const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/monacoEnv-DDxkZyi9.js","assets/initialize-Dcc4x6Mw.js","assets/initialize-BkHOBohE.css","assets/monacoEnv-CtyFC10v.css","assets/ActivitySafeEditor-jnRET48j.js"])))=>i.map(i=>d[i]);
var BUe=Object.defineProperty;var Vne=t=>{throw TypeError(t)};var jUe=(t,e,i)=>e in t?BUe(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i;var Go=(t,e,i)=>jUe(t,typeof e!="symbol"?e+"":e,i),EG=(t,e,i)=>e.has(t)||Vne("Cannot "+i);var At=(t,e,i)=>(EG(t,e,"read from private field"),i?i.call(t):e.get(t)),bi=(t,e,i)=>e.has(t)?Vne("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,i),Xr=(t,e,i,n)=>(EG(t,e,"write to private field"),n?n.call(t,i):e.set(t,i),i),Cn=(t,e,i)=>(EG(t,e,"access private method"),i);var dH=(t,e,i,n)=>({set _(r){Xr(t,e,r,i)},get _(){return At(t,e,n)}});function VUe(t,e){for(var i=0;i<e.length;i++){const n=e[i];if(typeof n!="string"&&!Array.isArray(n)){for(const r in n)if(r!=="default"&&!(r in t)){const o=Object.getOwnPropertyDescriptor(n,r);o&&Object.defineProperty(t,r,o.get?o:{enumerable:!0,get:()=>n[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const o of r)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&n(a)}).observe(document,{childList:!0,subtree:!0});function i(r){const o={};return r.integrity&&(o.integrity=r.integrity),r.referrerPolicy&&(o.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?o.credentials="include":r.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function n(r){if(r.ep)return;r.ep=!0;const o=i(r);fetch(r.href,o)}})();var xp=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function wc(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function RS(t){if(Object.prototype.hasOwnProperty.call(t,"__esModule"))return t;var e=t.default;if(typeof e=="function"){var i=function n(){return this instanceof n?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(i,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}),i}var wG={exports:{}},B2={};/**
 * @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 Hne;function HUe(){if(Hne)return B2;Hne=1;var t=Symbol.for("react.transitional.element"),e=Symbol.for("react.fragment");function i(n,r,o){var a=null;if(o!==void 0&&(a=""+o),r.key!==void 0&&(a=""+r.key),"key"in r){o={};for(var s in r)s!=="key"&&(o[s]=r[s])}else o=r;return r=o.ref,{$$typeof:t,type:n,key:a,ref:r!==void 0?r:null,props:o}}return B2.Fragment=e,B2.jsx=i,B2.jsxs=i,B2}var Une;function MP(){return Une||(Une=1,wG.exports=HUe()),wG.exports}var L=MP(),AG={exports:{}},En={};/**
 * @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 zne;function UUe(){if(zne)return En;zne=1;var t=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),r=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),c=Symbol.for("react.lazy"),d=Symbol.for("react.activity"),f=Symbol.iterator;function h(k){return k===null||typeof k!="object"?null:(k=f&&k[f]||k["@@iterator"],typeof k=="function"?k:null)}var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,v={};function y(k,X,W){this.props=k,this.context=X,this.refs=v,this.updater=W||p}y.prototype.isReactComponent={},y.prototype.setState=function(k,X){if(typeof k!="object"&&typeof k!="function"&&k!=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,k,X,"setState")},y.prototype.forceUpdate=function(k){this.updater.enqueueForceUpdate(this,k,"forceUpdate")};function m(){}m.prototype=y.prototype;function b(k,X,W){this.props=k,this.context=X,this.refs=v,this.updater=W||p}var S=b.prototype=new m;S.constructor=b,g(S,y.prototype),S.isPureReactComponent=!0;var _=Array.isArray;function C(){}var P={H:null,A:null,T:null,S:null},x=Object.prototype.hasOwnProperty;function E(k,X,W){var Y=W.ref;return{$$typeof:t,type:k,key:X,ref:Y!==void 0?Y:null,props:W}}function A(k,X){return E(k.type,X,k.props)}function R(k){return typeof k=="object"&&k!==null&&k.$$typeof===t}function M(k){var X={"=":"=0",":":"=2"};return"$"+k.replace(/[=:]/g,function(W){return X[W]})}var D=/\/+/g;function F(k,X){return typeof k=="object"&&k!==null&&k.key!=null?M(""+k.key):X.toString(36)}function I(k){switch(k.status){case"fulfilled":return k.value;case"rejected":throw k.reason;default:switch(typeof k.status=="string"?k.then(C,C):(k.status="pending",k.then(function(X){k.status==="pending"&&(k.status="fulfilled",k.value=X)},function(X){k.status==="pending"&&(k.status="rejected",k.reason=X)})),k.status){case"fulfilled":return k.value;case"rejected":throw k.reason}}throw k}function V(k,X,W,Y,te){var oe=typeof k;(oe==="undefined"||oe==="boolean")&&(k=null);var de=!1;if(k===null)de=!0;else switch(oe){case"bigint":case"string":case"number":de=!0;break;case"object":switch(k.$$typeof){case t:case e:de=!0;break;case c:return de=k._init,V(de(k._payload),X,W,Y,te)}}if(de)return te=te(k),de=Y===""?"."+F(k,0):Y,_(te)?(W="",de!=null&&(W=de.replace(D,"$&/")+"/"),V(te,X,W,"",function(Re){return Re})):te!=null&&(R(te)&&(te=A(te,W+(te.key==null||k&&k.key===te.key?"":(""+te.key).replace(D,"$&/")+"/")+de)),X.push(te)),1;de=0;var ge=Y===""?".":Y+":";if(_(k))for(var Ee=0;Ee<k.length;Ee++)Y=k[Ee],oe=ge+F(Y,Ee),de+=V(Y,X,W,oe,te);else if(Ee=h(k),typeof Ee=="function")for(k=Ee.call(k),Ee=0;!(Y=k.next()).done;)Y=Y.value,oe=ge+F(Y,Ee++),de+=V(Y,X,W,oe,te);else if(oe==="object"){if(typeof k.then=="function")return V(I(k),X,W,Y,te);throw X=String(k),Error("Objects are not valid as a React child (found: "+(X==="[object Object]"?"object with keys {"+Object.keys(k).join(", ")+"}":X)+"). If you meant to render a collection of children, use an array instead.")}return de}function z(k,X,W){if(k==null)return k;var Y=[],te=0;return V(k,Y,"","",function(oe){return X.call(W,oe,te++)}),Y}function G(k){if(k._status===-1){var X=k._result;X=X(),X.then(function(W){(k._status===0||k._status===-1)&&(k._status=1,k._result=W)},function(W){(k._status===0||k._status===-1)&&(k._status=2,k._result=W)}),k._status===-1&&(k._status=0,k._result=X)}if(k._status===1)return k._result.default;throw k._result}var H=typeof reportError=="function"?reportError:function(k){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var X=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof k=="object"&&k!==null&&typeof k.message=="string"?String(k.message):String(k),error:k});if(!window.dispatchEvent(X))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",k);return}console.error(k)},U={map:z,forEach:function(k,X,W){z(k,function(){X.apply(this,arguments)},W)},count:function(k){var X=0;return z(k,function(){X++}),X},toArray:function(k){return z(k,function(X){return X})||[]},only:function(k){if(!R(k))throw Error("React.Children.only expected to receive a single React element child.");return k}};return En.Activity=d,En.Children=U,En.Component=y,En.Fragment=i,En.Profiler=r,En.PureComponent=b,En.StrictMode=n,En.Suspense=l,En.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=P,En.__COMPILER_RUNTIME={__proto__:null,c:function(k){return P.H.useMemoCache(k)}},En.cache=function(k){return function(){return k.apply(null,arguments)}},En.cacheSignal=function(){return null},En.cloneElement=function(k,X,W){if(k==null)throw Error("The argument must be a React element, but you passed "+k+".");var Y=g({},k.props),te=k.key;if(X!=null)for(oe in X.key!==void 0&&(te=""+X.key),X)!x.call(X,oe)||oe==="key"||oe==="__self"||oe==="__source"||oe==="ref"&&X.ref===void 0||(Y[oe]=X[oe]);var oe=arguments.length-2;if(oe===1)Y.children=W;else if(1<oe){for(var de=Array(oe),ge=0;ge<oe;ge++)de[ge]=arguments[ge+2];Y.children=de}return E(k.type,te,Y)},En.createContext=function(k){return k={$$typeof:a,_currentValue:k,_currentValue2:k,_threadCount:0,Provider:null,Consumer:null},k.Provider=k,k.Consumer={$$typeof:o,_context:k},k},En.createElement=function(k,X,W){var Y,te={},oe=null;if(X!=null)for(Y in X.key!==void 0&&(oe=""+X.key),X)x.call(X,Y)&&Y!=="key"&&Y!=="__self"&&Y!=="__source"&&(te[Y]=X[Y]);var de=arguments.length-2;if(de===1)te.children=W;else if(1<de){for(var ge=Array(de),Ee=0;Ee<de;Ee++)ge[Ee]=arguments[Ee+2];te.children=ge}if(k&&k.defaultProps)for(Y in de=k.defaultProps,de)te[Y]===void 0&&(te[Y]=de[Y]);return E(k,oe,te)},En.createRef=function(){return{current:null}},En.forwardRef=function(k){return{$$typeof:s,render:k}},En.isValidElement=R,En.lazy=function(k){return{$$typeof:c,_payload:{_status:-1,_result:k},_init:G}},En.memo=function(k,X){return{$$typeof:u,type:k,compare:X===void 0?null:X}},En.startTransition=function(k){var X=P.T,W={};P.T=W;try{var Y=k(),te=P.S;te!==null&&te(W,Y),typeof Y=="object"&&Y!==null&&typeof Y.then=="function"&&Y.then(C,H)}catch(oe){H(oe)}finally{X!==null&&W.types!==null&&(X.types=W.types),P.T=X}},En.unstable_useCacheRefresh=function(){return P.H.useCacheRefresh()},En.use=function(k){return P.H.use(k)},En.useActionState=function(k,X,W){return P.H.useActionState(k,X,W)},En.useCallback=function(k,X){return P.H.useCallback(k,X)},En.useContext=function(k){return P.H.useContext(k)},En.useDebugValue=function(){},En.useDeferredValue=function(k,X){return P.H.useDeferredValue(k,X)},En.useEffect=function(k,X){return P.H.useEffect(k,X)},En.useEffectEvent=function(k){return P.H.useEffectEvent(k)},En.useId=function(){return P.H.useId()},En.useImperativeHandle=function(k,X,W){return P.H.useImperativeHandle(k,X,W)},En.useInsertionEffect=function(k,X){return P.H.useInsertionEffect(k,X)},En.useLayoutEffect=function(k,X){return P.H.useLayoutEffect(k,X)},En.useMemo=function(k,X){return P.H.useMemo(k,X)},En.useOptimistic=function(k,X){return P.H.useOptimistic(k,X)},En.useReducer=function(k,X,W){return P.H.useReducer(k,X,W)},En.useRef=function(k){return P.H.useRef(k)},En.useState=function(k){return P.H.useState(k)},En.useSyncExternalStore=function(k,X,W){return P.H.useSyncExternalStore(k,X,W)},En.useTransition=function(){return P.H.useTransition()},En.version="19.2.0",En}var $ne;function ld(){return $ne||($ne=1,AG.exports=UUe()),AG.exports}var J=ld();const Wn=wc(J),s5=VUe({__proto__:null,default:Wn},[J]);var OG={exports:{}},j2={},DG={exports:{}},RG={};/**
 * @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 Wne;function zUe(){return Wne||(Wne=1,(function(t){function e(V,z){var G=V.length;V.push(z);e:for(;0<G;){var H=G-1>>>1,U=V[H];if(0<r(U,z))V[H]=z,V[G]=U,G=H;else break e}}function i(V){return V.length===0?null:V[0]}function n(V){if(V.length===0)return null;var z=V[0],G=V.pop();if(G!==z){V[0]=G;e:for(var H=0,U=V.length,k=U>>>1;H<k;){var X=2*(H+1)-1,W=V[X],Y=X+1,te=V[Y];if(0>r(W,G))Y<U&&0>r(te,W)?(V[H]=te,V[Y]=G,H=Y):(V[H]=W,V[X]=G,H=X);else if(Y<U&&0>r(te,G))V[H]=te,V[Y]=G,H=Y;else break e}}return z}function r(V,z){var G=V.sortIndex-z.sortIndex;return G!==0?G:V.id-z.id}if(t.unstable_now=void 0,typeof performance=="object"&&typeof performance.now=="function"){var o=performance;t.unstable_now=function(){return o.now()}}else{var a=Date,s=a.now();t.unstable_now=function(){return a.now()-s}}var l=[],u=[],c=1,d=null,f=3,h=!1,p=!1,g=!1,v=!1,y=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,b=typeof setImmediate<"u"?setImmediate:null;function S(V){for(var z=i(u);z!==null;){if(z.callback===null)n(u);else if(z.startTime<=V)n(u),z.sortIndex=z.expirationTime,e(l,z);else break;z=i(u)}}function _(V){if(g=!1,S(V),!p)if(i(l)!==null)p=!0,C||(C=!0,M());else{var z=i(u);z!==null&&I(_,z.startTime-V)}}var C=!1,P=-1,x=5,E=-1;function A(){return v?!0:!(t.unstable_now()-E<x)}function R(){if(v=!1,C){var V=t.unstable_now();E=V;var z=!0;try{e:{p=!1,g&&(g=!1,m(P),P=-1),h=!0;var G=f;try{t:{for(S(V),d=i(l);d!==null&&!(d.expirationTime>V&&A());){var H=d.callback;if(typeof H=="function"){d.callback=null,f=d.priorityLevel;var U=H(d.expirationTime<=V);if(V=t.unstable_now(),typeof U=="function"){d.callback=U,S(V),z=!0;break t}d===i(l)&&n(l),S(V)}else n(l);d=i(l)}if(d!==null)z=!0;else{var k=i(u);k!==null&&I(_,k.startTime-V),z=!1}}break e}finally{d=null,f=G,h=!1}z=void 0}}finally{z?M():C=!1}}}var M;if(typeof b=="function")M=function(){b(R)};else if(typeof MessageChannel<"u"){var D=new MessageChannel,F=D.port2;D.port1.onmessage=R,M=function(){F.postMessage(null)}}else M=function(){y(R,0)};function I(V,z){P=y(function(){V(t.unstable_now())},z)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(V){V.callback=null},t.unstable_forceFrameRate=function(V){0>V||125<V?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):x=0<V?Math.floor(1e3/V):5},t.unstable_getCurrentPriorityLevel=function(){return f},t.unstable_next=function(V){switch(f){case 1:case 2:case 3:var z=3;break;default:z=f}var G=f;f=z;try{return V()}finally{f=G}},t.unstable_requestPaint=function(){v=!0},t.unstable_runWithPriority=function(V,z){switch(V){case 1:case 2:case 3:case 4:case 5:break;default:V=3}var G=f;f=V;try{return z()}finally{f=G}},t.unstable_scheduleCallback=function(V,z,G){var H=t.unstable_now();switch(typeof G=="object"&&G!==null?(G=G.delay,G=typeof G=="number"&&0<G?H+G:H):G=H,V){case 1:var U=-1;break;case 2:U=250;break;case 5:U=1073741823;break;case 4:U=1e4;break;default:U=5e3}return U=G+U,V={id:c++,callback:z,priorityLevel:V,startTime:G,expirationTime:U,sortIndex:-1},G>H?(V.sortIndex=G,e(u,V),i(l)===null&&V===i(u)&&(g?(m(P),P=-1):g=!0,I(_,G-H))):(V.sortIndex=U,e(l,V),p||h||(p=!0,C||(C=!0,M()))),V},t.unstable_shouldYield=A,t.unstable_wrapCallback=function(V){var z=f;return function(){var G=f;f=z;try{return V.apply(this,arguments)}finally{f=G}}}})(RG)),RG}var Gne;function $Ue(){return Gne||(Gne=1,DG.exports=zUe()),DG.exports}var MG={exports:{}},Dd={};/**
 * @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 Yne;function WUe(){if(Yne)return Dd;Yne=1;var t=ld();function e(l){var u="https://react.dev/errors/"+l;if(1<arguments.length){u+="?args[]="+encodeURIComponent(arguments[1]);for(var c=2;c<arguments.length;c++)u+="&args[]="+encodeURIComponent(arguments[c])}return"Minified React error #"+l+"; visit "+u+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function i(){}var n={d:{f:i,r:function(){throw Error(e(522))},D:i,C:i,L:i,m:i,X:i,S:i,M:i},p:0,findDOMNode:null},r=Symbol.for("react.portal");function o(l,u,c){var d=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:r,key:d==null?null:""+d,children:l,containerInfo:u,implementation:c}}var a=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function s(l,u){if(l==="font")return"";if(typeof u=="string")return u==="use-credentials"?u:""}return Dd.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=n,Dd.createPortal=function(l,u){var c=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!u||u.nodeType!==1&&u.nodeType!==9&&u.nodeType!==11)throw Error(e(299));return o(l,u,null,c)},Dd.flushSync=function(l){var u=a.T,c=n.p;try{if(a.T=null,n.p=2,l)return l()}finally{a.T=u,n.p=c,n.d.f()}},Dd.preconnect=function(l,u){typeof l=="string"&&(u?(u=u.crossOrigin,u=typeof u=="string"?u==="use-credentials"?u:"":void 0):u=null,n.d.C(l,u))},Dd.prefetchDNS=function(l){typeof l=="string"&&n.d.D(l)},Dd.preinit=function(l,u){if(typeof l=="string"&&u&&typeof u.as=="string"){var c=u.as,d=s(c,u.crossOrigin),f=typeof u.integrity=="string"?u.integrity:void 0,h=typeof u.fetchPriority=="string"?u.fetchPriority:void 0;c==="style"?n.d.S(l,typeof u.precedence=="string"?u.precedence:void 0,{crossOrigin:d,integrity:f,fetchPriority:h}):c==="script"&&n.d.X(l,{crossOrigin:d,integrity:f,fetchPriority:h,nonce:typeof u.nonce=="string"?u.nonce:void 0})}},Dd.preinitModule=function(l,u){if(typeof l=="string")if(typeof u=="object"&&u!==null){if(u.as==null||u.as==="script"){var c=s(u.as,u.crossOrigin);n.d.M(l,{crossOrigin:c,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0})}}else u==null&&n.d.M(l)},Dd.preload=function(l,u){if(typeof l=="string"&&typeof u=="object"&&u!==null&&typeof u.as=="string"){var c=u.as,d=s(c,u.crossOrigin);n.d.L(l,c,{crossOrigin:d,integrity:typeof u.integrity=="string"?u.integrity:void 0,nonce:typeof u.nonce=="string"?u.nonce:void 0,type:typeof u.type=="string"?u.type:void 0,fetchPriority:typeof u.fetchPriority=="string"?u.fetchPriority:void 0,referrerPolicy:typeof u.referrerPolicy=="string"?u.referrerPolicy:void 0,imageSrcSet:typeof u.imageSrcSet=="string"?u.imageSrcSet:void 0,imageSizes:typeof u.imageSizes=="string"?u.imageSizes:void 0,media:typeof u.media=="string"?u.media:void 0})}},Dd.preloadModule=function(l,u){if(typeof l=="string")if(u){var c=s(u.as,u.crossOrigin);n.d.m(l,{as:typeof u.as=="string"&&u.as!=="script"?u.as:void 0,crossOrigin:c,integrity:typeof u.integrity=="string"?u.integrity:void 0})}else n.d.m(l)},Dd.requestFormReset=function(l){n.d.r(l)},Dd.unstable_batchedUpdates=function(l,u){return l(u)},Dd.useFormState=function(l,u,c){return a.H.useFormState(l,u,c)},Dd.useFormStatus=function(){return a.H.useHostTransitionStatus()},Dd.version="19.2.0",Dd}var qne;function uEe(){if(qne)return MG.exports;qne=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(e){console.error(e)}}return t(),MG.exports=WUe(),MG.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 Xne;function GUe(){if(Xne)return j2;Xne=1;var t=$Ue(),e=ld(),i=uEe();function n(T){var w="https://react.dev/errors/"+T;if(1<arguments.length){w+="?args[]="+encodeURIComponent(arguments[1]);for(var N=2;N<arguments.length;N++)w+="&args[]="+encodeURIComponent(arguments[N])}return"Minified React error #"+T+"; visit "+w+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}function r(T){return!(!T||T.nodeType!==1&&T.nodeType!==9&&T.nodeType!==11)}function o(T){var w=T,N=T;if(T.alternate)for(;w.return;)w=w.return;else{T=w;do w=T,(w.flags&4098)!==0&&(N=w.return),T=w.return;while(T)}return w.tag===3?N:null}function a(T){if(T.tag===13){var w=T.memoizedState;if(w===null&&(T=T.alternate,T!==null&&(w=T.memoizedState)),w!==null)return w.dehydrated}return null}function s(T){if(T.tag===31){var w=T.memoizedState;if(w===null&&(T=T.alternate,T!==null&&(w=T.memoizedState)),w!==null)return w.dehydrated}return null}function l(T){if(o(T)!==T)throw Error(n(188))}function u(T){var w=T.alternate;if(!w){if(w=o(T),w===null)throw Error(n(188));return w!==T?null:T}for(var N=T,q=w;;){var ne=N.return;if(ne===null)break;var ue=ne.alternate;if(ue===null){if(q=ne.return,q!==null){N=q;continue}break}if(ne.child===ue.child){for(ue=ne.child;ue;){if(ue===N)return l(ne),T;if(ue===q)return l(ne),w;ue=ue.sibling}throw Error(n(188))}if(N.return!==q.return)N=ne,q=ue;else{for(var Ie=!1,ot=ne.child;ot;){if(ot===N){Ie=!0,N=ne,q=ue;break}if(ot===q){Ie=!0,q=ne,N=ue;break}ot=ot.sibling}if(!Ie){for(ot=ue.child;ot;){if(ot===N){Ie=!0,N=ue,q=ne;break}if(ot===q){Ie=!0,q=ue,N=ne;break}ot=ot.sibling}if(!Ie)throw Error(n(189))}}if(N.alternate!==q)throw Error(n(190))}if(N.tag!==3)throw Error(n(188));return N.stateNode.current===N?T:w}function c(T){var w=T.tag;if(w===5||w===26||w===27||w===6)return T;for(T=T.child;T!==null;){if(w=c(T),w!==null)return w;T=T.sibling}return null}var d=Object.assign,f=Symbol.for("react.element"),h=Symbol.for("react.transitional.element"),p=Symbol.for("react.portal"),g=Symbol.for("react.fragment"),v=Symbol.for("react.strict_mode"),y=Symbol.for("react.profiler"),m=Symbol.for("react.consumer"),b=Symbol.for("react.context"),S=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),C=Symbol.for("react.suspense_list"),P=Symbol.for("react.memo"),x=Symbol.for("react.lazy"),E=Symbol.for("react.activity"),A=Symbol.for("react.memo_cache_sentinel"),R=Symbol.iterator;function M(T){return T===null||typeof T!="object"?null:(T=R&&T[R]||T["@@iterator"],typeof T=="function"?T:null)}var D=Symbol.for("react.client.reference");function F(T){if(T==null)return null;if(typeof T=="function")return T.$$typeof===D?null:T.displayName||T.name||null;if(typeof T=="string")return T;switch(T){case g:return"Fragment";case y:return"Profiler";case v:return"StrictMode";case _:return"Suspense";case C:return"SuspenseList";case E:return"Activity"}if(typeof T=="object")switch(T.$$typeof){case p:return"Portal";case b:return T.displayName||"Context";case m:return(T._context.displayName||"Context")+".Consumer";case S:var w=T.render;return T=T.displayName,T||(T=w.displayName||w.name||"",T=T!==""?"ForwardRef("+T+")":"ForwardRef"),T;case P:return w=T.displayName||null,w!==null?w:F(T.type)||"Memo";case x:w=T._payload,T=T._init;try{return F(T(w))}catch{}}return null}var I=Array.isArray,V=e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,z=i.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,G={pending:!1,data:null,method:null,action:null},H=[],U=-1;function k(T){return{current:T}}function X(T){0>U||(T.current=H[U],H[U]=null,U--)}function W(T,w){U++,H[U]=T.current,T.current=w}var Y=k(null),te=k(null),oe=k(null),de=k(null);function ge(T,w){switch(W(oe,w),W(te,T),W(Y,null),w.nodeType){case 9:case 11:T=(T=w.documentElement)&&(T=T.namespaceURI)?_0(T):0;break;default:if(T=w.tagName,w=w.namespaceURI)w=_0(w),T=mc(w,T);else switch(T){case"svg":T=1;break;case"math":T=2;break;default:T=0}}X(Y),W(Y,T)}function Ee(){X(Y),X(te),X(oe)}function Re(T){T.memoizedState!==null&&W(de,T);var w=Y.current,N=mc(w,T.type);w!==N&&(W(te,T),W(Y,N))}function Ae(T){te.current===T&&(X(Y),X(te)),de.current===T&&(X(de),Sy._currentValue=G)}var Pe,we;function Te(T){if(Pe===void 0)try{throw Error()}catch(N){var w=N.stack.trim().match(/\n( *(at )?)/);Pe=w&&w[1]||"",we=-1<N.stack.indexOf(`
    at`)?" (<anonymous>)":-1<N.stack.indexOf("@")?"@unknown:0:0":""}return`
`+Pe+T+we}var ke=!1;function $e(T,w){if(!T||ke)return"";ke=!0;var N=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var q={DetermineComponentFrameRoot:function(){try{if(w){var Pr=function(){throw Error()};if(Object.defineProperty(Pr.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(Pr,[])}catch(ar){var ir=ar}Reflect.construct(T,[],Pr)}else{try{Pr.call()}catch(ar){ir=ar}T.call(Pr.prototype)}}else{try{throw Error()}catch(ar){ir=ar}(Pr=T())&&typeof Pr.catch=="function"&&Pr.catch(function(){})}}catch(ar){if(ar&&ir&&typeof ar.stack=="string")return[ar.stack,ir.stack]}return[null,null]}};q.DetermineComponentFrameRoot.displayName="DetermineComponentFrameRoot";var ne=Object.getOwnPropertyDescriptor(q.DetermineComponentFrameRoot,"name");ne&&ne.configurable&&Object.defineProperty(q.DetermineComponentFrameRoot,"name",{value:"DetermineComponentFrameRoot"});var ue=q.DetermineComponentFrameRoot(),Ie=ue[0],ot=ue[1];if(Ie&&ot){var Et=Ie.split(`
`),tr=ot.split(`
`);for(ne=q=0;q<Et.length&&!Et[q].includes("DetermineComponentFrameRoot");)q++;for(;ne<tr.length&&!tr[ne].includes("DetermineComponentFrameRoot");)ne++;if(q===Et.length||ne===tr.length)for(q=Et.length-1,ne=tr.length-1;1<=q&&0<=ne&&Et[q]!==tr[ne];)ne--;for(;1<=q&&0<=ne;q--,ne--)if(Et[q]!==tr[ne]){if(q!==1||ne!==1)do if(q--,ne--,0>ne||Et[q]!==tr[ne]){var yr=`
`+Et[q].replace(" at new "," at ");return T.displayName&&yr.includes("<anonymous>")&&(yr=yr.replace("<anonymous>",T.displayName)),yr}while(1<=q&&0<=ne);break}}}finally{ke=!1,Error.prepareStackTrace=N}return(N=T?T.displayName||T.name:"")?Te(N):""}function Ne(T,w){switch(T.tag){case 26:case 27:case 5:return Te(T.type);case 16:return Te("Lazy");case 13:return T.child!==w&&w!==null?Te("Suspense Fallback"):Te("Suspense");case 19:return Te("SuspenseList");case 0:case 15:return $e(T.type,!1);case 11:return $e(T.type.render,!1);case 1:return $e(T.type,!0);case 31:return Te("Activity");default:return""}}function ve(T){try{var w="",N=null;do w+=Ne(T,N),N=T,T=T.return;while(T);return w}catch(q){return`
Error generating stack: `+q.message+`
`+q.stack}}var pe=Object.prototype.hasOwnProperty,fe=t.unstable_scheduleCallback,me=t.unstable_cancelCallback,Ce=t.unstable_shouldYield,Ue=t.unstable_requestPaint,Qe=t.unstable_now,it=t.unstable_getCurrentPriorityLevel,xt=t.unstable_ImmediatePriority,wt=t.unstable_UserBlockingPriority,$t=t.unstable_NormalPriority,Mt=t.unstable_LowPriority,rt=t.unstable_IdlePriority,qe=t.log,vt=t.unstable_setDisableYieldValue,kt=null,Xe=null;function _t(T){if(typeof qe=="function"&&vt(T),Xe&&typeof Xe.setStrictMode=="function")try{Xe.setStrictMode(kt,T)}catch{}}var Ht=Math.clz32?Math.clz32:zt,Pt=Math.log,Jt=Math.LN2;function zt(T){return T>>>=0,T===0?32:31-(Pt(T)/Jt|0)|0}var Bt=256,Mr=262144,Be=4194304;function We(T){var w=T&42;if(w!==0)return w;switch(T&-T){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return T&261888;case 262144:case 524288:case 1048576:case 2097152:return T&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return T&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return T}}function dt(T,w,N){var q=T.pendingLanes;if(q===0)return 0;var ne=0,ue=T.suspendedLanes,Ie=T.pingedLanes;T=T.warmLanes;var ot=q&134217727;return ot!==0?(q=ot&~ue,q!==0?ne=We(q):(Ie&=ot,Ie!==0?ne=We(Ie):N||(N=ot&~T,N!==0&&(ne=We(N))))):(ot=q&~ue,ot!==0?ne=We(ot):Ie!==0?ne=We(Ie):N||(N=q&~T,N!==0&&(ne=We(N)))),ne===0?0:w!==0&&w!==ne&&(w&ue)===0&&(ue=ne&-ne,N=w&-w,ue>=N||ue===32&&(N&4194048)!==0)?w:ne}function Tt(T,w){return(T.pendingLanes&~(T.suspendedLanes&~T.pingedLanes)&w)===0}function nr(T,w){switch(T){case 1:case 2:case 4:case 8:case 64:return w+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 w+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 Ar(){var T=Be;return Be<<=1,(Be&62914560)===0&&(Be=4194304),T}function Qr(T){for(var w=[],N=0;31>N;N++)w.push(T);return w}function Si(T,w){T.pendingLanes|=w,w!==268435456&&(T.suspendedLanes=0,T.pingedLanes=0,T.warmLanes=0)}function oi(T,w,N,q,ne,ue){var Ie=T.pendingLanes;T.pendingLanes=N,T.suspendedLanes=0,T.pingedLanes=0,T.warmLanes=0,T.expiredLanes&=N,T.entangledLanes&=N,T.errorRecoveryDisabledLanes&=N,T.shellSuspendCounter=0;var ot=T.entanglements,Et=T.expirationTimes,tr=T.hiddenUpdates;for(N=Ie&~N;0<N;){var yr=31-Ht(N),Pr=1<<yr;ot[yr]=0,Et[yr]=-1;var ir=tr[yr];if(ir!==null)for(tr[yr]=null,yr=0;yr<ir.length;yr++){var ar=ir[yr];ar!==null&&(ar.lane&=-536870913)}N&=~Pr}q!==0&&Yr(T,q,0),ue!==0&&ne===0&&T.tag!==0&&(T.suspendedLanes|=ue&~(Ie&~w))}function Yr(T,w,N){T.pendingLanes|=w,T.suspendedLanes&=~w;var q=31-Ht(w);T.entangledLanes|=w,T.entanglements[q]=T.entanglements[q]|1073741824|N&261930}function vi(T,w){var N=T.entangledLanes|=w;for(T=T.entanglements;N;){var q=31-Ht(N),ne=1<<q;ne&w|T[q]&w&&(T[q]|=w),N&=~ne}}function rr(T,w){var N=w&-w;return N=(N&42)!==0?1:Ji(N),(N&(T.suspendedLanes|w))!==0?0:N}function Ji(T){switch(T){case 2:T=1;break;case 8:T=4;break;case 32:T=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:T=128;break;case 268435456:T=134217728;break;default:T=0}return T}function qn(T){return T&=-T,2<T?8<T?(T&134217727)!==0?32:268435456:8:2}function ri(){var T=z.p;return T!==0?T:(T=window.event,T===void 0?32:IM(T.type))}function eo(T,w){var N=z.p;try{return z.p=T,w()}finally{z.p=N}}var xn=Math.random().toString(36).slice(2),mt="__reactFiber$"+xn,gr="__reactProps$"+xn,ce="__reactContainer$"+xn,fr="__reactEvents$"+xn,Yt="__reactListeners$"+xn,Lr="__reactHandles$"+xn,Cr="__reactResources$"+xn,zr="__reactMarker$"+xn;function fi(T){delete T[mt],delete T[gr],delete T[fr],delete T[Yt],delete T[Lr]}function to(T){var w=T[mt];if(w)return w;for(var N=T.parentNode;N;){if(w=N[ce]||N[mt]){if(N=w.alternate,w.child!==null||N!==null&&N.child!==null)for(T=mM(T);T!==null;){if(N=T[mt])return N;T=mM(T)}return w}T=N,N=T.parentNode}return null}function st(T){if(T=T[mt]||T[ce]){var w=T.tag;if(w===5||w===6||w===13||w===31||w===26||w===27||w===3)return T}return null}function zo(T){var w=T.tag;if(w===5||w===26||w===27||w===6)return T.stateNode;throw Error(n(33))}function hi(T){var w=T[Cr];return w||(w=T[Cr]={hoistableStyles:new Map,hoistableScripts:new Map}),w}function si(T){T[zr]=!0}var sr=new Set,Ns={};function ts(T,w){Z(T,w),Z(T+"Capture",w)}function Z(T,w){for(Ns[T]=w,T=0;T<w.length;T++)sr.add(w[T])}var re=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]*$"),ye={},Ye={};function gt(T){return pe.call(Ye,T)?!0:pe.call(ye,T)?!1:re.test(T)?Ye[T]=!0:(ye[T]=!0,!1)}function Dt(T,w,N){if(gt(w))if(N===null)T.removeAttribute(w);else{switch(typeof N){case"undefined":case"function":case"symbol":T.removeAttribute(w);return;case"boolean":var q=w.toLowerCase().slice(0,5);if(q!=="data-"&&q!=="aria-"){T.removeAttribute(w);return}}T.setAttribute(w,""+N)}}function pr(T,w,N){if(N===null)T.removeAttribute(w);else{switch(typeof N){case"undefined":case"function":case"symbol":case"boolean":T.removeAttribute(w);return}T.setAttribute(w,""+N)}}function Gr(T,w,N,q){if(q===null)T.removeAttribute(N);else{switch(typeof q){case"undefined":case"function":case"symbol":case"boolean":T.removeAttribute(N);return}T.setAttributeNS(w,N,""+q)}}function rn(T){switch(typeof T){case"bigint":case"boolean":case"number":case"string":case"undefined":return T;case"object":return T;default:return""}}function ro(T){var w=T.type;return(T=T.nodeName)&&T.toLowerCase()==="input"&&(w==="checkbox"||w==="radio")}function na(T,w,N){var q=Object.getOwnPropertyDescriptor(T.constructor.prototype,w);if(!T.hasOwnProperty(w)&&typeof q<"u"&&typeof q.get=="function"&&typeof q.set=="function"){var ne=q.get,ue=q.set;return Object.defineProperty(T,w,{configurable:!0,get:function(){return ne.call(this)},set:function(Ie){N=""+Ie,ue.call(this,Ie)}}),Object.defineProperty(T,w,{enumerable:q.enumerable}),{getValue:function(){return N},setValue:function(Ie){N=""+Ie},stopTracking:function(){T._valueTracker=null,delete T[w]}}}}function yl(T){if(!T._valueTracker){var w=ro(T)?"checked":"value";T._valueTracker=na(T,w,""+T[w])}}function Ga(T){if(!T)return!1;var w=T._valueTracker;if(!w)return!0;var N=w.getValue(),q="";return T&&(q=ro(T)?T.checked?"true":"false":T.value),T=q,T!==N?(w.setValue(T),!0):!1}function ys(T){if(T=T||(typeof document<"u"?document:void 0),typeof T>"u")return null;try{return T.activeElement||T.body}catch{return T.body}}var tc=/[\n"\\]/g;function rs(T){return T.replace(tc,function(w){return"\\"+w.charCodeAt(0).toString(16)+" "})}function rc(T,w,N,q,ne,ue,Ie,ot){T.name="",Ie!=null&&typeof Ie!="function"&&typeof Ie!="symbol"&&typeof Ie!="boolean"?T.type=Ie:T.removeAttribute("type"),w!=null?Ie==="number"?(w===0&&T.value===""||T.value!=w)&&(T.value=""+rn(w)):T.value!==""+rn(w)&&(T.value=""+rn(w)):Ie!=="submit"&&Ie!=="reset"||T.removeAttribute("value"),w!=null?fu(T,Ie,rn(w)):N!=null?fu(T,Ie,rn(N)):q!=null&&T.removeAttribute("value"),ne==null&&ue!=null&&(T.defaultChecked=!!ue),ne!=null&&(T.checked=ne&&typeof ne!="function"&&typeof ne!="symbol"),ot!=null&&typeof ot!="function"&&typeof ot!="symbol"&&typeof ot!="boolean"?T.name=""+rn(ot):T.removeAttribute("name")}function Hl(T,w,N,q,ne,ue,Ie,ot){if(ue!=null&&typeof ue!="function"&&typeof ue!="symbol"&&typeof ue!="boolean"&&(T.type=ue),w!=null||N!=null){if(!(ue!=="submit"&&ue!=="reset"||w!=null)){yl(T);return}N=N!=null?""+rn(N):"",w=w!=null?""+rn(w):N,ot||w===T.value||(T.value=w),T.defaultValue=w}q=q??ne,q=typeof q!="function"&&typeof q!="symbol"&&!!q,T.checked=ot?T.checked:!!q,T.defaultChecked=!!q,Ie!=null&&typeof Ie!="function"&&typeof Ie!="symbol"&&typeof Ie!="boolean"&&(T.name=Ie),yl(T)}function fu(T,w,N){w==="number"&&ys(T.ownerDocument)===T||T.defaultValue===""+N||(T.defaultValue=""+N)}function hu(T,w,N,q){if(T=T.options,w){w={};for(var ne=0;ne<N.length;ne++)w["$"+N[ne]]=!0;for(N=0;N<T.length;N++)ne=w.hasOwnProperty("$"+T[N].value),T[N].selected!==ne&&(T[N].selected=ne),ne&&q&&(T[N].defaultSelected=!0)}else{for(N=""+rn(N),w=null,ne=0;ne<T.length;ne++){if(T[ne].value===N){T[ne].selected=!0,q&&(T[ne].defaultSelected=!0);return}w!==null||T[ne].disabled||(w=T[ne])}w!==null&&(w.selected=!0)}}function ic(T,w,N){if(w!=null&&(w=""+rn(w),w!==T.value&&(T.value=w),N==null)){T.defaultValue!==w&&(T.defaultValue=w);return}T.defaultValue=N!=null?""+rn(N):""}function rl(T,w,N,q){if(w==null){if(q!=null){if(N!=null)throw Error(n(92));if(I(q)){if(1<q.length)throw Error(n(93));q=q[0]}N=q}N==null&&(N=""),w=N}N=rn(w),T.defaultValue=N,q=T.textContent,q===N&&q!==""&&q!==null&&(T.value=q),yl(T)}function oa(T,w){if(w){var N=T.firstChild;if(N&&N===T.lastChild&&N.nodeType===3){N.nodeValue=w;return}}T.textContent=w}var Wd=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 Ya(T,w,N){var q=w.indexOf("--")===0;N==null||typeof N=="boolean"||N===""?q?T.setProperty(w,""):w==="float"?T.cssFloat="":T[w]="":q?T.setProperty(w,N):typeof N!="number"||N===0||Wd.has(w)?w==="float"?T.cssFloat=N:T[w]=(""+N).trim():T[w]=N+"px"}function cd(T,w,N){if(w!=null&&typeof w!="object")throw Error(n(62));if(T=T.style,N!=null){for(var q in N)!N.hasOwnProperty(q)||w!=null&&w.hasOwnProperty(q)||(q.indexOf("--")===0?T.setProperty(q,""):q==="float"?T.cssFloat="":T[q]="");for(var ne in w)q=w[ne],w.hasOwnProperty(ne)&&N[ne]!==q&&Ya(T,ne,q)}else for(var ue in w)w.hasOwnProperty(ue)&&Ya(T,ue,w[ue])}function ml(T){if(T.indexOf("-")===-1)return!1;switch(T){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Fs=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"]]),Ul=/^[\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 wo(T){return Ul.test(""+T)?"javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')":T}function Ta(){}var Lo=null;function ao(T){return T=T.target||T.srcElement||window,T.correspondingUseElement&&(T=T.correspondingUseElement),T.nodeType===3?T.parentNode:T}var bl=null,nc=null;function Vu(T){var w=st(T);if(w&&(T=w.stateNode)){var N=T[gr]||null;e:switch(T=w.stateNode,w.type){case"input":if(rc(T,N.value,N.defaultValue,N.defaultValue,N.checked,N.defaultChecked,N.type,N.name),w=N.name,N.type==="radio"&&w!=null){for(N=T;N.parentNode;)N=N.parentNode;for(N=N.querySelectorAll('input[name="'+rs(""+w)+'"][type="radio"]'),w=0;w<N.length;w++){var q=N[w];if(q!==T&&q.form===T.form){var ne=q[gr]||null;if(!ne)throw Error(n(90));rc(q,ne.value,ne.defaultValue,ne.defaultValue,ne.checked,ne.defaultChecked,ne.type,ne.name)}}for(w=0;w<N.length;w++)q=N[w],q.form===T.form&&Ga(q)}break e;case"textarea":ic(T,N.value,N.defaultValue);break e;case"select":w=N.value,w!=null&&hu(T,!!N.multiple,w,!1)}}}var dd=!1;function xa(T,w,N){if(dd)return T(w,N);dd=!0;try{var q=T(w);return q}finally{if(dd=!1,(bl!==null||nc!==null)&&(h_(),bl&&(w=bl,T=nc,nc=bl=null,Vu(w),T)))for(w=0;w<T.length;w++)Vu(T[w])}}function Fa(T,w){var N=T.stateNode;if(N===null)return null;var q=N[gr]||null;if(q===null)return null;N=q[w];e:switch(w){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(q=!q.disabled)||(T=T.type,q=!(T==="button"||T==="input"||T==="select"||T==="textarea")),T=!q;break e;default:T=!1}if(T)return null;if(N&&typeof N!="function")throw Error(n(231,w,typeof N));return N}var va=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Gd=!1;if(va)try{var Oc={};Object.defineProperty(Oc,"passive",{get:function(){Gd=!0}}),window.addEventListener("test",Oc,Oc),window.removeEventListener("test",Oc,Oc)}catch{Gd=!1}var il=null,aa=null,Qi=null;function mn(){if(Qi)return Qi;var T,w=aa,N=w.length,q,ne="value"in il?il.value:il.textContent,ue=ne.length;for(T=0;T<N&&w[T]===ne[T];T++);var Ie=N-T;for(q=1;q<=Ie&&w[N-q]===ne[ue-q];q++);return Qi=ne.slice(T,1<q?1-q:void 0)}function oc(T){var w=T.keyCode;return"charCode"in T?(T=T.charCode,T===0&&w===13&&(T=13)):T=w,T===10&&(T=13),32<=T||T===13?T:0}function _e(){return!0}function He(){return!1}function et(T){function w(N,q,ne,ue,Ie){this._reactName=N,this._targetInst=ne,this.type=q,this.nativeEvent=ue,this.target=Ie,this.currentTarget=null;for(var ot in T)T.hasOwnProperty(ot)&&(N=T[ot],this[ot]=N?N(ue):ue[ot]);return this.isDefaultPrevented=(ue.defaultPrevented!=null?ue.defaultPrevented:ue.returnValue===!1)?_e:He,this.isPropagationStopped=He,this}return d(w.prototype,{preventDefault:function(){this.defaultPrevented=!0;var N=this.nativeEvent;N&&(N.preventDefault?N.preventDefault():typeof N.returnValue!="unknown"&&(N.returnValue=!1),this.isDefaultPrevented=_e)},stopPropagation:function(){var N=this.nativeEvent;N&&(N.stopPropagation?N.stopPropagation():typeof N.cancelBubble!="unknown"&&(N.cancelBubble=!0),this.isPropagationStopped=_e)},persist:function(){},isPersistent:_e}),w}var ht={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(T){return T.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Ft=et(ht),ur=d({},ht,{view:0,detail:0}),Lt=et(ur),Kt,Zr,ni,pi=d({},ur,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Yd,button:0,buttons:0,relatedTarget:function(T){return T.relatedTarget===void 0?T.fromElement===T.srcElement?T.toElement:T.fromElement:T.relatedTarget},movementX:function(T){return"movementX"in T?T.movementX:(T!==ni&&(ni&&T.type==="mousemove"?(Kt=T.screenX-ni.screenX,Zr=T.screenY-ni.screenY):Zr=Kt=0,ni=T),Kt)},movementY:function(T){return"movementY"in T?T.movementY:Zr}}),Oi=et(pi),Bi=d({},pi,{dataTransfer:0}),ms=et(Bi),Ba=d({},ur,{relatedTarget:0}),Sl=et(Ba),zl=d({},ht,{animationName:0,elapsedTime:0,pseudoElement:0}),Hu=et(zl),fd=d({},ht,{clipboardData:function(T){return"clipboardData"in T?T.clipboardData:window.clipboardData}}),Bs=et(fd),jg=d({},ht,{data:0}),js=et(jg),qf={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},hd={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"},is={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Xf(T){var w=this.nativeEvent;return w.getModifierState?w.getModifierState(T):(T=is[T])?!!w[T]:!1}function Yd(){return Xf}var ko=d({},ur,{key:function(T){if(T.key){var w=qf[T.key]||T.key;if(w!=="Unidentified")return w}return T.type==="keypress"?(T=oc(T),T===13?"Enter":String.fromCharCode(T)):T.type==="keydown"||T.type==="keyup"?hd[T.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Yd,charCode:function(T){return T.type==="keypress"?oc(T):0},keyCode:function(T){return T.type==="keydown"||T.type==="keyup"?T.keyCode:0},which:function(T){return T.type==="keypress"?oc(T):T.type==="keydown"||T.type==="keyup"?T.keyCode:0}}),ac=et(ko),Nh=d({},pi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),pd=et(Nh),Fh=d({},ur,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Yd}),Vg=et(Fh),Hg=d({},ht,{propertyName:0,elapsedTime:0,pseudoElement:0}),Kf=et(Hg),gd=d({},pi,{deltaX:function(T){return"deltaX"in T?T.deltaX:"wheelDeltaX"in T?-T.wheelDeltaX:0},deltaY:function(T){return"deltaY"in T?T.deltaY:"wheelDeltaY"in T?-T.wheelDeltaY:"wheelDelta"in T?-T.wheelDelta:0},deltaZ:0,deltaMode:0}),Zf=et(gd),Di=d({},ht,{newState:0,oldState:0}),Ip=et(Di),qd=[9,13,27,32],Xd=va&&"CompositionEvent"in window,sc=null;va&&"documentMode"in document&&(sc=document.documentMode);var Kd=va&&"TextEvent"in window&&!sc,Jf=va&&(!Xd||sc&&8<sc&&11>=sc),Bh=" ",Dc=!1;function Rc(T,w){switch(T){case"keyup":return qd.indexOf(w.keyCode)!==-1;case"keydown":return w.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Np(T){return T=T.detail,typeof T=="object"&&"data"in T?T.data:null}var Mc=!1;function nl(T,w){switch(T){case"compositionend":return Np(w);case"keypress":return w.which!==32?null:(Dc=!0,Bh);case"textInput":return T=w.data,T===Bh&&Dc?null:T;default:return null}}function jh(T,w){if(Mc)return T==="compositionend"||!Xd&&Rc(T,w)?(T=mn(),Qi=aa=il=null,Mc=!1,T):null;switch(T){case"paste":return null;case"keypress":if(!(w.ctrlKey||w.altKey||w.metaKey)||w.ctrlKey&&w.altKey){if(w.char&&1<w.char.length)return w.char;if(w.which)return String.fromCharCode(w.which)}return null;case"compositionend":return Jf&&w.locale!=="ko"?null:w.data;default:return null}}var Zd={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 Uu(T){var w=T&&T.nodeName&&T.nodeName.toLowerCase();return w==="input"?!!Zd[T.type]:w==="textarea"}function Vh(T,w,N,q){bl?nc?nc.push(q):nc=[q]:bl=q,w=y0(w,"onChange"),0<w.length&&(N=new Ft("onChange","change",null,N,q),T.push({event:N,listeners:w}))}var Jd=null,pu=null;function io(T){uM(T,0)}function gu(T){var w=zo(T);if(Ga(w))return T}function ns(T,w){if(T==="change")return w}var os=!1;if(va){var Hh;if(va){var Qf="oninput"in document;if(!Qf){var eh=document.createElement("div");eh.setAttribute("oninput","return;"),Qf=typeof eh.oninput=="function"}Hh=Qf}else Hh=!1;os=Hh&&(!document.documentMode||9<document.documentMode)}function Uh(){Jd&&(Jd.detachEvent("onpropertychange",zu),pu=Jd=null)}function zu(T){if(T.propertyName==="value"&&gu(pu)){var w=[];Vh(w,pu,T,ao(T)),xa(io,w)}}function th(T,w,N){T==="focusin"?(Uh(),Jd=w,pu=N,Jd.attachEvent("onpropertychange",zu)):T==="focusout"&&Uh()}function Ug(T){if(T==="selectionchange"||T==="keyup"||T==="keydown")return gu(pu)}function Qd(T,w){if(T==="click")return gu(w)}function Fp(T,w){if(T==="input"||T==="change")return gu(w)}function Lc(T,w){return T===w&&(T!==0||1/T===1/w)||T!==T&&w!==w}var Ke=typeof Object.is=="function"?Object.is:Lc;function le(T,w){if(Ke(T,w))return!0;if(typeof T!="object"||T===null||typeof w!="object"||w===null)return!1;var N=Object.keys(T),q=Object.keys(w);if(N.length!==q.length)return!1;for(q=0;q<N.length;q++){var ne=N[q];if(!pe.call(w,ne)||!Ke(T[ne],w[ne]))return!1}return!0}function Se(T){for(;T&&T.firstChild;)T=T.firstChild;return T}function be(T,w){var N=Se(T);T=0;for(var q;N;){if(N.nodeType===3){if(q=T+N.textContent.length,T<=w&&q>=w)return{node:N,offset:w-T};T=q}e:{for(;N;){if(N.nextSibling){N=N.nextSibling;break e}N=N.parentNode}N=void 0}N=Se(N)}}function xe(T,w){return T&&w?T===w?!0:T&&T.nodeType===3?!1:w&&w.nodeType===3?xe(T,w.parentNode):"contains"in T?T.contains(w):T.compareDocumentPosition?!!(T.compareDocumentPosition(w)&16):!1:!1}function Le(T){T=T!=null&&T.ownerDocument!=null&&T.ownerDocument.defaultView!=null?T.ownerDocument.defaultView:window;for(var w=ys(T.document);w instanceof T.HTMLIFrameElement;){try{var N=typeof w.contentWindow.location.href=="string"}catch{N=!1}if(N)T=w.contentWindow;else break;w=ys(T.document)}return w}function je(T){var w=T&&T.nodeName&&T.nodeName.toLowerCase();return w&&(w==="input"&&(T.type==="text"||T.type==="search"||T.type==="tel"||T.type==="url"||T.type==="password")||w==="textarea"||T.contentEditable==="true")}var ct=va&&"documentMode"in document&&11>=document.documentMode,ze=null,at=null,tt=null,pt=!1;function Ut(T,w,N){var q=N.window===N?N.document:N.nodeType===9?N:N.ownerDocument;pt||ze==null||ze!==ys(q)||(q=ze,"selectionStart"in q&&je(q)?q={start:q.selectionStart,end:q.selectionEnd}:(q=(q.ownerDocument&&q.ownerDocument.defaultView||window).getSelection(),q={anchorNode:q.anchorNode,anchorOffset:q.anchorOffset,focusNode:q.focusNode,focusOffset:q.focusOffset}),tt&&le(tt,q)||(tt=q,q=y0(at,"onSelect"),0<q.length&&(w=new Ft("onSelect","select",null,w,N),T.push({event:w,listeners:q}),w.target=ze)))}function vr(T,w){var N={};return N[T.toLowerCase()]=w.toLowerCase(),N["Webkit"+T]="webkit"+w,N["Moz"+T]="moz"+w,N}var Ir={animationend:vr("Animation","AnimationEnd"),animationiteration:vr("Animation","AnimationIteration"),animationstart:vr("Animation","AnimationStart"),transitionrun:vr("Transition","TransitionRun"),transitionstart:vr("Transition","TransitionStart"),transitioncancel:vr("Transition","TransitionCancel"),transitionend:vr("Transition","TransitionEnd")},Nt={},hr={};va&&(hr=document.createElement("div").style,"AnimationEvent"in window||(delete Ir.animationend.animation,delete Ir.animationiteration.animation,delete Ir.animationstart.animation),"TransitionEvent"in window||delete Ir.transitionend.transition);function Ao(T){if(Nt[T])return Nt[T];if(!Ir[T])return T;var w=Ir[T],N;for(N in w)if(w.hasOwnProperty(N)&&N in hr)return Nt[T]=w[N];return T}var ho=Ao("animationend"),$l=Ao("animationiteration"),rh=Ao("animationstart"),kc=Ao("transitionrun"),ef=Ao("transitionstart"),tf=Ao("transitioncancel"),Mn=Ao("transitionend"),ya=new Map,Po="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(" ");Po.push("scrollEnd");function po(T,w){ya.set(T,w),ts(w,[T])}var so=typeof reportError=="function"?reportError:function(T){if(typeof window=="object"&&typeof window.ErrorEvent=="function"){var w=new window.ErrorEvent("error",{bubbles:!0,cancelable:!0,message:typeof T=="object"&&T!==null&&typeof T.message=="string"?String(T.message):String(T),error:T});if(!window.dispatchEvent(w))return}else if(typeof process=="object"&&typeof process.emit=="function"){process.emit("uncaughtException",T);return}console.error(T)},_l=[],as=0,rf=0;function Or(){for(var T=as,w=rf=as=0;w<T;){var N=_l[w];_l[w++]=null;var q=_l[w];_l[w++]=null;var ne=_l[w];_l[w++]=null;var ue=_l[w];if(_l[w++]=null,q!==null&&ne!==null){var Ie=q.pending;Ie===null?ne.next=ne:(ne.next=Ie.next,Ie.next=ne),q.pending=ne}ue!==0&&zg(N,ne,ue)}}function nf(T,w,N,q){_l[as++]=T,_l[as++]=w,_l[as++]=N,_l[as++]=q,rf|=q,T.lanes|=q,T=T.alternate,T!==null&&(T.lanes|=q)}function Bp(T,w,N,q){return nf(T,w,N,q),zh(T)}function Rr(T,w){return nf(T,null,null,w),zh(T)}function zg(T,w,N){T.lanes|=N;var q=T.alternate;q!==null&&(q.lanes|=N);for(var ne=!1,ue=T.return;ue!==null;)ue.childLanes|=N,q=ue.alternate,q!==null&&(q.childLanes|=N),ue.tag===22&&(T=ue.stateNode,T===null||T._visibility&1||(ne=!0)),T=ue,ue=ue.return;return T.tag===3?(ue=T.stateNode,ne&&w!==null&&(ne=31-Ht(N),T=ue.hiddenUpdates,q=T[ne],q===null?T[ne]=[w]:q.push(w),w.lane=N|536870912),ue):null}function zh(T){if(50<c0)throw c0=0,HC=null,Error(n(185));for(var w=T.return;w!==null;)T=w,w=T.return;return T.tag===3?T.stateNode:null}var Ic={};function qv(T,w,N,q){this.tag=T,this.key=N,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=w,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=q,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function bs(T,w,N,q){return new qv(T,w,N,q)}function Nc(T){return T=T.prototype,!(!T||!T.isReactComponent)}function Wl(T,w){var N=T.alternate;return N===null?(N=bs(T.tag,w,T.key,T.mode),N.elementType=T.elementType,N.type=T.type,N.stateNode=T.stateNode,N.alternate=T,T.alternate=N):(N.pendingProps=w,N.type=T.type,N.flags=0,N.subtreeFlags=0,N.deletions=null),N.flags=T.flags&65011712,N.childLanes=T.childLanes,N.lanes=T.lanes,N.child=T.child,N.memoizedProps=T.memoizedProps,N.memoizedState=T.memoizedState,N.updateQueue=T.updateQueue,w=T.dependencies,N.dependencies=w===null?null:{lanes:w.lanes,firstContext:w.firstContext},N.sibling=T.sibling,N.index=T.index,N.ref=T.ref,N.refCleanup=T.refCleanup,N}function Tr(T,w){T.flags&=65011714;var N=T.alternate;return N===null?(T.childLanes=0,T.lanes=w,T.child=null,T.subtreeFlags=0,T.memoizedProps=null,T.memoizedState=null,T.updateQueue=null,T.dependencies=null,T.stateNode=null):(T.childLanes=N.childLanes,T.lanes=N.lanes,T.child=N.child,T.subtreeFlags=0,T.deletions=null,T.memoizedProps=N.memoizedProps,T.memoizedState=N.memoizedState,T.updateQueue=N.updateQueue,T.type=N.type,w=N.dependencies,T.dependencies=w===null?null:{lanes:w.lanes,firstContext:w.firstContext}),T}function Ln(T,w,N,q,ne,ue){var Ie=0;if(q=T,typeof T=="function")Nc(T)&&(Ie=1);else if(typeof T=="string")Ie=O2(T,N,Y.current)?26:T==="html"||T==="head"||T==="body"?27:5;else e:switch(T){case E:return T=bs(31,N,w,ne),T.elementType=E,T.lanes=ue,T;case g:return vd(N.children,ne,ue,w);case v:Ie=8,ne|=24;break;case y:return T=bs(12,N,w,ne|2),T.elementType=y,T.lanes=ue,T;case _:return T=bs(13,N,w,ne),T.elementType=_,T.lanes=ue,T;case C:return T=bs(19,N,w,ne),T.elementType=C,T.lanes=ue,T;default:if(typeof T=="object"&&T!==null)switch(T.$$typeof){case b:Ie=10;break e;case m:Ie=9;break e;case S:Ie=11;break e;case P:Ie=14;break e;case x:Ie=16,q=null;break e}Ie=29,N=Error(n(130,T===null?"null":typeof T,"")),q=null}return w=bs(Ie,N,w,ne),w.elementType=T,w.type=q,w.lanes=ue,w}function vd(T,w,N,q){return T=bs(7,T,q,w),T.lanes=N,T}function _r(T,w,N){return T=bs(6,T,null,w),T.lanes=N,T}function _n(T){var w=bs(18,null,null,0);return w.stateNode=T,w}function $h(T,w,N){return w=bs(4,T.children!==null?T.children:[],T.key,w),w.lanes=N,w.stateNode={containerInfo:T.containerInfo,pendingChildren:null,implementation:T.implementation},w}var Xv=new WeakMap;function Pl(T,w){if(typeof T=="object"&&T!==null){var N=Xv.get(T);return N!==void 0?N:(w={value:T,source:w,stack:ve(w)},Xv.set(T,w),w)}return{value:T,source:w,stack:ve(w)}}var ih=[],nh=0,ma=null,ja=0,Cl=[],vu=0,Gl=null,yu=1,mu="";function Ss(T,w){ih[nh++]=ja,ih[nh++]=ma,ma=T,ja=w}function jp(T,w,N){Cl[vu++]=yu,Cl[vu++]=mu,Cl[vu++]=Gl,Gl=T;var q=yu;T=mu;var ne=32-Ht(q)-1;q&=~(1<<ne),N+=1;var ue=32-Ht(w)+ne;if(30<ue){var Ie=ne-ne%5;ue=(q&(1<<Ie)-1).toString(32),q>>=Ie,ne-=Ie,yu=1<<32-Ht(w)+ne|N<<ne|q,mu=ue+T}else yu=1<<ue|N<<ne|q,mu=T}function yd(T){T.return!==null&&(Ss(T,1),jp(T,1,0))}function of(T){for(;T===ma;)ma=ih[--nh],ih[nh]=null,ja=ih[--nh],ih[nh]=null;for(;T===Gl;)Gl=Cl[--vu],Cl[vu]=null,mu=Cl[--vu],Cl[vu]=null,yu=Cl[--vu],Cl[vu]=null}function oh(T,w){Cl[vu++]=yu,Cl[vu++]=mu,Cl[vu++]=Gl,yu=w.id,mu=w.overflow,Gl=T}var Va=null,lo=null,kn=!1,md=null,bu=!1,$g=Error(n(519));function bd(T){var w=Error(n(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?"text":"HTML",""));throw _d(Pl(w,T)),$g}function Wh(T){var w=T.stateNode,N=T.type,q=T.memoizedProps;switch(w[mt]=T,w[gr]=q,N){case"dialog":zn("cancel",w),zn("close",w);break;case"iframe":case"object":case"embed":zn("load",w);break;case"video":case"audio":for(N=0;N<v0.length;N++)zn(v0[N],w);break;case"source":zn("error",w);break;case"img":case"image":case"link":zn("error",w),zn("load",w);break;case"details":zn("toggle",w);break;case"input":zn("invalid",w),Hl(w,q.value,q.defaultValue,q.checked,q.defaultChecked,q.type,q.name,!0);break;case"select":zn("invalid",w);break;case"textarea":zn("invalid",w),rl(w,q.value,q.defaultValue,q.children)}N=q.children,typeof N!="string"&&typeof N!="number"&&typeof N!="bigint"||w.textContent===""+N||q.suppressHydrationWarning===!0||fM(w.textContent,N)?(q.popover!=null&&(zn("beforetoggle",w),zn("toggle",w)),q.onScroll!=null&&zn("scroll",w),q.onScrollEnd!=null&&zn("scrollend",w),q.onClick!=null&&(w.onclick=Ta),w=!0):w=!1,w||bd(T,!0)}function ah(T){for(Va=T.return;Va;)switch(Va.tag){case 5:case 31:case 13:bu=!1;return;case 27:case 3:bu=!0;return;default:Va=Va.return}}function af(T){if(T!==Va)return!1;if(!kn)return ah(T),kn=!0,!1;var w=T.tag,N;if((N=w!==3&&w!==27)&&((N=w===5)&&(N=T.type,N=!(N!=="form"&&N!=="button")||ag(T.type,T.memoizedProps)),N=!N),N&&lo&&bd(T),ah(T),w===13){if(T=T.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(n(317));lo=yM(T)}else if(w===31){if(T=T.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(n(317));lo=yM(T)}else w===27?(w=lo,Wi(T.type)?(T=sT,sT=null,lo=T):lo=w):lo=Va?Ad(T.stateNode.nextSibling):null;return!0}function nt(){lo=Va=null,kn=!1}function Sd(){var T=md;return T!==null&&(gc===null?gc=T:gc.push.apply(gc,T),md=null),T}function _d(T){md===null?md=[T]:md.push(T)}var Tl=k(null),nn=null,Fc=null;function Pd(T,w,N){W(Tl,w._currentValue),w._currentValue=N}function Bc(T){T._currentValue=Tl.current,X(Tl)}function jc(T,w,N){for(;T!==null;){var q=T.alternate;if((T.childLanes&w)!==w?(T.childLanes|=w,q!==null&&(q.childLanes|=w)):q!==null&&(q.childLanes&w)!==w&&(q.childLanes|=w),T===N)break;T=T.return}}function Wg(T,w,N,q){var ne=T.child;for(ne!==null&&(ne.return=T);ne!==null;){var ue=ne.dependencies;if(ue!==null){var Ie=ne.child;ue=ue.firstContext;e:for(;ue!==null;){var ot=ue;ue=ne;for(var Et=0;Et<w.length;Et++)if(ot.context===w[Et]){ue.lanes|=N,ot=ue.alternate,ot!==null&&(ot.lanes|=N),jc(ue.return,N,T),q||(Ie=null);break e}ue=ot.next}}else if(ne.tag===18){if(Ie=ne.return,Ie===null)throw Error(n(341));Ie.lanes|=N,ue=Ie.alternate,ue!==null&&(ue.lanes|=N),jc(Ie,N,T),Ie=null}else Ie=ne.child;if(Ie!==null)Ie.return=ne;else for(Ie=ne;Ie!==null;){if(Ie===T){Ie=null;break}if(ne=Ie.sibling,ne!==null){ne.return=Ie.return,Ie=ne;break}Ie=Ie.return}ne=Ie}}function sh(T,w,N,q){T=null;for(var ne=w,ue=!1;ne!==null;){if(!ue){if((ne.flags&524288)!==0)ue=!0;else if((ne.flags&262144)!==0)break}if(ne.tag===10){var Ie=ne.alternate;if(Ie===null)throw Error(n(387));if(Ie=Ie.memoizedProps,Ie!==null){var ot=ne.type;Ke(ne.pendingProps.value,Ie.value)||(T!==null?T.push(ot):T=[ot])}}else if(ne===de.current){if(Ie=ne.alternate,Ie===null)throw Error(n(387));Ie.memoizedState.memoizedState!==ne.memoizedState.memoizedState&&(T!==null?T.push(Sy):T=[Sy])}ne=ne.return}T!==null&&Wg(w,T,N,q),w.flags|=262144}function Vp(T){for(T=T.firstContext;T!==null;){if(!Ke(T.context._currentValue,T.memoizedValue))return!0;T=T.next}return!1}function sf(T){nn=T,Fc=null,T=T.dependencies,T!==null&&(T.firstContext=null)}function _s(T){return Kv(nn,T)}function Su(T,w){return nn===null&&sf(T),Kv(T,w)}function Kv(T,w){var N=w._currentValue;if(w={context:w,memoizedValue:N,next:null},Fc===null){if(T===null)throw Error(n(308));Fc=w,T.dependencies={lanes:0,firstContext:w},T.flags|=524288}else Fc=Fc.next=w;return N}var Fm=typeof AbortController<"u"?AbortController:function(){var T=[],w=this.signal={aborted:!1,addEventListener:function(N,q){T.push(q)}};this.abort=function(){w.aborted=!0,T.forEach(function(N){return N()})}},Bm=t.unstable_scheduleCallback,jm=t.unstable_NormalPriority,Ha={$$typeof:b,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function $u(){return{controller:new Fm,data:new Map,refCount:0}}function Gh(T){T.refCount--,T.refCount===0&&Bm(jm,function(){T.controller.abort()})}var Yh=null,Gg=0,lh=0,uh=null;function lf(T,w){if(Yh===null){var N=Yh=[];Gg=0,lh=Xc(),uh={status:"pending",value:void 0,then:function(q){N.push(q)}}}return Gg++,w.then(Zv,Zv),w}function Zv(){if(--Gg===0&&Yh!==null){uh!==null&&(uh.status="fulfilled");var T=Yh;Yh=null,lh=0,uh=null;for(var w=0;w<T.length;w++)(0,T[w])()}}function Vm(T,w){var N=[],q={status:"pending",value:null,reason:null,then:function(ne){N.push(ne)}};return T.then(function(){q.status="fulfilled",q.value=w;for(var ne=0;ne<N.length;ne++)(0,N[ne])(w)},function(ne){for(q.status="rejected",q.reason=ne,ne=0;ne<N.length;ne++)(0,N[ne])(void 0)}),q}var _u=V.S;V.S=function(T,w){WR=Qe(),typeof w=="object"&&w!==null&&typeof w.then=="function"&&lf(T,w),_u!==null&&_u(T,w)};var uf=k(null);function Yg(){var T=uf.current;return T!==null?T:ua.pooledCache}function Hp(T,w){w===null?W(uf,uf.current):W(uf,w.pool)}function Jv(){var T=Yg();return T===null?null:{parent:Ha._currentValue,pool:T}}var ch=Error(n(460)),Up=Error(n(474)),qh=Error(n(542)),Xh={then:function(){}};function Qv(T){return T=T.status,T==="fulfilled"||T==="rejected"}function zp(T,w,N){switch(N=T[N],N===void 0?T.push(w):N!==w&&(w.then(Ta,Ta),w=N),w.status){case"fulfilled":return w.value;case"rejected":throw T=w.reason,qg(T),T;default:if(typeof w.status=="string")w.then(Ta,Ta);else{if(T=ua,T!==null&&100<T.shellSuspendCounter)throw Error(n(482));T=w,T.status="pending",T.then(function(q){if(w.status==="pending"){var ne=w;ne.status="fulfilled",ne.value=q}},function(q){if(w.status==="pending"){var ne=w;ne.status="rejected",ne.reason=q}})}switch(w.status){case"fulfilled":return w.value;case"rejected":throw T=w.reason,qg(T),T}throw lc=w,ch}}function Pu(T){try{var w=T._init;return w(T._payload)}catch(N){throw N!==null&&typeof N=="object"&&typeof N.then=="function"?(lc=N,ch):N}}var lc=null;function ey(){if(lc===null)throw Error(n(459));var T=lc;return lc=null,T}function qg(T){if(T===ch||T===qh)throw Error(n(483))}var Vc=null,Yl=0;function dh(T){var w=Yl;return Yl+=1,Vc===null&&(Vc=[]),zp(Vc,T,w)}function xl(T,w){w=w.props.ref,T.ref=w!==void 0?w:null}function Vs(T,w){throw w.$$typeof===f?Error(n(525)):(T=Object.prototype.toString.call(w),Error(n(31,T==="[object Object]"?"object with keys {"+Object.keys(w).join(", ")+"}":T)))}function ty(T){function w(Wt,It){if(T){var Qt=Wt.deletions;Qt===null?(Wt.deletions=[It],Wt.flags|=16):Qt.push(It)}}function N(Wt,It){if(!T)return null;for(;It!==null;)w(Wt,It),It=It.sibling;return null}function q(Wt){for(var It=new Map;Wt!==null;)Wt.key!==null?It.set(Wt.key,Wt):It.set(Wt.index,Wt),Wt=Wt.sibling;return It}function ne(Wt,It){return Wt=Wl(Wt,It),Wt.index=0,Wt.sibling=null,Wt}function ue(Wt,It,Qt){return Wt.index=Qt,T?(Qt=Wt.alternate,Qt!==null?(Qt=Qt.index,Qt<It?(Wt.flags|=67108866,It):Qt):(Wt.flags|=67108866,It)):(Wt.flags|=1048576,It)}function Ie(Wt){return T&&Wt.alternate===null&&(Wt.flags|=67108866),Wt}function ot(Wt,It,Qt,Sr){return It===null||It.tag!==6?(It=_r(Qt,Wt.mode,Sr),It.return=Wt,It):(It=ne(It,Qt),It.return=Wt,It)}function Et(Wt,It,Qt,Sr){var wi=Qt.type;return wi===g?yr(Wt,It,Qt.props.children,Sr,Qt.key):It!==null&&(It.elementType===wi||typeof wi=="object"&&wi!==null&&wi.$$typeof===x&&Pu(wi)===It.type)?(It=ne(It,Qt.props),xl(It,Qt),It.return=Wt,It):(It=Ln(Qt.type,Qt.key,Qt.props,null,Wt.mode,Sr),xl(It,Qt),It.return=Wt,It)}function tr(Wt,It,Qt,Sr){return It===null||It.tag!==4||It.stateNode.containerInfo!==Qt.containerInfo||It.stateNode.implementation!==Qt.implementation?(It=$h(Qt,Wt.mode,Sr),It.return=Wt,It):(It=ne(It,Qt.children||[]),It.return=Wt,It)}function yr(Wt,It,Qt,Sr,wi){return It===null||It.tag!==7?(It=vd(Qt,Wt.mode,Sr,wi),It.return=Wt,It):(It=ne(It,Qt),It.return=Wt,It)}function Pr(Wt,It,Qt){if(typeof It=="string"&&It!==""||typeof It=="number"||typeof It=="bigint")return It=_r(""+It,Wt.mode,Qt),It.return=Wt,It;if(typeof It=="object"&&It!==null){switch(It.$$typeof){case h:return Qt=Ln(It.type,It.key,It.props,null,Wt.mode,Qt),xl(Qt,It),Qt.return=Wt,Qt;case p:return It=$h(It,Wt.mode,Qt),It.return=Wt,It;case x:return It=Pu(It),Pr(Wt,It,Qt)}if(I(It)||M(It))return It=vd(It,Wt.mode,Qt,null),It.return=Wt,It;if(typeof It.then=="function")return Pr(Wt,dh(It),Qt);if(It.$$typeof===b)return Pr(Wt,Su(Wt,It),Qt);Vs(Wt,It)}return null}function ir(Wt,It,Qt,Sr){var wi=It!==null?It.key:null;if(typeof Qt=="string"&&Qt!==""||typeof Qt=="number"||typeof Qt=="bigint")return wi!==null?null:ot(Wt,It,""+Qt,Sr);if(typeof Qt=="object"&&Qt!==null){switch(Qt.$$typeof){case h:return Qt.key===wi?Et(Wt,It,Qt,Sr):null;case p:return Qt.key===wi?tr(Wt,It,Qt,Sr):null;case x:return Qt=Pu(Qt),ir(Wt,It,Qt,Sr)}if(I(Qt)||M(Qt))return wi!==null?null:yr(Wt,It,Qt,Sr,null);if(typeof Qt.then=="function")return ir(Wt,It,dh(Qt),Sr);if(Qt.$$typeof===b)return ir(Wt,It,Su(Wt,Qt),Sr);Vs(Wt,Qt)}return null}function ar(Wt,It,Qt,Sr,wi){if(typeof Sr=="string"&&Sr!==""||typeof Sr=="number"||typeof Sr=="bigint")return Wt=Wt.get(Qt)||null,ot(It,Wt,""+Sr,wi);if(typeof Sr=="object"&&Sr!==null){switch(Sr.$$typeof){case h:return Wt=Wt.get(Sr.key===null?Qt:Sr.key)||null,Et(It,Wt,Sr,wi);case p:return Wt=Wt.get(Sr.key===null?Qt:Sr.key)||null,tr(It,Wt,Sr,wi);case x:return Sr=Pu(Sr),ar(Wt,It,Qt,Sr,wi)}if(I(Sr)||M(Sr))return Wt=Wt.get(Qt)||null,yr(It,Wt,Sr,wi,null);if(typeof Sr.then=="function")return ar(Wt,It,Qt,dh(Sr),wi);if(Sr.$$typeof===b)return ar(Wt,It,Qt,Su(It,Sr),wi);Vs(It,Sr)}return null}function li(Wt,It,Qt,Sr){for(var wi=null,Co=null,gi=It,Pn=It=0,Kn=null;gi!==null&&Pn<Qt.length;Pn++){gi.index>Pn?(Kn=gi,gi=null):Kn=gi.sibling;var To=ir(Wt,gi,Qt[Pn],Sr);if(To===null){gi===null&&(gi=Kn);break}T&&gi&&To.alternate===null&&w(Wt,gi),It=ue(To,It,Pn),Co===null?wi=To:Co.sibling=To,Co=To,gi=Kn}if(Pn===Qt.length)return N(Wt,gi),kn&&Ss(Wt,Pn),wi;if(gi===null){for(;Pn<Qt.length;Pn++)gi=Pr(Wt,Qt[Pn],Sr),gi!==null&&(It=ue(gi,It,Pn),Co===null?wi=gi:Co.sibling=gi,Co=gi);return kn&&Ss(Wt,Pn),wi}for(gi=q(gi);Pn<Qt.length;Pn++)Kn=ar(gi,Wt,Pn,Qt[Pn],Sr),Kn!==null&&(T&&Kn.alternate!==null&&gi.delete(Kn.key===null?Pn:Kn.key),It=ue(Kn,It,Pn),Co===null?wi=Kn:Co.sibling=Kn,Co=Kn);return T&&gi.forEach(function(fg){return w(Wt,fg)}),kn&&Ss(Wt,Pn),wi}function Ii(Wt,It,Qt,Sr){if(Qt==null)throw Error(n(151));for(var wi=null,Co=null,gi=It,Pn=It=0,Kn=null,To=Qt.next();gi!==null&&!To.done;Pn++,To=Qt.next()){gi.index>Pn?(Kn=gi,gi=null):Kn=gi.sibling;var fg=ir(Wt,gi,To.value,Sr);if(fg===null){gi===null&&(gi=Kn);break}T&&gi&&fg.alternate===null&&w(Wt,gi),It=ue(fg,It,Pn),Co===null?wi=fg:Co.sibling=fg,Co=fg,gi=Kn}if(To.done)return N(Wt,gi),kn&&Ss(Wt,Pn),wi;if(gi===null){for(;!To.done;Pn++,To=Qt.next())To=Pr(Wt,To.value,Sr),To!==null&&(It=ue(To,It,Pn),Co===null?wi=To:Co.sibling=To,Co=To);return kn&&Ss(Wt,Pn),wi}for(gi=q(gi);!To.done;Pn++,To=Qt.next())To=ar(gi,Wt,Pn,To.value,Sr),To!==null&&(T&&To.alternate!==null&&gi.delete(To.key===null?Pn:To.key),It=ue(To,It,Pn),Co===null?wi=To:Co.sibling=To,Co=To);return T&&gi.forEach(function(F2){return w(Wt,F2)}),kn&&Ss(Wt,Pn),wi}function Jo(Wt,It,Qt,Sr){if(typeof Qt=="object"&&Qt!==null&&Qt.type===g&&Qt.key===null&&(Qt=Qt.props.children),typeof Qt=="object"&&Qt!==null){switch(Qt.$$typeof){case h:e:{for(var wi=Qt.key;It!==null;){if(It.key===wi){if(wi=Qt.type,wi===g){if(It.tag===7){N(Wt,It.sibling),Sr=ne(It,Qt.props.children),Sr.return=Wt,Wt=Sr;break e}}else if(It.elementType===wi||typeof wi=="object"&&wi!==null&&wi.$$typeof===x&&Pu(wi)===It.type){N(Wt,It.sibling),Sr=ne(It,Qt.props),xl(Sr,Qt),Sr.return=Wt,Wt=Sr;break e}N(Wt,It);break}else w(Wt,It);It=It.sibling}Qt.type===g?(Sr=vd(Qt.props.children,Wt.mode,Sr,Qt.key),Sr.return=Wt,Wt=Sr):(Sr=Ln(Qt.type,Qt.key,Qt.props,null,Wt.mode,Sr),xl(Sr,Qt),Sr.return=Wt,Wt=Sr)}return Ie(Wt);case p:e:{for(wi=Qt.key;It!==null;){if(It.key===wi)if(It.tag===4&&It.stateNode.containerInfo===Qt.containerInfo&&It.stateNode.implementation===Qt.implementation){N(Wt,It.sibling),Sr=ne(It,Qt.children||[]),Sr.return=Wt,Wt=Sr;break e}else{N(Wt,It);break}else w(Wt,It);It=It.sibling}Sr=$h(Qt,Wt.mode,Sr),Sr.return=Wt,Wt=Sr}return Ie(Wt);case x:return Qt=Pu(Qt),Jo(Wt,It,Qt,Sr)}if(I(Qt))return li(Wt,It,Qt,Sr);if(M(Qt)){if(wi=M(Qt),typeof wi!="function")throw Error(n(150));return Qt=wi.call(Qt),Ii(Wt,It,Qt,Sr)}if(typeof Qt.then=="function")return Jo(Wt,It,dh(Qt),Sr);if(Qt.$$typeof===b)return Jo(Wt,It,Su(Wt,Qt),Sr);Vs(Wt,Qt)}return typeof Qt=="string"&&Qt!==""||typeof Qt=="number"||typeof Qt=="bigint"?(Qt=""+Qt,It!==null&&It.tag===6?(N(Wt,It.sibling),Sr=ne(It,Qt),Sr.return=Wt,Wt=Sr):(N(Wt,It),Sr=_r(Qt,Wt.mode,Sr),Sr.return=Wt,Wt=Sr),Ie(Wt)):N(Wt,It)}return function(Wt,It,Qt,Sr){try{Yl=0;var wi=Jo(Wt,It,Qt,Sr);return Vc=null,wi}catch(gi){if(gi===ch||gi===qh)throw gi;var Co=bs(29,gi,null,Wt.mode);return Co.lanes=Sr,Co.return=Wt,Co}finally{}}}var Cd=ty(!0),$p=ty(!1),Cu=!1;function uc(T){T.updateQueue={baseState:T.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function Wp(T,w){T=T.updateQueue,w.updateQueue===T&&(w.updateQueue={baseState:T.baseState,firstBaseUpdate:T.firstBaseUpdate,lastBaseUpdate:T.lastBaseUpdate,shared:T.shared,callbacks:null})}function Td(T){return{lane:T,tag:0,payload:null,callback:null,next:null}}function Tu(T,w,N){var q=T.updateQueue;if(q===null)return null;if(q=q.shared,(Oo&2)!==0){var ne=q.pending;return ne===null?w.next=w:(w.next=ne.next,ne.next=w),q.pending=w,w=zh(T),zg(T,null,N),w}return nf(T,q,w,N),zh(T)}function fh(T,w,N){if(w=w.updateQueue,w!==null&&(w=w.shared,(N&4194048)!==0)){var q=w.lanes;q&=T.pendingLanes,N|=q,w.lanes=N,vi(T,N)}}function Gp(T,w){var N=T.updateQueue,q=T.alternate;if(q!==null&&(q=q.updateQueue,N===q)){var ne=null,ue=null;if(N=N.firstBaseUpdate,N!==null){do{var Ie={lane:N.lane,tag:N.tag,payload:N.payload,callback:null,next:null};ue===null?ne=ue=Ie:ue=ue.next=Ie,N=N.next}while(N!==null);ue===null?ne=ue=w:ue=ue.next=w}else ne=ue=w;N={baseState:q.baseState,firstBaseUpdate:ne,lastBaseUpdate:ue,shared:q.shared,callbacks:q.callbacks},T.updateQueue=N;return}T=N.lastBaseUpdate,T===null?N.firstBaseUpdate=w:T.next=w,N.lastBaseUpdate=w}var Ua=!1;function xd(){if(Ua){var T=uh;if(T!==null)throw T}}function hh(T,w,N,q){Ua=!1;var ne=T.updateQueue;Cu=!1;var ue=ne.firstBaseUpdate,Ie=ne.lastBaseUpdate,ot=ne.shared.pending;if(ot!==null){ne.shared.pending=null;var Et=ot,tr=Et.next;Et.next=null,Ie===null?ue=tr:Ie.next=tr,Ie=Et;var yr=T.alternate;yr!==null&&(yr=yr.updateQueue,ot=yr.lastBaseUpdate,ot!==Ie&&(ot===null?yr.firstBaseUpdate=tr:ot.next=tr,yr.lastBaseUpdate=Et))}if(ue!==null){var Pr=ne.baseState;Ie=0,yr=tr=Et=null,ot=ue;do{var ir=ot.lane&-536870913,ar=ir!==ot.lane;if(ar?(Xn&ir)===ir:(q&ir)===ir){ir!==0&&ir===lh&&(Ua=!0),yr!==null&&(yr=yr.next={lane:0,tag:ot.tag,payload:ot.payload,callback:null,next:null});e:{var li=T,Ii=ot;ir=w;var Jo=N;switch(Ii.tag){case 1:if(li=Ii.payload,typeof li=="function"){Pr=li.call(Jo,Pr,ir);break e}Pr=li;break e;case 3:li.flags=li.flags&-65537|128;case 0:if(li=Ii.payload,ir=typeof li=="function"?li.call(Jo,Pr,ir):li,ir==null)break e;Pr=d({},Pr,ir);break e;case 2:Cu=!0}}ir=ot.callback,ir!==null&&(T.flags|=64,ar&&(T.flags|=8192),ar=ne.callbacks,ar===null?ne.callbacks=[ir]:ar.push(ir))}else ar={lane:ir,tag:ot.tag,payload:ot.payload,callback:ot.callback,next:null},yr===null?(tr=yr=ar,Et=Pr):yr=yr.next=ar,Ie|=ir;if(ot=ot.next,ot===null){if(ot=ne.shared.pending,ot===null)break;ar=ot,ot=ar.next,ar.next=null,ne.lastBaseUpdate=ar,ne.shared.pending=null}}while(!0);yr===null&&(Et=Pr),ne.baseState=Et,ne.firstBaseUpdate=tr,ne.lastBaseUpdate=yr,ue===null&&(ne.shared.lanes=0),tg|=Ie,T.lanes=Ie,T.memoizedState=Pr}}function Wu(T,w){if(typeof T!="function")throw Error(n(191,T));T.call(w)}function Yp(T,w){var N=T.callbacks;if(N!==null)for(T.callbacks=null,T=0;T<N.length;T++)Wu(N[T],w)}var Hc=k(null),cc=k(0);function Xg(T,w){T=gf,W(cc,T),W(Hc,w),gf=T|w.baseLanes}function Ps(){W(cc,gf),W(Hc,Hc.current)}function Kh(){gf=cc.current,X(Hc),X(cc)}var ql=k(null),El=null;function Uc(T){var w=T.alternate;W(Ea,Ea.current&1),W(ql,T),El===null&&(w===null||Hc.current!==null||w.memoizedState!==null)&&(El=T)}function ph(T){W(Ea,Ea.current),W(ql,T),El===null&&(El=T)}function qp(T){T.tag===22?(W(Ea,Ea.current),W(ql,T),El===null&&(El=T)):wl()}function wl(){W(Ea,Ea.current),W(ql,ql.current)}function ol(T){X(ql),El===T&&(El=null),X(Ea)}var Ea=k(0);function Io(T){for(var w=T;w!==null;){if(w.tag===13){var N=w.memoizedState;if(N!==null&&(N=N.dehydrated,N===null||C_(N)||py(N)))return w}else if(w.tag===19&&(w.memoizedProps.revealOrder==="forwards"||w.memoizedProps.revealOrder==="backwards"||w.memoizedProps.revealOrder==="unstable_legacy-backwards"||w.memoizedProps.revealOrder==="together")){if((w.flags&128)!==0)return w}else if(w.child!==null){w.child.return=w,w=w.child;continue}if(w===T)break;for(;w.sibling===null;){if(w.return===null||w.return===T)return null;w=w.return}w.sibling.return=w.return,w=w.sibling}return null}var Al=0,xi=null,yi=null,Xo=null,Cs=!1,Ol=!1,zc=!1,Ed=0,cf=0,$c=null,ry=0;function Ko(){throw Error(n(321))}function df(T,w){if(w===null)return!1;for(var N=0;N<w.length&&N<T.length;N++)if(!Ke(T[N],w[N]))return!1;return!0}function Zh(T,w,N,q,ne,ue){return Al=ue,xi=w,w.memoizedState=null,w.updateQueue=null,w.lanes=0,V.H=T===null||T.memoizedState===null?CR:JS,zc=!1,ue=N(q,ne),zc=!1,Ol&&(ue=Wc(w,N,q,ne)),Xp(T),ue}function Xp(T){V.H=Zp;var w=yi!==null&&yi.next!==null;if(Al=0,Xo=yi=xi=null,Cs=!1,cf=0,$c=null,w)throw Error(n(300));T===null||Xa||(T=T.dependencies,T!==null&&Vp(T)&&(Xa=!0))}function Wc(T,w,N,q){xi=T;var ne=0;do{if(Ol&&($c=null),cf=0,Ol=!1,25<=ne)throw Error(n(301));if(ne+=1,Xo=yi=null,T.updateQueue!=null){var ue=T.updateQueue;ue.lastEffect=null,ue.events=null,ue.stores=null,ue.memoCache!=null&&(ue.memoCache.index=0)}V.H=Gm,ue=w(N,q)}while(Ol);return ue}function $(){var T=V.H,w=T.useState()[0];return w=typeof w.then=="function"?he(w):w,T=T.useState()[0],(yi!==null?yi.memoizedState:null)!==T&&(xi.flags|=1024),w}function ee(){var T=Ed!==0;return Ed=0,T}function ae(T,w,N){w.updateQueue=T.updateQueue,w.flags&=-2053,T.lanes&=~N}function O(T){if(Cs){for(T=T.memoizedState;T!==null;){var w=T.queue;w!==null&&(w.pending=null),T=T.next}Cs=!1}Al=0,Xo=yi=xi=null,Ol=!1,cf=Ed=0,$c=null}function j(){var T={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Xo===null?xi.memoizedState=Xo=T:Xo=Xo.next=T,Xo}function Q(){if(yi===null){var T=xi.alternate;T=T!==null?T.memoizedState:null}else T=yi.next;var w=Xo===null?xi.memoizedState:Xo.next;if(w!==null)Xo=w,yi=T;else{if(T===null)throw xi.alternate===null?Error(n(467)):Error(n(310));yi=T,T={memoizedState:yi.memoizedState,baseState:yi.baseState,baseQueue:yi.baseQueue,queue:yi.queue,next:null},Xo===null?xi.memoizedState=Xo=T:Xo=Xo.next=T}return Xo}function ie(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function he(T){var w=cf;return cf+=1,$c===null&&($c=[]),T=zp($c,T,w),w=xi,(Xo===null?w.memoizedState:Xo.next)===null&&(w=w.alternate,V.H=w===null||w.memoizedState===null?CR:JS),T}function Oe(T){if(T!==null&&typeof T=="object"){if(typeof T.then=="function")return he(T);if(T.$$typeof===b)return _s(T)}throw Error(n(438,String(T)))}function Fe(T){var w=null,N=xi.updateQueue;if(N!==null&&(w=N.memoCache),w==null){var q=xi.alternate;q!==null&&(q=q.updateQueue,q!==null&&(q=q.memoCache,q!=null&&(w={data:q.data.map(function(ne){return ne.slice()}),index:0})))}if(w==null&&(w={data:[],index:0}),N===null&&(N=ie(),xi.updateQueue=N),N.memoCache=w,N=w.data[w.index],N===void 0)for(N=w.data[w.index]=Array(T),q=0;q<T;q++)N[q]=A;return w.index++,N}function Ge(T,w){return typeof w=="function"?w(T):w}function lt(T){var w=Q();return Ot(w,yi,T)}function Ot(T,w,N){var q=T.queue;if(q===null)throw Error(n(311));q.lastRenderedReducer=N;var ne=T.baseQueue,ue=q.pending;if(ue!==null){if(ne!==null){var Ie=ne.next;ne.next=ue.next,ue.next=Ie}w.baseQueue=ne=ue,q.pending=null}if(ue=T.baseState,ne===null)T.memoizedState=ue;else{w=ne.next;var ot=Ie=null,Et=null,tr=w,yr=!1;do{var Pr=tr.lane&-536870913;if(Pr!==tr.lane?(Xn&Pr)===Pr:(Al&Pr)===Pr){var ir=tr.revertLane;if(ir===0)Et!==null&&(Et=Et.next={lane:0,revertLane:0,gesture:null,action:tr.action,hasEagerState:tr.hasEagerState,eagerState:tr.eagerState,next:null}),Pr===lh&&(yr=!0);else if((Al&ir)===ir){tr=tr.next,ir===lh&&(yr=!0);continue}else Pr={lane:0,revertLane:tr.revertLane,gesture:null,action:tr.action,hasEagerState:tr.hasEagerState,eagerState:tr.eagerState,next:null},Et===null?(ot=Et=Pr,Ie=ue):Et=Et.next=Pr,xi.lanes|=ir,tg|=ir;Pr=tr.action,zc&&N(ue,Pr),ue=tr.hasEagerState?tr.eagerState:N(ue,Pr)}else ir={lane:Pr,revertLane:tr.revertLane,gesture:tr.gesture,action:tr.action,hasEagerState:tr.hasEagerState,eagerState:tr.eagerState,next:null},Et===null?(ot=Et=ir,Ie=ue):Et=Et.next=ir,xi.lanes|=Pr,tg|=Pr;tr=tr.next}while(tr!==null&&tr!==w);if(Et===null?Ie=ue:Et.next=ot,!Ke(ue,T.memoizedState)&&(Xa=!0,yr&&(N=uh,N!==null)))throw N;T.memoizedState=ue,T.baseState=Ie,T.baseQueue=Et,q.lastRenderedState=ue}return ne===null&&(q.lanes=0),[T.memoizedState,q.dispatch]}function St(T){var w=Q(),N=w.queue;if(N===null)throw Error(n(311));N.lastRenderedReducer=T;var q=N.dispatch,ne=N.pending,ue=w.memoizedState;if(ne!==null){N.pending=null;var Ie=ne=ne.next;do ue=T(ue,Ie.action),Ie=Ie.next;while(Ie!==ne);Ke(ue,w.memoizedState)||(Xa=!0),w.memoizedState=ue,w.baseQueue===null&&(w.baseState=ue),N.lastRenderedState=ue}return[ue,q]}function jt(T,w,N){var q=xi,ne=Q(),ue=kn;if(ue){if(N===void 0)throw Error(n(407));N=N()}else N=w();var Ie=!Ke((yi||ne).memoizedState,N);if(Ie&&(ne.memoizedState=N,Xa=!0),ne=ne.queue,Um(mr.bind(null,q,ne,T),[T]),ne.getSnapshot!==w||Ie||Xo!==null&&Xo.memoizedState.tag&1){if(q.flags|=2048,In(9,{destroy:void 0},or.bind(null,q,ne,N,w),null),ua===null)throw Error(n(349));ue||(Al&127)!==0||cr(q,w,N)}return N}function cr(T,w,N){T.flags|=16384,T={getSnapshot:w,value:N},w=xi.updateQueue,w===null?(w=ie(),xi.updateQueue=w,w.stores=[T]):(N=w.stores,N===null?w.stores=[T]:N.push(T))}function or(T,w,N,q){w.value=N,w.getSnapshot=q,Vr(w)&&ei(T)}function mr(T,w,N){return N(function(){Vr(w)&&ei(T)})}function Vr(T){var w=T.getSnapshot;T=T.value;try{var N=w();return!Ke(T,N)}catch{return!0}}function ei(T){var w=Rr(T,2);w!==null&&vc(w,T,2)}function ui(T){var w=j();if(typeof T=="function"){var N=T;if(T=N(),zc){_t(!0);try{N()}finally{_t(!1)}}}return w.memoizedState=w.baseState=T,w.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ge,lastRenderedState:T},w}function Ei(T,w,N,q){return T.baseState=N,Ot(T,yi,typeof q=="function"?q:Ge)}function jr(T,w,N,q,ne){if($m(T))throw Error(n(485));if(T=w.action,T!==null){var ue={payload:ne,action:T,next:null,isTransition:!0,status:"pending",value:null,reason:null,listeners:[],then:function(Ie){ue.listeners.push(Ie)}};V.T!==null?N(!0):ue.isTransition=!1,q(ue),N=w.pending,N===null?(ue.next=w.pending=ue,cn(w,ue)):(ue.next=N.next,w.pending=N.next=ue)}}function cn(T,w){var N=w.action,q=w.payload,ne=T.state;if(w.isTransition){var ue=V.T,Ie={};V.T=Ie;try{var ot=N(ne,q),Et=V.S;Et!==null&&Et(Ie,ot),ji(T,w,ot)}catch(tr){Ai(T,w,tr)}finally{ue!==null&&Ie.types!==null&&(ue.types=Ie.types),V.T=ue}}else try{ue=N(ne,q),ji(T,w,ue)}catch(tr){Ai(T,w,tr)}}function ji(T,w,N){N!==null&&typeof N=="object"&&typeof N.then=="function"?N.then(function(q){Kr(T,w,q)},function(q){return Ai(T,w,q)}):Kr(T,w,N)}function Kr(T,w,N){w.status="fulfilled",w.value=N,qa(w),T.state=N,w=T.pending,w!==null&&(N=w.next,N===w?T.pending=null:(N=N.next,w.next=N,cn(T,N)))}function Ai(T,w,N){var q=T.pending;if(T.pending=null,q!==null){q=q.next;do w.status="rejected",w.reason=N,qa(w),w=w.next;while(w!==q)}T.action=null}function qa(T){T=T.listeners;for(var w=0;w<T.length;w++)(0,T[w])()}function sa(T,w){return w}function No(T,w){if(kn){var N=ua.formState;if(N!==null){e:{var q=xi;if(kn){if(lo){t:{for(var ne=lo,ue=bu;ne.nodeType!==8;){if(!ue){ne=null;break t}if(ne=Ad(ne.nextSibling),ne===null){ne=null;break t}}ue=ne.data,ne=ue==="F!"||ue==="F"?ne:null}if(ne){lo=Ad(ne.nextSibling),q=ne.data==="F!";break e}}bd(q)}q=!1}q&&(w=N[0])}}return N=j(),N.memoizedState=N.baseState=w,q={pending:null,lanes:0,dispatch:null,lastRenderedReducer:sa,lastRenderedState:w},N.queue=q,N=gC.bind(null,xi,q),q.dispatch=N,q=ui(!1),ue=ny.bind(null,xi,!1,q.queue),q=j(),ne={state:w,dispatch:null,action:T,pending:null},q.queue=ne,N=jr.bind(null,xi,ne,ue,N),ne.dispatch=N,q.memoizedState=T,[w,N,!1]}function al(T){var w=Q();return pn(w,yi,T)}function pn(T,w,N){if(w=Ot(T,w,sa)[0],T=lt(Ge)[0],typeof w=="object"&&w!==null&&typeof w.then=="function")try{var q=he(w)}catch(Ie){throw Ie===ch?qh:Ie}else q=w;w=Q();var ne=w.queue,ue=ne.dispatch;return N!==w.memoizedState&&(xi.flags|=2048,In(9,{destroy:void 0},sl.bind(null,ne,N),null)),[q,ue,T]}function sl(T,w){T.action=w}function Hs(T){var w=Q(),N=yi;if(N!==null)return pn(w,N,T);Q(),w=w.memoizedState,N=Q();var q=N.queue.dispatch;return N.memoizedState=T,[w,q,!1]}function In(T,w,N,q){return T={tag:T,create:N,deps:q,inst:w,next:null},w=xi.updateQueue,w===null&&(w=ie(),xi.updateQueue=w),N=w.lastEffect,N===null?w.lastEffect=T.next=T:(q=N.next,N.next=T,T.next=q,w.lastEffect=T),T}function dc(){return Q().memoizedState}function ss(T,w,N,q){var ne=j();xi.flags|=T,ne.memoizedState=In(1|w,{destroy:void 0},N,q===void 0?null:q)}function Hm(T,w,N,q){var ne=Q();q=q===void 0?null:q;var ue=ne.memoizedState.inst;yi!==null&&q!==null&&df(q,yi.memoizedState.deps)?ne.memoizedState=In(w,ue,N,q):(xi.flags|=T,ne.memoizedState=In(1|w,ue,N,q))}function sC(T,w){ss(8390656,8,T,w)}function Um(T,w){Hm(2048,8,T,w)}function t2(T){xi.flags|=4;var w=xi.updateQueue;if(w===null)w=ie(),xi.updateQueue=w,w.events=[T];else{var N=w.events;N===null?w.events=[T]:N.push(T)}}function mR(T){var w=Q().memoizedState;return t2({ref:w,nextImpl:T}),function(){if((Oo&2)!==0)throw Error(n(440));return w.impl.apply(void 0,arguments)}}function bR(T,w){return Hm(4,2,T,w)}function lC(T,w){return Hm(4,4,T,w)}function uC(T,w){if(typeof w=="function"){T=T();var N=w(T);return function(){typeof N=="function"?N():w(null)}}if(w!=null)return T=T(),w.current=T,function(){w.current=null}}function SR(T,w,N){N=N!=null?N.concat([T]):null,Hm(4,4,uC.bind(null,w,T),N)}function XS(){}function cC(T,w){var N=Q();w=w===void 0?null:w;var q=N.memoizedState;return w!==null&&df(w,q[1])?q[0]:(N.memoizedState=[T,w],T)}function Gu(T,w){var N=Q();w=w===void 0?null:w;var q=N.memoizedState;if(w!==null&&df(w,q[1]))return q[0];if(q=T(),zc){_t(!0);try{T()}finally{_t(!1)}}return N.memoizedState=[q,w],q}function wd(T,w,N){return N===void 0||(Al&1073741824)!==0&&(Xn&261930)===0?T.memoizedState=w:(T.memoizedState=N,T=YR(),xi.lanes|=T,tg|=T,N)}function _R(T,w,N,q){return Ke(N,w)?N:Hc.current!==null?(T=wd(T,N,q),Ke(T,w)||(Xa=!0),T):(Al&42)===0||(Al&1073741824)!==0&&(Xn&261930)===0?(Xa=!0,T.memoizedState=N):(T=YR(),xi.lanes|=T,tg|=T,w)}function PR(T,w,N,q,ne){var ue=z.p;z.p=ue!==0&&8>ue?ue:8;var Ie=V.T,ot={};V.T=ot,ny(T,!1,w,N);try{var Et=ne(),tr=V.S;if(tr!==null&&tr(ot,Et),Et!==null&&typeof Et=="object"&&typeof Et.then=="function"){var yr=Vm(Et,q);iy(T,w,yr,qc(T))}else iy(T,w,q,qc(T))}catch(Pr){iy(T,w,{then:function(){},status:"rejected",reason:Pr},qc())}finally{z.p=ue,Ie!==null&&ot.types!==null&&(Ie.types=ot.types),V.T=Ie}}function KS(){}function Kp(T,w,N,q){if(T.tag!==5)throw Error(n(476));var ne=dC(T).queue;PR(T,ne,w,G,N===null?KS:function(){return fC(T),N(q)})}function dC(T){var w=T.memoizedState;if(w!==null)return w;w={memoizedState:G,baseState:G,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ge,lastRenderedState:G},next:null};var N={};return w.next={memoizedState:N,baseState:N,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Ge,lastRenderedState:N},next:null},T.memoizedState=w,T=T.alternate,T!==null&&(T.memoizedState=w),w}function fC(T){var w=dC(T);w.next===null&&(w=T.alternate.memoizedState),iy(T,w.next.queue,{},qc())}function hC(){return _s(Sy)}function pC(){return Q().memoizedState}function Kg(){return Q().memoizedState}function zm(T){for(var w=T.return;w!==null;){switch(w.tag){case 24:case 3:var N=qc();T=Td(N);var q=Tu(w,T,N);q!==null&&(vc(q,w,N),fh(q,w,N)),w={cache:$u()},T.payload=w;return}w=w.return}}function r2(T,w,N){var q=qc();N={lane:q,revertLane:0,gesture:null,action:N,hasEagerState:!1,eagerState:null,next:null},$m(T)?Wm(w,N):(N=Bp(T,w,N,q),N!==null&&(vc(N,T,q),ZS(N,w,q)))}function gC(T,w,N){var q=qc();iy(T,w,N,q)}function iy(T,w,N,q){var ne={lane:q,revertLane:0,gesture:null,action:N,hasEagerState:!1,eagerState:null,next:null};if($m(T))Wm(w,ne);else{var ue=T.alternate;if(T.lanes===0&&(ue===null||ue.lanes===0)&&(ue=w.lastRenderedReducer,ue!==null))try{var Ie=w.lastRenderedState,ot=ue(Ie,N);if(ne.hasEagerState=!0,ne.eagerState=ot,Ke(ot,Ie))return nf(T,w,ne,0),ua===null&&Or(),!1}catch{}finally{}if(N=Bp(T,w,ne,q),N!==null)return vc(N,T,q),ZS(N,w,q),!0}return!1}function ny(T,w,N,q){if(q={lane:2,revertLane:Xc(),gesture:null,action:q,hasEagerState:!1,eagerState:null,next:null},$m(T)){if(w)throw Error(n(479))}else w=Bp(T,N,q,2),w!==null&&vc(w,T,2)}function $m(T){var w=T.alternate;return T===xi||w!==null&&w===xi}function Wm(T,w){Ol=Cs=!0;var N=T.pending;N===null?w.next=w:(w.next=N.next,N.next=w),T.pending=w}function ZS(T,w,N){if((N&4194048)!==0){var q=w.lanes;q&=T.pendingLanes,N|=q,w.lanes=N,vi(T,N)}}var Zp={readContext:_s,use:Oe,useCallback:Ko,useContext:Ko,useEffect:Ko,useImperativeHandle:Ko,useLayoutEffect:Ko,useInsertionEffect:Ko,useMemo:Ko,useReducer:Ko,useRef:Ko,useState:Ko,useDebugValue:Ko,useDeferredValue:Ko,useTransition:Ko,useSyncExternalStore:Ko,useId:Ko,useHostTransitionStatus:Ko,useFormState:Ko,useActionState:Ko,useOptimistic:Ko,useMemoCache:Ko,useCacheRefresh:Ko};Zp.useEffectEvent=Ko;var CR={readContext:_s,use:Oe,useCallback:function(T,w){return j().memoizedState=[T,w===void 0?null:w],T},useContext:_s,useEffect:sC,useImperativeHandle:function(T,w,N){N=N!=null?N.concat([T]):null,ss(4194308,4,uC.bind(null,w,T),N)},useLayoutEffect:function(T,w){return ss(4194308,4,T,w)},useInsertionEffect:function(T,w){ss(4,2,T,w)},useMemo:function(T,w){var N=j();w=w===void 0?null:w;var q=T();if(zc){_t(!0);try{T()}finally{_t(!1)}}return N.memoizedState=[q,w],q},useReducer:function(T,w,N){var q=j();if(N!==void 0){var ne=N(w);if(zc){_t(!0);try{N(w)}finally{_t(!1)}}}else ne=w;return q.memoizedState=q.baseState=ne,T={pending:null,lanes:0,dispatch:null,lastRenderedReducer:T,lastRenderedState:ne},q.queue=T,T=T.dispatch=r2.bind(null,xi,T),[q.memoizedState,T]},useRef:function(T){var w=j();return T={current:T},w.memoizedState=T},useState:function(T){T=ui(T);var w=T.queue,N=gC.bind(null,xi,w);return w.dispatch=N,[T.memoizedState,N]},useDebugValue:XS,useDeferredValue:function(T,w){var N=j();return wd(N,T,w)},useTransition:function(){var T=ui(!1);return T=PR.bind(null,xi,T.queue,!0,!1),j().memoizedState=T,[!1,T]},useSyncExternalStore:function(T,w,N){var q=xi,ne=j();if(kn){if(N===void 0)throw Error(n(407));N=N()}else{if(N=w(),ua===null)throw Error(n(349));(Xn&127)!==0||cr(q,w,N)}ne.memoizedState=N;var ue={value:N,getSnapshot:w};return ne.queue=ue,sC(mr.bind(null,q,ue,T),[T]),q.flags|=2048,In(9,{destroy:void 0},or.bind(null,q,ue,N,w),null),N},useId:function(){var T=j(),w=ua.identifierPrefix;if(kn){var N=mu,q=yu;N=(q&~(1<<32-Ht(q)-1)).toString(32)+N,w="_"+w+"R_"+N,N=Ed++,0<N&&(w+="H"+N.toString(32)),w+="_"}else N=ry++,w="_"+w+"r_"+N.toString(32)+"_";return T.memoizedState=w},useHostTransitionStatus:hC,useFormState:No,useActionState:No,useOptimistic:function(T){var w=j();w.memoizedState=w.baseState=T;var N={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return w.queue=N,w=ny.bind(null,xi,!0,N),N.dispatch=w,[T,w]},useMemoCache:Fe,useCacheRefresh:function(){return j().memoizedState=zm.bind(null,xi)},useEffectEvent:function(T){var w=j(),N={impl:T};return w.memoizedState=N,function(){if((Oo&2)!==0)throw Error(n(440));return N.impl.apply(void 0,arguments)}}},JS={readContext:_s,use:Oe,useCallback:cC,useContext:_s,useEffect:Um,useImperativeHandle:SR,useInsertionEffect:bR,useLayoutEffect:lC,useMemo:Gu,useReducer:lt,useRef:dc,useState:function(){return lt(Ge)},useDebugValue:XS,useDeferredValue:function(T,w){var N=Q();return _R(N,yi.memoizedState,T,w)},useTransition:function(){var T=lt(Ge)[0],w=Q().memoizedState;return[typeof T=="boolean"?T:he(T),w]},useSyncExternalStore:jt,useId:pC,useHostTransitionStatus:hC,useFormState:al,useActionState:al,useOptimistic:function(T,w){var N=Q();return Ei(N,yi,T,w)},useMemoCache:Fe,useCacheRefresh:Kg};JS.useEffectEvent=mR;var Gm={readContext:_s,use:Oe,useCallback:cC,useContext:_s,useEffect:Um,useImperativeHandle:SR,useInsertionEffect:bR,useLayoutEffect:lC,useMemo:Gu,useReducer:St,useRef:dc,useState:function(){return St(Ge)},useDebugValue:XS,useDeferredValue:function(T,w){var N=Q();return yi===null?wd(N,T,w):_R(N,yi.memoizedState,T,w)},useTransition:function(){var T=St(Ge)[0],w=Q().memoizedState;return[typeof T=="boolean"?T:he(T),w]},useSyncExternalStore:jt,useId:pC,useHostTransitionStatus:hC,useFormState:Hs,useActionState:Hs,useOptimistic:function(T,w){var N=Q();return yi!==null?Ei(N,yi,T,w):(N.baseState=T,[T,N.queue.dispatch])},useMemoCache:Fe,useCacheRefresh:Kg};Gm.useEffectEvent=mR;function QS(T,w,N,q){w=T.memoizedState,N=N(q,w),N=N==null?w:d({},w,N),T.memoizedState=N,T.lanes===0&&(T.updateQueue.baseState=N)}var Ym={enqueueSetState:function(T,w,N){T=T._reactInternals;var q=qc(),ne=Td(q);ne.payload=w,N!=null&&(ne.callback=N),w=Tu(T,ne,q),w!==null&&(vc(w,T,q),fh(w,T,q))},enqueueReplaceState:function(T,w,N){T=T._reactInternals;var q=qc(),ne=Td(q);ne.tag=1,ne.payload=w,N!=null&&(ne.callback=N),w=Tu(T,ne,q),w!==null&&(vc(w,T,q),fh(w,T,q))},enqueueForceUpdate:function(T,w){T=T._reactInternals;var N=qc(),q=Td(N);q.tag=2,w!=null&&(q.callback=w),w=Tu(T,q,N),w!==null&&(vc(w,T,N),fh(w,T,N))}};function TR(T,w,N,q,ne,ue,Ie){return T=T.stateNode,typeof T.shouldComponentUpdate=="function"?T.shouldComponentUpdate(q,ue,Ie):w.prototype&&w.prototype.isPureReactComponent?!le(N,q)||!le(ne,ue):!0}function vC(T,w,N,q){T=w.state,typeof w.componentWillReceiveProps=="function"&&w.componentWillReceiveProps(N,q),typeof w.UNSAFE_componentWillReceiveProps=="function"&&w.UNSAFE_componentWillReceiveProps(N,q),w.state!==T&&Ym.enqueueReplaceState(w,w.state,null)}function Yu(T,w){var N=w;if("ref"in w){N={};for(var q in w)q!=="ref"&&(N[q]=w[q])}if(T=T.defaultProps){N===w&&(N=d({},N));for(var ne in T)N[ne]===void 0&&(N[ne]=T[ne])}return N}function yC(T){so(T)}function mC(T){console.error(T)}function xR(T){so(T)}function qm(T,w){try{var N=T.onUncaughtError;N(w.value,{componentStack:w.stack})}catch(q){setTimeout(function(){throw q})}}function ER(T,w,N){try{var q=T.onCaughtError;q(N.value,{componentStack:N.stack,errorBoundary:w.tag===1?w.stateNode:null})}catch(ne){setTimeout(function(){throw ne})}}function bC(T,w,N){return N=Td(N),N.tag=3,N.payload={element:null},N.callback=function(){qm(T,w)},N}function gh(T){return T=Td(T),T.tag=3,T}function e_(T,w,N,q){var ne=N.type.getDerivedStateFromError;if(typeof ne=="function"){var ue=q.value;T.payload=function(){return ne(ue)},T.callback=function(){ER(w,N,q)}}var Ie=N.stateNode;Ie!==null&&typeof Ie.componentDidCatch=="function"&&(T.callback=function(){ER(w,N,q),typeof ne!="function"&&(rg===null?rg=new Set([this]):rg.add(this));var ot=q.stack;this.componentDidCatch(q.value,{componentStack:ot!==null?ot:""})})}function SC(T,w,N,q,ne){if(N.flags|=32768,q!==null&&typeof q=="object"&&typeof q.then=="function"){if(w=N.alternate,w!==null&&sh(w,N,ne,!0),N=ql.current,N!==null){switch(N.tag){case 31:case 13:return El===null?p_():N.alternate===null&&Ka===0&&(Ka=3),N.flags&=-257,N.flags|=65536,N.lanes=ne,q===Xh?N.flags|=16384:(w=N.updateQueue,w===null?N.updateQueue=new Set([q]):w.add(q),XC(T,q,ne)),!1;case 22:return N.flags|=65536,q===Xh?N.flags|=16384:(w=N.updateQueue,w===null?(w={transitions:null,markerInstances:null,retryQueue:new Set([q])},N.updateQueue=w):(N=w.retryQueue,N===null?w.retryQueue=new Set([q]):N.add(q)),XC(T,q,ne)),!1}throw Error(n(435,N.tag))}return XC(T,q,ne),p_(),!1}if(kn)return w=ql.current,w!==null?((w.flags&65536)===0&&(w.flags|=256),w.flags|=65536,w.lanes=ne,q!==$g&&(T=Error(n(422),{cause:q}),_d(Pl(T,N)))):(q!==$g&&(w=Error(n(423),{cause:q}),_d(Pl(w,N))),T=T.current.alternate,T.flags|=65536,ne&=-ne,T.lanes|=ne,q=Pl(q,N),ne=bC(T.stateNode,q,ne),Gp(T,ne),Ka!==4&&(Ka=2)),!1;var ue=Error(n(520),{cause:q});if(ue=Pl(ue,N),l0===null?l0=[ue]:l0.push(ue),Ka!==4&&(Ka=2),w===null)return!0;q=Pl(q,N),N=w;do{switch(N.tag){case 3:return N.flags|=65536,T=ne&-ne,N.lanes|=T,T=bC(N.stateNode,q,T),Gp(N,T),!1;case 1:if(w=N.type,ue=N.stateNode,(N.flags&128)===0&&(typeof w.getDerivedStateFromError=="function"||ue!==null&&typeof ue.componentDidCatch=="function"&&(rg===null||!rg.has(ue))))return N.flags|=65536,ne&=-ne,N.lanes|=ne,ne=gh(ne),e_(ne,T,N,q),Gp(N,ne),!1}N=N.return}while(N!==null);return!1}var Xm=Error(n(461)),Xa=!1;function ls(T,w,N,q){w.child=T===null?$p(w,null,N,q):Cd(w,T.child,N,q)}function Mi(T,w,N,q,ne){N=N.render;var ue=w.ref;if("ref"in q){var Ie={};for(var ot in q)ot!=="ref"&&(Ie[ot]=q[ot])}else Ie=q;return sf(w),q=Zh(T,w,N,Ie,ue,ne),ot=ee(),T!==null&&!Xa?(ae(T,w,ne),vh(T,w,ne)):(kn&&ot&&yd(w),w.flags|=1,ls(T,w,q,ne),w.child)}function Km(T,w,N,q,ne){if(T===null){var ue=N.type;return typeof ue=="function"&&!Nc(ue)&&ue.defaultProps===void 0&&N.compare===null?(w.tag=15,w.type=ue,t_(T,w,ue,q,ne)):(T=Ln(N.type,null,q,w,w.mode,ne),T.ref=w.ref,T.return=w,w.child=T)}if(ue=T.child,!a_(T,ne)){var Ie=ue.memoizedProps;if(N=N.compare,N=N!==null?N:le,N(Ie,q)&&T.ref===w.ref)return vh(T,w,ne)}return w.flags|=1,T=Wl(ue,q),T.ref=w.ref,T.return=w,w.child=T}function t_(T,w,N,q,ne){if(T!==null){var ue=T.memoizedProps;if(le(ue,q)&&T.ref===w.ref)if(Xa=!1,w.pendingProps=q=ue,a_(T,ne))(T.flags&131072)!==0&&(Xa=!0);else return w.lanes=T.lanes,vh(T,w,ne)}return n_(T,w,N,q,ne)}function Jp(T,w,N,q){var ne=q.children,ue=T!==null?T.memoizedState:null;if(T===null&&w.stateNode===null&&(w.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),q.mode==="hidden"){if((w.flags&128)!==0){if(ue=ue!==null?ue.baseLanes|N:N,T!==null){for(q=w.child=T.child,ne=0;q!==null;)ne=ne|q.lanes|q.childLanes,q=q.sibling;q=ne&~ue}else q=0,w.child=null;return r_(T,w,ue,N,q)}if((N&536870912)!==0)w.memoizedState={baseLanes:0,cachePool:null},T!==null&&Hp(w,ue!==null?ue.cachePool:null),ue!==null?Xg(w,ue):Ps(),qp(w);else return q=w.lanes=536870912,r_(T,w,ue!==null?ue.baseLanes|N:N,N,q)}else ue!==null?(Hp(w,ue.cachePool),Xg(w,ue),wl(),w.memoizedState=null):(T!==null&&Hp(w,null),Ps(),wl());return ls(T,w,ne,N),w.child}function Zm(T,w){return T!==null&&T.tag===22||w.stateNode!==null||(w.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),w.sibling}function r_(T,w,N,q,ne){var ue=Yg();return ue=ue===null?null:{parent:Ha._currentValue,pool:ue},w.memoizedState={baseLanes:N,cachePool:ue},T!==null&&Hp(w,null),Ps(),qp(w),T!==null&&sh(T,w,q,!0),w.childLanes=ne,null}function Jm(T,w){return w=o_({mode:w.mode,children:w.children},T.mode),w.ref=T.ref,T.child=w,w.return=T,w}function Xl(T,w,N){return Cd(w,T.child,null,N),T=Jm(w,w.pendingProps),T.flags|=2,ol(w),w.memoizedState=null,T}function i2(T,w,N){var q=w.pendingProps,ne=(w.flags&128)!==0;if(w.flags&=-129,T===null){if(kn){if(q.mode==="hidden")return T=Jm(w,q),w.lanes=536870912,Zm(null,T);if(ph(w),(T=lo)?(T=vM(T,bu),T=T!==null&&T.data==="&"?T:null,T!==null&&(w.memoizedState={dehydrated:T,treeContext:Gl!==null?{id:yu,overflow:mu}:null,retryLane:536870912,hydrationErrors:null},N=_n(T),N.return=w,w.child=N,Va=w,lo=null)):T=null,T===null)throw bd(w);return w.lanes=536870912,null}return Jm(w,q)}var ue=T.memoizedState;if(ue!==null){var Ie=ue.dehydrated;if(ph(w),ne)if(w.flags&256)w.flags&=-257,w=Xl(T,w,N);else if(w.memoizedState!==null)w.child=T.child,w.flags|=128,w=null;else throw Error(n(558));else if(Xa||sh(T,w,N,!1),ne=(N&T.childLanes)!==0,Xa||ne){if(q=ua,q!==null&&(Ie=rr(q,N),Ie!==0&&Ie!==ue.retryLane))throw ue.retryLane=Ie,Rr(T,Ie),vc(q,T,Ie),Xm;p_(),w=Xl(T,w,N)}else T=ue.treeContext,lo=Ad(Ie.nextSibling),Va=w,kn=!0,md=null,bu=!1,T!==null&&oh(w,T),w=Jm(w,q),w.flags|=4096;return w}return T=Wl(T.child,{mode:q.mode,children:q.children}),T.ref=w.ref,w.child=T,T.return=w,T}function i_(T,w){var N=w.ref;if(N===null)T!==null&&T.ref!==null&&(w.flags|=4194816);else{if(typeof N!="function"&&typeof N!="object")throw Error(n(284));(T===null||T.ref!==N)&&(w.flags|=4194816)}}function n_(T,w,N,q,ne){return sf(w),N=Zh(T,w,N,q,void 0,ne),q=ee(),T!==null&&!Xa?(ae(T,w,ne),vh(T,w,ne)):(kn&&q&&yd(w),w.flags|=1,ls(T,w,N,ne),w.child)}function wR(T,w,N,q,ne,ue){return sf(w),w.updateQueue=null,N=Wc(w,q,N,ne),Xp(T),q=ee(),T!==null&&!Xa?(ae(T,w,ue),vh(T,w,ue)):(kn&&q&&yd(w),w.flags|=1,ls(T,w,N,ue),w.child)}function _C(T,w,N,q,ne){if(sf(w),w.stateNode===null){var ue=Ic,Ie=N.contextType;typeof Ie=="object"&&Ie!==null&&(ue=_s(Ie)),ue=new N(q,ue),w.memoizedState=ue.state!==null&&ue.state!==void 0?ue.state:null,ue.updater=Ym,w.stateNode=ue,ue._reactInternals=w,ue=w.stateNode,ue.props=q,ue.state=w.memoizedState,ue.refs={},uc(w),Ie=N.contextType,ue.context=typeof Ie=="object"&&Ie!==null?_s(Ie):Ic,ue.state=w.memoizedState,Ie=N.getDerivedStateFromProps,typeof Ie=="function"&&(QS(w,N,Ie,q),ue.state=w.memoizedState),typeof N.getDerivedStateFromProps=="function"||typeof ue.getSnapshotBeforeUpdate=="function"||typeof ue.UNSAFE_componentWillMount!="function"&&typeof ue.componentWillMount!="function"||(Ie=ue.state,typeof ue.componentWillMount=="function"&&ue.componentWillMount(),typeof ue.UNSAFE_componentWillMount=="function"&&ue.UNSAFE_componentWillMount(),Ie!==ue.state&&Ym.enqueueReplaceState(ue,ue.state,null),hh(w,q,ue,ne),xd(),ue.state=w.memoizedState),typeof ue.componentDidMount=="function"&&(w.flags|=4194308),q=!0}else if(T===null){ue=w.stateNode;var ot=w.memoizedProps,Et=Yu(N,ot);ue.props=Et;var tr=ue.context,yr=N.contextType;Ie=Ic,typeof yr=="object"&&yr!==null&&(Ie=_s(yr));var Pr=N.getDerivedStateFromProps;yr=typeof Pr=="function"||typeof ue.getSnapshotBeforeUpdate=="function",ot=w.pendingProps!==ot,yr||typeof ue.UNSAFE_componentWillReceiveProps!="function"&&typeof ue.componentWillReceiveProps!="function"||(ot||tr!==Ie)&&vC(w,ue,q,Ie),Cu=!1;var ir=w.memoizedState;ue.state=ir,hh(w,q,ue,ne),xd(),tr=w.memoizedState,ot||ir!==tr||Cu?(typeof Pr=="function"&&(QS(w,N,Pr,q),tr=w.memoizedState),(Et=Cu||TR(w,N,Et,q,ir,tr,Ie))?(yr||typeof ue.UNSAFE_componentWillMount!="function"&&typeof ue.componentWillMount!="function"||(typeof ue.componentWillMount=="function"&&ue.componentWillMount(),typeof ue.UNSAFE_componentWillMount=="function"&&ue.UNSAFE_componentWillMount()),typeof ue.componentDidMount=="function"&&(w.flags|=4194308)):(typeof ue.componentDidMount=="function"&&(w.flags|=4194308),w.memoizedProps=q,w.memoizedState=tr),ue.props=q,ue.state=tr,ue.context=Ie,q=Et):(typeof ue.componentDidMount=="function"&&(w.flags|=4194308),q=!1)}else{ue=w.stateNode,Wp(T,w),Ie=w.memoizedProps,yr=Yu(N,Ie),ue.props=yr,Pr=w.pendingProps,ir=ue.context,tr=N.contextType,Et=Ic,typeof tr=="object"&&tr!==null&&(Et=_s(tr)),ot=N.getDerivedStateFromProps,(tr=typeof ot=="function"||typeof ue.getSnapshotBeforeUpdate=="function")||typeof ue.UNSAFE_componentWillReceiveProps!="function"&&typeof ue.componentWillReceiveProps!="function"||(Ie!==Pr||ir!==Et)&&vC(w,ue,q,Et),Cu=!1,ir=w.memoizedState,ue.state=ir,hh(w,q,ue,ne),xd();var ar=w.memoizedState;Ie!==Pr||ir!==ar||Cu||T!==null&&T.dependencies!==null&&Vp(T.dependencies)?(typeof ot=="function"&&(QS(w,N,ot,q),ar=w.memoizedState),(yr=Cu||TR(w,N,yr,q,ir,ar,Et)||T!==null&&T.dependencies!==null&&Vp(T.dependencies))?(tr||typeof ue.UNSAFE_componentWillUpdate!="function"&&typeof ue.componentWillUpdate!="function"||(typeof ue.componentWillUpdate=="function"&&ue.componentWillUpdate(q,ar,Et),typeof ue.UNSAFE_componentWillUpdate=="function"&&ue.UNSAFE_componentWillUpdate(q,ar,Et)),typeof ue.componentDidUpdate=="function"&&(w.flags|=4),typeof ue.getSnapshotBeforeUpdate=="function"&&(w.flags|=1024)):(typeof ue.componentDidUpdate!="function"||Ie===T.memoizedProps&&ir===T.memoizedState||(w.flags|=4),typeof ue.getSnapshotBeforeUpdate!="function"||Ie===T.memoizedProps&&ir===T.memoizedState||(w.flags|=1024),w.memoizedProps=q,w.memoizedState=ar),ue.props=q,ue.state=ar,ue.context=Et,q=yr):(typeof ue.componentDidUpdate!="function"||Ie===T.memoizedProps&&ir===T.memoizedState||(w.flags|=4),typeof ue.getSnapshotBeforeUpdate!="function"||Ie===T.memoizedProps&&ir===T.memoizedState||(w.flags|=1024),q=!1)}return ue=q,i_(T,w),q=(w.flags&128)!==0,ue||q?(ue=w.stateNode,N=q&&typeof N.getDerivedStateFromError!="function"?null:ue.render(),w.flags|=1,T!==null&&q?(w.child=Cd(w,T.child,null,ne),w.child=Cd(w,null,N,ne)):ls(T,w,N,ne),w.memoizedState=ue.state,T=w.child):T=vh(T,w,ne),T}function AR(T,w,N,q){return nt(),w.flags|=256,ls(T,w,N,q),w.child}var PC={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function CC(T){return{baseLanes:T,cachePool:Jv()}}function ff(T,w,N){return T=T!==null?T.childLanes&~N:0,w&&(T|=Yc),T}function xu(T,w,N){var q=w.pendingProps,ne=!1,ue=(w.flags&128)!==0,Ie;if((Ie=ue)||(Ie=T!==null&&T.memoizedState===null?!1:(Ea.current&2)!==0),Ie&&(ne=!0,w.flags&=-129),Ie=(w.flags&32)!==0,w.flags&=-33,T===null){if(kn){if(ne?Uc(w):wl(),(T=lo)?(T=vM(T,bu),T=T!==null&&T.data!=="&"?T:null,T!==null&&(w.memoizedState={dehydrated:T,treeContext:Gl!==null?{id:yu,overflow:mu}:null,retryLane:536870912,hydrationErrors:null},N=_n(T),N.return=w,w.child=N,Va=w,lo=null)):T=null,T===null)throw bd(w);return py(T)?w.lanes=32:w.lanes=536870912,null}var ot=q.children;return q=q.fallback,ne?(wl(),ne=w.mode,ot=o_({mode:"hidden",children:ot},ne),q=vd(q,ne,N,null),ot.return=w,q.return=w,ot.sibling=q,w.child=ot,q=w.child,q.memoizedState=CC(N),q.childLanes=ff(T,Ie,N),w.memoizedState=PC,Zm(null,q)):(Uc(w),Qm(w,ot))}var Et=T.memoizedState;if(Et!==null&&(ot=Et.dehydrated,ot!==null)){if(ue)w.flags&256?(Uc(w),w.flags&=-257,w=e0(T,w,N)):w.memoizedState!==null?(wl(),w.child=T.child,w.flags|=128,w=null):(wl(),ot=q.fallback,ne=w.mode,q=o_({mode:"visible",children:q.children},ne),ot=vd(ot,ne,N,null),ot.flags|=2,q.return=w,ot.return=w,q.sibling=ot,w.child=q,Cd(w,T.child,null,N),q=w.child,q.memoizedState=CC(N),q.childLanes=ff(T,Ie,N),w.memoizedState=PC,w=Zm(null,q));else if(Uc(w),py(ot)){if(Ie=ot.nextSibling&&ot.nextSibling.dataset,Ie)var tr=Ie.dgst;Ie=tr,q=Error(n(419)),q.stack="",q.digest=Ie,_d({value:q,source:null,stack:null}),w=e0(T,w,N)}else if(Xa||sh(T,w,N,!1),Ie=(N&T.childLanes)!==0,Xa||Ie){if(Ie=ua,Ie!==null&&(q=rr(Ie,N),q!==0&&q!==Et.retryLane))throw Et.retryLane=q,Rr(T,q),vc(Ie,T,q),Xm;C_(ot)||p_(),w=e0(T,w,N)}else C_(ot)?(w.flags|=192,w.child=T.child,w=null):(T=Et.treeContext,lo=Ad(ot.nextSibling),Va=w,kn=!0,md=null,bu=!1,T!==null&&oh(w,T),w=Qm(w,q.children),w.flags|=4096);return w}return ne?(wl(),ot=q.fallback,ne=w.mode,Et=T.child,tr=Et.sibling,q=Wl(Et,{mode:"hidden",children:q.children}),q.subtreeFlags=Et.subtreeFlags&65011712,tr!==null?ot=Wl(tr,ot):(ot=vd(ot,ne,N,null),ot.flags|=2),ot.return=w,q.return=w,q.sibling=ot,w.child=q,Zm(null,q),q=w.child,ot=T.child.memoizedState,ot===null?ot=CC(N):(ne=ot.cachePool,ne!==null?(Et=Ha._currentValue,ne=ne.parent!==Et?{parent:Et,pool:Et}:ne):ne=Jv(),ot={baseLanes:ot.baseLanes|N,cachePool:ne}),q.memoizedState=ot,q.childLanes=ff(T,Ie,N),w.memoizedState=PC,Zm(T.child,q)):(Uc(w),N=T.child,T=N.sibling,N=Wl(N,{mode:"visible",children:q.children}),N.return=w,N.sibling=null,T!==null&&(Ie=w.deletions,Ie===null?(w.deletions=[T],w.flags|=16):Ie.push(T)),w.child=N,w.memoizedState=null,N)}function Qm(T,w){return w=o_({mode:"visible",children:w},T.mode),w.return=T,T.child=w}function o_(T,w){return T=bs(22,T,null,w),T.lanes=0,T}function e0(T,w,N){return Cd(w,T.child,null,N),T=Qm(w,w.pendingProps.children),T.flags|=2,w.memoizedState=null,T}function OR(T,w,N){T.lanes|=w;var q=T.alternate;q!==null&&(q.lanes|=w),jc(T.return,w,N)}function TC(T,w,N,q,ne,ue){var Ie=T.memoizedState;Ie===null?T.memoizedState={isBackwards:w,rendering:null,renderingStartTime:0,last:q,tail:N,tailMode:ne,treeForkCount:ue}:(Ie.isBackwards=w,Ie.rendering=null,Ie.renderingStartTime=0,Ie.last=q,Ie.tail=N,Ie.tailMode=ne,Ie.treeForkCount=ue)}function oy(T,w,N){var q=w.pendingProps,ne=q.revealOrder,ue=q.tail;q=q.children;var Ie=Ea.current,ot=(Ie&2)!==0;if(ot?(Ie=Ie&1|2,w.flags|=128):Ie&=1,W(Ea,Ie),ls(T,w,q,N),q=kn?ja:0,!ot&&T!==null&&(T.flags&128)!==0)e:for(T=w.child;T!==null;){if(T.tag===13)T.memoizedState!==null&&OR(T,N,w);else if(T.tag===19)OR(T,N,w);else if(T.child!==null){T.child.return=T,T=T.child;continue}if(T===w)break e;for(;T.sibling===null;){if(T.return===null||T.return===w)break e;T=T.return}T.sibling.return=T.return,T=T.sibling}switch(ne){case"forwards":for(N=w.child,ne=null;N!==null;)T=N.alternate,T!==null&&Io(T)===null&&(ne=N),N=N.sibling;N=ne,N===null?(ne=w.child,w.child=null):(ne=N.sibling,N.sibling=null),TC(w,!1,ne,N,ue,q);break;case"backwards":case"unstable_legacy-backwards":for(N=null,ne=w.child,w.child=null;ne!==null;){if(T=ne.alternate,T!==null&&Io(T)===null){w.child=ne;break}T=ne.sibling,ne.sibling=N,N=ne,ne=T}TC(w,!0,N,null,ue,q);break;case"together":TC(w,!1,null,null,void 0,q);break;default:w.memoizedState=null}return w.child}function vh(T,w,N){if(T!==null&&(w.dependencies=T.dependencies),tg|=w.lanes,(N&w.childLanes)===0)if(T!==null){if(sh(T,w,N,!1),(N&w.childLanes)===0)return null}else return null;if(T!==null&&w.child!==T.child)throw Error(n(153));if(w.child!==null){for(T=w.child,N=Wl(T,T.pendingProps),w.child=N,N.return=w;T.sibling!==null;)T=T.sibling,N=N.sibling=Wl(T,T.pendingProps),N.return=w;N.sibling=null}return w.child}function a_(T,w){return(T.lanes&w)!==0?!0:(T=T.dependencies,!!(T!==null&&Vp(T)))}function n2(T,w,N){switch(w.tag){case 3:ge(w,w.stateNode.containerInfo),Pd(w,Ha,T.memoizedState.cache),nt();break;case 27:case 5:Re(w);break;case 4:ge(w,w.stateNode.containerInfo);break;case 10:Pd(w,w.type,w.memoizedProps.value);break;case 31:if(w.memoizedState!==null)return w.flags|=128,ph(w),null;break;case 13:var q=w.memoizedState;if(q!==null)return q.dehydrated!==null?(Uc(w),w.flags|=128,null):(N&w.child.childLanes)!==0?xu(T,w,N):(Uc(w),T=vh(T,w,N),T!==null?T.sibling:null);Uc(w);break;case 19:var ne=(T.flags&128)!==0;if(q=(N&w.childLanes)!==0,q||(sh(T,w,N,!1),q=(N&w.childLanes)!==0),ne){if(q)return oy(T,w,N);w.flags|=128}if(ne=w.memoizedState,ne!==null&&(ne.rendering=null,ne.tail=null,ne.lastEffect=null),W(Ea,Ea.current),q)break;return null;case 22:return w.lanes=0,Jp(T,w,N,w.pendingProps);case 24:Pd(w,Ha,T.memoizedState.cache)}return vh(T,w,N)}function DR(T,w,N){if(T!==null)if(T.memoizedProps!==w.pendingProps)Xa=!0;else{if(!a_(T,N)&&(w.flags&128)===0)return Xa=!1,n2(T,w,N);Xa=(T.flags&131072)!==0}else Xa=!1,kn&&(w.flags&1048576)!==0&&jp(w,ja,w.index);switch(w.lanes=0,w.tag){case 16:e:{var q=w.pendingProps;if(T=Pu(w.elementType),w.type=T,typeof T=="function")Nc(T)?(q=Yu(T,q),w.tag=1,w=_C(null,w,T,q,N)):(w.tag=0,w=n_(null,w,T,q,N));else{if(T!=null){var ne=T.$$typeof;if(ne===S){w.tag=11,w=Mi(null,w,T,q,N);break e}else if(ne===P){w.tag=14,w=Km(null,w,T,q,N);break e}}throw w=F(T)||T,Error(n(306,w,""))}}return w;case 0:return n_(T,w,w.type,w.pendingProps,N);case 1:return q=w.type,ne=Yu(q,w.pendingProps),_C(T,w,q,ne,N);case 3:e:{if(ge(w,w.stateNode.containerInfo),T===null)throw Error(n(387));q=w.pendingProps;var ue=w.memoizedState;ne=ue.element,Wp(T,w),hh(w,q,null,N);var Ie=w.memoizedState;if(q=Ie.cache,Pd(w,Ha,q),q!==ue.cache&&Wg(w,[Ha],N,!0),xd(),q=Ie.element,ue.isDehydrated)if(ue={element:q,isDehydrated:!1,cache:Ie.cache},w.updateQueue.baseState=ue,w.memoizedState=ue,w.flags&256){w=AR(T,w,q,N);break e}else if(q!==ne){ne=Pl(Error(n(424)),w),_d(ne),w=AR(T,w,q,N);break e}else{switch(T=w.stateNode.containerInfo,T.nodeType){case 9:T=T.body;break;default:T=T.nodeName==="HTML"?T.ownerDocument.body:T}for(lo=Ad(T.firstChild),Va=w,kn=!0,md=null,bu=!0,N=$p(w,null,q,N),w.child=N;N;)N.flags=N.flags&-3|4096,N=N.sibling}else{if(nt(),q===ne){w=vh(T,w,N);break e}ls(T,w,q,N)}w=w.child}return w;case 26:return i_(T,w),T===null?(N=PM(w.type,null,w.pendingProps,null))?w.memoizedState=N:kn||(N=w.type,T=w.pendingProps,q=S0(oe.current).createElement(N),q[mt]=w,q[gr]=T,Kl(q,N,T),si(q),w.stateNode=q):w.memoizedState=PM(w.type,T.memoizedProps,w.pendingProps,T.memoizedState),null;case 27:return Re(w),T===null&&kn&&(q=w.stateNode=bM(w.type,w.pendingProps,oe.current),Va=w,bu=!0,ne=lo,Wi(w.type)?(sT=ne,lo=Ad(q.firstChild)):lo=ne),ls(T,w,w.pendingProps.children,N),i_(T,w),T===null&&(w.flags|=4194304),w.child;case 5:return T===null&&kn&&((ne=q=lo)&&(q=S2(q,w.type,w.pendingProps,bu),q!==null?(w.stateNode=q,Va=w,lo=Ad(q.firstChild),bu=!1,ne=!0):ne=!1),ne||bd(w)),Re(w),ne=w.type,ue=w.pendingProps,Ie=T!==null?T.memoizedProps:null,q=ue.children,ag(ne,ue)?q=null:Ie!==null&&ag(ne,Ie)&&(w.flags|=32),w.memoizedState!==null&&(ne=Zh(T,w,$,null,null,N),Sy._currentValue=ne),i_(T,w),ls(T,w,q,N),w.child;case 6:return T===null&&kn&&((T=N=lo)&&(N=Fo(N,w.pendingProps,bu),N!==null?(w.stateNode=N,Va=w,lo=null,T=!0):T=!1),T||bd(w)),null;case 13:return xu(T,w,N);case 4:return ge(w,w.stateNode.containerInfo),q=w.pendingProps,T===null?w.child=Cd(w,null,q,N):ls(T,w,q,N),w.child;case 11:return Mi(T,w,w.type,w.pendingProps,N);case 7:return ls(T,w,w.pendingProps,N),w.child;case 8:return ls(T,w,w.pendingProps.children,N),w.child;case 12:return ls(T,w,w.pendingProps.children,N),w.child;case 10:return q=w.pendingProps,Pd(w,w.type,q.value),ls(T,w,q.children,N),w.child;case 9:return ne=w.type._context,q=w.pendingProps.children,sf(w),ne=_s(ne),q=q(ne),w.flags|=1,ls(T,w,q,N),w.child;case 14:return Km(T,w,w.type,w.pendingProps,N);case 15:return t_(T,w,w.type,w.pendingProps,N);case 19:return oy(T,w,N);case 31:return i2(T,w,N);case 22:return Jp(T,w,N,w.pendingProps);case 24:return sf(w),q=_s(Ha),T===null?(ne=Yg(),ne===null&&(ne=ua,ue=$u(),ne.pooledCache=ue,ue.refCount++,ue!==null&&(ne.pooledCacheLanes|=N),ne=ue),w.memoizedState={parent:q,cache:ne},uc(w),Pd(w,Ha,ne)):((T.lanes&N)!==0&&(Wp(T,w),hh(w,null,null,N),xd()),ne=T.memoizedState,ue=w.memoizedState,ne.parent!==q?(ne={parent:q,cache:q},w.memoizedState=ne,w.lanes===0&&(w.memoizedState=w.updateQueue.baseState=ne),Pd(w,Ha,q)):(q=ue.cache,Pd(w,Ha,q),q!==ne.cache&&Wg(w,[Ha],N,!0))),ls(T,w,w.pendingProps.children,N),w.child;case 29:throw w.pendingProps}throw Error(n(156,w.tag))}function Jh(T){T.flags|=4}function xC(T,w,N,q,ne){if((w=(T.mode&32)!==0)&&(w=!1),w){if(T.flags|=16777216,(ne&335544128)===ne)if(T.stateNode.complete)T.flags|=8192;else if(d0())T.flags|=8192;else throw lc=Xh,Up}else T.flags&=-16777217}function EC(T,w){if(w.type!=="stylesheet"||(w.state.loading&4)!==0)T.flags&=-16777217;else if(T.flags|=16777216,!wM(w))if(d0())T.flags|=8192;else throw lc=Xh,Up}function t0(T,w){w!==null&&(T.flags|=4),T.flags&16384&&(w=T.tag!==22?Ar():536870912,T.lanes|=w,uy|=w)}function r0(T,w){if(!kn)switch(T.tailMode){case"hidden":w=T.tail;for(var N=null;w!==null;)w.alternate!==null&&(N=w),w=w.sibling;N===null?T.tail=null:N.sibling=null;break;case"collapsed":N=T.tail;for(var q=null;N!==null;)N.alternate!==null&&(q=N),N=N.sibling;q===null?w||T.tail===null?T.tail=null:T.tail.sibling=null:q.sibling=null}}function la(T){var w=T.alternate!==null&&T.alternate.child===T.child,N=0,q=0;if(w)for(var ne=T.child;ne!==null;)N|=ne.lanes|ne.childLanes,q|=ne.subtreeFlags&65011712,q|=ne.flags&65011712,ne.return=T,ne=ne.sibling;else for(ne=T.child;ne!==null;)N|=ne.lanes|ne.childLanes,q|=ne.subtreeFlags,q|=ne.flags,ne.return=T,ne=ne.sibling;return T.subtreeFlags|=q,T.childLanes=N,w}function RR(T,w,N){var q=w.pendingProps;switch(of(w),w.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return la(w),null;case 1:return la(w),null;case 3:return N=w.stateNode,q=null,T!==null&&(q=T.memoizedState.cache),w.memoizedState.cache!==q&&(w.flags|=2048),Bc(Ha),Ee(),N.pendingContext&&(N.context=N.pendingContext,N.pendingContext=null),(T===null||T.child===null)&&(af(w)?Jh(w):T===null||T.memoizedState.isDehydrated&&(w.flags&256)===0||(w.flags|=1024,Sd())),la(w),null;case 26:var ne=w.type,ue=w.memoizedState;return T===null?(Jh(w),ue!==null?(la(w),EC(w,ue)):(la(w),xC(w,ne,null,q,N))):ue?ue!==T.memoizedState?(Jh(w),la(w),EC(w,ue)):(la(w),w.flags&=-16777217):(T=T.memoizedProps,T!==q&&Jh(w),la(w),xC(w,ne,T,q,N)),null;case 27:if(Ae(w),N=oe.current,ne=w.type,T!==null&&w.stateNode!=null)T.memoizedProps!==q&&Jh(w);else{if(!q){if(w.stateNode===null)throw Error(n(166));return la(w),null}T=Y.current,af(w)?Wh(w):(T=bM(ne,q,N),w.stateNode=T,Jh(w))}return la(w),null;case 5:if(Ae(w),ne=w.type,T!==null&&w.stateNode!=null)T.memoizedProps!==q&&Jh(w);else{if(!q){if(w.stateNode===null)throw Error(n(166));return la(w),null}if(ue=Y.current,af(w))Wh(w);else{var Ie=S0(oe.current);switch(ue){case 1:ue=Ie.createElementNS("http://www.w3.org/2000/svg",ne);break;case 2:ue=Ie.createElementNS("http://www.w3.org/1998/Math/MathML",ne);break;default:switch(ne){case"svg":ue=Ie.createElementNS("http://www.w3.org/2000/svg",ne);break;case"math":ue=Ie.createElementNS("http://www.w3.org/1998/Math/MathML",ne);break;case"script":ue=Ie.createElement("div"),ue.innerHTML="<script><\/script>",ue=ue.removeChild(ue.firstChild);break;case"select":ue=typeof q.is=="string"?Ie.createElement("select",{is:q.is}):Ie.createElement("select"),q.multiple?ue.multiple=!0:q.size&&(ue.size=q.size);break;default:ue=typeof q.is=="string"?Ie.createElement(ne,{is:q.is}):Ie.createElement(ne)}}ue[mt]=w,ue[gr]=q;e:for(Ie=w.child;Ie!==null;){if(Ie.tag===5||Ie.tag===6)ue.appendChild(Ie.stateNode);else if(Ie.tag!==4&&Ie.tag!==27&&Ie.child!==null){Ie.child.return=Ie,Ie=Ie.child;continue}if(Ie===w)break e;for(;Ie.sibling===null;){if(Ie.return===null||Ie.return===w)break e;Ie=Ie.return}Ie.sibling.return=Ie.return,Ie=Ie.sibling}w.stateNode=ue;e:switch(Kl(ue,ne,q),ne){case"button":case"input":case"select":case"textarea":q=!!q.autoFocus;break e;case"img":q=!0;break e;default:q=!1}q&&Jh(w)}}return la(w),xC(w,w.type,T===null?null:T.memoizedProps,w.pendingProps,N),null;case 6:if(T&&w.stateNode!=null)T.memoizedProps!==q&&Jh(w);else{if(typeof q!="string"&&w.stateNode===null)throw Error(n(166));if(T=oe.current,af(w)){if(T=w.stateNode,N=w.memoizedProps,q=null,ne=Va,ne!==null)switch(ne.tag){case 27:case 5:q=ne.memoizedProps}T[mt]=w,T=!!(T.nodeValue===N||q!==null&&q.suppressHydrationWarning===!0||fM(T.nodeValue,N)),T||bd(w,!0)}else T=S0(T).createTextNode(q),T[mt]=w,w.stateNode=T}return la(w),null;case 31:if(N=w.memoizedState,T===null||T.memoizedState!==null){if(q=af(w),N!==null){if(T===null){if(!q)throw Error(n(318));if(T=w.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(n(557));T[mt]=w}else nt(),(w.flags&128)===0&&(w.memoizedState=null),w.flags|=4;la(w),T=!1}else N=Sd(),T!==null&&T.memoizedState!==null&&(T.memoizedState.hydrationErrors=N),T=!0;if(!T)return w.flags&256?(ol(w),w):(ol(w),null);if((w.flags&128)!==0)throw Error(n(558))}return la(w),null;case 13:if(q=w.memoizedState,T===null||T.memoizedState!==null&&T.memoizedState.dehydrated!==null){if(ne=af(w),q!==null&&q.dehydrated!==null){if(T===null){if(!ne)throw Error(n(318));if(ne=w.memoizedState,ne=ne!==null?ne.dehydrated:null,!ne)throw Error(n(317));ne[mt]=w}else nt(),(w.flags&128)===0&&(w.memoizedState=null),w.flags|=4;la(w),ne=!1}else ne=Sd(),T!==null&&T.memoizedState!==null&&(T.memoizedState.hydrationErrors=ne),ne=!0;if(!ne)return w.flags&256?(ol(w),w):(ol(w),null)}return ol(w),(w.flags&128)!==0?(w.lanes=N,w):(N=q!==null,T=T!==null&&T.memoizedState!==null,N&&(q=w.child,ne=null,q.alternate!==null&&q.alternate.memoizedState!==null&&q.alternate.memoizedState.cachePool!==null&&(ne=q.alternate.memoizedState.cachePool.pool),ue=null,q.memoizedState!==null&&q.memoizedState.cachePool!==null&&(ue=q.memoizedState.cachePool.pool),ue!==ne&&(q.flags|=2048)),N!==T&&N&&(w.child.flags|=8192),t0(w,w.updateQueue),la(w),null);case 4:return Ee(),T===null&&eT(w.stateNode.containerInfo),la(w),null;case 10:return Bc(w.type),la(w),null;case 19:if(X(Ea),q=w.memoizedState,q===null)return la(w),null;if(ne=(w.flags&128)!==0,ue=q.rendering,ue===null)if(ne)r0(q,!1);else{if(Ka!==0||T!==null&&(T.flags&128)!==0)for(T=w.child;T!==null;){if(ue=Io(T),ue!==null){for(w.flags|=128,r0(q,!1),T=ue.updateQueue,w.updateQueue=T,t0(w,T),w.subtreeFlags=0,T=N,N=w.child;N!==null;)Tr(N,T),N=N.sibling;return W(Ea,Ea.current&1|2),kn&&Ss(w,q.treeForkCount),w.child}T=T.sibling}q.tail!==null&&Qe()>Qg&&(w.flags|=128,ne=!0,r0(q,!1),w.lanes=4194304)}else{if(!ne)if(T=Io(ue),T!==null){if(w.flags|=128,ne=!0,T=T.updateQueue,w.updateQueue=T,t0(w,T),r0(q,!0),q.tail===null&&q.tailMode==="hidden"&&!ue.alternate&&!kn)return la(w),null}else 2*Qe()-q.renderingStartTime>Qg&&N!==536870912&&(w.flags|=128,ne=!0,r0(q,!1),w.lanes=4194304);q.isBackwards?(ue.sibling=w.child,w.child=ue):(T=q.last,T!==null?T.sibling=ue:w.child=ue,q.last=ue)}return q.tail!==null?(T=q.tail,q.rendering=T,q.tail=T.sibling,q.renderingStartTime=Qe(),T.sibling=null,N=Ea.current,W(Ea,ne?N&1|2:N&1),kn&&Ss(w,q.treeForkCount),T):(la(w),null);case 22:case 23:return ol(w),Kh(),q=w.memoizedState!==null,T!==null?T.memoizedState!==null!==q&&(w.flags|=8192):q&&(w.flags|=8192),q?(N&536870912)!==0&&(w.flags&128)===0&&(la(w),w.subtreeFlags&6&&(w.flags|=8192)):la(w),N=w.updateQueue,N!==null&&t0(w,N.retryQueue),N=null,T!==null&&T.memoizedState!==null&&T.memoizedState.cachePool!==null&&(N=T.memoizedState.cachePool.pool),q=null,w.memoizedState!==null&&w.memoizedState.cachePool!==null&&(q=w.memoizedState.cachePool.pool),q!==N&&(w.flags|=2048),T!==null&&X(uf),null;case 24:return N=null,T!==null&&(N=T.memoizedState.cache),w.memoizedState.cache!==N&&(w.flags|=2048),Bc(Ha),la(w),null;case 25:return null;case 30:return null}throw Error(n(156,w.tag))}function i0(T,w){switch(of(w),w.tag){case 1:return T=w.flags,T&65536?(w.flags=T&-65537|128,w):null;case 3:return Bc(Ha),Ee(),T=w.flags,(T&65536)!==0&&(T&128)===0?(w.flags=T&-65537|128,w):null;case 26:case 27:case 5:return Ae(w),null;case 31:if(w.memoizedState!==null){if(ol(w),w.alternate===null)throw Error(n(340));nt()}return T=w.flags,T&65536?(w.flags=T&-65537|128,w):null;case 13:if(ol(w),T=w.memoizedState,T!==null&&T.dehydrated!==null){if(w.alternate===null)throw Error(n(340));nt()}return T=w.flags,T&65536?(w.flags=T&-65537|128,w):null;case 19:return X(Ea),null;case 4:return Ee(),null;case 10:return Bc(w.type),null;case 22:case 23:return ol(w),Kh(),T!==null&&X(uf),T=w.flags,T&65536?(w.flags=T&-65537|128,w):null;case 24:return Bc(Ha),null;case 25:return null;default:return null}}function s_(T,w){switch(of(w),w.tag){case 3:Bc(Ha),Ee();break;case 26:case 27:case 5:Ae(w);break;case 4:Ee();break;case 31:w.memoizedState!==null&&ol(w);break;case 13:ol(w);break;case 19:X(Ea);break;case 10:Bc(w.type);break;case 22:case 23:ol(w),Kh(),T!==null&&X(uf);break;case 24:Bc(Ha)}}function ay(T,w){try{var N=w.updateQueue,q=N!==null?N.lastEffect:null;if(q!==null){var ne=q.next;N=ne;do{if((N.tag&T)===T){q=void 0;var ue=N.create,Ie=N.inst;q=ue(),Ie.destroy=q}N=N.next}while(N!==ne)}}catch(ot){Wo(w,w.return,ot)}}function Qh(T,w,N){try{var q=w.updateQueue,ne=q!==null?q.lastEffect:null;if(ne!==null){var ue=ne.next;q=ue;do{if((q.tag&T)===T){var Ie=q.inst,ot=Ie.destroy;if(ot!==void 0){Ie.destroy=void 0,ne=w;var Et=N,tr=ot;try{tr()}catch(yr){Wo(ne,Et,yr)}}}q=q.next}while(q!==ue)}}catch(yr){Wo(w,w.return,yr)}}function n0(T){var w=T.updateQueue;if(w!==null){var N=T.stateNode;try{Yp(w,N)}catch(q){Wo(T,T.return,q)}}}function wC(T,w,N){N.props=Yu(T.type,T.memoizedProps),N.state=T.memoizedState;try{N.componentWillUnmount()}catch(q){Wo(T,w,q)}}function fc(T,w){try{var N=T.ref;if(N!==null){switch(T.tag){case 26:case 27:case 5:var q=T.stateNode;break;case 30:q=T.stateNode;break;default:q=T.stateNode}typeof N=="function"?T.refCleanup=N(q):N.current=q}}catch(ne){Wo(T,w,ne)}}function Eu(T,w){var N=T.ref,q=T.refCleanup;if(N!==null)if(typeof q=="function")try{q()}catch(ne){Wo(T,w,ne)}finally{T.refCleanup=null,T=T.alternate,T!=null&&(T.refCleanup=null)}else if(typeof N=="function")try{N(null)}catch(ne){Wo(T,w,ne)}else N.current=null}function MR(T){var w=T.type,N=T.memoizedProps,q=T.stateNode;try{e:switch(w){case"button":case"input":case"select":case"textarea":N.autoFocus&&q.focus();break e;case"img":N.src?q.src=N.src:N.srcSet&&(q.srcset=N.srcSet)}}catch(ne){Wo(T,T.return,ne)}}function l_(T,w,N){try{var q=T.stateNode;y2(q,T.type,N,w),q[gr]=w}catch(ne){Wo(T,T.return,ne)}}function LR(T){return T.tag===5||T.tag===3||T.tag===26||T.tag===27&&Wi(T.type)||T.tag===4}function AC(T){e:for(;;){for(;T.sibling===null;){if(T.return===null||LR(T.return))return null;T=T.return}for(T.sibling.return=T.return,T=T.sibling;T.tag!==5&&T.tag!==6&&T.tag!==18;){if(T.tag===27&&Wi(T.type)||T.flags&2||T.child===null||T.tag===4)continue e;T.child.return=T,T=T.child}if(!(T.flags&2))return T.stateNode}}function OC(T,w,N){var q=T.tag;if(q===5||q===6)T=T.stateNode,w?(N.nodeType===9?N.body:N.nodeName==="HTML"?N.ownerDocument.body:N).insertBefore(T,w):(w=N.nodeType===9?N.body:N.nodeName==="HTML"?N.ownerDocument.body:N,w.appendChild(T),N=N._reactRootContainer,N!=null||w.onclick!==null||(w.onclick=Ta));else if(q!==4&&(q===27&&Wi(T.type)&&(N=T.stateNode,w=null),T=T.child,T!==null))for(OC(T,w,N),T=T.sibling;T!==null;)OC(T,w,N),T=T.sibling}function u_(T,w,N){var q=T.tag;if(q===5||q===6)T=T.stateNode,w?N.insertBefore(T,w):N.appendChild(T);else if(q!==4&&(q===27&&Wi(T.type)&&(N=T.stateNode),T=T.child,T!==null))for(u_(T,w,N),T=T.sibling;T!==null;)u_(T,w,N),T=T.sibling}function kR(T){var w=T.stateNode,N=T.memoizedProps;try{for(var q=T.type,ne=w.attributes;ne.length;)w.removeAttributeNode(ne[0]);Kl(w,q,N),w[mt]=T,w[gr]=N}catch(ue){Wo(T,T.return,ue)}}var ep=!1,Us=!1,DC=!1,IR=typeof WeakSet=="function"?WeakSet:Set,Dl=null;function o2(T,w){if(T=T.containerInfo,b0=D_,T=Le(T),je(T)){if("selectionStart"in T)var N={start:T.selectionStart,end:T.selectionEnd};else e:{N=(N=T.ownerDocument)&&N.defaultView||window;var q=N.getSelection&&N.getSelection();if(q&&q.rangeCount!==0){N=q.anchorNode;var ne=q.anchorOffset,ue=q.focusNode;q=q.focusOffset;try{N.nodeType,ue.nodeType}catch{N=null;break e}var Ie=0,ot=-1,Et=-1,tr=0,yr=0,Pr=T,ir=null;t:for(;;){for(var ar;Pr!==N||ne!==0&&Pr.nodeType!==3||(ot=Ie+ne),Pr!==ue||q!==0&&Pr.nodeType!==3||(Et=Ie+q),Pr.nodeType===3&&(Ie+=Pr.nodeValue.length),(ar=Pr.firstChild)!==null;)ir=Pr,Pr=ar;for(;;){if(Pr===T)break t;if(ir===N&&++tr===ne&&(ot=Ie),ir===ue&&++yr===q&&(Et=Ie),(ar=Pr.nextSibling)!==null)break;Pr=ir,ir=Pr.parentNode}Pr=ar}N=ot===-1||Et===-1?null:{start:ot,end:Et}}else N=null}N=N||{start:0,end:0}}else N=null;for(nT={focusedElem:T,selectionRange:N},D_=!1,Dl=w;Dl!==null;)if(w=Dl,T=w.child,(w.subtreeFlags&1028)!==0&&T!==null)T.return=w,Dl=T;else for(;Dl!==null;){switch(w=Dl,ue=w.alternate,T=w.flags,w.tag){case 0:if((T&4)!==0&&(T=w.updateQueue,T=T!==null?T.events:null,T!==null))for(N=0;N<T.length;N++)ne=T[N],ne.ref.impl=ne.nextImpl;break;case 11:case 15:break;case 1:if((T&1024)!==0&&ue!==null){T=void 0,N=w,ne=ue.memoizedProps,ue=ue.memoizedState,q=N.stateNode;try{var li=Yu(N.type,ne);T=q.getSnapshotBeforeUpdate(li,ue),q.__reactInternalSnapshotBeforeUpdate=T}catch(Ii){Wo(N,N.return,Ii)}}break;case 3:if((T&1024)!==0){if(T=w.stateNode.containerInfo,N=T.nodeType,N===9)P_(T);else if(N===1)switch(T.nodeName){case"HEAD":case"HTML":case"BODY":P_(T);break;default:T.textContent=""}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if((T&1024)!==0)throw Error(n(163))}if(T=w.sibling,T!==null){T.return=w.return,Dl=T;break}Dl=w.return}}function RC(T,w,N){var q=N.flags;switch(N.tag){case 0:case 11:case 15:rp(T,N),q&4&&ay(5,N);break;case 1:if(rp(T,N),q&4)if(T=N.stateNode,w===null)try{T.componentDidMount()}catch(Ie){Wo(N,N.return,Ie)}else{var ne=Yu(N.type,w.memoizedProps);w=w.memoizedState;try{T.componentDidUpdate(ne,w,T.__reactInternalSnapshotBeforeUpdate)}catch(Ie){Wo(N,N.return,Ie)}}q&64&&n0(N),q&512&&fc(N,N.return);break;case 3:if(rp(T,N),q&64&&(T=N.updateQueue,T!==null)){if(w=null,N.child!==null)switch(N.child.tag){case 27:case 5:w=N.child.stateNode;break;case 1:w=N.child.stateNode}try{Yp(T,w)}catch(Ie){Wo(N,N.return,Ie)}}break;case 27:w===null&&q&4&&kR(N);case 26:case 5:rp(T,N),w===null&&q&4&&MR(N),q&512&&fc(N,N.return);break;case 12:rp(T,N);break;case 31:rp(T,N),q&4&&LC(T,N);break;case 13:rp(T,N),q&4&&FR(T,N),q&64&&(T=N.memoizedState,T!==null&&(T=T.dehydrated,T!==null&&(N=y_.bind(null,N),_2(T,N))));break;case 22:if(q=N.memoizedState!==null||ep,!q){w=w!==null&&w.memoizedState!==null||Us,ne=ep;var ue=Us;ep=q,(Us=w)&&!ue?yh(T,N,(N.subtreeFlags&8772)!==0):rp(T,N),ep=ne,Us=ue}break;case 30:break;default:rp(T,N)}}function MC(T){var w=T.alternate;w!==null&&(T.alternate=null,MC(w)),T.child=null,T.deletions=null,T.sibling=null,T.tag===5&&(w=T.stateNode,w!==null&&fi(w)),T.stateNode=null,T.return=null,T.dependencies=null,T.memoizedProps=null,T.memoizedState=null,T.pendingProps=null,T.stateNode=null,T.updateQueue=null}var wa=null,hc=!1;function tp(T,w,N){for(N=N.child;N!==null;)NR(T,w,N),N=N.sibling}function NR(T,w,N){if(Xe&&typeof Xe.onCommitFiberUnmount=="function")try{Xe.onCommitFiberUnmount(kt,N)}catch{}switch(N.tag){case 26:Us||Eu(N,w),tp(T,w,N),N.memoizedState?N.memoizedState.count--:N.stateNode&&(N=N.stateNode,N.parentNode.removeChild(N));break;case 27:Us||Eu(N,w);var q=wa,ne=hc;Wi(N.type)&&(wa=N.stateNode,hc=!1),tp(T,w,N),P0(N.stateNode),wa=q,hc=ne;break;case 5:Us||Eu(N,w);case 6:if(q=wa,ne=hc,wa=null,tp(T,w,N),wa=q,hc=ne,wa!==null)if(hc)try{(wa.nodeType===9?wa.body:wa.nodeName==="HTML"?wa.ownerDocument.body:wa).removeChild(N.stateNode)}catch(ue){Wo(N,w,ue)}else try{wa.removeChild(N.stateNode)}catch(ue){Wo(N,w,ue)}break;case 18:wa!==null&&(hc?(T=wa,aT(T.nodeType===9?T.body:T.nodeName==="HTML"?T.ownerDocument.body:T,N.stateNode),Py(T)):aT(wa,N.stateNode));break;case 4:q=wa,ne=hc,wa=N.stateNode.containerInfo,hc=!0,tp(T,w,N),wa=q,hc=ne;break;case 0:case 11:case 14:case 15:Qh(2,N,w),Us||Qh(4,N,w),tp(T,w,N);break;case 1:Us||(Eu(N,w),q=N.stateNode,typeof q.componentWillUnmount=="function"&&wC(N,w,q)),tp(T,w,N);break;case 21:tp(T,w,N);break;case 22:Us=(q=Us)||N.memoizedState!==null,tp(T,w,N),Us=q;break;default:tp(T,w,N)}}function LC(T,w){if(w.memoizedState===null&&(T=w.alternate,T!==null&&(T=T.memoizedState,T!==null))){T=T.dehydrated;try{Py(T)}catch(N){Wo(w,w.return,N)}}}function FR(T,w){if(w.memoizedState===null&&(T=w.alternate,T!==null&&(T=T.memoizedState,T!==null&&(T=T.dehydrated,T!==null))))try{Py(T)}catch(N){Wo(w,w.return,N)}}function a2(T){switch(T.tag){case 31:case 13:case 19:var w=T.stateNode;return w===null&&(w=T.stateNode=new IR),w;case 22:return T=T.stateNode,w=T._retryCache,w===null&&(w=T._retryCache=new IR),w;default:throw Error(n(435,T.tag))}}function c_(T,w){var N=a2(T);w.forEach(function(q){if(!N.has(q)){N.add(q);var ne=h2.bind(null,T,q);q.then(ne,ne)}})}function pc(T,w){var N=w.deletions;if(N!==null)for(var q=0;q<N.length;q++){var ne=N[q],ue=T,Ie=w,ot=Ie;e:for(;ot!==null;){switch(ot.tag){case 27:if(Wi(ot.type)){wa=ot.stateNode,hc=!1;break e}break;case 5:wa=ot.stateNode,hc=!1;break e;case 3:case 4:wa=ot.stateNode.containerInfo,hc=!0;break e}ot=ot.return}if(wa===null)throw Error(n(160));NR(ue,Ie,ne),wa=null,hc=!1,ue=ne.alternate,ue!==null&&(ue.return=null),ne.return=null}if(w.subtreeFlags&13886)for(w=w.child;w!==null;)BR(w,T),w=w.sibling}var hf=null;function BR(T,w){var N=T.alternate,q=T.flags;switch(T.tag){case 0:case 11:case 14:case 15:pc(w,T),Aa(T),q&4&&(Qh(3,T,T.return),ay(3,T),Qh(5,T,T.return));break;case 1:pc(w,T),Aa(T),q&512&&(Us||N===null||Eu(N,N.return)),q&64&&ep&&(T=T.updateQueue,T!==null&&(q=T.callbacks,q!==null&&(N=T.shared.hiddenCallbacks,T.shared.hiddenCallbacks=N===null?q:N.concat(q))));break;case 26:var ne=hf;if(pc(w,T),Aa(T),q&512&&(Us||N===null||Eu(N,N.return)),q&4){var ue=N!==null?N.memoizedState:null;if(q=T.memoizedState,N===null)if(q===null)if(T.stateNode===null){e:{q=T.type,N=T.memoizedProps,ne=ne.ownerDocument||ne;t:switch(q){case"title":ue=ne.getElementsByTagName("title")[0],(!ue||ue[zr]||ue[mt]||ue.namespaceURI==="http://www.w3.org/2000/svg"||ue.hasAttribute("itemprop"))&&(ue=ne.createElement(q),ne.head.insertBefore(ue,ne.querySelector("head > title"))),Kl(ue,q,N),ue[mt]=T,si(ue),q=ue;break e;case"link":var Ie=xM("link","href",ne).get(q+(N.href||""));if(Ie){for(var ot=0;ot<Ie.length;ot++)if(ue=Ie[ot],ue.getAttribute("href")===(N.href==null||N.href===""?null:N.href)&&ue.getAttribute("rel")===(N.rel==null?null:N.rel)&&ue.getAttribute("title")===(N.title==null?null:N.title)&&ue.getAttribute("crossorigin")===(N.crossOrigin==null?null:N.crossOrigin)){Ie.splice(ot,1);break t}}ue=ne.createElement(q),Kl(ue,q,N),ne.head.appendChild(ue);break;case"meta":if(Ie=xM("meta","content",ne).get(q+(N.content||""))){for(ot=0;ot<Ie.length;ot++)if(ue=Ie[ot],ue.getAttribute("content")===(N.content==null?null:""+N.content)&&ue.getAttribute("name")===(N.name==null?null:N.name)&&ue.getAttribute("property")===(N.property==null?null:N.property)&&ue.getAttribute("http-equiv")===(N.httpEquiv==null?null:N.httpEquiv)&&ue.getAttribute("charset")===(N.charSet==null?null:N.charSet)){Ie.splice(ot,1);break t}}ue=ne.createElement(q),Kl(ue,q,N),ne.head.appendChild(ue);break;default:throw Error(n(468,q))}ue[mt]=T,si(ue),q=ue}T.stateNode=q}else EM(ne,T.type,T.stateNode);else T.stateNode=TM(ne,q,T.memoizedProps);else ue!==q?(ue===null?N.stateNode!==null&&(N=N.stateNode,N.parentNode.removeChild(N)):ue.count--,q===null?EM(ne,T.type,T.stateNode):TM(ne,q,T.memoizedProps)):q===null&&T.stateNode!==null&&l_(T,T.memoizedProps,N.memoizedProps)}break;case 27:pc(w,T),Aa(T),q&512&&(Us||N===null||Eu(N,N.return)),N!==null&&q&4&&l_(T,T.memoizedProps,N.memoizedProps);break;case 5:if(pc(w,T),Aa(T),q&512&&(Us||N===null||Eu(N,N.return)),T.flags&32){ne=T.stateNode;try{oa(ne,"")}catch(li){Wo(T,T.return,li)}}q&4&&T.stateNode!=null&&(ne=T.memoizedProps,l_(T,ne,N!==null?N.memoizedProps:ne)),q&1024&&(DC=!0);break;case 6:if(pc(w,T),Aa(T),q&4){if(T.stateNode===null)throw Error(n(162));q=T.memoizedProps,N=T.stateNode;try{N.nodeValue=q}catch(li){Wo(T,T.return,li)}}break;case 3:if(C0=null,ne=hf,hf=T_(w.containerInfo),pc(w,T),hf=ne,Aa(T),q&4&&N!==null&&N.memoizedState.isDehydrated)try{Py(w.containerInfo)}catch(li){Wo(T,T.return,li)}DC&&(DC=!1,jR(T));break;case 4:q=hf,hf=T_(T.stateNode.containerInfo),pc(w,T),Aa(T),hf=q;break;case 12:pc(w,T),Aa(T);break;case 31:pc(w,T),Aa(T),q&4&&(q=T.updateQueue,q!==null&&(T.updateQueue=null,c_(T,q)));break;case 13:pc(w,T),Aa(T),T.child.flags&8192&&T.memoizedState!==null!=(N!==null&&N.memoizedState!==null)&&(u0=Qe()),q&4&&(q=T.updateQueue,q!==null&&(T.updateQueue=null,c_(T,q)));break;case 22:ne=T.memoizedState!==null;var Et=N!==null&&N.memoizedState!==null,tr=ep,yr=Us;if(ep=tr||ne,Us=yr||Et,pc(w,T),Us=yr,ep=tr,Aa(T),q&8192)e:for(w=T.stateNode,w._visibility=ne?w._visibility&-2:w._visibility|1,ne&&(N===null||Et||ep||Us||Zg(T)),N=null,w=T;;){if(w.tag===5||w.tag===26){if(N===null){Et=N=w;try{if(ue=Et.stateNode,ne)Ie=ue.style,typeof Ie.setProperty=="function"?Ie.setProperty("display","none","important"):Ie.display="none";else{ot=Et.stateNode;var Pr=Et.memoizedProps.style,ir=Pr!=null&&Pr.hasOwnProperty("display")?Pr.display:null;ot.style.display=ir==null||typeof ir=="boolean"?"":(""+ir).trim()}}catch(li){Wo(Et,Et.return,li)}}}else if(w.tag===6){if(N===null){Et=w;try{Et.stateNode.nodeValue=ne?"":Et.memoizedProps}catch(li){Wo(Et,Et.return,li)}}}else if(w.tag===18){if(N===null){Et=w;try{var ar=Et.stateNode;ne?Zc(ar,!0):Zc(Et.stateNode,!1)}catch(li){Wo(Et,Et.return,li)}}}else if((w.tag!==22&&w.tag!==23||w.memoizedState===null||w===T)&&w.child!==null){w.child.return=w,w=w.child;continue}if(w===T)break e;for(;w.sibling===null;){if(w.return===null||w.return===T)break e;N===w&&(N=null),w=w.return}N===w&&(N=null),w.sibling.return=w.return,w=w.sibling}q&4&&(q=T.updateQueue,q!==null&&(N=q.retryQueue,N!==null&&(q.retryQueue=null,c_(T,N))));break;case 19:pc(w,T),Aa(T),q&4&&(q=T.updateQueue,q!==null&&(T.updateQueue=null,c_(T,q)));break;case 30:break;case 21:break;default:pc(w,T),Aa(T)}}function Aa(T){var w=T.flags;if(w&2){try{for(var N,q=T.return;q!==null;){if(LR(q)){N=q;break}q=q.return}if(N==null)throw Error(n(160));switch(N.tag){case 27:var ne=N.stateNode,ue=AC(T);u_(T,ue,ne);break;case 5:var Ie=N.stateNode;N.flags&32&&(oa(Ie,""),N.flags&=-33);var ot=AC(T);u_(T,ot,Ie);break;case 3:case 4:var Et=N.stateNode.containerInfo,tr=AC(T);OC(T,tr,Et);break;default:throw Error(n(161))}}catch(yr){Wo(T,T.return,yr)}T.flags&=-3}w&4096&&(T.flags&=-4097)}function jR(T){if(T.subtreeFlags&1024)for(T=T.child;T!==null;){var w=T;jR(w),w.tag===5&&w.flags&1024&&w.stateNode.reset(),T=T.sibling}}function rp(T,w){if(w.subtreeFlags&8772)for(w=w.child;w!==null;)RC(T,w.alternate,w),w=w.sibling}function Zg(T){for(T=T.child;T!==null;){var w=T;switch(w.tag){case 0:case 11:case 14:case 15:Qh(4,w,w.return),Zg(w);break;case 1:Eu(w,w.return);var N=w.stateNode;typeof N.componentWillUnmount=="function"&&wC(w,w.return,N),Zg(w);break;case 27:P0(w.stateNode);case 26:case 5:Eu(w,w.return),Zg(w);break;case 22:w.memoizedState===null&&Zg(w);break;case 30:Zg(w);break;default:Zg(w)}T=T.sibling}}function yh(T,w,N){for(N=N&&(w.subtreeFlags&8772)!==0,w=w.child;w!==null;){var q=w.alternate,ne=T,ue=w,Ie=ue.flags;switch(ue.tag){case 0:case 11:case 15:yh(ne,ue,N),ay(4,ue);break;case 1:if(yh(ne,ue,N),q=ue,ne=q.stateNode,typeof ne.componentDidMount=="function")try{ne.componentDidMount()}catch(tr){Wo(q,q.return,tr)}if(q=ue,ne=q.updateQueue,ne!==null){var ot=q.stateNode;try{var Et=ne.shared.hiddenCallbacks;if(Et!==null)for(ne.shared.hiddenCallbacks=null,ne=0;ne<Et.length;ne++)Wu(Et[ne],ot)}catch(tr){Wo(q,q.return,tr)}}N&&Ie&64&&n0(ue),fc(ue,ue.return);break;case 27:kR(ue);case 26:case 5:yh(ne,ue,N),N&&q===null&&Ie&4&&MR(ue),fc(ue,ue.return);break;case 12:yh(ne,ue,N);break;case 31:yh(ne,ue,N),N&&Ie&4&&LC(ne,ue);break;case 13:yh(ne,ue,N),N&&Ie&4&&FR(ne,ue);break;case 22:ue.memoizedState===null&&yh(ne,ue,N),fc(ue,ue.return);break;case 30:break;default:yh(ne,ue,N)}w=w.sibling}}function kC(T,w){var N=null;T!==null&&T.memoizedState!==null&&T.memoizedState.cachePool!==null&&(N=T.memoizedState.cachePool.pool),T=null,w.memoizedState!==null&&w.memoizedState.cachePool!==null&&(T=w.memoizedState.cachePool.pool),T!==N&&(T!=null&&T.refCount++,N!=null&&Gh(N))}function IC(T,w){T=null,w.alternate!==null&&(T=w.alternate.memoizedState.cache),w=w.memoizedState.cache,w!==T&&(w.refCount++,T!=null&&Gh(T))}function pf(T,w,N,q){if(w.subtreeFlags&10256)for(w=w.child;w!==null;)VR(T,w,N,q),w=w.sibling}function VR(T,w,N,q){var ne=w.flags;switch(w.tag){case 0:case 11:case 15:pf(T,w,N,q),ne&2048&&ay(9,w);break;case 1:pf(T,w,N,q);break;case 3:pf(T,w,N,q),ne&2048&&(T=null,w.alternate!==null&&(T=w.alternate.memoizedState.cache),w=w.memoizedState.cache,w!==T&&(w.refCount++,T!=null&&Gh(T)));break;case 12:if(ne&2048){pf(T,w,N,q),T=w.stateNode;try{var ue=w.memoizedProps,Ie=ue.id,ot=ue.onPostCommit;typeof ot=="function"&&ot(Ie,w.alternate===null?"mount":"update",T.passiveEffectDuration,-0)}catch(Et){Wo(w,w.return,Et)}}else pf(T,w,N,q);break;case 31:pf(T,w,N,q);break;case 13:pf(T,w,N,q);break;case 23:break;case 22:ue=w.stateNode,Ie=w.alternate,w.memoizedState!==null?ue._visibility&2?pf(T,w,N,q):o0(T,w):ue._visibility&2?pf(T,w,N,q):(ue._visibility|=2,Qp(T,w,N,q,(w.subtreeFlags&10256)!==0||!1)),ne&2048&&kC(Ie,w);break;case 24:pf(T,w,N,q),ne&2048&&IC(w.alternate,w);break;default:pf(T,w,N,q)}}function Qp(T,w,N,q,ne){for(ne=ne&&((w.subtreeFlags&10256)!==0||!1),w=w.child;w!==null;){var ue=T,Ie=w,ot=N,Et=q,tr=Ie.flags;switch(Ie.tag){case 0:case 11:case 15:Qp(ue,Ie,ot,Et,ne),ay(8,Ie);break;case 23:break;case 22:var yr=Ie.stateNode;Ie.memoizedState!==null?yr._visibility&2?Qp(ue,Ie,ot,Et,ne):o0(ue,Ie):(yr._visibility|=2,Qp(ue,Ie,ot,Et,ne)),ne&&tr&2048&&kC(Ie.alternate,Ie);break;case 24:Qp(ue,Ie,ot,Et,ne),ne&&tr&2048&&IC(Ie.alternate,Ie);break;default:Qp(ue,Ie,ot,Et,ne)}w=w.sibling}}function o0(T,w){if(w.subtreeFlags&10256)for(w=w.child;w!==null;){var N=T,q=w,ne=q.flags;switch(q.tag){case 22:o0(N,q),ne&2048&&kC(q.alternate,q);break;case 24:o0(N,q),ne&2048&&IC(q.alternate,q);break;default:o0(N,q)}w=w.sibling}}var a0=8192;function sy(T,w,N){if(T.subtreeFlags&a0)for(T=T.child;T!==null;)HR(T,w,N),T=T.sibling}function HR(T,w,N){switch(T.tag){case 26:sy(T,w,N),T.flags&a0&&T.memoizedState!==null&&by(N,hf,T.memoizedState,T.memoizedProps);break;case 5:sy(T,w,N);break;case 3:case 4:var q=hf;hf=T_(T.stateNode.containerInfo),sy(T,w,N),hf=q;break;case 22:T.memoizedState===null&&(q=T.alternate,q!==null&&q.memoizedState!==null?(q=a0,a0=16777216,sy(T,w,N),a0=q):sy(T,w,N));break;default:sy(T,w,N)}}function UR(T){var w=T.alternate;if(w!==null&&(T=w.child,T!==null)){w.child=null;do w=T.sibling,T.sibling=null,T=w;while(T!==null)}}function s0(T){var w=T.deletions;if((T.flags&16)!==0){if(w!==null)for(var N=0;N<w.length;N++){var q=w[N];Dl=q,$R(q,T)}UR(T)}if(T.subtreeFlags&10256)for(T=T.child;T!==null;)zR(T),T=T.sibling}function zR(T){switch(T.tag){case 0:case 11:case 15:s0(T),T.flags&2048&&Qh(9,T,T.return);break;case 3:s0(T);break;case 12:s0(T);break;case 22:var w=T.stateNode;T.memoizedState!==null&&w._visibility&2&&(T.return===null||T.return.tag!==13)?(w._visibility&=-3,d_(T)):s0(T);break;default:s0(T)}}function d_(T){var w=T.deletions;if((T.flags&16)!==0){if(w!==null)for(var N=0;N<w.length;N++){var q=w[N];Dl=q,$R(q,T)}UR(T)}for(T=T.child;T!==null;){switch(w=T,w.tag){case 0:case 11:case 15:Qh(8,w,w.return),d_(w);break;case 22:N=w.stateNode,N._visibility&2&&(N._visibility&=-3,d_(w));break;default:d_(w)}T=T.sibling}}function $R(T,w){for(;Dl!==null;){var N=Dl;switch(N.tag){case 0:case 11:case 15:Qh(8,N,w);break;case 23:case 22:if(N.memoizedState!==null&&N.memoizedState.cachePool!==null){var q=N.memoizedState.cachePool.pool;q!=null&&q.refCount++}break;case 24:Gh(N.memoizedState.cache)}if(q=N.child,q!==null)q.return=N,Dl=q;else e:for(N=T;Dl!==null;){q=Dl;var ne=q.sibling,ue=q.return;if(MC(q),q===N){Dl=null;break e}if(ne!==null){ne.return=ue,Dl=ne;break e}Dl=ue}}}var s2={getCacheForType:function(T){var w=_s(Ha),N=w.data.get(T);return N===void 0&&(N=T(),w.data.set(T,N)),N},cacheSignal:function(){return _s(Ha).controller.signal}},l2=typeof WeakMap=="function"?WeakMap:Map,Oo=0,ua=null,Un=null,Xn=0,$o=0,Gc=null,eg=!1,ly=!1,NC=!1,gf=0,Ka=0,tg=0,Jg=0,FC=0,Yc=0,uy=0,l0=null,gc=null,BC=!1,u0=0,WR=0,Qg=1/0,f_=null,rg=null,ll=0,ig=null,cy=null,ip=0,jC=0,VC=null,GR=null,c0=0,HC=null;function qc(){return(Oo&2)!==0&&Xn!==0?Xn&-Xn:V.T!==null?Xc():ri()}function YR(){if(Yc===0)if((Xn&536870912)===0||kn){var T=Mr;Mr<<=1,(Mr&3932160)===0&&(Mr=262144),Yc=T}else Yc=536870912;return T=ql.current,T!==null&&(T.flags|=32),Yc}function vc(T,w,N){(T===ua&&($o===2||$o===9)||T.cancelPendingCommit!==null)&&(dy(T,0),np(T,Xn,Yc,!1)),Si(T,N),((Oo&2)===0||T!==ua)&&(T===ua&&((Oo&2)===0&&(Jg|=N),Ka===4&&np(T,Xn,Yc,!1)),mh(T))}function qR(T,w,N){if((Oo&6)!==0)throw Error(n(327));var q=!N&&(w&127)===0&&(w&T.expiredLanes)===0||Tt(T,w),ne=q?c2(T,w):zC(T,w,!0),ue=q;do{if(ne===0){ly&&!q&&np(T,w,0,!1);break}else{if(N=T.current.alternate,ue&&!KR(N)){ne=zC(T,w,!1),ue=!1;continue}if(ne===2){if(ue=w,T.errorRecoveryDisabledLanes&ue)var Ie=0;else Ie=T.pendingLanes&-536870913,Ie=Ie!==0?Ie:Ie&536870912?536870912:0;if(Ie!==0){w=Ie;e:{var ot=T;ne=l0;var Et=ot.current.memoizedState.isDehydrated;if(Et&&(dy(ot,Ie).flags|=256),Ie=zC(ot,Ie,!1),Ie!==2){if(NC&&!Et){ot.errorRecoveryDisabledLanes|=ue,Jg|=ue,ne=4;break e}ue=gc,gc=ne,ue!==null&&(gc===null?gc=ue:gc.push.apply(gc,ue))}ne=Ie}if(ue=!1,ne!==2)continue}}if(ne===1){dy(T,0),np(T,w,0,!0);break}e:{switch(q=T,ue=ne,ue){case 0:case 1:throw Error(n(345));case 4:if((w&4194048)!==w)break;case 6:np(q,w,Yc,!eg);break e;case 2:gc=null;break;case 3:case 5:break;default:throw Error(n(329))}if((w&62914560)===w&&(ne=u0+300-Qe(),10<ne)){if(np(q,w,Yc,!eg),dt(q,0,!0)!==0)break e;ip=w,q.timeoutHandle=hM(XR.bind(null,q,N,gc,f_,BC,w,Yc,Jg,uy,eg,ue,"Throttled",-0,0),ne);break e}XR(q,N,gc,f_,BC,w,Yc,Jg,uy,eg,ue,null,-0,0)}}break}while(!0);mh(T)}function XR(T,w,N,q,ne,ue,Ie,ot,Et,tr,yr,Pr,ir,ar){if(T.timeoutHandle=-1,Pr=w.subtreeFlags,Pr&8192||(Pr&16785408)===16785408){Pr={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:Ta},HR(w,ue,Pr);var li=(ue&62914560)===ue?u0-Qe():(ue&4194048)===ue?WR-Qe():0;if(li=D2(Pr,li),li!==null){ip=ue,T.cancelPendingCommit=li(rM.bind(null,T,w,ue,N,q,ne,Ie,ot,Et,yr,Pr,null,ir,ar)),np(T,ue,Ie,!tr);return}}rM(T,w,ue,N,q,ne,Ie,ot,Et)}function KR(T){for(var w=T;;){var N=w.tag;if((N===0||N===11||N===15)&&w.flags&16384&&(N=w.updateQueue,N!==null&&(N=N.stores,N!==null)))for(var q=0;q<N.length;q++){var ne=N[q],ue=ne.getSnapshot;ne=ne.value;try{if(!Ke(ue(),ne))return!1}catch{return!1}}if(N=w.child,w.subtreeFlags&16384&&N!==null)N.return=w,w=N;else{if(w===T)break;for(;w.sibling===null;){if(w.return===null||w.return===T)return!0;w=w.return}w.sibling.return=w.return,w=w.sibling}}return!0}function np(T,w,N,q){w&=~FC,w&=~Jg,T.suspendedLanes|=w,T.pingedLanes&=~w,q&&(T.warmLanes|=w),q=T.expirationTimes;for(var ne=w;0<ne;){var ue=31-Ht(ne),Ie=1<<ue;q[ue]=-1,ne&=~Ie}N!==0&&Yr(T,N,w)}function h_(){return(Oo&6)===0?(g0(0),!1):!0}function UC(){if(Un!==null){if($o===0)var T=Un.return;else T=Un,Fc=nn=null,O(T),Vc=null,Yl=0,T=Un;for(;T!==null;)s_(T.alternate,T),T=T.return;Un=null}}function dy(T,w){var N=T.timeoutHandle;N!==-1&&(T.timeoutHandle=-1,b2(N)),N=T.cancelPendingCommit,N!==null&&(T.cancelPendingCommit=null,N()),ip=0,UC(),ua=T,Un=N=Wl(T.current,null),Xn=w,$o=0,Gc=null,eg=!1,ly=Tt(T,w),NC=!1,uy=Yc=FC=Jg=tg=Ka=0,gc=l0=null,BC=!1,(w&8)!==0&&(w|=w&32);var q=T.entangledLanes;if(q!==0)for(T=T.entanglements,q&=w;0<q;){var ne=31-Ht(q),ue=1<<ne;w|=T[ne],q&=~ue}return gf=w,Or(),N}function ZR(T,w){xi=null,V.H=Zp,w===ch||w===qh?(w=ey(),$o=3):w===Up?(w=ey(),$o=4):$o=w===Xm?8:w!==null&&typeof w=="object"&&typeof w.then=="function"?6:1,Gc=w,Un===null&&(Ka=1,qm(T,Pl(w,T.current)))}function d0(){var T=ql.current;return T===null?!0:(Xn&4194048)===Xn?El===null:(Xn&62914560)===Xn||(Xn&536870912)!==0?T===El:!1}function JR(){var T=V.H;return V.H=Zp,T===null?Zp:T}function QR(){var T=V.A;return V.A=s2,T}function p_(){Ka=4,eg||(Xn&4194048)!==Xn&&ql.current!==null||(ly=!0),(tg&134217727)===0&&(Jg&134217727)===0||ua===null||np(ua,Xn,Yc,!1)}function zC(T,w,N){var q=Oo;Oo|=2;var ne=JR(),ue=QR();(ua!==T||Xn!==w)&&(f_=null,dy(T,w)),w=!1;var Ie=Ka;e:do try{if($o!==0&&Un!==null){var ot=Un,Et=Gc;switch($o){case 8:UC(),Ie=6;break e;case 3:case 2:case 9:case 6:ql.current===null&&(w=!0);var tr=$o;if($o=0,Gc=null,fy(T,ot,Et,tr),N&&ly){Ie=0;break e}break;default:tr=$o,$o=0,Gc=null,fy(T,ot,Et,tr)}}u2(),Ie=Ka;break}catch(yr){ZR(T,yr)}while(!0);return w&&T.shellSuspendCounter++,Fc=nn=null,Oo=q,V.H=ne,V.A=ue,Un===null&&(ua=null,Xn=0,Or()),Ie}function u2(){for(;Un!==null;)eM(Un)}function c2(T,w){var N=Oo;Oo|=2;var q=JR(),ne=QR();ua!==T||Xn!==w?(f_=null,Qg=Qe()+500,dy(T,w)):ly=Tt(T,w);e:do try{if($o!==0&&Un!==null){w=Un;var ue=Gc;t:switch($o){case 1:$o=0,Gc=null,fy(T,w,ue,1);break;case 2:case 9:if(Qv(ue)){$o=0,Gc=null,tM(w);break}w=function(){$o!==2&&$o!==9||ua!==T||($o=7),mh(T)},ue.then(w,w);break e;case 3:$o=7;break e;case 4:$o=5;break e;case 7:Qv(ue)?($o=0,Gc=null,tM(w)):($o=0,Gc=null,fy(T,w,ue,7));break;case 5:var Ie=null;switch(Un.tag){case 26:Ie=Un.memoizedState;case 5:case 27:var ot=Un;if(Ie?wM(Ie):ot.stateNode.complete){$o=0,Gc=null;var Et=ot.sibling;if(Et!==null)Un=Et;else{var tr=ot.return;tr!==null?(Un=tr,g_(tr)):Un=null}break t}}$o=0,Gc=null,fy(T,w,ue,5);break;case 6:$o=0,Gc=null,fy(T,w,ue,6);break;case 8:UC(),Ka=6;break e;default:throw Error(n(462))}}d2();break}catch(yr){ZR(T,yr)}while(!0);return Fc=nn=null,V.H=q,V.A=ne,Oo=N,Un!==null?0:(ua=null,Xn=0,Or(),Ka)}function d2(){for(;Un!==null&&!Ce();)eM(Un)}function eM(T){var w=DR(T.alternate,T,gf);T.memoizedProps=T.pendingProps,w===null?g_(T):Un=w}function tM(T){var w=T,N=w.alternate;switch(w.tag){case 15:case 0:w=wR(N,w,w.pendingProps,w.type,void 0,Xn);break;case 11:w=wR(N,w,w.pendingProps,w.type.render,w.ref,Xn);break;case 5:O(w);default:s_(N,w),w=Un=Tr(w,gf),w=DR(N,w,gf)}T.memoizedProps=T.pendingProps,w===null?g_(T):Un=w}function fy(T,w,N,q){Fc=nn=null,O(w),Vc=null,Yl=0;var ne=w.return;try{if(SC(T,ne,w,N,Xn)){Ka=1,qm(T,Pl(N,T.current)),Un=null;return}}catch(ue){if(ne!==null)throw Un=ne,ue;Ka=1,qm(T,Pl(N,T.current)),Un=null;return}w.flags&32768?(kn||q===1?T=!0:ly||(Xn&536870912)!==0?T=!1:(eg=T=!0,(q===2||q===9||q===3||q===6)&&(q=ql.current,q!==null&&q.tag===13&&(q.flags|=16384))),f0(w,T)):g_(w)}function g_(T){var w=T;do{if((w.flags&32768)!==0){f0(w,eg);return}T=w.return;var N=RR(w.alternate,w,gf);if(N!==null){Un=N;return}if(w=w.sibling,w!==null){Un=w;return}Un=w=T}while(w!==null);Ka===0&&(Ka=5)}function f0(T,w){do{var N=i0(T.alternate,T);if(N!==null){N.flags&=32767,Un=N;return}if(N=T.return,N!==null&&(N.flags|=32768,N.subtreeFlags=0,N.deletions=null),!w&&(T=T.sibling,T!==null)){Un=T;return}Un=T=N}while(T!==null);Ka=6,Un=null}function rM(T,w,N,q,ne,ue,Ie,ot,Et){T.cancelPendingCommit=null;do h0();while(ll!==0);if((Oo&6)!==0)throw Error(n(327));if(w!==null){if(w===T.current)throw Error(n(177));if(ue=w.lanes|w.childLanes,ue|=rf,oi(T,N,ue,Ie,ot,Et),T===ua&&(Un=ua=null,Xn=0),cy=w,ig=T,ip=N,jC=ue,VC=ne,GR=q,(w.subtreeFlags&10256)!==0||(w.flags&10256)!==0?(T.callbackNode=null,T.callbackPriority=0,p2($t,function(){return YC(),null})):(T.callbackNode=null,T.callbackPriority=0),q=(w.flags&13878)!==0,(w.subtreeFlags&13878)!==0||q){q=V.T,V.T=null,ne=z.p,z.p=2,Ie=Oo,Oo|=4;try{o2(T,w,N)}finally{Oo=Ie,z.p=ne,V.T=q}}ll=1,$C(),WC(),v_()}}function $C(){if(ll===1){ll=0;var T=ig,w=cy,N=(w.flags&13878)!==0;if((w.subtreeFlags&13878)!==0||N){N=V.T,V.T=null;var q=z.p;z.p=2;var ne=Oo;Oo|=4;try{BR(w,T);var ue=nT,Ie=Le(T.containerInfo),ot=ue.focusedElem,Et=ue.selectionRange;if(Ie!==ot&&ot&&ot.ownerDocument&&xe(ot.ownerDocument.documentElement,ot)){if(Et!==null&&je(ot)){var tr=Et.start,yr=Et.end;if(yr===void 0&&(yr=tr),"selectionStart"in ot)ot.selectionStart=tr,ot.selectionEnd=Math.min(yr,ot.value.length);else{var Pr=ot.ownerDocument||document,ir=Pr&&Pr.defaultView||window;if(ir.getSelection){var ar=ir.getSelection(),li=ot.textContent.length,Ii=Math.min(Et.start,li),Jo=Et.end===void 0?Ii:Math.min(Et.end,li);!ar.extend&&Ii>Jo&&(Ie=Jo,Jo=Ii,Ii=Ie);var Wt=be(ot,Ii),It=be(ot,Jo);if(Wt&&It&&(ar.rangeCount!==1||ar.anchorNode!==Wt.node||ar.anchorOffset!==Wt.offset||ar.focusNode!==It.node||ar.focusOffset!==It.offset)){var Qt=Pr.createRange();Qt.setStart(Wt.node,Wt.offset),ar.removeAllRanges(),Ii>Jo?(ar.addRange(Qt),ar.extend(It.node,It.offset)):(Qt.setEnd(It.node,It.offset),ar.addRange(Qt))}}}}for(Pr=[],ar=ot;ar=ar.parentNode;)ar.nodeType===1&&Pr.push({element:ar,left:ar.scrollLeft,top:ar.scrollTop});for(typeof ot.focus=="function"&&ot.focus(),ot=0;ot<Pr.length;ot++){var Sr=Pr[ot];Sr.element.scrollLeft=Sr.left,Sr.element.scrollTop=Sr.top}}D_=!!b0,nT=b0=null}finally{Oo=ne,z.p=q,V.T=N}}T.current=w,ll=2}}function WC(){if(ll===2){ll=0;var T=ig,w=cy,N=(w.flags&8772)!==0;if((w.subtreeFlags&8772)!==0||N){N=V.T,V.T=null;var q=z.p;z.p=2;var ne=Oo;Oo|=4;try{RC(T,w.alternate,w)}finally{Oo=ne,z.p=q,V.T=N}}ll=3}}function v_(){if(ll===4||ll===3){ll=0,Ue();var T=ig,w=cy,N=ip,q=GR;(w.subtreeFlags&10256)!==0||(w.flags&10256)!==0?ll=5:(ll=0,cy=ig=null,GC(T,T.pendingLanes));var ne=T.pendingLanes;if(ne===0&&(rg=null),qn(N),w=w.stateNode,Xe&&typeof Xe.onCommitFiberRoot=="function")try{Xe.onCommitFiberRoot(kt,w,void 0,(w.current.flags&128)===128)}catch{}if(q!==null){w=V.T,ne=z.p,z.p=2,V.T=null;try{for(var ue=T.onRecoverableError,Ie=0;Ie<q.length;Ie++){var ot=q[Ie];ue(ot.value,{componentStack:ot.stack})}}finally{V.T=w,z.p=ne}}(ip&3)!==0&&h0(),mh(T),ne=T.pendingLanes,(N&261930)!==0&&(ne&42)!==0?T===HC?c0++:(c0=0,HC=T):c0=0,g0(0)}}function GC(T,w){(T.pooledCacheLanes&=w)===0&&(w=T.pooledCache,w!=null&&(T.pooledCache=null,Gh(w)))}function h0(){return $C(),WC(),v_(),YC()}function YC(){if(ll!==5)return!1;var T=ig,w=jC;jC=0;var N=qn(ip),q=V.T,ne=z.p;try{z.p=32>N?32:N,V.T=null,N=VC,VC=null;var ue=ig,Ie=ip;if(ll=0,cy=ig=null,ip=0,(Oo&6)!==0)throw Error(n(331));var ot=Oo;if(Oo|=4,zR(ue.current),VR(ue,ue.current,Ie,N),Oo=ot,g0(0,!1),Xe&&typeof Xe.onPostCommitFiberRoot=="function")try{Xe.onPostCommitFiberRoot(kt,ue)}catch{}return!0}finally{z.p=ne,V.T=q,GC(T,w)}}function qC(T,w,N){w=Pl(N,w),w=bC(T.stateNode,w,2),T=Tu(T,w,2),T!==null&&(Si(T,2),mh(T))}function Wo(T,w,N){if(T.tag===3)qC(T,T,N);else for(;w!==null;){if(w.tag===3){qC(w,T,N);break}else if(w.tag===1){var q=w.stateNode;if(typeof w.type.getDerivedStateFromError=="function"||typeof q.componentDidCatch=="function"&&(rg===null||!rg.has(q))){T=Pl(N,T),N=gh(2),q=Tu(w,N,2),q!==null&&(e_(N,q,w,T),Si(q,2),mh(q));break}}w=w.return}}function XC(T,w,N){var q=T.pingCache;if(q===null){q=T.pingCache=new l2;var ne=new Set;q.set(w,ne)}else ne=q.get(w),ne===void 0&&(ne=new Set,q.set(w,ne));ne.has(N)||(NC=!0,ne.add(N),T=f2.bind(null,T,w,N),w.then(T,T))}function f2(T,w,N){var q=T.pingCache;q!==null&&q.delete(w),T.pingedLanes|=T.suspendedLanes&N,T.warmLanes&=~N,ua===T&&(Xn&N)===N&&(Ka===4||Ka===3&&(Xn&62914560)===Xn&&300>Qe()-u0?(Oo&2)===0&&dy(T,0):FC|=N,uy===Xn&&(uy=0)),mh(T)}function p0(T,w){w===0&&(w=Ar()),T=Rr(T,w),T!==null&&(Si(T,w),mh(T))}function y_(T){var w=T.memoizedState,N=0;w!==null&&(N=w.retryLane),p0(T,N)}function h2(T,w){var N=0;switch(T.tag){case 31:case 13:var q=T.stateNode,ne=T.memoizedState;ne!==null&&(N=ne.retryLane);break;case 19:q=T.stateNode;break;case 22:q=T.stateNode._retryCache;break;default:throw Error(n(314))}q!==null&&q.delete(w),p0(T,N)}function p2(T,w){return fe(T,w)}var hy=null,ev=null,KC=!1,m_=!1,ZC=!1,ng=0;function mh(T){T!==ev&&T.next===null&&(ev===null?hy=ev=T:ev=ev.next=T),m_=!0,KC||(KC=!0,v2())}function g0(T,w){if(!ZC&&m_){ZC=!0;do for(var N=!1,q=hy;q!==null;){if(T!==0){var ne=q.pendingLanes;if(ne===0)var ue=0;else{var Ie=q.suspendedLanes,ot=q.pingedLanes;ue=(1<<31-Ht(42|T)+1)-1,ue&=ne&~(Ie&~ot),ue=ue&201326741?ue&201326741|1:ue?ue|2:0}ue!==0&&(N=!0,aM(q,ue))}else ue=Xn,ue=dt(q,q===ua?ue:0,q.cancelPendingCommit!==null||q.timeoutHandle!==-1),(ue&3)===0||Tt(q,ue)||(N=!0,aM(q,ue));q=q.next}while(N);ZC=!1}}function g2(){iM()}function iM(){m_=KC=!1;var T=0;ng!==0&&m2()&&(T=ng);for(var w=Qe(),N=null,q=hy;q!==null;){var ne=q.next,ue=nM(q,w);ue===0?(q.next=null,N===null?hy=ne:N.next=ne,ne===null&&(ev=N)):(N=q,(T!==0||(ue&3)!==0)&&(m_=!0)),q=ne}ll!==0&&ll!==5||g0(T),ng!==0&&(ng=0)}function nM(T,w){for(var N=T.suspendedLanes,q=T.pingedLanes,ne=T.expirationTimes,ue=T.pendingLanes&-62914561;0<ue;){var Ie=31-Ht(ue),ot=1<<Ie,Et=ne[Ie];Et===-1?((ot&N)===0||(ot&q)!==0)&&(ne[Ie]=nr(ot,w)):Et<=w&&(T.expiredLanes|=ot),ue&=~ot}if(w=ua,N=Xn,N=dt(T,T===w?N:0,T.cancelPendingCommit!==null||T.timeoutHandle!==-1),q=T.callbackNode,N===0||T===w&&($o===2||$o===9)||T.cancelPendingCommit!==null)return q!==null&&q!==null&&me(q),T.callbackNode=null,T.callbackPriority=0;if((N&3)===0||Tt(T,N)){if(w=N&-N,w===T.callbackPriority)return w;switch(q!==null&&me(q),qn(N)){case 2:case 8:N=wt;break;case 32:N=$t;break;case 268435456:N=rt;break;default:N=$t}return q=oM.bind(null,T),N=fe(N,q),T.callbackPriority=w,T.callbackNode=N,w}return q!==null&&q!==null&&me(q),T.callbackPriority=2,T.callbackNode=null,2}function oM(T,w){if(ll!==0&&ll!==5)return T.callbackNode=null,T.callbackPriority=0,null;var N=T.callbackNode;if(h0()&&T.callbackNode!==N)return null;var q=Xn;return q=dt(T,T===ua?q:0,T.cancelPendingCommit!==null||T.timeoutHandle!==-1),q===0?null:(qR(T,q,w),nM(T,Qe()),T.callbackNode!=null&&T.callbackNode===N?oM.bind(null,T):null)}function aM(T,w){if(h0())return null;qR(T,w,!0)}function v2(){gM(function(){(Oo&6)!==0?fe(xt,g2):iM()})}function Xc(){if(ng===0){var T=lh;T===0&&(T=Bt,Bt<<=1,(Bt&261888)===0&&(Bt=256)),ng=T}return ng}function sM(T){return T==null||typeof T=="symbol"||typeof T=="boolean"?null:typeof T=="function"?T:wo(""+T)}function lM(T,w){var N=w.ownerDocument.createElement("input");return N.name=w.name,N.value=w.value,T.id&&N.setAttribute("form",T.id),w.parentNode.insertBefore(N,w),T=new FormData(T),N.parentNode.removeChild(N),T}function tv(T,w,N,q,ne){if(w==="submit"&&N&&N.stateNode===ne){var ue=sM((ne[gr]||null).action),Ie=q.submitter;Ie&&(w=(w=Ie[gr]||null)?sM(w.formAction):Ie.getAttribute("formAction"),w!==null&&(ue=w,Ie=null));var ot=new Ft("action","action",null,q,ne);T.push({event:ot,listeners:[{instance:null,listener:function(){if(q.defaultPrevented){if(ng!==0){var Et=Ie?lM(ne,Ie):new FormData(ne);Kp(N,{pending:!0,data:Et,method:ne.method,action:ue},null,Et)}}else typeof ue=="function"&&(ot.preventDefault(),Et=Ie?lM(ne,Ie):new FormData(ne),Kp(N,{pending:!0,data:Et,method:ne.method,action:ue},ue,Et))},currentTarget:ne}]})}}for(var on=0;on<Po.length;on++){var JC=Po[on],yc=JC.toLowerCase(),Ts=JC[0].toUpperCase()+JC.slice(1);po(yc,"on"+Ts)}po(ho,"onAnimationEnd"),po($l,"onAnimationIteration"),po(rh,"onAnimationStart"),po("dblclick","onDoubleClick"),po("focusin","onFocus"),po("focusout","onBlur"),po(kc,"onTransitionRun"),po(ef,"onTransitionStart"),po(tf,"onTransitionCancel"),po(Mn,"onTransitionEnd"),Z("onMouseEnter",["mouseout","mouseover"]),Z("onMouseLeave",["mouseout","mouseover"]),Z("onPointerEnter",["pointerout","pointerover"]),Z("onPointerLeave",["pointerout","pointerover"]),ts("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),ts("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),ts("onBeforeInput",["compositionend","keypress","textInput","paste"]),ts("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),ts("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),ts("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var v0="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(" "),og=new Set("beforetoggle cancel close invalid load scroll scrollend toggle".split(" ").concat(v0));function uM(T,w){w=(w&4)!==0;for(var N=0;N<T.length;N++){var q=T[N],ne=q.event;q=q.listeners;e:{var ue=void 0;if(w)for(var Ie=q.length-1;0<=Ie;Ie--){var ot=q[Ie],Et=ot.instance,tr=ot.currentTarget;if(ot=ot.listener,Et!==ue&&ne.isPropagationStopped())break e;ue=ot,ne.currentTarget=tr;try{ue(ne)}catch(yr){so(yr)}ne.currentTarget=null,ue=Et}else for(Ie=0;Ie<q.length;Ie++){if(ot=q[Ie],Et=ot.instance,tr=ot.currentTarget,ot=ot.listener,Et!==ue&&ne.isPropagationStopped())break e;ue=ot,ne.currentTarget=tr;try{ue(ne)}catch(yr){so(yr)}ne.currentTarget=null,ue=Et}}}}function zn(T,w){var N=w[fr];N===void 0&&(N=w[fr]=new Set);var q=T+"__bubble";N.has(q)||(S_(w,T,2,!1),N.add(q))}function QC(T,w,N){var q=0;w&&(q|=4),S_(N,T,q,w)}var b_="_reactListening"+Math.random().toString(36).slice(2);function eT(T){if(!T[b_]){T[b_]=!0,sr.forEach(function(N){N!=="selectionchange"&&(og.has(N)||QC(N,!1,T),QC(N,!0,T))});var w=T.nodeType===9?T:T.ownerDocument;w===null||w[b_]||(w[b_]=!0,QC("selectionchange",!1,w))}}function S_(T,w,N,q){switch(IM(w)){case 2:var ne=M2;break;case 8:ne=L2;break;default:ne=fT}N=ne.bind(null,w,N,T),ne=void 0,!Gd||w!=="touchstart"&&w!=="touchmove"&&w!=="wheel"||(ne=!0),q?ne!==void 0?T.addEventListener(w,N,{capture:!0,passive:ne}):T.addEventListener(w,N,!0):ne!==void 0?T.addEventListener(w,N,{passive:ne}):T.addEventListener(w,N,!1)}function tT(T,w,N,q,ne){var ue=q;if((w&1)===0&&(w&2)===0&&q!==null)e:for(;;){if(q===null)return;var Ie=q.tag;if(Ie===3||Ie===4){var ot=q.stateNode.containerInfo;if(ot===ne)break;if(Ie===4)for(Ie=q.return;Ie!==null;){var Et=Ie.tag;if((Et===3||Et===4)&&Ie.stateNode.containerInfo===ne)return;Ie=Ie.return}for(;ot!==null;){if(Ie=to(ot),Ie===null)return;if(Et=Ie.tag,Et===5||Et===6||Et===26||Et===27){q=ue=Ie;continue e}ot=ot.parentNode}}q=q.return}xa(function(){var tr=ue,yr=ao(N),Pr=[];e:{var ir=ya.get(T);if(ir!==void 0){var ar=Ft,li=T;switch(T){case"keypress":if(oc(N)===0)break e;case"keydown":case"keyup":ar=ac;break;case"focusin":li="focus",ar=Sl;break;case"focusout":li="blur",ar=Sl;break;case"beforeblur":case"afterblur":ar=Sl;break;case"click":if(N.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ar=Oi;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ar=ms;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ar=Vg;break;case ho:case $l:case rh:ar=Hu;break;case Mn:ar=Kf;break;case"scroll":case"scrollend":ar=Lt;break;case"wheel":ar=Zf;break;case"copy":case"cut":case"paste":ar=Bs;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ar=pd;break;case"toggle":case"beforetoggle":ar=Ip}var Ii=(w&4)!==0,Jo=!Ii&&(T==="scroll"||T==="scrollend"),Wt=Ii?ir!==null?ir+"Capture":null:ir;Ii=[];for(var It=tr,Qt;It!==null;){var Sr=It;if(Qt=Sr.stateNode,Sr=Sr.tag,Sr!==5&&Sr!==26&&Sr!==27||Qt===null||Wt===null||(Sr=Fa(It,Wt),Sr!=null&&Ii.push(Kc(It,Sr,Qt))),Jo)break;It=It.return}0<Ii.length&&(ir=new ar(ir,li,null,N,yr),Pr.push({event:ir,listeners:Ii}))}}if((w&7)===0){e:{if(ir=T==="mouseover"||T==="pointerover",ar=T==="mouseout"||T==="pointerout",ir&&N!==Lo&&(li=N.relatedTarget||N.fromElement)&&(to(li)||li[ce]))break e;if((ar||ir)&&(ir=yr.window===yr?yr:(ir=yr.ownerDocument)?ir.defaultView||ir.parentWindow:window,ar?(li=N.relatedTarget||N.toElement,ar=tr,li=li?to(li):null,li!==null&&(Jo=o(li),Ii=li.tag,li!==Jo||Ii!==5&&Ii!==27&&Ii!==6)&&(li=null)):(ar=null,li=tr),ar!==li)){if(Ii=Oi,Sr="onMouseLeave",Wt="onMouseEnter",It="mouse",(T==="pointerout"||T==="pointerover")&&(Ii=pd,Sr="onPointerLeave",Wt="onPointerEnter",It="pointer"),Jo=ar==null?ir:zo(ar),Qt=li==null?ir:zo(li),ir=new Ii(Sr,It+"leave",ar,N,yr),ir.target=Jo,ir.relatedTarget=Qt,Sr=null,to(yr)===tr&&(Ii=new Ii(Wt,It+"enter",li,N,yr),Ii.target=Qt,Ii.relatedTarget=Jo,Sr=Ii),Jo=Sr,ar&&li)t:{for(Ii=__,Wt=ar,It=li,Qt=0,Sr=Wt;Sr;Sr=Ii(Sr))Qt++;Sr=0;for(var wi=It;wi;wi=Ii(wi))Sr++;for(;0<Qt-Sr;)Wt=Ii(Wt),Qt--;for(;0<Sr-Qt;)It=Ii(It),Sr--;for(;Qt--;){if(Wt===It||It!==null&&Wt===It.alternate){Ii=Wt;break t}Wt=Ii(Wt),It=Ii(It)}Ii=null}else Ii=null;ar!==null&&za(Pr,ir,ar,Ii,!1),li!==null&&Jo!==null&&za(Pr,Jo,li,Ii,!0)}}e:{if(ir=tr?zo(tr):window,ar=ir.nodeName&&ir.nodeName.toLowerCase(),ar==="select"||ar==="input"&&ir.type==="file")var Co=ns;else if(Uu(ir))if(os)Co=Fp;else{Co=Ug;var gi=th}else ar=ir.nodeName,!ar||ar.toLowerCase()!=="input"||ir.type!=="checkbox"&&ir.type!=="radio"?tr&&ml(tr.elementType)&&(Co=ns):Co=Qd;if(Co&&(Co=Co(T,tr))){Vh(Pr,Co,N,yr);break e}gi&&gi(T,ir,tr),T==="focusout"&&tr&&ir.type==="number"&&tr.memoizedProps.value!=null&&fu(ir,"number",ir.value)}switch(gi=tr?zo(tr):window,T){case"focusin":(Uu(gi)||gi.contentEditable==="true")&&(ze=gi,at=tr,tt=null);break;case"focusout":tt=at=ze=null;break;case"mousedown":pt=!0;break;case"contextmenu":case"mouseup":case"dragend":pt=!1,Ut(Pr,N,yr);break;case"selectionchange":if(ct)break;case"keydown":case"keyup":Ut(Pr,N,yr)}var Pn;if(Xd)e:{switch(T){case"compositionstart":var Kn="onCompositionStart";break e;case"compositionend":Kn="onCompositionEnd";break e;case"compositionupdate":Kn="onCompositionUpdate";break e}Kn=void 0}else Mc?Rc(T,N)&&(Kn="onCompositionEnd"):T==="keydown"&&N.keyCode===229&&(Kn="onCompositionStart");Kn&&(Jf&&N.locale!=="ko"&&(Mc||Kn!=="onCompositionStart"?Kn==="onCompositionEnd"&&Mc&&(Pn=mn()):(il=yr,aa="value"in il?il.value:il.textContent,Mc=!0)),gi=y0(tr,Kn),0<gi.length&&(Kn=new js(Kn,T,null,N,yr),Pr.push({event:Kn,listeners:gi}),Pn?Kn.data=Pn:(Pn=Np(N),Pn!==null&&(Kn.data=Pn)))),(Pn=Kd?nl(T,N):jh(T,N))&&(Kn=y0(tr,"onBeforeInput"),0<Kn.length&&(gi=new js("onBeforeInput","beforeinput",null,N,yr),Pr.push({event:gi,listeners:Kn}),gi.data=Pn)),tv(Pr,T,tr,N,yr)}uM(Pr,w)})}function Kc(T,w,N){return{instance:T,listener:w,currentTarget:N}}function y0(T,w){for(var N=w+"Capture",q=[];T!==null;){var ne=T,ue=ne.stateNode;if(ne=ne.tag,ne!==5&&ne!==26&&ne!==27||ue===null||(ne=Fa(T,N),ne!=null&&q.unshift(Kc(T,ne,ue)),ne=Fa(T,w),ne!=null&&q.push(Kc(T,ne,ue))),T.tag===3)return q;T=T.return}return[]}function __(T){if(T===null)return null;do T=T.return;while(T&&T.tag!==5&&T.tag!==27);return T||null}function za(T,w,N,q,ne){for(var ue=w._reactName,Ie=[];N!==null&&N!==q;){var ot=N,Et=ot.alternate,tr=ot.stateNode;if(ot=ot.tag,Et!==null&&Et===q)break;ot!==5&&ot!==26&&ot!==27||tr===null||(Et=tr,ne?(tr=Fa(N,ue),tr!=null&&Ie.unshift(Kc(N,tr,Et))):ne||(tr=Fa(N,ue),tr!=null&&Ie.push(Kc(N,tr,Et)))),N=N.return}Ie.length!==0&&T.push({event:w,listeners:Ie})}var us=/\r\n?/g,cM=/\u0000|\uFFFD/g;function dM(T){return(typeof T=="string"?T:""+T).replace(us,`
`).replace(cM,"")}function fM(T,w){return w=dM(w),dM(T)===w}function Zo(T,w,N,q,ne,ue){switch(N){case"children":typeof q=="string"?w==="body"||w==="textarea"&&q===""||oa(T,q):(typeof q=="number"||typeof q=="bigint")&&w!=="body"&&oa(T,""+q);break;case"className":pr(T,"class",q);break;case"tabIndex":pr(T,"tabindex",q);break;case"dir":case"role":case"viewBox":case"width":case"height":pr(T,N,q);break;case"style":cd(T,q,ue);break;case"data":if(w!=="object"){pr(T,"data",q);break}case"src":case"href":if(q===""&&(w!=="a"||N!=="href")){T.removeAttribute(N);break}if(q==null||typeof q=="function"||typeof q=="symbol"||typeof q=="boolean"){T.removeAttribute(N);break}q=wo(""+q),T.setAttribute(N,q);break;case"action":case"formAction":if(typeof q=="function"){T.setAttribute(N,"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 ue=="function"&&(N==="formAction"?(w!=="input"&&Zo(T,w,"name",ne.name,ne,null),Zo(T,w,"formEncType",ne.formEncType,ne,null),Zo(T,w,"formMethod",ne.formMethod,ne,null),Zo(T,w,"formTarget",ne.formTarget,ne,null)):(Zo(T,w,"encType",ne.encType,ne,null),Zo(T,w,"method",ne.method,ne,null),Zo(T,w,"target",ne.target,ne,null)));if(q==null||typeof q=="symbol"||typeof q=="boolean"){T.removeAttribute(N);break}q=wo(""+q),T.setAttribute(N,q);break;case"onClick":q!=null&&(T.onclick=Ta);break;case"onScroll":q!=null&&zn("scroll",T);break;case"onScrollEnd":q!=null&&zn("scrollend",T);break;case"dangerouslySetInnerHTML":if(q!=null){if(typeof q!="object"||!("__html"in q))throw Error(n(61));if(N=q.__html,N!=null){if(ne.children!=null)throw Error(n(60));T.innerHTML=N}}break;case"multiple":T.multiple=q&&typeof q!="function"&&typeof q!="symbol";break;case"muted":T.muted=q&&typeof q!="function"&&typeof q!="symbol";break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"defaultValue":case"defaultChecked":case"innerHTML":case"ref":break;case"autoFocus":break;case"xlinkHref":if(q==null||typeof q=="function"||typeof q=="boolean"||typeof q=="symbol"){T.removeAttribute("xlink:href");break}N=wo(""+q),T.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",N);break;case"contentEditable":case"spellCheck":case"draggable":case"value":case"autoReverse":case"externalResourcesRequired":case"focusable":case"preserveAlpha":q!=null&&typeof q!="function"&&typeof q!="symbol"?T.setAttribute(N,""+q):T.removeAttribute(N);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":q&&typeof q!="function"&&typeof q!="symbol"?T.setAttribute(N,""):T.removeAttribute(N);break;case"capture":case"download":q===!0?T.setAttribute(N,""):q!==!1&&q!=null&&typeof q!="function"&&typeof q!="symbol"?T.setAttribute(N,q):T.removeAttribute(N);break;case"cols":case"rows":case"size":case"span":q!=null&&typeof q!="function"&&typeof q!="symbol"&&!isNaN(q)&&1<=q?T.setAttribute(N,q):T.removeAttribute(N);break;case"rowSpan":case"start":q==null||typeof q=="function"||typeof q=="symbol"||isNaN(q)?T.removeAttribute(N):T.setAttribute(N,q);break;case"popover":zn("beforetoggle",T),zn("toggle",T),Dt(T,"popover",q);break;case"xlinkActuate":Gr(T,"http://www.w3.org/1999/xlink","xlink:actuate",q);break;case"xlinkArcrole":Gr(T,"http://www.w3.org/1999/xlink","xlink:arcrole",q);break;case"xlinkRole":Gr(T,"http://www.w3.org/1999/xlink","xlink:role",q);break;case"xlinkShow":Gr(T,"http://www.w3.org/1999/xlink","xlink:show",q);break;case"xlinkTitle":Gr(T,"http://www.w3.org/1999/xlink","xlink:title",q);break;case"xlinkType":Gr(T,"http://www.w3.org/1999/xlink","xlink:type",q);break;case"xmlBase":Gr(T,"http://www.w3.org/XML/1998/namespace","xml:base",q);break;case"xmlLang":Gr(T,"http://www.w3.org/XML/1998/namespace","xml:lang",q);break;case"xmlSpace":Gr(T,"http://www.w3.org/XML/1998/namespace","xml:space",q);break;case"is":Dt(T,"is",q);break;case"innerText":case"textContent":break;default:(!(2<N.length)||N[0]!=="o"&&N[0]!=="O"||N[1]!=="n"&&N[1]!=="N")&&(N=Fs.get(N)||N,Dt(T,N,q))}}function rT(T,w,N,q,ne,ue){switch(N){case"style":cd(T,q,ue);break;case"dangerouslySetInnerHTML":if(q!=null){if(typeof q!="object"||!("__html"in q))throw Error(n(61));if(N=q.__html,N!=null){if(ne.children!=null)throw Error(n(60));T.innerHTML=N}}break;case"children":typeof q=="string"?oa(T,q):(typeof q=="number"||typeof q=="bigint")&&oa(T,""+q);break;case"onScroll":q!=null&&zn("scroll",T);break;case"onScrollEnd":q!=null&&zn("scrollend",T);break;case"onClick":q!=null&&(T.onclick=Ta);break;case"suppressContentEditableWarning":case"suppressHydrationWarning":case"innerHTML":case"ref":break;case"innerText":case"textContent":break;default:if(!Ns.hasOwnProperty(N))e:{if(N[0]==="o"&&N[1]==="n"&&(ne=N.endsWith("Capture"),w=N.slice(2,ne?N.length-7:void 0),ue=T[gr]||null,ue=ue!=null?ue[N]:null,typeof ue=="function"&&T.removeEventListener(w,ue,ne),typeof q=="function")){typeof ue!="function"&&ue!==null&&(N in T?T[N]=null:T.hasAttribute(N)&&T.removeAttribute(N)),T.addEventListener(w,q,ne);break e}N in T?T[N]=q:q===!0?T.setAttribute(N,""):Dt(T,N,q)}}}function Kl(T,w,N){switch(w){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"img":zn("error",T),zn("load",T);var q=!1,ne=!1,ue;for(ue in N)if(N.hasOwnProperty(ue)){var Ie=N[ue];if(Ie!=null)switch(ue){case"src":q=!0;break;case"srcSet":ne=!0;break;case"children":case"dangerouslySetInnerHTML":throw Error(n(137,w));default:Zo(T,w,ue,Ie,N,null)}}ne&&Zo(T,w,"srcSet",N.srcSet,N,null),q&&Zo(T,w,"src",N.src,N,null);return;case"input":zn("invalid",T);var ot=ue=Ie=ne=null,Et=null,tr=null;for(q in N)if(N.hasOwnProperty(q)){var yr=N[q];if(yr!=null)switch(q){case"name":ne=yr;break;case"type":Ie=yr;break;case"checked":Et=yr;break;case"defaultChecked":tr=yr;break;case"value":ue=yr;break;case"defaultValue":ot=yr;break;case"children":case"dangerouslySetInnerHTML":if(yr!=null)throw Error(n(137,w));break;default:Zo(T,w,q,yr,N,null)}}Hl(T,ue,ot,Et,tr,Ie,ne,!1);return;case"select":zn("invalid",T),q=Ie=ue=null;for(ne in N)if(N.hasOwnProperty(ne)&&(ot=N[ne],ot!=null))switch(ne){case"value":ue=ot;break;case"defaultValue":Ie=ot;break;case"multiple":q=ot;default:Zo(T,w,ne,ot,N,null)}w=ue,N=Ie,T.multiple=!!q,w!=null?hu(T,!!q,w,!1):N!=null&&hu(T,!!q,N,!0);return;case"textarea":zn("invalid",T),ue=ne=q=null;for(Ie in N)if(N.hasOwnProperty(Ie)&&(ot=N[Ie],ot!=null))switch(Ie){case"value":q=ot;break;case"defaultValue":ne=ot;break;case"children":ue=ot;break;case"dangerouslySetInnerHTML":if(ot!=null)throw Error(n(91));break;default:Zo(T,w,Ie,ot,N,null)}rl(T,q,ne,ue);return;case"option":for(Et in N)if(N.hasOwnProperty(Et)&&(q=N[Et],q!=null))switch(Et){case"selected":T.selected=q&&typeof q!="function"&&typeof q!="symbol";break;default:Zo(T,w,Et,q,N,null)}return;case"dialog":zn("beforetoggle",T),zn("toggle",T),zn("cancel",T),zn("close",T);break;case"iframe":case"object":zn("load",T);break;case"video":case"audio":for(q=0;q<v0.length;q++)zn(v0[q],T);break;case"image":zn("error",T),zn("load",T);break;case"details":zn("toggle",T);break;case"embed":case"source":case"link":zn("error",T),zn("load",T);case"area":case"base":case"br":case"col":case"hr":case"keygen":case"meta":case"param":case"track":case"wbr":case"menuitem":for(tr in N)if(N.hasOwnProperty(tr)&&(q=N[tr],q!=null))switch(tr){case"children":case"dangerouslySetInnerHTML":throw Error(n(137,w));default:Zo(T,w,tr,q,N,null)}return;default:if(ml(w)){for(yr in N)N.hasOwnProperty(yr)&&(q=N[yr],q!==void 0&&rT(T,w,yr,q,N,void 0));return}}for(ot in N)N.hasOwnProperty(ot)&&(q=N[ot],q!=null&&Zo(T,w,ot,q,N,null))}function y2(T,w,N,q){switch(w){case"div":case"span":case"svg":case"path":case"a":case"g":case"p":case"li":break;case"input":var ne=null,ue=null,Ie=null,ot=null,Et=null,tr=null,yr=null;for(ar in N){var Pr=N[ar];if(N.hasOwnProperty(ar)&&Pr!=null)switch(ar){case"checked":break;case"value":break;case"defaultValue":Et=Pr;default:q.hasOwnProperty(ar)||Zo(T,w,ar,null,q,Pr)}}for(var ir in q){var ar=q[ir];if(Pr=N[ir],q.hasOwnProperty(ir)&&(ar!=null||Pr!=null))switch(ir){case"type":ue=ar;break;case"name":ne=ar;break;case"checked":tr=ar;break;case"defaultChecked":yr=ar;break;case"value":Ie=ar;break;case"defaultValue":ot=ar;break;case"children":case"dangerouslySetInnerHTML":if(ar!=null)throw Error(n(137,w));break;default:ar!==Pr&&Zo(T,w,ir,ar,q,Pr)}}rc(T,Ie,ot,Et,tr,yr,ue,ne);return;case"select":ar=Ie=ot=ir=null;for(ue in N)if(Et=N[ue],N.hasOwnProperty(ue)&&Et!=null)switch(ue){case"value":break;case"multiple":ar=Et;default:q.hasOwnProperty(ue)||Zo(T,w,ue,null,q,Et)}for(ne in q)if(ue=q[ne],Et=N[ne],q.hasOwnProperty(ne)&&(ue!=null||Et!=null))switch(ne){case"value":ir=ue;break;case"defaultValue":ot=ue;break;case"multiple":Ie=ue;default:ue!==Et&&Zo(T,w,ne,ue,q,Et)}w=ot,N=Ie,q=ar,ir!=null?hu(T,!!N,ir,!1):!!q!=!!N&&(w!=null?hu(T,!!N,w,!0):hu(T,!!N,N?[]:"",!1));return;case"textarea":ar=ir=null;for(ot in N)if(ne=N[ot],N.hasOwnProperty(ot)&&ne!=null&&!q.hasOwnProperty(ot))switch(ot){case"value":break;case"children":break;default:Zo(T,w,ot,null,q,ne)}for(Ie in q)if(ne=q[Ie],ue=N[Ie],q.hasOwnProperty(Ie)&&(ne!=null||ue!=null))switch(Ie){case"value":ir=ne;break;case"defaultValue":ar=ne;break;case"children":break;case"dangerouslySetInnerHTML":if(ne!=null)throw Error(n(91));break;default:ne!==ue&&Zo(T,w,Ie,ne,q,ue)}ic(T,ir,ar);return;case"option":for(var li in N)if(ir=N[li],N.hasOwnProperty(li)&&ir!=null&&!q.hasOwnProperty(li))switch(li){case"selected":T.selected=!1;break;default:Zo(T,w,li,null,q,ir)}for(Et in q)if(ir=q[Et],ar=N[Et],q.hasOwnProperty(Et)&&ir!==ar&&(ir!=null||ar!=null))switch(Et){case"selected":T.selected=ir&&typeof ir!="function"&&typeof ir!="symbol";break;default:Zo(T,w,Et,ir,q,ar)}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 Ii in N)ir=N[Ii],N.hasOwnProperty(Ii)&&ir!=null&&!q.hasOwnProperty(Ii)&&Zo(T,w,Ii,null,q,ir);for(tr in q)if(ir=q[tr],ar=N[tr],q.hasOwnProperty(tr)&&ir!==ar&&(ir!=null||ar!=null))switch(tr){case"children":case"dangerouslySetInnerHTML":if(ir!=null)throw Error(n(137,w));break;default:Zo(T,w,tr,ir,q,ar)}return;default:if(ml(w)){for(var Jo in N)ir=N[Jo],N.hasOwnProperty(Jo)&&ir!==void 0&&!q.hasOwnProperty(Jo)&&rT(T,w,Jo,void 0,q,ir);for(yr in q)ir=q[yr],ar=N[yr],!q.hasOwnProperty(yr)||ir===ar||ir===void 0&&ar===void 0||rT(T,w,yr,ir,q,ar);return}}for(var Wt in N)ir=N[Wt],N.hasOwnProperty(Wt)&&ir!=null&&!q.hasOwnProperty(Wt)&&Zo(T,w,Wt,null,q,ir);for(Pr in q)ir=q[Pr],ar=N[Pr],!q.hasOwnProperty(Pr)||ir===ar||ir==null&&ar==null||Zo(T,w,Pr,ir,q,ar)}function iT(T){switch(T){case"css":case"script":case"font":case"img":case"image":case"input":case"link":return!0;default:return!1}}function m0(){if(typeof performance.getEntriesByType=="function"){for(var T=0,w=0,N=performance.getEntriesByType("resource"),q=0;q<N.length;q++){var ne=N[q],ue=ne.transferSize,Ie=ne.initiatorType,ot=ne.duration;if(ue&&ot&&iT(Ie)){for(Ie=0,ot=ne.responseEnd,q+=1;q<N.length;q++){var Et=N[q],tr=Et.startTime;if(tr>ot)break;var yr=Et.transferSize,Pr=Et.initiatorType;yr&&iT(Pr)&&(Et=Et.responseEnd,Ie+=yr*(Et<ot?1:(ot-tr)/(Et-tr)))}if(--q,w+=8*(ue+Ie)/(ne.duration/1e3),T++,10<T)break}}if(0<T)return w/T/1e6}return navigator.connection&&(T=navigator.connection.downlink,typeof T=="number")?T:5}var b0=null,nT=null;function S0(T){return T.nodeType===9?T:T.ownerDocument}function _0(T){switch(T){case"http://www.w3.org/2000/svg":return 1;case"http://www.w3.org/1998/Math/MathML":return 2;default:return 0}}function mc(T,w){if(T===0)switch(w){case"svg":return 1;case"math":return 2;default:return 0}return T===1&&w==="foreignObject"?0:T}function ag(T,w){return T==="textarea"||T==="noscript"||typeof w.children=="string"||typeof w.children=="number"||typeof w.children=="bigint"||typeof w.dangerouslySetInnerHTML=="object"&&w.dangerouslySetInnerHTML!==null&&w.dangerouslySetInnerHTML.__html!=null}var oT=null;function m2(){var T=window.event;return T&&T.type==="popstate"?T===oT?!1:(oT=T,!0):(oT=null,!1)}var hM=typeof setTimeout=="function"?setTimeout:void 0,b2=typeof clearTimeout=="function"?clearTimeout:void 0,pM=typeof Promise=="function"?Promise:void 0,gM=typeof queueMicrotask=="function"?queueMicrotask:typeof pM<"u"?function(T){return pM.resolve(null).then(T).catch(op)}:hM;function op(T){setTimeout(function(){throw T})}function Wi(T){return T==="head"}function aT(T,w){var N=w,q=0;do{var ne=N.nextSibling;if(T.removeChild(N),ne&&ne.nodeType===8)if(N=ne.data,N==="/$"||N==="/&"){if(q===0){T.removeChild(ne),Py(w);return}q--}else if(N==="$"||N==="$?"||N==="$~"||N==="$!"||N==="&")q++;else if(N==="html")P0(T.ownerDocument.documentElement);else if(N==="head"){N=T.ownerDocument.head,P0(N);for(var ue=N.firstChild;ue;){var Ie=ue.nextSibling,ot=ue.nodeName;ue[zr]||ot==="SCRIPT"||ot==="STYLE"||ot==="LINK"&&ue.rel.toLowerCase()==="stylesheet"||N.removeChild(ue),ue=Ie}}else N==="body"&&P0(T.ownerDocument.body);N=ne}while(N);Py(w)}function Zc(T,w){var N=T;T=0;do{var q=N.nextSibling;if(N.nodeType===1?w?(N._stashedDisplay=N.style.display,N.style.display="none"):(N.style.display=N._stashedDisplay||"",N.getAttribute("style")===""&&N.removeAttribute("style")):N.nodeType===3&&(w?(N._stashedText=N.nodeValue,N.nodeValue=""):N.nodeValue=N._stashedText||""),q&&q.nodeType===8)if(N=q.data,N==="/$"){if(T===0)break;T--}else N!=="$"&&N!=="$?"&&N!=="$~"&&N!=="$!"||T++;N=q}while(N)}function P_(T){var w=T.firstChild;for(w&&w.nodeType===10&&(w=w.nextSibling);w;){var N=w;switch(w=w.nextSibling,N.nodeName){case"HTML":case"HEAD":case"BODY":P_(N),fi(N);continue;case"SCRIPT":case"STYLE":continue;case"LINK":if(N.rel.toLowerCase()==="stylesheet")continue}T.removeChild(N)}}function S2(T,w,N,q){for(;T.nodeType===1;){var ne=N;if(T.nodeName.toLowerCase()!==w.toLowerCase()){if(!q&&(T.nodeName!=="INPUT"||T.type!=="hidden"))break}else if(q){if(!T[zr])switch(w){case"meta":if(!T.hasAttribute("itemprop"))break;return T;case"link":if(ue=T.getAttribute("rel"),ue==="stylesheet"&&T.hasAttribute("data-precedence"))break;if(ue!==ne.rel||T.getAttribute("href")!==(ne.href==null||ne.href===""?null:ne.href)||T.getAttribute("crossorigin")!==(ne.crossOrigin==null?null:ne.crossOrigin)||T.getAttribute("title")!==(ne.title==null?null:ne.title))break;return T;case"style":if(T.hasAttribute("data-precedence"))break;return T;case"script":if(ue=T.getAttribute("src"),(ue!==(ne.src==null?null:ne.src)||T.getAttribute("type")!==(ne.type==null?null:ne.type)||T.getAttribute("crossorigin")!==(ne.crossOrigin==null?null:ne.crossOrigin))&&ue&&T.hasAttribute("async")&&!T.hasAttribute("itemprop"))break;return T;default:return T}}else if(w==="input"&&T.type==="hidden"){var ue=ne.name==null?null:""+ne.name;if(ne.type==="hidden"&&T.getAttribute("name")===ue)return T}else return T;if(T=Ad(T.nextSibling),T===null)break}return null}function Fo(T,w,N){if(w==="")return null;for(;T.nodeType!==3;)if((T.nodeType!==1||T.nodeName!=="INPUT"||T.type!=="hidden")&&!N||(T=Ad(T.nextSibling),T===null))return null;return T}function vM(T,w){for(;T.nodeType!==8;)if((T.nodeType!==1||T.nodeName!=="INPUT"||T.type!=="hidden")&&!w||(T=Ad(T.nextSibling),T===null))return null;return T}function C_(T){return T.data==="$?"||T.data==="$~"}function py(T){return T.data==="$!"||T.data==="$?"&&T.ownerDocument.readyState!=="loading"}function _2(T,w){var N=T.ownerDocument;if(T.data==="$~")T._reactRetry=w;else if(T.data!=="$?"||N.readyState!=="loading")w();else{var q=function(){w(),N.removeEventListener("DOMContentLoaded",q)};N.addEventListener("DOMContentLoaded",q),T._reactRetry=q}}function Ad(T){for(;T!=null;T=T.nextSibling){var w=T.nodeType;if(w===1||w===3)break;if(w===8){if(w=T.data,w==="$"||w==="$!"||w==="$?"||w==="$~"||w==="&"||w==="F!"||w==="F")break;if(w==="/$"||w==="/&")return null}}return T}var sT=null;function yM(T){T=T.nextSibling;for(var w=0;T;){if(T.nodeType===8){var N=T.data;if(N==="/$"||N==="/&"){if(w===0)return Ad(T.nextSibling);w--}else N!=="$"&&N!=="$!"&&N!=="$?"&&N!=="$~"&&N!=="&"||w++}T=T.nextSibling}return null}function mM(T){T=T.previousSibling;for(var w=0;T;){if(T.nodeType===8){var N=T.data;if(N==="$"||N==="$!"||N==="$?"||N==="$~"||N==="&"){if(w===0)return T;w--}else N!=="/$"&&N!=="/&"||w++}T=T.previousSibling}return null}function bM(T,w,N){switch(w=S0(N),T){case"html":if(T=w.documentElement,!T)throw Error(n(452));return T;case"head":if(T=w.head,!T)throw Error(n(453));return T;case"body":if(T=w.body,!T)throw Error(n(454));return T;default:throw Error(n(451))}}function P0(T){for(var w=T.attributes;w.length;)T.removeAttributeNode(w[0]);fi(T)}var Od=new Map,SM=new Set;function T_(T){return typeof T.getRootNode=="function"?T.getRootNode():T.nodeType===9?T:T.ownerDocument}var ap=z.d;z.d={f:P2,r:C2,D:lT,C:T2,L:x2,m:E2,X:bc,S:Rl,M:w2};function P2(){var T=ap.f(),w=h_();return T||w}function C2(T){var w=st(T);w!==null&&w.tag===5&&w.type==="form"?fC(w):ap.r(T)}var sg=typeof document>"u"?null:document;function _M(T,w,N){var q=sg;if(q&&typeof w=="string"&&w){var ne=rs(w);ne='link[rel="'+T+'"][href="'+ne+'"]',typeof N=="string"&&(ne+='[crossorigin="'+N+'"]'),SM.has(ne)||(SM.add(ne),T={rel:T,crossOrigin:N,href:w},q.querySelector(ne)===null&&(w=q.createElement("link"),Kl(w,"link",T),si(w),q.head.appendChild(w)))}}function lT(T){ap.D(T),_M("dns-prefetch",T,null)}function T2(T,w){ap.C(T,w),_M("preconnect",T,w)}function x2(T,w,N){ap.L(T,w,N);var q=sg;if(q&&T&&w){var ne='link[rel="preload"][as="'+rs(w)+'"]';w==="image"&&N&&N.imageSrcSet?(ne+='[imagesrcset="'+rs(N.imageSrcSet)+'"]',typeof N.imageSizes=="string"&&(ne+='[imagesizes="'+rs(N.imageSizes)+'"]')):ne+='[href="'+rs(T)+'"]';var ue=ne;switch(w){case"style":ue=gy(T);break;case"script":ue=yy(T)}Od.has(ue)||(T=d({rel:"preload",href:w==="image"&&N&&N.imageSrcSet?void 0:T,as:w},N),Od.set(ue,T),q.querySelector(ne)!==null||w==="style"&&q.querySelector(vy(ue))||w==="script"&&q.querySelector(my(ue))||(w=q.createElement("link"),Kl(w,"link",T),si(w),q.head.appendChild(w)))}}function E2(T,w){ap.m(T,w);var N=sg;if(N&&T){var q=w&&typeof w.as=="string"?w.as:"script",ne='link[rel="modulepreload"][as="'+rs(q)+'"][href="'+rs(T)+'"]',ue=ne;switch(q){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":ue=yy(T)}if(!Od.has(ue)&&(T=d({rel:"modulepreload",href:T},w),Od.set(ue,T),N.querySelector(ne)===null)){switch(q){case"audioworklet":case"paintworklet":case"serviceworker":case"sharedworker":case"worker":case"script":if(N.querySelector(my(ue)))return}q=N.createElement("link"),Kl(q,"link",T),si(q),N.head.appendChild(q)}}}function Rl(T,w,N){ap.S(T,w,N);var q=sg;if(q&&T){var ne=hi(q).hoistableStyles,ue=gy(T);w=w||"default";var Ie=ne.get(ue);if(!Ie){var ot={loading:0,preload:null};if(Ie=q.querySelector(vy(ue)))ot.loading=5;else{T=d({rel:"stylesheet",href:T,"data-precedence":w},N),(N=Od.get(ue))&&uT(T,N);var Et=Ie=q.createElement("link");si(Et),Kl(Et,"link",T),Et._p=new Promise(function(tr,yr){Et.onload=tr,Et.onerror=yr}),Et.addEventListener("load",function(){ot.loading|=1}),Et.addEventListener("error",function(){ot.loading|=2}),ot.loading|=4,x_(Ie,w,q)}Ie={type:"stylesheet",instance:Ie,count:1,state:ot},ne.set(ue,Ie)}}}function bc(T,w){ap.X(T,w);var N=sg;if(N&&T){var q=hi(N).hoistableScripts,ne=yy(T),ue=q.get(ne);ue||(ue=N.querySelector(my(ne)),ue||(T=d({src:T,async:!0},w),(w=Od.get(ne))&&E_(T,w),ue=N.createElement("script"),si(ue),Kl(ue,"link",T),N.head.appendChild(ue)),ue={type:"script",instance:ue,count:1,state:null},q.set(ne,ue))}}function w2(T,w){ap.M(T,w);var N=sg;if(N&&T){var q=hi(N).hoistableScripts,ne=yy(T),ue=q.get(ne);ue||(ue=N.querySelector(my(ne)),ue||(T=d({src:T,async:!0,type:"module"},w),(w=Od.get(ne))&&E_(T,w),ue=N.createElement("script"),si(ue),Kl(ue,"link",T),N.head.appendChild(ue)),ue={type:"script",instance:ue,count:1,state:null},q.set(ne,ue))}}function PM(T,w,N,q){var ne=(ne=oe.current)?T_(ne):null;if(!ne)throw Error(n(446));switch(T){case"meta":case"title":return null;case"style":return typeof N.precedence=="string"&&typeof N.href=="string"?(w=gy(N.href),N=hi(ne).hoistableStyles,q=N.get(w),q||(q={type:"style",instance:null,count:0,state:null},N.set(w,q)),q):{type:"void",instance:null,count:0,state:null};case"link":if(N.rel==="stylesheet"&&typeof N.href=="string"&&typeof N.precedence=="string"){T=gy(N.href);var ue=hi(ne).hoistableStyles,Ie=ue.get(T);if(Ie||(ne=ne.ownerDocument||ne,Ie={type:"stylesheet",instance:null,count:0,state:{loading:0,preload:null}},ue.set(T,Ie),(ue=ne.querySelector(vy(T)))&&!ue._p&&(Ie.instance=ue,Ie.state.loading=5),Od.has(T)||(N={rel:"preload",as:"style",href:N.href,crossOrigin:N.crossOrigin,integrity:N.integrity,media:N.media,hrefLang:N.hrefLang,referrerPolicy:N.referrerPolicy},Od.set(T,N),ue||A2(ne,T,N,Ie.state))),w&&q===null)throw Error(n(528,""));return Ie}if(w&&q!==null)throw Error(n(529,""));return null;case"script":return w=N.async,N=N.src,typeof N=="string"&&w&&typeof w!="function"&&typeof w!="symbol"?(w=yy(N),N=hi(ne).hoistableScripts,q=N.get(w),q||(q={type:"script",instance:null,count:0,state:null},N.set(w,q)),q):{type:"void",instance:null,count:0,state:null};default:throw Error(n(444,T))}}function gy(T){return'href="'+rs(T)+'"'}function vy(T){return'link[rel="stylesheet"]['+T+"]"}function CM(T){return d({},T,{"data-precedence":T.precedence,precedence:null})}function A2(T,w,N,q){T.querySelector('link[rel="preload"][as="style"]['+w+"]")?q.loading=1:(w=T.createElement("link"),q.preload=w,w.addEventListener("load",function(){return q.loading|=1}),w.addEventListener("error",function(){return q.loading|=2}),Kl(w,"link",N),si(w),T.head.appendChild(w))}function yy(T){return'[src="'+rs(T)+'"]'}function my(T){return"script[async]"+T}function TM(T,w,N){if(w.count++,w.instance===null)switch(w.type){case"style":var q=T.querySelector('style[data-href~="'+rs(N.href)+'"]');if(q)return w.instance=q,si(q),q;var ne=d({},N,{"data-href":N.href,"data-precedence":N.precedence,href:null,precedence:null});return q=(T.ownerDocument||T).createElement("style"),si(q),Kl(q,"style",ne),x_(q,N.precedence,T),w.instance=q;case"stylesheet":ne=gy(N.href);var ue=T.querySelector(vy(ne));if(ue)return w.state.loading|=4,w.instance=ue,si(ue),ue;q=CM(N),(ne=Od.get(ne))&&uT(q,ne),ue=(T.ownerDocument||T).createElement("link"),si(ue);var Ie=ue;return Ie._p=new Promise(function(ot,Et){Ie.onload=ot,Ie.onerror=Et}),Kl(ue,"link",q),w.state.loading|=4,x_(ue,N.precedence,T),w.instance=ue;case"script":return ue=yy(N.src),(ne=T.querySelector(my(ue)))?(w.instance=ne,si(ne),ne):(q=N,(ne=Od.get(ue))&&(q=d({},N),E_(q,ne)),T=T.ownerDocument||T,ne=T.createElement("script"),si(ne),Kl(ne,"link",q),T.head.appendChild(ne),w.instance=ne);case"void":return null;default:throw Error(n(443,w.type))}else w.type==="stylesheet"&&(w.state.loading&4)===0&&(q=w.instance,w.state.loading|=4,x_(q,N.precedence,T));return w.instance}function x_(T,w,N){for(var q=N.querySelectorAll('link[rel="stylesheet"][data-precedence],style[data-precedence]'),ne=q.length?q[q.length-1]:null,ue=ne,Ie=0;Ie<q.length;Ie++){var ot=q[Ie];if(ot.dataset.precedence===w)ue=ot;else if(ue!==ne)break}ue?ue.parentNode.insertBefore(T,ue.nextSibling):(w=N.nodeType===9?N.head:N,w.insertBefore(T,w.firstChild))}function uT(T,w){T.crossOrigin==null&&(T.crossOrigin=w.crossOrigin),T.referrerPolicy==null&&(T.referrerPolicy=w.referrerPolicy),T.title==null&&(T.title=w.title)}function E_(T,w){T.crossOrigin==null&&(T.crossOrigin=w.crossOrigin),T.referrerPolicy==null&&(T.referrerPolicy=w.referrerPolicy),T.integrity==null&&(T.integrity=w.integrity)}var C0=null;function xM(T,w,N){if(C0===null){var q=new Map,ne=C0=new Map;ne.set(N,q)}else ne=C0,q=ne.get(N),q||(q=new Map,ne.set(N,q));if(q.has(T))return q;for(q.set(T,null),N=N.getElementsByTagName(T),ne=0;ne<N.length;ne++){var ue=N[ne];if(!(ue[zr]||ue[mt]||T==="link"&&ue.getAttribute("rel")==="stylesheet")&&ue.namespaceURI!=="http://www.w3.org/2000/svg"){var Ie=ue.getAttribute(w)||"";Ie=T+Ie;var ot=q.get(Ie);ot?ot.push(ue):q.set(Ie,[ue])}}return q}function EM(T,w,N){T=T.ownerDocument||T,T.head.insertBefore(N,w==="title"?T.querySelector("head > title"):null)}function O2(T,w,N){if(N===1||w.itemProp!=null)return!1;switch(T){case"meta":case"title":return!0;case"style":if(typeof w.precedence!="string"||typeof w.href!="string"||w.href==="")break;return!0;case"link":if(typeof w.rel!="string"||typeof w.href!="string"||w.href===""||w.onLoad||w.onError)break;switch(w.rel){case"stylesheet":return T=w.disabled,typeof w.precedence=="string"&&T==null;default:return!0}case"script":if(w.async&&typeof w.async!="function"&&typeof w.async!="symbol"&&!w.onLoad&&!w.onError&&w.src&&typeof w.src=="string")return!0}return!1}function wM(T){return!(T.type==="stylesheet"&&(T.state.loading&3)===0)}function by(T,w,N,q){if(N.type==="stylesheet"&&(typeof q.media!="string"||matchMedia(q.media).matches!==!1)&&(N.state.loading&4)===0){if(N.instance===null){var ne=gy(q.href),ue=w.querySelector(vy(ne));if(ue){w=ue._p,w!==null&&typeof w=="object"&&typeof w.then=="function"&&(T.count++,T=w_.bind(T),w.then(T,T)),N.state.loading|=4,N.instance=ue,si(ue);return}ue=w.ownerDocument||w,q=CM(q),(ne=Od.get(ne))&&uT(q,ne),ue=ue.createElement("link"),si(ue);var Ie=ue;Ie._p=new Promise(function(ot,Et){Ie.onload=ot,Ie.onerror=Et}),Kl(ue,"link",q),N.instance=ue}T.stylesheets===null&&(T.stylesheets=new Map),T.stylesheets.set(N,w),(w=N.state.preload)&&(N.state.loading&3)===0&&(T.count++,N=w_.bind(T),w.addEventListener("load",N),w.addEventListener("error",N))}}var cT=0;function D2(T,w){return T.stylesheets&&T.count===0&&O_(T,T.stylesheets),0<T.count||0<T.imgCount?function(N){var q=setTimeout(function(){if(T.stylesheets&&O_(T,T.stylesheets),T.unsuspend){var ue=T.unsuspend;T.unsuspend=null,ue()}},6e4+w);0<T.imgBytes&&cT===0&&(cT=62500*m0());var ne=setTimeout(function(){if(T.waitingForImages=!1,T.count===0&&(T.stylesheets&&O_(T,T.stylesheets),T.unsuspend)){var ue=T.unsuspend;T.unsuspend=null,ue()}},(T.imgBytes>cT?50:800)+w);return T.unsuspend=N,function(){T.unsuspend=null,clearTimeout(q),clearTimeout(ne)}}:null}function w_(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)O_(this,this.stylesheets);else if(this.unsuspend){var T=this.unsuspend;this.unsuspend=null,T()}}}var A_=null;function O_(T,w){T.stylesheets=null,T.unsuspend!==null&&(T.count++,A_=new Map,w.forEach(AM,T),A_=null,w_.call(T))}function AM(T,w){if(!(w.state.loading&4)){var N=A_.get(T);if(N)var q=N.get(null);else{N=new Map,A_.set(T,N);for(var ne=T.querySelectorAll("link[data-precedence],style[data-precedence]"),ue=0;ue<ne.length;ue++){var Ie=ne[ue];(Ie.nodeName==="LINK"||Ie.getAttribute("media")!=="not all")&&(N.set(Ie.dataset.precedence,Ie),q=Ie)}q&&N.set(null,q)}ne=w.instance,Ie=ne.getAttribute("data-precedence"),ue=N.get(Ie)||q,ue===q&&N.set(null,ne),N.set(Ie,ne),this.count++,q=w_.bind(this),ne.addEventListener("load",q),ne.addEventListener("error",q),ue?ue.parentNode.insertBefore(ne,ue.nextSibling):(T=T.nodeType===9?T.head:T,T.insertBefore(ne,T.firstChild)),w.state.loading|=4}}var Sy={$$typeof:b,Provider:null,Consumer:null,_currentValue:G,_currentValue2:G,_threadCount:0};function R2(T,w,N,q,ne,ue,Ie,ot,Et){this.tag=1,this.containerInfo=T,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=Qr(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Qr(0),this.hiddenUpdates=Qr(null),this.identifierPrefix=q,this.onUncaughtError=ne,this.onCaughtError=ue,this.onRecoverableError=Ie,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=Et,this.incompleteTransitions=new Map}function OM(T,w,N,q,ne,ue,Ie,ot,Et,tr,yr,Pr){return T=new R2(T,w,N,Ie,Et,tr,yr,Pr,ot),w=1,ue===!0&&(w|=24),ue=bs(3,null,null,w),T.current=ue,ue.stateNode=T,w=$u(),w.refCount++,T.pooledCache=w,w.refCount++,ue.memoizedState={element:q,isDehydrated:N,cache:w},uc(ue),T}function DM(T){return T?(T=Ic,T):Ic}function RM(T,w,N,q,ne,ue){ne=DM(ne),q.context===null?q.context=ne:q.pendingContext=ne,q=Td(w),q.payload={element:N},ue=ue===void 0?null:ue,ue!==null&&(q.callback=ue),N=Tu(T,q,w),N!==null&&(vc(N,T,w),fh(N,T,w))}function MM(T,w){if(T=T.memoizedState,T!==null&&T.dehydrated!==null){var N=T.retryLane;T.retryLane=N!==0&&N<w?N:w}}function dT(T,w){MM(T,w),(T=T.alternate)&&MM(T,w)}function LM(T){if(T.tag===13||T.tag===31){var w=Rr(T,67108864);w!==null&&vc(w,T,67108864),dT(T,67108864)}}function kM(T){if(T.tag===13||T.tag===31){var w=qc();w=Ji(w);var N=Rr(T,w);N!==null&&vc(N,T,w),dT(T,w)}}var D_=!0;function M2(T,w,N,q){var ne=V.T;V.T=null;var ue=z.p;try{z.p=2,fT(T,w,N,q)}finally{z.p=ue,V.T=ne}}function L2(T,w,N,q){var ne=V.T;V.T=null;var ue=z.p;try{z.p=8,fT(T,w,N,q)}finally{z.p=ue,V.T=ne}}function fT(T,w,N,q){if(D_){var ne=hT(q);if(ne===null)tT(T,w,q,R_,N),NM(T,q);else if(FM(ne,T,w,N,q))q.stopPropagation();else if(NM(T,q),w&4&&-1<k2.indexOf(T)){for(;ne!==null;){var ue=st(ne);if(ue!==null)switch(ue.tag){case 3:if(ue=ue.stateNode,ue.current.memoizedState.isDehydrated){var Ie=We(ue.pendingLanes);if(Ie!==0){var ot=ue;for(ot.pendingLanes|=2,ot.entangledLanes|=2;Ie;){var Et=1<<31-Ht(Ie);ot.entanglements[1]|=Et,Ie&=~Et}mh(ue),(Oo&6)===0&&(Qg=Qe()+500,g0(0))}}break;case 31:case 13:ot=Rr(ue,2),ot!==null&&vc(ot,ue,2),h_(),dT(ue,2)}if(ue=hT(q),ue===null&&tT(T,w,q,R_,N),ue===ne)break;ne=ue}ne!==null&&q.stopPropagation()}else tT(T,w,q,null,N)}}function hT(T){return T=ao(T),pT(T)}var R_=null;function pT(T){if(R_=null,T=to(T),T!==null){var w=o(T);if(w===null)T=null;else{var N=w.tag;if(N===13){if(T=a(w),T!==null)return T;T=null}else if(N===31){if(T=s(w),T!==null)return T;T=null}else if(N===3){if(w.stateNode.current.memoizedState.isDehydrated)return w.tag===3?w.stateNode.containerInfo:null;T=null}else w!==T&&(T=null)}}return R_=T,null}function IM(T){switch(T){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(it()){case xt:return 2;case wt:return 8;case $t:case Mt:return 32;case rt:return 268435456;default:return 32}default:return 32}}var gT=!1,lg=null,ug=null,cg=null,T0=new Map,x0=new Map,dg=[],k2="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 NM(T,w){switch(T){case"focusin":case"focusout":lg=null;break;case"dragenter":case"dragleave":ug=null;break;case"mouseover":case"mouseout":cg=null;break;case"pointerover":case"pointerout":T0.delete(w.pointerId);break;case"gotpointercapture":case"lostpointercapture":x0.delete(w.pointerId)}}function rv(T,w,N,q,ne,ue){return T===null||T.nativeEvent!==ue?(T={blockedOn:w,domEventName:N,eventSystemFlags:q,nativeEvent:ue,targetContainers:[ne]},w!==null&&(w=st(w),w!==null&&LM(w)),T):(T.eventSystemFlags|=q,w=T.targetContainers,ne!==null&&w.indexOf(ne)===-1&&w.push(ne),T)}function FM(T,w,N,q,ne){switch(w){case"focusin":return lg=rv(lg,T,w,N,q,ne),!0;case"dragenter":return ug=rv(ug,T,w,N,q,ne),!0;case"mouseover":return cg=rv(cg,T,w,N,q,ne),!0;case"pointerover":var ue=ne.pointerId;return T0.set(ue,rv(T0.get(ue)||null,T,w,N,q,ne)),!0;case"gotpointercapture":return ue=ne.pointerId,x0.set(ue,rv(x0.get(ue)||null,T,w,N,q,ne)),!0}return!1}function vT(T){var w=to(T.target);if(w!==null){var N=o(w);if(N!==null){if(w=N.tag,w===13){if(w=a(N),w!==null){T.blockedOn=w,eo(T.priority,function(){kM(N)});return}}else if(w===31){if(w=s(N),w!==null){T.blockedOn=w,eo(T.priority,function(){kM(N)});return}}else if(w===3&&N.stateNode.current.memoizedState.isDehydrated){T.blockedOn=N.tag===3?N.stateNode.containerInfo:null;return}}}T.blockedOn=null}function M_(T){if(T.blockedOn!==null)return!1;for(var w=T.targetContainers;0<w.length;){var N=hT(T.nativeEvent);if(N===null){N=T.nativeEvent;var q=new N.constructor(N.type,N);Lo=q,N.target.dispatchEvent(q),Lo=null}else return w=st(N),w!==null&&LM(w),T.blockedOn=N,!1;w.shift()}return!0}function BM(T,w,N){M_(T)&&N.delete(w)}function I2(){gT=!1,lg!==null&&M_(lg)&&(lg=null),ug!==null&&M_(ug)&&(ug=null),cg!==null&&M_(cg)&&(cg=null),T0.forEach(BM),x0.forEach(BM)}function _y(T,w){T.blockedOn===w&&(T.blockedOn=null,gT||(gT=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,I2)))}var L_=null;function jM(T){L_!==T&&(L_=T,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){L_===T&&(L_=null);for(var w=0;w<T.length;w+=3){var N=T[w],q=T[w+1],ne=T[w+2];if(typeof q!="function"){if(pT(q||N)===null)continue;break}var ue=st(N);ue!==null&&(T.splice(w,3),w-=3,Kp(ue,{pending:!0,data:ne,method:N.method,action:q},q,ne))}}))}function Py(T){function w(Et){return _y(Et,T)}lg!==null&&_y(lg,T),ug!==null&&_y(ug,T),cg!==null&&_y(cg,T),T0.forEach(w),x0.forEach(w);for(var N=0;N<dg.length;N++){var q=dg[N];q.blockedOn===T&&(q.blockedOn=null)}for(;0<dg.length&&(N=dg[0],N.blockedOn===null);)vT(N),N.blockedOn===null&&dg.shift();if(N=(T.ownerDocument||T).$$reactFormReplay,N!=null)for(q=0;q<N.length;q+=3){var ne=N[q],ue=N[q+1],Ie=ne[gr]||null;if(typeof ue=="function")Ie||jM(N);else if(Ie){var ot=null;if(ue&&ue.hasAttribute("formAction")){if(ne=ue,Ie=ue[gr]||null)ot=Ie.formAction;else if(pT(ne)!==null)continue}else ot=Ie.action;typeof ot=="function"?N[q+1]=ot:(N.splice(q,3),q-=3),jM(N)}}}function qu(){function T(ue){ue.canIntercept&&ue.info==="react-transition"&&ue.intercept({handler:function(){return new Promise(function(Ie){return ne=Ie})},focusReset:"manual",scroll:"manual"})}function w(){ne!==null&&(ne(),ne=null),q||setTimeout(N,20)}function N(){if(!q&&!navigation.transition){var ue=navigation.currentEntry;ue&&ue.url!=null&&navigation.navigate(ue.url,{state:ue.getState(),info:"react-transition",history:"replace"})}}if(typeof navigation=="object"){var q=!1,ne=null;return navigation.addEventListener("navigate",T),navigation.addEventListener("navigatesuccess",w),navigation.addEventListener("navigateerror",w),setTimeout(N,100),function(){q=!0,navigation.removeEventListener("navigate",T),navigation.removeEventListener("navigatesuccess",w),navigation.removeEventListener("navigateerror",w),ne!==null&&(ne(),ne=null)}}}function E0(T){this._internalRoot=T}k_.prototype.render=E0.prototype.render=function(T){var w=this._internalRoot;if(w===null)throw Error(n(409));var N=w.current,q=qc();RM(N,q,T,w,null,null)},k_.prototype.unmount=E0.prototype.unmount=function(){var T=this._internalRoot;if(T!==null){this._internalRoot=null;var w=T.containerInfo;RM(T.current,2,null,T,null,null),h_(),w[ce]=null}};function k_(T){this._internalRoot=T}k_.prototype.unstable_scheduleHydration=function(T){if(T){var w=ri();T={blockedOn:null,target:T,priority:w};for(var N=0;N<dg.length&&w!==0&&w<dg[N].priority;N++);dg.splice(N,0,T),N===0&&vT(T)}};var VM=e.version;if(VM!=="19.2.0")throw Error(n(527,VM,"19.2.0"));z.findDOMNode=function(T){var w=T._reactInternals;if(w===void 0)throw typeof T.render=="function"?Error(n(188)):(T=Object.keys(T).join(","),Error(n(268,T)));return T=u(w),T=T!==null?c(T):null,T=T===null?null:T.stateNode,T};var N2={bundleType:0,version:"19.2.0",rendererPackageName:"react-dom",currentDispatcherRef:V,reconcilerVersion:"19.2.0"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var I_=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!I_.isDisabled&&I_.supportsFiber)try{kt=I_.inject(N2),Xe=I_}catch{}}return j2.createRoot=function(T,w){if(!r(T))throw Error(n(299));var N=!1,q="",ne=yC,ue=mC,Ie=xR;return w!=null&&(w.unstable_strictMode===!0&&(N=!0),w.identifierPrefix!==void 0&&(q=w.identifierPrefix),w.onUncaughtError!==void 0&&(ne=w.onUncaughtError),w.onCaughtError!==void 0&&(ue=w.onCaughtError),w.onRecoverableError!==void 0&&(Ie=w.onRecoverableError)),w=OM(T,1,!1,null,null,N,q,null,ne,ue,Ie,qu),T[ce]=w.current,eT(T),new E0(w)},j2.hydrateRoot=function(T,w,N){if(!r(T))throw Error(n(299));var q=!1,ne="",ue=yC,Ie=mC,ot=xR,Et=null;return N!=null&&(N.unstable_strictMode===!0&&(q=!0),N.identifierPrefix!==void 0&&(ne=N.identifierPrefix),N.onUncaughtError!==void 0&&(ue=N.onUncaughtError),N.onCaughtError!==void 0&&(Ie=N.onCaughtError),N.onRecoverableError!==void 0&&(ot=N.onRecoverableError),N.formState!==void 0&&(Et=N.formState)),w=OM(T,1,!0,w,N??null,q,ne,Et,ue,Ie,ot,qu),w.context=DM(null),N=w.current,q=qc(),q=Ji(q),ne=Td(q),ne.callback=null,Tu(N,ne,q),N=q,w.current.lanes=N,Si(w,N),mh(w),T[ce]=w.current,eT(T),new k_(w)},j2.version="19.2.0",j2}var Kne;function YUe(){if(Kne)return OG.exports;Kne=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(e){console.error(e)}}return t(),OG.exports=GUe(),OG.exports}var qUe=YUe();const XUe=wc(qUe),oX=new WeakMap,KUe=new WeakMap,l5={current:[]};let LG=!1,gj=0;const rj=new Set,fH=new Map;function cEe(t){for(const e of t){if(l5.current.includes(e))continue;l5.current.push(e),e.recompute();const i=KUe.get(e);if(i)for(const n of i){const r=oX.get(n);r!=null&&r.length&&cEe(r)}}}function ZUe(t){const e={prevVal:t.prevState,currentVal:t.state};for(const i of t.listeners)i(e)}function JUe(t){const e={prevVal:t.prevState,currentVal:t.state};for(const i of t.listeners)i(e)}function dEe(t){if(gj>0&&!fH.has(t)&&fH.set(t,t.prevState),rj.add(t),!(gj>0)&&!LG)try{for(LG=!0;rj.size>0;){const e=Array.from(rj);rj.clear();for(const i of e){const n=fH.get(i)??i.prevState;i.prevState=n,ZUe(i)}for(const i of e){const n=oX.get(i);n&&(l5.current.push(i),cEe(n))}for(const i of e){const n=oX.get(i);if(n)for(const r of n)JUe(r)}}}finally{LG=!1,l5.current=[],fH.clear()}}function vj(t){gj++;try{t()}finally{if(gj--,gj===0){const e=rj.values().next().value;e&&dEe(e)}}}function QUe(t){return typeof t=="function"}class e5e{constructor(e,i){this.listeners=new Set,this.subscribe=n=>{var r,o;this.listeners.add(n);const a=(o=(r=this.options)==null?void 0:r.onSubscribe)==null?void 0:o.call(r,n,this);return()=>{this.listeners.delete(n),a==null||a()}},this.prevState=e,this.state=e,this.options=i}setState(e){var i,n,r;this.prevState=this.state,(i=this.options)!=null&&i.updateFn?this.state=this.options.updateFn(this.prevState)(e):QUe(e)?this.state=e(this.prevState):this.state=e,(r=(n=this.options)==null?void 0:n.onUpdate)==null||r.call(n),dEe(this)}}const fP="__TSR_index",Zne="popstate",Jne="beforeunload";function t5e(t){let e=t.getLocation();const i=new Set,n=a=>{e=t.getLocation(),i.forEach(s=>s({location:e,action:a}))},r=a=>{t.notifyOnIndexChange??!0?n(a):e=t.getLocation()},o=async({task:a,navigateOpts:s,...l})=>{var f,h;if((s==null?void 0:s.ignoreBlocker)??!1){a();return}const c=((f=t.getBlockers)==null?void 0:f.call(t))??[],d=l.type==="PUSH"||l.type==="REPLACE";if(typeof document<"u"&&c.length&&d)for(const p of c){const g=u5(l.path,l.state);if(await p.blockerFn({currentLocation:e,nextLocation:g,action:l.type})){(h=t.onBlocked)==null||h.call(t);return}}a()};return{get location(){return e},get length(){return t.getLength()},subscribers:i,subscribe:a=>(i.add(a),()=>{i.delete(a)}),push:(a,s,l)=>{const u=e.state[fP];s=Qne(u+1,s),o({task:()=>{t.pushState(a,s),n({type:"PUSH"})},navigateOpts:l,type:"PUSH",path:a,state:s})},replace:(a,s,l)=>{const u=e.state[fP];s=Qne(u,s),o({task:()=>{t.replaceState(a,s),n({type:"REPLACE"})},navigateOpts:l,type:"REPLACE",path:a,state:s})},go:(a,s)=>{o({task:()=>{t.go(a),r({type:"GO",index:a})},navigateOpts:s,type:"GO"})},back:a=>{o({task:()=>{t.back((a==null?void 0:a.ignoreBlocker)??!1),r({type:"BACK"})},navigateOpts:a,type:"BACK"})},forward:a=>{o({task:()=>{t.forward((a==null?void 0:a.ignoreBlocker)??!1),r({type:"FORWARD"})},navigateOpts:a,type:"FORWARD"})},canGoBack:()=>e.state[fP]!==0,createHref:a=>t.createHref(a),block:a=>{var l;if(!t.setBlockers)return()=>{};const s=((l=t.getBlockers)==null?void 0:l.call(t))??[];return t.setBlockers([...s,a]),()=>{var c,d;const u=((c=t.getBlockers)==null?void 0:c.call(t))??[];(d=t.setBlockers)==null||d.call(t,u.filter(f=>f!==a))}},flush:()=>{var a;return(a=t.flush)==null?void 0:a.call(t)},destroy:()=>{var a;return(a=t.destroy)==null?void 0:a.call(t)},notify:n}}function Qne(t,e){e||(e={});const i=FJ();return{...e,key:i,__TSR_key:i,[fP]:t}}function r5e(t){var x,E;const e=typeof document<"u"?window:void 0,i=e.history.pushState,n=e.history.replaceState;let r=[];const o=()=>r,a=A=>r=A,s=(A=>A),l=(()=>u5(`${e.location.pathname}${e.location.search}${e.location.hash}`,e.history.state));if(!((x=e.history.state)!=null&&x.__TSR_key)&&!((E=e.history.state)!=null&&E.key)){const A=FJ();e.history.replaceState({[fP]:0,key:A,__TSR_key:A},"")}let u=l(),c,d=!1,f=!1,h=!1,p=!1;const g=()=>u;let v,y;const m=()=>{v&&(P._ignoreSubscribers=!0,(v.isPush?e.history.pushState:e.history.replaceState)(v.state,"",v.href),P._ignoreSubscribers=!1,v=void 0,y=void 0,c=void 0)},b=(A,R,M)=>{const D=s(R);y||(c=u),u=u5(R,M),v={href:D,state:M,isPush:(v==null?void 0:v.isPush)||A==="push"},y||(y=Promise.resolve().then(()=>m()))},S=A=>{u=l(),P.notify({type:A})},_=async()=>{if(f){f=!1;return}const A=l(),R=A.state[fP]-u.state[fP],M=R===1,D=R===-1,F=!M&&!D||d;d=!1;const I=F?"GO":D?"BACK":"FORWARD",V=F?{type:"GO",index:R}:{type:D?"BACK":"FORWARD"};if(h)h=!1;else{const z=o();if(typeof document<"u"&&z.length){for(const G of z)if(await G.blockerFn({currentLocation:u,nextLocation:A,action:I})){f=!0,e.history.go(1),P.notify(V);return}}}u=l(),P.notify(V)},C=A=>{if(p){p=!1;return}let R=!1;const M=o();if(typeof document<"u"&&M.length)for(const D of M){const F=D.enableBeforeUnload??!0;if(F===!0){R=!0;break}if(typeof F=="function"&&F()===!0){R=!0;break}}if(R)return A.preventDefault(),A.returnValue=""},P=t5e({getLocation:g,getLength:()=>e.history.length,pushState:(A,R)=>b("push",A,R),replaceState:(A,R)=>b("replace",A,R),back:A=>(A&&(h=!0),p=!0,e.history.back()),forward:A=>{A&&(h=!0),p=!0,e.history.forward()},go:A=>{d=!0,e.history.go(A)},createHref:A=>s(A),flush:m,destroy:()=>{e.history.pushState=i,e.history.replaceState=n,e.removeEventListener(Jne,C,{capture:!0}),e.removeEventListener(Zne,_)},onBlocked:()=>{c&&u!==c&&(u=c)},getBlockers:o,setBlockers:a,notifyOnIndexChange:!1});return e.addEventListener(Jne,C,{capture:!0}),e.addEventListener(Zne,_),e.history.pushState=function(...A){const R=i.apply(e.history,A);return P._ignoreSubscribers||S("PUSH"),R},e.history.replaceState=function(...A){const R=n.apply(e.history,A);return P._ignoreSubscribers||S("REPLACE"),R},P}function u5(t,e){const i=t.indexOf("#"),n=t.indexOf("?"),r=FJ();return{href:t,pathname:t.substring(0,i>0?n>0?Math.min(i,n):i:n>0?n:t.length),hash:i>-1?t.substring(i):"",search:n>-1?t.slice(n,i===-1?void 0:i):"",state:e||{[fP]:0,key:r,__TSR_key:r}}}function FJ(){return(Math.random()+1).toString(36).substring(7)}function c5(t){return t[t.length-1]}function i5e(t){return typeof t=="function"}function nP(t,e){return i5e(t)?t(e):t}const n5e=Object.prototype.hasOwnProperty;function vg(t,e){if(t===e)return t;const i=e,n=roe(t)&&roe(i);if(!n&&!(d5(t)&&d5(i)))return i;const r=n?t:eoe(t);if(!r)return i;const o=n?i:eoe(i);if(!o)return i;const a=r.length,s=o.length,l=n?new Array(s):{};let u=0;for(let c=0;c<s;c++){const d=n?c:o[c],f=t[d],h=i[d];if(f===h){l[d]=f,(n?c<a:n5e.call(t,d))&&u++;continue}if(f===null||h===null||typeof f!="object"||typeof h!="object"){l[d]=h;continue}const p=vg(f,h);l[d]=p,p===f&&u++}return a===s&&u===a?t:l}function eoe(t){const e=[],i=Object.getOwnPropertyNames(t);for(const r of i){if(!Object.prototype.propertyIsEnumerable.call(t,r))return!1;e.push(r)}const n=Object.getOwnPropertySymbols(t);for(const r of n){if(!Object.prototype.propertyIsEnumerable.call(t,r))return!1;e.push(r)}return e}function d5(t){if(!toe(t))return!1;const e=t.constructor;if(typeof e>"u")return!0;const i=e.prototype;return!(!toe(i)||!i.hasOwnProperty("isPrototypeOf"))}function toe(t){return Object.prototype.toString.call(t)==="[object Object]"}function roe(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function oD(t,e,i){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(Array.isArray(t)&&Array.isArray(e)){if(t.length!==e.length)return!1;for(let n=0,r=t.length;n<r;n++)if(!oD(t[n],e[n],i))return!1;return!0}if(d5(t)&&d5(e)){const n=(i==null?void 0:i.ignoreUndefined)??!0;if(i!=null&&i.partial){for(const a in e)if((!n||e[a]!==void 0)&&!oD(t[a],e[a],i))return!1;return!0}let r=0;if(!n)r=Object.keys(t).length;else for(const a in t)t[a]!==void 0&&r++;let o=0;for(const a in e)if((!n||e[a]!==void 0)&&(o++,o>r||!oD(t[a],e[a],i)))return!1;return r===o}return!1}function gk(t){let e,i;const n=new Promise((r,o)=>{e=r,i=o});return n.status="pending",n.resolve=r=>{n.status="resolved",n.value=r,e(r),t==null||t(r)},n.reject=r=>{n.status="rejected",i(r)},n}function hP(t){return!!(t&&typeof t=="object"&&typeof t.then=="function")}function ioe(t){try{return decodeURI(t)}catch{return t.replaceAll(/%[0-9A-F]{2}/gi,e=>{try{return decodeURI(e)}catch{return e}})}}function noe(t,e){if(!t)return t;const i=/%25|%5C/gi;let n=0,r="",o;for(;(o=i.exec(t))!==null;)r+=ioe(t.slice(n,o.index))+o[0],n=i.lastIndex;return r+ioe(n?t.slice(n):t)}var o5e="Invariant failed";function mS(t,e){if(!t)throw new Error(o5e)}function f5(t){const e=new Map;let i,n;const r=o=>{o.next&&(o.prev?(o.prev.next=o.next,o.next.prev=o.prev,o.next=void 0,n&&(n.next=o,o.prev=n)):(o.next.prev=void 0,i=o.next,o.next=void 0,n&&(o.prev=n,n.next=o)),n=o)};return{get(o){const a=e.get(o);if(a)return r(a),a.value},set(o,a){if(e.size>=t&&i){const l=i;e.delete(l.key),l.next&&(i=l.next,l.next.prev=void 0),l===n&&(n=void 0)}const s=e.get(o);if(s)s.value=a,r(s);else{const l={key:o,value:a,prev:n};n&&(n.next=l),n=l,i||(i=l),e.set(o,l)}},clear(){e.clear(),i=void 0,n=void 0}}}const vk=0,yD=1,mD=2,Hj=3,a5e=/^([^{]*)\{\$([a-zA-Z_$][a-zA-Z0-9_$]*)\}([^}]*)$/,s5e=/^([^{]*)\{-\$([a-zA-Z_$][a-zA-Z0-9_$]*)\}([^}]*)$/,l5e=/^([^{]*)\{\$\}([^}]*)$/;function BJ(t,e,i=new Uint16Array(6)){const n=t.indexOf("/",e),r=n===-1?t.length:n,o=t.substring(e,r);if(!o||!o.includes("$"))return i[0]=vk,i[1]=e,i[2]=e,i[3]=r,i[4]=r,i[5]=r,i;if(o==="$"){const u=t.length;return i[0]=mD,i[1]=e,i[2]=e,i[3]=u,i[4]=u,i[5]=u,i}if(o.charCodeAt(0)===36)return i[0]=yD,i[1]=e,i[2]=e+1,i[3]=r,i[4]=r,i[5]=r,i;const a=o.match(l5e);if(a){const c=a[1].length;return i[0]=mD,i[1]=e+c,i[2]=e+c+1,i[3]=e+c+2,i[4]=e+c+3,i[5]=t.length,i}const s=o.match(s5e);if(s){const u=s[1],c=s[2],d=s[3],f=u.length;return i[0]=Hj,i[1]=e+f,i[2]=e+f+3,i[3]=e+f+3+c.length,i[4]=r-d.length,i[5]=r,i}const l=o.match(a5e);if(l){const u=l[1],c=l[2],d=l[3],f=u.length;return i[0]=yD,i[1]=e+f,i[2]=e+f+2,i[3]=e+f+2+c.length,i[4]=r-d.length,i[5]=r,i}return i[0]=vk,i[1]=e,i[2]=e,i[3]=r,i[4]=r,i[5]=r,i}function T$(t,e,i,n,r,o,a){var l,u,c,d,f;a==null||a(i);let s=n;{const h=i.fullPath??i.from,p=h.length,g=((l=i.options)==null?void 0:l.caseSensitive)??t;for(;s<p;){const v=BJ(h,s,e);let y;const m=s,b=v[5];switch(s=b+1,o++,v[0]){case vk:{const _=h.substring(v[2],v[3]);if(g){const C=(u=r.static)==null?void 0:u.get(_);if(C)y=C;else{r.static??(r.static=new Map);const P=Uj(i.fullPath??i.from);P.parent=r,P.depth=o,y=P,r.static.set(_,P)}}else{const C=_.toLowerCase(),P=(c=r.staticInsensitive)==null?void 0:c.get(C);if(P)y=P;else{r.staticInsensitive??(r.staticInsensitive=new Map);const x=Uj(i.fullPath??i.from);x.parent=r,x.depth=o,y=x,r.staticInsensitive.set(C,x)}}break}case yD:{const _=h.substring(m,v[1]),C=h.substring(v[4],b),P=g&&!!(_||C),x=_?P?_:_.toLowerCase():void 0,E=C?P?C:C.toLowerCase():void 0,A=(d=r.dynamic)==null?void 0:d.find(R=>R.caseSensitive===P&&R.prefix===x&&R.suffix===E);if(A)y=A;else{const R=IG(yD,i.fullPath??i.from,P,x,E);y=R,R.depth=o,R.parent=r,r.dynamic??(r.dynamic=[]),r.dynamic.push(R)}break}case Hj:{const _=h.substring(m,v[1]),C=h.substring(v[4],b),P=g&&!!(_||C),x=_?P?_:_.toLowerCase():void 0,E=C?P?C:C.toLowerCase():void 0,A=(f=r.optional)==null?void 0:f.find(R=>R.caseSensitive===P&&R.prefix===x&&R.suffix===E);if(A)y=A;else{const R=IG(Hj,i.fullPath??i.from,P,x,E);y=R,R.parent=r,R.depth=o,r.optional??(r.optional=[]),r.optional.push(R)}break}case mD:{const _=h.substring(m,v[1]),C=h.substring(v[4],b),P=g&&!!(_||C),x=_?P?_:_.toLowerCase():void 0,E=C?P?C:C.toLowerCase():void 0,A=IG(mD,i.fullPath??i.from,P,x,E);y=A,A.parent=r,A.depth=o,r.wildcard??(r.wildcard=[]),r.wildcard.push(A)}}r=y}if((i.path||!i.children)&&!i.isRoot){const v=h.endsWith("/");v||(r.notFound=i),(!r.route||!r.isIndex&&v)&&(r.route=i,r.fullPath=i.fullPath??i.from),r.isIndex||(r.isIndex=v)}}if(i.children)for(const h of i.children)T$(t,e,h,s,r,o,a)}function kG(t,e){if(t.prefix&&e.prefix&&t.prefix!==e.prefix){if(t.prefix.startsWith(e.prefix))return-1;if(e.prefix.startsWith(t.prefix))return 1}if(t.suffix&&e.suffix&&t.suffix!==e.suffix){if(t.suffix.endsWith(e.suffix))return-1;if(e.suffix.endsWith(t.suffix))return 1}return t.prefix&&!e.prefix?-1:!t.prefix&&e.prefix?1:t.suffix&&!e.suffix?-1:!t.suffix&&e.suffix?1:t.caseSensitive&&!e.caseSensitive?-1:!t.caseSensitive&&e.caseSensitive?1:0}function BO(t){var e,i,n;if(t.static)for(const r of t.static.values())BO(r);if(t.staticInsensitive)for(const r of t.staticInsensitive.values())BO(r);if((e=t.dynamic)!=null&&e.length){t.dynamic.sort(kG);for(const r of t.dynamic)BO(r)}if((i=t.optional)!=null&&i.length){t.optional.sort(kG);for(const r of t.optional)BO(r)}if((n=t.wildcard)!=null&&n.length){t.wildcard.sort(kG);for(const r of t.wildcard)BO(r)}}function Uj(t){return{kind:vk,depth:0,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:t,parent:null,isIndex:!1,notFound:null}}function IG(t,e,i,n,r){return{kind:t,depth:0,static:null,staticInsensitive:null,dynamic:null,optional:null,wildcard:null,route:null,fullPath:e,parent:null,isIndex:!1,notFound:null,caseSensitive:i,prefix:n,suffix:r}}function u5e(t,e){const i=Uj("/"),n=new Uint16Array(6);for(const r of t)T$(!1,n,r,1,i,0);BO(i),e.masksTree=i,e.flatCache=f5(1e3)}function c5e(t,e){t||(t="/");const i=e.flatCache.get(t);if(i)return i;const n=jJ(t,e.masksTree);return e.flatCache.set(t,n),n}function d5e(t,e,i,n,r){t||(t="/"),n||(n="/");const o=e?`case\0${t}`:t;let a=r.singleCache.get(o);if(!a){a=Uj("/");const s=new Uint16Array(6);T$(e,s,{from:t},1,a,0),r.singleCache.set(o,a)}return jJ(n,a,i)}function f5e(t,e,i=!1){const n=i?t:`nofuzz\0${t}`,r=e.matchCache.get(n);if(r!==void 0)return r;t||(t="/");const o=jJ(t,e.segmentTree,i);return o&&(o.branch=v5e(o.route)),e.matchCache.set(n,o),o}function h5e(t){return t==="/"?t:t.replace(/\/{1,}$/,"")}function p5e(t,e=!1,i){const n=Uj(t.fullPath),r=new Uint16Array(6),o={},a={};let s=0;return T$(e,r,t,1,n,0,u=>{if(i==null||i(u,s),mS(!(u.id in o),`Duplicate routes found with id: ${String(u.id)}`),o[u.id]=u,s!==0&&u.path){const c=h5e(u.fullPath);(!a[c]||u.fullPath.endsWith("/"))&&(a[c]=u)}s++}),BO(n),{processedTree:{segmentTree:n,singleCache:f5(1e3),matchCache:f5(1e3),flatCache:null,masksTree:null},routesById:o,routesByPath:a}}function jJ(t,e,i=!1){const n=t.split("/"),r=m5e(t,n,e,i);if(!r)return null;const o=g5e(t,n,r),a="**"in r;return a&&(o["**"]=r["**"]),{route:a?r.node.notFound??r.node.route:r.node.route,params:o}}function g5e(t,e,i){var a,s,l,u,c,d;const n=y5e(i.node);let r=null;const o={};for(let f=0,h=0,p=0;h<n.length;f++,h++,p++){const g=n[h],v=e[f],y=p;if(v&&(p+=v.length),g.kind===yD){r??(r=i.node.fullPath.split("/"));const m=r[h],b=((a=g.prefix)==null?void 0:a.length)??0;if(m.charCodeAt(b)===123){const _=((s=g.suffix)==null?void 0:s.length)??0,C=m.substring(b+2,m.length-_-1),P=v.substring(b,v.length-_);o[C]=decodeURIComponent(P)}else{const _=m.substring(1);o[_]=decodeURIComponent(v)}}else if(g.kind===Hj){if(i.skipped&1<<h){f--;continue}r??(r=i.node.fullPath.split("/"));const m=r[h],b=((l=g.prefix)==null?void 0:l.length)??0,S=((u=g.suffix)==null?void 0:u.length)??0,_=m.substring(b+3,m.length-S-1),C=g.suffix||g.prefix?v.substring(b,v.length-S):v;C&&(o[_]=decodeURIComponent(C))}else if(g.kind===mD){const m=g,b=t.substring(y+(((c=m.prefix)==null?void 0:c.length)??0),t.length-(((d=m.suffix)==null?void 0:d.length)??0)),S=decodeURIComponent(b);o["*"]=S,o._splat=S;break}}return o}function v5e(t){const e=[t];for(;t.parentRoute;)t=t.parentRoute,e.push(t);return e.reverse(),e}function y5e(t){const e=Array(t.depth+1);do e[t.depth]=t,t=t.parent;while(t);return e}function m5e(t,e,i,n){const r=!c5(e),o=r&&t!=="/",a=e.length-(r?1:0),s=[{node:i,index:1,skipped:0,depth:1,statics:1,dynamics:0,optionals:0}];let l=null,u=null,c=null;for(;s.length;){const d=s.pop();let{node:f,index:h,skipped:p,depth:g,statics:v,dynamics:y,optionals:m}=d;n&&f.notFound&&hH(u,d)&&(u=d);const b=h===a;if(b){if(f.route&&(!o||f.isIndex)&&(hH(c,d)&&(c=d),v===a&&f.isIndex))return c;if(!f.optional&&!f.wildcard)continue}const S=b?void 0:e[h];let _;if(f.wildcard&&hH(l,d))for(const C of f.wildcard){const{prefix:P,suffix:x}=C;if(!(P&&(b||!(C.caseSensitive?S:_??(_=S.toLowerCase())).startsWith(P)))){if(x){if(b)continue;const E=e.slice(h).join("/").slice(-x.length);if((C.caseSensitive?E:E.toLowerCase())!==x)continue}l={node:C,index:h,skipped:p,depth:g,statics:v,dynamics:y,optionals:m};break}}if(f.optional){const C=p|1<<g,P=g+1;for(let x=f.optional.length-1;x>=0;x--){const E=f.optional[x];s.push({node:E,index:h,skipped:C,depth:P,statics:v,dynamics:y,optionals:m})}if(!b)for(let x=f.optional.length-1;x>=0;x--){const E=f.optional[x],{prefix:A,suffix:R}=E;if(A||R){const M=E.caseSensitive?S:_??(_=S.toLowerCase());if(A&&!M.startsWith(A)||R&&!M.endsWith(R))continue}s.push({node:E,index:h+1,skipped:p,depth:P,statics:v,dynamics:y,optionals:m+1})}}if(!b&&f.dynamic&&S)for(let C=f.dynamic.length-1;C>=0;C--){const P=f.dynamic[C],{prefix:x,suffix:E}=P;if(x||E){const A=P.caseSensitive?S:_??(_=S.toLowerCase());if(x&&!A.startsWith(x)||E&&!A.endsWith(E))continue}s.push({node:P,index:h+1,skipped:p,depth:g+1,statics:v,dynamics:y+1,optionals:m})}if(!b&&f.staticInsensitive){const C=f.staticInsensitive.get(_??(_=S.toLowerCase()));C&&s.push({node:C,index:h+1,skipped:p,depth:g+1,statics:v+1,dynamics:y,optionals:m})}if(!b&&f.static){const C=f.static.get(S);C&&s.push({node:C,index:h+1,skipped:p,depth:g+1,statics:v+1,dynamics:y,optionals:m})}}if(c&&l)return hH(l,c)?c:l;if(c)return c;if(l)return l;if(n&&u){let d=u.index;for(let h=0;h<u.index;h++)d+=e[h].length;const f=d===t.length?"/":t.slice(d);return{node:u.node,skipped:u.skipped,"**":decodeURIComponent(f)}}return null}function hH(t,e){return t?e.statics>t.statics||e.statics===t.statics&&(e.dynamics>t.dynamics||e.dynamics===t.dynamics&&(e.optionals>t.optionals||e.optionals===t.optionals&&(e.node.isIndex>t.node.isIndex||e.node.isIndex===t.node.isIndex&&e.depth>t.depth))):!0}function xU(t){return VJ(t.filter(e=>e!==void 0).join("/"))}function VJ(t){return t.replace(/\/{2,}/g,"/")}function fEe(t){return t==="/"?t:t.replace(/^\/{1,}/,"")}function aD(t){const e=t.length;return e>1&&t[e-1]==="/"?t.replace(/\/{1,}$/,""):t}function EU(t){return aD(fEe(t))}function h5(t,e){return t!=null&&t.endsWith("/")&&t!=="/"&&t!==`${e}/`?t.slice(0,-1):t}function b5e(t,e,i){return h5(t,i)===h5(e,i)}function S5e({base:t,to:e,trailingSlash:i="never",cache:n}){const r=e.startsWith("/"),o=!r&&e===".";let a;if(n){a=r?e:o?t:t+"\0"+e;const d=n.get(a);if(d)return d}let s;if(o)s=t.split("/");else if(r)s=e.split("/");else{for(s=t.split("/");s.length>1&&c5(s)==="";)s.pop();const d=e.split("/");for(let f=0,h=d.length;f<h;f++){const p=d[f];p===""?f?f===h-1&&s.push(p):s=[p]:p===".."?s.pop():p==="."||s.push(p)}}s.length>1&&(c5(s)===""?i==="never"&&s.pop():i==="always"&&s.push(""));let l,u="";for(let d=0;d<s.length;d++){d>0&&(u+="/");const f=s[d];if(!f)continue;l=BJ(f,0,l);const h=l[0];if(h===vk){u+=f;continue}const p=l[5],g=f.substring(0,l[1]),v=f.substring(l[4],p),y=f.substring(l[2],l[3]);h===yD?u+=g||v?`${g}{$${y}}${v}`:`$${y}`:h===mD?u+=g||v?`${g}{$}${v}`:"$":u+=`${g}{-$${y}}${v}`}u=VJ(u);const c=u||"/";return a&&n&&n.set(a,c),c}function NG(t,e,i){const n=e[t];return typeof n!="string"?n:t==="_splat"?encodeURI(n):_5e(n,i)}function FG({path:t,params:e,decodeCharMap:i}){let n=!1;const r={};if(!t||t==="/")return{interpolatedPath:"/",usedParams:r,isMissingParams:n};if(!t.includes("$"))return{interpolatedPath:t,usedParams:r,isMissingParams:n};const o=t.length;let a=0,s,l="";for(;a<o;){const c=a;s=BJ(t,c,s);const d=s[5];if(a=d+1,c===d)continue;const f=s[0];if(f===vk){l+="/"+t.substring(c,d);continue}if(f===mD){const h=e._splat;r._splat=h,r["*"]=h;const p=t.substring(c,s[1]),g=t.substring(s[4],d);if(!h){n=!0,(p||g)&&(l+="/"+p+g);continue}const v=NG("_splat",e,i);l+="/"+p+v+g;continue}if(f===yD){const h=t.substring(s[2],s[3]);!n&&!(h in e)&&(n=!0),r[h]=e[h];const p=t.substring(c,s[1]),g=t.substring(s[4],d),v=NG(h,e,i)??"undefined";l+="/"+p+v+g;continue}if(f===Hj){const h=t.substring(s[2],s[3]),p=e[h];if(p==null)continue;r[h]=p;const g=t.substring(c,s[1]),v=t.substring(s[4],d),y=NG(h,e,i)??"";l+="/"+g+y+v;continue}}return t.endsWith("/")&&(l+="/"),{usedParams:r,interpolatedPath:l||"/",isMissingParams:n}}function _5e(t,e){let i=encodeURIComponent(t);if(e)for(const[n,r]of e)i=i.replaceAll(n,r);return i}function Eg(t){return!!(t!=null&&t.isNotFound)}function P5e(){try{if(typeof window<"u"&&typeof window.sessionStorage=="object")return window.sessionStorage}catch{}}const p5="tsr-scroll-restoration-v1_3",C5e=(t,e)=>{let i;return(...n)=>{i||(i=setTimeout(()=>{t(...n),i=null},e))}};function T5e(){const t=P5e();if(!t)return null;const e=t.getItem(p5);let i=e?JSON.parse(e):{};return{state:i,set:n=>(i=nP(n,i)||i,t.setItem(p5,JSON.stringify(i)))}}const pH=T5e(),aX=t=>t.state.__TSR_key||t.href;function x5e(t){const e=[];let i;for(;i=t.parentNode;)e.push(`${t.tagName}:nth-child(${Array.prototype.indexOf.call(i.children,t)+1})`),t=i;return`${e.reverse().join(" > ")}`.toLowerCase()}let g5=!1;function hEe({storageKey:t,key:e,behavior:i,shouldScrollRestoration:n,scrollToTopSelectors:r,location:o}){var u,c;let a;try{a=JSON.parse(sessionStorage.getItem(t)||"{}")}catch(d){console.error(d);return}const s=e||((u=window.history.state)==null?void 0:u.__TSR_key),l=a[s];g5=!0;e:{if(n&&l&&Object.keys(l).length>0){for(const h in l){const p=l[h];if(h==="window")window.scrollTo({top:p.scrollY,left:p.scrollX,behavior:i});else if(h){const g=document.querySelector(h);g&&(g.scrollLeft=p.scrollX,g.scrollTop=p.scrollY)}}break e}const d=(o??window.location).hash.split("#",2)[1];if(d){const h=((c=window.history.state)==null?void 0:c.__hashScrollIntoViewOptions)??!0;if(h){const p=document.getElementById(d);p&&p.scrollIntoView(h)}break e}const f={top:0,left:0,behavior:i};if(window.scrollTo(f),r)for(const h of r){if(h==="window")continue;const p=typeof h=="function"?h():document.querySelector(h);p&&p.scrollTo(f)}}g5=!1}function E5e(t,e){if(!pH&&!t.isServer||((t.options.scrollRestoration??!1)&&(t.isScrollRestoring=!0),t.isServer||t.isScrollRestorationSetup||!pH))return;t.isScrollRestorationSetup=!0,g5=!1;const n=t.options.getScrollRestorationKey||aX;window.history.scrollRestoration="manual";const r=o=>{if(g5||!t.isScrollRestoring)return;let a="";if(o.target===document||o.target===window)a="window";else{const l=o.target.getAttribute("data-scroll-restoration-id");l?a=`[data-scroll-restoration-id="${l}"]`:a=x5e(o.target)}const s=n(t.state.location);pH.set(l=>{const u=l[s]||(l[s]={}),c=u[a]||(u[a]={});if(a==="window")c.scrollX=window.scrollX||0,c.scrollY=window.scrollY||0;else if(a){const d=document.querySelector(a);d&&(c.scrollX=d.scrollLeft||0,c.scrollY=d.scrollTop||0)}return l})};typeof document<"u"&&document.addEventListener("scroll",C5e(r,100),!0),t.subscribe("onRendered",o=>{const a=n(o.toLocation);if(!t.resetNextScroll){t.resetNextScroll=!0;return}typeof t.options.scrollRestoration=="function"&&!t.options.scrollRestoration({location:t.latestLocation})||(hEe({storageKey:p5,key:a,behavior:t.options.scrollRestorationBehavior,shouldScrollRestoration:t.isScrollRestoring,scrollToTopSelectors:t.options.scrollToTopSelectors,location:t.history.location}),t.isScrollRestoring&&pH.set(s=>(s[a]||(s[a]={}),s)))})}function w5e(t){if(typeof document<"u"&&document.querySelector){const e=t.state.location.state.__hashScrollIntoViewOptions??!0;if(e&&t.state.location.hash!==""){const i=document.getElementById(t.state.location.hash);i&&i.scrollIntoView(e)}}}function A5e(t,e=String){const i=new URLSearchParams;for(const n in t){const r=t[n];r!==void 0&&i.set(n,e(r))}return i.toString()}function BG(t){return t?t==="false"?!1:t==="true"?!0:+t*0===0&&+t+""===t?+t:t:""}function O5e(t){const e=new URLSearchParams(t),i={};for(const[n,r]of e.entries()){const o=i[n];o==null?i[n]=BG(r):Array.isArray(o)?o.push(BG(r)):i[n]=[o,BG(r)]}return i}const D5e=M5e(JSON.parse),R5e=L5e(JSON.stringify,JSON.parse);function M5e(t){return e=>{e[0]==="?"&&(e=e.substring(1));const i=O5e(e);for(const n in i){const r=i[n];if(typeof r=="string")try{i[n]=t(r)}catch{}}return i}}function L5e(t,e){const i=typeof e=="function";function n(r){if(typeof r=="object"&&r!==null)try{return t(r)}catch{}else if(i&&typeof r=="string")try{return e(r),t(r)}catch{}return r}return r=>{const o=A5e(r,n);return o?`?${o}`:""}}const Sp="__root__";function k5e(t){if(t.statusCode=t.statusCode||t.code||307,!t.reloadDocument&&typeof t.href=="string")try{new URL(t.href),t.reloadDocument=!0}catch{}const e=new Headers(t.headers);t.href&&e.get("Location")===null&&e.set("Location",t.href);const i=new Response(null,{status:t.statusCode,headers:e});if(i.options=t,t.throw)throw i;return i}function xv(t){return t instanceof Response&&!!t.options}const wU=t=>{var e;if(!t.rendered)return t.rendered=!0,(e=t.onReady)==null?void 0:e.call(t)},x$=(t,e)=>!!(t.preload&&!t.router.state.matches.some(i=>i.id===e)),pEe=(t,e)=>{var r;const i=t.router.routesById[e.routeId??""]??t.router.routeTree;!i.options.notFoundComponent&&((r=t.router.options)!=null&&r.defaultNotFoundComponent)&&(i.options.notFoundComponent=t.router.options.defaultNotFoundComponent),mS(i.options.notFoundComponent);const n=t.matches.find(o=>o.routeId===i.id);mS(n,"Could not find match for route: "+i.id),t.updateMatch(n.id,o=>({...o,status:"notFound",error:e,isFetching:!1})),e.routerCode==="BEFORE_LOAD"&&i.parentRoute&&(e.routeId=i.parentRoute.id,pEe(t,e))},oP=(t,e,i)=>{var n,r,o;if(!(!xv(i)&&!Eg(i))){if(xv(i)&&i.redirectHandled&&!i.options.reloadDocument)throw i;if(e){(n=e._nonReactive.beforeLoadPromise)==null||n.resolve(),(r=e._nonReactive.loaderPromise)==null||r.resolve(),e._nonReactive.beforeLoadPromise=void 0,e._nonReactive.loaderPromise=void 0;const a=xv(i)?"redirected":"notFound";e._nonReactive.error=i,t.updateMatch(e.id,s=>({...s,status:a,isFetching:!1,error:i})),Eg(i)&&!i.routeId&&(i.routeId=e.routeId),(o=e._nonReactive.loadPromise)==null||o.resolve()}throw xv(i)?(t.rendered=!0,i.options._fromLocation=t.location,i.redirectHandled=!0,i=t.router.resolveRedirect(i),i):(pEe(t,i),i)}},gEe=(t,e)=>{const i=t.router.getMatch(e);return!!(!t.router.isServer&&i._nonReactive.dehydrated||t.router.isServer&&i.ssr===!1)},V2=(t,e,i,n)=>{var s,l;const{id:r,routeId:o}=t.matches[e],a=t.router.looseRoutesById[o];if(i instanceof Promise)throw i;i.routerCode=n,t.firstBadMatchIndex??(t.firstBadMatchIndex=e),oP(t,t.router.getMatch(r),i);try{(l=(s=a.options).onError)==null||l.call(s,i)}catch(u){i=u,oP(t,t.router.getMatch(r),i)}t.updateMatch(r,u=>{var c,d;return(c=u._nonReactive.beforeLoadPromise)==null||c.resolve(),u._nonReactive.beforeLoadPromise=void 0,(d=u._nonReactive.loadPromise)==null||d.resolve(),{...u,error:i,status:"error",isFetching:!1,updatedAt:Date.now(),abortController:new AbortController}})},I5e=(t,e,i,n)=>{var h;const r=t.router.getMatch(e),o=(h=t.matches[i-1])==null?void 0:h.id,a=o?t.router.getMatch(o):void 0;if(t.router.isShell()){r.ssr=n.id===Sp;return}if((a==null?void 0:a.ssr)===!1){r.ssr=!1;return}const s=p=>p===!0&&(a==null?void 0:a.ssr)==="data-only"?"data-only":p,l=t.router.options.defaultSsr??!0;if(n.options.ssr===void 0){r.ssr=s(l);return}if(typeof n.options.ssr!="function"){r.ssr=s(n.options.ssr);return}const{search:u,params:c}=r,d={search:gH(u,r.searchError),params:gH(c,r.paramsError),location:t.location,matches:t.matches.map(p=>({index:p.index,pathname:p.pathname,fullPath:p.fullPath,staticData:p.staticData,id:p.id,routeId:p.routeId,search:gH(p.search,p.searchError),params:gH(p.params,p.paramsError),ssr:p.ssr}))},f=n.options.ssr(d);if(hP(f))return f.then(p=>{r.ssr=s(p??l)});r.ssr=s(f??l)},vEe=(t,e,i,n)=>{var a;if(n._nonReactive.pendingTimeout!==void 0)return;const r=i.options.pendingMs??t.router.options.defaultPendingMs;if(!!(t.onReady&&!t.router.isServer&&!x$(t,e)&&(i.options.loader||i.options.beforeLoad||bEe(i))&&typeof r=="number"&&r!==1/0&&(i.options.pendingComponent??((a=t.router.options)==null?void 0:a.defaultPendingComponent)))){const s=setTimeout(()=>{wU(t)},r);n._nonReactive.pendingTimeout=s}},N5e=(t,e,i)=>{const n=t.router.getMatch(e);if(!n._nonReactive.beforeLoadPromise&&!n._nonReactive.loaderPromise)return;vEe(t,e,i,n);const r=()=>{const o=t.router.getMatch(e);o.preload&&(o.status==="redirected"||o.status==="notFound")&&oP(t,o,o.error)};return n._nonReactive.beforeLoadPromise?n._nonReactive.beforeLoadPromise.then(r):r()},F5e=(t,e,i,n)=>{var P;const r=t.router.getMatch(e),o=r._nonReactive.loadPromise;r._nonReactive.loadPromise=gk(()=>{o==null||o.resolve()});const{paramsError:a,searchError:s}=r;a&&V2(t,i,a,"PARSE_PARAMS"),s&&V2(t,i,s,"VALIDATE_SEARCH"),vEe(t,e,n,r);const l=new AbortController,u=(P=t.matches[i-1])==null?void 0:P.id,c=u?t.router.getMatch(u):void 0,f={...(c==null?void 0:c.context)??t.router.options.context??void 0,...r.__routeContext};let h=!1;const p=()=>{h||(h=!0,t.updateMatch(e,x=>({...x,isFetching:"beforeLoad",fetchCount:x.fetchCount+1,abortController:l,context:f})))},g=()=>{var x;(x=r._nonReactive.beforeLoadPromise)==null||x.resolve(),r._nonReactive.beforeLoadPromise=void 0,t.updateMatch(e,E=>({...E,isFetching:!1}))};if(!n.options.beforeLoad){vj(()=>{p(),g()});return}r._nonReactive.beforeLoadPromise=gk();const{search:v,params:y,cause:m}=r,b=x$(t,e),S={search:v,abortController:l,params:y,preload:b,context:f,location:t.location,navigate:x=>t.router.navigate({...x,_fromLocation:t.location}),buildLocation:t.router.buildLocation,cause:b?"preload":m,matches:t.matches,...t.router.options.additionalContext},_=x=>{if(x===void 0){vj(()=>{p(),g()});return}(xv(x)||Eg(x))&&(p(),V2(t,i,x,"BEFORE_LOAD")),vj(()=>{p(),t.updateMatch(e,E=>({...E,__beforeLoadContext:x,context:{...E.context,...x}})),g()})};let C;try{if(C=n.options.beforeLoad(S),hP(C))return p(),C.catch(x=>{V2(t,i,x,"BEFORE_LOAD")}).then(_)}catch(x){p(),V2(t,i,x,"BEFORE_LOAD")}_(C)},B5e=(t,e)=>{const{id:i,routeId:n}=t.matches[e],r=t.router.looseRoutesById[n],o=()=>{if(t.router.isServer){const l=I5e(t,i,e,r);if(hP(l))return l.then(s)}return s()},a=()=>F5e(t,i,e,r),s=()=>{if(gEe(t,i))return;const l=N5e(t,i,r);return hP(l)?l.then(a):a()};return o()},yj=(t,e,i)=>{var o,a,s,l,u,c;const n=t.router.getMatch(e);if(!n||!i.options.head&&!i.options.scripts&&!i.options.headers)return;const r={matches:t.matches,match:n,params:n.params,loaderData:n.loaderData};return Promise.all([(a=(o=i.options).head)==null?void 0:a.call(o,r),(l=(s=i.options).scripts)==null?void 0:l.call(s,r),(c=(u=i.options).headers)==null?void 0:c.call(u,r)]).then(([d,f,h])=>{const p=d==null?void 0:d.meta,g=d==null?void 0:d.links,v=d==null?void 0:d.scripts,y=d==null?void 0:d.styles;return{meta:p,links:g,headScripts:v,headers:h,scripts:f,styles:y}})},yEe=(t,e,i,n)=>{const r=t.matchPromises[i-1],{params:o,loaderDeps:a,abortController:s,cause:l}=t.router.getMatch(e);let u=t.router.options.context??{};for(let d=0;d<=i;d++){const f=t.matches[d];if(!f)continue;const h=t.router.getMatch(f.id);h&&(u={...u,...h.__routeContext??{},...h.__beforeLoadContext??{}})}const c=x$(t,e);return{params:o,deps:a,preload:!!c,parentMatchPromise:r,abortController:s,context:u,location:t.location,navigate:d=>t.router.navigate({...d,_fromLocation:t.location}),cause:c?"preload":l,route:n,...t.router.options.additionalContext}},ooe=async(t,e,i,n)=>{var r,o,a,s,l,u;try{const c=t.router.getMatch(e);try{(!t.router.isServer||c.ssr===!0)&&mEe(n);const d=(o=(r=n.options).loader)==null?void 0:o.call(r,yEe(t,e,i,n)),f=n.options.loader&&hP(d);if(!!(f||n._lazyPromise||n._componentsPromise||n.options.head||n.options.scripts||n.options.headers||c._nonReactive.minPendingPromise)&&t.updateMatch(e,y=>({...y,isFetching:"loader"})),n.options.loader){const y=f?await d:d;oP(t,t.router.getMatch(e),y),y!==void 0&&t.updateMatch(e,m=>({...m,loaderData:y}))}n._lazyPromise&&await n._lazyPromise;const p=yj(t,e,n),g=p?await p:void 0,v=c._nonReactive.minPendingPromise;v&&await v,n._componentsPromise&&await n._componentsPromise,t.updateMatch(e,y=>({...y,error:void 0,status:"success",isFetching:!1,updatedAt:Date.now(),...g}))}catch(d){let f=d;const h=c._nonReactive.minPendingPromise;h&&await h,Eg(d)&&await((s=(a=n.options.notFoundComponent)==null?void 0:a.preload)==null?void 0:s.call(a)),oP(t,t.router.getMatch(e),d);try{(u=(l=n.options).onError)==null||u.call(l,d)}catch(v){f=v,oP(t,t.router.getMatch(e),v)}const p=yj(t,e,n),g=p?await p:void 0;t.updateMatch(e,v=>({...v,error:f,status:"error",isFetching:!1,...g}))}}catch(c){const d=t.router.getMatch(e);if(d){const f=yj(t,e,n);if(f){const h=await f;t.updateMatch(e,p=>({...p,...h}))}d._nonReactive.loaderPromise=void 0}oP(t,d,c)}},j5e=async(t,e)=>{var u,c;const{id:i,routeId:n}=t.matches[e];let r=!1,o=!1;const a=t.router.looseRoutesById[n];if(gEe(t,i)){if(t.router.isServer){const d=yj(t,i,a);if(d){const f=await d;t.updateMatch(i,h=>({...h,...f}))}return t.router.getMatch(i)}}else{const d=t.router.getMatch(i);if(d._nonReactive.loaderPromise){if(d.status==="success"&&!t.sync&&!d.preload)return d;await d._nonReactive.loaderPromise;const f=t.router.getMatch(i),h=f._nonReactive.error||f.error;h&&oP(t,f,h)}else{const f=Date.now()-d.updatedAt,h=x$(t,i),p=h?a.options.preloadStaleTime??t.router.options.defaultPreloadStaleTime??3e4:a.options.staleTime??t.router.options.defaultStaleTime??0,g=a.options.shouldReload,v=typeof g=="function"?g(yEe(t,i,e,a)):g,y=!!h&&!t.router.state.matches.some(_=>_.id===i),m=t.router.getMatch(i);m._nonReactive.loaderPromise=gk(),y!==m.preload&&t.updateMatch(i,_=>({..._,preload:y}));const{status:b,invalid:S}=m;if(r=b==="success"&&(S||(v??f>p)),!(h&&a.options.preload===!1))if(r&&!t.sync)o=!0,(async()=>{var _,C;try{await ooe(t,i,e,a);const P=t.router.getMatch(i);(_=P._nonReactive.loaderPromise)==null||_.resolve(),(C=P._nonReactive.loadPromise)==null||C.resolve(),P._nonReactive.loaderPromise=void 0}catch(P){xv(P)&&await t.router.navigate(P.options)}})();else if(b!=="success"||r&&t.sync)await ooe(t,i,e,a);else{const _=yj(t,i,a);if(_){const C=await _;t.updateMatch(i,P=>({...P,...C}))}}}}const s=t.router.getMatch(i);o||((u=s._nonReactive.loaderPromise)==null||u.resolve(),(c=s._nonReactive.loadPromise)==null||c.resolve()),clearTimeout(s._nonReactive.pendingTimeout),s._nonReactive.pendingTimeout=void 0,o||(s._nonReactive.loaderPromise=void 0),s._nonReactive.dehydrated=void 0;const l=o?s.isFetching:!1;return l!==s.isFetching||s.invalid!==!1?(t.updateMatch(i,d=>({...d,isFetching:l,invalid:!1})),t.router.getMatch(i)):s};async function aoe(t){const e=Object.assign(t,{matchPromises:[]});!e.router.isServer&&e.router.state.matches.some(i=>i._forcePending)&&wU(e);try{for(let r=0;r<e.matches.length;r++){const o=B5e(e,r);hP(o)&&await o}const i=e.firstBadMatchIndex??e.matches.length;for(let r=0;r<i;r++)e.matchPromises.push(j5e(e,r));await Promise.all(e.matchPromises);const n=wU(e);hP(n)&&await n}catch(i){if(Eg(i)&&!e.preload){const n=wU(e);throw hP(n)&&await n,i}if(xv(i))throw i}return e.matches}async function mEe(t){if(!t._lazyLoaded&&t._lazyPromise===void 0&&(t.lazyFn?t._lazyPromise=t.lazyFn().then(e=>{const{id:i,...n}=e.options;Object.assign(t.options,n),t._lazyLoaded=!0,t._lazyPromise=void 0}):t._lazyLoaded=!0),!t._componentsLoaded&&t._componentsPromise===void 0){const e=()=>{var n;const i=[];for(const r of SEe){const o=(n=t.options[r])==null?void 0:n.preload;o&&i.push(o())}if(i.length)return Promise.all(i).then(()=>{t._componentsLoaded=!0,t._componentsPromise=void 0});t._componentsLoaded=!0,t._componentsPromise=void 0};t._componentsPromise=t._lazyPromise?t._lazyPromise.then(e):e()}return t._componentsPromise}function gH(t,e){return e?{status:"error",error:e}:{status:"success",value:t}}function bEe(t){var e;for(const i of SEe)if((e=t.options[i])!=null&&e.preload)return!0;return!1}const SEe=["component","errorComponent","pendingComponent","notFoundComponent"];function V5e(t){return{input:({url:e})=>{for(const i of t)e=_Ee(i,e);return e},output:({url:e})=>{for(let i=t.length-1;i>=0;i--)e=PEe(t[i],e);return e}}}function H5e(t){const e=EU(t.basepath),i=`/${e}`,n=`${i}/`,r=t.caseSensitive?i:i.toLowerCase(),o=t.caseSensitive?n:n.toLowerCase();return{input:({url:a})=>{const s=t.caseSensitive?a.pathname:a.pathname.toLowerCase();return s===r?a.pathname="/":s.startsWith(o)&&(a.pathname=a.pathname.slice(i.length)),a},output:({url:a})=>(a.pathname=xU(["/",e,a.pathname]),a)}}function _Ee(t,e){var n;const i=(n=t==null?void 0:t.input)==null?void 0:n.call(t,{url:e});if(i){if(typeof i=="string")return new URL(i);if(i instanceof URL)return i}return e}function PEe(t,e){var n;const i=(n=t==null?void 0:t.output)==null?void 0:n.call(t,{url:e});if(i){if(typeof i=="string")return new URL(i);if(i instanceof URL)return i}return e}function sD(t){const e=t.resolvedLocation,i=t.location,n=(e==null?void 0:e.pathname)!==i.pathname,r=(e==null?void 0:e.href)!==i.href,o=(e==null?void 0:e.hash)!==i.hash;return{fromLocation:e,toLocation:i,pathChanged:n,hrefChanged:r,hashChanged:o}}class U5e{constructor(e){this.tempLocationKey=`${Math.round(Math.random()*1e7)}`,this.resetNextScroll=!0,this.shouldViewTransition=void 0,this.isViewTransitionTypesSupported=void 0,this.subscribers=new Set,this.isScrollRestoring=!1,this.isScrollRestorationSetup=!1,this.startTransition=i=>i(),this.update=i=>{var f;i.notFoundRoute&&console.warn("The notFoundRoute API is deprecated and will be removed in the next major version. See https://tanstack.com/router/v1/docs/framework/react/guide/not-found-errors#migrating-from-notfoundroute for more info.");const n=this.options,r=this.basepath??(n==null?void 0:n.basepath)??"/",o=this.basepath===void 0,a=n==null?void 0:n.rewrite;this.options={...n,...i},this.isServer=this.options.isServer??typeof document>"u",this.pathParamsDecodeCharMap=this.options.pathParamsAllowedCharacters?new Map(this.options.pathParamsAllowedCharacters.map(h=>[encodeURIComponent(h),h])):void 0,(!this.history||this.options.history&&this.options.history!==this.history)&&(this.options.history?this.history=this.options.history:this.isServer||(this.history=r5e())),this.origin=this.options.origin,this.origin||(!this.isServer&&(window!=null&&window.origin)&&window.origin!=="null"?this.origin=window.origin:this.origin="http://localhost"),this.history&&this.updateLatestLocation(),this.options.routeTree!==this.routeTree&&(this.routeTree=this.options.routeTree,this.buildRouteTree()),!this.__store&&this.latestLocation&&(this.__store=new e5e($5e(this.latestLocation),{onUpdate:()=>{this.__store.state={...this.state,cachedMatches:this.state.cachedMatches.filter(h=>!["redirected"].includes(h.status))}}}),E5e(this));let s=!1;const l=this.options.basepath??"/",u=this.options.rewrite;if(o||r!==l||a!==u){this.basepath=l;const h=[];EU(l)!==""&&h.push(H5e({basepath:l})),u&&h.push(u),this.rewrite=h.length===0?void 0:h.length===1?h[0]:V5e(h),this.history&&this.updateLatestLocation(),s=!0}s&&this.__store&&(this.__store.state={...this.state,location:this.latestLocation}),typeof window<"u"&&"CSS"in window&&typeof((f=window.CSS)==null?void 0:f.supports)=="function"&&(this.isViewTransitionTypesSupported=window.CSS.supports("selector(:active-view-transition-type(a)"))},this.updateLatestLocation=()=>{this.latestLocation=this.parseLocation(this.history.location,this.latestLocation)},this.buildRouteTree=()=>{const{routesById:i,routesByPath:n,processedTree:r}=p5e(this.routeTree,this.options.caseSensitive,(a,s)=>{a.init({originalIndex:s})});this.options.routeMasks&&u5e(this.options.routeMasks,r),this.routesById=i,this.routesByPath=n,this.processedTree=r;const o=this.options.notFoundRoute;o&&(o.init({originalIndex:99999999999}),this.routesById[o.id]=o)},this.subscribe=(i,n)=>{const r={eventType:i,fn:n};return this.subscribers.add(r),()=>{this.subscribers.delete(r)}},this.emit=i=>{this.subscribers.forEach(n=>{n.eventType===i.type&&n.fn(i)})},this.parseLocation=(i,n)=>{const r=({href:l,state:u})=>{const c=new URL(l,this.origin),d=_Ee(this.rewrite,c),f=this.options.parseSearch(d.search),h=this.options.stringifySearch(f);d.search=h;const p=d.href.replace(d.origin,""),{pathname:g,hash:v}=d;return{href:p,publicHref:l,url:d.href,pathname:noe(g),searchStr:h,search:vg(n==null?void 0:n.search,f),hash:v.split("#").reverse()[0]??"",state:vg(n==null?void 0:n.state,u)}},o=r(i),{__tempLocation:a,__tempKey:s}=o.state;if(a&&(!s||s===this.tempLocationKey)){const l=r(a);return l.state.key=o.state.key,l.state.__TSR_key=o.state.__TSR_key,delete l.state.__tempLocation,{...l,maskedLocation:o}}return o},this.resolvePathCache=f5(1e3),this.resolvePathWithBase=(i,n)=>S5e({base:i,to:VJ(n),trailingSlash:this.options.trailingSlash,cache:this.resolvePathCache}),this.matchRoutes=(i,n,r)=>typeof i=="string"?this.matchRoutesInternal({pathname:i,search:n},r):this.matchRoutesInternal(i,n),this.getMatchedRoutes=i=>W5e({pathname:i,routesById:this.routesById,processedTree:this.processedTree}),this.cancelMatch=i=>{const n=this.getMatch(i);n&&(n.abortController.abort(),clearTimeout(n._nonReactive.pendingTimeout),n._nonReactive.pendingTimeout=void 0)},this.cancelMatches=()=>{const i=this.state.matches.filter(o=>o.status==="pending"),n=this.state.matches.filter(o=>o.isFetching==="loader");new Set([...this.state.pendingMatches??[],...i,...n]).forEach(o=>{this.cancelMatch(o.id)})},this.buildLocation=i=>{const n=(o={})=>{var A,R;const a=o._fromLocation||this.pendingBuiltLocation||this.latestLocation,s=this.matchRoutes(a,{_buildLocation:!0}),l=c5(s);o.from;const u=o.unsafeRelative==="path"?a.pathname:o.from??l.fullPath,c=this.resolvePathWithBase(u,"."),d=l.search,f={...l.params},h=o.to?this.resolvePathWithBase(c,`${o.to}`):this.resolvePathWithBase(c,"."),p=o.params===!1||o.params===null?{}:(o.params??!0)===!0?f:Object.assign(f,nP(o.params,f)),g=FG({path:h,params:p}).interpolatedPath,v=this.matchRoutes(g,void 0,{_buildLocation:!0}).map(M=>this.looseRoutesById[M.routeId]);if(Object.keys(p).length>0)for(const M of v){const D=((A=M.options.params)==null?void 0:A.stringify)??M.options.stringifyParams;D&&Object.assign(p,D(p))}const y=i.leaveParams?h:noe(FG({path:h,params:p,decodeCharMap:this.pathParamsDecodeCharMap}).interpolatedPath);let m=d;if(i._includeValidateSearch&&((R=this.options.search)!=null&&R.strict)){const M={};v.forEach(D=>{if(D.options.validateSearch)try{Object.assign(M,sX(D.options.validateSearch,{...M,...m}))}catch{}}),m=M}m=G5e({search:m,dest:o,destRoutes:v,_includeValidateSearch:i._includeValidateSearch}),m=vg(d,m);const b=this.options.stringifySearch(m),S=o.hash===!0?a.hash:o.hash?nP(o.hash,a.hash):void 0,_=S?`#${S}`:"";let C=o.state===!0?a.state:o.state?nP(o.state,a.state):{};C=vg(a.state,C);const P=`${y}${b}${_}`,x=new URL(P,this.origin),E=PEe(this.rewrite,x);return{publicHref:E.pathname+E.search+E.hash,href:P,url:E.href,pathname:y,search:m,searchStr:b,state:C,hash:S??"",unmaskOnReload:o.unmaskOnReload}},r=(o={},a)=>{const s=n(o);let l=a?n(a):void 0;if(!l){const u={};if(this.options.routeMasks){const c=c5e(s.pathname,this.processedTree);if(c){Object.assign(u,c.params);const{from:d,params:f,...h}=c.route,p=f===!1||f===null?{}:(f??!0)===!0?u:Object.assign(u,nP(f,u));a={from:i.from,...h,params:p},l=n(a)}}}return l&&(s.maskedLocation=l),s};return i.mask?r(i,{from:i.from,...i.mask}):r(i)},this.commitLocation=({viewTransition:i,ignoreBlocker:n,...r})=>{const o=()=>{const l=["key","__TSR_key","__TSR_index","__hashScrollIntoViewOptions"];l.forEach(c=>{r.state[c]=this.latestLocation.state[c]});const u=oD(r.state,this.latestLocation.state);return l.forEach(c=>{delete r.state[c]}),u},a=aD(this.latestLocation.href)===aD(r.href),s=this.commitLocationPromise;if(this.commitLocationPromise=gk(()=>{s==null||s.resolve()}),a&&o())this.load();else{let{maskedLocation:l,hashScrollIntoView:u,...c}=r;l&&(c={...l,state:{...l.state,__tempKey:void 0,__tempLocation:{...c,search:c.searchStr,state:{...c.state,__tempKey:void 0,__tempLocation:void 0,__TSR_key:void 0,key:void 0}}}},(c.unmaskOnReload??this.options.unmaskOnReload??!1)&&(c.state.__tempKey=this.tempLocationKey)),c.state.__hashScrollIntoViewOptions=u??this.options.defaultHashScrollIntoView??!0,this.shouldViewTransition=i,this.history[r.replace?"replace":"push"](c.publicHref,c.state,{ignoreBlocker:n})}return this.resetNextScroll=r.resetScroll??!0,this.history.subscribers.size||this.load(),this.commitLocationPromise},this.buildAndCommitLocation=({replace:i,resetScroll:n,hashScrollIntoView:r,viewTransition:o,ignoreBlocker:a,href:s,...l}={})=>{if(s){const d=this.history.location.state.__TSR_index,f=u5(s,{__TSR_index:i?d:d+1});l.to=f.pathname,l.search=this.options.parseSearch(f.search),l.hash=f.hash.slice(1)}const u=this.buildLocation({...l,_includeValidateSearch:!0});this.pendingBuiltLocation=u;const c=this.commitLocation({...u,viewTransition:o,replace:i,resetScroll:n,hashScrollIntoView:r,ignoreBlocker:a});return Promise.resolve().then(()=>{this.pendingBuiltLocation===u&&(this.pendingBuiltLocation=void 0)}),c},this.navigate=async({to:i,reloadDocument:n,href:r,...o})=>{var a;if(!n&&r)try{new URL(`${r}`),n=!0}catch{}if(n){if(r||(r=this.buildLocation({to:i,...o}).url),!o.ignoreBlocker){const s=this.history,l=((a=s.getBlockers)==null?void 0:a.call(s))??[];for(const u of l)if(u!=null&&u.blockerFn&&await u.blockerFn({currentLocation:this.latestLocation,nextLocation:this.latestLocation,action:"PUSH"}))return Promise.resolve()}return o.replace?window.location.replace(r):window.location.href=r,Promise.resolve()}return this.buildAndCommitLocation({...o,href:r,to:i,_isNavigate:!0})},this.beforeLoad=()=>{if(this.cancelMatches(),this.updateLatestLocation(),this.isServer){const n=this.buildLocation({to:this.latestLocation.pathname,search:!0,params:!0,hash:!0,state:!0,_includeValidateSearch:!0}),r=o=>{try{return encodeURI(decodeURI(o))}catch{return o}};if(EU(r(this.latestLocation.href))!==EU(r(n.href))){let o=n.url;throw this.origin&&o.startsWith(this.origin)&&(o=o.replace(this.origin,"")||"/"),k5e({href:o})}}const i=this.matchRoutes(this.latestLocation);this.__store.setState(n=>({...n,status:"pending",statusCode:200,isLoading:!0,location:this.latestLocation,pendingMatches:i,cachedMatches:n.cachedMatches.filter(r=>!i.some(o=>o.id===r.id))}))},this.load=async i=>{let n,r,o;for(o=new Promise(s=>{this.startTransition(async()=>{var l;try{this.beforeLoad();const u=this.latestLocation,c=this.state.resolvedLocation;this.state.redirect||this.emit({type:"onBeforeNavigate",...sD({resolvedLocation:c,location:u})}),this.emit({type:"onBeforeLoad",...sD({resolvedLocation:c,location:u})}),await aoe({router:this,sync:i==null?void 0:i.sync,matches:this.state.pendingMatches,location:u,updateMatch:this.updateMatch,onReady:async()=>{this.startTransition(()=>{this.startViewTransition(async()=>{let d=[],f=[],h=[];vj(()=>{this.__store.setState(p=>{const g=p.matches,v=p.pendingMatches||p.matches;return d=g.filter(y=>!v.some(m=>m.id===y.id)),f=v.filter(y=>!g.some(m=>m.id===y.id)),h=v.filter(y=>g.some(m=>m.id===y.id)),{...p,isLoading:!1,loadedAt:Date.now(),matches:v,pendingMatches:void 0,cachedMatches:[...p.cachedMatches,...d.filter(y=>y.status!=="error"&&y.status!=="notFound")]}}),this.clearExpiredCache()}),[[d,"onLeave"],[f,"onEnter"],[h,"onStay"]].forEach(([p,g])=>{p.forEach(v=>{var y,m;(m=(y=this.looseRoutesById[v.routeId].options)[g])==null||m.call(y,v)})})})})}})}catch(u){xv(u)?(n=u,this.isServer||this.navigate({...n.options,replace:!0,ignoreBlocker:!0})):Eg(u)&&(r=u),this.__store.setState(c=>({...c,statusCode:n?n.status:r?404:c.matches.some(d=>d.status==="error")?500:200,redirect:n}))}this.latestLoadPromise===o&&((l=this.commitLocationPromise)==null||l.resolve(),this.latestLoadPromise=void 0,this.commitLocationPromise=void 0),s()})}),this.latestLoadPromise=o,await o;this.latestLoadPromise&&o!==this.latestLoadPromise;)await this.latestLoadPromise;let a;this.hasNotFoundMatch()?a=404:this.__store.state.matches.some(s=>s.status==="error")&&(a=500),a!==void 0&&this.__store.setState(s=>({...s,statusCode:a}))},this.startViewTransition=i=>{const n=this.shouldViewTransition??this.options.defaultViewTransition;if(delete this.shouldViewTransition,n&&typeof document<"u"&&"startViewTransition"in document&&typeof document.startViewTransition=="function"){let r;if(typeof n=="object"&&this.isViewTransitionTypesSupported){const o=this.latestLocation,a=this.state.resolvedLocation,s=typeof n.types=="function"?n.types(sD({resolvedLocation:a,location:o})):n.types;if(s===!1){i();return}r={update:i,types:s}}else r=i;document.startViewTransition(r)}else i()},this.updateMatch=(i,n)=>{this.startTransition(()=>{var o;const r=(o=this.state.pendingMatches)!=null&&o.some(a=>a.id===i)?"pendingMatches":this.state.matches.some(a=>a.id===i)?"matches":this.state.cachedMatches.some(a=>a.id===i)?"cachedMatches":"";r&&this.__store.setState(a=>{var s;return{...a,[r]:(s=a[r])==null?void 0:s.map(l=>l.id===i?n(l):l)}})})},this.getMatch=i=>{var r;const n=o=>o.id===i;return this.state.cachedMatches.find(n)??((r=this.state.pendingMatches)==null?void 0:r.find(n))??this.state.matches.find(n)},this.invalidate=i=>{const n=r=>{var o;return((o=i==null?void 0:i.filter)==null?void 0:o.call(i,r))??!0?{...r,invalid:!0,...i!=null&&i.forcePending||r.status==="error"||r.status==="notFound"?{status:"pending",error:void 0}:void 0}:r};return this.__store.setState(r=>{var o;return{...r,matches:r.matches.map(n),cachedMatches:r.cachedMatches.map(n),pendingMatches:(o=r.pendingMatches)==null?void 0:o.map(n)}}),this.shouldViewTransition=!1,this.load({sync:i==null?void 0:i.sync})},this.resolveRedirect=i=>{if(!i.options.href){const n=this.buildLocation(i.options);let r=n.url;this.origin&&r.startsWith(this.origin)&&(r=r.replace(this.origin,"")||"/"),i.options.href=n.href,i.headers.set("Location",r)}return i.headers.get("Location")||i.headers.set("Location",i.options.href),i},this.clearCache=i=>{const n=i==null?void 0:i.filter;n!==void 0?this.__store.setState(r=>({...r,cachedMatches:r.cachedMatches.filter(o=>!n(o))})):this.__store.setState(r=>({...r,cachedMatches:[]}))},this.clearExpiredCache=()=>{const i=n=>{const r=this.looseRoutesById[n.routeId];if(!r.options.loader)return!0;const o=(n.preload?r.options.preloadGcTime??this.options.defaultPreloadGcTime:r.options.gcTime??this.options.defaultGcTime)??300*1e3;return n.status==="error"?!0:Date.now()-n.updatedAt>=o};this.clearCache({filter:i})},this.loadRouteChunk=mEe,this.preloadRoute=async i=>{const n=this.buildLocation(i);let r=this.matchRoutes(n,{throwOnError:!0,preload:!0,dest:i});const o=new Set([...this.state.matches,...this.state.pendingMatches??[]].map(s=>s.id)),a=new Set([...o,...this.state.cachedMatches.map(s=>s.id)]);vj(()=>{r.forEach(s=>{a.has(s.id)||this.__store.setState(l=>({...l,cachedMatches:[...l.cachedMatches,s]}))})});try{return r=await aoe({router:this,matches:r,location:n,preload:!0,updateMatch:(s,l)=>{o.has(s)?r=r.map(u=>u.id===s?l(u):u):this.updateMatch(s,l)}}),r}catch(s){if(xv(s))return s.options.reloadDocument?void 0:await this.preloadRoute({...s.options,_fromLocation:n});Eg(s)||console.error(s);return}},this.matchRoute=(i,n)=>{const r={...i,to:i.to?this.resolvePathWithBase(i.from||"",i.to):void 0,params:i.params||{},leaveParams:!0},o=this.buildLocation(r);if(n!=null&&n.pending&&this.state.status!=="pending")return!1;const s=((n==null?void 0:n.pending)===void 0?!this.state.isLoading:n.pending)?this.latestLocation:this.state.resolvedLocation||this.state.location,l=d5e(o.pathname,(n==null?void 0:n.caseSensitive)??!1,(n==null?void 0:n.fuzzy)??!1,s.pathname,this.processedTree);return!l||i.params&&!oD(l.params,i.params,{partial:!0})?!1:(n==null?void 0:n.includeSearch)??!0?oD(s.search,o.search,{partial:!0})?l.params:!1:l.params},this.hasNotFoundMatch=()=>this.__store.state.matches.some(i=>i.status==="notFound"||i.globalNotFound),this.update({defaultPreloadDelay:50,defaultPendingMs:1e3,defaultPendingMinMs:500,context:void 0,...e,caseSensitive:e.caseSensitive??!1,notFoundMode:e.notFoundMode??"fuzzy",stringifySearch:e.stringifySearch??R5e,parseSearch:e.parseSearch??D5e}),typeof document<"u"&&(self.__TSR_ROUTER__=this)}isShell(){return!!this.options.isShell}isPrerendering(){return!!this.options.isPrerendering}get state(){return this.__store.state}get looseRoutesById(){return this.routesById}matchRoutesInternal(e,i){const n=this.getMatchedRoutes(e.pathname),{foundRoute:r,routeParams:o}=n;let{matchedRoutes:a}=n,s=!1;(r?r.path!=="/"&&o["**"]:aD(e.pathname))&&(this.options.notFoundRoute?a=[...a,this.options.notFoundRoute]:s=!0);const l=(()=>{if(s){if(this.options.notFoundMode!=="root")for(let d=a.length-1;d>=0;d--){const f=a[d];if(f.children)return f.id}return Sp}})(),u=[],c=d=>(d==null?void 0:d.id)?d.context??this.options.context??void 0:this.options.context??void 0;return a.forEach((d,f)=>{var D,F,I;const h=u[f-1],[p,g,v]=(()=>{const V=(h==null?void 0:h.search)??e.search,z=(h==null?void 0:h._strictSearch)??void 0;try{const G=sX(d.options.validateSearch,{...V})??void 0;return[{...V,...G},{...z,...G},void 0]}catch(G){let H=G;if(G instanceof v5||(H=new v5(G.message,{cause:G})),i!=null&&i.throwOnError)throw H;return[V,{},H]}})(),y=((F=(D=d.options).loaderDeps)==null?void 0:F.call(D,{search:p}))??"",m=y?JSON.stringify(y):"",{interpolatedPath:b,usedParams:S}=FG({path:d.fullPath,params:o,decodeCharMap:this.pathParamsDecodeCharMap}),_=d.id+b+m,C=this.getMatch(_),P=this.state.matches.find(V=>V.routeId===d.id),x=(C==null?void 0:C._strictParams)??S;let E;if(!C){const V=((I=d.options.params)==null?void 0:I.parse)??d.options.parseParams;if(V)try{Object.assign(x,V(x))}catch(z){if(Eg(z)||xv(z)?E=z:E=new z5e(z.message,{cause:z}),i!=null&&i.throwOnError)throw E}}Object.assign(o,x);const A=P?"stay":"enter";let R;if(C)R={...C,cause:A,params:P?vg(P.params,o):o,_strictParams:x,search:vg(P?P.search:C.search,p),_strictSearch:g};else{const V=d.options.loader||d.options.beforeLoad||d.lazyFn||bEe(d)?"pending":"success";R={id:_,ssr:this.isServer?void 0:d.options.ssr,index:f,routeId:d.id,params:P?vg(P.params,o):o,_strictParams:x,pathname:b,updatedAt:Date.now(),search:P?vg(P.search,p):p,_strictSearch:g,searchError:void 0,status:V,isFetching:!1,error:void 0,paramsError:E,__routeContext:void 0,_nonReactive:{loadPromise:gk()},__beforeLoadContext:void 0,context:{},abortController:new AbortController,fetchCount:0,cause:A,loaderDeps:P?vg(P.loaderDeps,y):y,invalid:!1,preload:!1,links:void 0,scripts:void 0,headScripts:void 0,meta:void 0,staticData:d.options.staticData||{},fullPath:d.fullPath}}i!=null&&i.preload||(R.globalNotFound=l===d.id),R.searchError=v;const M=c(h);R.context={...M,...R.__routeContext,...R.__beforeLoadContext},u.push(R)}),u.forEach((d,f)=>{const h=this.looseRoutesById[d.routeId];if(!this.getMatch(d.id)&&(i==null?void 0:i._buildLocation)!==!0){const g=u[f-1],v=c(g);if(h.options.context){const y={deps:d.loaderDeps,params:d.params,context:v??{},location:e,navigate:m=>this.navigate({...m,_fromLocation:e}),buildLocation:this.buildLocation,cause:d.cause,abortController:d.abortController,preload:!!d.preload,matches:u};d.__routeContext=h.options.context(y)??void 0}d.context={...v,...d.__routeContext,...d.__beforeLoadContext}}}),u}}class v5 extends Error{}class z5e extends Error{}function $5e(t){return{loadedAt:0,isLoading:!1,isTransitioning:!1,status:"idle",resolvedLocation:void 0,location:t,matches:[],pendingMatches:[],cachedMatches:[],statusCode:200}}function sX(t,e){if(t==null)return{};if("~standard"in t){const i=t["~standard"].validate(e);if(i instanceof Promise)throw new v5("Async validation not supported");if(i.issues)throw new v5(JSON.stringify(i.issues,void 0,2),{cause:i});return i.value}return"parse"in t?t.parse(e):typeof t=="function"?t(e):{}}function W5e({pathname:t,routesById:e,processedTree:i}){const n={},r=aD(t);let o;const a=f5e(r,i,!0);return a&&(o=a.route,Object.assign(n,a.params)),{matchedRoutes:(a==null?void 0:a.branch)||[e[Sp]],routeParams:n,foundRoute:o}}function G5e({search:t,dest:e,destRoutes:i,_includeValidateSearch:n}){const r=i.reduce((s,l)=>{var c;const u=[];if("search"in l.options)(c=l.options.search)!=null&&c.middlewares&&u.push(...l.options.search.middlewares);else if(l.options.preSearchFilters||l.options.postSearchFilters){const d=({search:f,next:h})=>{let p=f;"preSearchFilters"in l.options&&l.options.preSearchFilters&&(p=l.options.preSearchFilters.reduce((v,y)=>y(v),f));const g=h(p);return"postSearchFilters"in l.options&&l.options.postSearchFilters?l.options.postSearchFilters.reduce((v,y)=>y(v),g):g};u.push(d)}if(n&&l.options.validateSearch){const d=({search:f,next:h})=>{const p=h(f);try{return{...p,...sX(l.options.validateSearch,p)??void 0}}catch{return p}};u.push(d)}return s.concat(u)},[])??[],o=({search:s})=>e.search?e.search===!0?s:nP(e.search,s):{};r.push(o);const a=(s,l)=>{if(s>=r.length)return l;const u=r[s];return u({search:l,next:d=>a(s+1,d)})};return a(0,t)}const Y5e="Error preloading route! ☝️";class CEe{constructor(e){if(this.init=i=>{var u,c;this.originalIndex=i.originalIndex;const n=this.options,r=!(n!=null&&n.path)&&!(n!=null&&n.id);this.parentRoute=(c=(u=this.options).getParentRoute)==null?void 0:c.call(u),r?this._path=Sp:this.parentRoute||mS(!1);let o=r?Sp:n==null?void 0:n.path;o&&o!=="/"&&(o=fEe(o));const a=(n==null?void 0:n.id)||o;let s=r?Sp:xU([this.parentRoute.id===Sp?"":this.parentRoute.id,a]);o===Sp&&(o="/"),s!==Sp&&(s=xU(["/",s]));const l=s===Sp?"/":xU([this.parentRoute.fullPath,o]);this._path=o,this._id=s,this._fullPath=l,this._to=l},this.addChildren=i=>this._addFileChildren(i),this._addFileChildren=i=>(Array.isArray(i)&&(this.children=i),typeof i=="object"&&i!==null&&(this.children=Object.values(i)),this),this._addFileTypes=()=>this,this.updateLoader=i=>(Object.assign(this.options,i),this),this.update=i=>(Object.assign(this.options,i),this),this.lazy=i=>(this.lazyFn=i,this),this.options=e||{},this.isRoot=!(e!=null&&e.getParentRoute),e!=null&&e.id&&(e!=null&&e.path))throw new Error("Route cannot have both an 'id' and a 'path' option.")}get to(){return this._to}get id(){return this._id}get path(){return this._path}get fullPath(){return this._fullPath}}class q5e extends CEe{constructor(e){super(e)}}function HJ(t){const e=t.errorComponent??E$;return L.jsx(X5e,{getResetKey:t.getResetKey,onCatch:t.onCatch,children:({error:i,reset:n})=>i?J.createElement(e,{error:i,reset:n}):t.children})}class X5e extends J.Component{constructor(){super(...arguments),this.state={error:null}}static getDerivedStateFromProps(e){return{resetKey:e.getResetKey()}}static getDerivedStateFromError(e){return{error:e}}reset(){this.setState({error:null})}componentDidUpdate(e,i){i.error&&i.resetKey!==this.state.resetKey&&this.reset()}componentDidCatch(e,i){this.props.onCatch&&this.props.onCatch(e,i)}render(){return this.props.children({error:this.state.resetKey!==this.props.getResetKey()?null:this.state.error,reset:()=>{this.reset()}})}}function E$({error:t}){const[e,i]=J.useState(!1);return L.jsxs("div",{style:{padding:".5rem",maxWidth:"100%"},children:[L.jsxs("div",{style:{display:"flex",alignItems:"center",gap:".5rem"},children:[L.jsx("strong",{style:{fontSize:"1rem"},children:"Something went wrong!"}),L.jsx("button",{style:{appearance:"none",fontSize:".6em",border:"1px solid currentColor",padding:".1rem .2rem",fontWeight:"bold",borderRadius:".25rem"},onClick:()=>i(n=>!n),children:e?"Hide Error":"Show Error"})]}),L.jsx("div",{style:{height:".25rem"}}),e?L.jsx("div",{children:L.jsx("pre",{style:{fontSize:".7em",border:"1px solid red",borderRadius:".25rem",padding:".3rem",color:"red",overflow:"auto"},children:t.message?L.jsx("code",{children:t.message}):null})}):null]})}function K5e({children:t,fallback:e=null}){return Z5e()?L.jsx(Wn.Fragment,{children:t}):L.jsx(Wn.Fragment,{children:e})}function Z5e(){return Wn.useSyncExternalStore(J5e,()=>!0,()=>!1)}function J5e(){return()=>{}}var jG={exports:{}},VG={},HG={exports:{}},UG={};/**
 * @license React
 * use-sync-external-store-shim.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 soe;function Q5e(){if(soe)return UG;soe=1;var t=ld();function e(d,f){return d===f&&(d!==0||1/d===1/f)||d!==d&&f!==f}var i=typeof Object.is=="function"?Object.is:e,n=t.useState,r=t.useEffect,o=t.useLayoutEffect,a=t.useDebugValue;function s(d,f){var h=f(),p=n({inst:{value:h,getSnapshot:f}}),g=p[0].inst,v=p[1];return o(function(){g.value=h,g.getSnapshot=f,l(g)&&v({inst:g})},[d,h,f]),r(function(){return l(g)&&v({inst:g}),d(function(){l(g)&&v({inst:g})})},[d]),a(h),h}function l(d){var f=d.getSnapshot;d=d.value;try{var h=f();return!i(d,h)}catch{return!0}}function u(d,f){return f()}var c=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?u:s;return UG.useSyncExternalStore=t.useSyncExternalStore!==void 0?t.useSyncExternalStore:c,UG}var loe;function eze(){return loe||(loe=1,HG.exports=Q5e()),HG.exports}/**
 * @license React
 * use-sync-external-store-shim/with-selector.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 uoe;function tze(){if(uoe)return VG;uoe=1;var t=ld(),e=eze();function i(u,c){return u===c&&(u!==0||1/u===1/c)||u!==u&&c!==c}var n=typeof Object.is=="function"?Object.is:i,r=e.useSyncExternalStore,o=t.useRef,a=t.useEffect,s=t.useMemo,l=t.useDebugValue;return VG.useSyncExternalStoreWithSelector=function(u,c,d,f,h){var p=o(null);if(p.current===null){var g={hasValue:!1,value:null};p.current=g}else g=p.current;p=s(function(){function y(C){if(!m){if(m=!0,b=C,C=f(C),h!==void 0&&g.hasValue){var P=g.value;if(h(P,C))return S=P}return S=C}if(P=S,n(b,C))return P;var x=f(C);return h!==void 0&&h(P,x)?(b=C,P):(b=C,S=x)}var m=!1,b,S,_=d===void 0?null:d;return[function(){return y(c())},_===null?void 0:function(){return y(_())}]},[c,d,f,h]);var v=r(u,p[0],p[1]);return a(function(){g.hasValue=!0,g.value=v},[v]),l(v),v},VG}var coe;function rze(){return coe||(coe=1,jG.exports=tze()),jG.exports}var ize=rze();function nze(t,e=n=>n,i={}){const n=i.equal??oze;return ize.useSyncExternalStoreWithSelector(t.subscribe,()=>t.state,()=>t.state,e,n)}function oze(t,e){if(Object.is(t,e))return!0;if(typeof t!="object"||t===null||typeof e!="object"||e===null)return!1;if(t instanceof Map&&e instanceof Map){if(t.size!==e.size)return!1;for(const[n,r]of t)if(!e.has(n)||!Object.is(r,e.get(n)))return!1;return!0}if(t instanceof Set&&e instanceof Set){if(t.size!==e.size)return!1;for(const n of t)if(!e.has(n))return!1;return!0}if(t instanceof Date&&e instanceof Date)return t.getTime()===e.getTime();const i=doe(t);if(i.length!==doe(e).length)return!1;for(let n=0;n<i.length;n++)if(!Object.prototype.hasOwnProperty.call(e,i[n])||!Object.is(t[i[n]],e[i[n]]))return!1;return!0}function doe(t){return Object.keys(t).concat(Object.getOwnPropertySymbols(t))}const zG=J.createContext(null);function TEe(){return typeof document>"u"?zG:window.__TSR_ROUTER_CONTEXT__?window.__TSR_ROUTER_CONTEXT__:(window.__TSR_ROUTER_CONTEXT__=zG,zG)}function Rp(t){const e=J.useContext(TEe());return t==null||t.warn,e}function Oh(t){const e=Rp({warn:(t==null?void 0:t.router)===void 0}),i=(t==null?void 0:t.router)||e,n=J.useRef(void 0);return nze(i.__store,r=>{if(t!=null&&t.select){if(t.structuralSharing??i.options.defaultStructuralSharing){const o=vg(n.current,t.select(r));return n.current=o,o}return t.select(r)}return r})}const w$=J.createContext(void 0),aze=J.createContext(void 0);function lm(t){const e=J.useContext(t.from?aze:w$);return Oh({select:n=>{const r=n.matches.find(o=>t.from?t.from===o.routeId:o.id===e);if(mS(!((t.shouldThrow??!0)&&!r),`Could not find ${t.from?`an active match from "${t.from}"`:"a nearest match!"}`),r!==void 0)return t.select?t.select(r):r},structuralSharing:t.structuralSharing})}function UJ(t){return lm({from:t.from,strict:t.strict,structuralSharing:t.structuralSharing,select:e=>t.select?t.select(e.loaderData):e.loaderData})}function zJ(t){const{select:e,...i}=t;return lm({...i,select:n=>e?e(n.loaderDeps):n.loaderDeps})}function $J(t){return lm({from:t.from,shouldThrow:t.shouldThrow,structuralSharing:t.structuralSharing,strict:t.strict,select:e=>{const i=t.strict===!1?e.params:e._strictParams;return t.select?t.select(i):i}})}function WJ(t){return lm({from:t.from,strict:t.strict,shouldThrow:t.shouldThrow,structuralSharing:t.structuralSharing,select:e=>t.select?t.select(e.search):e.search})}const vH=typeof window<"u"?J.useLayoutEffect:J.useEffect;function $G(t){const e=J.useRef({value:t,prev:null}),i=e.current.value;return t!==i&&(e.current={value:t,prev:i}),e.current.prev}function sze(t,e,i={},n={}){J.useEffect(()=>{if(!t.current||n.disabled||typeof IntersectionObserver!="function")return;const r=new IntersectionObserver(([o])=>{e(o)},i);return r.observe(t.current),()=>{r.disconnect()}},[e,i,n.disabled,t])}function lze(t){const e=J.useRef(null);return J.useImperativeHandle(t,()=>e.current,[]),e}function GJ(t){const e=Rp();return J.useCallback(i=>e.navigate({...i,from:i.from??(t==null?void 0:t.from)}),[t==null?void 0:t.from,e])}var zf=uEe();const uze=wc(zf);function cze(t,e){const i=Rp(),[n,r]=J.useState(!1),o=J.useRef(!1),a=lze(e),{activeProps:s,inactiveProps:l,activeOptions:u,to:c,preload:d,preloadDelay:f,hashScrollIntoView:h,replace:p,startTransition:g,resetScroll:v,viewTransition:y,children:m,target:b,disabled:S,style:_,className:C,onClick:P,onFocus:x,onMouseEnter:E,onMouseLeave:A,onTouchStart:R,ignoreBlocker:M,params:D,search:F,hash:I,state:V,mask:z,reloadDocument:G,unsafeRelative:H,from:U,_fromLocation:k,...X}=t,W=Oh({select:Ue=>Ue.location.search,structuralSharing:!0}),Y=t.from,te=J.useMemo(()=>({...t,from:Y}),[i,W,Y,t._fromLocation,t.hash,t.to,t.search,t.params,t.state,t.mask,t.unsafeRelative]),oe=J.useMemo(()=>i.buildLocation({...te}),[i,te]),de=J.useMemo(()=>{if(S)return;let Ue=oe.maskedLocation?oe.maskedLocation.url:oe.url,Qe=!1;return i.origin&&(Ue.startsWith(i.origin)?Ue=i.history.createHref(Ue.replace(i.origin,""))||"/":Qe=!0),{href:Ue,external:Qe}},[S,oe.maskedLocation,oe.url,i.origin,i.history]),ge=J.useMemo(()=>{if(de!=null&&de.external)return de.href;try{return new URL(c),c}catch{}},[c,de]),Ee=t.reloadDocument||ge?!1:d??i.options.defaultPreload,Re=f??i.options.defaultPreloadDelay??0,Ae=Oh({select:Ue=>{if(ge)return!1;if(u!=null&&u.exact){if(!b5e(Ue.location.pathname,oe.pathname,i.basepath))return!1}else{const Qe=h5(Ue.location.pathname,i.basepath),it=h5(oe.pathname,i.basepath);if(!(Qe.startsWith(it)&&(Qe.length===it.length||Qe[it.length]==="/")))return!1}return((u==null?void 0:u.includeSearch)??!0)&&!oD(Ue.location.search,oe.search,{partial:!(u!=null&&u.exact),ignoreUndefined:!(u!=null&&u.explicitUndefined)})?!1:u!=null&&u.includeHash?Ue.location.hash===oe.hash:!0}}),Pe=J.useCallback(()=>{i.preloadRoute({...te}).catch(Ue=>{console.warn(Ue),console.warn(Y5e)})},[i,te]),we=J.useCallback(Ue=>{Ue!=null&&Ue.isIntersecting&&Pe()},[Pe]);sze(a,we,gze,{disabled:!!S||Ee!=="viewport"}),J.useEffect(()=>{o.current||!S&&Ee==="render"&&(Pe(),o.current=!0)},[S,Pe,Ee]);const Te=Ue=>{const Qe=Ue.currentTarget.getAttribute("target"),it=b!==void 0?b:Qe;if(!S&&!vze(Ue)&&!Ue.defaultPrevented&&(!it||it==="_self")&&Ue.button===0){Ue.preventDefault(),zf.flushSync(()=>{r(!0)});const xt=i.subscribe("onResolved",()=>{xt(),r(!1)});i.navigate({...te,replace:p,resetScroll:v,hashScrollIntoView:h,startTransition:g,viewTransition:y,ignoreBlocker:M})}};if(ge)return{...X,ref:a,href:ge,...m&&{children:m},...b&&{target:b},...S&&{disabled:S},..._&&{style:_},...C&&{className:C},...P&&{onClick:P},...x&&{onFocus:x},...E&&{onMouseEnter:E},...A&&{onMouseLeave:A},...R&&{onTouchStart:R}};const ke=Ue=>{S||Ee&&Pe()},$e=ke,Ne=Ue=>{if(!(S||!Ee))if(!Re)Pe();else{const Qe=Ue.target;if(H2.has(Qe))return;const it=setTimeout(()=>{H2.delete(Qe),Pe()},Re);H2.set(Qe,it)}},ve=Ue=>{if(S||!Ee||!Re)return;const Qe=Ue.target,it=H2.get(Qe);it&&(clearTimeout(it),H2.delete(Qe))},pe=Ae?nP(s,{})??dze:WG,fe=Ae?WG:nP(l,{})??WG,me=[C,pe.className,fe.className].filter(Boolean).join(" "),Ce=(_||pe.style||fe.style)&&{..._,...pe.style,...fe.style};return{...X,...pe,...fe,href:de==null?void 0:de.href,ref:a,onClick:U2([P,Te]),onFocus:U2([x,ke]),onMouseEnter:U2([E,Ne]),onMouseLeave:U2([A,ve]),onTouchStart:U2([R,$e]),disabled:!!S,target:b,...Ce&&{style:Ce},...me&&{className:me},...S&&fze,...Ae&&hze,...n&&pze}}const WG={},dze={className:"active"},fze={role:"link","aria-disabled":!0},hze={"data-status":"active","aria-current":"page"},pze={"data-transitioning":"transitioning"},H2=new WeakMap,gze={rootMargin:"100px"},U2=t=>e=>{for(const i of t)if(i){if(e.defaultPrevented)return;i(e)}},xEe=J.forwardRef((t,e)=>{const{_asChild:i,...n}=t,{type:r,ref:o,...a}=cze(n,e),s=typeof n.children=="function"?n.children({isActive:a["data-status"]==="active"}):n.children;return i===void 0&&delete a.disabled,J.createElement(i||"a",{...a,ref:o},s)});function vze(t){return!!(t.metaKey||t.altKey||t.ctrlKey||t.shiftKey)}class yze extends CEe{constructor(e){super(e),this.useMatch=i=>lm({select:i==null?void 0:i.select,from:this.id,structuralSharing:i==null?void 0:i.structuralSharing}),this.useRouteContext=i=>lm({...i,from:this.id,select:n=>i!=null&&i.select?i.select(n.context):n.context}),this.useSearch=i=>WJ({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.id}),this.useParams=i=>$J({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.id}),this.useLoaderDeps=i=>zJ({...i,from:this.id}),this.useLoaderData=i=>UJ({...i,from:this.id}),this.useNavigate=()=>GJ({from:this.fullPath}),this.Link=Wn.forwardRef((i,n)=>L.jsx(xEe,{ref:n,from:this.fullPath,...i})),this.$$typeof=Symbol.for("react.memo")}}function mze(t){return new yze(t)}class bze extends q5e{constructor(e){super(e),this.useMatch=i=>lm({select:i==null?void 0:i.select,from:this.id,structuralSharing:i==null?void 0:i.structuralSharing}),this.useRouteContext=i=>lm({...i,from:this.id,select:n=>i!=null&&i.select?i.select(n.context):n.context}),this.useSearch=i=>WJ({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.id}),this.useParams=i=>$J({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.id}),this.useLoaderDeps=i=>zJ({...i,from:this.id}),this.useLoaderData=i=>UJ({...i,from:this.id}),this.useNavigate=()=>GJ({from:this.fullPath}),this.Link=Wn.forwardRef((i,n)=>L.jsx(xEe,{ref:n,from:this.fullPath,...i})),this.$$typeof=Symbol.for("react.memo")}}function Sze(t){return new bze(t)}function foe(t){return typeof t=="object"?new hoe(t,{silent:!0}).createRoute(t):new hoe(t,{silent:!0}).createRoute}class hoe{constructor(e,i){this.path=e,this.createRoute=n=>{this.silent;const r=mze(n);return r.isRoot=!1,r},this.silent=i==null?void 0:i.silent}}class poe{constructor(e){this.useMatch=i=>lm({select:i==null?void 0:i.select,from:this.options.id,structuralSharing:i==null?void 0:i.structuralSharing}),this.useRouteContext=i=>lm({from:this.options.id,select:n=>i!=null&&i.select?i.select(n.context):n.context}),this.useSearch=i=>WJ({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.options.id}),this.useParams=i=>$J({select:i==null?void 0:i.select,structuralSharing:i==null?void 0:i.structuralSharing,from:this.options.id}),this.useLoaderDeps=i=>zJ({...i,from:this.options.id}),this.useLoaderData=i=>UJ({...i,from:this.options.id}),this.useNavigate=()=>{const i=Rp();return GJ({from:i.routesById[this.options.id].fullPath})},this.options=e,this.$$typeof=Symbol.for("react.memo")}}function goe(t){return typeof t=="object"?new poe(t):e=>new poe({id:t,...e})}function _ze(){const t=Rp(),e=J.useRef({router:t,mounted:!1}),[i,n]=J.useState(!1),{hasPendingMatches:r,isLoading:o}=Oh({select:d=>({isLoading:d.isLoading,hasPendingMatches:d.matches.some(f=>f.status==="pending")}),structuralSharing:!0}),a=$G(o),s=o||i||r,l=$G(s),u=o||r,c=$G(u);return t.startTransition=d=>{n(!0),J.startTransition(()=>{d(),n(!1)})},J.useEffect(()=>{const d=t.history.subscribe(t.load),f=t.buildLocation({to:t.latestLocation.pathname,search:!0,params:!0,hash:!0,state:!0,_includeValidateSearch:!0});return aD(t.latestLocation.href)!==aD(f.href)&&t.commitLocation({...f,replace:!0}),()=>{d()}},[t,t.history]),vH(()=>{if(typeof window<"u"&&t.ssr||e.current.router===t&&e.current.mounted)return;e.current={router:t,mounted:!0},(async()=>{try{await t.load()}catch(f){console.error(f)}})()},[t]),vH(()=>{a&&!o&&t.emit({type:"onLoad",...sD(t.state)})},[a,t,o]),vH(()=>{c&&!u&&t.emit({type:"onBeforeRouteMount",...sD(t.state)})},[u,c,t]),vH(()=>{if(l&&!s){const d=sD(t.state);t.emit({type:"onResolved",...d}),t.__store.setState(f=>({...f,status:"idle",resolvedLocation:f.location})),d.hrefChanged&&w5e(t)}},[s,l,t]),null}function Pze(t){const e=Oh({select:i=>`not-found-${i.location.pathname}-${i.status}`});return L.jsx(HJ,{getResetKey:()=>e,onCatch:(i,n)=>{var r;if(Eg(i))(r=t.onCatch)==null||r.call(t,i,n);else throw i},errorComponent:({error:i})=>{var n;if(Eg(i))return(n=t.fallback)==null?void 0:n.call(t,i);throw i},children:t.children})}function Cze(){return L.jsx("p",{children:"Not Found"})}function hL(t){return L.jsx(L.Fragment,{children:t.children})}function EEe(t,e,i){return e.options.notFoundComponent?L.jsx(e.options.notFoundComponent,{...i}):t.options.defaultNotFoundComponent?L.jsx(t.options.defaultNotFoundComponent,{...i}):L.jsx(Cze,{})}function Tze({children:t}){var i;const e=Rp();return e.isServer?L.jsx("script",{nonce:(i=e.options.ssr)==null?void 0:i.nonce,className:"$tsr",dangerouslySetInnerHTML:{__html:t+';typeof $_TSR !== "undefined" && $_TSR.c()'}}):null}function xze(){const t=Rp();if(!t.isScrollRestoring||!t.isServer||typeof t.options.scrollRestoration=="function"&&!t.options.scrollRestoration({location:t.latestLocation}))return null;const i=(t.options.getScrollRestorationKey||aX)(t.latestLocation),n=i!==aX(t.latestLocation)?i:void 0,r={storageKey:p5,shouldScrollRestoration:!0};return n&&(r.key=n),L.jsx(Tze,{children:`(${hEe.toString()})(${JSON.stringify(r)})`})}const wEe=J.memo(function({matchId:e}){var y,m;const i=Rp(),n=Oh({select:b=>{const S=b.matches.find(_=>_.id===e);return mS(S),{routeId:S.routeId,ssr:S.ssr,_displayPending:S._displayPending}},structuralSharing:!0}),r=i.routesById[n.routeId],o=r.options.pendingComponent??i.options.defaultPendingComponent,a=o?L.jsx(o,{}):null,s=r.options.errorComponent??i.options.defaultErrorComponent,l=r.options.onCatch??i.options.defaultOnCatch,u=r.isRoot?r.options.notFoundComponent??((y=i.options.notFoundRoute)==null?void 0:y.options.component):r.options.notFoundComponent,c=n.ssr===!1||n.ssr==="data-only",d=(!r.isRoot||r.options.wrapInSuspense||c)&&(r.options.wrapInSuspense??o??(((m=r.options.errorComponent)==null?void 0:m.preload)||c))?J.Suspense:hL,f=s?HJ:hL,h=u?Pze:hL,p=Oh({select:b=>b.loadedAt}),g=Oh({select:b=>{var _;const S=b.matches.findIndex(C=>C.id===e);return(_=b.matches[S-1])==null?void 0:_.routeId}}),v=r.isRoot?r.options.shellComponent??hL:hL;return L.jsxs(v,{children:[L.jsx(w$.Provider,{value:e,children:L.jsx(d,{fallback:a,children:L.jsx(f,{getResetKey:()=>p,errorComponent:s||E$,onCatch:(b,S)=>{if(Eg(b))throw b;l==null||l(b,S)},children:L.jsx(h,{fallback:b=>{if(!u||b.routeId&&b.routeId!==n.routeId||!b.routeId&&!r.isRoot)throw b;return J.createElement(u,b)},children:c||n._displayPending?L.jsx(K5e,{fallback:a,children:L.jsx(voe,{matchId:e})}):L.jsx(voe,{matchId:e})})})})}),g===Sp&&i.options.scrollRestoration?L.jsxs(L.Fragment,{children:[L.jsx(Eze,{}),L.jsx(xze,{})]}):null]})});function Eze(){const t=Rp(),e=J.useRef(void 0);return L.jsx("script",{suppressHydrationWarning:!0,ref:i=>{i&&(e.current===void 0||e.current.href!==t.latestLocation.href)&&(t.emit({type:"onRendered",...sD(t.state)}),e.current=t.latestLocation)}},t.latestLocation.state.__TSR_key)}const voe=J.memo(function({matchId:e}){var l,u,c,d;const i=Rp(),{match:n,key:r,routeId:o}=Oh({select:f=>{const h=f.matches.find(m=>m.id===e),p=h.routeId,g=i.routesById[p].options.remountDeps??i.options.defaultRemountDeps,v=g==null?void 0:g({routeId:p,loaderDeps:h.loaderDeps,params:h._strictParams,search:h._strictSearch});return{key:v?JSON.stringify(v):void 0,routeId:p,match:{id:h.id,status:h.status,error:h.error,_forcePending:h._forcePending,_displayPending:h._displayPending}}},structuralSharing:!0}),a=i.routesById[o],s=J.useMemo(()=>{const f=a.options.component??i.options.defaultComponent;return f?L.jsx(f,{},r):L.jsx(wze,{})},[r,a.options.component,i.options.defaultComponent]);if(n._displayPending)throw(l=i.getMatch(n.id))==null?void 0:l._nonReactive.displayPendingPromise;if(n._forcePending)throw(u=i.getMatch(n.id))==null?void 0:u._nonReactive.minPendingPromise;if(n.status==="pending"){const f=a.options.pendingMinMs??i.options.defaultPendingMinMs;if(f){const h=i.getMatch(n.id);if(h&&!h._nonReactive.minPendingPromise&&!i.isServer){const p=gk();h._nonReactive.minPendingPromise=p,setTimeout(()=>{p.resolve(),h._nonReactive.minPendingPromise=void 0},f)}}throw(c=i.getMatch(n.id))==null?void 0:c._nonReactive.loadPromise}if(n.status==="notFound")return mS(Eg(n.error)),EEe(i,a,n.error);if(n.status==="redirected")throw mS(xv(n.error)),(d=i.getMatch(n.id))==null?void 0:d._nonReactive.loadPromise;if(n.status==="error"){if(i.isServer){const f=(a.options.errorComponent??i.options.defaultErrorComponent)||E$;return L.jsx(f,{error:n.error,reset:void 0,info:{componentStack:""}})}throw n.error}return s}),wze=J.memo(function(){const e=Rp(),i=J.useContext(w$),n=Oh({select:u=>{var c;return(c=u.matches.find(d=>d.id===i))==null?void 0:c.routeId}}),r=e.routesById[n],o=Oh({select:u=>{const d=u.matches.find(f=>f.id===i);return mS(d),d.globalNotFound}}),a=Oh({select:u=>{var f;const c=u.matches,d=c.findIndex(h=>h.id===i);return(f=c[d+1])==null?void 0:f.id}}),s=e.options.defaultPendingComponent?L.jsx(e.options.defaultPendingComponent,{}):null;if(o)return EEe(e,r,void 0);if(!a)return null;const l=L.jsx(wEe,{matchId:a});return n===Sp?L.jsx(J.Suspense,{fallback:s,children:l}):l});function Aze(){const t=Rp(),i=t.routesById[Sp].options.pendingComponent??t.options.defaultPendingComponent,n=i?L.jsx(i,{}):null,r=t.isServer||typeof document<"u"&&t.ssr?hL:J.Suspense,o=L.jsxs(r,{fallback:n,children:[!t.isServer&&L.jsx(_ze,{}),L.jsx(Oze,{})]});return t.options.InnerWrap?L.jsx(t.options.InnerWrap,{children:o}):o}function Oze(){const t=Rp(),e=Oh({select:r=>{var o;return(o=r.matches[0])==null?void 0:o.id}}),i=Oh({select:r=>r.loadedAt}),n=e?L.jsx(wEe,{matchId:e}):null;return L.jsx(w$.Provider,{value:e,children:t.options.disableGlobalCatchBoundary?n:L.jsx(HJ,{getResetKey:()=>i,errorComponent:E$,onCatch:r=>{r.message||r.toString()},children:n})})}const Dze=t=>new Rze(t);class Rze extends U5e{constructor(e){super(e)}}typeof globalThis<"u"?(globalThis.createFileRoute=foe,globalThis.createLazyFileRoute=goe):typeof window<"u"&&(window.createFileRoute=foe,window.createLazyFileRoute=goe);function Mze({router:t,children:e,...i}){Object.keys(i).length>0&&t.update({...t.options,...i,context:{...t.options.context,...i.context}});const n=TEe(),r=L.jsx(n.Provider,{value:t,children:e});return t.options.Wrap?L.jsx(t.options.Wrap,{children:r}):r}function Lze({router:t,...e}){return L.jsx(Mze,{router:t,...e,children:L.jsx(Aze,{})})}var GG={exports:{}},YG={};/**
 * @license React
 * react-compiler-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 yoe;function kze(){if(yoe)return YG;yoe=1;var t=ld().__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;return YG.c=function(e){return t.H.useMemoCache(e)},YG}var moe;function Ize(){return moe||(moe=1,GG.exports=kze()),GG.exports}var qt=Ize();function AEe(t){var e,i,n="";if(typeof t=="string"||typeof t=="number")n+=t;else if(typeof t=="object")if(Array.isArray(t)){var r=t.length;for(e=0;e<r;e++)t[e]&&(i=AEe(t[e]))&&(n&&(n+=" "),n+=i)}else for(i in t)t[i]&&(n&&(n+=" "),n+=i);return n}function Rv(){for(var t,e,i=0,n="",r=arguments.length;i<r;i++)(t=arguments[i])&&(e=AEe(t))&&(n&&(n+=" "),n+=e);return n}const YJ="-",Nze=t=>{const e=Bze(t),{conflictingClassGroups:i,conflictingClassGroupModifiers:n}=t;return{getClassGroupId:a=>{const s=a.split(YJ);return s[0]===""&&s.length!==1&&s.shift(),OEe(s,e)||Fze(a)},getConflictingClassGroupIds:(a,s)=>{const l=i[a]||[];return s&&n[a]?[...l,...n[a]]:l}}},OEe=(t,e)=>{var a;if(t.length===0)return e.classGroupId;const i=t[0],n=e.nextPart.get(i),r=n?OEe(t.slice(1),n):void 0;if(r)return r;if(e.validators.length===0)return;const o=t.join(YJ);return(a=e.validators.find(({validator:s})=>s(o)))==null?void 0:a.classGroupId},boe=/^\[(.+)\]$/,Fze=t=>{if(boe.test(t)){const e=boe.exec(t)[1],i=e==null?void 0:e.substring(0,e.indexOf(":"));if(i)return"arbitrary.."+i}},Bze=t=>{const{theme:e,prefix:i}=t,n={nextPart:new Map,validators:[]};return Vze(Object.entries(t.classGroups),i).forEach(([o,a])=>{lX(a,n,o,e)}),n},lX=(t,e,i,n)=>{t.forEach(r=>{if(typeof r=="string"){const o=r===""?e:Soe(e,r);o.classGroupId=i;return}if(typeof r=="function"){if(jze(r)){lX(r(n),e,i,n);return}e.validators.push({validator:r,classGroupId:i});return}Object.entries(r).forEach(([o,a])=>{lX(a,Soe(e,o),i,n)})})},Soe=(t,e)=>{let i=t;return e.split(YJ).forEach(n=>{i.nextPart.has(n)||i.nextPart.set(n,{nextPart:new Map,validators:[]}),i=i.nextPart.get(n)}),i},jze=t=>t.isThemeGetter,Vze=(t,e)=>e?t.map(([i,n])=>{const r=n.map(o=>typeof o=="string"?e+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([a,s])=>[e+a,s])):o);return[i,r]}):t,Hze=t=>{if(t<1)return{get:()=>{},set:()=>{}};let e=0,i=new Map,n=new Map;const r=(o,a)=>{i.set(o,a),e++,e>t&&(e=0,n=i,i=new Map)};return{get(o){let a=i.get(o);if(a!==void 0)return a;if((a=n.get(o))!==void 0)return r(o,a),a},set(o,a){i.has(o)?i.set(o,a):r(o,a)}}},DEe="!",Uze=t=>{const{separator:e,experimentalParseClassName:i}=t,n=e.length===1,r=e[0],o=e.length,a=s=>{const l=[];let u=0,c=0,d;for(let v=0;v<s.length;v++){let y=s[v];if(u===0){if(y===r&&(n||s.slice(v,v+o)===e)){l.push(s.slice(c,v)),c=v+o;continue}if(y==="/"){d=v;continue}}y==="["?u++:y==="]"&&u--}const f=l.length===0?s:s.substring(c),h=f.startsWith(DEe),p=h?f.substring(1):f,g=d&&d>c?d-c:void 0;return{modifiers:l,hasImportantModifier:h,baseClassName:p,maybePostfixModifierPosition:g}};return i?s=>i({className:s,parseClassName:a}):a},zze=t=>{if(t.length<=1)return t;const e=[];let i=[];return t.forEach(n=>{n[0]==="["?(e.push(...i.sort(),n),i=[]):i.push(n)}),e.push(...i.sort()),e},$ze=t=>({cache:Hze(t.cacheSize),parseClassName:Uze(t),...Nze(t)}),Wze=/\s+/,Gze=(t,e)=>{const{parseClassName:i,getClassGroupId:n,getConflictingClassGroupIds:r}=e,o=[],a=t.trim().split(Wze);let s="";for(let l=a.length-1;l>=0;l-=1){const u=a[l],{modifiers:c,hasImportantModifier:d,baseClassName:f,maybePostfixModifierPosition:h}=i(u);let p=!!h,g=n(p?f.substring(0,h):f);if(!g){if(!p){s=u+(s.length>0?" "+s:s);continue}if(g=n(f),!g){s=u+(s.length>0?" "+s:s);continue}p=!1}const v=zze(c).join(":"),y=d?v+DEe:v,m=y+g;if(o.includes(m))continue;o.push(m);const b=r(g,p);for(let S=0;S<b.length;++S){const _=b[S];o.push(y+_)}s=u+(s.length>0?" "+s:s)}return s};function Yze(){let t=0,e,i,n="";for(;t<arguments.length;)(e=arguments[t++])&&(i=REe(e))&&(n&&(n+=" "),n+=i);return n}const REe=t=>{if(typeof t=="string")return t;let e,i="";for(let n=0;n<t.length;n++)t[n]&&(e=REe(t[n]))&&(i&&(i+=" "),i+=e);return i};function qze(t,...e){let i,n,r,o=a;function a(l){const u=e.reduce((c,d)=>d(c),t());return i=$ze(u),n=i.cache.get,r=i.cache.set,o=s,s(l)}function s(l){const u=n(l);if(u)return u;const c=Gze(l,i);return r(l,c),c}return function(){return o(Yze.apply(null,arguments))}}const xs=t=>{const e=i=>i[t]||[];return e.isThemeGetter=!0,e},MEe=/^\[(?:([a-z-]+):)?(.+)\]$/i,Xze=/^\d+\/\d+$/,Kze=new Set(["px","full","screen"]),Zze=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Jze=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Qze=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,e$e=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,t$e=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,w0=t=>BL(t)||Kze.has(t)||Xze.test(t),N_=t=>aI(t,"length",u$e),BL=t=>!!t&&!Number.isNaN(Number(t)),qG=t=>aI(t,"number",BL),z2=t=>!!t&&Number.isInteger(Number(t)),r$e=t=>t.endsWith("%")&&BL(t.slice(0,-1)),$n=t=>MEe.test(t),F_=t=>Zze.test(t),i$e=new Set(["length","size","percentage"]),n$e=t=>aI(t,i$e,LEe),o$e=t=>aI(t,"position",LEe),a$e=new Set(["image","url"]),s$e=t=>aI(t,a$e,d$e),l$e=t=>aI(t,"",c$e),$2=()=>!0,aI=(t,e,i)=>{const n=MEe.exec(t);return n?n[1]?typeof e=="string"?n[1]===e:e.has(n[1]):i(n[2]):!1},u$e=t=>Jze.test(t)&&!Qze.test(t),LEe=()=>!1,c$e=t=>e$e.test(t),d$e=t=>t$e.test(t),f$e=()=>{const t=xs("colors"),e=xs("spacing"),i=xs("blur"),n=xs("brightness"),r=xs("borderColor"),o=xs("borderRadius"),a=xs("borderSpacing"),s=xs("borderWidth"),l=xs("contrast"),u=xs("grayscale"),c=xs("hueRotate"),d=xs("invert"),f=xs("gap"),h=xs("gradientColorStops"),p=xs("gradientColorStopPositions"),g=xs("inset"),v=xs("margin"),y=xs("opacity"),m=xs("padding"),b=xs("saturate"),S=xs("scale"),_=xs("sepia"),C=xs("skew"),P=xs("space"),x=xs("translate"),E=()=>["auto","contain","none"],A=()=>["auto","hidden","clip","visible","scroll"],R=()=>["auto",$n,e],M=()=>[$n,e],D=()=>["",w0,N_],F=()=>["auto",BL,$n],I=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],V=()=>["solid","dashed","dotted","double","none"],z=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],G=()=>["start","end","center","between","around","evenly","stretch"],H=()=>["","0",$n],U=()=>["auto","avoid","all","avoid-page","page","left","right","column"],k=()=>[BL,$n];return{cacheSize:500,separator:":",theme:{colors:[$2],spacing:[w0,N_],blur:["none","",F_,$n],brightness:k(),borderColor:[t],borderRadius:["none","","full",F_,$n],borderSpacing:M(),borderWidth:D(),contrast:k(),grayscale:H(),hueRotate:k(),invert:H(),gap:M(),gradientColorStops:[t],gradientColorStopPositions:[r$e,N_],inset:R(),margin:R(),opacity:k(),padding:M(),saturate:k(),scale:k(),sepia:H(),skew:k(),space:M(),translate:M()},classGroups:{aspect:[{aspect:["auto","square","video",$n]}],container:["container"],columns:[{columns:[F_]}],"break-after":[{"break-after":U()}],"break-before":[{"break-before":U()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...I(),$n]}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:E()}],"overscroll-x":[{"overscroll-x":E()}],"overscroll-y":[{"overscroll-y":E()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[g]}],"inset-x":[{"inset-x":[g]}],"inset-y":[{"inset-y":[g]}],start:[{start:[g]}],end:[{end:[g]}],top:[{top:[g]}],right:[{right:[g]}],bottom:[{bottom:[g]}],left:[{left:[g]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",z2,$n]}],basis:[{basis:R()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",$n]}],grow:[{grow:H()}],shrink:[{shrink:H()}],order:[{order:["first","last","none",z2,$n]}],"grid-cols":[{"grid-cols":[$2]}],"col-start-end":[{col:["auto",{span:["full",z2,$n]},$n]}],"col-start":[{"col-start":F()}],"col-end":[{"col-end":F()}],"grid-rows":[{"grid-rows":[$2]}],"row-start-end":[{row:["auto",{span:[z2,$n]},$n]}],"row-start":[{"row-start":F()}],"row-end":[{"row-end":F()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",$n]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",$n]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...G()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...G(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...G(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],m:[{m:[v]}],mx:[{mx:[v]}],my:[{my:[v]}],ms:[{ms:[v]}],me:[{me:[v]}],mt:[{mt:[v]}],mr:[{mr:[v]}],mb:[{mb:[v]}],ml:[{ml:[v]}],"space-x":[{"space-x":[P]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[P]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",$n,e]}],"min-w":[{"min-w":[$n,e,"min","max","fit"]}],"max-w":[{"max-w":[$n,e,"none","full","min","max","fit","prose",{screen:[F_]},F_]}],h:[{h:[$n,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[$n,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[$n,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[$n,e,"auto","min","max","fit"]}],"font-size":[{text:["base",F_,N_]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",qG]}],"font-family":[{font:[$2]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",$n]}],"line-clamp":[{"line-clamp":["none",BL,qG]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",w0,$n]}],"list-image":[{"list-image":["none",$n]}],"list-style-type":[{list:["none","disc","decimal",$n]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[t]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[t]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...V(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",w0,N_]}],"underline-offset":[{"underline-offset":["auto",w0,$n]}],"text-decoration-color":[{decoration:[t]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:M()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",$n]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",$n]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...I(),o$e]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",n$e]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},s$e]}],"bg-color":[{bg:[t]}],"gradient-from-pos":[{from:[p]}],"gradient-via-pos":[{via:[p]}],"gradient-to-pos":[{to:[p]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[...V(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:V()}],"border-color":[{border:[r]}],"border-color-x":[{"border-x":[r]}],"border-color-y":[{"border-y":[r]}],"border-color-s":[{"border-s":[r]}],"border-color-e":[{"border-e":[r]}],"border-color-t":[{"border-t":[r]}],"border-color-r":[{"border-r":[r]}],"border-color-b":[{"border-b":[r]}],"border-color-l":[{"border-l":[r]}],"divide-color":[{divide:[r]}],"outline-style":[{outline:["",...V()]}],"outline-offset":[{"outline-offset":[w0,$n]}],"outline-w":[{outline:[w0,N_]}],"outline-color":[{outline:[t]}],"ring-w":[{ring:D()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[t]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[w0,N_]}],"ring-offset-color":[{"ring-offset":[t]}],shadow:[{shadow:["","inner","none",F_,l$e]}],"shadow-color":[{shadow:[$2]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...z(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":z()}],filter:[{filter:["","none"]}],blur:[{blur:[i]}],brightness:[{brightness:[n]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",F_,$n]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[c]}],invert:[{invert:[d]}],saturate:[{saturate:[b]}],sepia:[{sepia:[_]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[i]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[c]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[b]}],"backdrop-sepia":[{"backdrop-sepia":[_]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",$n]}],duration:[{duration:k()}],ease:[{ease:["linear","in","out","in-out",$n]}],delay:[{delay:k()}],animate:[{animate:["none","spin","ping","pulse","bounce",$n]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[z2,$n]}],"translate-x":[{"translate-x":[x]}],"translate-y":[{"translate-y":[x]}],"skew-x":[{"skew-x":[C]}],"skew-y":[{"skew-y":[C]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",$n]}],accent:[{accent:["auto",t]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",$n]}],"caret-color":[{caret:[t]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":M()}],"scroll-mx":[{"scroll-mx":M()}],"scroll-my":[{"scroll-my":M()}],"scroll-ms":[{"scroll-ms":M()}],"scroll-me":[{"scroll-me":M()}],"scroll-mt":[{"scroll-mt":M()}],"scroll-mr":[{"scroll-mr":M()}],"scroll-mb":[{"scroll-mb":M()}],"scroll-ml":[{"scroll-ml":M()}],"scroll-p":[{"scroll-p":M()}],"scroll-px":[{"scroll-px":M()}],"scroll-py":[{"scroll-py":M()}],"scroll-ps":[{"scroll-ps":M()}],"scroll-pe":[{"scroll-pe":M()}],"scroll-pt":[{"scroll-pt":M()}],"scroll-pr":[{"scroll-pr":M()}],"scroll-pb":[{"scroll-pb":M()}],"scroll-pl":[{"scroll-pl":M()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",$n]}],fill:[{fill:[t,"none"]}],"stroke-w":[{stroke:[w0,N_,qG]}],stroke:[{stroke:[t,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},qJ=qze(f$e);function Hr(...t){return qJ(Rv(t))}const h$e={wide:"max-w-7xl",full:"max-w-full"};function MS(t){const e=qt.c(6),i=t.maxWidth??"wide",n=h$e[i];let r;e[0]!==t.className||e[1]!==n?(r=Hr("p-1 flex-1 min-h-0 w-full mx-auto animate-fade-in flex flex-col",n,t.className),e[0]=t.className,e[1]=n,e[2]=r):r=e[2];let o;return e[3]!==t.children||e[4]!==r?(o=L.jsx("div",{className:r,children:t.children}),e[3]=t.children,e[4]=r,e[5]=o):o=e[5],o}function LP(t){const e=qt.c(11);let i;e[0]!==t.className?(i=Hr("p-4",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;e[2]!==t.title?(n=t.title&&L.jsx("h1",{className:"text-xl font-bold text-foreground mb-1",children:t.title}),e[2]=t.title,e[3]=n):n=e[3];let r;e[4]!==t.description?(r=t.description&&L.jsx("p",{className:"text-muted-foreground text-md",children:t.description}),e[4]=t.description,e[5]=r):r=e[5];let o;return e[6]!==t.children||e[7]!==i||e[8]!==n||e[9]!==r?(o=L.jsxs("div",{className:i,children:[n,r,t.children]}),e[6]=t.children,e[7]=i,e[8]=n,e[9]=r,e[10]=o):o=e[10],o}function LS(t){const e=qt.c(5);let i;e[0]!==t.className?(i=Hr("p-5 flex-1 flex flex-col",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;return e[2]!==t.children||e[3]!==i?(n=L.jsx("div",{className:i,children:t.children}),e[2]=t.children,e[3]=i,e[4]=n):n=e[4],n}/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const p$e=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),g$e=t=>t.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,i,n)=>n?n.toUpperCase():i.toLowerCase()),_oe=t=>{const e=g$e(t);return e.charAt(0).toUpperCase()+e.slice(1)},kEe=(...t)=>t.filter((e,i,n)=>!!e&&e.trim()!==""&&n.indexOf(e)===i).join(" ").trim(),v$e=t=>{for(const e in t)if(e.startsWith("aria-")||e==="role"||e==="title")return!0};/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */var y$e={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const m$e=J.forwardRef(({color:t="currentColor",size:e=24,strokeWidth:i=2,absoluteStrokeWidth:n,className:r="",children:o,iconNode:a,...s},l)=>J.createElement("svg",{ref:l,...y$e,width:e,height:e,stroke:t,strokeWidth:n?Number(i)*24/Number(e):i,className:kEe("lucide",r),...!o&&!v$e(s)&&{"aria-hidden":"true"},...s},[...a.map(([u,c])=>J.createElement(u,c)),...Array.isArray(o)?o:[o]]));/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Er=(t,e)=>{const i=J.forwardRef(({className:n,...r},o)=>J.createElement(m$e,{ref:o,iconNode:e,className:kEe(`lucide-${p$e(_oe(t))}`,`lucide-${t}`,n),...r}));return i.displayName=_oe(t),i};/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const b$e=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],S$e=Er("activity",b$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _$e=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],P$e=Er("arrow-left",_$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const C$e=[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M16 12h2",key:"7q9ll5"}],["path",{d:"M16 8h2",key:"msurwy"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}],["path",{d:"M6 12h2",key:"32wvfc"}],["path",{d:"M6 8h2",key:"30oboj"}]],Poe=Er("book-open-text",C$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const T$e=[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]],x$e=Er("book-open",T$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const E$e=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],XG=Er("box",E$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const w$e=[["path",{d:"m16 22-1-4",key:"1ow2iv"}],["path",{d:"M19 14a1 1 0 0 0 1-1v-1a2 2 0 0 0-2-2h-3a1 1 0 0 1-1-1V4a2 2 0 0 0-4 0v5a1 1 0 0 1-1 1H6a2 2 0 0 0-2 2v1a1 1 0 0 0 1 1",key:"11gii7"}],["path",{d:"M19 14H5l-1.973 6.767A1 1 0 0 0 4 22h16a1 1 0 0 0 .973-1.233z",key:"bju7h4"}],["path",{d:"m8 22 1-4",key:"s3unb"}]],A$e=Er("brush-cleaning",w$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const O$e=[["path",{d:"M8 6v6",key:"18i7km"}],["path",{d:"M15 6v6",key:"1sg6z9"}],["path",{d:"M2 12h19.6",key:"de5uta"}],["path",{d:"M18 18h3s.5-1.7.8-2.8c.1-.4.2-.8.2-1.2 0-.4-.1-.8-.2-1.2l-1.4-5C20.1 6.8 19.1 6 18 6H4a2 2 0 0 0-2 2v10h3",key:"1wwztk"}],["circle",{cx:"7",cy:"18",r:"2",key:"19iecd"}],["path",{d:"M9 18h5",key:"lrx6i"}],["circle",{cx:"16",cy:"18",r:"2",key:"1v4tcr"}]],D$e=Er("bus",O$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const R$e=[["path",{d:"M19 17h2c.6 0 1-.4 1-1v-3c0-.9-.7-1.7-1.5-1.9C18.7 10.6 16 10 16 10s-1.3-1.4-2.2-2.3c-.5-.4-1.1-.7-1.8-.7H5c-.6 0-1.1.4-1.4.9l-1.4 2.9A3.7 3.7 0 0 0 2 12v4c0 .6.4 1 1 1h2",key:"5owen"}],["circle",{cx:"7",cy:"17",r:"2",key:"u2ysq9"}],["path",{d:"M9 17h6",key:"r8uit2"}],["circle",{cx:"17",cy:"17",r:"2",key:"axvx0g"}]],M$e=Er("car",R$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const L$e=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],Coe=Er("chart-column",L$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const k$e=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"m19 9-5 5-4-4-3 3",key:"2osh9i"}]],I$e=Er("chart-line",k$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const N$e=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],A$=Er("chevron-down",N$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const F$e=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],B$e=Er("chevron-left",F$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const j$e=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],V$e=Er("chevron-right",j$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const H$e=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],IEe=Er("chevron-up",H$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const U$e=[["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M16 12h.01",key:"1l6xoz"}],["path",{d:"m17 7 5 5-5 5",key:"1xlxn0"}],["path",{d:"m7 7-5 5 5 5",key:"19njba"}],["path",{d:"M8 12h.01",key:"czm47f"}]],z$e=Er("chevrons-left-right-ellipsis",U$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const $$e=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],W$e=Er("circle-alert",$$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const G$e=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]],Y$e=Er("circle-check-big",G$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const q$e=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M17 12h.01",key:"1m0b6t"}],["path",{d:"M12 12h.01",key:"1mp3jc"}],["path",{d:"M7 12h.01",key:"eqddd0"}]],X$e=Er("circle-ellipsis",q$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const K$e=[["path",{d:"M15.6 2.7a10 10 0 1 0 5.7 5.7",key:"1e0p6d"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"M13.4 10.6 19 5",key:"1kr7tw"}]],Z$e=Er("circle-gauge",K$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const J$e=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]],NEe=Er("circle-question-mark",J$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Q$e=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}],["path",{d:"M7 20.662V19a2 2 0 0 1 2-2h6a2 2 0 0 1 2 2v1.662",key:"154egf"}]],e6e=Er("circle-user",Q$e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const t6e=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],r6e=Er("circle-x",t6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const i6e=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],n6e=Er("clock",i6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const o6e=[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]],a6e=Er("code",o6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const s6e=[["path",{d:"M11 10.27 7 3.34",key:"16pf9h"}],["path",{d:"m11 13.73-4 6.93",key:"794ttg"}],["path",{d:"M12 22v-2",key:"1osdcq"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M14 12h8",key:"4f43i9"}],["path",{d:"m17 20.66-1-1.73",key:"eq3orb"}],["path",{d:"m17 3.34-1 1.73",key:"2wel8s"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"m20.66 17-1.73-1",key:"sg0v6f"}],["path",{d:"m20.66 7-1.73 1",key:"1ow05n"}],["path",{d:"m3.34 17 1.73-1",key:"nuk764"}],["path",{d:"m3.34 7 1.73 1",key:"1ulond"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}]],l6e=Er("cog",s6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const u6e=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],uX=Er("copy",u6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const c6e=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],d6e=Er("cpu",c6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const f6e=[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]],Toe=Er("database",f6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const h6e=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],p6e=Er("download",h6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const g6e=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"12",cy:"5",r:"1",key:"gxeob9"}],["circle",{cx:"12",cy:"19",r:"1",key:"lyex9k"}]],v6e=Er("ellipsis-vertical",g6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const y6e=[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"19",cy:"12",r:"1",key:"1wjl8i"}],["circle",{cx:"5",cy:"12",r:"1",key:"1pcz8c"}]],m6e=Er("ellipsis",y6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const b6e=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],S6e=Er("external-link",b6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _6e=[["path",{d:"M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49",key:"ct8e1f"}],["path",{d:"M14.084 14.158a3 3 0 0 1-4.242-4.242",key:"151rxh"}],["path",{d:"M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143",key:"13bj9a"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],P6e=Er("eye-off",_6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const C6e=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],T6e=Er("eye",C6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const x6e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1",key:"1oajmo"}],["path",{d:"M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1",key:"mpwhp6"}]],E6e=Er("file-braces",x6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const w6e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12.5 8 15l2 2.5",key:"1tg20x"}],["path",{d:"m14 12.5 2 2.5-2 2.5",key:"yinavb"}]],A6e=Er("file-code",w6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const O6e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M12 17h.01",key:"p32p05"}],["path",{d:"M9.1 9a3 3 0 0 1 5.82 1c0 2-3 3-3 3",key:"mhlwft"}]],D6e=Er("file-question-mark",O6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const R6e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],M6e=Er("file-text",R6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const L6e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}]],k6e=Er("file",L6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const I6e=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M7 3v18",key:"bbkbws"}],["path",{d:"M3 7.5h4",key:"zfgn84"}],["path",{d:"M3 12h18",key:"1i2n21"}],["path",{d:"M3 16.5h4",key:"1230mu"}],["path",{d:"M17 3v18",key:"in4fa5"}],["path",{d:"M17 7.5h4",key:"myr1c1"}],["path",{d:"M17 16.5h4",key:"go4c1d"}]],N6e=Er("film",I6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const F6e=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],B6e=Er("folder-open",F6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const j6e=[["path",{d:"M20 10a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1h-2.5a1 1 0 0 1-.8-.4l-.9-1.2A1 1 0 0 0 15 3h-2a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"hod4my"}],["path",{d:"M20 21a1 1 0 0 0 1-1v-3a1 1 0 0 0-1-1h-2.9a1 1 0 0 1-.88-.55l-.42-.85a1 1 0 0 0-.92-.6H13a1 1 0 0 0-1 1v5a1 1 0 0 0 1 1Z",key:"w4yl2u"}],["path",{d:"M3 5a2 2 0 0 0 2 2h3",key:"f2jnh7"}],["path",{d:"M3 3v13a2 2 0 0 0 2 2h3",key:"k8epm1"}]],V6e=Er("folder-tree",j6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const H6e=[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]],U6e=Er("folder",H6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const z6e=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],$6e=Er("funnel",z6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const W6e=[["path",{d:"M15 22v-4a4.8 4.8 0 0 0-1-3.5c3 0 6-2 6-5.5.08-1.25-.27-2.48-1-3.5.28-1.15.28-2.35 0-3.5 0 0-1 0-3 1.5-2.64-.5-5.36-.5-8 0C6 2 5 2 5 2c-.3 1.15-.3 2.35 0 3.5A5.403 5.403 0 0 0 4 9c0 3.5 3 5.5 6 5.5-.39.49-.68 1.05-.85 1.65-.17.6-.22 1.23-.15 1.85v4",key:"tonef"}],["path",{d:"M9 18c-4.51 2-5-2-7-2",key:"9comsn"}]],G6e=Er("github",W6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const Y6e=[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]],xoe=Er("hard-drive",Y6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const q6e=[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]],X6e=Er("heart",q6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const K6e=[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-6a2 2 0 0 1 2.582 0l7 6A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"r6nss1"}]],Z6e=Er("house",K6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const J6e=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]],Q6e=Er("image",J6e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const eWe=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],cX=Er("info",eWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const tWe=[["path",{d:"m15.5 7.5 2.3 2.3a1 1 0 0 0 1.4 0l2.1-2.1a1 1 0 0 0 0-1.4L19 4",key:"g0fldk"}],["path",{d:"m21 2-9.6 9.6",key:"1j0ho8"}],["circle",{cx:"7.5",cy:"15.5",r:"5.5",key:"yqb3hr"}]],rWe=Er("key",tWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const iWe=[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]],Eoe=Er("layout-dashboard",iWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const nWe=[["path",{d:"m16 6 4 14",key:"ji33uf"}],["path",{d:"M12 6v14",key:"1n7gus"}],["path",{d:"M8 8v12",key:"1gg7y9"}],["path",{d:"M4 4v16",key:"6qkkli"}]],oWe=Er("library",nWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const aWe=[["path",{d:"M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71",key:"1cjeqo"}],["path",{d:"M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71",key:"19qd67"}]],sWe=Er("link",aWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const lWe=[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"c2jq9f"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"mk3on5"}],["circle",{cx:"4",cy:"4",r:"2",key:"bt5ra8"}]],uWe=Er("linkedin",lWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const cWe=[["path",{d:"M8 5h13",key:"1pao27"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"M3 10a2 2 0 0 0 2 2h3",key:"1npucw"}],["path",{d:"M3 5v12a2 2 0 0 0 2 2h3",key:"x1gjn2"}]],dWe=Er("list-tree",cWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const fWe=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],FEe=Er("loader-circle",fWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const hWe=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 9.9-1",key:"1mm8w8"}]],pWe=Er("lock-open",hWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const gWe=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],vWe=Er("lock",gWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const yWe=[["path",{d:"m10 17 5-5-5-5",key:"1bsop3"}],["path",{d:"M15 12H3",key:"6jk70r"}],["path",{d:"M15 3h4a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2h-4",key:"u53s6r"}]],mWe=Er("log-in",yWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const bWe=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],SWe=Er("log-out",bWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const _We=[["path",{d:"M3 5h1",key:"1mv5vm"}],["path",{d:"M3 12h1",key:"lp3yf2"}],["path",{d:"M3 19h1",key:"w6f3n9"}],["path",{d:"M8 5h1",key:"1nxr5w"}],["path",{d:"M8 12h1",key:"1con00"}],["path",{d:"M8 19h1",key:"k7p10e"}],["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}]],PWe=Er("logs",_We);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const CWe=[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]],TWe=Er("map-pin",CWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const xWe=[["path",{d:"M8 3H5a2 2 0 0 0-2 2v3",key:"1dcmit"}],["path",{d:"M21 8V5a2 2 0 0 0-2-2h-3",key:"1e4gt3"}],["path",{d:"M3 16v3a2 2 0 0 0 2 2h3",key:"wsl5sc"}],["path",{d:"M16 21h3a2 2 0 0 0 2-2v-3",key:"18trek"}]],EWe=Er("maximize",xWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const wWe=[["path",{d:"M4 5h16",key:"1tepv9"}],["path",{d:"M4 12h16",key:"1lakjw"}],["path",{d:"M4 19h16",key:"1djgab"}]],AWe=Er("menu",wWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const OWe=[["path",{d:"M8 3v3a2 2 0 0 1-2 2H3",key:"hohbtr"}],["path",{d:"M21 8h-3a2 2 0 0 1-2-2V3",key:"5jw1f3"}],["path",{d:"M3 16h3a2 2 0 0 1 2 2v3",key:"198tvr"}],["path",{d:"M16 21v-3a2 2 0 0 1 2-2h3",key:"ph8mxp"}]],DWe=Er("minimize",OWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const RWe=[["path",{d:"M5 12h14",key:"1ays0h"}]],MWe=Er("minus",RWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const LWe=[["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],kWe=Er("moon",LWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const IWe=[["path",{d:"M9 18V5l12-2v13",key:"1jmyc2"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["circle",{cx:"18",cy:"16",r:"3",key:"1hluhg"}]],NWe=Er("music",IWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const FWe=[["rect",{x:"16",y:"16",width:"6",height:"6",rx:"1",key:"4q2zg0"}],["rect",{x:"2",y:"16",width:"6",height:"6",rx:"1",key:"8cvhb9"}],["rect",{x:"9",y:"2",width:"6",height:"6",rx:"1",key:"1egb70"}],["path",{d:"M5 16v-3a1 1 0 0 1 1-1h12a1 1 0 0 1 1 1v3",key:"1jsf9p"}],["path",{d:"M12 12V8",key:"2874zd"}]],woe=Er("network",FWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const BWe=[["path",{d:"M15 18h-5",key:"95g1m2"}],["path",{d:"M18 14h-8",key:"sponae"}],["path",{d:"M4 22h16a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v16a2 2 0 0 1-4 0v-9a2 2 0 0 1 2-2h2",key:"39pd36"}],["rect",{width:"8",height:"4",x:"10",y:"6",rx:"1",key:"aywv1n"}]],jWe=Er("newspaper",BWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const VWe=[["path",{d:"M2 6h4",key:"aawbzj"}],["path",{d:"M2 10h4",key:"l0bgd4"}],["path",{d:"M2 14h4",key:"1gsvsf"}],["path",{d:"M2 18h4",key:"1bu2t1"}],["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",key:"1nb95v"}],["path",{d:"M16 2v20",key:"rotuqe"}]],HWe=Er("notebook",VWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const UWe=[["path",{d:"M12 22a1 1 0 0 1 0-20 10 9 0 0 1 10 9 5 5 0 0 1-5 5h-2.25a1.75 1.75 0 0 0-1.4 2.8l.3.4a1.75 1.75 0 0 1-1.4 2.8z",key:"e79jfc"}],["circle",{cx:"13.5",cy:"6.5",r:".5",fill:"currentColor",key:"1okk4w"}],["circle",{cx:"17.5",cy:"10.5",r:".5",fill:"currentColor",key:"f64h9f"}],["circle",{cx:"6.5",cy:"12.5",r:".5",fill:"currentColor",key:"qy21gx"}],["circle",{cx:"8.5",cy:"7.5",r:".5",fill:"currentColor",key:"fotxhn"}]],zWe=Er("palette",UWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const $We=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"m16 15-3-3 3-3",key:"14y99z"}]],WWe=Er("panel-left-close",$We);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const GWe=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],YWe=Er("panel-left",GWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const qWe=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M15 3v18",key:"14nvp0"}]],XWe=Er("panel-right",qWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const KWe=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M3 9h18",key:"1pudct"}]],ZWe=Er("panel-top",KWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const JWe=[["rect",{x:"14",y:"3",width:"5",height:"18",rx:"1",key:"kaeet6"}],["rect",{x:"5",y:"3",width:"5",height:"18",rx:"1",key:"1wsw3u"}]],QWe=Er("pause",JWe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const eGe=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],tGe=Er("play",eGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const rGe=[["path",{d:"M12 22v-5",key:"1ega77"}],["path",{d:"M15 8V2",key:"18g5xt"}],["path",{d:"M17 8a1 1 0 0 1 1 1v4a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V9a1 1 0 0 1 1-1z",key:"1xoxul"}],["path",{d:"M9 8V2",key:"14iosj"}]],iGe=Er("plug",rGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const nGe=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],oGe=Er("plus",nGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const aGe=[["path",{d:"M18.36 6.64A9 9 0 0 1 20.77 15",key:"dxknvb"}],["path",{d:"M6.16 6.16a9 9 0 1 0 12.68 12.68",key:"1x7qb5"}],["path",{d:"M12 2v4",key:"3427ic"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],sGe=Er("power-off",aGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const lGe=[["path",{d:"M12 2v10",key:"mnfbl"}],["path",{d:"M18.4 6.6a9 9 0 1 1-12.77.04",key:"obofu9"}]],uGe=Er("power",lGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const cGe=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],dGe=Er("refresh-cw",cGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const fGe=[["path",{d:"M15.2 3a2 2 0 0 1 1.4.6l3.8 3.8a2 2 0 0 1 .6 1.4V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2z",key:"1c8476"}],["path",{d:"M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7",key:"1ydtos"}],["path",{d:"M7 3v4a1 1 0 0 0 1 1h7",key:"t51u73"}]],hGe=Er("save",fGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const pGe=[["path",{d:"m13.5 8.5-5 5",key:"1cs55j"}],["path",{d:"m8.5 8.5 5 5",key:"a8mexj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]],gGe=Er("search-x",pGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const vGe=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],BEe=Er("search",vGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const yGe=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],mGe=Er("server",yGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const bGe=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],KG=Er("settings",bGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const SGe=[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]],_Ge=Er("share-2",SGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const PGe=[["path",{d:"M12 2v13",key:"1km8f5"}],["path",{d:"m16 6-4-4-4 4",key:"13yo43"}],["path",{d:"M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8",key:"1b2hhj"}]],CGe=Er("share",PGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const TGe=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]],xGe=Er("shield",TGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const EGe=[["path",{d:"m15 15 6 6m-6-6v4.8m0-4.8h4.8",key:"17vawe"}],["path",{d:"M9 19.8V15m0 0H4.2M9 15l-6 6",key:"chjx8e"}],["path",{d:"M15 4.2V9m0 0h4.8M15 9l6-6",key:"lav6yq"}],["path",{d:"M9 4.2V9m0 0H4.2M9 9 3 3",key:"1pxi2q"}]],wGe=Er("shrink",EGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const AGe=[["path",{d:"M2 20h.01",key:"4haj6o"}],["path",{d:"M7 20v-4",key:"j294jx"}],["path",{d:"M12 20v-8",key:"i3yub9"}],["path",{d:"M17 20V8",key:"1tkaf5"}],["path",{d:"M22 4v16",key:"sih9yq"}]],OGe=Er("signal",AGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const DGe=[["path",{d:"M17.971 4.285A2 2 0 0 1 21 6v12a2 2 0 0 1-3.029 1.715l-9.997-5.998a2 2 0 0 1-.003-3.432z",key:"15892j"}],["path",{d:"M3 20V4",key:"1ptbpl"}]],RGe=Er("skip-back",DGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const MGe=[["path",{d:"M21 4v16",key:"7j8fe9"}],["path",{d:"M6.029 4.285A2 2 0 0 0 3 6v12a2 2 0 0 0 3.029 1.715l9.997-5.998a2 2 0 0 0 .003-3.432z",key:"zs4d6"}]],LGe=Er("skip-forward",MGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const kGe=[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]],IGe=Er("square-pen",kGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const NGe=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]],FGe=Er("square",NGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const BGe=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],jGe=Er("star",BGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const VGe=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],HGe=Er("sun",VGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const UGe=[["path",{d:"M15 3v18",key:"14nvp0"}],["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M21 9H3",key:"1338ky"}],["path",{d:"M21 15H3",key:"9uk58r"}]],zGe=Er("table-properties",UGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const $Ge=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],WGe=Er("terminal",$Ge);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const GGe=[["path",{d:"M15 5h6",key:"1pr8yx"}],["path",{d:"M15 12h6",key:"upa0zy"}],["path",{d:"M3 19h18",key:"awlh7x"}],["path",{d:"m3 12 3.553-7.724a.5.5 0 0 1 .894 0L11 12",key:"6lvno8"}],["path",{d:"M3.92 10h6.16",key:"1tl8ex"}]],YGe=Er("text-initial",GGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const qGe=[["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],XGe=Er("trash",qGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const KGe=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],jEe=Er("triangle-alert",KGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const ZGe=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],JGe=Er("upload",ZGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const QGe=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["line",{x1:"19",x2:"19",y1:"8",y2:"14",key:"1bvyxn"}],["line",{x1:"22",x2:"16",y1:"11",y2:"11",key:"1shjgl"}]],e8e=Er("user-plus",QGe);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const t8e=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],r8e=Er("user",t8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const i8e=[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["path",{d:"M16 3.128a4 4 0 0 1 0 7.744",key:"16gr8j"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}]],n8e=Er("users",i8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const o8e=[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["path",{d:"M16 9a5 5 0 0 1 0 6",key:"1q6k2b"}],["path",{d:"M19.364 18.364a9 9 0 0 0 0-12.728",key:"ijwkga"}]],a8e=Er("volume-2",o8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const s8e=[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["line",{x1:"22",x2:"16",y1:"9",y2:"15",key:"1ewh16"}],["line",{x1:"16",x2:"22",y1:"9",y2:"15",key:"5ykzw1"}]],l8e=Er("volume-x",s8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const u8e=[["path",{d:"M2 6c.6.5 1.2 1 2.5 1C7 7 7 5 9.5 5c2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1",key:"knzxuh"}],["path",{d:"M2 12c.6.5 1.2 1 2.5 1 2.5 0 2.5-2 5-2 2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1",key:"2jd2cc"}],["path",{d:"M2 18c.6.5 1.2 1 2.5 1 2.5 0 2.5-2 5-2 2.6 0 2.4 2 5 2 2.5 0 2.5-2 5-2 1.3 0 1.9.5 2.5 1",key:"rd2r6e"}]],c8e=Er("waves",u8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const d8e=[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}],["path",{d:"M5 12.859a10 10 0 0 1 5.17-2.69",key:"1dl1wf"}],["path",{d:"M19 12.859a10 10 0 0 0-2.007-1.523",key:"4k23kn"}],["path",{d:"M2 8.82a15 15 0 0 1 4.177-2.643",key:"1grhjp"}],["path",{d:"M22 8.82a15 15 0 0 0-11.288-3.764",key:"z3jwby"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],f8e=Er("wifi-off",d8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const h8e=[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]],p8e=Er("wifi",h8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const g8e=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],zj=Er("x",g8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const v8e=[["path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17",key:"1q2vi4"}],["path",{d:"m10 15 5-3-5-3z",key:"1jp15x"}]],y8e=Er("youtube",v8e);/**
 * @license lucide-react v0.562.0 - ISC
 *
 * This source code is licensed under the ISC license.
 * See the LICENSE file in the root directory of this source tree.
 */const m8e=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],b8e=Er("zap",m8e),dr={CONTEXT_OVERVIEW:Eoe,CONTEXT_FILES:V6e,CONTEXT_DASHBOARD:Coe,CONTEXT_TOPOLOGY:woe,CONTEXT_SETTINGS:KG,CONTEXT_ABOUT:cX,CONTEXT_HOME:Z6e,FILE_GENERIC:k6e,FILE_CODE:A6e,FILE_JSON:E6e,FILE_TEXT:M6e,FILE_IMAGE:Q6e,FILE_VIDEO:N6e,FILE_AUDIO:NWe,FILE_DATABASE:Toe,FILE_RECORDING:xoe,FILE_PLATFORM:KG,FILE_INSTANCE:XG,FILE_DASHBOARD:Eoe,FILE_UNKNOWN:D6e,FOLDER_CLOSED:U6e,FOLDER_OPEN:B6e,NAV_BACK:P$e,NAV_CHEVRON_RIGHT:V$e,NAV_CHEVRON_DOWN:A$,NAV_CHEVRON_UP:IEe,NAV_CHEVRON_LEFT:B$e,NAV_MENU:AWe,NAV_MORE_HORIZONTAL:m6e,NAV_MORE_VERTICAL:v6e,PANEL_LEFT:YWe,PANEL_LEFT_CLOSE:WWe,PANEL_RIGHT:XWe,PANEL_TOP:ZWe,PANEL_MAXIMIZE:EWe,PANEL_MINIMIZE:DWe,PANEL_SHRINK:wGe,ACTION_CLOSE:zj,ACTION_SEARCH:BEe,ACTION_FILTER:$6e,ACTION_ADD:oGe,ACTION_REMOVE:MWe,ACTION_EDIT:IGe,ACTION_DELETE:XGe,ACTION_CLEAR:A$e,ACTION_COPY:uX,ACTION_DOWNLOAD:p6e,ACTION_UPLOAD:JGe,ACTION_SHARE:CGe,ACTION_REFRESH:dGe,ACTION_SAVE:hGe,ACTION_SETTINGS:KG,ACTION_EXTERNAL_LINK:S6e,ACTION_LINK:sWe,STATUS_INFO:cX,STATUS_WARNING:jEe,STATUS_ERROR:W$e,STATUS_SUCCESS:Y$e,STATUS_FAILED:r6e,STATUS_LOADING:FEe,STATUS_CLOCK:n6e,STATUS_HELP:NEe,USER_PROFILE:r8e,USER_PROFILE_CIRCLE:e6e,USER_GROUP:n8e,USER_ADD:e8e,USER_LOGOUT:SWe,USER_LOGIN:mWe,THEME_LIGHT:HGe,THEME_DARK:kWe,THEME_PALETTE:zWe,VISIBILITY_SHOW:T6e,VISIBILITY_HIDE:P6e,BRAND_GITHUB:G6e,BRAND_YOUTUBE:y8e,BRAND_LINKEDIN:uWe,CONTENT_NEWS:jWe,CONTENT_BOOK:x$e,CONTENT_BOOK_TEXT:Poe,CONTENT_NOTEBOOK:HWe,CONTENT_CODE:a6e,CONTENT_TERMINAL:WGe,MEDIA_PLAY:tGe,MEDIA_PAUSE:QWe,MEDIA_STOP:FGe,MEDIA_SKIP_FORWARD:LGe,MEDIA_SKIP_BACK:RGe,MEDIA_VOLUME:a8e,MEDIA_MUTE:l8e,SYSTEM_POWER:uGe,SYSTEM_POWER_OFF:sGe,SYSTEM_NETWORK:woe,SYSTEM_SERVER:mGe,SYSTEM_WIFI:p8e,SYSTEM_WIFI_OFF:f8e,SYSTEM_SIGNAL:OGe,SYSTEM_SEARCH_X:gGe,SYSTEM_ACTIVITY:S$e,SYSTEM_ZAP:b8e,DATA_BAR_CHART:Coe,DATA_TIMESERIES:I$e,DATA_TRACE:PWe,DATA_DATABASE:Toe,DATA_HARD_DRIVE:xoe,DATA_TABLE:zGe,DATA_CIRCLE_GAUGE:Z$e,TOPOLOGY_SERVICE:oWe,TOPOLOGY_INSTANCE:Poe,TOPOLOGY_SOCKET:iGe,TOPOLOGY_ENDPOINT:TWe,TOPOLOGY_ECU:d6e,TOPOLOGY_CHANNEL:z$e,TOPOLOGY_CONTAINER:XG,TOPOLOGY_BEHAVIORAL_MODEL:l6e,OBJECT_CAR:M$e,OBJECT_WAVES:c8e,OBJECT_BUS:D$e,OBJECT_BOX:XG,OBJECT_HEART:X6e,OBJECT_STAR:jGe,SECURITY_SHIELD:xGe,SECURITY_KEY:rWe,SECURITY_LOCK:vWe,SECURITY_UNLOCK:pWe,VIEW_TREE:dWe,VIEW_GRAPH:_Ge,VIEW_TEXT:YGe,VIEW_MORE:X$e},Xi=Object.fromEntries(Object.keys(dr).map(t=>[t,t]));function dV(t){return dr[t]}function Wr(t){const e=qt.c(12);let i,n,r,o;e[0]!==t?({type:i,size:n,style:r,...o}=t,e[0]=t,e[1]=i,e[2]=n,e[3]=r,e[4]=o):(i=e[1],n=e[2],r=e[3],o=e[4]);let a;e[5]!==n||e[6]!==r?(a=n?{width:n,height:n,...r}:r,e[5]=n,e[6]=r,e[7]=a):a=e[7];let s;return e[8]!==i||e[9]!==o||e[10]!==a?(s=L.jsx(i,{...o,style:a}),e[8]=i,e[9]=o,e[10]=a,e[11]=s):s=e[11],s}var fn=(t=>(t.PRIMARY="primary",t.PRIMARY_OUTLINE="primary_outline",t.SECONDARY="secondary",t.SUCCESS="success",t.SUCCESS_OUTLINE="success_outline",t.DESTRUCTIVE="destructive",t.DESTRUCTIVE_OUTLINE="destructive_outline",t.NO_BACKGROUND="no_background",t.NEUTRAL="neutral",t.PANEL_BUTTON="panel_button",t.PANEL_BUTTON_ACTIVE="panel_button_active",t))(fn||{}),_a=(t=>(t.XS="xs",t.SM="sm",t.MD="md",t.LG="lg",t))(_a||{});const XJ="inline-flex items-center justify-center font-medium transition-colors duration-200 focus:outline-none focus-visible:ring-2 focus-visible:ring-offset-2",VEe={[_a.XS]:"gap-1 px-2 py-0.5 text-xs rounded-md",[_a.SM]:"gap-1 px-3 py-1 text-xs rounded-md",[_a.MD]:"gap-2 px-5 py-2 text-sm rounded-full",[_a.LG]:"gap-2 px-6 py-3 text-base rounded-full"},Aoe="bg-slate-300/60 text-foreground hover:bg-slate-300 dark:bg-slate-700 dark:hover:bg-slate-600 focus-visible:ring-border disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",KJ={[fn.PRIMARY]:"bg-[var(--btn-primary-bg)] text-[var(--btn-primary-text)] hover:bg-[var(--btn-primary-hover-bg)] focus-visible:ring-[var(--btn-primary-bg)] disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",[fn.PRIMARY_OUTLINE]:"bg-transparent border-2 border-[var(--btn-primary-bg)] text-[var(--btn-primary-bg)] hover:bg-[var(--btn-primary-bg)] hover:text-[var(--btn-primary-text)] focus-visible:ring-[var(--btn-primary-bg)]",[fn.SECONDARY]:"bg-slate-50 dark:bg-slate-800/90 border border-[var(--btn-primary-bg)] text-[var(--btn-primary-bg)] dark:text-white hover:bg-[var(--btn-primary-bg)] hover:text-[var(--btn-primary-text)] dark:hover:text-gray-400 hover:border-transparent focus-visible:ring-[var(--btn-primary-bg)] disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",[fn.SUCCESS]:"bg-[var(--btn-success-bg)] text-[var(--btn-success-text)] hover:bg-[var(--btn-success-hover-bg)] focus-visible:ring-[var(--btn-success-bg)] disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",[fn.SUCCESS_OUTLINE]:"bg-transparent border-2 border-[var(--btn-success-bg)] text-[var(--btn-success-bg)] hover:bg-[var(--btn-success-bg)] hover:text-[var(--btn-success-text)] focus-visible:ring-[var(--btn-success-bg)]",[fn.DESTRUCTIVE]:"bg-[var(--btn-destructive-bg)] text-[var(--btn-destructive-text)] hover:bg-[var(--btn-destructive-hover-bg)] focus-visible:ring-[var(--btn-destructive-bg)] disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",[fn.DESTRUCTIVE_OUTLINE]:"bg-transparent border-2 border-[var(--btn-destructive-bg)] text-[var(--btn-destructive-bg)] hover:bg-[var(--btn-destructive-bg)] hover:text-[var(--btn-destructive-text)] focus-visible:ring-[var(--btn-destructive-bg)]",[fn.NO_BACKGROUND]:"bg-transparent text-foreground hover:text-muted-foreground focus-visible:ring-transparent disabled:cursor-not-allowed disabled:opacity-50",[fn.NEUTRAL]:"bg-muted text-foreground hover:bg-gray-200 dark:bg-blue-400/30 dark:hover:bg-blue-400/20 focus-visible:ring-border disabled:bg-[var(--btn-disabled-bg)] disabled:text-[var(--btn-disabled-text)] disabled:cursor-not-allowed disabled:opacity-50",[fn.PANEL_BUTTON]:Aoe,[fn.PANEL_BUTTON_ACTIVE]:Hr(Aoe,"bg-green-600/20 text-green-600 hover:bg-green-600/30 dark:bg-green-600/20 dark:text-green-400 dark:hover:bg-green-600/30")},Za=J.forwardRef(function(e,i){const n=qt.c(18),{icon:r,label:o,title:a,trailing:s,type:l,size:u,onClick:c,disabled:d,isLoading:f,className:h}=e,p=u===void 0?_a.MD:u,g=p===_a.XS||p===_a.SM?12:p===_a.LG?20:16,v=d??f,y=VEe[p],m=KJ[l],b=l===fn.NO_BACKGROUND&&"px-0 py-0";let S;n[0]!==h||n[1]!==y||n[2]!==m||n[3]!==b?(S=Hr(XJ,y,m,b,h),n[0]=h,n[1]=y,n[2]=m,n[3]=b,n[4]=S):S=n[4];let _;n[5]!==r||n[6]!==g||n[7]!==f||n[8]!==o||n[9]!==s?(_=f?L.jsx(Wr,{type:dr.STATUS_LOADING,size:g,className:"animate-spin"}):L.jsxs(L.Fragment,{children:[r&&L.jsx(Wr,{type:r,size:g}),o,s]}),n[5]=r,n[6]=g,n[7]=f,n[8]=o,n[9]=s,n[10]=_):_=n[10];let C;return n[11]!==c||n[12]!==i||n[13]!==v||n[14]!==S||n[15]!==_||n[16]!==a?(C=L.jsx("button",{ref:i,title:a,onClick:c,disabled:v,className:S,children:_}),n[11]=c,n[12]=i,n[13]=v,n[14]=S,n[15]=_,n[16]=a,n[17]=C):C=n[17],C});function tn(t,e,{checkForDefaultPrevented:i=!0}={}){return function(r){if(t==null||t(r),i===!1||!r.defaultPrevented)return e==null?void 0:e(r)}}function Ooe(t,e){if(typeof t=="function")return t(e);t!=null&&(t.current=e)}function O$(...t){return e=>{let i=!1;const n=t.map(r=>{const o=Ooe(r,e);return!i&&typeof o=="function"&&(i=!0),o});if(i)return()=>{for(let r=0;r<n.length;r++){const o=n[r];typeof o=="function"?o():Ooe(t[r],null)}}}}function Bl(...t){return J.useCallback(O$(...t),t)}function S8e(t,e){const i=J.createContext(e),n=o=>{const{children:a,...s}=o,l=J.useMemo(()=>s,Object.values(s));return L.jsx(i.Provider,{value:l,children:a})};n.displayName=t+"Provider";function r(o){const a=J.useContext(i);if(a)return a;if(e!==void 0)return e;throw new Error(`\`${o}\` must be used within \`${t}\``)}return[n,r]}function kS(t,e=[]){let i=[];function n(o,a){const s=J.createContext(a),l=i.length;i=[...i,a];const u=d=>{var y;const{scope:f,children:h,...p}=d,g=((y=f==null?void 0:f[t])==null?void 0:y[l])||s,v=J.useMemo(()=>p,Object.values(p));return L.jsx(g.Provider,{value:v,children:h})};u.displayName=o+"Provider";function c(d,f){var g;const h=((g=f==null?void 0:f[t])==null?void 0:g[l])||s,p=J.useContext(h);if(p)return p;if(a!==void 0)return a;throw new Error(`\`${d}\` must be used within \`${o}\``)}return[u,c]}const r=()=>{const o=i.map(a=>J.createContext(a));return function(s){const l=(s==null?void 0:s[t])||o;return J.useMemo(()=>({[`__scope${t}`]:{...s,[t]:l}}),[s,l])}};return r.scopeName=t,[n,_8e(r,...e)]}function _8e(...t){const e=t[0];if(t.length===1)return e;const i=()=>{const n=t.map(r=>({useScope:r(),scopeName:r.scopeName}));return function(o){const a=n.reduce((s,{useScope:l,scopeName:u})=>{const d=l(o)[`__scope${u}`];return{...s,...d}},{});return J.useMemo(()=>({[`__scope${e.scopeName}`]:a}),[a])}};return i.scopeName=e.scopeName,i}function yk(t){const e=P8e(t),i=J.forwardRef((n,r)=>{const{children:o,...a}=n,s=J.Children.toArray(o),l=s.find(T8e);if(l){const u=l.props.children,c=s.map(d=>d===l?J.Children.count(u)>1?J.Children.only(null):J.isValidElement(u)?u.props.children:null:d);return L.jsx(e,{...a,ref:r,children:J.isValidElement(u)?J.cloneElement(u,void 0,c):null})}return L.jsx(e,{...a,ref:r,children:o})});return i.displayName=`${t}.Slot`,i}function P8e(t){const e=J.forwardRef((i,n)=>{const{children:r,...o}=i;if(J.isValidElement(r)){const a=E8e(r),s=x8e(o,r.props);return r.type!==J.Fragment&&(s.ref=n?O$(n,a):a),J.cloneElement(r,s)}return J.Children.count(r)>1?J.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var HEe=Symbol("radix.slottable");function C8e(t){const e=({children:i})=>L.jsx(L.Fragment,{children:i});return e.displayName=`${t}.Slottable`,e.__radixId=HEe,e}function T8e(t){return J.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===HEe}function x8e(t,e){const i={...e};for(const n in e){const r=t[n],o=e[n];/^on[A-Z]/.test(n)?r&&o?i[n]=(...s)=>{const l=o(...s);return r(...s),l}:r&&(i[n]=r):n==="style"?i[n]={...r,...o}:n==="className"&&(i[n]=[r,o].filter(Boolean).join(" "))}return{...t,...i}}function E8e(t){var n,r;let e=(n=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:n.get,i=e&&"isReactWarning"in e&&e.isReactWarning;return i?t.ref:(e=(r=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:r.get,i=e&&"isReactWarning"in e&&e.isReactWarning,i?t.props.ref:t.props.ref||t.ref)}var w8e=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],es=w8e.reduce((t,e)=>{const i=yk(`Primitive.${e}`),n=J.forwardRef((r,o)=>{const{asChild:a,...s}=r,l=a?i:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),L.jsx(l,{...s,ref:o})});return n.displayName=`Primitive.${e}`,{...t,[e]:n}},{});function UEe(t,e){t&&zf.flushSync(()=>t.dispatchEvent(e))}function um(t){const e=J.useRef(t);return J.useEffect(()=>{e.current=t}),J.useMemo(()=>(...i)=>{var n;return(n=e.current)==null?void 0:n.call(e,...i)},[])}function A8e(t,e=globalThis==null?void 0:globalThis.document){const i=um(t);J.useEffect(()=>{const n=r=>{r.key==="Escape"&&i(r)};return e.addEventListener("keydown",n,{capture:!0}),()=>e.removeEventListener("keydown",n,{capture:!0})},[i,e])}var O8e="DismissableLayer",dX="dismissableLayer.update",D8e="dismissableLayer.pointerDownOutside",R8e="dismissableLayer.focusOutside",Doe,zEe=J.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),fV=J.forwardRef((t,e)=>{const{disableOutsidePointerEvents:i=!1,onEscapeKeyDown:n,onPointerDownOutside:r,onFocusOutside:o,onInteractOutside:a,onDismiss:s,...l}=t,u=J.useContext(zEe),[c,d]=J.useState(null),f=(c==null?void 0:c.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=J.useState({}),p=Bl(e,P=>d(P)),g=Array.from(u.layers),[v]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),y=g.indexOf(v),m=c?g.indexOf(c):-1,b=u.layersWithOutsidePointerEventsDisabled.size>0,S=m>=y,_=k8e(P=>{const x=P.target,E=[...u.branches].some(A=>A.contains(x));!S||E||(r==null||r(P),a==null||a(P),P.defaultPrevented||s==null||s())},f),C=I8e(P=>{const x=P.target;[...u.branches].some(A=>A.contains(x))||(o==null||o(P),a==null||a(P),P.defaultPrevented||s==null||s())},f);return A8e(P=>{m===u.layers.size-1&&(n==null||n(P),!P.defaultPrevented&&s&&(P.preventDefault(),s()))},f),J.useEffect(()=>{if(c)return i&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(Doe=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(c)),u.layers.add(c),Roe(),()=>{i&&u.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=Doe)}},[c,f,i,u]),J.useEffect(()=>()=>{c&&(u.layers.delete(c),u.layersWithOutsidePointerEventsDisabled.delete(c),Roe())},[c,u]),J.useEffect(()=>{const P=()=>h({});return document.addEventListener(dX,P),()=>document.removeEventListener(dX,P)},[]),L.jsx(es.div,{...l,ref:p,style:{pointerEvents:b?S?"auto":"none":void 0,...t.style},onFocusCapture:tn(t.onFocusCapture,C.onFocusCapture),onBlurCapture:tn(t.onBlurCapture,C.onBlurCapture),onPointerDownCapture:tn(t.onPointerDownCapture,_.onPointerDownCapture)})});fV.displayName=O8e;var M8e="DismissableLayerBranch",L8e=J.forwardRef((t,e)=>{const i=J.useContext(zEe),n=J.useRef(null),r=Bl(e,n);return J.useEffect(()=>{const o=n.current;if(o)return i.branches.add(o),()=>{i.branches.delete(o)}},[i.branches]),L.jsx(es.div,{...t,ref:r})});L8e.displayName=M8e;function k8e(t,e=globalThis==null?void 0:globalThis.document){const i=um(t),n=J.useRef(!1),r=J.useRef(()=>{});return J.useEffect(()=>{const o=s=>{if(s.target&&!n.current){let l=function(){$Ee(D8e,i,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(e.removeEventListener("click",r.current),r.current=l,e.addEventListener("click",r.current,{once:!0})):l()}else e.removeEventListener("click",r.current);n.current=!1},a=window.setTimeout(()=>{e.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(a),e.removeEventListener("pointerdown",o),e.removeEventListener("click",r.current)}},[e,i]),{onPointerDownCapture:()=>n.current=!0}}function I8e(t,e=globalThis==null?void 0:globalThis.document){const i=um(t),n=J.useRef(!1);return J.useEffect(()=>{const r=o=>{o.target&&!n.current&&$Ee(R8e,i,{originalEvent:o},{discrete:!1})};return e.addEventListener("focusin",r),()=>e.removeEventListener("focusin",r)},[e,i]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function Roe(){const t=new CustomEvent(dX);document.dispatchEvent(t)}function $Ee(t,e,i,{discrete:n}){const r=i.originalEvent.target,o=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:i});e&&r.addEventListener(t,e,{once:!0}),n?UEe(r,o):r.dispatchEvent(o)}var bS=globalThis!=null&&globalThis.document?J.useLayoutEffect:()=>{},N8e=s5[" useId ".trim().toString()]||(()=>{}),F8e=0;function Mv(t){const[e,i]=J.useState(N8e());return bS(()=>{i(n=>n??String(F8e++))},[t]),e?`radix-${e}`:""}const B8e=["top","right","bottom","left"],bP=Math.min,_p=Math.max,y5=Math.round,yH=Math.floor,rm=t=>({x:t,y:t}),j8e={left:"right",right:"left",bottom:"top",top:"bottom"},V8e={start:"end",end:"start"};function fX(t,e,i){return _p(t,bP(e,i))}function SS(t,e){return typeof t=="function"?t(e):t}function _S(t){return t.split("-")[0]}function sI(t){return t.split("-")[1]}function ZJ(t){return t==="x"?"y":"x"}function JJ(t){return t==="y"?"height":"width"}const H8e=new Set(["top","bottom"]);function Yy(t){return H8e.has(_S(t))?"y":"x"}function QJ(t){return ZJ(Yy(t))}function U8e(t,e,i){i===void 0&&(i=!1);const n=sI(t),r=QJ(t),o=JJ(r);let a=r==="x"?n===(i?"end":"start")?"right":"left":n==="start"?"bottom":"top";return e.reference[o]>e.floating[o]&&(a=m5(a)),[a,m5(a)]}function z8e(t){const e=m5(t);return[hX(t),e,hX(e)]}function hX(t){return t.replace(/start|end/g,e=>V8e[e])}const Moe=["left","right"],Loe=["right","left"],$8e=["top","bottom"],W8e=["bottom","top"];function G8e(t,e,i){switch(t){case"top":case"bottom":return i?e?Loe:Moe:e?Moe:Loe;case"left":case"right":return e?$8e:W8e;default:return[]}}function Y8e(t,e,i,n){const r=sI(t);let o=G8e(_S(t),i==="start",n);return r&&(o=o.map(a=>a+"-"+r),e&&(o=o.concat(o.map(hX)))),o}function m5(t){return t.replace(/left|right|bottom|top/g,e=>j8e[e])}function q8e(t){return{top:0,right:0,bottom:0,left:0,...t}}function WEe(t){return typeof t!="number"?q8e(t):{top:t,right:t,bottom:t,left:t}}function b5(t){const{x:e,y:i,width:n,height:r}=t;return{width:n,height:r,top:i,left:e,right:e+n,bottom:i+r,x:e,y:i}}function koe(t,e,i){let{reference:n,floating:r}=t;const o=Yy(e),a=QJ(e),s=JJ(a),l=_S(e),u=o==="y",c=n.x+n.width/2-r.width/2,d=n.y+n.height/2-r.height/2,f=n[s]/2-r[s]/2;let h;switch(l){case"top":h={x:c,y:n.y-r.height};break;case"bottom":h={x:c,y:n.y+n.height};break;case"right":h={x:n.x+n.width,y:d};break;case"left":h={x:n.x-r.width,y:d};break;default:h={x:n.x,y:n.y}}switch(sI(e)){case"start":h[a]-=f*(i&&u?-1:1);break;case"end":h[a]+=f*(i&&u?-1:1);break}return h}async function X8e(t,e){var i;e===void 0&&(e={});const{x:n,y:r,platform:o,rects:a,elements:s,strategy:l}=t,{boundary:u="clippingAncestors",rootBoundary:c="viewport",elementContext:d="floating",altBoundary:f=!1,padding:h=0}=SS(e,t),p=WEe(h),v=s[f?d==="floating"?"reference":"floating":d],y=b5(await o.getClippingRect({element:(i=await(o.isElement==null?void 0:o.isElement(v)))==null||i?v:v.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)),boundary:u,rootBoundary:c,strategy:l})),m=d==="floating"?{x:n,y:r,width:a.floating.width,height:a.floating.height}:a.reference,b=await(o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)),S=await(o.isElement==null?void 0:o.isElement(b))?await(o.getScale==null?void 0:o.getScale(b))||{x:1,y:1}:{x:1,y:1},_=b5(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:m,offsetParent:b,strategy:l}):m);return{top:(y.top-_.top+p.top)/S.y,bottom:(_.bottom-y.bottom+p.bottom)/S.y,left:(y.left-_.left+p.left)/S.x,right:(_.right-y.right+p.right)/S.x}}const K8e=async(t,e,i)=>{const{placement:n="bottom",strategy:r="absolute",middleware:o=[],platform:a}=i,s=o.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(e));let u=await a.getElementRects({reference:t,floating:e,strategy:r}),{x:c,y:d}=koe(u,n,l),f=n,h={},p=0;for(let v=0;v<s.length;v++){var g;const{name:y,fn:m}=s[v],{x:b,y:S,data:_,reset:C}=await m({x:c,y:d,initialPlacement:n,placement:f,strategy:r,middlewareData:h,rects:u,platform:{...a,detectOverflow:(g=a.detectOverflow)!=null?g:X8e},elements:{reference:t,floating:e}});c=b??c,d=S??d,h={...h,[y]:{...h[y],..._}},C&&p<=50&&(p++,typeof C=="object"&&(C.placement&&(f=C.placement),C.rects&&(u=C.rects===!0?await a.getElementRects({reference:t,floating:e,strategy:r}):C.rects),{x:c,y:d}=koe(u,f,l)),v=-1)}return{x:c,y:d,placement:f,strategy:r,middlewareData:h}},Z8e=t=>({name:"arrow",options:t,async fn(e){const{x:i,y:n,placement:r,rects:o,platform:a,elements:s,middlewareData:l}=e,{element:u,padding:c=0}=SS(t,e)||{};if(u==null)return{};const d=WEe(c),f={x:i,y:n},h=QJ(r),p=JJ(h),g=await a.getDimensions(u),v=h==="y",y=v?"top":"left",m=v?"bottom":"right",b=v?"clientHeight":"clientWidth",S=o.reference[p]+o.reference[h]-f[h]-o.floating[p],_=f[h]-o.reference[h],C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u));let P=C?C[b]:0;(!P||!await(a.isElement==null?void 0:a.isElement(C)))&&(P=s.floating[b]||o.floating[p]);const x=S/2-_/2,E=P/2-g[p]/2-1,A=bP(d[y],E),R=bP(d[m],E),M=A,D=P-g[p]-R,F=P/2-g[p]/2+x,I=fX(M,F,D),V=!l.arrow&&sI(r)!=null&&F!==I&&o.reference[p]/2-(F<M?A:R)-g[p]/2<0,z=V?F<M?F-M:F-D:0;return{[h]:f[h]+z,data:{[h]:I,centerOffset:F-I-z,...V&&{alignmentOffset:z}},reset:V}}}),J8e=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var i,n;const{placement:r,middlewareData:o,rects:a,initialPlacement:s,platform:l,elements:u}=e,{mainAxis:c=!0,crossAxis:d=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:g=!0,...v}=SS(t,e);if((i=o.arrow)!=null&&i.alignmentOffset)return{};const y=_S(r),m=Yy(s),b=_S(s)===s,S=await(l.isRTL==null?void 0:l.isRTL(u.floating)),_=f||(b||!g?[m5(s)]:z8e(s)),C=p!=="none";!f&&C&&_.push(...Y8e(s,g,p,S));const P=[s,..._],x=await l.detectOverflow(e,v),E=[];let A=((n=o.flip)==null?void 0:n.overflows)||[];if(c&&E.push(x[y]),d){const F=U8e(r,a,S);E.push(x[F[0]],x[F[1]])}if(A=[...A,{placement:r,overflows:E}],!E.every(F=>F<=0)){var R,M;const F=(((R=o.flip)==null?void 0:R.index)||0)+1,I=P[F];if(I&&(!(d==="alignment"?m!==Yy(I):!1)||A.every(G=>Yy(G.placement)===m?G.overflows[0]>0:!0)))return{data:{index:F,overflows:A},reset:{placement:I}};let V=(M=A.filter(z=>z.overflows[0]<=0).sort((z,G)=>z.overflows[1]-G.overflows[1])[0])==null?void 0:M.placement;if(!V)switch(h){case"bestFit":{var D;const z=(D=A.filter(G=>{if(C){const H=Yy(G.placement);return H===m||H==="y"}return!0}).map(G=>[G.placement,G.overflows.filter(H=>H>0).reduce((H,U)=>H+U,0)]).sort((G,H)=>G[1]-H[1])[0])==null?void 0:D[0];z&&(V=z);break}case"initialPlacement":V=s;break}if(r!==V)return{reset:{placement:V}}}return{}}}};function Ioe(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function Noe(t){return B8e.some(e=>t[e]>=0)}const Q8e=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(e){const{rects:i,platform:n}=e,{strategy:r="referenceHidden",...o}=SS(t,e);switch(r){case"referenceHidden":{const a=await n.detectOverflow(e,{...o,elementContext:"reference"}),s=Ioe(a,i.reference);return{data:{referenceHiddenOffsets:s,referenceHidden:Noe(s)}}}case"escaped":{const a=await n.detectOverflow(e,{...o,altBoundary:!0}),s=Ioe(a,i.floating);return{data:{escapedOffsets:s,escaped:Noe(s)}}}default:return{}}}}},GEe=new Set(["left","top"]);async function eYe(t,e){const{placement:i,platform:n,elements:r}=t,o=await(n.isRTL==null?void 0:n.isRTL(r.floating)),a=_S(i),s=sI(i),l=Yy(i)==="y",u=GEe.has(a)?-1:1,c=o&&l?-1:1,d=SS(e,t);let{mainAxis:f,crossAxis:h,alignmentAxis:p}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&typeof p=="number"&&(h=s==="end"?p*-1:p),l?{x:h*c,y:f*u}:{x:f*u,y:h*c}}const tYe=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var i,n;const{x:r,y:o,placement:a,middlewareData:s}=e,l=await eYe(e,t);return a===((i=s.offset)==null?void 0:i.placement)&&(n=s.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:o+l.y,data:{...l,placement:a}}}}},rYe=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:i,y:n,placement:r,platform:o}=e,{mainAxis:a=!0,crossAxis:s=!1,limiter:l={fn:y=>{let{x:m,y:b}=y;return{x:m,y:b}}},...u}=SS(t,e),c={x:i,y:n},d=await o.detectOverflow(e,u),f=Yy(_S(r)),h=ZJ(f);let p=c[h],g=c[f];if(a){const y=h==="y"?"top":"left",m=h==="y"?"bottom":"right",b=p+d[y],S=p-d[m];p=fX(b,p,S)}if(s){const y=f==="y"?"top":"left",m=f==="y"?"bottom":"right",b=g+d[y],S=g-d[m];g=fX(b,g,S)}const v=l.fn({...e,[h]:p,[f]:g});return{...v,data:{x:v.x-i,y:v.y-n,enabled:{[h]:a,[f]:s}}}}}},iYe=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:i,y:n,placement:r,rects:o,middlewareData:a}=e,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=SS(t,e),c={x:i,y:n},d=Yy(r),f=ZJ(d);let h=c[f],p=c[d];const g=SS(s,e),v=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const b=f==="y"?"height":"width",S=o.reference[f]-o.floating[b]+v.mainAxis,_=o.reference[f]+o.reference[b]-v.mainAxis;h<S?h=S:h>_&&(h=_)}if(u){var y,m;const b=f==="y"?"width":"height",S=GEe.has(_S(r)),_=o.reference[d]-o.floating[b]+(S&&((y=a.offset)==null?void 0:y[d])||0)+(S?0:v.crossAxis),C=o.reference[d]+o.reference[b]+(S?0:((m=a.offset)==null?void 0:m[d])||0)-(S?v.crossAxis:0);p<_?p=_:p>C&&(p=C)}return{[f]:h,[d]:p}}}},nYe=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var i,n;const{placement:r,rects:o,platform:a,elements:s}=e,{apply:l=()=>{},...u}=SS(t,e),c=await a.detectOverflow(e,u),d=_S(r),f=sI(r),h=Yy(r)==="y",{width:p,height:g}=o.floating;let v,y;d==="top"||d==="bottom"?(v=d,y=f===(await(a.isRTL==null?void 0:a.isRTL(s.floating))?"start":"end")?"left":"right"):(y=d,v=f==="end"?"top":"bottom");const m=g-c.top-c.bottom,b=p-c.left-c.right,S=bP(g-c[v],m),_=bP(p-c[y],b),C=!e.middlewareData.shift;let P=S,x=_;if((i=e.middlewareData.shift)!=null&&i.enabled.x&&(x=b),(n=e.middlewareData.shift)!=null&&n.enabled.y&&(P=m),C&&!f){const A=_p(c.left,0),R=_p(c.right,0),M=_p(c.top,0),D=_p(c.bottom,0);h?x=p-2*(A!==0||R!==0?A+R:_p(c.left,c.right)):P=g-2*(M!==0||D!==0?M+D:_p(c.top,c.bottom))}await l({...e,availableWidth:x,availableHeight:P});const E=await a.getDimensions(s.floating);return p!==E.width||g!==E.height?{reset:{rects:!0}}:{}}}};function D$(){return typeof window<"u"}function lI(t){return YEe(t)?(t.nodeName||"").toLowerCase():"#document"}function wp(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function Sm(t){var e;return(e=(YEe(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function YEe(t){return D$()?t instanceof Node||t instanceof wp(t).Node:!1}function Nv(t){return D$()?t instanceof Element||t instanceof wp(t).Element:!1}function cm(t){return D$()?t instanceof HTMLElement||t instanceof wp(t).HTMLElement:!1}function Foe(t){return!D$()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof wp(t).ShadowRoot}const oYe=new Set(["inline","contents"]);function hV(t){const{overflow:e,overflowX:i,overflowY:n,display:r}=Fv(t);return/auto|scroll|overlay|hidden|clip/.test(e+n+i)&&!oYe.has(r)}const aYe=new Set(["table","td","th"]);function sYe(t){return aYe.has(lI(t))}const lYe=[":popover-open",":modal"];function R$(t){return lYe.some(e=>{try{return t.matches(e)}catch{return!1}})}const uYe=["transform","translate","scale","rotate","perspective"],cYe=["transform","translate","scale","rotate","perspective","filter"],dYe=["paint","layout","strict","content"];function eQ(t){const e=tQ(),i=Nv(t)?Fv(t):t;return uYe.some(n=>i[n]?i[n]!=="none":!1)||(i.containerType?i.containerType!=="normal":!1)||!e&&(i.backdropFilter?i.backdropFilter!=="none":!1)||!e&&(i.filter?i.filter!=="none":!1)||cYe.some(n=>(i.willChange||"").includes(n))||dYe.some(n=>(i.contain||"").includes(n))}function fYe(t){let e=SP(t);for(;cm(e)&&!mk(e);){if(eQ(e))return e;if(R$(e))return null;e=SP(e)}return null}function tQ(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const hYe=new Set(["html","body","#document"]);function mk(t){return hYe.has(lI(t))}function Fv(t){return wp(t).getComputedStyle(t)}function M$(t){return Nv(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function SP(t){if(lI(t)==="html")return t;const e=t.assignedSlot||t.parentNode||Foe(t)&&t.host||Sm(t);return Foe(e)?e.host:e}function qEe(t){const e=SP(t);return mk(e)?t.ownerDocument?t.ownerDocument.body:t.body:cm(e)&&hV(e)?e:qEe(e)}function $j(t,e,i){var n;e===void 0&&(e=[]),i===void 0&&(i=!0);const r=qEe(t),o=r===((n=t.ownerDocument)==null?void 0:n.body),a=wp(r);if(o){const s=pX(a);return e.concat(a,a.visualViewport||[],hV(r)?r:[],s&&i?$j(s):[])}return e.concat(r,$j(r,[],i))}function pX(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function XEe(t){const e=Fv(t);let i=parseFloat(e.width)||0,n=parseFloat(e.height)||0;const r=cm(t),o=r?t.offsetWidth:i,a=r?t.offsetHeight:n,s=y5(i)!==o||y5(n)!==a;return s&&(i=o,n=a),{width:i,height:n,$:s}}function rQ(t){return Nv(t)?t:t.contextElement}function jL(t){const e=rQ(t);if(!cm(e))return rm(1);const i=e.getBoundingClientRect(),{width:n,height:r,$:o}=XEe(e);let a=(o?y5(i.width):i.width)/n,s=(o?y5(i.height):i.height)/r;return(!a||!Number.isFinite(a))&&(a=1),(!s||!Number.isFinite(s))&&(s=1),{x:a,y:s}}const pYe=rm(0);function KEe(t){const e=wp(t);return!tQ()||!e.visualViewport?pYe:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function gYe(t,e,i){return e===void 0&&(e=!1),!i||e&&i!==wp(t)?!1:e}function bD(t,e,i,n){e===void 0&&(e=!1),i===void 0&&(i=!1);const r=t.getBoundingClientRect(),o=rQ(t);let a=rm(1);e&&(n?Nv(n)&&(a=jL(n)):a=jL(t));const s=gYe(o,i,n)?KEe(o):rm(0);let l=(r.left+s.x)/a.x,u=(r.top+s.y)/a.y,c=r.width/a.x,d=r.height/a.y;if(o){const f=wp(o),h=n&&Nv(n)?wp(n):n;let p=f,g=pX(p);for(;g&&n&&h!==p;){const v=jL(g),y=g.getBoundingClientRect(),m=Fv(g),b=y.left+(g.clientLeft+parseFloat(m.paddingLeft))*v.x,S=y.top+(g.clientTop+parseFloat(m.paddingTop))*v.y;l*=v.x,u*=v.y,c*=v.x,d*=v.y,l+=b,u+=S,p=wp(g),g=pX(p)}}return b5({width:c,height:d,x:l,y:u})}function L$(t,e){const i=M$(t).scrollLeft;return e?e.left+i:bD(Sm(t)).left+i}function ZEe(t,e){const i=t.getBoundingClientRect(),n=i.left+e.scrollLeft-L$(t,i),r=i.top+e.scrollTop;return{x:n,y:r}}function vYe(t){let{elements:e,rect:i,offsetParent:n,strategy:r}=t;const o=r==="fixed",a=Sm(n),s=e?R$(e.floating):!1;if(n===a||s&&o)return i;let l={scrollLeft:0,scrollTop:0},u=rm(1);const c=rm(0),d=cm(n);if((d||!d&&!o)&&((lI(n)!=="body"||hV(a))&&(l=M$(n)),cm(n))){const h=bD(n);u=jL(n),c.x=h.x+n.clientLeft,c.y=h.y+n.clientTop}const f=a&&!d&&!o?ZEe(a,l):rm(0);return{width:i.width*u.x,height:i.height*u.y,x:i.x*u.x-l.scrollLeft*u.x+c.x+f.x,y:i.y*u.y-l.scrollTop*u.y+c.y+f.y}}function yYe(t){return Array.from(t.getClientRects())}function mYe(t){const e=Sm(t),i=M$(t),n=t.ownerDocument.body,r=_p(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth),o=_p(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);let a=-i.scrollLeft+L$(t);const s=-i.scrollTop;return Fv(n).direction==="rtl"&&(a+=_p(e.clientWidth,n.clientWidth)-r),{width:r,height:o,x:a,y:s}}const Boe=25;function bYe(t,e){const i=wp(t),n=Sm(t),r=i.visualViewport;let o=n.clientWidth,a=n.clientHeight,s=0,l=0;if(r){o=r.width,a=r.height;const c=tQ();(!c||c&&e==="fixed")&&(s=r.offsetLeft,l=r.offsetTop)}const u=L$(n);if(u<=0){const c=n.ownerDocument,d=c.body,f=getComputedStyle(d),h=c.compatMode==="CSS1Compat"&&parseFloat(f.marginLeft)+parseFloat(f.marginRight)||0,p=Math.abs(n.clientWidth-d.clientWidth-h);p<=Boe&&(o-=p)}else u<=Boe&&(o+=u);return{width:o,height:a,x:s,y:l}}const SYe=new Set(["absolute","fixed"]);function _Ye(t,e){const i=bD(t,!0,e==="fixed"),n=i.top+t.clientTop,r=i.left+t.clientLeft,o=cm(t)?jL(t):rm(1),a=t.clientWidth*o.x,s=t.clientHeight*o.y,l=r*o.x,u=n*o.y;return{width:a,height:s,x:l,y:u}}function joe(t,e,i){let n;if(e==="viewport")n=bYe(t,i);else if(e==="document")n=mYe(Sm(t));else if(Nv(e))n=_Ye(e,i);else{const r=KEe(t);n={x:e.x-r.x,y:e.y-r.y,width:e.width,height:e.height}}return b5(n)}function JEe(t,e){const i=SP(t);return i===e||!Nv(i)||mk(i)?!1:Fv(i).position==="fixed"||JEe(i,e)}function PYe(t,e){const i=e.get(t);if(i)return i;let n=$j(t,[],!1).filter(s=>Nv(s)&&lI(s)!=="body"),r=null;const o=Fv(t).position==="fixed";let a=o?SP(t):t;for(;Nv(a)&&!mk(a);){const s=Fv(a),l=eQ(a);!l&&s.position==="fixed"&&(r=null),(o?!l&&!r:!l&&s.position==="static"&&!!r&&SYe.has(r.position)||hV(a)&&!l&&JEe(t,a))?n=n.filter(c=>c!==a):r=s,a=SP(a)}return e.set(t,n),n}function CYe(t){let{element:e,boundary:i,rootBoundary:n,strategy:r}=t;const a=[...i==="clippingAncestors"?R$(e)?[]:PYe(e,this._c):[].concat(i),n],s=a[0],l=a.reduce((u,c)=>{const d=joe(e,c,r);return u.top=_p(d.top,u.top),u.right=bP(d.right,u.right),u.bottom=bP(d.bottom,u.bottom),u.left=_p(d.left,u.left),u},joe(e,s,r));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function TYe(t){const{width:e,height:i}=XEe(t);return{width:e,height:i}}function xYe(t,e,i){const n=cm(e),r=Sm(e),o=i==="fixed",a=bD(t,!0,o,e);let s={scrollLeft:0,scrollTop:0};const l=rm(0);function u(){l.x=L$(r)}if(n||!n&&!o)if((lI(e)!=="body"||hV(r))&&(s=M$(e)),n){const h=bD(e,!0,o,e);l.x=h.x+e.clientLeft,l.y=h.y+e.clientTop}else r&&u();o&&!n&&r&&u();const c=r&&!n&&!o?ZEe(r,s):rm(0),d=a.left+s.scrollLeft-l.x-c.x,f=a.top+s.scrollTop-l.y-c.y;return{x:d,y:f,width:a.width,height:a.height}}function ZG(t){return Fv(t).position==="static"}function Voe(t,e){if(!cm(t)||Fv(t).position==="fixed")return null;if(e)return e(t);let i=t.offsetParent;return Sm(t)===i&&(i=i.ownerDocument.body),i}function QEe(t,e){const i=wp(t);if(R$(t))return i;if(!cm(t)){let r=SP(t);for(;r&&!mk(r);){if(Nv(r)&&!ZG(r))return r;r=SP(r)}return i}let n=Voe(t,e);for(;n&&sYe(n)&&ZG(n);)n=Voe(n,e);return n&&mk(n)&&ZG(n)&&!eQ(n)?i:n||fYe(t)||i}const EYe=async function(t){const e=this.getOffsetParent||QEe,i=this.getDimensions,n=await i(t.floating);return{reference:xYe(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function wYe(t){return Fv(t).direction==="rtl"}const AYe={convertOffsetParentRelativeRectToViewportRelativeRect:vYe,getDocumentElement:Sm,getClippingRect:CYe,getOffsetParent:QEe,getElementRects:EYe,getClientRects:yYe,getDimensions:TYe,getScale:jL,isElement:Nv,isRTL:wYe};function ewe(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function OYe(t,e){let i=null,n;const r=Sm(t);function o(){var s;clearTimeout(n),(s=i)==null||s.disconnect(),i=null}function a(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),o();const u=t.getBoundingClientRect(),{left:c,top:d,width:f,height:h}=u;if(s||e(),!f||!h)return;const p=yH(d),g=yH(r.clientWidth-(c+f)),v=yH(r.clientHeight-(d+h)),y=yH(c),b={rootMargin:-p+"px "+-g+"px "+-v+"px "+-y+"px",threshold:_p(0,bP(1,l))||1};let S=!0;function _(C){const P=C[0].intersectionRatio;if(P!==l){if(!S)return a();P?a(!1,P):n=setTimeout(()=>{a(!1,1e-7)},1e3)}P===1&&!ewe(u,t.getBoundingClientRect())&&a(),S=!1}try{i=new IntersectionObserver(_,{...b,root:r.ownerDocument})}catch{i=new IntersectionObserver(_,b)}i.observe(t)}return a(!0),o}function DYe(t,e,i,n){n===void 0&&(n={});const{ancestorScroll:r=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,u=rQ(t),c=r||o?[...u?$j(u):[],...$j(e)]:[];c.forEach(y=>{r&&y.addEventListener("scroll",i,{passive:!0}),o&&y.addEventListener("resize",i)});const d=u&&s?OYe(u,i):null;let f=-1,h=null;a&&(h=new ResizeObserver(y=>{let[m]=y;m&&m.target===u&&h&&(h.unobserve(e),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var b;(b=h)==null||b.observe(e)})),i()}),u&&!l&&h.observe(u),h.observe(e));let p,g=l?bD(t):null;l&&v();function v(){const y=bD(t);g&&!ewe(g,y)&&i(),g=y,p=requestAnimationFrame(v)}return i(),()=>{var y;c.forEach(m=>{r&&m.removeEventListener("scroll",i),o&&m.removeEventListener("resize",i)}),d==null||d(),(y=h)==null||y.disconnect(),h=null,l&&cancelAnimationFrame(p)}}const RYe=tYe,MYe=rYe,LYe=J8e,kYe=nYe,IYe=Q8e,Hoe=Z8e,NYe=iYe,FYe=(t,e,i)=>{const n=new Map,r={platform:AYe,...i},o={...r.platform,_c:n};return K8e(t,e,{...r,platform:o})};var BYe=typeof document<"u",jYe=function(){},AU=BYe?J.useLayoutEffect:jYe;function S5(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let i,n,r;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(i=t.length,i!==e.length)return!1;for(n=i;n--!==0;)if(!S5(t[n],e[n]))return!1;return!0}if(r=Object.keys(t),i=r.length,i!==Object.keys(e).length)return!1;for(n=i;n--!==0;)if(!{}.hasOwnProperty.call(e,r[n]))return!1;for(n=i;n--!==0;){const o=r[n];if(!(o==="_owner"&&t.$$typeof)&&!S5(t[o],e[o]))return!1}return!0}return t!==t&&e!==e}function twe(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function Uoe(t,e){const i=twe(t);return Math.round(e*i)/i}function JG(t){const e=J.useRef(t);return AU(()=>{e.current=t}),e}function VYe(t){t===void 0&&(t={});const{placement:e="bottom",strategy:i="absolute",middleware:n=[],platform:r,elements:{reference:o,floating:a}={},transform:s=!0,whileElementsMounted:l,open:u}=t,[c,d]=J.useState({x:0,y:0,strategy:i,placement:e,middlewareData:{},isPositioned:!1}),[f,h]=J.useState(n);S5(f,n)||h(n);const[p,g]=J.useState(null),[v,y]=J.useState(null),m=J.useCallback(G=>{G!==C.current&&(C.current=G,g(G))},[]),b=J.useCallback(G=>{G!==P.current&&(P.current=G,y(G))},[]),S=o||p,_=a||v,C=J.useRef(null),P=J.useRef(null),x=J.useRef(c),E=l!=null,A=JG(l),R=JG(r),M=JG(u),D=J.useCallback(()=>{if(!C.current||!P.current)return;const G={placement:e,strategy:i,middleware:f};R.current&&(G.platform=R.current),FYe(C.current,P.current,G).then(H=>{const U={...H,isPositioned:M.current!==!1};F.current&&!S5(x.current,U)&&(x.current=U,zf.flushSync(()=>{d(U)}))})},[f,e,i,R,M]);AU(()=>{u===!1&&x.current.isPositioned&&(x.current.isPositioned=!1,d(G=>({...G,isPositioned:!1})))},[u]);const F=J.useRef(!1);AU(()=>(F.current=!0,()=>{F.current=!1}),[]),AU(()=>{if(S&&(C.current=S),_&&(P.current=_),S&&_){if(A.current)return A.current(S,_,D);D()}},[S,_,D,A,E]);const I=J.useMemo(()=>({reference:C,floating:P,setReference:m,setFloating:b}),[m,b]),V=J.useMemo(()=>({reference:S,floating:_}),[S,_]),z=J.useMemo(()=>{const G={position:i,left:0,top:0};if(!V.floating)return G;const H=Uoe(V.floating,c.x),U=Uoe(V.floating,c.y);return s?{...G,transform:"translate("+H+"px, "+U+"px)",...twe(V.floating)>=1.5&&{willChange:"transform"}}:{position:i,left:H,top:U}},[i,s,V.floating,c.x,c.y]);return J.useMemo(()=>({...c,update:D,refs:I,elements:V,floatingStyles:z}),[c,D,I,V,z])}const HYe=t=>{function e(i){return{}.hasOwnProperty.call(i,"current")}return{name:"arrow",options:t,fn(i){const{element:n,padding:r}=typeof t=="function"?t(i):t;return n&&e(n)?n.current!=null?Hoe({element:n.current,padding:r}).fn(i):{}:n?Hoe({element:n,padding:r}).fn(i):{}}}},UYe=(t,e)=>({...RYe(t),options:[t,e]}),zYe=(t,e)=>({...MYe(t),options:[t,e]}),$Ye=(t,e)=>({...NYe(t),options:[t,e]}),WYe=(t,e)=>({...LYe(t),options:[t,e]}),GYe=(t,e)=>({...kYe(t),options:[t,e]}),YYe=(t,e)=>({...IYe(t),options:[t,e]}),qYe=(t,e)=>({...HYe(t),options:[t,e]});var XYe="Arrow",rwe=J.forwardRef((t,e)=>{const{children:i,width:n=10,height:r=5,...o}=t;return L.jsx(es.svg,{...o,ref:e,width:n,height:r,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?i:L.jsx("polygon",{points:"0,0 30,0 15,10"})})});rwe.displayName=XYe;var KYe=rwe;function ZYe(t){const[e,i]=J.useState(void 0);return bS(()=>{if(t){i({width:t.offsetWidth,height:t.offsetHeight});const n=new ResizeObserver(r=>{if(!Array.isArray(r)||!r.length)return;const o=r[0];let a,s;if("borderBoxSize"in o){const l=o.borderBoxSize,u=Array.isArray(l)?l[0]:l;a=u.inlineSize,s=u.blockSize}else a=t.offsetWidth,s=t.offsetHeight;i({width:a,height:s})});return n.observe(t,{box:"border-box"}),()=>n.unobserve(t)}else i(void 0)},[t]),e}var iQ="Popper",[iwe,uI]=kS(iQ),[JYe,nwe]=iwe(iQ),owe=t=>{const{__scopePopper:e,children:i}=t,[n,r]=J.useState(null);return L.jsx(JYe,{scope:e,anchor:n,onAnchorChange:r,children:i})};owe.displayName=iQ;var awe="PopperAnchor",swe=J.forwardRef((t,e)=>{const{__scopePopper:i,virtualRef:n,...r}=t,o=nwe(awe,i),a=J.useRef(null),s=Bl(e,a),l=J.useRef(null);return J.useEffect(()=>{const u=l.current;l.current=(n==null?void 0:n.current)||a.current,u!==l.current&&o.onAnchorChange(l.current)}),n?null:L.jsx(es.div,{...r,ref:s})});swe.displayName=awe;var nQ="PopperContent",[QYe,eqe]=iwe(nQ),lwe=J.forwardRef((t,e)=>{var de,ge,Ee,Re,Ae,Pe;const{__scopePopper:i,side:n="bottom",sideOffset:r=0,align:o="center",alignOffset:a=0,arrowPadding:s=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:c=0,sticky:d="partial",hideWhenDetached:f=!1,updatePositionStrategy:h="optimized",onPlaced:p,...g}=t,v=nwe(nQ,i),[y,m]=J.useState(null),b=Bl(e,we=>m(we)),[S,_]=J.useState(null),C=ZYe(S),P=(C==null?void 0:C.width)??0,x=(C==null?void 0:C.height)??0,E=n+(o!=="center"?"-"+o:""),A=typeof c=="number"?c:{top:0,right:0,bottom:0,left:0,...c},R=Array.isArray(u)?u:[u],M=R.length>0,D={padding:A,boundary:R.filter(rqe),altBoundary:M},{refs:F,floatingStyles:I,placement:V,isPositioned:z,middlewareData:G}=VYe({strategy:"fixed",placement:E,whileElementsMounted:(...we)=>DYe(...we,{animationFrame:h==="always"}),elements:{reference:v.anchor},middleware:[UYe({mainAxis:r+x,alignmentAxis:a}),l&&zYe({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?$Ye():void 0,...D}),l&&WYe({...D}),GYe({...D,apply:({elements:we,rects:Te,availableWidth:ke,availableHeight:$e})=>{const{width:Ne,height:ve}=Te.reference,pe=we.floating.style;pe.setProperty("--radix-popper-available-width",`${ke}px`),pe.setProperty("--radix-popper-available-height",`${$e}px`),pe.setProperty("--radix-popper-anchor-width",`${Ne}px`),pe.setProperty("--radix-popper-anchor-height",`${ve}px`)}}),S&&qYe({element:S,padding:s}),iqe({arrowWidth:P,arrowHeight:x}),f&&YYe({strategy:"referenceHidden",...D})]}),[H,U]=dwe(V),k=um(p);bS(()=>{z&&(k==null||k())},[z,k]);const X=(de=G.arrow)==null?void 0:de.x,W=(ge=G.arrow)==null?void 0:ge.y,Y=((Ee=G.arrow)==null?void 0:Ee.centerOffset)!==0,[te,oe]=J.useState();return bS(()=>{y&&oe(window.getComputedStyle(y).zIndex)},[y]),L.jsx("div",{ref:F.setFloating,"data-radix-popper-content-wrapper":"",style:{...I,transform:z?I.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:te,"--radix-popper-transform-origin":[(Re=G.transformOrigin)==null?void 0:Re.x,(Ae=G.transformOrigin)==null?void 0:Ae.y].join(" "),...((Pe=G.hide)==null?void 0:Pe.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:L.jsx(QYe,{scope:i,placedSide:H,onArrowChange:_,arrowX:X,arrowY:W,shouldHideArrow:Y,children:L.jsx(es.div,{"data-side":H,"data-align":U,...g,ref:b,style:{...g.style,animation:z?void 0:"none"}})})})});lwe.displayName=nQ;var uwe="PopperArrow",tqe={top:"bottom",right:"left",bottom:"top",left:"right"},cwe=J.forwardRef(function(e,i){const{__scopePopper:n,...r}=e,o=eqe(uwe,n),a=tqe[o.placedSide];return L.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:L.jsx(KYe,{...r,ref:i,style:{...r.style,display:"block"}})})});cwe.displayName=uwe;function rqe(t){return t!==null}var iqe=t=>({name:"transformOrigin",options:t,fn(e){var v,y,m;const{placement:i,rects:n,middlewareData:r}=e,a=((v=r.arrow)==null?void 0:v.centerOffset)!==0,s=a?0:t.arrowWidth,l=a?0:t.arrowHeight,[u,c]=dwe(i),d={start:"0%",center:"50%",end:"100%"}[c],f=(((y=r.arrow)==null?void 0:y.x)??0)+s/2,h=(((m=r.arrow)==null?void 0:m.y)??0)+l/2;let p="",g="";return u==="bottom"?(p=a?d:`${f}px`,g=`${-l}px`):u==="top"?(p=a?d:`${f}px`,g=`${n.floating.height+l}px`):u==="right"?(p=`${-l}px`,g=a?d:`${h}px`):u==="left"&&(p=`${n.floating.width+l}px`,g=a?d:`${h}px`),{data:{x:p,y:g}}}});function dwe(t){const[e,i="center"]=t.split("-");return[e,i]}var k$=owe,I$=swe,oQ=lwe,aQ=cwe,nqe="Portal",pV=J.forwardRef((t,e)=>{var s;const{container:i,...n}=t,[r,o]=J.useState(!1);bS(()=>o(!0),[]);const a=i||r&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return a?uze.createPortal(L.jsx(es.div,{...n,ref:e}),a):null});pV.displayName=nqe;function oqe(t,e){return J.useReducer((i,n)=>e[i][n]??i,t)}var Mp=t=>{const{present:e,children:i}=t,n=aqe(e),r=typeof i=="function"?i({present:n.isPresent}):J.Children.only(i),o=Bl(n.ref,sqe(r));return typeof i=="function"||n.isPresent?J.cloneElement(r,{ref:o}):null};Mp.displayName="Presence";function aqe(t){const[e,i]=J.useState(),n=J.useRef(null),r=J.useRef(t),o=J.useRef("none"),a=t?"mounted":"unmounted",[s,l]=oqe(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return J.useEffect(()=>{const u=mH(n.current);o.current=s==="mounted"?u:"none"},[s]),bS(()=>{const u=n.current,c=r.current;if(c!==t){const f=o.current,h=mH(u);t?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(c&&f!==h?"ANIMATION_OUT":"UNMOUNT"),r.current=t}},[t,l]),bS(()=>{if(e){let u;const c=e.ownerDocument.defaultView??window,d=h=>{const g=mH(n.current).includes(CSS.escape(h.animationName));if(h.target===e&&g&&(l("ANIMATION_END"),!r.current)){const v=e.style.animationFillMode;e.style.animationFillMode="forwards",u=c.setTimeout(()=>{e.style.animationFillMode==="forwards"&&(e.style.animationFillMode=v)})}},f=h=>{h.target===e&&(o.current=mH(n.current))};return e.addEventListener("animationstart",f),e.addEventListener("animationcancel",d),e.addEventListener("animationend",d),()=>{c.clearTimeout(u),e.removeEventListener("animationstart",f),e.removeEventListener("animationcancel",d),e.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[e,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:J.useCallback(u=>{n.current=u?getComputedStyle(u):null,i(u)},[])}}function mH(t){return(t==null?void 0:t.animationName)||"none"}function sqe(t){var n,r;let e=(n=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:n.get,i=e&&"isReactWarning"in e&&e.isReactWarning;return i?t.ref:(e=(r=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:r.get,i=e&&"isReactWarning"in e&&e.isReactWarning,i?t.props.ref:t.props.ref||t.ref)}var lqe=s5[" useInsertionEffect ".trim().toString()]||bS;function ND({prop:t,defaultProp:e,onChange:i=()=>{},caller:n}){const[r,o,a]=uqe({defaultProp:e,onChange:i}),s=t!==void 0,l=s?t:r;{const c=J.useRef(t!==void 0);J.useEffect(()=>{const d=c.current;d!==s&&console.warn(`${n} is changing from ${d?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),c.current=s},[s,n])}const u=J.useCallback(c=>{var d;if(s){const f=cqe(c)?c(t):c;f!==t&&((d=a.current)==null||d.call(a,f))}else o(c)},[s,t,o,a]);return[l,u]}function uqe({defaultProp:t,onChange:e}){const[i,n]=J.useState(t),r=J.useRef(i),o=J.useRef(e);return lqe(()=>{o.current=e},[e]),J.useEffect(()=>{var a;r.current!==i&&((a=o.current)==null||a.call(o,i),r.current=i)},[i,r]),[i,n,o]}function cqe(t){return typeof t=="function"}var dqe=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),fqe="VisuallyHidden",fwe=J.forwardRef((t,e)=>L.jsx(es.span,{...t,ref:e,style:{...dqe,...t.style}}));fwe.displayName=fqe;var hqe=fwe,[N$]=kS("Tooltip",[uI]),F$=uI(),hwe="TooltipProvider",pqe=700,gX="tooltip.open",[gqe,sQ]=N$(hwe),pwe=t=>{const{__scopeTooltip:e,delayDuration:i=pqe,skipDelayDuration:n=300,disableHoverableContent:r=!1,children:o}=t,a=J.useRef(!0),s=J.useRef(!1),l=J.useRef(0);return J.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),L.jsx(gqe,{scope:e,isOpenDelayedRef:a,delayDuration:i,onOpen:J.useCallback(()=>{window.clearTimeout(l.current),a.current=!1},[]),onClose:J.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>a.current=!0,n)},[n]),isPointerInTransitRef:s,onPointerInTransitChange:J.useCallback(u=>{s.current=u},[]),disableHoverableContent:r,children:o})};pwe.displayName=hwe;var Wj="Tooltip",[vqe,gV]=N$(Wj),lQ=t=>{const{__scopeTooltip:e,children:i,open:n,defaultOpen:r,onOpenChange:o,disableHoverableContent:a,delayDuration:s}=t,l=sQ(Wj,t.__scopeTooltip),u=F$(e),[c,d]=J.useState(null),f=Mv(),h=J.useRef(0),p=a??l.disableHoverableContent,g=s??l.delayDuration,v=J.useRef(!1),[y,m]=ND({prop:n,defaultProp:r??!1,onChange:P=>{P?(l.onOpen(),document.dispatchEvent(new CustomEvent(gX))):l.onClose(),o==null||o(P)},caller:Wj}),b=J.useMemo(()=>y?v.current?"delayed-open":"instant-open":"closed",[y]),S=J.useCallback(()=>{window.clearTimeout(h.current),h.current=0,v.current=!1,m(!0)},[m]),_=J.useCallback(()=>{window.clearTimeout(h.current),h.current=0,m(!1)},[m]),C=J.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{v.current=!0,m(!0),h.current=0},g)},[g,m]);return J.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),L.jsx(k$,{...u,children:L.jsx(vqe,{scope:e,contentId:f,open:y,stateAttribute:b,trigger:c,onTriggerChange:d,onTriggerEnter:J.useCallback(()=>{l.isOpenDelayedRef.current?C():S()},[l.isOpenDelayedRef,C,S]),onTriggerLeave:J.useCallback(()=>{p?_():(window.clearTimeout(h.current),h.current=0)},[_,p]),onOpen:S,onClose:_,disableHoverableContent:p,children:i})})};lQ.displayName=Wj;var vX="TooltipTrigger",uQ=J.forwardRef((t,e)=>{const{__scopeTooltip:i,...n}=t,r=gV(vX,i),o=sQ(vX,i),a=F$(i),s=J.useRef(null),l=Bl(e,s,r.onTriggerChange),u=J.useRef(!1),c=J.useRef(!1),d=J.useCallback(()=>u.current=!1,[]);return J.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),L.jsx(I$,{asChild:!0,...a,children:L.jsx(es.button,{"aria-describedby":r.open?r.contentId:void 0,"data-state":r.stateAttribute,...n,ref:l,onPointerMove:tn(t.onPointerMove,f=>{f.pointerType!=="touch"&&!c.current&&!o.isPointerInTransitRef.current&&(r.onTriggerEnter(),c.current=!0)}),onPointerLeave:tn(t.onPointerLeave,()=>{r.onTriggerLeave(),c.current=!1}),onPointerDown:tn(t.onPointerDown,()=>{r.open&&r.onClose(),u.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:tn(t.onFocus,()=>{u.current||r.onOpen()}),onBlur:tn(t.onBlur,r.onClose),onClick:tn(t.onClick,r.onClose)})})});uQ.displayName=vX;var cQ="TooltipPortal",[yqe,mqe]=N$(cQ,{forceMount:void 0}),dQ=t=>{const{__scopeTooltip:e,forceMount:i,children:n,container:r}=t,o=gV(cQ,e);return L.jsx(yqe,{scope:e,forceMount:i,children:L.jsx(Mp,{present:i||o.open,children:L.jsx(pV,{asChild:!0,container:r,children:n})})})};dQ.displayName=cQ;var bk="TooltipContent",fQ=J.forwardRef((t,e)=>{const i=mqe(bk,t.__scopeTooltip),{forceMount:n=i.forceMount,side:r="top",...o}=t,a=gV(bk,t.__scopeTooltip);return L.jsx(Mp,{present:n||a.open,children:a.disableHoverableContent?L.jsx(gwe,{side:r,...o,ref:e}):L.jsx(bqe,{side:r,...o,ref:e})})}),bqe=J.forwardRef((t,e)=>{const i=gV(bk,t.__scopeTooltip),n=sQ(bk,t.__scopeTooltip),r=J.useRef(null),o=Bl(e,r),[a,s]=J.useState(null),{trigger:l,onClose:u}=i,c=r.current,{onPointerInTransitChange:d}=n,f=J.useCallback(()=>{s(null),d(!1)},[d]),h=J.useCallback((p,g)=>{const v=p.currentTarget,y={x:p.clientX,y:p.clientY},m=Tqe(y,v.getBoundingClientRect()),b=xqe(y,m),S=Eqe(g.getBoundingClientRect()),_=Aqe([...b,...S]);s(_),d(!0)},[d]);return J.useEffect(()=>()=>f(),[f]),J.useEffect(()=>{if(l&&c){const p=v=>h(v,c),g=v=>h(v,l);return l.addEventListener("pointerleave",p),c.addEventListener("pointerleave",g),()=>{l.removeEventListener("pointerleave",p),c.removeEventListener("pointerleave",g)}}},[l,c,h,f]),J.useEffect(()=>{if(a){const p=g=>{const v=g.target,y={x:g.clientX,y:g.clientY},m=(l==null?void 0:l.contains(v))||(c==null?void 0:c.contains(v)),b=!wqe(y,a);m?f():b&&(f(),u())};return document.addEventListener("pointermove",p),()=>document.removeEventListener("pointermove",p)}},[l,c,a,u,f]),L.jsx(gwe,{...t,ref:o})}),[Sqe,_qe]=N$(Wj,{isInside:!1}),Pqe=C8e("TooltipContent"),gwe=J.forwardRef((t,e)=>{const{__scopeTooltip:i,children:n,"aria-label":r,onEscapeKeyDown:o,onPointerDownOutside:a,...s}=t,l=gV(bk,i),u=F$(i),{onClose:c}=l;return J.useEffect(()=>(document.addEventListener(gX,c),()=>document.removeEventListener(gX,c)),[c]),J.useEffect(()=>{if(l.trigger){const d=f=>{const h=f.target;h!=null&&h.contains(l.trigger)&&c()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,c]),L.jsx(fV,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:d=>d.preventDefault(),onDismiss:c,children:L.jsxs(oQ,{"data-state":l.stateAttribute,...u,...s,ref:e,style:{...s.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[L.jsx(Pqe,{children:n}),L.jsx(Sqe,{scope:i,isInside:!0,children:L.jsx(hqe,{id:l.contentId,role:"tooltip",children:r||n})})]})})});fQ.displayName=bk;var vwe="TooltipArrow",Cqe=J.forwardRef((t,e)=>{const{__scopeTooltip:i,...n}=t,r=F$(i);return _qe(vwe,i).isInside?null:L.jsx(aQ,{...r,...n,ref:e})});Cqe.displayName=vwe;function Tqe(t,e){const i=Math.abs(e.top-t.y),n=Math.abs(e.bottom-t.y),r=Math.abs(e.right-t.x),o=Math.abs(e.left-t.x);switch(Math.min(i,n,r,o)){case o:return"left";case r:return"right";case i:return"top";case n:return"bottom";default:throw new Error("unreachable")}}function xqe(t,e,i=5){const n=[];switch(e){case"top":n.push({x:t.x-i,y:t.y+i},{x:t.x+i,y:t.y+i});break;case"bottom":n.push({x:t.x-i,y:t.y-i},{x:t.x+i,y:t.y-i});break;case"left":n.push({x:t.x+i,y:t.y-i},{x:t.x+i,y:t.y+i});break;case"right":n.push({x:t.x-i,y:t.y-i},{x:t.x-i,y:t.y+i});break}return n}function Eqe(t){const{top:e,right:i,bottom:n,left:r}=t;return[{x:r,y:e},{x:i,y:e},{x:i,y:n},{x:r,y:n}]}function wqe(t,e){const{x:i,y:n}=t;let r=!1;for(let o=0,a=e.length-1;o<e.length;a=o++){const s=e[o],l=e[a],u=s.x,c=s.y,d=l.x,f=l.y;c>n!=f>n&&i<(d-u)*(n-c)/(f-c)+u&&(r=!r)}return r}function Aqe(t){const e=t.slice();return e.sort((i,n)=>i.x<n.x?-1:i.x>n.x?1:i.y<n.y?-1:i.y>n.y?1:0),Oqe(e)}function Oqe(t){if(t.length<=1)return t.slice();const e=[];for(let n=0;n<t.length;n++){const r=t[n];for(;e.length>=2;){const o=e[e.length-1],a=e[e.length-2];if((o.x-a.x)*(r.y-a.y)>=(o.y-a.y)*(r.x-a.x))e.pop();else break}e.push(r)}e.pop();const i=[];for(let n=t.length-1;n>=0;n--){const r=t[n];for(;i.length>=2;){const o=i[i.length-1],a=i[i.length-2];if((o.x-a.x)*(r.y-a.y)>=(o.y-a.y)*(r.x-a.x))i.pop();else break}i.push(r)}return i.pop(),e.length===1&&i.length===1&&e[0].x===i[0].x&&e[0].y===i[0].y?e:e.concat(i)}var Dqe=lQ,Rqe=uQ,Mqe=dQ,Lqe=fQ;function FD(t){const e=qt.c(13),i=t.side??"bottom",n=t.delay??0;let r;e[0]!==t.className?(r=Hr("inline-flex",t.className),e[0]=t.className,e[1]=r):r=e[1];let o;e[2]!==t.children||e[3]!==r?(o=L.jsx(uQ,{asChild:!0,children:L.jsx("div",{className:r,children:t.children})}),e[2]=t.children,e[3]=r,e[4]=o):o=e[4];let a;e[5]===Symbol.for("react.memo_cache_sentinel")?(a=Hr("z-[9999] max-w-[var(--radix-tooltip-content-available-width)]","px-3 py-2.5 bg-slate-50 text-slate-950 border dark:bg-neutral-800 dark:text-neutral-200 rounded-lg shadow-2xl","transition-opacity duration-150"),e[5]=a):a=e[5];let s;e[6]!==t.content||e[7]!==i?(s=L.jsx(dQ,{children:L.jsx(fQ,{side:i,sideOffset:8,avoidCollisions:!0,collisionPadding:8,className:a,children:t.content})}),e[6]=t.content,e[7]=i,e[8]=s):s=e[8];let l;return e[9]!==n||e[10]!==o||e[11]!==s?(l=L.jsxs(lQ,{delayDuration:n,children:[o,s]}),e[9]=n,e[10]=o,e[11]=s,e[12]=l):l=e[12],l}function kqe(t){const e=qt.c(7);let i;e[0]!==t.className?(i=Hr("flex items-center gap-0.5 p-1 rounded-lg bg-muted",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;e[2]!==t?(n=t.options.map(o=>{const a=t.value===o.value,s=o.isLoading,l=o.icon&&!o.label,u=L.jsxs("button",{onClick:()=>t.onChange(o.value),className:Hr("flex items-center justify-center gap-1.5 rounded-md transition-all duration-150",l?"w-8 h-8":"px-3 py-1.5",a?"bg-blue-950/90 text-primary-foreground dark:bg-background dark:text-foreground":"text-muted-foreground hover:text-foreground hover:bg-muted-foreground/10"),children:[s?L.jsx(Wr,{type:dr.STATUS_LOADING,className:Hr("animate-spin",l?"w-4 h-4":"w-3.5 h-3.5")}):o.icon&&L.jsx(Wr,{type:o.icon,className:l?"w-4 h-4":"w-3.5 h-3.5"}),!l&&o.label&&L.jsx("span",{className:"text-xs font-medium",children:o.label})]},o.value);return o.tooltip?L.jsx(FD,{content:L.jsx("p",{className:"text-xs",children:o.tooltip}),side:"bottom",delay:400,children:u},o.value):u}),e[2]=t,e[3]=n):n=e[3];let r;return e[4]!==i||e[5]!==n?(r=L.jsx("div",{className:i,children:n}),e[4]=i,e[5]=n,e[6]=r):r=e[6],r}const qs={OVERVIEW:"overview",FILES:"files",TOPOLOGY:"topology",SETTINGS:"settings",ABOUT:"about"},rS={MAIN:"main",BOTTOM:"bottom"},bH=[{id:qs.OVERVIEW,label:"Overview",icon:Xi.CONTEXT_HOME,position:rS.MAIN},{id:qs.FILES,label:"Files",icon:Xi.CONTEXT_FILES,position:rS.MAIN},{id:qs.TOPOLOGY,label:"Topology",icon:Xi.CONTEXT_TOPOLOGY,position:rS.MAIN},{id:qs.SETTINGS,label:"Settings",icon:Xi.CONTEXT_SETTINGS,position:rS.BOTTOM},{id:qs.ABOUT,label:"About",icon:Xi.CONTEXT_ABOUT,position:rS.BOTTOM}],Nu={WELCOME:"/",OVERVIEW:"/overview",FILES:"/files",TOPOLOGY_PLATFORM:"/topology/platform",TOPOLOGY_INSTANCE:"/topology/instance",TOPOLOGY_RESTBUS:"/topology/restbus",TOPOLOGY_API_PLAYGROUND:"/topology/api-playground",SETTINGS:"/settings",ABOUT:"/about"};function QG(t){const e=qt.c(23);let i;e[0]!==t.iconType?(i=L.jsx("div",{className:"flex-shrink-0 w-9 h-9 rounded-md bg-primary/10 dark:bg-primary/20 flex items-center justify-center",children:L.jsx(Wr,{type:t.iconType,className:"w-4 h-4 text-primary"})}),e[0]=t.iconType,e[1]=i):i=e[1];let n;e[2]!==t.label?(n=L.jsx("div",{className:"font-medium text-foreground text-sm",children:t.label}),e[2]=t.label,e[3]=n):n=e[3];let r;e[4]!==t.description?(r=L.jsx("div",{className:"text-xs text-muted-foreground truncate",children:t.description}),e[4]=t.description,e[5]=r):r=e[5];let o;e[6]!==n||e[7]!==r?(o=L.jsxs("div",{className:"flex-1 min-w-0 text-start",children:[n,r]}),e[6]=n,e[7]=r,e[8]=o):o=e[8];let a;e[9]!==i||e[10]!==o?(a=L.jsxs("div",{className:"flex justify-start items-center gap-3 flex-1 min-w-0",children:[i,o]}),e[9]=i,e[10]=o,e[11]=a):a=e[11];let s;e[12]!==t.hint?(s=t.hint&&L.jsx("span",{className:"text-xs text-muted-foreground/60 flex-shrink-0",children:t.hint}),e[12]=t.hint,e[13]=s):s=e[13];let l;e[14]!==t.external?(l=t.external&&L.jsx(Wr,{type:dr.ACTION_EXTERNAL_LINK,className:"w-3.5 h-3.5 text-muted-foreground/60 flex-shrink-0"}),e[14]=t.external,e[15]=l):l=e[15];let u;e[16]!==a||e[17]!==s||e[18]!==l?(u=L.jsxs("div",{className:"flex gap-3 flex-1 min-w-0",children:[a,s,l]}),e[16]=a,e[17]=s,e[18]=l,e[19]=u):u=e[19];const c=u;let d;return e[20]!==c||e[21]!==t.onClick?(d=L.jsx("button",{onClick:t.onClick,className:"flex items-center gap-3 w-full px-3 py-2 rounded-md transition-colors hover:bg-white/10 group cursor-pointer",children:c}),e[20]=c,e[21]=t.onClick,e[22]=d):d=e[22],d}function Iqe(t){const e=qt.c(3);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i={maskImage:"url(/images/rlabs_logo_bw.svg)",maskSize:"contain",maskRepeat:"no-repeat",maskPosition:"center",WebkitMaskImage:"url(/images/rlabs_logo_bw.svg)",WebkitMaskSize:"contain",WebkitMaskRepeat:"no-repeat",WebkitMaskPosition:"center",backgroundColor:"currentColor"},e[0]=i):i=e[0];let n;return e[1]!==t.className?(n=L.jsx("div",{className:t.className,style:i,role:"img","aria-label":"RemotiveLabs"}),e[1]=t.className,e[2]=n):n=e[2],n}const Nqe={route:Nu.WELCOME,title:"Welcome",icon:Xi.CONTEXT_HOME,component:ywe};function ywe(){const t=qt.c(6),{openPage:e}=Ih(),{setActiveContext:i}=e2(),n=Fqe;let r;t[0]!==e||t[1]!==i?(r=()=>L.jsx(L.Fragment,{children:L.jsx("div",{className:"w-full max-w-md space-y-4 px-4",children:L.jsxs("div",{children:[L.jsxs("h3",{className:"text-[11px] font-light uppercase tracking-wider text-muted-foreground mb-1.5 px-1",children:["Let's"," ",L.jsx("span",{className:"font-bold",children:"get stuff done!"})]}),L.jsxs("div",{children:[L.jsx(QG,{iconType:dr.CONTEXT_HOME,label:"Open overview",description:"Get started with helpful links",onClick:()=>{e(Nu.OVERVIEW)}}),L.jsx(QG,{iconType:dr.CONTEXT_SETTINGS,label:"Customize your experience",description:"Change the appearance and behavior of RemotiveStudio",onClick:()=>{e(Nu.SETTINGS)}}),L.jsx(QG,{iconType:dr.CONTEXT_FILES,label:"Start working with the file tree",description:"E.g. visualize RemotiveTopology files and build dashboards",onClick:()=>{i(qs.FILES)}})]})]})})}),t[0]=e,t[1]=i,t[2]=r):r=t[2];const o=r;let a;t[3]===Symbol.for("react.memo_cache_sentinel")?(a=n(),t[3]=a):a=t[3];let s;return t[4]!==o?(s=L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center select-none overflow-auto py-6",children:[a,o()]}),t[4]=o,t[5]=s):s=t[5],s}function Fqe(){return L.jsx(L.Fragment,{children:L.jsx("div",{className:"mb-12 flex-shrink-0",children:L.jsx(Iqe,{className:"w-56 h-56 text-neutral-300 dark:text-neutral-700"})})})}function e8(t){const e=qt.c(17),i=t.href;let n;e[0]!==t.className?(n=Hr("group relative flex flex-col items-start p-6 rounded-2xl","bg-card border border-border","hover:border-primary/50 hover:shadow-lg hover:shadow-primary/5","hover:-translate-y-0.5","transition-all duration-300 ease-out","text-left w-full",t.className),e[0]=t.className,e[1]=n):n=e[1];let r;e[2]!==t.iconType?(r=L.jsx("div",{className:"p-3 rounded-xl bg-primary/10 text-primary",children:L.jsx(Wr,{type:t.iconType,className:"w-6 h-6"})}),e[2]=t.iconType,e[3]=r):r=e[3];let o;e[4]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx(Wr,{type:dr.ACTION_EXTERNAL_LINK,className:"w-4 h-4 text-muted-foreground opacity-0 group-hover:opacity-100 transition-opacity duration-200",style:{position:"absolute",right:18,top:18}}),e[4]=o):o=e[4];let a;e[5]!==r?(a=L.jsxs("div",{className:"flex items-center justify-between w-full mb-4",children:[r,o]}),e[5]=r,e[6]=a):a=e[6];let s;e[7]!==t.title?(s=L.jsx("h3",{className:"text-lg font-semibold text-card-foreground mb-1",children:t.title}),e[7]=t.title,e[8]=s):s=e[8];let l;e[9]!==t.description?(l=t.description&&L.jsx("p",{className:"text-sm text-muted-foreground",children:t.description}),e[9]=t.description,e[10]=l):l=e[10];let u;return e[11]!==t.href||e[12]!==n||e[13]!==a||e[14]!==s||e[15]!==l?(u=L.jsxs("a",{href:i,target:"_blank",rel:"noopener noreferrer",className:n,children:[a,s,l]}),e[11]=t.href,e[12]=n,e[13]=a,e[14]=s,e[15]=l,e[16]=u):u=e[16],u}function zoe(t){const e=qt.c(11);let i;e[0]!==t.title?(i=L.jsx("p",{className:"font-medium text-card-foreground",children:t.title}),e[0]=t.title,e[1]=i):i=e[1];let n;e[2]!==t.description?(n=L.jsx("p",{className:"text-sm text-muted-foreground",children:t.description}),e[2]=t.description,e[3]=n):n=e[3];let r;e[4]!==i||e[5]!==n?(r=L.jsxs("div",{className:"px-8",children:[i,n]}),e[4]=i,e[5]=n,e[6]=r):r=e[6];let o;e[7]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx("div",{className:"px-8",children:L.jsx(Wr,{type:dr.ACTION_EXTERNAL_LINK,className:"h-4 w-4 text-muted-foreground"})}),e[7]=o):o=e[7];let a;return e[8]!==t.link||e[9]!==r?(a=L.jsxs("a",{href:t.link,target:"_blank",rel:"noopener noreferrer",className:"flex items-center justify-between py-3 px-0 hover:bg-muted/50 transition-colors border-b border-border/50 last:border-0",children:[r,o]}),e[8]=t.link,e[9]=r,e[10]=a):a=e[10],a}const mwe=J.createContext(null),bwe="/api/studio/v1",Bqe=`http://localhost:57123${bwe}`,jqe="AIzaSyAWP8ZPH513e9xl6YOunHbItqd3yP9Zlxs",Vqe="1.16.9",Swe=!1,Hqe="initial-splash";function Uqe(){return{googleMapsApiKey:jqe}}function zqe(){return{showHiddenFiles:(localStorage.getItem("SHOW_HIDDEN_FILES_PREFERENCES")??"true")==="true"}}function $qe(t){const[e,i]=J.useState(`${window.location.origin}${bwe}`),[n,r]=J.useState(void 0),[o,a]=J.useState(Uqe),[s,l]=J.useState(zqe),[u,c]=J.useState(!0),d=J.useCallback(g=>{a(v=>({...v,...g}))},[]),f=J.useCallback(async(g,v)=>{c(!0),r(void 0);try{const y=await fetch(`${g}/environment`),m=await y.json();if(!y.ok)throw new Error(`Failed to fetch environment: ${y.status}`);if(!m.workspace||!m.broker_url)throw new Error("Incorrect environment data received from backend");a(S=>({...S}));const b=Array.isArray(m.versions)?m.versions:[];r({brokerUrl:m.broker_url,studioBackendUrl:g,workspace:m.workspace,authMode:m.auth_mode,versions:[...b,{name:"RemotiveStudio",version:Vqe}]}),c(!1)}catch(y){throw v?await f(v):c(!1),y}},[]),h=J.useCallback(g=>{g.showHiddenFiles!==void 0&&localStorage.setItem("SHOW_HIDDEN_FILES_PREFERENCES",g.showHiddenFiles.toString()),l(v=>({...v,...g}))},[]);if(J.useEffect(()=>{const g=document.getElementById(Hqe);g&&(u?(g.style.display="flex",g.style.animation="",g.style.opacity="1"):(g.style.animation="initial-splash-fade-out 0.4s ease forwards",g.addEventListener("animationend",()=>{g.style.display="none"},{once:!0})))},[u]),J.useEffect(()=>{f(e).catch(async g=>{f(Bqe).catch(v=>{})})},[]),u)return null;if(!n)return L.jsx("div",{className:Hr("h-full flex flex-col items-center justify-center text-muted-foreground"),children:L.jsx("p",{className:"text-sm",children:"RemotiveStudio not running."})});const p={settings:o,preferences:s,updateSettings:d,environment:n,updateEnvironment:f,updatePreferences:h};return L.jsx(mwe.Provider,{value:p,children:t.children})}function Lp(){const t=J.useContext(mwe);if(!t)throw new Error("useSettings must be used within a SettingsProvider");return t}const Wqe={route:Nu.OVERVIEW,title:"Overview",contextId:qs.OVERVIEW,icon:Xi.CONTEXT_HOME,component:Gqe};function Gqe(){const t=qt.c(6),{environment:e}=Lp(),i=qqe,n=Yqe,r=`${e.workspace}`;let o;t[0]!==r?(o=L.jsx(LP,{title:"Welcome to RemotiveStudio",description:L.jsxs(L.Fragment,{children:["Your current workspace is"," ",L.jsx("span",{className:"font-bold break-all",children:r})]})}),t[0]=r,t[1]=o):o=t[1];let a;t[2]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx("section",{className:"mb-10",children:i()}),t[2]=a):a=t[2];let s;t[3]===Symbol.for("react.memo_cache_sentinel")?(s=L.jsxs(LS,{children:[a,L.jsx("section",{className:"mb-10",children:n()})]}),t[3]=s):s=t[3];let l;return t[4]!==o?(l=L.jsxs(MS,{children:[o,s]}),t[4]=o,t[5]=l):l=t[5],l}function Yqe(){return L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-foreground mb-4",children:"Quick Links"}),L.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4",children:[L.jsx(e8,{title:"Documentation",description:"Learn how to use RemotiveStudio",iconType:dr.CONTENT_BOOK,href:"https://docs.remotivelabs.com"}),L.jsx(e8,{title:"Jupyter Notebooks",description:"Interact with your running topology",iconType:dr.CONTENT_NOTEBOOK,href:"https://jupyter.org/"}),L.jsx(e8,{title:"EdgeShark",description:"Capture network packets from your running topology",iconType:dr.OBJECT_WAVES,href:"https://edgeshark.siemens.io"})]})]})}function qqe(){return L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-foreground mb-4",children:"Getting Started"}),L.jsxs("div",{className:"rounded-2xl border border-border bg-card py-3 space-y-1",children:[L.jsx(zoe,{title:"Signal data playback",description:"Locally playback signal data from a recording session",link:"https://docs.remotivelabs.com/docs/remotive-topology/usage/recordings/usage"}),L.jsx(zoe,{title:"Instantiate & run your own topology",description:"Get up and running in minutes on your local machine",link:"https://docs.remotivelabs.com/docs/remotive-topology/usage/instance"})]})]})}var Ef=(t=>(t.UNKNOWN="FILE_TYPE_UNKNOWN",t.FOLDER="FILE_TYPE_FOLDER",t.VIDEO="FILE_TYPE_VIDEO",t.AUDIO="FILE_TYPE_AUDIO",t.IMAGE="FILE_TYPE_IMAGE",t.RECORDING="FILE_TYPE_RECORDING",t.RECORDING_SESSION="FILE_TYPE_RECORDING_SESSION",t.RECORDING_MAPPING="FILE_TYPE_RECORDING_MAPPING",t.PLATFORM="FILE_TYPE_PLATFORM",t.INSTANCE="FILE_TYPE_INSTANCE",t.TEXT="FILE_TYPE_TEXT",t.SIGNAL_DATABASE="FILE_TYPE_SIGNAL_DATABASE",t.DASHBOARD="FILE_TYPE_DASHBOARD",t))(Ef||{});function Xqe(t){const e=t.lastIndexOf(".");if(!(e===-1||e===0))return t.slice(e)}const _we=new Set(["FILE_TYPE_PLATFORM","FILE_TYPE_SIGNAL_DATABASE"]),Pwe=new Set(["FILE_TYPE_INSTANCE"]),Cwe=new Set(["FILE_TYPE_DASHBOARD"]),hQ=new Set(["FILE_TYPE_VIDEO"]),pQ=new Set(["FILE_TYPE_AUDIO"]),gQ=new Set(["FILE_TYPE_IMAGE"]),Twe=new Set(["FILE_TYPE_RECORDING","FILE_TYPE_RECORDING_SESSION","FILE_TYPE_RECORDING_MAPPING","FILE_TYPE_PLATFORM","FILE_TYPE_INSTANCE","FILE_TYPE_SIGNAL_DATABASE","FILE_TYPE_DASHBOARD","FILE_TYPE_TEXT"]),Kqe=["unsupported","text","platform","instance","signal-database","dashboard","image","video","audio"];function Zqe(t,e){return t&&Kqe.includes(t)?t:Qqe(e)}function Jqe(t){return t&&Object.values(Ef).includes(t)?t:void 0}function Qqe(t){return t?hQ.has(t)?"video":pQ.has(t)?"audio":gQ.has(t)?"image":_we.has(t)?"platform":Pwe.has(t)?"instance":Cwe.has(t)?"dashboard":Twe.has(t)?"text":"unsupported":"unsupported"}const e9e={FILE_TYPE_IMAGE:Xi.FILE_IMAGE,FILE_TYPE_VIDEO:Xi.FILE_VIDEO,FILE_TYPE_AUDIO:Xi.FILE_AUDIO,FILE_TYPE_SIGNAL_DATABASE:Xi.FILE_DATABASE,FILE_TYPE_PLATFORM:Xi.FILE_PLATFORM,FILE_TYPE_INSTANCE:Xi.FILE_INSTANCE,FILE_TYPE_RECORDING:Xi.FILE_RECORDING,FILE_TYPE_RECORDING_SESSION:Xi.FILE_RECORDING,FILE_TYPE_RECORDING_MAPPING:Xi.FILE_RECORDING,FILE_TYPE_DASHBOARD:Xi.FILE_DASHBOARD,FILE_TYPE_UNKNOWN:Xi.FILE_GENERIC},t9e={".py":Xi.FILE_CODE,".ipynb":Xi.FILE_CODE,".json":Xi.FILE_JSON,".yaml":Xi.FILE_JSON,".yml":Xi.FILE_JSON};function r9e(t){var i;if(t.type==="folder")return Xi.FOLDER_CLOSED;if(t.fileType){const n=e9e[t.fileType];if(n)return n}const e=(i=t.extension)==null?void 0:i.toLowerCase();if(e){const n=t9e[e];if(n)return n}return Xi.FILE_GENERIC}function i9e(t){return dV(r9e(t))}class xwe{constructor(e,i=2e4){Go(this,"baseUrl");Go(this,"timeoutMs");this.baseUrl=e.endsWith("/")?e.slice(0,-1):e,this.timeoutMs=i}async fetchWithTimeout(e,i){const n=new AbortController,r=setTimeout(()=>n.abort(),this.timeoutMs);try{return await fetch(e,{...i,signal:n.signal})}catch(o){throw o instanceof Error&&o.name==="AbortError"?new Error("Request timed out"):o}finally{clearTimeout(r)}}async getDirectoryContents(e,i=!1){const n=new URL(`${this.baseUrl}/files`);n.searchParams.set("path",e),n.searchParams.set("include_hidden",i.toString());const r=await this.fetchWithTimeout(n.toString());if(!r.ok)throw new Error(`Failed to list files at ${e}: ${r.status}`);return(await r.json()).files.map(s=>{const l=s.path.split("/").pop()||s.path,u=this.getExtension(l);return s.type===Ef.FOLDER?{id:s.path,name:l,path:s.path,type:"folder",children:void 0,fileType:Ef.FOLDER}:{id:s.path,name:l,path:s.path,type:"file",extension:u,fileType:s.type}}).sort((s,l)=>s.type==="folder"&&l.type==="file"?-1:s.type==="file"&&l.type==="folder"?1:s.name.localeCompare(l.name))}async getFileMetadata(e){try{const i=e.lastIndexOf("/"),n=i>0?e.substring(0,i):"/",r=new URL(`${this.baseUrl}/files`);r.searchParams.set("path",n),r.searchParams.set("include_hidden","false");const o=await this.fetchWithTimeout(r.toString());if(!o.ok)return console.error(`Failed to list files at ${n}: ${o.status}`),null;const s=(await o.json()).files.find(l=>l.path===e);return s?{path:s.path,fileType:s.type}:(console.error(`File not found in directory listing: ${e}`),null)}catch(i){return console.error(`Error getting file metadata for ${e}:`,i),null}}async getFileContent(e){try{const i=new URL(`${this.baseUrl}/files/download`);i.searchParams.set("path",e);const n=await this.fetchWithTimeout(i.toString());if(!n.ok)throw console.error(`Failed to fetch file: ${n.status}`),new Error(`Failed to fetch file: ${n.status}`);return await n.text()}catch(i){throw console.error("Error loading file content:",i),i}}async uploadAsFile(e,i){try{const n=new URL(`${this.baseUrl}/files/upload`);n.searchParams.set("path",e);const r=await this.fetchWithTimeout(n.toString(),{method:"PUT",body:i});if(!r.ok)throw console.error(`Failed to upload file: ${r.status}`),new Error(`Failed to upload file: ${r.status}`);return}catch(n){throw console.error("Error loading file content:",n),n}}getFileUrl(e){const i=new URL(`${this.baseUrl}/files/download`);return i.searchParams.set("path",e),i.toString()}async getResolvedPlatform(e){const i=new URL(`${this.baseUrl}/files/platform`);return i.searchParams.set("path",e),this.callApi(i,"resolve platform")}async getResolvedInstance(e){const i=new URL(`${this.baseUrl}/files/instance`);return i.searchParams.set("path",e),this.callApi(i,"resolve instance")}async callApi(e,i){const n=await this.fetchWithTimeout(e.toString());if(n.ok)return n.text();const r=await n.json();if(r.detail){if(typeof r.detail=="string")throw new Error(r.detail);if(typeof r.detail=="object"&&typeof r.detail.message=="string")throw new Error(r.detail.message);if(Array.isArray(r.detail))throw new Error(r.detail.map(o=>o.msg||"").join(", "))}throw new Error(n.statusText||`Failed to ${i}`)}getExtension(e){const i=e.lastIndexOf(".");if(!(i===-1||i===0))return e.slice(i)}}function B$(){const t=qt.c(4),{environment:e}=Lp();let i;t[0]!==e.studioBackendUrl?(i=new xwe(e.studioBackendUrl),t[0]=e.studioBackendUrl,t[1]=i):i=t[1];const n=i;let r;return t[2]!==n?(r={getDirectoryContents:o=>n.getDirectoryContents(o),getFileContent:o=>n.getFileContent(o),getFileUrl:o=>n.getFileUrl(o),getFileMetadata:o=>n.getFileMetadata(o),getResolvedPlatform:o=>n.getResolvedPlatform(o),getResolvedInstance:o=>n.getResolvedInstance(o),uploadAsFile:(o,a)=>n.uploadAsFile(o,a)},t[2]=n,t[3]=r):r=t[3],r}var cI=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},n9e={setTimeout:(t,e)=>setTimeout(t,e),clearTimeout:t=>clearTimeout(t),setInterval:(t,e)=>setInterval(t,e),clearInterval:t=>clearInterval(t)},X_,NJ,Jxe,o9e=(Jxe=class{constructor(){bi(this,X_,n9e);bi(this,NJ,!1)}setTimeoutProvider(t){Xr(this,X_,t)}setTimeout(t,e){return At(this,X_).setTimeout(t,e)}clearTimeout(t){At(this,X_).clearTimeout(t)}setInterval(t,e){return At(this,X_).setInterval(t,e)}clearInterval(t){At(this,X_).clearInterval(t)}},X_=new WeakMap,NJ=new WeakMap,Jxe),zO=new o9e;function a9e(t){setTimeout(t,0)}var SD=typeof window>"u"||"Deno"in globalThis;function wf(){}function s9e(t,e){return typeof t=="function"?t(e):t}function yX(t){return typeof t=="number"&&t>=0&&t!==1/0}function Ewe(t,e){return Math.max(t+(e||0)-Date.now(),0)}function pP(t,e){return typeof t=="function"?t(e):t}function Sg(t,e){return typeof t=="function"?t(e):t}function $oe(t,e){const{type:i="all",exact:n,fetchStatus:r,predicate:o,queryKey:a,stale:s}=t;if(a){if(n){if(e.queryHash!==vQ(a,e.options))return!1}else if(!Yj(e.queryKey,a))return!1}if(i!=="all"){const l=e.isActive();if(i==="active"&&!l||i==="inactive"&&l)return!1}return!(typeof s=="boolean"&&e.isStale()!==s||r&&r!==e.state.fetchStatus||o&&!o(e))}function Woe(t,e){const{exact:i,status:n,predicate:r,mutationKey:o}=t;if(o){if(!e.options.mutationKey)return!1;if(i){if(Gj(e.options.mutationKey)!==Gj(o))return!1}else if(!Yj(e.options.mutationKey,o))return!1}return!(n&&e.state.status!==n||r&&!r(e))}function vQ(t,e){return((e==null?void 0:e.queryKeyHashFn)||Gj)(t)}function Gj(t){return JSON.stringify(t,(e,i)=>mX(i)?Object.keys(i).sort().reduce((n,r)=>(n[r]=i[r],n),{}):i)}function Yj(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?Object.keys(e).every(i=>Yj(t[i],e[i])):!1}var l9e=Object.prototype.hasOwnProperty;function yQ(t,e,i=0){if(t===e)return t;if(i>500)return e;const n=Goe(t)&&Goe(e);if(!n&&!(mX(t)&&mX(e)))return e;const o=(n?t:Object.keys(t)).length,a=n?e:Object.keys(e),s=a.length,l=n?new Array(s):{};let u=0;for(let c=0;c<s;c++){const d=n?c:a[c],f=t[d],h=e[d];if(f===h){l[d]=f,(n?c<o:l9e.call(t,d))&&u++;continue}if(f===null||h===null||typeof f!="object"||typeof h!="object"){l[d]=h;continue}const p=yQ(f,h,i+1);l[d]=p,p===f&&u++}return o===s&&u===o?t:l}function _5(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const i in t)if(t[i]!==e[i])return!1;return!0}function Goe(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function mX(t){if(!Yoe(t))return!1;const e=t.constructor;if(e===void 0)return!0;const i=e.prototype;return!(!Yoe(i)||!i.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function Yoe(t){return Object.prototype.toString.call(t)==="[object Object]"}function u9e(t){return new Promise(e=>{zO.setTimeout(e,t)})}function bX(t,e,i){return typeof i.structuralSharing=="function"?i.structuralSharing(t,e):i.structuralSharing!==!1?yQ(t,e):e}function c9e(t,e,i=0){const n=[...t,e];return i&&n.length>i?n.slice(1):n}function d9e(t,e,i=0){const n=[e,...t];return i&&n.length>i?n.slice(0,-1):n}var mQ=Symbol();function wwe(t,e){return!t.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!t.queryFn||t.queryFn===mQ?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}function Awe(t,e){return typeof t=="function"?t(...e):!!t}function f9e(t,e,i){let n=!1,r;return Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(r??(r=e()),n||(n=!0,r.aborted?i():r.addEventListener("abort",i,{once:!0})),r)}),t}var KO,K_,ek,Qxe,h9e=(Qxe=class extends cI{constructor(){super();bi(this,KO);bi(this,K_);bi(this,ek);Xr(this,ek,e=>{if(!SD&&window.addEventListener){const i=()=>e();return window.addEventListener("visibilitychange",i,!1),()=>{window.removeEventListener("visibilitychange",i)}}})}onSubscribe(){At(this,K_)||this.setEventListener(At(this,ek))}onUnsubscribe(){var e;this.hasListeners()||((e=At(this,K_))==null||e.call(this),Xr(this,K_,void 0))}setEventListener(e){var i;Xr(this,ek,e),(i=At(this,K_))==null||i.call(this),Xr(this,K_,e(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(e){At(this,KO)!==e&&(Xr(this,KO,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(i=>{i(e)})}isFocused(){var e;return typeof At(this,KO)=="boolean"?At(this,KO):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},KO=new WeakMap,K_=new WeakMap,ek=new WeakMap,Qxe),bQ=new h9e;function SX(){let t,e;const i=new Promise((r,o)=>{t=r,e=o});i.status="pending",i.catch(()=>{});function n(r){Object.assign(i,r),delete i.resolve,delete i.reject}return i.resolve=r=>{n({status:"fulfilled",value:r}),t(r)},i.reject=r=>{n({status:"rejected",reason:r}),e(r)},i}var p9e=a9e;function g9e(){let t=[],e=0,i=s=>{s()},n=s=>{s()},r=p9e;const o=s=>{e?t.push(s):r(()=>{i(s)})},a=()=>{const s=t;t=[],s.length&&r(()=>{n(()=>{s.forEach(l=>{i(l)})})})};return{batch:s=>{let l;e++;try{l=s()}finally{e--,e||a()}return l},batchCalls:s=>(...l)=>{o(()=>{s(...l)})},schedule:o,setNotifyFunction:s=>{i=s},setBatchNotifyFunction:s=>{n=s},setScheduler:s=>{r=s}}}var Ru=g9e(),tk,Z_,rk,eEe,v9e=(eEe=class extends cI{constructor(){super();bi(this,tk,!0);bi(this,Z_);bi(this,rk);Xr(this,rk,e=>{if(!SD&&window.addEventListener){const i=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",i,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",i),window.removeEventListener("offline",n)}}})}onSubscribe(){At(this,Z_)||this.setEventListener(At(this,rk))}onUnsubscribe(){var e;this.hasListeners()||((e=At(this,Z_))==null||e.call(this),Xr(this,Z_,void 0))}setEventListener(e){var i;Xr(this,rk,e),(i=At(this,Z_))==null||i.call(this),Xr(this,Z_,e(this.setOnline.bind(this)))}setOnline(e){At(this,tk)!==e&&(Xr(this,tk,e),this.listeners.forEach(n=>{n(e)}))}isOnline(){return At(this,tk)}},tk=new WeakMap,Z_=new WeakMap,rk=new WeakMap,eEe),P5=new v9e;function y9e(t){return Math.min(1e3*2**t,3e4)}function Owe(t){return(t??"online")==="online"?P5.isOnline():!0}var _X=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function Dwe(t){let e=!1,i=0,n;const r=SX(),o=()=>r.status!=="pending",a=g=>{var v;if(!o()){const y=new _X(g);f(y),(v=t.onCancel)==null||v.call(t,y)}},s=()=>{e=!0},l=()=>{e=!1},u=()=>bQ.isFocused()&&(t.networkMode==="always"||P5.isOnline())&&t.canRun(),c=()=>Owe(t.networkMode)&&t.canRun(),d=g=>{o()||(n==null||n(),r.resolve(g))},f=g=>{o()||(n==null||n(),r.reject(g))},h=()=>new Promise(g=>{var v;n=y=>{(o()||u())&&g(y)},(v=t.onPause)==null||v.call(t)}).then(()=>{var g;n=void 0,o()||(g=t.onContinue)==null||g.call(t)}),p=()=>{if(o())return;let g;const v=i===0?t.initialPromise:void 0;try{g=v??t.fn()}catch(y){g=Promise.reject(y)}Promise.resolve(g).then(d).catch(y=>{var C;if(o())return;const m=t.retry??(SD?0:3),b=t.retryDelay??y9e,S=typeof b=="function"?b(i,y):b,_=m===!0||typeof m=="number"&&i<m||typeof m=="function"&&m(i,y);if(e||!_){f(y);return}i++,(C=t.onFail)==null||C.call(t,i,y),u9e(S).then(()=>u()?void 0:h()).then(()=>{e?f(y):p()})})};return{promise:r,status:()=>r.status,cancel:a,continue:()=>(n==null||n(),r),cancelRetry:s,continueRetry:l,canStart:c,start:()=>(c()?p():h().then(p),r)}}var ZO,tEe,Rwe=(tEe=class{constructor(){bi(this,ZO)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),yX(this.gcTime)&&Xr(this,ZO,zO.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(SD?1/0:300*1e3))}clearGcTimeout(){At(this,ZO)&&(zO.clearTimeout(At(this,ZO)),Xr(this,ZO,void 0))}},ZO=new WeakMap,tEe),JO,ik,mg,QO,Sc,rV,eD,gv,qb,rEe,m9e=(rEe=class extends Rwe{constructor(e){super();bi(this,gv);bi(this,JO);bi(this,ik);bi(this,mg);bi(this,QO);bi(this,Sc);bi(this,rV);bi(this,eD);Xr(this,eD,!1),Xr(this,rV,e.defaultOptions),this.setOptions(e.options),this.observers=[],Xr(this,QO,e.client),Xr(this,mg,At(this,QO).getQueryCache()),this.queryKey=e.queryKey,this.queryHash=e.queryHash,Xr(this,JO,Xoe(this.options)),this.state=e.state??At(this,JO),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return(e=At(this,Sc))==null?void 0:e.promise}setOptions(e){if(this.options={...At(this,rV),...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const i=Xoe(this.options);i.data!==void 0&&(this.setState(qoe(i.data,i.dataUpdatedAt)),Xr(this,JO,i))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&At(this,mg).remove(this)}setData(e,i){const n=bX(this.state.data,e,this.options);return Cn(this,gv,qb).call(this,{data:n,type:"success",dataUpdatedAt:i==null?void 0:i.updatedAt,manual:i==null?void 0:i.manual}),n}setState(e,i){Cn(this,gv,qb).call(this,{type:"setState",state:e,setStateOptions:i})}cancel(e){var n,r;const i=(n=At(this,Sc))==null?void 0:n.promise;return(r=At(this,Sc))==null||r.cancel(e),i?i.then(wf).catch(wf):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(At(this,JO))}isActive(){return this.observers.some(e=>Sg(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===mQ||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>pP(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!Ewe(this.state.dataUpdatedAt,e)}onFocus(){var i;const e=this.observers.find(n=>n.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(i=At(this,Sc))==null||i.continue()}onOnline(){var i;const e=this.observers.find(n=>n.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(i=At(this,Sc))==null||i.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),At(this,mg).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(i=>i!==e),this.observers.length||(At(this,Sc)&&(At(this,eD)?At(this,Sc).cancel({revert:!0}):At(this,Sc).cancelRetry()),this.scheduleGc()),At(this,mg).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Cn(this,gv,qb).call(this,{type:"invalidate"})}async fetch(e,i){var l,u,c,d,f,h,p,g,v,y,m,b;if(this.state.fetchStatus!=="idle"&&((l=At(this,Sc))==null?void 0:l.status())!=="rejected"){if(this.state.data!==void 0&&(i!=null&&i.cancelRefetch))this.cancel({silent:!0});else if(At(this,Sc))return At(this,Sc).continueRetry(),At(this,Sc).promise}if(e&&this.setOptions(e),!this.options.queryFn){const S=this.observers.find(_=>_.options.queryFn);S&&this.setOptions(S.options)}const n=new AbortController,r=S=>{Object.defineProperty(S,"signal",{enumerable:!0,get:()=>(Xr(this,eD,!0),n.signal)})},o=()=>{const S=wwe(this.options,i),C=(()=>{const P={client:At(this,QO),queryKey:this.queryKey,meta:this.meta};return r(P),P})();return Xr(this,eD,!1),this.options.persister?this.options.persister(S,C,this):S(C)},s=(()=>{const S={fetchOptions:i,options:this.options,queryKey:this.queryKey,client:At(this,QO),state:this.state,fetchFn:o};return r(S),S})();(u=this.options.behavior)==null||u.onFetch(s,this),Xr(this,ik,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=s.fetchOptions)==null?void 0:c.meta))&&Cn(this,gv,qb).call(this,{type:"fetch",meta:(d=s.fetchOptions)==null?void 0:d.meta}),Xr(this,Sc,Dwe({initialPromise:i==null?void 0:i.initialPromise,fn:s.fetchFn,onCancel:S=>{S instanceof _X&&S.revert&&this.setState({...At(this,ik),fetchStatus:"idle"}),n.abort()},onFail:(S,_)=>{Cn(this,gv,qb).call(this,{type:"failed",failureCount:S,error:_})},onPause:()=>{Cn(this,gv,qb).call(this,{type:"pause"})},onContinue:()=>{Cn(this,gv,qb).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0}));try{const S=await At(this,Sc).start();if(S===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(S),(h=(f=At(this,mg).config).onSuccess)==null||h.call(f,S,this),(g=(p=At(this,mg).config).onSettled)==null||g.call(p,S,this.state.error,this),S}catch(S){if(S instanceof _X){if(S.silent)return At(this,Sc).promise;if(S.revert){if(this.state.data===void 0)throw S;return this.state.data}}throw Cn(this,gv,qb).call(this,{type:"error",error:S}),(y=(v=At(this,mg).config).onError)==null||y.call(v,S,this),(b=(m=At(this,mg).config).onSettled)==null||b.call(m,this.state.data,S,this),S}finally{this.scheduleGc()}}},JO=new WeakMap,ik=new WeakMap,mg=new WeakMap,QO=new WeakMap,Sc=new WeakMap,rV=new WeakMap,eD=new WeakMap,gv=new WeakSet,qb=function(e){const i=n=>{switch(e.type){case"failed":return{...n,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...Mwe(n.data,this.options),fetchMeta:e.meta??null};case"success":const r={...n,...qoe(e.data,e.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return Xr(this,ik,e.manual?r:void 0),r;case"error":const o=e.error;return{...n,error:o,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:o,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...e.state}}};this.state=i(this.state),Ru.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),At(this,mg).notify({query:this,type:"updated",action:e})})},rEe);function Mwe(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Owe(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function qoe(t,e){return{data:t,dataUpdatedAt:e??Date.now(),error:null,isInvalidated:!1,status:"success"}}function Xoe(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,i=e!==void 0,n=i?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,dataUpdateCount:0,dataUpdatedAt:i?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:i?"success":"pending",fetchStatus:"idle"}}var Ph,Do,iV,xf,tD,nk,eS,J_,nV,ok,ak,rD,iD,Q_,sk,Pa,ij,PX,CX,TX,xX,EX,wX,AX,Lwe,iEe,SQ=(iEe=class extends cI{constructor(e,i){super();bi(this,Pa);bi(this,Ph);bi(this,Do);bi(this,iV);bi(this,xf);bi(this,tD);bi(this,nk);bi(this,eS);bi(this,J_);bi(this,nV);bi(this,ok);bi(this,ak);bi(this,rD);bi(this,iD);bi(this,Q_);bi(this,sk,new Set);this.options=i,Xr(this,Ph,e),Xr(this,J_,null),Xr(this,eS,SX()),this.bindMethods(),this.setOptions(i)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(At(this,Do).addObserver(this),Koe(At(this,Do),this.options)?Cn(this,Pa,ij).call(this):this.updateResult(),Cn(this,Pa,xX).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return OX(At(this,Do),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return OX(At(this,Do),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Cn(this,Pa,EX).call(this),Cn(this,Pa,wX).call(this),At(this,Do).removeObserver(this)}setOptions(e){const i=this.options,n=At(this,Do);if(this.options=At(this,Ph).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Sg(this.options.enabled,At(this,Do))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Cn(this,Pa,AX).call(this),At(this,Do).setOptions(this.options),i._defaulted&&!_5(this.options,i)&&At(this,Ph).getQueryCache().notify({type:"observerOptionsUpdated",query:At(this,Do),observer:this});const r=this.hasListeners();r&&Zoe(At(this,Do),n,this.options,i)&&Cn(this,Pa,ij).call(this),this.updateResult(),r&&(At(this,Do)!==n||Sg(this.options.enabled,At(this,Do))!==Sg(i.enabled,At(this,Do))||pP(this.options.staleTime,At(this,Do))!==pP(i.staleTime,At(this,Do)))&&Cn(this,Pa,PX).call(this);const o=Cn(this,Pa,CX).call(this);r&&(At(this,Do)!==n||Sg(this.options.enabled,At(this,Do))!==Sg(i.enabled,At(this,Do))||o!==At(this,Q_))&&Cn(this,Pa,TX).call(this,o)}getOptimisticResult(e){const i=At(this,Ph).getQueryCache().build(At(this,Ph),e),n=this.createResult(i,e);return S9e(this,n)&&(Xr(this,xf,n),Xr(this,nk,this.options),Xr(this,tD,At(this,Do).state)),n}getCurrentResult(){return At(this,xf)}trackResult(e,i){return new Proxy(e,{get:(n,r)=>(this.trackProp(r),i==null||i(r),r==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&At(this,eS).status==="pending"&&At(this,eS).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,r))})}trackProp(e){At(this,sk).add(e)}getCurrentQuery(){return At(this,Do)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const i=At(this,Ph).defaultQueryOptions(e),n=At(this,Ph).getQueryCache().build(At(this,Ph),i);return n.fetch().then(()=>this.createResult(n,i))}fetch(e){return Cn(this,Pa,ij).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),At(this,xf)))}createResult(e,i){var E;const n=At(this,Do),r=this.options,o=At(this,xf),a=At(this,tD),s=At(this,nk),u=e!==n?e.state:At(this,iV),{state:c}=e;let d={...c},f=!1,h;if(i._optimisticResults){const A=this.hasListeners(),R=!A&&Koe(e,i),M=A&&Zoe(e,n,i,r);(R||M)&&(d={...d,...Mwe(c.data,e.options)}),i._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:p,errorUpdatedAt:g,status:v}=d;h=d.data;let y=!1;if(i.placeholderData!==void 0&&h===void 0&&v==="pending"){let A;o!=null&&o.isPlaceholderData&&i.placeholderData===(s==null?void 0:s.placeholderData)?(A=o.data,y=!0):A=typeof i.placeholderData=="function"?i.placeholderData((E=At(this,ak))==null?void 0:E.state.data,At(this,ak)):i.placeholderData,A!==void 0&&(v="success",h=bX(o==null?void 0:o.data,A,i),f=!0)}if(i.select&&h!==void 0&&!y)if(o&&h===(a==null?void 0:a.data)&&i.select===At(this,nV))h=At(this,ok);else try{Xr(this,nV,i.select),h=i.select(h),h=bX(o==null?void 0:o.data,h,i),Xr(this,ok,h),Xr(this,J_,null)}catch(A){Xr(this,J_,A)}At(this,J_)&&(p=At(this,J_),h=At(this,ok),g=Date.now(),v="error");const m=d.fetchStatus==="fetching",b=v==="pending",S=v==="error",_=b&&m,C=h!==void 0,x={status:v,fetchStatus:d.fetchStatus,isPending:b,isSuccess:v==="success",isError:S,isInitialLoading:_,isLoading:_,data:h,dataUpdatedAt:d.dataUpdatedAt,error:p,errorUpdatedAt:g,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>u.dataUpdateCount||d.errorUpdateCount>u.errorUpdateCount,isFetching:m,isRefetching:m&&!b,isLoadingError:S&&!C,isPaused:d.fetchStatus==="paused",isPlaceholderData:f,isRefetchError:S&&C,isStale:_Q(e,i),refetch:this.refetch,promise:At(this,eS),isEnabled:Sg(i.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const A=x.data!==void 0,R=x.status==="error"&&!A,M=I=>{R?I.reject(x.error):A&&I.resolve(x.data)},D=()=>{const I=Xr(this,eS,x.promise=SX());M(I)},F=At(this,eS);switch(F.status){case"pending":e.queryHash===n.queryHash&&M(F);break;case"fulfilled":(R||x.data!==F.value)&&D();break;case"rejected":(!R||x.error!==F.reason)&&D();break}}return x}updateResult(){const e=At(this,xf),i=this.createResult(At(this,Do),this.options);if(Xr(this,tD,At(this,Do).state),Xr(this,nk,this.options),At(this,tD).data!==void 0&&Xr(this,ak,At(this,Do)),_5(i,e))return;Xr(this,xf,i);const n=()=>{if(!e)return!0;const{notifyOnChangeProps:r}=this.options,o=typeof r=="function"?r():r;if(o==="all"||!o&&!At(this,sk).size)return!0;const a=new Set(o??At(this,sk));return this.options.throwOnError&&a.add("error"),Object.keys(At(this,xf)).some(s=>{const l=s;return At(this,xf)[l]!==e[l]&&a.has(l)})};Cn(this,Pa,Lwe).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Cn(this,Pa,xX).call(this)}},Ph=new WeakMap,Do=new WeakMap,iV=new WeakMap,xf=new WeakMap,tD=new WeakMap,nk=new WeakMap,eS=new WeakMap,J_=new WeakMap,nV=new WeakMap,ok=new WeakMap,ak=new WeakMap,rD=new WeakMap,iD=new WeakMap,Q_=new WeakMap,sk=new WeakMap,Pa=new WeakSet,ij=function(e){Cn(this,Pa,AX).call(this);let i=At(this,Do).fetch(this.options,e);return e!=null&&e.throwOnError||(i=i.catch(wf)),i},PX=function(){Cn(this,Pa,EX).call(this);const e=pP(this.options.staleTime,At(this,Do));if(SD||At(this,xf).isStale||!yX(e))return;const n=Ewe(At(this,xf).dataUpdatedAt,e)+1;Xr(this,rD,zO.setTimeout(()=>{At(this,xf).isStale||this.updateResult()},n))},CX=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(At(this,Do)):this.options.refetchInterval)??!1},TX=function(e){Cn(this,Pa,wX).call(this),Xr(this,Q_,e),!(SD||Sg(this.options.enabled,At(this,Do))===!1||!yX(At(this,Q_))||At(this,Q_)===0)&&Xr(this,iD,zO.setInterval(()=>{(this.options.refetchIntervalInBackground||bQ.isFocused())&&Cn(this,Pa,ij).call(this)},At(this,Q_)))},xX=function(){Cn(this,Pa,PX).call(this),Cn(this,Pa,TX).call(this,Cn(this,Pa,CX).call(this))},EX=function(){At(this,rD)&&(zO.clearTimeout(At(this,rD)),Xr(this,rD,void 0))},wX=function(){At(this,iD)&&(zO.clearInterval(At(this,iD)),Xr(this,iD,void 0))},AX=function(){const e=At(this,Ph).getQueryCache().build(At(this,Ph),this.options);if(e===At(this,Do))return;const i=At(this,Do);Xr(this,Do,e),Xr(this,iV,e.state),this.hasListeners()&&(i==null||i.removeObserver(this),e.addObserver(this))},Lwe=function(e){Ru.batch(()=>{e.listeners&&this.listeners.forEach(i=>{i(At(this,xf))}),At(this,Ph).getQueryCache().notify({query:At(this,Do),type:"observerResultsUpdated"})})},iEe);function b9e(t,e){return Sg(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function Koe(t,e){return b9e(t,e)||t.state.data!==void 0&&OX(t,e,e.refetchOnMount)}function OX(t,e,i){if(Sg(e.enabled,t)!==!1&&pP(e.staleTime,t)!=="static"){const n=typeof i=="function"?i(t):i;return n==="always"||n!==!1&&_Q(t,e)}return!1}function Zoe(t,e,i,n){return(t!==e||Sg(n.enabled,t)===!1)&&(!i.suspense||t.state.status!=="error")&&_Q(t,i)}function _Q(t,e){return Sg(e.enabled,t)!==!1&&t.isStaleByTime(pP(e.staleTime,t))}function S9e(t,e){return!_5(t.getCurrentResult(),e)}function Joe(t){return{onFetch:(e,i)=>{var c,d,f,h,p;const n=e.options,r=(f=(d=(c=e.fetchOptions)==null?void 0:c.meta)==null?void 0:d.fetchMore)==null?void 0:f.direction,o=((h=e.state.data)==null?void 0:h.pages)||[],a=((p=e.state.data)==null?void 0:p.pageParams)||[];let s={pages:[],pageParams:[]},l=0;const u=async()=>{let g=!1;const v=b=>{f9e(b,()=>e.signal,()=>g=!0)},y=wwe(e.options,e.fetchOptions),m=async(b,S,_)=>{if(g)return Promise.reject();if(S==null&&b.pages.length)return Promise.resolve(b);const P=(()=>{const R={client:e.client,queryKey:e.queryKey,pageParam:S,direction:_?"backward":"forward",meta:e.options.meta};return v(R),R})(),x=await y(P),{maxPages:E}=e.options,A=_?d9e:c9e;return{pages:A(b.pages,x,E),pageParams:A(b.pageParams,S,E)}};if(r&&o.length){const b=r==="backward",S=b?_9e:Qoe,_={pages:o,pageParams:a},C=S(n,_);s=await m(_,C,b)}else{const b=t??o.length;do{const S=l===0?a[0]??n.initialPageParam:Qoe(n,s);if(l>0&&S==null)break;s=await m(s,S),l++}while(l<b)}return s};e.options.persister?e.fetchFn=()=>{var g,v;return(v=(g=e.options).persister)==null?void 0:v.call(g,u,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},i)}:e.fetchFn=u}}}function Qoe(t,{pages:e,pageParams:i}){const n=e.length-1;return e.length>0?t.getNextPageParam(e[n],e,i[n],i):void 0}function _9e(t,{pages:e,pageParams:i}){var n;return e.length>0?(n=t.getPreviousPageParam)==null?void 0:n.call(t,e[0],e,i[0],i):void 0}var oV,Iy,kd,nD,Ny,j_,nEe,P9e=(nEe=class extends Rwe{constructor(e){super();bi(this,Ny);bi(this,oV);bi(this,Iy);bi(this,kd);bi(this,nD);Xr(this,oV,e.client),this.mutationId=e.mutationId,Xr(this,kd,e.mutationCache),Xr(this,Iy,[]),this.state=e.state||C9e(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){At(this,Iy).includes(e)||(At(this,Iy).push(e),this.clearGcTimeout(),At(this,kd).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){Xr(this,Iy,At(this,Iy).filter(i=>i!==e)),this.scheduleGc(),At(this,kd).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){At(this,Iy).length||(this.state.status==="pending"?this.scheduleGc():At(this,kd).remove(this))}continue(){var e;return((e=At(this,nD))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var a,s,l,u,c,d,f,h,p,g,v,y,m,b,S,_,C,P;const i=()=>{Cn(this,Ny,j_).call(this,{type:"continue"})},n={client:At(this,oV),meta:this.options.meta,mutationKey:this.options.mutationKey};Xr(this,nD,Dwe({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(new Error("No mutationFn found")),onFail:(x,E)=>{Cn(this,Ny,j_).call(this,{type:"failed",failureCount:x,error:E})},onPause:()=>{Cn(this,Ny,j_).call(this,{type:"pause"})},onContinue:i,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>At(this,kd).canRun(this)}));const r=this.state.status==="pending",o=!At(this,nD).canStart();try{if(r)i();else{Cn(this,Ny,j_).call(this,{type:"pending",variables:e,isPaused:o}),At(this,kd).config.onMutate&&await At(this,kd).config.onMutate(e,this,n);const E=await((s=(a=this.options).onMutate)==null?void 0:s.call(a,e,n));E!==this.state.context&&Cn(this,Ny,j_).call(this,{type:"pending",context:E,variables:e,isPaused:o})}const x=await At(this,nD).start();return await((u=(l=At(this,kd).config).onSuccess)==null?void 0:u.call(l,x,e,this.state.context,this,n)),await((d=(c=this.options).onSuccess)==null?void 0:d.call(c,x,e,this.state.context,n)),await((h=(f=At(this,kd).config).onSettled)==null?void 0:h.call(f,x,null,this.state.variables,this.state.context,this,n)),await((g=(p=this.options).onSettled)==null?void 0:g.call(p,x,null,e,this.state.context,n)),Cn(this,Ny,j_).call(this,{type:"success",data:x}),x}catch(x){try{await((y=(v=At(this,kd).config).onError)==null?void 0:y.call(v,x,e,this.state.context,this,n))}catch(E){Promise.reject(E)}try{await((b=(m=this.options).onError)==null?void 0:b.call(m,x,e,this.state.context,n))}catch(E){Promise.reject(E)}try{await((_=(S=At(this,kd).config).onSettled)==null?void 0:_.call(S,void 0,x,this.state.variables,this.state.context,this,n))}catch(E){Promise.reject(E)}try{await((P=(C=this.options).onSettled)==null?void 0:P.call(C,void 0,x,e,this.state.context,n))}catch(E){Promise.reject(E)}throw Cn(this,Ny,j_).call(this,{type:"error",error:x}),x}finally{At(this,kd).runNext(this)}}},oV=new WeakMap,Iy=new WeakMap,kd=new WeakMap,nD=new WeakMap,Ny=new WeakSet,j_=function(e){const i=n=>{switch(e.type){case"failed":return{...n,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...n,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:e.error,failureCount:n.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=i(this.state),Ru.batch(()=>{At(this,Iy).forEach(n=>{n.onMutationUpdate(e)}),At(this,kd).notify({mutation:this,type:"updated",action:e})})},nEe);function C9e(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var tS,vv,aV,oEe,T9e=(oEe=class extends cI{constructor(e={}){super();bi(this,tS);bi(this,vv);bi(this,aV);this.config=e,Xr(this,tS,new Set),Xr(this,vv,new Map),Xr(this,aV,0)}build(e,i,n){const r=new P9e({client:e,mutationCache:this,mutationId:++dH(this,aV)._,options:e.defaultMutationOptions(i),state:n});return this.add(r),r}add(e){At(this,tS).add(e);const i=SH(e);if(typeof i=="string"){const n=At(this,vv).get(i);n?n.push(e):At(this,vv).set(i,[e])}this.notify({type:"added",mutation:e})}remove(e){if(At(this,tS).delete(e)){const i=SH(e);if(typeof i=="string"){const n=At(this,vv).get(i);if(n)if(n.length>1){const r=n.indexOf(e);r!==-1&&n.splice(r,1)}else n[0]===e&&At(this,vv).delete(i)}}this.notify({type:"removed",mutation:e})}canRun(e){const i=SH(e);if(typeof i=="string"){const n=At(this,vv).get(i),r=n==null?void 0:n.find(o=>o.state.status==="pending");return!r||r===e}else return!0}runNext(e){var n;const i=SH(e);if(typeof i=="string"){const r=(n=At(this,vv).get(i))==null?void 0:n.find(o=>o!==e&&o.state.isPaused);return(r==null?void 0:r.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Ru.batch(()=>{At(this,tS).forEach(e=>{this.notify({type:"removed",mutation:e})}),At(this,tS).clear(),At(this,vv).clear()})}getAll(){return Array.from(At(this,tS))}find(e){const i={exact:!0,...e};return this.getAll().find(n=>Woe(i,n))}findAll(e={}){return this.getAll().filter(i=>Woe(e,i))}notify(e){Ru.batch(()=>{this.listeners.forEach(i=>{i(e)})})}resumePausedMutations(){const e=this.getAll().filter(i=>i.state.isPaused);return Ru.batch(()=>Promise.all(e.map(i=>i.continue().catch(wf))))}},tS=new WeakMap,vv=new WeakMap,aV=new WeakMap,oEe);function SH(t){var e;return(e=t.options.scope)==null?void 0:e.id}function eae(t,e){const i=new Set(e);return t.filter(n=>!i.has(n))}function x9e(t,e,i){const n=t.slice(0);return n[e]=i,n}var lk,mp,uk,ck,bg,eP,sV,lV,uV,cV,sd,DX,RX,MX,LX,kX,aEe,E9e=(aEe=class extends cI{constructor(e,i,n){super();bi(this,sd);bi(this,lk);bi(this,mp);bi(this,uk);bi(this,ck);bi(this,bg);bi(this,eP);bi(this,sV);bi(this,lV);bi(this,uV);bi(this,cV,[]);Xr(this,lk,e),Xr(this,ck,n),Xr(this,uk,[]),Xr(this,bg,[]),Xr(this,mp,[]),this.setQueries(i)}onSubscribe(){this.listeners.size===1&&At(this,bg).forEach(e=>{e.subscribe(i=>{Cn(this,sd,LX).call(this,e,i)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,At(this,bg).forEach(e=>{e.destroy()})}setQueries(e,i){Xr(this,uk,e),Xr(this,ck,i),Ru.batch(()=>{const n=At(this,bg),r=Cn(this,sd,MX).call(this,At(this,uk));r.forEach(d=>d.observer.setOptions(d.defaultedQueryOptions));const o=r.map(d=>d.observer),a=o.map(d=>d.getCurrentResult()),s=n.length!==o.length,l=o.some((d,f)=>d!==n[f]),u=s||l,c=u?!0:a.some((d,f)=>{const h=At(this,mp)[f];return!h||!_5(d,h)});!u&&!c||(u&&(Xr(this,cV,r),Xr(this,bg,o)),Xr(this,mp,a),this.hasListeners()&&(u&&(eae(n,o).forEach(d=>{d.destroy()}),eae(o,n).forEach(d=>{d.subscribe(f=>{Cn(this,sd,LX).call(this,d,f)})})),Cn(this,sd,kX).call(this)))})}getCurrentResult(){return At(this,mp)}getQueries(){return At(this,bg).map(e=>e.getCurrentQuery())}getObservers(){return At(this,bg)}getOptimisticResult(e,i){const n=Cn(this,sd,MX).call(this,e),r=n.map(a=>a.observer.getOptimisticResult(a.defaultedQueryOptions)),o=n.map(a=>a.defaultedQueryOptions.queryHash);return[r,a=>Cn(this,sd,RX).call(this,a??r,i,o),()=>Cn(this,sd,DX).call(this,r,n)]}},lk=new WeakMap,mp=new WeakMap,uk=new WeakMap,ck=new WeakMap,bg=new WeakMap,eP=new WeakMap,sV=new WeakMap,lV=new WeakMap,uV=new WeakMap,cV=new WeakMap,sd=new WeakSet,DX=function(e,i){return i.map((n,r)=>{const o=e[r];return n.defaultedQueryOptions.notifyOnChangeProps?o:n.observer.trackResult(o,a=>{i.forEach(s=>{s.observer.trackProp(a)})})})},RX=function(e,i,n){if(i){const r=At(this,uV),o=n!==void 0&&r!==void 0&&(r.length!==n.length||n.some((a,s)=>a!==r[s]));return(!At(this,eP)||At(this,mp)!==At(this,lV)||o||i!==At(this,sV))&&(Xr(this,sV,i),Xr(this,lV,At(this,mp)),n!==void 0&&Xr(this,uV,n),Xr(this,eP,yQ(At(this,eP),i(e)))),At(this,eP)}return e},MX=function(e){const i=new Map;At(this,bg).forEach(r=>{const o=r.options.queryHash;if(!o)return;const a=i.get(o);a?a.push(r):i.set(o,[r])});const n=[];return e.forEach(r=>{var l;const o=At(this,lk).defaultQueryOptions(r),s=((l=i.get(o.queryHash))==null?void 0:l.shift())??new SQ(At(this,lk),o);n.push({defaultedQueryOptions:o,observer:s})}),n},LX=function(e,i){const n=At(this,bg).indexOf(e);n!==-1&&(Xr(this,mp,x9e(At(this,mp),n,i)),Cn(this,sd,kX).call(this))},kX=function(){var e;if(this.hasListeners()){const i=At(this,eP),n=Cn(this,sd,DX).call(this,At(this,mp),At(this,cV)),r=Cn(this,sd,RX).call(this,n,(e=At(this,ck))==null?void 0:e.combine);i!==r&&Ru.batch(()=>{this.listeners.forEach(o=>{o(At(this,mp))})})}},aEe),Fy,sEe,w9e=(sEe=class extends cI{constructor(e={}){super();bi(this,Fy);this.config=e,Xr(this,Fy,new Map)}build(e,i,n){const r=i.queryKey,o=i.queryHash??vQ(r,i);let a=this.get(o);return a||(a=new m9e({client:e,queryKey:r,queryHash:o,options:e.defaultQueryOptions(i),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(a)),a}add(e){At(this,Fy).has(e.queryHash)||(At(this,Fy).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const i=At(this,Fy).get(e.queryHash);i&&(e.destroy(),i===e&&At(this,Fy).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){Ru.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return At(this,Fy).get(e)}getAll(){return[...At(this,Fy).values()]}find(e){const i={exact:!0,...e};return this.getAll().find(n=>$oe(i,n))}findAll(e={}){const i=this.getAll();return Object.keys(e).length>0?i.filter(n=>$oe(e,n)):i}notify(e){Ru.batch(()=>{this.listeners.forEach(i=>{i(e)})})}onFocus(){Ru.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){Ru.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},Fy=new WeakMap,sEe),Il,tP,rP,dk,fk,iP,hk,pk,lEe,A9e=(lEe=class{constructor(t={}){bi(this,Il);bi(this,tP);bi(this,rP);bi(this,dk);bi(this,fk);bi(this,iP);bi(this,hk);bi(this,pk);Xr(this,Il,t.queryCache||new w9e),Xr(this,tP,t.mutationCache||new T9e),Xr(this,rP,t.defaultOptions||{}),Xr(this,dk,new Map),Xr(this,fk,new Map),Xr(this,iP,0)}mount(){dH(this,iP)._++,At(this,iP)===1&&(Xr(this,hk,bQ.subscribe(async t=>{t&&(await this.resumePausedMutations(),At(this,Il).onFocus())})),Xr(this,pk,P5.subscribe(async t=>{t&&(await this.resumePausedMutations(),At(this,Il).onOnline())})))}unmount(){var t,e;dH(this,iP)._--,At(this,iP)===0&&((t=At(this,hk))==null||t.call(this),Xr(this,hk,void 0),(e=At(this,pk))==null||e.call(this),Xr(this,pk,void 0))}isFetching(t){return At(this,Il).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return At(this,tP).findAll({...t,status:"pending"}).length}getQueryData(t){var i;const e=this.defaultQueryOptions({queryKey:t});return(i=At(this,Il).get(e.queryHash))==null?void 0:i.state.data}ensureQueryData(t){const e=this.defaultQueryOptions(t),i=At(this,Il).build(this,e),n=i.state.data;return n===void 0?this.fetchQuery(t):(t.revalidateIfStale&&i.isStaleByTime(pP(e.staleTime,i))&&this.prefetchQuery(e),Promise.resolve(n))}getQueriesData(t){return At(this,Il).findAll(t).map(({queryKey:e,state:i})=>{const n=i.data;return[e,n]})}setQueryData(t,e,i){const n=this.defaultQueryOptions({queryKey:t}),r=At(this,Il).get(n.queryHash),o=r==null?void 0:r.state.data,a=s9e(e,o);if(a!==void 0)return At(this,Il).build(this,n).setData(a,{...i,manual:!0})}setQueriesData(t,e,i){return Ru.batch(()=>At(this,Il).findAll(t).map(({queryKey:n})=>[n,this.setQueryData(n,e,i)]))}getQueryState(t){var i;const e=this.defaultQueryOptions({queryKey:t});return(i=At(this,Il).get(e.queryHash))==null?void 0:i.state}removeQueries(t){const e=At(this,Il);Ru.batch(()=>{e.findAll(t).forEach(i=>{e.remove(i)})})}resetQueries(t,e){const i=At(this,Il);return Ru.batch(()=>(i.findAll(t).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...t},e)))}cancelQueries(t,e={}){const i={revert:!0,...e},n=Ru.batch(()=>At(this,Il).findAll(t).map(r=>r.cancel(i)));return Promise.all(n).then(wf).catch(wf)}invalidateQueries(t,e={}){return Ru.batch(()=>(At(this,Il).findAll(t).forEach(i=>{i.invalidate()}),(t==null?void 0:t.refetchType)==="none"?Promise.resolve():this.refetchQueries({...t,type:(t==null?void 0:t.refetchType)??(t==null?void 0:t.type)??"active"},e)))}refetchQueries(t,e={}){const i={...e,cancelRefetch:e.cancelRefetch??!0},n=Ru.batch(()=>At(this,Il).findAll(t).filter(r=>!r.isDisabled()&&!r.isStatic()).map(r=>{let o=r.fetch(void 0,i);return i.throwOnError||(o=o.catch(wf)),r.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(n).then(wf)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const i=At(this,Il).build(this,e);return i.isStaleByTime(pP(e.staleTime,i))?i.fetch(e):Promise.resolve(i.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(wf).catch(wf)}fetchInfiniteQuery(t){return t.behavior=Joe(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(wf).catch(wf)}ensureInfiniteQueryData(t){return t.behavior=Joe(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return P5.isOnline()?At(this,tP).resumePausedMutations():Promise.resolve()}getQueryCache(){return At(this,Il)}getMutationCache(){return At(this,tP)}getDefaultOptions(){return At(this,rP)}setDefaultOptions(t){Xr(this,rP,t)}setQueryDefaults(t,e){At(this,dk).set(Gj(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...At(this,dk).values()],i={};return e.forEach(n=>{Yj(t,n.queryKey)&&Object.assign(i,n.defaultOptions)}),i}setMutationDefaults(t,e){At(this,fk).set(Gj(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...At(this,fk).values()],i={};return e.forEach(n=>{Yj(t,n.mutationKey)&&Object.assign(i,n.defaultOptions)}),i}defaultQueryOptions(t){if(t._defaulted)return t;const e={...At(this,rP).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=vQ(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===mQ&&(e.enabled=!1),e}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...At(this,rP).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){At(this,Il).clear(),At(this,tP).clear()}},Il=new WeakMap,tP=new WeakMap,rP=new WeakMap,dk=new WeakMap,fk=new WeakMap,iP=new WeakMap,hk=new WeakMap,pk=new WeakMap,lEe),kwe=J.createContext(void 0),PQ=t=>{const e=J.useContext(kwe);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},O9e=({client:t,children:e})=>(J.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),L.jsx(kwe.Provider,{value:t,children:e})),Iwe=J.createContext(!1),Nwe=()=>J.useContext(Iwe);Iwe.Provider;function D9e(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var R9e=J.createContext(D9e()),Fwe=()=>J.useContext(R9e),Bwe=(t,e,i)=>{const n=i!=null&&i.state.error&&typeof t.throwOnError=="function"?Awe(t.throwOnError,[i.state.error,i]):t.throwOnError;(t.suspense||t.experimental_prefetchInRender||n)&&(e.isReset()||(t.retryOnMount=!1))},jwe=t=>{J.useEffect(()=>{t.clearReset()},[t])},Vwe=({result:t,errorResetBoundary:e,throwOnError:i,query:n,suspense:r})=>t.isError&&!e.isReset()&&!t.isFetching&&n&&(r&&t.data===void 0||Awe(i,[t.error,n])),Hwe=t=>{if(t.suspense){const i=r=>r==="static"?r:Math.max(r??1e3,1e3),n=t.staleTime;t.staleTime=typeof n=="function"?(...r)=>i(n(...r)):i(n),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3))}},Uwe=(t,e)=>t.isLoading&&t.isFetching&&!e,IX=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,C5=(t,e,i)=>e.fetchOptimistic(t).catch(()=>{i.clearReset()});function M9e({queries:t,...e},i){const n=PQ(),r=Nwe(),o=Fwe(),a=J.useMemo(()=>t.map(g=>{const v=n.defaultQueryOptions(g);return v._optimisticResults=r?"isRestoring":"optimistic",v}),[t,n,r]);a.forEach(g=>{Hwe(g);const v=n.getQueryCache().get(g.queryHash);Bwe(g,o,v)}),jwe(o);const[s]=J.useState(()=>new E9e(n,a,e)),[l,u,c]=s.getOptimisticResult(a,e.combine),d=!r&&e.subscribed!==!1;J.useSyncExternalStore(J.useCallback(g=>d?s.subscribe(Ru.batchCalls(g)):wf,[s,d]),()=>s.getCurrentResult(),()=>s.getCurrentResult()),J.useEffect(()=>{s.setQueries(a,e)},[a,e,s]);const h=l.some((g,v)=>IX(a[v],g))?l.flatMap((g,v)=>{const y=a[v];if(y){const m=new SQ(n,y);if(IX(y,g))return C5(y,m,o);Uwe(g,r)&&C5(y,m,o)}return[]}):[];if(h.length>0)throw Promise.all(h);const p=l.find((g,v)=>{const y=a[v];return y&&Vwe({result:g,errorResetBoundary:o,throwOnError:y.throwOnError,query:n.getQueryCache().get(y.queryHash),suspense:y.suspense})});if(p!=null&&p.error)throw p.error;return u(c())}function L9e(t,e,i){var f,h,p,g;const n=Nwe(),r=Fwe(),o=PQ(),a=o.defaultQueryOptions(t);(h=(f=o.getDefaultOptions().queries)==null?void 0:f._experimental_beforeQuery)==null||h.call(f,a);const s=o.getQueryCache().get(a.queryHash);a._optimisticResults=n?"isRestoring":"optimistic",Hwe(a),Bwe(a,r,s),jwe(r);const l=!o.getQueryCache().get(a.queryHash),[u]=J.useState(()=>new e(o,a)),c=u.getOptimisticResult(a),d=!n&&t.subscribed!==!1;if(J.useSyncExternalStore(J.useCallback(v=>{const y=d?u.subscribe(Ru.batchCalls(v)):wf;return u.updateResult(),y},[u,d]),()=>u.getCurrentResult(),()=>u.getCurrentResult()),J.useEffect(()=>{u.setOptions(a)},[a,u]),IX(a,c))throw C5(a,u,r);if(Vwe({result:c,errorResetBoundary:r,throwOnError:a.throwOnError,query:s,suspense:a.suspense}))throw c.error;if((g=(p=o.getDefaultOptions().queries)==null?void 0:p._experimental_afterQuery)==null||g.call(p,a,c),a.experimental_prefetchInRender&&!SD&&Uwe(c,n)){const v=l?C5(a,u,r):s==null?void 0:s.promise;v==null||v.catch(wf).finally(()=>{u.updateResult()})}return a.notifyOnChangeProps?c:u.trackResult(c)}function k9e(t,e){return L9e(t,SQ)}function I9e(t){if(typeof document>"u")return;let e=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css",e.firstChild?e.insertBefore(i,e.firstChild):e.appendChild(i),i.styleSheet?i.styleSheet.cssText=t:i.appendChild(document.createTextNode(t))}I9e(`:root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
`);var vV=t=>typeof t=="number"&&!isNaN(t),_D=t=>typeof t=="string",PS=t=>typeof t=="function",N9e=t=>_D(t)||vV(t),NX=t=>_D(t)||PS(t)?t:null,F9e=(t,e)=>t===!1||vV(t)&&t>0?t:e,FX=t=>J.isValidElement(t)||_D(t)||PS(t)||vV(t);function B9e(t,e,i=300){let{scrollHeight:n,style:r}=t;requestAnimationFrame(()=>{r.minHeight="initial",r.height=n+"px",r.transition=`all ${i}ms`,requestAnimationFrame(()=>{r.height="0",r.padding="0",r.margin="0",setTimeout(e,i)})})}function j9e({enter:t,exit:e,appendPosition:i=!1,collapse:n=!0,collapseDuration:r=300}){return function({children:o,position:a,preventExitTransition:s,done:l,nodeRef:u,isIn:c,playToast:d}){let f=i?`${t}--${a}`:t,h=i?`${e}--${a}`:e,p=J.useRef(0);return J.useLayoutEffect(()=>{let g=u.current,v=f.split(" "),y=m=>{m.target===u.current&&(d(),g.removeEventListener("animationend",y),g.removeEventListener("animationcancel",y),p.current===0&&m.type!=="animationcancel"&&g.classList.remove(...v))};g.classList.add(...v),g.addEventListener("animationend",y),g.addEventListener("animationcancel",y)},[]),J.useEffect(()=>{let g=u.current,v=()=>{g.removeEventListener("animationend",v),n?B9e(g,l,r):l()};c||(s?v():(p.current=1,g.className+=` ${h}`,g.addEventListener("animationend",v)))},[c]),Wn.createElement(Wn.Fragment,null,o)}}function tae(t,e){return{content:zwe(t.content,t.props),containerId:t.props.containerId,id:t.props.toastId,theme:t.props.theme,type:t.props.type,data:t.props.data||{},isLoading:t.props.isLoading,icon:t.props.icon,reason:t.removalReason,status:e}}function zwe(t,e,i=!1){return J.isValidElement(t)&&!_D(t.type)?J.cloneElement(t,{closeToast:e.closeToast,toastProps:e,data:e.data,isPaused:i}):PS(t)?t({closeToast:e.closeToast,toastProps:e,data:e.data,isPaused:i}):t}function V9e({closeToast:t,theme:e,ariaLabel:i="close"}){return Wn.createElement("button",{className:`Toastify__close-button Toastify__close-button--${e}`,type:"button",onClick:n=>{n.stopPropagation(),t(!0)},"aria-label":i},Wn.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},Wn.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function H9e({delay:t,isRunning:e,closeToast:i,type:n="default",hide:r,className:o,controlledProgress:a,progress:s,rtl:l,isIn:u,theme:c}){let d=r||a&&s===0,f={animationDuration:`${t}ms`,animationPlayState:e?"running":"paused"};a&&(f.transform=`scaleX(${s})`);let h=Rv("Toastify__progress-bar",a?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${c}`,`Toastify__progress-bar--${n}`,{"Toastify__progress-bar--rtl":l}),p=PS(o)?o({rtl:l,type:n,defaultClassName:h}):Rv(h,o),g={[a&&s>=1?"onTransitionEnd":"onAnimationEnd"]:a&&s<1?null:()=>{u&&i()}};return Wn.createElement("div",{className:"Toastify__progress-bar--wrp","data-hidden":d},Wn.createElement("div",{className:`Toastify__progress-bar--bg Toastify__progress-bar-theme--${c} Toastify__progress-bar--${n}`}),Wn.createElement("div",{role:"progressbar","aria-hidden":d?"true":"false","aria-label":"notification timer",className:p,style:f,...g}))}var U9e=1,$we=()=>`${U9e++}`;function z9e(t,e,i){let n=1,r=0,o=[],a=[],s=e,l=new Map,u=new Set,c=m=>(u.add(m),()=>u.delete(m)),d=()=>{a=Array.from(l.values()),u.forEach(m=>m())},f=({containerId:m,toastId:b,updateId:S})=>{let _=m?m!==t:t!==1,C=l.has(b)&&S==null;return _||C},h=(m,b)=>{l.forEach(S=>{var _;(b==null||b===S.props.toastId)&&((_=S.toggle)==null||_.call(S,m))})},p=m=>{var b,S;(S=(b=m.props)==null?void 0:b.onClose)==null||S.call(b,m.removalReason),m.isActive=!1},g=m=>{if(m==null)l.forEach(p);else{let b=l.get(m);b&&p(b)}d()},v=()=>{r-=o.length,o=[]},y=m=>{var b,S;let{toastId:_,updateId:C}=m.props,P=C==null;m.staleId&&l.delete(m.staleId),m.isActive=!0,l.set(_,m),d(),i(tae(m,P?"added":"updated")),P&&((S=(b=m.props).onOpen)==null||S.call(b))};return{id:t,props:s,observe:c,toggle:h,removeToast:g,toasts:l,clearQueue:v,buildToast:(m,b)=>{if(f(b))return;let{toastId:S,updateId:_,data:C,staleId:P,delay:x}=b,E=_==null;E&&r++;let A={...s,style:s.toastStyle,key:n++,...Object.fromEntries(Object.entries(b).filter(([M,D])=>D!=null)),toastId:S,updateId:_,data:C,isIn:!1,className:NX(b.className||s.toastClassName),progressClassName:NX(b.progressClassName||s.progressClassName),autoClose:b.isLoading?!1:F9e(b.autoClose,s.autoClose),closeToast(M){l.get(S).removalReason=M,g(S)},deleteToast(){let M=l.get(S);if(M!=null){if(i(tae(M,"removed")),l.delete(S),r--,r<0&&(r=0),o.length>0){y(o.shift());return}d()}}};A.closeButton=s.closeButton,b.closeButton===!1||FX(b.closeButton)?A.closeButton=b.closeButton:b.closeButton===!0&&(A.closeButton=FX(s.closeButton)?s.closeButton:!0);let R={content:m,props:A,staleId:P};s.limit&&s.limit>0&&r>s.limit&&E?o.push(R):vV(x)?setTimeout(()=>{y(R)},x):y(R)},setProps(m){s=m},setToggle:(m,b)=>{let S=l.get(m);S&&(S.toggle=b)},isToastActive:m=>{var b;return(b=l.get(m))==null?void 0:b.isActive},getSnapshot:()=>a}}var Bf=new Map,qj=[],BX=new Set,$9e=t=>BX.forEach(e=>e(t)),Wwe=()=>Bf.size>0;function W9e(){qj.forEach(t=>Ywe(t.content,t.options)),qj=[]}var G9e=(t,{containerId:e})=>{var i;return(i=Bf.get(e||1))==null?void 0:i.toasts.get(t)};function Gwe(t,e){var i;if(e)return!!((i=Bf.get(e))!=null&&i.isToastActive(t));let n=!1;return Bf.forEach(r=>{r.isToastActive(t)&&(n=!0)}),n}function Y9e(t){if(!Wwe()){qj=qj.filter(e=>t!=null&&e.options.toastId!==t);return}if(t==null||N9e(t))Bf.forEach(e=>{e.removeToast(t)});else if(t&&("containerId"in t||"id"in t)){let e=Bf.get(t.containerId);e?e.removeToast(t.id):Bf.forEach(i=>{i.removeToast(t.id)})}}var q9e=(t={})=>{Bf.forEach(e=>{e.props.limit&&(!t.containerId||e.id===t.containerId)&&e.clearQueue()})};function Ywe(t,e){FX(t)&&(Wwe()||qj.push({content:t,options:e}),Bf.forEach(i=>{i.buildToast(t,e)}))}function X9e(t){var e;(e=Bf.get(t.containerId||1))==null||e.setToggle(t.id,t.fn)}function qwe(t,e){Bf.forEach(i=>{(e==null||!(e!=null&&e.containerId)||(e==null?void 0:e.containerId)===i.id)&&i.toggle(t,e==null?void 0:e.id)})}function K9e(t){let e=t.containerId||1;return{subscribe(i){let n=z9e(e,t,$9e);Bf.set(e,n);let r=n.observe(i);return W9e(),()=>{r(),Bf.delete(e)}},setProps(i){var n;(n=Bf.get(e))==null||n.setProps(i)},getSnapshot(){var i;return(i=Bf.get(e))==null?void 0:i.getSnapshot()}}}function Z9e(t){return BX.add(t),()=>{BX.delete(t)}}function J9e(t){return t&&(_D(t.toastId)||vV(t.toastId))?t.toastId:$we()}function yV(t,e){return Ywe(t,e),e.toastId}function j$(t,e){return{...e,type:e&&e.type||t,toastId:J9e(e)}}function V$(t){return(e,i)=>yV(e,j$(t,i))}function Ki(t,e){return yV(t,j$("default",e))}Ki.loading=(t,e)=>yV(t,j$("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...e}));function Q9e(t,{pending:e,error:i,success:n},r){let o;e&&(o=_D(e)?Ki.loading(e,r):Ki.loading(e.render,{...r,...e}));let a={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},s=(u,c,d)=>{if(c==null){Ki.dismiss(o);return}let f={type:u,...a,...r,data:d},h=_D(c)?{render:c}:c;return o?Ki.update(o,{...f,...h}):Ki(h.render,{...f,...h}),d},l=PS(t)?t():t;return l.then(u=>s("success",n,u)).catch(u=>s("error",i,u)),l}Ki.promise=Q9e;Ki.success=V$("success");Ki.info=V$("info");Ki.error=V$("error");Ki.warning=V$("warning");Ki.warn=Ki.warning;Ki.dark=(t,e)=>yV(t,j$("default",{theme:"dark",...e}));function e7e(t){Y9e(t)}Ki.dismiss=e7e;Ki.clearWaitingQueue=q9e;Ki.isActive=Gwe;Ki.update=(t,e={})=>{let i=G9e(t,e);if(i){let{props:n,content:r}=i,o={delay:100,...n,...e,toastId:e.toastId||t,updateId:$we()};o.toastId!==t&&(o.staleId=t);let a=o.render||r;delete o.render,yV(a,o)}};Ki.done=t=>{Ki.update(t,{progress:1})};Ki.onChange=Z9e;Ki.play=t=>qwe(!0,t);Ki.pause=t=>qwe(!1,t);function t7e(t){var e;let{subscribe:i,getSnapshot:n,setProps:r}=J.useRef(K9e(t)).current;r(t);let o=(e=J.useSyncExternalStore(i,n,n))==null?void 0:e.slice();function a(s){if(!o)return[];let l=new Map;return t.newestOnTop&&o.reverse(),o.forEach(u=>{let{position:c}=u.props;l.has(c)||l.set(c,[]),l.get(c).push(u)}),Array.from(l,u=>s(u[0],u[1]))}return{getToastToRender:a,isToastActive:Gwe,count:o==null?void 0:o.length}}function r7e(t){let[e,i]=J.useState(!1),[n,r]=J.useState(!1),o=J.useRef(null),a=J.useRef({start:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,didMove:!1}).current,{autoClose:s,pauseOnHover:l,closeToast:u,onClick:c,closeOnClick:d}=t;X9e({id:t.toastId,containerId:t.containerId,fn:i}),J.useEffect(()=>{if(t.pauseOnFocusLoss)return f(),()=>{h()}},[t.pauseOnFocusLoss]);function f(){document.hasFocus()||y(),window.addEventListener("focus",v),window.addEventListener("blur",y)}function h(){window.removeEventListener("focus",v),window.removeEventListener("blur",y)}function p(P){if(t.draggable===!0||t.draggable===P.pointerType){m();let x=o.current;a.canCloseOnClick=!0,a.canDrag=!0,x.style.transition="none",t.draggableDirection==="x"?(a.start=P.clientX,a.removalDistance=x.offsetWidth*(t.draggablePercent/100)):(a.start=P.clientY,a.removalDistance=x.offsetHeight*(t.draggablePercent===80?t.draggablePercent*1.5:t.draggablePercent)/100)}}function g(P){let{top:x,bottom:E,left:A,right:R}=o.current.getBoundingClientRect();P.nativeEvent.type!=="touchend"&&t.pauseOnHover&&P.clientX>=A&&P.clientX<=R&&P.clientY>=x&&P.clientY<=E?y():v()}function v(){i(!0)}function y(){i(!1)}function m(){a.didMove=!1,document.addEventListener("pointermove",S),document.addEventListener("pointerup",_)}function b(){document.removeEventListener("pointermove",S),document.removeEventListener("pointerup",_)}function S(P){let x=o.current;if(a.canDrag&&x){a.didMove=!0,e&&y(),t.draggableDirection==="x"?a.delta=P.clientX-a.start:a.delta=P.clientY-a.start,a.start!==P.clientX&&(a.canCloseOnClick=!1);let E=t.draggableDirection==="x"?`${a.delta}px, var(--y)`:`0, calc(${a.delta}px + var(--y))`;x.style.transform=`translate3d(${E},0)`,x.style.opacity=`${1-Math.abs(a.delta/a.removalDistance)}`}}function _(){b();let P=o.current;if(a.canDrag&&a.didMove&&P){if(a.canDrag=!1,Math.abs(a.delta)>a.removalDistance){r(!0),t.closeToast(!0),t.collapseAll();return}P.style.transition="transform 0.2s, opacity 0.2s",P.style.removeProperty("transform"),P.style.removeProperty("opacity")}}let C={onPointerDown:p,onPointerUp:g};return s&&l&&(C.onMouseEnter=y,t.stacked||(C.onMouseLeave=v)),d&&(C.onClick=P=>{c&&c(P),a.canCloseOnClick&&u(!0)}),{playToast:v,pauseToast:y,isRunning:e,preventExitTransition:n,toastRef:o,eventHandlers:C}}var i7e=typeof window<"u"?J.useLayoutEffect:J.useEffect,H$=({theme:t,type:e,isLoading:i,...n})=>Wn.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${e})`,...n});function n7e(t){return Wn.createElement(H$,{...t},Wn.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))}function o7e(t){return Wn.createElement(H$,{...t},Wn.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))}function a7e(t){return Wn.createElement(H$,{...t},Wn.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))}function s7e(t){return Wn.createElement(H$,{...t},Wn.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))}function l7e(){return Wn.createElement("div",{className:"Toastify__spinner"})}var jX={info:o7e,warning:n7e,success:a7e,error:s7e,spinner:l7e},u7e=t=>t in jX;function c7e({theme:t,type:e,isLoading:i,icon:n}){let r=null,o={theme:t,type:e};return n===!1||(PS(n)?r=n({...o,isLoading:i}):J.isValidElement(n)?r=J.cloneElement(n,o):i?r=jX.spinner():u7e(e)&&(r=jX[e](o))),r}var d7e=t=>{let{isRunning:e,preventExitTransition:i,toastRef:n,eventHandlers:r,playToast:o}=r7e(t),{closeButton:a,children:s,autoClose:l,onClick:u,type:c,hideProgressBar:d,closeToast:f,transition:h,position:p,className:g,style:v,progressClassName:y,updateId:m,role:b,progress:S,rtl:_,toastId:C,deleteToast:P,isIn:x,isLoading:E,closeOnClick:A,theme:R,ariaLabel:M}=t,D=Rv("Toastify__toast",`Toastify__toast-theme--${R}`,`Toastify__toast--${c}`,{"Toastify__toast--rtl":_},{"Toastify__toast--close-on-click":A}),F=PS(g)?g({rtl:_,position:p,type:c,defaultClassName:D}):Rv(D,g),I=c7e(t),V=!!S||!l,z={closeToast:f,type:c,theme:R},G=null;return a===!1||(PS(a)?G=a(z):J.isValidElement(a)?G=J.cloneElement(a,z):G=V9e(z)),Wn.createElement(h,{isIn:x,done:P,position:p,preventExitTransition:i,nodeRef:n,playToast:o},Wn.createElement("div",{id:C,tabIndex:0,onClick:u,"data-in":x,className:F,...r,style:v,ref:n,...x&&{role:b,"aria-label":M}},I!=null&&Wn.createElement("div",{className:Rv("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!E})},I),zwe(s,t,!e),G,!t.customProgressBar&&Wn.createElement(H9e,{...m&&!V?{key:`p-${m}`}:{},rtl:_,theme:R,delay:l,isRunning:e,isIn:x,closeToast:f,hide:d,type:c,className:y,controlledProgress:V,progress:S||0})))},f7e=(t,e=!1)=>({enter:`Toastify--animate Toastify__${t}-enter`,exit:`Toastify--animate Toastify__${t}-exit`,appendPosition:e}),h7e=j9e(f7e("bounce",!0)),p7e={position:"top-right",transition:h7e,autoClose:5e3,closeButton:!0,pauseOnHover:!0,pauseOnFocusLoss:!0,draggable:"touch",draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light","aria-label":"Notifications Alt+T",hotKeys:t=>t.altKey&&t.code==="KeyT"};function g7e(t){let e={...p7e,...t},i=t.stacked,[n,r]=J.useState(!0),o=J.useRef(null),{getToastToRender:a,isToastActive:s,count:l}=t7e(e),{className:u,style:c,rtl:d,containerId:f,hotKeys:h}=e;function p(v){let y=Rv("Toastify__toast-container",`Toastify__toast-container--${v}`,{"Toastify__toast-container--rtl":d});return PS(u)?u({position:v,rtl:d,defaultClassName:y}):Rv(y,NX(u))}function g(){i&&(r(!0),Ki.play())}return i7e(()=>{var v;if(i){let y=o.current.querySelectorAll('[data-in="true"]'),m=12,b=(v=e.position)==null?void 0:v.includes("top"),S=0,_=0;Array.from(y).reverse().forEach((C,P)=>{let x=C;x.classList.add("Toastify__toast--stacked"),P>0&&(x.dataset.collapsed=`${n}`),x.dataset.pos||(x.dataset.pos=b?"top":"bot");let E=S*(n?.2:1)+(n?0:m*P);x.style.setProperty("--y",`${b?E:E*-1}px`),x.style.setProperty("--g",`${m}`),x.style.setProperty("--s",`${1-(n?_:0)}`),S+=x.offsetHeight,_+=.025})}},[n,l,i]),J.useEffect(()=>{function v(y){var m;let b=o.current;h(y)&&((m=b.querySelector('[tabIndex="0"]'))==null||m.focus(),r(!1),Ki.pause()),y.key==="Escape"&&(document.activeElement===b||b!=null&&b.contains(document.activeElement))&&(r(!0),Ki.play())}return document.addEventListener("keydown",v),()=>{document.removeEventListener("keydown",v)}},[h]),Wn.createElement("section",{ref:o,className:"Toastify",id:f,onMouseEnter:()=>{i&&(r(!1),Ki.pause())},onMouseLeave:g,"aria-live":"polite","aria-atomic":"false","aria-relevant":"additions text","aria-label":e["aria-label"]},a((v,y)=>{let m=y.length?{...c}:{...c,pointerEvents:"none"};return Wn.createElement("div",{tabIndex:-1,className:p(v),"data-stacked":i,style:m,key:`c-${v}`},y.map(({content:b,props:S})=>Wn.createElement(d7e,{...S,stacked:i,collapseAll:g,isIn:s(S.toastId,S.containerId),key:`t-${S.key}`},b)))}))}function CQ(){const t=qt.c(51),e=PQ(),{environment:i,preferences:n}=Lp();let r;t[0]!==i.studioBackendUrl?(r=new xwe(i.studioBackendUrl),t[0]=i.studioBackendUrl,t[1]=r):r=t[1];const o=r;let a;t[2]===Symbol.for("react.memo_cache_sentinel")?(a=new Set,t[2]=a):a=t[2];const[s,l]=J.useState(a);let u;t[3]!==n.showHiddenFiles?(u=["folder","/",n.showHiddenFiles],t[3]=n.showHiddenFiles,t[4]=u):u=t[4];let c;t[5]!==o||t[6]!==n.showHiddenFiles?(c=()=>o.getDirectoryContents("/",n.showHiddenFiles),t[5]=o,t[6]=n.showHiddenFiles,t[7]=c):c=t[7];let d;t[8]!==u||t[9]!==c?(d={queryKey:u,queryFn:c,networkMode:"always"},t[8]=u,t[9]=c,t[10]=d):d=t[10];const f=k9e(d);let h;t[11]!==s?(h=Array.from(s),t[11]=s,t[12]=h):h=t[12];const p=h;let g;t[13]!==p||t[14]!==o||t[15]!==n.showHiddenFiles?(g={queries:p.map(Y=>({queryKey:["folder",Y,n.showHiddenFiles],queryFn:()=>o.getDirectoryContents(Y,n.showHiddenFiles),networkMode:"always"}))},t[13]=p,t[14]=o,t[15]=n.showHiddenFiles,t[16]=g):g=t[16];const v=M9e(g);let y;t[17]!==v?(y=v.map(y7e),t[17]=v,t[18]=y):y=t[18];const m=y;let b;t[19]!==v?(b=v.map(v7e),t[19]=v,t[20]=b):b=t[20];const S=b;let _;t[21]!==p||t[22]!==m||t[23]!==f.data?(_=new Map,_.set("/",f.data??[]),p.forEach((Y,te)=>{const oe=m[te];oe&&_.set(Y,oe)}),t[21]=p,t[22]=m,t[23]=f.data,t[24]=_):_=t[24];const C=_;let P;e:{if(!f.data){P=null;break e}let Y;if(t[25]!==C||t[26]!==f.data){const te={id:"/",name:"root",path:"/",type:"folder",children:f.data};Y=Xwe(te,C),t[25]=C,t[26]=f.data,t[27]=Y}else Y=t[27];P=Y}const x=P;let E,A;t[28]!==p||t[29]!==S?(E=()=>{p.forEach((Y,te)=>{S[te]&&(Ki.error(`Failed to load folder: ${Y}`,{toastId:`folder-error-${Y}`}),l(de=>{const ge=new Set(de);return ge.delete(Y),ge}))})},A=[p,S],t[28]=p,t[29]=S,t[30]=E,t[31]=A):(E=t[30],A=t[31]),J.useEffect(E,A);let R;t[32]!==p||t[33]!==v?(R=Y=>{var oe;const te=p.indexOf(Y);return te===-1?!1:((oe=v[te])==null?void 0:oe.isLoading)??!1},t[32]=p,t[33]=v,t[34]=R):R=t[34];const M=R;let D;t[35]===Symbol.for("react.memo_cache_sentinel")?(D=Y=>{l(te=>{const oe=new Set(te);return oe.has(Y)?oe.delete(Y):oe.add(Y),oe})},t[35]=D):D=t[35];const F=D;let I;t[36]!==s?(I=Y=>s.has(Y),t[36]=s,t[37]=I):I=t[37];const V=I;let z;t[38]===Symbol.for("react.memo_cache_sentinel")?(z=Y=>{if(!Y)return;const te=m7e(Y);l(oe=>{const de=new Set(oe);return te.forEach(ge=>de.add(ge)),de})},t[38]=z):z=t[38];const G=z;let H;t[39]!==e?(H=()=>{e.invalidateQueries({queryKey:["folder"]})},t[39]=e,t[40]=H):H=t[40];const U=H;let k;t[41]!==e?(k=Y=>{e.invalidateQueries({queryKey:["folder",Y]})},t[41]=e,t[42]=k):k=t[42];const X=k;let W;return t[43]!==s||t[44]!==x||t[45]!==V||t[46]!==M||t[47]!==U||t[48]!==X||t[49]!==f.isLoading?(W={fileTree:x,expandedFolders:s,isLoading:f.isLoading,toggleFolder:F,setExpandedFolders:l,isFolderExpanded:V,isFolderLoading:M,expandToPath:G,refreshFileTree:U,refreshFolder:X},t[43]=s,t[44]=x,t[45]=V,t[46]=M,t[47]=U,t[48]=X,t[49]=f.isLoading,t[50]=W):W=t[50],W}function v7e(t){return t.error}function y7e(t){return t.data}function Xwe(t,e){if(t.type!=="folder")return t;const i=e.get(t.path);return i?{...t,children:i.map(n=>Xwe(n,e))}:t}function m7e(t){const e=t.split("/").filter(Boolean),i=["/"];let n="";for(let r=0;r<e.length-1;r++)n+="/"+e[r],i.push(n);return i}const b7e=new A9e({defaultOptions:{queries:{staleTime:600*1e3,gcTime:1/0,refetchOnWindowFocus:!1}}});function S7e(t){const e=qt.c(2);let i;return e[0]!==t.children?(i=L.jsx(O9e,{client:b7e,children:t.children}),e[0]=t.children,e[1]=i):i=e[1],i}function Kwe(){const t=qt.c(2),{openPage:e}=Ih();let i;return t[0]!==e?(i=(n,r)=>{const o=n.split("/").pop()||"File";e(Nu.FILES,{id:`file:${n}`,title:o,params:{path:n,fileType:r}})},t[0]=e,t[1]=i):i=t[1],i}const _7e=50;function P7e(t,e){const i=qt.c(4),n=_7e,[r,o]=J.useState(!1);let a,s;return i[0]!==n||i[1]!==t?(a=()=>{if(!t)return;const l=setTimeout(()=>o(!0),n);return()=>{clearTimeout(l),o(!1)}},s=[t,n],i[0]=n,i[1]=t,i[2]=a,i[3]=s):(a=i[2],s=i[3]),J.useEffect(a,s),r}const C7e=12,T7e=(t,e,i)=>{i?t():e()},x7e=(t,e)=>L.jsx(L.Fragment,{children:e?L.jsx("span",{className:"w-4 h-4 flex items-center justify-center",children:L.jsx(Wr,{type:dr.NAV_CHEVRON_RIGHT,className:Hr("w-3.5 h-3.5 text-white/50 transition-transform duration-100",t&&"rotate-90")})}):L.jsx("span",{className:"w-4"})}),E7e=(t,e,i,n)=>t?L.jsx(Wr,{type:dr.STATUS_LOADING,className:"w-4 h-4 text-white/50 animate-spin"}):e?L.jsxs("span",{className:"relative w-4 h-4 shrink-0",children:[L.jsx(Wr,{type:dr.FOLDER_OPEN,className:Hr("absolute inset-0 w-4 h-4 text-green-500/90 transition-opacity duration-200",i?"opacity-100":"opacity-0")}),L.jsx(Wr,{type:dr.FOLDER_CLOSED,className:Hr("absolute inset-0 w-4 h-4 text-green-500/90 transition-opacity duration-200",i?"opacity-0":"opacity-100")})]}):L.jsx(Wr,{type:n,className:"w-4 h-4 shrink-0 text-blue-300/90"}),w7e=t=>L.jsx(L.Fragment,{children:L.jsx("span",{className:"truncate",children:t})});function Zwe(t){const e=qt.c(35),i=t.node.type==="folder",n=P7e(t.isLoading??!1)&&i;let r,o,a,s,l,u;if(e[0]!==i||e[1]!==t.depth||e[2]!==t.isActive||e[3]!==t.isExpanded||e[4]!==t.node||e[5]!==t.onSelect||e[6]!==t.onToggle||e[7]!==n){const f=i?t.isExpanded?dr.FOLDER_OPEN:dr.FOLDER_CLOSED:i9e(t.node),h=t.isActive?"bg-white/[0.08] hover:bg-white/[0.14]":"hover:bg-white/10";e[14]!==h?(r=Hr("flex items-center gap-1.5 py-1.5 px-2 cursor-pointer ms-1","text-white hover:text-white/80 text-xs","transition-colors duration-150",h),e[14]=h,e[15]=r):r=e[15];const p=`${t.depth*C7e}px`;e[16]!==p?(o={paddingLeft:p},e[16]=p,e[17]=o):o=e[17],e[18]!==i||e[19]!==t.onSelect||e[20]!==t.onToggle?(a=()=>T7e(t.onToggle,t.onSelect,i),e[18]=i,e[19]=t.onSelect,e[20]=t.onToggle,e[21]=a):a=e[21],s=`file-${t.node.id}`,e[22]!==i||e[23]!==t.isExpanded?(l=x7e(t.isExpanded,i),e[22]=i,e[23]=t.isExpanded,e[24]=l):l=e[24],u=E7e(n,i,t.isExpanded,f),e[0]=i,e[1]=t.depth,e[2]=t.isActive,e[3]=t.isExpanded,e[4]=t.node,e[5]=t.onSelect,e[6]=t.onToggle,e[7]=n,e[8]=r,e[9]=o,e[10]=a,e[11]=s,e[12]=l,e[13]=u}else r=e[8],o=e[9],a=e[10],s=e[11],l=e[12],u=e[13];let c;e[25]!==t.node.name?(c=w7e(t.node.name),e[25]=t.node.name,e[26]=c):c=e[26];let d;return e[27]!==r||e[28]!==o||e[29]!==a||e[30]!==s||e[31]!==l||e[32]!==u||e[33]!==c?(d=L.jsxs("div",{className:r,style:o,onClick:a,"data-testid":s,children:[l,u,c]}),e[27]=r,e[28]=o,e[29]=a,e[30]=s,e[31]=l,e[32]=u,e[33]=c,e[34]=d):d=e[34],d}function Jwe(){const t=qt.c(23),{fileTree:e,isLoading:i,isFolderExpanded:n,isFolderLoading:r,toggleFolder:o,expandToPath:a}=CQ(),{activePage:s}=Ih(),l=Kwe(),u=J.useRef(null);let c,d;t[0]!==s||t[1]!==a||t[2]!==e||t[3]!==i?(c=()=>{(()=>{var b;if(!e||i||!s||s.type!==Nu.FILES)return;const m=(b=s.params)==null?void 0:b.path;m&&m!==u.current&&(u.current=m,a(m))})()},d=[e,i,s,a],t[0]=s,t[1]=a,t[2]=e,t[3]=i,t[4]=c,t[5]=d):(c=t[4],d=t[5]),J.useEffect(c,d);let f,h,p,g;if(t[6]!==(s==null?void 0:s.id)||t[7]!==e||t[8]!==n||t[9]!==r||t[10]!==i||t[11]!==l||t[12]!==o){g=Symbol.for("react.early_return_sentinel");e:{const y=(m,b)=>{var P;const S=n(m.id),_=r(m.path),C=m.type==="file"&&(s==null?void 0:s.id)===`file:${m.path}`;return L.jsxs("div",{children:[L.jsx(Zwe,{node:m,depth:b,isExpanded:S,isActive:C,isLoading:_,onToggle:()=>o(m.id),onSelect:()=>{m.type==="file"&&l(m.path,m.fileType)}}),m.type==="folder"&&S&&L.jsx("div",{children:(P=m.children)==null?void 0:P.map(x=>y(x,b+1))})]},m.id)};if(!e){let m;t[17]===Symbol.for("react.memo_cache_sentinel")?(m=L.jsx("div",{className:"p-4 text-sm text-white/60",children:"No files found"}),t[17]=m):m=t[17],g=m;break e}if(i||e.children===void 0){let m;t[18]===Symbol.for("react.memo_cache_sentinel")?(m=L.jsx("div",{className:"p-4 text-sm text-white/60",children:"Loading files..."}),t[18]=m):m=t[18],g=m;break e}f="py-2",h="file-tree",p=e.children.map(m=>y(m,0))}t[6]=s==null?void 0:s.id,t[7]=e,t[8]=n,t[9]=r,t[10]=i,t[11]=l,t[12]=o,t[13]=f,t[14]=h,t[15]=p,t[16]=g}else f=t[13],h=t[14],p=t[15],g=t[16];if(g!==Symbol.for("react.early_return_sentinel"))return g;let v;return t[19]!==f||t[20]!==h||t[21]!==p?(v=L.jsx("div",{className:f,"data-testid":h,children:p}),t[19]=f,t[20]=h,t[21]=p,t[22]=v):v=t[22],v}function A7e(t){const e=qt.c(4);let i;return e[0]!==t.fileName||e[1]!==t.onError||e[2]!==t.url?(i=L.jsx("div",{className:"h-full flex items-center justify-center bg-muted/30 rounded-sm border border-border overflow-hidden",children:L.jsx("img",{src:t.url,alt:t.fileName,className:"max-w-full max-h-full object-contain",onError:t.onError})}),e[0]=t.fileName,e[1]=t.onError,e[2]=t.url,e[3]=i):i=e[3],i}function O7e(t){const e=qt.c(3);let i;return e[0]!==t.onError||e[1]!==t.url?(i=L.jsx("div",{className:"h-full flex items-center justify-center bg-black rounded-sm border border-border overflow-hidden",children:L.jsx("video",{src:t.url,controls:!0,className:"max-w-full max-h-full",onError:t.onError,children:"Your browser does not support video playback."})}),e[0]=t.onError,e[1]=t.url,e[2]=i):i=e[2],i}function D7e(t){const e=qt.c(4);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx(Wr,{type:dr.FILE_AUDIO,className:"w-16 h-16 text-muted-foreground mb-4 mx-auto"}),e[0]=i):i=e[0];let n;return e[1]!==t.onError||e[2]!==t.url?(n=L.jsx("div",{className:"h-full flex flex-col items-center justify-center",children:L.jsxs("div",{className:"p-4 rounded-sm bg-muted/30 border border-border",children:[i,L.jsx("audio",{src:t.url,controls:!0,className:"w-full max-w-md",onError:t.onError,children:"Your browser does not support audio playback."})]})}),e[1]=t.onError,e[2]=t.url,e[3]=n):n=e[3],n}const R7e="modulepreload",M7e=function(t){return"/"+t},rae={},iae=function(e,i,n){let r=Promise.resolve();if(i&&i.length>0){let a=function(u){return Promise.all(u.map(c=>Promise.resolve(c).then(d=>({status:"fulfilled",value:d}),d=>({status:"rejected",reason:d}))))};document.getElementsByTagName("link");const s=document.querySelector("meta[property=csp-nonce]"),l=(s==null?void 0:s.nonce)||(s==null?void 0:s.getAttribute("nonce"));r=a(i.map(u=>{if(u=M7e(u),u in rae)return;rae[u]=!0;const c=u.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${u}"]${d}`))return;const f=document.createElement("link");if(f.rel=c?"stylesheet":R7e,c||(f.as="script"),f.crossOrigin="",f.href=u,l&&f.setAttribute("nonce",l),document.head.appendChild(f),c)return new Promise((h,p)=>{f.addEventListener("load",h),f.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${u}`)))})}))}function o(a){const s=new Event("vite:preloadError",{cancelable:!0});if(s.payload=a,window.dispatchEvent(s),!s.defaultPrevented)throw a}return r.then(a=>{for(const s of a||[])s.status==="rejected"&&o(s.reason);return e().catch(o)})},nae="#edf4fa",oae="#10121c";function L7e(t,e){document.querySelectorAll('meta[name="theme-color"]').forEach(i=>i.remove()),e?(t8(nae,"(prefers-color-scheme: light)"),t8(oae,"(prefers-color-scheme: dark)")):t8(t?oae:nae)}function t8(t,e){const i=document.createElement("meta");i.setAttribute("name","theme-color"),i.setAttribute("content",t),e&&i.setAttribute("media",e),document.head.appendChild(i)}var VL=(t=>(t.System="system",t.Light="light",t.Dark="dark",t))(VL||{});const Qwe="THEME_PREFERENCE";function k7e(){const t=localStorage.getItem(Qwe);return t==="light"||t==="dark"||t==="system"?t:"system"}function I7e(){return window.matchMedia("(prefers-color-scheme: dark)").matches}function N7e(t){window.document.documentElement.classList.toggle("dark",t)}const eAe=J.createContext(null);function F7e(t){const e=qt.c(16),[i,n]=J.useState(k7e),[r,o]=J.useState(I7e),a=i==="system"?r:i==="dark";let s;e[0]!==a||e[1]!==i?(s=()=>{N7e(a),localStorage.setItem(Qwe,i),L7e(a,i==="system")},e[0]=a,e[1]=i,e[2]=s):s=e[2];let l;e[3]!==a||e[4]!==r||e[5]!==i?(l=[i,r,a],e[3]=a,e[4]=r,e[5]=i,e[6]=l):l=e[6],J.useEffect(s,l);let u,c;e[7]===Symbol.for("react.memo_cache_sentinel")?(u=()=>{const p=window.matchMedia("(prefers-color-scheme: dark)"),g=v=>{o(v.matches)};return p.addEventListener("change",g),()=>p.removeEventListener("change",g)},c=[],e[7]=u,e[8]=c):(u=e[7],c=e[8]),J.useEffect(u,c);let d;e[9]!==a||e[10]!==r||e[11]!==i?(d={theme:i,setTheme:n,systemPrefersDark:r,isDarkMode:a},e[9]=a,e[10]=r,e[11]=i,e[12]=d):d=e[12];const f=d;let h;return e[13]!==t.children||e[14]!==f?(h=L.jsx(eAe.Provider,{value:f,children:t.children}),e[13]=t.children,e[14]=f,e[15]=h):h=e[15],h}function dI(){const t=J.useContext(eAe);if(!t)throw new Error("useTheme must be used within a ThemeProvider");return t}function B7e(t){return t?{text:"plaintext",json:"json",yaml:"yaml",yml:"yaml",javascript:"javascript",js:"javascript",typescript:"typescript",ts:"typescript",xml:"xml",html:"html",css:"css",markdown:"markdown",md:"markdown",python:"python",py:"python"}[t.toLowerCase()]??"plaintext":"plaintext"}const j7e=J.lazy(()=>iae(()=>import("./monacoEnv-DDxkZyi9.js"),__vite__mapDeps([0,1,2,3])).then(()=>iae(()=>import("./ActivitySafeEditor-jnRET48j.js"),__vite__mapDeps([4,1,2])).then(t=>({default:t.ActivitySafeEditor}))));function V7e(){const t=qt.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center min-h-[200px] text-muted-foreground text-sm gap-2",children:[L.jsx(Wr,{type:dr.STATUS_LOADING,className:"w-6 h-6 animate-spin"}),"Loading editor…"]}),t[0]=e):e=t[0],e}function tAe(t){const e=qt.c(11),{isDarkMode:i}=dI();let n;e[0]!==t.language?(n=B7e(t.language),e[0]=t.language,e[1]=n):n=e[1];const r=n,o=`rounded-sm overflow-hidden border border-border bg-muted dark:bg-[#1a1b26] flex flex-col min-h-0 ${t.className}`;let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(V7e,{}),e[2]=a):a=e[2];const s=i?"vs-dark":"vs-light";let l;e[3]===Symbol.for("react.memo_cache_sentinel")?(l={readOnly:!0,minimap:{enabled:!0},scrollBeyondLastLine:!1,lineNumbers:"on",wordWrap:"on",folding:!0,automaticLayout:!0},e[3]=l):l=e[3];let u;e[4]!==r||e[5]!==t.text||e[6]!==s?(u=L.jsx("div",{className:"flex-1 min-h-0 relative",children:L.jsx("div",{className:"absolute inset-0 overflow-hidden",children:L.jsx(J.Suspense,{fallback:a,children:L.jsx(j7e,{value:t.text,language:r,theme:s,options:l})})})}),e[4]=r,e[5]=t.text,e[6]=s,e[7]=u):u=e[7];let c;return e[8]!==o||e[9]!==u?(c=L.jsx("div",{className:o,children:u}),e[8]=o,e[9]=u,e[10]=c):c=e[10],c}var Sk={},kr;if(typeof window>"u"){var aae={hostname:""};kr={crypto:{randomUUID:function(){throw Error("unsupported")}},navigator:{userAgent:"",onLine:!0},document:{createElement:function(){return{}},location:aae,referrer:""},screen:{width:0,height:0},location:aae,addEventListener:function(){},removeEventListener:function(){},dispatchEvent:function(){},CustomEvent:function(){}}}else kr=window;var Dh={DEBUG:!1,LIB_VERSION:"2.76.0"},yv="__mp_targeting",VX="__mp_recorder",H7e="__MP_RECORDER_FILENAME__",rAe="__MP_TARGETING_FILENAME__";function sae(t,e){(e==null||e>t.length)&&(e=t.length);for(var i=0,n=new Array(e);i<e;i++)n[i]=t[i];return n}function lae(t,e,i,n,r,o,a){try{var s=t[o](a),l=s.value}catch(u){i(u);return}s.done?e(l):Promise.resolve(l).then(n,r)}function U$(t){return function(){var e=this,i=arguments;return new Promise(function(n,r){var o=t.apply(e,i);function a(l){lae(o,n,r,a,s,"next",l)}function s(l){lae(o,n,r,a,s,"throw",l)}a(void 0)})}}function OU(t,e,i){return iAe()?OU=Reflect.construct:OU=function(r,o,a){var s=[null];s.push.apply(s,o);var l=Function.bind.apply(r,s),u=new l;return a&&Xj(u,a.prototype),u},OU.apply(null,arguments)}function U7e(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}function Is(t,e,i){return e&&U7e(t.prototype,e),t}function Zn(){return Zn=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n]=i[n])}return t},Zn.apply(this,arguments)}function HX(t){return HX=Object.setPrototypeOf?Object.getPrototypeOf:function(i){return i.__proto__||Object.getPrototypeOf(i)},HX(t)}function Ks(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Xj(t,e)}function Ni(t,e){return e!=null&&typeof Symbol<"u"&&e[Symbol.hasInstance]?!!e[Symbol.hasInstance](t):t instanceof e}function z7e(t){return Function.toString.call(t).indexOf("[native code]")!==-1}function PD(t,e){if(t==null)return{};var i={},n=Object.keys(t),r,o;for(o=0;o<n.length;o++)r=n[o],!(e.indexOf(r)>=0)&&(i[r]=t[r]);return i}function Xj(t,e){return Xj=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n},Xj(t,e)}function Ui(t){"@swc/helpers - typeof";return t&&typeof Symbol<"u"&&t.constructor===Symbol?"symbol":typeof t}function $7e(t,e){if(t){if(typeof t=="string")return sae(t,e);var i=Object.prototype.toString.call(t).slice(8,-1);if(i==="Object"&&t.constructor&&(i=t.constructor.name),i==="Map"||i==="Set")return Array.from(i);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return sae(t,e)}}function Kj(t){var e=typeof Map=="function"?new Map:void 0;return Kj=function(n){if(n===null||!z7e(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(typeof e<"u"){if(e.has(n))return e.get(n);e.set(n,r)}function r(){return OU(n,arguments,HX(this).constructor)}return r.prototype=Object.create(n.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Xj(r,n)},Kj(t)}function iAe(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(iAe=function(){return!!t})()}function Ur(t,e){var i=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(i)return(i=i.call(t)).next.bind(i);if(Array.isArray(t)||(i=$7e(t))||e){i&&(t=i);var n=0;return function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function CD(t,e){var i,n,r,o,a={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]};return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(c){return l([u,c])}}function l(u){if(i)throw new TypeError("Generator is already executing.");for(;a;)try{if(i=1,n&&(r=u[0]&2?n.return:u[0]?n.throw||((r=n.return)&&r.call(n),0):n.next)&&!(r=r.call(n,u[1])).done)return r;switch(n=0,r&&(u=[u[0]&2,r.value]),u[0]){case 0:case 1:r=u;break;case 4:return a.label++,{value:u[1],done:!1};case 5:a.label++,n=u[1],u=[0];continue;case 7:u=a.ops.pop(),a.trys.pop();continue;default:if(r=a.trys,!(r=r.length>0&&r[r.length-1])&&(u[0]===6||u[0]===2)){a=0;continue}if(u[0]===3&&(!r||u[1]>r[0]&&u[1]<r[3])){a.label=u[1];break}if(u[0]===6&&a.label<r[1]){a.label=r[1],r=u;break}if(r&&a.label<r[2]){a.label=r[2],a.ops.push(u);break}r[2]&&a.ops.pop(),a.trys.pop();continue}u=e.call(t,a)}catch(c){u=[6,c],n=0}finally{i=r=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}}function TQ(t){var e=typeof Symbol=="function"&&Symbol.iterator,i=e&&t[e],n=0;if(i)return i.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}var W7e=Object.defineProperty,G7e=function(t,e,i){return e in t?W7e(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i},Jr=function(t,e,i){return G7e(t,(typeof e>"u"?"undefined":Ui(e))!=="symbol"?e+"":e,i)},uae,Y7e=Object.defineProperty,q7e=function(t,e,i){return e in t?Y7e(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i},cae=function(t,e,i){return q7e(t,(typeof e>"u"?"undefined":Ui(e))!=="symbol"?e+"":e,i)},Zu=(function(t){return t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t})(Zu||{}),dae={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},fae={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},_H={},X7e=function(){return!!globalThis.Zone};function xQ(t){if(_H[t])return _H[t];var e=globalThis[t],i=e.prototype,n=t in dae?dae[t]:void 0,r=!!(n&&n.every(function(c){var d,f;return!!((f=(d=Object.getOwnPropertyDescriptor(i,c))==null?void 0:d.get)!=null&&f.toString().includes("[native code]"))})),o=t in fae?fae[t]:void 0,a=!!(o&&o.every(function(c){var d;return typeof i[c]=="function"&&((d=i[c])==null?void 0:d.toString().includes("[native code]"))}));if(r&&a&&!X7e())return _H[t]=e.prototype,e.prototype;try{var s=document.createElement("iframe");document.body.appendChild(s);var l=s.contentWindow;if(!l)return e.prototype;var u=l[t].prototype;return document.body.removeChild(s),u?_H[t]=u:i}catch{return i}}var r8={};function kP(t,e,i){var n,r=t+"."+String(i);if(r8[r])return r8[r].call(e);var o=xQ(t),a=(n=Object.getOwnPropertyDescriptor(o,i))==null?void 0:n.get;return a?(r8[r]=a,a.call(e)):e[i]}var i8={};function nAe(t,e,i){var n=t+"."+String(i);if(i8[n])return i8[n].bind(e);var r=xQ(t),o=r[i];return typeof o!="function"?e[i]:(i8[n]=o,o.bind(e))}function K7e(t){return kP("Node",t,"childNodes")}function Z7e(t){return kP("Node",t,"parentNode")}function J7e(t){return kP("Node",t,"parentElement")}function Q7e(t){return kP("Node",t,"textContent")}function eXe(t,e){return nAe("Node",t,"contains")(e)}function tXe(t){return nAe("Node",t,"getRootNode")()}function rXe(t){return!t||!("host"in t)?null:kP("ShadowRoot",t,"host")}function iXe(t){return t.styleSheets}function nXe(t){return!t||!("shadowRoot"in t)?null:kP("Element",t,"shadowRoot")}function oXe(t,e){return kP("Element",t,"querySelector")(e)}function aXe(t,e){return kP("Element",t,"querySelectorAll")(e)}function sXe(){return xQ("MutationObserver").constructor}function lXe(t,e,i){try{if(!(e in t))return function(){};var n=t[e],r=i(n);return typeof r=="function"&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__rrweb_original__:{enumerable:!1,value:n}})),t[e]=r,function(){t[e]=n}}catch{return function(){}}}var Bd={childNodes:K7e,parentNode:Z7e,parentElement:J7e,textContent:Q7e,contains:eXe,getRootNode:tXe,host:rXe,styleSheets:iXe,shadowRoot:nXe,querySelector:oXe,querySelectorAll:aXe,mutationObserver:sXe,patch:lXe};function oAe(t){return t.nodeType===t.ELEMENT_NODE}function mj(t){var e=t&&"host"in t&&"mode"in t&&Bd.host(t)||null;return!!(e&&"shadowRoot"in e&&Bd.shadowRoot(e)===t)}function bj(t){return Object.prototype.toString.call(t)==="[object ShadowRoot]"}function uXe(t){return t.includes(" background-clip: text;")&&!t.includes(" -webkit-background-clip: text;")&&(t=t.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),t}function cXe(t){var e=t.cssText;if(e.split('"').length<3)return e;var i=["@import","url("+JSON.stringify(t.href)+")"];return t.layerName===""?i.push("layer"):t.layerName&&i.push("layer("+t.layerName+")"),t.supportsText&&i.push("supports("+t.supportsText+")"),t.media.length&&i.push(t.media.mediaText),i.join(" ")+";"}function UX(t){try{var e=t.rules||t.cssRules;if(!e)return null;var i=t.href;!i&&t.ownerNode&&t.ownerNode.ownerDocument&&(i=t.ownerNode.ownerDocument.location.href);var n=Array.from(e,function(r){return aAe(r,i)}).join("");return uXe(n)}catch{return null}}function aAe(t,e){if(fXe(t)){var i;try{i=UX(t.styleSheet)||cXe(t)}catch{i=t.cssText}return t.styleSheet.href?E5(i,t.styleSheet.href):i}else{var n=t.cssText;return hXe(t)&&t.selectorText.includes(":")&&(n=dXe(n)),e?E5(n,e):n}}function dXe(t){var e=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return t.replace(e,"$1\\$2")}function fXe(t){return"styleSheet"in t}function hXe(t){return"selectorText"in t}var sAe=(function(){function t(){cae(this,"idNodeMap",new Map),cae(this,"nodeMetaMap",new WeakMap)}var e=t.prototype;return e.getId=function(n){var r;if(!n)return-1;var o=(r=this.getMeta(n))==null?void 0:r.id;return o??-1},e.getNode=function(n){return this.idNodeMap.get(n)||null},e.getIds=function(){return Array.from(this.idNodeMap.keys())},e.getMeta=function(n){return this.nodeMetaMap.get(n)||null},e.removeNodeFromMap=function(n,r){var o=this;r===void 0&&(r=!1);var a=this.getId(n);this.idNodeMap.delete(a),r&&this.nodeMetaMap.delete(n),n.childNodes&&n.childNodes.forEach(function(s){return o.removeNodeFromMap(s,r)})},e.has=function(n){return this.idNodeMap.has(n)},e.hasNode=function(n){return this.nodeMetaMap.has(n)},e.add=function(n,r){var o=r.id;this.idNodeMap.set(o,n),this.nodeMetaMap.set(n,r)},e.replace=function(n,r){var o=this.getNode(n);if(o){var a=this.nodeMetaMap.get(o);a&&this.nodeMetaMap.set(r,a)}this.idNodeMap.set(n,r)},e.reset=function(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap},t})();function pXe(){return new sAe}function T5(t){var e=t.element,i=t.maskInputOptions,n=t.tagName,r=t.type,o=t.value,a=t.maskInputFn,s=o||"",l=r&&TD(r);return(i[n.toLowerCase()]||l&&i[l])&&(a?s=a(s,e):s="*".repeat(s.length)),s}function TD(t){return t.toLowerCase()}var hae="__rrweb_original__";function gXe(t){var e=t.getContext("2d");if(!e)return!0;for(var i=50,n=0;n<t.width;n+=i)for(var r=0;r<t.height;r+=i){var o=e.getImageData,a=hae in o?o[hae]:o,s=new Uint32Array(a.call(e,n,r,Math.min(i,t.width-n),Math.min(i,t.height-r)).data.buffer);if(s.some(function(l){return l!==0}))return!1}return!0}function x5(t){var e=t.type;return t.hasAttribute("data-rr-is-password")?"password":e?TD(e):null}function lAe(t,e){var i;try{i=new URL(t,e??window.location.href)}catch{return null}var n=/\.([0-9a-z]+)(?:$)/i,r=i.pathname.match(n),o;return(o=r==null?void 0:r[1])!=null?o:null}function vXe(t){var e="";return t.indexOf("//")>-1?e=t.split("/").slice(0,3).join("/"):e=t.split("/")[0],e=e.split("?")[0],e}var yXe=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,mXe=/^(?:[a-z+]+:)?\/\//i,bXe=/^www\..*/i,SXe=/^(data:)([^,]*),(.*)/i;function E5(t,e){return(t||"").replace(yXe,function(i,n,r,o,a,s){var l=r||a||s,u=n||o||"";if(!l)return i;if(mXe.test(l)||bXe.test(l)||SXe.test(l))return"url("+u+l+u+")";if(l[0]==="/")return"url("+u+(vXe(e)+l)+u+")";var c=e.split("/"),d=l.split("/");c.pop();for(var f=Ur(d),h;!(h=f()).done;){var p=h.value;p!=="."&&(p===".."?c.pop():c.push(p))}return"url("+u+c.join("/")+u+")"})}function PH(t,e){return e===void 0&&(e=!1),e?t.replace(/(\/\*[^*]*\*\/)|[\s;]/g,""):t.replace(/(\/\*[^*]*\*\/)|[\s;]/g,"").replace(/0px/g,"0")}function _Xe(t,e,i){i===void 0&&(i=!1);var n=Array.from(e.childNodes),r=[],o=0;if(n.length>1&&t&&typeof t=="string"){for(var a=PH(t,i),s=a.length/t.length,l=1;l<n.length;l++)if(n[l].textContent&&typeof n[l].textContent=="string"){for(var u=PH(n[l].textContent,i),c=100,d=3;d<u.length&&(u[d].match(/[a-zA-Z0-9]/)||u.indexOf(u.substring(0,d),1)!==-1);d++);for(;d<u.length;d++){var f=u.substring(0,d),h=a.split(f),p=-1;if(h.length===2)p=h[0].length;else if(h.length>2&&h[0]===""&&n[l-1].textContent!=="")p=a.indexOf(f,1);else if(h.length===1){if(f=f.substring(0,f.length-1),h=a.split(f),h.length<=1)return r.push(t),r;d=c+1}else d===u.length-1&&(p=a.indexOf(f));if(h.length>=2&&d>c){var g=n[l-1].textContent;if(g&&typeof g=="string"){var v=PH(g).length;p=a.indexOf(f,v)}p===-1&&(p=h[0].length)}if(p!==-1){for(var y=Math.floor(p/s);y>0&&y<t.length;){if(o+=1,o>50*n.length)return r.push(t),r;var m=PH(t.substring(0,y),i);if(m.length===p){r.push(t.substring(0,y)),t=t.substring(y),a=a.substring(p);break}else m.length<p?y+=Math.max(1,Math.floor((p-m.length)/s)):y-=Math.max(1,Math.floor((m.length-p)*s))}break}}}}return r.push(t),r}function PXe(t,e){return _Xe(t,e).join("/* rr_split */")}var CXe=1,TXe=new RegExp("[^a-z0-9-_:]"),Zj=-2;function uAe(){return CXe++}function xXe(t){if(Ni(t,HTMLFormElement))return"form";var e=TD(t.tagName);return TXe.test(e)?"div":e}var HM,pae,EXe=/^[^ \t\n\r\u000c]+/,wXe=/^[, \t\n\r\u000c]+/;function AXe(t,e){if(e.trim()==="")return e;var i=0;function n(u){var c,d=u.exec(e.substring(i));return d?(c=d[0],i+=c.length,c):""}for(var r=[];n(wXe),!(i>=e.length);){var o=n(EXe);if(o.slice(-1)===",")o=bL(t,o.substring(0,o.length-1)),r.push(o);else{var a="";o=bL(t,o);for(var s=!1;;){var l=e.charAt(i);if(l===""){r.push((o+a).trim());break}else if(s)l===")"&&(s=!1);else if(l===","){i+=1,r.push((o+a).trim());break}else l==="("&&(s=!0);a+=l,i+=1}}}return r.join(", ")}var gae=new WeakMap;function bL(t,e){return!e||e.trim()===""?e:EQ(t,e)}function OXe(t){return!!(t.tagName==="svg"||t.ownerSVGElement)}function EQ(t,e){var i=gae.get(t);if(i||(i=t.createElement("a"),gae.set(t,i)),!e)e="";else if(e.startsWith("blob:")||e.startsWith("data:"))return e;return i.setAttribute("href",e),i.href}function cAe(t,e,i,n){return n&&(i==="src"||i==="href"&&!(e==="use"&&n[0]==="#")||i==="xlink:href"&&n[0]!=="#"||i==="background"&&(e==="table"||e==="td"||e==="th")?bL(t,n):i==="srcset"?AXe(t,n):i==="style"?E5(n,EQ(t)):e==="object"&&i==="data"?bL(t,n):n)}function dAe(t,e,i){return(t==="video"||t==="audio")&&e==="autoplay"}function DXe(t,e,i){try{if(typeof e=="string"){if(t.classList.contains(e))return!0}else for(var n=t.classList.length;n--;){var r=t.classList[n];if(e.test(r))return!0}if(i)return t.matches(i)}catch{}return!1}function w5(t,e,i){if(!t)return!1;if(t.nodeType!==t.ELEMENT_NODE)return i?w5(Bd.parentNode(t),e,i):!1;for(var n=t.classList.length;n--;){var r=t.classList[n];if(e.test(r))return!0}return i?w5(Bd.parentNode(t),e,i):!1}function fAe(t,e,i,n){var r;if(oAe(t)){if(r=t,!Bd.childNodes(r).length)return!1}else{if(Bd.parentElement(t)===null)return!1;r=Bd.parentElement(t)}try{if(typeof e=="string"){if(n){if(r.closest("."+e))return!0}else if(r.classList.contains(e))return!0}else if(w5(r,e,n))return!0;if(i){if(n){if(r.closest(i))return!0}else if(r.matches(i))return!0}}catch{}return!1}function RXe(t,e,i){var n=t.contentWindow;if(n){var r=!1,o;try{o=n.document.readyState}catch{return}if(o!=="complete"){var a=setTimeout(function(){r||(e(),r=!0)},i);t.addEventListener("load",function(){clearTimeout(a),r=!0,e()});return}var s="about:blank";if(n.location.href!==s||t.src===s||t.src==="")return setTimeout(e,0),t.addEventListener("load",e);t.addEventListener("load",e)}}function MXe(t,e,i){var n=!1,r;try{r=t.sheet}catch{return}if(!r){var o=setTimeout(function(){n||(e(),n=!0)},i);t.addEventListener("load",function(){clearTimeout(o),n=!0,e()})}}function LXe(t,e){var i=e.doc,n=e.mirror,r=e.blockClass,o=e.blockSelector,a=e.needsMask,s=e.inlineStylesheet,l=e.maskInputOptions,u=l===void 0?{}:l,c=e.maskTextFn,d=e.maskInputFn,f=e.dataURLOptions,h=f===void 0?{}:f,p=e.inlineImages,g=e.recordCanvas,v=e.keepIframeSrcFn,y=e.newlyAddedElement,m=y===void 0?!1:y,b=e.cssCaptured,S=b===void 0?!1:b,_=kXe(i,n);switch(t.nodeType){case t.DOCUMENT_NODE:return t.compatMode!=="CSS1Compat"?{type:Zu.Document,childNodes:[],compatMode:t.compatMode}:{type:Zu.Document,childNodes:[]};case t.DOCUMENT_TYPE_NODE:return{type:Zu.DocumentType,name:t.name,publicId:t.publicId,systemId:t.systemId,rootId:_};case t.ELEMENT_NODE:return NXe(t,{doc:i,blockClass:r,blockSelector:o,inlineStylesheet:s,maskInputOptions:u,maskInputFn:d,dataURLOptions:h,inlineImages:p,recordCanvas:g,keepIframeSrcFn:v,newlyAddedElement:m,rootId:_});case t.TEXT_NODE:return IXe(t,{doc:i,needsMask:a,maskTextFn:c,rootId:_,cssCaptured:S});case t.CDATA_SECTION_NODE:return{type:Zu.CDATA,textContent:"",rootId:_};case t.COMMENT_NODE:return{type:Zu.Comment,textContent:Bd.textContent(t)||"",rootId:_};default:return!1}}function kXe(t,e){if(e.hasNode(t)){var i=e.getId(t);return i===1?void 0:i}}function IXe(t,e){var i=e.needsMask,n=e.maskTextFn,r=e.rootId,o=e.cssCaptured,a=Bd.parentNode(t),s=a&&a.tagName,l="",u=s==="STYLE"?!0:void 0,c=s==="SCRIPT"?!0:void 0;return c?l="SCRIPT_PLACEHOLDER":o||(l=Bd.textContent(t),u&&l&&(l=E5(l,EQ(e.doc)))),!u&&!c&&l&&i&&(l=n?n(l,Bd.parentElement(t)):l.replace(/[\S]/g,"*")),{type:Zu.Text,textContent:l||"",rootId:r}}function NXe(t,e){for(var i=e.doc,n=e.blockClass,r=e.blockSelector,o=e.inlineStylesheet,a=e.maskInputOptions,s=a===void 0?{}:a,l=e.maskInputFn,u=e.dataURLOptions,c=u===void 0?{}:u,d=e.inlineImages,f=e.recordCanvas,h=e.keepIframeSrcFn,p=e.newlyAddedElement,g=p===void 0?!1:p,v=e.rootId,y=DXe(t,n,r),m=xXe(t),b={},S=t.attributes.length,_=0;_<S;_++){var C=t.attributes[_];dAe(m,C.name,C.value)||(b[C.name]=cAe(i,m,TD(C.name),C.value))}if(m==="link"&&o){var P=Array.from(i.styleSheets).find(function(Y){return Y.href===t.href}),x=null;P&&(x=UX(P)),x&&(delete b.rel,delete b.href,b._cssText=x)}if(m==="style"&&t.sheet){var E=UX(t.sheet);E&&(t.childNodes.length>1&&(E=PXe(E,t)),b._cssText=E)}if(m==="input"||m==="textarea"||m==="select"){var A=t.value,R=t.checked;b.type!=="radio"&&b.type!=="checkbox"&&b.type!=="submit"&&b.type!=="button"&&A?b.value=T5({element:t,type:x5(t),tagName:m,value:A,maskInputOptions:s,maskInputFn:l}):R&&(b.checked=R)}if(m==="option"&&(t.selected&&!s.select?b.selected=!0:delete b.selected),m==="dialog"&&t.open&&(b.rr_open_mode=t.matches("dialog:modal")?"modal":"non-modal"),m==="canvas"&&f){if(t.__context==="2d")gXe(t)||(b.rr_dataURL=t.toDataURL(c.type,c.quality));else if(!("__context"in t)){var M=t.toDataURL(c.type,c.quality),D=i.createElement("canvas");D.width=t.width,D.height=t.height;var F=D.toDataURL(c.type,c.quality);M!==F&&(b.rr_dataURL=M)}}if(m==="img"&&d){HM||(HM=i.createElement("canvas"),pae=HM.getContext("2d"));var I=t,V=I.currentSrc||I.getAttribute("src")||"<unknown-src>",z=I.crossOrigin,G=function(){I.removeEventListener("load",G);try{HM.width=I.naturalWidth,HM.height=I.naturalHeight,pae.drawImage(I,0,0),b.rr_dataURL=HM.toDataURL(c.type,c.quality)}catch(Y){if(I.crossOrigin!=="anonymous"){I.crossOrigin="anonymous",I.complete&&I.naturalWidth!==0?G():I.addEventListener("load",G);return}else console.warn("Cannot inline img src="+V+"! Error: "+Y)}I.crossOrigin==="anonymous"&&(z?b.crossOrigin=z:I.removeAttribute("crossorigin"))};I.complete&&I.naturalWidth!==0?G():I.addEventListener("load",G)}if(m==="audio"||m==="video"){var H=b;H.rr_mediaState=t.paused?"paused":"played",H.rr_mediaCurrentTime=t.currentTime,H.rr_mediaPlaybackRate=t.playbackRate,H.rr_mediaMuted=t.muted,H.rr_mediaLoop=t.loop,H.rr_mediaVolume=t.volume}if(g||(t.scrollLeft&&(b.rr_scrollLeft=t.scrollLeft),t.scrollTop&&(b.rr_scrollTop=t.scrollTop)),y){var U=t.getBoundingClientRect(),k=U.width,X=U.height;b={class:b.class,rr_width:""+k+"px",rr_height:""+X+"px"}}m==="iframe"&&!h(b.src)&&(t.contentDocument||(b.rr_src=b.src),delete b.src);var W;try{customElements.get(m)&&(W=!0)}catch{}return{type:Zu.Element,tagName:m,attributes:b,childNodes:[],isSVG:OXe(t)||void 0,needBlock:y,rootId:v,isCustom:W}}function cs(t){return t==null?"":t.toLowerCase()}function FXe(t,e){if(e.comment&&t.type===Zu.Comment)return!0;if(t.type===Zu.Element){if(e.script&&(t.tagName==="script"||t.tagName==="link"&&(t.attributes.rel==="preload"&&t.attributes.as==="script"||t.attributes.rel==="modulepreload")||t.tagName==="link"&&t.attributes.rel==="prefetch"&&typeof t.attributes.href=="string"&&lAe(t.attributes.href)==="js"))return!0;if(e.headFavicon&&(t.tagName==="link"&&t.attributes.rel==="shortcut icon"||t.tagName==="meta"&&(cs(t.attributes.name).match(/^msapplication-tile(image|color)$/)||cs(t.attributes.name)==="application-name"||cs(t.attributes.rel)==="icon"||cs(t.attributes.rel)==="apple-touch-icon"||cs(t.attributes.rel)==="shortcut icon")))return!0;if(t.tagName==="meta"){if(e.headMetaDescKeywords&&cs(t.attributes.name).match(/^description|keywords$/))return!0;if(e.headMetaSocial&&(cs(t.attributes.property).match(/^(og|twitter|fb):/)||cs(t.attributes.name).match(/^(og|twitter):/)||cs(t.attributes.name)==="pinterest"))return!0;if(e.headMetaRobots&&(cs(t.attributes.name)==="robots"||cs(t.attributes.name)==="googlebot"||cs(t.attributes.name)==="bingbot"))return!0;if(e.headMetaHttpEquiv&&t.attributes["http-equiv"]!==void 0)return!0;if(e.headMetaAuthorship&&(cs(t.attributes.name)==="author"||cs(t.attributes.name)==="generator"||cs(t.attributes.name)==="framework"||cs(t.attributes.name)==="publisher"||cs(t.attributes.name)==="progid"||cs(t.attributes.property).match(/^article:/)||cs(t.attributes.property).match(/^product:/)))return!0;if(e.headMetaVerification&&(cs(t.attributes.name)==="google-site-verification"||cs(t.attributes.name)==="yandex-verification"||cs(t.attributes.name)==="csrf-token"||cs(t.attributes.name)==="p:domain_verify"||cs(t.attributes.name)==="verify-v1"||cs(t.attributes.name)==="verification"||cs(t.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function SL(t,e){var i=e.doc,n=e.mirror,r=e.blockClass,o=e.blockSelector,a=e.maskTextClass,s=e.maskTextSelector,l=e.skipChild,u=l===void 0?!1:l,c=e.inlineStylesheet,d=c===void 0?!0:c,f=e.maskInputOptions,h=f===void 0?{}:f,p=e.maskTextFn,g=e.maskInputFn,v=e.slimDOMOptions,y=e.dataURLOptions,m=y===void 0?{}:y,b=e.inlineImages,S=b===void 0?!1:b,_=e.recordCanvas,C=_===void 0?!1:_,P=e.onSerialize,x=e.onIframeLoad,E=e.iframeLoadTimeout,A=E===void 0?5e3:E,R=e.onStylesheetLoad,M=e.stylesheetLoadTimeout,D=M===void 0?5e3:M,F=e.keepIframeSrcFn,I=F===void 0?function(){return!1}:F,V=e.newlyAddedElement,z=V===void 0?!1:V,G=e.cssCaptured,H=G===void 0?!1:G,U=e.needsMask,k=e.preserveWhiteSpace,X=k===void 0?!0:k;if(!U){var W=U===void 0;U=fAe(t,a,s,W)}var Y=LXe(t,{doc:i,mirror:n,blockClass:r,blockSelector:o,needsMask:U,inlineStylesheet:d,maskInputOptions:h,maskTextFn:p,maskInputFn:g,dataURLOptions:m,inlineImages:S,recordCanvas:C,keepIframeSrcFn:I,newlyAddedElement:z,cssCaptured:H});if(!Y)return console.warn(t,"not serialized"),null;var te;n.hasNode(t)?te=n.getId(t):FXe(Y,v)||!X&&Y.type===Zu.Text&&!Y.textContent.replace(/^\s+|\s+$/gm,"").length?te=Zj:te=uAe();var oe=Object.assign(Y,{id:te});if(n.add(t,oe),te===Zj)return null;P&&P(t);var de=!u;if(oe.type===Zu.Element){de=de&&!oe.needBlock,delete oe.needBlock;var ge=Bd.shadowRoot(t);ge&&bj(ge)&&(oe.isShadowHost=!0)}if((oe.type===Zu.Document||oe.type===Zu.Element)&&de){v.headWhitespace&&oe.type===Zu.Element&&oe.tagName==="head"&&(X=!1);var Ee={doc:i,mirror:n,blockClass:r,blockSelector:o,needsMask:U,maskTextClass:a,maskTextSelector:s,skipChild:u,inlineStylesheet:d,maskInputOptions:h,maskTextFn:p,maskInputFn:g,slimDOMOptions:v,dataURLOptions:m,inlineImages:S,recordCanvas:C,preserveWhiteSpace:X,onSerialize:P,onIframeLoad:x,iframeLoadTimeout:A,onStylesheetLoad:R,stylesheetLoadTimeout:D,keepIframeSrcFn:I,cssCaptured:!1};if(!(oe.type===Zu.Element&&oe.tagName==="textarea"&&oe.attributes.value!==void 0)){oe.type===Zu.Element&&oe.attributes._cssText!==void 0&&typeof oe.attributes._cssText=="string"&&(Ee.cssCaptured=!0);for(var Re=Ur(Array.from(Bd.childNodes(t))),Ae;!(Ae=Re()).done;){var Pe=Ae.value,we=SL(Pe,Ee);we&&oe.childNodes.push(we)}}var Te=null;if(oAe(t)&&(Te=Bd.shadowRoot(t)))for(var ke=Ur(Array.from(Bd.childNodes(Te))),$e;!($e=ke()).done;){var Ne=$e.value,ve=SL(Ne,Ee);ve&&(bj(Te)&&(ve.isShadow=!0),oe.childNodes.push(ve))}}var pe=Bd.parentNode(t);return pe&&mj(pe)&&bj(pe)&&(oe.isShadow=!0),oe.type===Zu.Element&&oe.tagName==="iframe"&&RXe(t,function(){var fe=t.contentDocument;if(fe&&x){var me=SL(fe,{doc:fe,mirror:n,blockClass:r,blockSelector:o,needsMask:U,maskTextClass:a,maskTextSelector:s,skipChild:!1,inlineStylesheet:d,maskInputOptions:h,maskTextFn:p,maskInputFn:g,slimDOMOptions:v,dataURLOptions:m,inlineImages:S,recordCanvas:C,preserveWhiteSpace:X,onSerialize:P,onIframeLoad:x,iframeLoadTimeout:A,onStylesheetLoad:R,stylesheetLoadTimeout:D,keepIframeSrcFn:I});me&&x(t,me)}},A),oe.type===Zu.Element&&oe.tagName==="link"&&typeof oe.attributes.rel=="string"&&(oe.attributes.rel==="stylesheet"||oe.attributes.rel==="preload"&&typeof oe.attributes.href=="string"&&lAe(oe.attributes.href)==="css")&&MXe(t,function(){if(R){var fe=SL(t,{doc:i,mirror:n,blockClass:r,blockSelector:o,needsMask:U,maskTextClass:a,maskTextSelector:s,skipChild:!1,inlineStylesheet:d,maskInputOptions:h,maskTextFn:p,maskInputFn:g,slimDOMOptions:v,dataURLOptions:m,inlineImages:S,recordCanvas:C,preserveWhiteSpace:X,onSerialize:P,onIframeLoad:x,iframeLoadTimeout:A,onStylesheetLoad:R,stylesheetLoadTimeout:D,keepIframeSrcFn:I});fe&&R(t,fe)}},D),oe}function BXe(t,e){var i=e||{},n=i.mirror,r=n===void 0?new sAe:n,o=i.blockClass,a=o===void 0?"rr-block":o,s=i.blockSelector,l=s===void 0?null:s,u=i.maskTextClass,c=u===void 0?"rr-mask":u,d=i.maskTextSelector,f=d===void 0?null:d,h=i.inlineStylesheet,p=h===void 0?!0:h,g=i.inlineImages,v=g===void 0?!1:g,y=i.recordCanvas,m=y===void 0?!1:y,b=i.maskAllInputs,S=b===void 0?!1:b,_=i.maskTextFn,C=i.maskInputFn,P=i.slimDOM,x=P===void 0?!1:P,E=i.dataURLOptions,A=i.preserveWhiteSpace,R=i.onSerialize,M=i.onIframeLoad,D=i.iframeLoadTimeout,F=i.onStylesheetLoad,I=i.stylesheetLoadTimeout,V=i.keepIframeSrcFn,z=V===void 0?function(){return!1}:V,G=S===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0,hidden:!0}:S===!1?{password:!0}:S,H=x===!0||x==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:x==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:x===!1?{}:x;return SL(t,{doc:t,mirror:r,blockClass:a,blockSelector:l,maskTextClass:c,maskTextSelector:f,skipChild:!1,inlineStylesheet:p,maskInputOptions:G,maskTextFn:_,maskInputFn:C,slimDOMOptions:H,dataURLOptions:E,inlineImages:v,recordCanvas:m,preserveWhiteSpace:A,onSerialize:R,onIframeLoad:M,iframeLoadTimeout:D,onStylesheetLoad:F,stylesheetLoadTimeout:I,keepIframeSrcFn:z,newlyAddedElement:!1})}function jXe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function VXe(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var i=function n(){return Ni(this,n)?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(i,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}),i}var wQ={exports:{}},Es=String,hAe=function(){return{isColorSupported:!1,reset:Es,bold:Es,dim:Es,italic:Es,underline:Es,inverse:Es,hidden:Es,strikethrough:Es,black:Es,red:Es,green:Es,yellow:Es,blue:Es,magenta:Es,cyan:Es,white:Es,gray:Es,bgBlack:Es,bgRed:Es,bgGreen:Es,bgYellow:Es,bgBlue:Es,bgMagenta:Es,bgCyan:Es,bgWhite:Es}};wQ.exports=hAe();wQ.exports.createColors=hAe;var HXe=wQ.exports,UXe={},zXe=Object.freeze(Object.defineProperty({__proto__:null,default:UXe},Symbol.toStringTag,{value:"Module"})),ou=VXe(zXe),vae=HXe,yae=ou,zX=(function(t){Ks(e,t);function e(n,r,o,a,s,l){var u;return u=t.call(this,n)||this,u.name="CssSyntaxError",u.reason=n,s&&(u.file=s),a&&(u.source=a),l&&(u.plugin=l),typeof r<"u"&&typeof o<"u"&&(typeof r=="number"?(u.line=r,u.column=o):(u.line=r.line,u.column=r.column,u.endLine=o.line,u.endColumn=o.column)),u.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(u,e),u}var i=e.prototype;return i.setMessage=function(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason},i.showSourceCode=function(r){var o=this;if(!this.source)return"";var a=this.source;r==null&&(r=vae.isColorSupported),yae&&r&&(a=yae(a));var s=a.split(/\r?\n/),l=Math.max(this.line-3,0),u=Math.min(this.line+2,s.length),c=String(u).length,d,f;if(r){var h=vae.createColors(!0),p=h.bold,g=h.gray,v=h.red;d=function(y){return p(v(y))},f=function(y){return g(y)}}else d=f=function(y){return y};return s.slice(l,u).map(function(y,m){var b=l+1+m,S=" "+(" "+b).slice(-c)+" | ";if(b===o.line){var _=f(S.replace(/\d/g," "))+y.slice(0,o.column-1).replace(/[^\t]/g," ");return d(">")+f(S)+y+`
 `+_+d("^")}return" "+f(S)+y}).join(`
`)},i.toString=function(){var r=this.showSourceCode();return r&&(r=`

`+r+`
`),this.name+": "+this.message+r},e})(Kj(Error)),AQ=zX;zX.default=zX;var IP={};IP.isClean=Symbol("isClean");IP.my=Symbol("my");var mae={after:`
`,beforeClose:`
`,beforeComment:`
`,beforeDecl:`
`,beforeOpen:" ",beforeRule:`
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:"    ",semicolon:!1};function $Xe(t){return t[0].toUpperCase()+t.slice(1)}var $X=(function(){function t(i){this.builder=i}var e=t.prototype;return e.atrule=function(n,r){var o="@"+n.name,a=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?o+=n.raws.afterName:a&&(o+=" "),n.nodes)this.block(n,o+a);else{var s=(n.raws.between||"")+(r?";":"");this.builder(o+a+s,n)}},e.beforeAfter=function(n,r){var o;n.type==="decl"?o=this.raw(n,null,"beforeDecl"):n.type==="comment"?o=this.raw(n,null,"beforeComment"):r==="before"?o=this.raw(n,null,"beforeRule"):o=this.raw(n,null,"beforeClose");for(var a=n.parent,s=0;a&&a.type!=="root";)s+=1,a=a.parent;if(o.includes(`
`)){var l=this.raw(n,null,"indent");if(l.length)for(var u=0;u<s;u++)o+=l}return o},e.block=function(n,r){var o=this.raw(n,"between","beforeOpen");this.builder(r+o+"{",n,"start");var a;n.nodes&&n.nodes.length?(this.body(n),a=this.raw(n,"after")):a=this.raw(n,"after","emptyBody"),a&&this.builder(a),this.builder("}",n,"end")},e.body=function(n){for(var r=n.nodes.length-1;r>0&&n.nodes[r].type==="comment";)r-=1;for(var o=this.raw(n,"semicolon"),a=0;a<n.nodes.length;a++){var s=n.nodes[a],l=this.raw(s,"before");l&&this.builder(l),this.stringify(s,r!==a||o)}},e.comment=function(n){var r=this.raw(n,"left","commentLeft"),o=this.raw(n,"right","commentRight");this.builder("/*"+r+n.text+o+"*/",n)},e.decl=function(n,r){var o=this.raw(n,"between","colon"),a=n.prop+o+this.rawValue(n,"value");n.important&&(a+=n.raws.important||" !important"),r&&(a+=";"),this.builder(a,n)},e.document=function(n){this.body(n)},e.raw=function(n,r,o){var a;if(o||(o=r),r&&(a=n.raws[r],typeof a<"u"))return a;var s=n.parent;if(o==="before"&&(!s||s.type==="root"&&s.first===n||s&&s.type==="document"))return"";if(!s)return mae[o];var l=n.root();if(l.rawCache||(l.rawCache={}),typeof l.rawCache[o]<"u")return l.rawCache[o];if(o==="before"||o==="after")return this.beforeAfter(n,o);var u="raw"+$Xe(o);return this[u]?a=this[u](l,n):l.walk(function(c){if(a=c.raws[r],typeof a<"u")return!1}),typeof a>"u"&&(a=mae[o]),l.rawCache[o]=a,a},e.rawBeforeClose=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length>0&&typeof o.raws.after<"u")return r=o.raws.after,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawBeforeComment=function(n,r){var o;return n.walkComments(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeDecl"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeDecl=function(n,r){var o;return n.walkDecls(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeRule"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeOpen=function(n){var r;return n.walk(function(o){if(o.type!=="decl"&&(r=o.raws.between,typeof r<"u"))return!1}),r},e.rawBeforeRule=function(n){var r;return n.walk(function(o){if(o.nodes&&(o.parent!==n||n.first!==o)&&typeof o.raws.before<"u")return r=o.raws.before,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawColon=function(n){var r;return n.walkDecls(function(o){if(typeof o.raws.between<"u")return r=o.raws.between.replace(/[^\s:]/g,""),!1}),r},e.rawEmptyBody=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length===0&&(r=o.raws.after,typeof r<"u"))return!1}),r},e.rawIndent=function(n){if(n.raws.indent)return n.raws.indent;var r;return n.walk(function(o){var a=o.parent;if(a&&a!==n&&a.parent&&a.parent===n&&typeof o.raws.before<"u"){var s=o.raws.before.split(`
`);return r=s[s.length-1],r=r.replace(/\S/g,""),!1}}),r},e.rawSemicolon=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length&&o.last.type==="decl"&&(r=o.raws.semicolon,typeof r<"u"))return!1}),r},e.rawValue=function(n,r){var o=n[r],a=n.raws[r];return a&&a.value===o?a.raw:o},e.root=function(n){this.body(n),n.raws.after&&this.builder(n.raws.after)},e.rule=function(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end")},e.stringify=function(n,r){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,r)},t})(),pAe=$X;$X.default=$X;var WXe=pAe;function WX(t,e){var i=new WXe(e);i.stringify(t)}var z$=WX;WX.default=WX;var CH=IP.isClean,GXe=IP.my,YXe=AQ,qXe=pAe,XXe=z$;function GX(t,e){var i=new t.constructor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&n!=="proxyCache"){var r=t[n],o=typeof r>"u"?"undefined":Ui(r);n==="parent"&&o==="object"?e&&(i[n]=e):n==="source"?i[n]=r:Array.isArray(r)?i[n]=r.map(function(a){return GX(a,i)}):(o==="object"&&r!==null&&(r=GX(r)),i[n]=r)}return i}var YX=(function(){function t(i){i===void 0&&(i={}),this.raws={},this[CH]=!1,this[GXe]=!0;for(var n in i)if(n==="nodes"){this.nodes=[];for(var r=Ur(i[n]),o;!(o=r()).done;){var a=o.value;typeof a.clone=="function"?this.append(a.clone()):this.append(a)}}else this[n]=i[n]}var e=t.prototype;return e.addToError=function(n){if(n.postcssNode=this,n.stack&&this.source&&/\n\s{4}at /.test(n.stack)){var r=this.source;n.stack=n.stack.replace(/\n\s{4}at /,"$&"+r.input.from+":"+r.start.line+":"+r.start.column+"$&")}return n},e.after=function(n){return this.parent.insertAfter(this,n),this},e.assign=function(n){n===void 0&&(n={});for(var r in n)this[r]=n[r];return this},e.before=function(n){return this.parent.insertBefore(this,n),this},e.cleanRaws=function(n){delete this.raws.before,delete this.raws.after,n||delete this.raws.between},e.clone=function(n){n===void 0&&(n={});var r=GX(this);for(var o in n)r[o]=n[o];return r},e.cloneAfter=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertAfter(this,r),r},e.cloneBefore=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertBefore(this,r),r},e.error=function(n,r){if(r===void 0&&(r={}),this.source){var o=this.rangeBy(r),a=o.end,s=o.start;return this.source.input.error(n,{column:s.column,line:s.line},{column:a.column,line:a.line},r)}return new YXe(n)},e.getProxyProcessor=function(){return{get:function(r,o){return o==="proxyOf"?r:o==="root"?function(){return r.root().toProxy()}:r[o]},set:function(r,o,a){return r[o]===a||(r[o]=a,(o==="prop"||o==="value"||o==="name"||o==="params"||o==="important"||o==="text")&&r.markDirty()),!0}}},e.markDirty=function(){if(this[CH]){this[CH]=!1;for(var n=this;n=n.parent;)n[CH]=!1}},e.next=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n+1]}},e.positionBy=function(n,r){var o=this.source.start;if(n.index)o=this.positionInside(n.index,r);else if(n.word){r=this.toString();var a=r.indexOf(n.word);a!==-1&&(o=this.positionInside(a,r))}return o},e.positionInside=function(n,r){for(var o=r||this.toString(),a=this.source.start.column,s=this.source.start.line,l=0;l<n;l++)o[l]===`
`?(a=1,s+=1):a+=1;return{column:a,line:s}},e.prev=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n-1]}},e.rangeBy=function(n){var r={column:this.source.start.column,line:this.source.start.line},o=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(n.word){var a=this.toString(),s=a.indexOf(n.word);s!==-1&&(r=this.positionInside(s,a),o=this.positionInside(s+n.word.length,a))}else n.start?r={column:n.start.column,line:n.start.line}:n.index&&(r=this.positionInside(n.index)),n.end?o={column:n.end.column,line:n.end.line}:typeof n.endIndex=="number"?o=this.positionInside(n.endIndex):n.index&&(o=this.positionInside(n.index+1));return(o.line<r.line||o.line===r.line&&o.column<=r.column)&&(o={column:r.column+1,line:r.line}),{end:o,start:r}},e.raw=function(n,r){var o=new qXe;return o.raw(this,n,r)},e.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},e.replaceWith=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];if(this.parent){for(var a=this,s=!1,l=Ur(r),u;!(u=l()).done;){var c=u.value;c===this?s=!0:s?(this.parent.insertAfter(a,c),a=c):this.parent.insertBefore(a,c)}s||this.remove()}return this},e.root=function(){for(var n=this;n.parent&&n.parent.type!=="document";)n=n.parent;return n},e.toJSON=function(n,r){var o={},a=r==null;r=r||new Map;var s=0;for(var l in this)if(Object.prototype.hasOwnProperty.call(this,l)&&!(l==="parent"||l==="proxyCache")){var u=this[l];if(Array.isArray(u))o[l]=u.map(function(d){return(typeof d>"u"?"undefined":Ui(d))==="object"&&d.toJSON?d.toJSON(null,r):d});else if((typeof u>"u"?"undefined":Ui(u))==="object"&&u.toJSON)o[l]=u.toJSON(null,r);else if(l==="source"){var c=r.get(u.input);c==null&&(c=s,r.set(u.input,s),s++),o[l]={end:u.end,inputId:c,start:u.start}}else o[l]=u}return a&&(o.inputs=[].concat(r.keys()).map(function(d){return d.toJSON()})),o},e.toProxy=function(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache},e.toString=function(n){n===void 0&&(n=XXe),n.stringify&&(n=n.stringify);var r="";return n(this,function(o){r+=o}),r},e.warn=function(n,r,o){var a={node:this};for(var s in o)a[s]=o[s];return n.warn(r,a)},Is(t,[{key:"proxyOf",get:function(){return this}}]),t})(),$$=YX;YX.default=YX;var KXe=$$,qX=(function(t){Ks(e,t);function e(i){var n;return i&&typeof i.value<"u"&&typeof i.value!="string"&&(i=Zn({},i,{value:String(i.value)})),n=t.call(this,i)||this,n.type="decl",n}return Is(e,[{key:"variable",get:function(){return this.prop.startsWith("--")||this.prop[0]==="$"}}]),e})(KXe),W$=qX;qX.default=qX;var ZXe="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",JXe=function(t){t===void 0&&(t=21);for(var e="",i=t;i--;)e+=ZXe[Math.random()*64|0];return e},QXe={nanoid:JXe},bae=ou.SourceMapConsumer,Sae=ou.SourceMapGenerator,eKe=ou.existsSync,tKe=ou.readFileSync,n8=ou.dirname,rKe=ou.join;function iKe(t){return Buffer?Buffer.from(t,"base64").toString():window.atob(t)}var XX=(function(){function t(i,n){if(n.map!==!1){this.loadAnnotation(i),this.inline=this.startWith(this.annotation,"data:");var r=n.map?n.map.prev:void 0,o=this.loadMap(n.from,r);!this.mapFile&&n.from&&(this.mapFile=n.from),this.mapFile&&(this.root=n8(this.mapFile)),o&&(this.text=o)}}var e=t.prototype;return e.consumer=function(){return this.consumerCache||(this.consumerCache=new bae(this.text)),this.consumerCache},e.decodeInline=function(n){var r=/^data:application\/json;charset=utf-?8;base64,/,o=/^data:application\/json;base64,/,a=/^data:application\/json;charset=utf-?8,/,s=/^data:application\/json,/;if(a.test(n)||s.test(n))return decodeURIComponent(n.substr(RegExp.lastMatch.length));if(r.test(n)||o.test(n))return iKe(n.substr(RegExp.lastMatch.length));var l=n.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+l)},e.getAnnotationURL=function(n){return n.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()},e.isMap=function(n){return(typeof n>"u"?"undefined":Ui(n))!=="object"?!1:typeof n.mappings=="string"||typeof n._mappings=="string"||Array.isArray(n.sections)},e.loadAnnotation=function(n){var r=n.match(/\/\*\s*# sourceMappingURL=/gm);if(r){var o=n.lastIndexOf(r.pop()),a=n.indexOf("*/",o);o>-1&&a>-1&&(this.annotation=this.getAnnotationURL(n.substring(o,a)))}},e.loadFile=function(n){if(this.root=n8(n),eKe(n))return this.mapFile=n,tKe(n,"utf-8").toString().trim()},e.loadMap=function(n,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){var o=r(n);if(o){var a=this.loadFile(o);if(!a)throw new Error("Unable to load previous source map: "+o.toString());return a}}else{if(Ni(r,bae))return Sae.fromSourceMap(r).toString();if(Ni(r,Sae))return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){var s=this.annotation;return n&&(s=rKe(n8(n),s)),this.loadFile(s)}}},e.startWith=function(n,r){return n?n.substr(0,r.length)===r:!1},e.withContent=function(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)},t})(),gAe=XX;XX.default=XX;var nKe=ou.SourceMapConsumer,oKe=ou.SourceMapGenerator,_ae=ou.fileURLToPath,TH=ou.pathToFileURL,KX=ou.isAbsolute,ZX=ou.resolve,aKe=QXe.nanoid,o8=ou,Pae=AQ,sKe=gAe,a8=Symbol("fromOffsetCache"),lKe=!!(nKe&&oKe),Cae=!!(ZX&&KX),A5=(function(){function t(i,n){if(n===void 0&&(n={}),i===null||typeof i>"u"||(typeof i>"u"?"undefined":Ui(i))==="object"&&!i.toString)throw new Error("PostCSS received "+i+" instead of CSS string");if(this.css=i.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,n.from&&(!Cae||/^\w+:\/\//.test(n.from)||KX(n.from)?this.file=n.from:this.file=ZX(n.from)),Cae&&lKe){var r=new sKe(this.css,n);if(r.text){this.map=r;var o=r.consumer().file;!this.file&&o&&(this.file=this.mapResolve(o))}}this.file||(this.id="<input css "+aKe(6)+">"),this.map&&(this.map.file=this.from)}var e=t.prototype;return e.error=function(n,r,o,a){a===void 0&&(a={});var s,l,u;if(r&&(typeof r>"u"?"undefined":Ui(r))==="object"){var c=r,d=o;if(typeof c.offset=="number"){var f=this.fromOffset(c.offset);r=f.line,o=f.col}else r=c.line,o=c.column;if(typeof d.offset=="number"){var h=this.fromOffset(d.offset);l=h.line,u=h.col}else l=d.line,u=d.column}else if(!o){var p=this.fromOffset(r);r=p.line,o=p.col}var g=this.origin(r,o,l,u);return g?s=new Pae(n,g.endLine===void 0?g.line:{column:g.column,line:g.line},g.endLine===void 0?g.column:{column:g.endColumn,line:g.endLine},g.source,g.file,a.plugin):s=new Pae(n,l===void 0?r:{column:o,line:r},l===void 0?o:{column:u,line:l},this.css,this.file,a.plugin),s.input={column:o,endColumn:u,endLine:l,line:r,source:this.css},this.file&&(TH&&(s.input.url=TH(this.file).toString()),s.input.file=this.file),s},e.fromOffset=function(n){var r,o;if(this[a8])o=this[a8];else{var a=this.css.split(`
`);o=new Array(a.length);for(var s=0,l=0,u=a.length;l<u;l++)o[l]=s,s+=a[l].length+1;this[a8]=o}r=o[o.length-1];var c=0;if(n>=r)c=o.length-1;else for(var d=o.length-2,f;c<d;)if(f=c+(d-c>>1),n<o[f])d=f-1;else if(n>=o[f+1])c=f+1;else{c=f;break}return{col:n-o[c]+1,line:c+1}},e.mapResolve=function(n){return/^\w+:\/\//.test(n)?n:ZX(this.map.consumer().sourceRoot||this.map.root||".",n)},e.origin=function(n,r,o,a){if(!this.map)return!1;var s=this.map.consumer(),l=s.originalPositionFor({column:r,line:n});if(!l.source)return!1;var u;typeof o=="number"&&(u=s.originalPositionFor({column:a,line:o}));var c;KX(l.source)?c=TH(l.source):c=new URL(l.source,this.map.consumer().sourceRoot||TH(this.map.mapFile));var d={column:l.column,endColumn:u&&u.column,endLine:u&&u.line,line:l.line,url:c.toString()};if(c.protocol==="file:")if(_ae)d.file=_ae(c);else throw new Error("file: protocol is not available in this PostCSS build");var f=s.sourceContentFor(l.source);return f&&(d.source=f),d},e.toJSON=function(){for(var n={},r=0,o=["hasBOM","css","file","id"];r<o.length;r++){var a=o[r];this[a]!=null&&(n[a]=this[a])}return this.map&&(n.map=Zn({},this.map),n.map.consumerCache&&(n.map.consumerCache=void 0)),n},Is(t,[{key:"from",get:function(){return this.file||this.id}}]),t})(),G$=A5;A5.default=A5;o8&&o8.registerInput&&o8.registerInput(A5);var vAe=ou.SourceMapConsumer,DU=ou.SourceMapGenerator,RU=ou.dirname,yAe=ou.relative,mAe=ou.resolve,bAe=ou.sep,Tae=ou.pathToFileURL,uKe=G$,cKe=!!(vAe&&DU),dKe=!!(RU&&mAe&&yAe&&bAe),fKe=(function(){function t(i,n,r,o){this.stringify=i,this.mapOpts=r.map||{},this.root=n,this.opts=r,this.css=o,this.originalCSS=o,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}var e=t.prototype;return e.addAnnotation=function(){var n;this.isInline()?n="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?n=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?n=this.mapOpts.annotation(this.opts.to,this.root):n=this.outputFile()+".map";var r=`
`;this.css.includes(`\r
`)&&(r=`\r
`),this.css+=r+"/*# sourceMappingURL="+n+" */"},e.applyPrevMaps=function(){for(var n=Ur(this.previous()),r;!(r=n()).done;){var o=r.value,a=this.toUrl(this.path(o.file)),s=o.root||RU(o.file),l=void 0;this.mapOpts.sourcesContent===!1?(l=new vAe(o.text),l.sourcesContent&&(l.sourcesContent=null)):l=o.consumer(),this.map.applySourceMap(l,a,this.toUrl(this.path(s)))}},e.clearAnnotation=function(){if(this.mapOpts.annotation!==!1)if(this.root)for(var n,r=this.root.nodes.length-1;r>=0;r--)n=this.root.nodes[r],n.type==="comment"&&n.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(r);else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))},e.generate=function(){if(this.clearAnnotation(),dKe&&cKe&&this.isMap())return this.generateMap();var n="";return this.stringify(this.root,function(r){n+=r}),[n]},e.generateMap=function(){if(this.root)this.generateString();else if(this.previous().length===1){var n=this.previous()[0].consumer();n.file=this.outputFile(),this.map=DU.fromSourceMap(n,{ignoreInvalidMapping:!0})}else this.map=new DU({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]},e.generateString=function(){var n=this;this.css="",this.map=new DU({file:this.outputFile(),ignoreInvalidMapping:!0});var r=1,o=1,a="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},l,u;this.stringify(this.root,function(c,d,f){if(n.css+=c,d&&f!=="end"&&(s.generated.line=r,s.generated.column=o-1,d.source&&d.source.start?(s.source=n.sourcePath(d),s.original.line=d.source.start.line,s.original.column=d.source.start.column-1,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,n.map.addMapping(s))),l=c.match(/\n/g),l?(r+=l.length,u=c.lastIndexOf(`
`),o=c.length-u):o+=c.length,d&&f!=="start"){var h=d.parent||{raws:{}},p=d.type==="decl"||d.type==="atrule"&&!d.nodes;(!p||d!==h.last||h.raws.semicolon)&&(d.source&&d.source.end?(s.source=n.sourcePath(d),s.original.line=d.source.end.line,s.original.column=d.source.end.column-1,s.generated.line=r,s.generated.column=o-2,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,s.generated.line=r,s.generated.column=o-1,n.map.addMapping(s)))}})},e.isAnnotation=function(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(function(n){return n.annotation}):!0},e.isInline=function(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;var n=this.mapOpts.annotation;return typeof n<"u"&&n!==!0?!1:this.previous().length?this.previous().some(function(r){return r.inline}):!0},e.isMap=function(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0},e.isSourcesContent=function(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(function(n){return n.withContent()}):!0},e.outputFile=function(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"},e.path=function(n){if(this.mapOpts.absolute||n.charCodeAt(0)===60||/^\w+:\/\//.test(n))return n;var r=this.memoizedPaths.get(n);if(r)return r;var o=this.opts.to?RU(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(o=RU(mAe(o,this.mapOpts.annotation)));var a=yAe(o,n);return this.memoizedPaths.set(n,a),a},e.previous=function(){var n=this;if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(function(o){if(o.source&&o.source.input.map){var a=o.source.input.map;n.previousMaps.includes(a)||n.previousMaps.push(a)}});else{var r=new uKe(this.originalCSS,this.opts);r.map&&this.previousMaps.push(r.map)}return this.previousMaps},e.setSourcesContent=function(){var n=this,r={};if(this.root)this.root.walk(function(a){if(a.source){var s=a.source.input.from;if(s&&!r[s]){r[s]=!0;var l=n.usesFileUrls?n.toFileUrl(s):n.toUrl(n.path(s));n.map.setSourceContent(l,a.source.input.css)}}});else if(this.css){var o=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(o,this.css)}},e.sourcePath=function(n){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(n.source.input.from):this.toUrl(this.path(n.source.input.from))},e.toBase64=function(n){return Buffer?Buffer.from(n).toString("base64"):window.btoa(unescape(encodeURIComponent(n)))},e.toFileUrl=function(n){var r=this.memoizedFileURLs.get(n);if(r)return r;if(Tae){var o=Tae(n).toString();return this.memoizedFileURLs.set(n,o),o}else throw new Error("`map.absolute` option is not available in this PostCSS build")},e.toUrl=function(n){var r=this.memoizedURLs.get(n);if(r)return r;bAe==="\\"&&(n=n.replace(/\\/g,"/"));var o=encodeURI(n).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(n,o),o},t})(),SAe=fKe,hKe=$$,JX=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="comment",n}return e})(hKe),Y$=JX;JX.default=JX;var _Ae=IP.isClean,PAe=IP.my,CAe=W$,TAe=Y$,pKe=$$,xAe,OQ,DQ,EAe;function wAe(t){return t.map(function(e){return e.nodes&&(e.nodes=wAe(e.nodes)),delete e.source,e})}function AAe(t){if(t[_Ae]=!1,t.proxyOf.nodes)for(var e=Ur(t.proxyOf.nodes),i;!(i=e()).done;){var n=i.value;AAe(n)}}var CS=(function(t){Ks(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];for(var s=Ur(o),l;!(l=s()).done;)for(var u=l.value,c=this.normalize(u,this.last),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.push(h)}return this.markDirty(),this},i.cleanRaws=function(r){if(t.prototype.cleanRaws.call(this,r),this.nodes)for(var o=Ur(this.nodes),a;!(a=o()).done;){var s=a.value;s.cleanRaws(r)}},i.each=function(r){if(this.proxyOf.nodes){for(var o=this.getIterator(),a,s;this.indexes[o]<this.proxyOf.nodes.length&&(a=this.indexes[o],s=r(this.proxyOf.nodes[a],a),s!==!1);)this.indexes[o]+=1;return delete this.indexes[o],s}},i.every=function(r){return this.nodes.every(r)},i.getIterator=function(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;var r=this.lastEach;return this.indexes[r]=0,r},i.getProxyProcessor=function(){return{get:function(o,a){return a==="proxyOf"?o:o[a]?a==="each"||typeof a=="string"&&a.startsWith("walk")?function(){for(var s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];var c;return(c=o)[a].apply(c,[].concat(l.map(function(d){return typeof d=="function"?function(f,h){return d(f.toProxy(),h)}:d})))}:a==="every"||a==="some"?function(s){return o[a](function(l){for(var u=arguments.length,c=new Array(u>1?u-1:0),d=1;d<u;d++)c[d-1]=arguments[d];return s.apply(void 0,[].concat([l.toProxy()],c))})}:a==="root"?function(){return o.root().toProxy()}:a==="nodes"?o.nodes.map(function(s){return s.toProxy()}):a==="first"||a==="last"?o[a].toProxy():o[a]:o[a]},set:function(o,a,s){return o[a]===s||(o[a]=s,(a==="name"||a==="params"||a==="selector")&&o.markDirty()),!0}}},i.index=function(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))},i.insertAfter=function(r,o){var a=this.index(r),s=this.normalize(o,this.proxyOf.nodes[a]).reverse();a=this.index(r);for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;this.proxyOf.nodes.splice(a+1,0,c)}var d;for(var f in this.indexes)d=this.indexes[f],a<d&&(this.indexes[f]=d+s.length);return this.markDirty(),this},i.insertBefore=function(r,o){var a=this.index(r),s=a===0?"prepend":!1,l=this.normalize(o,this.proxyOf.nodes[a],s).reverse();a=this.index(r);for(var u=Ur(l),c;!(c=u()).done;){var d=c.value;this.proxyOf.nodes.splice(a,0,d)}var f;for(var h in this.indexes)f=this.indexes[h],a<=f&&(this.indexes[h]=f+l.length);return this.markDirty(),this},i.normalize=function(r,o){var a=this;if(typeof r=="string")r=wAe(xAe(r).nodes);else if(typeof r>"u")r=[];else if(Array.isArray(r)){r=r.slice(0);for(var s=Ur(r),l;!(l=s()).done;){var u=l.value;u.parent&&u.parent.removeChild(u,"ignore")}}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(var c=Ur(r),d;!(d=c()).done;){var f=d.value;f.parent&&f.parent.removeChild(f,"ignore")}}else if(r.type)r=[r];else if(r.prop){if(typeof r.value>"u")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new CAe(r)]}else if(r.selector)r=[new OQ(r)];else if(r.name)r=[new DQ(r)];else if(r.text)r=[new TAe(r)];else throw new Error("Unknown node type in node creation");var h=r.map(function(p){return p[PAe]||e.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[_Ae]&&AAe(p),typeof p.raws.before>"u"&&o&&typeof o.raws.before<"u"&&(p.raws.before=o.raws.before.replace(/\S/g,"")),p.parent=a.proxyOf,p});return h},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];o=o.reverse();for(var s=Ur(o),l;!(l=s()).done;){for(var u=l.value,c=this.normalize(u,this.first,"prepend").reverse(),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.unshift(h)}for(var p in this.indexes)this.indexes[p]=this.indexes[p]+c.length}return this.markDirty(),this},i.push=function(r){return r.parent=this,this.proxyOf.nodes.push(r),this},i.removeAll=function(){for(var r=Ur(this.proxyOf.nodes),o;!(o=r()).done;){var a=o.value;a.parent=void 0}return this.proxyOf.nodes=[],this.markDirty(),this},i.removeChild=function(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);var o;for(var a in this.indexes)o=this.indexes[a],o>=r&&(this.indexes[a]=o-1);return this.markDirty(),this},i.replaceValues=function(r,o,a){return a||(a=o,o={}),this.walkDecls(function(s){o.props&&!o.props.includes(s.prop)||o.fast&&!s.value.includes(o.fast)||(s.value=s.value.replace(r,a))}),this.markDirty(),this},i.some=function(r){return this.nodes.some(r)},i.walk=function(r){return this.each(function(o,a){var s;try{s=r(o,a)}catch(l){throw o.addToError(l)}return s!==!1&&o.walk&&(s=o.walk(r)),s})},i.walkAtRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="atrule"&&r.test(a.name))return o(a,s)}):this.walk(function(a,s){if(a.type==="atrule"&&a.name===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="atrule")return o(a,s)}))},i.walkComments=function(r){return this.walk(function(o,a){if(o.type==="comment")return r(o,a)})},i.walkDecls=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="decl"&&r.test(a.prop))return o(a,s)}):this.walk(function(a,s){if(a.type==="decl"&&a.prop===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="decl")return o(a,s)}))},i.walkRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="rule"&&r.test(a.selector))return o(a,s)}):this.walk(function(a,s){if(a.type==="rule"&&a.selector===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="rule")return o(a,s)}))},Is(e,[{key:"first",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}},{key:"last",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}]),e})(pKe);CS.registerParse=function(t){xAe=t};CS.registerRule=function(t){OQ=t};CS.registerAtRule=function(t){DQ=t};CS.registerRoot=function(t){EAe=t};var BD=CS;CS.default=CS;CS.rebuild=function(t){t.type==="atrule"?Object.setPrototypeOf(t,DQ.prototype):t.type==="rule"?Object.setPrototypeOf(t,OQ.prototype):t.type==="decl"?Object.setPrototypeOf(t,CAe.prototype):t.type==="comment"?Object.setPrototypeOf(t,TAe.prototype):t.type==="root"&&Object.setPrototypeOf(t,EAe.prototype),t[PAe]=!0,t.nodes&&t.nodes.forEach(function(e){CS.rebuild(e)})};var gKe=BD,OAe,DAe,Jj=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,Zn({type:"document"},n))||this,r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.toResult=function(r){r===void 0&&(r={});var o=new OAe(new DAe,this,r);return o.stringify()},e})(gKe);Jj.registerLazyResult=function(t){OAe=t};Jj.registerProcessor=function(t){DAe=t};var RQ=Jj;Jj.default=Jj;var QX=(function(){function t(i,n){if(n===void 0&&(n={}),this.type="warning",this.text=i,n.node&&n.node.source){var r=n.node.rangeBy(n);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(var o in n)this[o]=n[o]}var e=t.prototype;return e.toString=function(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text},t})(),RAe=QX;QX.default=QX;var vKe=RAe,eK=(function(){function t(i,n,r){this.processor=i,this.messages=[],this.root=n,this.opts=r,this.css=void 0,this.map=void 0}var e=t.prototype;return e.toString=function(){return this.css},e.warn=function(n,r){r===void 0&&(r={}),r.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(r.plugin=this.lastPlugin.postcssPlugin);var o=new vKe(n,r);return this.messages.push(o),o},e.warnings=function(){return this.messages.filter(function(n){return n.type==="warning"})},Is(t,[{key:"content",get:function(){return this.css}}]),t})(),MQ=eK;eK.default=eK;var s8=39,xae=34,xH=92,Eae=47,EH=10,W2=32,wH=12,AH=9,OH=13,yKe=91,mKe=93,bKe=40,SKe=41,_Ke=123,PKe=125,CKe=59,TKe=42,xKe=58,EKe=64,DH=/[\t\n\f\r "#'()/;[\\\]{}]/g,RH=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,wKe=/.[\r\n"'(/\\]/,wae=/[\da-f]/i,AKe=function(e,i){i===void 0&&(i={});var n=e.css.valueOf(),r=i.ignoreErrors,o,a,s,l,u,c,d,f,h,p,g=n.length,v=0,y=[],m=[];function b(){return v}function S(x){throw e.error("Unclosed "+x,v)}function _(){return m.length===0&&v>=g}function C(x){if(m.length)return m.pop();if(!(v>=g)){var E=x?x.ignoreUnclosed:!1;switch(o=n.charCodeAt(v),o){case EH:case W2:case AH:case OH:case wH:{a=v;do a+=1,o=n.charCodeAt(a);while(o===W2||o===EH||o===AH||o===OH||o===wH);p=["space",n.slice(v,a)],v=a-1;break}case yKe:case mKe:case _Ke:case PKe:case xKe:case CKe:case SKe:{var A=String.fromCharCode(o);p=[A,A,v];break}case bKe:{if(f=y.length?y.pop()[1]:"",h=n.charCodeAt(v+1),f==="url"&&h!==s8&&h!==xae&&h!==W2&&h!==EH&&h!==AH&&h!==wH&&h!==OH){a=v;do{if(c=!1,a=n.indexOf(")",a+1),a===-1)if(r||E){a=v;break}else S("bracket");for(d=a;n.charCodeAt(d-1)===xH;)d-=1,c=!c}while(c);p=["brackets",n.slice(v,a+1),v,a],v=a}else a=n.indexOf(")",v+1),l=n.slice(v,a+1),a===-1||wKe.test(l)?p=["(","(",v]:(p=["brackets",l,v,a],v=a);break}case s8:case xae:{s=o===s8?"'":'"',a=v;do{if(c=!1,a=n.indexOf(s,a+1),a===-1)if(r||E){a=v+1;break}else S("string");for(d=a;n.charCodeAt(d-1)===xH;)d-=1,c=!c}while(c);p=["string",n.slice(v,a+1),v,a],v=a;break}case EKe:{DH.lastIndex=v+1,DH.test(n),DH.lastIndex===0?a=n.length-1:a=DH.lastIndex-2,p=["at-word",n.slice(v,a+1),v,a],v=a;break}case xH:{for(a=v,u=!0;n.charCodeAt(a+1)===xH;)a+=1,u=!u;if(o=n.charCodeAt(a+1),u&&o!==Eae&&o!==W2&&o!==EH&&o!==AH&&o!==OH&&o!==wH&&(a+=1,wae.test(n.charAt(a)))){for(;wae.test(n.charAt(a+1));)a+=1;n.charCodeAt(a+1)===W2&&(a+=1)}p=["word",n.slice(v,a+1),v,a],v=a;break}default:{o===Eae&&n.charCodeAt(v+1)===TKe?(a=n.indexOf("*/",v+2)+1,a===0&&(r||E?a=n.length:S("comment")),p=["comment",n.slice(v,a+1),v,a],v=a):(RH.lastIndex=v+1,RH.test(n),RH.lastIndex===0?a=n.length-1:a=RH.lastIndex-2,p=["word",n.slice(v,a+1),v,a],y.push(p),v=a);break}}return v++,p}}function P(x){m.push(x)}return{back:P,endOfFile:_,nextToken:C,position:b}},MAe=BD,O5=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="atrule",r}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.append).call.apply(s,[].concat([this],o))},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.prepend).call.apply(s,[].concat([this],o))},e})(MAe),LQ=O5;O5.default=O5;MAe.registerAtRule(O5);var LAe=BD,kAe,IAe,_k=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="root",r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.normalize=function(r,o,a){var s=t.prototype.normalize.call(this,r);if(o){if(a==="prepend")this.nodes.length>1?o.raws.before=this.nodes[1].raws.before:delete o.raws.before;else if(this.first!==o)for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;c.raws.before=o.raws.before}}return s},i.removeChild=function(r,o){var a=this.index(r);return!o&&a===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[a].raws.before),t.prototype.removeChild.call(this,r)},i.toResult=function(r){r===void 0&&(r={});var o=new kAe(new IAe,this,r);return o.stringify()},e})(LAe);_k.registerLazyResult=function(t){kAe=t};_k.registerProcessor=function(t){IAe=t};var mV=_k;_k.default=_k;LAe.registerRoot(_k);var Qj={comma:function(e){return Qj.split(e,[","],!0)},space:function(e){var i=[" ",`
`,"	"];return Qj.split(e,i)},split:function(e,i,n){for(var r=[],o="",a=!1,s=0,l=!1,u="",c=!1,d=Ur(e),f;!(f=d()).done;){var h=f.value;c?c=!1:h==="\\"?c=!0:l?h===u&&(l=!1):h==='"'||h==="'"?(l=!0,u=h):h==="("?s+=1:h===")"?s>0&&(s-=1):s===0&&i.includes(h)&&(a=!0),a?(o!==""&&r.push(o.trim()),o="",a=!1):o+=h}return(n||o!=="")&&r.push(o.trim()),r}},NAe=Qj;Qj.default=Qj;var FAe=BD,OKe=NAe,D5=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="rule",n.nodes||(n.nodes=[]),n}return Is(e,[{key:"selectors",get:function(){return OKe.comma(this.selector)},set:function(n){var r=this.selector?this.selector.match(/,\s*/):null,o=r?r[0]:","+this.raw("between","beforeOpen");this.selector=n.join(o)}}]),e})(FAe),kQ=D5;D5.default=D5;FAe.registerRule(D5);var DKe=W$,RKe=AKe,MKe=Y$,LKe=LQ,kKe=mV,Aae=kQ,Oae={empty:!0,space:!0};function IKe(t){for(var e=t.length-1;e>=0;e--){var i=t[e],n=i[3]||i[2];if(n)return n}}var NKe=(function(){function t(i){this.input=i,this.root=new kKe,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:i,start:{column:1,line:1,offset:0}}}var e=t.prototype;return e.atrule=function(n){var r=new LKe;r.name=n[1].slice(1),r.name===""&&this.unnamedAtrule(r,n),this.init(r,n[2]);for(var o,a,s,l=!1,u=!1,c=[],d=[];!this.tokenizer.endOfFile();){if(n=this.tokenizer.nextToken(),o=n[0],o==="("||o==="["?d.push(o==="("?")":"]"):o==="{"&&d.length>0?d.push("}"):o===d[d.length-1]&&d.pop(),d.length===0)if(o===";"){r.source.end=this.getPosition(n[2]),r.source.end.offset++,this.semicolon=!0;break}else if(o==="{"){u=!0;break}else if(o==="}"){if(c.length>0){for(s=c.length-1,a=c[s];a&&a[0]==="space";)a=c[--s];a&&(r.source.end=this.getPosition(a[3]||a[2]),r.source.end.offset++)}this.end(n);break}else c.push(n);else c.push(n);if(this.tokenizer.endOfFile()){l=!0;break}}r.raws.between=this.spacesAndCommentsFromEnd(c),c.length?(r.raws.afterName=this.spacesAndCommentsFromStart(c),this.raw(r,"params",c),l&&(n=c[c.length-1],r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++,this.spaces=r.raws.between,r.raws.between="")):(r.raws.afterName="",r.params=""),u&&(r.nodes=[],this.current=r)},e.checkMissedSemicolon=function(n){var r=this.colon(n);if(r!==!1){for(var o=0,a,s=r-1;s>=0&&(a=n[s],!(a[0]!=="space"&&(o+=1,o===2)));s--);throw this.input.error("Missed semicolon",a[0]==="word"?a[3]+1:a[2])}},e.colon=function(n){for(var r=0,o,a,s,l=Ur(n.entries()),u;!(u=l()).done;){var c=u.value,d=c[0],f=c[1];if(o=f,a=o[0],a==="("&&(r+=1),a===")"&&(r-=1),r===0&&a===":")if(!s)this.doubleColon(o);else{if(s[0]==="word"&&s[1]==="progid")continue;return d}s=o}return!1},e.comment=function(n){var r=new MKe;this.init(r,n[2]),r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++;var o=n[1].slice(2,-2);if(/^\s*$/.test(o))r.text="",r.raws.left=o,r.raws.right="";else{var a=o.match(/^(\s*)([^]*\S)(\s*)$/);r.text=a[2],r.raws.left=a[1],r.raws.right=a[3]}},e.createTokenizer=function(){this.tokenizer=RKe(this.input)},e.decl=function(n,r){var o=new DKe;this.init(o,n[0][2]);var a=n[n.length-1];for(a[0]===";"&&(this.semicolon=!0,n.pop()),o.source.end=this.getPosition(a[3]||a[2]||IKe(n)),o.source.end.offset++;n[0][0]!=="word";)n.length===1&&this.unknownWord(n),o.raws.before+=n.shift()[1];for(o.source.start=this.getPosition(n[0][2]),o.prop="";n.length;){var s=n[0][0];if(s===":"||s==="space"||s==="comment")break;o.prop+=n.shift()[1]}o.raws.between="";for(var l;n.length;)if(l=n.shift(),l[0]===":"){o.raws.between+=l[1];break}else l[0]==="word"&&/\w/.test(l[1])&&this.unknownWord([l]),o.raws.between+=l[1];(o.prop[0]==="_"||o.prop[0]==="*")&&(o.raws.before+=o.prop[0],o.prop=o.prop.slice(1));for(var u=[],c;n.length&&(c=n[0][0],!(c!=="space"&&c!=="comment"));)u.push(n.shift());this.precheckMissedSemicolon(n);for(var d=n.length-1;d>=0;d--){if(l=n[d],l[1].toLowerCase()==="!important"){o.important=!0;var f=this.stringFrom(n,d);f=this.spacesFromEnd(n)+f,f!==" !important"&&(o.raws.important=f);break}else if(l[1].toLowerCase()==="important"){for(var h=n.slice(0),p="",g=d;g>0;g--){var v=h[g][0];if(p.trim().indexOf("!")===0&&v!=="space")break;p=h.pop()[1]+p}p.trim().indexOf("!")===0&&(o.important=!0,o.raws.important=p,n=h)}if(l[0]!=="space"&&l[0]!=="comment")break}var y=n.some(function(m){return m[0]!=="space"&&m[0]!=="comment"});y&&(o.raws.between+=u.map(function(m){return m[1]}).join(""),u=[]),this.raw(o,"value",u.concat(n),r),o.value.includes(":")&&!r&&this.checkMissedSemicolon(n)},e.doubleColon=function(n){throw this.input.error("Double colon",{offset:n[2]},{offset:n[2]+n[1].length})},e.emptyRule=function(n){var r=new Aae;this.init(r,n[2]),r.selector="",r.raws.between="",this.current=r},e.end=function(n){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(n[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(n)},e.endFile=function(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())},e.freeSemicolon=function(n){if(this.spaces+=n[1],this.current.nodes){var r=this.current.nodes[this.current.nodes.length-1];r&&r.type==="rule"&&!r.raws.ownSemicolon&&(r.raws.ownSemicolon=this.spaces,this.spaces="")}},e.getPosition=function(n){var r=this.input.fromOffset(n);return{column:r.col,line:r.line,offset:n}},e.init=function(n,r){this.current.push(n),n.source={input:this.input,start:this.getPosition(r)},n.raws.before=this.spaces,this.spaces="",n.type!=="comment"&&(this.semicolon=!1)},e.other=function(n){for(var r=!1,o=null,a=!1,s=null,l=[],u=n[1].startsWith("--"),c=[],d=n;d;){if(o=d[0],c.push(d),o==="("||o==="[")s||(s=d),l.push(o==="("?")":"]");else if(u&&a&&o==="{")s||(s=d),l.push("}");else if(l.length===0)if(o===";")if(a){this.decl(c,u);return}else break;else if(o==="{"){this.rule(c);return}else if(o==="}"){this.tokenizer.back(c.pop()),r=!0;break}else o===":"&&(a=!0);else o===l[l.length-1]&&(l.pop(),l.length===0&&(s=null));d=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(r=!0),l.length>0&&this.unclosedBracket(s),r&&a){if(!u)for(;c.length&&(d=c[c.length-1][0],!(d!=="space"&&d!=="comment"));)this.tokenizer.back(c.pop());this.decl(c,u)}else this.unknownWord(c)},e.parse=function(){for(var n;!this.tokenizer.endOfFile();)switch(n=this.tokenizer.nextToken(),n[0]){case"space":this.spaces+=n[1];break;case";":this.freeSemicolon(n);break;case"}":this.end(n);break;case"comment":this.comment(n);break;case"at-word":this.atrule(n);break;case"{":this.emptyRule(n);break;default:this.other(n);break}this.endFile()},e.precheckMissedSemicolon=function(){},e.raw=function(n,r,o,a){for(var s,l,u=o.length,c="",d=!0,f,h,p=0;p<u;p+=1)s=o[p],l=s[0],l==="space"&&p===u-1&&!a?d=!1:l==="comment"?(h=o[p-1]?o[p-1][0]:"empty",f=o[p+1]?o[p+1][0]:"empty",!Oae[h]&&!Oae[f]?c.slice(-1)===","?d=!1:c+=s[1]:d=!1):c+=s[1];if(!d){var g=o.reduce(function(v,y){return v+y[1]},"");n.raws[r]={raw:g,value:c}}n[r]=c},e.rule=function(n){n.pop();var r=new Aae;this.init(r,n[0][2]),r.raws.between=this.spacesAndCommentsFromEnd(n),this.raw(r,"selector",n),this.current=r},e.spacesAndCommentsFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],!(r!=="space"&&r!=="comment"));)o=n.pop()[1]+o;return o},e.spacesAndCommentsFromStart=function(n){for(var r,o="";n.length&&(r=n[0][0],!(r!=="space"&&r!=="comment"));)o+=n.shift()[1];return o},e.spacesFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],r==="space");)o=n.pop()[1]+o;return o},e.stringFrom=function(n,r){for(var o="",a=r;a<n.length;a++)o+=n[a][1];return n.splice(r,n.length-r),o},e.unclosedBlock=function(){var n=this.current.source.start;throw this.input.error("Unclosed block",n.line,n.column)},e.unclosedBracket=function(n){throw this.input.error("Unclosed bracket",{offset:n[2]},{offset:n[2]+1})},e.unexpectedClose=function(n){throw this.input.error("Unexpected }",{offset:n[2]},{offset:n[2]+1})},e.unknownWord=function(n){throw this.input.error("Unknown word",{offset:n[0][2]},{offset:n[0][2]+n[0][1].length})},e.unnamedAtrule=function(n,r){throw this.input.error("At-rule without name",{offset:r[2]},{offset:r[2]+r[1].length})},t})(),FKe=NKe,BKe=BD,jKe=FKe,VKe=G$;function R5(t,e){var i=new VKe(t,e),n=new jKe(i);try{n.parse()}catch(r){throw r}return n.root}var IQ=R5;R5.default=R5;BKe.registerParse(R5);var Ey=IP.isClean,HKe=IP.my,UKe=SAe,zKe=z$,$Ke=BD,WKe=RQ,Dae=MQ,GKe=IQ,YKe=mV,qKe={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},XKe={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},KKe={Once:!0,postcssPlugin:!0,prepare:!0},Pk=0;function G2(t){return(typeof t>"u"?"undefined":Ui(t))==="object"&&typeof t.then=="function"}function BAe(t){var e=!1,i=qKe[t.type];return t.type==="decl"?e=t.prop.toLowerCase():t.type==="atrule"&&(e=t.name.toLowerCase()),e&&t.append?[i,i+"-"+e,Pk,i+"Exit",i+"Exit-"+e]:e?[i,i+"-"+e,i+"Exit",i+"Exit-"+e]:t.append?[i,Pk,i+"Exit"]:[i,i+"Exit"]}function Rae(t){var e;return t.type==="document"?e=["Document",Pk,"DocumentExit"]:t.type==="root"?e=["Root",Pk,"RootExit"]:e=BAe(t),{eventIndex:0,events:e,iterator:0,node:t,visitorIndex:0,visitors:[]}}function tK(t){return t[Ey]=!1,t.nodes&&t.nodes.forEach(function(e){return tK(e)}),t}var rK={},Ck=(function(){function t(i,n,r){var o=this;this.stringified=!1,this.processed=!1;var a;if((typeof n>"u"?"undefined":Ui(n))==="object"&&n!==null&&(n.type==="root"||n.type==="document"))a=tK(n);else if(Ni(n,t)||Ni(n,Dae))a=tK(n.root),n.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=n.map);else{var s=GKe;r.syntax&&(s=r.syntax.parse),r.parser&&(s=r.parser),s.parse&&(s=s.parse);try{a=s(n,r)}catch(l){this.processed=!0,this.error=l}a&&!a[HKe]&&$Ke.rebuild(a)}this.result=new Dae(i,a,r),this.helpers=Zn({},rK,{postcss:rK,result:this.result}),this.plugins=this.processor.plugins.map(function(l){return(typeof l>"u"?"undefined":Ui(l))==="object"&&l.prepare?Zn({},l,l.prepare(o.result)):l})}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.getAsyncError=function(){throw new Error("Use process(css).then(cb) to work with async plugins")},e.handleError=function(n,r){var o=this.result.lastPlugin;try{if(r&&r.addToError(n),this.error=n,n.name==="CssSyntaxError"&&!n.plugin)n.plugin=o.postcssPlugin,n.setMessage();else if(o.postcssVersion)var a,s,l,u,c}catch(d){console&&console.error&&console.error(d)}return n},e.prepareVisitors=function(){var n=this;this.listeners={};for(var r=function(c,d,f){n.listeners[d]||(n.listeners[d]=[]),n.listeners[d].push([c,f])},o=Ur(this.plugins),a;!(a=o()).done;){var s=a.value;if((typeof s>"u"?"undefined":Ui(s))==="object")for(var l in s){if(!XKe[l]&&/^[A-Z]/.test(l))throw new Error("Unknown event "+l+" in "+s.postcssPlugin+". Try to update PostCSS ("+this.processor.version+" now).");if(!KKe[l])if(Ui(s[l])==="object")for(var u in s[l])u==="*"?r(s,l,s[l][u]):r(s,l+"-"+u.toLowerCase(),s[l][u]);else typeof s[l]=="function"&&r(s,l,s[l])}}this.hasListener=Object.keys(this.listeners).length>0},e.runAsync=function(){var n=this;return U$(function(){var r,o,a,s,l,u,c,d,f,h,p,g;return CD(this,function(v){switch(v.label){case 0:n.plugin=0,r=0,v.label=1;case 1:if(!(r<n.plugins.length))return[3,6];if(o=n.plugins[r],a=n.runOnRoot(o),!G2(a))return[3,5];v.label=2;case 2:return v.trys.push([2,4,,5]),[4,a];case 3:return v.sent(),[3,5];case 4:throw s=v.sent(),n.handleError(s);case 5:return r++,[3,1];case 6:if(n.prepareVisitors(),!n.hasListener)return[3,18];l=n.result.root,v.label=7;case 7:if(l[Ey])return[3,14];l[Ey]=!0,u=[Rae(l)],v.label=8;case 8:if(!(u.length>0))return[3,13];if(c=n.visitTick(u),!G2(c))return[3,12];v.label=9;case 9:return v.trys.push([9,11,,12]),[4,c];case 10:return v.sent(),[3,12];case 11:throw d=v.sent(),f=u[u.length-1].node,n.handleError(d,f);case 12:return[3,8];case 13:return[3,7];case 14:if(!n.listeners.OnceExit)return[3,18];h=function(){var y,m,b,S,_;return CD(this,function(C){switch(C.label){case 0:y=g.value,m=y[0],b=y[1],n.result.lastPlugin=m,C.label=1;case 1:return C.trys.push([1,6,,7]),l.type!=="document"?[3,3]:(S=l.nodes.map(function(P){return b(P,n.helpers)}),[4,Promise.all(S)]);case 2:return C.sent(),[3,5];case 3:return[4,b(l,n.helpers)];case 4:C.sent(),C.label=5;case 5:return[3,7];case 6:throw _=C.sent(),n.handleError(_);case 7:return[2]}})},p=Ur(n.listeners.OnceExit),v.label=15;case 15:return(g=p()).done?[3,18]:[5,TQ(h())];case 16:v.sent(),v.label=17;case 17:return[3,15];case 18:return n.processed=!0,[2,n.stringify()]}})})()},e.runOnRoot=function(n){var r=this;this.result.lastPlugin=n;try{if((typeof n>"u"?"undefined":Ui(n))==="object"&&n.Once){if(this.result.root.type==="document"){var o=this.result.root.nodes.map(function(a){return n.Once(a,r.helpers)});return G2(o[0])?Promise.all(o):o}return n.Once(this.result.root,this.helpers)}else if(typeof n=="function")return n(this.result.root,this.result)}catch(a){throw this.handleError(a)}},e.stringify=function(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();var n=this.result.opts,r=zKe;n.syntax&&(r=n.syntax.stringify),n.stringifier&&(r=n.stringifier),r.stringify&&(r=r.stringify);var o=new UKe(r,this.result.root,this.result.opts),a=o.generate();return this.result.css=a[0],this.result.map=a[1],this.result},e.sync=function(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(var n=Ur(this.plugins),r;!(r=n()).done;){var o=r.value,a=this.runOnRoot(o);if(G2(a))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){for(var s=this.result.root;!s[Ey];)s[Ey]=!0,this.walkSync(s);if(this.listeners.OnceExit)if(s.type==="document")for(var l=Ur(s.nodes),u;!(u=l()).done;){var c=u.value;this.visitSync(this.listeners.OnceExit,c)}else this.visitSync(this.listeners.OnceExit,s)}return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this.css},e.visitSync=function(n,r){for(var o=Ur(n),a;!(a=o()).done;){var s=a.value,l=s[0],u=s[1];this.result.lastPlugin=l;var c=void 0;try{c=u(r,this.helpers)}catch(d){throw this.handleError(d,r.proxyOf)}if(r.type!=="root"&&r.type!=="document"&&!r.parent)return!0;if(G2(c))throw this.getAsyncError()}},e.visitTick=function(n){var r=n[n.length-1],o=r.node,a=r.visitors;if(o.type!=="root"&&o.type!=="document"&&!o.parent){n.pop();return}if(a.length>0&&r.visitorIndex<a.length){var s=a[r.visitorIndex],l=s[0],u=s[1];r.visitorIndex+=1,r.visitorIndex===a.length&&(r.visitors=[],r.visitorIndex=0),this.result.lastPlugin=l;try{return u(o.toProxy(),this.helpers)}catch(p){throw this.handleError(p,o)}}if(r.iterator!==0){for(var c=r.iterator,d;d=o.nodes[o.indexes[c]];)if(o.indexes[c]+=1,!d[Ey]){d[Ey]=!0,n.push(Rae(d));return}r.iterator=0,delete o.indexes[c]}for(var f=r.events;r.eventIndex<f.length;){var h=f[r.eventIndex];if(r.eventIndex+=1,h===Pk){o.nodes&&o.nodes.length&&(o[Ey]=!0,r.iterator=o.getIterator());return}else if(this.listeners[h]){r.visitors=this.listeners[h];return}}n.pop()},e.walkSync=function(n){var r=this;n[Ey]=!0;for(var o=BAe(n),a=Ur(o),s;!(s=a()).done;){var l=s.value;if(l===Pk)n.nodes&&n.each(function(c){c[Ey]||r.walkSync(c)});else{var u=this.listeners[l];if(u&&this.visitSync(u,n.toProxy()))return}}},e.warnings=function(){return this.sync().warnings()},Is(t,[{key:"content",get:function(){return this.stringify().content}},{key:"css",get:function(){return this.stringify().css}},{key:"map",get:function(){return this.stringify().map}},{key:"messages",get:function(){return this.sync().messages}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){return this.sync().root}},{key:Symbol.toStringTag,get:function(){return"LazyResult"}}]),t})();Ck.registerPostcss=function(t){rK=t};var jAe=Ck;Ck.default=Ck;YKe.registerLazyResult(Ck);WKe.registerLazyResult(Ck);var ZKe=SAe,JKe=z$,QKe=IQ,eZe=MQ,iK=(function(){function t(i,n,r){n=n.toString(),this.stringified=!1,this._processor=i,this._css=n,this._opts=r,this._map=void 0;var o,a=JKe;this.result=new eZe(this._processor,o,this._opts),this.result.css=n;var s=this;Object.defineProperty(this.result,"root",{get:function(){return s.root}});var l=new ZKe(a,o,this._opts,n);if(l.isMap()){var u=l.generate(),c=u[0],d=u[1];c&&(this.result.css=c),d&&(this.result.map=d)}else l.clearAnnotation(),this.result.css=l.css}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.sync=function(){if(this.error)throw this.error;return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this._css},e.warnings=function(){return[]},Is(t,[{key:"content",get:function(){return this.result.css}},{key:"css",get:function(){return this.result.css}},{key:"map",get:function(){return this.result.map}},{key:"messages",get:function(){return[]}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){if(this._root)return this._root;var n,r=QKe;try{n=r(this._css,this._opts)}catch(o){this.error=o}if(this.error)throw this.error;return this._root=n,n}},{key:Symbol.toStringTag,get:function(){return"NoWorkResult"}}]),t})(),tZe=iK;iK.default=iK;var rZe=tZe,iZe=jAe,nZe=RQ,oZe=mV,e3=(function(){function t(i){i===void 0&&(i=[]),this.version="8.4.38",this.plugins=this.normalize(i)}var e=t.prototype;return e.normalize=function(n){for(var r=[],o=Ur(n),a;!(a=o()).done;){var s=a.value;if(s.postcss===!0?s=s():s.postcss&&(s=s.postcss),(typeof s>"u"?"undefined":Ui(s))==="object"&&Array.isArray(s.plugins))r=r.concat(s.plugins);else if((typeof s>"u"?"undefined":Ui(s))==="object"&&s.postcssPlugin)r.push(s);else if(typeof s=="function")r.push(s);else if(!((typeof s>"u"?"undefined":Ui(s))==="object"&&(s.parse||s.stringify)))throw new Error(s+" is not a PostCSS plugin")}return r},e.process=function(n,r){return r===void 0&&(r={}),!this.plugins.length&&!r.parser&&!r.stringifier&&!r.syntax?new rZe(this,n,r):new iZe(this,n,r)},e.use=function(n){return this.plugins=this.plugins.concat(this.normalize([n])),this},t})(),aZe=e3;e3.default=e3;oZe.registerProcessor(e3);nZe.registerProcessor(e3);var sZe=W$,lZe=gAe,uZe=Y$,cZe=LQ,dZe=G$,fZe=mV,hZe=kQ;function t3(t,e){if(Array.isArray(t))return t.map(function(d){return t3(d)});var i=t.inputs,n=PD(t,["inputs"]);if(i){e=[];for(var r=Ur(i),o;!(o=r()).done;){var a=o.value,s=Zn({},a,{__proto__:dZe.prototype});s.map&&(s.map=Zn({},s.map,{__proto__:lZe.prototype})),e.push(s)}}if(n.nodes&&(n.nodes=t.nodes.map(function(d){return t3(d,e)})),n.source){var l=n.source,u=l.inputId,c=PD(l,["inputId"]);n.source=c,u!=null&&(n.source.input=e[u])}if(n.type==="root")return new fZe(n);if(n.type==="decl")return new sZe(n);if(n.type==="rule")return new hZe(n);if(n.type==="comment")return new uZe(n);if(n.type==="atrule")return new cZe(n);throw new Error("Unknown node type: "+t.type)}var pZe=t3;t3.default=t3;var gZe=AQ,VAe=W$,vZe=jAe,yZe=BD,NQ=aZe,mZe=z$,bZe=pZe,HAe=RQ,SZe=RAe,UAe=Y$,zAe=LQ,_Ze=MQ,PZe=G$,CZe=IQ,TZe=NAe,$Ae=kQ,WAe=mV,xZe=$$;function ka(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return e.length===1&&Array.isArray(e[0])&&(e=e[0]),new NQ(e)}ka.plugin=function(e,i){var n=!1;function r(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];console&&console.warn&&!n&&(n=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),Sk.LANG&&Sk.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
https://www.w3ctech.com/topic/2226`));var u=i.apply(void 0,[].concat(s));return u.postcssPlugin=e,u.postcssVersion=new NQ().version,u}var o;return Object.defineProperty(r,"postcss",{get:function(){return o||(o=r()),o}}),r.process=function(a,s,l){return ka([r(l)]).process(a,s)},r};ka.stringify=mZe;ka.parse=CZe;ka.fromJSON=bZe;ka.list=TZe;ka.comment=function(t){return new UAe(t)};ka.atRule=function(t){return new zAe(t)};ka.decl=function(t){return new VAe(t)};ka.rule=function(t){return new $Ae(t)};ka.root=function(t){return new WAe(t)};ka.document=function(t){return new HAe(t)};ka.CssSyntaxError=gZe;ka.Declaration=VAe;ka.Container=yZe;ka.Processor=NQ;ka.Document=HAe;ka.Comment=UAe;ka.Warning=SZe;ka.AtRule=zAe;ka.Result=_Ze;ka.Input=PZe;ka.Rule=$Ae;ka.Root=WAe;ka.Node=xZe;vZe.registerPostcss(ka);var EZe=ka;ka.default=ka;var Zs=jXe(EZe);Zs.stringify;Zs.fromJSON;Zs.plugin;Zs.parse;Zs.list;Zs.document;Zs.comment;Zs.atRule;Zs.rule;Zs.decl;Zs.root;Zs.CssSyntaxError;Zs.Declaration;Zs.Container;Zs.Processor;Zs.Document;Zs.Comment;Zs.Warning;Zs.AtRule;Zs.Result;Zs.Input;Zs.Rule;Zs.Root;Zs.Node;var wZe=Object.defineProperty,AZe=function(t,e,i){return e in t?wZe(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i},hg=function(t,e,i){return AZe(t,(typeof e>"u"?"undefined":Ui(e))!=="symbol"?e+"":e,i)};function OZe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function DZe(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var i=function n(){return Ni(this,n)?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(i,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}),i}var FQ={exports:{}},ws=String,GAe=function(){return{isColorSupported:!1,reset:ws,bold:ws,dim:ws,italic:ws,underline:ws,inverse:ws,hidden:ws,strikethrough:ws,black:ws,red:ws,green:ws,yellow:ws,blue:ws,magenta:ws,cyan:ws,white:ws,gray:ws,bgBlack:ws,bgRed:ws,bgGreen:ws,bgYellow:ws,bgBlue:ws,bgMagenta:ws,bgCyan:ws,bgWhite:ws}};FQ.exports=GAe();FQ.exports.createColors=GAe;var RZe=FQ.exports,MZe={},LZe=Object.freeze(Object.defineProperty({__proto__:null,default:MZe},Symbol.toStringTag,{value:"Module"})),au=DZe(LZe),Mae=RZe,Lae=au,nK=(function(t){Ks(e,t);function e(n,r,o,a,s,l){var u;return u=t.call(this,n)||this,u.name="CssSyntaxError",u.reason=n,s&&(u.file=s),a&&(u.source=a),l&&(u.plugin=l),typeof r<"u"&&typeof o<"u"&&(typeof r=="number"?(u.line=r,u.column=o):(u.line=r.line,u.column=r.column,u.endLine=o.line,u.endColumn=o.column)),u.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(u,e),u}var i=e.prototype;return i.setMessage=function(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason},i.showSourceCode=function(r){var o=this;if(!this.source)return"";var a=this.source;r==null&&(r=Mae.isColorSupported),Lae&&r&&(a=Lae(a));var s=a.split(/\r?\n/),l=Math.max(this.line-3,0),u=Math.min(this.line+2,s.length),c=String(u).length,d,f;if(r){var h=Mae.createColors(!0),p=h.bold,g=h.gray,v=h.red;d=function(y){return p(v(y))},f=function(y){return g(y)}}else d=f=function(y){return y};return s.slice(l,u).map(function(y,m){var b=l+1+m,S=" "+(" "+b).slice(-c)+" | ";if(b===o.line){var _=f(S.replace(/\d/g," "))+y.slice(0,o.column-1).replace(/[^\t]/g," ");return d(">")+f(S)+y+`
 `+_+d("^")}return" "+f(S)+y}).join(`
`)},i.toString=function(){var r=this.showSourceCode();return r&&(r=`

`+r+`
`),this.name+": "+this.message+r},e})(Kj(Error)),BQ=nK;nK.default=nK;var NP={};NP.isClean=Symbol("isClean");NP.my=Symbol("my");var kae={after:`
`,beforeClose:`
`,beforeComment:`
`,beforeDecl:`
`,beforeOpen:" ",beforeRule:`
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:"    ",semicolon:!1};function kZe(t){return t[0].toUpperCase()+t.slice(1)}var oK=(function(){function t(i){this.builder=i}var e=t.prototype;return e.atrule=function(n,r){var o="@"+n.name,a=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?o+=n.raws.afterName:a&&(o+=" "),n.nodes)this.block(n,o+a);else{var s=(n.raws.between||"")+(r?";":"");this.builder(o+a+s,n)}},e.beforeAfter=function(n,r){var o;n.type==="decl"?o=this.raw(n,null,"beforeDecl"):n.type==="comment"?o=this.raw(n,null,"beforeComment"):r==="before"?o=this.raw(n,null,"beforeRule"):o=this.raw(n,null,"beforeClose");for(var a=n.parent,s=0;a&&a.type!=="root";)s+=1,a=a.parent;if(o.includes(`
`)){var l=this.raw(n,null,"indent");if(l.length)for(var u=0;u<s;u++)o+=l}return o},e.block=function(n,r){var o=this.raw(n,"between","beforeOpen");this.builder(r+o+"{",n,"start");var a;n.nodes&&n.nodes.length?(this.body(n),a=this.raw(n,"after")):a=this.raw(n,"after","emptyBody"),a&&this.builder(a),this.builder("}",n,"end")},e.body=function(n){for(var r=n.nodes.length-1;r>0&&n.nodes[r].type==="comment";)r-=1;for(var o=this.raw(n,"semicolon"),a=0;a<n.nodes.length;a++){var s=n.nodes[a],l=this.raw(s,"before");l&&this.builder(l),this.stringify(s,r!==a||o)}},e.comment=function(n){var r=this.raw(n,"left","commentLeft"),o=this.raw(n,"right","commentRight");this.builder("/*"+r+n.text+o+"*/",n)},e.decl=function(n,r){var o=this.raw(n,"between","colon"),a=n.prop+o+this.rawValue(n,"value");n.important&&(a+=n.raws.important||" !important"),r&&(a+=";"),this.builder(a,n)},e.document=function(n){this.body(n)},e.raw=function(n,r,o){var a;if(o||(o=r),r&&(a=n.raws[r],typeof a<"u"))return a;var s=n.parent;if(o==="before"&&(!s||s.type==="root"&&s.first===n||s&&s.type==="document"))return"";if(!s)return kae[o];var l=n.root();if(l.rawCache||(l.rawCache={}),typeof l.rawCache[o]<"u")return l.rawCache[o];if(o==="before"||o==="after")return this.beforeAfter(n,o);var u="raw"+kZe(o);return this[u]?a=this[u](l,n):l.walk(function(c){if(a=c.raws[r],typeof a<"u")return!1}),typeof a>"u"&&(a=kae[o]),l.rawCache[o]=a,a},e.rawBeforeClose=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length>0&&typeof o.raws.after<"u")return r=o.raws.after,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawBeforeComment=function(n,r){var o;return n.walkComments(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeDecl"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeDecl=function(n,r){var o;return n.walkDecls(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeRule"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeOpen=function(n){var r;return n.walk(function(o){if(o.type!=="decl"&&(r=o.raws.between,typeof r<"u"))return!1}),r},e.rawBeforeRule=function(n){var r;return n.walk(function(o){if(o.nodes&&(o.parent!==n||n.first!==o)&&typeof o.raws.before<"u")return r=o.raws.before,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawColon=function(n){var r;return n.walkDecls(function(o){if(typeof o.raws.between<"u")return r=o.raws.between.replace(/[^\s:]/g,""),!1}),r},e.rawEmptyBody=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length===0&&(r=o.raws.after,typeof r<"u"))return!1}),r},e.rawIndent=function(n){if(n.raws.indent)return n.raws.indent;var r;return n.walk(function(o){var a=o.parent;if(a&&a!==n&&a.parent&&a.parent===n&&typeof o.raws.before<"u"){var s=o.raws.before.split(`
`);return r=s[s.length-1],r=r.replace(/\S/g,""),!1}}),r},e.rawSemicolon=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length&&o.last.type==="decl"&&(r=o.raws.semicolon,typeof r<"u"))return!1}),r},e.rawValue=function(n,r){var o=n[r],a=n.raws[r];return a&&a.value===o?a.raw:o},e.root=function(n){this.body(n),n.raws.after&&this.builder(n.raws.after)},e.rule=function(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end")},e.stringify=function(n,r){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,r)},t})(),YAe=oK;oK.default=oK;var IZe=YAe;function aK(t,e){var i=new IZe(e);i.stringify(t)}var q$=aK;aK.default=aK;var MH=NP.isClean,NZe=NP.my,FZe=BQ,BZe=YAe,jZe=q$;function sK(t,e){var i=new t.constructor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&n!=="proxyCache"){var r=t[n],o=typeof r>"u"?"undefined":Ui(r);n==="parent"&&o==="object"?e&&(i[n]=e):n==="source"?i[n]=r:Array.isArray(r)?i[n]=r.map(function(a){return sK(a,i)}):(o==="object"&&r!==null&&(r=sK(r)),i[n]=r)}return i}var lK=(function(){function t(i){i===void 0&&(i={}),this.raws={},this[MH]=!1,this[NZe]=!0;for(var n in i)if(n==="nodes"){this.nodes=[];for(var r=Ur(i[n]),o;!(o=r()).done;){var a=o.value;typeof a.clone=="function"?this.append(a.clone()):this.append(a)}}else this[n]=i[n]}var e=t.prototype;return e.addToError=function(n){if(n.postcssNode=this,n.stack&&this.source&&/\n\s{4}at /.test(n.stack)){var r=this.source;n.stack=n.stack.replace(/\n\s{4}at /,"$&"+r.input.from+":"+r.start.line+":"+r.start.column+"$&")}return n},e.after=function(n){return this.parent.insertAfter(this,n),this},e.assign=function(n){n===void 0&&(n={});for(var r in n)this[r]=n[r];return this},e.before=function(n){return this.parent.insertBefore(this,n),this},e.cleanRaws=function(n){delete this.raws.before,delete this.raws.after,n||delete this.raws.between},e.clone=function(n){n===void 0&&(n={});var r=sK(this);for(var o in n)r[o]=n[o];return r},e.cloneAfter=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertAfter(this,r),r},e.cloneBefore=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertBefore(this,r),r},e.error=function(n,r){if(r===void 0&&(r={}),this.source){var o=this.rangeBy(r),a=o.end,s=o.start;return this.source.input.error(n,{column:s.column,line:s.line},{column:a.column,line:a.line},r)}return new FZe(n)},e.getProxyProcessor=function(){return{get:function(r,o){return o==="proxyOf"?r:o==="root"?function(){return r.root().toProxy()}:r[o]},set:function(r,o,a){return r[o]===a||(r[o]=a,(o==="prop"||o==="value"||o==="name"||o==="params"||o==="important"||o==="text")&&r.markDirty()),!0}}},e.markDirty=function(){if(this[MH]){this[MH]=!1;for(var n=this;n=n.parent;)n[MH]=!1}},e.next=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n+1]}},e.positionBy=function(n,r){var o=this.source.start;if(n.index)o=this.positionInside(n.index,r);else if(n.word){r=this.toString();var a=r.indexOf(n.word);a!==-1&&(o=this.positionInside(a,r))}return o},e.positionInside=function(n,r){for(var o=r||this.toString(),a=this.source.start.column,s=this.source.start.line,l=0;l<n;l++)o[l]===`
`?(a=1,s+=1):a+=1;return{column:a,line:s}},e.prev=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n-1]}},e.rangeBy=function(n){var r={column:this.source.start.column,line:this.source.start.line},o=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(n.word){var a=this.toString(),s=a.indexOf(n.word);s!==-1&&(r=this.positionInside(s,a),o=this.positionInside(s+n.word.length,a))}else n.start?r={column:n.start.column,line:n.start.line}:n.index&&(r=this.positionInside(n.index)),n.end?o={column:n.end.column,line:n.end.line}:typeof n.endIndex=="number"?o=this.positionInside(n.endIndex):n.index&&(o=this.positionInside(n.index+1));return(o.line<r.line||o.line===r.line&&o.column<=r.column)&&(o={column:r.column+1,line:r.line}),{end:o,start:r}},e.raw=function(n,r){var o=new BZe;return o.raw(this,n,r)},e.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},e.replaceWith=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];if(this.parent){for(var a=this,s=!1,l=Ur(r),u;!(u=l()).done;){var c=u.value;c===this?s=!0:s?(this.parent.insertAfter(a,c),a=c):this.parent.insertBefore(a,c)}s||this.remove()}return this},e.root=function(){for(var n=this;n.parent&&n.parent.type!=="document";)n=n.parent;return n},e.toJSON=function(n,r){var o={},a=r==null;r=r||new Map;var s=0;for(var l in this)if(Object.prototype.hasOwnProperty.call(this,l)&&!(l==="parent"||l==="proxyCache")){var u=this[l];if(Array.isArray(u))o[l]=u.map(function(d){return(typeof d>"u"?"undefined":Ui(d))==="object"&&d.toJSON?d.toJSON(null,r):d});else if((typeof u>"u"?"undefined":Ui(u))==="object"&&u.toJSON)o[l]=u.toJSON(null,r);else if(l==="source"){var c=r.get(u.input);c==null&&(c=s,r.set(u.input,s),s++),o[l]={end:u.end,inputId:c,start:u.start}}else o[l]=u}return a&&(o.inputs=[].concat(r.keys()).map(function(d){return d.toJSON()})),o},e.toProxy=function(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache},e.toString=function(n){n===void 0&&(n=jZe),n.stringify&&(n=n.stringify);var r="";return n(this,function(o){r+=o}),r},e.warn=function(n,r,o){var a={node:this};for(var s in o)a[s]=o[s];return n.warn(r,a)},Is(t,[{key:"proxyOf",get:function(){return this}}]),t})(),X$=lK;lK.default=lK;var VZe=X$,uK=(function(t){Ks(e,t);function e(i){var n;return i&&typeof i.value<"u"&&typeof i.value!="string"&&(i=Zn({},i,{value:String(i.value)})),n=t.call(this,i)||this,n.type="decl",n}return Is(e,[{key:"variable",get:function(){return this.prop.startsWith("--")||this.prop[0]==="$"}}]),e})(VZe),K$=uK;uK.default=uK;var HZe="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",UZe=function(t){t===void 0&&(t=21);for(var e="",i=t;i--;)e+=HZe[Math.random()*64|0];return e},zZe={nanoid:UZe},Iae=au.SourceMapConsumer,Nae=au.SourceMapGenerator,$Ze=au.existsSync,WZe=au.readFileSync,l8=au.dirname,GZe=au.join;function YZe(t){return Buffer?Buffer.from(t,"base64").toString():window.atob(t)}var cK=(function(){function t(i,n){if(n.map!==!1){this.loadAnnotation(i),this.inline=this.startWith(this.annotation,"data:");var r=n.map?n.map.prev:void 0,o=this.loadMap(n.from,r);!this.mapFile&&n.from&&(this.mapFile=n.from),this.mapFile&&(this.root=l8(this.mapFile)),o&&(this.text=o)}}var e=t.prototype;return e.consumer=function(){return this.consumerCache||(this.consumerCache=new Iae(this.text)),this.consumerCache},e.decodeInline=function(n){var r=/^data:application\/json;charset=utf-?8;base64,/,o=/^data:application\/json;base64,/,a=/^data:application\/json;charset=utf-?8,/,s=/^data:application\/json,/;if(a.test(n)||s.test(n))return decodeURIComponent(n.substr(RegExp.lastMatch.length));if(r.test(n)||o.test(n))return YZe(n.substr(RegExp.lastMatch.length));var l=n.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+l)},e.getAnnotationURL=function(n){return n.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()},e.isMap=function(n){return(typeof n>"u"?"undefined":Ui(n))!=="object"?!1:typeof n.mappings=="string"||typeof n._mappings=="string"||Array.isArray(n.sections)},e.loadAnnotation=function(n){var r=n.match(/\/\*\s*# sourceMappingURL=/gm);if(r){var o=n.lastIndexOf(r.pop()),a=n.indexOf("*/",o);o>-1&&a>-1&&(this.annotation=this.getAnnotationURL(n.substring(o,a)))}},e.loadFile=function(n){if(this.root=l8(n),$Ze(n))return this.mapFile=n,WZe(n,"utf-8").toString().trim()},e.loadMap=function(n,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){var o=r(n);if(o){var a=this.loadFile(o);if(!a)throw new Error("Unable to load previous source map: "+o.toString());return a}}else{if(Ni(r,Iae))return Nae.fromSourceMap(r).toString();if(Ni(r,Nae))return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){var s=this.annotation;return n&&(s=GZe(l8(n),s)),this.loadFile(s)}}},e.startWith=function(n,r){return n?n.substr(0,r.length)===r:!1},e.withContent=function(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)},t})(),qAe=cK;cK.default=cK;var qZe=au.SourceMapConsumer,XZe=au.SourceMapGenerator,Fae=au.fileURLToPath,LH=au.pathToFileURL,dK=au.isAbsolute,fK=au.resolve,KZe=zZe.nanoid,u8=au,Bae=BQ,ZZe=qAe,c8=Symbol("fromOffsetCache"),JZe=!!(qZe&&XZe),jae=!!(fK&&dK),M5=(function(){function t(i,n){if(n===void 0&&(n={}),i===null||typeof i>"u"||(typeof i>"u"?"undefined":Ui(i))==="object"&&!i.toString)throw new Error("PostCSS received "+i+" instead of CSS string");if(this.css=i.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,n.from&&(!jae||/^\w+:\/\//.test(n.from)||dK(n.from)?this.file=n.from:this.file=fK(n.from)),jae&&JZe){var r=new ZZe(this.css,n);if(r.text){this.map=r;var o=r.consumer().file;!this.file&&o&&(this.file=this.mapResolve(o))}}this.file||(this.id="<input css "+KZe(6)+">"),this.map&&(this.map.file=this.from)}var e=t.prototype;return e.error=function(n,r,o,a){a===void 0&&(a={});var s,l,u;if(r&&(typeof r>"u"?"undefined":Ui(r))==="object"){var c=r,d=o;if(typeof c.offset=="number"){var f=this.fromOffset(c.offset);r=f.line,o=f.col}else r=c.line,o=c.column;if(typeof d.offset=="number"){var h=this.fromOffset(d.offset);l=h.line,u=h.col}else l=d.line,u=d.column}else if(!o){var p=this.fromOffset(r);r=p.line,o=p.col}var g=this.origin(r,o,l,u);return g?s=new Bae(n,g.endLine===void 0?g.line:{column:g.column,line:g.line},g.endLine===void 0?g.column:{column:g.endColumn,line:g.endLine},g.source,g.file,a.plugin):s=new Bae(n,l===void 0?r:{column:o,line:r},l===void 0?o:{column:u,line:l},this.css,this.file,a.plugin),s.input={column:o,endColumn:u,endLine:l,line:r,source:this.css},this.file&&(LH&&(s.input.url=LH(this.file).toString()),s.input.file=this.file),s},e.fromOffset=function(n){var r,o;if(this[c8])o=this[c8];else{var a=this.css.split(`
`);o=new Array(a.length);for(var s=0,l=0,u=a.length;l<u;l++)o[l]=s,s+=a[l].length+1;this[c8]=o}r=o[o.length-1];var c=0;if(n>=r)c=o.length-1;else for(var d=o.length-2,f;c<d;)if(f=c+(d-c>>1),n<o[f])d=f-1;else if(n>=o[f+1])c=f+1;else{c=f;break}return{col:n-o[c]+1,line:c+1}},e.mapResolve=function(n){return/^\w+:\/\//.test(n)?n:fK(this.map.consumer().sourceRoot||this.map.root||".",n)},e.origin=function(n,r,o,a){if(!this.map)return!1;var s=this.map.consumer(),l=s.originalPositionFor({column:r,line:n});if(!l.source)return!1;var u;typeof o=="number"&&(u=s.originalPositionFor({column:a,line:o}));var c;dK(l.source)?c=LH(l.source):c=new URL(l.source,this.map.consumer().sourceRoot||LH(this.map.mapFile));var d={column:l.column,endColumn:u&&u.column,endLine:u&&u.line,line:l.line,url:c.toString()};if(c.protocol==="file:")if(Fae)d.file=Fae(c);else throw new Error("file: protocol is not available in this PostCSS build");var f=s.sourceContentFor(l.source);return f&&(d.source=f),d},e.toJSON=function(){for(var n={},r=0,o=["hasBOM","css","file","id"];r<o.length;r++){var a=o[r];this[a]!=null&&(n[a]=this[a])}return this.map&&(n.map=Zn({},this.map),n.map.consumerCache&&(n.map.consumerCache=void 0)),n},Is(t,[{key:"from",get:function(){return this.file||this.id}}]),t})(),Z$=M5;M5.default=M5;u8&&u8.registerInput&&u8.registerInput(M5);var XAe=au.SourceMapConsumer,MU=au.SourceMapGenerator,LU=au.dirname,KAe=au.relative,ZAe=au.resolve,JAe=au.sep,Vae=au.pathToFileURL,QZe=Z$,eJe=!!(XAe&&MU),tJe=!!(LU&&ZAe&&KAe&&JAe),rJe=(function(){function t(i,n,r,o){this.stringify=i,this.mapOpts=r.map||{},this.root=n,this.opts=r,this.css=o,this.originalCSS=o,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}var e=t.prototype;return e.addAnnotation=function(){var n;this.isInline()?n="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?n=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?n=this.mapOpts.annotation(this.opts.to,this.root):n=this.outputFile()+".map";var r=`
`;this.css.includes(`\r
`)&&(r=`\r
`),this.css+=r+"/*# sourceMappingURL="+n+" */"},e.applyPrevMaps=function(){for(var n=Ur(this.previous()),r;!(r=n()).done;){var o=r.value,a=this.toUrl(this.path(o.file)),s=o.root||LU(o.file),l=void 0;this.mapOpts.sourcesContent===!1?(l=new XAe(o.text),l.sourcesContent&&(l.sourcesContent=null)):l=o.consumer(),this.map.applySourceMap(l,a,this.toUrl(this.path(s)))}},e.clearAnnotation=function(){if(this.mapOpts.annotation!==!1)if(this.root)for(var n,r=this.root.nodes.length-1;r>=0;r--)n=this.root.nodes[r],n.type==="comment"&&n.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(r);else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))},e.generate=function(){if(this.clearAnnotation(),tJe&&eJe&&this.isMap())return this.generateMap();var n="";return this.stringify(this.root,function(r){n+=r}),[n]},e.generateMap=function(){if(this.root)this.generateString();else if(this.previous().length===1){var n=this.previous()[0].consumer();n.file=this.outputFile(),this.map=MU.fromSourceMap(n,{ignoreInvalidMapping:!0})}else this.map=new MU({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]},e.generateString=function(){var n=this;this.css="",this.map=new MU({file:this.outputFile(),ignoreInvalidMapping:!0});var r=1,o=1,a="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},l,u;this.stringify(this.root,function(c,d,f){if(n.css+=c,d&&f!=="end"&&(s.generated.line=r,s.generated.column=o-1,d.source&&d.source.start?(s.source=n.sourcePath(d),s.original.line=d.source.start.line,s.original.column=d.source.start.column-1,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,n.map.addMapping(s))),l=c.match(/\n/g),l?(r+=l.length,u=c.lastIndexOf(`
`),o=c.length-u):o+=c.length,d&&f!=="start"){var h=d.parent||{raws:{}},p=d.type==="decl"||d.type==="atrule"&&!d.nodes;(!p||d!==h.last||h.raws.semicolon)&&(d.source&&d.source.end?(s.source=n.sourcePath(d),s.original.line=d.source.end.line,s.original.column=d.source.end.column-1,s.generated.line=r,s.generated.column=o-2,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,s.generated.line=r,s.generated.column=o-1,n.map.addMapping(s)))}})},e.isAnnotation=function(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(function(n){return n.annotation}):!0},e.isInline=function(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;var n=this.mapOpts.annotation;return typeof n<"u"&&n!==!0?!1:this.previous().length?this.previous().some(function(r){return r.inline}):!0},e.isMap=function(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0},e.isSourcesContent=function(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(function(n){return n.withContent()}):!0},e.outputFile=function(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"},e.path=function(n){if(this.mapOpts.absolute||n.charCodeAt(0)===60||/^\w+:\/\//.test(n))return n;var r=this.memoizedPaths.get(n);if(r)return r;var o=this.opts.to?LU(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(o=LU(ZAe(o,this.mapOpts.annotation)));var a=KAe(o,n);return this.memoizedPaths.set(n,a),a},e.previous=function(){var n=this;if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(function(o){if(o.source&&o.source.input.map){var a=o.source.input.map;n.previousMaps.includes(a)||n.previousMaps.push(a)}});else{var r=new QZe(this.originalCSS,this.opts);r.map&&this.previousMaps.push(r.map)}return this.previousMaps},e.setSourcesContent=function(){var n=this,r={};if(this.root)this.root.walk(function(a){if(a.source){var s=a.source.input.from;if(s&&!r[s]){r[s]=!0;var l=n.usesFileUrls?n.toFileUrl(s):n.toUrl(n.path(s));n.map.setSourceContent(l,a.source.input.css)}}});else if(this.css){var o=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(o,this.css)}},e.sourcePath=function(n){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(n.source.input.from):this.toUrl(this.path(n.source.input.from))},e.toBase64=function(n){return Buffer?Buffer.from(n).toString("base64"):window.btoa(unescape(encodeURIComponent(n)))},e.toFileUrl=function(n){var r=this.memoizedFileURLs.get(n);if(r)return r;if(Vae){var o=Vae(n).toString();return this.memoizedFileURLs.set(n,o),o}else throw new Error("`map.absolute` option is not available in this PostCSS build")},e.toUrl=function(n){var r=this.memoizedURLs.get(n);if(r)return r;JAe==="\\"&&(n=n.replace(/\\/g,"/"));var o=encodeURI(n).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(n,o),o},t})(),QAe=rJe,iJe=X$,hK=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="comment",n}return e})(iJe),J$=hK;hK.default=hK;var eOe=NP.isClean,tOe=NP.my,rOe=K$,iOe=J$,nJe=X$,nOe,jQ,VQ,oOe;function aOe(t){return t.map(function(e){return e.nodes&&(e.nodes=aOe(e.nodes)),delete e.source,e})}function sOe(t){if(t[eOe]=!1,t.proxyOf.nodes)for(var e=Ur(t.proxyOf.nodes),i;!(i=e()).done;){var n=i.value;sOe(n)}}var TS=(function(t){Ks(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];for(var s=Ur(o),l;!(l=s()).done;)for(var u=l.value,c=this.normalize(u,this.last),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.push(h)}return this.markDirty(),this},i.cleanRaws=function(r){if(t.prototype.cleanRaws.call(this,r),this.nodes)for(var o=Ur(this.nodes),a;!(a=o()).done;){var s=a.value;s.cleanRaws(r)}},i.each=function(r){if(this.proxyOf.nodes){for(var o=this.getIterator(),a,s;this.indexes[o]<this.proxyOf.nodes.length&&(a=this.indexes[o],s=r(this.proxyOf.nodes[a],a),s!==!1);)this.indexes[o]+=1;return delete this.indexes[o],s}},i.every=function(r){return this.nodes.every(r)},i.getIterator=function(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;var r=this.lastEach;return this.indexes[r]=0,r},i.getProxyProcessor=function(){return{get:function(o,a){return a==="proxyOf"?o:o[a]?a==="each"||typeof a=="string"&&a.startsWith("walk")?function(){for(var s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];var c;return(c=o)[a].apply(c,[].concat(l.map(function(d){return typeof d=="function"?function(f,h){return d(f.toProxy(),h)}:d})))}:a==="every"||a==="some"?function(s){return o[a](function(l){for(var u=arguments.length,c=new Array(u>1?u-1:0),d=1;d<u;d++)c[d-1]=arguments[d];return s.apply(void 0,[].concat([l.toProxy()],c))})}:a==="root"?function(){return o.root().toProxy()}:a==="nodes"?o.nodes.map(function(s){return s.toProxy()}):a==="first"||a==="last"?o[a].toProxy():o[a]:o[a]},set:function(o,a,s){return o[a]===s||(o[a]=s,(a==="name"||a==="params"||a==="selector")&&o.markDirty()),!0}}},i.index=function(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))},i.insertAfter=function(r,o){var a=this.index(r),s=this.normalize(o,this.proxyOf.nodes[a]).reverse();a=this.index(r);for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;this.proxyOf.nodes.splice(a+1,0,c)}var d;for(var f in this.indexes)d=this.indexes[f],a<d&&(this.indexes[f]=d+s.length);return this.markDirty(),this},i.insertBefore=function(r,o){var a=this.index(r),s=a===0?"prepend":!1,l=this.normalize(o,this.proxyOf.nodes[a],s).reverse();a=this.index(r);for(var u=Ur(l),c;!(c=u()).done;){var d=c.value;this.proxyOf.nodes.splice(a,0,d)}var f;for(var h in this.indexes)f=this.indexes[h],a<=f&&(this.indexes[h]=f+l.length);return this.markDirty(),this},i.normalize=function(r,o){var a=this;if(typeof r=="string")r=aOe(nOe(r).nodes);else if(typeof r>"u")r=[];else if(Array.isArray(r)){r=r.slice(0);for(var s=Ur(r),l;!(l=s()).done;){var u=l.value;u.parent&&u.parent.removeChild(u,"ignore")}}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(var c=Ur(r),d;!(d=c()).done;){var f=d.value;f.parent&&f.parent.removeChild(f,"ignore")}}else if(r.type)r=[r];else if(r.prop){if(typeof r.value>"u")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new rOe(r)]}else if(r.selector)r=[new jQ(r)];else if(r.name)r=[new VQ(r)];else if(r.text)r=[new iOe(r)];else throw new Error("Unknown node type in node creation");var h=r.map(function(p){return p[tOe]||e.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[eOe]&&sOe(p),typeof p.raws.before>"u"&&o&&typeof o.raws.before<"u"&&(p.raws.before=o.raws.before.replace(/\S/g,"")),p.parent=a.proxyOf,p});return h},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];o=o.reverse();for(var s=Ur(o),l;!(l=s()).done;){for(var u=l.value,c=this.normalize(u,this.first,"prepend").reverse(),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.unshift(h)}for(var p in this.indexes)this.indexes[p]=this.indexes[p]+c.length}return this.markDirty(),this},i.push=function(r){return r.parent=this,this.proxyOf.nodes.push(r),this},i.removeAll=function(){for(var r=Ur(this.proxyOf.nodes),o;!(o=r()).done;){var a=o.value;a.parent=void 0}return this.proxyOf.nodes=[],this.markDirty(),this},i.removeChild=function(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);var o;for(var a in this.indexes)o=this.indexes[a],o>=r&&(this.indexes[a]=o-1);return this.markDirty(),this},i.replaceValues=function(r,o,a){return a||(a=o,o={}),this.walkDecls(function(s){o.props&&!o.props.includes(s.prop)||o.fast&&!s.value.includes(o.fast)||(s.value=s.value.replace(r,a))}),this.markDirty(),this},i.some=function(r){return this.nodes.some(r)},i.walk=function(r){return this.each(function(o,a){var s;try{s=r(o,a)}catch(l){throw o.addToError(l)}return s!==!1&&o.walk&&(s=o.walk(r)),s})},i.walkAtRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="atrule"&&r.test(a.name))return o(a,s)}):this.walk(function(a,s){if(a.type==="atrule"&&a.name===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="atrule")return o(a,s)}))},i.walkComments=function(r){return this.walk(function(o,a){if(o.type==="comment")return r(o,a)})},i.walkDecls=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="decl"&&r.test(a.prop))return o(a,s)}):this.walk(function(a,s){if(a.type==="decl"&&a.prop===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="decl")return o(a,s)}))},i.walkRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="rule"&&r.test(a.selector))return o(a,s)}):this.walk(function(a,s){if(a.type==="rule"&&a.selector===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="rule")return o(a,s)}))},Is(e,[{key:"first",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}},{key:"last",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}]),e})(nJe);TS.registerParse=function(t){nOe=t};TS.registerRule=function(t){jQ=t};TS.registerAtRule=function(t){VQ=t};TS.registerRoot=function(t){oOe=t};var jD=TS;TS.default=TS;TS.rebuild=function(t){t.type==="atrule"?Object.setPrototypeOf(t,VQ.prototype):t.type==="rule"?Object.setPrototypeOf(t,jQ.prototype):t.type==="decl"?Object.setPrototypeOf(t,rOe.prototype):t.type==="comment"?Object.setPrototypeOf(t,iOe.prototype):t.type==="root"&&Object.setPrototypeOf(t,oOe.prototype),t[tOe]=!0,t.nodes&&t.nodes.forEach(function(e){TS.rebuild(e)})};var oJe=jD,lOe,uOe,r3=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,Zn({type:"document"},n))||this,r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.toResult=function(r){r===void 0&&(r={});var o=new lOe(new uOe,this,r);return o.stringify()},e})(oJe);r3.registerLazyResult=function(t){lOe=t};r3.registerProcessor=function(t){uOe=t};var HQ=r3;r3.default=r3;var pK=(function(){function t(i,n){if(n===void 0&&(n={}),this.type="warning",this.text=i,n.node&&n.node.source){var r=n.node.rangeBy(n);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(var o in n)this[o]=n[o]}var e=t.prototype;return e.toString=function(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text},t})(),cOe=pK;pK.default=pK;var aJe=cOe,gK=(function(){function t(i,n,r){this.processor=i,this.messages=[],this.root=n,this.opts=r,this.css=void 0,this.map=void 0}var e=t.prototype;return e.toString=function(){return this.css},e.warn=function(n,r){r===void 0&&(r={}),r.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(r.plugin=this.lastPlugin.postcssPlugin);var o=new aJe(n,r);return this.messages.push(o),o},e.warnings=function(){return this.messages.filter(function(n){return n.type==="warning"})},Is(t,[{key:"content",get:function(){return this.css}}]),t})(),UQ=gK;gK.default=gK;var d8=39,Hae=34,kH=92,Uae=47,IH=10,Y2=32,NH=12,FH=9,BH=13,sJe=91,lJe=93,uJe=40,cJe=41,dJe=123,fJe=125,hJe=59,pJe=42,gJe=58,vJe=64,jH=/[\t\n\f\r "#'()/;[\\\]{}]/g,VH=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,yJe=/.[\r\n"'(/\\]/,zae=/[\da-f]/i,mJe=function(e,i){i===void 0&&(i={});var n=e.css.valueOf(),r=i.ignoreErrors,o,a,s,l,u,c,d,f,h,p,g=n.length,v=0,y=[],m=[];function b(){return v}function S(x){throw e.error("Unclosed "+x,v)}function _(){return m.length===0&&v>=g}function C(x){if(m.length)return m.pop();if(!(v>=g)){var E=x?x.ignoreUnclosed:!1;switch(o=n.charCodeAt(v),o){case IH:case Y2:case FH:case BH:case NH:{a=v;do a+=1,o=n.charCodeAt(a);while(o===Y2||o===IH||o===FH||o===BH||o===NH);p=["space",n.slice(v,a)],v=a-1;break}case sJe:case lJe:case dJe:case fJe:case gJe:case hJe:case cJe:{var A=String.fromCharCode(o);p=[A,A,v];break}case uJe:{if(f=y.length?y.pop()[1]:"",h=n.charCodeAt(v+1),f==="url"&&h!==d8&&h!==Hae&&h!==Y2&&h!==IH&&h!==FH&&h!==NH&&h!==BH){a=v;do{if(c=!1,a=n.indexOf(")",a+1),a===-1)if(r||E){a=v;break}else S("bracket");for(d=a;n.charCodeAt(d-1)===kH;)d-=1,c=!c}while(c);p=["brackets",n.slice(v,a+1),v,a],v=a}else a=n.indexOf(")",v+1),l=n.slice(v,a+1),a===-1||yJe.test(l)?p=["(","(",v]:(p=["brackets",l,v,a],v=a);break}case d8:case Hae:{s=o===d8?"'":'"',a=v;do{if(c=!1,a=n.indexOf(s,a+1),a===-1)if(r||E){a=v+1;break}else S("string");for(d=a;n.charCodeAt(d-1)===kH;)d-=1,c=!c}while(c);p=["string",n.slice(v,a+1),v,a],v=a;break}case vJe:{jH.lastIndex=v+1,jH.test(n),jH.lastIndex===0?a=n.length-1:a=jH.lastIndex-2,p=["at-word",n.slice(v,a+1),v,a],v=a;break}case kH:{for(a=v,u=!0;n.charCodeAt(a+1)===kH;)a+=1,u=!u;if(o=n.charCodeAt(a+1),u&&o!==Uae&&o!==Y2&&o!==IH&&o!==FH&&o!==BH&&o!==NH&&(a+=1,zae.test(n.charAt(a)))){for(;zae.test(n.charAt(a+1));)a+=1;n.charCodeAt(a+1)===Y2&&(a+=1)}p=["word",n.slice(v,a+1),v,a],v=a;break}default:{o===Uae&&n.charCodeAt(v+1)===pJe?(a=n.indexOf("*/",v+2)+1,a===0&&(r||E?a=n.length:S("comment")),p=["comment",n.slice(v,a+1),v,a],v=a):(VH.lastIndex=v+1,VH.test(n),VH.lastIndex===0?a=n.length-1:a=VH.lastIndex-2,p=["word",n.slice(v,a+1),v,a],y.push(p),v=a);break}}return v++,p}}function P(x){m.push(x)}return{back:P,endOfFile:_,nextToken:C,position:b}},dOe=jD,L5=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="atrule",r}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.append).call.apply(s,[].concat([this],o))},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.prepend).call.apply(s,[].concat([this],o))},e})(dOe),zQ=L5;L5.default=L5;dOe.registerAtRule(L5);var fOe=jD,hOe,pOe,Tk=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="root",r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.normalize=function(r,o,a){var s=t.prototype.normalize.call(this,r);if(o){if(a==="prepend")this.nodes.length>1?o.raws.before=this.nodes[1].raws.before:delete o.raws.before;else if(this.first!==o)for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;c.raws.before=o.raws.before}}return s},i.removeChild=function(r,o){var a=this.index(r);return!o&&a===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[a].raws.before),t.prototype.removeChild.call(this,r)},i.toResult=function(r){r===void 0&&(r={});var o=new hOe(new pOe,this,r);return o.stringify()},e})(fOe);Tk.registerLazyResult=function(t){hOe=t};Tk.registerProcessor=function(t){pOe=t};var bV=Tk;Tk.default=Tk;fOe.registerRoot(Tk);var i3={comma:function(e){return i3.split(e,[","],!0)},space:function(e){var i=[" ",`
`,"	"];return i3.split(e,i)},split:function(e,i,n){for(var r=[],o="",a=!1,s=0,l=!1,u="",c=!1,d=Ur(e),f;!(f=d()).done;){var h=f.value;c?c=!1:h==="\\"?c=!0:l?h===u&&(l=!1):h==='"'||h==="'"?(l=!0,u=h):h==="("?s+=1:h===")"?s>0&&(s-=1):s===0&&i.includes(h)&&(a=!0),a?(o!==""&&r.push(o.trim()),o="",a=!1):o+=h}return(n||o!=="")&&r.push(o.trim()),r}},gOe=i3;i3.default=i3;var vOe=jD,bJe=gOe,k5=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="rule",n.nodes||(n.nodes=[]),n}return Is(e,[{key:"selectors",get:function(){return bJe.comma(this.selector)},set:function(n){var r=this.selector?this.selector.match(/,\s*/):null,o=r?r[0]:","+this.raw("between","beforeOpen");this.selector=n.join(o)}}]),e})(vOe),$Q=k5;k5.default=k5;vOe.registerRule(k5);var SJe=K$,_Je=mJe,PJe=J$,CJe=zQ,TJe=bV,$ae=$Q,Wae={empty:!0,space:!0};function xJe(t){for(var e=t.length-1;e>=0;e--){var i=t[e],n=i[3]||i[2];if(n)return n}}var EJe=(function(){function t(i){this.input=i,this.root=new TJe,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:i,start:{column:1,line:1,offset:0}}}var e=t.prototype;return e.atrule=function(n){var r=new CJe;r.name=n[1].slice(1),r.name===""&&this.unnamedAtrule(r,n),this.init(r,n[2]);for(var o,a,s,l=!1,u=!1,c=[],d=[];!this.tokenizer.endOfFile();){if(n=this.tokenizer.nextToken(),o=n[0],o==="("||o==="["?d.push(o==="("?")":"]"):o==="{"&&d.length>0?d.push("}"):o===d[d.length-1]&&d.pop(),d.length===0)if(o===";"){r.source.end=this.getPosition(n[2]),r.source.end.offset++,this.semicolon=!0;break}else if(o==="{"){u=!0;break}else if(o==="}"){if(c.length>0){for(s=c.length-1,a=c[s];a&&a[0]==="space";)a=c[--s];a&&(r.source.end=this.getPosition(a[3]||a[2]),r.source.end.offset++)}this.end(n);break}else c.push(n);else c.push(n);if(this.tokenizer.endOfFile()){l=!0;break}}r.raws.between=this.spacesAndCommentsFromEnd(c),c.length?(r.raws.afterName=this.spacesAndCommentsFromStart(c),this.raw(r,"params",c),l&&(n=c[c.length-1],r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++,this.spaces=r.raws.between,r.raws.between="")):(r.raws.afterName="",r.params=""),u&&(r.nodes=[],this.current=r)},e.checkMissedSemicolon=function(n){var r=this.colon(n);if(r!==!1){for(var o=0,a,s=r-1;s>=0&&(a=n[s],!(a[0]!=="space"&&(o+=1,o===2)));s--);throw this.input.error("Missed semicolon",a[0]==="word"?a[3]+1:a[2])}},e.colon=function(n){for(var r=0,o,a,s,l=Ur(n.entries()),u;!(u=l()).done;){var c=u.value,d=c[0],f=c[1];if(o=f,a=o[0],a==="("&&(r+=1),a===")"&&(r-=1),r===0&&a===":")if(!s)this.doubleColon(o);else{if(s[0]==="word"&&s[1]==="progid")continue;return d}s=o}return!1},e.comment=function(n){var r=new PJe;this.init(r,n[2]),r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++;var o=n[1].slice(2,-2);if(/^\s*$/.test(o))r.text="",r.raws.left=o,r.raws.right="";else{var a=o.match(/^(\s*)([^]*\S)(\s*)$/);r.text=a[2],r.raws.left=a[1],r.raws.right=a[3]}},e.createTokenizer=function(){this.tokenizer=_Je(this.input)},e.decl=function(n,r){var o=new SJe;this.init(o,n[0][2]);var a=n[n.length-1];for(a[0]===";"&&(this.semicolon=!0,n.pop()),o.source.end=this.getPosition(a[3]||a[2]||xJe(n)),o.source.end.offset++;n[0][0]!=="word";)n.length===1&&this.unknownWord(n),o.raws.before+=n.shift()[1];for(o.source.start=this.getPosition(n[0][2]),o.prop="";n.length;){var s=n[0][0];if(s===":"||s==="space"||s==="comment")break;o.prop+=n.shift()[1]}o.raws.between="";for(var l;n.length;)if(l=n.shift(),l[0]===":"){o.raws.between+=l[1];break}else l[0]==="word"&&/\w/.test(l[1])&&this.unknownWord([l]),o.raws.between+=l[1];(o.prop[0]==="_"||o.prop[0]==="*")&&(o.raws.before+=o.prop[0],o.prop=o.prop.slice(1));for(var u=[],c;n.length&&(c=n[0][0],!(c!=="space"&&c!=="comment"));)u.push(n.shift());this.precheckMissedSemicolon(n);for(var d=n.length-1;d>=0;d--){if(l=n[d],l[1].toLowerCase()==="!important"){o.important=!0;var f=this.stringFrom(n,d);f=this.spacesFromEnd(n)+f,f!==" !important"&&(o.raws.important=f);break}else if(l[1].toLowerCase()==="important"){for(var h=n.slice(0),p="",g=d;g>0;g--){var v=h[g][0];if(p.trim().indexOf("!")===0&&v!=="space")break;p=h.pop()[1]+p}p.trim().indexOf("!")===0&&(o.important=!0,o.raws.important=p,n=h)}if(l[0]!=="space"&&l[0]!=="comment")break}var y=n.some(function(m){return m[0]!=="space"&&m[0]!=="comment"});y&&(o.raws.between+=u.map(function(m){return m[1]}).join(""),u=[]),this.raw(o,"value",u.concat(n),r),o.value.includes(":")&&!r&&this.checkMissedSemicolon(n)},e.doubleColon=function(n){throw this.input.error("Double colon",{offset:n[2]},{offset:n[2]+n[1].length})},e.emptyRule=function(n){var r=new $ae;this.init(r,n[2]),r.selector="",r.raws.between="",this.current=r},e.end=function(n){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(n[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(n)},e.endFile=function(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())},e.freeSemicolon=function(n){if(this.spaces+=n[1],this.current.nodes){var r=this.current.nodes[this.current.nodes.length-1];r&&r.type==="rule"&&!r.raws.ownSemicolon&&(r.raws.ownSemicolon=this.spaces,this.spaces="")}},e.getPosition=function(n){var r=this.input.fromOffset(n);return{column:r.col,line:r.line,offset:n}},e.init=function(n,r){this.current.push(n),n.source={input:this.input,start:this.getPosition(r)},n.raws.before=this.spaces,this.spaces="",n.type!=="comment"&&(this.semicolon=!1)},e.other=function(n){for(var r=!1,o=null,a=!1,s=null,l=[],u=n[1].startsWith("--"),c=[],d=n;d;){if(o=d[0],c.push(d),o==="("||o==="[")s||(s=d),l.push(o==="("?")":"]");else if(u&&a&&o==="{")s||(s=d),l.push("}");else if(l.length===0)if(o===";")if(a){this.decl(c,u);return}else break;else if(o==="{"){this.rule(c);return}else if(o==="}"){this.tokenizer.back(c.pop()),r=!0;break}else o===":"&&(a=!0);else o===l[l.length-1]&&(l.pop(),l.length===0&&(s=null));d=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(r=!0),l.length>0&&this.unclosedBracket(s),r&&a){if(!u)for(;c.length&&(d=c[c.length-1][0],!(d!=="space"&&d!=="comment"));)this.tokenizer.back(c.pop());this.decl(c,u)}else this.unknownWord(c)},e.parse=function(){for(var n;!this.tokenizer.endOfFile();)switch(n=this.tokenizer.nextToken(),n[0]){case"space":this.spaces+=n[1];break;case";":this.freeSemicolon(n);break;case"}":this.end(n);break;case"comment":this.comment(n);break;case"at-word":this.atrule(n);break;case"{":this.emptyRule(n);break;default:this.other(n);break}this.endFile()},e.precheckMissedSemicolon=function(){},e.raw=function(n,r,o,a){for(var s,l,u=o.length,c="",d=!0,f,h,p=0;p<u;p+=1)s=o[p],l=s[0],l==="space"&&p===u-1&&!a?d=!1:l==="comment"?(h=o[p-1]?o[p-1][0]:"empty",f=o[p+1]?o[p+1][0]:"empty",!Wae[h]&&!Wae[f]?c.slice(-1)===","?d=!1:c+=s[1]:d=!1):c+=s[1];if(!d){var g=o.reduce(function(v,y){return v+y[1]},"");n.raws[r]={raw:g,value:c}}n[r]=c},e.rule=function(n){n.pop();var r=new $ae;this.init(r,n[0][2]),r.raws.between=this.spacesAndCommentsFromEnd(n),this.raw(r,"selector",n),this.current=r},e.spacesAndCommentsFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],!(r!=="space"&&r!=="comment"));)o=n.pop()[1]+o;return o},e.spacesAndCommentsFromStart=function(n){for(var r,o="";n.length&&(r=n[0][0],!(r!=="space"&&r!=="comment"));)o+=n.shift()[1];return o},e.spacesFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],r==="space");)o=n.pop()[1]+o;return o},e.stringFrom=function(n,r){for(var o="",a=r;a<n.length;a++)o+=n[a][1];return n.splice(r,n.length-r),o},e.unclosedBlock=function(){var n=this.current.source.start;throw this.input.error("Unclosed block",n.line,n.column)},e.unclosedBracket=function(n){throw this.input.error("Unclosed bracket",{offset:n[2]},{offset:n[2]+1})},e.unexpectedClose=function(n){throw this.input.error("Unexpected }",{offset:n[2]},{offset:n[2]+1})},e.unknownWord=function(n){throw this.input.error("Unknown word",{offset:n[0][2]},{offset:n[0][2]+n[0][1].length})},e.unnamedAtrule=function(n,r){throw this.input.error("At-rule without name",{offset:r[2]},{offset:r[2]+r[1].length})},t})(),wJe=EJe,AJe=jD,OJe=wJe,DJe=Z$;function I5(t,e){var i=new DJe(t,e),n=new OJe(i);try{n.parse()}catch(r){throw r}return n.root}var WQ=I5;I5.default=I5;AJe.registerParse(I5);var wy=NP.isClean,RJe=NP.my,MJe=QAe,LJe=q$,kJe=jD,IJe=HQ,Gae=UQ,NJe=WQ,FJe=bV,BJe={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},jJe={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},VJe={Once:!0,postcssPlugin:!0,prepare:!0},xk=0;function q2(t){return(typeof t>"u"?"undefined":Ui(t))==="object"&&typeof t.then=="function"}function yOe(t){var e=!1,i=BJe[t.type];return t.type==="decl"?e=t.prop.toLowerCase():t.type==="atrule"&&(e=t.name.toLowerCase()),e&&t.append?[i,i+"-"+e,xk,i+"Exit",i+"Exit-"+e]:e?[i,i+"-"+e,i+"Exit",i+"Exit-"+e]:t.append?[i,xk,i+"Exit"]:[i,i+"Exit"]}function Yae(t){var e;return t.type==="document"?e=["Document",xk,"DocumentExit"]:t.type==="root"?e=["Root",xk,"RootExit"]:e=yOe(t),{eventIndex:0,events:e,iterator:0,node:t,visitorIndex:0,visitors:[]}}function vK(t){return t[wy]=!1,t.nodes&&t.nodes.forEach(function(e){return vK(e)}),t}var yK={},Ek=(function(){function t(i,n,r){var o=this;this.stringified=!1,this.processed=!1;var a;if((typeof n>"u"?"undefined":Ui(n))==="object"&&n!==null&&(n.type==="root"||n.type==="document"))a=vK(n);else if(Ni(n,t)||Ni(n,Gae))a=vK(n.root),n.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=n.map);else{var s=NJe;r.syntax&&(s=r.syntax.parse),r.parser&&(s=r.parser),s.parse&&(s=s.parse);try{a=s(n,r)}catch(l){this.processed=!0,this.error=l}a&&!a[RJe]&&kJe.rebuild(a)}this.result=new Gae(i,a,r),this.helpers=Zn({},yK,{postcss:yK,result:this.result}),this.plugins=this.processor.plugins.map(function(l){return(typeof l>"u"?"undefined":Ui(l))==="object"&&l.prepare?Zn({},l,l.prepare(o.result)):l})}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.getAsyncError=function(){throw new Error("Use process(css).then(cb) to work with async plugins")},e.handleError=function(n,r){var o=this.result.lastPlugin;try{if(r&&r.addToError(n),this.error=n,n.name==="CssSyntaxError"&&!n.plugin)n.plugin=o.postcssPlugin,n.setMessage();else if(o.postcssVersion)var a,s,l,u,c}catch(d){console&&console.error&&console.error(d)}return n},e.prepareVisitors=function(){var n=this;this.listeners={};for(var r=function(c,d,f){n.listeners[d]||(n.listeners[d]=[]),n.listeners[d].push([c,f])},o=Ur(this.plugins),a;!(a=o()).done;){var s=a.value;if((typeof s>"u"?"undefined":Ui(s))==="object")for(var l in s){if(!jJe[l]&&/^[A-Z]/.test(l))throw new Error("Unknown event "+l+" in "+s.postcssPlugin+". Try to update PostCSS ("+this.processor.version+" now).");if(!VJe[l])if(Ui(s[l])==="object")for(var u in s[l])u==="*"?r(s,l,s[l][u]):r(s,l+"-"+u.toLowerCase(),s[l][u]);else typeof s[l]=="function"&&r(s,l,s[l])}}this.hasListener=Object.keys(this.listeners).length>0},e.runAsync=function(){var n=this;return U$(function(){var r,o,a,s,l,u,c,d,f,h,p,g;return CD(this,function(v){switch(v.label){case 0:n.plugin=0,r=0,v.label=1;case 1:if(!(r<n.plugins.length))return[3,6];if(o=n.plugins[r],a=n.runOnRoot(o),!q2(a))return[3,5];v.label=2;case 2:return v.trys.push([2,4,,5]),[4,a];case 3:return v.sent(),[3,5];case 4:throw s=v.sent(),n.handleError(s);case 5:return r++,[3,1];case 6:if(n.prepareVisitors(),!n.hasListener)return[3,18];l=n.result.root,v.label=7;case 7:if(l[wy])return[3,14];l[wy]=!0,u=[Yae(l)],v.label=8;case 8:if(!(u.length>0))return[3,13];if(c=n.visitTick(u),!q2(c))return[3,12];v.label=9;case 9:return v.trys.push([9,11,,12]),[4,c];case 10:return v.sent(),[3,12];case 11:throw d=v.sent(),f=u[u.length-1].node,n.handleError(d,f);case 12:return[3,8];case 13:return[3,7];case 14:if(!n.listeners.OnceExit)return[3,18];h=function(){var y,m,b,S,_;return CD(this,function(C){switch(C.label){case 0:y=g.value,m=y[0],b=y[1],n.result.lastPlugin=m,C.label=1;case 1:return C.trys.push([1,6,,7]),l.type!=="document"?[3,3]:(S=l.nodes.map(function(P){return b(P,n.helpers)}),[4,Promise.all(S)]);case 2:return C.sent(),[3,5];case 3:return[4,b(l,n.helpers)];case 4:C.sent(),C.label=5;case 5:return[3,7];case 6:throw _=C.sent(),n.handleError(_);case 7:return[2]}})},p=Ur(n.listeners.OnceExit),v.label=15;case 15:return(g=p()).done?[3,18]:[5,TQ(h())];case 16:v.sent(),v.label=17;case 17:return[3,15];case 18:return n.processed=!0,[2,n.stringify()]}})})()},e.runOnRoot=function(n){var r=this;this.result.lastPlugin=n;try{if((typeof n>"u"?"undefined":Ui(n))==="object"&&n.Once){if(this.result.root.type==="document"){var o=this.result.root.nodes.map(function(a){return n.Once(a,r.helpers)});return q2(o[0])?Promise.all(o):o}return n.Once(this.result.root,this.helpers)}else if(typeof n=="function")return n(this.result.root,this.result)}catch(a){throw this.handleError(a)}},e.stringify=function(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();var n=this.result.opts,r=LJe;n.syntax&&(r=n.syntax.stringify),n.stringifier&&(r=n.stringifier),r.stringify&&(r=r.stringify);var o=new MJe(r,this.result.root,this.result.opts),a=o.generate();return this.result.css=a[0],this.result.map=a[1],this.result},e.sync=function(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(var n=Ur(this.plugins),r;!(r=n()).done;){var o=r.value,a=this.runOnRoot(o);if(q2(a))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){for(var s=this.result.root;!s[wy];)s[wy]=!0,this.walkSync(s);if(this.listeners.OnceExit)if(s.type==="document")for(var l=Ur(s.nodes),u;!(u=l()).done;){var c=u.value;this.visitSync(this.listeners.OnceExit,c)}else this.visitSync(this.listeners.OnceExit,s)}return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this.css},e.visitSync=function(n,r){for(var o=Ur(n),a;!(a=o()).done;){var s=a.value,l=s[0],u=s[1];this.result.lastPlugin=l;var c=void 0;try{c=u(r,this.helpers)}catch(d){throw this.handleError(d,r.proxyOf)}if(r.type!=="root"&&r.type!=="document"&&!r.parent)return!0;if(q2(c))throw this.getAsyncError()}},e.visitTick=function(n){var r=n[n.length-1],o=r.node,a=r.visitors;if(o.type!=="root"&&o.type!=="document"&&!o.parent){n.pop();return}if(a.length>0&&r.visitorIndex<a.length){var s=a[r.visitorIndex],l=s[0],u=s[1];r.visitorIndex+=1,r.visitorIndex===a.length&&(r.visitors=[],r.visitorIndex=0),this.result.lastPlugin=l;try{return u(o.toProxy(),this.helpers)}catch(p){throw this.handleError(p,o)}}if(r.iterator!==0){for(var c=r.iterator,d;d=o.nodes[o.indexes[c]];)if(o.indexes[c]+=1,!d[wy]){d[wy]=!0,n.push(Yae(d));return}r.iterator=0,delete o.indexes[c]}for(var f=r.events;r.eventIndex<f.length;){var h=f[r.eventIndex];if(r.eventIndex+=1,h===xk){o.nodes&&o.nodes.length&&(o[wy]=!0,r.iterator=o.getIterator());return}else if(this.listeners[h]){r.visitors=this.listeners[h];return}}n.pop()},e.walkSync=function(n){var r=this;n[wy]=!0;for(var o=yOe(n),a=Ur(o),s;!(s=a()).done;){var l=s.value;if(l===xk)n.nodes&&n.each(function(c){c[wy]||r.walkSync(c)});else{var u=this.listeners[l];if(u&&this.visitSync(u,n.toProxy()))return}}},e.warnings=function(){return this.sync().warnings()},Is(t,[{key:"content",get:function(){return this.stringify().content}},{key:"css",get:function(){return this.stringify().css}},{key:"map",get:function(){return this.stringify().map}},{key:"messages",get:function(){return this.sync().messages}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){return this.sync().root}},{key:Symbol.toStringTag,get:function(){return"LazyResult"}}]),t})();Ek.registerPostcss=function(t){yK=t};var mOe=Ek;Ek.default=Ek;FJe.registerLazyResult(Ek);IJe.registerLazyResult(Ek);var HJe=QAe,UJe=q$,zJe=WQ,$Je=UQ,mK=(function(){function t(i,n,r){n=n.toString(),this.stringified=!1,this._processor=i,this._css=n,this._opts=r,this._map=void 0;var o,a=UJe;this.result=new $Je(this._processor,o,this._opts),this.result.css=n;var s=this;Object.defineProperty(this.result,"root",{get:function(){return s.root}});var l=new HJe(a,o,this._opts,n);if(l.isMap()){var u=l.generate(),c=u[0],d=u[1];c&&(this.result.css=c),d&&(this.result.map=d)}else l.clearAnnotation(),this.result.css=l.css}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.sync=function(){if(this.error)throw this.error;return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this._css},e.warnings=function(){return[]},Is(t,[{key:"content",get:function(){return this.result.css}},{key:"css",get:function(){return this.result.css}},{key:"map",get:function(){return this.result.map}},{key:"messages",get:function(){return[]}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){if(this._root)return this._root;var n,r=zJe;try{n=r(this._css,this._opts)}catch(o){this.error=o}if(this.error)throw this.error;return this._root=n,n}},{key:Symbol.toStringTag,get:function(){return"NoWorkResult"}}]),t})(),WJe=mK;mK.default=mK;var GJe=WJe,YJe=mOe,qJe=HQ,XJe=bV,n3=(function(){function t(i){i===void 0&&(i=[]),this.version="8.4.38",this.plugins=this.normalize(i)}var e=t.prototype;return e.normalize=function(n){for(var r=[],o=Ur(n),a;!(a=o()).done;){var s=a.value;if(s.postcss===!0?s=s():s.postcss&&(s=s.postcss),(typeof s>"u"?"undefined":Ui(s))==="object"&&Array.isArray(s.plugins))r=r.concat(s.plugins);else if((typeof s>"u"?"undefined":Ui(s))==="object"&&s.postcssPlugin)r.push(s);else if(typeof s=="function")r.push(s);else if(!((typeof s>"u"?"undefined":Ui(s))==="object"&&(s.parse||s.stringify)))throw new Error(s+" is not a PostCSS plugin")}return r},e.process=function(n,r){return r===void 0&&(r={}),!this.plugins.length&&!r.parser&&!r.stringifier&&!r.syntax?new GJe(this,n,r):new YJe(this,n,r)},e.use=function(n){return this.plugins=this.plugins.concat(this.normalize([n])),this},t})(),KJe=n3;n3.default=n3;XJe.registerProcessor(n3);qJe.registerProcessor(n3);var ZJe=K$,JJe=qAe,QJe=J$,eQe=zQ,tQe=Z$,rQe=bV,iQe=$Q;function o3(t,e){if(Array.isArray(t))return t.map(function(d){return o3(d)});var i=t.inputs,n=PD(t,["inputs"]);if(i){e=[];for(var r=Ur(i),o;!(o=r()).done;){var a=o.value,s=Zn({},a,{__proto__:tQe.prototype});s.map&&(s.map=Zn({},s.map,{__proto__:JJe.prototype})),e.push(s)}}if(n.nodes&&(n.nodes=t.nodes.map(function(d){return o3(d,e)})),n.source){var l=n.source,u=l.inputId,c=PD(l,["inputId"]);n.source=c,u!=null&&(n.source.input=e[u])}if(n.type==="root")return new rQe(n);if(n.type==="decl")return new ZJe(n);if(n.type==="rule")return new iQe(n);if(n.type==="comment")return new QJe(n);if(n.type==="atrule")return new eQe(n);throw new Error("Unknown node type: "+t.type)}var nQe=o3;o3.default=o3;var oQe=BQ,bOe=K$,aQe=mOe,sQe=jD,GQ=KJe,lQe=q$,uQe=nQe,SOe=HQ,cQe=cOe,_Oe=J$,POe=zQ,dQe=UQ,fQe=Z$,hQe=WQ,pQe=gOe,COe=$Q,TOe=bV,gQe=X$;function Ia(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return e.length===1&&Array.isArray(e[0])&&(e=e[0]),new GQ(e)}Ia.plugin=function(e,i){var n=!1;function r(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];console&&console.warn&&!n&&(n=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),Sk.LANG&&Sk.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
https://www.w3ctech.com/topic/2226`));var u=i.apply(void 0,[].concat(s));return u.postcssPlugin=e,u.postcssVersion=new GQ().version,u}var o;return Object.defineProperty(r,"postcss",{get:function(){return o||(o=r()),o}}),r.process=function(a,s,l){return Ia([r(l)]).process(a,s)},r};Ia.stringify=lQe;Ia.parse=hQe;Ia.fromJSON=uQe;Ia.list=pQe;Ia.comment=function(t){return new _Oe(t)};Ia.atRule=function(t){return new POe(t)};Ia.decl=function(t){return new bOe(t)};Ia.rule=function(t){return new COe(t)};Ia.root=function(t){return new TOe(t)};Ia.document=function(t){return new SOe(t)};Ia.CssSyntaxError=oQe;Ia.Declaration=bOe;Ia.Container=sQe;Ia.Processor=GQ;Ia.Document=SOe;Ia.Comment=_Oe;Ia.Warning=cQe;Ia.AtRule=POe;Ia.Result=dQe;Ia.Input=fQe;Ia.Rule=COe;Ia.Root=TOe;Ia.Node=gQe;aQe.registerPostcss(Ia);var vQe=Ia;Ia.default=Ia;var Js=OZe(vQe);Js.stringify;Js.fromJSON;Js.plugin;Js.parse;Js.list;Js.document;Js.comment;Js.atRule;Js.rule;Js.decl;Js.root;Js.CssSyntaxError;Js.Declaration;Js.Container;Js.Processor;Js.Document;Js.Comment;Js.Warning;Js.AtRule;Js.Result;Js.Input;Js.Rule;Js.Root;Js.Node;var yQe=(function(){function t(){for(var i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];hg(this,"parentElement",null),hg(this,"parentNode",null),hg(this,"ownerDocument"),hg(this,"firstChild",null),hg(this,"lastChild",null),hg(this,"previousSibling",null),hg(this,"nextSibling",null),hg(this,"ELEMENT_NODE",1),hg(this,"TEXT_NODE",3),hg(this,"nodeType"),hg(this,"nodeName"),hg(this,"RRNodeType")}var e=t.prototype;return e.contains=function(n){if(Ni(n,t)){if(n.ownerDocument!==this.ownerDocument)return!1;if(n===this)return!0}else return!1;for(;n.parentNode;){if(n.parentNode===this)return!0;n=n.parentNode}return!1},e.appendChild=function(n){throw new Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")},e.insertBefore=function(n,r){throw new Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")},e.removeChild=function(n){throw new Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")},e.toString=function(){return"RRNode"},Is(t,[{key:"childNodes",get:function(){for(var n=[],r=this.firstChild;r;)n.push(r),r=r.nextSibling;return n}}]),t})(),qae={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},Xae={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},HH={},mQe=function(){return!!globalThis.Zone};function YQ(t){if(HH[t])return HH[t];var e=globalThis[t],i=e.prototype,n=t in qae?qae[t]:void 0,r=!!(n&&n.every(function(c){var d,f;return!!((f=(d=Object.getOwnPropertyDescriptor(i,c))==null?void 0:d.get)!=null&&f.toString().includes("[native code]"))})),o=t in Xae?Xae[t]:void 0,a=!!(o&&o.every(function(c){var d;return typeof i[c]=="function"&&((d=i[c])==null?void 0:d.toString().includes("[native code]"))}));if(r&&a&&!mQe())return HH[t]=e.prototype,e.prototype;try{var s=document.createElement("iframe");document.body.appendChild(s);var l=s.contentWindow;if(!l)return e.prototype;var u=l[t].prototype;return document.body.removeChild(s),u?HH[t]=u:i}catch{return i}}var f8={};function FP(t,e,i){var n,r=t+"."+String(i);if(f8[r])return f8[r].call(e);var o=YQ(t),a=(n=Object.getOwnPropertyDescriptor(o,i))==null?void 0:n.get;return a?(f8[r]=a,a.call(e)):e[i]}var h8={};function xOe(t,e,i){var n=t+"."+String(i);if(h8[n])return h8[n].bind(e);var r=YQ(t),o=r[i];return typeof o!="function"?e[i]:(h8[n]=o,o.bind(e))}function bQe(t){return FP("Node",t,"childNodes")}function SQe(t){return FP("Node",t,"parentNode")}function _Qe(t){return FP("Node",t,"parentElement")}function PQe(t){return FP("Node",t,"textContent")}function CQe(t,e){return xOe("Node",t,"contains")(e)}function TQe(t){return xOe("Node",t,"getRootNode")()}function xQe(t){return!t||!("host"in t)?null:FP("ShadowRoot",t,"host")}function EQe(t){return t.styleSheets}function wQe(t){return!t||!("shadowRoot"in t)?null:FP("Element",t,"shadowRoot")}function AQe(t,e){return FP("Element",t,"querySelector")(e)}function OQe(t,e){return FP("Element",t,"querySelectorAll")(e)}function EOe(){return YQ("MutationObserver").constructor}function VD(t,e,i){try{if(!(e in t))return function(){};var n=t[e],r=i(n);return typeof r=="function"&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__rrweb_original__:{enumerable:!1,value:n}})),t[e]=r,function(){t[e]=n}}catch{return function(){}}}var xo={childNodes:bQe,parentNode:SQe,parentElement:_Qe,textContent:PQe,contains:CQe,getRootNode:TQe,host:xQe,styleSheets:EQe,shadowRoot:wQe,querySelector:AQe,querySelectorAll:OQe,mutationObserver:EOe,patch:VD};function Mf(t,e,i){i===void 0&&(i=document);var n={capture:!0,passive:!0};return i.addEventListener(t,e,n),function(){return i.removeEventListener(t,e,n)}}var pL=`Please stop import mirror directly. Instead of that,\r
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
or you can use record.mirror to access the mirror instance during recording.`,Kae={map:{},getId:function(){return console.error(pL),-1},getNode:function(){return console.error(pL),null},removeNodeFromMap:function(){console.error(pL)},has:function(){return console.error(pL),!1},reset:function(){console.error(pL)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(Kae=new Proxy(Kae,{get:function(e,i,n){return i==="map"&&console.error(pL),Reflect.get(e,i,n)}}));function a3(t,e,i){i===void 0&&(i={});var n=null,r=0;return function(){for(var o=arguments.length,a=new Array(o),s=0;s<o;s++)a[s]=arguments[s];var l=Date.now();!r&&i.leading===!1&&(r=l);var u=e-(l-r),c=this;u<=0||u>e?(n&&(clearTimeout(n),n=null),r=l,t.apply(c,a)):!n&&i.trailing!==!1&&(n=setTimeout(function(){r=i.leading===!1?0:Date.now(),n=null,t.apply(c,a)},u))}}function Q$(t,e,i,n,r){r===void 0&&(r=window);var o=r.Object.getOwnPropertyDescriptor(t,e);return r.Object.defineProperty(t,e,n?i:{set:function(s){var l=this;setTimeout(function(){i.set.call(l,s)},0),o&&o.set&&o.set.call(this,s)}}),function(){return Q$(t,e,o||{},!0)}}var N5=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(N5=function(){return new Date().getTime()});function wOe(t){var e,i,n,r,o=t.document;return{left:o.scrollingElement?o.scrollingElement.scrollLeft:t.pageXOffset!==void 0?t.pageXOffset:o.documentElement.scrollLeft||(o==null?void 0:o.body)&&((e=xo.parentElement(o.body))==null?void 0:e.scrollLeft)||((i=o==null?void 0:o.body)==null?void 0:i.scrollLeft)||0,top:o.scrollingElement?o.scrollingElement.scrollTop:t.pageYOffset!==void 0?t.pageYOffset:(o==null?void 0:o.documentElement.scrollTop)||(o==null?void 0:o.body)&&((n=xo.parentElement(o.body))==null?void 0:n.scrollTop)||((r=o==null?void 0:o.body)==null?void 0:r.scrollTop)||0}}function AOe(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function OOe(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function DOe(t){if(!t)return null;var e=t.nodeType===t.ELEMENT_NODE?t:xo.parentElement(t);return e}function Lf(t,e,i,n){if(!t)return!1;var r=DOe(t);if(!r)return!1;try{if(typeof e=="string"){if(r.classList.contains(e)||n&&r.closest("."+e)!==null)return!0}else if(w5(r,e,n))return!0}catch{}return!!(i&&(r.matches(i)||n&&r.closest(i)!==null))}function DQe(t,e){return e.getId(t)!==-1}function p8(t,e,i){return t.tagName==="TITLE"&&i.headTitleMutations?!0:e.getId(t)===Zj}function ROe(t,e){if(mj(t))return!1;var i=e.getId(t);if(!e.has(i))return!0;var n=xo.parentNode(t);return n&&n.nodeType===t.DOCUMENT_NODE?!1:n?ROe(n,e):!0}function bK(t){return!!t.changedTouches}function RQe(t){t===void 0&&(t=window),"NodeList"in t&&!t.NodeList.prototype.forEach&&(t.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in t&&!t.DOMTokenList.prototype.forEach&&(t.DOMTokenList.prototype.forEach=Array.prototype.forEach)}function MOe(t,e){return!!(t.nodeName==="IFRAME"&&e.getMeta(t))}function LOe(t,e){return!!(t.nodeName==="LINK"&&t.nodeType===t.ELEMENT_NODE&&t.getAttribute&&t.getAttribute("rel")==="stylesheet"&&e.getMeta(t))}function SK(t){return t?Ni(t,yQe)&&"shadowRoot"in t?!!t.shadowRoot:!!xo.shadowRoot(t):!1}var MQe=(function(){function t(){Jr(this,"id",1),Jr(this,"styleIDMap",new WeakMap),Jr(this,"idStyleMap",new Map)}var e=t.prototype;return e.getId=function(n){var r;return(r=this.styleIDMap.get(n))!=null?r:-1},e.has=function(n){return this.styleIDMap.has(n)},e.add=function(n,r){if(this.has(n))return this.getId(n);var o;return r===void 0?o=this.id++:o=r,this.styleIDMap.set(n,o),this.idStyleMap.set(o,n),o},e.getStyle=function(n){return this.idStyleMap.get(n)||null},e.reset=function(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1},e.generateId=function(){return this.id++},e.remove=function(n){var r=this.styleIDMap.get(n);return r!==void 0?(this.styleIDMap.delete(n),this.idStyleMap.delete(r),!0):!1},t})();function kOe(t){var e,i=null;return"getRootNode"in t&&((e=xo.getRootNode(t))==null?void 0:e.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&xo.host(xo.getRootNode(t))&&(i=xo.host(xo.getRootNode(t))),i}function LQe(t){for(var e=t,i;i=kOe(e);)e=i;return e}function kQe(t){var e=t.ownerDocument;if(!e)return!1;var i=LQe(t);return xo.contains(e,i)}function IOe(t){var e=t.ownerDocument;return e?xo.contains(e,t)||kQe(t):!1}var Ro=(function(t){return t[t.DomContentLoaded=0]="DomContentLoaded",t[t.Load=1]="Load",t[t.FullSnapshot=2]="FullSnapshot",t[t.IncrementalSnapshot=3]="IncrementalSnapshot",t[t.Meta=4]="Meta",t[t.Custom=5]="Custom",t[t.Plugin=6]="Plugin",t})(Ro||{}),wn=(function(t){return t[t.Mutation=0]="Mutation",t[t.MouseMove=1]="MouseMove",t[t.MouseInteraction=2]="MouseInteraction",t[t.Scroll=3]="Scroll",t[t.ViewportResize=4]="ViewportResize",t[t.Input=5]="Input",t[t.TouchMove=6]="TouchMove",t[t.MediaInteraction=7]="MediaInteraction",t[t.StyleSheetRule=8]="StyleSheetRule",t[t.CanvasMutation=9]="CanvasMutation",t[t.Font=10]="Font",t[t.Log=11]="Log",t[t.Drag=12]="Drag",t[t.StyleDeclaration=13]="StyleDeclaration",t[t.Selection=14]="Selection",t[t.AdoptedStyleSheet=15]="AdoptedStyleSheet",t[t.CustomElement=16]="CustomElement",t})(wn||{}),Sh=(function(t){return t[t.MouseUp=0]="MouseUp",t[t.MouseDown=1]="MouseDown",t[t.Click=2]="Click",t[t.ContextMenu=3]="ContextMenu",t[t.DblClick=4]="DblClick",t[t.Focus=5]="Focus",t[t.Blur=6]="Blur",t[t.TouchStart=7]="TouchStart",t[t.TouchMove_Departed=8]="TouchMove_Departed",t[t.TouchEnd=9]="TouchEnd",t[t.TouchCancel=10]="TouchCancel",t})(Sh||{}),Xb=(function(t){return t[t.Mouse=0]="Mouse",t[t.Pen=1]="Pen",t[t.Touch=2]="Touch",t})(Xb||{}),wk=(function(t){return t[t["2D"]=0]="2D",t[t.WebGL=1]="WebGL",t[t.WebGL2=2]="WebGL2",t})(wk||{}),gL=(function(t){return t[t.Play=0]="Play",t[t.Pause=1]="Pause",t[t.Seeked=2]="Seeked",t[t.VolumeChange=3]="VolumeChange",t[t.RateChange=4]="RateChange",t})(gL||{}),NOe=(function(t){return t[t.Document=0]="Document",t[t.DocumentType=1]="DocumentType",t[t.Element=2]="Element",t[t.Text=3]="Text",t[t.CDATA=4]="CDATA",t[t.Comment=5]="Comment",t})(NOe||{});function Zae(t){return"__ln"in t}var IQe=(function(){function t(){Jr(this,"length",0),Jr(this,"head",null),Jr(this,"tail",null)}var e=t.prototype;return e.get=function(n){if(n>=this.length)throw new Error("Position outside of list range");for(var r=this.head,o=0;o<n;o++)r=(r==null?void 0:r.next)||null;return r},e.addNode=function(n){var r={value:n,previous:null,next:null};if(n.__ln=r,n.previousSibling&&Zae(n.previousSibling)){var o=n.previousSibling.__ln.next;r.next=o,r.previous=n.previousSibling.__ln,n.previousSibling.__ln.next=r,o&&(o.previous=r)}else if(n.nextSibling&&Zae(n.nextSibling)&&n.nextSibling.__ln.previous){var a=n.nextSibling.__ln.previous;r.previous=a,r.next=n.nextSibling.__ln,n.nextSibling.__ln.previous=r,a&&(a.next=r)}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++},e.removeNode=function(n){var r=n.__ln;this.head&&(r.previous?(r.previous.next=r.next,r.next?r.next.previous=r.previous:this.tail=r.previous):(this.head=r.next,this.head?this.head.previous=null:this.tail=null),n.__ln&&delete n.__ln,this.length--)},t})(),Jae=function(t,e){return t+"@"+e},NQe=(function(){function t(){var i=this;Jr(this,"frozen",!1),Jr(this,"locked",!1),Jr(this,"texts",[]),Jr(this,"attributes",[]),Jr(this,"attributeMap",new WeakMap),Jr(this,"removes",[]),Jr(this,"mapRemoves",[]),Jr(this,"movedMap",{}),Jr(this,"addedSet",new Set),Jr(this,"movedSet",new Set),Jr(this,"droppedSet",new Set),Jr(this,"removesSubTreeCache",new Set),Jr(this,"mutationCb"),Jr(this,"blockClass"),Jr(this,"blockSelector"),Jr(this,"maskTextClass"),Jr(this,"maskTextSelector"),Jr(this,"inlineStylesheet"),Jr(this,"maskInputOptions"),Jr(this,"maskTextFn"),Jr(this,"maskInputFn"),Jr(this,"keepIframeSrcFn"),Jr(this,"recordCanvas"),Jr(this,"inlineImages"),Jr(this,"slimDOMOptions"),Jr(this,"dataURLOptions"),Jr(this,"doc"),Jr(this,"mirror"),Jr(this,"iframeManager"),Jr(this,"stylesheetManager"),Jr(this,"shadowDomManager"),Jr(this,"canvasManager"),Jr(this,"processedNodeManager"),Jr(this,"unattachedDoc"),Jr(this,"processMutations",function(n){n.forEach(i.processMutation),i.emit()}),Jr(this,"emit",function(){if(!(i.frozen||i.locked)){for(var n=[],r=new Set,o=new IQe,a=function(M){for(var D=M,F=Zj;F===Zj;)D=D&&D.nextSibling,F=D&&i.mirror.getId(D);return F},s=function(M){var D=xo.parentNode(M);if(!(!D||!IOe(M))){var F=!1;if(M.nodeType===Node.TEXT_NODE){var I=D.tagName;if(I==="TEXTAREA")return;I==="STYLE"&&i.addedSet.has(D)&&(F=!0)}var V=mj(D)?i.mirror.getId(kOe(M)):i.mirror.getId(D),z=a(M);if(V===-1||z===-1)return o.addNode(M);var G=SL(M,{doc:i.doc,mirror:i.mirror,blockClass:i.blockClass,blockSelector:i.blockSelector,maskTextClass:i.maskTextClass,maskTextSelector:i.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:i.inlineStylesheet,maskInputOptions:i.maskInputOptions,maskTextFn:i.maskTextFn,maskInputFn:i.maskInputFn,slimDOMOptions:i.slimDOMOptions,dataURLOptions:i.dataURLOptions,recordCanvas:i.recordCanvas,inlineImages:i.inlineImages,onSerialize:function(H){MOe(H,i.mirror)&&i.iframeManager.addIframe(H),LOe(H,i.mirror)&&i.stylesheetManager.trackLinkElement(H),SK(M)&&i.shadowDomManager.addShadowRoot(xo.shadowRoot(M),i.doc)},onIframeLoad:function(H,U){i.iframeManager.attachIframe(H,U),i.shadowDomManager.observeAttachShadow(H)},onStylesheetLoad:function(H,U){i.stylesheetManager.attachLinkElement(H,U)},cssCaptured:F});G&&(n.push({parentId:V,nextId:z,node:G}),r.add(G.id))}};i.mapRemoves.length;){var l=i.mapRemoves.shift();if(l.nodeName==="IFRAME")try{i.iframeManager.removeIframe(l)}catch{}else i.stylesheetManager.cleanupStylesheetsForRemovedNode(l);i.mirror.removeNodeFromMap(l)}for(var u=Ur(i.movedSet),c;!(c=u()).done;){var d=c.value;Qae(i.removesSubTreeCache,d,i.mirror)&&!i.movedSet.has(xo.parentNode(d))||s(d)}for(var f=Ur(i.addedSet),h;!(h=f()).done;){var p=h.value;!ese(i.droppedSet,p)&&!Qae(i.removesSubTreeCache,p,i.mirror)||ese(i.movedSet,p)?s(p):i.droppedSet.add(p)}for(var g=null;o.length;){var v=null;if(g){var y=i.mirror.getId(xo.parentNode(g.value)),m=a(g.value);y!==-1&&m!==-1&&(v=g)}if(!v)for(var b=o.tail;b;){var S=b;if(b=b.previous,S){var _=i.mirror.getId(xo.parentNode(S.value)),C=a(S.value);if(C===-1)continue;if(_!==-1){v=S;break}else{var P=S.value,x=xo.parentNode(P);if(x&&x.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var E=xo.host(x),A=i.mirror.getId(E);if(A!==-1){v=S;break}}}}}if(!v){for(;o.head;)o.removeNode(o.head.value);break}g=v.previous,o.removeNode(v.value),s(v.value)}var R={texts:i.texts.map(function(M){var D=M.node,F=xo.parentNode(D);return F&&F.tagName==="TEXTAREA"&&i.genTextAreaValueMutation(F),{id:i.mirror.getId(D),value:M.value}}).filter(function(M){return!r.has(M.id)}).filter(function(M){return i.mirror.has(M.id)}),attributes:i.attributes.map(function(M){var D=M.attributes;if(typeof D.style=="string"){var F=JSON.stringify(M.styleDiff),I=JSON.stringify(M._unchangedStyles);F.length<D.style.length&&(F+I).split("var(").length===D.style.split("var(").length&&(D.style=M.styleDiff)}return{id:i.mirror.getId(M.node),attributes:D}}).filter(function(M){return!r.has(M.id)}).filter(function(M){return i.mirror.has(M.id)}),removes:i.removes,adds:n};!R.texts.length&&!R.attributes.length&&!R.removes.length&&!R.adds.length||(i.texts=[],i.attributes=[],i.attributeMap=new WeakMap,i.removes=[],i.addedSet=new Set,i.movedSet=new Set,i.droppedSet=new Set,i.removesSubTreeCache=new Set,i.movedMap={},i.mutationCb(R))}}),Jr(this,"genTextAreaValueMutation",function(n){var r=i.attributeMap.get(n);r||(r={node:n,attributes:{},styleDiff:{},_unchangedStyles:{}},i.attributes.push(r),i.attributeMap.set(n,r));var o=Array.from(xo.childNodes(n),function(a){return xo.textContent(a)||""}).join("");r.attributes.value=T5({element:n,maskInputOptions:i.maskInputOptions,tagName:n.tagName,type:x5(n),value:o,maskInputFn:i.maskInputFn})}),Jr(this,"processMutation",function(n){if(!p8(n.target,i.mirror,i.slimDOMOptions))switch(n.type){case"characterData":{var r=xo.textContent(n.target);!Lf(n.target,i.blockClass,i.blockSelector,!1)&&r!==n.oldValue&&i.texts.push({value:fAe(n.target,i.maskTextClass,i.maskTextSelector,!0)&&r?i.maskTextFn?i.maskTextFn(r,DOe(n.target)):r.replace(/[\S]/g,"*"):r,node:n.target});break}case"attributes":{var o=n.target,a=n.attributeName,s=n.target.getAttribute(a);if(a==="value"){var l=x5(o);s=T5({element:o,maskInputOptions:i.maskInputOptions,tagName:o.tagName,type:l,value:s,maskInputFn:i.maskInputFn})}if(Lf(n.target,i.blockClass,i.blockSelector,!1)||s===n.oldValue)return;var u=i.attributeMap.get(n.target);if(o.tagName==="IFRAME"&&a==="src"&&!i.keepIframeSrcFn(s))if(!o.contentDocument)a="rr_src";else return;if(u||(u={node:n.target,attributes:{},styleDiff:{},_unchangedStyles:{}},i.attributes.push(u),i.attributeMap.set(n.target,u)),a==="type"&&o.tagName==="INPUT"&&(n.oldValue||"").toLowerCase()==="password"&&o.setAttribute("data-rr-is-password","true"),!dAe(o.tagName,a))if(u.attributes[a]=cAe(i.doc,TD(o.tagName),TD(a),s),a==="style"){if(!i.unattachedDoc)try{i.unattachedDoc=document.implementation.createHTMLDocument()}catch{i.unattachedDoc=i.doc}var c=i.unattachedDoc.createElement("span");n.oldValue&&c.setAttribute("style",n.oldValue);for(var d=Ur(Array.from(o.style)),f;!(f=d()).done;){var h=f.value,p=o.style.getPropertyValue(h),g=o.style.getPropertyPriority(h);p!==c.style.getPropertyValue(h)||g!==c.style.getPropertyPriority(h)?g===""?u.styleDiff[h]=p:u.styleDiff[h]=[p,g]:u._unchangedStyles[h]=[p,g]}for(var v=Ur(Array.from(c.style)),y;!(y=v()).done;){var m=y.value;o.style.getPropertyValue(m)===""&&(u.styleDiff[m]=!1)}}else a==="open"&&o.tagName==="DIALOG"&&(o.matches("dialog:modal")?u.attributes.rr_open_mode="modal":u.attributes.rr_open_mode="non-modal");break}case"childList":{if(Lf(n.target,i.blockClass,i.blockSelector,!0))return;if(n.target.tagName==="TEXTAREA"){i.genTextAreaValueMutation(n.target);return}n.addedNodes.forEach(function(b){return i.genAdds(b,n.target)}),n.removedNodes.forEach(function(b){var S=i.mirror.getId(b),_=mj(n.target)?i.mirror.getId(xo.host(n.target)):i.mirror.getId(n.target);Lf(n.target,i.blockClass,i.blockSelector,!1)||p8(b,i.mirror,i.slimDOMOptions)||!DQe(b,i.mirror)||(i.addedSet.has(b)?(_K(i.addedSet,b),i.droppedSet.add(b)):i.addedSet.has(n.target)&&S===-1||ROe(n.target,i.mirror)||(i.movedSet.has(b)&&i.movedMap[Jae(S,_)]?_K(i.movedSet,b):(i.removes.push({parentId:_,id:S,isShadow:mj(n.target)&&bj(n.target)?!0:void 0}),FQe(b,i.removesSubTreeCache))),i.mapRemoves.push(b))});break}}}),Jr(this,"genAdds",function(n,r){if(!i.processedNodeManager.inOtherBuffer(n,i)&&!(i.addedSet.has(n)||i.movedSet.has(n))){if(i.mirror.hasNode(n)){if(p8(n,i.mirror,i.slimDOMOptions))return;i.movedSet.add(n);var o=null;r&&i.mirror.hasNode(r)&&(o=i.mirror.getId(r)),o&&o!==-1&&(i.movedMap[Jae(i.mirror.getId(n),o)]=!0)}else i.addedSet.add(n),i.droppedSet.delete(n);Lf(n,i.blockClass,i.blockSelector,!1)||(xo.childNodes(n).forEach(function(a){return i.genAdds(a)}),SK(n)&&xo.childNodes(xo.shadowRoot(n)).forEach(function(a){i.processedNodeManager.add(a,i),i.genAdds(a,n)}))}})}var e=t.prototype;return e.init=function(n){var r=this;["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(function(o){r[o]=n[o]})},e.freeze=function(){this.frozen=!0,this.canvasManager.freeze()},e.unfreeze=function(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()},e.isFrozen=function(){return this.frozen},e.lock=function(){this.locked=!0,this.canvasManager.lock()},e.unlock=function(){this.locked=!1,this.canvasManager.unlock(),this.emit()},e.reset=function(){this.shadowDomManager.reset(),this.canvasManager.reset()},e.getDoc=function(){return this.doc},t})();function _K(t,e){t.delete(e),xo.childNodes(e).forEach(function(i){return _K(t,i)})}function FQe(t,e){for(var i=[t];i.length;){var n=i.pop();e.has(n)||(e.add(n),xo.childNodes(n).forEach(function(r){return i.push(r)}))}}function Qae(t,e,i){return t.size===0?!1:BQe(t,e)}function BQe(t,e,i){var n=xo.parentNode(e);return n?t.has(n):!1}function ese(t,e){return t.size===0?!1:FOe(t,e)}function FOe(t,e){var i=xo.parentNode(e);return i?t.has(i)?!0:FOe(t,i):!1}var Sj;function jQe(t){Sj=t}function VQe(){Sj=void 0}var jo=function(t){if(!Sj)return t;var e=function(){for(var i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];try{return t.apply(void 0,[].concat(n))}catch(o){if(Sj&&Sj(o)===!0)return;throw o}};return e},qy=[];function SV(t){try{if("composedPath"in t){var e=t.composedPath();if(e.length)return e[0]}else if("path"in t&&t.path.length)return t.path[0]}catch{}return t&&t.target}function BOe(t,e){var i=new NQe;qy.push(i),i.init(t);var n=new(EOe())(jo(i.processMutations.bind(i)));return n.observe(e,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),n}function HQe(t){for(var e=qy.length-1;e>=0;e--){var i=qy[e];i.getDoc()===t&&qy.splice(e,1)}}function UQe(t){var e=t.mousemoveCb,i=t.sampling,n=t.doc,r=t.mirror;if(i.mousemove===!1)return function(){};var o=typeof i.mousemove=="number"?i.mousemove:50,a=typeof i.mousemoveCallback=="number"?i.mousemoveCallback:500,s=[],l,u=a3(jo(function(f){var h=Date.now()-l;e(s.map(function(p){return p.timeOffset-=h,p}),f),s=[],l=null}),a),c=jo(a3(jo(function(f){var h=SV(f),p=bK(f)?f.changedTouches[0]:f,g=p.clientX,v=p.clientY;l||(l=N5()),s.push({x:g,y:v,id:r.getId(h),timeOffset:N5()-l}),u(typeof DragEvent<"u"&&Ni(f,DragEvent)?wn.Drag:Ni(f,MouseEvent)?wn.MouseMove:wn.TouchMove)}),o,{trailing:!1})),d=[Mf("mousemove",c,n),Mf("touchmove",c,n),Mf("drag",c,n)];return jo(function(){d.forEach(function(f){return f()})})}function zQe(t){var e=t.mouseInteractionCb,i=t.doc,n=t.mirror,r=t.blockClass,o=t.blockSelector,a=t.sampling;if(a.mouseInteraction===!1)return function(){};var s=a.mouseInteraction===!0||a.mouseInteraction===void 0?{}:a.mouseInteraction,l=[],u=null,c=function(d){return function(f){var h=SV(f);if(!Lf(h,r,o,!0)){var p=null,g=d;if("pointerType"in f){switch(f.pointerType){case"mouse":p=Xb.Mouse;break;case"touch":p=Xb.Touch;break;case"pen":p=Xb.Pen;break}p===Xb.Touch?Sh[d]===Sh.MouseDown?g="TouchStart":Sh[d]===Sh.MouseUp&&(g="TouchEnd"):Xb.Pen}else bK(f)&&(p=Xb.Touch);p!==null?(u=p,(g.startsWith("Touch")&&p===Xb.Touch||g.startsWith("Mouse")&&p===Xb.Mouse)&&(p=null)):Sh[d]===Sh.Click&&(p=u,u=null);var v=bK(f)?f.changedTouches[0]:f;if(v){var y=n.getId(h),m=v.clientX,b=v.clientY;jo(e)(Zn({type:Sh[g],id:y,x:m,y:b},p!==null&&{pointerType:p}))}}}};return Object.keys(Sh).filter(function(d){return Number.isNaN(Number(d))&&!d.endsWith("_Departed")&&s[d]!==!1}).forEach(function(d){var f=TD(d),h=c(d);if(window.PointerEvent)switch(Sh[d]){case Sh.MouseDown:case Sh.MouseUp:f=f.replace("mouse","pointer");break;case Sh.TouchStart:case Sh.TouchEnd:return}l.push(Mf(f,h,i))}),jo(function(){l.forEach(function(d){return d()})})}function jOe(t){var e=t.scrollCb,i=t.doc,n=t.mirror,r=t.blockClass,o=t.blockSelector,a=t.sampling,s=jo(a3(jo(function(l){var u=SV(l);if(!(!u||Lf(u,r,o,!0))){var c=n.getId(u);if(u===i&&i.defaultView){var d=wOe(i.defaultView);e({id:c,x:d.left,y:d.top})}else e({id:c,x:u.scrollLeft,y:u.scrollTop})}}),a.scroll||100));return Mf("scroll",s,i)}function $Qe(t,e){var i=t.viewportResizeCb,n=e.win,r=-1,o=-1,a=jo(a3(jo(function(){var s=AOe(),l=OOe();(r!==s||o!==l)&&(i({width:Number(l),height:Number(s)}),r=s,o=l)}),200));return Mf("resize",a,n)}var WQe=["INPUT","TEXTAREA","SELECT"],tse=new WeakMap;function GQe(t){var e=t.inputCb,i=t.doc,n=t.mirror,r=t.blockClass,o=t.blockSelector,a=t.ignoreClass,s=t.ignoreSelector,l=t.maskInputOptions,u=t.maskInputFn,c=t.sampling,d=t.userTriggeredOnInput;function f(S){var _=SV(S),C=S.isTrusted,P=_&&_.tagName;if(_&&P==="OPTION"&&(_=xo.parentElement(_)),!(!_||!P||WQe.indexOf(P)<0||Lf(_,r,o,!0))&&!(_.classList.contains(a)||s&&_.matches(s))){var x=_.value,E=!1,A=x5(_)||"";A==="radio"||A==="checkbox"?E=_.checked:(l[P.toLowerCase()]||l[A])&&(x=T5({element:_,maskInputOptions:l,tagName:P,type:A,value:x,maskInputFn:u})),h(_,d?{text:x,isChecked:E,userTriggered:C}:{text:x,isChecked:E});var R=_.name;A==="radio"&&R&&E&&i.querySelectorAll('input[type="radio"][name="'+R+'"]').forEach(function(M){if(M!==_){var D=M.value;h(M,d?{text:D,isChecked:!E,userTriggered:!1}:{text:D,isChecked:!E})}})}}function h(S,_){var C=tse.get(S);if(!C||C.text!==_.text||C.isChecked!==_.isChecked){tse.set(S,_);var P=n.getId(S);jo(e)(Zn({},_,{id:P}))}}var p=c.input==="last"?["change"]:["input","change"],g=p.map(function(S){return Mf(S,jo(f),i)}),v=i.defaultView;if(!v)return function(){g.forEach(function(S){return S()})};var y=v.Object.getOwnPropertyDescriptor(v.HTMLInputElement.prototype,"value"),m=[[v.HTMLInputElement.prototype,"value"],[v.HTMLInputElement.prototype,"checked"],[v.HTMLSelectElement.prototype,"value"],[v.HTMLTextAreaElement.prototype,"value"],[v.HTMLSelectElement.prototype,"selectedIndex"],[v.HTMLOptionElement.prototype,"selected"]];if(y&&y.set){var b;(b=g).push.apply(b,[].concat(m.map(function(S){return Q$(S[0],S[1],{set:function(){jo(f)({target:this,isTrusted:!1})}},!1,v)})))}return jo(function(){g.forEach(function(S){return S()})})}function F5(t){var e=[];function i(n,r){if(UH("CSSGroupingRule")&&Ni(n.parentRule,CSSGroupingRule)||UH("CSSMediaRule")&&Ni(n.parentRule,CSSMediaRule)||UH("CSSSupportsRule")&&Ni(n.parentRule,CSSSupportsRule)||UH("CSSConditionRule")&&Ni(n.parentRule,CSSConditionRule)){var o=Array.from(n.parentRule.cssRules),a=o.indexOf(n);r.unshift(a)}else if(n.parentStyleSheet){var s=Array.from(n.parentStyleSheet.cssRules),l=s.indexOf(n);r.unshift(l)}return r}return i(t,e)}function $_(t,e,i){var n,r;return t?(t.ownerNode?n=e.getId(t.ownerNode):r=i.getId(t),{styleId:r,id:n}):{}}function YQe(t,e){var i=t.styleSheetRuleCb,n=t.mirror,r=t.stylesheetManager,o=e.win;if(!o.CSSStyleSheet||!o.CSSStyleSheet.prototype)return function(){};var a=o.CSSStyleSheet.prototype.insertRule;o.CSSStyleSheet.prototype.insertRule=new Proxy(a,{apply:jo(function(f,h,p){var g=p[0],v=p[1],y=$_(h,n,r.styleMirror),m=y.id,b=y.styleId;return(m&&m!==-1||b&&b!==-1)&&i({id:m,styleId:b,adds:[{rule:g,index:v}]}),f.apply(h,p)})}),o.CSSStyleSheet.prototype.addRule=function(f,h,p){p===void 0&&(p=this.cssRules.length);var g=f+" { "+h+" }";return o.CSSStyleSheet.prototype.insertRule.apply(this,[g,p])};var s=o.CSSStyleSheet.prototype.deleteRule;o.CSSStyleSheet.prototype.deleteRule=new Proxy(s,{apply:jo(function(f,h,p){var g=p[0],v=$_(h,n,r.styleMirror),y=v.id,m=v.styleId;return(y&&y!==-1||m&&m!==-1)&&i({id:y,styleId:m,removes:[{index:g}]}),f.apply(h,p)})}),o.CSSStyleSheet.prototype.removeRule=function(f){return o.CSSStyleSheet.prototype.deleteRule.apply(this,[f])};var l;o.CSSStyleSheet.prototype.replace&&(l=o.CSSStyleSheet.prototype.replace,o.CSSStyleSheet.prototype.replace=new Proxy(l,{apply:jo(function(f,h,p){var g=p[0],v=$_(h,n,r.styleMirror),y=v.id,m=v.styleId;return(y&&y!==-1||m&&m!==-1)&&i({id:y,styleId:m,replace:g}),f.apply(h,p)})}));var u;o.CSSStyleSheet.prototype.replaceSync&&(u=o.CSSStyleSheet.prototype.replaceSync,o.CSSStyleSheet.prototype.replaceSync=new Proxy(u,{apply:jo(function(f,h,p){var g=p[0],v=$_(h,n,r.styleMirror),y=v.id,m=v.styleId;return(y&&y!==-1||m&&m!==-1)&&i({id:y,styleId:m,replaceSync:g}),f.apply(h,p)})}));var c={};zH("CSSGroupingRule")?c.CSSGroupingRule=o.CSSGroupingRule:(zH("CSSMediaRule")&&(c.CSSMediaRule=o.CSSMediaRule),zH("CSSConditionRule")&&(c.CSSConditionRule=o.CSSConditionRule),zH("CSSSupportsRule")&&(c.CSSSupportsRule=o.CSSSupportsRule));var d={};return Object.entries(c).forEach(function(f){var h=f[0],p=f[1];d[h]={insertRule:p.prototype.insertRule,deleteRule:p.prototype.deleteRule},p.prototype.insertRule=new Proxy(d[h].insertRule,{apply:jo(function(g,v,y){var m=y[0],b=y[1],S=$_(v.parentStyleSheet,n,r.styleMirror),_=S.id,C=S.styleId;return(_&&_!==-1||C&&C!==-1)&&i({id:_,styleId:C,adds:[{rule:m,index:[].concat(F5(v),[b||0])}]}),g.apply(v,y)})}),p.prototype.deleteRule=new Proxy(d[h].deleteRule,{apply:jo(function(g,v,y){var m=y[0],b=$_(v.parentStyleSheet,n,r.styleMirror),S=b.id,_=b.styleId;return(S&&S!==-1||_&&_!==-1)&&i({id:S,styleId:_,removes:[{index:[].concat(F5(v),[m])}]}),g.apply(v,y)})})}),jo(function(){o.CSSStyleSheet.prototype.insertRule=a,o.CSSStyleSheet.prototype.deleteRule=s,l&&(o.CSSStyleSheet.prototype.replace=l),u&&(o.CSSStyleSheet.prototype.replaceSync=u),Object.entries(c).forEach(function(f){var h=f[0],p=f[1];p.prototype.insertRule=d[h].insertRule,p.prototype.deleteRule=d[h].deleteRule})})}function VOe(t,e){var i=t.mirror,n=t.stylesheetManager,r,o,a,s=null;e.nodeName==="#document"?s=i.getId(e):s=i.getId(xo.host(e));var l=e.nodeName==="#document"?(r=e.defaultView)==null?void 0:r.Document:(a=(o=e.ownerDocument)==null?void 0:o.defaultView)==null?void 0:a.ShadowRoot,u=l!=null&&l.prototype?Object.getOwnPropertyDescriptor(l==null?void 0:l.prototype,"adoptedStyleSheets"):void 0;return s===null||s===-1||!l||!u?function(){}:(Object.defineProperty(e,"adoptedStyleSheets",{configurable:u.configurable,enumerable:u.enumerable,get:function(){var d;return(d=u.get)==null?void 0:d.call(this)},set:function(d){var f,h=(f=u.set)==null?void 0:f.call(this,d);if(s!==null&&s!==-1)try{n.adoptStyleSheets(d,s)}catch{}return h}}),jo(function(){Object.defineProperty(e,"adoptedStyleSheets",{configurable:u.configurable,enumerable:u.enumerable,get:u.get,set:u.set})}))}function qQe(t,e){var i=t.styleDeclarationCb,n=t.mirror,r=t.ignoreCSSAttributes,o=t.stylesheetManager,a=e.win,s=a.CSSStyleDeclaration.prototype.setProperty;a.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:jo(function(u,c,d){var f,h=d[0],p=d[1],g=d[2];if(r.has(h))return s.apply(c,[h,p,g]);var v=$_((f=c.parentRule)==null?void 0:f.parentStyleSheet,n,o.styleMirror),y=v.id,m=v.styleId;return(y&&y!==-1||m&&m!==-1)&&i({id:y,styleId:m,set:{property:h,value:p,priority:g},index:F5(c.parentRule)}),u.apply(c,d)})});var l=a.CSSStyleDeclaration.prototype.removeProperty;return a.CSSStyleDeclaration.prototype.removeProperty=new Proxy(l,{apply:jo(function(u,c,d){var f,h=d[0];if(r.has(h))return l.apply(c,[h]);var p=$_((f=c.parentRule)==null?void 0:f.parentStyleSheet,n,o.styleMirror),g=p.id,v=p.styleId;return(g&&g!==-1||v&&v!==-1)&&i({id:g,styleId:v,remove:{property:h},index:F5(c.parentRule)}),u.apply(c,d)})}),jo(function(){a.CSSStyleDeclaration.prototype.setProperty=s,a.CSSStyleDeclaration.prototype.removeProperty=l})}function XQe(t){var e=t.mediaInteractionCb,i=t.blockClass,n=t.blockSelector,r=t.mirror,o=t.sampling,a=t.doc,s=jo(function(u){return a3(jo(function(c){var d=SV(c);if(!(!d||Lf(d,i,n,!0))){var f=d.currentTime,h=d.volume,p=d.muted,g=d.playbackRate,v=d.loop;e({type:u,id:r.getId(d),currentTime:f,volume:h,muted:p,playbackRate:g,loop:v})}}),o.media||500)}),l=[Mf("play",s(gL.Play),a),Mf("pause",s(gL.Pause),a),Mf("seeked",s(gL.Seeked),a),Mf("volumechange",s(gL.VolumeChange),a),Mf("ratechange",s(gL.RateChange),a)];return jo(function(){l.forEach(function(u){return u()})})}function KQe(t){var e=t.fontCb,i=t.doc,n=i.defaultView;if(!n)return function(){};var r=[],o=new WeakMap,a=n.FontFace;n.FontFace=function(u,c,d){var f=new a(u,c,d);return o.set(f,{family:u,buffer:typeof c!="string",descriptors:d,fontSource:typeof c=="string"?c:JSON.stringify(Array.from(new Uint8Array(c)))}),f};var s=VD(i.fonts,"add",function(l){return function(u){return setTimeout(jo(function(){var c=o.get(u);c&&(e(c),o.delete(u))}),0),l.apply(this,[u])}});return r.push(function(){n.FontFace=a}),r.push(s),jo(function(){r.forEach(function(l){return l()})})}function ZQe(t){var e=t.doc,i=t.mirror,n=t.blockClass,r=t.blockSelector,o=t.selectionCb,a=!0,s=jo(function(){var l=e.getSelection();if(!(!l||a&&(l!=null&&l.isCollapsed))){a=l.isCollapsed||!1;for(var u=[],c=l.rangeCount||0,d=0;d<c;d++){var f=l.getRangeAt(d),h=f.startContainer,p=f.startOffset,g=f.endContainer,v=f.endOffset,y=Lf(h,n,r,!0)||Lf(g,n,r,!0);y||u.push({start:i.getId(h),startOffset:p,end:i.getId(g),endOffset:v})}o({ranges:u})}});return s(),Mf("selectionchange",s)}function JQe(t){var e=t.doc,i=t.customElementCb,n=e.defaultView;if(!n||!n.customElements)return function(){};var r=VD(n.customElements,"define",function(o){return function(a,s,l){try{i({define:{name:a}})}catch{console.warn("Custom element callback failed for "+a)}return o.apply(this,[a,s,l])}});return r}function QQe(t,e){var i=t.mutationCb,n=t.mousemoveCb,r=t.mouseInteractionCb,o=t.scrollCb,a=t.viewportResizeCb,s=t.inputCb,l=t.mediaInteractionCb,u=t.styleSheetRuleCb,c=t.styleDeclarationCb,d=t.canvasMutationCb,f=t.fontCb,h=t.selectionCb,p=t.customElementCb;t.mutationCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.mutation){var m;(m=e).mutation.apply(m,[].concat(v))}i.apply(void 0,[].concat(v))},t.mousemoveCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.mousemove){var m;(m=e).mousemove.apply(m,[].concat(v))}n.apply(void 0,[].concat(v))},t.mouseInteractionCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.mouseInteraction){var m;(m=e).mouseInteraction.apply(m,[].concat(v))}r.apply(void 0,[].concat(v))},t.scrollCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.scroll){var m;(m=e).scroll.apply(m,[].concat(v))}o.apply(void 0,[].concat(v))},t.viewportResizeCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.viewportResize){var m;(m=e).viewportResize.apply(m,[].concat(v))}a.apply(void 0,[].concat(v))},t.inputCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.input){var m;(m=e).input.apply(m,[].concat(v))}s.apply(void 0,[].concat(v))},t.mediaInteractionCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.mediaInteaction){var m;(m=e).mediaInteaction.apply(m,[].concat(v))}l.apply(void 0,[].concat(v))},t.styleSheetRuleCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.styleSheetRule){var m;(m=e).styleSheetRule.apply(m,[].concat(v))}u.apply(void 0,[].concat(v))},t.styleDeclarationCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.styleDeclaration){var m;(m=e).styleDeclaration.apply(m,[].concat(v))}c.apply(void 0,[].concat(v))},t.canvasMutationCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.canvasMutation){var m;(m=e).canvasMutation.apply(m,[].concat(v))}d.apply(void 0,[].concat(v))},t.fontCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.font){var m;(m=e).font.apply(m,[].concat(v))}f.apply(void 0,[].concat(v))},t.selectionCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.selection){var m;(m=e).selection.apply(m,[].concat(v))}h.apply(void 0,[].concat(v))},t.customElementCb=function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];if(e.customElement){var m;(m=e).customElement.apply(m,[].concat(v))}p.apply(void 0,[].concat(v))}}function eet(t,e){e===void 0&&(e={});var i=t.doc.defaultView;if(!i)return function(){};QQe(t,e);var n;t.recordDOM&&(n=BOe(t,t.doc));var r=UQe(t),o=zQe(t),a=jOe(t),s=$Qe(t,{win:i}),l=GQe(t),u=XQe(t),c=function(){},d=function(){},f=function(){},h=function(){};t.recordDOM&&(c=YQe(t,{win:i}),d=VOe(t,t.doc),f=qQe(t,{win:i}),t.collectFonts&&(h=KQe(t)));for(var p=ZQe(t),g=JQe(t),v=[],y=Ur(t.plugins),m;!(m=y()).done;){var b=m.value;v.push(b.observer(b.callback,i,b.options))}return jo(function(){qy.forEach(function(S){return S.reset()}),n==null||n.disconnect(),r(),o(),a(),s(),l(),u(),c(),d(),f(),h(),p(),g(),v.forEach(function(S){return S()})})}function UH(t){return typeof window[t]<"u"}function zH(t){return!!(typeof window[t]<"u"&&window[t].prototype&&"insertRule"in window[t].prototype&&"deleteRule"in window[t].prototype)}var rse=(function(){function t(i){Jr(this,"iframeIdToRemoteIdMap",new WeakMap),Jr(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=i}var e=t.prototype;return e.getId=function(n,r,o,a){var s=o||this.getIdToRemoteIdMap(n),l=a||this.getRemoteIdToIdMap(n),u=s.get(r);return u||(u=this.generateIdFn(),s.set(r,u),l.set(u,r)),u},e.getIds=function(n,r){var o=this,a=this.getIdToRemoteIdMap(n),s=this.getRemoteIdToIdMap(n);return r.map(function(l){return o.getId(n,l,a,s)})},e.getRemoteId=function(n,r,o){var a=o||this.getRemoteIdToIdMap(n);if(typeof r!="number")return r;var s=a.get(r);return s||-1},e.getRemoteIds=function(n,r){var o=this,a=this.getRemoteIdToIdMap(n);return r.map(function(s){return o.getRemoteId(n,s,a)})},e.reset=function(n){if(!n){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(n),this.iframeRemoteIdToIdMap.delete(n)},e.getIdToRemoteIdMap=function(n){var r=this.iframeIdToRemoteIdMap.get(n);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(n,r)),r},e.getRemoteIdToIdMap=function(n){var r=this.iframeRemoteIdToIdMap.get(n);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(n,r)),r},t})(),tet=(function(){function t(i){Jr(this,"iframes",new WeakMap),Jr(this,"crossOriginIframeMap",new WeakMap),Jr(this,"crossOriginIframeMirror",new rse(uAe)),Jr(this,"crossOriginIframeStyleMirror"),Jr(this,"crossOriginIframeRootIdMap",new WeakMap),Jr(this,"iframeContentDocumentMap",new WeakMap),Jr(this,"iframeObserverCleanupMap",new WeakMap),Jr(this,"mirror"),Jr(this,"mutationCb"),Jr(this,"wrappedEmit"),Jr(this,"loadListener"),Jr(this,"stylesheetManager"),Jr(this,"recordCrossOriginIframes"),this.mutationCb=i.mutationCb,this.wrappedEmit=i.wrappedEmit,this.stylesheetManager=i.stylesheetManager,this.recordCrossOriginIframes=i.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new rse(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=i.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}var e=t.prototype;return e.addIframe=function(n){this.iframes.set(n,!0),n.contentWindow&&this.crossOriginIframeMap.set(n.contentWindow,n)},e.getIframeContentDocument=function(n){return this.iframeContentDocumentMap.get(n)},e.setObserverCleanup=function(n,r){this.iframeObserverCleanupMap.set(n,r)},e.getObserverCleanup=function(n){return this.iframeObserverCleanupMap.get(n)},e.removeIframe=function(n){var r=this.iframeContentDocumentMap.get(n);r&&(this.stylesheetManager.cleanupStylesheetsForRemovedNode(r),this.mirror.removeNodeFromMap(r,!0)),this.iframes.delete(n),this.iframeContentDocumentMap.delete(n);var o=this.iframeObserverCleanupMap.get(n);if(o){try{o()}catch{}this.iframeObserverCleanupMap.delete(n)}},e.addLoadListener=function(n){this.loadListener=n},e.attachIframe=function(n,r){var o,a;this.mutationCb({adds:[{parentId:this.mirror.getId(n),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),n.contentDocument&&this.iframeContentDocumentMap.set(n,n.contentDocument),this.recordCrossOriginIframes&&((o=n.contentWindow)==null||o.addEventListener("message",this.handleMessage.bind(this))),(a=this.loadListener)==null||a.call(this,n),n.contentDocument&&n.contentDocument.adoptedStyleSheets&&n.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(n.contentDocument.adoptedStyleSheets,this.mirror.getId(n.contentDocument))},e.handleMessage=function(n){var r=n;if(!(r.data.type!=="rrweb"||r.origin!==r.data.origin)){var o=n.source;if(o){var a=this.crossOriginIframeMap.get(n.source);if(a){var s=this.transformCrossOriginEvent(a,r.data.event);s&&this.wrappedEmit(s,r.data.isCheckout)}}}},e.transformCrossOriginEvent=function(n,r){var o=this,a;switch(r.type){case Ro.FullSnapshot:{this.crossOriginIframeMirror.reset(n),this.crossOriginIframeStyleMirror.reset(n),this.replaceIdOnNode(r.data.node,n);var s=r.data.node.id;return this.crossOriginIframeRootIdMap.set(n,s),this.patchRootIdOnNode(r.data.node,s),{timestamp:r.timestamp,type:Ro.IncrementalSnapshot,data:{source:wn.Mutation,adds:[{parentId:this.mirror.getId(n),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case Ro.Meta:case Ro.Load:case Ro.DomContentLoaded:return!1;case Ro.Plugin:return r;case Ro.Custom:return this.replaceIds(r.data.payload,n,["id","parentId","previousId","nextId"]),r;case Ro.IncrementalSnapshot:switch(r.data.source){case wn.Mutation:return r.data.adds.forEach(function(l){o.replaceIds(l,n,["parentId","nextId","previousId"]),o.replaceIdOnNode(l.node,n);var u=o.crossOriginIframeRootIdMap.get(n);u&&o.patchRootIdOnNode(l.node,u)}),r.data.removes.forEach(function(l){o.replaceIds(l,n,["parentId","id"])}),r.data.attributes.forEach(function(l){o.replaceIds(l,n,["id"])}),r.data.texts.forEach(function(l){o.replaceIds(l,n,["id"])}),r;case wn.Drag:case wn.TouchMove:case wn.MouseMove:return r.data.positions.forEach(function(l){o.replaceIds(l,n,["id"])}),r;case wn.ViewportResize:return!1;case wn.MediaInteraction:case wn.MouseInteraction:case wn.Scroll:case wn.CanvasMutation:case wn.Input:return this.replaceIds(r.data,n,["id"]),r;case wn.StyleSheetRule:case wn.StyleDeclaration:return this.replaceIds(r.data,n,["id"]),this.replaceStyleIds(r.data,n,["styleId"]),r;case wn.Font:return r;case wn.Selection:return r.data.ranges.forEach(function(l){o.replaceIds(l,n,["start","end"])}),r;case wn.AdoptedStyleSheet:return this.replaceIds(r.data,n,["id"]),this.replaceStyleIds(r.data,n,["styleIds"]),(a=r.data.styles)==null||a.forEach(function(l){o.replaceStyleIds(l,n,["styleId"])}),r}}return!1},e.replace=function(n,r,o,a){for(var s=Ur(a),l;!(l=s()).done;){var u=l.value;!Array.isArray(r[u])&&typeof r[u]!="number"||(Array.isArray(r[u])?r[u]=n.getIds(o,r[u]):r[u]=n.getId(o,r[u]))}return r},e.replaceIds=function(n,r,o){return this.replace(this.crossOriginIframeMirror,n,r,o)},e.replaceStyleIds=function(n,r,o){return this.replace(this.crossOriginIframeStyleMirror,n,r,o)},e.replaceIdOnNode=function(n,r){var o=this;this.replaceIds(n,r,["id","rootId"]),"childNodes"in n&&n.childNodes.forEach(function(a){o.replaceIdOnNode(a,r)})},e.patchRootIdOnNode=function(n,r){var o=this;n.type!==NOe.Document&&!n.rootId&&(n.rootId=r),"childNodes"in n&&n.childNodes.forEach(function(a){o.patchRootIdOnNode(a,r)})},t})(),ret=(function(){function t(i){Jr(this,"shadowDoms",new WeakSet),Jr(this,"mutationCb"),Jr(this,"scrollCb"),Jr(this,"bypassOptions"),Jr(this,"mirror"),Jr(this,"restoreHandlers",[]),this.mutationCb=i.mutationCb,this.scrollCb=i.scrollCb,this.bypassOptions=i.bypassOptions,this.mirror=i.mirror,this.init()}var e=t.prototype;return e.init=function(){this.reset(),this.patchAttachShadow(Element,document)},e.addShadowRoot=function(n,r){var o=this;if(bj(n)&&!this.shadowDoms.has(n)){this.shadowDoms.add(n);var a=BOe(Zn({},this.bypassOptions,{doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),n);this.restoreHandlers.push(function(){return a.disconnect()}),this.restoreHandlers.push(jOe(Zn({},this.bypassOptions,{scrollCb:this.scrollCb,doc:n,mirror:this.mirror}))),setTimeout(function(){n.adoptedStyleSheets&&n.adoptedStyleSheets.length>0&&o.bypassOptions.stylesheetManager.adoptStyleSheets(n.adoptedStyleSheets,o.mirror.getId(xo.host(n))),o.restoreHandlers.push(VOe({mirror:o.mirror,stylesheetManager:o.bypassOptions.stylesheetManager},n))},0)}},e.observeAttachShadow=function(n){!n.contentWindow||!n.contentDocument||this.patchAttachShadow(n.contentWindow.Element,n.contentDocument)},e.patchAttachShadow=function(n,r){var o=this;this.restoreHandlers.push(VD(n.prototype,"attachShadow",function(a){return function(s){var l=a.call(this,s),u=xo.shadowRoot(this);return u&&IOe(this)&&o.addShadowRoot(u,r),l}}))},e.reset=function(){this.restoreHandlers.forEach(function(n){try{n()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet},t})(),_L="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",iet=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var $H=0;$H<_L.length;$H++)iet[_L.charCodeAt($H)]=$H;var net=function(e){var i=new Uint8Array(e),n,r=i.length,o="";for(n=0;n<r;n+=3)o+=_L[i[n]>>2],o+=_L[(i[n]&3)<<4|i[n+1]>>4],o+=_L[(i[n+1]&15)<<2|i[n+2]>>6],o+=_L[i[n+2]&63];return r%3===2?o=o.substring(0,o.length-1)+"=":r%3===1&&(o=o.substring(0,o.length-2)+"=="),o},ise=new Map;function oet(t,e){var i=ise.get(t);return i||(i=new Map,ise.set(t,i)),i.has(e)||i.set(e,[]),i.get(e)}var HOe=function(t,e,i){if(!(!t||!(zOe(t,e)||(typeof t>"u"?"undefined":Ui(t))==="object"))){var n=t.constructor.name,r=oet(i,n),o=r.indexOf(t);return o===-1&&(o=r.length,r.push(t)),o}};function kU(t,e,i){if(Ni(t,Array))return t.map(function(p){return kU(p,e,i)});if(t===null)return t;if(Ni(t,Float32Array)||Ni(t,Float64Array)||Ni(t,Int32Array)||Ni(t,Uint32Array)||Ni(t,Uint8Array)||Ni(t,Uint16Array)||Ni(t,Int16Array)||Ni(t,Int8Array)||Ni(t,Uint8ClampedArray)){var n=t.constructor.name;return{rr_type:n,args:[Object.values(t)]}}else if(Ni(t,ArrayBuffer)){var r=t.constructor.name,o=net(t);return{rr_type:r,base64:o}}else if(Ni(t,DataView)){var a=t.constructor.name;return{rr_type:a,args:[kU(t.buffer,e,i),t.byteOffset,t.byteLength]}}else if(Ni(t,HTMLImageElement)){var s=t.constructor.name,l=t.src;return{rr_type:s,src:l}}else if(Ni(t,HTMLCanvasElement)){var u="HTMLImageElement",c=t.toDataURL();return{rr_type:u,src:c}}else if(Ni(t,ImageData)){var d=t.constructor.name;return{rr_type:d,args:[kU(t.data,e,i),t.width,t.height]}}else if(zOe(t,e)||(typeof t>"u"?"undefined":Ui(t))==="object"){var f=t.constructor.name,h=HOe(t,e,i);return{rr_type:f,index:h}}return t}var UOe=function(t,e,i){return t.map(function(n){return kU(n,e,i)})},zOe=function(t,e){var i=["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"],n=i.filter(function(r){return typeof e[r]=="function"});return!!n.find(function(r){return Ni(t,e[r])})};function aet(t,e,i,n){for(var r=function(){var u=l.value;try{if(typeof e.CanvasRenderingContext2D.prototype[u]!="function")return"continue";var c=VD(e.CanvasRenderingContext2D.prototype,u,function(f){return function(){for(var h=this,p=arguments.length,g=new Array(p),v=0;v<p;v++)g[v]=arguments[v];return Lf(this.canvas,i,n,!0)||setTimeout(function(){var y=UOe(g,e,h);t(h.canvas,{type:wk["2D"],property:u,args:y})},0),f.apply(this,g)}});o.push(c)}catch{var d=Q$(e.CanvasRenderingContext2D.prototype,u,{set:function(p){t(this.canvas,{type:wk["2D"],property:u,args:[p],setter:!0})}});o.push(d)}},o=[],a=Object.getOwnPropertyNames(e.CanvasRenderingContext2D.prototype),s=Ur(a),l;!(l=s()).done;)r();return function(){o.forEach(function(u){return u()})}}function set(t){return t==="experimental-webgl"?"webgl":t}function nse(t,e,i,n){var r=[];try{var o=VD(t.HTMLCanvasElement.prototype,"getContext",function(a){return function(s){for(var l=arguments.length,u=new Array(l>1?l-1:0),c=1;c<l;c++)u[c-1]=arguments[c];if(!Lf(this,e,i,!0)){var d=set(s);if("__context"in this||(this.__context=d),n&&["webgl","webgl2"].includes(d))if(u[0]&&Ui(u[0])==="object"){var f=u[0];f.preserveDrawingBuffer||(f.preserveDrawingBuffer=!0)}else u.splice(0,1,{preserveDrawingBuffer:!0})}return a.apply(this,[].concat([s],u))}});r.push(o)}catch{console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return function(){r.forEach(function(a){return a()})}}function ose(t,e,i,n,r,o){for(var a=function(){var d=c.value;if(["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(d))return"continue";try{if(typeof t[d]!="function")return"continue";var f=VD(t,d,function(p){return function(){for(var g=arguments.length,v=new Array(g),y=0;y<g;y++)v[y]=arguments[y];var m=p.apply(this,v);if(HOe(m,o,this),"tagName"in this.canvas&&!Lf(this.canvas,n,r,!0)){var b=UOe(v,o,this),S={type:e,property:d,args:b};i(this.canvas,S)}return m}});s.push(f)}catch{var h=Q$(t,d,{set:function(v){i(this.canvas,{type:e,property:d,args:[v],setter:!0})}});s.push(h)}},s=[],l=Object.getOwnPropertyNames(t),u=Ur(l),c;!(c=u()).done;)a();return s}function uet(t,e,i,n){var r,o=[];if((r=o).push.apply(r,[].concat(ose(e.WebGLRenderingContext.prototype,wk.WebGL,t,i,n,e))),typeof e.WebGL2RenderingContext<"u"){var a;(a=o).push.apply(a,[].concat(ose(e.WebGL2RenderingContext.prototype,wk.WebGL2,t,i,n,e)))}return function(){o.forEach(function(s){return s()})}}var $Oe="KGZ1bmN0aW9uKCkgewogICJ1c2Ugc3RyaWN0IjsKICB2YXIgY2hhcnMgPSAiQUJDREVGR0hJSktMTU5PUFFSU1RVVldYWVphYmNkZWZnaGlqa2xtbm9wcXJzdHV2d3h5ejAxMjM0NTY3ODkrLyI7CiAgdmFyIGxvb2t1cCA9IHR5cGVvZiBVaW50OEFycmF5ID09PSAidW5kZWZpbmVkIiA/IFtdIDogbmV3IFVpbnQ4QXJyYXkoMjU2KTsKICBmb3IgKHZhciBpID0gMDsgaSA8IGNoYXJzLmxlbmd0aDsgaSsrKSB7CiAgICBsb29rdXBbY2hhcnMuY2hhckNvZGVBdChpKV0gPSBpOwogIH0KICB2YXIgZW5jb2RlID0gZnVuY3Rpb24oYXJyYXlidWZmZXIpIHsKICAgIHZhciBieXRlcyA9IG5ldyBVaW50OEFycmF5KGFycmF5YnVmZmVyKSwgaTIsIGxlbiA9IGJ5dGVzLmxlbmd0aCwgYmFzZTY0ID0gIiI7CiAgICBmb3IgKGkyID0gMDsgaTIgPCBsZW47IGkyICs9IDMpIHsKICAgICAgYmFzZTY0ICs9IGNoYXJzW2J5dGVzW2kyXSA+PiAyXTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMl0gJiAzKSA8PCA0IHwgYnl0ZXNbaTIgKyAxXSA+PiA0XTsKICAgICAgYmFzZTY0ICs9IGNoYXJzWyhieXRlc1tpMiArIDFdICYgMTUpIDw8IDIgfCBieXRlc1tpMiArIDJdID4+IDZdOwogICAgICBiYXNlNjQgKz0gY2hhcnNbYnl0ZXNbaTIgKyAyXSAmIDYzXTsKICAgIH0KICAgIGlmIChsZW4gJSAzID09PSAyKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDEpICsgIj0iOwogICAgfSBlbHNlIGlmIChsZW4gJSAzID09PSAxKSB7CiAgICAgIGJhc2U2NCA9IGJhc2U2NC5zdWJzdHJpbmcoMCwgYmFzZTY0Lmxlbmd0aCAtIDIpICsgIj09IjsKICAgIH0KICAgIHJldHVybiBiYXNlNjQ7CiAgfTsKICBjb25zdCBsYXN0QmxvYk1hcCA9IC8qIEBfX1BVUkVfXyAqLyBuZXcgTWFwKCk7CiAgY29uc3QgdHJhbnNwYXJlbnRCbG9iTWFwID0gLyogQF9fUFVSRV9fICovIG5ldyBNYXAoKTsKICBhc3luYyBmdW5jdGlvbiBnZXRUcmFuc3BhcmVudEJsb2JGb3Iod2lkdGgsIGhlaWdodCwgZGF0YVVSTE9wdGlvbnMpIHsKICAgIGNvbnN0IGlkID0gYCR7d2lkdGh9LSR7aGVpZ2h0fWA7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBpZiAodHJhbnNwYXJlbnRCbG9iTWFwLmhhcyhpZCkpIHJldHVybiB0cmFuc3BhcmVudEJsb2JNYXAuZ2V0KGlkKTsKICAgICAgY29uc3Qgb2Zmc2NyZWVuID0gbmV3IE9mZnNjcmVlbkNhbnZhcyh3aWR0aCwgaGVpZ2h0KTsKICAgICAgb2Zmc2NyZWVuLmdldENvbnRleHQoIjJkIik7CiAgICAgIGNvbnN0IGJsb2IgPSBhd2FpdCBvZmZzY3JlZW4uY29udmVydFRvQmxvYihkYXRhVVJMT3B0aW9ucyk7CiAgICAgIGNvbnN0IGFycmF5QnVmZmVyID0gYXdhaXQgYmxvYi5hcnJheUJ1ZmZlcigpOwogICAgICBjb25zdCBiYXNlNjQgPSBlbmNvZGUoYXJyYXlCdWZmZXIpOwogICAgICB0cmFuc3BhcmVudEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICByZXR1cm4gYmFzZTY0OwogICAgfSBlbHNlIHsKICAgICAgcmV0dXJuICIiOwogICAgfQogIH0KICBjb25zdCB3b3JrZXIgPSBzZWxmOwogIHdvcmtlci5vbm1lc3NhZ2UgPSBhc3luYyBmdW5jdGlvbihlKSB7CiAgICBpZiAoIk9mZnNjcmVlbkNhbnZhcyIgaW4gZ2xvYmFsVGhpcykgewogICAgICBjb25zdCB7IGlkLCBiaXRtYXAsIHdpZHRoLCBoZWlnaHQsIGRhdGFVUkxPcHRpb25zIH0gPSBlLmRhdGE7CiAgICAgIGNvbnN0IHRyYW5zcGFyZW50QmFzZTY0ID0gZ2V0VHJhbnNwYXJlbnRCbG9iRm9yKAogICAgICAgIHdpZHRoLAogICAgICAgIGhlaWdodCwKICAgICAgICBkYXRhVVJMT3B0aW9ucwogICAgICApOwogICAgICBjb25zdCBvZmZzY3JlZW4gPSBuZXcgT2Zmc2NyZWVuQ2FudmFzKHdpZHRoLCBoZWlnaHQpOwogICAgICBjb25zdCBjdHggPSBvZmZzY3JlZW4uZ2V0Q29udGV4dCgiMmQiKTsKICAgICAgY3R4LmRyYXdJbWFnZShiaXRtYXAsIDAsIDApOwogICAgICBiaXRtYXAuY2xvc2UoKTsKICAgICAgY29uc3QgYmxvYiA9IGF3YWl0IG9mZnNjcmVlbi5jb252ZXJ0VG9CbG9iKGRhdGFVUkxPcHRpb25zKTsKICAgICAgY29uc3QgdHlwZSA9IGJsb2IudHlwZTsKICAgICAgY29uc3QgYXJyYXlCdWZmZXIgPSBhd2FpdCBibG9iLmFycmF5QnVmZmVyKCk7CiAgICAgIGNvbnN0IGJhc2U2NCA9IGVuY29kZShhcnJheUJ1ZmZlcik7CiAgICAgIGlmICghbGFzdEJsb2JNYXAuaGFzKGlkKSAmJiBhd2FpdCB0cmFuc3BhcmVudEJhc2U2NCA9PT0gYmFzZTY0KSB7CiAgICAgICAgbGFzdEJsb2JNYXAuc2V0KGlkLCBiYXNlNjQpOwogICAgICAgIHJldHVybiB3b3JrZXIucG9zdE1lc3NhZ2UoeyBpZCB9KTsKICAgICAgfQogICAgICBpZiAobGFzdEJsb2JNYXAuZ2V0KGlkKSA9PT0gYmFzZTY0KSByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQgfSk7CiAgICAgIHdvcmtlci5wb3N0TWVzc2FnZSh7CiAgICAgICAgaWQsCiAgICAgICAgdHlwZSwKICAgICAgICBiYXNlNjQsCiAgICAgICAgd2lkdGgsCiAgICAgICAgaGVpZ2h0CiAgICAgIH0pOwogICAgICBsYXN0QmxvYk1hcC5zZXQoaWQsIGJhc2U2NCk7CiAgICB9IGVsc2UgewogICAgICByZXR1cm4gd29ya2VyLnBvc3RNZXNzYWdlKHsgaWQ6IGUuZGF0YS5pZCB9KTsKICAgIH0KICB9Owp9KSgpOwovLyMgc291cmNlTWFwcGluZ1VSTD1pbWFnZS1iaXRtYXAtZGF0YS11cmwtd29ya2VyLUlKcEM3Z19iLmpzLm1hcAo=",cet=function(t){return Uint8Array.from(atob(t),function(e){return e.charCodeAt(0)})},ase=typeof window<"u"&&window.Blob&&new Blob([cet($Oe)],{type:"text/javascript;charset=utf-8"});function det(t){var e;try{if(e=ase&&(window.URL||window.webkitURL).createObjectURL(ase),!e)throw"";var i=new Worker(e,{name:t==null?void 0:t.name});return i.addEventListener("error",function(){(window.URL||window.webkitURL).revokeObjectURL(e)}),i}catch{return new Worker("data:text/javascript;base64,"+$Oe,{name:t==null?void 0:t.name})}finally{e&&(window.URL||window.webkitURL).revokeObjectURL(e)}}var fet=(function(){function t(i){var n=this;Jr(this,"pendingCanvasMutations",new Map),Jr(this,"rafStamps",{latestId:0,invokeId:null}),Jr(this,"mirror"),Jr(this,"mutationCb"),Jr(this,"resetObservers"),Jr(this,"frozen",!1),Jr(this,"locked",!1),Jr(this,"processMutation",function(d,f){var h=n.rafStamps.invokeId&&n.rafStamps.latestId!==n.rafStamps.invokeId;(h||!n.rafStamps.invokeId)&&(n.rafStamps.invokeId=n.rafStamps.latestId),n.pendingCanvasMutations.has(d)||n.pendingCanvasMutations.set(d,[]),n.pendingCanvasMutations.get(d).push(f)});var r=i.sampling,o=r===void 0?"all":r,a=i.win,s=i.blockClass,l=i.blockSelector,u=i.recordCanvas,c=i.dataURLOptions;this.mutationCb=i.mutationCb,this.mirror=i.mirror,u&&o==="all"&&this.initCanvasMutationObserver(a,s,l),u&&typeof o=="number"&&this.initCanvasFPSObserver(o,a,s,l,{dataURLOptions:c})}var e=t.prototype;return e.reset=function(){this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers()},e.freeze=function(){this.frozen=!0},e.unfreeze=function(){this.frozen=!1},e.lock=function(){this.locked=!0},e.unlock=function(){this.locked=!1},e.initCanvasFPSObserver=function(n,r,o,a,s){var l=this,u=nse(r,o,a,!0),c=new Map,d=new det;d.onmessage=function(y){var m=y.data.id;if(c.set(m,!1),"base64"in y.data){var b=y.data,S=b.base64,_=b.type,C=b.width,P=b.height;l.mutationCb({id:m,type:wk["2D"],commands:[{property:"clearRect",args:[0,0,C,P]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:S}],type:_}]},0,0]}]})}};var f=1e3/n,h=0,p,g=function(){var y=[];return r.document.querySelectorAll("canvas").forEach(function(m){Lf(m,o,a,!0)||y.push(m)}),y},v=function(y){if(h&&y-h<f){p=requestAnimationFrame(v);return}h=y;var m=l;g().forEach(U$(function(b){var S,_,C,P;return CD(this,function(x){switch(x.label){case 0:return _=m.mirror.getId(b),c.get(_)?[2]:b.width===0||b.height===0?[2]:(c.set(_,!0),["webgl","webgl2"].includes(b.__context)&&(C=b.getContext(b.__context),((S=C==null?void 0:C.getContextAttributes())==null?void 0:S.preserveDrawingBuffer)===!1&&C.clear(C.COLOR_BUFFER_BIT)),[4,createImageBitmap(b)]);case 1:return P=x.sent(),d.postMessage({id:_,bitmap:P,width:b.width,height:b.height,dataURLOptions:s.dataURLOptions},[P]),[2]}})})),p=requestAnimationFrame(v)};p=requestAnimationFrame(v),this.resetObservers=function(){u(),cancelAnimationFrame(p)}},e.initCanvasMutationObserver=function(n,r,o){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();var a=nse(n,r,o,!1),s=aet(this.processMutation.bind(this),n,r,o),l=uet(this.processMutation.bind(this),n,r,o);this.resetObservers=function(){a(),s(),l()}},e.startPendingCanvasMutationFlusher=function(){var n=this;requestAnimationFrame(function(){return n.flushPendingCanvasMutations()})},e.startRAFTimestamping=function(){var n=this,r=function(o){n.rafStamps.latestId=o,requestAnimationFrame(r)};requestAnimationFrame(r)},e.flushPendingCanvasMutations=function(){var n=this;this.pendingCanvasMutations.forEach(function(r,o){var a=n.mirror.getId(o);n.flushPendingCanvasMutationFor(o,a)}),requestAnimationFrame(function(){return n.flushPendingCanvasMutations()})},e.flushPendingCanvasMutationFor=function(n,r){if(!(this.frozen||this.locked)){var o=this.pendingCanvasMutations.get(n);if(!(!o||r===-1)){var a=o.map(function(l){l.type;var u=PD(l,["type"]);return u}),s=o[0].type;this.mutationCb({id:r,type:s,commands:a}),this.pendingCanvasMutations.delete(n)}}},t})(),het=(function(){function t(i){Jr(this,"trackedLinkElements",new WeakSet),Jr(this,"mutationCb"),Jr(this,"adoptedStyleSheetCb"),Jr(this,"styleMirror",new MQe),this.mutationCb=i.mutationCb,this.adoptedStyleSheetCb=i.adoptedStyleSheetCb}var e=t.prototype;return e.attachLinkElement=function(n,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(n)},e.trackLinkElement=function(n){this.trackedLinkElements.has(n)||(this.trackedLinkElements.add(n),this.trackStylesheetInLinkElement(n))},e.adoptStyleSheets=function(n,r){var o,a=function(){var d=c.value,f=void 0;o.styleMirror.has(d)?f=o.styleMirror.getId(d):(f=o.styleMirror.add(d),l.push({styleId:f,rules:Array.from(d.rules||CSSRule,function(h,p){return{rule:aAe(h,d.href),index:p}})})),s.styleIds.push(f)};if(n.length!==0){for(var s={id:r,styleIds:[]},l=[],u=Ur(n),c;!(c=u()).done;)o=this,a();l.length>0&&(s.styles=l),this.adoptedStyleSheetCb(s)}},e.reset=function(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet},e.cleanupStylesheetsForRemovedNode=function(n){var r=this;try{if(n.nodeType===Node.DOCUMENT_NODE){var o=n;if(o.adoptedStyleSheets)for(var a=Ur(o.adoptedStyleSheets),s;!(s=a()).done;){var l=s.value;this.styleMirror.remove(l)}}if(n.nodeName==="STYLE"){var u=n;u.sheet&&this.styleMirror.remove(u.sheet)}if(n.nodeName==="LINK"&&n.rel==="stylesheet"){var c=n;c.sheet&&this.styleMirror.remove(c.sheet)}n.childNodes&&n.childNodes.forEach(function(d){r.cleanupStylesheetsForRemovedNode(d)})}catch{}},e.trackStylesheetInLinkElement=function(n){},t})(),pet=(function(){function t(){Jr(this,"nodeMap",new WeakMap),Jr(this,"active",!1)}var e=t.prototype;return e.inOtherBuffer=function(n,r){var o=this.nodeMap.get(n);return o&&Array.from(o).some(function(a){return a!==r})},e.add=function(n,r){var o=this;this.active||(this.active=!0,requestAnimationFrame(function(){o.nodeMap=new WeakMap,o.active=!1})),this.nodeMap.set(n,(this.nodeMap.get(n)||new Set).add(r))},e.destroy=function(){},t})(),Ml,IU,g8,B5=!1;try{if(Array.from([1],function(t){return t*2})[0]!==2){var v8=document.createElement("iframe");document.body.appendChild(v8),Array.from=((uae=v8.contentWindow)==null?void 0:uae.Array.from)||Array.from,document.body.removeChild(v8)}}catch(t){console.debug("Unable to override Array.from",t)}var dv=pXe();function BP(t){t===void 0&&(t={});var e=t.emit,i=t.checkoutEveryNms,n=t.checkoutEveryNth,r=t.blockClass,o=r===void 0?"rr-block":r,a=t.blockSelector,s=a===void 0?null:a,l=t.ignoreClass,u=l===void 0?"rr-ignore":l,c=t.ignoreSelector,d=c===void 0?null:c,f=t.maskTextClass,h=f===void 0?"rr-mask":f,p=t.maskTextSelector,g=p===void 0?null:p,v=t.inlineStylesheet,y=v===void 0?!0:v,m=t.maskAllInputs,b=t.maskInputOptions,S=t.slimDOMOptions,_=t.maskInputFn,C=t.maskTextFn,P=t.hooks,x=t.packFn,E=t.sampling,A=E===void 0?{}:E,R=t.dataURLOptions,M=R===void 0?{}:R,D=t.mousemoveWait,F=t.recordDOM,I=F===void 0?!0:F,V=t.recordCanvas,z=V===void 0?!1:V,G=t.recordCrossOriginIframes,H=G===void 0?!1:G,U=t.recordAfter,k=U===void 0?t.recordAfter==="DOMContentLoaded"?t.recordAfter:"load":U,X=t.userTriggeredOnInput,W=X===void 0?!1:X,Y=t.collectFonts,te=Y===void 0?!1:Y,oe=t.inlineImages,de=oe===void 0?!1:oe,ge=t.plugins,Ee=t.keepIframeSrcFn,Re=Ee===void 0?function(){return!1}:Ee,Ae=t.ignoreCSSAttributes,Pe=Ae===void 0?new Set([]):Ae,we=t.errorHandler;jQe(we);var Te=H?window.parent===window:!0,ke=!1;if(!Te)try{window.parent.document&&(ke=!1)}catch{ke=!0}if(Te&&!e)throw new Error("emit function is required");if(!Te&&!ke)return function(){};D!==void 0&&A.mousemove===void 0&&(A.mousemove=D),dv.reset();var $e=m===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0,hidden:!0}:b!==void 0?b:{password:!0},Ne=S===!0||S==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:S==="all",headMetaDescKeywords:S==="all",headTitleMutations:S==="all"}:S||{};RQe();var ve,pe=0,fe=function(_t){for(var Ht=Ur(ge||[]),Pt;!(Pt=Ht()).done;){var Jt=Pt.value;Jt.eventProcessor&&(_t=Jt.eventProcessor(_t))}return x&&!ke&&(_t=x(_t)),_t};Ml=function(_t,Ht){var Pt,Jt=_t;if(Jt.timestamp=N5(),(Pt=qy[0])!=null&&Pt.isFrozen()&&Jt.type!==Ro.FullSnapshot&&!(Jt.type===Ro.IncrementalSnapshot&&Jt.data.source===wn.Mutation)&&qy.forEach(function(Be){return Be.unfreeze()}),Te)e==null||e(fe(Jt),Ht);else if(ke){var zt={type:"rrweb",event:fe(Jt),origin:window.location.origin,isCheckout:Ht};window.parent.postMessage(zt,"*")}if(Jt.type===Ro.FullSnapshot)ve=Jt,pe=0;else if(Jt.type===Ro.IncrementalSnapshot){if(Jt.data.source===wn.Mutation&&Jt.data.isAttachIframe)return;pe++;var Bt=n&&pe>=n,Mr=i&&Jt.timestamp-ve.timestamp>i;(Bt||Mr)&&IU(!0)}};for(var me=function(_t){Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.Mutation},_t)})},Ce=function(_t){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.Scroll},_t)})},Ue=function(_t){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.CanvasMutation},_t)})},Qe=function(_t){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.AdoptedStyleSheet},_t)})},it=new het({mutationCb:me,adoptedStyleSheetCb:Qe}),xt=new tet({mirror:dv,mutationCb:me,stylesheetManager:it,recordCrossOriginIframes:H,wrappedEmit:Ml}),wt=Ur(ge||[]),$t;!($t=wt()).done;){var Mt=$t.value;Mt.getMirror&&Mt.getMirror({nodeMirror:dv,crossOriginIframeMirror:xt.crossOriginIframeMirror,crossOriginIframeStyleMirror:xt.crossOriginIframeStyleMirror})}var rt=new pet;g8=new fet({recordCanvas:z,mutationCb:Ue,win:window,blockClass:o,blockSelector:s,mirror:dv,sampling:A.canvas,dataURLOptions:M});var qe=new ret({mutationCb:me,scrollCb:Ce,bypassOptions:{blockClass:o,blockSelector:s,maskTextClass:h,maskTextSelector:g,inlineStylesheet:y,maskInputOptions:$e,dataURLOptions:M,maskTextFn:C,maskInputFn:_,recordCanvas:z,inlineImages:de,sampling:A,slimDOMOptions:Ne,iframeManager:xt,stylesheetManager:it,canvasManager:g8,keepIframeSrcFn:Re,processedNodeManager:rt},mirror:dv});IU=function(_t){if(_t===void 0&&(_t=!1),!!I){Ml({type:Ro.Meta,data:{href:window.location.href,width:OOe(),height:AOe()}},_t),it.reset(),qe.init(),qy.forEach(function(Pt){return Pt.lock()});var Ht=BXe(document,{mirror:dv,blockClass:o,blockSelector:s,maskTextClass:h,maskTextSelector:g,inlineStylesheet:y,maskAllInputs:$e,maskTextFn:C,maskInputFn:_,slimDOM:Ne,dataURLOptions:M,recordCanvas:z,inlineImages:de,onSerialize:function(Pt){MOe(Pt,dv)&&xt.addIframe(Pt),LOe(Pt,dv)&&it.trackLinkElement(Pt),SK(Pt)&&qe.addShadowRoot(xo.shadowRoot(Pt),document)},onIframeLoad:function(Pt,Jt){xt.attachIframe(Pt,Jt),qe.observeAttachShadow(Pt)},onStylesheetLoad:function(Pt,Jt){it.attachLinkElement(Pt,Jt)},keepIframeSrcFn:Re});if(!Ht)return console.warn("Failed to snapshot the document");Ml({type:Ro.FullSnapshot,data:{node:Ht,initialOffset:wOe(window)}},_t),qy.forEach(function(Pt){return Pt.unlock()}),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&it.adoptStyleSheets(document.adoptedStyleSheets,dv.getId(document))}};try{var vt=[],kt=function(_t){var Ht;return jo(eet)({mutationCb:me,mousemoveCb:function(Pt,Jt){return Ml({type:Ro.IncrementalSnapshot,data:{source:Jt,positions:Pt}})},mouseInteractionCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.MouseInteraction},Pt)})},scrollCb:Ce,viewportResizeCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.ViewportResize},Pt)})},inputCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.Input},Pt)})},mediaInteractionCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.MediaInteraction},Pt)})},styleSheetRuleCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.StyleSheetRule},Pt)})},styleDeclarationCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.StyleDeclaration},Pt)})},canvasMutationCb:Ue,fontCb:function(Pt){return Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.Font},Pt)})},selectionCb:function(Pt){Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.Selection},Pt)})},customElementCb:function(Pt){Ml({type:Ro.IncrementalSnapshot,data:Zn({source:wn.CustomElement},Pt)})},blockClass:o,ignoreClass:u,ignoreSelector:d,maskTextClass:h,maskTextSelector:g,maskInputOptions:$e,inlineStylesheet:y,sampling:A,recordDOM:I,recordCanvas:z,inlineImages:de,userTriggeredOnInput:W,collectFonts:te,doc:_t,maskInputFn:_,maskTextFn:C,keepIframeSrcFn:Re,blockSelector:s,slimDOMOptions:Ne,dataURLOptions:M,mirror:dv,iframeManager:xt,stylesheetManager:it,shadowDomManager:qe,processedNodeManager:rt,canvasManager:g8,ignoreCSSAttributes:Pe,plugins:((Ht=ge==null?void 0:ge.filter(function(Pt){return Pt.observer}))==null?void 0:Ht.map(function(Pt){return{observer:Pt.observer,options:Pt.options,callback:function(Jt){return Ml({type:Ro.Plugin,data:{plugin:Pt.name,payload:Jt}})}}}))||[]},P)};xt.addLoadListener(function(_t){try{var Ht=_t.contentDocument,Pt=kt(Ht);vt.push(Pt);var Jt=xt.getObserverCleanup(_t);xt.setObserverCleanup(_t,function(){if(Jt)try{Jt()}catch{}try{Pt();var zt=vt.indexOf(Pt);zt!==-1&&vt.splice(zt,1),HQe(Ht)}catch{}})}catch(zt){console.warn(zt)}});var Xe=function(){IU(),vt.push(kt(document)),B5=!0};return document.readyState==="interactive"||document.readyState==="complete"?Xe():(vt.push(Mf("DOMContentLoaded",function(){Ml({type:Ro.DomContentLoaded,data:{}}),k==="DOMContentLoaded"&&Xe()})),vt.push(Mf("load",function(){Ml({type:Ro.Load,data:{}}),k==="load"&&Xe()},window))),function(){vt.forEach(function(_t){try{_t()}catch(Pt){var Ht=String(Pt).toLowerCase();Ht.includes("cross-origin")||console.warn(Pt)}}),rt.destroy(),B5=!1,VQe()}}catch(_t){console.warn(_t)}}BP.addCustomEvent=function(t,e){if(!B5)throw new Error("please add custom event after start recording");Ml({type:Ro.Custom,data:{tag:t,payload:e}})};BP.freezePage=function(){qy.forEach(function(t){return t.freeze()})};BP.takeFullSnapshot=function(t){if(!B5)throw new Error("please take full snapshot after start recording");IU(t)};BP.mirror=dv;var sse;(function(t){t[t.NotStarted=0]="NotStarted",t[t.Running=1]="Running",t[t.Stopped=2]="Stopped"})(sse||(sse={}));BP.addCustomEvent;BP.freezePage;BP.takeFullSnapshot;var lse={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot","querySelector","querySelectorAll"],MutationObserver:[]},use={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:[],MutationObserver:["constructor"]},WH={},get=function(){return!!globalThis.Zone};function qQ(t){if(WH[t])return WH[t];var e=globalThis[t],i=e.prototype,n=t in lse?lse[t]:void 0,r=!!(n&&n.every(function(c){var d,f;return!!((f=(d=Object.getOwnPropertyDescriptor(i,c))==null?void 0:d.get)!=null&&f.toString().includes("[native code]"))})),o=t in use?use[t]:void 0,a=!!(o&&o.every(function(c){var d;return typeof i[c]=="function"&&((d=i[c])==null?void 0:d.toString().includes("[native code]"))}));if(r&&a&&!get())return WH[t]=e.prototype,e.prototype;try{var s=document.createElement("iframe");document.body.appendChild(s);var l=s.contentWindow;if(!l)return e.prototype;var u=l[t].prototype;return document.body.removeChild(s),u?WH[t]=u:i}catch{return i}}var y8={};function jP(t,e,i){var n,r=t+"."+String(i);if(y8[r])return y8[r].call(e);var o=qQ(t),a=(n=Object.getOwnPropertyDescriptor(o,i))==null?void 0:n.get;return a?(y8[r]=a,a.call(e)):e[i]}var m8={};function WOe(t,e,i){var n=t+"."+String(i);if(m8[n])return m8[n].bind(e);var r=qQ(t),o=r[i];return typeof o!="function"?e[i]:(m8[n]=o,o.bind(e))}function vet(t){return jP("Node",t,"childNodes")}function yet(t){return jP("Node",t,"parentNode")}function met(t){return jP("Node",t,"parentElement")}function bet(t){return jP("Node",t,"textContent")}function _et(t,e){return WOe("Node",t,"contains")(e)}function Pet(t){return WOe("Node",t,"getRootNode")()}function Cet(t){return!t||!("host"in t)?null:jP("ShadowRoot",t,"host")}function Tet(t){return t.styleSheets}function xet(t){return!t||!("shadowRoot"in t)?null:jP("Element",t,"shadowRoot")}function Eet(t,e){return jP("Element",t,"querySelector")(e)}function wet(t,e){return jP("Element",t,"querySelectorAll")(e)}function Aet(){return qQ("MutationObserver").constructor}function Oet(t,e,i){try{if(!(e in t))return function(){};var n=t[e],r=i(n);return typeof r=="function"&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__rrweb_original__:{enumerable:!1,value:n}})),t[e]=r,function(){t[e]=n}}catch{return function(){}}}var cse={childNodes:vet,parentNode:yet,parentElement:met,textContent:bet,contains:_et,getRootNode:Pet,host:Cet,styleSheets:Tet,shadowRoot:xet,querySelector:Eet,querySelectorAll:wet,mutationObserver:Aet,patch:Oet};function PK(t,e,i){if(!t)return!1;if(t.nodeType!==t.ELEMENT_NODE)return PK(cse.parentNode(t),e);for(var n=t.classList.length;n--;){var r=t.classList[n];if(e.test(r))return!0}return PK(cse.parentNode(t),e)}function Det(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Ret(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var i=function n(){return Ni(this,n)?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};i.prototype=e.prototype}else i={};return Object.defineProperty(i,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(i,n,r.get?r:{enumerable:!0,get:function(){return t[n]}})}),i}var XQ={exports:{}},As=String,GOe=function(){return{isColorSupported:!1,reset:As,bold:As,dim:As,italic:As,underline:As,inverse:As,hidden:As,strikethrough:As,black:As,red:As,green:As,yellow:As,blue:As,magenta:As,cyan:As,white:As,gray:As,bgBlack:As,bgRed:As,bgGreen:As,bgYellow:As,bgBlue:As,bgMagenta:As,bgCyan:As,bgWhite:As}};XQ.exports=GOe();XQ.exports.createColors=GOe;var Met=XQ.exports,Let={},ket=Object.freeze(Object.defineProperty({__proto__:null,default:Let},Symbol.toStringTag,{value:"Module"})),su=Ret(ket),dse=Met,fse=su,CK=(function(t){Ks(e,t);function e(n,r,o,a,s,l){var u;return u=t.call(this,n)||this,u.name="CssSyntaxError",u.reason=n,s&&(u.file=s),a&&(u.source=a),l&&(u.plugin=l),typeof r<"u"&&typeof o<"u"&&(typeof r=="number"?(u.line=r,u.column=o):(u.line=r.line,u.column=r.column,u.endLine=o.line,u.endColumn=o.column)),u.setMessage(),Error.captureStackTrace&&Error.captureStackTrace(u,e),u}var i=e.prototype;return i.setMessage=function(){this.message=this.plugin?this.plugin+": ":"",this.message+=this.file?this.file:"<css input>",typeof this.line<"u"&&(this.message+=":"+this.line+":"+this.column),this.message+=": "+this.reason},i.showSourceCode=function(r){var o=this;if(!this.source)return"";var a=this.source;r==null&&(r=dse.isColorSupported),fse&&r&&(a=fse(a));var s=a.split(/\r?\n/),l=Math.max(this.line-3,0),u=Math.min(this.line+2,s.length),c=String(u).length,d,f;if(r){var h=dse.createColors(!0),p=h.bold,g=h.gray,v=h.red;d=function(y){return p(v(y))},f=function(y){return g(y)}}else d=f=function(y){return y};return s.slice(l,u).map(function(y,m){var b=l+1+m,S=" "+(" "+b).slice(-c)+" | ";if(b===o.line){var _=f(S.replace(/\d/g," "))+y.slice(0,o.column-1).replace(/[^\t]/g," ");return d(">")+f(S)+y+`
 `+_+d("^")}return" "+f(S)+y}).join(`
`)},i.toString=function(){var r=this.showSourceCode();return r&&(r=`

`+r+`
`),this.name+": "+this.message+r},e})(Kj(Error)),KQ=CK;CK.default=CK;var VP={};VP.isClean=Symbol("isClean");VP.my=Symbol("my");var hse={after:`
`,beforeClose:`
`,beforeComment:`
`,beforeDecl:`
`,beforeOpen:" ",beforeRule:`
`,colon:": ",commentLeft:" ",commentRight:" ",emptyBody:"",indent:"    ",semicolon:!1};function Iet(t){return t[0].toUpperCase()+t.slice(1)}var TK=(function(){function t(i){this.builder=i}var e=t.prototype;return e.atrule=function(n,r){var o="@"+n.name,a=n.params?this.rawValue(n,"params"):"";if(typeof n.raws.afterName<"u"?o+=n.raws.afterName:a&&(o+=" "),n.nodes)this.block(n,o+a);else{var s=(n.raws.between||"")+(r?";":"");this.builder(o+a+s,n)}},e.beforeAfter=function(n,r){var o;n.type==="decl"?o=this.raw(n,null,"beforeDecl"):n.type==="comment"?o=this.raw(n,null,"beforeComment"):r==="before"?o=this.raw(n,null,"beforeRule"):o=this.raw(n,null,"beforeClose");for(var a=n.parent,s=0;a&&a.type!=="root";)s+=1,a=a.parent;if(o.includes(`
`)){var l=this.raw(n,null,"indent");if(l.length)for(var u=0;u<s;u++)o+=l}return o},e.block=function(n,r){var o=this.raw(n,"between","beforeOpen");this.builder(r+o+"{",n,"start");var a;n.nodes&&n.nodes.length?(this.body(n),a=this.raw(n,"after")):a=this.raw(n,"after","emptyBody"),a&&this.builder(a),this.builder("}",n,"end")},e.body=function(n){for(var r=n.nodes.length-1;r>0&&n.nodes[r].type==="comment";)r-=1;for(var o=this.raw(n,"semicolon"),a=0;a<n.nodes.length;a++){var s=n.nodes[a],l=this.raw(s,"before");l&&this.builder(l),this.stringify(s,r!==a||o)}},e.comment=function(n){var r=this.raw(n,"left","commentLeft"),o=this.raw(n,"right","commentRight");this.builder("/*"+r+n.text+o+"*/",n)},e.decl=function(n,r){var o=this.raw(n,"between","colon"),a=n.prop+o+this.rawValue(n,"value");n.important&&(a+=n.raws.important||" !important"),r&&(a+=";"),this.builder(a,n)},e.document=function(n){this.body(n)},e.raw=function(n,r,o){var a;if(o||(o=r),r&&(a=n.raws[r],typeof a<"u"))return a;var s=n.parent;if(o==="before"&&(!s||s.type==="root"&&s.first===n||s&&s.type==="document"))return"";if(!s)return hse[o];var l=n.root();if(l.rawCache||(l.rawCache={}),typeof l.rawCache[o]<"u")return l.rawCache[o];if(o==="before"||o==="after")return this.beforeAfter(n,o);var u="raw"+Iet(o);return this[u]?a=this[u](l,n):l.walk(function(c){if(a=c.raws[r],typeof a<"u")return!1}),typeof a>"u"&&(a=hse[o]),l.rawCache[o]=a,a},e.rawBeforeClose=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length>0&&typeof o.raws.after<"u")return r=o.raws.after,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawBeforeComment=function(n,r){var o;return n.walkComments(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeDecl"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeDecl=function(n,r){var o;return n.walkDecls(function(a){if(typeof a.raws.before<"u")return o=a.raws.before,o.includes(`
`)&&(o=o.replace(/[^\n]+$/,"")),!1}),typeof o>"u"?o=this.raw(r,null,"beforeRule"):o&&(o=o.replace(/\S/g,"")),o},e.rawBeforeOpen=function(n){var r;return n.walk(function(o){if(o.type!=="decl"&&(r=o.raws.between,typeof r<"u"))return!1}),r},e.rawBeforeRule=function(n){var r;return n.walk(function(o){if(o.nodes&&(o.parent!==n||n.first!==o)&&typeof o.raws.before<"u")return r=o.raws.before,r.includes(`
`)&&(r=r.replace(/[^\n]+$/,"")),!1}),r&&(r=r.replace(/\S/g,"")),r},e.rawColon=function(n){var r;return n.walkDecls(function(o){if(typeof o.raws.between<"u")return r=o.raws.between.replace(/[^\s:]/g,""),!1}),r},e.rawEmptyBody=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length===0&&(r=o.raws.after,typeof r<"u"))return!1}),r},e.rawIndent=function(n){if(n.raws.indent)return n.raws.indent;var r;return n.walk(function(o){var a=o.parent;if(a&&a!==n&&a.parent&&a.parent===n&&typeof o.raws.before<"u"){var s=o.raws.before.split(`
`);return r=s[s.length-1],r=r.replace(/\S/g,""),!1}}),r},e.rawSemicolon=function(n){var r;return n.walk(function(o){if(o.nodes&&o.nodes.length&&o.last.type==="decl"&&(r=o.raws.semicolon,typeof r<"u"))return!1}),r},e.rawValue=function(n,r){var o=n[r],a=n.raws[r];return a&&a.value===o?a.raw:o},e.root=function(n){this.body(n),n.raws.after&&this.builder(n.raws.after)},e.rule=function(n){this.block(n,this.rawValue(n,"selector")),n.raws.ownSemicolon&&this.builder(n.raws.ownSemicolon,n,"end")},e.stringify=function(n,r){if(!this[n.type])throw new Error("Unknown AST node type "+n.type+". Maybe you need to change PostCSS stringifier.");this[n.type](n,r)},t})(),YOe=TK;TK.default=TK;var Net=YOe;function xK(t,e){var i=new Net(e);i.stringify(t)}var e6=xK;xK.default=xK;var GH=VP.isClean,Fet=VP.my,Bet=KQ,jet=YOe,Vet=e6;function EK(t,e){var i=new t.constructor;for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&n!=="proxyCache"){var r=t[n],o=typeof r>"u"?"undefined":Ui(r);n==="parent"&&o==="object"?e&&(i[n]=e):n==="source"?i[n]=r:Array.isArray(r)?i[n]=r.map(function(a){return EK(a,i)}):(o==="object"&&r!==null&&(r=EK(r)),i[n]=r)}return i}var wK=(function(){function t(i){i===void 0&&(i={}),this.raws={},this[GH]=!1,this[Fet]=!0;for(var n in i)if(n==="nodes"){this.nodes=[];for(var r=Ur(i[n]),o;!(o=r()).done;){var a=o.value;typeof a.clone=="function"?this.append(a.clone()):this.append(a)}}else this[n]=i[n]}var e=t.prototype;return e.addToError=function(n){if(n.postcssNode=this,n.stack&&this.source&&/\n\s{4}at /.test(n.stack)){var r=this.source;n.stack=n.stack.replace(/\n\s{4}at /,"$&"+r.input.from+":"+r.start.line+":"+r.start.column+"$&")}return n},e.after=function(n){return this.parent.insertAfter(this,n),this},e.assign=function(n){n===void 0&&(n={});for(var r in n)this[r]=n[r];return this},e.before=function(n){return this.parent.insertBefore(this,n),this},e.cleanRaws=function(n){delete this.raws.before,delete this.raws.after,n||delete this.raws.between},e.clone=function(n){n===void 0&&(n={});var r=EK(this);for(var o in n)r[o]=n[o];return r},e.cloneAfter=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertAfter(this,r),r},e.cloneBefore=function(n){n===void 0&&(n={});var r=this.clone(n);return this.parent.insertBefore(this,r),r},e.error=function(n,r){if(r===void 0&&(r={}),this.source){var o=this.rangeBy(r),a=o.end,s=o.start;return this.source.input.error(n,{column:s.column,line:s.line},{column:a.column,line:a.line},r)}return new Bet(n)},e.getProxyProcessor=function(){return{get:function(r,o){return o==="proxyOf"?r:o==="root"?function(){return r.root().toProxy()}:r[o]},set:function(r,o,a){return r[o]===a||(r[o]=a,(o==="prop"||o==="value"||o==="name"||o==="params"||o==="important"||o==="text")&&r.markDirty()),!0}}},e.markDirty=function(){if(this[GH]){this[GH]=!1;for(var n=this;n=n.parent;)n[GH]=!1}},e.next=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n+1]}},e.positionBy=function(n,r){var o=this.source.start;if(n.index)o=this.positionInside(n.index,r);else if(n.word){r=this.toString();var a=r.indexOf(n.word);a!==-1&&(o=this.positionInside(a,r))}return o},e.positionInside=function(n,r){for(var o=r||this.toString(),a=this.source.start.column,s=this.source.start.line,l=0;l<n;l++)o[l]===`
`?(a=1,s+=1):a+=1;return{column:a,line:s}},e.prev=function(){if(this.parent){var n=this.parent.index(this);return this.parent.nodes[n-1]}},e.rangeBy=function(n){var r={column:this.source.start.column,line:this.source.start.line},o=this.source.end?{column:this.source.end.column+1,line:this.source.end.line}:{column:r.column+1,line:r.line};if(n.word){var a=this.toString(),s=a.indexOf(n.word);s!==-1&&(r=this.positionInside(s,a),o=this.positionInside(s+n.word.length,a))}else n.start?r={column:n.start.column,line:n.start.line}:n.index&&(r=this.positionInside(n.index)),n.end?o={column:n.end.column,line:n.end.line}:typeof n.endIndex=="number"?o=this.positionInside(n.endIndex):n.index&&(o=this.positionInside(n.index+1));return(o.line<r.line||o.line===r.line&&o.column<=r.column)&&(o={column:r.column+1,line:r.line}),{end:o,start:r}},e.raw=function(n,r){var o=new jet;return o.raw(this,n,r)},e.remove=function(){return this.parent&&this.parent.removeChild(this),this.parent=void 0,this},e.replaceWith=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];if(this.parent){for(var a=this,s=!1,l=Ur(r),u;!(u=l()).done;){var c=u.value;c===this?s=!0:s?(this.parent.insertAfter(a,c),a=c):this.parent.insertBefore(a,c)}s||this.remove()}return this},e.root=function(){for(var n=this;n.parent&&n.parent.type!=="document";)n=n.parent;return n},e.toJSON=function(n,r){var o={},a=r==null;r=r||new Map;var s=0;for(var l in this)if(Object.prototype.hasOwnProperty.call(this,l)&&!(l==="parent"||l==="proxyCache")){var u=this[l];if(Array.isArray(u))o[l]=u.map(function(d){return(typeof d>"u"?"undefined":Ui(d))==="object"&&d.toJSON?d.toJSON(null,r):d});else if((typeof u>"u"?"undefined":Ui(u))==="object"&&u.toJSON)o[l]=u.toJSON(null,r);else if(l==="source"){var c=r.get(u.input);c==null&&(c=s,r.set(u.input,s),s++),o[l]={end:u.end,inputId:c,start:u.start}}else o[l]=u}return a&&(o.inputs=[].concat(r.keys()).map(function(d){return d.toJSON()})),o},e.toProxy=function(){return this.proxyCache||(this.proxyCache=new Proxy(this,this.getProxyProcessor())),this.proxyCache},e.toString=function(n){n===void 0&&(n=Vet),n.stringify&&(n=n.stringify);var r="";return n(this,function(o){r+=o}),r},e.warn=function(n,r,o){var a={node:this};for(var s in o)a[s]=o[s];return n.warn(r,a)},Is(t,[{key:"proxyOf",get:function(){return this}}]),t})(),t6=wK;wK.default=wK;var Het=t6,AK=(function(t){Ks(e,t);function e(i){var n;return i&&typeof i.value<"u"&&typeof i.value!="string"&&(i=Zn({},i,{value:String(i.value)})),n=t.call(this,i)||this,n.type="decl",n}return Is(e,[{key:"variable",get:function(){return this.prop.startsWith("--")||this.prop[0]==="$"}}]),e})(Het),r6=AK;AK.default=AK;var Uet="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",zet=function(t){t===void 0&&(t=21);for(var e="",i=t;i--;)e+=Uet[Math.random()*64|0];return e},$et={nanoid:zet},pse=su.SourceMapConsumer,gse=su.SourceMapGenerator,Wet=su.existsSync,Get=su.readFileSync,b8=su.dirname,Yet=su.join;function qet(t){return Buffer?Buffer.from(t,"base64").toString():window.atob(t)}var OK=(function(){function t(i,n){if(n.map!==!1){this.loadAnnotation(i),this.inline=this.startWith(this.annotation,"data:");var r=n.map?n.map.prev:void 0,o=this.loadMap(n.from,r);!this.mapFile&&n.from&&(this.mapFile=n.from),this.mapFile&&(this.root=b8(this.mapFile)),o&&(this.text=o)}}var e=t.prototype;return e.consumer=function(){return this.consumerCache||(this.consumerCache=new pse(this.text)),this.consumerCache},e.decodeInline=function(n){var r=/^data:application\/json;charset=utf-?8;base64,/,o=/^data:application\/json;base64,/,a=/^data:application\/json;charset=utf-?8,/,s=/^data:application\/json,/;if(a.test(n)||s.test(n))return decodeURIComponent(n.substr(RegExp.lastMatch.length));if(r.test(n)||o.test(n))return qet(n.substr(RegExp.lastMatch.length));var l=n.match(/data:application\/json;([^,]+),/)[1];throw new Error("Unsupported source map encoding "+l)},e.getAnnotationURL=function(n){return n.replace(/^\/\*\s*# sourceMappingURL=/,"").trim()},e.isMap=function(n){return(typeof n>"u"?"undefined":Ui(n))!=="object"?!1:typeof n.mappings=="string"||typeof n._mappings=="string"||Array.isArray(n.sections)},e.loadAnnotation=function(n){var r=n.match(/\/\*\s*# sourceMappingURL=/gm);if(r){var o=n.lastIndexOf(r.pop()),a=n.indexOf("*/",o);o>-1&&a>-1&&(this.annotation=this.getAnnotationURL(n.substring(o,a)))}},e.loadFile=function(n){if(this.root=b8(n),Wet(n))return this.mapFile=n,Get(n,"utf-8").toString().trim()},e.loadMap=function(n,r){if(r===!1)return!1;if(r){if(typeof r=="string")return r;if(typeof r=="function"){var o=r(n);if(o){var a=this.loadFile(o);if(!a)throw new Error("Unable to load previous source map: "+o.toString());return a}}else{if(Ni(r,pse))return gse.fromSourceMap(r).toString();if(Ni(r,gse))return r.toString();if(this.isMap(r))return JSON.stringify(r);throw new Error("Unsupported previous source map format: "+r.toString())}}else{if(this.inline)return this.decodeInline(this.annotation);if(this.annotation){var s=this.annotation;return n&&(s=Yet(b8(n),s)),this.loadFile(s)}}},e.startWith=function(n,r){return n?n.substr(0,r.length)===r:!1},e.withContent=function(){return!!(this.consumer().sourcesContent&&this.consumer().sourcesContent.length>0)},t})(),qOe=OK;OK.default=OK;var Xet=su.SourceMapConsumer,Ket=su.SourceMapGenerator,vse=su.fileURLToPath,YH=su.pathToFileURL,DK=su.isAbsolute,RK=su.resolve,Zet=$et.nanoid,S8=su,yse=KQ,Jet=qOe,_8=Symbol("fromOffsetCache"),Qet=!!(Xet&&Ket),mse=!!(RK&&DK),j5=(function(){function t(i,n){if(n===void 0&&(n={}),i===null||typeof i>"u"||(typeof i>"u"?"undefined":Ui(i))==="object"&&!i.toString)throw new Error("PostCSS received "+i+" instead of CSS string");if(this.css=i.toString(),this.css[0]==="\uFEFF"||this.css[0]===""?(this.hasBOM=!0,this.css=this.css.slice(1)):this.hasBOM=!1,n.from&&(!mse||/^\w+:\/\//.test(n.from)||DK(n.from)?this.file=n.from:this.file=RK(n.from)),mse&&Qet){var r=new Jet(this.css,n);if(r.text){this.map=r;var o=r.consumer().file;!this.file&&o&&(this.file=this.mapResolve(o))}}this.file||(this.id="<input css "+Zet(6)+">"),this.map&&(this.map.file=this.from)}var e=t.prototype;return e.error=function(n,r,o,a){a===void 0&&(a={});var s,l,u;if(r&&(typeof r>"u"?"undefined":Ui(r))==="object"){var c=r,d=o;if(typeof c.offset=="number"){var f=this.fromOffset(c.offset);r=f.line,o=f.col}else r=c.line,o=c.column;if(typeof d.offset=="number"){var h=this.fromOffset(d.offset);l=h.line,u=h.col}else l=d.line,u=d.column}else if(!o){var p=this.fromOffset(r);r=p.line,o=p.col}var g=this.origin(r,o,l,u);return g?s=new yse(n,g.endLine===void 0?g.line:{column:g.column,line:g.line},g.endLine===void 0?g.column:{column:g.endColumn,line:g.endLine},g.source,g.file,a.plugin):s=new yse(n,l===void 0?r:{column:o,line:r},l===void 0?o:{column:u,line:l},this.css,this.file,a.plugin),s.input={column:o,endColumn:u,endLine:l,line:r,source:this.css},this.file&&(YH&&(s.input.url=YH(this.file).toString()),s.input.file=this.file),s},e.fromOffset=function(n){var r,o;if(this[_8])o=this[_8];else{var a=this.css.split(`
`);o=new Array(a.length);for(var s=0,l=0,u=a.length;l<u;l++)o[l]=s,s+=a[l].length+1;this[_8]=o}r=o[o.length-1];var c=0;if(n>=r)c=o.length-1;else for(var d=o.length-2,f;c<d;)if(f=c+(d-c>>1),n<o[f])d=f-1;else if(n>=o[f+1])c=f+1;else{c=f;break}return{col:n-o[c]+1,line:c+1}},e.mapResolve=function(n){return/^\w+:\/\//.test(n)?n:RK(this.map.consumer().sourceRoot||this.map.root||".",n)},e.origin=function(n,r,o,a){if(!this.map)return!1;var s=this.map.consumer(),l=s.originalPositionFor({column:r,line:n});if(!l.source)return!1;var u;typeof o=="number"&&(u=s.originalPositionFor({column:a,line:o}));var c;DK(l.source)?c=YH(l.source):c=new URL(l.source,this.map.consumer().sourceRoot||YH(this.map.mapFile));var d={column:l.column,endColumn:u&&u.column,endLine:u&&u.line,line:l.line,url:c.toString()};if(c.protocol==="file:")if(vse)d.file=vse(c);else throw new Error("file: protocol is not available in this PostCSS build");var f=s.sourceContentFor(l.source);return f&&(d.source=f),d},e.toJSON=function(){for(var n={},r=0,o=["hasBOM","css","file","id"];r<o.length;r++){var a=o[r];this[a]!=null&&(n[a]=this[a])}return this.map&&(n.map=Zn({},this.map),n.map.consumerCache&&(n.map.consumerCache=void 0)),n},Is(t,[{key:"from",get:function(){return this.file||this.id}}]),t})(),i6=j5;j5.default=j5;S8&&S8.registerInput&&S8.registerInput(j5);var XOe=su.SourceMapConsumer,NU=su.SourceMapGenerator,FU=su.dirname,KOe=su.relative,ZOe=su.resolve,JOe=su.sep,bse=su.pathToFileURL,ett=i6,ttt=!!(XOe&&NU),rtt=!!(FU&&ZOe&&KOe&&JOe),itt=(function(){function t(i,n,r,o){this.stringify=i,this.mapOpts=r.map||{},this.root=n,this.opts=r,this.css=o,this.originalCSS=o,this.usesFileUrls=!this.mapOpts.from&&this.mapOpts.absolute,this.memoizedFileURLs=new Map,this.memoizedPaths=new Map,this.memoizedURLs=new Map}var e=t.prototype;return e.addAnnotation=function(){var n;this.isInline()?n="data:application/json;base64,"+this.toBase64(this.map.toString()):typeof this.mapOpts.annotation=="string"?n=this.mapOpts.annotation:typeof this.mapOpts.annotation=="function"?n=this.mapOpts.annotation(this.opts.to,this.root):n=this.outputFile()+".map";var r=`
`;this.css.includes(`\r
`)&&(r=`\r
`),this.css+=r+"/*# sourceMappingURL="+n+" */"},e.applyPrevMaps=function(){for(var n=Ur(this.previous()),r;!(r=n()).done;){var o=r.value,a=this.toUrl(this.path(o.file)),s=o.root||FU(o.file),l=void 0;this.mapOpts.sourcesContent===!1?(l=new XOe(o.text),l.sourcesContent&&(l.sourcesContent=null)):l=o.consumer(),this.map.applySourceMap(l,a,this.toUrl(this.path(s)))}},e.clearAnnotation=function(){if(this.mapOpts.annotation!==!1)if(this.root)for(var n,r=this.root.nodes.length-1;r>=0;r--)n=this.root.nodes[r],n.type==="comment"&&n.text.indexOf("# sourceMappingURL=")===0&&this.root.removeChild(r);else this.css&&(this.css=this.css.replace(/\n*?\/\*#[\S\s]*?\*\/$/gm,""))},e.generate=function(){if(this.clearAnnotation(),rtt&&ttt&&this.isMap())return this.generateMap();var n="";return this.stringify(this.root,function(r){n+=r}),[n]},e.generateMap=function(){if(this.root)this.generateString();else if(this.previous().length===1){var n=this.previous()[0].consumer();n.file=this.outputFile(),this.map=NU.fromSourceMap(n,{ignoreInvalidMapping:!0})}else this.map=new NU({file:this.outputFile(),ignoreInvalidMapping:!0}),this.map.addMapping({generated:{column:0,line:1},original:{column:0,line:1},source:this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>"});return this.isSourcesContent()&&this.setSourcesContent(),this.root&&this.previous().length>0&&this.applyPrevMaps(),this.isAnnotation()&&this.addAnnotation(),this.isInline()?[this.css]:[this.css,this.map]},e.generateString=function(){var n=this;this.css="",this.map=new NU({file:this.outputFile(),ignoreInvalidMapping:!0});var r=1,o=1,a="<no source>",s={generated:{column:0,line:0},original:{column:0,line:0},source:""},l,u;this.stringify(this.root,function(c,d,f){if(n.css+=c,d&&f!=="end"&&(s.generated.line=r,s.generated.column=o-1,d.source&&d.source.start?(s.source=n.sourcePath(d),s.original.line=d.source.start.line,s.original.column=d.source.start.column-1,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,n.map.addMapping(s))),l=c.match(/\n/g),l?(r+=l.length,u=c.lastIndexOf(`
`),o=c.length-u):o+=c.length,d&&f!=="start"){var h=d.parent||{raws:{}},p=d.type==="decl"||d.type==="atrule"&&!d.nodes;(!p||d!==h.last||h.raws.semicolon)&&(d.source&&d.source.end?(s.source=n.sourcePath(d),s.original.line=d.source.end.line,s.original.column=d.source.end.column-1,s.generated.line=r,s.generated.column=o-2,n.map.addMapping(s)):(s.source=a,s.original.line=1,s.original.column=0,s.generated.line=r,s.generated.column=o-1,n.map.addMapping(s)))}})},e.isAnnotation=function(){return this.isInline()?!0:typeof this.mapOpts.annotation<"u"?this.mapOpts.annotation:this.previous().length?this.previous().some(function(n){return n.annotation}):!0},e.isInline=function(){if(typeof this.mapOpts.inline<"u")return this.mapOpts.inline;var n=this.mapOpts.annotation;return typeof n<"u"&&n!==!0?!1:this.previous().length?this.previous().some(function(r){return r.inline}):!0},e.isMap=function(){return typeof this.opts.map<"u"?!!this.opts.map:this.previous().length>0},e.isSourcesContent=function(){return typeof this.mapOpts.sourcesContent<"u"?this.mapOpts.sourcesContent:this.previous().length?this.previous().some(function(n){return n.withContent()}):!0},e.outputFile=function(){return this.opts.to?this.path(this.opts.to):this.opts.from?this.path(this.opts.from):"to.css"},e.path=function(n){if(this.mapOpts.absolute||n.charCodeAt(0)===60||/^\w+:\/\//.test(n))return n;var r=this.memoizedPaths.get(n);if(r)return r;var o=this.opts.to?FU(this.opts.to):".";typeof this.mapOpts.annotation=="string"&&(o=FU(ZOe(o,this.mapOpts.annotation)));var a=KOe(o,n);return this.memoizedPaths.set(n,a),a},e.previous=function(){var n=this;if(!this.previousMaps)if(this.previousMaps=[],this.root)this.root.walk(function(o){if(o.source&&o.source.input.map){var a=o.source.input.map;n.previousMaps.includes(a)||n.previousMaps.push(a)}});else{var r=new ett(this.originalCSS,this.opts);r.map&&this.previousMaps.push(r.map)}return this.previousMaps},e.setSourcesContent=function(){var n=this,r={};if(this.root)this.root.walk(function(a){if(a.source){var s=a.source.input.from;if(s&&!r[s]){r[s]=!0;var l=n.usesFileUrls?n.toFileUrl(s):n.toUrl(n.path(s));n.map.setSourceContent(l,a.source.input.css)}}});else if(this.css){var o=this.opts.from?this.toUrl(this.path(this.opts.from)):"<no source>";this.map.setSourceContent(o,this.css)}},e.sourcePath=function(n){return this.mapOpts.from?this.toUrl(this.mapOpts.from):this.usesFileUrls?this.toFileUrl(n.source.input.from):this.toUrl(this.path(n.source.input.from))},e.toBase64=function(n){return Buffer?Buffer.from(n).toString("base64"):window.btoa(unescape(encodeURIComponent(n)))},e.toFileUrl=function(n){var r=this.memoizedFileURLs.get(n);if(r)return r;if(bse){var o=bse(n).toString();return this.memoizedFileURLs.set(n,o),o}else throw new Error("`map.absolute` option is not available in this PostCSS build")},e.toUrl=function(n){var r=this.memoizedURLs.get(n);if(r)return r;JOe==="\\"&&(n=n.replace(/\\/g,"/"));var o=encodeURI(n).replace(/[#?]/g,encodeURIComponent);return this.memoizedURLs.set(n,o),o},t})(),QOe=itt,ntt=t6,MK=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="comment",n}return e})(ntt),n6=MK;MK.default=MK;var eDe=VP.isClean,tDe=VP.my,rDe=r6,iDe=n6,ott=t6,nDe,ZQ,JQ,oDe;function aDe(t){return t.map(function(e){return e.nodes&&(e.nodes=aDe(e.nodes)),delete e.source,e})}function sDe(t){if(t[eDe]=!1,t.proxyOf.nodes)for(var e=Ur(t.proxyOf.nodes),i;!(i=e()).done;){var n=i.value;sDe(n)}}var xS=(function(t){Ks(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];for(var s=Ur(o),l;!(l=s()).done;)for(var u=l.value,c=this.normalize(u,this.last),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.push(h)}return this.markDirty(),this},i.cleanRaws=function(r){if(t.prototype.cleanRaws.call(this,r),this.nodes)for(var o=Ur(this.nodes),a;!(a=o()).done;){var s=a.value;s.cleanRaws(r)}},i.each=function(r){if(this.proxyOf.nodes){for(var o=this.getIterator(),a,s;this.indexes[o]<this.proxyOf.nodes.length&&(a=this.indexes[o],s=r(this.proxyOf.nodes[a],a),s!==!1);)this.indexes[o]+=1;return delete this.indexes[o],s}},i.every=function(r){return this.nodes.every(r)},i.getIterator=function(){this.lastEach||(this.lastEach=0),this.indexes||(this.indexes={}),this.lastEach+=1;var r=this.lastEach;return this.indexes[r]=0,r},i.getProxyProcessor=function(){return{get:function(o,a){return a==="proxyOf"?o:o[a]?a==="each"||typeof a=="string"&&a.startsWith("walk")?function(){for(var s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];var c;return(c=o)[a].apply(c,[].concat(l.map(function(d){return typeof d=="function"?function(f,h){return d(f.toProxy(),h)}:d})))}:a==="every"||a==="some"?function(s){return o[a](function(l){for(var u=arguments.length,c=new Array(u>1?u-1:0),d=1;d<u;d++)c[d-1]=arguments[d];return s.apply(void 0,[].concat([l.toProxy()],c))})}:a==="root"?function(){return o.root().toProxy()}:a==="nodes"?o.nodes.map(function(s){return s.toProxy()}):a==="first"||a==="last"?o[a].toProxy():o[a]:o[a]},set:function(o,a,s){return o[a]===s||(o[a]=s,(a==="name"||a==="params"||a==="selector")&&o.markDirty()),!0}}},i.index=function(r){return typeof r=="number"?r:(r.proxyOf&&(r=r.proxyOf),this.proxyOf.nodes.indexOf(r))},i.insertAfter=function(r,o){var a=this.index(r),s=this.normalize(o,this.proxyOf.nodes[a]).reverse();a=this.index(r);for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;this.proxyOf.nodes.splice(a+1,0,c)}var d;for(var f in this.indexes)d=this.indexes[f],a<d&&(this.indexes[f]=d+s.length);return this.markDirty(),this},i.insertBefore=function(r,o){var a=this.index(r),s=a===0?"prepend":!1,l=this.normalize(o,this.proxyOf.nodes[a],s).reverse();a=this.index(r);for(var u=Ur(l),c;!(c=u()).done;){var d=c.value;this.proxyOf.nodes.splice(a,0,d)}var f;for(var h in this.indexes)f=this.indexes[h],a<=f&&(this.indexes[h]=f+l.length);return this.markDirty(),this},i.normalize=function(r,o){var a=this;if(typeof r=="string")r=aDe(nDe(r).nodes);else if(typeof r>"u")r=[];else if(Array.isArray(r)){r=r.slice(0);for(var s=Ur(r),l;!(l=s()).done;){var u=l.value;u.parent&&u.parent.removeChild(u,"ignore")}}else if(r.type==="root"&&this.type!=="document"){r=r.nodes.slice(0);for(var c=Ur(r),d;!(d=c()).done;){var f=d.value;f.parent&&f.parent.removeChild(f,"ignore")}}else if(r.type)r=[r];else if(r.prop){if(typeof r.value>"u")throw new Error("Value field is missed in node creation");typeof r.value!="string"&&(r.value=String(r.value)),r=[new rDe(r)]}else if(r.selector)r=[new ZQ(r)];else if(r.name)r=[new JQ(r)];else if(r.text)r=[new iDe(r)];else throw new Error("Unknown node type in node creation");var h=r.map(function(p){return p[tDe]||e.rebuild(p),p=p.proxyOf,p.parent&&p.parent.removeChild(p),p[eDe]&&sDe(p),typeof p.raws.before>"u"&&o&&typeof o.raws.before<"u"&&(p.raws.before=o.raws.before.replace(/\S/g,"")),p.parent=a.proxyOf,p});return h},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];o=o.reverse();for(var s=Ur(o),l;!(l=s()).done;){for(var u=l.value,c=this.normalize(u,this.first,"prepend").reverse(),d=Ur(c),f;!(f=d()).done;){var h=f.value;this.proxyOf.nodes.unshift(h)}for(var p in this.indexes)this.indexes[p]=this.indexes[p]+c.length}return this.markDirty(),this},i.push=function(r){return r.parent=this,this.proxyOf.nodes.push(r),this},i.removeAll=function(){for(var r=Ur(this.proxyOf.nodes),o;!(o=r()).done;){var a=o.value;a.parent=void 0}return this.proxyOf.nodes=[],this.markDirty(),this},i.removeChild=function(r){r=this.index(r),this.proxyOf.nodes[r].parent=void 0,this.proxyOf.nodes.splice(r,1);var o;for(var a in this.indexes)o=this.indexes[a],o>=r&&(this.indexes[a]=o-1);return this.markDirty(),this},i.replaceValues=function(r,o,a){return a||(a=o,o={}),this.walkDecls(function(s){o.props&&!o.props.includes(s.prop)||o.fast&&!s.value.includes(o.fast)||(s.value=s.value.replace(r,a))}),this.markDirty(),this},i.some=function(r){return this.nodes.some(r)},i.walk=function(r){return this.each(function(o,a){var s;try{s=r(o,a)}catch(l){throw o.addToError(l)}return s!==!1&&o.walk&&(s=o.walk(r)),s})},i.walkAtRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="atrule"&&r.test(a.name))return o(a,s)}):this.walk(function(a,s){if(a.type==="atrule"&&a.name===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="atrule")return o(a,s)}))},i.walkComments=function(r){return this.walk(function(o,a){if(o.type==="comment")return r(o,a)})},i.walkDecls=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="decl"&&r.test(a.prop))return o(a,s)}):this.walk(function(a,s){if(a.type==="decl"&&a.prop===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="decl")return o(a,s)}))},i.walkRules=function(r,o){return o?Ni(r,RegExp)?this.walk(function(a,s){if(a.type==="rule"&&r.test(a.selector))return o(a,s)}):this.walk(function(a,s){if(a.type==="rule"&&a.selector===r)return o(a,s)}):(o=r,this.walk(function(a,s){if(a.type==="rule")return o(a,s)}))},Is(e,[{key:"first",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[0]}},{key:"last",get:function(){if(this.proxyOf.nodes)return this.proxyOf.nodes[this.proxyOf.nodes.length-1]}}]),e})(ott);xS.registerParse=function(t){nDe=t};xS.registerRule=function(t){ZQ=t};xS.registerAtRule=function(t){JQ=t};xS.registerRoot=function(t){oDe=t};var HD=xS;xS.default=xS;xS.rebuild=function(t){t.type==="atrule"?Object.setPrototypeOf(t,JQ.prototype):t.type==="rule"?Object.setPrototypeOf(t,ZQ.prototype):t.type==="decl"?Object.setPrototypeOf(t,rDe.prototype):t.type==="comment"?Object.setPrototypeOf(t,iDe.prototype):t.type==="root"&&Object.setPrototypeOf(t,oDe.prototype),t[tDe]=!0,t.nodes&&t.nodes.forEach(function(e){xS.rebuild(e)})};var att=HD,lDe,uDe,s3=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,Zn({type:"document"},n))||this,r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.toResult=function(r){r===void 0&&(r={});var o=new lDe(new uDe,this,r);return o.stringify()},e})(att);s3.registerLazyResult=function(t){lDe=t};s3.registerProcessor=function(t){uDe=t};var QQ=s3;s3.default=s3;var LK=(function(){function t(i,n){if(n===void 0&&(n={}),this.type="warning",this.text=i,n.node&&n.node.source){var r=n.node.rangeBy(n);this.line=r.start.line,this.column=r.start.column,this.endLine=r.end.line,this.endColumn=r.end.column}for(var o in n)this[o]=n[o]}var e=t.prototype;return e.toString=function(){return this.node?this.node.error(this.text,{index:this.index,plugin:this.plugin,word:this.word}).message:this.plugin?this.plugin+": "+this.text:this.text},t})(),cDe=LK;LK.default=LK;var stt=cDe,kK=(function(){function t(i,n,r){this.processor=i,this.messages=[],this.root=n,this.opts=r,this.css=void 0,this.map=void 0}var e=t.prototype;return e.toString=function(){return this.css},e.warn=function(n,r){r===void 0&&(r={}),r.plugin||this.lastPlugin&&this.lastPlugin.postcssPlugin&&(r.plugin=this.lastPlugin.postcssPlugin);var o=new stt(n,r);return this.messages.push(o),o},e.warnings=function(){return this.messages.filter(function(n){return n.type==="warning"})},Is(t,[{key:"content",get:function(){return this.css}}]),t})(),eee=kK;kK.default=kK;var P8=39,Sse=34,qH=92,_se=47,XH=10,X2=32,KH=12,ZH=9,JH=13,ltt=91,utt=93,ctt=40,dtt=41,ftt=123,htt=125,ptt=59,gtt=42,vtt=58,ytt=64,QH=/[\t\n\f\r "#'()/;[\\\]{}]/g,e4=/[\t\n\f\r !"#'():;@[\\\]{}]|\/(?=\*)/g,mtt=/.[\r\n"'(/\\]/,Pse=/[\da-f]/i,btt=function(e,i){i===void 0&&(i={});var n=e.css.valueOf(),r=i.ignoreErrors,o,a,s,l,u,c,d,f,h,p,g=n.length,v=0,y=[],m=[];function b(){return v}function S(x){throw e.error("Unclosed "+x,v)}function _(){return m.length===0&&v>=g}function C(x){if(m.length)return m.pop();if(!(v>=g)){var E=x?x.ignoreUnclosed:!1;switch(o=n.charCodeAt(v),o){case XH:case X2:case ZH:case JH:case KH:{a=v;do a+=1,o=n.charCodeAt(a);while(o===X2||o===XH||o===ZH||o===JH||o===KH);p=["space",n.slice(v,a)],v=a-1;break}case ltt:case utt:case ftt:case htt:case vtt:case ptt:case dtt:{var A=String.fromCharCode(o);p=[A,A,v];break}case ctt:{if(f=y.length?y.pop()[1]:"",h=n.charCodeAt(v+1),f==="url"&&h!==P8&&h!==Sse&&h!==X2&&h!==XH&&h!==ZH&&h!==KH&&h!==JH){a=v;do{if(c=!1,a=n.indexOf(")",a+1),a===-1)if(r||E){a=v;break}else S("bracket");for(d=a;n.charCodeAt(d-1)===qH;)d-=1,c=!c}while(c);p=["brackets",n.slice(v,a+1),v,a],v=a}else a=n.indexOf(")",v+1),l=n.slice(v,a+1),a===-1||mtt.test(l)?p=["(","(",v]:(p=["brackets",l,v,a],v=a);break}case P8:case Sse:{s=o===P8?"'":'"',a=v;do{if(c=!1,a=n.indexOf(s,a+1),a===-1)if(r||E){a=v+1;break}else S("string");for(d=a;n.charCodeAt(d-1)===qH;)d-=1,c=!c}while(c);p=["string",n.slice(v,a+1),v,a],v=a;break}case ytt:{QH.lastIndex=v+1,QH.test(n),QH.lastIndex===0?a=n.length-1:a=QH.lastIndex-2,p=["at-word",n.slice(v,a+1),v,a],v=a;break}case qH:{for(a=v,u=!0;n.charCodeAt(a+1)===qH;)a+=1,u=!u;if(o=n.charCodeAt(a+1),u&&o!==_se&&o!==X2&&o!==XH&&o!==ZH&&o!==JH&&o!==KH&&(a+=1,Pse.test(n.charAt(a)))){for(;Pse.test(n.charAt(a+1));)a+=1;n.charCodeAt(a+1)===X2&&(a+=1)}p=["word",n.slice(v,a+1),v,a],v=a;break}default:{o===_se&&n.charCodeAt(v+1)===gtt?(a=n.indexOf("*/",v+2)+1,a===0&&(r||E?a=n.length:S("comment")),p=["comment",n.slice(v,a+1),v,a],v=a):(e4.lastIndex=v+1,e4.test(n),e4.lastIndex===0?a=n.length-1:a=e4.lastIndex-2,p=["word",n.slice(v,a+1),v,a],y.push(p),v=a);break}}return v++,p}}function P(x){m.push(x)}return{back:P,endOfFile:_,nextToken:C,position:b}},dDe=HD,V5=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="atrule",r}var i=e.prototype;return i.append=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.append).call.apply(s,[].concat([this],o))},i.prepend=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];var s;return this.proxyOf.nodes||(this.nodes=[]),(s=t.prototype.prepend).call.apply(s,[].concat([this],o))},e})(dDe),tee=V5;V5.default=V5;dDe.registerAtRule(V5);var fDe=HD,hDe,pDe,Ak=(function(t){Ks(e,t);function e(n){var r;return r=t.call(this,n)||this,r.type="root",r.nodes||(r.nodes=[]),r}var i=e.prototype;return i.normalize=function(r,o,a){var s=t.prototype.normalize.call(this,r);if(o){if(a==="prepend")this.nodes.length>1?o.raws.before=this.nodes[1].raws.before:delete o.raws.before;else if(this.first!==o)for(var l=Ur(s),u;!(u=l()).done;){var c=u.value;c.raws.before=o.raws.before}}return s},i.removeChild=function(r,o){var a=this.index(r);return!o&&a===0&&this.nodes.length>1&&(this.nodes[1].raws.before=this.nodes[a].raws.before),t.prototype.removeChild.call(this,r)},i.toResult=function(r){r===void 0&&(r={});var o=new hDe(new pDe,this,r);return o.stringify()},e})(fDe);Ak.registerLazyResult=function(t){hDe=t};Ak.registerProcessor=function(t){pDe=t};var _V=Ak;Ak.default=Ak;fDe.registerRoot(Ak);var l3={comma:function(e){return l3.split(e,[","],!0)},space:function(e){var i=[" ",`
`,"	"];return l3.split(e,i)},split:function(e,i,n){for(var r=[],o="",a=!1,s=0,l=!1,u="",c=!1,d=Ur(e),f;!(f=d()).done;){var h=f.value;c?c=!1:h==="\\"?c=!0:l?h===u&&(l=!1):h==='"'||h==="'"?(l=!0,u=h):h==="("?s+=1:h===")"?s>0&&(s-=1):s===0&&i.includes(h)&&(a=!0),a?(o!==""&&r.push(o.trim()),o="",a=!1):o+=h}return(n||o!=="")&&r.push(o.trim()),r}},gDe=l3;l3.default=l3;var vDe=HD,Stt=gDe,H5=(function(t){Ks(e,t);function e(i){var n;return n=t.call(this,i)||this,n.type="rule",n.nodes||(n.nodes=[]),n}return Is(e,[{key:"selectors",get:function(){return Stt.comma(this.selector)},set:function(n){var r=this.selector?this.selector.match(/,\s*/):null,o=r?r[0]:","+this.raw("between","beforeOpen");this.selector=n.join(o)}}]),e})(vDe),ree=H5;H5.default=H5;vDe.registerRule(H5);var _tt=r6,Ptt=btt,Ctt=n6,Ttt=tee,xtt=_V,Cse=ree,Tse={empty:!0,space:!0};function Ett(t){for(var e=t.length-1;e>=0;e--){var i=t[e],n=i[3]||i[2];if(n)return n}}var wtt=(function(){function t(i){this.input=i,this.root=new xtt,this.current=this.root,this.spaces="",this.semicolon=!1,this.createTokenizer(),this.root.source={input:i,start:{column:1,line:1,offset:0}}}var e=t.prototype;return e.atrule=function(n){var r=new Ttt;r.name=n[1].slice(1),r.name===""&&this.unnamedAtrule(r,n),this.init(r,n[2]);for(var o,a,s,l=!1,u=!1,c=[],d=[];!this.tokenizer.endOfFile();){if(n=this.tokenizer.nextToken(),o=n[0],o==="("||o==="["?d.push(o==="("?")":"]"):o==="{"&&d.length>0?d.push("}"):o===d[d.length-1]&&d.pop(),d.length===0)if(o===";"){r.source.end=this.getPosition(n[2]),r.source.end.offset++,this.semicolon=!0;break}else if(o==="{"){u=!0;break}else if(o==="}"){if(c.length>0){for(s=c.length-1,a=c[s];a&&a[0]==="space";)a=c[--s];a&&(r.source.end=this.getPosition(a[3]||a[2]),r.source.end.offset++)}this.end(n);break}else c.push(n);else c.push(n);if(this.tokenizer.endOfFile()){l=!0;break}}r.raws.between=this.spacesAndCommentsFromEnd(c),c.length?(r.raws.afterName=this.spacesAndCommentsFromStart(c),this.raw(r,"params",c),l&&(n=c[c.length-1],r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++,this.spaces=r.raws.between,r.raws.between="")):(r.raws.afterName="",r.params=""),u&&(r.nodes=[],this.current=r)},e.checkMissedSemicolon=function(n){var r=this.colon(n);if(r!==!1){for(var o=0,a,s=r-1;s>=0&&(a=n[s],!(a[0]!=="space"&&(o+=1,o===2)));s--);throw this.input.error("Missed semicolon",a[0]==="word"?a[3]+1:a[2])}},e.colon=function(n){for(var r=0,o,a,s,l=Ur(n.entries()),u;!(u=l()).done;){var c=u.value,d=c[0],f=c[1];if(o=f,a=o[0],a==="("&&(r+=1),a===")"&&(r-=1),r===0&&a===":")if(!s)this.doubleColon(o);else{if(s[0]==="word"&&s[1]==="progid")continue;return d}s=o}return!1},e.comment=function(n){var r=new Ctt;this.init(r,n[2]),r.source.end=this.getPosition(n[3]||n[2]),r.source.end.offset++;var o=n[1].slice(2,-2);if(/^\s*$/.test(o))r.text="",r.raws.left=o,r.raws.right="";else{var a=o.match(/^(\s*)([^]*\S)(\s*)$/);r.text=a[2],r.raws.left=a[1],r.raws.right=a[3]}},e.createTokenizer=function(){this.tokenizer=Ptt(this.input)},e.decl=function(n,r){var o=new _tt;this.init(o,n[0][2]);var a=n[n.length-1];for(a[0]===";"&&(this.semicolon=!0,n.pop()),o.source.end=this.getPosition(a[3]||a[2]||Ett(n)),o.source.end.offset++;n[0][0]!=="word";)n.length===1&&this.unknownWord(n),o.raws.before+=n.shift()[1];for(o.source.start=this.getPosition(n[0][2]),o.prop="";n.length;){var s=n[0][0];if(s===":"||s==="space"||s==="comment")break;o.prop+=n.shift()[1]}o.raws.between="";for(var l;n.length;)if(l=n.shift(),l[0]===":"){o.raws.between+=l[1];break}else l[0]==="word"&&/\w/.test(l[1])&&this.unknownWord([l]),o.raws.between+=l[1];(o.prop[0]==="_"||o.prop[0]==="*")&&(o.raws.before+=o.prop[0],o.prop=o.prop.slice(1));for(var u=[],c;n.length&&(c=n[0][0],!(c!=="space"&&c!=="comment"));)u.push(n.shift());this.precheckMissedSemicolon(n);for(var d=n.length-1;d>=0;d--){if(l=n[d],l[1].toLowerCase()==="!important"){o.important=!0;var f=this.stringFrom(n,d);f=this.spacesFromEnd(n)+f,f!==" !important"&&(o.raws.important=f);break}else if(l[1].toLowerCase()==="important"){for(var h=n.slice(0),p="",g=d;g>0;g--){var v=h[g][0];if(p.trim().indexOf("!")===0&&v!=="space")break;p=h.pop()[1]+p}p.trim().indexOf("!")===0&&(o.important=!0,o.raws.important=p,n=h)}if(l[0]!=="space"&&l[0]!=="comment")break}var y=n.some(function(m){return m[0]!=="space"&&m[0]!=="comment"});y&&(o.raws.between+=u.map(function(m){return m[1]}).join(""),u=[]),this.raw(o,"value",u.concat(n),r),o.value.includes(":")&&!r&&this.checkMissedSemicolon(n)},e.doubleColon=function(n){throw this.input.error("Double colon",{offset:n[2]},{offset:n[2]+n[1].length})},e.emptyRule=function(n){var r=new Cse;this.init(r,n[2]),r.selector="",r.raws.between="",this.current=r},e.end=function(n){this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.semicolon=!1,this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.spaces="",this.current.parent?(this.current.source.end=this.getPosition(n[2]),this.current.source.end.offset++,this.current=this.current.parent):this.unexpectedClose(n)},e.endFile=function(){this.current.parent&&this.unclosedBlock(),this.current.nodes&&this.current.nodes.length&&(this.current.raws.semicolon=this.semicolon),this.current.raws.after=(this.current.raws.after||"")+this.spaces,this.root.source.end=this.getPosition(this.tokenizer.position())},e.freeSemicolon=function(n){if(this.spaces+=n[1],this.current.nodes){var r=this.current.nodes[this.current.nodes.length-1];r&&r.type==="rule"&&!r.raws.ownSemicolon&&(r.raws.ownSemicolon=this.spaces,this.spaces="")}},e.getPosition=function(n){var r=this.input.fromOffset(n);return{column:r.col,line:r.line,offset:n}},e.init=function(n,r){this.current.push(n),n.source={input:this.input,start:this.getPosition(r)},n.raws.before=this.spaces,this.spaces="",n.type!=="comment"&&(this.semicolon=!1)},e.other=function(n){for(var r=!1,o=null,a=!1,s=null,l=[],u=n[1].startsWith("--"),c=[],d=n;d;){if(o=d[0],c.push(d),o==="("||o==="[")s||(s=d),l.push(o==="("?")":"]");else if(u&&a&&o==="{")s||(s=d),l.push("}");else if(l.length===0)if(o===";")if(a){this.decl(c,u);return}else break;else if(o==="{"){this.rule(c);return}else if(o==="}"){this.tokenizer.back(c.pop()),r=!0;break}else o===":"&&(a=!0);else o===l[l.length-1]&&(l.pop(),l.length===0&&(s=null));d=this.tokenizer.nextToken()}if(this.tokenizer.endOfFile()&&(r=!0),l.length>0&&this.unclosedBracket(s),r&&a){if(!u)for(;c.length&&(d=c[c.length-1][0],!(d!=="space"&&d!=="comment"));)this.tokenizer.back(c.pop());this.decl(c,u)}else this.unknownWord(c)},e.parse=function(){for(var n;!this.tokenizer.endOfFile();)switch(n=this.tokenizer.nextToken(),n[0]){case"space":this.spaces+=n[1];break;case";":this.freeSemicolon(n);break;case"}":this.end(n);break;case"comment":this.comment(n);break;case"at-word":this.atrule(n);break;case"{":this.emptyRule(n);break;default:this.other(n);break}this.endFile()},e.precheckMissedSemicolon=function(){},e.raw=function(n,r,o,a){for(var s,l,u=o.length,c="",d=!0,f,h,p=0;p<u;p+=1)s=o[p],l=s[0],l==="space"&&p===u-1&&!a?d=!1:l==="comment"?(h=o[p-1]?o[p-1][0]:"empty",f=o[p+1]?o[p+1][0]:"empty",!Tse[h]&&!Tse[f]?c.slice(-1)===","?d=!1:c+=s[1]:d=!1):c+=s[1];if(!d){var g=o.reduce(function(v,y){return v+y[1]},"");n.raws[r]={raw:g,value:c}}n[r]=c},e.rule=function(n){n.pop();var r=new Cse;this.init(r,n[0][2]),r.raws.between=this.spacesAndCommentsFromEnd(n),this.raw(r,"selector",n),this.current=r},e.spacesAndCommentsFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],!(r!=="space"&&r!=="comment"));)o=n.pop()[1]+o;return o},e.spacesAndCommentsFromStart=function(n){for(var r,o="";n.length&&(r=n[0][0],!(r!=="space"&&r!=="comment"));)o+=n.shift()[1];return o},e.spacesFromEnd=function(n){for(var r,o="";n.length&&(r=n[n.length-1][0],r==="space");)o=n.pop()[1]+o;return o},e.stringFrom=function(n,r){for(var o="",a=r;a<n.length;a++)o+=n[a][1];return n.splice(r,n.length-r),o},e.unclosedBlock=function(){var n=this.current.source.start;throw this.input.error("Unclosed block",n.line,n.column)},e.unclosedBracket=function(n){throw this.input.error("Unclosed bracket",{offset:n[2]},{offset:n[2]+1})},e.unexpectedClose=function(n){throw this.input.error("Unexpected }",{offset:n[2]},{offset:n[2]+1})},e.unknownWord=function(n){throw this.input.error("Unknown word",{offset:n[0][2]},{offset:n[0][2]+n[0][1].length})},e.unnamedAtrule=function(n,r){throw this.input.error("At-rule without name",{offset:r[2]},{offset:r[2]+r[1].length})},t})(),Att=wtt,Ott=HD,Dtt=Att,Rtt=i6;function U5(t,e){var i=new Rtt(t,e),n=new Dtt(i);try{n.parse()}catch(r){throw r}return n.root}var iee=U5;U5.default=U5;Ott.registerParse(U5);var Ay=VP.isClean,Mtt=VP.my,Ltt=QOe,ktt=e6,Itt=HD,Ntt=QQ,xse=eee,Ftt=iee,Btt=_V,jtt={atrule:"AtRule",comment:"Comment",decl:"Declaration",document:"Document",root:"Root",rule:"Rule"},Vtt={AtRule:!0,AtRuleExit:!0,Comment:!0,CommentExit:!0,Declaration:!0,DeclarationExit:!0,Document:!0,DocumentExit:!0,Once:!0,OnceExit:!0,postcssPlugin:!0,prepare:!0,Root:!0,RootExit:!0,Rule:!0,RuleExit:!0},Htt={Once:!0,postcssPlugin:!0,prepare:!0},Ok=0;function K2(t){return(typeof t>"u"?"undefined":Ui(t))==="object"&&typeof t.then=="function"}function yDe(t){var e=!1,i=jtt[t.type];return t.type==="decl"?e=t.prop.toLowerCase():t.type==="atrule"&&(e=t.name.toLowerCase()),e&&t.append?[i,i+"-"+e,Ok,i+"Exit",i+"Exit-"+e]:e?[i,i+"-"+e,i+"Exit",i+"Exit-"+e]:t.append?[i,Ok,i+"Exit"]:[i,i+"Exit"]}function Ese(t){var e;return t.type==="document"?e=["Document",Ok,"DocumentExit"]:t.type==="root"?e=["Root",Ok,"RootExit"]:e=yDe(t),{eventIndex:0,events:e,iterator:0,node:t,visitorIndex:0,visitors:[]}}function IK(t){return t[Ay]=!1,t.nodes&&t.nodes.forEach(function(e){return IK(e)}),t}var NK={},Dk=(function(){function t(i,n,r){var o=this;this.stringified=!1,this.processed=!1;var a;if((typeof n>"u"?"undefined":Ui(n))==="object"&&n!==null&&(n.type==="root"||n.type==="document"))a=IK(n);else if(Ni(n,t)||Ni(n,xse))a=IK(n.root),n.map&&(typeof r.map>"u"&&(r.map={}),r.map.inline||(r.map.inline=!1),r.map.prev=n.map);else{var s=Ftt;r.syntax&&(s=r.syntax.parse),r.parser&&(s=r.parser),s.parse&&(s=s.parse);try{a=s(n,r)}catch(l){this.processed=!0,this.error=l}a&&!a[Mtt]&&Itt.rebuild(a)}this.result=new xse(i,a,r),this.helpers=Zn({},NK,{postcss:NK,result:this.result}),this.plugins=this.processor.plugins.map(function(l){return(typeof l>"u"?"undefined":Ui(l))==="object"&&l.prepare?Zn({},l,l.prepare(o.result)):l})}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):this.processed?Promise.resolve(this.result):(this.processing||(this.processing=this.runAsync()),this.processing)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.getAsyncError=function(){throw new Error("Use process(css).then(cb) to work with async plugins")},e.handleError=function(n,r){var o=this.result.lastPlugin;try{if(r&&r.addToError(n),this.error=n,n.name==="CssSyntaxError"&&!n.plugin)n.plugin=o.postcssPlugin,n.setMessage();else if(o.postcssVersion)var a,s,l,u,c}catch(d){console&&console.error&&console.error(d)}return n},e.prepareVisitors=function(){var n=this;this.listeners={};for(var r=function(c,d,f){n.listeners[d]||(n.listeners[d]=[]),n.listeners[d].push([c,f])},o=Ur(this.plugins),a;!(a=o()).done;){var s=a.value;if((typeof s>"u"?"undefined":Ui(s))==="object")for(var l in s){if(!Vtt[l]&&/^[A-Z]/.test(l))throw new Error("Unknown event "+l+" in "+s.postcssPlugin+". Try to update PostCSS ("+this.processor.version+" now).");if(!Htt[l])if(Ui(s[l])==="object")for(var u in s[l])u==="*"?r(s,l,s[l][u]):r(s,l+"-"+u.toLowerCase(),s[l][u]);else typeof s[l]=="function"&&r(s,l,s[l])}}this.hasListener=Object.keys(this.listeners).length>0},e.runAsync=function(){var n=this;return U$(function(){var r,o,a,s,l,u,c,d,f,h,p,g;return CD(this,function(v){switch(v.label){case 0:n.plugin=0,r=0,v.label=1;case 1:if(!(r<n.plugins.length))return[3,6];if(o=n.plugins[r],a=n.runOnRoot(o),!K2(a))return[3,5];v.label=2;case 2:return v.trys.push([2,4,,5]),[4,a];case 3:return v.sent(),[3,5];case 4:throw s=v.sent(),n.handleError(s);case 5:return r++,[3,1];case 6:if(n.prepareVisitors(),!n.hasListener)return[3,18];l=n.result.root,v.label=7;case 7:if(l[Ay])return[3,14];l[Ay]=!0,u=[Ese(l)],v.label=8;case 8:if(!(u.length>0))return[3,13];if(c=n.visitTick(u),!K2(c))return[3,12];v.label=9;case 9:return v.trys.push([9,11,,12]),[4,c];case 10:return v.sent(),[3,12];case 11:throw d=v.sent(),f=u[u.length-1].node,n.handleError(d,f);case 12:return[3,8];case 13:return[3,7];case 14:if(!n.listeners.OnceExit)return[3,18];h=function(){var y,m,b,S,_;return CD(this,function(C){switch(C.label){case 0:y=g.value,m=y[0],b=y[1],n.result.lastPlugin=m,C.label=1;case 1:return C.trys.push([1,6,,7]),l.type!=="document"?[3,3]:(S=l.nodes.map(function(P){return b(P,n.helpers)}),[4,Promise.all(S)]);case 2:return C.sent(),[3,5];case 3:return[4,b(l,n.helpers)];case 4:C.sent(),C.label=5;case 5:return[3,7];case 6:throw _=C.sent(),n.handleError(_);case 7:return[2]}})},p=Ur(n.listeners.OnceExit),v.label=15;case 15:return(g=p()).done?[3,18]:[5,TQ(h())];case 16:v.sent(),v.label=17;case 17:return[3,15];case 18:return n.processed=!0,[2,n.stringify()]}})})()},e.runOnRoot=function(n){var r=this;this.result.lastPlugin=n;try{if((typeof n>"u"?"undefined":Ui(n))==="object"&&n.Once){if(this.result.root.type==="document"){var o=this.result.root.nodes.map(function(a){return n.Once(a,r.helpers)});return K2(o[0])?Promise.all(o):o}return n.Once(this.result.root,this.helpers)}else if(typeof n=="function")return n(this.result.root,this.result)}catch(a){throw this.handleError(a)}},e.stringify=function(){if(this.error)throw this.error;if(this.stringified)return this.result;this.stringified=!0,this.sync();var n=this.result.opts,r=ktt;n.syntax&&(r=n.syntax.stringify),n.stringifier&&(r=n.stringifier),r.stringify&&(r=r.stringify);var o=new Ltt(r,this.result.root,this.result.opts),a=o.generate();return this.result.css=a[0],this.result.map=a[1],this.result},e.sync=function(){if(this.error)throw this.error;if(this.processed)return this.result;if(this.processed=!0,this.processing)throw this.getAsyncError();for(var n=Ur(this.plugins),r;!(r=n()).done;){var o=r.value,a=this.runOnRoot(o);if(K2(a))throw this.getAsyncError()}if(this.prepareVisitors(),this.hasListener){for(var s=this.result.root;!s[Ay];)s[Ay]=!0,this.walkSync(s);if(this.listeners.OnceExit)if(s.type==="document")for(var l=Ur(s.nodes),u;!(u=l()).done;){var c=u.value;this.visitSync(this.listeners.OnceExit,c)}else this.visitSync(this.listeners.OnceExit,s)}return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this.css},e.visitSync=function(n,r){for(var o=Ur(n),a;!(a=o()).done;){var s=a.value,l=s[0],u=s[1];this.result.lastPlugin=l;var c=void 0;try{c=u(r,this.helpers)}catch(d){throw this.handleError(d,r.proxyOf)}if(r.type!=="root"&&r.type!=="document"&&!r.parent)return!0;if(K2(c))throw this.getAsyncError()}},e.visitTick=function(n){var r=n[n.length-1],o=r.node,a=r.visitors;if(o.type!=="root"&&o.type!=="document"&&!o.parent){n.pop();return}if(a.length>0&&r.visitorIndex<a.length){var s=a[r.visitorIndex],l=s[0],u=s[1];r.visitorIndex+=1,r.visitorIndex===a.length&&(r.visitors=[],r.visitorIndex=0),this.result.lastPlugin=l;try{return u(o.toProxy(),this.helpers)}catch(p){throw this.handleError(p,o)}}if(r.iterator!==0){for(var c=r.iterator,d;d=o.nodes[o.indexes[c]];)if(o.indexes[c]+=1,!d[Ay]){d[Ay]=!0,n.push(Ese(d));return}r.iterator=0,delete o.indexes[c]}for(var f=r.events;r.eventIndex<f.length;){var h=f[r.eventIndex];if(r.eventIndex+=1,h===Ok){o.nodes&&o.nodes.length&&(o[Ay]=!0,r.iterator=o.getIterator());return}else if(this.listeners[h]){r.visitors=this.listeners[h];return}}n.pop()},e.walkSync=function(n){var r=this;n[Ay]=!0;for(var o=yDe(n),a=Ur(o),s;!(s=a()).done;){var l=s.value;if(l===Ok)n.nodes&&n.each(function(c){c[Ay]||r.walkSync(c)});else{var u=this.listeners[l];if(u&&this.visitSync(u,n.toProxy()))return}}},e.warnings=function(){return this.sync().warnings()},Is(t,[{key:"content",get:function(){return this.stringify().content}},{key:"css",get:function(){return this.stringify().css}},{key:"map",get:function(){return this.stringify().map}},{key:"messages",get:function(){return this.sync().messages}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){return this.sync().root}},{key:Symbol.toStringTag,get:function(){return"LazyResult"}}]),t})();Dk.registerPostcss=function(t){NK=t};var mDe=Dk;Dk.default=Dk;Btt.registerLazyResult(Dk);Ntt.registerLazyResult(Dk);var Utt=QOe,ztt=e6,$tt=iee,Wtt=eee,FK=(function(){function t(i,n,r){n=n.toString(),this.stringified=!1,this._processor=i,this._css=n,this._opts=r,this._map=void 0;var o,a=ztt;this.result=new Wtt(this._processor,o,this._opts),this.result.css=n;var s=this;Object.defineProperty(this.result,"root",{get:function(){return s.root}});var l=new Utt(a,o,this._opts,n);if(l.isMap()){var u=l.generate(),c=u[0],d=u[1];c&&(this.result.css=c),d&&(this.result.map=d)}else l.clearAnnotation(),this.result.css=l.css}var e=t.prototype;return e.async=function(){return this.error?Promise.reject(this.error):Promise.resolve(this.result)},e.catch=function(n){return this.async().catch(n)},e.finally=function(n){return this.async().then(n,n)},e.sync=function(){if(this.error)throw this.error;return this.result},e.then=function(n,r){return this.async().then(n,r)},e.toString=function(){return this._css},e.warnings=function(){return[]},Is(t,[{key:"content",get:function(){return this.result.css}},{key:"css",get:function(){return this.result.css}},{key:"map",get:function(){return this.result.map}},{key:"messages",get:function(){return[]}},{key:"opts",get:function(){return this.result.opts}},{key:"processor",get:function(){return this.result.processor}},{key:"root",get:function(){if(this._root)return this._root;var n,r=$tt;try{n=r(this._css,this._opts)}catch(o){this.error=o}if(this.error)throw this.error;return this._root=n,n}},{key:Symbol.toStringTag,get:function(){return"NoWorkResult"}}]),t})(),Gtt=FK;FK.default=FK;var Ytt=Gtt,qtt=mDe,Xtt=QQ,Ktt=_V,u3=(function(){function t(i){i===void 0&&(i=[]),this.version="8.4.38",this.plugins=this.normalize(i)}var e=t.prototype;return e.normalize=function(n){for(var r=[],o=Ur(n),a;!(a=o()).done;){var s=a.value;if(s.postcss===!0?s=s():s.postcss&&(s=s.postcss),(typeof s>"u"?"undefined":Ui(s))==="object"&&Array.isArray(s.plugins))r=r.concat(s.plugins);else if((typeof s>"u"?"undefined":Ui(s))==="object"&&s.postcssPlugin)r.push(s);else if(typeof s=="function")r.push(s);else if(!((typeof s>"u"?"undefined":Ui(s))==="object"&&(s.parse||s.stringify)))throw new Error(s+" is not a PostCSS plugin")}return r},e.process=function(n,r){return r===void 0&&(r={}),!this.plugins.length&&!r.parser&&!r.stringifier&&!r.syntax?new Ytt(this,n,r):new qtt(this,n,r)},e.use=function(n){return this.plugins=this.plugins.concat(this.normalize([n])),this},t})(),Ztt=u3;u3.default=u3;Ktt.registerProcessor(u3);Xtt.registerProcessor(u3);var Jtt=r6,Qtt=qOe,ert=n6,trt=tee,rrt=i6,irt=_V,nrt=ree;function c3(t,e){if(Array.isArray(t))return t.map(function(d){return c3(d)});var i=t.inputs,n=PD(t,["inputs"]);if(i){e=[];for(var r=Ur(i),o;!(o=r()).done;){var a=o.value,s=Zn({},a,{__proto__:rrt.prototype});s.map&&(s.map=Zn({},s.map,{__proto__:Qtt.prototype})),e.push(s)}}if(n.nodes&&(n.nodes=t.nodes.map(function(d){return c3(d,e)})),n.source){var l=n.source,u=l.inputId,c=PD(l,["inputId"]);n.source=c,u!=null&&(n.source.input=e[u])}if(n.type==="root")return new irt(n);if(n.type==="decl")return new Jtt(n);if(n.type==="rule")return new nrt(n);if(n.type==="comment")return new ert(n);if(n.type==="atrule")return new trt(n);throw new Error("Unknown node type: "+t.type)}var ort=c3;c3.default=c3;var art=KQ,bDe=r6,srt=mDe,lrt=HD,nee=Ztt,urt=e6,crt=ort,SDe=QQ,drt=cDe,_De=n6,PDe=tee,frt=eee,hrt=i6,prt=iee,grt=gDe,CDe=ree,TDe=_V,vrt=t6;function Na(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return e.length===1&&Array.isArray(e[0])&&(e=e[0]),new nee(e)}Na.plugin=function(e,i){var n=!1;function r(){for(var a=arguments.length,s=new Array(a),l=0;l<a;l++)s[l]=arguments[l];console&&console.warn&&!n&&(n=!0,console.warn(e+`: postcss.plugin was deprecated. Migration guide:
https://evilmartians.com/chronicles/postcss-8-plugin-migration`),Sk.LANG&&Sk.LANG.startsWith("cn")&&console.warn(e+`: 里面 postcss.plugin 被弃用. 迁移指南:
https://www.w3ctech.com/topic/2226`));var u=i.apply(void 0,[].concat(s));return u.postcssPlugin=e,u.postcssVersion=new nee().version,u}var o;return Object.defineProperty(r,"postcss",{get:function(){return o||(o=r()),o}}),r.process=function(a,s,l){return Na([r(l)]).process(a,s)},r};Na.stringify=urt;Na.parse=prt;Na.fromJSON=crt;Na.list=grt;Na.comment=function(t){return new _De(t)};Na.atRule=function(t){return new PDe(t)};Na.decl=function(t){return new bDe(t)};Na.rule=function(t){return new CDe(t)};Na.root=function(t){return new TDe(t)};Na.document=function(t){return new SDe(t)};Na.CssSyntaxError=art;Na.Declaration=bDe;Na.Container=lrt;Na.Processor=nee;Na.Document=SDe;Na.Comment=_De;Na.Warning=drt;Na.AtRule=PDe;Na.Result=frt;Na.Input=hrt;Na.Rule=CDe;Na.Root=TDe;Na.Node=vrt;srt.registerPostcss(Na);var yrt=Na;Na.default=Na;var Qs=Det(yrt);Qs.stringify;Qs.fromJSON;Qs.plugin;Qs.parse;Qs.list;Qs.document;Qs.comment;Qs.atRule;Qs.rule;Qs.decl;Qs.root;Qs.CssSyntaxError;Qs.Declaration;Qs.Container;Qs.Processor;Qs.Document;Qs.Comment;Qs.Warning;Qs.AtRule;Qs.Result;Qs.Input;Qs.Rule;Qs.Root;Qs.Node;var mrt=Object.defineProperty,brt=function(t,e,i){return e in t?mrt(t,e,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[e]=i},t4=function(t,e,i){return brt(t,(typeof e>"u"?"undefined":Ui(e))!=="symbol"?e+"":e,i)};function Srt(t,e,i){try{if(!(e in t))return function(){};var n=t[e],r=i(n);return typeof r=="function"&&(r.prototype=r.prototype||{},Object.defineProperties(r,{__rrweb_original__:{enumerable:!1,value:n}})),t[e]=r,function(){t[e]=n}}catch{return function(){}}}var UM=(function(){function t(i){t4(this,"fileName"),t4(this,"functionName"),t4(this,"lineNumber"),t4(this,"columnNumber"),this.fileName=i.fileName||"",this.functionName=i.functionName||"",this.lineNumber=i.lineNumber,this.columnNumber=i.columnNumber}var e=t.prototype;return e.toString=function(){var n=this.lineNumber||"",r=this.columnNumber||"";return this.functionName?this.functionName+" ("+this.fileName+":"+n+":"+r+")":this.fileName+":"+n+":"+r},t})(),_rt=/(^|@)\S+:\d+/,wse=/^\s*at .*(\S+:\d+|\(native\))/m,Prt=/^(eval@)?(\[native code])?$/,C8={parse:function(e){return e?typeof e.stacktrace<"u"||typeof e["opera#sourceloc"]<"u"?this.parseOpera(e):e.stack&&e.stack.match(wse)?this.parseV8OrIE(e):e.stack?this.parseFFOrSafari(e):(console.warn("[console-record-plugin]: Failed to parse error object:",e),[]):[]},extractLocation:function(e){if(e.indexOf(":")===-1)return[e];var i=/(.+?)(?::(\d+))?(?::(\d+))?$/,n=i.exec(e.replace(/[()]/g,""));if(!n)throw new Error("Cannot parse given url: "+e);return[n[1],n[2]||void 0,n[3]||void 0]},parseV8OrIE:function(e){var i=e.stack.split(`
`).filter(function(n){return!!n.match(wse)},this);return i.map(function(n){n.indexOf("(eval ")>-1&&(n=n.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(\),.*$)/g,""));var r=n.replace(/^\s+/,"").replace(/\(eval code/g,"("),o=r.match(/ (\((.+):(\d+):(\d+)\)$)/);r=o?r.replace(o[0],""):r;var a=r.split(/\s+/).slice(1),s=this.extractLocation(o?o[1]:a.pop()),l=a.join(" ")||void 0,u=["eval","<anonymous>"].indexOf(s[0])>-1?void 0:s[0];return new UM({functionName:l,fileName:u,lineNumber:s[1],columnNumber:s[2]})},this)},parseFFOrSafari:function(e){var i=e.stack.split(`
`).filter(function(n){return!n.match(Prt)},this);return i.map(function(n){if(n.indexOf(" > eval")>-1&&(n=n.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),n.indexOf("@")===-1&&n.indexOf(":")===-1)return new UM({functionName:n});var r=/((.*".+"[^@]*)?[^@]*)(?:@)/,o=n.match(r),a=o&&o[1]?o[1]:void 0,s=this.extractLocation(n.replace(r,""));return new UM({functionName:a,fileName:s[0],lineNumber:s[1],columnNumber:s[2]})},this)},parseOpera:function(e){return!e.stacktrace||e.message.indexOf(`
`)>-1&&e.message.split(`
`).length>e.stacktrace.split(`
`).length?this.parseOpera9(e):e.stack?this.parseOpera11(e):this.parseOpera10(e)},parseOpera9:function(e){for(var i=/Line (\d+).*script (?:in )?(\S+)/i,n=e.message.split(`
`),r=[],o=2,a=n.length;o<a;o+=2){var s=i.exec(n[o]);s&&r.push(new UM({fileName:s[2],lineNumber:parseFloat(s[1])}))}return r},parseOpera10:function(e){for(var i=/Line (\d+).*script (?:in )?(\S+)(?:: In function (\S+))?$/i,n=e.stacktrace.split(`
`),r=[],o=0,a=n.length;o<a;o+=2){var s=i.exec(n[o]);s&&r.push(new UM({functionName:s[3]||void 0,fileName:s[2],lineNumber:parseFloat(s[1])}))}return r},parseOpera11:function(e){var i=e.stack.split(`
`).filter(function(n){return!!n.match(_rt)&&!n.match(/^Error created at/)},this);return i.map(function(n){var r=n.split("@"),o=this.extractLocation(r.pop()),a=r.shift()||"",s=a.replace(/<anonymous function(: (\w+))?>/,"$2").replace(/\([^)]*\)/g,"")||void 0;return new UM({functionName:s,fileName:o[0],lineNumber:o[1],columnNumber:o[2]})},this)}};function Crt(t){if(!t||!t.outerHTML)return"";for(var e="";t.parentElement;){var i=t.localName;if(!i)break;i=i.toLowerCase();var n=t.parentElement,r=[];if(n.children&&n.children.length>0)for(var o=0;o<n.children.length;o++){var a=n.children[o];a.localName&&a.localName.toLowerCase&&a.localName.toLowerCase()===i&&r.push(a)}r.length>1&&(i+=":eq("+r.indexOf(t)+")"),e=i+(e?">"+e:""),t=n}return e}function BK(t){return Object.prototype.toString.call(t)==="[object Object]"}function xDe(t,e){if(e===0)return!0;for(var i=Object.keys(t),n=Ur(i),r;!(r=n()).done;){var o=r.value;if(BK(t[o])&&xDe(t[o],e-1))return!0}return!1}function zM(t,e){var i={numOfKeysLimit:50,depthOfLimit:4};Object.assign(i,e);var n=[],r=[];return JSON.stringify(t,function(s,l){if(n.length>0){var u=n.indexOf(this);~u?n.splice(u+1):n.push(this),~u?r.splice(u,1/0,s):r.push(s),~n.indexOf(l)&&(n[0]===l?l="[Circular ~]":l="[Circular ~."+r.slice(0,n.indexOf(l)).join(".")+"]")}else n.push(l);if(l===null)return l;if(l===void 0)return"undefined";if(o(l))return a(l);if((typeof l>"u"?"undefined":Ui(l))==="bigint")return l.toString()+"n";if(Ni(l,Event)){var c={};for(var d in l){var f=l[d];Array.isArray(f)?c[d]=Crt(f.length?f[0]:null):c[d]=f}return c}else{if(Ni(l,Node))return Ni(l,HTMLElement)?l?l.outerHTML:"":l.nodeName;if(Ni(l,Error))return l.stack?l.stack+`
End of stack for Error object`:l.name+": "+l.message}return l});function o(s){return!!(BK(s)&&Object.keys(s).length>i.numOfKeysLimit||typeof s=="function"||BK(s)&&xDe(s,i.depthOfLimit))}function a(s){var l=s.toString();return i.stringLengthLimit&&l.length>i.stringLengthLimit&&(l=""+l.slice(0,i.stringLengthLimit)+"..."),l}}var Ase={level:["assert","clear","count","countReset","debug","dir","dirxml","error","group","groupCollapsed","groupEnd","info","log","table","time","timeEnd","timeLog","trace","warn"],lengthThreshold:1e3,logger:"console"};function Trt(t,e,i){var n=i?Object.assign({},Ase,i):Ase,r=n.logger;if(!r)return function(){};var o;typeof r=="string"?o=e[r]:o=r;var a=0,s=!1,l=[];if(n.level.includes("error")){var u=function(g){var v=g.message,y=g.error,m=C8.parse(y).map(function(S){return S.toString()}),b=[zM(v,n.stringifyOptions)];t({level:"error",trace:m,payload:b})};e.addEventListener("error",u),l.push(function(){e.removeEventListener("error",u)});var c=function(g){var v,y;Ni(g.reason,Error)?(v=g.reason,y=[zM("Uncaught (in promise) "+v.name+": "+v.message,n.stringifyOptions)]):(v=new Error,y=[zM("Uncaught (in promise)",n.stringifyOptions),zM(g.reason,n.stringifyOptions)]);var m=C8.parse(v).map(function(b){return b.toString()});t({level:"error",trace:m,payload:y})};e.addEventListener("unhandledrejection",c),l.push(function(){e.removeEventListener("unhandledrejection",c)})}for(var d=Ur(n.level),f;!(f=d()).done;){var h=f.value;l.push(p(o,h))}return function(){l.forEach(function(g){return g()})};function p(g,v){var y=this;return g[v]?Srt(g,v,function(m){var b=y;return function(){for(var S=arguments.length,_=new Array(S),C=0;C<S;C++)_[C]=arguments[C];if(m.apply(b,_),!(v==="assert"&&_[0])&&!s){s=!0;try{var P=C8.parse(new Error).map(function(A){return A.toString()}).splice(1),x=v==="assert"?_.slice(1):_,E=x.map(function(A){return zM(A,n.stringifyOptions)});a++,a<n.lengthThreshold?t({level:v,trace:P,payload:E}):a===n.lengthThreshold&&t({level:"warn",trace:[],payload:[zM("The number of log records reached the threshold.")]})}catch(A){m.apply(void 0,[].concat(["rrweb logger error:",A],_))}finally{s=!1}}}}):function(){}}}var xrt="rrweb/console@1",Ert=function(t){return{name:xrt,observer:Trt,options:t}},Ose=kr.setImmediate,_P,jK,VK,EDe=Object.prototype.toString,wrt=typeof Ose<"u"?function(e){return Ose(e)}:setTimeout;try{Object.defineProperty({},"x",{}),_P=function(e,i,n,r){return Object.defineProperty(e,i,{value:n,writable:!0,configurable:r!==!1})}}catch{_P=function(i,n,r){return i[n]=r,i}}VK=(function(){var e,i,n;function r(o,a){this.fn=o,this.self=a,this.next=void 0}return{add:function(a,s){n=new r(a,s),i?i.next=n:e=n,i=n,n=void 0},drain:function(){var a=e;for(e=i=jK=void 0;a;)a.fn.call(a.self),a=a.next}}})();function z5(t,e){VK.add(t,e),jK||(jK=wrt(VK.drain))}function wDe(t){var e,i=typeof t;return t!==null&&(i==="object"||i==="function")&&(e=t.then),typeof e=="function"?e:!1}function oee(){for(var t=0;t<this.chain.length;t++)Art(this,this.state===1?this.chain[t].success:this.chain[t].failure,this.chain[t]);this.chain.length=0}function Art(t,e,i){var n,r;try{e===!1?i.reject(t.msg):(e===!0?n=t.msg:n=e.call(void 0,t.msg),n===i.promise?i.reject(TypeError("Promise-chain cycle")):(r=wDe(n))?r.call(n,i.resolve,i.reject):i.resolve(n))}catch(o){i.reject(o)}}function ADe(t){var e,i=this;if(!i.triggered){i.triggered=!0,i.def&&(i=i.def);try{(e=wDe(t))?z5(function(){var n=new Dse(i);try{e.call(t,function(){ADe.apply(n,arguments)},function(){_j.apply(n,arguments)})}catch(r){_j.call(n,r)}}):(i.msg=t,i.state=1,i.chain.length>0&&z5(oee,i))}catch(n){_j.call(new Dse(i),n)}}}function _j(t){var e=this;e.triggered||(e.triggered=!0,e.def&&(e=e.def),e.msg=t,e.state=2,e.chain.length>0&&z5(oee,e))}function ODe(t,e,i,n){for(var r=0;r<e.length;r++)(function(a){t.resolve(e[a]).then(function(l){i(a,l)},n)})(r)}function Dse(t){this.def=t,this.triggered=!1}function Ort(t){this.promise=t,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function HP(t){if(typeof t!="function")throw TypeError("Not a function");if(this.__NPO__!==0)throw TypeError("Not a promise");this.__NPO__=1;var e=new Ort(this);this.then=function(n,r){var o={success:typeof n=="function"?n:!0,failure:typeof r=="function"?r:!1};return o.promise=new this.constructor(function(s,l){if(typeof s!="function"||typeof l!="function")throw TypeError("Not a function");o.resolve=s,o.reject=l}),e.chain.push(o),e.state!==0&&z5(oee,e),o.promise},this.catch=function(n){return this.then(void 0,n)};try{t.call(void 0,function(n){ADe.call(e,n)},function(n){_j.call(e,n)})}catch(i){_j.call(e,i)}}var DDe=_P({},"constructor",HP,!1);HP.prototype=DDe;_P(DDe,"__NPO__",0,!1);_P(HP,"resolve",function(e){var i=this;return e&&typeof e=="object"&&e.__NPO__===1?e:new i(function(r,o){if(typeof r!="function"||typeof o!="function")throw TypeError("Not a function");r(e)})});_P(HP,"reject",function(e){return new this(function(n,r){if(typeof n!="function"||typeof r!="function")throw TypeError("Not a function");r(e)})});_P(HP,"all",function(e){var i=this;return EDe.call(e)!=="[object Array]"?i.reject(TypeError("Not an array")):e.length===0?i.resolve([]):new i(function(r,o){if(typeof r!="function"||typeof o!="function")throw TypeError("Not a function");var a=e.length,s=Array(a),l=0;ODe(i,e,function(c,d){s[c]=d,++l===a&&r(s)},o)})});_P(HP,"race",function(e){var i=this;return EDe.call(e)!=="[object Array]"?i.reject(TypeError("Not an array")):new i(function(r,o){if(typeof r!="function"||typeof o!="function")throw TypeError("Not a function");ODe(i,e,function(s,l){r(l)},o)})});var Hn;typeof Promise<"u"&&Promise.toString().indexOf("[native code]")!==-1?Hn=Promise:Hn=HP;var Pj=1440*60*1e3,T8=8*1e3,o6=Array.prototype,Drt=Function.prototype,RDe=Object.prototype,aP=o6.slice,PV=RDe.toString,a6=RDe.hasOwnProperty,wu=kr.console,cS=kr.navigator,Dn=kr.document,nj=kr.opera,Rse=kr.screen,By=cS.userAgent,x8=Drt.bind,Mse=o6.forEach,Lse=o6.indexOf,kse=o6.map,Rrt=Array.isArray,HK={},Ve={trim:function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},Bn={log:function(){if(Dh.DEBUG&&!Ve.isUndefined(wu)&&wu)try{wu.log.apply(wu,arguments)}catch{Ve.each(arguments,function(e){wu.log(e)})}},warn:function(){if(Dh.DEBUG&&!Ve.isUndefined(wu)&&wu){var t=["Mixpanel warning:"].concat(Ve.toArray(arguments));try{wu.warn.apply(wu,t)}catch{Ve.each(t,function(i){wu.warn(i)})}}},error:function(){if(Dh.DEBUG&&!Ve.isUndefined(wu)&&wu){var t=["Mixpanel error:"].concat(Ve.toArray(arguments));try{wu.error.apply(wu,t)}catch{Ve.each(t,function(i){wu.error(i)})}}},critical:function(){if(!Ve.isUndefined(wu)&&wu){var t=["Mixpanel error:"].concat(Ve.toArray(arguments));try{wu.error.apply(wu,t)}catch{Ve.each(t,function(i){wu.error(i)})}}}},E8=function(t,e){return function(){return arguments[0]="["+e+"] "+arguments[0],t.apply(Bn,arguments)}},UP=function(t){return{log:E8(Bn.log,t),error:E8(Bn.error,t),critical:E8(Bn.critical,t)}},Rk=function(t){return function(){try{return t.apply(this,arguments)}catch(e){Bn.critical("Implementation error. Please turn on debug and contact support@mixpanel.com."),Dh.DEBUG&&Bn.critical(e)}}},aee=function(t){var e=t.prototype;for(var i in e)typeof e[i]=="function"&&(e[i]=Rk(e[i]))};Ve.bind=function(t,e){var i,n;if(x8&&t.bind===x8)return x8.apply(t,aP.call(arguments,1));if(!Ve.isFunction(t))throw new TypeError;return i=aP.call(arguments,2),n=function(){if(!(this instanceof n))return t.apply(e,i.concat(aP.call(arguments)));var r={};r.prototype=t.prototype;var o=new r;r.prototype=null;var a=t.apply(o,i.concat(aP.call(arguments)));return Object(a)===a?a:o},n};Ve.each=function(t,e,i){if(t!=null){if(Mse&&t.forEach===Mse)t.forEach(e,i);else if(t.length===+t.length){for(var n=0,r=t.length;n<r;n++)if(n in t&&e.call(i,t[n],n,t)===HK)return}else for(var o in t)if(a6.call(t,o)&&e.call(i,t[o],o,t)===HK)return}};Ve.extend=function(t){return Ve.each(aP.call(arguments,1),function(e){for(var i in e)e[i]!==void 0&&(t[i]=e[i])}),t};Ve.isArray=Rrt||function(t){return PV.call(t)==="[object Array]"};Ve.isFunction=function(t){return typeof t=="function"};Ve.isArguments=function(t){return!!(t&&a6.call(t,"callee"))};Ve.toArray=function(t){return t?t.toArray?t.toArray():Ve.isArray(t)||Ve.isArguments(t)?aP.call(t):Ve.values(t):[]};Ve.map=function(t,e,i){if(kse&&t.map===kse)return t.map(e,i);var n=[];return Ve.each(t,function(r){n.push(e.call(i,r))}),n};Ve.keys=function(t){var e=[];return t===null||Ve.each(t,function(i,n){e[e.length]=n}),e};Ve.values=function(t){var e=[];return t===null||Ve.each(t,function(i){e[e.length]=i}),e};Ve.include=function(t,e){var i=!1;return t===null?i:Lse&&t.indexOf===Lse?t.indexOf(e)!=-1:(Ve.each(t,function(n){if(i||(i=n===e))return HK}),i)};Ve.includes=function(t,e){return t.indexOf(e)!==-1};Ve.inherit=function(t,e){return t.prototype=new e,t.prototype.constructor=t,t.superclass=e.prototype,t};Ve.isObject=function(t){return t===Object(t)&&!Ve.isArray(t)};Ve.isEmptyObject=function(t){if(Ve.isObject(t)){for(var e in t)if(a6.call(t,e))return!1;return!0}return!1};Ve.isUndefined=function(t){return t===void 0};Ve.isString=function(t){return PV.call(t)=="[object String]"};Ve.isDate=function(t){return PV.call(t)=="[object Date]"};Ve.isNumber=function(t){return PV.call(t)=="[object Number]"};Ve.isElement=function(t){return!!(t&&t.nodeType===1)};Ve.encodeDates=function(t){return Ve.each(t,function(e,i){Ve.isDate(e)?t[i]=Ve.formatDate(e):Ve.isObject(e)&&(t[i]=Ve.encodeDates(e))}),t};Ve.timestamp=function(){return Date.now=Date.now||function(){return+new Date},Date.now()};Ve.formatDate=function(t){function e(i){return i<10?"0"+i:i}return t.getUTCFullYear()+"-"+e(t.getUTCMonth()+1)+"-"+e(t.getUTCDate())+"T"+e(t.getUTCHours())+":"+e(t.getUTCMinutes())+":"+e(t.getUTCSeconds())};Ve.strip_empty_properties=function(t){var e={};return Ve.each(t,function(i,n){Ve.isString(i)&&i.length>0&&(e[n]=i)}),e};Ve.truncate=function(t,e){var i;return typeof t=="string"?i=t.slice(0,e):Ve.isArray(t)?(i=[],Ve.each(t,function(n){i.push(Ve.truncate(n,e))})):Ve.isObject(t)?(i={},Ve.each(t,function(n,r){i[r]=Ve.truncate(n,e)})):i=t,i};Ve.JSONEncode=(function(){return function(t){var e=t,i=function(r){var o=/[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,a={"\b":"\\b","	":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};return o.lastIndex=0,o.test(r)?'"'+r.replace(o,function(s){var l=a[s];return typeof l=="string"?l:"\\u"+("0000"+s.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+r+'"'},n=function(r,o){var a="",s="    ",l=0,u="",c="",d=0,f=a,h=[],p=o[r];switch(p&&typeof p=="object"&&typeof p.toJSON=="function"&&(p=p.toJSON(r)),typeof p){case"string":return i(p);case"number":return isFinite(p)?String(p):"null";case"boolean":case"null":return String(p);case"object":if(!p)return"null";if(a+=s,h=[],PV.apply(p)==="[object Array]"){for(d=p.length,l=0;l<d;l+=1)h[l]=n(l,p)||"null";return c=h.length===0?"[]":a?`[
`+a+h.join(`,
`+a)+`
`+f+"]":"["+h.join(",")+"]",a=f,c}for(u in p)a6.call(p,u)&&(c=n(u,p),c&&h.push(i(u)+(a?": ":":")+c));return c=h.length===0?"{}":a?"{"+h.join(",")+f+"}":"{"+h.join(",")+"}",a=f,c}};return n("",{"":e})}})();Ve.JSONDecode=(function(){var t,e,i={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:`
`,r:"\r",t:"	"},n,r=function(h){var p=new SyntaxError(h);throw p.at=t,p.text=n,p},o=function(h){return h&&h!==e&&r("Expected '"+h+"' instead of '"+e+"'"),e=n.charAt(t),t+=1,e},a=function(){var h,p="";for(e==="-"&&(p="-",o("-"));e>="0"&&e<="9";)p+=e,o();if(e===".")for(p+=".";o()&&e>="0"&&e<="9";)p+=e;if(e==="e"||e==="E")for(p+=e,o(),(e==="-"||e==="+")&&(p+=e,o());e>="0"&&e<="9";)p+=e,o();if(h=+p,!isFinite(h))r("Bad number");else return h},s=function(){var h,p,g="",v;if(e==='"')for(;o();){if(e==='"')return o(),g;if(e==="\\")if(o(),e==="u"){for(v=0,p=0;p<4&&(h=parseInt(o(),16),!!isFinite(h));p+=1)v=v*16+h;g+=String.fromCharCode(v)}else if(typeof i[e]=="string")g+=i[e];else break;else g+=e}r("Bad string")},l=function(){for(;e&&e<=" ";)o()},u=function(){switch(e){case"t":return o("t"),o("r"),o("u"),o("e"),!0;case"f":return o("f"),o("a"),o("l"),o("s"),o("e"),!1;case"n":return o("n"),o("u"),o("l"),o("l"),null}r('Unexpected "'+e+'"')},c,d=function(){var h=[];if(e==="["){if(o("["),l(),e==="]")return o("]"),h;for(;e;){if(h.push(c()),l(),e==="]")return o("]"),h;o(","),l()}}r("Bad array")},f=function(){var h,p={};if(e==="{"){if(o("{"),l(),e==="}")return o("}"),p;for(;e;){if(h=s(),l(),o(":"),Object.hasOwnProperty.call(p,h)&&r('Duplicate key "'+h+'"'),p[h]=c(),l(),e==="}")return o("}"),p;o(","),l()}}r("Bad object")};return c=function(){switch(l(),e){case"{":return f();case"[":return d();case'"':return s();case"-":return a();default:return e>="0"&&e<="9"?a():u()}},function(h){var p;return n=h,t=0,e=" ",p=c(),l(),e&&r("Syntax error"),p}})();Ve.base64Encode=function(t){var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",i,n,r,o,a,s,l,u,c=0,d=0,f="",h=[];if(!t)return t;t=Ve.utf8Encode(t);do i=t.charCodeAt(c++),n=t.charCodeAt(c++),r=t.charCodeAt(c++),u=i<<16|n<<8|r,o=u>>18&63,a=u>>12&63,s=u>>6&63,l=u&63,h[d++]=e.charAt(o)+e.charAt(a)+e.charAt(s)+e.charAt(l);while(c<t.length);switch(f=h.join(""),t.length%3){case 1:f=f.slice(0,-2)+"==";break;case 2:f=f.slice(0,-1)+"=";break}return f};Ve.utf8Encode=function(t){t=(t+"").replace(/\r\n/g,`
`).replace(/\r/g,`
`);var e="",i,n,r=0,o;for(i=n=0,r=t.length,o=0;o<r;o++){var a=t.charCodeAt(o),s=null;a<128?n++:a>127&&a<2048?s=String.fromCharCode(a>>6|192,a&63|128):s=String.fromCharCode(a>>12|224,a>>6&63|128,a&63|128),s!==null&&(n>i&&(e+=t.substring(i,n)),e+=s,i=n=o+1)}return n>i&&(e+=t.substring(i,t.length)),e};Ve.UUID=function(){try{return kr.crypto.randomUUID()}catch{for(var t=new Array(36),e=0;e<36;e++)t[e]=Math.floor(Math.random()*16);return t[14]=4,t[19]=t[19]&=-5,t[19]=t[19]|=8,t[8]=t[13]=t[18]=t[23]="-",Ve.map(t,function(n){return n.toString(16)}).join("")}};var Ise=["ahrefsbot","ahrefssiteaudit","amazonbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","facebookexternal","petalbot","pinterest","screaming frog","yahoo! slurp","yandex","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleweblight","mediapartners-google","storebot-google"];Ve.isBlockedUA=function(t){var e;for(t=t.toLowerCase(),e=0;e<Ise.length;e++)if(t.indexOf(Ise[e])!==-1)return!0;return!1};Ve.HTTPBuildQuery=function(t,e){var i,n,r=[];return Ve.isUndefined(e)&&(e="&"),Ve.each(t,function(o,a){i=encodeURIComponent(o.toString()),n=encodeURIComponent(a),r[r.length]=n+"="+i}),r.join(e)};Ve.getQueryParam=function(t,e){e=e.replace(/[[]/g,"\\[").replace(/[\]]/g,"\\]");var i="[\\?&]"+e+"=([^&#]*)",n=new RegExp(i),r=n.exec(t);if(r===null||r&&typeof r[1]!="string"&&r[1].length)return"";var o=r[1];try{o=decodeURIComponent(o)}catch{Bn.error("Skipping decoding for malformed query param: "+o)}return o.replace(/\+/g," ")};Ve.cookie={get:function(t){for(var e=t+"=",i=Dn.cookie.split(";"),n=0;n<i.length;n++){for(var r=i[n];r.charAt(0)==" ";)r=r.substring(1,r.length);if(r.indexOf(e)===0)return decodeURIComponent(r.substring(e.length,r.length))}return null},parse:function(t){var e;try{e=Ve.JSONDecode(Ve.cookie.get(t))||{}}catch{}return e},set_seconds:function(t,e,i,n,r,o,a){var s="",l="",u="";if(a)s="; domain="+a;else if(n){var c=Nse(Dn.location.hostname);s=c?"; domain=."+c:""}if(i){var d=new Date;d.setTime(d.getTime()+i*1e3),l="; expires="+d.toGMTString()}o&&(r=!0,u="; SameSite=None"),r&&(u+="; secure"),Dn.cookie=t+"="+encodeURIComponent(e)+l+"; path=/"+s+u},set:function(t,e,i,n,r,o,a){var s="",l="",u="";if(a)s="; domain="+a;else if(n){var c=Nse(Dn.location.hostname);s=c?"; domain=."+c:""}if(i){var d=new Date;d.setTime(d.getTime()+i*24*60*60*1e3),l="; expires="+d.toGMTString()}o&&(r=!0,u="; SameSite=None"),r&&(u+="; secure");var f=t+"="+encodeURIComponent(e)+l+"; path=/"+s+u;return Dn.cookie=f,f},remove:function(t,e,i){Ve.cookie.set(t,"",-1,e,!1,!1,i)}};var MDe=function(t){var e=!0;try{var i="__mplss_"+see(8),n="xyz";t.setItem(i,n),t.getItem(i)!==n&&(e=!1),t.removeItem(i)}catch{e=!1}return e},w8=null,d3=function(t,e){return w8!==null&&!e?w8:w8=MDe(t||kr.localStorage)},A8=null,Mrt=function(t,e){return A8!==null&&!e?A8:A8=MDe(t||kr.sessionStorage)};function LDe(t,e,i){var n=function(r){Bn.error(e+" error: "+r)};return{is_supported:function(r){var o=i(t,r);return o||Bn.error(e+" unsupported"),o},error:n,get:function(r){try{return t.getItem(r)}catch(o){n(o)}return null},parse:function(r){try{return Ve.JSONDecode(t.getItem(r))||{}}catch{}return null},set:function(r,o){try{t.setItem(r,o)}catch(a){n(a)}},remove:function(r){try{t.removeItem(r)}catch(o){n(o)}}}}var kDe=null,IDe=null;try{kDe=kr.localStorage,IDe=kr.sessionStorage}catch{}Ve.localStorage=LDe(kDe,"localStorage",d3);Ve.sessionStorage=LDe(IDe,"sessionStorage",Mrt);Ve.register_event=(function(){var t=function(n,r,o,a,s){if(!n){Bn.error("No valid element provided to register_event");return}if(n.addEventListener&&!a)n.addEventListener(r,o,!!s);else{var l="on"+r,u=n[l];n[l]=e(n,o,u)}};function e(n,r,o){var a=function(s){if(s=s||i(kr.event),!!s){var l=!0,u,c;return Ve.isFunction(o)&&(u=o(s)),c=r.call(n,s),(u===!1||c===!1)&&(l=!1),l}};return a}function i(n){return n&&(n.preventDefault=i.preventDefault,n.stopPropagation=i.stopPropagation),n}return i.preventDefault=function(){this.returnValue=!1},i.stopPropagation=function(){this.cancelBubble=!0},t})();var Lrt=new RegExp('^(\\w*)\\[(\\w+)([=~\\|\\^\\$\\*]?)=?"?([^\\]"]*)"?\\]$');Ve.dom_query=(function(){function t(r){return r.all?r.all:r.getElementsByTagName("*")}var e=/[\t\r\n]/g;function i(r,o){var a=" "+o+" ";return(" "+r.className+" ").replace(e," ").indexOf(a)>=0}function n(r){if(!Dn.getElementsByTagName)return[];var o=r.split(" "),a,s,l,u,c,d,f,h,p,g,v=[Dn];for(d=0;d<o.length;d++){if(a=o[d].replace(/^\s+/,"").replace(/\s+$/,""),a.indexOf("#")>-1){s=a.split("#"),l=s[0];var y=s[1],m=Dn.getElementById(y);if(!m||l&&m.nodeName.toLowerCase()!=l)return[];v=[m];continue}if(a.indexOf(".")>-1){s=a.split("."),l=s[0];var b=s[1];for(l||(l="*"),u=[],c=0,f=0;f<v.length;f++)for(l=="*"?p=t(v[f]):p=v[f].getElementsByTagName(l),h=0;h<p.length;h++)u[c++]=p[h];for(v=[],g=0,f=0;f<u.length;f++)u[f].className&&Ve.isString(u[f].className)&&i(u[f],b)&&(v[g++]=u[f]);continue}var S=a.match(Lrt);if(S){l=S[1];var _=S[2],C=S[3],P=S[4];for(l||(l="*"),u=[],c=0,f=0;f<v.length;f++)for(l=="*"?p=t(v[f]):p=v[f].getElementsByTagName(l),h=0;h<p.length;h++)u[c++]=p[h];v=[],g=0;var x;switch(C){case"=":x=function(E){return E.getAttribute(_)==P};break;case"~":x=function(E){return E.getAttribute(_).match(new RegExp("\\b"+P+"\\b"))};break;case"|":x=function(E){return E.getAttribute(_).match(new RegExp("^"+P+"-?"))};break;case"^":x=function(E){return E.getAttribute(_).indexOf(P)===0};break;case"$":x=function(E){return E.getAttribute(_).lastIndexOf(P)==E.getAttribute(_).length-P.length};break;case"*":x=function(E){return E.getAttribute(_).indexOf(P)>-1};break;default:x=function(E){return E.getAttribute(_)}}for(v=[],g=0,f=0;f<u.length;f++)x(u[f])&&(v[g++]=u[f]);continue}for(l=a,u=[],c=0,f=0;f<v.length;f++)for(p=v[f].getElementsByTagName(l),h=0;h<p.length;h++)u[c++]=p[h];v=u}return v}return function(r){return Ve.isElement(r)?[r]:Ve.isObject(r)&&!Ve.isUndefined(r.length)?r:n.call(this,r)}})();var krt=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","utm_id","utm_source_platform","utm_campaign_id","utm_creative_format","utm_marketing_tactic"],Irt=["dclid","fbclid","gclid","ko_click_id","li_fat_id","msclkid","sccid","ttclid","twclid","wbraid"];Ve.info={campaignParams:function(t){var e="",i={};return Ve.each(krt,function(n){e=Ve.getQueryParam(Dn.URL,n),e.length?i[n]=e:t!==void 0&&(i[n]=t)}),i},clickParams:function(){var t="",e={};return Ve.each(Irt,function(i){t=Ve.getQueryParam(Dn.URL,i),t.length&&(e[i]=t)}),e},marketingParams:function(){return Ve.extend(Ve.info.campaignParams(),Ve.info.clickParams())},searchEngine:function(t){return t.search("https?://(.*)google.([^/?]*)")===0?"google":t.search("https?://(.*)bing.com")===0?"bing":t.search("https?://(.*)yahoo.com")===0?"yahoo":t.search("https?://(.*)duckduckgo.com")===0?"duckduckgo":null},searchInfo:function(t){var e=Ve.info.searchEngine(t),i=e!="yahoo"?"q":"p",n={};if(e!==null){n.$search_engine=e;var r=Ve.getQueryParam(t,i);r.length&&(n.mp_keyword=r)}return n},browser:function(t,e,i){return e=e||"",i||Ve.includes(t," OPR/")?Ve.includes(t,"Mini")?"Opera Mini":"Opera":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":Ve.includes(t,"IEMobile")||Ve.includes(t,"WPDesktop")?"Internet Explorer Mobile":Ve.includes(t,"SamsungBrowser/")?"Samsung Internet":Ve.includes(t,"Edge")||Ve.includes(t,"Edg/")?"Microsoft Edge":Ve.includes(t,"FBIOS")?"Facebook Mobile":Ve.includes(t,"Whale/")?"Whale Browser":Ve.includes(t,"Chrome")?"Chrome":Ve.includes(t,"CriOS")?"Chrome iOS":Ve.includes(t,"UCWEB")||Ve.includes(t,"UCBrowser")?"UC Browser":Ve.includes(t,"FxiOS")?"Firefox iOS":Ve.includes(e,"Apple")?Ve.includes(t,"Mobile")?"Mobile Safari":"Safari":Ve.includes(t,"Android")?"Android Mobile":Ve.includes(t,"Konqueror")?"Konqueror":Ve.includes(t,"Firefox")?"Firefox":Ve.includes(t,"MSIE")||Ve.includes(t,"Trident/")?"Internet Explorer":Ve.includes(t,"Gecko")?"Mozilla":""},browserVersion:function(t,e,i){var n=Ve.info.browser(t,e,i),r={"Internet Explorer Mobile":/rv:(\d+(\.\d+)?)/,"Microsoft Edge":/Edge?\/(\d+(\.\d+)?)/,Chrome:/Chrome\/(\d+(\.\d+)?)/,"Chrome iOS":/CriOS\/(\d+(\.\d+)?)/,"UC Browser":/(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/,Safari:/Version\/(\d+(\.\d+)?)/,"Mobile Safari":/Version\/(\d+(\.\d+)?)/,Opera:/(Opera|OPR)\/(\d+(\.\d+)?)/,Firefox:/Firefox\/(\d+(\.\d+)?)/,"Firefox iOS":/FxiOS\/(\d+(\.\d+)?)/,Konqueror:/Konqueror:(\d+(\.\d+)?)/,BlackBerry:/BlackBerry (\d+(\.\d+)?)/,"Android Mobile":/android\s(\d+(\.\d+)?)/,"Samsung Internet":/SamsungBrowser\/(\d+(\.\d+)?)/,"Internet Explorer":/(rv:|MSIE )(\d+(\.\d+)?)/,Mozilla:/rv:(\d+(\.\d+)?)/,"Whale Browser":/Whale\/(\d+(\.\d+)?)/},o=r[n];if(o===void 0)return null;var a=t.match(o);return a?parseFloat(a[a.length-2]):null},os:function(){var t=By;return/Windows/i.test(t)?/Phone/.test(t)||/WPDesktop/.test(t)?"Windows Phone":"Windows":/(iPhone|iPad|iPod)/.test(t)?"iOS":/Android/.test(t)?"Android":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":/Mac/i.test(t)?"Mac OS X":/Linux/.test(t)?"Linux":/CrOS/.test(t)?"Chrome OS":""},device:function(t){return/Windows Phone/i.test(t)||/WPDesktop/.test(t)?"Windows Phone":/iPad/.test(t)?"iPad":/iPod/.test(t)?"iPod Touch":/iPhone/.test(t)?"iPhone":/(BlackBerry|PlayBook|BB10)/i.test(t)?"BlackBerry":/Android/.test(t)?"Android":""},referringDomain:function(t){var e=t.split("/");return e.length>=3?e[2]:""},currentUrl:function(){return kr.location.href},properties:function(t){return typeof t!="object"&&(t={}),Ve.extend(Ve.strip_empty_properties({$os:Ve.info.os(),$browser:Ve.info.browser(By,cS.vendor,nj),$referrer:Dn.referrer,$referring_domain:Ve.info.referringDomain(Dn.referrer),$device:Ve.info.device(By)}),{$current_url:Ve.info.currentUrl(),$browser_version:Ve.info.browserVersion(By,cS.vendor,nj),$screen_height:Rse.height,$screen_width:Rse.width,mp_lib:"web",$lib_version:Dh.LIB_VERSION,$insert_id:see(),time:Ve.timestamp()/1e3},Ve.strip_empty_properties(t))},people_properties:function(){return Ve.extend(Ve.strip_empty_properties({$os:Ve.info.os(),$browser:Ve.info.browser(By,cS.vendor,nj)}),{$browser_version:Ve.info.browserVersion(By,cS.vendor,nj)})},mpPageViewProperties:function(){return Ve.strip_empty_properties({current_page_title:Dn.title,current_domain:kr.location.hostname,current_url_path:kr.location.pathname,current_url_protocol:kr.location.protocol,current_url_search:kr.location.search})}};var Nrt=function(t,e){var i=null,n=[];return function(r){var o=this;return n.push(r),i||(i=new Hn(function(a){setTimeout(function(){var s=t.apply(o,[n]);i=null,n=[],a(s)},e)})),i}},see=function(t){var e=Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10);return t?e.substring(0,t):e},NDe=function(){var t=Ve.UUID().replace(/-/g,""),e=Ve.UUID().replace(/-/g,"").substring(0,16),i="01";return"00-"+t+"-"+e+"-"+i},Frt=/[a-z0-9][a-z0-9-]*\.[a-z]+$/i,Brt=/[a-z0-9][a-z0-9-]+\.[a-z.]{2,6}$/i,Nse=function(t){var e=Brt,i=t.split("."),n=i[i.length-1];(n.length>4||n==="com"||n==="org")&&(e=Frt);var r=t.match(e);return r?r[0]:""},jrt=function(){var t=kr.navigator.onLine;return Ve.isUndefined(t)||t},gP=function(){},$5=function(t,e){for(var i=!1,n=0;n<e.length;n++)if(t.match(e[n])){i=!0;break}return i},Mk=null,W5=null;typeof JSON<"u"&&(Mk=JSON.stringify,W5=JSON.parse);Mk=Mk||Ve.JSONEncode;W5=W5||Ve.JSONDecode;var Vrt=function(t,e,i){if(!kr.CompressionStream)return!1;var n=Ve.info.browser(t,e,i),r=Ve.info.browserVersion(t,e,i);return!((n==="Safari"||n==="Mobile Safari")&&r>=16.4&&r<16.6)};Ve.info=Ve.info;Ve.info.browser=Ve.info.browser;Ve.info.browserVersion=Ve.info.browserVersion;Ve.info.device=Ve.info.device;Ve.info.properties=Ve.info.properties;Ve.isBlockedUA=Ve.isBlockedUA;Ve.isEmptyObject=Ve.isEmptyObject;Ve.isObject=Ve.isObject;Ve.JSONDecode=Ve.JSONDecode;Ve.JSONEncode=Ve.JSONEncode;Ve.toArray=Ve.toArray;Ve.NPO=HP;var Hrt="mixpanelBrowserDb",FDe="mixpanelRecordingEvents",lee="mixpanelRecordingRegistry",Urt=1,zrt=[FDe,lee],Hv=function(t){this.dbPromise=null,this.storeName=t};Hv.prototype._openDb=function(){return new Hn(function(t,e){var i=kr.indexedDB.open(Hrt,Urt);i.onerror=function(){e(i.error)},i.onsuccess=function(){t(i.result)},i.onupgradeneeded=function(n){var r=n.target.result;zrt.forEach(function(o){r.createObjectStore(o)})}})};Hv.prototype.init=function(){return kr.indexedDB?(this.dbPromise||(this.dbPromise=this._openDb()),this.dbPromise.then(function(t){return t instanceof kr.IDBDatabase?Hn.resolve():Hn.reject(t)})):Hn.reject("indexedDB is not supported in this browser")};Hv.prototype.isInitialized=function(){return!!this.dbPromise};Hv.prototype.makeTransaction=function(t,e){var i=this.storeName,n=function(r){return new Hn(function(o,a){var s=r.transaction(i,t);s.oncomplete=function(){o(s)},s.onabort=s.onerror=function(){a(s.error)},e(s.objectStore(i))})};return this.dbPromise.then(n).catch((function(r){return r&&r.name==="InvalidStateError"?(this.dbPromise=this._openDb(),this.dbPromise.then(n)):Hn.reject(r)}).bind(this))};Hv.prototype.setItem=function(t,e){return this.makeTransaction("readwrite",function(i){i.put(e,t)})};Hv.prototype.getItem=function(t){var e;return this.makeTransaction("readonly",function(i){e=i.get(t)}).then(function(){return e.result})};Hv.prototype.removeItem=function(t){return this.makeTransaction("readwrite",function(e){e.delete(t)})};Hv.prototype.getAll=function(){var t;return this.makeTransaction("readonly",function(e){t=e.getAll()}).then(function(){return t.result})};var $rt="__mp_opt_in_out_";function Wrt(t,e){VDe(!0,t,e)}function Grt(t,e){VDe(!1,t,e)}function Yrt(t,e){return jDe(t,e)==="1"}function BDe(t,e){if(Xrt(e))return Bn.warn('This browser has "Do Not Track" enabled. This will prevent the Mixpanel SDK from sending any data. To ignore the "Do Not Track" browser setting, initialize the Mixpanel instance with the config "ignore_dnt: true"'),!0;var i=jDe(t,e)==="0";return i&&Bn.warn("You are opted out of Mixpanel tracking. This will prevent the Mixpanel SDK from sending any data."),i}function zP(t){return dee(t,function(e){return this.get_config(e)})}function $P(t){return dee(t,function(e){return this._get_config(e)})}function fI(t){return dee(t,function(e){return this._get_config(e)})}function qrt(t,e){e=e||{},uee(e).remove(cee(t,e),!!e.crossSubdomainCookie,e.cookieDomain)}function uee(t){return t=t||{},t.persistenceType==="localStorage"?Ve.localStorage:Ve.cookie}function cee(t,e){return e=e||{},(e.persistencePrefix||$rt)+t}function jDe(t,e){return uee(e).get(cee(t,e))}function Xrt(t){if(t&&t.ignoreDnt)return!1;var e=t&&t.window||kr,i=e.navigator||{},n=!1;return Ve.each([i.doNotTrack,i.msDoNotTrack,e.doNotTrack],function(r){Ve.includes([!0,1,"1","yes"],r)&&(n=!0)}),n}function VDe(t,e,i){if(!Ve.isString(e)||!e.length){Bn.error("gdpr."+(t?"optIn":"optOut")+" called with an invalid token");return}i=i||{},uee(i).set(cee(e,i),t?1:0,Ve.isNumber(i.cookieExpiration)?i.cookieExpiration:null,!!i.crossSubdomainCookie,!!i.secureCookie,!!i.crossSiteCookie,i.cookieDomain),i.track&&t&&i.track(i.trackEventName||"$opt_in",i.trackProperties,{send_immediately:!0})}function dee(t,e){return function(){var i=!1;try{var n=e.call(this,"token"),r=e.call(this,"ignore_dnt"),o=e.call(this,"opt_out_tracking_persistence_type"),a=e.call(this,"opt_out_tracking_cookie_prefix"),s=e.call(this,"window");n&&(i=BDe(n,{ignoreDnt:r,persistenceType:o,persistencePrefix:a,window:s}))}catch(u){Bn.error("Unexpected error when checking tracking opt-out status: "+u)}if(!i)return t.apply(this,arguments);var l=arguments[arguments.length-1];typeof l=="function"&&l(0)}}var Krt=UP("lock"),HDe=function(t,e){e=e||{},this.storageKey=t,this.storage=e.storage||kr.localStorage,this.pollIntervalMS=e.pollIntervalMS||100,this.timeoutMS=e.timeoutMS||2e3,this.promiseImpl=e.promiseImpl||Hn};HDe.prototype.withLock=function(t,e){var i=this.promiseImpl;return new i(Ve.bind(function(n,r){var o=e||new Date().getTime()+"|"+Math.random(),a=new Date().getTime(),s=this.storageKey,l=this.pollIntervalMS,u=this.timeoutMS,c=this.storage,d=s+":X",f=s+":Y",h=s+":Z",p=function(b){if(new Date().getTime()-a>u){Krt.error("Timeout waiting for mutex on "+s+"; clearing lock. ["+o+"]"),c.removeItem(h),c.removeItem(f),y();return}setTimeout(function(){try{b()}catch(S){r(S)}},l*(Math.random()+.1))},g=function(b,S){b()?S():p(function(){g(b,S)})},v=function(){var b=c.getItem(f);return b&&b!==o?!1:(c.setItem(f,o),c.getItem(f)===o?!0:(d3(c,!0)||r(new Error("localStorage support dropped while acquiring lock")),!1))},y=function(){c.setItem(d,o),g(v,function(){if(c.getItem(d)===o){m();return}p(function(){if(c.getItem(f)!==o){y();return}g(function(){return!c.getItem(h)},m)})})},m=function(){c.setItem(h,"1");var b=function(){c.removeItem(h),c.getItem(f)===o&&c.removeItem(f),c.getItem(d)===o&&c.removeItem(d)};t().then(function(S){b(),n(S)}).catch(function(S){b(),r(S)})};try{if(d3(c,!0))y();else throw new Error("localStorage support check failed")}catch(b){r(b)}},this))};var hI=function(t){this.storage=t||kr.localStorage};hI.prototype.init=function(){return Hn.resolve()};hI.prototype.isInitialized=function(){return!0};hI.prototype.setItem=function(t,e){return new Hn(Ve.bind(function(i,n){try{this.storage.setItem(t,Mk(e))}catch(r){n(r)}i()},this))};hI.prototype.getItem=function(t){return new Hn(Ve.bind(function(e,i){var n;try{n=W5(this.storage.getItem(t))}catch(r){i(r)}e(n)},this))};hI.prototype.removeItem=function(t){return new Hn(Ve.bind(function(e,i){try{this.storage.removeItem(t)}catch(n){i(n)}e()},this))};var Fse=UP("batch"),_m=function(t,e){e=e||{},this.storageKey=t,this.usePersistence=e.usePersistence,this.usePersistence&&(this.queueStorage=e.queueStorage||new hI,this.lock=new HDe(t,{storage:e.sharedLockStorage||kr.localStorage,timeoutMS:e.sharedLockTimeoutMS})),this.reportError=e.errorReporter||Ve.bind(Fse.error,Fse),this.pid=e.pid||null,this.memQueue=[],this.initialized=!1,e.enqueueThrottleMs?this.enqueuePersisted=Nrt(Ve.bind(this._enqueuePersisted,this),e.enqueueThrottleMs):this.enqueuePersisted=Ve.bind(function(i){return this._enqueuePersisted([i])},this)};_m.prototype.ensureInit=function(){return this.initialized||!this.usePersistence?Hn.resolve():this.queueStorage.init().then(Ve.bind(function(){this.initialized=!0},this)).catch(Ve.bind(function(t){this.reportError("Error initializing queue persistence. Disabling persistence",t),this.initialized=!0,this.usePersistence=!1},this))};_m.prototype.enqueue=function(t,e){var i={id:see(),flushAfter:new Date().getTime()+e*2,payload:t};return this.usePersistence?this.enqueuePersisted(i):(this.memQueue.push(i),Hn.resolve(!0))};_m.prototype._enqueuePersisted=function(t){var e=Ve.bind(function(){return this.ensureInit().then(Ve.bind(function(){return this.readFromStorage()},this)).then(Ve.bind(function(i){return this.saveToStorage(i.concat(t))},this)).then(Ve.bind(function(i){return i&&(this.memQueue=this.memQueue.concat(t)),i},this)).catch(Ve.bind(function(i){return this.reportError("Error enqueueing items",i,t),!1},this))},this);return this.lock.withLock(e,this.pid).catch(Ve.bind(function(i){return this.reportError("Error acquiring storage lock",i),!1},this))};_m.prototype.fillBatch=function(t){var e=this.memQueue.slice(0,t);return this.usePersistence&&e.length<t?this.ensureInit().then(Ve.bind(function(){return this.readFromStorage()},this)).then(Ve.bind(function(i){if(i.length){var n={};Ve.each(e,function(a){n[a.id]=!0});for(var r=0;r<i.length;r++){var o=i[r];if(new Date().getTime()>o.flushAfter&&!n[o.id]&&(o.orphaned=!0,e.push(o),e.length>=t))break}}return e},this)):Hn.resolve(e)};var Bse=function(t,e){var i=[];return Ve.each(t,function(n){n.id&&!e[n.id]&&i.push(n)}),i};_m.prototype.removeItemsByID=function(t){var e={};if(Ve.each(t,function(n){e[n]=!0}),this.memQueue=Bse(this.memQueue,e),this.usePersistence){var i=Ve.bind(function(){return this.ensureInit().then(Ve.bind(function(){return this.readFromStorage()},this)).then(Ve.bind(function(n){return n=Bse(n,e),this.saveToStorage(n)},this)).then(Ve.bind(function(){return this.readFromStorage()},this)).then(Ve.bind(function(n){for(var r=0;r<n.length;r++){var o=n[r];if(o.id&&e[o.id])throw new Error("Item not removed from storage")}return!0},this)).catch(Ve.bind(function(n){return this.reportError("Error removing items",n,t),!1},this))},this);return this.lock.withLock(i,this.pid).catch(Ve.bind(function(n){return this.reportError("Error acquiring storage lock",n),d3(this.lock.storage,!0)?!1:i().then(Ve.bind(function(r){return r||this.queueStorage.removeItem(this.storageKey).then(function(){return r})},this)).catch(Ve.bind(function(r){return this.reportError("Error clearing queue",r),!1},this))},this))}else return Hn.resolve(!0)};var jse=function(t,e){var i=[];return Ve.each(t,function(n){var r=n.id;if(r in e){var o=e[r];o!==null&&(n.payload=o,i.push(n))}else i.push(n)}),i};_m.prototype.updatePayloads=function(t){return this.memQueue=jse(this.memQueue,t),this.usePersistence?this.lock.withLock(Ve.bind(function(){return this.ensureInit().then(Ve.bind(function(){return this.readFromStorage()},this)).then(Ve.bind(function(i){return i=jse(i,t),this.saveToStorage(i)},this)).catch(Ve.bind(function(i){return this.reportError("Error updating items",t,i),!1},this))},this),this.pid).catch(Ve.bind(function(e){return this.reportError("Error acquiring storage lock",e),!1},this)):Hn.resolve(!0)};_m.prototype.readFromStorage=function(){return this.ensureInit().then(Ve.bind(function(){return this.queueStorage.getItem(this.storageKey)},this)).then(Ve.bind(function(t){return t&&(Ve.isArray(t)||(this.reportError("Invalid storage entry:",t),t=null)),t||[]},this)).catch(Ve.bind(function(t){return this.reportError("Error retrieving queue",t),[]},this))};_m.prototype.saveToStorage=function(t){return this.ensureInit().then(Ve.bind(function(){return this.queueStorage.setItem(this.storageKey,t)},this)).then(function(){return!0}).catch(Ve.bind(function(e){return this.reportError("Error saving queue",e),!1},this))};_m.prototype.clear=function(){return this.memQueue=[],this.usePersistence?this.ensureInit().then(Ve.bind(function(){return this.queueStorage.removeItem(this.storageKey)},this)):Hn.resolve()};var Zrt=600*1e3,Cj=UP("batch"),Lg=function(t,e){this.errorReporter=e.errorReporter,this.queue=new _m(t,{errorReporter:Ve.bind(this.reportError,this),queueStorage:e.queueStorage,sharedLockStorage:e.sharedLockStorage,sharedLockTimeoutMS:e.sharedLockTimeoutMS,usePersistence:e.usePersistence,enqueueThrottleMs:e.enqueueThrottleMs}),this.libConfig=e.libConfig,this.sendRequest=e.sendRequestFunc,this.beforeSendHook=e.beforeSendHook,this.stopAllBatching=e.stopAllBatchingFunc,this.batchSize=this.libConfig.batch_size,this.flushInterval=this.libConfig.batch_flush_interval_ms,this.stopped=!this.libConfig.batch_autostart,this.consecutiveRemovalFailures=0,this.itemIdsSentSuccessfully={},this.flushOnlyOnInterval=e.flushOnlyOnInterval||!1,this._flushPromise=null};Lg.prototype.enqueue=function(t){return this.queue.enqueue(t,this.flushInterval)};Lg.prototype.start=function(){return this.stopped=!1,this.consecutiveRemovalFailures=0,this.flush()};Lg.prototype.stop=function(){this.stopped=!0,this.timeoutID&&(clearTimeout(this.timeoutID),this.timeoutID=null)};Lg.prototype.clear=function(){return this.queue.clear()};Lg.prototype.resetBatchSize=function(){this.batchSize=this.libConfig.batch_size};Lg.prototype.resetFlush=function(){this.scheduleFlush(this.libConfig.batch_flush_interval_ms)};Lg.prototype.scheduleFlush=function(t){this.flushInterval=t,this.stopped||(this.timeoutID=setTimeout(Ve.bind(function(){this.stopped||(this._flushPromise=this.flush())},this),this.flushInterval))};Lg.prototype.sendRequestPromise=function(t,e){return new Hn(Ve.bind(function(i){this.sendRequest(t,e,i)},this))};Lg.prototype.flush=function(t){if(this.requestInProgress)return Cj.log("Flush: Request already in progress"),Hn.resolve();this.requestInProgress=!0,t=t||{};var e=this.libConfig.batch_request_timeout_ms,i=new Date().getTime(),n=this.batchSize;return this.queue.fillBatch(n).then(Ve.bind(function(r){var o=r.length===n,a=[],s={};if(Ve.each(r,function(d){var f=d.payload;if(this.beforeSendHook&&!d.orphaned&&(f=this.beforeSendHook(f)),f){f.event&&f.properties&&(f.properties=Ve.extend({},f.properties,{mp_sent_by_lib_version:Dh.LIB_VERSION}));var h=!0,p=d.id;p?(this.itemIdsSentSuccessfully[p]||0)>5&&(this.reportError("[dupe] item ID sent too many times, not sending",{item:d,batchSize:r.length,timesSent:this.itemIdsSentSuccessfully[p]}),h=!1):this.reportError("[dupe] found item with no ID",{item:d}),h&&a.push(f)}s[d.id]=f},this),a.length<1)return this.requestInProgress=!1,this.resetFlush(),Hn.resolve();var l=Ve.bind(function(){return this.queue.removeItemsByID(Ve.map(r,function(d){return d.id})).then(Ve.bind(function(d){return Ve.each(r,Ve.bind(function(f){var h=f.id;h?(this.itemIdsSentSuccessfully[h]=this.itemIdsSentSuccessfully[h]||0,this.itemIdsSentSuccessfully[h]++,this.itemIdsSentSuccessfully[h]>5&&this.reportError("[dupe] item ID sent too many times",{item:f,batchSize:r.length,timesSent:this.itemIdsSentSuccessfully[h]})):this.reportError("[dupe] found item with no ID while removing",{item:f})},this)),d?(this.consecutiveRemovalFailures=0,this.flushOnlyOnInterval&&!o?(this.resetFlush(),Hn.resolve()):this.flush()):(++this.consecutiveRemovalFailures>5?(this.reportError("Too many queue failures; disabling batching system."),this.stopAllBatching()):this.resetFlush(),Hn.resolve())},this))},this),u=Ve.bind(function(d){this.requestInProgress=!1;try{if(t.unloading)return this.queue.updatePayloads(s);if(Ve.isObject(d)&&d.error==="timeout"&&new Date().getTime()-i>=e)return this.reportError("Network timeout; retrying"),this.flush();if(Ve.isObject(d)&&(d.httpStatusCode>=500||d.httpStatusCode===429||d.httpStatusCode<=0&&!jrt()||d.error==="timeout")){var f=this.flushInterval*2;return d.retryAfter&&(f=parseInt(d.retryAfter,10)*1e3||f),f=Math.min(Zrt,f),this.reportError("Error; retry in "+f+" ms"),this.scheduleFlush(f),Hn.resolve()}else if(Ve.isObject(d)&&d.httpStatusCode===413)if(r.length>1){var h=Math.max(1,Math.floor(n/2));return this.batchSize=Math.min(this.batchSize,h,r.length-1),this.reportError("413 response; reducing batch size to "+this.batchSize),this.resetFlush(),Hn.resolve()}else return this.reportError("Single-event request too large; dropping",r),this.resetBatchSize(),l();else return l()}catch(p){this.reportError("Error handling API response",p),this.resetFlush()}},this),c={method:"POST",verbose:!0,ignore_json_errors:!0,timeout_ms:e};return t.unloading&&(c.transport="sendBeacon"),Cj.log("MIXPANEL REQUEST:",a),this.sendRequestPromise(a,c).then(u)},this)).catch(Ve.bind(function(r){this.reportError("Error flushing request queue",r),this.resetFlush()},this))};Lg.prototype.reportError=function(t,e){if(Cj.error.apply(Cj.error,arguments),this.errorReporter)try{e instanceof Error||(e=new Error(t)),this.errorReporter(t,e)}catch(i){Cj.error(i)}};var fee=function(t){var e=Date.now();return!t||e>t.maxExpires||e>t.idleExpires},Jrt=250,f3="change",ES="click",UK="hashchange",Qrt="input",Vse="load",sP="mp_locationchange",Hse="popstate",s6="scrollend",hee="scroll",eit="select",G5="submit",tit="toggle",Use="visibilitychange",rit=["clientX","clientY","offsetX","offsetY","pageX","pageY","screenX","screenY","x","y"],zse=["mp-include"],zK=["mp-no-track"],$se=zK.concat(["mp-sensitive"]),iit=["aria-label","aria-labelledby","aria-describedby","href","name","role","title","type"],nit={button:!0,checkbox:!0,combobox:!0,grid:!0,link:!0,listbox:!0,menu:!0,menubar:!0,menuitem:!0,menuitemcheckbox:!0,menuitemradio:!0,navigation:!0,option:!0,radio:!0,radiogroup:!0,searchbox:!0,slider:!0,spinbutton:!0,switch:!0,tab:!0,tablist:!0,textbox:!0,tree:!0,treegrid:!0,treeitem:!0},oit={base:!0,head:!0,html:!0,link:!0,meta:!0,script:!0,style:!0,title:!0,br:!0,hr:!0,wbr:!0,noscript:!0,picture:!0,source:!0,template:!0,track:!0},ait={article:!0,div:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,p:!0,section:!0,span:!0},Wse=["onclick","onmousedown","onmouseup","onpointerdown","onpointerup","ontouchend","ontouchstart"],sit=5,hs=UP("autocapture");function $K(t){for(var e={},i=UDe(t).split(" "),n=0;n<i.length;n++){var r=i[n];r&&(e[r]=!0)}return e}function UDe(t){switch(typeof t.className){case"string":return t.className;case"object":return t.className.baseVal||t.getAttribute("class")||"";default:return""}}function lit(t){if(t.previousElementSibling)return t.previousElementSibling;do t=t.previousSibling;while(t&&!zDe(t));return t}function Gse(t,e,i,n,r,o){var a={$classes:UDe(t).split(" "),$tag_name:t.tagName.toLowerCase()},s=t.id;s&&(a.$id=s),pee(t,e,r,o)&&Ve.each(iit.concat(n),function(d){if(t.hasAttribute(d)&&!i[d]){var f=t.getAttribute(d);Y5(f)&&(a["$attr-"+d]=f)}});for(var l=1,u=1,c=t;c=lit(c);)l++,c.tagName===t.tagName&&u++;return a.$nth_child=l,a.$nth_of_type=u,a}function uit(t,e){var i=e.allowElementCallback,n=e.allowSelectors||[],r=e.blockAttrs||[],o=e.blockElementCallback,a=e.blockSelectors||[],s=e.captureTextContent||!1,l=e.captureExtraAttrs||[],u=e.capturedForHeatMap||!1,c={};Ve.each(r,function(_){c[_]=!0});var d=null,f=typeof t.target>"u"?t.srcElement:t.target;if($De(f)&&(f=f.parentNode),hit(f,t)&&WK(f,t,i,n)&&!O8(f,t,o,a)){for(var h=[f],p=f;p.parentNode&&!Xy(p,"body");)h.push(p.parentNode),p=p.parentNode;var g=[],v,y=!1;if(Ve.each(h,function(_){var C=pee(_,t,i,n);!c.href&&_.tagName.toLowerCase()==="a"&&(v=_.getAttribute("href"),v=C&&Y5(v)&&v),O8(_,t,o,a)&&(y=!0),g.push(Gse(_,t,c,l,i,n))},this),!y){var m=Dn.documentElement;if(d={$event_type:t.type,$host:kr.location.host,$pathname:kr.location.pathname,$elements:g,$el_attr__href:v,$viewportHeight:Math.max(m.clientHeight,kr.innerHeight||0),$viewportWidth:Math.max(m.clientWidth,kr.innerWidth||0),$pageHeight:Dn.body.offsetHeight||0,$pageWidth:Dn.body.offsetWidth||0},Ve.each(l,function(_){if(!c[_]&&f.hasAttribute(_)){var C=f.getAttribute(_);Y5(C)&&(d["$el_attr__"+_]=C)}}),s&&(b=Yse(f,t,i,n),b&&b.length&&(d.$el_text=b)),t.type===ES&&(Ve.each(rit,function(_){_ in t&&(d["$"+_]=t[_])}),u&&(d.$captured_for_heatmap=!0),f=cit(t)),s){var b=Yse(f,t,i,n);b&&b.length&&(d.$el_text=b)}if(f){if(!WK(f,t,i,n)||O8(f,t,o,a))return null;var S=Gse(f,t,c,l,i,n);d.$target=S,d.$el_classes=S.$classes,Ve.extend(d,Ve.strip_empty_properties({$el_id:S.$id,$el_tag_name:S.$tag_name}))}}}return d}function Yse(t,e,i,n){var r="";return pee(t,e,i,n)&&t.childNodes&&t.childNodes.length&&Ve.each(t.childNodes,function(o){$De(o)&&o.textContent&&(r+=Ve.trim(o.textContent).split(/(\s+)/).filter(Y5).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255))}),Ve.trim(r)}function cit(t){for(var e=t.target,i=t.composedPath(),n=0;n<i.length;n++){var r=i[n];if(Xy(r,"a")||Xy(r,"button")||Xy(r,"input")||Xy(r,"select")||r.getAttribute&&r.getAttribute("role")==="button"){e=r;break}if(r===e)break}return e}function WK(t,e,i,n){if(i)try{if(!i(t,e))return!1}catch(a){return hs.critical("Error while checking element in allowElementCallback",a),!1}if(!n.length)return!0;for(var r=0;r<n.length;r++){var o=n[r];try{if(t.matches(o))return!0}catch(a){hs.critical("Error while checking selector: "+o,a)}}return!1}function O8(t,e,i,n){var r;if(i)try{if(i(t,e))return!0}catch(s){return hs.critical("Error while checking element in blockElementCallback",s),!0}if(n&&n.length)for(r=0;r<n.length;r++){var o=n[r];try{if(t.matches(o))return!0}catch(s){hs.critical("Error while checking selector: "+o,s)}}var a=$K(t);for(r=0;r<zK.length;r++)if(a[zK[r]])return!0;return!1}function zDe(t){return t&&t.nodeType===1}function Xy(t,e){return t&&t.tagName&&t.tagName.toLowerCase()===e.toLowerCase()}function $De(t){return t&&t.nodeType===3}function dit(){try{var t=Dn.createElement("div");return!!t.matches}catch{return!1}}function fit(){return typeof WeakSet<"u"}function hit(t,e){if(!t||Xy(t,"html")||!zDe(t))return!1;var i=t.tagName.toLowerCase();switch(i){case"form":return e.type===G5;case"input":return["button","submit"].indexOf(t.getAttribute("type"))===-1?e.type===f3:e.type===ES;case"select":case"textarea":return e.type===f3;default:return e.type===ES}}function WDe(t){var e=(t.name||t.id||"").toString().toLowerCase();if(typeof e=="string"){var i=/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i;if(i.test(e.replace(/[^a-zA-Z0-9]/g,"")))return!0}return!1}function pee(t,e,i,n){var r;if(!WK(t,e,i,n))return!1;for(var o=t;o.parentNode&&!Xy(o,"body");o=o.parentNode){var a=$K(o);for(r=0;r<$se.length;r++)if(a[$se[r]])return!1}var s=$K(t);for(r=0;r<zse.length;r++)if(s[zse[r]])return!0;if(Xy(t,"input")||Xy(t,"select")||Xy(t,"textarea")||t.getAttribute("contenteditable")==="true")return!1;var l=t.type||"";if(typeof l=="string")switch(l.toLowerCase()){case"hidden":return!1;case"password":return!1}return!WDe(t)}function Y5(t){if(t===null||Ve.isUndefined(t))return!1;if(typeof t=="string"){t=Ve.trim(t);var e=/^(?:(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11}))$/;if(e.test((t||"").replace(/[- ]/g,"")))return!1;var i=/(^\d{3}-?\d{2}-?\d{4}$)/;if(i.test(t))return!1}return!0}function GDe(t){var e="onscrollend"in kr,i=Rk(t),n=s6;if(!e){var r=null,o=100;i=Rk(function(){clearTimeout(r),r=setTimeout(t,o)}),n=hee}return{listener:i,eventType:n}}function pit(t){for(var e=0;e<Wse.length;e++)if(t.hasAttribute(Wse[e]))return!0;return!1}function git(t){var e=t.getAttribute("role");if(!e)return!1;var i=e.trim().split(/\s+/)[0].toLowerCase();return nit[i]}function D8(t){var e=t.tagName.toLowerCase();return!!(e==="button"||e==="input"||e==="select"||e==="textarea"||e==="details"||e==="dialog"||t.isContentEditable||t.onclick||t.onmousedown||t.onmouseup||t.ontouchstart||t.ontouchend||pit(t)||git(t)||e==="a"&&t.hasAttribute("href")||t.hasAttribute("tabindex"))}function YDe(t){if(!t||!t.tagName)return!0;var e=t.tagName.toLowerCase();if(oit[e])return!0;if(D8(t))return!1;for(var i=t.parentElement,n=0;i&&n<sit;){if(D8(i))return!1;if(i.getRootNode&&i.getRootNode()!==Dn){var r=i.getRootNode();if(r.host&&D8(r.host))return!1}i=i.parentElement,n++}return!!ait[e]}function qDe(t){return"composedPath"in t?t.composedPath():[]}function XDe(t){var e=qDe(t);return e&&e.length>0?e[0]:t.target||t.srcElement}var KDe=".mp-mask, .fs-mask, .amp-mask, .rr-mask, .ph-mask",vit="data-rr-is-password",yit=["password","email","tel","hidden"];function r4(t){return t?Array.isArray(t)?t:[t]:[]}function mit(t){var e={input:{maskingSelector:"",unmaskingSelector:"",maskAll:!0},text:{maskingSelector:"",unmaskingSelector:"",maskAll:!0}},i=t.get_config("record_mask_input_selector"),n=t.get_config("record_unmask_input_selector"),r=t.get_config("record_mask_all_inputs");e.input.maskingSelector=r4(i).join(","),e.input.unmaskingSelector=r4(n).join(","),r!==void 0&&(e.input.maskAll=r);var o=t.get_config("record_mask_text_selector"),a=t.get_config("record_unmask_text_selector"),s=t.get_config("record_mask_all_text"),l=t.get_config("record_mask_text_class"),u=r4(o);if(l)if(l instanceof RegExp)e.text._legacyClassRegex=l;else{var c="."+l;u.indexOf(c)===-1&&u.push(c)}return e.text.maskingSelector=u.join(","),e.text.unmaskingSelector=r4(a).join(","),s===void 0&&o!==void 0?e.text.maskAll=!1:s!==void 0&&(e.text.maskAll=s),e}function HL(t,e){return e?!!t.closest(e):!1}function bit(t,e){var i=(t.getAttribute("type")||"").toLowerCase();if(yit.indexOf(i)!==-1)return!0;var n=(t.getAttribute("autocomplete")||"").toLowerCase();return n&&n!==""&&n!=="off"||t.hasAttribute(vit)||WDe(t)?!0:e.input.maskAll?!HL(t,e.input.unmaskingSelector):!!(HL(t,e.input.maskingSelector)||HL(t,KDe))}function Sit(t,e){return t?e.text._legacyClassRegex&&PK(t,e.text._legacyClassRegex)?!0:e.text.maskAll?!HL(t,e.text.unmaskingSelector):!!(HL(t,e.text.maskingSelector)||HL(t,KDe)):!1}var xD=UP("network-plugin");function q5(t){return Math.round(Date.now()-t.performance.now())}var R8={initiatorTypes:["audio","beacon","body","css","early-hint","embed","fetch","frame","iframe","icon","image","img","input","link","navigation","object","ping","script","track","video","xmlhttprequest"],ignoreRequestFn:function(){return!1},recordHeaders:{request:[],response:[]},recordBodyUrls:{request:[],response:[]},recordInitialRequests:!1};function _it(t){return t.entryType==="navigation"}function GK(t){return t.entryType==="resource"}function Pit(t,e){for(var i=t.length,n=i-1;n>=0;n-=1)if(e(t[n]))return t[n]}function ZDe(t,e,i){if(!(e in t)||typeof t[e]!="function")return function(){};var n=t[e],r=i(n);return t[e]=r,function(){t[e]=n}}var M8=1024*1024;function JDe(t){return!t||typeof t!="string"?t:t.length>M8?(xD.error("Body truncated from "+t.length+" to "+M8+" characters"),t.substring(0,M8)+"... [truncated]"):t}function Cit(t,e,i){if(!e.PerformanceObserver)return xD.error("PerformanceObserver not supported"),function(){};if(i.recordInitialRequests){var n=e.performance.getEntries().filter(function(o){return _it(o)||GK(o)&&i.initiatorTypes.includes(o.initiatorType)});t({requests:n.map(function(o){return{url:o.name,initiatorType:o.initiatorType,status:"responseStatus"in o?o.responseStatus:void 0,startTime:Math.round(o.startTime),endTime:Math.round(o.responseEnd),timeOrigin:q5(e)}}),isInitial:!0})}var r=new e.PerformanceObserver(function(o){var a=o.getEntries().filter(function(s){return GK(s)&&i.initiatorTypes.includes(s.initiatorType)&&s.initiatorType!=="xmlhttprequest"&&s.initiatorType!=="fetch"});t({requests:a.map(function(s){return{url:s.name,initiatorType:s.initiatorType,status:"responseStatus"in s?s.responseStatus:void 0,startTime:Math.round(s.startTime),endTime:Math.round(s.responseEnd),timeOrigin:q5(e)}})})});return r.observe({entryTypes:["navigation","resource"]}),function(){r.disconnect()}}function X5(t,e,i){return!e[t]||e[t].length===0?!1:e[t].includes(i.toLowerCase())}function K5(t,e,i){return!e[t]||e[t].length===0?!1:$5(i,e[t])}function qse(t){if(t==null)return null;var e;if(typeof t=="string")e=t;else if(t instanceof Document)e=t.textContent;else if(t instanceof FormData)e=Ve.HTTPBuildQuery(t);else if(Ve.isObject(t))try{e=JSON.stringify(t)}catch{return"Failed to stringify response object"}else return"Cannot read body of type "+typeof t;return JDe(e)}function Xse(t){return new Promise(function(e){var i=setTimeout(function(){e("Timeout while trying to read body")},500);try{t.clone().text().then(function(n){clearTimeout(i),e(JDe(n))},function(n){clearTimeout(i),e("Failed to read body: "+String(n))})}catch(n){clearTimeout(i),e("Failed to read body: "+String(n))}})}function gee(t,e,i,n,r,o){if(o===void 0&&(o=0),o>10)return xD.error("Cannot find performance entry"),Promise.resolve(null);var a=t.performance.getEntriesByName(i),s=Pit(a,function(l){return GK(l)&&l.initiatorType===e&&(!n||l.startTime>=n)&&(!r||l.startTime<=r)});return s?Promise.resolve(s):new Promise(function(l){setTimeout(l,50*o)}).then(function(){return gee(t,e,i,n,r,o+1)})}function Tit(t,e,i){if(!i.initiatorTypes.includes("xmlhttprequest"))return function(){};var n=ZDe(e.XMLHttpRequest.prototype,"open",function(r){return function(o,a,s,l,u){s===void 0&&(s=!0);var c=this,d=new Request(a,{method:o}),f={},h,p,g={},v=c.setRequestHeader.bind(c);c.setRequestHeader=function(m,b){return X5("request",i.recordHeaders,m)&&(g[m]=b),v(m,b)},f.requestHeaders=g;var y=c.send.bind(c);c.send=function(m){return K5("request",i.recordBodyUrls,d.url)&&(f.requestBody=qse(m)),h=e.performance.now(),y(m)},c.addEventListener("readystatechange",function(){if(c.readyState===c.DONE){p=e.performance.now();var m={},b=c.getAllResponseHeaders();if(b){var S=b.trim().split(/[\r\n]+/);S.forEach(function(_){if(_){var C=_.indexOf(": ");if(C!==-1){var P=_.substring(0,C),x=_.substring(C+2);P&&X5("response",i.recordHeaders,P)&&(m[P]=x)}}})}f.responseHeaders=m,K5("response",i.recordBodyUrls,d.url)&&(f.responseBody=qse(c.response)),gee(e,"xmlhttprequest",d.url,h,p).then(function(_){if(!_){xD.error("Failed to get performance entry for XHR request to "+d.url);return}var C={url:_.name,method:d.method,initiatorType:_.initiatorType,status:c.status,startTime:Math.round(_.startTime),endTime:Math.round(_.responseEnd),timeOrigin:q5(e),requestHeaders:f.requestHeaders,requestBody:f.requestBody,responseHeaders:f.responseHeaders,responseBody:f.responseBody};t({requests:[C]})}).catch(function(_){xD.error("Error recording XHR request to "+d.url+": "+String(_))})}}),r.call(c,o,a,s,l,u)}});return function(){n()}}function xit(t,e,i){if(!i.initiatorTypes.includes("fetch"))return function(){};var n=ZDe(e,"fetch",function(r){return function(){var o=new Request(arguments[0],arguments[1]),a,s={},l,u,c,d=Promise.resolve(void 0),f=Promise.resolve(void 0);try{var h={};o.headers.forEach(function(p,g){X5("request",i.recordHeaders,g)&&(h[g]=p)}),s.requestHeaders=h,K5("request",i.recordBodyUrls,o.url)&&(d=Xse(o).then(function(p){s.requestBody=p})),l=e.performance.now(),c=r.apply(e,arguments).then(function(p){a=p,u=e.performance.now();var g={};return a.headers.forEach(function(v,y){X5("response",i.recordHeaders,y)&&(g[y]=v)}),s.responseHeaders=g,K5("response",i.recordBodyUrls,o.url)&&(f=Xse(a).then(function(v){s.responseBody=v})),a})}catch(p){c=Promise.reject(p)}return Promise.all([d,f,c]).then(function(){return gee(e,"fetch",o.url,l,u)}).then(function(p){if(!p){xD.error("Failed to get performance entry for fetch request to "+o.url);return}var g={url:p.name,method:o.method,initiatorType:p.initiatorType,status:a?a.status:void 0,startTime:Math.round(p.startTime),endTime:Math.round(p.responseEnd),timeOrigin:q5(e),requestHeaders:s.requestHeaders,requestBody:s.requestBody,responseHeaders:s.responseHeaders,responseBody:s.responseBody};t({requests:[g]})}).catch(function(p){xD.error("Error recording fetch request to "+o.url+": "+String(p))}),c}});return function(){n()}}function Eit(t,e,i){if(!("performance"in e))return function(){};var n=Object.assign({},R8.recordHeaders,i.recordHeaders||{}),r=Object.assign({},R8.recordBodyUrls,i.recordBodyUrls||{});i=Object.assign({},i,{recordHeaders:n,recordBodyUrls:r});var o=Object.assign({},R8,i),a=function(c){var d=c.requests.filter(function(f){var h=$5(f.url,o.ignoreRequestUrls||[]);return!h&&!o.ignoreRequestFn(f)});(d.length>0||c.isInitial)&&t(Object.assign({},c,{requests:d}))},s=Cit(a,e,o),l=Tit(a,e,o),u=xit(a,e,o);return function(){s(),l(),u()}}var wit="rrweb/network@1.mp",Ait=function(t){return{name:wit,observer:Eit,options:t}},UL=UP("recorder"),Oit=kr.CompressionStream,Dit={batch_size:1e3,batch_flush_interval_ms:10*1e3,batch_request_timeout_ms:90*1e3,batch_autostart:!0},Rit=new Set([wn.MouseMove,wn.MouseInteraction,wn.Scroll,wn.ViewportResize,wn.Input,wn.TouchMove,wn.MediaInteraction,wn.Drag,wn.Selection]);function Mit(t){return t.type===Ro.IncrementalSnapshot&&Rit.has(t.data.source)}var iu=function(t){this._mixpanel=t.mixpanelInstance,this._onIdleTimeout=t.onIdleTimeout||gP,this._onMaxLengthReached=t.onMaxLengthReached||gP,this._onBatchSent=t.onBatchSent||gP,this._rrwebRecord=t.rrwebRecord||null,this._stopRecording=null,this.replayId=t.replayId,this.batchStartUrl=t.batchStartUrl||null,this.replayStartUrl=t.replayStartUrl||null,this.idleExpires=t.idleExpires||null,this.maxExpires=t.maxExpires||null,this.replayStartTime=t.replayStartTime||null,this.lastEventTimestamp=t.lastEventTimestamp||null,this.seqNo=t.seqNo||0,this.idleTimeoutId=null,this.maxTimeoutId=null,this.recordMaxMs=Pj,this.recordMinMs=0;var e=d3(t.sharedLockStorage,!0)&&!this.getConfig("disable_persistence");this.batcherKey="__mprec_"+this.getConfig("name")+"_"+this.getConfig("token")+"_"+this.replayId,this.queueStorage=new Hv(FDe),this.batcher=new Lg(this.batcherKey,{errorReporter:this.reportError.bind(this),flushOnlyOnInterval:!0,libConfig:Dit,sendRequestFunc:this.flushEventsWithOptOut.bind(this),queueStorage:this.queueStorage,sharedLockStorage:t.sharedLockStorage,usePersistence:e,stopAllBatchingFunc:this.stopRecording.bind(this),enqueueThrottleMs:Jrt,sharedLockTimeoutMS:10*1e3})};iu.prototype.getUserIdInfo=function(){if(this.finalFlushUserIdInfo)return this.finalFlushUserIdInfo;var t={distinct_id:String(this._mixpanel.get_distinct_id())},e=this._mixpanel.get_property("$device_id");e&&(t.$device_id=e);var i=this._mixpanel.get_property("$user_id");return i&&(t.$user_id=i),t};iu.prototype.unloadPersistedData=function(){return this.batcher.stop(),this.queueStorage.init().catch((function(){this.reportError("Error initializing IndexedDB storage for unloading persisted data.")}).bind(this)).then((function(){return this.getDurationMs()<this._getRecordMinMs()?this.queueStorage.removeItem(this.batcherKey):this.batcher.flush().then((function(){return this.queueStorage.removeItem(this.batcherKey)}).bind(this))}).bind(this))};iu.prototype.getConfig=function(t){return this._mixpanel.get_config(t)};iu.prototype.get_config=function(t){return this.getConfig(t)};iu.prototype.startRecording=function(t){if(this._rrwebRecord===null){this.reportError("rrweb record function not provided. ");return}if(this._stopRecording!==null){UL.log("Recording already in progress, skipping startRecording.");return}this.recordMaxMs=this.getConfig("record_max_ms"),this.recordMaxMs>Pj&&(this.recordMaxMs=Pj,UL.critical("record_max_ms cannot be greater than "+Pj+"ms. Capping value.")),this.maxExpires||(this.maxExpires=new Date().getTime()+this.recordMaxMs),this.recordMinMs=this._getRecordMinMs(),this.replayStartTime||(this.replayStartTime=new Date().getTime(),this.batchStartUrl=Ve.info.currentUrl(),this.replayStartUrl=Ve.info.currentUrl()),t||this.recordMinMs>0?this.batcher.stop():this.batcher.start();var e=(function(){clearTimeout(this.idleTimeoutId);var l=this.getConfig("record_idle_timeout_ms");this.idleTimeoutId=setTimeout(this._onIdleTimeout,l),this.idleExpires=new Date().getTime()+l}).bind(this);e();var i=this.getConfig("record_block_selector");(i===""||i===null)&&(i=void 0);var n=mit(this._mixpanel),r=[];if(this.getConfig("record_network")){var o=this.getConfig("record_network_options")||{},a=(o.ignoreRequestUrls||[]).slice();a.push(this._getApiRoute()),o.ignoreRequestUrls=a,r.push(Ait(o))}this.getConfig("record_console")&&r.push(Ert({stringifyOptions:{stringLengthLimit:1e3,numOfKeysLimit:50,depthOfLimit:2}}));try{this._stopRecording=this._rrwebRecord({emit:(function(l){if(this.idleExpires&&this.idleExpires<l.timestamp){this._onIdleTimeout();return}Mit(l)&&(this.batcher.stopped&&new Date().getTime()-this.replayStartTime>=this.recordMinMs&&this.batcher.start(),e()),this.__enqueuePromise=this.batcher.enqueue(l),(this.lastEventTimestamp===null||l.timestamp>this.lastEventTimestamp)&&(this.lastEventTimestamp=l.timestamp)}).bind(this),blockClass:this.getConfig("record_block_class"),blockSelector:i,collectFonts:this.getConfig("record_collect_fonts"),dataURLOptions:{type:"image/webp",quality:.6},maskAllInputs:!0,maskTextSelector:"*",maskInputFn:this._getMaskFn(bit,n),maskTextFn:this._getMaskFn(Sit,n),recordCanvas:this.getConfig("record_canvas"),sampling:{canvas:15},plugins:r})}catch(l){this.reportError("Unexpected error when starting rrweb recording.",l)}if(typeof this._stopRecording!="function"){this.reportError("rrweb failed to start, skipping this recording."),this._stopRecording=null,this.stopRecording();return}var s=this.maxExpires-new Date().getTime();this.maxTimeoutId=setTimeout(this._onMaxLengthReached.bind(this),s)};iu.prototype.stopRecording=function(t){if(this.finalFlushUserIdInfo=this.getUserIdInfo(),!this.isRrwebStopped()){try{this._stopRecording()}catch(i){this.reportError("Error with rrweb stopRecording",i)}this._stopRecording=null}var e;return this.batcher.stopped?e=this.batcher.clear():t||(e=this.batcher.flush()),this.batcher.stop(),clearTimeout(this.idleTimeoutId),clearTimeout(this.maxTimeoutId),e};iu.prototype.isRrwebStopped=function(){return this._stopRecording===null};iu.prototype.flushEventsWithOptOut=function(t,e,i){var n=(function(r){r===0&&(this.stopRecording(),i({error:"Tracking has been opted out, stopping recording."}))}).bind(this);this._flushEvents(t,e,i,n)};iu.prototype.serialize=function(){var t;try{t=this._mixpanel.get_tab_id()}catch(e){this.reportError("Error getting tab ID for serialization ",e),t=null}return{replayId:this.replayId,seqNo:this.seqNo,replayStartTime:this.replayStartTime,batchStartUrl:this.batchStartUrl,replayStartUrl:this.replayStartUrl,lastEventTimestamp:this.lastEventTimestamp,idleExpires:this.idleExpires,maxExpires:this.maxExpires,tabId:t}};iu.deserialize=function(t,e){var i=new iu(Ve.extend({},e,{replayId:t.replayId,batchStartUrl:t.batchStartUrl,replayStartUrl:t.replayStartUrl,idleExpires:t.idleExpires,maxExpires:t.maxExpires,replayStartTime:t.replayStartTime,lastEventTimestamp:t.lastEventTimestamp,seqNo:t.seqNo,sharedLockStorage:e.sharedLockStorage}));return i};iu.prototype._getApiRoute=function(){return this.getConfig("api_routes").record};iu.prototype._sendRequest=function(t,e,i,n){var r=(function(a,s){a.status===200&&this.replayId===t&&(this.seqNo++,this.batchStartUrl=Ve.info.currentUrl()),this._onBatchSent(),n({status:0,httpStatusCode:a.status,responseBody:s,retryAfter:a.headers.get("Retry-After")})}).bind(this),o=this._mixpanel.get_api_host&&this._mixpanel.get_api_host("record")||this.getConfig("api_host");kr.fetch(o+"/"+this._getApiRoute()+"?"+new URLSearchParams(e),{method:"POST",headers:{Authorization:"Basic "+btoa(this.getConfig("token")+":"),"Content-Type":"application/octet-stream"},body:i}).then(function(a){a.json().then(function(s){r(a,s)}).catch(function(s){n({error:s})})}).catch(function(a){n({error:a,httpStatusCode:0})})};iu.prototype._flushEvents=zP(function(t,e,i){var n=t.length;if(n>0){for(var r=this.replayId,o=1/0,a=-1/0,s=!1,l=0;l<n;l++)o=Math.min(o,t[l].timestamp),a=Math.max(a,t[l].timestamp),t[l].type===Ro.FullSnapshot&&(s=!0);if(this.seqNo===0){if(!s){i({error:"First batch does not contain a full snapshot. Aborting recording."}),this.stopRecording(!0);return}this.replayStartTime=o}else this.replayStartTime||(this.reportError("Replay start time not set but seqNo is not 0. Using current batch start time as a fallback."),this.replayStartTime=o);var u=a-this.replayStartTime,c={$current_url:this.batchStartUrl,$lib_version:Dh.LIB_VERSION,batch_start_time:o/1e3,mp_lib:"web",replay_id:r,replay_length_ms:u,replay_start_time:this.replayStartTime/1e3,replay_start_url:this.replayStartUrl,seq:this.seqNo},d=JSON.stringify(t);if(Object.assign(c,this.getUserIdInfo()),Vrt(By,cS.vendor,nj)){var f=new Blob([d],{type:"application/json"}).stream(),h=f.pipeThrough(new Oit("gzip"));new Response(h).blob().then((function(p){c.format="gzip",this._sendRequest(r,c,p,i)}).bind(this))}else c.format="body",this._sendRequest(r,c,d,i)}});iu.prototype.reportError=function(t,e){UL.error.apply(UL.error,arguments);try{!e&&!(t instanceof Error)&&(t=new Error(t)),this.getConfig("error_reporter")(t,e)}catch(i){UL.error(i)}};iu.prototype.getDurationMs=function(){return this.replayStartTime===null?0:this.lastEventTimestamp===null?new Date().getTime()-this.replayStartTime:this.lastEventTimestamp-this.replayStartTime};iu.prototype._getRecordMinMs=function(){var t=this.getConfig("record_min_ms");return t>T8?(UL.critical("record_min_ms cannot be greater than "+T8+"ms. Capping value."),T8):t};iu.prototype._getMaskFn=function(t,e){return(function(i,n){if(!i.trim().length)return"";var r=!0;try{r=t(n,e)}catch(a){this.reportError("Error checking if text should be masked, defaulting to masked",a)}if(r){var o=Math.min(i.length,1e4);return"*".repeat(o)}else return i}).bind(this)};var IS=function(t){this.idb=new Hv(lee),this.errorReporter=t.errorReporter,this.mixpanelInstance=t.mixpanelInstance,this.sharedLockStorage=t.sharedLockStorage};IS.prototype.isPersistenceEnabled=function(){return!this.mixpanelInstance.get_config("disable_persistence")};IS.prototype.handleError=function(t){this.errorReporter("IndexedDB error: ",t)};IS.prototype.setActiveRecording=function(t){if(!this.isPersistenceEnabled())return Hn.resolve();var e=t.tabId;return e?this.idb.init().then((function(){return this.idb.setItem(e,t)}).bind(this)).catch(this.handleError.bind(this)):(console.warn("No tab ID is set, cannot persist recording metadata."),Hn.resolve())};IS.prototype.getActiveRecording=function(){return this.isPersistenceEnabled()?this.idb.init().then((function(){return this.idb.getItem(this.mixpanelInstance.get_tab_id())}).bind(this)).then((function(t){return fee(t)?null:t}).bind(this)).catch(this.handleError.bind(this)):Hn.resolve(null)};IS.prototype.clearActiveRecording=function(){return this.isPersistenceEnabled()?this.markActiveRecordingExpired():this.deleteActiveRecording()};IS.prototype.markActiveRecordingExpired=function(){return this.getActiveRecording().then((function(t){if(t)return t.maxExpires=0,this.setActiveRecording(t)}).bind(this)).catch(this.handleError.bind(this))};IS.prototype.deleteActiveRecording=function(){return this.idb.isInitialized()?this.idb.removeItem(this.mixpanelInstance.get_tab_id()).catch(this.handleError.bind(this)):Hn.resolve()};IS.prototype.flushInactiveRecordings=function(){return this.isPersistenceEnabled()?this.idb.init().then((function(){return this.idb.getAll()}).bind(this)).then((function(t){var e=t.filter(function(i){return fee(i)}).map((function(i){var n=iu.deserialize(i,{mixpanelInstance:this.mixpanelInstance,sharedLockStorage:this.sharedLockStorage});return n.unloadPersistedData().then((function(){return this.idb.removeItem(i.tabId)}).bind(this)).catch(this.handleError.bind(this))}).bind(this));return Hn.all(e)}).bind(this)).catch(this.handleError.bind(this)):Hn.resolve([])};var Tj=UP("recorder"),Pm=function(t,e,i){this.mixpanelInstance=t,this.rrwebRecord=e||BP,this.sharedLockStorage=i,this.recordingRegistry=new IS({mixpanelInstance:this.mixpanelInstance,errorReporter:Tj.error,sharedLockStorage:i}),this._flushInactivePromise=this.recordingRegistry.flushInactiveRecordings(),this.activeRecording=null,this.stopRecordingInProgress=!1};Pm.prototype.startRecording=function(t){if(t=t||{},this.activeRecording&&!this.activeRecording.isRrwebStopped()){Tj.log("Recording already in progress, skipping startRecording.");return}var e=(function(){Tj.log("Idle timeout reached, restarting recording."),this.resetRecording()}).bind(this),i=(function(){Tj.log("Max recording length reached, stopping recording."),this.resetRecording()}).bind(this),n=(function(){this.recordingRegistry.setActiveRecording(this.activeRecording.serialize()),this.__flushPromise=this.activeRecording.batcher._flushPromise}).bind(this),r={mixpanelInstance:this.mixpanelInstance,onBatchSent:n,onIdleTimeout:e,onMaxLengthReached:i,replayId:Ve.UUID(),rrwebRecord:this.rrwebRecord,sharedLockStorage:this.sharedLockStorage};return t.activeSerializedRecording?this.activeRecording=iu.deserialize(t.activeSerializedRecording,r):this.activeRecording=new iu(r),this.activeRecording.startRecording(t.shouldStopBatcher),this.recordingRegistry.setActiveRecording(this.activeRecording.serialize())};Pm.prototype.stopRecording=function(){return this.stopRecordingInProgress=!0,this._stopCurrentRecording(!1,!0).then((function(){return this.recordingRegistry.clearActiveRecording()}).bind(this)).then((function(){this.stopRecordingInProgress=!1}).bind(this))};Pm.prototype.pauseRecording=function(){return this._stopCurrentRecording(!1)};Pm.prototype._stopCurrentRecording=function(t,e){if(this.activeRecording){var i=this.activeRecording.stopRecording(t);return e&&(this.activeRecording=null),i}return Hn.resolve()};Pm.prototype.resumeRecording=function(t){return this.activeRecording&&this.activeRecording.isRrwebStopped()?(this.activeRecording.startRecording(!1),Hn.resolve(null)):this.recordingRegistry.getActiveRecording().then((function(e){return e&&!this.stopRecordingInProgress?this.startRecording({activeSerializedRecording:e}):t?this.startRecording({shouldStopBatcher:!1}):(Tj.log("No resumable recording found."),null)}).bind(this))};Pm.prototype.resetRecording=function(){this.stopRecording(),this.startRecording({shouldStopBatcher:!0})};Pm.prototype.isRecording=function(){return this.activeRecording&&!this.activeRecording.isRrwebStopped()};Pm.prototype.getActiveReplayId=function(){return this.isRecording()?this.activeRecording.replayId:null};Object.defineProperty(Pm.prototype,"replayId",{get:function(){return this.getActiveReplayId()}});kr[VX]=Pm;function Lit(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var BU={exports:{}},kit=BU.exports,Kse;function Iit(){return Kse||(Kse=1,(function(t,e){(function(i,n){t.exports=n()})(kit,function(){Array.isArray||(Array.isArray=function(o){return Object.prototype.toString.call(o)==="[object Array]"});function i(o){for(var a=[],s=0,l=o.length;s<l;s++)a.indexOf(o[s])===-1&&a.push(o[s]);return a}var n={},r={"==":function(o,a){return o==a},"===":function(o,a){return o===a},"!=":function(o,a){return o!=a},"!==":function(o,a){return o!==a},">":function(o,a){return o>a},">=":function(o,a){return o>=a},"<":function(o,a,s){return s===void 0?o<a:o<a&&a<s},"<=":function(o,a,s){return s===void 0?o<=a:o<=a&&a<=s},"!!":function(o){return n.truthy(o)},"!":function(o){return!n.truthy(o)},"%":function(o,a){return o%a},log:function(o){return console.log(o),o},in:function(o,a){return!a||typeof a.indexOf>"u"?!1:a.indexOf(o)!==-1},cat:function(){return Array.prototype.join.call(arguments,"")},substr:function(o,a,s){if(s<0){var l=String(o).substr(a);return l.substr(0,l.length+s)}return String(o).substr(a,s)},"+":function(){return Array.prototype.reduce.call(arguments,function(o,a){return parseFloat(o,10)+parseFloat(a,10)},0)},"*":function(){return Array.prototype.reduce.call(arguments,function(o,a){return parseFloat(o,10)*parseFloat(a,10)})},"-":function(o,a){return a===void 0?-o:o-a},"/":function(o,a){return o/a},min:function(){return Math.min.apply(this,arguments)},max:function(){return Math.max.apply(this,arguments)},merge:function(){return Array.prototype.reduce.call(arguments,function(o,a){return o.concat(a)},[])},var:function(o,a){var s=a===void 0?null:a,l=this;if(typeof o>"u"||o===""||o===null)return l;for(var u=String(o).split("."),c=0;c<u.length;c++)if(l==null||(l=l[u[c]],l===void 0))return s;return l},missing:function(){for(var o=[],a=Array.isArray(arguments[0])?arguments[0]:arguments,s=0;s<a.length;s++){var l=a[s],u=n.apply({var:l},this);(u===null||u==="")&&o.push(l)}return o},missing_some:function(o,a){var s=n.apply({missing:a},this);return a.length-s.length>=o?[]:s}};return n.is_logic=function(o){return typeof o=="object"&&o!==null&&!Array.isArray(o)&&Object.keys(o).length===1},n.truthy=function(o){return Array.isArray(o)&&o.length===0?!1:!!o},n.get_operator=function(o){return Object.keys(o)[0]},n.get_values=function(o){return o[n.get_operator(o)]},n.apply=function(o,a){if(Array.isArray(o))return o.map(function(v){return n.apply(v,a)});if(!n.is_logic(o))return o;var s=n.get_operator(o),l=o[s],u,c,d,f,h;if(Array.isArray(l)||(l=[l]),s==="if"||s=="?:"){for(u=0;u<l.length-1;u+=2)if(n.truthy(n.apply(l[u],a)))return n.apply(l[u+1],a);return l.length===u+1?n.apply(l[u],a):null}else if(s==="and"){for(u=0;u<l.length;u+=1)if(c=n.apply(l[u],a),!n.truthy(c))return c;return c}else if(s==="or"){for(u=0;u<l.length;u+=1)if(c=n.apply(l[u],a),n.truthy(c))return c;return c}else{if(s==="filter")return f=n.apply(l[0],a),d=l[1],Array.isArray(f)?f.filter(function(v){return n.truthy(n.apply(d,v))}):[];if(s==="map")return f=n.apply(l[0],a),d=l[1],Array.isArray(f)?f.map(function(v){return n.apply(d,v)}):[];if(s==="reduce")return f=n.apply(l[0],a),d=l[1],h=typeof l[2]<"u"?n.apply(l[2],a):null,Array.isArray(f)?f.reduce(function(v,y){return n.apply(d,{current:y,accumulator:v})},h):h;if(s==="all"){if(f=n.apply(l[0],a),d=l[1],!Array.isArray(f)||!f.length)return!1;for(u=0;u<f.length;u+=1)if(!n.truthy(n.apply(d,f[u])))return!1;return!0}else if(s==="none"){if(f=n.apply(l[0],a),d=l[1],!Array.isArray(f)||!f.length)return!0;for(u=0;u<f.length;u+=1)if(n.truthy(n.apply(d,f[u])))return!1;return!0}else if(s==="some"){if(f=n.apply(l[0],a),d=l[1],!Array.isArray(f)||!f.length)return!1;for(u=0;u<f.length;u+=1)if(n.truthy(n.apply(d,f[u])))return!0;return!1}}if(l=l.map(function(v){return n.apply(v,a)}),r.hasOwnProperty(s)&&typeof r[s]=="function")return r[s].apply(a,l);if(s.indexOf(".")>0){var p=String(s).split("."),g=r;for(u=0;u<p.length;u++){if(!g.hasOwnProperty(p[u]))throw new Error("Unrecognized operation "+s+" (failed at "+p.slice(0,u+1).join(".")+")");g=g[p[u]]}return g.apply(a,l)}throw new Error("Unrecognized operation "+s)},n.uses_data=function(o){var a=[];if(n.is_logic(o)){var s=n.get_operator(o),l=o[s];Array.isArray(l)||(l=[l]),s==="var"?a.push(l[0]):l.forEach(function(u){a.push.apply(a,n.uses_data(u))})}return i(a)},n.add_operation=function(o,a){r[o]=a},n.rm_operation=function(o){delete r[o]},n.rule_like=function(o,a){if(a===o||a==="@")return!0;if(a==="number")return typeof o=="number";if(a==="string")return typeof o=="string";if(a==="array")return Array.isArray(o)&&!n.is_logic(o);if(n.is_logic(a)){if(n.is_logic(o)){var s=n.get_operator(a),l=n.get_operator(o);if(s==="@"||s===l)return n.rule_like(n.get_values(o,!1),n.get_values(a,!1))}return!1}if(Array.isArray(a))if(Array.isArray(o)){if(a.length!==o.length)return!1;for(var u=0;u<a.length;u+=1)if(!n.rule_like(o[u],a[u]))return!1;return!0}else return!1;return!1},n})})(BU)),BU.exports}var Nit=Iit(),Fit=Lit(Nit),Bit=function(t,e,i){if(t!==i.event_name)return{matches:!1};var n=i.property_filters,r=!0;if(n&&!Ve.isEmptyObject(n))try{r=Fit.apply(n,e||{})}catch(o){return{matches:!1,error:o.toString()}}return{matches:r}},QDe={};QDe.eventMatchesCriteria=Bit;kr[yv]=Promise.resolve(QDe);var jit=30,Vit=1e3,Hit=4,Uit=!1;function eRe(){this.clicks=[]}eRe.prototype.isRageClick=function(t,e){e=e||{};var i=e.threshold_px||jit,n=e.timeout_ms||Vit,r=e.click_count||Hit,o=e.interactive_elements_only||Uit;if(o){var a=XDe(t);if(!a||YDe(a))return!1}var s=Date.now(),l=t.pageX,u=t.pageY,c=this.clicks[this.clicks.length-1];if(c&&s-c.timestamp<n&&Math.sqrt(Math.pow(l-c.x,2)+Math.pow(u-c.y,2))<i){if(this.clicks.push({x:l,y:u,timestamp:s}),this.clicks.length>=r)return this.clicks=[],!0}else this.clicks=[{x:l,y:u,timestamp:s}];return!1};function pI(t,e){this.changeCallback=t||function(){},this.observerConfig=e,this.observedShadowRoots=null,this.shadowObservers=[]}pI.prototype.getEventTarget=function(t){if(this.observedShadowRoots)return XDe(t)};pI.prototype.observeFromEvent=function(t){if(this.observedShadowRoots)for(var e=qDe(t),i=0;i<e.length;i++){var n=e[i];n&&n.shadowRoot&&this.observeShadowRoot(n.shadowRoot)}};pI.prototype.observeShadowRoot=function(t){if(!(!this.observedShadowRoots||this.observedShadowRoots.has(t))){var e=this;try{this.observedShadowRoots.add(t);var i=new window.MutationObserver(function(){e.changeCallback()});i.observe(t,this.observerConfig),this.shadowObservers.push(i)}catch(n){hs.critical("Error while observing shadow root",n)}}};pI.prototype.start=function(){if(!this.observedShadowRoots){if(!fit()){hs.critical("Shadow DOM observation unavailable: WeakSet not supported");return}this.observedShadowRoots=new WeakSet}};pI.prototype.stop=function(){if(this.observedShadowRoots){for(var t=0;t<this.shadowObservers.length;t++)try{this.shadowObservers[t].disconnect()}catch(e){hs.critical("Error while disconnecting shadow DOM observer",e)}this.shadowObservers=[],this.observedShadowRoots=null}};var zit=500,$it=[f3,Qrt,G5,eit,tit],Wit=[s6],Git=[UK],Zse={characterData:!0,childList:!0,subtree:!0,attributes:!0,attributeFilter:["style","class","hidden","checked","selected","value","display","visibility"]};function Cm(t){this.eventListeners=[],this.mutationObserver=null,this.shadowDOMObserver=null,this.isTracking=!1,this.lastChangeEventTimestamp=0,this.pendingClicks=[],this.onDeadClickCallback=t,this.processingActive=!1,this.processingTimeout=null}Cm.prototype.addClick=function(t){var e=this.shadowDOMObserver&&this.shadowDOMObserver.getEventTarget(t);return e||(e=t.target||t.srcElement),!e||YDe(e)?!1:(this.shadowDOMObserver&&this.shadowDOMObserver.observeFromEvent(t),this.pendingClicks.push({element:e,event:t,timestamp:Date.now()}),!0)};Cm.prototype.trackClick=function(t,e){if(!this.isTracking)return!1;var i=this.addClick(t);return i&&this.triggerProcessing(e),i};Cm.prototype.getDeadClicks=function(t){if(this.pendingClicks.length===0)return[];var e=t.timeout_ms,i=Date.now(),n=this.pendingClicks.slice();this.pendingClicks=[];for(var r=[],o=0;o<n.length;o++){var a=n[o];i-a.timestamp>=e?this.hasChangesAfter(a.timestamp)||r.push(a):this.pendingClicks.push(a)}return r};Cm.prototype.hasChangesAfter=function(t){return this.lastChangeEventTimestamp>=t-100};Cm.prototype.recordChangeEvent=function(){this.lastChangeEventTimestamp=Date.now()};Cm.prototype.triggerProcessing=function(t){this.processingActive||(this.processingActive=!0,this.processRecursively(t))};Cm.prototype.processRecursively=function(t){if(!this.isTracking||!this.onDeadClickCallback){this.processingActive=!1;return}var e=t.timeout_ms,i=this;this.processingTimeout=setTimeout(function(){if(i.processingActive){for(var n=i.getDeadClicks(t),r=0;r<n.length;r++)i.onDeadClickCallback(n[r].event);i.pendingClicks.length>0?i.processRecursively(t):i.processingActive=!1}},e)};Cm.prototype.startTracking=function(){if(!this.isTracking){this.isTracking=!0;var t=this;$it.forEach(function(i){var n=function(){t.recordChangeEvent()};document.addEventListener(i,n,{capture:!0,passive:!0}),t.eventListeners.push({target:document,event:i,handler:n,options:{capture:!0,passive:!0}})}),Git.forEach(function(i){var n=function(){t.recordChangeEvent()};window.addEventListener(i,n),t.eventListeners.push({target:window,event:i,handler:n})}),Wit.forEach(function(i){var n=function(){t.recordChangeEvent()};window.addEventListener(i,n,{passive:!0}),t.eventListeners.push({target:window,event:i,handler:n,options:{passive:!0}})});var e=function(){t.recordChangeEvent()};if(document.addEventListener("selectionchange",e),t.eventListeners.push({target:document,event:"selectionchange",handler:e}),window.MutationObserver)try{this.mutationObserver=new window.MutationObserver(function(){t.recordChangeEvent()}),this.mutationObserver.observe(document.body||document.documentElement,Zse)}catch(i){hs.critical("Error while setting up mutation observer",i)}if(window.customElements)try{this.shadowDOMObserver=new pI(function(){t.recordChangeEvent()},Zse),this.shadowDOMObserver.start()}catch(i){hs.critical("Error while setting up shadow DOM observer",i),this.shadowDOMObserver=null}}};Cm.prototype.stopTracking=function(){if(this.isTracking){this.isTracking=!1,this.pendingClicks=[],this.lastChangeEventTimestamp=0,this.processingActive=!1,this.processingTimeout&&(clearTimeout(this.processingTimeout),this.processingTimeout=null);for(var t=0;t<this.eventListeners.length;t++){var e=this.eventListeners[t];try{e.target.removeEventListener(e.event,e.handler,e.options)}catch(i){hs.critical("Error while removing event listener",i)}}if(this.eventListeners=[],this.mutationObserver){try{this.mutationObserver.disconnect()}catch(i){hs.critical("Error while disconnecting mutation observer",i)}this.mutationObserver=null}if(this.shadowDOMObserver){try{this.shadowDOMObserver.stop()}catch(i){hs.critical("Error while stopping shadow DOM observer",i)}this.shadowDOMObserver=null}}};var tRe="autocapture",Yit="track_pageview",rRe="full-url",qit="url-with-path-and-query-string",Xit="url-with-path",Kit="allow_element_callback",iRe="allow_selectors",nRe="allow_url_regexes",oRe="block_attrs",aRe="block_element_callback",sRe="block_selectors",lRe="block_url_regexes",uRe="capture_extra_attrs",cRe="capture_text_content",dRe="scroll_capture_all",fRe="scroll_depth_percent_checkpoints",Z5="click",J5="dead_click",YK="input",hRe="pageview",Q5="rage_click",qK="scroll",l6="page_leave",XK="submit",Fu={};Fu[iRe]=[];Fu[nRe]=[];Fu[oRe]=[];Fu[aRe]=null;Fu[sRe]=[];Fu[lRe]=[];Fu[uRe]=[];Fu[cRe]=!1;Fu[dRe]=!1;Fu[fRe]=[25,50,75,100];Fu[Z5]=!0;Fu[J5]=!0;Fu[YK]=!0;Fu[hRe]=rRe;Fu[Q5]=!0;Fu[qK]=!0;Fu[l6]=!1;Fu[XK]=!0;var h3={$mp_autocapture:!0},pRe="$mp_click",gRe="$mp_dead_click",Zit="$mp_input_change",vRe="$mp_rage_click",Jit="$mp_scroll",Qit="$mp_submit",ent="$mp_page_leave",lu=function(t){this.mp=t,this.maxScrollViewDepth=0,this.hasTrackedScrollSession=!1,this.previousScrollHeight=0};lu.prototype.init=function(){if(!dit()){hs.critical("Autocapture unavailable: missing required DOM APIs");return}this.initPageListeners(),this.initPageviewTracking(),this.initClickTracking(),this.initDeadClickTracking(),this.initInputTracking(),this.initScrollTracking(),this.initSubmitTracking(),this.initRageClickTracking(),this.initPageLeaveTracking()};lu.prototype.getFullConfig=function(){var t=this.mp.get_config(tRe);return t?Ve.isObject(t)?Ve.extend({},Fu,t):Fu:{}};lu.prototype.getConfig=function(t){return this.getFullConfig()[t]};lu.prototype.currentUrlBlocked=function(){var t=Ve.info.currentUrl(),e=this.getConfig(nRe)||[];if(e.length)try{return!$5(t,e)}catch(n){return hs.critical("Error while checking block URL regexes: ",n),!0}var i=this.getConfig(lRe)||[];if(!i||!i.length)return!1;try{return $5(t,i)}catch(n){return hs.critical("Error while checking block URL regexes: ",n),!0}};lu.prototype.pageviewTrackingConfig=function(){return this.mp.get_config(tRe)?this.getConfig(hRe):this.mp.get_config(Yit)};lu.prototype.trackDomEvent=function(t,e){if(!this.currentUrlBlocked()){var i=this.mp.is_recording_heatmap_data()&&(e===pRe&&!this.getConfig(Z5)||e===vRe&&!this._getClickTrackingConfig(Q5)||e===gRe&&!this._getClickTrackingConfig(J5)),n=uit(t,{allowElementCallback:this.getConfig(Kit),allowSelectors:this.getConfig(iRe),blockAttrs:this.getConfig(oRe),blockElementCallback:this.getConfig(aRe),blockSelectors:this.getConfig(sRe),captureExtraAttrs:this.getConfig(uRe),captureTextContent:this.getConfig(cRe),capturedForHeatMap:i});n&&(Ve.extend(n,h3),this.mp.track(e,n))}};lu.prototype.initPageListeners=function(){if(kr.removeEventListener(Hse,this.listenerPopstate),kr.removeEventListener(UK,this.listenerHashchange),!(!this.pageviewTrackingConfig()&&!this.getConfig(l6)&&!this.mp.get_config("record_heatmap_data"))){this.listenerPopstate=function(){kr.dispatchEvent(new Event(sP))},this.listenerHashchange=function(){kr.dispatchEvent(new Event(sP))},kr.addEventListener(Hse,this.listenerPopstate),kr.addEventListener(UK,this.listenerHashchange);var t=kr.history.pushState;typeof t=="function"&&(kr.history.pushState=function(i,n,r){t.call(kr.history,i,n,r),kr.dispatchEvent(new Event(sP))});var e=kr.history.replaceState;typeof e=="function"&&(kr.history.replaceState=function(i,n,r){e.call(kr.history,i,n,r),kr.dispatchEvent(new Event(sP))})}};lu.prototype._getClickTrackingConfig=function(t){var e=this.getConfig(t);return e?e===!0?{}:typeof e=="object"?e:{}:null};lu.prototype._trackPageLeave=function(t,e,i){if(!this.hasTrackedScrollSession&&!(!this.getConfig(l6)&&!this.mp.is_recording_heatmap_data())){this.hasTrackedScrollSession=!0;var n=Math.max(Dn.documentElement.clientHeight,kr.innerHeight||0),r=Math.round(Math.max(this.maxScrollViewDepth-n,0)/(i-n)*100),o=Math.round(n/i*100);i<=n&&(r=100,o=100);var a=Ve.extend({$max_scroll_view_depth:this.maxScrollViewDepth,$max_scroll_percentage:r,$fold_line_percentage:o,$scroll_height:i,$event_type:t.type,$current_url:e||Ve.info.currentUrl(),$viewportHeight:n,$viewportWidth:Math.max(Dn.documentElement.clientWidth,kr.innerWidth||0),$captured_for_heatmap:this.mp.is_recording_heatmap_data()},h3);this.mp.track(ent,a,{transport:"sendBeacon"})}};lu.prototype._initScrollDepthTracking=function(){if(kr.removeEventListener(hee,this.listenerScrollDepth),kr.removeEventListener(s6,this.listenerScrollDepth),!!this.mp.get_config("record_heatmap_data")){hs.log("Initializing scroll depth tracking"),this.maxScrollViewDepth=Math.max(Dn.documentElement.clientHeight,kr.innerHeight||0);var t=(function(){if(!this.currentUrlBlocked()){var i=Math.max(Dn.documentElement.clientHeight,kr.innerHeight||0)+kr.scrollY;i>this.maxScrollViewDepth&&(this.maxScrollViewDepth=i),this.previousScrollHeight=Dn.body.scrollHeight}}).bind(this),e=GDe(t);this.listenerScrollDepth=e.listener,kr.addEventListener(e.eventType,this.listenerScrollDepth)}};lu.prototype.initClickTracking=function(){kr.removeEventListener(ES,this.listenerClick),!(!this.getConfig(Z5)&&!this.mp.get_config("record_heatmap_data"))&&(hs.log("Initializing click tracking"),this.listenerClick=(function(t){!this.getConfig(Z5)&&!this.mp.is_recording_heatmap_data()||this.trackDomEvent(t,pRe)}).bind(this),kr.addEventListener(ES,this.listenerClick))};lu.prototype.initDeadClickTracking=function(){var t=this._getClickTrackingConfig(J5);if(!t&&!this.mp.get_config("record_heatmap_data")){this.stopDeadClickTracking();return}hs.log("Initializing dead click tracking"),this._deadClickTracker||(this._deadClickTracker=new Cm((function(e){this.trackDomEvent(e,gRe)}).bind(this)),this._deadClickTracker.startTracking()),this.listenerDeadClick||(this.listenerDeadClick=(function(e){var i=this._getClickTrackingConfig(J5);if(!(!i&&!this.mp.is_recording_heatmap_data())&&!this.currentUrlBlocked()){var n=i||{};n.timeout_ms||(n.timeout_ms=zit),this._deadClickTracker.trackClick(e,n)}}).bind(this),kr.addEventListener(ES,this.listenerDeadClick))};lu.prototype.initInputTracking=function(){kr.removeEventListener(f3,this.listenerChange),this.getConfig(YK)&&(hs.log("Initializing input tracking"),this.listenerChange=(function(t){this.getConfig(YK)&&this.trackDomEvent(t,Zit)}).bind(this),kr.addEventListener(f3,this.listenerChange))};lu.prototype.initPageviewTracking=function(){if(kr.removeEventListener(sP,this.listenerLocationchange),!!this.pageviewTrackingConfig()){hs.log("Initializing pageview tracking");var t="",e=!1;this.currentUrlBlocked()||(e=this.mp.track_pageview(h3)),e&&(t=Ve.info.currentUrl()),this.listenerLocationchange=Rk((function(){if(!this.currentUrlBlocked()){var i=Ve.info.currentUrl(),n=!1,r=i.split("#")[0].split("?")[0]!==t.split("#")[0].split("?")[0],o=this.pageviewTrackingConfig();if(o===rRe?n=i!==t:o===qit?n=i.split("#")[0]!==t.split("#")[0]:o===Xit&&(n=r),n){var a=this.mp.track_pageview(h3);a&&(t=i),r&&(this.lastScrollCheckpoint=0,hs.log("Path change: re-initializing scroll depth checkpoints"))}}}).bind(this)),kr.addEventListener(sP,this.listenerLocationchange)}};lu.prototype.initRageClickTracking=function(){kr.removeEventListener(ES,this.listenerRageClick);var t=this._getClickTrackingConfig(Q5);!t&&!this.mp.get_config("record_heatmap_data")||(hs.log("Initializing rage click tracking"),this._rageClickTracker||(this._rageClickTracker=new eRe),this.listenerRageClick=(function(e){var i=this._getClickTrackingConfig(Q5);!i&&!this.mp.is_recording_heatmap_data()||this.currentUrlBlocked()||this._rageClickTracker.isRageClick(e,i)&&this.trackDomEvent(e,vRe)}).bind(this),kr.addEventListener(ES,this.listenerRageClick))};lu.prototype.initScrollTracking=function(){if(kr.removeEventListener(s6,this.listenerScroll),kr.removeEventListener(hee,this.listenerScroll),!!this.getConfig(qK)){hs.log("Initializing scroll tracking"),this.lastScrollCheckpoint=0;var t=(function(){if(this.getConfig(qK)&&!this.currentUrlBlocked()){var i=this.getConfig(dRe),n=(this.getConfig(fRe)||[]).slice().sort(function(c,d){return c-d}),r=kr.scrollY,o=Ve.extend({$scroll_top:r},h3);try{var a=Dn.body.scrollHeight,s=Math.round(r/(a-kr.innerHeight)*100);if(o.$scroll_height=a,o.$scroll_percentage=s,s>this.lastScrollCheckpoint)for(var l=0;l<n.length;l++){var u=n[l];s>=u&&this.lastScrollCheckpoint<u&&(o.$scroll_checkpoint=u,this.lastScrollCheckpoint=u,i=!0)}}catch(c){hs.critical("Error while calculating scroll percentage",c)}i&&this.mp.track(Jit,o)}}).bind(this),e=GDe(t);this.listenerScroll=e.listener,kr.addEventListener(e.eventType,this.listenerScroll)}};lu.prototype.initSubmitTracking=function(){kr.removeEventListener(G5,this.listenerSubmit),this.getConfig(XK)&&(hs.log("Initializing submit tracking"),this.listenerSubmit=(function(t){this.getConfig(XK)&&this.trackDomEvent(t,Qit)}).bind(this),kr.addEventListener(G5,this.listenerSubmit))};lu.prototype.initPageLeaveTracking=function(){if(Dn.removeEventListener(Use,this.listenerPageLeaveVisibilitychange),kr.removeEventListener(sP,this.listenerPageLeaveLocationchange),kr.removeEventListener(Vse,this.listenerPageLoad),!(!this.getConfig(l6)&&!this.mp.get_config("record_heatmap_data"))){hs.log("Initializing page visibility tracking."),this._initScrollDepthTracking();var t=Ve.info.currentUrl();this.listenerPageLoad=(function(){this.previousScrollHeight=Dn.body.scrollHeight}).bind(this),kr.addEventListener(Vse,this.listenerPageLoad),this.listenerPageLeaveLocationchange=Rk((function(e){if(!this.currentUrlBlocked()){var i=Ve.info.currentUrl(),n=i!==t;n&&(this._trackPageLeave(e,t,this.previousScrollHeight),t=i,this.maxScrollViewDepth=Math.max(Dn.documentElement.clientHeight,kr.innerHeight||0),this.previousScrollHeight=Dn.body.scrollHeight,this.hasTrackedScrollSession=!1)}}).bind(this)),kr.addEventListener(sP,this.listenerPageLeaveLocationchange),this.listenerPageLeaveVisibilitychange=(function(e){Dn.hidden&&this._trackPageLeave(e,t,this.previousScrollHeight)}).bind(this),Dn.addEventListener(Use,this.listenerPageLeaveVisibilitychange)}};lu.prototype.stopDeadClickTracking=function(){this.listenerDeadClick&&(kr.removeEventListener(ES,this.listenerDeadClick),this.listenerDeadClick=null),this._deadClickTracker&&(this._deadClickTracker.stopTracking(),this._deadClickTracker=null)};aee(lu);var yRe=function(t,e){return kr[yv]&&typeof kr[yv].then=="function"||(kr[yv]=new Promise(function(i){t(e,i)}).then(function(){var i=kr[yv];if(i&&typeof i.then=="function")return i;throw new Error("targeting failed to load")}).catch(function(i){throw delete kr[yv],i})),kr[yv]},Fl=UP("flags"),ez="flags",tz="context",KK={};KK[tz]={};var tnt=function(t,e){return t+":"+e},rnt=function(t){return t.split(":")[0]},Tn=function(t){this.fetch=kr.fetch,this.getFullApiRoute=t.getFullApiRoute,this.getMpConfig=t.getConfigFunc,this.setMpConfig=t.setConfigFunc,this.getMpProperty=t.getPropertyFunc,this.track=t.trackingFunc,this.loadExtraBundle=t.loadExtraBundle||function(){},this.targetingSrc=t.targetingSrc||""};Tn.prototype.init=function(){if(!this.minApisSupported()){Fl.critical("Feature Flags unavailable: missing minimum required APIs");return}this.flags=null,this.fetchFlags(),this.trackedFeatures=new Set,this.pendingFirstTimeEvents={},this.activatedFirstTimeEvents={}};Tn.prototype.getFullConfig=function(){var t=this.getMpConfig(ez);return t?Ve.isObject(t)?Ve.extend({},KK,t):KK:{}};Tn.prototype.getConfig=function(t){return this.getFullConfig()[t]};Tn.prototype.isSystemEnabled=function(){return!!this.getMpConfig(ez)};Tn.prototype.updateContext=function(t,e){if(!this.isSystemEnabled())return Fl.critical("Feature Flags not enabled, cannot update context"),Promise.resolve();var i=this.getMpConfig(ez);Ve.isObject(i)||(i={});var n=e&&e.replace?{}:this.getConfig(tz);return i[tz]=Ve.extend({},n,t),this.setMpConfig(ez,i),this.fetchFlags()};Tn.prototype.areFlagsReady=function(){return this.isSystemEnabled()||Fl.error("Feature Flags not enabled"),!!this.flags};Tn.prototype.fetchFlags=function(){if(!this.isSystemEnabled())return Promise.resolve();var t=this.getMpProperty("distinct_id"),e=this.getMpProperty("$device_id"),i=NDe();Fl.log("Fetching flags for distinct ID: "+t);var n=Ve.extend({distinct_id:t,device_id:e},this.getConfig(tz)),r=new URLSearchParams;r.set("context",JSON.stringify(n)),r.set("token",this.getMpConfig("token")),r.set("mp_lib","web"),r.set("$lib_version",Dh.LIB_VERSION);var o=this.getFullApiRoute()+"?"+r.toString();return this._fetchInProgressStartTime=Date.now(),this.fetchPromise=this.fetch.call(kr,o,{method:"GET",headers:{Authorization:"Basic "+btoa(this.getMpConfig("token")+":"),traceparent:i}}).then((function(a){return this.markFetchComplete(),a.json().then((function(s){var l=s.flags;if(!l)throw new Error("No flags in API response");var u=new Map,c={};Ve.each(l,function(f,h){var p=!1,g=h+":";if(Ve.each(this.activatedFirstTimeEvents,function(y,m){m.startsWith(g)&&(p=!0)}),p){var v=this.flags&&this.flags.get(h);v&&u.set(h,v)}else u.set(h,{key:f.variant_key,value:f.variant_value,experiment_id:f.experiment_id,is_experiment_active:f.is_experiment_active,is_qa_tester:f.is_qa_tester})},this);var d=s.pending_first_time_events;d&&d.length>0&&Ve.each(d,function(f){var h=f.flag_key,p=tnt(h,f.first_time_event_hash);this.activatedFirstTimeEvents[p]||(c[p]={flag_key:h,flag_id:f.flag_id,project_id:f.project_id,first_time_event_hash:f.first_time_event_hash,event_name:f.event_name,property_filters:f.property_filters,pending_variant:f.pending_variant})},this),this.activatedFirstTimeEvents&&Ve.each(this.activatedFirstTimeEvents,function(f,h){var p=rnt(h);f&&!u.has(p)&&this.flags&&this.flags.has(p)&&u.set(p,this.flags.get(p))},this),this.flags=u,this.pendingFirstTimeEvents=c,this._traceparent=i,this._loadTargetingIfNeeded()}).bind(this)).catch((function(s){this.markFetchComplete(),Fl.error(s)}).bind(this))}).bind(this)).catch((function(a){this.markFetchComplete(),Fl.error(a)}).bind(this)),this.fetchPromise};Tn.prototype.markFetchComplete=function(){if(!this._fetchInProgressStartTime){Fl.error("Fetch in progress started time not set, cannot mark fetch complete");return}this._fetchStartTime=this._fetchInProgressStartTime,this._fetchCompleteTime=Date.now(),this._fetchLatency=this._fetchCompleteTime-this._fetchStartTime,this._fetchInProgressStartTime=null};Tn.prototype._loadTargetingIfNeeded=function(){var t=!1;Ve.each(this.pendingFirstTimeEvents,function(e){e.property_filters&&!Ve.isEmptyObject(e.property_filters)&&(t=!0)}),t&&this.getTargeting().then(function(){Fl.log("targeting loaded for property filter evaluation")})};Tn.prototype.getTargeting=function(){return yRe(this.loadExtraBundle.bind(this),this.targetingSrc).catch((function(t){Fl.error("Failed to load targeting: "+t)}).bind(this))};Tn.prototype.checkFirstTimeEvents=function(t,e){!this.pendingFirstTimeEvents||Ve.isEmptyObject(this.pendingFirstTimeEvents)||(kr[yv]&&Ve.isFunction(kr[yv].then)?kr[yv].then((function(i){this._processFirstTimeEventCheck(t,e,i)}).bind(this)).catch((function(){this._processFirstTimeEventCheck(t,e,null)}).bind(this)):this._processFirstTimeEventCheck(t,e,null))};Tn.prototype._processFirstTimeEventCheck=function(t,e,i){Ve.each(this.pendingFirstTimeEvents,function(n,r){if(!this.activatedFirstTimeEvents[r]){var o=n.flag_key,a;if(!i&&n.property_filters&&!Ve.isEmptyObject(n.property_filters)){Fl.warn('Skipping event check for "'+o+'" - property filters require targeting library');return}if(!i)a={matches:t===n.event_name,error:null};else{var s={event_name:n.event_name,property_filters:n.property_filters};a=i.eventMatchesCriteria(t,e,s)}if(a.error){Fl.error('Error checking first-time event for flag "'+o+'": '+a.error);return}if(a.matches){Fl.log('First-time event matched for flag "'+o+'": '+t);var l={key:n.pending_variant.variant_key,value:n.pending_variant.variant_value,experiment_id:n.pending_variant.experiment_id,is_experiment_active:n.pending_variant.is_experiment_active};this.flags.set(o,l),this.activatedFirstTimeEvents[r]=!0,this.recordFirstTimeEvent(n.flag_id,n.project_id,n.first_time_event_hash)}}},this)};Tn.prototype.getFirstTimeEventApiRoute=function(t){return this.getFullApiRoute()+"/"+t+"/first-time-events"};Tn.prototype.recordFirstTimeEvent=function(t,e,i){var n=this.getMpProperty("distinct_id"),r=NDe(),o=new URLSearchParams;o.set("mp_lib","web"),o.set("$lib_version",Dh.LIB_VERSION);var a=this.getFirstTimeEventApiRoute(t)+"?"+o.toString(),s={distinct_id:n,project_id:e,first_time_event_hash:i};Fl.log("Recording first-time event for flag: "+t),this.fetch.call(kr,a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Basic "+btoa(this.getMpConfig("token")+":"),traceparent:r},body:JSON.stringify(s)}).catch(function(l){Fl.error("Failed to record first-time event for flag "+t+": "+l)})};Tn.prototype.getVariant=function(t,e){return this.fetchPromise?this.fetchPromise.then((function(){return this.getVariantSync(t,e)}).bind(this)).catch(function(i){return Fl.error(i),e}):new Promise(function(i){Fl.critical("Feature Flags not initialized"),i(e)})};Tn.prototype.getVariantSync=function(t,e){if(!this.areFlagsReady())return Fl.log("Flags not loaded yet"),e;var i=this.flags.get(t);return i?(this.trackFeatureCheck(t,i),i):(Fl.log('No flag found: "'+t+'"'),e)};Tn.prototype.getVariantValue=function(t,e){return this.getVariant(t,{value:e}).then(function(i){return i.value}).catch(function(i){return Fl.error(i),e})};Tn.prototype.getFeatureData=function(t,e){return Fl.critical("mixpanel.flags.get_feature_data() is deprecated and will be removed in a future release. Use mixpanel.flags.get_variant_value() instead."),this.getVariantValue(t,e)};Tn.prototype.getVariantValueSync=function(t,e){return this.getVariantSync(t,{value:e}).value};Tn.prototype.isEnabled=function(t,e){return this.getVariantValue(t).then((function(){return this.isEnabledSync(t,e)}).bind(this)).catch(function(i){return Fl.error(i),e})};Tn.prototype.isEnabledSync=function(t,e){e=e||!1;var i=this.getVariantValueSync(t,e);return i!==!0&&i!==!1&&(Fl.error('Feature flag "'+t+'" value: '+i+" is not a boolean; returning fallback value: "+e),i=e),i};Tn.prototype.trackFeatureCheck=function(t,e){if(!this.trackedFeatures.has(t)){this.trackedFeatures.add(t);var i={"Experiment name":t,"Variant name":e.key,$experiment_type:"feature_flag","Variant fetch start time":new Date(this._fetchStartTime).toISOString(),"Variant fetch complete time":new Date(this._fetchCompleteTime).toISOString(),"Variant fetch latency (ms)":this._fetchLatency,"Variant fetch traceparent":this._traceparent};e.experiment_id!=="undefined"&&(i.$experiment_id=e.experiment_id),e.is_experiment_active!=="undefined"&&(i.$is_experiment_active=e.is_experiment_active),e.is_qa_tester!=="undefined"&&(i.$is_qa_tester=e.is_qa_tester),this.track("$experiment_started",i)}};Tn.prototype.minApisSupported=function(){return!!this.fetch&&typeof Promise<"u"&&typeof Map<"u"&&typeof Set<"u"};aee(Tn);Tn.prototype.are_flags_ready=Tn.prototype.areFlagsReady;Tn.prototype.get_variant=Tn.prototype.getVariant;Tn.prototype.get_variant_sync=Tn.prototype.getVariantSync;Tn.prototype.get_variant_value=Tn.prototype.getVariantValue;Tn.prototype.get_variant_value_sync=Tn.prototype.getVariantValueSync;Tn.prototype.is_enabled=Tn.prototype.isEnabled;Tn.prototype.is_enabled_sync=Tn.prototype.isEnabledSync;Tn.prototype.update_context=Tn.prototype.updateContext;Tn.prototype.get_feature_data=Tn.prototype.getFeatureData;Tn.prototype.getTargeting=Tn.prototype.getTargeting;var Lh=function(t){this.mixpanelInstance=t.mixpanelInstance,this.getMpConfig=t.getConfigFunc,this.getTabId=t.getTabIdFunc,this.reportError=t.reportErrorFunc,this.getDistinctId=t.getDistinctIdFunc,this.loadExtraBundle=t.loadExtraBundle,this.recorderSrc=t.recorderSrc,this.targetingSrc=t.targetingSrc,this.libBasePath=t.libBasePath,this._recorder=null};Lh.prototype.shouldLoadRecorder=function(){if(this.getMpConfig("disable_persistence"))return Bn.log("Load recorder check skipped due to disable_persistence config"),Hn.resolve(!1);var t=new Hv(lee),e=this.getTabId();return t.init().then(function(){return t.getAll()}).then(function(i){for(var n=0;n<i.length;n++)if(fee(i[n])||i[n].tabId===e)return!0;return!1}).catch(Ve.bind(function(i){return this.reportError("Error checking recording registry",i),!1},this))};Lh.prototype.checkAndStartSessionRecording=function(t,e){if(!kr.MutationObserver)return Bn.critical("Browser does not support MutationObserver; skipping session recording"),Hn.resolve();var i=Ve.bind(function(o){return new Hn(Ve.bind(function(a){var s=Rk(Ve.bind(function(){this._recorder=this._recorder||new kr[VX](this.mixpanelInstance),this._recorder.resumeRecording(o),a()},this));if(Ve.isUndefined(kr[VX])){var l=this.recorderSrc||this.libBasePath+H7e;this.loadExtraBundle(l,s)}else s()},this))},this),n=Ve.isUndefined(e)?this.getMpConfig("record_sessions_percent"):e,r=n>0&&Math.random()*100<=n;return t||r?i(!0):this.shouldLoadRecorder().then(Ve.bind(function(o){return o?i(!1):Hn.resolve()},this))};Lh.prototype.isRecording=function(){if(!this._recorder||!Ve.isFunction(this._recorder.isRecording))return!1;try{return this._recorder.isRecording()}catch(t){return this.reportError("Error checking if recording is active",t),!1}};Lh.prototype.startRecordingOnEvent=function(t,e){var i=this.isRecording(),n=this.getMpConfig("recording_event_triggers");if(!i&&n){var r=n[t];if(r&&typeof r.percentage=="number"){var o=r.percentage,a=r.property_filters;if(a&&!Ve.isEmptyObject(a)){var s=this.targetingSrc||this.libBasePath+rAe;yRe(this.loadExtraBundle,s).then((function(l){try{var u=l.eventMatchesCriteria(t,e,{event_name:t,property_filters:a});u.matches&&this.checkAndStartSessionRecording(!1,o)}catch(c){Bn.critical("Could not parse recording event trigger properties logic:",c)}}).bind(this)).catch(function(l){Bn.critical("Failed to load targeting library:",l)})}else this.checkAndStartSessionRecording(!1,o)}}};Lh.prototype.stopSessionRecording=function(){return this._recorder?this._recorder.stopRecording():Hn.resolve()};Lh.prototype.pauseSessionRecording=function(){return this._recorder?this._recorder.pauseRecording():Hn.resolve()};Lh.prototype.resumeSessionRecording=function(){return this._recorder?this._recorder.resumeRecording():Hn.resolve()};Lh.prototype.isRecordingHeatmapData=function(){return this.getSessionReplayId()&&this.getMpConfig("record_heatmap_data")};Lh.prototype.getSessionRecordingProperties=function(){var t={},e=this.getSessionReplayId();return e&&(t.$mp_replay_id=e),t};Lh.prototype.getSessionReplayUrl=function(){var t=null,e=this.getSessionReplayId();if(e){var i=Ve.HTTPBuildQuery({replay_id:e,distinct_id:this.getDistinctId(),token:this.getMpConfig("token")});t="https://mixpanel.com/projects/replay-redirect?"+i}return t};Lh.prototype.getSessionReplayId=function(){var t=null;return this._recorder&&(t=this._recorder.replayId),t||null};Lh.prototype.getRecorder=function(){return this._recorder};aee(Lh);var NS=function(){};NS.prototype.create_properties=function(){};NS.prototype.event_handler=function(){};NS.prototype.after_track_handler=function(){};NS.prototype.init=function(t){return this.mp=t,this};NS.prototype.track=function(t,e,i,n){var r=this,o=Ve.dom_query(t);if(o.length===0){Bn.error("The DOM query ("+t+") returned 0 elements");return}return Ve.each(o,function(a){Ve.register_event(a,this.override_event,function(s){var l={},u=r.create_properties(i,this),c=r.mp.get_config("track_links_timeout");r.event_handler(s,this,l),window.setTimeout(r.track_callback(n,u,l,!0),c),r.mp.track(e,u,r.track_callback(n,u,l))})},this),!0};NS.prototype.track_callback=function(t,e,i,n){n=n||!1;var r=this;return function(){i.callback_fired||(i.callback_fired=!0,!(t&&t(n,e)===!1)&&r.after_track_handler(e,i,n))}};NS.prototype.create_properties=function(t,e){var i;return typeof t=="function"?i=t(e):i=Ve.extend({},t),i};var Lk=function(){this.override_event="click"};Ve.inherit(Lk,NS);Lk.prototype.create_properties=function(t,e){var i=Lk.superclass.create_properties.apply(this,arguments);return e.href&&(i.url=e.href),i};Lk.prototype.event_handler=function(t,e,i){i.new_tab=t.which===2||t.metaKey||t.ctrlKey||e.target==="_blank",i.href=e.href,i.new_tab||t.preventDefault()};Lk.prototype.after_track_handler=function(t,e){e.new_tab||setTimeout(function(){window.location=e.href},0)};var u6=function(){this.override_event="submit"};Ve.inherit(u6,NS);u6.prototype.event_handler=function(t,e,i){i.element=e,t.preventDefault()};u6.prototype.after_track_handler=function(t,e){setTimeout(function(){e.element.submit()},0)};var PP="$set",kk="$set_once",bv="$unset",ED="$add",im="$append",wD="$union",fS="$remove",int="$delete",mRe={set_action:function(t,e){var i={},n={};return Ve.isObject(t)?Ve.each(t,function(r,o){this._is_reserved_property(o)||(n[o]=r)},this):n[t]=e,i[PP]=n,i},unset_action:function(t){var e={},i=[];return Ve.isArray(t)||(t=[t]),Ve.each(t,function(n){this._is_reserved_property(n)||i.push(n)},this),e[bv]=i,e},set_once_action:function(t,e){var i={},n={};return Ve.isObject(t)?Ve.each(t,function(r,o){this._is_reserved_property(o)||(n[o]=r)},this):n[t]=e,i[kk]=n,i},union_action:function(t,e){var i={},n={};return Ve.isObject(t)?Ve.each(t,function(r,o){this._is_reserved_property(o)||(n[o]=Ve.isArray(r)?r:[r])},this):n[t]=Ve.isArray(e)?e:[e],i[wD]=n,i},append_action:function(t,e){var i={},n={};return Ve.isObject(t)?Ve.each(t,function(r,o){this._is_reserved_property(o)||(n[o]=r)},this):n[t]=e,i[im]=n,i},remove_action:function(t,e){var i={},n={};return Ve.isObject(t)?Ve.each(t,function(r,o){this._is_reserved_property(o)||(n[o]=r)},this):n[t]=e,i[fS]=n,i},delete_action:function(){var t={};return t[int]="",t}},ks=function(){};Ve.extend(ks.prototype,mRe);ks.prototype._init=function(t,e,i){this._mixpanel=t,this._group_key=e,this._group_id=i};ks.prototype.set=fI(function(t,e,i){var n=this.set_action(t,e);return Ve.isObject(t)&&(i=e),this._send_request(n,i)});ks.prototype.set_once=fI(function(t,e,i){var n=this.set_once_action(t,e);return Ve.isObject(t)&&(i=e),this._send_request(n,i)});ks.prototype.unset=fI(function(t,e){var i=this.unset_action(t);return this._send_request(i,e)});ks.prototype.union=fI(function(t,e,i){Ve.isObject(t)&&(i=e);var n=this.union_action(t,e);return this._send_request(n,i)});ks.prototype.delete=fI(function(t){var e=this.delete_action();return this._send_request(e,t)});ks.prototype.remove=fI(function(t,e,i){var n=this.remove_action(t,e);return this._send_request(n,i)});ks.prototype._send_request=function(t,e){t.$group_key=this._group_key,t.$group_id=this._group_id,t.$token=this._get_config("token");var i=Ve.encodeDates(t);return this._mixpanel._track_or_batch({type:"groups",data:i,endpoint:this._mixpanel.get_api_host("groups")+"/"+this._get_config("api_routes").groups,batcher:this._mixpanel.request_batchers.groups},e)};ks.prototype._is_reserved_property=function(t){return t==="$group_key"||t==="$group_id"};ks.prototype._get_config=function(t){return this._mixpanel.get_config(t)};ks.prototype.toString=function(){return this._mixpanel.toString()+".group."+this._group_key+"."+this._group_id};ks.prototype.remove=ks.prototype.remove;ks.prototype.set=ks.prototype.set;ks.prototype.set_once=ks.prototype.set_once;ks.prototype.union=ks.prototype.union;ks.prototype.unset=ks.prototype.unset;ks.prototype.toString=ks.prototype.toString;var jn=function(){};Ve.extend(jn.prototype,mRe);jn.prototype._init=function(t){this._mixpanel=t};jn.prototype.set=$P(function(t,e,i){var n=this.set_action(t,e);return Ve.isObject(t)&&(i=e),this._get_config("save_referrer")&&this._mixpanel.persistence.update_referrer_info(document.referrer),n[PP]=Ve.extend({},Ve.info.people_properties(),n[PP]),this._send_request(n,i)});jn.prototype.set_once=$P(function(t,e,i){var n=this.set_once_action(t,e);return Ve.isObject(t)&&(i=e),this._send_request(n,i)});jn.prototype.unset=$P(function(t,e){var i=this.unset_action(t);return this._send_request(i,e)});jn.prototype.increment=$P(function(t,e,i){var n={},r={};return Ve.isObject(t)?(Ve.each(t,function(o,a){if(!this._is_reserved_property(a))if(isNaN(parseFloat(o))){Bn.error("Invalid increment value passed to mixpanel.people.increment - must be a number");return}else r[a]=o},this),i=e):(Ve.isUndefined(e)&&(e=1),r[t]=e),n[ED]=r,this._send_request(n,i)});jn.prototype.append=$P(function(t,e,i){Ve.isObject(t)&&(i=e);var n=this.append_action(t,e);return this._send_request(n,i)});jn.prototype.remove=$P(function(t,e,i){Ve.isObject(t)&&(i=e);var n=this.remove_action(t,e);return this._send_request(n,i)});jn.prototype.union=$P(function(t,e,i){Ve.isObject(t)&&(i=e);var n=this.union_action(t,e);return this._send_request(n,i)});jn.prototype.track_charge=$P(function(){Bn.error("mixpanel.people.track_charge() is deprecated and no longer has any effect.")});jn.prototype.clear_charges=function(t){return this.set("$transactions",[],t)};jn.prototype.delete_user=function(){if(!this._identify_called()){Bn.error("mixpanel.people.delete_user() requires you to call identify() first");return}var t={$delete:this._mixpanel.get_distinct_id()};return this._send_request(t)};jn.prototype.toString=function(){return this._mixpanel.toString()+".people"};jn.prototype._send_request=function(t,e){t.$token=this._get_config("token"),t.$distinct_id=this._mixpanel.get_distinct_id();var i=this._mixpanel.get_property("$device_id"),n=this._mixpanel.get_property("$user_id"),r=this._mixpanel.get_property("$had_persisted_distinct_id");i&&(t.$device_id=i),n&&(t.$user_id=n),r&&(t.$had_persisted_distinct_id=r);var o=Ve.encodeDates(t);return this._identify_called()?this._mixpanel._track_or_batch({type:"people",data:o,endpoint:this._mixpanel.get_api_host("people")+"/"+this._get_config("api_routes").engage,batcher:this._mixpanel.request_batchers.people},e):(this._enqueue(t),Ve.isUndefined(e)||(this._get_config("verbose")?e({status:-1,error:null}):e(-1)),Ve.truncate(o,255))};jn.prototype._get_config=function(t){return this._mixpanel.get_config(t)};jn.prototype._identify_called=function(){return this._mixpanel._flags.identify_called===!0};jn.prototype._enqueue=function(t){PP in t?this._mixpanel.persistence._add_to_people_queue(PP,t):kk in t?this._mixpanel.persistence._add_to_people_queue(kk,t):bv in t?this._mixpanel.persistence._add_to_people_queue(bv,t):ED in t?this._mixpanel.persistence._add_to_people_queue(ED,t):im in t?this._mixpanel.persistence._add_to_people_queue(im,t):fS in t?this._mixpanel.persistence._add_to_people_queue(fS,t):wD in t?this._mixpanel.persistence._add_to_people_queue(wD,t):Bn.error("Invalid call to _enqueue():",t)};jn.prototype._flush_one_queue=function(t,e,i,n){var r=this,o=Ve.extend({},this._mixpanel.persistence.load_queue(t)),a=o;!Ve.isUndefined(o)&&Ve.isObject(o)&&!Ve.isEmptyObject(o)&&(r._mixpanel.persistence._pop_from_people_queue(t,o),r._mixpanel.persistence.save(),n&&(a=n(o)),e.call(r,a,function(s,l){s===0&&r._mixpanel.persistence._add_to_people_queue(t,o),Ve.isUndefined(i)||i(s,l)}))};jn.prototype._flush=function(t,e,i,n,r,o,a){var s=this;this._flush_one_queue(PP,this.set,t),this._flush_one_queue(kk,this.set_once,n),this._flush_one_queue(bv,this.unset,o,function(v){return Ve.keys(v)}),this._flush_one_queue(ED,this.increment,e),this._flush_one_queue(wD,this.union,r);var l=this._mixpanel.persistence.load_queue(im);if(!Ve.isUndefined(l)&&Ve.isArray(l)&&l.length)for(var u,c=function(v,y){v===0&&s._mixpanel.persistence._add_to_people_queue(im,u),Ve.isUndefined(i)||i(v,y)},d=l.length-1;d>=0;d--)l=this._mixpanel.persistence.load_queue(im),u=l.pop(),s._mixpanel.persistence.save(),Ve.isEmptyObject(u)||s.append(u,c);var f=this._mixpanel.persistence.load_queue(fS);if(!Ve.isUndefined(f)&&Ve.isArray(f)&&f.length)for(var h,p=function(v,y){v===0&&s._mixpanel.persistence._add_to_people_queue(fS,h),Ve.isUndefined(a)||a(v,y)},g=f.length-1;g>=0;g--)f=this._mixpanel.persistence.load_queue(fS),h=f.pop(),s._mixpanel.persistence.save(),Ve.isEmptyObject(h)||s.remove(h,p)};jn.prototype._is_reserved_property=function(t){return t==="$distinct_id"||t==="$token"||t==="$device_id"||t==="$user_id"||t==="$had_persisted_distinct_id"};jn.prototype.set=jn.prototype.set;jn.prototype.set_once=jn.prototype.set_once;jn.prototype.unset=jn.prototype.unset;jn.prototype.increment=jn.prototype.increment;jn.prototype.append=jn.prototype.append;jn.prototype.remove=jn.prototype.remove;jn.prototype.union=jn.prototype.union;jn.prototype.track_charge=jn.prototype.track_charge;jn.prototype.clear_charges=jn.prototype.clear_charges;jn.prototype.delete_user=jn.prototype.delete_user;jn.prototype.toString=jn.prototype.toString;var vee="__mps",yee="__mpso",mee="__mpus",bee="__mpa",See="__mpap",_ee="__mpr",Pee="__mpu",bRe="$people_distinct_id",rz="__alias",p3="__timers",nnt=[vee,yee,mee,bee,See,_ee,Pee,bRe,rz,p3],uo=function(t){this.props={},this.campaign_params_saved=!1,t.persistence_name?this.name="mp_"+t.persistence_name:this.name="mp_"+t.token+"_mixpanel";var e=t.persistence;e!=="cookie"&&e!=="localStorage"&&(Bn.critical("Unknown persistence type "+e+"; falling back to cookie"),e=t.persistence="cookie"),e==="localStorage"&&Ve.localStorage.is_supported()?this.storage=Ve.localStorage:this.storage=Ve.cookie,this.load(),this.update_config(t),this.upgrade(),this.save()};uo.prototype.properties=function(){var t={};return this.load(),Ve.each(this.props,function(e,i){Ve.include(nnt,i)||(t[i]=e)}),t};uo.prototype.load=function(){if(!this.disabled){var t=this.storage.parse(this.name);t&&(this.props=Ve.extend({},t))}};uo.prototype.upgrade=function(){var t,e;this.storage===Ve.localStorage?(t=Ve.cookie.parse(this.name),Ve.cookie.remove(this.name),Ve.cookie.remove(this.name,!0),t&&this.register_once(t)):this.storage===Ve.cookie&&(e=Ve.localStorage.parse(this.name),Ve.localStorage.remove(this.name),e&&this.register_once(e))};uo.prototype.save=function(){this.disabled||this.storage.set(this.name,Mk(this.props),this.expire_days,this.cross_subdomain,this.secure,this.cross_site,this.cookie_domain)};uo.prototype.load_prop=function(t){return this.load(),this.props[t]};uo.prototype.remove=function(){this.storage.remove(this.name,!1,this.cookie_domain),this.storage.remove(this.name,!0,this.cookie_domain)};uo.prototype.clear=function(){this.remove(),this.props={}};uo.prototype.register_once=function(t,e,i){return Ve.isObject(t)?(typeof e>"u"&&(e="None"),this.expire_days=typeof i>"u"?this.default_expiry:i,this.load(),Ve.each(t,function(n,r){(!this.props.hasOwnProperty(r)||this.props[r]===e)&&(this.props[r]=n)},this),this.save(),!0):!1};uo.prototype.register=function(t,e){return Ve.isObject(t)?(this.expire_days=typeof e>"u"?this.default_expiry:e,this.load(),Ve.extend(this.props,t),this.save(),!0):!1};uo.prototype.unregister=function(t){this.load(),t in this.props&&(delete this.props[t],this.save())};uo.prototype.update_search_keyword=function(t){this.register(Ve.info.searchInfo(t))};uo.prototype.update_referrer_info=function(t){this.register_once({$initial_referrer:t||"$direct",$initial_referring_domain:Ve.info.referringDomain(t)||"$direct"},"")};uo.prototype.get_referrer_info=function(){return Ve.strip_empty_properties({$initial_referrer:this.props.$initial_referrer,$initial_referring_domain:this.props.$initial_referring_domain})};uo.prototype.update_config=function(t){this.default_expiry=this.expire_days=t.cookie_expiration,this.set_disabled(t.disable_persistence),this.set_cookie_domain(t.cookie_domain),this.set_cross_site(t.cross_site_cookie),this.set_cross_subdomain(t.cross_subdomain_cookie),this.set_secure(t.secure_cookie)};uo.prototype.set_disabled=function(t){this.disabled=t,this.disabled?this.remove():this.save()};uo.prototype.set_cookie_domain=function(t){t!==this.cookie_domain&&(this.remove(),this.cookie_domain=t,this.save())};uo.prototype.set_cross_site=function(t){t!==this.cross_site&&(this.cross_site=t,this.remove(),this.save())};uo.prototype.set_cross_subdomain=function(t){t!==this.cross_subdomain&&(this.cross_subdomain=t,this.remove(),this.save())};uo.prototype.get_cross_subdomain=function(){return this.cross_subdomain};uo.prototype.set_secure=function(t){t!==this.secure&&(this.secure=!!t,this.remove(),this.save())};uo.prototype._add_to_people_queue=function(t,e){var i=this._get_queue_key(t),n=e[t],r=this._get_or_create_queue(PP),o=this._get_or_create_queue(kk),a=this._get_or_create_queue(bv),s=this._get_or_create_queue(ED),l=this._get_or_create_queue(wD),u=this._get_or_create_queue(fS,[]),c=this._get_or_create_queue(im,[]);i===vee?(Ve.extend(r,n),this._pop_from_people_queue(ED,n),this._pop_from_people_queue(wD,n),this._pop_from_people_queue(bv,n)):i===yee?(Ve.each(n,function(d,f){f in o||(o[f]=d)}),this._pop_from_people_queue(bv,n)):i===mee?Ve.each(n,function(d){Ve.each([r,o,s,l],function(f){d in f&&delete f[d]}),Ve.each(c,function(f){d in f&&delete f[d]}),a[d]=!0}):i===bee?(Ve.each(n,function(d,f){f in r?r[f]+=d:(f in s||(s[f]=0),s[f]+=d)},this),this._pop_from_people_queue(bv,n)):i===Pee?(Ve.each(n,function(d,f){Ve.isArray(d)&&(f in l||(l[f]=[]),Ve.each(d,function(h){Ve.include(l[f],h)||l[f].push(h)}))}),this._pop_from_people_queue(bv,n)):i===_ee?(u.push(n),this._pop_from_people_queue(im,n)):i===See&&(c.push(n),this._pop_from_people_queue(bv,n)),Bn.log("MIXPANEL PEOPLE REQUEST (QUEUED, PENDING IDENTIFY):"),Bn.log(e),this.save()};uo.prototype._pop_from_people_queue=function(t,e){var i=this.props[this._get_queue_key(t)];Ve.isUndefined(i)||Ve.each(e,function(n,r){t===im||t===fS?Ve.each(i,function(o){o[r]===n&&delete o[r]}):delete i[r]},this)};uo.prototype.load_queue=function(t){return this.load_prop(this._get_queue_key(t))};uo.prototype._get_queue_key=function(t){if(t===PP)return vee;if(t===kk)return yee;if(t===bv)return mee;if(t===ED)return bee;if(t===im)return See;if(t===fS)return _ee;if(t===wD)return Pee;Bn.error("Invalid queue:",t)};uo.prototype._get_or_create_queue=function(t,e){var i=this._get_queue_key(t);return e=Ve.isUndefined(e)?{}:e,this.props[i]||(this.props[i]=e)};uo.prototype.set_event_timer=function(t,e){var i=this.load_prop(p3)||{};i[t]=e,this.props[p3]=i,this.save()};uo.prototype.remove_event_timer=function(t){var e=this.load_prop(p3)||{},i=e[t];return Ve.isUndefined(i)||(delete this.props[p3][t],this.save()),i};var iz,ZK=function(t,e){throw new Error(t+" not available in this build.")},Nd,JK=0,ont=1,Cg="mixpanel",SRe="base64",ant="json",Cee="$device:",snt="strict",lnt="fallback",unt="disabled",zL=kr.XMLHttpRequest&&"withCredentials"in new XMLHttpRequest,_Re=!zL&&By.indexOf("MSIE")===-1&&By.indexOf("Mozilla")===-1,nz=null;cS.sendBeacon&&(nz=function(){return cS.sendBeacon.apply(cS,arguments)});var PRe={track:"track/",engage:"engage/",groups:"groups/",record:"record/",flags:"flags/",settings:"settings/"},QK={api_host:"https://api-js.mixpanel.com",api_hosts:{},api_routes:PRe,api_extra_query_params:{},api_method:"POST",api_transport:"XHR",api_payload_format:SRe,app_host:"https://mixpanel.com",autocapture:!1,cdn:"https://cdn.mxpnl.com",cross_site_cookie:!1,cross_subdomain_cookie:!0,error_reporter:gP,flags:!1,persistence:"cookie",persistence_name:"",cookie_domain:"",cookie_name:"",loaded:gP,mp_loader:null,track_marketing:!0,track_pageview:!1,skip_first_touch_marketing:!1,store_google:!0,stop_utm_persistence:!1,save_referrer:!0,test:!1,verbose:!1,img:!1,debug:!1,track_links_timeout:300,cookie_expiration:365,upgrade:!1,disable_persistence:!1,disable_cookie:!1,secure_cookie:!1,ip:!0,opt_out_tracking_by_default:!1,opt_out_persistence_by_default:!1,opt_out_tracking_persistence_type:"localStorage",opt_out_tracking_cookie_prefix:null,property_blacklist:[],xhr_headers:{},ignore_dnt:!1,batch_requests:!0,batch_size:50,batch_flush_interval_ms:5e3,batch_request_timeout_ms:9e4,batch_autostart:!0,hooks:{},record_block_class:new RegExp("^(mp-block|fs-exclude|amp-block|rr-block|ph-no-capture)$"),record_block_selector:"img, video, audio",record_canvas:!1,record_collect_fonts:!1,record_console:!0,record_heatmap_data:!1,recording_event_triggers:{},record_idle_timeout_ms:1800*1e3,record_mask_inputs:!0,record_max_ms:Pj,record_min_ms:0,record_network:!1,record_network_options:{},record_sessions_percent:0,recorder_src:null,targeting_src:null,lib_base_path:"https://cdn.mxpnl.com/libs/",remote_settings_mode:unt},CRe=!1,er=function(){},eZ=function(t,e,i){var n,r=i===Cg?Nd:Nd[i];if(r&&iz===JK)n=r;else{if(r&&!Ve.isArray(r)){Bn.error("You have already initialized "+i);return}n=new er}if(n._cached_groups={},n._init(t,e,i),n.people=new jn,n.people._init(n),!n.get_config("skip_first_touch_marketing")){var o=Ve.info.campaignParams(null),a={},s=!1;Ve.each(o,function(u,c){a["initial_"+c]=u,u&&(s=!0)}),s&&n.people.set_once(a)}Dh.DEBUG=Dh.DEBUG||n.get_config("debug");var l=iz===JK?"module":"snippet";return kr.dispatchEvent(new kr.CustomEvent("$mp_sdk_to_extension_event",{detail:{instance:n,source:l,token:t,name:i,info:Ve.info}})),!Ve.isUndefined(r)&&Ve.isArray(r)&&(n._execute_array.call(n.people,r.people),n._execute_array(r)),n};er.prototype.init=function(t,e,i){if(Ve.isUndefined(i)){this.report_error("You must name your new library: init(token, config, name)");return}if(i===Cg){this.report_error("You must initialize the main mixpanel object right after you include the Mixpanel js snippet");return}var n=eZ(t,e,i);return Nd[i]=n,n._loaded(),n};er.prototype._init=function(t,e,i){e=e||{},this.__loaded=!0,this.config={};var n={};if(!("api_payload_format"in e)){var r=e.api_host||QK.api_host;r.match(/\.mixpanel\.com/)&&(n.api_payload_format=ant)}if(this.hooks={},this.set_config(Ve.extend({},QK,n,e,{name:i,token:t,callback_fn:(i===Cg?i:Cg+"."+i)+"._jsc"})),this.recorderManager=new Lh({mixpanelInstance:this,getConfigFunc:Ve.bind(this.get_config,this),setConfigFunc:Ve.bind(this.set_config,this),getTabIdFunc:Ve.bind(this.get_tab_id,this),reportErrorFunc:Ve.bind(this.report_error,this),getDistinctIdFunc:Ve.bind(this.get_distinct_id,this),recorderSrc:this.get_config("recorder_src"),targetingSrc:this.get_config("targeting_src"),libBasePath:this.get_config("lib_base_path"),loadExtraBundle:ZK}),this._jsc=gP,this.__dom_loaded_queue=[],this.__request_queue=[],this.__disabled_events=[],this._flags={disable_all_events:!1,identify_called:!1},this.request_batchers={},this._batch_requests=this.get_config("batch_requests"),this._batch_requests){if(!Ve.localStorage.is_supported(!0)||!zL)this._batch_requests=!1,Bn.log("Turning off Mixpanel request-queueing; needs XHR and localStorage support"),Ve.each(this.get_batcher_configs(),function(l){Bn.log("Clearing batch queue "+l.queue_key),Ve.localStorage.remove(l.queue_key)});else if(this.init_batchers(),nz&&kr.addEventListener){var o=Ve.bind(function(){this.request_batchers.events.stopped||this.request_batchers.events.flush({unloading:!0})},this);kr.addEventListener("pagehide",function(l){l.persisted&&o()}),kr.addEventListener("visibilitychange",function(){Dn.visibilityState==="hidden"&&o()})}}this.persistence=this.cookie=new uo(this.config),this.unpersisted_superprops={},this._gdpr_init();var a=Ve.UUID();this.get_distinct_id()||this.register_once({distinct_id:Cee+a,$device_id:a},""),this.flags=new Tn({getFullApiRoute:Ve.bind(function(){return this.get_api_host("flags")+"/"+this.get_config("api_routes").flags},this),getConfigFunc:Ve.bind(this.get_config,this),setConfigFunc:Ve.bind(this.set_config,this),getPropertyFunc:Ve.bind(this.get_property,this),trackingFunc:Ve.bind(this.track,this),loadExtraBundle:ZK,targetingSrc:this.get_config("targeting_src")||this.get_config("lib_base_path")+rAe}),this.flags.init(),this.flags=this.flags,this.autocapture=new lu(this),this.autocapture.init(),this._init_tab_id();var s=this.get_config("remote_settings_mode");s===snt||s===lnt?this.__session_recording_init_promise=this._fetch_remote_settings(s).then(Ve.bind(function(){return this._check_and_start_session_recording()},this)):this.__session_recording_init_promise=this._check_and_start_session_recording()};er.prototype._init_tab_id=function(){if(this.get_config("disable_persistence"))Bn.log("Tab ID initialization skipped due to disable_persistence config");else if(Ve.sessionStorage.is_supported())try{var t=this.get_config("name")+"_"+this.get_config("token"),e="mp_tab_id_"+t,i="mp_gen_new_tab_id_"+t;(Ve.sessionStorage.get(i)||!Ve.sessionStorage.get(e))&&Ve.sessionStorage.set(e,"$tab-"+Ve.UUID()),Ve.sessionStorage.set(i,"1"),this.tab_id=Ve.sessionStorage.get(e),kr.addEventListener("beforeunload",function(){Ve.sessionStorage.remove(i)})}catch(n){this.report_error("Error initializing tab id",n)}else this.report_error("Session storage is not supported, cannot keep track of unique tab ID.")};er.prototype.get_tab_id=function(){return this.tab_id||null};er.prototype._check_and_start_session_recording=zP(function(t){return this.recorderManager.checkAndStartSessionRecording(t)});er.prototype._start_recording_on_event=function(t,e){return this.recorderManager.startRecordingOnEvent(t,e)};er.prototype.start_session_recording=function(){return this._check_and_start_session_recording(!0)};er.prototype.stop_session_recording=function(){return this.recorderManager.stopSessionRecording()};er.prototype.pause_session_recording=function(){return this.recorderManager.pauseSessionRecording()};er.prototype.resume_session_recording=function(){return this.recorderManager.resumeSessionRecording()};er.prototype.is_recording_heatmap_data=function(){return this.recorderManager.isRecordingHeatmapData()};er.prototype.get_session_recording_properties=function(){return this.recorderManager.getSessionRecordingProperties()};er.prototype.get_session_replay_url=function(){return this.recorderManager.getSessionReplayUrl()};er.prototype.__get_recorder=function(){return this.recorderManager.getRecorder()};er.prototype.__get_recording_init_promise=function(){return this.__session_recording_init_promise};er.prototype._loaded=function(){if(this.get_config("loaded")(this),this._set_default_superprops(),this.people.set_once(this.persistence.get_referrer_info()),this.get_config("store_google")&&this.get_config("stop_utm_persistence")){var t=Ve.info.campaignParams(null);Ve.each(t,(function(e,i){this.unregister(i)}).bind(this))}};er.prototype._set_default_superprops=function(){this.persistence.update_search_keyword(Dn.referrer),this.get_config("store_google")&&!this.get_config("stop_utm_persistence")&&this.register(Ve.info.campaignParams()),this.get_config("save_referrer")&&this.persistence.update_referrer_info(Dn.referrer)};er.prototype._dom_loaded=function(){Ve.each(this.__dom_loaded_queue,function(t){this._track_dom.apply(this,t)},this),this.has_opted_out_tracking()||Ve.each(this.__request_queue,function(t){this._send_request.apply(this,t)},this),delete this.__dom_loaded_queue,delete this.__request_queue};er.prototype._track_dom=function(t,e){if(this.get_config("img"))return this.report_error("You can't use DOM tracking functions with img = true."),!1;if(!CRe)return this.__dom_loaded_queue.push([t,e]),!1;var i=new t().init(this);return i.track.apply(i,e)};er.prototype._prepare_callback=function(t,e){if(Ve.isUndefined(t))return null;if(zL){var i=function(a){t(a,e)};return i}else{var n=this._jsc,r=""+Math.floor(Math.random()*1e8),o=this.get_config("callback_fn")+"["+r+"]";return n[r]=function(a){delete n[r],t(a,e)},o}};er.prototype._send_request=function(t,e,i,n){var r=!0;if(_Re)return this.__request_queue.push(arguments),r;var o={method:this.get_config("api_method"),transport:this.get_config("api_transport"),verbose:this.get_config("verbose")},a=null;!n&&(Ve.isFunction(i)||typeof i=="string")&&(n=i,i=null),i=Ve.extend(o,i||{}),zL||(i.method="GET");var s=i.method==="POST",l=nz&&s&&i.transport.toLowerCase()==="sendbeacon",u=i.verbose;e.verbose&&(u=!0),this.get_config("test")&&(e.test=1),u&&(e.verbose=1),this.get_config("img")&&(e.img=1),zL||(n?e.callback=n:(u||this.get_config("test"))&&(e.callback="(function(){})")),e.ip=this.get_config("ip")?1:0,e._=new Date().getTime().toString(),s&&(a="data="+encodeURIComponent(e.data),delete e.data),Ve.extend(e,this.get_config("api_extra_query_params")),t+="?"+Ve.HTTPBuildQuery(e);var c=this;if("img"in e){var d=Dn.createElement("img");d.src=t,Dn.body.appendChild(d)}else if(l){try{r=nz(t,a)}catch(y){c.report_error(y),r=!1}try{n&&n(r?1:0)}catch(y){c.report_error(y)}}else if(zL)try{var f=new XMLHttpRequest;f.open(i.method,t,!0);var h=this.get_config("xhr_headers");if(s&&(h["Content-Type"]="application/x-www-form-urlencoded"),Ve.each(h,function(y,m){f.setRequestHeader(m,y)}),i.timeout_ms&&typeof f.timeout<"u"){f.timeout=i.timeout_ms;var p=new Date().getTime()}f.withCredentials=!0,f.onreadystatechange=function(){if(f.readyState===4)if(f.status===200){if(n)if(u){var y;try{y=Ve.JSONDecode(f.responseText)}catch(S){if(c.report_error(S),i.ignore_json_errors)y=f.responseText;else return}n(y)}else n(Number(f.responseText))}else{var m;if(f.timeout&&!f.status&&new Date().getTime()-p>=f.timeout?m="timeout":m="Bad HTTP status: "+f.status+" "+f.statusText,c.report_error(m),n)if(u){var b=f.responseHeaders||{};n({status:0,httpStatusCode:f.status,error:m,retryAfter:b["Retry-After"]})}else n(0)}},f.send(a)}catch(y){c.report_error(y),r=!1}else{var g=Dn.createElement("script");g.type="text/javascript",g.async=!0,g.defer=!0,g.src=t;var v=Dn.getElementsByTagName("script")[0];v.parentNode.insertBefore(g,v)}return r};er.prototype._fetch_remote_settings=function(t){var e=this,i=function(){t==="strict"&&e.set_config({record_sessions_percent:0})};if(!kr.AbortController)return Bn.critical("Remote settings unavailable: missing minimum required APIs"),i(),Promise.resolve();var n=this.get_api_host("settings")+"/"+this.get_config("api_routes").settings,r={$lib_version:Dh.LIB_VERSION,mp_lib:"web",sdk_config:"1"},o=Ve.HTTPBuildQuery(r),a=n+"?"+o,s=new AbortController,l=setTimeout(function(){s.abort()},500),u={method:"GET",headers:{Authorization:"Basic "+btoa(e.get_config("token")+":")},signal:s.signal};return kr.fetch(a,u).then(function(c){if(clearTimeout(l),!c.ok){Bn.critical("Network response was not ok"),i();return}return c.json()}).then(function(c){if(c&&c.sdk_config&&c.sdk_config.config){var d=c.sdk_config.config,f={};Ve.each(d,function(h,p){QK.hasOwnProperty(p)&&(f[p]=h)}),Ve.isEmptyObject(f)?(Bn.critical("No valid config keys found in remote settings."),i()):e.set_config(f)}else i()}).catch(function(c){clearTimeout(l),Bn.critical("Failed to fetch remote settings",c),i()})};er.prototype._execute_array=function(t){var e,i=[],n=[],r=[];Ve.each(t,function(a){a&&(e=a[0],Ve.isArray(e)?r.push(a):typeof a=="function"?a.call(this):Ve.isArray(a)&&e==="alias"?i.push(a):Ve.isArray(a)&&e.indexOf("track")!==-1&&typeof this[e]=="function"?r.push(a):n.push(a))},this);var o=function(a,s){Ve.each(a,function(l){if(Ve.isArray(l[0])){var u=s;Ve.each(l,function(c){u=u[c[0]].apply(u,c.slice(1))})}else this[l[0]].apply(this,l.slice(1))},s)};o(i,this),o(n,this),o(r,this)};er.prototype.are_batchers_initialized=function(){return!!this.request_batchers.events};er.prototype.get_batcher_configs=function(){var t="__mpq_"+this.get_config("token");return this._batcher_configs=this._batcher_configs||{events:{type:"events",api_name:"track",queue_key:t+"_ev"},people:{type:"people",api_name:"engage",queue_key:t+"_pp"},groups:{type:"groups",api_name:"groups",queue_key:t+"_gr"}},this._batcher_configs};er.prototype.init_batchers=function(){if(!this.are_batchers_initialized()){var t=Ve.bind(function(i){return new Lg(i.queue_key,{libConfig:this.config,errorReporter:this.get_config("error_reporter"),sendRequestFunc:Ve.bind(function(n,r,o){var a=this.get_config("api_routes");this._send_request(this.get_api_host(i.api_name)+"/"+a[i.api_name],this._encode_data_for_request(n),r,this._prepare_callback(o,n))},this),beforeSendHook:Ve.bind(function(n){var r=this._run_hook("before_send_"+i.type,n);return r?r[0]:null},this),stopAllBatchingFunc:Ve.bind(this.stop_batch_senders,this),usePersistence:!0})},this),e=this.get_batcher_configs();this.request_batchers={events:t(e.events),people:t(e.people),groups:t(e.groups)}}this.get_config("batch_autostart")&&this.start_batch_senders()};er.prototype.start_batch_senders=function(){this._batchers_were_started=!0,this.are_batchers_initialized()&&(this._batch_requests=!0,Ve.each(this.request_batchers,function(t){t.start()}))};er.prototype.stop_batch_senders=function(){this._batch_requests=!1,Ve.each(this.request_batchers,function(t){t.stop(),t.clear()})};er.prototype.push=function(t){this._execute_array([t])};er.prototype.enable=function(t){var e,i,n,r;if(typeof t>"u")this._flags.disable_all_events=!1;else{for(e={},i=[],n=0;n<t.length;n++)e[t[n]]=!0;for(r=0;r<this.__disabled_events.length;r++)e[this.__disabled_events[r]]||i.push(this.__disabled_events[r]);this.__disabled_events=i}};er.prototype.disable=function(t){typeof t>"u"?this._flags.disable_all_events=!0:this.__disabled_events=this.__disabled_events.concat(t)};er.prototype._encode_data_for_request=function(t){var e=Mk(t);return this.get_config("api_payload_format")===SRe&&(e=Ve.base64Encode(e)),{data:e}};er.prototype._track_or_batch=function(t,e){var i=Ve.truncate(t.data,255),n=t.endpoint,r=t.batcher,o=t.should_send_immediately,a=t.send_request_options||{};e=e||gP;var s=!0,l=Ve.bind(function(){return a.skip_hooks||(i=this._run_hook("before_send_"+t.type,i),i&&(i=i[0])),i?(Bn.log("MIXPANEL REQUEST:"),Bn.log(i),this._send_request(n,this._encode_data_for_request(i),a,this._prepare_callback(e,i))):null},this);return this._batch_requests&&!o?r.enqueue(i).then(function(u){u?e(1,i):l()}):s=l(),s&&i};er.prototype.track=zP(function(t,e,i,n){var r;if(!(i&&i.skip_hooks)){if(r=this._run_hook("before_track",t,e),r===null)return;t=r[0],e=r[1]}!n&&typeof i=="function"&&(n=i,i=null),i=i||{};var o=i.transport;o&&(i.transport=o);var a=i.send_immediately;if(typeof n!="function"&&(n=gP),Ve.isUndefined(t)){this.report_error("No event name provided to mixpanel.track");return}if(this._event_is_disabled(t)){n(0);return}e=Ve.extend({},e),e.token=this.get_config("token");var s=this.persistence.remove_event_timer(t);if(!Ve.isUndefined(s)){var l=new Date().getTime()-s;e.$duration=parseFloat((l/1e3).toFixed(3))}this._set_default_superprops();var u=this.get_config("track_marketing")?Ve.info.marketingParams():{};e=Ve.extend({},Ve.info.properties({mp_loader:this.get_config("mp_loader")}),u,this.persistence.properties(),this.unpersisted_superprops,this.get_session_recording_properties(),e);var c=this.get_config("property_blacklist");Ve.isArray(c)?Ve.each(c,function(f){delete e[f]}):this.report_error("Invalid value for property_blacklist config: "+c),this._start_recording_on_event(t,e);var d={event:t,properties:e};return r=this._track_or_batch({type:"events",data:d,endpoint:this.get_api_host("events")+"/"+this.get_config("api_routes").track,batcher:this.request_batchers.events,should_send_immediately:a,send_request_options:i},n),this.flags&&this.flags.checkFirstTimeEvents&&this.flags.checkFirstTimeEvents(t,e),r});er.prototype.set_group=zP(function(t,e,i){Ve.isArray(e)||(e=[e]);var n={};return n[t]=e,this.register(n),this.people.set(t,e,i)});er.prototype.add_group=zP(function(t,e,i){var n=this.get_property(t),r={};return n===void 0?(r[t]=[e],this.register(r)):n.indexOf(e)===-1&&(n.push(e),r[t]=n,this.register(r)),this.people.union(t,e,i)});er.prototype.remove_group=zP(function(t,e,i){var n=this.get_property(t);if(n!==void 0){var r=n.indexOf(e);r>-1&&(n.splice(r,1),this.register({group_key:n})),n.length===0&&this.unregister(t)}return this.people.remove(t,e,i)});er.prototype.track_with_groups=zP(function(t,e,i,n){var r=Ve.extend({},e||{});return Ve.each(i,function(o,a){o!=null&&(r[a]=o)}),this.track(t,r,n)});er.prototype._create_map_key=function(t,e){return t+"_"+JSON.stringify(e)};er.prototype._remove_group_from_cache=function(t,e){delete this._cached_groups[this._create_map_key(t,e)]};er.prototype.get_group=function(t,e){var i=this._create_map_key(t,e),n=this._cached_groups[i];return(n===void 0||n._group_key!==t||n._group_id!==e)&&(n=new ks,n._init(this,t,e),this._cached_groups[i]=n),n};er.prototype.track_pageview=zP(function(t,e){typeof t!="object"&&(t={}),e=e||{};var i=e.event_name||"$mp_web_page_view",n=Ve.extend(Ve.info.mpPageViewProperties(),Ve.info.campaignParams(),Ve.info.clickParams()),r=Ve.extend({},n,t);return this.track(i,r)});er.prototype.track_links=function(){return this._track_dom.call(this,Lk,arguments)};er.prototype.track_forms=function(){return this._track_dom.call(this,u6,arguments)};er.prototype.time_event=function(t){if(Ve.isUndefined(t)){this.report_error("No event name provided to mixpanel.time_event");return}this._event_is_disabled(t)||this.persistence.set_event_timer(t,new Date().getTime())};var cnt={persistent:!0},Tee=function(t){var e;return Ve.isObject(t)?e=t:Ve.isUndefined(t)?e={}:e={days:t},Ve.extend({},cnt,e)};er.prototype.register=function(t,e){var i=this._run_hook("before_register",t,e);if(i!==null){t=i[0],e=i[1];var n=Tee(e);n.persistent?this.persistence.register(t,n.days):Ve.extend(this.unpersisted_superprops,t)}};er.prototype.register_once=function(t,e,i){var n=this._run_hook("before_register_once",t,e,i);if(n!==null){t=n[0],e=n[1],i=n[2];var r=Tee(i);r.persistent?this.persistence.register_once(t,e,r.days):(typeof e>"u"&&(e="None"),Ve.each(t,function(o,a){(!this.unpersisted_superprops.hasOwnProperty(a)||this.unpersisted_superprops[a]===e)&&(this.unpersisted_superprops[a]=o)},this))}};er.prototype.unregister=function(t,e){var i=this._run_hook("before_unregister",t,e);i!==null&&(t=i[0],e=i[1],e=Tee(e),e.persistent?this.persistence.unregister(t):delete this.unpersisted_superprops[t])};er.prototype._register_single=function(t,e){var i={};i[t]=e,this.register(i)};er.prototype.identify=function(t,e,i,n,r,o,a,s){var l=this._run_hook("before_identify",t);if(l===null)return-1;t=l[0];var u=this.get_distinct_id();if(t&&u!==t){if(typeof t=="string"&&t.indexOf(Cee)===0)return this.report_error("distinct_id cannot have $device: prefix"),-1;this.register({$user_id:t})}if(!this.get_property("$device_id")){var c=u;this.register_once({$had_persisted_distinct_id:!0,$device_id:c},"")}t!==u&&t!==this.get_property(rz)&&(this.unregister(rz),this.register({distinct_id:t})),this._flags.identify_called=!0,this.people._flush(e,i,n,r,o,a,s),t!==u&&this.track("$identify",{distinct_id:t,$anon_distinct_id:u},{skip_hooks:!0}),t!==u&&this.flags.fetchFlags()};er.prototype.reset=function(){this.stop_session_recording(),this.persistence.clear(),this._flags.identify_called=!1;var t=Ve.UUID();this.register_once({distinct_id:Cee+t,$device_id:t},""),this._check_and_start_session_recording()};er.prototype.get_distinct_id=function(){return this.get_property("distinct_id")};er.prototype.alias=function(t,e){if(t===this.get_property(bRe))return this.report_error("Attempting to create alias for existing People user - aborting."),-2;var i=this;return Ve.isUndefined(e)&&(e=this.get_distinct_id()),t!==e?(this._register_single(rz,t),this.track("$create_alias",{alias:t,distinct_id:e},{skip_hooks:!0},function(){i.identify(t)})):(this.report_error("alias matches current distinct_id - skipping api call."),this.identify(t),-1)};er.prototype.name_tag=function(t){this._register_single("mp_name_tag",t)};er.prototype.set_config=function(t){if(Ve.isObject(t)){Ve.extend(this.config,t);var e=t.batch_size;e&&Ve.each(this.request_batchers,function(i){i.resetBatchSize()}),this.get_config("persistence_name")||(this.config.persistence_name=this.config.cookie_name),this.get_config("disable_persistence")||(this.config.disable_persistence=this.config.disable_cookie),this.persistence&&this.persistence.update_config(this.config),Dh.DEBUG=Dh.DEBUG||this.get_config("debug"),("autocapture"in t||"record_heatmap_data"in t)&&this.autocapture&&this.autocapture.init(),Ve.isObject(t.hooks)&&(this.hooks={},Ve.each(t.hooks,function(i,n){if(Ve.isFunction(i))this.hooks[n]=[i];else if(Ve.isArray(i)){this.hooks[n]=[];for(var r=0;r<i.length;r++)Ve.isFunction(i[r])||Bn.critical("Invalid hook added. Hook is not a function"),this.hooks[n].push(i[r])}else Bn.critical("Invalid hooks added. Ensure that the hook values passed into config.hooks are functions or arrays of functions.")},this))}};er.prototype.get_config=function(t){return this.config[t]};er.prototype._run_hook=function(t){var e=aP.call(arguments,1);return Ve.each(this.hooks[t],function(i){if(e===null)return null;var n=i.apply(this,e);typeof n>"u"?(this.report_error(t+" hook did not return a valid value"),e=null):(Ve.isArray(n)||(n=[n]),e.splice.apply(e,[0,n.length].concat(n)))},this),e};er.prototype.get_property=function(t){return this.persistence.load_prop([t])};er.prototype.get_api_host=function(t){return this.get_config("api_hosts")[t]||this.get_config("api_host")};er.prototype.toString=function(){var t=this.get_config("name");return t!==Cg&&(t=Cg+"."+t),t};er.prototype._event_is_disabled=function(t){return Ve.isBlockedUA(By)||this._flags.disable_all_events||Ve.include(this.__disabled_events,t)};er.prototype._gdpr_init=function(){var t=this.get_config("opt_out_tracking_persistence_type")==="localStorage";t&&Ve.localStorage.is_supported()&&(!this.has_opted_in_tracking()&&this.has_opted_in_tracking({persistence_type:"cookie"})&&this.opt_in_tracking({enable_persistence:!1}),!this.has_opted_out_tracking()&&this.has_opted_out_tracking({persistence_type:"cookie"})&&this.opt_out_tracking({clear_persistence:!1}),this.clear_opt_in_out_tracking({persistence_type:"cookie",enable_persistence:!1})),this.has_opted_out_tracking()?this._gdpr_update_persistence({clear_persistence:!0}):!this.has_opted_in_tracking()&&(this.get_config("opt_out_tracking_by_default")||Ve.cookie.get("mp_optout"))&&(Ve.cookie.remove("mp_optout"),this.opt_out_tracking({clear_persistence:this.get_config("opt_out_persistence_by_default")}))};er.prototype._gdpr_update_persistence=function(t){var e;if(t&&t.clear_persistence)e=!0;else if(t&&t.enable_persistence)e=!1;else return;!this.get_config("disable_persistence")&&this.persistence.disabled!==e&&this.persistence.set_disabled(e),e?(this.stop_batch_senders(),this.stop_session_recording()):this._batchers_were_started&&this.start_batch_senders()};er.prototype._gdpr_call_func=function(t,e){return e=Ve.extend({track:Ve.bind(this.track,this),persistence_type:this.get_config("opt_out_tracking_persistence_type"),cookie_prefix:this.get_config("opt_out_tracking_cookie_prefix"),cookie_expiration:this.get_config("cookie_expiration"),cross_site_cookie:this.get_config("cross_site_cookie"),cross_subdomain_cookie:this.get_config("cross_subdomain_cookie"),cookie_domain:this.get_config("cookie_domain"),secure_cookie:this.get_config("secure_cookie"),ignore_dnt:this.get_config("ignore_dnt")},e),Ve.localStorage.is_supported()||(e.persistence_type="cookie"),t(this.get_config("token"),{track:e.track,trackEventName:e.track_event_name,trackProperties:e.track_properties,persistenceType:e.persistence_type,persistencePrefix:e.cookie_prefix,cookieDomain:e.cookie_domain,cookieExpiration:e.cookie_expiration,crossSiteCookie:e.cross_site_cookie,crossSubdomainCookie:e.cross_subdomain_cookie,secureCookie:e.secure_cookie,ignoreDnt:e.ignore_dnt})};er.prototype.opt_in_tracking=function(t){t=Ve.extend({enable_persistence:!0},t),this._gdpr_call_func(Wrt,t),this._gdpr_update_persistence(t)};er.prototype.opt_out_tracking=function(t){t=Ve.extend({clear_persistence:!0,delete_user:!0},t),t.delete_user&&this.people&&this.people._identify_called()&&(this.people.delete_user(),this.people.clear_charges()),this._gdpr_call_func(Grt,t),this._gdpr_update_persistence(t)};er.prototype.has_opted_in_tracking=function(t){return this._gdpr_call_func(Yrt,t)};er.prototype.has_opted_out_tracking=function(t){return this._gdpr_call_func(BDe,t)};er.prototype.clear_opt_in_out_tracking=function(t){t=Ve.extend({enable_persistence:!0},t),this._gdpr_call_func(qrt,t),this._gdpr_update_persistence(t)};er.prototype.report_error=function(t,e){Bn.error.apply(Bn.error,arguments);try{!e&&!(t instanceof Error)&&(t=new Error(t)),this.get_config("error_reporter")(t,e)}catch(i){Bn.error(i)}};er.prototype.add_hook=function(t,e){this.hooks[t]||(this.hooks[t]=[]),this.hooks[t].push(e)};er.prototype.remove_hook=function(t,e){var i;this.hooks[t]&&(i=this.hooks[t].indexOf(e),i!==-1?this.hooks[t].splice(i,1):Bn.log("remove_hook failed. Matching hook was not found"))};er.prototype.init=er.prototype.init;er.prototype.reset=er.prototype.reset;er.prototype.enable=er.prototype.enable;er.prototype.disable=er.prototype.disable;er.prototype.time_event=er.prototype.time_event;er.prototype.track=er.prototype.track;er.prototype.track_links=er.prototype.track_links;er.prototype.track_forms=er.prototype.track_forms;er.prototype.track_pageview=er.prototype.track_pageview;er.prototype.register=er.prototype.register;er.prototype.register_once=er.prototype.register_once;er.prototype.unregister=er.prototype.unregister;er.prototype.identify=er.prototype.identify;er.prototype.alias=er.prototype.alias;er.prototype.name_tag=er.prototype.name_tag;er.prototype.set_config=er.prototype.set_config;er.prototype.get_config=er.prototype.get_config;er.prototype.get_api_host=er.prototype.get_api_host;er.prototype.get_property=er.prototype.get_property;er.prototype.get_distinct_id=er.prototype.get_distinct_id;er.prototype.toString=er.prototype.toString;er.prototype.opt_out_tracking=er.prototype.opt_out_tracking;er.prototype.opt_in_tracking=er.prototype.opt_in_tracking;er.prototype.has_opted_out_tracking=er.prototype.has_opted_out_tracking;er.prototype.has_opted_in_tracking=er.prototype.has_opted_in_tracking;er.prototype.clear_opt_in_out_tracking=er.prototype.clear_opt_in_out_tracking;er.prototype.get_group=er.prototype.get_group;er.prototype.set_group=er.prototype.set_group;er.prototype.add_group=er.prototype.add_group;er.prototype.remove_group=er.prototype.remove_group;er.prototype.add_hook=er.prototype.add_hook;er.prototype.remove_hook=er.prototype.remove_hook;er.prototype.track_with_groups=er.prototype.track_with_groups;er.prototype.start_batch_senders=er.prototype.start_batch_senders;er.prototype.stop_batch_senders=er.prototype.stop_batch_senders;er.prototype.start_session_recording=er.prototype.start_session_recording;er.prototype.stop_session_recording=er.prototype.stop_session_recording;er.prototype.pause_session_recording=er.prototype.pause_session_recording;er.prototype.resume_session_recording=er.prototype.resume_session_recording;er.prototype.get_session_recording_properties=er.prototype.get_session_recording_properties;er.prototype.get_session_replay_url=er.prototype.get_session_replay_url;er.prototype.get_tab_id=er.prototype.get_tab_id;er.prototype.DEFAULT_API_ROUTES=PRe;er.prototype.__get_recorder=er.prototype.__get_recorder;er.prototype.__get_recording_init_promise=er.prototype.__get_recording_init_promise;uo.prototype.properties=uo.prototype.properties;uo.prototype.update_search_keyword=uo.prototype.update_search_keyword;uo.prototype.update_referrer_info=uo.prototype.update_referrer_info;uo.prototype.get_cross_subdomain=uo.prototype.get_cross_subdomain;uo.prototype.clear=uo.prototype.clear;var PL={},dnt=function(){Ve.each(PL,function(t,e){e!==Cg&&(Nd[e]=t)}),Nd._=Ve},fnt=function(){Nd.init=function(t,e,i){if(i)return Nd[i]||(Nd[i]=PL[i]=eZ(t,e,i),Nd[i]._loaded()),Nd[i];var n=Nd;PL[Cg]?n=PL[Cg]:t&&(n=eZ(t,e,Cg),n._loaded(),PL[Cg]=n),Nd=n,iz===ont&&(kr[Cg]=Nd),dnt()}},hnt=function(){function t(){t.done||(t.done=!0,CRe=!0,_Re=!1,Ve.each(PL,function(n){n._dom_loaded()}))}function e(){try{Dn.documentElement.doScroll("left")}catch{setTimeout(e,1);return}t()}if(Dn.addEventListener)Dn.readyState==="complete"?t():Dn.addEventListener("DOMContentLoaded",t,!1);else if(Dn.attachEvent){Dn.attachEvent("onreadystatechange",t);var i=!1;try{i=kr.frameElement===null}catch{}Dn.documentElement.doScroll&&i&&e()}Ve.register_event(kr,"load",t,!0)};function pnt(t){return ZK=t,iz=JK,Nd=new er,fnt(),Nd.init(),hnt(),Nd}function gnt(t,e){e()}var g3=pnt(gnt);const Jse="c05029406c50b6b66255d71bcb400116",vnt="https://api-eu.mixpanel.com",ynt={app:"RemotiveStudio",environment:"prod"},mnt=["$current_url","$initial_referrer","$referrer"];let Qse=!1;function TRe(){Qse||!Jse||(g3.init(Jse,{api_host:vnt,track_pageview:!1,persistence:"localStorage",property_blacklist:mnt}),g3.register(ynt),Qse=!0)}function bnt(t,e){try{TRe(),g3.track(t,e)}catch(i){console.warn("Failed to capture analytics track event",i)}}function Snt(t,e){try{TRe(),g3.identify(t),e&&g3.people.set({$email:e})}catch(i){console.warn("Failed to capture analytics identify event",i)}}function el(){const t=qt.c(1),e=Pnt,i=_nt;let n;return t[0]===Symbol.for("react.memo_cache_sentinel")?(n={track:e,identify:i},t[0]=n):n=t[0],n}function _nt(t,e){console.debug("useProductAnalytics - identify",t),Snt(t,e)}function Pnt(t,e){console.debug("useProductAnalytics - track",t,e),bnt(t,e)}var Fi=(t=>(t.Play="Play",t.Pause="Pause",t.OpenTab="OpenTab",t.ViewModeChanged="ViewModeChanged",t.CreateDashboard="CreateDashboard",t.CloseTab="CloseTab",t.ChangeSetting="ChangeSetting",t.AppMounted="AppMounted",t.AppCrashed="AppCrashed",t.NotFoundPageViewed="NotFoundPageViewed",t.AddPanelToDashboard="AddPanelToDashboard",t.RemovePanelFromDashboard="RemovePanelFromDashboard",t.AddSignalToPanel="AddSignalToPanel",t.AddVideoToPanel="AddVideoToPanel",t.ChangePanelSetting="ChangePanelSetting",t.OpenRecordingSession="OpenRecordingSession",t.CloseRecordingSession="CloseRecordingSession",t.PlaybackReset="PlaybackReset",t.PlaybackRepeatSet="PlaybackRepeatSet",t.SaveDashboard="SaveDashboard",t.SaveDashboardAs="SaveDashboardAs",t.CompactDashboard="CompactDashboard",t.DashboardLayoutMove="DashboardLayoutMove",t.DashboardLayoutResize="DashboardLayoutResize",t.TopologyExpandNode="TopologyExpandNode",t.TopologyCollapseNode="TopologyCollapseNode",t.TopologyEntityDetailsOpen="TopologyEntityDetailsOpen",t.TopologyEntityDetailsClose="TopologyEntityDetailsClose",t.TopologyChangeMode="TopologyChangeMode",t.TopologyShowAllEntities="TopologyShowAllEntities",t.TopologySearch="TopologySearch",t))(Fi||{});function xRe(t){const e=t+"CollectionProvider",[i,n]=kS(e),[r,o]=i(e,{collectionRef:{current:null},itemMap:new Map}),a=g=>{const{scope:v,children:y}=g,m=Wn.useRef(null),b=Wn.useRef(new Map).current;return L.jsx(r,{scope:v,itemMap:b,collectionRef:m,children:y})};a.displayName=e;const s=t+"CollectionSlot",l=yk(s),u=Wn.forwardRef((g,v)=>{const{scope:y,children:m}=g,b=o(s,y),S=Bl(v,b.collectionRef);return L.jsx(l,{ref:S,children:m})});u.displayName=s;const c=t+"CollectionItemSlot",d="data-radix-collection-item",f=yk(c),h=Wn.forwardRef((g,v)=>{const{scope:y,children:m,...b}=g,S=Wn.useRef(null),_=Bl(v,S),C=o(c,y);return Wn.useEffect(()=>(C.itemMap.set(S,{ref:S,...b}),()=>void C.itemMap.delete(S))),L.jsx(f,{[d]:"",ref:_,children:m})});h.displayName=c;function p(g){const v=o(t+"CollectionConsumer",g);return Wn.useCallback(()=>{const m=v.collectionRef.current;if(!m)return[];const b=Array.from(m.querySelectorAll(`[${d}]`));return Array.from(v.itemMap.values()).sort((C,P)=>b.indexOf(C.ref.current)-b.indexOf(P.ref.current))},[v.collectionRef,v.itemMap])}return[{Provider:a,Slot:u,ItemSlot:h},p,n]}var Cnt=J.createContext(void 0);function ERe(t){const e=J.useContext(Cnt);return t||e||"ltr"}var L8=0;function xee(){J.useEffect(()=>{const t=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",t[0]??ele()),document.body.insertAdjacentElement("beforeend",t[1]??ele()),L8++,()=>{L8===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(e=>e.remove()),L8--}},[])}function ele(){const t=document.createElement("span");return t.setAttribute("data-radix-focus-guard",""),t.tabIndex=0,t.style.outline="none",t.style.opacity="0",t.style.position="fixed",t.style.pointerEvents="none",t}var k8="focusScope.autoFocusOnMount",I8="focusScope.autoFocusOnUnmount",tle={bubbles:!1,cancelable:!0},Tnt="FocusScope",c6=J.forwardRef((t,e)=>{const{loop:i=!1,trapped:n=!1,onMountAutoFocus:r,onUnmountAutoFocus:o,...a}=t,[s,l]=J.useState(null),u=um(r),c=um(o),d=J.useRef(null),f=Bl(e,g=>l(g)),h=J.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;J.useEffect(()=>{if(n){let g=function(b){if(h.paused||!s)return;const S=b.target;s.contains(S)?d.current=S:V_(d.current,{select:!0})},v=function(b){if(h.paused||!s)return;const S=b.relatedTarget;S!==null&&(s.contains(S)||V_(d.current,{select:!0}))},y=function(b){if(document.activeElement===document.body)for(const _ of b)_.removedNodes.length>0&&V_(s)};document.addEventListener("focusin",g),document.addEventListener("focusout",v);const m=new MutationObserver(y);return s&&m.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",v),m.disconnect()}}},[n,s,h.paused]),J.useEffect(()=>{if(s){ile.add(h);const g=document.activeElement;if(!s.contains(g)){const y=new CustomEvent(k8,tle);s.addEventListener(k8,u),s.dispatchEvent(y),y.defaultPrevented||(xnt(Dnt(wRe(s)),{select:!0}),document.activeElement===g&&V_(s))}return()=>{s.removeEventListener(k8,u),setTimeout(()=>{const y=new CustomEvent(I8,tle);s.addEventListener(I8,c),s.dispatchEvent(y),y.defaultPrevented||V_(g??document.body,{select:!0}),s.removeEventListener(I8,c),ile.remove(h)},0)}}},[s,u,c,h]);const p=J.useCallback(g=>{if(!i&&!n||h.paused)return;const v=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,y=document.activeElement;if(v&&y){const m=g.currentTarget,[b,S]=Ent(m);b&&S?!g.shiftKey&&y===S?(g.preventDefault(),i&&V_(b,{select:!0})):g.shiftKey&&y===b&&(g.preventDefault(),i&&V_(S,{select:!0})):y===m&&g.preventDefault()}},[i,n,h.paused]);return L.jsx(es.div,{tabIndex:-1,...a,ref:f,onKeyDown:p})});c6.displayName=Tnt;function xnt(t,{select:e=!1}={}){const i=document.activeElement;for(const n of t)if(V_(n,{select:e}),document.activeElement!==i)return}function Ent(t){const e=wRe(t),i=rle(e,t),n=rle(e.reverse(),t);return[i,n]}function wRe(t){const e=[],i=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const r=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||r?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;i.nextNode();)e.push(i.currentNode);return e}function rle(t,e){for(const i of t)if(!wnt(i,{upTo:e}))return i}function wnt(t,{upTo:e}){if(getComputedStyle(t).visibility==="hidden")return!0;for(;t;){if(e!==void 0&&t===e)return!1;if(getComputedStyle(t).display==="none")return!0;t=t.parentElement}return!1}function Ant(t){return t instanceof HTMLInputElement&&"select"in t}function V_(t,{select:e=!1}={}){if(t&&t.focus){const i=document.activeElement;t.focus({preventScroll:!0}),t!==i&&Ant(t)&&e&&t.select()}}var ile=Ont();function Ont(){let t=[];return{add(e){const i=t[0];e!==i&&(i==null||i.pause()),t=nle(t,e),t.unshift(e)},remove(e){var i;t=nle(t,e),(i=t[0])==null||i.resume()}}}function nle(t,e){const i=[...t],n=i.indexOf(e);return n!==-1&&i.splice(n,1),i}function Dnt(t){return t.filter(e=>e.tagName!=="A")}var N8="rovingFocusGroup.onEntryFocus",Rnt={bubbles:!1,cancelable:!0},CV="RovingFocusGroup",[tZ,ARe,Mnt]=xRe(CV),[Lnt,ORe]=kS(CV,[Mnt]),[knt,Int]=Lnt(CV),DRe=J.forwardRef((t,e)=>L.jsx(tZ.Provider,{scope:t.__scopeRovingFocusGroup,children:L.jsx(tZ.Slot,{scope:t.__scopeRovingFocusGroup,children:L.jsx(Nnt,{...t,ref:e})})}));DRe.displayName=CV;var Nnt=J.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:i,orientation:n,loop:r=!1,dir:o,currentTabStopId:a,defaultCurrentTabStopId:s,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:c=!1,...d}=t,f=J.useRef(null),h=Bl(e,f),p=ERe(o),[g,v]=ND({prop:a,defaultProp:s??null,onChange:l,caller:CV}),[y,m]=J.useState(!1),b=um(u),S=ARe(i),_=J.useRef(!1),[C,P]=J.useState(0);return J.useEffect(()=>{const x=f.current;if(x)return x.addEventListener(N8,b),()=>x.removeEventListener(N8,b)},[b]),L.jsx(knt,{scope:i,orientation:n,dir:p,loop:r,currentTabStopId:g,onItemFocus:J.useCallback(x=>v(x),[v]),onItemShiftTab:J.useCallback(()=>m(!0),[]),onFocusableItemAdd:J.useCallback(()=>P(x=>x+1),[]),onFocusableItemRemove:J.useCallback(()=>P(x=>x-1),[]),children:L.jsx(es.div,{tabIndex:y||C===0?-1:0,"data-orientation":n,...d,ref:h,style:{outline:"none",...t.style},onMouseDown:tn(t.onMouseDown,()=>{_.current=!0}),onFocus:tn(t.onFocus,x=>{const E=!_.current;if(x.target===x.currentTarget&&E&&!y){const A=new CustomEvent(N8,Rnt);if(x.currentTarget.dispatchEvent(A),!A.defaultPrevented){const R=S().filter(V=>V.focusable),M=R.find(V=>V.active),D=R.find(V=>V.id===g),I=[M,D,...R].filter(Boolean).map(V=>V.ref.current);LRe(I,c)}}_.current=!1}),onBlur:tn(t.onBlur,()=>m(!1))})})}),RRe="RovingFocusGroupItem",MRe=J.forwardRef((t,e)=>{const{__scopeRovingFocusGroup:i,focusable:n=!0,active:r=!1,tabStopId:o,children:a,...s}=t,l=Mv(),u=o||l,c=Int(RRe,i),d=c.currentTabStopId===u,f=ARe(i),{onFocusableItemAdd:h,onFocusableItemRemove:p,currentTabStopId:g}=c;return J.useEffect(()=>{if(n)return h(),()=>p()},[n,h,p]),L.jsx(tZ.ItemSlot,{scope:i,id:u,focusable:n,active:r,children:L.jsx(es.span,{tabIndex:d?0:-1,"data-orientation":c.orientation,...s,ref:e,onMouseDown:tn(t.onMouseDown,v=>{n?c.onItemFocus(u):v.preventDefault()}),onFocus:tn(t.onFocus,()=>c.onItemFocus(u)),onKeyDown:tn(t.onKeyDown,v=>{if(v.key==="Tab"&&v.shiftKey){c.onItemShiftTab();return}if(v.target!==v.currentTarget)return;const y=jnt(v,c.orientation,c.dir);if(y!==void 0){if(v.metaKey||v.ctrlKey||v.altKey||v.shiftKey)return;v.preventDefault();let b=f().filter(S=>S.focusable).map(S=>S.ref.current);if(y==="last")b.reverse();else if(y==="prev"||y==="next"){y==="prev"&&b.reverse();const S=b.indexOf(v.currentTarget);b=c.loop?Vnt(b,S+1):b.slice(S+1)}setTimeout(()=>LRe(b))}}),children:typeof a=="function"?a({isCurrentTabStop:d,hasTabStop:g!=null}):a})})});MRe.displayName=RRe;var Fnt={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Bnt(t,e){return e!=="rtl"?t:t==="ArrowLeft"?"ArrowRight":t==="ArrowRight"?"ArrowLeft":t}function jnt(t,e,i){const n=Bnt(t.key,i);if(!(e==="vertical"&&["ArrowLeft","ArrowRight"].includes(n))&&!(e==="horizontal"&&["ArrowUp","ArrowDown"].includes(n)))return Fnt[n]}function LRe(t,e=!1){const i=document.activeElement;for(const n of t)if(n===i||(n.focus({preventScroll:e}),document.activeElement!==i))return}function Vnt(t,e){return t.map((i,n)=>t[(e+n)%t.length])}var Hnt=DRe,Unt=MRe,znt=function(t){if(typeof document>"u")return null;var e=Array.isArray(t)?t[0]:t;return e.ownerDocument.body},$M=new WeakMap,i4=new WeakMap,n4={},F8=0,kRe=function(t){return t&&(t.host||kRe(t.parentNode))},$nt=function(t,e){return e.map(function(i){if(t.contains(i))return i;var n=kRe(i);return n&&t.contains(n)?n:(console.error("aria-hidden",i,"in not contained inside",t,". Doing nothing"),null)}).filter(function(i){return!!i})},Wnt=function(t,e,i,n){var r=$nt(e,Array.isArray(t)?t:[t]);n4[i]||(n4[i]=new WeakMap);var o=n4[i],a=[],s=new Set,l=new Set(r),u=function(d){!d||s.has(d)||(s.add(d),u(d.parentNode))};r.forEach(u);var c=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(f){if(s.has(f))c(f);else try{var h=f.getAttribute(n),p=h!==null&&h!=="false",g=($M.get(f)||0)+1,v=(o.get(f)||0)+1;$M.set(f,g),o.set(f,v),a.push(f),g===1&&p&&i4.set(f,!0),v===1&&f.setAttribute(i,"true"),p||f.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",f,y)}})};return c(e),s.clear(),F8++,function(){a.forEach(function(d){var f=$M.get(d)-1,h=o.get(d)-1;$M.set(d,f),o.set(d,h),f||(i4.has(d)||d.removeAttribute(n),i4.delete(d)),h||d.removeAttribute(i)}),F8--,F8||($M=new WeakMap,$M=new WeakMap,i4=new WeakMap,n4={})}},Eee=function(t,e,i){i===void 0&&(i="data-aria-hidden");var n=Array.from(Array.isArray(t)?t:[t]),r=znt(t);return r?(n.push.apply(n,Array.from(r.querySelectorAll("[aria-live], script"))),Wnt(n,r,i,"aria-hidden")):function(){return null}},$y=function(){return $y=Object.assign||function(e){for(var i,n=1,r=arguments.length;n<r;n++){i=arguments[n];for(var o in i)Object.prototype.hasOwnProperty.call(i,o)&&(e[o]=i[o])}return e},$y.apply(this,arguments)};function IRe(t,e){var i={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(i[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,n=Object.getOwnPropertySymbols(t);r<n.length;r++)e.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(t,n[r])&&(i[n[r]]=t[n[r]]);return i}function Gnt(t,e,i){if(i||arguments.length===2)for(var n=0,r=e.length,o;n<r;n++)(o||!(n in e))&&(o||(o=Array.prototype.slice.call(e,0,n)),o[n]=e[n]);return t.concat(o||Array.prototype.slice.call(e))}var jU="right-scroll-bar-position",VU="width-before-scroll-bar",Ynt="with-scroll-bars-hidden",qnt="--removed-body-scroll-bar-size";function B8(t,e){return typeof t=="function"?t(e):t&&(t.current=e),t}function Xnt(t,e){var i=J.useState(function(){return{value:t,callback:e,facade:{get current(){return i.value},set current(n){var r=i.value;r!==n&&(i.value=n,i.callback(n,r))}}}})[0];return i.callback=e,i.facade}var Knt=typeof window<"u"?J.useLayoutEffect:J.useEffect,ole=new WeakMap;function Znt(t,e){var i=Xnt(null,function(n){return t.forEach(function(r){return B8(r,n)})});return Knt(function(){var n=ole.get(i);if(n){var r=new Set(n),o=new Set(t),a=i.current;r.forEach(function(s){o.has(s)||B8(s,null)}),o.forEach(function(s){r.has(s)||B8(s,a)})}ole.set(i,t)},[t]),i}function Jnt(t){return t}function Qnt(t,e){e===void 0&&(e=Jnt);var i=[],n=!1,r={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return i.length?i[i.length-1]:t},useMedium:function(o){var a=e(o,n);return i.push(a),function(){i=i.filter(function(s){return s!==a})}},assignSyncMedium:function(o){for(n=!0;i.length;){var a=i;i=[],a.forEach(o)}i={push:function(s){return o(s)},filter:function(){return i}}},assignMedium:function(o){n=!0;var a=[];if(i.length){var s=i;i=[],s.forEach(o),a=i}var l=function(){var c=a;a=[],c.forEach(o)},u=function(){return Promise.resolve().then(l)};u(),i={push:function(c){a.push(c),u()},filter:function(c){return a=a.filter(c),i}}}};return r}function eot(t){t===void 0&&(t={});var e=Qnt(null);return e.options=$y({async:!0,ssr:!1},t),e}var NRe=function(t){var e=t.sideCar,i=IRe(t,["sideCar"]);if(!e)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=e.read();if(!n)throw new Error("Sidecar medium not found");return J.createElement(n,$y({},i))};NRe.isSideCarExport=!0;function tot(t,e){return t.useMedium(e),NRe}var FRe=eot(),j8=function(){},d6=J.forwardRef(function(t,e){var i=J.useRef(null),n=J.useState({onScrollCapture:j8,onWheelCapture:j8,onTouchMoveCapture:j8}),r=n[0],o=n[1],a=t.forwardProps,s=t.children,l=t.className,u=t.removeScrollBar,c=t.enabled,d=t.shards,f=t.sideCar,h=t.noRelative,p=t.noIsolation,g=t.inert,v=t.allowPinchZoom,y=t.as,m=y===void 0?"div":y,b=t.gapMode,S=IRe(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),_=f,C=Znt([i,e]),P=$y($y({},S),r);return J.createElement(J.Fragment,null,c&&J.createElement(_,{sideCar:FRe,removeScrollBar:u,shards:d,noRelative:h,noIsolation:p,inert:g,setCallbacks:o,allowPinchZoom:!!v,lockRef:i,gapMode:b}),a?J.cloneElement(J.Children.only(s),$y($y({},P),{ref:C})):J.createElement(m,$y({},P,{className:l,ref:C}),s))});d6.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};d6.classNames={fullWidth:VU,zeroRight:jU};var rot=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function iot(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var e=rot();return e&&t.setAttribute("nonce",e),t}function not(t,e){t.styleSheet?t.styleSheet.cssText=e:t.appendChild(document.createTextNode(e))}function oot(t){var e=document.head||document.getElementsByTagName("head")[0];e.appendChild(t)}var aot=function(){var t=0,e=null;return{add:function(i){t==0&&(e=iot())&&(not(e,i),oot(e)),t++},remove:function(){t--,!t&&e&&(e.parentNode&&e.parentNode.removeChild(e),e=null)}}},sot=function(){var t=aot();return function(e,i){J.useEffect(function(){return t.add(e),function(){t.remove()}},[e&&i])}},BRe=function(){var t=sot(),e=function(i){var n=i.styles,r=i.dynamic;return t(n,r),null};return e},lot={left:0,top:0,right:0,gap:0},V8=function(t){return parseInt(t||"",10)||0},uot=function(t){var e=window.getComputedStyle(document.body),i=e[t==="padding"?"paddingLeft":"marginLeft"],n=e[t==="padding"?"paddingTop":"marginTop"],r=e[t==="padding"?"paddingRight":"marginRight"];return[V8(i),V8(n),V8(r)]},cot=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return lot;var e=uot(t),i=document.documentElement.clientWidth,n=window.innerWidth;return{left:e[0],top:e[1],right:e[2],gap:Math.max(0,n-i+e[2]-e[0])}},dot=BRe(),$L="data-scroll-locked",fot=function(t,e,i,n){var r=t.left,o=t.top,a=t.right,s=t.gap;return i===void 0&&(i="margin"),`
  .`.concat(Ynt,` {
   overflow: hidden `).concat(n,`;
   padding-right: `).concat(s,"px ").concat(n,`;
  }
  body[`).concat($L,`] {
    overflow: hidden `).concat(n,`;
    overscroll-behavior: contain;
    `).concat([e&&"position: relative ".concat(n,";"),i==="margin"&&`
    padding-left: `.concat(r,`px;
    padding-top: `).concat(o,`px;
    padding-right: `).concat(a,`px;
    margin-left:0;
    margin-top:0;
    margin-right: `).concat(s,"px ").concat(n,`;
    `),i==="padding"&&"padding-right: ".concat(s,"px ").concat(n,";")].filter(Boolean).join(""),`
  }
  
  .`).concat(jU,` {
    right: `).concat(s,"px ").concat(n,`;
  }
  
  .`).concat(VU,` {
    margin-right: `).concat(s,"px ").concat(n,`;
  }
  
  .`).concat(jU," .").concat(jU,` {
    right: 0 `).concat(n,`;
  }
  
  .`).concat(VU," .").concat(VU,` {
    margin-right: 0 `).concat(n,`;
  }
  
  body[`).concat($L,`] {
    `).concat(qnt,": ").concat(s,`px;
  }
`)},ale=function(){var t=parseInt(document.body.getAttribute($L)||"0",10);return isFinite(t)?t:0},hot=function(){J.useEffect(function(){return document.body.setAttribute($L,(ale()+1).toString()),function(){var t=ale()-1;t<=0?document.body.removeAttribute($L):document.body.setAttribute($L,t.toString())}},[])},pot=function(t){var e=t.noRelative,i=t.noImportant,n=t.gapMode,r=n===void 0?"margin":n;hot();var o=J.useMemo(function(){return cot(r)},[r]);return J.createElement(dot,{styles:fot(o,!e,r,i?"":"!important")})},rZ=!1;if(typeof window<"u")try{var o4=Object.defineProperty({},"passive",{get:function(){return rZ=!0,!0}});window.addEventListener("test",o4,o4),window.removeEventListener("test",o4,o4)}catch{rZ=!1}var WM=rZ?{passive:!1}:!1,got=function(t){return t.tagName==="TEXTAREA"},jRe=function(t,e){if(!(t instanceof Element))return!1;var i=window.getComputedStyle(t);return i[e]!=="hidden"&&!(i.overflowY===i.overflowX&&!got(t)&&i[e]==="visible")},vot=function(t){return jRe(t,"overflowY")},yot=function(t){return jRe(t,"overflowX")},sle=function(t,e){var i=e.ownerDocument,n=e;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var r=VRe(t,n);if(r){var o=HRe(t,n),a=o[1],s=o[2];if(a>s)return!0}n=n.parentNode}while(n&&n!==i.body);return!1},mot=function(t){var e=t.scrollTop,i=t.scrollHeight,n=t.clientHeight;return[e,i,n]},bot=function(t){var e=t.scrollLeft,i=t.scrollWidth,n=t.clientWidth;return[e,i,n]},VRe=function(t,e){return t==="v"?vot(e):yot(e)},HRe=function(t,e){return t==="v"?mot(e):bot(e)},Sot=function(t,e){return t==="h"&&e==="rtl"?-1:1},_ot=function(t,e,i,n,r){var o=Sot(t,window.getComputedStyle(e).direction),a=o*n,s=i.target,l=e.contains(s),u=!1,c=a>0,d=0,f=0;do{if(!s)break;var h=HRe(t,s),p=h[0],g=h[1],v=h[2],y=g-v-o*p;(p||y)&&VRe(t,s)&&(d+=y,f+=p);var m=s.parentNode;s=m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE?m.host:m}while(!l&&s!==document.body||l&&(e.contains(s)||e===s));return(c&&Math.abs(d)<1||!c&&Math.abs(f)<1)&&(u=!0),u},a4=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},lle=function(t){return[t.deltaX,t.deltaY]},ule=function(t){return t&&"current"in t?t.current:t},Pot=function(t,e){return t[0]===e[0]&&t[1]===e[1]},Cot=function(t){return`
  .block-interactivity-`.concat(t,` {pointer-events: none;}
  .allow-interactivity-`).concat(t,` {pointer-events: all;}
`)},Tot=0,GM=[];function xot(t){var e=J.useRef([]),i=J.useRef([0,0]),n=J.useRef(),r=J.useState(Tot++)[0],o=J.useState(BRe)[0],a=J.useRef(t);J.useEffect(function(){a.current=t},[t]),J.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(r));var g=Gnt([t.lockRef.current],(t.shards||[]).map(ule),!0).filter(Boolean);return g.forEach(function(v){return v.classList.add("allow-interactivity-".concat(r))}),function(){document.body.classList.remove("block-interactivity-".concat(r)),g.forEach(function(v){return v.classList.remove("allow-interactivity-".concat(r))})}}},[t.inert,t.lockRef.current,t.shards]);var s=J.useCallback(function(g,v){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!a.current.allowPinchZoom;var y=a4(g),m=i.current,b="deltaX"in g?g.deltaX:m[0]-y[0],S="deltaY"in g?g.deltaY:m[1]-y[1],_,C=g.target,P=Math.abs(b)>Math.abs(S)?"h":"v";if("touches"in g&&P==="h"&&C.type==="range")return!1;var x=window.getSelection(),E=x&&x.anchorNode,A=E?E===C||E.contains(C):!1;if(A)return!1;var R=sle(P,C);if(!R)return!0;if(R?_=P:(_=P==="v"?"h":"v",R=sle(P,C)),!R)return!1;if(!n.current&&"changedTouches"in g&&(b||S)&&(n.current=_),!_)return!0;var M=n.current||_;return _ot(M,v,g,M==="h"?b:S)},[]),l=J.useCallback(function(g){var v=g;if(!(!GM.length||GM[GM.length-1]!==o)){var y="deltaY"in v?lle(v):a4(v),m=e.current.filter(function(_){return _.name===v.type&&(_.target===v.target||v.target===_.shadowParent)&&Pot(_.delta,y)})[0];if(m&&m.should){v.cancelable&&v.preventDefault();return}if(!m){var b=(a.current.shards||[]).map(ule).filter(Boolean).filter(function(_){return _.contains(v.target)}),S=b.length>0?s(v,b[0]):!a.current.noIsolation;S&&v.cancelable&&v.preventDefault()}}},[]),u=J.useCallback(function(g,v,y,m){var b={name:g,delta:v,target:y,should:m,shadowParent:Eot(y)};e.current.push(b),setTimeout(function(){e.current=e.current.filter(function(S){return S!==b})},1)},[]),c=J.useCallback(function(g){i.current=a4(g),n.current=void 0},[]),d=J.useCallback(function(g){u(g.type,lle(g),g.target,s(g,t.lockRef.current))},[]),f=J.useCallback(function(g){u(g.type,a4(g),g.target,s(g,t.lockRef.current))},[]);J.useEffect(function(){return GM.push(o),t.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:f}),document.addEventListener("wheel",l,WM),document.addEventListener("touchmove",l,WM),document.addEventListener("touchstart",c,WM),function(){GM=GM.filter(function(g){return g!==o}),document.removeEventListener("wheel",l,WM),document.removeEventListener("touchmove",l,WM),document.removeEventListener("touchstart",c,WM)}},[]);var h=t.removeScrollBar,p=t.inert;return J.createElement(J.Fragment,null,p?J.createElement(o,{styles:Cot(r)}):null,h?J.createElement(pot,{noRelative:t.noRelative,gapMode:t.gapMode}):null)}function Eot(t){for(var e=null;t!==null;)t instanceof ShadowRoot&&(e=t.host,t=t.host),t=t.parentNode;return e}const wot=tot(FRe,xot);var f6=J.forwardRef(function(t,e){return J.createElement(d6,$y({},t,{ref:e,sideCar:wot}))});f6.classNames=d6.classNames;var iZ=["Enter"," "],Aot=["ArrowDown","PageUp","Home"],URe=["ArrowUp","PageDown","End"],Oot=[...Aot,...URe],Dot={ltr:[...iZ,"ArrowRight"],rtl:[...iZ,"ArrowLeft"]},Rot={ltr:["ArrowLeft"],rtl:["ArrowRight"]},TV="Menu",[v3,Mot,Lot]=xRe(TV),[UD,zRe]=kS(TV,[Lot,uI,ORe]),xV=uI(),$Re=ORe(),[WRe,WP]=UD(TV),[kot,EV]=UD(TV),GRe=t=>{const{__scopeMenu:e,open:i=!1,children:n,dir:r,onOpenChange:o,modal:a=!0}=t,s=xV(e),[l,u]=J.useState(null),c=J.useRef(!1),d=um(o),f=ERe(r);return J.useEffect(()=>{const h=()=>{c.current=!0,document.addEventListener("pointerdown",p,{capture:!0,once:!0}),document.addEventListener("pointermove",p,{capture:!0,once:!0})},p=()=>c.current=!1;return document.addEventListener("keydown",h,{capture:!0}),()=>{document.removeEventListener("keydown",h,{capture:!0}),document.removeEventListener("pointerdown",p,{capture:!0}),document.removeEventListener("pointermove",p,{capture:!0})}},[]),L.jsx(k$,{...s,children:L.jsx(WRe,{scope:e,open:i,onOpenChange:d,content:l,onContentChange:u,children:L.jsx(kot,{scope:e,onClose:J.useCallback(()=>d(!1),[d]),isUsingKeyboardRef:c,dir:f,modal:a,children:n})})})};GRe.displayName=TV;var Iot="MenuAnchor",wee=J.forwardRef((t,e)=>{const{__scopeMenu:i,...n}=t,r=xV(i);return L.jsx(I$,{...r,...n,ref:e})});wee.displayName=Iot;var Aee="MenuPortal",[Not,YRe]=UD(Aee,{forceMount:void 0}),qRe=t=>{const{__scopeMenu:e,forceMount:i,children:n,container:r}=t,o=WP(Aee,e);return L.jsx(Not,{scope:e,forceMount:i,children:L.jsx(Mp,{present:i||o.open,children:L.jsx(pV,{asChild:!0,container:r,children:n})})})};qRe.displayName=Aee;var wg="MenuContent",[Fot,Oee]=UD(wg),XRe=J.forwardRef((t,e)=>{const i=YRe(wg,t.__scopeMenu),{forceMount:n=i.forceMount,...r}=t,o=WP(wg,t.__scopeMenu),a=EV(wg,t.__scopeMenu);return L.jsx(v3.Provider,{scope:t.__scopeMenu,children:L.jsx(Mp,{present:n||o.open,children:L.jsx(v3.Slot,{scope:t.__scopeMenu,children:a.modal?L.jsx(Bot,{...r,ref:e}):L.jsx(jot,{...r,ref:e})})})})}),Bot=J.forwardRef((t,e)=>{const i=WP(wg,t.__scopeMenu),n=J.useRef(null),r=Bl(e,n);return J.useEffect(()=>{const o=n.current;if(o)return Eee(o)},[]),L.jsx(Dee,{...t,ref:r,trapFocus:i.open,disableOutsidePointerEvents:i.open,disableOutsideScroll:!0,onFocusOutside:tn(t.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>i.onOpenChange(!1)})}),jot=J.forwardRef((t,e)=>{const i=WP(wg,t.__scopeMenu);return L.jsx(Dee,{...t,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>i.onOpenChange(!1)})}),Vot=yk("MenuContent.ScrollLock"),Dee=J.forwardRef((t,e)=>{const{__scopeMenu:i,loop:n=!1,trapFocus:r,onOpenAutoFocus:o,onCloseAutoFocus:a,disableOutsidePointerEvents:s,onEntryFocus:l,onEscapeKeyDown:u,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:h,disableOutsideScroll:p,...g}=t,v=WP(wg,i),y=EV(wg,i),m=xV(i),b=$Re(i),S=Mot(i),[_,C]=J.useState(null),P=J.useRef(null),x=Bl(e,P,v.onContentChange),E=J.useRef(0),A=J.useRef(""),R=J.useRef(0),M=J.useRef(null),D=J.useRef("right"),F=J.useRef(0),I=p?f6:J.Fragment,V=p?{as:Vot,allowPinchZoom:!0}:void 0,z=H=>{var de,ge;const U=A.current+H,k=S().filter(Ee=>!Ee.disabled),X=document.activeElement,W=(de=k.find(Ee=>Ee.ref.current===X))==null?void 0:de.textValue,Y=k.map(Ee=>Ee.textValue),te=Jot(Y,U,W),oe=(ge=k.find(Ee=>Ee.textValue===te))==null?void 0:ge.ref.current;(function Ee(Re){A.current=Re,window.clearTimeout(E.current),Re!==""&&(E.current=window.setTimeout(()=>Ee(""),1e3))})(U),oe&&setTimeout(()=>oe.focus())};J.useEffect(()=>()=>window.clearTimeout(E.current),[]),xee();const G=J.useCallback(H=>{var k,X;return D.current===((k=M.current)==null?void 0:k.side)&&eat(H,(X=M.current)==null?void 0:X.area)},[]);return L.jsx(Fot,{scope:i,searchRef:A,onItemEnter:J.useCallback(H=>{G(H)&&H.preventDefault()},[G]),onItemLeave:J.useCallback(H=>{var U;G(H)||((U=P.current)==null||U.focus(),C(null))},[G]),onTriggerLeave:J.useCallback(H=>{G(H)&&H.preventDefault()},[G]),pointerGraceTimerRef:R,onPointerGraceIntentChange:J.useCallback(H=>{M.current=H},[]),children:L.jsx(I,{...V,children:L.jsx(c6,{asChild:!0,trapped:r,onMountAutoFocus:tn(o,H=>{var U;H.preventDefault(),(U=P.current)==null||U.focus({preventScroll:!0})}),onUnmountAutoFocus:a,children:L.jsx(fV,{asChild:!0,disableOutsidePointerEvents:s,onEscapeKeyDown:u,onPointerDownOutside:c,onFocusOutside:d,onInteractOutside:f,onDismiss:h,children:L.jsx(Hnt,{asChild:!0,...b,dir:y.dir,orientation:"vertical",loop:n,currentTabStopId:_,onCurrentTabStopIdChange:C,onEntryFocus:tn(l,H=>{y.isUsingKeyboardRef.current||H.preventDefault()}),preventScrollOnEntryFocus:!0,children:L.jsx(oQ,{role:"menu","aria-orientation":"vertical","data-state":fMe(v.open),"data-radix-menu-content":"",dir:y.dir,...m,...g,ref:x,style:{outline:"none",...g.style},onKeyDown:tn(g.onKeyDown,H=>{const k=H.target.closest("[data-radix-menu-content]")===H.currentTarget,X=H.ctrlKey||H.altKey||H.metaKey,W=H.key.length===1;k&&(H.key==="Tab"&&H.preventDefault(),!X&&W&&z(H.key));const Y=P.current;if(H.target!==Y||!Oot.includes(H.key))return;H.preventDefault();const oe=S().filter(de=>!de.disabled).map(de=>de.ref.current);URe.includes(H.key)&&oe.reverse(),Kot(oe)}),onBlur:tn(t.onBlur,H=>{H.currentTarget.contains(H.target)||(window.clearTimeout(E.current),A.current="")}),onPointerMove:tn(t.onPointerMove,y3(H=>{const U=H.target,k=F.current!==H.clientX;if(H.currentTarget.contains(U)&&k){const X=H.clientX>F.current?"right":"left";D.current=X,F.current=H.clientX}}))})})})})})})});XRe.displayName=wg;var Hot="MenuGroup",Ree=J.forwardRef((t,e)=>{const{__scopeMenu:i,...n}=t;return L.jsx(es.div,{role:"group",...n,ref:e})});Ree.displayName=Hot;var Uot="MenuLabel",KRe=J.forwardRef((t,e)=>{const{__scopeMenu:i,...n}=t;return L.jsx(es.div,{...n,ref:e})});KRe.displayName=Uot;var oz="MenuItem",cle="menu.itemSelect",h6=J.forwardRef((t,e)=>{const{disabled:i=!1,onSelect:n,...r}=t,o=J.useRef(null),a=EV(oz,t.__scopeMenu),s=Oee(oz,t.__scopeMenu),l=Bl(e,o),u=J.useRef(!1),c=()=>{const d=o.current;if(!i&&d){const f=new CustomEvent(cle,{bubbles:!0,cancelable:!0});d.addEventListener(cle,h=>n==null?void 0:n(h),{once:!0}),UEe(d,f),f.defaultPrevented?u.current=!1:a.onClose()}};return L.jsx(ZRe,{...r,ref:l,disabled:i,onClick:tn(t.onClick,c),onPointerDown:d=>{var f;(f=t.onPointerDown)==null||f.call(t,d),u.current=!0},onPointerUp:tn(t.onPointerUp,d=>{var f;u.current||(f=d.currentTarget)==null||f.click()}),onKeyDown:tn(t.onKeyDown,d=>{const f=s.searchRef.current!=="";i||f&&d.key===" "||iZ.includes(d.key)&&(d.currentTarget.click(),d.preventDefault())})})});h6.displayName=oz;var ZRe=J.forwardRef((t,e)=>{const{__scopeMenu:i,disabled:n=!1,textValue:r,...o}=t,a=Oee(oz,i),s=$Re(i),l=J.useRef(null),u=Bl(e,l),[c,d]=J.useState(!1),[f,h]=J.useState("");return J.useEffect(()=>{const p=l.current;p&&h((p.textContent??"").trim())},[o.children]),L.jsx(v3.ItemSlot,{scope:i,disabled:n,textValue:r??f,children:L.jsx(Unt,{asChild:!0,...s,focusable:!n,children:L.jsx(es.div,{role:"menuitem","data-highlighted":c?"":void 0,"aria-disabled":n||void 0,"data-disabled":n?"":void 0,...o,ref:u,onPointerMove:tn(t.onPointerMove,y3(p=>{n?a.onItemLeave(p):(a.onItemEnter(p),p.defaultPrevented||p.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:tn(t.onPointerLeave,y3(p=>a.onItemLeave(p))),onFocus:tn(t.onFocus,()=>d(!0)),onBlur:tn(t.onBlur,()=>d(!1))})})})}),zot="MenuCheckboxItem",JRe=J.forwardRef((t,e)=>{const{checked:i=!1,onCheckedChange:n,...r}=t;return L.jsx(iMe,{scope:t.__scopeMenu,checked:i,children:L.jsx(h6,{role:"menuitemcheckbox","aria-checked":az(i)?"mixed":i,...r,ref:e,"data-state":kee(i),onSelect:tn(r.onSelect,()=>n==null?void 0:n(az(i)?!0:!i),{checkForDefaultPrevented:!1})})})});JRe.displayName=zot;var QRe="MenuRadioGroup",[$ot,Wot]=UD(QRe,{value:void 0,onValueChange:()=>{}}),eMe=J.forwardRef((t,e)=>{const{value:i,onValueChange:n,...r}=t,o=um(n);return L.jsx($ot,{scope:t.__scopeMenu,value:i,onValueChange:o,children:L.jsx(Ree,{...r,ref:e})})});eMe.displayName=QRe;var tMe="MenuRadioItem",rMe=J.forwardRef((t,e)=>{const{value:i,...n}=t,r=Wot(tMe,t.__scopeMenu),o=i===r.value;return L.jsx(iMe,{scope:t.__scopeMenu,checked:o,children:L.jsx(h6,{role:"menuitemradio","aria-checked":o,...n,ref:e,"data-state":kee(o),onSelect:tn(n.onSelect,()=>{var a;return(a=r.onValueChange)==null?void 0:a.call(r,i)},{checkForDefaultPrevented:!1})})})});rMe.displayName=tMe;var Mee="MenuItemIndicator",[iMe,Got]=UD(Mee,{checked:!1}),nMe=J.forwardRef((t,e)=>{const{__scopeMenu:i,forceMount:n,...r}=t,o=Got(Mee,i);return L.jsx(Mp,{present:n||az(o.checked)||o.checked===!0,children:L.jsx(es.span,{...r,ref:e,"data-state":kee(o.checked)})})});nMe.displayName=Mee;var Yot="MenuSeparator",oMe=J.forwardRef((t,e)=>{const{__scopeMenu:i,...n}=t;return L.jsx(es.div,{role:"separator","aria-orientation":"horizontal",...n,ref:e})});oMe.displayName=Yot;var qot="MenuArrow",aMe=J.forwardRef((t,e)=>{const{__scopeMenu:i,...n}=t,r=xV(i);return L.jsx(aQ,{...r,...n,ref:e})});aMe.displayName=qot;var Lee="MenuSub",[Xot,sMe]=UD(Lee),lMe=t=>{const{__scopeMenu:e,children:i,open:n=!1,onOpenChange:r}=t,o=WP(Lee,e),a=xV(e),[s,l]=J.useState(null),[u,c]=J.useState(null),d=um(r);return J.useEffect(()=>(o.open===!1&&d(!1),()=>d(!1)),[o.open,d]),L.jsx(k$,{...a,children:L.jsx(WRe,{scope:e,open:n,onOpenChange:d,content:u,onContentChange:c,children:L.jsx(Xot,{scope:e,contentId:Mv(),triggerId:Mv(),trigger:s,onTriggerChange:l,children:i})})})};lMe.displayName=Lee;var oj="MenuSubTrigger",uMe=J.forwardRef((t,e)=>{const i=WP(oj,t.__scopeMenu),n=EV(oj,t.__scopeMenu),r=sMe(oj,t.__scopeMenu),o=Oee(oj,t.__scopeMenu),a=J.useRef(null),{pointerGraceTimerRef:s,onPointerGraceIntentChange:l}=o,u={__scopeMenu:t.__scopeMenu},c=J.useCallback(()=>{a.current&&window.clearTimeout(a.current),a.current=null},[]);return J.useEffect(()=>c,[c]),J.useEffect(()=>{const d=s.current;return()=>{window.clearTimeout(d),l(null)}},[s,l]),L.jsx(wee,{asChild:!0,...u,children:L.jsx(ZRe,{id:r.triggerId,"aria-haspopup":"menu","aria-expanded":i.open,"aria-controls":r.contentId,"data-state":fMe(i.open),...t,ref:O$(e,r.onTriggerChange),onClick:d=>{var f;(f=t.onClick)==null||f.call(t,d),!(t.disabled||d.defaultPrevented)&&(d.currentTarget.focus(),i.open||i.onOpenChange(!0))},onPointerMove:tn(t.onPointerMove,y3(d=>{o.onItemEnter(d),!d.defaultPrevented&&!t.disabled&&!i.open&&!a.current&&(o.onPointerGraceIntentChange(null),a.current=window.setTimeout(()=>{i.onOpenChange(!0),c()},100))})),onPointerLeave:tn(t.onPointerLeave,y3(d=>{var h,p;c();const f=(h=i.content)==null?void 0:h.getBoundingClientRect();if(f){const g=(p=i.content)==null?void 0:p.dataset.side,v=g==="right",y=v?-5:5,m=f[v?"left":"right"],b=f[v?"right":"left"];o.onPointerGraceIntentChange({area:[{x:d.clientX+y,y:d.clientY},{x:m,y:f.top},{x:b,y:f.top},{x:b,y:f.bottom},{x:m,y:f.bottom}],side:g}),window.clearTimeout(s.current),s.current=window.setTimeout(()=>o.onPointerGraceIntentChange(null),300)}else{if(o.onTriggerLeave(d),d.defaultPrevented)return;o.onPointerGraceIntentChange(null)}})),onKeyDown:tn(t.onKeyDown,d=>{var h;const f=o.searchRef.current!=="";t.disabled||f&&d.key===" "||Dot[n.dir].includes(d.key)&&(i.onOpenChange(!0),(h=i.content)==null||h.focus(),d.preventDefault())})})})});uMe.displayName=oj;var cMe="MenuSubContent",dMe=J.forwardRef((t,e)=>{const i=YRe(wg,t.__scopeMenu),{forceMount:n=i.forceMount,...r}=t,o=WP(wg,t.__scopeMenu),a=EV(wg,t.__scopeMenu),s=sMe(cMe,t.__scopeMenu),l=J.useRef(null),u=Bl(e,l);return L.jsx(v3.Provider,{scope:t.__scopeMenu,children:L.jsx(Mp,{present:n||o.open,children:L.jsx(v3.Slot,{scope:t.__scopeMenu,children:L.jsx(Dee,{id:s.contentId,"aria-labelledby":s.triggerId,...r,ref:u,align:"start",side:a.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:c=>{var d;a.isUsingKeyboardRef.current&&((d=l.current)==null||d.focus()),c.preventDefault()},onCloseAutoFocus:c=>c.preventDefault(),onFocusOutside:tn(t.onFocusOutside,c=>{c.target!==s.trigger&&o.onOpenChange(!1)}),onEscapeKeyDown:tn(t.onEscapeKeyDown,c=>{a.onClose(),c.preventDefault()}),onKeyDown:tn(t.onKeyDown,c=>{var h;const d=c.currentTarget.contains(c.target),f=Rot[a.dir].includes(c.key);d&&f&&(o.onOpenChange(!1),(h=s.trigger)==null||h.focus(),c.preventDefault())})})})})})});dMe.displayName=cMe;function fMe(t){return t?"open":"closed"}function az(t){return t==="indeterminate"}function kee(t){return az(t)?"indeterminate":t?"checked":"unchecked"}function Kot(t){const e=document.activeElement;for(const i of t)if(i===e||(i.focus(),document.activeElement!==e))return}function Zot(t,e){return t.map((i,n)=>t[(e+n)%t.length])}function Jot(t,e,i){const r=e.length>1&&Array.from(e).every(u=>u===e[0])?e[0]:e,o=i?t.indexOf(i):-1;let a=Zot(t,Math.max(o,0));r.length===1&&(a=a.filter(u=>u!==i));const l=a.find(u=>u.toLowerCase().startsWith(r.toLowerCase()));return l!==i?l:void 0}function Qot(t,e){const{x:i,y:n}=t;let r=!1;for(let o=0,a=e.length-1;o<e.length;a=o++){const s=e[o],l=e[a],u=s.x,c=s.y,d=l.x,f=l.y;c>n!=f>n&&i<(d-u)*(n-c)/(f-c)+u&&(r=!r)}return r}function eat(t,e){if(!e)return!1;const i={x:t.clientX,y:t.clientY};return Qot(i,e)}function y3(t){return e=>e.pointerType==="mouse"?t(e):void 0}var tat=GRe,rat=wee,iat=qRe,nat=XRe,oat=Ree,aat=KRe,sat=h6,lat=JRe,uat=eMe,cat=rMe,dat=nMe,fat=oMe,hat=aMe,pat=lMe,gat=uMe,vat=dMe,p6="DropdownMenu",[yat]=kS(p6,[zRe]),zd=zRe(),[mat,hMe]=yat(p6),pMe=t=>{const{__scopeDropdownMenu:e,children:i,dir:n,open:r,defaultOpen:o,onOpenChange:a,modal:s=!0}=t,l=zd(e),u=J.useRef(null),[c,d]=ND({prop:r,defaultProp:o??!1,onChange:a,caller:p6});return L.jsx(mat,{scope:e,triggerId:Mv(),triggerRef:u,contentId:Mv(),open:c,onOpenChange:d,onOpenToggle:J.useCallback(()=>d(f=>!f),[d]),modal:s,children:L.jsx(tat,{...l,open:c,onOpenChange:d,dir:n,modal:s,children:i})})};pMe.displayName=p6;var gMe="DropdownMenuTrigger",vMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,disabled:n=!1,...r}=t,o=hMe(gMe,i),a=zd(i);return L.jsx(rat,{asChild:!0,...a,children:L.jsx(es.button,{type:"button",id:o.triggerId,"aria-haspopup":"menu","aria-expanded":o.open,"aria-controls":o.open?o.contentId:void 0,"data-state":o.open?"open":"closed","data-disabled":n?"":void 0,disabled:n,...r,ref:O$(e,o.triggerRef),onPointerDown:tn(t.onPointerDown,s=>{!n&&s.button===0&&s.ctrlKey===!1&&(o.onOpenToggle(),o.open||s.preventDefault())}),onKeyDown:tn(t.onKeyDown,s=>{n||(["Enter"," "].includes(s.key)&&o.onOpenToggle(),s.key==="ArrowDown"&&o.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(s.key)&&s.preventDefault())})})})});vMe.displayName=gMe;var bat="DropdownMenuPortal",yMe=t=>{const{__scopeDropdownMenu:e,...i}=t,n=zd(e);return L.jsx(iat,{...n,...i})};yMe.displayName=bat;var mMe="DropdownMenuContent",bMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=hMe(mMe,i),o=zd(i),a=J.useRef(!1);return L.jsx(nat,{id:r.contentId,"aria-labelledby":r.triggerId,...o,...n,ref:e,onCloseAutoFocus:tn(t.onCloseAutoFocus,s=>{var l;a.current||(l=r.triggerRef.current)==null||l.focus(),a.current=!1,s.preventDefault()}),onInteractOutside:tn(t.onInteractOutside,s=>{const l=s.detail.originalEvent,u=l.button===0&&l.ctrlKey===!0,c=l.button===2||u;(!r.modal||c)&&(a.current=!0)}),style:{...t.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});bMe.displayName=mMe;var Sat="DropdownMenuGroup",SMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(oat,{...r,...n,ref:e})});SMe.displayName=Sat;var _at="DropdownMenuLabel",_Me=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(aat,{...r,...n,ref:e})});_Me.displayName=_at;var Pat="DropdownMenuItem",PMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(sat,{...r,...n,ref:e})});PMe.displayName=Pat;var Cat="DropdownMenuCheckboxItem",Tat=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(lat,{...r,...n,ref:e})});Tat.displayName=Cat;var xat="DropdownMenuRadioGroup",Eat=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(uat,{...r,...n,ref:e})});Eat.displayName=xat;var wat="DropdownMenuRadioItem",Aat=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(cat,{...r,...n,ref:e})});Aat.displayName=wat;var Oat="DropdownMenuItemIndicator",Dat=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(dat,{...r,...n,ref:e})});Dat.displayName=Oat;var Rat="DropdownMenuSeparator",CMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(fat,{...r,...n,ref:e})});CMe.displayName=Rat;var Mat="DropdownMenuArrow",Lat=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(hat,{...r,...n,ref:e})});Lat.displayName=Mat;var kat=t=>{const{__scopeDropdownMenu:e,children:i,open:n,onOpenChange:r,defaultOpen:o}=t,a=zd(e),[s,l]=ND({prop:n,defaultProp:o??!1,onChange:r,caller:"DropdownMenuSub"});return L.jsx(pat,{...a,open:s,onOpenChange:l,children:i})},Iat="DropdownMenuSubTrigger",TMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(gat,{...r,...n,ref:e})});TMe.displayName=Iat;var Nat="DropdownMenuSubContent",xMe=J.forwardRef((t,e)=>{const{__scopeDropdownMenu:i,...n}=t,r=zd(i);return L.jsx(vat,{...r,...n,ref:e,style:{...t.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});xMe.displayName=Nat;var Ik=pMe,Nk=vMe,AD=yMe,Fk=bMe,EMe=SMe,wMe=_Me,dm=PMe,Fat=CMe,Bat=kat,jat=TMe,Vat=xMe;const dle=Hr("flex items-center gap-2 px-3 py-1.5 text-xs outline-none cursor-pointer transition-colors","text-foreground data-[highlighted]:bg-muted rounded-sm");function Hat(t){var M;const e=qt.c(44),{track:i}=el();let n;e[0]!==t||e[1]!==i?(n=D=>{D!==t.currentViewMode&&i(Fi.ViewModeChanged,{fileType:t.fileType,viewMode:D}),t.onViewModeChange(D)},e[0]=t,e[1]=i,e[2]=n):n=e[2];const r=n;let o;e[3]!==t.currentViewMode||e[4]!==t.viewModeOptions?(o=((M=t.viewModeOptions.find(D=>D.value===t.currentViewMode))==null?void 0:M.label)??t.currentViewMode,e[3]=t.currentViewMode,e[4]=t.viewModeOptions,e[5]=o):o=e[5];const a=o;let s;e[6]!==t.filePath?(s=L.jsx("div",{className:"min-w-0 flex-1",children:L.jsx("p",{title:t.filePath,className:"text-xs text-muted-foreground font-mono truncate",children:t.filePath})}),e[6]=t.filePath,e[7]=s):s=e[7];let l;e[8]===Symbol.for("react.memo_cache_sentinel")?(l=L.jsx(Nk,{asChild:!0,children:L.jsx("button",{className:Hr("py-0.5 -my-0.5 rounded transition-all","text-muted-foreground hover:bg-muted hover:text-foreground","data-[state=open]:bg-muted data-[state=open]:text-foreground"),children:L.jsx(Wr,{type:dr.NAV_MORE_VERTICAL,className:"w-4 h-4"})})}),e[8]=l):l=e[8];const u=t.viewModeOptions.length<=1,c=t.viewModeOptions.length<=1?"There is only one view mode available for this file.":"",d=t.viewModeOptions.length<=1&&"cursor-not-allowed opacity-50";let f;e[9]!==d?(f=Hr("flex items-center justify-between px-3 py-1.5 text-xs outline-none cursor-pointer transition-colors","text-popover-foreground data-[highlighted]:bg-muted rounded-sm",d),e[9]=d,e[10]=f):f=e[10];let h;e[11]===Symbol.for("react.memo_cache_sentinel")?(h=L.jsx("span",{children:"View Mode"}),e[11]=h):h=e[11];let p;e[12]!==a?(p=L.jsx("span",{className:"text-muted-foreground",children:a}),e[12]=a,e[13]=p):p=e[13];let g;e[14]===Symbol.for("react.memo_cache_sentinel")?(g=L.jsx(Wr,{type:dr.NAV_CHEVRON_RIGHT,className:"w-3 h-3 text-muted-foreground"}),e[14]=g):g=e[14];let v;e[15]!==p?(v=L.jsxs("div",{className:"flex items-center gap-1.5 ml-4",children:[p,g]}),e[15]=p,e[16]=v):v=e[16];let y;e[17]!==v||e[18]!==u||e[19]!==c||e[20]!==f?(y=L.jsxs(jat,{disabled:u,title:c,className:f,children:[h,v]}),e[17]=v,e[18]=u,e[19]=c,e[20]=f,e[21]=y):y=e[21];let m;if(e[22]!==r||e[23]!==t.viewModeOptions){let D;e[25]!==r?(D=F=>L.jsxs(dm,{onSelect:()=>r(F.value),className:dle,children:[F.icon&&L.jsx(Wr,{type:F.icon,className:"w-3.5 h-3.5"}),L.jsx("span",{children:F.label||F.value})]},F.value),e[25]=r,e[26]=D):D=e[26],m=t.viewModeOptions.map(D),e[22]=r,e[23]=t.viewModeOptions,e[24]=m}else m=e[24];let b;e[27]!==m?(b=L.jsx(AD,{children:L.jsx(Vat,{sideOffset:4,className:"z-50 min-w-[140px] bg-popover border border-border rounded-md shadow-lg p-1 animate-in fade-in-0 zoom-in-95",children:m})}),e[27]=m,e[28]=b):b=e[28];let S;e[29]!==y||e[30]!==b?(S=L.jsxs(Bat,{children:[y,b]}),e[29]=y,e[30]=b,e[31]=S):S=e[31];const _=!t.hasOtherTabs,C=t.onCloseOtherTabs,P=!t.hasOtherTabs&&"cursor-not-allowed opacity-50";let x;e[32]!==P?(x=Hr(dle,P),e[32]=P,e[33]=x):x=e[33];let E;e[34]!==t.onCloseOtherTabs||e[35]!==_||e[36]!==x?(E=L.jsx(L.Fragment,{children:L.jsx(dm,{disabled:_,onSelect:C,className:x,children:"Close all other tabs"})}),e[34]=t.onCloseOtherTabs,e[35]=_,e[36]=x,e[37]=E):E=e[37];let A;e[38]!==S||e[39]!==E?(A=L.jsxs(Ik,{children:[l,L.jsx(AD,{children:L.jsxs(Fk,{align:"end",sideOffset:4,className:"z-50 min-w-[160px] bg-popover border border-border rounded-md shadow-lg p-1 animate-in fade-in-0 zoom-in-95",children:[S,E]})})]}),e[38]=S,e[39]=E,e[40]=A):A=e[40];let R;return e[41]!==s||e[42]!==A?(R=L.jsx("div",{className:"flex-shrink-0 p-0 ps-1 pt-1 pb-2",children:L.jsxs("div",{className:"flex items-center gap-3",children:[s,A]})}),e[41]=s,e[42]=A,e[43]=R):R=e[43],R}function Uat(t){if(!t)return"text";const e=t.toLowerCase().replace(/^\./,"");return{dbc:"dbc",arxml:"xml",json:"json",yaml:"yaml",yml:"yaml",toml:"toml",platform:"toml",py:"python",ipynb:"json",js:"javascript",ts:"typescript",tsx:"typescript",jsx:"javascript",csv:"csv",xml:"xml",md:"markdown",txt:"text",record:"text",remotivedb:"text"}[e]||"text"}const zat={[Ef.IMAGE]:Xi.FILE_IMAGE,[Ef.VIDEO]:Xi.FILE_VIDEO,[Ef.AUDIO]:Xi.FILE_AUDIO,[Ef.SIGNAL_DATABASE]:Xi.FILE_DATABASE,[Ef.PLATFORM]:Xi.FILE_PLATFORM,[Ef.INSTANCE]:Xi.FILE_INSTANCE,[Ef.RECORDING]:Xi.FILE_RECORDING,[Ef.RECORDING_SESSION]:Xi.FILE_RECORDING,[Ef.RECORDING_MAPPING]:Xi.FILE_RECORDING,[Ef.DASHBOARD]:Xi.FILE_DASHBOARD},$at={".py":Xi.FILE_CODE,".ipynb":Xi.FILE_CODE,".js":Xi.FILE_CODE,".ts":Xi.FILE_CODE};function Wat(t,e){if(t){const n=zat[t];if(n)return n}const i=e==null?void 0:e.toLowerCase();if(i){const n=$at[i];if(n)return n}return Xi.FILE_GENERIC}function Gat(t,e){return dV(Wat(t,e))}function Yat(t){if(hQ.has(t))return[];if(pQ.has(t))return[];if(gQ.has(t))return[];const e=[];return Twe.has(t)&&e.push("text"),_we.has(t)&&e.push("platform"),Pwe.has(t)&&e.push("instance"),Cwe.has(t)&&e.push("dashboard"),e}function qat(t){return t?gQ.has(t)||hQ.has(t)||pQ.has(t):!1}const Xat={text:{label:"Text",iconName:Xi.CONTENT_CODE},platform:{label:"Platform",iconName:Xi.SYSTEM_NETWORK},instance:{label:"Instance",iconName:Xi.SYSTEM_NETWORK},"signal-database":{label:"Table",iconName:Xi.DATA_TABLE},dashboard:{label:"Dashboard",iconName:Xi.FILE_DASHBOARD}};var g6="Popover",[AMe]=kS(g6,[uI]),wV=uI(),[Kat,GP]=AMe(g6),OMe=t=>{const{__scopePopover:e,children:i,open:n,defaultOpen:r,onOpenChange:o,modal:a=!1}=t,s=wV(e),l=J.useRef(null),[u,c]=J.useState(!1),[d,f]=ND({prop:n,defaultProp:r??!1,onChange:o,caller:g6});return L.jsx(k$,{...s,children:L.jsx(Kat,{scope:e,contentId:Mv(),triggerRef:l,open:d,onOpenChange:f,onOpenToggle:J.useCallback(()=>f(h=>!h),[f]),hasCustomAnchor:u,onCustomAnchorAdd:J.useCallback(()=>c(!0),[]),onCustomAnchorRemove:J.useCallback(()=>c(!1),[]),modal:a,children:i})})};OMe.displayName=g6;var DMe="PopoverAnchor",Zat=J.forwardRef((t,e)=>{const{__scopePopover:i,...n}=t,r=GP(DMe,i),o=wV(i),{onCustomAnchorAdd:a,onCustomAnchorRemove:s}=r;return J.useEffect(()=>(a(),()=>s()),[a,s]),L.jsx(I$,{...o,...n,ref:e})});Zat.displayName=DMe;var RMe="PopoverTrigger",MMe=J.forwardRef((t,e)=>{const{__scopePopover:i,...n}=t,r=GP(RMe,i),o=wV(i),a=Bl(e,r.triggerRef),s=L.jsx(es.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":FMe(r.open),...n,ref:a,onClick:tn(t.onClick,r.onOpenToggle)});return r.hasCustomAnchor?s:L.jsx(I$,{asChild:!0,...o,children:s})});MMe.displayName=RMe;var Iee="PopoverPortal",[Jat,Qat]=AMe(Iee,{forceMount:void 0}),LMe=t=>{const{__scopePopover:e,forceMount:i,children:n,container:r}=t,o=GP(Iee,e);return L.jsx(Jat,{scope:e,forceMount:i,children:L.jsx(Mp,{present:i||o.open,children:L.jsx(pV,{asChild:!0,container:r,children:n})})})};LMe.displayName=Iee;var Bk="PopoverContent",kMe=J.forwardRef((t,e)=>{const i=Qat(Bk,t.__scopePopover),{forceMount:n=i.forceMount,...r}=t,o=GP(Bk,t.__scopePopover);return L.jsx(Mp,{present:n||o.open,children:o.modal?L.jsx(tst,{...r,ref:e}):L.jsx(rst,{...r,ref:e})})});kMe.displayName=Bk;var est=yk("PopoverContent.RemoveScroll"),tst=J.forwardRef((t,e)=>{const i=GP(Bk,t.__scopePopover),n=J.useRef(null),r=Bl(e,n),o=J.useRef(!1);return J.useEffect(()=>{const a=n.current;if(a)return Eee(a)},[]),L.jsx(f6,{as:est,allowPinchZoom:!0,children:L.jsx(IMe,{...t,ref:r,trapFocus:i.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:tn(t.onCloseAutoFocus,a=>{var s;a.preventDefault(),o.current||(s=i.triggerRef.current)==null||s.focus()}),onPointerDownOutside:tn(t.onPointerDownOutside,a=>{const s=a.detail.originalEvent,l=s.button===0&&s.ctrlKey===!0,u=s.button===2||l;o.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:tn(t.onFocusOutside,a=>a.preventDefault(),{checkForDefaultPrevented:!1})})})}),rst=J.forwardRef((t,e)=>{const i=GP(Bk,t.__scopePopover),n=J.useRef(!1),r=J.useRef(!1);return L.jsx(IMe,{...t,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var a,s;(a=t.onCloseAutoFocus)==null||a.call(t,o),o.defaultPrevented||(n.current||(s=i.triggerRef.current)==null||s.focus(),o.preventDefault()),n.current=!1,r.current=!1},onInteractOutside:o=>{var l,u;(l=t.onInteractOutside)==null||l.call(t,o),o.defaultPrevented||(n.current=!0,o.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const a=o.target;((u=i.triggerRef.current)==null?void 0:u.contains(a))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&r.current&&o.preventDefault()}})}),IMe=J.forwardRef((t,e)=>{const{__scopePopover:i,trapFocus:n,onOpenAutoFocus:r,onCloseAutoFocus:o,disableOutsidePointerEvents:a,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:c,...d}=t,f=GP(Bk,i),h=wV(i);return xee(),L.jsx(c6,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:r,onUnmountAutoFocus:o,children:L.jsx(fV,{asChild:!0,disableOutsidePointerEvents:a,onInteractOutside:c,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>f.onOpenChange(!1),children:L.jsx(oQ,{"data-state":FMe(f.open),role:"dialog",id:f.contentId,...h,...d,ref:e,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),NMe="PopoverClose",ist=J.forwardRef((t,e)=>{const{__scopePopover:i,...n}=t,r=GP(NMe,i);return L.jsx(es.button,{type:"button",...n,ref:e,onClick:tn(t.onClick,()=>r.onOpenChange(!1))})});ist.displayName=NMe;var nst="PopoverArrow",ost=J.forwardRef((t,e)=>{const{__scopePopover:i,...n}=t,r=wV(i);return L.jsx(aQ,{...r,...n,ref:e})});ost.displayName=nst;function FMe(t){return t?"open":"closed"}var ast=OMe,sst=MMe,lst=LMe,ust=kMe;function Gn(){return Gn=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var n in i)({}).hasOwnProperty.call(i,n)&&(t[n]=i[n])}return t},Gn.apply(null,arguments)}function q_(t){if(typeof t!="object"||t===null)return!1;const e=Object.getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)}function BMe(t){if(J.isValidElement(t)||!q_(t))return t;const e={};return Object.keys(t).forEach(i=>{e[i]=BMe(t[i])}),e}function nm(t,e,i={clone:!0}){const n=i.clone?Gn({},t):t;return q_(t)&&q_(e)&&Object.keys(e).forEach(r=>{J.isValidElement(e[r])?n[r]=e[r]:q_(e[r])&&Object.prototype.hasOwnProperty.call(t,r)&&q_(t[r])?n[r]=nm(t[r],e[r],i):i.clone?n[r]=q_(e[r])?BMe(e[r]):e[r]:n[r]=e[r]}),n}const cst=Object.freeze(Object.defineProperty({__proto__:null,default:nm,isPlainObject:q_},Symbol.toStringTag,{value:"Module"}));function m3(t){let e="https://mui.com/production-error/?code="+t;for(let i=1;i<arguments.length;i+=1)e+="&args[]="+encodeURIComponent(arguments[i]);return"Minified MUI error #"+t+"; visit "+e+" for the full message."}const dst=Object.freeze(Object.defineProperty({__proto__:null,default:m3},Symbol.toStringTag,{value:"Module"}));var H8={exports:{}},$a={};/**
 * @license React
 * react-is.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 fle;function fst(){if(fle)return $a;fle=1;var t=Symbol.for("react.transitional.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),r=Symbol.for("react.profiler"),o=Symbol.for("react.consumer"),a=Symbol.for("react.context"),s=Symbol.for("react.forward_ref"),l=Symbol.for("react.suspense"),u=Symbol.for("react.suspense_list"),c=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.for("react.view_transition"),h=Symbol.for("react.client.reference");function p(g){if(typeof g=="object"&&g!==null){var v=g.$$typeof;switch(v){case t:switch(g=g.type,g){case i:case r:case n:case l:case u:case f:return g;default:switch(g=g&&g.$$typeof,g){case a:case s:case d:case c:return g;case o:return g;default:return v}}case e:return v}}}return $a.ContextConsumer=o,$a.ContextProvider=a,$a.Element=t,$a.ForwardRef=s,$a.Fragment=i,$a.Lazy=d,$a.Memo=c,$a.Portal=e,$a.Profiler=r,$a.StrictMode=n,$a.Suspense=l,$a.SuspenseList=u,$a.isContextConsumer=function(g){return p(g)===o},$a.isContextProvider=function(g){return p(g)===a},$a.isElement=function(g){return typeof g=="object"&&g!==null&&g.$$typeof===t},$a.isForwardRef=function(g){return p(g)===s},$a.isFragment=function(g){return p(g)===i},$a.isLazy=function(g){return p(g)===d},$a.isMemo=function(g){return p(g)===c},$a.isPortal=function(g){return p(g)===e},$a.isProfiler=function(g){return p(g)===r},$a.isStrictMode=function(g){return p(g)===n},$a.isSuspense=function(g){return p(g)===l},$a.isSuspenseList=function(g){return p(g)===u},$a.isValidElementType=function(g){return typeof g=="string"||typeof g=="function"||g===i||g===r||g===n||g===l||g===u||typeof g=="object"&&g!==null&&(g.$$typeof===d||g.$$typeof===c||g.$$typeof===a||g.$$typeof===o||g.$$typeof===s||g.$$typeof===h||g.getModuleId!==void 0)},$a.typeOf=p,$a}var hle;function hst(){return hle||(hle=1,H8.exports=fst()),H8.exports}var ple=hst();const pst=/^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^(\s/]*)\s*/;function jMe(t){const e=`${t}`.match(pst);return e&&e[1]||""}function VMe(t,e=""){return t.displayName||t.name||jMe(t)||e}function gle(t,e,i){const n=VMe(e);return t.displayName||(n!==""?`${i}(${n})`:i)}function gst(t){if(t!=null){if(typeof t=="string")return t;if(typeof t=="function")return VMe(t,"Component");if(typeof t=="object")switch(t.$$typeof){case ple.ForwardRef:return gle(t,t.render,"ForwardRef");case ple.Memo:return gle(t,t.type,"memo");default:return}}}const vst=Object.freeze(Object.defineProperty({__proto__:null,default:gst,getFunctionName:jMe},Symbol.toStringTag,{value:"Module"}));function OD(t){if(typeof t!="string")throw new Error(m3(7));return t.charAt(0).toUpperCase()+t.slice(1)}const yst=Object.freeze(Object.defineProperty({__proto__:null,default:OD},Symbol.toStringTag,{value:"Module"}));function nZ(t,e){const i=Gn({},e);return Object.keys(t).forEach(n=>{if(n.toString().match(/^(components|slots)$/))i[n]=Gn({},t[n],i[n]);else if(n.toString().match(/^(componentsProps|slotProps)$/)){const r=t[n]||{},o=e[n];i[n]={},!o||!Object.keys(o)?i[n]=r:!r||!Object.keys(r)?i[n]=o:(i[n]=Gn({},o),Object.keys(r).forEach(a=>{i[n][a]=nZ(r[a],o[a])}))}else i[n]===void 0&&(i[n]=t[n])}),i}function mst(t,e,i=void 0){const n={};return Object.keys(t).forEach(r=>{n[r]=t[r].reduce((o,a)=>{if(a){const s=e(a);s!==""&&o.push(s),i&&i[a]&&o.push(i[a])}return o},[]).join(" ")}),n}const vle=t=>t,bst=()=>{let t=vle;return{configure(e){t=e},generate(e){return t(e)},reset(){t=vle}}},Sst=bst(),_st={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function HMe(t,e,i="Mui"){const n=_st[e];return n?`${i}-${n}`:`${Sst.generate(t)}-${e}`}function Pst(t,e,i="Mui"){const n={};return e.forEach(r=>{n[r]=HMe(t,r,i)}),n}function Cst(t,e=Number.MIN_SAFE_INTEGER,i=Number.MAX_SAFE_INTEGER){return Math.max(e,Math.min(t,i))}const Tst=Object.freeze(Object.defineProperty({__proto__:null,default:Cst},Symbol.toStringTag,{value:"Module"}));function FS(t,e){if(t==null)return{};var i={};for(var n in t)if({}.hasOwnProperty.call(t,n)){if(e.indexOf(n)!==-1)continue;i[n]=t[n]}return i}const xst=J.createContext(void 0);function Est(t){const{theme:e,name:i,props:n}=t;if(!e||!e.components||!e.components[i])return n;const r=e.components[i];return r.defaultProps?nZ(r.defaultProps,n):!r.styleOverrides&&!r.variants?nZ(r,n):n}function wst({props:t,name:e}){const i=J.useContext(xst);return Est({props:t,name:e,theme:{components:i}})}function Ast(t){return wst(t)}var yT={},U8={exports:{}},yle;function UMe(){return yle||(yle=1,(function(t){function e(i){return i&&i.__esModule?i:{default:i}}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})(U8)),U8.exports}var z8={exports:{}},mle;function zMe(){return mle||(mle=1,(function(t){function e(){return t.exports=e=Object.assign?Object.assign.bind():function(i){for(var n=1;n<arguments.length;n++){var r=arguments[n];for(var o in r)({}).hasOwnProperty.call(r,o)&&(i[o]=r[o])}return i},t.exports.__esModule=!0,t.exports.default=t.exports,e.apply(null,arguments)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})(z8)),z8.exports}var $8={exports:{}},ble;function Ost(){return ble||(ble=1,(function(t){function e(i,n){if(i==null)return{};var r={};for(var o in i)if({}.hasOwnProperty.call(i,o)){if(n.indexOf(o)!==-1)continue;r[o]=i[o]}return r}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports})($8)),$8.exports}function Dst(t){if(t.sheet)return t.sheet;for(var e=0;e<document.styleSheets.length;e++)if(document.styleSheets[e].ownerNode===t)return document.styleSheets[e]}function Rst(t){var e=document.createElement("style");return e.setAttribute("data-emotion",t.key),t.nonce!==void 0&&e.setAttribute("nonce",t.nonce),e.appendChild(document.createTextNode("")),e.setAttribute("data-s",""),e}var Mst=(function(){function t(i){var n=this;this._insertTag=function(r){var o;n.tags.length===0?n.insertionPoint?o=n.insertionPoint.nextSibling:n.prepend?o=n.container.firstChild:o=n.before:o=n.tags[n.tags.length-1].nextSibling,n.container.insertBefore(r,o),n.tags.push(r)},this.isSpeedy=i.speedy===void 0?!0:i.speedy,this.tags=[],this.ctr=0,this.nonce=i.nonce,this.key=i.key,this.container=i.container,this.prepend=i.prepend,this.insertionPoint=i.insertionPoint,this.before=null}var e=t.prototype;return e.hydrate=function(n){n.forEach(this._insertTag)},e.insert=function(n){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(Rst(this));var r=this.tags[this.tags.length-1];if(this.isSpeedy){var o=Dst(r);try{o.insertRule(n,o.cssRules.length)}catch{}}else r.appendChild(document.createTextNode(n));this.ctr++},e.flush=function(){this.tags.forEach(function(n){var r;return(r=n.parentNode)==null?void 0:r.removeChild(n)}),this.tags=[],this.ctr=0},t})(),Ld="-ms-",sz="-moz-",ca="-webkit-",$Me="comm",Nee="rule",Fee="decl",Lst="@import",WMe="@keyframes",kst="@layer",Ist=Math.abs,v6=String.fromCharCode,Nst=Object.assign;function Fst(t,e){return rd(t,0)^45?(((e<<2^rd(t,0))<<2^rd(t,1))<<2^rd(t,2))<<2^rd(t,3):0}function GMe(t){return t.trim()}function Bst(t,e){return(t=e.exec(t))?t[0]:t}function da(t,e,i){return t.replace(e,i)}function oZ(t,e){return t.indexOf(e)}function rd(t,e){return t.charCodeAt(e)|0}function b3(t,e,i){return t.slice(e,i)}function jy(t){return t.length}function Bee(t){return t.length}function s4(t,e){return e.push(t),t}function jst(t,e){return t.map(e).join("")}var y6=1,jk=1,YMe=0,Mh=0,Mu=0,gI="";function m6(t,e,i,n,r,o,a){return{value:t,root:e,parent:i,type:n,props:r,children:o,line:y6,column:jk,length:a,return:""}}function Z2(t,e){return Nst(m6("",null,null,"",null,null,0),t,{length:-t.length},e)}function Vst(){return Mu}function Hst(){return Mu=Mh>0?rd(gI,--Mh):0,jk--,Mu===10&&(jk=1,y6--),Mu}function Ap(){return Mu=Mh<YMe?rd(gI,Mh++):0,jk++,Mu===10&&(jk=1,y6++),Mu}function om(){return rd(gI,Mh)}function HU(){return Mh}function AV(t,e){return b3(gI,t,e)}function S3(t){switch(t){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function qMe(t){return y6=jk=1,YMe=jy(gI=t),Mh=0,[]}function XMe(t){return gI="",t}function UU(t){return GMe(AV(Mh-1,aZ(t===91?t+2:t===40?t+1:t)))}function Ust(t){for(;(Mu=om())&&Mu<33;)Ap();return S3(t)>2||S3(Mu)>3?"":" "}function zst(t,e){for(;--e&&Ap()&&!(Mu<48||Mu>102||Mu>57&&Mu<65||Mu>70&&Mu<97););return AV(t,HU()+(e<6&&om()==32&&Ap()==32))}function aZ(t){for(;Ap();)switch(Mu){case t:return Mh;case 34:case 39:t!==34&&t!==39&&aZ(Mu);break;case 40:t===41&&aZ(t);break;case 92:Ap();break}return Mh}function $st(t,e){for(;Ap()&&t+Mu!==57;)if(t+Mu===84&&om()===47)break;return"/*"+AV(e,Mh-1)+"*"+v6(t===47?t:Ap())}function Wst(t){for(;!S3(om());)Ap();return AV(t,Mh)}function Gst(t){return XMe(zU("",null,null,null,[""],t=qMe(t),0,[0],t))}function zU(t,e,i,n,r,o,a,s,l){for(var u=0,c=0,d=a,f=0,h=0,p=0,g=1,v=1,y=1,m=0,b="",S=r,_=o,C=n,P=b;v;)switch(p=m,m=Ap()){case 40:if(p!=108&&rd(P,d-1)==58){oZ(P+=da(UU(m),"&","&\f"),"&\f")!=-1&&(y=-1);break}case 34:case 39:case 91:P+=UU(m);break;case 9:case 10:case 13:case 32:P+=Ust(p);break;case 92:P+=zst(HU()-1,7);continue;case 47:switch(om()){case 42:case 47:s4(Yst($st(Ap(),HU()),e,i),l);break;default:P+="/"}break;case 123*g:s[u++]=jy(P)*y;case 125*g:case 59:case 0:switch(m){case 0:case 125:v=0;case 59+c:y==-1&&(P=da(P,/\f/g,"")),h>0&&jy(P)-d&&s4(h>32?_le(P+";",n,i,d-1):_le(da(P," ","")+";",n,i,d-2),l);break;case 59:P+=";";default:if(s4(C=Sle(P,e,i,u,c,r,s,b,S=[],_=[],d),o),m===123)if(c===0)zU(P,e,C,C,S,o,d,s,_);else switch(f===99&&rd(P,3)===110?100:f){case 100:case 108:case 109:case 115:zU(t,C,C,n&&s4(Sle(t,C,C,0,0,r,s,b,r,S=[],d),_),r,_,d,s,n?S:_);break;default:zU(P,C,C,C,[""],_,0,s,_)}}u=c=h=0,g=y=1,b=P="",d=a;break;case 58:d=1+jy(P),h=p;default:if(g<1){if(m==123)--g;else if(m==125&&g++==0&&Hst()==125)continue}switch(P+=v6(m),m*g){case 38:y=c>0?1:(P+="\f",-1);break;case 44:s[u++]=(jy(P)-1)*y,y=1;break;case 64:om()===45&&(P+=UU(Ap())),f=om(),c=d=jy(b=P+=Wst(HU())),m++;break;case 45:p===45&&jy(P)==2&&(g=0)}}return o}function Sle(t,e,i,n,r,o,a,s,l,u,c){for(var d=r-1,f=r===0?o:[""],h=Bee(f),p=0,g=0,v=0;p<n;++p)for(var y=0,m=b3(t,d+1,d=Ist(g=a[p])),b=t;y<h;++y)(b=GMe(g>0?f[y]+" "+m:da(m,/&\f/g,f[y])))&&(l[v++]=b);return m6(t,e,i,r===0?Nee:s,l,u,c)}function Yst(t,e,i){return m6(t,e,i,$Me,v6(Vst()),b3(t,2,-2),0)}function _le(t,e,i,n){return m6(t,e,i,Fee,b3(t,0,n),b3(t,n+1,-1),n)}function WL(t,e){for(var i="",n=Bee(t),r=0;r<n;r++)i+=e(t[r],r,t,e)||"";return i}function qst(t,e,i,n){switch(t.type){case kst:if(t.children.length)break;case Lst:case Fee:return t.return=t.return||t.value;case $Me:return"";case WMe:return t.return=t.value+"{"+WL(t.children,n)+"}";case Nee:t.value=t.props.join(",")}return jy(i=WL(t.children,n))?t.return=t.value+"{"+i+"}":""}function Xst(t){var e=Bee(t);return function(i,n,r,o){for(var a="",s=0;s<e;s++)a+=t[s](i,n,r,o)||"";return a}}function Kst(t){return function(e){e.root||(e=e.return)&&t(e)}}function KMe(t){var e=Object.create(null);return function(i){return e[i]===void 0&&(e[i]=t(i)),e[i]}}var Zst=function(e,i,n){for(var r=0,o=0;r=o,o=om(),r===38&&o===12&&(i[n]=1),!S3(o);)Ap();return AV(e,Mh)},Jst=function(e,i){var n=-1,r=44;do switch(S3(r)){case 0:r===38&&om()===12&&(i[n]=1),e[n]+=Zst(Mh-1,i,n);break;case 2:e[n]+=UU(r);break;case 4:if(r===44){e[++n]=om()===58?"&\f":"",i[n]=e[n].length;break}default:e[n]+=v6(r)}while(r=Ap());return e},Qst=function(e,i){return XMe(Jst(qMe(e),i))},Ple=new WeakMap,elt=function(e){if(!(e.type!=="rule"||!e.parent||e.length<1)){for(var i=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;n.type!=="rule";)if(n=n.parent,!n)return;if(!(e.props.length===1&&i.charCodeAt(0)!==58&&!Ple.get(n))&&!r){Ple.set(e,!0);for(var o=[],a=Qst(i,o),s=n.props,l=0,u=0;l<a.length;l++)for(var c=0;c<s.length;c++,u++)e.props[u]=o[l]?a[l].replace(/&\f/g,s[c]):s[c]+" "+a[l]}}},tlt=function(e){if(e.type==="decl"){var i=e.value;i.charCodeAt(0)===108&&i.charCodeAt(2)===98&&(e.return="",e.value="")}};function ZMe(t,e){switch(Fst(t,e)){case 5103:return ca+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return ca+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return ca+t+sz+t+Ld+t+t;case 6828:case 4268:return ca+t+Ld+t+t;case 6165:return ca+t+Ld+"flex-"+t+t;case 5187:return ca+t+da(t,/(\w+).+(:[^]+)/,ca+"box-$1$2"+Ld+"flex-$1$2")+t;case 5443:return ca+t+Ld+"flex-item-"+da(t,/flex-|-self/,"")+t;case 4675:return ca+t+Ld+"flex-line-pack"+da(t,/align-content|flex-|-self/,"")+t;case 5548:return ca+t+Ld+da(t,"shrink","negative")+t;case 5292:return ca+t+Ld+da(t,"basis","preferred-size")+t;case 6060:return ca+"box-"+da(t,"-grow","")+ca+t+Ld+da(t,"grow","positive")+t;case 4554:return ca+da(t,/([^-])(transform)/g,"$1"+ca+"$2")+t;case 6187:return da(da(da(t,/(zoom-|grab)/,ca+"$1"),/(image-set)/,ca+"$1"),t,"")+t;case 5495:case 3959:return da(t,/(image-set\([^]*)/,ca+"$1$`$1");case 4968:return da(da(t,/(.+:)(flex-)?(.*)/,ca+"box-pack:$3"+Ld+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+ca+t+t;case 4095:case 3583:case 4068:case 2532:return da(t,/(.+)-inline(.+)/,ca+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(jy(t)-1-e>6)switch(rd(t,e+1)){case 109:if(rd(t,e+4)!==45)break;case 102:return da(t,/(.+:)(.+)-([^]+)/,"$1"+ca+"$2-$3$1"+sz+(rd(t,e+3)==108?"$3":"$2-$3"))+t;case 115:return~oZ(t,"stretch")?ZMe(da(t,"stretch","fill-available"),e)+t:t}break;case 4949:if(rd(t,e+1)!==115)break;case 6444:switch(rd(t,jy(t)-3-(~oZ(t,"!important")&&10))){case 107:return da(t,":",":"+ca)+t;case 101:return da(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+ca+(rd(t,14)===45?"inline-":"")+"box$3$1"+ca+"$2$3$1"+Ld+"$2box$3")+t}break;case 5936:switch(rd(t,e+11)){case 114:return ca+t+Ld+da(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return ca+t+Ld+da(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return ca+t+Ld+da(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return ca+t+Ld+t+t}return t}var rlt=function(e,i,n,r){if(e.length>-1&&!e.return)switch(e.type){case Fee:e.return=ZMe(e.value,e.length);break;case WMe:return WL([Z2(e,{value:da(e.value,"@","@"+ca)})],r);case Nee:if(e.length)return jst(e.props,function(o){switch(Bst(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return WL([Z2(e,{props:[da(o,/:(read-\w+)/,":"+sz+"$1")]})],r);case"::placeholder":return WL([Z2(e,{props:[da(o,/:(plac\w+)/,":"+ca+"input-$1")]}),Z2(e,{props:[da(o,/:(plac\w+)/,":"+sz+"$1")]}),Z2(e,{props:[da(o,/:(plac\w+)/,Ld+"input-$1")]})],r)}return""})}},ilt=[rlt],JMe=function(e){var i=e.key;if(i==="css"){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,function(g){var v=g.getAttribute("data-emotion");v.indexOf(" ")!==-1&&(document.head.appendChild(g),g.setAttribute("data-s",""))})}var r=e.stylisPlugins||ilt,o={},a,s=[];a=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+i+' "]'),function(g){for(var v=g.getAttribute("data-emotion").split(" "),y=1;y<v.length;y++)o[v[y]]=!0;s.push(g)});var l,u=[elt,tlt];{var c,d=[qst,Kst(function(g){c.insert(g)})],f=Xst(u.concat(r,d)),h=function(v){return WL(Gst(v),f)};l=function(v,y,m,b){c=m,h(v?v+"{"+y.styles+"}":y.styles),b&&(p.inserted[y.name]=!0)}}var p={key:i,sheet:new Mst({key:i,container:a,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:o,registered:{},insert:l};return p.sheet.hydrate(s),p},W8={exports:{}},ba={};/** @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 Cle;function nlt(){if(Cle)return ba;Cle=1;var t=typeof Symbol=="function"&&Symbol.for,e=t?Symbol.for("react.element"):60103,i=t?Symbol.for("react.portal"):60106,n=t?Symbol.for("react.fragment"):60107,r=t?Symbol.for("react.strict_mode"):60108,o=t?Symbol.for("react.profiler"):60114,a=t?Symbol.for("react.provider"):60109,s=t?Symbol.for("react.context"):60110,l=t?Symbol.for("react.async_mode"):60111,u=t?Symbol.for("react.concurrent_mode"):60111,c=t?Symbol.for("react.forward_ref"):60112,d=t?Symbol.for("react.suspense"):60113,f=t?Symbol.for("react.suspense_list"):60120,h=t?Symbol.for("react.memo"):60115,p=t?Symbol.for("react.lazy"):60116,g=t?Symbol.for("react.block"):60121,v=t?Symbol.for("react.fundamental"):60117,y=t?Symbol.for("react.responder"):60118,m=t?Symbol.for("react.scope"):60119;function b(_){if(typeof _=="object"&&_!==null){var C=_.$$typeof;switch(C){case e:switch(_=_.type,_){case l:case u:case n:case o:case r:case d:return _;default:switch(_=_&&_.$$typeof,_){case s:case c:case p:case h:case a:return _;default:return C}}case i:return C}}}function S(_){return b(_)===u}return ba.AsyncMode=l,ba.ConcurrentMode=u,ba.ContextConsumer=s,ba.ContextProvider=a,ba.Element=e,ba.ForwardRef=c,ba.Fragment=n,ba.Lazy=p,ba.Memo=h,ba.Portal=i,ba.Profiler=o,ba.StrictMode=r,ba.Suspense=d,ba.isAsyncMode=function(_){return S(_)||b(_)===l},ba.isConcurrentMode=S,ba.isContextConsumer=function(_){return b(_)===s},ba.isContextProvider=function(_){return b(_)===a},ba.isElement=function(_){return typeof _=="object"&&_!==null&&_.$$typeof===e},ba.isForwardRef=function(_){return b(_)===c},ba.isFragment=function(_){return b(_)===n},ba.isLazy=function(_){return b(_)===p},ba.isMemo=function(_){return b(_)===h},ba.isPortal=function(_){return b(_)===i},ba.isProfiler=function(_){return b(_)===o},ba.isStrictMode=function(_){return b(_)===r},ba.isSuspense=function(_){return b(_)===d},ba.isValidElementType=function(_){return typeof _=="string"||typeof _=="function"||_===n||_===u||_===o||_===r||_===d||_===f||typeof _=="object"&&_!==null&&(_.$$typeof===p||_.$$typeof===h||_.$$typeof===a||_.$$typeof===s||_.$$typeof===c||_.$$typeof===v||_.$$typeof===y||_.$$typeof===m||_.$$typeof===g)},ba.typeOf=b,ba}var Tle;function olt(){return Tle||(Tle=1,W8.exports=nlt()),W8.exports}var G8,xle;function alt(){if(xle)return G8;xle=1;var t=olt(),e={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},n={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},r={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},o={};o[t.ForwardRef]=n,o[t.Memo]=r;function a(p){return t.isMemo(p)?r:o[p.$$typeof]||e}var s=Object.defineProperty,l=Object.getOwnPropertyNames,u=Object.getOwnPropertySymbols,c=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,f=Object.prototype;function h(p,g,v){if(typeof g!="string"){if(f){var y=d(g);y&&y!==f&&h(p,y,v)}var m=l(g);u&&(m=m.concat(u(g)));for(var b=a(p),S=a(g),_=0;_<m.length;++_){var C=m[_];if(!i[C]&&!(v&&v[C])&&!(S&&S[C])&&!(b&&b[C])){var P=c(g,C);try{s(p,C,P)}catch{}}}}return p}return G8=h,G8}alt();var slt=!0;function QMe(t,e,i){var n="";return i.split(" ").forEach(function(r){t[r]!==void 0?e.push(t[r]+";"):r&&(n+=r+" ")}),n}var jee=function(e,i,n){var r=e.key+"-"+i.name;(n===!1||slt===!1)&&e.registered[r]===void 0&&(e.registered[r]=i.styles)},Vee=function(e,i,n){jee(e,i,n);var r=e.key+"-"+i.name;if(e.inserted[i.name]===void 0){var o=i;do e.insert(i===o?"."+r:"",o,e.sheet,!0),o=o.next;while(o!==void 0)}};function llt(t){for(var e=0,i,n=0,r=t.length;r>=4;++n,r-=4)i=t.charCodeAt(n)&255|(t.charCodeAt(++n)&255)<<8|(t.charCodeAt(++n)&255)<<16|(t.charCodeAt(++n)&255)<<24,i=(i&65535)*1540483477+((i>>>16)*59797<<16),i^=i>>>24,e=(i&65535)*1540483477+((i>>>16)*59797<<16)^(e&65535)*1540483477+((e>>>16)*59797<<16);switch(r){case 3:e^=(t.charCodeAt(n+2)&255)<<16;case 2:e^=(t.charCodeAt(n+1)&255)<<8;case 1:e^=t.charCodeAt(n)&255,e=(e&65535)*1540483477+((e>>>16)*59797<<16)}return e^=e>>>13,e=(e&65535)*1540483477+((e>>>16)*59797<<16),((e^e>>>15)>>>0).toString(36)}var ult={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},clt=/[A-Z]|^ms/g,dlt=/_EMO_([^_]+?)_([^]*?)_EMO_/g,eLe=function(e){return e.charCodeAt(1)===45},Ele=function(e){return e!=null&&typeof e!="boolean"},Y8=KMe(function(t){return eLe(t)?t:t.replace(clt,"-$&").toLowerCase()}),wle=function(e,i){switch(e){case"animation":case"animationName":if(typeof i=="string")return i.replace(dlt,function(n,r,o){return Vy={name:r,styles:o,next:Vy},r})}return ult[e]!==1&&!eLe(e)&&typeof i=="number"&&i!==0?i+"px":i};function _3(t,e,i){if(i==null)return"";var n=i;if(n.__emotion_styles!==void 0)return n;switch(typeof i){case"boolean":return"";case"object":{var r=i;if(r.anim===1)return Vy={name:r.name,styles:r.styles,next:Vy},r.name;var o=i;if(o.styles!==void 0){var a=o.next;if(a!==void 0)for(;a!==void 0;)Vy={name:a.name,styles:a.styles,next:Vy},a=a.next;var s=o.styles+";";return s}return flt(t,e,i)}case"function":{if(t!==void 0){var l=Vy,u=i(t);return Vy=l,_3(t,e,u)}break}}var c=i;if(e==null)return c;var d=e[c];return d!==void 0?d:c}function flt(t,e,i){var n="";if(Array.isArray(i))for(var r=0;r<i.length;r++)n+=_3(t,e,i[r])+";";else for(var o in i){var a=i[o];if(typeof a!="object"){var s=a;e!=null&&e[s]!==void 0?n+=o+"{"+e[s]+"}":Ele(s)&&(n+=Y8(o)+":"+wle(o,s)+";")}else if(Array.isArray(a)&&typeof a[0]=="string"&&(e==null||e[a[0]]===void 0))for(var l=0;l<a.length;l++)Ele(a[l])&&(n+=Y8(o)+":"+wle(o,a[l])+";");else{var u=_3(t,e,a);switch(o){case"animation":case"animationName":{n+=Y8(o)+":"+u+";";break}default:n+=o+"{"+u+"}"}}}return n}var Ale=/label:\s*([^\s;{]+)\s*(;|$)/g,Vy;function OV(t,e,i){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var n=!0,r="";Vy=void 0;var o=t[0];if(o==null||o.raw===void 0)n=!1,r+=_3(i,e,o);else{var a=o;r+=a[0]}for(var s=1;s<t.length;s++)if(r+=_3(i,e,t[s]),n){var l=o;r+=l[s]}Ale.lastIndex=0;for(var u="",c;(c=Ale.exec(r))!==null;)u+="-"+c[1];var d=llt(r)+u;return{name:d,styles:r,next:Vy}}var hlt=function(e){return e()},tLe=s5.useInsertionEffect?s5.useInsertionEffect:!1,rLe=tLe||hlt,Ole=tLe||J.useLayoutEffect,iLe=J.createContext(typeof HTMLElement<"u"?JMe({key:"css"}):null),plt=iLe.Provider,Hee=function(e){return J.forwardRef(function(i,n){var r=J.useContext(iLe);return e(i,r,n)})},b6=J.createContext({}),Uee={}.hasOwnProperty,sZ="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",glt=function(e,i){var n={};for(var r in i)Uee.call(i,r)&&(n[r]=i[r]);return n[sZ]=e,n},vlt=function(e){var i=e.cache,n=e.serialized,r=e.isStringTag;return jee(i,n,r),rLe(function(){return Vee(i,n,r)}),null},ylt=Hee(function(t,e,i){var n=t.css;typeof n=="string"&&e.registered[n]!==void 0&&(n=e.registered[n]);var r=t[sZ],o=[n],a="";typeof t.className=="string"?a=QMe(e.registered,o,t.className):t.className!=null&&(a=t.className+" ");var s=OV(o,void 0,J.useContext(b6));a+=e.key+"-"+s.name;var l={};for(var u in t)Uee.call(t,u)&&u!=="css"&&u!==sZ&&(l[u]=t[u]);return l.className=a,i&&(l.ref=i),J.createElement(J.Fragment,null,J.createElement(vlt,{cache:e,serialized:s,isStringTag:typeof r=="string"}),J.createElement(r,l))}),mlt=ylt,Dle=function(e,i){var n=arguments;if(i==null||!Uee.call(i,"css"))return J.createElement.apply(void 0,n);var r=n.length,o=new Array(r);o[0]=mlt,o[1]=glt(e,i);for(var a=2;a<r;a++)o[a]=n[a];return J.createElement.apply(null,o)};(function(t){var e;e||(e=t.JSX||(t.JSX={}))})(Dle||(Dle={}));var blt=Hee(function(t,e){var i=t.styles,n=OV([i],void 0,J.useContext(b6)),r=J.useRef();return Ole(function(){var o=e.key+"-global",a=new e.sheet.constructor({key:o,nonce:e.sheet.nonce,container:e.sheet.container,speedy:e.sheet.isSpeedy}),s=!1,l=document.querySelector('style[data-emotion="'+o+" "+n.name+'"]');return e.sheet.tags.length&&(a.before=e.sheet.tags[0]),l!==null&&(s=!0,l.setAttribute("data-emotion",o),a.hydrate([l])),r.current=[a,s],function(){a.flush()}},[e]),Ole(function(){var o=r.current,a=o[0],s=o[1];if(s){o[1]=!1;return}if(n.next!==void 0&&Vee(e,n.next,!0),a.tags.length){var l=a.tags[a.tags.length-1].nextElementSibling;a.before=l,a.flush()}e.insert("",n,a,!1)},[e,n.name]),null});function nLe(){for(var t=arguments.length,e=new Array(t),i=0;i<t;i++)e[i]=arguments[i];return OV(e)}function Slt(){var t=nLe.apply(void 0,arguments),e="animation-"+t.name;return{name:e,styles:"@keyframes "+e+"{"+t.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}var _lt=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Plt=KMe(function(t){return _lt.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91}),Clt=Plt,Tlt=function(e){return e!=="theme"},Rle=function(e){return typeof e=="string"&&e.charCodeAt(0)>96?Clt:Tlt},Mle=function(e,i,n){var r;if(i){var o=i.shouldForwardProp;r=e.__emotion_forwardProp&&o?function(a){return e.__emotion_forwardProp(a)&&o(a)}:o}return typeof r!="function"&&n&&(r=e.__emotion_forwardProp),r},xlt=function(e){var i=e.cache,n=e.serialized,r=e.isStringTag;return jee(i,n,r),rLe(function(){return Vee(i,n,r)}),null},Elt=function t(e,i){var n=e.__emotion_real===e,r=n&&e.__emotion_base||e,o,a;i!==void 0&&(o=i.label,a=i.target);var s=Mle(e,i,n),l=s||Rle(r),u=!l("as");return function(){var c=arguments,d=n&&e.__emotion_styles!==void 0?e.__emotion_styles.slice(0):[];if(o!==void 0&&d.push("label:"+o+";"),c[0]==null||c[0].raw===void 0)d.push.apply(d,c);else{var f=c[0];d.push(f[0]);for(var h=c.length,p=1;p<h;p++)d.push(c[p],f[p])}var g=Hee(function(v,y,m){var b=u&&v.as||r,S="",_=[],C=v;if(v.theme==null){C={};for(var P in v)C[P]=v[P];C.theme=J.useContext(b6)}typeof v.className=="string"?S=QMe(y.registered,_,v.className):v.className!=null&&(S=v.className+" ");var x=OV(d.concat(_),y.registered,C);S+=y.key+"-"+x.name,a!==void 0&&(S+=" "+a);var E=u&&s===void 0?Rle(b):l,A={};for(var R in v)u&&R==="as"||E(R)&&(A[R]=v[R]);return A.className=S,m&&(A.ref=m),J.createElement(J.Fragment,null,J.createElement(xlt,{cache:y,serialized:x,isStringTag:typeof b=="string"}),J.createElement(b,A))});return g.displayName=o!==void 0?o:"Styled("+(typeof r=="string"?r:r.displayName||r.name||"Component")+")",g.defaultProps=e.defaultProps,g.__emotion_real=g,g.__emotion_base=r,g.__emotion_styles=d,g.__emotion_forwardProp=s,Object.defineProperty(g,"toString",{value:function(){return"."+a}}),g.withComponent=function(v,y){var m=t(v,Gn({},i,y,{shouldForwardProp:Mle(g,y,!0)}));return m.apply(void 0,d)},g}},wlt=["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],lZ=Elt.bind(null);wlt.forEach(function(t){lZ[t]=lZ(t)});function Alt(t,e){const i=JMe({key:"css",prepend:t});if(e){const n=i.insert;i.insert=(...r)=>(r[1].styles.match(/^@layer\s+[^{]*$/)||(r[1].styles=`@layer mui {${r[1].styles}}`),n(...r))}return i}const q8=new Map;function Olt(t){const{injectFirst:e,enableCssLayer:i,children:n}=t,r=J.useMemo(()=>{const o=`${e}-${i}`;if(typeof document=="object"&&q8.has(o))return q8.get(o);const a=Alt(e,i);return q8.set(o,a),a},[e,i]);return e||i?L.jsx(plt,{value:r,children:n}):n}function Dlt(t){return t==null||Object.keys(t).length===0}function Rlt(t){const{styles:e,defaultTheme:i={}}=t,n=typeof e=="function"?r=>e(Dlt(r)?i:r):e;return L.jsx(blt,{styles:n})}function Mlt(t,e){return lZ(t,e)}const Llt=(t,e)=>{Array.isArray(t.__emotion_styles)&&(t.__emotion_styles=e(t.__emotion_styles))},Lle=[];function klt(t){return Lle[0]=t,OV(Lle)}const Ilt=Object.freeze(Object.defineProperty({__proto__:null,GlobalStyles:Rlt,StyledEngineProvider:Olt,ThemeContext:b6,css:nLe,default:Mlt,internal_processStyles:Llt,internal_serializeStyles:klt,keyframes:Slt},Symbol.toStringTag,{value:"Module"})),Nlt=RS(Ilt),Flt=RS(cst),Blt=RS(yst),jlt=RS(vst),Vlt=["values","unit","step"],Hlt=t=>{const e=Object.keys(t).map(i=>({key:i,val:t[i]}))||[];return e.sort((i,n)=>i.val-n.val),e.reduce((i,n)=>Gn({},i,{[n.key]:n.val}),{})};function oLe(t){const{values:e={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:i="px",step:n=5}=t,r=FS(t,Vlt),o=Hlt(e),a=Object.keys(o);function s(f){return`@media (min-width:${typeof e[f]=="number"?e[f]:f}${i})`}function l(f){return`@media (max-width:${(typeof e[f]=="number"?e[f]:f)-n/100}${i})`}function u(f,h){const p=a.indexOf(h);return`@media (min-width:${typeof e[f]=="number"?e[f]:f}${i}) and (max-width:${(p!==-1&&typeof e[a[p]]=="number"?e[a[p]]:h)-n/100}${i})`}function c(f){return a.indexOf(f)+1<a.length?u(f,a[a.indexOf(f)+1]):s(f)}function d(f){const h=a.indexOf(f);return h===0?s(a[1]):h===a.length-1?l(a[h]):u(f,a[a.indexOf(f)+1]).replace("@media","@media not all and")}return Gn({keys:a,values:o,up:s,down:l,between:u,only:c,not:d,unit:i},r)}const Ult={borderRadius:4};function xj(t,e){return e?nm(t,e,{clone:!1}):t}const zee={xs:0,sm:600,md:900,lg:1200,xl:1536},kle={keys:["xs","sm","md","lg","xl"],up:t=>`@media (min-width:${zee[t]}px)`};function wS(t,e,i){const n=t.theme||{};if(Array.isArray(e)){const o=n.breakpoints||kle;return e.reduce((a,s,l)=>(a[o.up(o.keys[l])]=i(e[l]),a),{})}if(typeof e=="object"){const o=n.breakpoints||kle;return Object.keys(e).reduce((a,s)=>{if(Object.keys(o.values||zee).indexOf(s)!==-1){const l=o.up(s);a[l]=i(e[s],s)}else{const l=s;a[l]=e[l]}return a},{})}return i(e)}function zlt(t={}){var e;return((e=t.keys)==null?void 0:e.reduce((n,r)=>{const o=t.up(r);return n[o]={},n},{}))||{}}function Ile(t,e){return t.reduce((i,n)=>{const r=i[n];return(!r||Object.keys(r).length===0)&&delete i[n],i},e)}function S6(t,e,i=!0){if(!e||typeof e!="string")return null;if(t&&t.vars&&i){const n=`vars.${e}`.split(".").reduce((r,o)=>r&&r[o]?r[o]:null,t);if(n!=null)return n}return e.split(".").reduce((n,r)=>n&&n[r]!=null?n[r]:null,t)}function lz(t,e,i,n=i){let r;return typeof t=="function"?r=t(i):Array.isArray(t)?r=t[i]||n:r=S6(t,i)||n,e&&(r=e(r,n,t)),r}function uu(t){const{prop:e,cssProperty:i=t.prop,themeKey:n,transform:r}=t,o=a=>{if(a[e]==null)return null;const s=a[e],l=a.theme,u=S6(l,n)||{};return wS(a,s,d=>{let f=lz(u,r,d);return d===f&&typeof d=="string"&&(f=lz(u,r,`${e}${d==="default"?"":OD(d)}`,d)),i===!1?f:{[i]:f}})};return o.propTypes={},o.filterProps=[e],o}function $lt(t){const e={};return i=>(e[i]===void 0&&(e[i]=t(i)),e[i])}const Wlt={m:"margin",p:"padding"},Glt={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Nle={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Ylt=$lt(t=>{if(t.length>2)if(Nle[t])t=Nle[t];else return[t];const[e,i]=t.split(""),n=Wlt[e],r=Glt[i]||"";return Array.isArray(r)?r.map(o=>n+o):[n+r]}),$ee=["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"],Wee=["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"];[...$ee,...Wee];function DV(t,e,i,n){var r;const o=(r=S6(t,e,!1))!=null?r:i;return typeof o=="number"?a=>typeof a=="string"?a:o*a:Array.isArray(o)?a=>typeof a=="string"?a:o[a]:typeof o=="function"?o:()=>{}}function aLe(t){return DV(t,"spacing",8)}function RV(t,e){if(typeof e=="string"||e==null)return e;const i=Math.abs(e),n=t(i);return e>=0?n:typeof n=="number"?-n:`-${n}`}function qlt(t,e){return i=>t.reduce((n,r)=>(n[r]=RV(e,i),n),{})}function Xlt(t,e,i,n){if(e.indexOf(i)===-1)return null;const r=Ylt(i),o=qlt(r,n),a=t[i];return wS(t,a,o)}function sLe(t,e){const i=aLe(t.theme);return Object.keys(t).map(n=>Xlt(t,e,n,i)).reduce(xj,{})}function Ll(t){return sLe(t,$ee)}Ll.propTypes={};Ll.filterProps=$ee;function kl(t){return sLe(t,Wee)}kl.propTypes={};kl.filterProps=Wee;function Klt(t=8){if(t.mui)return t;const e=aLe({spacing:t}),i=(...n)=>(n.length===0?[1]:n).map(o=>{const a=e(o);return typeof a=="number"?`${a}px`:a}).join(" ");return i.mui=!0,i}function _6(...t){const e=t.reduce((n,r)=>(r.filterProps.forEach(o=>{n[o]=r}),n),{}),i=n=>Object.keys(n).reduce((r,o)=>e[o]?xj(r,e[o](n)):r,{});return i.propTypes={},i.filterProps=t.reduce((n,r)=>n.concat(r.filterProps),[]),i}function _g(t){return typeof t!="number"?t:`${t}px solid`}function kg(t,e){return uu({prop:t,themeKey:"borders",transform:e})}const Zlt=kg("border",_g),Jlt=kg("borderTop",_g),Qlt=kg("borderRight",_g),eut=kg("borderBottom",_g),tut=kg("borderLeft",_g),rut=kg("borderColor"),iut=kg("borderTopColor"),nut=kg("borderRightColor"),out=kg("borderBottomColor"),aut=kg("borderLeftColor"),sut=kg("outline",_g),lut=kg("outlineColor"),P6=t=>{if(t.borderRadius!==void 0&&t.borderRadius!==null){const e=DV(t.theme,"shape.borderRadius",4),i=n=>({borderRadius:RV(e,n)});return wS(t,t.borderRadius,i)}return null};P6.propTypes={};P6.filterProps=["borderRadius"];_6(Zlt,Jlt,Qlt,eut,tut,rut,iut,nut,out,aut,P6,sut,lut);const C6=t=>{if(t.gap!==void 0&&t.gap!==null){const e=DV(t.theme,"spacing",8),i=n=>({gap:RV(e,n)});return wS(t,t.gap,i)}return null};C6.propTypes={};C6.filterProps=["gap"];const T6=t=>{if(t.columnGap!==void 0&&t.columnGap!==null){const e=DV(t.theme,"spacing",8),i=n=>({columnGap:RV(e,n)});return wS(t,t.columnGap,i)}return null};T6.propTypes={};T6.filterProps=["columnGap"];const x6=t=>{if(t.rowGap!==void 0&&t.rowGap!==null){const e=DV(t.theme,"spacing",8),i=n=>({rowGap:RV(e,n)});return wS(t,t.rowGap,i)}return null};x6.propTypes={};x6.filterProps=["rowGap"];const uut=uu({prop:"gridColumn"}),cut=uu({prop:"gridRow"}),dut=uu({prop:"gridAutoFlow"}),fut=uu({prop:"gridAutoColumns"}),hut=uu({prop:"gridAutoRows"}),put=uu({prop:"gridTemplateColumns"}),gut=uu({prop:"gridTemplateRows"}),vut=uu({prop:"gridTemplateAreas"}),yut=uu({prop:"gridArea"});_6(C6,T6,x6,uut,cut,dut,fut,hut,put,gut,vut,yut);function GL(t,e){return e==="grey"?e:t}const mut=uu({prop:"color",themeKey:"palette",transform:GL}),but=uu({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:GL}),Sut=uu({prop:"backgroundColor",themeKey:"palette",transform:GL});_6(mut,but,Sut);function Cp(t){return t<=1&&t!==0?`${t*100}%`:t}const _ut=uu({prop:"width",transform:Cp}),Gee=t=>{if(t.maxWidth!==void 0&&t.maxWidth!==null){const e=i=>{var n,r;const o=((n=t.theme)==null||(n=n.breakpoints)==null||(n=n.values)==null?void 0:n[i])||zee[i];return o?((r=t.theme)==null||(r=r.breakpoints)==null?void 0:r.unit)!=="px"?{maxWidth:`${o}${t.theme.breakpoints.unit}`}:{maxWidth:o}:{maxWidth:Cp(i)}};return wS(t,t.maxWidth,e)}return null};Gee.filterProps=["maxWidth"];const Put=uu({prop:"minWidth",transform:Cp}),Cut=uu({prop:"height",transform:Cp}),Tut=uu({prop:"maxHeight",transform:Cp}),xut=uu({prop:"minHeight",transform:Cp});uu({prop:"size",cssProperty:"width",transform:Cp});uu({prop:"size",cssProperty:"height",transform:Cp});const Eut=uu({prop:"boxSizing"});_6(_ut,Gee,Put,Cut,Tut,xut,Eut);const MV={border:{themeKey:"borders",transform:_g},borderTop:{themeKey:"borders",transform:_g},borderRight:{themeKey:"borders",transform:_g},borderBottom:{themeKey:"borders",transform:_g},borderLeft:{themeKey:"borders",transform:_g},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:_g},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:P6},color:{themeKey:"palette",transform:GL},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:GL},backgroundColor:{themeKey:"palette",transform:GL},p:{style:kl},pt:{style:kl},pr:{style:kl},pb:{style:kl},pl:{style:kl},px:{style:kl},py:{style:kl},padding:{style:kl},paddingTop:{style:kl},paddingRight:{style:kl},paddingBottom:{style:kl},paddingLeft:{style:kl},paddingX:{style:kl},paddingY:{style:kl},paddingInline:{style:kl},paddingInlineStart:{style:kl},paddingInlineEnd:{style:kl},paddingBlock:{style:kl},paddingBlockStart:{style:kl},paddingBlockEnd:{style:kl},m:{style:Ll},mt:{style:Ll},mr:{style:Ll},mb:{style:Ll},ml:{style:Ll},mx:{style:Ll},my:{style:Ll},margin:{style:Ll},marginTop:{style:Ll},marginRight:{style:Ll},marginBottom:{style:Ll},marginLeft:{style:Ll},marginX:{style:Ll},marginY:{style:Ll},marginInline:{style:Ll},marginInlineStart:{style:Ll},marginInlineEnd:{style:Ll},marginBlock:{style:Ll},marginBlockStart:{style:Ll},marginBlockEnd:{style:Ll},displayPrint:{cssProperty:!1,transform:t=>({"@media print":{display:t}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:C6},rowGap:{style:x6},columnGap:{style:T6},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Cp},maxWidth:{style:Gee},minWidth:{transform:Cp},height:{transform:Cp},maxHeight:{transform:Cp},minHeight:{transform:Cp},boxSizing:{},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}};function wut(...t){const e=t.reduce((n,r)=>n.concat(Object.keys(r)),[]),i=new Set(e);return t.every(n=>i.size===Object.keys(n).length)}function Aut(t,e){return typeof t=="function"?t(e):t}function lLe(){function t(i,n,r,o){const a={[i]:n,theme:r},s=o[i];if(!s)return{[i]:n};const{cssProperty:l=i,themeKey:u,transform:c,style:d}=s;if(n==null)return null;if(u==="typography"&&n==="inherit")return{[i]:n};const f=S6(r,u)||{};return d?d(a):wS(a,n,p=>{let g=lz(f,c,p);return p===g&&typeof p=="string"&&(g=lz(f,c,`${i}${p==="default"?"":OD(p)}`,p)),l===!1?g:{[l]:g}})}function e(i){var n;const{sx:r,theme:o={},nested:a}=i||{};if(!r)return null;const s=(n=o.unstable_sxConfig)!=null?n:MV;function l(u){let c=u;if(typeof u=="function")c=u(o);else if(typeof u!="object")return u;if(!c)return null;const d=zlt(o.breakpoints),f=Object.keys(d);let h=d;return Object.keys(c).forEach(p=>{const g=Aut(c[p],o);if(g!=null)if(typeof g=="object")if(s[p])h=xj(h,t(p,g,o,s));else{const v=wS({theme:o},g,y=>({[p]:y}));wut(v,g)?h[p]=e({sx:g,theme:o,nested:!0}):h=xj(h,v)}else h=xj(h,t(p,g,o,s))}),!a&&o.modularCssLayers?{"@layer sx":Ile(f,h)}:Ile(f,h)}return Array.isArray(r)?r.map(l):l(r)}return e}const E6=lLe();E6.filterProps=["sx"];function uLe(t,e){const i=this;return i.vars&&typeof i.getColorSchemeSelector=="function"?{[i.getColorSchemeSelector(t).replace(/(\[[^\]]+\])/,"*:where($1)")]:e}:i.palette.mode===t?e:{}}const Out=["breakpoints","palette","spacing","shape"];function cLe(t={},...e){const{breakpoints:i={},palette:n={},spacing:r,shape:o={}}=t,a=FS(t,Out),s=oLe(i),l=Klt(r);let u=nm({breakpoints:s,direction:"ltr",components:{},palette:Gn({mode:"light"},n),spacing:l,shape:Gn({},Ult,o)},a);return u.applyStyles=uLe,u=e.reduce((c,d)=>nm(c,d),u),u.unstable_sxConfig=Gn({},MV,a==null?void 0:a.unstable_sxConfig),u.unstable_sx=function(d){return E6({sx:d,theme:this})},u}const Dut=Object.freeze(Object.defineProperty({__proto__:null,default:cLe,private_createBreakpoints:oLe,unstable_applyStyles:uLe},Symbol.toStringTag,{value:"Module"})),Rut=RS(Dut),Mut=["sx"],Lut=t=>{var e,i;const n={systemProps:{},otherProps:{}},r=(e=t==null||(i=t.theme)==null?void 0:i.unstable_sxConfig)!=null?e:MV;return Object.keys(t).forEach(o=>{r[o]?n.systemProps[o]=t[o]:n.otherProps[o]=t[o]}),n};function kut(t){const{sx:e}=t,i=FS(t,Mut),{systemProps:n,otherProps:r}=Lut(i);let o;return Array.isArray(e)?o=[n,...e]:typeof e=="function"?o=(...a)=>{const s=e(...a);return q_(s)?Gn({},n,s):n}:o=Gn({},n,e),Gn({},r,{sx:o})}const Iut=Object.freeze(Object.defineProperty({__proto__:null,default:E6,extendSxProp:kut,unstable_createStyleFunctionSx:lLe,unstable_defaultSxConfig:MV},Symbol.toStringTag,{value:"Module"})),Nut=RS(Iut);var Fle;function Fut(){if(Fle)return yT;Fle=1;var t=UMe();Object.defineProperty(yT,"__esModule",{value:!0}),yT.default=_,yT.shouldForwardProp=p,yT.systemDefaultTheme=void 0;var e=t(zMe()),i=t(Ost()),n=d(Nlt),r=Flt;t(Blt),t(jlt);var o=t(Rut),a=t(Nut);const s=["ownerState"],l=["variants"],u=["name","slot","skipVariantsResolver","skipSx","overridesResolver"];function c(C){if(typeof WeakMap!="function")return null;var P=new WeakMap,x=new WeakMap;return(c=function(E){return E?x:P})(C)}function d(C,P){if(C&&C.__esModule)return C;if(C===null||typeof C!="object"&&typeof C!="function")return{default:C};var x=c(P);if(x&&x.has(C))return x.get(C);var E={__proto__:null},A=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var R in C)if(R!=="default"&&Object.prototype.hasOwnProperty.call(C,R)){var M=A?Object.getOwnPropertyDescriptor(C,R):null;M&&(M.get||M.set)?Object.defineProperty(E,R,M):E[R]=C[R]}return E.default=C,x&&x.set(C,E),E}function f(C){return Object.keys(C).length===0}function h(C){return typeof C=="string"&&C.charCodeAt(0)>96}function p(C){return C!=="ownerState"&&C!=="theme"&&C!=="sx"&&C!=="as"}function g(C,P){return P&&C&&typeof C=="object"&&C.styles&&!C.styles.startsWith("@layer")&&(C.styles=`@layer ${P}{${String(C.styles)}}`),C}const v=yT.systemDefaultTheme=(0,o.default)(),y=C=>C&&C.charAt(0).toLowerCase()+C.slice(1);function m({defaultTheme:C,theme:P,themeId:x}){return f(P)?C:P[x]||P}function b(C){return C?(P,x)=>x[C]:null}function S(C,P,x){let{ownerState:E}=P,A=(0,i.default)(P,s);const R=typeof C=="function"?C((0,e.default)({ownerState:E},A)):C;if(Array.isArray(R))return R.flatMap(M=>S(M,(0,e.default)({ownerState:E},A),x));if(R&&typeof R=="object"&&Array.isArray(R.variants)){const{variants:M=[]}=R;let F=(0,i.default)(R,l);return M.forEach(I=>{let V=!0;if(typeof I.props=="function"?V=I.props((0,e.default)({ownerState:E},A,E)):Object.keys(I.props).forEach(z=>{(E==null?void 0:E[z])!==I.props[z]&&A[z]!==I.props[z]&&(V=!1)}),V){Array.isArray(F)||(F=[F]);const z=typeof I.style=="function"?I.style((0,e.default)({ownerState:E},A,E)):I.style;F.push(x?g((0,n.internal_serializeStyles)(z),x):z)}}),F}return x?g((0,n.internal_serializeStyles)(R),x):R}function _(C={}){const{themeId:P,defaultTheme:x=v,rootShouldForwardProp:E=p,slotShouldForwardProp:A=p}=C,R=M=>(0,a.default)((0,e.default)({},M,{theme:m((0,e.default)({},M,{defaultTheme:x,themeId:P}))}));return R.__mui_systemSx=!0,(M,D={})=>{(0,n.internal_processStyles)(M,ge=>ge.filter(Ee=>!(Ee!=null&&Ee.__mui_systemSx)));const{name:F,slot:I,skipVariantsResolver:V,skipSx:z,overridesResolver:G=b(y(I))}=D,H=(0,i.default)(D,u),U=F&&F.startsWith("Mui")||I?"components":"custom",k=V!==void 0?V:I&&I!=="Root"&&I!=="root"||!1,X=z||!1;let W,Y=p;I==="Root"||I==="root"?Y=E:I?Y=A:h(M)&&(Y=void 0);const te=(0,n.default)(M,(0,e.default)({shouldForwardProp:Y,label:W},H)),oe=ge=>typeof ge=="function"&&ge.__emotion_real!==ge||(0,r.isPlainObject)(ge)?Ee=>{const Re=m({theme:Ee.theme,defaultTheme:x,themeId:P});return S(ge,(0,e.default)({},Ee,{theme:Re}),Re.modularCssLayers?U:void 0)}:ge,de=(ge,...Ee)=>{let Re=oe(ge);const Ae=Ee?Ee.map(oe):[];F&&G&&Ae.push(Te=>{const ke=m((0,e.default)({},Te,{defaultTheme:x,themeId:P}));if(!ke.components||!ke.components[F]||!ke.components[F].styleOverrides)return null;const $e=ke.components[F].styleOverrides,Ne={};return Object.entries($e).forEach(([ve,pe])=>{Ne[ve]=S(pe,(0,e.default)({},Te,{theme:ke}),ke.modularCssLayers?"theme":void 0)}),G(Te,Ne)}),F&&!k&&Ae.push(Te=>{var ke;const $e=m((0,e.default)({},Te,{defaultTheme:x,themeId:P})),Ne=$e==null||(ke=$e.components)==null||(ke=ke[F])==null?void 0:ke.variants;return S({variants:Ne},(0,e.default)({},Te,{theme:$e}),$e.modularCssLayers?"theme":void 0)}),X||Ae.push(R);const Pe=Ae.length-Ee.length;if(Array.isArray(ge)&&Pe>0){const Te=new Array(Pe).fill("");Re=[...ge,...Te],Re.raw=[...ge.raw,...Te]}const we=te(Re,...Ae);return M.muiName&&(we.muiName=M.muiName),we};return te.withConfig&&(de.withConfig=te.withConfig),de}}return yT}var But=Fut();const jut=wc(But);function Vut(t,e){return Gn({toolbar:{minHeight:56,[t.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[t.up("sm")]:{minHeight:64}}},e)}var cl={};const Hut=RS(dst),Uut=RS(Tst);var Ble;function zut(){if(Ble)return cl;Ble=1;var t=UMe();Object.defineProperty(cl,"__esModule",{value:!0}),cl.alpha=p,cl.blend=C,cl.colorChannel=void 0,cl.darken=v,cl.decomposeColor=a,cl.emphasize=S,cl.getContrastRatio=h,cl.getLuminance=f,cl.hexToRgb=r,cl.hslToRgb=d,cl.lighten=m,cl.private_safeAlpha=g,cl.private_safeColorChannel=void 0,cl.private_safeDarken=y,cl.private_safeEmphasize=_,cl.private_safeLighten=b,cl.recomposeColor=u,cl.rgbToHex=c;var e=t(Hut),i=t(Uut);function n(P,x=0,E=1){return(0,i.default)(P,x,E)}function r(P){P=P.slice(1);const x=new RegExp(`.{1,${P.length>=6?2:1}}`,"g");let E=P.match(x);return E&&E[0].length===1&&(E=E.map(A=>A+A)),E?`rgb${E.length===4?"a":""}(${E.map((A,R)=>R<3?parseInt(A,16):Math.round(parseInt(A,16)/255*1e3)/1e3).join(", ")})`:""}function o(P){const x=P.toString(16);return x.length===1?`0${x}`:x}function a(P){if(P.type)return P;if(P.charAt(0)==="#")return a(r(P));const x=P.indexOf("("),E=P.substring(0,x);if(["rgb","rgba","hsl","hsla","color"].indexOf(E)===-1)throw new Error((0,e.default)(9,P));let A=P.substring(x+1,P.length-1),R;if(E==="color"){if(A=A.split(" "),R=A.shift(),A.length===4&&A[3].charAt(0)==="/"&&(A[3]=A[3].slice(1)),["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].indexOf(R)===-1)throw new Error((0,e.default)(10,R))}else A=A.split(",");return A=A.map(M=>parseFloat(M)),{type:E,values:A,colorSpace:R}}const s=P=>{const x=a(P);return x.values.slice(0,3).map((E,A)=>x.type.indexOf("hsl")!==-1&&A!==0?`${E}%`:E).join(" ")};cl.colorChannel=s;const l=(P,x)=>{try{return s(P)}catch{return P}};cl.private_safeColorChannel=l;function u(P){const{type:x,colorSpace:E}=P;let{values:A}=P;return x.indexOf("rgb")!==-1?A=A.map((R,M)=>M<3?parseInt(R,10):R):x.indexOf("hsl")!==-1&&(A[1]=`${A[1]}%`,A[2]=`${A[2]}%`),x.indexOf("color")!==-1?A=`${E} ${A.join(" ")}`:A=`${A.join(", ")}`,`${x}(${A})`}function c(P){if(P.indexOf("#")===0)return P;const{values:x}=a(P);return`#${x.map((E,A)=>o(A===3?Math.round(255*E):E)).join("")}`}function d(P){P=a(P);const{values:x}=P,E=x[0],A=x[1]/100,R=x[2]/100,M=A*Math.min(R,1-R),D=(V,z=(V+E/30)%12)=>R-M*Math.max(Math.min(z-3,9-z,1),-1);let F="rgb";const I=[Math.round(D(0)*255),Math.round(D(8)*255),Math.round(D(4)*255)];return P.type==="hsla"&&(F+="a",I.push(x[3])),u({type:F,values:I})}function f(P){P=a(P);let x=P.type==="hsl"||P.type==="hsla"?a(d(P)).values:P.values;return x=x.map(E=>(P.type!=="color"&&(E/=255),E<=.03928?E/12.92:((E+.055)/1.055)**2.4)),Number((.2126*x[0]+.7152*x[1]+.0722*x[2]).toFixed(3))}function h(P,x){const E=f(P),A=f(x);return(Math.max(E,A)+.05)/(Math.min(E,A)+.05)}function p(P,x){return P=a(P),x=n(x),(P.type==="rgb"||P.type==="hsl")&&(P.type+="a"),P.type==="color"?P.values[3]=`/${x}`:P.values[3]=x,u(P)}function g(P,x,E){try{return p(P,x)}catch{return P}}function v(P,x){if(P=a(P),x=n(x),P.type.indexOf("hsl")!==-1)P.values[2]*=1-x;else if(P.type.indexOf("rgb")!==-1||P.type.indexOf("color")!==-1)for(let E=0;E<3;E+=1)P.values[E]*=1-x;return u(P)}function y(P,x,E){try{return v(P,x)}catch{return P}}function m(P,x){if(P=a(P),x=n(x),P.type.indexOf("hsl")!==-1)P.values[2]+=(100-P.values[2])*x;else if(P.type.indexOf("rgb")!==-1)for(let E=0;E<3;E+=1)P.values[E]+=(255-P.values[E])*x;else if(P.type.indexOf("color")!==-1)for(let E=0;E<3;E+=1)P.values[E]+=(1-P.values[E])*x;return u(P)}function b(P,x,E){try{return m(P,x)}catch{return P}}function S(P,x=.15){return f(P)>.5?v(P,x):m(P,x)}function _(P,x,E){try{return S(P,x)}catch{return P}}function C(P,x,E,A=1){const R=(I,V)=>Math.round((I**(1/A)*(1-E)+V**(1/A)*E)**A),M=a(P),D=a(x),F=[R(M.values[0],D.values[0]),R(M.values[1],D.values[1]),R(M.values[2],D.values[2])];return u({type:"rgb",values:F})}return cl}var uZ=zut();const P3={black:"#000",white:"#fff"},$ut={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},YM={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},qM={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},J2={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},XM={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},KM={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},ZM={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"},Wut=["mode","contrastThreshold","tonalOffset"],jle={text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:P3.white,default:P3.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}},X8={text:{primary:P3.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:P3.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}};function Vle(t,e,i,n){const r=n.light||n,o=n.dark||n*1.5;t[e]||(t.hasOwnProperty(i)?t[e]=t[i]:e==="light"?t.light=uZ.lighten(t.main,r):e==="dark"&&(t.dark=uZ.darken(t.main,o)))}function Gut(t="light"){return t==="dark"?{main:XM[200],light:XM[50],dark:XM[400]}:{main:XM[700],light:XM[400],dark:XM[800]}}function Yut(t="light"){return t==="dark"?{main:YM[200],light:YM[50],dark:YM[400]}:{main:YM[500],light:YM[300],dark:YM[700]}}function qut(t="light"){return t==="dark"?{main:qM[500],light:qM[300],dark:qM[700]}:{main:qM[700],light:qM[400],dark:qM[800]}}function Xut(t="light"){return t==="dark"?{main:KM[400],light:KM[300],dark:KM[700]}:{main:KM[700],light:KM[500],dark:KM[900]}}function Kut(t="light"){return t==="dark"?{main:ZM[400],light:ZM[300],dark:ZM[700]}:{main:ZM[800],light:ZM[500],dark:ZM[900]}}function Zut(t="light"){return t==="dark"?{main:J2[400],light:J2[300],dark:J2[700]}:{main:"#ed6c02",light:J2[500],dark:J2[900]}}function Jut(t){const{mode:e="light",contrastThreshold:i=3,tonalOffset:n=.2}=t,r=FS(t,Wut),o=t.primary||Gut(e),a=t.secondary||Yut(e),s=t.error||qut(e),l=t.info||Xut(e),u=t.success||Kut(e),c=t.warning||Zut(e);function d(g){return uZ.getContrastRatio(g,X8.text.primary)>=i?X8.text.primary:jle.text.primary}const f=({color:g,name:v,mainShade:y=500,lightShade:m=300,darkShade:b=700})=>{if(g=Gn({},g),!g.main&&g[y]&&(g.main=g[y]),!g.hasOwnProperty("main"))throw new Error(m3(11,v?` (${v})`:"",y));if(typeof g.main!="string")throw new Error(m3(12,v?` (${v})`:"",JSON.stringify(g.main)));return Vle(g,"light",m,n),Vle(g,"dark",b,n),g.contrastText||(g.contrastText=d(g.main)),g},h={dark:X8,light:jle};return nm(Gn({common:Gn({},P3),mode:e,primary:f({color:o,name:"primary"}),secondary:f({color:a,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:f({color:s,name:"error"}),warning:f({color:c,name:"warning"}),info:f({color:l,name:"info"}),success:f({color:u,name:"success"}),grey:$ut,contrastThreshold:i,getContrastText:d,augmentColor:f,tonalOffset:n},h[e]),r)}const Qut=["fontFamily","fontSize","fontWeightLight","fontWeightRegular","fontWeightMedium","fontWeightBold","htmlFontSize","allVariants","pxToRem"];function ect(t){return Math.round(t*1e5)/1e5}const Hle={textTransform:"uppercase"},Ule='"Roboto", "Helvetica", "Arial", sans-serif';function tct(t,e){const i=typeof e=="function"?e(t):e,{fontFamily:n=Ule,fontSize:r=14,fontWeightLight:o=300,fontWeightRegular:a=400,fontWeightMedium:s=500,fontWeightBold:l=700,htmlFontSize:u=16,allVariants:c,pxToRem:d}=i,f=FS(i,Qut),h=r/14,p=d||(y=>`${y/u*h}rem`),g=(y,m,b,S,_)=>Gn({fontFamily:n,fontWeight:y,fontSize:p(m),lineHeight:b},n===Ule?{letterSpacing:`${ect(S/m)}em`}:{},_,c),v={h1:g(o,96,1.167,-1.5),h2:g(o,60,1.2,-.5),h3:g(a,48,1.167,0),h4:g(a,34,1.235,.25),h5:g(a,24,1.334,0),h6:g(s,20,1.6,.15),subtitle1:g(a,16,1.75,.15),subtitle2:g(s,14,1.57,.1),body1:g(a,16,1.5,.15),body2:g(a,14,1.43,.15),button:g(s,14,1.75,.4,Hle),caption:g(a,12,1.66,.4),overline:g(a,12,2.66,1,Hle),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return nm(Gn({htmlFontSize:u,pxToRem:p,fontFamily:n,fontSize:r,fontWeightLight:o,fontWeightRegular:a,fontWeightMedium:s,fontWeightBold:l},v),f,{clone:!1})}const rct=.2,ict=.14,nct=.12;function zs(...t){return[`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,${rct})`,`${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,${ict})`,`${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,${nct})`].join(",")}const oct=["none",zs(0,2,1,-1,0,1,1,0,0,1,3,0),zs(0,3,1,-2,0,2,2,0,0,1,5,0),zs(0,3,3,-2,0,3,4,0,0,1,8,0),zs(0,2,4,-1,0,4,5,0,0,1,10,0),zs(0,3,5,-1,0,5,8,0,0,1,14,0),zs(0,3,5,-1,0,6,10,0,0,1,18,0),zs(0,4,5,-2,0,7,10,1,0,2,16,1),zs(0,5,5,-3,0,8,10,1,0,3,14,2),zs(0,5,6,-3,0,9,12,1,0,3,16,2),zs(0,6,6,-3,0,10,14,1,0,4,18,3),zs(0,6,7,-4,0,11,15,1,0,4,20,3),zs(0,7,8,-4,0,12,17,2,0,5,22,4),zs(0,7,8,-4,0,13,19,2,0,5,24,4),zs(0,7,9,-4,0,14,21,2,0,5,26,4),zs(0,8,9,-5,0,15,22,2,0,6,28,5),zs(0,8,10,-5,0,16,24,2,0,6,30,5),zs(0,8,11,-5,0,17,26,2,0,6,32,5),zs(0,9,11,-5,0,18,28,2,0,7,34,6),zs(0,9,12,-6,0,19,29,2,0,7,36,6),zs(0,10,13,-6,0,20,31,3,0,8,38,7),zs(0,10,13,-6,0,21,33,3,0,8,40,7),zs(0,10,14,-6,0,22,35,3,0,8,42,7),zs(0,11,14,-7,0,23,36,3,0,9,44,8),zs(0,11,15,-7,0,24,38,3,0,9,46,8)],act=["duration","easing","delay"],sct={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},lct={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function zle(t){return`${Math.round(t)}ms`}function uct(t){if(!t)return 0;const e=t/36;return Math.round((4+15*e**.25+e/5)*10)}function cct(t){const e=Gn({},sct,t.easing),i=Gn({},lct,t.duration);return Gn({getAutoHeightDuration:uct,create:(r=["all"],o={})=>{const{duration:a=i.standard,easing:s=e.easeInOut,delay:l=0}=o;return FS(o,act),(Array.isArray(r)?r:[r]).map(u=>`${u} ${typeof a=="string"?a:zle(a)} ${s} ${typeof l=="string"?l:zle(l)}`).join(",")}},t,{easing:e,duration:i})}const dct={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500},fct=["breakpoints","mixins","spacing","palette","transitions","typography","shape"];function hct(t={},...e){const{mixins:i={},palette:n={},transitions:r={},typography:o={}}=t,a=FS(t,fct);if(t.vars&&t.generateCssVars===void 0)throw new Error(m3(18));const s=Jut(n),l=cLe(t);let u=nm(l,{mixins:Vut(l.breakpoints,i),palette:s,shadows:oct.slice(),typography:tct(s,o),transitions:cct(r),zIndex:Gn({},dct)});return u=nm(u,a),u=e.reduce((c,d)=>nm(c,d),u),u.unstable_sxConfig=Gn({},MV,a==null?void 0:a.unstable_sxConfig),u.unstable_sx=function(d){return E6({sx:d,theme:this})},u}const pct=hct(),gct="$$material";function vct(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}const yct=t=>vct(t)&&t!=="classes",mct=jut({themeId:gct,defaultTheme:pct,rootShouldForwardProp:yct});function bct(t){return HMe("MuiSvgIcon",t)}Pst("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Sct=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],_ct=t=>{const{color:e,fontSize:i,classes:n}=t,r={root:["root",e!=="inherit"&&`color${OD(e)}`,`fontSize${OD(i)}`]};return mst(r,bct,n)},Pct=mct("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(t,e)=>{const{ownerState:i}=t;return[e.root,i.color!=="inherit"&&e[`color${OD(i.color)}`],e[`fontSize${OD(i.fontSize)}`]]}})(({theme:t,ownerState:e})=>{var i,n,r,o,a,s,l,u,c,d,f,h,p;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:e.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:(i=t.transitions)==null||(n=i.create)==null?void 0:n.call(i,"fill",{duration:(r=t.transitions)==null||(r=r.duration)==null?void 0:r.shorter}),fontSize:{inherit:"inherit",small:((o=t.typography)==null||(a=o.pxToRem)==null?void 0:a.call(o,20))||"1.25rem",medium:((s=t.typography)==null||(l=s.pxToRem)==null?void 0:l.call(s,24))||"1.5rem",large:((u=t.typography)==null||(c=u.pxToRem)==null?void 0:c.call(u,35))||"2.1875rem"}[e.fontSize],color:(d=(f=(t.vars||t).palette)==null||(f=f[e.color])==null?void 0:f.main)!=null?d:{action:(h=(t.vars||t).palette)==null||(h=h.action)==null?void 0:h.active,disabled:(p=(t.vars||t).palette)==null||(p=p.action)==null?void 0:p.disabled,inherit:void 0}[e.color]}}),cZ=J.forwardRef(function(e,i){const n=Ast({props:e,name:"MuiSvgIcon"}),{children:r,className:o,color:a="inherit",component:s="svg",fontSize:l="medium",htmlColor:u,inheritViewBox:c=!1,titleAccess:d,viewBox:f="0 0 24 24"}=n,h=FS(n,Sct),p=J.isValidElement(r)&&r.type==="svg",g=Gn({},n,{color:a,component:s,fontSize:l,instanceFontSize:e.fontSize,inheritViewBox:c,viewBox:f,hasSvgAsChild:p}),v={};c||(v.viewBox=f);const y=_ct(g);return L.jsxs(Pct,Gn({as:s,className:Rv(y.root,o),focusable:"false",color:u,"aria-hidden":d?void 0:!0,role:d?"img":void 0,ref:i},v,h,p&&r.props,{ownerState:g,children:[p?r.props.children:r,d?L.jsx("title",{children:d}):null]}))});cZ.muiName="SvgIcon";function cu(t,e){function i(n,r){return L.jsx(cZ,Gn({"data-testid":`${e}Icon`,ref:r},n,{children:t}))}return i.muiName=cZ.muiName,J.memo(J.forwardRef(i))}const Cct=cu(L.jsx("path",{d:"M18 13h-5v5c0 .55-.45 1-1 1s-1-.45-1-1v-5H6c-.55 0-1-.45-1-1s.45-1 1-1h5V6c0-.55.45-1 1-1s1 .45 1 1v5h5c.55 0 1 .45 1 1s-.45 1-1 1"}),"AddRounded"),Tct=cu(L.jsx("path",{d:"M9 16.17 5.53 12.7a.996.996 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41l4.18 4.18c.39.39 1.02.39 1.41 0L20.29 7.71c.39-.39.39-1.02 0-1.41a.996.996 0 0 0-1.41 0z"}),"CheckRounded"),xct=cu(L.jsx("path",{d:"M9.29 6.71c-.39.39-.39 1.02 0 1.41L13.17 12l-3.88 3.88c-.39.39-.39 1.02 0 1.41s1.02.39 1.41 0l4.59-4.59c.39-.39.39-1.02 0-1.41L10.7 6.7c-.38-.38-1.02-.38-1.41.01"}),"ChevronRightRounded"),dLe=cu(L.jsx("path",{d:"M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2"}),"CircleRounded"),Ect=cu(L.jsx("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}),"ClearOutlined"),uz=cu(L.jsx("path",{d:"M18.3 5.71a.996.996 0 0 0-1.41 0L12 10.59 7.11 5.7a.996.996 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41L10.59 12 5.7 16.89c-.39.39-.39 1.02 0 1.41s1.02.39 1.41 0L12 13.41l4.89 4.89c.39.39 1.02.39 1.41 0s.39-1.02 0-1.41L13.41 12l4.89-4.89c.38-.38.38-1.02 0-1.4"}),"CloseRounded"),wct=cu(L.jsx("path",{d:"M14.59 2.59c-.38-.38-.89-.59-1.42-.59H6c-1.1 0-2 .9-2 2v16c0 1.1.89 2 1.99 2H18c1.1 0 2-.9 2-2V8.83c0-.53-.21-1.04-.59-1.41zM15 18H9c-.55 0-1-.45-1-1s.45-1 1-1h6c.55 0 1 .45 1 1s-.45 1-1 1m0-4H9c-.55 0-1-.45-1-1s.45-1 1-1h6c.55 0 1 .45 1 1s-.45 1-1 1m-2-6V3.5L18.5 9H14c-.55 0-1-.45-1-1"}),"DescriptionRounded"),fLe=cu(L.jsx("path",{d:"M15.88 9.29 12 13.17 8.12 9.29a.996.996 0 0 0-1.41 0c-.39.39-.39 1.02 0 1.41l4.59 4.59c.39.39 1.02.39 1.41 0l4.59-4.59c.39-.39.39-1.02 0-1.41-.39-.38-1.03-.39-1.42 0"}),"ExpandMoreRounded"),Act=cu(L.jsx("path",{d:"M20 6h-8l-1.41-1.41C10.21 4.21 9.7 4 9.17 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2m-1 12H5c-.55 0-1-.45-1-1V9c0-.55.45-1 1-1h14c.55 0 1 .45 1 1v8c0 .55-.45 1-1 1"}),"FolderOpenRounded"),Oct=cu(L.jsx("path",{d:"M10.59 4.59C10.21 4.21 9.7 4 9.17 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2h-8z"}),"FolderRounded"),Dct=cu(L.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m-1-4h2v2h-2zm1.61-9.96c-2.06-.3-3.88.97-4.43 2.79-.18.58.26 1.17.87 1.17h.2c.41 0 .74-.29.88-.67.32-.89 1.27-1.5 2.3-1.28.95.2 1.65 1.13 1.57 2.1-.1 1.34-1.62 1.63-2.45 2.88 0 .01-.01.01-.01.02-.01.02-.02.03-.03.05-.09.15-.18.32-.25.5-.01.03-.03.05-.04.08-.01.02-.01.04-.02.07-.12.34-.2.75-.2 1.25h2c0-.42.11-.77.28-1.07.02-.03.03-.06.05-.09.08-.14.18-.27.28-.39.01-.01.02-.03.03-.04.1-.12.21-.23.33-.34.96-.91 2.26-1.65 1.99-3.56-.24-1.74-1.61-3.21-3.35-3.47"}),"HelpOutlineRounded"),Rct=cu(L.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m0 15c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1s1 .45 1 1v4c0 .55-.45 1-1 1m1-8h-2V7h2z"}),"InfoRounded"),hLe=cu(L.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m-2 14c-.55 0-1-.45-1-1V9c0-.55.45-1 1-1s1 .45 1 1v6c0 .55-.45 1-1 1m4 0c-.55 0-1-.45-1-1V9c0-.55.45-1 1-1s1 .45 1 1v6c0 .55-.45 1-1 1"}),"PauseCircleFilledRounded"),Yee=cu(L.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m-2 13.5v-7c0-.41.47-.65.8-.4l4.67 3.5c.27.2.27.6 0 .8l-4.67 3.5c-.33.25-.8.01-.8-.4"}),"PlayCircleFilledRounded"),Mct=cu(L.jsx("path",{d:"M18 13H6c-.55 0-1-.45-1-1s.45-1 1-1h12c.55 0 1 .45 1 1s-.45 1-1 1"}),"RemoveRounded"),$le=cu(L.jsx("path",{d:"M7 7h10v1.79c0 .45.54.67.85.35l2.79-2.79c.2-.2.2-.51 0-.71l-2.79-2.79c-.31-.31-.85-.09-.85.36V5H6c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1s1-.45 1-1zm10 10H7v-1.79c0-.45-.54-.67-.85-.35l-2.79 2.79c-.2.2-.2.51 0 .71l2.79 2.79c.31.31.85.09.85-.36V19h11c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1s-1 .45-1 1z"}),"RepeatRounded"),Lct=cu(L.jsx("path",{d:"M19.14 12.94c.04-.3.06-.61.06-.94 0-.32-.02-.64-.07-.94l2.03-1.58c.18-.14.23-.41.12-.61l-1.92-3.32c-.12-.22-.37-.29-.59-.22l-2.39.96c-.5-.38-1.03-.7-1.62-.94l-.36-2.54c-.04-.24-.24-.41-.48-.41h-3.84c-.24 0-.43.17-.47.41l-.36 2.54c-.59.24-1.13.57-1.62.94l-2.39-.96c-.22-.08-.47 0-.59.22L2.74 8.87c-.12.21-.08.47.12.61l2.03 1.58c-.05.3-.09.63-.09.94s.02.64.07.94l-2.03 1.58c-.18.14-.23.41-.12.61l1.92 3.32c.12.22.37.29.59.22l2.39-.96c.5.38 1.03.7 1.62.94l.36 2.54c.05.24.24.41.48.41h3.84c.24 0 .44-.17.47-.41l.36-2.54c.59-.24 1.13-.56 1.62-.94l2.39.96c.22.08.47 0 .59-.22l1.92-3.32c.12-.22.07-.47-.12-.61zM12 15.6c-1.98 0-3.6-1.62-3.6-3.6s1.62-3.6 3.6-3.6 3.6 1.62 3.6 3.6-1.62 3.6-3.6 3.6"}),"Settings"),pLe=cu(L.jsx("path",{d:"M7 6c.55 0 1 .45 1 1v10c0 .55-.45 1-1 1s-1-.45-1-1V7c0-.55.45-1 1-1m3.66 6.82 5.77 4.07c.66.47 1.58-.01 1.58-.82V7.93c0-.81-.91-1.28-1.58-.82l-5.77 4.07c-.57.4-.57 1.24 0 1.64"}),"SkipPreviousRounded"),kct=cu(L.jsx("path",{d:"M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2M8 14H6v-2h2zm0-3H6V9h2zm0-3H6V6h2zm6 6h-3c-.55 0-1-.45-1-1s.45-1 1-1h3c.55 0 1 .45 1 1s-.45 1-1 1m3-3h-6c-.55 0-1-.45-1-1s.45-1 1-1h6c.55 0 1 .45 1 1s-.45 1-1 1m0-3h-6c-.55 0-1-.45-1-1s.45-1 1-1h6c.55 0 1 .45 1 1s-.45 1-1 1"}),"SpeakerNotesRounded"),Ict=cu(L.jsx("path",{d:"M3.63 3.63c-.39.39-.39 1.02 0 1.41L7.29 8.7 7 9H4c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1h3l3.29 3.29c.63.63 1.71.18 1.71-.71v-4.17l4.18 4.18c-.49.37-1.02.68-1.6.91-.36.15-.58.53-.58.92 0 .72.73 1.18 1.39.91.8-.33 1.55-.77 2.22-1.31l1.34 1.34c.39.39 1.02.39 1.41 0s.39-1.02 0-1.41L5.05 3.63c-.39-.39-1.02-.39-1.42 0M19 12c0 .82-.15 1.61-.41 2.34l1.53 1.53c.56-1.17.88-2.48.88-3.87 0-3.83-2.4-7.11-5.78-8.4-.59-.23-1.22.23-1.22.86v.19c0 .38.25.71.61.85C17.18 6.54 19 9.06 19 12m-8.71-6.29-.17.17L12 7.76V6.41c0-.89-1.08-1.33-1.71-.7M16.5 12c0-1.77-1.02-3.29-2.5-4.03v1.79l2.48 2.48c.01-.08.02-.16.02-.24"}),"VolumeOffRounded"),Nct=cu(L.jsx("path",{d:"M3 10v4c0 .55.45 1 1 1h3l3.29 3.29c.63.63 1.71.18 1.71-.71V6.41c0-.89-1.08-1.34-1.71-.71L7 9H4c-.55 0-1 .45-1 1m13.5 2c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02M14 4.45v.2c0 .38.25.71.6.85C17.18 6.53 19 9.06 19 12s-1.82 5.47-4.4 6.5c-.36.14-.6.47-.6.85v.2c0 .63.63 1.07 1.21.85C18.6 19.11 21 15.84 21 12s-2.4-7.11-5.79-8.4c-.58-.23-1.21.22-1.21.85"}),"VolumeUpRounded");var Fct=function(e){return Bct(e)&&!jct(e)};function Bct(t){return!!t&&typeof t=="object"}function jct(t){var e=Object.prototype.toString.call(t);return e==="[object RegExp]"||e==="[object Date]"||Uct(t)}var Vct=typeof Symbol=="function"&&Symbol.for,Hct=Vct?Symbol.for("react.element"):60103;function Uct(t){return t.$$typeof===Hct}function zct(t){return Array.isArray(t)?[]:{}}function cz(t,e){return e.clone!==!1&&e.isMergeableObject(t)?C3(zct(t),t,e):t}function $ct(t,e,i){return t.concat(e).map(function(n){return cz(n,i)})}function Wct(t,e,i){var n={};return i.isMergeableObject(t)&&Object.keys(t).forEach(function(r){n[r]=cz(t[r],i)}),Object.keys(e).forEach(function(r){!i.isMergeableObject(e[r])||!t[r]?n[r]=cz(e[r],i):n[r]=C3(t[r],e[r],i)}),n}function C3(t,e,i){i=i||{},i.arrayMerge=i.arrayMerge||$ct,i.isMergeableObject=i.isMergeableObject||Fct;var n=Array.isArray(e),r=Array.isArray(t),o=n===r;return o?n?i.arrayMerge(t,e,i):Wct(t,e,i):cz(e,i)}C3.all=function(e,i){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(n,r){return C3(n,r,i)},{})};var dZ=C3,gLe=typeof global=="object"&&global&&global.Object===Object&&global,Gct=typeof self=="object"&&self&&self.Object===Object&&self,Tm=gLe||Gct||Function("return this")(),CP=Tm.Symbol,vLe=Object.prototype,Yct=vLe.hasOwnProperty,qct=vLe.toString,Q2=CP?CP.toStringTag:void 0;function Xct(t){var e=Yct.call(t,Q2),i=t[Q2];try{t[Q2]=void 0;var n=!0}catch{}var r=qct.call(t);return n&&(e?t[Q2]=i:delete t[Q2]),r}var Kct=Object.prototype,Zct=Kct.toString;function Jct(t){return Zct.call(t)}var Qct="[object Null]",edt="[object Undefined]",Wle=CP?CP.toStringTag:void 0;function zD(t){return t==null?t===void 0?edt:Qct:Wle&&Wle in Object(t)?Xct(t):Jct(t)}function yLe(t,e){return function(i){return t(e(i))}}var qee=yLe(Object.getPrototypeOf,Object);function $D(t){return t!=null&&typeof t=="object"}var tdt="[object Object]",rdt=Function.prototype,idt=Object.prototype,mLe=rdt.toString,ndt=idt.hasOwnProperty,odt=mLe.call(Object);function Gle(t){if(!$D(t)||zD(t)!=tdt)return!1;var e=qee(t);if(e===null)return!0;var i=ndt.call(e,"constructor")&&e.constructor;return typeof i=="function"&&i instanceof i&&mLe.call(i)==odt}function adt(){this.__data__=[],this.size=0}function bLe(t,e){return t===e||t!==t&&e!==e}function w6(t,e){for(var i=t.length;i--;)if(bLe(t[i][0],e))return i;return-1}var sdt=Array.prototype,ldt=sdt.splice;function udt(t){var e=this.__data__,i=w6(e,t);if(i<0)return!1;var n=e.length-1;return i==n?e.pop():ldt.call(e,i,1),--this.size,!0}function cdt(t){var e=this.__data__,i=w6(e,t);return i<0?void 0:e[i][1]}function ddt(t){return w6(this.__data__,t)>-1}function fdt(t,e){var i=this.__data__,n=w6(i,t);return n<0?(++this.size,i.push([t,e])):i[n][1]=e,this}function BS(t){var e=-1,i=t==null?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}BS.prototype.clear=adt;BS.prototype.delete=udt;BS.prototype.get=cdt;BS.prototype.has=ddt;BS.prototype.set=fdt;function hdt(){this.__data__=new BS,this.size=0}function pdt(t){var e=this.__data__,i=e.delete(t);return this.size=e.size,i}function gdt(t){return this.__data__.get(t)}function vdt(t){return this.__data__.has(t)}function LV(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var ydt="[object AsyncFunction]",mdt="[object Function]",bdt="[object GeneratorFunction]",Sdt="[object Proxy]";function SLe(t){if(!LV(t))return!1;var e=zD(t);return e==mdt||e==bdt||e==ydt||e==Sdt}var K8=Tm["__core-js_shared__"],Yle=(function(){var t=/[^.]+$/.exec(K8&&K8.keys&&K8.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function _dt(t){return!!Yle&&Yle in t}var Pdt=Function.prototype,Cdt=Pdt.toString;function WD(t){if(t!=null){try{return Cdt.call(t)}catch{}try{return t+""}catch{}}return""}var Tdt=/[\\^$.*+?()[\]{}|]/g,xdt=/^\[object .+?Constructor\]$/,Edt=Function.prototype,wdt=Object.prototype,Adt=Edt.toString,Odt=wdt.hasOwnProperty,Ddt=RegExp("^"+Adt.call(Odt).replace(Tdt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Rdt(t){if(!LV(t)||_dt(t))return!1;var e=SLe(t)?Ddt:xdt;return e.test(WD(t))}function Mdt(t,e){return t==null?void 0:t[e]}function GD(t,e){var i=Mdt(t,e);return Rdt(i)?i:void 0}var T3=GD(Tm,"Map"),x3=GD(Object,"create");function Ldt(){this.__data__=x3?x3(null):{},this.size=0}function kdt(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var Idt="__lodash_hash_undefined__",Ndt=Object.prototype,Fdt=Ndt.hasOwnProperty;function Bdt(t){var e=this.__data__;if(x3){var i=e[t];return i===Idt?void 0:i}return Fdt.call(e,t)?e[t]:void 0}var jdt=Object.prototype,Vdt=jdt.hasOwnProperty;function Hdt(t){var e=this.__data__;return x3?e[t]!==void 0:Vdt.call(e,t)}var Udt="__lodash_hash_undefined__";function zdt(t,e){var i=this.__data__;return this.size+=this.has(t)?0:1,i[t]=x3&&e===void 0?Udt:e,this}function DD(t){var e=-1,i=t==null?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}DD.prototype.clear=Ldt;DD.prototype.delete=kdt;DD.prototype.get=Bdt;DD.prototype.has=Hdt;DD.prototype.set=zdt;function $dt(){this.size=0,this.__data__={hash:new DD,map:new(T3||BS),string:new DD}}function Wdt(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}function A6(t,e){var i=t.__data__;return Wdt(e)?i[typeof e=="string"?"string":"hash"]:i.map}function Gdt(t){var e=A6(this,t).delete(t);return this.size-=e?1:0,e}function Ydt(t){return A6(this,t).get(t)}function qdt(t){return A6(this,t).has(t)}function Xdt(t,e){var i=A6(this,t),n=i.size;return i.set(t,e),this.size+=i.size==n?0:1,this}function YP(t){var e=-1,i=t==null?0:t.length;for(this.clear();++e<i;){var n=t[e];this.set(n[0],n[1])}}YP.prototype.clear=$dt;YP.prototype.delete=Gdt;YP.prototype.get=Ydt;YP.prototype.has=qdt;YP.prototype.set=Xdt;var Kdt=200;function Zdt(t,e){var i=this.__data__;if(i instanceof BS){var n=i.__data__;if(!T3||n.length<Kdt-1)return n.push([t,e]),this.size=++i.size,this;i=this.__data__=new YP(n)}return i.set(t,e),this.size=i.size,this}function vI(t){var e=this.__data__=new BS(t);this.size=e.size}vI.prototype.clear=hdt;vI.prototype.delete=pdt;vI.prototype.get=gdt;vI.prototype.has=vdt;vI.prototype.set=Zdt;function Jdt(t,e){for(var i=-1,n=t==null?0:t.length;++i<n&&e(t[i],i,t)!==!1;);return t}var qle=(function(){try{var t=GD(Object,"defineProperty");return t({},"",{}),t}catch{}})();function _Le(t,e,i){e=="__proto__"&&qle?qle(t,e,{configurable:!0,enumerable:!0,value:i,writable:!0}):t[e]=i}var Qdt=Object.prototype,eft=Qdt.hasOwnProperty;function PLe(t,e,i){var n=t[e];(!(eft.call(t,e)&&bLe(n,i))||i===void 0&&!(e in t))&&_Le(t,e,i)}function O6(t,e,i,n){var r=!i;i||(i={});for(var o=-1,a=e.length;++o<a;){var s=e[o],l=void 0;l===void 0&&(l=t[s]),r?_Le(i,s,l):PLe(i,s,l)}return i}function tft(t,e){for(var i=-1,n=Array(t);++i<t;)n[i]=e(i);return n}var rft="[object Arguments]";function Xle(t){return $D(t)&&zD(t)==rft}var CLe=Object.prototype,ift=CLe.hasOwnProperty,nft=CLe.propertyIsEnumerable,oft=Xle((function(){return arguments})())?Xle:function(t){return $D(t)&&ift.call(t,"callee")&&!nft.call(t,"callee")},kV=Array.isArray;function aft(){return!1}var TLe=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Kle=TLe&&typeof module=="object"&&module&&!module.nodeType&&module,sft=Kle&&Kle.exports===TLe,Zle=sft?Tm.Buffer:void 0,lft=Zle?Zle.isBuffer:void 0,xLe=lft||aft,uft=9007199254740991,cft=/^(?:0|[1-9]\d*)$/;function dft(t,e){var i=typeof t;return e=e??uft,!!e&&(i=="number"||i!="symbol"&&cft.test(t))&&t>-1&&t%1==0&&t<e}var fft=9007199254740991;function ELe(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=fft}var hft="[object Arguments]",pft="[object Array]",gft="[object Boolean]",vft="[object Date]",yft="[object Error]",mft="[object Function]",bft="[object Map]",Sft="[object Number]",_ft="[object Object]",Pft="[object RegExp]",Cft="[object Set]",Tft="[object String]",xft="[object WeakMap]",Eft="[object ArrayBuffer]",wft="[object DataView]",Aft="[object Float32Array]",Oft="[object Float64Array]",Dft="[object Int8Array]",Rft="[object Int16Array]",Mft="[object Int32Array]",Lft="[object Uint8Array]",kft="[object Uint8ClampedArray]",Ift="[object Uint16Array]",Nft="[object Uint32Array]",Ds={};Ds[Aft]=Ds[Oft]=Ds[Dft]=Ds[Rft]=Ds[Mft]=Ds[Lft]=Ds[kft]=Ds[Ift]=Ds[Nft]=!0;Ds[hft]=Ds[pft]=Ds[Eft]=Ds[gft]=Ds[wft]=Ds[vft]=Ds[yft]=Ds[mft]=Ds[bft]=Ds[Sft]=Ds[_ft]=Ds[Pft]=Ds[Cft]=Ds[Tft]=Ds[xft]=!1;function Fft(t){return $D(t)&&ELe(t.length)&&!!Ds[zD(t)]}function Xee(t){return function(e){return t(e)}}var wLe=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Ej=wLe&&typeof module=="object"&&module&&!module.nodeType&&module,Bft=Ej&&Ej.exports===wLe,Z8=Bft&&gLe.process,Vk=(function(){try{var t=Ej&&Ej.require&&Ej.require("util").types;return t||Z8&&Z8.binding&&Z8.binding("util")}catch{}})(),Jle=Vk&&Vk.isTypedArray,jft=Jle?Xee(Jle):Fft,Vft=Object.prototype,Hft=Vft.hasOwnProperty;function ALe(t,e){var i=kV(t),n=!i&&oft(t),r=!i&&!n&&xLe(t),o=!i&&!n&&!r&&jft(t),a=i||n||r||o,s=a?tft(t.length,String):[],l=s.length;for(var u in t)(e||Hft.call(t,u))&&!(a&&(u=="length"||r&&(u=="offset"||u=="parent")||o&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||dft(u,l)))&&s.push(u);return s}var Uft=Object.prototype;function Kee(t){var e=t&&t.constructor,i=typeof e=="function"&&e.prototype||Uft;return t===i}var zft=yLe(Object.keys,Object),$ft=Object.prototype,Wft=$ft.hasOwnProperty;function Gft(t){if(!Kee(t))return zft(t);var e=[];for(var i in Object(t))Wft.call(t,i)&&i!="constructor"&&e.push(i);return e}function OLe(t){return t!=null&&ELe(t.length)&&!SLe(t)}function Zee(t){return OLe(t)?ALe(t):Gft(t)}function Yft(t,e){return t&&O6(e,Zee(e),t)}function qft(t){var e=[];if(t!=null)for(var i in Object(t))e.push(i);return e}var Xft=Object.prototype,Kft=Xft.hasOwnProperty;function Zft(t){if(!LV(t))return qft(t);var e=Kee(t),i=[];for(var n in t)n=="constructor"&&(e||!Kft.call(t,n))||i.push(n);return i}function Jee(t){return OLe(t)?ALe(t,!0):Zft(t)}function Jft(t,e){return t&&O6(e,Jee(e),t)}var DLe=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Qle=DLe&&typeof module=="object"&&module&&!module.nodeType&&module,Qft=Qle&&Qle.exports===DLe,eue=Qft?Tm.Buffer:void 0,tue=eue?eue.allocUnsafe:void 0;function eht(t,e){if(e)return t.slice();var i=t.length,n=tue?tue(i):new t.constructor(i);return t.copy(n),n}function RLe(t,e){var i=-1,n=t.length;for(e||(e=Array(n));++i<n;)e[i]=t[i];return e}function tht(t,e){for(var i=-1,n=t==null?0:t.length,r=0,o=[];++i<n;){var a=t[i];e(a,i,t)&&(o[r++]=a)}return o}function MLe(){return[]}var rht=Object.prototype,iht=rht.propertyIsEnumerable,rue=Object.getOwnPropertySymbols,Qee=rue?function(t){return t==null?[]:(t=Object(t),tht(rue(t),function(e){return iht.call(t,e)}))}:MLe;function nht(t,e){return O6(t,Qee(t),e)}function LLe(t,e){for(var i=-1,n=e.length,r=t.length;++i<n;)t[r+i]=e[i];return t}var oht=Object.getOwnPropertySymbols,kLe=oht?function(t){for(var e=[];t;)LLe(e,Qee(t)),t=qee(t);return e}:MLe;function aht(t,e){return O6(t,kLe(t),e)}function ILe(t,e,i){var n=e(t);return kV(t)?n:LLe(n,i(t))}function sht(t){return ILe(t,Zee,Qee)}function lht(t){return ILe(t,Jee,kLe)}var fZ=GD(Tm,"DataView"),hZ=GD(Tm,"Promise"),pZ=GD(Tm,"Set"),gZ=GD(Tm,"WeakMap"),iue="[object Map]",uht="[object Object]",nue="[object Promise]",oue="[object Set]",aue="[object WeakMap]",sue="[object DataView]",cht=WD(fZ),dht=WD(T3),fht=WD(hZ),hht=WD(pZ),pht=WD(gZ),Qb=zD;(fZ&&Qb(new fZ(new ArrayBuffer(1)))!=sue||T3&&Qb(new T3)!=iue||hZ&&Qb(hZ.resolve())!=nue||pZ&&Qb(new pZ)!=oue||gZ&&Qb(new gZ)!=aue)&&(Qb=function(t){var e=zD(t),i=e==uht?t.constructor:void 0,n=i?WD(i):"";if(n)switch(n){case cht:return sue;case dht:return iue;case fht:return nue;case hht:return oue;case pht:return aue}return e});var ght=Object.prototype,vht=ght.hasOwnProperty;function yht(t){var e=t.length,i=new t.constructor(e);return e&&typeof t[0]=="string"&&vht.call(t,"index")&&(i.index=t.index,i.input=t.input),i}var lue=Tm.Uint8Array;function ete(t){var e=new t.constructor(t.byteLength);return new lue(e).set(new lue(t)),e}function mht(t,e){var i=e?ete(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.byteLength)}var bht=/\w*$/;function Sht(t){var e=new t.constructor(t.source,bht.exec(t));return e.lastIndex=t.lastIndex,e}var uue=CP?CP.prototype:void 0,cue=uue?uue.valueOf:void 0;function _ht(t){return cue?Object(cue.call(t)):{}}function Pht(t,e){var i=e?ete(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}var Cht="[object Boolean]",Tht="[object Date]",xht="[object Map]",Eht="[object Number]",wht="[object RegExp]",Aht="[object Set]",Oht="[object String]",Dht="[object Symbol]",Rht="[object ArrayBuffer]",Mht="[object DataView]",Lht="[object Float32Array]",kht="[object Float64Array]",Iht="[object Int8Array]",Nht="[object Int16Array]",Fht="[object Int32Array]",Bht="[object Uint8Array]",jht="[object Uint8ClampedArray]",Vht="[object Uint16Array]",Hht="[object Uint32Array]";function Uht(t,e,i){var n=t.constructor;switch(e){case Rht:return ete(t);case Cht:case Tht:return new n(+t);case Mht:return mht(t,i);case Lht:case kht:case Iht:case Nht:case Fht:case Bht:case jht:case Vht:case Hht:return Pht(t,i);case xht:return new n;case Eht:case Oht:return new n(t);case wht:return Sht(t);case Aht:return new n;case Dht:return _ht(t)}}var due=Object.create,zht=(function(){function t(){}return function(e){if(!LV(e))return{};if(due)return due(e);t.prototype=e;var i=new t;return t.prototype=void 0,i}})();function $ht(t){return typeof t.constructor=="function"&&!Kee(t)?zht(qee(t)):{}}var Wht="[object Map]";function Ght(t){return $D(t)&&Qb(t)==Wht}var fue=Vk&&Vk.isMap,Yht=fue?Xee(fue):Ght,qht="[object Set]";function Xht(t){return $D(t)&&Qb(t)==qht}var hue=Vk&&Vk.isSet,Kht=hue?Xee(hue):Xht,Zht=1,Jht=2,Qht=4,NLe="[object Arguments]",ept="[object Array]",tpt="[object Boolean]",rpt="[object Date]",ipt="[object Error]",FLe="[object Function]",npt="[object GeneratorFunction]",opt="[object Map]",apt="[object Number]",BLe="[object Object]",spt="[object RegExp]",lpt="[object Set]",upt="[object String]",cpt="[object Symbol]",dpt="[object WeakMap]",fpt="[object ArrayBuffer]",hpt="[object DataView]",ppt="[object Float32Array]",gpt="[object Float64Array]",vpt="[object Int8Array]",ypt="[object Int16Array]",mpt="[object Int32Array]",bpt="[object Uint8Array]",Spt="[object Uint8ClampedArray]",_pt="[object Uint16Array]",Ppt="[object Uint32Array]",ds={};ds[NLe]=ds[ept]=ds[fpt]=ds[hpt]=ds[tpt]=ds[rpt]=ds[ppt]=ds[gpt]=ds[vpt]=ds[ypt]=ds[mpt]=ds[opt]=ds[apt]=ds[BLe]=ds[spt]=ds[lpt]=ds[upt]=ds[cpt]=ds[bpt]=ds[Spt]=ds[_pt]=ds[Ppt]=!0;ds[ipt]=ds[FLe]=ds[dpt]=!1;function wj(t,e,i,n,r,o){var a,s=e&Zht,l=e&Jht,u=e&Qht;if(a!==void 0)return a;if(!LV(t))return t;var c=kV(t);if(c){if(a=yht(t),!s)return RLe(t,a)}else{var d=Qb(t),f=d==FLe||d==npt;if(xLe(t))return eht(t,s);if(d==BLe||d==NLe||f&&!r){if(a=l||f?{}:$ht(t),!s)return l?aht(t,Jft(a,t)):nht(t,Yft(a,t))}else{if(!ds[d])return r?t:{};a=Uht(t,d,s)}}o||(o=new vI);var h=o.get(t);if(h)return h;o.set(t,a),Kht(t)?t.forEach(function(v){a.add(wj(v,e,i,v,t,o))}):Yht(t)&&t.forEach(function(v,y){a.set(y,wj(v,e,i,y,t,o))});var p=u?l?lht:sht:l?Jee:Zee,g=c?void 0:p(t);return Jdt(g||t,function(v,y){g&&(y=v,v=t[y]),PLe(a,y,wj(v,e,i,y,t,o))}),a}var Cpt=1,Tpt=4;function l4(t){return wj(t,Cpt|Tpt)}var J8,pue;function xpt(){if(pue)return J8;pue=1;var t=Array.isArray,e=Object.keys,i=Object.prototype.hasOwnProperty,n=typeof Element<"u";function r(o,a){if(o===a)return!0;if(o&&a&&typeof o=="object"&&typeof a=="object"){var s=t(o),l=t(a),u,c,d;if(s&&l){if(c=o.length,c!=a.length)return!1;for(u=c;u--!==0;)if(!r(o[u],a[u]))return!1;return!0}if(s!=l)return!1;var f=o instanceof Date,h=a instanceof Date;if(f!=h)return!1;if(f&&h)return o.getTime()==a.getTime();var p=o instanceof RegExp,g=a instanceof RegExp;if(p!=g)return!1;if(p&&g)return o.toString()==a.toString();var v=e(o);if(c=v.length,c!==e(a).length)return!1;for(u=c;u--!==0;)if(!i.call(a,v[u]))return!1;if(n&&o instanceof Element&&a instanceof Element)return o===a;for(u=c;u--!==0;)if(d=v[u],!(d==="_owner"&&o.$$typeof)&&!r(o[d],a[d]))return!1;return!0}return o!==o&&a!==a}return J8=function(a,s){try{return r(a,s)}catch(l){if(l.message&&l.message.match(/stack|recursion/i)||l.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",l.name,l.message),!1;throw l}},J8}var Ept=xpt();const kO=wc(Ept);var wpt=4;function gue(t){return wj(t,wpt)}function jLe(t,e){for(var i=-1,n=t==null?0:t.length,r=Array(n);++i<n;)r[i]=e(t[i],i,t);return r}var Apt="[object Symbol]";function tte(t){return typeof t=="symbol"||$D(t)&&zD(t)==Apt}var Opt="Expected a function";function rte(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(Opt);var i=function(){var n=arguments,r=e?e.apply(this,n):n[0],o=i.cache;if(o.has(r))return o.get(r);var a=t.apply(this,n);return i.cache=o.set(r,a)||o,a};return i.cache=new(rte.Cache||YP),i}rte.Cache=YP;var Dpt=500;function Rpt(t){var e=rte(t,function(n){return i.size===Dpt&&i.clear(),n}),i=e.cache;return e}var Mpt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Lpt=/\\(\\)?/g,kpt=Rpt(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(Mpt,function(i,n,r,o){e.push(r?o.replace(Lpt,"$1"):n||i)}),e});function Ipt(t){if(typeof t=="string"||tte(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}var vue=CP?CP.prototype:void 0,yue=vue?vue.toString:void 0;function VLe(t){if(typeof t=="string")return t;if(kV(t))return jLe(t,VLe)+"";if(tte(t))return yue?yue.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}function Npt(t){return t==null?"":VLe(t)}function HLe(t){return kV(t)?jLe(t,Ipt):tte(t)?[t]:RLe(kpt(Npt(t)))}function _c(){return _c=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n]=i[n])}return t},_c.apply(this,arguments)}function ULe(t,e){if(t==null)return{};var i={},n=Object.keys(t),r,o;for(o=0;o<n.length;o++)r=n[o],!(e.indexOf(r)>=0)&&(i[r]=t[r]);return i}var D6=J.createContext(void 0);D6.displayName="FormikContext";D6.Provider;D6.Consumer;function Fpt(){var t=J.useContext(D6);return t}var fv=function(e){return typeof e=="function"},R6=function(e){return e!==null&&typeof e=="object"},Bpt=function(e){return String(Math.floor(Number(e)))===e},Q8=function(e){return Object.prototype.toString.call(e)==="[object String]"},eY=function(e){return R6(e)&&fv(e.then)};function yp(t,e,i,n){n===void 0&&(n=0);for(var r=HLe(e);t&&n<r.length;)t=t[r[n++]];return n!==r.length&&!t||t===void 0?i:t}function lD(t,e,i){for(var n=gue(t),r=n,o=0,a=HLe(e);o<a.length-1;o++){var s=a[o],l=yp(t,a.slice(0,o+1));if(l&&(R6(l)||Array.isArray(l)))r=r[s]=gue(l);else{var u=a[o+1];r=r[s]=Bpt(u)&&Number(u)>=0?[]:{}}}return(o===0?t:r)[a[o]]===i?t:(i===void 0?delete r[a[o]]:r[a[o]]=i,o===0&&i===void 0&&delete n[a[o]],n)}function zLe(t,e,i,n){i===void 0&&(i=new WeakMap),n===void 0&&(n={});for(var r=0,o=Object.keys(t);r<o.length;r++){var a=o[r],s=t[a];R6(s)?i.get(s)||(i.set(s,!0),n[a]=Array.isArray(s)?[]:{},zLe(s,e,i,n[a])):n[a]=e}return n}function jpt(t,e){switch(e.type){case"SET_VALUES":return _c({},t,{values:e.payload});case"SET_TOUCHED":return _c({},t,{touched:e.payload});case"SET_ERRORS":return kO(t.errors,e.payload)?t:_c({},t,{errors:e.payload});case"SET_STATUS":return _c({},t,{status:e.payload});case"SET_ISSUBMITTING":return _c({},t,{isSubmitting:e.payload});case"SET_ISVALIDATING":return _c({},t,{isValidating:e.payload});case"SET_FIELD_VALUE":return _c({},t,{values:lD(t.values,e.payload.field,e.payload.value)});case"SET_FIELD_TOUCHED":return _c({},t,{touched:lD(t.touched,e.payload.field,e.payload.value)});case"SET_FIELD_ERROR":return _c({},t,{errors:lD(t.errors,e.payload.field,e.payload.value)});case"RESET_FORM":return _c({},t,e.payload);case"SET_FORMIK_STATE":return e.payload(t);case"SUBMIT_ATTEMPT":return _c({},t,{touched:zLe(t.values,!0),isSubmitting:!0,submitCount:t.submitCount+1});case"SUBMIT_FAILURE":return _c({},t,{isSubmitting:!1});case"SUBMIT_SUCCESS":return _c({},t,{isSubmitting:!1});default:return t}}var mT={},u4={};function Vpt(t){var e=t.validateOnChange,i=e===void 0?!0:e,n=t.validateOnBlur,r=n===void 0?!0:n,o=t.validateOnMount,a=o===void 0?!1:o,s=t.isInitialValid,l=t.enableReinitialize,u=l===void 0?!1:l,c=t.onSubmit,d=ULe(t,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),f=_c({validateOnChange:i,validateOnBlur:r,validateOnMount:a,onSubmit:c},d),h=J.useRef(f.initialValues),p=J.useRef(f.initialErrors||mT),g=J.useRef(f.initialTouched||u4),v=J.useRef(f.initialStatus),y=J.useRef(!1),m=J.useRef({});J.useEffect(function(){return y.current=!0,function(){y.current=!1}},[]);var b=J.useState(0),S=b[1],_=J.useRef({values:l4(f.initialValues),errors:l4(f.initialErrors)||mT,touched:l4(f.initialTouched)||u4,status:l4(f.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),C=_.current,P=J.useCallback(function(Ce){var Ue=_.current;_.current=jpt(Ue,Ce),Ue!==_.current&&S(function(Qe){return Qe+1})},[]),x=J.useCallback(function(Ce,Ue){return new Promise(function(Qe,it){var xt=f.validate(Ce,Ue);xt==null?Qe(mT):eY(xt)?xt.then(function(wt){Qe(wt||mT)},function(wt){it(wt)}):Qe(xt)})},[f.validate]),E=J.useCallback(function(Ce,Ue){var Qe=f.validationSchema,it=fv(Qe)?Qe(Ue):Qe,xt=Ue&&it.validateAt?it.validateAt(Ue,Ce):Upt(Ce,it);return new Promise(function(wt,$t){xt.then(function(){wt(mT)},function(Mt){Mt.name==="ValidationError"?wt(Hpt(Mt)):$t(Mt)})})},[f.validationSchema]),A=J.useCallback(function(Ce,Ue){return new Promise(function(Qe){return Qe(m.current[Ce].validate(Ue))})},[]),R=J.useCallback(function(Ce){var Ue=Object.keys(m.current).filter(function(it){return fv(m.current[it].validate)}),Qe=Ue.length>0?Ue.map(function(it){return A(it,yp(Ce,it))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all(Qe).then(function(it){return it.reduce(function(xt,wt,$t){return wt==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||wt&&(xt=lD(xt,Ue[$t],wt)),xt},{})})},[A]),M=J.useCallback(function(Ce){return Promise.all([R(Ce),f.validationSchema?E(Ce):{},f.validate?x(Ce):{}]).then(function(Ue){var Qe=Ue[0],it=Ue[1],xt=Ue[2],wt=dZ.all([Qe,it,xt],{arrayMerge:zpt});return wt})},[f.validate,f.validationSchema,R,x,E]),D=pg(function(Ce){return Ce===void 0&&(Ce=C.values),P({type:"SET_ISVALIDATING",payload:!0}),M(Ce).then(function(Ue){return y.current&&(P({type:"SET_ISVALIDATING",payload:!1}),P({type:"SET_ERRORS",payload:Ue})),Ue})});J.useEffect(function(){a&&y.current===!0&&kO(h.current,f.initialValues)&&D(h.current)},[a,D]);var F=J.useCallback(function(Ce){var Ue=Ce&&Ce.values?Ce.values:h.current,Qe=Ce&&Ce.errors?Ce.errors:p.current?p.current:f.initialErrors||{},it=Ce&&Ce.touched?Ce.touched:g.current?g.current:f.initialTouched||{},xt=Ce&&Ce.status?Ce.status:v.current?v.current:f.initialStatus;h.current=Ue,p.current=Qe,g.current=it,v.current=xt;var wt=function(){P({type:"RESET_FORM",payload:{isSubmitting:!!Ce&&!!Ce.isSubmitting,errors:Qe,touched:it,status:xt,values:Ue,isValidating:!!Ce&&!!Ce.isValidating,submitCount:Ce&&Ce.submitCount&&typeof Ce.submitCount=="number"?Ce.submitCount:0}})};if(f.onReset){var $t=f.onReset(C.values,we);eY($t)?$t.then(wt):wt()}else wt()},[f.initialErrors,f.initialStatus,f.initialTouched,f.onReset]);J.useEffect(function(){y.current===!0&&!kO(h.current,f.initialValues)&&u&&(h.current=f.initialValues,F(),a&&D(h.current))},[u,f.initialValues,F,a,D]),J.useEffect(function(){u&&y.current===!0&&!kO(p.current,f.initialErrors)&&(p.current=f.initialErrors||mT,P({type:"SET_ERRORS",payload:f.initialErrors||mT}))},[u,f.initialErrors]),J.useEffect(function(){u&&y.current===!0&&!kO(g.current,f.initialTouched)&&(g.current=f.initialTouched||u4,P({type:"SET_TOUCHED",payload:f.initialTouched||u4}))},[u,f.initialTouched]),J.useEffect(function(){u&&y.current===!0&&!kO(v.current,f.initialStatus)&&(v.current=f.initialStatus,P({type:"SET_STATUS",payload:f.initialStatus}))},[u,f.initialStatus,f.initialTouched]);var I=pg(function(Ce){if(m.current[Ce]&&fv(m.current[Ce].validate)){var Ue=yp(C.values,Ce),Qe=m.current[Ce].validate(Ue);return eY(Qe)?(P({type:"SET_ISVALIDATING",payload:!0}),Qe.then(function(it){return it}).then(function(it){P({type:"SET_FIELD_ERROR",payload:{field:Ce,value:it}}),P({type:"SET_ISVALIDATING",payload:!1})})):(P({type:"SET_FIELD_ERROR",payload:{field:Ce,value:Qe}}),Promise.resolve(Qe))}else if(f.validationSchema)return P({type:"SET_ISVALIDATING",payload:!0}),E(C.values,Ce).then(function(it){return it}).then(function(it){P({type:"SET_FIELD_ERROR",payload:{field:Ce,value:yp(it,Ce)}}),P({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),V=J.useCallback(function(Ce,Ue){var Qe=Ue.validate;m.current[Ce]={validate:Qe}},[]),z=J.useCallback(function(Ce){delete m.current[Ce]},[]),G=pg(function(Ce,Ue){P({type:"SET_TOUCHED",payload:Ce});var Qe=Ue===void 0?r:Ue;return Qe?D(C.values):Promise.resolve()}),H=J.useCallback(function(Ce){P({type:"SET_ERRORS",payload:Ce})},[]),U=pg(function(Ce,Ue){var Qe=fv(Ce)?Ce(C.values):Ce;P({type:"SET_VALUES",payload:Qe});var it=Ue===void 0?i:Ue;return it?D(Qe):Promise.resolve()}),k=J.useCallback(function(Ce,Ue){P({type:"SET_FIELD_ERROR",payload:{field:Ce,value:Ue}})},[]),X=pg(function(Ce,Ue,Qe){P({type:"SET_FIELD_VALUE",payload:{field:Ce,value:Ue}});var it=Qe===void 0?i:Qe;return it?D(lD(C.values,Ce,Ue)):Promise.resolve()}),W=J.useCallback(function(Ce,Ue){var Qe=Ue,it=Ce,xt;if(!Q8(Ce)){Ce.persist&&Ce.persist();var wt=Ce.target?Ce.target:Ce.currentTarget,$t=wt.type,Mt=wt.name,rt=wt.id,qe=wt.value,vt=wt.checked;wt.outerHTML;var kt=wt.options,Xe=wt.multiple;Qe=Ue||Mt||rt,it=/number|range/.test($t)?(xt=parseFloat(qe),isNaN(xt)?"":xt):/checkbox/.test($t)?Wpt(yp(C.values,Qe),vt,qe):kt&&Xe?$pt(kt):qe}Qe&&X(Qe,it)},[X,C.values]),Y=pg(function(Ce){if(Q8(Ce))return function(Ue){return W(Ue,Ce)};W(Ce)}),te=pg(function(Ce,Ue,Qe){Ue===void 0&&(Ue=!0),P({type:"SET_FIELD_TOUCHED",payload:{field:Ce,value:Ue}});var it=Qe===void 0?r:Qe;return it?D(C.values):Promise.resolve()}),oe=J.useCallback(function(Ce,Ue){Ce.persist&&Ce.persist();var Qe=Ce.target,it=Qe.name,xt=Qe.id;Qe.outerHTML;var wt=Ue||it||xt;te(wt,!0)},[te]),de=pg(function(Ce){if(Q8(Ce))return function(Ue){return oe(Ue,Ce)};oe(Ce)}),ge=J.useCallback(function(Ce){fv(Ce)?P({type:"SET_FORMIK_STATE",payload:Ce}):P({type:"SET_FORMIK_STATE",payload:function(){return Ce}})},[]),Ee=J.useCallback(function(Ce){P({type:"SET_STATUS",payload:Ce})},[]),Re=J.useCallback(function(Ce){P({type:"SET_ISSUBMITTING",payload:Ce})},[]),Ae=pg(function(){return P({type:"SUBMIT_ATTEMPT"}),D().then(function(Ce){var Ue=Ce instanceof Error,Qe=!Ue&&Object.keys(Ce).length===0;if(Qe){var it;try{if(it=Te(),it===void 0)return}catch(xt){throw xt}return Promise.resolve(it).then(function(xt){return y.current&&P({type:"SUBMIT_SUCCESS"}),xt}).catch(function(xt){if(y.current)throw P({type:"SUBMIT_FAILURE"}),xt})}else if(y.current&&(P({type:"SUBMIT_FAILURE"}),Ue))throw Ce})}),Pe=pg(function(Ce){Ce&&Ce.preventDefault&&fv(Ce.preventDefault)&&Ce.preventDefault(),Ce&&Ce.stopPropagation&&fv(Ce.stopPropagation)&&Ce.stopPropagation(),Ae().catch(function(Ue){console.warn("Warning: An unhandled error was caught from submitForm()",Ue)})}),we={resetForm:F,validateForm:D,validateField:I,setErrors:H,setFieldError:k,setFieldTouched:te,setFieldValue:X,setStatus:Ee,setSubmitting:Re,setTouched:G,setValues:U,setFormikState:ge,submitForm:Ae},Te=pg(function(){return c(C.values,we)}),ke=pg(function(Ce){Ce&&Ce.preventDefault&&fv(Ce.preventDefault)&&Ce.preventDefault(),Ce&&Ce.stopPropagation&&fv(Ce.stopPropagation)&&Ce.stopPropagation(),F()}),$e=J.useCallback(function(Ce){return{value:yp(C.values,Ce),error:yp(C.errors,Ce),touched:!!yp(C.touched,Ce),initialValue:yp(h.current,Ce),initialTouched:!!yp(g.current,Ce),initialError:yp(p.current,Ce)}},[C.errors,C.touched,C.values]),Ne=J.useCallback(function(Ce){return{setValue:function(Qe,it){return X(Ce,Qe,it)},setTouched:function(Qe,it){return te(Ce,Qe,it)},setError:function(Qe){return k(Ce,Qe)}}},[X,te,k]),ve=J.useCallback(function(Ce){var Ue=R6(Ce),Qe=Ue?Ce.name:Ce,it=yp(C.values,Qe),xt={name:Qe,value:it,onChange:Y,onBlur:de};if(Ue){var wt=Ce.type,$t=Ce.value,Mt=Ce.as,rt=Ce.multiple;wt==="checkbox"?$t===void 0?xt.checked=!!it:(xt.checked=!!(Array.isArray(it)&&~it.indexOf($t)),xt.value=$t):wt==="radio"?(xt.checked=it===$t,xt.value=$t):Mt==="select"&&rt&&(xt.value=xt.value||[],xt.multiple=!0)}return xt},[de,Y,C.values]),pe=J.useMemo(function(){return!kO(h.current,C.values)},[h.current,C.values]),fe=J.useMemo(function(){return typeof s<"u"?pe?C.errors&&Object.keys(C.errors).length===0:s!==!1&&fv(s)?s(f):s:C.errors&&Object.keys(C.errors).length===0},[s,pe,C.errors,f]),me=_c({},C,{initialValues:h.current,initialErrors:p.current,initialTouched:g.current,initialStatus:v.current,handleBlur:de,handleChange:Y,handleReset:ke,handleSubmit:Pe,resetForm:F,setErrors:H,setFormikState:ge,setFieldTouched:te,setFieldValue:X,setFieldError:k,setStatus:Ee,setSubmitting:Re,setTouched:G,setValues:U,submitForm:Ae,validateForm:D,validateField:I,isValid:fe,dirty:pe,unregisterField:z,registerField:V,getFieldProps:ve,getFieldMeta:$e,getFieldHelpers:Ne,validateOnBlur:r,validateOnChange:i,validateOnMount:a});return me}function Hpt(t){var e={};if(t.inner){if(t.inner.length===0)return lD(e,t.path,t.message);for(var r=t.inner,i=Array.isArray(r),n=0,r=i?r:r[Symbol.iterator]();;){var o;if(i){if(n>=r.length)break;o=r[n++]}else{if(n=r.next(),n.done)break;o=n.value}var a=o;yp(e,a.path)||(e=lD(e,a.path,a.message))}}return e}function Upt(t,e,i,n){i===void 0&&(i=!1);var r=vZ(t);return e[i?"validateSync":"validate"](r,{abortEarly:!1,context:r})}function vZ(t){var e=Array.isArray(t)?[]:{};for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)){var n=String(i);Array.isArray(t[n])===!0?e[n]=t[n].map(function(r){return Array.isArray(r)===!0||Gle(r)?vZ(r):r!==""?r:void 0}):Gle(t[n])?e[n]=vZ(t[n]):e[n]=t[n]!==""?t[n]:void 0}return e}function zpt(t,e,i){var n=t.slice();return e.forEach(function(o,a){if(typeof n[a]>"u"){var s=i.clone!==!1,l=s&&i.isMergeableObject(o);n[a]=l?dZ(Array.isArray(o)?[]:{},o,i):o}else i.isMergeableObject(o)?n[a]=dZ(t[a],o,i):t.indexOf(o)===-1&&n.push(o)}),n}function $pt(t){return Array.from(t).filter(function(e){return e.selected}).map(function(e){return e.value})}function Wpt(t,e,i){if(typeof t=="boolean")return!!e;var n=[],r=!1,o=-1;if(Array.isArray(t))n=t,o=t.indexOf(i),r=o>=0;else if(!i||i=="true"||i=="false")return!!e;return e&&i&&!r?n.concat(i):r?n.slice(0,o).concat(n.slice(o+1)):n}var Gpt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?J.useLayoutEffect:J.useEffect;function pg(t){var e=J.useRef(t);return Gpt(function(){e.current=t}),J.useCallback(function(){for(var i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];return e.current.apply(void 0,n)},[])}var Ypt=J.forwardRef(function(t,e){var i=t.action,n=ULe(t,["action"]),r=i??"#",o=Fpt(),a=o.handleReset,s=o.handleSubmit;return J.createElement("form",_c({onSubmit:s,ref:e,onReset:a,action:r},n))});Ypt.displayName="Form";var tY,mue;function qpt(){if(mue)return tY;mue=1;function t(y){this._maxSize=y,this.clear()}t.prototype.clear=function(){this._size=0,this._values=Object.create(null)},t.prototype.get=function(y){return this._values[y]},t.prototype.set=function(y,m){return this._size>=this._maxSize&&this.clear(),y in this._values||this._size++,this._values[y]=m};var e=/[^.^\]^[]+|(?=\[\]|\.\.)/g,i=/^\d+$/,n=/^\d/,r=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,o=/^\s*(['"]?)(.*?)(\1)\s*$/,a=512,s=new t(a),l=new t(a),u=new t(a);tY={Cache:t,split:d,normalizePath:c,setter:function(y){var m=c(y);return l.get(y)||l.set(y,function(S,_){for(var C=0,P=m.length,x=S;C<P-1;){var E=m[C];if(E==="__proto__"||E==="constructor"||E==="prototype")return S;x=x[m[C++]]}x[m[C]]=_})},getter:function(y,m){var b=c(y);return u.get(y)||u.set(y,function(_){for(var C=0,P=b.length;C<P;)if(_!=null||!m)_=_[b[C++]];else return;return _})},join:function(y){return y.reduce(function(m,b){return m+(h(b)||i.test(b)?"["+b+"]":(m?".":"")+b)},"")},forEach:function(y,m,b){f(Array.isArray(y)?y:d(y),m,b)}};function c(y){return s.get(y)||s.set(y,d(y).map(function(m){return m.replace(o,"$2")}))}function d(y){return y.match(e)||[""]}function f(y,m,b){var S=y.length,_,C,P,x;for(C=0;C<S;C++)_=y[C],_&&(v(_)&&(_='"'+_+'"'),x=h(_),P=!x&&/^\d+$/.test(_),m.call(b,_,x,P,C,y))}function h(y){return typeof y=="string"&&y&&["'",'"'].indexOf(y.charAt(0))!==-1}function p(y){return y.match(n)&&!y.match(i)}function g(y){return r.test(y)}function v(y){return!h(y)&&(p(y)||g(y))}return tY}var uD=qpt(),rY,bue;function Xpt(){if(bue)return rY;bue=1;const t=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,e=c=>c.match(t)||[],i=c=>c[0].toUpperCase()+c.slice(1),n=(c,d)=>e(c).join(d).toLowerCase(),r=c=>e(c).reduce((d,f)=>`${d}${d?f[0].toUpperCase()+f.slice(1).toLowerCase():f.toLowerCase()}`,"");return rY={words:e,upperFirst:i,camelCase:r,pascalCase:c=>i(r(c)),snakeCase:c=>n(c,"_"),kebabCase:c=>n(c,"-"),sentenceCase:c=>i(n(c," ")),titleCase:c=>e(c).map(i).join(" ")},rY}var iY=Xpt(),c4={exports:{}},Sue;function Kpt(){if(Sue)return c4.exports;Sue=1,c4.exports=function(r){return t(e(r),r)},c4.exports.array=t;function t(r,o){var a=r.length,s=new Array(a),l={},u=a,c=i(o),d=n(r);for(o.forEach(function(h){if(!d.has(h[0])||!d.has(h[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});u--;)l[u]||f(r[u],u,new Set);return s;function f(h,p,g){if(g.has(h)){var v;try{v=", node was:"+JSON.stringify(h)}catch{v=""}throw new Error("Cyclic dependency"+v)}if(!d.has(h))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(h));if(!l[p]){l[p]=!0;var y=c.get(h)||new Set;if(y=Array.from(y),p=y.length){g.add(h);do{var m=y[--p];f(m,d.get(m),g)}while(p);g.delete(h)}s[--a]=h}}}function e(r){for(var o=new Set,a=0,s=r.length;a<s;a++){var l=r[a];o.add(l[0]),o.add(l[1])}return Array.from(o)}function i(r){for(var o=new Map,a=0,s=r.length;a<s;a++){var l=r[a];o.has(l[0])||o.set(l[0],new Set),o.has(l[1])||o.set(l[1],new Set),o.get(l[0]).add(l[1])}return o}function n(r){for(var o=new Map,a=0,s=r.length;a<s;a++)o.set(r[a],a);return o}return c4.exports}var Zpt=Kpt();const Jpt=wc(Zpt),Qpt=Object.prototype.toString,egt=Error.prototype.toString,tgt=RegExp.prototype.toString,rgt=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",igt=/^Symbol\((.*)\)(.*)$/;function ngt(t){return t!=+t?"NaN":t===0&&1/t<0?"-0":""+t}function _ue(t,e=!1){if(t==null||t===!0||t===!1)return""+t;const i=typeof t;if(i==="number")return ngt(t);if(i==="string")return e?`"${t}"`:t;if(i==="function")return"[Function "+(t.name||"anonymous")+"]";if(i==="symbol")return rgt.call(t).replace(igt,"Symbol($1)");const n=Qpt.call(t).slice(8,-1);return n==="Date"?isNaN(t.getTime())?""+t:t.toISOString(t):n==="Error"||t instanceof Error?"["+egt.call(t)+"]":n==="RegExp"?tgt.call(t):null}function vP(t,e){let i=_ue(t,e);return i!==null?i:JSON.stringify(t,function(n,r){let o=_ue(this[n],e);return o!==null?o:r},2)}function $Le(t){return t==null?[]:[].concat(t)}let WLe,GLe,YLe,ogt=/\$\{\s*(\w+)\s*\}/g;WLe=Symbol.toStringTag;class Pue{constructor(e,i,n,r){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[WLe]="Error",this.name="ValidationError",this.value=i,this.path=n,this.type=r,this.errors=[],this.inner=[],$Le(e).forEach(o=>{if(Of.isError(o)){this.errors.push(...o.errors);const a=o.inner.length?o.inner:[o];this.inner.push(...a)}else this.errors.push(o)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}GLe=Symbol.hasInstance;YLe=Symbol.toStringTag;class Of extends Error{static formatError(e,i){const n=i.label||i.path||"this";return i=Object.assign({},i,{path:n,originalPath:i.path}),typeof e=="string"?e.replace(ogt,(r,o)=>vP(i[o])):typeof e=="function"?e(i):e}static isError(e){return e&&e.name==="ValidationError"}constructor(e,i,n,r,o){const a=new Pue(e,i,n,r);if(o)return a;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[YLe]="Error",this.name=a.name,this.message=a.message,this.type=a.type,this.value=a.value,this.path=a.path,this.errors=a.errors,this.inner=a.inner,Error.captureStackTrace&&Error.captureStackTrace(this,Of)}static[GLe](e){return Pue[Symbol.hasInstance](e)||super[Symbol.hasInstance](e)}}let My={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:t,type:e,value:i,originalValue:n})=>{const r=n!=null&&n!==i?` (cast from the value \`${vP(n,!0)}\`).`:".";return e!=="mixed"?`${t} must be a \`${e}\` type, but the final value was: \`${vP(i,!0)}\``+r:`${t} must match the configured type. The validated value was: \`${vP(i,!0)}\``+r}},_h={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},agt={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},yZ={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},sgt={isValue:"${path} field must be ${value}"},$U={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},lgt={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},ugt={notType:t=>{const{path:e,value:i,spec:n}=t,r=n.types.length;if(Array.isArray(i)){if(i.length<r)return`${e} tuple value has too few items, expected a length of ${r} but got ${i.length} for value: \`${vP(i,!0)}\``;if(i.length>r)return`${e} tuple value has too many items, expected a length of ${r} but got ${i.length} for value: \`${vP(i,!0)}\``}return Of.formatError(My.notType,t)}};Object.assign(Object.create(null),{mixed:My,string:_h,number:agt,date:yZ,object:$U,array:lgt,boolean:sgt,tuple:ugt});const ite=t=>t&&t.__isYupSchema__;class dz{static fromOptions(e,i){if(!i.then&&!i.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:n,then:r,otherwise:o}=i,a=typeof n=="function"?n:(...s)=>s.every(l=>l===n);return new dz(e,(s,l)=>{var u;let c=a(...s)?r:o;return(u=c==null?void 0:c(l))!=null?u:l})}constructor(e,i){this.fn=void 0,this.refs=e,this.refs=e,this.fn=i}resolve(e,i){let n=this.refs.map(o=>o.getValue(i==null?void 0:i.value,i==null?void 0:i.parent,i==null?void 0:i.context)),r=this.fn(n,e,i);if(r===void 0||r===e)return e;if(!ite(r))throw new TypeError("conditions must return a schema object");return r.resolve(i)}}const d4={context:"$",value:"."};class YD{constructor(e,i={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof e!="string")throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),e==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===d4.context,this.isValue=this.key[0]===d4.value,this.isSibling=!this.isContext&&!this.isValue;let n=this.isContext?d4.context:this.isValue?d4.value:"";this.path=this.key.slice(n.length),this.getter=this.path&&uD.getter(this.path,!0),this.map=i.map}getValue(e,i,n){let r=this.isContext?n:this.isValue?e:i;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}cast(e,i){return this.getValue(e,i==null?void 0:i.parent,i==null?void 0:i.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(e){return e&&e.__isYupRef}}YD.prototype.__isYupRef=!0;const $O=t=>t==null;function JM(t){function e({value:i,path:n="",options:r,originalValue:o,schema:a},s,l){const{name:u,test:c,params:d,message:f,skipAbsent:h}=t;let{parent:p,context:g,abortEarly:v=a.spec.abortEarly,disableStackTrace:y=a.spec.disableStackTrace}=r;const m={value:i,parent:p,context:g};function b(R={}){const M=qLe(Object.assign({value:i,originalValue:o,label:a.spec.label,path:R.path||n,spec:a.spec,disableStackTrace:R.disableStackTrace||y},d,R.params),m),D=new Of(Of.formatError(R.message||f,M),i,M.path,R.type||u,M.disableStackTrace);return D.params=M,D}const S=v?s:l;let _={path:n,parent:p,type:u,from:r.from,createError:b,resolve(R){return XLe(R,m)},options:r,originalValue:o,schema:a};const C=R=>{Of.isError(R)?S(R):R?l(null):S(b())},P=R=>{Of.isError(R)?S(R):s(R)};if(h&&$O(i))return C(!0);let E;try{var A;if(E=c.call(_,i,_),typeof((A=E)==null?void 0:A.then)=="function"){if(r.sync)throw new Error(`Validation test of type: "${_.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(E).then(C,P)}}catch(R){P(R);return}C(E)}return e.OPTIONS=t,e}function qLe(t,e){if(!t)return t;for(const i of Object.keys(t))t[i]=XLe(t[i],e);return t}function XLe(t,e){return YD.isRef(t)?t.getValue(e.value,e.parent,e.context):t}function cgt(t,e,i,n=i){let r,o,a;return e?(uD.forEach(e,(s,l,u)=>{let c=l?s.slice(1,s.length-1):s;t=t.resolve({context:n,parent:r,value:i});let d=t.type==="tuple",f=u?parseInt(c,10):0;if(t.innerType||d){if(d&&!u)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${a}" must contain an index to the tuple element, e.g. "${a}[0]"`);if(i&&f>=i.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${s}, in the path: ${e}. because there is no value at that index. `);r=i,i=i&&i[f],t=d?t.spec.types[f]:t.innerType}if(!u){if(!t.fields||!t.fields[c])throw new Error(`The schema does not contain the path: ${e}. (failed at: ${a} which is a type: "${t.type}")`);r=i,i=i&&i[c],t=t.fields[c]}o=c,a=l?"["+s+"]":"."+s}),{schema:t,parent:r,parentPath:o}):{parent:r,parentPath:e,schema:t}}class fz extends Set{describe(){const e=[];for(const i of this.values())e.push(YD.isRef(i)?i.describe():i);return e}resolveAll(e){let i=[];for(const n of this.values())i.push(e(n));return i}clone(){return new fz(this.values())}merge(e,i){const n=this.clone();return e.forEach(r=>n.add(r)),i.forEach(r=>n.delete(r)),n}}function CL(t,e=new Map){if(ite(t)||!t||typeof t!="object")return t;if(e.has(t))return e.get(t);let i;if(t instanceof Date)i=new Date(t.getTime()),e.set(t,i);else if(t instanceof RegExp)i=new RegExp(t),e.set(t,i);else if(Array.isArray(t)){i=new Array(t.length),e.set(t,i);for(let n=0;n<t.length;n++)i[n]=CL(t[n],e)}else if(t instanceof Map){i=new Map,e.set(t,i);for(const[n,r]of t.entries())i.set(n,CL(r,e))}else if(t instanceof Set){i=new Set,e.set(t,i);for(const n of t)i.add(CL(n,e))}else if(t instanceof Object){i={},e.set(t,i);for(const[n,r]of Object.entries(t))i[n]=CL(r,e)}else throw Error(`Unable to clone ${t}`);return i}function dgt(t){if(!(t!=null&&t.length))return;const e=[];let i="",n=!1,r=!1;for(let o=0;o<t.length;o++){const a=t[o];if(a==="["&&!r){i&&(e.push(...i.split(".").filter(Boolean)),i=""),n=!0;continue}if(a==="]"&&!r){i&&(/^\d+$/.test(i)?e.push(i):e.push(i.replace(/^"|"$/g,"")),i=""),n=!1;continue}if(a==='"'){r=!r;continue}if(a==="."&&!n&&!r){i&&(e.push(i),i="");continue}i+=a}return i&&e.push(...i.split(".").filter(Boolean)),e}function fgt(t,e){const i=e?`${e}.${t.path}`:t.path;return t.errors.map(n=>({message:n,path:dgt(i)}))}function KLe(t,e){var i;if(!((i=t.inner)!=null&&i.length)&&t.errors.length)return fgt(t,e);const n=e?`${e}.${t.path}`:t.path;return t.inner.flatMap(r=>KLe(r,n))}let fm=class{constructor(e){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new fz,this._blacklist=new fz,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(My.notType)}),this.type=e.type,this._typeCheck=e.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},e==null?void 0:e.spec),this.withMutation(i=>{i.nonNullable()})}get _type(){return this.type}clone(e){if(this._mutate)return e&&Object.assign(this.spec,e),this;const i=Object.create(Object.getPrototypeOf(this));return i.type=this.type,i._typeCheck=this._typeCheck,i._whitelist=this._whitelist.clone(),i._blacklist=this._blacklist.clone(),i.internalTests=Object.assign({},this.internalTests),i.exclusiveTests=Object.assign({},this.exclusiveTests),i.deps=[...this.deps],i.conditions=[...this.conditions],i.tests=[...this.tests],i.transforms=[...this.transforms],i.spec=CL(Object.assign({},this.spec,e)),i}label(e){let i=this.clone();return i.spec.label=e,i}meta(...e){if(e.length===0)return this.spec.meta;let i=this.clone();return i.spec.meta=Object.assign(i.spec.meta||{},e[0]),i}withMutation(e){let i=this._mutate;this._mutate=!0;let n=e(this);return this._mutate=i,n}concat(e){if(!e||e===this)return this;if(e.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${e.type}`);let i=this,n=e.clone();const r=Object.assign({},i.spec,n.spec);return n.spec=r,n.internalTests=Object.assign({},i.internalTests,n.internalTests),n._whitelist=i._whitelist.merge(e._whitelist,e._blacklist),n._blacklist=i._blacklist.merge(e._blacklist,e._whitelist),n.tests=i.tests,n.exclusiveTests=i.exclusiveTests,n.withMutation(o=>{e.tests.forEach(a=>{o.test(a.OPTIONS)})}),n.transforms=[...i.transforms,...n.transforms],n}isType(e){return e==null?!!(this.spec.nullable&&e===null||this.spec.optional&&e===void 0):this._typeCheck(e)}resolve(e){let i=this;if(i.conditions.length){let n=i.conditions;i=i.clone(),i.conditions=[],i=n.reduce((r,o)=>o.resolve(r,e),i),i=i.resolve(e)}return i}resolveOptions(e){var i,n,r,o;return Object.assign({},e,{from:e.from||[],strict:(i=e.strict)!=null?i:this.spec.strict,abortEarly:(n=e.abortEarly)!=null?n:this.spec.abortEarly,recursive:(r=e.recursive)!=null?r:this.spec.recursive,disableStackTrace:(o=e.disableStackTrace)!=null?o:this.spec.disableStackTrace})}cast(e,i={}){let n=this.resolve(Object.assign({},i,{value:e})),r=i.assert==="ignore-optionality",o=n._cast(e,i);if(i.assert!==!1&&!n.isType(o)){if(r&&$O(o))return o;let a=vP(e),s=vP(o);throw new TypeError(`The value of ${i.path||"field"} could not be cast to a value that satisfies the schema type: "${n.type}". 

attempted value: ${a} 
`+(s!==a?`result of cast: ${s}`:""))}return o}_cast(e,i){let n=e===void 0?e:this.transforms.reduce((r,o)=>o.call(this,r,e,this,i),e);return n===void 0&&(n=this.getDefault(i)),n}_validate(e,i={},n,r){let{path:o,originalValue:a=e,strict:s=this.spec.strict}=i,l=e;s||(l=this._cast(l,Object.assign({assert:!1},i)));let u=[];for(let c of Object.values(this.internalTests))c&&u.push(c);this.runTests({path:o,value:l,originalValue:a,options:i,tests:u},n,c=>{if(c.length)return r(c,l);this.runTests({path:o,value:l,originalValue:a,options:i,tests:this.tests},n,r)})}runTests(e,i,n){let r=!1,{tests:o,value:a,originalValue:s,path:l,options:u}=e,c=g=>{r||(r=!0,i(g,a))},d=g=>{r||(r=!0,n(g,a))},f=o.length,h=[];if(!f)return d([]);let p={value:a,originalValue:s,path:l,options:u,schema:this};for(let g=0;g<o.length;g++){const v=o[g];v(p,c,function(m){m&&(Array.isArray(m)?h.push(...m):h.push(m)),--f<=0&&d(h)})}}asNestedTest({key:e,index:i,parent:n,parentPath:r,originalParent:o,options:a}){const s=e??i;if(s==null)throw TypeError("Must include `key` or `index` for nested validations");const l=typeof s=="number";let u=n[s];const c=Object.assign({},a,{strict:!0,parent:n,value:u,originalValue:o[s],key:void 0,[l?"index":"key"]:s,path:l||s.includes(".")?`${r||""}[${l?s:`"${s}"`}]`:(r?`${r}.`:"")+e});return(d,f,h)=>this.resolve(c)._validate(u,c,f,h)}validate(e,i){var n;let r=this.resolve(Object.assign({},i,{value:e})),o=(n=i==null?void 0:i.disableStackTrace)!=null?n:r.spec.disableStackTrace;return new Promise((a,s)=>r._validate(e,i,(l,u)=>{Of.isError(l)&&(l.value=u),s(l)},(l,u)=>{l.length?s(new Of(l,u,void 0,void 0,o)):a(u)}))}validateSync(e,i){var n;let r=this.resolve(Object.assign({},i,{value:e})),o,a=(n=i==null?void 0:i.disableStackTrace)!=null?n:r.spec.disableStackTrace;return r._validate(e,Object.assign({},i,{sync:!0}),(s,l)=>{throw Of.isError(s)&&(s.value=l),s},(s,l)=>{if(s.length)throw new Of(s,e,void 0,void 0,a);o=l}),o}isValid(e,i){return this.validate(e,i).then(()=>!0,n=>{if(Of.isError(n))return!1;throw n})}isValidSync(e,i){try{return this.validateSync(e,i),!0}catch(n){if(Of.isError(n))return!1;throw n}}_getDefault(e){let i=this.spec.default;return i==null?i:typeof i=="function"?i.call(this,e):CL(i)}getDefault(e){return this.resolve(e||{})._getDefault(e)}default(e){return arguments.length===0?this._getDefault():this.clone({default:e})}strict(e=!0){return this.clone({strict:e})}nullability(e,i){const n=this.clone({nullable:e});return n.internalTests.nullable=JM({message:i,name:"nullable",test(r){return r===null?this.schema.spec.nullable:!0}}),n}optionality(e,i){const n=this.clone({optional:e});return n.internalTests.optionality=JM({message:i,name:"optionality",test(r){return r===void 0?this.schema.spec.optional:!0}}),n}optional(){return this.optionality(!0)}defined(e=My.defined){return this.optionality(!1,e)}nullable(){return this.nullability(!0)}nonNullable(e=My.notNull){return this.nullability(!1,e)}required(e=My.required){return this.clone().withMutation(i=>i.nonNullable(e).defined(e))}notRequired(){return this.clone().withMutation(e=>e.nullable().optional())}transform(e){let i=this.clone();return i.transforms.push(e),i}test(...e){let i;if(e.length===1?typeof e[0]=="function"?i={test:e[0]}:i=e[0]:e.length===2?i={name:e[0],test:e[1]}:i={name:e[0],message:e[1],test:e[2]},i.message===void 0&&(i.message=My.default),typeof i.test!="function")throw new TypeError("`test` is a required parameters");let n=this.clone(),r=JM(i),o=i.exclusive||i.name&&n.exclusiveTests[i.name]===!0;if(i.exclusive&&!i.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return i.name&&(n.exclusiveTests[i.name]=!!i.exclusive),n.tests=n.tests.filter(a=>!(a.OPTIONS.name===i.name&&(o||a.OPTIONS.test===r.OPTIONS.test))),n.tests.push(r),n}when(e,i){!Array.isArray(e)&&typeof e!="string"&&(i=e,e=".");let n=this.clone(),r=$Le(e).map(o=>new YD(o));return r.forEach(o=>{o.isSibling&&n.deps.push(o.key)}),n.conditions.push(typeof i=="function"?new dz(r,i):dz.fromOptions(r,i)),n}typeError(e){let i=this.clone();return i.internalTests.typeError=JM({message:e,name:"typeError",skipAbsent:!0,test(n){return this.schema._typeCheck(n)?!0:this.createError({params:{type:this.schema.type}})}}),i}oneOf(e,i=My.oneOf){let n=this.clone();return e.forEach(r=>{n._whitelist.add(r),n._blacklist.delete(r)}),n.internalTests.whiteList=JM({message:i,name:"oneOf",skipAbsent:!0,test(r){let o=this.schema._whitelist,a=o.resolveAll(this.resolve);return a.includes(r)?!0:this.createError({params:{values:Array.from(o).join(", "),resolved:a}})}}),n}notOneOf(e,i=My.notOneOf){let n=this.clone();return e.forEach(r=>{n._blacklist.add(r),n._whitelist.delete(r)}),n.internalTests.blacklist=JM({message:i,name:"notOneOf",test(r){let o=this.schema._blacklist,a=o.resolveAll(this.resolve);return a.includes(r)?this.createError({params:{values:Array.from(o).join(", "),resolved:a}}):!0}}),n}strip(e=!0){let i=this.clone();return i.spec.strip=e,i}describe(e){const i=(e?this.resolve(e):this).clone(),{label:n,meta:r,optional:o,nullable:a}=i.spec;return{meta:r,label:n,optional:o,nullable:a,default:i.getDefault(e),type:i.type,oneOf:i._whitelist.describe(),notOneOf:i._blacklist.describe(),tests:i.tests.filter((l,u,c)=>c.findIndex(d=>d.OPTIONS.name===l.OPTIONS.name)===u).map(l=>{const u=l.OPTIONS.params&&e?qLe(Object.assign({},l.OPTIONS.params),e):l.OPTIONS.params;return{name:l.OPTIONS.name,params:u}})}}get"~standard"(){const e=this;return{version:1,vendor:"yup",async validate(n){try{return{value:await e.validate(n,{abortEarly:!1})}}catch(r){if(r instanceof Of)return{issues:KLe(r)};throw r}}}}};fm.prototype.__isYupSchema__=!0;for(const t of["validate","validateSync"])fm.prototype[`${t}At`]=function(e,i,n={}){const{parent:r,parentPath:o,schema:a}=cgt(this,e,i,n.context);return a[t](r&&r[o],Object.assign({},n,{parent:r,path:e}))};for(const t of["equals","is"])fm.prototype[t]=fm.prototype.oneOf;for(const t of["not","nope"])fm.prototype[t]=fm.prototype.notOneOf;const hgt=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function pgt(t){const e=mZ(t);if(!e)return Date.parse?Date.parse(t):Number.NaN;if(e.z===void 0&&e.plusMinus===void 0)return new Date(e.year,e.month,e.day,e.hour,e.minute,e.second,e.millisecond).valueOf();let i=0;return e.z!=="Z"&&e.plusMinus!==void 0&&(i=e.hourOffset*60+e.minuteOffset,e.plusMinus==="+"&&(i=0-i)),Date.UTC(e.year,e.month,e.day,e.hour,e.minute+i,e.second,e.millisecond)}function mZ(t){var e,i;const n=hgt.exec(t);return n?{year:A0(n[1]),month:A0(n[2],1)-1,day:A0(n[3],1),hour:A0(n[4]),minute:A0(n[5]),second:A0(n[6]),millisecond:n[7]?A0(n[7].substring(0,3)):0,precision:(e=(i=n[7])==null?void 0:i.length)!=null?e:void 0,z:n[8]||void 0,plusMinus:n[9]||void 0,hourOffset:A0(n[10]),minuteOffset:A0(n[11])}:null}function A0(t,e=0){return Number(t)||e}let ggt=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,vgt=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,ygt=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,mgt="^\\d{4}-\\d{2}-\\d{2}",bgt="\\d{2}:\\d{2}:\\d{2}",Sgt="(([+-]\\d{2}(:?\\d{2})?)|Z)",_gt=new RegExp(`${mgt}T${bgt}(\\.\\d+)?${Sgt}$`),Pgt=t=>$O(t)||t===t.trim(),Cgt={}.toString();function bZ(){return new ZLe}class ZLe extends fm{constructor(){super({type:"string",check(e){return e instanceof String&&(e=e.valueOf()),typeof e=="string"}}),this.withMutation(()=>{this.transform((e,i)=>{if(!this.spec.coerce||this.isType(e)||Array.isArray(e))return e;const n=e!=null&&e.toString?e.toString():e;return n===Cgt?e:n})})}required(e){return super.required(e).withMutation(i=>i.test({message:e||My.required,name:"required",skipAbsent:!0,test:n=>!!n.length}))}notRequired(){return super.notRequired().withMutation(e=>(e.tests=e.tests.filter(i=>i.OPTIONS.name!=="required"),e))}length(e,i=_h.length){return this.test({message:i,name:"length",exclusive:!0,params:{length:e},skipAbsent:!0,test(n){return n.length===this.resolve(e)}})}min(e,i=_h.min){return this.test({message:i,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(n){return n.length>=this.resolve(e)}})}max(e,i=_h.max){return this.test({name:"max",exclusive:!0,message:i,params:{max:e},skipAbsent:!0,test(n){return n.length<=this.resolve(e)}})}matches(e,i){let n=!1,r,o;return i&&(typeof i=="object"?{excludeEmptyString:n=!1,message:r,name:o}=i:r=i),this.test({name:o||"matches",message:r||_h.matches,params:{regex:e},skipAbsent:!0,test:a=>a===""&&n||a.search(e)!==-1})}email(e=_h.email){return this.matches(ggt,{name:"email",message:e,excludeEmptyString:!0})}url(e=_h.url){return this.matches(vgt,{name:"url",message:e,excludeEmptyString:!0})}uuid(e=_h.uuid){return this.matches(ygt,{name:"uuid",message:e,excludeEmptyString:!1})}datetime(e){let i="",n,r;return e&&(typeof e=="object"?{message:i="",allowOffset:n=!1,precision:r=void 0}=e:i=e),this.matches(_gt,{name:"datetime",message:i||_h.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:i||_h.datetime_offset,params:{allowOffset:n},skipAbsent:!0,test:o=>{if(!o||n)return!0;const a=mZ(o);return a?!!a.z:!1}}).test({name:"datetime_precision",message:i||_h.datetime_precision,params:{precision:r},skipAbsent:!0,test:o=>{if(!o||r==null)return!0;const a=mZ(o);return a?a.precision===r:!1}})}ensure(){return this.default("").transform(e=>e===null?"":e)}trim(e=_h.trim){return this.transform(i=>i!=null?i.trim():i).test({message:e,name:"trim",test:Pgt})}lowercase(e=_h.lowercase){return this.transform(i=>$O(i)?i:i.toLowerCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:i=>$O(i)||i===i.toLowerCase()})}uppercase(e=_h.uppercase){return this.transform(i=>$O(i)?i:i.toUpperCase()).test({message:e,name:"string_case",exclusive:!0,skipAbsent:!0,test:i=>$O(i)||i===i.toUpperCase()})}}bZ.prototype=ZLe.prototype;let Tgt=new Date(""),xgt=t=>Object.prototype.toString.call(t)==="[object Date]";class nte extends fm{constructor(){super({type:"date",check(e){return xgt(e)&&!isNaN(e.getTime())}}),this.withMutation(()=>{this.transform((e,i)=>!this.spec.coerce||this.isType(e)||e===null?e:(e=pgt(e),isNaN(e)?nte.INVALID_DATE:new Date(e)))})}prepareParam(e,i){let n;if(YD.isRef(e))n=e;else{let r=this.cast(e);if(!this._typeCheck(r))throw new TypeError(`\`${i}\` must be a Date or a value that can be \`cast()\` to a Date`);n=r}return n}min(e,i=yZ.min){let n=this.prepareParam(e,"min");return this.test({message:i,name:"min",exclusive:!0,params:{min:e},skipAbsent:!0,test(r){return r>=this.resolve(n)}})}max(e,i=yZ.max){let n=this.prepareParam(e,"max");return this.test({message:i,name:"max",exclusive:!0,params:{max:e},skipAbsent:!0,test(r){return r<=this.resolve(n)}})}}nte.INVALID_DATE=Tgt;function Egt(t,e=[]){let i=[],n=new Set,r=new Set(e.map(([a,s])=>`${a}-${s}`));function o(a,s){let l=uD.split(a)[0];n.add(l),r.has(`${s}-${l}`)||i.push([s,l])}for(const a of Object.keys(t)){let s=t[a];n.add(a),YD.isRef(s)&&s.isSibling?o(s.path,a):ite(s)&&"deps"in s&&s.deps.forEach(l=>o(l,a))}return Jpt.array(Array.from(n),i).reverse()}function Cue(t,e){let i=1/0;return t.some((n,r)=>{var o;if((o=e.path)!=null&&o.includes(n))return i=r,!0}),i}function JLe(t){return(e,i)=>Cue(t,e)-Cue(t,i)}const wgt=(t,e,i)=>{if(typeof t!="string")return t;let n=t;try{n=JSON.parse(t)}catch{}return i.isType(n)?n:t};function WU(t){if("fields"in t){const e={};for(const[i,n]of Object.entries(t.fields))e[i]=WU(n);return t.setFields(e)}if(t.type==="array"){const e=t.optional();return e.innerType&&(e.innerType=WU(e.innerType)),e}return t.type==="tuple"?t.optional().clone({types:t.spec.types.map(WU)}):"optional"in t?t.optional():t}const Agt=(t,e)=>{const i=[...uD.normalizePath(e)];if(i.length===1)return i[0]in t;let n=i.pop(),r=uD.getter(uD.join(i),!0)(t);return!!(r&&n in r)};let Tue=t=>Object.prototype.toString.call(t)==="[object Object]";function xue(t,e){let i=Object.keys(t.fields);return Object.keys(e).filter(n=>i.indexOf(n)===-1)}const Ogt=JLe([]);function QLe(t){return new eke(t)}class eke extends fm{constructor(e){super({type:"object",check(i){return Tue(i)||typeof i=="function"}}),this.fields=Object.create(null),this._sortErrors=Ogt,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{e&&this.shape(e)})}_cast(e,i={}){var n;let r=super._cast(e,i);if(r===void 0)return this.getDefault(i);if(!this._typeCheck(r))return r;let o=this.fields,a=(n=i.stripUnknown)!=null?n:this.spec.noUnknown,s=[].concat(this._nodes,Object.keys(r).filter(d=>!this._nodes.includes(d))),l={},u=Object.assign({},i,{parent:l,__validating:i.__validating||!1}),c=!1;for(const d of s){let f=o[d],h=d in r,p=r[d];if(f){let g;u.path=(i.path?`${i.path}.`:"")+d,f=f.resolve({value:p,context:i.context,parent:l});let v=f instanceof fm?f.spec:void 0,y=v==null?void 0:v.strict;if(v!=null&&v.strip){c=c||d in r;continue}g=!i.__validating||!y?f.cast(p,u):p,g!==void 0&&(l[d]=g)}else h&&!a&&(l[d]=p);(h!==d in l||l[d]!==p)&&(c=!0)}return c?l:r}_validate(e,i={},n,r){let{from:o=[],originalValue:a=e,recursive:s=this.spec.recursive}=i;i.from=[{schema:this,value:a},...o],i.__validating=!0,i.originalValue=a,super._validate(e,i,n,(l,u)=>{if(!s||!Tue(u)){r(l,u);return}a=a||u;let c=[];for(let d of this._nodes){let f=this.fields[d];!f||YD.isRef(f)||c.push(f.asNestedTest({options:i,key:d,parent:u,parentPath:i.path,originalParent:a}))}this.runTests({tests:c,value:u,originalValue:a,options:i},n,d=>{r(d.sort(this._sortErrors).concat(l),u)})})}clone(e){const i=super.clone(e);return i.fields=Object.assign({},this.fields),i._nodes=this._nodes,i._excludedEdges=this._excludedEdges,i._sortErrors=this._sortErrors,i}concat(e){let i=super.concat(e),n=i.fields;for(let[r,o]of Object.entries(this.fields)){const a=n[r];n[r]=a===void 0?o:a}return i.withMutation(r=>r.setFields(n,[...this._excludedEdges,...e._excludedEdges]))}_getDefault(e){if("default"in this.spec)return super._getDefault(e);if(!this._nodes.length)return;let i={};return this._nodes.forEach(n=>{var r;const o=this.fields[n];let a=e;(r=a)!=null&&r.value&&(a=Object.assign({},a,{parent:a.value,value:a.value[n]})),i[n]=o&&"getDefault"in o?o.getDefault(a):void 0}),i}setFields(e,i){let n=this.clone();return n.fields=e,n._nodes=Egt(e,i),n._sortErrors=JLe(Object.keys(e)),i&&(n._excludedEdges=i),n}shape(e,i=[]){return this.clone().withMutation(n=>{let r=n._excludedEdges;return i.length&&(Array.isArray(i[0])||(i=[i]),r=[...n._excludedEdges,...i]),n.setFields(Object.assign(n.fields,e),r)})}partial(){const e={};for(const[i,n]of Object.entries(this.fields))e[i]="optional"in n&&n.optional instanceof Function?n.optional():n;return this.setFields(e)}deepPartial(){return WU(this)}pick(e){const i={};for(const n of e)this.fields[n]&&(i[n]=this.fields[n]);return this.setFields(i,this._excludedEdges.filter(([n,r])=>e.includes(n)&&e.includes(r)))}omit(e){const i=[];for(const n of Object.keys(this.fields))e.includes(n)||i.push(n);return this.pick(i)}from(e,i,n){let r=uD.getter(e,!0);return this.transform(o=>{if(!o)return o;let a=o;return Agt(o,e)&&(a=Object.assign({},o),n||delete a[e],a[i]=r(o)),a})}json(){return this.transform(wgt)}exact(e){return this.test({name:"exact",exclusive:!0,message:e||$U.exact,test(i){if(i==null)return!0;const n=xue(this.schema,i);return n.length===0||this.createError({params:{properties:n.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(e=!0,i=$U.noUnknown){typeof e!="boolean"&&(i=e,e=!0);let n=this.test({name:"noUnknown",exclusive:!0,message:i,test(r){if(r==null)return!0;const o=xue(this.schema,r);return!e||o.length===0||this.createError({params:{unknown:o.join(", ")}})}});return n.spec.noUnknown=e,n}unknown(e=!0,i=$U.noUnknown){return this.noUnknown(!e,i)}transformKeys(e){return this.transform(i=>{if(!i)return i;const n={};for(const r of Object.keys(i))n[e(r)]=i[r];return n})}camelCase(){return this.transformKeys(iY.camelCase)}snakeCase(){return this.transformKeys(iY.snakeCase)}constantCase(){return this.transformKeys(e=>iY.snakeCase(e).toUpperCase())}describe(e){const i=(e?this.resolve(e):this).clone(),n=super.describe(e);n.fields={};for(const[o,a]of Object.entries(i.fields)){var r;let s=e;(r=s)!=null&&r.value&&(s=Object.assign({},s,{parent:s.value,value:s.value[o]})),n.fields[o]=a.describe(s)}return n}}QLe.prototype=eke.prototype;var M6="Dialog",[tke]=kS(M6),[Dgt,Uv]=tke(M6),rke=t=>{const{__scopeDialog:e,children:i,open:n,defaultOpen:r,onOpenChange:o,modal:a=!0}=t,s=J.useRef(null),l=J.useRef(null),[u,c]=ND({prop:n,defaultProp:r??!1,onChange:o,caller:M6});return L.jsx(Dgt,{scope:e,triggerRef:s,contentRef:l,contentId:Mv(),titleId:Mv(),descriptionId:Mv(),open:u,onOpenChange:c,onOpenToggle:J.useCallback(()=>c(d=>!d),[c]),modal:a,children:i})};rke.displayName=M6;var ike="DialogTrigger",Rgt=J.forwardRef((t,e)=>{const{__scopeDialog:i,...n}=t,r=Uv(ike,i),o=Bl(e,r.triggerRef);return L.jsx(es.button,{type:"button","aria-haspopup":"dialog","aria-expanded":r.open,"aria-controls":r.contentId,"data-state":ste(r.open),...n,ref:o,onClick:tn(t.onClick,r.onOpenToggle)})});Rgt.displayName=ike;var ote="DialogPortal",[Mgt,nke]=tke(ote,{forceMount:void 0}),oke=t=>{const{__scopeDialog:e,forceMount:i,children:n,container:r}=t,o=Uv(ote,e);return L.jsx(Mgt,{scope:e,forceMount:i,children:J.Children.map(n,a=>L.jsx(Mp,{present:i||o.open,children:L.jsx(pV,{asChild:!0,container:r,children:a})}))})};oke.displayName=ote;var hz="DialogOverlay",ake=J.forwardRef((t,e)=>{const i=nke(hz,t.__scopeDialog),{forceMount:n=i.forceMount,...r}=t,o=Uv(hz,t.__scopeDialog);return o.modal?L.jsx(Mp,{present:n||o.open,children:L.jsx(kgt,{...r,ref:e})}):null});ake.displayName=hz;var Lgt=yk("DialogOverlay.RemoveScroll"),kgt=J.forwardRef((t,e)=>{const{__scopeDialog:i,...n}=t,r=Uv(hz,i);return L.jsx(f6,{as:Lgt,allowPinchZoom:!0,shards:[r.contentRef],children:L.jsx(es.div,{"data-state":ste(r.open),...n,ref:e,style:{pointerEvents:"auto",...n.style}})})}),RD="DialogContent",ske=J.forwardRef((t,e)=>{const i=nke(RD,t.__scopeDialog),{forceMount:n=i.forceMount,...r}=t,o=Uv(RD,t.__scopeDialog);return L.jsx(Mp,{present:n||o.open,children:o.modal?L.jsx(Igt,{...r,ref:e}):L.jsx(Ngt,{...r,ref:e})})});ske.displayName=RD;var Igt=J.forwardRef((t,e)=>{const i=Uv(RD,t.__scopeDialog),n=J.useRef(null),r=Bl(e,i.contentRef,n);return J.useEffect(()=>{const o=n.current;if(o)return Eee(o)},[]),L.jsx(lke,{...t,ref:r,trapFocus:i.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:tn(t.onCloseAutoFocus,o=>{var a;o.preventDefault(),(a=i.triggerRef.current)==null||a.focus()}),onPointerDownOutside:tn(t.onPointerDownOutside,o=>{const a=o.detail.originalEvent,s=a.button===0&&a.ctrlKey===!0;(a.button===2||s)&&o.preventDefault()}),onFocusOutside:tn(t.onFocusOutside,o=>o.preventDefault())})}),Ngt=J.forwardRef((t,e)=>{const i=Uv(RD,t.__scopeDialog),n=J.useRef(!1),r=J.useRef(!1);return L.jsx(lke,{...t,ref:e,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var a,s;(a=t.onCloseAutoFocus)==null||a.call(t,o),o.defaultPrevented||(n.current||(s=i.triggerRef.current)==null||s.focus(),o.preventDefault()),n.current=!1,r.current=!1},onInteractOutside:o=>{var l,u;(l=t.onInteractOutside)==null||l.call(t,o),o.defaultPrevented||(n.current=!0,o.detail.originalEvent.type==="pointerdown"&&(r.current=!0));const a=o.target;((u=i.triggerRef.current)==null?void 0:u.contains(a))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&r.current&&o.preventDefault()}})}),lke=J.forwardRef((t,e)=>{const{__scopeDialog:i,trapFocus:n,onOpenAutoFocus:r,onCloseAutoFocus:o,...a}=t,s=Uv(RD,i),l=J.useRef(null),u=Bl(e,l);return xee(),L.jsxs(L.Fragment,{children:[L.jsx(c6,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:r,onUnmountAutoFocus:o,children:L.jsx(fV,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":ste(s.open),...a,ref:u,onDismiss:()=>s.onOpenChange(!1)})}),L.jsxs(L.Fragment,{children:[L.jsx(Vgt,{titleId:s.titleId}),L.jsx(Ugt,{contentRef:l,descriptionId:s.descriptionId})]})]})}),ate="DialogTitle",Fgt=J.forwardRef((t,e)=>{const{__scopeDialog:i,...n}=t,r=Uv(ate,i);return L.jsx(es.h2,{id:r.titleId,...n,ref:e})});Fgt.displayName=ate;var uke="DialogDescription",Bgt=J.forwardRef((t,e)=>{const{__scopeDialog:i,...n}=t,r=Uv(uke,i);return L.jsx(es.p,{id:r.descriptionId,...n,ref:e})});Bgt.displayName=uke;var cke="DialogClose",jgt=J.forwardRef((t,e)=>{const{__scopeDialog:i,...n}=t,r=Uv(cke,i);return L.jsx(es.button,{type:"button",...n,ref:e,onClick:tn(t.onClick,()=>r.onOpenChange(!1))})});jgt.displayName=cke;function ste(t){return t?"open":"closed"}var dke="DialogTitleWarning",[tFt,fke]=S8e(dke,{contentName:RD,titleName:ate,docsSlug:"dialog"}),Vgt=({titleId:t})=>{const e=fke(dke),i=`\`${e.contentName}\` requires a \`${e.titleName}\` for the component to be accessible for screen reader users.

If you want to hide the \`${e.titleName}\`, you can wrap it with our VisuallyHidden component.

For more information, see https://radix-ui.com/primitives/docs/components/${e.docsSlug}`;return J.useEffect(()=>{t&&(document.getElementById(t)||console.error(i))},[i,t]),null},Hgt="DialogDescriptionWarning",Ugt=({contentRef:t,descriptionId:e})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${fke(Hgt).contentName}}.`;return J.useEffect(()=>{var o;const r=(o=t.current)==null?void 0:o.getAttribute("aria-describedby");e&&r&&(document.getElementById(e)||console.warn(n))},[n,t,e]),null},zgt=rke,$gt=oke,Wgt=ake,Ggt=ske;const Ygt={xs:"max-w-xs",sm:"max-w-sm",md:"max-w-md",lg:"max-w-lg",xl:"max-w-xl","2xl":"max-w-2xl","3xl":"max-w-3xl","4xl":"max-w-4xl","5xl":"max-w-5xl","6xl":"max-w-6xl","7xl":"max-w-7xl"},qgt=10001;function yI(t){const e=qt.c(24),i=t.show??!1;let n;e[0]!==t.onClose?(n=()=>L.jsx("button",{type:"button",onClick:t.onClose,className:Hr("absolute top-4 right-4 z-10","w-8 h-8 rounded-lg flex items-center justify-center","text-neutral-400 hover:text-neutral-600 dark:hover:text-neutral-200","hover:bg-neutral-100 dark:hover:bg-neutral-800","transition-colors"),"aria-label":"Close",children:L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-5 h-5"})}),e[0]=t.onClose,e[1]=n):n=e[1];const r=n;let o;e[2]!==t?(o=p=>!p&&t.onClose(),e[2]=t,e[3]=o):o=e[3];let a;e[4]===Symbol.for("react.memo_cache_sentinel")?(a={zIndex:qgt},e[4]=a):a=e[4];let s;e[5]!==t.onClose?(s=L.jsx(Wgt,{className:"absolute inset-0 bg-black/50 backdrop-blur-sm cursor-default",onClick:t.onClose}),e[5]=t.onClose,e[6]=s):s=e[6];const l=Ygt[t.size];let u;e[7]!==t.className||e[8]!==l?(u=Hr("relative w-full",l,"bg-white dark:bg-neutral-900","rounded-xl shadow-md","border border-neutral-200 dark:border-neutral-700","animate-fade-in overflow-hidden",t.className),e[7]=t.className,e[8]=l,e[9]=u):u=e[9];let c;e[10]!==r||e[11]!==t.showCloseButton?(c=t.showCloseButton&&r(),e[10]=r,e[11]=t.showCloseButton,e[12]=c):c=e[12];let d;e[13]!==t.children||e[14]!==u||e[15]!==c?(d=L.jsxs(Ggt,{className:u,onClick:Xgt,"aria-describedby":void 0,children:[c,t.children]}),e[13]=t.children,e[14]=u,e[15]=c,e[16]=d):d=e[16];let f;e[17]!==s||e[18]!==d?(f=L.jsx($gt,{children:L.jsxs("div",{className:"fixed inset-0 flex items-center justify-center p-4",style:a,children:[s,d]})}),e[17]=s,e[18]=d,e[19]=f):f=e[19];let h;return e[20]!==i||e[21]!==o||e[22]!==f?(h=L.jsx(zgt,{open:i,onOpenChange:o,children:f}),e[20]=i,e[21]=o,e[22]=f,e[23]=h):h=e[23],h}function Xgt(t){return t.stopPropagation()}const Kgt=100002;function Zgt(){const t=qt.c(8),{theme:e}=dI(),i=Jgt,n=e===VL.Dark,o=`inset 0 1px 0 0 ${n?"rgba(255, 255, 255, 0.24)":"rgba(16, 35, 82, 0.28)"}`,a=n?"var(--foreground)":"black";let s;t[0]!==o||t[1]!==a?(s={borderRadius:"var(--radius)",fontFamily:"'LexendDeca', sans-serif",overflow:"hidden",border:"none",boxShadow:o,backgroundColor:"var(--primary-10)",color:a},t[0]=o,t[1]=a,t[2]=s):s=t[2];const l=s;let u;t[3]===Symbol.for("react.memo_cache_sentinel")?(u=L.jsx("style",{children:`
        .Toastify__toast-icon {
          align-self: center !important;
          margin-right: -30px;
          right: 0;
          opacity: 0.2;
          height: 90px;
          width: 90px;
          position: absolute !important;
        }
      `}),t[3]=u):u=t[3];const c=i(e);let d;t[4]===Symbol.for("react.memo_cache_sentinel")?(d={zIndex:Kgt},t[4]=d):d=t[4];let f;return t[5]!==c||t[6]!==l?(f=L.jsxs(L.Fragment,{children:[u,L.jsx(g7e,{stacked:!0,pauseOnFocusLoss:!1,position:"bottom-right",autoClose:9e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,draggable:!0,pauseOnHover:!0,theme:c,toastStyle:l,style:d})]}),t[5]=c,t[6]=l,t[7]=f):f=t[7],f}function Jgt(t){return t===VL.Dark?"dark":"light"}function hke(t){const e=qt.c(19),i=t.side??"right",[n,r]=J.useState(!1),[o,a]=J.useState(null),s=J.useRef(null);let l;e[0]!==i?(l=()=>{if(!s.current)return null;const g=s.current.getBoundingClientRect();let v=0,y=0;e:switch(i){case"right":{v=g.top+g.height/2,y=g.right+14;break e}case"left":{v=g.top+g.height/2,y=g.left-14;break e}case"top":{v=g.top-14,y=g.left+g.width/2;break e}case"bottom":v=g.bottom+14,y=g.left+g.width/2}return{top:v,left:y}},e[0]=i,e[1]=l):l=e[1];const u=l;let c;e[2]!==u?(c=()=>{const g=u();g&&(a(g),r(!0))},e[2]=u,e[3]=c):c=e[3];const d=c;let f;e[4]===Symbol.for("react.memo_cache_sentinel")?(f=()=>{r(!1)},e[4]=f):f=e[4];const h=f;let p;if(e[5]!==d||e[6]!==n||e[7]!==o||e[8]!==t.children||e[9]!==t.className||e[10]!==t.label||e[11]!==i){const g={right:"-translate-y-1/2",left:"-translate-y-1/2 -translate-x-full",top:"-translate-x-1/2 -translate-y-full",bottom:"-translate-x-1/2"};let v;e[13]!==t.className?(v=Hr("inline-flex",t.className),e[13]=t.className,e[14]=v):v=e[14];let y;e[15]!==d||e[16]!==t.children||e[17]!==v?(y=L.jsx("div",{ref:s,className:v,onMouseEnter:d,onMouseLeave:h,children:t.children}),e[15]=d,e[16]=t.children,e[17]=v,e[18]=y):y=e[18],p=L.jsxs(L.Fragment,{children:[y,o&&zf.createPortal(L.jsx("div",{className:Hr("fixed z-[9999] pointer-events-none","transition-opacity duration-150",g[i],n?"opacity-100":"opacity-0"),style:{top:o.top,left:o.left},children:L.jsx("div",{className:"relative px-2.5 py-1.5 bg-neutral-900 text-white text-xs font-medium rounded-md whitespace-nowrap shadow-lg ring-1 ring-neutral-600",children:t.label})}),document.body)]}),e[5]=d,e[6]=n,e[7]=o,e[8]=t.children,e[9]=t.className,e[10]=t.label,e[11]=i,e[12]=p}else p=e[12];return p}function yo(...t){return qJ(Rv(t))}const QM=t=>{const e=Math.floor(t/1e3),i=Math.floor(e/60),n=e%60;return`${i}:${n.toString().padStart(2,"0")}`},Cy=t=>{const e=t.trim();if(e.endsWith("us")){const i=parseFloat(e.slice(0,-2));return isNaN(i)?null:i/1e3}if(e.endsWith("ms")){const i=parseFloat(e.slice(0,-2));return isNaN(i)?null:i}if(e.endsWith("s")){const i=parseFloat(e.slice(0,-1));return isNaN(i)?null:i*1e3}if(e.includes(":")){const i=e.split(":").map(r=>parseInt(r,10));if(i.some(isNaN))return null;let n=0;if(i.length===2)n=i[0]*60+i[1];else if(i.length===3)n=i[0]*3600+i[1]*60+i[2];else return null;return n*1e3}return null};function Qgt(t){const{track:e}=el(),[i,n]=J.useState(!1),r=QLe({startTime:bZ().required("Start time is required").test("valid-format","Invalid format. Use MM:SS or append s/ms/us",function(f){return f?Cy(f)!==null:!1}).test("min-value","Start time must be 0 or greater",function(f){if(!f)return!0;const h=Cy(f);return h!==null&&h>=0}).test("max-value",`Must be less than recording duration (${QM(t.recordingSessionInfo.durationMs)})`,function(f){if(!f)return!0;const h=Cy(f);return h!==null&&h<=t.recordingSessionInfo.durationMs}),endTime:bZ().required("End time is required").test("valid-format","Invalid format. Use MM:SS or append s/ms/us",function(f){return f?Cy(f)!==null:!1}).test("min-value","End time must be greater than 0",function(f){if(!f)return!0;const h=Cy(f);return h!==null&&h>0}).test("max-value",`Must be less than recording duration (${QM(t.recordingSessionInfo.durationMs)})`,function(f){if(!f)return!0;const h=Cy(f);return h!==null&&h<=t.recordingSessionInfo.durationMs}).test("greater-than-start","End time must be greater than start time",function(f){const{startTime:h}=this.parent;if(!f||!h)return!0;const p=Cy(h),g=Cy(f);return p===null||g===null?!0:g>p})}),o=Vpt({initialValues:{startTime:"",endTime:""},validationSchema:r,validateOnMount:!1,validateOnChange:!0,validateOnBlur:!0,onSubmit:()=>{c()}}),a=()=>L.jsx(L.Fragment,{children:t.playbackControls.repeat.isRepeating?L.jsxs("div",{className:"flex flex-col items-center justify-center -mb-1",children:[L.jsx($le,{sx:{fontSize:17}}),L.jsx(dLe,{sx:{fontSize:4}})]}):L.jsx($le,{sx:{fontSize:17}})}),s=()=>{const f=L.jsxs("div",{className:"text-left text-inherit",children:[L.jsx("p",{className:"mb-2 text-sm font-bold",children:"Input formats"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Seconds"}),": 90s",L.jsx("br",{}),L.jsx("span",{className:"font-bold",children:"Milliseconds"}),": 90000ms",L.jsx("br",{}),L.jsx("span",{className:"font-bold",children:"Microseconds"}),": 90000000us",L.jsx("br",{}),L.jsx("span",{className:"font-bold",children:"MM:SS"}),": 1:30 (1 minute 30 seconds)",L.jsx("br",{}),L.jsx("span",{className:"font-bold",children:"HH:MM:SS"}),": 1:30:45 (1 hour 30 minutes 45 seconds)"]})]});return L.jsx(FD,{content:f,children:L.jsx(Dct,{className:"mx-1",sx:{fontSize:15}})})},l=async()=>{if(!t.isPlaybackControlsDisabled)try{if(t.playbackControls.repeat.isRepeating){const f=t.playbackControls.repeat.startMs??0,h=t.playbackControls.repeat.endMs??t.recordingSessionInfo.durationMs;await o.setFieldValue("startTime",QM(f)),await o.setFieldValue("endTime",QM(h))}else{const h=t.recordingSessionInfo.durationMs;await o.setFieldValue("startTime",QM(0)),await o.setFieldValue("endTime",QM(h))}o.setErrors({}),o.setTouched({}),n(!i)}catch{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})}},u=async()=>{t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.setRepeat(!1),e(Fi.PlaybackRepeatSet,{enabled:!1,path:t.recordingSessionInfo.path,maxDuration:t.recordingSessionInfo.durationMs}),o.resetForm(),n(!1)},()=>{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})})},c=async()=>{if(!o.isValid){o.setTouched({startTime:!0,endTime:!0});return}const f=Cy(o.values.startTime)??0,h=Cy(o.values.endTime);t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.setRepeat(!0,f,h??void 0),e(Fi.PlaybackRepeatSet,{enabled:!0,path:t.recordingSessionInfo.path,start:f,stop:h,maxDuration:t.recordingSessionInfo.durationMs}),n(!1)},()=>{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})})},d=()=>{const f=!o.isValid||!!o.errors.startTime||!!o.errors.endTime,h=!t.playbackControls.repeat.isRepeating;return L.jsxs(ust,{align:"center",side:"top",sideOffset:8,className:yo("z-[9999] p-3 rounded-lg shadow-lg min-w-[260px]","bg-white dark:bg-neutral-800","border border-neutral-200 dark:border-neutral-700"),children:[L.jsxs("div",{className:"flex items-center mb-2",children:[s(),L.jsx("span",{className:"font-bold text-sm text-foreground dark:text-white",children:"Repeat"})]}),L.jsxs("div",{className:yo("flex justify-between items-center rounded px-2 py-1 mb-1","bg-remotive-primary-10 dark:bg-neutral-700"),children:[L.jsx("p",{className:"m-0 text-sm font-bold text-foreground dark:text-white",title:"Start time of the repeated section",children:"Start"}),L.jsx("input",{title:"MM:SS or number with unit (e.g., 2s, 2000ms, 2000000us)",autoComplete:"off",type:"text",name:"startTime",placeholder:"MM:SS",className:yo("text-sm text-right px-1 py-0.5 rounded border","max-w-[80px] h-5","bg-white dark:bg-neutral-600","border-neutral-300 dark:border-neutral-500","text-foreground dark:text-white","focus:outline-none focus:ring-1 focus:ring-remotive-primary-60"),value:o.values.startTime,onChange:o.handleChange,onBlur:o.handleBlur})]}),o.errors.startTime&&L.jsx("p",{className:"text-xxs text-destructive dark:text-red-500 text-right mr-2 m-0 -mt-0.5 mb-1",children:o.errors.startTime}),L.jsxs("div",{className:yo("flex justify-between items-center rounded px-2 py-1 mb-1","bg-remotive-primary-10 dark:bg-neutral-700"),children:[L.jsx("p",{className:"m-0 text-sm font-bold text-foreground dark:text-white",title:"End time of the repeated section",children:"End"}),L.jsx("input",{title:"MM:SS or number with unit (e.g., 2s, 2000ms, 2000000us)",type:"text",autoComplete:"off",name:"endTime",placeholder:"MM:SS",className:yo("text-sm text-right px-1 py-0.5 rounded border","max-w-[80px] h-5","bg-white dark:bg-neutral-600","border-neutral-300 dark:border-neutral-500","text-foreground dark:text-white","focus:outline-none focus:ring-1 focus:ring-remotive-primary-60"),value:o.values.endTime,onChange:o.handleChange,onBlur:o.handleBlur})]}),o.errors.endTime&&L.jsx("p",{className:"text-[10px] text-destructive text-right mr-2 m-0 -mt-1 mb-1",children:o.errors.endTime}),L.jsxs("div",{className:"flex justify-between gap-2 mt-3",children:[L.jsx(Za,{type:fn.PRIMARY,label:"Stop",title:"Stops and clears the current repeat interval.",size:_a.SM,onClick:u,disabled:h,className:"flex-1"}),L.jsx(Za,{type:fn.SUCCESS,label:"Apply",title:"Applies the current start and end times as the repeat interval.",size:_a.SM,onClick:c,disabled:f,className:"flex-1"})]})]})};return L.jsxs(ast,{open:i,onOpenChange:n,children:[L.jsx(sst,{asChild:!0,children:L.jsx("span",{title:"Open settings to start and stop repeating the recording",role:"button",tabIndex:0,style:{opacity:t.isPlaybackControlsDisabled?.6:1,cursor:t.isPlaybackControlsDisabled?"not-allowed":"pointer"},onClick:f=>{f.preventDefault(),l()},onKeyDown:f=>{(f.key==="Enter"||f.key===" ")&&(f.preventDefault(),l())},className:yo("inline-flex items-center justify-center","p-0 ml-1 mr-2","border-0 bg-transparent",t.playbackControls.repeat.isRepeating?"text-remotive-success-60":"text-remotive-primary-60","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),children:a()})}),L.jsx(lst,{children:d()})]})}function evt(t){const e=qt.c(14),{track:i}=el();let n;e[0]!==t||e[1]!==i?(n=async()=>{t.isPlaybackControlsDisabled||(i(Fi.PlaybackReset,{path:t.recordingSessionInfo.path}),t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.restart()},()=>{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})}))},e[0]=t,e[1]=i,e[2]=n):n=e[2];const r=n,o=t.isPlaybackControlsDisabled?.6:1,a=t.isPlaybackControlsDisabled?"not-allowed":"pointer";let s;e[3]!==o||e[4]!==a?(s={opacity:o,cursor:a},e[3]=o,e[4]=a,e[5]=s):s=e[5];let l;e[6]!==r?(l=f=>{(f.key==="Enter"||f.key===" ")&&r()},e[6]=r,e[7]=l):l=e[7];let u;e[8]===Symbol.for("react.memo_cache_sentinel")?(u=yo("inline-flex items-center justify-center","p-0 mr-1","border-0 bg-transparent","text-remotive-primary-60","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),e[8]=u):u=e[8];let c;e[9]===Symbol.for("react.memo_cache_sentinel")?(c=L.jsx(pLe,{sx:{fontSize:24}}),e[9]=c):c=e[9];let d;return e[10]!==r||e[11]!==s||e[12]!==l?(d=L.jsx("span",{title:"Restart recording from the beginning",role:"button",tabIndex:0,style:s,onClick:r,onKeyDown:l,className:u,children:c}),e[10]=r,e[11]=s,e[12]=l,e[13]=d):d=e[13],d}function tvt(t){const e=qt.c(19),{track:i}=el(),n=t.playbackControls.isPlaying,r=n?hLe:Yee;let o;e[0]!==n||e[1]!==t||e[2]!==i?(o=async()=>{t.isPlaybackControlsDisabled||(n?(i(Fi.Pause,{path:t.recordingSessionInfo.path}),t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.pause()},()=>{Ki.error(t.playbackErrorMessage("pause"),{autoClose:1e4})})):(i(Fi.Play,{path:t.recordingSessionInfo.path}),t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.play()},()=>{Ki.error(t.playbackErrorMessage("play"),{autoClose:1e4})})))},e[0]=n,e[1]=t,e[2]=i,e[3]=o):o=e[3];const a=o,s=`${n?"Pause":"Play"} the recording`,l=t.isPlaybackControlsDisabled?.6:1,u=t.isPlaybackControlsDisabled?"not-allowed":"pointer";let c;e[4]!==l||e[5]!==u?(c={opacity:l,cursor:u},e[4]=l,e[5]=u,e[6]=c):c=e[6];let d;e[7]!==a?(d=v=>{(v.key==="Enter"||v.key===" ")&&a()},e[7]=a,e[8]=d):d=e[8];let f;e[9]===Symbol.for("react.memo_cache_sentinel")?(f=yo("inline-flex items-center justify-center","p-0 mr-1","border-0 bg-transparent","text-remotive-primary-60","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),e[9]=f):f=e[9];let h;e[10]===Symbol.for("react.memo_cache_sentinel")?(h={fontSize:32},e[10]=h):h=e[10];let p;e[11]!==r?(p=L.jsx(r,{sx:h}),e[11]=r,e[12]=p):p=e[12];let g;return e[13]!==s||e[14]!==c||e[15]!==d||e[16]!==p||e[17]!==a?(g=L.jsx("span",{title:s,role:"button",tabIndex:0,style:c,onClick:a,onKeyDown:d,className:f,children:p}),e[13]=s,e[14]=c,e[15]=d,e[16]=p,e[17]=a,e[18]=g):g=e[18],g}function rvt(t){const e=qt.c(10),{track:i}=el();let n;e[0]!==t||e[1]!==i?(n=async()=>{try{await t.playbackControls.close(),i(Fi.CloseRecordingSession,{path:t.recordingSessionInfo.path}),t.onAfterClose()}catch{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})}},e[0]=t,e[1]=i,e[2]=n):n=e[2];const r=n;let o;e[3]===Symbol.for("react.memo_cache_sentinel")?(o=yo("inline-flex items-center justify-center","p-0","border-0 bg-transparent","cursor-pointer","text-foreground dark:text-neutral-300","hover:bg-neutral-100 dark:hover:bg-muted","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),e[3]=o):o=e[3];let a;e[4]!==r?(a=u=>{(u.key==="Enter"||u.key===" ")&&(u.preventDefault(),r())},e[4]=r,e[5]=a):a=e[5];let s;e[6]===Symbol.for("react.memo_cache_sentinel")?(s=L.jsx(uz,{sx:{fontSize:12}}),e[6]=s):s=e[6];let l;return e[7]!==r||e[8]!==a?(l=L.jsx("div",{role:"button",tabIndex:0,className:o,onClick:r,onKeyDown:a,children:s}),e[7]=r,e[8]=a,e[9]=l):l=e[9],l}var nY,Eue;function ivt(){if(Eue)return nY;Eue=1;function t(r){if(typeof r!="number")throw new TypeError("Expected a number");return{days:Math.trunc(r/864e5),hours:Math.trunc(r/36e5)%24,minutes:Math.trunc(r/6e4)%60,seconds:Math.trunc(r/1e3)%60,ms:Math.trunc(r)%1e3}}function e(r,o){o=o||2;let a=r.toString(),s=0;return s=o-a.length+1,a=new Array(s).join("0").concat(a),a}function i(r,o){return o?r<0?"-":"":r<=-1e3?"-":""}function n(r,o){const a=o&&o.leading,s=o&&o.ms,l=r<0?-r:r,u=i(r,s),c=t(l),d=e(c.seconds);let f="";return c.days&&!f&&(f=u+c.days+":"+e(c.hours)+":"+e(c.minutes)+":"+d),c.hours&&!f&&(f=u+(a?e(c.hours):c.hours)+":"+e(c.minutes)+":"+d),f||(f=u+(a?e(c.minutes):c.minutes)+":"+d),s&&(f+="."+e(c.ms,3)),f}return nY=n,nY}var nvt=ivt();const Hk=wc(nvt);function TP(t){"@babel/helpers - typeof";return TP=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},TP(t)}function ovt(t,e){if(TP(t)!="object"||!t)return t;var i=t[Symbol.toPrimitive];if(i!==void 0){var n=i.call(t,e);if(TP(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function avt(t){var e=ovt(t,"string");return TP(e)=="symbol"?e:e+""}function Ev(t,e,i){return(e=avt(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function wue(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function jd(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?wue(Object(i),!0).forEach(function(n){Ev(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):wue(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}function SZ(t,e){(e==null||e>t.length)&&(e=t.length);for(var i=0,n=Array(e);i<e;i++)n[i]=t[i];return n}function svt(t){if(Array.isArray(t))return SZ(t)}function lvt(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function pke(t,e){if(t){if(typeof t=="string")return SZ(t,e);var i={}.toString.call(t).slice(8,-1);return i==="Object"&&t.constructor&&(i=t.constructor.name),i==="Map"||i==="Set"?Array.from(t):i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?SZ(t,e):void 0}}function uvt(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function lP(t){return svt(t)||lvt(t)||pke(t)||uvt()}function cvt(t){if(Array.isArray(t))return t}function dvt(t,e){var i=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(i!=null){var n,r,o,a,s=[],l=!0,u=!1;try{if(o=(i=i.call(t)).next,e===0){if(Object(i)!==i)return;l=!1}else for(;!(l=(n=o.call(i)).done)&&(s.push(n.value),s.length!==e);l=!0);}catch(c){u=!0,r=c}finally{try{if(!l&&i.return!=null&&(a=i.return(),Object(a)!==a))return}finally{if(u)throw r}}return s}}function fvt(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function xh(t,e){return cvt(t)||dvt(t,e)||pke(t,e)||fvt()}var oY={exports:{}};/*!
	Copyright (c) 2018 Jed Watson.
	Licensed under the MIT License (MIT), see
	http://jedwatson.github.io/classnames
*/var Aue;function hvt(){return Aue||(Aue=1,(function(t){(function(){var e={}.hasOwnProperty;function i(){for(var o="",a=0;a<arguments.length;a++){var s=arguments[a];s&&(o=r(o,n(s)))}return o}function n(o){if(typeof o=="string"||typeof o=="number")return o;if(typeof o!="object")return"";if(Array.isArray(o))return i.apply(null,o);if(o.toString!==Object.prototype.toString&&!o.toString.toString().includes("[native code]"))return o.toString();var a="";for(var s in o)e.call(o,s)&&o[s]&&(a=r(a,s));return a}function r(o,a){return a?o?o+" "+a:o+a:o}t.exports?(i.default=i,t.exports=i):window.classNames=i})()})(oY)),oY.exports}var pvt=hvt();const hm=wc(pvt);function _Z(t){var e=J.useRef();e.current=t;var i=J.useCallback(function(){for(var n,r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return(n=e.current)===null||n===void 0?void 0:n.call.apply(n,[e].concat(o))},[]);return i}function gvt(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var Oue=gvt()?J.useLayoutEffect:J.useEffect,vvt=function(e,i){var n=J.useRef(!0);Oue(function(){return e(n.current)},i),Oue(function(){return n.current=!1,function(){n.current=!0}},[])},Due=function(e,i){vvt(function(n){if(!n)return e()},i)};function Rue(t){var e=J.useRef(!1),i=J.useState(t),n=xh(i,2),r=n[0],o=n[1];J.useEffect(function(){return e.current=!1,function(){e.current=!0}},[]);function a(s,l){l&&e.current||o(s)}return[r,a]}function aY(t){return t!==void 0}function yvt(t,e){var i=e||{},n=i.defaultValue,r=i.value,o=i.onChange,a=i.postState,s=Rue(function(){return aY(r)?r:aY(n)?typeof n=="function"?n():n:typeof t=="function"?t():t}),l=xh(s,2),u=l[0],c=l[1],d=r!==void 0?r:u,f=a?a(d):d,h=_Z(o),p=Rue([d]),g=xh(p,2),v=g[0],y=g[1];Due(function(){var b=v[0];u!==b&&h(u,b)},[v]),Due(function(){aY(r)||c(r)},[r]);var m=_Z(function(b,S){c(b,S),y([d],S)});return[f,m]}var PZ={},mvt=function(e){};function bvt(t,e){}function Svt(t,e){}function _vt(){PZ={}}function gke(t,e,i){!e&&!PZ[i]&&(t(!1,i),PZ[i]=!0)}function IV(t,e){gke(bvt,t,e)}function Pvt(t,e){gke(Svt,t,e)}IV.preMessage=mvt;IV.resetWarned=_vt;IV.noteOnce=Pvt;function Cvt(t,e){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1,n=new Set;function r(o,a){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,l=n.has(o);if(IV(!l,"Warning: There may be circular references"),l)return!1;if(o===a)return!0;if(i&&s>1)return!1;n.add(o);var u=s+1;if(Array.isArray(o)){if(!Array.isArray(a)||o.length!==a.length)return!1;for(var c=0;c<o.length;c++)if(!r(o[c],a[c],u))return!1;return!0}if(o&&a&&TP(o)==="object"&&TP(a)==="object"){var d=Object.keys(o);return d.length!==Object.keys(a).length?!1:d.every(function(f){return r(o[f],a[f],u)})}return!1}return r(t,e)}function vke(t,e){if(t==null)return{};var i,n,r=FS(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)i=o[n],e.indexOf(i)===-1&&{}.propertyIsEnumerable.call(t,i)&&(r[i]=t[i])}return r}function CZ(t,e,i){return(t-e)/(i-e)}function lte(t,e,i,n){var r=CZ(e,i,n),o={};switch(t){case"rtl":o.right="".concat(r*100,"%"),o.transform="translateX(50%)";break;case"btt":o.bottom="".concat(r*100,"%"),o.transform="translateY(50%)";break;case"ttb":o.top="".concat(r*100,"%"),o.transform="translateY(-50%)";break;default:o.left="".concat(r*100,"%"),o.transform="translateX(-50%)";break}return o}function TL(t,e){return Array.isArray(t)?t[e]:t}var Rd={PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40},qD=J.createContext({min:0,max:0,direction:"ltr",step:1,includedStart:0,includedEnd:0,tabIndex:0,keyboard:!0,styles:{},classNames:{}}),Tvt=["prefixCls","value","valueIndex","onStartMove","style","render","dragging","onOffsetChange","onChangeComplete","onFocus","onMouseEnter"],Mue=J.forwardRef(function(t,e){var i=t.prefixCls,n=t.value,r=t.valueIndex,o=t.onStartMove,a=t.style,s=t.render,l=t.dragging,u=t.onOffsetChange,c=t.onChangeComplete,d=t.onFocus,f=t.onMouseEnter,h=vke(t,Tvt),p=J.useContext(qD),g=p.min,v=p.max,y=p.direction,m=p.disabled,b=p.keyboard,S=p.range,_=p.tabIndex,C=p.ariaLabelForHandle,P=p.ariaLabelledByForHandle,x=p.ariaValueTextFormatterForHandle,E=p.styles,A=p.classNames,R="".concat(i,"-handle"),M=function(X){m||o(X,r)},D=function(X){d==null||d(X,r)},F=function(X){f(X,r)},I=function(X){if(!m&&b){var W=null;switch(X.which||X.keyCode){case Rd.LEFT:W=y==="ltr"||y==="btt"?-1:1;break;case Rd.RIGHT:W=y==="ltr"||y==="btt"?1:-1;break;case Rd.UP:W=y!=="ttb"?1:-1;break;case Rd.DOWN:W=y!=="ttb"?-1:1;break;case Rd.HOME:W="min";break;case Rd.END:W="max";break;case Rd.PAGE_UP:W=2;break;case Rd.PAGE_DOWN:W=-2;break}W!==null&&(X.preventDefault(),u(W,r))}},V=function(X){switch(X.which||X.keyCode){case Rd.LEFT:case Rd.RIGHT:case Rd.UP:case Rd.DOWN:case Rd.HOME:case Rd.END:case Rd.PAGE_UP:case Rd.PAGE_DOWN:c==null||c();break}},z=lte(y,n,g,v),G={};if(r!==null){var H;G={tabIndex:m?null:TL(_,r),role:"slider","aria-valuemin":g,"aria-valuemax":v,"aria-valuenow":n,"aria-disabled":m,"aria-label":TL(C,r),"aria-labelledby":TL(P,r),"aria-valuetext":(H=TL(x,r))===null||H===void 0?void 0:H(n),"aria-orientation":y==="ltr"||y==="rtl"?"horizontal":"vertical",onMouseDown:M,onTouchStart:M,onFocus:D,onMouseEnter:F,onKeyDown:I,onKeyUp:V}}var U=J.createElement("div",Gn({ref:e,className:hm(R,Ev(Ev({},"".concat(R,"-").concat(r+1),r!==null&&S),"".concat(R,"-dragging"),l),A.handle),style:jd(jd(jd({},z),a),E.handle)},G,h));return s&&(U=s(U,{index:r,prefixCls:i,value:n,dragging:l})),U}),xvt=["prefixCls","style","onStartMove","onOffsetChange","values","handleRender","activeHandleRender","draggingIndex","onFocus"],Evt=J.forwardRef(function(t,e){var i=t.prefixCls,n=t.style,r=t.onStartMove,o=t.onOffsetChange,a=t.values,s=t.handleRender,l=t.activeHandleRender,u=t.draggingIndex,c=t.onFocus,d=vke(t,xvt),f=J.useRef({});J.useImperativeHandle(e,function(){return{focus:function(_){var C;(C=f.current[_])===null||C===void 0||C.focus()}}});var h=J.useState(-1),p=xh(h,2),g=p[0],v=p[1],y=function(_,C){v(C),c==null||c(_)},m=function(_,C){v(C)},b=jd({prefixCls:i,onStartMove:r,onOffsetChange:o,render:s,onFocus:y,onMouseEnter:m},d);return J.createElement(J.Fragment,null,a.map(function(S,_){return J.createElement(Mue,Gn({ref:function(P){P?f.current[_]=P:delete f.current[_]},dragging:u===_,style:TL(n,_),key:_,value:S,valueIndex:_},b))}),l&&J.createElement(Mue,Gn({key:"a11y"},b,{value:a[g],valueIndex:null,dragging:u!==-1,render:l,style:{pointerEvents:"none"},tabIndex:null,"aria-hidden":!0})))}),wvt=function(e){var i=e.prefixCls,n=e.style,r=e.children,o=e.value,a=e.onClick,s=J.useContext(qD),l=s.min,u=s.max,c=s.direction,d=s.includedStart,f=s.includedEnd,h=s.included,p="".concat(i,"-text"),g=lte(c,o,l,u);return J.createElement("span",{className:hm(p,Ev({},"".concat(p,"-active"),h&&d<=o&&o<=f)),style:jd(jd({},g),n),onMouseDown:function(y){y.stopPropagation()},onClick:function(){a(o)}},r)},Avt=function(e){var i=e.prefixCls,n=e.marks,r=e.onClick,o="".concat(i,"-mark");return n.length?J.createElement("div",{className:o},n.map(function(a){var s=a.value,l=a.style,u=a.label;return J.createElement(wvt,{key:s,prefixCls:o,style:l,value:s,onClick:r},u)})):null},Ovt=function(e){var i=e.prefixCls,n=e.value,r=e.style,o=e.activeStyle,a=J.useContext(qD),s=a.min,l=a.max,u=a.direction,c=a.included,d=a.includedStart,f=a.includedEnd,h="".concat(i,"-dot"),p=c&&d<=n&&n<=f,g=jd(jd({},lte(u,n,s,l)),typeof r=="function"?r(n):r);return p&&(g=jd(jd({},g),typeof o=="function"?o(n):o)),J.createElement("span",{className:hm(h,Ev({},"".concat(h,"-active"),p)),style:g})},Dvt=function(e){var i=e.prefixCls,n=e.marks,r=e.dots,o=e.style,a=e.activeStyle,s=J.useContext(qD),l=s.min,u=s.max,c=s.step,d=J.useMemo(function(){var f=new Set;if(n.forEach(function(p){f.add(p.value)}),r&&c!==null)for(var h=l;h<=u;)f.add(h),h+=c;return Array.from(f)},[l,u,c,r,n]);return J.createElement("div",{className:"".concat(i,"-step")},d.map(function(f){return J.createElement(Ovt,{prefixCls:i,key:f,value:f,style:o,activeStyle:a})}))},Lue=function(e){var i=e.prefixCls,n=e.style,r=e.start,o=e.end,a=e.index,s=e.onStartMove,l=e.replaceCls,u=J.useContext(qD),c=u.direction,d=u.min,f=u.max,h=u.disabled,p=u.range,g=u.classNames,v="".concat(i,"-track"),y=CZ(r,d,f),m=CZ(o,d,f),b=function(P){!h&&s&&s(P,-1)},S={};switch(c){case"rtl":S.right="".concat(y*100,"%"),S.width="".concat(m*100-y*100,"%");break;case"btt":S.bottom="".concat(y*100,"%"),S.height="".concat(m*100-y*100,"%");break;case"ttb":S.top="".concat(y*100,"%"),S.height="".concat(m*100-y*100,"%");break;default:S.left="".concat(y*100,"%"),S.width="".concat(m*100-y*100,"%")}var _=l||hm(v,Ev(Ev({},"".concat(v,"-").concat(a+1),a!==null&&p),"".concat(i,"-track-draggable"),s),g.track);return J.createElement("div",{className:_,style:jd(jd({},S),n),onMouseDown:b,onTouchStart:b})},Rvt=function(e){var i=e.prefixCls,n=e.style,r=e.values,o=e.startPoint,a=e.onStartMove,s=J.useContext(qD),l=s.included,u=s.range,c=s.min,d=s.styles,f=s.classNames,h=J.useMemo(function(){if(!u){if(r.length===0)return[];var g=o??c,v=r[0];return[{start:Math.min(g,v),end:Math.max(g,v)}]}for(var y=[],m=0;m<r.length-1;m+=1)y.push({start:r[m],end:r[m+1]});return y},[r,u,o,c]);if(!l)return null;var p=f.tracks||d.tracks?J.createElement(Lue,{index:null,prefixCls:i,start:h[0].start,end:h[h.length-1].end,replaceCls:hm(f.tracks,"".concat(i,"-tracks")),style:d.tracks}):null;return J.createElement(J.Fragment,null,p,h.map(function(g,v){var y=g.start,m=g.end;return J.createElement(Lue,{index:v,prefixCls:i,style:jd(jd({},TL(n,v)),d.track),start:y,end:m,key:v,onStartMove:a})}))},sY={exports:{}},Sa={};/**
 * @license React
 * 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 kue;function Mvt(){if(kue)return Sa;kue=1;var t=Symbol.for("react.element"),e=Symbol.for("react.portal"),i=Symbol.for("react.fragment"),n=Symbol.for("react.strict_mode"),r=Symbol.for("react.profiler"),o=Symbol.for("react.provider"),a=Symbol.for("react.context"),s=Symbol.for("react.server_context"),l=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),c=Symbol.for("react.suspense_list"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),h=Symbol.for("react.offscreen"),p;p=Symbol.for("react.module.reference");function g(v){if(typeof v=="object"&&v!==null){var y=v.$$typeof;switch(y){case t:switch(v=v.type,v){case i:case r:case n:case u:case c:return v;default:switch(v=v&&v.$$typeof,v){case s:case a:case l:case f:case d:case o:return v;default:return y}}case e:return y}}}return Sa.ContextConsumer=a,Sa.ContextProvider=o,Sa.Element=t,Sa.ForwardRef=l,Sa.Fragment=i,Sa.Lazy=f,Sa.Memo=d,Sa.Portal=e,Sa.Profiler=r,Sa.StrictMode=n,Sa.Suspense=u,Sa.SuspenseList=c,Sa.isAsyncMode=function(){return!1},Sa.isConcurrentMode=function(){return!1},Sa.isContextConsumer=function(v){return g(v)===a},Sa.isContextProvider=function(v){return g(v)===o},Sa.isElement=function(v){return typeof v=="object"&&v!==null&&v.$$typeof===t},Sa.isForwardRef=function(v){return g(v)===l},Sa.isFragment=function(v){return g(v)===i},Sa.isLazy=function(v){return g(v)===f},Sa.isMemo=function(v){return g(v)===d},Sa.isPortal=function(v){return g(v)===e},Sa.isProfiler=function(v){return g(v)===r},Sa.isStrictMode=function(v){return g(v)===n},Sa.isSuspense=function(v){return g(v)===u},Sa.isSuspenseList=function(v){return g(v)===c},Sa.isValidElementType=function(v){return typeof v=="string"||typeof v=="function"||v===i||v===r||v===n||v===u||v===c||v===h||typeof v=="object"&&v!==null&&(v.$$typeof===f||v.$$typeof===d||v.$$typeof===o||v.$$typeof===a||v.$$typeof===l||v.$$typeof===p||v.getModuleId!==void 0)},Sa.typeOf=g,Sa}var Iue;function Lvt(){return Iue||(Iue=1,sY.exports=Mvt()),sY.exports}Lvt();Number(J.version.split(".")[0]);function Nue(t){var e="touches"in t?t.touches[0]:t;return{pageX:e.pageX,pageY:e.pageY}}function kvt(t,e,i,n,r,o,a,s,l){var u=J.useState(null),c=xh(u,2),d=c[0],f=c[1],h=J.useState(-1),p=xh(h,2),g=p[0],v=p[1],y=J.useState(i),m=xh(y,2),b=m[0],S=m[1],_=J.useState(i),C=xh(_,2),P=C[0],x=C[1],E=J.useRef(null),A=J.useRef(null);J.useLayoutEffect(function(){g===-1&&S(i)},[i,g]),J.useEffect(function(){return function(){document.removeEventListener("mousemove",E.current),document.removeEventListener("mouseup",A.current),document.removeEventListener("touchmove",E.current),document.removeEventListener("touchend",A.current)}},[]);var R=function(V,z){b.some(function(G,H){return G!==V[H]})&&(z!==void 0&&f(z),S(V),a(V))},M=_Z(function(I,V){if(I===-1){var z=P[0],G=P[P.length-1],H=n-z,U=r-G,k=V*(r-n);k=Math.max(k,H),k=Math.min(k,U);var X=o(z+k);k=X-z;var W=P.map(function(de){return de+k});R(W)}else{var Y=(r-n)*V,te=lP(b);te[I]=P[I];var oe=l(te,Y,I,"dist");R(oe.values,oe.value)}}),D=function(V,z,G){V.stopPropagation();var H=G||i,U=H[z];v(z),f(U),x(H);var k=Nue(V),X=k.pageX,W=k.pageY,Y=function(de){de.preventDefault();var ge=Nue(de),Ee=ge.pageX,Re=ge.pageY,Ae=Ee-X,Pe=Re-W,we=t.current.getBoundingClientRect(),Te=we.width,ke=we.height,$e;switch(e){case"btt":$e=-Pe/ke;break;case"ttb":$e=Pe/ke;break;case"rtl":$e=-Ae/Te;break;default:$e=Ae/Te}M(z,$e)},te=function oe(de){de.preventDefault(),document.removeEventListener("mouseup",oe),document.removeEventListener("mousemove",Y),document.removeEventListener("touchend",oe),document.removeEventListener("touchmove",Y),E.current=null,A.current=null,v(-1),s()};document.addEventListener("mouseup",te),document.addEventListener("mousemove",Y),document.addEventListener("touchend",te),document.addEventListener("touchmove",Y),E.current=Y,A.current=te},F=J.useMemo(function(){var I=lP(i).sort(function(z,G){return z-G}),V=lP(b).sort(function(z,G){return z-G});return I.every(function(z,G){return z===V[G]})?b:i},[i,b]);return[g,d,F,D]}function Ivt(t,e,i,n,r,o){var a=J.useCallback(function(h){return Math.max(t,Math.min(e,h))},[t,e]),s=J.useCallback(function(h){if(i!==null){var p=t+Math.round((a(h)-t)/i)*i,g=function(b){return(String(b).split(".")[1]||"").length},v=Math.max(g(i),g(e),g(t)),y=Number(p.toFixed(v));return t<=y&&y<=e?y:null}return null},[i,t,e,a]),l=J.useCallback(function(h){var p=a(h),g=n.map(function(m){return m.value});i!==null&&g.push(s(h)),g.push(t,e);var v=g[0],y=e-t;return g.forEach(function(m){var b=Math.abs(p-m);b<=y&&(v=m,y=b)}),v},[t,e,n,i,a,s]),u=function h(p,g,v){var y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit";if(typeof g=="number"){var m,b=p[v],S=b+g,_=[];n.forEach(function(A){_.push(A.value)}),_.push(t,e),_.push(s(b));var C=g>0?1:-1;y==="unit"?_.push(s(b+C*i)):_.push(s(S)),_=_.filter(function(A){return A!==null}).filter(function(A){return g<0?A<=b:A>=b}),y==="unit"&&(_=_.filter(function(A){return A!==b}));var P=y==="unit"?b:S;m=_[0];var x=Math.abs(m-P);if(_.forEach(function(A){var R=Math.abs(A-P);R<x&&(m=A,x=R)}),m===void 0)return g<0?t:e;if(y==="dist")return m;if(Math.abs(g)>1){var E=lP(p);return E[v]=m,h(E,g-C,v,y)}return m}else{if(g==="min")return t;if(g==="max")return e}},c=function(p,g,v){var y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",m=p[v],b=u(p,g,v,y);return{value:b,changed:b!==m}},d=function(p){return o===null&&p===0||typeof o=="number"&&p<o},f=function(p,g,v){var y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unit",m=p.map(l),b=m[v],S=u(m,g,v,y);if(m[v]=S,r===!1){var _=o||0;v>0&&m[v-1]!==b&&(m[v]=Math.max(m[v],m[v-1]+_)),v<m.length-1&&m[v+1]!==b&&(m[v]=Math.min(m[v],m[v+1]-_))}else if(typeof o=="number"||o===null){for(var C=v+1;C<m.length;C+=1)for(var P=!0;d(m[C]-m[C-1])&&P;){var x=c(m,1,C);m[C]=x.value,P=x.changed}for(var E=v;E>0;E-=1)for(var A=!0;d(m[E]-m[E-1])&&A;){var R=c(m,-1,E-1);m[E-1]=R.value,A=R.changed}for(var M=m.length-1;M>0;M-=1)for(var D=!0;d(m[M]-m[M-1])&&D;){var F=c(m,-1,M-1);m[M-1]=F.value,D=F.changed}for(var I=0;I<m.length-1;I+=1)for(var V=!0;d(m[I+1]-m[I])&&V;){var z=c(m,1,I+1);m[I+1]=z.value,V=z.changed}}return{value:m[v],values:m}};return[l,f]}var Nvt=J.forwardRef(function(t,e){var i=t.prefixCls,n=i===void 0?"rc-slider":i,r=t.className,o=t.style,a=t.classNames,s=t.styles,l=t.disabled,u=l===void 0?!1:l,c=t.keyboard,d=c===void 0?!0:c,f=t.autoFocus,h=t.onFocus,p=t.onBlur,g=t.min,v=g===void 0?0:g,y=t.max,m=y===void 0?100:y,b=t.step,S=b===void 0?1:b,_=t.value,C=t.defaultValue,P=t.range,x=t.count,E=t.onChange,A=t.onBeforeChange,R=t.onAfterChange,M=t.onChangeComplete,D=t.allowCross,F=D===void 0?!0:D,I=t.pushable,V=I===void 0?!1:I,z=t.draggableTrack,G=t.reverse,H=t.vertical,U=t.included,k=U===void 0?!0:U,X=t.startPoint,W=t.trackStyle,Y=t.handleStyle,te=t.railStyle,oe=t.dotStyle,de=t.activeDotStyle,ge=t.marks,Ee=t.dots,Re=t.handleRender,Ae=t.activeHandleRender,Pe=t.tabIndex,we=Pe===void 0?0:Pe,Te=t.ariaLabelForHandle,ke=t.ariaLabelledByForHandle,$e=t.ariaValueTextFormatterForHandle,Ne=J.useRef(null),ve=J.useRef(null),pe=J.useMemo(function(){return H?G?"ttb":"btt":G?"rtl":"ltr"},[G,H]),fe=J.useMemo(function(){return isFinite(v)?v:0},[v]),me=J.useMemo(function(){return isFinite(m)?m:100},[m]),Ce=J.useMemo(function(){return S!==null&&S<=0?1:S},[S]),Ue=J.useMemo(function(){return typeof V=="boolean"?V?Ce:!1:V>=0?V:!1},[V,Ce]),Qe=J.useMemo(function(){return Object.keys(ge||{}).map(function(gr){var ce=ge[gr],fr={value:Number(gr)};return ce&&TP(ce)==="object"&&!J.isValidElement(ce)&&("label"in ce||"style"in ce)?(fr.style=ce.style,fr.label=ce.label):fr.label=ce,fr}).filter(function(gr){var ce=gr.label;return ce||typeof ce=="number"}).sort(function(gr,ce){return gr.value-ce.value})},[ge]),it=Ivt(fe,me,Ce,Qe,F,Ue),xt=xh(it,2),wt=xt[0],$t=xt[1],Mt=yvt(C,{value:_}),rt=xh(Mt,2),qe=rt[0],vt=rt[1],kt=J.useMemo(function(){var gr=qe==null?[]:Array.isArray(qe)?qe:[qe],ce=xh(gr,1),fr=ce[0],Yt=fr===void 0?fe:fr,Lr=qe===null?[]:[Yt];if(P){if(Lr=lP(gr),x||qe===void 0){var Cr=x>=0?x+1:2;for(Lr=Lr.slice(0,Cr);Lr.length<Cr;){var zr;Lr.push((zr=Lr[Lr.length-1])!==null&&zr!==void 0?zr:fe)}}Lr.sort(function(fi,to){return fi-to})}return Lr.forEach(function(fi,to){Lr[to]=wt(fi)}),Lr},[qe,P,fe,x,wt]),Xe=J.useRef(kt);Xe.current=kt;var _t=function(ce){return P?ce:ce[0]},Ht=function(ce){var fr=lP(ce).sort(function(Yt,Lr){return Yt-Lr});E&&!Cvt(fr,Xe.current,!0)&&E(_t(fr)),vt(fr)},Pt=function(){var ce=_t(Xe.current);R==null||R(ce),IV(!R,"[rc-slider] `onAfterChange` is deprecated. Please use `onChangeComplete` instead."),M==null||M(ce)},Jt=kvt(ve,pe,kt,fe,me,wt,Ht,Pt,$t),zt=xh(Jt,4),Bt=zt[0],Mr=zt[1],Be=zt[2],We=zt[3],dt=function(ce,fr){if(!u){var Yt=0,Lr=me-fe;kt.forEach(function(to,st){var zo=Math.abs(ce-to);zo<=Lr&&(Lr=zo,Yt=st)});var Cr=lP(kt);if(Cr[Yt]=ce,P&&!kt.length&&x===void 0&&Cr.push(ce),A==null||A(_t(Cr)),Ht(Cr),fr){var zr,fi;(zr=document.activeElement)===null||zr===void 0||(fi=zr.blur)===null||fi===void 0||fi.call(zr),Ne.current.focus(Yt),We(fr,Yt,Cr)}}},Tt=function(ce){ce.preventDefault();var fr=ve.current.getBoundingClientRect(),Yt=fr.width,Lr=fr.height,Cr=fr.left,zr=fr.top,fi=fr.bottom,to=fr.right,st=ce.clientX,zo=ce.clientY,hi;switch(pe){case"btt":hi=(fi-zo)/Lr;break;case"ttb":hi=(zo-zr)/Lr;break;case"rtl":hi=(to-st)/Yt;break;default:hi=(st-Cr)/Yt}var si=fe+hi*(me-fe);dt(wt(si),ce)},nr=J.useState(null),Ar=xh(nr,2),Qr=Ar[0],Si=Ar[1],oi=function(ce,fr){if(!u){var Yt=$t(kt,ce,fr);A==null||A(_t(kt)),Ht(Yt.values),Si(Yt.value)}};J.useEffect(function(){if(Qr!==null){var gr=kt.indexOf(Qr);gr>=0&&Ne.current.focus(gr)}Si(null)},[Qr]);var Yr=J.useMemo(function(){return z&&Ce===null?!1:z},[z,Ce]),vi=function(ce,fr){We(ce,fr),A==null||A(_t(Xe.current))},rr=Bt!==-1;J.useEffect(function(){if(!rr){var gr=kt.lastIndexOf(Mr);Ne.current.focus(gr)}},[rr]);var Ji=J.useMemo(function(){return lP(Be).sort(function(gr,ce){return gr-ce})},[Be]),qn=J.useMemo(function(){return P?[Ji[0],Ji[Ji.length-1]]:[fe,Ji[0]]},[Ji,P,fe]),ri=xh(qn,2),eo=ri[0],xn=ri[1];J.useImperativeHandle(e,function(){return{focus:function(){Ne.current.focus(0)},blur:function(){var ce,fr=document,Yt=fr.activeElement;(ce=ve.current)!==null&&ce!==void 0&&ce.contains(Yt)&&(Yt==null||Yt.blur())}}}),J.useEffect(function(){f&&Ne.current.focus(0)},[]);var mt=J.useMemo(function(){return{min:fe,max:me,direction:pe,disabled:u,keyboard:d,step:Ce,included:k,includedStart:eo,includedEnd:xn,range:P,tabIndex:we,ariaLabelForHandle:Te,ariaLabelledByForHandle:ke,ariaValueTextFormatterForHandle:$e,styles:s||{},classNames:a||{}}},[fe,me,pe,u,d,Ce,k,eo,xn,P,we,Te,ke,$e,s,a]);return J.createElement(qD.Provider,{value:mt},J.createElement("div",{ref:ve,className:hm(n,r,Ev(Ev(Ev(Ev({},"".concat(n,"-disabled"),u),"".concat(n,"-vertical"),H),"".concat(n,"-horizontal"),!H),"".concat(n,"-with-marks"),Qe.length)),style:o,onMouseDown:Tt},J.createElement("div",{className:hm("".concat(n,"-rail"),a==null?void 0:a.rail),style:jd(jd({},te),s==null?void 0:s.rail)}),J.createElement(Rvt,{prefixCls:n,style:W,values:Ji,startPoint:X,onStartMove:Yr?vi:void 0}),J.createElement(Dvt,{prefixCls:n,marks:Qe,dots:Ee,style:oe,activeStyle:de}),J.createElement(Evt,{ref:Ne,prefixCls:n,style:Y,values:Be,draggingIndex:Bt,onStartMove:vi,onOffsetChange:oi,onFocus:h,onBlur:p,handleRender:Re,activeHandleRender:Ae,onChangeComplete:Pt}),J.createElement(Avt,{prefixCls:n,marks:Qe,onClick:dt})))});class Fvt extends Error{constructor(e,i){super(e),this.originalError=i,this.name="FailedToPlayError"}}class Bvt{constructor(){this.createSession=(e,i,n=1,r=!0)=>{let s,l=r,u=i||0,c=n,d=!1,f=0;function h(v){u=v,d=!0}function p(v){l=v}async function g(v){const y=v.playbackControls.elapsedTimeMs/1e3;if(!l){console.log("Video sync currently disabled");return}v.playbackControls.isClosed?(e.setCurrentTime(0),e.pause()):v.playbackControls.isPaused&&(e!=null&&e.paused()||e.pause());const m=y-u;if(y>u){if(m>e.duration()){e.paused()||(e.setCurrentTime(e.duration()),e.pause());return}const b=e.currentTime();if(e.paused()&&v.playbackControls.isPlaying)try{e.play()}catch(C){throw console.log(C),new Fvt("Could not play video")}const S=Date.now(),_=S-f>=5e3;Math.abs(b-m)>c&&(v.playbackControls.isPlaying&&!d&&_?(console.log(`Aligning video with stream at ${S}ms: ${b} =>  ${m}. Allowed drift is ${c}`),e.setCurrentTime(m),e.play(),f=S,c=Math.min(1,Math.abs(c)+.05)):v.playbackControls.isPaused&&!d&&_&&(e.setCurrentTime(m),f=S))}else u>y&&(e.paused()||e.pause(),console.log(`Video not be started until ${y-u}   secs`));return d=!1,{expectedSecsIntoVideo:m,streamAndVideoOffsetSecs:m-e.currentTime(),videoPlayerCurrentTimeSecs:e.currentTime()?e.currentTime():0,isVideoPlaying:!e.paused(),hasVideoEnded:m>e.duration(),isVideoSynced:u!==void 0,currentOffset:u,videoLengthSeconds:e.duration(),problemDescription:s,currentMaxDriftSeconds:c,recordingElapsedTime:y}}return{syncVideoWithRecording:g,enable:p,setVideoOffsetSeconds:h}}}}var iS=(t=>(t.PLAYBACK_PLAYING="PLAYBACK_PLAYING",t.PLAYBACK_PAUSED="PLAYBACK_PAUSED",t.PLAYBACK_CLOSED="PLAYBACK_CLOSED",t))(iS||{}),ea=(t=>(t.FILE_TYPE_UNKNOWN="FILE_TYPE_UNKNOWN",t.FILE_TYPE_FOLDER="FILE_TYPE_FOLDER",t.FILE_TYPE_VIDEO="FILE_TYPE_VIDEO",t.FILE_TYPE_AUDIO="FILE_TYPE_AUDIO",t.FILE_TYPE_IMAGE="FILE_TYPE_IMAGE",t.FILE_TYPE_RECORDING="FILE_TYPE_RECORDING",t.FILE_TYPE_RECORDING_SESSION="FILE_TYPE_RECORDING_SESSION",t.FILE_TYPE_RECORDING_MAPPING="FILE_TYPE_RECORDING_MAPPING",t.FILE_TYPE_PLATFORM="FILE_TYPE_PLATFORM",t.FILE_TYPE_INSTANCE="FILE_TYPE_INSTANCE",t.FILE_TYPE_SIGNAL_DATABASE="FILE_TYPE_SIGNAL_DATABASE",t))(ea||{});class yke{constructor(e,i){this.recordingSessionInfoCache=new Map,this.accumulatedPlaybackStatuses=new Map,this.open=async n=>{await this.filesClient.fetchSessionInfo(n),await this.playbackClient.open(n)},this.subscribeToRecordingSessionPlaybacks=async(n,r,o,a,s)=>{const l=async c=>{const d=c.items??[],f=this.processStatusUpdates(d,r);await this.fetchSessionInfoForNewPaths(f,a),this.notifyPlaybackUpdates(d,n)},u=c=>{console.log("Playback stream error, clearing accumulated state",c),o(),this.accumulatedPlaybackStatuses.clear(),this.recordingSessionInfoCache.clear()};try{await this.playbackClient.subscribeToPlaybackStatuses(l,u,s)}catch(c){a("Playback stream failed",c)}},this.stopPlaybackStatusStream=async()=>{await this.playbackClient.stopPlaybackStatusStream(),this.accumulatedPlaybackStatuses.clear(),this.recordingSessionInfoCache.clear()},this.playbackClient=e,this.filesClient=i}processStatusUpdates(e,i){const n=[];return e.forEach(r=>{r.mode===iS.PLAYBACK_CLOSED?this.handleClosedPlayback(r.path,i):this.updateAccumulatedStatus(r)&&n.push(r.path)}),n}handleClosedPlayback(e,i){console.log("Recording session closed via PLAYBACK_CLOSED event:",e),this.accumulatedPlaybackStatuses.delete(e),this.recordingSessionInfoCache.delete(e),i(e)}updateAccumulatedStatus(e){const i=!this.accumulatedPlaybackStatuses.has(e.path);return this.accumulatedPlaybackStatuses.set(e.path,e),i}async fetchSessionInfoForNewPaths(e,i){if(e.length===0)return;console.log("Fetching info for new paths:",e),(await Promise.allSettled(e.map(r=>this.filesClient.fetchSessionInfo(r)))).forEach((r,o)=>{const a=e[o];r.status==="fulfilled"?this.recordingSessionInfoCache.set(a,r.value):i(a,r.reason)})}notifyPlaybackUpdates(e,i){e.forEach(n=>{if(n.mode===iS.PLAYBACK_CLOSED)return;const r=this.createPlaybackObjectFromCache(n.path);r&&i(n.path,r)})}createPlaybackObjectFromCache(e){const i=this.accumulatedPlaybackStatuses.get(e),n=this.recordingSessionInfoCache.get(e);if(!(!i||!n))return this.createPlaybackObject(i,n)}createPlaybackObject(e,i){var a,s;if(e===void 0||i===void 0)return;const o={play:async()=>{e.elapsedTimeMs>=i.durationMs?(await this.playbackClient.seek(e.path,0),await this.playbackClient.play(e.path)):await this.playbackClient.play(e.path)},setRepeat:async(l,u,c)=>{l?u===void 0&&c===void 0?await this.playbackClient.repeatEntireRecording(e.path):await this.playbackClient.repeatWithOffset(e.path,u?u*1e3:void 0,c?c*1e3:void 0):await this.playbackClient.stopRepeat(e.path)},pause:async()=>{await this.playbackClient.pause(e.path)},restart:async()=>{await this.playbackClient.seek(e.path,0)},close:async()=>{await this.playbackClient.close(e.path)},seek:async l=>{await this.playbackClient.seek(e.path,l*1e3)},isPlaying:e.mode===iS.PLAYBACK_PLAYING,isPaused:e.mode===iS.PLAYBACK_PAUSED,isClosed:e.mode===iS.PLAYBACK_CLOSED,elapsedTimeMs:e.elapsedTimeMs,durationMs:i.durationMs,repeat:{isRepeating:!!e.repeat,startMs:(a=e.repeat)!=null&&a.startOffset?e.repeat.startOffset/1e3:void 0,endMs:(s=e.repeat)!=null&&s.endOffset?e.repeat.endOffset/1e3:void 0}};return{recordingSessionInfo:i,playbackControls:o}}}class jvt{constructor(e){this.listFiles=async(i="/",n=!1,r)=>this.filesClient.listFiles(i,n,r),this.filesClient=e}}//! @version @js-joda/core - 5.6.5
//! @copyright (c) 2015-present, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
//! @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
//! @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */function XD(t,e,i){i===void 0&&(i=Error);function n(r){Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=r,e&&e.apply(this,arguments),this.toString=function(){return this.name+": "+this.message}}return n.prototype=Object.create(i.prototype),n.prototype.name=t,n.prototype.constructor=n,n}var ai=XD("DateTimeException",Vvt),Pv=XD("DateTimeParseException",Hvt),Qn=XD("UnsupportedTemporalTypeException",null,ai),mv=XD("ArithmeticException"),Pi=XD("IllegalArgumentException"),E3=XD("IllegalStateException"),hS=XD("NullPointerException");function Vvt(t,e){e===void 0&&(e=null);var i=t||this.name;e!==null&&e instanceof Error&&(i+=`
-------
Caused by: `+e.stack+`
-------
`),this.message=i}function Hvt(t,e,i,n){e===void 0&&(e=""),i===void 0&&(i=0),n===void 0&&(n=null);var r=t||this.name;r+=": "+e+", at index: "+i,n!==null&&n instanceof Error&&(r+=`
-------
Caused by: `+n.stack+`
-------
`),this.message=r,this.parsedString=function(){return e},this.errorIndex=function(){return i}}function yn(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,TZ(t,e)}function TZ(t,e){return TZ=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,r){return n.__proto__=r,n},TZ(t,e)}function w3(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */function ha(t,e,i){if(!t)throw i?new i(e):new Error(e)}function yt(t,e){if(t==null)throw new hS(e+" must not be null");return t}function _i(t,e,i){if(!(t instanceof e))throw new Pi(i+" must be an instance of "+(e.name?e.name:e)+(t&&t.constructor&&t.constructor.name?", but is "+t.constructor.name:""));return t}function Hi(t){throw new TypeError('abstract method "'+t+'" is not implemented')}var Uvt=Object.freeze({__proto__:null,abstractMethodFail:Hi,assert:ha,requireInstance:_i,requireNonNull:yt});/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var hv=9007199254740991,bp=-9007199254740991,Ze=(function(){function t(){}return t.intDiv=function(i,n){var r=i/n;return r=t.roundDown(r),t.safeZero(r)},t.intMod=function(i,n){var r=i-t.intDiv(i,n)*n;return r=t.roundDown(r),t.safeZero(r)},t.roundDown=function(i){return i<0?Math.ceil(i):Math.floor(i)},t.floorDiv=function(i,n){var r=Math.floor(i/n);return t.safeZero(r)},t.floorMod=function(i,n){var r=i-t.floorDiv(i,n)*n;return t.safeZero(r)},t.safeAdd=function(i,n){if(t.verifyInt(i),t.verifyInt(n),i===0)return t.safeZero(n);if(n===0)return t.safeZero(i);var r=t.safeToInt(i+n);if(r===i||r===n)throw new mv("Invalid addition beyond MAX_SAFE_INTEGER!");return r},t.safeSubtract=function(i,n){return t.verifyInt(i),t.verifyInt(n),i===0&&n===0?0:i===0?t.safeZero(-1*n):n===0?t.safeZero(i):t.safeToInt(i-n)},t.safeMultiply=function(i,n){if(t.verifyInt(i),t.verifyInt(n),i===1)return t.safeZero(n);if(n===1)return t.safeZero(i);if(i===0||n===0)return 0;var r=t.safeToInt(i*n);if(r/n!==i||i===bp&&n===-1||n===bp&&i===-1)throw new mv("Multiplication overflows: "+i+" * "+n);return r},t.parseInt=(function(e){function i(n){return e.apply(this,arguments)}return i.toString=function(){return e.toString()},i})(function(e){var i=parseInt(e);return t.safeToInt(i)}),t.safeToInt=function(i){return t.verifyInt(i),t.safeZero(i)},t.verifyInt=function(i){if(i==null)throw new mv("Invalid value: '"+i+"', using null or undefined as argument");if(isNaN(i))throw new mv("Invalid int value, using NaN as argument");if(Number.isInteger){if(!Number.isInteger(Number(i)))throw new mv("Invalid value: '"+i+"' is a float")}else if(i%1!==0)throw new mv("Invalid value: '"+i+"' is a float");if(i>hv||i<bp)throw new mv("Calculation overflows an int: "+i)},t.safeZero=function(i){return i===0?0:+i},t.compareNumbers=function(i,n){return i<n?-1:i>n?1:0},t.smi=function(i){return i>>>1&1073741824|i&3221225471},t.hash=function(i){if(i!==i||i===1/0)return 0;for(var n=i;i>4294967295;)i/=4294967295,n^=i;return t.smi(n)},t.hashCode=function(){for(var i=17,n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];for(var a=0,s=r;a<s.length;a++){var l=s[a];i=(i<<5)-i+t.hash(l)}return t.hash(i)},t})();Ze.MAX_SAFE_INTEGER=hv;Ze.MIN_SAFE_INTEGER=bp;/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var mI=(function(){function t(i){this._name=i}var e=t.prototype;return e.equals=function(n){return this===n},e.toString=function(){return this._name},e.toJSON=function(){return this.toString()},t})();/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var MD=(function(){function t(){}var e=t.prototype;return e.get=function(n){Hi("get")},e.units=function(){Hi("units")},e.addTo=function(n){Hi("addTo")},e.subtractFrom=function(n){Hi("subtractFrom")},t})();typeof Symbol<"u"&&Symbol.toPrimitive&&(MD.prototype[Symbol.toPrimitive]=function(t){if(t!=="number")return this.toString();throw new TypeError("A conversion from TemporalAmount to a number is not allowed. To compare use the methods .equals(), .compareTo(), .isBefore() or one that is more suitable to your use case.")});/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var AS=(function(){function t(){}var e=t.prototype;return e.duration=function(){Hi("duration")},e.isDurationEstimated=function(){Hi("isDurationEstimated")},e.isDateBased=function(){Hi("isDateBased")},e.isTimeBased=function(){Hi("isTimeBased")},e.isSupportedBy=function(n){Hi("isSupportedBy")},e.addTo=function(n,r){Hi("addTo")},e.between=function(n,r){Hi("between")},t})(),fl=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._seconds=Ze.safeToInt(n),o._nanos=Ze.safeToInt(r),o}e.ofDays=function(r){return e._create(Ze.safeMultiply(r,Zt.SECONDS_PER_DAY),0)},e.ofHours=function(r){return e._create(Ze.safeMultiply(r,Zt.SECONDS_PER_HOUR),0)},e.ofMinutes=function(r){return e._create(Ze.safeMultiply(r,Zt.SECONDS_PER_MINUTE),0)},e.ofSeconds=function(r,o){o===void 0&&(o=0);var a=Ze.safeAdd(r,Ze.floorDiv(o,Zt.NANOS_PER_SECOND)),s=Ze.floorMod(o,Zt.NANOS_PER_SECOND);return e._create(a,s)},e.ofMillis=function(r){var o=Ze.intDiv(r,1e3),a=Ze.intMod(r,1e3);return a<0&&(a+=1e3,o--),e._create(o,a*1e6)},e.ofNanos=function(r){var o=Ze.intDiv(r,Zt.NANOS_PER_SECOND),a=Ze.intMod(r,Zt.NANOS_PER_SECOND);return a<0&&(a+=Zt.NANOS_PER_SECOND,o--),this._create(o,a)},e.of=function(r,o){return e.ZERO.plus(r,o)},e.from=function(r){yt(r,"amount"),_i(r,MD);var o=e.ZERO;return r.units().forEach(function(a){o=o.plus(r.get(a),a)}),o},e.between=function(r,o){yt(r,"startInclusive"),yt(o,"endExclusive");var a=r.until(o,ft.SECONDS),s=0;if(r.isSupported(Me.NANO_OF_SECOND)&&o.isSupported(Me.NANO_OF_SECOND))try{var l=r.getLong(Me.NANO_OF_SECOND);if(s=o.getLong(Me.NANO_OF_SECOND)-l,a>0&&s<0)s+=Zt.NANOS_PER_SECOND;else if(a<0&&s>0)s-=Zt.NANOS_PER_SECOND;else if(a===0&&s!==0){var u=o.with(Me.NANO_OF_SECOND,l);a=r.until(u,ft.SECONDS)}}catch{}return this.ofSeconds(a,s)},e.parse=function(r){yt(r,"text");var o=new RegExp("([-+]?)P(?:([-+]?[0-9]+)D)?(T(?:([-+]?[0-9]+)H)?(?:([-+]?[0-9]+)M)?(?:([-+]?[0-9]+)(?:[.,]([0-9]{0,9}))?S)?)?","i"),a=o.exec(r);if(a!==null&&a[3]!=="T"){var s=a[1]==="-",l=a[2],u=a[4],c=a[5],d=a[6],f=a[7];if(l!=null||u!=null||c!=null||d!=null){var h=e._parseNumber(r,l,Zt.SECONDS_PER_DAY,"days"),p=e._parseNumber(r,u,Zt.SECONDS_PER_HOUR,"hours"),g=e._parseNumber(r,c,Zt.SECONDS_PER_MINUTE,"minutes"),v=e._parseNumber(r,d,1,"seconds"),y=d!=null&&d.charAt(0)==="-",m=e._parseFraction(r,f,y?-1:1);try{return e._create(s,h,p,g,v,m)}catch(b){throw new Pv("Text cannot be parsed to a Duration: overflow",r,0,b)}}}throw new Pv("Text cannot be parsed to a Duration",r,0)},e._parseNumber=function(r,o,a,s){if(o==null)return 0;try{return o[0]==="+"&&(o=o.substring(1)),Ze.safeMultiply(parseFloat(o),a)}catch(l){throw new Pv("Text cannot be parsed to a Duration: "+s,r,0,l)}},e._parseFraction=function(r,o,a){return o==null||o.length===0?0:(o=(o+"000000000").substring(0,9),parseFloat(o)*a)},e._create=function(){return arguments.length<=2?e._createSecondsNanos(arguments[0],arguments[1]):e._createNegateDaysHoursMinutesSecondsNanos(arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5])},e._createNegateDaysHoursMinutesSecondsNanos=function(r,o,a,s,l,u){var c=Ze.safeAdd(o,Ze.safeAdd(a,Ze.safeAdd(s,l)));return r?e.ofSeconds(c,u).negated():e.ofSeconds(c,u)},e._createSecondsNanos=function(r,o){return r===void 0&&(r=0),o===void 0&&(o=0),r===0&&o===0?e.ZERO:new e(r,o)};var i=e.prototype;return i.get=function(r){if(r===ft.SECONDS)return this._seconds;if(r===ft.NANOS)return this._nanos;throw new Qn("Unsupported unit: "+r)},i.units=function(){return[ft.SECONDS,ft.NANOS]},i.isZero=function(){return this._seconds===0&&this._nanos===0},i.isNegative=function(){return this._seconds<0},i.seconds=function(){return this._seconds},i.nano=function(){return this._nanos},i.withSeconds=function(r){return e._create(r,this._nanos)},i.withNanos=function(r){return Me.NANO_OF_SECOND.checkValidIntValue(r),e._create(this._seconds,r)},i.plusDuration=function(r){return yt(r,"duration"),this.plus(r.seconds(),r.nano())},i.plus=function(r,o){return arguments.length===1?this.plusDuration(r):arguments.length===2&&o instanceof AS?this.plusAmountUnit(r,o):this.plusSecondsNanos(r,o)},i.plusAmountUnit=function(r,o){if(yt(r,"amountToAdd"),yt(o,"unit"),o===ft.DAYS)return this.plusSecondsNanos(Ze.safeMultiply(r,Zt.SECONDS_PER_DAY),0);if(o.isDurationEstimated())throw new Qn("Unit must not have an estimated duration");if(r===0)return this;if(o instanceof ft){switch(o){case ft.NANOS:return this.plusNanos(r);case ft.MICROS:return this.plusSecondsNanos(Ze.intDiv(r,1e6*1e3)*1e3,Ze.intMod(r,1e6*1e3)*1e3);case ft.MILLIS:return this.plusMillis(r);case ft.SECONDS:return this.plusSeconds(r)}return this.plusSecondsNanos(Ze.safeMultiply(o.duration().seconds(),r),0)}var a=o.duration().multipliedBy(r);return this.plusSecondsNanos(a.seconds(),a.nano())},i.plusDays=function(r){return this.plusSecondsNanos(Ze.safeMultiply(r,Zt.SECONDS_PER_DAY),0)},i.plusHours=function(r){return this.plusSecondsNanos(Ze.safeMultiply(r,Zt.SECONDS_PER_HOUR),0)},i.plusMinutes=function(r){return this.plusSecondsNanos(Ze.safeMultiply(r,Zt.SECONDS_PER_MINUTE),0)},i.plusSeconds=function(r){return this.plusSecondsNanos(r,0)},i.plusMillis=function(r){return this.plusSecondsNanos(Ze.intDiv(r,1e3),Ze.intMod(r,1e3)*1e6)},i.plusNanos=function(r){return this.plusSecondsNanos(0,r)},i.plusSecondsNanos=function(r,o){if(yt(r,"secondsToAdd"),yt(o,"nanosToAdd"),r===0&&o===0)return this;var a=Ze.safeAdd(this._seconds,r);a=Ze.safeAdd(a,Ze.intDiv(o,Zt.NANOS_PER_SECOND)),o=Ze.intMod(o,Zt.NANOS_PER_SECOND);var s=Ze.safeAdd(this._nanos,o);return e.ofSeconds(a,s)},i.minus=function(r,o){return arguments.length===1?this.minusDuration(r):this.minusAmountUnit(r,o)},i.minusDuration=function(r){yt(r,"duration");var o=r.seconds(),a=r.nano();return o===bp?this.plus(hv,-a):this.plus(-o,-a)},i.minusAmountUnit=function(r,o){return yt(r,"amountToSubtract"),yt(o,"unit"),r===bp?this.plusAmountUnit(hv,o):this.plusAmountUnit(-r,o)},i.minusDays=function(r){return r===bp?this.plusDays(hv):this.plusDays(-r)},i.minusHours=function(r){return r===bp?this.plusHours(hv):this.plusHours(-r)},i.minusMinutes=function(r){return r===bp?this.plusMinutes(hv):this.plusMinutes(-r)},i.minusSeconds=function(r){return r===bp?this.plusSeconds(hv):this.plusSeconds(-r)},i.minusMillis=function(r){return r===bp?this.plusMillis(hv):this.plusMillis(-r)},i.minusNanos=function(r){return r===bp?this.plusNanos(hv):this.plusNanos(-r)},i.multipliedBy=function(r){if(r===0)return e.ZERO;if(r===1)return this;var o=Ze.safeMultiply(this._seconds,r),a=Ze.safeMultiply(this._nanos,r);return o=o+Ze.intDiv(a,Zt.NANOS_PER_SECOND),a=Ze.intMod(a,Zt.NANOS_PER_SECOND),e.ofSeconds(o,a)},i.dividedBy=function(r){if(r===0)throw new mv("Cannot divide by zero");if(r===1)return this;var o=Ze.intDiv(this._seconds,r),a=Ze.roundDown((this._seconds/r-o)*Zt.NANOS_PER_SECOND),s=Ze.intDiv(this._nanos,r);return s=a+s,e.ofSeconds(o,s)},i.negated=function(){return this.multipliedBy(-1)},i.abs=function(){return this.isNegative()?this.negated():this},i.addTo=function(r){return yt(r,"temporal"),this._seconds!==0&&(r=r.plus(this._seconds,ft.SECONDS)),this._nanos!==0&&(r=r.plus(this._nanos,ft.NANOS)),r},i.subtractFrom=function(r){return yt(r,"temporal"),this._seconds!==0&&(r=r.minus(this._seconds,ft.SECONDS)),this._nanos!==0&&(r=r.minus(this._nanos,ft.NANOS)),r},i.toDays=function(){return Ze.intDiv(this._seconds,Zt.SECONDS_PER_DAY)},i.toHours=function(){return Ze.intDiv(this._seconds,Zt.SECONDS_PER_HOUR)},i.toMinutes=function(){return Ze.intDiv(this._seconds,Zt.SECONDS_PER_MINUTE)},i.toMillis=function(){var r=Math.round(Ze.safeMultiply(this._seconds,1e3));return r=Ze.safeAdd(r,Ze.intDiv(this._nanos,1e6)),r},i.toNanos=function(){var r=Ze.safeMultiply(this._seconds,Zt.NANOS_PER_SECOND);return r=Ze.safeAdd(r,this._nanos),r},i.compareTo=function(r){yt(r,"otherDuration"),_i(r,e,"otherDuration");var o=Ze.compareNumbers(this._seconds,r.seconds());return o!==0?o:this._nanos-r.nano()},i.equals=function(r){return this===r?!0:r instanceof e?this.seconds()===r.seconds()&&this.nano()===r.nano():!1},i.toString=function(){if(this===e.ZERO)return"PT0S";var r=Ze.intDiv(this._seconds,Zt.SECONDS_PER_HOUR),o=Ze.intDiv(Ze.intMod(this._seconds,Zt.SECONDS_PER_HOUR),Zt.SECONDS_PER_MINUTE),a=Ze.intMod(this._seconds,Zt.SECONDS_PER_MINUTE),s="PT";if(r!==0&&(s+=r+"H"),o!==0&&(s+=o+"M"),a===0&&this._nanos===0&&s.length>2)return s;if(a<0&&this._nanos>0?a===-1?s+="-0":s+=a+1:s+=a,this._nanos>0){s+=".";var l;for(a<0?l=""+(2*Zt.NANOS_PER_SECOND-this._nanos):l=""+(Zt.NANOS_PER_SECOND+this._nanos),l=l.slice(1,l.length),s+=l;s.charAt(s.length-1)==="0";)s=s.slice(0,s.length-1)}return s+="S",s},i.toJSON=function(){return this.toString()},e})(MD);function zvt(){fl.ZERO=new fl(0,0)}/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE.md in the root directory of this source tree)
 */var Eh=function(){};function $vt(){Eh.MIN_VALUE=-999999,Eh.MAX_VALUE=999999}var ft=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._name=n,o._duration=r,o}var i=e.prototype;return i.duration=function(){return this._duration},i.isDurationEstimated=function(){return this.isDateBased()||this===e.FOREVER},i.isDateBased=function(){return this.compareTo(e.DAYS)>=0&&this!==e.FOREVER},i.isTimeBased=function(){return this.compareTo(e.DAYS)<0},i.isSupportedBy=function(r){if(this===e.FOREVER)return!1;try{return r.plus(1,this),!0}catch{try{return r.plus(-1,this),!0}catch{return!1}}},i.addTo=function(r,o){return r.plus(o,this)},i.between=function(r,o){return r.until(o,this)},i.toString=function(){return this._name},i.compareTo=function(r){return this.duration().compareTo(r.duration())},e})(AS);function Wvt(){ft.NANOS=new ft("Nanos",fl.ofNanos(1)),ft.MICROS=new ft("Micros",fl.ofNanos(1e3)),ft.MILLIS=new ft("Millis",fl.ofNanos(1e6)),ft.SECONDS=new ft("Seconds",fl.ofSeconds(1)),ft.MINUTES=new ft("Minutes",fl.ofSeconds(60)),ft.HOURS=new ft("Hours",fl.ofSeconds(3600)),ft.HALF_DAYS=new ft("HalfDays",fl.ofSeconds(43200)),ft.DAYS=new ft("Days",fl.ofSeconds(86400)),ft.WEEKS=new ft("Weeks",fl.ofSeconds(7*86400)),ft.MONTHS=new ft("Months",fl.ofSeconds(31556952/12)),ft.YEARS=new ft("Years",fl.ofSeconds(31556952)),ft.DECADES=new ft("Decades",fl.ofSeconds(31556952*10)),ft.CENTURIES=new ft("Centuries",fl.ofSeconds(31556952*100)),ft.MILLENNIA=new ft("Millennia",fl.ofSeconds(31556952*1e3)),ft.ERAS=new ft("Eras",fl.ofSeconds(31556952*(Eh.MAX_VALUE+1))),ft.FOREVER=new ft("Forever",fl.ofSeconds(Ze.MAX_SAFE_INTEGER,999999999))}/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Ky=(function(){function t(){}var e=t.prototype;return e.isDateBased=function(){Hi("isDateBased")},e.isTimeBased=function(){Hi("isTimeBased")},e.baseUnit=function(){Hi("baseUnit")},e.rangeUnit=function(){Hi("rangeUnit")},e.range=function(){Hi("range")},e.rangeRefinedBy=function(n){Hi("rangeRefinedBy")},e.getFrom=function(n){Hi("getFrom")},e.adjustInto=function(n,r){Hi("adjustInto")},e.isSupportedBy=function(n){Hi("isSupportedBy")},e.displayName=function(){Hi("displayName")},e.equals=function(n){Hi("equals")},e.name=function(){Hi("name")},t})();/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var dn=(function(){function t(i,n,r,o){ha(!(i>n),"Smallest minimum value '"+i+"' must be less than largest minimum value '"+n+"'",Pi),ha(!(r>o),"Smallest maximum value '"+r+"' must be less than largest maximum value '"+o+"'",Pi),ha(!(n>o),"Minimum value '"+n+"' must be less than maximum value '"+o+"'",Pi),this._minSmallest=i,this._minLargest=n,this._maxLargest=o,this._maxSmallest=r}var e=t.prototype;return e.isFixed=function(){return this._minSmallest===this._minLargest&&this._maxSmallest===this._maxLargest},e.minimum=function(){return this._minSmallest},e.largestMinimum=function(){return this._minLargest},e.maximum=function(){return this._maxLargest},e.smallestMaximum=function(){return this._maxSmallest},e.isValidValue=function(n){return this.minimum()<=n&&n<=this.maximum()},e.checkValidValue=function(n,r){var o;return this.isValidValue(n)?n:(r!=null?o="Invalid value for "+r+" (valid values "+this.toString()+"): "+n:o="Invalid value (valid values "+this.toString()+"): "+n,ha(!1,o,ai))},e.checkValidIntValue=function(n,r){if(this.isValidIntValue(n)===!1)throw new ai("Invalid int value for "+r+": "+n);return n},e.isValidIntValue=function(n){return this.isIntValue()&&this.isValidValue(n)},e.isIntValue=function(){return this.minimum()>=Ze.MIN_SAFE_INTEGER&&this.maximum()<=Ze.MAX_SAFE_INTEGER},e.equals=function(n){return n===this?!0:n instanceof t?this._minSmallest===n._minSmallest&&this._minLargest===n._minLargest&&this._maxSmallest===n._maxSmallest&&this._maxLargest===n._maxLargest:!1},e.hashCode=function(){return Ze.hashCode(this._minSmallest,this._minLargest,this._maxSmallest,this._maxLargest)},e.toString=function(){var n=this.minimum()+(this.minimum()!==this.largestMinimum()?"/"+this.largestMinimum():"");return n+=" - ",n+=this.smallestMaximum()+(this.smallestMaximum()!==this.maximum()?"/"+this.maximum():""),n},t.of=function(){return arguments.length===2?new t(arguments[0],arguments[0],arguments[1],arguments[1]):arguments.length===3?new t(arguments[0],arguments[0],arguments[1],arguments[2]):arguments.length===4?new t(arguments[0],arguments[1],arguments[2],arguments[3]):ha(!1,"Invalid number of arguments "+arguments.length,Pi)},t})(),Me=(function(t){yn(e,t),e.byName=function(r){for(var o in e)if(e[o]&&e[o]instanceof e&&e[o].name()===r)return e[o]};function e(n,r,o,a){var s;return s=t.call(this)||this,s._name=n,s._baseUnit=r,s._rangeUnit=o,s._range=a,s}var i=e.prototype;return i.name=function(){return this._name},i.baseUnit=function(){return this._baseUnit},i.rangeUnit=function(){return this._rangeUnit},i.range=function(){return this._range},i.displayName=function(){return this.toString()},i.checkValidValue=function(r){return this.range().checkValidValue(r,this)},i.checkValidIntValue=function(r){return this.range().checkValidIntValue(r,this)},i.isDateBased=function(){var r=this===e.DAY_OF_WEEK||this===e.ALIGNED_DAY_OF_WEEK_IN_MONTH||this===e.ALIGNED_DAY_OF_WEEK_IN_YEAR||this===e.DAY_OF_MONTH||this===e.DAY_OF_YEAR||this===e.EPOCH_DAY||this===e.ALIGNED_WEEK_OF_MONTH||this===e.ALIGNED_WEEK_OF_YEAR||this===e.MONTH_OF_YEAR||this===e.PROLEPTIC_MONTH||this===e.YEAR_OF_ERA||this===e.YEAR||this===e.ERA;return r},i.isTimeBased=function(){var r=this===e.NANO_OF_SECOND||this===e.NANO_OF_DAY||this===e.MICRO_OF_SECOND||this===e.MICRO_OF_DAY||this===e.MILLI_OF_SECOND||this===e.MILLI_OF_DAY||this===e.SECOND_OF_MINUTE||this===e.SECOND_OF_DAY||this===e.MINUTE_OF_HOUR||this===e.MINUTE_OF_DAY||this===e.HOUR_OF_AMPM||this===e.CLOCK_HOUR_OF_AMPM||this===e.HOUR_OF_DAY||this===e.CLOCK_HOUR_OF_DAY||this===e.AMPM_OF_DAY;return r},i.rangeRefinedBy=function(r){return r.range(this)},i.getFrom=function(r){return r.getLong(this)},i.toString=function(){return this.name()},i.equals=function(r){return this===r},i.adjustInto=function(r,o){return r.with(this,o)},i.isSupportedBy=function(r){return r.isSupported(this)},e})(Ky);function Gvt(){Me.NANO_OF_SECOND=new Me("NanoOfSecond",ft.NANOS,ft.SECONDS,dn.of(0,999999999)),Me.NANO_OF_DAY=new Me("NanoOfDay",ft.NANOS,ft.DAYS,dn.of(0,86400*1e9-1)),Me.MICRO_OF_SECOND=new Me("MicroOfSecond",ft.MICROS,ft.SECONDS,dn.of(0,999999)),Me.MICRO_OF_DAY=new Me("MicroOfDay",ft.MICROS,ft.DAYS,dn.of(0,86400*1e6-1)),Me.MILLI_OF_SECOND=new Me("MilliOfSecond",ft.MILLIS,ft.SECONDS,dn.of(0,999)),Me.MILLI_OF_DAY=new Me("MilliOfDay",ft.MILLIS,ft.DAYS,dn.of(0,86400*1e3-1)),Me.SECOND_OF_MINUTE=new Me("SecondOfMinute",ft.SECONDS,ft.MINUTES,dn.of(0,59)),Me.SECOND_OF_DAY=new Me("SecondOfDay",ft.SECONDS,ft.DAYS,dn.of(0,86399)),Me.MINUTE_OF_HOUR=new Me("MinuteOfHour",ft.MINUTES,ft.HOURS,dn.of(0,59)),Me.MINUTE_OF_DAY=new Me("MinuteOfDay",ft.MINUTES,ft.DAYS,dn.of(0,1439)),Me.HOUR_OF_AMPM=new Me("HourOfAmPm",ft.HOURS,ft.HALF_DAYS,dn.of(0,11)),Me.CLOCK_HOUR_OF_AMPM=new Me("ClockHourOfAmPm",ft.HOURS,ft.HALF_DAYS,dn.of(1,12)),Me.HOUR_OF_DAY=new Me("HourOfDay",ft.HOURS,ft.DAYS,dn.of(0,23)),Me.CLOCK_HOUR_OF_DAY=new Me("ClockHourOfDay",ft.HOURS,ft.DAYS,dn.of(1,24)),Me.AMPM_OF_DAY=new Me("AmPmOfDay",ft.HALF_DAYS,ft.DAYS,dn.of(0,1)),Me.DAY_OF_WEEK=new Me("DayOfWeek",ft.DAYS,ft.WEEKS,dn.of(1,7)),Me.ALIGNED_DAY_OF_WEEK_IN_MONTH=new Me("AlignedDayOfWeekInMonth",ft.DAYS,ft.WEEKS,dn.of(1,7)),Me.ALIGNED_DAY_OF_WEEK_IN_YEAR=new Me("AlignedDayOfWeekInYear",ft.DAYS,ft.WEEKS,dn.of(1,7)),Me.DAY_OF_MONTH=new Me("DayOfMonth",ft.DAYS,ft.MONTHS,dn.of(1,28,31),"day"),Me.DAY_OF_YEAR=new Me("DayOfYear",ft.DAYS,ft.YEARS,dn.of(1,365,366)),Me.EPOCH_DAY=new Me("EpochDay",ft.DAYS,ft.FOREVER,dn.of(-365961662,364522971)),Me.ALIGNED_WEEK_OF_MONTH=new Me("AlignedWeekOfMonth",ft.WEEKS,ft.MONTHS,dn.of(1,4,5)),Me.ALIGNED_WEEK_OF_YEAR=new Me("AlignedWeekOfYear",ft.WEEKS,ft.YEARS,dn.of(1,53)),Me.MONTH_OF_YEAR=new Me("MonthOfYear",ft.MONTHS,ft.YEARS,dn.of(1,12),"month"),Me.PROLEPTIC_MONTH=new Me("ProlepticMonth",ft.MONTHS,ft.FOREVER,dn.of(Eh.MIN_VALUE*12,Eh.MAX_VALUE*12+11)),Me.YEAR_OF_ERA=new Me("YearOfEra",ft.YEARS,ft.FOREVER,dn.of(1,Eh.MAX_VALUE,Eh.MAX_VALUE+1)),Me.YEAR=new Me("Year",ft.YEARS,ft.FOREVER,dn.of(Eh.MIN_VALUE,Eh.MAX_VALUE),"year"),Me.ERA=new Me("Era",ft.ERAS,ft.FOREVER,dn.of(0,1)),Me.INSTANT_SECONDS=new Me("InstantSeconds",ft.SECONDS,ft.FOREVER,dn.of(bp,hv)),Me.OFFSET_SECONDS=new Me("OffsetSeconds",ft.SECONDS,ft.FOREVER,dn.of(-18*3600,18*3600))}/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Dr=(function(){function t(){}return t.zoneId=function(){return t.ZONE_ID},t.chronology=function(){return t.CHRONO},t.precision=function(){return t.PRECISION},t.zone=function(){return t.ZONE},t.offset=function(){return t.OFFSET},t.localDate=function(){return t.LOCAL_DATE},t.localTime=function(){return t.LOCAL_TIME},t})();/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var xP=(function(){function t(){}var e=t.prototype;return e.query=function(n){return n===Dr.zoneId()||n===Dr.chronology()||n===Dr.precision()?null:n.queryFrom(this)},e.get=function(n){return this.range(n).checkValidIntValue(this.getLong(n),n)},e.getLong=function(n){Hi("getLong")},e.range=function(n){if(n instanceof Me){if(this.isSupported(n))return n.range();throw new Qn("Unsupported field: "+n)}return n.rangeRefinedBy(this)},e.isSupported=function(n){Hi("isSupported")},t})(),NV=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.queryFrom=function(r){Hi("queryFrom")},e})(mI);function Ou(t,e){var i=(function(n){yn(r,n);function r(){return n.apply(this,arguments)||this}return r})(NV);return i.prototype.queryFrom=e,new i(t)}var Wa=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._ordinal=n,o._name=r,o}var i=e.prototype;return i.ordinal=function(){return this._ordinal},i.name=function(){return this._name},e.values=function(){return vL.slice()},e.valueOf=function(r){var o=0;for(o;o<vL.length&&vL[o].name()!==r;o++);return e.of(o+1)},e.of=function(r){if(r<1||r>7)throw new ai("Invalid value for DayOfWeek: "+r);return vL[r-1]},e.from=function(r){if(ha(r!=null,"temporal",hS),r instanceof e)return r;try{return e.of(r.get(Me.DAY_OF_WEEK))}catch(o){throw o instanceof ai?new ai("Unable to obtain DayOfWeek from TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""),o):o}},i.value=function(){return this._ordinal+1},i.displayName=function(r,o){throw new Pi("Pattern using (localized) text not implemented yet!")},i.isSupported=function(r){return r instanceof Me?r===Me.DAY_OF_WEEK:r!=null&&r.isSupportedBy(this)},i.range=function(r){if(r===Me.DAY_OF_WEEK)return r.range();if(r instanceof Me)throw new Qn("Unsupported field: "+r);return r.rangeRefinedBy(this)},i.get=function(r){return r===Me.DAY_OF_WEEK?this.value():this.range(r).checkValidIntValue(this.getLong(r),r)},i.getLong=function(r){if(r===Me.DAY_OF_WEEK)return this.value();if(r instanceof Me)throw new Qn("Unsupported field: "+r);return r.getFrom(this)},i.plus=function(r){var o=Ze.floorMod(r,7);return vL[Ze.floorMod(this._ordinal+(o+7),7)]},i.minus=function(r){return this.plus(-1*Ze.floorMod(r,7))},i.query=function(r){return r===Dr.precision()?ft.DAYS:r===Dr.localDate()||r===Dr.localTime()||r===Dr.chronology()||r===Dr.zone()||r===Dr.zoneId()||r===Dr.offset()?null:(ha(r!=null,"query",hS),r.queryFrom(this))},i.adjustInto=function(r){return yt(r,"temporal"),r.with(Me.DAY_OF_WEEK,this.value())},i.equals=function(r){return this===r},i.toString=function(){return this._name},i.compareTo=function(r){return yt(r,"other"),_i(r,e,"other"),this._ordinal-r._ordinal},i.toJSON=function(){return this.toString()},e})(xP),vL;function Yvt(){Wa.MONDAY=new Wa(0,"MONDAY"),Wa.TUESDAY=new Wa(1,"TUESDAY"),Wa.WEDNESDAY=new Wa(2,"WEDNESDAY"),Wa.THURSDAY=new Wa(3,"THURSDAY"),Wa.FRIDAY=new Wa(4,"FRIDAY"),Wa.SATURDAY=new Wa(5,"SATURDAY"),Wa.SUNDAY=new Wa(6,"SUNDAY"),Wa.FROM=Ou("DayOfWeek.FROM",function(t){return Wa.from(t)}),vL=[Wa.MONDAY,Wa.TUESDAY,Wa.WEDNESDAY,Wa.THURSDAY,Wa.FRIDAY,Wa.SATURDAY,Wa.SUNDAY]}var qi=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._value=Ze.safeToInt(n),o._name=r,o}var i=e.prototype;return i.value=function(){return this._value},i.ordinal=function(){return this._value-1},i.name=function(){return this._name},i.displayName=function(r,o){throw new Pi("Pattern using (localized) text not implemented yet!")},i.isSupported=function(r){return r===null?!1:r instanceof Me?r===Me.MONTH_OF_YEAR:r!=null&&r.isSupportedBy(this)},i.get=function(r){return r===Me.MONTH_OF_YEAR?this.value():this.range(r).checkValidIntValue(this.getLong(r),r)},i.getLong=function(r){if(r===Me.MONTH_OF_YEAR)return this.value();if(r instanceof Me)throw new Qn("Unsupported field: "+r);return r.getFrom(this)},i.plus=function(r){var o=Ze.intMod(r,12)+12,a=Ze.intMod(this.value()+o,12);return a=a===0?12:a,e.of(a)},i.minus=function(r){return this.plus(-1*Ze.intMod(r,12))},i.length=function(r){switch(this){case e.FEBRUARY:return r?29:28;case e.APRIL:case e.JUNE:case e.SEPTEMBER:case e.NOVEMBER:return 30;default:return 31}},i.minLength=function(){switch(this){case e.FEBRUARY:return 28;case e.APRIL:case e.JUNE:case e.SEPTEMBER:case e.NOVEMBER:return 30;default:return 31}},i.maxLength=function(){switch(this){case e.FEBRUARY:return 29;case e.APRIL:case e.JUNE:case e.SEPTEMBER:case e.NOVEMBER:return 30;default:return 31}},i.firstDayOfYear=function(r){var o=r?1:0;switch(this){case e.JANUARY:return 1;case e.FEBRUARY:return 32;case e.MARCH:return 60+o;case e.APRIL:return 91+o;case e.MAY:return 121+o;case e.JUNE:return 152+o;case e.JULY:return 182+o;case e.AUGUST:return 213+o;case e.SEPTEMBER:return 244+o;case e.OCTOBER:return 274+o;case e.NOVEMBER:return 305+o;case e.DECEMBER:default:return 335+o}},i.firstMonthOfQuarter=function(){switch(this){case e.JANUARY:case e.FEBRUARY:case e.MARCH:return e.JANUARY;case e.APRIL:case e.MAY:case e.JUNE:return e.APRIL;case e.JULY:case e.AUGUST:case e.SEPTEMBER:return e.JULY;case e.OCTOBER:case e.NOVEMBER:case e.DECEMBER:default:return e.OCTOBER}},i.query=function(r){return ha(r!=null,"query() parameter must not be null",ai),r===Dr.chronology()?ta.INSTANCE:r===Dr.precision()?ft.MONTHS:t.prototype.query.call(this,r)},i.toString=function(){switch(this){case e.JANUARY:return"JANUARY";case e.FEBRUARY:return"FEBRUARY";case e.MARCH:return"MARCH";case e.APRIL:return"APRIL";case e.MAY:return"MAY";case e.JUNE:return"JUNE";case e.JULY:return"JULY";case e.AUGUST:return"AUGUST";case e.SEPTEMBER:return"SEPTEMBER";case e.OCTOBER:return"OCTOBER";case e.NOVEMBER:return"NOVEMBER";case e.DECEMBER:return"DECEMBER";default:return"unknown Month, value: "+this.value()}},i.toJSON=function(){return this.toString()},i.adjustInto=function(r){return r.with(Me.MONTH_OF_YEAR,this.value())},i.compareTo=function(r){return yt(r,"other"),_i(r,e,"other"),this._value-r._value},i.equals=function(r){return this===r},e.valueOf=function(r){var o=0;for(o;o<aj.length&&aj[o].name()!==r;o++);return e.of(o+1)},e.values=function(){return aj.slice()},e.of=function(r){return(r<1||r>12)&&ha(!1,"Invalid value for MonthOfYear: "+r,ai),aj[r-1]},e.from=function(r){if(r instanceof e)return r;try{return e.of(r.get(Me.MONTH_OF_YEAR))}catch(o){throw new ai("Unable to obtain Month from TemporalAccessor: "+r+" of type "+(r&&r.constructor!=null?r.constructor.name:""),o)}},e})(xP),aj;function qvt(){qi.JANUARY=new qi(1,"JANUARY"),qi.FEBRUARY=new qi(2,"FEBRUARY"),qi.MARCH=new qi(3,"MARCH"),qi.APRIL=new qi(4,"APRIL"),qi.MAY=new qi(5,"MAY"),qi.JUNE=new qi(6,"JUNE"),qi.JULY=new qi(7,"JULY"),qi.AUGUST=new qi(8,"AUGUST"),qi.SEPTEMBER=new qi(9,"SEPTEMBER"),qi.OCTOBER=new qi(10,"OCTOBER"),qi.NOVEMBER=new qi(11,"NOVEMBER"),qi.DECEMBER=new qi(12,"DECEMBER"),aj=[qi.JANUARY,qi.FEBRUARY,qi.MARCH,qi.APRIL,qi.MAY,qi.JUNE,qi.JULY,qi.AUGUST,qi.SEPTEMBER,qi.OCTOBER,qi.NOVEMBER,qi.DECEMBER]}var Xvt=/([-+]?)P(?:([-+]?[0-9]+)Y)?(?:([-+]?[0-9]+)M)?(?:([-+]?[0-9]+)W)?(?:([-+]?[0-9]+)D)?/,nS=(function(t){yn(e,t);function e(n,r,o){var a;a=t.call(this)||this;var s=Ze.safeToInt(n),l=Ze.safeToInt(r),u=Ze.safeToInt(o);return s===0&&l===0&&u===0?(e.ZERO||(a._years=s,a._months=l,a._days=u,e.ZERO=w3(a)),e.ZERO||w3(a)):(a._years=s,a._months=l,a._days=u,a)}e.ofYears=function(r){return e.create(r,0,0)},e.ofMonths=function(r){return e.create(0,r,0)},e.ofWeeks=function(r){return e.create(0,0,Ze.safeMultiply(r,7))},e.ofDays=function(r){return e.create(0,0,r)},e.of=function(r,o,a){return e.create(r,o,a)},e.from=function(r){if(r instanceof e)return r;yt(r,"amount");for(var o=0,a=0,s=0,l=r.units(),u=0;u<l.length;u++){var c=l[u],d=r.get(c);if(c===ft.YEARS)o=Ze.safeToInt(d);else if(c===ft.MONTHS)a=Ze.safeToInt(d);else if(c===ft.DAYS)s=Ze.safeToInt(d);else throw new ai("Unit must be Years, Months or Days, but was "+c)}return e.create(o,a,s)},e.between=function(r,o){return yt(r,"startDate"),yt(o,"endDate"),_i(r,Ci,"startDate"),_i(o,Ci,"endDate"),r.until(o)},e.parse=function(r){yt(r,"text");try{return e._parse(r)}catch(o){throw o instanceof mv?new Pv("Text cannot be parsed to a Period",r,0,o):o}},e._parse=function(r){var o=Xvt.exec(r);if(o!=null){var a=o[1]==="-"?-1:1,s=o[2],l=o[3],u=o[4],c=o[5];if(s!=null||l!=null||u!=null||c!=null){var d=e._parseNumber(r,s,a),f=e._parseNumber(r,l,a),h=e._parseNumber(r,u,a),p=e._parseNumber(r,c,a);return p=Ze.safeAdd(p,Ze.safeMultiply(h,7)),e.create(d,f,p)}}throw new Pv("Text cannot be parsed to a Period",r,0)},e._parseNumber=function(r,o,a){if(o==null)return 0;var s=Ze.parseInt(o);return Ze.safeMultiply(s,a)},e.create=function(r,o,a){return new e(r,o,a)};var i=e.prototype;return i.units=function(){return[ft.YEARS,ft.MONTHS,ft.DAYS]},i.chronology=function(){return ta.INSTANCE},i.get=function(r){if(r===ft.YEARS)return this._years;if(r===ft.MONTHS)return this._months;if(r===ft.DAYS)return this._days;throw new Qn("Unsupported unit: "+r)},i.isZero=function(){return this===e.ZERO},i.isNegative=function(){return this._years<0||this._months<0||this._days<0},i.years=function(){return this._years},i.months=function(){return this._months},i.days=function(){return this._days},i.withYears=function(r){return r===this._years?this:e.create(r,this._months,this._days)},i.withMonths=function(r){return r===this._months?this:e.create(this._years,r,this._days)},i.withDays=function(r){return r===this._days?this:e.create(this._years,this._months,r)},i.plus=function(r){var o=e.from(r);return e.create(Ze.safeAdd(this._years,o._years),Ze.safeAdd(this._months,o._months),Ze.safeAdd(this._days,o._days))},i.plusYears=function(r){return r===0?this:e.create(Ze.safeToInt(Ze.safeAdd(this._years,r)),this._months,this._days)},i.plusMonths=function(r){return r===0?this:e.create(this._years,Ze.safeToInt(Ze.safeAdd(this._months,r)),this._days)},i.plusDays=function(r){return r===0?this:e.create(this._years,this._months,Ze.safeToInt(Ze.safeAdd(this._days,r)))},i.minus=function(r){var o=e.from(r);return e.create(Ze.safeSubtract(this._years,o._years),Ze.safeSubtract(this._months,o._months),Ze.safeSubtract(this._days,o._days))},i.minusYears=function(r){return this.plusYears(-1*r)},i.minusMonths=function(r){return this.plusMonths(-1*r)},i.minusDays=function(r){return this.plusDays(-1*r)},i.multipliedBy=function(r){return this===e.ZERO||r===1?this:e.create(Ze.safeMultiply(this._years,r),Ze.safeMultiply(this._months,r),Ze.safeMultiply(this._days,r))},i.negated=function(){return this.multipliedBy(-1)},i.normalized=function(){var r=this.toTotalMonths(),o=Ze.intDiv(r,12),a=Ze.intMod(r,12);return o===this._years&&a===this._months?this:e.create(Ze.safeToInt(o),a,this._days)},i.toTotalMonths=function(){return this._years*12+this._months},i.addTo=function(r){return yt(r,"temporal"),this._years!==0?this._months!==0?r=r.plus(this.toTotalMonths(),ft.MONTHS):r=r.plus(this._years,ft.YEARS):this._months!==0&&(r=r.plus(this._months,ft.MONTHS)),this._days!==0&&(r=r.plus(this._days,ft.DAYS)),r},i.subtractFrom=function(r){return yt(r,"temporal"),this._years!==0?this._months!==0?r=r.minus(this.toTotalMonths(),ft.MONTHS):r=r.minus(this._years,ft.YEARS):this._months!==0&&(r=r.minus(this._months,ft.MONTHS)),this._days!==0&&(r=r.minus(this._days,ft.DAYS)),r},i.equals=function(r){if(this===r)return!0;if(r instanceof e){var o=r;return this._years===o._years&&this._months===o._months&&this._days===o._days}return!1},i.hashCode=function(){return Ze.hashCode(this._years,this._months,this._days)},i.toString=function(){if(this===e.ZERO)return"P0D";var r="P";return this._years!==0&&(r+=this._years+"Y"),this._months!==0&&(r+=this._months+"M"),this._days!==0&&(r+=this._days+"D"),r},i.toJSON=function(){return this.toString()},e})(MD);function Kvt(){nS.ofDays(0)}/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var mke=(function(){function t(i){this._index=i,this._errorIndex=-1}var e=t.prototype;return e.getIndex=function(){return this._index},e.setIndex=function(n){this._index=n},e.getErrorIndex=function(){return this._errorIndex},e.setErrorIndex=function(n){this._errorIndex=n},t})();/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var bke=(function(){function t(){this._map={}}var e=t.prototype;return e.putAll=function(n){for(var r in n._map)this._map[r]=n._map[r];return this},e.containsKey=function(n){return this._map.hasOwnProperty(n.name())&&this.get(n)!==void 0},e.get=function(n){return this._map[n.name()]},e.put=function(n,r){return this.set(n,r)},e.set=function(n,r){return this._map[n.name()]=r,this},e.retainAll=function(n){for(var r={},o=0;o<n.length;o++){var a=n[o].name();r[a]=this._map[a]}return this._map=r,this},e.remove=function(n){var r=n.name(),o=this._map[r];return this._map[r]=void 0,o},e.keySet=function(){return this._map},e.clear=function(){this._map={}},t})(),ln=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}return e})(mI);ln.STRICT=new ln("STRICT");ln.SMART=new ln("SMART");ln.LENIENT=new ln("LENIENT");var Rh=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.isSupported=function(r){Hi("isSupported")},i.minus=function(r,o){return arguments.length<2?this._minusAmount(r):this._minusUnit(r,o)},i._minusAmount=function(r){return yt(r,"amount"),_i(r,MD,"amount"),r.subtractFrom(this)},i._minusUnit=function(r,o){return yt(r,"amountToSubtract"),yt(o,"unit"),_i(o,AS,"unit"),this._plusUnit(-r,o)},i.plus=function(r,o){return arguments.length<2?this._plusAmount(r):this._plusUnit(r,o)},i._plusAmount=function(r){return yt(r,"amount"),_i(r,MD,"amount"),r.addTo(this)},i._plusUnit=function(r,o){Hi("_plusUnit")},i.until=function(r,o){Hi("until")},i.with=function(r,o){return arguments.length<2?this._withAdjuster(r):this._withField(r,o)},i._withAdjuster=function(r){return yt(r,"adjuster"),ha(typeof r.adjustInto=="function","adjuster must be a TemporalAdjuster",Pi),r.adjustInto(this)},i._withField=function(r,o){Hi("_withField")},e})(xP);typeof Symbol<"u"&&Symbol.toPrimitive&&(Rh.prototype[Symbol.toPrimitive]=function(t){if(t!=="number")return this.toString();throw new TypeError("A conversion from Temporal to a number is not allowed. To compare use the methods .equals(), .compareTo(), .isBefore() or one that is more suitable to your use case.")});var A3=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.isSupported=function(r){return r instanceof Me||r instanceof ft?r.isDateBased():r!=null&&r.isSupportedBy(this)},i.query=function(r){return r===Dr.chronology()?this.chronology():r===Dr.precision()?ft.DAYS:r===Dr.localDate()?Ci.ofEpochDay(this.toEpochDay()):r===Dr.localTime()||r===Dr.zone()||r===Dr.zoneId()||r===Dr.offset()?null:t.prototype.query.call(this,r)},i.adjustInto=function(r){return r.with(Me.EPOCH_DAY,this.toEpochDay())},i.format=function(r){return yt(r,"formatter"),_i(r,Nn,"formatter"),r.format(this)},e})(Rh);/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Oy=(function(){function t(){}return t.startsWith=function(i,n){return i.indexOf(n)===0},t.hashCode=function(i){var n=i.length;if(n===0)return 0;for(var r=0,o=0;o<n;o++){var a=i.charCodeAt(o);r=(r<<5)-r+a,r|=0}return Ze.smi(r)},t})();/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var ra=(function(){function t(){}t.systemDefault=function(){throw new ai("not supported operation")},t.getAvailableZoneIds=function(){throw new ai("not supported operation")},t.of=function(n){throw new ai("not supported operation"+n)},t.ofOffset=function(n,r){throw new ai("not supported operation"+n+r)},t.from=function(n){throw new ai("not supported operation"+n)};var e=t.prototype;return e.id=function(){Hi("ZoneId.id")},e.rules=function(){Hi("ZoneId.rules")},e.normalized=function(){var n=this.rules();return n.isFixedOffset()?n.offset(Ra.EPOCH):this},e.equals=function(n){return this===n?!0:n instanceof t?this.id()===n.id():!1},e.hashCode=function(){return Oy.hashCode(this.id())},e.toString=function(){return this.id()},e.toJSON=function(){return this.toString()},t})(),L6=(function(){function t(){}t.of=function(n){return yt(n,"offset"),new Zvt(n)};var e=t.prototype;return e.isFixedOffset=function(){Hi("ZoneRules.isFixedOffset")},e.offset=function(n){return n instanceof Ra?this.offsetOfInstant(n):this.offsetOfLocalDateTime(n)},e.offsetOfInstant=function(n){Hi("ZoneRules.offsetInstant")},e.offsetOfEpochMilli=function(n){Hi("ZoneRules.offsetOfEpochMilli")},e.offsetOfLocalDateTime=function(n){Hi("ZoneRules.offsetLocalDateTime")},e.validOffsets=function(n){Hi("ZoneRules.validOffsets")},e.transition=function(n){Hi("ZoneRules.transition")},e.standardOffset=function(n){Hi("ZoneRules.standardOffset")},e.daylightSavings=function(n){Hi("ZoneRules.daylightSavings")},e.isDaylightSavings=function(n){Hi("ZoneRules.isDaylightSavings")},e.isValidOffset=function(n,r){Hi("ZoneRules.isValidOffset")},e.nextTransition=function(n){Hi("ZoneRules.nextTransition")},e.previousTransition=function(n){Hi("ZoneRules.previousTransition")},e.transitions=function(){Hi("ZoneRules.transitions")},e.transitionRules=function(){Hi("ZoneRules.transitionRules")},e.toString=function(){Hi("ZoneRules.toString")},e.toJSON=function(){return this.toString()},t})(),Zvt=(function(t){yn(e,t);function e(n){var r;return r=t.call(this)||this,r._offset=n,r}var i=e.prototype;return i.isFixedOffset=function(){return!0},i.offsetOfInstant=function(){return this._offset},i.offsetOfEpochMilli=function(){return this._offset},i.offsetOfLocalDateTime=function(){return this._offset},i.validOffsets=function(){return[this._offset]},i.transition=function(){return null},i.standardOffset=function(){return this._offset},i.daylightSavings=function(){return fl.ZERO},i.isDaylightSavings=function(){return!1},i.isValidOffset=function(r,o){return this._offset.equals(o)},i.nextTransition=function(){return null},i.previousTransition=function(){return null},i.transitions=function(){return[]},i.transitionRules=function(){return[]},i.equals=function(r){return this===r?!0:r instanceof e?this._offset.equals(r._offset):!1},i.toString=function(){return"FixedRules:"+this._offset.toString()},e})(L6),Fue={},Bue={},en=(function(t){yn(e,t);function e(n){var r;return r=t.call(this)||this,e._validateTotalSeconds(n),r._totalSeconds=Ze.safeToInt(n),r._rules=L6.of(w3(r)),r._id=e._buildId(n),r}var i=e.prototype;return i.totalSeconds=function(){return this._totalSeconds},i.id=function(){return this._id},e._buildId=function(r){if(r===0)return"Z";var o=Math.abs(r),a=Ze.intDiv(o,Zt.SECONDS_PER_HOUR),s=Ze.intMod(Ze.intDiv(o,Zt.SECONDS_PER_MINUTE),Zt.MINUTES_PER_HOUR),l=(r<0?"-":"+")+(a<10?"0":"")+a+(s<10?":0":":")+s,u=Ze.intMod(o,Zt.SECONDS_PER_MINUTE);return u!==0&&(l+=(u<10?":0":":")+u),l},e._validateTotalSeconds=function(r){if(Math.abs(r)>e.MAX_SECONDS)throw new ai("Zone offset not in valid range: -18:00 to +18:00")},e._validate=function(r,o,a){if(r<-18||r>18)throw new ai("Zone offset hours not in valid range: value "+r+" is not in the range -18 to 18");if(r>0){if(o<0||a<0)throw new ai("Zone offset minutes and seconds must be positive because hours is positive")}else if(r<0){if(o>0||a>0)throw new ai("Zone offset minutes and seconds must be negative because hours is negative")}else if(o>0&&a<0||o<0&&a>0)throw new ai("Zone offset minutes and seconds must have the same sign");if(Math.abs(o)>59)throw new ai("Zone offset minutes not in valid range: abs(value) "+Math.abs(o)+" is not in the range 0 to 59");if(Math.abs(a)>59)throw new ai("Zone offset seconds not in valid range: abs(value) "+Math.abs(a)+" is not in the range 0 to 59");if(Math.abs(r)===18&&(Math.abs(o)>0||Math.abs(a)>0))throw new ai("Zone offset not in valid range: -18:00 to +18:00")},e.of=function(r){yt(r,"offsetId");var o=Bue[r];if(o!=null)return o;var a,s,l;switch(r.length){case 2:r=r[0]+"0"+r[1];case 3:a=e._parseNumber(r,1,!1),s=0,l=0;break;case 5:a=e._parseNumber(r,1,!1),s=e._parseNumber(r,3,!1),l=0;break;case 6:a=e._parseNumber(r,1,!1),s=e._parseNumber(r,4,!0),l=0;break;case 7:a=e._parseNumber(r,1,!1),s=e._parseNumber(r,3,!1),l=e._parseNumber(r,5,!1);break;case 9:a=e._parseNumber(r,1,!1),s=e._parseNumber(r,4,!0),l=e._parseNumber(r,7,!0);break;default:throw new ai("Invalid ID for ZoneOffset, invalid format: "+r)}var u=r[0];if(u!=="+"&&u!=="-")throw new ai("Invalid ID for ZoneOffset, plus/minus not found when expected: "+r);return u==="-"?e.ofHoursMinutesSeconds(-a,-s,-l):e.ofHoursMinutesSeconds(a,s,l)},e._parseNumber=function(r,o,a){if(a&&r[o-1]!==":")throw new ai("Invalid ID for ZoneOffset, colon not found when expected: "+r);var s=r[o],l=r[o+1];if(s<"0"||s>"9"||l<"0"||l>"9")throw new ai("Invalid ID for ZoneOffset, non numeric characters found: "+r);return(s.charCodeAt(0)-48)*10+(l.charCodeAt(0)-48)},e.ofHours=function(r){return e.ofHoursMinutesSeconds(r,0,0)},e.ofHoursMinutes=function(r,o){return e.ofHoursMinutesSeconds(r,o,0)},e.ofHoursMinutesSeconds=function(r,o,a){e._validate(r,o,a);var s=r*Zt.SECONDS_PER_HOUR+o*Zt.SECONDS_PER_MINUTE+a;return e.ofTotalSeconds(s)},e.ofTotalMinutes=function(r){var o=r*Zt.SECONDS_PER_MINUTE;return e.ofTotalSeconds(o)},e.ofTotalSeconds=function(r){if(r%(15*Zt.SECONDS_PER_MINUTE)===0){var o=r,a=Fue[o];return a==null&&(a=new e(r),Fue[o]=a,Bue[a.id()]=a),a}else return new e(r)},i.rules=function(){return this._rules},i.get=function(r){return this.getLong(r)},i.getLong=function(r){if(r===Me.OFFSET_SECONDS)return this._totalSeconds;if(r instanceof Me)throw new ai("Unsupported field: "+r);return r.getFrom(this)},i.query=function(r){return yt(r,"query"),r===Dr.offset()||r===Dr.zone()?this:r===Dr.localDate()||r===Dr.localTime()||r===Dr.precision()||r===Dr.chronology()||r===Dr.zoneId()?null:r.queryFrom(this)},i.adjustInto=function(r){return r.with(Me.OFFSET_SECONDS,this._totalSeconds)},i.compareTo=function(r){return yt(r,"other"),r._totalSeconds-this._totalSeconds},i.equals=function(r){return this===r?!0:r instanceof e?this._totalSeconds===r._totalSeconds:!1},i.hashCode=function(){return this._totalSeconds},i.toString=function(){return this._id},e})(ra);function Jvt(){en.MAX_SECONDS=18*Zt.SECONDS_PER_HOUR,en.UTC=en.ofTotalSeconds(0),en.MIN=en.ofTotalSeconds(-en.MAX_SECONDS),en.MAX=en.ofTotalSeconds(en.MAX_SECONDS)}var pz=(function(t){yn(e,t),e.create=function(r,o){var a=new e;return a._addFieldValue(r,o),a};function e(){var n;return n=t.call(this)||this,n.fieldValues=new bke,n.chrono=null,n.zone=null,n.date=null,n.time=null,n.leapSecond=!1,n.excessDays=null,n}var i=e.prototype;return i.getFieldValue0=function(r){return this.fieldValues.get(r)},i._addFieldValue=function(r,o){yt(r,"field");var a=this.getFieldValue0(r);if(a!=null&&a!==o)throw new ai("Conflict found: "+r+" "+a+" differs from "+r+" "+o+": "+this);return this._putFieldValue0(r,o)},i._putFieldValue0=function(r,o){return this.fieldValues.put(r,o),this},i.resolve=function(r,o){return o!=null&&this.fieldValues.retainAll(o),this._mergeDate(r),this._mergeTime(r),this._resolveTimeInferZeroes(r),this.excessDays!=null&&this.excessDays.isZero()===!1&&this.date!=null&&this.time!=null&&(this.date=this.date.plus(this.excessDays),this.excessDays=nS.ZERO),this._resolveInstant(),this},i._mergeDate=function(r){this._checkDate(ta.INSTANCE.resolveDate(this.fieldValues,r))},i._checkDate=function(r){if(r!=null){this._addObject(r);for(var o in this.fieldValues.keySet()){var a=Me.byName(o);if(a&&this.fieldValues.get(a)!==void 0&&a.isDateBased()){var s=void 0;try{s=r.getLong(a)}catch(u){if(u instanceof ai)continue;throw u}var l=this.fieldValues.get(a);if(s!==l)throw new ai("Conflict found: Field "+a+" "+s+" differs from "+a+" "+l+" derived from "+r)}}}},i._mergeTime=function(r){if(this.fieldValues.containsKey(Me.CLOCK_HOUR_OF_DAY)){var o=this.fieldValues.remove(Me.CLOCK_HOUR_OF_DAY);r!==ln.LENIENT&&(r===ln.SMART&&o===0||Me.CLOCK_HOUR_OF_DAY.checkValidValue(o)),this._addFieldValue(Me.HOUR_OF_DAY,o===24?0:o)}if(this.fieldValues.containsKey(Me.CLOCK_HOUR_OF_AMPM)){var a=this.fieldValues.remove(Me.CLOCK_HOUR_OF_AMPM);r!==ln.LENIENT&&(r===ln.SMART&&a===0||Me.CLOCK_HOUR_OF_AMPM.checkValidValue(a)),this._addFieldValue(Me.HOUR_OF_AMPM,a===12?0:a)}if(r!==ln.LENIENT&&(this.fieldValues.containsKey(Me.AMPM_OF_DAY)&&Me.AMPM_OF_DAY.checkValidValue(this.fieldValues.get(Me.AMPM_OF_DAY)),this.fieldValues.containsKey(Me.HOUR_OF_AMPM)&&Me.HOUR_OF_AMPM.checkValidValue(this.fieldValues.get(Me.HOUR_OF_AMPM))),this.fieldValues.containsKey(Me.AMPM_OF_DAY)&&this.fieldValues.containsKey(Me.HOUR_OF_AMPM)){var s=this.fieldValues.remove(Me.AMPM_OF_DAY),l=this.fieldValues.remove(Me.HOUR_OF_AMPM);this._addFieldValue(Me.HOUR_OF_DAY,s*12+l)}if(this.fieldValues.containsKey(Me.NANO_OF_DAY)){var u=this.fieldValues.remove(Me.NANO_OF_DAY);r!==ln.LENIENT&&Me.NANO_OF_DAY.checkValidValue(u),this._addFieldValue(Me.SECOND_OF_DAY,Ze.intDiv(u,1e9)),this._addFieldValue(Me.NANO_OF_SECOND,Ze.intMod(u,1e9))}if(this.fieldValues.containsKey(Me.MICRO_OF_DAY)){var c=this.fieldValues.remove(Me.MICRO_OF_DAY);r!==ln.LENIENT&&Me.MICRO_OF_DAY.checkValidValue(c),this._addFieldValue(Me.SECOND_OF_DAY,Ze.intDiv(c,1e6)),this._addFieldValue(Me.MICRO_OF_SECOND,Ze.intMod(c,1e6))}if(this.fieldValues.containsKey(Me.MILLI_OF_DAY)){var d=this.fieldValues.remove(Me.MILLI_OF_DAY);r!==ln.LENIENT&&Me.MILLI_OF_DAY.checkValidValue(d),this._addFieldValue(Me.SECOND_OF_DAY,Ze.intDiv(d,1e3)),this._addFieldValue(Me.MILLI_OF_SECOND,Ze.intMod(d,1e3))}if(this.fieldValues.containsKey(Me.SECOND_OF_DAY)){var f=this.fieldValues.remove(Me.SECOND_OF_DAY);r!==ln.LENIENT&&Me.SECOND_OF_DAY.checkValidValue(f),this._addFieldValue(Me.HOUR_OF_DAY,Ze.intDiv(f,3600)),this._addFieldValue(Me.MINUTE_OF_HOUR,Ze.intMod(Ze.intDiv(f,60),60)),this._addFieldValue(Me.SECOND_OF_MINUTE,Ze.intMod(f,60))}if(this.fieldValues.containsKey(Me.MINUTE_OF_DAY)){var h=this.fieldValues.remove(Me.MINUTE_OF_DAY);r!==ln.LENIENT&&Me.MINUTE_OF_DAY.checkValidValue(h),this._addFieldValue(Me.HOUR_OF_DAY,Ze.intDiv(h,60)),this._addFieldValue(Me.MINUTE_OF_HOUR,Ze.intMod(h,60))}if(r!==ln.LENIENT&&(this.fieldValues.containsKey(Me.MILLI_OF_SECOND)&&Me.MILLI_OF_SECOND.checkValidValue(this.fieldValues.get(Me.MILLI_OF_SECOND)),this.fieldValues.containsKey(Me.MICRO_OF_SECOND)&&Me.MICRO_OF_SECOND.checkValidValue(this.fieldValues.get(Me.MICRO_OF_SECOND))),this.fieldValues.containsKey(Me.MILLI_OF_SECOND)&&this.fieldValues.containsKey(Me.MICRO_OF_SECOND)){var p=this.fieldValues.remove(Me.MILLI_OF_SECOND),g=this.fieldValues.get(Me.MICRO_OF_SECOND);this._putFieldValue0(Me.MICRO_OF_SECOND,p*1e3+Ze.intMod(g,1e3))}if(this.fieldValues.containsKey(Me.MICRO_OF_SECOND)&&this.fieldValues.containsKey(Me.NANO_OF_SECOND)){var v=this.fieldValues.get(Me.NANO_OF_SECOND);this._putFieldValue0(Me.MICRO_OF_SECOND,Ze.intDiv(v,1e3)),this.fieldValues.remove(Me.MICRO_OF_SECOND)}if(this.fieldValues.containsKey(Me.MILLI_OF_SECOND)&&this.fieldValues.containsKey(Me.NANO_OF_SECOND)){var y=this.fieldValues.get(Me.NANO_OF_SECOND);this._putFieldValue0(Me.MILLI_OF_SECOND,Ze.intDiv(y,1e6)),this.fieldValues.remove(Me.MILLI_OF_SECOND)}if(this.fieldValues.containsKey(Me.MICRO_OF_SECOND)){var m=this.fieldValues.remove(Me.MICRO_OF_SECOND);this._putFieldValue0(Me.NANO_OF_SECOND,m*1e3)}else if(this.fieldValues.containsKey(Me.MILLI_OF_SECOND)){var b=this.fieldValues.remove(Me.MILLI_OF_SECOND);this._putFieldValue0(Me.NANO_OF_SECOND,b*1e6)}},i._resolveTimeInferZeroes=function(r){var o=this.fieldValues.get(Me.HOUR_OF_DAY),a=this.fieldValues.get(Me.MINUTE_OF_HOUR),s=this.fieldValues.get(Me.SECOND_OF_MINUTE),l=this.fieldValues.get(Me.NANO_OF_SECOND);if(o!=null&&!(a==null&&(s!=null||l!=null))&&!(a!=null&&s==null&&l!=null)){if(r!==ln.LENIENT){if(o!=null){r===ln.SMART&&o===24&&(a==null||a===0)&&(s==null||s===0)&&(l==null||l===0)&&(o=0,this.excessDays=nS.ofDays(1));var u=Me.HOUR_OF_DAY.checkValidIntValue(o);if(a!=null){var c=Me.MINUTE_OF_HOUR.checkValidIntValue(a);if(s!=null){var d=Me.SECOND_OF_MINUTE.checkValidIntValue(s);if(l!=null){var f=Me.NANO_OF_SECOND.checkValidIntValue(l);this._addObject(Zt.of(u,c,d,f))}else this._addObject(Zt.of(u,c,d))}else l==null&&this._addObject(Zt.of(u,c))}else s==null&&l==null&&this._addObject(Zt.of(u,0))}}else if(o!=null){var h=o;if(a!=null)if(s!=null){l==null&&(l=0);var p=Ze.safeMultiply(h,36e11);p=Ze.safeAdd(p,Ze.safeMultiply(a,6e10)),p=Ze.safeAdd(p,Ze.safeMultiply(s,1e9)),p=Ze.safeAdd(p,l);var g=Ze.floorDiv(p,864e11),v=Ze.floorMod(p,864e11);this._addObject(Zt.ofNanoOfDay(v)),this.excessDays=nS.ofDays(g)}else{var y=Ze.safeMultiply(h,3600);y=Ze.safeAdd(y,Ze.safeMultiply(a,60));var m=Ze.floorDiv(y,86400),b=Ze.floorMod(y,86400);this._addObject(Zt.ofSecondOfDay(b)),this.excessDays=nS.ofDays(m)}else{var S=Ze.safeToInt(Ze.floorDiv(h,24));h=Ze.floorMod(h,24),this._addObject(Zt.of(h,0)),this.excessDays=nS.ofDays(S)}}this.fieldValues.remove(Me.HOUR_OF_DAY),this.fieldValues.remove(Me.MINUTE_OF_HOUR),this.fieldValues.remove(Me.SECOND_OF_MINUTE),this.fieldValues.remove(Me.NANO_OF_SECOND)}},i._addObject=function(r){r instanceof A3?this.date=r:r instanceof Zt&&(this.time=r)},i._resolveInstant=function(){if(this.date!=null&&this.time!=null){var r=this.fieldValues.get(Me.OFFSET_SECONDS);if(r!=null){var o=en.ofTotalSeconds(r),a=this.date.atTime(this.time).atZone(o).getLong(Me.INSTANT_SECONDS);this.fieldValues.put(Me.INSTANT_SECONDS,a)}else if(this.zone!=null){var s=this.date.atTime(this.time).atZone(this.zone).getLong(Me.INSTANT_SECONDS);this.fieldValues.put(Me.INSTANT_SECONDS,s)}}},i.build=function(r){return r.queryFrom(this)},i.isSupported=function(r){return r==null?!1:this.fieldValues.containsKey(r)&&this.fieldValues.get(r)!==void 0||this.date!=null&&this.date.isSupported(r)||this.time!=null&&this.time.isSupported(r)},i.getLong=function(r){yt(r,"field");var o=this.getFieldValue0(r);if(o==null){if(this.date!=null&&this.date.isSupported(r))return this.date.getLong(r);if(this.time!=null&&this.time.isSupported(r))return this.time.getLong(r);throw new ai("Field not found: "+r)}return o},i.query=function(r){return r===Dr.zoneId()?this.zone:r===Dr.chronology()?this.chrono:r===Dr.localDate()?this.date!=null?Ci.from(this.date):null:r===Dr.localTime()?this.time:r===Dr.zone()||r===Dr.offset()?r.queryFrom(this):r===Dr.precision()?null:r.queryFrom(this)},e})(xP),Ske=(function(){function t(){if(arguments.length===1)if(arguments[0]instanceof t){this._constructorSelf.apply(this,arguments);return}else this._constructorFormatter.apply(this,arguments);else this._constructorParam.apply(this,arguments);this._caseSensitive=!0,this._strict=!0,this._parsed=[new jue(this)]}var e=t.prototype;return e._constructorParam=function(n,r,o){this._locale=n,this._symbols=r,this._overrideChronology=o},e._constructorFormatter=function(n){this._locale=n.locale(),this._symbols=n.decimalStyle(),this._overrideChronology=n.chronology()},e._constructorSelf=function(n){this._locale=n._locale,this._symbols=n._symbols,this._overrideChronology=n._overrideChronology,this._overrideZone=n._overrideZone,this._caseSensitive=n._caseSensitive,this._strict=n._strict,this._parsed=[new jue(this)]},e.copy=function(){return new t(this)},e.symbols=function(){return this._symbols},e.isStrict=function(){return this._strict},e.setStrict=function(n){this._strict=n},e.locale=function(){return this._locale},e.setLocale=function(n){this._locale=n},e.startOptional=function(){this._parsed.push(this.currentParsed().copy())},e.endOptional=function(n){n?this._parsed.splice(this._parsed.length-2,1):this._parsed.splice(this._parsed.length-1,1)},e.isCaseSensitive=function(){return this._caseSensitive},e.setCaseSensitive=function(n){this._caseSensitive=n},e.subSequenceEquals=function(n,r,o,a,s){if(r+s>n.length||a+s>o.length)return!1;this.isCaseSensitive()||(n=n.toLowerCase(),o=o.toLowerCase());for(var l=0;l<s;l++){var u=n[r+l],c=o[a+l];if(u!==c)return!1}return!0},e.charEquals=function(n,r){return this.isCaseSensitive()?n===r:this.charEqualsIgnoreCase(n,r)},e.charEqualsIgnoreCase=function(n,r){return n===r||n.toLowerCase()===r.toLowerCase()},e.setParsedField=function(n,r,o,a){var s=this.currentParsed().fieldValues,l=s.get(n);return s.set(n,r),l!=null&&l!==r?~o:a},e.setParsedZone=function(n){yt(n,"zone"),this.currentParsed().zone=n},e.getParsed=function(n){return this.currentParsed().fieldValues.get(n)},e.toParsed=function(){return this.currentParsed()},e.currentParsed=function(){return this._parsed[this._parsed.length-1]},e.setParsedLeapSecond=function(){this.currentParsed().leapSecond=!0},e.getEffectiveChronology=function(){var n=this.currentParsed().chrono;return n==null&&(n=this._overrideChronology,n==null&&(n=ta.INSTANCE)),n},t})(),jue=(function(t){yn(e,t);function e(n){var r;return r=t.call(this)||this,r.chrono=null,r.zone=null,r.fieldValues=new bke,r.leapSecond=!1,r.dateTimeParseContext=n,r}var i=e.prototype;return i.copy=function(){var r=new e;return r.chrono=this.chrono,r.zone=this.zone,r.fieldValues.putAll(this.fieldValues),r.leapSecond=this.leapSecond,r.dateTimeParseContext=this.dateTimeParseContext,r},i.toString=function(){return this.fieldValues+", "+this.chrono+", "+this.zone},i.isSupported=function(r){return this.fieldValues.containsKey(r)},i.get=function(r){var o=this.fieldValues.get(r);return ha(o!=null),o},i.query=function(r){return r===Dr.chronology()?this.chrono:r===Dr.zoneId()||r===Dr.zone()?this.zone:t.prototype.query.call(this,r)},i.toBuilder=function(){var r=new pz;return r.fieldValues.putAll(this.fieldValues),r.chrono=this.dateTimeParseContext.getEffectiveChronology(),this.zone!=null?r.zone=this.zone:r.zone=this.overrideZone,r.leapSecond=this.leapSecond,r.excessDays=this.excessDays,r},e})(Rh);/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var _ke=(function(){function t(i,n,r){arguments.length===2&&arguments[1]instanceof Nn?(this._temporal=t.adjust(i,n),this._locale=n.locale(),this._symbols=n.decimalStyle()):(this._temporal=i,this._locale=n,this._symbols=r),this._optional=0}t.adjust=function(n,r){return n};var e=t.prototype;return e.symbols=function(){return this._symbols},e.startOptional=function(){this._optional++},e.endOptional=function(){this._optional--},e.getValueQuery=function(n){var r=this._temporal.query(n);if(r==null&&this._optional===0)throw new ai("Unable to extract value: "+this._temporal);return r},e.getValue=function(n){try{return this._temporal.getLong(n)}catch(r){if(r instanceof ai&&this._optional>0)return null;throw r}},e.temporal=function(){return this._temporal},e.locale=function(){return this._locale},e.setDateTime=function(n){this._temporal=n},e.setLocale=function(n){this._locale=n},t})(),pv={},Qvt=[0,90,181,273,0,91,182,274],Zy=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.isDateBased=function(){return!0},i.isTimeBased=function(){return!1},i._isIso=function(){return!0},e._getWeekRangeByLocalDate=function(r){var o=e._getWeekBasedYear(r);return dn.of(1,e._getWeekRangeByYear(o))},e._getWeekRangeByYear=function(r){var o=Ci.of(r,1,1);return o.dayOfWeek()===Wa.THURSDAY||o.dayOfWeek()===Wa.WEDNESDAY&&o.isLeapYear()?53:52},e._getWeek=function(r){var o=r.dayOfWeek().ordinal(),a=r.dayOfYear()-1,s=a+(3-o),l=Ze.intDiv(s,7),u=s-l*7,c=u-3;if(c<-3&&(c+=7),a<c)return e._getWeekRangeByLocalDate(r.withDayOfYear(180).minusYears(1)).maximum();var d=Ze.intDiv(a-c,7)+1;return d===53&&(c===-3||c===-2&&r.isLeapYear())===!1&&(d=1),d},e._getWeekBasedYear=function(r){var o=r.year(),a=r.dayOfYear();if(a<=3){var s=r.dayOfWeek().ordinal();a-s<-2&&o--}else if(a>=363){var l=r.dayOfWeek().ordinal();a=a-363-(r.isLeapYear()?1:0),a-l>=0&&o++}return o},i.displayName=function(){return this.toString()},i.resolve=function(){return null},i.name=function(){return this.toString()},e})(Ky),eyt=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.toString=function(){return"DayOfQuarter"},i.baseUnit=function(){return ft.DAYS},i.rangeUnit=function(){return zk},i.range=function(){return dn.of(1,90,92)},i.isSupportedBy=function(r){return r.isSupported(Me.DAY_OF_YEAR)&&r.isSupported(Me.MONTH_OF_YEAR)&&r.isSupported(Me.YEAR)&&this._isIso(r)},i.rangeRefinedBy=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: DayOfQuarter");var o=r.getLong(jO);if(o===1){var a=r.getLong(Me.YEAR);return ta.isLeapYear(a)?dn.of(1,91):dn.of(1,90)}else{if(o===2)return dn.of(1,91);if(o===3||o===4)return dn.of(1,92)}return this.range()},i.getFrom=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: DayOfQuarter");var o=r.get(Me.DAY_OF_YEAR),a=r.get(Me.MONTH_OF_YEAR),s=r.getLong(Me.YEAR);return o-Qvt[Ze.intDiv(a-1,3)+(ta.isLeapYear(s)?4:0)]},i.adjustInto=function(r,o){var a=this.getFrom(r);return this.range().checkValidValue(o,this),r.with(Me.DAY_OF_YEAR,r.getLong(Me.DAY_OF_YEAR)+(o-a))},i.resolve=function(r,o,a){var s=r.get(Me.YEAR),l=r.get(jO);if(s==null||l==null)return null;var u=Me.YEAR.checkValidIntValue(s),c=r.get(xZ),d;if(a===ln.LENIENT){var f=l;d=Ci.of(u,1,1),d=d.plusMonths(Ze.safeMultiply(Ze.safeSubtract(f,1),3)),d=d.plusDays(Ze.safeSubtract(c,1))}else{var h=jO.range().checkValidIntValue(l,jO);if(a===ln.STRICT){var p=92;h===1?p=ta.isLeapYear(u)?91:90:h===2&&(p=91),dn.of(1,p).checkValidValue(c,this)}else this.range().checkValidValue(c,this);d=Ci.of(u,(h-1)*3+1,1).plusDays(c-1)}return r.remove(this),r.remove(Me.YEAR),r.remove(jO),d},e})(Zy),tyt=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.toString=function(){return"QuarterOfYear"},i.baseUnit=function(){return zk},i.rangeUnit=function(){return ft.YEARS},i.range=function(){return dn.of(1,4)},i.isSupportedBy=function(r){return r.isSupported(Me.MONTH_OF_YEAR)&&this._isIso(r)},i.rangeRefinedBy=function(r){return this.range()},i.getFrom=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: QuarterOfYear");var o=r.getLong(Me.MONTH_OF_YEAR);return Ze.intDiv(o+2,3)},i.adjustInto=function(r,o){var a=this.getFrom(r);return this.range().checkValidValue(o,this),r.with(Me.MONTH_OF_YEAR,r.getLong(Me.MONTH_OF_YEAR)+(o-a)*3)},e})(Zy),ryt=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.toString=function(){return"WeekOfWeekBasedYear"},i.baseUnit=function(){return ft.WEEKS},i.rangeUnit=function(){return Uk},i.range=function(){return dn.of(1,52,53)},i.isSupportedBy=function(r){return r.isSupported(Me.EPOCH_DAY)&&this._isIso(r)},i.rangeRefinedBy=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: WeekOfWeekBasedYear");return Zy._getWeekRangeByLocalDate(Ci.from(r))},i.getFrom=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: WeekOfWeekBasedYear");return Zy._getWeek(Ci.from(r))},i.adjustInto=function(r,o){return this.range().checkValidValue(o,this),r.plus(Ze.safeSubtract(o,this.getFrom(r)),ft.WEEKS)},i.resolve=function(r,o,a){var s=r.get(wv),l=r.get(Me.DAY_OF_WEEK);if(s==null||l==null)return null;var u=wv.range().checkValidIntValue(s,wv),c=r.get(EZ),d;if(a===ln.LENIENT){var f=l,h=0;f>7?(h=Ze.intDiv(f-1,7),f=Ze.intMod(f-1,7)+1):f<1&&(h=Ze.intDiv(f,7)-1,f=Ze.intMod(f,7)+7),d=Ci.of(u,1,4).plusWeeks(c-1).plusWeeks(h).with(Me.DAY_OF_WEEK,f)}else{var p=Me.DAY_OF_WEEK.checkValidIntValue(l);if(a===ln.STRICT){var g=Ci.of(u,1,4),v=Zy._getWeekRangeByLocalDate(g);v.checkValidValue(c,this)}else this.range().checkValidValue(c,this);d=Ci.of(u,1,4).plusWeeks(c-1).with(Me.DAY_OF_WEEK,p)}return r.remove(this),r.remove(wv),r.remove(Me.DAY_OF_WEEK),d},i.displayName=function(){return"Week"},e})(Zy),iyt=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.toString=function(){return"WeekBasedYear"},i.baseUnit=function(){return Uk},i.rangeUnit=function(){return ft.FOREVER},i.range=function(){return Me.YEAR.range()},i.isSupportedBy=function(r){return r.isSupported(Me.EPOCH_DAY)&&this._isIso(r)},i.rangeRefinedBy=function(r){return Me.YEAR.range()},i.getFrom=function(r){if(r.isSupported(this)===!1)throw new Qn("Unsupported field: WeekBasedYear");return Zy._getWeekBasedYear(Ci.from(r))},i.adjustInto=function(r,o){if(this.isSupportedBy(r)===!1)throw new Qn("Unsupported field: WeekBasedYear");var a=this.range().checkValidIntValue(o,wv),s=Ci.from(r),l=s.get(Me.DAY_OF_WEEK),u=Zy._getWeek(s);u===53&&Zy._getWeekRangeByYear(a)===52&&(u=52);var c=Ci.of(a,1,4),d=l-c.get(Me.DAY_OF_WEEK)+(u-1)*7;return c=c.plusDays(d),r.with(c)},e})(Zy),Vue=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._name=n,o._duration=r,o}var i=e.prototype;return i.duration=function(){return this._duration},i.isDurationEstimated=function(){return!0},i.isDateBased=function(){return!0},i.isTimeBased=function(){return!1},i.isSupportedBy=function(r){return r.isSupported(Me.EPOCH_DAY)},i.addTo=function(r,o){switch(this){case Uk:{var a=Ze.safeAdd(r.get(wv),o);return r.with(wv,a)}case zk:return r.plus(Ze.intDiv(o,256),ft.YEARS).plus(Ze.intMod(o,256)*3,ft.MONTHS);default:throw new E3("Unreachable")}},i.between=function(r,o){switch(this){case Uk:return Ze.safeSubtract(o.getLong(wv),r.getLong(wv));case zk:return Ze.intDiv(r.until(o,ft.MONTHS),3);default:throw new E3("Unreachable")}},i.toString=function(){return this._name},e})(AS),xZ=null,jO=null,EZ=null,wv=null,Uk=null,zk=null;function nyt(){xZ=new eyt,jO=new tyt,EZ=new ryt,wv=new iyt,Uk=new Vue("WeekBasedYears",fl.ofSeconds(31556952)),zk=new Vue("QuarterYears",fl.ofSeconds(31556952/4)),pv.DAY_OF_QUARTER=xZ,pv.QUARTER_OF_YEAR=jO,pv.WEEK_OF_WEEK_BASED_YEAR=EZ,pv.WEEK_BASED_YEAR=wv,pv.WEEK_BASED_YEARS=Uk,pv.QUARTER_YEARS=zk,Ci.prototype.isoWeekOfWeekyear=function(){return this.get(pv.WEEK_OF_WEEK_BASED_YEAR)},Ci.prototype.isoWeekyear=function(){return this.get(pv.WEEK_BASED_YEAR)}}/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var gz=(function(){function t(i,n,r,o){this._zeroDigit=i,this._zeroDigitCharCode=i.charCodeAt(0),this._positiveSign=n,this._negativeSign=r,this._decimalSeparator=o}var e=t.prototype;return e.positiveSign=function(){return this._positiveSign},e.withPositiveSign=function(n){return n===this._positiveSign?this:new t(this._zeroDigit,n,this._negativeSign,this._decimalSeparator)},e.negativeSign=function(){return this._negativeSign},e.withNegativeSign=function(n){return n===this._negativeSign?this:new t(this._zeroDigit,this._positiveSign,n,this._decimalSeparator)},e.zeroDigit=function(){return this._zeroDigit},e.withZeroDigit=function(n){return n===this._zeroDigit?this:new t(n,this._positiveSign,this._negativeSign,this._decimalSeparator)},e.decimalSeparator=function(){return this._decimalSeparator},e.withDecimalSeparator=function(n){return n===this._decimalSeparator?this:new t(this._zeroDigit,this._positiveSign,this._negativeSign,n)},e.convertToDigit=function(n){var r=n.charCodeAt(0)-this._zeroDigitCharCode;return r>=0&&r<=9?r:-1},e.convertNumberToI18N=function(n){if(this._zeroDigit==="0")return n;for(var r=this._zeroDigitCharCode-48,o="",a=0;a<n.length;a++)o+=String.fromCharCode(n.charCodeAt(a)+r);return o},e.equals=function(n){return this===n?!0:n instanceof t?this._zeroDigit===n._zeroDigit&&this._positiveSign===n._positiveSign&&this._negativeSign===n._negativeSign&&this._decimalSeparator===n._decimalSeparator:!1},e.hashCode=function(){return this._zeroDigit+this._positiveSign+this._negativeSign+this._decimalSeparator},e.toString=function(){return"DecimalStyle["+this._zeroDigit+this._positiveSign+this._negativeSign+this._decimalSeparator+"]"},t.of=function(){throw new Error("not yet supported")},t.availableLocales=function(){throw new Error("not yet supported")},t})();gz.STANDARD=new gz("0","+","-",".");var Mo=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.parse=function(r,o,a){switch(this){case e.NORMAL:return!r||!o;case e.ALWAYS:case e.EXCEEDS_PAD:return!0;default:return!o&&!a}},e})(mI);Mo.NORMAL=new Mo("NORMAL");Mo.NEVER=new Mo("NEVER");Mo.ALWAYS=new Mo("ALWAYS");Mo.EXCEEDS_PAD=new Mo("EXCEEDS_PAD");Mo.NOT_NEGATIVE=new Mo("NOT_NEGATIVE");var Bo=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.isStandalone=function(){switch(this){case e.FULL_STANDALONE:case e.SHORT_STANDALONE:case e.NARROW_STANDALONE:return!0;default:return!1}},i.asStandalone=function(){switch(this){case e.FULL:return e.FULL_STANDALONE;case e.SHORT:return e.SHORT_STANDALONE;case e.NARROW:return e.NARROW_STANDALONE;default:return this}},i.asNormal=function(){switch(this){case e.FULL_STANDALONE:return e.FULL;case e.SHORT_STANDALONE:return e.SHORT;case e.NARROW_STANDALONE:return e.NARROW;default:return this}},e})(mI);Bo.FULL=new Bo("FULL");Bo.FULL_STANDALONE=new Bo("FULL_STANDALONE");Bo.SHORT=new Bo("SHORT");Bo.SHORT_STANDALONE=new Bo("SHORT_STANDALONE");Bo.NARROW=new Bo("NARROW");Bo.NARROW_STANDALONE=new Bo("NARROW_STANDALONE");/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Pke=(function(){function t(i){if(i.length>1)throw new Pi('invalid literal, too long: "'+i+'"');this._literal=i}var e=t.prototype;return e.print=function(n,r){return r.append(this._literal),!0},e.parse=function(n,r,o){var a=r.length;if(o===a)return~o;var s=r.charAt(o);return n.charEquals(this._literal,s)===!1?~o:o+this._literal.length},e.toString=function(){return this._literal==="'"?"''":"'"+this._literal+"'"},t})();/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var wZ=(function(){function t(i,n){this._printerParsers=i,this._optional=n}var e=t.prototype;return e.withOptional=function(n){return n===this._optional?this:new t(this._printerParsers,n)},e.print=function(n,r){var o=r.length();this._optional&&n.startOptional();try{for(var a=0;a<this._printerParsers.length;a++){var s=this._printerParsers[a];if(s.print(n,r)===!1)return r.setLength(o),!0}}finally{this._optional&&n.endOptional()}return!0},e.parse=function(n,r,o){if(this._optional){n.startOptional();for(var a=o,s=0;s<this._printerParsers.length;s++){var l=this._printerParsers[s];if(a=l.parse(n,r,a),a<0)return n.endOptional(!1),o}return n.endOptional(!0),a}else{for(var u=0;u<this._printerParsers.length;u++){var c=this._printerParsers[u];if(o=c.parse(n,r,o),o<0)break}return o}},e.toString=function(){var n="";if(this._printerParsers!=null){n+=this._optional?"[":"(";for(var r=0;r<this._printerParsers.length;r++){var o=this._printerParsers[r];n+=o.toString()}n+=this._optional?"]":")"}return n},t})();/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Cke=(function(){function t(i,n,r,o){if(yt(i,"field"),i.range().isFixed()===!1)throw new Pi("Field must have a fixed set of values: "+i);if(n<0||n>9)throw new Pi("Minimum width must be from 0 to 9 inclusive but was "+n);if(r<1||r>9)throw new Pi("Maximum width must be from 1 to 9 inclusive but was "+r);if(r<n)throw new Pi("Maximum width must exceed or equal the minimum width but "+r+" < "+n);this.field=i,this.minWidth=n,this.maxWidth=r,this.decimalPoint=o}var e=t.prototype;return e.print=function(n,r){var o=n.getValue(this.field);if(o===null)return!1;var a=n.symbols();if(o===0){if(this.minWidth>0){this.decimalPoint&&r.append(a.decimalSeparator());for(var s=0;s<this.minWidth;s++)r.append(a.zeroDigit())}}else{var l=this.convertToFraction(o,a.zeroDigit()),u=Math.min(Math.max(l.length,this.minWidth),this.maxWidth);if(l=l.substr(0,u),l*1>0)for(;l.length>this.minWidth&&l[l.length-1]==="0";)l=l.substr(0,l.length-1);var c=l;c=a.convertNumberToI18N(c),this.decimalPoint&&r.append(a.decimalSeparator()),r.append(c)}return!0},e.parse=function(n,r,o){var a=n.isStrict()?this.minWidth:0,s=n.isStrict()?this.maxWidth:9,l=r.length;if(o===l)return a>0?~o:o;if(this.decimalPoint){if(r[o]!==n.symbols().decimalSeparator())return a>0?~o:o;o++}var u=o+a;if(u>l)return~o;for(var c=Math.min(o+s,l),d=0,f=o;f<c;){var h=r.charAt(f++),p=n.symbols().convertToDigit(h);if(p<0){if(f<u)return~o;f--;break}d=d*10+p}var g=f-o,v=Math.pow(10,g),y=this.convertFromFraction(d,v);return n.setParsedField(this.field,y,o,f)},e.convertToFraction=function(n,r){var o=this.field.range();o.checkValidValue(n,this.field);for(var a=o.minimum(),s=o.maximum()-a+1,l=n-a,u=Ze.intDiv(l*1e9,s),c=""+u;c.length<9;)c=r+c;return c},e.convertFromFraction=function(n,r){var o=this.field.range(),a=o.minimum(),s=o.maximum()-a+1,l=Ze.intDiv(n*s,r);return l},e.toString=function(){var n=this.decimalPoint?",DecimalPoint":"";return"Fraction("+this.field+","+this.minWidth+","+this.maxWidth+n+")"},t})(),lY=15,yL=[0,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9],xL=(function(){function t(i,n,r,o,a){a===void 0&&(a=0),this._field=i,this._minWidth=n,this._maxWidth=r,this._signStyle=o,this._subsequentWidth=a}var e=t.prototype;return e.field=function(){return this._field},e.minWidth=function(){return this._minWidth},e.maxWidth=function(){return this._maxWidth},e.signStyle=function(){return this._signStyle},e.withFixedWidth=function(){return this._subsequentWidth===-1?this:new t(this._field,this._minWidth,this._maxWidth,this._signStyle,-1)},e.withSubsequentWidth=function(n){return new t(this._field,this._minWidth,this._maxWidth,this._signStyle,this._subsequentWidth+n)},e._isFixedWidth=function(){return this._subsequentWidth===-1||this._subsequentWidth>0&&this._minWidth===this._maxWidth&&this._signStyle===Mo.NOT_NEGATIVE},e.print=function(n,r){var o=n.getValue(this._field);if(o==null)return!1;var a=this._getValue(n,o),s=n.symbols(),l=""+Math.abs(a);if(l.length>this._maxWidth)throw new ai("Field "+this._field+" cannot be printed as the value "+a+" exceeds the maximum print width of "+this._maxWidth);if(l=s.convertNumberToI18N(l),a>=0)switch(this._signStyle){case Mo.EXCEEDS_PAD:this._minWidth<lY&&a>=yL[this._minWidth]&&r.append(s.positiveSign());break;case Mo.ALWAYS:r.append(s.positiveSign());break}else switch(this._signStyle){case Mo.NORMAL:case Mo.EXCEEDS_PAD:case Mo.ALWAYS:r.append(s.negativeSign());break;case Mo.NOT_NEGATIVE:throw new ai("Field "+this._field+" cannot be printed as the value "+a+" cannot be negative according to the SignStyle")}for(var u=0;u<this._minWidth-l.length;u++)r.append(s.zeroDigit());return r.append(l),!0},e.parse=function(n,r,o){var a=r.length;if(o===a)return~o;ha(o>=0&&o<a);var s=r.charAt(o),l=!1,u=!1;if(s===n.symbols().positiveSign()){if(this._signStyle.parse(!0,n.isStrict(),this._minWidth===this._maxWidth)===!1)return~o;u=!0,o++}else if(s===n.symbols().negativeSign()){if(this._signStyle.parse(!1,n.isStrict(),this._minWidth===this._maxWidth)===!1)return~o;l=!0,o++}else if(this._signStyle===Mo.ALWAYS&&n.isStrict())return~o;var c=n.isStrict()||this._isFixedWidth()?this._minWidth:1,d=o+c;if(d>a)return~o;for(var f=(n.isStrict()||this._isFixedWidth()?this._maxWidth:9)+Math.max(this._subsequentWidth,0),h=0,p=o,g=0;g<2;g++){for(var v=Math.min(p+f,a);p<v;){var y=r.charAt(p++),m=n.symbols().convertToDigit(y);if(m<0){if(p--,p<d)return~o;break}if(p-o>lY)throw new mv("number text exceeds length");h=h*10+m}if(this._subsequentWidth>0&&g===0){var b=p-o;f=Math.max(c,b-this._subsequentWidth),p=o,h=0}else break}if(l){if(h===0&&n.isStrict())return~(o-1);h!==0&&(h=-h)}else if(this._signStyle===Mo.EXCEEDS_PAD&&n.isStrict()){var S=p-o;if(u){if(S<=this._minWidth)return~(o-1)}else if(S>this._minWidth)return~o}return this._setValue(n,h,o,p)},e._getValue=function(n,r){return r},e._setValue=function(n,r,o,a){return n.setParsedField(this._field,r,o,a)},e.toString=function(){return this._minWidth===1&&this._maxWidth===lY&&this._signStyle===Mo.NORMAL?"Value("+this._field+")":this._minWidth===this._maxWidth&&this._signStyle===Mo.NOT_NEGATIVE?"Value("+this._field+","+this._minWidth+")":"Value("+this._field+","+this._minWidth+","+this._maxWidth+","+this._signStyle+")"},t})(),Aj=(function(t){yn(e,t);function e(n,r,o,a,s){var l;if(l=t.call(this,n,r,o,Mo.NOT_NEGATIVE)||this,r<1||r>10)throw new Pi("The width must be from 1 to 10 inclusive but was "+r);if(o<1||o>10)throw new Pi("The maxWidth must be from 1 to 10 inclusive but was "+o);if(o<r)throw new Pi("The maxWidth must be greater than the width");if(s===null){if(n.range().isValidValue(a)===!1)throw new Pi("The base value must be within the range of the field");if(a+yL[r]>Ze.MAX_SAFE_INTEGER)throw new ai("Unable to add printer-parser as the range exceeds the capacity of an int")}return l._baseValue=a,l._baseDate=s,l}var i=e.prototype;return i._getValue=function(r,o){var a=Math.abs(o),s=this._baseValue;if(this._baseDate!==null){r.temporal();var l=ta.INSTANCE;s=l.date(this._baseDate).get(this._field)}return o>=s&&o<s+yL[this._minWidth]?a%yL[this._minWidth]:a%yL[this._maxWidth]},i._setValue=function(r,o,a,s){var l=this._baseValue;if(this._baseDate!=null){var u=r.getEffectiveChronology();l=u.date(this._baseDate).get(this._field)}var c=s-a;if(c===this._minWidth&&o>=0){var d=yL[this._minWidth],f=l%d,h=l-f;l>0?o=h+o:o=h-o,o<l&&(o+=d)}return r.setParsedField(this._field,o,a,s)},i.withFixedWidth=function(){return this._subsequentWidth===-1?this:new e(this._field,this._minWidth,this._maxWidth,this._baseValue,this._baseDate)},i.withSubsequentWidth=function(r){return new e(this._field,this._minWidth,this._maxWidth,this._baseValue,this._baseDate,this._subsequentWidth+r)},i.isFixedWidth=function(r){return r.isStrict()===!1?!1:t.prototype.isFixedWidth.call(this,r)},i.toString=function(){return"ReducedValue("+this._field+","+this._minWidth+","+this._maxWidth+","+(this._baseDate!=null?this._baseDate:this._baseValue)+")"},e})(xL);/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var GU=["+HH","+HHmm","+HH:mm","+HHMM","+HH:MM","+HHMMss","+HH:MM:ss","+HHMMSS","+HH:MM:SS"],Jy=(function(){function t(i,n){yt(i,"noOffsetText"),yt(n,"pattern"),this.noOffsetText=i,this.type=this._checkPattern(n)}var e=t.prototype;return e._checkPattern=function(n){for(var r=0;r<GU.length;r++)if(GU[r]===n)return r;throw new Pi("Invalid zone offset pattern: "+n)},e.print=function(n,r){var o=n.getValue(Me.OFFSET_SECONDS);if(o==null)return!1;var a=Ze.safeToInt(o);if(a===0)r.append(this.noOffsetText);else{var s=Math.abs(Ze.intMod(Ze.intDiv(a,3600),100)),l=Math.abs(Ze.intMod(Ze.intDiv(a,60),60)),u=Math.abs(Ze.intMod(a,60)),c=r.length(),d=s;r.append(a<0?"-":"+").appendChar(Ze.intDiv(s,10)+"0").appendChar(Ze.intMod(s,10)+"0"),(this.type>=3||this.type>=1&&l>0)&&(r.append(this.type%2===0?":":"").appendChar(Ze.intDiv(l,10)+"0").appendChar(l%10+"0"),d+=l,(this.type>=7||this.type>=5&&u>0)&&(r.append(this.type%2===0?":":"").appendChar(Ze.intDiv(u,10)+"0").appendChar(u%10+"0"),d+=u)),d===0&&(r.setLength(c),r.append(this.noOffsetText))}return!0},e.parse=function(n,r,o){var a=r.length,s=this.noOffsetText.length;if(s===0){if(o===a)return n.setParsedField(Me.OFFSET_SECONDS,0,o,o)}else{if(o===a)return~o;if(n.subSequenceEquals(r,o,this.noOffsetText,0,s))return n.setParsedField(Me.OFFSET_SECONDS,0,o,o+s)}var l=r[o];if(l==="+"||l==="-"){var u=l==="-"?-1:1,c=[0,0,0,0];if(c[0]=o+1,(this._parseNumber(c,1,r,!0)||this._parseNumber(c,2,r,this.type>=3)||this._parseNumber(c,3,r,!1))===!1){var d=Ze.safeZero(u*(c[1]*3600+c[2]*60+c[3]));return n.setParsedField(Me.OFFSET_SECONDS,d,o,c[0])}}return s===0?n.setParsedField(Me.OFFSET_SECONDS,0,o,o+s):~o},e._parseNumber=function(n,r,o,a){if((this.type+3)/2<r)return!1;var s=n[0];if(this.type%2===0&&r>1){if(s+1>o.length||o[s]!==":")return a;s++}if(s+2>o.length)return a;var l=o[s++],u=o[s++];if(l<"0"||l>"9"||u<"0"||u>"9")return a;var c=(l.charCodeAt(0)-48)*10+(u.charCodeAt(0)-48);return c<0||c>59?a:(n[r]=c,n[0]=s,!1)},e.toString=function(){var n=this.noOffsetText.replace("'","''");return"Offset("+GU[this.type]+",'"+n+"')"},t})();Jy.INSTANCE_ID=new Jy("Z","+HH:MM:ss");Jy.PATTERNS=GU;/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var AZ=(function(){function t(i,n,r){this._printerParser=i,this._padWidth=n,this._padChar=r}var e=t.prototype;return e.print=function(n,r){var o=r.length();if(this._printerParser.print(n,r)===!1)return!1;var a=r.length()-o;if(a>this._padWidth)throw new ai("Cannot print as output of "+a+" characters exceeds pad width of "+this._padWidth);for(var s=0;s<this._padWidth-a;s++)r.insert(o,this._padChar);return!0},e.parse=function(n,r,o){var a=n.isStrict(),s=n.isCaseSensitive();if(ha(!(o>r.length)),ha(o>=0),o===r.length)return~o;var l=o+this._padWidth;if(l>r.length){if(a)return~o;l=r.length}for(var u=o;u<l&&(s?r[u]===this._padChar:n.charEquals(r[u],this._padChar));)u++;r=r.substring(0,l);var c=this._printerParser.parse(n,r,u);return c!==l&&a?~(o+u):c},e.toString=function(){return"Pad("+this._printerParser+","+this._padWidth+(this._padChar===" "?")":",'"+this._padChar+"')")},t})(),Ep=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.print=function(){return!0},i.parse=function(r,o,a){switch(this){case e.SENSITIVE:r.setCaseSensitive(!0);break;case e.INSENSITIVE:r.setCaseSensitive(!1);break;case e.STRICT:r.setStrict(!0);break;case e.LENIENT:r.setStrict(!1);break}return a},i.toString=function(){switch(this){case e.SENSITIVE:return"ParseCaseSensitive(true)";case e.INSENSITIVE:return"ParseCaseSensitive(false)";case e.STRICT:return"ParseStrict(true)";case e.LENIENT:return"ParseStrict(false)"}},e})(mI);Ep.SENSITIVE=new Ep("SENSITIVE");Ep.INSENSITIVE=new Ep("INSENSITIVE");Ep.STRICT=new Ep("STRICT");Ep.LENIENT=new Ep("LENIENT");/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var OZ=(function(){function t(i){this._literal=i}var e=t.prototype;return e.print=function(n,r){return r.append(this._literal),!0},e.parse=function(n,r,o){var a=r.length;return ha(!(o>a||o<0)),n.subSequenceEquals(r,o,this._literal,0,this._literal.length)===!1?~o:o+this._literal.length},e.toString=function(){var n=this._literal.replace("'","''");return"'"+n+"'"},t})();/*
 * @copyright (c) 2016, Philipp Thürwächter, Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var k6=(function(){function t(){}return t.getRules=function(i){throw new ai("unsupported ZoneId:"+i)},t.getAvailableZoneIds=function(){return[]},t})(),Dy=(function(t){yn(e,t),e.ofId=function(r){var o=k6.getRules(r);return new e(r,o)};function e(n,r){var o;return o=t.call(this)||this,o._id=n,o._rules=r,o}var i=e.prototype;return i.id=function(){return this._id},i.rules=function(){return this._rules},e})(ra);/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Tke=(function(){function t(i,n){this.query=i,this.description=n}var e=t.prototype;return e.print=function(n,r){var o=n.getValueQuery(this.query);return o==null?!1:(r.append(o.id()),!0)},e.parse=function(n,r,o){var a=r.length;if(o>a||o===a)return~o;var s=r.charAt(o);if(s==="+"||s==="-"){var l=n.copy(),u=Jy.INSTANCE_ID.parse(l,r,o);if(u<0)return u;var c=l.getParsed(Me.OFFSET_SECONDS),d=en.ofTotalSeconds(c);return n.setParsedZone(d),u}else if(a>=o+2){var f=r.charAt(o+1);if(n.charEquals(s,"U")&&n.charEquals(f,"T"))return a>=o+3&&n.charEquals(r.charAt(o+2),"C")?this._parsePrefixedOffset(n,r,o,o+3):this._parsePrefixedOffset(n,r,o,o+2);if(n.charEquals(s,"G")&&a>=o+3&&n.charEquals(f,"M")&&n.charEquals(r.charAt(o+2),"T"))return this._parsePrefixedOffset(n,r,o,o+3)}if(r.substr(o,6)==="SYSTEM")return n.setParsedZone(ra.systemDefault()),o+6;if(n.charEquals(s,"Z"))return n.setParsedZone(en.UTC),o+1;var h=k6.getAvailableZoneIds();uY.size!==h.length&&(uY=xke.createTreeMap(h));for(var p=a-o,g=uY.treeMap,v=null,y=0;g!=null;){var m=r.substr(o,Math.min(g.length,p));g=g.get(m),g!=null&&g.isLeaf&&(v=m,y=g.length)}return v!=null?(n.setParsedZone(Dy.ofId(v)),o+y):~o},e._parsePrefixedOffset=function(n,r,o,a){var s=r.substring(o,a).toUpperCase(),l=n.copy();if(a<r.length&&n.charEquals(r.charAt(a),"Z"))return n.setParsedZone(ra.ofOffset(s,en.UTC)),a;var u=Jy.INSTANCE_ID.parse(l,r,a);if(u<0)return n.setParsedZone(ra.ofOffset(s,en.UTC)),a;var c=l.getParsed(Me.OFFSET_SECONDS),d=en.ofTotalSeconds(c);return n.setParsedZone(ra.ofOffset(s,d)),u},e.toString=function(){return this.description},t})(),xke=(function(){t.createTreeMap=function(i){for(var n=i.sort(function(a,s){return a.length-s.length}),r=new oyt(n[0].length,!1),o=0;o<n.length;o++)r.add(n[o]);return new t(n.length,r)};function t(e,i){this.size=e,this.treeMap=i}return t})(),oyt=(function(){function t(i,n){i===void 0&&(i=0),n===void 0&&(n=!1),this.length=i,this.isLeaf=n,this._treeMap={}}var e=t.prototype;return e.add=function(n){var r=n.length;if(r===this.length)this._treeMap[n]=new t(r,!0);else if(r>this.length){var o=n.substr(0,this.length),a=this._treeMap[o];a==null&&(a=new t(r,!1),this._treeMap[o]=a),a.add(n)}},e.get=function(n){return this._treeMap[n]},t})(),uY=new xke([]);/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var O0=15,fa=(function(){function t(){this._active=this,this._parent=null,this._printerParsers=[],this._optional=!1,this._padNextWidth=0,this._padNextChar=null,this._valueParserIndex=-1}t._of=function(n,r){yt(n,"parent"),yt(r,"optional");var o=new t;return o._parent=n,o._optional=r,o};var e=t.prototype;return e.parseCaseSensitive=function(){return this._appendInternalPrinterParser(Ep.SENSITIVE),this},e.parseCaseInsensitive=function(){return this._appendInternalPrinterParser(Ep.INSENSITIVE),this},e.parseStrict=function(){return this._appendInternalPrinterParser(Ep.STRICT),this},e.parseLenient=function(){return this._appendInternalPrinterParser(Ep.LENIENT),this},e.parseDefaulting=function(n,r){return yt(n),this._appendInternal(new syt(n,r)),this},e.appendValue=function(){return arguments.length===1?this._appendValue1.apply(this,arguments):arguments.length===2?this._appendValue2.apply(this,arguments):this._appendValue4.apply(this,arguments)},e._appendValue1=function(n){return yt(n),this._appendValuePrinterParser(new xL(n,1,O0,Mo.NORMAL)),this},e._appendValue2=function(n,r){if(yt(n),r<1||r>O0)throw new Pi("The width must be from 1 to "+O0+" inclusive but was "+r);var o=new xL(n,r,r,Mo.NOT_NEGATIVE);return this._appendValuePrinterParser(o),this},e._appendValue4=function(n,r,o,a){if(yt(n),yt(a),r===o&&a===Mo.NOT_NEGATIVE)return this._appendValue2(n,o);if(r<1||r>O0)throw new Pi("The minimum width must be from 1 to "+O0+" inclusive but was "+r);if(o<1||o>O0)throw new Pi("The minimum width must be from 1 to "+O0+" inclusive but was "+o);if(o<r)throw new Pi("The maximum width must exceed or equal the minimum width but "+o+" < "+r);var s=new xL(n,r,o,a);return this._appendValuePrinterParser(s),this},e.appendValueReduced=function(){return arguments.length===4&&arguments[3]instanceof A3?this._appendValueReducedFieldWidthMaxWidthBaseDate.apply(this,arguments):this._appendValueReducedFieldWidthMaxWidthBaseValue.apply(this,arguments)},e._appendValueReducedFieldWidthMaxWidthBaseValue=function(n,r,o,a){yt(n,"field");var s=new Aj(n,r,o,a,null);return this._appendValuePrinterParser(s),this},e._appendValueReducedFieldWidthMaxWidthBaseDate=function(n,r,o,a){yt(n,"field"),yt(a,"baseDate"),_i(a,A3,"baseDate");var s=new Aj(n,r,o,0,a);return this._appendValuePrinterParser(s),this},e._appendValuePrinterParser=function(n){if(ha(n!=null),this._active._valueParserIndex>=0&&this._active._printerParsers[this._active._valueParserIndex]instanceof xL){var r=this._active._valueParserIndex,o=this._active._printerParsers[r];n.minWidth()===n.maxWidth()&&n.signStyle()===Mo.NOT_NEGATIVE?(o=o.withSubsequentWidth(n.maxWidth()),this._appendInternal(n.withFixedWidth()),this._active._valueParserIndex=r):(o=o.withFixedWidth(),this._active._valueParserIndex=this._appendInternal(n)),this._active._printerParsers[r]=o}else this._active._valueParserIndex=this._appendInternal(n);return this},e.appendFraction=function(n,r,o,a){return this._appendInternal(new Cke(n,r,o,a)),this},e.appendInstant=function(n){if(n===void 0&&(n=-2),n<-2||n>9)throw new Pi("Invalid fractional digits: "+n);return this._appendInternal(new ayt(n)),this},e.appendOffsetId=function(){return this._appendInternal(Jy.INSTANCE_ID),this},e.appendOffset=function(n,r){return this._appendInternalPrinterParser(new Jy(r,n)),this},e.appendZoneId=function(){return this._appendInternal(new Tke(Dr.zoneId(),"ZoneId()")),this},e.appendPattern=function(n){return yt(n,"pattern"),this._parsePattern(n),this},e.appendZoneText=function(){throw new Pi("Pattern using (localized) text not implemented, use @js-joda/locale plugin!")},e.appendText=function(){throw new Pi("Pattern using (localized) text not implemented, use @js-joda/locale plugin!")},e.appendLocalizedOffset=function(){throw new Pi("Pattern using (localized) text not implemented, use @js-joda/locale plugin!")},e.appendWeekField=function(){throw new Pi("Pattern using (localized) text not implemented, use @js-joda/locale plugin!")},e._parsePattern=function(n){for(var r={G:Me.ERA,y:Me.YEAR_OF_ERA,u:Me.YEAR,Q:pv.QUARTER_OF_YEAR,q:pv.QUARTER_OF_YEAR,M:Me.MONTH_OF_YEAR,L:Me.MONTH_OF_YEAR,D:Me.DAY_OF_YEAR,d:Me.DAY_OF_MONTH,F:Me.ALIGNED_DAY_OF_WEEK_IN_MONTH,E:Me.DAY_OF_WEEK,c:Me.DAY_OF_WEEK,e:Me.DAY_OF_WEEK,a:Me.AMPM_OF_DAY,H:Me.HOUR_OF_DAY,k:Me.CLOCK_HOUR_OF_DAY,K:Me.HOUR_OF_AMPM,h:Me.CLOCK_HOUR_OF_AMPM,m:Me.MINUTE_OF_HOUR,s:Me.SECOND_OF_MINUTE,S:Me.NANO_OF_SECOND,A:Me.MILLI_OF_DAY,n:Me.NANO_OF_SECOND,N:Me.NANO_OF_DAY},o=0;o<n.length;o++){var a=n.charAt(o);if(a>="A"&&a<="Z"||a>="a"&&a<="z"){for(var s=o++;o<n.length&&n.charAt(o)===a;o++);var l=o-s;if(a==="p"){var u=0;if(o<n.length&&(a=n.charAt(o),a>="A"&&a<="Z"||a>="a"&&a<="z")){for(u=l,s=o++;o<n.length&&n.charAt(o)===a;o++);l=o-s}if(u===0)throw new Pi("Pad letter 'p' must be followed by valid pad pattern: "+n);this.padNext(u)}var c=r[a];if(c!=null)this._parseField(a,l,c);else if(a==="z"){if(l>4)throw new Pi("Too many pattern letters: "+a);l===4?this.appendZoneText(Bo.FULL):this.appendZoneText(Bo.SHORT)}else if(a==="V"){if(l!==2)throw new Pi("Pattern letter count must be 2: "+a);this.appendZoneId()}else if(a==="Z")if(l<4)this.appendOffset("+HHMM","+0000");else if(l===4)this.appendLocalizedOffset(Bo.FULL);else if(l===5)this.appendOffset("+HH:MM:ss","Z");else throw new Pi("Too many pattern letters: "+a);else if(a==="O")if(l===1)this.appendLocalizedOffset(Bo.SHORT);else if(l===4)this.appendLocalizedOffset(Bo.FULL);else throw new Pi("Pattern letter count must be 1 or 4: "+a);else if(a==="X"){if(l>5)throw new Pi("Too many pattern letters: "+a);this.appendOffset(Jy.PATTERNS[l+(l===1?0:1)],"Z")}else if(a==="x"){if(l>5)throw new Pi("Too many pattern letters: "+a);var d=l===1?"+00":l%2===0?"+0000":"+00:00";this.appendOffset(Jy.PATTERNS[l+(l===1?0:1)],d)}else if(a==="W"){if(l>1)throw new Pi("Too many pattern letters: "+a);this.appendWeekField("W",l)}else if(a==="w"){if(l>2)throw new Pi("Too many pattern letters: "+a);this.appendWeekField("w",l)}else if(a==="Y")this.appendWeekField("Y",l);else throw new Pi("Unknown pattern letter: "+a);o--}else if(a==="'"){for(var f=o++;o<n.length;o++)if(n.charAt(o)==="'")if(o+1<n.length&&n.charAt(o+1)==="'")o++;else break;if(o>=n.length)throw new Pi("Pattern ends with an incomplete string literal: "+n);var h=n.substring(f+1,o);h.length===0?this.appendLiteral("'"):this.appendLiteral(h.replace("''","'"))}else if(a==="[")this.optionalStart();else if(a==="]"){if(this._active._parent===null)throw new Pi("Pattern invalid as it contains ] without previous [");this.optionalEnd()}else{if(a==="{"||a==="}"||a==="#")throw new Pi("Pattern includes reserved character: '"+a+"'");this.appendLiteral(a)}}},e._parseField=function(n,r,o){switch(n){case"u":case"y":r===2?this.appendValueReduced(o,2,2,Aj.BASE_DATE):r<4?this.appendValue(o,r,O0,Mo.NORMAL):this.appendValue(o,r,O0,Mo.EXCEEDS_PAD);break;case"M":case"Q":switch(r){case 1:this.appendValue(o);break;case 2:this.appendValue(o,2);break;case 3:this.appendText(o,Bo.SHORT);break;case 4:this.appendText(o,Bo.FULL);break;case 5:this.appendText(o,Bo.NARROW);break;default:throw new Pi("Too many pattern letters: "+n)}break;case"L":case"q":switch(r){case 1:this.appendValue(o);break;case 2:this.appendValue(o,2);break;case 3:this.appendText(o,Bo.SHORT_STANDALONE);break;case 4:this.appendText(o,Bo.FULL_STANDALONE);break;case 5:this.appendText(o,Bo.NARROW_STANDALONE);break;default:throw new Pi("Too many pattern letters: "+n)}break;case"e":switch(r){case 1:case 2:this.appendWeekField("e",r);break;case 3:this.appendText(o,Bo.SHORT);break;case 4:this.appendText(o,Bo.FULL);break;case 5:this.appendText(o,Bo.NARROW);break;default:throw new Pi("Too many pattern letters: "+n)}break;case"c":switch(r){case 1:this.appendWeekField("c",r);break;case 2:throw new Pi("Invalid number of pattern letters: "+n);case 3:this.appendText(o,Bo.SHORT_STANDALONE);break;case 4:this.appendText(o,Bo.FULL_STANDALONE);break;case 5:this.appendText(o,Bo.NARROW_STANDALONE);break;default:throw new Pi("Too many pattern letters: "+n)}break;case"a":if(r===1)this.appendText(o,Bo.SHORT);else throw new Pi("Too many pattern letters: "+n);break;case"E":case"G":switch(r){case 1:case 2:case 3:this.appendText(o,Bo.SHORT);break;case 4:this.appendText(o,Bo.FULL);break;case 5:this.appendText(o,Bo.NARROW);break;default:throw new Pi("Too many pattern letters: "+n)}break;case"S":this.appendFraction(Me.NANO_OF_SECOND,r,r,!1);break;case"F":if(r===1)this.appendValue(o);else throw new Pi("Too many pattern letters: "+n);break;case"d":case"h":case"H":case"k":case"K":case"m":case"s":if(r===1)this.appendValue(o);else if(r===2)this.appendValue(o,r);else throw new Pi("Too many pattern letters: "+n);break;case"D":if(r===1)this.appendValue(o);else if(r<=3)this.appendValue(o,r);else throw new Pi("Too many pattern letters: "+n);break;default:r===1?this.appendValue(o):this.appendValue(o,r);break}},e.padNext=function(){return arguments.length===1?this._padNext1.apply(this,arguments):this._padNext2.apply(this,arguments)},e._padNext1=function(n){return this._padNext2(n," ")},e._padNext2=function(n,r){if(n<1)throw new Pi("The pad width must be at least one but was "+n);return this._active._padNextWidth=n,this._active._padNextChar=r,this._active._valueParserIndex=-1,this},e.optionalStart=function(){return this._active._valueParserIndex=-1,this._active=t._of(this._active,!0),this},e.optionalEnd=function(){if(this._active._parent==null)throw new E3("Cannot call optionalEnd() as there was no previous call to optionalStart()");if(this._active._printerParsers.length>0){var n=new wZ(this._active._printerParsers,this._active._optional);this._active=this._active._parent,this._appendInternal(n)}else this._active=this._active._parent;return this},e._appendInternal=function(n){return ha(n!=null),this._active._padNextWidth>0&&(n!=null&&(n=new AZ(n,this._active._padNextWidth,this._active._padNextChar)),this._active._padNextWidth=0,this._active._padNextChar=0),this._active._printerParsers.push(n),this._active._valueParserIndex=-1,this._active._printerParsers.length-1},e.appendLiteral=function(n){return ha(n!=null),n.length>0&&(n.length===1?this._appendInternalPrinterParser(new Pke(n.charAt(0))):this._appendInternalPrinterParser(new OZ(n))),this},e._appendInternalPrinterParser=function(n){return ha(n!=null),this._active._padNextWidth>0&&(n!=null&&(n=new AZ(n,this._active._padNextWidth,this._active._padNextChar)),this._active._padNextWidth=0,this._active._padNextChar=0),this._active._printerParsers.push(n),this._active._valueParserIndex=-1,this._active._printerParsers.length-1},e.append=function(n){return yt(n,"formatter"),this._appendInternal(n._toPrinterParser(!1)),this},e.toFormatter=function(n){for(n===void 0&&(n=ln.SMART);this._active._parent!=null;)this.optionalEnd();var r=new wZ(this._printerParsers,!1);return new Nn(r,null,gz.STANDARD,n,null,null,null)},t})(),eL=146097*25*86400,eN=(146097*5-(30*365+7))*86400,ayt=(function(){function t(i){this.fractionalDigits=i}var e=t.prototype;return e.print=function(n,r){var o=n.getValue(Me.INSTANT_SECONDS),a=0;if(n.temporal().isSupported(Me.NANO_OF_SECOND)&&(a=n.temporal().getLong(Me.NANO_OF_SECOND)),o==null)return!1;var s=o,l=Me.NANO_OF_SECOND.checkValidIntValue(a);if(s>=-eN){var u=s-eL+eN,c=Ze.floorDiv(u,eL)+1,d=Ze.floorMod(u,eL),f=ia.ofEpochSecond(d-eN,0,en.UTC);c>0&&r.append("+").append(c),r.append(f.toString()),f.second()===0&&r.append(":00")}else{var h=s+eN,p=Ze.intDiv(h,eL),g=Ze.intMod(h,eL),v=ia.ofEpochSecond(g-eN,0,en.UTC),y=r.length();r.append(v.toString()),v.second()===0&&r.append(":00"),p<0&&(v.year()===-1e4?r.replace(y,y+2,""+(p-1)):g===0?r.insert(y,p):r.insert(y+1,Math.abs(p)))}if(this.fractionalDigits===-2)l!==0&&(r.append("."),Ze.intMod(l,1e6)===0?r.append((""+(Ze.intDiv(l,1e6)+1e3)).substring(1)):Ze.intMod(l,1e3)===0?r.append((""+(Ze.intDiv(l,1e3)+1e6)).substring(1)):r.append((""+(l+1e9)).substring(1)));else if(this.fractionalDigits>0||this.fractionalDigits===-1&&l>0){r.append(".");for(var m=1e8,b=0;this.fractionalDigits===-1&&l>0||b<this.fractionalDigits;b++){var S=Ze.intDiv(l,m);r.append(S),l=l-S*m,m=Ze.intDiv(m,10)}}return r.append("Z"),!0},e.parse=function(n,r,o){var a=n.copy(),s=this.fractionalDigits<0?0:this.fractionalDigits,l=this.fractionalDigits<0?9:this.fractionalDigits,u=new fa().append(Nn.ISO_LOCAL_DATE).appendLiteral("T").appendValue(Me.HOUR_OF_DAY,2).appendLiteral(":").appendValue(Me.MINUTE_OF_HOUR,2).appendLiteral(":").appendValue(Me.SECOND_OF_MINUTE,2).appendFraction(Me.NANO_OF_SECOND,s,l,!0).appendLiteral("Z").toFormatter()._toPrinterParser(!1),c=u.parse(a,r,o);if(c<0)return c;var d=a.getParsed(Me.YEAR),f=a.getParsed(Me.MONTH_OF_YEAR),h=a.getParsed(Me.DAY_OF_MONTH),p=a.getParsed(Me.HOUR_OF_DAY),g=a.getParsed(Me.MINUTE_OF_HOUR),v=a.getParsed(Me.SECOND_OF_MINUTE),y=a.getParsed(Me.NANO_OF_SECOND),m=v??0,b=y??0,S=Ze.intMod(d,1e4),_=0;p===24&&g===0&&m===0&&b===0?(p=0,_=1):p===23&&g===59&&m===60&&(n.setParsedLeapSecond(),m=59);var C;try{var P=ia.of(S,f,h,p,g,m,0).plusDays(_);C=P.toEpochSecond(en.UTC),C+=Ze.safeMultiply(Ze.intDiv(d,1e4),eL)}catch{return~o}var x=c;return x=n.setParsedField(Me.INSTANT_SECONDS,C,o,x),n.setParsedField(Me.NANO_OF_SECOND,b,o,x)},e.toString=function(){return"Instant()"},t})(),syt=(function(){function t(i,n){this._field=i,this._value=n}var e=t.prototype;return e.print=function(){return!0},e.parse=function(n,r,o){return n.getParsed(this._field)==null&&n.setParsedField(this._field,this._value,o,o),o},t})();function lyt(){Aj.BASE_DATE=Ci.of(2e3,1,1),fa.CompositePrinterParser=wZ,fa.PadPrinterParserDecorator=AZ,fa.SettingsParser=Ep,fa.CharLiteralPrinterParser=OZ,fa.StringLiteralPrinterParser=OZ,fa.CharLiteralPrinterParser=Pke,fa.NumberPrinterParser=xL,fa.ReducedPrinterParser=Aj,fa.FractionPrinterParser=Cke,fa.OffsetIdPrinterParser=Jy,fa.ZoneIdPrinterParser=Tke}/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Eke=(function(){function t(){this._str=""}var e=t.prototype;return e.append=function(n){return this._str+=n,this},e.appendChar=function(n){return this._str+=n[0],this},e.insert=function(n,r){return this._str=this._str.slice(0,n)+r+this._str.slice(n),this},e.replace=function(n,r,o){return this._str=this._str.slice(0,n)+o+this._str.slice(r),this},e.length=function(){return this._str.length},e.setLength=function(n){return this._str=this._str.slice(0,n),this},e.toString=function(){return this._str},t})();/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Nn=(function(){t.parsedExcessDays=function(){return t.PARSED_EXCESS_DAYS},t.parsedLeapSecond=function(){return t.PARSED_LEAP_SECOND},t.ofPattern=function(n){return new fa().appendPattern(n).toFormatter()};function t(i,n,r,o,a,s,l){s===void 0&&(s=ta.INSTANCE),ha(i!=null),ha(r!=null),ha(o!=null),this._printerParser=i,this._locale=n,this._decimalStyle=r,this._resolverStyle=o,this._resolverFields=a,this._chrono=s,this._zone=l}var e=t.prototype;return e.locale=function(){return this._locale},e.decimalStyle=function(){return this._decimalStyle},e.chronology=function(){return this._chrono},e.withChronology=function(n){return this._chrono!=null&&this._chrono.equals(n)?this:new t(this._printerParser,this._locale,this._decimalStyle,this._resolverStyle,this._resolverFields,n,this._zone)},e.withLocale=function(){return this},e.withResolverStyle=function(n){return yt(n,"resolverStyle"),n.equals(this._resolverStyle)?this:new t(this._printerParser,this._locale,this._decimalStyle,n,this._resolverFields,this._chrono,this._zone)},e.format=function(n){var r=new Eke(32);return this._formatTo(n,r),r.toString()},e._formatTo=function(n,r){yt(n,"temporal"),yt(r,"appendable");var o=new _ke(n,this);this._printerParser.print(o,r)},e.parse=function(n,r){return arguments.length===1?this.parse1(n):this.parse2(n,r)},e.parse1=function(n){yt(n,"text");try{return this._parseToBuilder(n,null).resolve(this._resolverStyle,this._resolverFields)}catch(r){throw r instanceof Pv?r:this._createError(n,r)}},e.parse2=function(n,r){yt(n,"text"),yt(r,"type");try{var o=this._parseToBuilder(n,null).resolve(this._resolverStyle,this._resolverFields);return o.build(r)}catch(a){throw a instanceof Pv?a:this._createError(n,a)}},e._createError=function(n,r){var o="";return n.length>64?o=n.substring(0,64)+"...":o=n,new Pv("Text '"+o+"' could not be parsed: "+r.message,n,0,r)},e._parseToBuilder=function(n,r){var o=r??new mke(0),a=this._parseUnresolved0(n,o);if(a==null||o.getErrorIndex()>=0||r==null&&o.getIndex()<n.length){var s="";throw n.length>64?s=n.substr(0,64).toString()+"...":s=n,o.getErrorIndex()>=0?new Pv("Text '"+s+"' could not be parsed at index "+o.getErrorIndex(),n,o.getErrorIndex()):new Pv("Text '"+s+"' could not be parsed, unparsed text found at index "+o.getIndex(),n,o.getIndex())}return a.toBuilder()},e.parseUnresolved=function(n,r){return this._parseUnresolved0(n,r)},e._parseUnresolved0=function(n,r){ha(n!=null,"text",hS),ha(r!=null,"position",hS);var o=new Ske(this),a=r.getIndex();return a=this._printerParser.parse(o,n,a),a<0?(r.setErrorIndex(~a),null):(r.setIndex(a),o.toParsed())},e._toPrinterParser=function(n){return this._printerParser.withOptional(n)},e.toString=function(){var n=this._printerParser.toString();return n.indexOf("[")===0?n:n.substring(1,n.length-1)},t})();function uyt(){Nn.ISO_LOCAL_DATE=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).appendLiteral("-").appendValue(Me.MONTH_OF_YEAR,2).appendLiteral("-").appendValue(Me.DAY_OF_MONTH,2).toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_LOCAL_TIME=new fa().appendValue(Me.HOUR_OF_DAY,2).appendLiteral(":").appendValue(Me.MINUTE_OF_HOUR,2).optionalStart().appendLiteral(":").appendValue(Me.SECOND_OF_MINUTE,2).optionalStart().appendFraction(Me.NANO_OF_SECOND,0,9,!0).toFormatter(ln.STRICT),Nn.ISO_LOCAL_DATE_TIME=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_DATE).appendLiteral("T").append(Nn.ISO_LOCAL_TIME).toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_INSTANT=new fa().parseCaseInsensitive().appendInstant().toFormatter(ln.STRICT),Nn.ISO_OFFSET_DATE_TIME=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_DATE_TIME).appendOffsetId().toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_ZONED_DATE_TIME=new fa().append(Nn.ISO_OFFSET_DATE_TIME).optionalStart().appendLiteral("[").parseCaseSensitive().appendZoneId().appendLiteral("]").toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.BASIC_ISO_DATE=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).appendValue(Me.MONTH_OF_YEAR,2).appendValue(Me.DAY_OF_MONTH,2).toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_OFFSET_DATE=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_DATE).appendOffsetId().toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_OFFSET_TIME=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_TIME).appendOffsetId().toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_ORDINAL_DATE=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).appendLiteral("-").appendValue(Me.DAY_OF_YEAR).toFormatter(ln.STRICT),Nn.ISO_WEEK_DATE=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).appendLiteral("-W").appendValue(Me.ALIGNED_WEEK_OF_YEAR).appendLiteral("-").appendValue(Me.DAY_OF_WEEK).toFormatter(ln.STRICT),Nn.ISO_DATE=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_DATE).optionalStart().appendOffsetId().optionalEnd().toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.ISO_TIME=new fa().parseCaseInsensitive().append(Nn.ISO_LOCAL_TIME).optionalStart().appendOffsetId().optionalEnd().toFormatter(ln.STRICT),Nn.ISO_DATE_TIME=new fa().append(Nn.ISO_LOCAL_DATE_TIME).optionalStart().appendOffsetId().optionalEnd().toFormatter(ln.STRICT).withChronology(ta.INSTANCE),Nn.PARSED_EXCESS_DAYS=Ou("PARSED_EXCESS_DAYS",function(t){return t instanceof pz?t.excessDays:nS.ZERO}),Nn.PARSED_LEAP_SECOND=Ou("PARSED_LEAP_SECOND",function(t){return t instanceof pz?t.leapSecond:!1})}var vz=(function(t){yn(e,t),e.now=function(r){return arguments.length===0?e.now0():arguments.length===1&&r instanceof ra?e.nowZoneId(r):e.nowClock(r)},e.now0=function(){return this.nowClock(Ma.systemDefaultZone())},e.nowZoneId=function(r){return yt(r,"zone"),this.nowClock(Ma.system(r))},e.nowClock=function(r){yt(r,"clock");var o=Ci.now(r);return e.of(o.month(),o.dayOfMonth())},e.of=function(r,o){return arguments.length===2&&r instanceof qi?e.ofMonthNumber(r,o):e.ofNumberNumber(r,o)},e.ofMonthNumber=function(r,o){if(yt(r,"month"),Me.DAY_OF_MONTH.checkValidValue(o),o>r.maxLength())throw new ai("Illegal value for DayOfMonth field, value "+o+" is not valid for month "+r.toString());return new e(r.value(),o)},e.ofNumberNumber=function(r,o){return yt(r,"month"),yt(o,"dayOfMonth"),e.of(qi.of(r),o)},e.from=function(r){if(yt(r,"temporal"),_i(r,xP,"temporal"),r instanceof e)return r;try{return e.of(r.get(Me.MONTH_OF_YEAR),r.get(Me.DAY_OF_MONTH))}catch{throw new ai("Unable to obtain MonthDay from TemporalAccessor: "+r+", type "+(r&&r.constructor!=null?r.constructor.name:""))}},e.parse=function(r,o){return arguments.length===1?e.parseString(r):e.parseStringFormatter(r,o)},e.parseString=function(r){return e.parseStringFormatter(r,wke)},e.parseStringFormatter=function(r,o){return yt(r,"text"),yt(o,"formatter"),_i(o,Nn,"formatter"),o.parse(r,e.FROM)};function e(n,r){var o;return o=t.call(this)||this,o._month=Ze.safeToInt(n),o._day=Ze.safeToInt(r),o}var i=e.prototype;return i.monthValue=function(){return this._month},i.month=function(){return qi.of(this._month)},i.dayOfMonth=function(){return this._day},i.isSupported=function(r){return r instanceof Me?r===Me.MONTH_OF_YEAR||r===Me.DAY_OF_MONTH:r!=null&&r.isSupportedBy(this)},i.range=function(r){return r===Me.MONTH_OF_YEAR?r.range():r===Me.DAY_OF_MONTH?dn.of(1,this.month().minLength(),this.month().maxLength()):t.prototype.range.call(this,r)},i.get=function(r){return this.range(r).checkValidIntValue(this.getLong(r),r)},i.getLong=function(r){if(yt(r,"field"),r instanceof Me){switch(r){case Me.DAY_OF_MONTH:return this._day;case Me.MONTH_OF_YEAR:return this._month}throw new Qn("Unsupported field: "+r)}return r.getFrom(this)},i.isValidYear=function(r){return!(this._day===29&&this._month===2&&Av.isLeap(r)===!1)},i.withMonth=function(r){return this.with(qi.of(r))},i.with=function(r){if(yt(r,"month"),r.value()===this._month)return this;var o=Math.min(this._day,r.maxLength());return new e(r.value(),o)},i.withDayOfMonth=function(r){return r===this._day?this:e.of(this._month,r)},i.query=function(r){return yt(r,"query"),_i(r,NV,"query"),r===Dr.chronology()?ta.INSTANCE:t.prototype.query.call(this,r)},i.adjustInto=function(r){return yt(r,"temporal"),r=r.with(Me.MONTH_OF_YEAR,this._month),r.with(Me.DAY_OF_MONTH,Math.min(r.range(Me.DAY_OF_MONTH).maximum(),this._day))},i.atYear=function(r){return Ci.of(r,this._month,this.isValidYear(r)?this._day:28)},i.compareTo=function(r){yt(r,"other"),_i(r,e,"other");var o=this._month-r.monthValue();return o===0&&(o=this._day-r.dayOfMonth()),o},i.isAfter=function(r){return yt(r,"other"),_i(r,e,"other"),this.compareTo(r)>0},i.isBefore=function(r){return yt(r,"other"),_i(r,e,"other"),this.compareTo(r)<0},i.equals=function(r){if(this===r)return!0;if(r instanceof e){var o=r;return this.monthValue()===o.monthValue()&&this.dayOfMonth()===o.dayOfMonth()}return!1},i.toString=function(){return"--"+(this._month<10?"0":"")+this._month+(this._day<10?"-0":"-")+this._day},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),_i(r,Nn,"formatter"),r.format(this)},e})(xP),wke;function cyt(){wke=new fa().appendLiteral("--").appendValue(Me.MONTH_OF_YEAR,2).appendLiteral("-").appendValue(Me.DAY_OF_MONTH,2).toFormatter(),vz.FROM=Ou("MonthDay.FROM",function(t){return vz.from(t)})}var O3=(function(t){yn(e,t),e.now=function(r){return arguments.length===0?e.now0():arguments.length===1&&r instanceof ra?e.nowZoneId(r):e.nowClock(r)},e.now0=function(){return e.nowClock(Ma.systemDefaultZone())},e.nowZoneId=function(r){return e.nowClock(Ma.system(r))},e.nowClock=function(r){var o=Ci.now(r);return e.of(o.year(),o.month())},e.of=function(r,o){return arguments.length===2&&o instanceof qi?e.ofNumberMonth(r,o):e.ofNumberNumber(r,o)},e.ofNumberMonth=function(r,o){return yt(o,"month"),_i(o,qi,"month"),e.ofNumberNumber(r,o.value())},e.ofNumberNumber=function(r,o){return yt(r,"year"),yt(o,"month"),Me.YEAR.checkValidValue(r),Me.MONTH_OF_YEAR.checkValidValue(o),new e(r,o)},e.from=function(r){if(yt(r,"temporal"),r instanceof e)return r;try{return e.of(r.get(Me.YEAR),r.get(Me.MONTH_OF_YEAR))}catch{throw new ai("Unable to obtain YearMonth from TemporalAccessor: "+r+", type "+(r&&r.constructor!=null?r.constructor.name:""))}},e.parse=function(r,o){return arguments.length===1?e.parseString(r):e.parseStringFormatter(r,o)},e.parseString=function(r){return e.parseStringFormatter(r,DZ)},e.parseStringFormatter=function(r,o){return yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r){var o;return o=t.call(this)||this,o._year=Ze.safeToInt(n),o._month=Ze.safeToInt(r),o}var i=e.prototype;return i.isSupported=function(r){return arguments.length===1&&r instanceof Ky?this.isSupportedField(r):this.isSupportedUnit(r)},i.isSupportedField=function(r){return r instanceof Me?r===Me.YEAR||r===Me.MONTH_OF_YEAR||r===Me.PROLEPTIC_MONTH||r===Me.YEAR_OF_ERA||r===Me.ERA:r!=null&&r.isSupportedBy(this)},i.isSupportedUnit=function(r){return r instanceof ft?r===ft.MONTHS||r===ft.YEARS||r===ft.DECADES||r===ft.CENTURIES||r===ft.MILLENNIA||r===ft.ERAS:r!=null&&r.isSupportedBy(this)},i.range=function(r){return r===Me.YEAR_OF_ERA?this.year()<=0?dn.of(1,Av.MAX_VALUE+1):dn.of(1,Av.MAX_VALUE):t.prototype.range.call(this,r)},i.get=function(r){return yt(r,"field"),_i(r,Ky,"field"),this.range(r).checkValidIntValue(this.getLong(r),r)},i.getLong=function(r){if(yt(r,"field"),_i(r,Ky,"field"),r instanceof Me){switch(r){case Me.MONTH_OF_YEAR:return this._month;case Me.PROLEPTIC_MONTH:return this._getProlepticMonth();case Me.YEAR_OF_ERA:return this._year<1?1-this._year:this._year;case Me.YEAR:return this._year;case Me.ERA:return this._year<1?0:1}throw new Qn("Unsupported field: "+r)}return r.getFrom(this)},i._getProlepticMonth=function(){return Ze.safeAdd(Ze.safeMultiply(this._year,12),this._month-1)},i.year=function(){return this._year},i.monthValue=function(){return this._month},i.month=function(){return qi.of(this._month)},i.isLeapYear=function(){return ta.isLeapYear(this._year)},i.isValidDay=function(r){return r>=1&&r<=this.lengthOfMonth()},i.lengthOfMonth=function(){return this.month().length(this.isLeapYear())},i.lengthOfYear=function(){return this.isLeapYear()?366:365},i.with=function(r,o){return arguments.length===1?this._withAdjuster(r):this._withField(r,o)},i._withField=function(r,o){if(yt(r,"field"),_i(r,Ky,"field"),r instanceof Me){var a=r;switch(a.checkValidValue(o),a){case Me.MONTH_OF_YEAR:return this.withMonth(o);case Me.PROLEPTIC_MONTH:return this.plusMonths(o-this.getLong(Me.PROLEPTIC_MONTH));case Me.YEAR_OF_ERA:return this.withYear(this._year<1?1-o:o);case Me.YEAR:return this.withYear(o);case Me.ERA:return this.getLong(Me.ERA)===o?this:this.withYear(1-this._year)}throw new Qn("Unsupported field: "+r)}return r.adjustInto(this,o)},i.withYear=function(r){return Me.YEAR.checkValidValue(r),new e(r,this._month)},i.withMonth=function(r){return Me.MONTH_OF_YEAR.checkValidValue(r),new e(this._year,r)},i._plusUnit=function(r,o){if(yt(o,"unit"),_i(o,AS,"unit"),o instanceof ft){switch(o){case ft.MONTHS:return this.plusMonths(r);case ft.YEARS:return this.plusYears(r);case ft.DECADES:return this.plusYears(Ze.safeMultiply(r,10));case ft.CENTURIES:return this.plusYears(Ze.safeMultiply(r,100));case ft.MILLENNIA:return this.plusYears(Ze.safeMultiply(r,1e3));case ft.ERAS:return this.with(Me.ERA,Ze.safeAdd(this.getLong(Me.ERA),r))}throw new Qn("Unsupported unit: "+o)}return o.addTo(this,r)},i.plusYears=function(r){if(r===0)return this;var o=Me.YEAR.checkValidIntValue(this._year+r);return this.withYear(o)},i.plusMonths=function(r){if(r===0)return this;var o=this._year*12+(this._month-1),a=o+r,s=Me.YEAR.checkValidIntValue(Ze.floorDiv(a,12)),l=Ze.floorMod(a,12)+1;return new e(s,l)},i.minusYears=function(r){return r===Ze.MIN_SAFE_INTEGER?this.plusYears(Ze.MIN_SAFE_INTEGER).plusYears(1):this.plusYears(-r)},i.minusMonths=function(r){return r===Ze.MIN_SAFE_INTEGER?this.plusMonths(Math.MAX_SAFE_INTEGER).plusMonths(1):this.plusMonths(-r)},i.query=function(r){return yt(r,"query"),_i(r,NV,"query"),r===Dr.chronology()?ta.INSTANCE:r===Dr.precision()?ft.MONTHS:r===Dr.localDate()||r===Dr.localTime()||r===Dr.zone()||r===Dr.zoneId()||r===Dr.offset()?null:t.prototype.query.call(this,r)},i.adjustInto=function(r){return yt(r,"temporal"),_i(r,Rh,"temporal"),r.with(Me.PROLEPTIC_MONTH,this._getProlepticMonth())},i.until=function(r,o){yt(r,"endExclusive"),yt(o,"unit"),_i(r,Rh,"endExclusive"),_i(o,AS,"unit");var a=e.from(r);if(o instanceof ft){var s=a._getProlepticMonth()-this._getProlepticMonth();switch(o){case ft.MONTHS:return s;case ft.YEARS:return Ze.intDiv(s,12);case ft.DECADES:return Ze.intDiv(s,120);case ft.CENTURIES:return Ze.intDiv(s,1200);case ft.MILLENNIA:return Ze.intDiv(s,12e3);case ft.ERAS:return a.getLong(Me.ERA)-this.getLong(Me.ERA)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},i.atDay=function(r){return yt(r,"dayOfMonth"),Ci.of(this._year,this._month,r)},i.atEndOfMonth=function(){return Ci.of(this._year,this._month,this.lengthOfMonth())},i.compareTo=function(r){yt(r,"other"),_i(r,e,"other");var o=this._year-r.year();return o===0&&(o=this._month-r.monthValue()),o},i.isAfter=function(r){return this.compareTo(r)>0},i.isBefore=function(r){return this.compareTo(r)<0},i.equals=function(r){if(this===r)return!0;if(r instanceof e){var o=r;return this.year()===o.year()&&this.monthValue()===o.monthValue()}return!1},i.toString=function(){return DZ.format(this)},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),r.format(this)},e})(Rh),DZ;function dyt(){DZ=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).appendLiteral("-").appendValue(Me.MONTH_OF_YEAR,2).toFormatter(),O3.FROM=Ou("YearMonth.FROM",function(t){return O3.from(t)})}var Av=(function(t){yn(e,t);function e(n){var r;return r=t.call(this)||this,r._year=Ze.safeToInt(n),r}var i=e.prototype;return i.value=function(){return this._year},e.now=function(r){return r===void 0&&(r=void 0),r===void 0?e.now0():r instanceof ra?e.nowZoneId(r):e.nowClock(r)},e.now0=function(){return e.nowClock(Ma.systemDefaultZone())},e.nowZoneId=function(r){return yt(r,"zone"),_i(r,ra,"zone"),e.nowClock(Ma.system(r))},e.nowClock=function(r){yt(r,"clock"),_i(r,Ma,"clock");var o=Ci.now(r);return e.of(o.year())},e.of=function(r){return yt(r,"isoYear"),Me.YEAR.checkValidValue(r),new e(r)},e.from=function(r){if(yt(r,"temporal"),_i(r,xP,"temporal"),r instanceof e)return r;try{return e.of(r.get(Me.YEAR))}catch{throw new ai("Unable to obtain Year from TemporalAccessor: "+r+", type "+(r&&r.constructor!=null?r.constructor.name:""))}},e.parse=function(r,o){return arguments.length<=1?e.parseText(r):e.parseTextFormatter(r,o)},e.parseText=function(r){return yt(r,"text"),e.parse(r,RZ)},e.parseTextFormatter=function(r,o){return o===void 0&&(o=RZ),yt(r,"text"),yt(o,"formatter"),_i(o,Nn,"formatter"),o.parse(r,e.FROM)},e.isLeap=function(r){return Ze.intMod(r,4)===0&&(Ze.intMod(r,100)!==0||Ze.intMod(r,400)===0)},i.isSupported=function(r){return arguments.length===1&&r instanceof Ky?this.isSupportedField(r):this.isSupportedUnit(r)},i.isSupportedField=function(r){return r instanceof Me?r===Me.YEAR||r===Me.YEAR_OF_ERA||r===Me.ERA:r!=null&&r.isSupportedBy(this)},i.isSupportedUnit=function(r){return r instanceof ft?r===ft.YEARS||r===ft.DECADES||r===ft.CENTURIES||r===ft.MILLENNIA||r===ft.ERAS:r!=null&&r.isSupportedBy(this)},i.range=function(r){if(this.isSupported(r))return r.range();if(r instanceof Me)throw new Qn("Unsupported field: "+r);return t.prototype.range.call(this,r)},i.get=function(r){return this.range(r).checkValidIntValue(this.getLong(r),r)},i.getLong=function(r){if(yt(r,"field"),r instanceof Me){switch(r){case Me.YEAR_OF_ERA:return this._year<1?1-this._year:this._year;case Me.YEAR:return this._year;case Me.ERA:return this._year<1?0:1}throw new Qn("Unsupported field: "+r)}return r.getFrom(this)},i.isLeap=function(){return e.isLeap(this._year)},i._withField=function(r,o){if(yt(r,"field"),_i(r,Ky,"field"),r instanceof Me){switch(r.checkValidValue(o),r){case Me.YEAR_OF_ERA:return e.of(this._year<1?1-o:o);case Me.YEAR:return e.of(o);case Me.ERA:return this.getLong(Me.ERA)===o?this:e.of(1-this._year)}throw new Qn("Unsupported field: "+r)}return r.adjustInto(this,o)},i._plusUnit=function(r,o){if(yt(r,"amountToAdd"),yt(o,"unit"),_i(o,AS,"unit"),o instanceof ft){switch(o){case ft.YEARS:return this.plusYears(r);case ft.DECADES:return this.plusYears(Ze.safeMultiply(r,10));case ft.CENTURIES:return this.plusYears(Ze.safeMultiply(r,100));case ft.MILLENNIA:return this.plusYears(Ze.safeMultiply(r,1e3));case ft.ERAS:return this.with(Me.ERA,Ze.safeAdd(this.getLong(Me.ERA),r))}throw new Qn("Unsupported unit: "+o)}return o.addTo(this,r)},i.plusYears=function(r){return r===0?this:e.of(Me.YEAR.checkValidIntValue(Ze.safeAdd(this._year,r)))},i.minusYears=function(r){return r===Ze.MIN_SAFE_INTEGER?this.plusYears(Ze.MAX_SAFE_INTEGER).plusYears(1):this.plusYears(-r)},i.adjustInto=function(r){return yt(r,"temporal"),r.with(Me.YEAR,this._year)},i.isValidMonthDay=function(r){return r!=null&&r.isValidYear(this._year)},i.length=function(){return this.isLeap()?366:365},i.atDay=function(r){return Ci.ofYearDay(this._year,r)},i.atMonth=function(r){return arguments.length===1&&r instanceof qi?this.atMonthMonth(r):this.atMonthNumber(r)},i.atMonthMonth=function(r){return yt(r,"month"),_i(r,qi,"month"),O3.of(this._year,r)},i.atMonthNumber=function(r){return yt(r,"month"),O3.of(this._year,r)},i.atMonthDay=function(r){return yt(r,"monthDay"),_i(r,vz,"monthDay"),r.atYear(this._year)},i.query=function(r){return yt(r,"query()"),_i(r,NV,"query()"),r===Dr.chronology()?ta.INSTANCE:r===Dr.precision()?ft.YEARS:r===Dr.localDate()||r===Dr.localTime()||r===Dr.zone()||r===Dr.zoneId()||r===Dr.offset()?null:t.prototype.query.call(this,r)},i.compareTo=function(r){return yt(r,"other"),_i(r,e,"other"),this._year-r._year},i.isAfter=function(r){return yt(r,"other"),_i(r,e,"other"),this._year>r._year},i.isBefore=function(r){return yt(r,"other"),_i(r,e,"other"),this._year<r._year},i.format=function(r){return yt(r,"formatter"),_i(r,Nn,"formatter"),r.format(this)},i.equals=function(r){return this===r?!0:r instanceof e?this.value()===r.value():!1},i.toString=function(){return""+this._year},i.toJSON=function(){return this.toString()},i.until=function(r,o){var a=e.from(r);if(o instanceof ft){var s=a.value()-this.value();switch(o){case ft.YEARS:return s;case ft.DECADES:return Ze.intDiv(s,10);case ft.CENTURIES:return Ze.intDiv(s,100);case ft.MILLENNIA:return Ze.intDiv(s,1e3);case ft.ERAS:return a.getLong(Me.ERA)-this.getLong(Me.ERA)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},e})(Rh),RZ;function fyt(){Av.MIN_VALUE=Eh.MIN_VALUE,Av.MAX_VALUE=Eh.MAX_VALUE,RZ=new fa().appendValue(Me.YEAR,4,10,Mo.EXCEEDS_PAD).toFormatter(),Av.FROM=Ou("Year.FROM",function(t){return Av.from(t)})}/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var I6=(function(){function t(){}var e=t.prototype;return e.adjustInto=function(n){Hi("adjustInto")},t})(),Ake=(function(){function t(){}return t.firstDayOfMonth=function(){return Cc.FIRST_DAY_OF_MONTH},t.lastDayOfMonth=function(){return Cc.LAST_DAY_OF_MONTH},t.firstDayOfNextMonth=function(){return Cc.FIRST_DAY_OF_NEXT_MONTH},t.firstDayOfYear=function(){return Cc.FIRST_DAY_OF_YEAR},t.lastDayOfYear=function(){return Cc.LAST_DAY_OF_YEAR},t.firstDayOfNextYear=function(){return Cc.FIRST_DAY_OF_NEXT_YEAR},t.firstInMonth=function(i){return yt(i,"dayOfWeek"),new cY(1,i)},t.lastInMonth=function(i){return yt(i,"dayOfWeek"),new cY(-1,i)},t.dayOfWeekInMonth=function(i,n){return yt(n,"dayOfWeek"),new cY(i,n)},t.next=function(i){return new f4(2,i)},t.nextOrSame=function(i){return new f4(0,i)},t.previous=function(i){return new f4(3,i)},t.previousOrSame=function(i){return new f4(1,i)},t})(),Cc=(function(t){yn(e,t);function e(n){var r;return r=t.call(this)||this,r._ordinal=n,r}var i=e.prototype;return i.adjustInto=function(r){switch(this._ordinal){case 0:return r.with(Me.DAY_OF_MONTH,1);case 1:return r.with(Me.DAY_OF_MONTH,r.range(Me.DAY_OF_MONTH).maximum());case 2:return r.with(Me.DAY_OF_MONTH,1).plus(1,ft.MONTHS);case 3:return r.with(Me.DAY_OF_YEAR,1);case 4:return r.with(Me.DAY_OF_YEAR,r.range(Me.DAY_OF_YEAR).maximum());case 5:return r.with(Me.DAY_OF_YEAR,1).plus(1,ft.YEARS)}throw new E3("Unreachable")},e})(I6);Cc.FIRST_DAY_OF_MONTH=new Cc(0);Cc.LAST_DAY_OF_MONTH=new Cc(1);Cc.FIRST_DAY_OF_NEXT_MONTH=new Cc(2);Cc.FIRST_DAY_OF_YEAR=new Cc(3);Cc.LAST_DAY_OF_YEAR=new Cc(4);Cc.FIRST_DAY_OF_NEXT_YEAR=new Cc(5);var cY=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._ordinal=n,o._dowValue=r.value(),o}var i=e.prototype;return i.adjustInto=function(r){if(this._ordinal>=0){var o=r.with(Me.DAY_OF_MONTH,1),a=o.get(Me.DAY_OF_WEEK),s=Ze.intMod(this._dowValue-a+7,7);return s+=(this._ordinal-1)*7,o.plus(s,ft.DAYS)}else{var l=r.with(Me.DAY_OF_MONTH,r.range(Me.DAY_OF_MONTH).maximum()),u=l.get(Me.DAY_OF_WEEK),c=this._dowValue-u;return c=c===0?0:c>0?c-7:c,c-=(-this._ordinal-1)*7,l.plus(c,ft.DAYS)}},e})(I6),f4=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,yt(r,"dayOfWeek"),o._relative=n,o._dowValue=r.value(),o}var i=e.prototype;return i.adjustInto=function(r){var o=r.get(Me.DAY_OF_WEEK);if(this._relative<2&&o===this._dowValue)return r;if((this._relative&1)===0){var a=o-this._dowValue;return r.plus(a>=0?7-a:-a,ft.DAYS)}else{var s=this._dowValue-o;return r.minus(s>=0?7-s:-s,ft.DAYS)}},e})(I6),ta=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}e.isLeapYear=function(r){return(r&3)===0&&(r%100!==0||r%400===0)};var i=e.prototype;return i._updateResolveMap=function(r,o,a){yt(r,"fieldValues"),yt(o,"field");var s=r.get(o);if(s!=null&&s!==a)throw new ai("Invalid state, field: "+o+" "+s+" conflicts with "+o+" "+a);r.put(o,a)},i.resolveDate=function(r,o){if(r.containsKey(Me.EPOCH_DAY))return Ci.ofEpochDay(r.remove(Me.EPOCH_DAY));var a=r.remove(Me.PROLEPTIC_MONTH);a!=null&&(o!==ln.LENIENT&&Me.PROLEPTIC_MONTH.checkValidValue(a),this._updateResolveMap(r,Me.MONTH_OF_YEAR,Ze.floorMod(a,12)+1),this._updateResolveMap(r,Me.YEAR,Ze.floorDiv(a,12)));var s=r.remove(Me.YEAR_OF_ERA);if(s!=null){o!==ln.LENIENT&&Me.YEAR_OF_ERA.checkValidValue(s);var l=r.remove(Me.ERA);if(l==null){var u=r.get(Me.YEAR);o===ln.STRICT?u!=null?this._updateResolveMap(r,Me.YEAR,u>0?s:Ze.safeSubtract(1,s)):r.put(Me.YEAR_OF_ERA,s):this._updateResolveMap(r,Me.YEAR,u==null||u>0?s:Ze.safeSubtract(1,s))}else if(l===1)this._updateResolveMap(r,Me.YEAR,s);else if(l===0)this._updateResolveMap(r,Me.YEAR,Ze.safeSubtract(1,s));else throw new ai("Invalid value for era: "+l)}else r.containsKey(Me.ERA)&&Me.ERA.checkValidValue(r.get(Me.ERA));if(r.containsKey(Me.YEAR)){if(r.containsKey(Me.MONTH_OF_YEAR)&&r.containsKey(Me.DAY_OF_MONTH)){var c=Me.YEAR.checkValidIntValue(r.remove(Me.YEAR)),d=r.remove(Me.MONTH_OF_YEAR),f=r.remove(Me.DAY_OF_MONTH);if(o===ln.LENIENT){var h=d-1,p=f-1;return Ci.of(c,1,1).plusMonths(h).plusDays(p)}else return o===ln.SMART&&(Me.DAY_OF_MONTH.checkValidValue(f),d===4||d===6||d===9||d===11?f=Math.min(f,30):d===2&&(f=Math.min(f,qi.FEBRUARY.length(Av.isLeap(c))))),Ci.of(c,d,f)}if(r.containsKey(Me.DAY_OF_YEAR)){var g=Me.YEAR.checkValidIntValue(r.remove(Me.YEAR));if(o===ln.LENIENT){var v=Ze.safeSubtract(r.remove(Me.DAY_OF_YEAR),1);return Ci.ofYearDay(g,1).plusDays(v)}var y=Me.DAY_OF_YEAR.checkValidIntValue(r.remove(Me.DAY_OF_YEAR));return Ci.ofYearDay(g,y)}if(r.containsKey(Me.ALIGNED_WEEK_OF_YEAR)){if(r.containsKey(Me.ALIGNED_DAY_OF_WEEK_IN_YEAR)){var m=Me.YEAR.checkValidIntValue(r.remove(Me.YEAR));if(o===ln.LENIENT){var b=Ze.safeSubtract(r.remove(Me.ALIGNED_WEEK_OF_YEAR),1),S=Ze.safeSubtract(r.remove(Me.ALIGNED_DAY_OF_WEEK_IN_YEAR),1);return Ci.of(m,1,1).plusWeeks(b).plusDays(S)}var _=Me.ALIGNED_WEEK_OF_YEAR.checkValidIntValue(r.remove(Me.ALIGNED_WEEK_OF_YEAR)),C=Me.ALIGNED_DAY_OF_WEEK_IN_YEAR.checkValidIntValue(r.remove(Me.ALIGNED_DAY_OF_WEEK_IN_YEAR)),P=Ci.of(m,1,1).plusDays((_-1)*7+(C-1));if(o===ln.STRICT&&P.get(Me.YEAR)!==m)throw new ai("Strict mode rejected date parsed to a different year");return P}if(r.containsKey(Me.DAY_OF_WEEK)){var x=Me.YEAR.checkValidIntValue(r.remove(Me.YEAR));if(o===ln.LENIENT){var E=Ze.safeSubtract(r.remove(Me.ALIGNED_WEEK_OF_YEAR),1),A=Ze.safeSubtract(r.remove(Me.DAY_OF_WEEK),1);return Ci.of(x,1,1).plusWeeks(E).plusDays(A)}var R=Me.ALIGNED_WEEK_OF_YEAR.checkValidIntValue(r.remove(Me.ALIGNED_WEEK_OF_YEAR)),M=Me.DAY_OF_WEEK.checkValidIntValue(r.remove(Me.DAY_OF_WEEK)),D=Ci.of(x,1,1).plusWeeks(R-1).with(Ake.nextOrSame(Wa.of(M)));if(o===ln.STRICT&&D.get(Me.YEAR)!==x)throw new ai("Strict mode rejected date parsed to a different month");return D}}}return null},i.date=function(r){return Ci.from(r)},e})(mI);function hyt(){ta.INSTANCE=new ta("IsoChronology")}var Hy=(function(t){yn(e,t),e.from=function(r){if(yt(r,"temporal"),r instanceof e)return r;if(r instanceof xg)return r.toOffsetTime();try{var o=Zt.from(r),a=en.from(r);return new e(o,a)}catch{throw new ai("Unable to obtain OffsetTime TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""))}},e.now=function(r){return arguments.length===0?e._now(Ma.systemDefaultZone()):r instanceof Ma?e._now(r):e._now(Ma.system(r))},e._now=function(r){yt(r,"clock");var o=r.instant();return e.ofInstant(o,r.zone().rules().offset(o))},e.of=function(){return arguments.length<=2?e.ofTimeAndOffset.apply(this,arguments):e.ofNumbers.apply(this,arguments)},e.ofNumbers=function(r,o,a,s,l){var u=Zt.of(r,o,a,s);return new e(u,l)},e.ofTimeAndOffset=function(r,o){return new e(r,o)},e.ofInstant=function(r,o){yt(r,"instant"),_i(r,Ra,"instant"),yt(o,"zone"),_i(o,ra,"zone");var a=o.rules(),s=a.offset(r),l=r.epochSecond()%Zt.SECONDS_PER_DAY;l=(l+s.totalSeconds())%Zt.SECONDS_PER_DAY,l<0&&(l+=Zt.SECONDS_PER_DAY);var u=Zt.ofSecondOfDay(l,r.nano());return new e(u,s)},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_OFFSET_TIME),yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r){var o;return o=t.call(this)||this,yt(n,"time"),_i(n,Zt,"time"),yt(r,"offset"),_i(r,en,"offset"),o._time=n,o._offset=r,o}var i=e.prototype;return i.adjustInto=function(r){return r.with(Me.NANO_OF_DAY,this._time.toNanoOfDay()).with(Me.OFFSET_SECONDS,this.offset().totalSeconds())},i.atDate=function(r){return xg.of(r,this._time,this._offset)},i.format=function(r){return yt(r,"formatter"),r.format(this,e.FROM)},i.get=function(r){return t.prototype.get.call(this,r)},i.getLong=function(r){return r instanceof Me?r===Me.OFFSET_SECONDS?this._offset.totalSeconds():this._time.getLong(r):r.getFrom(this)},i.hour=function(){return this._time.hour()},i.minute=function(){return this._time.minute()},i.second=function(){return this._time.second()},i.nano=function(){return this._time.nano()},i.offset=function(){return this._offset},i.isAfter=function(r){return yt(r,"other"),this._toEpochNano()>r._toEpochNano()},i.isBefore=function(r){return yt(r,"other"),this._toEpochNano()<r._toEpochNano()},i.isEqual=function(r){return yt(r,"other"),this._toEpochNano()===r._toEpochNano()},i.isSupported=function(r){return r instanceof Me?r.isTimeBased()||r===Me.OFFSET_SECONDS:r instanceof ft?r.isTimeBased():r!=null&&r.isSupportedBy(this)},i.minusHours=function(r){return this._withLocalTimeOffset(this._time.minusHours(r),this._offset)},i.minusMinutes=function(r){return this._withLocalTimeOffset(this._time.minusMinutes(r),this._offset)},i.minusSeconds=function(r){return this._withLocalTimeOffset(this._time.minusSeconds(r),this._offset)},i.minusNanos=function(r){return this._withLocalTimeOffset(this._time.minusNanos(r),this._offset)},i._minusAmount=function(r){return yt(r),r.subtractFrom(this)},i._minusUnit=function(r,o){return this.plus(-1*r,o)},i._plusAmount=function(r){return yt(r),r.addTo(this)},i._plusUnit=function(r,o){return o instanceof ft?this._withLocalTimeOffset(this._time.plus(r,o),this._offset):o.addTo(this,r)},i.plusHours=function(r){return this._withLocalTimeOffset(this._time.plusHours(r),this._offset)},i.plusMinutes=function(r){return this._withLocalTimeOffset(this._time.plusMinutes(r),this._offset)},i.plusSeconds=function(r){return this._withLocalTimeOffset(this._time.plusSeconds(r),this._offset)},i.plusNanos=function(r){return this._withLocalTimeOffset(this._time.plusNanos(r),this._offset)},i.query=function(r){return yt(r,"query"),r===Dr.precision()?ft.NANOS:r===Dr.offset()||r===Dr.zone()?this.offset():r===Dr.localTime()?this._time:r===Dr.chronology()||r===Dr.localDate()||r===Dr.zoneId()?null:t.prototype.query.call(this,r)},i.range=function(r){return r instanceof Me?r===Me.OFFSET_SECONDS?r.range():this._time.range(r):r.rangeRefinedBy(this)},i.toLocalTime=function(){return this._time},i.truncatedTo=function(r){return this._withLocalTimeOffset(this._time.truncatedTo(r),this._offset)},i.until=function(r,o){yt(r,"endExclusive"),yt(o,"unit");var a=e.from(r);if(o instanceof ft){var s=a._toEpochNano()-this._toEpochNano();switch(o){case ft.NANOS:return s;case ft.MICROS:return Ze.intDiv(s,1e3);case ft.MILLIS:return Ze.intDiv(s,1e6);case ft.SECONDS:return Ze.intDiv(s,Zt.NANOS_PER_SECOND);case ft.MINUTES:return Ze.intDiv(s,Zt.NANOS_PER_MINUTE);case ft.HOURS:return Ze.intDiv(s,Zt.NANOS_PER_HOUR);case ft.HALF_DAYS:return Ze.intDiv(s,12*Zt.NANOS_PER_HOUR)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},i.withHour=function(r){return this._withLocalTimeOffset(this._time.withHour(r),this._offset)},i.withMinute=function(r){return this._withLocalTimeOffset(this._time.withMinute(r),this._offset)},i.withSecond=function(r){return this._withLocalTimeOffset(this._time.withSecond(r),this._offset)},i.withNano=function(r){return this._withLocalTimeOffset(this._time.withNano(r),this._offset)},i.withOffsetSameInstant=function(r){if(yt(r,"offset"),r.equals(this._offset))return this;var o=r.totalSeconds()-this._offset.totalSeconds(),a=this._time.plusSeconds(o);return new e(a,r)},i.withOffsetSameLocal=function(r){return r!=null&&r.equals(this._offset)?this:new e(this._time,r)},i._toEpochNano=function(){var r=this._time.toNanoOfDay(),o=this._offset.totalSeconds()*Zt.NANOS_PER_SECOND;return r-o},i._withAdjuster=function(r){return yt(r,"adjuster"),r instanceof Zt?this._withLocalTimeOffset(r,this._offset):r instanceof en?this._withLocalTimeOffset(this._time,r):r instanceof e?r:r.adjustInto(this)},i._withField=function(r,o){return yt(r,"field"),r instanceof Me?r===Me.OFFSET_SECONDS?this._withLocalTimeOffset(this._time,en.ofTotalSeconds(r.checkValidIntValue(o))):this._withLocalTimeOffset(this._time.with(r,o),this._offset):r.adjustInto(this,o)},i._withLocalTimeOffset=function(r,o){return this._time===r&&this._offset.equals(o)?this:new e(r,o)},i.compareTo=function(r){if(yt(r,"other"),_i(r,e,"other"),this._offset.equals(r._offset))return this._time.compareTo(r._time);var o=Ze.compareNumbers(this._toEpochNano(),r._toEpochNano());return o===0?this._time.compareTo(r._time):o},i.equals=function(r){return this===r?!0:r instanceof e?this._time.equals(r._time)&&this._offset.equals(r._offset):!1},i.hashCode=function(){return this._time.hashCode()^this._offset.hashCode()},i.toString=function(){return this._time.toString()+this._offset.toString()},i.toJSON=function(){return this.toString()},e})(Rh);function pyt(){Hy.MIN=Hy.ofNumbers(0,0,0,0,en.MAX),Hy.MAX=Hy.ofNumbers(23,59,59,999999999,en.MIN),Hy.FROM=Ou("OffsetTime.FROM",function(t){return Hy.from(t)})}var Oke=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.query=function(r){return r===Dr.zoneId()||r===Dr.zone()?this.zone():r===Dr.chronology()?this.toLocalDate().chronology():r===Dr.precision()?ft.NANOS:r===Dr.offset()?this.offset():r===Dr.localDate()?Ci.ofEpochDay(this.toLocalDate().toEpochDay()):r===Dr.localTime()?this.toLocalTime():t.prototype.query.call(this,r)},i.format=function(r){return yt(r,"formatter"),r.format(this)},i.toInstant=function(){return Ra.ofEpochSecond(this.toEpochSecond(),this.toLocalTime().nano())},i.toEpochSecond=function(){var r=this.toLocalDate().toEpochDay(),o=r*86400+this.toLocalTime().toSecondOfDay();return o-=this.offset().totalSeconds(),o},i.compareTo=function(r){yt(r,"other");var o=Ze.compareNumbers(this.toEpochSecond(),r.toEpochSecond());return o===0&&(o=this.toLocalTime().nano()-r.toLocalTime().nano(),o===0&&(o=this.toLocalDateTime().compareTo(r.toLocalDateTime()),o===0&&(o=gyt(this.zone().id(),r.zone().id())))),o},i.isAfter=function(r){yt(r,"other");var o=this.toEpochSecond(),a=r.toEpochSecond();return o>a||o===a&&this.toLocalTime().nano()>r.toLocalTime().nano()},i.isBefore=function(r){yt(r,"other");var o=this.toEpochSecond(),a=r.toEpochSecond();return o<a||o===a&&this.toLocalTime().nano()<r.toLocalTime().nano()},i.isEqual=function(r){return yt(r,"other"),this.toEpochSecond()===r.toEpochSecond()&&this.toLocalTime().nano()===r.toLocalTime().nano()},i.equals=function(r){return this===r?!0:r instanceof e?this.compareTo(r)===0:!1},e})(Rh);function gyt(t,e){return t<e?-1:t>e?1:0}var Lv=(function(t){yn(e,t),e.now=function(r){var o;return r instanceof ra?o=Ma.system(r):o=r??Ma.systemDefaultZone(),e.ofInstant(o.instant(),o.zone())},e.of=function(){return arguments.length<=2?e.of2.apply(this,arguments):arguments.length===3&&arguments[0]instanceof Ci?e.of3.apply(this,arguments):e.of8.apply(this,arguments)},e.of3=function(r,o,a){return e.of2(ia.of(r,o),a)},e.of2=function(r,o){return e.ofLocal(r,o,null)},e.of8=function(r,o,a,s,l,u,c,d){var f=ia.of(r,o,a,s,l,u,c);return e.ofLocal(f,d,null)},e.ofLocal=function(r,o,a){if(yt(r,"localDateTime"),yt(o,"zone"),o instanceof en)return new e(r,o,o);var s=null,l=o.rules(),u=l.validOffsets(r);if(u.length===1)s=u[0];else if(u.length===0){var c=l.transition(r);r=r.plusSeconds(c.duration().seconds()),s=c.offsetAfter()}else a!=null&&u.some(function(d){return d.equals(a)})?s=a:s=yt(u[0],"offset");return new e(r,s,o)},e.ofInstant=function(){return arguments.length===2?e.ofInstant2.apply(this,arguments):e.ofInstant3.apply(this,arguments)},e.ofInstant2=function(r,o){return yt(r,"instant"),yt(o,"zone"),e._create(r.epochSecond(),r.nano(),o)},e.ofInstant3=function(r,o,a){return yt(r,"localDateTime"),yt(o,"offset"),yt(a,"zone"),e._create(r.toEpochSecond(o),r.nano(),a)},e._create=function(r,o,a){var s=a.rules(),l=Ra.ofEpochSecond(r,o),u=s.offset(l),c=ia.ofEpochSecond(r,o,u);return new e(c,u,a)},e.ofStrict=function(r,o,a){yt(r,"localDateTime"),yt(o,"offset"),yt(a,"zone");var s=a.rules();if(s.isValidOffset(r,o)===!1){var l=s.transition(r);throw l!=null&&l.isGap()?new ai("LocalDateTime "+r+" does not exist in zone "+a+" due to a gap in the local time-line, typically caused by daylight savings"):new ai('ZoneOffset "'+o+'" is not valid for LocalDateTime "'+r+'" in zone "'+a+'"')}return new e(r,o,a)},e.ofLenient=function(r,o,a){if(yt(r,"localDateTime"),yt(o,"offset"),yt(a,"zone"),a instanceof en&&o.equals(a)===!1)throw new Pi("ZoneId must match ZoneOffset");return new e(r,o,a)},e.from=function(r){if(yt(r,"temporal"),r instanceof e)return r;var o=ra.from(r);if(r.isSupported(Me.INSTANT_SECONDS)){var a=e._from(r,o);if(a!=null)return a}var s=ia.from(r);return e.of2(s,o)},e._from=function(r,o){try{return e.__from(r,o)}catch(a){if(!(a instanceof ai))throw a}},e.__from=function(r,o){var a=r.getLong(Me.INSTANT_SECONDS),s=r.get(Me.NANO_OF_SECOND);return e._create(a,s,o)},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_ZONED_DATE_TIME),yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r,o){var a;return yt(n,"dateTime"),yt(r,"offset"),yt(o,"zone"),a=t.call(this)||this,a._dateTime=n,a._offset=r,a._zone=o,a}var i=e.prototype;return i._resolveLocal=function(r){return yt(r,"newDateTime"),e.ofLocal(r,this._zone,this._offset)},i._resolveInstant=function(r){return e.ofInstant3(r,this._offset,this._zone)},i._resolveOffset=function(r){return r.equals(this._offset)===!1&&this._zone.rules().isValidOffset(this._dateTime,r)?new e(this._dateTime,r,this._zone):this},i.isSupported=function(r){return r instanceof Me?!0:r instanceof ft?r.isDateBased()||r.isTimeBased():r!=null&&r.isSupportedBy(this)},i.range=function(r){return r instanceof Me?r===Me.INSTANT_SECONDS||r===Me.OFFSET_SECONDS?r.range():this._dateTime.range(r):r.rangeRefinedBy(this)},i.get=function(r){return this.getLong(r)},i.getLong=function(r){if(r instanceof Me){switch(r){case Me.INSTANT_SECONDS:return this.toEpochSecond();case Me.OFFSET_SECONDS:return this._offset.totalSeconds()}return this._dateTime.getLong(r)}return yt(r,"field"),r.getFrom(this)},i.offset=function(){return this._offset},i.withEarlierOffsetAtOverlap=function(){var r=this._zone.rules().transition(this._dateTime);if(r!=null&&r.isOverlap()){var o=r.offsetBefore();if(o.equals(this._offset)===!1)return new e(this._dateTime,o,this._zone)}return this},i.withLaterOffsetAtOverlap=function(){var r=this._zone.rules().transition(this.toLocalDateTime());if(r!=null){var o=r.offsetAfter();if(o.equals(this._offset)===!1)return new e(this._dateTime,o,this._zone)}return this},i.zone=function(){return this._zone},i.withZoneSameLocal=function(r){return yt(r,"zone"),this._zone.equals(r)?this:e.ofLocal(this._dateTime,r,this._offset)},i.withZoneSameInstant=function(r){return yt(r,"zone"),this._zone.equals(r)?this:e._create(this._dateTime.toEpochSecond(this._offset),this._dateTime.nano(),r)},i.withFixedOffsetZone=function(){return this._zone.equals(this._offset)?this:new e(this._dateTime,this._offset,this._offset)},i.year=function(){return this._dateTime.year()},i.monthValue=function(){return this._dateTime.monthValue()},i.month=function(){return this._dateTime.month()},i.dayOfMonth=function(){return this._dateTime.dayOfMonth()},i.dayOfYear=function(){return this._dateTime.dayOfYear()},i.dayOfWeek=function(){return this._dateTime.dayOfWeek()},i.hour=function(){return this._dateTime.hour()},i.minute=function(){return this._dateTime.minute()},i.second=function(){return this._dateTime.second()},i.nano=function(){return this._dateTime.nano()},i._withAdjuster=function(r){if(r instanceof Ci)return this._resolveLocal(ia.of(r,this._dateTime.toLocalTime()));if(r instanceof Zt)return this._resolveLocal(ia.of(this._dateTime.toLocalDate(),r));if(r instanceof ia)return this._resolveLocal(r);if(r instanceof Ra){var o=r;return e._create(o.epochSecond(),o.nano(),this._zone)}else if(r instanceof en)return this._resolveOffset(r);return t.prototype._withAdjuster.call(this,r)},i._withField=function(r,o){if(r instanceof Me){switch(r){case Me.INSTANT_SECONDS:return e._create(o,this.nano(),this._zone);case Me.OFFSET_SECONDS:{var a=en.ofTotalSeconds(r.checkValidIntValue(o));return this._resolveOffset(a)}}return this._resolveLocal(this._dateTime.with(r,o))}return r.adjustInto(this,o)},i.withYear=function(r){return this._resolveLocal(this._dateTime.withYear(r))},i.withMonth=function(r){return this._resolveLocal(this._dateTime.withMonth(r))},i.withDayOfMonth=function(r){return this._resolveLocal(this._dateTime.withDayOfMonth(r))},i.withDayOfYear=function(r){return this._resolveLocal(this._dateTime.withDayOfYear(r))},i.withHour=function(r){return this._resolveLocal(this._dateTime.withHour(r))},i.withMinute=function(r){return this._resolveLocal(this._dateTime.withMinute(r))},i.withSecond=function(r){return this._resolveLocal(this._dateTime.withSecond(r))},i.withNano=function(r){return this._resolveLocal(this._dateTime.withNano(r))},i.truncatedTo=function(r){return this._resolveLocal(this._dateTime.truncatedTo(r))},i._plusUnit=function(r,o){return o instanceof ft?o.isDateBased()?this._resolveLocal(this._dateTime.plus(r,o)):this._resolveInstant(this._dateTime.plus(r,o)):(yt(o,"unit"),o.addTo(this,r))},i.plusYears=function(r){return this._resolveLocal(this._dateTime.plusYears(r))},i.plusMonths=function(r){return this._resolveLocal(this._dateTime.plusMonths(r))},i.plusWeeks=function(r){return this._resolveLocal(this._dateTime.plusWeeks(r))},i.plusDays=function(r){return this._resolveLocal(this._dateTime.plusDays(r))},i.plusHours=function(r){return this._resolveInstant(this._dateTime.plusHours(r))},i.plusMinutes=function(r){return this._resolveInstant(this._dateTime.plusMinutes(r))},i.plusSeconds=function(r){return this._resolveInstant(this._dateTime.plusSeconds(r))},i.plusNanos=function(r){return this._resolveInstant(this._dateTime.plusNanos(r))},i._minusUnit=function(r,o){return this._plusUnit(-1*r,o)},i.minusYears=function(r){return this.plusYears(-1*r)},i.minusMonths=function(r){return this.plusMonths(-1*r)},i.minusWeeks=function(r){return this.plusWeeks(-1*r)},i.minusDays=function(r){return this.plusDays(-1*r)},i.minusHours=function(r){return this.plusHours(-1*r)},i.minusMinutes=function(r){return this.plusMinutes(-1*r)},i.minusSeconds=function(r){return this.plusSeconds(-1*r)},i.minusNanos=function(r){return this.plusNanos(-1*r)},i.query=function(r){return r===Dr.localDate()?this.toLocalDate():(yt(r,"query"),t.prototype.query.call(this,r))},i.until=function(r,o){var a=e.from(r);if(o instanceof ft){if(a=a.withZoneSameInstant(this._zone),o.isDateBased())return this._dateTime.until(a._dateTime,o);var s=this._offset.totalSeconds()-a._offset.totalSeconds(),l=a._dateTime.plusSeconds(s);return this._dateTime.until(l,o)}return o.between(this,a)},i.toLocalDateTime=function(){return this._dateTime},i.toLocalDate=function(){return this._dateTime.toLocalDate()},i.toLocalTime=function(){return this._dateTime.toLocalTime()},i.toOffsetDateTime=function(){return xg.of(this._dateTime,this._offset)},i.equals=function(r){return this===r?!0:r instanceof e?this._dateTime.equals(r._dateTime)&&this._offset.equals(r._offset)&&this._zone.equals(r._zone):!1},i.hashCode=function(){return Ze.hashCode(this._dateTime.hashCode(),this._offset.hashCode(),this._zone.hashCode())},i.toString=function(){var r=this._dateTime.toString()+this._offset.toString();return this._offset!==this._zone&&(r+="["+this._zone.toString()+"]"),r},i.toJSON=function(){return this.toString()},i.format=function(r){return t.prototype.format.call(this,r)},e})(Oke);function vyt(){Lv.FROM=Ou("ZonedDateTime.FROM",function(t){return Lv.from(t)})}var xg=(function(t){yn(e,t),e.from=function(r){if(yt(r,"temporal"),r instanceof e)return r;try{var o=en.from(r);try{var a=ia.from(r);return e.of(a,o)}catch{var s=Ra.from(r);return e.ofInstant(s,o)}}catch{throw new ai("Unable to obtain OffsetDateTime TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""))}},e.now=function(r){if(arguments.length===0)return e.now(Ma.systemDefaultZone());if(yt(r,"clockOrZone"),r instanceof ra)return e.now(Ma.system(r));if(r instanceof Ma){var o=r.instant();return e.ofInstant(o,r.zone().rules().offset(o))}else throw new Pi("clockOrZone must be an instance of ZoneId or Clock")},e.of=function(){return arguments.length<=2?e.ofDateTime.apply(this,arguments):arguments.length===3?e.ofDateAndTime.apply(this,arguments):e.ofNumbers.apply(this,arguments)},e.ofDateTime=function(r,o){return new e(r,o)},e.ofDateAndTime=function(r,o,a){var s=ia.of(r,o);return new e(s,a)},e.ofNumbers=function(r,o,a,s,l,u,c,d){s===void 0&&(s=0),l===void 0&&(l=0),u===void 0&&(u=0),c===void 0&&(c=0);var f=ia.of(r,o,a,s,l,u,c);return new e(f,d)},e.ofInstant=function(r,o){yt(r,"instant"),yt(o,"zone");var a=o.rules(),s=a.offset(r),l=ia.ofEpochSecond(r.epochSecond(),r.nano(),s);return new e(l,s)},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_OFFSET_DATE_TIME),yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r){var o;return o=t.call(this)||this,yt(n,"dateTime"),_i(n,ia,"dateTime"),yt(r,"offset"),_i(r,en,"offset"),o._dateTime=n,o._offset=r,o}var i=e.prototype;return i.adjustInto=function(r){return r.with(Me.EPOCH_DAY,this.toLocalDate().toEpochDay()).with(Me.NANO_OF_DAY,this.toLocalTime().toNanoOfDay()).with(Me.OFFSET_SECONDS,this.offset().totalSeconds())},i.until=function(r,o){var a=e.from(r);return o instanceof ft?(a=a.withOffsetSameInstant(this._offset),this._dateTime.until(a._dateTime,o)):o.between(this,a)},i.atZoneSameInstant=function(r){return Lv.ofInstant(this._dateTime,this._offset,r)},i.atZoneSimilarLocal=function(r){return Lv.ofLocal(this._dateTime,r,this._offset)},i.query=function(r){return yt(r,"query"),r===Dr.chronology()?ta.INSTANCE:r===Dr.precision()?ft.NANOS:r===Dr.offset()||r===Dr.zone()?this.offset():r===Dr.localDate()?this.toLocalDate():r===Dr.localTime()?this.toLocalTime():r===Dr.zoneId()?null:t.prototype.query.call(this,r)},i.get=function(r){if(r instanceof Me){switch(r){case Me.INSTANT_SECONDS:throw new ai("Field too large for an int: "+r);case Me.OFFSET_SECONDS:return this.offset().totalSeconds()}return this._dateTime.get(r)}return t.prototype.get.call(this,r)},i.getLong=function(r){if(r instanceof Me){switch(r){case Me.INSTANT_SECONDS:return this.toEpochSecond();case Me.OFFSET_SECONDS:return this.offset().totalSeconds()}return this._dateTime.getLong(r)}return r.getFrom(this)},i.offset=function(){return this._offset},i.year=function(){return this._dateTime.year()},i.monthValue=function(){return this._dateTime.monthValue()},i.month=function(){return this._dateTime.month()},i.dayOfMonth=function(){return this._dateTime.dayOfMonth()},i.dayOfYear=function(){return this._dateTime.dayOfYear()},i.dayOfWeek=function(){return this._dateTime.dayOfWeek()},i.hour=function(){return this._dateTime.hour()},i.minute=function(){return this._dateTime.minute()},i.second=function(){return this._dateTime.second()},i.nano=function(){return this._dateTime.nano()},i.toLocalDateTime=function(){return this._dateTime},i.toLocalDate=function(){return this._dateTime.toLocalDate()},i.toLocalTime=function(){return this._dateTime.toLocalTime()},i.toOffsetTime=function(){return Hy.of(this._dateTime.toLocalTime(),this._offset)},i.toZonedDateTime=function(){return Lv.of(this._dateTime,this._offset)},i.toInstant=function(){return this._dateTime.toInstant(this._offset)},i.toEpochSecond=function(){return this._dateTime.toEpochSecond(this._offset)},i.isSupported=function(r){return r instanceof Me||r instanceof ft?r.isDateBased()||r.isTimeBased():r!=null&&r.isSupportedBy(this)},i.range=function(r){return r instanceof Me?r===Me.INSTANT_SECONDS||r===Me.OFFSET_SECONDS?r.range():this._dateTime.range(r):r.rangeRefinedBy(this)},i._withAdjuster=function(r){return yt(r),r instanceof Ci||r instanceof Zt||r instanceof ia?this._withDateTimeOffset(this._dateTime.with(r),this._offset):r instanceof Ra?e.ofInstant(r,this._offset):r instanceof en?this._withDateTimeOffset(this._dateTime,r):r instanceof e?r:r.adjustInto(this)},i._withField=function(r,o){if(yt(r),r instanceof Me){var a=r;switch(a){case Me.INSTANT_SECONDS:return e.ofInstant(Ra.ofEpochSecond(o,this.nano()),this._offset);case Me.OFFSET_SECONDS:return this._withDateTimeOffset(this._dateTime,en.ofTotalSeconds(a.checkValidIntValue(o)))}return this._withDateTimeOffset(this._dateTime.with(r,o),this._offset)}return r.adjustInto(this,o)},i._withDateTimeOffset=function(r,o){return this._dateTime===r&&this._offset.equals(o)?this:new e(r,o)},i.withYear=function(r){return this._withDateTimeOffset(this._dateTime.withYear(r),this._offset)},i.withMonth=function(r){return this._withDateTimeOffset(this._dateTime.withMonth(r),this._offset)},i.withDayOfMonth=function(r){return this._withDateTimeOffset(this._dateTime.withDayOfMonth(r),this._offset)},i.withDayOfYear=function(r){return this._withDateTimeOffset(this._dateTime.withDayOfYear(r),this._offset)},i.withHour=function(r){return this._withDateTimeOffset(this._dateTime.withHour(r),this._offset)},i.withMinute=function(r){return this._withDateTimeOffset(this._dateTime.withMinute(r),this._offset)},i.withSecond=function(r){return this._withDateTimeOffset(this._dateTime.withSecond(r),this._offset)},i.withNano=function(r){return this._withDateTimeOffset(this._dateTime.withNano(r),this._offset)},i.withOffsetSameLocal=function(r){return yt(r,"offset"),this._withDateTimeOffset(this._dateTime,r)},i.withOffsetSameInstant=function(r){if(yt(r,"offset"),r.equals(this._offset))return this;var o=r.totalSeconds()-this._offset.totalSeconds(),a=this._dateTime.plusSeconds(o);return new e(a,r)},i.truncatedTo=function(r){return this._withDateTimeOffset(this._dateTime.truncatedTo(r),this._offset)},i._plusAmount=function(r){return yt(r,"amount"),r.addTo(this)},i._plusUnit=function(r,o){return o instanceof ft?this._withDateTimeOffset(this._dateTime.plus(r,o),this._offset):o.addTo(this,r)},i.plusYears=function(r){return this._withDateTimeOffset(this._dateTime.plusYears(r),this._offset)},i.plusMonths=function(r){return this._withDateTimeOffset(this._dateTime.plusMonths(r),this._offset)},i.plusWeeks=function(r){return this._withDateTimeOffset(this._dateTime.plusWeeks(r),this._offset)},i.plusDays=function(r){return this._withDateTimeOffset(this._dateTime.plusDays(r),this._offset)},i.plusHours=function(r){return this._withDateTimeOffset(this._dateTime.plusHours(r),this._offset)},i.plusMinutes=function(r){return this._withDateTimeOffset(this._dateTime.plusMinutes(r),this._offset)},i.plusSeconds=function(r){return this._withDateTimeOffset(this._dateTime.plusSeconds(r),this._offset)},i.plusNanos=function(r){return this._withDateTimeOffset(this._dateTime.plusNanos(r),this._offset)},i._minusAmount=function(r){return yt(r),r.subtractFrom(this)},i._minusUnit=function(r,o){return this.plus(-1*r,o)},i.minusYears=function(r){return this._withDateTimeOffset(this._dateTime.minusYears(r),this._offset)},i.minusMonths=function(r){return this._withDateTimeOffset(this._dateTime.minusMonths(r),this._offset)},i.minusWeeks=function(r){return this._withDateTimeOffset(this._dateTime.minusWeeks(r),this._offset)},i.minusDays=function(r){return this._withDateTimeOffset(this._dateTime.minusDays(r),this._offset)},i.minusHours=function(r){return this._withDateTimeOffset(this._dateTime.minusHours(r),this._offset)},i.minusMinutes=function(r){return this._withDateTimeOffset(this._dateTime.minusMinutes(r),this._offset)},i.minusSeconds=function(r){return this._withDateTimeOffset(this._dateTime.minusSeconds(r),this._offset)},i.minusNanos=function(r){return this._withDateTimeOffset(this._dateTime.minusNanos(r),this._offset)},i.compareTo=function(r){if(yt(r,"other"),_i(r,e,"other"),this.offset().equals(r.offset()))return this.toLocalDateTime().compareTo(r.toLocalDateTime());var o=Ze.compareNumbers(this.toEpochSecond(),r.toEpochSecond());return o===0&&(o=this.toLocalTime().nano()-r.toLocalTime().nano(),o===0&&(o=this.toLocalDateTime().compareTo(r.toLocalDateTime()))),o},i.isAfter=function(r){yt(r,"other");var o=this.toEpochSecond(),a=r.toEpochSecond();return o>a||o===a&&this.toLocalTime().nano()>r.toLocalTime().nano()},i.isBefore=function(r){yt(r,"other");var o=this.toEpochSecond(),a=r.toEpochSecond();return o<a||o===a&&this.toLocalTime().nano()<r.toLocalTime().nano()},i.isEqual=function(r){return yt(r,"other"),this.toEpochSecond()===r.toEpochSecond()&&this.toLocalTime().nano()===r.toLocalTime().nano()},i.equals=function(r){return this===r?!0:r instanceof e?this._dateTime.equals(r._dateTime)&&this._offset.equals(r._offset):!1},i.hashCode=function(){return this._dateTime.hashCode()^this._offset.hashCode()},i.toString=function(){return this._dateTime.toString()+this._offset.toString()},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),r.format(this)},e})(Rh);function yyt(){xg.MIN=ia.MIN.atOffset(en.MAX),xg.MAX=ia.MAX.atOffset(en.MIN),xg.FROM=Ou("OffsetDateTime.FROM",function(t){return xg.from(t)})}var YU=146097,Hue=YU*5-(30*365+7),Ci=(function(t){yn(e,t),e.now=function(r){var o;return r==null?o=Ma.systemDefaultZone():r instanceof ra?o=Ma.system(r):o=r,e.ofInstant(o.instant(),o.zone())},e.ofInstant=function(r,o){o===void 0&&(o=ra.systemDefault()),yt(r,"instant");var a=o.rules().offset(r),s=r.epochSecond()+a.totalSeconds(),l=Ze.floorDiv(s,Zt.SECONDS_PER_DAY);return e.ofEpochDay(l)},e.of=function(r,o,a){return new e(r,o,a)},e.ofYearDay=function(r,o){Me.YEAR.checkValidValue(r);var a=ta.isLeapYear(r);o===366&&a===!1&&ha(!1,"Invalid date 'DayOfYear 366' as '"+r+"' is not a leap year",ai);var s=qi.of(Math.floor((o-1)/31+1)),l=s.firstDayOfYear(a)+s.length(a)-1;o>l&&(s=s.plus(1));var u=o-s.firstDayOfYear(a)+1;return new e(r,s.value(),u)},e.ofEpochDay=function(r){r===void 0&&(r=0);var o,a,s,l,u;u=r+Hue,u-=60,o=0,u<0&&(a=Ze.intDiv(u+1,YU)-1,o=a*400,u+=-a*YU),l=Ze.intDiv(400*u+591,YU),s=u-(365*l+Ze.intDiv(l,4)-Ze.intDiv(l,100)+Ze.intDiv(l,400)),s<0&&(l--,s=u-(365*l+Ze.intDiv(l,4)-Ze.intDiv(l,100)+Ze.intDiv(l,400))),l+=o;var c=s,d=Ze.intDiv(c*5+2,153),f=(d+2)%12+1,h=c-Ze.intDiv(d*306+5,10)+1;l+=Ze.intDiv(d,10);var p=l;return new e(p,f,h)},e.from=function(r){yt(r,"temporal");var o=r.query(Dr.localDate());if(o==null)throw new ai("Unable to obtain LocalDate from TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""));return o},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_LOCAL_DATE),ha(o!=null,"formatter",hS),o.parse(r,e.FROM)},e._resolvePreviousValid=function(r,o,a){switch(o){case 2:a=Math.min(a,ta.isLeapYear(r)?29:28);break;case 4:case 6:case 9:case 11:a=Math.min(a,30);break}return e.of(r,o,a)};function e(n,r,o){var a;return a=t.call(this)||this,yt(n,"year"),yt(r,"month"),yt(o,"dayOfMonth"),r instanceof qi&&(r=r.value()),a._year=Ze.safeToInt(n),a._month=Ze.safeToInt(r),a._day=Ze.safeToInt(o),e._validate(a._year,a._month,a._day),a}e._validate=function(r,o,a){var s;if(Me.YEAR.checkValidValue(r),Me.MONTH_OF_YEAR.checkValidValue(o),Me.DAY_OF_MONTH.checkValidValue(a),a>28){switch(s=31,o){case 2:s=ta.isLeapYear(r)?29:28;break;case 4:case 6:case 9:case 11:s=30}a>s&&(a===29?ha(!1,"Invalid date 'February 29' as '"+r+"' is not a leap year",ai):ha(!1,"Invalid date '"+r+"' '"+o+"' '"+a+"'",ai))}};var i=e.prototype;return i.isSupported=function(r){return t.prototype.isSupported.call(this,r)},i.range=function(r){if(r instanceof Me){if(r.isDateBased()){switch(r){case Me.DAY_OF_MONTH:return dn.of(1,this.lengthOfMonth());case Me.DAY_OF_YEAR:return dn.of(1,this.lengthOfYear());case Me.ALIGNED_WEEK_OF_MONTH:return dn.of(1,this.month()===qi.FEBRUARY&&this.isLeapYear()===!1?4:5);case Me.YEAR_OF_ERA:return this._year<=0?dn.of(1,Av.MAX_VALUE+1):dn.of(1,Av.MAX_VALUE)}return r.range()}throw new Qn("Unsupported field: "+r)}return r.rangeRefinedBy(this)},i.get=function(r){return this.getLong(r)},i.getLong=function(r){return ha(r!=null,"",hS),r instanceof Me?this._get0(r):r.getFrom(this)},i._get0=function(r){switch(r){case Me.DAY_OF_WEEK:return this.dayOfWeek().value();case Me.ALIGNED_DAY_OF_WEEK_IN_MONTH:return Ze.intMod(this._day-1,7)+1;case Me.ALIGNED_DAY_OF_WEEK_IN_YEAR:return Ze.intMod(this.dayOfYear()-1,7)+1;case Me.DAY_OF_MONTH:return this._day;case Me.DAY_OF_YEAR:return this.dayOfYear();case Me.EPOCH_DAY:return this.toEpochDay();case Me.ALIGNED_WEEK_OF_MONTH:return Ze.intDiv(this._day-1,7)+1;case Me.ALIGNED_WEEK_OF_YEAR:return Ze.intDiv(this.dayOfYear()-1,7)+1;case Me.MONTH_OF_YEAR:return this._month;case Me.PROLEPTIC_MONTH:return this._prolepticMonth();case Me.YEAR_OF_ERA:return this._year>=1?this._year:1-this._year;case Me.YEAR:return this._year;case Me.ERA:return this._year>=1?1:0}throw new Qn("Unsupported field: "+r)},i._prolepticMonth=function(){return this._year*12+(this._month-1)},i.chronology=function(){return ta.INSTANCE},i.year=function(){return this._year},i.monthValue=function(){return this._month},i.month=function(){return qi.of(this._month)},i.dayOfMonth=function(){return this._day},i.dayOfYear=function(){return this.month().firstDayOfYear(this.isLeapYear())+this._day-1},i.dayOfWeek=function(){var r=Ze.floorMod(this.toEpochDay()+3,7);return Wa.of(r+1)},i.isLeapYear=function(){return ta.isLeapYear(this._year)},i.lengthOfMonth=function(){switch(this._month){case 2:return this.isLeapYear()?29:28;case 4:case 6:case 9:case 11:return 30;default:return 31}},i.lengthOfYear=function(){return this.isLeapYear()?366:365},i._withAdjuster=function(r){return yt(r,"adjuster"),r instanceof e?r:t.prototype._withAdjuster.call(this,r)},i._withField=function(r,o){if(ha(r!=null,"field",hS),r instanceof Me){var a=r;switch(a.checkValidValue(o),a){case Me.DAY_OF_WEEK:return this.plusDays(o-this.dayOfWeek().value());case Me.ALIGNED_DAY_OF_WEEK_IN_MONTH:return this.plusDays(o-this.getLong(Me.ALIGNED_DAY_OF_WEEK_IN_MONTH));case Me.ALIGNED_DAY_OF_WEEK_IN_YEAR:return this.plusDays(o-this.getLong(Me.ALIGNED_DAY_OF_WEEK_IN_YEAR));case Me.DAY_OF_MONTH:return this.withDayOfMonth(o);case Me.DAY_OF_YEAR:return this.withDayOfYear(o);case Me.EPOCH_DAY:return e.ofEpochDay(o);case Me.ALIGNED_WEEK_OF_MONTH:return this.plusWeeks(o-this.getLong(Me.ALIGNED_WEEK_OF_MONTH));case Me.ALIGNED_WEEK_OF_YEAR:return this.plusWeeks(o-this.getLong(Me.ALIGNED_WEEK_OF_YEAR));case Me.MONTH_OF_YEAR:return this.withMonth(o);case Me.PROLEPTIC_MONTH:return this.plusMonths(o-this.getLong(Me.PROLEPTIC_MONTH));case Me.YEAR_OF_ERA:return this.withYear(this._year>=1?o:1-o);case Me.YEAR:return this.withYear(o);case Me.ERA:return this.getLong(Me.ERA)===o?this:this.withYear(1-this._year)}throw new Qn("Unsupported field: "+r)}return r.adjustInto(this,o)},i.withYear=function(r){return this._year===r?this:(Me.YEAR.checkValidValue(r),e._resolvePreviousValid(r,this._month,this._day))},i.withMonth=function(r){var o=r instanceof qi?r.value():r;return this._month===o?this:(Me.MONTH_OF_YEAR.checkValidValue(o),e._resolvePreviousValid(this._year,o,this._day))},i.withDayOfMonth=function(r){return this._day===r?this:e.of(this._year,this._month,r)},i.withDayOfYear=function(r){return this.dayOfYear()===r?this:e.ofYearDay(this._year,r)},i._plusUnit=function(r,o){if(yt(r,"amountToAdd"),yt(o,"unit"),o instanceof ft){switch(o){case ft.DAYS:return this.plusDays(r);case ft.WEEKS:return this.plusWeeks(r);case ft.MONTHS:return this.plusMonths(r);case ft.YEARS:return this.plusYears(r);case ft.DECADES:return this.plusYears(Ze.safeMultiply(r,10));case ft.CENTURIES:return this.plusYears(Ze.safeMultiply(r,100));case ft.MILLENNIA:return this.plusYears(Ze.safeMultiply(r,1e3));case ft.ERAS:return this.with(Me.ERA,Ze.safeAdd(this.getLong(Me.ERA),r))}throw new Qn("Unsupported unit: "+o)}return o.addTo(this,r)},i.plusYears=function(r){if(r===0)return this;var o=Me.YEAR.checkValidIntValue(this._year+r);return e._resolvePreviousValid(o,this._month,this._day)},i.plusMonths=function(r){if(r===0)return this;var o=this._year*12+(this._month-1),a=o+r,s=Me.YEAR.checkValidIntValue(Ze.floorDiv(a,12)),l=Ze.floorMod(a,12)+1;return e._resolvePreviousValid(s,l,this._day)},i.plusWeeks=function(r){return this.plusDays(Ze.safeMultiply(r,7))},i.plusDays=function(r){if(r===0)return this;var o=Ze.safeAdd(this.toEpochDay(),r);return e.ofEpochDay(o)},i._minusUnit=function(r,o){return yt(r,"amountToSubtract"),yt(o,"unit"),this._plusUnit(-1*r,o)},i.minusYears=function(r){return this.plusYears(r*-1)},i.minusMonths=function(r){return this.plusMonths(r*-1)},i.minusWeeks=function(r){return this.plusWeeks(r*-1)},i.minusDays=function(r){return this.plusDays(r*-1)},i.query=function(r){return yt(r,"query"),r===Dr.localDate()?this:t.prototype.query.call(this,r)},i.adjustInto=function(r){return t.prototype.adjustInto.call(this,r)},i.until=function(r,o){return arguments.length<2?this.until1(r):this.until2(r,o)},i.until2=function(r,o){var a=e.from(r);if(o instanceof ft){switch(o){case ft.DAYS:return this.daysUntil(a);case ft.WEEKS:return Ze.intDiv(this.daysUntil(a),7);case ft.MONTHS:return this._monthsUntil(a);case ft.YEARS:return Ze.intDiv(this._monthsUntil(a),12);case ft.DECADES:return Ze.intDiv(this._monthsUntil(a),120);case ft.CENTURIES:return Ze.intDiv(this._monthsUntil(a),1200);case ft.MILLENNIA:return Ze.intDiv(this._monthsUntil(a),12e3);case ft.ERAS:return a.getLong(Me.ERA)-this.getLong(Me.ERA)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},i.daysUntil=function(r){return r.toEpochDay()-this.toEpochDay()},i._monthsUntil=function(r){var o=this._prolepticMonth()*32+this.dayOfMonth(),a=r._prolepticMonth()*32+r.dayOfMonth();return Ze.intDiv(a-o,32)},i.until1=function(r){var o=e.from(r),a=o._prolepticMonth()-this._prolepticMonth(),s=o._day-this._day;if(a>0&&s<0){a--;var l=this.plusMonths(a);s=o.toEpochDay()-l.toEpochDay()}else a<0&&s>0&&(a++,s-=o.lengthOfMonth());var u=Ze.intDiv(a,12),c=Ze.intMod(a,12);return nS.of(u,c,s)},i.atTime=function(){return arguments.length===1?this.atTime1.apply(this,arguments):this.atTime4.apply(this,arguments)},i.atTime1=function(r){if(yt(r,"time"),r instanceof Zt)return ia.of(this,r);if(r instanceof Hy)return this._atTimeOffsetTime(r);throw new Pi("time must be an instance of LocalTime or OffsetTime"+(r&&r.constructor&&r.constructor.name?", but is "+r.constructor.name:""))},i.atTime4=function(r,o,a,s){return a===void 0&&(a=0),s===void 0&&(s=0),this.atTime1(Zt.of(r,o,a,s))},i._atTimeOffsetTime=function(r){return xg.of(ia.of(this,r.toLocalTime()),r.offset())},i.atStartOfDay=function(r){return r!=null?this._atStartOfDayWithZone(r):ia.of(this,Zt.MIDNIGHT)},i._atStartOfDayWithZone=function(r){yt(r,"zone");var o=this.atTime(Zt.MIDNIGHT);if(!(r instanceof en)){var a=r.rules().transition(o);a!=null&&a.isGap()&&(o=a.dateTimeAfter())}return Lv.of(o,r)},i.toEpochDay=function(){var r=this._year,o=this._month,a=0;return a+=365*r,r>=0?a+=Ze.intDiv(r+3,4)-Ze.intDiv(r+99,100)+Ze.intDiv(r+399,400):a-=Ze.intDiv(r,-4)-Ze.intDiv(r,-100)+Ze.intDiv(r,-400),a+=Ze.intDiv(367*o-362,12),a+=this.dayOfMonth()-1,o>2&&(a--,ta.isLeapYear(r)||a--),a-Hue},i.compareTo=function(r){return yt(r,"other"),_i(r,e,"other"),this._compareTo0(r)},i._compareTo0=function(r){var o=this._year-r._year;return o===0&&(o=this._month-r._month,o===0&&(o=this._day-r._day)),o},i.isAfter=function(r){return this.compareTo(r)>0},i.isBefore=function(r){return this.compareTo(r)<0},i.isEqual=function(r){return this.compareTo(r)===0},i.equals=function(r){return this===r?!0:r instanceof e?this._compareTo0(r)===0:!1},i.hashCode=function(){var r=this._year,o=this._month,a=this._day;return Ze.hash(r&4294965248^(r<<11)+(o<<6)+a)},i.toString=function(){var r,o,a,s=this._year,l=this._month,u=this._day,c=Math.abs(s);return c<1e3?s<0?a="-"+(""+(s-1e4)).slice(-4):a=(""+(s+1e4)).slice(-4):s>9999?a="+"+s:a=""+s,l<10?o="-0"+l:o="-"+l,u<10?r="-0"+u:r="-"+u,a+o+r},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),_i(r,Nn,"formatter"),t.prototype.format.call(this,r)},e})(A3);function myt(){Ci.MIN=Ci.of(Eh.MIN_VALUE,1,1),Ci.MAX=Ci.of(Eh.MAX_VALUE,12,31),Ci.EPOCH_0=Ci.ofEpochDay(0),Ci.FROM=Ou("LocalDate.FROM",function(t){return Ci.from(t)})}var Dke=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.chronology=function(){return this.toLocalDate().chronology()},i.query=function(r){return r===Dr.chronology()?this.chronology():r===Dr.precision()?ft.NANOS:r===Dr.localDate()?Ci.ofEpochDay(this.toLocalDate().toEpochDay()):r===Dr.localTime()?this.toLocalTime():r===Dr.zone()||r===Dr.zoneId()||r===Dr.offset()?null:t.prototype.query.call(this,r)},i.adjustInto=function(r){return r.with(Me.EPOCH_DAY,this.toLocalDate().toEpochDay()).with(Me.NANO_OF_DAY,this.toLocalTime().toNanoOfDay())},i.toInstant=function(r){return _i(r,en,"zoneId"),Ra.ofEpochSecond(this.toEpochSecond(r),this.toLocalTime().nano())},i.toEpochSecond=function(r){yt(r,"offset");var o=this.toLocalDate().toEpochDay(),a=o*86400+this.toLocalTime().toSecondOfDay();return a-=r.totalSeconds(),Ze.safeToInt(a)},e})(Rh),ia=(function(t){yn(e,t),e.now=function(r){return r==null?e._now(Ma.systemDefaultZone()):r instanceof Ma?e._now(r):e._now(Ma.system(r))},e._now=function(r){return yt(r,"clock"),e.ofInstant(r.instant(),r.zone())},e._ofEpochMillis=function(r,o){var a=Ze.floorDiv(r,1e3)+o.totalSeconds(),s=Ze.floorDiv(a,Zt.SECONDS_PER_DAY),l=Ze.floorMod(a,Zt.SECONDS_PER_DAY),u=Ze.floorMod(r,1e3)*1e6,c=Ci.ofEpochDay(s),d=Zt.ofSecondOfDay(l,u);return new e(c,d)},e.of=function(){return arguments.length<=2?e.ofDateAndTime.apply(this,arguments):e.ofNumbers.apply(this,arguments)},e.ofNumbers=function(r,o,a,s,l,u,c){s===void 0&&(s=0),l===void 0&&(l=0),u===void 0&&(u=0),c===void 0&&(c=0);var d=Ci.of(r,o,a),f=Zt.of(s,l,u,c);return new e(d,f)},e.ofDateAndTime=function(r,o){return yt(r,"date"),yt(o,"time"),new e(r,o)},e.ofInstant=function(r,o){o===void 0&&(o=ra.systemDefault()),yt(r,"instant"),_i(r,Ra,"instant"),yt(o,"zone");var a=o.rules().offset(r);return e.ofEpochSecond(r.epochSecond(),r.nano(),a)},e.ofEpochSecond=function(r,o,a){r===void 0&&(r=0),o===void 0&&(o=0),arguments.length===2&&o instanceof en&&(a=o,o=0),yt(a,"offset");var s=r+a.totalSeconds(),l=Ze.floorDiv(s,Zt.SECONDS_PER_DAY),u=Ze.floorMod(s,Zt.SECONDS_PER_DAY),c=Ci.ofEpochDay(l),d=Zt.ofSecondOfDay(u,o);return new e(c,d)},e.from=function(r){if(yt(r,"temporal"),r instanceof e)return r;if(r instanceof Lv)return r.toLocalDateTime();try{var o=Ci.from(r),a=Zt.from(r);return new e(o,a)}catch{throw new ai("Unable to obtain LocalDateTime TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""))}},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_LOCAL_DATE_TIME),yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r){var o;return o=t.call(this)||this,_i(n,Ci,"date"),_i(r,Zt,"time"),o._date=n,o._time=r,o}var i=e.prototype;return i._withDateTime=function(r,o){return this._date.equals(r)&&this._time.equals(o)?this:new e(r,o)},i.isSupported=function(r){return r instanceof Me||r instanceof ft?r.isDateBased()||r.isTimeBased():r!=null&&r.isSupportedBy(this)},i.range=function(r){return r instanceof Me?r.isTimeBased()?this._time.range(r):this._date.range(r):r.rangeRefinedBy(this)},i.get=function(r){return r instanceof Me?r.isTimeBased()?this._time.get(r):this._date.get(r):t.prototype.get.call(this,r)},i.getLong=function(r){return yt(r,"field"),r instanceof Me?r.isTimeBased()?this._time.getLong(r):this._date.getLong(r):r.getFrom(this)},i.year=function(){return this._date.year()},i.monthValue=function(){return this._date.monthValue()},i.month=function(){return this._date.month()},i.dayOfMonth=function(){return this._date.dayOfMonth()},i.dayOfYear=function(){return this._date.dayOfYear()},i.dayOfWeek=function(){return this._date.dayOfWeek()},i.hour=function(){return this._time.hour()},i.minute=function(){return this._time.minute()},i.second=function(){return this._time.second()},i.nano=function(){return this._time.nano()},i._withAdjuster=function(r){return yt(r,"adjuster"),r instanceof Ci?this._withDateTime(r,this._time):r instanceof Zt?this._withDateTime(this._date,r):r instanceof e?r:t.prototype._withAdjuster.call(this,r)},i._withField=function(r,o){return yt(r,"field"),r instanceof Me?r.isTimeBased()?this._withDateTime(this._date,this._time.with(r,o)):this._withDateTime(this._date.with(r,o),this._time):r.adjustInto(this,o)},i.withYear=function(r){return this._withDateTime(this._date.withYear(r),this._time)},i.withMonth=function(r){return this._withDateTime(this._date.withMonth(r),this._time)},i.withDayOfMonth=function(r){return this._withDateTime(this._date.withDayOfMonth(r),this._time)},i.withDayOfYear=function(r){return this._withDateTime(this._date.withDayOfYear(r),this._time)},i.withHour=function(r){var o=this._time.withHour(r);return this._withDateTime(this._date,o)},i.withMinute=function(r){var o=this._time.withMinute(r);return this._withDateTime(this._date,o)},i.withSecond=function(r){var o=this._time.withSecond(r);return this._withDateTime(this._date,o)},i.withNano=function(r){var o=this._time.withNano(r);return this._withDateTime(this._date,o)},i.truncatedTo=function(r){return this._withDateTime(this._date,this._time.truncatedTo(r))},i._plusUnit=function(r,o){if(yt(o,"unit"),o instanceof ft){switch(o){case ft.NANOS:return this.plusNanos(r);case ft.MICROS:return this.plusDays(Ze.intDiv(r,Zt.MICROS_PER_DAY)).plusNanos(Ze.intMod(r,Zt.MICROS_PER_DAY)*1e3);case ft.MILLIS:return this.plusDays(Ze.intDiv(r,Zt.MILLIS_PER_DAY)).plusNanos(Ze.intMod(r,Zt.MILLIS_PER_DAY)*1e6);case ft.SECONDS:return this.plusSeconds(r);case ft.MINUTES:return this.plusMinutes(r);case ft.HOURS:return this.plusHours(r);case ft.HALF_DAYS:return this.plusDays(Ze.intDiv(r,256)).plusHours(Ze.intMod(r,256)*12)}return this._withDateTime(this._date.plus(r,o),this._time)}return o.addTo(this,r)},i.plusYears=function(r){var o=this._date.plusYears(r);return this._withDateTime(o,this._time)},i.plusMonths=function(r){var o=this._date.plusMonths(r);return this._withDateTime(o,this._time)},i.plusWeeks=function(r){var o=this._date.plusWeeks(r);return this._withDateTime(o,this._time)},i.plusDays=function(r){var o=this._date.plusDays(r);return this._withDateTime(o,this._time)},i.plusHours=function(r){return this._plusWithOverflow(this._date,r,0,0,0,1)},i.plusMinutes=function(r){return this._plusWithOverflow(this._date,0,r,0,0,1)},i.plusSeconds=function(r){return this._plusWithOverflow(this._date,0,0,r,0,1)},i.plusNanos=function(r){return this._plusWithOverflow(this._date,0,0,0,r,1)},i._minusUnit=function(r,o){return yt(o,"unit"),this._plusUnit(-1*r,o)},i.minusYears=function(r){return this.plusYears(-1*r)},i.minusMonths=function(r){return this.plusMonths(-1*r)},i.minusWeeks=function(r){return this.plusWeeks(-1*r)},i.minusDays=function(r){return this.plusDays(-1*r)},i.minusHours=function(r){return this._plusWithOverflow(this._date,r,0,0,0,-1)},i.minusMinutes=function(r){return this._plusWithOverflow(this._date,0,r,0,0,-1)},i.minusSeconds=function(r){return this._plusWithOverflow(this._date,0,0,r,0,-1)},i.minusNanos=function(r){return this._plusWithOverflow(this._date,0,0,0,r,-1)},i._plusWithOverflow=function(r,o,a,s,l,u){if(o===0&&a===0&&s===0&&l===0)return this._withDateTime(r,this._time);var c=Ze.intDiv(l,Zt.NANOS_PER_DAY)+Ze.intDiv(s,Zt.SECONDS_PER_DAY)+Ze.intDiv(a,Zt.MINUTES_PER_DAY)+Ze.intDiv(o,Zt.HOURS_PER_DAY);c*=u;var d=Ze.intMod(l,Zt.NANOS_PER_DAY)+Ze.intMod(s,Zt.SECONDS_PER_DAY)*Zt.NANOS_PER_SECOND+Ze.intMod(a,Zt.MINUTES_PER_DAY)*Zt.NANOS_PER_MINUTE+Ze.intMod(o,Zt.HOURS_PER_DAY)*Zt.NANOS_PER_HOUR,f=this._time.toNanoOfDay();d=d*u+f,c+=Ze.floorDiv(d,Zt.NANOS_PER_DAY);var h=Ze.floorMod(d,Zt.NANOS_PER_DAY),p=h===f?this._time:Zt.ofNanoOfDay(h);return this._withDateTime(r.plusDays(c),p)},i.query=function(r){return yt(r,"query"),r===Dr.localDate()?this.toLocalDate():t.prototype.query.call(this,r)},i.adjustInto=function(r){return t.prototype.adjustInto.call(this,r)},i.until=function(r,o){yt(r,"endExclusive"),yt(o,"unit");var a=e.from(r);if(o instanceof ft){if(o.isTimeBased()){var s=this._date.daysUntil(a._date),l=a._time.toNanoOfDay()-this._time.toNanoOfDay();s>0&&l<0?(s--,l+=Zt.NANOS_PER_DAY):s<0&&l>0&&(s++,l-=Zt.NANOS_PER_DAY);var u=s;switch(o){case ft.NANOS:return u=Ze.safeMultiply(u,Zt.NANOS_PER_DAY),Ze.safeAdd(u,l);case ft.MICROS:return u=Ze.safeMultiply(u,Zt.MICROS_PER_DAY),Ze.safeAdd(u,Ze.intDiv(l,1e3));case ft.MILLIS:return u=Ze.safeMultiply(u,Zt.MILLIS_PER_DAY),Ze.safeAdd(u,Ze.intDiv(l,1e6));case ft.SECONDS:return u=Ze.safeMultiply(u,Zt.SECONDS_PER_DAY),Ze.safeAdd(u,Ze.intDiv(l,Zt.NANOS_PER_SECOND));case ft.MINUTES:return u=Ze.safeMultiply(u,Zt.MINUTES_PER_DAY),Ze.safeAdd(u,Ze.intDiv(l,Zt.NANOS_PER_MINUTE));case ft.HOURS:return u=Ze.safeMultiply(u,Zt.HOURS_PER_DAY),Ze.safeAdd(u,Ze.intDiv(l,Zt.NANOS_PER_HOUR));case ft.HALF_DAYS:return u=Ze.safeMultiply(u,2),Ze.safeAdd(u,Ze.intDiv(l,Zt.NANOS_PER_HOUR*12))}throw new Qn("Unsupported unit: "+o)}var c=a._date,d=a._time;return c.isAfter(this._date)&&d.isBefore(this._time)?c=c.minusDays(1):c.isBefore(this._date)&&d.isAfter(this._time)&&(c=c.plusDays(1)),this._date.until(c,o)}return o.between(this,a)},i.atOffset=function(r){return xg.of(this,r)},i.atZone=function(r){return Lv.of(this,r)},i.toLocalDate=function(){return this._date},i.toLocalTime=function(){return this._time},i.compareTo=function(r){return yt(r,"other"),_i(r,e,"other"),this._compareTo0(r)},i._compareTo0=function(r){var o=this._date.compareTo(r.toLocalDate());return o===0&&(o=this._time.compareTo(r.toLocalTime())),o},i.isAfter=function(r){return this.compareTo(r)>0},i.isBefore=function(r){return this.compareTo(r)<0},i.isEqual=function(r){return this.compareTo(r)===0},i.equals=function(r){return this===r?!0:r instanceof e?this._date.equals(r._date)&&this._time.equals(r._time):!1},i.hashCode=function(){return this._date.hashCode()^this._time.hashCode()},i.toString=function(){return this._date.toString()+"T"+this._time.toString()},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),r.format(this)},e})(Dke);function byt(){ia.MIN=ia.of(Ci.MIN,Zt.MIN),ia.MAX=ia.of(Ci.MAX,Zt.MAX),ia.FROM=Ou("LocalDateTime.FROM",function(t){return ia.from(t)})}var Zt=(function(t){yn(e,t),e.now=function(r){return r==null?e._now(Ma.systemDefaultZone()):r instanceof Ma?e._now(r):e._now(Ma.system(r))},e._now=function(r){return r===void 0&&(r=Ma.systemDefaultZone()),yt(r,"clock"),e.ofInstant(r.instant(),r.zone())},e.ofInstant=function(r,o){o===void 0&&(o=ra.systemDefault());var a=o.rules().offset(r),s=Ze.intMod(r.epochSecond(),e.SECONDS_PER_DAY);return s=Ze.intMod(s+a.totalSeconds(),e.SECONDS_PER_DAY),s<0&&(s+=e.SECONDS_PER_DAY),e.ofSecondOfDay(s,r.nano())},e.of=function(r,o,a,s){return new e(r,o,a,s)},e.ofSecondOfDay=function(r,o){r===void 0&&(r=0),o===void 0&&(o=0),Me.SECOND_OF_DAY.checkValidValue(r),Me.NANO_OF_SECOND.checkValidValue(o);var a=Ze.intDiv(r,e.SECONDS_PER_HOUR);r-=a*e.SECONDS_PER_HOUR;var s=Ze.intDiv(r,e.SECONDS_PER_MINUTE);return r-=s*e.SECONDS_PER_MINUTE,new e(a,s,r,o)},e.ofNanoOfDay=function(r){r===void 0&&(r=0),Me.NANO_OF_DAY.checkValidValue(r);var o=Ze.intDiv(r,e.NANOS_PER_HOUR);r-=o*e.NANOS_PER_HOUR;var a=Ze.intDiv(r,e.NANOS_PER_MINUTE);r-=a*e.NANOS_PER_MINUTE;var s=Ze.intDiv(r,e.NANOS_PER_SECOND);return r-=s*e.NANOS_PER_SECOND,new e(o,a,s,r)},e.from=function(r){yt(r,"temporal");var o=r.query(Dr.localTime());if(o==null)throw new ai("Unable to obtain LocalTime TemporalAccessor: "+r+", type "+(r.constructor!=null?r.constructor.name:""));return o},e.parse=function(r,o){return o===void 0&&(o=Nn.ISO_LOCAL_TIME),yt(o,"formatter"),o.parse(r,e.FROM)};function e(n,r,o,a){var s;n===void 0&&(n=0),r===void 0&&(r=0),o===void 0&&(o=0),a===void 0&&(a=0),s=t.call(this)||this;var l=Ze.safeToInt(n),u=Ze.safeToInt(r),c=Ze.safeToInt(o),d=Ze.safeToInt(a);return e._validate(l,u,c,d),u===0&&c===0&&d===0?(e.HOURS[l]||(s._hour=l,s._minute=u,s._second=c,s._nano=d,e.HOURS[l]=w3(s)),e.HOURS[l]||w3(s)):(s._hour=l,s._minute=u,s._second=c,s._nano=d,s)}e._validate=function(r,o,a,s){Me.HOUR_OF_DAY.checkValidValue(r),Me.MINUTE_OF_HOUR.checkValidValue(o),Me.SECOND_OF_MINUTE.checkValidValue(a),Me.NANO_OF_SECOND.checkValidValue(s)};var i=e.prototype;return i.isSupported=function(r){return r instanceof Me||r instanceof ft?r.isTimeBased():r!=null&&r.isSupportedBy(this)},i.range=function(r){return yt(r),t.prototype.range.call(this,r)},i.get=function(r){return this.getLong(r)},i.getLong=function(r){return yt(r,"field"),r instanceof Me?this._get0(r):r.getFrom(this)},i._get0=function(r){switch(r){case Me.NANO_OF_SECOND:return this._nano;case Me.NANO_OF_DAY:return this.toNanoOfDay();case Me.MICRO_OF_SECOND:return Ze.intDiv(this._nano,1e3);case Me.MICRO_OF_DAY:return Ze.intDiv(this.toNanoOfDay(),1e3);case Me.MILLI_OF_SECOND:return Ze.intDiv(this._nano,1e6);case Me.MILLI_OF_DAY:return Ze.intDiv(this.toNanoOfDay(),1e6);case Me.SECOND_OF_MINUTE:return this._second;case Me.SECOND_OF_DAY:return this.toSecondOfDay();case Me.MINUTE_OF_HOUR:return this._minute;case Me.MINUTE_OF_DAY:return this._hour*60+this._minute;case Me.HOUR_OF_AMPM:return Ze.intMod(this._hour,12);case Me.CLOCK_HOUR_OF_AMPM:{var o=Ze.intMod(this._hour,12);return o%12===0?12:o}case Me.HOUR_OF_DAY:return this._hour;case Me.CLOCK_HOUR_OF_DAY:return this._hour===0?24:this._hour;case Me.AMPM_OF_DAY:return Ze.intDiv(this._hour,12)}throw new Qn("Unsupported field: "+r)},i.hour=function(){return this._hour},i.minute=function(){return this._minute},i.second=function(){return this._second},i.nano=function(){return this._nano},i._withAdjuster=function(r){return yt(r,"adjuster"),r instanceof e?r:t.prototype._withAdjuster.call(this,r)},i._withField=function(r,o){if(yt(r,"field"),_i(r,Ky,"field"),r instanceof Me){switch(r.checkValidValue(o),r){case Me.NANO_OF_SECOND:return this.withNano(o);case Me.NANO_OF_DAY:return e.ofNanoOfDay(o);case Me.MICRO_OF_SECOND:return this.withNano(o*1e3);case Me.MICRO_OF_DAY:return e.ofNanoOfDay(o*1e3);case Me.MILLI_OF_SECOND:return this.withNano(o*1e6);case Me.MILLI_OF_DAY:return e.ofNanoOfDay(o*1e6);case Me.SECOND_OF_MINUTE:return this.withSecond(o);case Me.SECOND_OF_DAY:return this.plusSeconds(o-this.toSecondOfDay());case Me.MINUTE_OF_HOUR:return this.withMinute(o);case Me.MINUTE_OF_DAY:return this.plusMinutes(o-(this._hour*60+this._minute));case Me.HOUR_OF_AMPM:return this.plusHours(o-Ze.intMod(this._hour,12));case Me.CLOCK_HOUR_OF_AMPM:return this.plusHours((o===12?0:o)-Ze.intMod(this._hour,12));case Me.HOUR_OF_DAY:return this.withHour(o);case Me.CLOCK_HOUR_OF_DAY:return this.withHour(o===24?0:o);case Me.AMPM_OF_DAY:return this.plusHours((o-Ze.intDiv(this._hour,12))*12)}throw new Qn("Unsupported field: "+r)}return r.adjustInto(this,o)},i.withHour=function(r){return r===void 0&&(r=0),this._hour===r?this:new e(r,this._minute,this._second,this._nano)},i.withMinute=function(r){return r===void 0&&(r=0),this._minute===r?this:new e(this._hour,r,this._second,this._nano)},i.withSecond=function(r){return r===void 0&&(r=0),this._second===r?this:new e(this._hour,this._minute,r,this._nano)},i.withNano=function(r){return r===void 0&&(r=0),this._nano===r?this:new e(this._hour,this._minute,this._second,r)},i.truncatedTo=function(r){if(yt(r,"unit"),r===ft.NANOS)return this;var o=r.duration();if(o.seconds()>e.SECONDS_PER_DAY)throw new ai("Unit is too large to be used for truncation");var a=o.toNanos();if(Ze.intMod(e.NANOS_PER_DAY,a)!==0)throw new ai("Unit must divide into a standard day without remainder");var s=this.toNanoOfDay();return e.ofNanoOfDay(Ze.intDiv(s,a)*a)},i._plusUnit=function(r,o){if(yt(o,"unit"),o instanceof ft){switch(o){case ft.NANOS:return this.plusNanos(r);case ft.MICROS:return this.plusNanos(Ze.intMod(r,e.MICROS_PER_DAY)*1e3);case ft.MILLIS:return this.plusNanos(Ze.intMod(r,e.MILLIS_PER_DAY)*1e6);case ft.SECONDS:return this.plusSeconds(r);case ft.MINUTES:return this.plusMinutes(r);case ft.HOURS:return this.plusHours(r);case ft.HALF_DAYS:return this.plusHours(Ze.intMod(r,2)*12)}throw new Qn("Unsupported unit: "+o)}return o.addTo(this,r)},i.plusHours=function(r){if(r===0)return this;var o=Ze.intMod(Ze.intMod(r,e.HOURS_PER_DAY)+this._hour+e.HOURS_PER_DAY,e.HOURS_PER_DAY);return new e(o,this._minute,this._second,this._nano)},i.plusMinutes=function(r){if(r===0)return this;var o=this._hour*e.MINUTES_PER_HOUR+this._minute,a=Ze.intMod(Ze.intMod(r,e.MINUTES_PER_DAY)+o+e.MINUTES_PER_DAY,e.MINUTES_PER_DAY);if(o===a)return this;var s=Ze.intDiv(a,e.MINUTES_PER_HOUR),l=Ze.intMod(a,e.MINUTES_PER_HOUR);return new e(s,l,this._second,this._nano)},i.plusSeconds=function(r){if(r===0)return this;var o=this._hour*e.SECONDS_PER_HOUR+this._minute*e.SECONDS_PER_MINUTE+this._second,a=Ze.intMod(Ze.intMod(r,e.SECONDS_PER_DAY)+o+e.SECONDS_PER_DAY,e.SECONDS_PER_DAY);if(o===a)return this;var s=Ze.intDiv(a,e.SECONDS_PER_HOUR),l=Ze.intMod(Ze.intDiv(a,e.SECONDS_PER_MINUTE),e.MINUTES_PER_HOUR),u=Ze.intMod(a,e.SECONDS_PER_MINUTE);return new e(s,l,u,this._nano)},i.plusNanos=function(r){if(r===0)return this;var o=this.toNanoOfDay(),a=Ze.intMod(Ze.intMod(r,e.NANOS_PER_DAY)+o+e.NANOS_PER_DAY,e.NANOS_PER_DAY);if(o===a)return this;var s=Ze.intDiv(a,e.NANOS_PER_HOUR),l=Ze.intMod(Ze.intDiv(a,e.NANOS_PER_MINUTE),e.MINUTES_PER_HOUR),u=Ze.intMod(Ze.intDiv(a,e.NANOS_PER_SECOND),e.SECONDS_PER_MINUTE),c=Ze.intMod(a,e.NANOS_PER_SECOND);return new e(s,l,u,c)},i._minusUnit=function(r,o){return yt(o,"unit"),this._plusUnit(-1*r,o)},i.minusHours=function(r){return this.plusHours(-1*Ze.intMod(r,e.HOURS_PER_DAY))},i.minusMinutes=function(r){return this.plusMinutes(-1*Ze.intMod(r,e.MINUTES_PER_DAY))},i.minusSeconds=function(r){return this.plusSeconds(-1*Ze.intMod(r,e.SECONDS_PER_DAY))},i.minusNanos=function(r){return this.plusNanos(-1*Ze.intMod(r,e.NANOS_PER_DAY))},i.query=function(r){return yt(r,"query"),r===Dr.precision()?ft.NANOS:r===Dr.localTime()?this:r===Dr.chronology()||r===Dr.zoneId()||r===Dr.zone()||r===Dr.offset()||r===Dr.localDate()?null:r.queryFrom(this)},i.adjustInto=function(r){return r.with(e.NANO_OF_DAY,this.toNanoOfDay())},i.until=function(r,o){yt(r,"endExclusive"),yt(o,"unit");var a=e.from(r);if(o instanceof ft){var s=a.toNanoOfDay()-this.toNanoOfDay();switch(o){case ft.NANOS:return s;case ft.MICROS:return Ze.intDiv(s,1e3);case ft.MILLIS:return Ze.intDiv(s,1e6);case ft.SECONDS:return Ze.intDiv(s,e.NANOS_PER_SECOND);case ft.MINUTES:return Ze.intDiv(s,e.NANOS_PER_MINUTE);case ft.HOURS:return Ze.intDiv(s,e.NANOS_PER_HOUR);case ft.HALF_DAYS:return Ze.intDiv(s,12*e.NANOS_PER_HOUR)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},i.atDate=function(r){return ia.of(r,this)},i.atOffset=function(r){return Hy.of(this,r)},i.toSecondOfDay=function(){var r=this._hour*e.SECONDS_PER_HOUR;return r+=this._minute*e.SECONDS_PER_MINUTE,r+=this._second,r},i.toNanoOfDay=function(){var r=this._hour*e.NANOS_PER_HOUR;return r+=this._minute*e.NANOS_PER_MINUTE,r+=this._second*e.NANOS_PER_SECOND,r+=this._nano,r},i.compareTo=function(r){yt(r,"other"),_i(r,e,"other");var o=Ze.compareNumbers(this._hour,r._hour);return o===0&&(o=Ze.compareNumbers(this._minute,r._minute),o===0&&(o=Ze.compareNumbers(this._second,r._second),o===0&&(o=Ze.compareNumbers(this._nano,r._nano)))),o},i.isAfter=function(r){return this.compareTo(r)>0},i.isBefore=function(r){return this.compareTo(r)<0},i.equals=function(r){return this===r?!0:r instanceof e?this._hour===r._hour&&this._minute===r._minute&&this._second===r._second&&this._nano===r._nano:!1},i.hashCode=function(){var r=this.toNanoOfDay();return Ze.hash(r)},i.toString=function(){var r="",o=this._hour,a=this._minute,s=this._second,l=this._nano;return r+=o<10?"0":"",r+=o,r+=a<10?":0":":",r+=a,(s>0||l>0)&&(r+=s<10?":0":":",r+=s,l>0&&(r+=".",Ze.intMod(l,1e6)===0?r+=(""+(Ze.intDiv(l,1e6)+1e3)).substring(1):Ze.intMod(l,1e3)===0?r+=(""+(Ze.intDiv(l,1e3)+1e6)).substring(1):r+=(""+(l+1e9)).substring(1))),r},i.toJSON=function(){return this.toString()},i.format=function(r){return yt(r,"formatter"),r.format(this)},e})(Rh);function Syt(){Zt.HOURS=[];for(var t=0;t<24;t++)Zt.of(t,0,0,0);Zt.MIN=Zt.HOURS[0],Zt.MAX=new Zt(23,59,59,999999999),Zt.MIDNIGHT=Zt.HOURS[0],Zt.NOON=Zt.HOURS[12],Zt.FROM=Ou("LocalTime.FROM",function(e){return Zt.from(e)})}Zt.HOURS_PER_DAY=24;Zt.MINUTES_PER_HOUR=60;Zt.MINUTES_PER_DAY=Zt.MINUTES_PER_HOUR*Zt.HOURS_PER_DAY;Zt.SECONDS_PER_MINUTE=60;Zt.SECONDS_PER_HOUR=Zt.SECONDS_PER_MINUTE*Zt.MINUTES_PER_HOUR;Zt.SECONDS_PER_DAY=Zt.SECONDS_PER_HOUR*Zt.HOURS_PER_DAY;Zt.MILLIS_PER_DAY=Zt.SECONDS_PER_DAY*1e3;Zt.MICROS_PER_DAY=Zt.SECONDS_PER_DAY*1e6;Zt.NANOS_PER_SECOND=1e9;Zt.NANOS_PER_MINUTE=Zt.NANOS_PER_SECOND*Zt.SECONDS_PER_MINUTE;Zt.NANOS_PER_HOUR=Zt.NANOS_PER_MINUTE*Zt.MINUTES_PER_HOUR;Zt.NANOS_PER_DAY=Zt.NANOS_PER_HOUR*Zt.HOURS_PER_DAY;var h4=1e6,Ra=(function(t){yn(e,t),e.now=function(r){return r===void 0&&(r=Ma.systemUTC()),r.instant()},e.ofEpochSecond=function(r,o){o===void 0&&(o=0);var a=r+Ze.floorDiv(o,Zt.NANOS_PER_SECOND),s=Ze.floorMod(o,Zt.NANOS_PER_SECOND);return e._create(a,s)},e.ofEpochMilli=function(r){var o=Ze.floorDiv(r,1e3),a=Ze.floorMod(r,1e3);return e._create(o,a*1e6)},e.ofEpochMicro=function(r){var o=Ze.floorDiv(r,1e6),a=Ze.floorMod(r,1e6);return e._create(o,a*1e3)},e.from=function(r){try{var o=r.getLong(Me.INSTANT_SECONDS),a=r.get(Me.NANO_OF_SECOND);return e.ofEpochSecond(o,a)}catch(s){throw new ai("Unable to obtain Instant from TemporalAccessor: "+r+", type "+typeof r,s)}},e.parse=function(r){return Nn.ISO_INSTANT.parse(r,e.FROM)},e._create=function(r,o){return r===0&&o===0?e.EPOCH:new e(r,o)},e._validate=function(r,o){if(r<e.MIN_SECONDS||r>e.MAX_SECONDS)throw new ai("Instant exceeds minimum or maximum instant");if(o<0||o>Zt.NANOS_PER_SECOND)throw new ai("Instant exceeds minimum or maximum instant")};function e(n,r){var o;return o=t.call(this)||this,e._validate(n,r),o._seconds=Ze.safeToInt(n),o._nanos=Ze.safeToInt(r),o}var i=e.prototype;return i.isSupported=function(r){return r instanceof Me?r===Me.INSTANT_SECONDS||r===Me.NANO_OF_SECOND||r===Me.MICRO_OF_SECOND||r===Me.MILLI_OF_SECOND:r instanceof ft?r.isTimeBased()||r===ft.DAYS:r!=null&&r.isSupportedBy(this)},i.range=function(r){return t.prototype.range.call(this,r)},i.get=function(r){return this.getLong(r)},i.getLong=function(r){if(r instanceof Me){switch(r){case Me.NANO_OF_SECOND:return this._nanos;case Me.MICRO_OF_SECOND:return Ze.intDiv(this._nanos,1e3);case Me.MILLI_OF_SECOND:return Ze.intDiv(this._nanos,h4);case Me.INSTANT_SECONDS:return this._seconds}throw new Qn("Unsupported field: "+r)}return r.getFrom(this)},i.epochSecond=function(){return this._seconds},i.nano=function(){return this._nanos},i._withField=function(r,o){if(yt(r,"field"),r instanceof Me){switch(r.checkValidValue(o),r){case Me.MILLI_OF_SECOND:{var a=o*h4;return a!==this._nanos?e._create(this._seconds,a):this}case Me.MICRO_OF_SECOND:{var s=o*1e3;return s!==this._nanos?e._create(this._seconds,s):this}case Me.NANO_OF_SECOND:return o!==this._nanos?e._create(this._seconds,o):this;case Me.INSTANT_SECONDS:return o!==this._seconds?e._create(o,this._nanos):this}throw new Qn("Unsupported field: "+r)}return r.adjustInto(this,o)},i.truncatedTo=function(r){if(yt(r,"unit"),r===ft.NANOS)return this;var o=r.duration();if(o.seconds()>Zt.SECONDS_PER_DAY)throw new ai("Unit is too large to be used for truncation");var a=o.toNanos();if(Ze.intMod(Zt.NANOS_PER_DAY,a)!==0)throw new ai("Unit must divide into a standard day without remainder");var s=Ze.intMod(this._seconds,Zt.SECONDS_PER_DAY)*Zt.NANOS_PER_SECOND+this._nanos,l=Ze.intDiv(s,a)*a;return this.plusNanos(l-s)},i._plusUnit=function(r,o){if(yt(r,"amountToAdd"),yt(o,"unit"),_i(o,AS),o instanceof ft){switch(o){case ft.NANOS:return this.plusNanos(r);case ft.MICROS:return this.plusMicros(r);case ft.MILLIS:return this.plusMillis(r);case ft.SECONDS:return this.plusSeconds(r);case ft.MINUTES:return this.plusSeconds(Ze.safeMultiply(r,Zt.SECONDS_PER_MINUTE));case ft.HOURS:return this.plusSeconds(Ze.safeMultiply(r,Zt.SECONDS_PER_HOUR));case ft.HALF_DAYS:return this.plusSeconds(Ze.safeMultiply(r,Zt.SECONDS_PER_DAY/2));case ft.DAYS:return this.plusSeconds(Ze.safeMultiply(r,Zt.SECONDS_PER_DAY))}throw new Qn("Unsupported unit: "+o)}return o.addTo(this,r)},i.plusSeconds=function(r){return this._plus(r,0)},i.plusMillis=function(r){return this._plus(Ze.intDiv(r,1e3),Ze.intMod(r,1e3)*h4)},i.plusNanos=function(r){return this._plus(0,r)},i.plusMicros=function(r){return this._plus(Ze.intDiv(r,1e6),Ze.intMod(r,1e6)*1e3)},i._plus=function(r,o){if(r===0&&o===0)return this;var a=this._seconds+r;a=a+Ze.intDiv(o,Zt.NANOS_PER_SECOND);var s=this._nanos+o%Zt.NANOS_PER_SECOND;return e.ofEpochSecond(a,s)},i._minusUnit=function(r,o){return this._plusUnit(-1*r,o)},i.minusSeconds=function(r){return this.plusSeconds(r*-1)},i.minusMillis=function(r){return this.plusMillis(-1*r)},i.minusNanos=function(r){return this.plusNanos(-1*r)},i.minusMicros=function(r){return this.plusMicros(-1*r)},i.query=function(r){return yt(r,"query"),r===Dr.precision()?ft.NANOS:r===Dr.localDate()||r===Dr.localTime()||r===Dr.chronology()||r===Dr.zoneId()||r===Dr.zone()||r===Dr.offset()?null:r.queryFrom(this)},i.adjustInto=function(r){return yt(r,"temporal"),r.with(Me.INSTANT_SECONDS,this._seconds).with(Me.NANO_OF_SECOND,this._nanos)},i.until=function(r,o){yt(r,"endExclusive"),yt(o,"unit");var a=e.from(r);if(o instanceof ft){switch(o){case ft.NANOS:return this._nanosUntil(a);case ft.MICROS:return this._microsUntil(a);case ft.MILLIS:return Ze.safeSubtract(a.toEpochMilli(),this.toEpochMilli());case ft.SECONDS:return this._secondsUntil(a);case ft.MINUTES:return Ze.intDiv(this._secondsUntil(a),Zt.SECONDS_PER_MINUTE);case ft.HOURS:return Ze.intDiv(this._secondsUntil(a),Zt.SECONDS_PER_HOUR);case ft.HALF_DAYS:return Ze.intDiv(this._secondsUntil(a),12*Zt.SECONDS_PER_HOUR);case ft.DAYS:return Ze.intDiv(this._secondsUntil(a),Zt.SECONDS_PER_DAY)}throw new Qn("Unsupported unit: "+o)}return o.between(this,a)},i._microsUntil=function(r){var o=Ze.safeSubtract(r.epochSecond(),this.epochSecond()),a=Ze.safeMultiply(o,1e6);return Ze.safeAdd(a,Ze.intDiv(r.nano()-this.nano(),1e3))},i._nanosUntil=function(r){var o=Ze.safeSubtract(r.epochSecond(),this.epochSecond()),a=Ze.safeMultiply(o,Zt.NANOS_PER_SECOND);return Ze.safeAdd(a,r.nano()-this.nano())},i._secondsUntil=function(r){var o=Ze.safeSubtract(r.epochSecond(),this.epochSecond()),a=r.nano()-this.nano();return o>0&&a<0?o--:o<0&&a>0&&o++,o},i.atOffset=function(r){return xg.ofInstant(this,r)},i.atZone=function(r){return Lv.ofInstant(this,r)},i.toEpochMilli=function(){var r=Ze.safeMultiply(this._seconds,1e3);return r+Ze.intDiv(this._nanos,h4)},i.compareTo=function(r){yt(r,"otherInstant"),_i(r,e,"otherInstant");var o=Ze.compareNumbers(this._seconds,r._seconds);return o!==0?o:this._nanos-r._nanos},i.isAfter=function(r){return this.compareTo(r)>0},i.isBefore=function(r){return this.compareTo(r)<0},i.equals=function(r){return this===r?!0:r instanceof e?this.epochSecond()===r.epochSecond()&&this.nano()===r.nano():!1},i.hashCode=function(){return Ze.hashCode(this._seconds,this._nanos)},i.toString=function(){return Nn.ISO_INSTANT.format(this)},i.toJSON=function(){return this.toString()},e})(Rh);function _yt(){Ra.MIN_SECONDS=-31619119219200,Ra.MAX_SECONDS=31494816403199,Ra.EPOCH=new Ra(0,0),Ra.MIN=Ra.ofEpochSecond(Ra.MIN_SECONDS,0),Ra.MAX=Ra.ofEpochSecond(Ra.MAX_SECONDS,999999999),Ra.FROM=Ou("Instant.FROM",function(t){return Ra.from(t)})}var Ma=(function(){function t(){}t.systemUTC=function(){return new dY(en.UTC)},t.systemDefaultZone=function(){return new dY(ra.systemDefault())},t.system=function(n){return new dY(n)},t.fixed=function(n,r){return new Pyt(n,r)},t.offset=function(n,r){return new Cyt(n,r)};var e=t.prototype;return e.millis=function(){Hi("Clock.millis")},e.instant=function(){Hi("Clock.instant")},e.zone=function(){Hi("Clock.zone")},e.withZone=function(){Hi("Clock.withZone")},t})(),dY=(function(t){yn(e,t);function e(n){var r;return yt(n,"zone"),r=t.call(this)||this,r._zone=n,r}var i=e.prototype;return i.zone=function(){return this._zone},i.millis=function(){return new Date().getTime()},i.instant=function(){return Ra.ofEpochMilli(this.millis())},i.equals=function(r){return r instanceof e?this._zone.equals(r._zone):!1},i.withZone=function(r){return r.equals(this._zone)?this:new e(r)},i.toString=function(){return"SystemClock["+this._zone.toString()+"]"},e})(Ma),Pyt=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._instant=n,o._zoneId=r,o}var i=e.prototype;return i.instant=function(){return this._instant},i.millis=function(){return this._instant.toEpochMilli()},i.zone=function(){return this._zoneId},i.toString=function(){return"FixedClock[]"},i.equals=function(r){return r instanceof e?this._instant.equals(r._instant)&&this._zoneId.equals(r._zoneId):!1},i.withZone=function(r){return r.equals(this._zoneId)?this:new e(this._instant,r)},e})(Ma),Cyt=(function(t){yn(e,t);function e(n,r){var o;return o=t.call(this)||this,o._baseClock=n,o._offset=r,o}var i=e.prototype;return i.zone=function(){return this._baseClock.zone()},i.withZone=function(r){return r.equals(this._baseClock.zone())?this:new e(this._baseClock.withZone(r),this._offset)},i.millis=function(){return this._baseClock.millis()+this._offset.toMillis()},i.instant=function(){return this._baseClock.instant().plus(this._offset)},i.equals=function(r){return r instanceof e?this._baseClock.equals(r._baseClock)&&this._offset.equals(r._offset):!1},i.toString=function(){return"OffsetClock["+this._baseClock+","+this._offset+"]"},e})(Ma);/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Tyt=(function(){t.of=function(n,r,o){return new t(n,r,o)};function t(i,n,r){if(yt(i,"transition"),yt(n,"offsetBefore"),yt(r,"offsetAfter"),n.equals(r))throw new Pi("Offsets must not be equal");if(i.nano()!==0)throw new Pi("Nano-of-second must be zero");i instanceof ia?this._transition=i:this._transition=ia.ofEpochSecond(i,0,n),this._offsetBefore=n,this._offsetAfter=r}var e=t.prototype;return e.instant=function(){return this._transition.toInstant(this._offsetBefore)},e.toEpochSecond=function(){return this._transition.toEpochSecond(this._offsetBefore)},e.dateTimeBefore=function(){return this._transition},e.dateTimeAfter=function(){return this._transition.plusSeconds(this.durationSeconds())},e.offsetBefore=function(){return this._offsetBefore},e.offsetAfter=function(){return this._offsetAfter},e.duration=function(){return fl.ofSeconds(this.durationSeconds())},e.durationSeconds=function(){return this._offsetAfter.totalSeconds()-this._offsetBefore.totalSeconds()},e.isGap=function(){return this._offsetAfter.totalSeconds()>this._offsetBefore.totalSeconds()},e.isOverlap=function(){return this._offsetAfter.totalSeconds()<this._offsetBefore.totalSeconds()},e.isValidOffset=function(n){return this.isGap()?!1:this._offsetBefore.equals(n)||this._offsetAfter.equals(n)},e.validOffsets=function(){return this.isGap()?[]:[this._offsetBefore,this._offsetAfter]},e.compareTo=function(n){return this.instant().compareTo(n.instant())},e.equals=function(n){if(n===this)return!0;if(n instanceof t){var r=n;return this._transition.equals(r._transition)&&this._offsetBefore.equals(r.offsetBefore())&&this._offsetAfter.equals(r.offsetAfter())}return!1},e.hashCode=function(){return this._transition.hashCode()^this._offsetBefore.hashCode()^this._offsetAfter.hashCode()>>>16},e.toString=function(){return"Transition["+(this.isGap()?"Gap":"Overlap")+" at "+this._transition.toString()+this._offsetBefore.toString()+" to "+this._offsetAfter+"]"},t})();/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */function xyt(){Dr.ZONE_ID=Ou("ZONE_ID",function(t){return t.query(Dr.ZONE_ID)}),Dr.CHRONO=Ou("CHRONO",function(t){return t.query(Dr.CHRONO)}),Dr.PRECISION=Ou("PRECISION",function(t){return t.query(Dr.PRECISION)}),Dr.OFFSET=Ou("OFFSET",function(t){return t.isSupported(Me.OFFSET_SECONDS)?en.ofTotalSeconds(t.get(Me.OFFSET_SECONDS)):null}),Dr.ZONE=Ou("ZONE",function(t){var e=t.query(Dr.ZONE_ID);return e??t.query(Dr.OFFSET)}),Dr.LOCAL_DATE=Ou("LOCAL_DATE",function(t){return t.isSupported(Me.EPOCH_DAY)?Ci.ofEpochDay(t.getLong(Me.EPOCH_DAY)):null}),Dr.LOCAL_TIME=Ou("LOCAL_TIME",function(t){return t.isSupported(Me.NANO_OF_DAY)?Zt.ofNanoOfDay(t.getLong(Me.NANO_OF_DAY)):null})}var Eyt=(function(t){yn(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.isFixedOffset=function(){return!1},i.offsetOfInstant=function(r){var o=new Date(r.toEpochMilli()).getTimezoneOffset();return en.ofTotalMinutes(o*-1)},i.offsetOfEpochMilli=function(r){var o=new Date(r).getTimezoneOffset();return en.ofTotalMinutes(o*-1)},i.offsetOfLocalDateTime=function(r){var o=r.toEpochSecond(en.UTC)*1e3,a=new Date(o).getTimezoneOffset(),s=o+a*6e4,l=new Date(s).getTimezoneOffset();return en.ofTotalMinutes(l*-1)},i.validOffsets=function(r){return[this.offsetOfLocalDateTime(r)]},i.transition=function(){return null},i.standardOffset=function(r){return this.offsetOfInstant(r)},i.daylightSavings=function(){this._throwNotSupported()},i.isDaylightSavings=function(){this._throwNotSupported()},i.isValidOffset=function(r,o){return this.offsetOfLocalDateTime(r).equals(o)},i.nextTransition=function(){this._throwNotSupported()},i.previousTransition=function(){this._throwNotSupported()},i.transitions=function(){this._throwNotSupported()},i.transitionRules=function(){this._throwNotSupported()},i._throwNotSupported=function(){throw new ai("not supported operation")},i.equals=function(r){return this===r||r instanceof e},i.toString=function(){return"SYSTEM"},e})(L6),wyt=(function(t){yn(e,t);function e(){var n;return n=t.call(this)||this,n._rules=new Eyt,n}var i=e.prototype;return i.rules=function(){return this._rules},i.equals=function(r){return this===r},i.id=function(){return"SYSTEM"},e})(ra);/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @copyright (c) 2007-present, Stephen Colebourne & Michael Nascimento Santos
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var tL=(function(){function t(){}return t.systemDefault=function(){return MZ},t.getAvailableZoneIds=function(){return k6.getAvailableZoneIds()},t.of=function(i){if(yt(i,"zoneId"),i==="Z")return en.UTC;if(i.length===1)throw new ai("Invalid zone: "+i);if(Oy.startsWith(i,"+")||Oy.startsWith(i,"-"))return en.of(i);if(i==="UTC"||i==="GMT"||i==="GMT0"||i==="UT")return new Dy(i,en.UTC.rules());if(Oy.startsWith(i,"UTC+")||Oy.startsWith(i,"GMT+")||Oy.startsWith(i,"UTC-")||Oy.startsWith(i,"GMT-")){var n=en.of(i.substring(3));return n.totalSeconds()===0?new Dy(i.substring(0,3),n.rules()):new Dy(i.substring(0,3)+n.id(),n.rules())}if(Oy.startsWith(i,"UT+")||Oy.startsWith(i,"UT-")){var r=en.of(i.substring(2));return r.totalSeconds()===0?new Dy("UT",r.rules()):new Dy("UT"+r.id(),r.rules())}return i==="SYSTEM"?ra.systemDefault():Dy.ofId(i)},t.ofOffset=function(i,n){if(yt(i,"prefix"),yt(n,"offset"),i.length===0)return n;if(i==="GMT"||i==="UTC"||i==="UT")return n.totalSeconds()===0?new Dy(i,n.rules()):new Dy(i+n.id(),n.rules());throw new Pi("Invalid prefix, must be GMT, UTC or UT: "+i)},t.from=function(i){yt(i,"temporal");var n=i.query(Dr.zone());if(n==null)throw new ai("Unable to obtain ZoneId from TemporalAccessor: "+i+", type "+(i.constructor!=null?i.constructor.name:""));return n},t})(),MZ=null;function Ayt(){MZ=new wyt,ra.systemDefault=tL.systemDefault,ra.getAvailableZoneIds=tL.getAvailableZoneIds,ra.of=tL.of,ra.ofOffset=tL.ofOffset,ra.from=tL.from,en.from=tL.from,ra.SYSTEM=MZ,ra.UTC=en.ofTotalSeconds(0)}/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Uue=!1;function Oyt(){Uue||(Uue=!0,$vt(),zvt(),Wvt(),Gvt(),Syt(),nyt(),xyt(),Yvt(),_yt(),myt(),byt(),fyt(),qvt(),dyt(),cyt(),Kvt(),Jvt(),vyt(),Ayt(),hyt(),uyt(),lyt(),yyt(),pyt())}Oyt();/*
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var Dyt=(function(){function t(i,n){var r;if(i instanceof Ra){this.instant=i;return}else if(i instanceof Ci)n=n??ra.systemDefault(),r=i.atStartOfDay(n);else if(i instanceof ia)n=n??ra.systemDefault(),r=i.atZone(n);else if(i instanceof Lv)n==null?r=i:r=i.withZoneSameInstant(n);else throw new Pi("unsupported instance for convert operation:"+i);this.instant=r.toInstant()}var e=t.prototype;return e.toDate=function(){return new Date(this.instant.toEpochMilli())},e.toEpochMilli=function(){return this.instant.toEpochMilli()},t})();function Ryt(t,e){return new Dyt(t,e)}/*
 * @copyright (c) 2015-present, Philipp Thürwächter, Pattrick Hüper & js-joda contributors
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */function Myt(t,e){if(e===void 0&&(e=ra.systemDefault()),yt(t,"date"),yt(e,"zone"),t instanceof Date)return Ra.ofEpochMilli(t.getTime()).atZone(e);if(typeof t.toDate=="function"&&t.toDate()instanceof Date)return Ra.ofEpochMilli(t.toDate().getTime()).atZone(e);throw new Pi("date must be a javascript Date or a moment instance")}function Lyt(t){var e=[];return function(n){return~e.indexOf(n)||(n(t),e.push(n)),t}}/**
 * @copyright (c) 2016, Philipp Thürwächter & Pattrick Hüper
 * @license BSD-3-Clause (see LICENSE in the root directory of this source tree)
 */var kyt={assert:Uvt,DateTimeBuilder:pz,DateTimeParseContext:Ske,DateTimePrintContext:_ke,MathUtil:Ze,StringUtil:Oy,StringBuilder:Eke},Rke={_:kyt,convert:Ryt,nativeJs:Myt,ArithmeticException:mv,DateTimeException:ai,DateTimeParseException:Pv,IllegalArgumentException:Pi,IllegalStateException:E3,UnsupportedTemporalTypeException:Qn,NullPointerException:hS,Clock:Ma,DayOfWeek:Wa,Duration:fl,Instant:Ra,LocalDate:Ci,LocalTime:Zt,LocalDateTime:ia,OffsetTime:Hy,OffsetDateTime:xg,Month:qi,MonthDay:vz,ParsePosition:mke,Period:nS,Year:Av,YearConstants:Eh,YearMonth:O3,ZonedDateTime:Lv,ZoneOffset:en,ZoneId:ra,ZoneRegion:Dy,ZoneOffsetTransition:Tyt,ZoneRules:L6,ZoneRulesProvider:k6,ChronoLocalDate:A3,ChronoLocalDateTime:Dke,ChronoZonedDateTime:Oke,IsoChronology:ta,ChronoField:Me,ChronoUnit:ft,IsoFields:pv,Temporal:Rh,TemporalAccessor:xP,TemporalAdjuster:I6,TemporalAdjusters:Ake,TemporalAmount:MD,TemporalField:Ky,TemporalQueries:Dr,TemporalQuery:NV,TemporalUnit:AS,ValueRange:dn,DateTimeFormatter:Nn,DateTimeFormatterBuilder:fa,DecimalStyle:gz,ResolverStyle:ln,SignStyle:Mo,TextStyle:Bo},Iyt=Lyt(Rke);Rke.use=Iyt;const Nyt=/^(?<date>\d{4}-\d{2}-\d{2})T(?<time>\d{2}:\d{2}:\d{2})(?:\.(?<frac>\d+))?(?<zone>Z|[+\-]\d{2}:\d{2})$/,Fyt=/^\d+us$/i,Byt=/^\d+ms$/i,jyt=/^\d+(?:\.\d+)?s$/i,Vyt="9007199254740991";function Hyt(t,e){return t=t.replace(/^0+/,"")||"0",e=e.replace(/^0+/,"")||"0",t.length!==e.length?t.length<e.length?-1:1:t===e?0:t<e?-1:1}function zue(t){return Hyt(t,Vyt)<=0}function Uyt(t){return t.length<=3?"0":t.slice(0,t.length-3)}function fY(t){if(t==null)throw new Error("input is null");const e=t.trim();if(Fyt.test(e)){const n=e.slice(0,-2),r=Uyt(n);if(!zue(r))throw new Error(`Microseconds timestamp out of safe range: ${t}`);return Number(r)}if(Byt.test(e)){const n=e.slice(0,-2);if(!zue(n))throw new Error(`Millisecond timestamp out of safe range: ${t}`);return Number(n)}if(jyt.test(e)){const n=Number(e.slice(0,-1));if(!Number.isFinite(n))throw new Error(`Invalid seconds timestamp: ${t}`);const r=Math.floor(n*1e3);if(!Number.isSafeInteger(r))throw new Error(`Seconds timestamp out of safe range: ${t}`);return r}const i=e.match(Nyt);if(i)try{const n=i.groups.zone;return n==="Z"||n==="z"?Ra.parse(e).toEpochMilli():xg.parse(e).toInstant().toEpochMilli()}catch{throw new Error(`Invalid RFC3339/ISO-8601 timestamp: ${t}`)}throw new Error(`Unsupported timestamp format: ${t}`)}const zyt=t=>`${t.toUTCString().replace(" GMT","")}.${t.getMilliseconds().toString().padStart(3,"0")}`;function $yt(t){if(t===void 0)return 0;const e=t.trim().toLowerCase().match(/^(-?\d+(?:\.\d+)?)(us|ms|s)$/);if(!e)throw new Error(`Unknown or malformed duration: ${t}`);const[,i,n]=e,r=Number(i);if(!Number.isFinite(r))throw new Error(`Invalid number: ${t}`);switch(n){case"us":return r/1e3;case"ms":return r;case"s":return r*1e3}}const Wyt=new Bvt;var Os=(t=>(t.FILE_TYPE_UNKNOWN="FILE_TYPE_UNKNOWN",t.FILE_TYPE_FOLDER="FILE_TYPE_FOLDER",t.FILE_TYPE_VIDEO="FILE_TYPE_VIDEO",t.FILE_TYPE_AUDIO="FILE_TYPE_AUDIO",t.FILE_TYPE_IMAGE="FILE_TYPE_IMAGE",t.FILE_TYPE_RECORDING="FILE_TYPE_RECORDING",t.FILE_TYPE_RECORDING_SESSION="FILE_TYPE_RECORDING_SESSION",t.FILE_TYPE_RECORDING_MAPPING="FILE_TYPE_RECORDING_MAPPING",t.FILE_TYPE_PLATFORM="FILE_TYPE_PLATFORM",t.FILE_TYPE_INSTANCE="FILE_TYPE_INSTANCE",t.FILE_TYPE_SIGNAL_DATABASE="FILE_TYPE_SIGNAL_DATABASE",t))(Os||{}),qU=(t=>(t.PLAYBACK_PLAYING="PLAYBACK_PLAYING",t.PLAYBACK_PAUSED="PLAYBACK_PAUSED",t.PLAYBACK_CLOSED="PLAYBACK_CLOSED",t))(qU||{});/*! js-yaml 4.1.1 https://github.com/nodeca/js-yaml @license MIT */function Mke(t){return typeof t>"u"||t===null}function Gyt(t){return typeof t=="object"&&t!==null}function Yyt(t){return Array.isArray(t)?t:Mke(t)?[]:[t]}function qyt(t,e){var i,n,r,o;if(e)for(o=Object.keys(e),i=0,n=o.length;i<n;i+=1)r=o[i],t[r]=e[r];return t}function Xyt(t,e){var i="",n;for(n=0;n<e;n+=1)i+=t;return i}function Kyt(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var Zyt=Mke,Jyt=Gyt,Qyt=Yyt,emt=Xyt,tmt=Kyt,rmt=qyt,kf={isNothing:Zyt,isObject:Jyt,toArray:Qyt,repeat:emt,isNegativeZero:tmt,extend:rmt};function Lke(t,e){var i="",n=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(i+='in "'+t.mark.name+'" '),i+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(i+=`

`+t.mark.snippet),n+" "+i):n}function D3(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=Lke(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}D3.prototype=Object.create(Error.prototype);D3.prototype.constructor=D3;D3.prototype.toString=function(e){return this.name+": "+Lke(this,e)};var oS=D3;function hY(t,e,i,n,r){var o="",a="",s=Math.floor(r/2)-1;return n-e>s&&(o=" ... ",e=n-s+o.length),i-n>s&&(a=" ...",i=n+s-a.length),{str:o+t.slice(e,i).replace(/\t/g,"→")+a,pos:n-e+o.length}}function pY(t,e){return kf.repeat(" ",e-t.length)+t}function imt(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),typeof e.indent!="number"&&(e.indent=1),typeof e.linesBefore!="number"&&(e.linesBefore=3),typeof e.linesAfter!="number"&&(e.linesAfter=2);for(var i=/\r?\n|\r|\0/g,n=[0],r=[],o,a=-1;o=i.exec(t.buffer);)r.push(o.index),n.push(o.index+o[0].length),t.position<=o.index&&a<0&&(a=n.length-2);a<0&&(a=n.length-1);var s="",l,u,c=Math.min(t.line+e.linesAfter,r.length).toString().length,d=e.maxLength-(e.indent+c+3);for(l=1;l<=e.linesBefore&&!(a-l<0);l++)u=hY(t.buffer,n[a-l],r[a-l],t.position-(n[a]-n[a-l]),d),s=kf.repeat(" ",e.indent)+pY((t.line-l+1).toString(),c)+" | "+u.str+`
`+s;for(u=hY(t.buffer,n[a],r[a],t.position,d),s+=kf.repeat(" ",e.indent)+pY((t.line+1).toString(),c)+" | "+u.str+`
`,s+=kf.repeat("-",e.indent+c+3+u.pos)+`^
`,l=1;l<=e.linesAfter&&!(a+l>=r.length);l++)u=hY(t.buffer,n[a+l],r[a+l],t.position-(n[a]-n[a+l]),d),s+=kf.repeat(" ",e.indent)+pY((t.line+l+1).toString(),c)+" | "+u.str+`
`;return s.replace(/\n$/,"")}var nmt=imt,omt=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],amt=["scalar","sequence","mapping"];function smt(t){var e={};return t!==null&&Object.keys(t).forEach(function(i){t[i].forEach(function(n){e[String(n)]=i})}),e}function lmt(t,e){if(e=e||{},Object.keys(e).forEach(function(i){if(omt.indexOf(i)===-1)throw new oS('Unknown option "'+i+'" is met in definition of "'+t+'" YAML type.')}),this.options=e,this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(i){return i},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.representName=e.representName||null,this.defaultStyle=e.defaultStyle||null,this.multi=e.multi||!1,this.styleAliases=smt(e.styleAliases||null),amt.indexOf(this.kind)===-1)throw new oS('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var Hd=lmt;function $ue(t,e){var i=[];return t[e].forEach(function(n){var r=i.length;i.forEach(function(o,a){o.tag===n.tag&&o.kind===n.kind&&o.multi===n.multi&&(r=a)}),i[r]=n}),i}function umt(){var t={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},e,i;function n(r){r.multi?(t.multi[r.kind].push(r),t.multi.fallback.push(r)):t[r.kind][r.tag]=t.fallback[r.tag]=r}for(e=0,i=arguments.length;e<i;e+=1)arguments[e].forEach(n);return t}function LZ(t){return this.extend(t)}LZ.prototype.extend=function(e){var i=[],n=[];if(e instanceof Hd)n.push(e);else if(Array.isArray(e))n=n.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(i=i.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit));else throw new oS("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");i.forEach(function(o){if(!(o instanceof Hd))throw new oS("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(o.loadKind&&o.loadKind!=="scalar")throw new oS("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(o.multi)throw new oS("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),n.forEach(function(o){if(!(o instanceof Hd))throw new oS("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var r=Object.create(LZ.prototype);return r.implicit=(this.implicit||[]).concat(i),r.explicit=(this.explicit||[]).concat(n),r.compiledImplicit=$ue(r,"implicit"),r.compiledExplicit=$ue(r,"explicit"),r.compiledTypeMap=umt(r.compiledImplicit,r.compiledExplicit),r};var cmt=LZ,dmt=new Hd("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),fmt=new Hd("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),hmt=new Hd("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),pmt=new cmt({explicit:[dmt,fmt,hmt]});function gmt(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function vmt(){return null}function ymt(t){return t===null}var mmt=new Hd("tag:yaml.org,2002:null",{kind:"scalar",resolve:gmt,construct:vmt,predicate:ymt,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function bmt(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function Smt(t){return t==="true"||t==="True"||t==="TRUE"}function _mt(t){return Object.prototype.toString.call(t)==="[object Boolean]"}var Pmt=new Hd("tag:yaml.org,2002:bool",{kind:"scalar",resolve:bmt,construct:Smt,predicate:_mt,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"});function Cmt(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function Tmt(t){return 48<=t&&t<=55}function xmt(t){return 48<=t&&t<=57}function Emt(t){if(t===null)return!1;var e=t.length,i=0,n=!1,r;if(!e)return!1;if(r=t[i],(r==="-"||r==="+")&&(r=t[++i]),r==="0"){if(i+1===e)return!0;if(r=t[++i],r==="b"){for(i++;i<e;i++)if(r=t[i],r!=="_"){if(r!=="0"&&r!=="1")return!1;n=!0}return n&&r!=="_"}if(r==="x"){for(i++;i<e;i++)if(r=t[i],r!=="_"){if(!Cmt(t.charCodeAt(i)))return!1;n=!0}return n&&r!=="_"}if(r==="o"){for(i++;i<e;i++)if(r=t[i],r!=="_"){if(!Tmt(t.charCodeAt(i)))return!1;n=!0}return n&&r!=="_"}}if(r==="_")return!1;for(;i<e;i++)if(r=t[i],r!=="_"){if(!xmt(t.charCodeAt(i)))return!1;n=!0}return!(!n||r==="_")}function wmt(t){var e=t,i=1,n;if(e.indexOf("_")!==-1&&(e=e.replace(/_/g,"")),n=e[0],(n==="-"||n==="+")&&(n==="-"&&(i=-1),e=e.slice(1),n=e[0]),e==="0")return 0;if(n==="0"){if(e[1]==="b")return i*parseInt(e.slice(2),2);if(e[1]==="x")return i*parseInt(e.slice(2),16);if(e[1]==="o")return i*parseInt(e.slice(2),8)}return i*parseInt(e,10)}function Amt(t){return Object.prototype.toString.call(t)==="[object Number]"&&t%1===0&&!kf.isNegativeZero(t)}var Omt=new Hd("tag:yaml.org,2002:int",{kind:"scalar",resolve:Emt,construct:wmt,predicate:Amt,represent:{binary:function(t){return t>=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Dmt=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Rmt(t){return!(t===null||!Dmt.test(t)||t[t.length-1]==="_")}function Mmt(t){var e,i;return e=t.replace(/_/g,"").toLowerCase(),i=e[0]==="-"?-1:1,"+-".indexOf(e[0])>=0&&(e=e.slice(1)),e===".inf"?i===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:i*parseFloat(e,10)}var Lmt=/^[-+]?[0-9]+e/;function kmt(t,e){var i;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(kf.isNegativeZero(t))return"-0.0";return i=t.toString(10),Lmt.test(i)?i.replace("e",".e"):i}function Imt(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||kf.isNegativeZero(t))}var Nmt=new Hd("tag:yaml.org,2002:float",{kind:"scalar",resolve:Rmt,construct:Mmt,predicate:Imt,represent:kmt,defaultStyle:"lowercase"}),Fmt=pmt.extend({implicit:[mmt,Pmt,Omt,Nmt]}),Bmt=Fmt,kke=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Ike=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");function jmt(t){return t===null?!1:kke.exec(t)!==null||Ike.exec(t)!==null}function Vmt(t){var e,i,n,r,o,a,s,l=0,u=null,c,d,f;if(e=kke.exec(t),e===null&&(e=Ike.exec(t)),e===null)throw new Error("Date resolve error");if(i=+e[1],n=+e[2]-1,r=+e[3],!e[4])return new Date(Date.UTC(i,n,r));if(o=+e[4],a=+e[5],s=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(c=+e[10],d=+(e[11]||0),u=(c*60+d)*6e4,e[9]==="-"&&(u=-u)),f=new Date(Date.UTC(i,n,r,o,a,s,l)),u&&f.setTime(f.getTime()-u),f}function Hmt(t){return t.toISOString()}var Umt=new Hd("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:jmt,construct:Vmt,instanceOf:Date,represent:Hmt});function zmt(t){return t==="<<"||t===null}var $mt=new Hd("tag:yaml.org,2002:merge",{kind:"scalar",resolve:zmt}),ute=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
\r`;function Wmt(t){if(t===null)return!1;var e,i,n=0,r=t.length,o=ute;for(i=0;i<r;i++)if(e=o.indexOf(t.charAt(i)),!(e>64)){if(e<0)return!1;n+=6}return n%8===0}function Gmt(t){var e,i,n=t.replace(/[\r\n=]/g,""),r=n.length,o=ute,a=0,s=[];for(e=0;e<r;e++)e%4===0&&e&&(s.push(a>>16&255),s.push(a>>8&255),s.push(a&255)),a=a<<6|o.indexOf(n.charAt(e));return i=r%4*6,i===0?(s.push(a>>16&255),s.push(a>>8&255),s.push(a&255)):i===18?(s.push(a>>10&255),s.push(a>>2&255)):i===12&&s.push(a>>4&255),new Uint8Array(s)}function Ymt(t){var e="",i=0,n,r,o=t.length,a=ute;for(n=0;n<o;n++)n%3===0&&n&&(e+=a[i>>18&63],e+=a[i>>12&63],e+=a[i>>6&63],e+=a[i&63]),i=(i<<8)+t[n];return r=o%3,r===0?(e+=a[i>>18&63],e+=a[i>>12&63],e+=a[i>>6&63],e+=a[i&63]):r===2?(e+=a[i>>10&63],e+=a[i>>4&63],e+=a[i<<2&63],e+=a[64]):r===1&&(e+=a[i>>2&63],e+=a[i<<4&63],e+=a[64],e+=a[64]),e}function qmt(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var Xmt=new Hd("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Wmt,construct:Gmt,predicate:qmt,represent:Ymt}),Kmt=Object.prototype.hasOwnProperty,Zmt=Object.prototype.toString;function Jmt(t){if(t===null)return!0;var e=[],i,n,r,o,a,s=t;for(i=0,n=s.length;i<n;i+=1){if(r=s[i],a=!1,Zmt.call(r)!=="[object Object]")return!1;for(o in r)if(Kmt.call(r,o))if(!a)a=!0;else return!1;if(!a)return!1;if(e.indexOf(o)===-1)e.push(o);else return!1}return!0}function Qmt(t){return t!==null?t:[]}var e0t=new Hd("tag:yaml.org,2002:omap",{kind:"sequence",resolve:Jmt,construct:Qmt}),t0t=Object.prototype.toString;function r0t(t){if(t===null)return!0;var e,i,n,r,o,a=t;for(o=new Array(a.length),e=0,i=a.length;e<i;e+=1){if(n=a[e],t0t.call(n)!=="[object Object]"||(r=Object.keys(n),r.length!==1))return!1;o[e]=[r[0],n[r[0]]]}return!0}function i0t(t){if(t===null)return[];var e,i,n,r,o,a=t;for(o=new Array(a.length),e=0,i=a.length;e<i;e+=1)n=a[e],r=Object.keys(n),o[e]=[r[0],n[r[0]]];return o}var n0t=new Hd("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:r0t,construct:i0t}),o0t=Object.prototype.hasOwnProperty;function a0t(t){if(t===null)return!0;var e,i=t;for(e in i)if(o0t.call(i,e)&&i[e]!==null)return!1;return!0}function s0t(t){return t!==null?t:{}}var l0t=new Hd("tag:yaml.org,2002:set",{kind:"mapping",resolve:a0t,construct:s0t}),u0t=Bmt.extend({implicit:[Umt,$mt],explicit:[Xmt,e0t,n0t,l0t]}),EP=Object.prototype.hasOwnProperty,yz=1,Nke=2,Fke=3,mz=4,gY=1,c0t=2,Wue=3,d0t=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,f0t=/[\x85\u2028\u2029]/,h0t=/[,\[\]\{\}]/,Bke=/^(?:!|!!|![a-z\-]+!)$/i,jke=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function Gue(t){return Object.prototype.toString.call(t)}function am(t){return t===10||t===13}function cD(t){return t===9||t===32}function Ah(t){return t===9||t===32||t===10||t===13}function EL(t){return t===44||t===91||t===93||t===123||t===125}function p0t(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function g0t(t){return t===120?2:t===117?4:t===85?8:0}function v0t(t){return 48<=t&&t<=57?t-48:-1}function Yue(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?"	":t===110?`
`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"\x1B":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"":t===95?" ":t===76?"\u2028":t===80?"\u2029":""}function y0t(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}function Vke(t,e,i){e==="__proto__"?Object.defineProperty(t,e,{configurable:!0,enumerable:!0,writable:!0,value:i}):t[e]=i}var Hke=new Array(256),Uke=new Array(256);for(var rL=0;rL<256;rL++)Hke[rL]=Yue(rL)?1:0,Uke[rL]=Yue(rL);function m0t(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||u0t,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function zke(t,e){var i={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return i.snippet=nmt(i),new oS(e,i)}function ki(t,e){throw zke(t,e)}function bz(t,e){t.onWarning&&t.onWarning.call(null,zke(t,e))}var que={YAML:function(e,i,n){var r,o,a;e.version!==null&&ki(e,"duplication of %YAML directive"),n.length!==1&&ki(e,"YAML directive accepts exactly one argument"),r=/^([0-9]+)\.([0-9]+)$/.exec(n[0]),r===null&&ki(e,"ill-formed argument of the YAML directive"),o=parseInt(r[1],10),a=parseInt(r[2],10),o!==1&&ki(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=a<2,a!==1&&a!==2&&bz(e,"unsupported YAML version of the document")},TAG:function(e,i,n){var r,o;n.length!==2&&ki(e,"TAG directive accepts exactly two arguments"),r=n[0],o=n[1],Bke.test(r)||ki(e,"ill-formed tag handle (first argument) of the TAG directive"),EP.call(e.tagMap,r)&&ki(e,'there is a previously declared suffix for "'+r+'" tag handle'),jke.test(o)||ki(e,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch{ki(e,"tag prefix is malformed: "+o)}e.tagMap[r]=o}};function yP(t,e,i,n){var r,o,a,s;if(e<i){if(s=t.input.slice(e,i),n)for(r=0,o=s.length;r<o;r+=1)a=s.charCodeAt(r),a===9||32<=a&&a<=1114111||ki(t,"expected valid JSON character");else d0t.test(s)&&ki(t,"the stream contains non-printable characters");t.result+=s}}function Xue(t,e,i,n){var r,o,a,s;for(kf.isObject(i)||ki(t,"cannot merge mappings; the provided source object is unacceptable"),r=Object.keys(i),a=0,s=r.length;a<s;a+=1)o=r[a],EP.call(e,o)||(Vke(e,o,i[o]),n[o]=!0)}function wL(t,e,i,n,r,o,a,s,l){var u,c;if(Array.isArray(r))for(r=Array.prototype.slice.call(r),u=0,c=r.length;u<c;u+=1)Array.isArray(r[u])&&ki(t,"nested arrays are not supported inside keys"),typeof r=="object"&&Gue(r[u])==="[object Object]"&&(r[u]="[object Object]");if(typeof r=="object"&&Gue(r)==="[object Object]"&&(r="[object Object]"),r=String(r),e===null&&(e={}),n==="tag:yaml.org,2002:merge")if(Array.isArray(o))for(u=0,c=o.length;u<c;u+=1)Xue(t,e,o[u],i);else Xue(t,e,o,i);else!t.json&&!EP.call(i,r)&&EP.call(e,r)&&(t.line=a||t.line,t.lineStart=s||t.lineStart,t.position=l||t.position,ki(t,"duplicated mapping key")),Vke(e,r,o),delete i[r];return e}function cte(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):ki(t,"a line break is expected"),t.line+=1,t.lineStart=t.position,t.firstTabInLine=-1}function Lu(t,e,i){for(var n=0,r=t.input.charCodeAt(t.position);r!==0;){for(;cD(r);)r===9&&t.firstTabInLine===-1&&(t.firstTabInLine=t.position),r=t.input.charCodeAt(++t.position);if(e&&r===35)do r=t.input.charCodeAt(++t.position);while(r!==10&&r!==13&&r!==0);if(am(r))for(cte(t),r=t.input.charCodeAt(t.position),n++,t.lineIndent=0;r===32;)t.lineIndent++,r=t.input.charCodeAt(++t.position);else break}return i!==-1&&n!==0&&t.lineIndent<i&&bz(t,"deficient indentation"),n}function N6(t){var e=t.position,i;return i=t.input.charCodeAt(e),!!((i===45||i===46)&&i===t.input.charCodeAt(e+1)&&i===t.input.charCodeAt(e+2)&&(e+=3,i=t.input.charCodeAt(e),i===0||Ah(i)))}function dte(t,e){e===1?t.result+=" ":e>1&&(t.result+=kf.repeat(`
`,e-1))}function b0t(t,e,i){var n,r,o,a,s,l,u,c,d=t.kind,f=t.result,h;if(h=t.input.charCodeAt(t.position),Ah(h)||EL(h)||h===35||h===38||h===42||h===33||h===124||h===62||h===39||h===34||h===37||h===64||h===96||(h===63||h===45)&&(r=t.input.charCodeAt(t.position+1),Ah(r)||i&&EL(r)))return!1;for(t.kind="scalar",t.result="",o=a=t.position,s=!1;h!==0;){if(h===58){if(r=t.input.charCodeAt(t.position+1),Ah(r)||i&&EL(r))break}else if(h===35){if(n=t.input.charCodeAt(t.position-1),Ah(n))break}else{if(t.position===t.lineStart&&N6(t)||i&&EL(h))break;if(am(h))if(l=t.line,u=t.lineStart,c=t.lineIndent,Lu(t,!1,-1),t.lineIndent>=e){s=!0,h=t.input.charCodeAt(t.position);continue}else{t.position=a,t.line=l,t.lineStart=u,t.lineIndent=c;break}}s&&(yP(t,o,a,!1),dte(t,t.line-l),o=a=t.position,s=!1),cD(h)||(a=t.position+1),h=t.input.charCodeAt(++t.position)}return yP(t,o,a,!1),t.result?!0:(t.kind=d,t.result=f,!1)}function S0t(t,e){var i,n,r;if(i=t.input.charCodeAt(t.position),i!==39)return!1;for(t.kind="scalar",t.result="",t.position++,n=r=t.position;(i=t.input.charCodeAt(t.position))!==0;)if(i===39)if(yP(t,n,t.position,!0),i=t.input.charCodeAt(++t.position),i===39)n=t.position,t.position++,r=t.position;else return!0;else am(i)?(yP(t,n,r,!0),dte(t,Lu(t,!1,e)),n=r=t.position):t.position===t.lineStart&&N6(t)?ki(t,"unexpected end of the document within a single quoted scalar"):(t.position++,r=t.position);ki(t,"unexpected end of the stream within a single quoted scalar")}function _0t(t,e){var i,n,r,o,a,s;if(s=t.input.charCodeAt(t.position),s!==34)return!1;for(t.kind="scalar",t.result="",t.position++,i=n=t.position;(s=t.input.charCodeAt(t.position))!==0;){if(s===34)return yP(t,i,t.position,!0),t.position++,!0;if(s===92){if(yP(t,i,t.position,!0),s=t.input.charCodeAt(++t.position),am(s))Lu(t,!1,e);else if(s<256&&Hke[s])t.result+=Uke[s],t.position++;else if((a=g0t(s))>0){for(r=a,o=0;r>0;r--)s=t.input.charCodeAt(++t.position),(a=p0t(s))>=0?o=(o<<4)+a:ki(t,"expected hexadecimal character");t.result+=y0t(o),t.position++}else ki(t,"unknown escape sequence");i=n=t.position}else am(s)?(yP(t,i,n,!0),dte(t,Lu(t,!1,e)),i=n=t.position):t.position===t.lineStart&&N6(t)?ki(t,"unexpected end of the document within a double quoted scalar"):(t.position++,n=t.position)}ki(t,"unexpected end of the stream within a double quoted scalar")}function P0t(t,e){var i=!0,n,r,o,a=t.tag,s,l=t.anchor,u,c,d,f,h,p=Object.create(null),g,v,y,m;if(m=t.input.charCodeAt(t.position),m===91)c=93,h=!1,s=[];else if(m===123)c=125,h=!0,s={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),m=t.input.charCodeAt(++t.position);m!==0;){if(Lu(t,!0,e),m=t.input.charCodeAt(t.position),m===c)return t.position++,t.tag=a,t.anchor=l,t.kind=h?"mapping":"sequence",t.result=s,!0;i?m===44&&ki(t,"expected the node content, but found ','"):ki(t,"missed comma between flow collection entries"),v=g=y=null,d=f=!1,m===63&&(u=t.input.charCodeAt(t.position+1),Ah(u)&&(d=f=!0,t.position++,Lu(t,!0,e))),n=t.line,r=t.lineStart,o=t.position,$k(t,e,yz,!1,!0),v=t.tag,g=t.result,Lu(t,!0,e),m=t.input.charCodeAt(t.position),(f||t.line===n)&&m===58&&(d=!0,m=t.input.charCodeAt(++t.position),Lu(t,!0,e),$k(t,e,yz,!1,!0),y=t.result),h?wL(t,s,p,v,g,y,n,r,o):d?s.push(wL(t,null,p,v,g,y,n,r,o)):s.push(g),Lu(t,!0,e),m=t.input.charCodeAt(t.position),m===44?(i=!0,m=t.input.charCodeAt(++t.position)):i=!1}ki(t,"unexpected end of the stream within a flow collection")}function C0t(t,e){var i,n,r=gY,o=!1,a=!1,s=e,l=0,u=!1,c,d;if(d=t.input.charCodeAt(t.position),d===124)n=!1;else if(d===62)n=!0;else return!1;for(t.kind="scalar",t.result="";d!==0;)if(d=t.input.charCodeAt(++t.position),d===43||d===45)gY===r?r=d===43?Wue:c0t:ki(t,"repeat of a chomping mode identifier");else if((c=v0t(d))>=0)c===0?ki(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):a?ki(t,"repeat of an indentation width identifier"):(s=e+c-1,a=!0);else break;if(cD(d)){do d=t.input.charCodeAt(++t.position);while(cD(d));if(d===35)do d=t.input.charCodeAt(++t.position);while(!am(d)&&d!==0)}for(;d!==0;){for(cte(t),t.lineIndent=0,d=t.input.charCodeAt(t.position);(!a||t.lineIndent<s)&&d===32;)t.lineIndent++,d=t.input.charCodeAt(++t.position);if(!a&&t.lineIndent>s&&(s=t.lineIndent),am(d)){l++;continue}if(t.lineIndent<s){r===Wue?t.result+=kf.repeat(`
`,o?1+l:l):r===gY&&o&&(t.result+=`
`);break}for(n?cD(d)?(u=!0,t.result+=kf.repeat(`
`,o?1+l:l)):u?(u=!1,t.result+=kf.repeat(`
`,l+1)):l===0?o&&(t.result+=" "):t.result+=kf.repeat(`
`,l):t.result+=kf.repeat(`
`,o?1+l:l),o=!0,a=!0,l=0,i=t.position;!am(d)&&d!==0;)d=t.input.charCodeAt(++t.position);yP(t,i,t.position,!1)}return!0}function Kue(t,e){var i,n=t.tag,r=t.anchor,o=[],a,s=!1,l;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=o),l=t.input.charCodeAt(t.position);l!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ki(t,"tab characters must not be used in indentation")),!(l!==45||(a=t.input.charCodeAt(t.position+1),!Ah(a))));){if(s=!0,t.position++,Lu(t,!0,-1)&&t.lineIndent<=e){o.push(null),l=t.input.charCodeAt(t.position);continue}if(i=t.line,$k(t,e,Fke,!1,!0),o.push(t.result),Lu(t,!0,-1),l=t.input.charCodeAt(t.position),(t.line===i||t.lineIndent>e)&&l!==0)ki(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return s?(t.tag=n,t.anchor=r,t.kind="sequence",t.result=o,!0):!1}function T0t(t,e,i){var n,r,o,a,s,l,u=t.tag,c=t.anchor,d={},f=Object.create(null),h=null,p=null,g=null,v=!1,y=!1,m;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=d),m=t.input.charCodeAt(t.position);m!==0;){if(!v&&t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,ki(t,"tab characters must not be used in indentation")),n=t.input.charCodeAt(t.position+1),o=t.line,(m===63||m===58)&&Ah(n))m===63?(v&&(wL(t,d,f,h,p,null,a,s,l),h=p=g=null),y=!0,v=!0,r=!0):v?(v=!1,r=!0):ki(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,m=n;else{if(a=t.line,s=t.lineStart,l=t.position,!$k(t,i,Nke,!1,!0))break;if(t.line===o){for(m=t.input.charCodeAt(t.position);cD(m);)m=t.input.charCodeAt(++t.position);if(m===58)m=t.input.charCodeAt(++t.position),Ah(m)||ki(t,"a whitespace character is expected after the key-value separator within a block mapping"),v&&(wL(t,d,f,h,p,null,a,s,l),h=p=g=null),y=!0,v=!1,r=!1,h=t.tag,p=t.result;else if(y)ki(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=u,t.anchor=c,!0}else if(y)ki(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=u,t.anchor=c,!0}if((t.line===o||t.lineIndent>e)&&(v&&(a=t.line,s=t.lineStart,l=t.position),$k(t,e,mz,!0,r)&&(v?p=t.result:g=t.result),v||(wL(t,d,f,h,p,g,a,s,l),h=p=g=null),Lu(t,!0,-1),m=t.input.charCodeAt(t.position)),(t.line===o||t.lineIndent>e)&&m!==0)ki(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return v&&wL(t,d,f,h,p,null,a,s,l),y&&(t.tag=u,t.anchor=c,t.kind="mapping",t.result=d),y}function x0t(t){var e,i=!1,n=!1,r,o,a;if(a=t.input.charCodeAt(t.position),a!==33)return!1;if(t.tag!==null&&ki(t,"duplication of a tag property"),a=t.input.charCodeAt(++t.position),a===60?(i=!0,a=t.input.charCodeAt(++t.position)):a===33?(n=!0,r="!!",a=t.input.charCodeAt(++t.position)):r="!",e=t.position,i){do a=t.input.charCodeAt(++t.position);while(a!==0&&a!==62);t.position<t.length?(o=t.input.slice(e,t.position),a=t.input.charCodeAt(++t.position)):ki(t,"unexpected end of the stream within a verbatim tag")}else{for(;a!==0&&!Ah(a);)a===33&&(n?ki(t,"tag suffix cannot contain exclamation marks"):(r=t.input.slice(e-1,t.position+1),Bke.test(r)||ki(t,"named tag handle cannot contain such characters"),n=!0,e=t.position+1)),a=t.input.charCodeAt(++t.position);o=t.input.slice(e,t.position),h0t.test(o)&&ki(t,"tag suffix cannot contain flow indicator characters")}o&&!jke.test(o)&&ki(t,"tag name cannot contain such characters: "+o);try{o=decodeURIComponent(o)}catch{ki(t,"tag name is malformed: "+o)}return i?t.tag=o:EP.call(t.tagMap,r)?t.tag=t.tagMap[r]+o:r==="!"?t.tag="!"+o:r==="!!"?t.tag="tag:yaml.org,2002:"+o:ki(t,'undeclared tag handle "'+r+'"'),!0}function E0t(t){var e,i;if(i=t.input.charCodeAt(t.position),i!==38)return!1;for(t.anchor!==null&&ki(t,"duplication of an anchor property"),i=t.input.charCodeAt(++t.position),e=t.position;i!==0&&!Ah(i)&&!EL(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&ki(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function w0t(t){var e,i,n;if(n=t.input.charCodeAt(t.position),n!==42)return!1;for(n=t.input.charCodeAt(++t.position),e=t.position;n!==0&&!Ah(n)&&!EL(n);)n=t.input.charCodeAt(++t.position);return t.position===e&&ki(t,"name of an alias node must contain at least one character"),i=t.input.slice(e,t.position),EP.call(t.anchorMap,i)||ki(t,'unidentified alias "'+i+'"'),t.result=t.anchorMap[i],Lu(t,!0,-1),!0}function $k(t,e,i,n,r){var o,a,s,l=1,u=!1,c=!1,d,f,h,p,g,v;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,o=a=s=mz===i||Fke===i,n&&Lu(t,!0,-1)&&(u=!0,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)),l===1)for(;x0t(t)||E0t(t);)Lu(t,!0,-1)?(u=!0,s=o,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)):s=!1;if(s&&(s=u||r),(l===1||mz===i)&&(yz===i||Nke===i?g=e:g=e+1,v=t.position-t.lineStart,l===1?s&&(Kue(t,v)||T0t(t,v,g))||P0t(t,g)?c=!0:(a&&C0t(t,g)||S0t(t,g)||_0t(t,g)?c=!0:w0t(t)?(c=!0,(t.tag!==null||t.anchor!==null)&&ki(t,"alias node should not have any properties")):b0t(t,g,yz===i)&&(c=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):l===0&&(c=s&&Kue(t,v))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&ki(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),d=0,f=t.implicitTypes.length;d<f;d+=1)if(p=t.implicitTypes[d],p.resolve(t.result)){t.result=p.construct(t.result),t.tag=p.tag,t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);break}}else if(t.tag!=="!"){if(EP.call(t.typeMap[t.kind||"fallback"],t.tag))p=t.typeMap[t.kind||"fallback"][t.tag];else for(p=null,h=t.typeMap.multi[t.kind||"fallback"],d=0,f=h.length;d<f;d+=1)if(t.tag.slice(0,h[d].tag.length)===h[d].tag){p=h[d];break}p||ki(t,"unknown tag !<"+t.tag+">"),t.result!==null&&p.kind!==t.kind&&ki(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+p.kind+'", not "'+t.kind+'"'),p.resolve(t.result,t.tag)?(t.result=p.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):ki(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||c}function A0t(t){var e=t.position,i,n,r,o=!1,a;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(a=t.input.charCodeAt(t.position))!==0&&(Lu(t,!0,-1),a=t.input.charCodeAt(t.position),!(t.lineIndent>0||a!==37));){for(o=!0,a=t.input.charCodeAt(++t.position),i=t.position;a!==0&&!Ah(a);)a=t.input.charCodeAt(++t.position);for(n=t.input.slice(i,t.position),r=[],n.length<1&&ki(t,"directive name must not be less than one character in length");a!==0;){for(;cD(a);)a=t.input.charCodeAt(++t.position);if(a===35){do a=t.input.charCodeAt(++t.position);while(a!==0&&!am(a));break}if(am(a))break;for(i=t.position;a!==0&&!Ah(a);)a=t.input.charCodeAt(++t.position);r.push(t.input.slice(i,t.position))}a!==0&&cte(t),EP.call(que,n)?que[n](t,n,r):bz(t,'unknown document directive "'+n+'"')}if(Lu(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,Lu(t,!0,-1)):o&&ki(t,"directives end mark is expected"),$k(t,t.lineIndent-1,mz,!1,!0),Lu(t,!0,-1),t.checkLineBreaks&&f0t.test(t.input.slice(e,t.position))&&bz(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&N6(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,Lu(t,!0,-1));return}if(t.position<t.length-1)ki(t,"end of the stream or a document separator is expected");else return}function O0t(t,e){t=String(t),e=e||{},t.length!==0&&(t.charCodeAt(t.length-1)!==10&&t.charCodeAt(t.length-1)!==13&&(t+=`
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var i=new m0t(t,e),n=t.indexOf("\0");for(n!==-1&&(i.position=n,ki(i,"null byte is not allowed in input")),i.input+="\0";i.input.charCodeAt(i.position)===32;)i.lineIndent+=1,i.position+=1;for(;i.position<i.length-1;)A0t(i);return i.documents}function D0t(t,e){var i=O0t(t,e);if(i.length!==0){if(i.length===1)return i[0];throw new oS("expected a single document in the stream, but found more")}}var R0t=D0t,M0t={load:R0t},L0t=M0t.load;class $ke{constructor(e){this.config=e}get fileDownloadBaseUrl(){return this.config.httpUrl}async postJSON(e,i){const n=i?JSON.stringify(i):"{}",r=await fetch(this.config.grpcUrl+e,{method:"POST",headers:{"Content-Type":"application/json"},body:n});if(!r.ok)throw new Error(`HTTP ${r.status} ${r.statusText}`);return r.json()}async fetchYaml(e,i){const n=new AbortController,r=i!=null&&i.timeoutMs?setTimeout(()=>n.abort(),i.timeoutMs):void 0;try{const o=await fetch(`${this.config.httpUrl}/api/broker/files?path=${e}`,{signal:(i==null?void 0:i.signal)??n.signal,redirect:"follow",cache:"no-store"});if(!o.ok)throw new Error(`HTTP ${o.status} ${o.statusText}`);const a=await o.text();return console.log("as YAML",a),L0t(a)}finally{r&&clearTimeout(r)}}async*postJSONStream(e,i,n){var u,c;const r=await fetch(this.config.grpcUrl+e,{method:"POST",headers:{"content-type":"application/json"},body:i?JSON.stringify(i):"{}",signal:n});if(!r.body){yield await r.json();return}const o=r.body.getReader(),a=new TextDecoder;let s="";const l=()=>{try{o.cancel("aborted")}catch{}};n==null||n.addEventListener("abort",l,{once:!0});try{for(;;){const{done:d,value:f}=await o.read();if(d)break;s+=a.decode(f,{stream:!0});const h=s.split(/\r?\n/);s=h.pop()??"";for(const p of h){const g=p.trim();if(g)try{yield JSON.parse(g)}catch{}}}if(s.trim())try{yield JSON.parse(s.trim())}catch{}}catch(d){if((d==null?void 0:d.name)!=="AbortError")throw d}finally{n==null||n.removeEventListener("abort",l);try{await o.cancel("done")}catch{}try{o.releaseLock()}catch{}try{await((c=(u=r.body)==null?void 0:u.cancel)==null?void 0:c.call(u,"done"))}catch{}}}}function k0t(t,e){const i=a=>a.replace(/\\/g,"/").split(/[?#]/)[0];let n=i(t);const r=i(e);return n.startsWith("/")||(n="/"+n),new URL(r,"http://x"+n).pathname}class I0t{constructor(e,i,n,r){this.name=e,this.path=i,this.type=n,this.downloadBaseUrl=r,this.isDirectory=!1}url(){return`${this.downloadBaseUrl}/api/broker/files?path=${this.path}`}}class vY{constructor(e,i,n=ea.FILE_TYPE_FOLDER,r=[]){this.name=e,this.path=i,this.type=n,this.files=r,this.isDirectory=!0}findAll(e){return this.doFindAll(e)}doFindAll(e){const i=[],n=r=>{for(const o of r)o.isDirectory?n(o.files):(!e||o.type===e)&&i.push(o)};return n(this.files),i}flatten(){return this.doFindAll(void 0)}}class Wke{constructor(e){this.listFiles=async(i="/",n=!1,r)=>{const o=i,a=(()=>{if(!r)return;const f=Array.isArray(r)?r:[r];return n&&!f.includes(ea.FILE_TYPE_FOLDER)?[...f,ea.FILE_TYPE_FOLDER]:f})(),s=f=>{const h=f.replace(/\/+$/,"");if(h===""||h==="/")return"/";const p=h.split("/").filter(Boolean);return p.length?p[p.length-1]:"/"},l=async f=>{const h={path:f,types:a==null?void 0:a.map(y=>this.convertFileTypeDomainToDTO(y))},g=(await this.http.postJSON("/v1/ListRecordingFiles/",h)).files??[],v=new vY(f==="/"?"/":s(f),f,ea.FILE_TYPE_FOLDER,[]);for(const y of g)if(y.type===Os.FILE_TYPE_FOLDER&&n){const m=await l(y.path);v.files.push(m)}else{const m=y.type===Os.FILE_TYPE_FOLDER?new vY(s(y.path),y.path,this.convertFileTypeDTOToDomain(y.type),[]):new I0t(s(y.path),y.path,this.convertFileTypeDTOToDomain(y.type),this.http.fileDownloadBaseUrl);v.files.push(m)}return v},u=f=>{const h=r?Array.isArray(r)?r:[r]:void 0;if(!f.isDirectory)return f;const p=f.files.map(g=>u(g)).filter(g=>!g.isDirectory||h&&h.includes(ea.FILE_TYPE_FOLDER)?!0:g.isDirectory&&g.files.length>0);return{...f,files:p}},c=await l(o),d=u(c);return new vY("/","/",ea.FILE_TYPE_FOLDER,d.files)},this.http=new $ke(e)}convertFileTypeDomainToDTO(e){switch(e){case null:case void 0:case ea.FILE_TYPE_UNKNOWN:return Os.FILE_TYPE_UNKNOWN;case ea.FILE_TYPE_FOLDER:return Os.FILE_TYPE_FOLDER;case ea.FILE_TYPE_VIDEO:return Os.FILE_TYPE_VIDEO;case ea.FILE_TYPE_AUDIO:return Os.FILE_TYPE_AUDIO;case ea.FILE_TYPE_IMAGE:return Os.FILE_TYPE_IMAGE;case ea.FILE_TYPE_RECORDING:return Os.FILE_TYPE_RECORDING;case ea.FILE_TYPE_RECORDING_SESSION:return Os.FILE_TYPE_RECORDING_SESSION;case ea.FILE_TYPE_RECORDING_MAPPING:return Os.FILE_TYPE_RECORDING_MAPPING;case ea.FILE_TYPE_PLATFORM:return Os.FILE_TYPE_PLATFORM;case ea.FILE_TYPE_INSTANCE:return Os.FILE_TYPE_INSTANCE;case ea.FILE_TYPE_SIGNAL_DATABASE:return Os.FILE_TYPE_SIGNAL_DATABASE;default:throw new Error(`Unknown FileType: ${e}`)}}convertFileTypeDTOToDomain(e){switch(e){case Os.FILE_TYPE_UNKNOWN:return ea.FILE_TYPE_UNKNOWN;case Os.FILE_TYPE_FOLDER:return ea.FILE_TYPE_FOLDER;case Os.FILE_TYPE_VIDEO:return ea.FILE_TYPE_VIDEO;case Os.FILE_TYPE_AUDIO:return ea.FILE_TYPE_AUDIO;case Os.FILE_TYPE_IMAGE:return ea.FILE_TYPE_IMAGE;case Os.FILE_TYPE_RECORDING:return ea.FILE_TYPE_RECORDING;case Os.FILE_TYPE_RECORDING_SESSION:return ea.FILE_TYPE_RECORDING_SESSION;case Os.FILE_TYPE_RECORDING_MAPPING:return ea.FILE_TYPE_RECORDING_MAPPING;case Os.FILE_TYPE_PLATFORM:return ea.FILE_TYPE_PLATFORM;case Os.FILE_TYPE_INSTANCE:return ea.FILE_TYPE_INSTANCE;case Os.FILE_TYPE_SIGNAL_DATABASE:return ea.FILE_TYPE_SIGNAL_DATABASE;default:throw new Error(`Unknown FileTypeDTO: ${e}`)}}async fetchSessionInfo(e){try{const i=await this.http.fetchYaml(e),n=fY(i.start_time),r=fY(i.end_time),o=i.files.map(s=>{if(s.type==="recording")return{location:s.location,devices:s.devices};{const l=s.start_time?fY(s.start_time):void 0,u=$yt(s.offset)||0,c=l!==void 0?l-n+u:u;return{location:s.location,name:s.name??s.location,offsetMs:c,startTimeMs:l,url:`${this.http.fileDownloadBaseUrl}/api/broker/files?path=${k0t(e,s.location)}`}}}),a=o.filter(s=>"url"in s);return{path:e,name:i.name,startTimeMs:n,endTimeMs:r,durationMs:r-n,files:o,videos:a}}catch(i){throw i}}}const Zue=5e3;class Gke{constructor(e){this.play=async i=>{const n={path:i};await this.http.postJSON("/v1/RecordingSession/PlaybackPlay",n)},this.pause=async i=>{const n={path:i};await this.http.postJSON("/v1/RecordingSession/PlaybackPause",n)},this.seek=async(i,n)=>{const r={path:i,offset:n};await this.http.postJSON("/v1/RecordingSession/PlaybackSeek",r)},this.stopRepeat=async i=>{const n={path:i,startOffset:void 0,endOffset:void 0};await this.http.postJSON("/v1/RecordingSession/PlaybackRepeat",n)},this.repeatEntireRecording=async i=>{const n={path:i,startOffset:0,endOffset:void 0};await this.http.postJSON("/v1/RecordingSession/PlaybackRepeat",n)},this.repeatWithOffset=async(i,n,r)=>{console.log(`> repeat (${i})`);const o={path:i,startOffset:n,endOffset:r};await this.http.postJSON("/v1/RecordingSession/PlaybackRepeat",o)},this.open=async i=>{const n={path:i};await this.http.postJSON("/v1/RecordingSession/PlaybackOpen",n)},this.close=async i=>{const n={path:i};await this.http.postJSON("/v1/RecordingSession/PlaybackClose",n)},this.subscribeToPlaybackStatuses=async(i,n,r)=>{this._abortController&&(this._abortController.abort(),this._abortController=void 0),this._abortController=new AbortController,await this.tryConnectPlaybackStream(i,n,r)},this.stopPlaybackStatusStream=()=>{this._abortController&&(this._abortController.abort(),this._abortController=void 0),this._currentPlaybackStream&&(this._currentPlaybackStream(),this._currentPlaybackStream=void 0)},this.http=new $ke(e),this._currentPlaybackStream=void 0,this._abortController=void 0}convertPlaybackModeDTOToDomain(e){switch(e){case null:case void 0:case qU.PLAYBACK_PLAYING:return iS.PLAYBACK_PLAYING;case qU.PLAYBACK_PAUSED:return iS.PLAYBACK_PAUSED;case qU.PLAYBACK_CLOSED:return iS.PLAYBACK_CLOSED;default:throw new Error(`Unknown PlaybackModeDTO: ${e}`)}}convertPlaybackStatusDTOToDomain(e){return{path:e.path,mode:this.convertPlaybackModeDTOToDomain(e.mode),elapsedTimeMs:e.offset/1e3,repeat:e.repeat?{startOffset:e.repeat.startOffset,endOffset:e.repeat.endOffset}:void 0}}async waitForRetry(e){return new Promise(i=>{var o;const n=setTimeout(i,e),r=()=>{clearTimeout(n),i()};(o=this._abortController)==null||o.signal.addEventListener("abort",r,{once:!0})})}async consumePlaybackStatusStream(e,i){var n;for await(const r of e){const o=((n=r.items)==null?void 0:n.map(a=>this.convertPlaybackStatusDTOToDomain(a)))??[];i({items:o})}}async tryConnectPlaybackStream(e,i,n){if(!(!this._abortController||this._abortController.signal.aborted))try{const r=this.http.postJSONStream("/v1/RecordingSession/PlaybackStatus",{},this._abortController.signal);console.log("Playback status stream connected"),n(),e({items:[]}),await this.consumePlaybackStatusStream(r,e),console.log("Playback status stream ended");return}catch(r){if((r==null?void 0:r.name)==="AbortError"||!this._abortController)return;console.log(`Playback status stream error, retrying in ${Zue}ms...`,r),i(r),await this.waitForRetry(Zue),await this.tryConnectPlaybackStream(e,i,n)}}}const Yke=J.createContext(null);function F6(){const t=J.useContext(Yke);if(!t)throw new Error("useBrokerContext must be used within a BrokerProvider");return t}function fte(){const t=F6();if(!t.connectedBroker)throw new Error("No broker config found. Specify which broker to connect to first.");return t.connectedBroker}async function N0t(t,e){const i=t.replace(/\/+$/,""),n=new URL(i),r=await qke(n,e?[e]:[50051,8081]);return{grpcUrl:i,httpUrl:r}}async function qke(t,e){if(e.length===0)throw new Error("No working port found");const i=e[0],n=`${t.protocol}//${t.hostname}:${i}`;return await F0t(`${n}/api/broker/health`)?n:qke(t,e.slice(1))}async function F0t(t){try{return(await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}})).status===200}catch{return!1}}var yY={},mY={},bT={},Jue;function qP(){return Jue||(Jue=1,(function(t){var e=typeof Object.defineProperties=="function"?Object.defineProperty:function(Z,re,ye){Z!=Array.prototype&&Z!=Object.prototype&&(Z[re]=ye.value)},i=typeof window<"u"&&window===bT?bT:typeof xp<"u"&&xp!=null?xp:bT;function n(Z,re){if(re){var ye=i;Z=Z.split(".");for(var Ye=0;Ye<Z.length-1;Ye++){var gt=Z[Ye];gt in ye||(ye[gt]={}),ye=ye[gt]}Z=Z[Z.length-1],Ye=ye[Z],re=re(Ye),re!=Ye&&re!=null&&e(ye,Z,{configurable:!0,writable:!0,value:re})}}function r(Z){var re=0;return function(){return re<Z.length?{done:!1,value:Z[re++]}:{done:!0}}}function o(){o=function(){},i.Symbol||(i.Symbol=s)}function a(Z,re){this.a=Z,e(this,"description",{configurable:!0,writable:!0,value:re})}a.prototype.toString=function(){return this.a};var s=(function(){function Z(ye){if(this instanceof Z)throw new TypeError("Symbol is not a constructor");return new a("jscomp_symbol_"+(ye||"")+"_"+re++,ye)}var re=0;return Z})();function l(){o();var Z=i.Symbol.iterator;Z||(Z=i.Symbol.iterator=i.Symbol("Symbol.iterator")),typeof Array.prototype[Z]!="function"&&e(Array.prototype,Z,{configurable:!0,writable:!0,value:function(){return u(r(this))}}),l=function(){}}function u(Z){return l(),Z={next:Z},Z[i.Symbol.iterator]=function(){return this},Z}function c(Z,re){l(),Z instanceof String&&(Z+="");var ye=0,Ye={next:function(){if(ye<Z.length){var gt=ye++;return{value:re(gt,Z[gt]),done:!1}}return Ye.next=function(){return{done:!0,value:void 0}},Ye.next()}};return Ye[Symbol.iterator]=function(){return Ye},Ye}n("Array.prototype.entries",function(Z){return Z||function(){return c(this,function(re,ye){return[re,ye]})}});var d=bT||self;function f(Z,re,ye){Z=Z.split("."),ye=ye||d,Z[0]in ye||typeof ye.execScript>"u"||ye.execScript("var "+Z[0]);for(var Ye;Z.length&&(Ye=Z.shift());)Z.length||re===void 0?ye[Ye]&&ye[Ye]!==Object.prototype[Ye]?ye=ye[Ye]:ye=ye[Ye]={}:ye[Ye]=re}function h(Z){var re=typeof Z;if(re=="object")if(Z){if(Z instanceof Array)return"array";if(Z instanceof Object)return re;var ye=Object.prototype.toString.call(Z);if(ye=="[object Window]")return"object";if(ye=="[object Array]"||typeof Z.length=="number"&&typeof Z.splice<"u"&&typeof Z.propertyIsEnumerable<"u"&&!Z.propertyIsEnumerable("splice"))return"array";if(ye=="[object Function]"||typeof Z.call<"u"&&typeof Z.propertyIsEnumerable<"u"&&!Z.propertyIsEnumerable("call"))return"function"}else return"null";else if(re=="function"&&typeof Z.call>"u")return"object";return re}function p(Z){var re=typeof Z;return re=="object"&&Z!=null||re=="function"}function g(Z,re,ye){f(Z,re,ye)}function v(Z,re){function ye(){}ye.prototype=re.prototype,Z.prototype=new ye,Z.prototype.constructor=Z}var y="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function m(Z,re){for(var ye,Ye,gt=1;gt<arguments.length;gt++){Ye=arguments[gt];for(ye in Ye)Z[ye]=Ye[ye];for(var Dt=0;Dt<y.length;Dt++)ye=y[Dt],Object.prototype.hasOwnProperty.call(Ye,ye)&&(Z[ye]=Ye[ye])}}var b=Array.prototype.forEach?function(Z,re){Array.prototype.forEach.call(Z,re,void 0)}:function(Z,re){for(var ye=Z.length,Ye=typeof Z=="string"?Z.split(""):Z,gt=0;gt<ye;gt++)gt in Ye&&re.call(void 0,Ye[gt],gt,Z)},S=Array.prototype.map?function(Z,re){return Array.prototype.map.call(Z,re,void 0)}:function(Z,re){for(var ye=Z.length,Ye=Array(ye),gt=typeof Z=="string"?Z.split(""):Z,Dt=0;Dt<ye;Dt++)Dt in gt&&(Ye[Dt]=re.call(void 0,gt[Dt],Dt,Z));return Ye};function _(Z,re,ye){return 2>=arguments.length?Array.prototype.slice.call(Z,re):Array.prototype.slice.call(Z,re,ye)}function C(Z,re,ye,Ye){var gt="Assertion failed";if(ye){gt+=": "+ye;var Dt=Ye}else Z&&(gt+=": "+Z,Dt=re);throw Error(gt,Dt||[])}function P(Z,re,ye){for(var Ye=[],gt=2;gt<arguments.length;++gt)Ye[gt-2]=arguments[gt];return Z||C("",null,re,Ye),Z}function x(Z,re,ye){for(var Ye=[],gt=2;gt<arguments.length;++gt)Ye[gt-2]=arguments[gt];typeof Z!="string"&&C("Expected string but got %s: %s.",[h(Z),Z],re,Ye)}function E(Z,re,ye){for(var Ye=[],gt=2;gt<arguments.length;++gt)Ye[gt-2]=arguments[gt];Array.isArray(Z)||C("Expected array but got %s: %s.",[h(Z),Z],re,Ye)}function A(Z,re){for(var ye=[],Ye=1;Ye<arguments.length;++Ye)ye[Ye-1]=arguments[Ye];throw Error("Failure"+(Z?": "+Z:""),ye)}function R(Z,re,ye,Ye){for(var gt=[],Dt=3;Dt<arguments.length;++Dt)gt[Dt-3]=arguments[Dt];Z instanceof re||C("Expected instanceof %s but got %s.",[M(re),M(Z)],ye,gt)}function M(Z){return Z instanceof Function?Z.displayName||Z.name||"unknown type name":Z instanceof Object?Z.constructor.displayName||Z.constructor.name||Object.prototype.toString.call(Z):Z===null?"null":typeof Z}function D(Z,re){if(this.c=Z,this.b=re,this.a={},this.arrClean=!0,0<this.c.length){for(Z=0;Z<this.c.length;Z++){re=this.c[Z];var ye=re[0];this.a[ye.toString()]=new z(ye,re[1])}this.arrClean=!0}}f("jspb.Map",D,void 0),D.prototype.g=function(){if(this.arrClean){if(this.b){var Z=this.a,re;for(re in Z)if(Object.prototype.hasOwnProperty.call(Z,re)){var ye=Z[re].a;ye&&ye.g()}}}else{for(this.c.length=0,Z=V(this),Z.sort(),re=0;re<Z.length;re++){var Ye=this.a[Z[re]];(ye=Ye.a)&&ye.g(),this.c.push([Ye.key,Ye.value])}this.arrClean=!0}return this.c},D.prototype.toArray=D.prototype.g,D.prototype.Mc=function(Z,re){for(var ye=this.g(),Ye=[],gt=0;gt<ye.length;gt++){var Dt=this.a[ye[gt][0].toString()];I(this,Dt);var pr=Dt.a;pr?(P(re),Ye.push([Dt.key,re(Z,pr)])):Ye.push([Dt.key,Dt.value])}return Ye},D.prototype.toObject=D.prototype.Mc,D.fromObject=function(Z,re,ye){re=new D([],re);for(var Ye=0;Ye<Z.length;Ye++){var gt=Z[Ye][0],Dt=ye(Z[Ye][1]);re.set(gt,Dt)}return re};function F(Z){this.a=0,this.b=Z}F.prototype.next=function(){return this.a<this.b.length?{done:!1,value:this.b[this.a++]}:{done:!0,value:void 0}},typeof Symbol<"u"&&(F.prototype[Symbol.iterator]=function(){return this}),D.prototype.Jb=function(){return V(this).length},D.prototype.getLength=D.prototype.Jb,D.prototype.clear=function(){this.a={},this.arrClean=!1},D.prototype.clear=D.prototype.clear,D.prototype.Cb=function(Z){Z=Z.toString();var re=this.a.hasOwnProperty(Z);return delete this.a[Z],this.arrClean=!1,re},D.prototype.del=D.prototype.Cb,D.prototype.Eb=function(){var Z=[],re=V(this);re.sort();for(var ye=0;ye<re.length;ye++){var Ye=this.a[re[ye]];Z.push([Ye.key,Ye.value])}return Z},D.prototype.getEntryList=D.prototype.Eb,D.prototype.entries=function(){var Z=[],re=V(this);re.sort();for(var ye=0;ye<re.length;ye++){var Ye=this.a[re[ye]];Z.push([Ye.key,I(this,Ye)])}return new F(Z)},D.prototype.entries=D.prototype.entries,D.prototype.keys=function(){var Z=[],re=V(this);re.sort();for(var ye=0;ye<re.length;ye++)Z.push(this.a[re[ye]].key);return new F(Z)},D.prototype.keys=D.prototype.keys,D.prototype.values=function(){var Z=[],re=V(this);re.sort();for(var ye=0;ye<re.length;ye++)Z.push(I(this,this.a[re[ye]]));return new F(Z)},D.prototype.values=D.prototype.values,D.prototype.forEach=function(Z,re){var ye=V(this);ye.sort();for(var Ye=0;Ye<ye.length;Ye++){var gt=this.a[ye[Ye]];Z.call(re,I(this,gt),gt.key,this)}},D.prototype.forEach=D.prototype.forEach,D.prototype.set=function(Z,re){var ye=new z(Z);return this.b?(ye.a=re,ye.value=re.g()):ye.value=re,this.a[Z.toString()]=ye,this.arrClean=!1,this},D.prototype.set=D.prototype.set;function I(Z,re){return Z.b?(re.a||(re.a=new Z.b(re.value)),re.a):re.value}D.prototype.get=function(Z){if(Z=this.a[Z.toString()])return I(this,Z)},D.prototype.get=D.prototype.get,D.prototype.has=function(Z){return Z.toString()in this.a},D.prototype.has=D.prototype.has,D.prototype.Jc=function(Z,re,ye,Ye,gt){var Dt=V(this);Dt.sort();for(var pr=0;pr<Dt.length;pr++){var Gr=this.a[Dt[pr]];re.Va(Z),ye.call(re,1,Gr.key),this.b?Ye.call(re,2,I(this,Gr),gt):Ye.call(re,2,Gr.value),re.Ya()}},D.prototype.serializeBinary=D.prototype.Jc,D.deserializeBinary=function(Z,re,ye,Ye,gt,Dt,pr){for(;re.oa()&&!re.bb();){var Gr=re.c;Gr==1?Dt=ye.call(re):Gr==2&&(Z.b?(P(gt),pr||(pr=new Z.b),Ye.call(re,pr,gt)):pr=Ye.call(re))}P(Dt!=null),P(pr!=null),Z.set(Dt,pr)};function V(Z){Z=Z.a;var re=[],ye;for(ye in Z)Object.prototype.hasOwnProperty.call(Z,ye)&&re.push(ye);return re}function z(Z,re){this.key=Z,this.value=re,this.a=void 0}function G(Z){if(8192>=Z.length)return String.fromCharCode.apply(null,Z);for(var re="",ye=0;ye<Z.length;ye+=8192)re+=String.fromCharCode.apply(null,_(Z,ye,ye+8192));return re}var H={"\0":"\\0","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","	":"\\t","\v":"\\x0B",'"':'\\"',"\\":"\\\\","<":"\\u003C"},U={"'":"\\'"},k={},X=null;function W(Z,re){re===void 0&&(re=0),oe(),re=k[re];for(var ye=[],Ye=0;Ye<Z.length;Ye+=3){var gt=Z[Ye],Dt=Ye+1<Z.length,pr=Dt?Z[Ye+1]:0,Gr=Ye+2<Z.length,rn=Gr?Z[Ye+2]:0,ro=gt>>2;gt=(gt&3)<<4|pr>>4,pr=(pr&15)<<2|rn>>6,rn&=63,Gr||(rn=64,Dt||(pr=64)),ye.push(re[ro],re[gt],re[pr]||"",re[rn]||"")}return ye.join("")}function Y(Z){var re=Z.length,ye=3*re/4;ye%3?ye=Math.floor(ye):"=.".indexOf(Z[re-1])!=-1&&(ye="=.".indexOf(Z[re-2])!=-1?ye-2:ye-1);var Ye=new Uint8Array(ye),gt=0;return te(Z,function(Dt){Ye[gt++]=Dt}),Ye.subarray(0,gt)}function te(Z,re){function ye(rn){for(;Ye<Z.length;){var ro=Z.charAt(Ye++),na=X[ro];if(na!=null)return na;if(!/^[\s\xa0]*$/.test(ro))throw Error("Unknown base64 encoding at char: "+ro)}return rn}oe();for(var Ye=0;;){var gt=ye(-1),Dt=ye(0),pr=ye(64),Gr=ye(64);if(Gr===64&&gt===-1)break;re(gt<<2|Dt>>4),pr!=64&&(re(Dt<<4&240|pr>>2),Gr!=64&&re(pr<<6&192|Gr))}}function oe(){if(!X){X={};for(var Z="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),re=["+/=","+/","-_=","-_.","-_"],ye=0;5>ye;ye++){var Ye=Z.concat(re[ye].split(""));k[ye]=Ye;for(var gt=0;gt<Ye.length;gt++){var Dt=Ye[gt];X[Dt]===void 0&&(X[Dt]=gt)}}}}f("jspb.ConstBinaryMessage",function(){},void 0),f("jspb.BinaryMessage",function(){},void 0),f("jspb.BinaryConstants.FieldType",{yb:-1,ee:1,FLOAT:2,ke:3,te:4,je:5,xb:6,wb:7,BOOL:8,re:9,ie:10,le:11,ce:12,se:13,ge:14,me:15,ne:16,oe:17,pe:18,he:30,ve:31},void 0),f("jspb.BinaryConstants.WireType",{yb:-1,ue:0,xb:1,de:2,qe:3,fe:4,wb:5},void 0),f("jspb.BinaryConstants.FieldTypeToWireType",function(Z){switch(Z){case 5:case 3:case 13:case 4:case 17:case 18:case 8:case 14:case 31:return 0;case 1:case 6:case 16:case 30:return 1;case 9:case 11:case 12:return 2;case 2:case 7:case 15:return 5;default:return-1}},void 0),f("jspb.BinaryConstants.INVALID_FIELD_NUMBER",-1,void 0),f("jspb.BinaryConstants.FLOAT32_EPS",1401298464324817e-60,void 0),f("jspb.BinaryConstants.FLOAT32_MIN",11754943508222875e-54,void 0),f("jspb.BinaryConstants.FLOAT32_MAX",34028234663852886e22,void 0),f("jspb.BinaryConstants.FLOAT64_EPS",5e-324,void 0),f("jspb.BinaryConstants.FLOAT64_MIN",22250738585072014e-324,void 0),f("jspb.BinaryConstants.FLOAT64_MAX",17976931348623157e292,void 0),f("jspb.BinaryConstants.TWO_TO_20",1048576,void 0),f("jspb.BinaryConstants.TWO_TO_23",8388608,void 0),f("jspb.BinaryConstants.TWO_TO_31",2147483648,void 0),f("jspb.BinaryConstants.TWO_TO_32",4294967296,void 0),f("jspb.BinaryConstants.TWO_TO_52",4503599627370496,void 0),f("jspb.BinaryConstants.TWO_TO_63",9223372036854776e3,void 0),f("jspb.BinaryConstants.TWO_TO_64",18446744073709552e3,void 0),f("jspb.BinaryConstants.ZERO_HASH","\0\0\0\0\0\0\0\0",void 0);var de=0,ge=0;f("jspb.utils.getSplit64Low",function(){return de},void 0),f("jspb.utils.getSplit64High",function(){return ge},void 0);function Ee(Z){var re=Z>>>0;Z=Math.floor((Z-re)/4294967296)>>>0,de=re,ge=Z}f("jspb.utils.splitUint64",Ee,void 0);function Re(Z){var re=0>Z;Z=Math.abs(Z);var ye=Z>>>0;Z=Math.floor((Z-ye)/4294967296),Z>>>=0,re&&(Z=~Z>>>0,ye=(~ye>>>0)+1,4294967295<ye&&(ye=0,Z++,4294967295<Z&&(Z=0))),de=ye,ge=Z}f("jspb.utils.splitInt64",Re,void 0);function Ae(Z){var re=0>Z;Z=2*Math.abs(Z),Ee(Z),Z=de;var ye=ge;re&&(Z==0?ye==0?ye=Z=4294967295:(ye--,Z=4294967295):Z--),de=Z,ge=ye}f("jspb.utils.splitZigzag64",Ae,void 0);function Pe(Z){var re=0>Z?1:0;if(Z=re?-Z:Z,Z===0)0<1/Z?de=ge=0:(ge=0,de=2147483648);else if(isNaN(Z))ge=0,de=2147483647;else if(34028234663852886e22<Z)ge=0,de=(re<<31|2139095040)>>>0;else if(11754943508222875e-54>Z)Z=Math.round(Z/Math.pow(2,-149)),ge=0,de=(re<<31|Z)>>>0;else{var ye=Math.floor(Math.log(Z)/Math.LN2);Z*=Math.pow(2,-ye),Z=Math.round(8388608*Z),16777216<=Z&&++ye,ge=0,de=(re<<31|ye+127<<23|Z&8388607)>>>0}}f("jspb.utils.splitFloat32",Pe,void 0);function we(Z){var re=0>Z?1:0;if(Z=re?-Z:Z,Z===0)ge=0<1/Z?0:2147483648,de=0;else if(isNaN(Z))ge=2147483647,de=4294967295;else if(17976931348623157e292<Z)ge=(re<<31|2146435072)>>>0,de=0;else if(22250738585072014e-324>Z)Z/=Math.pow(2,-1074),ge=(re<<31|Z/4294967296)>>>0,de=Z>>>0;else{var ye=Z,Ye=0;if(2<=ye)for(;2<=ye&&1023>Ye;)Ye++,ye/=2;else for(;1>ye&&-1022<Ye;)ye*=2,Ye--;Z*=Math.pow(2,-Ye),ge=(re<<31|Ye+1023<<20|1048576*Z&1048575)>>>0,de=4503599627370496*Z>>>0}}f("jspb.utils.splitFloat64",we,void 0);function Te(Z){var re=Z.charCodeAt(4),ye=Z.charCodeAt(5),Ye=Z.charCodeAt(6),gt=Z.charCodeAt(7);de=Z.charCodeAt(0)+(Z.charCodeAt(1)<<8)+(Z.charCodeAt(2)<<16)+(Z.charCodeAt(3)<<24)>>>0,ge=re+(ye<<8)+(Ye<<16)+(gt<<24)>>>0}f("jspb.utils.splitHash64",Te,void 0);function ke(Z,re){return 4294967296*re+(Z>>>0)}f("jspb.utils.joinUint64",ke,void 0);function $e(Z,re){var ye=re&2147483648;return ye&&(Z=~Z+1>>>0,re=~re>>>0,Z==0&&(re=re+1>>>0)),Z=ke(Z,re),ye?-Z:Z}f("jspb.utils.joinInt64",$e,void 0);function Ne(Z,re,ye){var Ye=re>>31;return ye(Z<<1^Ye,(re<<1|Z>>>31)^Ye)}f("jspb.utils.toZigzag64",Ne,void 0);function ve(Z,re){return pe(Z,re,$e)}f("jspb.utils.joinZigzag64",ve,void 0);function pe(Z,re,ye){var Ye=-(Z&1);return ye((Z>>>1|re<<31)^Ye,re>>>1^Ye)}f("jspb.utils.fromZigzag64",pe,void 0);function fe(Z){var re=2*(Z>>31)+1,ye=Z>>>23&255;return Z&=8388607,ye==255?Z?NaN:1/0*re:ye==0?re*Math.pow(2,-149)*Z:re*Math.pow(2,ye-150)*(Z+Math.pow(2,23))}f("jspb.utils.joinFloat32",fe,void 0);function me(Z,re){var ye=2*(re>>31)+1,Ye=re>>>20&2047;return Z=4294967296*(re&1048575)+Z,Ye==2047?Z?NaN:1/0*ye:Ye==0?ye*Math.pow(2,-1074)*Z:ye*Math.pow(2,Ye-1075)*(Z+4503599627370496)}f("jspb.utils.joinFloat64",me,void 0);function Ce(Z,re){return String.fromCharCode(Z>>>0&255,Z>>>8&255,Z>>>16&255,Z>>>24&255,re>>>0&255,re>>>8&255,re>>>16&255,re>>>24&255)}f("jspb.utils.joinHash64",Ce,void 0),f("jspb.utils.DIGITS","0123456789abcdef".split(""),void 0);function Ue(Z,re){function ye(gt,Dt){return gt=gt?String(gt):"",Dt?"0000000".slice(gt.length)+gt:gt}if(2097151>=re)return""+ke(Z,re);var Ye=(Z>>>24|re<<8)>>>0&16777215;return re=re>>16&65535,Z=(Z&16777215)+6777216*Ye+6710656*re,Ye+=8147497*re,re*=2,1e7<=Z&&(Ye+=Math.floor(Z/1e7),Z%=1e7),1e7<=Ye&&(re+=Math.floor(Ye/1e7),Ye%=1e7),ye(re,0)+ye(Ye,re)+ye(Z,1)}f("jspb.utils.joinUnsignedDecimalString",Ue,void 0);function Qe(Z,re){var ye=re&2147483648;return ye&&(Z=~Z+1>>>0,re=~re+(Z==0?1:0)>>>0),Z=Ue(Z,re),ye?"-"+Z:Z}f("jspb.utils.joinSignedDecimalString",Qe,void 0);function it(Z,re){Te(Z),Z=de;var ye=ge;return re?Qe(Z,ye):Ue(Z,ye)}f("jspb.utils.hash64ToDecimalString",it,void 0),f("jspb.utils.hash64ArrayToDecimalStrings",function(Z,re){for(var ye=Array(Z.length),Ye=0;Ye<Z.length;Ye++)ye[Ye]=it(Z[Ye],re);return ye},void 0);function xt(Z){function re(pr,Gr){for(var rn=0;8>rn&&(pr!==1||0<Gr);rn++)Gr=pr*gt[rn]+Gr,gt[rn]=Gr&255,Gr>>>=8}function ye(){for(var pr=0;8>pr;pr++)gt[pr]=~gt[pr]&255}P(0<Z.length);var Ye=!1;Z[0]==="-"&&(Ye=!0,Z=Z.slice(1));for(var gt=[0,0,0,0,0,0,0,0],Dt=0;Dt<Z.length;Dt++)re(10,Z.charCodeAt(Dt)-48);return Ye&&(ye(),re(1,1)),G(gt)}f("jspb.utils.decimalStringToHash64",xt,void 0),f("jspb.utils.splitDecimalString",function(Z){Te(xt(Z))},void 0);function wt(Z){return String.fromCharCode(10>Z?48+Z:87+Z)}function $t(Z){return 97<=Z?Z-97+10:Z-48}f("jspb.utils.hash64ToHexString",function(Z){var re=Array(18);re[0]="0",re[1]="x";for(var ye=0;8>ye;ye++){var Ye=Z.charCodeAt(7-ye);re[2*ye+2]=wt(Ye>>4),re[2*ye+3]=wt(Ye&15)}return re.join("")},void 0),f("jspb.utils.hexStringToHash64",function(Z){Z=Z.toLowerCase(),P(Z.length==18),P(Z[0]=="0"),P(Z[1]=="x");for(var re="",ye=0;8>ye;ye++)re=String.fromCharCode(16*$t(Z.charCodeAt(2*ye+2))+$t(Z.charCodeAt(2*ye+3)))+re;return re},void 0),f("jspb.utils.hash64ToNumber",function(Z,re){Te(Z),Z=de;var ye=ge;return re?$e(Z,ye):ke(Z,ye)},void 0),f("jspb.utils.numberToHash64",function(Z){return Re(Z),Ce(de,ge)},void 0),f("jspb.utils.countVarints",function(Z,re,ye){for(var Ye=0,gt=re;gt<ye;gt++)Ye+=Z[gt]>>7;return ye-re-Ye},void 0),f("jspb.utils.countVarintFields",function(Z,re,ye,Ye){var gt=0;if(Ye*=8,128>Ye)for(;re<ye&&Z[re++]==Ye;)for(gt++;;){var Dt=Z[re++];if((Dt&128)==0)break}else for(;re<ye;){for(Dt=Ye;128<Dt;){if(Z[re]!=(Dt&127|128))return gt;re++,Dt>>=7}if(Z[re++]!=Dt)break;for(gt++;Dt=Z[re++],(Dt&128)!=0;);}return gt},void 0);function Mt(Z,re,ye,Ye,gt){var Dt=0;if(128>Ye)for(;re<ye&&Z[re++]==Ye;)Dt++,re+=gt;else for(;re<ye;){for(var pr=Ye;128<pr;){if(Z[re++]!=(pr&127|128))return Dt;pr>>=7}if(Z[re++]!=pr)break;Dt++,re+=gt}return Dt}f("jspb.utils.countFixed32Fields",function(Z,re,ye,Ye){return Mt(Z,re,ye,8*Ye+5,4)},void 0),f("jspb.utils.countFixed64Fields",function(Z,re,ye,Ye){return Mt(Z,re,ye,8*Ye+1,8)},void 0),f("jspb.utils.countDelimitedFields",function(Z,re,ye,Ye){var gt=0;for(Ye=8*Ye+2;re<ye;){for(var Dt=Ye;128<Dt;){if(Z[re++]!=(Dt&127|128))return gt;Dt>>=7}if(Z[re++]!=Dt)break;gt++;for(var pr=0,Gr=1;Dt=Z[re++],pr+=(Dt&127)*Gr,Gr*=128,(Dt&128)!=0;);re+=pr}return gt},void 0),f("jspb.utils.debugBytesToTextFormat",function(Z){var re='"';if(Z){Z=rt(Z);for(var ye=0;ye<Z.length;ye++)re+="\\x",16>Z[ye]&&(re+="0"),re+=Z[ye].toString(16)}return re+'"'},void 0),f("jspb.utils.debugScalarToTextFormat",function(Z){if(typeof Z=="string"){Z=String(Z);for(var re=['"'],ye=0;ye<Z.length;ye++){var Ye=Z.charAt(ye),gt=Ye.charCodeAt(0),Dt=ye+1,pr;(pr=H[Ye])||(31<gt&&127>gt||(gt=Ye,gt in U?Ye=U[gt]:gt in H?Ye=U[gt]=H[gt]:(pr=gt.charCodeAt(0),31<pr&&127>pr?Ye=gt:(256>pr?(Ye="\\x",(16>pr||256<pr)&&(Ye+="0")):(Ye="\\u",4096>pr&&(Ye+="0")),Ye+=pr.toString(16).toUpperCase()),Ye=U[gt]=Ye)),pr=Ye),re[Dt]=pr}re.push('"'),Z=re.join("")}else Z=Z.toString();return Z},void 0),f("jspb.utils.stringToByteArray",function(Z){for(var re=new Uint8Array(Z.length),ye=0;ye<Z.length;ye++){var Ye=Z.charCodeAt(ye);if(255<Ye)throw Error("Conversion error: string contains codepoint outside of byte range");re[ye]=Ye}return re},void 0);function rt(Z){return Z.constructor===Uint8Array?Z:Z.constructor===ArrayBuffer?new Uint8Array(Z):Z.constructor===Array?new Uint8Array(Z):Z.constructor===String?Y(Z):Z instanceof Uint8Array?new Uint8Array(Z.buffer,Z.byteOffset,Z.byteLength):(A("Type not convertible to Uint8Array."),new Uint8Array(0))}f("jspb.utils.byteSourceToUint8Array",rt,void 0);function qe(Z,re,ye){this.b=null,this.a=this.c=this.h=0,this.v=!1,Z&&this.H(Z,re,ye)}f("jspb.BinaryDecoder",qe,void 0);var vt=[];qe.getInstanceCacheLength=function(){return vt.length};function kt(Z,re,ye){if(vt.length){var Ye=vt.pop();return Z&&Ye.H(Z,re,ye),Ye}return new qe(Z,re,ye)}qe.alloc=kt,qe.prototype.Ca=function(){this.clear(),100>vt.length&&vt.push(this)},qe.prototype.free=qe.prototype.Ca,qe.prototype.clone=function(){return kt(this.b,this.h,this.c-this.h)},qe.prototype.clone=qe.prototype.clone,qe.prototype.clear=function(){this.b=null,this.a=this.c=this.h=0,this.v=!1},qe.prototype.clear=qe.prototype.clear,qe.prototype.Y=function(){return this.b},qe.prototype.getBuffer=qe.prototype.Y,qe.prototype.H=function(Z,re,ye){this.b=rt(Z),this.h=re!==void 0?re:0,this.c=ye!==void 0?this.h+ye:this.b.length,this.a=this.h},qe.prototype.setBlock=qe.prototype.H,qe.prototype.Db=function(){return this.c},qe.prototype.getEnd=qe.prototype.Db,qe.prototype.setEnd=function(Z){this.c=Z},qe.prototype.setEnd=qe.prototype.setEnd,qe.prototype.reset=function(){this.a=this.h},qe.prototype.reset=qe.prototype.reset,qe.prototype.B=function(){return this.a},qe.prototype.getCursor=qe.prototype.B,qe.prototype.Ma=function(Z){this.a=Z},qe.prototype.setCursor=qe.prototype.Ma,qe.prototype.advance=function(Z){this.a+=Z,P(this.a<=this.c)},qe.prototype.advance=qe.prototype.advance,qe.prototype.ya=function(){return this.a==this.c},qe.prototype.atEnd=qe.prototype.ya,qe.prototype.Qb=function(){return this.a>this.c},qe.prototype.pastEnd=qe.prototype.Qb,qe.prototype.getError=function(){return this.v||0>this.a||this.a>this.c},qe.prototype.getError=qe.prototype.getError,qe.prototype.w=function(Z){for(var re=128,ye=0,Ye=0,gt=0;4>gt&&128<=re;gt++)re=this.b[this.a++],ye|=(re&127)<<7*gt;if(128<=re&&(re=this.b[this.a++],ye|=(re&127)<<28,Ye|=(re&127)>>4),128<=re)for(gt=0;5>gt&&128<=re;gt++)re=this.b[this.a++],Ye|=(re&127)<<7*gt+3;if(128>re)return Z(ye>>>0,Ye>>>0);A("Failed to read varint, encoding is invalid."),this.v=!0},qe.prototype.readSplitVarint64=qe.prototype.w,qe.prototype.ea=function(Z){return this.w(function(re,ye){return pe(re,ye,Z)})},qe.prototype.readSplitZigzagVarint64=qe.prototype.ea,qe.prototype.ta=function(Z){var re=this.b,ye=this.a;this.a+=8;for(var Ye=0,gt=0,Dt=ye+7;Dt>=ye;Dt--)Ye=Ye<<8|re[Dt],gt=gt<<8|re[Dt+4];return Z(Ye,gt)},qe.prototype.readSplitFixed64=qe.prototype.ta,qe.prototype.kb=function(){for(;this.b[this.a]&128;)this.a++;this.a++},qe.prototype.skipVarint=qe.prototype.kb,qe.prototype.mb=function(Z){for(;128<Z;)this.a--,Z>>>=7;this.a--},qe.prototype.unskipVarint=qe.prototype.mb,qe.prototype.o=function(){var Z=this.b,re=Z[this.a],ye=re&127;return 128>re?(this.a+=1,P(this.a<=this.c),ye):(re=Z[this.a+1],ye|=(re&127)<<7,128>re?(this.a+=2,P(this.a<=this.c),ye):(re=Z[this.a+2],ye|=(re&127)<<14,128>re?(this.a+=3,P(this.a<=this.c),ye):(re=Z[this.a+3],ye|=(re&127)<<21,128>re?(this.a+=4,P(this.a<=this.c),ye):(re=Z[this.a+4],ye|=(re&15)<<28,128>re?(this.a+=5,P(this.a<=this.c),ye>>>0):(this.a+=5,128<=Z[this.a++]&&128<=Z[this.a++]&&128<=Z[this.a++]&&128<=Z[this.a++]&&128<=Z[this.a++]&&P(!1),P(this.a<=this.c),ye)))))},qe.prototype.readUnsignedVarint32=qe.prototype.o,qe.prototype.da=function(){return~~this.o()},qe.prototype.readSignedVarint32=qe.prototype.da,qe.prototype.O=function(){return this.o().toString()},qe.prototype.Ea=function(){return this.da().toString()},qe.prototype.readSignedVarint32String=qe.prototype.Ea,qe.prototype.Ia=function(){var Z=this.o();return Z>>>1^-(Z&1)},qe.prototype.readZigzagVarint32=qe.prototype.Ia,qe.prototype.Ga=function(){return this.w(ke)},qe.prototype.readUnsignedVarint64=qe.prototype.Ga,qe.prototype.Ha=function(){return this.w(Ue)},qe.prototype.readUnsignedVarint64String=qe.prototype.Ha,qe.prototype.sa=function(){return this.w($e)},qe.prototype.readSignedVarint64=qe.prototype.sa,qe.prototype.Fa=function(){return this.w(Qe)},qe.prototype.readSignedVarint64String=qe.prototype.Fa,qe.prototype.Ja=function(){return this.w(ve)},qe.prototype.readZigzagVarint64=qe.prototype.Ja,qe.prototype.fb=function(){return this.ea(Ce)},qe.prototype.readZigzagVarintHash64=qe.prototype.fb,qe.prototype.Ka=function(){return this.ea(Qe)},qe.prototype.readZigzagVarint64String=qe.prototype.Ka,qe.prototype.Gc=function(){var Z=this.b[this.a];return this.a+=1,P(this.a<=this.c),Z},qe.prototype.readUint8=qe.prototype.Gc,qe.prototype.Ec=function(){var Z=this.b[this.a],re=this.b[this.a+1];return this.a+=2,P(this.a<=this.c),Z<<0|re<<8},qe.prototype.readUint16=qe.prototype.Ec,qe.prototype.m=function(){var Z=this.b[this.a],re=this.b[this.a+1],ye=this.b[this.a+2],Ye=this.b[this.a+3];return this.a+=4,P(this.a<=this.c),(Z<<0|re<<8|ye<<16|Ye<<24)>>>0},qe.prototype.readUint32=qe.prototype.m,qe.prototype.ga=function(){var Z=this.m(),re=this.m();return ke(Z,re)},qe.prototype.readUint64=qe.prototype.ga,qe.prototype.ha=function(){var Z=this.m(),re=this.m();return Ue(Z,re)},qe.prototype.readUint64String=qe.prototype.ha,qe.prototype.Xb=function(){var Z=this.b[this.a];return this.a+=1,P(this.a<=this.c),Z<<24>>24},qe.prototype.readInt8=qe.prototype.Xb,qe.prototype.Vb=function(){var Z=this.b[this.a],re=this.b[this.a+1];return this.a+=2,P(this.a<=this.c),(Z<<0|re<<8)<<16>>16},qe.prototype.readInt16=qe.prototype.Vb,qe.prototype.P=function(){var Z=this.b[this.a],re=this.b[this.a+1],ye=this.b[this.a+2],Ye=this.b[this.a+3];return this.a+=4,P(this.a<=this.c),Z<<0|re<<8|ye<<16|Ye<<24},qe.prototype.readInt32=qe.prototype.P,qe.prototype.ba=function(){var Z=this.m(),re=this.m();return $e(Z,re)},qe.prototype.readInt64=qe.prototype.ba,qe.prototype.ca=function(){var Z=this.m(),re=this.m();return Qe(Z,re)},qe.prototype.readInt64String=qe.prototype.ca,qe.prototype.aa=function(){var Z=this.m();return fe(Z)},qe.prototype.readFloat=qe.prototype.aa,qe.prototype.Z=function(){var Z=this.m(),re=this.m();return me(Z,re)},qe.prototype.readDouble=qe.prototype.Z,qe.prototype.pa=function(){return!!this.b[this.a++]},qe.prototype.readBool=qe.prototype.pa,qe.prototype.ra=function(){return this.da()},qe.prototype.readEnum=qe.prototype.ra,qe.prototype.fa=function(Z){var re=this.b,ye=this.a;Z=ye+Z;for(var Ye=[],gt="";ye<Z;){var Dt=re[ye++];if(128>Dt)Ye.push(Dt);else{if(192>Dt)continue;if(224>Dt){var pr=re[ye++];Ye.push((Dt&31)<<6|pr&63)}else if(240>Dt){pr=re[ye++];var Gr=re[ye++];Ye.push((Dt&15)<<12|(pr&63)<<6|Gr&63)}else if(248>Dt){pr=re[ye++],Gr=re[ye++];var rn=re[ye++];Dt=(Dt&7)<<18|(pr&63)<<12|(Gr&63)<<6|rn&63,Dt-=65536,Ye.push((Dt>>10&1023)+55296,(Dt&1023)+56320)}}8192<=Ye.length&&(gt+=String.fromCharCode.apply(null,Ye),Ye.length=0)}return gt+=G(Ye),this.a=ye,gt},qe.prototype.readString=qe.prototype.fa,qe.prototype.Dc=function(){var Z=this.o();return this.fa(Z)},qe.prototype.readStringWithLength=qe.prototype.Dc,qe.prototype.qa=function(Z){if(0>Z||this.a+Z>this.b.length)return this.v=!0,A("Invalid byte length!"),new Uint8Array(0);var re=this.b.subarray(this.a,this.a+Z);return this.a+=Z,P(this.a<=this.c),re},qe.prototype.readBytes=qe.prototype.qa,qe.prototype.ia=function(){return this.w(Ce)},qe.prototype.readVarintHash64=qe.prototype.ia,qe.prototype.$=function(){var Z=this.b,re=this.a,ye=Z[re],Ye=Z[re+1],gt=Z[re+2],Dt=Z[re+3],pr=Z[re+4],Gr=Z[re+5],rn=Z[re+6];return Z=Z[re+7],this.a+=8,String.fromCharCode(ye,Ye,gt,Dt,pr,Gr,rn,Z)},qe.prototype.readFixedHash64=qe.prototype.$;function Xe(Z,re,ye){this.a=kt(Z,re,ye),this.O=this.a.B(),this.b=this.c=-1,this.h=!1,this.v=null}f("jspb.BinaryReader",Xe,void 0);var _t=[];Xe.clearInstanceCache=function(){_t=[]},Xe.getInstanceCacheLength=function(){return _t.length};function Ht(Z,re,ye){if(_t.length){var Ye=_t.pop();return Z&&Ye.a.H(Z,re,ye),Ye}return new Xe(Z,re,ye)}Xe.alloc=Ht,Xe.prototype.zb=Ht,Xe.prototype.alloc=Xe.prototype.zb,Xe.prototype.Ca=function(){this.a.clear(),this.b=this.c=-1,this.h=!1,this.v=null,100>_t.length&&_t.push(this)},Xe.prototype.free=Xe.prototype.Ca,Xe.prototype.Fb=function(){return this.O},Xe.prototype.getFieldCursor=Xe.prototype.Fb,Xe.prototype.B=function(){return this.a.B()},Xe.prototype.getCursor=Xe.prototype.B,Xe.prototype.Y=function(){return this.a.Y()},Xe.prototype.getBuffer=Xe.prototype.Y,Xe.prototype.Hb=function(){return this.c},Xe.prototype.getFieldNumber=Xe.prototype.Hb,Xe.prototype.Lb=function(){return this.b},Xe.prototype.getWireType=Xe.prototype.Lb,Xe.prototype.Mb=function(){return this.b==2},Xe.prototype.isDelimited=Xe.prototype.Mb,Xe.prototype.bb=function(){return this.b==4},Xe.prototype.isEndGroup=Xe.prototype.bb,Xe.prototype.getError=function(){return this.h||this.a.getError()},Xe.prototype.getError=Xe.prototype.getError,Xe.prototype.H=function(Z,re,ye){this.a.H(Z,re,ye),this.b=this.c=-1},Xe.prototype.setBlock=Xe.prototype.H,Xe.prototype.reset=function(){this.a.reset(),this.b=this.c=-1},Xe.prototype.reset=Xe.prototype.reset,Xe.prototype.advance=function(Z){this.a.advance(Z)},Xe.prototype.advance=Xe.prototype.advance,Xe.prototype.oa=function(){if(this.a.ya())return!1;if(this.getError())return A("Decoder hit an error"),!1;this.O=this.a.B();var Z=this.a.o(),re=Z>>>3;return Z&=7,Z!=0&&Z!=5&&Z!=1&&Z!=2&&Z!=3&&Z!=4?(A("Invalid wire type: %s (at position %s)",Z,this.O),this.h=!0,!1):(this.c=re,this.b=Z,!0)},Xe.prototype.nextField=Xe.prototype.oa,Xe.prototype.Oa=function(){this.a.mb(this.c<<3|this.b)},Xe.prototype.unskipHeader=Xe.prototype.Oa,Xe.prototype.Lc=function(){var Z=this.c;for(this.Oa();this.oa()&&this.c==Z;)this.C();this.a.ya()||this.Oa()},Xe.prototype.skipMatchingFields=Xe.prototype.Lc,Xe.prototype.lb=function(){this.b!=0?(A("Invalid wire type for skipVarintField"),this.C()):this.a.kb()},Xe.prototype.skipVarintField=Xe.prototype.lb,Xe.prototype.gb=function(){if(this.b!=2)A("Invalid wire type for skipDelimitedField"),this.C();else{var Z=this.a.o();this.a.advance(Z)}},Xe.prototype.skipDelimitedField=Xe.prototype.gb,Xe.prototype.hb=function(){this.b!=5?(A("Invalid wire type for skipFixed32Field"),this.C()):this.a.advance(4)},Xe.prototype.skipFixed32Field=Xe.prototype.hb,Xe.prototype.ib=function(){this.b!=1?(A("Invalid wire type for skipFixed64Field"),this.C()):this.a.advance(8)},Xe.prototype.skipFixed64Field=Xe.prototype.ib,Xe.prototype.jb=function(){var Z=this.c;do{if(!this.oa()){A("Unmatched start-group tag: stream EOF"),this.h=!0;break}if(this.b==4){this.c!=Z&&(A("Unmatched end-group tag"),this.h=!0);break}this.C()}while(!0)},Xe.prototype.skipGroup=Xe.prototype.jb,Xe.prototype.C=function(){switch(this.b){case 0:this.lb();break;case 1:this.ib();break;case 2:this.gb();break;case 5:this.hb();break;case 3:this.jb();break;default:A("Invalid wire encoding for field.")}},Xe.prototype.skipField=Xe.prototype.C,Xe.prototype.Hc=function(Z,re){this.v===null&&(this.v={}),P(!this.v[Z]),this.v[Z]=re},Xe.prototype.registerReadCallback=Xe.prototype.Hc,Xe.prototype.Ic=function(Z){return P(this.v!==null),Z=this.v[Z],P(Z),Z(this)},Xe.prototype.runReadCallback=Xe.prototype.Ic,Xe.prototype.Yb=function(Z,re){P(this.b==2);var ye=this.a.c,Ye=this.a.o();Ye=this.a.B()+Ye,this.a.setEnd(Ye),re(Z,this),this.a.Ma(Ye),this.a.setEnd(ye)},Xe.prototype.readMessage=Xe.prototype.Yb,Xe.prototype.Ub=function(Z,re,ye){P(this.b==3),P(this.c==Z),ye(re,this),this.h||this.b==4||(A("Group submessage did not end with an END_GROUP tag"),this.h=!0)},Xe.prototype.readGroup=Xe.prototype.Ub,Xe.prototype.Gb=function(){P(this.b==2);var Z=this.a.o(),re=this.a.B(),ye=re+Z;return Z=kt(this.a.Y(),re,Z),this.a.Ma(ye),Z},Xe.prototype.getFieldDecoder=Xe.prototype.Gb,Xe.prototype.P=function(){return P(this.b==0),this.a.da()},Xe.prototype.readInt32=Xe.prototype.P,Xe.prototype.Wb=function(){return P(this.b==0),this.a.Ea()},Xe.prototype.readInt32String=Xe.prototype.Wb,Xe.prototype.ba=function(){return P(this.b==0),this.a.sa()},Xe.prototype.readInt64=Xe.prototype.ba,Xe.prototype.ca=function(){return P(this.b==0),this.a.Fa()},Xe.prototype.readInt64String=Xe.prototype.ca,Xe.prototype.m=function(){return P(this.b==0),this.a.o()},Xe.prototype.readUint32=Xe.prototype.m,Xe.prototype.Fc=function(){return P(this.b==0),this.a.O()},Xe.prototype.readUint32String=Xe.prototype.Fc,Xe.prototype.ga=function(){return P(this.b==0),this.a.Ga()},Xe.prototype.readUint64=Xe.prototype.ga,Xe.prototype.ha=function(){return P(this.b==0),this.a.Ha()},Xe.prototype.readUint64String=Xe.prototype.ha,Xe.prototype.zc=function(){return P(this.b==0),this.a.Ia()},Xe.prototype.readSint32=Xe.prototype.zc,Xe.prototype.Ac=function(){return P(this.b==0),this.a.Ja()},Xe.prototype.readSint64=Xe.prototype.Ac,Xe.prototype.Bc=function(){return P(this.b==0),this.a.Ka()},Xe.prototype.readSint64String=Xe.prototype.Bc,Xe.prototype.Rb=function(){return P(this.b==5),this.a.m()},Xe.prototype.readFixed32=Xe.prototype.Rb,Xe.prototype.Sb=function(){return P(this.b==1),this.a.ga()},Xe.prototype.readFixed64=Xe.prototype.Sb,Xe.prototype.Tb=function(){return P(this.b==1),this.a.ha()},Xe.prototype.readFixed64String=Xe.prototype.Tb,Xe.prototype.vc=function(){return P(this.b==5),this.a.P()},Xe.prototype.readSfixed32=Xe.prototype.vc,Xe.prototype.wc=function(){return P(this.b==5),this.a.P().toString()},Xe.prototype.readSfixed32String=Xe.prototype.wc,Xe.prototype.xc=function(){return P(this.b==1),this.a.ba()},Xe.prototype.readSfixed64=Xe.prototype.xc,Xe.prototype.yc=function(){return P(this.b==1),this.a.ca()},Xe.prototype.readSfixed64String=Xe.prototype.yc,Xe.prototype.aa=function(){return P(this.b==5),this.a.aa()},Xe.prototype.readFloat=Xe.prototype.aa,Xe.prototype.Z=function(){return P(this.b==1),this.a.Z()},Xe.prototype.readDouble=Xe.prototype.Z,Xe.prototype.pa=function(){return P(this.b==0),!!this.a.o()},Xe.prototype.readBool=Xe.prototype.pa,Xe.prototype.ra=function(){return P(this.b==0),this.a.sa()},Xe.prototype.readEnum=Xe.prototype.ra,Xe.prototype.fa=function(){P(this.b==2);var Z=this.a.o();return this.a.fa(Z)},Xe.prototype.readString=Xe.prototype.fa,Xe.prototype.qa=function(){P(this.b==2);var Z=this.a.o();return this.a.qa(Z)},Xe.prototype.readBytes=Xe.prototype.qa,Xe.prototype.ia=function(){return P(this.b==0),this.a.ia()},Xe.prototype.readVarintHash64=Xe.prototype.ia,Xe.prototype.Cc=function(){return P(this.b==0),this.a.fb()},Xe.prototype.readSintHash64=Xe.prototype.Cc,Xe.prototype.w=function(Z){return P(this.b==0),this.a.w(Z)},Xe.prototype.readSplitVarint64=Xe.prototype.w,Xe.prototype.ea=function(Z){return P(this.b==0),this.a.w(function(re,ye){return pe(re,ye,Z)})},Xe.prototype.readSplitZigzagVarint64=Xe.prototype.ea,Xe.prototype.$=function(){return P(this.b==1),this.a.$()},Xe.prototype.readFixedHash64=Xe.prototype.$,Xe.prototype.ta=function(Z){return P(this.b==1),this.a.ta(Z)},Xe.prototype.readSplitFixed64=Xe.prototype.ta;function Pt(Z,re){P(Z.b==2);var ye=Z.a.o();ye=Z.a.B()+ye;for(var Ye=[];Z.a.B()<ye;)Ye.push(re.call(Z.a));return Ye}Xe.prototype.gc=function(){return Pt(this,this.a.da)},Xe.prototype.readPackedInt32=Xe.prototype.gc,Xe.prototype.hc=function(){return Pt(this,this.a.Ea)},Xe.prototype.readPackedInt32String=Xe.prototype.hc,Xe.prototype.ic=function(){return Pt(this,this.a.sa)},Xe.prototype.readPackedInt64=Xe.prototype.ic,Xe.prototype.jc=function(){return Pt(this,this.a.Fa)},Xe.prototype.readPackedInt64String=Xe.prototype.jc,Xe.prototype.qc=function(){return Pt(this,this.a.o)},Xe.prototype.readPackedUint32=Xe.prototype.qc,Xe.prototype.rc=function(){return Pt(this,this.a.O)},Xe.prototype.readPackedUint32String=Xe.prototype.rc,Xe.prototype.sc=function(){return Pt(this,this.a.Ga)},Xe.prototype.readPackedUint64=Xe.prototype.sc,Xe.prototype.tc=function(){return Pt(this,this.a.Ha)},Xe.prototype.readPackedUint64String=Xe.prototype.tc,Xe.prototype.nc=function(){return Pt(this,this.a.Ia)},Xe.prototype.readPackedSint32=Xe.prototype.nc,Xe.prototype.oc=function(){return Pt(this,this.a.Ja)},Xe.prototype.readPackedSint64=Xe.prototype.oc,Xe.prototype.pc=function(){return Pt(this,this.a.Ka)},Xe.prototype.readPackedSint64String=Xe.prototype.pc,Xe.prototype.bc=function(){return Pt(this,this.a.m)},Xe.prototype.readPackedFixed32=Xe.prototype.bc,Xe.prototype.cc=function(){return Pt(this,this.a.ga)},Xe.prototype.readPackedFixed64=Xe.prototype.cc,Xe.prototype.dc=function(){return Pt(this,this.a.ha)},Xe.prototype.readPackedFixed64String=Xe.prototype.dc,Xe.prototype.kc=function(){return Pt(this,this.a.P)},Xe.prototype.readPackedSfixed32=Xe.prototype.kc,Xe.prototype.lc=function(){return Pt(this,this.a.ba)},Xe.prototype.readPackedSfixed64=Xe.prototype.lc,Xe.prototype.mc=function(){return Pt(this,this.a.ca)},Xe.prototype.readPackedSfixed64String=Xe.prototype.mc,Xe.prototype.fc=function(){return Pt(this,this.a.aa)},Xe.prototype.readPackedFloat=Xe.prototype.fc,Xe.prototype.$b=function(){return Pt(this,this.a.Z)},Xe.prototype.readPackedDouble=Xe.prototype.$b,Xe.prototype.Zb=function(){return Pt(this,this.a.pa)},Xe.prototype.readPackedBool=Xe.prototype.Zb,Xe.prototype.ac=function(){return Pt(this,this.a.ra)},Xe.prototype.readPackedEnum=Xe.prototype.ac,Xe.prototype.uc=function(){return Pt(this,this.a.ia)},Xe.prototype.readPackedVarintHash64=Xe.prototype.uc,Xe.prototype.ec=function(){return Pt(this,this.a.$)},Xe.prototype.readPackedFixedHash64=Xe.prototype.ec;function Jt(Z,re,ye,Ye,gt){this.ma=Z,this.Ba=re,this.la=ye,this.Na=Ye,this.na=gt}f("jspb.ExtensionFieldInfo",Jt,void 0);function zt(Z,re,ye,Ye,gt,Dt){this.Za=Z,this.za=re,this.Aa=ye,this.Wa=Ye,this.Ab=gt,this.Nb=Dt}f("jspb.ExtensionFieldBinaryInfo",zt,void 0),Jt.prototype.F=function(){return!!this.la},Jt.prototype.isMessageType=Jt.prototype.F;function Bt(){}f("jspb.Message",Bt,void 0),Bt.GENERATE_TO_OBJECT=!0,Bt.GENERATE_FROM_OBJECT=!0;var Mr=typeof Uint8Array=="function";Bt.prototype.Ib=function(){return this.b},Bt.prototype.getJsPbMessageId=Bt.prototype.Ib,Bt.initialize=function(Z,re,ye,Ye,gt,Dt){Z.f=null,re||(re=ye?[ye]:[]),Z.b=ye?String(ye):void 0,Z.D=ye===0?-1:0,Z.u=re;e:{if(ye=Z.u.length,re=-1,ye&&(re=ye-1,ye=Z.u[re],!(ye===null||typeof ye!="object"||Array.isArray(ye)||Mr&&ye instanceof Uint8Array))){Z.G=re-Z.D,Z.i=ye;break e}-1<Ye?(Z.G=Math.max(Ye,re+1-Z.D),Z.i=null):Z.G=Number.MAX_VALUE}if(Z.a={},gt)for(Ye=0;Ye<gt.length;Ye++)re=gt[Ye],re<Z.G?(re+=Z.D,Z.u[re]=Z.u[re]||Be):(We(Z),Z.i[re]=Z.i[re]||Be);if(Dt&&Dt.length)for(Ye=0;Ye<Dt.length;Ye++)qn(Z,Dt[Ye])};var Be=Object.freeze?Object.freeze([]):[];function We(Z){var re=Z.G+Z.D;Z.u[re]||(Z.i=Z.u[re]={})}function dt(Z,re,ye){for(var Ye=[],gt=0;gt<Z.length;gt++)Ye[gt]=re.call(Z[gt],ye,Z[gt]);return Ye}Bt.toObjectList=dt,Bt.toObjectExtension=function(Z,re,ye,Ye,gt){for(var Dt in ye){var pr=ye[Dt],Gr=Ye.call(Z,pr);if(Gr!=null){for(var rn in pr.Ba)if(pr.Ba.hasOwnProperty(rn))break;re[rn]=pr.Na?pr.na?dt(Gr,pr.Na,gt):pr.Na(gt,Gr):Gr}}},Bt.serializeBinaryExtensions=function(Z,re,ye,Ye){for(var gt in ye){var Dt=ye[gt],pr=Dt.Za;if(!Dt.Aa)throw Error("Message extension present that was generated without binary serialization support");var Gr=Ye.call(Z,pr);if(Gr!=null)if(pr.F())if(Dt.Wa)Dt.Aa.call(re,pr.ma,Gr,Dt.Wa);else throw Error("Message extension present holding submessage without binary support enabled, and message is being serialized to binary format");else Dt.Aa.call(re,pr.ma,Gr)}},Bt.readBinaryExtension=function(Z,re,ye,Ye,gt){var Dt=ye[re.c];if(Dt){if(ye=Dt.Za,!Dt.za)throw Error("Deserializing extension whose generated code does not support binary format");if(ye.F()){var pr=new ye.la;Dt.za.call(re,pr,Dt.Ab)}else pr=Dt.za.call(re);ye.na&&!Dt.Nb?(re=Ye.call(Z,ye))?re.push(pr):gt.call(Z,ye,[pr]):gt.call(Z,ye,pr)}else re.C()};function Tt(Z,re){if(re<Z.G){re+=Z.D;var ye=Z.u[re];return ye===Be?Z.u[re]=[]:ye}if(Z.i)return ye=Z.i[re],ye===Be?Z.i[re]=[]:ye}Bt.getField=Tt,Bt.getRepeatedField=function(Z,re){return Tt(Z,re)};function nr(Z,re){return Z=Tt(Z,re),Z==null?Z:+Z}Bt.getOptionalFloatingPointField=nr;function Ar(Z,re){return Z=Tt(Z,re),Z==null?Z:!!Z}Bt.getBooleanField=Ar,Bt.getRepeatedFloatingPointField=function(Z,re){var ye=Tt(Z,re);if(Z.a||(Z.a={}),!Z.a[re]){for(var Ye=0;Ye<ye.length;Ye++)ye[Ye]=+ye[Ye];Z.a[re]=!0}return ye},Bt.getRepeatedBooleanField=function(Z,re){var ye=Tt(Z,re);if(Z.a||(Z.a={}),!Z.a[re]){for(var Ye=0;Ye<ye.length;Ye++)ye[Ye]=!!ye[Ye];Z.a[re]=!0}return ye};function Qr(Z){return Z==null||typeof Z=="string"?Z:Mr&&Z instanceof Uint8Array?W(Z):(A("Cannot coerce to b64 string: "+h(Z)),null)}Bt.bytesAsB64=Qr;function Si(Z){return Z==null||Z instanceof Uint8Array?Z:typeof Z=="string"?Y(Z):(A("Cannot coerce to Uint8Array: "+h(Z)),null)}Bt.bytesAsU8=Si,Bt.bytesListAsB64=function(Z){return oi(Z),Z.length&&typeof Z[0]!="string"?S(Z,Qr):Z},Bt.bytesListAsU8=function(Z){return oi(Z),!Z.length||Z[0]instanceof Uint8Array?Z:S(Z,Si)};function oi(Z){if(Z&&1<Z.length){var re=h(Z[0]);b(Z,function(ye){h(ye)!=re&&A("Inconsistent type in JSPB repeated field array. Got "+h(ye)+" expected "+re)})}}function Yr(Z,re,ye){return Z=Tt(Z,re),Z??ye}Bt.getFieldWithDefault=Yr,Bt.getBooleanFieldWithDefault=function(Z,re,ye){return Z=Ar(Z,re),Z??ye},Bt.getFloatingPointFieldWithDefault=function(Z,re,ye){return Z=nr(Z,re),Z??ye},Bt.getFieldProto3=Yr,Bt.getMapField=function(Z,re,ye,Ye){if(Z.f||(Z.f={}),re in Z.f)return Z.f[re];var gt=Tt(Z,re);if(!gt){if(ye)return;gt=[],vi(Z,re,gt)}return Z.f[re]=new D(gt,Ye)};function vi(Z,re,ye){return R(Z,Bt),re<Z.G?Z.u[re+Z.D]=ye:(We(Z),Z.i[re]=ye),Z}Bt.setField=vi,Bt.setProto3IntField=function(Z,re,ye){return rr(Z,re,ye,0)},Bt.setProto3FloatField=function(Z,re,ye){return rr(Z,re,ye,0)},Bt.setProto3BooleanField=function(Z,re,ye){return rr(Z,re,ye,!1)},Bt.setProto3StringField=function(Z,re,ye){return rr(Z,re,ye,"")},Bt.setProto3BytesField=function(Z,re,ye){return rr(Z,re,ye,"")},Bt.setProto3EnumField=function(Z,re,ye){return rr(Z,re,ye,0)},Bt.setProto3StringIntField=function(Z,re,ye){return rr(Z,re,ye,"0")};function rr(Z,re,ye,Ye){return R(Z,Bt),ye!==Ye?vi(Z,re,ye):re<Z.G?Z.u[re+Z.D]=null:(We(Z),delete Z.i[re]),Z}Bt.addToRepeatedField=function(Z,re,ye,Ye){return R(Z,Bt),re=Tt(Z,re),Ye!=null?re.splice(Ye,0,ye):re.push(ye),Z};function Ji(Z,re,ye,Ye){return R(Z,Bt),(ye=qn(Z,ye))&&ye!==re&&Ye!==void 0&&(Z.f&&ye in Z.f&&(Z.f[ye]=void 0),vi(Z,ye,void 0)),vi(Z,re,Ye)}Bt.setOneofField=Ji;function qn(Z,re){for(var ye,Ye,gt=0;gt<re.length;gt++){var Dt=re[gt],pr=Tt(Z,Dt);pr!=null&&(ye=Dt,Ye=pr,vi(Z,Dt,void 0))}return ye?(vi(Z,ye,Ye),ye):0}Bt.computeOneofCase=qn,Bt.getWrapperField=function(Z,re,ye,Ye){if(Z.f||(Z.f={}),!Z.f[ye]){var gt=Tt(Z,ye);(Ye||gt)&&(Z.f[ye]=new re(gt))}return Z.f[ye]},Bt.getRepeatedWrapperField=function(Z,re,ye){return ri(Z,re,ye),re=Z.f[ye],re==Be&&(re=Z.f[ye]=[]),re};function ri(Z,re,ye){if(Z.f||(Z.f={}),!Z.f[ye]){for(var Ye=Tt(Z,ye),gt=[],Dt=0;Dt<Ye.length;Dt++)gt[Dt]=new re(Ye[Dt]);Z.f[ye]=gt}}Bt.setWrapperField=function(Z,re,ye){R(Z,Bt),Z.f||(Z.f={});var Ye=ye&&ye.g();return Z.f[re]=ye,vi(Z,re,Ye)},Bt.setOneofWrapperField=function(Z,re,ye,Ye){R(Z,Bt),Z.f||(Z.f={});var gt=Ye&&Ye.g();return Z.f[re]=Ye,Ji(Z,re,ye,gt)},Bt.setRepeatedWrapperField=function(Z,re,ye){R(Z,Bt),Z.f||(Z.f={}),ye=ye||[];for(var Ye=[],gt=0;gt<ye.length;gt++)Ye[gt]=ye[gt].g();return Z.f[re]=ye,vi(Z,re,Ye)},Bt.addToRepeatedWrapperField=function(Z,re,ye,Ye,gt){ri(Z,Ye,re);var Dt=Z.f[re];return Dt||(Dt=Z.f[re]=[]),ye=ye||new Ye,Z=Tt(Z,re),gt!=null?(Dt.splice(gt,0,ye),Z.splice(gt,0,ye.g())):(Dt.push(ye),Z.push(ye.g())),ye},Bt.toMap=function(Z,re,ye,Ye){for(var gt={},Dt=0;Dt<Z.length;Dt++)gt[re.call(Z[Dt])]=ye?ye.call(Z[Dt],Ye,Z[Dt]):Z[Dt];return gt};function eo(Z){if(Z.f)for(var re in Z.f){var ye=Z.f[re];if(Array.isArray(ye))for(var Ye=0;Ye<ye.length;Ye++)ye[Ye]&&ye[Ye].g();else ye&&ye.g()}}Bt.prototype.g=function(){return eo(this),this.u},Bt.prototype.toArray=Bt.prototype.g,Bt.prototype.toString=function(){return eo(this),this.u.toString()},Bt.prototype.getExtension=function(Z){if(this.i){this.f||(this.f={});var re=Z.ma;if(Z.na){if(Z.F())return this.f[re]||(this.f[re]=S(this.i[re]||[],function(ye){return new Z.la(ye)})),this.f[re]}else if(Z.F())return!this.f[re]&&this.i[re]&&(this.f[re]=new Z.la(this.i[re])),this.f[re];return this.i[re]}},Bt.prototype.getExtension=Bt.prototype.getExtension,Bt.prototype.Kc=function(Z,re){this.f||(this.f={}),We(this);var ye=Z.ma;return Z.na?(re=re||[],Z.F()?(this.f[ye]=re,this.i[ye]=S(re,function(Ye){return Ye.g()})):this.i[ye]=re):Z.F()?(this.f[ye]=re,this.i[ye]=re&&re.g()):this.i[ye]=re,this},Bt.prototype.setExtension=Bt.prototype.Kc,Bt.difference=function(Z,re){if(!(Z instanceof re.constructor))throw Error("Messages have different types.");var ye=Z.g();re=re.g();var Ye=[],gt=0,Dt=ye.length>re.length?ye.length:re.length;for(Z.b&&(Ye[0]=Z.b,gt=1);gt<Dt;gt++)mt(ye[gt],re[gt])||(Ye[gt]=re[gt]);return new Z.constructor(Ye)},Bt.equals=function(Z,re){return Z==re||!(!Z||!re)&&Z instanceof re.constructor&&mt(Z.g(),re.g())};function xn(Z,re){Z=Z||{},re=re||{};var ye={},Ye;for(Ye in Z)ye[Ye]=0;for(Ye in re)ye[Ye]=0;for(Ye in ye)if(!mt(Z[Ye],re[Ye]))return!1;return!0}Bt.compareExtensions=xn;function mt(Z,re){if(Z==re)return!0;if(!p(Z)||!p(re))return typeof Z=="number"&&isNaN(Z)||typeof re=="number"&&isNaN(re)?String(Z)==String(re):!1;if(Z.constructor!=re.constructor)return!1;if(Mr&&Z.constructor===Uint8Array){if(Z.length!=re.length)return!1;for(var ye=0;ye<Z.length;ye++)if(Z[ye]!=re[ye])return!1;return!0}if(Z.constructor===Array){var Ye=void 0,gt=void 0,Dt=Math.max(Z.length,re.length);for(ye=0;ye<Dt;ye++){var pr=Z[ye],Gr=re[ye];if(pr&&pr.constructor==Object&&(P(Ye===void 0),P(ye===Z.length-1),Ye=pr,pr=void 0),Gr&&Gr.constructor==Object&&(P(gt===void 0),P(ye===re.length-1),gt=Gr,Gr=void 0),!mt(pr,Gr))return!1}return Ye||gt?(Ye=Ye||{},gt=gt||{},xn(Ye,gt)):!0}if(Z.constructor===Object)return xn(Z,re);throw Error("Invalid type in JSPB array")}Bt.compareFields=mt,Bt.prototype.Bb=function(){return gr(this)},Bt.prototype.cloneMessage=Bt.prototype.Bb,Bt.prototype.clone=function(){return gr(this)},Bt.prototype.clone=Bt.prototype.clone,Bt.clone=function(Z){return gr(Z)};function gr(Z){return new Z.constructor(ce(Z.g()))}Bt.copyInto=function(Z,re){R(Z,Bt),R(re,Bt),P(Z.constructor==re.constructor,"Copy source and target message should have the same type."),Z=gr(Z);for(var ye=re.g(),Ye=Z.g(),gt=ye.length=0;gt<Ye.length;gt++)ye[gt]=Ye[gt];re.f=Z.f,re.i=Z.i};function ce(Z){if(Array.isArray(Z)){for(var re=Array(Z.length),ye=0;ye<Z.length;ye++){var Ye=Z[ye];Ye!=null&&(re[ye]=typeof Ye=="object"?ce(P(Ye)):Ye)}return re}if(Mr&&Z instanceof Uint8Array)return new Uint8Array(Z);re={};for(ye in Z)Ye=Z[ye],Ye!=null&&(re[ye]=typeof Ye=="object"?ce(P(Ye)):Ye);return re}Bt.registerMessageType=function(Z,re){re.we=Z};var fr={dump:function(Z){return R(Z,Bt,"jspb.Message instance expected"),P(Z.getExtension,"Only unobfuscated and unoptimized compilation modes supported."),fr.X(Z)}};f("jspb.debug.dump",fr.dump,void 0),fr.X=function(Z){var re=h(Z);if(re=="number"||re=="string"||re=="boolean"||re=="null"||re=="undefined"||typeof Uint8Array<"u"&&Z instanceof Uint8Array)return Z;if(re=="array")return E(Z),S(Z,fr.X);if(Z instanceof D){var ye={};Z=Z.entries();for(var Ye=Z.next();!Ye.done;Ye=Z.next())ye[Ye.value[0]]=fr.X(Ye.value[1]);return ye}R(Z,Bt,"Only messages expected: "+Z),re=Z.constructor;var gt={$name:re.name||re.displayName};for(Gr in re.prototype){var Dt=/^get([A-Z]\w*)/.exec(Gr);if(Dt&&Gr!="getExtension"&&Gr!="getJsPbMessageId"){var pr="has"+Dt[1];(!Z[pr]||Z[pr]())&&(pr=Z[Gr](),gt[fr.$a(Dt[1])]=fr.X(pr))}}if(Z.extensionObject_)return gt.$extensions="Recursive dumping of extensions not supported in compiled code. Switch to uncompiled or dump extension object directly",gt;for(Ye in re.extensions)if(/^\d+$/.test(Ye)){pr=re.extensions[Ye];var Gr=Z.getExtension(pr);Dt=void 0,pr=pr.Ba;var rn=[],ro=0;for(Dt in pr)rn[ro++]=Dt;Dt=rn[0],Gr!=null&&(ye||(ye=gt.$extensions={}),ye[fr.$a(Dt)]=fr.X(Gr))}return gt},fr.$a=function(Z){return Z.replace(/^[A-Z]/,function(re){return re.toLowerCase()})};function Yt(){this.a=[]}f("jspb.BinaryEncoder",Yt,void 0),Yt.prototype.length=function(){return this.a.length},Yt.prototype.length=Yt.prototype.length,Yt.prototype.end=function(){var Z=this.a;return this.a=[],Z},Yt.prototype.end=Yt.prototype.end,Yt.prototype.l=function(Z,re){for(P(Z==Math.floor(Z)),P(re==Math.floor(re)),P(0<=Z&&4294967296>Z),P(0<=re&&4294967296>re);0<re||127<Z;)this.a.push(Z&127|128),Z=(Z>>>7|re<<25)>>>0,re>>>=7;this.a.push(Z)},Yt.prototype.writeSplitVarint64=Yt.prototype.l,Yt.prototype.A=function(Z,re){P(Z==Math.floor(Z)),P(re==Math.floor(re)),P(0<=Z&&4294967296>Z),P(0<=re&&4294967296>re),this.s(Z),this.s(re)},Yt.prototype.writeSplitFixed64=Yt.prototype.A,Yt.prototype.j=function(Z){for(P(Z==Math.floor(Z)),P(0<=Z&&4294967296>Z);127<Z;)this.a.push(Z&127|128),Z>>>=7;this.a.push(Z)},Yt.prototype.writeUnsignedVarint32=Yt.prototype.j,Yt.prototype.M=function(Z){if(P(Z==Math.floor(Z)),P(-2147483648<=Z&&2147483648>Z),0<=Z)this.j(Z);else{for(var re=0;9>re;re++)this.a.push(Z&127|128),Z>>=7;this.a.push(1)}},Yt.prototype.writeSignedVarint32=Yt.prototype.M,Yt.prototype.va=function(Z){P(Z==Math.floor(Z)),P(0<=Z&&18446744073709552e3>Z),Re(Z),this.l(de,ge)},Yt.prototype.writeUnsignedVarint64=Yt.prototype.va,Yt.prototype.ua=function(Z){P(Z==Math.floor(Z)),P(-9223372036854776e3<=Z&&9223372036854776e3>Z),Re(Z),this.l(de,ge)},Yt.prototype.writeSignedVarint64=Yt.prototype.ua,Yt.prototype.wa=function(Z){P(Z==Math.floor(Z)),P(-2147483648<=Z&&2147483648>Z),this.j((Z<<1^Z>>31)>>>0)},Yt.prototype.writeZigzagVarint32=Yt.prototype.wa,Yt.prototype.xa=function(Z){P(Z==Math.floor(Z)),P(-9223372036854776e3<=Z&&9223372036854776e3>Z),Ae(Z),this.l(de,ge)},Yt.prototype.writeZigzagVarint64=Yt.prototype.xa,Yt.prototype.Ta=function(Z){this.W(xt(Z))},Yt.prototype.writeZigzagVarint64String=Yt.prototype.Ta,Yt.prototype.W=function(Z){var re=this;Te(Z),Ne(de,ge,function(ye,Ye){re.l(ye>>>0,Ye>>>0)})},Yt.prototype.writeZigzagVarintHash64=Yt.prototype.W,Yt.prototype.be=function(Z){P(Z==Math.floor(Z)),P(0<=Z&&256>Z),this.a.push(Z>>>0&255)},Yt.prototype.writeUint8=Yt.prototype.be,Yt.prototype.ae=function(Z){P(Z==Math.floor(Z)),P(0<=Z&&65536>Z),this.a.push(Z>>>0&255),this.a.push(Z>>>8&255)},Yt.prototype.writeUint16=Yt.prototype.ae,Yt.prototype.s=function(Z){P(Z==Math.floor(Z)),P(0<=Z&&4294967296>Z),this.a.push(Z>>>0&255),this.a.push(Z>>>8&255),this.a.push(Z>>>16&255),this.a.push(Z>>>24&255)},Yt.prototype.writeUint32=Yt.prototype.s,Yt.prototype.V=function(Z){P(Z==Math.floor(Z)),P(0<=Z&&18446744073709552e3>Z),Ee(Z),this.s(de),this.s(ge)},Yt.prototype.writeUint64=Yt.prototype.V,Yt.prototype.Qc=function(Z){P(Z==Math.floor(Z)),P(-128<=Z&&128>Z),this.a.push(Z>>>0&255)},Yt.prototype.writeInt8=Yt.prototype.Qc,Yt.prototype.Pc=function(Z){P(Z==Math.floor(Z)),P(-32768<=Z&&32768>Z),this.a.push(Z>>>0&255),this.a.push(Z>>>8&255)},Yt.prototype.writeInt16=Yt.prototype.Pc,Yt.prototype.S=function(Z){P(Z==Math.floor(Z)),P(-2147483648<=Z&&2147483648>Z),this.a.push(Z>>>0&255),this.a.push(Z>>>8&255),this.a.push(Z>>>16&255),this.a.push(Z>>>24&255)},Yt.prototype.writeInt32=Yt.prototype.S,Yt.prototype.T=function(Z){P(Z==Math.floor(Z)),P(-9223372036854776e3<=Z&&9223372036854776e3>Z),Re(Z),this.A(de,ge)},Yt.prototype.writeInt64=Yt.prototype.T,Yt.prototype.ka=function(Z){P(Z==Math.floor(Z)),P(-9223372036854776e3<=+Z&&9223372036854776e3>+Z),Te(xt(Z)),this.A(de,ge)},Yt.prototype.writeInt64String=Yt.prototype.ka,Yt.prototype.L=function(Z){P(Z===1/0||Z===-1/0||isNaN(Z)||-34028234663852886e22<=Z&&34028234663852886e22>=Z),Pe(Z),this.s(de)},Yt.prototype.writeFloat=Yt.prototype.L,Yt.prototype.J=function(Z){P(Z===1/0||Z===-1/0||isNaN(Z)||-17976931348623157e292<=Z&&17976931348623157e292>=Z),we(Z),this.s(de),this.s(ge)},Yt.prototype.writeDouble=Yt.prototype.J,Yt.prototype.I=function(Z){P(typeof Z=="boolean"||typeof Z=="number"),this.a.push(Z?1:0)},Yt.prototype.writeBool=Yt.prototype.I,Yt.prototype.R=function(Z){P(Z==Math.floor(Z)),P(-2147483648<=Z&&2147483648>Z),this.M(Z)},Yt.prototype.writeEnum=Yt.prototype.R,Yt.prototype.ja=function(Z){this.a.push.apply(this.a,Z)},Yt.prototype.writeBytes=Yt.prototype.ja,Yt.prototype.N=function(Z){Te(Z),this.l(de,ge)},Yt.prototype.writeVarintHash64=Yt.prototype.N,Yt.prototype.K=function(Z){Te(Z),this.s(de),this.s(ge)},Yt.prototype.writeFixedHash64=Yt.prototype.K,Yt.prototype.U=function(Z){var re=this.a.length;x(Z);for(var ye=0;ye<Z.length;ye++){var Ye=Z.charCodeAt(ye);if(128>Ye)this.a.push(Ye);else if(2048>Ye)this.a.push(Ye>>6|192),this.a.push(Ye&63|128);else if(65536>Ye)if(55296<=Ye&&56319>=Ye&&ye+1<Z.length){var gt=Z.charCodeAt(ye+1);56320<=gt&&57343>=gt&&(Ye=1024*(Ye-55296)+gt-56320+65536,this.a.push(Ye>>18|240),this.a.push(Ye>>12&63|128),this.a.push(Ye>>6&63|128),this.a.push(Ye&63|128),ye++)}else this.a.push(Ye>>12|224),this.a.push(Ye>>6&63|128),this.a.push(Ye&63|128)}return this.a.length-re},Yt.prototype.writeString=Yt.prototype.U;function Lr(Z,re){this.lo=Z,this.hi=re}f("jspb.arith.UInt64",Lr,void 0),Lr.prototype.cmp=function(Z){return this.hi<Z.hi||this.hi==Z.hi&&this.lo<Z.lo?-1:this.hi==Z.hi&&this.lo==Z.lo?0:1},Lr.prototype.cmp=Lr.prototype.cmp,Lr.prototype.La=function(){return new Lr((this.lo>>>1|(this.hi&1)<<31)>>>0,this.hi>>>1>>>0)},Lr.prototype.rightShift=Lr.prototype.La,Lr.prototype.Da=function(){return new Lr(this.lo<<1>>>0,(this.hi<<1|this.lo>>>31)>>>0)},Lr.prototype.leftShift=Lr.prototype.Da,Lr.prototype.cb=function(){return!!(this.hi&2147483648)},Lr.prototype.msb=Lr.prototype.cb,Lr.prototype.Ob=function(){return!!(this.lo&1)},Lr.prototype.lsb=Lr.prototype.Ob,Lr.prototype.Ua=function(){return this.lo==0&&this.hi==0},Lr.prototype.zero=Lr.prototype.Ua,Lr.prototype.add=function(Z){return new Lr((this.lo+Z.lo&4294967295)>>>0>>>0,((this.hi+Z.hi&4294967295)>>>0)+(4294967296<=this.lo+Z.lo?1:0)>>>0)},Lr.prototype.add=Lr.prototype.add,Lr.prototype.sub=function(Z){return new Lr((this.lo-Z.lo&4294967295)>>>0>>>0,((this.hi-Z.hi&4294967295)>>>0)-(0>this.lo-Z.lo?1:0)>>>0)},Lr.prototype.sub=Lr.prototype.sub;function Cr(Z,re){var ye=Z&65535;Z>>>=16;var Ye=re&65535,gt=re>>>16;for(re=ye*Ye+65536*(ye*gt&65535)+65536*(Z*Ye&65535),ye=Z*gt+(ye*gt>>>16)+(Z*Ye>>>16);4294967296<=re;)re-=4294967296,ye+=1;return new Lr(re>>>0,ye>>>0)}Lr.mul32x32=Cr,Lr.prototype.eb=function(Z){var re=Cr(this.lo,Z);return Z=Cr(this.hi,Z),Z.hi=Z.lo,Z.lo=0,re.add(Z)},Lr.prototype.mul=Lr.prototype.eb,Lr.prototype.Xa=function(Z){if(Z==0)return[];var re=new Lr(0,0),ye=new Lr(this.lo,this.hi);Z=new Lr(Z,0);for(var Ye=new Lr(1,0);!Z.cb();)Z=Z.Da(),Ye=Ye.Da();for(;!Ye.Ua();)0>=Z.cmp(ye)&&(re=re.add(Ye),ye=ye.sub(Z)),Z=Z.La(),Ye=Ye.La();return[re,ye]},Lr.prototype.div=Lr.prototype.Xa,Lr.prototype.toString=function(){for(var Z="",re=this;!re.Ua();){re=re.Xa(10);var ye=re[0];Z=re[1].lo+Z,re=ye}return Z==""&&(Z="0"),Z},Lr.prototype.toString=Lr.prototype.toString;function zr(Z){for(var re=new Lr(0,0),ye=new Lr(0,0),Ye=0;Ye<Z.length;Ye++){if("0">Z[Ye]||"9"<Z[Ye])return null;ye.lo=parseInt(Z[Ye],10),re=re.eb(10).add(ye)}return re}Lr.fromString=zr,Lr.prototype.clone=function(){return new Lr(this.lo,this.hi)},Lr.prototype.clone=Lr.prototype.clone;function fi(Z,re){this.lo=Z,this.hi=re}f("jspb.arith.Int64",fi,void 0),fi.prototype.add=function(Z){return new fi((this.lo+Z.lo&4294967295)>>>0>>>0,((this.hi+Z.hi&4294967295)>>>0)+(4294967296<=this.lo+Z.lo?1:0)>>>0)},fi.prototype.add=fi.prototype.add,fi.prototype.sub=function(Z){return new fi((this.lo-Z.lo&4294967295)>>>0>>>0,((this.hi-Z.hi&4294967295)>>>0)-(0>this.lo-Z.lo?1:0)>>>0)},fi.prototype.sub=fi.prototype.sub,fi.prototype.clone=function(){return new fi(this.lo,this.hi)},fi.prototype.clone=fi.prototype.clone,fi.prototype.toString=function(){var Z=(this.hi&2147483648)!=0,re=new Lr(this.lo,this.hi);return Z&&(re=new Lr(0,0).sub(re)),(Z?"-":"")+re.toString()},fi.prototype.toString=fi.prototype.toString;function to(Z){var re=0<Z.length&&Z[0]=="-";return re&&(Z=Z.substring(1)),Z=zr(Z),Z===null?null:(re&&(Z=new Lr(0,0).sub(Z)),new fi(Z.lo,Z.hi))}fi.fromString=to;function st(){this.c=[],this.b=0,this.a=new Yt,this.h=[]}f("jspb.BinaryWriter",st,void 0);function zo(Z,re){var ye=Z.a.end();Z.c.push(ye),Z.c.push(re),Z.b+=ye.length+re.length}function hi(Z,re){return sr(Z,re,2),re=Z.a.end(),Z.c.push(re),Z.b+=re.length,re.push(Z.b),re}function si(Z,re){var ye=re.pop();for(ye=Z.b+Z.a.length()-ye,P(0<=ye);127<ye;)re.push(ye&127|128),ye>>>=7,Z.b++;re.push(ye),Z.b++}st.prototype.pb=function(Z,re,ye){zo(this,Z.subarray(re,ye))},st.prototype.writeSerializedMessage=st.prototype.pb,st.prototype.Pb=function(Z,re,ye){Z!=null&&re!=null&&ye!=null&&this.pb(Z,re,ye)},st.prototype.maybeWriteSerializedMessage=st.prototype.Pb,st.prototype.reset=function(){this.c=[],this.a.end(),this.b=0,this.h=[]},st.prototype.reset=st.prototype.reset,st.prototype.ab=function(){P(this.h.length==0);for(var Z=new Uint8Array(this.b+this.a.length()),re=this.c,ye=re.length,Ye=0,gt=0;gt<ye;gt++){var Dt=re[gt];Z.set(Dt,Ye),Ye+=Dt.length}return re=this.a.end(),Z.set(re,Ye),Ye+=re.length,P(Ye==Z.length),this.c=[Z],Z},st.prototype.getResultBuffer=st.prototype.ab,st.prototype.Kb=function(Z){return W(this.ab(),Z)},st.prototype.getResultBase64String=st.prototype.Kb,st.prototype.Va=function(Z){this.h.push(hi(this,Z))},st.prototype.beginSubMessage=st.prototype.Va,st.prototype.Ya=function(){P(0<=this.h.length),si(this,this.h.pop())},st.prototype.endSubMessage=st.prototype.Ya;function sr(Z,re,ye){P(1<=re&&re==Math.floor(re)),Z.a.j(8*re+ye)}st.prototype.Nc=function(Z,re,ye){switch(Z){case 1:this.J(re,ye);break;case 2:this.L(re,ye);break;case 3:this.T(re,ye);break;case 4:this.V(re,ye);break;case 5:this.S(re,ye);break;case 6:this.Qa(re,ye);break;case 7:this.Pa(re,ye);break;case 8:this.I(re,ye);break;case 9:this.U(re,ye);break;case 10:A("Group field type not supported in writeAny()");break;case 11:A("Message field type not supported in writeAny()");break;case 12:this.ja(re,ye);break;case 13:this.s(re,ye);break;case 14:this.R(re,ye);break;case 15:this.Ra(re,ye);break;case 16:this.Sa(re,ye);break;case 17:this.rb(re,ye);break;case 18:this.sb(re,ye);break;case 30:this.K(re,ye);break;case 31:this.N(re,ye);break;default:A("Invalid field type in writeAny()")}},st.prototype.writeAny=st.prototype.Nc;function Ns(Z,re,ye){ye!=null&&(sr(Z,re,0),Z.a.j(ye))}function ts(Z,re,ye){ye!=null&&(sr(Z,re,0),Z.a.M(ye))}st.prototype.S=function(Z,re){re!=null&&(P(-2147483648<=re&&2147483648>re),ts(this,Z,re))},st.prototype.writeInt32=st.prototype.S,st.prototype.ob=function(Z,re){re!=null&&(re=parseInt(re,10),P(-2147483648<=re&&2147483648>re),ts(this,Z,re))},st.prototype.writeInt32String=st.prototype.ob,st.prototype.T=function(Z,re){re!=null&&(P(-9223372036854776e3<=re&&9223372036854776e3>re),re!=null&&(sr(this,Z,0),this.a.ua(re)))},st.prototype.writeInt64=st.prototype.T,st.prototype.ka=function(Z,re){re!=null&&(re=to(re),sr(this,Z,0),this.a.l(re.lo,re.hi))},st.prototype.writeInt64String=st.prototype.ka,st.prototype.s=function(Z,re){re!=null&&(P(0<=re&&4294967296>re),Ns(this,Z,re))},st.prototype.writeUint32=st.prototype.s,st.prototype.ub=function(Z,re){re!=null&&(re=parseInt(re,10),P(0<=re&&4294967296>re),Ns(this,Z,re))},st.prototype.writeUint32String=st.prototype.ub,st.prototype.V=function(Z,re){re!=null&&(P(0<=re&&18446744073709552e3>re),re!=null&&(sr(this,Z,0),this.a.va(re)))},st.prototype.writeUint64=st.prototype.V,st.prototype.vb=function(Z,re){re!=null&&(re=zr(re),sr(this,Z,0),this.a.l(re.lo,re.hi))},st.prototype.writeUint64String=st.prototype.vb,st.prototype.rb=function(Z,re){re!=null&&(P(-2147483648<=re&&2147483648>re),re!=null&&(sr(this,Z,0),this.a.wa(re)))},st.prototype.writeSint32=st.prototype.rb,st.prototype.sb=function(Z,re){re!=null&&(P(-9223372036854776e3<=re&&9223372036854776e3>re),re!=null&&(sr(this,Z,0),this.a.xa(re)))},st.prototype.writeSint64=st.prototype.sb,st.prototype.$d=function(Z,re){re!=null&&re!=null&&(sr(this,Z,0),this.a.W(re))},st.prototype.writeSintHash64=st.prototype.$d,st.prototype.Zd=function(Z,re){re!=null&&re!=null&&(sr(this,Z,0),this.a.Ta(re))},st.prototype.writeSint64String=st.prototype.Zd,st.prototype.Pa=function(Z,re){re!=null&&(P(0<=re&&4294967296>re),sr(this,Z,5),this.a.s(re))},st.prototype.writeFixed32=st.prototype.Pa,st.prototype.Qa=function(Z,re){re!=null&&(P(0<=re&&18446744073709552e3>re),sr(this,Z,1),this.a.V(re))},st.prototype.writeFixed64=st.prototype.Qa,st.prototype.nb=function(Z,re){re!=null&&(re=zr(re),sr(this,Z,1),this.a.A(re.lo,re.hi))},st.prototype.writeFixed64String=st.prototype.nb,st.prototype.Ra=function(Z,re){re!=null&&(P(-2147483648<=re&&2147483648>re),sr(this,Z,5),this.a.S(re))},st.prototype.writeSfixed32=st.prototype.Ra,st.prototype.Sa=function(Z,re){re!=null&&(P(-9223372036854776e3<=re&&9223372036854776e3>re),sr(this,Z,1),this.a.T(re))},st.prototype.writeSfixed64=st.prototype.Sa,st.prototype.qb=function(Z,re){re!=null&&(re=to(re),sr(this,Z,1),this.a.A(re.lo,re.hi))},st.prototype.writeSfixed64String=st.prototype.qb,st.prototype.L=function(Z,re){re!=null&&(sr(this,Z,5),this.a.L(re))},st.prototype.writeFloat=st.prototype.L,st.prototype.J=function(Z,re){re!=null&&(sr(this,Z,1),this.a.J(re))},st.prototype.writeDouble=st.prototype.J,st.prototype.I=function(Z,re){re!=null&&(P(typeof re=="boolean"||typeof re=="number"),sr(this,Z,0),this.a.I(re))},st.prototype.writeBool=st.prototype.I,st.prototype.R=function(Z,re){re!=null&&(P(-2147483648<=re&&2147483648>re),sr(this,Z,0),this.a.M(re))},st.prototype.writeEnum=st.prototype.R,st.prototype.U=function(Z,re){re!=null&&(Z=hi(this,Z),this.a.U(re),si(this,Z))},st.prototype.writeString=st.prototype.U,st.prototype.ja=function(Z,re){re!=null&&(re=rt(re),sr(this,Z,2),this.a.j(re.length),zo(this,re))},st.prototype.writeBytes=st.prototype.ja,st.prototype.Rc=function(Z,re,ye){re!=null&&(Z=hi(this,Z),ye(re,this),si(this,Z))},st.prototype.writeMessage=st.prototype.Rc,st.prototype.Sc=function(Z,re,ye){re!=null&&(sr(this,1,3),sr(this,2,0),this.a.M(Z),Z=hi(this,3),ye(re,this),si(this,Z),sr(this,1,4))},st.prototype.writeMessageSet=st.prototype.Sc,st.prototype.Oc=function(Z,re,ye){re!=null&&(sr(this,Z,3),ye(re,this),sr(this,Z,4))},st.prototype.writeGroup=st.prototype.Oc,st.prototype.K=function(Z,re){re!=null&&(P(re.length==8),sr(this,Z,1),this.a.K(re))},st.prototype.writeFixedHash64=st.prototype.K,st.prototype.N=function(Z,re){re!=null&&(P(re.length==8),sr(this,Z,0),this.a.N(re))},st.prototype.writeVarintHash64=st.prototype.N,st.prototype.A=function(Z,re,ye){sr(this,Z,1),this.a.A(re,ye)},st.prototype.writeSplitFixed64=st.prototype.A,st.prototype.l=function(Z,re,ye){sr(this,Z,0),this.a.l(re,ye)},st.prototype.writeSplitVarint64=st.prototype.l,st.prototype.tb=function(Z,re,ye){sr(this,Z,0);var Ye=this.a;Ne(re,ye,function(gt,Dt){Ye.l(gt>>>0,Dt>>>0)})},st.prototype.writeSplitZigzagVarint64=st.prototype.tb,st.prototype.Ed=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)ts(this,Z,re[ye])},st.prototype.writeRepeatedInt32=st.prototype.Ed,st.prototype.Fd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.ob(Z,re[ye])},st.prototype.writeRepeatedInt32String=st.prototype.Fd,st.prototype.Gd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.ua(Ye))}},st.prototype.writeRepeatedInt64=st.prototype.Gd,st.prototype.Qd=function(Z,re,ye,Ye){if(re!=null)for(var gt=0;gt<re.length;gt++)this.A(Z,ye(re[gt]),Ye(re[gt]))},st.prototype.writeRepeatedSplitFixed64=st.prototype.Qd,st.prototype.Rd=function(Z,re,ye,Ye){if(re!=null)for(var gt=0;gt<re.length;gt++)this.l(Z,ye(re[gt]),Ye(re[gt]))},st.prototype.writeRepeatedSplitVarint64=st.prototype.Rd,st.prototype.Sd=function(Z,re,ye,Ye){if(re!=null)for(var gt=0;gt<re.length;gt++)this.tb(Z,ye(re[gt]),Ye(re[gt]))},st.prototype.writeRepeatedSplitZigzagVarint64=st.prototype.Sd,st.prototype.Hd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.ka(Z,re[ye])},st.prototype.writeRepeatedInt64String=st.prototype.Hd,st.prototype.Ud=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)Ns(this,Z,re[ye])},st.prototype.writeRepeatedUint32=st.prototype.Ud,st.prototype.Vd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.ub(Z,re[ye])},st.prototype.writeRepeatedUint32String=st.prototype.Vd,st.prototype.Wd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.va(Ye))}},st.prototype.writeRepeatedUint64=st.prototype.Wd,st.prototype.Xd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.vb(Z,re[ye])},st.prototype.writeRepeatedUint64String=st.prototype.Xd,st.prototype.Md=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.wa(Ye))}},st.prototype.writeRepeatedSint32=st.prototype.Md,st.prototype.Nd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.xa(Ye))}},st.prototype.writeRepeatedSint64=st.prototype.Nd,st.prototype.Od=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.Ta(Ye))}},st.prototype.writeRepeatedSint64String=st.prototype.Od,st.prototype.Pd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++){var Ye=re[ye];Ye!=null&&(sr(this,Z,0),this.a.W(Ye))}},st.prototype.writeRepeatedSintHash64=st.prototype.Pd,st.prototype.yd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.Pa(Z,re[ye])},st.prototype.writeRepeatedFixed32=st.prototype.yd,st.prototype.zd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.Qa(Z,re[ye])},st.prototype.writeRepeatedFixed64=st.prototype.zd,st.prototype.Ad=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.nb(Z,re[ye])},st.prototype.writeRepeatedFixed64String=st.prototype.Ad,st.prototype.Jd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.Ra(Z,re[ye])},st.prototype.writeRepeatedSfixed32=st.prototype.Jd,st.prototype.Kd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.Sa(Z,re[ye])},st.prototype.writeRepeatedSfixed64=st.prototype.Kd,st.prototype.Ld=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.qb(Z,re[ye])},st.prototype.writeRepeatedSfixed64String=st.prototype.Ld,st.prototype.Cd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.L(Z,re[ye])},st.prototype.writeRepeatedFloat=st.prototype.Cd,st.prototype.wd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.J(Z,re[ye])},st.prototype.writeRepeatedDouble=st.prototype.wd,st.prototype.ud=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.I(Z,re[ye])},st.prototype.writeRepeatedBool=st.prototype.ud,st.prototype.xd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.R(Z,re[ye])},st.prototype.writeRepeatedEnum=st.prototype.xd,st.prototype.Td=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.U(Z,re[ye])},st.prototype.writeRepeatedString=st.prototype.Td,st.prototype.vd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.ja(Z,re[ye])},st.prototype.writeRepeatedBytes=st.prototype.vd,st.prototype.Id=function(Z,re,ye){if(re!=null)for(var Ye=0;Ye<re.length;Ye++){var gt=hi(this,Z);ye(re[Ye],this),si(this,gt)}},st.prototype.writeRepeatedMessage=st.prototype.Id,st.prototype.Dd=function(Z,re,ye){if(re!=null)for(var Ye=0;Ye<re.length;Ye++)sr(this,Z,3),ye(re[Ye],this),sr(this,Z,4)},st.prototype.writeRepeatedGroup=st.prototype.Dd,st.prototype.Bd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.K(Z,re[ye])},st.prototype.writeRepeatedFixedHash64=st.prototype.Bd,st.prototype.Yd=function(Z,re){if(re!=null)for(var ye=0;ye<re.length;ye++)this.N(Z,re[ye])},st.prototype.writeRepeatedVarintHash64=st.prototype.Yd,st.prototype.ad=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.M(re[ye]);si(this,Z)}},st.prototype.writePackedInt32=st.prototype.ad,st.prototype.bd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.M(parseInt(re[ye],10));si(this,Z)}},st.prototype.writePackedInt32String=st.prototype.bd,st.prototype.cd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.ua(re[ye]);si(this,Z)}},st.prototype.writePackedInt64=st.prototype.cd,st.prototype.md=function(Z,re,ye,Ye){if(re!=null){Z=hi(this,Z);for(var gt=0;gt<re.length;gt++)this.a.A(ye(re[gt]),Ye(re[gt]));si(this,Z)}},st.prototype.writePackedSplitFixed64=st.prototype.md,st.prototype.nd=function(Z,re,ye,Ye){if(re!=null){Z=hi(this,Z);for(var gt=0;gt<re.length;gt++)this.a.l(ye(re[gt]),Ye(re[gt]));si(this,Z)}},st.prototype.writePackedSplitVarint64=st.prototype.nd,st.prototype.od=function(Z,re,ye,Ye){if(re!=null){Z=hi(this,Z);for(var gt=this.a,Dt=0;Dt<re.length;Dt++)Ne(ye(re[Dt]),Ye(re[Dt]),function(pr,Gr){gt.l(pr>>>0,Gr>>>0)});si(this,Z)}},st.prototype.writePackedSplitZigzagVarint64=st.prototype.od,st.prototype.dd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++){var Ye=to(re[ye]);this.a.l(Ye.lo,Ye.hi)}si(this,Z)}},st.prototype.writePackedInt64String=st.prototype.dd,st.prototype.pd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.j(re[ye]);si(this,Z)}},st.prototype.writePackedUint32=st.prototype.pd,st.prototype.qd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.j(parseInt(re[ye],10));si(this,Z)}},st.prototype.writePackedUint32String=st.prototype.qd,st.prototype.rd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.va(re[ye]);si(this,Z)}},st.prototype.writePackedUint64=st.prototype.rd,st.prototype.sd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++){var Ye=zr(re[ye]);this.a.l(Ye.lo,Ye.hi)}si(this,Z)}},st.prototype.writePackedUint64String=st.prototype.sd,st.prototype.hd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.wa(re[ye]);si(this,Z)}},st.prototype.writePackedSint32=st.prototype.hd,st.prototype.jd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.xa(re[ye]);si(this,Z)}},st.prototype.writePackedSint64=st.prototype.jd,st.prototype.kd=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.W(xt(re[ye]));si(this,Z)}},st.prototype.writePackedSint64String=st.prototype.kd,st.prototype.ld=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.W(re[ye]);si(this,Z)}},st.prototype.writePackedSintHash64=st.prototype.ld,st.prototype.Wc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(4*re.length),Z=0;Z<re.length;Z++)this.a.s(re[Z])},st.prototype.writePackedFixed32=st.prototype.Wc,st.prototype.Xc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++)this.a.V(re[Z])},st.prototype.writePackedFixed64=st.prototype.Xc,st.prototype.Yc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++){var ye=zr(re[Z]);this.a.A(ye.lo,ye.hi)}},st.prototype.writePackedFixed64String=st.prototype.Yc,st.prototype.ed=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(4*re.length),Z=0;Z<re.length;Z++)this.a.S(re[Z])},st.prototype.writePackedSfixed32=st.prototype.ed,st.prototype.fd=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++)this.a.T(re[Z])},st.prototype.writePackedSfixed64=st.prototype.fd,st.prototype.gd=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++)this.a.ka(re[Z])},st.prototype.writePackedSfixed64String=st.prototype.gd,st.prototype.$c=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(4*re.length),Z=0;Z<re.length;Z++)this.a.L(re[Z])},st.prototype.writePackedFloat=st.prototype.$c,st.prototype.Uc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++)this.a.J(re[Z])},st.prototype.writePackedDouble=st.prototype.Uc,st.prototype.Tc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(re.length),Z=0;Z<re.length;Z++)this.a.I(re[Z])},st.prototype.writePackedBool=st.prototype.Tc,st.prototype.Vc=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.R(re[ye]);si(this,Z)}},st.prototype.writePackedEnum=st.prototype.Vc,st.prototype.Zc=function(Z,re){if(re!=null&&re.length)for(sr(this,Z,2),this.a.j(8*re.length),Z=0;Z<re.length;Z++)this.a.K(re[Z])},st.prototype.writePackedFixedHash64=st.prototype.Zc,st.prototype.td=function(Z,re){if(re!=null&&re.length){Z=hi(this,Z);for(var ye=0;ye<re.length;ye++)this.a.N(re[ye]);si(this,Z)}},st.prototype.writePackedVarintHash64=st.prototype.td,t.debug=fr,t.Map=D,t.Message=Bt,t.BinaryReader=Xe,t.BinaryWriter=st,t.ExtensionFieldInfo=Jt,t.ExtensionFieldBinaryInfo=zt,t.exportSymbol=g,t.inherits=v,t.object={extend:m},t.typeOf=h})(bT)),bT}var Que;function jS(){return Que||(Que=1,(function(t){var e=qP(),i=e,n=Function("return this")();i.exportSymbol("proto.base.ClientId",null,n),i.exportSymbol("proto.base.E2e",null,n),i.exportSymbol("proto.base.E2eProfile",null,n),i.exportSymbol("proto.base.Empty",null,n),i.exportSymbol("proto.base.FrameInfo",null,n),i.exportSymbol("proto.base.Frames",null,n),i.exportSymbol("proto.base.Group",null,n),i.exportSymbol("proto.base.MetaData",null,n),i.exportSymbol("proto.base.Multiplex",null,n),i.exportSymbol("proto.base.Multiplex.ModeCase",null,n),i.exportSymbol("proto.base.NameSpace",null,n),i.exportSymbol("proto.base.NetworkInfo",null,n),i.exportSymbol("proto.base.SignalId",null,n),i.exportSymbol("proto.base.SignalInfo",null,n),proto.base.Empty=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.Empty,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Empty.displayName="proto.base.Empty"),proto.base.ClientId=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.ClientId,e.Message),i.DEBUG&&!COMPILED&&(proto.base.ClientId.displayName="proto.base.ClientId"),proto.base.SignalId=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.SignalId,e.Message),i.DEBUG&&!COMPILED&&(proto.base.SignalId.displayName="proto.base.SignalId"),proto.base.SignalInfo=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.SignalInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.base.SignalInfo.displayName="proto.base.SignalInfo"),proto.base.Multiplex=function(r){e.Message.initialize(this,r,0,-1,null,proto.base.Multiplex.oneofGroups_)},i.inherits(proto.base.Multiplex,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Multiplex.displayName="proto.base.Multiplex"),proto.base.E2e=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.E2e,e.Message),i.DEBUG&&!COMPILED&&(proto.base.E2e.displayName="proto.base.E2e"),proto.base.Group=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.Group,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Group.displayName="proto.base.Group"),proto.base.MetaData=function(r){e.Message.initialize(this,r,0,-1,proto.base.MetaData.repeatedFields_,null)},i.inherits(proto.base.MetaData,e.Message),i.DEBUG&&!COMPILED&&(proto.base.MetaData.displayName="proto.base.MetaData"),proto.base.NameSpace=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.NameSpace,e.Message),i.DEBUG&&!COMPILED&&(proto.base.NameSpace.displayName="proto.base.NameSpace"),proto.base.NetworkInfo=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.base.NetworkInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.base.NetworkInfo.displayName="proto.base.NetworkInfo"),proto.base.FrameInfo=function(r){e.Message.initialize(this,r,0,-1,proto.base.FrameInfo.repeatedFields_,null)},i.inherits(proto.base.FrameInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FrameInfo.displayName="proto.base.FrameInfo"),proto.base.Frames=function(r){e.Message.initialize(this,r,0,-1,proto.base.Frames.repeatedFields_,null)},i.inherits(proto.base.Frames,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Frames.displayName="proto.base.Frames"),e.Message.GENERATE_TO_OBJECT&&(proto.base.Empty.prototype.toObject=function(r){return proto.base.Empty.toObject(r,this)},proto.base.Empty.toObject=function(r,o){var a={};return r&&(a.$jspbMessageInstance=o),a}),proto.base.Empty.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.Empty;return proto.base.Empty.deserializeBinaryFromReader(a,o)},proto.base.Empty.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();o.skipField()}return r},proto.base.Empty.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.Empty.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.Empty.serializeBinaryToWriter=function(r,o){},e.Message.GENERATE_TO_OBJECT&&(proto.base.ClientId.prototype.toObject=function(r){return proto.base.ClientId.toObject(r,this)},proto.base.ClientId.toObject=function(r,o){var a={id:e.Message.getFieldWithDefault(o,1,"")};return r&&(a.$jspbMessageInstance=o),a}),proto.base.ClientId.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.ClientId;return proto.base.ClientId.deserializeBinaryFromReader(a,o)},proto.base.ClientId.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setId(s);break;default:o.skipField();break}}return r},proto.base.ClientId.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.ClientId.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.ClientId.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getId(),a.length>0&&o.writeString(1,a)},proto.base.ClientId.prototype.getId=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.ClientId.prototype.setId=function(r){return e.Message.setProto3StringField(this,1,r)},e.Message.GENERATE_TO_OBJECT&&(proto.base.SignalId.prototype.toObject=function(r){return proto.base.SignalId.toObject(r,this)},proto.base.SignalId.toObject=function(r,o){var a,s={name:e.Message.getFieldWithDefault(o,1,""),namespace:(a=o.getNamespace())&&proto.base.NameSpace.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.base.SignalId.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.SignalId;return proto.base.SignalId.deserializeBinaryFromReader(a,o)},proto.base.SignalId.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=new proto.base.NameSpace;o.readMessage(s,proto.base.NameSpace.deserializeBinaryFromReader),r.setNamespace(s);break;default:o.skipField();break}}return r},proto.base.SignalId.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.SignalId.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.SignalId.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getName(),a.length>0&&o.writeString(1,a),a=r.getNamespace(),a!=null&&o.writeMessage(2,a,proto.base.NameSpace.serializeBinaryToWriter)},proto.base.SignalId.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.SignalId.prototype.setName=function(r){return e.Message.setProto3StringField(this,1,r)},proto.base.SignalId.prototype.getNamespace=function(){return e.Message.getWrapperField(this,proto.base.NameSpace,2)},proto.base.SignalId.prototype.setNamespace=function(r){return e.Message.setWrapperField(this,2,r)},proto.base.SignalId.prototype.clearNamespace=function(){return this.setNamespace(void 0)},proto.base.SignalId.prototype.hasNamespace=function(){return e.Message.getField(this,2)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.SignalInfo.prototype.toObject=function(r){return proto.base.SignalInfo.toObject(r,this)},proto.base.SignalInfo.toObject=function(r,o){var a,s={id:(a=o.getId())&&proto.base.SignalId.toObject(r,a),metadata:(a=o.getMetadata())&&proto.base.MetaData.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.base.SignalInfo.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.SignalInfo;return proto.base.SignalInfo.deserializeBinaryFromReader(a,o)},proto.base.SignalInfo.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.base.SignalId;o.readMessage(s,proto.base.SignalId.deserializeBinaryFromReader),r.setId(s);break;case 2:var s=new proto.base.MetaData;o.readMessage(s,proto.base.MetaData.deserializeBinaryFromReader),r.setMetadata(s);break;default:o.skipField();break}}return r},proto.base.SignalInfo.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.SignalInfo.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.SignalInfo.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getId(),a!=null&&o.writeMessage(1,a,proto.base.SignalId.serializeBinaryToWriter),a=r.getMetadata(),a!=null&&o.writeMessage(2,a,proto.base.MetaData.serializeBinaryToWriter)},proto.base.SignalInfo.prototype.getId=function(){return e.Message.getWrapperField(this,proto.base.SignalId,1)},proto.base.SignalInfo.prototype.setId=function(r){return e.Message.setWrapperField(this,1,r)},proto.base.SignalInfo.prototype.clearId=function(){return this.setId(void 0)},proto.base.SignalInfo.prototype.hasId=function(){return e.Message.getField(this,1)!=null},proto.base.SignalInfo.prototype.getMetadata=function(){return e.Message.getWrapperField(this,proto.base.MetaData,2)},proto.base.SignalInfo.prototype.setMetadata=function(r){return e.Message.setWrapperField(this,2,r)},proto.base.SignalInfo.prototype.clearMetadata=function(){return this.setMetadata(void 0)},proto.base.SignalInfo.prototype.hasMetadata=function(){return e.Message.getField(this,2)!=null},proto.base.Multiplex.oneofGroups_=[[1,2,3]],proto.base.Multiplex.ModeCase={MODE_NOT_SET:0,NONE:1,SELECT:2,FILTER:3},proto.base.Multiplex.prototype.getModeCase=function(){return e.Message.computeOneofCase(this,proto.base.Multiplex.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.Multiplex.prototype.toObject=function(r){return proto.base.Multiplex.toObject(r,this)},proto.base.Multiplex.toObject=function(r,o){var a,s={none:(a=o.getNone())&&proto.base.Empty.toObject(r,a),select:(a=o.getSelect())&&proto.base.Empty.toObject(r,a),filter:e.Message.getFieldWithDefault(o,3,0)};return r&&(s.$jspbMessageInstance=o),s}),proto.base.Multiplex.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.Multiplex;return proto.base.Multiplex.deserializeBinaryFromReader(a,o)},proto.base.Multiplex.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.base.Empty;o.readMessage(s,proto.base.Empty.deserializeBinaryFromReader),r.setNone(s);break;case 2:var s=new proto.base.Empty;o.readMessage(s,proto.base.Empty.deserializeBinaryFromReader),r.setSelect(s);break;case 3:var s=o.readInt32();r.setFilter(s);break;default:o.skipField();break}}return r},proto.base.Multiplex.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.Multiplex.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.Multiplex.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getNone(),a!=null&&o.writeMessage(1,a,proto.base.Empty.serializeBinaryToWriter),a=r.getSelect(),a!=null&&o.writeMessage(2,a,proto.base.Empty.serializeBinaryToWriter),a=e.Message.getField(r,3),a!=null&&o.writeInt32(3,a)},proto.base.Multiplex.prototype.getNone=function(){return e.Message.getWrapperField(this,proto.base.Empty,1)},proto.base.Multiplex.prototype.setNone=function(r){return e.Message.setOneofWrapperField(this,1,proto.base.Multiplex.oneofGroups_[0],r)},proto.base.Multiplex.prototype.clearNone=function(){return this.setNone(void 0)},proto.base.Multiplex.prototype.hasNone=function(){return e.Message.getField(this,1)!=null},proto.base.Multiplex.prototype.getSelect=function(){return e.Message.getWrapperField(this,proto.base.Empty,2)},proto.base.Multiplex.prototype.setSelect=function(r){return e.Message.setOneofWrapperField(this,2,proto.base.Multiplex.oneofGroups_[0],r)},proto.base.Multiplex.prototype.clearSelect=function(){return this.setSelect(void 0)},proto.base.Multiplex.prototype.hasSelect=function(){return e.Message.getField(this,2)!=null},proto.base.Multiplex.prototype.getFilter=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.base.Multiplex.prototype.setFilter=function(r){return e.Message.setOneofField(this,3,proto.base.Multiplex.oneofGroups_[0],r)},proto.base.Multiplex.prototype.clearFilter=function(){return e.Message.setOneofField(this,3,proto.base.Multiplex.oneofGroups_[0],void 0)},proto.base.Multiplex.prototype.hasFilter=function(){return e.Message.getField(this,3)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.E2e.prototype.toObject=function(r){return proto.base.E2e.toObject(r,this)},proto.base.E2e.toObject=function(r,o){var a={profile:e.Message.getFieldWithDefault(o,1,0),dataid:e.Message.getFieldWithDefault(o,2,0),signalcrc:e.Message.getFieldWithDefault(o,3,""),signalcounter:e.Message.getFieldWithDefault(o,4,"")};return r&&(a.$jspbMessageInstance=o),a}),proto.base.E2e.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.E2e;return proto.base.E2e.deserializeBinaryFromReader(a,o)},proto.base.E2e.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readEnum();r.setProfile(s);break;case 2:var s=o.readUint32();r.setDataid(s);break;case 3:var s=o.readString();r.setSignalcrc(s);break;case 4:var s=o.readString();r.setSignalcounter(s);break;default:o.skipField();break}}return r},proto.base.E2e.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.E2e.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.E2e.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getProfile(),a!==0&&o.writeEnum(1,a),a=r.getDataid(),a!==0&&o.writeUint32(2,a),a=r.getSignalcrc(),a.length>0&&o.writeString(3,a),a=r.getSignalcounter(),a.length>0&&o.writeString(4,a)},proto.base.E2e.prototype.getProfile=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.base.E2e.prototype.setProfile=function(r){return e.Message.setProto3EnumField(this,1,r)},proto.base.E2e.prototype.getDataid=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.base.E2e.prototype.setDataid=function(r){return e.Message.setProto3IntField(this,2,r)},proto.base.E2e.prototype.getSignalcrc=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.E2e.prototype.setSignalcrc=function(r){return e.Message.setProto3StringField(this,3,r)},proto.base.E2e.prototype.getSignalcounter=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.E2e.prototype.setSignalcounter=function(r){return e.Message.setProto3StringField(this,4,r)},e.Message.GENERATE_TO_OBJECT&&(proto.base.Group.prototype.toObject=function(r){return proto.base.Group.toObject(r,this)},proto.base.Group.toObject=function(r,o){var a,s={start:e.Message.getFieldWithDefault(o,1,0),length:e.Message.getFieldWithDefault(o,2,0),e2e:(a=o.getE2e())&&proto.base.E2e.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.base.Group.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.Group;return proto.base.Group.deserializeBinaryFromReader(a,o)},proto.base.Group.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readUint32();r.setStart(s);break;case 2:var s=o.readUint32();r.setLength(s);break;case 3:var s=new proto.base.E2e;o.readMessage(s,proto.base.E2e.deserializeBinaryFromReader),r.setE2e(s);break;default:o.skipField();break}}return r},proto.base.Group.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.Group.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.Group.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getStart(),a!==0&&o.writeUint32(1,a),a=r.getLength(),a!==0&&o.writeUint32(2,a),a=r.getE2e(),a!=null&&o.writeMessage(3,a,proto.base.E2e.serializeBinaryToWriter)},proto.base.Group.prototype.getStart=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.base.Group.prototype.setStart=function(r){return e.Message.setProto3IntField(this,1,r)},proto.base.Group.prototype.getLength=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.base.Group.prototype.setLength=function(r){return e.Message.setProto3IntField(this,2,r)},proto.base.Group.prototype.getE2e=function(){return e.Message.getWrapperField(this,proto.base.E2e,3)},proto.base.Group.prototype.setE2e=function(r){return e.Message.setWrapperField(this,3,r)},proto.base.Group.prototype.clearE2e=function(){return this.setE2e(void 0)},proto.base.Group.prototype.hasE2e=function(){return e.Message.getField(this,3)!=null},proto.base.MetaData.repeatedFields_=[14,15,20],e.Message.GENERATE_TO_OBJECT&&(proto.base.MetaData.prototype.toObject=function(r){return proto.base.MetaData.toObject(r,this)},proto.base.MetaData.toObject=function(r,o){var a,s={description:e.Message.getFieldWithDefault(o,4,""),max:e.Message.getFloatingPointFieldWithDefault(o,12,0),min:e.Message.getFloatingPointFieldWithDefault(o,13,0),unit:e.Message.getFieldWithDefault(o,7,""),size:e.Message.getFieldWithDefault(o,8,0),israw:e.Message.getBooleanFieldWithDefault(o,9,!1),factor:e.Message.getFloatingPointFieldWithDefault(o,10,0),offset:e.Message.getFloatingPointFieldWithDefault(o,11,0),senderList:(a=e.Message.getRepeatedField(o,14))==null?void 0:a,receiverList:(a=e.Message.getRepeatedField(o,15))==null?void 0:a,cycletime:e.Message.getFloatingPointFieldWithDefault(o,16,0),startvalue:e.Message.getFloatingPointFieldWithDefault(o,17,0),multiplex:(a=o.getMultiplex())&&proto.base.Multiplex.toObject(r,a),e2e:(a=o.getE2e())&&proto.base.E2e.toObject(r,a),groupsList:e.Message.toObjectList(o.getGroupsList(),proto.base.Group.toObject,r),frameid:e.Message.getFieldWithDefault(o,21,0),namedvaluesMap:(a=o.getNamedvaluesMap())?a.toObject(r,void 0):[]};return r&&(s.$jspbMessageInstance=o),s}),proto.base.MetaData.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.MetaData;return proto.base.MetaData.deserializeBinaryFromReader(a,o)},proto.base.MetaData.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 4:var s=o.readString();r.setDescription(s);break;case 12:var s=o.readFloat();r.setMax(s);break;case 13:var s=o.readFloat();r.setMin(s);break;case 7:var s=o.readString();r.setUnit(s);break;case 8:var s=o.readInt32();r.setSize(s);break;case 9:var s=o.readBool();r.setIsraw(s);break;case 10:var s=o.readDouble();r.setFactor(s);break;case 11:var s=o.readDouble();r.setOffset(s);break;case 14:var s=o.readString();r.addSender(s);break;case 15:var s=o.readString();r.addReceiver(s);break;case 16:var s=o.readFloat();r.setCycletime(s);break;case 17:var s=o.readFloat();r.setStartvalue(s);break;case 18:var s=new proto.base.Multiplex;o.readMessage(s,proto.base.Multiplex.deserializeBinaryFromReader),r.setMultiplex(s);break;case 19:var s=new proto.base.E2e;o.readMessage(s,proto.base.E2e.deserializeBinaryFromReader),r.setE2e(s);break;case 20:var s=new proto.base.Group;o.readMessage(s,proto.base.Group.deserializeBinaryFromReader),r.addGroups(s);break;case 21:var s=o.readUint32();r.setFrameid(s);break;case 22:var s=r.getNamedvaluesMap();o.readMessage(s,function(l,u){e.Map.deserializeBinary(l,u,e.BinaryReader.prototype.readInt64,e.BinaryReader.prototype.readString,null,0,"")});break;default:o.skipField();break}}return r},proto.base.MetaData.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.MetaData.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.MetaData.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getDescription(),a.length>0&&o.writeString(4,a),a=r.getMax(),a!==0&&o.writeFloat(12,a),a=r.getMin(),a!==0&&o.writeFloat(13,a),a=r.getUnit(),a.length>0&&o.writeString(7,a),a=r.getSize(),a!==0&&o.writeInt32(8,a),a=r.getIsraw(),a&&o.writeBool(9,a),a=r.getFactor(),a!==0&&o.writeDouble(10,a),a=r.getOffset(),a!==0&&o.writeDouble(11,a),a=r.getSenderList(),a.length>0&&o.writeRepeatedString(14,a),a=r.getReceiverList(),a.length>0&&o.writeRepeatedString(15,a),a=r.getCycletime(),a!==0&&o.writeFloat(16,a),a=r.getStartvalue(),a!==0&&o.writeFloat(17,a),a=r.getMultiplex(),a!=null&&o.writeMessage(18,a,proto.base.Multiplex.serializeBinaryToWriter),a=r.getE2e(),a!=null&&o.writeMessage(19,a,proto.base.E2e.serializeBinaryToWriter),a=r.getGroupsList(),a.length>0&&o.writeRepeatedMessage(20,a,proto.base.Group.serializeBinaryToWriter),a=r.getFrameid(),a!==0&&o.writeUint32(21,a),a=r.getNamedvaluesMap(!0),a&&a.getLength()>0&&a.serializeBinary(22,o,e.BinaryWriter.prototype.writeInt64,e.BinaryWriter.prototype.writeString)},proto.base.MetaData.prototype.getDescription=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.MetaData.prototype.setDescription=function(r){return e.Message.setProto3StringField(this,4,r)},proto.base.MetaData.prototype.getMax=function(){return e.Message.getFloatingPointFieldWithDefault(this,12,0)},proto.base.MetaData.prototype.setMax=function(r){return e.Message.setProto3FloatField(this,12,r)},proto.base.MetaData.prototype.getMin=function(){return e.Message.getFloatingPointFieldWithDefault(this,13,0)},proto.base.MetaData.prototype.setMin=function(r){return e.Message.setProto3FloatField(this,13,r)},proto.base.MetaData.prototype.getUnit=function(){return e.Message.getFieldWithDefault(this,7,"")},proto.base.MetaData.prototype.setUnit=function(r){return e.Message.setProto3StringField(this,7,r)},proto.base.MetaData.prototype.getSize=function(){return e.Message.getFieldWithDefault(this,8,0)},proto.base.MetaData.prototype.setSize=function(r){return e.Message.setProto3IntField(this,8,r)},proto.base.MetaData.prototype.getIsraw=function(){return e.Message.getBooleanFieldWithDefault(this,9,!1)},proto.base.MetaData.prototype.setIsraw=function(r){return e.Message.setProto3BooleanField(this,9,r)},proto.base.MetaData.prototype.getFactor=function(){return e.Message.getFloatingPointFieldWithDefault(this,10,0)},proto.base.MetaData.prototype.setFactor=function(r){return e.Message.setProto3FloatField(this,10,r)},proto.base.MetaData.prototype.getOffset=function(){return e.Message.getFloatingPointFieldWithDefault(this,11,0)},proto.base.MetaData.prototype.setOffset=function(r){return e.Message.setProto3FloatField(this,11,r)},proto.base.MetaData.prototype.getSenderList=function(){return e.Message.getRepeatedField(this,14)},proto.base.MetaData.prototype.setSenderList=function(r){return e.Message.setField(this,14,r||[])},proto.base.MetaData.prototype.addSender=function(r,o){return e.Message.addToRepeatedField(this,14,r,o)},proto.base.MetaData.prototype.clearSenderList=function(){return this.setSenderList([])},proto.base.MetaData.prototype.getReceiverList=function(){return e.Message.getRepeatedField(this,15)},proto.base.MetaData.prototype.setReceiverList=function(r){return e.Message.setField(this,15,r||[])},proto.base.MetaData.prototype.addReceiver=function(r,o){return e.Message.addToRepeatedField(this,15,r,o)},proto.base.MetaData.prototype.clearReceiverList=function(){return this.setReceiverList([])},proto.base.MetaData.prototype.getCycletime=function(){return e.Message.getFloatingPointFieldWithDefault(this,16,0)},proto.base.MetaData.prototype.setCycletime=function(r){return e.Message.setProto3FloatField(this,16,r)},proto.base.MetaData.prototype.getStartvalue=function(){return e.Message.getFloatingPointFieldWithDefault(this,17,0)},proto.base.MetaData.prototype.setStartvalue=function(r){return e.Message.setProto3FloatField(this,17,r)},proto.base.MetaData.prototype.getMultiplex=function(){return e.Message.getWrapperField(this,proto.base.Multiplex,18)},proto.base.MetaData.prototype.setMultiplex=function(r){return e.Message.setWrapperField(this,18,r)},proto.base.MetaData.prototype.clearMultiplex=function(){return this.setMultiplex(void 0)},proto.base.MetaData.prototype.hasMultiplex=function(){return e.Message.getField(this,18)!=null},proto.base.MetaData.prototype.getE2e=function(){return e.Message.getWrapperField(this,proto.base.E2e,19)},proto.base.MetaData.prototype.setE2e=function(r){return e.Message.setWrapperField(this,19,r)},proto.base.MetaData.prototype.clearE2e=function(){return this.setE2e(void 0)},proto.base.MetaData.prototype.hasE2e=function(){return e.Message.getField(this,19)!=null},proto.base.MetaData.prototype.getGroupsList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.Group,20)},proto.base.MetaData.prototype.setGroupsList=function(r){return e.Message.setRepeatedWrapperField(this,20,r)},proto.base.MetaData.prototype.addGroups=function(r,o){return e.Message.addToRepeatedWrapperField(this,20,r,proto.base.Group,o)},proto.base.MetaData.prototype.clearGroupsList=function(){return this.setGroupsList([])},proto.base.MetaData.prototype.getFrameid=function(){return e.Message.getFieldWithDefault(this,21,0)},proto.base.MetaData.prototype.setFrameid=function(r){return e.Message.setProto3IntField(this,21,r)},proto.base.MetaData.prototype.getNamedvaluesMap=function(r){return e.Message.getMapField(this,22,r,null)},proto.base.MetaData.prototype.clearNamedvaluesMap=function(){return this.getNamedvaluesMap().clear(),this},e.Message.GENERATE_TO_OBJECT&&(proto.base.NameSpace.prototype.toObject=function(r){return proto.base.NameSpace.toObject(r,this)},proto.base.NameSpace.toObject=function(r,o){var a={name:e.Message.getFieldWithDefault(o,1,"")};return r&&(a.$jspbMessageInstance=o),a}),proto.base.NameSpace.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.NameSpace;return proto.base.NameSpace.deserializeBinaryFromReader(a,o)},proto.base.NameSpace.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;default:o.skipField();break}}return r},proto.base.NameSpace.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.NameSpace.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.NameSpace.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getName(),a.length>0&&o.writeString(1,a)},proto.base.NameSpace.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.NameSpace.prototype.setName=function(r){return e.Message.setProto3StringField(this,1,r)},e.Message.GENERATE_TO_OBJECT&&(proto.base.NetworkInfo.prototype.toObject=function(r){return proto.base.NetworkInfo.toObject(r,this)},proto.base.NetworkInfo.toObject=function(r,o){var a,s={namespace:(a=o.getNamespace())&&proto.base.NameSpace.toObject(r,a),type:e.Message.getFieldWithDefault(o,2,""),description:e.Message.getFieldWithDefault(o,3,"")};return r&&(s.$jspbMessageInstance=o),s}),proto.base.NetworkInfo.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.NetworkInfo;return proto.base.NetworkInfo.deserializeBinaryFromReader(a,o)},proto.base.NetworkInfo.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.base.NameSpace;o.readMessage(s,proto.base.NameSpace.deserializeBinaryFromReader),r.setNamespace(s);break;case 2:var s=o.readString();r.setType(s);break;case 3:var s=o.readString();r.setDescription(s);break;default:o.skipField();break}}return r},proto.base.NetworkInfo.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.NetworkInfo.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.NetworkInfo.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getNamespace(),a!=null&&o.writeMessage(1,a,proto.base.NameSpace.serializeBinaryToWriter),a=r.getType(),a.length>0&&o.writeString(2,a),a=r.getDescription(),a.length>0&&o.writeString(3,a)},proto.base.NetworkInfo.prototype.getNamespace=function(){return e.Message.getWrapperField(this,proto.base.NameSpace,1)},proto.base.NetworkInfo.prototype.setNamespace=function(r){return e.Message.setWrapperField(this,1,r)},proto.base.NetworkInfo.prototype.clearNamespace=function(){return this.setNamespace(void 0)},proto.base.NetworkInfo.prototype.hasNamespace=function(){return e.Message.getField(this,1)!=null},proto.base.NetworkInfo.prototype.getType=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.NetworkInfo.prototype.setType=function(r){return e.Message.setProto3StringField(this,2,r)},proto.base.NetworkInfo.prototype.getDescription=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.NetworkInfo.prototype.setDescription=function(r){return e.Message.setProto3StringField(this,3,r)},proto.base.FrameInfo.repeatedFields_=[2],e.Message.GENERATE_TO_OBJECT&&(proto.base.FrameInfo.prototype.toObject=function(r){return proto.base.FrameInfo.toObject(r,this)},proto.base.FrameInfo.toObject=function(r,o){var a,s={signalinfo:(a=o.getSignalinfo())&&proto.base.SignalInfo.toObject(r,a),childinfoList:e.Message.toObjectList(o.getChildinfoList(),proto.base.SignalInfo.toObject,r)};return r&&(s.$jspbMessageInstance=o),s}),proto.base.FrameInfo.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.FrameInfo;return proto.base.FrameInfo.deserializeBinaryFromReader(a,o)},proto.base.FrameInfo.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.base.SignalInfo;o.readMessage(s,proto.base.SignalInfo.deserializeBinaryFromReader),r.setSignalinfo(s);break;case 2:var s=new proto.base.SignalInfo;o.readMessage(s,proto.base.SignalInfo.deserializeBinaryFromReader),r.addChildinfo(s);break;default:o.skipField();break}}return r},proto.base.FrameInfo.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.FrameInfo.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.FrameInfo.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getSignalinfo(),a!=null&&o.writeMessage(1,a,proto.base.SignalInfo.serializeBinaryToWriter),a=r.getChildinfoList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.base.SignalInfo.serializeBinaryToWriter)},proto.base.FrameInfo.prototype.getSignalinfo=function(){return e.Message.getWrapperField(this,proto.base.SignalInfo,1)},proto.base.FrameInfo.prototype.setSignalinfo=function(r){return e.Message.setWrapperField(this,1,r)},proto.base.FrameInfo.prototype.clearSignalinfo=function(){return this.setSignalinfo(void 0)},proto.base.FrameInfo.prototype.hasSignalinfo=function(){return e.Message.getField(this,1)!=null},proto.base.FrameInfo.prototype.getChildinfoList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.SignalInfo,2)},proto.base.FrameInfo.prototype.setChildinfoList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.base.FrameInfo.prototype.addChildinfo=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.base.SignalInfo,o)},proto.base.FrameInfo.prototype.clearChildinfoList=function(){return this.setChildinfoList([])},proto.base.Frames.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.Frames.prototype.toObject=function(r){return proto.base.Frames.toObject(r,this)},proto.base.Frames.toObject=function(r,o){var a={frameList:e.Message.toObjectList(o.getFrameList(),proto.base.FrameInfo.toObject,r)};return r&&(a.$jspbMessageInstance=o),a}),proto.base.Frames.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.base.Frames;return proto.base.Frames.deserializeBinaryFromReader(a,o)},proto.base.Frames.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.base.FrameInfo;o.readMessage(s,proto.base.FrameInfo.deserializeBinaryFromReader),r.addFrame(s);break;default:o.skipField();break}}return r},proto.base.Frames.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.base.Frames.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.base.Frames.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getFrameList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.base.FrameInfo.serializeBinaryToWriter)},proto.base.Frames.prototype.getFrameList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.FrameInfo,1)},proto.base.Frames.prototype.setFrameList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.base.Frames.prototype.addFrame=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.base.FrameInfo,o)},proto.base.Frames.prototype.clearFrameList=function(){return this.setFrameList([])},proto.base.E2eProfile={PROFILE_AR_01A:0},i.object.extend(t,proto.base)})(mY)),mY}var D0={},ece;function B6(){if(ece)return D0;ece=1;function t(_e){var He=0;return function(){return He<_e.length?{done:!1,value:_e[He++]}:{done:!0}}}var e=typeof Object.defineProperties=="function"?Object.defineProperty:function(_e,He,et){_e!=Array.prototype&&_e!=Object.prototype&&(_e[He]=et.value)};function i(_e){_e=[typeof window=="object"&&window,typeof self=="object"&&self,typeof xp=="object"&&xp,_e];for(var He=0;He<_e.length;++He){var et=_e[He];if(et&&et.Math==Math)return et}throw Error("Cannot find global object")}var n=i(D0);function r(_e,He){if(He){var et=n;_e=_e.split(".");for(var ht=0;ht<_e.length-1;ht++){var Ft=_e[ht];Ft in et||(et[Ft]={}),et=et[Ft]}_e=_e[_e.length-1],ht=et[_e],He=He(ht),He!=ht&&He!=null&&e(et,_e,{configurable:!0,writable:!0,value:He})}}r("Object.is",function(_e){return _e||function(He,et){return He===et?He!==0||1/He===1/et:He!==He&&et!==et}}),r("Array.prototype.includes",function(_e){return _e||function(He,et){var ht=this;ht instanceof String&&(ht=String(ht));var Ft=ht.length;for(et=et||0,0>et&&(et=Math.max(et+Ft,0));et<Ft;et++){var ur=ht[et];if(ur===He||Object.is(ur,He))return!0}return!1}});function o(_e){var He=typeof Symbol<"u"&&Symbol.iterator&&_e[Symbol.iterator];return He?He.call(_e):{next:t(_e)}}r("Promise",function(_e){function He(Lt){this.b=0,this.c=void 0,this.a=[];var Kt=this.f();try{Lt(Kt.resolve,Kt.reject)}catch(Zr){Kt.reject(Zr)}}function et(){this.a=null}function ht(Lt){return Lt instanceof He?Lt:new He(function(Kt){Kt(Lt)})}if(_e)return _e;et.prototype.b=function(Lt){if(this.a==null){this.a=[];var Kt=this;this.c(function(){Kt.g()})}this.a.push(Lt)};var Ft=n.setTimeout;et.prototype.c=function(Lt){Ft(Lt,0)},et.prototype.g=function(){for(;this.a&&this.a.length;){var Lt=this.a;this.a=[];for(var Kt=0;Kt<Lt.length;++Kt){var Zr=Lt[Kt];Lt[Kt]=null;try{Zr()}catch(ni){this.f(ni)}}}this.a=null},et.prototype.f=function(Lt){this.c(function(){throw Lt})},He.prototype.f=function(){function Lt(ni){return function(pi){Zr||(Zr=!0,ni.call(Kt,pi))}}var Kt=this,Zr=!1;return{resolve:Lt(this.m),reject:Lt(this.g)}},He.prototype.m=function(Lt){if(Lt===this)this.g(new TypeError("A Promise cannot resolve to itself"));else if(Lt instanceof He)this.o(Lt);else{e:switch(typeof Lt){case"object":var Kt=Lt!=null;break e;case"function":Kt=!0;break e;default:Kt=!1}Kt?this.l(Lt):this.h(Lt)}},He.prototype.l=function(Lt){var Kt=void 0;try{Kt=Lt.then}catch(Zr){this.g(Zr);return}typeof Kt=="function"?this.u(Kt,Lt):this.h(Lt)},He.prototype.g=function(Lt){this.i(2,Lt)},He.prototype.h=function(Lt){this.i(1,Lt)},He.prototype.i=function(Lt,Kt){if(this.b!=0)throw Error("Cannot settle("+Lt+", "+Kt+"): Promise already settled in state"+this.b);this.b=Lt,this.c=Kt,this.j()},He.prototype.j=function(){if(this.a!=null){for(var Lt=0;Lt<this.a.length;++Lt)ur.b(this.a[Lt]);this.a=null}};var ur=new et;return He.prototype.o=function(Lt){var Kt=this.f();Lt.w(Kt.resolve,Kt.reject)},He.prototype.u=function(Lt,Kt){var Zr=this.f();try{Lt.call(Kt,Zr.resolve,Zr.reject)}catch(ni){Zr.reject(ni)}},He.prototype.then=function(Lt,Kt){function Zr(Bi,ms){return typeof Bi=="function"?function(Ba){try{ni(Bi(Ba))}catch(Sl){pi(Sl)}}:ms}var ni,pi,Oi=new He(function(Bi,ms){ni=Bi,pi=ms});return this.w(Zr(Lt,ni),Zr(Kt,pi)),Oi},He.prototype.catch=function(Lt){return this.then(void 0,Lt)},He.prototype.w=function(Lt,Kt){function Zr(){switch(ni.b){case 1:Lt(ni.c);break;case 2:Kt(ni.c);break;default:throw Error("Unexpected state: "+ni.b)}}var ni=this;this.a==null?ur.b(Zr):this.a.push(Zr)},He.resolve=ht,He.reject=function(Lt){return new He(function(Kt,Zr){Zr(Lt)})},He.race=function(Lt){return new He(function(Kt,Zr){for(var ni=o(Lt),pi=ni.next();!pi.done;pi=ni.next())ht(pi.value).w(Kt,Zr)})},He.all=function(Lt){var Kt=o(Lt),Zr=Kt.next();return Zr.done?ht([]):new He(function(ni,pi){function Oi(Ba){return function(Sl){Bi[Ba]=Sl,ms--,ms==0&&ni(Bi)}}var Bi=[],ms=0;do Bi.push(void 0),ms++,ht(Zr.value).w(Oi(Bi.length-1),pi),Zr=Kt.next();while(!Zr.done)})},He});var a=a||{},s=D0||self;function l(_e,He){_e=_e.split("."),He=He||s;for(var et=0;et<_e.length;et++)if(He=He[_e[et]],He==null)return null;return He}function u(){}function c(_e){var He=typeof _e;if(He=="object")if(_e){if(_e instanceof Array)return"array";if(_e instanceof Object)return He;var et=Object.prototype.toString.call(_e);if(et=="[object Window]")return"object";if(et=="[object Array]"||typeof _e.length=="number"&&typeof _e.splice<"u"&&typeof _e.propertyIsEnumerable<"u"&&!_e.propertyIsEnumerable("splice"))return"array";if(et=="[object Function]"||typeof _e.call<"u"&&typeof _e.propertyIsEnumerable<"u"&&!_e.propertyIsEnumerable("call"))return"function"}else return"null";else if(He=="function"&&typeof _e.call>"u")return"object";return He}function d(_e){var He=typeof _e;return He=="object"&&_e!=null||He=="function"}function f(_e,He,et){return _e.call.apply(_e.bind,arguments)}function h(_e,He,et){if(!_e)throw Error();if(2<arguments.length){var ht=Array.prototype.slice.call(arguments,2);return function(){var Ft=Array.prototype.slice.call(arguments);return Array.prototype.unshift.apply(Ft,ht),_e.apply(He,Ft)}}return function(){return _e.apply(He,arguments)}}function p(_e,He,et){return Function.prototype.bind&&Function.prototype.bind.toString().indexOf("native code")!=-1?p=f:p=h,p.apply(null,arguments)}function g(_e,He){function et(){}et.prototype=He.prototype,_e.S=He.prototype,_e.prototype=new et,_e.prototype.constructor=_e}function v(){this.a={}}v.prototype.get=function(_e){return this.a[_e]},v.prototype.f=function(){return Object.keys(this.a)};function y(_e,He,et,ht){this.f=_e,this.c=He,this.b=et,this.a=ht}y.prototype.getRequestMessage=function(){return this.f},y.prototype.getMethodDescriptor=function(){return this.c},y.prototype.getMetadata=function(){return this.b},y.prototype.getCallOptions=function(){return this.a};function m(_e,He,et,ht){et=et===void 0?{}:et,this.c=_e,this.a=et,this.b=He,this.f=ht===void 0?null:ht}m.prototype.getResponseMessage=function(){return this.c},m.prototype.getMetadata=function(){return this.a},m.prototype.getMethodDescriptor=function(){return this.b},m.prototype.getStatus=function(){return this.f};function b(_e,He,et,ht,Ft,ur){this.name=_e,this.a=Ft,this.b=ur}function S(_e,He,et){et=et===void 0?{}:et;var ht=ht===void 0?new v:ht;return new y(He,_e,et,ht)}function _(_e,He,et,ht){return ht instanceof b?ht:new b(_e,et,ht.b||He.constructor,ht.f,ht.a,ht.c)}function C(_e){this.a=_e}C.prototype.on=function(_e,He){return _e=="data"||_e=="error"?this:this.a.on(_e,He)},C.prototype.removeListener=function(_e,He){return this.a.removeListener(_e,He)},C.prototype.cancel=function(){this.a.cancel()};function P(_e){switch(_e){case 0:return"No Error";case 1:return"Access denied to content document";case 2:return"File not found";case 3:return"Firefox silently errored";case 4:return"Application custom error";case 5:return"An exception occurred";case 6:return"Http response at 400 or 500 level";case 7:return"Request was aborted";case 8:return"Request timed out";case 9:return"The resource is not available offline";default:return"Unrecognized error code"}}function x(_e){if(Error.captureStackTrace)Error.captureStackTrace(this,x);else{var He=Error().stack;He&&(this.stack=He)}_e&&(this.message=String(_e))}g(x,Error),x.prototype.name="CustomError";function E(_e,He){_e=_e.split("%s");for(var et="",ht=_e.length-1,Ft=0;Ft<ht;Ft++)et+=_e[Ft]+(Ft<He.length?He[Ft]:"%s");x.call(this,et+_e[ht])}g(E,x),E.prototype.name="AssertionError";function A(_e,He){throw new E("Failure"+(": "+_e),Array.prototype.slice.call(arguments,1))}function R(){this.j=null,this.i=[],this.l=0,this.b=D,this.f=this.a=this.h=0,this.c=null,this.g=0}function M(_e,He){function et(ni){ni==z||ni==G?Lt.h=ni:H(Lt,Kt,Zr,"invalid frame byte"),Lt.b=F,Lt.a=0,Lt.f=0}function ht(ni){Lt.f++,Lt.a=(Lt.a<<8)+ni,Lt.f==4&&(Lt.b=I,Lt.g=0,typeof Uint8Array<"u"?Lt.c=new Uint8Array(Lt.a):Lt.c=Array(Lt.a),Lt.a==0&&ur())}function Ft(ni){Lt.c[Lt.g++]=ni,Lt.g==Lt.a&&ur()}function ur(){var ni={};ni[Lt.h]=Lt.c,Lt.i.push(ni),Lt.b=D}var Lt=_e,Kt,Zr=0;for(He instanceof Uint8Array||He instanceof Array?Kt=He:Kt=new Uint8Array(He);Zr<Kt.length;){switch(Lt.b){case V:H(Lt,Kt,Zr,"stream already broken");break;case D:et(Kt[Zr]);break;case F:ht(Kt[Zr]);break;case I:Ft(Kt[Zr]);break;default:throw Error("unexpected parser state: "+Lt.b)}Lt.l++,Zr++}return _e=Lt.i,Lt.i=[],0<_e.length?_e:null}var D=0,F=1,I=2,V=3,z=0,G=128;function H(_e,He,et,ht){throw _e.b=V,_e.j="The stream is broken @"+_e.l+"/"+et+". Error: "+ht+`. With input:
`+He,Error(_e.j)}function U(_e){switch(_e){case 200:return 0;case 400:return 3;case 401:return 16;case 403:return 7;case 404:return 5;case 409:return 10;case 412:return 9;case 429:return 8;case 499:return 1;case 500:return 2;case 501:return 12;case 503:return 14;case 504:return 4;default:return 2}}var k=Array.prototype.indexOf?function(_e,He){return Array.prototype.indexOf.call(_e,He,void 0)}:function(_e,He){if(typeof _e=="string")return typeof He!="string"||He.length!=1?-1:_e.indexOf(He,0);for(var et=0;et<_e.length;et++)if(et in _e&&_e[et]===He)return et;return-1};function X(_e){e:{for(var He=ic,et=_e.length,ht=typeof _e=="string"?_e.split(""):_e,Ft=0;Ft<et;Ft++)if(Ft in ht&&He.call(void 0,ht[Ft],Ft,_e)){He=Ft;break e}He=-1}return 0>He?null:typeof _e=="string"?_e.charAt(He):_e[He]}var W=String.prototype.trim?function(_e){return _e.trim()}:function(_e){return/^[\s\xa0]*([\s\S]*?)[\s\xa0]*$/.exec(_e)[1]};function Y(_e,He){return _e.indexOf(He)!=-1}function te(_e,He){return _e<He?-1:_e>He?1:0}var oe;e:{var de=s.navigator;if(de){var ge=de.userAgent;if(ge){oe=ge;break e}}oe=""}function Ee(_e,He){for(var et in _e)He.call(void 0,_e[et],et,_e)}function Re(_e,He){var et={},ht;for(ht in _e)et[ht]=He.call(void 0,_e[ht],ht,_e);return et}var Ae="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function Pe(_e,He){for(var et,ht,Ft=1;Ft<arguments.length;Ft++){ht=arguments[Ft];for(et in ht)_e[et]=ht[et];for(var ur=0;ur<Ae.length;ur++)et=Ae[ur],Object.prototype.hasOwnProperty.call(ht,et)&&(_e[et]=ht[et])}}function we(_e){var He=1;_e=_e.split(":");for(var et=[];0<He&&_e.length;)et.push(_e.shift()),He--;return _e.length&&et.push(_e.join(":")),et}function Te(_e){return Te[" "](_e),_e}Te[" "]=u;function ke(_e,He){var et=xt;return Object.prototype.hasOwnProperty.call(et,_e)?et[_e]:et[_e]=He(_e)}var $e=Y(oe,"Opera"),Ne=Y(oe,"Trident")||Y(oe,"MSIE"),ve=Y(oe,"Edge"),pe=Y(oe,"Gecko")&&!(Y(oe.toLowerCase(),"webkit")&&!Y(oe,"Edge"))&&!(Y(oe,"Trident")||Y(oe,"MSIE"))&&!Y(oe,"Edge"),fe=Y(oe.toLowerCase(),"webkit")&&!Y(oe,"Edge");function me(){var _e=s.document;return _e?_e.documentMode:void 0}var Ce;e:{var Ue="",Qe=(function(){var _e=oe;if(pe)return/rv:([^\);]+)(\)|;)/.exec(_e);if(ve)return/Edge\/([\d\.]+)/.exec(_e);if(Ne)return/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(_e);if(fe)return/WebKit\/(\S+)/.exec(_e);if($e)return/(?:Version)[ \/]?(\S+)/.exec(_e)})();if(Qe&&(Ue=Qe?Qe[1]:""),Ne){var it=me();if(it!=null&&it>parseFloat(Ue)){Ce=String(it);break e}}Ce=Ue}var xt={};function wt(_e){return ke(_e,function(){for(var He=0,et=W(String(Ce)).split("."),ht=W(String(_e)).split("."),Ft=Math.max(et.length,ht.length),ur=0;He==0&&ur<Ft;ur++){var Lt=et[ur]||"",Kt=ht[ur]||"";do{if(Lt=/(\d*)(\D*)(.*)/.exec(Lt)||["","","",""],Kt=/(\d*)(\D*)(.*)/.exec(Kt)||["","","",""],Lt[0].length==0&&Kt[0].length==0)break;He=te(Lt[1].length==0?0:parseInt(Lt[1],10),Kt[1].length==0?0:parseInt(Kt[1],10))||te(Lt[2].length==0,Kt[2].length==0)||te(Lt[2],Kt[2]),Lt=Lt[3],Kt=Kt[3]}while(He==0)}return 0<=He})}var $t;if(s.document&&Ne){var Mt=me();$t=Mt||parseInt(Ce,10)||void 0}else $t=void 0;var rt=$t;function qe(){this.F=this.F}qe.prototype.F=!1;var vt=Object.freeze||function(_e){return _e},kt;(kt=!Ne)||(kt=9<=Number(rt));var Xe=kt,_t=Ne&&!wt("9"),Ht=(function(){if(!s.addEventListener||!Object.defineProperty)return!1;var _e=!1,He=Object.defineProperty({},"passive",{get:function(){_e=!0}});try{s.addEventListener("test",u,He),s.removeEventListener("test",u,He)}catch{}return _e})();function Pt(_e,He){this.type=_e,this.a=this.target=He,this.defaultPrevented=!1}Pt.prototype.b=function(){this.defaultPrevented=!0};function Jt(_e,He){if(Pt.call(this,_e?_e.type:""),this.relatedTarget=this.a=this.target=null,this.button=this.screenY=this.screenX=this.clientY=this.clientX=0,this.key="",this.metaKey=this.shiftKey=this.altKey=this.ctrlKey=!1,this.pointerId=0,this.pointerType="",this.c=null,_e){var et=this.type=_e.type,ht=_e.changedTouches&&_e.changedTouches.length?_e.changedTouches[0]:null;if(this.target=_e.target||_e.srcElement,this.a=He,He=_e.relatedTarget){if(pe){e:{try{Te(He.nodeName);var Ft=!0;break e}catch{}Ft=!1}Ft||(He=null)}}else et=="mouseover"?He=_e.fromElement:et=="mouseout"&&(He=_e.toElement);this.relatedTarget=He,ht?(this.clientX=ht.clientX!==void 0?ht.clientX:ht.pageX,this.clientY=ht.clientY!==void 0?ht.clientY:ht.pageY,this.screenX=ht.screenX||0,this.screenY=ht.screenY||0):(this.clientX=_e.clientX!==void 0?_e.clientX:_e.pageX,this.clientY=_e.clientY!==void 0?_e.clientY:_e.pageY,this.screenX=_e.screenX||0,this.screenY=_e.screenY||0),this.button=_e.button,this.key=_e.key||"",this.ctrlKey=_e.ctrlKey,this.altKey=_e.altKey,this.shiftKey=_e.shiftKey,this.metaKey=_e.metaKey,this.pointerId=_e.pointerId||0,this.pointerType=typeof _e.pointerType=="string"?_e.pointerType:zt[_e.pointerType]||"",this.c=_e,_e.defaultPrevented&&this.b()}}g(Jt,Pt);var zt=vt({2:"touch",3:"pen",4:"mouse"});Jt.prototype.b=function(){Jt.S.b.call(this);var _e=this.c;if(_e.preventDefault)_e.preventDefault();else if(_e.returnValue=!1,_t)try{(_e.ctrlKey||112<=_e.keyCode&&123>=_e.keyCode)&&(_e.keyCode=-1)}catch{}};var Bt="closure_listenable_"+(1e6*Math.random()|0),Mr=0;function Be(_e,He,et,ht,Ft){this.listener=_e,this.proxy=null,this.src=He,this.type=et,this.capture=!!ht,this.A=Ft,this.key=++Mr,this.s=this.v=!1}function We(_e){_e.s=!0,_e.listener=null,_e.proxy=null,_e.src=null,_e.A=null}function dt(_e){this.src=_e,this.a={},this.b=0}dt.prototype.add=function(_e,He,et,ht,Ft){var ur=_e.toString();_e=this.a[ur],_e||(_e=this.a[ur]=[],this.b++);var Lt=nr(_e,He,ht,Ft);return-1<Lt?(He=_e[Lt],et||(He.v=!1)):(He=new Be(He,this.src,ur,!!ht,Ft),He.v=et,_e.push(He)),He};function Tt(_e,He){var et=He.type;if(et in _e.a){var ht=_e.a[et],Ft=k(ht,He),ur;(ur=0<=Ft)&&Array.prototype.splice.call(ht,Ft,1),ur&&(We(He),_e.a[et].length==0&&(delete _e.a[et],_e.b--))}}function nr(_e,He,et,ht){for(var Ft=0;Ft<_e.length;++Ft){var ur=_e[Ft];if(!ur.s&&ur.listener==He&&ur.capture==!!et&&ur.A==ht)return Ft}return-1}var Ar="closure_lm_"+(1e6*Math.random()|0),Qr={};function Si(_e,He,et,ht,Ft){if(ht&&ht.once)vi(_e,He,et,ht,Ft);else if(Array.isArray(He))for(var ur=0;ur<He.length;ur++)Si(_e,He[ur],et,ht,Ft);else et=ce(et),_e&&_e[Bt]?_e.f.add(String(He),et,!1,d(ht)?!!ht.capture:!!ht,Ft):oi(_e,He,et,!1,ht,Ft)}function oi(_e,He,et,ht,Ft,ur){if(!He)throw Error("Invalid event type");var Lt=d(Ft)?!!Ft.capture:!!Ft,Kt=mt(_e);if(Kt||(_e[Ar]=Kt=new dt(_e)),et=Kt.add(He,et,ht,Lt,ur),!et.proxy)if(ht=Yr(),et.proxy=ht,ht.src=_e,ht.listener=et,_e.addEventListener)Ht||(Ft=Lt),Ft===void 0&&(Ft=!1),_e.addEventListener(He.toString(),ht,Ft);else if(_e.attachEvent)_e.attachEvent(qn(He.toString()),ht);else if(_e.addListener&&_e.removeListener)_e.addListener(ht);else throw Error("addEventListener and attachEvent are unavailable.")}function Yr(){var _e=xn,He=Xe?function(et){return _e.call(He.src,He.listener,et)}:function(et){if(et=_e.call(He.src,He.listener,et),!et)return et};return He}function vi(_e,He,et,ht,Ft){if(Array.isArray(He))for(var ur=0;ur<He.length;ur++)vi(_e,He[ur],et,ht,Ft);else et=ce(et),_e&&_e[Bt]?_e.f.add(String(He),et,!0,d(ht)?!!ht.capture:!!ht,Ft):oi(_e,He,et,!0,ht,Ft)}function rr(_e,He,et,ht,Ft){if(Array.isArray(He))for(var ur=0;ur<He.length;ur++)rr(_e,He[ur],et,ht,Ft);else ht=d(ht)?!!ht.capture:!!ht,et=ce(et),_e&&_e[Bt]?(_e=_e.f,He=String(He).toString(),He in _e.a&&(ur=_e.a[He],et=nr(ur,et,ht,Ft),-1<et&&(We(ur[et]),Array.prototype.splice.call(ur,et,1),ur.length==0&&(delete _e.a[He],_e.b--)))):_e&&(_e=mt(_e))&&(He=_e.a[He.toString()],_e=-1,He&&(_e=nr(He,et,ht,Ft)),(et=-1<_e?He[_e]:null)&&Ji(et))}function Ji(_e){if(typeof _e!="number"&&_e&&!_e.s){var He=_e.src;if(He&&He[Bt])Tt(He.f,_e);else{var et=_e.type,ht=_e.proxy;He.removeEventListener?He.removeEventListener(et,ht,_e.capture):He.detachEvent?He.detachEvent(qn(et),ht):He.addListener&&He.removeListener&&He.removeListener(ht),(et=mt(He))?(Tt(et,_e),et.b==0&&(et.src=null,He[Ar]=null)):We(_e)}}}function qn(_e){return _e in Qr?Qr[_e]:Qr[_e]="on"+_e}function ri(_e,He,et,ht){var Ft=!0;if((_e=mt(_e))&&(He=_e.a[He.toString()]))for(He=He.concat(),_e=0;_e<He.length;_e++){var ur=He[_e];ur&&ur.capture==et&&!ur.s&&(ur=eo(ur,ht),Ft=Ft&&ur!==!1)}return Ft}function eo(_e,He){var et=_e.listener,ht=_e.A||_e.src;return _e.v&&Ji(_e),et.call(ht,He)}function xn(_e,He){if(_e.s)return!0;if(!Xe){var et=He||l("window.event");He=new Jt(et,this);var ht=!0;if(!(0>et.keyCode||et.returnValue!=null)){e:{var Ft=!1;if(et.keyCode==0)try{et.keyCode=-1;break e}catch{Ft=!0}(Ft||et.returnValue==null)&&(et.returnValue=!0)}for(et=[],Ft=He.a;Ft;Ft=Ft.parentNode)et.push(Ft);for(_e=_e.type,Ft=et.length-1;0<=Ft;Ft--){He.a=et[Ft];var ur=ri(et[Ft],_e,!0,He);ht=ht&&ur}for(Ft=0;Ft<et.length;Ft++)He.a=et[Ft],ur=ri(et[Ft],_e,!1,He),ht=ht&&ur}return ht}return eo(_e,new Jt(He,this))}function mt(_e){return _e=_e[Ar],_e instanceof dt?_e:null}var gr="__closure_events_fn_"+(1e9*Math.random()>>>0);function ce(_e){return c(_e)=="function"?_e:(_e[gr]||(_e[gr]=function(He){return _e.handleEvent(He)}),_e[gr])}function fr(){qe.call(this),this.f=new dt(this),this.N=this}g(fr,qe),fr.prototype[Bt]=!0,fr.prototype.addEventListener=function(_e,He,et,ht){Si(this,_e,He,et,ht)},fr.prototype.removeEventListener=function(_e,He,et,ht){rr(this,_e,He,et,ht)};function Yt(_e,He){_e=_e.N;var et=He.type||He;if(typeof He=="string")He=new Pt(He,_e);else if(He instanceof Pt)He.target=He.target||_e;else{var ht=He;He=new Pt(et,_e),Pe(He,ht)}_e=He.a=_e,Lr(_e,et,!0,He),Lr(_e,et,!1,He)}function Lr(_e,He,et,ht){if(He=_e.f.a[String(He)]){He=He.concat();for(var Ft=!0,ur=0;ur<He.length;++ur){var Lt=He[ur];if(Lt&&!Lt.s&&Lt.capture==et){var Kt=Lt.listener,Zr=Lt.A||Lt.src;Lt.v&&Tt(_e.f,Lt),Ft=Kt.call(Zr,ht)!==!1&&Ft}}}}function Cr(_e,He,et){if(c(_e)=="function")et&&(_e=p(_e,et));else if(_e&&typeof _e.handleEvent=="function")_e=p(_e.handleEvent,_e);else throw Error("Invalid listener argument");return 2147483647<Number(He)?-1:s.setTimeout(_e,He||0)}function zr(_e,He,et){this.reset(_e,He,et,void 0,void 0)}zr.prototype.a=null,zr.prototype.reset=function(_e,He,et,ht,Ft){delete this.a};function fi(_e){this.f=_e,this.b=this.c=this.a=null}function to(_e,He){this.name=_e,this.value=He}to.prototype.toString=function(){return this.name};var st=new to("SEVERE",1e3),zo=new to("CONFIG",700),hi=new to("FINE",500);function si(_e){return _e.c?_e.c:_e.a?si(_e.a):(A("Root logger has no level set."),null)}fi.prototype.log=function(_e,He,et){if(_e.value>=si(this).value)for(c(He)=="function"&&(He=He()),_e=new zr(_e,String(He),this.f),et&&(_e.a=et),et=this;et;)et=et.a};var sr={},Ns=null;function ts(_e){Ns||(Ns=new fi(""),sr[""]=Ns,Ns.c=zo);var He;if(!(He=sr[_e])){He=new fi(_e);var et=_e.lastIndexOf("."),ht=_e.substr(et+1);et=ts(_e.substr(0,et)),et.b||(et.b={}),et.b[ht]=He,He.a=et,sr[_e]=He}return He}function Z(_e,He){_e&&_e.log(hi,He,void 0)}function re(){}re.prototype.a=null;function ye(_e){var He;return(He=_e.a)||(He={},pr(_e)&&(He[0]=!0,He[1]=!0),He=_e.a=He),He}var Ye;function gt(){}g(gt,re);function Dt(_e){return(_e=pr(_e))?new ActiveXObject(_e):new XMLHttpRequest}function pr(_e){if(!_e.b&&typeof XMLHttpRequest>"u"&&typeof ActiveXObject<"u"){for(var He=["MSXML2.XMLHTTP.6.0","MSXML2.XMLHTTP.3.0","MSXML2.XMLHTTP","Microsoft.XMLHTTP"],et=0;et<He.length;et++){var ht=He[et];try{return new ActiveXObject(ht),_e.b=ht}catch{}}throw Error("Could not create ActiveXObject. ActiveX might be disabled, or MSXML might not be installed")}return _e.b}Ye=new gt;function Gr(_e,He){this.b={},this.a=[],this.c=0;var et=arguments.length;if(1<et){if(et%2)throw Error("Uneven number of arguments");for(var ht=0;ht<et;ht+=2)this.set(arguments[ht],arguments[ht+1])}else _e&&ro(this,_e)}Gr.prototype.f=function(){return rn(this),this.a.concat()};function rn(_e){if(_e.c!=_e.a.length){for(var He=0,et=0;He<_e.a.length;){var ht=_e.a[He];na(_e.b,ht)&&(_e.a[et++]=ht),He++}_e.a.length=et}if(_e.c!=_e.a.length){var Ft={};for(et=He=0;He<_e.a.length;)ht=_e.a[He],na(Ft,ht)||(_e.a[et++]=ht,Ft[ht]=1),He++;_e.a.length=et}}Gr.prototype.get=function(_e,He){return na(this.b,_e)?this.b[_e]:He},Gr.prototype.set=function(_e,He){na(this.b,_e)||(this.c++,this.a.push(_e)),this.b[_e]=He};function ro(_e,He){if(He instanceof Gr)for(var et=He.f(),ht=0;ht<et.length;ht++)_e.set(et[ht],He.get(et[ht]));else for(et in He)_e.set(et,He[et])}Gr.prototype.forEach=function(_e,He){for(var et=this.f(),ht=0;ht<et.length;ht++){var Ft=et[ht],ur=this.get(Ft);_e.call(He,ur,Ft,this)}};function na(_e,He){return Object.prototype.hasOwnProperty.call(_e,He)}var yl=/^(?:([^:/?#.]+):)?(?:\/\/(?:([^\\/?#]*)@)?([^\\/?#]*?)(?::([0-9]+))?(?=[\\/?#]|$))?([^?#]+)?(?:\?([^#]*))?(?:#([\s\S]*))?$/;function Ga(_e){fr.call(this),this.headers=new Gr,this.D=_e||null,this.c=!1,this.C=this.a=null,this.J=this.o="",this.g=0,this.i="",this.h=this.I=this.m=this.G=!1,this.l=0,this.u=null,this.j=ys,this.B=this.H=!1}g(Ga,fr);var ys="",tc=Ga.prototype,rs=ts("goog.net.XhrIo");tc.b=rs;var rc=/^https?$/i,Hl=["POST","PUT"];function fu(_e,He,et){if(_e.a)throw Error("[goog.net.XhrIo] Object is active with another request="+_e.o+"; newUri="+He);_e.o=He,_e.i="",_e.g=0,_e.J="POST",_e.G=!1,_e.c=!0,_e.a=_e.D?Dt(_e.D):Dt(Ye),_e.C=_e.D?ye(_e.D):ye(Ye),_e.a.onreadystatechange=p(_e.K,_e);try{Z(_e.b,Ta(_e,"Opening Xhr")),_e.I=!0,_e.a.open("POST",String(He),!0),_e.I=!1}catch(ur){Z(_e.b,Ta(_e,"Error opening Xhr: "+ur.message)),rl(_e,ur);return}He=et||"",et=new Gr(_e.headers);var ht=X(et.f()),Ft=s.FormData&&He instanceof s.FormData;!(0<=k(Hl,"POST"))||ht||Ft||et.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8"),et.forEach(function(ur,Lt){this.a.setRequestHeader(Lt,ur)},_e),_e.j&&(_e.a.responseType=_e.j),"withCredentials"in _e.a&&_e.a.withCredentials!==_e.H&&(_e.a.withCredentials=_e.H);try{cd(_e),0<_e.l&&(_e.B=hu(_e.a),Z(_e.b,Ta(_e,"Will abort after "+_e.l+"ms if incomplete, xhr2 "+_e.B)),_e.B?(_e.a.timeout=_e.l,_e.a.ontimeout=p(_e.L,_e)):_e.u=Cr(_e.L,_e.l,_e)),Z(_e.b,Ta(_e,"Sending request")),_e.m=!0,_e.a.send(He),_e.m=!1}catch(ur){Z(_e.b,Ta(_e,"Send error: "+ur.message)),rl(_e,ur)}}function hu(_e){return Ne&&wt(9)&&typeof _e.timeout=="number"&&_e.ontimeout!==void 0}function ic(_e){return _e.toLowerCase()=="content-type"}Ga.prototype.L=function(){typeof a<"u"&&this.a&&(this.i="Timed out after "+this.l+"ms, aborting",this.g=8,Z(this.b,Ta(this,this.i)),Yt(this,"timeout"),this.abort(8))};function rl(_e,He){_e.c=!1,_e.a&&(_e.h=!0,_e.a.abort(),_e.h=!1),_e.i=He,_e.g=5,oa(_e),Ya(_e)}function oa(_e){_e.G||(_e.G=!0,Yt(_e,"complete"),Yt(_e,"error"))}Ga.prototype.abort=function(_e){this.a&&this.c&&(Z(this.b,Ta(this,"Aborting")),this.c=!1,this.h=!0,this.a.abort(),this.h=!1,this.g=_e||7,Yt(this,"complete"),Yt(this,"abort"),Ya(this))},Ga.prototype.K=function(){this.F||(this.I||this.m||this.h?Wd(this):this.O())},Ga.prototype.O=function(){Wd(this)};function Wd(_e){if(_e.c&&typeof a<"u"){if(_e.C[1]&&ml(_e)==4&&_e.getStatus()==2)Z(_e.b,Ta(_e,"Local request error detected and ignored"));else if(_e.m&&ml(_e)==4)Cr(_e.K,0,_e);else if(Yt(_e,"readystatechange"),ml(_e)==4){Z(_e.b,Ta(_e,"Request complete")),_e.c=!1;try{var He=_e.getStatus();e:switch(He){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:var et=!0;break e;default:et=!1}var ht;if(!(ht=et)){var Ft;if(Ft=He===0){var ur=String(_e.o).match(yl)[1]||null;if(!ur&&s.self&&s.self.location){var Lt=s.self.location.protocol;ur=Lt.substr(0,Lt.length-1)}Ft=!rc.test(ur?ur.toLowerCase():"")}ht=Ft}if(ht)Yt(_e,"complete"),Yt(_e,"success");else{_e.g=6;try{var Kt=2<ml(_e)?_e.a.statusText:""}catch(Zr){Z(_e.b,"Can not get status: "+Zr.message),Kt=""}_e.i=Kt+" ["+_e.getStatus()+"]",oa(_e)}}finally{Ya(_e)}}}}function Ya(_e){if(_e.a){cd(_e);var He=_e.a,et=_e.C[0]?u:null;_e.a=null,_e.C=null,Yt(_e,"ready");try{He.onreadystatechange=et}catch(ht){(_e=_e.b)&&_e.log(st,"Problem encountered resetting onreadystatechange: "+ht.message,void 0)}}}function cd(_e){_e.a&&_e.B&&(_e.a.ontimeout=null),_e.u&&(s.clearTimeout(_e.u),_e.u=null)}function ml(_e){return _e.a?_e.a.readyState:0}Ga.prototype.getStatus=function(){try{return 2<ml(this)?this.a.status:-1}catch{return-1}};function Fs(_e){try{if(!_e.a)return null;if("response"in _e.a)return _e.a.response;switch(_e.j){case ys:case"text":return _e.a.responseText;case"arraybuffer":if("mozResponseArrayBuffer"in _e.a)return _e.a.mozResponseArrayBuffer}var He=_e.b;return He&&He.log(st,"Response type "+_e.j+" is not supported on this browser",void 0),null}catch(et){return Z(_e.b,"Can not get response: "+et.message),null}}function Ul(_e,He){if(_e.a&&ml(_e)==4)return _e=_e.a.getResponseHeader(He),_e===null?void 0:_e}function wo(_e){var He={};_e=(_e.a&&ml(_e)==4&&_e.a.getAllResponseHeaders()||"").split(`\r
`);for(var et=0;et<_e.length;et++)if(!/^[\s\xa0]*$/.test(_e[et])){var ht=we(_e[et]),Ft=ht[0];if(ht=ht[1],typeof ht=="string"){ht=ht.trim();var ur=He[Ft]||[];He[Ft]=ur,ur.push(ht)}}return Re(He,function(Lt){return Lt.join(", ")})}function Ta(_e,He){return He+" ["+_e.J+" "+_e.o+" "+_e.getStatus()+"]"}var Lo={},ao=null;function bl(_e){var He=_e.length,et=3*He/4;et%3?et=Math.floor(et):Y("=.",_e[He-1])&&(et=Y("=.",_e[He-2])?et-2:et-1);var ht=new Uint8Array(et),Ft=0;return nc(_e,function(ur){ht[Ft++]=ur}),ht.subarray(0,Ft)}function nc(_e,He){function et(Zr){for(;ht<_e.length;){var ni=_e.charAt(ht++),pi=ao[ni];if(pi!=null)return pi;if(!/^[\s\xa0]*$/.test(ni))throw Error("Unknown base64 encoding at char: "+ni)}return Zr}Vu();for(var ht=0;;){var Ft=et(-1),ur=et(0),Lt=et(64),Kt=et(64);if(Kt===64&&Ft===-1)break;He(Ft<<2|ur>>4),Lt!=64&&(He(ur<<4&240|Lt>>2),Kt!=64&&He(Lt<<6&192|Kt))}}function Vu(){if(!ao){ao={};for(var _e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789".split(""),He=["+/=","+/","-_=","-_.","-_"],et=0;5>et;et++){var ht=_e.concat(He[et].split(""));Lo[et]=ht;for(var Ft=0;Ft<ht.length;Ft++){var ur=ht[Ft];ao[ur]===void 0&&(ao[ur]=Ft)}}}}var dd=["content-type","grpc-status","grpc-message"];function xa(_e){this.a=_e.T,this.l=null,this.b=[],this.h=[],this.g=[],this.f=[],this.c=[],this.j=!1,this.i=0,this.m=new R;var He=this;Si(this.a,"readystatechange",function(){var et=He.a;if(et=et.a?et.a.getResponseHeader("Content-Type"):null){if(et=et.toLowerCase(),et.lastIndexOf("application/grpc-web-text",0)==0){et=He.a;try{var ht=et.a?et.a.responseText:""}catch(ni){Z(et.b,"Can not get responseText: "+ni.message),ht=""}if(et=ht||"",ht=et.length-et.length%4,et=et.substr(He.i,ht-He.i),et.length==0)return;He.i=ht,et=bl(et)}else if(et.lastIndexOf("application/grpc",0)==0)et=new Uint8Array(Fs(He.a));else{va(He,{code:2,message:"Unknown Content-type received.",metadata:{}});return}ht=null;try{ht=M(He.m,et)}catch{va(He,{code:2,message:"Error in parsing response body",metadata:{}})}if(ht)for(et=0;et<ht.length;et++){if(z in ht[et]){var Ft=ht[et][z];if(Ft)try{var ur=He.l(Ft);if(ur){Ft=He;for(var Lt=ur,Kt=0;Kt<Ft.b.length;Kt++)Ft.b[Kt](Lt)}}catch{va(He,{code:2,message:"Error in response deserializer function.",metadata:{}})}}if(G in ht[et]&&0<ht[et][G].length){for(Ft="",Lt=0;Lt<ht[et][G].length;Lt++)Ft+=String.fromCharCode(ht[et][G][Lt]);for(Ft=Ft.trim().split(`\r
`),Lt={},Kt=0;Kt<Ft.length;Kt++){var Zr=Ft[Kt].indexOf(":");Lt[Ft[Kt].substring(0,Zr).trim()]=Ft[Kt].substring(Zr+1).trim()}Ft=Lt,Lt=0,Kt="","grpc-status"in Ft&&(Lt=Ft["grpc-status"],delete Ft["grpc-status"]),"grpc-message"in Ft&&(Kt=Ft["grpc-message"],delete Ft["grpc-message"]),va(He,{code:Number(Lt),message:Kt,metadata:Ft})}}}}),Si(this.a,"complete",function(){var et=He.a.g,ht="",Ft={},ur=wo(He.a);if(Object.keys(ur).forEach(function(Kt){dd.includes(Kt)||(Ft[Kt]=ur[Kt])}),Gd(He,Ft),et!=0){switch(et){case 7:var Lt=10;break;case 8:Lt=4;break;case 6:Lt=U(He.a.getStatus());break;default:Lt=14}Lt==10&&He.j||va(He,{code:Lt,message:P(et),metadata:{}})}else et=!1,"grpc-status"in ur&&(Lt=Ul(He.a,"grpc-status"),"grpc-message"in ur&&(ht=Ul(He.a,"grpc-message")),Number(Lt)!=0&&(va(He,{code:Number(Lt),message:ht,metadata:ur}),et=!0)),et||Oc(He)})}xa.prototype.on=function(_e,He){return _e=="data"?this.b.push(He):_e=="status"?this.h.push(He):_e=="metadata"?this.g.push(He):_e=="end"?this.c.push(He):_e=="error"&&this.f.push(He),this};function Fa(_e,He){He=_e.indexOf(He),-1<He&&_e.splice(He,1)}xa.prototype.removeListener=function(_e,He){return _e=="data"?Fa(this.b,He):_e=="status"?Fa(this.h,He):_e=="metadata"?Fa(this.g,He):_e=="end"?Fa(this.c,He):_e=="error"&&Fa(this.f,He),this},xa.prototype.cancel=function(){this.j=!0,this.a.abort()};function va(_e,He){if(He.code!=0)for(var et={code:He.code,message:decodeURIComponent(He.message||""),metadata:He.metadata},ht=0;ht<_e.f.length;ht++)_e.f[ht](et);for(He={code:He.code,details:decodeURIComponent(He.message||""),metadata:He.metadata},et=0;et<_e.h.length;et++)_e.h[et](He)}function Gd(_e,He){for(var et=0;et<_e.g.length;et++)_e.g[et](He)}function Oc(_e){for(var He=0;He<_e.c.length;He++)_e.c[He]()}xa.prototype.cancel=xa.prototype.cancel,xa.prototype.removeListener=xa.prototype.removeListener,xa.prototype.on=xa.prototype.on;function il(_e){var He="";return Ee(_e,function(et,ht){He+=ht,He+=":",He+=et,He+=`\r
`}),He}function aa(_e){this.a=l("format",_e)||"text",this.f=l("suppressCorsPreflight",_e)||!1,this.c=l("withCredentials",_e)||!1,this.b=l("streamInterceptors",_e)||[],this.g=l("unaryInterceptors",_e)||[]}aa.prototype.P=function(_e,He,et,ht,Ft){var ur=this;ht=_(_e,He,"unary",ht);var Lt=_e.substr(0,_e.length-ht.name.length);return _e=oc(function(Kt){return Qi(ur,Kt,Lt)},this.b).call(this,S(ht,He,et)),mn(_e,Ft,!1),new C(_e)},aa.prototype.M=function(_e,He,et,ht){var Ft=this;ht=_(_e,He,"unary",ht);var ur=_e.substr(0,_e.length-ht.name.length);return oc(function(Lt){return new Promise(function(Kt,Zr){var ni=Qi(Ft,Lt,ur),pi,Oi,Bi;mn(ni,function(ms,Ba,Sl,zl){ms?Zr(ms):Ba?Bi=Ba:Sl?Oi=Sl:zl?pi=zl:(ms=Lt.getMethodDescriptor(),Ba=pi,Ba=Ba===void 0?{}:Ba,Kt(new m(Bi,ms,Ba,Oi===void 0?null:Oi)))},!0)})},this.g).call(this,S(ht,He,et)).then(function(Lt){return Lt.getResponseMessage()})},aa.prototype.unaryCall=function(_e,He,et,ht){return this.M(_e,He,et,ht)},aa.prototype.R=function(_e,He,et,ht){var Ft=this;ht=_(_e,He,"server_streaming",ht);var ur=_e.substr(0,_e.length-ht.name.length);return oc(function(Lt){return Qi(Ft,Lt,ur)},this.b).call(this,S(ht,He,et))};function Qi(_e,He,et){var ht=He.getMethodDescriptor(),Ft=et+ht.name;et=new Ga,et.H=_e.c;var ur=new xa({T:et});if(ur.l=ht.b,ro(et.headers,He.getMetadata()),_e.a=="text"?(et.headers.set("Content-Type","application/grpc-web-text"),et.headers.set("Accept","application/grpc-web-text")):et.headers.set("Content-Type","application/grpc-web+proto"),et.headers.set("X-User-Agent","grpc-web-javascript/0.1"),et.headers.set("X-Grpc-Web","1"),na(et.headers.b,"deadline")){var Lt=et.headers.get("deadline");Lt=Math.round(Lt-new Date().getTime());var Kt=et.headers;na(Kt.b,"deadline")&&(delete Kt.b.deadline,Kt.c--,Kt.a.length>2*Kt.c&&rn(Kt)),Lt===1/0&&(Lt=0),0<Lt&&et.headers.set("grpc-timeout",Lt+"m")}if(_e.f){Kt=et.headers,rn(Kt),Lt={};for(var Zr=0;Zr<Kt.a.length;Zr++){var ni=Kt.a[Zr];Lt[ni]=Kt.b[ni]}Kt=et.headers,Kt.b={},Kt.a.length=0,Kt.c=0;e:{for(pi in Lt){var pi=!1;break e}pi=!0}pi||(Lt=il(Lt),typeof Ft=="string"?(pi=encodeURIComponent("$httpHeaders"),Lt=Lt!=null?"="+encodeURIComponent(String(Lt)):"",(pi+=Lt)&&(Lt=Ft.indexOf("#"),0>Lt&&(Lt=Ft.length),Kt=Ft.indexOf("?"),0>Kt||Kt>Lt?(Kt=Lt,Zr=""):Zr=Ft.substring(Kt+1,Lt),Ft=[Ft.substr(0,Kt),Zr,Ft.substr(Lt)],Lt=Ft[1],Ft[1]=pi?Lt?Lt+"&"+pi:pi:Lt,Ft=Ft[0]+(Ft[1]?"?"+Ft[1]:"")+Ft[2])):Ft.a("$httpHeaders",Lt))}for(He=(0,ht.a)(He.getRequestMessage()),ht=He.length,pi=[0,0,0,0],Lt=new Uint8Array(5+ht),Kt=3;0<=Kt;Kt--)pi[Kt]=ht%256,ht>>>=8;if(Lt.set(new Uint8Array(pi),1),Lt.set(He,5),He=Lt,_e.a=="text"){_e=He;var Oi;for(Oi===void 0&&(Oi=0),Vu(),Oi=Lo[Oi],He=[],ht=0;ht<_e.length;ht+=3){ni=_e[ht];var Bi=(pi=ht+1<_e.length)?_e[ht+1]:0;Zr=(Lt=ht+2<_e.length)?_e[ht+2]:0,Kt=ni>>2,ni=(ni&3)<<4|Bi>>4,Bi=(Bi&15)<<2|Zr>>6,Zr&=63,Lt||(Zr=64,pi||(Bi=64)),He.push(Oi[Kt],Oi[ni],Oi[Bi]||"",Oi[Zr]||"")}He=He.join("")}else _e.a=="binary"&&(et.j="arraybuffer");return fu(et,Ft,He),ur}function mn(_e,He,et){var ht=null,Ft=!1;_e.on("data",function(ur){ht=ur}),_e.on("error",function(ur){ur.code==0||Ft||(Ft=!0,He(ur,null))}),_e.on("status",function(ur){ur.code==0||Ft?et&&He(null,null,ur):(Ft=!0,He({code:ur.code,message:ur.details,metadata:ur.metadata},null))}),et&&_e.on("metadata",function(ur){He(null,null,null,ur)}),_e.on("end",function(){Ft||(ht==null?He({code:2,message:"Incomplete response"}):He(null,ht)),et&&He(null,null)})}function oc(_e,He){var et=_e;return He.forEach(function(ht){var Ft=et;et=function(ur){return ht.intercept(ur,Ft)}}),et}return aa.prototype.serverStreaming=aa.prototype.R,aa.prototype.unaryCall=aa.prototype.unaryCall,aa.prototype.thenableCall=aa.prototype.M,aa.prototype.rpcCall=aa.prototype.P,D0.AbstractClientBase={MethodInfo:function(_e,He,et,ht,Ft){this.name=ht,this.b=Ft,this.f=_e,this.a=He,this.c=et}},D0.GrpcWebClientBase=aa,D0.StatusCode={OK:0,CANCELLED:1,UNKNOWN:2,INVALID_ARGUMENT:3,DEADLINE_EXCEEDED:4,NOT_FOUND:5,ALREADY_EXISTS:6,PERMISSION_DENIED:7,UNAUTHENTICATED:16,RESOURCE_EXHAUSTED:8,FAILED_PRECONDITION:9,ABORTED:10,OUT_OF_RANGE:11,UNIMPLEMENTED:12,INTERNAL:13,UNAVAILABLE:14,DATA_LOSS:15},D0.MethodDescriptor=b,D0.MethodType={UNARY:"unary",SERVER_STREAMING:"server_streaming"},D0}var bY={},SY={},tce;function B0t(){return tce||(tce=1,(function(t){var e=qP(),i=e,n=Function("return this")();i.exportSymbol("proto.google.api.CustomHttpPattern",null,n),i.exportSymbol("proto.google.api.Http",null,n),i.exportSymbol("proto.google.api.HttpRule",null,n),i.exportSymbol("proto.google.api.HttpRule.PatternCase",null,n),proto.google.api.Http=function(r){e.Message.initialize(this,r,0,-1,proto.google.api.Http.repeatedFields_,null)},i.inherits(proto.google.api.Http,e.Message),i.DEBUG&&!COMPILED&&(proto.google.api.Http.displayName="proto.google.api.Http"),proto.google.api.HttpRule=function(r){e.Message.initialize(this,r,0,-1,proto.google.api.HttpRule.repeatedFields_,proto.google.api.HttpRule.oneofGroups_)},i.inherits(proto.google.api.HttpRule,e.Message),i.DEBUG&&!COMPILED&&(proto.google.api.HttpRule.displayName="proto.google.api.HttpRule"),proto.google.api.CustomHttpPattern=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.api.CustomHttpPattern,e.Message),i.DEBUG&&!COMPILED&&(proto.google.api.CustomHttpPattern.displayName="proto.google.api.CustomHttpPattern"),proto.google.api.Http.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.api.Http.prototype.toObject=function(r){return proto.google.api.Http.toObject(r,this)},proto.google.api.Http.toObject=function(r,o){var a={rulesList:e.Message.toObjectList(o.getRulesList(),proto.google.api.HttpRule.toObject,r),fullyDecodeReservedExpansion:e.Message.getBooleanFieldWithDefault(o,2,!1)};return r&&(a.$jspbMessageInstance=o),a}),proto.google.api.Http.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.api.Http;return proto.google.api.Http.deserializeBinaryFromReader(a,o)},proto.google.api.Http.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.api.HttpRule;o.readMessage(s,proto.google.api.HttpRule.deserializeBinaryFromReader),r.addRules(s);break;case 2:var s=o.readBool();r.setFullyDecodeReservedExpansion(s);break;default:o.skipField();break}}return r},proto.google.api.Http.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.api.Http.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.api.Http.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getRulesList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.google.api.HttpRule.serializeBinaryToWriter),a=r.getFullyDecodeReservedExpansion(),a&&o.writeBool(2,a)},proto.google.api.Http.prototype.getRulesList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.api.HttpRule,1)},proto.google.api.Http.prototype.setRulesList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.google.api.Http.prototype.addRules=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.google.api.HttpRule,o)},proto.google.api.Http.prototype.clearRulesList=function(){return this.setRulesList([])},proto.google.api.Http.prototype.getFullyDecodeReservedExpansion=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.google.api.Http.prototype.setFullyDecodeReservedExpansion=function(r){return e.Message.setProto3BooleanField(this,2,r)},proto.google.api.HttpRule.repeatedFields_=[11],proto.google.api.HttpRule.oneofGroups_=[[2,3,4,5,6,8]],proto.google.api.HttpRule.PatternCase={PATTERN_NOT_SET:0,GET:2,PUT:3,POST:4,DELETE:5,PATCH:6,CUSTOM:8},proto.google.api.HttpRule.prototype.getPatternCase=function(){return e.Message.computeOneofCase(this,proto.google.api.HttpRule.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.google.api.HttpRule.prototype.toObject=function(r){return proto.google.api.HttpRule.toObject(r,this)},proto.google.api.HttpRule.toObject=function(r,o){var a,s={selector:e.Message.getFieldWithDefault(o,1,""),get:e.Message.getFieldWithDefault(o,2,""),put:e.Message.getFieldWithDefault(o,3,""),post:e.Message.getFieldWithDefault(o,4,""),pb_delete:e.Message.getFieldWithDefault(o,5,""),patch:e.Message.getFieldWithDefault(o,6,""),custom:(a=o.getCustom())&&proto.google.api.CustomHttpPattern.toObject(r,a),body:e.Message.getFieldWithDefault(o,7,""),responseBody:e.Message.getFieldWithDefault(o,12,""),additionalBindingsList:e.Message.toObjectList(o.getAdditionalBindingsList(),proto.google.api.HttpRule.toObject,r)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.api.HttpRule.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.api.HttpRule;return proto.google.api.HttpRule.deserializeBinaryFromReader(a,o)},proto.google.api.HttpRule.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setSelector(s);break;case 2:var s=o.readString();r.setGet(s);break;case 3:var s=o.readString();r.setPut(s);break;case 4:var s=o.readString();r.setPost(s);break;case 5:var s=o.readString();r.setDelete(s);break;case 6:var s=o.readString();r.setPatch(s);break;case 8:var s=new proto.google.api.CustomHttpPattern;o.readMessage(s,proto.google.api.CustomHttpPattern.deserializeBinaryFromReader),r.setCustom(s);break;case 7:var s=o.readString();r.setBody(s);break;case 12:var s=o.readString();r.setResponseBody(s);break;case 11:var s=new proto.google.api.HttpRule;o.readMessage(s,proto.google.api.HttpRule.deserializeBinaryFromReader),r.addAdditionalBindings(s);break;default:o.skipField();break}}return r},proto.google.api.HttpRule.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.api.HttpRule.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.api.HttpRule.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getSelector(),a.length>0&&o.writeString(1,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=e.Message.getField(r,4),a!=null&&o.writeString(4,a),a=e.Message.getField(r,5),a!=null&&o.writeString(5,a),a=e.Message.getField(r,6),a!=null&&o.writeString(6,a),a=r.getCustom(),a!=null&&o.writeMessage(8,a,proto.google.api.CustomHttpPattern.serializeBinaryToWriter),a=r.getBody(),a.length>0&&o.writeString(7,a),a=r.getResponseBody(),a.length>0&&o.writeString(12,a),a=r.getAdditionalBindingsList(),a.length>0&&o.writeRepeatedMessage(11,a,proto.google.api.HttpRule.serializeBinaryToWriter)},proto.google.api.HttpRule.prototype.getSelector=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.api.HttpRule.prototype.setSelector=function(r){return e.Message.setProto3StringField(this,1,r)},proto.google.api.HttpRule.prototype.getGet=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.api.HttpRule.prototype.setGet=function(r){return e.Message.setOneofField(this,2,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearGet=function(){return e.Message.setOneofField(this,2,proto.google.api.HttpRule.oneofGroups_[0],void 0)},proto.google.api.HttpRule.prototype.hasGet=function(){return e.Message.getField(this,2)!=null},proto.google.api.HttpRule.prototype.getPut=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.api.HttpRule.prototype.setPut=function(r){return e.Message.setOneofField(this,3,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearPut=function(){return e.Message.setOneofField(this,3,proto.google.api.HttpRule.oneofGroups_[0],void 0)},proto.google.api.HttpRule.prototype.hasPut=function(){return e.Message.getField(this,3)!=null},proto.google.api.HttpRule.prototype.getPost=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.google.api.HttpRule.prototype.setPost=function(r){return e.Message.setOneofField(this,4,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearPost=function(){return e.Message.setOneofField(this,4,proto.google.api.HttpRule.oneofGroups_[0],void 0)},proto.google.api.HttpRule.prototype.hasPost=function(){return e.Message.getField(this,4)!=null},proto.google.api.HttpRule.prototype.getDelete=function(){return e.Message.getFieldWithDefault(this,5,"")},proto.google.api.HttpRule.prototype.setDelete=function(r){return e.Message.setOneofField(this,5,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearDelete=function(){return e.Message.setOneofField(this,5,proto.google.api.HttpRule.oneofGroups_[0],void 0)},proto.google.api.HttpRule.prototype.hasDelete=function(){return e.Message.getField(this,5)!=null},proto.google.api.HttpRule.prototype.getPatch=function(){return e.Message.getFieldWithDefault(this,6,"")},proto.google.api.HttpRule.prototype.setPatch=function(r){return e.Message.setOneofField(this,6,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearPatch=function(){return e.Message.setOneofField(this,6,proto.google.api.HttpRule.oneofGroups_[0],void 0)},proto.google.api.HttpRule.prototype.hasPatch=function(){return e.Message.getField(this,6)!=null},proto.google.api.HttpRule.prototype.getCustom=function(){return e.Message.getWrapperField(this,proto.google.api.CustomHttpPattern,8)},proto.google.api.HttpRule.prototype.setCustom=function(r){return e.Message.setOneofWrapperField(this,8,proto.google.api.HttpRule.oneofGroups_[0],r)},proto.google.api.HttpRule.prototype.clearCustom=function(){return this.setCustom(void 0)},proto.google.api.HttpRule.prototype.hasCustom=function(){return e.Message.getField(this,8)!=null},proto.google.api.HttpRule.prototype.getBody=function(){return e.Message.getFieldWithDefault(this,7,"")},proto.google.api.HttpRule.prototype.setBody=function(r){return e.Message.setProto3StringField(this,7,r)},proto.google.api.HttpRule.prototype.getResponseBody=function(){return e.Message.getFieldWithDefault(this,12,"")},proto.google.api.HttpRule.prototype.setResponseBody=function(r){return e.Message.setProto3StringField(this,12,r)},proto.google.api.HttpRule.prototype.getAdditionalBindingsList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.api.HttpRule,11)},proto.google.api.HttpRule.prototype.setAdditionalBindingsList=function(r){return e.Message.setRepeatedWrapperField(this,11,r)},proto.google.api.HttpRule.prototype.addAdditionalBindings=function(r,o){return e.Message.addToRepeatedWrapperField(this,11,r,proto.google.api.HttpRule,o)},proto.google.api.HttpRule.prototype.clearAdditionalBindingsList=function(){return this.setAdditionalBindingsList([])},e.Message.GENERATE_TO_OBJECT&&(proto.google.api.CustomHttpPattern.prototype.toObject=function(r){return proto.google.api.CustomHttpPattern.toObject(r,this)},proto.google.api.CustomHttpPattern.toObject=function(r,o){var a={kind:e.Message.getFieldWithDefault(o,1,""),path:e.Message.getFieldWithDefault(o,2,"")};return r&&(a.$jspbMessageInstance=o),a}),proto.google.api.CustomHttpPattern.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.api.CustomHttpPattern;return proto.google.api.CustomHttpPattern.deserializeBinaryFromReader(a,o)},proto.google.api.CustomHttpPattern.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setKind(s);break;case 2:var s=o.readString();r.setPath(s);break;default:o.skipField();break}}return r},proto.google.api.CustomHttpPattern.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.api.CustomHttpPattern.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.api.CustomHttpPattern.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getKind(),a.length>0&&o.writeString(1,a),a=r.getPath(),a.length>0&&o.writeString(2,a)},proto.google.api.CustomHttpPattern.prototype.getKind=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.api.CustomHttpPattern.prototype.setKind=function(r){return e.Message.setProto3StringField(this,1,r)},proto.google.api.CustomHttpPattern.prototype.getPath=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.api.CustomHttpPattern.prototype.setPath=function(r){return e.Message.setProto3StringField(this,2,r)},i.object.extend(t,proto.google.api)})(SY)),SY}var _Y={},rce;function j0t(){return rce||(rce=1,(function(t){var e=qP(),i=e,n=typeof globalThis<"u"&&globalThis||typeof window<"u"&&window||typeof n<"u"&&n||typeof self<"u"&&self||(function(){return this}).call(null)||Function("return this")();i.exportSymbol("proto.google.protobuf.DescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.DescriptorProto.ExtensionRange",null,n),i.exportSymbol("proto.google.protobuf.DescriptorProto.ReservedRange",null,n),i.exportSymbol("proto.google.protobuf.Edition",null,n),i.exportSymbol("proto.google.protobuf.EnumDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.EnumDescriptorProto.EnumReservedRange",null,n),i.exportSymbol("proto.google.protobuf.EnumOptions",null,n),i.exportSymbol("proto.google.protobuf.EnumValueDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.EnumValueOptions",null,n),i.exportSymbol("proto.google.protobuf.ExtensionRangeOptions",null,n),i.exportSymbol("proto.google.protobuf.ExtensionRangeOptions.Declaration",null,n),i.exportSymbol("proto.google.protobuf.ExtensionRangeOptions.VerificationState",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.EnumType",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.FieldPresence",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.JsonFormat",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.MessageEncoding",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.RepeatedFieldEncoding",null,n),i.exportSymbol("proto.google.protobuf.FeatureSet.Utf8Validation",null,n),i.exportSymbol("proto.google.protobuf.FeatureSetDefaults",null,n),i.exportSymbol("proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault",null,n),i.exportSymbol("proto.google.protobuf.FieldDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.FieldDescriptorProto.Label",null,n),i.exportSymbol("proto.google.protobuf.FieldDescriptorProto.Type",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.CType",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.EditionDefault",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.FeatureSupport",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.JSType",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.OptionRetention",null,n),i.exportSymbol("proto.google.protobuf.FieldOptions.OptionTargetType",null,n),i.exportSymbol("proto.google.protobuf.FileDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.FileDescriptorSet",null,n),i.exportSymbol("proto.google.protobuf.FileOptions",null,n),i.exportSymbol("proto.google.protobuf.FileOptions.OptimizeMode",null,n),i.exportSymbol("proto.google.protobuf.GeneratedCodeInfo",null,n),i.exportSymbol("proto.google.protobuf.GeneratedCodeInfo.Annotation",null,n),i.exportSymbol("proto.google.protobuf.GeneratedCodeInfo.Annotation.Semantic",null,n),i.exportSymbol("proto.google.protobuf.MessageOptions",null,n),i.exportSymbol("proto.google.protobuf.MethodDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.MethodOptions",null,n),i.exportSymbol("proto.google.protobuf.MethodOptions.IdempotencyLevel",null,n),i.exportSymbol("proto.google.protobuf.OneofDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.OneofOptions",null,n),i.exportSymbol("proto.google.protobuf.ServiceDescriptorProto",null,n),i.exportSymbol("proto.google.protobuf.ServiceOptions",null,n),i.exportSymbol("proto.google.protobuf.SourceCodeInfo",null,n),i.exportSymbol("proto.google.protobuf.SourceCodeInfo.Location",null,n),i.exportSymbol("proto.google.protobuf.UninterpretedOption",null,n),i.exportSymbol("proto.google.protobuf.UninterpretedOption.NamePart",null,n),proto.google.protobuf.FileDescriptorSet=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.FileDescriptorSet.repeatedFields_,null)},i.inherits(proto.google.protobuf.FileDescriptorSet,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FileDescriptorSet.displayName="proto.google.protobuf.FileDescriptorSet"),proto.google.protobuf.FileDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.FileDescriptorProto.repeatedFields_,null)},i.inherits(proto.google.protobuf.FileDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FileDescriptorProto.displayName="proto.google.protobuf.FileDescriptorProto"),proto.google.protobuf.DescriptorProto=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.DescriptorProto.repeatedFields_,null)},i.inherits(proto.google.protobuf.DescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.DescriptorProto.displayName="proto.google.protobuf.DescriptorProto"),proto.google.protobuf.DescriptorProto.ExtensionRange=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.DescriptorProto.ExtensionRange,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.DescriptorProto.ExtensionRange.displayName="proto.google.protobuf.DescriptorProto.ExtensionRange"),proto.google.protobuf.DescriptorProto.ReservedRange=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.DescriptorProto.ReservedRange,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.DescriptorProto.ReservedRange.displayName="proto.google.protobuf.DescriptorProto.ReservedRange"),proto.google.protobuf.ExtensionRangeOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.ExtensionRangeOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.ExtensionRangeOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.ExtensionRangeOptions.displayName="proto.google.protobuf.ExtensionRangeOptions"),proto.google.protobuf.ExtensionRangeOptions.extensions={},proto.google.protobuf.ExtensionRangeOptions.extensionsBinary={},proto.google.protobuf.ExtensionRangeOptions.Declaration=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.ExtensionRangeOptions.Declaration,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.ExtensionRangeOptions.Declaration.displayName="proto.google.protobuf.ExtensionRangeOptions.Declaration"),proto.google.protobuf.FieldDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.FieldDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FieldDescriptorProto.displayName="proto.google.protobuf.FieldDescriptorProto"),proto.google.protobuf.OneofDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.OneofDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.OneofDescriptorProto.displayName="proto.google.protobuf.OneofDescriptorProto"),proto.google.protobuf.EnumDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.EnumDescriptorProto.repeatedFields_,null)},i.inherits(proto.google.protobuf.EnumDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.EnumDescriptorProto.displayName="proto.google.protobuf.EnumDescriptorProto"),proto.google.protobuf.EnumDescriptorProto.EnumReservedRange=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.EnumDescriptorProto.EnumReservedRange,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.displayName="proto.google.protobuf.EnumDescriptorProto.EnumReservedRange"),proto.google.protobuf.EnumValueDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.EnumValueDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.EnumValueDescriptorProto.displayName="proto.google.protobuf.EnumValueDescriptorProto"),proto.google.protobuf.ServiceDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.ServiceDescriptorProto.repeatedFields_,null)},i.inherits(proto.google.protobuf.ServiceDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.ServiceDescriptorProto.displayName="proto.google.protobuf.ServiceDescriptorProto"),proto.google.protobuf.MethodDescriptorProto=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.MethodDescriptorProto,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.MethodDescriptorProto.displayName="proto.google.protobuf.MethodDescriptorProto"),proto.google.protobuf.FileOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.FileOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.FileOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FileOptions.displayName="proto.google.protobuf.FileOptions"),proto.google.protobuf.FileOptions.extensions={},proto.google.protobuf.FileOptions.extensionsBinary={},proto.google.protobuf.MessageOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.MessageOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.MessageOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.MessageOptions.displayName="proto.google.protobuf.MessageOptions"),proto.google.protobuf.MessageOptions.extensions={},proto.google.protobuf.MessageOptions.extensionsBinary={},proto.google.protobuf.FieldOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.FieldOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.FieldOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FieldOptions.displayName="proto.google.protobuf.FieldOptions"),proto.google.protobuf.FieldOptions.extensions={},proto.google.protobuf.FieldOptions.extensionsBinary={},proto.google.protobuf.FieldOptions.EditionDefault=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.FieldOptions.EditionDefault,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FieldOptions.EditionDefault.displayName="proto.google.protobuf.FieldOptions.EditionDefault"),proto.google.protobuf.FieldOptions.FeatureSupport=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.FieldOptions.FeatureSupport,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FieldOptions.FeatureSupport.displayName="proto.google.protobuf.FieldOptions.FeatureSupport"),proto.google.protobuf.OneofOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.OneofOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.OneofOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.OneofOptions.displayName="proto.google.protobuf.OneofOptions"),proto.google.protobuf.OneofOptions.extensions={},proto.google.protobuf.OneofOptions.extensionsBinary={},proto.google.protobuf.EnumOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.EnumOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.EnumOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.EnumOptions.displayName="proto.google.protobuf.EnumOptions"),proto.google.protobuf.EnumOptions.extensions={},proto.google.protobuf.EnumOptions.extensionsBinary={},proto.google.protobuf.EnumValueOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.EnumValueOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.EnumValueOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.EnumValueOptions.displayName="proto.google.protobuf.EnumValueOptions"),proto.google.protobuf.EnumValueOptions.extensions={},proto.google.protobuf.EnumValueOptions.extensionsBinary={},proto.google.protobuf.ServiceOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.ServiceOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.ServiceOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.ServiceOptions.displayName="proto.google.protobuf.ServiceOptions"),proto.google.protobuf.ServiceOptions.extensions={},proto.google.protobuf.ServiceOptions.extensionsBinary={},proto.google.protobuf.MethodOptions=function(r){e.Message.initialize(this,r,0,500,proto.google.protobuf.MethodOptions.repeatedFields_,null)},i.inherits(proto.google.protobuf.MethodOptions,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.MethodOptions.displayName="proto.google.protobuf.MethodOptions"),proto.google.protobuf.MethodOptions.extensions={},proto.google.protobuf.MethodOptions.extensionsBinary={},proto.google.protobuf.UninterpretedOption=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.UninterpretedOption.repeatedFields_,null)},i.inherits(proto.google.protobuf.UninterpretedOption,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.UninterpretedOption.displayName="proto.google.protobuf.UninterpretedOption"),proto.google.protobuf.UninterpretedOption.NamePart=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.UninterpretedOption.NamePart,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.UninterpretedOption.NamePart.displayName="proto.google.protobuf.UninterpretedOption.NamePart"),proto.google.protobuf.FeatureSet=function(r){e.Message.initialize(this,r,0,7,null,null)},i.inherits(proto.google.protobuf.FeatureSet,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FeatureSet.displayName="proto.google.protobuf.FeatureSet"),proto.google.protobuf.FeatureSet.extensions={},proto.google.protobuf.FeatureSet.extensionsBinary={},proto.google.protobuf.FeatureSetDefaults=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.FeatureSetDefaults.repeatedFields_,null)},i.inherits(proto.google.protobuf.FeatureSetDefaults,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FeatureSetDefaults.displayName="proto.google.protobuf.FeatureSetDefaults"),proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault=function(r){e.Message.initialize(this,r,0,-1,null,null)},i.inherits(proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.displayName="proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault"),proto.google.protobuf.SourceCodeInfo=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.SourceCodeInfo.repeatedFields_,null)},i.inherits(proto.google.protobuf.SourceCodeInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.SourceCodeInfo.displayName="proto.google.protobuf.SourceCodeInfo"),proto.google.protobuf.SourceCodeInfo.Location=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.SourceCodeInfo.Location.repeatedFields_,null)},i.inherits(proto.google.protobuf.SourceCodeInfo.Location,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.SourceCodeInfo.Location.displayName="proto.google.protobuf.SourceCodeInfo.Location"),proto.google.protobuf.GeneratedCodeInfo=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.GeneratedCodeInfo.repeatedFields_,null)},i.inherits(proto.google.protobuf.GeneratedCodeInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.GeneratedCodeInfo.displayName="proto.google.protobuf.GeneratedCodeInfo"),proto.google.protobuf.GeneratedCodeInfo.Annotation=function(r){e.Message.initialize(this,r,0,-1,proto.google.protobuf.GeneratedCodeInfo.Annotation.repeatedFields_,null)},i.inherits(proto.google.protobuf.GeneratedCodeInfo.Annotation,e.Message),i.DEBUG&&!COMPILED&&(proto.google.protobuf.GeneratedCodeInfo.Annotation.displayName="proto.google.protobuf.GeneratedCodeInfo.Annotation"),proto.google.protobuf.FileDescriptorSet.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FileDescriptorSet.prototype.toObject=function(r){return proto.google.protobuf.FileDescriptorSet.toObject(r,this)},proto.google.protobuf.FileDescriptorSet.toObject=function(r,o){var a={fileList:e.Message.toObjectList(o.getFileList(),proto.google.protobuf.FileDescriptorProto.toObject,r)};return r&&(a.$jspbMessageInstance=o),a}),proto.google.protobuf.FileDescriptorSet.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FileDescriptorSet;return proto.google.protobuf.FileDescriptorSet.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FileDescriptorSet.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.protobuf.FileDescriptorProto;o.readMessage(s,proto.google.protobuf.FileDescriptorProto.deserializeBinaryFromReader),r.addFile(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FileDescriptorSet.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FileDescriptorSet.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FileDescriptorSet.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getFileList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.google.protobuf.FileDescriptorProto.serializeBinaryToWriter)},proto.google.protobuf.FileDescriptorSet.prototype.getFileList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FileDescriptorProto,1)},proto.google.protobuf.FileDescriptorSet.prototype.setFileList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.google.protobuf.FileDescriptorSet.prototype.addFile=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.google.protobuf.FileDescriptorProto,o)},proto.google.protobuf.FileDescriptorSet.prototype.clearFileList=function(){return this.setFileList([])},proto.google.protobuf.FileDescriptorProto.repeatedFields_=[3,10,11,4,5,6,7],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FileDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.FileDescriptorProto.toObject(r,this)},proto.google.protobuf.FileDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,pb_package:(a=e.Message.getField(o,2))==null?void 0:a,dependencyList:(a=e.Message.getRepeatedField(o,3))==null?void 0:a,publicDependencyList:(a=e.Message.getRepeatedField(o,10))==null?void 0:a,weakDependencyList:(a=e.Message.getRepeatedField(o,11))==null?void 0:a,messageTypeList:e.Message.toObjectList(o.getMessageTypeList(),proto.google.protobuf.DescriptorProto.toObject,r),enumTypeList:e.Message.toObjectList(o.getEnumTypeList(),proto.google.protobuf.EnumDescriptorProto.toObject,r),serviceList:e.Message.toObjectList(o.getServiceList(),proto.google.protobuf.ServiceDescriptorProto.toObject,r),extensionList:e.Message.toObjectList(o.getExtensionList(),proto.google.protobuf.FieldDescriptorProto.toObject,r),options:(a=o.getOptions())&&proto.google.protobuf.FileOptions.toObject(r,a),sourceCodeInfo:(a=o.getSourceCodeInfo())&&proto.google.protobuf.SourceCodeInfo.toObject(r,a),syntax:(a=e.Message.getField(o,12))==null?void 0:a,edition:(a=e.Message.getField(o,14))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FileDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FileDescriptorProto;return proto.google.protobuf.FileDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FileDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var u=o.readString();r.setName(u);break;case 2:var u=o.readString();r.setPackage(u);break;case 3:var u=o.readString();r.addDependency(u);break;case 10:for(var l=o.isDelimited()?o.readPackedInt32():[o.readInt32()],s=0;s<l.length;s++)r.addPublicDependency(l[s]);break;case 11:for(var l=o.isDelimited()?o.readPackedInt32():[o.readInt32()],s=0;s<l.length;s++)r.addWeakDependency(l[s]);break;case 4:var u=new proto.google.protobuf.DescriptorProto;o.readMessage(u,proto.google.protobuf.DescriptorProto.deserializeBinaryFromReader),r.addMessageType(u);break;case 5:var u=new proto.google.protobuf.EnumDescriptorProto;o.readMessage(u,proto.google.protobuf.EnumDescriptorProto.deserializeBinaryFromReader),r.addEnumType(u);break;case 6:var u=new proto.google.protobuf.ServiceDescriptorProto;o.readMessage(u,proto.google.protobuf.ServiceDescriptorProto.deserializeBinaryFromReader),r.addService(u);break;case 7:var u=new proto.google.protobuf.FieldDescriptorProto;o.readMessage(u,proto.google.protobuf.FieldDescriptorProto.deserializeBinaryFromReader),r.addExtension$(u);break;case 8:var u=new proto.google.protobuf.FileOptions;o.readMessage(u,proto.google.protobuf.FileOptions.deserializeBinaryFromReader),r.setOptions(u);break;case 9:var u=new proto.google.protobuf.SourceCodeInfo;o.readMessage(u,proto.google.protobuf.SourceCodeInfo.deserializeBinaryFromReader),r.setSourceCodeInfo(u);break;case 12:var u=o.readString();r.setSyntax(u);break;case 14:var u=o.readEnum();r.setEdition(u);break;default:o.skipField();break}}return r},proto.google.protobuf.FileDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FileDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FileDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=r.getDependencyList(),a.length>0&&o.writeRepeatedString(3,a),a=r.getPublicDependencyList(),a.length>0&&o.writeRepeatedInt32(10,a),a=r.getWeakDependencyList(),a.length>0&&o.writeRepeatedInt32(11,a),a=r.getMessageTypeList(),a.length>0&&o.writeRepeatedMessage(4,a,proto.google.protobuf.DescriptorProto.serializeBinaryToWriter),a=r.getEnumTypeList(),a.length>0&&o.writeRepeatedMessage(5,a,proto.google.protobuf.EnumDescriptorProto.serializeBinaryToWriter),a=r.getServiceList(),a.length>0&&o.writeRepeatedMessage(6,a,proto.google.protobuf.ServiceDescriptorProto.serializeBinaryToWriter),a=r.getExtensionList(),a.length>0&&o.writeRepeatedMessage(7,a,proto.google.protobuf.FieldDescriptorProto.serializeBinaryToWriter),a=r.getOptions(),a!=null&&o.writeMessage(8,a,proto.google.protobuf.FileOptions.serializeBinaryToWriter),a=r.getSourceCodeInfo(),a!=null&&o.writeMessage(9,a,proto.google.protobuf.SourceCodeInfo.serializeBinaryToWriter),a=e.Message.getField(r,12),a!=null&&o.writeString(12,a),a=e.Message.getField(r,14),a!=null&&o.writeEnum(14,a)},proto.google.protobuf.FileDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.FileDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FileDescriptorProto.prototype.getPackage=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.FileDescriptorProto.prototype.setPackage=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearPackage=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasPackage=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.FileDescriptorProto.prototype.getDependencyList=function(){return e.Message.getRepeatedField(this,3)},proto.google.protobuf.FileDescriptorProto.prototype.setDependencyList=function(r){return e.Message.setField(this,3,r||[])},proto.google.protobuf.FileDescriptorProto.prototype.addDependency=function(r,o){return e.Message.addToRepeatedField(this,3,r,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearDependencyList=function(){return this.setDependencyList([])},proto.google.protobuf.FileDescriptorProto.prototype.getPublicDependencyList=function(){return e.Message.getRepeatedField(this,10)},proto.google.protobuf.FileDescriptorProto.prototype.setPublicDependencyList=function(r){return e.Message.setField(this,10,r||[])},proto.google.protobuf.FileDescriptorProto.prototype.addPublicDependency=function(r,o){return e.Message.addToRepeatedField(this,10,r,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearPublicDependencyList=function(){return this.setPublicDependencyList([])},proto.google.protobuf.FileDescriptorProto.prototype.getWeakDependencyList=function(){return e.Message.getRepeatedField(this,11)},proto.google.protobuf.FileDescriptorProto.prototype.setWeakDependencyList=function(r){return e.Message.setField(this,11,r||[])},proto.google.protobuf.FileDescriptorProto.prototype.addWeakDependency=function(r,o){return e.Message.addToRepeatedField(this,11,r,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearWeakDependencyList=function(){return this.setWeakDependencyList([])},proto.google.protobuf.FileDescriptorProto.prototype.getMessageTypeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.DescriptorProto,4)},proto.google.protobuf.FileDescriptorProto.prototype.setMessageTypeList=function(r){return e.Message.setRepeatedWrapperField(this,4,r)},proto.google.protobuf.FileDescriptorProto.prototype.addMessageType=function(r,o){return e.Message.addToRepeatedWrapperField(this,4,r,proto.google.protobuf.DescriptorProto,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearMessageTypeList=function(){return this.setMessageTypeList([])},proto.google.protobuf.FileDescriptorProto.prototype.getEnumTypeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.EnumDescriptorProto,5)},proto.google.protobuf.FileDescriptorProto.prototype.setEnumTypeList=function(r){return e.Message.setRepeatedWrapperField(this,5,r)},proto.google.protobuf.FileDescriptorProto.prototype.addEnumType=function(r,o){return e.Message.addToRepeatedWrapperField(this,5,r,proto.google.protobuf.EnumDescriptorProto,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearEnumTypeList=function(){return this.setEnumTypeList([])},proto.google.protobuf.FileDescriptorProto.prototype.getServiceList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.ServiceDescriptorProto,6)},proto.google.protobuf.FileDescriptorProto.prototype.setServiceList=function(r){return e.Message.setRepeatedWrapperField(this,6,r)},proto.google.protobuf.FileDescriptorProto.prototype.addService=function(r,o){return e.Message.addToRepeatedWrapperField(this,6,r,proto.google.protobuf.ServiceDescriptorProto,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearServiceList=function(){return this.setServiceList([])},proto.google.protobuf.FileDescriptorProto.prototype.getExtensionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FieldDescriptorProto,7)},proto.google.protobuf.FileDescriptorProto.prototype.setExtensionList=function(r){return e.Message.setRepeatedWrapperField(this,7,r)},proto.google.protobuf.FileDescriptorProto.prototype.addExtension$=function(r,o){return e.Message.addToRepeatedWrapperField(this,7,r,proto.google.protobuf.FieldDescriptorProto,o)},proto.google.protobuf.FileDescriptorProto.prototype.clearExtensionList=function(){return this.setExtensionList([])},proto.google.protobuf.FileDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FileOptions,8)},proto.google.protobuf.FileDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,8,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,8)!=null},proto.google.protobuf.FileDescriptorProto.prototype.getSourceCodeInfo=function(){return e.Message.getWrapperField(this,proto.google.protobuf.SourceCodeInfo,9)},proto.google.protobuf.FileDescriptorProto.prototype.setSourceCodeInfo=function(r){return e.Message.setWrapperField(this,9,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearSourceCodeInfo=function(){return this.setSourceCodeInfo(void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasSourceCodeInfo=function(){return e.Message.getField(this,9)!=null},proto.google.protobuf.FileDescriptorProto.prototype.getSyntax=function(){return e.Message.getFieldWithDefault(this,12,"")},proto.google.protobuf.FileDescriptorProto.prototype.setSyntax=function(r){return e.Message.setField(this,12,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearSyntax=function(){return e.Message.setField(this,12,void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasSyntax=function(){return e.Message.getField(this,12)!=null},proto.google.protobuf.FileDescriptorProto.prototype.getEdition=function(){return e.Message.getFieldWithDefault(this,14,0)},proto.google.protobuf.FileDescriptorProto.prototype.setEdition=function(r){return e.Message.setField(this,14,r)},proto.google.protobuf.FileDescriptorProto.prototype.clearEdition=function(){return e.Message.setField(this,14,void 0)},proto.google.protobuf.FileDescriptorProto.prototype.hasEdition=function(){return e.Message.getField(this,14)!=null},proto.google.protobuf.DescriptorProto.repeatedFields_=[2,6,3,4,5,8,9,10],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.DescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.DescriptorProto.toObject(r,this)},proto.google.protobuf.DescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,fieldList:e.Message.toObjectList(o.getFieldList(),proto.google.protobuf.FieldDescriptorProto.toObject,r),extensionList:e.Message.toObjectList(o.getExtensionList(),proto.google.protobuf.FieldDescriptorProto.toObject,r),nestedTypeList:e.Message.toObjectList(o.getNestedTypeList(),proto.google.protobuf.DescriptorProto.toObject,r),enumTypeList:e.Message.toObjectList(o.getEnumTypeList(),proto.google.protobuf.EnumDescriptorProto.toObject,r),extensionRangeList:e.Message.toObjectList(o.getExtensionRangeList(),proto.google.protobuf.DescriptorProto.ExtensionRange.toObject,r),oneofDeclList:e.Message.toObjectList(o.getOneofDeclList(),proto.google.protobuf.OneofDescriptorProto.toObject,r),options:(a=o.getOptions())&&proto.google.protobuf.MessageOptions.toObject(r,a),reservedRangeList:e.Message.toObjectList(o.getReservedRangeList(),proto.google.protobuf.DescriptorProto.ReservedRange.toObject,r),reservedNameList:(a=e.Message.getRepeatedField(o,10))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.DescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.DescriptorProto;return proto.google.protobuf.DescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.DescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=new proto.google.protobuf.FieldDescriptorProto;o.readMessage(s,proto.google.protobuf.FieldDescriptorProto.deserializeBinaryFromReader),r.addField(s);break;case 6:var s=new proto.google.protobuf.FieldDescriptorProto;o.readMessage(s,proto.google.protobuf.FieldDescriptorProto.deserializeBinaryFromReader),r.addExtension$(s);break;case 3:var s=new proto.google.protobuf.DescriptorProto;o.readMessage(s,proto.google.protobuf.DescriptorProto.deserializeBinaryFromReader),r.addNestedType(s);break;case 4:var s=new proto.google.protobuf.EnumDescriptorProto;o.readMessage(s,proto.google.protobuf.EnumDescriptorProto.deserializeBinaryFromReader),r.addEnumType(s);break;case 5:var s=new proto.google.protobuf.DescriptorProto.ExtensionRange;o.readMessage(s,proto.google.protobuf.DescriptorProto.ExtensionRange.deserializeBinaryFromReader),r.addExtensionRange(s);break;case 8:var s=new proto.google.protobuf.OneofDescriptorProto;o.readMessage(s,proto.google.protobuf.OneofDescriptorProto.deserializeBinaryFromReader),r.addOneofDecl(s);break;case 7:var s=new proto.google.protobuf.MessageOptions;o.readMessage(s,proto.google.protobuf.MessageOptions.deserializeBinaryFromReader),r.setOptions(s);break;case 9:var s=new proto.google.protobuf.DescriptorProto.ReservedRange;o.readMessage(s,proto.google.protobuf.DescriptorProto.ReservedRange.deserializeBinaryFromReader),r.addReservedRange(s);break;case 10:var s=o.readString();r.addReservedName(s);break;default:o.skipField();break}}return r},proto.google.protobuf.DescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.DescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.DescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=r.getFieldList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.google.protobuf.FieldDescriptorProto.serializeBinaryToWriter),a=r.getExtensionList(),a.length>0&&o.writeRepeatedMessage(6,a,proto.google.protobuf.FieldDescriptorProto.serializeBinaryToWriter),a=r.getNestedTypeList(),a.length>0&&o.writeRepeatedMessage(3,a,proto.google.protobuf.DescriptorProto.serializeBinaryToWriter),a=r.getEnumTypeList(),a.length>0&&o.writeRepeatedMessage(4,a,proto.google.protobuf.EnumDescriptorProto.serializeBinaryToWriter),a=r.getExtensionRangeList(),a.length>0&&o.writeRepeatedMessage(5,a,proto.google.protobuf.DescriptorProto.ExtensionRange.serializeBinaryToWriter),a=r.getOneofDeclList(),a.length>0&&o.writeRepeatedMessage(8,a,proto.google.protobuf.OneofDescriptorProto.serializeBinaryToWriter),a=r.getOptions(),a!=null&&o.writeMessage(7,a,proto.google.protobuf.MessageOptions.serializeBinaryToWriter),a=r.getReservedRangeList(),a.length>0&&o.writeRepeatedMessage(9,a,proto.google.protobuf.DescriptorProto.ReservedRange.serializeBinaryToWriter),a=r.getReservedNameList(),a.length>0&&o.writeRepeatedString(10,a)},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.toObject=function(r){return proto.google.protobuf.DescriptorProto.ExtensionRange.toObject(r,this)},proto.google.protobuf.DescriptorProto.ExtensionRange.toObject=function(r,o){var a,s={start:(a=e.Message.getField(o,1))==null?void 0:a,end:(a=e.Message.getField(o,2))==null?void 0:a,options:(a=o.getOptions())&&proto.google.protobuf.ExtensionRangeOptions.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.DescriptorProto.ExtensionRange.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.DescriptorProto.ExtensionRange;return proto.google.protobuf.DescriptorProto.ExtensionRange.deserializeBinaryFromReader(a,o)},proto.google.protobuf.DescriptorProto.ExtensionRange.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readInt32();r.setStart(s);break;case 2:var s=o.readInt32();r.setEnd(s);break;case 3:var s=new proto.google.protobuf.ExtensionRangeOptions;o.readMessage(s,proto.google.protobuf.ExtensionRangeOptions.deserializeBinaryFromReader),r.setOptions(s);break;default:o.skipField();break}}return r},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.DescriptorProto.ExtensionRange.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.DescriptorProto.ExtensionRange.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeInt32(1,a),a=e.Message.getField(r,2),a!=null&&o.writeInt32(2,a),a=r.getOptions(),a!=null&&o.writeMessage(3,a,proto.google.protobuf.ExtensionRangeOptions.serializeBinaryToWriter)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.getStart=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.setStart=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.clearStart=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.hasStart=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.getEnd=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.setEnd=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.clearEnd=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.hasEnd=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.ExtensionRangeOptions,3)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.setOptions=function(r){return e.Message.setWrapperField(this,3,r)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.DescriptorProto.ExtensionRange.prototype.hasOptions=function(){return e.Message.getField(this,3)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.DescriptorProto.ReservedRange.prototype.toObject=function(r){return proto.google.protobuf.DescriptorProto.ReservedRange.toObject(r,this)},proto.google.protobuf.DescriptorProto.ReservedRange.toObject=function(r,o){var a,s={start:(a=e.Message.getField(o,1))==null?void 0:a,end:(a=e.Message.getField(o,2))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.DescriptorProto.ReservedRange.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.DescriptorProto.ReservedRange;return proto.google.protobuf.DescriptorProto.ReservedRange.deserializeBinaryFromReader(a,o)},proto.google.protobuf.DescriptorProto.ReservedRange.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readInt32();r.setStart(s);break;case 2:var s=o.readInt32();r.setEnd(s);break;default:o.skipField();break}}return r},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.DescriptorProto.ReservedRange.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.DescriptorProto.ReservedRange.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeInt32(1,a),a=e.Message.getField(r,2),a!=null&&o.writeInt32(2,a)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.getStart=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.setStart=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.clearStart=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.hasStart=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.getEnd=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.setEnd=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.clearEnd=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.DescriptorProto.ReservedRange.prototype.hasEnd=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.DescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.DescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.DescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.DescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.DescriptorProto.prototype.getFieldList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FieldDescriptorProto,2)},proto.google.protobuf.DescriptorProto.prototype.setFieldList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.google.protobuf.DescriptorProto.prototype.addField=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.google.protobuf.FieldDescriptorProto,o)},proto.google.protobuf.DescriptorProto.prototype.clearFieldList=function(){return this.setFieldList([])},proto.google.protobuf.DescriptorProto.prototype.getExtensionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FieldDescriptorProto,6)},proto.google.protobuf.DescriptorProto.prototype.setExtensionList=function(r){return e.Message.setRepeatedWrapperField(this,6,r)},proto.google.protobuf.DescriptorProto.prototype.addExtension$=function(r,o){return e.Message.addToRepeatedWrapperField(this,6,r,proto.google.protobuf.FieldDescriptorProto,o)},proto.google.protobuf.DescriptorProto.prototype.clearExtensionList=function(){return this.setExtensionList([])},proto.google.protobuf.DescriptorProto.prototype.getNestedTypeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.DescriptorProto,3)},proto.google.protobuf.DescriptorProto.prototype.setNestedTypeList=function(r){return e.Message.setRepeatedWrapperField(this,3,r)},proto.google.protobuf.DescriptorProto.prototype.addNestedType=function(r,o){return e.Message.addToRepeatedWrapperField(this,3,r,proto.google.protobuf.DescriptorProto,o)},proto.google.protobuf.DescriptorProto.prototype.clearNestedTypeList=function(){return this.setNestedTypeList([])},proto.google.protobuf.DescriptorProto.prototype.getEnumTypeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.EnumDescriptorProto,4)},proto.google.protobuf.DescriptorProto.prototype.setEnumTypeList=function(r){return e.Message.setRepeatedWrapperField(this,4,r)},proto.google.protobuf.DescriptorProto.prototype.addEnumType=function(r,o){return e.Message.addToRepeatedWrapperField(this,4,r,proto.google.protobuf.EnumDescriptorProto,o)},proto.google.protobuf.DescriptorProto.prototype.clearEnumTypeList=function(){return this.setEnumTypeList([])},proto.google.protobuf.DescriptorProto.prototype.getExtensionRangeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.DescriptorProto.ExtensionRange,5)},proto.google.protobuf.DescriptorProto.prototype.setExtensionRangeList=function(r){return e.Message.setRepeatedWrapperField(this,5,r)},proto.google.protobuf.DescriptorProto.prototype.addExtensionRange=function(r,o){return e.Message.addToRepeatedWrapperField(this,5,r,proto.google.protobuf.DescriptorProto.ExtensionRange,o)},proto.google.protobuf.DescriptorProto.prototype.clearExtensionRangeList=function(){return this.setExtensionRangeList([])},proto.google.protobuf.DescriptorProto.prototype.getOneofDeclList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.OneofDescriptorProto,8)},proto.google.protobuf.DescriptorProto.prototype.setOneofDeclList=function(r){return e.Message.setRepeatedWrapperField(this,8,r)},proto.google.protobuf.DescriptorProto.prototype.addOneofDecl=function(r,o){return e.Message.addToRepeatedWrapperField(this,8,r,proto.google.protobuf.OneofDescriptorProto,o)},proto.google.protobuf.DescriptorProto.prototype.clearOneofDeclList=function(){return this.setOneofDeclList([])},proto.google.protobuf.DescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.MessageOptions,7)},proto.google.protobuf.DescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,7,r)},proto.google.protobuf.DescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.DescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,7)!=null},proto.google.protobuf.DescriptorProto.prototype.getReservedRangeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.DescriptorProto.ReservedRange,9)},proto.google.protobuf.DescriptorProto.prototype.setReservedRangeList=function(r){return e.Message.setRepeatedWrapperField(this,9,r)},proto.google.protobuf.DescriptorProto.prototype.addReservedRange=function(r,o){return e.Message.addToRepeatedWrapperField(this,9,r,proto.google.protobuf.DescriptorProto.ReservedRange,o)},proto.google.protobuf.DescriptorProto.prototype.clearReservedRangeList=function(){return this.setReservedRangeList([])},proto.google.protobuf.DescriptorProto.prototype.getReservedNameList=function(){return e.Message.getRepeatedField(this,10)},proto.google.protobuf.DescriptorProto.prototype.setReservedNameList=function(r){return e.Message.setField(this,10,r||[])},proto.google.protobuf.DescriptorProto.prototype.addReservedName=function(r,o){return e.Message.addToRepeatedField(this,10,r,o)},proto.google.protobuf.DescriptorProto.prototype.clearReservedNameList=function(){return this.setReservedNameList([])},proto.google.protobuf.ExtensionRangeOptions.repeatedFields_=[999,2],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.ExtensionRangeOptions.prototype.toObject=function(r){return proto.google.protobuf.ExtensionRangeOptions.toObject(r,this)},proto.google.protobuf.ExtensionRangeOptions.toObject=function(r,o){var a,s={uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r),declarationList:e.Message.toObjectList(o.getDeclarationList(),proto.google.protobuf.ExtensionRangeOptions.Declaration.toObject,r),features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),verification:e.Message.getFieldWithDefault(o,3,1)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.ExtensionRangeOptions.extensions,proto.google.protobuf.ExtensionRangeOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.ExtensionRangeOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.ExtensionRangeOptions;return proto.google.protobuf.ExtensionRangeOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.ExtensionRangeOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;case 2:var s=new proto.google.protobuf.ExtensionRangeOptions.Declaration;o.readMessage(s,proto.google.protobuf.ExtensionRangeOptions.Declaration.deserializeBinaryFromReader),r.addDeclaration(s);break;case 50:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 3:var s=o.readEnum();r.setVerification(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.ExtensionRangeOptions.extensionsBinary,proto.google.protobuf.ExtensionRangeOptions.prototype.getExtension,proto.google.protobuf.ExtensionRangeOptions.prototype.setExtension);break}}return r},proto.google.protobuf.ExtensionRangeOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.ExtensionRangeOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.ExtensionRangeOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),a=r.getDeclarationList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.google.protobuf.ExtensionRangeOptions.Declaration.serializeBinaryToWriter),a=r.getFeatures(),a!=null&&o.writeMessage(50,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=e.Message.getField(r,3),a!=null&&o.writeEnum(3,a),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.ExtensionRangeOptions.extensionsBinary,proto.google.protobuf.ExtensionRangeOptions.prototype.getExtension)},proto.google.protobuf.ExtensionRangeOptions.VerificationState={DECLARATION:0,UNVERIFIED:1},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.toObject=function(r){return proto.google.protobuf.ExtensionRangeOptions.Declaration.toObject(r,this)},proto.google.protobuf.ExtensionRangeOptions.Declaration.toObject=function(r,o){var a,s={number:(a=e.Message.getField(o,1))==null?void 0:a,fullName:(a=e.Message.getField(o,2))==null?void 0:a,type:(a=e.Message.getField(o,3))==null?void 0:a,reserved:(a=e.Message.getBooleanField(o,5))==null?void 0:a,repeated:(a=e.Message.getBooleanField(o,6))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.ExtensionRangeOptions.Declaration.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.ExtensionRangeOptions.Declaration;return proto.google.protobuf.ExtensionRangeOptions.Declaration.deserializeBinaryFromReader(a,o)},proto.google.protobuf.ExtensionRangeOptions.Declaration.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readInt32();r.setNumber(s);break;case 2:var s=o.readString();r.setFullName(s);break;case 3:var s=o.readString();r.setType(s);break;case 5:var s=o.readBool();r.setReserved(s);break;case 6:var s=o.readBool();r.setRepeated(s);break;default:o.skipField();break}}return r},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.ExtensionRangeOptions.Declaration.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.ExtensionRangeOptions.Declaration.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeInt32(1,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=e.Message.getField(r,5),a!=null&&o.writeBool(5,a),a=e.Message.getField(r,6),a!=null&&o.writeBool(6,a)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.getNumber=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.setNumber=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.clearNumber=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.hasNumber=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.getFullName=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.setFullName=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.clearFullName=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.hasFullName=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.getType=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.setType=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.clearType=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.hasType=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.getReserved=function(){return e.Message.getBooleanFieldWithDefault(this,5,!1)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.setReserved=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.clearReserved=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.hasReserved=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.getRepeated=function(){return e.Message.getBooleanFieldWithDefault(this,6,!1)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.setRepeated=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.clearRepeated=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.ExtensionRangeOptions.Declaration.prototype.hasRepeated=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.ExtensionRangeOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.ExtensionRangeOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.ExtensionRangeOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.ExtensionRangeOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.ExtensionRangeOptions.prototype.getDeclarationList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.ExtensionRangeOptions.Declaration,2)},proto.google.protobuf.ExtensionRangeOptions.prototype.setDeclarationList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.google.protobuf.ExtensionRangeOptions.prototype.addDeclaration=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.google.protobuf.ExtensionRangeOptions.Declaration,o)},proto.google.protobuf.ExtensionRangeOptions.prototype.clearDeclarationList=function(){return this.setDeclarationList([])},proto.google.protobuf.ExtensionRangeOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,50)},proto.google.protobuf.ExtensionRangeOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,50,r)},proto.google.protobuf.ExtensionRangeOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.ExtensionRangeOptions.prototype.hasFeatures=function(){return e.Message.getField(this,50)!=null},proto.google.protobuf.ExtensionRangeOptions.prototype.getVerification=function(){return e.Message.getFieldWithDefault(this,3,1)},proto.google.protobuf.ExtensionRangeOptions.prototype.setVerification=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.ExtensionRangeOptions.prototype.clearVerification=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.ExtensionRangeOptions.prototype.hasVerification=function(){return e.Message.getField(this,3)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FieldDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.FieldDescriptorProto.toObject(r,this)},proto.google.protobuf.FieldDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,number:(a=e.Message.getField(o,3))==null?void 0:a,label:(a=e.Message.getField(o,4))==null?void 0:a,type:(a=e.Message.getField(o,5))==null?void 0:a,typeName:(a=e.Message.getField(o,6))==null?void 0:a,extendee:(a=e.Message.getField(o,2))==null?void 0:a,defaultValue:(a=e.Message.getField(o,7))==null?void 0:a,oneofIndex:(a=e.Message.getField(o,9))==null?void 0:a,jsonName:(a=e.Message.getField(o,10))==null?void 0:a,options:(a=o.getOptions())&&proto.google.protobuf.FieldOptions.toObject(r,a),proto3Optional:(a=e.Message.getBooleanField(o,17))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FieldDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FieldDescriptorProto;return proto.google.protobuf.FieldDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FieldDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 3:var s=o.readInt32();r.setNumber(s);break;case 4:var s=o.readEnum();r.setLabel(s);break;case 5:var s=o.readEnum();r.setType(s);break;case 6:var s=o.readString();r.setTypeName(s);break;case 2:var s=o.readString();r.setExtendee(s);break;case 7:var s=o.readString();r.setDefaultValue(s);break;case 9:var s=o.readInt32();r.setOneofIndex(s);break;case 10:var s=o.readString();r.setJsonName(s);break;case 8:var s=new proto.google.protobuf.FieldOptions;o.readMessage(s,proto.google.protobuf.FieldOptions.deserializeBinaryFromReader),r.setOptions(s);break;case 17:var s=o.readBool();r.setProto3Optional(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FieldDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FieldDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FieldDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,3),a!=null&&o.writeInt32(3,a),a=e.Message.getField(r,4),a!=null&&o.writeEnum(4,a),a=e.Message.getField(r,5),a!=null&&o.writeEnum(5,a),a=e.Message.getField(r,6),a!=null&&o.writeString(6,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=e.Message.getField(r,7),a!=null&&o.writeString(7,a),a=e.Message.getField(r,9),a!=null&&o.writeInt32(9,a),a=e.Message.getField(r,10),a!=null&&o.writeString(10,a),a=r.getOptions(),a!=null&&o.writeMessage(8,a,proto.google.protobuf.FieldOptions.serializeBinaryToWriter),a=e.Message.getField(r,17),a!=null&&o.writeBool(17,a)},proto.google.protobuf.FieldDescriptorProto.Type={TYPE_DOUBLE:1,TYPE_FLOAT:2,TYPE_INT64:3,TYPE_UINT64:4,TYPE_INT32:5,TYPE_FIXED64:6,TYPE_FIXED32:7,TYPE_BOOL:8,TYPE_STRING:9,TYPE_GROUP:10,TYPE_MESSAGE:11,TYPE_BYTES:12,TYPE_UINT32:13,TYPE_ENUM:14,TYPE_SFIXED32:15,TYPE_SFIXED64:16,TYPE_SINT32:17,TYPE_SINT64:18},proto.google.protobuf.FieldDescriptorProto.Label={LABEL_OPTIONAL:1,LABEL_REPEATED:3,LABEL_REQUIRED:2},proto.google.protobuf.FieldDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.FieldDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getNumber=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.google.protobuf.FieldDescriptorProto.prototype.setNumber=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearNumber=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasNumber=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getLabel=function(){return e.Message.getFieldWithDefault(this,4,1)},proto.google.protobuf.FieldDescriptorProto.prototype.setLabel=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearLabel=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasLabel=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getType=function(){return e.Message.getFieldWithDefault(this,5,1)},proto.google.protobuf.FieldDescriptorProto.prototype.setType=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearType=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasType=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getTypeName=function(){return e.Message.getFieldWithDefault(this,6,"")},proto.google.protobuf.FieldDescriptorProto.prototype.setTypeName=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearTypeName=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasTypeName=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getExtendee=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.FieldDescriptorProto.prototype.setExtendee=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearExtendee=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasExtendee=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getDefaultValue=function(){return e.Message.getFieldWithDefault(this,7,"")},proto.google.protobuf.FieldDescriptorProto.prototype.setDefaultValue=function(r){return e.Message.setField(this,7,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearDefaultValue=function(){return e.Message.setField(this,7,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasDefaultValue=function(){return e.Message.getField(this,7)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getOneofIndex=function(){return e.Message.getFieldWithDefault(this,9,0)},proto.google.protobuf.FieldDescriptorProto.prototype.setOneofIndex=function(r){return e.Message.setField(this,9,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearOneofIndex=function(){return e.Message.setField(this,9,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasOneofIndex=function(){return e.Message.getField(this,9)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getJsonName=function(){return e.Message.getFieldWithDefault(this,10,"")},proto.google.protobuf.FieldDescriptorProto.prototype.setJsonName=function(r){return e.Message.setField(this,10,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearJsonName=function(){return e.Message.setField(this,10,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasJsonName=function(){return e.Message.getField(this,10)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FieldOptions,8)},proto.google.protobuf.FieldDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,8,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,8)!=null},proto.google.protobuf.FieldDescriptorProto.prototype.getProto3Optional=function(){return e.Message.getBooleanFieldWithDefault(this,17,!1)},proto.google.protobuf.FieldDescriptorProto.prototype.setProto3Optional=function(r){return e.Message.setField(this,17,r)},proto.google.protobuf.FieldDescriptorProto.prototype.clearProto3Optional=function(){return e.Message.setField(this,17,void 0)},proto.google.protobuf.FieldDescriptorProto.prototype.hasProto3Optional=function(){return e.Message.getField(this,17)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.OneofDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.OneofDescriptorProto.toObject(r,this)},proto.google.protobuf.OneofDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,options:(a=o.getOptions())&&proto.google.protobuf.OneofOptions.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.OneofDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.OneofDescriptorProto;return proto.google.protobuf.OneofDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.OneofDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=new proto.google.protobuf.OneofOptions;o.readMessage(s,proto.google.protobuf.OneofOptions.deserializeBinaryFromReader),r.setOptions(s);break;default:o.skipField();break}}return r},proto.google.protobuf.OneofDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.OneofDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.OneofDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=r.getOptions(),a!=null&&o.writeMessage(2,a,proto.google.protobuf.OneofOptions.serializeBinaryToWriter)},proto.google.protobuf.OneofDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.OneofDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.OneofDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.OneofDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.OneofDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.OneofOptions,2)},proto.google.protobuf.OneofDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,2,r)},proto.google.protobuf.OneofDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.OneofDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.EnumDescriptorProto.repeatedFields_=[2,4,5],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.EnumDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.EnumDescriptorProto.toObject(r,this)},proto.google.protobuf.EnumDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,valueList:e.Message.toObjectList(o.getValueList(),proto.google.protobuf.EnumValueDescriptorProto.toObject,r),options:(a=o.getOptions())&&proto.google.protobuf.EnumOptions.toObject(r,a),reservedRangeList:e.Message.toObjectList(o.getReservedRangeList(),proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject,r),reservedNameList:(a=e.Message.getRepeatedField(o,5))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.EnumDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.EnumDescriptorProto;return proto.google.protobuf.EnumDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.EnumDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=new proto.google.protobuf.EnumValueDescriptorProto;o.readMessage(s,proto.google.protobuf.EnumValueDescriptorProto.deserializeBinaryFromReader),r.addValue(s);break;case 3:var s=new proto.google.protobuf.EnumOptions;o.readMessage(s,proto.google.protobuf.EnumOptions.deserializeBinaryFromReader),r.setOptions(s);break;case 4:var s=new proto.google.protobuf.EnumDescriptorProto.EnumReservedRange;o.readMessage(s,proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.deserializeBinaryFromReader),r.addReservedRange(s);break;case 5:var s=o.readString();r.addReservedName(s);break;default:o.skipField();break}}return r},proto.google.protobuf.EnumDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.EnumDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.EnumDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=r.getValueList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.google.protobuf.EnumValueDescriptorProto.serializeBinaryToWriter),a=r.getOptions(),a!=null&&o.writeMessage(3,a,proto.google.protobuf.EnumOptions.serializeBinaryToWriter),a=r.getReservedRangeList(),a.length>0&&o.writeRepeatedMessage(4,a,proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.serializeBinaryToWriter),a=r.getReservedNameList(),a.length>0&&o.writeRepeatedString(5,a)},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.toObject=function(r){return proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject(r,this)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.toObject=function(r,o){var a,s={start:(a=e.Message.getField(o,1))==null?void 0:a,end:(a=e.Message.getField(o,2))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.EnumDescriptorProto.EnumReservedRange;return proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.deserializeBinaryFromReader(a,o)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readInt32();r.setStart(s);break;case 2:var s=o.readInt32();r.setEnd(s);break;default:o.skipField();break}}return r},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeInt32(1,a),a=e.Message.getField(r,2),a!=null&&o.writeInt32(2,a)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.getStart=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.setStart=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.clearStart=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.hasStart=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.getEnd=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.setEnd=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.clearEnd=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.EnumDescriptorProto.EnumReservedRange.prototype.hasEnd=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.EnumDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.EnumDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.EnumDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.EnumDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.EnumDescriptorProto.prototype.getValueList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.EnumValueDescriptorProto,2)},proto.google.protobuf.EnumDescriptorProto.prototype.setValueList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.google.protobuf.EnumDescriptorProto.prototype.addValue=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.google.protobuf.EnumValueDescriptorProto,o)},proto.google.protobuf.EnumDescriptorProto.prototype.clearValueList=function(){return this.setValueList([])},proto.google.protobuf.EnumDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.EnumOptions,3)},proto.google.protobuf.EnumDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,3,r)},proto.google.protobuf.EnumDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.EnumDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.EnumDescriptorProto.prototype.getReservedRangeList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.EnumDescriptorProto.EnumReservedRange,4)},proto.google.protobuf.EnumDescriptorProto.prototype.setReservedRangeList=function(r){return e.Message.setRepeatedWrapperField(this,4,r)},proto.google.protobuf.EnumDescriptorProto.prototype.addReservedRange=function(r,o){return e.Message.addToRepeatedWrapperField(this,4,r,proto.google.protobuf.EnumDescriptorProto.EnumReservedRange,o)},proto.google.protobuf.EnumDescriptorProto.prototype.clearReservedRangeList=function(){return this.setReservedRangeList([])},proto.google.protobuf.EnumDescriptorProto.prototype.getReservedNameList=function(){return e.Message.getRepeatedField(this,5)},proto.google.protobuf.EnumDescriptorProto.prototype.setReservedNameList=function(r){return e.Message.setField(this,5,r||[])},proto.google.protobuf.EnumDescriptorProto.prototype.addReservedName=function(r,o){return e.Message.addToRepeatedField(this,5,r,o)},proto.google.protobuf.EnumDescriptorProto.prototype.clearReservedNameList=function(){return this.setReservedNameList([])},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.EnumValueDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.EnumValueDescriptorProto.toObject(r,this)},proto.google.protobuf.EnumValueDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,number:(a=e.Message.getField(o,2))==null?void 0:a,options:(a=o.getOptions())&&proto.google.protobuf.EnumValueOptions.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.EnumValueDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.EnumValueDescriptorProto;return proto.google.protobuf.EnumValueDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.EnumValueDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=o.readInt32();r.setNumber(s);break;case 3:var s=new proto.google.protobuf.EnumValueOptions;o.readMessage(s,proto.google.protobuf.EnumValueOptions.deserializeBinaryFromReader),r.setOptions(s);break;default:o.skipField();break}}return r},proto.google.protobuf.EnumValueDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.EnumValueDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.EnumValueDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,2),a!=null&&o.writeInt32(2,a),a=r.getOptions(),a!=null&&o.writeMessage(3,a,proto.google.protobuf.EnumValueOptions.serializeBinaryToWriter)},proto.google.protobuf.EnumValueDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.EnumValueDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.EnumValueDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.EnumValueDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.EnumValueDescriptorProto.prototype.getNumber=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.EnumValueDescriptorProto.prototype.setNumber=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.EnumValueDescriptorProto.prototype.clearNumber=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.EnumValueDescriptorProto.prototype.hasNumber=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.EnumValueDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.EnumValueOptions,3)},proto.google.protobuf.EnumValueDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,3,r)},proto.google.protobuf.EnumValueDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.EnumValueDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.ServiceDescriptorProto.repeatedFields_=[2],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.ServiceDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.ServiceDescriptorProto.toObject(r,this)},proto.google.protobuf.ServiceDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,methodList:e.Message.toObjectList(o.getMethodList(),proto.google.protobuf.MethodDescriptorProto.toObject,r),options:(a=o.getOptions())&&proto.google.protobuf.ServiceOptions.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.ServiceDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.ServiceDescriptorProto;return proto.google.protobuf.ServiceDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.ServiceDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=new proto.google.protobuf.MethodDescriptorProto;o.readMessage(s,proto.google.protobuf.MethodDescriptorProto.deserializeBinaryFromReader),r.addMethod(s);break;case 3:var s=new proto.google.protobuf.ServiceOptions;o.readMessage(s,proto.google.protobuf.ServiceOptions.deserializeBinaryFromReader),r.setOptions(s);break;default:o.skipField();break}}return r},proto.google.protobuf.ServiceDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.ServiceDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.ServiceDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=r.getMethodList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.google.protobuf.MethodDescriptorProto.serializeBinaryToWriter),a=r.getOptions(),a!=null&&o.writeMessage(3,a,proto.google.protobuf.ServiceOptions.serializeBinaryToWriter)},proto.google.protobuf.ServiceDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.ServiceDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.ServiceDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.ServiceDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.ServiceDescriptorProto.prototype.getMethodList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.MethodDescriptorProto,2)},proto.google.protobuf.ServiceDescriptorProto.prototype.setMethodList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.google.protobuf.ServiceDescriptorProto.prototype.addMethod=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.google.protobuf.MethodDescriptorProto,o)},proto.google.protobuf.ServiceDescriptorProto.prototype.clearMethodList=function(){return this.setMethodList([])},proto.google.protobuf.ServiceDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.ServiceOptions,3)},proto.google.protobuf.ServiceDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,3,r)},proto.google.protobuf.ServiceDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.ServiceDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,3)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.MethodDescriptorProto.prototype.toObject=function(r){return proto.google.protobuf.MethodDescriptorProto.toObject(r,this)},proto.google.protobuf.MethodDescriptorProto.toObject=function(r,o){var a,s={name:(a=e.Message.getField(o,1))==null?void 0:a,inputType:(a=e.Message.getField(o,2))==null?void 0:a,outputType:(a=e.Message.getField(o,3))==null?void 0:a,options:(a=o.getOptions())&&proto.google.protobuf.MethodOptions.toObject(r,a),clientStreaming:e.Message.getBooleanFieldWithDefault(o,5,!1),serverStreaming:e.Message.getBooleanFieldWithDefault(o,6,!1)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.MethodDescriptorProto.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.MethodDescriptorProto;return proto.google.protobuf.MethodDescriptorProto.deserializeBinaryFromReader(a,o)},proto.google.protobuf.MethodDescriptorProto.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setName(s);break;case 2:var s=o.readString();r.setInputType(s);break;case 3:var s=o.readString();r.setOutputType(s);break;case 4:var s=new proto.google.protobuf.MethodOptions;o.readMessage(s,proto.google.protobuf.MethodOptions.deserializeBinaryFromReader),r.setOptions(s);break;case 5:var s=o.readBool();r.setClientStreaming(s);break;case 6:var s=o.readBool();r.setServerStreaming(s);break;default:o.skipField();break}}return r},proto.google.protobuf.MethodDescriptorProto.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.MethodDescriptorProto.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.MethodDescriptorProto.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=r.getOptions(),a!=null&&o.writeMessage(4,a,proto.google.protobuf.MethodOptions.serializeBinaryToWriter),a=e.Message.getField(r,5),a!=null&&o.writeBool(5,a),a=e.Message.getField(r,6),a!=null&&o.writeBool(6,a)},proto.google.protobuf.MethodDescriptorProto.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.MethodDescriptorProto.prototype.setName=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearName=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasName=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.MethodDescriptorProto.prototype.getInputType=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.MethodDescriptorProto.prototype.setInputType=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearInputType=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasInputType=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.MethodDescriptorProto.prototype.getOutputType=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.protobuf.MethodDescriptorProto.prototype.setOutputType=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearOutputType=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasOutputType=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.MethodDescriptorProto.prototype.getOptions=function(){return e.Message.getWrapperField(this,proto.google.protobuf.MethodOptions,4)},proto.google.protobuf.MethodDescriptorProto.prototype.setOptions=function(r){return e.Message.setWrapperField(this,4,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearOptions=function(){return this.setOptions(void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasOptions=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.MethodDescriptorProto.prototype.getClientStreaming=function(){return e.Message.getBooleanFieldWithDefault(this,5,!1)},proto.google.protobuf.MethodDescriptorProto.prototype.setClientStreaming=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearClientStreaming=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasClientStreaming=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.MethodDescriptorProto.prototype.getServerStreaming=function(){return e.Message.getBooleanFieldWithDefault(this,6,!1)},proto.google.protobuf.MethodDescriptorProto.prototype.setServerStreaming=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.MethodDescriptorProto.prototype.clearServerStreaming=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.MethodDescriptorProto.prototype.hasServerStreaming=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.FileOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FileOptions.prototype.toObject=function(r){return proto.google.protobuf.FileOptions.toObject(r,this)},proto.google.protobuf.FileOptions.toObject=function(r,o){var a,s={javaPackage:(a=e.Message.getField(o,1))==null?void 0:a,javaOuterClassname:(a=e.Message.getField(o,8))==null?void 0:a,javaMultipleFiles:e.Message.getBooleanFieldWithDefault(o,10,!1),javaGenerateEqualsAndHash:(a=e.Message.getBooleanField(o,20))==null?void 0:a,javaStringCheckUtf8:e.Message.getBooleanFieldWithDefault(o,27,!1),optimizeFor:e.Message.getFieldWithDefault(o,9,1),goPackage:(a=e.Message.getField(o,11))==null?void 0:a,ccGenericServices:e.Message.getBooleanFieldWithDefault(o,16,!1),javaGenericServices:e.Message.getBooleanFieldWithDefault(o,17,!1),pyGenericServices:e.Message.getBooleanFieldWithDefault(o,18,!1),deprecated:e.Message.getBooleanFieldWithDefault(o,23,!1),ccEnableArenas:e.Message.getBooleanFieldWithDefault(o,31,!0),objcClassPrefix:(a=e.Message.getField(o,36))==null?void 0:a,csharpNamespace:(a=e.Message.getField(o,37))==null?void 0:a,swiftPrefix:(a=e.Message.getField(o,39))==null?void 0:a,phpClassPrefix:(a=e.Message.getField(o,40))==null?void 0:a,phpNamespace:(a=e.Message.getField(o,41))==null?void 0:a,phpMetadataNamespace:(a=e.Message.getField(o,44))==null?void 0:a,rubyPackage:(a=e.Message.getField(o,45))==null?void 0:a,features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.FileOptions.extensions,proto.google.protobuf.FileOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FileOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FileOptions;return proto.google.protobuf.FileOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FileOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setJavaPackage(s);break;case 8:var s=o.readString();r.setJavaOuterClassname(s);break;case 10:var s=o.readBool();r.setJavaMultipleFiles(s);break;case 20:var s=o.readBool();r.setJavaGenerateEqualsAndHash(s);break;case 27:var s=o.readBool();r.setJavaStringCheckUtf8(s);break;case 9:var s=o.readEnum();r.setOptimizeFor(s);break;case 11:var s=o.readString();r.setGoPackage(s);break;case 16:var s=o.readBool();r.setCcGenericServices(s);break;case 17:var s=o.readBool();r.setJavaGenericServices(s);break;case 18:var s=o.readBool();r.setPyGenericServices(s);break;case 23:var s=o.readBool();r.setDeprecated(s);break;case 31:var s=o.readBool();r.setCcEnableArenas(s);break;case 36:var s=o.readString();r.setObjcClassPrefix(s);break;case 37:var s=o.readString();r.setCsharpNamespace(s);break;case 39:var s=o.readString();r.setSwiftPrefix(s);break;case 40:var s=o.readString();r.setPhpClassPrefix(s);break;case 41:var s=o.readString();r.setPhpNamespace(s);break;case 44:var s=o.readString();r.setPhpMetadataNamespace(s);break;case 45:var s=o.readString();r.setRubyPackage(s);break;case 50:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.FileOptions.extensionsBinary,proto.google.protobuf.FileOptions.prototype.getExtension,proto.google.protobuf.FileOptions.prototype.setExtension);break}}return r},proto.google.protobuf.FileOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FileOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FileOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,8),a!=null&&o.writeString(8,a),a=e.Message.getField(r,10),a!=null&&o.writeBool(10,a),a=e.Message.getField(r,20),a!=null&&o.writeBool(20,a),a=e.Message.getField(r,27),a!=null&&o.writeBool(27,a),a=e.Message.getField(r,9),a!=null&&o.writeEnum(9,a),a=e.Message.getField(r,11),a!=null&&o.writeString(11,a),a=e.Message.getField(r,16),a!=null&&o.writeBool(16,a),a=e.Message.getField(r,17),a!=null&&o.writeBool(17,a),a=e.Message.getField(r,18),a!=null&&o.writeBool(18,a),a=e.Message.getField(r,23),a!=null&&o.writeBool(23,a),a=e.Message.getField(r,31),a!=null&&o.writeBool(31,a),a=e.Message.getField(r,36),a!=null&&o.writeString(36,a),a=e.Message.getField(r,37),a!=null&&o.writeString(37,a),a=e.Message.getField(r,39),a!=null&&o.writeString(39,a),a=e.Message.getField(r,40),a!=null&&o.writeString(40,a),a=e.Message.getField(r,41),a!=null&&o.writeString(41,a),a=e.Message.getField(r,44),a!=null&&o.writeString(44,a),a=e.Message.getField(r,45),a!=null&&o.writeString(45,a),a=r.getFeatures(),a!=null&&o.writeMessage(50,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.FileOptions.extensionsBinary,proto.google.protobuf.FileOptions.prototype.getExtension)},proto.google.protobuf.FileOptions.OptimizeMode={SPEED:1,CODE_SIZE:2,LITE_RUNTIME:3},proto.google.protobuf.FileOptions.prototype.getJavaPackage=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.FileOptions.prototype.setJavaPackage=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FileOptions.prototype.clearJavaPackage=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaPackage=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FileOptions.prototype.getJavaOuterClassname=function(){return e.Message.getFieldWithDefault(this,8,"")},proto.google.protobuf.FileOptions.prototype.setJavaOuterClassname=function(r){return e.Message.setField(this,8,r)},proto.google.protobuf.FileOptions.prototype.clearJavaOuterClassname=function(){return e.Message.setField(this,8,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaOuterClassname=function(){return e.Message.getField(this,8)!=null},proto.google.protobuf.FileOptions.prototype.getJavaMultipleFiles=function(){return e.Message.getBooleanFieldWithDefault(this,10,!1)},proto.google.protobuf.FileOptions.prototype.setJavaMultipleFiles=function(r){return e.Message.setField(this,10,r)},proto.google.protobuf.FileOptions.prototype.clearJavaMultipleFiles=function(){return e.Message.setField(this,10,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaMultipleFiles=function(){return e.Message.getField(this,10)!=null},proto.google.protobuf.FileOptions.prototype.getJavaGenerateEqualsAndHash=function(){return e.Message.getBooleanFieldWithDefault(this,20,!1)},proto.google.protobuf.FileOptions.prototype.setJavaGenerateEqualsAndHash=function(r){return e.Message.setField(this,20,r)},proto.google.protobuf.FileOptions.prototype.clearJavaGenerateEqualsAndHash=function(){return e.Message.setField(this,20,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaGenerateEqualsAndHash=function(){return e.Message.getField(this,20)!=null},proto.google.protobuf.FileOptions.prototype.getJavaStringCheckUtf8=function(){return e.Message.getBooleanFieldWithDefault(this,27,!1)},proto.google.protobuf.FileOptions.prototype.setJavaStringCheckUtf8=function(r){return e.Message.setField(this,27,r)},proto.google.protobuf.FileOptions.prototype.clearJavaStringCheckUtf8=function(){return e.Message.setField(this,27,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaStringCheckUtf8=function(){return e.Message.getField(this,27)!=null},proto.google.protobuf.FileOptions.prototype.getOptimizeFor=function(){return e.Message.getFieldWithDefault(this,9,1)},proto.google.protobuf.FileOptions.prototype.setOptimizeFor=function(r){return e.Message.setField(this,9,r)},proto.google.protobuf.FileOptions.prototype.clearOptimizeFor=function(){return e.Message.setField(this,9,void 0)},proto.google.protobuf.FileOptions.prototype.hasOptimizeFor=function(){return e.Message.getField(this,9)!=null},proto.google.protobuf.FileOptions.prototype.getGoPackage=function(){return e.Message.getFieldWithDefault(this,11,"")},proto.google.protobuf.FileOptions.prototype.setGoPackage=function(r){return e.Message.setField(this,11,r)},proto.google.protobuf.FileOptions.prototype.clearGoPackage=function(){return e.Message.setField(this,11,void 0)},proto.google.protobuf.FileOptions.prototype.hasGoPackage=function(){return e.Message.getField(this,11)!=null},proto.google.protobuf.FileOptions.prototype.getCcGenericServices=function(){return e.Message.getBooleanFieldWithDefault(this,16,!1)},proto.google.protobuf.FileOptions.prototype.setCcGenericServices=function(r){return e.Message.setField(this,16,r)},proto.google.protobuf.FileOptions.prototype.clearCcGenericServices=function(){return e.Message.setField(this,16,void 0)},proto.google.protobuf.FileOptions.prototype.hasCcGenericServices=function(){return e.Message.getField(this,16)!=null},proto.google.protobuf.FileOptions.prototype.getJavaGenericServices=function(){return e.Message.getBooleanFieldWithDefault(this,17,!1)},proto.google.protobuf.FileOptions.prototype.setJavaGenericServices=function(r){return e.Message.setField(this,17,r)},proto.google.protobuf.FileOptions.prototype.clearJavaGenericServices=function(){return e.Message.setField(this,17,void 0)},proto.google.protobuf.FileOptions.prototype.hasJavaGenericServices=function(){return e.Message.getField(this,17)!=null},proto.google.protobuf.FileOptions.prototype.getPyGenericServices=function(){return e.Message.getBooleanFieldWithDefault(this,18,!1)},proto.google.protobuf.FileOptions.prototype.setPyGenericServices=function(r){return e.Message.setField(this,18,r)},proto.google.protobuf.FileOptions.prototype.clearPyGenericServices=function(){return e.Message.setField(this,18,void 0)},proto.google.protobuf.FileOptions.prototype.hasPyGenericServices=function(){return e.Message.getField(this,18)!=null},proto.google.protobuf.FileOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,23,!1)},proto.google.protobuf.FileOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,23,r)},proto.google.protobuf.FileOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,23,void 0)},proto.google.protobuf.FileOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,23)!=null},proto.google.protobuf.FileOptions.prototype.getCcEnableArenas=function(){return e.Message.getBooleanFieldWithDefault(this,31,!0)},proto.google.protobuf.FileOptions.prototype.setCcEnableArenas=function(r){return e.Message.setField(this,31,r)},proto.google.protobuf.FileOptions.prototype.clearCcEnableArenas=function(){return e.Message.setField(this,31,void 0)},proto.google.protobuf.FileOptions.prototype.hasCcEnableArenas=function(){return e.Message.getField(this,31)!=null},proto.google.protobuf.FileOptions.prototype.getObjcClassPrefix=function(){return e.Message.getFieldWithDefault(this,36,"")},proto.google.protobuf.FileOptions.prototype.setObjcClassPrefix=function(r){return e.Message.setField(this,36,r)},proto.google.protobuf.FileOptions.prototype.clearObjcClassPrefix=function(){return e.Message.setField(this,36,void 0)},proto.google.protobuf.FileOptions.prototype.hasObjcClassPrefix=function(){return e.Message.getField(this,36)!=null},proto.google.protobuf.FileOptions.prototype.getCsharpNamespace=function(){return e.Message.getFieldWithDefault(this,37,"")},proto.google.protobuf.FileOptions.prototype.setCsharpNamespace=function(r){return e.Message.setField(this,37,r)},proto.google.protobuf.FileOptions.prototype.clearCsharpNamespace=function(){return e.Message.setField(this,37,void 0)},proto.google.protobuf.FileOptions.prototype.hasCsharpNamespace=function(){return e.Message.getField(this,37)!=null},proto.google.protobuf.FileOptions.prototype.getSwiftPrefix=function(){return e.Message.getFieldWithDefault(this,39,"")},proto.google.protobuf.FileOptions.prototype.setSwiftPrefix=function(r){return e.Message.setField(this,39,r)},proto.google.protobuf.FileOptions.prototype.clearSwiftPrefix=function(){return e.Message.setField(this,39,void 0)},proto.google.protobuf.FileOptions.prototype.hasSwiftPrefix=function(){return e.Message.getField(this,39)!=null},proto.google.protobuf.FileOptions.prototype.getPhpClassPrefix=function(){return e.Message.getFieldWithDefault(this,40,"")},proto.google.protobuf.FileOptions.prototype.setPhpClassPrefix=function(r){return e.Message.setField(this,40,r)},proto.google.protobuf.FileOptions.prototype.clearPhpClassPrefix=function(){return e.Message.setField(this,40,void 0)},proto.google.protobuf.FileOptions.prototype.hasPhpClassPrefix=function(){return e.Message.getField(this,40)!=null},proto.google.protobuf.FileOptions.prototype.getPhpNamespace=function(){return e.Message.getFieldWithDefault(this,41,"")},proto.google.protobuf.FileOptions.prototype.setPhpNamespace=function(r){return e.Message.setField(this,41,r)},proto.google.protobuf.FileOptions.prototype.clearPhpNamespace=function(){return e.Message.setField(this,41,void 0)},proto.google.protobuf.FileOptions.prototype.hasPhpNamespace=function(){return e.Message.getField(this,41)!=null},proto.google.protobuf.FileOptions.prototype.getPhpMetadataNamespace=function(){return e.Message.getFieldWithDefault(this,44,"")},proto.google.protobuf.FileOptions.prototype.setPhpMetadataNamespace=function(r){return e.Message.setField(this,44,r)},proto.google.protobuf.FileOptions.prototype.clearPhpMetadataNamespace=function(){return e.Message.setField(this,44,void 0)},proto.google.protobuf.FileOptions.prototype.hasPhpMetadataNamespace=function(){return e.Message.getField(this,44)!=null},proto.google.protobuf.FileOptions.prototype.getRubyPackage=function(){return e.Message.getFieldWithDefault(this,45,"")},proto.google.protobuf.FileOptions.prototype.setRubyPackage=function(r){return e.Message.setField(this,45,r)},proto.google.protobuf.FileOptions.prototype.clearRubyPackage=function(){return e.Message.setField(this,45,void 0)},proto.google.protobuf.FileOptions.prototype.hasRubyPackage=function(){return e.Message.getField(this,45)!=null},proto.google.protobuf.FileOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,50)},proto.google.protobuf.FileOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,50,r)},proto.google.protobuf.FileOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.FileOptions.prototype.hasFeatures=function(){return e.Message.getField(this,50)!=null},proto.google.protobuf.FileOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.FileOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.FileOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.FileOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.MessageOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.MessageOptions.prototype.toObject=function(r){return proto.google.protobuf.MessageOptions.toObject(r,this)},proto.google.protobuf.MessageOptions.toObject=function(r,o){var a,s={messageSetWireFormat:e.Message.getBooleanFieldWithDefault(o,1,!1),noStandardDescriptorAccessor:e.Message.getBooleanFieldWithDefault(o,2,!1),deprecated:e.Message.getBooleanFieldWithDefault(o,3,!1),mapEntry:(a=e.Message.getBooleanField(o,7))==null?void 0:a,deprecatedLegacyJsonFieldConflicts:(a=e.Message.getBooleanField(o,11))==null?void 0:a,features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.MessageOptions.extensions,proto.google.protobuf.MessageOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.MessageOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.MessageOptions;return proto.google.protobuf.MessageOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.MessageOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readBool();r.setMessageSetWireFormat(s);break;case 2:var s=o.readBool();r.setNoStandardDescriptorAccessor(s);break;case 3:var s=o.readBool();r.setDeprecated(s);break;case 7:var s=o.readBool();r.setMapEntry(s);break;case 11:var s=o.readBool();r.setDeprecatedLegacyJsonFieldConflicts(s);break;case 12:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.MessageOptions.extensionsBinary,proto.google.protobuf.MessageOptions.prototype.getExtension,proto.google.protobuf.MessageOptions.prototype.setExtension);break}}return r},proto.google.protobuf.MessageOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.MessageOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.MessageOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeBool(1,a),a=e.Message.getField(r,2),a!=null&&o.writeBool(2,a),a=e.Message.getField(r,3),a!=null&&o.writeBool(3,a),a=e.Message.getField(r,7),a!=null&&o.writeBool(7,a),a=e.Message.getField(r,11),a!=null&&o.writeBool(11,a),a=r.getFeatures(),a!=null&&o.writeMessage(12,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.MessageOptions.extensionsBinary,proto.google.protobuf.MessageOptions.prototype.getExtension)},proto.google.protobuf.MessageOptions.prototype.getMessageSetWireFormat=function(){return e.Message.getBooleanFieldWithDefault(this,1,!1)},proto.google.protobuf.MessageOptions.prototype.setMessageSetWireFormat=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.MessageOptions.prototype.clearMessageSetWireFormat=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.MessageOptions.prototype.hasMessageSetWireFormat=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.MessageOptions.prototype.getNoStandardDescriptorAccessor=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.google.protobuf.MessageOptions.prototype.setNoStandardDescriptorAccessor=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.MessageOptions.prototype.clearNoStandardDescriptorAccessor=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.MessageOptions.prototype.hasNoStandardDescriptorAccessor=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.MessageOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.google.protobuf.MessageOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.MessageOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.MessageOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.MessageOptions.prototype.getMapEntry=function(){return e.Message.getBooleanFieldWithDefault(this,7,!1)},proto.google.protobuf.MessageOptions.prototype.setMapEntry=function(r){return e.Message.setField(this,7,r)},proto.google.protobuf.MessageOptions.prototype.clearMapEntry=function(){return e.Message.setField(this,7,void 0)},proto.google.protobuf.MessageOptions.prototype.hasMapEntry=function(){return e.Message.getField(this,7)!=null},proto.google.protobuf.MessageOptions.prototype.getDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.getBooleanFieldWithDefault(this,11,!1)},proto.google.protobuf.MessageOptions.prototype.setDeprecatedLegacyJsonFieldConflicts=function(r){return e.Message.setField(this,11,r)},proto.google.protobuf.MessageOptions.prototype.clearDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.setField(this,11,void 0)},proto.google.protobuf.MessageOptions.prototype.hasDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.getField(this,11)!=null},proto.google.protobuf.MessageOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,12)},proto.google.protobuf.MessageOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,12,r)},proto.google.protobuf.MessageOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.MessageOptions.prototype.hasFeatures=function(){return e.Message.getField(this,12)!=null},proto.google.protobuf.MessageOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.MessageOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.MessageOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.MessageOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.FieldOptions.repeatedFields_=[19,20,999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FieldOptions.prototype.toObject=function(r){return proto.google.protobuf.FieldOptions.toObject(r,this)},proto.google.protobuf.FieldOptions.toObject=function(r,o){var a,s={ctype:e.Message.getFieldWithDefault(o,1,0),packed:(a=e.Message.getBooleanField(o,2))==null?void 0:a,jstype:e.Message.getFieldWithDefault(o,6,0),lazy:e.Message.getBooleanFieldWithDefault(o,5,!1),unverifiedLazy:e.Message.getBooleanFieldWithDefault(o,15,!1),deprecated:e.Message.getBooleanFieldWithDefault(o,3,!1),weak:e.Message.getBooleanFieldWithDefault(o,10,!1),debugRedact:e.Message.getBooleanFieldWithDefault(o,16,!1),retention:(a=e.Message.getField(o,17))==null?void 0:a,targetsList:(a=e.Message.getRepeatedField(o,19))==null?void 0:a,editionDefaultsList:e.Message.toObjectList(o.getEditionDefaultsList(),proto.google.protobuf.FieldOptions.EditionDefault.toObject,r),features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),featureSupport:(a=o.getFeatureSupport())&&proto.google.protobuf.FieldOptions.FeatureSupport.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.FieldOptions.extensions,proto.google.protobuf.FieldOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FieldOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FieldOptions;return proto.google.protobuf.FieldOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FieldOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var u=o.readEnum();r.setCtype(u);break;case 2:var u=o.readBool();r.setPacked(u);break;case 6:var u=o.readEnum();r.setJstype(u);break;case 5:var u=o.readBool();r.setLazy(u);break;case 15:var u=o.readBool();r.setUnverifiedLazy(u);break;case 3:var u=o.readBool();r.setDeprecated(u);break;case 10:var u=o.readBool();r.setWeak(u);break;case 16:var u=o.readBool();r.setDebugRedact(u);break;case 17:var u=o.readEnum();r.setRetention(u);break;case 19:for(var s=o.isDelimited()?o.readPackedEnum():[o.readEnum()],l=0;l<s.length;l++)r.addTargets(s[l]);break;case 20:var u=new proto.google.protobuf.FieldOptions.EditionDefault;o.readMessage(u,proto.google.protobuf.FieldOptions.EditionDefault.deserializeBinaryFromReader),r.addEditionDefaults(u);break;case 21:var u=new proto.google.protobuf.FeatureSet;o.readMessage(u,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(u);break;case 22:var u=new proto.google.protobuf.FieldOptions.FeatureSupport;o.readMessage(u,proto.google.protobuf.FieldOptions.FeatureSupport.deserializeBinaryFromReader),r.setFeatureSupport(u);break;case 999:var u=new proto.google.protobuf.UninterpretedOption;o.readMessage(u,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(u);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.FieldOptions.extensionsBinary,proto.google.protobuf.FieldOptions.prototype.getExtension,proto.google.protobuf.FieldOptions.prototype.setExtension);break}}return r},proto.google.protobuf.FieldOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FieldOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FieldOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeEnum(1,a),a=e.Message.getField(r,2),a!=null&&o.writeBool(2,a),a=e.Message.getField(r,6),a!=null&&o.writeEnum(6,a),a=e.Message.getField(r,5),a!=null&&o.writeBool(5,a),a=e.Message.getField(r,15),a!=null&&o.writeBool(15,a),a=e.Message.getField(r,3),a!=null&&o.writeBool(3,a),a=e.Message.getField(r,10),a!=null&&o.writeBool(10,a),a=e.Message.getField(r,16),a!=null&&o.writeBool(16,a),a=e.Message.getField(r,17),a!=null&&o.writeEnum(17,a),a=r.getTargetsList(),a.length>0&&o.writeRepeatedEnum(19,a),a=r.getEditionDefaultsList(),a.length>0&&o.writeRepeatedMessage(20,a,proto.google.protobuf.FieldOptions.EditionDefault.serializeBinaryToWriter),a=r.getFeatures(),a!=null&&o.writeMessage(21,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getFeatureSupport(),a!=null&&o.writeMessage(22,a,proto.google.protobuf.FieldOptions.FeatureSupport.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.FieldOptions.extensionsBinary,proto.google.protobuf.FieldOptions.prototype.getExtension)},proto.google.protobuf.FieldOptions.CType={STRING:0,CORD:1,STRING_PIECE:2},proto.google.protobuf.FieldOptions.JSType={JS_NORMAL:0,JS_STRING:1,JS_NUMBER:2},proto.google.protobuf.FieldOptions.OptionRetention={RETENTION_UNKNOWN:0,RETENTION_RUNTIME:1,RETENTION_SOURCE:2},proto.google.protobuf.FieldOptions.OptionTargetType={TARGET_TYPE_UNKNOWN:0,TARGET_TYPE_FILE:1,TARGET_TYPE_EXTENSION_RANGE:2,TARGET_TYPE_MESSAGE:3,TARGET_TYPE_FIELD:4,TARGET_TYPE_ONEOF:5,TARGET_TYPE_ENUM:6,TARGET_TYPE_ENUM_ENTRY:7,TARGET_TYPE_SERVICE:8,TARGET_TYPE_METHOD:9},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FieldOptions.EditionDefault.prototype.toObject=function(r){return proto.google.protobuf.FieldOptions.EditionDefault.toObject(r,this)},proto.google.protobuf.FieldOptions.EditionDefault.toObject=function(r,o){var a,s={edition:(a=e.Message.getField(o,3))==null?void 0:a,value:(a=e.Message.getField(o,2))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FieldOptions.EditionDefault.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FieldOptions.EditionDefault;return proto.google.protobuf.FieldOptions.EditionDefault.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FieldOptions.EditionDefault.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 3:var s=o.readEnum();r.setEdition(s);break;case 2:var s=o.readString();r.setValue(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FieldOptions.EditionDefault.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FieldOptions.EditionDefault.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FieldOptions.EditionDefault.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,3),a!=null&&o.writeEnum(3,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.getEdition=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.setEdition=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.clearEdition=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.hasEdition=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FieldOptions.EditionDefault.prototype.getValue=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.FieldOptions.EditionDefault.prototype.setValue=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.clearValue=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FieldOptions.EditionDefault.prototype.hasValue=function(){return e.Message.getField(this,2)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FieldOptions.FeatureSupport.prototype.toObject=function(r){return proto.google.protobuf.FieldOptions.FeatureSupport.toObject(r,this)},proto.google.protobuf.FieldOptions.FeatureSupport.toObject=function(r,o){var a,s={editionIntroduced:(a=e.Message.getField(o,1))==null?void 0:a,editionDeprecated:(a=e.Message.getField(o,2))==null?void 0:a,deprecationWarning:(a=e.Message.getField(o,3))==null?void 0:a,editionRemoved:(a=e.Message.getField(o,4))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FieldOptions.FeatureSupport.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FieldOptions.FeatureSupport;return proto.google.protobuf.FieldOptions.FeatureSupport.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FieldOptions.FeatureSupport.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readEnum();r.setEditionIntroduced(s);break;case 2:var s=o.readEnum();r.setEditionDeprecated(s);break;case 3:var s=o.readString();r.setDeprecationWarning(s);break;case 4:var s=o.readEnum();r.setEditionRemoved(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FieldOptions.FeatureSupport.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FieldOptions.FeatureSupport.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeEnum(1,a),a=e.Message.getField(r,2),a!=null&&o.writeEnum(2,a),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=e.Message.getField(r,4),a!=null&&o.writeEnum(4,a)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.getEditionIntroduced=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.setEditionIntroduced=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.clearEditionIntroduced=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.hasEditionIntroduced=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.getEditionDeprecated=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.setEditionDeprecated=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.clearEditionDeprecated=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.hasEditionDeprecated=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.getDeprecationWarning=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.setDeprecationWarning=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.clearDeprecationWarning=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.hasDeprecationWarning=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.getEditionRemoved=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.setEditionRemoved=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.clearEditionRemoved=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.FieldOptions.FeatureSupport.prototype.hasEditionRemoved=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.FieldOptions.prototype.getCtype=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.FieldOptions.prototype.setCtype=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FieldOptions.prototype.clearCtype=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FieldOptions.prototype.hasCtype=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FieldOptions.prototype.getPacked=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.google.protobuf.FieldOptions.prototype.setPacked=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FieldOptions.prototype.clearPacked=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FieldOptions.prototype.hasPacked=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.FieldOptions.prototype.getJstype=function(){return e.Message.getFieldWithDefault(this,6,0)},proto.google.protobuf.FieldOptions.prototype.setJstype=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.FieldOptions.prototype.clearJstype=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.FieldOptions.prototype.hasJstype=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.FieldOptions.prototype.getLazy=function(){return e.Message.getBooleanFieldWithDefault(this,5,!1)},proto.google.protobuf.FieldOptions.prototype.setLazy=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.FieldOptions.prototype.clearLazy=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.FieldOptions.prototype.hasLazy=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.FieldOptions.prototype.getUnverifiedLazy=function(){return e.Message.getBooleanFieldWithDefault(this,15,!1)},proto.google.protobuf.FieldOptions.prototype.setUnverifiedLazy=function(r){return e.Message.setField(this,15,r)},proto.google.protobuf.FieldOptions.prototype.clearUnverifiedLazy=function(){return e.Message.setField(this,15,void 0)},proto.google.protobuf.FieldOptions.prototype.hasUnverifiedLazy=function(){return e.Message.getField(this,15)!=null},proto.google.protobuf.FieldOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.google.protobuf.FieldOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FieldOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FieldOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FieldOptions.prototype.getWeak=function(){return e.Message.getBooleanFieldWithDefault(this,10,!1)},proto.google.protobuf.FieldOptions.prototype.setWeak=function(r){return e.Message.setField(this,10,r)},proto.google.protobuf.FieldOptions.prototype.clearWeak=function(){return e.Message.setField(this,10,void 0)},proto.google.protobuf.FieldOptions.prototype.hasWeak=function(){return e.Message.getField(this,10)!=null},proto.google.protobuf.FieldOptions.prototype.getDebugRedact=function(){return e.Message.getBooleanFieldWithDefault(this,16,!1)},proto.google.protobuf.FieldOptions.prototype.setDebugRedact=function(r){return e.Message.setField(this,16,r)},proto.google.protobuf.FieldOptions.prototype.clearDebugRedact=function(){return e.Message.setField(this,16,void 0)},proto.google.protobuf.FieldOptions.prototype.hasDebugRedact=function(){return e.Message.getField(this,16)!=null},proto.google.protobuf.FieldOptions.prototype.getRetention=function(){return e.Message.getFieldWithDefault(this,17,0)},proto.google.protobuf.FieldOptions.prototype.setRetention=function(r){return e.Message.setField(this,17,r)},proto.google.protobuf.FieldOptions.prototype.clearRetention=function(){return e.Message.setField(this,17,void 0)},proto.google.protobuf.FieldOptions.prototype.hasRetention=function(){return e.Message.getField(this,17)!=null},proto.google.protobuf.FieldOptions.prototype.getTargetsList=function(){return e.Message.getRepeatedField(this,19)},proto.google.protobuf.FieldOptions.prototype.setTargetsList=function(r){return e.Message.setField(this,19,r||[])},proto.google.protobuf.FieldOptions.prototype.addTargets=function(r,o){return e.Message.addToRepeatedField(this,19,r,o)},proto.google.protobuf.FieldOptions.prototype.clearTargetsList=function(){return this.setTargetsList([])},proto.google.protobuf.FieldOptions.prototype.getEditionDefaultsList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FieldOptions.EditionDefault,20)},proto.google.protobuf.FieldOptions.prototype.setEditionDefaultsList=function(r){return e.Message.setRepeatedWrapperField(this,20,r)},proto.google.protobuf.FieldOptions.prototype.addEditionDefaults=function(r,o){return e.Message.addToRepeatedWrapperField(this,20,r,proto.google.protobuf.FieldOptions.EditionDefault,o)},proto.google.protobuf.FieldOptions.prototype.clearEditionDefaultsList=function(){return this.setEditionDefaultsList([])},proto.google.protobuf.FieldOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,21)},proto.google.protobuf.FieldOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,21,r)},proto.google.protobuf.FieldOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.FieldOptions.prototype.hasFeatures=function(){return e.Message.getField(this,21)!=null},proto.google.protobuf.FieldOptions.prototype.getFeatureSupport=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FieldOptions.FeatureSupport,22)},proto.google.protobuf.FieldOptions.prototype.setFeatureSupport=function(r){return e.Message.setWrapperField(this,22,r)},proto.google.protobuf.FieldOptions.prototype.clearFeatureSupport=function(){return this.setFeatureSupport(void 0)},proto.google.protobuf.FieldOptions.prototype.hasFeatureSupport=function(){return e.Message.getField(this,22)!=null},proto.google.protobuf.FieldOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.FieldOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.FieldOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.FieldOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.OneofOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.OneofOptions.prototype.toObject=function(r){return proto.google.protobuf.OneofOptions.toObject(r,this)},proto.google.protobuf.OneofOptions.toObject=function(r,o){var a,s={features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.OneofOptions.extensions,proto.google.protobuf.OneofOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.OneofOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.OneofOptions;return proto.google.protobuf.OneofOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.OneofOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.OneofOptions.extensionsBinary,proto.google.protobuf.OneofOptions.prototype.getExtension,proto.google.protobuf.OneofOptions.prototype.setExtension);break}}return r},proto.google.protobuf.OneofOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.OneofOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.OneofOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getFeatures(),a!=null&&o.writeMessage(1,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.OneofOptions.extensionsBinary,proto.google.protobuf.OneofOptions.prototype.getExtension)},proto.google.protobuf.OneofOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,1)},proto.google.protobuf.OneofOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,1,r)},proto.google.protobuf.OneofOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.OneofOptions.prototype.hasFeatures=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.OneofOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.OneofOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.OneofOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.OneofOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.EnumOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.EnumOptions.prototype.toObject=function(r){return proto.google.protobuf.EnumOptions.toObject(r,this)},proto.google.protobuf.EnumOptions.toObject=function(r,o){var a,s={allowAlias:(a=e.Message.getBooleanField(o,2))==null?void 0:a,deprecated:e.Message.getBooleanFieldWithDefault(o,3,!1),deprecatedLegacyJsonFieldConflicts:(a=e.Message.getBooleanField(o,6))==null?void 0:a,features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.EnumOptions.extensions,proto.google.protobuf.EnumOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.EnumOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.EnumOptions;return proto.google.protobuf.EnumOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.EnumOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 2:var s=o.readBool();r.setAllowAlias(s);break;case 3:var s=o.readBool();r.setDeprecated(s);break;case 6:var s=o.readBool();r.setDeprecatedLegacyJsonFieldConflicts(s);break;case 7:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.EnumOptions.extensionsBinary,proto.google.protobuf.EnumOptions.prototype.getExtension,proto.google.protobuf.EnumOptions.prototype.setExtension);break}}return r},proto.google.protobuf.EnumOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.EnumOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.EnumOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,2),a!=null&&o.writeBool(2,a),a=e.Message.getField(r,3),a!=null&&o.writeBool(3,a),a=e.Message.getField(r,6),a!=null&&o.writeBool(6,a),a=r.getFeatures(),a!=null&&o.writeMessage(7,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.EnumOptions.extensionsBinary,proto.google.protobuf.EnumOptions.prototype.getExtension)},proto.google.protobuf.EnumOptions.prototype.getAllowAlias=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.google.protobuf.EnumOptions.prototype.setAllowAlias=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.EnumOptions.prototype.clearAllowAlias=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.EnumOptions.prototype.hasAllowAlias=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.EnumOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.google.protobuf.EnumOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.EnumOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.EnumOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.EnumOptions.prototype.getDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.getBooleanFieldWithDefault(this,6,!1)},proto.google.protobuf.EnumOptions.prototype.setDeprecatedLegacyJsonFieldConflicts=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.EnumOptions.prototype.clearDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.EnumOptions.prototype.hasDeprecatedLegacyJsonFieldConflicts=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.EnumOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,7)},proto.google.protobuf.EnumOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,7,r)},proto.google.protobuf.EnumOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.EnumOptions.prototype.hasFeatures=function(){return e.Message.getField(this,7)!=null},proto.google.protobuf.EnumOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.EnumOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.EnumOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.EnumOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.EnumValueOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.EnumValueOptions.prototype.toObject=function(r){return proto.google.protobuf.EnumValueOptions.toObject(r,this)},proto.google.protobuf.EnumValueOptions.toObject=function(r,o){var a,s={deprecated:e.Message.getBooleanFieldWithDefault(o,1,!1),features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),debugRedact:e.Message.getBooleanFieldWithDefault(o,3,!1),featureSupport:(a=o.getFeatureSupport())&&proto.google.protobuf.FieldOptions.FeatureSupport.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.EnumValueOptions.extensions,proto.google.protobuf.EnumValueOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.EnumValueOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.EnumValueOptions;return proto.google.protobuf.EnumValueOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.EnumValueOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readBool();r.setDeprecated(s);break;case 2:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 3:var s=o.readBool();r.setDebugRedact(s);break;case 4:var s=new proto.google.protobuf.FieldOptions.FeatureSupport;o.readMessage(s,proto.google.protobuf.FieldOptions.FeatureSupport.deserializeBinaryFromReader),r.setFeatureSupport(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.EnumValueOptions.extensionsBinary,proto.google.protobuf.EnumValueOptions.prototype.getExtension,proto.google.protobuf.EnumValueOptions.prototype.setExtension);break}}return r},proto.google.protobuf.EnumValueOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.EnumValueOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.EnumValueOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeBool(1,a),a=r.getFeatures(),a!=null&&o.writeMessage(2,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=e.Message.getField(r,3),a!=null&&o.writeBool(3,a),a=r.getFeatureSupport(),a!=null&&o.writeMessage(4,a,proto.google.protobuf.FieldOptions.FeatureSupport.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.EnumValueOptions.extensionsBinary,proto.google.protobuf.EnumValueOptions.prototype.getExtension)},proto.google.protobuf.EnumValueOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,1,!1)},proto.google.protobuf.EnumValueOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.EnumValueOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.EnumValueOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.EnumValueOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,2)},proto.google.protobuf.EnumValueOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,2,r)},proto.google.protobuf.EnumValueOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.EnumValueOptions.prototype.hasFeatures=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.EnumValueOptions.prototype.getDebugRedact=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.google.protobuf.EnumValueOptions.prototype.setDebugRedact=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.EnumValueOptions.prototype.clearDebugRedact=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.EnumValueOptions.prototype.hasDebugRedact=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.EnumValueOptions.prototype.getFeatureSupport=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FieldOptions.FeatureSupport,4)},proto.google.protobuf.EnumValueOptions.prototype.setFeatureSupport=function(r){return e.Message.setWrapperField(this,4,r)},proto.google.protobuf.EnumValueOptions.prototype.clearFeatureSupport=function(){return this.setFeatureSupport(void 0)},proto.google.protobuf.EnumValueOptions.prototype.hasFeatureSupport=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.EnumValueOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.EnumValueOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.EnumValueOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.EnumValueOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.ServiceOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.ServiceOptions.prototype.toObject=function(r){return proto.google.protobuf.ServiceOptions.toObject(r,this)},proto.google.protobuf.ServiceOptions.toObject=function(r,o){var a,s={features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),deprecated:e.Message.getBooleanFieldWithDefault(o,33,!1),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.ServiceOptions.extensions,proto.google.protobuf.ServiceOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.ServiceOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.ServiceOptions;return proto.google.protobuf.ServiceOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.ServiceOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 34:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 33:var s=o.readBool();r.setDeprecated(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.ServiceOptions.extensionsBinary,proto.google.protobuf.ServiceOptions.prototype.getExtension,proto.google.protobuf.ServiceOptions.prototype.setExtension);break}}return r},proto.google.protobuf.ServiceOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.ServiceOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.ServiceOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getFeatures(),a!=null&&o.writeMessage(34,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=e.Message.getField(r,33),a!=null&&o.writeBool(33,a),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.ServiceOptions.extensionsBinary,proto.google.protobuf.ServiceOptions.prototype.getExtension)},proto.google.protobuf.ServiceOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,34)},proto.google.protobuf.ServiceOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,34,r)},proto.google.protobuf.ServiceOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.ServiceOptions.prototype.hasFeatures=function(){return e.Message.getField(this,34)!=null},proto.google.protobuf.ServiceOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,33,!1)},proto.google.protobuf.ServiceOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,33,r)},proto.google.protobuf.ServiceOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,33,void 0)},proto.google.protobuf.ServiceOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,33)!=null},proto.google.protobuf.ServiceOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.ServiceOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.ServiceOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.ServiceOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.MethodOptions.repeatedFields_=[999],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.MethodOptions.prototype.toObject=function(r){return proto.google.protobuf.MethodOptions.toObject(r,this)},proto.google.protobuf.MethodOptions.toObject=function(r,o){var a,s={deprecated:e.Message.getBooleanFieldWithDefault(o,33,!1),idempotencyLevel:e.Message.getFieldWithDefault(o,34,0),features:(a=o.getFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),uninterpretedOptionList:e.Message.toObjectList(o.getUninterpretedOptionList(),proto.google.protobuf.UninterpretedOption.toObject,r)};return e.Message.toObjectExtension(o,s,proto.google.protobuf.MethodOptions.extensions,proto.google.protobuf.MethodOptions.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.MethodOptions.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.MethodOptions;return proto.google.protobuf.MethodOptions.deserializeBinaryFromReader(a,o)},proto.google.protobuf.MethodOptions.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 33:var s=o.readBool();r.setDeprecated(s);break;case 34:var s=o.readEnum();r.setIdempotencyLevel(s);break;case 35:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFeatures(s);break;case 999:var s=new proto.google.protobuf.UninterpretedOption;o.readMessage(s,proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader),r.addUninterpretedOption(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.MethodOptions.extensionsBinary,proto.google.protobuf.MethodOptions.prototype.getExtension,proto.google.protobuf.MethodOptions.prototype.setExtension);break}}return r},proto.google.protobuf.MethodOptions.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.MethodOptions.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.MethodOptions.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,33),a!=null&&o.writeBool(33,a),a=e.Message.getField(r,34),a!=null&&o.writeEnum(34,a),a=r.getFeatures(),a!=null&&o.writeMessage(35,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getUninterpretedOptionList(),a.length>0&&o.writeRepeatedMessage(999,a,proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.MethodOptions.extensionsBinary,proto.google.protobuf.MethodOptions.prototype.getExtension)},proto.google.protobuf.MethodOptions.IdempotencyLevel={IDEMPOTENCY_UNKNOWN:0,NO_SIDE_EFFECTS:1,IDEMPOTENT:2},proto.google.protobuf.MethodOptions.prototype.getDeprecated=function(){return e.Message.getBooleanFieldWithDefault(this,33,!1)},proto.google.protobuf.MethodOptions.prototype.setDeprecated=function(r){return e.Message.setField(this,33,r)},proto.google.protobuf.MethodOptions.prototype.clearDeprecated=function(){return e.Message.setField(this,33,void 0)},proto.google.protobuf.MethodOptions.prototype.hasDeprecated=function(){return e.Message.getField(this,33)!=null},proto.google.protobuf.MethodOptions.prototype.getIdempotencyLevel=function(){return e.Message.getFieldWithDefault(this,34,0)},proto.google.protobuf.MethodOptions.prototype.setIdempotencyLevel=function(r){return e.Message.setField(this,34,r)},proto.google.protobuf.MethodOptions.prototype.clearIdempotencyLevel=function(){return e.Message.setField(this,34,void 0)},proto.google.protobuf.MethodOptions.prototype.hasIdempotencyLevel=function(){return e.Message.getField(this,34)!=null},proto.google.protobuf.MethodOptions.prototype.getFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,35)},proto.google.protobuf.MethodOptions.prototype.setFeatures=function(r){return e.Message.setWrapperField(this,35,r)},proto.google.protobuf.MethodOptions.prototype.clearFeatures=function(){return this.setFeatures(void 0)},proto.google.protobuf.MethodOptions.prototype.hasFeatures=function(){return e.Message.getField(this,35)!=null},proto.google.protobuf.MethodOptions.prototype.getUninterpretedOptionList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption,999)},proto.google.protobuf.MethodOptions.prototype.setUninterpretedOptionList=function(r){return e.Message.setRepeatedWrapperField(this,999,r)},proto.google.protobuf.MethodOptions.prototype.addUninterpretedOption=function(r,o){return e.Message.addToRepeatedWrapperField(this,999,r,proto.google.protobuf.UninterpretedOption,o)},proto.google.protobuf.MethodOptions.prototype.clearUninterpretedOptionList=function(){return this.setUninterpretedOptionList([])},proto.google.protobuf.UninterpretedOption.repeatedFields_=[2],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.UninterpretedOption.prototype.toObject=function(r){return proto.google.protobuf.UninterpretedOption.toObject(r,this)},proto.google.protobuf.UninterpretedOption.toObject=function(r,o){var a,s={nameList:e.Message.toObjectList(o.getNameList(),proto.google.protobuf.UninterpretedOption.NamePart.toObject,r),identifierValue:(a=e.Message.getField(o,3))==null?void 0:a,positiveIntValue:(a=e.Message.getField(o,4))==null?void 0:a,negativeIntValue:(a=e.Message.getField(o,5))==null?void 0:a,doubleValue:(a=e.Message.getOptionalFloatingPointField(o,6))==null?void 0:a,stringValue:o.getStringValue_asB64(),aggregateValue:(a=e.Message.getField(o,8))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.UninterpretedOption.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.UninterpretedOption;return proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader(a,o)},proto.google.protobuf.UninterpretedOption.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 2:var s=new proto.google.protobuf.UninterpretedOption.NamePart;o.readMessage(s,proto.google.protobuf.UninterpretedOption.NamePart.deserializeBinaryFromReader),r.addName(s);break;case 3:var s=o.readString();r.setIdentifierValue(s);break;case 4:var s=o.readUint64();r.setPositiveIntValue(s);break;case 5:var s=o.readInt64();r.setNegativeIntValue(s);break;case 6:var s=o.readDouble();r.setDoubleValue(s);break;case 7:var s=o.readBytes();r.setStringValue(s);break;case 8:var s=o.readString();r.setAggregateValue(s);break;default:o.skipField();break}}return r},proto.google.protobuf.UninterpretedOption.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.UninterpretedOption.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getNameList(),a.length>0&&o.writeRepeatedMessage(2,a,proto.google.protobuf.UninterpretedOption.NamePart.serializeBinaryToWriter),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=e.Message.getField(r,4),a!=null&&o.writeUint64(4,a),a=e.Message.getField(r,5),a!=null&&o.writeInt64(5,a),a=e.Message.getField(r,6),a!=null&&o.writeDouble(6,a),a=e.Message.getField(r,7),a!=null&&o.writeBytes(7,a),a=e.Message.getField(r,8),a!=null&&o.writeString(8,a)},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.UninterpretedOption.NamePart.prototype.toObject=function(r){return proto.google.protobuf.UninterpretedOption.NamePart.toObject(r,this)},proto.google.protobuf.UninterpretedOption.NamePart.toObject=function(r,o){var a,s={namePart:(a=e.Message.getField(o,1))==null?void 0:a,isExtension:(a=e.Message.getBooleanField(o,2))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.UninterpretedOption.NamePart.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.UninterpretedOption.NamePart;return proto.google.protobuf.UninterpretedOption.NamePart.deserializeBinaryFromReader(a,o)},proto.google.protobuf.UninterpretedOption.NamePart.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readString();r.setNamePart(s);break;case 2:var s=o.readBool();r.setIsExtension(s);break;default:o.skipField();break}}return r},proto.google.protobuf.UninterpretedOption.NamePart.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.UninterpretedOption.NamePart.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.UninterpretedOption.NamePart.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeString(1,a),a=e.Message.getField(r,2),a!=null&&o.writeBool(2,a)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.getNamePart=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.google.protobuf.UninterpretedOption.NamePart.prototype.setNamePart=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.clearNamePart=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.hasNamePart=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.UninterpretedOption.NamePart.prototype.getIsExtension=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.setIsExtension=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.clearIsExtension=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.UninterpretedOption.NamePart.prototype.hasIsExtension=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.UninterpretedOption.prototype.getNameList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.UninterpretedOption.NamePart,2)},proto.google.protobuf.UninterpretedOption.prototype.setNameList=function(r){return e.Message.setRepeatedWrapperField(this,2,r)},proto.google.protobuf.UninterpretedOption.prototype.addName=function(r,o){return e.Message.addToRepeatedWrapperField(this,2,r,proto.google.protobuf.UninterpretedOption.NamePart,o)},proto.google.protobuf.UninterpretedOption.prototype.clearNameList=function(){return this.setNameList([])},proto.google.protobuf.UninterpretedOption.prototype.getIdentifierValue=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.protobuf.UninterpretedOption.prototype.setIdentifierValue=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.UninterpretedOption.prototype.clearIdentifierValue=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasIdentifierValue=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.UninterpretedOption.prototype.getPositiveIntValue=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.google.protobuf.UninterpretedOption.prototype.setPositiveIntValue=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.UninterpretedOption.prototype.clearPositiveIntValue=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasPositiveIntValue=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.UninterpretedOption.prototype.getNegativeIntValue=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.google.protobuf.UninterpretedOption.prototype.setNegativeIntValue=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.UninterpretedOption.prototype.clearNegativeIntValue=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasNegativeIntValue=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.UninterpretedOption.prototype.getDoubleValue=function(){return e.Message.getFloatingPointFieldWithDefault(this,6,0)},proto.google.protobuf.UninterpretedOption.prototype.setDoubleValue=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.UninterpretedOption.prototype.clearDoubleValue=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasDoubleValue=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.UninterpretedOption.prototype.getStringValue=function(){return e.Message.getFieldWithDefault(this,7,"")},proto.google.protobuf.UninterpretedOption.prototype.getStringValue_asB64=function(){return e.Message.bytesAsB64(this.getStringValue())},proto.google.protobuf.UninterpretedOption.prototype.getStringValue_asU8=function(){return e.Message.bytesAsU8(this.getStringValue())},proto.google.protobuf.UninterpretedOption.prototype.setStringValue=function(r){return e.Message.setField(this,7,r)},proto.google.protobuf.UninterpretedOption.prototype.clearStringValue=function(){return e.Message.setField(this,7,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasStringValue=function(){return e.Message.getField(this,7)!=null},proto.google.protobuf.UninterpretedOption.prototype.getAggregateValue=function(){return e.Message.getFieldWithDefault(this,8,"")},proto.google.protobuf.UninterpretedOption.prototype.setAggregateValue=function(r){return e.Message.setField(this,8,r)},proto.google.protobuf.UninterpretedOption.prototype.clearAggregateValue=function(){return e.Message.setField(this,8,void 0)},proto.google.protobuf.UninterpretedOption.prototype.hasAggregateValue=function(){return e.Message.getField(this,8)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FeatureSet.prototype.toObject=function(r){return proto.google.protobuf.FeatureSet.toObject(r,this)},proto.google.protobuf.FeatureSet.toObject=function(r,o){var a,s={fieldPresence:(a=e.Message.getField(o,1))==null?void 0:a,enumType:(a=e.Message.getField(o,2))==null?void 0:a,repeatedFieldEncoding:(a=e.Message.getField(o,3))==null?void 0:a,utf8Validation:(a=e.Message.getField(o,4))==null?void 0:a,messageEncoding:(a=e.Message.getField(o,5))==null?void 0:a,jsonFormat:(a=e.Message.getField(o,6))==null?void 0:a};return e.Message.toObjectExtension(o,s,proto.google.protobuf.FeatureSet.extensions,proto.google.protobuf.FeatureSet.prototype.getExtension,r),r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FeatureSet.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FeatureSet;return proto.google.protobuf.FeatureSet.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FeatureSet.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=o.readEnum();r.setFieldPresence(s);break;case 2:var s=o.readEnum();r.setEnumType(s);break;case 3:var s=o.readEnum();r.setRepeatedFieldEncoding(s);break;case 4:var s=o.readEnum();r.setUtf8Validation(s);break;case 5:var s=o.readEnum();r.setMessageEncoding(s);break;case 6:var s=o.readEnum();r.setJsonFormat(s);break;default:e.Message.readBinaryExtension(r,o,proto.google.protobuf.FeatureSet.extensionsBinary,proto.google.protobuf.FeatureSet.prototype.getExtension,proto.google.protobuf.FeatureSet.prototype.setExtension);break}}return r},proto.google.protobuf.FeatureSet.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FeatureSet.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FeatureSet.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,1),a!=null&&o.writeEnum(1,a),a=e.Message.getField(r,2),a!=null&&o.writeEnum(2,a),a=e.Message.getField(r,3),a!=null&&o.writeEnum(3,a),a=e.Message.getField(r,4),a!=null&&o.writeEnum(4,a),a=e.Message.getField(r,5),a!=null&&o.writeEnum(5,a),a=e.Message.getField(r,6),a!=null&&o.writeEnum(6,a),e.Message.serializeBinaryExtensions(r,o,proto.google.protobuf.FeatureSet.extensionsBinary,proto.google.protobuf.FeatureSet.prototype.getExtension)},proto.google.protobuf.FeatureSet.FieldPresence={FIELD_PRESENCE_UNKNOWN:0,EXPLICIT:1,IMPLICIT:2,LEGACY_REQUIRED:3},proto.google.protobuf.FeatureSet.EnumType={ENUM_TYPE_UNKNOWN:0,OPEN:1,CLOSED:2},proto.google.protobuf.FeatureSet.RepeatedFieldEncoding={REPEATED_FIELD_ENCODING_UNKNOWN:0,PACKED:1,EXPANDED:2},proto.google.protobuf.FeatureSet.Utf8Validation={UTF8_VALIDATION_UNKNOWN:0,VERIFY:2,NONE:3},proto.google.protobuf.FeatureSet.MessageEncoding={MESSAGE_ENCODING_UNKNOWN:0,LENGTH_PREFIXED:1,DELIMITED:2},proto.google.protobuf.FeatureSet.JsonFormat={JSON_FORMAT_UNKNOWN:0,ALLOW:1,LEGACY_BEST_EFFORT:2},proto.google.protobuf.FeatureSet.prototype.getFieldPresence=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.google.protobuf.FeatureSet.prototype.setFieldPresence=function(r){return e.Message.setField(this,1,r)},proto.google.protobuf.FeatureSet.prototype.clearFieldPresence=function(){return e.Message.setField(this,1,void 0)},proto.google.protobuf.FeatureSet.prototype.hasFieldPresence=function(){return e.Message.getField(this,1)!=null},proto.google.protobuf.FeatureSet.prototype.getEnumType=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.google.protobuf.FeatureSet.prototype.setEnumType=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.FeatureSet.prototype.clearEnumType=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.FeatureSet.prototype.hasEnumType=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.FeatureSet.prototype.getRepeatedFieldEncoding=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.google.protobuf.FeatureSet.prototype.setRepeatedFieldEncoding=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FeatureSet.prototype.clearRepeatedFieldEncoding=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FeatureSet.prototype.hasRepeatedFieldEncoding=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FeatureSet.prototype.getUtf8Validation=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.google.protobuf.FeatureSet.prototype.setUtf8Validation=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.FeatureSet.prototype.clearUtf8Validation=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.FeatureSet.prototype.hasUtf8Validation=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.FeatureSet.prototype.getMessageEncoding=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.google.protobuf.FeatureSet.prototype.setMessageEncoding=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.FeatureSet.prototype.clearMessageEncoding=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.FeatureSet.prototype.hasMessageEncoding=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.FeatureSet.prototype.getJsonFormat=function(){return e.Message.getFieldWithDefault(this,6,0)},proto.google.protobuf.FeatureSet.prototype.setJsonFormat=function(r){return e.Message.setField(this,6,r)},proto.google.protobuf.FeatureSet.prototype.clearJsonFormat=function(){return e.Message.setField(this,6,void 0)},proto.google.protobuf.FeatureSet.prototype.hasJsonFormat=function(){return e.Message.getField(this,6)!=null},proto.google.protobuf.FeatureSetDefaults.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FeatureSetDefaults.prototype.toObject=function(r){return proto.google.protobuf.FeatureSetDefaults.toObject(r,this)},proto.google.protobuf.FeatureSetDefaults.toObject=function(r,o){var a,s={defaultsList:e.Message.toObjectList(o.getDefaultsList(),proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.toObject,r),minimumEdition:(a=e.Message.getField(o,4))==null?void 0:a,maximumEdition:(a=e.Message.getField(o,5))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FeatureSetDefaults.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FeatureSetDefaults;return proto.google.protobuf.FeatureSetDefaults.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FeatureSetDefaults.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault;o.readMessage(s,proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.deserializeBinaryFromReader),r.addDefaults(s);break;case 4:var s=o.readEnum();r.setMinimumEdition(s);break;case 5:var s=o.readEnum();r.setMaximumEdition(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FeatureSetDefaults.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FeatureSetDefaults.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FeatureSetDefaults.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getDefaultsList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.serializeBinaryToWriter),a=e.Message.getField(r,4),a!=null&&o.writeEnum(4,a),a=e.Message.getField(r,5),a!=null&&o.writeEnum(5,a)},e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.toObject=function(r){return proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.toObject(r,this)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.toObject=function(r,o){var a,s={edition:(a=e.Message.getField(o,3))==null?void 0:a,overridableFeatures:(a=o.getOverridableFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a),fixedFeatures:(a=o.getFixedFeatures())&&proto.google.protobuf.FeatureSet.toObject(r,a)};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault;return proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.deserializeBinaryFromReader(a,o)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 3:var s=o.readEnum();r.setEdition(s);break;case 4:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setOverridableFeatures(s);break;case 5:var s=new proto.google.protobuf.FeatureSet;o.readMessage(s,proto.google.protobuf.FeatureSet.deserializeBinaryFromReader),r.setFixedFeatures(s);break;default:o.skipField();break}}return r},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.serializeBinaryToWriter=function(r,o){var a=void 0;a=e.Message.getField(r,3),a!=null&&o.writeEnum(3,a),a=r.getOverridableFeatures(),a!=null&&o.writeMessage(4,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter),a=r.getFixedFeatures(),a!=null&&o.writeMessage(5,a,proto.google.protobuf.FeatureSet.serializeBinaryToWriter)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.getEdition=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.setEdition=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.clearEdition=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.hasEdition=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.getOverridableFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,4)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.setOverridableFeatures=function(r){return e.Message.setWrapperField(this,4,r)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.clearOverridableFeatures=function(){return this.setOverridableFeatures(void 0)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.hasOverridableFeatures=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.getFixedFeatures=function(){return e.Message.getWrapperField(this,proto.google.protobuf.FeatureSet,5)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.setFixedFeatures=function(r){return e.Message.setWrapperField(this,5,r)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.clearFixedFeatures=function(){return this.setFixedFeatures(void 0)},proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault.prototype.hasFixedFeatures=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.FeatureSetDefaults.prototype.getDefaultsList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault,1)},proto.google.protobuf.FeatureSetDefaults.prototype.setDefaultsList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.google.protobuf.FeatureSetDefaults.prototype.addDefaults=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault,o)},proto.google.protobuf.FeatureSetDefaults.prototype.clearDefaultsList=function(){return this.setDefaultsList([])},proto.google.protobuf.FeatureSetDefaults.prototype.getMinimumEdition=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.google.protobuf.FeatureSetDefaults.prototype.setMinimumEdition=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.FeatureSetDefaults.prototype.clearMinimumEdition=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.FeatureSetDefaults.prototype.hasMinimumEdition=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.FeatureSetDefaults.prototype.getMaximumEdition=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.google.protobuf.FeatureSetDefaults.prototype.setMaximumEdition=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.FeatureSetDefaults.prototype.clearMaximumEdition=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.FeatureSetDefaults.prototype.hasMaximumEdition=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.SourceCodeInfo.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.SourceCodeInfo.prototype.toObject=function(r){return proto.google.protobuf.SourceCodeInfo.toObject(r,this)},proto.google.protobuf.SourceCodeInfo.toObject=function(r,o){var a={locationList:e.Message.toObjectList(o.getLocationList(),proto.google.protobuf.SourceCodeInfo.Location.toObject,r)};return r&&(a.$jspbMessageInstance=o),a}),proto.google.protobuf.SourceCodeInfo.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.SourceCodeInfo;return proto.google.protobuf.SourceCodeInfo.deserializeBinaryFromReader(a,o)},proto.google.protobuf.SourceCodeInfo.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.protobuf.SourceCodeInfo.Location;o.readMessage(s,proto.google.protobuf.SourceCodeInfo.Location.deserializeBinaryFromReader),r.addLocation(s);break;default:o.skipField();break}}return r},proto.google.protobuf.SourceCodeInfo.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.SourceCodeInfo.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.SourceCodeInfo.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getLocationList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.google.protobuf.SourceCodeInfo.Location.serializeBinaryToWriter)},proto.google.protobuf.SourceCodeInfo.Location.repeatedFields_=[1,2,6],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.SourceCodeInfo.Location.prototype.toObject=function(r){return proto.google.protobuf.SourceCodeInfo.Location.toObject(r,this)},proto.google.protobuf.SourceCodeInfo.Location.toObject=function(r,o){var a,s={pathList:(a=e.Message.getRepeatedField(o,1))==null?void 0:a,spanList:(a=e.Message.getRepeatedField(o,2))==null?void 0:a,leadingComments:(a=e.Message.getField(o,3))==null?void 0:a,trailingComments:(a=e.Message.getField(o,4))==null?void 0:a,leadingDetachedCommentsList:(a=e.Message.getRepeatedField(o,6))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.SourceCodeInfo.Location.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.SourceCodeInfo.Location;return proto.google.protobuf.SourceCodeInfo.Location.deserializeBinaryFromReader(a,o)},proto.google.protobuf.SourceCodeInfo.Location.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:for(var l=o.isDelimited()?o.readPackedInt32():[o.readInt32()],s=0;s<l.length;s++)r.addPath(l[s]);break;case 2:for(var l=o.isDelimited()?o.readPackedInt32():[o.readInt32()],s=0;s<l.length;s++)r.addSpan(l[s]);break;case 3:var u=o.readString();r.setLeadingComments(u);break;case 4:var u=o.readString();r.setTrailingComments(u);break;case 6:var u=o.readString();r.addLeadingDetachedComments(u);break;default:o.skipField();break}}return r},proto.google.protobuf.SourceCodeInfo.Location.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.SourceCodeInfo.Location.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.SourceCodeInfo.Location.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getPathList(),a.length>0&&o.writePackedInt32(1,a),a=r.getSpanList(),a.length>0&&o.writePackedInt32(2,a),a=e.Message.getField(r,3),a!=null&&o.writeString(3,a),a=e.Message.getField(r,4),a!=null&&o.writeString(4,a),a=r.getLeadingDetachedCommentsList(),a.length>0&&o.writeRepeatedString(6,a)},proto.google.protobuf.SourceCodeInfo.Location.prototype.getPathList=function(){return e.Message.getRepeatedField(this,1)},proto.google.protobuf.SourceCodeInfo.Location.prototype.setPathList=function(r){return e.Message.setField(this,1,r||[])},proto.google.protobuf.SourceCodeInfo.Location.prototype.addPath=function(r,o){return e.Message.addToRepeatedField(this,1,r,o)},proto.google.protobuf.SourceCodeInfo.Location.prototype.clearPathList=function(){return this.setPathList([])},proto.google.protobuf.SourceCodeInfo.Location.prototype.getSpanList=function(){return e.Message.getRepeatedField(this,2)},proto.google.protobuf.SourceCodeInfo.Location.prototype.setSpanList=function(r){return e.Message.setField(this,2,r||[])},proto.google.protobuf.SourceCodeInfo.Location.prototype.addSpan=function(r,o){return e.Message.addToRepeatedField(this,2,r,o)},proto.google.protobuf.SourceCodeInfo.Location.prototype.clearSpanList=function(){return this.setSpanList([])},proto.google.protobuf.SourceCodeInfo.Location.prototype.getLeadingComments=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.google.protobuf.SourceCodeInfo.Location.prototype.setLeadingComments=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.SourceCodeInfo.Location.prototype.clearLeadingComments=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.SourceCodeInfo.Location.prototype.hasLeadingComments=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.SourceCodeInfo.Location.prototype.getTrailingComments=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.google.protobuf.SourceCodeInfo.Location.prototype.setTrailingComments=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.SourceCodeInfo.Location.prototype.clearTrailingComments=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.SourceCodeInfo.Location.prototype.hasTrailingComments=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.SourceCodeInfo.Location.prototype.getLeadingDetachedCommentsList=function(){return e.Message.getRepeatedField(this,6)},proto.google.protobuf.SourceCodeInfo.Location.prototype.setLeadingDetachedCommentsList=function(r){return e.Message.setField(this,6,r||[])},proto.google.protobuf.SourceCodeInfo.Location.prototype.addLeadingDetachedComments=function(r,o){return e.Message.addToRepeatedField(this,6,r,o)},proto.google.protobuf.SourceCodeInfo.Location.prototype.clearLeadingDetachedCommentsList=function(){return this.setLeadingDetachedCommentsList([])},proto.google.protobuf.SourceCodeInfo.prototype.getLocationList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.SourceCodeInfo.Location,1)},proto.google.protobuf.SourceCodeInfo.prototype.setLocationList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.google.protobuf.SourceCodeInfo.prototype.addLocation=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.google.protobuf.SourceCodeInfo.Location,o)},proto.google.protobuf.SourceCodeInfo.prototype.clearLocationList=function(){return this.setLocationList([])},proto.google.protobuf.GeneratedCodeInfo.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.GeneratedCodeInfo.prototype.toObject=function(r){return proto.google.protobuf.GeneratedCodeInfo.toObject(r,this)},proto.google.protobuf.GeneratedCodeInfo.toObject=function(r,o){var a={annotationList:e.Message.toObjectList(o.getAnnotationList(),proto.google.protobuf.GeneratedCodeInfo.Annotation.toObject,r)};return r&&(a.$jspbMessageInstance=o),a}),proto.google.protobuf.GeneratedCodeInfo.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.GeneratedCodeInfo;return proto.google.protobuf.GeneratedCodeInfo.deserializeBinaryFromReader(a,o)},proto.google.protobuf.GeneratedCodeInfo.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:var s=new proto.google.protobuf.GeneratedCodeInfo.Annotation;o.readMessage(s,proto.google.protobuf.GeneratedCodeInfo.Annotation.deserializeBinaryFromReader),r.addAnnotation(s);break;default:o.skipField();break}}return r},proto.google.protobuf.GeneratedCodeInfo.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.GeneratedCodeInfo.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.GeneratedCodeInfo.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getAnnotationList(),a.length>0&&o.writeRepeatedMessage(1,a,proto.google.protobuf.GeneratedCodeInfo.Annotation.serializeBinaryToWriter)},proto.google.protobuf.GeneratedCodeInfo.Annotation.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.toObject=function(r){return proto.google.protobuf.GeneratedCodeInfo.Annotation.toObject(r,this)},proto.google.protobuf.GeneratedCodeInfo.Annotation.toObject=function(r,o){var a,s={pathList:(a=e.Message.getRepeatedField(o,1))==null?void 0:a,sourceFile:(a=e.Message.getField(o,2))==null?void 0:a,begin:(a=e.Message.getField(o,3))==null?void 0:a,end:(a=e.Message.getField(o,4))==null?void 0:a,semantic:(a=e.Message.getField(o,5))==null?void 0:a};return r&&(s.$jspbMessageInstance=o),s}),proto.google.protobuf.GeneratedCodeInfo.Annotation.deserializeBinary=function(r){var o=new e.BinaryReader(r),a=new proto.google.protobuf.GeneratedCodeInfo.Annotation;return proto.google.protobuf.GeneratedCodeInfo.Annotation.deserializeBinaryFromReader(a,o)},proto.google.protobuf.GeneratedCodeInfo.Annotation.deserializeBinaryFromReader=function(r,o){for(;o.nextField()&&!o.isEndGroup();){var a=o.getFieldNumber();switch(a){case 1:for(var s=o.isDelimited()?o.readPackedInt32():[o.readInt32()],l=0;l<s.length;l++)r.addPath(s[l]);break;case 2:var u=o.readString();r.setSourceFile(u);break;case 3:var u=o.readInt32();r.setBegin(u);break;case 4:var u=o.readInt32();r.setEnd(u);break;case 5:var u=o.readEnum();r.setSemantic(u);break;default:o.skipField();break}}return r},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.serializeBinary=function(){var r=new e.BinaryWriter;return proto.google.protobuf.GeneratedCodeInfo.Annotation.serializeBinaryToWriter(this,r),r.getResultBuffer()},proto.google.protobuf.GeneratedCodeInfo.Annotation.serializeBinaryToWriter=function(r,o){var a=void 0;a=r.getPathList(),a.length>0&&o.writePackedInt32(1,a),a=e.Message.getField(r,2),a!=null&&o.writeString(2,a),a=e.Message.getField(r,3),a!=null&&o.writeInt32(3,a),a=e.Message.getField(r,4),a!=null&&o.writeInt32(4,a),a=e.Message.getField(r,5),a!=null&&o.writeEnum(5,a)},proto.google.protobuf.GeneratedCodeInfo.Annotation.Semantic={NONE:0,SET:1,ALIAS:2},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.getPathList=function(){return e.Message.getRepeatedField(this,1)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.setPathList=function(r){return e.Message.setField(this,1,r||[])},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.addPath=function(r,o){return e.Message.addToRepeatedField(this,1,r,o)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.clearPathList=function(){return this.setPathList([])},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.getSourceFile=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.setSourceFile=function(r){return e.Message.setField(this,2,r)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.clearSourceFile=function(){return e.Message.setField(this,2,void 0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.hasSourceFile=function(){return e.Message.getField(this,2)!=null},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.getBegin=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.setBegin=function(r){return e.Message.setField(this,3,r)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.clearBegin=function(){return e.Message.setField(this,3,void 0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.hasBegin=function(){return e.Message.getField(this,3)!=null},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.getEnd=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.setEnd=function(r){return e.Message.setField(this,4,r)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.clearEnd=function(){return e.Message.setField(this,4,void 0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.hasEnd=function(){return e.Message.getField(this,4)!=null},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.getSemantic=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.setSemantic=function(r){return e.Message.setField(this,5,r)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.clearSemantic=function(){return e.Message.setField(this,5,void 0)},proto.google.protobuf.GeneratedCodeInfo.Annotation.prototype.hasSemantic=function(){return e.Message.getField(this,5)!=null},proto.google.protobuf.GeneratedCodeInfo.prototype.getAnnotationList=function(){return e.Message.getRepeatedWrapperField(this,proto.google.protobuf.GeneratedCodeInfo.Annotation,1)},proto.google.protobuf.GeneratedCodeInfo.prototype.setAnnotationList=function(r){return e.Message.setRepeatedWrapperField(this,1,r)},proto.google.protobuf.GeneratedCodeInfo.prototype.addAnnotation=function(r,o){return e.Message.addToRepeatedWrapperField(this,1,r,proto.google.protobuf.GeneratedCodeInfo.Annotation,o)},proto.google.protobuf.GeneratedCodeInfo.prototype.clearAnnotationList=function(){return this.setAnnotationList([])},proto.google.protobuf.Edition={EDITION_UNKNOWN:0,EDITION_LEGACY:900,EDITION_PROTO2:998,EDITION_PROTO3:999,EDITION_2023:1e3,EDITION_2024:1001,EDITION_1_TEST_ONLY:1,EDITION_2_TEST_ONLY:2,EDITION_99997_TEST_ONLY:99997,EDITION_99998_TEST_ONLY:99998,EDITION_99999_TEST_ONLY:99999,EDITION_MAX:2147483647},i.object.extend(t,proto.google.protobuf)})(_Y)),_Y}var ice;function XP(){return ice||(ice=1,(function(t){var e=qP(),i=e,n=Function("return this")(),r=B0t();i.object.extend(proto,r);var o=j0t();i.object.extend(proto,o),i.exportSymbol("proto.google.api.http",null,n),proto.google.api.http=new e.ExtensionFieldInfo(72295728,{http:0},r.HttpRule,r.HttpRule.toObject,0),o.MethodOptions.extensionsBinary[72295728]=new e.ExtensionFieldBinaryInfo(proto.google.api.http,e.BinaryReader.prototype.readMessage,e.BinaryWriter.prototype.writeMessage,r.HttpRule.serializeBinaryToWriter,r.HttpRule.deserializeBinaryFromReader,!1),o.MethodOptions.extensions[72295728]=proto.google.api.http,i.object.extend(t,proto.google.api)})(bY)),bY}var PY={},nce;function V0t(){return nce||(nce=1,(function(t){var e=qP(),i=e,n=Function("return this")(),r=jS();i.object.extend(proto,r);var o=XP();i.object.extend(proto,o),i.exportSymbol("proto.diagnostics.Link",null,n),i.exportSymbol("proto.diagnostics.LinkTimers",null,n),i.exportSymbol("proto.diagnostics.Payload",null,n),i.exportSymbol("proto.diagnostics.PublisherConfig",null,n),i.exportSymbol("proto.diagnostics.SubscriberConfig",null,n),proto.diagnostics.LinkTimers=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.diagnostics.LinkTimers,e.Message),i.DEBUG&&!COMPILED&&(proto.diagnostics.LinkTimers.displayName="proto.diagnostics.LinkTimers"),proto.diagnostics.PublisherConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.diagnostics.PublisherConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.diagnostics.PublisherConfig.displayName="proto.diagnostics.PublisherConfig"),proto.diagnostics.SubscriberConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.diagnostics.SubscriberConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.diagnostics.SubscriberConfig.displayName="proto.diagnostics.SubscriberConfig"),proto.diagnostics.Payload=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.diagnostics.Payload,e.Message),i.DEBUG&&!COMPILED&&(proto.diagnostics.Payload.displayName="proto.diagnostics.Payload"),proto.diagnostics.Link=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.diagnostics.Link,e.Message),i.DEBUG&&!COMPILED&&(proto.diagnostics.Link.displayName="proto.diagnostics.Link"),e.Message.GENERATE_TO_OBJECT&&(proto.diagnostics.LinkTimers.prototype.toObject=function(a){return proto.diagnostics.LinkTimers.toObject(a,this)},proto.diagnostics.LinkTimers.toObject=function(a,s){var l={maxresponsetimeout:e.Message.getFieldWithDefault(s,3,0),delayresponse:e.Message.getFieldWithDefault(s,4,0)};return a&&(l.$jspbMessageInstance=s),l}),proto.diagnostics.LinkTimers.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.diagnostics.LinkTimers;return proto.diagnostics.LinkTimers.deserializeBinaryFromReader(l,s)},proto.diagnostics.LinkTimers.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 3:var u=s.readInt64();a.setMaxresponsetimeout(u);break;case 4:var u=s.readInt64();a.setDelayresponse(u);break;default:s.skipField();break}}return a},proto.diagnostics.LinkTimers.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.diagnostics.LinkTimers.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.diagnostics.LinkTimers.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getMaxresponsetimeout(),l!==0&&s.writeInt64(3,l),l=a.getDelayresponse(),l!==0&&s.writeInt64(4,l)},proto.diagnostics.LinkTimers.prototype.getMaxresponsetimeout=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.diagnostics.LinkTimers.prototype.setMaxresponsetimeout=function(a){return e.Message.setProto3IntField(this,3,a)},proto.diagnostics.LinkTimers.prototype.getDelayresponse=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.diagnostics.LinkTimers.prototype.setDelayresponse=function(a){return e.Message.setProto3IntField(this,4,a)},e.Message.GENERATE_TO_OBJECT&&(proto.diagnostics.PublisherConfig.prototype.toObject=function(a){return proto.diagnostics.PublisherConfig.toObject(a,this)},proto.diagnostics.PublisherConfig.toObject=function(a,s){var l,u={link:(l=s.getLink())&&proto.diagnostics.Link.toObject(a,l),payload:(l=s.getPayload())&&proto.diagnostics.Payload.toObject(a,l),linktimers:(l=s.getLinktimers())&&proto.diagnostics.LinkTimers.toObject(a,l),nopadding:e.Message.getBooleanFieldWithDefault(s,4,!1)};return a&&(u.$jspbMessageInstance=s),u}),proto.diagnostics.PublisherConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.diagnostics.PublisherConfig;return proto.diagnostics.PublisherConfig.deserializeBinaryFromReader(l,s)},proto.diagnostics.PublisherConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.diagnostics.Link;s.readMessage(u,proto.diagnostics.Link.deserializeBinaryFromReader),a.setLink(u);break;case 2:var u=new proto.diagnostics.Payload;s.readMessage(u,proto.diagnostics.Payload.deserializeBinaryFromReader),a.setPayload(u);break;case 3:var u=new proto.diagnostics.LinkTimers;s.readMessage(u,proto.diagnostics.LinkTimers.deserializeBinaryFromReader),a.setLinktimers(u);break;case 4:var u=s.readBool();a.setNopadding(u);break;default:s.skipField();break}}return a},proto.diagnostics.PublisherConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.diagnostics.PublisherConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.diagnostics.PublisherConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getLink(),l!=null&&s.writeMessage(1,l,proto.diagnostics.Link.serializeBinaryToWriter),l=a.getPayload(),l!=null&&s.writeMessage(2,l,proto.diagnostics.Payload.serializeBinaryToWriter),l=a.getLinktimers(),l!=null&&s.writeMessage(3,l,proto.diagnostics.LinkTimers.serializeBinaryToWriter),l=a.getNopadding(),l&&s.writeBool(4,l)},proto.diagnostics.PublisherConfig.prototype.getLink=function(){return e.Message.getWrapperField(this,proto.diagnostics.Link,1)},proto.diagnostics.PublisherConfig.prototype.setLink=function(a){return e.Message.setWrapperField(this,1,a)},proto.diagnostics.PublisherConfig.prototype.clearLink=function(){return this.setLink(void 0)},proto.diagnostics.PublisherConfig.prototype.hasLink=function(){return e.Message.getField(this,1)!=null},proto.diagnostics.PublisherConfig.prototype.getPayload=function(){return e.Message.getWrapperField(this,proto.diagnostics.Payload,2)},proto.diagnostics.PublisherConfig.prototype.setPayload=function(a){return e.Message.setWrapperField(this,2,a)},proto.diagnostics.PublisherConfig.prototype.clearPayload=function(){return this.setPayload(void 0)},proto.diagnostics.PublisherConfig.prototype.hasPayload=function(){return e.Message.getField(this,2)!=null},proto.diagnostics.PublisherConfig.prototype.getLinktimers=function(){return e.Message.getWrapperField(this,proto.diagnostics.LinkTimers,3)},proto.diagnostics.PublisherConfig.prototype.setLinktimers=function(a){return e.Message.setWrapperField(this,3,a)},proto.diagnostics.PublisherConfig.prototype.clearLinktimers=function(){return this.setLinktimers(void 0)},proto.diagnostics.PublisherConfig.prototype.hasLinktimers=function(){return e.Message.getField(this,3)!=null},proto.diagnostics.PublisherConfig.prototype.getNopadding=function(){return e.Message.getBooleanFieldWithDefault(this,4,!1)},proto.diagnostics.PublisherConfig.prototype.setNopadding=function(a){return e.Message.setProto3BooleanField(this,4,a)},e.Message.GENERATE_TO_OBJECT&&(proto.diagnostics.SubscriberConfig.prototype.toObject=function(a){return proto.diagnostics.SubscriberConfig.toObject(a,this)},proto.diagnostics.SubscriberConfig.toObject=function(a,s){var l,u={link:(l=s.getLink())&&proto.diagnostics.Link.toObject(a,l),linktimers:(l=s.getLinktimers())&&proto.diagnostics.LinkTimers.toObject(a,l),rawpayload:e.Message.getBooleanFieldWithDefault(s,3,!1),nopadding:e.Message.getBooleanFieldWithDefault(s,4,!1)};return a&&(u.$jspbMessageInstance=s),u}),proto.diagnostics.SubscriberConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.diagnostics.SubscriberConfig;return proto.diagnostics.SubscriberConfig.deserializeBinaryFromReader(l,s)},proto.diagnostics.SubscriberConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.diagnostics.Link;s.readMessage(u,proto.diagnostics.Link.deserializeBinaryFromReader),a.setLink(u);break;case 2:var u=new proto.diagnostics.LinkTimers;s.readMessage(u,proto.diagnostics.LinkTimers.deserializeBinaryFromReader),a.setLinktimers(u);break;case 3:var u=s.readBool();a.setRawpayload(u);break;case 4:var u=s.readBool();a.setNopadding(u);break;default:s.skipField();break}}return a},proto.diagnostics.SubscriberConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.diagnostics.SubscriberConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.diagnostics.SubscriberConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getLink(),l!=null&&s.writeMessage(1,l,proto.diagnostics.Link.serializeBinaryToWriter),l=a.getLinktimers(),l!=null&&s.writeMessage(2,l,proto.diagnostics.LinkTimers.serializeBinaryToWriter),l=a.getRawpayload(),l&&s.writeBool(3,l),l=a.getNopadding(),l&&s.writeBool(4,l)},proto.diagnostics.SubscriberConfig.prototype.getLink=function(){return e.Message.getWrapperField(this,proto.diagnostics.Link,1)},proto.diagnostics.SubscriberConfig.prototype.setLink=function(a){return e.Message.setWrapperField(this,1,a)},proto.diagnostics.SubscriberConfig.prototype.clearLink=function(){return this.setLink(void 0)},proto.diagnostics.SubscriberConfig.prototype.hasLink=function(){return e.Message.getField(this,1)!=null},proto.diagnostics.SubscriberConfig.prototype.getLinktimers=function(){return e.Message.getWrapperField(this,proto.diagnostics.LinkTimers,2)},proto.diagnostics.SubscriberConfig.prototype.setLinktimers=function(a){return e.Message.setWrapperField(this,2,a)},proto.diagnostics.SubscriberConfig.prototype.clearLinktimers=function(){return this.setLinktimers(void 0)},proto.diagnostics.SubscriberConfig.prototype.hasLinktimers=function(){return e.Message.getField(this,2)!=null},proto.diagnostics.SubscriberConfig.prototype.getRawpayload=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.diagnostics.SubscriberConfig.prototype.setRawpayload=function(a){return e.Message.setProto3BooleanField(this,3,a)},proto.diagnostics.SubscriberConfig.prototype.getNopadding=function(){return e.Message.getBooleanFieldWithDefault(this,4,!1)},proto.diagnostics.SubscriberConfig.prototype.setNopadding=function(a){return e.Message.setProto3BooleanField(this,4,a)},e.Message.GENERATE_TO_OBJECT&&(proto.diagnostics.Payload.prototype.toObject=function(a){return proto.diagnostics.Payload.toObject(a,this)},proto.diagnostics.Payload.toObject=function(a,s){var l={bytes:s.getBytes_asB64()};return a&&(l.$jspbMessageInstance=s),l}),proto.diagnostics.Payload.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.diagnostics.Payload;return proto.diagnostics.Payload.deserializeBinaryFromReader(l,s)},proto.diagnostics.Payload.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readBytes();a.setBytes(u);break;default:s.skipField();break}}return a},proto.diagnostics.Payload.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.diagnostics.Payload.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.diagnostics.Payload.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getBytes_asU8(),l.length>0&&s.writeBytes(1,l)},proto.diagnostics.Payload.prototype.getBytes=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.diagnostics.Payload.prototype.getBytes_asB64=function(){return e.Message.bytesAsB64(this.getBytes())},proto.diagnostics.Payload.prototype.getBytes_asU8=function(){return e.Message.bytesAsU8(this.getBytes())},proto.diagnostics.Payload.prototype.setBytes=function(a){return e.Message.setProto3BytesField(this,1,a)},e.Message.GENERATE_TO_OBJECT&&(proto.diagnostics.Link.prototype.toObject=function(a){return proto.diagnostics.Link.toObject(a,this)},proto.diagnostics.Link.toObject=function(a,s){var l,u={clientid:(l=s.getClientid())&&r.ClientId.toObject(a,l),publishsignal:(l=s.getPublishsignal())&&r.SignalId.toObject(a,l),subscribesignal:(l=s.getSubscribesignal())&&r.SignalId.toObject(a,l)};return a&&(u.$jspbMessageInstance=s),u}),proto.diagnostics.Link.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.diagnostics.Link;return proto.diagnostics.Link.deserializeBinaryFromReader(l,s)},proto.diagnostics.Link.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.ClientId;s.readMessage(u,r.ClientId.deserializeBinaryFromReader),a.setClientid(u);break;case 2:var u=new r.SignalId;s.readMessage(u,r.SignalId.deserializeBinaryFromReader),a.setPublishsignal(u);break;case 3:var u=new r.SignalId;s.readMessage(u,r.SignalId.deserializeBinaryFromReader),a.setSubscribesignal(u);break;default:s.skipField();break}}return a},proto.diagnostics.Link.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.diagnostics.Link.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.diagnostics.Link.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getClientid(),l!=null&&s.writeMessage(1,l,r.ClientId.serializeBinaryToWriter),l=a.getPublishsignal(),l!=null&&s.writeMessage(2,l,r.SignalId.serializeBinaryToWriter),l=a.getSubscribesignal(),l!=null&&s.writeMessage(3,l,r.SignalId.serializeBinaryToWriter)},proto.diagnostics.Link.prototype.getClientid=function(){return e.Message.getWrapperField(this,r.ClientId,1)},proto.diagnostics.Link.prototype.setClientid=function(a){return e.Message.setWrapperField(this,1,a)},proto.diagnostics.Link.prototype.clearClientid=function(){return this.setClientid(void 0)},proto.diagnostics.Link.prototype.hasClientid=function(){return e.Message.getField(this,1)!=null},proto.diagnostics.Link.prototype.getPublishsignal=function(){return e.Message.getWrapperField(this,r.SignalId,2)},proto.diagnostics.Link.prototype.setPublishsignal=function(a){return e.Message.setWrapperField(this,2,a)},proto.diagnostics.Link.prototype.clearPublishsignal=function(){return this.setPublishsignal(void 0)},proto.diagnostics.Link.prototype.hasPublishsignal=function(){return e.Message.getField(this,2)!=null},proto.diagnostics.Link.prototype.getSubscribesignal=function(){return e.Message.getWrapperField(this,r.SignalId,3)},proto.diagnostics.Link.prototype.setSubscribesignal=function(a){return e.Message.setWrapperField(this,3,a)},proto.diagnostics.Link.prototype.clearSubscribesignal=function(){return this.setSubscribesignal(void 0)},proto.diagnostics.Link.prototype.hasSubscribesignal=function(){return e.Message.getField(this,3)!=null},i.object.extend(t,proto.diagnostics)})(PY)),PY}var CY,oce;function H0t(){if(oce)return CY;oce=1;const t={};t.web=B6();var e=jS();XP();const i={};i.diagnostics=V0t(),i.diagnostics.DiagnosticsServiceClient=function(o,a,s){s||(s={}),s.format="text",this.client_=new t.web.GrpcWebClientBase(s),this.hostname_=o},i.diagnostics.DiagnosticsServicePromiseClient=function(o,a,s){s||(s={}),s.format="text",this.client_=new t.web.GrpcWebClientBase(s),this.hostname_=o};const n=new t.web.MethodDescriptor("/diagnostics.DiagnosticsService/PublishMultiFrame",t.web.MethodType.UNARY,i.diagnostics.PublisherConfig,e.Empty,function(o){return o.serializeBinary()},e.Empty.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(e.Empty,function(o){return o.serializeBinary()},e.Empty.deserializeBinary),i.diagnostics.DiagnosticsServiceClient.prototype.publishMultiFrame=function(o,a,s){return this.client_.rpcCall(this.hostname_+"/diagnostics.DiagnosticsService/PublishMultiFrame",o,a||{},n,s)},i.diagnostics.DiagnosticsServicePromiseClient.prototype.publishMultiFrame=function(o,a){return this.client_.unaryCall(this.hostname_+"/diagnostics.DiagnosticsService/PublishMultiFrame",o,a||{},n)};const r=new t.web.MethodDescriptor("/diagnostics.DiagnosticsService/SubscribeMultiFrame",t.web.MethodType.SERVER_STREAMING,i.diagnostics.SubscriberConfig,i.diagnostics.Payload,function(o){return o.serializeBinary()},i.diagnostics.Payload.deserializeBinary);return new t.web.AbstractClientBase.MethodInfo(i.diagnostics.Payload,function(o){return o.serializeBinary()},i.diagnostics.Payload.deserializeBinary),i.diagnostics.DiagnosticsServiceClient.prototype.subscribeMultiFrame=function(o,a){return this.client_.serverStreaming(this.hostname_+"/diagnostics.DiagnosticsService/SubscribeMultiFrame",o,a||{},r)},i.diagnostics.DiagnosticsServicePromiseClient.prototype.subscribeMultiFrame=function(o,a){return this.client_.serverStreaming(this.hostname_+"/diagnostics.DiagnosticsService/SubscribeMultiFrame",o,a||{},r)},CY=i.diagnostics,CY}var TY={},ace;function Xke(){return ace||(ace=1,(function(t){var e=qP(),i=e,n=Function("return this")(),r=jS();i.object.extend(proto,r);var o=XP();i.object.extend(proto,o),i.exportSymbol("proto.base.CountByFrameId",null,n),i.exportSymbol("proto.base.FramesDistribution",null,n),i.exportSymbol("proto.base.FramesDistributionConfig",null,n),i.exportSymbol("proto.base.PublisherConfig",null,n),i.exportSymbol("proto.base.Signal",null,n),i.exportSymbol("proto.base.Signal.PayloadCase",null,n),i.exportSymbol("proto.base.SignalIds",null,n),i.exportSymbol("proto.base.Signals",null,n),i.exportSymbol("proto.base.SubscriberConfig",null,n),i.exportSymbol("proto.base.SubscriberWithScriptConfig",null,n),proto.base.SubscriberConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.SubscriberConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.base.SubscriberConfig.displayName="proto.base.SubscriberConfig"),proto.base.SubscriberWithScriptConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.SubscriberWithScriptConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.base.SubscriberWithScriptConfig.displayName="proto.base.SubscriberWithScriptConfig"),proto.base.FramesDistributionConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.FramesDistributionConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FramesDistributionConfig.displayName="proto.base.FramesDistributionConfig"),proto.base.CountByFrameId=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.CountByFrameId,e.Message),i.DEBUG&&!COMPILED&&(proto.base.CountByFrameId.displayName="proto.base.CountByFrameId"),proto.base.FramesDistribution=function(a){e.Message.initialize(this,a,0,-1,proto.base.FramesDistribution.repeatedFields_,null)},i.inherits(proto.base.FramesDistribution,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FramesDistribution.displayName="proto.base.FramesDistribution"),proto.base.SignalIds=function(a){e.Message.initialize(this,a,0,-1,proto.base.SignalIds.repeatedFields_,null)},i.inherits(proto.base.SignalIds,e.Message),i.DEBUG&&!COMPILED&&(proto.base.SignalIds.displayName="proto.base.SignalIds"),proto.base.Signals=function(a){e.Message.initialize(this,a,0,-1,proto.base.Signals.repeatedFields_,null)},i.inherits(proto.base.Signals,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Signals.displayName="proto.base.Signals"),proto.base.PublisherConfig=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.PublisherConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PublisherConfig.displayName="proto.base.PublisherConfig"),proto.base.Signal=function(a){e.Message.initialize(this,a,0,-1,null,proto.base.Signal.oneofGroups_)},i.inherits(proto.base.Signal,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Signal.displayName="proto.base.Signal"),e.Message.GENERATE_TO_OBJECT&&(proto.base.SubscriberConfig.prototype.toObject=function(a){return proto.base.SubscriberConfig.toObject(a,this)},proto.base.SubscriberConfig.toObject=function(a,s){var l,u={clientid:(l=s.getClientid())&&r.ClientId.toObject(a,l),signals:(l=s.getSignals())&&proto.base.SignalIds.toObject(a,l),onchange:e.Message.getBooleanFieldWithDefault(s,3,!1),initialempty:e.Message.getBooleanFieldWithDefault(s,4,!1)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.SubscriberConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.SubscriberConfig;return proto.base.SubscriberConfig.deserializeBinaryFromReader(l,s)},proto.base.SubscriberConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.ClientId;s.readMessage(u,r.ClientId.deserializeBinaryFromReader),a.setClientid(u);break;case 2:var u=new proto.base.SignalIds;s.readMessage(u,proto.base.SignalIds.deserializeBinaryFromReader),a.setSignals(u);break;case 3:var u=s.readBool();a.setOnchange(u);break;case 4:var u=s.readBool();a.setInitialempty(u);break;default:s.skipField();break}}return a},proto.base.SubscriberConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.SubscriberConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.SubscriberConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getClientid(),l!=null&&s.writeMessage(1,l,r.ClientId.serializeBinaryToWriter),l=a.getSignals(),l!=null&&s.writeMessage(2,l,proto.base.SignalIds.serializeBinaryToWriter),l=a.getOnchange(),l&&s.writeBool(3,l),l=a.getInitialempty(),l&&s.writeBool(4,l)},proto.base.SubscriberConfig.prototype.getClientid=function(){return e.Message.getWrapperField(this,r.ClientId,1)},proto.base.SubscriberConfig.prototype.setClientid=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.SubscriberConfig.prototype.clearClientid=function(){return this.setClientid(void 0)},proto.base.SubscriberConfig.prototype.hasClientid=function(){return e.Message.getField(this,1)!=null},proto.base.SubscriberConfig.prototype.getSignals=function(){return e.Message.getWrapperField(this,proto.base.SignalIds,2)},proto.base.SubscriberConfig.prototype.setSignals=function(a){return e.Message.setWrapperField(this,2,a)},proto.base.SubscriberConfig.prototype.clearSignals=function(){return this.setSignals(void 0)},proto.base.SubscriberConfig.prototype.hasSignals=function(){return e.Message.getField(this,2)!=null},proto.base.SubscriberConfig.prototype.getOnchange=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.base.SubscriberConfig.prototype.setOnchange=function(a){return e.Message.setProto3BooleanField(this,3,a)},proto.base.SubscriberConfig.prototype.getInitialempty=function(){return e.Message.getBooleanFieldWithDefault(this,4,!1)},proto.base.SubscriberConfig.prototype.setInitialempty=function(a){return e.Message.setProto3BooleanField(this,4,a)},e.Message.GENERATE_TO_OBJECT&&(proto.base.SubscriberWithScriptConfig.prototype.toObject=function(a){return proto.base.SubscriberWithScriptConfig.toObject(a,this)},proto.base.SubscriberWithScriptConfig.toObject=function(a,s){var l,u={clientid:(l=s.getClientid())&&r.ClientId.toObject(a,l),script:s.getScript_asB64(),onchange:e.Message.getBooleanFieldWithDefault(s,3,!1)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.SubscriberWithScriptConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.SubscriberWithScriptConfig;return proto.base.SubscriberWithScriptConfig.deserializeBinaryFromReader(l,s)},proto.base.SubscriberWithScriptConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.ClientId;s.readMessage(u,r.ClientId.deserializeBinaryFromReader),a.setClientid(u);break;case 2:var u=s.readBytes();a.setScript(u);break;case 3:var u=s.readBool();a.setOnchange(u);break;default:s.skipField();break}}return a},proto.base.SubscriberWithScriptConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.SubscriberWithScriptConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.SubscriberWithScriptConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getClientid(),l!=null&&s.writeMessage(1,l,r.ClientId.serializeBinaryToWriter),l=a.getScript_asU8(),l.length>0&&s.writeBytes(2,l),l=a.getOnchange(),l&&s.writeBool(3,l)},proto.base.SubscriberWithScriptConfig.prototype.getClientid=function(){return e.Message.getWrapperField(this,r.ClientId,1)},proto.base.SubscriberWithScriptConfig.prototype.setClientid=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.SubscriberWithScriptConfig.prototype.clearClientid=function(){return this.setClientid(void 0)},proto.base.SubscriberWithScriptConfig.prototype.hasClientid=function(){return e.Message.getField(this,1)!=null},proto.base.SubscriberWithScriptConfig.prototype.getScript=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.SubscriberWithScriptConfig.prototype.getScript_asB64=function(){return e.Message.bytesAsB64(this.getScript())},proto.base.SubscriberWithScriptConfig.prototype.getScript_asU8=function(){return e.Message.bytesAsU8(this.getScript())},proto.base.SubscriberWithScriptConfig.prototype.setScript=function(a){return e.Message.setProto3BytesField(this,2,a)},proto.base.SubscriberWithScriptConfig.prototype.getOnchange=function(){return e.Message.getBooleanFieldWithDefault(this,3,!1)},proto.base.SubscriberWithScriptConfig.prototype.setOnchange=function(a){return e.Message.setProto3BooleanField(this,3,a)},e.Message.GENERATE_TO_OBJECT&&(proto.base.FramesDistributionConfig.prototype.toObject=function(a){return proto.base.FramesDistributionConfig.toObject(a,this)},proto.base.FramesDistributionConfig.toObject=function(a,s){var l,u={namespace:(l=s.getNamespace())&&r.NameSpace.toObject(a,l)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.FramesDistributionConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FramesDistributionConfig;return proto.base.FramesDistributionConfig.deserializeBinaryFromReader(l,s)},proto.base.FramesDistributionConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.NameSpace;s.readMessage(u,r.NameSpace.deserializeBinaryFromReader),a.setNamespace(u);break;default:s.skipField();break}}return a},proto.base.FramesDistributionConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FramesDistributionConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FramesDistributionConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getNamespace(),l!=null&&s.writeMessage(1,l,r.NameSpace.serializeBinaryToWriter)},proto.base.FramesDistributionConfig.prototype.getNamespace=function(){return e.Message.getWrapperField(this,r.NameSpace,1)},proto.base.FramesDistributionConfig.prototype.setNamespace=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.FramesDistributionConfig.prototype.clearNamespace=function(){return this.setNamespace(void 0)},proto.base.FramesDistributionConfig.prototype.hasNamespace=function(){return e.Message.getField(this,1)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.CountByFrameId.prototype.toObject=function(a){return proto.base.CountByFrameId.toObject(a,this)},proto.base.CountByFrameId.toObject=function(a,s){var l={frameid:e.Message.getFieldWithDefault(s,1,0),count:e.Message.getFieldWithDefault(s,2,0)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.CountByFrameId.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.CountByFrameId;return proto.base.CountByFrameId.deserializeBinaryFromReader(l,s)},proto.base.CountByFrameId.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readUint32();a.setFrameid(u);break;case 2:var u=s.readUint64();a.setCount(u);break;default:s.skipField();break}}return a},proto.base.CountByFrameId.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.CountByFrameId.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.CountByFrameId.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getFrameid(),l!==0&&s.writeUint32(1,l),l=a.getCount(),l!==0&&s.writeUint64(2,l)},proto.base.CountByFrameId.prototype.getFrameid=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.base.CountByFrameId.prototype.setFrameid=function(a){return e.Message.setProto3IntField(this,1,a)},proto.base.CountByFrameId.prototype.getCount=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.base.CountByFrameId.prototype.setCount=function(a){return e.Message.setProto3IntField(this,2,a)},proto.base.FramesDistribution.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.FramesDistribution.prototype.toObject=function(a){return proto.base.FramesDistribution.toObject(a,this)},proto.base.FramesDistribution.toObject=function(a,s){var l={countsbyframeidList:e.Message.toObjectList(s.getCountsbyframeidList(),proto.base.CountByFrameId.toObject,a)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.FramesDistribution.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FramesDistribution;return proto.base.FramesDistribution.deserializeBinaryFromReader(l,s)},proto.base.FramesDistribution.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.CountByFrameId;s.readMessage(u,proto.base.CountByFrameId.deserializeBinaryFromReader),a.addCountsbyframeid(u);break;default:s.skipField();break}}return a},proto.base.FramesDistribution.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FramesDistribution.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FramesDistribution.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getCountsbyframeidList(),l.length>0&&s.writeRepeatedMessage(1,l,proto.base.CountByFrameId.serializeBinaryToWriter)},proto.base.FramesDistribution.prototype.getCountsbyframeidList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.CountByFrameId,1)},proto.base.FramesDistribution.prototype.setCountsbyframeidList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.FramesDistribution.prototype.addCountsbyframeid=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.CountByFrameId,s)},proto.base.FramesDistribution.prototype.clearCountsbyframeidList=function(){return this.setCountsbyframeidList([])},proto.base.SignalIds.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.SignalIds.prototype.toObject=function(a){return proto.base.SignalIds.toObject(a,this)},proto.base.SignalIds.toObject=function(a,s){var l={signalidList:e.Message.toObjectList(s.getSignalidList(),r.SignalId.toObject,a)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.SignalIds.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.SignalIds;return proto.base.SignalIds.deserializeBinaryFromReader(l,s)},proto.base.SignalIds.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.SignalId;s.readMessage(u,r.SignalId.deserializeBinaryFromReader),a.addSignalid(u);break;default:s.skipField();break}}return a},proto.base.SignalIds.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.SignalIds.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.SignalIds.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getSignalidList(),l.length>0&&s.writeRepeatedMessage(1,l,r.SignalId.serializeBinaryToWriter)},proto.base.SignalIds.prototype.getSignalidList=function(){return e.Message.getRepeatedWrapperField(this,r.SignalId,1)},proto.base.SignalIds.prototype.setSignalidList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.SignalIds.prototype.addSignalid=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.SignalId,s)},proto.base.SignalIds.prototype.clearSignalidList=function(){return this.setSignalidList([])},proto.base.Signals.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.Signals.prototype.toObject=function(a){return proto.base.Signals.toObject(a,this)},proto.base.Signals.toObject=function(a,s){var l={signalList:e.Message.toObjectList(s.getSignalList(),proto.base.Signal.toObject,a)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.Signals.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.Signals;return proto.base.Signals.deserializeBinaryFromReader(l,s)},proto.base.Signals.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.Signal;s.readMessage(u,proto.base.Signal.deserializeBinaryFromReader),a.addSignal(u);break;default:s.skipField();break}}return a},proto.base.Signals.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.Signals.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.Signals.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getSignalList(),l.length>0&&s.writeRepeatedMessage(1,l,proto.base.Signal.serializeBinaryToWriter)},proto.base.Signals.prototype.getSignalList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.Signal,1)},proto.base.Signals.prototype.setSignalList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.Signals.prototype.addSignal=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.Signal,s)},proto.base.Signals.prototype.clearSignalList=function(){return this.setSignalList([])},e.Message.GENERATE_TO_OBJECT&&(proto.base.PublisherConfig.prototype.toObject=function(a){return proto.base.PublisherConfig.toObject(a,this)},proto.base.PublisherConfig.toObject=function(a,s){var l,u={signals:(l=s.getSignals())&&proto.base.Signals.toObject(a,l),clientid:(l=s.getClientid())&&r.ClientId.toObject(a,l),frequency:e.Message.getFieldWithDefault(s,3,0)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.PublisherConfig.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.PublisherConfig;return proto.base.PublisherConfig.deserializeBinaryFromReader(l,s)},proto.base.PublisherConfig.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.Signals;s.readMessage(u,proto.base.Signals.deserializeBinaryFromReader),a.setSignals(u);break;case 2:var u=new r.ClientId;s.readMessage(u,r.ClientId.deserializeBinaryFromReader),a.setClientid(u);break;case 3:var u=s.readInt32();a.setFrequency(u);break;default:s.skipField();break}}return a},proto.base.PublisherConfig.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.PublisherConfig.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.PublisherConfig.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getSignals(),l!=null&&s.writeMessage(1,l,proto.base.Signals.serializeBinaryToWriter),l=a.getClientid(),l!=null&&s.writeMessage(2,l,r.ClientId.serializeBinaryToWriter),l=a.getFrequency(),l!==0&&s.writeInt32(3,l)},proto.base.PublisherConfig.prototype.getSignals=function(){return e.Message.getWrapperField(this,proto.base.Signals,1)},proto.base.PublisherConfig.prototype.setSignals=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.PublisherConfig.prototype.clearSignals=function(){return this.setSignals(void 0)},proto.base.PublisherConfig.prototype.hasSignals=function(){return e.Message.getField(this,1)!=null},proto.base.PublisherConfig.prototype.getClientid=function(){return e.Message.getWrapperField(this,r.ClientId,2)},proto.base.PublisherConfig.prototype.setClientid=function(a){return e.Message.setWrapperField(this,2,a)},proto.base.PublisherConfig.prototype.clearClientid=function(){return this.setClientid(void 0)},proto.base.PublisherConfig.prototype.hasClientid=function(){return e.Message.getField(this,2)!=null},proto.base.PublisherConfig.prototype.getFrequency=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.base.PublisherConfig.prototype.setFrequency=function(a){return e.Message.setProto3IntField(this,3,a)},proto.base.Signal.oneofGroups_=[[2,3,4,6,8]],proto.base.Signal.PayloadCase={PAYLOAD_NOT_SET:0,INTEGER:2,DOUBLE:3,ARBITRATION:4,EMPTY:6,STRVALUE:8},proto.base.Signal.prototype.getPayloadCase=function(){return e.Message.computeOneofCase(this,proto.base.Signal.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.Signal.prototype.toObject=function(a){return proto.base.Signal.toObject(a,this)},proto.base.Signal.toObject=function(a,s){var l,u={id:(l=s.getId())&&r.SignalId.toObject(a,l),integer:e.Message.getFieldWithDefault(s,2,0),pb_double:e.Message.getFloatingPointFieldWithDefault(s,3,0),arbitration:e.Message.getBooleanFieldWithDefault(s,4,!1),empty:e.Message.getBooleanFieldWithDefault(s,6,!1),strvalue:e.Message.getFieldWithDefault(s,8,""),raw:s.getRaw_asB64(),timestamp:e.Message.getFieldWithDefault(s,7,0)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.Signal.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.Signal;return proto.base.Signal.deserializeBinaryFromReader(l,s)},proto.base.Signal.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.SignalId;s.readMessage(u,r.SignalId.deserializeBinaryFromReader),a.setId(u);break;case 2:var u=s.readInt64();a.setInteger(u);break;case 3:var u=s.readDouble();a.setDouble(u);break;case 4:var u=s.readBool();a.setArbitration(u);break;case 6:var u=s.readBool();a.setEmpty(u);break;case 8:var u=s.readString();a.setStrvalue(u);break;case 5:var u=s.readBytes();a.setRaw(u);break;case 7:var u=s.readInt64();a.setTimestamp(u);break;default:s.skipField();break}}return a},proto.base.Signal.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.Signal.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.Signal.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getId(),l!=null&&s.writeMessage(1,l,r.SignalId.serializeBinaryToWriter),l=e.Message.getField(a,2),l!=null&&s.writeInt64(2,l),l=e.Message.getField(a,3),l!=null&&s.writeDouble(3,l),l=e.Message.getField(a,4),l!=null&&s.writeBool(4,l),l=e.Message.getField(a,6),l!=null&&s.writeBool(6,l),l=e.Message.getField(a,8),l!=null&&s.writeString(8,l),l=a.getRaw_asU8(),l.length>0&&s.writeBytes(5,l),l=a.getTimestamp(),l!==0&&s.writeInt64(7,l)},proto.base.Signal.prototype.getId=function(){return e.Message.getWrapperField(this,r.SignalId,1)},proto.base.Signal.prototype.setId=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.Signal.prototype.clearId=function(){return this.setId(void 0)},proto.base.Signal.prototype.hasId=function(){return e.Message.getField(this,1)!=null},proto.base.Signal.prototype.getInteger=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.base.Signal.prototype.setInteger=function(a){return e.Message.setOneofField(this,2,proto.base.Signal.oneofGroups_[0],a)},proto.base.Signal.prototype.clearInteger=function(){return e.Message.setOneofField(this,2,proto.base.Signal.oneofGroups_[0],void 0)},proto.base.Signal.prototype.hasInteger=function(){return e.Message.getField(this,2)!=null},proto.base.Signal.prototype.getDouble=function(){return e.Message.getFloatingPointFieldWithDefault(this,3,0)},proto.base.Signal.prototype.setDouble=function(a){return e.Message.setOneofField(this,3,proto.base.Signal.oneofGroups_[0],a)},proto.base.Signal.prototype.clearDouble=function(){return e.Message.setOneofField(this,3,proto.base.Signal.oneofGroups_[0],void 0)},proto.base.Signal.prototype.hasDouble=function(){return e.Message.getField(this,3)!=null},proto.base.Signal.prototype.getArbitration=function(){return e.Message.getBooleanFieldWithDefault(this,4,!1)},proto.base.Signal.prototype.setArbitration=function(a){return e.Message.setOneofField(this,4,proto.base.Signal.oneofGroups_[0],a)},proto.base.Signal.prototype.clearArbitration=function(){return e.Message.setOneofField(this,4,proto.base.Signal.oneofGroups_[0],void 0)},proto.base.Signal.prototype.hasArbitration=function(){return e.Message.getField(this,4)!=null},proto.base.Signal.prototype.getEmpty=function(){return e.Message.getBooleanFieldWithDefault(this,6,!1)},proto.base.Signal.prototype.setEmpty=function(a){return e.Message.setOneofField(this,6,proto.base.Signal.oneofGroups_[0],a)},proto.base.Signal.prototype.clearEmpty=function(){return e.Message.setOneofField(this,6,proto.base.Signal.oneofGroups_[0],void 0)},proto.base.Signal.prototype.hasEmpty=function(){return e.Message.getField(this,6)!=null},proto.base.Signal.prototype.getStrvalue=function(){return e.Message.getFieldWithDefault(this,8,"")},proto.base.Signal.prototype.setStrvalue=function(a){return e.Message.setOneofField(this,8,proto.base.Signal.oneofGroups_[0],a)},proto.base.Signal.prototype.clearStrvalue=function(){return e.Message.setOneofField(this,8,proto.base.Signal.oneofGroups_[0],void 0)},proto.base.Signal.prototype.hasStrvalue=function(){return e.Message.getField(this,8)!=null},proto.base.Signal.prototype.getRaw=function(){return e.Message.getFieldWithDefault(this,5,"")},proto.base.Signal.prototype.getRaw_asB64=function(){return e.Message.bytesAsB64(this.getRaw())},proto.base.Signal.prototype.getRaw_asU8=function(){return e.Message.bytesAsU8(this.getRaw())},proto.base.Signal.prototype.setRaw=function(a){return e.Message.setProto3BytesField(this,5,a)},proto.base.Signal.prototype.getTimestamp=function(){return e.Message.getFieldWithDefault(this,7,0)},proto.base.Signal.prototype.setTimestamp=function(a){return e.Message.setProto3IntField(this,7,a)},i.object.extend(t,proto.base)})(TY)),TY}var xY,sce;function U0t(){if(sce)return xY;sce=1;const t={};t.web=B6();var e=jS();XP();const i={};i.base=Xke(),i.base.NetworkServiceClient=function(l,u,c){c||(c={}),c.format="text",this.client_=new t.web.GrpcWebClientBase(c),this.hostname_=l},i.base.NetworkServicePromiseClient=function(l,u,c){c||(c={}),c.format="text",this.client_=new t.web.GrpcWebClientBase(c),this.hostname_=l};const n=new t.web.MethodDescriptor("/base.NetworkService/SubscribeToSignals",t.web.MethodType.SERVER_STREAMING,i.base.SubscriberConfig,i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary),i.base.NetworkServiceClient.prototype.subscribeToSignals=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToSignals",l,u||{},n)},i.base.NetworkServicePromiseClient.prototype.subscribeToSignals=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToSignals",l,u||{},n)};const r=new t.web.MethodDescriptor("/base.NetworkService/SubscribeToSignalWithScript",t.web.MethodType.SERVER_STREAMING,i.base.SubscriberWithScriptConfig,i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary),i.base.NetworkServiceClient.prototype.subscribeToSignalWithScript=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToSignalWithScript",l,u||{},r)},i.base.NetworkServicePromiseClient.prototype.subscribeToSignalWithScript=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToSignalWithScript",l,u||{},r)};const o=new t.web.MethodDescriptor("/base.NetworkService/SubscribeToFramesDistribution",t.web.MethodType.SERVER_STREAMING,i.base.FramesDistributionConfig,i.base.FramesDistribution,function(l){return l.serializeBinary()},i.base.FramesDistribution.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.FramesDistribution,function(l){return l.serializeBinary()},i.base.FramesDistribution.deserializeBinary),i.base.NetworkServiceClient.prototype.subscribeToFramesDistribution=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToFramesDistribution",l,u||{},o)},i.base.NetworkServicePromiseClient.prototype.subscribeToFramesDistribution=function(l,u){return this.client_.serverStreaming(this.hostname_+"/base.NetworkService/SubscribeToFramesDistribution",l,u||{},o)};const a=new t.web.MethodDescriptor("/base.NetworkService/PublishSignals",t.web.MethodType.UNARY,i.base.PublisherConfig,e.Empty,function(l){return l.serializeBinary()},e.Empty.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(e.Empty,function(l){return l.serializeBinary()},e.Empty.deserializeBinary),i.base.NetworkServiceClient.prototype.publishSignals=function(l,u,c){return this.client_.rpcCall(this.hostname_+"/base.NetworkService/PublishSignals",l,u||{},a,c)},i.base.NetworkServicePromiseClient.prototype.publishSignals=function(l,u){return this.client_.unaryCall(this.hostname_+"/base.NetworkService/PublishSignals",l,u||{},a)};const s=new t.web.MethodDescriptor("/base.NetworkService/ReadSignals",t.web.MethodType.UNARY,i.base.SignalIds,i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary);return new t.web.AbstractClientBase.MethodInfo(i.base.Signals,function(l){return l.serializeBinary()},i.base.Signals.deserializeBinary),i.base.NetworkServiceClient.prototype.readSignals=function(l,u,c){return this.client_.rpcCall(this.hostname_+"/base.NetworkService/ReadSignals",l,u||{},s,c)},i.base.NetworkServicePromiseClient.prototype.readSignals=function(l,u){return this.client_.unaryCall(this.hostname_+"/base.NetworkService/ReadSignals",l,u||{},s)},xY=i.base,xY}var EY={},lce;function j6(){return lce||(lce=1,(function(t){var e=qP(),i=e,n=Function("return this")(),r=jS();i.object.extend(proto,r);var o=XP();i.object.extend(proto,o),i.exportSymbol("proto.base.BatchDownloadFileChunksRequest",null,n),i.exportSymbol("proto.base.BatchDownloadFileChunksResponse",null,n),i.exportSymbol("proto.base.Configuration",null,n),i.exportSymbol("proto.base.FileDescription",null,n),i.exportSymbol("proto.base.FileDescriptions",null,n),i.exportSymbol("proto.base.FileDownloadResponse",null,n),i.exportSymbol("proto.base.FileDownloadResponse.DataCase",null,n),i.exportSymbol("proto.base.FileUploadChunkRequest",null,n),i.exportSymbol("proto.base.FileUploadRequest",null,n),i.exportSymbol("proto.base.FileUploadRequest.DataCase",null,n),i.exportSymbol("proto.base.FileUploadResponse",null,n),i.exportSymbol("proto.base.FileUploadResponse.DataCase",null,n),i.exportSymbol("proto.base.License",null,n),i.exportSymbol("proto.base.LicenseInfo",null,n),i.exportSymbol("proto.base.LicenseStatus",null,n),i.exportSymbol("proto.base.PropertyValue",null,n),i.exportSymbol("proto.base.PropertyValue.ValueCase",null,n),i.exportSymbol("proto.base.ReloadMessage",null,n),i.exportSymbol("proto.base.ReloadMessage.StatusCase",null,n),proto.base.Configuration=function(a){e.Message.initialize(this,a,0,-1,proto.base.Configuration.repeatedFields_,null)},i.inherits(proto.base.Configuration,e.Message),i.DEBUG&&!COMPILED&&(proto.base.Configuration.displayName="proto.base.Configuration"),proto.base.ReloadMessage=function(a){e.Message.initialize(this,a,0,-1,null,proto.base.ReloadMessage.oneofGroups_)},i.inherits(proto.base.ReloadMessage,e.Message),i.DEBUG&&!COMPILED&&(proto.base.ReloadMessage.displayName="proto.base.ReloadMessage"),proto.base.FileDescription=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.FileDescription,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileDescription.displayName="proto.base.FileDescription"),proto.base.FileDescriptions=function(a){e.Message.initialize(this,a,0,-1,proto.base.FileDescriptions.repeatedFields_,null)},i.inherits(proto.base.FileDescriptions,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileDescriptions.displayName="proto.base.FileDescriptions"),proto.base.FileUploadRequest=function(a){e.Message.initialize(this,a,0,-1,null,proto.base.FileUploadRequest.oneofGroups_)},i.inherits(proto.base.FileUploadRequest,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileUploadRequest.displayName="proto.base.FileUploadRequest"),proto.base.FileUploadChunkRequest=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.FileUploadChunkRequest,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileUploadChunkRequest.displayName="proto.base.FileUploadChunkRequest"),proto.base.FileUploadResponse=function(a){e.Message.initialize(this,a,0,-1,null,proto.base.FileUploadResponse.oneofGroups_)},i.inherits(proto.base.FileUploadResponse,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileUploadResponse.displayName="proto.base.FileUploadResponse"),proto.base.FileDownloadResponse=function(a){e.Message.initialize(this,a,0,-1,null,proto.base.FileDownloadResponse.oneofGroups_)},i.inherits(proto.base.FileDownloadResponse,e.Message),i.DEBUG&&!COMPILED&&(proto.base.FileDownloadResponse.displayName="proto.base.FileDownloadResponse"),proto.base.BatchDownloadFileChunksRequest=function(a){e.Message.initialize(this,a,0,-1,proto.base.BatchDownloadFileChunksRequest.repeatedFields_,null)},i.inherits(proto.base.BatchDownloadFileChunksRequest,e.Message),i.DEBUG&&!COMPILED&&(proto.base.BatchDownloadFileChunksRequest.displayName="proto.base.BatchDownloadFileChunksRequest"),proto.base.BatchDownloadFileChunksResponse=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.BatchDownloadFileChunksResponse,e.Message),i.DEBUG&&!COMPILED&&(proto.base.BatchDownloadFileChunksResponse.displayName="proto.base.BatchDownloadFileChunksResponse"),proto.base.LicenseInfo=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.LicenseInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.base.LicenseInfo.displayName="proto.base.LicenseInfo"),proto.base.License=function(a){e.Message.initialize(this,a,0,-1,null,null)},i.inherits(proto.base.License,e.Message),i.DEBUG&&!COMPILED&&(proto.base.License.displayName="proto.base.License"),proto.base.PropertyValue=function(a){e.Message.initialize(this,a,0,-1,proto.base.PropertyValue.repeatedFields_,proto.base.PropertyValue.oneofGroups_)},i.inherits(proto.base.PropertyValue,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PropertyValue.displayName="proto.base.PropertyValue"),proto.base.Configuration.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.Configuration.prototype.toObject=function(a){return proto.base.Configuration.toObject(a,this)},proto.base.Configuration.toObject=function(a,s){var l={networkinfoList:e.Message.toObjectList(s.getNetworkinfoList(),r.NetworkInfo.toObject,a),interfacesjson:s.getInterfacesjson_asB64(),publicaddress:e.Message.getFieldWithDefault(s,4,""),serverversion:e.Message.getFieldWithDefault(s,5,""),interfacesinfo:e.Message.getFieldWithDefault(s,6,"")};return a&&(l.$jspbMessageInstance=s),l}),proto.base.Configuration.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.Configuration;return proto.base.Configuration.deserializeBinaryFromReader(l,s)},proto.base.Configuration.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new r.NetworkInfo;s.readMessage(u,r.NetworkInfo.deserializeBinaryFromReader),a.addNetworkinfo(u);break;case 2:var u=s.readBytes();a.setInterfacesjson(u);break;case 4:var u=s.readString();a.setPublicaddress(u);break;case 5:var u=s.readString();a.setServerversion(u);break;case 6:var u=s.readString();a.setInterfacesinfo(u);break;default:s.skipField();break}}return a},proto.base.Configuration.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.Configuration.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.Configuration.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getNetworkinfoList(),l.length>0&&s.writeRepeatedMessage(1,l,r.NetworkInfo.serializeBinaryToWriter),l=a.getInterfacesjson_asU8(),l.length>0&&s.writeBytes(2,l),l=a.getPublicaddress(),l.length>0&&s.writeString(4,l),l=a.getServerversion(),l.length>0&&s.writeString(5,l),l=a.getInterfacesinfo(),l.length>0&&s.writeString(6,l)},proto.base.Configuration.prototype.getNetworkinfoList=function(){return e.Message.getRepeatedWrapperField(this,r.NetworkInfo,1)},proto.base.Configuration.prototype.setNetworkinfoList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.Configuration.prototype.addNetworkinfo=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.NetworkInfo,s)},proto.base.Configuration.prototype.clearNetworkinfoList=function(){return this.setNetworkinfoList([])},proto.base.Configuration.prototype.getInterfacesjson=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.Configuration.prototype.getInterfacesjson_asB64=function(){return e.Message.bytesAsB64(this.getInterfacesjson())},proto.base.Configuration.prototype.getInterfacesjson_asU8=function(){return e.Message.bytesAsU8(this.getInterfacesjson())},proto.base.Configuration.prototype.setInterfacesjson=function(a){return e.Message.setProto3BytesField(this,2,a)},proto.base.Configuration.prototype.getPublicaddress=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.Configuration.prototype.setPublicaddress=function(a){return e.Message.setProto3StringField(this,4,a)},proto.base.Configuration.prototype.getServerversion=function(){return e.Message.getFieldWithDefault(this,5,"")},proto.base.Configuration.prototype.setServerversion=function(a){return e.Message.setProto3StringField(this,5,a)},proto.base.Configuration.prototype.getInterfacesinfo=function(){return e.Message.getFieldWithDefault(this,6,"")},proto.base.Configuration.prototype.setInterfacesinfo=function(a){return e.Message.setProto3StringField(this,6,a)},proto.base.ReloadMessage.oneofGroups_=[[1,2]],proto.base.ReloadMessage.StatusCase={STATUS_NOT_SET:0,CONFIGURATION:1,ERRORMESSAGE:2},proto.base.ReloadMessage.prototype.getStatusCase=function(){return e.Message.computeOneofCase(this,proto.base.ReloadMessage.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.ReloadMessage.prototype.toObject=function(a){return proto.base.ReloadMessage.toObject(a,this)},proto.base.ReloadMessage.toObject=function(a,s){var l,u={configuration:(l=s.getConfiguration())&&proto.base.Configuration.toObject(a,l),errormessage:e.Message.getFieldWithDefault(s,2,"")};return a&&(u.$jspbMessageInstance=s),u}),proto.base.ReloadMessage.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.ReloadMessage;return proto.base.ReloadMessage.deserializeBinaryFromReader(l,s)},proto.base.ReloadMessage.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.Configuration;s.readMessage(u,proto.base.Configuration.deserializeBinaryFromReader),a.setConfiguration(u);break;case 2:var u=s.readString();a.setErrormessage(u);break;default:s.skipField();break}}return a},proto.base.ReloadMessage.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.ReloadMessage.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.ReloadMessage.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getConfiguration(),l!=null&&s.writeMessage(1,l,proto.base.Configuration.serializeBinaryToWriter),l=e.Message.getField(a,2),l!=null&&s.writeString(2,l)},proto.base.ReloadMessage.prototype.getConfiguration=function(){return e.Message.getWrapperField(this,proto.base.Configuration,1)},proto.base.ReloadMessage.prototype.setConfiguration=function(a){return e.Message.setOneofWrapperField(this,1,proto.base.ReloadMessage.oneofGroups_[0],a)},proto.base.ReloadMessage.prototype.clearConfiguration=function(){return this.setConfiguration(void 0)},proto.base.ReloadMessage.prototype.hasConfiguration=function(){return e.Message.getField(this,1)!=null},proto.base.ReloadMessage.prototype.getErrormessage=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.ReloadMessage.prototype.setErrormessage=function(a){return e.Message.setOneofField(this,2,proto.base.ReloadMessage.oneofGroups_[0],a)},proto.base.ReloadMessage.prototype.clearErrormessage=function(){return e.Message.setOneofField(this,2,proto.base.ReloadMessage.oneofGroups_[0],void 0)},proto.base.ReloadMessage.prototype.hasErrormessage=function(){return e.Message.getField(this,2)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.FileDescription.prototype.toObject=function(a){return proto.base.FileDescription.toObject(a,this)},proto.base.FileDescription.toObject=function(a,s){var l={sha256:e.Message.getFieldWithDefault(s,1,""),path:e.Message.getFieldWithDefault(s,2,"")};return a&&(l.$jspbMessageInstance=s),l}),proto.base.FileDescription.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileDescription;return proto.base.FileDescription.deserializeBinaryFromReader(l,s)},proto.base.FileDescription.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readString();a.setSha256(u);break;case 2:var u=s.readString();a.setPath(u);break;default:s.skipField();break}}return a},proto.base.FileDescription.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileDescription.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileDescription.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getSha256(),l.length>0&&s.writeString(1,l),l=a.getPath(),l.length>0&&s.writeString(2,l)},proto.base.FileDescription.prototype.getSha256=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.FileDescription.prototype.setSha256=function(a){return e.Message.setProto3StringField(this,1,a)},proto.base.FileDescription.prototype.getPath=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.FileDescription.prototype.setPath=function(a){return e.Message.setProto3StringField(this,2,a)},proto.base.FileDescriptions.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.FileDescriptions.prototype.toObject=function(a){return proto.base.FileDescriptions.toObject(a,this)},proto.base.FileDescriptions.toObject=function(a,s){var l={filedescriptionsList:e.Message.toObjectList(s.getFiledescriptionsList(),proto.base.FileDescription.toObject,a)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.FileDescriptions.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileDescriptions;return proto.base.FileDescriptions.deserializeBinaryFromReader(l,s)},proto.base.FileDescriptions.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.FileDescription;s.readMessage(u,proto.base.FileDescription.deserializeBinaryFromReader),a.addFiledescriptions(u);break;default:s.skipField();break}}return a},proto.base.FileDescriptions.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileDescriptions.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileDescriptions.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getFiledescriptionsList(),l.length>0&&s.writeRepeatedMessage(1,l,proto.base.FileDescription.serializeBinaryToWriter)},proto.base.FileDescriptions.prototype.getFiledescriptionsList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.FileDescription,1)},proto.base.FileDescriptions.prototype.setFiledescriptionsList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.FileDescriptions.prototype.addFiledescriptions=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.FileDescription,s)},proto.base.FileDescriptions.prototype.clearFiledescriptionsList=function(){return this.setFiledescriptionsList([])},proto.base.FileUploadRequest.oneofGroups_=[[1,2]],proto.base.FileUploadRequest.DataCase={DATA_NOT_SET:0,FILEDESCRIPTION:1,CHUNK:2},proto.base.FileUploadRequest.prototype.getDataCase=function(){return e.Message.computeOneofCase(this,proto.base.FileUploadRequest.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.FileUploadRequest.prototype.toObject=function(a){return proto.base.FileUploadRequest.toObject(a,this)},proto.base.FileUploadRequest.toObject=function(a,s){var l,u={filedescription:(l=s.getFiledescription())&&proto.base.FileDescription.toObject(a,l),chunk:s.getChunk_asB64()};return a&&(u.$jspbMessageInstance=s),u}),proto.base.FileUploadRequest.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileUploadRequest;return proto.base.FileUploadRequest.deserializeBinaryFromReader(l,s)},proto.base.FileUploadRequest.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.FileDescription;s.readMessage(u,proto.base.FileDescription.deserializeBinaryFromReader),a.setFiledescription(u);break;case 2:var u=s.readBytes();a.setChunk(u);break;default:s.skipField();break}}return a},proto.base.FileUploadRequest.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileUploadRequest.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileUploadRequest.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getFiledescription(),l!=null&&s.writeMessage(1,l,proto.base.FileDescription.serializeBinaryToWriter),l=e.Message.getField(a,2),l!=null&&s.writeBytes(2,l)},proto.base.FileUploadRequest.prototype.getFiledescription=function(){return e.Message.getWrapperField(this,proto.base.FileDescription,1)},proto.base.FileUploadRequest.prototype.setFiledescription=function(a){return e.Message.setOneofWrapperField(this,1,proto.base.FileUploadRequest.oneofGroups_[0],a)},proto.base.FileUploadRequest.prototype.clearFiledescription=function(){return this.setFiledescription(void 0)},proto.base.FileUploadRequest.prototype.hasFiledescription=function(){return e.Message.getField(this,1)!=null},proto.base.FileUploadRequest.prototype.getChunk=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.FileUploadRequest.prototype.getChunk_asB64=function(){return e.Message.bytesAsB64(this.getChunk())},proto.base.FileUploadRequest.prototype.getChunk_asU8=function(){return e.Message.bytesAsU8(this.getChunk())},proto.base.FileUploadRequest.prototype.setChunk=function(a){return e.Message.setOneofField(this,2,proto.base.FileUploadRequest.oneofGroups_[0],a)},proto.base.FileUploadRequest.prototype.clearChunk=function(){return e.Message.setOneofField(this,2,proto.base.FileUploadRequest.oneofGroups_[0],void 0)},proto.base.FileUploadRequest.prototype.hasChunk=function(){return e.Message.getField(this,2)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.FileUploadChunkRequest.prototype.toObject=function(a){return proto.base.FileUploadChunkRequest.toObject(a,this)},proto.base.FileUploadChunkRequest.toObject=function(a,s){var l,u={filedescription:(l=s.getFiledescription())&&proto.base.FileDescription.toObject(a,l),chunks:e.Message.getFieldWithDefault(s,2,0),chunkid:e.Message.getFieldWithDefault(s,3,0),chunk:s.getChunk_asB64(),cancelupload:e.Message.getBooleanFieldWithDefault(s,5,!1),uploadtimeout:e.Message.getFieldWithDefault(s,6,0)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.FileUploadChunkRequest.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileUploadChunkRequest;return proto.base.FileUploadChunkRequest.deserializeBinaryFromReader(l,s)},proto.base.FileUploadChunkRequest.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.FileDescription;s.readMessage(u,proto.base.FileDescription.deserializeBinaryFromReader),a.setFiledescription(u);break;case 2:var u=s.readUint32();a.setChunks(u);break;case 3:var u=s.readUint32();a.setChunkid(u);break;case 4:var u=s.readBytes();a.setChunk(u);break;case 5:var u=s.readBool();a.setCancelupload(u);break;case 6:var u=s.readUint32();a.setUploadtimeout(u);break;default:s.skipField();break}}return a},proto.base.FileUploadChunkRequest.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileUploadChunkRequest.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileUploadChunkRequest.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getFiledescription(),l!=null&&s.writeMessage(1,l,proto.base.FileDescription.serializeBinaryToWriter),l=a.getChunks(),l!==0&&s.writeUint32(2,l),l=a.getChunkid(),l!==0&&s.writeUint32(3,l),l=a.getChunk_asU8(),l.length>0&&s.writeBytes(4,l),l=a.getCancelupload(),l&&s.writeBool(5,l),l=a.getUploadtimeout(),l!==0&&s.writeUint32(6,l)},proto.base.FileUploadChunkRequest.prototype.getFiledescription=function(){return e.Message.getWrapperField(this,proto.base.FileDescription,1)},proto.base.FileUploadChunkRequest.prototype.setFiledescription=function(a){return e.Message.setWrapperField(this,1,a)},proto.base.FileUploadChunkRequest.prototype.clearFiledescription=function(){return this.setFiledescription(void 0)},proto.base.FileUploadChunkRequest.prototype.hasFiledescription=function(){return e.Message.getField(this,1)!=null},proto.base.FileUploadChunkRequest.prototype.getChunks=function(){return e.Message.getFieldWithDefault(this,2,0)},proto.base.FileUploadChunkRequest.prototype.setChunks=function(a){return e.Message.setProto3IntField(this,2,a)},proto.base.FileUploadChunkRequest.prototype.getChunkid=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.base.FileUploadChunkRequest.prototype.setChunkid=function(a){return e.Message.setProto3IntField(this,3,a)},proto.base.FileUploadChunkRequest.prototype.getChunk=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.FileUploadChunkRequest.prototype.getChunk_asB64=function(){return e.Message.bytesAsB64(this.getChunk())},proto.base.FileUploadChunkRequest.prototype.getChunk_asU8=function(){return e.Message.bytesAsU8(this.getChunk())},proto.base.FileUploadChunkRequest.prototype.setChunk=function(a){return e.Message.setProto3BytesField(this,4,a)},proto.base.FileUploadChunkRequest.prototype.getCancelupload=function(){return e.Message.getBooleanFieldWithDefault(this,5,!1)},proto.base.FileUploadChunkRequest.prototype.setCancelupload=function(a){return e.Message.setProto3BooleanField(this,5,a)},proto.base.FileUploadChunkRequest.prototype.getUploadtimeout=function(){return e.Message.getFieldWithDefault(this,6,0)},proto.base.FileUploadChunkRequest.prototype.setUploadtimeout=function(a){return e.Message.setProto3IntField(this,6,a)},proto.base.FileUploadResponse.oneofGroups_=[[1,2,3]],proto.base.FileUploadResponse.DataCase={DATA_NOT_SET:0,FINISHED:1,CANCELLED:2,ERRORMESSAGE:3},proto.base.FileUploadResponse.prototype.getDataCase=function(){return e.Message.computeOneofCase(this,proto.base.FileUploadResponse.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.FileUploadResponse.prototype.toObject=function(a){return proto.base.FileUploadResponse.toObject(a,this)},proto.base.FileUploadResponse.toObject=function(a,s){var l={finished:e.Message.getBooleanFieldWithDefault(s,1,!1),cancelled:e.Message.getBooleanFieldWithDefault(s,2,!1),errormessage:e.Message.getFieldWithDefault(s,3,"")};return a&&(l.$jspbMessageInstance=s),l}),proto.base.FileUploadResponse.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileUploadResponse;return proto.base.FileUploadResponse.deserializeBinaryFromReader(l,s)},proto.base.FileUploadResponse.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readBool();a.setFinished(u);break;case 2:var u=s.readBool();a.setCancelled(u);break;case 3:var u=s.readString();a.setErrormessage(u);break;default:s.skipField();break}}return a},proto.base.FileUploadResponse.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileUploadResponse.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileUploadResponse.serializeBinaryToWriter=function(a,s){var l=void 0;l=e.Message.getField(a,1),l!=null&&s.writeBool(1,l),l=e.Message.getField(a,2),l!=null&&s.writeBool(2,l),l=e.Message.getField(a,3),l!=null&&s.writeString(3,l)},proto.base.FileUploadResponse.prototype.getFinished=function(){return e.Message.getBooleanFieldWithDefault(this,1,!1)},proto.base.FileUploadResponse.prototype.setFinished=function(a){return e.Message.setOneofField(this,1,proto.base.FileUploadResponse.oneofGroups_[0],a)},proto.base.FileUploadResponse.prototype.clearFinished=function(){return e.Message.setOneofField(this,1,proto.base.FileUploadResponse.oneofGroups_[0],void 0)},proto.base.FileUploadResponse.prototype.hasFinished=function(){return e.Message.getField(this,1)!=null},proto.base.FileUploadResponse.prototype.getCancelled=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.base.FileUploadResponse.prototype.setCancelled=function(a){return e.Message.setOneofField(this,2,proto.base.FileUploadResponse.oneofGroups_[0],a)},proto.base.FileUploadResponse.prototype.clearCancelled=function(){return e.Message.setOneofField(this,2,proto.base.FileUploadResponse.oneofGroups_[0],void 0)},proto.base.FileUploadResponse.prototype.hasCancelled=function(){return e.Message.getField(this,2)!=null},proto.base.FileUploadResponse.prototype.getErrormessage=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.FileUploadResponse.prototype.setErrormessage=function(a){return e.Message.setOneofField(this,3,proto.base.FileUploadResponse.oneofGroups_[0],a)},proto.base.FileUploadResponse.prototype.clearErrormessage=function(){return e.Message.setOneofField(this,3,proto.base.FileUploadResponse.oneofGroups_[0],void 0)},proto.base.FileUploadResponse.prototype.hasErrormessage=function(){return e.Message.getField(this,3)!=null},proto.base.FileDownloadResponse.oneofGroups_=[[1,2]],proto.base.FileDownloadResponse.DataCase={DATA_NOT_SET:0,CHUNK:1,ERRORMESSAGE:2},proto.base.FileDownloadResponse.prototype.getDataCase=function(){return e.Message.computeOneofCase(this,proto.base.FileDownloadResponse.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.FileDownloadResponse.prototype.toObject=function(a){return proto.base.FileDownloadResponse.toObject(a,this)},proto.base.FileDownloadResponse.toObject=function(a,s){var l={chunk:s.getChunk_asB64(),errormessage:e.Message.getFieldWithDefault(s,2,"")};return a&&(l.$jspbMessageInstance=s),l}),proto.base.FileDownloadResponse.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.FileDownloadResponse;return proto.base.FileDownloadResponse.deserializeBinaryFromReader(l,s)},proto.base.FileDownloadResponse.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readBytes();a.setChunk(u);break;case 2:var u=s.readString();a.setErrormessage(u);break;default:s.skipField();break}}return a},proto.base.FileDownloadResponse.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.FileDownloadResponse.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.FileDownloadResponse.serializeBinaryToWriter=function(a,s){var l=void 0;l=e.Message.getField(a,1),l!=null&&s.writeBytes(1,l),l=e.Message.getField(a,2),l!=null&&s.writeString(2,l)},proto.base.FileDownloadResponse.prototype.getChunk=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.FileDownloadResponse.prototype.getChunk_asB64=function(){return e.Message.bytesAsB64(this.getChunk())},proto.base.FileDownloadResponse.prototype.getChunk_asU8=function(){return e.Message.bytesAsU8(this.getChunk())},proto.base.FileDownloadResponse.prototype.setChunk=function(a){return e.Message.setOneofField(this,1,proto.base.FileDownloadResponse.oneofGroups_[0],a)},proto.base.FileDownloadResponse.prototype.clearChunk=function(){return e.Message.setOneofField(this,1,proto.base.FileDownloadResponse.oneofGroups_[0],void 0)},proto.base.FileDownloadResponse.prototype.hasChunk=function(){return e.Message.getField(this,1)!=null},proto.base.FileDownloadResponse.prototype.getErrormessage=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.FileDownloadResponse.prototype.setErrormessage=function(a){return e.Message.setOneofField(this,2,proto.base.FileDownloadResponse.oneofGroups_[0],a)},proto.base.FileDownloadResponse.prototype.clearErrormessage=function(){return e.Message.setOneofField(this,2,proto.base.FileDownloadResponse.oneofGroups_[0],void 0)},proto.base.FileDownloadResponse.prototype.hasErrormessage=function(){return e.Message.getField(this,2)!=null},proto.base.BatchDownloadFileChunksRequest.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.BatchDownloadFileChunksRequest.prototype.toObject=function(a){return proto.base.BatchDownloadFileChunksRequest.toObject(a,this)},proto.base.BatchDownloadFileChunksRequest.toObject=function(a,s){var l={filedescriptionsList:e.Message.toObjectList(s.getFiledescriptionsList(),proto.base.FileDescription.toObject,a),timeout:e.Message.getFieldWithDefault(s,6,0)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.BatchDownloadFileChunksRequest.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.BatchDownloadFileChunksRequest;return proto.base.BatchDownloadFileChunksRequest.deserializeBinaryFromReader(l,s)},proto.base.BatchDownloadFileChunksRequest.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=new proto.base.FileDescription;s.readMessage(u,proto.base.FileDescription.deserializeBinaryFromReader),a.addFiledescriptions(u);break;case 6:var u=s.readUint32();a.setTimeout(u);break;default:s.skipField();break}}return a},proto.base.BatchDownloadFileChunksRequest.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.BatchDownloadFileChunksRequest.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.BatchDownloadFileChunksRequest.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getFiledescriptionsList(),l.length>0&&s.writeRepeatedMessage(1,l,proto.base.FileDescription.serializeBinaryToWriter),l=a.getTimeout(),l!==0&&s.writeUint32(6,l)},proto.base.BatchDownloadFileChunksRequest.prototype.getFiledescriptionsList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.FileDescription,1)},proto.base.BatchDownloadFileChunksRequest.prototype.setFiledescriptionsList=function(a){return e.Message.setRepeatedWrapperField(this,1,a)},proto.base.BatchDownloadFileChunksRequest.prototype.addFiledescriptions=function(a,s){return e.Message.addToRepeatedWrapperField(this,1,a,proto.base.FileDescription,s)},proto.base.BatchDownloadFileChunksRequest.prototype.clearFiledescriptionsList=function(){return this.setFiledescriptionsList([])},proto.base.BatchDownloadFileChunksRequest.prototype.getTimeout=function(){return e.Message.getFieldWithDefault(this,6,0)},proto.base.BatchDownloadFileChunksRequest.prototype.setTimeout=function(a){return e.Message.setProto3IntField(this,6,a)},e.Message.GENERATE_TO_OBJECT&&(proto.base.BatchDownloadFileChunksResponse.prototype.toObject=function(a){return proto.base.BatchDownloadFileChunksResponse.toObject(a,this)},proto.base.BatchDownloadFileChunksResponse.toObject=function(a,s){var l={lastchunk:e.Message.getBooleanFieldWithDefault(s,2,!1),chunkid:e.Message.getFieldWithDefault(s,3,0),chunk:s.getChunk_asB64(),estimatedtotalsize:e.Message.getFieldWithDefault(s,5,0)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.BatchDownloadFileChunksResponse.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.BatchDownloadFileChunksResponse;return proto.base.BatchDownloadFileChunksResponse.deserializeBinaryFromReader(l,s)},proto.base.BatchDownloadFileChunksResponse.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 2:var u=s.readBool();a.setLastchunk(u);break;case 3:var u=s.readUint32();a.setChunkid(u);break;case 4:var u=s.readBytes();a.setChunk(u);break;case 5:var u=s.readUint32();a.setEstimatedtotalsize(u);break;default:s.skipField();break}}return a},proto.base.BatchDownloadFileChunksResponse.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.BatchDownloadFileChunksResponse.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.BatchDownloadFileChunksResponse.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getLastchunk(),l&&s.writeBool(2,l),l=a.getChunkid(),l!==0&&s.writeUint32(3,l),l=a.getChunk_asU8(),l.length>0&&s.writeBytes(4,l),l=a.getEstimatedtotalsize(),l!==0&&s.writeUint32(5,l)},proto.base.BatchDownloadFileChunksResponse.prototype.getLastchunk=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.base.BatchDownloadFileChunksResponse.prototype.setLastchunk=function(a){return e.Message.setProto3BooleanField(this,2,a)},proto.base.BatchDownloadFileChunksResponse.prototype.getChunkid=function(){return e.Message.getFieldWithDefault(this,3,0)},proto.base.BatchDownloadFileChunksResponse.prototype.setChunkid=function(a){return e.Message.setProto3IntField(this,3,a)},proto.base.BatchDownloadFileChunksResponse.prototype.getChunk=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.BatchDownloadFileChunksResponse.prototype.getChunk_asB64=function(){return e.Message.bytesAsB64(this.getChunk())},proto.base.BatchDownloadFileChunksResponse.prototype.getChunk_asU8=function(){return e.Message.bytesAsU8(this.getChunk())},proto.base.BatchDownloadFileChunksResponse.prototype.setChunk=function(a){return e.Message.setProto3BytesField(this,4,a)},proto.base.BatchDownloadFileChunksResponse.prototype.getEstimatedtotalsize=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.base.BatchDownloadFileChunksResponse.prototype.setEstimatedtotalsize=function(a){return e.Message.setProto3IntField(this,5,a)},e.Message.GENERATE_TO_OBJECT&&(proto.base.LicenseInfo.prototype.toObject=function(a){return proto.base.LicenseInfo.toObject(a,this)},proto.base.LicenseInfo.toObject=function(a,s){var l={status:e.Message.getFieldWithDefault(s,1,0),json:s.getJson_asB64(),expires:e.Message.getFieldWithDefault(s,3,""),requestid:e.Message.getFieldWithDefault(s,4,""),requestmachineid:s.getRequestmachineid_asB64()};return a&&(l.$jspbMessageInstance=s),l}),proto.base.LicenseInfo.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.LicenseInfo;return proto.base.LicenseInfo.deserializeBinaryFromReader(l,s)},proto.base.LicenseInfo.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readEnum();a.setStatus(u);break;case 2:var u=s.readBytes();a.setJson(u);break;case 3:var u=s.readString();a.setExpires(u);break;case 4:var u=s.readString();a.setRequestid(u);break;case 5:var u=s.readBytes();a.setRequestmachineid(u);break;default:s.skipField();break}}return a},proto.base.LicenseInfo.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.LicenseInfo.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.LicenseInfo.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getStatus(),l!==0&&s.writeEnum(1,l),l=a.getJson_asU8(),l.length>0&&s.writeBytes(2,l),l=a.getExpires(),l.length>0&&s.writeString(3,l),l=a.getRequestid(),l.length>0&&s.writeString(4,l),l=a.getRequestmachineid_asU8(),l.length>0&&s.writeBytes(5,l)},proto.base.LicenseInfo.prototype.getStatus=function(){return e.Message.getFieldWithDefault(this,1,0)},proto.base.LicenseInfo.prototype.setStatus=function(a){return e.Message.setProto3EnumField(this,1,a)},proto.base.LicenseInfo.prototype.getJson=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.LicenseInfo.prototype.getJson_asB64=function(){return e.Message.bytesAsB64(this.getJson())},proto.base.LicenseInfo.prototype.getJson_asU8=function(){return e.Message.bytesAsU8(this.getJson())},proto.base.LicenseInfo.prototype.setJson=function(a){return e.Message.setProto3BytesField(this,2,a)},proto.base.LicenseInfo.prototype.getExpires=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.LicenseInfo.prototype.setExpires=function(a){return e.Message.setProto3StringField(this,3,a)},proto.base.LicenseInfo.prototype.getRequestid=function(){return e.Message.getFieldWithDefault(this,4,"")},proto.base.LicenseInfo.prototype.setRequestid=function(a){return e.Message.setProto3StringField(this,4,a)},proto.base.LicenseInfo.prototype.getRequestmachineid=function(){return e.Message.getFieldWithDefault(this,5,"")},proto.base.LicenseInfo.prototype.getRequestmachineid_asB64=function(){return e.Message.bytesAsB64(this.getRequestmachineid())},proto.base.LicenseInfo.prototype.getRequestmachineid_asU8=function(){return e.Message.bytesAsU8(this.getRequestmachineid())},proto.base.LicenseInfo.prototype.setRequestmachineid=function(a){return e.Message.setProto3BytesField(this,5,a)},e.Message.GENERATE_TO_OBJECT&&(proto.base.License.prototype.toObject=function(a){return proto.base.License.toObject(a,this)},proto.base.License.toObject=function(a,s){var l={data:s.getData_asB64(),termsagreement:e.Message.getBooleanFieldWithDefault(s,2,!1)};return a&&(l.$jspbMessageInstance=s),l}),proto.base.License.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.License;return proto.base.License.deserializeBinaryFromReader(l,s)},proto.base.License.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readBytes();a.setData(u);break;case 2:var u=s.readBool();a.setTermsagreement(u);break;default:s.skipField();break}}return a},proto.base.License.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.License.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.License.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getData_asU8(),l.length>0&&s.writeBytes(1,l),l=a.getTermsagreement(),l&&s.writeBool(2,l)},proto.base.License.prototype.getData=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.License.prototype.getData_asB64=function(){return e.Message.bytesAsB64(this.getData())},proto.base.License.prototype.getData_asU8=function(){return e.Message.bytesAsU8(this.getData())},proto.base.License.prototype.setData=function(a){return e.Message.setProto3BytesField(this,1,a)},proto.base.License.prototype.getTermsagreement=function(){return e.Message.getBooleanFieldWithDefault(this,2,!1)},proto.base.License.prototype.setTermsagreement=function(a){return e.Message.setProto3BooleanField(this,2,a)},proto.base.PropertyValue.repeatedFields_=[2],proto.base.PropertyValue.oneofGroups_=[[3,4,5]],proto.base.PropertyValue.ValueCase={VALUE_NOT_SET:0,RAW:3,INTEGER:4,DOUBLE:5},proto.base.PropertyValue.prototype.getValueCase=function(){return e.Message.computeOneofCase(this,proto.base.PropertyValue.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.PropertyValue.prototype.toObject=function(a){return proto.base.PropertyValue.toObject(a,this)},proto.base.PropertyValue.toObject=function(a,s){var l,u={name:e.Message.getFieldWithDefault(s,1,""),scopeList:(l=e.Message.getRepeatedField(s,2))==null?void 0:l,raw:s.getRaw_asB64(),integer:e.Message.getFieldWithDefault(s,4,0),pb_double:e.Message.getFloatingPointFieldWithDefault(s,5,0)};return a&&(u.$jspbMessageInstance=s),u}),proto.base.PropertyValue.deserializeBinary=function(a){var s=new e.BinaryReader(a),l=new proto.base.PropertyValue;return proto.base.PropertyValue.deserializeBinaryFromReader(l,s)},proto.base.PropertyValue.deserializeBinaryFromReader=function(a,s){for(;s.nextField()&&!s.isEndGroup();){var l=s.getFieldNumber();switch(l){case 1:var u=s.readString();a.setName(u);break;case 2:var u=s.readString();a.addScope(u);break;case 3:var u=s.readBytes();a.setRaw(u);break;case 4:var u=s.readInt64();a.setInteger(u);break;case 5:var u=s.readDouble();a.setDouble(u);break;default:s.skipField();break}}return a},proto.base.PropertyValue.prototype.serializeBinary=function(){var a=new e.BinaryWriter;return proto.base.PropertyValue.serializeBinaryToWriter(this,a),a.getResultBuffer()},proto.base.PropertyValue.serializeBinaryToWriter=function(a,s){var l=void 0;l=a.getName(),l.length>0&&s.writeString(1,l),l=a.getScopeList(),l.length>0&&s.writeRepeatedString(2,l),l=e.Message.getField(a,3),l!=null&&s.writeBytes(3,l),l=e.Message.getField(a,4),l!=null&&s.writeInt64(4,l),l=e.Message.getField(a,5),l!=null&&s.writeDouble(5,l)},proto.base.PropertyValue.prototype.getName=function(){return e.Message.getFieldWithDefault(this,1,"")},proto.base.PropertyValue.prototype.setName=function(a){return e.Message.setProto3StringField(this,1,a)},proto.base.PropertyValue.prototype.getScopeList=function(){return e.Message.getRepeatedField(this,2)},proto.base.PropertyValue.prototype.setScopeList=function(a){return e.Message.setField(this,2,a||[])},proto.base.PropertyValue.prototype.addScope=function(a,s){return e.Message.addToRepeatedField(this,2,a,s)},proto.base.PropertyValue.prototype.clearScopeList=function(){return this.setScopeList([])},proto.base.PropertyValue.prototype.getRaw=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.PropertyValue.prototype.getRaw_asB64=function(){return e.Message.bytesAsB64(this.getRaw())},proto.base.PropertyValue.prototype.getRaw_asU8=function(){return e.Message.bytesAsU8(this.getRaw())},proto.base.PropertyValue.prototype.setRaw=function(a){return e.Message.setOneofField(this,3,proto.base.PropertyValue.oneofGroups_[0],a)},proto.base.PropertyValue.prototype.clearRaw=function(){return e.Message.setOneofField(this,3,proto.base.PropertyValue.oneofGroups_[0],void 0)},proto.base.PropertyValue.prototype.hasRaw=function(){return e.Message.getField(this,3)!=null},proto.base.PropertyValue.prototype.getInteger=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.base.PropertyValue.prototype.setInteger=function(a){return e.Message.setOneofField(this,4,proto.base.PropertyValue.oneofGroups_[0],a)},proto.base.PropertyValue.prototype.clearInteger=function(){return e.Message.setOneofField(this,4,proto.base.PropertyValue.oneofGroups_[0],void 0)},proto.base.PropertyValue.prototype.hasInteger=function(){return e.Message.getField(this,4)!=null},proto.base.PropertyValue.prototype.getDouble=function(){return e.Message.getFloatingPointFieldWithDefault(this,5,0)},proto.base.PropertyValue.prototype.setDouble=function(a){return e.Message.setOneofField(this,5,proto.base.PropertyValue.oneofGroups_[0],a)},proto.base.PropertyValue.prototype.clearDouble=function(){return e.Message.setOneofField(this,5,proto.base.PropertyValue.oneofGroups_[0],void 0)},proto.base.PropertyValue.prototype.hasDouble=function(){return e.Message.getField(this,5)!=null},proto.base.LicenseStatus={UNSET:0,VALID:1,EXPIRED:2,BADDATE:3,WRONGMACHINE:4,INCOMPLETEJSON:5,INVALIDJSON:6,BADSIGNATURE:7,MALFORMED:8,SERVERERROR:9,NOTERMSAGREEMENT:10},i.object.extend(t,proto.base)})(EY)),EY}var wY,uce;function z0t(){if(uce)return wY;uce=1;const t={};t.web=B6();var e=jS();XP();const i={};i.base=j6(),i.base.SystemServiceClient=function(p,g,v){v||(v={}),v.format="text",this.client_=new t.web.GrpcWebClientBase(v),this.hostname_=p},i.base.SystemServicePromiseClient=function(p,g,v){v||(v={}),v.format="text",this.client_=new t.web.GrpcWebClientBase(v),this.hostname_=p};const n=new t.web.MethodDescriptor("/base.SystemService/GetConfiguration",t.web.MethodType.UNARY,e.Empty,i.base.Configuration,function(p){return p.serializeBinary()},i.base.Configuration.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.Configuration,function(p){return p.serializeBinary()},i.base.Configuration.deserializeBinary),i.base.SystemServiceClient.prototype.getConfiguration=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/GetConfiguration",p,g||{},n,v)},i.base.SystemServicePromiseClient.prototype.getConfiguration=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/GetConfiguration",p,g||{},n)};const r=new t.web.MethodDescriptor("/base.SystemService/ListSignals",t.web.MethodType.UNARY,e.NameSpace,e.Frames,function(p){return p.serializeBinary()},e.Frames.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(e.Frames,function(p){return p.serializeBinary()},e.Frames.deserializeBinary),i.base.SystemServiceClient.prototype.listSignals=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/ListSignals",p,g||{},r,v)},i.base.SystemServicePromiseClient.prototype.listSignals=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/ListSignals",p,g||{},r)};const o=new t.web.MethodDescriptor("/base.SystemService/HealthCheck",t.web.MethodType.UNARY,e.Empty,e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary),i.base.SystemServiceClient.prototype.healthCheck=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/HealthCheck",p,g||{},o,v)},i.base.SystemServicePromiseClient.prototype.healthCheck=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/HealthCheck",p,g||{},o)};const a=new t.web.MethodDescriptor("/base.SystemService/UploadFileChunk",t.web.MethodType.UNARY,i.base.FileUploadChunkRequest,i.base.FileUploadResponse,function(p){return p.serializeBinary()},i.base.FileUploadResponse.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.FileUploadResponse,function(p){return p.serializeBinary()},i.base.FileUploadResponse.deserializeBinary),i.base.SystemServiceClient.prototype.uploadFileChunk=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/UploadFileChunk",p,g||{},a,v)},i.base.SystemServicePromiseClient.prototype.uploadFileChunk=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/UploadFileChunk",p,g||{},a)};const s=new t.web.MethodDescriptor("/base.SystemService/BatchDeleteFiles",t.web.MethodType.UNARY,i.base.FileDescriptions,e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary),i.base.SystemServiceClient.prototype.batchDeleteFiles=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/BatchDeleteFiles",p,g||{},s,v)},i.base.SystemServicePromiseClient.prototype.batchDeleteFiles=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/BatchDeleteFiles",p,g||{},s)};const l=new t.web.MethodDescriptor("/base.SystemService/BatchDownloadFiles",t.web.MethodType.SERVER_STREAMING,i.base.FileDescriptions,i.base.FileDownloadResponse,function(p){return p.serializeBinary()},i.base.FileDownloadResponse.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.FileDownloadResponse,function(p){return p.serializeBinary()},i.base.FileDownloadResponse.deserializeBinary),i.base.SystemServiceClient.prototype.batchDownloadFiles=function(p,g){return this.client_.serverStreaming(this.hostname_+"/base.SystemService/BatchDownloadFiles",p,g||{},l)},i.base.SystemServicePromiseClient.prototype.batchDownloadFiles=function(p,g){return this.client_.serverStreaming(this.hostname_+"/base.SystemService/BatchDownloadFiles",p,g||{},l)};const u=new t.web.MethodDescriptor("/base.SystemService/BatchDownloadFileChunks",t.web.MethodType.UNARY,i.base.BatchDownloadFileChunksRequest,i.base.BatchDownloadFileChunksResponse,function(p){return p.serializeBinary()},i.base.BatchDownloadFileChunksResponse.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.BatchDownloadFileChunksResponse,function(p){return p.serializeBinary()},i.base.BatchDownloadFileChunksResponse.deserializeBinary),i.base.SystemServiceClient.prototype.batchDownloadFileChunks=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/BatchDownloadFileChunks",p,g||{},u,v)},i.base.SystemServicePromiseClient.prototype.batchDownloadFileChunks=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/BatchDownloadFileChunks",p,g||{},u)};const c=new t.web.MethodDescriptor("/base.SystemService/ReloadConfiguration",t.web.MethodType.UNARY,e.Empty,i.base.ReloadMessage,function(p){return p.serializeBinary()},i.base.ReloadMessage.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.ReloadMessage,function(p){return p.serializeBinary()},i.base.ReloadMessage.deserializeBinary),i.base.SystemServiceClient.prototype.reloadConfiguration=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/ReloadConfiguration",p,g||{},c,v)},i.base.SystemServicePromiseClient.prototype.reloadConfiguration=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/ReloadConfiguration",p,g||{},c)};const d=new t.web.MethodDescriptor("/base.SystemService/GetLicenseInfo",t.web.MethodType.UNARY,e.Empty,i.base.LicenseInfo,function(p){return p.serializeBinary()},i.base.LicenseInfo.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.LicenseInfo,function(p){return p.serializeBinary()},i.base.LicenseInfo.deserializeBinary),i.base.SystemServiceClient.prototype.getLicenseInfo=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/GetLicenseInfo",p,g||{},d,v)},i.base.SystemServicePromiseClient.prototype.getLicenseInfo=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/GetLicenseInfo",p,g||{},d)};const f=new t.web.MethodDescriptor("/base.SystemService/SetLicense",t.web.MethodType.UNARY,i.base.License,i.base.LicenseInfo,function(p){return p.serializeBinary()},i.base.LicenseInfo.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.LicenseInfo,function(p){return p.serializeBinary()},i.base.LicenseInfo.deserializeBinary),i.base.SystemServiceClient.prototype.setLicense=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/SetLicense",p,g||{},f,v)},i.base.SystemServicePromiseClient.prototype.setLicense=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/SetLicense",p,g||{},f)};const h=new t.web.MethodDescriptor("/base.SystemService/SetProperty",t.web.MethodType.UNARY,i.base.PropertyValue,e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary);return new t.web.AbstractClientBase.MethodInfo(e.Empty,function(p){return p.serializeBinary()},e.Empty.deserializeBinary),i.base.SystemServiceClient.prototype.setProperty=function(p,g,v){return this.client_.rpcCall(this.hostname_+"/base.SystemService/SetProperty",p,g||{},h,v)},i.base.SystemServicePromiseClient.prototype.setProperty=function(p,g){return this.client_.unaryCall(this.hostname_+"/base.SystemService/SetProperty",p,g||{},h)},wY=i.base,wY}var AY={},cce;function Kke(){return cce||(cce=1,(function(t){var e=qP(),i=e,n=Function("return this")(),r=jS();i.object.extend(proto,r);var o=j6();i.object.extend(proto,o);var a=XP();i.object.extend(proto,a),i.exportSymbol("proto.base.Mode",null,n),i.exportSymbol("proto.base.PlaybackConfig",null,n),i.exportSymbol("proto.base.PlaybackInfo",null,n),i.exportSymbol("proto.base.PlaybackInfos",null,n),i.exportSymbol("proto.base.PlaybackMode",null,n),i.exportSymbol("proto.base.PlaybackMode.StatusCase",null,n),proto.base.PlaybackMode=function(s){e.Message.initialize(this,s,0,-1,null,proto.base.PlaybackMode.oneofGroups_)},i.inherits(proto.base.PlaybackMode,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PlaybackMode.displayName="proto.base.PlaybackMode"),proto.base.PlaybackInfos=function(s){e.Message.initialize(this,s,0,-1,proto.base.PlaybackInfos.repeatedFields_,null)},i.inherits(proto.base.PlaybackInfos,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PlaybackInfos.displayName="proto.base.PlaybackInfos"),proto.base.PlaybackConfig=function(s){e.Message.initialize(this,s,0,-1,null,null)},i.inherits(proto.base.PlaybackConfig,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PlaybackConfig.displayName="proto.base.PlaybackConfig"),proto.base.PlaybackInfo=function(s){e.Message.initialize(this,s,0,-1,null,null)},i.inherits(proto.base.PlaybackInfo,e.Message),i.DEBUG&&!COMPILED&&(proto.base.PlaybackInfo.displayName="proto.base.PlaybackInfo"),proto.base.PlaybackMode.oneofGroups_=[[2,3,4]],proto.base.PlaybackMode.StatusCase={STATUS_NOT_SET:0,ERRORMESSAGE:2,EOF:3,MODE:4},proto.base.PlaybackMode.prototype.getStatusCase=function(){return e.Message.computeOneofCase(this,proto.base.PlaybackMode.oneofGroups_[0])},e.Message.GENERATE_TO_OBJECT&&(proto.base.PlaybackMode.prototype.toObject=function(s){return proto.base.PlaybackMode.toObject(s,this)},proto.base.PlaybackMode.toObject=function(s,l){var u={errormessage:e.Message.getFieldWithDefault(l,2,""),eof:e.Message.getFieldWithDefault(l,3,""),mode:e.Message.getFieldWithDefault(l,4,0),offsettime:e.Message.getFieldWithDefault(l,5,0),starttime:e.Message.getFieldWithDefault(l,6,0),endtime:e.Message.getFieldWithDefault(l,7,0),timedeviation:e.Message.getFieldWithDefault(l,8,0),offsetwallclockvssample:e.Message.getFieldWithDefault(l,9,0),noplaybacktoapplication:e.Message.getBooleanFieldWithDefault(l,10,!1),playbacktobus:e.Message.getBooleanFieldWithDefault(l,11,!1)};return s&&(u.$jspbMessageInstance=l),u}),proto.base.PlaybackMode.deserializeBinary=function(s){var l=new e.BinaryReader(s),u=new proto.base.PlaybackMode;return proto.base.PlaybackMode.deserializeBinaryFromReader(u,l)},proto.base.PlaybackMode.deserializeBinaryFromReader=function(s,l){for(;l.nextField()&&!l.isEndGroup();){var u=l.getFieldNumber();switch(u){case 2:var c=l.readString();s.setErrormessage(c);break;case 3:var c=l.readString();s.setEof(c);break;case 4:var c=l.readEnum();s.setMode(c);break;case 5:var c=l.readUint64();s.setOffsettime(c);break;case 6:var c=l.readUint64();s.setStarttime(c);break;case 7:var c=l.readUint64();s.setEndtime(c);break;case 8:var c=l.readInt64();s.setTimedeviation(c);break;case 9:var c=l.readInt64();s.setOffsetwallclockvssample(c);break;case 10:var c=l.readBool();s.setNoplaybacktoapplication(c);break;case 11:var c=l.readBool();s.setPlaybacktobus(c);break;default:l.skipField();break}}return s},proto.base.PlaybackMode.prototype.serializeBinary=function(){var s=new e.BinaryWriter;return proto.base.PlaybackMode.serializeBinaryToWriter(this,s),s.getResultBuffer()},proto.base.PlaybackMode.serializeBinaryToWriter=function(s,l){var u=void 0;u=e.Message.getField(s,2),u!=null&&l.writeString(2,u),u=e.Message.getField(s,3),u!=null&&l.writeString(3,u),u=e.Message.getField(s,4),u!=null&&l.writeEnum(4,u),u=s.getOffsettime(),u!==0&&l.writeUint64(5,u),u=s.getStarttime(),u!==0&&l.writeUint64(6,u),u=s.getEndtime(),u!==0&&l.writeUint64(7,u),u=s.getTimedeviation(),u!==0&&l.writeInt64(8,u),u=s.getOffsetwallclockvssample(),u!==0&&l.writeInt64(9,u),u=s.getNoplaybacktoapplication(),u&&l.writeBool(10,u),u=s.getPlaybacktobus(),u&&l.writeBool(11,u)},proto.base.PlaybackMode.prototype.getErrormessage=function(){return e.Message.getFieldWithDefault(this,2,"")},proto.base.PlaybackMode.prototype.setErrormessage=function(s){return e.Message.setOneofField(this,2,proto.base.PlaybackMode.oneofGroups_[0],s)},proto.base.PlaybackMode.prototype.clearErrormessage=function(){return e.Message.setOneofField(this,2,proto.base.PlaybackMode.oneofGroups_[0],void 0)},proto.base.PlaybackMode.prototype.hasErrormessage=function(){return e.Message.getField(this,2)!=null},proto.base.PlaybackMode.prototype.getEof=function(){return e.Message.getFieldWithDefault(this,3,"")},proto.base.PlaybackMode.prototype.setEof=function(s){return e.Message.setOneofField(this,3,proto.base.PlaybackMode.oneofGroups_[0],s)},proto.base.PlaybackMode.prototype.clearEof=function(){return e.Message.setOneofField(this,3,proto.base.PlaybackMode.oneofGroups_[0],void 0)},proto.base.PlaybackMode.prototype.hasEof=function(){return e.Message.getField(this,3)!=null},proto.base.PlaybackMode.prototype.getMode=function(){return e.Message.getFieldWithDefault(this,4,0)},proto.base.PlaybackMode.prototype.setMode=function(s){return e.Message.setOneofField(this,4,proto.base.PlaybackMode.oneofGroups_[0],s)},proto.base.PlaybackMode.prototype.clearMode=function(){return e.Message.setOneofField(this,4,proto.base.PlaybackMode.oneofGroups_[0],void 0)},proto.base.PlaybackMode.prototype.hasMode=function(){return e.Message.getField(this,4)!=null},proto.base.PlaybackMode.prototype.getOffsettime=function(){return e.Message.getFieldWithDefault(this,5,0)},proto.base.PlaybackMode.prototype.setOffsettime=function(s){return e.Message.setProto3IntField(this,5,s)},proto.base.PlaybackMode.prototype.getStarttime=function(){return e.Message.getFieldWithDefault(this,6,0)},proto.base.PlaybackMode.prototype.setStarttime=function(s){return e.Message.setProto3IntField(this,6,s)},proto.base.PlaybackMode.prototype.getEndtime=function(){return e.Message.getFieldWithDefault(this,7,0)},proto.base.PlaybackMode.prototype.setEndtime=function(s){return e.Message.setProto3IntField(this,7,s)},proto.base.PlaybackMode.prototype.getTimedeviation=function(){return e.Message.getFieldWithDefault(this,8,0)},proto.base.PlaybackMode.prototype.setTimedeviation=function(s){return e.Message.setProto3IntField(this,8,s)},proto.base.PlaybackMode.prototype.getOffsetwallclockvssample=function(){return e.Message.getFieldWithDefault(this,9,0)},proto.base.PlaybackMode.prototype.setOffsetwallclockvssample=function(s){return e.Message.setProto3IntField(this,9,s)},proto.base.PlaybackMode.prototype.getNoplaybacktoapplication=function(){return e.Message.getBooleanFieldWithDefault(this,10,!1)},proto.base.PlaybackMode.prototype.setNoplaybacktoapplication=function(s){return e.Message.setProto3BooleanField(this,10,s)},proto.base.PlaybackMode.prototype.getPlaybacktobus=function(){return e.Message.getBooleanFieldWithDefault(this,11,!1)},proto.base.PlaybackMode.prototype.setPlaybacktobus=function(s){return e.Message.setProto3BooleanField(this,11,s)},proto.base.PlaybackInfos.repeatedFields_=[1],e.Message.GENERATE_TO_OBJECT&&(proto.base.PlaybackInfos.prototype.toObject=function(s){return proto.base.PlaybackInfos.toObject(s,this)},proto.base.PlaybackInfos.toObject=function(s,l){var u={playbackinfoList:e.Message.toObjectList(l.getPlaybackinfoList(),proto.base.PlaybackInfo.toObject,s)};return s&&(u.$jspbMessageInstance=l),u}),proto.base.PlaybackInfos.deserializeBinary=function(s){var l=new e.BinaryReader(s),u=new proto.base.PlaybackInfos;return proto.base.PlaybackInfos.deserializeBinaryFromReader(u,l)},proto.base.PlaybackInfos.deserializeBinaryFromReader=function(s,l){for(;l.nextField()&&!l.isEndGroup();){var u=l.getFieldNumber();switch(u){case 1:var c=new proto.base.PlaybackInfo;l.readMessage(c,proto.base.PlaybackInfo.deserializeBinaryFromReader),s.addPlaybackinfo(c);break;default:l.skipField();break}}return s},proto.base.PlaybackInfos.prototype.serializeBinary=function(){var s=new e.BinaryWriter;return proto.base.PlaybackInfos.serializeBinaryToWriter(this,s),s.getResultBuffer()},proto.base.PlaybackInfos.serializeBinaryToWriter=function(s,l){var u=void 0;u=s.getPlaybackinfoList(),u.length>0&&l.writeRepeatedMessage(1,u,proto.base.PlaybackInfo.serializeBinaryToWriter)},proto.base.PlaybackInfos.prototype.getPlaybackinfoList=function(){return e.Message.getRepeatedWrapperField(this,proto.base.PlaybackInfo,1)},proto.base.PlaybackInfos.prototype.setPlaybackinfoList=function(s){return e.Message.setRepeatedWrapperField(this,1,s)},proto.base.PlaybackInfos.prototype.addPlaybackinfo=function(s,l){return e.Message.addToRepeatedWrapperField(this,1,s,proto.base.PlaybackInfo,l)},proto.base.PlaybackInfos.prototype.clearPlaybackinfoList=function(){return this.setPlaybackinfoList([])},e.Message.GENERATE_TO_OBJECT&&(proto.base.PlaybackConfig.prototype.toObject=function(s){return proto.base.PlaybackConfig.toObject(s,this)},proto.base.PlaybackConfig.toObject=function(s,l){var u,c={filedescription:(u=l.getFiledescription())&&o.FileDescription.toObject(s,u),namespace:(u=l.getNamespace())&&r.NameSpace.toObject(s,u)};return s&&(c.$jspbMessageInstance=l),c}),proto.base.PlaybackConfig.deserializeBinary=function(s){var l=new e.BinaryReader(s),u=new proto.base.PlaybackConfig;return proto.base.PlaybackConfig.deserializeBinaryFromReader(u,l)},proto.base.PlaybackConfig.deserializeBinaryFromReader=function(s,l){for(;l.nextField()&&!l.isEndGroup();){var u=l.getFieldNumber();switch(u){case 1:var c=new o.FileDescription;l.readMessage(c,o.FileDescription.deserializeBinaryFromReader),s.setFiledescription(c);break;case 2:var c=new r.NameSpace;l.readMessage(c,r.NameSpace.deserializeBinaryFromReader),s.setNamespace(c);break;default:l.skipField();break}}return s},proto.base.PlaybackConfig.prototype.serializeBinary=function(){var s=new e.BinaryWriter;return proto.base.PlaybackConfig.serializeBinaryToWriter(this,s),s.getResultBuffer()},proto.base.PlaybackConfig.serializeBinaryToWriter=function(s,l){var u=void 0;u=s.getFiledescription(),u!=null&&l.writeMessage(1,u,o.FileDescription.serializeBinaryToWriter),u=s.getNamespace(),u!=null&&l.writeMessage(2,u,r.NameSpace.serializeBinaryToWriter)},proto.base.PlaybackConfig.prototype.getFiledescription=function(){return e.Message.getWrapperField(this,o.FileDescription,1)},proto.base.PlaybackConfig.prototype.setFiledescription=function(s){return e.Message.setWrapperField(this,1,s)},proto.base.PlaybackConfig.prototype.clearFiledescription=function(){return this.setFiledescription(void 0)},proto.base.PlaybackConfig.prototype.hasFiledescription=function(){return e.Message.getField(this,1)!=null},proto.base.PlaybackConfig.prototype.getNamespace=function(){return e.Message.getWrapperField(this,r.NameSpace,2)},proto.base.PlaybackConfig.prototype.setNamespace=function(s){return e.Message.setWrapperField(this,2,s)},proto.base.PlaybackConfig.prototype.clearNamespace=function(){return this.setNamespace(void 0)},proto.base.PlaybackConfig.prototype.hasNamespace=function(){return e.Message.getField(this,2)!=null},e.Message.GENERATE_TO_OBJECT&&(proto.base.PlaybackInfo.prototype.toObject=function(s){return proto.base.PlaybackInfo.toObject(s,this)},proto.base.PlaybackInfo.toObject=function(s,l){var u,c={playbackconfig:(u=l.getPlaybackconfig())&&proto.base.PlaybackConfig.toObject(s,u),playbackmode:(u=l.getPlaybackmode())&&proto.base.PlaybackMode.toObject(s,u)};return s&&(c.$jspbMessageInstance=l),c}),proto.base.PlaybackInfo.deserializeBinary=function(s){var l=new e.BinaryReader(s),u=new proto.base.PlaybackInfo;return proto.base.PlaybackInfo.deserializeBinaryFromReader(u,l)},proto.base.PlaybackInfo.deserializeBinaryFromReader=function(s,l){for(;l.nextField()&&!l.isEndGroup();){var u=l.getFieldNumber();switch(u){case 1:var c=new proto.base.PlaybackConfig;l.readMessage(c,proto.base.PlaybackConfig.deserializeBinaryFromReader),s.setPlaybackconfig(c);break;case 2:var c=new proto.base.PlaybackMode;l.readMessage(c,proto.base.PlaybackMode.deserializeBinaryFromReader),s.setPlaybackmode(c);break;default:l.skipField();break}}return s},proto.base.PlaybackInfo.prototype.serializeBinary=function(){var s=new e.BinaryWriter;return proto.base.PlaybackInfo.serializeBinaryToWriter(this,s),s.getResultBuffer()},proto.base.PlaybackInfo.serializeBinaryToWriter=function(s,l){var u=void 0;u=s.getPlaybackconfig(),u!=null&&l.writeMessage(1,u,proto.base.PlaybackConfig.serializeBinaryToWriter),u=s.getPlaybackmode(),u!=null&&l.writeMessage(2,u,proto.base.PlaybackMode.serializeBinaryToWriter)},proto.base.PlaybackInfo.prototype.getPlaybackconfig=function(){return e.Message.getWrapperField(this,proto.base.PlaybackConfig,1)},proto.base.PlaybackInfo.prototype.setPlaybackconfig=function(s){return e.Message.setWrapperField(this,1,s)},proto.base.PlaybackInfo.prototype.clearPlaybackconfig=function(){return this.setPlaybackconfig(void 0)},proto.base.PlaybackInfo.prototype.hasPlaybackconfig=function(){return e.Message.getField(this,1)!=null},proto.base.PlaybackInfo.prototype.getPlaybackmode=function(){return e.Message.getWrapperField(this,proto.base.PlaybackMode,2)},proto.base.PlaybackInfo.prototype.setPlaybackmode=function(s){return e.Message.setWrapperField(this,2,s)},proto.base.PlaybackInfo.prototype.clearPlaybackmode=function(){return this.setPlaybackmode(void 0)},proto.base.PlaybackInfo.prototype.hasPlaybackmode=function(){return e.Message.getField(this,2)!=null},proto.base.Mode={PLAY:0,PAUSE:1,STOP:2,RECORD:3,SEEK:4},i.object.extend(t,proto.base)})(AY)),AY}var OY,dce;function $0t(){if(dce)return OY;dce=1;const t={};t.web=B6();var e=jS();j6(),XP();const i={};i.base=Kke(),i.base.TrafficServiceClient=function(o,a,s){s||(s={}),s.format="text",this.client_=new t.web.GrpcWebClientBase(s),this.hostname_=o},i.base.TrafficServicePromiseClient=function(o,a,s){s||(s={}),s.format="text",this.client_=new t.web.GrpcWebClientBase(s),this.hostname_=o};const n=new t.web.MethodDescriptor("/base.TrafficService/PlayTraffic",t.web.MethodType.UNARY,i.base.PlaybackInfos,i.base.PlaybackInfos,function(o){return o.serializeBinary()},i.base.PlaybackInfos.deserializeBinary);new t.web.AbstractClientBase.MethodInfo(i.base.PlaybackInfos,function(o){return o.serializeBinary()},i.base.PlaybackInfos.deserializeBinary),i.base.TrafficServiceClient.prototype.playTraffic=function(o,a,s){return this.client_.rpcCall(this.hostname_+"/base.TrafficService/PlayTraffic",o,a||{},n,s)},i.base.TrafficServicePromiseClient.prototype.playTraffic=function(o,a){return this.client_.unaryCall(this.hostname_+"/base.TrafficService/PlayTraffic",o,a||{},n)};const r=new t.web.MethodDescriptor("/base.TrafficService/PlayTrafficStatus",t.web.MethodType.SERVER_STREAMING,e.Empty,i.base.PlaybackInfos,function(o){return o.serializeBinary()},i.base.PlaybackInfos.deserializeBinary);return new t.web.AbstractClientBase.MethodInfo(i.base.PlaybackInfos,function(o){return o.serializeBinary()},i.base.PlaybackInfos.deserializeBinary),i.base.TrafficServiceClient.prototype.playTrafficStatus=function(o,a){return this.client_.serverStreaming(this.hostname_+"/base.TrafficService/PlayTrafficStatus",o,a||{},r)},i.base.TrafficServicePromiseClient.prototype.playTrafficStatus=function(o,a){return this.client_.serverStreaming(this.hostname_+"/base.TrafficService/PlayTrafficStatus",o,a||{},r)},OY=i.base,OY}var fce;function W0t(){return fce||(fce=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PlaybackMode=t.PlaybackInfos=t.PlaybackInfo=t.PlaybackConfig=t.Mode=t.TrafficServicePromiseClient=t.TrafficServiceClient=t.FileUploadResponse=t.FileDownloadResponse=t.FileDescriptions=t.FileDescription=t.FileUploadChunkRequest=t.ReloadMessage=t.License=t.LicenseStatus=t.LicenseInfo=t.Configuration=t.SystemServicePromiseClient=t.SystemServiceClient=t.CountByFrameId=t.FramesDistribution=t.FramesDistributionConfig=t.Signal=t.PublisherConfig=t.Signals=t.SignalIds=t.SubscriberConfig=t.NetworkServicePromiseClient=t.NetworkServiceClient=t.DiagnosticsServicePromiseClient=t.DiagnosticsServiceClient=t.NetworkInfo=t.FrameInfo=t.MetaData=t.Frames=t.NameSpace=t.SignalInfo=t.SignalId=t.ClientId=t.Empty=void 0;var e=jS();Object.defineProperty(t,"Empty",{enumerable:!0,get:function(){return e.Empty}}),Object.defineProperty(t,"ClientId",{enumerable:!0,get:function(){return e.ClientId}}),Object.defineProperty(t,"SignalId",{enumerable:!0,get:function(){return e.SignalId}}),Object.defineProperty(t,"SignalInfo",{enumerable:!0,get:function(){return e.SignalInfo}}),Object.defineProperty(t,"NameSpace",{enumerable:!0,get:function(){return e.NameSpace}}),Object.defineProperty(t,"Frames",{enumerable:!0,get:function(){return e.Frames}}),Object.defineProperty(t,"MetaData",{enumerable:!0,get:function(){return e.MetaData}}),Object.defineProperty(t,"FrameInfo",{enumerable:!0,get:function(){return e.FrameInfo}}),Object.defineProperty(t,"NetworkInfo",{enumerable:!0,get:function(){return e.NetworkInfo}});var i=H0t();Object.defineProperty(t,"DiagnosticsServiceClient",{enumerable:!0,get:function(){return i.DiagnosticsServiceClient}}),Object.defineProperty(t,"DiagnosticsServicePromiseClient",{enumerable:!0,get:function(){return i.DiagnosticsServicePromiseClient}});var n=U0t();Object.defineProperty(t,"NetworkServiceClient",{enumerable:!0,get:function(){return n.NetworkServiceClient}}),Object.defineProperty(t,"NetworkServicePromiseClient",{enumerable:!0,get:function(){return n.NetworkServicePromiseClient}});var r=Xke();Object.defineProperty(t,"SubscriberConfig",{enumerable:!0,get:function(){return r.SubscriberConfig}}),Object.defineProperty(t,"SignalIds",{enumerable:!0,get:function(){return r.SignalIds}}),Object.defineProperty(t,"Signals",{enumerable:!0,get:function(){return r.Signals}}),Object.defineProperty(t,"PublisherConfig",{enumerable:!0,get:function(){return r.PublisherConfig}}),Object.defineProperty(t,"Signal",{enumerable:!0,get:function(){return r.Signal}}),Object.defineProperty(t,"FramesDistributionConfig",{enumerable:!0,get:function(){return r.FramesDistributionConfig}}),Object.defineProperty(t,"FramesDistribution",{enumerable:!0,get:function(){return r.FramesDistribution}}),Object.defineProperty(t,"CountByFrameId",{enumerable:!0,get:function(){return r.CountByFrameId}});var o=z0t();Object.defineProperty(t,"SystemServiceClient",{enumerable:!0,get:function(){return o.SystemServiceClient}}),Object.defineProperty(t,"SystemServicePromiseClient",{enumerable:!0,get:function(){return o.SystemServicePromiseClient}});var a=j6();Object.defineProperty(t,"Configuration",{enumerable:!0,get:function(){return a.Configuration}}),Object.defineProperty(t,"LicenseInfo",{enumerable:!0,get:function(){return a.LicenseInfo}}),Object.defineProperty(t,"LicenseStatus",{enumerable:!0,get:function(){return a.LicenseStatus}}),Object.defineProperty(t,"License",{enumerable:!0,get:function(){return a.License}}),Object.defineProperty(t,"ReloadMessage",{enumerable:!0,get:function(){return a.ReloadMessage}}),Object.defineProperty(t,"FileUploadChunkRequest",{enumerable:!0,get:function(){return a.FileUploadChunkRequest}}),Object.defineProperty(t,"FileDescription",{enumerable:!0,get:function(){return a.FileDescription}}),Object.defineProperty(t,"FileDescriptions",{enumerable:!0,get:function(){return a.FileDescriptions}}),Object.defineProperty(t,"FileDownloadResponse",{enumerable:!0,get:function(){return a.FileDownloadResponse}}),Object.defineProperty(t,"FileUploadResponse",{enumerable:!0,get:function(){return a.FileUploadResponse}});var s=$0t();Object.defineProperty(t,"TrafficServiceClient",{enumerable:!0,get:function(){return s.TrafficServiceClient}}),Object.defineProperty(t,"TrafficServicePromiseClient",{enumerable:!0,get:function(){return s.TrafficServicePromiseClient}});var l=Kke();Object.defineProperty(t,"Mode",{enumerable:!0,get:function(){return l.Mode}}),Object.defineProperty(t,"PlaybackConfig",{enumerable:!0,get:function(){return l.PlaybackConfig}}),Object.defineProperty(t,"PlaybackInfo",{enumerable:!0,get:function(){return l.PlaybackInfo}}),Object.defineProperty(t,"PlaybackInfos",{enumerable:!0,get:function(){return l.PlaybackInfos}}),Object.defineProperty(t,"PlaybackMode",{enumerable:!0,get:function(){return l.PlaybackMode}})})(yY)),yY}var Id=W0t();async function Zke(t){await new Id.SystemServicePromiseClient(t).healthCheck(new Id.Empty,{})}const G0t=3e3,Y0t=1e4;function q0t(t,e,i,n){const r=qt.c(18),o=J.useRef(!1),a=J.useRef(!1);let s,l;r[0]!==t||r[1]!==i||r[2]!==e?(s=()=>{if(!t||e||a.current)return;let v;const y=()=>{o.current||(o.current=!0,i(t).catch(()=>{v=setTimeout(y,G0t)}).finally(()=>{o.current=!1}))};return y(),()=>{clearTimeout(v)}},l=[e,i,t],r[0]=t,r[1]=i,r[2]=e,r[3]=s,r[4]=l):(s=r[3],l=r[4]),J.useEffect(s,l);let u,c;r[5]!==t||r[6]!==e||r[7]!==n?(u=()=>{if(!t||!e)return;const v=setInterval(()=>{Zke(t).catch(()=>{n()})},Y0t);return()=>{clearInterval(v)}},c=[e,t,n],r[5]=t,r[6]=e,r[7]=n,r[8]=u,r[9]=c):(u=r[8],c=r[9]),J.useEffect(u,c);let d;r[10]!==t||r[11]!==i?(d=async()=>{t&&(a.current=!1,await i(t))},r[10]=t,r[11]=i,r[12]=d):d=r[12];const f=d;let h;r[13]!==n?(h=()=>{a.current=!0,n()},r[13]=n,r[14]=h):h=r[14];const p=h;let g;return r[15]!==f||r[16]!==p?(g={connect:f,disconnect:p},r[15]=f,r[16]=p,r[17]=g):g=r[17],g}function X0t(t){const e=qt.c(9),[i,n]=J.useState(void 0);let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=async(h,p)=>{await Zke(h);const g=await N0t(h,p);n(g)},e[0]=r):r=e[0];const o=r;let a;e[1]===Symbol.for("react.memo_cache_sentinel")?(a=()=>{n(void 0)},e[1]=a):a=e[1];const s=a,{connect:l,disconnect:u}=q0t(t.brokerUrl,i,o,s);let c;e[2]!==l||e[3]!==i||e[4]!==u?(c={connectedBroker:i,connectBroker:l,disconnectBroker:u},e[2]=l,e[3]=i,e[4]=u,e[5]=c):c=e[5];const d=c;let f;return e[6]!==d||e[7]!==t.children?(f=L.jsx(Yke.Provider,{value:d,children:t.children}),e[6]=d,e[7]=t.children,e[8]=f):f=e[8],f}function Jke(){const t=fte(),[e,i]=J.useState(void 0),[n,r]=J.useState([]),[o,a]=J.useState([]),[s,l]=J.useState(!0),u=J.useRef(null),c=J.useRef(0);J.useEffect(()=>{if(u.current===t.httpUrl&&e!==void 0)return;u.current=t.httpUrl;let h=!1;const p=async()=>{l(!0);try{const g=new Gke(t),v=new Wke(t);if(!h){const y=new yke(g,v),m=new jvt(v);i({playbackService:y,recordingSessionService:m})}}catch(g){console.error("Failed to initialize playback services:",g),h||(i(void 0),l(!1))}};return i(void 0),r([]),a([]),p(),()=>{h=!0}},[t]),J.useEffect(()=>{if(!e)return;let h=!1;return(async()=>{try{const g=await e.recordingSessionService.listFiles("/",!0,[ea.FILE_TYPE_RECORDING_SESSION]);console.log("fetchFiles",g),h||(r(g.flatten()),a(g.files),l(!1))}catch(g){console.error("Failed to fetch recording files:",g),h||(r([]),a([]),l(!1))}})(),()=>{h=!0}},[e,c.current]);const d=J.useCallback(async h=>{if(!e)throw new Error("Playback services not initialized");await e.playbackService.open(h)},[e]),f=J.useCallback(()=>{c.current+=1,l(!0)},[]);return{files:n,fileTree:o,isLoading:s,open:d,refresh:f}}const hte=J.createContext(void 0);function pte(){"use no memo";const t=J.useContext(hte);if(t===void 0)throw new Error("useAccumulatedPlaybacks must be used within a PlaybackProvider");return J.useSyncExternalStore(i=>t.subscribeAll(i),()=>t.getAll())}function Qke(t){"use no memo";const e=J.useContext(hte);if(e===void 0)throw new Error("usePlayback must be used within a PlaybackProvider");return J.useSyncExternalStore(n=>e.subscribe(t,n),()=>e.get(t))}class K0t{constructor(){this.openPlaybacks=new Map,this.perPathPlaybackListeners=new Map,this.accumulatedPlaybackListeners=new Set,this.latestAccumulatedPlaybacks=[]}get(e){return this.openPlaybacks.get(e)}getAll(){return this.latestAccumulatedPlaybacks}update(e,i){var n;this.openPlaybacks.set(e,i),this.latestAccumulatedPlaybacks=Array.from(this.openPlaybacks.values()),(n=this.perPathPlaybackListeners.get(e))==null||n.forEach(r=>r()),this.accumulatedPlaybackListeners.forEach(r=>r())}delete(e){var i;this.openPlaybacks.delete(e),this.latestAccumulatedPlaybacks=Array.from(this.openPlaybacks.values()),(i=this.perPathPlaybackListeners.get(e))==null||i.forEach(n=>n()),this.accumulatedPlaybackListeners.forEach(n=>n())}subscribe(e,i){return this.perPathPlaybackListeners.has(e)||this.perPathPlaybackListeners.set(e,new Set),this.perPathPlaybackListeners.get(e).add(i),()=>{var n;(n=this.perPathPlaybackListeners.get(e))==null||n.delete(i)}}subscribeAll(e){return this.accumulatedPlaybackListeners.add(e),()=>{this.accumulatedPlaybackListeners.delete(e)}}clear(){this.openPlaybacks.clear(),this.latestAccumulatedPlaybacks=[],this.perPathPlaybackListeners.clear(),this.accumulatedPlaybackListeners.clear()}}const iL=new K0t;function Z0t(t){const e=qt.c(15),{onRecordingSessionClosed:i,onFetchError:n,children:r}=t,o=fte(),[a,s]=J.useState(void 0),[l,u]=J.useState(!1),c=J.useRef(null);let d;e[0]!==o||e[1]!==a?(d=()=>{if(c.current===o.grpcUrl&&a!==void 0)return;c.current=o.grpcUrl;let y=!1;const m=async()=>{try{const b=new Gke(o),S=new Wke(o);if(!y){const _=new yke(b,S);s(_)}}catch(b){console.error("Failed to create PlaybackService:",b),y||s(void 0)}};return s(void 0),iL.clear(),m(),()=>{y=!0}},e[0]=o,e[1]=a,e[2]=d):d=e[2];let f;e[3]!==o?(f=[o],e[3]=o,e[4]=f):f=e[4],J.useEffect(d,f);let h,p;e[5]!==n||e[6]!==i||e[7]!==a?(h=()=>{if(!a)return;const y=(C,P)=>{iL.update(C,P),u(!1)},m=C=>{iL.delete(C),i==null||i(C),u(!1)},b=()=>{u(!0),iL.clear()},S=(C,P)=>{n==null||n(C,P)},_=()=>{u(!1)};return a.subscribeToRecordingSessionPlaybacks(y,m,b,S,_),()=>{a.stopPlaybackStatusStream(),iL.clear()}},p=[a,i,n],e[5]=n,e[6]=i,e[7]=a,e[8]=h,e[9]=p):(h=e[8],p=e[9]),J.useEffect(h,p);let g;e[10]!==l?(g=l&&L.jsx("p",{className:"text-red-500 text-sm",children:"Unable to connect to playback stream"}),e[10]=l,e[11]=g):g=e[11];let v;return e[12]!==r||e[13]!==g?(v=L.jsxs(hte.Provider,{value:iL,children:[g,r]}),e[12]=r,e[13]=g,e[14]=v):v=e[14],v}function hce(t){const e=qt.c(6),{position:i}=t,n=`${i}%`;let r;e[0]!==n?(r={position:"absolute",left:n,top:"0"},e[0]=n,e[1]=r):r=e[1];let o;e[2]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx(dLe,{sx:{fontSize:7,color:"var(--success-60)",position:"absolute",top:"-6px",left:"-3px"}}),e[2]=o):o=e[2];let a;e[3]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx("div",{className:"absolute top-[0px] left-0 w-0 h-[16px] border-l border-dotted pointer-events-none",style:{borderColor:"var(--success-60)"}}),e[3]=a):a=e[3];let s;return e[4]!==r?(s=L.jsxs("div",{style:r,children:[o,a]}),e[4]=r,e[5]=s):s=e[5],s}const pce=(t,e)=>L.jsxs(L.Fragment,{children:[L.jsx("p",{className:"text-left font-bold m-0 mb-1",children:t}),L.jsx("p",{className:"text-left text-sm m-0",children:e})]});function J0t(t){const e=qt.c(24),[i,n]=J.useState(!1),[r,o]=J.useState(""),a=J.useRef(null);let s,l;e[0]!==i?(s=()=>{i&&a.current&&(a.current.focus(),a.current.select())},l=[i],e[0]=i,e[1]=s,e[2]=l):(s=e[1],l=e[2]),J.useEffect(s,l);const u=tbt;let c;e[3]!==t.currentTime||e[4]!==t.isDisabled?(c=()=>{t.isDisabled||(o(t.currentTime),n(!0))},e[3]=t.currentTime,e[4]=t.isDisabled,e[5]=c):c=e[5];const d=c;let f;e[6]!==t||e[7]!==r?(f=async()=>{const b=u(r);if(b===null){Ki.error(pce("Invalid input","Your input must be numbers in the format HH:MM:SS, MM:SS, or SS"),{autoClose:1e4});return}if(b<0||b>t.durationMs){Ki.error(pce("Invalid input","Time must be within the recording duration."),{autoClose:1e4});return}await t.onSeek(b),n(!1)},e[6]=t,e[7]=r,e[8]=f):f=e[8];const h=f;let p;e[9]!==h?(p=b=>{b.key==="Enter"?(b.preventDefault(),h()):b.key==="Escape"&&(b.preventDefault(),n(!1))},e[9]=h,e[10]=p):p=e[10];const g=p;let v;e[11]===Symbol.for("react.memo_cache_sentinel")?(v=()=>{n(!1)},e[11]=v):v=e[11];const y=v;let m;if(e[12]!==d||e[13]!==g||e[14]!==h||e[15]!==i||e[16]!==t.currentTime||e[17]!==t.isDisabled||e[18]!==r){const b=()=>L.jsxs("div",{className:"flex items-center -ml-0.5 -my-1.5 z-[2]",children:[L.jsx("input",{ref:a,type:"text",value:r,onChange:C=>o(C.target.value),onKeyDown:g,className:yo("text-xs w-[45px] px-1 py-0.5 mr-1","rounded border","bg-background dark:bg-neutral-800","border-remotive-primary-30 dark:border-neutral-600","text-foreground dark:text-neutral-200","focus:outline-none focus:ring-1 focus:ring-remotive-primary-60"),placeholder:"MM:SS",title:"Enter time (HH:MM:SS, MM:SS, or SS)"}),L.jsx("button",{onClick:h,onMouseDown:ebt,className:yo("flex items-center justify-center","border-0 rounded p-0","bg-transparent","text-remotive-success-70","transition-colors duration-200"),title:"Confirm and seek to time in input",children:L.jsx(Tct,{style:{fontSize:"16px"}})}),L.jsx("button",{onClick:y,onMouseDown:Q0t,className:yo("flex items-center justify-center","border-0 rounded p-0","bg-transparent","text-destructive","transition-colors duration-200"),title:"Cancel",children:L.jsx(uz,{style:{fontSize:"16px"}})})]});let S;e[20]!==d||e[21]!==t.currentTime||e[22]!==t.isDisabled?(S=()=>L.jsx("span",{className:yo("px-0.5 py-0 rounded z-[2]","bg-transparent","text-foreground dark:text-neutral-300",t.isDisabled?"cursor-default":"cursor-pointer hover:bg-remotive-primary-10"),onClick:d,title:"Click to enter a specific time",style:{fontSize:"10px"},children:t.currentTime}),e[20]=d,e[21]=t.currentTime,e[22]=t.isDisabled,e[23]=S):S=e[23],m=i?b():S(),e[12]=d,e[13]=g,e[14]=h,e[15]=i,e[16]=t.currentTime,e[17]=t.isDisabled,e[18]=r,e[19]=m}else m=e[19];return m}function Q0t(t){return t.preventDefault()}function ebt(t){return t.preventDefault()}function tbt(t){const e=t.trim().split(":").map(rbt);if(e.some(isNaN))return null;let i;if(e.length===1)i=e[0];else if(e.length===2)i=e[0]*60+e[1];else if(e.length===3)i=e[0]*3600+e[1]*60+e[2];else return null;return i*1e3}function rbt(t){return parseInt(t,10)}function ibt(t){const e=qt.c(62),[i,n]=J.useState(!1),[r,o]=J.useState(void 0),{isDarkMode:a}=dI();let s;e[0]!==r||e[1]!==i||e[2]!==t.playbackControls.elapsedTimeMs?(s=()=>{const X=i?r:Number(t.playbackControls.elapsedTimeMs);return Hk(X||0)},e[0]=r,e[1]=i,e[2]=t.playbackControls.elapsedTimeMs,e[3]=s):s=e[3];const l=s;let u;e[4]!==t.playbackControls.durationMs?(u=()=>Hk(t.playbackControls.durationMs),e[4]=t.playbackControls.durationMs,e[5]=u):u=e[5];const c=u;let d;e[6]!==r||e[7]!==t.recordingSessionInfo.startTimeMs?(d=()=>{const X=new Date(t.recordingSessionInfo.startTimeMs+Number(r));return zyt(X)},e[6]=r,e[7]=t.recordingSessionInfo.startTimeMs,e[8]=d):d=e[8];const f=d;let h;e[9]!==r||e[10]!==i||e[11]!==t.playbackControls.elapsedTimeMs?(h=()=>i?r??0:Number(t.playbackControls.elapsedTimeMs),e[9]=r,e[10]=i,e[11]=t.playbackControls.elapsedTimeMs,e[12]=h):h=e[12];const p=h;let g;e[13]!==t?(g=async X=>{await t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.seek(X)},()=>{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})})},e[13]=t,e[14]=g):g=e[14];const v=g;let y;e[15]!==p||e[16]!==a||e[17]!==t?(y=()=>L.jsx(Nvt,{disabled:t.isPlaybackControlsDisabled,onBeforeChange:()=>{n(!0)},onChange:X=>{o(X)},onAfterChange:async X=>{await t.onDisableControlsAndChangePlaybackState(async()=>{await t.playbackControls.seek(X)},()=>{Ki.error(t.playbackErrorMessage(),{autoClose:1e4})}),n(!1)},handleStyle:{backgroundColor:a?"#1e3a5f":"#B6F0C3",borderColor:a?"#89CFF0":"#0b3f70",opacity:"1"},trackStyle:{backgroundColor:a?"#89CFF0":"#0b3f70"},railStyle:{backgroundColor:a?"#374151":"#d2e1ee"},min:0,max:t.recordingSessionInfo.durationMs,value:p()}),e[15]=p,e[16]=a,e[17]=t,e[18]=y):y=e[18];const m=y;let b;e[19]!==t.playbackControls.repeat.endMs||e[20]!==t.playbackControls.repeat.startMs||e[21]!==t.recordingSessionInfo.durationMs?(b=X=>{if(!X)return null;const W=t.playbackControls.repeat.startMs!==void 0?t.playbackControls.repeat.startMs/t.recordingSessionInfo.durationMs*100:null,Y=t.playbackControls.repeat.endMs!==void 0?t.playbackControls.repeat.endMs/t.recordingSessionInfo.durationMs*100:null;return L.jsxs(L.Fragment,{children:[W!==null&&L.jsx(hce,{position:W}),Y!==null&&L.jsx(hce,{position:Y})]})},e[19]=t.playbackControls.repeat.endMs,e[20]=t.playbackControls.repeat.startMs,e[21]=t.recordingSessionInfo.durationMs,e[22]=b):b=e[22];const S=b;let _;e[23]===Symbol.for("react.memo_cache_sentinel")?(_={lineHeight:"normal"},e[23]=_):_=e[23];let C;e[24]===Symbol.for("react.memo_cache_sentinel")?(C=L.jsx("div",{className:"flex items-start justify-between",children:L.jsx("div",{className:"flex-1 min-w-0 overflow-hidden mx-2"})}),e[24]=C):C=e[24];let P;e[25]!==m?(P=m(),e[25]=m,e[26]=P):P=e[26];let x;e[27]!==t.playbackControls.repeat.isRepeating||e[28]!==S?(x=S(t.playbackControls.repeat.isRepeating),e[27]=t.playbackControls.repeat.isRepeating,e[28]=S,e[29]=x):x=e[29];let E;e[30]!==l?(E=l(),e[30]=l,e[31]=E):E=e[31];let A;e[32]!==v||e[33]!==a||e[34]!==t.isPlaybackControlsDisabled||e[35]!==t.recordingSessionInfo.durationMs||e[36]!==E?(A=L.jsx(J0t,{currentTime:E,durationMs:t.recordingSessionInfo.durationMs,isDisabled:t.isPlaybackControlsDisabled,onSeek:v,isDarkMode:a}),e[32]=v,e[33]=a,e[34]=t.isPlaybackControlsDisabled,e[35]=t.recordingSessionInfo.durationMs,e[36]=E,e[37]=A):A=e[37];let R,M;e[38]===Symbol.for("react.memo_cache_sentinel")?(R=yo("m-0 truncate text-center","text-muted-foreground dark:text-neutral-200"),M={fontSize:"10px"},e[38]=R,e[39]=M):(R=e[38],M=e[39]);let D;e[40]!==t.recordingSessionInfo.path?(D=L.jsx("p",{className:R,style:M,title:t.recordingSessionInfo.path,children:t.recordingSessionInfo.path}),e[40]=t.recordingSessionInfo.path,e[41]=D):D=e[41];let F,I;e[42]===Symbol.for("react.memo_cache_sentinel")?(F=yo("z-[2] shrink-0","text-foreground dark:text-neutral-300"),I={fontSize:"10px"},e[42]=F,e[43]=I):(F=e[42],I=e[43]);let V;e[44]!==c?(V=c(),e[44]=c,e[45]=V):V=e[45];let z;e[46]!==V?(z=L.jsx("span",{className:F,style:I,children:V}),e[46]=V,e[47]=z):z=e[47];let G;e[48]!==A||e[49]!==D||e[50]!==z?(G=L.jsxs("div",{className:"flex items-center justify-between",children:[A,D,z]}),e[48]=A,e[49]=D,e[50]=z,e[51]=G):G=e[51];let H;e[52]!==x||e[53]!==G||e[54]!==P?(H=L.jsxs("div",{className:"relative",children:[P,x,G]}),e[52]=x,e[53]=G,e[54]=P,e[55]=H):H=e[55];let U;e[56]!==i||e[57]!==f?(U=i&&L.jsx("div",{className:"flex justify-center absolute overflow-visible z-[2] pointer-events-none",style:{top:"15px",left:"50%",transform:"translateX(-50%)"},children:L.jsx("div",{className:yo("p-2 rounded-xs mt-4","bg-neutral-800 dark:bg-neutral-900"),children:L.jsx("p",{className:"m-0 text-sm text-white whitespace-nowrap",children:f()})})}),e[56]=i,e[57]=f,e[58]=U):U=e[58];let k;return e[59]!==H||e[60]!==U?(k=L.jsxs("div",{style:_,children:[C,H,U]}),e[59]=H,e[60]=U,e[61]=k):k=e[61],k}function nbt(t){const e=qt.c(34),[i,n]=J.useState(!1);let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=async(b,S)=>{n(!0);try{await b()}catch(_){S(_)}n(!1)},e[0]=r):r=e[0];const o=r;let a;e[1]!==t.recordingSessionInfo.path?(a=(b,S)=>L.jsxs("div",{className:"text-left",children:[L.jsx("p",{className:"font-bold m-0",children:b}),L.jsxs("p",{className:"text-sm m-0",children:["There was an error trying to ",S," the recording"," ",L.jsx("span",{className:"font-bold",children:t.recordingSessionInfo.path}),". If this keeps happening, you might have to reload the application."]})]}),e[1]=t.recordingSessionInfo.path,e[2]=a):a=e[2];const s=a;let l;e[3]!==i||e[4]!==s||e[5]!==t.playbackControls||e[6]!==t.recordingSessionInfo?(l=()=>L.jsxs("div",{className:"flex items-center",children:[L.jsx(evt,{playbackControls:t.playbackControls,recordingSessionInfo:t.recordingSessionInfo,isPlaybackControlsDisabled:i,onDisableControlsAndChangePlaybackState:o,playbackErrorMessage:()=>s("Failed to stop recording","stop")}),L.jsx(tvt,{playbackControls:t.playbackControls,recordingSessionInfo:t.recordingSessionInfo,isPlaybackControlsDisabled:i,onDisableControlsAndChangePlaybackState:o,playbackErrorMessage:b=>s(`Failed to ${b} recording`,b)}),L.jsx(Qgt,{playbackControls:t.playbackControls,recordingSessionInfo:t.recordingSessionInfo,isPlaybackControlsDisabled:i,onDisableControlsAndChangePlaybackState:o,playbackErrorMessage:()=>s("Failed to set repeat","set repeat for")})]}),e[3]=i,e[4]=s,e[5]=t.playbackControls,e[6]=t.recordingSessionInfo,e[7]=l):l=e[7];const u=l;let c;e[8]===Symbol.for("react.memo_cache_sentinel")?(c={cursor:"default"},e[8]=c):c=e[8];let d;e[9]!==t.className?(d=yo("flex p-1 rounded-xs w-full","bg-blue-100 dark:bg-neutral-900 rounded-sm",t.className),e[9]=t.className,e[10]=d):d=e[10];let f;e[11]!==u?(f=L.jsx("div",{className:"shrink-0",children:u()}),e[11]=u,e[12]=f):f=e[12];let h;e[13]!==s?(h=()=>s("Failed to seek recording","seek in"),e[13]=s,e[14]=h):h=e[14];let p;e[15]!==i||e[16]!==t.playbackControls||e[17]!==t.recordingSessionInfo||e[18]!==h?(p=L.jsx("div",{className:"grow pl-3 pr-3 min-w-0",children:L.jsx(ibt,{playbackControls:t.playbackControls,recordingSessionInfo:t.recordingSessionInfo,isPlaybackControlsDisabled:i,onDisableControlsAndChangePlaybackState:o,playbackErrorMessage:h})}),e[15]=i,e[16]=t.playbackControls,e[17]=t.recordingSessionInfo,e[18]=h,e[19]=p):p=e[19];let g;e[20]!==f||e[21]!==p?(g=L.jsxs("div",{className:"flex items-center grow min-w-0",children:[f,p]}),e[20]=f,e[21]=p,e[22]=g):g=e[22];let v;e[23]!==s?(v=()=>s("Failed to close recording","close"),e[23]=s,e[24]=v):v=e[24];let y;e[25]!==t.onAfterClose||e[26]!==t.playbackControls||e[27]!==t.recordingSessionInfo||e[28]!==v?(y=L.jsx("div",{className:"shrink-0 flex items-start",children:L.jsx(rvt,{playbackControls:t.playbackControls,recordingSessionInfo:t.recordingSessionInfo,onAfterClose:t.onAfterClose,playbackErrorMessage:v})}),e[25]=t.onAfterClose,e[26]=t.playbackControls,e[27]=t.recordingSessionInfo,e[28]=v,e[29]=y):y=e[29];let m;return e[30]!==y||e[31]!==d||e[32]!==g?(m=L.jsx("div",{style:c,children:L.jsxs("div",{className:d,children:[g,y]})}),e[30]=y,e[31]=d,e[32]=g,e[33]=m):m=e[33],m}function obt(t){const e=qt.c(45),[i,n]=J.useState(!1);let r;e[0]!==i||e[1]!==t.recordingSessionPlaybacks?(r=async(G,H)=>{if(!i){n(!0);try{await Promise.all(t.recordingSessionPlaybacks.map(async U=>{try{await H(U)}catch(k){const X=k;console.error(`Failed to ${G} recording ${U.recordingSessionInfo.path}:`,X)}}))}catch{Ki.error(L.jsxs("div",{className:"text-left",children:[L.jsxs("p",{className:"font-bold m-0",children:["Failed to ",G," recordings"]}),L.jsxs("p",{className:"text-sm m-0",children:["There was an error trying to ",G," multiple recordings. If this keeps happening, you might have to reload the application."]})]}),{autoClose:1e4})}n(!1)}},e[0]=i,e[1]=t.recordingSessionPlaybacks,e[2]=r):r=e[2];const o=r;let a;e[3]!==o?(a=async()=>{await o("restart",cbt)},e[3]=o,e[4]=a):a=e[4];const s=a;let l;e[5]!==o||e[6]!==t.recordingSessionPlaybacks?(l=async()=>{t.recordingSessionPlaybacks.some(ubt)?await o("pause",lbt):await o("play",sbt)},e[5]=o,e[6]=t.recordingSessionPlaybacks,e[7]=l):l=e[7];const u=l,c=t.recordingSessionPlaybacks.some(abt),d=c?hLe:Yee,f=i?.6:1,h=i?"not-allowed":"pointer";let p;e[8]!==f||e[9]!==h?(p={opacity:f,cursor:h},e[8]=f,e[9]=h,e[10]=p):p=e[10];let g,v;e[11]!==s?(g=G=>{G.stopPropagation(),s()},v=G=>{(G.key==="Enter"||G.key===" ")&&(G.preventDefault(),G.stopPropagation(),s())},e[11]=s,e[12]=g,e[13]=v):(g=e[12],v=e[13]);let y;e[14]===Symbol.for("react.memo_cache_sentinel")?(y=yo("inline-flex items-center justify-center","p-0 mr-1","border-0 bg-transparent","text-remotive-primary-60","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),e[14]=y):y=e[14];let m;e[15]===Symbol.for("react.memo_cache_sentinel")?(m=L.jsx(pLe,{sx:{fontSize:24}}),e[15]=m):m=e[15];let b;e[16]!==p||e[17]!==g||e[18]!==v?(b=L.jsx("span",{title:"Restart all recordings from the beginning",role:"button",tabIndex:0,style:p,onClick:g,onKeyDown:v,className:y,children:m}),e[16]=p,e[17]=g,e[18]=v,e[19]=b):b=e[19];const S=`${c?"Pause":"Play"} all recordings`,_=i?.6:1,C=i?"not-allowed":"pointer";let P;e[20]!==_||e[21]!==C?(P={opacity:_,cursor:C},e[20]=_,e[21]=C,e[22]=P):P=e[22];let x,E;e[23]!==u?(x=G=>{G.stopPropagation(),u()},E=G=>{(G.key==="Enter"||G.key===" ")&&(G.preventDefault(),G.stopPropagation(),u())},e[23]=u,e[24]=x,e[25]=E):(x=e[24],E=e[25]);let A;e[26]===Symbol.for("react.memo_cache_sentinel")?(A=yo("inline-flex items-center justify-center","p-0 mr-1","border-0 bg-transparent","text-remotive-primary-60","focus:outline-none focus-visible:ring-2 focus-visible:ring-remotive-primary-60 focus-visible:ring-offset-1 rounded"),e[26]=A):A=e[26];let R;e[27]===Symbol.for("react.memo_cache_sentinel")?(R={fontSize:32},e[27]=R):R=e[27];let M;e[28]!==d?(M=L.jsx(d,{sx:R}),e[28]=d,e[29]=M):M=e[29];let D;e[30]!==S||e[31]!==P||e[32]!==x||e[33]!==E||e[34]!==M?(D=L.jsx("span",{title:S,role:"button",tabIndex:0,style:P,onClick:x,onKeyDown:E,className:A,children:M}),e[30]=S,e[31]=P,e[32]=x,e[33]=E,e[34]=M,e[35]=D):D=e[35];let F;e[36]!==t.recordingSessionPlaybacks.length?(F=L.jsxs("span",{className:"text-xs text-foreground dark:text-neutral-200",children:["You are using ",t.recordingSessionPlaybacks.length," recordings simultaneously"]}),e[36]=t.recordingSessionPlaybacks.length,e[37]=F):F=e[37];let I;e[38]===Symbol.for("react.memo_cache_sentinel")?(I=L.jsx("span",{className:"text-muted-foreground",style:{fontSize:"10px"},children:"Click to expand to see individual playback controls"}),e[38]=I):I=e[38];let V;e[39]!==F?(V=L.jsxs("div",{className:"flex flex-col text-left pl-2",children:[F,I]}),e[39]=F,e[40]=V):V=e[40];let z;return e[41]!==b||e[42]!==D||e[43]!==V?(z=L.jsxs("div",{className:"flex items-center ml-2",children:[b,D,V]}),e[41]=b,e[42]=D,e[43]=V,e[44]=z):z=e[44],z}function abt(t){return t.playbackControls.isPlaying}async function sbt(t){t.playbackControls.isPlaying||await t.playbackControls.play()}async function lbt(t){t.playbackControls.isPlaying&&await t.playbackControls.pause()}function ubt(t){return t.playbackControls.isPlaying}async function cbt(t){await t.playbackControls.restart()}const dbt=(t="",e="")=>L.jsxs("p",{className:"text-left m-0",children:[L.jsx("span",{className:"font-bold",children:t})," ",L.jsx("br",{})," ",L.jsx("span",{className:"text-sm",children:e})]});function eIe(t){const e=qt.c(50),{node:i,depth:n,selectedFiles:r,onFileSelect:o,expandAll:a}=t,[s,l]=J.useState(a);let u;if(e[0]!==i.path||e[1]!==r){let F;e[3]!==i.path?(F=I=>I.path===i.path,e[3]=i.path,e[4]=F):F=e[4],u=r.some(F),e[0]=i.path,e[1]=r,e[2]=u}else u=e[2];const c=u,d=i.type===ea.FILE_TYPE_RECORDING_SESSION&&!i.isDirectory,f=(n+1)*12;let h;e[5]!==s||e[6]!==d||e[7]!==c||e[8]!==i||e[9]!==o?(h=()=>{i.isDirectory?l(!s):d&&(c?Ki.warning(dbt("Already in playback",`Recording session ${i.name} is already in playback`),{autoClose:1e4}):o(i))},e[5]=s,e[6]=d,e[7]=c,e[8]=i,e[9]=o,e[10]=h):h=e[10];const p=h;let g;e[11]!==s||e[12]!==i.isDirectory||e[13]!==i.type?(g=()=>i.isDirectory?s?L.jsx(Act,{className:"text-remotive-primary-50",sx:{fontSize:18}}):L.jsx(Oct,{className:"text-remotive-primary-50",sx:{fontSize:18}}):i.type===ea.FILE_TYPE_RECORDING_SESSION?L.jsx(Yee,{className:"text-remotive-primary-50",sx:{fontSize:18}}):L.jsx(wct,{className:"text-remotive-primary-50",sx:{fontSize:18}}),e[11]=s,e[12]=i.isDirectory,e[13]=i.type,e[14]=g):g=e[14];const v=g;let y;e[15]!==s||e[16]!==i.isDirectory?(y=()=>i.isDirectory?s?L.jsx(fLe,{sx:{fontSize:16},className:"text-gray-500"}):L.jsx(xct,{sx:{fontSize:16},className:"text-gray-500"}):null,e[15]=s,e[16]=i.isDirectory,e[17]=y):y=e[17];const m=y,b=d||i.isDirectory?"cursor-pointer hover:bg-black/10 dark:hover:bg-white/20":"cursor-default";let S;e[18]!==b?(S=yo("flex items-center py-1 rounded pr-2 mb-0.5","transition-colors duration-100",b),e[18]=b,e[19]=S):S=e[19];let _;e[20]!==f?(_={marginLeft:f},e[20]=f,e[21]=_):_=e[21];let C;e[22]!==m?(C=m(),e[22]=m,e[23]=C):C=e[23];let P;e[24]!==C?(P=L.jsx("div",{className:"flex items-center shrink-0 mr-1 w-4",children:C}),e[24]=C,e[25]=P):P=e[25];let x;e[26]!==v?(x=L.jsx("div",{className:"mr-2",children:v()}),e[26]=v,e[27]=x):x=e[27];let E;e[28]!==i.name?(E=L.jsx("div",{className:"grow min-w-0",children:L.jsx("p",{className:"m-0 text-sm truncate text-foreground dark:text-neutral-200",title:i.name,children:i.name})}),e[28]=i.name,e[29]=E):E=e[29];let A;e[30]!==c?(A=c&&L.jsx("div",{className:"ml-2",children:L.jsx("span",{className:"text-xs text-muted-foreground",children:"Already open"})}),e[30]=c,e[31]=A):A=e[31];let R;e[32]!==p||e[33]!==x||e[34]!==E||e[35]!==A||e[36]!==S||e[37]!==_||e[38]!==P?(R=L.jsxs("div",{className:S,style:_,onClick:p,children:[P,x,E,A]}),e[32]=p,e[33]=x,e[34]=E,e[35]=A,e[36]=S,e[37]=_,e[38]=P,e[39]=R):R=e[39];let M;e[40]!==n||e[41]!==a||e[42]!==s||e[43]!==i||e[44]!==o||e[45]!==r?(M=i.isDirectory&&s&&"files"in i&&L.jsx("div",{children:i.files.map(F=>L.jsx(eIe,{expandAll:a,node:F,depth:n+1,selectedFiles:r,onFileSelect:o},F.path))}),e[40]=n,e[41]=a,e[42]=s,e[43]=i,e[44]=o,e[45]=r,e[46]=M):M=e[46];let D;return e[47]!==R||e[48]!==M?(D=L.jsxs(L.Fragment,{children:[R,M]}),e[47]=R,e[48]=M,e[49]=D):D=e[49],D}const fbt=(t="",e)=>L.jsxs(L.Fragment,{children:[L.jsx("p",{className:"text-left m-0 mb-1 font-bold",children:t}),L.jsx(L.Fragment,{children:e})]});function hbt(t){const[e,i]=J.useState(!1),n=()=>{t.handleCloseFunction()},r=async s=>{if(e)return;const l=(u,c)=>{Ki.error(fbt("Failed to open",L.jsxs("div",{className:"text-left flex flex-col gap-1",children:[L.jsxs("p",{className:"mb-2 text-sm",children:["Could not open recording session ",L.jsx("span",{className:"font-bold",children:u}),"."]}),L.jsx("p",{className:"m-0 text-left text-sm",children:c.message})]})))};i(!0);try{await t.open(s.path),n(),t.onAfterSelect(s.path)}catch(u){l(s.path,u instanceof Error?u:new Error(String(u)))}finally{i(!1)}},a=((s,l)=>{const u=[],c=d=>{l.includes(d.path)&&u.push(d),d.isDirectory&&"files"in d&&d.files&&d.files.forEach(c)};return s.forEach(c),u})(t.fileTree,t.playingFilePaths);return t.show?L.jsx(yI,{show:t.show,onClose:n,size:"2xl",showCloseButton:!0,className:"flex flex-col max-h-[90vh]",children:L.jsxs("div",{className:"p-5 flex flex-col min-h-0 flex-1",children:[L.jsx("h3",{className:"text-sm font-medium mb-2",children:"Open recording"}),L.jsx("p",{className:"mb-1 text-muted-foreground text-xs",children:"Available recording sessions:"}),L.jsx("div",{className:yo("rounded-md p-2 flex-1 min-h-0 overflow-y-auto","bg-neutral-100 dark:bg-neutral-800 m"),children:t.fileTree.length===0?L.jsx("div",{className:"text-center py-4",children:L.jsx("p",{className:"text-muted-foreground m-0",children:"No files available"})}):t.fileTree.map(s=>L.jsx(eIe,{expandAll:t.expandAll,node:s,depth:0,selectedFiles:a,onFileSelect:r},s.path))}),L.jsx("div",{className:"flex justify-end gap-2 mt-4 flex-shrink-0",children:L.jsx(Za,{type:fn.PRIMARY,size:_a.MD,label:"Cancel",onClick:n})})]})}):null}function pbt(t){const e=qt.c(26),{fileTree:i,open:n}=Jke(),r=pte(),[o,a]=J.useState(r.length>0);let s,l,u;if(e[0]===Symbol.for("react.memo_cache_sentinel")){l=(P,x)=>L.jsx("div",{className:"grow min-w-0",children:P.map((E,A)=>L.jsx("div",{className:P.length>1&&A!==P.length-1?"mb-1 mx-1":" mx-1",children:L.jsx(nbt,{className:x,recordingSessionInfo:E.recordingSessionInfo,playbackControls:E.playbackControls,onAfterClose:()=>{P.length<=2&&C(150)}})},E.recordingSessionInfo.path))}),s=ybt;const C=async P=>{const x=P;await new Promise(E=>setTimeout(E,x)),a(!1)};u=async P=>{const x=P===void 0?0:P;await new Promise(E=>setTimeout(E,x)),a(!0)},e[0]=s,e[1]=l,e[2]=u}else s=e[0],l=e[1],u=e[2];const c=u;let d;e[3]!==o?(d=()=>{a(!o)},e[3]=o,e[4]=d):d=e[4];const f=d,h=t.showFileTreeModal;let p;e[5]!==r?(p=r.map(vbt).filter(gbt),e[5]=r,e[6]=p):p=e[6];let g;e[7]!==t||e[8]!==r.length?(g=C=>{var P;(P=t.onRecordingSessionOpened)==null||P.call(t,C),r.length>=1&&c(350)},e[7]=t,e[8]=r.length,e[9]=g):g=e[9];let v;e[10]!==t?(v=()=>{t.setShowFileTreeModal(!1)},e[10]=t,e[11]=v):v=e[11];let y;e[12]!==i||e[13]!==n||e[14]!==t.showFileTreeModal||e[15]!==p||e[16]!==g||e[17]!==v?(y=L.jsx(hbt,{expandAll:!0,fileTree:i,show:h,playingFilePaths:p,open:n,onAfterSelect:g,handleCloseFunction:v}),e[12]=i,e[13]=n,e[14]=t.showFileTreeModal,e[15]=p,e[16]=g,e[17]=v,e[18]=y):y=e[18];const m=y;if(r.length===0)return m;let b;e[19]!==m?(b=C=>L.jsxs(L.Fragment,{children:[L.jsx("div",{className:"my-1",id:"maincard-container-id-tw",children:L.jsx("div",{className:"col-12 p-0",children:L.jsx("div",{className:"p-0",id:"maincard-container-card-id-tw",children:L.jsx("div",{className:"row m-0 p-0 mb-0 flex ",children:L.jsx("div",{className:"flex flex-col p-0 m-0 w-full mx-1",id:"playback-controls-card-container-tw",children:L.jsx("div",{className:"border-0",id:"playback-controls-card-tw",children:L.jsx("div",{className:"p-0 m-0",children:L.jsx("div",{className:"w-full",children:L.jsx("div",{className:"bg-[var(--primary-10)] rounded-sm",children:C})})})})})})})})}),m]}),e[19]=m,e[20]=b):b=e[20];const S=b;let _;return e[21]!==S||e[22]!==o||e[23]!==r||e[24]!==f?(_=r.length===1?S(L.jsx("div",{className:"py-1",children:l(r,"bg-transparent dark:bg-transparent")})):S(L.jsxs(L.Fragment,{children:[L.jsxs("button",{onClick:f,className:yo("flex items-center w-full py-1","bg-transparent border-0","cursor-pointer"),children:[L.jsx("div",{className:"flex grow flex-wrap-reverse text-foreground dark:text-neutral-200 mr-2 gap-x-1 gap-y-2 min-w-0",children:L.jsx("div",{className:"grow self-center min-w-0",style:{flexBasis:"350px"},children:s(r)})}),L.jsx(fLe,{className:yo("text-muted-foreground transition-transform duration-200 me-1 hover:bg-accent rounded-sm",o&&"rotate-180"),sx:{fontSize:24}})]}),L.jsx("div",{className:yo("overflow-hidden transition-all duration-300 ease-in-out",o?"max-h-[1000px] opacity-100":"max-h-0 opacity-0"),children:L.jsx("div",{className:"px-0 pt-0 pb-1 flex content-start",children:l(r)})})]})),e[21]=S,e[22]=o,e[23]=r,e[24]=f,e[25]=_):_=e[25],_}function gbt(t){return t!==void 0}function vbt(t){return t.recordingSessionInfo.path}function ybt(t){return L.jsx(obt,{recordingSessionPlaybacks:t})}function mbt(t){const e=qt.c(42),[i,n]=J.useState(),[r,o]=J.useState(),a=pte();let s;e[0]!==a?(s=new Set(a.flatMap(Sbt).map(bbt)),e[0]=a,e[1]=s):s=e[1];let l;e[2]!==s?(l=[...s],e[2]=s,e[3]=l):l=e[3];const u=l;let c;e[4]!==a||e[5]!==i?(c=i?a.filter(F=>F.recordingSessionInfo.videos.some(I=>I.name===i)):[],e[4]=a,e[5]=i,e[6]=c):c=e[6];const d=c,f=d.length===1?d[0]:r;let h;e[7]!==(f==null?void 0:f.recordingSessionInfo.videos)||e[8]!==i?(h=f==null?void 0:f.recordingSessionInfo.videos.find(F=>F.name===i),e[7]=f==null?void 0:f.recordingSessionInfo.videos,e[8]=i,e[9]=h):h=e[9];const p=h;let g;e[10]===Symbol.for("react.memo_cache_sentinel")?(g=F=>{n(F),o(void 0)},e[10]=g):g=e[10];const v=g;let y;e[11]!==t?(y=()=>{n(void 0),o(void 0),t.handleCloseFunction()},e[11]=t,e[12]=y):y=e[12];const m=y;let b;e[13]!==m||e[14]!==f||e[15]!==t||e[16]!==p?(b=()=>{if(!p||!f)return;const F={videoFilePath:p.location,videoName:p.name,recordingSessionPath:f.recordingSessionInfo.path};t.savePanelFunction(p.location,F),m()},e[13]=m,e[14]=f,e[15]=t,e[16]=p,e[17]=b):b=e[17];const S=b;if(!t.show)return null;const _=a.length>0?"Select video to play":"No open recording sessions";let C;e[18]!==_?(C=L.jsx("h3",{className:"text-sm font-medium mb-4",children:_}),e[18]=_,e[19]=C):C=e[19];let P;e[20]!==u||e[21]!==(f==null?void 0:f.recordingSessionInfo)||e[22]!==d||e[23]!==a.length||e[24]!==i?(P=a.length>0?L.jsxs("div",{className:"space-y-4",children:[L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx("span",{className:"text-sm font-medium w-24 text-foreground dark:text-neutral-200",children:"Video"}),L.jsxs(Ik,{children:[L.jsx(Nk,{asChild:!0,children:L.jsxs("button",{className:yo("w-full flex items-center justify-between px-3 py-2","bg-transparent text-foreground dark:text-neutral-200","border border-neutral-300 dark:border-neutral-600","rounded text-sm text-left","hover:border-neutral-400 dark:hover:border-neutral-500","truncate data-[state=open]:border-neutral-400 dark:data-[state=open]:border-neutral-500"),children:[L.jsx("span",{className:"truncate",children:i??"Select video..."}),L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"w-4 h-4 ml-2 flex-shrink-0"})]})}),L.jsx(AD,{children:L.jsx(Fk,{align:"start",sideOffset:4,className:yo("z-[10002] min-w-[var(--radix-dropdown-menu-trigger-width)] max-w-[var(--radix-dropdown-menu-trigger-width)]","bg-popover border border-border rounded-md shadow-lg p-1","max-h-60 overflow-y-auto","animate-in fade-in-0 zoom-in-95"),children:u.map(F=>L.jsx(dm,{onSelect:()=>v(F),className:yo("px-3 py-2 text-sm cursor-pointer outline-none","text-popover-foreground rounded-sm truncate","data-[highlighted]:bg-muted"),children:F},F))})})]})]}),i&&d.length>1&&L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx("span",{className:"text-sm font-medium w-24 text-foreground dark:text-neutral-200",children:"Recording"}),L.jsxs(Ik,{children:[L.jsx(Nk,{asChild:!0,children:L.jsxs("button",{className:yo("w-full flex items-center justify-between px-3 py-2","bg-transparent text-foreground dark:text-neutral-200","border border-neutral-300 dark:border-neutral-600","rounded text-sm text-left","hover:border-neutral-400 dark:hover:border-neutral-500","truncate data-[state=open]:border-neutral-400 dark:data-[state=open]:border-neutral-500"),children:[L.jsx("span",{className:"truncate",children:(f==null?void 0:f.recordingSessionInfo.path)??"Select recording..."}),L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"w-4 h-4 ml-2 flex-shrink-0"})]})}),L.jsx(AD,{children:L.jsx(Fk,{align:"start",sideOffset:4,className:yo("z-[10002] min-w-[var(--radix-dropdown-menu-trigger-width)] max-w-[var(--radix-dropdown-menu-trigger-width)]","bg-popover border border-border rounded-md shadow-lg p-1","max-h-60 overflow-y-auto","animate-in fade-in-0 zoom-in-95"),children:d.map(F=>L.jsx(dm,{onSelect:()=>o(F),className:yo("px-3 py-2 text-sm cursor-pointer outline-none","text-popover-foreground rounded-sm truncate","data-[highlighted]:bg-muted"),children:F.recordingSessionInfo.path},F.recordingSessionInfo.path))})})]})]}),i&&d.length===1&&L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx("span",{className:"text-sm font-medium w-24 text-foreground dark:text-neutral-200",children:"Recording"}),L.jsx("span",{className:"text-sm text-foreground dark:text-neutral-200 truncate",children:d[0].recordingSessionInfo.path})]})]}):L.jsx("p",{className:"text-sm text-muted-foreground",children:"To view available videos, open a recording session that contains videos first."}),e[20]=u,e[21]=f==null?void 0:f.recordingSessionInfo,e[22]=d,e[23]=a.length,e[24]=i,e[25]=P):P=e[25];let x;e[26]!==m?(x=L.jsx(Za,{type:fn.PRIMARY,size:_a.MD,label:"Cancel",onClick:m}),e[26]=m,e[27]=x):x=e[27];const E=!p||!f;let A;e[28]!==S||e[29]!==E?(A=L.jsx(Za,{type:fn.SUCCESS,size:_a.MD,label:"Apply",onClick:S,disabled:E}),e[28]=S,e[29]=E,e[30]=A):A=e[30];let R;e[31]!==x||e[32]!==A?(R=L.jsxs("div",{className:"flex justify-end gap-2 mt-4",children:[x,A]}),e[31]=x,e[32]=A,e[33]=R):R=e[33];let M;e[34]!==R||e[35]!==C||e[36]!==P?(M=L.jsxs("div",{className:"p-5",children:[C,P,R]}),e[34]=R,e[35]=C,e[36]=P,e[37]=M):M=e[37];let D;return e[38]!==m||e[39]!==t.show||e[40]!==M?(D=L.jsx(yI,{show:t.show,onClose:m,size:"2xl",showCloseButton:!0,children:M}),e[38]=m,e[39]=t.show,e[40]=M,e[41]=D):D=e[41],D}function bbt(t){return t.name}function Sbt(t){return t.recordingSessionInfo.videos}var DY,gce;function V6(){if(gce)return DY;gce=1;var t;return typeof window<"u"?t=window:typeof xp<"u"?t=xp:typeof self<"u"?t=self:t={},DY=t,DY}var _bt=V6();const Ct=wc(_bt),Pbt={},Cbt=Object.freeze(Object.defineProperty({__proto__:null,default:Pbt},Symbol.toStringTag,{value:"Module"})),Tbt=RS(Cbt);var RY,vce;function tIe(){if(vce)return RY;vce=1;var t=typeof xp<"u"?xp:typeof window<"u"?window:{},e=Tbt,i;return typeof document<"u"?i=document:(i=t["__GLOBAL_DOCUMENT_CACHE@4"],i||(i=t["__GLOBAL_DOCUMENT_CACHE@4"]=e)),RY=i,RY}var xbt=tIe();const $r=wc(xbt);var p4={exports:{}},yce;function Ebt(){return yce||(yce=1,(function(t,e){function i(l){if(l&&typeof l=="object"){var u=l.which||l.keyCode||l.charCode;u&&(l=u)}if(typeof l=="number")return a[l];var c=String(l),d=n[c.toLowerCase()];if(d)return d;var d=r[c.toLowerCase()];if(d)return d;if(c.length===1)return c.charCodeAt(0)}i.isEventKey=function(u,c){if(u&&typeof u=="object"){var d=u.which||u.keyCode||u.charCode;if(d==null)return!1;if(typeof c=="string"){var f=n[c.toLowerCase()];if(f)return f===d;var f=r[c.toLowerCase()];if(f)return f===d}else if(typeof c=="number")return c===d;return!1}},e=t.exports=i;var n=e.code=e.codes={backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,"pause/break":19,"caps lock":20,esc:27,space:32,"page up":33,"page down":34,end:35,home:36,left:37,up:38,right:39,down:40,insert:45,delete:46,command:91,"left command":91,"right command":93,"numpad *":106,"numpad +":107,"numpad -":109,"numpad .":110,"numpad /":111,"num lock":144,"scroll lock":145,"my computer":182,"my calculator":183,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222},r=e.aliases={windows:91,"⇧":16,"⌥":18,"⌃":17,"⌘":91,ctl:17,control:17,option:18,pause:19,break:19,caps:20,return:13,escape:27,spc:32,spacebar:32,pgup:33,pgdn:34,ins:45,del:46,cmd:91};/*!
 * Programatically add the following
 */for(o=97;o<123;o++)n[String.fromCharCode(o)]=o-32;for(var o=48;o<58;o++)n[o-48]=o;for(o=1;o<13;o++)n["f"+o]=o+111;for(o=0;o<10;o++)n["numpad "+o]=o+96;var a=e.names=e.title={};for(o in n)a[n[o]]=o;for(var s in r)n[s]=r[s]})(p4,p4.exports)),p4.exports}var wbt=Ebt();const On=wc(wbt);function bn(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Wk(t,e){return Wk=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(i,n){return i.__proto__=n,i},Wk(t,e)}function qr(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,Wk(t,e)}var MY,mce;function Abt(){if(mce)return MY;mce=1,MY=t;function t(e,i){var n,r=null;try{n=JSON.parse(e,i)}catch(o){r=o}return[r,n]}return MY}var Obt=Abt();const Dbt=wc(Obt);var g4={exports:{}},LY,bce;function Rbt(){if(bce)return LY;bce=1,LY=e;var t=Object.prototype.toString;function e(i){if(!i)return!1;var n=t.call(i);return n==="[object Function]"||typeof i=="function"&&n!=="[object RegExp]"||typeof window<"u"&&(i===window.setTimeout||i===window.alert||i===window.confirm||i===window.prompt)}return LY}var kY,Sce;function Mbt(){if(Sce)return kY;Sce=1;var t=V6(),e=function(r,o){return o===void 0&&(o=!1),function(a,s,l){if(a){r(a);return}if(s.statusCode>=400&&s.statusCode<=599){var u=l;if(o)if(t.TextDecoder){var c=i(s.headers&&s.headers["content-type"]);try{u=new TextDecoder(c).decode(l)}catch{}}else u=String.fromCharCode.apply(null,new Uint8Array(l));r({cause:u});return}r(null,l)}};function i(n){return n===void 0&&(n=""),n.toLowerCase().split(";").reduce(function(r,o){var a=o.split("="),s=a[0],l=a[1];return s.trim()==="charset"?l.trim():r},"utf-8")}return kY=e,kY}var _ce;function Lbt(){if(_ce)return g4.exports;_ce=1;var t=V6(),e=zMe(),i=Rbt();s.httpHandler=Mbt();/**
 * @license
 * slighly modified parse-headers 2.0.2 <https://github.com/kesla/parse-headers/>
 * Copyright (c) 2014 David Björklund
 * Available under the MIT license
 * <https://github.com/kesla/parse-headers/blob/master/LICENCE>
 */var n=function(f){var h={};return f&&f.trim().split(`
`).forEach(function(p){var g=p.indexOf(":"),v=p.slice(0,g).trim().toLowerCase(),y=p.slice(g+1).trim();typeof h[v]>"u"?h[v]=y:Array.isArray(h[v])?h[v].push(y):h[v]=[h[v],y]}),h};g4.exports=s,g4.exports.default=s,s.XMLHttpRequest=t.XMLHttpRequest||c,s.XDomainRequest="withCredentials"in new s.XMLHttpRequest?s.XMLHttpRequest:t.XDomainRequest,r(["get","put","post","patch","head","delete"],function(d){s[d==="delete"?"del":d]=function(f,h,p){return h=a(f,h,p),h.method=d.toUpperCase(),l(h)}});function r(d,f){for(var h=0;h<d.length;h++)f(d[h])}function o(d){for(var f in d)if(d.hasOwnProperty(f))return!1;return!0}function a(d,f,h){var p=d;return i(f)?(h=f,typeof d=="string"&&(p={uri:d})):p=e({},f,{uri:d}),p.callback=h,p}function s(d,f,h){return f=a(d,f,h),l(f)}function l(d){if(typeof d.callback>"u")throw new Error("callback argument missing");var f=!1,h=function(F,I,V){f||(f=!0,d.callback(F,I,V))};function p(){m.readyState===4&&setTimeout(y,0)}function g(){var D=void 0;if(m.response?D=m.response:D=m.responseText||u(m),A)try{D=JSON.parse(D)}catch{}return D}function v(D){return clearTimeout(R),D instanceof Error||(D=new Error(""+(D||"Unknown XMLHttpRequest Error"))),D.statusCode=0,h(D,M)}function y(){if(!S){var D;clearTimeout(R),d.useXDR&&m.status===void 0?D=200:D=m.status===1223?204:m.status;var F=M,I=null;return D!==0?(F={body:g(),statusCode:D,method:C,headers:{},url:_,rawRequest:m},m.getAllResponseHeaders&&(F.headers=n(m.getAllResponseHeaders()))):I=new Error("Internal XMLHttpRequest Error"),h(I,F,F.body)}}var m=d.xhr||null;m||(d.cors||d.useXDR?m=new s.XDomainRequest:m=new s.XMLHttpRequest);var b,S,_=m.url=d.uri||d.url,C=m.method=d.method||"GET",P=d.body||d.data,x=m.headers=d.headers||{},E=!!d.sync,A=!1,R,M={body:void 0,headers:{},statusCode:0,method:C,url:_,rawRequest:m};if("json"in d&&d.json!==!1&&(A=!0,x.accept||x.Accept||(x.Accept="application/json"),C!=="GET"&&C!=="HEAD"&&(x["content-type"]||x["Content-Type"]||(x["Content-Type"]="application/json"),P=JSON.stringify(d.json===!0?P:d.json))),m.onreadystatechange=p,m.onload=y,m.onerror=v,m.onprogress=function(){},m.onabort=function(){S=!0},m.ontimeout=v,m.open(C,_,!E,d.username,d.password),E||(m.withCredentials=!!d.withCredentials),!E&&d.timeout>0&&(R=setTimeout(function(){if(!S){S=!0,m.abort("timeout");var D=new Error("XMLHttpRequest timeout");D.code="ETIMEDOUT",v(D)}},d.timeout)),m.setRequestHeader)for(b in x)x.hasOwnProperty(b)&&m.setRequestHeader(b,x[b]);else if(d.headers&&!o(d.headers))throw new Error("Headers cannot be set on an XDomainRequest object");return"responseType"in d&&(m.responseType=d.responseType),"beforeSend"in d&&typeof d.beforeSend=="function"&&d.beforeSend(m),m.send(P||null),m}function u(d){try{if(d.responseType==="document")return d.responseXML;var f=d.responseXML&&d.responseXML.documentElement.nodeName==="parsererror";if(d.responseType===""&&!f)return d.responseXML}catch{}return null}function c(){}return g4.exports}var kbt=Lbt();const rIe=wc(kbt);var IY={exports:{}},NY,Pce;function Ibt(){if(Pce)return NY;Pce=1;var t=tIe(),e=Object.create||(function(){function E(){}return function(A){if(arguments.length!==1)throw new Error("Object.create shim only accepts one parameter.");return E.prototype=A,new E}})();function i(E,A){this.name="ParsingError",this.code=E.code,this.message=A||E.message}i.prototype=e(Error.prototype),i.prototype.constructor=i,i.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}};function n(E){function A(M,D,F,I){return(M|0)*3600+(D|0)*60+(F|0)+(I|0)/1e3}var R=E.match(/^(\d+):(\d{1,2})(:\d{1,2})?\.(\d{3})/);return R?R[3]?A(R[1],R[2],R[3].replace(":",""),R[4]):R[1]>59?A(R[1],R[2],0,R[4]):A(0,R[1],R[2],R[4]):null}function r(){this.values=e(null)}r.prototype={set:function(E,A){!this.get(E)&&A!==""&&(this.values[E]=A)},get:function(E,A,R){return R?this.has(E)?this.values[E]:A[R]:this.has(E)?this.values[E]:A},has:function(E){return E in this.values},alt:function(E,A,R){for(var M=0;M<R.length;++M)if(A===R[M]){this.set(E,A);break}},integer:function(E,A){/^-?\d+$/.test(A)&&this.set(E,parseInt(A,10))},percent:function(E,A){return A.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(A=parseFloat(A),A>=0&&A<=100)?(this.set(E,A),!0):!1}};function o(E,A,R,M){var D=M?E.split(M):[E];for(var F in D)if(typeof D[F]=="string"){var I=D[F].split(R);if(I.length===2){var V=I[0].trim(),z=I[1].trim();A(V,z)}}}function a(E,A,R){var M=E;function D(){var V=n(E);if(V===null)throw new i(i.Errors.BadTimeStamp,"Malformed timestamp: "+M);return E=E.replace(/^[^\sa-zA-Z-]+/,""),V}function F(V,z){var G=new r;o(V,function(H,U){switch(H){case"region":for(var k=R.length-1;k>=0;k--)if(R[k].id===U){G.set(H,R[k].region);break}break;case"vertical":G.alt(H,U,["rl","lr"]);break;case"line":var X=U.split(","),W=X[0];G.integer(H,W),G.percent(H,W)&&G.set("snapToLines",!1),G.alt(H,W,["auto"]),X.length===2&&G.alt("lineAlign",X[1],["start","center","end"]);break;case"position":X=U.split(","),G.percent(H,X[0]),X.length===2&&G.alt("positionAlign",X[1],["start","center","end"]);break;case"size":G.percent(H,U);break;case"align":G.alt(H,U,["start","center","end","left","right"]);break}},/:/,/\s/),z.region=G.get("region",null),z.vertical=G.get("vertical","");try{z.line=G.get("line","auto")}catch{}z.lineAlign=G.get("lineAlign","start"),z.snapToLines=G.get("snapToLines",!0),z.size=G.get("size",100);try{z.align=G.get("align","center")}catch{z.align=G.get("align","middle")}try{z.position=G.get("position","auto")}catch{z.position=G.get("position",{start:0,left:0,center:50,middle:50,end:100,right:100},z.align)}z.positionAlign=G.get("positionAlign",{start:"start",left:"start",center:"center",middle:"center",end:"end",right:"end"},z.align)}function I(){E=E.replace(/^\s+/,"")}if(I(),A.startTime=D(),I(),E.substr(0,3)!=="-->")throw new i(i.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '-->'): "+M);E=E.substr(3),I(),A.endTime=D(),I(),F(E,A)}var s=t.createElement&&t.createElement("textarea"),l={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},u={white:"rgba(255,255,255,1)",lime:"rgba(0,255,0,1)",cyan:"rgba(0,255,255,1)",red:"rgba(255,0,0,1)",yellow:"rgba(255,255,0,1)",magenta:"rgba(255,0,255,1)",blue:"rgba(0,0,255,1)",black:"rgba(0,0,0,1)"},c={v:"title",lang:"lang"},d={rt:"ruby"};function f(E,A){function R(){if(!A)return null;function W(te){return A=A.substr(te.length),te}var Y=A.match(/^([^<]*)(<[^>]*>?)?/);return W(Y[1]?Y[1]:Y[2])}function M(W){return s.innerHTML=W,W=s.textContent,s.textContent="",W}function D(W,Y){return!d[Y.localName]||d[Y.localName]===W.localName}function F(W,Y){var te=l[W];if(!te)return null;var oe=E.document.createElement(te),de=c[W];return de&&Y&&(oe[de]=Y.trim()),oe}for(var I=E.document.createElement("div"),V=I,z,G=[];(z=R())!==null;){if(z[0]==="<"){if(z[1]==="/"){G.length&&G[G.length-1]===z.substr(2).replace(">","")&&(G.pop(),V=V.parentNode);continue}var H=n(z.substr(1,z.length-2)),U;if(H){U=E.document.createProcessingInstruction("timestamp",H),V.appendChild(U);continue}var k=z.match(/^<([^.\s/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!k||(U=F(k[1],k[3]),!U)||!D(V,U))continue;if(k[2]){var X=k[2].split(".");X.forEach(function(W){var Y=/^bg_/.test(W),te=Y?W.slice(3):W;if(u.hasOwnProperty(te)){var oe=Y?"background-color":"color",de=u[te];U.style[oe]=de}}),U.className=X.join(" ")}G.push(k[1]),V.appendChild(U),V=U;continue}V.appendChild(E.document.createTextNode(M(z)))}return I}var h=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];function p(E){for(var A=0;A<h.length;A++){var R=h[A];if(E>=R[0]&&E<=R[1])return!0}return!1}function g(E){var A=[],R="",M;if(!E||!E.childNodes)return"ltr";function D(V,z){for(var G=z.childNodes.length-1;G>=0;G--)V.push(z.childNodes[G])}function F(V){if(!V||!V.length)return null;var z=V.pop(),G=z.textContent||z.innerText;if(G){var H=G.match(/^.*(\n|\r)/);return H?(V.length=0,H[0]):G}if(z.tagName==="ruby")return F(V);if(z.childNodes)return D(V,z),F(V)}for(D(A,E);R=F(A);)for(var I=0;I<R.length;I++)if(M=R.charCodeAt(I),p(M))return"rtl";return"ltr"}function v(E){if(typeof E.line=="number"&&(E.snapToLines||E.line>=0&&E.line<=100))return E.line;if(!E.track||!E.track.textTrackList||!E.track.textTrackList.mediaElement)return-1;for(var A=E.track,R=A.textTrackList,M=0,D=0;D<R.length&&R[D]!==A;D++)R[D].mode==="showing"&&M++;return++M*-1}function y(){}y.prototype.applyStyles=function(E,A){A=A||this.div;for(var R in E)E.hasOwnProperty(R)&&(A.style[R]=E[R])},y.prototype.formatStyle=function(E,A){return E===0?0:E+A};function m(E,A,R){y.call(this),this.cue=A,this.cueDiv=f(E,A.text);var M={color:"rgba(255, 255, 255, 1)",backgroundColor:"rgba(0, 0, 0, 0.8)",position:"relative",left:0,right:0,top:0,bottom:0,display:"inline",writingMode:A.vertical===""?"horizontal-tb":A.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext"};this.applyStyles(M,this.cueDiv),this.div=E.document.createElement("div"),M={direction:g(this.cueDiv),writingMode:A.vertical===""?"horizontal-tb":A.vertical==="lr"?"vertical-lr":"vertical-rl",unicodeBidi:"plaintext",textAlign:A.align==="middle"?"center":A.align,font:R.font,whiteSpace:"pre-line",position:"absolute"},this.applyStyles(M),this.div.appendChild(this.cueDiv);var D=0;switch(A.positionAlign){case"start":case"line-left":D=A.position;break;case"center":D=A.position-A.size/2;break;case"end":case"line-right":D=A.position-A.size;break}A.vertical===""?this.applyStyles({left:this.formatStyle(D,"%"),width:this.formatStyle(A.size,"%")}):this.applyStyles({top:this.formatStyle(D,"%"),height:this.formatStyle(A.size,"%")}),this.move=function(F){this.applyStyles({top:this.formatStyle(F.top,"px"),bottom:this.formatStyle(F.bottom,"px"),left:this.formatStyle(F.left,"px"),right:this.formatStyle(F.right,"px"),height:this.formatStyle(F.height,"px"),width:this.formatStyle(F.width,"px")})}}m.prototype=e(y.prototype),m.prototype.constructor=m;function b(E){var A,R,M,D;if(E.div){R=E.div.offsetHeight,M=E.div.offsetWidth,D=E.div.offsetTop;var F=(F=E.div.childNodes)&&(F=F[0])&&F.getClientRects&&F.getClientRects();E=E.div.getBoundingClientRect(),A=F?Math.max(F[0]&&F[0].height||0,E.height/F.length):0}this.left=E.left,this.right=E.right,this.top=E.top||D,this.height=E.height||R,this.bottom=E.bottom||D+(E.height||R),this.width=E.width||M,this.lineHeight=A!==void 0?A:E.lineHeight}b.prototype.move=function(E,A){switch(A=A!==void 0?A:this.lineHeight,E){case"+x":this.left+=A,this.right+=A;break;case"-x":this.left-=A,this.right-=A;break;case"+y":this.top+=A,this.bottom+=A;break;case"-y":this.top-=A,this.bottom-=A;break}},b.prototype.overlaps=function(E){return this.left<E.right&&this.right>E.left&&this.top<E.bottom&&this.bottom>E.top},b.prototype.overlapsAny=function(E){for(var A=0;A<E.length;A++)if(this.overlaps(E[A]))return!0;return!1},b.prototype.within=function(E){return this.top>=E.top&&this.bottom<=E.bottom&&this.left>=E.left&&this.right<=E.right},b.prototype.overlapsOppositeAxis=function(E,A){switch(A){case"+x":return this.left<E.left;case"-x":return this.right>E.right;case"+y":return this.top<E.top;case"-y":return this.bottom>E.bottom}},b.prototype.intersectPercentage=function(E){var A=Math.max(0,Math.min(this.right,E.right)-Math.max(this.left,E.left)),R=Math.max(0,Math.min(this.bottom,E.bottom)-Math.max(this.top,E.top)),M=A*R;return M/(this.height*this.width)},b.prototype.toCSSCompatValues=function(E){return{top:this.top-E.top,bottom:E.bottom-this.bottom,left:this.left-E.left,right:E.right-this.right,height:this.height,width:this.width}},b.getSimpleBoxPosition=function(E){var A=E.div?E.div.offsetHeight:E.tagName?E.offsetHeight:0,R=E.div?E.div.offsetWidth:E.tagName?E.offsetWidth:0,M=E.div?E.div.offsetTop:E.tagName?E.offsetTop:0;E=E.div?E.div.getBoundingClientRect():E.tagName?E.getBoundingClientRect():E;var D={left:E.left,right:E.right,top:E.top||M,height:E.height||A,bottom:E.bottom||M+(E.height||A),width:E.width||R};return D};function S(E,A,R,M){function D(te,oe){for(var de,ge=new b(te),Ee=1,Re=0;Re<oe.length;Re++){for(;te.overlapsOppositeAxis(R,oe[Re])||te.within(R)&&te.overlapsAny(M);)te.move(oe[Re]);if(te.within(R))return te;var Ae=te.intersectPercentage(R);Ee>Ae&&(de=new b(te),Ee=Ae),te=new b(ge)}return de||ge}var F=new b(A),I=A.cue,V=v(I),z=[];if(I.snapToLines){var G;switch(I.vertical){case"":z=["+y","-y"],G="height";break;case"rl":z=["+x","-x"],G="width";break;case"lr":z=["-x","+x"],G="width";break}var H=F.lineHeight,U=H*Math.round(V),k=R[G]+H,X=z[0];Math.abs(U)>k&&(U=U<0?-1:1,U*=Math.ceil(k/H)*H),V<0&&(U+=I.vertical===""?R.height:R.width,z=z.reverse()),F.move(X,U)}else{var W=F.lineHeight/R.height*100;switch(I.lineAlign){case"center":V-=W/2;break;case"end":V-=W;break}switch(I.vertical){case"":A.applyStyles({top:A.formatStyle(V,"%")});break;case"rl":A.applyStyles({left:A.formatStyle(V,"%")});break;case"lr":A.applyStyles({right:A.formatStyle(V,"%")});break}z=["+y","-x","+x","-y"],F=new b(A)}var Y=D(F,z);A.move(Y.toCSSCompatValues(R))}function _(){}_.StringDecoder=function(){return{decode:function(E){if(!E)return"";if(typeof E!="string")throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(E))}}},_.convertCueToDOMTree=function(E,A){return!E||!A?null:f(E,A)};var C=.05,P="sans-serif",x="1.5%";return _.processCues=function(E,A,R){if(!E||!A||!R)return null;for(;R.firstChild;)R.removeChild(R.firstChild);var M=E.document.createElement("div");M.style.position="absolute",M.style.left="0",M.style.right="0",M.style.top="0",M.style.bottom="0",M.style.margin=x,R.appendChild(M);function D(H){for(var U=0;U<H.length;U++)if(H[U].hasBeenReset||!H[U].displayState)return!0;return!1}if(!D(A)){for(var F=0;F<A.length;F++)M.appendChild(A[F].displayState);return}var I=[],V=b.getSimpleBoxPosition(M),z=Math.round(V.height*C*100)/100,G={font:z+"px "+P};(function(){for(var H,U,k=0;k<A.length;k++)U=A[k],H=new m(E,U,G),M.appendChild(H.div),S(E,H,V,I),U.displayState=H.div,I.push(b.getSimpleBoxPosition(H))})()},_.Parser=function(E,A,R){R||(R=A,A={}),A||(A={}),this.window=E,this.vttjs=A,this.state="INITIAL",this.buffer="",this.decoder=R||new TextDecoder("utf8"),this.regionList=[]},_.Parser.prototype={reportOrThrowError:function(E){if(E instanceof i)this.onparsingerror&&this.onparsingerror(E);else throw E},parse:function(E){var A=this;E&&(A.buffer+=A.decoder.decode(E,{stream:!0}));function R(){for(var H=A.buffer,U=0;U<H.length&&H[U]!=="\r"&&H[U]!==`
`;)++U;var k=H.substr(0,U);return H[U]==="\r"&&++U,H[U]===`
`&&++U,A.buffer=H.substr(U),k}function M(H){var U=new r;if(o(H,function(X,W){switch(X){case"id":U.set(X,W);break;case"width":U.percent(X,W);break;case"lines":U.integer(X,W);break;case"regionanchor":case"viewportanchor":var Y=W.split(",");if(Y.length!==2)break;var te=new r;if(te.percent("x",Y[0]),te.percent("y",Y[1]),!te.has("x")||!te.has("y"))break;U.set(X+"X",te.get("x")),U.set(X+"Y",te.get("y"));break;case"scroll":U.alt(X,W,["up"]);break}},/=/,/\s/),U.has("id")){var k=new(A.vttjs.VTTRegion||A.window.VTTRegion);k.width=U.get("width",100),k.lines=U.get("lines",3),k.regionAnchorX=U.get("regionanchorX",0),k.regionAnchorY=U.get("regionanchorY",100),k.viewportAnchorX=U.get("viewportanchorX",0),k.viewportAnchorY=U.get("viewportanchorY",100),k.scroll=U.get("scroll",""),A.onregion&&A.onregion(k),A.regionList.push({id:U.get("id"),region:k})}}function D(H){var U=new r;o(H,function(k,X){switch(k){case"MPEGT":U.integer(k+"S",X);break;case"LOCA":U.set(k+"L",n(X));break}},/[^\d]:/,/,/),A.ontimestampmap&&A.ontimestampmap({MPEGTS:U.get("MPEGTS"),LOCAL:U.get("LOCAL")})}function F(H){H.match(/X-TIMESTAMP-MAP/)?o(H,function(U,k){switch(U){case"X-TIMESTAMP-MAP":D(k);break}},/=/):o(H,function(U,k){switch(U){case"Region":M(k);break}},/:/)}try{var I;if(A.state==="INITIAL"){if(!/\r\n|\n/.test(A.buffer))return this;I=R();var V=I.match(/^WEBVTT([ \t].*)?$/);if(!V||!V[0])throw new i(i.Errors.BadSignature);A.state="HEADER"}for(var z=!1;A.buffer;){if(!/\r\n|\n/.test(A.buffer))return this;switch(z?z=!1:I=R(),A.state){case"HEADER":/:/.test(I)?F(I):I||(A.state="ID");continue;case"NOTE":I||(A.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(I)){A.state="NOTE";break}if(!I)continue;A.cue=new(A.vttjs.VTTCue||A.window.VTTCue)(0,0,"");try{A.cue.align="center"}catch{A.cue.align="middle"}if(A.state="CUE",I.indexOf("-->")===-1){A.cue.id=I;continue}case"CUE":try{a(I,A.cue,A.regionList)}catch(H){A.reportOrThrowError(H),A.cue=null,A.state="BADCUE";continue}A.state="CUETEXT";continue;case"CUETEXT":var G=I.indexOf("-->")!==-1;if(!I||G&&(z=!0)){A.oncue&&A.oncue(A.cue),A.cue=null,A.state="ID";continue}A.cue.text&&(A.cue.text+=`
`),A.cue.text+=I.replace(/\u2028/g,`
`).replace(/u2029/g,`
`);continue;case"BADCUE":I||(A.state="ID");continue}}}catch(H){A.reportOrThrowError(H),A.state==="CUETEXT"&&A.cue&&A.oncue&&A.oncue(A.cue),A.cue=null,A.state=A.state==="INITIAL"?"BADWEBVTT":"BADCUE"}return this},flush:function(){var E=this;try{if(E.buffer+=E.decoder.decode(),(E.cue||E.state==="HEADER")&&(E.buffer+=`

`,E.parse()),E.state==="INITIAL")throw new i(i.Errors.BadSignature)}catch(A){E.reportOrThrowError(A)}return E.onflush&&E.onflush(),this}},NY=_,NY}var FY,Cce;function Nbt(){if(Cce)return FY;Cce=1;var t="auto",e={"":1,lr:1,rl:1},i={start:1,center:1,end:1,left:1,right:1,auto:1,"line-left":1,"line-right":1};function n(a){if(typeof a!="string")return!1;var s=e[a.toLowerCase()];return s?a.toLowerCase():!1}function r(a){if(typeof a!="string")return!1;var s=i[a.toLowerCase()];return s?a.toLowerCase():!1}function o(a,s,l){this.hasBeenReset=!1;var u="",c=!1,d=a,f=s,h=l,p=null,g="",v=!0,y="auto",m="start",b="auto",S="auto",_=100,C="center";Object.defineProperties(this,{id:{enumerable:!0,get:function(){return u},set:function(P){u=""+P}},pauseOnExit:{enumerable:!0,get:function(){return c},set:function(P){c=!!P}},startTime:{enumerable:!0,get:function(){return d},set:function(P){if(typeof P!="number")throw new TypeError("Start time must be set to a number.");d=P,this.hasBeenReset=!0}},endTime:{enumerable:!0,get:function(){return f},set:function(P){if(typeof P!="number")throw new TypeError("End time must be set to a number.");f=P,this.hasBeenReset=!0}},text:{enumerable:!0,get:function(){return h},set:function(P){h=""+P,this.hasBeenReset=!0}},region:{enumerable:!0,get:function(){return p},set:function(P){p=P,this.hasBeenReset=!0}},vertical:{enumerable:!0,get:function(){return g},set:function(P){var x=n(P);if(x===!1)throw new SyntaxError("Vertical: an invalid or illegal direction string was specified.");g=x,this.hasBeenReset=!0}},snapToLines:{enumerable:!0,get:function(){return v},set:function(P){v=!!P,this.hasBeenReset=!0}},line:{enumerable:!0,get:function(){return y},set:function(P){if(typeof P!="number"&&P!==t)throw new SyntaxError("Line: an invalid number or illegal string was specified.");y=P,this.hasBeenReset=!0}},lineAlign:{enumerable:!0,get:function(){return m},set:function(P){var x=r(P);x?(m=x,this.hasBeenReset=!0):console.warn("lineAlign: an invalid or illegal string was specified.")}},position:{enumerable:!0,get:function(){return b},set:function(P){if(P<0||P>100)throw new Error("Position must be between 0 and 100.");b=P,this.hasBeenReset=!0}},positionAlign:{enumerable:!0,get:function(){return S},set:function(P){var x=r(P);x?(S=x,this.hasBeenReset=!0):console.warn("positionAlign: an invalid or illegal string was specified.")}},size:{enumerable:!0,get:function(){return _},set:function(P){if(P<0||P>100)throw new Error("Size must be between 0 and 100.");_=P,this.hasBeenReset=!0}},align:{enumerable:!0,get:function(){return C},set:function(P){var x=r(P);if(!x)throw new SyntaxError("align: an invalid or illegal alignment string was specified.");C=x,this.hasBeenReset=!0}}}),this.displayState=void 0}return o.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)},FY=o,FY}var BY,Tce;function Fbt(){if(Tce)return BY;Tce=1;var t={"":!0,up:!0};function e(r){if(typeof r!="string")return!1;var o=t[r.toLowerCase()];return o?r.toLowerCase():!1}function i(r){return typeof r=="number"&&r>=0&&r<=100}function n(){var r=100,o=3,a=0,s=100,l=0,u=100,c="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return r},set:function(d){if(!i(d))throw new Error("Width must be between 0 and 100.");r=d}},lines:{enumerable:!0,get:function(){return o},set:function(d){if(typeof d!="number")throw new TypeError("Lines must be set to a number.");o=d}},regionAnchorY:{enumerable:!0,get:function(){return s},set:function(d){if(!i(d))throw new Error("RegionAnchorX must be between 0 and 100.");s=d}},regionAnchorX:{enumerable:!0,get:function(){return a},set:function(d){if(!i(d))throw new Error("RegionAnchorY must be between 0 and 100.");a=d}},viewportAnchorY:{enumerable:!0,get:function(){return u},set:function(d){if(!i(d))throw new Error("ViewportAnchorY must be between 0 and 100.");u=d}},viewportAnchorX:{enumerable:!0,get:function(){return l},set:function(d){if(!i(d))throw new Error("ViewportAnchorX must be between 0 and 100.");l=d}},scroll:{enumerable:!0,get:function(){return c},set:function(d){var f=e(d);f===!1?console.warn("Scroll: an invalid or illegal string was specified."):c=f}}})}return BY=n,BY}var xce;function Bbt(){if(xce)return IY.exports;xce=1;var t=V6(),e=IY.exports={WebVTT:Ibt(),VTTCue:Nbt(),VTTRegion:Fbt()};t.vttjs=e,t.WebVTT=e.WebVTT;var i=e.VTTCue,n=e.VTTRegion,r=t.VTTCue,o=t.VTTRegion;return e.shim=function(){t.VTTCue=i,t.VTTRegion=n},e.restore=function(){t.VTTCue=r,t.VTTRegion=o},t.VTTCue||e.shim(),IY.exports}var jbt=Bbt();const Ece=wc(jbt);function iIe(){try{var t=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(iIe=function(){return!!t})()}function nIe(t,e,i){if(iIe())return Reflect.construct.apply(null,arguments);var n=[null];n.push.apply(n,e);var r=new(t.bind.apply(t,n));return i&&Wk(r,i.prototype),r}function Vbt(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&Wk(t,e)}var jY={exports:{}},wce;function Hbt(){return wce||(wce=1,(function(t,e){(function(i){var n=/^(?=((?:[a-zA-Z0-9+\-.]+:)?))\1(?=((?:\/\/[^\/?#]*)?))\2(?=((?:(?:[^?#\/]*\/)*[^;?#\/]*)?))\3((?:;[^?#]*)?)(\?[^#]*)?(#[^]*)?$/,r=/^(?=([^\/?#]*))\1([^]*)$/,o=/(?:\/|^)\.(?=\/)/g,a=/(?:\/|^)\.\.\/(?!\.\.\/)[^\/]*(?=\/)/g,s={buildAbsoluteURL:function(l,u,c){if(c=c||{},l=l.trim(),u=u.trim(),!u){if(!c.alwaysNormalize)return l;var d=s.parseURL(l);if(!d)throw new Error("Error trying to parse base URL.");return d.path=s.normalizePath(d.path),s.buildURLFromParts(d)}var f=s.parseURL(u);if(!f)throw new Error("Error trying to parse relative URL.");if(f.scheme)return c.alwaysNormalize?(f.path=s.normalizePath(f.path),s.buildURLFromParts(f)):u;var h=s.parseURL(l);if(!h)throw new Error("Error trying to parse base URL.");if(!h.netLoc&&h.path&&h.path[0]!=="/"){var p=r.exec(h.path);h.netLoc=p[1],h.path=p[2]}h.netLoc&&!h.path&&(h.path="/");var g={scheme:h.scheme,netLoc:f.netLoc,path:null,params:f.params,query:f.query,fragment:f.fragment};if(!f.netLoc&&(g.netLoc=h.netLoc,f.path[0]!=="/"))if(!f.path)g.path=h.path,f.params||(g.params=h.params,f.query||(g.query=h.query));else{var v=h.path,y=v.substring(0,v.lastIndexOf("/")+1)+f.path;g.path=s.normalizePath(y)}return g.path===null&&(g.path=c.alwaysNormalize?s.normalizePath(f.path):f.path),s.buildURLFromParts(g)},parseURL:function(l){var u=n.exec(l);return u?{scheme:u[1]||"",netLoc:u[2]||"",path:u[3]||"",params:u[4]||"",query:u[5]||"",fragment:u[6]||""}:null},normalizePath:function(l){for(l=l.split("").reverse().join("").replace(o,"");l.length!==(l=l.replace(a,"")).length;);return l.split("").reverse().join("")},buildURLFromParts:function(l){return l.scheme+l.netLoc+l.path+l.params+l.query+l.fragment}};t.exports=s})()})(jY)),jY.exports}var Ubt=Hbt();const Ace=wc(Ubt);var Oce="http://example.com",H6=function(e,i){if(/^[a-z]+:/i.test(i))return i;/^data:/.test(e)&&(e=Ct.location&&Ct.location.href||"");var n=typeof Ct.URL=="function",r=/^\/\//.test(e),o=!Ct.location&&!/\/\//i.test(e);if(n?e=new Ct.URL(e,Ct.location||Oce):/\/\//i.test(e)||(e=Ace.buildAbsoluteURL(Ct.location&&Ct.location.href||"",e)),n){var a=new URL(i,e);return o?a.href.slice(Oce.length):r?a.href.slice(a.protocol.length):a.href}return Ace.buildAbsoluteURL(e,i)},gte=(function(){function t(){this.listeners={}}var e=t.prototype;return e.on=function(n,r){this.listeners[n]||(this.listeners[n]=[]),this.listeners[n].push(r)},e.off=function(n,r){if(!this.listeners[n])return!1;var o=this.listeners[n].indexOf(r);return this.listeners[n]=this.listeners[n].slice(0),this.listeners[n].splice(o,1),o>-1},e.trigger=function(n){var r=this.listeners[n];if(r)if(arguments.length===2)for(var o=r.length,a=0;a<o;++a)r[a].call(this,arguments[1]);else for(var s=Array.prototype.slice.call(arguments,1),l=r.length,u=0;u<l;++u)r[u].apply(this,s)},e.dispose=function(){this.listeners={}},e.pipe=function(n){this.on("data",function(r){n.push(r)})},t})(),zbt=function(e){return Ct.atob?Ct.atob(e):Buffer.from(e,"base64").toString("binary")};function oIe(t){for(var e=zbt(t),i=new Uint8Array(e.length),n=0;n<e.length;n++)i[n]=e.charCodeAt(n);return i}/*! @name m3u8-parser @version 4.8.0 @license Apache-2.0 */var $bt=(function(t){qr(e,t);function e(){var n;return n=t.call(this)||this,n.buffer="",n}var i=e.prototype;return i.push=function(r){var o;for(this.buffer+=r,o=this.buffer.indexOf(`
`);o>-1;o=this.buffer.indexOf(`
`))this.trigger("data",this.buffer.substring(0,o)),this.buffer=this.buffer.substring(o+1)},e})(gte),Wbt="	",VY=function(e){var i=/([0-9.]*)?@?([0-9.]*)?/.exec(e||""),n={};return i[1]&&(n.length=parseInt(i[1],10)),i[2]&&(n.offset=parseInt(i[2],10)),n},Gbt=function(){var e="[^=]*",i='"[^"]*"|[^,]*',n="(?:"+e+")=(?:"+i+")";return new RegExp("(?:^|,)("+n+")")},nv=function(e){for(var i=e.split(Gbt()),n={},r=i.length,o;r--;)i[r]!==""&&(o=/([^=]*)=(.*)/.exec(i[r]).slice(1),o[0]=o[0].replace(/^\s+|\s+$/g,""),o[1]=o[1].replace(/^\s+|\s+$/g,""),o[1]=o[1].replace(/^['"](.*)['"]$/g,"$1"),n[o[0]]=o[1]);return n},Ybt=(function(t){qr(e,t);function e(){var n;return n=t.call(this)||this,n.customParsers=[],n.tagMappers=[],n}var i=e.prototype;return i.push=function(r){var o=this,a,s;if(r=r.trim(),r.length!==0){if(r[0]!=="#"){this.trigger("data",{type:"uri",uri:r});return}var l=this.tagMappers.reduce(function(u,c){var d=c(r);return d===r?u:u.concat([d])},[r]);l.forEach(function(u){for(var c=0;c<o.customParsers.length;c++)if(o.customParsers[c].call(o,u))return;if(u.indexOf("#EXT")!==0){o.trigger("data",{type:"comment",text:u.slice(1)});return}if(u=u.replace("\r",""),a=/^#EXTM3U/.exec(u),a){o.trigger("data",{type:"tag",tagType:"m3u"});return}if(a=/^#EXTINF:?([0-9\.]*)?,?(.*)?$/.exec(u),a){s={type:"tag",tagType:"inf"},a[1]&&(s.duration=parseFloat(a[1])),a[2]&&(s.title=a[2]),o.trigger("data",s);return}if(a=/^#EXT-X-TARGETDURATION:?([0-9.]*)?/.exec(u),a){s={type:"tag",tagType:"targetduration"},a[1]&&(s.duration=parseInt(a[1],10)),o.trigger("data",s);return}if(a=/^#EXT-X-VERSION:?([0-9.]*)?/.exec(u),a){s={type:"tag",tagType:"version"},a[1]&&(s.version=parseInt(a[1],10)),o.trigger("data",s);return}if(a=/^#EXT-X-MEDIA-SEQUENCE:?(\-?[0-9.]*)?/.exec(u),a){s={type:"tag",tagType:"media-sequence"},a[1]&&(s.number=parseInt(a[1],10)),o.trigger("data",s);return}if(a=/^#EXT-X-DISCONTINUITY-SEQUENCE:?(\-?[0-9.]*)?/.exec(u),a){s={type:"tag",tagType:"discontinuity-sequence"},a[1]&&(s.number=parseInt(a[1],10)),o.trigger("data",s);return}if(a=/^#EXT-X-PLAYLIST-TYPE:?(.*)?$/.exec(u),a){s={type:"tag",tagType:"playlist-type"},a[1]&&(s.playlistType=a[1]),o.trigger("data",s);return}if(a=/^#EXT-X-BYTERANGE:?(.*)?$/.exec(u),a){s=Gn(VY(a[1]),{type:"tag",tagType:"byterange"}),o.trigger("data",s);return}if(a=/^#EXT-X-ALLOW-CACHE:?(YES|NO)?/.exec(u),a){s={type:"tag",tagType:"allow-cache"},a[1]&&(s.allowed=!/NO/.test(a[1])),o.trigger("data",s);return}if(a=/^#EXT-X-MAP:?(.*)$/.exec(u),a){if(s={type:"tag",tagType:"map"},a[1]){var d=nv(a[1]);d.URI&&(s.uri=d.URI),d.BYTERANGE&&(s.byterange=VY(d.BYTERANGE))}o.trigger("data",s);return}if(a=/^#EXT-X-STREAM-INF:?(.*)$/.exec(u),a){if(s={type:"tag",tagType:"stream-inf"},a[1]){if(s.attributes=nv(a[1]),s.attributes.RESOLUTION){var f=s.attributes.RESOLUTION.split("x"),h={};f[0]&&(h.width=parseInt(f[0],10)),f[1]&&(h.height=parseInt(f[1],10)),s.attributes.RESOLUTION=h}s.attributes.BANDWIDTH&&(s.attributes.BANDWIDTH=parseInt(s.attributes.BANDWIDTH,10)),s.attributes["FRAME-RATE"]&&(s.attributes["FRAME-RATE"]=parseFloat(s.attributes["FRAME-RATE"])),s.attributes["PROGRAM-ID"]&&(s.attributes["PROGRAM-ID"]=parseInt(s.attributes["PROGRAM-ID"],10))}o.trigger("data",s);return}if(a=/^#EXT-X-MEDIA:?(.*)$/.exec(u),a){s={type:"tag",tagType:"media"},a[1]&&(s.attributes=nv(a[1])),o.trigger("data",s);return}if(a=/^#EXT-X-ENDLIST/.exec(u),a){o.trigger("data",{type:"tag",tagType:"endlist"});return}if(a=/^#EXT-X-DISCONTINUITY/.exec(u),a){o.trigger("data",{type:"tag",tagType:"discontinuity"});return}if(a=/^#EXT-X-PROGRAM-DATE-TIME:?(.*)$/.exec(u),a){s={type:"tag",tagType:"program-date-time"},a[1]&&(s.dateTimeString=a[1],s.dateTimeObject=new Date(a[1])),o.trigger("data",s);return}if(a=/^#EXT-X-KEY:?(.*)$/.exec(u),a){s={type:"tag",tagType:"key"},a[1]&&(s.attributes=nv(a[1]),s.attributes.IV&&(s.attributes.IV.substring(0,2).toLowerCase()==="0x"&&(s.attributes.IV=s.attributes.IV.substring(2)),s.attributes.IV=s.attributes.IV.match(/.{8}/g),s.attributes.IV[0]=parseInt(s.attributes.IV[0],16),s.attributes.IV[1]=parseInt(s.attributes.IV[1],16),s.attributes.IV[2]=parseInt(s.attributes.IV[2],16),s.attributes.IV[3]=parseInt(s.attributes.IV[3],16),s.attributes.IV=new Uint32Array(s.attributes.IV))),o.trigger("data",s);return}if(a=/^#EXT-X-START:?(.*)$/.exec(u),a){s={type:"tag",tagType:"start"},a[1]&&(s.attributes=nv(a[1]),s.attributes["TIME-OFFSET"]=parseFloat(s.attributes["TIME-OFFSET"]),s.attributes.PRECISE=/YES/.test(s.attributes.PRECISE)),o.trigger("data",s);return}if(a=/^#EXT-X-CUE-OUT-CONT:?(.*)?$/.exec(u),a){s={type:"tag",tagType:"cue-out-cont"},a[1]?s.data=a[1]:s.data="",o.trigger("data",s);return}if(a=/^#EXT-X-CUE-OUT:?(.*)?$/.exec(u),a){s={type:"tag",tagType:"cue-out"},a[1]?s.data=a[1]:s.data="",o.trigger("data",s);return}if(a=/^#EXT-X-CUE-IN:?(.*)?$/.exec(u),a){s={type:"tag",tagType:"cue-in"},a[1]?s.data=a[1]:s.data="",o.trigger("data",s);return}if(a=/^#EXT-X-SKIP:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"skip"},s.attributes=nv(a[1]),s.attributes.hasOwnProperty("SKIPPED-SEGMENTS")&&(s.attributes["SKIPPED-SEGMENTS"]=parseInt(s.attributes["SKIPPED-SEGMENTS"],10)),s.attributes.hasOwnProperty("RECENTLY-REMOVED-DATERANGES")&&(s.attributes["RECENTLY-REMOVED-DATERANGES"]=s.attributes["RECENTLY-REMOVED-DATERANGES"].split(Wbt)),o.trigger("data",s);return}if(a=/^#EXT-X-PART:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"part"},s.attributes=nv(a[1]),["DURATION"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=parseFloat(s.attributes[p]))}),["INDEPENDENT","GAP"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=/YES/.test(s.attributes[p]))}),s.attributes.hasOwnProperty("BYTERANGE")&&(s.attributes.byterange=VY(s.attributes.BYTERANGE)),o.trigger("data",s);return}if(a=/^#EXT-X-SERVER-CONTROL:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"server-control"},s.attributes=nv(a[1]),["CAN-SKIP-UNTIL","PART-HOLD-BACK","HOLD-BACK"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=parseFloat(s.attributes[p]))}),["CAN-SKIP-DATERANGES","CAN-BLOCK-RELOAD"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=/YES/.test(s.attributes[p]))}),o.trigger("data",s);return}if(a=/^#EXT-X-PART-INF:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"part-inf"},s.attributes=nv(a[1]),["PART-TARGET"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=parseFloat(s.attributes[p]))}),o.trigger("data",s);return}if(a=/^#EXT-X-PRELOAD-HINT:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"preload-hint"},s.attributes=nv(a[1]),["BYTERANGE-START","BYTERANGE-LENGTH"].forEach(function(p){if(s.attributes.hasOwnProperty(p)){s.attributes[p]=parseInt(s.attributes[p],10);var g=p==="BYTERANGE-LENGTH"?"length":"offset";s.attributes.byterange=s.attributes.byterange||{},s.attributes.byterange[g]=s.attributes[p],delete s.attributes[p]}}),o.trigger("data",s);return}if(a=/^#EXT-X-RENDITION-REPORT:(.*)$/.exec(u),a&&a[1]){s={type:"tag",tagType:"rendition-report"},s.attributes=nv(a[1]),["LAST-MSN","LAST-PART"].forEach(function(p){s.attributes.hasOwnProperty(p)&&(s.attributes[p]=parseInt(s.attributes[p],10))}),o.trigger("data",s);return}o.trigger("data",{type:"tag",data:u.slice(4)})})}},i.addParser=function(r){var o=this,a=r.expression,s=r.customType,l=r.dataParser,u=r.segment;typeof l!="function"&&(l=function(d){return d}),this.customParsers.push(function(c){var d=a.exec(c);if(d)return o.trigger("data",{type:"custom",data:l(c),customType:s,segment:u}),!0})},i.addTagMapper=function(r){var o=r.expression,a=r.map,s=function(u){return o.test(u)?a(u):u};this.tagMappers.push(s)},e})(gte),qbt=function(e){return e.toLowerCase().replace(/-(\w)/g,function(i){return i[1].toUpperCase()})},nL=function(e){var i={};return Object.keys(e).forEach(function(n){i[qbt(n)]=e[n]}),i},HY=function(e){var i=e.serverControl,n=e.targetDuration,r=e.partTargetDuration;if(i){var o="#EXT-X-SERVER-CONTROL",a="holdBack",s="partHoldBack",l=n&&n*3,u=r&&r*2;n&&!i.hasOwnProperty(a)&&(i[a]=l,this.trigger("info",{message:o+" defaulting HOLD-BACK to targetDuration * 3 ("+l+")."})),l&&i[a]<l&&(this.trigger("warn",{message:o+" clamping HOLD-BACK ("+i[a]+") to targetDuration * 3 ("+l+")"}),i[a]=l),r&&!i.hasOwnProperty(s)&&(i[s]=r*3,this.trigger("info",{message:o+" defaulting PART-HOLD-BACK to partTargetDuration * 3 ("+i[s]+")."})),r&&i[s]<u&&(this.trigger("warn",{message:o+" clamping PART-HOLD-BACK ("+i[s]+") to partTargetDuration * 2 ("+u+")."}),i[s]=u)}},Xbt=(function(t){qr(e,t);function e(){var n;n=t.call(this)||this,n.lineStream=new $bt,n.parseStream=new Ybt,n.lineStream.pipe(n.parseStream);var r=bn(n),o=[],a={},s,l,u=!1,c=function(){},d={AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},f="urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed",h=0;n.manifest={allowCache:!0,discontinuityStarts:[],segments:[]};var p=0,g=0;return n.on("end",function(){a.uri||!a.parts&&!a.preloadHints||(!a.map&&s&&(a.map=s),!a.key&&l&&(a.key=l),!a.timeline&&typeof h=="number"&&(a.timeline=h),n.manifest.preloadSegment=a)}),n.parseStream.on("data",function(v){var y,m;({tag:function(){({version:function(){v.version&&(this.manifest.version=v.version)},"allow-cache":function(){this.manifest.allowCache=v.allowed,"allowed"in v||(this.trigger("info",{message:"defaulting allowCache to YES"}),this.manifest.allowCache=!0)},byterange:function(){var _={};"length"in v&&(a.byterange=_,_.length=v.length,"offset"in v||(v.offset=p)),"offset"in v&&(a.byterange=_,_.offset=v.offset),p=_.offset+_.length},endlist:function(){this.manifest.endList=!0},inf:function(){"mediaSequence"in this.manifest||(this.manifest.mediaSequence=0,this.trigger("info",{message:"defaulting media sequence to zero"})),"discontinuitySequence"in this.manifest||(this.manifest.discontinuitySequence=0,this.trigger("info",{message:"defaulting discontinuity sequence to zero"})),v.duration>0&&(a.duration=v.duration),v.duration===0&&(a.duration=.01,this.trigger("info",{message:"updating zero segment duration to a small value"})),this.manifest.segments=o},key:function(){if(!v.attributes){this.trigger("warn",{message:"ignoring key declaration without attribute list"});return}if(v.attributes.METHOD==="NONE"){l=null;return}if(!v.attributes.URI){this.trigger("warn",{message:"ignoring key declaration without URI"});return}if(v.attributes.KEYFORMAT==="com.apple.streamingkeydelivery"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.apple.fps.1_0"]={attributes:v.attributes};return}if(v.attributes.KEYFORMAT==="com.microsoft.playready"){this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.microsoft.playready"]={uri:v.attributes.URI};return}if(v.attributes.KEYFORMAT===f){var _=["SAMPLE-AES","SAMPLE-AES-CTR","SAMPLE-AES-CENC"];if(_.indexOf(v.attributes.METHOD)===-1){this.trigger("warn",{message:"invalid key method provided for Widevine"});return}if(v.attributes.METHOD==="SAMPLE-AES-CENC"&&this.trigger("warn",{message:"SAMPLE-AES-CENC is deprecated, please use SAMPLE-AES-CTR instead"}),v.attributes.URI.substring(0,23)!=="data:text/plain;base64,"){this.trigger("warn",{message:"invalid key URI provided for Widevine"});return}if(!(v.attributes.KEYID&&v.attributes.KEYID.substring(0,2)==="0x")){this.trigger("warn",{message:"invalid key ID provided for Widevine"});return}this.manifest.contentProtection=this.manifest.contentProtection||{},this.manifest.contentProtection["com.widevine.alpha"]={attributes:{schemeIdUri:v.attributes.KEYFORMAT,keyId:v.attributes.KEYID.substring(2)},pssh:oIe(v.attributes.URI.split(",")[1])};return}v.attributes.METHOD||this.trigger("warn",{message:"defaulting key method to AES-128"}),l={method:v.attributes.METHOD||"AES-128",uri:v.attributes.URI},typeof v.attributes.IV<"u"&&(l.iv=v.attributes.IV)},"media-sequence":function(){if(!isFinite(v.number)){this.trigger("warn",{message:"ignoring invalid media sequence: "+v.number});return}this.manifest.mediaSequence=v.number},"discontinuity-sequence":function(){if(!isFinite(v.number)){this.trigger("warn",{message:"ignoring invalid discontinuity sequence: "+v.number});return}this.manifest.discontinuitySequence=v.number,h=v.number},"playlist-type":function(){if(!/VOD|EVENT/.test(v.playlistType)){this.trigger("warn",{message:"ignoring unknown playlist type: "+v.playlist});return}this.manifest.playlistType=v.playlistType},map:function(){s={},v.uri&&(s.uri=v.uri),v.byterange&&(s.byterange=v.byterange),l&&(s.key=l)},"stream-inf":function(){if(this.manifest.playlists=o,this.manifest.mediaGroups=this.manifest.mediaGroups||d,!v.attributes){this.trigger("warn",{message:"ignoring empty stream-inf attributes"});return}a.attributes||(a.attributes={}),Gn(a.attributes,v.attributes)},media:function(){if(this.manifest.mediaGroups=this.manifest.mediaGroups||d,!(v.attributes&&v.attributes.TYPE&&v.attributes["GROUP-ID"]&&v.attributes.NAME)){this.trigger("warn",{message:"ignoring incomplete or missing media group"});return}var _=this.manifest.mediaGroups[v.attributes.TYPE];_[v.attributes["GROUP-ID"]]=_[v.attributes["GROUP-ID"]]||{},y=_[v.attributes["GROUP-ID"]],m={default:/yes/i.test(v.attributes.DEFAULT)},m.default?m.autoselect=!0:m.autoselect=/yes/i.test(v.attributes.AUTOSELECT),v.attributes.LANGUAGE&&(m.language=v.attributes.LANGUAGE),v.attributes.URI&&(m.uri=v.attributes.URI),v.attributes["INSTREAM-ID"]&&(m.instreamId=v.attributes["INSTREAM-ID"]),v.attributes.CHARACTERISTICS&&(m.characteristics=v.attributes.CHARACTERISTICS),v.attributes.FORCED&&(m.forced=/yes/i.test(v.attributes.FORCED)),y[v.attributes.NAME]=m},discontinuity:function(){h+=1,a.discontinuity=!0,this.manifest.discontinuityStarts.push(o.length)},"program-date-time":function(){typeof this.manifest.dateTimeString>"u"&&(this.manifest.dateTimeString=v.dateTimeString,this.manifest.dateTimeObject=v.dateTimeObject),a.dateTimeString=v.dateTimeString,a.dateTimeObject=v.dateTimeObject},targetduration:function(){if(!isFinite(v.duration)||v.duration<0){this.trigger("warn",{message:"ignoring invalid target duration: "+v.duration});return}this.manifest.targetDuration=v.duration,HY.call(this,this.manifest)},start:function(){if(!v.attributes||isNaN(v.attributes["TIME-OFFSET"])){this.trigger("warn",{message:"ignoring start declaration without appropriate attribute list"});return}this.manifest.start={timeOffset:v.attributes["TIME-OFFSET"],precise:v.attributes.PRECISE}},"cue-out":function(){a.cueOut=v.data},"cue-out-cont":function(){a.cueOutCont=v.data},"cue-in":function(){a.cueIn=v.data},skip:function(){this.manifest.skip=nL(v.attributes),this.warnOnMissingAttributes_("#EXT-X-SKIP",v.attributes,["SKIPPED-SEGMENTS"])},part:function(){var _=this;u=!0;var C=this.manifest.segments.length,P=nL(v.attributes);a.parts=a.parts||[],a.parts.push(P),P.byterange&&(P.byterange.hasOwnProperty("offset")||(P.byterange.offset=g),g=P.byterange.offset+P.byterange.length);var x=a.parts.length-1;this.warnOnMissingAttributes_("#EXT-X-PART #"+x+" for segment #"+C,v.attributes,["URI","DURATION"]),this.manifest.renditionReports&&this.manifest.renditionReports.forEach(function(E,A){E.hasOwnProperty("lastPart")||_.trigger("warn",{message:"#EXT-X-RENDITION-REPORT #"+A+" lacks required attribute(s): LAST-PART"})})},"server-control":function(){var _=this.manifest.serverControl=nL(v.attributes);_.hasOwnProperty("canBlockReload")||(_.canBlockReload=!1,this.trigger("info",{message:"#EXT-X-SERVER-CONTROL defaulting CAN-BLOCK-RELOAD to false"})),HY.call(this,this.manifest),_.canSkipDateranges&&!_.hasOwnProperty("canSkipUntil")&&this.trigger("warn",{message:"#EXT-X-SERVER-CONTROL lacks required attribute CAN-SKIP-UNTIL which is required when CAN-SKIP-DATERANGES is set"})},"preload-hint":function(){var _=this.manifest.segments.length,C=nL(v.attributes),P=C.type&&C.type==="PART";a.preloadHints=a.preloadHints||[],a.preloadHints.push(C),C.byterange&&(C.byterange.hasOwnProperty("offset")||(C.byterange.offset=P?g:0,P&&(g=C.byterange.offset+C.byterange.length)));var x=a.preloadHints.length-1;if(this.warnOnMissingAttributes_("#EXT-X-PRELOAD-HINT #"+x+" for segment #"+_,v.attributes,["TYPE","URI"]),!!C.type)for(var E=0;E<a.preloadHints.length-1;E++){var A=a.preloadHints[E];A.type&&A.type===C.type&&this.trigger("warn",{message:"#EXT-X-PRELOAD-HINT #"+x+" for segment #"+_+" has the same TYPE "+C.type+" as preload hint #"+E})}},"rendition-report":function(){var _=nL(v.attributes);this.manifest.renditionReports=this.manifest.renditionReports||[],this.manifest.renditionReports.push(_);var C=this.manifest.renditionReports.length-1,P=["LAST-MSN","URI"];u&&P.push("LAST-PART"),this.warnOnMissingAttributes_("#EXT-X-RENDITION-REPORT #"+C,v.attributes,P)},"part-inf":function(){this.manifest.partInf=nL(v.attributes),this.warnOnMissingAttributes_("#EXT-X-PART-INF",v.attributes,["PART-TARGET"]),this.manifest.partInf.partTarget&&(this.manifest.partTargetDuration=this.manifest.partInf.partTarget),HY.call(this,this.manifest)}}[v.tagType]||c).call(r)},uri:function(){a.uri=v.uri,o.push(a),this.manifest.targetDuration&&!("duration"in a)&&(this.trigger("warn",{message:"defaulting segment duration to the target duration"}),a.duration=this.manifest.targetDuration),l&&(a.key=l),a.timeline=h,s&&(a.map=s),g=0,a={}},comment:function(){},custom:function(){v.segment?(a.custom=a.custom||{},a.custom[v.customType]=v.data):(this.manifest.custom=this.manifest.custom||{},this.manifest.custom[v.customType]=v.data)}})[v.type].call(r)}),n}var i=e.prototype;return i.warnOnMissingAttributes_=function(r,o,a){var s=[];a.forEach(function(l){o.hasOwnProperty(l)||s.push(l)}),s.length&&this.trigger("warn",{message:r+" lacks required attribute(s): "+s.join(", ")})},i.push=function(r){this.lineStream.push(r)},i.end=function(){this.lineStream.push(`
`),this.trigger("end")},i.addParser=function(r){this.parseStream.addParser(r)},i.addTagMapper=function(r){this.parseStream.addTagMapper(r)},e})(gte),dD={mp4:/^(av0?1|avc0?[1234]|vp0?9|flac|opus|mp3|mp4a|mp4v|stpp.ttml.im1t)/,webm:/^(vp0?[89]|av0?1|opus|vorbis)/,ogg:/^(vp0?[89]|theora|flac|opus|vorbis)/,video:/^(av0?1|avc0?[1234]|vp0?[89]|hvc1|hev1|theora|mp4v)/,audio:/^(mp4a|flac|vorbis|opus|ac-[34]|ec-3|alac|mp3|speex|aac)/,text:/^(stpp.ttml.im1t)/,muxerVideo:/^(avc0?1)/,muxerAudio:/^(mp4a)/,muxerText:/a^/},Kbt=["video","audio","text"],Dce=["Video","Audio","Text"],aIe=function(e){return e&&e.replace(/avc1\.(\d+)\.(\d+)/i,function(i,n,r){var o=("00"+Number(n).toString(16)).slice(-2),a=("00"+Number(r).toString(16)).slice(-2);return"avc1."+o+"00"+a})},Ly=function(e){e===void 0&&(e="");var i=e.split(","),n=[];return i.forEach(function(r){r=r.trim();var o;Kbt.forEach(function(a){var s=dD[a].exec(r.toLowerCase());if(!(!s||s.length<=1)){o=a;var l=r.substring(0,s[1].length),u=r.replace(l,"");n.push({type:l,details:u,mediaType:a})}}),o||n.push({type:r,details:"",mediaType:"unknown"})}),n},Zbt=function(e,i){if(!e.mediaGroups.AUDIO||!i)return null;var n=e.mediaGroups.AUDIO[i];if(!n)return null;for(var r in n){var o=n[r];if(o.default&&o.playlists)return Ly(o.playlists[0].attributes.CODECS)}return null},sIe=function(e){return e===void 0&&(e=""),dD.audio.test(e.trim().toLowerCase())},Jbt=function(e){return e===void 0&&(e=""),dD.text.test(e.trim().toLowerCase())},R3=function(e){if(!(!e||typeof e!="string")){var i=e.toLowerCase().split(",").map(function(o){return aIe(o.trim())}),n="video";i.length===1&&sIe(i[0])?n="audio":i.length===1&&Jbt(i[0])&&(n="application");var r="mp4";return i.every(function(o){return dD.mp4.test(o)})?r="mp4":i.every(function(o){return dD.webm.test(o)})?r="webm":i.every(function(o){return dD.ogg.test(o)})&&(r="ogg"),n+"/"+r+';codecs="'+e+'"'}},XU=function(e){return e===void 0&&(e=""),Ct.MediaSource&&Ct.MediaSource.isTypeSupported&&Ct.MediaSource.isTypeSupported(R3(e))||!1},UY=function(e){return e===void 0&&(e=""),e.toLowerCase().split(",").every(function(i){i=i.trim();for(var n=0;n<Dce.length;n++){var r=Dce[n];if(dD["muxer"+r].test(i))return!0}return!1})},Rce="mp4a.40.2",Qbt="avc1.4d400d",eSt=/^(audio|video|application)\/(x-|vnd\.apple\.)?mpegurl/i,tSt=/^application\/dash\+xml/i,lIe=function(e){return eSt.test(e)?"hls":tSt.test(e)?"dash":e==="application/vnd.videojs.vhs+json"?"vhs-json":null},rSt=function(e){return e.toString(2).length},iSt=function(e){return Math.ceil(rSt(e)/8)},uIe=function(e){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer},nSt=function(e){return uIe(e)},Vi=function(e){return e instanceof Uint8Array?e:(!Array.isArray(e)&&!nSt(e)&&!(e instanceof ArrayBuffer)&&(typeof e!="number"||typeof e=="number"&&e!==e?e=0:e=[e]),new Uint8Array(e&&e.buffer||e,e&&e.byteOffset||0,e&&e.byteLength||0))},td=Ct.BigInt||Number,kZ=[td("0x1"),td("0x100"),td("0x10000"),td("0x1000000"),td("0x100000000"),td("0x10000000000"),td("0x1000000000000"),td("0x100000000000000"),td("0x10000000000000000")];(function(){var t=new Uint16Array([65484]),e=new Uint8Array(t.buffer,t.byteOffset,t.byteLength);return e[0]===255?"big":e[0]===204?"little":"unknown"})();var oSt=function(e,i){var n=i===void 0?{}:i,r=n.signed,o=r===void 0?!1:r,a=n.le,s=a===void 0?!1:a;e=Vi(e);var l=s?"reduce":"reduceRight",u=e[l]?e[l]:Array.prototype[l],c=u.call(e,function(f,h,p){var g=s?p:Math.abs(p+1-e.length);return f+td(h)*kZ[g]},td(0));if(o){var d=kZ[e.length]/td(2)-td(1);c=td(c),c>d&&(c-=d,c-=d,c-=td(2))}return Number(c)},aSt=function(e,i){var n={},r=n.le,o=r===void 0?!1:r;(typeof e!="bigint"&&typeof e!="number"||typeof e=="number"&&e!==e)&&(e=0),e=td(e);for(var a=iSt(e),s=new Uint8Array(new ArrayBuffer(a)),l=0;l<a;l++){var u=o?l:Math.abs(l+1-s.length);s[u]=Number(e/kZ[l]&td(255)),e<0&&(s[u]=Math.abs(~s[u]),s[u]-=l===0?1:2)}return s},cIe=function(e,i){if(typeof e!="string"&&e&&typeof e.toString=="function"&&(e=e.toString()),typeof e!="string")return new Uint8Array;i||(e=unescape(encodeURIComponent(e)));for(var n=new Uint8Array(e.length),r=0;r<e.length;r++)n[r]=e.charCodeAt(r);return n},sSt=function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];if(i=i.filter(function(s){return s&&(s.byteLength||s.length)&&typeof s!="string"}),i.length<=1)return Vi(i[0]);var r=i.reduce(function(s,l,u){return s+(l.byteLength||l.length)},0),o=new Uint8Array(r),a=0;return i.forEach(function(s){s=Vi(s),o.set(s,a),a+=s.byteLength}),o},Gs=function(e,i,n){var r=n===void 0?{}:n,o=r.offset,a=o===void 0?0:o,s=r.mask,l=s===void 0?[]:s;e=Vi(e),i=Vi(i);var u=i.every?i.every:Array.prototype.every;return i.length&&e.length-a>=i.length&&u.call(i,function(c,d){var f=l[d]?l[d]&e[a+d]:e[a+d];return c===f})},lSt=function(e,i,n){i.forEach(function(r){for(var o in e.mediaGroups[r])for(var a in e.mediaGroups[r][o]){var s=e.mediaGroups[r][o][a];n(s,r,o,a)}})},tN={},R0={},ST={},Mce;function U6(){if(Mce)return ST;Mce=1;function t(o,a,s){if(s===void 0&&(s=Array.prototype),o&&typeof s.find=="function")return s.find.call(o,a);for(var l=0;l<o.length;l++)if(Object.prototype.hasOwnProperty.call(o,l)){var u=o[l];if(a.call(void 0,u,l,o))return u}}function e(o,a){return a===void 0&&(a=Object),a&&typeof a.freeze=="function"?a.freeze(o):o}function i(o,a){if(o===null||typeof o!="object")throw new TypeError("target is not an object");for(var s in a)Object.prototype.hasOwnProperty.call(a,s)&&(o[s]=a[s]);return o}var n=e({HTML:"text/html",isHTML:function(o){return o===n.HTML},XML_APPLICATION:"application/xml",XML_TEXT:"text/xml",XML_XHTML_APPLICATION:"application/xhtml+xml",XML_SVG_IMAGE:"image/svg+xml"}),r=e({HTML:"http://www.w3.org/1999/xhtml",isHTML:function(o){return o===r.HTML},SVG:"http://www.w3.org/2000/svg",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"});return ST.assign=i,ST.find=t,ST.freeze=e,ST.MIME_TYPE=n,ST.NAMESPACE=r,ST}var Lce;function dIe(){if(Lce)return R0;Lce=1;var t=U6(),e=t.find,i=t.NAMESPACE;function n(Be){return Be!==""}function r(Be){return Be?Be.split(/[\t\n\f\r ]+/).filter(n):[]}function o(Be,We){return Be.hasOwnProperty(We)||(Be[We]=!0),Be}function a(Be){if(!Be)return[];var We=r(Be);return Object.keys(We.reduce(o,{}))}function s(Be){return function(We){return Be&&Be.indexOf(We)!==-1}}function l(Be,We){for(var dt in Be)Object.prototype.hasOwnProperty.call(Be,dt)&&(We[dt]=Be[dt])}function u(Be,We){var dt=Be.prototype;if(!(dt instanceof We)){let Tt=function(){};Tt.prototype=We.prototype,Tt=new Tt,l(dt,Tt),Be.prototype=dt=Tt}dt.constructor!=Be&&(typeof Be!="function"&&console.error("unknown Class:"+Be),dt.constructor=Be)}var c={},d=c.ELEMENT_NODE=1,f=c.ATTRIBUTE_NODE=2,h=c.TEXT_NODE=3,p=c.CDATA_SECTION_NODE=4,g=c.ENTITY_REFERENCE_NODE=5,v=c.ENTITY_NODE=6,y=c.PROCESSING_INSTRUCTION_NODE=7,m=c.COMMENT_NODE=8,b=c.DOCUMENT_NODE=9,S=c.DOCUMENT_TYPE_NODE=10,_=c.DOCUMENT_FRAGMENT_NODE=11,C=c.NOTATION_NODE=12,P={},x={};P.INDEX_SIZE_ERR=(x[1]="Index size error",1),P.DOMSTRING_SIZE_ERR=(x[2]="DOMString size error",2);var E=P.HIERARCHY_REQUEST_ERR=(x[3]="Hierarchy request error",3);P.WRONG_DOCUMENT_ERR=(x[4]="Wrong document",4),P.INVALID_CHARACTER_ERR=(x[5]="Invalid character",5),P.NO_DATA_ALLOWED_ERR=(x[6]="No data allowed",6),P.NO_MODIFICATION_ALLOWED_ERR=(x[7]="No modification allowed",7);var A=P.NOT_FOUND_ERR=(x[8]="Not found",8);P.NOT_SUPPORTED_ERR=(x[9]="Not supported",9);var R=P.INUSE_ATTRIBUTE_ERR=(x[10]="Attribute in use",10);P.INVALID_STATE_ERR=(x[11]="Invalid state",11),P.SYNTAX_ERR=(x[12]="Syntax error",12),P.INVALID_MODIFICATION_ERR=(x[13]="Invalid modification",13),P.NAMESPACE_ERR=(x[14]="Invalid namespace",14),P.INVALID_ACCESS_ERR=(x[15]="Invalid access",15);function M(Be,We){if(We instanceof Error)var dt=We;else dt=this,Error.call(this,x[Be]),this.message=x[Be],Error.captureStackTrace&&Error.captureStackTrace(this,M);return dt.code=Be,We&&(this.message=this.message+": "+We),dt}M.prototype=Error.prototype,l(P,M);function D(){}D.prototype={length:0,item:function(Be){return Be>=0&&Be<this.length?this[Be]:null},toString:function(Be,We){for(var dt=[],Tt=0;Tt<this.length;Tt++)Jt(this[Tt],dt,Be,We);return dt.join("")},filter:function(Be){return Array.prototype.filter.call(this,Be)},indexOf:function(Be){return Array.prototype.indexOf.call(this,Be)}};function F(Be,We){this._node=Be,this._refresh=We,I(this)}function I(Be){var We=Be._node._inc||Be._node.ownerDocument._inc;if(Be._inc!==We){var dt=Be._refresh(Be._node);if(Mr(Be,"length",dt.length),!Be.$$length||dt.length<Be.$$length)for(var Tt=dt.length;Tt in Be;Tt++)Object.prototype.hasOwnProperty.call(Be,Tt)&&delete Be[Tt];l(dt,Be),Be._inc=We}}F.prototype.item=function(Be){return I(this),this[Be]||null},u(F,D);function V(){}function z(Be,We){for(var dt=Be.length;dt--;)if(Be[dt]===We)return dt}function G(Be,We,dt,Tt){if(Tt?We[z(We,Tt)]=dt:We[We.length++]=dt,Be){dt.ownerElement=Be;var nr=Be.ownerDocument;nr&&(Tt&&oe(nr,Be,Tt),te(nr,Be,dt))}}function H(Be,We,dt){var Tt=z(We,dt);if(Tt>=0){for(var nr=We.length-1;Tt<nr;)We[Tt]=We[++Tt];if(We.length=nr,Be){var Ar=Be.ownerDocument;Ar&&(oe(Ar,Be,dt),dt.ownerElement=null)}}else throw new M(A,new Error(Be.tagName+"@"+dt))}V.prototype={length:0,item:D.prototype.item,getNamedItem:function(Be){for(var We=this.length;We--;){var dt=this[We];if(dt.nodeName==Be)return dt}},setNamedItem:function(Be){var We=Be.ownerElement;if(We&&We!=this._ownerElement)throw new M(R);var dt=this.getNamedItem(Be.nodeName);return G(this._ownerElement,this,Be,dt),dt},setNamedItemNS:function(Be){var We=Be.ownerElement,dt;if(We&&We!=this._ownerElement)throw new M(R);return dt=this.getNamedItemNS(Be.namespaceURI,Be.localName),G(this._ownerElement,this,Be,dt),dt},removeNamedItem:function(Be){var We=this.getNamedItem(Be);return H(this._ownerElement,this,We),We},removeNamedItemNS:function(Be,We){var dt=this.getNamedItemNS(Be,We);return H(this._ownerElement,this,dt),dt},getNamedItemNS:function(Be,We){for(var dt=this.length;dt--;){var Tt=this[dt];if(Tt.localName==We&&Tt.namespaceURI==Be)return Tt}return null}};function U(){}U.prototype={hasFeature:function(Be,We){return!0},createDocument:function(Be,We,dt){var Tt=new Y;if(Tt.implementation=this,Tt.childNodes=new D,Tt.doctype=dt||null,dt&&Tt.appendChild(dt),We){var nr=Tt.createElementNS(Be,We);Tt.appendChild(nr)}return Tt},createDocumentType:function(Be,We,dt){var Tt=new $t;return Tt.name=Be,Tt.nodeName=Be,Tt.publicId=We||"",Tt.systemId=dt||"",Tt}};function k(){}k.prototype={firstChild:null,lastChild:null,previousSibling:null,nextSibling:null,attributes:null,parentNode:null,childNodes:null,ownerDocument:null,nodeValue:null,namespaceURI:null,prefix:null,localName:null,insertBefore:function(Be,We){return pe(this,Be,We)},replaceChild:function(Be,We){pe(this,Be,We,ve),We&&this.removeChild(We)},removeChild:function(Be){return ge(this,Be)},appendChild:function(Be){return this.insertBefore(Be,null)},hasChildNodes:function(){return this.firstChild!=null},cloneNode:function(Be){return Bt(this.ownerDocument||this,this,Be)},normalize:function(){for(var Be=this.firstChild;Be;){var We=Be.nextSibling;We&&We.nodeType==h&&Be.nodeType==h?(this.removeChild(We),Be.appendData(We.data)):(Be.normalize(),Be=We)}},isSupported:function(Be,We){return this.ownerDocument.implementation.hasFeature(Be,We)},hasAttributes:function(){return this.attributes.length>0},lookupPrefix:function(Be){for(var We=this;We;){var dt=We._nsMap;if(dt){for(var Tt in dt)if(Object.prototype.hasOwnProperty.call(dt,Tt)&&dt[Tt]===Be)return Tt}We=We.nodeType==f?We.ownerDocument:We.parentNode}return null},lookupNamespaceURI:function(Be){for(var We=this;We;){var dt=We._nsMap;if(dt&&Object.prototype.hasOwnProperty.call(dt,Be))return dt[Be];We=We.nodeType==f?We.ownerDocument:We.parentNode}return null},isDefaultNamespace:function(Be){var We=this.lookupPrefix(Be);return We==null}};function X(Be){return Be=="<"&&"&lt;"||Be==">"&&"&gt;"||Be=="&"&&"&amp;"||Be=='"'&&"&quot;"||"&#"+Be.charCodeAt()+";"}l(c,k),l(c,k.prototype);function W(Be,We){if(We(Be))return!0;if(Be=Be.firstChild)do if(W(Be,We))return!0;while(Be=Be.nextSibling)}function Y(){this.ownerDocument=this}function te(Be,We,dt){Be&&Be._inc++;var Tt=dt.namespaceURI;Tt===i.XMLNS&&(We._nsMap[dt.prefix?dt.localName:""]=dt.value)}function oe(Be,We,dt,Tt){Be&&Be._inc++;var nr=dt.namespaceURI;nr===i.XMLNS&&delete We._nsMap[dt.prefix?dt.localName:""]}function de(Be,We,dt){if(Be&&Be._inc){Be._inc++;var Tt=We.childNodes;if(dt)Tt[Tt.length++]=dt;else{for(var nr=We.firstChild,Ar=0;nr;)Tt[Ar++]=nr,nr=nr.nextSibling;Tt.length=Ar,delete Tt[Tt.length]}}}function ge(Be,We){var dt=We.previousSibling,Tt=We.nextSibling;return dt?dt.nextSibling=Tt:Be.firstChild=Tt,Tt?Tt.previousSibling=dt:Be.lastChild=dt,We.parentNode=null,We.previousSibling=null,We.nextSibling=null,de(Be.ownerDocument,Be),We}function Ee(Be){return Be&&(Be.nodeType===k.DOCUMENT_NODE||Be.nodeType===k.DOCUMENT_FRAGMENT_NODE||Be.nodeType===k.ELEMENT_NODE)}function Re(Be){return Be&&(Pe(Be)||we(Be)||Ae(Be)||Be.nodeType===k.DOCUMENT_FRAGMENT_NODE||Be.nodeType===k.COMMENT_NODE||Be.nodeType===k.PROCESSING_INSTRUCTION_NODE)}function Ae(Be){return Be&&Be.nodeType===k.DOCUMENT_TYPE_NODE}function Pe(Be){return Be&&Be.nodeType===k.ELEMENT_NODE}function we(Be){return Be&&Be.nodeType===k.TEXT_NODE}function Te(Be,We){var dt=Be.childNodes||[];if(e(dt,Pe)||Ae(We))return!1;var Tt=e(dt,Ae);return!(We&&Tt&&dt.indexOf(Tt)>dt.indexOf(We))}function ke(Be,We){var dt=Be.childNodes||[];function Tt(Ar){return Pe(Ar)&&Ar!==We}if(e(dt,Tt))return!1;var nr=e(dt,Ae);return!(We&&nr&&dt.indexOf(nr)>dt.indexOf(We))}function $e(Be,We,dt){if(!Ee(Be))throw new M(E,"Unexpected parent node type "+Be.nodeType);if(dt&&dt.parentNode!==Be)throw new M(A,"child not in parent");if(!Re(We)||Ae(We)&&Be.nodeType!==k.DOCUMENT_NODE)throw new M(E,"Unexpected node type "+We.nodeType+" for parent node type "+Be.nodeType)}function Ne(Be,We,dt){var Tt=Be.childNodes||[],nr=We.childNodes||[];if(We.nodeType===k.DOCUMENT_FRAGMENT_NODE){var Ar=nr.filter(Pe);if(Ar.length>1||e(nr,we))throw new M(E,"More than one element or text in fragment");if(Ar.length===1&&!Te(Be,dt))throw new M(E,"Element in fragment can not be inserted before doctype")}if(Pe(We)&&!Te(Be,dt))throw new M(E,"Only one element can be added and only after doctype");if(Ae(We)){if(e(Tt,Ae))throw new M(E,"Only one doctype is allowed");var Qr=e(Tt,Pe);if(dt&&Tt.indexOf(Qr)<Tt.indexOf(dt))throw new M(E,"Doctype can only be inserted before an element");if(!dt&&Qr)throw new M(E,"Doctype can not be appended since element is present")}}function ve(Be,We,dt){var Tt=Be.childNodes||[],nr=We.childNodes||[];if(We.nodeType===k.DOCUMENT_FRAGMENT_NODE){var Ar=nr.filter(Pe);if(Ar.length>1||e(nr,we))throw new M(E,"More than one element or text in fragment");if(Ar.length===1&&!ke(Be,dt))throw new M(E,"Element in fragment can not be inserted before doctype")}if(Pe(We)&&!ke(Be,dt))throw new M(E,"Only one element can be added and only after doctype");if(Ae(We)){if(e(Tt,function(oi){return Ae(oi)&&oi!==dt}))throw new M(E,"Only one doctype is allowed");var Qr=e(Tt,Pe);if(dt&&Tt.indexOf(Qr)<Tt.indexOf(dt))throw new M(E,"Doctype can only be inserted before an element")}}function pe(Be,We,dt,Tt){$e(Be,We,dt),Be.nodeType===k.DOCUMENT_NODE&&(Tt||Ne)(Be,We,dt);var nr=We.parentNode;if(nr&&nr.removeChild(We),We.nodeType===_){var Ar=We.firstChild;if(Ar==null)return We;var Qr=We.lastChild}else Ar=Qr=We;var Si=dt?dt.previousSibling:Be.lastChild;Ar.previousSibling=Si,Qr.nextSibling=dt,Si?Si.nextSibling=Ar:Be.firstChild=Ar,dt==null?Be.lastChild=Qr:dt.previousSibling=Qr;do{Ar.parentNode=Be;var oi=Be.ownerDocument||Be;fe(Ar,oi)}while(Ar!==Qr&&(Ar=Ar.nextSibling));return de(Be.ownerDocument||Be,Be),We.nodeType==_&&(We.firstChild=We.lastChild=null),We}function fe(Be,We){if(Be.ownerDocument!==We){if(Be.ownerDocument=We,Be.nodeType===d&&Be.attributes)for(var dt=0;dt<Be.attributes.length;dt++){var Tt=Be.attributes.item(dt);Tt&&(Tt.ownerDocument=We)}for(var nr=Be.firstChild;nr;)fe(nr,We),nr=nr.nextSibling}}function me(Be,We){We.parentNode&&We.parentNode.removeChild(We),We.parentNode=Be,We.previousSibling=Be.lastChild,We.nextSibling=null,We.previousSibling?We.previousSibling.nextSibling=We:Be.firstChild=We,Be.lastChild=We,de(Be.ownerDocument,Be,We);var dt=Be.ownerDocument||Be;return fe(We,dt),We}Y.prototype={nodeName:"#document",nodeType:b,doctype:null,documentElement:null,_inc:1,insertBefore:function(Be,We){if(Be.nodeType==_){for(var dt=Be.firstChild;dt;){var Tt=dt.nextSibling;this.insertBefore(dt,We),dt=Tt}return Be}return pe(this,Be,We),fe(Be,this),this.documentElement===null&&Be.nodeType===d&&(this.documentElement=Be),Be},removeChild:function(Be){return this.documentElement==Be&&(this.documentElement=null),ge(this,Be)},replaceChild:function(Be,We){pe(this,Be,We,ve),fe(Be,this),We&&this.removeChild(We),Pe(Be)&&(this.documentElement=Be)},importNode:function(Be,We){return zt(this,Be,We)},getElementById:function(Be){var We=null;return W(this.documentElement,function(dt){if(dt.nodeType==d&&dt.getAttribute("id")==Be)return We=dt,!0}),We},getElementsByClassName:function(Be){var We=a(Be);return new F(this,function(dt){var Tt=[];return We.length>0&&W(dt.documentElement,function(nr){if(nr!==dt&&nr.nodeType===d){var Ar=nr.getAttribute("class");if(Ar){var Qr=Be===Ar;if(!Qr){var Si=a(Ar);Qr=We.every(s(Si))}Qr&&Tt.push(nr)}}}),Tt})},createElement:function(Be){var We=new Ce;We.ownerDocument=this,We.nodeName=Be,We.tagName=Be,We.localName=Be,We.childNodes=new D;var dt=We.attributes=new V;return dt._ownerElement=We,We},createDocumentFragment:function(){var Be=new vt;return Be.ownerDocument=this,Be.childNodes=new D,Be},createTextNode:function(Be){var We=new it;return We.ownerDocument=this,We.appendData(Be),We},createComment:function(Be){var We=new xt;return We.ownerDocument=this,We.appendData(Be),We},createCDATASection:function(Be){var We=new wt;return We.ownerDocument=this,We.appendData(Be),We},createProcessingInstruction:function(Be,We){var dt=new kt;return dt.ownerDocument=this,dt.tagName=dt.nodeName=dt.target=Be,dt.nodeValue=dt.data=We,dt},createAttribute:function(Be){var We=new Ue;return We.ownerDocument=this,We.name=Be,We.nodeName=Be,We.localName=Be,We.specified=!0,We},createEntityReference:function(Be){var We=new qe;return We.ownerDocument=this,We.nodeName=Be,We},createElementNS:function(Be,We){var dt=new Ce,Tt=We.split(":"),nr=dt.attributes=new V;return dt.childNodes=new D,dt.ownerDocument=this,dt.nodeName=We,dt.tagName=We,dt.namespaceURI=Be,Tt.length==2?(dt.prefix=Tt[0],dt.localName=Tt[1]):dt.localName=We,nr._ownerElement=dt,dt},createAttributeNS:function(Be,We){var dt=new Ue,Tt=We.split(":");return dt.ownerDocument=this,dt.nodeName=We,dt.name=We,dt.namespaceURI=Be,dt.specified=!0,Tt.length==2?(dt.prefix=Tt[0],dt.localName=Tt[1]):dt.localName=We,dt}},u(Y,k);function Ce(){this._nsMap={}}Ce.prototype={nodeType:d,hasAttribute:function(Be){return this.getAttributeNode(Be)!=null},getAttribute:function(Be){var We=this.getAttributeNode(Be);return We&&We.value||""},getAttributeNode:function(Be){return this.attributes.getNamedItem(Be)},setAttribute:function(Be,We){var dt=this.ownerDocument.createAttribute(Be);dt.value=dt.nodeValue=""+We,this.setAttributeNode(dt)},removeAttribute:function(Be){var We=this.getAttributeNode(Be);We&&this.removeAttributeNode(We)},appendChild:function(Be){return Be.nodeType===_?this.insertBefore(Be,null):me(this,Be)},setAttributeNode:function(Be){return this.attributes.setNamedItem(Be)},setAttributeNodeNS:function(Be){return this.attributes.setNamedItemNS(Be)},removeAttributeNode:function(Be){return this.attributes.removeNamedItem(Be.nodeName)},removeAttributeNS:function(Be,We){var dt=this.getAttributeNodeNS(Be,We);dt&&this.removeAttributeNode(dt)},hasAttributeNS:function(Be,We){return this.getAttributeNodeNS(Be,We)!=null},getAttributeNS:function(Be,We){var dt=this.getAttributeNodeNS(Be,We);return dt&&dt.value||""},setAttributeNS:function(Be,We,dt){var Tt=this.ownerDocument.createAttributeNS(Be,We);Tt.value=Tt.nodeValue=""+dt,this.setAttributeNode(Tt)},getAttributeNodeNS:function(Be,We){return this.attributes.getNamedItemNS(Be,We)},getElementsByTagName:function(Be){return new F(this,function(We){var dt=[];return W(We,function(Tt){Tt!==We&&Tt.nodeType==d&&(Be==="*"||Tt.tagName==Be)&&dt.push(Tt)}),dt})},getElementsByTagNameNS:function(Be,We){return new F(this,function(dt){var Tt=[];return W(dt,function(nr){nr!==dt&&nr.nodeType===d&&(Be==="*"||nr.namespaceURI===Be)&&(We==="*"||nr.localName==We)&&Tt.push(nr)}),Tt})}},Y.prototype.getElementsByTagName=Ce.prototype.getElementsByTagName,Y.prototype.getElementsByTagNameNS=Ce.prototype.getElementsByTagNameNS,u(Ce,k);function Ue(){}Ue.prototype.nodeType=f,u(Ue,k);function Qe(){}Qe.prototype={data:"",substringData:function(Be,We){return this.data.substring(Be,Be+We)},appendData:function(Be){Be=this.data+Be,this.nodeValue=this.data=Be,this.length=Be.length},insertData:function(Be,We){this.replaceData(Be,0,We)},appendChild:function(Be){throw new Error(x[E])},deleteData:function(Be,We){this.replaceData(Be,We,"")},replaceData:function(Be,We,dt){var Tt=this.data.substring(0,Be),nr=this.data.substring(Be+We);dt=Tt+dt+nr,this.nodeValue=this.data=dt,this.length=dt.length}},u(Qe,k);function it(){}it.prototype={nodeName:"#text",nodeType:h,splitText:function(Be){var We=this.data,dt=We.substring(Be);We=We.substring(0,Be),this.data=this.nodeValue=We,this.length=We.length;var Tt=this.ownerDocument.createTextNode(dt);return this.parentNode&&this.parentNode.insertBefore(Tt,this.nextSibling),Tt}},u(it,Qe);function xt(){}xt.prototype={nodeName:"#comment",nodeType:m},u(xt,Qe);function wt(){}wt.prototype={nodeName:"#cdata-section",nodeType:p},u(wt,Qe);function $t(){}$t.prototype.nodeType=S,u($t,k);function Mt(){}Mt.prototype.nodeType=C,u(Mt,k);function rt(){}rt.prototype.nodeType=v,u(rt,k);function qe(){}qe.prototype.nodeType=g,u(qe,k);function vt(){}vt.prototype.nodeName="#document-fragment",vt.prototype.nodeType=_,u(vt,k);function kt(){}kt.prototype.nodeType=y,u(kt,k);function Xe(){}Xe.prototype.serializeToString=function(Be,We,dt){return _t.call(Be,We,dt)},k.prototype.toString=_t;function _t(Be,We){var dt=[],Tt=this.nodeType==9&&this.documentElement||this,nr=Tt.prefix,Ar=Tt.namespaceURI;if(Ar&&nr==null){var nr=Tt.lookupPrefix(Ar);if(nr==null)var Qr=[{namespace:Ar,prefix:null}]}return Jt(this,dt,Be,We,Qr),dt.join("")}function Ht(Be,We,dt){var Tt=Be.prefix||"",nr=Be.namespaceURI;if(!nr||Tt==="xml"&&nr===i.XML||nr===i.XMLNS)return!1;for(var Ar=dt.length;Ar--;){var Qr=dt[Ar];if(Qr.prefix===Tt)return Qr.namespace!==nr}return!0}function Pt(Be,We,dt){Be.push(" ",We,'="',dt.replace(/[<>&"\t\n\r]/g,X),'"')}function Jt(Be,We,dt,Tt,nr){if(nr||(nr=[]),Tt)if(Be=Tt(Be),Be){if(typeof Be=="string"){We.push(Be);return}}else return;switch(Be.nodeType){case d:var Ar=Be.attributes,Qr=Ar.length,mt=Be.firstChild,Si=Be.tagName;dt=i.isHTML(Be.namespaceURI)||dt;var oi=Si;if(!dt&&!Be.prefix&&Be.namespaceURI){for(var Yr,vi=0;vi<Ar.length;vi++)if(Ar.item(vi).name==="xmlns"){Yr=Ar.item(vi).value;break}if(!Yr)for(var rr=nr.length-1;rr>=0;rr--){var Ji=nr[rr];if(Ji.prefix===""&&Ji.namespace===Be.namespaceURI){Yr=Ji.namespace;break}}if(Yr!==Be.namespaceURI)for(var rr=nr.length-1;rr>=0;rr--){var Ji=nr[rr];if(Ji.namespace===Be.namespaceURI){Ji.prefix&&(oi=Ji.prefix+":"+Si);break}}}We.push("<",oi);for(var qn=0;qn<Qr;qn++){var ri=Ar.item(qn);ri.prefix=="xmlns"?nr.push({prefix:ri.localName,namespace:ri.value}):ri.nodeName=="xmlns"&&nr.push({prefix:"",namespace:ri.value})}for(var qn=0;qn<Qr;qn++){var ri=Ar.item(qn);if(Ht(ri,dt,nr)){var eo=ri.prefix||"",xn=ri.namespaceURI;Pt(We,eo?"xmlns:"+eo:"xmlns",xn),nr.push({prefix:eo,namespace:xn})}Jt(ri,We,dt,Tt,nr)}if(Si===oi&&Ht(Be,dt,nr)){var eo=Be.prefix||"",xn=Be.namespaceURI;Pt(We,eo?"xmlns:"+eo:"xmlns",xn),nr.push({prefix:eo,namespace:xn})}if(mt||dt&&!/^(?:meta|link|img|br|hr|input)$/i.test(Si)){if(We.push(">"),dt&&/^script$/i.test(Si))for(;mt;)mt.data?We.push(mt.data):Jt(mt,We,dt,Tt,nr.slice()),mt=mt.nextSibling;else for(;mt;)Jt(mt,We,dt,Tt,nr.slice()),mt=mt.nextSibling;We.push("</",oi,">")}else We.push("/>");return;case b:case _:for(var mt=Be.firstChild;mt;)Jt(mt,We,dt,Tt,nr.slice()),mt=mt.nextSibling;return;case f:return Pt(We,Be.name,Be.value);case h:return We.push(Be.data.replace(/[<&>]/g,X));case p:return We.push("<![CDATA[",Be.data,"]]>");case m:return We.push("<!--",Be.data,"-->");case S:var gr=Be.publicId,ce=Be.systemId;if(We.push("<!DOCTYPE ",Be.name),gr)We.push(" PUBLIC ",gr),ce&&ce!="."&&We.push(" ",ce),We.push(">");else if(ce&&ce!=".")We.push(" SYSTEM ",ce,">");else{var fr=Be.internalSubset;fr&&We.push(" [",fr,"]"),We.push(">")}return;case y:return We.push("<?",Be.target," ",Be.data,"?>");case g:return We.push("&",Be.nodeName,";");default:We.push("??",Be.nodeName)}}function zt(Be,We,dt){var Tt;switch(We.nodeType){case d:Tt=We.cloneNode(!1),Tt.ownerDocument=Be;case _:break;case f:dt=!0;break}if(Tt||(Tt=We.cloneNode(!1)),Tt.ownerDocument=Be,Tt.parentNode=null,dt)for(var nr=We.firstChild;nr;)Tt.appendChild(zt(Be,nr,dt)),nr=nr.nextSibling;return Tt}function Bt(Be,We,dt){var Tt=new We.constructor;for(var nr in We)if(Object.prototype.hasOwnProperty.call(We,nr)){var Ar=We[nr];typeof Ar!="object"&&Ar!=Tt[nr]&&(Tt[nr]=Ar)}switch(We.childNodes&&(Tt.childNodes=new D),Tt.ownerDocument=Be,Tt.nodeType){case d:var Qr=We.attributes,Si=Tt.attributes=new V,oi=Qr.length;Si._ownerElement=Tt;for(var Yr=0;Yr<oi;Yr++)Tt.setAttributeNode(Bt(Be,Qr.item(Yr),!0));break;case f:dt=!0}if(dt)for(var vi=We.firstChild;vi;)Tt.appendChild(Bt(Be,vi,dt)),vi=vi.nextSibling;return Tt}function Mr(Be,We,dt){Be[We]=dt}try{if(Object.defineProperty){let Be=function(We){switch(We.nodeType){case d:case _:var dt=[];for(We=We.firstChild;We;)We.nodeType!==7&&We.nodeType!==8&&dt.push(Be(We)),We=We.nextSibling;return dt.join("");default:return We.nodeValue}};Object.defineProperty(F.prototype,"length",{get:function(){return I(this),this.$$length}}),Object.defineProperty(k.prototype,"textContent",{get:function(){return Be(this)},set:function(We){switch(this.nodeType){case d:case _:for(;this.firstChild;)this.removeChild(this.firstChild);(We||String(We))&&this.appendChild(this.ownerDocument.createTextNode(We));break;default:this.data=We,this.value=We,this.nodeValue=We}}}),Mr=function(We,dt,Tt){We["$$"+dt]=Tt}}}catch{}return R0.DocumentType=$t,R0.DOMException=M,R0.DOMImplementation=U,R0.Element=Ce,R0.Node=k,R0.NodeList=D,R0.XMLSerializer=Xe,R0}var rN={},zY={},kce;function uSt(){return kce||(kce=1,(function(t){var e=U6().freeze;t.XML_ENTITIES=e({amp:"&",apos:"'",gt:">",lt:"<",quot:'"'}),t.HTML_ENTITIES=e({Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"⁡",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",AMP:"&",amp:"&",And:"⩓",and:"∧",andand:"⩕",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsd:"∡",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",ap:"≈",apacir:"⩯",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"⁡",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"‵",backsim:"∽",backsimeq:"⋍",Backslash:"∖",Barv:"⫧",barvee:"⊽",Barwed:"⌆",barwed:"⌅",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",Because:"∵",because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"ℬ",Bernoullis:"ℬ",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"⋃",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"⋁",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxDL:"╗",boxDl:"╖",boxdL:"╕",boxdl:"┐",boxDR:"╔",boxDr:"╓",boxdR:"╒",boxdr:"┌",boxH:"═",boxh:"─",boxHD:"╦",boxHd:"╤",boxhD:"╥",boxhd:"┬",boxHU:"╩",boxHu:"╧",boxhU:"╨",boxhu:"┴",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxUL:"╝",boxUl:"╜",boxuL:"╛",boxul:"┘",boxUR:"╚",boxUr:"╙",boxuR:"╘",boxur:"└",boxV:"║",boxv:"│",boxVH:"╬",boxVh:"╫",boxvH:"╪",boxvh:"┼",boxVL:"╣",boxVl:"╢",boxvL:"╡",boxvl:"┤",boxVR:"╠",boxVr:"╟",boxvR:"╞",boxvr:"├",bprime:"‵",Breve:"˘",breve:"˘",brvbar:"¦",Bscr:"ℬ",bscr:"𝒷",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsol:"\\",bsolb:"⧅",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",Cap:"⋒",cap:"∩",capand:"⩄",capbrcup:"⩉",capcap:"⩋",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"ⅅ",caps:"∩︀",caret:"⁁",caron:"ˇ",Cayleys:"ℭ",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",CenterDot:"·",centerdot:"·",Cfr:"ℭ",cfr:"𝔠",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",cir:"○",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"’",clubs:"♣",clubsuit:"♣",Colon:"∷",colon:":",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"ℂ",cong:"≅",congdot:"⩭",Congruent:"≡",Conint:"∯",conint:"∮",ContourIntegral:"∮",Copf:"ℂ",copf:"𝕔",coprod:"∐",Coproduct:"∐",COPY:"©",copy:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",Cross:"⨯",cross:"✗",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",Cup:"⋓",cup:"∪",cupbrcap:"⩈",CupCap:"≍",cupcap:"⩆",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"∪︀",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",Dagger:"‡",dagger:"†",daleth:"ℸ",Darr:"↡",dArr:"⇓",darr:"↓",dash:"‐",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",DD:"ⅅ",dd:"ⅆ",ddagger:"‡",ddarr:"⇊",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",Diamond:"⋄",diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"ⅆ",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrow:"↓",Downarrow:"⇓",downarrow:"↓",DownArrowBar:"⤓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVector:"↽",DownLeftVectorBar:"⥖",DownRightTeeVector:"⥟",DownRightVector:"⇁",DownRightVectorBar:"⥗",DownTee:"⊤",DownTeeArrow:"↧",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",ecir:"≖",Ecirc:"Ê",ecirc:"ê",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",eDot:"≑",edot:"ė",ee:"ⅇ",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"ℓ",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp:" ",emsp13:" ",emsp14:" ",ENG:"Ŋ",eng:"ŋ",ensp:" ",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",Escr:"ℰ",escr:"ℯ",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"ℰ",ExponentialE:"ⅇ",exponentiale:"ⅇ",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ﬃ",fflig:"ﬀ",ffllig:"ﬄ",Ffr:"𝔉",ffr:"𝔣",filig:"ﬁ",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"ﬂ",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",ForAll:"∀",forall:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"ℱ",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"⁄",frown:"⌢",Fscr:"ℱ",fscr:"𝒻",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",gE:"≧",ge:"≥",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",ges:"⩾",gescc:"⪩",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",Gg:"⋙",gg:"≫",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gl:"≷",gla:"⪥",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gnE:"≩",gne:"⪈",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"ℊ",gsim:"≳",gsime:"⪎",gsiml:"⪐",Gt:"≫",GT:">",gt:">",gtcc:"⪧",gtcir:"⩺",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:" ",half:"½",hamilt:"ℋ",HARDcy:"Ъ",hardcy:"ъ",hArr:"⇔",harr:"↔",harrcir:"⥈",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",Hfr:"ℌ",hfr:"𝔥",HilbertSpace:"ℋ",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",Hopf:"ℍ",hopf:"𝕙",horbar:"―",HorizontalLine:"─",Hscr:"ℋ",hscr:"𝒽",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"⁃",hyphen:"‐",Iacute:"Í",iacute:"í",ic:"⁣",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",Ifr:"ℑ",ifr:"𝔦",Igrave:"Ì",igrave:"ì",ii:"ⅈ",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"Ĳ",ijlig:"ĳ",Im:"ℑ",Imacr:"Ī",imacr:"ī",image:"ℑ",ImaginaryI:"ⅈ",imagline:"ℐ",imagpart:"ℑ",imath:"ı",imof:"⊷",imped:"Ƶ",Implies:"⇒",in:"∈",incare:"℅",infin:"∞",infintie:"⧝",inodot:"ı",Int:"∬",int:"∫",intcal:"⊺",integers:"ℤ",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"⁣",InvisibleTimes:"⁢",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",Iscr:"ℐ",iscr:"𝒾",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"⁢",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"ℒ",Lambda:"Λ",lambda:"λ",Lang:"⟪",lang:"⟨",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"ℒ",laquo:"«",Larr:"↞",lArr:"⇐",larr:"←",larrb:"⇤",larrbfs:"⤟",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",lat:"⪫",lAtail:"⤛",latail:"⤙",late:"⪭",lates:"⪭︀",lBarr:"⤎",lbarr:"⤌",lbbrk:"❲",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",lE:"≦",le:"≤",LeftAngleBracket:"⟨",LeftArrow:"←",Leftarrow:"⇐",leftarrow:"←",LeftArrowBar:"⇤",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVector:"⇃",LeftDownVectorBar:"⥙",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrow:"↔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTee:"⊣",LeftTeeArrow:"↤",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangle:"⊲",LeftTriangleBar:"⧏",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVector:"↿",LeftUpVectorBar:"⥘",LeftVector:"↼",LeftVectorBar:"⥒",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",les:"⩽",lescc:"⪨",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",Ll:"⋘",ll:"≪",llarr:"⇇",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoust:"⎰",lmoustache:"⎰",lnap:"⪉",lnapprox:"⪉",lnE:"≨",lne:"⪇",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftarrow:"⟵",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longleftrightarrow:"⟷",longmapsto:"⟼",LongRightArrow:"⟶",Longrightarrow:"⟹",longrightarrow:"⟶",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"∗",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"‎",lrtri:"⊿",lsaquo:"‹",Lscr:"ℒ",lscr:"𝓁",Lsh:"↰",lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"‘",lsquor:"‚",Lstrok:"Ł",lstrok:"ł",Lt:"≪",LT:"<",lt:"<",ltcc:"⪦",ltcir:"⩹",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:" ",Mellintrf:"ℳ",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",mid:"∣",midast:"*",midcir:"⫰",middot:"·",minus:"−",minusb:"⊟",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",Mscr:"ℳ",mscr:"𝓂",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ŉ",napprox:"≉",natur:"♮",natural:"♮",naturals:"ℕ",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"–",ne:"≠",nearhk:"⤤",neArr:"⇗",nearr:"↗",nearrow:"↗",nedot:"≐̸",NegativeMediumSpace:"​",NegativeThickSpace:"​",NegativeThinSpace:"​",NegativeVeryThinSpace:"​",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:`
`,nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nhArr:"⇎",nharr:"↮",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlArr:"⇍",nlarr:"↚",nldr:"‥",nlE:"≦̸",nle:"≰",nLeftarrow:"⇍",nleftarrow:"↚",nLeftrightarrow:"⇎",nleftrightarrow:"↮",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"⁠",NonBreakingSpace:" ",Nopf:"ℕ",nopf:"𝕟",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangle:"⋪",NotLeftTriangleBar:"⧏̸",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangle:"⋫",NotRightTriangleBar:"⧐̸",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",npar:"∦",nparallel:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",npre:"⪯̸",nprec:"⊀",npreceq:"⪯̸",nrArr:"⇏",nrarr:"↛",nrarrc:"⤳̸",nrarrw:"↝̸",nRightarrow:"⇏",nrightarrow:"↛",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:" ",nvap:"≍⃒",nVDash:"⊯",nVdash:"⊮",nvDash:"⊭",nvdash:"⊬",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwArr:"⇖",nwarr:"↖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",ocir:"⊚",Ocirc:"Ô",ocirc:"ô",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"‘",operp:"⦹",oplus:"⊕",Or:"⩔",or:"∨",orarr:"↻",ord:"⩝",order:"ℴ",orderof:"ℴ",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"ℴ",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",Otimes:"⨷",otimes:"⊗",otimesas:"⨶",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",par:"∥",para:"¶",parallel:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"ℳ",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"ℎ",plankv:"ℏ",plus:"+",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"ℌ",pointint:"⨕",Popf:"ℙ",popf:"𝕡",pound:"£",Pr:"⪻",pr:"≺",prap:"⪷",prcue:"≼",prE:"⪳",pre:"⪯",prec:"≺",precapprox:"⪷",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",precsim:"≾",Prime:"″",prime:"′",primes:"ℙ",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportion:"∷",Proportional:"∝",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:" ",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",Qopf:"ℚ",qopf:"𝕢",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"ℍ",quatint:"⨖",quest:"?",questeq:"≟",QUOT:'"',quot:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",Rang:"⟫",rang:"⟩",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",Rarr:"↠",rArr:"⇒",rarr:"→",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",rAtail:"⤜",ratail:"⤚",ratio:"∶",rationals:"ℚ",RBarr:"⤐",rBarr:"⤏",rbarr:"⤍",rbbrk:"❳",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",Re:"ℜ",real:"ℜ",realine:"ℛ",realpart:"ℜ",reals:"ℝ",rect:"▭",REG:"®",reg:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",Rfr:"ℜ",rfr:"𝔯",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrow:"→",Rightarrow:"⇒",rightarrow:"→",RightArrowBar:"⇥",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVector:"⇂",RightDownVectorBar:"⥕",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTee:"⊢",RightTeeArrow:"↦",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangle:"⊳",RightTriangleBar:"⧐",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVector:"↾",RightUpVectorBar:"⥔",RightVector:"⇀",RightVectorBar:"⥓",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"‏",rmoust:"⎱",rmoustache:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",Ropf:"ℝ",ropf:"𝕣",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"›",Rscr:"ℛ",rscr:"𝓇",Rsh:"↱",rsh:"↱",rsqb:"]",rsquo:"’",rsquor:"’",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"‚",Sc:"⪼",sc:"≻",scap:"⪸",Scaron:"Š",scaron:"š",sccue:"≽",scE:"⪴",sce:"⪰",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdot:"⋅",sdotb:"⊡",sdote:"⩦",searhk:"⤥",seArr:"⇘",searr:"↘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"∖",setmn:"∖",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"∣",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"∼",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"∖",smashp:"⨳",smeparsl:"⧤",smid:"∣",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",sol:"/",solb:"⧄",solbar:"⌿",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",squ:"□",Square:"□",square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"∖",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",Sub:"⋐",sub:"⊂",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",Subset:"⋐",subset:"⊂",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succ:"≻",succapprox:"⪸",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",Sum:"∑",sum:"∑",sung:"♪",Sup:"⋑",sup:"⊃",sup1:"¹",sup2:"²",sup3:"³",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",Supset:"⋑",supset:"⊃",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swArr:"⇙",swarr:"↙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:"	",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",Therefore:"∴",therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"∼",ThickSpace:"  ",thinsp:" ",ThinSpace:" ",thkap:"≈",thksim:"∼",THORN:"Þ",thorn:"þ",Tilde:"∼",tilde:"˜",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",times:"×",timesb:"⊠",timesbar:"⨱",timesd:"⨰",tint:"∭",toea:"⤨",top:"⊤",topbot:"⌶",topcir:"⫱",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",TRADE:"™",trade:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",Uarr:"↟",uArr:"⇑",uarr:"↑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"⋃",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrow:"↑",Uparrow:"⇑",uparrow:"↑",UpArrowBar:"⤒",UpArrowDownArrow:"⇅",UpDownArrow:"↕",Updownarrow:"⇕",updownarrow:"↕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",Upsi:"ϒ",upsi:"υ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTee:"⊥",UpTeeArrow:"↥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",vArr:"⇕",varr:"↕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",Vbar:"⫫",vBar:"⫨",vBarv:"⫩",Vcy:"В",vcy:"в",VDash:"⊫",Vdash:"⊩",vDash:"⊨",vdash:"⊢",Vdashl:"⫦",Vee:"⋁",vee:"∨",veebar:"⊻",veeeq:"≚",vellip:"⋮",Verbar:"‖",verbar:"|",Vert:"‖",vert:"|",VerticalBar:"∣",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:" ",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",Wedge:"⋀",wedge:"∧",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"⋃",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xhArr:"⟺",xharr:"⟷",Xi:"Ξ",xi:"ξ",xlArr:"⟸",xlarr:"⟵",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrArr:"⟹",xrarr:"⟶",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"⋁",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",Yuml:"Ÿ",yuml:"ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"ℨ",ZeroWidthSpace:"​",Zeta:"Ζ",zeta:"ζ",Zfr:"ℨ",zfr:"𝔷",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",Zopf:"ℤ",zopf:"𝕫",Zscr:"𝒵",zscr:"𝓏",zwj:"‍",zwnj:"‌"}),t.entityMap=t.HTML_ENTITIES})(zY)),zY}var v4={},Ice;function cSt(){if(Ice)return v4;Ice=1;var t=U6().NAMESPACE,e=/[A-Z_a-z\xC0-\xD6\xD8-\xF6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD]/,i=new RegExp("[\\-\\.0-9"+e.source.slice(1,-1)+"\\u00B7\\u0300-\\u036F\\u203F-\\u2040]"),n=new RegExp("^"+e.source+i.source+"*(?::"+e.source+i.source+"*)?$"),r=0,o=1,a=2,s=3,l=4,u=5,c=6,d=7;function f(E,A){this.message=E,this.locator=A,Error.captureStackTrace&&Error.captureStackTrace(this,f)}f.prototype=new Error,f.prototype.name=f.name;function h(){}h.prototype={parse:function(E,A,R){var M=this.domBuilder;M.startDocument(),S(A,A={}),p(E,A,R,M,this.errorHandler),M.endDocument()}};function p(E,A,R,M,D){function F(me){if(me>65535){me-=65536;var Ce=55296+(me>>10),Ue=56320+(me&1023);return String.fromCharCode(Ce,Ue)}else return String.fromCharCode(me)}function I(me){var Ce=me.slice(1,-1);return Object.hasOwnProperty.call(R,Ce)?R[Ce]:Ce.charAt(0)==="#"?F(parseInt(Ce.substr(1).replace("x","0x"))):(D.error("entity not found:"+me),me)}function V(me){if(me>Y){var Ce=E.substring(Y,me).replace(/&#?\w+;/g,I);k&&z(Y),M.characters(Ce,0,me-Y),Y=me}}function z(me,Ce){for(;me>=H&&(Ce=U.exec(E));)G=Ce.index,H=G+Ce[0].length,k.lineNumber++;k.columnNumber=me-G+1}for(var G=0,H=0,U=/.*(?:\r\n?|\n)|.*$/g,k=M.locator,X=[{currentNSMap:A}],W={},Y=0;;){try{var te=E.indexOf("<",Y);if(te<0){if(!E.substr(Y).match(/^\s*$/)){var oe=M.doc,de=oe.createTextNode(E.substr(Y));oe.appendChild(de),M.currentElement=de}return}switch(te>Y&&V(te),E.charAt(te+1)){case"/":var $e=E.indexOf(">",te+3),ge=E.substring(te+2,$e).replace(/[ \t\n\r]+$/g,""),Ee=X.pop();$e<0?(ge=E.substring(te+2).replace(/[\s<].*/,""),D.error("end tag name: "+ge+" is not complete:"+Ee.tagName),$e=te+1+ge.length):ge.match(/\s</)&&(ge=ge.replace(/[\s<].*/,""),D.error("end tag name: "+ge+" maybe not complete"),$e=te+1+ge.length);var Re=Ee.localNSMap,Ae=Ee.tagName==ge,Pe=Ae||Ee.tagName&&Ee.tagName.toLowerCase()==ge.toLowerCase();if(Pe){if(M.endElement(Ee.uri,Ee.localName,ge),Re)for(var we in Re)Object.prototype.hasOwnProperty.call(Re,we)&&M.endPrefixMapping(we);Ae||D.fatalError("end tag name: "+ge+" is not match the current start tagName:"+Ee.tagName)}else X.push(Ee);$e++;break;case"?":k&&z(te),$e=C(E,te,M);break;case"!":k&&z(te),$e=_(E,te,M,D);break;default:k&&z(te);var Te=new P,ke=X[X.length-1].currentNSMap,$e=v(E,te,Te,ke,I,D),Ne=Te.length;if(!Te.closed&&b(E,$e,Te.tagName,W)&&(Te.closed=!0,R.nbsp||D.warning("unclosed xml attribute")),k&&Ne){for(var ve=g(k,{}),pe=0;pe<Ne;pe++){var fe=Te[pe];z(fe.offset),fe.locator=g(k,{})}M.locator=ve,y(Te,M,ke)&&X.push(Te),M.locator=k}else y(Te,M,ke)&&X.push(Te);t.isHTML(Te.uri)&&!Te.closed?$e=m(E,$e,Te.tagName,I,M):$e++}}catch(me){if(me instanceof f)throw me;D.error("element parse error: "+me),$e=-1}$e>Y?Y=$e:V(Math.max(te,Y)+1)}}function g(E,A){return A.lineNumber=E.lineNumber,A.columnNumber=E.columnNumber,A}function v(E,A,R,M,D,F){function I(k,X,W){R.attributeNames.hasOwnProperty(k)&&F.fatalError("Attribute "+k+" redefined"),R.addValue(k,X.replace(/[\t\n\r]/g," ").replace(/&#?\w+;/g,D),W)}for(var V,z,G=++A,H=r;;){var U=E.charAt(G);switch(U){case"=":if(H===o)V=E.slice(A,G),H=s;else if(H===a)H=s;else throw new Error("attribute equal must after attrName");break;case"'":case'"':if(H===s||H===o)if(H===o&&(F.warning('attribute value must after "="'),V=E.slice(A,G)),A=G+1,G=E.indexOf(U,A),G>0)z=E.slice(A,G),I(V,z,A-1),H=u;else throw new Error("attribute value no end '"+U+"' match");else if(H==l)z=E.slice(A,G),I(V,z,A),F.warning('attribute "'+V+'" missed start quot('+U+")!!"),A=G+1,H=u;else throw new Error('attribute value must after "="');break;case"/":switch(H){case r:R.setTagName(E.slice(A,G));case u:case c:case d:H=d,R.closed=!0;case l:case o:break;case a:R.closed=!0;break;default:throw new Error("attribute invalid close char('/')")}break;case"":return F.error("unexpected end of input"),H==r&&R.setTagName(E.slice(A,G)),G;case">":switch(H){case r:R.setTagName(E.slice(A,G));case u:case c:case d:break;case l:case o:z=E.slice(A,G),z.slice(-1)==="/"&&(R.closed=!0,z=z.slice(0,-1));case a:H===a&&(z=V),H==l?(F.warning('attribute "'+z+'" missed quot(")!'),I(V,z,A)):((!t.isHTML(M[""])||!z.match(/^(?:disabled|checked|selected)$/i))&&F.warning('attribute "'+z+'" missed value!! "'+z+'" instead!!'),I(z,z,A));break;case s:throw new Error("attribute value missed!!")}return G;case"":U=" ";default:if(U<=" ")switch(H){case r:R.setTagName(E.slice(A,G)),H=c;break;case o:V=E.slice(A,G),H=a;break;case l:var z=E.slice(A,G);F.warning('attribute "'+z+'" missed quot(")!!'),I(V,z,A);case u:H=c;break}else switch(H){case a:R.tagName,(!t.isHTML(M[""])||!V.match(/^(?:disabled|checked|selected)$/i))&&F.warning('attribute "'+V+'" missed value!! "'+V+'" instead2!!'),I(V,V,A),A=G,H=o;break;case u:F.warning('attribute space is required"'+V+'"!!');case c:H=o,A=G;break;case s:H=l,A=G;break;case d:throw new Error("elements closed character '/' and '>' must be connected to")}}G++}}function y(E,A,R){for(var M=E.tagName,D=null,U=E.length;U--;){var F=E[U],I=F.qName,V=F.value,k=I.indexOf(":");if(k>0)var z=F.prefix=I.slice(0,k),G=I.slice(k+1),H=z==="xmlns"&&G;else G=I,z=null,H=I==="xmlns"&&"";F.localName=G,H!==!1&&(D==null&&(D={},S(R,R={})),R[H]=D[H]=V,F.uri=t.XMLNS,A.startPrefixMapping(H,V))}for(var U=E.length;U--;){F=E[U];var z=F.prefix;z&&(z==="xml"&&(F.uri=t.XML),z!=="xmlns"&&(F.uri=R[z||""]))}var k=M.indexOf(":");k>0?(z=E.prefix=M.slice(0,k),G=E.localName=M.slice(k+1)):(z=null,G=E.localName=M);var X=E.uri=R[z||""];if(A.startElement(X,G,M,E),E.closed){if(A.endElement(X,G,M),D)for(z in D)Object.prototype.hasOwnProperty.call(D,z)&&A.endPrefixMapping(z)}else return E.currentNSMap=R,E.localNSMap=D,!0}function m(E,A,R,M,D){if(/^(?:script|textarea)$/i.test(R)){var F=E.indexOf("</"+R+">",A),I=E.substring(A+1,F);if(/[&<]/.test(I))return/^script$/i.test(R)?(D.characters(I,0,I.length),F):(I=I.replace(/&#?\w+;/g,M),D.characters(I,0,I.length),F)}return A+1}function b(E,A,R,M){var D=M[R];return D==null&&(D=E.lastIndexOf("</"+R+">"),D<A&&(D=E.lastIndexOf("</"+R)),M[R]=D),D<A}function S(E,A){for(var R in E)Object.prototype.hasOwnProperty.call(E,R)&&(A[R]=E[R])}function _(E,A,R,M){var D=E.charAt(A+2);switch(D){case"-":if(E.charAt(A+3)==="-"){var F=E.indexOf("-->",A+4);return F>A?(R.comment(E,A+4,F-A-4),F+3):(M.error("Unclosed comment"),-1)}else return-1;default:if(E.substr(A+3,6)=="CDATA["){var F=E.indexOf("]]>",A+9);return R.startCDATA(),R.characters(E,A+9,F-A-9),R.endCDATA(),F+3}var I=x(E,A),V=I.length;if(V>1&&/!doctype/i.test(I[0][0])){var z=I[1][0],G=!1,H=!1;V>3&&(/^public$/i.test(I[2][0])?(G=I[3][0],H=V>4&&I[4][0]):/^system$/i.test(I[2][0])&&(H=I[3][0]));var U=I[V-1];return R.startDTD(z,G,H),R.endDTD(),U.index+U[0].length}}return-1}function C(E,A,R){var M=E.indexOf("?>",A);if(M){var D=E.substring(A,M).match(/^<\?(\S*)\s*([\s\S]*?)\s*$/);return D?(D[0].length,R.processingInstruction(D[1],D[2]),M+2):-1}return-1}function P(){this.attributeNames={}}P.prototype={setTagName:function(E){if(!n.test(E))throw new Error("invalid tagName:"+E);this.tagName=E},addValue:function(E,A,R){if(!n.test(E))throw new Error("invalid attribute:"+E);this.attributeNames[E]=this.length,this[this.length++]={qName:E,value:A,offset:R}},length:0,getLocalName:function(E){return this[E].localName},getLocator:function(E){return this[E].locator},getQName:function(E){return this[E].qName},getURI:function(E){return this[E].uri},getValue:function(E){return this[E].value}};function x(E,A){var R,M=[],D=/'[^']+'|"[^"]+"|[^\s<>\/=]+=?|(\/?\s*>|<)/g;for(D.lastIndex=A,D.exec(E);R=D.exec(E);)if(M.push(R),R[1])return M}return v4.XMLReader=h,v4.ParseError=f,v4}var Nce;function dSt(){if(Nce)return rN;Nce=1;var t=U6(),e=dIe(),i=uSt(),n=cSt(),r=e.DOMImplementation,o=t.NAMESPACE,a=n.ParseError,s=n.XMLReader;function l(v){return v.replace(/\r[\n\u0085]/g,`
`).replace(/[\r\u0085\u2028]/g,`
`)}function u(v){this.options=v||{locator:{}}}u.prototype.parseFromString=function(v,y){var m=this.options,b=new s,S=m.domBuilder||new d,_=m.errorHandler,C=m.locator,P=m.xmlns||{},x=/\/x?html?$/.test(y),E=x?i.HTML_ENTITIES:i.XML_ENTITIES;C&&S.setDocumentLocator(C),b.errorHandler=c(_,S,C),b.domBuilder=m.domBuilder||S,x&&(P[""]=o.HTML),P.xml=P.xml||o.XML;var A=m.normalizeLineEndings||l;return v&&typeof v=="string"?b.parse(A(v),P,E):b.errorHandler.error("invalid doc source"),S.doc};function c(v,y,m){if(!v){if(y instanceof d)return y;v=y}var b={},S=v instanceof Function;m=m||{};function _(C){var P=v[C];!P&&S&&(P=v.length==2?function(x){v(C,x)}:v),b[C]=P&&function(x){P("[xmldom "+C+"]	"+x+h(m))}||function(){}}return _("warning"),_("error"),_("fatalError"),b}function d(){this.cdata=!1}function f(v,y){y.lineNumber=v.lineNumber,y.columnNumber=v.columnNumber}d.prototype={startDocument:function(){this.doc=new r().createDocument(null,null,null),this.locator&&(this.doc.documentURI=this.locator.systemId)},startElement:function(v,y,m,b){var S=this.doc,_=S.createElementNS(v,m||y),C=b.length;g(this,_),this.currentElement=_,this.locator&&f(this.locator,_);for(var P=0;P<C;P++){var v=b.getURI(P),x=b.getValue(P),m=b.getQName(P),E=S.createAttributeNS(v,m);this.locator&&f(b.getLocator(P),E),E.value=E.nodeValue=x,_.setAttributeNode(E)}},endElement:function(v,y,m){var b=this.currentElement;b.tagName,this.currentElement=b.parentNode},startPrefixMapping:function(v,y){},endPrefixMapping:function(v){},processingInstruction:function(v,y){var m=this.doc.createProcessingInstruction(v,y);this.locator&&f(this.locator,m),g(this,m)},ignorableWhitespace:function(v,y,m){},characters:function(v,y,m){if(v=p.apply(this,arguments),v){if(this.cdata)var b=this.doc.createCDATASection(v);else var b=this.doc.createTextNode(v);this.currentElement?this.currentElement.appendChild(b):/^\s*$/.test(v)&&this.doc.appendChild(b),this.locator&&f(this.locator,b)}},skippedEntity:function(v){},endDocument:function(){this.doc.normalize()},setDocumentLocator:function(v){(this.locator=v)&&(v.lineNumber=0)},comment:function(v,y,m){v=p.apply(this,arguments);var b=this.doc.createComment(v);this.locator&&f(this.locator,b),g(this,b)},startCDATA:function(){this.cdata=!0},endCDATA:function(){this.cdata=!1},startDTD:function(v,y,m){var b=this.doc.implementation;if(b&&b.createDocumentType){var S=b.createDocumentType(v,y,m);this.locator&&f(this.locator,S),g(this,S),this.doc.doctype=S}},warning:function(v){console.warn("[xmldom warning]	"+v,h(this.locator))},error:function(v){console.error("[xmldom error]	"+v,h(this.locator))},fatalError:function(v){throw new a(v,this.locator)}};function h(v){if(v)return`
@`+(v.systemId||"")+"#[line:"+v.lineNumber+",col:"+v.columnNumber+"]"}function p(v,y,m){return typeof v=="string"?v.substr(y,m):v.length>=y+m||y?new java.lang.String(v,y,m)+"":v}"endDTD,startEntity,endEntity,attributeDecl,elementDecl,externalEntityDecl,internalEntityDecl,resolveEntity,getExternalSubset,notationDecl,unparsedEntityDecl".replace(/\w+/g,function(v){d.prototype[v]=function(){return null}});function g(v,y){v.currentElement?v.currentElement.appendChild(y):v.doc.appendChild(y)}return rN.__DOMHandler=d,rN.normalizeLineEndings=l,rN.DOMParser=u,rN}var Fce;function fSt(){if(Fce)return tN;Fce=1;var t=dIe();return tN.DOMImplementation=t.DOMImplementation,tN.XMLSerializer=t.XMLSerializer,tN.DOMParser=dSt().DOMParser,tN}var hSt=fSt();/*! @name mpd-parser @version 0.22.1 @license Apache-2.0 */var Bce=function(e){return!!e&&typeof e=="object"},If=function t(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return i.reduce(function(r,o){return typeof o!="object"||Object.keys(o).forEach(function(a){Array.isArray(r[a])&&Array.isArray(o[a])?r[a]=r[a].concat(o[a]):Bce(r[a])&&Bce(o[a])?r[a]=t(r[a],o[a]):r[a]=o[a]}),r},{})},fIe=function(e){return Object.keys(e).map(function(i){return e[i]})},pSt=function(e,i){for(var n=[],r=e;r<i;r++)n.push(r);return n},z6=function(e){return e.reduce(function(i,n){return i.concat(n)},[])},hIe=function(e){if(!e.length)return[];for(var i=[],n=0;n<e.length;n++)i.push(e[n]);return i},gSt=function(e,i){return e.reduce(function(n,r,o){return r[i]&&n.push(o),n},[])},IZ=function(e,i){for(var n=0;n<e.length;n++)if(i(e[n]))return n;return-1},vSt=function(e,i){return fIe(e.reduce(function(n,r){return r.forEach(function(o){n[i(o)]=o}),n},{}))},Gk={INVALID_NUMBER_OF_PERIOD:"INVALID_NUMBER_OF_PERIOD",DASH_EMPTY_MANIFEST:"DASH_EMPTY_MANIFEST",DASH_INVALID_XML:"DASH_INVALID_XML",NO_BASE_URL:"NO_BASE_URL",SEGMENT_TIME_UNSPECIFIED:"SEGMENT_TIME_UNSPECIFIED",UNSUPPORTED_UTC_TIMING_SCHEME:"UNSUPPORTED_UTC_TIMING_SCHEME"},M3=function(e){var i=e.baseUrl,n=i===void 0?"":i,r=e.source,o=r===void 0?"":r,a=e.range,s=a===void 0?"":a,l=e.indexRange,u=l===void 0?"":l,c={uri:o,resolvedUri:H6(n||"",o)};if(s||u){var d=s||u,f=d.split("-"),h=Ct.BigInt?Ct.BigInt(f[0]):parseInt(f[0],10),p=Ct.BigInt?Ct.BigInt(f[1]):parseInt(f[1],10);h<Number.MAX_SAFE_INTEGER&&typeof h=="bigint"&&(h=Number(h)),p<Number.MAX_SAFE_INTEGER&&typeof p=="bigint"&&(p=Number(p));var g;typeof p=="bigint"||typeof h=="bigint"?g=Ct.BigInt(p)-Ct.BigInt(h)+Ct.BigInt(1):g=p-h+1,typeof g=="bigint"&&g<Number.MAX_SAFE_INTEGER&&(g=Number(g)),c.byterange={length:g,offset:h}}return c},ySt=function(e){var i;return typeof e.offset=="bigint"||typeof e.length=="bigint"?i=Ct.BigInt(e.offset)+Ct.BigInt(e.length)-Ct.BigInt(1):i=e.offset+e.length-1,e.offset+"-"+i},jce=function(e){return e&&typeof e!="number"&&(e=parseInt(e,10)),isNaN(e)?null:e},mSt={static:function(e){var i=e.duration,n=e.timescale,r=n===void 0?1:n,o=e.sourceDuration,a=e.periodDuration,s=jce(e.endNumber),l=i/r;return typeof s=="number"?{start:0,end:s}:typeof a=="number"?{start:0,end:a/l}:{start:0,end:o/l}},dynamic:function(e){var i=e.NOW,n=e.clientOffset,r=e.availabilityStartTime,o=e.timescale,a=o===void 0?1:o,s=e.duration,l=e.periodStart,u=l===void 0?0:l,c=e.minimumUpdatePeriod,d=c===void 0?0:c,f=e.timeShiftBufferDepth,h=f===void 0?1/0:f,p=jce(e.endNumber),g=(i+n)/1e3,v=r+u,y=g+d,m=y-v,b=Math.ceil(m*a/s),S=Math.floor((g-v-h)*a/s),_=Math.floor((g-v)*a/s);return{start:Math.max(0,S),end:typeof p=="number"?p:Math.min(b,_)}}},bSt=function(e){return function(i){var n=e.duration,r=e.timescale,o=r===void 0?1:r,a=e.periodStart,s=e.startNumber,l=s===void 0?1:s;return{number:l+i,duration:n/o,timeline:a,time:i*n}}},vte=function(e){var i=e.type,n=e.duration,r=e.timescale,o=r===void 0?1:r,a=e.periodDuration,s=e.sourceDuration,l=mSt[i](e),u=l.start,c=l.end,d=pSt(u,c).map(bSt(e));if(i==="static"){var f=d.length-1,h=typeof a=="number"?a:s;d[f].duration=h-n/o*f}return d},pIe=function(e){var i=e.baseUrl,n=e.initialization,r=n===void 0?{}:n,o=e.sourceDuration,a=e.indexRange,s=a===void 0?"":a,l=e.periodStart,u=e.presentationTime,c=e.number,d=c===void 0?0:c,f=e.duration;if(!i)throw new Error(Gk.NO_BASE_URL);var h=M3({baseUrl:i,source:r.sourceURL,range:r.range}),p=M3({baseUrl:i,source:i,indexRange:s});if(p.map=h,f){var g=vte(e);g.length&&(p.duration=g[0].duration,p.timeline=g[0].timeline)}else o&&(p.duration=o,p.timeline=l);return p.presentationTime=u||l,p.number=d,[p]},yte=function(e,i,n){var r=e.sidx.map?e.sidx.map:null,o=e.sidx.duration,a=e.timeline||0,s=e.sidx.byterange,l=s.offset+s.length,u=i.timescale,c=i.references.filter(function(E){return E.referenceType!==1}),d=[],f=e.endList?"static":"dynamic",h=e.sidx.timeline,p=h,g=e.mediaSequence||0,v;typeof i.firstOffset=="bigint"?v=Ct.BigInt(l)+i.firstOffset:v=l+i.firstOffset;for(var y=0;y<c.length;y++){var m=i.references[y],b=m.referencedSize,S=m.subsegmentDuration,_=void 0;typeof v=="bigint"?_=v+Ct.BigInt(b)-Ct.BigInt(1):_=v+b-1;var C=v+"-"+_,P={baseUrl:n,timescale:u,timeline:a,periodStart:h,presentationTime:p,number:g,duration:S,sourceDuration:o,indexRange:C,type:f},x=pIe(P)[0];r&&(x.map=r),d.push(x),typeof v=="bigint"?v+=Ct.BigInt(b):v+=b,p+=S/u,g++}return e.segments=d,e},SSt=["AUDIO","SUBTITLES"],_St=1/60,gIe=function(e){return vSt(e,function(i){var n=i.timeline;return n}).sort(function(i,n){return i.timeline>n.timeline?1:-1})},PSt=function(e,i){for(var n=0;n<e.length;n++)if(e[n].attributes.NAME===i)return e[n];return null},Vce=function(e){var i=[];return lSt(e,SSt,function(n,r,o,a){i=i.concat(n.playlists||[])}),i},Hce=function(e){var i=e.playlist,n=e.mediaSequence;i.mediaSequence=n,i.segments.forEach(function(r,o){r.number=i.mediaSequence+o})},CSt=function(e){var i=e.oldPlaylists,n=e.newPlaylists,r=e.timelineStarts;n.forEach(function(o){o.discontinuitySequence=IZ(r,function(c){var d=c.timeline;return d===o.timeline});var a=PSt(i,o.attributes.NAME);if(a&&!o.sidx){var s=o.segments[0],l=IZ(a.segments,function(c){return Math.abs(c.presentationTime-s.presentationTime)<_St});if(l===-1){Hce({playlist:o,mediaSequence:a.mediaSequence+a.segments.length}),o.segments[0].discontinuity=!0,o.discontinuityStarts.unshift(0),(!a.segments.length&&o.timeline>a.timeline||a.segments.length&&o.timeline>a.segments[a.segments.length-1].timeline)&&o.discontinuitySequence--;return}var u=a.segments[l];u.discontinuity&&!s.discontinuity&&(s.discontinuity=!0,o.discontinuityStarts.unshift(0),o.discontinuitySequence--),Hce({playlist:o,mediaSequence:a.segments[l].number})}})},TSt=function(e){var i=e.oldManifest,n=e.newManifest,r=i.playlists.concat(Vce(i)),o=n.playlists.concat(Vce(n));return n.timelineStarts=gIe([i.timelineStarts,n.timelineStarts]),CSt({oldPlaylists:r,newPlaylists:o,timelineStarts:n.timelineStarts}),n},$6=function(e){return e&&e.uri+"-"+ySt(e.byterange)},$Y=function(e){var i=fIe(e.reduce(function(n,r){var o=r.attributes.id+(r.attributes.lang||"");if(!n[o])n[o]=r,n[o].attributes.timelineStarts=[];else{if(r.segments){var a;r.segments[0]&&(r.segments[0].discontinuity=!0),(a=n[o].segments).push.apply(a,r.segments)}r.attributes.contentProtection&&(n[o].attributes.contentProtection=r.attributes.contentProtection)}return n[o].attributes.timelineStarts.push({start:r.attributes.periodStart,timeline:r.attributes.periodStart}),n},{}));return i.map(function(n){return n.discontinuityStarts=gSt(n.segments||[],"discontinuity"),n})},mte=function(e,i){var n=$6(e.sidx),r=n&&i[n]&&i[n].sidx;return r&&yte(e,r,e.sidx.resolvedUri),e},xSt=function(e,i){if(i===void 0&&(i={}),!Object.keys(i).length)return e;for(var n in e)e[n]=mte(e[n],i);return e},ESt=function(e,i){var n,r=e.attributes,o=e.segments,a=e.sidx,s=e.mediaSequence,l=e.discontinuitySequence,u=e.discontinuityStarts,c={attributes:(n={NAME:r.id,BANDWIDTH:r.bandwidth,CODECS:r.codecs},n["PROGRAM-ID"]=1,n),uri:"",endList:r.type==="static",timeline:r.periodStart,resolvedUri:"",targetDuration:r.duration,discontinuitySequence:l,discontinuityStarts:u,timelineStarts:r.timelineStarts,mediaSequence:s,segments:o};return r.contentProtection&&(c.contentProtection=r.contentProtection),a&&(c.sidx=a),i&&(c.attributes.AUDIO="audio",c.attributes.SUBTITLES="subs"),c},wSt=function(e){var i,n=e.attributes,r=e.segments,o=e.mediaSequence,a=e.discontinuityStarts,s=e.discontinuitySequence;typeof r>"u"&&(r=[{uri:n.baseUrl,timeline:n.periodStart,resolvedUri:n.baseUrl||"",duration:n.sourceDuration,number:0}],n.duration=n.sourceDuration);var l=(i={NAME:n.id,BANDWIDTH:n.bandwidth},i["PROGRAM-ID"]=1,i);return n.codecs&&(l.CODECS=n.codecs),{attributes:l,uri:"",endList:n.type==="static",timeline:n.periodStart,resolvedUri:n.baseUrl||"",targetDuration:n.duration,timelineStarts:n.timelineStarts,discontinuityStarts:a,discontinuitySequence:s,mediaSequence:o,segments:r}},ASt=function(e,i,n){i===void 0&&(i={}),n===void 0&&(n=!1);var r,o=e.reduce(function(s,l){var u=l.attributes.role&&l.attributes.role.value||"",c=l.attributes.lang||"",d=l.attributes.label||"main";if(c&&!l.attributes.label){var f=u?" ("+u+")":"";d=""+l.attributes.lang+f}s[d]||(s[d]={language:c,autoselect:!0,default:u==="main",playlists:[],uri:""});var h=mte(ESt(l,n),i);return s[d].playlists.push(h),typeof r>"u"&&u==="main"&&(r=l,r.default=!0),s},{});if(!r){var a=Object.keys(o)[0];o[a].default=!0}return o},OSt=function(e,i){return i===void 0&&(i={}),e.reduce(function(n,r){var o=r.attributes.lang||"text";return n[o]||(n[o]={language:o,default:!1,autoselect:!1,playlists:[],uri:""}),n[o].playlists.push(mte(wSt(r),i)),n},{})},DSt=function(e){return e.reduce(function(i,n){return n&&n.forEach(function(r){var o=r.channel,a=r.language;i[a]={autoselect:!1,default:!1,instreamId:o,language:a},r.hasOwnProperty("aspectRatio")&&(i[a].aspectRatio=r.aspectRatio),r.hasOwnProperty("easyReader")&&(i[a].easyReader=r.easyReader),r.hasOwnProperty("3D")&&(i[a]["3D"]=r["3D"])}),i},{})},RSt=function(e){var i,n=e.attributes,r=e.segments,o=e.sidx,a=e.discontinuityStarts,s={attributes:(i={NAME:n.id,AUDIO:"audio",SUBTITLES:"subs",RESOLUTION:{width:n.width,height:n.height},CODECS:n.codecs,BANDWIDTH:n.bandwidth},i["PROGRAM-ID"]=1,i),uri:"",endList:n.type==="static",timeline:n.periodStart,resolvedUri:"",targetDuration:n.duration,discontinuityStarts:a,timelineStarts:n.timelineStarts,segments:r};return n.frameRate&&(s.attributes["FRAME-RATE"]=n.frameRate),n.contentProtection&&(s.contentProtection=n.contentProtection),o&&(s.sidx=o),s},MSt=function(e){var i=e.attributes;return i.mimeType==="video/mp4"||i.mimeType==="video/webm"||i.contentType==="video"},LSt=function(e){var i=e.attributes;return i.mimeType==="audio/mp4"||i.mimeType==="audio/webm"||i.contentType==="audio"},kSt=function(e){var i=e.attributes;return i.mimeType==="text/vtt"||i.contentType==="text"},ISt=function(e,i){e.forEach(function(n){n.mediaSequence=0,n.discontinuitySequence=IZ(i,function(r){var o=r.timeline;return o===n.timeline}),n.segments&&n.segments.forEach(function(r,o){r.number=o})})},Uce=function(e){return e?Object.keys(e).reduce(function(i,n){var r=e[n];return i.concat(r.playlists)},[]):[]},NSt=function(e){var i,n=e.dashPlaylists,r=e.locations,o=e.sidxMapping,a=o===void 0?{}:o,s=e.previousManifest;if(!n.length)return{};var l=n[0].attributes,u=l.sourceDuration,c=l.type,d=l.suggestedPresentationDelay,f=l.minimumUpdatePeriod,h=$Y(n.filter(MSt)).map(RSt),p=$Y(n.filter(LSt)),g=$Y(n.filter(kSt)),v=n.map(function(P){return P.attributes.captionServices}).filter(Boolean),y={allowCache:!0,discontinuityStarts:[],segments:[],endList:!0,mediaGroups:(i={AUDIO:{},VIDEO:{}},i["CLOSED-CAPTIONS"]={},i.SUBTITLES={},i),uri:"",duration:u,playlists:xSt(h,a)};f>=0&&(y.minimumUpdatePeriod=f*1e3),r&&(y.locations=r),c==="dynamic"&&(y.suggestedPresentationDelay=d);var m=y.playlists.length===0,b=p.length?ASt(p,a,m):null,S=g.length?OSt(g,a):null,_=h.concat(Uce(b),Uce(S)),C=_.map(function(P){var x=P.timelineStarts;return x});return y.timelineStarts=gIe(C),ISt(_,y.timelineStarts),b&&(y.mediaGroups.AUDIO.audio=b),S&&(y.mediaGroups.SUBTITLES.subs=S),v.length&&(y.mediaGroups["CLOSED-CAPTIONS"].cc=DSt(v)),s?TSt({oldManifest:s,newManifest:y}):y},FSt=function(e,i,n){var r=e.NOW,o=e.clientOffset,a=e.availabilityStartTime,s=e.timescale,l=s===void 0?1:s,u=e.periodStart,c=u===void 0?0:u,d=e.minimumUpdatePeriod,f=d===void 0?0:d,h=(r+o)/1e3,p=a+c,g=h+f,v=g-p;return Math.ceil((v*l-i)/n)},vIe=function(e,i){for(var n=e.type,r=e.minimumUpdatePeriod,o=r===void 0?0:r,a=e.media,s=a===void 0?"":a,l=e.sourceDuration,u=e.timescale,c=u===void 0?1:u,d=e.startNumber,f=d===void 0?1:d,h=e.periodStart,p=[],g=-1,v=0;v<i.length;v++){var y=i[v],m=y.d,b=y.r||0,S=y.t||0;g<0&&(g=S),S&&S>g&&(g=S);var _=void 0;if(b<0){var C=v+1;C===i.length?n==="dynamic"&&o>0&&s.indexOf("$Number$")>0?_=FSt(e,g,m):_=(l*c-g)/m:_=(i[C].t-g)/m}else _=b+1;for(var P=f+p.length+_,x=f+p.length;x<P;)p.push({number:x,duration:m/c,time:g,timeline:h}),g+=m,x++}return p},BSt=/\$([A-z]*)(?:(%0)([0-9]+)d)?\$/g,jSt=function(e){return function(i,n,r,o){if(i==="$$")return"$";if(typeof e[n]>"u")return i;var a=""+e[n];return n==="RepresentationID"||(r?o=parseInt(o,10):o=1,a.length>=o)?a:""+new Array(o-a.length+1).join("0")+a}},zce=function(e,i){return e.replace(BSt,jSt(i))},VSt=function(e,i){return!e.duration&&!i?[{number:e.startNumber||1,duration:e.sourceDuration,time:0,timeline:e.periodStart}]:e.duration?vte(e):vIe(e,i)},HSt=function(e,i){var n={RepresentationID:e.id,Bandwidth:e.bandwidth||0},r=e.initialization,o=r===void 0?{sourceURL:"",range:""}:r,a=M3({baseUrl:e.baseUrl,source:zce(o.sourceURL,n),range:o.range}),s=VSt(e,i);return s.map(function(l){n.Number=l.number,n.Time=l.time;var u=zce(e.media||"",n),c=e.timescale||1,d=e.presentationTimeOffset||0,f=e.periodStart+(l.time-d)/c,h={uri:u,timeline:l.timeline,duration:l.duration,resolvedUri:H6(e.baseUrl||"",u),map:a,number:l.number,presentationTime:f};return h})},USt=function(e,i){var n=e.baseUrl,r=e.initialization,o=r===void 0?{}:r,a=M3({baseUrl:n,source:o.sourceURL,range:o.range}),s=M3({baseUrl:n,source:i.media,range:i.mediaRange});return s.map=a,s},zSt=function(e,i){var n=e.duration,r=e.segmentUrls,o=r===void 0?[]:r,a=e.periodStart;if(!n&&!i||n&&i)throw new Error(Gk.SEGMENT_TIME_UNSPECIFIED);var s=o.map(function(c){return USt(e,c)}),l;n&&(l=vte(e)),i&&(l=vIe(e,i));var u=l.map(function(c,d){if(s[d]){var f=s[d],h=e.timescale||1,p=e.presentationTimeOffset||0;return f.timeline=c.timeline,f.duration=c.duration,f.number=c.number,f.presentationTime=a+(c.time-p)/h,f}}).filter(function(c){return c});return u},$St=function(e){var i=e.attributes,n=e.segmentInfo,r,o;n.template?(o=HSt,r=If(i,n.template)):n.base?(o=pIe,r=If(i,n.base)):n.list&&(o=zSt,r=If(i,n.list));var a={attributes:i};if(!o)return a;var s=o(r,n.segmentTimeline);if(r.duration){var l=r,u=l.duration,c=l.timescale,d=c===void 0?1:c;r.duration=u/d}else s.length?r.duration=s.reduce(function(f,h){return Math.max(f,Math.ceil(h.duration))},0):r.duration=0;return a.attributes=r,a.segments=s,n.base&&r.indexRange&&(a.sidx=s[0],a.segments=[]),a},WSt=function(e){return e.map($St)},Jl=function(e,i){return hIe(e.childNodes).filter(function(n){var r=n.tagName;return r===i})},bte=function(e){return e.textContent.trim()},GSt=function(e){return parseFloat(e.split("/").reduce(function(i,n){return i/n}))},oL=function(e){var i=31536e3,n=720*60*60,r=1440*60,o=3600,a=60,s=/P(?:(\d*)Y)?(?:(\d*)M)?(?:(\d*)D)?(?:T(?:(\d*)H)?(?:(\d*)M)?(?:([\d.]*)S)?)?/,l=s.exec(e);if(!l)return 0;var u=l.slice(1),c=u[0],d=u[1],f=u[2],h=u[3],p=u[4],g=u[5];return parseFloat(c||0)*i+parseFloat(d||0)*n+parseFloat(f||0)*r+parseFloat(h||0)*o+parseFloat(p||0)*a+parseFloat(g||0)},YSt=function(e){var i=/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/;return i.test(e)&&(e+="Z"),Date.parse(e)},$ce={mediaPresentationDuration:function(e){return oL(e)},availabilityStartTime:function(e){return YSt(e)/1e3},minimumUpdatePeriod:function(e){return oL(e)},suggestedPresentationDelay:function(e){return oL(e)},type:function(e){return e},timeShiftBufferDepth:function(e){return oL(e)},start:function(e){return oL(e)},width:function(e){return parseInt(e,10)},height:function(e){return parseInt(e,10)},bandwidth:function(e){return parseInt(e,10)},frameRate:function(e){return GSt(e)},startNumber:function(e){return parseInt(e,10)},timescale:function(e){return parseInt(e,10)},presentationTimeOffset:function(e){return parseInt(e,10)},duration:function(e){var i=parseInt(e,10);return isNaN(i)?oL(e):i},d:function(e){return parseInt(e,10)},t:function(e){return parseInt(e,10)},r:function(e){return parseInt(e,10)},DEFAULT:function(e){return e}},Fd=function(e){return e&&e.attributes?hIe(e.attributes).reduce(function(i,n){var r=$ce[n.name]||$ce.DEFAULT;return i[n.name]=r(n.value),i},{}):{}},qSt={"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime"},W6=function(e,i){return i.length?z6(e.map(function(n){return i.map(function(r){return H6(n,bte(r))})})):e},Ste=function(e){var i=Jl(e,"SegmentTemplate")[0],n=Jl(e,"SegmentList")[0],r=n&&Jl(n,"SegmentURL").map(function(f){return If({tag:"SegmentURL"},Fd(f))}),o=Jl(e,"SegmentBase")[0],a=n||i,s=a&&Jl(a,"SegmentTimeline")[0],l=n||o||i,u=l&&Jl(l,"Initialization")[0],c=i&&Fd(i);c&&u?c.initialization=u&&Fd(u):c&&c.initialization&&(c.initialization={sourceURL:c.initialization});var d={template:c,segmentTimeline:s&&Jl(s,"S").map(function(f){return Fd(f)}),list:n&&If(Fd(n),{segmentUrls:r,initialization:Fd(u)}),base:o&&If(Fd(o),{initialization:Fd(u)})};return Object.keys(d).forEach(function(f){d[f]||delete d[f]}),d},XSt=function(e,i,n){return function(r){var o=Jl(r,"BaseURL"),a=W6(i,o),s=If(e,Fd(r)),l=Ste(r);return a.map(function(u){return{segmentInfo:If(n,l),attributes:If(s,{baseUrl:u})}})}},KSt=function(e){return e.reduce(function(i,n){var r=Fd(n);r.schemeIdUri&&(r.schemeIdUri=r.schemeIdUri.toLowerCase());var o=qSt[r.schemeIdUri];if(o){i[o]={attributes:r};var a=Jl(n,"cenc:pssh")[0];if(a){var s=bte(a);i[o].pssh=s&&oIe(s)}}return i},{})},ZSt=function(e){if(e.schemeIdUri==="urn:scte:dash:cc:cea-608:2015"){var i=typeof e.value!="string"?[]:e.value.split(";");return i.map(function(r){var o,a;if(a=r,/^CC\d=/.test(r)){var s=r.split("=");o=s[0],a=s[1]}else/^CC\d$/.test(r)&&(o=r);return{channel:o,language:a}})}else if(e.schemeIdUri==="urn:scte:dash:cc:cea-708:2015"){var n=typeof e.value!="string"?[]:e.value.split(";");return n.map(function(r){var o={channel:void 0,language:void 0,aspectRatio:1,easyReader:0,"3D":0};if(/=/.test(r)){var a=r.split("="),s=a[0],l=a[1],u=l===void 0?"":l;o.channel=s,o.language=r,u.split(",").forEach(function(c){var d=c.split(":"),f=d[0],h=d[1];f==="lang"?o.language=h:f==="er"?o.easyReader=Number(h):f==="war"?o.aspectRatio=Number(h):f==="3D"&&(o["3D"]=Number(h))})}else o.language=r;return o.channel&&(o.channel="SERVICE"+o.channel),o})}},JSt=function(e,i,n){return function(r){var o=Fd(r),a=W6(i,Jl(r,"BaseURL")),s=Jl(r,"Role")[0],l={role:Fd(s)},u=If(e,o,l),c=Jl(r,"Accessibility")[0],d=ZSt(Fd(c));d&&(u=If(u,{captionServices:d}));var f=Jl(r,"Label")[0];if(f&&f.childNodes.length){var h=f.childNodes[0].nodeValue.trim();u=If(u,{label:h})}var p=KSt(Jl(r,"ContentProtection"));Object.keys(p).length&&(u=If(u,{contentProtection:p}));var g=Ste(r),v=Jl(r,"Representation"),y=If(n,g);return z6(v.map(XSt(u,a,y)))}},QSt=function(e,i){return function(n,r){var o=W6(i,Jl(n.node,"BaseURL")),a=If(e,{periodStart:n.attributes.start});typeof n.attributes.duration=="number"&&(a.periodDuration=n.attributes.duration);var s=Jl(n.node,"AdaptationSet"),l=Ste(n.node);return z6(s.map(JSt(a,o,l)))}},e_t=function(e){var i=e.attributes,n=e.priorPeriodAttributes,r=e.mpdType;return typeof i.start=="number"?i.start:n&&typeof n.start=="number"&&typeof n.duration=="number"?n.start+n.duration:!n&&r==="static"?0:null},t_t=function(e,i){i===void 0&&(i={});var n=i,r=n.manifestUri,o=r===void 0?"":r,a=n.NOW,s=a===void 0?Date.now():a,l=n.clientOffset,u=l===void 0?0:l,c=Jl(e,"Period");if(!c.length)throw new Error(Gk.INVALID_NUMBER_OF_PERIOD);var d=Jl(e,"Location"),f=Fd(e),h=W6([o],Jl(e,"BaseURL"));f.type=f.type||"static",f.sourceDuration=f.mediaPresentationDuration||0,f.NOW=s,f.clientOffset=u,d.length&&(f.locations=d.map(bte));var p=[];return c.forEach(function(g,v){var y=Fd(g),m=p[v-1];y.start=e_t({attributes:y,priorPeriodAttributes:m?m.attributes:null,mpdType:f.type}),p.push({node:g,attributes:y})}),{locations:f.locations,representationInfo:z6(p.map(QSt(f,h)))}},yIe=function(e){if(e==="")throw new Error(Gk.DASH_EMPTY_MANIFEST);var i=new hSt.DOMParser,n,r;try{n=i.parseFromString(e,"application/xml"),r=n&&n.documentElement.tagName==="MPD"?n.documentElement:null}catch{}if(!r||r&&r.getElementsByTagName("parsererror").length>0)throw new Error(Gk.DASH_INVALID_XML);return r},r_t=function(e){var i=Jl(e,"UTCTiming")[0];if(!i)return null;var n=Fd(i);switch(n.schemeIdUri){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":n.method="HEAD";break;case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":n.method="GET";break;case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":n.method="DIRECT",n.value=Date.parse(n.value);break;case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":default:throw new Error(Gk.UNSUPPORTED_UTC_TIMING_SCHEME)}return n},i_t=function(e,i){i===void 0&&(i={});var n=t_t(yIe(e),i),r=WSt(n.representationInfo);return NSt({dashPlaylists:r,locations:n.locations,sidxMapping:i.sidxMapping,previousManifest:i.previousManifest})},n_t=function(e){return r_t(yIe(e))},WY,Wce;function o_t(){if(Wce)return WY;Wce=1;var t=Math.pow(2,32),e=function(i){var n=new DataView(i.buffer,i.byteOffset,i.byteLength),r;return n.getBigUint64?(r=n.getBigUint64(0),r<Number.MAX_SAFE_INTEGER?Number(r):r):n.getUint32(0)*t+n.getUint32(4)};return WY={getUint64:e,MAX_UINT32:t},WY}var GY,Gce;function a_t(){if(Gce)return GY;Gce=1;var t=o_t().getUint64,e=function(i){var n=new DataView(i.buffer,i.byteOffset,i.byteLength),r={version:i[0],flags:new Uint8Array(i.subarray(1,4)),references:[],referenceId:n.getUint32(4),timescale:n.getUint32(8)},o=12;r.version===0?(r.earliestPresentationTime=n.getUint32(o),r.firstOffset=n.getUint32(o+4),o+=8):(r.earliestPresentationTime=t(i.subarray(o)),r.firstOffset=t(i.subarray(o+8)),o+=16),o+=2;var a=n.getUint16(o);for(o+=2;a>0;o+=12,a--)r.references.push({referenceType:(i[o]&128)>>>7,referencedSize:n.getUint32(o)&2147483647,subsegmentDuration:n.getUint32(o+4),startsWithSap:!!(i[o+8]&128),sapType:(i[o+8]&112)>>>4,sapDeltaTime:n.getUint32(o+8)&268435455});return r};return GY=e,GY}var s_t=a_t();const l_t=wc(s_t);var u_t=Vi([73,68,51]),c_t=function(e,i){i===void 0&&(i=0),e=Vi(e);var n=e[i+5],r=e[i+6]<<21|e[i+7]<<14|e[i+8]<<7|e[i+9],o=(n&16)>>4;return o?r+20:r+10},sj=function t(e,i){return i===void 0&&(i=0),e=Vi(e),e.length-i<10||!Gs(e,u_t,{offset:i})?i:(i+=c_t(e,i),t(e,i))},Yce=function(e){return typeof e=="string"?cIe(e):e},d_t=function(e){return Array.isArray(e)?e.map(function(i){return Yce(i)}):[Yce(e)]},f_t=function t(e,i,n){n===void 0&&(n=!1),i=d_t(i),e=Vi(e);var r=[];if(!i.length)return r;for(var o=0;o<e.length;){var a=(e[o]<<24|e[o+1]<<16|e[o+2]<<8|e[o+3])>>>0,s=e.subarray(o+4,o+8);if(a===0)break;var l=o+a;if(l>e.length){if(n)break;l=e.length}var u=e.subarray(o+8,l);Gs(s,i[0])&&(i.length===1?r.push(u):r.push.apply(r,t(u,i.slice(1),n))),o=l}return r},y4={EBML:Vi([26,69,223,163]),DocType:Vi([66,130]),Segment:Vi([24,83,128,103]),SegmentInfo:Vi([21,73,169,102]),Tracks:Vi([22,84,174,107]),Track:Vi([174]),TrackNumber:Vi([215]),DefaultDuration:Vi([35,227,131]),TrackEntry:Vi([174]),TrackType:Vi([131]),FlagDefault:Vi([136]),CodecID:Vi([134]),CodecPrivate:Vi([99,162]),VideoTrack:Vi([224]),AudioTrack:Vi([225]),Cluster:Vi([31,67,182,117]),Timestamp:Vi([231]),TimestampScale:Vi([42,215,177]),BlockGroup:Vi([160]),BlockDuration:Vi([155]),Block:Vi([161]),SimpleBlock:Vi([163])},NZ=[128,64,32,16,8,4,2,1],h_t=function(e){for(var i=1,n=0;n<NZ.length&&!(e&NZ[n]);n++)i++;return i},Sz=function(e,i,n,r){n===void 0&&(n=!0),r===void 0&&(r=!1);var o=h_t(e[i]),a=e.subarray(i,i+o);return n&&(a=Array.prototype.slice.call(e,i,i+o),a[0]^=NZ[o-1]),{length:o,value:oSt(a,{signed:r}),bytes:a}},qce=function t(e){return typeof e=="string"?e.match(/.{1,2}/g).map(function(i){return t(i)}):typeof e=="number"?aSt(e):e},p_t=function(e){return Array.isArray(e)?e.map(function(i){return qce(i)}):[qce(e)]},g_t=function t(e,i,n){if(n>=i.length)return i.length;var r=Sz(i,n,!1);if(Gs(e.bytes,r.bytes))return n;var o=Sz(i,n+r.length);return t(e,i,n+o.length+o.value+r.length)},Xce=function t(e,i){i=p_t(i),e=Vi(e);var n=[];if(!i.length)return n;for(var r=0;r<e.length;){var o=Sz(e,r,!1),a=Sz(e,r+o.length),s=r+o.length+a.length;a.value===127&&(a.value=g_t(o,e,s),a.value!==e.length&&(a.value-=s));var l=s+a.value>e.length?e.length:s+a.value,u=e.subarray(s,l);Gs(i[0],o.bytes)&&(i.length===1?n.push(u):n=n.concat(t(u,i.slice(1))));var c=o.length+a.length+u.length;r+=c}return n},v_t=Vi([0,0,0,1]),y_t=Vi([0,0,1]),m_t=Vi([0,0,3]),b_t=function(e){for(var i=[],n=1;n<e.length-2;)Gs(e.subarray(n,n+3),m_t)&&(i.push(n+2),n++),n++;if(i.length===0)return e;var r=e.length-i.length,o=new Uint8Array(r),a=0;for(n=0;n<r;a++,n++)a===i[0]&&(a++,i.shift()),o[n]=e[a];return o},mIe=function(e,i,n,r){e=Vi(e),n=[].concat(n);for(var o=0,a,s=0;o<e.length&&(s<r||a);){var l=void 0;if(Gs(e.subarray(o),v_t)?l=4:Gs(e.subarray(o),y_t)&&(l=3),!l){o++;continue}if(s++,a)return b_t(e.subarray(a,o));var u=void 0;i==="h264"?u=e[o+l]&31:i==="h265"&&(u=e[o+l]>>1&63),n.indexOf(u)!==-1&&(a=o+l),o+=l+(i==="h264"?1:2)}return e.subarray(0,0)},S_t=function(e,i,n){return mIe(e,"h264",i,n)},__t=function(e,i,n){return mIe(e,"h265",i,n)},mf={webm:Vi([119,101,98,109]),matroska:Vi([109,97,116,114,111,115,107,97]),flac:Vi([102,76,97,67]),ogg:Vi([79,103,103,83]),ac3:Vi([11,119]),riff:Vi([82,73,70,70]),avi:Vi([65,86,73]),wav:Vi([87,65,86,69]),"3gp":Vi([102,116,121,112,51,103]),mp4:Vi([102,116,121,112]),fmp4:Vi([115,116,121,112]),mov:Vi([102,116,121,112,113,116]),moov:Vi([109,111,111,118]),moof:Vi([109,111,111,102])},Yk={aac:function(e){var i=sj(e);return Gs(e,[255,16],{offset:i,mask:[255,22]})},mp3:function(e){var i=sj(e);return Gs(e,[255,2],{offset:i,mask:[255,6]})},webm:function(e){var i=Xce(e,[y4.EBML,y4.DocType])[0];return Gs(i,mf.webm)},mkv:function(e){var i=Xce(e,[y4.EBML,y4.DocType])[0];return Gs(i,mf.matroska)},mp4:function(e){if(Yk["3gp"](e)||Yk.mov(e))return!1;if(Gs(e,mf.mp4,{offset:4})||Gs(e,mf.fmp4,{offset:4})||Gs(e,mf.moof,{offset:4})||Gs(e,mf.moov,{offset:4}))return!0},mov:function(e){return Gs(e,mf.mov,{offset:4})},"3gp":function(e){return Gs(e,mf["3gp"],{offset:4})},ac3:function(e){var i=sj(e);return Gs(e,mf.ac3,{offset:i})},ts:function(e){if(e.length<189&&e.length>=1)return e[0]===71;for(var i=0;i+188<e.length&&i<188;){if(e[i]===71&&e[i+188]===71)return!0;i+=1}return!1},flac:function(e){var i=sj(e);return Gs(e,mf.flac,{offset:i})},ogg:function(e){return Gs(e,mf.ogg)},avi:function(e){return Gs(e,mf.riff)&&Gs(e,mf.avi,{offset:8})},wav:function(e){return Gs(e,mf.riff)&&Gs(e,mf.wav,{offset:8})},h264:function(e){return S_t(e,7,3).length},h265:function(e){return __t(e,[32,33],3).length}},FZ=Object.keys(Yk).filter(function(t){return t!=="ts"&&t!=="h264"&&t!=="h265"}).concat(["ts","h264","h265"]);FZ.forEach(function(t){var e=Yk[t];Yk[t]=function(i){return e(Vi(i))}});var P_t=Yk,_te=function(e){e=Vi(e);for(var i=0;i<FZ.length;i++){var n=FZ[i];if(P_t[n](e))return n}return""},C_t=function(e){return f_t(e,["moof"]).length>0},YY,Kce;function T_t(){if(Kce)return YY;Kce=1;var t=9e4,e,i,n,r,o,a,s;return e=function(l){return l*t},i=function(l,u){return l*u},n=function(l){return l/t},r=function(l,u){return l/u},o=function(l,u){return e(r(l,u))},a=function(l,u){return i(n(l),u)},s=function(l,u,c){return n(c?l:l-u)},YY={ONE_SECOND_IN_TS:t,secondsToVideoTs:e,secondsToAudioTs:i,videoTsToSeconds:n,audioTsToSeconds:r,audioTsToVideoTs:o,videoTsToAudioTs:a,metadataTsToSeconds:s},YY}var _z=T_t();function BZ(t){return BZ=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},BZ(t)}function x_t(t){try{return Function.toString.call(t).indexOf("[native code]")!==-1}catch{return typeof t=="function"}}function jZ(t){var e=typeof Map=="function"?new Map:void 0;return jZ=function(n){if(n===null||!x_t(n))return n;if(typeof n!="function")throw new TypeError("Super expression must either be null or a function");if(e!==void 0){if(e.has(n))return e.get(n);e.set(n,r)}function r(){return nIe(n,arguments,BZ(this).constructor)}return r.prototype=Object.create(n.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),Wk(r,n)},jZ(t)}/**
 * @license
 * Video.js 7.21.7 <http://videojs.com/>
 * Copyright Brightcove, Inc. <https://www.brightcove.com/>
 * Available under Apache License Version 2.0
 * <https://github.com/videojs/video.js/blob/main/LICENSE>
 *
 * Includes vtt.js <https://github.com/mozilla/vtt.js>
 * Available under Apache License Version 2.0
 * <https://github.com/mozilla/vtt.js/blob/main/LICENSE>
 */var bIe="7.21.7",aS={},wP=function(e,i){return aS[e]=aS[e]||[],i&&(aS[e]=aS[e].concat(i)),aS[e]},E_t=function(e,i){wP(e,i)},SIe=function(e,i){var n=wP(e).indexOf(i);return n<=-1?!1:(aS[e]=aS[e].slice(),aS[e].splice(n,1),!0)},w_t=function(e,i){wP(e,[].concat(i).map(function(n){var r=function o(){return SIe(e,o),n.apply(void 0,arguments)};return r}))},Pz={prefixed:!0},KU=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror","fullscreen"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror","-webkit-full-screen"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror","-moz-full-screen"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError","-ms-fullscreen"]],Zce=KU[0],lj;for(var m4=0;m4<KU.length;m4++)if(KU[m4][1]in $r){lj=KU[m4];break}if(lj){for(var b4=0;b4<lj.length;b4++)Pz[Zce[b4]]=lj[b4];Pz.prefixed=lj[0]!==Zce[0]}var Ch=[],A_t=function(e,i){return function(n,r,o){var a=i.levels[r],s=new RegExp("^("+a+")$");if(n!=="log"&&o.unshift(n.toUpperCase()+":"),o.unshift(e+":"),Ch){Ch.push([].concat(o));var l=Ch.length-1e3;Ch.splice(0,l>0?l:0)}if(Ct.console){var u=Ct.console[n];!u&&n==="debug"&&(u=Ct.console.info||Ct.console.log),!(!u||!a||!s.test(n))&&u[Array.isArray(o)?"apply":"call"](Ct.console,o)}}};function _Ie(t){var e="info",i,n=function(){for(var o=arguments.length,a=new Array(o),s=0;s<o;s++)a[s]=arguments[s];i("log",e,a)};return i=A_t(t,n),n.createLogger=function(r){return _Ie(t+": "+r)},n.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:e},n.level=function(r){if(typeof r=="string"){if(!n.levels.hasOwnProperty(r))throw new Error('"'+r+'" in not a valid log level');e=r}return e},n.history=function(){return Ch?[].concat(Ch):[]},n.history.filter=function(r){return(Ch||[]).filter(function(o){return new RegExp(".*"+r+".*").test(o[0])})},n.history.clear=function(){Ch&&(Ch.length=0)},n.history.disable=function(){Ch!==null&&(Ch.length=0,Ch=null)},n.history.enable=function(){Ch===null&&(Ch=[])},n.error=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return i("error",e,o)},n.warn=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return i("warn",e,o)},n.debug=function(){for(var r=arguments.length,o=new Array(r),a=0;a<r;a++)o[a]=arguments[a];return i("debug",e,o)},n}var Jn=_Ie("VIDEOJS"),PIe=Jn.createLogger,O_t=Object.prototype.toString,CIe=function(e){return OS(e)?Object.keys(e):[]};function YL(t,e){CIe(t).forEach(function(i){return e(t[i],i)})}function D_t(t,e,i){return i===void 0&&(i=0),CIe(t).reduce(function(n,r){return e(n,t[r],r)},i)}function Nl(t){for(var e=arguments.length,i=new Array(e>1?e-1:0),n=1;n<e;n++)i[n-1]=arguments[n];return Object.assign?Gn.apply(void 0,[t].concat(i)):(i.forEach(function(r){r&&YL(r,function(o,a){t[a]=o})}),t)}function OS(t){return!!t&&typeof t=="object"}function L3(t){return OS(t)&&O_t.call(t)==="[object Object]"&&t.constructor===Object}function k3(t,e){if(!t||!e)return"";if(typeof Ct.getComputedStyle=="function"){var i;try{i=Ct.getComputedStyle(t)}catch{return""}return i?i.getPropertyValue(e)||i[e]:""}return""}var xc=Ct.navigator&&Ct.navigator.userAgent||"",Jce=/AppleWebKit\/([\d.]+)/i.exec(xc),R_t=Jce?parseFloat(Jce.pop()):null,TIe=/iPod/i.test(xc),M_t=(function(){var t=xc.match(/OS (\d+)_/i);return t&&t[1]?t[1]:null})(),VS=/Android/i.test(xc),Pte=(function(){var t=xc.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var e=t[1]&&parseFloat(t[1]),i=t[2]&&parseFloat(t[2]);return e&&i?parseFloat(t[1]+"."+t[2]):e||null})(),xIe=VS&&Pte<5&&R_t<537,EIe=/Firefox/i.test(xc),FV=/Edg/i.test(xc),HS=!FV&&(/Chrome/i.test(xc)||/CriOS/i.test(xc)),wIe=(function(){var t=xc.match(/(Chrome|CriOS)\/(\d+)/);return t&&t[2]?parseFloat(t[2]):null})(),BV=(function(){var t=/MSIE\s(\d+)\.\d/.exec(xc),e=t&&parseFloat(t[1]);return!e&&/Trident\/7.0/i.test(xc)&&/rv:11.0/.test(xc)&&(e=11),e})(),Cte=/Safari/i.test(xc)&&!HS&&!VS&&!FV,AIe=/Windows/i.test(xc),qk=!!(bI()&&("ontouchstart"in Ct||Ct.navigator.maxTouchPoints||Ct.DocumentTouch&&Ct.document instanceof Ct.DocumentTouch)),Tte=/iPad/i.test(xc)||Cte&&qk&&!/iPhone/i.test(xc),xte=/iPhone/i.test(xc)&&!Tte,jf=xte||Tte||TIe,G6=(Cte||jf)&&!HS,L_t=Object.freeze({__proto__:null,IS_IPOD:TIe,IOS_VERSION:M_t,IS_ANDROID:VS,ANDROID_VERSION:Pte,IS_NATIVE_ANDROID:xIe,IS_FIREFOX:EIe,IS_EDGE:FV,IS_CHROME:HS,CHROME_VERSION:wIe,IE_VERSION:BV,IS_SAFARI:Cte,IS_WINDOWS:AIe,TOUCH_ENABLED:qk,IS_IPAD:Tte,IS_IPHONE:xte,IS_IOS:jf,IS_ANY_SAFARI:G6});function Qce(t){return typeof t=="string"&&!!t.trim()}function OIe(t){if(t.indexOf(" ")>=0)throw new Error("class has illegal whitespace characters")}function k_t(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}function bI(){return $r===Ct.document}function SI(t){return OS(t)&&t.nodeType===1}function DIe(){try{return Ct.parent!==Ct.self}catch{return!0}}function RIe(t){return function(e,i){if(!Qce(e))return $r[t](null);Qce(i)&&(i=$r.querySelector(i));var n=SI(i)?i:$r;return n[t]&&n[t](e)}}function Vo(t,e,i,n){t===void 0&&(t="div"),e===void 0&&(e={}),i===void 0&&(i={});var r=$r.createElement(t);return Object.getOwnPropertyNames(e).forEach(function(o){var a=e[o];o.indexOf("aria-")!==-1||o==="role"||o==="type"?(Jn.warn(`Setting attributes in the second argument of createEl()
has been deprecated. Use the third argument instead.
`+("createEl(type, properties, attributes). Attempting to set "+o+" to "+a+".")),r.setAttribute(o,a)):o==="textContent"?KD(r,a):(r[o]!==a||o==="tabIndex")&&(r[o]=a)}),Object.getOwnPropertyNames(i).forEach(function(o){r.setAttribute(o,i[o])}),n&&wte(r,n),r}function KD(t,e){return typeof t.textContent>"u"?t.innerText=e:t.textContent=e,t}function VZ(t,e){e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t)}function fD(t,e){return OIe(e),t.classList?t.classList.contains(e):k_t(e).test(t.className)}function pS(t,e){return t.classList?t.classList.add(e):fD(t,e)||(t.className=(t.className+" "+e).trim()),t}function jV(t,e){return t?(t.classList?t.classList.remove(e):(OIe(e),t.className=t.className.split(/\s+/).filter(function(i){return i!==e}).join(" ")),t):(Jn.warn("removeClass was called with an element that doesn't exist"),null)}function MIe(t,e,i){var n=fD(t,e);if(typeof i=="function"&&(i=i(t,e)),typeof i!="boolean"&&(i=!n),i!==n)return i?pS(t,e):jV(t,e),t}function LIe(t,e){Object.getOwnPropertyNames(e).forEach(function(i){var n=e[i];n===null||typeof n>"u"||n===!1?t.removeAttribute(i):t.setAttribute(i,n===!0?"":n)})}function Zb(t){var e={},i=",autoplay,controls,playsinline,loop,muted,default,defaultMuted,";if(t&&t.attributes&&t.attributes.length>0)for(var n=t.attributes,r=n.length-1;r>=0;r--){var o=n[r].name,a=n[r].value;(typeof t[o]=="boolean"||i.indexOf(","+o+",")!==-1)&&(a=a!==null),e[o]=a}return e}function kIe(t,e){return t.getAttribute(e)}function Xk(t,e,i){t.setAttribute(e,i)}function Y6(t,e){t.removeAttribute(e)}function IIe(){$r.body.focus(),$r.onselectstart=function(){return!1}}function NIe(){$r.onselectstart=function(){return!0}}function Kk(t){if(t&&t.getBoundingClientRect&&t.parentNode){var e=t.getBoundingClientRect(),i={};return["bottom","height","left","right","top","width"].forEach(function(n){e[n]!==void 0&&(i[n]=e[n])}),i.height||(i.height=parseFloat(k3(t,"height"))),i.width||(i.width=parseFloat(k3(t,"width"))),i}}function I3(t){if(!t||t&&!t.offsetParent)return{left:0,top:0,width:0,height:0};for(var e=t.offsetWidth,i=t.offsetHeight,n=0,r=0;t.offsetParent&&t!==$r[Pz.fullscreenElement];)n+=t.offsetLeft,r+=t.offsetTop,t=t.offsetParent;return{left:n,top:r,width:e,height:i}}function q6(t,e){var i={x:0,y:0};if(jf)for(var n=t;n&&n.nodeName.toLowerCase()!=="html";){var r=k3(n,"transform");if(/^matrix/.test(r)){var o=r.slice(7,-1).split(/,\s/).map(Number);i.x+=o[4],i.y+=o[5]}else if(/^matrix3d/.test(r)){var a=r.slice(9,-1).split(/,\s/).map(Number);i.x+=a[12],i.y+=a[13]}n=n.parentNode}var s={},l=I3(e.target),u=I3(t),c=u.width,d=u.height,f=e.offsetY-(u.top-l.top),h=e.offsetX-(u.left-l.left);return e.changedTouches&&(h=e.changedTouches[0].pageX-u.left,f=e.changedTouches[0].pageY+u.top,jf&&(h-=i.x,f-=i.y)),s.y=1-Math.max(0,Math.min(1,f/d)),s.x=Math.max(0,Math.min(1,h/c)),s}function FIe(t){return OS(t)&&t.nodeType===3}function Ete(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function BIe(t){return typeof t=="function"&&(t=t()),(Array.isArray(t)?t:[t]).map(function(e){if(typeof e=="function"&&(e=e()),SI(e)||FIe(e))return e;if(typeof e=="string"&&/\S/.test(e))return $r.createTextNode(e)}).filter(function(e){return e})}function wte(t,e){return BIe(e).forEach(function(i){return t.appendChild(i)}),t}function jIe(t,e){return wte(Ete(t),e)}function N3(t){return t.button===void 0&&t.buttons===void 0||t.button===0&&t.buttons===void 0||t.type==="mouseup"&&t.button===0&&t.buttons===0?!0:!(t.button!==0||t.buttons!==1)}var AP=RIe("querySelector"),VIe=RIe("querySelectorAll"),HIe=Object.freeze({__proto__:null,isReal:bI,isEl:SI,isInFrame:DIe,createEl:Vo,textContent:KD,prependTo:VZ,hasClass:fD,addClass:pS,removeClass:jV,toggleClass:MIe,setAttributes:LIe,getAttributes:Zb,getAttribute:kIe,setAttribute:Xk,removeAttribute:Y6,blockTextSelection:IIe,unblockTextSelection:NIe,getBoundingClientRect:Kk,findPosition:I3,getPointerPosition:q6,isTextNode:FIe,emptyEl:Ete,normalizeContent:BIe,appendContent:wte,insertContent:jIe,isSingleLeftClick:N3,$:AP,$$:VIe}),UIe=!1,HZ,I_t=function(){if(HZ.options.autoSetup!==!1){var e=Array.prototype.slice.call($r.getElementsByTagName("video")),i=Array.prototype.slice.call($r.getElementsByTagName("audio")),n=Array.prototype.slice.call($r.getElementsByTagName("video-js")),r=e.concat(i,n);if(r&&r.length>0)for(var o=0,a=r.length;o<a;o++){var s=r[o];if(s&&s.getAttribute){if(s.player===void 0){var l=s.getAttribute("data-setup");l!==null&&HZ(s)}}else{UZ(1);break}}else UIe||UZ(1)}};function UZ(t,e){bI()&&(e&&(HZ=e),Ct.setTimeout(I_t,t))}function zZ(){UIe=!0,Ct.removeEventListener("load",zZ)}bI()&&($r.readyState==="complete"?zZ():Ct.addEventListener("load",zZ));var zIe=function(e){var i=$r.createElement("style");return i.className=e,i},$Ie=function(e,i){e.styleSheet?e.styleSheet.cssText=i:e.textContent=i},N_t=3,F_t=N_t;function US(){return F_t++}var WIe;Ct.WeakMap||(WIe=(function(){function t(){this.vdata="vdata"+Math.floor(Ct.performance&&Ct.performance.now()||Date.now()),this.data={}}var e=t.prototype;return e.set=function(n,r){var o=n[this.vdata]||US();return n[this.vdata]||(n[this.vdata]=o),this.data[o]=r,this},e.get=function(n){var r=n[this.vdata];if(r)return this.data[r];Jn("We have no data for this element",n)},e.has=function(n){var r=n[this.vdata];return r in this.data},e.delete=function(n){var r=n[this.vdata];r&&(delete this.data[r],delete n[this.vdata])},t})());var Nf=Ct.WeakMap?new WeakMap:new WIe;function ede(t,e){if(Nf.has(t)){var i=Nf.get(t);i.handlers[e].length===0&&(delete i.handlers[e],t.removeEventListener?t.removeEventListener(e,i.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+e,i.dispatcher)),Object.getOwnPropertyNames(i.handlers).length<=0&&(delete i.handlers,delete i.dispatcher,delete i.disabled),Object.getOwnPropertyNames(i).length===0&&Nf.delete(t)}}function Ate(t,e,i,n){i.forEach(function(r){t(e,r,n)})}function X6(t){if(t.fixed_)return t;function e(){return!0}function i(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var n=t||Ct.event;t={};for(var r in n)r!=="layerX"&&r!=="layerY"&&r!=="keyLocation"&&r!=="webkitMovementX"&&r!=="webkitMovementY"&&r!=="path"&&(r==="returnValue"&&n.preventDefault||(t[r]=n[r]));if(t.target||(t.target=t.srcElement||$r),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){n.preventDefault&&n.preventDefault(),t.returnValue=!1,n.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){n.stopPropagation&&n.stopPropagation(),t.cancelBubble=!0,n.cancelBubble=!0,t.isPropagationStopped=e},t.isPropagationStopped=i,t.stopImmediatePropagation=function(){n.stopImmediatePropagation&&n.stopImmediatePropagation(),t.isImmediatePropagationStopped=e,t.stopPropagation()},t.isImmediatePropagationStopped=i,t.clientX!==null&&t.clientX!==void 0){var o=$r.documentElement,a=$r.body;t.pageX=t.clientX+(o&&o.scrollLeft||a&&a.scrollLeft||0)-(o&&o.clientLeft||a&&a.clientLeft||0),t.pageY=t.clientY+(o&&o.scrollTop||a&&a.scrollTop||0)-(o&&o.clientTop||a&&a.clientTop||0)}t.which=t.charCode||t.keyCode,t.button!==null&&t.button!==void 0&&(t.button=t.button&1?0:t.button&4?1:t.button&2?2:0)}return t.fixed_=!0,t}var S4,B_t=function(){if(typeof S4!="boolean"){S4=!1;try{var e=Object.defineProperty({},"passive",{get:function(){S4=!0}});Ct.addEventListener("test",null,e),Ct.removeEventListener("test",null,e)}catch{}}return S4},j_t=["touchstart","touchmove"];function Op(t,e,i){if(Array.isArray(e))return Ate(Op,t,e,i);Nf.has(t)||Nf.set(t,{});var n=Nf.get(t);if(n.handlers||(n.handlers={}),n.handlers[e]||(n.handlers[e]=[]),i.guid||(i.guid=US()),n.handlers[e].push(i),n.dispatcher||(n.disabled=!1,n.dispatcher=function(o,a){if(!n.disabled){o=X6(o);var s=n.handlers[o.type];if(s)for(var l=s.slice(0),u=0,c=l.length;u<c&&!o.isImmediatePropagationStopped();u++)try{l[u].call(t,o,a)}catch(d){Jn.error(d)}}}),n.handlers[e].length===1)if(t.addEventListener){var r=!1;B_t()&&j_t.indexOf(e)>-1&&(r={passive:!0}),t.addEventListener(e,n.dispatcher,r)}else t.attachEvent&&t.attachEvent("on"+e,n.dispatcher)}function Ud(t,e,i){if(Nf.has(t)){var n=Nf.get(t);if(n.handlers){if(Array.isArray(e))return Ate(Ud,t,e,i);var r=function(u,c){n.handlers[c]=[],ede(u,c)};if(e===void 0){for(var o in n.handlers)Object.prototype.hasOwnProperty.call(n.handlers||{},o)&&r(t,o);return}var a=n.handlers[e];if(a){if(!i){r(t,e);return}if(i.guid)for(var s=0;s<a.length;s++)a[s].guid===i.guid&&a.splice(s--,1);ede(t,e)}}}}function _I(t,e,i){var n=Nf.has(t)?Nf.get(t):{},r=t.parentNode||t.ownerDocument;if(typeof e=="string"?e={type:e,target:t}:e.target||(e.target=t),e=X6(e),n.dispatcher&&n.dispatcher.call(t,e,i),r&&!e.isPropagationStopped()&&e.bubbles===!0)_I.call(null,r,e,i);else if(!r&&!e.defaultPrevented&&e.target&&e.target[e.type]){Nf.has(e.target)||Nf.set(e.target,{});var o=Nf.get(e.target);e.target[e.type]&&(o.disabled=!0,typeof e.target[e.type]=="function"&&e.target[e.type](),o.disabled=!1)}return!e.defaultPrevented}function K6(t,e,i){if(Array.isArray(e))return Ate(K6,t,e,i);var n=function r(){Ud(t,e,r),i.apply(this,arguments)};n.guid=i.guid=i.guid||US(),Op(t,e,n)}function GIe(t,e,i){var n=function r(){Ud(t,e,r),i.apply(this,arguments)};n.guid=i.guid=i.guid||US(),Op(t,e,n)}var V_t=Object.freeze({__proto__:null,fixEvent:X6,on:Op,off:Ud,trigger:_I,one:K6,any:GIe}),Bv=30,Ms=function(e,i,n){i.guid||(i.guid=US());var r=i.bind(e);return r.guid=n?n+"_"+i.guid:i.guid,r},DS=function(e,i){var n=Ct.performance.now(),r=function(){var a=Ct.performance.now();a-n>=i&&(e.apply(void 0,arguments),n=a)};return r},H_t=function(e,i,n,r){r===void 0&&(r=Ct);var o,a=function(){r.clearTimeout(o),o=null},s=function(){var u=this,c=arguments,d=function(){o=null,d=null,e.apply(u,c)};r.clearTimeout(o),o=r.setTimeout(d,i)};return s.cancel=a,s},Ec=function(){};Ec.prototype.allowedEvents_={};Ec.prototype.on=function(t,e){var i=this.addEventListener;this.addEventListener=function(){},Op(this,t,e),this.addEventListener=i};Ec.prototype.addEventListener=Ec.prototype.on;Ec.prototype.off=function(t,e){Ud(this,t,e)};Ec.prototype.removeEventListener=Ec.prototype.off;Ec.prototype.one=function(t,e){var i=this.addEventListener;this.addEventListener=function(){},K6(this,t,e),this.addEventListener=i};Ec.prototype.any=function(t,e){var i=this.addEventListener;this.addEventListener=function(){},GIe(this,t,e),this.addEventListener=i};Ec.prototype.trigger=function(t){var e=t.type||t;typeof t=="string"&&(t={type:e}),t=X6(t),this.allowedEvents_[e]&&this["on"+e]&&this["on"+e](t),_I(this,t)};Ec.prototype.dispatchEvent=Ec.prototype.trigger;var iN;Ec.prototype.queueTrigger=function(t){var e=this;iN||(iN=new Map);var i=t.type||t,n=iN.get(this);n||(n=new Map,iN.set(this,n));var r=n.get(i);n.delete(i),Ct.clearTimeout(r);var o=Ct.setTimeout(function(){n.delete(i),n.size===0&&(n=null,iN.delete(e)),e.trigger(t)},0);n.set(i,o)};var Z6=function(e){return typeof e.name=="function"?e.name():typeof e.name=="string"?e.name:e.name_?e.name_:e.constructor&&e.constructor.name?e.constructor.name:typeof e},gS=function(e){return e instanceof Ec||!!e.eventBusEl_&&["on","one","off","trigger"].every(function(i){return typeof e[i]=="function"})},U_t=function(e,i){gS(e)?i():(e.eventedCallbacks||(e.eventedCallbacks=[]),e.eventedCallbacks.push(i))},$Z=function(e){return typeof e=="string"&&/\S/.test(e)||Array.isArray(e)&&!!e.length},Cz=function(e,i,n){if(!e||!e.nodeName&&!gS(e))throw new Error("Invalid target for "+Z6(i)+"#"+n+"; must be a DOM node or evented object.")},YIe=function(e,i,n){if(!$Z(e))throw new Error("Invalid event type for "+Z6(i)+"#"+n+"; must be a non-empty string or array.")},qIe=function(e,i,n){if(typeof e!="function")throw new Error("Invalid listener for "+Z6(i)+"#"+n+"; must be a function.")},qY=function(e,i,n){var r=i.length<3||i[0]===e||i[0]===e.eventBusEl_,o,a,s;return r?(o=e.eventBusEl_,i.length>=3&&i.shift(),a=i[0],s=i[1]):(o=i[0],a=i[1],s=i[2]),Cz(o,e,n),YIe(a,e,n),qIe(s,e,n),s=Ms(e,s),{isTargetingSelf:r,target:o,type:a,listener:s}},_T=function(e,i,n,r){Cz(e,e,i),e.nodeName?V_t[i](e,n,r):e[i](n,r)},z_t={on:function(){for(var e=this,i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];var o=qY(this,n,"on"),a=o.isTargetingSelf,s=o.target,l=o.type,u=o.listener;if(_T(s,"on",l,u),!a){var c=function(){return e.off(s,l,u)};c.guid=u.guid;var d=function(){return e.off("dispose",c)};d.guid=u.guid,_T(this,"on","dispose",c),_T(s,"on","dispose",d)}},one:function(){for(var e=this,i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];var o=qY(this,n,"one"),a=o.isTargetingSelf,s=o.target,l=o.type,u=o.listener;if(a)_T(s,"one",l,u);else{var c=function d(){e.off(s,l,d);for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];u.apply(null,h)};c.guid=u.guid,_T(s,"one",l,c)}},any:function(){for(var e=this,i=arguments.length,n=new Array(i),r=0;r<i;r++)n[r]=arguments[r];var o=qY(this,n,"any"),a=o.isTargetingSelf,s=o.target,l=o.type,u=o.listener;if(a)_T(s,"any",l,u);else{var c=function d(){e.off(s,l,d);for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];u.apply(null,h)};c.guid=u.guid,_T(s,"any",l,c)}},off:function(e,i,n){if(!e||$Z(e))Ud(this.eventBusEl_,e,i);else{var r=e,o=i;Cz(r,this,"off"),YIe(o,this,"off"),qIe(n,this,"off"),n=Ms(this,n),this.off("dispose",n),r.nodeName?(Ud(r,o,n),Ud(r,"dispose",n)):gS(r)&&(r.off(o,n),r.off("dispose",n))}},trigger:function(e,i){Cz(this.eventBusEl_,this,"trigger");var n=e&&typeof e!="string"?e.type:e;if(!$Z(n)){var r="Invalid event type for "+Z6(this)+"#trigger; must be a non-empty string or object with a type key that has a non-empty value.";if(e)(this.log||Jn).error(r);else throw new Error(r)}return _I(this.eventBusEl_,e,i)}};function Ote(t,e){e===void 0&&(e={});var i=e,n=i.eventBusKey;if(n){if(!t[n].nodeName)throw new Error('The eventBusKey "'+n+'" does not refer to an element.');t.eventBusEl_=t[n]}else t.eventBusEl_=Vo("span",{className:"vjs-event-bus"});return Nl(t,z_t),t.eventedCallbacks&&t.eventedCallbacks.forEach(function(r){r()}),t.on("dispose",function(){t.off(),[t,t.el_,t.eventBusEl_].forEach(function(r){r&&Nf.has(r)&&Nf.delete(r)}),Ct.setTimeout(function(){t.eventBusEl_=null},0)}),t}var $_t={state:{},setState:function(e){var i=this;typeof e=="function"&&(e=e());var n;return YL(e,function(r,o){i.state[o]!==r&&(n=n||{},n[o]={from:i.state[o],to:r}),i.state[o]=r}),n&&gS(this)&&this.trigger({changes:n,type:"statechanged"}),n}};function XIe(t,e){return Nl(t,$_t),t.state=Nl({},t.state,e),typeof t.handleStateChanged=="function"&&gS(t)&&t.on("statechanged",t.handleStateChanged),t}var ZU=function(e){return typeof e!="string"?e:e.replace(/./,function(i){return i.toLowerCase()})},Ql=function(e){return typeof e!="string"?e:e.replace(/./,function(i){return i.toUpperCase()})},W_t=function(e,i){return Ql(e)===Ql(i)};function Rs(){for(var t={},e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return i.forEach(function(r){r&&YL(r,function(o,a){if(!L3(o)){t[a]=o;return}L3(t[a])||(t[a]={}),t[a]=Rs(t[a],o)})}),t}var G_t=(function(){function t(){this.map_={}}var e=t.prototype;return e.has=function(n){return n in this.map_},e.delete=function(n){var r=this.has(n);return delete this.map_[n],r},e.set=function(n,r){return this.map_[n]=r,this},e.forEach=function(n,r){for(var o in this.map_)n.call(r,this.map_[o],o,this)},t})(),Y_t=Ct.Map?Ct.Map:G_t,q_t=(function(){function t(){this.set_={}}var e=t.prototype;return e.has=function(n){return n in this.set_},e.delete=function(n){var r=this.has(n);return delete this.set_[n],r},e.add=function(n){return this.set_[n]=1,this},e.forEach=function(n,r){for(var o in this.set_)n.call(r,o,o,this)},t})(),XY=Ct.Set?Ct.Set:q_t,Fr=(function(){function t(i,n,r){var o=this;if(!i&&this.play?this.player_=i=this:this.player_=i,this.isDisposed_=!1,this.parentComponent_=null,this.options_=Rs({},this.options_),n=this.options_=Rs(this.options_,n),this.id_=n.id||n.el&&n.el.id,!this.id_){var a=i&&i.id&&i.id()||"no_player";this.id_=a+"_component_"+US()}this.name_=n.name||null,n.el?this.el_=n.el:n.createEl!==!1&&(this.el_=this.createEl()),n.className&&this.el_&&n.className.split(" ").forEach(function(s){return o.addClass(s)}),n.evented!==!1&&(Ote(this,{eventBusKey:this.el_?"el_":null}),this.handleLanguagechange=this.handleLanguagechange.bind(this),this.on(this.player_,"languagechange",this.handleLanguagechange)),XIe(this,this.constructor.defaultState),this.children_=[],this.childIndex_={},this.childNameIndex_={},this.setTimeoutIds_=new XY,this.setIntervalIds_=new XY,this.rafIds_=new XY,this.namedRafs_=new Y_t,this.clearingTimersOnDispose_=!1,n.initChildren!==!1&&this.initChildren(),this.ready(r),n.reportTouchActivity!==!1&&this.enableTouchActivity()}var e=t.prototype;return e.dispose=function(n){if(n===void 0&&(n={}),!this.isDisposed_){if(this.readyQueue_&&(this.readyQueue_.length=0),this.trigger({type:"dispose",bubbles:!1}),this.isDisposed_=!0,this.children_)for(var r=this.children_.length-1;r>=0;r--)this.children_[r].dispose&&this.children_[r].dispose();this.children_=null,this.childIndex_=null,this.childNameIndex_=null,this.parentComponent_=null,this.el_&&(this.el_.parentNode&&(n.restoreEl?this.el_.parentNode.replaceChild(n.restoreEl,this.el_):this.el_.parentNode.removeChild(this.el_)),this.el_=null),this.player_=null}},e.isDisposed=function(){return!!this.isDisposed_},e.player=function(){return this.player_},e.options=function(n){return n?(this.options_=Rs(this.options_,n),this.options_):this.options_},e.el=function(){return this.el_},e.createEl=function(n,r,o){return Vo(n,r,o)},e.localize=function(n,r,o){o===void 0&&(o=n);var a=this.player_.language&&this.player_.language(),s=this.player_.languages&&this.player_.languages(),l=s&&s[a],u=a&&a.split("-")[0],c=s&&s[u],d=o;return l&&l[n]?d=l[n]:c&&c[n]&&(d=c[n]),r&&(d=d.replace(/\{(\d+)\}/g,function(f,h){var p=r[h-1],g=p;return typeof p>"u"&&(g=f),g})),d},e.handleLanguagechange=function(){},e.contentEl=function(){return this.contentEl_||this.el_},e.id=function(){return this.id_},e.name=function(){return this.name_},e.children=function(){return this.children_},e.getChildById=function(n){return this.childIndex_[n]},e.getChild=function(n){if(n)return this.childNameIndex_[n]},e.getDescendant=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];r=r.reduce(function(l,u){return l.concat(u)},[]);for(var a=this,s=0;s<r.length;s++)if(a=a.getChild(r[s]),!a||!a.getChild)return;return a},e.addChild=function(n,r,o){r===void 0&&(r={}),o===void 0&&(o=this.children_.length);var a,s;if(typeof n=="string"){s=Ql(n);var l=r.componentClass||s;r.name=s;var u=t.getComponent(l);if(!u)throw new Error("Component "+l+" does not exist");if(typeof u!="function")return null;a=new u(this.player_||this,r)}else a=n;if(a.parentComponent_&&a.parentComponent_.removeChild(a),this.children_.splice(o,0,a),a.parentComponent_=this,typeof a.id=="function"&&(this.childIndex_[a.id()]=a),s=s||a.name&&Ql(a.name()),s&&(this.childNameIndex_[s]=a,this.childNameIndex_[ZU(s)]=a),typeof a.el=="function"&&a.el()){var c=null;this.children_[o+1]&&(this.children_[o+1].el_?c=this.children_[o+1].el_:SI(this.children_[o+1])&&(c=this.children_[o+1])),this.contentEl().insertBefore(a.el(),c)}return a},e.removeChild=function(n){if(typeof n=="string"&&(n=this.getChild(n)),!(!n||!this.children_)){for(var r=!1,o=this.children_.length-1;o>=0;o--)if(this.children_[o]===n){r=!0,this.children_.splice(o,1);break}if(r){n.parentComponent_=null,this.childIndex_[n.id()]=null,this.childNameIndex_[Ql(n.name())]=null,this.childNameIndex_[ZU(n.name())]=null;var a=n.el();a&&a.parentNode===this.contentEl()&&this.contentEl().removeChild(n.el())}}},e.initChildren=function(){var n=this,r=this.options_.children;if(r){var o=this.options_,a=function(c){var d=c.name,f=c.opts;if(o[d]!==void 0&&(f=o[d]),f!==!1){f===!0&&(f={}),f.playerOptions=n.options_.playerOptions;var h=n.addChild(d,f);h&&(n[d]=h)}},s,l=t.getComponent("Tech");Array.isArray(r)?s=r:s=Object.keys(r),s.concat(Object.keys(this.options_).filter(function(u){return!s.some(function(c){return typeof c=="string"?u===c:u===c.name})})).map(function(u){var c,d;return typeof u=="string"?(c=u,d=r[c]||n.options_[c]||{}):(c=u.name,d=u),{name:c,opts:d}}).filter(function(u){var c=t.getComponent(u.opts.componentClass||Ql(u.name));return c&&!l.isTech(c)}).forEach(a)}},e.buildCSSClass=function(){return""},e.ready=function(n,r){if(r===void 0&&(r=!1),!!n){if(!this.isReady_){this.readyQueue_=this.readyQueue_||[],this.readyQueue_.push(n);return}r?n.call(this):this.setTimeout(n,1)}},e.triggerReady=function(){this.isReady_=!0,this.setTimeout(function(){var n=this.readyQueue_;this.readyQueue_=[],n&&n.length>0&&n.forEach(function(r){r.call(this)},this),this.trigger("ready")},1)},e.$=function(n,r){return AP(n,r||this.contentEl())},e.$$=function(n,r){return VIe(n,r||this.contentEl())},e.hasClass=function(n){return fD(this.el_,n)},e.addClass=function(n){pS(this.el_,n)},e.removeClass=function(n){jV(this.el_,n)},e.toggleClass=function(n,r){MIe(this.el_,n,r)},e.show=function(){this.removeClass("vjs-hidden")},e.hide=function(){this.addClass("vjs-hidden")},e.lockShowing=function(){this.addClass("vjs-lock-showing")},e.unlockShowing=function(){this.removeClass("vjs-lock-showing")},e.getAttribute=function(n){return kIe(this.el_,n)},e.setAttribute=function(n,r){Xk(this.el_,n,r)},e.removeAttribute=function(n){Y6(this.el_,n)},e.width=function(n,r){return this.dimension("width",n,r)},e.height=function(n,r){return this.dimension("height",n,r)},e.dimensions=function(n,r){this.width(n,!0),this.height(r)},e.dimension=function(n,r,o){if(r!==void 0){(r===null||r!==r)&&(r=0),(""+r).indexOf("%")!==-1||(""+r).indexOf("px")!==-1?this.el_.style[n]=r:r==="auto"?this.el_.style[n]="":this.el_.style[n]=r+"px",o||this.trigger("componentresize");return}if(!this.el_)return 0;var a=this.el_.style[n],s=a.indexOf("px");return parseInt(s!==-1?a.slice(0,s):this.el_["offset"+Ql(n)],10)},e.currentDimension=function(n){var r=0;if(n!=="width"&&n!=="height")throw new Error("currentDimension only accepts width or height value");if(r=k3(this.el_,n),r=parseFloat(r),r===0||isNaN(r)){var o="offset"+Ql(n);r=this.el_[o]}return r},e.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},e.currentWidth=function(){return this.currentDimension("width")},e.currentHeight=function(){return this.currentDimension("height")},e.focus=function(){this.el_.focus()},e.blur=function(){this.el_.blur()},e.handleKeyDown=function(n){this.player_&&(On.isEventKey(n,"Tab")||n.stopPropagation(),this.player_.handleKeyDown(n))},e.handleKeyPress=function(n){this.handleKeyDown(n)},e.emitTapEvents=function(){var n=0,r=null,o=10,a=200,s;this.on("touchstart",function(u){u.touches.length===1&&(r={pageX:u.touches[0].pageX,pageY:u.touches[0].pageY},n=Ct.performance.now(),s=!0)}),this.on("touchmove",function(u){if(u.touches.length>1)s=!1;else if(r){var c=u.touches[0].pageX-r.pageX,d=u.touches[0].pageY-r.pageY,f=Math.sqrt(c*c+d*d);f>o&&(s=!1)}});var l=function(){s=!1};this.on("touchleave",l),this.on("touchcancel",l),this.on("touchend",function(u){if(r=null,s===!0){var c=Ct.performance.now()-n;c<a&&(u.preventDefault(),this.trigger("tap"))}})},e.enableTouchActivity=function(){if(!(!this.player()||!this.player().reportUserActivity)){var n=Ms(this.player(),this.player().reportUserActivity),r;this.on("touchstart",function(){n(),this.clearInterval(r),r=this.setInterval(n,250)});var o=function(s){n(),this.clearInterval(r)};this.on("touchmove",n),this.on("touchend",o),this.on("touchcancel",o)}},e.setTimeout=function(n,r){var o=this,a;return n=Ms(this,n),this.clearTimersOnDispose_(),a=Ct.setTimeout(function(){o.setTimeoutIds_.has(a)&&o.setTimeoutIds_.delete(a),n()},r),this.setTimeoutIds_.add(a),a},e.clearTimeout=function(n){return this.setTimeoutIds_.has(n)&&(this.setTimeoutIds_.delete(n),Ct.clearTimeout(n)),n},e.setInterval=function(n,r){n=Ms(this,n),this.clearTimersOnDispose_();var o=Ct.setInterval(n,r);return this.setIntervalIds_.add(o),o},e.clearInterval=function(n){return this.setIntervalIds_.has(n)&&(this.setIntervalIds_.delete(n),Ct.clearInterval(n)),n},e.requestAnimationFrame=function(n){var r=this;if(!this.supportsRaf_)return this.setTimeout(n,1e3/60);this.clearTimersOnDispose_();var o;return n=Ms(this,n),o=Ct.requestAnimationFrame(function(){r.rafIds_.has(o)&&r.rafIds_.delete(o),n()}),this.rafIds_.add(o),o},e.requestNamedAnimationFrame=function(n,r){var o=this;if(!this.namedRafs_.has(n)){this.clearTimersOnDispose_(),r=Ms(this,r);var a=this.requestAnimationFrame(function(){r(),o.namedRafs_.has(n)&&o.namedRafs_.delete(n)});return this.namedRafs_.set(n,a),n}},e.cancelNamedAnimationFrame=function(n){this.namedRafs_.has(n)&&(this.cancelAnimationFrame(this.namedRafs_.get(n)),this.namedRafs_.delete(n))},e.cancelAnimationFrame=function(n){return this.supportsRaf_?(this.rafIds_.has(n)&&(this.rafIds_.delete(n),Ct.cancelAnimationFrame(n)),n):this.clearTimeout(n)},e.clearTimersOnDispose_=function(){var n=this;this.clearingTimersOnDispose_||(this.clearingTimersOnDispose_=!0,this.one("dispose",function(){[["namedRafs_","cancelNamedAnimationFrame"],["rafIds_","cancelAnimationFrame"],["setTimeoutIds_","clearTimeout"],["setIntervalIds_","clearInterval"]].forEach(function(r){var o=r[0],a=r[1];n[o].forEach(function(s,l){return n[a](l)})}),n.clearingTimersOnDispose_=!1}))},t.registerComponent=function(n,r){if(typeof n!="string"||!n)throw new Error('Illegal component name, "'+n+'"; must be a non-empty string.');var o=t.getComponent("Tech"),a=o&&o.isTech(r),s=t===r||t.prototype.isPrototypeOf(r.prototype);if(a||!s){var l;throw a?l="techs must be registered using Tech.registerTech()":l="must be a Component subclass",new Error('Illegal component, "'+n+'"; '+l+".")}n=Ql(n),t.components_||(t.components_={});var u=t.getComponent("Player");if(n==="Player"&&u&&u.players){var c=u.players,d=Object.keys(c);if(c&&d.length>0&&d.map(function(f){return c[f]}).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return t.components_[n]=r,t.components_[ZU(n)]=r,r},t.getComponent=function(n){if(!(!n||!t.components_))return t.components_[n]},t})();Fr.prototype.supportsRaf_=typeof Ct.requestAnimationFrame=="function"&&typeof Ct.cancelAnimationFrame=="function";Fr.registerComponent("Component",Fr);function X_t(t,e,i){if(typeof e!="number"||e<0||e>i)throw new Error("Failed to execute '"+t+"' on 'TimeRanges': The index provided ("+e+") is non-numeric or out of bounds (0-"+i+").")}function tde(t,e,i,n){return X_t(t,n,i.length-1),i[n][e]}function KY(t){var e;return t===void 0||t.length===0?e={length:0,start:function(){throw new Error("This TimeRanges object is empty")},end:function(){throw new Error("This TimeRanges object is empty")}}:e={length:t.length,start:tde.bind(null,"start",0,t),end:tde.bind(null,"end",1,t)},Ct.Symbol&&Ct.Symbol.iterator&&(e[Ct.Symbol.iterator]=function(){return(t||[]).values()}),e}function hD(t,e){return Array.isArray(t)?KY(t):t===void 0||e===void 0?KY():KY([[t,e]])}function KIe(t,e){var i=0,n,r;if(!e)return 0;(!t||!t.length)&&(t=hD(0,0));for(var o=0;o<t.length;o++)n=t.start(o),r=t.end(o),r>e&&(r=e),i+=r-n;return i/e}function Ff(t){if(t instanceof Ff)return t;typeof t=="number"?this.code=t:typeof t=="string"?this.message=t:OS(t)&&(typeof t.code=="number"&&(this.code=t.code),Nl(this,t)),this.message||(this.message=Ff.defaultMessages[this.code]||"")}Ff.prototype.code=0;Ff.prototype.message="";Ff.prototype.status=null;Ff.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"];Ff.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail part-way.",3:"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.",4:"The media could not be loaded, either because the server or network failed or because the format is not supported.",5:"The media is encrypted and we do not have the keys to decrypt it."};for(var aL=0;aL<Ff.errorTypes.length;aL++)Ff[Ff.errorTypes[aL]]=aL,Ff.prototype[Ff.errorTypes[aL]]=aL;function Oj(t){return t!=null&&typeof t.then=="function"}function Qy(t){Oj(t)&&t.then(null,function(e){})}var WZ=function(e){var i=["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce(function(n,r,o){return e[r]&&(n[r]=e[r]),n},{cues:e.cues&&Array.prototype.map.call(e.cues,function(n){return{startTime:n.startTime,endTime:n.endTime,text:n.text,id:n.id}})});return i},K_t=function(e){var i=e.$$("track"),n=Array.prototype.map.call(i,function(o){return o.track}),r=Array.prototype.map.call(i,function(o){var a=WZ(o.track);return o.src&&(a.src=o.src),a});return r.concat(Array.prototype.filter.call(e.textTracks(),function(o){return n.indexOf(o)===-1}).map(WZ))},Z_t=function(e,i){return e.forEach(function(n){var r=i.addRemoteTextTrack(n).track;!n.src&&n.cues&&n.cues.forEach(function(o){return r.addCue(o)})}),i.textTracks()},rde={textTracksToJson:K_t,jsonToTextTracks:Z_t,trackToJson_:WZ},ZY="vjs-modal-dialog",PI=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.handleKeyDown_=function(a){return o.handleKeyDown(a)},o.close_=function(a){return o.close(a)},o.opened_=o.hasBeenOpened_=o.hasBeenFilled_=!1,o.closeable(!o.options_.uncloseable),o.content(o.options_.content),o.contentEl_=Vo("div",{className:ZY+"-content"},{role:"document"}),o.descEl_=Vo("p",{className:ZY+"-description vjs-control-text",id:o.el().getAttribute("aria-describedby")}),KD(o.descEl_,o.description()),o.el_.appendChild(o.descEl_),o.el_.appendChild(o.contentEl_),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":this.id()+"_description","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},i.dispose=function(){this.contentEl_=null,this.descEl_=null,this.previouslyActiveEl_=null,t.prototype.dispose.call(this)},i.buildCSSClass=function(){return ZY+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},i.label=function(){return this.localize(this.options_.label||"Modal Window")},i.description=function(){var r=this.options_.description||this.localize("This is a modal window.");return this.closeable()&&(r+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),r},i.open=function(){if(!this.opened_){var r=this.player();this.trigger("beforemodalopen"),this.opened_=!0,(this.options_.fillAlways||!this.hasBeenOpened_&&!this.hasBeenFilled_)&&this.fill(),this.wasPlaying_=!r.paused(),this.options_.pauseOnOpen&&this.wasPlaying_&&r.pause(),this.on("keydown",this.handleKeyDown_),this.hadControls_=r.controls(),r.controls(!1),this.show(),this.conditionalFocus_(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.hasBeenOpened_=!0}},i.opened=function(r){return typeof r=="boolean"&&this[r?"open":"close"](),this.opened_},i.close=function(){if(this.opened_){var r=this.player();this.trigger("beforemodalclose"),this.opened_=!1,this.wasPlaying_&&this.options_.pauseOnOpen&&r.play(),this.off("keydown",this.handleKeyDown_),this.hadControls_&&r.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.conditionalBlur_(),this.options_.temporary&&this.dispose()}},i.closeable=function(r){if(typeof r=="boolean"){var o=this.closeable_=!!r,a=this.getChild("closeButton");if(o&&!a){var s=this.contentEl_;this.contentEl_=this.el_,a=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.contentEl_=s,this.on(a,"close",this.close_)}!o&&a&&(this.off(a,"close",this.close_),this.removeChild(a),a.dispose())}return this.closeable_},i.fill=function(){this.fillWith(this.content())},i.fillWith=function(r){var o=this.contentEl(),a=o.parentNode,s=o.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,a.removeChild(o),this.empty(),jIe(o,r),this.trigger("modalfill"),s?a.insertBefore(o,s):a.appendChild(o);var l=this.getChild("closeButton");l&&a.appendChild(l.el_)},i.empty=function(){this.trigger("beforemodalempty"),Ete(this.contentEl()),this.trigger("modalempty")},i.content=function(r){return typeof r<"u"&&(this.content_=r),this.content_},i.conditionalFocus_=function(){var r=$r.activeElement,o=this.player_.el_;this.previouslyActiveEl_=null,(o.contains(r)||o===r)&&(this.previouslyActiveEl_=r,this.focus())},i.conditionalBlur_=function(){this.previouslyActiveEl_&&(this.previouslyActiveEl_.focus(),this.previouslyActiveEl_=null)},i.handleKeyDown=function(r){if(r.stopPropagation(),On.isEventKey(r,"Escape")&&this.closeable()){r.preventDefault(),this.close();return}if(On.isEventKey(r,"Tab")){for(var o=this.focusableEls_(),a=this.el_.querySelector(":focus"),s,l=0;l<o.length;l++)if(a===o[l]){s=l;break}$r.activeElement===this.el_&&(s=0),r.shiftKey&&s===0?(o[o.length-1].focus(),r.preventDefault()):!r.shiftKey&&s===o.length-1&&(o[0].focus(),r.preventDefault())}},i.focusableEls_=function(){var r=this.el_.querySelectorAll("*");return Array.prototype.filter.call(r,function(o){return(o instanceof Ct.HTMLAnchorElement||o instanceof Ct.HTMLAreaElement)&&o.hasAttribute("href")||(o instanceof Ct.HTMLInputElement||o instanceof Ct.HTMLSelectElement||o instanceof Ct.HTMLTextAreaElement||o instanceof Ct.HTMLButtonElement)&&!o.hasAttribute("disabled")||o instanceof Ct.HTMLIFrameElement||o instanceof Ct.HTMLObjectElement||o instanceof Ct.HTMLEmbedElement||o.hasAttribute("tabindex")&&o.getAttribute("tabindex")!==-1||o.hasAttribute("contenteditable")})},e})(Fr);PI.prototype.options_={pauseOnOpen:!0,temporary:!0};Fr.registerComponent("ModalDialog",PI);var Zk=(function(t){qr(e,t);function e(n){var r;n===void 0&&(n=[]),r=t.call(this)||this,r.tracks_=[],Object.defineProperty(bn(r),"length",{get:function(){return this.tracks_.length}});for(var o=0;o<n.length;o++)r.addTrack(n[o]);return r}var i=e.prototype;return i.addTrack=function(r){var o=this,a=this.tracks_.length;""+a in this||Object.defineProperty(this,a,{get:function(){return this.tracks_[a]}}),this.tracks_.indexOf(r)===-1&&(this.tracks_.push(r),this.trigger({track:r,type:"addtrack",target:this})),r.labelchange_=function(){o.trigger({track:r,type:"labelchange",target:o})},gS(r)&&r.addEventListener("labelchange",r.labelchange_)},i.removeTrack=function(r){for(var o,a=0,s=this.length;a<s;a++)if(this[a]===r){o=this[a],o.off&&o.off(),this.tracks_.splice(a,1);break}o&&this.trigger({track:o,type:"removetrack",target:this})},i.getTrackById=function(r){for(var o=null,a=0,s=this.length;a<s;a++){var l=this[a];if(l.id===r){o=l;break}}return o},e})(Ec);Zk.prototype.allowedEvents_={change:"change",addtrack:"addtrack",removetrack:"removetrack",labelchange:"labelchange"};for(var J_t in Zk.prototype.allowedEvents_)Zk.prototype["on"+J_t]=null;var JY=function(e,i){for(var n=0;n<e.length;n++)!Object.keys(e[n]).length||i.id===e[n].id||(e[n].enabled=!1)},Q_t=(function(t){qr(e,t);function e(n){var r;n===void 0&&(n=[]);for(var o=n.length-1;o>=0;o--)if(n[o].enabled){JY(n,n[o]);break}return r=t.call(this,n)||this,r.changing_=!1,r}var i=e.prototype;return i.addTrack=function(r){var o=this;r.enabled&&JY(this,r),t.prototype.addTrack.call(this,r),r.addEventListener&&(r.enabledChange_=function(){o.changing_||(o.changing_=!0,JY(o,r),o.changing_=!1,o.trigger("change"))},r.addEventListener("enabledchange",r.enabledChange_))},i.removeTrack=function(r){t.prototype.removeTrack.call(this,r),r.removeEventListener&&r.enabledChange_&&(r.removeEventListener("enabledchange",r.enabledChange_),r.enabledChange_=null)},e})(Zk),QY=function(e,i){for(var n=0;n<e.length;n++)!Object.keys(e[n]).length||i.id===e[n].id||(e[n].selected=!1)},ePt=(function(t){qr(e,t);function e(n){var r;n===void 0&&(n=[]);for(var o=n.length-1;o>=0;o--)if(n[o].selected){QY(n,n[o]);break}return r=t.call(this,n)||this,r.changing_=!1,Object.defineProperty(bn(r),"selectedIndex",{get:function(){for(var s=0;s<this.length;s++)if(this[s].selected)return s;return-1},set:function(){}}),r}var i=e.prototype;return i.addTrack=function(r){var o=this;r.selected&&QY(this,r),t.prototype.addTrack.call(this,r),r.addEventListener&&(r.selectedChange_=function(){o.changing_||(o.changing_=!0,QY(o,r),o.changing_=!1,o.trigger("change"))},r.addEventListener("selectedchange",r.selectedChange_))},i.removeTrack=function(r){t.prototype.removeTrack.call(this,r),r.removeEventListener&&r.selectedChange_&&(r.removeEventListener("selectedchange",r.selectedChange_),r.selectedChange_=null)},e})(Zk),ZIe=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.addTrack=function(r){var o=this;t.prototype.addTrack.call(this,r),this.queueChange_||(this.queueChange_=function(){return o.queueTrigger("change")}),this.triggerSelectedlanguagechange||(this.triggerSelectedlanguagechange_=function(){return o.trigger("selectedlanguagechange")}),r.addEventListener("modechange",this.queueChange_);var a=["metadata","chapters"];a.indexOf(r.kind)===-1&&r.addEventListener("modechange",this.triggerSelectedlanguagechange_)},i.removeTrack=function(r){t.prototype.removeTrack.call(this,r),r.removeEventListener&&(this.queueChange_&&r.removeEventListener("modechange",this.queueChange_),this.selectedlanguagechange_&&r.removeEventListener("modechange",this.triggerSelectedlanguagechange_))},e})(Zk),tPt=(function(){function t(i){i===void 0&&(i=[]),this.trackElements_=[],Object.defineProperty(this,"length",{get:function(){return this.trackElements_.length}});for(var n=0,r=i.length;n<r;n++)this.addTrackElement_(i[n])}var e=t.prototype;return e.addTrackElement_=function(n){var r=this.trackElements_.length;""+r in this||Object.defineProperty(this,r,{get:function(){return this.trackElements_[r]}}),this.trackElements_.indexOf(n)===-1&&this.trackElements_.push(n)},e.getTrackElementByTrack_=function(n){for(var r,o=0,a=this.trackElements_.length;o<a;o++)if(n===this.trackElements_[o].track){r=this.trackElements_[o];break}return r},e.removeTrackElement_=function(n){for(var r=0,o=this.trackElements_.length;r<o;r++)if(n===this.trackElements_[r]){this.trackElements_[r].track&&typeof this.trackElements_[r].track.off=="function"&&this.trackElements_[r].track.off(),typeof this.trackElements_[r].off=="function"&&this.trackElements_[r].off(),this.trackElements_.splice(r,1);break}},t})(),ide=(function(){function t(i){t.prototype.setCues_.call(this,i),Object.defineProperty(this,"length",{get:function(){return this.length_}})}var e=t.prototype;return e.setCues_=function(n){var r=this.length||0,o=0,a=n.length;this.cues_=n,this.length_=n.length;var s=function(u){""+u in this||Object.defineProperty(this,""+u,{get:function(){return this.cues_[u]}})};if(r<a)for(o=r;o<a;o++)s.call(this,o)},e.getCueById=function(n){for(var r=null,o=0,a=this.length;o<a;o++){var s=this[o];if(s.id===n){r=s;break}}return r},t})(),rPt={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},iPt={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},nPt={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},nde={disabled:"disabled",hidden:"hidden",showing:"showing"},Dte=(function(t){qr(e,t);function e(i){var n;i===void 0&&(i={}),n=t.call(this)||this;var r={id:i.id||"vjs_track_"+US(),kind:i.kind||"",language:i.language||""},o=i.label||"",a=function(u){Object.defineProperty(bn(n),u,{get:function(){return r[u]},set:function(){}})};for(var s in r)a(s);return Object.defineProperty(bn(n),"label",{get:function(){return o},set:function(u){u!==o&&(o=u,this.trigger("labelchange"))}}),n}return e})(Ec),Rte=function(e){var i=["protocol","hostname","port","pathname","search","hash","host"],n=$r.createElement("a");n.href=e;for(var r={},o=0;o<i.length;o++)r[i[o]]=n[i[o]];return r.protocol==="http:"&&(r.host=r.host.replace(/:80$/,"")),r.protocol==="https:"&&(r.host=r.host.replace(/:443$/,"")),r.protocol||(r.protocol=Ct.location.protocol),r.host||(r.host=Ct.location.host),r},JIe=function(e){if(!e.match(/^https?:\/\//)){var i=$r.createElement("a");i.href=e,e=i.href}return e},Mte=function(e){if(typeof e=="string"){var i=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/,n=i.exec(e);if(n)return n.pop().toLowerCase()}return""},J6=function(e,i){i===void 0&&(i=Ct.location);var n=Rte(e),r=n.protocol===":"?i.protocol:n.protocol,o=r+n.host!==i.protocol+i.host;return o},oPt=Object.freeze({__proto__:null,parseUrl:Rte,getAbsoluteURL:JIe,getFileExtension:Mte,isCrossOrigin:J6}),ode=function(e,i){var n=new Ct.WebVTT.Parser(Ct,Ct.vttjs,Ct.WebVTT.StringDecoder()),r=[];n.oncue=function(o){i.addCue(o)},n.onparsingerror=function(o){r.push(o)},n.onflush=function(){i.trigger({type:"loadeddata",target:i})},n.parse(e),r.length>0&&(Ct.console&&Ct.console.groupCollapsed&&Ct.console.groupCollapsed("Text Track parsing errors for "+i.src),r.forEach(function(o){return Jn.error(o)}),Ct.console&&Ct.console.groupEnd&&Ct.console.groupEnd()),n.flush()},ade=function(e,i){var n={uri:e},r=J6(e);r&&(n.cors=r);var o=i.tech_.crossOrigin()==="use-credentials";o&&(n.withCredentials=o),rIe(n,Ms(this,function(a,s,l){if(a)return Jn.error(a,s);i.loaded_=!0,typeof Ct.WebVTT!="function"?i.tech_&&i.tech_.any(["vttjsloaded","vttjserror"],function(u){if(u.type==="vttjserror"){Jn.error("vttjs failed to load, stopping trying to process "+i.src);return}return ode(l,i)}):ode(l,i)}))},VV=(function(t){qr(e,t);function e(n){var r;if(n===void 0&&(n={}),!n.tech)throw new Error("A tech was not provided.");var o=Rs(n,{kind:nPt[n.kind]||"subtitles",language:n.language||n.srclang||""}),a=nde[o.mode]||"disabled",s=o.default;(o.kind==="metadata"||o.kind==="chapters")&&(a="hidden"),r=t.call(this,o)||this,r.tech_=o.tech,r.cues_=[],r.activeCues_=[],r.preload_=r.tech_.preloadTextTracks!==!1;var l=new ide(r.cues_),u=new ide(r.activeCues_),c=!1;r.timeupdateHandler=Ms(bn(r),function(f){if(f===void 0&&(f={}),!this.tech_.isDisposed()){if(!this.tech_.isReady_){f.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler));return}this.activeCues=this.activeCues,c&&(this.trigger("cuechange"),c=!1),f.type!=="timeupdate"&&(this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler))}});var d=function(){r.stopTracking()};return r.tech_.one("dispose",d),a!=="disabled"&&r.startTracking(),Object.defineProperties(bn(r),{default:{get:function(){return s},set:function(){}},mode:{get:function(){return a},set:function(h){nde[h]&&a!==h&&(a=h,!this.preload_&&a!=="disabled"&&this.cues.length===0&&ade(this.src,this),this.stopTracking(),a!=="disabled"&&this.startTracking(),this.trigger("modechange"))}},cues:{get:function(){return this.loaded_?l:null},set:function(){}},activeCues:{get:function(){if(!this.loaded_)return null;if(this.cues.length===0)return u;for(var h=this.tech_.currentTime(),p=[],g=0,v=this.cues.length;g<v;g++){var y=this.cues[g];(y.startTime<=h&&y.endTime>=h||y.startTime===y.endTime&&y.startTime<=h&&y.startTime+.5>=h)&&p.push(y)}if(c=!1,p.length!==this.activeCues_.length)c=!0;else for(var m=0;m<p.length;m++)this.activeCues_.indexOf(p[m])===-1&&(c=!0);return this.activeCues_=p,u.setCues_(this.activeCues_),u},set:function(){}}}),o.src?(r.src=o.src,r.preload_||(r.loaded_=!0),(r.preload_||o.kind!=="subtitles"&&o.kind!=="captions")&&ade(r.src,bn(r))):r.loaded_=!0,r}var i=e.prototype;return i.startTracking=function(){this.rvf_=this.tech_.requestVideoFrameCallback(this.timeupdateHandler),this.tech_.on("timeupdate",this.timeupdateHandler)},i.stopTracking=function(){this.rvf_&&(this.tech_.cancelVideoFrameCallback(this.rvf_),this.rvf_=void 0),this.tech_.off("timeupdate",this.timeupdateHandler)},i.addCue=function(r){var o=r;if(!("getCueAsHTML"in o)){o=new Ct.vttjs.VTTCue(r.startTime,r.endTime,r.text);for(var a in r)a in o||(o[a]=r[a]);o.id=r.id,o.originalCue_=r}for(var s=this.tech_.textTracks(),l=0;l<s.length;l++)s[l]!==this&&s[l].removeCue(o);this.cues_.push(o),this.cues.setCues_(this.cues_)},i.removeCue=function(r){for(var o=this.cues_.length;o--;){var a=this.cues_[o];if(a===r||a.originalCue_&&a.originalCue_===r){this.cues_.splice(o,1),this.cues.setCues_(this.cues_);break}}},e})(Dte);VV.prototype.allowedEvents_={cuechange:"cuechange"};var QIe=(function(t){qr(e,t);function e(i){var n;i===void 0&&(i={});var r=Rs(i,{kind:iPt[i.kind]||""});n=t.call(this,r)||this;var o=!1;return Object.defineProperty(bn(n),"enabled",{get:function(){return o},set:function(s){typeof s!="boolean"||s===o||(o=s,this.trigger("enabledchange"))}}),r.enabled&&(n.enabled=r.enabled),n.loaded_=!0,n}return e})(Dte),e2e=(function(t){qr(e,t);function e(i){var n;i===void 0&&(i={});var r=Rs(i,{kind:rPt[i.kind]||""});n=t.call(this,r)||this;var o=!1;return Object.defineProperty(bn(n),"selected",{get:function(){return o},set:function(s){typeof s!="boolean"||s===o||(o=s,this.trigger("selectedchange"))}}),r.selected&&(n.selected=r.selected),n}return e})(Dte),t2e=0,aPt=1,r2e=2,sPt=3,CI=(function(t){qr(e,t);function e(i){var n;i===void 0&&(i={}),n=t.call(this)||this;var r,o=new VV(i);return n.kind=o.kind,n.src=o.src,n.srclang=o.language,n.label=o.label,n.default=o.default,Object.defineProperties(bn(n),{readyState:{get:function(){return r}},track:{get:function(){return o}}}),r=t2e,o.addEventListener("loadeddata",function(){r=r2e,n.trigger({type:"load",target:bn(n)})}),n}return e})(Ec);CI.prototype.allowedEvents_={load:"load"};CI.NONE=t2e;CI.LOADING=aPt;CI.LOADED=r2e;CI.ERROR=sPt;var Ag={audio:{ListClass:Q_t,TrackClass:QIe,capitalName:"Audio"},video:{ListClass:ePt,TrackClass:e2e,capitalName:"Video"},text:{ListClass:ZIe,TrackClass:VV,capitalName:"Text"}};Object.keys(Ag).forEach(function(t){Ag[t].getterName=t+"Tracks",Ag[t].privateName=t+"Tracks_"});var Jk={remoteText:{ListClass:ZIe,TrackClass:VV,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:tPt,TrackClass:CI,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},Df=Gn({},Ag,Jk);Jk.names=Object.keys(Jk);Ag.names=Object.keys(Ag);Df.names=[].concat(Jk.names).concat(Ag.names);function lPt(t,e,i,n,r){r===void 0&&(r={});var o=t.textTracks();r.kind=e,i&&(r.label=i),n&&(r.language=n),r.tech=t;var a=new Df.text.TrackClass(r);return o.addTrack(a),a}var Ja=(function(t){qr(e,t);function e(n,r){var o;return n===void 0&&(n={}),r===void 0&&(r=function(){}),n.reportTouchActivity=!1,o=t.call(this,null,n,r)||this,o.onDurationChange_=function(a){return o.onDurationChange(a)},o.trackProgress_=function(a){return o.trackProgress(a)},o.trackCurrentTime_=function(a){return o.trackCurrentTime(a)},o.stopTrackingCurrentTime_=function(a){return o.stopTrackingCurrentTime(a)},o.disposeSourceHandler_=function(a){return o.disposeSourceHandler(a)},o.queuedHanders_=new Set,o.hasStarted_=!1,o.on("playing",function(){this.hasStarted_=!0}),o.on("loadstart",function(){this.hasStarted_=!1}),Df.names.forEach(function(a){var s=Df[a];n&&n[s.getterName]&&(o[s.privateName]=n[s.getterName])}),o.featuresProgressEvents||o.manualProgressOn(),o.featuresTimeupdateEvents||o.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(function(a){n["native"+a+"Tracks"]===!1&&(o["featuresNative"+a+"Tracks"]=!1)}),n.nativeCaptions===!1||n.nativeTextTracks===!1?o.featuresNativeTextTracks=!1:(n.nativeCaptions===!0||n.nativeTextTracks===!0)&&(o.featuresNativeTextTracks=!0),o.featuresNativeTextTracks||o.emulateTextTracks(),o.preloadTextTracks=n.preloadTextTracks!==!1,o.autoRemoteTextTracks_=new Df.text.ListClass,o.initTrackListeners(),n.nativeControlsForTouch||o.emitTapEvents(),o.constructor&&(o.name_=o.constructor.name||"Unknown Tech"),o}var i=e.prototype;return i.triggerSourceset=function(r){var o=this;this.isReady_||this.one("ready",function(){return o.setTimeout(function(){return o.triggerSourceset(r)},1)}),this.trigger({src:r,type:"sourceset"})},i.manualProgressOn=function(){this.on("durationchange",this.onDurationChange_),this.manualProgress=!0,this.one("ready",this.trackProgress_)},i.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange_)},i.trackProgress=function(r){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Ms(this,function(){var o=this.bufferedPercent();this.bufferedPercent_!==o&&this.trigger("progress"),this.bufferedPercent_=o,o===1&&this.stopTrackingProgress()}),500)},i.onDurationChange=function(r){this.duration_=this.duration()},i.buffered=function(){return hD(0,0)},i.bufferedPercent=function(){return KIe(this.buffered(),this.duration_)},i.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},i.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime_),this.on("pause",this.stopTrackingCurrentTime_)},i.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime_),this.off("pause",this.stopTrackingCurrentTime_)},i.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval(function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},250)},i.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},i.dispose=function(){this.clearTracks(Ag.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},i.clearTracks=function(r){var o=this;r=[].concat(r),r.forEach(function(a){for(var s=o[a+"Tracks"]()||[],l=s.length;l--;){var u=s[l];a==="text"&&o.removeRemoteTextTrack(u),s.removeTrack(u)}})},i.cleanupAutoTextTracks=function(){for(var r=this.autoRemoteTextTracks_||[],o=r.length;o--;){var a=r[o];this.removeRemoteTextTrack(a)}},i.reset=function(){},i.crossOrigin=function(){},i.setCrossOrigin=function(){},i.error=function(r){return r!==void 0&&(this.error_=new Ff(r),this.trigger("error")),this.error_},i.played=function(){return this.hasStarted_?hD(0,0):hD()},i.play=function(){},i.setScrubbing=function(){},i.scrubbing=function(){},i.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},i.initTrackListeners=function(){var r=this;Ag.names.forEach(function(o){var a=Ag[o],s=function(){r.trigger(o+"trackchange")},l=r[a.getterName]();l.addEventListener("removetrack",s),l.addEventListener("addtrack",s),r.on("dispose",function(){l.removeEventListener("removetrack",s),l.removeEventListener("addtrack",s)})})},i.addWebVttScript_=function(){var r=this;if(!Ct.WebVTT)if($r.body.contains(this.el())){if(!this.options_["vtt.js"]&&L3(Ece)&&Object.keys(Ece).length>0){this.trigger("vttjsloaded");return}var o=$r.createElement("script");o.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.14.1/vtt.min.js",o.onload=function(){r.trigger("vttjsloaded")},o.onerror=function(){r.trigger("vttjserror")},this.on("dispose",function(){o.onload=null,o.onerror=null}),Ct.WebVTT=!0,this.el().parentNode.appendChild(o)}else this.ready(this.addWebVttScript_)},i.emulateTextTracks=function(){var r=this,o=this.textTracks(),a=this.remoteTextTracks(),s=function(f){return o.addTrack(f.track)},l=function(f){return o.removeTrack(f.track)};a.on("addtrack",s),a.on("removetrack",l),this.addWebVttScript_();var u=function(){return r.trigger("texttrackchange")},c=function(){u();for(var f=0;f<o.length;f++){var h=o[f];h.removeEventListener("cuechange",u),h.mode==="showing"&&h.addEventListener("cuechange",u)}};c(),o.addEventListener("change",c),o.addEventListener("addtrack",c),o.addEventListener("removetrack",c),this.on("dispose",function(){a.off("addtrack",s),a.off("removetrack",l),o.removeEventListener("change",c),o.removeEventListener("addtrack",c),o.removeEventListener("removetrack",c);for(var d=0;d<o.length;d++){var f=o[d];f.removeEventListener("cuechange",u)}})},i.addTextTrack=function(r,o,a){if(!r)throw new Error("TextTrack kind is required but was not provided");return lPt(this,r,o,a)},i.createRemoteTextTrack=function(r){var o=Rs(r,{tech:this});return new Jk.remoteTextEl.TrackClass(o)},i.addRemoteTextTrack=function(r,o){var a=this;r===void 0&&(r={});var s=this.createRemoteTextTrack(r);return o!==!0&&o!==!1&&(Jn.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),o=!0),this.remoteTextTrackEls().addTrackElement_(s),this.remoteTextTracks().addTrack(s.track),o!==!0&&this.ready(function(){return a.autoRemoteTextTracks_.addTrack(s.track)}),s},i.removeRemoteTextTrack=function(r){var o=this.remoteTextTrackEls().getTrackElementByTrack_(r);this.remoteTextTrackEls().removeTrackElement_(o),this.remoteTextTracks().removeTrack(r),this.autoRemoteTextTracks_.removeTrack(r)},i.getVideoPlaybackQuality=function(){return{}},i.requestPictureInPicture=function(){var r=this.options_.Promise||Ct.Promise;if(r)return r.reject()},i.disablePictureInPicture=function(){return!0},i.setDisablePictureInPicture=function(){},i.requestVideoFrameCallback=function(r){var o=this,a=US();return!this.isReady_||this.paused()?(this.queuedHanders_.add(a),this.one("playing",function(){o.queuedHanders_.has(a)&&(o.queuedHanders_.delete(a),r())})):this.requestNamedAnimationFrame(a,r),a},i.cancelVideoFrameCallback=function(r){this.queuedHanders_.has(r)?this.queuedHanders_.delete(r):this.cancelNamedAnimationFrame(r)},i.setPoster=function(){},i.playsinline=function(){},i.setPlaysinline=function(){},i.overrideNativeAudioTracks=function(){},i.overrideNativeVideoTracks=function(){},i.canPlayType=function(){return""},e.canPlayType=function(){return""},e.canPlaySource=function(r,o){return e.canPlayType(r.type)},e.isTech=function(r){return r.prototype instanceof e||r instanceof e||r===e},e.registerTech=function(r,o){if(e.techs_||(e.techs_={}),!e.isTech(o))throw new Error("Tech "+r+" must be a Tech");if(!e.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!e.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return r=Ql(r),e.techs_[r]=o,e.techs_[ZU(r)]=o,r!=="Tech"&&e.defaultTechOrder_.push(r),o},e.getTech=function(r){if(r){if(e.techs_&&e.techs_[r])return e.techs_[r];if(r=Ql(r),Ct&&Ct.videojs&&Ct.videojs[r])return Jn.warn("The "+r+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),Ct.videojs[r]}},e})(Fr);Df.names.forEach(function(t){var e=Df[t];Ja.prototype[e.getterName]=function(){return this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName]}});Ja.prototype.featuresVolumeControl=!0;Ja.prototype.featuresMuteControl=!0;Ja.prototype.featuresFullscreenResize=!1;Ja.prototype.featuresPlaybackRate=!1;Ja.prototype.featuresProgressEvents=!1;Ja.prototype.featuresSourceset=!1;Ja.prototype.featuresTimeupdateEvents=!1;Ja.prototype.featuresNativeTextTracks=!1;Ja.prototype.featuresVideoFrameCallback=!1;Ja.withSourceHandlers=function(t){t.registerSourceHandler=function(i,n){var r=t.sourceHandlers;r||(r=t.sourceHandlers=[]),n===void 0&&(n=r.length),r.splice(n,0,i)},t.canPlayType=function(i){for(var n=t.sourceHandlers||[],r,o=0;o<n.length;o++)if(r=n[o].canPlayType(i),r)return r;return""},t.selectSourceHandler=function(i,n){for(var r=t.sourceHandlers||[],o,a=0;a<r.length;a++)if(o=r[a].canHandleSource(i,n),o)return r[a];return null},t.canPlaySource=function(i,n){var r=t.selectSourceHandler(i,n);return r?r.canHandleSource(i,n):""};var e=["seekable","seeking","duration"];e.forEach(function(i){var n=this[i];typeof n=="function"&&(this[i]=function(){return this.sourceHandler_&&this.sourceHandler_[i]?this.sourceHandler_[i].apply(this.sourceHandler_,arguments):n.apply(this,arguments)})},t.prototype),t.prototype.setSource=function(i){var n=t.selectSourceHandler(i,this.options_);n||(t.nativeSourceHandler?n=t.nativeSourceHandler:Jn.error("No source handler found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler_),n!==t.nativeSourceHandler&&(this.currentSource_=i),this.sourceHandler_=n.handleSource(i,this,this.options_),this.one("dispose",this.disposeSourceHandler_)},t.prototype.disposeSourceHandler=function(){this.currentSource_&&(this.clearTracks(["audio","video"]),this.currentSource_=null),this.cleanupAutoTextTracks(),this.sourceHandler_&&(this.sourceHandler_.dispose&&this.sourceHandler_.dispose(),this.sourceHandler_=null)}};Fr.registerComponent("Tech",Ja);Ja.registerTech("Tech",Ja);Ja.defaultTechOrder_=[];var pD={},GZ={},Tz={};function uPt(t,e){pD[t]=pD[t]||[],pD[t].push(e)}function cPt(t,e,i){t.setTimeout(function(){return IO(e,pD[e.type],i,t)},1)}function dPt(t,e){t.forEach(function(i){return i.setTech&&i.setTech(e)})}function fPt(t,e,i){return t.reduceRight(Lte(i),e[i]())}function hPt(t,e,i,n){return e[i](t.reduce(Lte(i),n))}function sde(t,e,i,n){n===void 0&&(n=null);var r="call"+Ql(i),o=t.reduce(Lte(r),n),a=o===Tz,s=a?null:e[i](o);return vPt(t,i,s,a),s}var pPt={buffered:1,currentTime:1,duration:1,muted:1,played:1,paused:1,seekable:1,volume:1,ended:1},gPt={setCurrentTime:1,setMuted:1,setVolume:1},lde={play:1,pause:1};function Lte(t){return function(e,i){return e===Tz?Tz:i[t]?i[t](e):e}}function vPt(t,e,i,n){for(var r=t.length-1;r>=0;r--){var o=t[r];o[e]&&o[e](n,i)}}function yPt(t){GZ[t.id()]=null}function mPt(t,e){var i=GZ[t.id()],n=null;if(i==null)return n=e(t),GZ[t.id()]=[[e,n]],n;for(var r=0;r<i.length;r++){var o=i[r],a=o[0],s=o[1];a===e&&(n=s)}return n===null&&(n=e(t),i.push([e,n])),n}function IO(t,e,i,n,r,o){t===void 0&&(t={}),e===void 0&&(e=[]),r===void 0&&(r=[]),o===void 0&&(o=!1);var a=e,s=a[0],l=a.slice(1);if(typeof s=="string")IO(t,pD[s],i,n,r,o);else if(s){var u=mPt(n,s);if(!u.setSource)return r.push(u),IO(t,l,i,n,r,o);u.setSource(Nl({},t),function(c,d){if(c)return IO(t,l,i,n,r,o);r.push(u),IO(d,t.type===d.type?l:pD[d.type],i,n,r,o)})}else l.length?IO(t,l,i,n,r,o):o?i(t,r):IO(t,pD["*"],i,n,r,!0)}var bPt={opus:"video/ogg",ogv:"video/ogg",mp4:"video/mp4",mov:"video/mp4",m4v:"video/mp4",mkv:"video/x-matroska",m4a:"audio/mp4",mp3:"audio/mpeg",aac:"audio/aac",caf:"audio/x-caf",flac:"audio/flac",oga:"audio/ogg",wav:"audio/wav",m3u8:"application/x-mpegURL",mpd:"application/dash+xml",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",png:"image/png",svg:"image/svg+xml",webp:"image/webp"},xz=function(e){e===void 0&&(e="");var i=Mte(e),n=bPt[i.toLowerCase()];return n||""},SPt=function(e,i){if(!i)return"";if(e.cache_.source.src===i&&e.cache_.source.type)return e.cache_.source.type;var n=e.cache_.sources.filter(function(s){return s.src===i});if(n.length)return n[0].type;for(var r=e.$$("source"),o=0;o<r.length;o++){var a=r[o];if(a.type&&a.src&&a.src===i)return a.type}return xz(i)},_Pt=function t(e){if(Array.isArray(e)){var i=[];e.forEach(function(n){n=t(n),Array.isArray(n)?i=i.concat(n):OS(n)&&i.push(n)}),e=i}else typeof e=="string"&&e.trim()?e=[ude({src:e})]:OS(e)&&typeof e.src=="string"&&e.src&&e.src.trim()?e=[ude(e)]:e=[];return e};function ude(t){if(!t.type){var e=xz(t.src);e&&(t.type=e)}return t}var PPt=(function(t){qr(e,t);function e(i,n,r){var o,a=Rs({createEl:!1},n);if(o=t.call(this,i,a,r)||this,!n.playerOptions.sources||n.playerOptions.sources.length===0)for(var s=0,l=n.playerOptions.techOrder;s<l.length;s++){var u=Ql(l[s]),c=Ja.getTech(u);if(u||(c=Fr.getComponent(u)),c&&c.isSupported()){i.loadTech_(u);break}}else i.src(n.playerOptions.sources);return o}return e})(Fr);Fr.registerComponent("MediaLoader",PPt);var Q6=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.options_.controlText&&o.controlText(o.options_.controlText),o.handleMouseOver_=function(a){return o.handleMouseOver(a)},o.handleMouseOut_=function(a){return o.handleMouseOut(a)},o.handleClick_=function(a){return o.handleClick(a)},o.handleKeyDown_=function(a){return o.handleKeyDown(a)},o.emitTapEvents(),o.enable(),o}var i=e.prototype;return i.createEl=function(r,o,a){r===void 0&&(r="div"),o===void 0&&(o={}),a===void 0&&(a={}),o=Nl({className:this.buildCSSClass(),tabIndex:0},o),r==="button"&&Jn.error("Creating a ClickableComponent with an HTML element of "+r+" is not supported; use a Button instead."),a=Nl({role:"button"},a),this.tabIndex_=o.tabIndex;var s=Vo(r,o,a);return s.appendChild(Vo("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(s),s},i.dispose=function(){this.controlTextEl_=null,t.prototype.dispose.call(this)},i.createControlTextEl=function(r){return this.controlTextEl_=Vo("span",{className:"vjs-control-text"},{"aria-live":"polite"}),r&&r.appendChild(this.controlTextEl_),this.controlText(this.controlText_,r),this.controlTextEl_},i.controlText=function(r,o){if(o===void 0&&(o=this.el()),r===void 0)return this.controlText_||"Need Text";var a=this.localize(r);this.controlText_=r,KD(this.controlTextEl_,a),!this.nonIconControl&&!this.player_.options_.noUITitleAttributes&&o.setAttribute("title",a)},i.buildCSSClass=function(){return"vjs-control vjs-button "+t.prototype.buildCSSClass.call(this)},i.enable=function(){this.enabled_||(this.enabled_=!0,this.removeClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","false"),typeof this.tabIndex_<"u"&&this.el_.setAttribute("tabIndex",this.tabIndex_),this.on(["tap","click"],this.handleClick_),this.on("keydown",this.handleKeyDown_))},i.disable=function(){this.enabled_=!1,this.addClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","true"),typeof this.tabIndex_<"u"&&this.el_.removeAttribute("tabIndex"),this.off("mouseover",this.handleMouseOver_),this.off("mouseout",this.handleMouseOut_),this.off(["tap","click"],this.handleClick_),this.off("keydown",this.handleKeyDown_)},i.handleLanguagechange=function(){this.controlText(this.controlText_)},i.handleClick=function(r){this.options_.clickHandler&&this.options_.clickHandler.call(this,arguments)},i.handleKeyDown=function(r){On.isEventKey(r,"Space")||On.isEventKey(r,"Enter")?(r.preventDefault(),r.stopPropagation(),this.trigger("click")):t.prototype.handleKeyDown.call(this,r)},e})(Fr);Fr.registerComponent("ClickableComponent",Q6);var CPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update(),o.update_=function(a){return o.update(a)},n.on("posterchange",o.update_),o}var i=e.prototype;return i.dispose=function(){this.player().off("posterchange",this.update_),t.prototype.dispose.call(this)},i.createEl=function(){var r=Vo("div",{className:"vjs-poster",tabIndex:-1});return r},i.update=function(r){var o=this.player().poster();this.setSrc(o),o?this.show():this.hide()},i.setSrc=function(r){var o="";r&&(o='url("'+r+'")'),this.el_.style.backgroundImage=o},i.handleClick=function(r){if(this.player_.controls()){var o=this.player_.usingPlugin("eme")&&this.player_.eme.sessions&&this.player_.eme.sessions.length>0;this.player_.tech(!0)&&!((BV||FV)&&o)&&this.player_.tech(!0).focus(),this.player_.paused()?Qy(this.player_.play()):this.player_.pause()}},e})(Q6);Fr.registerComponent("PosterImage",CPt);var gg="#222",cde="#ccc",TPt={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function eq(t,e){var i;if(t.length===4)i=t[1]+t[1]+t[2]+t[2]+t[3]+t[3];else if(t.length===7)i=t.slice(1);else throw new Error("Invalid color code provided, "+t+"; must be formatted as e.g. #f0e or #f604e2.");return"rgba("+parseInt(i.slice(0,2),16)+","+parseInt(i.slice(2,4),16)+","+parseInt(i.slice(4,6),16)+","+e+")"}function tq(t,e,i){try{t.style[e]=i}catch{return}}var xPt=(function(t){qr(e,t);function e(n,r,o){var a;a=t.call(this,n,r,o)||this;var s=function(u){return a.updateDisplay(u)};return n.on("loadstart",function(l){return a.toggleDisplay(l)}),n.on("texttrackchange",s),n.on("loadedmetadata",function(l){return a.preselectTrack(l)}),n.ready(Ms(bn(a),function(){if(n.tech_&&n.tech_.featuresNativeTextTracks){this.hide();return}n.on("fullscreenchange",s),n.on("playerresize",s),Ct.addEventListener("orientationchange",s),n.on("dispose",function(){return Ct.removeEventListener("orientationchange",s)});for(var l=this.options_.playerOptions.tracks||[],u=0;u<l.length;u++)this.player_.addRemoteTextTrack(l[u],!0);this.preselectTrack()})),a}var i=e.prototype;return i.preselectTrack=function(){for(var r={captions:1,subtitles:1},o=this.player_.textTracks(),a=this.player_.cache_.selectedLanguage,s,l,u,c=0;c<o.length;c++){var d=o[c];a&&a.enabled&&a.language&&a.language===d.language&&d.kind in r?d.kind===a.kind?u=d:u||(u=d):a&&!a.enabled?(u=null,s=null,l=null):d.default&&(d.kind==="descriptions"&&!s?s=d:d.kind in r&&!l&&(l=d))}u?u.mode="showing":l?l.mode="showing":s&&(s.mode="showing")},i.toggleDisplay=function(){this.player_.tech_&&this.player_.tech_.featuresNativeTextTracks?this.hide():this.show()},i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{translate:"yes","aria-live":"off","aria-atomic":"true"})},i.clearDisplay=function(){typeof Ct.WebVTT=="function"&&Ct.WebVTT.processCues(Ct,[],this.el_)},i.updateDisplay=function(){var r=this.player_.textTracks(),o=this.options_.allowMultipleShowingTracks;if(this.clearDisplay(),o){for(var a=[],s=0;s<r.length;++s){var l=r[s];l.mode==="showing"&&a.push(l)}this.updateForTrack(a);return}for(var u=null,c=null,d=r.length;d--;){var f=r[d];f.mode==="showing"&&(f.kind==="descriptions"?u=f:c=f)}c?(this.getAttribute("aria-live")!=="off"&&this.setAttribute("aria-live","off"),this.updateForTrack(c)):u&&(this.getAttribute("aria-live")!=="assertive"&&this.setAttribute("aria-live","assertive"),this.updateForTrack(u))},i.updateDisplayState=function(r){for(var o=this.player_.textTrackSettings.getValues(),a=r.activeCues,s=a.length;s--;){var l=a[s];if(l){var u=l.displayState;if(o.color&&(u.firstChild.style.color=o.color),o.textOpacity&&tq(u.firstChild,"color",eq(o.color||"#fff",o.textOpacity)),o.backgroundColor&&(u.firstChild.style.backgroundColor=o.backgroundColor),o.backgroundOpacity&&tq(u.firstChild,"backgroundColor",eq(o.backgroundColor||"#000",o.backgroundOpacity)),o.windowColor&&(o.windowOpacity?tq(u,"backgroundColor",eq(o.windowColor,o.windowOpacity)):u.style.backgroundColor=o.windowColor),o.edgeStyle&&(o.edgeStyle==="dropshadow"?u.firstChild.style.textShadow="2px 2px 3px "+gg+", 2px 2px 4px "+gg+", 2px 2px 5px "+gg:o.edgeStyle==="raised"?u.firstChild.style.textShadow="1px 1px "+gg+", 2px 2px "+gg+", 3px 3px "+gg:o.edgeStyle==="depressed"?u.firstChild.style.textShadow="1px 1px "+cde+", 0 1px "+cde+", -1px -1px "+gg+", 0 -1px "+gg:o.edgeStyle==="uniform"&&(u.firstChild.style.textShadow="0 0 4px "+gg+", 0 0 4px "+gg+", 0 0 4px "+gg+", 0 0 4px "+gg)),o.fontPercent&&o.fontPercent!==1){var c=Ct.parseFloat(u.style.fontSize);u.style.fontSize=c*o.fontPercent+"px",u.style.height="auto",u.style.top="auto"}o.fontFamily&&o.fontFamily!=="default"&&(o.fontFamily==="small-caps"?u.firstChild.style.fontVariant="small-caps":u.firstChild.style.fontFamily=TPt[o.fontFamily])}}},i.updateForTrack=function(r){if(Array.isArray(r)||(r=[r]),!(typeof Ct.WebVTT!="function"||r.every(function(h){return!h.activeCues}))){for(var o=[],a=0;a<r.length;++a)for(var s=r[a],l=0;l<s.activeCues.length;++l)o.push(s.activeCues[l]);Ct.WebVTT.processCues(Ct,o,this.el_);for(var u=0;u<r.length;++u){for(var c=r[u],d=0;d<c.activeCues.length;++d){var f=c.activeCues[d].displayState;pS(f,"vjs-text-track-cue"),pS(f,"vjs-text-track-cue-"+(c.language?c.language:u)),c.language&&Xk(f,"lang",c.language)}this.player_.textTrackSettings&&this.updateDisplayState(c)}}},e})(Fr);Fr.registerComponent("TextTrackDisplay",xPt);var EPt=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(){var r=this.player_.isAudio(),o=this.localize(r?"Audio Player":"Video Player"),a=Vo("span",{className:"vjs-control-text",textContent:this.localize("{1} is loading.",[o])}),s=t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"});return s.appendChild(a),s},e})(Fr);Fr.registerComponent("LoadingSpinner",EPt);var kv=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(r,o,a){o===void 0&&(o={}),a===void 0&&(a={}),r="button",o=Nl({className:this.buildCSSClass()},o),a=Nl({type:"button"},a);var s=Vo(r,o,a);return s.appendChild(Vo("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),this.createControlTextEl(s),s},i.addChild=function(r,o){o===void 0&&(o={});var a=this.constructor.name;return Jn.warn("Adding an actionable (user controllable) child to a Button ("+a+") is not supported; use a ClickableComponent instead."),Fr.prototype.addChild.call(this,r,o)},i.enable=function(){t.prototype.enable.call(this),this.el_.removeAttribute("disabled")},i.disable=function(){t.prototype.disable.call(this),this.el_.setAttribute("disabled","disabled")},i.handleKeyDown=function(r){if(On.isEventKey(r,"Space")||On.isEventKey(r,"Enter")){r.stopPropagation();return}t.prototype.handleKeyDown.call(this,r)},e})(Q6);Fr.registerComponent("Button",kv);var i2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.mouseused_=!1,o.on("mousedown",function(a){return o.handleMouseDown(a)}),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-big-play-button"},i.handleClick=function(r){var o=this.player_.play();if(this.mouseused_&&r.clientX&&r.clientY){var a=this.player_.usingPlugin("eme")&&this.player_.eme.sessions&&this.player_.eme.sessions.length>0;Qy(o),this.player_.tech(!0)&&!((BV||FV)&&a)&&this.player_.tech(!0).focus();return}var s=this.player_.getChild("controlBar"),l=s&&s.getChild("playToggle");if(!l){this.player_.tech(!0).focus();return}var u=function(){return l.focus()};Oj(o)?o.then(u,function(){}):this.setTimeout(u,1)},i.handleKeyDown=function(r){this.mouseused_=!1,t.prototype.handleKeyDown.call(this,r)},i.handleMouseDown=function(r){this.mouseused_=!0},e})(kv);i2e.prototype.controlText_="Play Video";Fr.registerComponent("BigPlayButton",i2e);var wPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.controlText(r&&r.controlText||o.localize("Close")),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-close-button "+t.prototype.buildCSSClass.call(this)},i.handleClick=function(r){this.trigger({type:"close",bubbles:!1})},i.handleKeyDown=function(r){On.isEventKey(r,"Esc")?(r.preventDefault(),r.stopPropagation(),this.trigger("click")):t.prototype.handleKeyDown.call(this,r)},e})(kv);Fr.registerComponent("CloseButton",wPt);var n2e=(function(t){qr(e,t);function e(n,r){var o;return r===void 0&&(r={}),o=t.call(this,n,r)||this,r.replay=r.replay===void 0||r.replay,o.on(n,"play",function(a){return o.handlePlay(a)}),o.on(n,"pause",function(a){return o.handlePause(a)}),r.replay&&o.on(n,"ended",function(a){return o.handleEnded(a)}),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},i.handleClick=function(r){this.player_.paused()?Qy(this.player_.play()):this.player_.pause()},i.handleSeeked=function(r){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(r):this.handlePlay(r)},i.handlePlay=function(r){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},i.handlePause=function(r){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},i.handleEnded=function(r){var o=this;this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.controlText("Replay"),this.one(this.player_,"seeked",function(a){return o.handleSeeked(a)})},e})(kv);n2e.prototype.controlText_="Play";Fr.registerComponent("PlayToggle",n2e);var o2e=function(e,i){e=e<0?0:e;var n=Math.floor(e%60),r=Math.floor(e/60%60),o=Math.floor(e/3600),a=Math.floor(i/60%60),s=Math.floor(i/3600);return(isNaN(e)||e===1/0)&&(o=r=n="-"),o=o>0||s>0?o+":":"",r=((o||a>=10)&&r<10?"0"+r:r)+":",n=n<10?"0"+n:n,o+r+n},kte=o2e;function APt(t){kte=t}function OPt(){kte=o2e}function Qk(t,e){return e===void 0&&(e=t),kte(t,e)}var TI=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on(n,["timeupdate","ended"],function(a){return o.updateContent(a)}),o.updateTextNode_(),o}var i=e.prototype;return i.createEl=function(){var r=this.buildCSSClass(),o=t.prototype.createEl.call(this,"div",{className:r+" vjs-time-control vjs-control"}),a=Vo("span",{className:"vjs-control-text",textContent:this.localize(this.labelText_)+" "},{role:"presentation"});return o.appendChild(a),this.contentEl_=Vo("span",{className:r+"-display"},{"aria-live":"off",role:"presentation"}),o.appendChild(this.contentEl_),o},i.dispose=function(){this.contentEl_=null,this.textNode_=null,t.prototype.dispose.call(this)},i.updateTextNode_=function(r){var o=this;r===void 0&&(r=0),r=Qk(r),this.formattedTime_!==r&&(this.formattedTime_=r,this.requestNamedAnimationFrame("TimeDisplay#updateTextNode_",function(){if(o.contentEl_){var a=o.textNode_;a&&o.contentEl_.firstChild!==a&&(a=null,Jn.warn("TimeDisplay#updateTextnode_: Prevented replacement of text node element since it was no longer a child of this node. Appending a new node instead.")),o.textNode_=$r.createTextNode(o.formattedTime_),o.textNode_&&(a?o.contentEl_.replaceChild(o.textNode_,a):o.contentEl_.appendChild(o.textNode_))}}))},i.updateContent=function(r){},e})(Fr);TI.prototype.labelText_="Time";TI.prototype.controlText_="Time";Fr.registerComponent("TimeDisplay",TI);var Ite=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-current-time"},i.updateContent=function(r){var o;this.player_.ended()?o=this.player_.duration():o=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime(),this.updateTextNode_(o)},e})(TI);Ite.prototype.labelText_="Current Time";Ite.prototype.controlText_="Current Time";Fr.registerComponent("CurrentTimeDisplay",Ite);var Nte=(function(t){qr(e,t);function e(n,r){var o;o=t.call(this,n,r)||this;var a=function(l){return o.updateContent(l)};return o.on(n,"durationchange",a),o.on(n,"loadstart",a),o.on(n,"loadedmetadata",a),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-duration"},i.updateContent=function(r){var o=this.player_.duration();this.updateTextNode_(o)},e})(TI);Nte.prototype.labelText_="Duration";Nte.prototype.controlText_="Duration";Fr.registerComponent("DurationDisplay",Nte);var DPt=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider"},{"aria-hidden":!0}),o=t.prototype.createEl.call(this,"div"),a=t.prototype.createEl.call(this,"span",{textContent:"/"});return o.appendChild(a),r.appendChild(o),r},e})(Fr);Fr.registerComponent("TimeDivider",DPt);var Fte=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on(n,"durationchange",function(a){return o.updateContent(a)}),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-remaining-time"},i.createEl=function(){var r=t.prototype.createEl.call(this);return this.options_.displayNegative!==!1&&r.insertBefore(Vo("span",{},{"aria-hidden":!0},"-"),this.contentEl_),r},i.updateContent=function(r){if(typeof this.player_.duration()=="number"){var o;this.player_.ended()?o=0:this.player_.remainingTimeDisplay?o=this.player_.remainingTimeDisplay():o=this.player_.remainingTime(),this.updateTextNode_(o)}},e})(TI);Fte.prototype.labelText_="Remaining Time";Fte.prototype.controlText_="Remaining Time";Fr.registerComponent("RemainingTimeDisplay",Fte);var RPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.updateShowing(),o.on(o.player(),"durationchange",function(a){return o.updateShowing(a)}),o}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.contentEl_=Vo("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.contentEl_.appendChild(Vo("span",{className:"vjs-control-text",textContent:this.localize("Stream Type")+" "})),this.contentEl_.appendChild($r.createTextNode(this.localize("LIVE"))),r.appendChild(this.contentEl_),r},i.dispose=function(){this.contentEl_=null,t.prototype.dispose.call(this)},i.updateShowing=function(r){this.player().duration()===1/0?this.show():this.hide()},e})(Fr);Fr.registerComponent("LiveDisplay",RPt);var a2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.updateLiveEdgeStatus(),o.player_.liveTracker&&(o.updateLiveEdgeStatusHandler_=function(a){return o.updateLiveEdgeStatus(a)},o.on(o.player_.liveTracker,"liveedgechange",o.updateLiveEdgeStatusHandler_)),o}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this,"button",{className:"vjs-seek-to-live-control vjs-control"});return this.textEl_=Vo("span",{className:"vjs-seek-to-live-text",textContent:this.localize("LIVE")},{"aria-hidden":"true"}),r.appendChild(this.textEl_),r},i.updateLiveEdgeStatus=function(){!this.player_.liveTracker||this.player_.liveTracker.atLiveEdge()?(this.setAttribute("aria-disabled",!0),this.addClass("vjs-at-live-edge"),this.controlText("Seek to live, currently playing live")):(this.setAttribute("aria-disabled",!1),this.removeClass("vjs-at-live-edge"),this.controlText("Seek to live, currently behind live"))},i.handleClick=function(){this.player_.liveTracker.seekToLiveEdge()},i.dispose=function(){this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.updateLiveEdgeStatusHandler_),this.textEl_=null,t.prototype.dispose.call(this)},e})(kv);a2e.prototype.controlText_="Seek to live, currently playing live";Fr.registerComponent("SeekToLive",a2e);var eW=function(e,i,n){return e=Number(e),Math.min(n,Math.max(i,isNaN(e)?i:e))},Bte=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.handleMouseDown_=function(a){return o.handleMouseDown(a)},o.handleMouseUp_=function(a){return o.handleMouseUp(a)},o.handleKeyDown_=function(a){return o.handleKeyDown(a)},o.handleClick_=function(a){return o.handleClick(a)},o.handleMouseMove_=function(a){return o.handleMouseMove(a)},o.update_=function(a){return o.update(a)},o.bar=o.getChild(o.options_.barName),o.vertical(!!o.options_.vertical),o.enable(),o}var i=e.prototype;return i.enabled=function(){return this.enabled_},i.enable=function(){this.enabled()||(this.on("mousedown",this.handleMouseDown_),this.on("touchstart",this.handleMouseDown_),this.on("keydown",this.handleKeyDown_),this.on("click",this.handleClick_),this.on(this.player_,"controlsvisible",this.update),this.playerEvent&&this.on(this.player_,this.playerEvent,this.update),this.removeClass("disabled"),this.setAttribute("tabindex",0),this.enabled_=!0)},i.disable=function(){if(this.enabled()){var r=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown_),this.off("touchstart",this.handleMouseDown_),this.off("keydown",this.handleKeyDown_),this.off("click",this.handleClick_),this.off(this.player_,"controlsvisible",this.update_),this.off(r,"mousemove",this.handleMouseMove_),this.off(r,"mouseup",this.handleMouseUp_),this.off(r,"touchmove",this.handleMouseMove_),this.off(r,"touchend",this.handleMouseUp_),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}},i.createEl=function(r,o,a){return o===void 0&&(o={}),a===void 0&&(a={}),o.className=o.className+" vjs-slider",o=Nl({tabIndex:0},o),a=Nl({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},a),t.prototype.createEl.call(this,r,o,a)},i.handleMouseDown=function(r){var o=this.bar.el_.ownerDocument;r.type==="mousedown"&&r.preventDefault(),r.type==="touchstart"&&!HS&&r.preventDefault(),IIe(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(o,"mousemove",this.handleMouseMove_),this.on(o,"mouseup",this.handleMouseUp_),this.on(o,"touchmove",this.handleMouseMove_),this.on(o,"touchend",this.handleMouseUp_),this.handleMouseMove(r,!0)},i.handleMouseMove=function(r){},i.handleMouseUp=function(){var r=this.bar.el_.ownerDocument;NIe(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(r,"mousemove",this.handleMouseMove_),this.off(r,"mouseup",this.handleMouseUp_),this.off(r,"touchmove",this.handleMouseMove_),this.off(r,"touchend",this.handleMouseUp_),this.update()},i.update=function(){var r=this;if(!(!this.el_||!this.bar)){var o=this.getProgress();return o===this.progress_||(this.progress_=o,this.requestNamedAnimationFrame("Slider#update",function(){var a=r.vertical()?"height":"width";r.bar.el().style[a]=(o*100).toFixed(2)+"%"})),o}},i.getProgress=function(){return Number(eW(this.getPercent(),0,1).toFixed(4))},i.calculateDistance=function(r){var o=q6(this.el_,r);return this.vertical()?o.y:o.x},i.handleKeyDown=function(r){On.isEventKey(r,"Left")||On.isEventKey(r,"Down")?(r.preventDefault(),r.stopPropagation(),this.stepBack()):On.isEventKey(r,"Right")||On.isEventKey(r,"Up")?(r.preventDefault(),r.stopPropagation(),this.stepForward()):t.prototype.handleKeyDown.call(this,r)},i.handleClick=function(r){r.stopPropagation(),r.preventDefault()},i.vertical=function(r){if(r===void 0)return this.vertical_||!1;this.vertical_=!!r,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")},e})(Fr);Fr.registerComponent("Slider",Bte);var rq=function(e,i){return eW(e/i*100,0,100).toFixed(2)+"%"},MPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.partEls_=[],o.on(n,"progress",function(a){return o.update(a)}),o}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"}),o=Vo("span",{className:"vjs-control-text"}),a=Vo("span",{textContent:this.localize("Loaded")}),s=$r.createTextNode(": ");return this.percentageEl_=Vo("span",{className:"vjs-control-text-loaded-percentage",textContent:"0%"}),r.appendChild(o),o.appendChild(a),o.appendChild(s),o.appendChild(this.percentageEl_),r},i.dispose=function(){this.partEls_=null,this.percentageEl_=null,t.prototype.dispose.call(this)},i.update=function(r){var o=this;this.requestNamedAnimationFrame("LoadProgressBar#update",function(){var a=o.player_.liveTracker,s=o.player_.buffered(),l=a&&a.isLive()?a.seekableEnd():o.player_.duration(),u=o.player_.bufferedEnd(),c=o.partEls_,d=rq(u,l);o.percent_!==d&&(o.el_.style.width=d,KD(o.percentageEl_,d),o.percent_=d);for(var f=0;f<s.length;f++){var h=s.start(f),p=s.end(f),g=c[f];g||(g=o.el_.appendChild(Vo()),c[f]=g),!(g.dataset.start===h&&g.dataset.end===p)&&(g.dataset.start=h,g.dataset.end=p,g.style.left=rq(h,u),g.style.width=rq(p-h,u))}for(var v=c.length;v>s.length;v--)o.el_.removeChild(c[v-1]);c.length=s.length})},e})(Fr);Fr.registerComponent("LoadProgressBar",MPt);var LPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update=DS(Ms(bn(o),o.update),Bv),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-tooltip"},{"aria-hidden":"true"})},i.update=function(r,o,a){var s=I3(this.el_),l=Kk(this.player_.el()),u=r.width*o;if(!(!l||!s)){var c=r.left-l.left+u,d=r.width-u+(l.right-r.right),f=s.width/2;c<f?f+=f-c:d<f&&(f=d),f<0?f=0:f>s.width&&(f=s.width),f=Math.round(f),this.el_.style.right="-"+f+"px",this.write(a)}},i.write=function(r){KD(this.el_,r)},i.updateTime=function(r,o,a,s){var l=this;this.requestNamedAnimationFrame("TimeTooltip#updateTime",function(){var u,c=l.player_.duration();if(l.player_.liveTracker&&l.player_.liveTracker.isLive()){var d=l.player_.liveTracker.liveWindow(),f=d-o*d;u=(f<1?"":"-")+Qk(f,d)}else u=Qk(a,c);l.update(r,o,u),s&&s()})},e})(Fr);Fr.registerComponent("TimeTooltip",LPt);var jte=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update=DS(Ms(bn(o),o.update),Bv),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"},{"aria-hidden":"true"})},i.update=function(r,o){var a=this.getChild("timeTooltip");if(a){var s=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();a.updateTime(r,o,s)}},e})(Fr);jte.prototype.options_={children:[]};!jf&&!VS&&jte.prototype.options_.children.push("timeTooltip");Fr.registerComponent("PlayProgressBar",jte);var s2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update=DS(Ms(bn(o),o.update),Bv),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},i.update=function(r,o){var a=this,s=o*this.player_.duration();this.getChild("timeTooltip").updateTime(r,o,s,function(){a.el_.style.left=r.width*o+"px"})},e})(Fr);s2e.prototype.options_={children:["timeTooltip"]};Fr.registerComponent("MouseTimeDisplay",s2e);var _4=5,dde=12,Vte=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.setEventHandlers_(),o}var i=e.prototype;return i.setEventHandlers_=function(){var r=this;this.update_=Ms(this,this.update),this.update=DS(this.update_,Bv),this.on(this.player_,["ended","durationchange","timeupdate"],this.update),this.player_.liveTracker&&this.on(this.player_.liveTracker,"liveedgechange",this.update),this.updateInterval=null,this.enableIntervalHandler_=function(o){return r.enableInterval_(o)},this.disableIntervalHandler_=function(o){return r.disableInterval_(o)},this.on(this.player_,["playing"],this.enableIntervalHandler_),this.on(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in $r&&"visibilityState"in $r&&this.on($r,"visibilitychange",this.toggleVisibility_)},i.toggleVisibility_=function(r){$r.visibilityState==="hidden"?(this.cancelNamedAnimationFrame("SeekBar#update"),this.cancelNamedAnimationFrame("Slider#update"),this.disableInterval_(r)):(!this.player_.ended()&&!this.player_.paused()&&this.enableInterval_(),this.update())},i.enableInterval_=function(){this.updateInterval||(this.updateInterval=this.setInterval(this.update,Bv))},i.disableInterval_=function(r){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&r&&r.type!=="ended"||this.updateInterval&&(this.clearInterval(this.updateInterval),this.updateInterval=null)},i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})},i.update=function(r){var o=this;if($r.visibilityState!=="hidden"){var a=t.prototype.update.call(this);return this.requestNamedAnimationFrame("SeekBar#update",function(){var s=o.player_.ended()?o.player_.duration():o.getCurrentTime_(),l=o.player_.liveTracker,u=o.player_.duration();l&&l.isLive()&&(u=o.player_.liveTracker.liveCurrentTime()),o.percent_!==a&&(o.el_.setAttribute("aria-valuenow",(a*100).toFixed(2)),o.percent_=a),(o.currentTime_!==s||o.duration_!==u)&&(o.el_.setAttribute("aria-valuetext",o.localize("progress bar timing: currentTime={1} duration={2}",[Qk(s,u),Qk(u,u)],"{1} of {2}")),o.currentTime_=s,o.duration_=u),o.bar&&o.bar.update(Kk(o.el()),o.getProgress())}),a}},i.userSeek_=function(r){this.player_.liveTracker&&this.player_.liveTracker.isLive()&&this.player_.liveTracker.nextSeekedFromUser(),this.player_.currentTime(r)},i.getCurrentTime_=function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()},i.getPercent=function(){var r=this.getCurrentTime_(),o,a=this.player_.liveTracker;return a&&a.isLive()?(o=(r-a.seekableStart())/a.liveWindow(),a.atLiveEdge()&&(o=1)):o=r/this.player_.duration(),o},i.handleMouseDown=function(r){N3(r)&&(r.stopPropagation(),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),t.prototype.handleMouseDown.call(this,r))},i.handleMouseMove=function(r,o){if(o===void 0&&(o=!1),!!N3(r)){!o&&!this.player_.scrubbing()&&this.player_.scrubbing(!0);var a,s=this.calculateDistance(r),l=this.player_.liveTracker;if(!l||!l.isLive())a=s*this.player_.duration(),a===this.player_.duration()&&(a=a-.1);else{if(s>=.99){l.seekToLiveEdge();return}var u=l.seekableStart(),c=l.liveCurrentTime();if(a=u+s*l.liveWindow(),a>=c&&(a=c),a<=u&&(a=u+.1),a===1/0)return}this.userSeek_(a)}},i.enable=function(){t.prototype.enable.call(this);var r=this.getChild("mouseTimeDisplay");r&&r.show()},i.disable=function(){t.prototype.disable.call(this);var r=this.getChild("mouseTimeDisplay");r&&r.hide()},i.handleMouseUp=function(r){t.prototype.handleMouseUp.call(this,r),r&&r.stopPropagation(),this.player_.scrubbing(!1),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying?Qy(this.player_.play()):this.update_()},i.stepForward=function(){this.userSeek_(this.player_.currentTime()+_4)},i.stepBack=function(){this.userSeek_(this.player_.currentTime()-_4)},i.handleAction=function(r){this.player_.paused()?this.player_.play():this.player_.pause()},i.handleKeyDown=function(r){var o=this.player_.liveTracker;if(On.isEventKey(r,"Space")||On.isEventKey(r,"Enter"))r.preventDefault(),r.stopPropagation(),this.handleAction(r);else if(On.isEventKey(r,"Home"))r.preventDefault(),r.stopPropagation(),this.userSeek_(0);else if(On.isEventKey(r,"End"))r.preventDefault(),r.stopPropagation(),o&&o.isLive()?this.userSeek_(o.liveCurrentTime()):this.userSeek_(this.player_.duration());else if(/^[0-9]$/.test(On(r))){r.preventDefault(),r.stopPropagation();var a=(On.codes[On(r)]-On.codes[0])*10/100;o&&o.isLive()?this.userSeek_(o.seekableStart()+o.liveWindow()*a):this.userSeek_(this.player_.duration()*a)}else On.isEventKey(r,"PgDn")?(r.preventDefault(),r.stopPropagation(),this.userSeek_(this.player_.currentTime()-_4*dde)):On.isEventKey(r,"PgUp")?(r.preventDefault(),r.stopPropagation(),this.userSeek_(this.player_.currentTime()+_4*dde)):t.prototype.handleKeyDown.call(this,r)},i.dispose=function(){this.disableInterval_(),this.off(this.player_,["ended","durationchange","timeupdate"],this.update),this.player_.liveTracker&&this.off(this.player_.liveTracker,"liveedgechange",this.update),this.off(this.player_,["playing"],this.enableIntervalHandler_),this.off(this.player_,["ended","pause","waiting"],this.disableIntervalHandler_),"hidden"in $r&&"visibilityState"in $r&&this.off($r,"visibilitychange",this.toggleVisibility_),t.prototype.dispose.call(this)},e})(Bte);Vte.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"};!jf&&!VS&&Vte.prototype.options_.children.splice(1,0,"mouseTimeDisplay");Fr.registerComponent("SeekBar",Vte);var l2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.handleMouseMove=DS(Ms(bn(o),o.handleMouseMove),Bv),o.throttledHandleMouseSeek=DS(Ms(bn(o),o.handleMouseSeek),Bv),o.handleMouseUpHandler_=function(a){return o.handleMouseUp(a)},o.handleMouseDownHandler_=function(a){return o.handleMouseDown(a)},o.enable(),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i.handleMouseMove=function(r){var o=this.getChild("seekBar");if(o){var a=o.getChild("playProgressBar"),s=o.getChild("mouseTimeDisplay");if(!(!a&&!s)){var l=o.el(),u=I3(l),c=q6(l,r).x;c=eW(c,0,1),s&&s.update(u,c),a&&a.update(u,o.getProgress())}}},i.handleMouseSeek=function(r){var o=this.getChild("seekBar");o&&o.handleMouseMove(r)},i.enabled=function(){return this.enabled_},i.disable=function(){if(this.children().forEach(function(o){return o.disable&&o.disable()}),!!this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDownHandler_),this.off(this.el_,"mousemove",this.handleMouseMove),this.removeListenersAddedOnMousedownAndTouchstart(),this.addClass("disabled"),this.enabled_=!1,this.player_.scrubbing())){var r=this.getChild("seekBar");this.player_.scrubbing(!1),r.videoWasPlaying&&Qy(this.player_.play())}},i.enable=function(){this.children().forEach(function(r){return r.enable&&r.enable()}),!this.enabled()&&(this.on(["mousedown","touchstart"],this.handleMouseDownHandler_),this.on(this.el_,"mousemove",this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)},i.removeListenersAddedOnMousedownAndTouchstart=function(){var r=this.el_.ownerDocument;this.off(r,"mousemove",this.throttledHandleMouseSeek),this.off(r,"touchmove",this.throttledHandleMouseSeek),this.off(r,"mouseup",this.handleMouseUpHandler_),this.off(r,"touchend",this.handleMouseUpHandler_)},i.handleMouseDown=function(r){var o=this.el_.ownerDocument,a=this.getChild("seekBar");a&&a.handleMouseDown(r),this.on(o,"mousemove",this.throttledHandleMouseSeek),this.on(o,"touchmove",this.throttledHandleMouseSeek),this.on(o,"mouseup",this.handleMouseUpHandler_),this.on(o,"touchend",this.handleMouseUpHandler_)},i.handleMouseUp=function(r){var o=this.getChild("seekBar");o&&o.handleMouseUp(r),this.removeListenersAddedOnMousedownAndTouchstart()},e})(Fr);l2e.prototype.options_={children:["seekBar"]};Fr.registerComponent("ProgressControl",l2e);var u2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on(n,["enterpictureinpicture","leavepictureinpicture"],function(a){return o.handlePictureInPictureChange(a)}),o.on(n,["disablepictureinpicturechanged","loadedmetadata"],function(a){return o.handlePictureInPictureEnabledChange(a)}),o.on(n,["loadedmetadata","audioonlymodechange","audiopostermodechange"],function(){var a=n.currentType().substring(0,5)==="audio";a||n.audioPosterMode()||n.audioOnlyMode()?(n.isInPictureInPicture()&&n.exitPictureInPicture(),o.hide()):o.show()}),o.disable(),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-picture-in-picture-control "+t.prototype.buildCSSClass.call(this)},i.handlePictureInPictureEnabledChange=function(){$r.pictureInPictureEnabled&&this.player_.disablePictureInPicture()===!1?this.enable():this.disable()},i.handlePictureInPictureChange=function(r){this.player_.isInPictureInPicture()?this.controlText("Exit Picture-in-Picture"):this.controlText("Picture-in-Picture"),this.handlePictureInPictureEnabledChange()},i.handleClick=function(r){this.player_.isInPictureInPicture()?this.player_.exitPictureInPicture():this.player_.requestPictureInPicture()},e})(kv);u2e.prototype.controlText_="Picture-in-Picture";Fr.registerComponent("PictureInPictureToggle",u2e);var c2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on(n,"fullscreenchange",function(a){return o.handleFullscreenChange(a)}),$r[n.fsApi_.fullscreenEnabled]===!1&&o.disable(),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},i.handleFullscreenChange=function(r){this.player_.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},i.handleClick=function(r){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()},e})(kv);c2e.prototype.controlText_="Fullscreen";Fr.registerComponent("FullscreenToggle",c2e);var kPt=function(e,i){i.tech_&&!i.tech_.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",function(){i.tech_.featuresVolumeControl?e.removeClass("vjs-hidden"):e.addClass("vjs-hidden")})},IPt=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this,"div",{className:"vjs-volume-level"});return r.appendChild(t.prototype.createEl.call(this,"span",{className:"vjs-control-text"})),r},e})(Fr);Fr.registerComponent("VolumeLevel",IPt);var NPt=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update=DS(Ms(bn(o),o.update),Bv),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-tooltip"},{"aria-hidden":"true"})},i.update=function(r,o,a,s){if(!a){var l=Kk(this.el_),u=Kk(this.player_.el()),c=r.width*o;if(!u||!l)return;var d=r.left-u.left+c,f=r.width-c+(u.right-r.right),h=l.width/2;d<h?h+=h-d:f<h&&(h=f),h<0?h=0:h>l.width&&(h=l.width),this.el_.style.right="-"+h+"px"}this.write(s+"%")},i.write=function(r){KD(this.el_,r)},i.updateVolume=function(r,o,a,s,l){var u=this;this.requestNamedAnimationFrame("VolumeLevelTooltip#updateVolume",function(){u.update(r,o,a,s.toFixed(0)),l&&l()})},e})(Fr);Fr.registerComponent("VolumeLevelTooltip",NPt);var d2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.update=DS(Ms(bn(o),o.update),Bv),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},i.update=function(r,o,a){var s=this,l=100*o;this.getChild("volumeLevelTooltip").updateVolume(r,o,a,l,function(){a?s.el_.style.bottom=r.height*o+"px":s.el_.style.left=r.width*o+"px"})},e})(Fr);d2e.prototype.options_={children:["volumeLevelTooltip"]};Fr.registerComponent("MouseVolumeLevelDisplay",d2e);var tW=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on("slideractive",function(a){return o.updateLastVolume_(a)}),o.on(n,"volumechange",function(a){return o.updateARIAAttributes(a)}),n.ready(function(){return o.updateARIAAttributes()}),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})},i.handleMouseDown=function(r){N3(r)&&t.prototype.handleMouseDown.call(this,r)},i.handleMouseMove=function(r){var o=this.getChild("mouseVolumeLevelDisplay");if(o){var a=this.el(),s=Kk(a),l=this.vertical(),u=q6(a,r);u=l?u.y:u.x,u=eW(u,0,1),o.update(s,u,l)}N3(r)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(r)))},i.checkMuted=function(){this.player_.muted()&&this.player_.muted(!1)},i.getPercent=function(){return this.player_.muted()?0:this.player_.volume()},i.stepForward=function(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)},i.stepBack=function(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)},i.updateARIAAttributes=function(r){var o=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",o),this.el_.setAttribute("aria-valuetext",o+"%")},i.volumeAsPercentage_=function(){return Math.round(this.player_.volume()*100)},i.updateLastVolume_=function(){var r=this,o=this.player_.volume();this.one("sliderinactive",function(){r.player_.volume()===0&&r.player_.lastVolume_(o)})},e})(Bte);tW.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"};!jf&&!VS&&tW.prototype.options_.children.splice(0,0,"mouseVolumeLevelDisplay");tW.prototype.playerEvent="volumechange";Fr.registerComponent("VolumeBar",tW);var f2e=(function(t){qr(e,t);function e(n,r){var o;return r===void 0&&(r={}),r.vertical=r.vertical||!1,(typeof r.volumeBar>"u"||L3(r.volumeBar))&&(r.volumeBar=r.volumeBar||{},r.volumeBar.vertical=r.vertical),o=t.call(this,n,r)||this,kPt(bn(o),n),o.throttledHandleMouseMove=DS(Ms(bn(o),o.handleMouseMove),Bv),o.handleMouseUpHandler_=function(a){return o.handleMouseUp(a)},o.on("mousedown",function(a){return o.handleMouseDown(a)}),o.on("touchstart",function(a){return o.handleMouseDown(a)}),o.on("mousemove",function(a){return o.handleMouseMove(a)}),o.on(o.volumeBar,["focus","slideractive"],function(){o.volumeBar.addClass("vjs-slider-active"),o.addClass("vjs-slider-active"),o.trigger("slideractive")}),o.on(o.volumeBar,["blur","sliderinactive"],function(){o.volumeBar.removeClass("vjs-slider-active"),o.removeClass("vjs-slider-active"),o.trigger("sliderinactive")}),o}var i=e.prototype;return i.createEl=function(){var r="vjs-volume-horizontal";return this.options_.vertical&&(r="vjs-volume-vertical"),t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control "+r})},i.handleMouseDown=function(r){var o=this.el_.ownerDocument;this.on(o,"mousemove",this.throttledHandleMouseMove),this.on(o,"touchmove",this.throttledHandleMouseMove),this.on(o,"mouseup",this.handleMouseUpHandler_),this.on(o,"touchend",this.handleMouseUpHandler_)},i.handleMouseUp=function(r){var o=this.el_.ownerDocument;this.off(o,"mousemove",this.throttledHandleMouseMove),this.off(o,"touchmove",this.throttledHandleMouseMove),this.off(o,"mouseup",this.handleMouseUpHandler_),this.off(o,"touchend",this.handleMouseUpHandler_)},i.handleMouseMove=function(r){this.volumeBar.handleMouseMove(r)},e})(Fr);f2e.prototype.options_={children:["volumeBar"]};Fr.registerComponent("VolumeControl",f2e);var FPt=function(e,i){i.tech_&&!i.tech_.featuresMuteControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",function(){i.tech_.featuresMuteControl?e.removeClass("vjs-hidden"):e.addClass("vjs-hidden")})},h2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,FPt(bn(o),n),o.on(n,["loadstart","volumechange"],function(a){return o.update(a)}),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},i.handleClick=function(r){var o=this.player_.volume(),a=this.player_.lastVolume_();if(o===0){var s=a<.1?.1:a;this.player_.volume(s),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())},i.update=function(r){this.updateIcon_(),this.updateControlText_()},i.updateIcon_=function(){var r=this.player_.volume(),o=3;jf&&this.player_.tech_&&this.player_.tech_.el_&&this.player_.muted(this.player_.tech_.el_.muted),r===0||this.player_.muted()?o=0:r<.33?o=1:r<.67&&(o=2);for(var a=0;a<4;a++)jV(this.el_,"vjs-vol-"+a);pS(this.el_,"vjs-vol-"+o)},i.updateControlText_=function(){var r=this.player_.muted()||this.player_.volume()===0,o=r?"Unmute":"Mute";this.controlText()!==o&&this.controlText(o)},e})(kv);h2e.prototype.controlText_="Mute";Fr.registerComponent("MuteToggle",h2e);var p2e=(function(t){qr(e,t);function e(n,r){var o;return r===void 0&&(r={}),typeof r.inline<"u"?r.inline=r.inline:r.inline=!0,(typeof r.volumeControl>"u"||L3(r.volumeControl))&&(r.volumeControl=r.volumeControl||{},r.volumeControl.vertical=!r.inline),o=t.call(this,n,r)||this,o.handleKeyPressHandler_=function(a){return o.handleKeyPress(a)},o.on(n,["loadstart"],function(a){return o.volumePanelState_(a)}),o.on(o.muteToggle,"keyup",function(a){return o.handleKeyPress(a)}),o.on(o.volumeControl,"keyup",function(a){return o.handleVolumeControlKeyUp(a)}),o.on("keydown",function(a){return o.handleKeyPress(a)}),o.on("mouseover",function(a){return o.handleMouseOver(a)}),o.on("mouseout",function(a){return o.handleMouseOut(a)}),o.on(o.volumeControl,["slideractive"],o.sliderActive_),o.on(o.volumeControl,["sliderinactive"],o.sliderInactive_),o}var i=e.prototype;return i.sliderActive_=function(){this.addClass("vjs-slider-active")},i.sliderInactive_=function(){this.removeClass("vjs-slider-active")},i.volumePanelState_=function(){this.volumeControl.hasClass("vjs-hidden")&&this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-hidden"),this.volumeControl.hasClass("vjs-hidden")&&!this.muteToggle.hasClass("vjs-hidden")&&this.addClass("vjs-mute-toggle-only")},i.createEl=function(){var r="vjs-volume-panel-horizontal";return this.options_.inline||(r="vjs-volume-panel-vertical"),t.prototype.createEl.call(this,"div",{className:"vjs-volume-panel vjs-control "+r})},i.dispose=function(){this.handleMouseOut(),t.prototype.dispose.call(this)},i.handleVolumeControlKeyUp=function(r){On.isEventKey(r,"Esc")&&this.muteToggle.focus()},i.handleMouseOver=function(r){this.addClass("vjs-hover"),Op($r,"keyup",this.handleKeyPressHandler_)},i.handleMouseOut=function(r){this.removeClass("vjs-hover"),Ud($r,"keyup",this.handleKeyPressHandler_)},i.handleKeyPress=function(r){On.isEventKey(r,"Esc")&&this.handleMouseOut()},e})(Fr);p2e.prototype.options_={children:["muteToggle","volumeControl"]};Fr.registerComponent("VolumePanel",p2e);var g2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,r&&(o.menuButton_=r.menuButton),o.focusedChild_=-1,o.on("keydown",function(a){return o.handleKeyDown(a)}),o.boundHandleBlur_=function(a){return o.handleBlur(a)},o.boundHandleTapClick_=function(a){return o.handleTapClick(a)},o}var i=e.prototype;return i.addEventListenerForItem=function(r){r instanceof Fr&&(this.on(r,"blur",this.boundHandleBlur_),this.on(r,["tap","click"],this.boundHandleTapClick_))},i.removeEventListenerForItem=function(r){r instanceof Fr&&(this.off(r,"blur",this.boundHandleBlur_),this.off(r,["tap","click"],this.boundHandleTapClick_))},i.removeChild=function(r){typeof r=="string"&&(r=this.getChild(r)),this.removeEventListenerForItem(r),t.prototype.removeChild.call(this,r)},i.addItem=function(r){var o=this.addChild(r);o&&this.addEventListenerForItem(o)},i.createEl=function(){var r=this.options_.contentElType||"ul";this.contentEl_=Vo(r,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");var o=t.prototype.createEl.call(this,"div",{append:this.contentEl_,className:"vjs-menu"});return o.appendChild(this.contentEl_),Op(o,"click",function(a){a.preventDefault(),a.stopImmediatePropagation()}),o},i.dispose=function(){this.contentEl_=null,this.boundHandleBlur_=null,this.boundHandleTapClick_=null,t.prototype.dispose.call(this)},i.handleBlur=function(r){var o=r.relatedTarget||$r.activeElement;if(!this.children().some(function(s){return s.el()===o})){var a=this.menuButton_;a&&a.buttonPressed_&&o!==a.el().firstChild&&a.unpressButton()}},i.handleTapClick=function(r){if(this.menuButton_){this.menuButton_.unpressButton();var o=this.children();if(!Array.isArray(o))return;var a=o.filter(function(s){return s.el()===r.target})[0];if(!a)return;a.name()!=="CaptionSettingsMenuItem"&&this.menuButton_.focus()}},i.handleKeyDown=function(r){On.isEventKey(r,"Left")||On.isEventKey(r,"Down")?(r.preventDefault(),r.stopPropagation(),this.stepForward()):(On.isEventKey(r,"Right")||On.isEventKey(r,"Up"))&&(r.preventDefault(),r.stopPropagation(),this.stepBack())},i.stepForward=function(){var r=0;this.focusedChild_!==void 0&&(r=this.focusedChild_+1),this.focus(r)},i.stepBack=function(){var r=0;this.focusedChild_!==void 0&&(r=this.focusedChild_-1),this.focus(r)},i.focus=function(r){r===void 0&&(r=0);var o=this.children().slice(),a=o.length&&o[0].hasClass("vjs-menu-title");a&&o.shift(),o.length>0&&(r<0?r=0:r>=o.length&&(r=o.length-1),this.focusedChild_=r,o[r].el_.focus())},e})(Fr);Fr.registerComponent("Menu",g2e);var Hte=(function(t){qr(e,t);function e(n,r){var o;r===void 0&&(r={}),o=t.call(this,n,r)||this,o.menuButton_=new kv(n,r),o.menuButton_.controlText(o.controlText_),o.menuButton_.el_.setAttribute("aria-haspopup","true");var a=kv.prototype.buildCSSClass();o.menuButton_.el_.className=o.buildCSSClass()+" "+a,o.menuButton_.removeClass("vjs-control"),o.addChild(o.menuButton_),o.update(),o.enabled_=!0;var s=function(u){return o.handleClick(u)};return o.handleMenuKeyUp_=function(l){return o.handleMenuKeyUp(l)},o.on(o.menuButton_,"tap",s),o.on(o.menuButton_,"click",s),o.on(o.menuButton_,"keydown",function(l){return o.handleKeyDown(l)}),o.on(o.menuButton_,"mouseenter",function(){o.addClass("vjs-hover"),o.menu.show(),Op($r,"keyup",o.handleMenuKeyUp_)}),o.on("mouseleave",function(l){return o.handleMouseLeave(l)}),o.on("keydown",function(l){return o.handleSubmenuKeyDown(l)}),o}var i=e.prototype;return i.update=function(){var r=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=r,this.addChild(r),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?(this.hide(),this.menu.contentEl_.removeAttribute("role")):(this.show(),this.menu.contentEl_.setAttribute("role","menu"))},i.createMenu=function(){var r=new g2e(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var o=Vo("li",{className:"vjs-menu-title",textContent:Ql(this.options_.title),tabIndex:-1}),a=new Fr(this.player_,{el:o});r.addItem(a)}if(this.items=this.createItems(),this.items)for(var s=0;s<this.items.length;s++)r.addItem(this.items[s]);return r},i.createItems=function(){},i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildWrapperCSSClass()},{})},i.buildWrapperCSSClass=function(){var r="vjs-menu-button";this.options_.inline===!0?r+="-inline":r+="-popup";var o=kv.prototype.buildCSSClass();return"vjs-menu-button "+r+" "+o+" "+t.prototype.buildCSSClass.call(this)},i.buildCSSClass=function(){var r="vjs-menu-button";return this.options_.inline===!0?r+="-inline":r+="-popup","vjs-menu-button "+r+" "+t.prototype.buildCSSClass.call(this)},i.controlText=function(r,o){return o===void 0&&(o=this.menuButton_.el()),this.menuButton_.controlText(r,o)},i.dispose=function(){this.handleMouseLeave(),t.prototype.dispose.call(this)},i.handleClick=function(r){this.buttonPressed_?this.unpressButton():this.pressButton()},i.handleMouseLeave=function(r){this.removeClass("vjs-hover"),Ud($r,"keyup",this.handleMenuKeyUp_)},i.focus=function(){this.menuButton_.focus()},i.blur=function(){this.menuButton_.blur()},i.handleKeyDown=function(r){On.isEventKey(r,"Esc")||On.isEventKey(r,"Tab")?(this.buttonPressed_&&this.unpressButton(),On.isEventKey(r,"Tab")||(r.preventDefault(),this.menuButton_.focus())):(On.isEventKey(r,"Up")||On.isEventKey(r,"Down"))&&(this.buttonPressed_||(r.preventDefault(),this.pressButton()))},i.handleMenuKeyUp=function(r){(On.isEventKey(r,"Esc")||On.isEventKey(r,"Tab"))&&this.removeClass("vjs-hover")},i.handleSubmenuKeyPress=function(r){this.handleSubmenuKeyDown(r)},i.handleSubmenuKeyDown=function(r){(On.isEventKey(r,"Esc")||On.isEventKey(r,"Tab"))&&(this.buttonPressed_&&this.unpressButton(),On.isEventKey(r,"Tab")||(r.preventDefault(),this.menuButton_.focus()))},i.pressButton=function(){if(this.enabled_){if(this.buttonPressed_=!0,this.menu.show(),this.menu.lockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","true"),jf&&DIe())return;this.menu.focus()}},i.unpressButton=function(){this.enabled_&&(this.buttonPressed_=!1,this.menu.unlockShowing(),this.menu.hide(),this.menuButton_.el_.setAttribute("aria-expanded","false"))},i.disable=function(){this.unpressButton(),this.enabled_=!1,this.addClass("vjs-disabled"),this.menuButton_.disable()},i.enable=function(){this.enabled_=!0,this.removeClass("vjs-disabled"),this.menuButton_.enable()},e})(Fr);Fr.registerComponent("MenuButton",Hte);var Ute=(function(t){qr(e,t);function e(i,n){var r,o=n.tracks;if(r=t.call(this,i,n)||this,r.items.length<=1&&r.hide(),!o)return bn(r);var a=Ms(bn(r),r.update);return o.addEventListener("removetrack",a),o.addEventListener("addtrack",a),o.addEventListener("labelchange",a),r.player_.on("ready",a),r.player_.on("dispose",function(){o.removeEventListener("removetrack",a),o.removeEventListener("addtrack",a),o.removeEventListener("labelchange",a)}),r}return e})(Hte);Fr.registerComponent("TrackButton",Ute);var BPt=["Tab","Esc","Up","Down","Right","Left"],HV=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.selectable=r.selectable,o.isSelected_=r.selected||!1,o.multiSelectable=r.multiSelectable,o.selected(o.isSelected_),o.selectable?o.multiSelectable?o.el_.setAttribute("role","menuitemcheckbox"):o.el_.setAttribute("role","menuitemradio"):o.el_.setAttribute("role","menuitem"),o}var i=e.prototype;return i.createEl=function(r,o,a){this.nonIconControl=!0;var s=t.prototype.createEl.call(this,"li",Nl({className:"vjs-menu-item",tabIndex:-1},o),a);return s.replaceChild(Vo("span",{className:"vjs-menu-item-text",textContent:this.localize(this.options_.label)}),s.querySelector(".vjs-icon-placeholder")),s},i.handleKeyDown=function(r){BPt.some(function(o){return On.isEventKey(r,o)})||t.prototype.handleKeyDown.call(this,r)},i.handleClick=function(r){this.selected(!0)},i.selected=function(r){this.selectable&&(r?(this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(", selected"),this.isSelected_=!0):(this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText(""),this.isSelected_=!1))},e})(Q6);Fr.registerComponent("MenuItem",HV);var UV=(function(t){qr(e,t);function e(n,r){var o,a=r.track,s=n.textTracks();r.label=a.label||a.language||"Unknown",r.selected=a.mode==="showing",o=t.call(this,n,r)||this,o.track=a,o.kinds=(r.kinds||[r.kind||o.track.kind]).filter(Boolean);var l=function(){for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];o.handleTracksChange.apply(bn(o),h)},u=function(){for(var f=arguments.length,h=new Array(f),p=0;p<f;p++)h[p]=arguments[p];o.handleSelectedLanguageChange.apply(bn(o),h)};if(n.on(["loadstart","texttrackchange"],l),s.addEventListener("change",l),s.addEventListener("selectedlanguagechange",u),o.on("dispose",function(){n.off(["loadstart","texttrackchange"],l),s.removeEventListener("change",l),s.removeEventListener("selectedlanguagechange",u)}),s.onchange===void 0){var c;o.on(["tap","click"],function(){if(typeof Ct.Event!="object")try{c=new Ct.Event("change")}catch{}c||(c=$r.createEvent("Event"),c.initEvent("change",!0,!0)),s.dispatchEvent(c)})}return o.handleTracksChange(),o}var i=e.prototype;return i.handleClick=function(r){var o=this.track,a=this.player_.textTracks();if(t.prototype.handleClick.call(this,r),!!a)for(var s=0;s<a.length;s++){var l=a[s];this.kinds.indexOf(l.kind)!==-1&&(l===o?l.mode!=="showing"&&(l.mode="showing"):l.mode!=="disabled"&&(l.mode="disabled"))}},i.handleTracksChange=function(r){var o=this.track.mode==="showing";o!==this.isSelected_&&this.selected(o)},i.handleSelectedLanguageChange=function(r){if(this.track.mode==="showing"){var o=this.player_.cache_.selectedLanguage;if(o&&o.enabled&&o.language===this.track.language&&o.kind!==this.track.kind)return;this.player_.cache_.selectedLanguage={enabled:!0,language:this.track.language,kind:this.track.kind}}},i.dispose=function(){this.track=null,t.prototype.dispose.call(this)},e})(HV);Fr.registerComponent("TextTrackMenuItem",UV);var v2e=(function(t){qr(e,t);function e(n,r){return r.track={player:n,kind:r.kind,kinds:r.kinds,default:!1,mode:"disabled"},r.kinds||(r.kinds=[r.kind]),r.label?r.track.label=r.label:r.track.label=r.kinds.join(" and ")+" off",r.selectable=!0,r.multiSelectable=!1,t.call(this,n,r)||this}var i=e.prototype;return i.handleTracksChange=function(r){for(var o=this.player().textTracks(),a=!0,s=0,l=o.length;s<l;s++){var u=o[s];if(this.options_.kinds.indexOf(u.kind)>-1&&u.mode==="showing"){a=!1;break}}a!==this.isSelected_&&this.selected(a)},i.handleSelectedLanguageChange=function(r){for(var o=this.player().textTracks(),a=!0,s=0,l=o.length;s<l;s++){var u=o[s];if(["captions","descriptions","subtitles"].indexOf(u.kind)>-1&&u.mode==="showing"){a=!1;break}}a&&(this.player_.cache_.selectedLanguage={enabled:!1})},e})(UV);Fr.registerComponent("OffTextTrackMenuItem",v2e);var xI=(function(t){qr(e,t);function e(n,r){return r===void 0&&(r={}),r.tracks=n.textTracks(),t.call(this,n,r)||this}var i=e.prototype;return i.createItems=function(r,o){r===void 0&&(r=[]),o===void 0&&(o=UV);var a;this.label_&&(a=this.label_+" off"),r.push(new v2e(this.player_,{kinds:this.kinds_,kind:this.kind_,label:a})),this.hideThreshold_+=1;var s=this.player_.textTracks();Array.isArray(this.kinds_)||(this.kinds_=[this.kind_]);for(var l=0;l<s.length;l++){var u=s[l];if(this.kinds_.indexOf(u.kind)>-1){var c=new o(this.player_,{track:u,kinds:this.kinds_,kind:this.kind_,selectable:!0,multiSelectable:!1});c.addClass("vjs-"+u.kind+"-menu-item"),r.push(c)}}return r},e})(Ute);Fr.registerComponent("TextTrackButton",xI);var y2e=(function(t){qr(e,t);function e(n,r){var o,a=r.track,s=r.cue,l=n.currentTime();return r.selectable=!0,r.multiSelectable=!1,r.label=s.text,r.selected=s.startTime<=l&&l<s.endTime,o=t.call(this,n,r)||this,o.track=a,o.cue=s,o}var i=e.prototype;return i.handleClick=function(r){t.prototype.handleClick.call(this),this.player_.currentTime(this.cue.startTime)},e})(HV);Fr.registerComponent("ChaptersTrackMenuItem",y2e);var zte=(function(t){qr(e,t);function e(n,r,o){var a;return a=t.call(this,n,r,o)||this,a.selectCurrentItem_=function(){a.items.forEach(function(s){s.selected(a.track_.activeCues[0]===s.cue)})},a}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildWrapperCSSClass.call(this)},i.update=function(r){if(!(r&&r.track&&r.track.kind!=="chapters")){var o=this.findChaptersTrack();o!==this.track_?(this.setTrack(o),t.prototype.update.call(this)):(!this.items||o&&o.cues&&o.cues.length!==this.items.length)&&t.prototype.update.call(this)}},i.setTrack=function(r){if(this.track_!==r){if(this.updateHandler_||(this.updateHandler_=this.update.bind(this)),this.track_){var o=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);o&&o.removeEventListener("load",this.updateHandler_),this.track_.removeEventListener("cuechange",this.selectCurrentItem_),this.track_=null}if(this.track_=r,this.track_){this.track_.mode="hidden";var a=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);a&&a.addEventListener("load",this.updateHandler_),this.track_.addEventListener("cuechange",this.selectCurrentItem_)}}},i.findChaptersTrack=function(){for(var r=this.player_.textTracks()||[],o=r.length-1;o>=0;o--){var a=r[o];if(a.kind===this.kind_)return a}},i.getMenuCaption=function(){return this.track_&&this.track_.label?this.track_.label:this.localize(Ql(this.kind_))},i.createMenu=function(){return this.options_.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},i.createItems=function(){var r=[];if(!this.track_)return r;var o=this.track_.cues;if(!o)return r;for(var a=0,s=o.length;a<s;a++){var l=o[a],u=new y2e(this.player_,{track:this.track_,cue:l});r.push(u)}return r},e})(xI);zte.prototype.kind_="chapters";zte.prototype.controlText_="Chapters";Fr.registerComponent("ChaptersButton",zte);var $te=(function(t){qr(e,t);function e(n,r,o){var a;a=t.call(this,n,r,o)||this;var s=n.textTracks(),l=Ms(bn(a),a.handleTracksChange);return s.addEventListener("change",l),a.on("dispose",function(){s.removeEventListener("change",l)}),a}var i=e.prototype;return i.handleTracksChange=function(r){for(var o=this.player().textTracks(),a=!1,s=0,l=o.length;s<l;s++){var u=o[s];if(u.kind!==this.kind_&&u.mode==="showing"){a=!0;break}}a?this.disable():this.enable()},i.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildWrapperCSSClass.call(this)},e})(xI);$te.prototype.kind_="descriptions";$te.prototype.controlText_="Descriptions";Fr.registerComponent("DescriptionsButton",$te);var Wte=(function(t){qr(e,t);function e(n,r,o){return t.call(this,n,r,o)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildWrapperCSSClass.call(this)},e})(xI);Wte.prototype.kind_="subtitles";Wte.prototype.controlText_="Subtitles";Fr.registerComponent("SubtitlesButton",Wte);var Gte=(function(t){qr(e,t);function e(n,r){var o;return r.track={player:n,kind:r.kind,label:r.kind+" settings",selectable:!1,default:!1,mode:"disabled"},r.selectable=!1,r.name="CaptionSettingsMenuItem",o=t.call(this,n,r)||this,o.addClass("vjs-texttrack-settings"),o.controlText(", opens "+r.kind+" settings dialog"),o}var i=e.prototype;return i.handleClick=function(r){this.player().getChild("textTrackSettings").open()},e})(UV);Fr.registerComponent("CaptionSettingsMenuItem",Gte);var Yte=(function(t){qr(e,t);function e(n,r,o){return t.call(this,n,r,o)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-captions-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-captions-button "+t.prototype.buildWrapperCSSClass.call(this)},i.createItems=function(){var r=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(r.push(new Gte(this.player_,{kind:this.kind_})),this.hideThreshold_+=1),t.prototype.createItems.call(this,r)},e})(xI);Yte.prototype.kind_="captions";Yte.prototype.controlText_="Captions";Fr.registerComponent("CaptionsButton",Yte);var m2e=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(r,o,a){var s=t.prototype.createEl.call(this,r,o,a),l=s.querySelector(".vjs-menu-item-text");return this.options_.track.kind==="captions"&&(l.appendChild(Vo("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),l.appendChild(Vo("span",{className:"vjs-control-text",textContent:" "+this.localize("Captions")}))),s},e})(UV);Fr.registerComponent("SubsCapsMenuItem",m2e);var qte=(function(t){qr(e,t);function e(n,r){var o;return r===void 0&&(r={}),o=t.call(this,n,r)||this,o.label_="subtitles",["en","en-us","en-ca","fr-ca"].indexOf(o.player_.language_)>-1&&(o.label_="captions"),o.menuButton_.controlText(Ql(o.label_)),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-subs-caps-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-subs-caps-button "+t.prototype.buildWrapperCSSClass.call(this)},i.createItems=function(){var r=[];return!(this.player().tech_&&this.player().tech_.featuresNativeTextTracks)&&this.player().getChild("textTrackSettings")&&(r.push(new Gte(this.player_,{kind:this.label_})),this.hideThreshold_+=1),r=t.prototype.createItems.call(this,r,m2e),r},e})(xI);qte.prototype.kinds_=["captions","subtitles"];qte.prototype.controlText_="Subtitles";Fr.registerComponent("SubsCapsButton",qte);var b2e=(function(t){qr(e,t);function e(n,r){var o,a=r.track,s=n.audioTracks();r.label=a.label||a.language||"Unknown",r.selected=a.enabled,o=t.call(this,n,r)||this,o.track=a,o.addClass("vjs-"+a.kind+"-menu-item");var l=function(){for(var c=arguments.length,d=new Array(c),f=0;f<c;f++)d[f]=arguments[f];o.handleTracksChange.apply(bn(o),d)};return s.addEventListener("change",l),o.on("dispose",function(){s.removeEventListener("change",l)}),o}var i=e.prototype;return i.createEl=function(r,o,a){var s=t.prototype.createEl.call(this,r,o,a),l=s.querySelector(".vjs-menu-item-text");return this.options_.track.kind==="main-desc"&&(l.appendChild(Vo("span",{className:"vjs-icon-placeholder"},{"aria-hidden":!0})),l.appendChild(Vo("span",{className:"vjs-control-text",textContent:" "+this.localize("Descriptions")}))),s},i.handleClick=function(r){if(t.prototype.handleClick.call(this,r),this.track.enabled=!0,this.player_.tech_.featuresNativeAudioTracks)for(var o=this.player_.audioTracks(),a=0;a<o.length;a++){var s=o[a];s!==this.track&&(s.enabled=s===this.track)}},i.handleTracksChange=function(r){this.selected(this.track.enabled)},e})(HV);Fr.registerComponent("AudioTrackMenuItem",b2e);var S2e=(function(t){qr(e,t);function e(n,r){return r===void 0&&(r={}),r.tracks=n.audioTracks(),t.call(this,n,r)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-audio-button "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-audio-button "+t.prototype.buildWrapperCSSClass.call(this)},i.createItems=function(r){r===void 0&&(r=[]),this.hideThreshold_=1;for(var o=this.player_.audioTracks(),a=0;a<o.length;a++){var s=o[a];r.push(new b2e(this.player_,{track:s,selectable:!0,multiSelectable:!1}))}return r},e})(Ute);S2e.prototype.controlText_="Audio Track";Fr.registerComponent("AudioTrackButton",S2e);var Xte=(function(t){qr(e,t);function e(n,r){var o,a=r.rate,s=parseFloat(a,10);return r.label=a,r.selected=s===n.playbackRate(),r.selectable=!0,r.multiSelectable=!1,o=t.call(this,n,r)||this,o.label=a,o.rate=s,o.on(n,"ratechange",function(l){return o.update(l)}),o}var i=e.prototype;return i.handleClick=function(r){t.prototype.handleClick.call(this),this.player().playbackRate(this.rate)},i.update=function(r){this.selected(this.player().playbackRate()===this.rate)},e})(HV);Xte.prototype.contentElType="button";Fr.registerComponent("PlaybackRateMenuItem",Xte);var _2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.menuButton_.el_.setAttribute("aria-describedby",o.labelElId_),o.updateVisibility(),o.updateLabel(),o.on(n,"loadstart",function(a){return o.updateVisibility(a)}),o.on(n,"ratechange",function(a){return o.updateLabel(a)}),o.on(n,"playbackrateschange",function(a){return o.handlePlaybackRateschange(a)}),o}var i=e.prototype;return i.createEl=function(){var r=t.prototype.createEl.call(this);return this.labelElId_="vjs-playback-rate-value-label-"+this.id_,this.labelEl_=Vo("div",{className:"vjs-playback-rate-value",id:this.labelElId_,textContent:"1x"}),r.appendChild(this.labelEl_),r},i.dispose=function(){this.labelEl_=null,t.prototype.dispose.call(this)},i.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},i.buildWrapperCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildWrapperCSSClass.call(this)},i.createItems=function(){for(var r=this.playbackRates(),o=[],a=r.length-1;a>=0;a--)o.push(new Xte(this.player(),{rate:r[a]+"x"}));return o},i.updateARIAAttributes=function(){this.el().setAttribute("aria-valuenow",this.player().playbackRate())},i.handleClick=function(r){var o=this.player().playbackRate(),a=this.playbackRates(),s=a.indexOf(o),l=(s+1)%a.length;this.player().playbackRate(a[l])},i.handlePlaybackRateschange=function(r){this.update()},i.playbackRates=function(){var r=this.player();return r.playbackRates&&r.playbackRates()||[]},i.playbackRateSupported=function(){return this.player().tech_&&this.player().tech_.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},i.updateVisibility=function(r){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},i.updateLabel=function(r){this.playbackRateSupported()&&(this.labelEl_.textContent=this.player().playbackRate()+"x")},e})(Hte);_2e.prototype.controlText_="Playback Rate";Fr.registerComponent("PlaybackRateMenuButton",_2e);var P2e=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},i.createEl=function(r,o,a){return r===void 0&&(r="div"),o===void 0&&(o={}),a===void 0&&(a={}),o.className||(o.className=this.buildCSSClass()),t.prototype.createEl.call(this,r,o,a)},e})(Fr);Fr.registerComponent("Spacer",P2e);var jPt=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-custom-control-spacer "+t.prototype.buildCSSClass.call(this)},i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),textContent:" "})},e})(P2e);Fr.registerComponent("CustomControlSpacer",jPt);var Ez=(function(t){qr(e,t);function e(){return t.apply(this,arguments)||this}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"})},e})(Fr);Ez.prototype.options_={children:["playToggle","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","seekToLive","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","fullscreenToggle"]};"exitPictureInPicture"in $r&&Ez.prototype.options_.children.splice(Ez.prototype.options_.children.length-1,0,"pictureInPictureToggle");Fr.registerComponent("ControlBar",Ez);var C2e=(function(t){qr(e,t);function e(n,r){var o;return o=t.call(this,n,r)||this,o.on(n,"error",function(a){return o.open(a)}),o}var i=e.prototype;return i.buildCSSClass=function(){return"vjs-error-display "+t.prototype.buildCSSClass.call(this)},i.content=function(){var r=this.player().error();return r?this.localize(r.message):""},e})(PI);C2e.prototype.options_=Gn({},PI.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0});Fr.registerComponent("ErrorDisplay",C2e);var iq="vjs-text-track-settings",fde=["#000","Black"],hde=["#00F","Blue"],pde=["#0FF","Cyan"],gde=["#0F0","Green"],vde=["#F0F","Magenta"],yde=["#F00","Red"],mde=["#FFF","White"],bde=["#FF0","Yellow"],nq=["1","Opaque"],oq=["0.5","Semi-Transparent"],Sde=["0","Transparent"],VO={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[fde,mde,yde,gde,hde,bde,vde,pde]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[nq,oq,Sde]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[mde,fde,yde,gde,hde,bde,vde,pde]},edgeStyle:{selector:".vjs-edge-style > select",id:"%s",label:"Text Edge Style",options:[["none","None"],["raised","Raised"],["depressed","Depressed"],["uniform","Uniform"],["dropshadow","Dropshadow"]]},fontFamily:{selector:".vjs-font-family > select",id:"captions-font-family-%s",label:"Font Family",options:[["proportionalSansSerif","Proportional Sans-Serif"],["monospaceSansSerif","Monospace Sans-Serif"],["proportionalSerif","Proportional Serif"],["monospaceSerif","Monospace Serif"],["casual","Casual"],["script","Script"],["small-caps","Small Caps"]]},fontPercent:{selector:".vjs-font-percent > select",id:"captions-font-size-%s",label:"Font Size",options:[["0.50","50%"],["0.75","75%"],["1.00","100%"],["1.25","125%"],["1.50","150%"],["1.75","175%"],["2.00","200%"],["3.00","300%"],["4.00","400%"]],default:2,parser:function(e){return e==="1.00"?null:Number(e)}},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Transparency",options:[nq,oq]},windowColor:{selector:".vjs-window-color > select",id:"captions-window-color-%s",label:"Color"},windowOpacity:{selector:".vjs-window-opacity > select",id:"captions-window-opacity-%s",label:"Transparency",options:[Sde,oq,nq]}};VO.windowColor.options=VO.backgroundColor.options;function T2e(t,e){if(e&&(t=e(t)),t&&t!=="none")return t}function VPt(t,e){var i=t.options[t.options.selectedIndex].value;return T2e(i,e)}function HPt(t,e,i){if(e){for(var n=0;n<t.options.length;n++)if(T2e(t.options[n].value,i)===e){t.selectedIndex=n;break}}}var UPt=(function(t){qr(e,t);function e(n,r){var o;return r.temporary=!1,o=t.call(this,n,r)||this,o.updateDisplay=o.updateDisplay.bind(bn(o)),o.fill(),o.hasBeenOpened_=o.hasBeenFilled_=!0,o.endDialog=Vo("p",{className:"vjs-control-text",textContent:o.localize("End of dialog window.")}),o.el().appendChild(o.endDialog),o.setDefaults(),r.persistTextTrackSettings===void 0&&(o.options_.persistTextTrackSettings=o.options_.playerOptions.persistTextTrackSettings),o.on(o.$(".vjs-done-button"),"click",function(){o.saveSettings(),o.close()}),o.on(o.$(".vjs-default-button"),"click",function(){o.setDefaults(),o.updateDisplay()}),YL(VO,function(a){o.on(o.$(a.selector),"change",o.updateDisplay)}),o.options_.persistTextTrackSettings&&o.restoreSettings(),o}var i=e.prototype;return i.dispose=function(){this.endDialog=null,t.prototype.dispose.call(this)},i.createElSelect_=function(r,o,a){var s=this;o===void 0&&(o=""),a===void 0&&(a="label");var l=VO[r],u=l.id.replace("%s",this.id_),c=[o,u].join(" ").trim();return["<"+a+' id="'+u+'" class="'+(a==="label"?"vjs-label":"")+'">',this.localize(l.label),"</"+a+">",'<select aria-labelledby="'+c+'">'].concat(l.options.map(function(d){var f=u+"-"+d[1].replace(/\W+/g,"");return['<option id="'+f+'" value="'+d[0]+'" ','aria-labelledby="'+c+" "+f+'">',s.localize(d[1]),"</option>"].join("")})).concat("</select>").join("")},i.createElFgColor_=function(){var r="captions-text-legend-"+this.id_;return['<fieldset class="vjs-fg-color vjs-track-setting">','<legend id="'+r+'">',this.localize("Text"),"</legend>",this.createElSelect_("color",r),'<span class="vjs-text-opacity vjs-opacity">',this.createElSelect_("textOpacity",r),"</span>","</fieldset>"].join("")},i.createElBgColor_=function(){var r="captions-background-"+this.id_;return['<fieldset class="vjs-bg-color vjs-track-setting">','<legend id="'+r+'">',this.localize("Background"),"</legend>",this.createElSelect_("backgroundColor",r),'<span class="vjs-bg-opacity vjs-opacity">',this.createElSelect_("backgroundOpacity",r),"</span>","</fieldset>"].join("")},i.createElWinColor_=function(){var r="captions-window-"+this.id_;return['<fieldset class="vjs-window-color vjs-track-setting">','<legend id="'+r+'">',this.localize("Window"),"</legend>",this.createElSelect_("windowColor",r),'<span class="vjs-window-opacity vjs-opacity">',this.createElSelect_("windowOpacity",r),"</span>","</fieldset>"].join("")},i.createElColors_=function(){return Vo("div",{className:"vjs-track-settings-colors",innerHTML:[this.createElFgColor_(),this.createElBgColor_(),this.createElWinColor_()].join("")})},i.createElFont_=function(){return Vo("div",{className:"vjs-track-settings-font",innerHTML:['<fieldset class="vjs-font-percent vjs-track-setting">',this.createElSelect_("fontPercent","","legend"),"</fieldset>",'<fieldset class="vjs-edge-style vjs-track-setting">',this.createElSelect_("edgeStyle","","legend"),"</fieldset>",'<fieldset class="vjs-font-family vjs-track-setting">',this.createElSelect_("fontFamily","","legend"),"</fieldset>"].join("")})},i.createElControls_=function(){var r=this.localize("restore all settings to the default values");return Vo("div",{className:"vjs-track-settings-controls",innerHTML:['<button type="button" class="vjs-default-button" title="'+r+'">',this.localize("Reset"),'<span class="vjs-control-text"> '+r+"</span>","</button>",'<button type="button" class="vjs-done-button">'+this.localize("Done")+"</button>"].join("")})},i.content=function(){return[this.createElColors_(),this.createElFont_(),this.createElControls_()]},i.label=function(){return this.localize("Caption Settings Dialog")},i.description=function(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")},i.buildCSSClass=function(){return t.prototype.buildCSSClass.call(this)+" vjs-text-track-settings"},i.getValues=function(){var r=this;return D_t(VO,function(o,a,s){var l=VPt(r.$(a.selector),a.parser);return l!==void 0&&(o[s]=l),o},{})},i.setValues=function(r){var o=this;YL(VO,function(a,s){HPt(o.$(a.selector),r[s],a.parser)})},i.setDefaults=function(){var r=this;YL(VO,function(o){var a=o.hasOwnProperty("default")?o.default:0;r.$(o.selector).selectedIndex=a})},i.restoreSettings=function(){var r;try{r=JSON.parse(Ct.localStorage.getItem(iq))}catch(o){Jn.warn(o)}r&&this.setValues(r)},i.saveSettings=function(){if(this.options_.persistTextTrackSettings){var r=this.getValues();try{Object.keys(r).length?Ct.localStorage.setItem(iq,JSON.stringify(r)):Ct.localStorage.removeItem(iq)}catch(o){Jn.warn(o)}}},i.updateDisplay=function(){var r=this.player_.getChild("textTrackDisplay");r&&r.updateDisplay()},i.conditionalBlur_=function(){this.previouslyActiveEl_=null;var r=this.player_.controlBar,o=r&&r.subsCapsButton,a=r&&r.captionsButton;o?o.focus():a&&a.focus()},e})(PI);Fr.registerComponent("TextTrackSettings",UPt);var zPt=(function(t){qr(e,t);function e(n,r){var o,a=r.ResizeObserver||Ct.ResizeObserver;r.ResizeObserver===null&&(a=!1);var s=Rs({createEl:!a,reportTouchActivity:!1},r);return o=t.call(this,n,s)||this,o.ResizeObserver=r.ResizeObserver||Ct.ResizeObserver,o.loadListener_=null,o.resizeObserver_=null,o.debouncedHandler_=H_t(function(){o.resizeHandler()},100,!1,bn(o)),a?(o.resizeObserver_=new o.ResizeObserver(o.debouncedHandler_),o.resizeObserver_.observe(n.el())):(o.loadListener_=function(){if(!(!o.el_||!o.el_.contentWindow)){var l=o.debouncedHandler_,u=o.unloadListener_=function(){Ud(this,"resize",l),Ud(this,"unload",u),u=null};Op(o.el_.contentWindow,"unload",u),Op(o.el_.contentWindow,"resize",l)}},o.one("load",o.loadListener_)),o}var i=e.prototype;return i.createEl=function(){return t.prototype.createEl.call(this,"iframe",{className:"vjs-resize-manager",tabIndex:-1,title:this.localize("No content")},{"aria-hidden":"true"})},i.resizeHandler=function(){!this.player_||!this.player_.trigger||this.player_.trigger("playerresize")},i.dispose=function(){this.debouncedHandler_&&this.debouncedHandler_.cancel(),this.resizeObserver_&&(this.player_.el()&&this.resizeObserver_.unobserve(this.player_.el()),this.resizeObserver_.disconnect()),this.loadListener_&&this.off("load",this.loadListener_),this.el_&&this.el_.contentWindow&&this.unloadListener_&&this.unloadListener_.call(this.el_.contentWindow),this.ResizeObserver=null,this.resizeObserver=null,this.debouncedHandler_=null,this.loadListener_=null,t.prototype.dispose.call(this)},e})(Fr);Fr.registerComponent("ResizeManager",zPt);var $Pt={trackingThreshold:20,liveTolerance:15},WPt=(function(t){qr(e,t);function e(n,r){var o,a=Rs($Pt,r,{createEl:!1});return o=t.call(this,n,a)||this,o.handleVisibilityChange_=function(s){return o.handleVisibilityChange(s)},o.trackLiveHandler_=function(){return o.trackLive_()},o.handlePlay_=function(s){return o.handlePlay(s)},o.handleFirstTimeupdate_=function(s){return o.handleFirstTimeupdate(s)},o.handleSeeked_=function(s){return o.handleSeeked(s)},o.seekToLiveEdge_=function(s){return o.seekToLiveEdge(s)},o.reset_(),o.on(o.player_,"durationchange",function(s){return o.handleDurationchange(s)}),o.on(o.player_,"canplay",function(){return o.toggleTracking()}),BV&&"hidden"in $r&&"visibilityState"in $r&&o.on($r,"visibilitychange",o.handleVisibilityChange_),o}var i=e.prototype;return i.handleVisibilityChange=function(){this.player_.duration()===1/0&&($r.hidden?this.stopTracking():this.startTracking())},i.trackLive_=function(){var r=this.player_.seekable();if(!(!r||!r.length)){var o=Number(Ct.performance.now().toFixed(4)),a=this.lastTime_===-1?0:(o-this.lastTime_)/1e3;this.lastTime_=o,this.pastSeekEnd_=this.pastSeekEnd()+a;var s=this.liveCurrentTime(),l=this.player_.currentTime(),u=this.player_.paused()||this.seekedBehindLive_||Math.abs(s-l)>this.options_.liveTolerance;(!this.timeupdateSeen_||s===1/0)&&(u=!1),u!==this.behindLiveEdge_&&(this.behindLiveEdge_=u,this.trigger("liveedgechange"))}},i.handleDurationchange=function(){this.toggleTracking()},i.toggleTracking=function(){this.player_.duration()===1/0&&this.liveWindow()>=this.options_.trackingThreshold?(this.player_.options_.liveui&&this.player_.addClass("vjs-liveui"),this.startTracking()):(this.player_.removeClass("vjs-liveui"),this.stopTracking())},i.startTracking=function(){this.isTracking()||(this.timeupdateSeen_||(this.timeupdateSeen_=this.player_.hasStarted()),this.trackingInterval_=this.setInterval(this.trackLiveHandler_,Bv),this.trackLive_(),this.on(this.player_,["play","pause"],this.trackLiveHandler_),this.timeupdateSeen_?this.on(this.player_,"seeked",this.handleSeeked_):(this.one(this.player_,"play",this.handlePlay_),this.one(this.player_,"timeupdate",this.handleFirstTimeupdate_)))},i.handleFirstTimeupdate=function(){this.timeupdateSeen_=!0,this.on(this.player_,"seeked",this.handleSeeked_)},i.handleSeeked=function(){var r=Math.abs(this.liveCurrentTime()-this.player_.currentTime());this.seekedBehindLive_=this.nextSeekedFromUser_&&r>2,this.nextSeekedFromUser_=!1,this.trackLive_()},i.handlePlay=function(){this.one(this.player_,"timeupdate",this.seekToLiveEdge_)},i.reset_=function(){this.lastTime_=-1,this.pastSeekEnd_=0,this.lastSeekEnd_=-1,this.behindLiveEdge_=!0,this.timeupdateSeen_=!1,this.seekedBehindLive_=!1,this.nextSeekedFromUser_=!1,this.clearInterval(this.trackingInterval_),this.trackingInterval_=null,this.off(this.player_,["play","pause"],this.trackLiveHandler_),this.off(this.player_,"seeked",this.handleSeeked_),this.off(this.player_,"play",this.handlePlay_),this.off(this.player_,"timeupdate",this.handleFirstTimeupdate_),this.off(this.player_,"timeupdate",this.seekToLiveEdge_)},i.nextSeekedFromUser=function(){this.nextSeekedFromUser_=!0},i.stopTracking=function(){this.isTracking()&&(this.reset_(),this.trigger("liveedgechange"))},i.seekableEnd=function(){for(var r=this.player_.seekable(),o=[],a=r?r.length:0;a--;)o.push(r.end(a));return o.length?o.sort()[o.length-1]:1/0},i.seekableStart=function(){for(var r=this.player_.seekable(),o=[],a=r?r.length:0;a--;)o.push(r.start(a));return o.length?o.sort()[0]:0},i.liveWindow=function(){var r=this.liveCurrentTime();return r===1/0?0:r-this.seekableStart()},i.isLive=function(){return this.isTracking()},i.atLiveEdge=function(){return!this.behindLiveEdge()},i.liveCurrentTime=function(){return this.pastSeekEnd()+this.seekableEnd()},i.pastSeekEnd=function(){var r=this.seekableEnd();return this.lastSeekEnd_!==-1&&r!==this.lastSeekEnd_&&(this.pastSeekEnd_=0),this.lastSeekEnd_=r,this.pastSeekEnd_},i.behindLiveEdge=function(){return this.behindLiveEdge_},i.isTracking=function(){return typeof this.trackingInterval_=="number"},i.seekToLiveEdge=function(){this.seekedBehindLive_=!1,!this.atLiveEdge()&&(this.nextSeekedFromUser_=!1,this.player_.currentTime(this.liveCurrentTime()))},i.dispose=function(){this.off($r,"visibilitychange",this.handleVisibilityChange_),this.stopTracking(),t.prototype.dispose.call(this)},e})(Fr);Fr.registerComponent("LiveTracker",WPt);var YZ=function(e){var i=e.el();if(i.hasAttribute("src"))return e.triggerSourceset(i.src),!0;var n=e.$$("source"),r=[],o="";if(!n.length)return!1;for(var a=0;a<n.length;a++){var s=n[a].src;s&&r.indexOf(s)===-1&&r.push(s)}return r.length?(r.length===1&&(o=r[0]),e.triggerSourceset(o),!0):!1},GPt=Object.defineProperty({},"innerHTML",{get:function(){return this.cloneNode(!0).innerHTML},set:function(e){var i=$r.createElement(this.nodeName.toLowerCase());i.innerHTML=e;for(var n=$r.createDocumentFragment();i.childNodes.length;)n.appendChild(i.childNodes[0]);return this.innerText="",Ct.Element.prototype.appendChild.call(this,n),this.innerHTML}}),x2e=function(e,i){for(var n={},r=0;r<e.length&&(n=Object.getOwnPropertyDescriptor(e[r],i),!(n&&n.set&&n.get));r++);return n.enumerable=!0,n.configurable=!0,n},YPt=function(e){return x2e([e.el(),Ct.HTMLMediaElement.prototype,Ct.Element.prototype,GPt],"innerHTML")},_de=function(e){var i=e.el();if(!i.resetSourceWatch_){var n={},r=YPt(e),o=function(s){return function(){for(var l=arguments.length,u=new Array(l),c=0;c<l;c++)u[c]=arguments[c];var d=s.apply(i,u);return YZ(e),d}};["append","appendChild","insertAdjacentHTML"].forEach(function(a){i[a]&&(n[a]=i[a],i[a]=o(n[a]))}),Object.defineProperty(i,"innerHTML",Rs(r,{set:o(r.set)})),i.resetSourceWatch_=function(){i.resetSourceWatch_=null,Object.keys(n).forEach(function(a){i[a]=n[a]}),Object.defineProperty(i,"innerHTML",r)},e.one("sourceset",i.resetSourceWatch_)}},qPt=Object.defineProperty({},"src",{get:function(){return this.hasAttribute("src")?JIe(Ct.Element.prototype.getAttribute.call(this,"src")):""},set:function(e){return Ct.Element.prototype.setAttribute.call(this,"src",e),e}}),XPt=function(e){return x2e([e.el(),Ct.HTMLMediaElement.prototype,qPt],"src")},KPt=function(e){if(e.featuresSourceset){var i=e.el();if(!i.resetSourceset_){var n=XPt(e),r=i.setAttribute,o=i.load;Object.defineProperty(i,"src",Rs(n,{set:function(s){var l=n.set.call(i,s);return e.triggerSourceset(i.src),l}})),i.setAttribute=function(a,s){var l=r.call(i,a,s);return/src/i.test(a)&&e.triggerSourceset(i.src),l},i.load=function(){var a=o.call(i);return YZ(e)||(e.triggerSourceset(""),_de(e)),a},i.currentSrc?e.triggerSourceset(i.currentSrc):YZ(e)||_de(e),i.resetSourceset_=function(){i.resetSourceset_=null,i.load=o,i.setAttribute=r,Object.defineProperty(i,"src",n),i.resetSourceWatch_&&i.resetSourceWatch_()}}}},Kte=function(e,i,n,r){r===void 0&&(r=!0);var o=function(l){return Object.defineProperty(e,i,{value:l,enumerable:!0,writable:!0})},a={configurable:!0,enumerable:!0,get:function(){var l=n();return o(l),l}};return r&&(a.set=o),Object.defineProperty(e,i,a)},ii=(function(t){qr(e,t);function e(n,r){var o;o=t.call(this,n,r)||this;var a=n.source,s=!1;if(o.featuresVideoFrameCallback=o.featuresVideoFrameCallback&&o.el_.tagName==="VIDEO",a&&(o.el_.currentSrc!==a.src||n.tag&&n.tag.initNetworkState_===3)?o.setSource(a):o.handleLateInit_(o.el_),n.enableSourceset&&o.setupSourcesetHandling_(),o.isScrubbing_=!1,o.el_.hasChildNodes()){for(var l=o.el_.childNodes,u=l.length,c=[];u--;){var d=l[u],f=d.nodeName.toLowerCase();f==="track"&&(o.featuresNativeTextTracks?(o.remoteTextTrackEls().addTrackElement_(d),o.remoteTextTracks().addTrack(d.track),o.textTracks().addTrack(d.track),!s&&!o.el_.hasAttribute("crossorigin")&&J6(d.src)&&(s=!0)):c.push(d))}for(var h=0;h<c.length;h++)o.el_.removeChild(c[h])}return o.proxyNativeTracks_(),o.featuresNativeTextTracks&&s&&Jn.warn(`Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.
This may prevent text tracks from loading.`),o.restoreMetadataTracksInIOSNativePlayer_(),(qk||xte||xIe)&&n.nativeControlsForTouch===!0&&o.setControls(!0),o.proxyWebkitFullscreen_(),o.triggerReady(),o}var i=e.prototype;return i.dispose=function(){this.el_&&this.el_.resetSourceset_&&this.el_.resetSourceset_(),e.disposeMediaElement(this.el_),this.options_=null,t.prototype.dispose.call(this)},i.setupSourcesetHandling_=function(){KPt(this)},i.restoreMetadataTracksInIOSNativePlayer_=function(){var r=this.textTracks(),o,a=function(){o=[];for(var u=0;u<r.length;u++){var c=r[u];c.kind==="metadata"&&o.push({track:c,storedMode:c.mode})}};a(),r.addEventListener("change",a),this.on("dispose",function(){return r.removeEventListener("change",a)});var s=function l(){for(var u=0;u<o.length;u++){var c=o[u];c.track.mode==="disabled"&&c.track.mode!==c.storedMode&&(c.track.mode=c.storedMode)}r.removeEventListener("change",l)};this.on("webkitbeginfullscreen",function(){r.removeEventListener("change",a),r.removeEventListener("change",s),r.addEventListener("change",s)}),this.on("webkitendfullscreen",function(){r.removeEventListener("change",a),r.addEventListener("change",a),r.removeEventListener("change",s)})},i.overrideNative_=function(r,o){var a=this;if(o===this["featuresNative"+r+"Tracks"]){var s=r.toLowerCase();this[s+"TracksListeners_"]&&Object.keys(this[s+"TracksListeners_"]).forEach(function(l){var u=a.el()[s+"Tracks"];u.removeEventListener(l,a[s+"TracksListeners_"][l])}),this["featuresNative"+r+"Tracks"]=!o,this[s+"TracksListeners_"]=null,this.proxyNativeTracksForType_(s)}},i.overrideNativeAudioTracks=function(r){this.overrideNative_("Audio",r)},i.overrideNativeVideoTracks=function(r){this.overrideNative_("Video",r)},i.proxyNativeTracksForType_=function(r){var o=this,a=Ag[r],s=this.el()[a.getterName],l=this[a.getterName]();if(!(!this["featuresNative"+a.capitalName+"Tracks"]||!s||!s.addEventListener)){var u={change:function(f){var h={type:"change",target:l,currentTarget:l,srcElement:l};l.trigger(h),r==="text"&&o[Jk.remoteText.getterName]().trigger(h)},addtrack:function(f){l.addTrack(f.track)},removetrack:function(f){l.removeTrack(f.track)}},c=function(){for(var f=[],h=0;h<l.length;h++){for(var p=!1,g=0;g<s.length;g++)if(s[g]===l[h]){p=!0;break}p||f.push(l[h])}for(;f.length;)l.removeTrack(f.shift())};this[a.getterName+"Listeners_"]=u,Object.keys(u).forEach(function(d){var f=u[d];s.addEventListener(d,f),o.on("dispose",function(h){return s.removeEventListener(d,f)})}),this.on("loadstart",c),this.on("dispose",function(d){return o.off("loadstart",c)})}},i.proxyNativeTracks_=function(){var r=this;Ag.names.forEach(function(o){r.proxyNativeTracksForType_(o)})},i.createEl=function(){var r=this.options_.tag;if(!r||!(this.options_.playerElIngest||this.movingMediaElementInDOM)){if(r){var o=r.cloneNode(!0);r.parentNode&&r.parentNode.insertBefore(o,r),e.disposeMediaElement(r),r=o}else{r=$r.createElement("video");var a=this.options_.tag&&Zb(this.options_.tag),s=Rs({},a);(!qk||this.options_.nativeControlsForTouch!==!0)&&delete s.controls,LIe(r,Nl(s,{id:this.options_.techId,class:"vjs-tech"}))}r.playerId=this.options_.playerId}typeof this.options_.preload<"u"&&Xk(r,"preload",this.options_.preload),this.options_.disablePictureInPicture!==void 0&&(r.disablePictureInPicture=this.options_.disablePictureInPicture);for(var l=["loop","muted","playsinline","autoplay"],u=0;u<l.length;u++){var c=l[u],d=this.options_[c];typeof d<"u"&&(d?Xk(r,c,c):Y6(r,c),r[c]=d)}return r},i.handleLateInit_=function(r){if(!(r.networkState===0||r.networkState===3)){if(r.readyState===0){var o=!1,a=function(){o=!0};this.on("loadstart",a);var s=function(){o||this.trigger("loadstart")};this.on("loadedmetadata",s),this.ready(function(){this.off("loadstart",a),this.off("loadedmetadata",s),o||this.trigger("loadstart")});return}var l=["loadstart"];l.push("loadedmetadata"),r.readyState>=2&&l.push("loadeddata"),r.readyState>=3&&l.push("canplay"),r.readyState>=4&&l.push("canplaythrough"),this.ready(function(){l.forEach(function(u){this.trigger(u)},this)})}},i.setScrubbing=function(r){this.isScrubbing_=r},i.scrubbing=function(){return this.isScrubbing_},i.setCurrentTime=function(r){try{this.isScrubbing_&&this.el_.fastSeek&&G6?this.el_.fastSeek(r):this.el_.currentTime=r}catch(o){Jn(o,"Video is not ready. (Video.js)")}},i.duration=function(){var r=this;if(this.el_.duration===1/0&&VS&&HS&&this.el_.currentTime===0){var o=function a(){r.el_.currentTime>0&&(r.el_.duration===1/0&&r.trigger("durationchange"),r.off("timeupdate",a))};return this.on("timeupdate",o),NaN}return this.el_.duration||NaN},i.width=function(){return this.el_.offsetWidth},i.height=function(){return this.el_.offsetHeight},i.proxyWebkitFullscreen_=function(){var r=this;if("webkitDisplayingFullscreen"in this.el_){var o=function(){this.trigger("fullscreenchange",{isFullscreen:!1}),this.el_.controls&&!this.options_.nativeControlsForTouch&&this.controls()&&(this.el_.controls=!1)},a=function(){"webkitPresentationMode"in this.el_&&this.el_.webkitPresentationMode!=="picture-in-picture"&&(this.one("webkitendfullscreen",o),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",a),this.on("dispose",function(){r.off("webkitbeginfullscreen",a),r.off("webkitendfullscreen",o)})}},i.supportsFullScreen=function(){if(typeof this.el_.webkitEnterFullScreen=="function"){var r=Ct.navigator&&Ct.navigator.userAgent||"";if(/Android/.test(r)||!/Chrome|Mac OS X 10.5/.test(r))return!0}return!1},i.enterFullScreen=function(){var r=this.el_;if(r.paused&&r.networkState<=r.HAVE_METADATA)Qy(this.el_.play()),this.setTimeout(function(){r.pause();try{r.webkitEnterFullScreen()}catch(o){this.trigger("fullscreenerror",o)}},0);else try{r.webkitEnterFullScreen()}catch(o){this.trigger("fullscreenerror",o)}},i.exitFullScreen=function(){if(!this.el_.webkitDisplayingFullscreen){this.trigger("fullscreenerror",new Error("The video is not fullscreen"));return}this.el_.webkitExitFullScreen()},i.requestPictureInPicture=function(){return this.el_.requestPictureInPicture()},i.requestVideoFrameCallback=function(r){return this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.requestVideoFrameCallback(r):t.prototype.requestVideoFrameCallback.call(this,r)},i.cancelVideoFrameCallback=function(r){this.featuresVideoFrameCallback&&!this.el_.webkitKeys?this.el_.cancelVideoFrameCallback(r):t.prototype.cancelVideoFrameCallback.call(this,r)},i.src=function(r){if(r===void 0)return this.el_.src;this.setSrc(r)},i.reset=function(){e.resetMediaElement(this.el_)},i.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},i.setControls=function(r){this.el_.controls=!!r},i.addTextTrack=function(r,o,a){return this.featuresNativeTextTracks?this.el_.addTextTrack(r,o,a):t.prototype.addTextTrack.call(this,r,o,a)},i.createRemoteTextTrack=function(r){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,r);var o=$r.createElement("track");return r.kind&&(o.kind=r.kind),r.label&&(o.label=r.label),(r.language||r.srclang)&&(o.srclang=r.language||r.srclang),r.default&&(o.default=r.default),r.id&&(o.id=r.id),r.src&&(o.src=r.src),o},i.addRemoteTextTrack=function(r,o){var a=t.prototype.addRemoteTextTrack.call(this,r,o);return this.featuresNativeTextTracks&&this.el().appendChild(a),a},i.removeRemoteTextTrack=function(r){if(t.prototype.removeRemoteTextTrack.call(this,r),this.featuresNativeTextTracks)for(var o=this.$$("track"),a=o.length;a--;)(r===o[a]||r===o[a].track)&&this.el().removeChild(o[a])},i.getVideoPlaybackQuality=function(){if(typeof this.el().getVideoPlaybackQuality=="function")return this.el().getVideoPlaybackQuality();var r={};return typeof this.el().webkitDroppedFrameCount<"u"&&typeof this.el().webkitDecodedFrameCount<"u"&&(r.droppedVideoFrames=this.el().webkitDroppedFrameCount,r.totalVideoFrames=this.el().webkitDecodedFrameCount),Ct.performance&&typeof Ct.performance.now=="function"?r.creationTime=Ct.performance.now():Ct.performance&&Ct.performance.timing&&typeof Ct.performance.timing.navigationStart=="number"&&(r.creationTime=Ct.Date.now()-Ct.performance.timing.navigationStart),r},e})(Ja);Kte(ii,"TEST_VID",function(){if(bI()){var t=$r.createElement("video"),e=$r.createElement("track");return e.kind="captions",e.srclang="en",e.label="English",t.appendChild(e),t}});ii.isSupported=function(){try{ii.TEST_VID.volume=.5}catch{return!1}return!!(ii.TEST_VID&&ii.TEST_VID.canPlayType)};ii.canPlayType=function(t){return ii.TEST_VID.canPlayType(t)};ii.canPlaySource=function(t,e){return ii.canPlayType(t.type)};ii.canControlVolume=function(){try{var t=ii.TEST_VID.volume;ii.TEST_VID.volume=t/2+.1;var e=t!==ii.TEST_VID.volume;return e&&jf?(Ct.setTimeout(function(){ii&&ii.prototype&&(ii.prototype.featuresVolumeControl=t!==ii.TEST_VID.volume)}),!1):e}catch{return!1}};ii.canMuteVolume=function(){try{var t=ii.TEST_VID.muted;return ii.TEST_VID.muted=!t,ii.TEST_VID.muted?Xk(ii.TEST_VID,"muted","muted"):Y6(ii.TEST_VID,"muted","muted"),t!==ii.TEST_VID.muted}catch{return!1}};ii.canControlPlaybackRate=function(){if(VS&&HS&&wIe<58)return!1;try{var t=ii.TEST_VID.playbackRate;return ii.TEST_VID.playbackRate=t/2+.1,t!==ii.TEST_VID.playbackRate}catch{return!1}};ii.canOverrideAttributes=function(){try{var t=function(){};Object.defineProperty($r.createElement("video"),"src",{get:t,set:t}),Object.defineProperty($r.createElement("audio"),"src",{get:t,set:t}),Object.defineProperty($r.createElement("video"),"innerHTML",{get:t,set:t}),Object.defineProperty($r.createElement("audio"),"innerHTML",{get:t,set:t})}catch{return!1}return!0};ii.supportsNativeTextTracks=function(){return G6||jf&&HS};ii.supportsNativeVideoTracks=function(){return!!(ii.TEST_VID&&ii.TEST_VID.videoTracks)};ii.supportsNativeAudioTracks=function(){return!!(ii.TEST_VID&&ii.TEST_VID.audioTracks)};ii.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"];[["featuresMuteControl","canMuteVolume"],["featuresPlaybackRate","canControlPlaybackRate"],["featuresSourceset","canOverrideAttributes"],["featuresNativeTextTracks","supportsNativeTextTracks"],["featuresNativeVideoTracks","supportsNativeVideoTracks"],["featuresNativeAudioTracks","supportsNativeAudioTracks"]].forEach(function(t){var e=t[0],i=t[1];Kte(ii.prototype,e,function(){return ii[i]()},!0)});ii.prototype.featuresVolumeControl=ii.canControlVolume();ii.prototype.movingMediaElementInDOM=!jf;ii.prototype.featuresFullscreenResize=!0;ii.prototype.featuresProgressEvents=!0;ii.prototype.featuresTimeupdateEvents=!0;ii.prototype.featuresVideoFrameCallback=!!(ii.TEST_VID&&ii.TEST_VID.requestVideoFrameCallback);var wz;ii.patchCanPlayType=function(){Pte>=4&&!EIe&&!HS&&(wz=ii.TEST_VID&&ii.TEST_VID.constructor.prototype.canPlayType,ii.TEST_VID.constructor.prototype.canPlayType=function(t){var e=/^application\/(?:x-|vnd\.apple\.)mpegurl/i;return t&&e.test(t)?"maybe":wz.call(this,t)})};ii.unpatchCanPlayType=function(){var t=ii.TEST_VID.constructor.prototype.canPlayType;return wz&&(ii.TEST_VID.constructor.prototype.canPlayType=wz),t};ii.patchCanPlayType();ii.disposeMediaElement=function(t){if(t){for(t.parentNode&&t.parentNode.removeChild(t);t.hasChildNodes();)t.removeChild(t.firstChild);t.removeAttribute("src"),typeof t.load=="function"&&(function(){try{t.load()}catch{}})()}};ii.resetMediaElement=function(t){if(t){for(var e=t.querySelectorAll("source"),i=e.length;i--;)t.removeChild(e[i]);t.removeAttribute("src"),typeof t.load=="function"&&(function(){try{t.load()}catch{}})()}};["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach(function(t){ii.prototype[t]=function(){return this.el_[t]||this.el_.hasAttribute(t)}});["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(t){ii.prototype["set"+Ql(t)]=function(e){this.el_[t]=e,e?this.el_.setAttribute(t,t):this.el_.removeAttribute(t)}});["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","disablePictureInPicture","played","networkState","readyState","videoWidth","videoHeight","crossOrigin"].forEach(function(t){ii.prototype[t]=function(){return this.el_[t]}});["volume","src","poster","preload","playbackRate","defaultPlaybackRate","disablePictureInPicture","crossOrigin"].forEach(function(t){ii.prototype["set"+Ql(t)]=function(e){this.el_[t]=e}});["pause","load","play"].forEach(function(t){ii.prototype[t]=function(){return this.el_[t]()}});Ja.withSourceHandlers(ii);ii.nativeSourceHandler={};ii.nativeSourceHandler.canPlayType=function(t){try{return ii.TEST_VID.canPlayType(t)}catch{return""}};ii.nativeSourceHandler.canHandleSource=function(t,e){if(t.type)return ii.nativeSourceHandler.canPlayType(t.type);if(t.src){var i=Mte(t.src);return ii.nativeSourceHandler.canPlayType("video/"+i)}return""};ii.nativeSourceHandler.handleSource=function(t,e,i){e.setSrc(t.src)};ii.nativeSourceHandler.dispose=function(){};ii.registerSourceHandler(ii.nativeSourceHandler);Ja.registerTech("Html5",ii);var E2e=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","resize","volumechange","texttrackchange"],aq={canplay:"CanPlay",canplaythrough:"CanPlayThrough",playing:"Playing",seeked:"Seeked"},qZ=["tiny","xsmall","small","medium","large","xlarge","huge"],JU={};qZ.forEach(function(t){var e=t.charAt(0)==="x"?"x-"+t.substring(1):t;JU[t]="vjs-layout-"+e});var ZPt={tiny:210,xsmall:320,small:425,medium:768,large:1440,xlarge:2560,huge:1/0},ku=(function(t){qr(e,t);function e(n,r,o){var a;if(n.id=n.id||r.id||"vjs_video_"+US(),r=Nl(e.getTagSettings(n),r),r.initChildren=!1,r.createEl=!1,r.evented=!1,r.reportTouchActivity=!1,!r.language)if(typeof n.closest=="function"){var s=n.closest("[lang]");s&&s.getAttribute&&(r.language=s.getAttribute("lang"))}else for(var l=n;l&&l.nodeType===1;){if(Zb(l).hasOwnProperty("lang")){r.language=l.getAttribute("lang");break}l=l.parentNode}if(a=t.call(this,null,r,o)||this,a.boundDocumentFullscreenChange_=function(f){return a.documentFullscreenChange_(f)},a.boundFullWindowOnEscKey_=function(f){return a.fullWindowOnEscKey(f)},a.boundUpdateStyleEl_=function(f){return a.updateStyleEl_(f)},a.boundApplyInitTime_=function(f){return a.applyInitTime_(f)},a.boundUpdateCurrentBreakpoint_=function(f){return a.updateCurrentBreakpoint_(f)},a.boundHandleTechClick_=function(f){return a.handleTechClick_(f)},a.boundHandleTechDoubleClick_=function(f){return a.handleTechDoubleClick_(f)},a.boundHandleTechTouchStart_=function(f){return a.handleTechTouchStart_(f)},a.boundHandleTechTouchMove_=function(f){return a.handleTechTouchMove_(f)},a.boundHandleTechTouchEnd_=function(f){return a.handleTechTouchEnd_(f)},a.boundHandleTechTap_=function(f){return a.handleTechTap_(f)},a.isFullscreen_=!1,a.log=PIe(a.id_),a.fsApi_=Pz,a.isPosterFromTech_=!1,a.queuedCallbacks_=[],a.isReady_=!1,a.hasStarted_=!1,a.userActive_=!1,a.debugEnabled_=!1,a.audioOnlyMode_=!1,a.audioPosterMode_=!1,a.audioOnlyCache_={playerHeight:null,hiddenChildren:[]},!a.options_||!a.options_.techOrder||!a.options_.techOrder.length)throw new Error("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(a.tag=n,a.tagAttributes=n&&Zb(n),a.language(a.options_.language),r.languages){var u={};Object.getOwnPropertyNames(r.languages).forEach(function(f){u[f.toLowerCase()]=r.languages[f]}),a.languages_=u}else a.languages_=e.prototype.options_.languages;a.resetCache_(),a.poster_=r.poster||"",a.controls_=!!r.controls,n.controls=!1,n.removeAttribute("controls"),a.changingSrc_=!1,a.playCallbacks_=[],a.playTerminatedQueue_=[],n.hasAttribute("autoplay")?a.autoplay(!0):a.autoplay(a.options_.autoplay),r.plugins&&Object.keys(r.plugins).forEach(function(f){if(typeof a[f]!="function")throw new Error('plugin "'+f+'" does not exist')}),a.scrubbing_=!1,a.el_=a.createEl(),Ote(bn(a),{eventBusKey:"el_"}),a.fsApi_.requestFullscreen&&(Op($r,a.fsApi_.fullscreenchange,a.boundDocumentFullscreenChange_),a.on(a.fsApi_.fullscreenchange,a.boundDocumentFullscreenChange_)),a.fluid_&&a.on(["playerreset","resize"],a.boundUpdateStyleEl_);var c=Rs(a.options_);r.plugins&&Object.keys(r.plugins).forEach(function(f){a[f](r.plugins[f])}),r.debug&&a.debug(!0),a.options_.playerOptions=c,a.middleware_=[],a.playbackRates(r.playbackRates),a.initChildren(),a.isAudio(n.nodeName.toLowerCase()==="audio"),a.controls()?a.addClass("vjs-controls-enabled"):a.addClass("vjs-controls-disabled"),a.el_.setAttribute("role","region"),a.isAudio()?a.el_.setAttribute("aria-label",a.localize("Audio Player")):a.el_.setAttribute("aria-label",a.localize("Video Player")),a.isAudio()&&a.addClass("vjs-audio"),a.flexNotSupported_()&&a.addClass("vjs-no-flex"),qk&&a.addClass("vjs-touch-enabled"),jf||a.addClass("vjs-workinghover"),e.players[a.id_]=bn(a);var d=bIe.split(".")[0];return a.addClass("vjs-v"+d),a.userActive(!0),a.reportUserActivity(),a.one("play",function(f){return a.listenForUserActivity_(f)}),a.on("stageclick",function(f){return a.handleStageClick_(f)}),a.on("keydown",function(f){return a.handleKeyDown(f)}),a.on("languagechange",function(f){return a.handleLanguagechange(f)}),a.breakpoints(a.options_.breakpoints),a.responsive(a.options_.responsive),a.on("ready",function(){a.audioPosterMode(a.options_.audioPosterMode),a.audioOnlyMode(a.options_.audioOnlyMode)}),a}var i=e.prototype;return i.dispose=function(){var r=this;this.trigger("dispose"),this.off("dispose"),Ud($r,this.fsApi_.fullscreenchange,this.boundDocumentFullscreenChange_),Ud($r,"keydown",this.boundFullWindowOnEscKey_),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),e.players[this.id_]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.el_&&this.el_.player&&(this.el_.player=null),this.tech_&&(this.tech_.dispose(),this.isPosterFromTech_=!1,this.poster_=""),this.playerElIngest_&&(this.playerElIngest_=null),this.tag&&(this.tag=null),yPt(this),Df.names.forEach(function(o){var a=Df[o],s=r[a.getterName]();s&&s.off&&s.off()}),t.prototype.dispose.call(this,{restoreEl:this.options_.restoreEl})},i.createEl=function(){var r=this.tag,o,a=this.playerElIngest_=r.parentNode&&r.parentNode.hasAttribute&&r.parentNode.hasAttribute("data-vjs-player"),s=this.tag.tagName.toLowerCase()==="video-js";a?o=this.el_=r.parentNode:s||(o=this.el_=t.prototype.createEl.call(this,"div"));var l=Zb(r);if(s){for(o=this.el_=r,r=this.tag=$r.createElement("video");o.children.length;)r.appendChild(o.firstChild);fD(o,"video-js")||pS(o,"video-js"),o.appendChild(r),a=this.playerElIngest_=o,Object.keys(o).forEach(function(p){try{r[p]=o[p]}catch{}})}if(r.setAttribute("tabindex","-1"),l.tabindex="-1",(BV||HS&&AIe)&&(r.setAttribute("role","application"),l.role="application"),r.removeAttribute("width"),r.removeAttribute("height"),"width"in l&&delete l.width,"height"in l&&delete l.height,Object.getOwnPropertyNames(l).forEach(function(p){s&&p==="class"||o.setAttribute(p,l[p]),s&&r.setAttribute(p,l[p])}),r.playerId=r.id,r.id+="_html5_api",r.className="vjs-tech",r.player=o.player=this,this.addClass("vjs-paused"),Ct.VIDEOJS_NO_DYNAMIC_STYLE!==!0){this.styleEl_=zIe("vjs-styles-dimensions");var u=AP(".vjs-styles-defaults"),c=AP("head");c.insertBefore(this.styleEl_,u?u.nextSibling:c.firstChild)}this.fill_=!1,this.fluid_=!1,this.width(this.options_.width),this.height(this.options_.height),this.fill(this.options_.fill),this.fluid(this.options_.fluid),this.aspectRatio(this.options_.aspectRatio),this.crossOrigin(this.options_.crossOrigin||this.options_.crossorigin);for(var d=r.getElementsByTagName("a"),f=0;f<d.length;f++){var h=d.item(f);pS(h,"vjs-hidden"),h.setAttribute("hidden","hidden")}return r.initNetworkState_=r.networkState,r.parentNode&&!a&&r.parentNode.insertBefore(o,r),VZ(r,o),this.children_.unshift(r),this.el_.setAttribute("lang",this.language_),this.el_.setAttribute("translate","no"),this.el_=o,o},i.crossOrigin=function(r){if(!r)return this.techGet_("crossOrigin");if(r!=="anonymous"&&r!=="use-credentials"){Jn.warn('crossOrigin must be "anonymous" or "use-credentials", given "'+r+'"');return}this.techCall_("setCrossOrigin",r)},i.width=function(r){return this.dimension("width",r)},i.height=function(r){return this.dimension("height",r)},i.dimension=function(r,o){var a=r+"_";if(o===void 0)return this[a]||0;if(o===""||o==="auto"){this[a]=void 0,this.updateStyleEl_();return}var s=parseFloat(o);if(isNaN(s)){Jn.error('Improper value "'+o+'" supplied for for '+r);return}this[a]=s,this.updateStyleEl_()},i.fluid=function(r){var o=this;if(r===void 0)return!!this.fluid_;this.fluid_=!!r,gS(this)&&this.off(["playerreset","resize"],this.boundUpdateStyleEl_),r?(this.addClass("vjs-fluid"),this.fill(!1),U_t(this,function(){o.on(["playerreset","resize"],o.boundUpdateStyleEl_)})):this.removeClass("vjs-fluid"),this.updateStyleEl_()},i.fill=function(r){if(r===void 0)return!!this.fill_;this.fill_=!!r,r?(this.addClass("vjs-fill"),this.fluid(!1)):this.removeClass("vjs-fill")},i.aspectRatio=function(r){if(r===void 0)return this.aspectRatio_;if(!/^\d+\:\d+$/.test(r))throw new Error("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.aspectRatio_=r,this.fluid(!0),this.updateStyleEl_()},i.updateStyleEl_=function(){if(Ct.VIDEOJS_NO_DYNAMIC_STYLE===!0){var r=typeof this.width_=="number"?this.width_:this.options_.width,o=typeof this.height_=="number"?this.height_:this.options_.height,a=this.tech_&&this.tech_.el();a&&(r>=0&&(a.width=r),o>=0&&(a.height=o));return}var s,l,u,c;this.aspectRatio_!==void 0&&this.aspectRatio_!=="auto"?u=this.aspectRatio_:this.videoWidth()>0?u=this.videoWidth()+":"+this.videoHeight():u="16:9";var d=u.split(":"),f=d[1]/d[0];this.width_!==void 0?s=this.width_:this.height_!==void 0?s=this.height_/f:s=this.videoWidth()||300,this.height_!==void 0?l=this.height_:l=s*f,/^[^a-zA-Z]/.test(this.id())?c="dimensions-"+this.id():c=this.id()+"-dimensions",this.addClass(c),$Ie(this.styleEl_,`
      .`+c+` {
        width: `+s+`px;
        height: `+l+`px;
      }

      .`+c+`.vjs-fluid:not(.vjs-audio-only-mode) {
        padding-top: `+f*100+`%;
      }
    `)},i.loadTech_=function(r,o){var a=this;this.tech_&&this.unloadTech_();var s=Ql(r),l=r.charAt(0).toLowerCase()+r.slice(1);s!=="Html5"&&this.tag&&(Ja.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=s,this.isReady_=!1;var u=this.autoplay();(typeof this.autoplay()=="string"||this.autoplay()===!0&&this.options_.normalizeAutoplay)&&(u=!1);var c={source:o,autoplay:u,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+l+"_api",playsinline:this.options_.playsinline,preload:this.options_.preload,loop:this.options_.loop,disablePictureInPicture:this.options_.disablePictureInPicture,muted:this.options_.muted,poster:this.poster(),language:this.language(),playerElIngest:this.playerElIngest_||!1,"vtt.js":this.options_["vtt.js"],canOverridePoster:!!this.options_.techCanOverridePoster,enableSourceset:this.options_.enableSourceset,Promise:this.options_.Promise};Df.names.forEach(function(f){var h=Df[f];c[h.getterName]=a[h.privateName]}),Nl(c,this.options_[s]),Nl(c,this.options_[l]),Nl(c,this.options_[r.toLowerCase()]),this.tag&&(c.tag=this.tag),o&&o.src===this.cache_.src&&this.cache_.currentTime>0&&(c.startTime=this.cache_.currentTime);var d=Ja.getTech(r);if(!d)throw new Error("No Tech named '"+s+"' exists! '"+s+"' should be registered using videojs.registerTech()'");this.tech_=new d(c),this.tech_.ready(Ms(this,this.handleTechReady_),!0),rde.jsonToTextTracks(this.textTracksJson_||[],this.tech_),E2e.forEach(function(f){a.on(a.tech_,f,function(h){return a["handleTech"+Ql(f)+"_"](h)})}),Object.keys(aq).forEach(function(f){a.on(a.tech_,f,function(h){if(a.tech_.playbackRate()===0&&a.tech_.seeking()){a.queuedCallbacks_.push({callback:a["handleTech"+aq[f]+"_"].bind(a),event:h});return}a["handleTech"+aq[f]+"_"](h)})}),this.on(this.tech_,"loadstart",function(f){return a.handleTechLoadStart_(f)}),this.on(this.tech_,"sourceset",function(f){return a.handleTechSourceset_(f)}),this.on(this.tech_,"waiting",function(f){return a.handleTechWaiting_(f)}),this.on(this.tech_,"ended",function(f){return a.handleTechEnded_(f)}),this.on(this.tech_,"seeking",function(f){return a.handleTechSeeking_(f)}),this.on(this.tech_,"play",function(f){return a.handleTechPlay_(f)}),this.on(this.tech_,"firstplay",function(f){return a.handleTechFirstPlay_(f)}),this.on(this.tech_,"pause",function(f){return a.handleTechPause_(f)}),this.on(this.tech_,"durationchange",function(f){return a.handleTechDurationChange_(f)}),this.on(this.tech_,"fullscreenchange",function(f,h){return a.handleTechFullscreenChange_(f,h)}),this.on(this.tech_,"fullscreenerror",function(f,h){return a.handleTechFullscreenError_(f,h)}),this.on(this.tech_,"enterpictureinpicture",function(f){return a.handleTechEnterPictureInPicture_(f)}),this.on(this.tech_,"leavepictureinpicture",function(f){return a.handleTechLeavePictureInPicture_(f)}),this.on(this.tech_,"error",function(f){return a.handleTechError_(f)}),this.on(this.tech_,"posterchange",function(f){return a.handleTechPosterChange_(f)}),this.on(this.tech_,"textdata",function(f){return a.handleTechTextData_(f)}),this.on(this.tech_,"ratechange",function(f){return a.handleTechRateChange_(f)}),this.on(this.tech_,"loadedmetadata",this.boundUpdateStyleEl_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode!==this.el()&&(s!=="Html5"||!this.tag)&&VZ(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)},i.unloadTech_=function(){var r=this;Df.names.forEach(function(o){var a=Df[o];r[a.privateName]=r[a.getterName]()}),this.textTracksJson_=rde.textTracksToJson(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1,this.isPosterFromTech_&&(this.poster_="",this.trigger("posterchange")),this.isPosterFromTech_=!1},i.tech=function(r){return r===void 0&&Jn.warn(`Using the tech directly can be dangerous. I hope you know what you're doing.
See https://github.com/videojs/video.js/issues/2617 for more info.
`),this.tech_},i.addTechControlsListeners_=function(){this.removeTechControlsListeners_(),this.on(this.tech_,"click",this.boundHandleTechClick_),this.on(this.tech_,"dblclick",this.boundHandleTechDoubleClick_),this.on(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.on(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.on(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.on(this.tech_,"tap",this.boundHandleTechTap_)},i.removeTechControlsListeners_=function(){this.off(this.tech_,"tap",this.boundHandleTechTap_),this.off(this.tech_,"touchstart",this.boundHandleTechTouchStart_),this.off(this.tech_,"touchmove",this.boundHandleTechTouchMove_),this.off(this.tech_,"touchend",this.boundHandleTechTouchEnd_),this.off(this.tech_,"click",this.boundHandleTechClick_),this.off(this.tech_,"dblclick",this.boundHandleTechDoubleClick_)},i.handleTechReady_=function(){this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_()},i.handleTechLoadStart_=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.handleTechDurationChange_(),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay")),this.manualAutoplay_(this.autoplay()===!0&&this.options_.normalizeAutoplay?"play":this.autoplay())},i.manualAutoplay_=function(r){var o=this;if(!(!this.tech_||typeof r!="string")){var a=function(){var u=o.muted();o.muted(!0);var c=function(){o.muted(u)};o.playTerminatedQueue_.push(c);var d=o.play();if(Oj(d))return d.catch(function(f){throw c(),new Error("Rejection at manualAutoplay. Restoring muted value. "+(f||""))})},s;if(r==="any"&&!this.muted()?(s=this.play(),Oj(s)&&(s=s.catch(a))):r==="muted"&&!this.muted()?s=a():s=this.play(),!!Oj(s))return s.then(function(){o.trigger({type:"autoplay-success",autoplay:r})}).catch(function(){o.trigger({type:"autoplay-failure",autoplay:r})})}},i.updateSourceCaches_=function(r){r===void 0&&(r="");var o=r,a="";typeof o!="string"&&(o=r.src,a=r.type),this.cache_.source=this.cache_.source||{},this.cache_.sources=this.cache_.sources||[],o&&!a&&(a=SPt(this,o)),this.cache_.source=Rs({},r,{src:o,type:a});for(var s=this.cache_.sources.filter(function(h){return h.src&&h.src===o}),l=[],u=this.$$("source"),c=[],d=0;d<u.length;d++){var f=Zb(u[d]);l.push(f),f.src&&f.src===o&&c.push(f.src)}c.length&&!s.length?this.cache_.sources=l:s.length||(this.cache_.sources=[this.cache_.source]),this.cache_.src=o},i.handleTechSourceset_=function(r){var o=this;if(!this.changingSrc_){var a=function(c){return o.updateSourceCaches_(c)},s=this.currentSource().src,l=r.src;s&&!/^blob:/.test(s)&&/^blob:/.test(l)&&(!this.lastSource_||this.lastSource_.tech!==l&&this.lastSource_.player!==s)&&(a=function(){}),a(l),r.src||this.tech_.any(["sourceset","loadstart"],function(u){if(u.type!=="sourceset"){var c=o.techGet("currentSrc");o.lastSource_.tech=c,o.updateSourceCaches_(c)}})}this.lastSource_={player:this.currentSource().src,tech:r.src},this.trigger({src:r.src,type:"sourceset"})},i.hasStarted=function(r){if(r===void 0)return this.hasStarted_;r!==this.hasStarted_&&(this.hasStarted_=r,this.hasStarted_?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started"))},i.handleTechPlay_=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},i.handleTechRateChange_=function(){this.tech_.playbackRate()>0&&this.cache_.lastPlaybackRate===0&&(this.queuedCallbacks_.forEach(function(r){return r.callback(r.event)}),this.queuedCallbacks_=[]),this.cache_.lastPlaybackRate=this.tech_.playbackRate(),this.trigger("ratechange")},i.handleTechWaiting_=function(){var r=this;this.addClass("vjs-waiting"),this.trigger("waiting");var o=this.currentTime(),a=function s(){o!==r.currentTime()&&(r.removeClass("vjs-waiting"),r.off("timeupdate",s))};this.on("timeupdate",a)},i.handleTechCanPlay_=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},i.handleTechCanPlayThrough_=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},i.handleTechPlaying_=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},i.handleTechSeeking_=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},i.handleTechSeeked_=function(){this.removeClass("vjs-seeking"),this.removeClass("vjs-ended"),this.trigger("seeked")},i.handleTechFirstPlay_=function(){this.options_.starttime&&(Jn.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.options_.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},i.handleTechPause_=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},i.handleTechEnded_=function(){this.addClass("vjs-ended"),this.removeClass("vjs-waiting"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},i.handleTechDurationChange_=function(){this.duration(this.techGet_("duration"))},i.handleTechClick_=function(r){this.controls_&&(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.click===void 0||this.options_.userActions.click!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.click=="function"?this.options_.userActions.click.call(this,r):this.paused()?Qy(this.play()):this.pause())},i.handleTechDoubleClick_=function(r){if(this.controls_){var o=Array.prototype.some.call(this.$$(".vjs-control-bar, .vjs-modal-dialog"),function(a){return a.contains(r.target)});o||(this.options_===void 0||this.options_.userActions===void 0||this.options_.userActions.doubleClick===void 0||this.options_.userActions.doubleClick!==!1)&&(this.options_!==void 0&&this.options_.userActions!==void 0&&typeof this.options_.userActions.doubleClick=="function"?this.options_.userActions.doubleClick.call(this,r):this.isFullscreen()?this.exitFullscreen():this.requestFullscreen())}},i.handleTechTap_=function(){this.userActive(!this.userActive())},i.handleTechTouchStart_=function(){this.userWasActive=this.userActive()},i.handleTechTouchMove_=function(){this.userWasActive&&this.reportUserActivity()},i.handleTechTouchEnd_=function(r){r.cancelable&&r.preventDefault()},i.handleStageClick_=function(){this.reportUserActivity()},i.toggleFullscreenClass_=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},i.documentFullscreenChange_=function(r){var o=r.target.player;if(!(o&&o!==this)){var a=this.el(),s=$r[this.fsApi_.fullscreenElement]===a;!s&&a.matches?s=a.matches(":"+this.fsApi_.fullscreen):!s&&a.msMatchesSelector&&(s=a.msMatchesSelector(":"+this.fsApi_.fullscreen)),this.isFullscreen(s)}},i.handleTechFullscreenChange_=function(r,o){var a=this;o&&(o.nativeIOSFullscreen&&(this.addClass("vjs-ios-native-fs"),this.tech_.one("webkitendfullscreen",function(){a.removeClass("vjs-ios-native-fs")})),this.isFullscreen(o.isFullscreen))},i.handleTechFullscreenError_=function(r,o){this.trigger("fullscreenerror",o)},i.togglePictureInPictureClass_=function(){this.isInPictureInPicture()?this.addClass("vjs-picture-in-picture"):this.removeClass("vjs-picture-in-picture")},i.handleTechEnterPictureInPicture_=function(r){this.isInPictureInPicture(!0)},i.handleTechLeavePictureInPicture_=function(r){this.isInPictureInPicture(!1)},i.handleTechError_=function(){var r=this.tech_.error();this.error(r)},i.handleTechTextData_=function(){var r=null;arguments.length>1&&(r=arguments[1]),this.trigger("textdata",r)},i.getCache=function(){return this.cache_},i.resetCache_=function(){this.cache_={currentTime:0,initTime:0,inactivityTimeout:this.options_.inactivityTimeout,duration:NaN,lastVolume:1,lastPlaybackRate:this.defaultPlaybackRate(),media:null,src:"",source:{},sources:[],playbackRates:[],volume:1}},i.techCall_=function(r,o){this.ready(function(){if(r in gPt)return hPt(this.middleware_,this.tech_,r,o);if(r in lde)return sde(this.middleware_,this.tech_,r,o);try{this.tech_&&this.tech_[r](o)}catch(a){throw Jn(a),a}},!0)},i.techGet_=function(r){if(!(!this.tech_||!this.tech_.isReady_)){if(r in pPt)return fPt(this.middleware_,this.tech_,r);if(r in lde)return sde(this.middleware_,this.tech_,r);try{return this.tech_[r]()}catch(o){throw this.tech_[r]===void 0?(Jn("Video.js: "+r+" method not defined for "+this.techName_+" playback technology.",o),o):o.name==="TypeError"?(Jn("Video.js: "+r+" unavailable on "+this.techName_+" playback technology element.",o),this.tech_.isReady_=!1,o):(Jn(o),o)}}},i.play=function(){var r=this,o=this.options_.Promise||Ct.Promise;return o?new o(function(a){r.play_(a)}):this.play_()},i.play_=function(r){var o=this;r===void 0&&(r=Qy),this.playCallbacks_.push(r);var a=!!(!this.changingSrc_&&(this.src()||this.currentSrc())),s=!!(G6||jf);if(this.waitToPlay_&&(this.off(["ready","loadstart"],this.waitToPlay_),this.waitToPlay_=null),!this.isReady_||!a){this.waitToPlay_=function(c){o.play_()},this.one(["ready","loadstart"],this.waitToPlay_),!a&&s&&this.load();return}var l=this.techGet_("play"),u=s&&this.hasClass("vjs-ended");u&&this.resetProgressBar_(),l===null?this.runPlayTerminatedQueue_():this.runPlayCallbacks_(l)},i.runPlayTerminatedQueue_=function(){var r=this.playTerminatedQueue_.slice(0);this.playTerminatedQueue_=[],r.forEach(function(o){o()})},i.runPlayCallbacks_=function(r){var o=this.playCallbacks_.slice(0);this.playCallbacks_=[],this.playTerminatedQueue_=[],o.forEach(function(a){a(r)})},i.pause=function(){this.techCall_("pause")},i.paused=function(){return this.techGet_("paused")!==!1},i.played=function(){return this.techGet_("played")||hD(0,0)},i.scrubbing=function(r){if(typeof r>"u")return this.scrubbing_;this.scrubbing_=!!r,this.techCall_("setScrubbing",this.scrubbing_),r?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")},i.currentTime=function(r){if(typeof r<"u"){if(r<0&&(r=0),!this.isReady_||this.changingSrc_||!this.tech_||!this.tech_.isReady_){this.cache_.initTime=r,this.off("canplay",this.boundApplyInitTime_),this.one("canplay",this.boundApplyInitTime_);return}this.techCall_("setCurrentTime",r),this.cache_.initTime=0;return}return this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime},i.applyInitTime_=function(){this.currentTime(this.cache_.initTime)},i.duration=function(r){if(r===void 0)return this.cache_.duration!==void 0?this.cache_.duration:NaN;r=parseFloat(r),r<0&&(r=1/0),r!==this.cache_.duration&&(this.cache_.duration=r,r===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),isNaN(r)||this.trigger("durationchange"))},i.remainingTime=function(){return this.duration()-this.currentTime()},i.remainingTimeDisplay=function(){return Math.floor(this.duration())-Math.floor(this.currentTime())},i.buffered=function(){var r=this.techGet_("buffered");return(!r||!r.length)&&(r=hD(0,0)),r},i.bufferedPercent=function(){return KIe(this.buffered(),this.duration())},i.bufferedEnd=function(){var r=this.buffered(),o=this.duration(),a=r.end(r.length-1);return a>o&&(a=o),a},i.volume=function(r){var o;if(r!==void 0){o=Math.max(0,Math.min(1,parseFloat(r))),this.cache_.volume=o,this.techCall_("setVolume",o),o>0&&this.lastVolume_(o);return}return o=parseFloat(this.techGet_("volume")),isNaN(o)?1:o},i.muted=function(r){if(r!==void 0){this.techCall_("setMuted",r);return}return this.techGet_("muted")||!1},i.defaultMuted=function(r){return r!==void 0?this.techCall_("setDefaultMuted",r):this.techGet_("defaultMuted")||!1},i.lastVolume_=function(r){if(r!==void 0&&r!==0){this.cache_.lastVolume=r;return}return this.cache_.lastVolume},i.supportsFullScreen=function(){return this.techGet_("supportsFullScreen")||!1},i.isFullscreen=function(r){if(r!==void 0){var o=this.isFullscreen_;this.isFullscreen_=!!r,this.isFullscreen_!==o&&this.fsApi_.prefixed&&this.trigger("fullscreenchange"),this.toggleFullscreenClass_();return}return this.isFullscreen_},i.requestFullscreen=function(r){var o=this.options_.Promise||Ct.Promise;if(o){var a=this;return new o(function(s,l){function u(){a.off("fullscreenerror",d),a.off("fullscreenchange",c)}function c(){u(),s()}function d(h,p){u(),l(p)}a.one("fullscreenchange",c),a.one("fullscreenerror",d);var f=a.requestFullscreenHelper_(r);f&&(f.then(u,u),f.then(s,l))})}return this.requestFullscreenHelper_()},i.requestFullscreenHelper_=function(r){var o=this,a;if(this.fsApi_.prefixed||(a=this.options_.fullscreen&&this.options_.fullscreen.options||{},r!==void 0&&(a=r)),this.fsApi_.requestFullscreen){var s=this.el_[this.fsApi_.requestFullscreen](a);return s&&s.then(function(){return o.isFullscreen(!0)},function(){return o.isFullscreen(!1)}),s}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("enterFullScreen"):this.enterFullWindow()},i.exitFullscreen=function(){var r=this.options_.Promise||Ct.Promise;if(r){var o=this;return new r(function(a,s){function l(){o.off("fullscreenerror",c),o.off("fullscreenchange",u)}function u(){l(),a()}function c(f,h){l(),s(h)}o.one("fullscreenchange",u),o.one("fullscreenerror",c);var d=o.exitFullscreenHelper_();d&&(d.then(l,l),d.then(a,s))})}return this.exitFullscreenHelper_()},i.exitFullscreenHelper_=function(){var r=this;if(this.fsApi_.requestFullscreen){var o=$r[this.fsApi_.exitFullscreen]();return o&&Qy(o.then(function(){return r.isFullscreen(!1)})),o}else this.tech_.supportsFullScreen()&&!this.options_.preferFullWindow?this.techCall_("exitFullScreen"):this.exitFullWindow()},i.enterFullWindow=function(){this.isFullscreen(!0),this.isFullWindow=!0,this.docOrigOverflow=$r.documentElement.style.overflow,Op($r,"keydown",this.boundFullWindowOnEscKey_),$r.documentElement.style.overflow="hidden",pS($r.body,"vjs-full-window"),this.trigger("enterFullWindow")},i.fullWindowOnEscKey=function(r){On.isEventKey(r,"Esc")&&this.isFullscreen()===!0&&(this.isFullWindow?this.exitFullWindow():this.exitFullscreen())},i.exitFullWindow=function(){this.isFullscreen(!1),this.isFullWindow=!1,Ud($r,"keydown",this.boundFullWindowOnEscKey_),$r.documentElement.style.overflow=this.docOrigOverflow,jV($r.body,"vjs-full-window"),this.trigger("exitFullWindow")},i.disablePictureInPicture=function(r){if(r===void 0)return this.techGet_("disablePictureInPicture");this.techCall_("setDisablePictureInPicture",r),this.options_.disablePictureInPicture=r,this.trigger("disablepictureinpicturechanged")},i.isInPictureInPicture=function(r){if(r!==void 0){this.isInPictureInPicture_=!!r,this.togglePictureInPictureClass_();return}return!!this.isInPictureInPicture_},i.requestPictureInPicture=function(){if("pictureInPictureEnabled"in $r&&this.disablePictureInPicture()===!1)return this.techGet_("requestPictureInPicture")},i.exitPictureInPicture=function(){if("pictureInPictureEnabled"in $r)return $r.exitPictureInPicture()},i.handleKeyDown=function(r){var o=this.options_.userActions;if(!(!o||!o.hotkeys)){var a=function(l){var u=l.tagName.toLowerCase();if(l.isContentEditable)return!0;var c=["button","checkbox","hidden","radio","reset","submit"];if(u==="input")return c.indexOf(l.type)===-1;var d=["textarea"];return d.indexOf(u)!==-1};a(this.el_.ownerDocument.activeElement)||(typeof o.hotkeys=="function"?o.hotkeys.call(this,r):this.handleHotkeys(r))}},i.handleHotkeys=function(r){var o=this.options_.userActions?this.options_.userActions.hotkeys:{},a=o.fullscreenKey,s=a===void 0?function(g){return On.isEventKey(g,"f")}:a,l=o.muteKey,u=l===void 0?function(g){return On.isEventKey(g,"m")}:l,c=o.playPauseKey,d=c===void 0?function(g){return On.isEventKey(g,"k")||On.isEventKey(g,"Space")}:c;if(s.call(this,r)){r.preventDefault(),r.stopPropagation();var f=Fr.getComponent("FullscreenToggle");$r[this.fsApi_.fullscreenEnabled]!==!1&&f.prototype.handleClick.call(this,r)}else if(u.call(this,r)){r.preventDefault(),r.stopPropagation();var h=Fr.getComponent("MuteToggle");h.prototype.handleClick.call(this,r)}else if(d.call(this,r)){r.preventDefault(),r.stopPropagation();var p=Fr.getComponent("PlayToggle");p.prototype.handleClick.call(this,r)}},i.canPlayType=function(r){for(var o,a=0,s=this.options_.techOrder;a<s.length;a++){var l=s[a],u=Ja.getTech(l);if(u||(u=Fr.getComponent(l)),!u){Jn.error('The "'+l+'" tech is undefined. Skipped browser support check for that tech.');continue}if(u.isSupported()&&(o=u.canPlayType(r),o))return o}return""},i.selectSource=function(r){var o=this,a=this.options_.techOrder.map(function(d){return[d,Ja.getTech(d)]}).filter(function(d){var f=d[0],h=d[1];return h?h.isSupported():(Jn.error('The "'+f+'" tech is undefined. Skipped browser support check for that tech.'),!1)}),s=function(f,h,p){var g;return f.some(function(v){return h.some(function(y){if(g=p(v,y),g)return!0})}),g},l,u=function(f){return function(h,p){return f(p,h)}},c=function(f,h){var p=f[0],g=f[1];if(g.canPlaySource(h,o.options_[p.toLowerCase()]))return{source:h,tech:p}};return this.options_.sourceOrder?l=s(r,a,u(c)):l=s(a,r,c),l||!1},i.handleSrc_=function(r,o){var a=this;if(typeof r>"u")return this.cache_.src||"";this.resetRetryOnError_&&this.resetRetryOnError_();var s=_Pt(r);if(!s.length){this.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0);return}if(this.changingSrc_=!0,o||(this.cache_.sources=s),this.updateSourceCaches_(s[0]),cPt(this,s[0],function(c,d){a.middleware_=d,o||(a.cache_.sources=s),a.updateSourceCaches_(c);var f=a.src_(c);if(f){if(s.length>1)return a.handleSrc_(s.slice(1));a.changingSrc_=!1,a.setTimeout(function(){this.error({code:4,message:this.options_.notSupportedMessage})},0),a.triggerReady();return}dPt(d,a.tech_)}),this.options_.retryOnError&&s.length>1){var l=function(){a.error(null),a.handleSrc_(s.slice(1),!0)},u=function(){a.off("error",l)};this.one("error",l),this.one("playing",u),this.resetRetryOnError_=function(){a.off("error",l),a.off("playing",u)}}},i.src=function(r){return this.handleSrc_(r,!1)},i.src_=function(r){var o=this,a=this.selectSource([r]);return a?W_t(a.tech,this.techName_)?(this.ready(function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",r):this.techCall_("src",r.src),this.changingSrc_=!1},!0),!1):(this.changingSrc_=!0,this.loadTech_(a.tech,a.source),this.tech_.ready(function(){o.changingSrc_=!1}),!1):!0},i.load=function(){this.techCall_("load")},i.reset=function(){var r=this,o=this.options_.Promise||Ct.Promise;if(this.paused()||!o)this.doReset_();else{var a=this.play();Qy(a.then(function(){return r.doReset_()}))}},i.doReset_=function(){this.tech_&&this.tech_.clearTracks("text"),this.resetCache_(),this.poster(""),this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset"),this.resetControlBarUI_(),gS(this)&&this.trigger("playerreset")},i.resetControlBarUI_=function(){this.resetProgressBar_(),this.resetPlaybackRate_(),this.resetVolumeBar_()},i.resetProgressBar_=function(){this.currentTime(0);var r=this.controlBar||{},o=r.durationDisplay,a=r.remainingTimeDisplay;o&&o.updateContent(),a&&a.updateContent()},i.resetPlaybackRate_=function(){this.playbackRate(this.defaultPlaybackRate()),this.handleTechRateChange_()},i.resetVolumeBar_=function(){this.volume(1),this.trigger("volumechange")},i.currentSources=function(){var r=this.currentSource(),o=[];return Object.keys(r).length!==0&&o.push(r),this.cache_.sources||o},i.currentSource=function(){return this.cache_.source||{}},i.currentSrc=function(){return this.currentSource()&&this.currentSource().src||""},i.currentType=function(){return this.currentSource()&&this.currentSource().type||""},i.preload=function(r){if(r!==void 0){this.techCall_("setPreload",r),this.options_.preload=r;return}return this.techGet_("preload")},i.autoplay=function(r){if(r===void 0)return this.options_.autoplay||!1;var o;typeof r=="string"&&/(any|play|muted)/.test(r)||r===!0&&this.options_.normalizeAutoplay?(this.options_.autoplay=r,this.manualAutoplay_(typeof r=="string"?r:"play"),o=!1):r?this.options_.autoplay=!0:this.options_.autoplay=!1,o=typeof o>"u"?this.options_.autoplay:o,this.tech_&&this.techCall_("setAutoplay",o)},i.playsinline=function(r){return r!==void 0?(this.techCall_("setPlaysinline",r),this.options_.playsinline=r,this):this.techGet_("playsinline")},i.loop=function(r){if(r!==void 0){this.techCall_("setLoop",r),this.options_.loop=r;return}return this.techGet_("loop")},i.poster=function(r){if(r===void 0)return this.poster_;r||(r=""),r!==this.poster_&&(this.poster_=r,this.techCall_("setPoster",r),this.isPosterFromTech_=!1,this.trigger("posterchange"))},i.handleTechPosterChange_=function(){if((!this.poster_||this.options_.techCanOverridePoster)&&this.tech_&&this.tech_.poster){var r=this.tech_.poster()||"";r!==this.poster_&&(this.poster_=r,this.isPosterFromTech_=!0,this.trigger("posterchange"))}},i.controls=function(r){if(r===void 0)return!!this.controls_;r=!!r,this.controls_!==r&&(this.controls_=r,this.usingNativeControls()&&this.techCall_("setControls",r),this.controls_?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.addTechControlsListeners_()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.removeTechControlsListeners_()))},i.usingNativeControls=function(r){if(r===void 0)return!!this.usingNativeControls_;r=!!r,this.usingNativeControls_!==r&&(this.usingNativeControls_=r,this.usingNativeControls_?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols")))},i.error=function(r){var o=this;if(r===void 0)return this.error_||null;if(wP("beforeerror").forEach(function(s){var l=s(o,r);if(!(OS(l)&&!Array.isArray(l)||typeof l=="string"||typeof l=="number"||l===null)){o.log.error("please return a value that MediaError expects in beforeerror hooks");return}r=l}),this.options_.suppressNotSupportedError&&r&&r.code===4){var a=function(){this.error(r)};this.options_.suppressNotSupportedError=!1,this.any(["click","touchstart"],a),this.one("loadstart",function(){this.off(["click","touchstart"],a)});return}if(r===null){this.error_=r,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close();return}this.error_=new Ff(r),this.addClass("vjs-error"),Jn.error("(CODE:"+this.error_.code+" "+Ff.errorTypes[this.error_.code]+")",this.error_.message,this.error_),this.trigger("error"),wP("error").forEach(function(s){return s(o,o.error_)})},i.reportUserActivity=function(r){this.userActivity_=!0},i.userActive=function(r){if(r===void 0)return this.userActive_;if(r=!!r,r!==this.userActive_){if(this.userActive_=r,this.userActive_){this.userActivity_=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive");return}this.tech_&&this.tech_.one("mousemove",function(o){o.stopPropagation(),o.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}},i.listenForUserActivity_=function(){var r,o,a,s=Ms(this,this.reportUserActivity),l=function(p){(p.screenX!==o||p.screenY!==a)&&(o=p.screenX,a=p.screenY,s())},u=function(){s(),this.clearInterval(r),r=this.setInterval(s,250)},c=function(p){s(),this.clearInterval(r)};this.on("mousedown",u),this.on("mousemove",l),this.on("mouseup",c),this.on("mouseleave",c);var d=this.getChild("controlBar");d&&!jf&&!VS&&(d.on("mouseenter",function(h){this.player().options_.inactivityTimeout!==0&&(this.player().cache_.inactivityTimeout=this.player().options_.inactivityTimeout),this.player().options_.inactivityTimeout=0}),d.on("mouseleave",function(h){this.player().options_.inactivityTimeout=this.player().cache_.inactivityTimeout})),this.on("keydown",s),this.on("keyup",s);var f;this.setInterval(function(){if(this.userActivity_){this.userActivity_=!1,this.userActive(!0),this.clearTimeout(f);var h=this.options_.inactivityTimeout;h<=0||(f=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},h))}},250)},i.playbackRate=function(r){if(r!==void 0){this.techCall_("setPlaybackRate",r);return}return this.tech_&&this.tech_.featuresPlaybackRate?this.cache_.lastPlaybackRate||this.techGet_("playbackRate"):1},i.defaultPlaybackRate=function(r){return r!==void 0?this.techCall_("setDefaultPlaybackRate",r):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1},i.isAudio=function(r){if(r!==void 0){this.isAudio_=!!r;return}return!!this.isAudio_},i.enableAudioOnlyUI_=function(){var r=this;this.addClass("vjs-audio-only-mode");var o=this.children(),a=this.getChild("ControlBar"),s=a&&a.currentHeight();o.forEach(function(l){l!==a&&l.el_&&!l.hasClass("vjs-hidden")&&(l.hide(),r.audioOnlyCache_.hiddenChildren.push(l))}),this.audioOnlyCache_.playerHeight=this.currentHeight(),this.height(s),this.trigger("audioonlymodechange")},i.disableAudioOnlyUI_=function(){this.removeClass("vjs-audio-only-mode"),this.audioOnlyCache_.hiddenChildren.forEach(function(r){return r.show()}),this.height(this.audioOnlyCache_.playerHeight),this.trigger("audioonlymodechange")},i.audioOnlyMode=function(r){var o=this;if(typeof r!="boolean"||r===this.audioOnlyMode_)return this.audioOnlyMode_;this.audioOnlyMode_=r;var a=this.options_.Promise||Ct.Promise;if(a){if(r){var s=[];return this.isInPictureInPicture()&&s.push(this.exitPictureInPicture()),this.isFullscreen()&&s.push(this.exitFullscreen()),this.audioPosterMode()&&s.push(this.audioPosterMode(!1)),a.all(s).then(function(){return o.enableAudioOnlyUI_()})}return a.resolve().then(function(){return o.disableAudioOnlyUI_()})}r?(this.isInPictureInPicture()&&this.exitPictureInPicture(),this.isFullscreen()&&this.exitFullscreen(),this.enableAudioOnlyUI_()):this.disableAudioOnlyUI_()},i.enablePosterModeUI_=function(){var r=this.tech_&&this.tech_;r.hide(),this.addClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")},i.disablePosterModeUI_=function(){var r=this.tech_&&this.tech_;r.show(),this.removeClass("vjs-audio-poster-mode"),this.trigger("audiopostermodechange")},i.audioPosterMode=function(r){var o=this;if(typeof r!="boolean"||r===this.audioPosterMode_)return this.audioPosterMode_;this.audioPosterMode_=r;var a=this.options_.Promise||Ct.Promise;if(a){if(r){if(this.audioOnlyMode()){var s=this.audioOnlyMode(!1);return s.then(function(){o.enablePosterModeUI_()})}return a.resolve().then(function(){o.enablePosterModeUI_()})}return a.resolve().then(function(){o.disablePosterModeUI_()})}if(r){this.audioOnlyMode()&&this.audioOnlyMode(!1),this.enablePosterModeUI_();return}this.disablePosterModeUI_()},i.addTextTrack=function(r,o,a){if(this.tech_)return this.tech_.addTextTrack(r,o,a)},i.addRemoteTextTrack=function(r,o){if(this.tech_)return this.tech_.addRemoteTextTrack(r,o)},i.removeRemoteTextTrack=function(r){r===void 0&&(r={});var o=r,a=o.track;if(a||(a=r),this.tech_)return this.tech_.removeRemoteTextTrack(a)},i.getVideoPlaybackQuality=function(){return this.techGet_("getVideoPlaybackQuality")},i.videoWidth=function(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0},i.videoHeight=function(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0},i.language=function(r){if(r===void 0)return this.language_;this.language_!==String(r).toLowerCase()&&(this.language_=String(r).toLowerCase(),gS(this)&&this.trigger("languagechange"))},i.languages=function(){return Rs(e.prototype.options_.languages,this.languages_)},i.toJSON=function(){var r=Rs(this.options_),o=r.tracks;r.tracks=[];for(var a=0;a<o.length;a++){var s=o[a];s=Rs(s),s.player=void 0,r.tracks[a]=s}return r},i.createModal=function(r,o){var a=this;o=o||{},o.content=r||"";var s=new PI(this,o);return this.addChild(s),s.on("dispose",function(){a.removeChild(s)}),s.open(),s},i.updateCurrentBreakpoint_=function(){if(this.responsive())for(var r=this.currentBreakpoint(),o=this.currentWidth(),a=0;a<qZ.length;a++){var s=qZ[a],l=this.breakpoints_[s];if(o<=l){if(r===s)return;r&&this.removeClass(JU[r]),this.addClass(JU[s]),this.breakpoint_=s;break}}},i.removeCurrentBreakpoint_=function(){var r=this.currentBreakpointClass();this.breakpoint_="",r&&this.removeClass(r)},i.breakpoints=function(r){return r===void 0?Nl(this.breakpoints_):(this.breakpoint_="",this.breakpoints_=Nl({},ZPt,r),this.updateCurrentBreakpoint_(),Nl(this.breakpoints_))},i.responsive=function(r){if(r===void 0)return this.responsive_;r=!!r;var o=this.responsive_;if(r!==o)return this.responsive_=r,r?(this.on("playerresize",this.boundUpdateCurrentBreakpoint_),this.updateCurrentBreakpoint_()):(this.off("playerresize",this.boundUpdateCurrentBreakpoint_),this.removeCurrentBreakpoint_()),r},i.currentBreakpoint=function(){return this.breakpoint_},i.currentBreakpointClass=function(){return JU[this.breakpoint_]||""},i.loadMedia=function(r,o){var a=this;if(!(!r||typeof r!="object")){this.reset(),this.cache_.media=Rs(r);var s=this.cache_.media,l=s.artwork,u=s.poster,c=s.src,d=s.textTracks;!l&&u&&(this.cache_.media.artwork=[{src:u,type:xz(u)}]),c&&this.src(c),u&&this.poster(u),Array.isArray(d)&&d.forEach(function(f){return a.addRemoteTextTrack(f,!1)}),this.ready(o)}},i.getMedia=function(){if(!this.cache_.media){var r=this.poster(),o=this.currentSources(),a=Array.prototype.map.call(this.remoteTextTracks(),function(l){return{kind:l.kind,label:l.label,language:l.language,src:l.src}}),s={src:o,textTracks:a};return r&&(s.poster=r,s.artwork=[{src:s.poster,type:xz(s.poster)}]),s}return Rs(this.cache_.media)},e.getTagSettings=function(r){var o={sources:[],tracks:[]},a=Zb(r),s=a["data-setup"];if(fD(r,"vjs-fill")&&(a.fill=!0),fD(r,"vjs-fluid")&&(a.fluid=!0),s!==null){var l=Dbt(s||"{}"),u=l[0],c=l[1];u&&Jn.error(u),Nl(a,c)}if(Nl(o,a),r.hasChildNodes())for(var d=r.childNodes,f=0,h=d.length;f<h;f++){var p=d[f],g=p.nodeName.toLowerCase();g==="source"?o.sources.push(Zb(p)):g==="track"&&o.tracks.push(Zb(p))}return o},i.flexNotSupported_=function(){var r=$r.createElement("i");return!("flexBasis"in r.style||"webkitFlexBasis"in r.style||"mozFlexBasis"in r.style||"msFlexBasis"in r.style||"msFlexOrder"in r.style)},i.debug=function(r){if(r===void 0)return this.debugEnabled_;r?(this.trigger("debugon"),this.previousLogLevel_=this.log.level,this.log.level("debug"),this.debugEnabled_=!0):(this.trigger("debugoff"),this.log.level(this.previousLogLevel_),this.previousLogLevel_=void 0,this.debugEnabled_=!1)},i.playbackRates=function(r){if(r===void 0)return this.cache_.playbackRates;Array.isArray(r)&&r.every(function(o){return typeof o=="number"})&&(this.cache_.playbackRates=r,this.trigger("playbackrateschange"))},e})(Fr);Df.names.forEach(function(t){var e=Df[t];ku.prototype[e.getterName]=function(){return this.tech_?this.tech_[e.getterName]():(this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName])}});ku.prototype.crossorigin=ku.prototype.crossOrigin;ku.players={};var nN=Ct.navigator;ku.prototype.options_={techOrder:Ja.defaultTechOrder_,html5:{},inactivityTimeout:2e3,playbackRates:[],liveui:!1,children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","liveTracker","controlBar","errorDisplay","textTrackSettings","resizeManager"],language:nN&&(nN.languages&&nN.languages[0]||nN.userLanguage||nN.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",normalizeAutoplay:!1,fullscreen:{options:{navigationUI:"hide"}},breakpoints:{},responsive:!1,audioOnlyMode:!1,audioPosterMode:!1};["ended","seeking","seekable","networkState","readyState"].forEach(function(t){ku.prototype[t]=function(){return this.techGet_(t)}});E2e.forEach(function(t){ku.prototype["handleTech"+Ql(t)+"_"]=function(){return this.trigger(t)}});Fr.registerComponent("Player",ku);var Az="plugin",qL="activePlugins_",AL={},Oz=function(e){return AL.hasOwnProperty(e)},QU=function(e){return Oz(e)?AL[e]:void 0},w2e=function(e,i){e[qL]=e[qL]||{},e[qL][i]=!0},Dz=function(e,i,n){var r=(n?"before":"")+"pluginsetup";e.trigger(r,i),e.trigger(r+":"+i.name,i)},JPt=function(e,i){var n=function(){Dz(this,{name:e,plugin:i,instance:null},!0);var o=i.apply(this,arguments);return w2e(this,e),Dz(this,{name:e,plugin:i,instance:o}),o};return Object.keys(i).forEach(function(r){n[r]=i[r]}),n},Pde=function(e,i){return i.prototype.name=e,function(){Dz(this,{name:e,plugin:i,instance:null},!0);for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];var a=nIe(i,[this].concat(r));return this[e]=function(){return a},Dz(this,a.getEventHash()),a}},pm=(function(){function t(i){if(this.constructor===t)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=i,this.log||(this.log=this.player.log.createLogger(this.name)),Ote(this),delete this.trigger,XIe(this,this.constructor.defaultState),w2e(i,this.name),this.dispose=this.dispose.bind(this),i.on("dispose",this.dispose)}var e=t.prototype;return e.version=function(){return this.constructor.VERSION},e.getEventHash=function(n){return n===void 0&&(n={}),n.name=this.name,n.plugin=this.constructor,n.instance=this,n},e.trigger=function(n,r){return r===void 0&&(r={}),_I(this.eventBusEl_,n,this.getEventHash(r))},e.handleStateChanged=function(n){},e.dispose=function(){var n=this.name,r=this.player;this.trigger("dispose"),this.off(),r.off("dispose",this.dispose),r[qL][n]=!1,this.player=this.state=null,r[n]=Pde(n,AL[n])},t.isBasic=function(n){var r=typeof n=="string"?QU(n):n;return typeof r=="function"&&!t.prototype.isPrototypeOf(r.prototype)},t.registerPlugin=function(n,r){if(typeof n!="string")throw new Error('Illegal plugin name, "'+n+'", must be a string, was '+typeof n+".");if(Oz(n))Jn.warn('A plugin named "'+n+'" already exists. You may want to avoid re-registering plugins!');else if(ku.prototype.hasOwnProperty(n))throw new Error('Illegal plugin name, "'+n+'", cannot share a name with an existing player method!');if(typeof r!="function")throw new Error('Illegal plugin for "'+n+'", must be a function, was '+typeof r+".");return AL[n]=r,n!==Az&&(t.isBasic(r)?ku.prototype[n]=JPt(n,r):ku.prototype[n]=Pde(n,r)),r},t.deregisterPlugin=function(n){if(n===Az)throw new Error("Cannot de-register base plugin.");Oz(n)&&(delete AL[n],delete ku.prototype[n])},t.getPlugins=function(n){n===void 0&&(n=Object.keys(AL));var r;return n.forEach(function(o){var a=QU(o);a&&(r=r||{},r[o]=a)}),r},t.getPluginVersion=function(n){var r=QU(n);return r&&r.VERSION||""},t})();pm.getPlugin=QU;pm.BASE_PLUGIN_NAME=Az;pm.registerPlugin(Az,pm);ku.prototype.usingPlugin=function(t){return!!this[qL]&&this[qL][t]===!0};ku.prototype.hasPlugin=function(t){return!!Oz(t)};var Cde=!1,QPt=function(e,i){i===void 0&&(i={}),Cde||(Jn.warn("videojs.extend is deprecated as of Video.js 7.22.0 and will be removed in Video.js 8.0.0"),Cde=!0);var n=function(){e.apply(this,arguments)},r={};typeof i=="object"?(i.constructor!==Object.prototype.constructor&&(n=i.constructor),r=i):typeof i=="function"&&(n=i),Vbt(n,e),e&&(n.super_=e);for(var o in r)r.hasOwnProperty(o)&&(n.prototype[o]=r[o]);return n},A2e=function(e){return e.indexOf("#")===0?e.slice(1):e};function Vt(t,e,i){var n=Vt.getPlayer(t);if(n)return e&&Jn.warn('Player "'+t+'" is already initialised. Options will not be applied.'),i&&n.ready(i),n;var r=typeof t=="string"?AP("#"+A2e(t)):t;if(!SI(r))throw new TypeError("The element or ID supplied is not valid. (videojs)");(!r.ownerDocument.defaultView||!r.ownerDocument.body.contains(r))&&Jn.warn("The element supplied is not included in the DOM"),e=e||{},e.restoreEl===!0&&(e.restoreEl=(r.parentNode&&r.parentNode.hasAttribute("data-vjs-player")?r.parentNode:r).cloneNode(!0)),wP("beforesetup").forEach(function(a){var s=a(r,Rs(e));if(!OS(s)||Array.isArray(s)){Jn.error("please return an object in beforesetup hooks");return}e=Rs(e,s)});var o=Fr.getComponent("Player");return n=new o(r,e,i),wP("setup").forEach(function(a){return a(n)}),n}Vt.hooks_=aS;Vt.hooks=wP;Vt.hook=E_t;Vt.hookOnce=w_t;Vt.removeHook=SIe;if(Ct.VIDEOJS_NO_DYNAMIC_STYLE!==!0&&bI()){var P4=AP(".vjs-styles-defaults");if(!P4){P4=zIe("vjs-styles-defaults");var sq=AP("head");sq&&sq.insertBefore(P4,sq.firstChild),$Ie(P4,`
      .video-js {
        width: 300px;
        height: 150px;
      }

      .vjs-fluid:not(.vjs-audio-only-mode) {
        padding-top: 56.25%
      }
    `)}}UZ(1,Vt);Vt.VERSION=bIe;Vt.options=ku.prototype.options_;Vt.getPlayers=function(){return ku.players};Vt.getPlayer=function(t){var e=ku.players,i;if(typeof t=="string"){var n=A2e(t),r=e[n];if(r)return r;i=AP("#"+n)}else i=t;if(SI(i)){var o=i,a=o.player,s=o.playerId;if(a||e[s])return a||e[s]}};Vt.getAllPlayers=function(){return Object.keys(ku.players).map(function(t){return ku.players[t]}).filter(Boolean)};Vt.players=ku.players;Vt.getComponent=Fr.getComponent;Vt.registerComponent=function(t,e){Ja.isTech(e)&&Jn.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),Fr.registerComponent.call(Fr,t,e)};Vt.getTech=Ja.getTech;Vt.registerTech=Ja.registerTech;Vt.use=uPt;Object.defineProperty(Vt,"middleware",{value:{},writeable:!1,enumerable:!0});Object.defineProperty(Vt.middleware,"TERMINATOR",{value:Tz,writeable:!1,enumerable:!0});Vt.browser=L_t;Vt.TOUCH_ENABLED=qk;Vt.extend=QPt;Vt.mergeOptions=Rs;Vt.bind=Ms;Vt.registerPlugin=pm.registerPlugin;Vt.deregisterPlugin=pm.deregisterPlugin;Vt.plugin=function(t,e){return Jn.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),pm.registerPlugin(t,e)};Vt.getPlugins=pm.getPlugins;Vt.getPlugin=pm.getPlugin;Vt.getPluginVersion=pm.getPluginVersion;Vt.addLanguage=function(t,e){var i;return t=(""+t).toLowerCase(),Vt.options.languages=Rs(Vt.options.languages,(i={},i[t]=e,i)),Vt.options.languages[t]};Vt.log=Jn;Vt.createLogger=PIe;Vt.createTimeRange=Vt.createTimeRanges=hD;Vt.formatTime=Qk;Vt.setFormatTime=APt;Vt.resetFormatTime=OPt;Vt.parseUrl=Rte;Vt.isCrossOrigin=J6;Vt.EventTarget=Ec;Vt.on=Op;Vt.one=K6;Vt.off=Ud;Vt.trigger=_I;Vt.xhr=rIe;Vt.TextTrack=VV;Vt.AudioTrack=QIe;Vt.VideoTrack=e2e;["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(function(t){Vt[t]=function(){return Jn.warn("videojs."+t+"() is deprecated; use videojs.dom."+t+"() instead"),HIe[t].apply(null,arguments)}});Vt.computedStyle=k3;Vt.dom=HIe;Vt.url=oPt;Vt.defineLazyProperty=Kte;Vt.addLanguage("en",{"Non-Fullscreen":"Exit Fullscreen"});/*! @name @videojs/http-streaming @version 2.16.3 @license Apache-2.0 */var Sv=H6,Rz=function(e,i,n){return e&&n&&n.responseURL&&i!==n.responseURL?n.responseURL:i},zv=function(e){return Vt.log.debug?Vt.log.debug.bind(Vt,"VHS:",e+" >"):function(){}},OP=1/30,em=OP*3,O2e=function(e,i){var n=[],r;if(e&&e.length)for(r=0;r<e.length;r++)i(e.start(r),e.end(r))&&n.push([e.start(r),e.end(r)]);return Vt.createTimeRanges(n)},OL=function(e,i){return O2e(e,function(n,r){return n-em<=i&&r+em>=i})},C4=function(e,i){return O2e(e,function(n){return n-OP>=i})},eCt=function(e){if(e.length<2)return Vt.createTimeRanges();for(var i=[],n=1;n<e.length;n++){var r=e.end(n-1),o=e.start(n);i.push([r,o])}return Vt.createTimeRanges(i)},tCt=function(e,i){var n=null,r=null,o=0,a=[],s=[];if(!e||!e.length||!i||!i.length)return Vt.createTimeRange();for(var l=e.length;l--;)a.push({time:e.start(l),type:"start"}),a.push({time:e.end(l),type:"end"});for(l=i.length;l--;)a.push({time:i.start(l),type:"start"}),a.push({time:i.end(l),type:"end"});for(a.sort(function(u,c){return u.time-c.time}),l=0;l<a.length;l++)a[l].type==="start"?(o++,o===2&&(n=a[l].time)):a[l].type==="end"&&(o--,o===1&&(r=a[l].time)),n!==null&&r!==null&&(s.push([n,r]),n=null,r=null);return Vt.createTimeRanges(s)},D2e=function(e){var i=[];if(!e||!e.length)return"";for(var n=0;n<e.length;n++)i.push(e.start(n)+" => "+e.end(n));return i.join(", ")},rCt=function(e,i,n){n===void 0&&(n=1);var r=e.length?e.end(e.length-1):0;return(r-i)/n},WO=function(e){for(var i=[],n=0;n<e.length;n++)i.push({start:e.start(n),end:e.end(n)});return i},iCt=function(e,i){if(e===i)return!1;if(!e&&i||!i&&e||e.length!==i.length)return!0;for(var n=0;n<e.length;n++)if(e.start(n)!==i.start(n)||e.end(n)!==i.end(n))return!0;return!1},Tde=function(e){if(!(!e||!e.length||!e.end))return e.end(e.length-1)},Zte=function(e,i){var n=0;if(!e||!e.length)return n;for(var r=0;r<e.length;r++){var o=e.start(r),a=e.end(r);if(!(i>a)){if(i>o&&i<=a){n+=a-i;continue}n+=a-o}}return n},xde=Vt.createTimeRange,Jte=function(e,i){if(!i.preload)return i.duration;var n=0;return(i.parts||[]).forEach(function(r){n+=r.duration}),(i.preloadHints||[]).forEach(function(r){r.type==="PART"&&(n+=e.partTargetDuration)}),n},XZ=function(e){return(e.segments||[]).reduce(function(i,n,r){return n.parts?n.parts.forEach(function(o,a){i.push({duration:o.duration,segmentIndex:r,partIndex:a,part:o,segment:n})}):i.push({duration:n.duration,segmentIndex:r,partIndex:null,segment:n,part:null}),i},[])},R2e=function(e){var i=e.segments&&e.segments.length&&e.segments[e.segments.length-1];return i&&i.parts||[]},M2e=function(e){var i=e.preloadSegment;if(i){var n=i.parts,r=i.preloadHints,o=(r||[]).reduce(function(a,s){return a+(s.type==="PART"?1:0)},0);return o+=n&&n.length?n.length:0,o}},L2e=function(e,i){if(i.endList)return 0;if(e&&e.suggestedPresentationDelay)return e.suggestedPresentationDelay;var n=R2e(i).length>0;return n&&i.serverControl&&i.serverControl.partHoldBack?i.serverControl.partHoldBack:n&&i.partTargetDuration?i.partTargetDuration*3:i.serverControl&&i.serverControl.holdBack?i.serverControl.holdBack:i.targetDuration?i.targetDuration*3:0},nCt=function(e,i){var n=0,r=i-e.mediaSequence,o=e.segments[r];if(o){if(typeof o.start<"u")return{result:o.start,precise:!0};if(typeof o.end<"u")return{result:o.end-o.duration,precise:!0}}for(;r--;){if(o=e.segments[r],typeof o.end<"u")return{result:n+o.end,precise:!0};if(n+=Jte(e,o),typeof o.start<"u")return{result:n+o.start,precise:!0}}return{result:n,precise:!1}},oCt=function(e,i){for(var n=0,r,o=i-e.mediaSequence;o<e.segments.length;o++){if(r=e.segments[o],typeof r.start<"u")return{result:r.start-n,precise:!0};if(n+=Jte(e,r),typeof r.end<"u")return{result:r.end-n,precise:!0}}return{result:-1,precise:!1}},k2e=function(e,i,n){if(typeof i>"u"&&(i=e.mediaSequence+e.segments.length),i<e.mediaSequence)return 0;var r=nCt(e,i);if(r.precise)return r.result;var o=oCt(e,i);return o.precise?o.result:r.result+n},I2e=function(e,i,n){if(!e)return 0;if(typeof n!="number"&&(n=0),typeof i>"u"){if(e.totalDuration)return e.totalDuration;if(!e.endList)return Ct.Infinity}return k2e(e,i,n)},Dj=function(e){var i=e.defaultDuration,n=e.durationList,r=e.startIndex,o=e.endIndex,a=0;if(r>o){var s=[o,r];r=s[0],o=s[1]}if(r<0){for(var l=r;l<Math.min(0,o);l++)a+=i;r=0}for(var u=r;u<o;u++)a+=n[u].duration;return a},N2e=function(e,i,n,r){if(!e||!e.segments)return null;if(e.endList)return I2e(e);if(i===null)return null;i=i||0;var o=k2e(e,e.mediaSequence+e.segments.length,i);return n&&(r=typeof r=="number"?r:L2e(null,e),o-=r),Math.max(0,o)},aCt=function(e,i,n){var r=!0,o=i||0,a=N2e(e,i,r,n);return a===null?xde():xde(o,a)},sCt=function(e){for(var i=e.playlist,n=e.currentTime,r=e.startingSegmentIndex,o=e.startingPartIndex,a=e.startTime,s=e.experimentalExactManifestTimings,l=n-a,u=XZ(i),c=0,d=0;d<u.length;d++){var f=u[d];if(r===f.segmentIndex&&!(typeof o=="number"&&typeof f.partIndex=="number"&&o!==f.partIndex)){c=d;break}}if(l<0){if(c>0)for(var h=c-1;h>=0;h--){var p=u[h];if(l+=p.duration,s){if(l<0)continue}else if(l+OP<=0)continue;return{partIndex:p.partIndex,segmentIndex:p.segmentIndex,startTime:a-Dj({defaultDuration:i.targetDuration,durationList:u,startIndex:c,endIndex:h})}}return{partIndex:u[0]&&u[0].partIndex||null,segmentIndex:u[0]&&u[0].segmentIndex||0,startTime:n}}if(c<0){for(var g=c;g<0;g++)if(l-=i.targetDuration,l<0)return{partIndex:u[0]&&u[0].partIndex||null,segmentIndex:u[0]&&u[0].segmentIndex||0,startTime:n};c=0}for(var v=c;v<u.length;v++){var y=u[v];if(l-=y.duration,s){if(l>0)continue}else if(l-OP>=0)continue;return{partIndex:y.partIndex,segmentIndex:y.segmentIndex,startTime:a+Dj({defaultDuration:i.targetDuration,durationList:u,startIndex:c,endIndex:v})}}return{segmentIndex:u[u.length-1].segmentIndex,partIndex:u[u.length-1].partIndex,startTime:n}},F2e=function(e){return e.excludeUntil&&e.excludeUntil>Date.now()},Qte=function(e){return e.excludeUntil&&e.excludeUntil===1/0},rW=function(e){var i=F2e(e);return!e.disabled&&!i},lCt=function(e){return e.disabled},uCt=function(e){for(var i=0;i<e.segments.length;i++)if(e.segments[i].key)return!0;return!1},B2e=function(e,i){return i.attributes&&i.attributes[e]},cCt=function(e,i,n,r){if(r===void 0&&(r=0),!B2e("BANDWIDTH",n))return NaN;var o=e*n.attributes.BANDWIDTH;return(o-r*8)/i},KZ=function(e,i){if(e.playlists.length===1)return!0;var n=i.attributes.BANDWIDTH||Number.MAX_VALUE;return e.playlists.filter(function(r){return rW(r)?(r.attributes.BANDWIDTH||0)<n:!1}).length===0},ere=function(e,i){return!e&&!i||!e&&i||e&&!i?!1:!!(e===i||e.id&&i.id&&e.id===i.id||e.resolvedUri&&i.resolvedUri&&e.resolvedUri===i.resolvedUri||e.uri&&i.uri&&e.uri===i.uri)},Ede=function(e,i){var n=e&&e.mediaGroups&&e.mediaGroups.AUDIO||{},r=!1;for(var o in n){for(var a in n[o])if(r=i(n[o][a]),r)break;if(r)break}return!!r},zV=function(e){if(!e||!e.playlists||!e.playlists.length){var i=Ede(e,function(a){return a.playlists&&a.playlists.length||a.uri});return i}for(var n=function(s){var l=e.playlists[s],u=l.attributes&&l.attributes.CODECS;if(u&&u.split(",").every(function(d){return sIe(d)}))return"continue";var c=Ede(e,function(d){return ere(l,d)});return c?"continue":{v:!1}},r=0;r<e.playlists.length;r++){var o=n(r);if(o!=="continue"&&typeof o=="object")return o.v}return!0},wh={liveEdgeDelay:L2e,duration:I2e,seekable:aCt,getMediaInfoForTime:sCt,isEnabled:rW,isDisabled:lCt,isBlacklisted:F2e,isIncompatible:Qte,playlistEnd:N2e,isAes:uCt,hasAttribute:B2e,estimateSegmentRequestTime:cCt,isLowestEnabledRendition:KZ,isAudioOnly:zV,playlistMatch:ere,segmentDurationWithParts:Jte},j2e=Vt.log,tre=function(e,i){return e+"-"+i},dCt=function(e,i,n){return"placeholder-uri-"+e+"-"+i+"-"+n},fCt=function(e){var i=e.onwarn,n=e.oninfo,r=e.manifestString,o=e.customTagParsers,a=o===void 0?[]:o,s=e.customTagMappers,l=s===void 0?[]:s,u=e.experimentalLLHLS,c=new Xbt;i&&c.on("warn",i),n&&c.on("info",n),a.forEach(function(g){return c.addParser(g)}),l.forEach(function(g){return c.addTagMapper(g)}),c.push(r),c.end();var d=c.manifest;if(u||(["preloadSegment","skip","serverControl","renditionReports","partInf","partTargetDuration"].forEach(function(g){d.hasOwnProperty(g)&&delete d[g]}),d.segments&&d.segments.forEach(function(g){["parts","preloadHints"].forEach(function(v){g.hasOwnProperty(v)&&delete g[v]})})),!d.targetDuration){var f=10;d.segments&&d.segments.length&&(f=d.segments.reduce(function(g,v){return Math.max(g,v.duration)},0)),i&&i("manifest has no targetDuration defaulting to "+f),d.targetDuration=f}var h=R2e(d);if(h.length&&!d.partTargetDuration){var p=h.reduce(function(g,v){return Math.max(g,v.duration)},0);i&&(i("manifest has no partTargetDuration defaulting to "+p),j2e.error("LL-HLS manifest has parts but lacks required #EXT-X-PART-INF:PART-TARGET value. See https://datatracker.ietf.org/doc/html/draft-pantos-hls-rfc8216bis-09#section-4.4.3.7. Playback is not guaranteed.")),d.partTargetDuration=p}return d},EI=function(e,i){e.mediaGroups&&["AUDIO","SUBTITLES"].forEach(function(n){if(e.mediaGroups[n])for(var r in e.mediaGroups[n])for(var o in e.mediaGroups[n][r]){var a=e.mediaGroups[n][r][o];i(a,n,r,o)}})},V2e=function(e){var i=e.playlist,n=e.uri,r=e.id;i.id=r,i.playlistErrors_=0,n&&(i.uri=n),i.attributes=i.attributes||{}},hCt=function(e){for(var i=e.playlists.length;i--;){var n=e.playlists[i];V2e({playlist:n,id:tre(i,n.uri)}),n.resolvedUri=Sv(e.uri,n.uri),e.playlists[n.id]=n,e.playlists[n.uri]=n,n.attributes.BANDWIDTH||j2e.warn("Invalid playlist STREAM-INF detected. Missing BANDWIDTH attribute.")}},pCt=function(e){EI(e,function(i){i.uri&&(i.resolvedUri=Sv(e.uri,i.uri))})},gCt=function(e,i){var n=tre(0,i),r={mediaGroups:{AUDIO:{},VIDEO:{},"CLOSED-CAPTIONS":{},SUBTITLES:{}},uri:Ct.location.href,resolvedUri:Ct.location.href,playlists:[{uri:i,id:n,resolvedUri:i,attributes:{}}]};return r.playlists[n]=r.playlists[0],r.playlists[i]=r.playlists[0],r},H2e=function(e,i,n){n===void 0&&(n=dCt),e.uri=i;for(var r=0;r<e.playlists.length;r++)if(!e.playlists[r].uri){var o="placeholder-uri-"+r;e.playlists[r].uri=o}var a=zV(e);EI(e,function(s,l,u,c){if(!s.playlists||!s.playlists.length){if(a&&l==="AUDIO"&&!s.uri)for(var d=0;d<e.playlists.length;d++){var f=e.playlists[d];if(f.attributes&&f.attributes.AUDIO&&f.attributes.AUDIO===u)return}s.playlists=[Gn({},s)]}s.playlists.forEach(function(h,p){var g=n(l,u,c,h),v=tre(p,g);h.uri?h.resolvedUri=h.resolvedUri||Sv(e.uri,h.uri):(h.uri=p===0?g:v,h.resolvedUri=h.uri),h.id=h.id||v,h.attributes=h.attributes||{},e.playlists[h.id]=h,e.playlists[h.uri]=h})}),hCt(e),pCt(e)},Mz=Vt.mergeOptions,vCt=Vt.EventTarget,yCt=function(e,i){if(i.endList||!i.serverControl)return e;var n={};if(i.serverControl.canBlockReload){var r=i.preloadSegment,o=i.mediaSequence+i.segments.length;if(r){var a=r.parts||[],s=M2e(i)-1;s>-1&&s!==a.length-1&&(n._HLS_part=s),(s>-1||a.length)&&o--}n._HLS_msn=o}if(i.serverControl&&i.serverControl.canSkipUntil&&(n._HLS_skip=i.serverControl.canSkipDateranges?"v2":"YES"),Object.keys(n).length){var l=new Ct.URL(e);["_HLS_skip","_HLS_msn","_HLS_part"].forEach(function(u){n.hasOwnProperty(u)&&l.searchParams.set(u,n[u])}),e=l.toString()}return e},mCt=function(e,i){if(!e)return i;var n=Mz(e,i);if(e.preloadHints&&!i.preloadHints&&delete n.preloadHints,e.parts&&!i.parts)delete n.parts;else if(e.parts&&i.parts)for(var r=0;r<i.parts.length;r++)e.parts&&e.parts[r]&&(n.parts[r]=Mz(e.parts[r],i.parts[r]));return!e.skipped&&i.skipped&&(n.skipped=!1),e.preload&&!i.preload&&(n.preload=!1),n},bCt=function(e,i,n){var r=e.slice(),o=i.slice();n=n||0;for(var a=[],s,l=0;l<o.length;l++){var u=r[l+n],c=o[l];u?(s=u.map||s,a.push(mCt(u,c))):(s&&!c.map&&(c.map=s),a.push(c))}return a},U2e=function(e,i){!e.resolvedUri&&e.uri&&(e.resolvedUri=Sv(i,e.uri)),e.key&&!e.key.resolvedUri&&(e.key.resolvedUri=Sv(i,e.key.uri)),e.map&&!e.map.resolvedUri&&(e.map.resolvedUri=Sv(i,e.map.uri)),e.map&&e.map.key&&!e.map.key.resolvedUri&&(e.map.key.resolvedUri=Sv(i,e.map.key.uri)),e.parts&&e.parts.length&&e.parts.forEach(function(n){n.resolvedUri||(n.resolvedUri=Sv(i,n.uri))}),e.preloadHints&&e.preloadHints.length&&e.preloadHints.forEach(function(n){n.resolvedUri||(n.resolvedUri=Sv(i,n.uri))})},z2e=function(e){var i=e.segments||[],n=e.preloadSegment;if(n&&n.parts&&n.parts.length){if(n.preloadHints){for(var r=0;r<n.preloadHints.length;r++)if(n.preloadHints[r].type==="MAP")return i}n.duration=e.targetDuration,n.preload=!0,i.push(n)}return i},$2e=function(e,i){return e===i||e.segments&&i.segments&&e.segments.length===i.segments.length&&e.endList===i.endList&&e.mediaSequence===i.mediaSequence&&e.preloadSegment===i.preloadSegment},ZZ=function(e,i,n){n===void 0&&(n=$2e);var r=Mz(e,{}),o=r.playlists[i.id];if(!o||n(o,i))return null;i.segments=z2e(i);var a=Mz(o,i);if(a.preloadSegment&&!i.preloadSegment&&delete a.preloadSegment,o.segments){if(i.skip){i.segments=i.segments||[];for(var s=0;s<i.skip.skippedSegments;s++)i.segments.unshift({skipped:!0})}a.segments=bCt(o.segments,i.segments,i.mediaSequence-o.mediaSequence)}a.segments.forEach(function(u){U2e(u,a.resolvedUri)});for(var l=0;l<r.playlists.length;l++)r.playlists[l].id===i.id&&(r.playlists[l]=a);return r.playlists[i.id]=a,r.playlists[i.uri]=a,EI(e,function(u,c,d,f){if(u.playlists)for(var h=0;h<u.playlists.length;h++)i.id===u.playlists[h].id&&(u.playlists[h]=a)}),r},JZ=function(e,i){var n=e.segments||[],r=n[n.length-1],o=r&&r.parts&&r.parts[r.parts.length-1],a=o&&o.duration||r&&r.duration;return i&&a?a*1e3:(e.partTargetDuration||e.targetDuration||10)*500},DL=(function(t){qr(e,t);function e(n,r,o){var a;if(o===void 0&&(o={}),a=t.call(this)||this,!n)throw new Error("A non-empty playlist URL or object is required");a.logger_=zv("PlaylistLoader");var s=o,l=s.withCredentials,u=l===void 0?!1:l,c=s.handleManifestRedirects,d=c===void 0?!1:c;a.src=n,a.vhs_=r,a.withCredentials=u,a.handleManifestRedirects=d;var f=r.options_;return a.customTagParsers=f&&f.customTagParsers||[],a.customTagMappers=f&&f.customTagMappers||[],a.experimentalLLHLS=f&&f.experimentalLLHLS||!1,Vt.browser.IE_VERSION&&(a.experimentalLLHLS=!1),a.state="HAVE_NOTHING",a.handleMediaupdatetimeout_=a.handleMediaupdatetimeout_.bind(bn(a)),a.on("mediaupdatetimeout",a.handleMediaupdatetimeout_),a}var i=e.prototype;return i.handleMediaupdatetimeout_=function(){var r=this;if(this.state==="HAVE_METADATA"){var o=this.media(),a=Sv(this.master.uri,o.uri);this.experimentalLLHLS&&(a=yCt(a,o)),this.state="HAVE_CURRENT_METADATA",this.request=this.vhs_.xhr({uri:a,withCredentials:this.withCredentials},function(s,l){if(r.request){if(s)return r.playlistRequestError(r.request,r.media(),"HAVE_METADATA");r.haveMetadata({playlistString:r.request.responseText,url:r.media().uri,id:r.media().id})}})}},i.playlistRequestError=function(r,o,a){var s=o.uri,l=o.id;this.request=null,a&&(this.state=a),this.error={playlist:this.master.playlists[l],status:r.status,message:"HLS playlist request error at URL: "+s+".",responseText:r.responseText,code:r.status>=500?4:2},this.trigger("error")},i.parseManifest_=function(r){var o=this,a=r.url,s=r.manifestString;return fCt({onwarn:function(u){var c=u.message;return o.logger_("m3u8-parser warn for "+a+": "+c)},oninfo:function(u){var c=u.message;return o.logger_("m3u8-parser info for "+a+": "+c)},manifestString:s,customTagParsers:this.customTagParsers,customTagMappers:this.customTagMappers,experimentalLLHLS:this.experimentalLLHLS})},i.haveMetadata=function(r){var o=r.playlistString,a=r.playlistObject,s=r.url,l=r.id;this.request=null,this.state="HAVE_METADATA";var u=a||this.parseManifest_({url:s,manifestString:o});u.lastRequest=Date.now(),V2e({playlist:u,uri:s,id:l});var c=ZZ(this.master,u);this.targetDuration=u.partTargetDuration||u.targetDuration,this.pendingMedia_=null,c?(this.master=c,this.media_=this.master.playlists[l]):this.trigger("playlistunchanged"),this.updateMediaUpdateTimeout_(JZ(this.media(),!!c)),this.trigger("loadedplaylist")},i.dispose=function(){this.trigger("dispose"),this.stopRequest(),Ct.clearTimeout(this.mediaUpdateTimeout),Ct.clearTimeout(this.finalRenditionTimeout),this.off()},i.stopRequest=function(){if(this.request){var r=this.request;this.request=null,r.onreadystatechange=null,r.abort()}},i.media=function(r,o){var a=this;if(!r)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);if(typeof r=="string"){if(!this.master.playlists[r])throw new Error("Unknown playlist URI: "+r);r=this.master.playlists[r]}if(Ct.clearTimeout(this.finalRenditionTimeout),o){var s=(r.partTargetDuration||r.targetDuration)/2*1e3||5e3;this.finalRenditionTimeout=Ct.setTimeout(this.media.bind(this,r,!1),s);return}var l=this.state,u=!this.media_||r.id!==this.media_.id,c=this.master.playlists[r.id];if(c&&c.endList||r.endList&&r.segments.length){this.request&&(this.request.onreadystatechange=null,this.request.abort(),this.request=null),this.state="HAVE_METADATA",this.media_=r,u&&(this.trigger("mediachanging"),l==="HAVE_MASTER"?this.trigger("loadedmetadata"):this.trigger("mediachange"));return}if(this.updateMediaUpdateTimeout_(JZ(r,!0)),!!u){if(this.state="SWITCHING_MEDIA",this.request){if(r.resolvedUri===this.request.url)return;this.request.onreadystatechange=null,this.request.abort(),this.request=null}this.media_&&this.trigger("mediachanging"),this.pendingMedia_=r,this.request=this.vhs_.xhr({uri:r.resolvedUri,withCredentials:this.withCredentials},function(d,f){if(a.request){if(r.lastRequest=Date.now(),r.resolvedUri=Rz(a.handleManifestRedirects,r.resolvedUri,f),d)return a.playlistRequestError(a.request,r,l);a.haveMetadata({playlistString:f.responseText,url:r.uri,id:r.id}),l==="HAVE_MASTER"?a.trigger("loadedmetadata"):a.trigger("mediachange")}})}},i.pause=function(){this.mediaUpdateTimeout&&(Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),this.stopRequest(),this.state==="HAVE_NOTHING"&&(this.started=!1),this.state==="SWITCHING_MEDIA"?this.media_?this.state="HAVE_METADATA":this.state="HAVE_MASTER":this.state==="HAVE_CURRENT_METADATA"&&(this.state="HAVE_METADATA")},i.load=function(r){var o=this;this.mediaUpdateTimeout&&(Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null);var a=this.media();if(r){var s=a?(a.partTargetDuration||a.targetDuration)/2*1e3:5e3;this.mediaUpdateTimeout=Ct.setTimeout(function(){o.mediaUpdateTimeout=null,o.load()},s);return}if(!this.started){this.start();return}a&&!a.endList?this.trigger("mediaupdatetimeout"):this.trigger("loadedplaylist")},i.updateMediaUpdateTimeout_=function(r){var o=this;this.mediaUpdateTimeout&&(Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null),!(!this.media()||this.media().endList)&&(this.mediaUpdateTimeout=Ct.setTimeout(function(){o.mediaUpdateTimeout=null,o.trigger("mediaupdatetimeout"),o.updateMediaUpdateTimeout_(r)},r))},i.start=function(){var r=this;if(this.started=!0,typeof this.src=="object"){this.src.uri||(this.src.uri=Ct.location.href),this.src.resolvedUri=this.src.uri,setTimeout(function(){r.setupInitialPlaylist(r.src)},0);return}this.request=this.vhs_.xhr({uri:this.src,withCredentials:this.withCredentials},function(o,a){if(r.request){if(r.request=null,o)return r.error={status:a.status,message:"HLS playlist request error at URL: "+r.src+".",responseText:a.responseText,code:2},r.state==="HAVE_NOTHING"&&(r.started=!1),r.trigger("error");r.src=Rz(r.handleManifestRedirects,r.src,a);var s=r.parseManifest_({manifestString:a.responseText,url:r.src});r.setupInitialPlaylist(s)}})},i.srcUri=function(){return typeof this.src=="string"?this.src:this.src.uri},i.setupInitialPlaylist=function(r){if(this.state="HAVE_MASTER",r.playlists){this.master=r,H2e(this.master,this.srcUri()),r.playlists.forEach(function(a){a.segments=z2e(a),a.segments.forEach(function(s){U2e(s,a.resolvedUri)})}),this.trigger("loadedplaylist"),this.request||this.media(this.master.playlists[0]);return}var o=this.srcUri()||Ct.location.href;this.master=gCt(r,o),this.haveMetadata({playlistObject:r,url:o,id:this.master.playlists[0].id}),this.trigger("loadedmetadata")},e})(vCt),SCt=Vt.xhr,_Ct=Vt.mergeOptions,QZ=function(e,i,n,r){var o=e.responseType==="arraybuffer"?e.response:e.responseText;!i&&o&&(e.responseTime=Date.now(),e.roundTripTime=e.responseTime-e.requestTime,e.bytesReceived=o.byteLength||o.length,e.bandwidth||(e.bandwidth=Math.floor(e.bytesReceived/e.roundTripTime*8*1e3))),n.headers&&(e.responseHeaders=n.headers),i&&i.code==="ETIMEDOUT"&&(e.timedout=!0),!i&&!e.aborted&&n.statusCode!==200&&n.statusCode!==206&&n.statusCode!==0&&(i=new Error("XHR Failed with a response of: "+(e&&(o||e.responseText)))),r(i,e)},W2e=function(){var e=function i(n,r){n=_Ct({timeout:45e3},n);var o=i.beforeRequest||Vt.Vhs.xhr.beforeRequest;if(o&&typeof o=="function"){var a=o(n);a&&(n=a)}var s=Vt.Vhs.xhr.original===!0?SCt:Vt.Vhs.xhr,l=s(n,function(c,d){return QZ(l,c,d,r)}),u=l.abort;return l.abort=function(){return l.aborted=!0,u.apply(l,arguments)},l.uri=n.uri,l.requestTime=Date.now(),l};return e.original=!0,e},PCt=function(e){var i,n=e.offset;return typeof e.offset=="bigint"||typeof e.length=="bigint"?i=Ct.BigInt(e.offset)+Ct.BigInt(e.length)-Ct.BigInt(1):i=e.offset+e.length-1,"bytes="+n+"-"+i},eJ=function(e){var i={};return e.byterange&&(i.Range=PCt(e.byterange)),i},CCt=function(e,i){return e.start(i)+"-"+e.end(i)},TCt=function(e,i){var n=e.toString(16);return"00".substring(0,2-n.length)+n+(i%2?" ":"")},xCt=function(e){return e>=32&&e<126?String.fromCharCode(e):"."},G2e=function(e){var i={};return Object.keys(e).forEach(function(n){var r=e[n];uIe(r)?i[n]={bytes:r.buffer,byteOffset:r.byteOffset,byteLength:r.byteLength}:i[n]=r}),i},Lz=function(e){var i=e.byterange||{length:1/0,offset:0};return[i.length,i.offset,e.resolvedUri].join(",")},Y2e=function(e){return e.resolvedUri},q2e=function(e){for(var i=Array.prototype.slice.call(e),n=16,r="",o,a,s=0;s<i.length/n;s++)o=i.slice(s*n,s*n+n).map(TCt).join(""),a=i.slice(s*n,s*n+n).map(xCt).join(""),r+=o+" "+a+`
`;return r},ECt=function(e){var i=e.bytes;return q2e(i)},wCt=function(e){var i="",n;for(n=0;n<e.length;n++)i+=CCt(e,n)+" ";return i},ACt=Object.freeze({__proto__:null,createTransferableMessage:G2e,initSegmentId:Lz,segmentKeyId:Y2e,hexDump:q2e,tagDump:ECt,textRanges:wCt}),X2e=.25,OCt=function(e,i){if(!i.dateTimeObject)return null;var n=i.videoTimingInfo.transmuxerPrependedSeconds,r=i.videoTimingInfo.transmuxedPresentationStart,o=r+n,a=e-o;return new Date(i.dateTimeObject.getTime()+a*1e3)},DCt=function(e){return e.transmuxedPresentationEnd-e.transmuxedPresentationStart-e.transmuxerPrependedSeconds},RCt=function(e,i){var n;try{n=new Date(e)}catch{return null}if(!i||!i.segments||i.segments.length===0)return null;var r=i.segments[0];if(n<r.dateTimeObject)return null;for(var o=0;o<i.segments.length-1;o++){r=i.segments[o];var a=i.segments[o+1].dateTimeObject;if(n<a)break}var s=i.segments[i.segments.length-1],l=s.dateTimeObject,u=s.videoTimingInfo?DCt(s.videoTimingInfo):s.duration+s.duration*X2e,c=new Date(l.getTime()+u*1e3);return n>c?null:(n>l&&(r=s),{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:wh.duration(i,i.mediaSequence+i.segments.indexOf(r)),type:r.videoTimingInfo?"accurate":"estimate"})},MCt=function(e,i){if(!i||!i.segments||i.segments.length===0)return null;for(var n=0,r,o=0;o<i.segments.length&&(r=i.segments[o],n=r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationEnd:n+r.duration,!(e<=n));o++);var a=i.segments[i.segments.length-1];if(a.videoTimingInfo&&a.videoTimingInfo.transmuxedPresentationEnd<e)return null;if(e>n){if(e>n+a.duration*X2e)return null;r=a}return{segment:r,estimatedStart:r.videoTimingInfo?r.videoTimingInfo.transmuxedPresentationStart:n-r.duration,type:r.videoTimingInfo?"accurate":"estimate"}},LCt=function(e,i){var n,r;try{n=new Date(e),r=new Date(i)}catch{}var o=n.getTime(),a=r.getTime();return(a-o)/1e3},kCt=function(e){if(!e.segments||e.segments.length===0)return!1;for(var i=0;i<e.segments.length;i++){var n=e.segments[i];if(!n.dateTimeObject)return!1}return!0},ICt=function(e){var i=e.playlist,n=e.time,r=n===void 0?void 0:n,o=e.callback;if(!o)throw new Error("getProgramTime: callback must be provided");if(!i||r===void 0)return o({message:"getProgramTime: playlist and time must be provided"});var a=MCt(r,i);if(!a)return o({message:"valid programTime was not found"});if(a.type==="estimate")return o({message:"Accurate programTime could not be determined. Please seek to e.seekTime and try again",seekTime:a.estimatedStart});var s={mediaSeconds:r},l=OCt(r,a.segment);return l&&(s.programDateTime=l.toISOString()),o(null,s)},NCt=function t(e){var i=e.programTime,n=e.playlist,r=e.retryCount,o=r===void 0?2:r,a=e.seekTo,s=e.pauseAfterSeek,l=s===void 0?!0:s,u=e.tech,c=e.callback;if(!c)throw new Error("seekToProgramTime: callback must be provided");if(typeof i>"u"||!n||!a)return c({message:"seekToProgramTime: programTime, seekTo and playlist must be provided"});if(!n.endList&&!u.hasStarted_)return c({message:"player must be playing a live stream to start buffering"});if(!kCt(n))return c({message:"programDateTime tags must be provided in the manifest "+n.resolvedUri});var d=RCt(i,n);if(!d)return c({message:i+" was not found in the stream"});var f=d.segment,h=LCt(f.dateTimeObject,i);if(d.type==="estimate"){if(o===0)return c({message:i+" is not buffered yet. Try again"});a(d.estimatedStart+h),u.one("seeked",function(){t({programTime:i,playlist:n,retryCount:o-1,seekTo:a,pauseAfterSeek:l,tech:u,callback:c})});return}var p=f.start+h,g=function(){return c(null,u.currentTime())};u.one("seeked",g),l&&u.pause(),a(p)},lq=function(e,i){if(e.readyState===4)return i()},FCt=function(e,i,n){var r=[],o,a=!1,s=function(f,h,p,g){return h.abort(),a=!0,n(f,h,p,g)},l=function(f,h){if(!a){if(f)return s(f,h,"",r);var p=h.responseText.substring(r&&r.byteLength||0,h.responseText.length);if(r=sSt(r,cIe(p,!0)),o=o||sj(r),r.length<10||o&&r.length<o+2)return lq(h,function(){return s(f,h,"",r)});var g=_te(r);return g==="ts"&&r.length<188?lq(h,function(){return s(f,h,"",r)}):!g&&r.length<376?lq(h,function(){return s(f,h,"",r)}):s(null,h,g,r)}},u={uri:e,beforeSend:function(f){f.overrideMimeType("text/plain; charset=x-user-defined"),f.addEventListener("progress",function(h){return h.total,h.loaded,QZ(f,null,{statusCode:f.status},l)})}},c=i(u,function(d,f){return QZ(c,d,f,l)});return c},BCt=Vt.EventTarget,K2e=Vt.mergeOptions,wde=function(e,i){if(!$2e(e,i)||e.sidx&&i.sidx&&(e.sidx.offset!==i.sidx.offset||e.sidx.length!==i.sidx.length))return!1;if(!e.sidx&&i.sidx||e.sidx&&!i.sidx||e.segments&&!i.segments||!e.segments&&i.segments)return!1;if(!e.segments&&!i.segments)return!0;for(var n=0;n<e.segments.length;n++){var r=e.segments[n],o=i.segments[n];if(r.uri!==o.uri)return!1;if(!(!r.byterange&&!o.byterange)){var a=r.byterange,s=o.byterange;if(a&&!s||!a&&s||a.offset!==s.offset||a.length!==s.length)return!1}}return!0},jCt=function(e,i,n,r){var o=r.attributes.NAME||n;return"placeholder-uri-"+e+"-"+i+"-"+o},VCt=function(e){var i=e.masterXml,n=e.srcUrl,r=e.clientOffset,o=e.sidxMapping,a=e.previousManifest,s=i_t(i,{manifestUri:n,clientOffset:r,sidxMapping:o,previousManifest:a});return H2e(s,n,jCt),s},HCt=function(e,i){EI(e,function(n,r,o,a){a in i.mediaGroups[r][o]||delete e.mediaGroups[r][o][a]})},UCt=function(e,i,n){for(var r=!0,o=K2e(e,{duration:i.duration,minimumUpdatePeriod:i.minimumUpdatePeriod,timelineStarts:i.timelineStarts}),a=0;a<i.playlists.length;a++){var s=i.playlists[a];if(s.sidx){var l=$6(s.sidx);n&&n[l]&&n[l].sidx&&yte(s,n[l].sidx,s.sidx.resolvedUri)}var u=ZZ(o,s,wde);u&&(o=u,r=!1)}return EI(i,function(c,d,f,h){if(c.playlists&&c.playlists.length){var p=c.playlists[0].id,g=ZZ(o,c.playlists[0],wde);g&&(o=g,h in o.mediaGroups[d][f]||(o.mediaGroups[d][f][h]=c),o.mediaGroups[d][f][h].playlists[0]=o.playlists[p],r=!1)}}),HCt(o,i),i.minimumUpdatePeriod!==e.minimumUpdatePeriod&&(r=!1),r?null:o},zCt=function(e,i){var n=!e.map&&!i.map,r=n||!!(e.map&&i.map&&e.map.byterange.offset===i.map.byterange.offset&&e.map.byterange.length===i.map.byterange.length);return r&&e.uri===i.uri&&e.byterange.offset===i.byterange.offset&&e.byterange.length===i.byterange.length},Ade=function(e,i){var n={};for(var r in e){var o=e[r],a=o.sidx;if(a){var s=$6(a);if(!i[s])break;var l=i[s].sidxInfo;zCt(l,a)&&(n[s]=i[s])}}return n},$Ct=function(e,i){var n=Ade(e.playlists,i),r=n;return EI(e,function(o,a,s,l){if(o.playlists&&o.playlists.length){var u=o.playlists;r=K2e(r,Ade(u,i))}}),r},tJ=(function(t){qr(e,t);function e(n,r,o,a){var s;o===void 0&&(o={}),s=t.call(this)||this,s.masterPlaylistLoader_=a||bn(s),a||(s.isMaster_=!0);var l=o,u=l.withCredentials,c=u===void 0?!1:u,d=l.handleManifestRedirects,f=d===void 0?!1:d;if(s.vhs_=r,s.withCredentials=c,s.handleManifestRedirects=f,!n)throw new Error("A non-empty playlist URL or object is required");return s.on("minimumUpdatePeriod",function(){s.refreshXml_()}),s.on("mediaupdatetimeout",function(){s.refreshMedia_(s.media().id)}),s.state="HAVE_NOTHING",s.loadedPlaylists_={},s.logger_=zv("DashPlaylistLoader"),s.isMaster_?(s.masterPlaylistLoader_.srcUrl=n,s.masterPlaylistLoader_.sidxMapping_={}):s.childPlaylist_=n,s}var i=e.prototype;return i.requestErrored_=function(r,o,a){if(!this.request)return!0;if(this.request=null,r)return this.error=typeof r=="object"&&!(r instanceof Error)?r:{status:o.status,message:"DASH request error at URL: "+o.uri,response:o.response,code:2},a&&(this.state=a),this.trigger("error"),!0},i.addSidxSegments_=function(r,o,a){var s=this,l=r.sidx&&$6(r.sidx);if(!r.sidx||!l||this.masterPlaylistLoader_.sidxMapping_[l]){this.mediaRequest_=Ct.setTimeout(function(){return a(!1)},0);return}var u=Rz(this.handleManifestRedirects,r.sidx.resolvedUri),c=function(f,h){if(!s.requestErrored_(f,h,o)){var p=s.masterPlaylistLoader_.sidxMapping_,g;try{g=l_t(Vi(h.response).subarray(8))}catch(v){s.requestErrored_(v,h,o);return}return p[l]={sidxInfo:r.sidx,sidx:g},yte(r,g,r.sidx.resolvedUri),a(!0)}};this.request=FCt(u,this.vhs_.xhr,function(d,f,h,p){if(d)return c(d,f);if(!h||h!=="mp4")return c({status:f.status,message:"Unsupported "+(h||"unknown")+" container type for sidx segment at URL: "+u,response:"",playlist:r,internal:!0,blacklistDuration:1/0,code:2},f);var g=r.sidx.byterange,v=g.offset,y=g.length;if(p.length>=y+v)return c(d,{response:p.subarray(v,v+y),status:f.status,uri:f.uri});s.request=s.vhs_.xhr({uri:u,responseType:"arraybuffer",headers:eJ({byterange:r.sidx.byterange})},c)})},i.dispose=function(){this.trigger("dispose"),this.stopRequest(),this.loadedPlaylists_={},Ct.clearTimeout(this.minimumUpdatePeriodTimeout_),Ct.clearTimeout(this.mediaRequest_),Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.mediaRequest_=null,this.minimumUpdatePeriodTimeout_=null,this.masterPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.masterPlaylistLoader_.createMupOnMedia_),this.masterPlaylistLoader_.createMupOnMedia_=null),this.off()},i.hasPendingRequest=function(){return this.request||this.mediaRequest_},i.stopRequest=function(){if(this.request){var r=this.request;this.request=null,r.onreadystatechange=null,r.abort()}},i.media=function(r){var o=this;if(!r)return this.media_;if(this.state==="HAVE_NOTHING")throw new Error("Cannot switch media playlist from "+this.state);var a=this.state;if(typeof r=="string"){if(!this.masterPlaylistLoader_.master.playlists[r])throw new Error("Unknown playlist URI: "+r);r=this.masterPlaylistLoader_.master.playlists[r]}var s=!this.media_||r.id!==this.media_.id;if(s&&this.loadedPlaylists_[r.id]&&this.loadedPlaylists_[r.id].endList){this.state="HAVE_METADATA",this.media_=r,s&&(this.trigger("mediachanging"),this.trigger("mediachange"));return}s&&(this.media_&&this.trigger("mediachanging"),this.addSidxSegments_(r,a,function(l){o.haveMetadata({startingState:a,playlist:r})}))},i.haveMetadata=function(r){var o=r.startingState,a=r.playlist;this.state="HAVE_METADATA",this.loadedPlaylists_[a.id]=a,this.mediaRequest_=null,this.refreshMedia_(a.id),o==="HAVE_MASTER"?this.trigger("loadedmetadata"):this.trigger("mediachange")},i.pause=function(){this.masterPlaylistLoader_.createMupOnMedia_&&(this.off("loadedmetadata",this.masterPlaylistLoader_.createMupOnMedia_),this.masterPlaylistLoader_.createMupOnMedia_=null),this.stopRequest(),Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null,this.isMaster_&&(Ct.clearTimeout(this.masterPlaylistLoader_.minimumUpdatePeriodTimeout_),this.masterPlaylistLoader_.minimumUpdatePeriodTimeout_=null),this.state==="HAVE_NOTHING"&&(this.started=!1)},i.load=function(r){var o=this;Ct.clearTimeout(this.mediaUpdateTimeout),this.mediaUpdateTimeout=null;var a=this.media();if(r){var s=a?a.targetDuration/2*1e3:5e3;this.mediaUpdateTimeout=Ct.setTimeout(function(){return o.load()},s);return}if(!this.started){this.start();return}a&&!a.endList?(this.isMaster_&&!this.minimumUpdatePeriodTimeout_&&(this.trigger("minimumUpdatePeriod"),this.updateMinimumUpdatePeriodTimeout_()),this.trigger("mediaupdatetimeout")):this.trigger("loadedplaylist")},i.start=function(){var r=this;if(this.started=!0,!this.isMaster_){this.mediaRequest_=Ct.setTimeout(function(){return r.haveMaster_()},0);return}this.requestMaster_(function(o,a){r.haveMaster_(),!r.hasPendingRequest()&&!r.media_&&r.media(r.masterPlaylistLoader_.master.playlists[0])})},i.requestMaster_=function(r){var o=this;this.request=this.vhs_.xhr({uri:this.masterPlaylistLoader_.srcUrl,withCredentials:this.withCredentials},function(a,s){if(o.requestErrored_(a,s)){o.state==="HAVE_NOTHING"&&(o.started=!1);return}var l=s.responseText!==o.masterPlaylistLoader_.masterXml_;if(o.masterPlaylistLoader_.masterXml_=s.responseText,s.responseHeaders&&s.responseHeaders.date?o.masterLoaded_=Date.parse(s.responseHeaders.date):o.masterLoaded_=Date.now(),o.masterPlaylistLoader_.srcUrl=Rz(o.handleManifestRedirects,o.masterPlaylistLoader_.srcUrl,s),l){o.handleMaster_(),o.syncClientServerClock_(function(){return r(s,l)});return}return r(s,l)})},i.syncClientServerClock_=function(r){var o=this,a=n_t(this.masterPlaylistLoader_.masterXml_);if(a===null)return this.masterPlaylistLoader_.clientOffset_=this.masterLoaded_-Date.now(),r();if(a.method==="DIRECT")return this.masterPlaylistLoader_.clientOffset_=a.value-Date.now(),r();this.request=this.vhs_.xhr({uri:Sv(this.masterPlaylistLoader_.srcUrl,a.value),method:a.method,withCredentials:this.withCredentials},function(s,l){if(o.request){if(s)return o.masterPlaylistLoader_.clientOffset_=o.masterLoaded_-Date.now(),r();var u;a.method==="HEAD"?!l.responseHeaders||!l.responseHeaders.date?u=o.masterLoaded_:u=Date.parse(l.responseHeaders.date):u=Date.parse(l.responseText),o.masterPlaylistLoader_.clientOffset_=u-Date.now(),r()}})},i.haveMaster_=function(){this.state="HAVE_MASTER",this.isMaster_?this.trigger("loadedplaylist"):this.media_||this.media(this.childPlaylist_)},i.handleMaster_=function(){this.mediaRequest_=null;var r=this.masterPlaylistLoader_.master,o=VCt({masterXml:this.masterPlaylistLoader_.masterXml_,srcUrl:this.masterPlaylistLoader_.srcUrl,clientOffset:this.masterPlaylistLoader_.clientOffset_,sidxMapping:this.masterPlaylistLoader_.sidxMapping_,previousManifest:r});r&&(o=UCt(r,o,this.masterPlaylistLoader_.sidxMapping_)),this.masterPlaylistLoader_.master=o||r;var a=this.masterPlaylistLoader_.master.locations&&this.masterPlaylistLoader_.master.locations[0];return a&&a!==this.masterPlaylistLoader_.srcUrl&&(this.masterPlaylistLoader_.srcUrl=a),(!r||o&&o.minimumUpdatePeriod!==r.minimumUpdatePeriod)&&this.updateMinimumUpdatePeriodTimeout_(),!!o},i.updateMinimumUpdatePeriodTimeout_=function(){var r=this.masterPlaylistLoader_;r.createMupOnMedia_&&(r.off("loadedmetadata",r.createMupOnMedia_),r.createMupOnMedia_=null),r.minimumUpdatePeriodTimeout_&&(Ct.clearTimeout(r.minimumUpdatePeriodTimeout_),r.minimumUpdatePeriodTimeout_=null);var o=r.master&&r.master.minimumUpdatePeriod;if(o===0&&(r.media()?o=r.media().targetDuration*1e3:(r.createMupOnMedia_=r.updateMinimumUpdatePeriodTimeout_,r.one("loadedmetadata",r.createMupOnMedia_))),typeof o!="number"||o<=0){o<0&&this.logger_("found invalid minimumUpdatePeriod of "+o+", not setting a timeout");return}this.createMUPTimeout_(o)},i.createMUPTimeout_=function(r){var o=this.masterPlaylistLoader_;o.minimumUpdatePeriodTimeout_=Ct.setTimeout(function(){o.minimumUpdatePeriodTimeout_=null,o.trigger("minimumUpdatePeriod"),o.createMUPTimeout_(r)},r)},i.refreshXml_=function(){var r=this;this.requestMaster_(function(o,a){a&&(r.media_&&(r.media_=r.masterPlaylistLoader_.master.playlists[r.media_.id]),r.masterPlaylistLoader_.sidxMapping_=$Ct(r.masterPlaylistLoader_.master,r.masterPlaylistLoader_.sidxMapping_),r.addSidxSegments_(r.media(),r.state,function(s){r.refreshMedia_(r.media().id)}))})},i.refreshMedia_=function(r){var o=this;if(!r)throw new Error("refreshMedia_ must take a media id");this.media_&&this.isMaster_&&this.handleMaster_();var a=this.masterPlaylistLoader_.master.playlists,s=!this.media_||this.media_!==a[r];if(s?this.media_=a[r]:this.trigger("playlistunchanged"),!this.mediaUpdateTimeout){var l=function u(){o.media().endList||(o.mediaUpdateTimeout=Ct.setTimeout(function(){o.trigger("mediaupdatetimeout"),u()},JZ(o.media(),!!s)))};l()}this.trigger("loadedplaylist")},e})(BCt),Pc={GOAL_BUFFER_LENGTH:30,MAX_GOAL_BUFFER_LENGTH:60,BACK_BUFFER_LENGTH:30,GOAL_BUFFER_LENGTH_RATE:1,INITIAL_BANDWIDTH:4194304,BANDWIDTH_VARIANCE:1.2,BUFFER_LOW_WATER_LINE:0,MAX_BUFFER_LOW_WATER_LINE:30,EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:16,BUFFER_LOW_WATER_LINE_RATE:1,BUFFER_HIGH_WATER_LINE:30},WCt=function(e){for(var i=new Uint8Array(new ArrayBuffer(e.length)),n=0;n<e.length;n++)i[n]=e.charCodeAt(n);return i.buffer},Z2e=function(e){return e.on=e.addEventListener,e.off=e.removeEventListener,e},GCt=function(e){try{return URL.createObjectURL(new Blob([e],{type:"application/javascript"}))}catch{var i=new BlobBuilder;return i.append(e),URL.createObjectURL(i.getBlob())}},J2e=function(e){return function(){var i=GCt(e),n=Z2e(new Worker(i));n.objURL=i;var r=n.terminate;return n.on=n.addEventListener,n.off=n.removeEventListener,n.terminate=function(){return URL.revokeObjectURL(i),r.call(this)},n}},Q2e=function(e){return"var browserWorkerPolyFill = "+Z2e.toString()+`;
browserWorkerPolyFill(self);
`+e},eNe=function(e){return e.toString().replace(/^function.+?{/,"").slice(0,-1)},YCt=Q2e(eNe(function(){var t=function(){this.init=function(){var le={};this.on=function(Se,be){le[Se]||(le[Se]=[]),le[Se]=le[Se].concat(be)},this.off=function(Se,be){var xe;return le[Se]?(xe=le[Se].indexOf(be),le[Se]=le[Se].slice(),le[Se].splice(xe,1),xe>-1):!1},this.trigger=function(Se){var be,xe,Le,je;if(be=le[Se],!!be)if(arguments.length===2)for(Le=be.length,xe=0;xe<Le;++xe)be[xe].call(this,arguments[1]);else{for(je=[],xe=arguments.length,xe=1;xe<arguments.length;++xe)je.push(arguments[xe]);for(Le=be.length,xe=0;xe<Le;++xe)be[xe].apply(this,je)}},this.dispose=function(){le={}}}};t.prototype.pipe=function(Ke){return this.on("data",function(le){Ke.push(le)}),this.on("done",function(le){Ke.flush(le)}),this.on("partialdone",function(le){Ke.partialFlush(le)}),this.on("endedtimeline",function(le){Ke.endTimeline(le)}),this.on("reset",function(le){Ke.reset(le)}),Ke},t.prototype.push=function(Ke){this.trigger("data",Ke)},t.prototype.flush=function(Ke){this.trigger("done",Ke)},t.prototype.partialFlush=function(Ke){this.trigger("partialdone",Ke)},t.prototype.endTimeline=function(Ke){this.trigger("endedtimeline",Ke)},t.prototype.reset=function(Ke){this.trigger("reset",Ke)};var e=t,i=Math.pow(2,32),n=function(le){var Se=new DataView(le.buffer,le.byteOffset,le.byteLength),be;return Se.getBigUint64?(be=Se.getBigUint64(0),be<Number.MAX_SAFE_INTEGER?Number(be):be):Se.getUint32(0)*i+Se.getUint32(4)},r={getUint64:n,MAX_UINT32:i},o=r.MAX_UINT32,a,s,l,u,c,d,f,h,p,g,v,y,m,b,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te;(function(){var Ke;if(M={avc1:[],avcC:[],btrt:[],dinf:[],dref:[],esds:[],ftyp:[],hdlr:[],mdat:[],mdhd:[],mdia:[],mfhd:[],minf:[],moof:[],moov:[],mp4a:[],mvex:[],mvhd:[],pasp:[],sdtp:[],smhd:[],stbl:[],stco:[],stsc:[],stsd:[],stsz:[],stts:[],styp:[],tfdt:[],tfhd:[],traf:[],trak:[],trun:[],trex:[],tkhd:[],vmhd:[]},!(typeof Uint8Array>"u")){for(Ke in M)M.hasOwnProperty(Ke)&&(M[Ke]=[Ke.charCodeAt(0),Ke.charCodeAt(1),Ke.charCodeAt(2),Ke.charCodeAt(3)]);D=new Uint8Array([105,115,111,109]),I=new Uint8Array([97,118,99,49]),F=new Uint8Array([0,0,0,1]),V=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),z=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),G={video:V,audio:z},k=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),U=new Uint8Array([0,0,0,0,0,0,0,0]),X=new Uint8Array([0,0,0,0,0,0,0,0]),W=X,Y=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),te=X,H=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0])}})(),a=function(le){var Se=[],be=0,xe,Le,je;for(xe=1;xe<arguments.length;xe++)Se.push(arguments[xe]);for(xe=Se.length;xe--;)be+=Se[xe].byteLength;for(Le=new Uint8Array(be+8),je=new DataView(Le.buffer,Le.byteOffset,Le.byteLength),je.setUint32(0,Le.byteLength),Le.set(le,4),xe=0,be=8;xe<Se.length;xe++)Le.set(Se[xe],be),be+=Se[xe].byteLength;return Le},s=function(){return a(M.dinf,a(M.dref,k))},l=function(le){return a(M.esds,new Uint8Array([0,0,0,0,3,25,0,0,0,4,17,64,21,0,6,0,0,0,218,192,0,0,218,192,5,2,le.audioobjecttype<<3|le.samplingfrequencyindex>>>1,le.samplingfrequencyindex<<7|le.channelcount<<3,6,1,2]))},u=function(){return a(M.ftyp,D,F,D,I)},_=function(le){return a(M.hdlr,G[le])},c=function(le){return a(M.mdat,le)},S=function(le){var Se=new Uint8Array([0,0,0,0,0,0,0,2,0,0,0,3,0,1,95,144,le.duration>>>24&255,le.duration>>>16&255,le.duration>>>8&255,le.duration&255,85,196,0,0]);return le.samplerate&&(Se[12]=le.samplerate>>>24&255,Se[13]=le.samplerate>>>16&255,Se[14]=le.samplerate>>>8&255,Se[15]=le.samplerate&255),a(M.mdhd,Se)},b=function(le){return a(M.mdia,S(le),_(le.type),f(le))},d=function(le){return a(M.mfhd,new Uint8Array([0,0,0,0,(le&4278190080)>>24,(le&16711680)>>16,(le&65280)>>8,le&255]))},f=function(le){return a(M.minf,le.type==="video"?a(M.vmhd,H):a(M.smhd,U),s(),P(le))},h=function(le,Se){for(var be=[],xe=Se.length;xe--;)be[xe]=E(Se[xe]);return a.apply(null,[M.moof,d(le)].concat(be))},p=function(le){for(var Se=le.length,be=[];Se--;)be[Se]=y(le[Se]);return a.apply(null,[M.moov,v(4294967295)].concat(be).concat(g(le)))},g=function(le){for(var Se=le.length,be=[];Se--;)be[Se]=A(le[Se]);return a.apply(null,[M.mvex].concat(be))},v=function(le){var Se=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,2,0,1,95,144,(le&4278190080)>>24,(le&16711680)>>16,(le&65280)>>8,le&255,0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]);return a(M.mvhd,Se)},C=function(le){var Se=le.samples||[],be=new Uint8Array(4+Se.length),xe,Le;for(Le=0;Le<Se.length;Le++)xe=Se[Le].flags,be[Le+4]=xe.dependsOn<<4|xe.isDependedOn<<2|xe.hasRedundancy;return a(M.sdtp,be)},P=function(le){return a(M.stbl,x(le),a(M.stts,te),a(M.stsc,W),a(M.stsz,Y),a(M.stco,X))},(function(){var Ke,le;x=function(be){return a(M.stsd,new Uint8Array([0,0,0,0,0,0,0,1]),be.type==="video"?Ke(be):le(be))},Ke=function(be){var xe=be.sps||[],Le=be.pps||[],je=[],ct=[],ze,at;for(ze=0;ze<xe.length;ze++)je.push((xe[ze].byteLength&65280)>>>8),je.push(xe[ze].byteLength&255),je=je.concat(Array.prototype.slice.call(xe[ze]));for(ze=0;ze<Le.length;ze++)ct.push((Le[ze].byteLength&65280)>>>8),ct.push(Le[ze].byteLength&255),ct=ct.concat(Array.prototype.slice.call(Le[ze]));if(at=[M.avc1,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,(be.width&65280)>>8,be.width&255,(be.height&65280)>>8,be.height&255,0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]),a(M.avcC,new Uint8Array([1,be.profileIdc,be.profileCompatibility,be.levelIdc,255].concat([xe.length],je,[Le.length],ct))),a(M.btrt,new Uint8Array([0,28,156,128,0,45,198,192,0,45,198,192]))],be.sarRatio){var tt=be.sarRatio[0],pt=be.sarRatio[1];at.push(a(M.pasp,new Uint8Array([(tt&4278190080)>>24,(tt&16711680)>>16,(tt&65280)>>8,tt&255,(pt&4278190080)>>24,(pt&16711680)>>16,(pt&65280)>>8,pt&255])))}return a.apply(null,at)},le=function(be){return a(M.mp4a,new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,(be.channelcount&65280)>>8,be.channelcount&255,(be.samplesize&65280)>>8,be.samplesize&255,0,0,0,0,(be.samplerate&65280)>>8,be.samplerate&255,0,0]),l(be))}})(),m=function(le){var Se=new Uint8Array([0,0,0,7,0,0,0,0,0,0,0,0,(le.id&4278190080)>>24,(le.id&16711680)>>16,(le.id&65280)>>8,le.id&255,0,0,0,0,(le.duration&4278190080)>>24,(le.duration&16711680)>>16,(le.duration&65280)>>8,le.duration&255,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,(le.width&65280)>>8,le.width&255,0,0,(le.height&65280)>>8,le.height&255,0,0]);return a(M.tkhd,Se)},E=function(le){var Se,be,xe,Le,je,ct,ze;return Se=a(M.tfhd,new Uint8Array([0,0,0,58,(le.id&4278190080)>>24,(le.id&16711680)>>16,(le.id&65280)>>8,le.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0])),ct=Math.floor(le.baseMediaDecodeTime/o),ze=Math.floor(le.baseMediaDecodeTime%o),be=a(M.tfdt,new Uint8Array([1,0,0,0,ct>>>24&255,ct>>>16&255,ct>>>8&255,ct&255,ze>>>24&255,ze>>>16&255,ze>>>8&255,ze&255])),je=92,le.type==="audio"?(xe=R(le,je),a(M.traf,Se,be,xe)):(Le=C(le),xe=R(le,Le.length+je),a(M.traf,Se,be,xe,Le))},y=function(le){return le.duration=le.duration||4294967295,a(M.trak,m(le),b(le))},A=function(le){var Se=new Uint8Array([0,0,0,0,(le.id&4278190080)>>24,(le.id&16711680)>>16,(le.id&65280)>>8,le.id&255,0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]);return le.type!=="video"&&(Se[Se.length-1]=0),a(M.trex,Se)},(function(){var Ke,le,Se;Se=function(xe,Le){var je=0,ct=0,ze=0,at=0;return xe.length&&(xe[0].duration!==void 0&&(je=1),xe[0].size!==void 0&&(ct=2),xe[0].flags!==void 0&&(ze=4),xe[0].compositionTimeOffset!==void 0&&(at=8)),[0,0,je|ct|ze|at,1,(xe.length&4278190080)>>>24,(xe.length&16711680)>>>16,(xe.length&65280)>>>8,xe.length&255,(Le&4278190080)>>>24,(Le&16711680)>>>16,(Le&65280)>>>8,Le&255]},le=function(xe,Le){var je,ct,ze,at,tt,pt;for(at=xe.samples||[],Le+=20+16*at.length,ze=Se(at,Le),ct=new Uint8Array(ze.length+at.length*16),ct.set(ze),je=ze.length,pt=0;pt<at.length;pt++)tt=at[pt],ct[je++]=(tt.duration&4278190080)>>>24,ct[je++]=(tt.duration&16711680)>>>16,ct[je++]=(tt.duration&65280)>>>8,ct[je++]=tt.duration&255,ct[je++]=(tt.size&4278190080)>>>24,ct[je++]=(tt.size&16711680)>>>16,ct[je++]=(tt.size&65280)>>>8,ct[je++]=tt.size&255,ct[je++]=tt.flags.isLeading<<2|tt.flags.dependsOn,ct[je++]=tt.flags.isDependedOn<<6|tt.flags.hasRedundancy<<4|tt.flags.paddingValue<<1|tt.flags.isNonSyncSample,ct[je++]=tt.flags.degradationPriority&61440,ct[je++]=tt.flags.degradationPriority&15,ct[je++]=(tt.compositionTimeOffset&4278190080)>>>24,ct[je++]=(tt.compositionTimeOffset&16711680)>>>16,ct[je++]=(tt.compositionTimeOffset&65280)>>>8,ct[je++]=tt.compositionTimeOffset&255;return a(M.trun,ct)},Ke=function(xe,Le){var je,ct,ze,at,tt,pt;for(at=xe.samples||[],Le+=20+8*at.length,ze=Se(at,Le),je=new Uint8Array(ze.length+at.length*8),je.set(ze),ct=ze.length,pt=0;pt<at.length;pt++)tt=at[pt],je[ct++]=(tt.duration&4278190080)>>>24,je[ct++]=(tt.duration&16711680)>>>16,je[ct++]=(tt.duration&65280)>>>8,je[ct++]=tt.duration&255,je[ct++]=(tt.size&4278190080)>>>24,je[ct++]=(tt.size&16711680)>>>16,je[ct++]=(tt.size&65280)>>>8,je[ct++]=tt.size&255;return a(M.trun,je)},R=function(xe,Le){return xe.type==="audio"?Ke(xe,Le):le(xe,Le)}})();var oe={ftyp:u,mdat:c,moof:h,moov:p,initSegment:function(le){var Se=u(),be=p(le),xe;return xe=new Uint8Array(Se.byteLength+be.byteLength),xe.set(Se),xe.set(be,Se.byteLength),xe}},de=function(le){var Se,be,xe=[],Le=[];for(Le.byteLength=0,Le.nalCount=0,Le.duration=0,xe.byteLength=0,Se=0;Se<le.length;Se++)be=le[Se],be.nalUnitType==="access_unit_delimiter_rbsp"?(xe.length&&(xe.duration=be.dts-xe.dts,Le.byteLength+=xe.byteLength,Le.nalCount+=xe.length,Le.duration+=xe.duration,Le.push(xe)),xe=[be],xe.byteLength=be.data.byteLength,xe.pts=be.pts,xe.dts=be.dts):(be.nalUnitType==="slice_layer_without_partitioning_rbsp_idr"&&(xe.keyFrame=!0),xe.duration=be.dts-xe.dts,xe.byteLength+=be.data.byteLength,xe.push(be));return Le.length&&(!xe.duration||xe.duration<=0)&&(xe.duration=Le[Le.length-1].duration),Le.byteLength+=xe.byteLength,Le.nalCount+=xe.length,Le.duration+=xe.duration,Le.push(xe),Le},ge=function(le){var Se,be,xe=[],Le=[];for(xe.byteLength=0,xe.nalCount=0,xe.duration=0,xe.pts=le[0].pts,xe.dts=le[0].dts,Le.byteLength=0,Le.nalCount=0,Le.duration=0,Le.pts=le[0].pts,Le.dts=le[0].dts,Se=0;Se<le.length;Se++)be=le[Se],be.keyFrame?(xe.length&&(Le.push(xe),Le.byteLength+=xe.byteLength,Le.nalCount+=xe.nalCount,Le.duration+=xe.duration),xe=[be],xe.nalCount=be.length,xe.byteLength=be.byteLength,xe.pts=be.pts,xe.dts=be.dts,xe.duration=be.duration):(xe.duration+=be.duration,xe.nalCount+=be.length,xe.byteLength+=be.byteLength,xe.push(be));return Le.length&&xe.duration<=0&&(xe.duration=Le[Le.length-1].duration),Le.byteLength+=xe.byteLength,Le.nalCount+=xe.nalCount,Le.duration+=xe.duration,Le.push(xe),Le},Ee=function(le){var Se;return!le[0][0].keyFrame&&le.length>1&&(Se=le.shift(),le.byteLength-=Se.byteLength,le.nalCount-=Se.nalCount,le[0][0].dts=Se.dts,le[0][0].pts=Se.pts,le[0][0].duration+=Se.duration),le},Re=function(){return{size:0,flags:{isLeading:0,dependsOn:1,isDependedOn:0,hasRedundancy:0,degradationPriority:0,isNonSyncSample:1}}},Ae=function(le,Se){var be=Re();return be.dataOffset=Se,be.compositionTimeOffset=le.pts-le.dts,be.duration=le.duration,be.size=4*le.length,be.size+=le.byteLength,le.keyFrame&&(be.flags.dependsOn=2,be.flags.isNonSyncSample=0),be},Pe=function(le,Se){var be,xe,Le,je,ct,ze=Se||0,at=[];for(be=0;be<le.length;be++)for(je=le[be],xe=0;xe<je.length;xe++)ct=je[xe],Le=Ae(ct,ze),ze+=Le.size,at.push(Le);return at},we=function(le){var Se,be,xe,Le,je,ct,ze=0,at=le.byteLength,tt=le.nalCount,pt=at+4*tt,Ut=new Uint8Array(pt),vr=new DataView(Ut.buffer);for(Se=0;Se<le.length;Se++)for(Le=le[Se],be=0;be<Le.length;be++)for(je=Le[be],xe=0;xe<je.length;xe++)ct=je[xe],vr.setUint32(ze,ct.data.byteLength),ze+=4,Ut.set(ct.data,ze),ze+=ct.data.byteLength;return Ut},Te=function(le,Se){var be,xe=Se||0,Le=[];return be=Ae(le,xe),Le.push(be),Le},ke=function(le){var Se,be,xe=0,Le=le.byteLength,je=le.length,ct=Le+4*je,ze=new Uint8Array(ct),at=new DataView(ze.buffer);for(Se=0;Se<le.length;Se++)be=le[Se],at.setUint32(xe,be.data.byteLength),xe+=4,ze.set(be.data,xe),xe+=be.data.byteLength;return ze},$e={groupNalsIntoFrames:de,groupFramesIntoGops:ge,extendFirstKeyFrame:Ee,generateSampleTable:Pe,concatenateNalData:we,generateSampleTableForFrame:Te,concatenateNalDataForFrame:ke},Ne=[33,16,5,32,164,27],ve=[33,65,108,84,1,2,4,8,168,2,4,8,17,191,252],pe=function(le){for(var Se=[];le--;)Se.push(0);return Se},fe=function(le){return Object.keys(le).reduce(function(Se,be){return Se[be]=new Uint8Array(le[be].reduce(function(xe,Le){return xe.concat(Le)},[])),Se},{})},me,Ce=function(){if(!me){var le={96e3:[Ne,[227,64],pe(154),[56]],88200:[Ne,[231],pe(170),[56]],64e3:[Ne,[248,192],pe(240),[56]],48e3:[Ne,[255,192],pe(268),[55,148,128],pe(54),[112]],44100:[Ne,[255,192],pe(268),[55,163,128],pe(84),[112]],32e3:[Ne,[255,192],pe(268),[55,234],pe(226),[112]],24e3:[Ne,[255,192],pe(268),[55,255,128],pe(268),[111,112],pe(126),[224]],16e3:[Ne,[255,192],pe(268),[55,255,128],pe(268),[111,255],pe(269),[223,108],pe(195),[1,192]],12e3:[ve,pe(268),[3,127,248],pe(268),[6,255,240],pe(268),[13,255,224],pe(268),[27,253,128],pe(259),[56]],11025:[ve,pe(268),[3,127,248],pe(268),[6,255,240],pe(268),[13,255,224],pe(268),[27,255,192],pe(268),[55,175,128],pe(108),[112]],8e3:[ve,pe(268),[3,121,16],pe(47),[7]]};me=fe(le)}return me},Ue=9e4,Qe,it,xt,wt,$t,Mt,rt;Qe=function(le){return le*Ue},it=function(le,Se){return le*Se},xt=function(le){return le/Ue},wt=function(le,Se){return le/Se},$t=function(le,Se){return Qe(wt(le,Se))},Mt=function(le,Se){return it(xt(le),Se)},rt=function(le,Se,be){return xt(be?le:le-Se)};var qe={ONE_SECOND_IN_TS:Ue,secondsToVideoTs:Qe,secondsToAudioTs:it,videoTsToSeconds:xt,audioTsToSeconds:wt,audioTsToVideoTs:$t,videoTsToAudioTs:Mt,metadataTsToSeconds:rt},vt=function(le){var Se,be,xe=0;for(Se=0;Se<le.length;Se++)be=le[Se],xe+=be.data.byteLength;return xe},kt=function(le,Se,be,xe){var Le,je=0,ct=0,ze=0,at=0,tt,pt,Ut;if(Se.length&&(Le=qe.audioTsToVideoTs(le.baseMediaDecodeTime,le.samplerate),je=Math.ceil(qe.ONE_SECOND_IN_TS/(le.samplerate/1024)),be&&xe&&(ct=Le-Math.max(be,xe),ze=Math.floor(ct/je),at=ze*je),!(ze<1||at>qe.ONE_SECOND_IN_TS/2))){for(tt=Ce()[le.samplerate],tt||(tt=Se[0].data),pt=0;pt<ze;pt++)Ut=Se[0],Se.splice(0,0,{data:tt,dts:Ut.dts-je,pts:Ut.pts-je});return le.baseMediaDecodeTime-=Math.floor(qe.videoTsToAudioTs(at,le.samplerate)),at}},Xe=function(le,Se,be){return Se.minSegmentDts>=be?le:(Se.minSegmentDts=1/0,le.filter(function(xe){return xe.dts>=be?(Se.minSegmentDts=Math.min(Se.minSegmentDts,xe.dts),Se.minSegmentPts=Se.minSegmentDts,!0):!1}))},_t=function(le){var Se,be,xe=[];for(Se=0;Se<le.length;Se++)be=le[Se],xe.push({size:be.data.byteLength,duration:1024});return xe},Ht=function(le){var Se,be,xe=0,Le=new Uint8Array(vt(le));for(Se=0;Se<le.length;Se++)be=le[Se],Le.set(be.data,xe),xe+=be.data.byteLength;return Le},Pt={prefixWithSilence:kt,trimAdtsFramesByEarliestDts:Xe,generateSampleTable:_t,concatenateFrameData:Ht},Jt=qe.ONE_SECOND_IN_TS,zt=function(le,Se){typeof Se.pts=="number"&&(le.timelineStartInfo.pts===void 0&&(le.timelineStartInfo.pts=Se.pts),le.minSegmentPts===void 0?le.minSegmentPts=Se.pts:le.minSegmentPts=Math.min(le.minSegmentPts,Se.pts),le.maxSegmentPts===void 0?le.maxSegmentPts=Se.pts:le.maxSegmentPts=Math.max(le.maxSegmentPts,Se.pts)),typeof Se.dts=="number"&&(le.timelineStartInfo.dts===void 0&&(le.timelineStartInfo.dts=Se.dts),le.minSegmentDts===void 0?le.minSegmentDts=Se.dts:le.minSegmentDts=Math.min(le.minSegmentDts,Se.dts),le.maxSegmentDts===void 0?le.maxSegmentDts=Se.dts:le.maxSegmentDts=Math.max(le.maxSegmentDts,Se.dts))},Bt=function(le){delete le.minSegmentDts,delete le.maxSegmentDts,delete le.minSegmentPts,delete le.maxSegmentPts},Mr=function(le,Se){var be,xe,Le=le.minSegmentDts;return Se||(Le-=le.timelineStartInfo.dts),be=le.timelineStartInfo.baseMediaDecodeTime,be+=Le,be=Math.max(0,be),le.type==="audio"&&(xe=le.samplerate/Jt,be*=xe,be=Math.floor(be)),be},Be={clearDtsInfo:Bt,calculateTrackBaseMediaDecodeTime:Mr,collectDtsInfo:zt},We=4,dt=128,Tt=function(le){for(var Se=0,be={payloadType:-1,payloadSize:0},xe=0,Le=0;Se<le.byteLength&&le[Se]!==dt;){for(;le[Se]===255;)xe+=255,Se++;for(xe+=le[Se++];le[Se]===255;)Le+=255,Se++;if(Le+=le[Se++],!be.payload&&xe===We){var je=String.fromCharCode(le[Se+3],le[Se+4],le[Se+5],le[Se+6]);if(je==="GA94"){be.payloadType=xe,be.payloadSize=Le,be.payload=le.subarray(Se,Se+Le);break}else be.payload=void 0}Se+=Le,xe=0,Le=0}return be},nr=function(le){return le.payload[0]!==181||(le.payload[1]<<8|le.payload[2])!==49||String.fromCharCode(le.payload[3],le.payload[4],le.payload[5],le.payload[6])!=="GA94"||le.payload[7]!==3?null:le.payload.subarray(8,le.payload.length-1)},Ar=function(le,Se){var be=[],xe,Le,je,ct;if(!(Se[0]&64))return be;for(Le=Se[0]&31,xe=0;xe<Le;xe++)je=xe*3,ct={type:Se[je+2]&3,pts:le},Se[je+2]&4&&(ct.ccData=Se[je+3]<<8|Se[je+4],be.push(ct));return be},Qr=function(le){for(var Se=le.byteLength,be=[],xe=1,Le,je;xe<Se-2;)le[xe]===0&&le[xe+1]===0&&le[xe+2]===3?(be.push(xe+2),xe+=2):xe++;if(be.length===0)return le;Le=Se-be.length,je=new Uint8Array(Le);var ct=0;for(xe=0;xe<Le;ct++,xe++)ct===be[0]&&(ct++,be.shift()),je[xe]=le[ct];return je},Si={parseSei:Tt,parseUserData:nr,parseCaptionPackets:Ar,discardEmulationPreventionBytes:Qr,USER_DATA_REGISTERED_ITU_T_T35:We},oi=function Ke(le){le=le||{},Ke.prototype.init.call(this),this.parse708captions_=typeof le.parse708captions=="boolean"?le.parse708captions:!0,this.captionPackets_=[],this.ccStreams_=[new fr(0,0),new fr(0,1),new fr(1,0),new fr(1,1)],this.parse708captions_&&(this.cc708Stream_=new ri({captionServices:le.captionServices})),this.reset(),this.ccStreams_.forEach(function(Se){Se.on("data",this.trigger.bind(this,"data")),Se.on("partialdone",this.trigger.bind(this,"partialdone")),Se.on("done",this.trigger.bind(this,"done"))},this),this.parse708captions_&&(this.cc708Stream_.on("data",this.trigger.bind(this,"data")),this.cc708Stream_.on("partialdone",this.trigger.bind(this,"partialdone")),this.cc708Stream_.on("done",this.trigger.bind(this,"done")))};oi.prototype=new e,oi.prototype.push=function(Ke){var le,Se,be;if(Ke.nalUnitType==="sei_rbsp"&&(le=Si.parseSei(Ke.escapedRBSP),!!le.payload&&le.payloadType===Si.USER_DATA_REGISTERED_ITU_T_T35&&(Se=Si.parseUserData(le),!!Se))){if(Ke.dts<this.latestDts_){this.ignoreNextEqualDts_=!0;return}else if(Ke.dts===this.latestDts_&&this.ignoreNextEqualDts_){this.numSameDts_--,this.numSameDts_||(this.ignoreNextEqualDts_=!1);return}be=Si.parseCaptionPackets(Ke.pts,Se),this.captionPackets_=this.captionPackets_.concat(be),this.latestDts_!==Ke.dts&&(this.numSameDts_=0),this.numSameDts_++,this.latestDts_=Ke.dts}},oi.prototype.flushCCStreams=function(Ke){this.ccStreams_.forEach(function(le){return Ke==="flush"?le.flush():le.partialFlush()},this)},oi.prototype.flushStream=function(Ke){if(!this.captionPackets_.length){this.flushCCStreams(Ke);return}this.captionPackets_.forEach(function(le,Se){le.presortIndex=Se}),this.captionPackets_.sort(function(le,Se){return le.pts===Se.pts?le.presortIndex-Se.presortIndex:le.pts-Se.pts}),this.captionPackets_.forEach(function(le){le.type<2?this.dispatchCea608Packet(le):this.dispatchCea708Packet(le)},this),this.captionPackets_.length=0,this.flushCCStreams(Ke)},oi.prototype.flush=function(){return this.flushStream("flush")},oi.prototype.partialFlush=function(){return this.flushStream("partialFlush")},oi.prototype.reset=function(){this.latestDts_=null,this.ignoreNextEqualDts_=!1,this.numSameDts_=0,this.activeCea608Channel_=[null,null],this.ccStreams_.forEach(function(Ke){Ke.reset()})},oi.prototype.dispatchCea608Packet=function(Ke){this.setsTextOrXDSActive(Ke)?this.activeCea608Channel_[Ke.type]=null:this.setsChannel1Active(Ke)?this.activeCea608Channel_[Ke.type]=0:this.setsChannel2Active(Ke)&&(this.activeCea608Channel_[Ke.type]=1),this.activeCea608Channel_[Ke.type]!==null&&this.ccStreams_[(Ke.type<<1)+this.activeCea608Channel_[Ke.type]].push(Ke)},oi.prototype.setsChannel1Active=function(Ke){return(Ke.ccData&30720)===4096},oi.prototype.setsChannel2Active=function(Ke){return(Ke.ccData&30720)===6144},oi.prototype.setsTextOrXDSActive=function(Ke){return(Ke.ccData&28928)===256||(Ke.ccData&30974)===4138||(Ke.ccData&30974)===6186},oi.prototype.dispatchCea708Packet=function(Ke){this.parse708captions_&&this.cc708Stream_.push(Ke)};var Yr={127:9834,4128:32,4129:160,4133:8230,4138:352,4140:338,4144:9608,4145:8216,4146:8217,4147:8220,4148:8221,4149:8226,4153:8482,4154:353,4156:339,4157:8480,4159:376,4214:8539,4215:8540,4216:8541,4217:8542,4218:9168,4219:9124,4220:9123,4221:9135,4222:9126,4223:9121,4256:12600},vi=function(le){var Se=Yr[le]||le;return le&4096&&le===Se?"":String.fromCharCode(Se)},rr=function(le){return 32<=le&&le<=127||160<=le&&le<=255},Ji=function(le){this.windowNum=le,this.reset()};Ji.prototype.reset=function(){this.clearText(),this.pendingNewLine=!1,this.winAttr={},this.penAttr={},this.penLoc={},this.penColor={},this.visible=0,this.rowLock=0,this.columnLock=0,this.priority=0,this.relativePositioning=0,this.anchorVertical=0,this.anchorHorizontal=0,this.anchorPoint=0,this.rowCount=1,this.virtualRowCount=this.rowCount+1,this.columnCount=41,this.windowStyle=0,this.penStyle=0},Ji.prototype.getText=function(){return this.rows.join(`
`)},Ji.prototype.clearText=function(){this.rows=[""],this.rowIdx=0},Ji.prototype.newLine=function(Ke){for(this.rows.length>=this.virtualRowCount&&typeof this.beforeRowOverflow=="function"&&this.beforeRowOverflow(Ke),this.rows.length>0&&(this.rows.push(""),this.rowIdx++);this.rows.length>this.virtualRowCount;)this.rows.shift(),this.rowIdx--},Ji.prototype.isEmpty=function(){return this.rows.length===0?!0:this.rows.length===1?this.rows[0]==="":!1},Ji.prototype.addText=function(Ke){this.rows[this.rowIdx]+=Ke},Ji.prototype.backspace=function(){if(!this.isEmpty()){var Ke=this.rows[this.rowIdx];this.rows[this.rowIdx]=Ke.substr(0,Ke.length-1)}};var qn=function(le,Se,be){this.serviceNum=le,this.text="",this.currentWindow=new Ji(-1),this.windows=[],this.stream=be,typeof Se=="string"&&this.createTextDecoder(Se)};qn.prototype.init=function(Ke,le){this.startPts=Ke;for(var Se=0;Se<8;Se++)this.windows[Se]=new Ji(Se),typeof le=="function"&&(this.windows[Se].beforeRowOverflow=le)},qn.prototype.setCurrentWindow=function(Ke){this.currentWindow=this.windows[Ke]},qn.prototype.createTextDecoder=function(Ke){if(typeof TextDecoder>"u")this.stream.trigger("log",{level:"warn",message:"The `encoding` option is unsupported without TextDecoder support"});else try{this.textDecoder_=new TextDecoder(Ke)}catch(le){this.stream.trigger("log",{level:"warn",message:"TextDecoder could not be created with "+Ke+" encoding. "+le})}};var ri=function Ke(le){le=le||{},Ke.prototype.init.call(this);var Se=this,be=le.captionServices||{},xe={},Le;Object.keys(be).forEach(function(je){Le=be[je],/^SERVICE/.test(je)&&(xe[je]=Le.encoding)}),this.serviceEncodings=xe,this.current708Packet=null,this.services={},this.push=function(je){je.type===3?(Se.new708Packet(),Se.add708Bytes(je)):(Se.current708Packet===null&&Se.new708Packet(),Se.add708Bytes(je))}};ri.prototype=new e,ri.prototype.new708Packet=function(){this.current708Packet!==null&&this.push708Packet(),this.current708Packet={data:[],ptsVals:[]}},ri.prototype.add708Bytes=function(Ke){var le=Ke.ccData,Se=le>>>8,be=le&255;this.current708Packet.ptsVals.push(Ke.pts),this.current708Packet.data.push(Se),this.current708Packet.data.push(be)},ri.prototype.push708Packet=function(){var Ke=this.current708Packet,le=Ke.data,Se=null,be=null,xe=0,Le=le[xe++];for(Ke.seq=Le>>6,Ke.sizeCode=Le&63;xe<le.length;xe++)Le=le[xe++],Se=Le>>5,be=Le&31,Se===7&&be>0&&(Le=le[xe++],Se=Le),this.pushServiceBlock(Se,xe,be),be>0&&(xe+=be-1)},ri.prototype.pushServiceBlock=function(Ke,le,Se){var be,xe=le,Le=this.current708Packet.data,je=this.services[Ke];for(je||(je=this.initService(Ke,xe));xe<le+Se&&xe<Le.length;xe++)be=Le[xe],rr(be)?xe=this.handleText(xe,je):be===24?xe=this.multiByteCharacter(xe,je):be===16?xe=this.extendedCommands(xe,je):128<=be&&be<=135?xe=this.setCurrentWindow(xe,je):152<=be&&be<=159?xe=this.defineWindow(xe,je):be===136?xe=this.clearWindows(xe,je):be===140?xe=this.deleteWindows(xe,je):be===137?xe=this.displayWindows(xe,je):be===138?xe=this.hideWindows(xe,je):be===139?xe=this.toggleWindows(xe,je):be===151?xe=this.setWindowAttributes(xe,je):be===144?xe=this.setPenAttributes(xe,je):be===145?xe=this.setPenColor(xe,je):be===146?xe=this.setPenLocation(xe,je):be===143?je=this.reset(xe,je):be===8?je.currentWindow.backspace():be===12?je.currentWindow.clearText():be===13?je.currentWindow.pendingNewLine=!0:be===14?je.currentWindow.clearText():be===141&&xe++},ri.prototype.extendedCommands=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke];return rr(be)&&(Ke=this.handleText(Ke,le,{isExtended:!0})),Ke},ri.prototype.getPts=function(Ke){return this.current708Packet.ptsVals[Math.floor(Ke/2)]},ri.prototype.initService=function(Ke,le){var be="SERVICE"+Ke,Se=this,be,xe;return be in this.serviceEncodings&&(xe=this.serviceEncodings[be]),this.services[Ke]=new qn(Ke,xe,Se),this.services[Ke].init(this.getPts(le),function(Le){Se.flushDisplayed(Le,Se.services[Ke])}),this.services[Ke]},ri.prototype.handleText=function(Ke,le,Se){var be=Se&&Se.isExtended,xe=Se&&Se.isMultiByte,Le=this.current708Packet.data,je=be?4096:0,ct=Le[Ke],ze=Le[Ke+1],at=le.currentWindow,tt,pt;return le.textDecoder_&&!be?(xe?(pt=[ct,ze],Ke++):pt=[ct],tt=le.textDecoder_.decode(new Uint8Array(pt))):tt=vi(je|ct),at.pendingNewLine&&!at.isEmpty()&&at.newLine(this.getPts(Ke)),at.pendingNewLine=!1,at.addText(tt),Ke},ri.prototype.multiByteCharacter=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke+1],xe=Se[Ke+2];return rr(be)&&rr(xe)&&(Ke=this.handleText(++Ke,le,{isMultiByte:!0})),Ke},ri.prototype.setCurrentWindow=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=be&7;return le.setCurrentWindow(xe),Ke},ri.prototype.defineWindow=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=be&7;le.setCurrentWindow(xe);var Le=le.currentWindow;return be=Se[++Ke],Le.visible=(be&32)>>5,Le.rowLock=(be&16)>>4,Le.columnLock=(be&8)>>3,Le.priority=be&7,be=Se[++Ke],Le.relativePositioning=(be&128)>>7,Le.anchorVertical=be&127,be=Se[++Ke],Le.anchorHorizontal=be,be=Se[++Ke],Le.anchorPoint=(be&240)>>4,Le.rowCount=be&15,be=Se[++Ke],Le.columnCount=be&63,be=Se[++Ke],Le.windowStyle=(be&56)>>3,Le.penStyle=be&7,Le.virtualRowCount=Le.rowCount+1,Ke},ri.prototype.setWindowAttributes=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=le.currentWindow.winAttr;return be=Se[++Ke],xe.fillOpacity=(be&192)>>6,xe.fillRed=(be&48)>>4,xe.fillGreen=(be&12)>>2,xe.fillBlue=be&3,be=Se[++Ke],xe.borderType=(be&192)>>6,xe.borderRed=(be&48)>>4,xe.borderGreen=(be&12)>>2,xe.borderBlue=be&3,be=Se[++Ke],xe.borderType+=(be&128)>>5,xe.wordWrap=(be&64)>>6,xe.printDirection=(be&48)>>4,xe.scrollDirection=(be&12)>>2,xe.justify=be&3,be=Se[++Ke],xe.effectSpeed=(be&240)>>4,xe.effectDirection=(be&12)>>2,xe.displayEffect=be&3,Ke},ri.prototype.flushDisplayed=function(Ke,le){for(var Se=[],be=0;be<8;be++)le.windows[be].visible&&!le.windows[be].isEmpty()&&Se.push(le.windows[be].getText());le.endPts=Ke,le.text=Se.join(`

`),this.pushCaption(le),le.startPts=Ke},ri.prototype.pushCaption=function(Ke){Ke.text!==""&&(this.trigger("data",{startPts:Ke.startPts,endPts:Ke.endPts,text:Ke.text,stream:"cc708_"+Ke.serviceNum}),Ke.text="",Ke.startPts=Ke.endPts)},ri.prototype.displayWindows=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke],xe=this.getPts(Ke);this.flushDisplayed(xe,le);for(var Le=0;Le<8;Le++)be&1<<Le&&(le.windows[Le].visible=1);return Ke},ri.prototype.hideWindows=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke],xe=this.getPts(Ke);this.flushDisplayed(xe,le);for(var Le=0;Le<8;Le++)be&1<<Le&&(le.windows[Le].visible=0);return Ke},ri.prototype.toggleWindows=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke],xe=this.getPts(Ke);this.flushDisplayed(xe,le);for(var Le=0;Le<8;Le++)be&1<<Le&&(le.windows[Le].visible^=1);return Ke},ri.prototype.clearWindows=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke],xe=this.getPts(Ke);this.flushDisplayed(xe,le);for(var Le=0;Le<8;Le++)be&1<<Le&&le.windows[Le].clearText();return Ke},ri.prototype.deleteWindows=function(Ke,le){var Se=this.current708Packet.data,be=Se[++Ke],xe=this.getPts(Ke);this.flushDisplayed(xe,le);for(var Le=0;Le<8;Le++)be&1<<Le&&le.windows[Le].reset();return Ke},ri.prototype.setPenAttributes=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=le.currentWindow.penAttr;return be=Se[++Ke],xe.textTag=(be&240)>>4,xe.offset=(be&12)>>2,xe.penSize=be&3,be=Se[++Ke],xe.italics=(be&128)>>7,xe.underline=(be&64)>>6,xe.edgeType=(be&56)>>3,xe.fontStyle=be&7,Ke},ri.prototype.setPenColor=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=le.currentWindow.penColor;return be=Se[++Ke],xe.fgOpacity=(be&192)>>6,xe.fgRed=(be&48)>>4,xe.fgGreen=(be&12)>>2,xe.fgBlue=be&3,be=Se[++Ke],xe.bgOpacity=(be&192)>>6,xe.bgRed=(be&48)>>4,xe.bgGreen=(be&12)>>2,xe.bgBlue=be&3,be=Se[++Ke],xe.edgeRed=(be&48)>>4,xe.edgeGreen=(be&12)>>2,xe.edgeBlue=be&3,Ke},ri.prototype.setPenLocation=function(Ke,le){var Se=this.current708Packet.data,be=Se[Ke],xe=le.currentWindow.penLoc;return le.currentWindow.pendingNewLine=!0,be=Se[++Ke],xe.row=be&15,be=Se[++Ke],xe.column=be&63,Ke},ri.prototype.reset=function(Ke,le){var Se=this.getPts(Ke);return this.flushDisplayed(Se,le),this.initService(le.serviceNum,Ke)};var eo={42:225,92:233,94:237,95:243,96:250,123:231,124:247,125:209,126:241,127:9608,304:174,305:176,306:189,307:191,308:8482,309:162,310:163,311:9834,312:224,313:160,314:232,315:226,316:234,317:238,318:244,319:251,544:193,545:201,546:211,547:218,548:220,549:252,550:8216,551:161,552:42,553:39,554:8212,555:169,556:8480,557:8226,558:8220,559:8221,560:192,561:194,562:199,563:200,564:202,565:203,566:235,567:206,568:207,569:239,570:212,571:217,572:249,573:219,574:171,575:187,800:195,801:227,802:205,803:204,804:236,805:210,806:242,807:213,808:245,809:123,810:125,811:92,812:94,813:95,814:124,815:126,816:196,817:228,818:214,819:246,820:223,821:165,822:164,823:9474,824:197,825:229,826:216,827:248,828:9484,829:9488,830:9492,831:9496},xn=function(le){return le===null?"":(le=eo[le]||le,String.fromCharCode(le))},mt=14,gr=[4352,4384,4608,4640,5376,5408,5632,5664,5888,5920,4096,4864,4896,5120,5152],ce=function(){for(var le=[],Se=mt+1;Se--;)le.push("");return le},fr=function Ke(le,Se){Ke.prototype.init.call(this),this.field_=le||0,this.dataChannel_=Se||0,this.name_="CC"+((this.field_<<1|this.dataChannel_)+1),this.setConstants(),this.reset(),this.push=function(be){var xe,Le,je,ct,ze;if(xe=be.ccData&32639,xe===this.lastControlCode_){this.lastControlCode_=null;return}if((xe&61440)===4096?this.lastControlCode_=xe:xe!==this.PADDING_&&(this.lastControlCode_=null),je=xe>>>8,ct=xe&255,xe!==this.PADDING_)if(xe===this.RESUME_CAPTION_LOADING_)this.mode_="popOn";else if(xe===this.END_OF_CAPTION_)this.mode_="popOn",this.clearFormatting(be.pts),this.flushDisplayed(be.pts),Le=this.displayed_,this.displayed_=this.nonDisplayed_,this.nonDisplayed_=Le,this.startPts_=be.pts;else if(xe===this.ROLL_UP_2_ROWS_)this.rollUpRows_=2,this.setRollUp(be.pts);else if(xe===this.ROLL_UP_3_ROWS_)this.rollUpRows_=3,this.setRollUp(be.pts);else if(xe===this.ROLL_UP_4_ROWS_)this.rollUpRows_=4,this.setRollUp(be.pts);else if(xe===this.CARRIAGE_RETURN_)this.clearFormatting(be.pts),this.flushDisplayed(be.pts),this.shiftRowsUp_(),this.startPts_=be.pts;else if(xe===this.BACKSPACE_)this.mode_==="popOn"?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1);else if(xe===this.ERASE_DISPLAYED_MEMORY_)this.flushDisplayed(be.pts),this.displayed_=ce();else if(xe===this.ERASE_NON_DISPLAYED_MEMORY_)this.nonDisplayed_=ce();else if(xe===this.RESUME_DIRECT_CAPTIONING_)this.mode_!=="paintOn"&&(this.flushDisplayed(be.pts),this.displayed_=ce()),this.mode_="paintOn",this.startPts_=be.pts;else if(this.isSpecialCharacter(je,ct))je=(je&3)<<8,ze=xn(je|ct),this[this.mode_](be.pts,ze),this.column_++;else if(this.isExtCharacter(je,ct))this.mode_==="popOn"?this.nonDisplayed_[this.row_]=this.nonDisplayed_[this.row_].slice(0,-1):this.displayed_[this.row_]=this.displayed_[this.row_].slice(0,-1),je=(je&3)<<8,ze=xn(je|ct),this[this.mode_](be.pts,ze),this.column_++;else if(this.isMidRowCode(je,ct))this.clearFormatting(be.pts),this[this.mode_](be.pts," "),this.column_++,(ct&14)===14&&this.addFormatting(be.pts,["i"]),(ct&1)===1&&this.addFormatting(be.pts,["u"]);else if(this.isOffsetControlCode(je,ct))this.column_+=ct&3;else if(this.isPAC(je,ct)){var at=gr.indexOf(xe&7968);this.mode_==="rollUp"&&(at-this.rollUpRows_+1<0&&(at=this.rollUpRows_-1),this.setRollUp(be.pts,at)),at!==this.row_&&(this.clearFormatting(be.pts),this.row_=at),ct&1&&this.formatting_.indexOf("u")===-1&&this.addFormatting(be.pts,["u"]),(xe&16)===16&&(this.column_=((xe&14)>>1)*4),this.isColorPAC(ct)&&(ct&14)===14&&this.addFormatting(be.pts,["i"])}else this.isNormalChar(je)&&(ct===0&&(ct=null),ze=xn(je),ze+=xn(ct),this[this.mode_](be.pts,ze),this.column_+=ze.length)}};fr.prototype=new e,fr.prototype.flushDisplayed=function(Ke){var le=this.displayed_.map(function(Se,be){try{return Se.trim()}catch{return this.trigger("log",{level:"warn",message:"Skipping a malformed 608 caption at index "+be+"."}),""}},this).join(`
`).replace(/^\n+|\n+$/g,"");le.length&&this.trigger("data",{startPts:this.startPts_,endPts:Ke,text:le,stream:this.name_})},fr.prototype.reset=function(){this.mode_="popOn",this.topRow_=0,this.startPts_=0,this.displayed_=ce(),this.nonDisplayed_=ce(),this.lastControlCode_=null,this.column_=0,this.row_=mt,this.rollUpRows_=2,this.formatting_=[]},fr.prototype.setConstants=function(){this.dataChannel_===0?(this.BASE_=16,this.EXT_=17,this.CONTROL_=(20|this.field_)<<8,this.OFFSET_=23):this.dataChannel_===1&&(this.BASE_=24,this.EXT_=25,this.CONTROL_=(28|this.field_)<<8,this.OFFSET_=31),this.PADDING_=0,this.RESUME_CAPTION_LOADING_=this.CONTROL_|32,this.END_OF_CAPTION_=this.CONTROL_|47,this.ROLL_UP_2_ROWS_=this.CONTROL_|37,this.ROLL_UP_3_ROWS_=this.CONTROL_|38,this.ROLL_UP_4_ROWS_=this.CONTROL_|39,this.CARRIAGE_RETURN_=this.CONTROL_|45,this.RESUME_DIRECT_CAPTIONING_=this.CONTROL_|41,this.BACKSPACE_=this.CONTROL_|33,this.ERASE_DISPLAYED_MEMORY_=this.CONTROL_|44,this.ERASE_NON_DISPLAYED_MEMORY_=this.CONTROL_|46},fr.prototype.isSpecialCharacter=function(Ke,le){return Ke===this.EXT_&&le>=48&&le<=63},fr.prototype.isExtCharacter=function(Ke,le){return(Ke===this.EXT_+1||Ke===this.EXT_+2)&&le>=32&&le<=63},fr.prototype.isMidRowCode=function(Ke,le){return Ke===this.EXT_&&le>=32&&le<=47},fr.prototype.isOffsetControlCode=function(Ke,le){return Ke===this.OFFSET_&&le>=33&&le<=35},fr.prototype.isPAC=function(Ke,le){return Ke>=this.BASE_&&Ke<this.BASE_+8&&le>=64&&le<=127},fr.prototype.isColorPAC=function(Ke){return Ke>=64&&Ke<=79||Ke>=96&&Ke<=127},fr.prototype.isNormalChar=function(Ke){return Ke>=32&&Ke<=127},fr.prototype.setRollUp=function(Ke,le){if(this.mode_!=="rollUp"&&(this.row_=mt,this.mode_="rollUp",this.flushDisplayed(Ke),this.nonDisplayed_=ce(),this.displayed_=ce()),le!==void 0&&le!==this.row_)for(var Se=0;Se<this.rollUpRows_;Se++)this.displayed_[le-Se]=this.displayed_[this.row_-Se],this.displayed_[this.row_-Se]="";le===void 0&&(le=this.row_),this.topRow_=le-this.rollUpRows_+1},fr.prototype.addFormatting=function(Ke,le){this.formatting_=this.formatting_.concat(le);var Se=le.reduce(function(be,xe){return be+"<"+xe+">"},"");this[this.mode_](Ke,Se)},fr.prototype.clearFormatting=function(Ke){if(this.formatting_.length){var le=this.formatting_.reverse().reduce(function(Se,be){return Se+"</"+be+">"},"");this.formatting_=[],this[this.mode_](Ke,le)}},fr.prototype.popOn=function(Ke,le){var Se=this.nonDisplayed_[this.row_];Se+=le,this.nonDisplayed_[this.row_]=Se},fr.prototype.rollUp=function(Ke,le){var Se=this.displayed_[this.row_];Se+=le,this.displayed_[this.row_]=Se},fr.prototype.shiftRowsUp_=function(){var Ke;for(Ke=0;Ke<this.topRow_;Ke++)this.displayed_[Ke]="";for(Ke=this.row_+1;Ke<mt+1;Ke++)this.displayed_[Ke]="";for(Ke=this.topRow_;Ke<this.row_;Ke++)this.displayed_[Ke]=this.displayed_[Ke+1];this.displayed_[this.row_]=""},fr.prototype.paintOn=function(Ke,le){var Se=this.displayed_[this.row_];Se+=le,this.displayed_[this.row_]=Se};var Yt={CaptionStream:oi,Cea608Stream:fr,Cea708Stream:ri},Lr={H264_STREAM_TYPE:27,ADTS_STREAM_TYPE:15,METADATA_STREAM_TYPE:21},Cr=8589934592,zr=4294967296,fi="shared",to=function(le,Se){var be=1;for(le>Se&&(be=-1);Math.abs(Se-le)>zr;)le+=be*Cr;return le},st=function Ke(le){var Se,be;Ke.prototype.init.call(this),this.type_=le||fi,this.push=function(xe){this.type_!==fi&&xe.type!==this.type_||(be===void 0&&(be=xe.dts),xe.dts=to(xe.dts,be),xe.pts=to(xe.pts,be),Se=xe.dts,this.trigger("data",xe))},this.flush=function(){be=Se,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.discontinuity=function(){be=void 0,Se=void 0},this.reset=function(){this.discontinuity(),this.trigger("reset")}};st.prototype=new e;var zo={TimestampRolloverStream:st,handleRollover:to},hi=function(le,Se,be){var xe,Le="";for(xe=Se;xe<be;xe++)Le+="%"+("00"+le[xe].toString(16)).slice(-2);return Le},si=function(le,Se,be){return decodeURIComponent(hi(le,Se,be))},sr=function(le,Se,be){return unescape(hi(le,Se,be))},Ns=function(le){return le[0]<<21|le[1]<<14|le[2]<<7|le[3]},ts={TXXX:function(le){var Se;if(le.data[0]===3){for(Se=1;Se<le.data.length;Se++)if(le.data[Se]===0){le.description=si(le.data,1,Se),le.value=si(le.data,Se+1,le.data.length).replace(/\0*$/,"");break}le.data=le.value}},WXXX:function(le){var Se;if(le.data[0]===3){for(Se=1;Se<le.data.length;Se++)if(le.data[Se]===0){le.description=si(le.data,1,Se),le.url=si(le.data,Se+1,le.data.length);break}}},PRIV:function(le){var Se;for(Se=0;Se<le.data.length;Se++)if(le.data[Se]===0){le.owner=sr(le.data,0,Se);break}le.privateData=le.data.subarray(Se+1),le.data=le.privateData}},Z;Z=function(le){var Se={descriptor:le&&le.descriptor},be=0,xe=[],Le=0,je;if(Z.prototype.init.call(this),this.dispatchType=Lr.METADATA_STREAM_TYPE.toString(16),Se.descriptor)for(je=0;je<Se.descriptor.length;je++)this.dispatchType+=("00"+Se.descriptor[je].toString(16)).slice(-2);this.push=function(ct){var ze,at,tt,pt,Ut,vr;if(ct.type==="timed-metadata"){if(ct.dataAlignmentIndicator&&(Le=0,xe.length=0),xe.length===0&&(ct.data.length<10||ct.data[0]!==73||ct.data[1]!==68||ct.data[2]!==51)){this.trigger("log",{level:"warn",message:"Skipping unrecognized metadata packet"});return}if(xe.push(ct),Le+=ct.data.byteLength,xe.length===1&&(be=Ns(ct.data.subarray(6,10)),be+=10),!(Le<be)){for(ze={data:new Uint8Array(be),frames:[],pts:xe[0].pts,dts:xe[0].dts},Ut=0;Ut<be;)ze.data.set(xe[0].data.subarray(0,be-Ut),Ut),Ut+=xe[0].data.byteLength,Le-=xe[0].data.byteLength,xe.shift();at=10,ze.data[5]&64&&(at+=4,at+=Ns(ze.data.subarray(10,14)),be-=Ns(ze.data.subarray(16,20)));do{if(tt=Ns(ze.data.subarray(at+4,at+8)),tt<1){this.trigger("log",{level:"warn",message:"Malformed ID3 frame encountered. Skipping metadata parsing."});return}if(vr=String.fromCharCode(ze.data[at],ze.data[at+1],ze.data[at+2],ze.data[at+3]),pt={id:vr,data:ze.data.subarray(at+10,at+tt+10)},pt.key=pt.id,ts[pt.id]&&(ts[pt.id](pt),pt.owner==="com.apple.streaming.transportStreamTimestamp")){var Ir=pt.data,Nt=(Ir[3]&1)<<30|Ir[4]<<22|Ir[5]<<14|Ir[6]<<6|Ir[7]>>>2;Nt*=4,Nt+=Ir[7]&3,pt.timeStamp=Nt,ze.pts===void 0&&ze.dts===void 0&&(ze.pts=pt.timeStamp,ze.dts=pt.timeStamp),this.trigger("timestamp",pt)}ze.frames.push(pt),at+=10,at+=tt}while(at<be);this.trigger("data",ze)}}}},Z.prototype=new e;var re=Z,ye=zo.TimestampRolloverStream,Ye,gt,Dt,pr=188,Gr=71;Ye=function(){var le=new Uint8Array(pr),Se=0;Ye.prototype.init.call(this),this.push=function(be){var xe=0,Le=pr,je;for(Se?(je=new Uint8Array(be.byteLength+Se),je.set(le.subarray(0,Se)),je.set(be,Se),Se=0):je=be;Le<je.byteLength;){if(je[xe]===Gr&&je[Le]===Gr){this.trigger("data",je.subarray(xe,Le)),xe+=pr,Le+=pr;continue}xe++,Le++}xe<je.byteLength&&(le.set(je.subarray(xe),0),Se=je.byteLength-xe)},this.flush=function(){Se===pr&&le[0]===Gr&&(this.trigger("data",le),Se=0),this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")},this.reset=function(){Se=0,this.trigger("reset")}},Ye.prototype=new e,gt=function(){var le,Se,be,xe;gt.prototype.init.call(this),xe=this,this.packetsWaitingForPmt=[],this.programMapTable=void 0,le=function(je,ct){var ze=0;ct.payloadUnitStartIndicator&&(ze+=je[ze]+1),ct.type==="pat"?Se(je.subarray(ze),ct):be(je.subarray(ze),ct)},Se=function(je,ct){ct.section_number=je[7],ct.last_section_number=je[8],xe.pmtPid=(je[10]&31)<<8|je[11],ct.pmtPid=xe.pmtPid},be=function(je,ct){var ze,at,tt,pt;if(je[5]&1){for(xe.programMapTable={video:null,audio:null,"timed-metadata":{}},ze=(je[1]&15)<<8|je[2],at=3+ze-4,tt=(je[10]&15)<<8|je[11],pt=12+tt;pt<at;){var Ut=je[pt],vr=(je[pt+1]&31)<<8|je[pt+2];Ut===Lr.H264_STREAM_TYPE&&xe.programMapTable.video===null?xe.programMapTable.video=vr:Ut===Lr.ADTS_STREAM_TYPE&&xe.programMapTable.audio===null?xe.programMapTable.audio=vr:Ut===Lr.METADATA_STREAM_TYPE&&(xe.programMapTable["timed-metadata"][vr]=Ut),pt+=((je[pt+3]&15)<<8|je[pt+4])+5}ct.programMapTable=xe.programMapTable}},this.push=function(Le){var je={},ct=4;if(je.payloadUnitStartIndicator=!!(Le[1]&64),je.pid=Le[1]&31,je.pid<<=8,je.pid|=Le[2],(Le[3]&48)>>>4>1&&(ct+=Le[ct]+1),je.pid===0)je.type="pat",le(Le.subarray(ct),je),this.trigger("data",je);else if(je.pid===this.pmtPid)for(je.type="pmt",le(Le.subarray(ct),je),this.trigger("data",je);this.packetsWaitingForPmt.length;)this.processPes_.apply(this,this.packetsWaitingForPmt.shift());else this.programMapTable===void 0?this.packetsWaitingForPmt.push([Le,ct,je]):this.processPes_(Le,ct,je)},this.processPes_=function(Le,je,ct){ct.pid===this.programMapTable.video?ct.streamType=Lr.H264_STREAM_TYPE:ct.pid===this.programMapTable.audio?ct.streamType=Lr.ADTS_STREAM_TYPE:ct.streamType=this.programMapTable["timed-metadata"][ct.pid],ct.type="pes",ct.data=Le.subarray(je),this.trigger("data",ct)}},gt.prototype=new e,gt.STREAM_TYPES={h264:27,adts:15},Dt=function(){var le=this,Se=!1,be={data:[],size:0},xe={data:[],size:0},Le={data:[],size:0},je,ct=function(tt,pt){var Ut,vr=tt[0]<<16|tt[1]<<8|tt[2];pt.data=new Uint8Array,vr===1&&(pt.packetLength=6+(tt[4]<<8|tt[5]),pt.dataAlignmentIndicator=(tt[6]&4)!==0,Ut=tt[7],Ut&192&&(pt.pts=(tt[9]&14)<<27|(tt[10]&255)<<20|(tt[11]&254)<<12|(tt[12]&255)<<5|(tt[13]&254)>>>3,pt.pts*=4,pt.pts+=(tt[13]&6)>>>1,pt.dts=pt.pts,Ut&64&&(pt.dts=(tt[14]&14)<<27|(tt[15]&255)<<20|(tt[16]&254)<<12|(tt[17]&255)<<5|(tt[18]&254)>>>3,pt.dts*=4,pt.dts+=(tt[18]&6)>>>1)),pt.data=tt.subarray(9+tt[8]))},ze=function(tt,pt,Ut){var vr=new Uint8Array(tt.size),Ir={type:pt},Nt=0,hr=0,Ao=!1,ho;if(!(!tt.data.length||tt.size<9)){for(Ir.trackId=tt.data[0].pid,Nt=0;Nt<tt.data.length;Nt++)ho=tt.data[Nt],vr.set(ho.data,hr),hr+=ho.data.byteLength;ct(vr,Ir),Ao=pt==="video"||Ir.packetLength<=tt.size,(Ut||Ao)&&(tt.size=0,tt.data.length=0),Ao&&le.trigger("data",Ir)}};Dt.prototype.init.call(this),this.push=function(at){({pat:function(){},pes:function(){var pt,Ut;switch(at.streamType){case Lr.H264_STREAM_TYPE:pt=be,Ut="video";break;case Lr.ADTS_STREAM_TYPE:pt=xe,Ut="audio";break;case Lr.METADATA_STREAM_TYPE:pt=Le,Ut="timed-metadata";break;default:return}at.payloadUnitStartIndicator&&ze(pt,Ut,!0),pt.data.push(at),pt.size+=at.data.byteLength},pmt:function(){var pt={type:"metadata",tracks:[]};je=at.programMapTable,je.video!==null&&pt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+je.video,codec:"avc",type:"video"}),je.audio!==null&&pt.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+je.audio,codec:"adts",type:"audio"}),Se=!0,le.trigger("data",pt)}})[at.type]()},this.reset=function(){be.size=0,be.data.length=0,xe.size=0,xe.data.length=0,this.trigger("reset")},this.flushStreams_=function(){ze(be,"video"),ze(xe,"audio"),ze(Le,"timed-metadata")},this.flush=function(){if(!Se&&je){var at={type:"metadata",tracks:[]};je.video!==null&&at.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+je.video,codec:"avc",type:"video"}),je.audio!==null&&at.tracks.push({timelineStartInfo:{baseMediaDecodeTime:0},id:+je.audio,codec:"adts",type:"audio"}),le.trigger("data",at)}Se=!1,this.flushStreams_(),this.trigger("done")}},Dt.prototype=new e;var rn={PAT_PID:0,MP2T_PACKET_LENGTH:pr,TransportPacketStream:Ye,TransportParseStream:gt,ElementaryStream:Dt,TimestampRolloverStream:ye,CaptionStream:Yt.CaptionStream,Cea608Stream:Yt.Cea608Stream,Cea708Stream:Yt.Cea708Stream,MetadataStream:re};for(var ro in Lr)Lr.hasOwnProperty(ro)&&(rn[ro]=Lr[ro]);var na=rn,yl=qe.ONE_SECOND_IN_TS,Ga,ys=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350];Ga=function(le){var Se,be=0;Ga.prototype.init.call(this),this.skipWarn_=function(xe,Le){this.trigger("log",{level:"warn",message:"adts skiping bytes "+xe+" to "+Le+" in frame "+be+" outside syncword"})},this.push=function(xe){var Le=0,je,ct,ze,at,tt;if(le||(be=0),xe.type==="audio"){Se&&Se.length?(ze=Se,Se=new Uint8Array(ze.byteLength+xe.data.byteLength),Se.set(ze),Se.set(xe.data,ze.byteLength)):Se=xe.data;for(var pt;Le+7<Se.length;){if(Se[Le]!==255||(Se[Le+1]&246)!==240){typeof pt!="number"&&(pt=Le),Le++;continue}if(typeof pt=="number"&&(this.skipWarn_(pt,Le),pt=null),ct=(~Se[Le+1]&1)*2,je=(Se[Le+3]&3)<<11|Se[Le+4]<<3|(Se[Le+5]&224)>>5,at=((Se[Le+6]&3)+1)*1024,tt=at*yl/ys[(Se[Le+2]&60)>>>2],Se.byteLength-Le<je)break;this.trigger("data",{pts:xe.pts+be*tt,dts:xe.dts+be*tt,sampleCount:at,audioobjecttype:(Se[Le+2]>>>6&3)+1,channelcount:(Se[Le+2]&1)<<2|(Se[Le+3]&192)>>>6,samplerate:ys[(Se[Le+2]&60)>>>2],samplingfrequencyindex:(Se[Le+2]&60)>>>2,samplesize:16,data:Se.subarray(Le+7+ct,Le+je)}),be++,Le+=je}typeof pt=="number"&&(this.skipWarn_(pt,Le),pt=null),Se=Se.subarray(Le)}},this.flush=function(){be=0,this.trigger("done")},this.reset=function(){Se=void 0,this.trigger("reset")},this.endTimeline=function(){Se=void 0,this.trigger("endedtimeline")}},Ga.prototype=new e;var tc=Ga,rs;rs=function(le){var Se=le.byteLength,be=0,xe=0;this.length=function(){return 8*Se},this.bitsAvailable=function(){return 8*Se+xe},this.loadWord=function(){var Le=le.byteLength-Se,je=new Uint8Array(4),ct=Math.min(4,Se);if(ct===0)throw new Error("no bytes available");je.set(le.subarray(Le,Le+ct)),be=new DataView(je.buffer).getUint32(0),xe=ct*8,Se-=ct},this.skipBits=function(Le){var je;xe>Le?(be<<=Le,xe-=Le):(Le-=xe,je=Math.floor(Le/8),Le-=je*8,Se-=je,this.loadWord(),be<<=Le,xe-=Le)},this.readBits=function(Le){var je=Math.min(xe,Le),ct=be>>>32-je;return xe-=je,xe>0?be<<=je:Se>0&&this.loadWord(),je=Le-je,je>0?ct<<je|this.readBits(je):ct},this.skipLeadingZeros=function(){var Le;for(Le=0;Le<xe;++Le)if((be&2147483648>>>Le)!==0)return be<<=Le,xe-=Le,Le;return this.loadWord(),Le+this.skipLeadingZeros()},this.skipUnsignedExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.skipExpGolomb=function(){this.skipBits(1+this.skipLeadingZeros())},this.readUnsignedExpGolomb=function(){var Le=this.skipLeadingZeros();return this.readBits(Le+1)-1},this.readExpGolomb=function(){var Le=this.readUnsignedExpGolomb();return 1&Le?1+Le>>>1:-1*(Le>>>1)},this.readBoolean=function(){return this.readBits(1)===1},this.readUnsignedByte=function(){return this.readBits(8)},this.loadWord()};var rc=rs,Hl,fu,hu;fu=function(){var le=0,Se,be;fu.prototype.init.call(this),this.push=function(xe){var Le;be?(Le=new Uint8Array(be.byteLength+xe.data.byteLength),Le.set(be),Le.set(xe.data,be.byteLength),be=Le):be=xe.data;for(var je=be.byteLength;le<je-3;le++)if(be[le+2]===1){Se=le+5;break}for(;Se<je;)switch(be[Se]){case 0:if(be[Se-1]!==0){Se+=2;break}else if(be[Se-2]!==0){Se++;break}le+3!==Se-2&&this.trigger("data",be.subarray(le+3,Se-2));do Se++;while(be[Se]!==1&&Se<je);le=Se-2,Se+=3;break;case 1:if(be[Se-1]!==0||be[Se-2]!==0){Se+=3;break}this.trigger("data",be.subarray(le+3,Se-2)),le=Se-2,Se+=3;break;default:Se+=3;break}be=be.subarray(le),Se-=le,le=0},this.reset=function(){be=null,le=0,this.trigger("reset")},this.flush=function(){be&&be.byteLength>3&&this.trigger("data",be.subarray(le+3)),be=null,le=0,this.trigger("done")},this.endTimeline=function(){this.flush(),this.trigger("endedtimeline")}},fu.prototype=new e,hu={100:!0,110:!0,122:!0,244:!0,44:!0,83:!0,86:!0,118:!0,128:!0,138:!0,139:!0,134:!0},Hl=function(){var le=new fu,Se,be,xe,Le,je,ct,ze;Hl.prototype.init.call(this),Se=this,this.push=function(at){at.type==="video"&&(be=at.trackId,xe=at.pts,Le=at.dts,le.push(at))},le.on("data",function(at){var tt={trackId:be,pts:xe,dts:Le,data:at,nalUnitTypeCode:at[0]&31};switch(tt.nalUnitTypeCode){case 5:tt.nalUnitType="slice_layer_without_partitioning_rbsp_idr";break;case 6:tt.nalUnitType="sei_rbsp",tt.escapedRBSP=je(at.subarray(1));break;case 7:tt.nalUnitType="seq_parameter_set_rbsp",tt.escapedRBSP=je(at.subarray(1)),tt.config=ct(tt.escapedRBSP);break;case 8:tt.nalUnitType="pic_parameter_set_rbsp";break;case 9:tt.nalUnitType="access_unit_delimiter_rbsp";break}Se.trigger("data",tt)}),le.on("done",function(){Se.trigger("done")}),le.on("partialdone",function(){Se.trigger("partialdone")}),le.on("reset",function(){Se.trigger("reset")}),le.on("endedtimeline",function(){Se.trigger("endedtimeline")}),this.flush=function(){le.flush()},this.partialFlush=function(){le.partialFlush()},this.reset=function(){le.reset()},this.endTimeline=function(){le.endTimeline()},ze=function(tt,pt){var Ut=8,vr=8,Ir,Nt;for(Ir=0;Ir<tt;Ir++)vr!==0&&(Nt=pt.readExpGolomb(),vr=(Ut+Nt+256)%256),Ut=vr===0?Ut:vr},je=function(tt){for(var pt=tt.byteLength,Ut=[],vr=1,Ir,Nt;vr<pt-2;)tt[vr]===0&&tt[vr+1]===0&&tt[vr+2]===3?(Ut.push(vr+2),vr+=2):vr++;if(Ut.length===0)return tt;Ir=pt-Ut.length,Nt=new Uint8Array(Ir);var hr=0;for(vr=0;vr<Ir;hr++,vr++)hr===Ut[0]&&(hr++,Ut.shift()),Nt[vr]=tt[hr];return Nt},ct=function(tt){var pt=0,Ut=0,vr=0,Ir=0,Nt,hr,Ao,ho,$l,rh,kc,ef,tf,Mn,ya,Po=[1,1],po,so;if(Nt=new rc(tt),hr=Nt.readUnsignedByte(),ho=Nt.readUnsignedByte(),Ao=Nt.readUnsignedByte(),Nt.skipUnsignedExpGolomb(),hu[hr]&&($l=Nt.readUnsignedExpGolomb(),$l===3&&Nt.skipBits(1),Nt.skipUnsignedExpGolomb(),Nt.skipUnsignedExpGolomb(),Nt.skipBits(1),Nt.readBoolean()))for(ya=$l!==3?8:12,so=0;so<ya;so++)Nt.readBoolean()&&(so<6?ze(16,Nt):ze(64,Nt));if(Nt.skipUnsignedExpGolomb(),rh=Nt.readUnsignedExpGolomb(),rh===0)Nt.readUnsignedExpGolomb();else if(rh===1)for(Nt.skipBits(1),Nt.skipExpGolomb(),Nt.skipExpGolomb(),kc=Nt.readUnsignedExpGolomb(),so=0;so<kc;so++)Nt.skipExpGolomb();if(Nt.skipUnsignedExpGolomb(),Nt.skipBits(1),ef=Nt.readUnsignedExpGolomb(),tf=Nt.readUnsignedExpGolomb(),Mn=Nt.readBits(1),Mn===0&&Nt.skipBits(1),Nt.skipBits(1),Nt.readBoolean()&&(pt=Nt.readUnsignedExpGolomb(),Ut=Nt.readUnsignedExpGolomb(),vr=Nt.readUnsignedExpGolomb(),Ir=Nt.readUnsignedExpGolomb()),Nt.readBoolean()&&Nt.readBoolean()){switch(po=Nt.readUnsignedByte(),po){case 1:Po=[1,1];break;case 2:Po=[12,11];break;case 3:Po=[10,11];break;case 4:Po=[16,11];break;case 5:Po=[40,33];break;case 6:Po=[24,11];break;case 7:Po=[20,11];break;case 8:Po=[32,11];break;case 9:Po=[80,33];break;case 10:Po=[18,11];break;case 11:Po=[15,11];break;case 12:Po=[64,33];break;case 13:Po=[160,99];break;case 14:Po=[4,3];break;case 15:Po=[3,2];break;case 16:Po=[2,1];break;case 255:{Po=[Nt.readUnsignedByte()<<8|Nt.readUnsignedByte(),Nt.readUnsignedByte()<<8|Nt.readUnsignedByte()];break}}Po&&Po[0]/Po[1]}return{profileIdc:hr,levelIdc:Ao,profileCompatibility:ho,width:(ef+1)*16-pt*2-Ut*2,height:(2-Mn)*(tf+1)*16-vr*2-Ir*2,sarRatio:Po}}},Hl.prototype=new e;var ic={H264Stream:Hl},rl=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],oa=function(le,Se){var be=le[Se+6]<<21|le[Se+7]<<14|le[Se+8]<<7|le[Se+9],xe=le[Se+5],Le=(xe&16)>>4;return be=be>=0?be:0,Le?be+20:be+10},Wd=function Ke(le,Se){return le.length-Se<10||le[Se]!==73||le[Se+1]!==68||le[Se+2]!==51?Se:(Se+=oa(le,Se),Ke(le,Se))},Ya=function(le){var Se=Wd(le,0);return le.length>=Se+2&&(le[Se]&255)===255&&(le[Se+1]&240)===240&&(le[Se+1]&22)===16},cd=function(le){return le[0]<<21|le[1]<<14|le[2]<<7|le[3]},ml=function(le,Se,be){var xe,Le="";for(xe=Se;xe<be;xe++)Le+="%"+("00"+le[xe].toString(16)).slice(-2);return Le},Fs=function(le,Se,be){return unescape(ml(le,Se,be))},Ul=function(le,Se){var be=(le[Se+5]&224)>>5,xe=le[Se+4]<<3,Le=le[Se+3]&6144;return Le|xe|be},wo=function(le,Se){return le[Se]===73&&le[Se+1]===68&&le[Se+2]===51?"timed-metadata":le[Se]&!0&&(le[Se+1]&240)===240?"audio":null},Ta=function(le){for(var Se=0;Se+5<le.length;){if(le[Se]!==255||(le[Se+1]&246)!==240){Se++;continue}return rl[(le[Se+2]&60)>>>2]}return null},Lo=function(le){var Se,be,xe,Le;Se=10,le[5]&64&&(Se+=4,Se+=cd(le.subarray(10,14)));do{if(be=cd(le.subarray(Se+4,Se+8)),be<1)return null;if(Le=String.fromCharCode(le[Se],le[Se+1],le[Se+2],le[Se+3]),Le==="PRIV"){xe=le.subarray(Se+10,Se+be+10);for(var je=0;je<xe.byteLength;je++)if(xe[je]===0){var ct=Fs(xe,0,je);if(ct==="com.apple.streaming.transportStreamTimestamp"){var ze=xe.subarray(je+1),at=(ze[3]&1)<<30|ze[4]<<22|ze[5]<<14|ze[6]<<6|ze[7]>>>2;return at*=4,at+=ze[7]&3,at}break}}Se+=10,Se+=be}while(Se<le.byteLength);return null},ao={isLikelyAacData:Ya,parseId3TagSize:oa,parseAdtsSize:Ul,parseType:wo,parseSampleRate:Ta,parseAacTimestamp:Lo},bl;bl=function(){var le=new Uint8Array,Se=0;bl.prototype.init.call(this),this.setTimestamp=function(be){Se=be},this.push=function(be){var xe=0,Le=0,je,ct,ze,at;for(le.length?(at=le.length,le=new Uint8Array(be.byteLength+at),le.set(le.subarray(0,at)),le.set(be,at)):le=be;le.length-Le>=3;){if(le[Le]===73&&le[Le+1]===68&&le[Le+2]===51){if(le.length-Le<10||(xe=ao.parseId3TagSize(le,Le),Le+xe>le.length))break;ct={type:"timed-metadata",data:le.subarray(Le,Le+xe)},this.trigger("data",ct),Le+=xe;continue}else if((le[Le]&255)===255&&(le[Le+1]&240)===240){if(le.length-Le<7||(xe=ao.parseAdtsSize(le,Le),Le+xe>le.length))break;ze={type:"audio",data:le.subarray(Le,Le+xe),pts:Se,dts:Se},this.trigger("data",ze),Le+=xe;continue}Le++}je=le.length-Le,je>0?le=le.subarray(Le):le=new Uint8Array},this.reset=function(){le=new Uint8Array,this.trigger("reset")},this.endTimeline=function(){le=new Uint8Array,this.trigger("endedtimeline")}},bl.prototype=new e;var nc=bl,Vu=["audioobjecttype","channelcount","samplerate","samplingfrequencyindex","samplesize"],dd=Vu,xa=["width","height","profileIdc","levelIdc","profileCompatibility","sarRatio"],Fa=xa,va=ic.H264Stream,Gd=ao.isLikelyAacData,Oc=qe.ONE_SECOND_IN_TS,il,aa,Qi,mn,oc=function(le,Se){Se.stream=le,this.trigger("log",Se)},_e=function(le,Se){for(var be=Object.keys(Se),xe=0;xe<be.length;xe++){var Le=be[xe];Le==="headOfPipeline"||!Se[Le].on||Se[Le].on("log",oc.bind(le,Le))}},He=function(le,Se){var be;if(le.length!==Se.length)return!1;for(be=0;be<le.length;be++)if(le[be]!==Se[be])return!1;return!0},et=function(le,Se,be,xe,Le,je){var ct=be-Se,ze=xe-Se,at=Le-be;return{start:{dts:le,pts:le+ct},end:{dts:le+ze,pts:le+at},prependedContentDuration:je,baseMediaDecodeTime:le}};aa=function(le,Se){var be=[],xe,Le=0,je=0,ct=1/0;Se=Se||{},xe=Se.firstSequenceNumber||0,aa.prototype.init.call(this),this.push=function(ze){Be.collectDtsInfo(le,ze),le&&dd.forEach(function(at){le[at]=ze[at]}),be.push(ze)},this.setEarliestDts=function(ze){Le=ze},this.setVideoBaseMediaDecodeTime=function(ze){ct=ze},this.setAudioAppendStart=function(ze){je=ze},this.flush=function(){var ze,at,tt,pt,Ut,vr,Ir;if(be.length===0){this.trigger("done","AudioSegmentStream");return}ze=Pt.trimAdtsFramesByEarliestDts(be,le,Le),le.baseMediaDecodeTime=Be.calculateTrackBaseMediaDecodeTime(le,Se.keepOriginalTimestamps),Ir=Pt.prefixWithSilence(le,ze,je,ct),le.samples=Pt.generateSampleTable(ze),tt=oe.mdat(Pt.concatenateFrameData(ze)),be=[],at=oe.moof(xe,[le]),pt=new Uint8Array(at.byteLength+tt.byteLength),xe++,pt.set(at),pt.set(tt,at.byteLength),Be.clearDtsInfo(le),Ut=Math.ceil(Oc*1024/le.samplerate),ze.length&&(vr=ze.length*Ut,this.trigger("segmentTimingInfo",et(qe.audioTsToVideoTs(le.baseMediaDecodeTime,le.samplerate),ze[0].dts,ze[0].pts,ze[0].dts+vr,ze[0].pts+vr,Ir||0)),this.trigger("timingInfo",{start:ze[0].pts,end:ze[0].pts+vr})),this.trigger("data",{track:le,boxes:pt}),this.trigger("done","AudioSegmentStream")},this.reset=function(){Be.clearDtsInfo(le),be=[],this.trigger("reset")}},aa.prototype=new e,il=function(le,Se){var be,xe=[],Le=[],je,ct;Se=Se||{},be=Se.firstSequenceNumber||0,il.prototype.init.call(this),delete le.minPTS,this.gopCache_=[],this.push=function(ze){Be.collectDtsInfo(le,ze),ze.nalUnitType==="seq_parameter_set_rbsp"&&!je&&(je=ze.config,le.sps=[ze.data],Fa.forEach(function(at){le[at]=je[at]},this)),ze.nalUnitType==="pic_parameter_set_rbsp"&&!ct&&(ct=ze.data,le.pps=[ze.data]),xe.push(ze)},this.flush=function(){for(var ze,at,tt,pt,Ut,vr,Ir=0,Nt,hr;xe.length&&xe[0].nalUnitType!=="access_unit_delimiter_rbsp";)xe.shift();if(xe.length===0){this.resetStream_(),this.trigger("done","VideoSegmentStream");return}if(ze=$e.groupNalsIntoFrames(xe),tt=$e.groupFramesIntoGops(ze),tt[0][0].keyFrame||(at=this.getGopForFusion_(xe[0],le),at?(Ir=at.duration,tt.unshift(at),tt.byteLength+=at.byteLength,tt.nalCount+=at.nalCount,tt.pts=at.pts,tt.dts=at.dts,tt.duration+=at.duration):tt=$e.extendFirstKeyFrame(tt)),Le.length){var Ao;if(Se.alignGopsAtEnd?Ao=this.alignGopsAtEnd_(tt):Ao=this.alignGopsAtStart_(tt),!Ao){this.gopCache_.unshift({gop:tt.pop(),pps:le.pps,sps:le.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),xe=[],this.resetStream_(),this.trigger("done","VideoSegmentStream");return}Be.clearDtsInfo(le),tt=Ao}Be.collectDtsInfo(le,tt),le.samples=$e.generateSampleTable(tt),Ut=oe.mdat($e.concatenateNalData(tt)),le.baseMediaDecodeTime=Be.calculateTrackBaseMediaDecodeTime(le,Se.keepOriginalTimestamps),this.trigger("processedGopsInfo",tt.map(function(ho){return{pts:ho.pts,dts:ho.dts,byteLength:ho.byteLength}})),Nt=tt[0],hr=tt[tt.length-1],this.trigger("segmentTimingInfo",et(le.baseMediaDecodeTime,Nt.dts,Nt.pts,hr.dts+hr.duration,hr.pts+hr.duration,Ir)),this.trigger("timingInfo",{start:tt[0].pts,end:tt[tt.length-1].pts+tt[tt.length-1].duration}),this.gopCache_.unshift({gop:tt.pop(),pps:le.pps,sps:le.sps}),this.gopCache_.length=Math.min(6,this.gopCache_.length),xe=[],this.trigger("baseMediaDecodeTime",le.baseMediaDecodeTime),this.trigger("timelineStartInfo",le.timelineStartInfo),pt=oe.moof(be,[le]),vr=new Uint8Array(pt.byteLength+Ut.byteLength),be++,vr.set(pt),vr.set(Ut,pt.byteLength),this.trigger("data",{track:le,boxes:vr}),this.resetStream_(),this.trigger("done","VideoSegmentStream")},this.reset=function(){this.resetStream_(),xe=[],this.gopCache_.length=0,Le.length=0,this.trigger("reset")},this.resetStream_=function(){Be.clearDtsInfo(le),je=void 0,ct=void 0},this.getGopForFusion_=function(ze){var at=45e3,tt=1/0,pt,Ut,vr,Ir,Nt;for(Nt=0;Nt<this.gopCache_.length;Nt++)Ir=this.gopCache_[Nt],vr=Ir.gop,!(!(le.pps&&He(le.pps[0],Ir.pps[0]))||!(le.sps&&He(le.sps[0],Ir.sps[0])))&&(vr.dts<le.timelineStartInfo.dts||(pt=ze.dts-vr.dts-vr.duration,pt>=-1e4&&pt<=at&&(!Ut||tt>pt)&&(Ut=Ir,tt=pt)));return Ut?Ut.gop:null},this.alignGopsAtStart_=function(ze){var at,tt,pt,Ut,vr,Ir,Nt,hr;for(vr=ze.byteLength,Ir=ze.nalCount,Nt=ze.duration,at=tt=0;at<Le.length&&tt<ze.length&&(pt=Le[at],Ut=ze[tt],pt.pts!==Ut.pts);){if(Ut.pts>pt.pts){at++;continue}tt++,vr-=Ut.byteLength,Ir-=Ut.nalCount,Nt-=Ut.duration}return tt===0?ze:tt===ze.length?null:(hr=ze.slice(tt),hr.byteLength=vr,hr.duration=Nt,hr.nalCount=Ir,hr.pts=hr[0].pts,hr.dts=hr[0].dts,hr)},this.alignGopsAtEnd_=function(ze){var at,tt,pt,Ut,vr,Ir;for(at=Le.length-1,tt=ze.length-1,vr=null,Ir=!1;at>=0&&tt>=0;){if(pt=Le[at],Ut=ze[tt],pt.pts===Ut.pts){Ir=!0;break}if(pt.pts>Ut.pts){at--;continue}at===Le.length-1&&(vr=tt),tt--}if(!Ir&&vr===null)return null;var Nt;if(Ir?Nt=tt:Nt=vr,Nt===0)return ze;var hr=ze.slice(Nt),Ao=hr.reduce(function(ho,$l){return ho.byteLength+=$l.byteLength,ho.duration+=$l.duration,ho.nalCount+=$l.nalCount,ho},{byteLength:0,duration:0,nalCount:0});return hr.byteLength=Ao.byteLength,hr.duration=Ao.duration,hr.nalCount=Ao.nalCount,hr.pts=hr[0].pts,hr.dts=hr[0].dts,hr},this.alignGopsWith=function(ze){Le=ze}},il.prototype=new e,mn=function(le,Se){this.numberOfTracks=0,this.metadataStream=Se,le=le||{},typeof le.remux<"u"?this.remuxTracks=!!le.remux:this.remuxTracks=!0,typeof le.keepOriginalTimestamps=="boolean"?this.keepOriginalTimestamps=le.keepOriginalTimestamps:this.keepOriginalTimestamps=!1,this.pendingTracks=[],this.videoTrack=null,this.pendingBoxes=[],this.pendingCaptions=[],this.pendingMetadata=[],this.pendingBytes=0,this.emittedTracks=0,mn.prototype.init.call(this),this.push=function(be){if(be.text)return this.pendingCaptions.push(be);if(be.frames)return this.pendingMetadata.push(be);this.pendingTracks.push(be.track),this.pendingBytes+=be.boxes.byteLength,be.track.type==="video"&&(this.videoTrack=be.track,this.pendingBoxes.push(be.boxes)),be.track.type==="audio"&&(this.audioTrack=be.track,this.pendingBoxes.unshift(be.boxes))}},mn.prototype=new e,mn.prototype.flush=function(Ke){var le=0,Se={captions:[],captionStreams:{},metadata:[],info:{}},be,xe,Le,je=0,ct;if(this.pendingTracks.length<this.numberOfTracks){if(Ke!=="VideoSegmentStream"&&Ke!=="AudioSegmentStream")return;if(this.remuxTracks)return;if(this.pendingTracks.length===0){this.emittedTracks++,this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0);return}}if(this.videoTrack?(je=this.videoTrack.timelineStartInfo.pts,Fa.forEach(function(ze){Se.info[ze]=this.videoTrack[ze]},this)):this.audioTrack&&(je=this.audioTrack.timelineStartInfo.pts,dd.forEach(function(ze){Se.info[ze]=this.audioTrack[ze]},this)),this.videoTrack||this.audioTrack){for(this.pendingTracks.length===1?Se.type=this.pendingTracks[0].type:Se.type="combined",this.emittedTracks+=this.pendingTracks.length,Le=oe.initSegment(this.pendingTracks),Se.initSegment=new Uint8Array(Le.byteLength),Se.initSegment.set(Le),Se.data=new Uint8Array(this.pendingBytes),ct=0;ct<this.pendingBoxes.length;ct++)Se.data.set(this.pendingBoxes[ct],le),le+=this.pendingBoxes[ct].byteLength;for(ct=0;ct<this.pendingCaptions.length;ct++)be=this.pendingCaptions[ct],be.startTime=qe.metadataTsToSeconds(be.startPts,je,this.keepOriginalTimestamps),be.endTime=qe.metadataTsToSeconds(be.endPts,je,this.keepOriginalTimestamps),Se.captionStreams[be.stream]=!0,Se.captions.push(be);for(ct=0;ct<this.pendingMetadata.length;ct++)xe=this.pendingMetadata[ct],xe.cueTime=qe.metadataTsToSeconds(xe.pts,je,this.keepOriginalTimestamps),Se.metadata.push(xe);for(Se.metadata.dispatchType=this.metadataStream.dispatchType,this.pendingTracks.length=0,this.videoTrack=null,this.pendingBoxes.length=0,this.pendingCaptions.length=0,this.pendingBytes=0,this.pendingMetadata.length=0,this.trigger("data",Se),ct=0;ct<Se.captions.length;ct++)be=Se.captions[ct],this.trigger("caption",be);for(ct=0;ct<Se.metadata.length;ct++)xe=Se.metadata[ct],this.trigger("id3Frame",xe)}this.emittedTracks>=this.numberOfTracks&&(this.trigger("done"),this.emittedTracks=0)},mn.prototype.setRemux=function(Ke){this.remuxTracks=Ke},Qi=function(le){var Se=this,be=!0,xe,Le;Qi.prototype.init.call(this),le=le||{},this.baseMediaDecodeTime=le.baseMediaDecodeTime||0,this.transmuxPipeline_={},this.setupAacPipeline=function(){var je={};this.transmuxPipeline_=je,je.type="aac",je.metadataStream=new na.MetadataStream,je.aacStream=new nc,je.audioTimestampRolloverStream=new na.TimestampRolloverStream("audio"),je.timedMetadataTimestampRolloverStream=new na.TimestampRolloverStream("timed-metadata"),je.adtsStream=new tc,je.coalesceStream=new mn(le,je.metadataStream),je.headOfPipeline=je.aacStream,je.aacStream.pipe(je.audioTimestampRolloverStream).pipe(je.adtsStream),je.aacStream.pipe(je.timedMetadataTimestampRolloverStream).pipe(je.metadataStream).pipe(je.coalesceStream),je.metadataStream.on("timestamp",function(ct){je.aacStream.setTimestamp(ct.timeStamp)}),je.aacStream.on("data",function(ct){ct.type!=="timed-metadata"&&ct.type!=="audio"||je.audioSegmentStream||(Le=Le||{timelineStartInfo:{baseMediaDecodeTime:Se.baseMediaDecodeTime},codec:"adts",type:"audio"},je.coalesceStream.numberOfTracks++,je.audioSegmentStream=new aa(Le,le),je.audioSegmentStream.on("log",Se.getLogTrigger_("audioSegmentStream")),je.audioSegmentStream.on("timingInfo",Se.trigger.bind(Se,"audioTimingInfo")),je.adtsStream.pipe(je.audioSegmentStream).pipe(je.coalesceStream),Se.trigger("trackinfo",{hasAudio:!!Le,hasVideo:!!xe}))}),je.coalesceStream.on("data",this.trigger.bind(this,"data")),je.coalesceStream.on("done",this.trigger.bind(this,"done")),_e(this,je)},this.setupTsPipeline=function(){var je={};this.transmuxPipeline_=je,je.type="ts",je.metadataStream=new na.MetadataStream,je.packetStream=new na.TransportPacketStream,je.parseStream=new na.TransportParseStream,je.elementaryStream=new na.ElementaryStream,je.timestampRolloverStream=new na.TimestampRolloverStream,je.adtsStream=new tc,je.h264Stream=new va,je.captionStream=new na.CaptionStream(le),je.coalesceStream=new mn(le,je.metadataStream),je.headOfPipeline=je.packetStream,je.packetStream.pipe(je.parseStream).pipe(je.elementaryStream).pipe(je.timestampRolloverStream),je.timestampRolloverStream.pipe(je.h264Stream),je.timestampRolloverStream.pipe(je.adtsStream),je.timestampRolloverStream.pipe(je.metadataStream).pipe(je.coalesceStream),je.h264Stream.pipe(je.captionStream).pipe(je.coalesceStream),je.elementaryStream.on("data",function(ct){var ze;if(ct.type==="metadata"){for(ze=ct.tracks.length;ze--;)!xe&&ct.tracks[ze].type==="video"?(xe=ct.tracks[ze],xe.timelineStartInfo.baseMediaDecodeTime=Se.baseMediaDecodeTime):!Le&&ct.tracks[ze].type==="audio"&&(Le=ct.tracks[ze],Le.timelineStartInfo.baseMediaDecodeTime=Se.baseMediaDecodeTime);xe&&!je.videoSegmentStream&&(je.coalesceStream.numberOfTracks++,je.videoSegmentStream=new il(xe,le),je.videoSegmentStream.on("log",Se.getLogTrigger_("videoSegmentStream")),je.videoSegmentStream.on("timelineStartInfo",function(at){Le&&!le.keepOriginalTimestamps&&(Le.timelineStartInfo=at,je.audioSegmentStream.setEarliestDts(at.dts-Se.baseMediaDecodeTime))}),je.videoSegmentStream.on("processedGopsInfo",Se.trigger.bind(Se,"gopInfo")),je.videoSegmentStream.on("segmentTimingInfo",Se.trigger.bind(Se,"videoSegmentTimingInfo")),je.videoSegmentStream.on("baseMediaDecodeTime",function(at){Le&&je.audioSegmentStream.setVideoBaseMediaDecodeTime(at)}),je.videoSegmentStream.on("timingInfo",Se.trigger.bind(Se,"videoTimingInfo")),je.h264Stream.pipe(je.videoSegmentStream).pipe(je.coalesceStream)),Le&&!je.audioSegmentStream&&(je.coalesceStream.numberOfTracks++,je.audioSegmentStream=new aa(Le,le),je.audioSegmentStream.on("log",Se.getLogTrigger_("audioSegmentStream")),je.audioSegmentStream.on("timingInfo",Se.trigger.bind(Se,"audioTimingInfo")),je.audioSegmentStream.on("segmentTimingInfo",Se.trigger.bind(Se,"audioSegmentTimingInfo")),je.adtsStream.pipe(je.audioSegmentStream).pipe(je.coalesceStream)),Se.trigger("trackinfo",{hasAudio:!!Le,hasVideo:!!xe})}}),je.coalesceStream.on("data",this.trigger.bind(this,"data")),je.coalesceStream.on("id3Frame",function(ct){ct.dispatchType=je.metadataStream.dispatchType,Se.trigger("id3Frame",ct)}),je.coalesceStream.on("caption",this.trigger.bind(this,"caption")),je.coalesceStream.on("done",this.trigger.bind(this,"done")),_e(this,je)},this.setBaseMediaDecodeTime=function(je){var ct=this.transmuxPipeline_;le.keepOriginalTimestamps||(this.baseMediaDecodeTime=je),Le&&(Le.timelineStartInfo.dts=void 0,Le.timelineStartInfo.pts=void 0,Be.clearDtsInfo(Le),ct.audioTimestampRolloverStream&&ct.audioTimestampRolloverStream.discontinuity()),xe&&(ct.videoSegmentStream&&(ct.videoSegmentStream.gopCache_=[]),xe.timelineStartInfo.dts=void 0,xe.timelineStartInfo.pts=void 0,Be.clearDtsInfo(xe),ct.captionStream.reset()),ct.timestampRolloverStream&&ct.timestampRolloverStream.discontinuity()},this.setAudioAppendStart=function(je){Le&&this.transmuxPipeline_.audioSegmentStream.setAudioAppendStart(je)},this.setRemux=function(je){var ct=this.transmuxPipeline_;le.remux=je,ct&&ct.coalesceStream&&ct.coalesceStream.setRemux(je)},this.alignGopsWith=function(je){xe&&this.transmuxPipeline_.videoSegmentStream&&this.transmuxPipeline_.videoSegmentStream.alignGopsWith(je)},this.getLogTrigger_=function(je){var ct=this;return function(ze){ze.stream=je,ct.trigger("log",ze)}},this.push=function(je){if(be){var ct=Gd(je);ct&&this.transmuxPipeline_.type!=="aac"?this.setupAacPipeline():!ct&&this.transmuxPipeline_.type!=="ts"&&this.setupTsPipeline(),be=!1}this.transmuxPipeline_.headOfPipeline.push(je)},this.flush=function(){be=!0,this.transmuxPipeline_.headOfPipeline.flush()},this.endTimeline=function(){this.transmuxPipeline_.headOfPipeline.endTimeline()},this.reset=function(){this.transmuxPipeline_.headOfPipeline&&this.transmuxPipeline_.headOfPipeline.reset()},this.resetCaptions=function(){this.transmuxPipeline_.captionStream&&this.transmuxPipeline_.captionStream.reset()}},Qi.prototype=new e;var ht={Transmuxer:Qi},Ft=function(le){return le>>>0},ur=function(le){return("00"+le.toString(16)).slice(-2)},Lt={toUnsigned:Ft,toHexString:ur},Kt=function(le){var Se="";return Se+=String.fromCharCode(le[0]),Se+=String.fromCharCode(le[1]),Se+=String.fromCharCode(le[2]),Se+=String.fromCharCode(le[3]),Se},Zr=Kt,ni=Lt.toUnsigned,pi=function Ke(le,Se){var be=[],xe,Le,je,ct,ze;if(!Se.length)return null;for(xe=0;xe<le.byteLength;)Le=ni(le[xe]<<24|le[xe+1]<<16|le[xe+2]<<8|le[xe+3]),je=Zr(le.subarray(xe+4,xe+8)),ct=Le>1?xe+Le:le.byteLength,je===Se[0]&&(Se.length===1?be.push(le.subarray(xe+8,ct)):(ze=Ke(le.subarray(xe+8,ct),Se.slice(1)),ze.length&&(be=be.concat(ze)))),xe=ct;return be},Oi=pi,Bi=Lt.toUnsigned,ms=r.getUint64,Ba=function(le){var Se={version:le[0],flags:new Uint8Array(le.subarray(1,4))};return Se.version===1?Se.baseMediaDecodeTime=ms(le.subarray(4)):Se.baseMediaDecodeTime=Bi(le[4]<<24|le[5]<<16|le[6]<<8|le[7]),Se},Sl=Ba,zl=function(le){return{isLeading:(le[0]&12)>>>2,dependsOn:le[0]&3,isDependedOn:(le[1]&192)>>>6,hasRedundancy:(le[1]&48)>>>4,paddingValue:(le[1]&14)>>>1,isNonSyncSample:le[1]&1,degradationPriority:le[2]<<8|le[3]}},Hu=zl,fd=function(le){var Se={version:le[0],flags:new Uint8Array(le.subarray(1,4)),samples:[]},be=new DataView(le.buffer,le.byteOffset,le.byteLength),xe=Se.flags[2]&1,Le=Se.flags[2]&4,je=Se.flags[1]&1,ct=Se.flags[1]&2,ze=Se.flags[1]&4,at=Se.flags[1]&8,tt=be.getUint32(4),pt=8,Ut;for(xe&&(Se.dataOffset=be.getInt32(pt),pt+=4),Le&&tt&&(Ut={flags:Hu(le.subarray(pt,pt+4))},pt+=4,je&&(Ut.duration=be.getUint32(pt),pt+=4),ct&&(Ut.size=be.getUint32(pt),pt+=4),at&&(Se.version===1?Ut.compositionTimeOffset=be.getInt32(pt):Ut.compositionTimeOffset=be.getUint32(pt),pt+=4),Se.samples.push(Ut),tt--);tt--;)Ut={},je&&(Ut.duration=be.getUint32(pt),pt+=4),ct&&(Ut.size=be.getUint32(pt),pt+=4),ze&&(Ut.flags=Hu(le.subarray(pt,pt+4)),pt+=4),at&&(Se.version===1?Ut.compositionTimeOffset=be.getInt32(pt):Ut.compositionTimeOffset=be.getUint32(pt),pt+=4),Se.samples.push(Ut);return Se},Bs=fd,jg=function(le){var Se=new DataView(le.buffer,le.byteOffset,le.byteLength),be={version:le[0],flags:new Uint8Array(le.subarray(1,4)),trackId:Se.getUint32(4)},xe=be.flags[2]&1,Le=be.flags[2]&2,je=be.flags[2]&8,ct=be.flags[2]&16,ze=be.flags[2]&32,at=be.flags[0]&65536,tt=be.flags[0]&131072,pt;return pt=8,xe&&(pt+=4,be.baseDataOffset=Se.getUint32(12),pt+=4),Le&&(be.sampleDescriptionIndex=Se.getUint32(pt),pt+=4),je&&(be.defaultSampleDuration=Se.getUint32(pt),pt+=4),ct&&(be.defaultSampleSize=Se.getUint32(pt),pt+=4),ze&&(be.defaultSampleFlags=Se.getUint32(pt)),at&&(be.durationIsEmpty=!0),!xe&&tt&&(be.baseDataOffsetIsMoof=!0),be},js=jg,qf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},hd;typeof window<"u"?hd=window:typeof qf<"u"?hd=qf:typeof self<"u"?hd=self:hd={};var is=hd,Xf=Si.discardEmulationPreventionBytes,Yd=Yt.CaptionStream,ko=function(le,Se){for(var be=le,xe=0;xe<Se.length;xe++){var Le=Se[xe];if(be<Le.size)return Le;be-=Le.size}return null},ac=function(le,Se,be){var xe=new DataView(le.buffer,le.byteOffset,le.byteLength),Le={logs:[],seiNals:[]},je,ct,ze,at;for(ct=0;ct+4<le.length;ct+=ze)if(ze=xe.getUint32(ct),ct+=4,!(ze<=0))switch(le[ct]&31){case 6:var tt=le.subarray(ct+1,ct+1+ze),pt=ko(ct,Se);if(je={nalUnitType:"sei_rbsp",size:ze,data:tt,escapedRBSP:Xf(tt),trackId:be},pt)je.pts=pt.pts,je.dts=pt.dts,at=pt;else if(at)je.pts=at.pts,je.dts=at.dts;else{Le.logs.push({level:"warn",message:"We've encountered a nal unit without data at "+ct+" for trackId "+be+". See mux.js#223."});break}Le.seiNals.push(je);break}return Le},Nh=function(le,Se,be){var xe=Se,Le=be.defaultSampleDuration||0,je=be.defaultSampleSize||0,ct=be.trackId,ze=[];return le.forEach(function(at){var tt=Bs(at),pt=tt.samples;pt.forEach(function(Ut){Ut.duration===void 0&&(Ut.duration=Le),Ut.size===void 0&&(Ut.size=je),Ut.trackId=ct,Ut.dts=xe,Ut.compositionTimeOffset===void 0&&(Ut.compositionTimeOffset=0),typeof xe=="bigint"?(Ut.pts=xe+is.BigInt(Ut.compositionTimeOffset),xe+=is.BigInt(Ut.duration)):(Ut.pts=xe+Ut.compositionTimeOffset,xe+=Ut.duration)}),ze=ze.concat(pt)}),ze},pd=function(le,Se){var be=Oi(le,["moof","traf"]),xe=Oi(le,["mdat"]),Le={},je=[];return xe.forEach(function(ct,ze){var at=be[ze];je.push({mdat:ct,traf:at})}),je.forEach(function(ct){var ze=ct.mdat,at=ct.traf,tt=Oi(at,["tfhd"]),pt=js(tt[0]),Ut=pt.trackId,vr=Oi(at,["tfdt"]),Ir=vr.length>0?Sl(vr[0]).baseMediaDecodeTime:0,Nt=Oi(at,["trun"]),hr,Ao;Se===Ut&&Nt.length>0&&(hr=Nh(Nt,Ir,pt),Ao=ac(ze,hr,Ut),Le[Ut]||(Le[Ut]={seiNals:[],logs:[]}),Le[Ut].seiNals=Le[Ut].seiNals.concat(Ao.seiNals),Le[Ut].logs=Le[Ut].logs.concat(Ao.logs))}),Le},Fh=function(le,Se,be){var xe;if(Se===null)return null;xe=pd(le,Se);var Le=xe[Se]||{};return{seiNals:Le.seiNals,logs:Le.logs,timescale:be}},Vg=function(){var le=!1,Se,be,xe,Le,je,ct;this.isInitialized=function(){return le},this.init=function(ze){Se=new Yd,le=!0,ct=ze?ze.isPartial:!1,Se.on("data",function(at){at.startTime=at.startPts/Le,at.endTime=at.endPts/Le,je.captions.push(at),je.captionStreams[at.stream]=!0}),Se.on("log",function(at){je.logs.push(at)})},this.isNewInit=function(ze,at){return ze&&ze.length===0||at&&typeof at=="object"&&Object.keys(at).length===0?!1:xe!==ze[0]||Le!==at[xe]},this.parse=function(ze,at,tt){var pt;if(this.isInitialized()){if(!at||!tt)return null;if(this.isNewInit(at,tt))xe=at[0],Le=tt[xe];else if(xe===null||!Le)return be.push(ze),null}else return null;for(;be.length>0;){var Ut=be.shift();this.parse(Ut,at,tt)}return pt=Fh(ze,xe,Le),pt&&pt.logs&&(je.logs=je.logs.concat(pt.logs)),pt===null||!pt.seiNals?je.logs.length?{logs:je.logs,captions:[],captionStreams:[]}:null:(this.pushNals(pt.seiNals),this.flushStream(),je)},this.pushNals=function(ze){if(!this.isInitialized()||!ze||ze.length===0)return null;ze.forEach(function(at){Se.push(at)})},this.flushStream=function(){if(!this.isInitialized())return null;ct?Se.partialFlush():Se.flush()},this.clearParsedCaptions=function(){je.captions=[],je.captionStreams={},je.logs=[]},this.resetCaptionStream=function(){if(!this.isInitialized())return null;Se.reset()},this.clearAllCaptions=function(){this.clearParsedCaptions(),this.resetCaptionStream()},this.reset=function(){be=[],xe=null,Le=null,je?this.clearParsedCaptions():je={captions:[],captionStreams:{},logs:[]},this.resetCaptionStream()},this.reset()},Hg=Vg,Kf=Lt.toUnsigned,gd=Lt.toHexString,Zf=r.getUint64,Di,Ip,qd,Xd,sc,Kd;Di=function(le){var Se={},be=Oi(le,["moov","trak"]);return be.reduce(function(xe,Le){var je,ct,ze,at,tt;return je=Oi(Le,["tkhd"])[0],!je||(ct=je[0],ze=ct===0?12:20,at=Kf(je[ze]<<24|je[ze+1]<<16|je[ze+2]<<8|je[ze+3]),tt=Oi(Le,["mdia","mdhd"])[0],!tt)?null:(ct=tt[0],ze=ct===0?12:20,xe[at]=Kf(tt[ze]<<24|tt[ze+1]<<16|tt[ze+2]<<8|tt[ze+3]),xe)},Se)},Ip=function(le,Se){var be;be=Oi(Se,["moof","traf"]);var xe=be.reduce(function(Le,je){var ct=Oi(je,["tfhd"])[0],ze=Kf(ct[4]<<24|ct[5]<<16|ct[6]<<8|ct[7]),at=le[ze]||9e4,tt=Oi(je,["tfdt"])[0],pt=new DataView(tt.buffer,tt.byteOffset,tt.byteLength),Ut;tt[0]===1?Ut=Zf(tt.subarray(4,12)):Ut=pt.getUint32(4);var vr;return typeof Ut=="bigint"?vr=Ut/is.BigInt(at):typeof Ut=="number"&&!isNaN(Ut)&&(vr=Ut/at),vr<Number.MAX_SAFE_INTEGER&&(vr=Number(vr)),vr<Le&&(Le=vr),Le},1/0);return typeof xe=="bigint"||isFinite(xe)?xe:0},qd=function(le,Se){var be=Oi(Se,["moof","traf"]),xe=0,Le=0,je;if(be&&be.length){var ct=Oi(be[0],["tfhd"])[0],ze=Oi(be[0],["trun"])[0],at=Oi(be[0],["tfdt"])[0];if(ct){var tt=js(ct);je=tt.trackId}if(at){var pt=Sl(at);xe=pt.baseMediaDecodeTime}if(ze){var Ut=Bs(ze);Ut.samples&&Ut.samples.length&&(Le=Ut.samples[0].compositionTimeOffset||0)}}var vr=le[je]||9e4;typeof xe=="bigint"&&(Le=is.BigInt(Le),vr=is.BigInt(vr));var Ir=(xe+Le)/vr;return typeof Ir=="bigint"&&Ir<Number.MAX_SAFE_INTEGER&&(Ir=Number(Ir)),Ir},Xd=function(le){var Se=Oi(le,["moov","trak"]),be=[];return Se.forEach(function(xe){var Le=Oi(xe,["mdia","hdlr"]),je=Oi(xe,["tkhd"]);Le.forEach(function(ct,ze){var at=Zr(ct.subarray(8,12)),tt=je[ze],pt,Ut,vr;at==="vide"&&(pt=new DataView(tt.buffer,tt.byteOffset,tt.byteLength),Ut=pt.getUint8(0),vr=Ut===0?pt.getUint32(12):pt.getUint32(20),be.push(vr))})}),be},Kd=function(le){var Se=le[0],be=Se===0?12:20;return Kf(le[be]<<24|le[be+1]<<16|le[be+2]<<8|le[be+3])},sc=function(le){var Se=Oi(le,["moov","trak"]),be=[];return Se.forEach(function(xe){var Le={},je=Oi(xe,["tkhd"])[0],ct,ze;je&&(ct=new DataView(je.buffer,je.byteOffset,je.byteLength),ze=ct.getUint8(0),Le.id=ze===0?ct.getUint32(12):ct.getUint32(20));var at=Oi(xe,["mdia","hdlr"])[0];if(at){var tt=Zr(at.subarray(8,12));tt==="vide"?Le.type="video":tt==="soun"?Le.type="audio":Le.type=tt}var pt=Oi(xe,["mdia","minf","stbl","stsd"])[0];if(pt){var Ut=pt.subarray(8);Le.codec=Zr(Ut.subarray(4,8));var vr=Oi(Ut,[Le.codec])[0],Ir,Nt;vr&&(/^[asm]vc[1-9]$/i.test(Le.codec)?(Ir=vr.subarray(78),Nt=Zr(Ir.subarray(4,8)),Nt==="avcC"&&Ir.length>11?(Le.codec+=".",Le.codec+=gd(Ir[9]),Le.codec+=gd(Ir[10]),Le.codec+=gd(Ir[11])):Le.codec="avc1.4d400d"):/^mp4[a,v]$/i.test(Le.codec)?(Ir=vr.subarray(28),Nt=Zr(Ir.subarray(4,8)),Nt==="esds"&&Ir.length>20&&Ir[19]!==0?(Le.codec+="."+gd(Ir[19]),Le.codec+="."+gd(Ir[20]>>>2&63).replace(/^0/,"")):Le.codec="mp4a.40.2"):Le.codec=Le.codec.toLowerCase())}var hr=Oi(xe,["mdia","mdhd"])[0];hr&&(Le.timescale=Kd(hr)),be.push(Le)}),be};var Jf={findBox:Oi,parseType:Zr,timescale:Di,startTime:Ip,compositionStartTime:qd,videoTrackIds:Xd,tracks:sc,getTimescaleFromMediaHeader:Kd},Bh=function(le){var Se=le[1]&31;return Se<<=8,Se|=le[2],Se},Dc=function(le){return!!(le[1]&64)},Rc=function(le){var Se=0;return(le[3]&48)>>>4>1&&(Se+=le[4]+1),Se},Np=function(le,Se){var be=Bh(le);return be===0?"pat":be===Se?"pmt":Se?"pes":null},Mc=function(le){var Se=Dc(le),be=4+Rc(le);return Se&&(be+=le[be]+1),(le[be+10]&31)<<8|le[be+11]},nl=function(le){var Se={},be=Dc(le),xe=4+Rc(le);if(be&&(xe+=le[xe]+1),!!(le[xe+5]&1)){var Le,je,ct;Le=(le[xe+1]&15)<<8|le[xe+2],je=3+Le-4,ct=(le[xe+10]&15)<<8|le[xe+11];for(var ze=12+ct;ze<je;){var at=xe+ze;Se[(le[at+1]&31)<<8|le[at+2]]=le[at],ze+=((le[at+3]&15)<<8|le[at+4])+5}return Se}},jh=function(le,Se){var be=Bh(le),xe=Se[be];switch(xe){case Lr.H264_STREAM_TYPE:return"video";case Lr.ADTS_STREAM_TYPE:return"audio";case Lr.METADATA_STREAM_TYPE:return"timed-metadata";default:return null}},Zd=function(le){var Se=Dc(le);if(!Se)return null;var be=4+Rc(le);if(be>=le.byteLength)return null;var xe=null,Le;return Le=le[be+7],Le&192&&(xe={},xe.pts=(le[be+9]&14)<<27|(le[be+10]&255)<<20|(le[be+11]&254)<<12|(le[be+12]&255)<<5|(le[be+13]&254)>>>3,xe.pts*=4,xe.pts+=(le[be+13]&6)>>>1,xe.dts=xe.pts,Le&64&&(xe.dts=(le[be+14]&14)<<27|(le[be+15]&255)<<20|(le[be+16]&254)<<12|(le[be+17]&255)<<5|(le[be+18]&254)>>>3,xe.dts*=4,xe.dts+=(le[be+18]&6)>>>1)),xe},Uu=function(le){switch(le){case 5:return"slice_layer_without_partitioning_rbsp_idr";case 6:return"sei_rbsp";case 7:return"seq_parameter_set_rbsp";case 8:return"pic_parameter_set_rbsp";case 9:return"access_unit_delimiter_rbsp";default:return null}},Vh=function(le){for(var Se=4+Rc(le),be=le.subarray(Se),xe=0,Le=0,je=!1,ct;Le<be.byteLength-3;Le++)if(be[Le+2]===1){xe=Le+5;break}for(;xe<be.byteLength;)switch(be[xe]){case 0:if(be[xe-1]!==0){xe+=2;break}else if(be[xe-2]!==0){xe++;break}Le+3!==xe-2&&(ct=Uu(be[Le+3]&31),ct==="slice_layer_without_partitioning_rbsp_idr"&&(je=!0));do xe++;while(be[xe]!==1&&xe<be.length);Le=xe-2,xe+=3;break;case 1:if(be[xe-1]!==0||be[xe-2]!==0){xe+=3;break}ct=Uu(be[Le+3]&31),ct==="slice_layer_without_partitioning_rbsp_idr"&&(je=!0),Le=xe-2,xe+=3;break;default:xe+=3;break}return be=be.subarray(Le),xe-=Le,Le=0,be&&be.byteLength>3&&(ct=Uu(be[Le+3]&31),ct==="slice_layer_without_partitioning_rbsp_idr"&&(je=!0)),je},Jd={parseType:Np,parsePat:Mc,parsePmt:nl,parsePayloadUnitStartIndicator:Dc,parsePesType:jh,parsePesTime:Zd,videoPacketContainsKeyFrame:Vh},pu=zo.handleRollover,io={};io.ts=Jd,io.aac=ao;var gu=qe.ONE_SECOND_IN_TS,ns=188,os=71,Hh=function(le,Se){for(var be=0,xe=ns,Le,je;xe<le.byteLength;){if(le[be]===os&&le[xe]===os){switch(Le=le.subarray(be,xe),je=io.ts.parseType(Le,Se.pid),je){case"pat":Se.pid=io.ts.parsePat(Le);break;case"pmt":var ct=io.ts.parsePmt(Le);Se.table=Se.table||{},Object.keys(ct).forEach(function(ze){Se.table[ze]=ct[ze]});break}be+=ns,xe+=ns;continue}be++,xe++}},Qf=function(le,Se,be){for(var xe=0,Le=ns,je,ct,ze,at,tt,pt=!1;Le<=le.byteLength;){if(le[xe]===os&&(le[Le]===os||Le===le.byteLength)){switch(je=le.subarray(xe,Le),ct=io.ts.parseType(je,Se.pid),ct){case"pes":ze=io.ts.parsePesType(je,Se.table),at=io.ts.parsePayloadUnitStartIndicator(je),ze==="audio"&&at&&(tt=io.ts.parsePesTime(je),tt&&(tt.type="audio",be.audio.push(tt),pt=!0));break}if(pt)break;xe+=ns,Le+=ns;continue}xe++,Le++}for(Le=le.byteLength,xe=Le-ns,pt=!1;xe>=0;){if(le[xe]===os&&(le[Le]===os||Le===le.byteLength)){switch(je=le.subarray(xe,Le),ct=io.ts.parseType(je,Se.pid),ct){case"pes":ze=io.ts.parsePesType(je,Se.table),at=io.ts.parsePayloadUnitStartIndicator(je),ze==="audio"&&at&&(tt=io.ts.parsePesTime(je),tt&&(tt.type="audio",be.audio.push(tt),pt=!0));break}if(pt)break;xe-=ns,Le-=ns;continue}xe--,Le--}},eh=function(le,Se,be){for(var xe=0,Le=ns,je,ct,ze,at,tt,pt,Ut,vr,Ir=!1,Nt={data:[],size:0};Le<le.byteLength;){if(le[xe]===os&&le[Le]===os){switch(je=le.subarray(xe,Le),ct=io.ts.parseType(je,Se.pid),ct){case"pes":if(ze=io.ts.parsePesType(je,Se.table),at=io.ts.parsePayloadUnitStartIndicator(je),ze==="video"&&(at&&!Ir&&(tt=io.ts.parsePesTime(je),tt&&(tt.type="video",be.video.push(tt),Ir=!0)),!be.firstKeyFrame)){if(at&&Nt.size!==0){for(pt=new Uint8Array(Nt.size),Ut=0;Nt.data.length;)vr=Nt.data.shift(),pt.set(vr,Ut),Ut+=vr.byteLength;if(io.ts.videoPacketContainsKeyFrame(pt)){var hr=io.ts.parsePesTime(pt);hr?(be.firstKeyFrame=hr,be.firstKeyFrame.type="video"):console.warn("Failed to extract PTS/DTS from PES at first keyframe. This could be an unusual TS segment, or else mux.js did not parse your TS segment correctly. If you know your TS segments do contain PTS/DTS on keyframes please file a bug report! You can try ffprobe to double check for yourself.")}Nt.size=0}Nt.data.push(je),Nt.size+=je.byteLength}break}if(Ir&&be.firstKeyFrame)break;xe+=ns,Le+=ns;continue}xe++,Le++}for(Le=le.byteLength,xe=Le-ns,Ir=!1;xe>=0;){if(le[xe]===os&&le[Le]===os){switch(je=le.subarray(xe,Le),ct=io.ts.parseType(je,Se.pid),ct){case"pes":ze=io.ts.parsePesType(je,Se.table),at=io.ts.parsePayloadUnitStartIndicator(je),ze==="video"&&at&&(tt=io.ts.parsePesTime(je),tt&&(tt.type="video",be.video.push(tt),Ir=!0));break}if(Ir)break;xe-=ns,Le-=ns;continue}xe--,Le--}},Uh=function(le,Se){if(le.audio&&le.audio.length){var be=Se;(typeof be>"u"||isNaN(be))&&(be=le.audio[0].dts),le.audio.forEach(function(je){je.dts=pu(je.dts,be),je.pts=pu(je.pts,be),je.dtsTime=je.dts/gu,je.ptsTime=je.pts/gu})}if(le.video&&le.video.length){var xe=Se;if((typeof xe>"u"||isNaN(xe))&&(xe=le.video[0].dts),le.video.forEach(function(je){je.dts=pu(je.dts,xe),je.pts=pu(je.pts,xe),je.dtsTime=je.dts/gu,je.ptsTime=je.pts/gu}),le.firstKeyFrame){var Le=le.firstKeyFrame;Le.dts=pu(Le.dts,xe),Le.pts=pu(Le.pts,xe),Le.dtsTime=Le.dts/gu,Le.ptsTime=Le.pts/gu}}},zu=function(le){for(var Se=!1,be=0,xe=null,Le=null,je=0,ct=0,ze;le.length-ct>=3;){var at=io.aac.parseType(le,ct);switch(at){case"timed-metadata":if(le.length-ct<10){Se=!0;break}if(je=io.aac.parseId3TagSize(le,ct),je>le.length){Se=!0;break}Le===null&&(ze=le.subarray(ct,ct+je),Le=io.aac.parseAacTimestamp(ze)),ct+=je;break;case"audio":if(le.length-ct<7){Se=!0;break}if(je=io.aac.parseAdtsSize(le,ct),je>le.length){Se=!0;break}xe===null&&(ze=le.subarray(ct,ct+je),xe=io.aac.parseSampleRate(ze)),be++,ct+=je;break;default:ct++;break}if(Se)return null}if(xe===null||Le===null)return null;var tt=gu/xe,pt={audio:[{type:"audio",dts:Le,pts:Le},{type:"audio",dts:Le+be*1024*tt,pts:Le+be*1024*tt}]};return pt},th=function(le){var Se={pid:null,table:null},be={};Hh(le,Se);for(var xe in Se.table)if(Se.table.hasOwnProperty(xe)){var Le=Se.table[xe];switch(Le){case Lr.H264_STREAM_TYPE:be.video=[],eh(le,Se,be),be.video.length===0&&delete be.video;break;case Lr.ADTS_STREAM_TYPE:be.audio=[],Qf(le,Se,be),be.audio.length===0&&delete be.audio;break}}return be},Ug=function(le,Se){var be=io.aac.isLikelyAacData(le),xe;return be?xe=zu(le):xe=th(le),!xe||!xe.audio&&!xe.video?null:(Uh(xe,Se),xe)},Qd={inspect:Ug,parseAudioPes_:Qf},Fp=function(le,Se){Se.on("data",function(be){var xe=be.initSegment;be.initSegment={data:xe.buffer,byteOffset:xe.byteOffset,byteLength:xe.byteLength};var Le=be.data;be.data=Le.buffer,le.postMessage({action:"data",segment:be,byteOffset:Le.byteOffset,byteLength:Le.byteLength},[be.data])}),Se.on("done",function(be){le.postMessage({action:"done"})}),Se.on("gopInfo",function(be){le.postMessage({action:"gopInfo",gopInfo:be})}),Se.on("videoSegmentTimingInfo",function(be){var xe={start:{decode:qe.videoTsToSeconds(be.start.dts),presentation:qe.videoTsToSeconds(be.start.pts)},end:{decode:qe.videoTsToSeconds(be.end.dts),presentation:qe.videoTsToSeconds(be.end.pts)},baseMediaDecodeTime:qe.videoTsToSeconds(be.baseMediaDecodeTime)};be.prependedContentDuration&&(xe.prependedContentDuration=qe.videoTsToSeconds(be.prependedContentDuration)),le.postMessage({action:"videoSegmentTimingInfo",videoSegmentTimingInfo:xe})}),Se.on("audioSegmentTimingInfo",function(be){var xe={start:{decode:qe.videoTsToSeconds(be.start.dts),presentation:qe.videoTsToSeconds(be.start.pts)},end:{decode:qe.videoTsToSeconds(be.end.dts),presentation:qe.videoTsToSeconds(be.end.pts)},baseMediaDecodeTime:qe.videoTsToSeconds(be.baseMediaDecodeTime)};be.prependedContentDuration&&(xe.prependedContentDuration=qe.videoTsToSeconds(be.prependedContentDuration)),le.postMessage({action:"audioSegmentTimingInfo",audioSegmentTimingInfo:xe})}),Se.on("id3Frame",function(be){le.postMessage({action:"id3Frame",id3Frame:be})}),Se.on("caption",function(be){le.postMessage({action:"caption",caption:be})}),Se.on("trackinfo",function(be){le.postMessage({action:"trackinfo",trackInfo:be})}),Se.on("audioTimingInfo",function(be){le.postMessage({action:"audioTimingInfo",audioTimingInfo:{start:qe.videoTsToSeconds(be.start),end:qe.videoTsToSeconds(be.end)}})}),Se.on("videoTimingInfo",function(be){le.postMessage({action:"videoTimingInfo",videoTimingInfo:{start:qe.videoTsToSeconds(be.start),end:qe.videoTsToSeconds(be.end)}})}),Se.on("log",function(be){le.postMessage({action:"log",log:be})})},Lc=(function(){function Ke(Se,be){this.options=be||{},this.self=Se,this.init()}var le=Ke.prototype;return le.init=function(){this.transmuxer&&this.transmuxer.dispose(),this.transmuxer=new ht.Transmuxer(this.options),Fp(this.self,this.transmuxer)},le.pushMp4Captions=function(be){this.captionParser||(this.captionParser=new Hg,this.captionParser.init());var xe=new Uint8Array(be.data,be.byteOffset,be.byteLength),Le=this.captionParser.parse(xe,be.trackIds,be.timescales);this.self.postMessage({action:"mp4Captions",captions:Le&&Le.captions||[],logs:Le&&Le.logs||[],data:xe.buffer},[xe.buffer])},le.probeMp4StartTime=function(be){var xe=be.timescales,Le=be.data,je=Jf.startTime(xe,Le);this.self.postMessage({action:"probeMp4StartTime",startTime:je,data:Le},[Le.buffer])},le.probeMp4Tracks=function(be){var xe=be.data,Le=Jf.tracks(xe);this.self.postMessage({action:"probeMp4Tracks",tracks:Le,data:xe},[xe.buffer])},le.probeTs=function(be){var xe=be.data,Le=be.baseStartTime,je=typeof Le=="number"&&!isNaN(Le)?Le*qe.ONE_SECOND_IN_TS:void 0,ct=Qd.inspect(xe,je),ze=null;ct&&(ze={hasVideo:ct.video&&ct.video.length===2||!1,hasAudio:ct.audio&&ct.audio.length===2||!1},ze.hasVideo&&(ze.videoStart=ct.video[0].ptsTime),ze.hasAudio&&(ze.audioStart=ct.audio[0].ptsTime)),this.self.postMessage({action:"probeTs",result:ze,data:xe},[xe.buffer])},le.clearAllMp4Captions=function(){this.captionParser&&this.captionParser.clearAllCaptions()},le.clearParsedMp4Captions=function(){this.captionParser&&this.captionParser.clearParsedCaptions()},le.push=function(be){var xe=new Uint8Array(be.data,be.byteOffset,be.byteLength);this.transmuxer.push(xe)},le.reset=function(){this.transmuxer.reset()},le.setTimestampOffset=function(be){var xe=be.timestampOffset||0;this.transmuxer.setBaseMediaDecodeTime(Math.round(qe.secondsToVideoTs(xe)))},le.setAudioAppendStart=function(be){this.transmuxer.setAudioAppendStart(Math.ceil(qe.secondsToVideoTs(be.appendStart)))},le.setRemux=function(be){this.transmuxer.setRemux(be.remux)},le.flush=function(be){this.transmuxer.flush(),self.postMessage({action:"done",type:"transmuxed"})},le.endTimeline=function(){this.transmuxer.endTimeline(),self.postMessage({action:"endedtimeline",type:"transmuxed"})},le.alignGopsWith=function(be){this.transmuxer.alignGopsWith(be.gopsToAlignWith.slice())},Ke})();self.onmessage=function(Ke){if(Ke.data.action==="init"&&Ke.data.options){this.messageHandlers=new Lc(self,Ke.data.options);return}this.messageHandlers||(this.messageHandlers=new Lc(self)),Ke.data&&Ke.data.action&&Ke.data.action!=="init"&&this.messageHandlers[Ke.data.action]&&this.messageHandlers[Ke.data.action](Ke.data)}})),qCt=J2e(YCt),XCt=function(e,i,n){var r=e.data.segment,o=r.type,a=r.initSegment,s=r.captions,l=r.captionStreams,u=r.metadata,c=r.videoFrameDtsTime,d=r.videoFramePtsTime;i.buffer.push({captions:s,captionStreams:l,metadata:u});var f=e.data.segment.boxes||{data:e.data.segment.data},h={type:o,data:new Uint8Array(f.data,f.data.byteOffset,f.data.byteLength),initSegment:new Uint8Array(a.data,a.byteOffset,a.byteLength)};typeof c<"u"&&(h.videoFrameDtsTime=c),typeof d<"u"&&(h.videoFramePtsTime=d),n(h)},KCt=function(e){var i=e.transmuxedData,n=e.callback;i.buffer=[],n(i)},ZCt=function(e,i){i.gopInfo=e.data.gopInfo},tNe=function(e){var i=e.transmuxer,n=e.bytes,r=e.audioAppendStart,o=e.gopsToAlignWith,a=e.remux,s=e.onData,l=e.onTrackInfo,u=e.onAudioTimingInfo,c=e.onVideoTimingInfo,d=e.onVideoSegmentTimingInfo,f=e.onAudioSegmentTimingInfo,h=e.onId3,p=e.onCaptions,g=e.onDone,v=e.onEndedTimeline,y=e.onTransmuxerLog,m=e.isEndOfTimeline,b={buffer:[]},S=m,_=function(E){i.currentTransmux===e&&(E.data.action==="data"&&XCt(E,b,s),E.data.action==="trackinfo"&&l(E.data.trackInfo),E.data.action==="gopInfo"&&ZCt(E,b),E.data.action==="audioTimingInfo"&&u(E.data.audioTimingInfo),E.data.action==="videoTimingInfo"&&c(E.data.videoTimingInfo),E.data.action==="videoSegmentTimingInfo"&&d(E.data.videoSegmentTimingInfo),E.data.action==="audioSegmentTimingInfo"&&f(E.data.audioSegmentTimingInfo),E.data.action==="id3Frame"&&h([E.data.id3Frame],E.data.id3Frame.dispatchType),E.data.action==="caption"&&p(E.data.caption),E.data.action==="endedtimeline"&&(S=!1,v()),E.data.action==="log"&&y(E.data.log),E.data.type==="transmuxed"&&(S||(i.onmessage=null,KCt({transmuxedData:b,callback:g}),rNe(i))))};if(i.onmessage=_,r&&i.postMessage({action:"setAudioAppendStart",appendStart:r}),Array.isArray(o)&&i.postMessage({action:"alignGopsWith",gopsToAlignWith:o}),typeof a<"u"&&i.postMessage({action:"setRemux",remux:a}),n.byteLength){var C=n instanceof ArrayBuffer?n:n.buffer,P=n instanceof ArrayBuffer?0:n.byteOffset;i.postMessage({action:"push",data:C,byteOffset:P,byteLength:n.byteLength},[C])}m&&i.postMessage({action:"endTimeline"}),i.postMessage({action:"flush"})},rNe=function(e){e.currentTransmux=null,e.transmuxQueue.length&&(e.currentTransmux=e.transmuxQueue.shift(),typeof e.currentTransmux=="function"?e.currentTransmux():tNe(e.currentTransmux))},Ode=function(e,i){e.postMessage({action:i}),rNe(e)},iNe=function(e,i){if(!i.currentTransmux){i.currentTransmux=e,Ode(i,e);return}i.transmuxQueue.push(Ode.bind(null,i,e))},JCt=function(e){iNe("reset",e)},QCt=function(e){iNe("endTimeline",e)},nNe=function(e){if(!e.transmuxer.currentTransmux){e.transmuxer.currentTransmux=e,tNe(e);return}e.transmuxer.transmuxQueue.push(e)},eTt=function(e){var i=new qCt;i.currentTransmux=null,i.transmuxQueue=[];var n=i.terminate;return i.terminate=function(){return i.currentTransmux=null,i.transmuxQueue.length=0,n.call(i)},i.postMessage({action:"init",options:e}),i},uq={reset:JCt,endTimeline:QCt,transmux:nNe,createTransmuxer:eTt},kz=function(e){var i=e.transmuxer,n=e.endAction||e.action,r=e.callback,o=Gn({},e,{endAction:null,transmuxer:null,callback:null}),a=function u(c){c.data.action===n&&(i.removeEventListener("message",u),c.data.data&&(c.data.data=new Uint8Array(c.data.data,e.byteOffset||0,e.byteLength||c.data.data.byteLength),e.data&&(e.data=c.data.data)),r(c.data))};if(i.addEventListener("message",a),e.data){var s=e.data instanceof ArrayBuffer;o.byteOffset=s?0:e.data.byteOffset,o.byteLength=e.data.byteLength;var l=[s?e.data:e.data.buffer];i.postMessage(o,l)}else i.postMessage(o)},tm={FAILURE:2,TIMEOUT:-101,ABORTED:-102},rJ=function(e){e.forEach(function(i){i.abort()})},tTt=function(e){return{bandwidth:e.bandwidth,bytesReceived:e.bytesReceived||0,roundTripTime:e.roundTripTime||0}},rTt=function(e){var i=e.target,n=Date.now()-i.requestTime,r={bandwidth:1/0,bytesReceived:0,roundTripTime:n||0};return r.bytesReceived=e.loaded,r.bandwidth=Math.floor(r.bytesReceived/r.roundTripTime*8*1e3),r},rre=function(e,i){return i.timedout?{status:i.status,message:"HLS request timed-out at URL: "+i.uri,code:tm.TIMEOUT,xhr:i}:i.aborted?{status:i.status,message:"HLS request aborted at URL: "+i.uri,code:tm.ABORTED,xhr:i}:e?{status:i.status,message:"HLS request errored at URL: "+i.uri,code:tm.FAILURE,xhr:i}:i.responseType==="arraybuffer"&&i.response.byteLength===0?{status:i.status,message:"Empty HLS response at URL: "+i.uri,code:tm.FAILURE,xhr:i}:null},Dde=function(e,i,n){return function(r,o){var a=o.response,s=rre(r,o);if(s)return n(s,e);if(a.byteLength!==16)return n({status:o.status,message:"Invalid HLS key at URL: "+o.uri,code:tm.FAILURE,xhr:o},e);for(var l=new DataView(a),u=new Uint32Array([l.getUint32(0),l.getUint32(4),l.getUint32(8),l.getUint32(12)]),c=0;c<i.length;c++)i[c].bytes=u;return n(null,e)}},oNe=function(e,i){var n=_te(e.map.bytes);if(n!=="mp4"){var r=e.map.resolvedUri||e.map.uri;return i({internal:!0,message:"Found unsupported "+(n||"unknown")+" container for initialization segment at URL: "+r,code:tm.FAILURE})}kz({action:"probeMp4Tracks",data:e.map.bytes,transmuxer:e.transmuxer,callback:function(a){var s=a.tracks,l=a.data;return e.map.bytes=l,s.forEach(function(u){e.map.tracks=e.map.tracks||{},!e.map.tracks[u.type]&&(e.map.tracks[u.type]=u,typeof u.id=="number"&&u.timescale&&(e.map.timescales=e.map.timescales||{},e.map.timescales[u.id]=u.timescale))}),i(null)}})},iTt=function(e){var i=e.segment,n=e.finishProcessingFn;return function(r,o){var a=rre(r,o);if(a)return n(a,i);var s=new Uint8Array(o.response);if(i.map.key)return i.map.encryptedBytes=s,n(null,i);i.map.bytes=s,oNe(i,function(l){if(l)return l.xhr=o,l.status=o.status,n(l,i);n(null,i)})}},nTt=function(e){var i=e.segment,n=e.finishProcessingFn,r=e.responseType;return function(o,a){var s=rre(o,a);if(s)return n(s,i);var l=r==="arraybuffer"||!a.responseText?a.response:WCt(a.responseText.substring(i.lastReachedChar||0));return i.stats=tTt(a),i.key?i.encryptedBytes=new Uint8Array(l):i.bytes=new Uint8Array(l),n(null,i)}},oTt=function(e){var i=e.segment,n=e.bytes,r=e.trackInfoFn,o=e.timingInfoFn,a=e.videoSegmentTimingInfoFn,s=e.audioSegmentTimingInfoFn,l=e.id3Fn,u=e.captionsFn,c=e.isEndOfTimeline,d=e.endedTimelineFn,f=e.dataFn,h=e.doneFn,p=e.onTransmuxerLog,g=i.map&&i.map.tracks||{},v=!!(g.audio&&g.video),y=o.bind(null,i,"audio","start"),m=o.bind(null,i,"audio","end"),b=o.bind(null,i,"video","start"),S=o.bind(null,i,"video","end"),_=function(){return nNe({bytes:n,transmuxer:i.transmuxer,audioAppendStart:i.audioAppendStart,gopsToAlignWith:i.gopsToAlignWith,remux:v,onData:function(x){x.type=x.type==="combined"?"video":x.type,f(i,x)},onTrackInfo:function(x){r&&(v&&(x.isMuxed=!0),r(i,x))},onAudioTimingInfo:function(x){y&&typeof x.start<"u"&&(y(x.start),y=null),m&&typeof x.end<"u"&&m(x.end)},onVideoTimingInfo:function(x){b&&typeof x.start<"u"&&(b(x.start),b=null),S&&typeof x.end<"u"&&S(x.end)},onVideoSegmentTimingInfo:function(x){a(x)},onAudioSegmentTimingInfo:function(x){s(x)},onId3:function(x,E){l(i,x,E)},onCaptions:function(x){u(i,[x])},isEndOfTimeline:c,onEndedTimeline:function(){d()},onTransmuxerLog:p,onDone:function(x){h&&(x.type=x.type==="combined"?"video":x.type,h(null,i,x))}})};kz({action:"probeTs",transmuxer:i.transmuxer,data:n,baseStartTime:i.baseStartTime,callback:function(P){i.bytes=n=P.data;var x=P.result;x&&(r(i,{hasAudio:x.hasAudio,hasVideo:x.hasVideo,isMuxed:v}),r=null,x.hasAudio&&!v&&y(x.audioStart),x.hasVideo&&b(x.videoStart),y=null,b=null),_()}})},aNe=function(e){var i=e.segment,n=e.bytes,r=e.trackInfoFn,o=e.timingInfoFn,a=e.videoSegmentTimingInfoFn,s=e.audioSegmentTimingInfoFn,l=e.id3Fn,u=e.captionsFn,c=e.isEndOfTimeline,d=e.endedTimelineFn,f=e.dataFn,h=e.doneFn,p=e.onTransmuxerLog,g=new Uint8Array(n);if(C_t(g)){i.isFmp4=!0;var v=i.map.tracks,y={isFmp4:!0,hasVideo:!!v.video,hasAudio:!!v.audio};v.audio&&v.audio.codec&&v.audio.codec!=="enca"&&(y.audioCodec=v.audio.codec),v.video&&v.video.codec&&v.video.codec!=="encv"&&(y.videoCodec=v.video.codec),v.video&&v.audio&&(y.isMuxed=!0),r(i,y);var m=function(S){f(i,{data:g,type:y.hasAudio&&!y.isMuxed?"audio":"video"}),S&&S.length&&u(i,S),h(null,i,{})};kz({action:"probeMp4StartTime",timescales:i.map.timescales,data:g,transmuxer:i.transmuxer,callback:function(S){var _=S.data,C=S.startTime;if(n=_.buffer,i.bytes=g=_,y.hasAudio&&!y.isMuxed&&o(i,"audio","start",C),y.hasVideo&&o(i,"video","start",C),!v.video||!_.byteLength||!i.transmuxer){m();return}kz({action:"pushMp4Captions",endAction:"mp4Captions",transmuxer:i.transmuxer,data:g,timescales:i.map.timescales,trackIds:[v.video.id],callback:function(x){n=x.data.buffer,i.bytes=g=x.data,x.logs.forEach(function(E){p(Vt.mergeOptions(E,{stream:"mp4CaptionParser"}))}),m(x.captions)}})}});return}if(!i.transmuxer){h(null,i,{});return}if(typeof i.container>"u"&&(i.container=_te(g)),i.container!=="ts"&&i.container!=="aac"){r(i,{hasAudio:!1,hasVideo:!1}),h(null,i,{});return}oTt({segment:i,bytes:n,trackInfoFn:r,timingInfoFn:o,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:s,id3Fn:l,captionsFn:u,isEndOfTimeline:c,endedTimelineFn:d,dataFn:f,doneFn:h,onTransmuxerLog:p})},sNe=function(e,i){var n=e.id,r=e.key,o=e.encryptedBytes,a=e.decryptionWorker,s=function u(c){if(c.data.source===n){a.removeEventListener("message",u);var d=c.data.decrypted;i(new Uint8Array(d.bytes,d.byteOffset,d.byteLength))}};a.addEventListener("message",s);var l;r.bytes.slice?l=r.bytes.slice():l=new Uint32Array(Array.prototype.slice.call(r.bytes)),a.postMessage(G2e({source:n,encrypted:o,key:l,iv:r.iv}),[o.buffer,l.buffer])},aTt=function(e){var i=e.decryptionWorker,n=e.segment,r=e.trackInfoFn,o=e.timingInfoFn,a=e.videoSegmentTimingInfoFn,s=e.audioSegmentTimingInfoFn,l=e.id3Fn,u=e.captionsFn,c=e.isEndOfTimeline,d=e.endedTimelineFn,f=e.dataFn,h=e.doneFn,p=e.onTransmuxerLog;sNe({id:n.requestId,key:n.key,encryptedBytes:n.encryptedBytes,decryptionWorker:i},function(g){n.bytes=g,aNe({segment:n,bytes:n.bytes,trackInfoFn:r,timingInfoFn:o,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:s,id3Fn:l,captionsFn:u,isEndOfTimeline:c,endedTimelineFn:d,dataFn:f,doneFn:h,onTransmuxerLog:p})})},sTt=function(e){var i=e.activeXhrs,n=e.decryptionWorker,r=e.trackInfoFn,o=e.timingInfoFn,a=e.videoSegmentTimingInfoFn,s=e.audioSegmentTimingInfoFn,l=e.id3Fn,u=e.captionsFn,c=e.isEndOfTimeline,d=e.endedTimelineFn,f=e.dataFn,h=e.doneFn,p=e.onTransmuxerLog,g=0,v=!1;return function(y,m){if(!v){if(y)return v=!0,rJ(i),h(y,m);if(g+=1,g===i.length){var b=function(){if(m.encryptedBytes)return aTt({decryptionWorker:n,segment:m,trackInfoFn:r,timingInfoFn:o,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:s,id3Fn:l,captionsFn:u,isEndOfTimeline:c,endedTimelineFn:d,dataFn:f,doneFn:h,onTransmuxerLog:p});aNe({segment:m,bytes:m.bytes,trackInfoFn:r,timingInfoFn:o,videoSegmentTimingInfoFn:a,audioSegmentTimingInfoFn:s,id3Fn:l,captionsFn:u,isEndOfTimeline:c,endedTimelineFn:d,dataFn:f,doneFn:h,onTransmuxerLog:p})};if(m.endOfAllRequests=Date.now(),m.map&&m.map.encryptedBytes&&!m.map.bytes)return sNe({decryptionWorker:n,id:m.requestId+"-init",encryptedBytes:m.map.encryptedBytes,key:m.map.key},function(S){m.map.bytes=S,oNe(m,function(_){if(_)return rJ(i),h(_,m);b()})});b()}}}},lTt=function(e){var i=e.loadendState,n=e.abortFn;return function(r){var o=r.target;o.aborted&&n&&!i.calledAbortFn&&(n(),i.calledAbortFn=!0)}},uTt=function(e){var i=e.segment,n=e.progressFn;return function(r){var o=r.target;if(!o.aborted)return i.stats=Vt.mergeOptions(i.stats,rTt(r)),!i.stats.firstBytesReceivedAt&&i.stats.bytesReceived&&(i.stats.firstBytesReceivedAt=Date.now()),n(r,i)}},cTt=function(e){var i=e.xhr,n=e.xhrOptions,r=e.decryptionWorker,o=e.segment,a=e.abortFn,s=e.progressFn,l=e.trackInfoFn,u=e.timingInfoFn,c=e.videoSegmentTimingInfoFn,d=e.audioSegmentTimingInfoFn,f=e.id3Fn,h=e.captionsFn,p=e.isEndOfTimeline,g=e.endedTimelineFn,v=e.dataFn,y=e.doneFn,m=e.onTransmuxerLog,b=[],S=sTt({activeXhrs:b,decryptionWorker:r,trackInfoFn:l,timingInfoFn:u,videoSegmentTimingInfoFn:c,audioSegmentTimingInfoFn:d,id3Fn:f,captionsFn:h,isEndOfTimeline:p,endedTimelineFn:g,dataFn:v,doneFn:y,onTransmuxerLog:m});if(o.key&&!o.key.bytes){var _=[o.key];o.map&&!o.map.bytes&&o.map.key&&o.map.key.resolvedUri===o.key.resolvedUri&&_.push(o.map.key);var C=Vt.mergeOptions(n,{uri:o.key.resolvedUri,responseType:"arraybuffer"}),P=Dde(o,_,S),x=i(C,P);b.push(x)}if(o.map&&!o.map.bytes){var E=o.map.key&&(!o.key||o.key.resolvedUri!==o.map.key.resolvedUri);if(E){var A=Vt.mergeOptions(n,{uri:o.map.key.resolvedUri,responseType:"arraybuffer"}),R=Dde(o,[o.map.key],S),M=i(A,R);b.push(M)}var D=Vt.mergeOptions(n,{uri:o.map.resolvedUri,responseType:"arraybuffer",headers:eJ(o.map)}),F=iTt({segment:o,finishProcessingFn:S}),I=i(D,F);b.push(I)}var V=Vt.mergeOptions(n,{uri:o.part&&o.part.resolvedUri||o.resolvedUri,responseType:"arraybuffer",headers:eJ(o)}),z=nTt({segment:o,finishProcessingFn:S,responseType:V.responseType}),G=i(V,z);G.addEventListener("progress",uTt({segment:o,progressFn:s})),b.push(G);var H={};return b.forEach(function(U){U.addEventListener("loadend",lTt({loadendState:H,abortFn:a}))}),function(){return rJ(b)}},dTt=zv("CodecUtils"),fTt=function(e){var i=e.attributes||{};if(i.CODECS)return Ly(i.CODECS)},lNe=function(e,i){var n=i.attributes||{};return e&&e.mediaGroups&&e.mediaGroups.AUDIO&&n.AUDIO&&e.mediaGroups.AUDIO[n.AUDIO]},hTt=function(e,i){if(!lNe(e,i))return!0;var n=i.attributes||{},r=e.mediaGroups.AUDIO[n.AUDIO];for(var o in r)if(!r[o].uri&&!r[o].playlists)return!0;return!1},Iz=function(e){var i={};return e.forEach(function(n){var r=n.mediaType,o=n.type,a=n.details;i[r]=i[r]||[],i[r].push(aIe(""+o+a))}),Object.keys(i).forEach(function(n){if(i[n].length>1){dTt("multiple "+n+" codecs found as attributes: "+i[n].join(", ")+". Setting playlist codecs to null so that we wait for mux.js to probe segments for real codecs."),i[n]=null;return}i[n]=i[n][0]}),i},Rde=function(e){var i=0;return e.audio&&i++,e.video&&i++,i},Rj=function(e,i){var n=i.attributes||{},r=Iz(fTt(i)||[]);if(lNe(e,i)&&!r.audio&&!hTt(e,i)){var o=Iz(Zbt(e,n.AUDIO)||[]);o.audio&&(r.audio=o.audio)}return r},T4=zv("PlaylistSelector"),Mde=function(e){if(!(!e||!e.playlist)){var i=e.playlist;return JSON.stringify({id:i.id,bandwidth:e.bandwidth,width:e.width,height:e.height,codecs:i.attributes&&i.attributes.CODECS||""})}},Nz=function(e,i){if(!e)return"";var n=Ct.getComputedStyle(e);return n?n[i]:""},XL=function(e,i){var n=e.slice();e.sort(function(r,o){var a=i(r,o);return a===0?n.indexOf(r)-n.indexOf(o):a})},ire=function(e,i){var n,r;return e.attributes.BANDWIDTH&&(n=e.attributes.BANDWIDTH),n=n||Ct.Number.MAX_VALUE,i.attributes.BANDWIDTH&&(r=i.attributes.BANDWIDTH),r=r||Ct.Number.MAX_VALUE,n-r},pTt=function(e,i){var n,r;return e.attributes.RESOLUTION&&e.attributes.RESOLUTION.width&&(n=e.attributes.RESOLUTION.width),n=n||Ct.Number.MAX_VALUE,i.attributes.RESOLUTION&&i.attributes.RESOLUTION.width&&(r=i.attributes.RESOLUTION.width),r=r||Ct.Number.MAX_VALUE,n===r&&e.attributes.BANDWIDTH&&i.attributes.BANDWIDTH?e.attributes.BANDWIDTH-i.attributes.BANDWIDTH:n-r},uNe=function(e,i,n,r,o,a){if(e){var s={bandwidth:i,width:n,height:r,limitRenditionByPlayerDimensions:o},l=e.playlists;wh.isAudioOnly(e)&&(l=a.getAudioTrackPlaylists_(),s.audioOnly=!0);var u=l.map(function(A){var R,M=A.attributes&&A.attributes.RESOLUTION&&A.attributes.RESOLUTION.width,D=A.attributes&&A.attributes.RESOLUTION&&A.attributes.RESOLUTION.height;return R=A.attributes&&A.attributes.BANDWIDTH,R=R||Ct.Number.MAX_VALUE,{bandwidth:R,width:M,height:D,playlist:A}});XL(u,function(A,R){return A.bandwidth-R.bandwidth}),u=u.filter(function(A){return!wh.isIncompatible(A.playlist)});var c=u.filter(function(A){return wh.isEnabled(A.playlist)});c.length||(c=u.filter(function(A){return!wh.isDisabled(A.playlist)}));var d=c.filter(function(A){return A.bandwidth*Pc.BANDWIDTH_VARIANCE<i}),f=d[d.length-1],h=d.filter(function(A){return A.bandwidth===f.bandwidth})[0];if(o===!1){var p=h||c[0]||u[0];if(p&&p.playlist){var g="sortedPlaylistReps";return h&&(g="bandwidthBestRep"),c[0]&&(g="enabledPlaylistReps"),T4("choosing "+Mde(p)+" using "+g+" with options",s),p.playlist}return T4("could not choose a playlist with options",s),null}var v=d.filter(function(A){return A.width&&A.height});XL(v,function(A,R){return A.width-R.width});var y=v.filter(function(A){return A.width===n&&A.height===r});f=y[y.length-1];var m=y.filter(function(A){return A.bandwidth===f.bandwidth})[0],b,S,_;m||(b=v.filter(function(A){return A.width>n||A.height>r}),S=b.filter(function(A){return A.width===b[0].width&&A.height===b[0].height}),f=S[S.length-1],_=S.filter(function(A){return A.bandwidth===f.bandwidth})[0]);var C;if(a.experimentalLeastPixelDiffSelector){var P=v.map(function(A){return A.pixelDiff=Math.abs(A.width-n)+Math.abs(A.height-r),A});XL(P,function(A,R){return A.pixelDiff===R.pixelDiff?R.bandwidth-A.bandwidth:A.pixelDiff-R.pixelDiff}),C=P[0]}var x=C||_||m||h||c[0]||u[0];if(x&&x.playlist){var E="sortedPlaylistReps";return C?E="leastPixelDiffRep":_?E="resolutionPlusOneRep":m?E="resolutionBestRep":h?E="bandwidthBestRep":c[0]&&(E="enabledPlaylistReps"),T4("choosing "+Mde(x)+" using "+E+" with options",s),x.playlist}return T4("could not choose a playlist with options",s),null}},Lde=function(){var e=this.useDevicePixelRatio&&Ct.devicePixelRatio||1;return uNe(this.playlists.master,this.systemBandwidth,parseInt(Nz(this.tech_.el(),"width"),10)*e,parseInt(Nz(this.tech_.el(),"height"),10)*e,this.limitRenditionByPlayerDimensions,this.masterPlaylistController_)},gTt=function(e){var i=-1,n=-1;if(e<0||e>1)throw new Error("Moving average bandwidth decay must be between 0 and 1.");return function(){var r=this.useDevicePixelRatio&&Ct.devicePixelRatio||1;return i<0&&(i=this.systemBandwidth,n=this.systemBandwidth),this.systemBandwidth>0&&this.systemBandwidth!==n&&(i=e*this.systemBandwidth+(1-e)*i,n=this.systemBandwidth),uNe(this.playlists.master,i,parseInt(Nz(this.tech_.el(),"width"),10)*r,parseInt(Nz(this.tech_.el(),"height"),10)*r,this.limitRenditionByPlayerDimensions,this.masterPlaylistController_)}},vTt=function(e){var i=e.master,n=e.currentTime,r=e.bandwidth,o=e.duration,a=e.segmentDuration,s=e.timeUntilRebuffer,l=e.currentTimeline,u=e.syncController,c=i.playlists.filter(function(g){return!wh.isIncompatible(g)}),d=c.filter(wh.isEnabled);d.length||(d=c.filter(function(g){return!wh.isDisabled(g)}));var f=d.filter(wh.hasAttribute.bind(null,"BANDWIDTH")),h=f.map(function(g){var v=u.getSyncPoint(g,o,l,n),y=v?1:2,m=wh.estimateSegmentRequestTime(a,r,g),b=m*y-s;return{playlist:g,rebufferingImpact:b}}),p=h.filter(function(g){return g.rebufferingImpact<=0});return XL(p,function(g,v){return ire(v.playlist,g.playlist)}),p.length?p[0]:(XL(h,function(g,v){return g.rebufferingImpact-v.rebufferingImpact}),h[0]||null)},yTt=function(){var e=this,i=this.playlists.master.playlists.filter(wh.isEnabled);XL(i,function(r,o){return ire(r,o)});var n=i.filter(function(r){return!!Rj(e.playlists.master,r).video});return n[0]||null},mTt=function(e){var i=0,n;return e.bytes&&(n=new Uint8Array(e.bytes),e.segments.forEach(function(r){n.set(r,i),i+=r.byteLength})),n},bTt=function(e,i,n){if(!e[n]){i.trigger({type:"usage",name:"vhs-608"}),i.trigger({type:"usage",name:"hls-608"});var r=n;/^cc708_/.test(n)&&(r="SERVICE"+n.split("_")[1]);var o=i.textTracks().getTrackById(r);if(o)e[n]=o;else{var a=i.options_.vhs&&i.options_.vhs.captionServices||{},s=n,l=n,u=!1,c=a[r];c&&(s=c.label,l=c.language,u=c.default),e[n]=i.addRemoteTextTrack({kind:"captions",id:r,default:u,label:s,language:l},!1).track}}},STt=function(e){var i=e.inbandTextTracks,n=e.captionArray,r=e.timestampOffset;if(n){var o=Ct.WebKitDataCue||Ct.VTTCue;n.forEach(function(a){var s=a.stream;i[s].addCue(new o(a.startTime+r,a.endTime+r,a.text))})}},_Tt=function(e){Object.defineProperties(e.frame,{id:{get:function(){return Vt.log.warn("cue.frame.id is deprecated. Use cue.value.key instead."),e.value.key}},value:{get:function(){return Vt.log.warn("cue.frame.value is deprecated. Use cue.value.data instead."),e.value.data}},privateData:{get:function(){return Vt.log.warn("cue.frame.privateData is deprecated. Use cue.value.data instead."),e.value.data}}})},PTt=function(e){var i=e.inbandTextTracks,n=e.metadataArray,r=e.timestampOffset,o=e.videoDuration;if(n){var a=Ct.WebKitDataCue||Ct.VTTCue,s=i.metadataTrack_;if(s&&(n.forEach(function(h){var p=h.cueTime+r;typeof p!="number"||Ct.isNaN(p)||p<0||!(p<1/0)||h.frames.forEach(function(g){var v=new a(p,p,g.value||g.url||g.data||"");v.frame=g,v.value=g,_Tt(v),s.addCue(v)})}),!(!s.cues||!s.cues.length))){for(var l=s.cues,u=[],c=0;c<l.length;c++)l[c]&&u.push(l[c]);var d=u.reduce(function(h,p){var g=h[p.startTime]||[];return g.push(p),h[p.startTime]=g,h},{}),f=Object.keys(d).sort(function(h,p){return Number(h)-Number(p)});f.forEach(function(h,p){var g=d[h],v=Number(f[p+1])||o;g.forEach(function(y){y.endTime=v})})}}},CTt=function(e,i,n){e.metadataTrack_||(e.metadataTrack_=n.addRemoteTextTrack({kind:"metadata",label:"Timed Metadata"},!1).track,e.metadataTrack_.inBandMetadataTrackDispatchType=i)},uj=function(e,i,n){var r,o;if(n&&n.cues)for(r=n.cues.length;r--;)o=n.cues[r],o.startTime>=e&&o.endTime<=i&&n.removeCue(o)},TTt=function(e){var i=e.cues;if(i)for(var n=0;n<i.length;n++){for(var r=[],o=0,a=0;a<i.length;a++)i[n].startTime===i[a].startTime&&i[n].endTime===i[a].endTime&&i[n].text===i[a].text&&(o++,o>1&&r.push(i[a]));r.length&&r.forEach(function(s){return e.removeCue(s)})}},xTt=function(e,i,n){if(typeof i>"u"||i===null||!e.length)return[];var r=Math.ceil((i-n+3)*_z.ONE_SECOND_IN_TS),o;for(o=0;o<e.length&&!(e[o].pts>r);o++);return e.slice(o)},ETt=function(e,i,n){if(!i.length)return e;if(n)return i.slice();var r=i[0].pts,o=0;for(o;o<e.length&&!(e[o].pts>=r);o++);return e.slice(0,o).concat(i)},wTt=function(e,i,n,r){for(var o=Math.ceil((i-r)*_z.ONE_SECOND_IN_TS),a=Math.ceil((n-r)*_z.ONE_SECOND_IN_TS),s=e.slice(),l=e.length;l--&&!(e[l].pts<=a););if(l===-1)return s;for(var u=l+1;u--&&!(e[u].pts<=o););return u=Math.max(u,0),s.splice(u,l-u+1),s},ATt=function(e,i){if(!e&&!i||!e&&i||e&&!i)return!1;if(e===i)return!0;var n=Object.keys(e).sort(),r=Object.keys(i).sort();if(n.length!==r.length)return!1;for(var o=0;o<n.length;o++){var a=n[o];if(a!==r[o]||e[a]!==i[a])return!1}return!0},cNe=22,OTt=function(e,i,n){i=i||[];for(var r=[],o=0,a=0;a<i.length;a++){var s=i[a];if(e===s.timeline&&(r.push(a),o+=s.duration,o>n))return a}return r.length===0?0:r[r.length-1]},oN=1,DTt=500,kde=function(e){return typeof e=="number"&&isFinite(e)},x4=1/60,RTt=function(e,i,n){return e!=="main"||!i||!n?null:!n.hasAudio&&!n.hasVideo?"Neither audio nor video found in segment.":i.hasVideo&&!n.hasVideo?"Only audio found in segment when we expected video. We can't switch to audio only from a stream that had video. To get rid of this message, please add codec information to the manifest.":!i.hasVideo&&n.hasVideo?"Video found in segment when we expected only audio. We can't switch to a stream with video from an audio only stream. To get rid of this message, please add codec information to the manifest.":null},MTt=function(e,i,n){var r=i-Pc.BACK_BUFFER_LENGTH;e.length&&(r=Math.max(r,e.start(0)));var o=i-n;return Math.min(o,r)},sL=function(e){var i=e.startOfSegment,n=e.duration,r=e.segment,o=e.part,a=e.playlist,s=a.mediaSequence,l=a.id,u=a.segments,c=u===void 0?[]:u,d=e.mediaIndex,f=e.partIndex,h=e.timeline,p=c.length-1,g="mediaIndex/partIndex increment";e.getMediaInfoForTime?g="getMediaInfoForTime ("+e.getMediaInfoForTime+")":e.isSyncRequest&&(g="getSyncSegmentCandidate (isSyncRequest)"),e.independent&&(g+=" with independent "+e.independent);var v=typeof f=="number",y=e.segment.uri?"segment":"pre-segment",m=v?M2e({preloadSegment:r})-1:0;return y+" ["+(s+d)+"/"+(s+p)+"]"+(v?" part ["+f+"/"+m+"]":"")+(" segment start/end ["+r.start+" => "+r.end+"]")+(v?" part start/end ["+o.start+" => "+o.end+"]":"")+(" startOfSegment ["+i+"]")+(" duration ["+n+"]")+(" timeline ["+h+"]")+(" selected by ["+g+"]")+(" playlist ["+l+"]")},Ide=function(e){return e+"TimingInfo"},LTt=function(e){var i=e.segmentTimeline,n=e.currentTimeline,r=e.startOfSegment,o=e.buffered,a=e.overrideCheck;return!a&&i===n?null:i<n?r:o.length?o.end(o.length-1):r},Nde=function(e){var i=e.timelineChangeController,n=e.currentTimeline,r=e.segmentTimeline,o=e.loaderType,a=e.audioDisabled;if(n===r)return!1;if(o==="audio"){var s=i.lastTimelineChange({type:"main"});return!s||s.to!==r}if(o==="main"&&a){var l=i.pendingTimelineChange({type:"audio"});return!(l&&l.to===r)}return!1},kTt=function(e){var i=0;return["video","audio"].forEach(function(n){var r=e[n+"TimingInfo"];if(r){var o=r.start,a=r.end,s;typeof o=="bigint"||typeof a=="bigint"?s=Ct.BigInt(a)-Ct.BigInt(o):typeof o=="number"&&typeof a=="number"&&(s=a-o),typeof s<"u"&&s>i&&(i=s)}}),typeof i=="bigint"&&i<Number.MAX_SAFE_INTEGER&&(i=Number(i)),i},Fde=function(e){var i=e.segmentDuration,n=e.maxDuration;return i?Math.round(i)>n+OP:!1},ITt=function(e,i){if(i!=="hls")return null;var n=kTt({audioTimingInfo:e.audioTimingInfo,videoTimingInfo:e.videoTimingInfo});if(!n)return null;var r=e.playlist.targetDuration,o=Fde({segmentDuration:n,maxDuration:r*2}),a=Fde({segmentDuration:n,maxDuration:r}),s="Segment with index "+e.mediaIndex+" "+("from playlist "+e.playlist.id+" ")+("has a duration of "+n+" ")+("when the reported duration is "+e.duration+" ")+("and the target duration is "+r+". ")+"For HLS content, a duration in excess of the target duration may result in playback issues. See the HLS specification section on EXT-X-TARGETDURATION for more details: https://tools.ietf.org/html/draft-pantos-http-live-streaming-23#section-4.3.3.1";return o||a?{severity:o?"warn":"info",message:s}:null},iJ=(function(t){qr(e,t);function e(n,r){var o;if(o=t.call(this)||this,!n)throw new TypeError("Initialization settings are required");if(typeof n.currentTime!="function")throw new TypeError("No currentTime getter specified");if(!n.mediaSource)throw new TypeError("No MediaSource specified");return o.bandwidth=n.bandwidth,o.throughput={rate:0,count:0},o.roundTrip=NaN,o.resetStats_(),o.mediaIndex=null,o.partIndex=null,o.hasPlayed_=n.hasPlayed,o.currentTime_=n.currentTime,o.seekable_=n.seekable,o.seeking_=n.seeking,o.duration_=n.duration,o.mediaSource_=n.mediaSource,o.vhs_=n.vhs,o.loaderType_=n.loaderType,o.currentMediaInfo_=void 0,o.startingMediaInfo_=void 0,o.segmentMetadataTrack_=n.segmentMetadataTrack,o.goalBufferLength_=n.goalBufferLength,o.sourceType_=n.sourceType,o.sourceUpdater_=n.sourceUpdater,o.inbandTextTracks_=n.inbandTextTracks,o.state_="INIT",o.timelineChangeController_=n.timelineChangeController,o.shouldSaveSegmentTimingInfo_=!0,o.parse708captions_=n.parse708captions,o.useDtsForTimestampOffset_=n.useDtsForTimestampOffset,o.captionServices_=n.captionServices,o.experimentalExactManifestTimings=n.experimentalExactManifestTimings,o.checkBufferTimeout_=null,o.error_=void 0,o.currentTimeline_=-1,o.pendingSegment_=null,o.xhrOptions_=null,o.pendingSegments_=[],o.audioDisabled_=!1,o.isPendingTimestampOffset_=!1,o.gopBuffer_=[],o.timeMapping_=0,o.safeAppend_=Vt.browser.IE_VERSION>=11,o.appendInitSegment_={audio:!0,video:!0},o.playlistOfLastInitSegment_={audio:null,video:null},o.callQueue_=[],o.loadQueue_=[],o.metadataQueue_={id3:[],caption:[]},o.waitingOnRemove_=!1,o.quotaExceededErrorRetryTimeout_=null,o.activeInitSegmentId_=null,o.initSegments_={},o.cacheEncryptionKeys_=n.cacheEncryptionKeys,o.keyCache_={},o.decrypter_=n.decrypter,o.syncController_=n.syncController,o.syncPoint_={segmentIndex:0,time:0},o.transmuxer_=o.createTransmuxer_(),o.triggerSyncInfoUpdate_=function(){return o.trigger("syncinfoupdate")},o.syncController_.on("syncinfoupdate",o.triggerSyncInfoUpdate_),o.mediaSource_.addEventListener("sourceopen",function(){o.isEndOfStream_()||(o.ended_=!1)}),o.fetchAtBuffer_=!1,o.logger_=zv("SegmentLoader["+o.loaderType_+"]"),Object.defineProperty(bn(o),"state",{get:function(){return this.state_},set:function(s){s!==this.state_&&(this.logger_(this.state_+" -> "+s),this.state_=s,this.trigger("statechange"))}}),o.sourceUpdater_.on("ready",function(){o.hasEnoughInfoToAppend_()&&o.processCallQueue_()}),o.loaderType_==="main"&&o.timelineChangeController_.on("pendingtimelinechange",function(){o.hasEnoughInfoToAppend_()&&o.processCallQueue_()}),o.loaderType_==="audio"&&o.timelineChangeController_.on("timelinechange",function(){o.hasEnoughInfoToLoad_()&&o.processLoadQueue_(),o.hasEnoughInfoToAppend_()&&o.processCallQueue_()}),o}var i=e.prototype;return i.createTransmuxer_=function(){return uq.createTransmuxer({remux:!1,alignGopsAtEnd:this.safeAppend_,keepOriginalTimestamps:!0,parse708captions:this.parse708captions_,captionServices:this.captionServices_})},i.resetStats_=function(){this.mediaBytesTransferred=0,this.mediaRequests=0,this.mediaRequestsAborted=0,this.mediaRequestsTimedout=0,this.mediaRequestsErrored=0,this.mediaTransferDuration=0,this.mediaSecondsLoaded=0,this.mediaAppends=0},i.dispose=function(){this.trigger("dispose"),this.state="DISPOSED",this.pause(),this.abort_(),this.transmuxer_&&this.transmuxer_.terminate(),this.resetStats_(),this.checkBufferTimeout_&&Ct.clearTimeout(this.checkBufferTimeout_),this.syncController_&&this.triggerSyncInfoUpdate_&&this.syncController_.off("syncinfoupdate",this.triggerSyncInfoUpdate_),this.off()},i.setAudio=function(r){this.audioDisabled_=!r,r?this.appendInitSegment_.audio=!0:this.sourceUpdater_.removeAudio(0,this.duration_())},i.abort=function(){if(this.state!=="WAITING"){this.pendingSegment_&&(this.pendingSegment_=null);return}this.abort_(),this.state="READY",this.paused()||this.monitorBuffer_()},i.abort_=function(){this.pendingSegment_&&this.pendingSegment_.abortRequests&&this.pendingSegment_.abortRequests(),this.pendingSegment_=null,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.timelineChangeController_.clearPendingTimelineChange(this.loaderType_),this.waitingOnRemove_=!1,Ct.clearTimeout(this.quotaExceededErrorRetryTimeout_),this.quotaExceededErrorRetryTimeout_=null},i.checkForAbort_=function(r){return this.state==="APPENDING"&&!this.pendingSegment_?(this.state="READY",!0):!this.pendingSegment_||this.pendingSegment_.requestId!==r},i.error=function(r){return typeof r<"u"&&(this.logger_("error occurred:",r),this.error_=r),this.pendingSegment_=null,this.error_},i.endOfStream=function(){this.ended_=!0,this.transmuxer_&&uq.reset(this.transmuxer_),this.gopBuffer_.length=0,this.pause(),this.trigger("ended")},i.buffered_=function(){var r=this.getMediaInfo_();if(!this.sourceUpdater_||!r)return Vt.createTimeRanges();if(this.loaderType_==="main"){var o=r.hasAudio,a=r.hasVideo,s=r.isMuxed;if(a&&o&&!this.audioDisabled_&&!s)return this.sourceUpdater_.buffered();if(a)return this.sourceUpdater_.videoBuffered()}return this.sourceUpdater_.audioBuffered()},i.initSegmentForMap=function(r,o){if(o===void 0&&(o=!1),!r)return null;var a=Lz(r),s=this.initSegments_[a];return o&&!s&&r.bytes&&(this.initSegments_[a]=s={resolvedUri:r.resolvedUri,byterange:r.byterange,bytes:r.bytes,tracks:r.tracks,timescales:r.timescales}),s||r},i.segmentKey=function(r,o){if(o===void 0&&(o=!1),!r)return null;var a=Y2e(r),s=this.keyCache_[a];this.cacheEncryptionKeys_&&o&&!s&&r.bytes&&(this.keyCache_[a]=s={resolvedUri:r.resolvedUri,bytes:r.bytes});var l={resolvedUri:(s||r).resolvedUri};return s&&(l.bytes=s.bytes),l},i.couldBeginLoading_=function(){return this.playlist_&&!this.paused()},i.load=function(){if(this.monitorBuffer_(),!!this.playlist_){if(this.state==="INIT"&&this.couldBeginLoading_())return this.init_();!this.couldBeginLoading_()||this.state!=="READY"&&this.state!=="INIT"||(this.state="READY")}},i.init_=function(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()},i.playlist=function(r,o){if(o===void 0&&(o={}),!!r){var a=this.playlist_,s=this.pendingSegment_;this.playlist_=r,this.xhrOptions_=o,this.state==="INIT"&&(r.syncInfo={mediaSequence:r.mediaSequence,time:0},this.loaderType_==="main"&&this.syncController_.setDateTimeMappingForStart(r));var l=null;if(a&&(a.id?l=a.id:a.uri&&(l=a.uri)),this.logger_("playlist update ["+l+" => "+(r.id||r.uri)+"]"),this.trigger("syncinfoupdate"),this.state==="INIT"&&this.couldBeginLoading_())return this.init_();if(!a||a.uri!==r.uri){this.mediaIndex!==null&&(r.endList?this.resyncLoader():this.resetLoader()),this.currentMediaInfo_=void 0,this.trigger("playlistupdate");return}var u=r.mediaSequence-a.mediaSequence;if(this.logger_("live window shift ["+u+"]"),this.mediaIndex!==null)if(this.mediaIndex-=u,this.mediaIndex<0)this.mediaIndex=null,this.partIndex=null;else{var c=this.playlist_.segments[this.mediaIndex];if(this.partIndex&&(!c.parts||!c.parts.length||!c.parts[this.partIndex])){var d=this.mediaIndex;this.logger_("currently processing part (index "+this.partIndex+") no longer exists."),this.resetLoader(),this.mediaIndex=d}}s&&(s.mediaIndex-=u,s.mediaIndex<0?(s.mediaIndex=null,s.partIndex=null):(s.mediaIndex>=0&&(s.segment=r.segments[s.mediaIndex]),s.partIndex>=0&&s.segment.parts&&(s.part=s.segment.parts[s.partIndex]))),this.syncController_.saveExpiredSegmentInfo(a,r)}},i.pause=function(){this.checkBufferTimeout_&&(Ct.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=null)},i.paused=function(){return this.checkBufferTimeout_===null},i.resetEverything=function(r){this.ended_=!1,this.activeInitSegmentId_=null,this.appendInitSegment_={audio:!0,video:!0},this.resetLoader(),this.remove(0,1/0,r),this.transmuxer_&&(this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),this.transmuxer_.postMessage({action:"reset"}))},i.resetLoader=function(){this.fetchAtBuffer_=!1,this.resyncLoader()},i.resyncLoader=function(){this.transmuxer_&&uq.reset(this.transmuxer_),this.mediaIndex=null,this.partIndex=null,this.syncPoint_=null,this.isPendingTimestampOffset_=!1,this.callQueue_=[],this.loadQueue_=[],this.metadataQueue_.id3=[],this.metadataQueue_.caption=[],this.abort(),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})},i.remove=function(r,o,a,s){if(a===void 0&&(a=function(){}),s===void 0&&(s=!1),o===1/0&&(o=this.duration_()),o<=r){this.logger_("skipping remove because end ${end} is <= start ${start}");return}if(!this.sourceUpdater_||!this.getMediaInfo_()){this.logger_("skipping remove because no source updater or starting media info");return}var l=1,u=function(){l--,l===0&&a()};(s||!this.audioDisabled_)&&(l++,this.sourceUpdater_.removeAudio(r,o,u)),(s||this.loaderType_==="main")&&(this.gopBuffer_=wTt(this.gopBuffer_,r,o,this.timeMapping_),l++,this.sourceUpdater_.removeVideo(r,o,u));for(var c in this.inbandTextTracks_)uj(r,o,this.inbandTextTracks_[c]);uj(r,o,this.segmentMetadataTrack_),u()},i.monitorBuffer_=function(){this.checkBufferTimeout_&&Ct.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=Ct.setTimeout(this.monitorBufferTick_.bind(this),1)},i.monitorBufferTick_=function(){this.state==="READY"&&this.fillBuffer_(),this.checkBufferTimeout_&&Ct.clearTimeout(this.checkBufferTimeout_),this.checkBufferTimeout_=Ct.setTimeout(this.monitorBufferTick_.bind(this),DTt)},i.fillBuffer_=function(){if(!this.sourceUpdater_.updating()){var r=this.chooseNextRequest_();r&&(typeof r.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!1,this.timelineChangeController_.pendingTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:r.timeline})),this.loadSegment_(r))}},i.isEndOfStream_=function(r,o,a){if(r===void 0&&(r=this.mediaIndex),o===void 0&&(o=this.playlist_),a===void 0&&(a=this.partIndex),!o||!this.mediaSource_)return!1;var s=typeof r=="number"&&o.segments[r],l=r+1===o.segments.length,u=!s||!s.parts||a+1===s.parts.length;return o.endList&&this.mediaSource_.readyState==="open"&&l&&u},i.chooseNextRequest_=function(){var r=this.buffered_(),o=Tde(r)||0,a=Zte(r,this.currentTime_()),s=!this.hasPlayed_()&&a>=1,l=a>=this.goalBufferLength_(),u=this.playlist_.segments;if(!u.length||s||l)return null;this.syncPoint_=this.syncPoint_||this.syncController_.getSyncPoint(this.playlist_,this.duration_(),this.currentTimeline_,this.currentTime_());var c={partIndex:null,mediaIndex:null,startOfSegment:null,playlist:this.playlist_,isSyncRequest:!this.syncPoint_};if(c.isSyncRequest)c.mediaIndex=OTt(this.currentTimeline_,u,o);else if(this.mediaIndex!==null){var d=u[this.mediaIndex],f=typeof this.partIndex=="number"?this.partIndex:-1;c.startOfSegment=d.end?d.end:o,d.parts&&d.parts[f+1]?(c.mediaIndex=this.mediaIndex,c.partIndex=f+1):c.mediaIndex=this.mediaIndex+1}else{var h=wh.getMediaInfoForTime({experimentalExactManifestTimings:this.experimentalExactManifestTimings,playlist:this.playlist_,currentTime:this.fetchAtBuffer_?o:this.currentTime_(),startingPartIndex:this.syncPoint_.partIndex,startingSegmentIndex:this.syncPoint_.segmentIndex,startTime:this.syncPoint_.time}),p=h.segmentIndex,g=h.startTime,v=h.partIndex;c.getMediaInfoForTime=this.fetchAtBuffer_?"bufferedEnd "+o:"currentTime "+this.currentTime_(),c.mediaIndex=p,c.startOfSegment=g,c.partIndex=v}var y=u[c.mediaIndex],m=y&&typeof c.partIndex=="number"&&y.parts&&y.parts[c.partIndex];if(!y||typeof c.partIndex=="number"&&!m)return null;if(typeof c.partIndex!="number"&&y.parts&&(c.partIndex=0,m=y.parts[0]),!a&&m&&!m.independent)if(c.partIndex===0){var b=u[c.mediaIndex-1],S=b.parts&&b.parts.length&&b.parts[b.parts.length-1];S&&S.independent&&(c.mediaIndex-=1,c.partIndex=b.parts.length-1,c.independent="previous segment")}else y.parts[c.partIndex-1].independent&&(c.partIndex-=1,c.independent="previous part");var _=this.mediaSource_&&this.mediaSource_.readyState==="ended";return c.mediaIndex>=u.length-1&&_&&!this.seeking_()?null:this.generateSegmentInfo_(c)},i.generateSegmentInfo_=function(r){var o=r.independent,a=r.playlist,s=r.mediaIndex,l=r.startOfSegment,u=r.isSyncRequest,c=r.partIndex,d=r.forceTimestampOffset,f=r.getMediaInfoForTime,h=a.segments[s],p=typeof c=="number"&&h.parts[c],g={requestId:"segment-loader-"+Math.random(),uri:p&&p.resolvedUri||h.resolvedUri,mediaIndex:s,partIndex:p?c:null,isSyncRequest:u,startOfSegment:l,playlist:a,bytes:null,encryptedBytes:null,timestampOffset:null,timeline:h.timeline,duration:p&&p.duration||h.duration,segment:h,part:p,byteLength:0,transmuxer:this.transmuxer_,getMediaInfoForTime:f,independent:o},v=typeof d<"u"?d:this.isPendingTimestampOffset_;g.timestampOffset=this.timestampOffsetForSegment_({segmentTimeline:h.timeline,currentTimeline:this.currentTimeline_,startOfSegment:l,buffered:this.buffered_(),overrideCheck:v});var y=Tde(this.sourceUpdater_.audioBuffered());return typeof y=="number"&&(g.audioAppendStart=y-this.sourceUpdater_.audioTimestampOffset()),this.sourceUpdater_.videoBuffered().length&&(g.gopsToAlignWith=xTt(this.gopBuffer_,this.currentTime_()-this.sourceUpdater_.videoTimestampOffset(),this.timeMapping_)),g},i.timestampOffsetForSegment_=function(r){return LTt(r)},i.earlyAbortWhenNeeded_=function(r){if(!(this.vhs_.tech_.paused()||!this.xhrOptions_.timeout||!this.playlist_.attributes.BANDWIDTH)&&!(Date.now()-(r.firstBytesReceivedAt||Date.now())<1e3)){var o=this.currentTime_(),a=r.bandwidth,s=this.pendingSegment_.duration,l=wh.estimateSegmentRequestTime(s,a,this.playlist_,r.bytesReceived),u=rCt(this.buffered_(),o,this.vhs_.tech_.playbackRate())-1;if(!(l<=u)){var c=vTt({master:this.vhs_.playlists.master,currentTime:o,bandwidth:a,duration:this.duration_(),segmentDuration:s,timeUntilRebuffer:u,currentTimeline:this.currentTimeline_,syncController:this.syncController_});if(c){var d=l-u,f=d-c.rebufferingImpact,h=.5;u<=OP&&(h=1),!(!c.playlist||c.playlist.uri===this.playlist_.uri||f<h)&&(this.bandwidth=c.playlist.attributes.BANDWIDTH*Pc.BANDWIDTH_VARIANCE+1,this.trigger("earlyabort"))}}}},i.handleAbort_=function(r){this.logger_("Aborting "+sL(r)),this.mediaRequestsAborted+=1},i.handleProgress_=function(r,o){this.earlyAbortWhenNeeded_(o.stats),!this.checkForAbort_(o.requestId)&&this.trigger("progress")},i.handleTrackInfo_=function(r,o){this.earlyAbortWhenNeeded_(r.stats),!this.checkForAbort_(r.requestId)&&(this.checkForIllegalMediaSwitch(o)||(o=o||{},ATt(this.currentMediaInfo_,o)||(this.appendInitSegment_={audio:!0,video:!0},this.startingMediaInfo_=o,this.currentMediaInfo_=o,this.logger_("trackinfo update",o),this.trigger("trackinfo")),!this.checkForAbort_(r.requestId)&&(this.pendingSegment_.trackInfo=o,this.hasEnoughInfoToAppend_()&&this.processCallQueue_())))},i.handleTimingInfo_=function(r,o,a,s){if(this.earlyAbortWhenNeeded_(r.stats),!this.checkForAbort_(r.requestId)){var l=this.pendingSegment_,u=Ide(o);l[u]=l[u]||{},l[u][a]=s,this.logger_("timinginfo: "+o+" - "+a+" - "+s),this.hasEnoughInfoToAppend_()&&this.processCallQueue_()}},i.handleCaptions_=function(r,o){var a=this;if(this.earlyAbortWhenNeeded_(r.stats),!this.checkForAbort_(r.requestId)){if(o.length===0){this.logger_("SegmentLoader received no captions from a caption event");return}var s=this.pendingSegment_;if(!s.hasAppendedData_){this.metadataQueue_.caption.push(this.handleCaptions_.bind(this,r,o));return}var l=this.sourceUpdater_.videoTimestampOffset()===null?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset(),u={};o.forEach(function(c){u[c.stream]=u[c.stream]||{startTime:1/0,captions:[],endTime:0};var d=u[c.stream];d.startTime=Math.min(d.startTime,c.startTime+l),d.endTime=Math.max(d.endTime,c.endTime+l),d.captions.push(c)}),Object.keys(u).forEach(function(c){var d=u[c],f=d.startTime,h=d.endTime,p=d.captions,g=a.inbandTextTracks_;a.logger_("adding cues from "+f+" -> "+h+" for "+c),bTt(g,a.vhs_.tech_,c),uj(f,h,g[c]),STt({captionArray:p,inbandTextTracks:g,timestampOffset:l})}),this.transmuxer_&&this.transmuxer_.postMessage({action:"clearParsedMp4Captions"})}},i.handleId3_=function(r,o,a){if(this.earlyAbortWhenNeeded_(r.stats),!this.checkForAbort_(r.requestId)){var s=this.pendingSegment_;if(!s.hasAppendedData_){this.metadataQueue_.id3.push(this.handleId3_.bind(this,r,o,a));return}var l=this.sourceUpdater_.videoTimestampOffset()===null?this.sourceUpdater_.audioTimestampOffset():this.sourceUpdater_.videoTimestampOffset();CTt(this.inbandTextTracks_,a,this.vhs_.tech_),PTt({inbandTextTracks:this.inbandTextTracks_,metadataArray:o,timestampOffset:l,videoDuration:this.duration_()})}},i.processMetadataQueue_=function(){this.metadataQueue_.id3.forEach(function(r){return r()}),this.metadataQueue_.caption.forEach(function(r){return r()}),this.metadataQueue_.id3=[],this.metadataQueue_.caption=[]},i.processCallQueue_=function(){var r=this.callQueue_;this.callQueue_=[],r.forEach(function(o){return o()})},i.processLoadQueue_=function(){var r=this.loadQueue_;this.loadQueue_=[],r.forEach(function(o){return o()})},i.hasEnoughInfoToLoad_=function(){if(this.loaderType_!=="audio")return!0;var r=this.pendingSegment_;return r?this.getCurrentMediaInfo_()?!Nde({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:r.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}):!0:!1},i.getCurrentMediaInfo_=function(r){return r===void 0&&(r=this.pendingSegment_),r&&r.trackInfo||this.currentMediaInfo_},i.getMediaInfo_=function(r){return r===void 0&&(r=this.pendingSegment_),this.getCurrentMediaInfo_(r)||this.startingMediaInfo_},i.getPendingSegmentPlaylist=function(){return this.pendingSegment_?this.pendingSegment_.playlist:null},i.hasEnoughInfoToAppend_=function(){if(!this.sourceUpdater_.ready()||this.waitingOnRemove_||this.quotaExceededErrorRetryTimeout_)return!1;var r=this.pendingSegment_,o=this.getCurrentMediaInfo_();if(!r||!o)return!1;var a=o.hasAudio,s=o.hasVideo,l=o.isMuxed;return!(s&&!r.videoTimingInfo||a&&!this.audioDisabled_&&!l&&!r.audioTimingInfo||Nde({timelineChangeController:this.timelineChangeController_,currentTimeline:this.currentTimeline_,segmentTimeline:r.timeline,loaderType:this.loaderType_,audioDisabled:this.audioDisabled_}))},i.handleData_=function(r,o){if(this.earlyAbortWhenNeeded_(r.stats),!this.checkForAbort_(r.requestId)){if(this.callQueue_.length||!this.hasEnoughInfoToAppend_()){this.callQueue_.push(this.handleData_.bind(this,r,o));return}var a=this.pendingSegment_;if(this.setTimeMapping_(a.timeline),this.updateMediaSecondsLoaded_(a.part||a.segment),this.mediaSource_.readyState!=="closed"){if(r.map&&(r.map=this.initSegmentForMap(r.map,!0),a.segment.map=r.map),r.key&&this.segmentKey(r.key,!0),a.isFmp4=r.isFmp4,a.timingInfo=a.timingInfo||{},a.isFmp4)this.trigger("fmp4"),a.timingInfo.start=a[Ide(o.type)].start;else{var s=this.getCurrentMediaInfo_(),l=this.loaderType_==="main"&&s&&s.hasVideo,u;l&&(u=a.videoTimingInfo.start),a.timingInfo.start=this.trueSegmentStart_({currentStart:a.timingInfo.start,playlist:a.playlist,mediaIndex:a.mediaIndex,currentVideoTimestampOffset:this.sourceUpdater_.videoTimestampOffset(),useVideoTimingInfo:l,firstVideoFrameTimeForData:u,videoTimingInfo:a.videoTimingInfo,audioTimingInfo:a.audioTimingInfo})}if(this.updateAppendInitSegmentStatus(a,o.type),this.updateSourceBufferTimestampOffset_(a),a.isSyncRequest){this.updateTimingInfoEnd_(a),this.syncController_.saveSegmentTimingInfo({segmentInfo:a,shouldSaveTimelineMapping:this.loaderType_==="main"});var c=this.chooseNextRequest_();if(c.mediaIndex!==a.mediaIndex||c.partIndex!==a.partIndex){this.logger_("sync segment was incorrect, not appending");return}this.logger_("sync segment was correct, appending")}a.hasAppendedData_=!0,this.processMetadataQueue_(),this.appendData_(a,o)}}},i.updateAppendInitSegmentStatus=function(r,o){this.loaderType_==="main"&&typeof r.timestampOffset=="number"&&!r.changedTimestampOffset&&(this.appendInitSegment_={audio:!0,video:!0}),this.playlistOfLastInitSegment_[o]!==r.playlist&&(this.appendInitSegment_[o]=!0)},i.getInitSegmentAndUpdateState_=function(r){var o=r.type,a=r.initSegment,s=r.map,l=r.playlist;if(s){var u=Lz(s);if(this.activeInitSegmentId_===u)return null;a=this.initSegmentForMap(s,!0).bytes,this.activeInitSegmentId_=u}return a&&this.appendInitSegment_[o]?(this.playlistOfLastInitSegment_[o]=l,this.appendInitSegment_[o]=!1,this.activeInitSegmentId_=null,a):null},i.handleQuotaExceededError_=function(r,o){var a=this,s=r.segmentInfo,l=r.type,u=r.bytes,c=this.sourceUpdater_.audioBuffered(),d=this.sourceUpdater_.videoBuffered();c.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the audio buffer: "+WO(c).join(", ")),d.length>1&&this.logger_("On QUOTA_EXCEEDED_ERR, found gaps in the video buffer: "+WO(d).join(", "));var f=c.length?c.start(0):0,h=c.length?c.end(c.length-1):0,p=d.length?d.start(0):0,g=d.length?d.end(d.length-1):0;if(h-f<=oN&&g-p<=oN){this.logger_("On QUOTA_EXCEEDED_ERR, single segment too large to append to buffer, triggering an error. "+("Appended byte length: "+u.byteLength+", ")+("audio buffer: "+WO(c).join(", ")+", ")+("video buffer: "+WO(d).join(", ")+", ")),this.error({message:"Quota exceeded error with append of a single segment of content",excludeUntil:1/0}),this.trigger("error");return}this.waitingOnRemove_=!0,this.callQueue_.push(this.appendToSourceBuffer_.bind(this,{segmentInfo:s,type:l,bytes:u}));var v=this.currentTime_(),y=v-oN;this.logger_("On QUOTA_EXCEEDED_ERR, removing audio/video from 0 to "+y),this.remove(0,y,function(){a.logger_("On QUOTA_EXCEEDED_ERR, retrying append in "+oN+"s"),a.waitingOnRemove_=!1,a.quotaExceededErrorRetryTimeout_=Ct.setTimeout(function(){a.logger_("On QUOTA_EXCEEDED_ERR, re-processing call queue"),a.quotaExceededErrorRetryTimeout_=null,a.processCallQueue_()},oN*1e3)},!0)},i.handleAppendError_=function(r,o){var a=r.segmentInfo,s=r.type,l=r.bytes;if(o){if(o.code===cNe){this.handleQuotaExceededError_({segmentInfo:a,type:s,bytes:l});return}this.logger_("Received non QUOTA_EXCEEDED_ERR on append",o),this.error(s+" append of "+l.length+"b failed for segment "+("#"+a.mediaIndex+" in playlist "+a.playlist.id)),this.trigger("appenderror")}},i.appendToSourceBuffer_=function(r){var o=r.segmentInfo,a=r.type,s=r.initSegment,l=r.data,u=r.bytes;if(!u){var c=[l],d=l.byteLength;s&&(c.unshift(s),d+=s.byteLength),u=mTt({bytes:d,segments:c})}this.sourceUpdater_.appendBuffer({segmentInfo:o,type:a,bytes:u},this.handleAppendError_.bind(this,{segmentInfo:o,type:a,bytes:u}))},i.handleSegmentTimingInfo_=function(r,o,a){if(!(!this.pendingSegment_||o!==this.pendingSegment_.requestId)){var s=this.pendingSegment_.segment,l=r+"TimingInfo";s[l]||(s[l]={}),s[l].transmuxerPrependedSeconds=a.prependedContentDuration||0,s[l].transmuxedPresentationStart=a.start.presentation,s[l].transmuxedDecodeStart=a.start.decode,s[l].transmuxedPresentationEnd=a.end.presentation,s[l].transmuxedDecodeEnd=a.end.decode,s[l].baseMediaDecodeTime=a.baseMediaDecodeTime}},i.appendData_=function(r,o){var a=o.type,s=o.data;if(!(!s||!s.byteLength)&&!(a==="audio"&&this.audioDisabled_)){var l=this.getInitSegmentAndUpdateState_({type:a,initSegment:o.initSegment,playlist:r.playlist,map:r.isFmp4?r.segment.map:null});this.appendToSourceBuffer_({segmentInfo:r,type:a,initSegment:l,data:s})}},i.loadSegment_=function(r){var o=this;if(this.state="WAITING",this.pendingSegment_=r,this.trimBackBuffer_(r),typeof r.timestampOffset=="number"&&this.transmuxer_&&this.transmuxer_.postMessage({action:"clearAllMp4Captions"}),!this.hasEnoughInfoToLoad_()){this.loadQueue_.push(function(){var a=Gn({},r,{forceTimestampOffset:!0});Gn(r,o.generateSegmentInfo_(a)),o.isPendingTimestampOffset_=!1,o.updateTransmuxerAndRequestSegment_(r)});return}this.updateTransmuxerAndRequestSegment_(r)},i.updateTransmuxerAndRequestSegment_=function(r){var o=this;this.shouldUpdateTransmuxerTimestampOffset_(r.timestampOffset)&&(this.gopBuffer_.length=0,r.gopsToAlignWith=[],this.timeMapping_=0,this.transmuxer_.postMessage({action:"reset"}),this.transmuxer_.postMessage({action:"setTimestampOffset",timestampOffset:r.timestampOffset}));var a=this.createSimplifiedSegmentObj_(r),s=this.isEndOfStream_(r.mediaIndex,r.playlist,r.partIndex),l=this.mediaIndex!==null,u=r.timeline!==this.currentTimeline_&&r.timeline>0,c=s||l&&u;this.logger_("Requesting "+sL(r)),a.map&&!a.map.bytes&&(this.logger_("going to request init segment."),this.appendInitSegment_={video:!0,audio:!0}),r.abortRequests=cTt({xhr:this.vhs_.xhr,xhrOptions:this.xhrOptions_,decryptionWorker:this.decrypter_,segment:a,abortFn:this.handleAbort_.bind(this,r),progressFn:this.handleProgress_.bind(this),trackInfoFn:this.handleTrackInfo_.bind(this),timingInfoFn:this.handleTimingInfo_.bind(this),videoSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"video",r.requestId),audioSegmentTimingInfoFn:this.handleSegmentTimingInfo_.bind(this,"audio",r.requestId),captionsFn:this.handleCaptions_.bind(this),isEndOfTimeline:c,endedTimelineFn:function(){o.logger_("received endedtimeline callback")},id3Fn:this.handleId3_.bind(this),dataFn:this.handleData_.bind(this),doneFn:this.segmentRequestFinished_.bind(this),onTransmuxerLog:function(f){var h=f.message,p=f.level,g=f.stream;o.logger_(sL(r)+" logged from transmuxer stream "+g+" as a "+p+": "+h)}})},i.trimBackBuffer_=function(r){var o=MTt(this.seekable_(),this.currentTime_(),this.playlist_.targetDuration||10);o>0&&this.remove(0,o)},i.createSimplifiedSegmentObj_=function(r){var o=r.segment,a=r.part,s={resolvedUri:a?a.resolvedUri:o.resolvedUri,byterange:a?a.byterange:o.byterange,requestId:r.requestId,transmuxer:r.transmuxer,audioAppendStart:r.audioAppendStart,gopsToAlignWith:r.gopsToAlignWith,part:r.part},l=r.playlist.segments[r.mediaIndex-1];if(l&&l.timeline===o.timeline&&(l.videoTimingInfo?s.baseStartTime=l.videoTimingInfo.transmuxedDecodeEnd:l.audioTimingInfo&&(s.baseStartTime=l.audioTimingInfo.transmuxedDecodeEnd)),o.key){var u=o.key.iv||new Uint32Array([0,0,0,r.mediaIndex+r.playlist.mediaSequence]);s.key=this.segmentKey(o.key),s.key.iv=u}return o.map&&(s.map=this.initSegmentForMap(o.map)),s},i.saveTransferStats_=function(r){this.mediaRequests+=1,r&&(this.mediaBytesTransferred+=r.bytesReceived,this.mediaTransferDuration+=r.roundTripTime)},i.saveBandwidthRelatedStats_=function(r,o){if(this.pendingSegment_.byteLength=o.bytesReceived,r<x4){this.logger_("Ignoring segment's bandwidth because its duration of "+r+(" is less than the min to record "+x4));return}this.bandwidth=o.bandwidth,this.roundTrip=o.roundTripTime},i.handleTimeout_=function(){this.mediaRequestsTimedout+=1,this.bandwidth=1,this.roundTrip=NaN,this.trigger("bandwidthupdate"),this.trigger("timeout")},i.segmentRequestFinished_=function(r,o,a){if(this.callQueue_.length){this.callQueue_.push(this.segmentRequestFinished_.bind(this,r,o,a));return}if(this.saveTransferStats_(o.stats),!!this.pendingSegment_&&o.requestId===this.pendingSegment_.requestId){if(r){if(this.pendingSegment_=null,this.state="READY",r.code===tm.ABORTED)return;if(this.pause(),r.code===tm.TIMEOUT){this.handleTimeout_();return}this.mediaRequestsErrored+=1,this.error(r),this.trigger("error");return}var s=this.pendingSegment_;this.saveBandwidthRelatedStats_(s.duration,o.stats),s.endOfAllRequests=o.endOfAllRequests,a.gopInfo&&(this.gopBuffer_=ETt(this.gopBuffer_,a.gopInfo,this.safeAppend_)),this.state="APPENDING",this.trigger("appending"),this.waitForAppendsToComplete_(s)}},i.setTimeMapping_=function(r){var o=this.syncController_.mappingForTimeline(r);o!==null&&(this.timeMapping_=o)},i.updateMediaSecondsLoaded_=function(r){typeof r.start=="number"&&typeof r.end=="number"?this.mediaSecondsLoaded+=r.end-r.start:this.mediaSecondsLoaded+=r.duration},i.shouldUpdateTransmuxerTimestampOffset_=function(r){return r===null?!1:this.loaderType_==="main"&&r!==this.sourceUpdater_.videoTimestampOffset()||!this.audioDisabled_&&r!==this.sourceUpdater_.audioTimestampOffset()},i.trueSegmentStart_=function(r){var o=r.currentStart,a=r.playlist,s=r.mediaIndex,l=r.firstVideoFrameTimeForData,u=r.currentVideoTimestampOffset,c=r.useVideoTimingInfo,d=r.videoTimingInfo,f=r.audioTimingInfo;if(typeof o<"u")return o;if(!c)return f.start;var h=a.segments[s-1];return s===0||!h||typeof h.start>"u"||h.end!==l+u?l:d.start},i.waitForAppendsToComplete_=function(r){var o=this.getCurrentMediaInfo_(r);if(!o){this.error({message:"No starting media returned, likely due to an unsupported media format.",blacklistDuration:1/0}),this.trigger("error");return}var a=o.hasAudio,s=o.hasVideo,l=o.isMuxed,u=this.loaderType_==="main"&&s,c=!this.audioDisabled_&&a&&!l;if(r.waitingOnAppends=0,!r.hasAppendedData_){!r.timingInfo&&typeof r.timestampOffset=="number"&&(this.isPendingTimestampOffset_=!0),r.timingInfo={start:0},r.waitingOnAppends++,this.isPendingTimestampOffset_||(this.updateSourceBufferTimestampOffset_(r),this.processMetadataQueue_()),this.checkAppendsDone_(r);return}u&&r.waitingOnAppends++,c&&r.waitingOnAppends++,u&&this.sourceUpdater_.videoQueueCallback(this.checkAppendsDone_.bind(this,r)),c&&this.sourceUpdater_.audioQueueCallback(this.checkAppendsDone_.bind(this,r))},i.checkAppendsDone_=function(r){this.checkForAbort_(r.requestId)||(r.waitingOnAppends--,r.waitingOnAppends===0&&this.handleAppendsDone_())},i.checkForIllegalMediaSwitch=function(r){var o=RTt(this.loaderType_,this.getCurrentMediaInfo_(),r);return o?(this.error({message:o,blacklistDuration:1/0}),this.trigger("error"),!0):!1},i.updateSourceBufferTimestampOffset_=function(r){if(!(r.timestampOffset===null||typeof r.timingInfo.start!="number"||r.changedTimestampOffset||this.loaderType_!=="main")){var o=!1;r.timestampOffset-=this.getSegmentStartTimeForTimestampOffsetCalculation_({videoTimingInfo:r.segment.videoTimingInfo,audioTimingInfo:r.segment.audioTimingInfo,timingInfo:r.timingInfo}),r.changedTimestampOffset=!0,r.timestampOffset!==this.sourceUpdater_.videoTimestampOffset()&&(this.sourceUpdater_.videoTimestampOffset(r.timestampOffset),o=!0),r.timestampOffset!==this.sourceUpdater_.audioTimestampOffset()&&(this.sourceUpdater_.audioTimestampOffset(r.timestampOffset),o=!0),o&&this.trigger("timestampoffset")}},i.getSegmentStartTimeForTimestampOffsetCalculation_=function(r){var o=r.videoTimingInfo,a=r.audioTimingInfo,s=r.timingInfo;return this.useDtsForTimestampOffset_?o&&typeof o.transmuxedDecodeStart=="number"?o.transmuxedDecodeStart:a&&typeof a.transmuxedDecodeStart=="number"?a.transmuxedDecodeStart:s.start:s.start},i.updateTimingInfoEnd_=function(r){r.timingInfo=r.timingInfo||{};var o=this.getMediaInfo_(),a=this.loaderType_==="main"&&o&&o.hasVideo,s=a&&r.videoTimingInfo?r.videoTimingInfo:r.audioTimingInfo;s&&(r.timingInfo.end=typeof s.end=="number"?s.end:s.start+r.duration)},i.handleAppendsDone_=function(){if(this.pendingSegment_&&this.trigger("appendsdone"),!this.pendingSegment_){this.state="READY",this.paused()||this.monitorBuffer_();return}var r=this.pendingSegment_;this.updateTimingInfoEnd_(r),this.shouldSaveSegmentTimingInfo_&&this.syncController_.saveSegmentTimingInfo({segmentInfo:r,shouldSaveTimelineMapping:this.loaderType_==="main"});var o=ITt(r,this.sourceType_);if(o&&(o.severity==="warn"?Vt.log.warn(o.message):this.logger_(o.message)),this.recordThroughput_(r),this.pendingSegment_=null,this.state="READY",r.isSyncRequest&&(this.trigger("syncinfoupdate"),!r.hasAppendedData_)){this.logger_("Throwing away un-appended sync request "+sL(r));return}this.logger_("Appended "+sL(r)),this.addSegmentMetadataCue_(r),this.fetchAtBuffer_=!0,this.currentTimeline_!==r.timeline&&(this.timelineChangeController_.lastTimelineChange({type:this.loaderType_,from:this.currentTimeline_,to:r.timeline}),this.loaderType_==="main"&&!this.audioDisabled_&&this.timelineChangeController_.lastTimelineChange({type:"audio",from:this.currentTimeline_,to:r.timeline})),this.currentTimeline_=r.timeline,this.trigger("syncinfoupdate");var a=r.segment,s=r.part,l=a.end&&this.currentTime_()-a.end>r.playlist.targetDuration*3,u=s&&s.end&&this.currentTime_()-s.end>r.playlist.partTargetDuration*3;if(l||u){this.logger_("bad "+(l?"segment":"part")+" "+sL(r)),this.resetEverything();return}var c=this.mediaIndex!==null;c&&this.trigger("bandwidthupdate"),this.trigger("progress"),this.mediaIndex=r.mediaIndex,this.partIndex=r.partIndex,this.isEndOfStream_(r.mediaIndex,r.playlist,r.partIndex)&&this.endOfStream(),this.trigger("appended"),r.hasAppendedData_&&this.mediaAppends++,this.paused()||this.monitorBuffer_()},i.recordThroughput_=function(r){if(r.duration<x4){this.logger_("Ignoring segment's throughput because its duration of "+r.duration+(" is less than the min to record "+x4));return}var o=this.throughput.rate,a=Date.now()-r.endOfAllRequests+1,s=Math.floor(r.byteLength/a*8*1e3);this.throughput.rate+=(s-o)/++this.throughput.count},i.addSegmentMetadataCue_=function(r){if(this.segmentMetadataTrack_){var o=r.segment,a=o.start,s=o.end;if(!(!kde(a)||!kde(s))){uj(a,s,this.segmentMetadataTrack_);var l=Ct.WebKitDataCue||Ct.VTTCue,u={custom:o.custom,dateTimeObject:o.dateTimeObject,dateTimeString:o.dateTimeString,bandwidth:r.playlist.attributes.BANDWIDTH,resolution:r.playlist.attributes.RESOLUTION,codecs:r.playlist.attributes.CODECS,byteLength:r.byteLength,uri:r.uri,timeline:r.timeline,playlist:r.playlist.id,start:a,end:s},c=JSON.stringify(u),d=new l(a,s,c);d.value=u,this.segmentMetadataTrack_.addCue(d)}}},e})(Vt.EventTarget);function sS(){}var dNe=function(e){return typeof e!="string"?e:e.replace(/./,function(i){return i.toUpperCase()})},NTt=["video","audio"],nJ=function(e,i){var n=i[e+"Buffer"];return n&&n.updating||i.queuePending[e]},FTt=function(e,i){for(var n=0;n<i.length;n++){var r=i[n];if(r.type==="mediaSource")return null;if(r.type===e)return n}return null},nre=function t(e,i){if(i.queue.length!==0){var n=0,r=i.queue[n];if(r.type==="mediaSource"){!i.updating()&&i.mediaSource.readyState!=="closed"&&(i.queue.shift(),r.action(i),r.doneFn&&r.doneFn(),t("audio",i),t("video",i));return}if(e!=="mediaSource"&&!(!i.ready()||i.mediaSource.readyState==="closed"||nJ(e,i))){if(r.type!==e){if(n=FTt(e,i.queue),n===null)return;r=i.queue[n]}if(i.queue.splice(n,1),i.queuePending[e]=r,r.action(e,i),!r.doneFn){i.queuePending[e]=null,t(e,i);return}}}},fNe=function(e,i){var n=i[e+"Buffer"],r=dNe(e);n&&(n.removeEventListener("updateend",i["on"+r+"UpdateEnd_"]),n.removeEventListener("error",i["on"+r+"Error_"]),i.codecs[e]=null,i[e+"Buffer"]=null)},Uy=function(e,i){return e&&i&&Array.prototype.indexOf.call(e.sourceBuffers,i)!==-1},lp={appendBuffer:function(e,i,n){return function(r,o){var a=o[r+"Buffer"];if(Uy(o.mediaSource,a)){o.logger_("Appending segment "+i.mediaIndex+"'s "+e.length+" bytes to "+r+"Buffer");try{a.appendBuffer(e)}catch(s){o.logger_("Error with code "+s.code+" "+(s.code===cNe?"(QUOTA_EXCEEDED_ERR) ":"")+("when appending segment "+i.mediaIndex+" to "+r+"Buffer")),o.queuePending[r]=null,n(s)}}}},remove:function(e,i){return function(n,r){var o=r[n+"Buffer"];if(Uy(r.mediaSource,o)){r.logger_("Removing "+e+" to "+i+" from "+n+"Buffer");try{o.remove(e,i)}catch{r.logger_("Remove "+e+" to "+i+" from "+n+"Buffer failed")}}}},timestampOffset:function(e){return function(i,n){var r=n[i+"Buffer"];Uy(n.mediaSource,r)&&(n.logger_("Setting "+i+"timestampOffset to "+e),r.timestampOffset=e)}},callback:function(e){return function(i,n){e()}},endOfStream:function(e){return function(i){if(i.mediaSource.readyState==="open"){i.logger_("Calling mediaSource endOfStream("+(e||"")+")");try{i.mediaSource.endOfStream(e)}catch(n){Vt.log.warn("Failed to call media source endOfStream",n)}}}},duration:function(e){return function(i){i.logger_("Setting mediaSource duration to "+e);try{i.mediaSource.duration=e}catch(n){Vt.log.warn("Failed to set media source duration",n)}}},abort:function(){return function(e,i){if(i.mediaSource.readyState==="open"){var n=i[e+"Buffer"];if(Uy(i.mediaSource,n)){i.logger_("calling abort on "+e+"Buffer");try{n.abort()}catch(r){Vt.log.warn("Failed to abort on "+e+"Buffer",r)}}}}},addSourceBuffer:function(e,i){return function(n){var r=dNe(e),o=R3(i);n.logger_("Adding "+e+"Buffer with codec "+i+" to mediaSource");var a=n.mediaSource.addSourceBuffer(o);a.addEventListener("updateend",n["on"+r+"UpdateEnd_"]),a.addEventListener("error",n["on"+r+"Error_"]),n.codecs[e]=i,n[e+"Buffer"]=a}},removeSourceBuffer:function(e){return function(i){var n=i[e+"Buffer"];if(fNe(e,i),!!Uy(i.mediaSource,n)){i.logger_("Removing "+e+"Buffer with codec "+i.codecs[e]+" from mediaSource");try{i.mediaSource.removeSourceBuffer(n)}catch(r){Vt.log.warn("Failed to removeSourceBuffer "+e+"Buffer",r)}}}},changeType:function(e){return function(i,n){var r=n[i+"Buffer"],o=R3(e);if(Uy(n.mediaSource,r)&&n.codecs[i]!==e){n.logger_("changing "+i+"Buffer codec from "+n.codecs[i]+" to "+e);try{r.changeType(o),n.codecs[i]=e}catch(a){Vt.log.warn("Failed to changeType on "+i+"Buffer",a)}}}}},up=function(e){var i=e.type,n=e.sourceUpdater,r=e.action,o=e.doneFn,a=e.name;n.queue.push({type:i,action:r,doneFn:o,name:a}),nre(i,n)},Bde=function(e,i){return function(n){if(i.queuePending[e]){var r=i.queuePending[e].doneFn;i.queuePending[e]=null,r&&r(i[e+"Error_"])}nre(e,i)}},hNe=(function(t){qr(e,t);function e(n){var r;return r=t.call(this)||this,r.mediaSource=n,r.sourceopenListener_=function(){return nre("mediaSource",bn(r))},r.mediaSource.addEventListener("sourceopen",r.sourceopenListener_),r.logger_=zv("SourceUpdater"),r.audioTimestampOffset_=0,r.videoTimestampOffset_=0,r.queue=[],r.queuePending={audio:null,video:null},r.delayedAudioAppendQueue_=[],r.videoAppendQueued_=!1,r.codecs={},r.onVideoUpdateEnd_=Bde("video",bn(r)),r.onAudioUpdateEnd_=Bde("audio",bn(r)),r.onVideoError_=function(o){r.videoError_=o},r.onAudioError_=function(o){r.audioError_=o},r.createdSourceBuffers_=!1,r.initializedEme_=!1,r.triggeredReady_=!1,r}var i=e.prototype;return i.initializedEme=function(){this.initializedEme_=!0,this.triggerReady()},i.hasCreatedSourceBuffers=function(){return this.createdSourceBuffers_},i.hasInitializedAnyEme=function(){return this.initializedEme_},i.ready=function(){return this.hasCreatedSourceBuffers()&&this.hasInitializedAnyEme()},i.createSourceBuffers=function(r){this.hasCreatedSourceBuffers()||(this.addOrChangeSourceBuffers(r),this.createdSourceBuffers_=!0,this.trigger("createdsourcebuffers"),this.triggerReady())},i.triggerReady=function(){this.ready()&&!this.triggeredReady_&&(this.triggeredReady_=!0,this.trigger("ready"))},i.addSourceBuffer=function(r,o){up({type:"mediaSource",sourceUpdater:this,action:lp.addSourceBuffer(r,o),name:"addSourceBuffer"})},i.abort=function(r){up({type:r,sourceUpdater:this,action:lp.abort(r),name:"abort"})},i.removeSourceBuffer=function(r){if(!this.canRemoveSourceBuffer()){Vt.log.error("removeSourceBuffer is not supported!");return}up({type:"mediaSource",sourceUpdater:this,action:lp.removeSourceBuffer(r),name:"removeSourceBuffer"})},i.canRemoveSourceBuffer=function(){return!Vt.browser.IE_VERSION&&!Vt.browser.IS_FIREFOX&&Ct.MediaSource&&Ct.MediaSource.prototype&&typeof Ct.MediaSource.prototype.removeSourceBuffer=="function"},e.canChangeType=function(){return Ct.SourceBuffer&&Ct.SourceBuffer.prototype&&typeof Ct.SourceBuffer.prototype.changeType=="function"},i.canChangeType=function(){return this.constructor.canChangeType()},i.changeType=function(r,o){if(!this.canChangeType()){Vt.log.error("changeType is not supported!");return}up({type:r,sourceUpdater:this,action:lp.changeType(o),name:"changeType"})},i.addOrChangeSourceBuffers=function(r){var o=this;if(!r||typeof r!="object"||Object.keys(r).length===0)throw new Error("Cannot addOrChangeSourceBuffers to undefined codecs");Object.keys(r).forEach(function(a){var s=r[a];if(!o.hasCreatedSourceBuffers())return o.addSourceBuffer(a,s);o.canChangeType()&&o.changeType(a,s)})},i.appendBuffer=function(r,o){var a=this,s=r.segmentInfo,l=r.type,u=r.bytes;if(this.processedAppend_=!0,l==="audio"&&this.videoBuffer&&!this.videoAppendQueued_){this.delayedAudioAppendQueue_.push([r,o]),this.logger_("delayed audio append of "+u.length+" until video append");return}var c=o;if(up({type:l,sourceUpdater:this,action:lp.appendBuffer(u,s||{mediaIndex:-1},c),doneFn:o,name:"appendBuffer"}),l==="video"){if(this.videoAppendQueued_=!0,!this.delayedAudioAppendQueue_.length)return;var d=this.delayedAudioAppendQueue_.slice();this.logger_("queuing delayed audio "+d.length+" appendBuffers"),this.delayedAudioAppendQueue_.length=0,d.forEach(function(f){a.appendBuffer.apply(a,f)})}},i.audioBuffered=function(){return Uy(this.mediaSource,this.audioBuffer)&&this.audioBuffer.buffered?this.audioBuffer.buffered:Vt.createTimeRange()},i.videoBuffered=function(){return Uy(this.mediaSource,this.videoBuffer)&&this.videoBuffer.buffered?this.videoBuffer.buffered:Vt.createTimeRange()},i.buffered=function(){var r=Uy(this.mediaSource,this.videoBuffer)?this.videoBuffer:null,o=Uy(this.mediaSource,this.audioBuffer)?this.audioBuffer:null;return o&&!r?this.audioBuffered():r&&!o?this.videoBuffered():tCt(this.audioBuffered(),this.videoBuffered())},i.setDuration=function(r,o){o===void 0&&(o=sS),up({type:"mediaSource",sourceUpdater:this,action:lp.duration(r),name:"duration",doneFn:o})},i.endOfStream=function(r,o){r===void 0&&(r=null),o===void 0&&(o=sS),typeof r!="string"&&(r=void 0),up({type:"mediaSource",sourceUpdater:this,action:lp.endOfStream(r),name:"endOfStream",doneFn:o})},i.removeAudio=function(r,o,a){if(a===void 0&&(a=sS),!this.audioBuffered().length||this.audioBuffered().end(0)===0){a();return}up({type:"audio",sourceUpdater:this,action:lp.remove(r,o),doneFn:a,name:"remove"})},i.removeVideo=function(r,o,a){if(a===void 0&&(a=sS),!this.videoBuffered().length||this.videoBuffered().end(0)===0){a();return}up({type:"video",sourceUpdater:this,action:lp.remove(r,o),doneFn:a,name:"remove"})},i.updating=function(){return!!(nJ("audio",this)||nJ("video",this))},i.audioTimestampOffset=function(r){return typeof r<"u"&&this.audioBuffer&&this.audioTimestampOffset_!==r&&(up({type:"audio",sourceUpdater:this,action:lp.timestampOffset(r),name:"timestampOffset"}),this.audioTimestampOffset_=r),this.audioTimestampOffset_},i.videoTimestampOffset=function(r){return typeof r<"u"&&this.videoBuffer&&this.videoTimestampOffset!==r&&(up({type:"video",sourceUpdater:this,action:lp.timestampOffset(r),name:"timestampOffset"}),this.videoTimestampOffset_=r),this.videoTimestampOffset_},i.audioQueueCallback=function(r){this.audioBuffer&&up({type:"audio",sourceUpdater:this,action:lp.callback(r),name:"callback"})},i.videoQueueCallback=function(r){this.videoBuffer&&up({type:"video",sourceUpdater:this,action:lp.callback(r),name:"callback"})},i.dispose=function(){var r=this;this.trigger("dispose"),NTt.forEach(function(o){r.abort(o),r.canRemoveSourceBuffer()?r.removeSourceBuffer(o):r[o+"QueueCallback"](function(){return fNe(o,r)})}),this.videoAppendQueued_=!1,this.delayedAudioAppendQueue_.length=0,this.sourceopenListener_&&this.mediaSource.removeEventListener("sourceopen",this.sourceopenListener_),this.off()},e})(Vt.EventTarget),jde=function(e){return decodeURIComponent(escape(String.fromCharCode.apply(null,e)))},Vde=new Uint8Array(`

`.split("").map(function(t){return t.charCodeAt(0)})),BTt=(function(t){qr(e,t);function e(){return t.call(this,"Trying to parse received VTT cues, but there is no WebVTT. Make sure vtt.js is loaded.")||this}return e})(jZ(Error)),jTt=(function(t){qr(e,t);function e(n,r){var o;return r===void 0&&(r={}),o=t.call(this,n,r)||this,o.mediaSource_=null,o.subtitlesTrack_=null,o.loaderType_="subtitle",o.featuresNativeTextTracks_=n.featuresNativeTextTracks,o.loadVttJs=n.loadVttJs,o.shouldSaveSegmentTimingInfo_=!1,o}var i=e.prototype;return i.createTransmuxer_=function(){return null},i.buffered_=function(){if(!this.subtitlesTrack_||!this.subtitlesTrack_.cues||!this.subtitlesTrack_.cues.length)return Vt.createTimeRanges();var r=this.subtitlesTrack_.cues,o=r[0].startTime,a=r[r.length-1].startTime;return Vt.createTimeRanges([[o,a]])},i.initSegmentForMap=function(r,o){if(o===void 0&&(o=!1),!r)return null;var a=Lz(r),s=this.initSegments_[a];if(o&&!s&&r.bytes){var l=Vde.byteLength+r.bytes.byteLength,u=new Uint8Array(l);u.set(r.bytes),u.set(Vde,r.bytes.byteLength),this.initSegments_[a]=s={resolvedUri:r.resolvedUri,byterange:r.byterange,bytes:u}}return s||r},i.couldBeginLoading_=function(){return this.playlist_&&this.subtitlesTrack_&&!this.paused()},i.init_=function(){return this.state="READY",this.resetEverything(),this.monitorBuffer_()},i.track=function(r){return typeof r>"u"?this.subtitlesTrack_:(this.subtitlesTrack_=r,this.state==="INIT"&&this.couldBeginLoading_()&&this.init_(),this.subtitlesTrack_)},i.remove=function(r,o){uj(r,o,this.subtitlesTrack_)},i.fillBuffer_=function(){var r=this,o=this.chooseNextRequest_();if(o){if(this.syncController_.timestampOffsetForTimeline(o.timeline)===null){var a=function(){r.state="READY",r.paused()||r.monitorBuffer_()};this.syncController_.one("timestampoffset",a),this.state="WAITING_ON_TIMELINE";return}this.loadSegment_(o)}},i.timestampOffsetForSegment_=function(){return null},i.chooseNextRequest_=function(){return this.skipEmptySegments_(t.prototype.chooseNextRequest_.call(this))},i.skipEmptySegments_=function(r){for(;r&&r.segment.empty;){if(r.mediaIndex+1>=r.playlist.segments.length){r=null;break}r=this.generateSegmentInfo_({playlist:r.playlist,mediaIndex:r.mediaIndex+1,startOfSegment:r.startOfSegment+r.duration,isSyncRequest:r.isSyncRequest})}return r},i.stopForError=function(r){this.error(r),this.state="READY",this.pause(),this.trigger("error")},i.segmentRequestFinished_=function(r,o,a){var s=this;if(!this.subtitlesTrack_){this.state="READY";return}if(this.saveTransferStats_(o.stats),!this.pendingSegment_){this.state="READY",this.mediaRequestsAborted+=1;return}if(r){r.code===tm.TIMEOUT&&this.handleTimeout_(),r.code===tm.ABORTED?this.mediaRequestsAborted+=1:this.mediaRequestsErrored+=1,this.stopForError(r);return}var l=this.pendingSegment_;this.saveBandwidthRelatedStats_(l.duration,o.stats),o.key&&this.segmentKey(o.key,!0),this.state="APPENDING",this.trigger("appending");var u=l.segment;if(u.map&&(u.map.bytes=o.map.bytes),l.bytes=o.bytes,typeof Ct.WebVTT!="function"&&typeof this.loadVttJs=="function"){this.state="WAITING_ON_VTTJS",this.loadVttJs().then(function(){return s.segmentRequestFinished_(r,o,a)},function(){return s.stopForError({message:"Error loading vtt.js"})});return}u.requested=!0;try{this.parseVTTCues_(l)}catch(c){this.stopForError({message:c.message});return}if(this.updateTimeMapping_(l,this.syncController_.timelines[l.timeline],this.playlist_),l.cues.length?l.timingInfo={start:l.cues[0].startTime,end:l.cues[l.cues.length-1].endTime}:l.timingInfo={start:l.startOfSegment,end:l.startOfSegment+l.duration},l.isSyncRequest){this.trigger("syncinfoupdate"),this.pendingSegment_=null,this.state="READY";return}l.byteLength=l.bytes.byteLength,this.mediaSecondsLoaded+=u.duration,l.cues.forEach(function(c){s.subtitlesTrack_.addCue(s.featuresNativeTextTracks_?new Ct.VTTCue(c.startTime,c.endTime,c.text):c)}),TTt(this.subtitlesTrack_),this.handleAppendsDone_()},i.handleData_=function(){},i.updateTimingInfoEnd_=function(){},i.parseVTTCues_=function(r){var o,a=!1;if(typeof Ct.WebVTT!="function")throw new BTt;typeof Ct.TextDecoder=="function"?o=new Ct.TextDecoder("utf8"):(o=Ct.WebVTT.StringDecoder(),a=!0);var s=new Ct.WebVTT.Parser(Ct,Ct.vttjs,o);if(r.cues=[],r.timestampmap={MPEGTS:0,LOCAL:0},s.oncue=r.cues.push.bind(r.cues),s.ontimestampmap=function(c){r.timestampmap=c},s.onparsingerror=function(c){Vt.log.warn("Error encountered when parsing cues: "+c.message)},r.segment.map){var l=r.segment.map.bytes;a&&(l=jde(l)),s.parse(l)}var u=r.bytes;a&&(u=jde(u)),s.parse(u),s.flush()},i.updateTimeMapping_=function(r,o,a){var s=r.segment;if(o){if(!r.cues.length){s.empty=!0;return}var l=r.timestampmap,u=l.MPEGTS/_z.ONE_SECOND_IN_TS-l.LOCAL+o.mapping;if(r.cues.forEach(function(f){f.startTime+=u,f.endTime+=u}),!a.syncInfo){var c=r.cues[0].startTime,d=r.cues[r.cues.length-1].startTime;a.syncInfo={mediaSequence:a.mediaSequence+r.mediaIndex,time:Math.min(c,d-s.duration)}}}},e})(iJ),VTt=function(e,i){for(var n=e.cues,r=0;r<n.length;r++){var o=n[r];if(i>=o.adStartTime&&i<=o.adEndTime)return o}return null},HTt=function(e,i,n){if(n===void 0&&(n=0),!!e.segments)for(var r=n,o,a=0;a<e.segments.length;a++){var s=e.segments[a];if(o||(o=VTt(i,r+s.duration/2)),o){if("cueIn"in s){o.endTime=r,o.adEndTime=r,r+=s.duration,o=null;continue}if(r<o.endTime){r+=s.duration;continue}o.endTime+=s.duration}else if("cueOut"in s&&(o=new Ct.VTTCue(r,r+s.duration,s.cueOut),o.adStartTime=r,o.adEndTime=r+parseFloat(s.cueOut),i.addCue(o)),"cueOutCont"in s){var l=s.cueOutCont.split("/").map(parseFloat),u=l[0],c=l[1];o=new Ct.VTTCue(r,r+s.duration,""),o.adStartTime=r-u,o.adEndTime=o.adStartTime+c,i.addCue(o)}r+=s.duration}},UTt=86400,Hde=[{name:"VOD",run:function(e,i,n,r,o){if(n!==1/0){var a={time:0,segmentIndex:0,partIndex:null};return a}return null}},{name:"ProgramDateTime",run:function(e,i,n,r,o){if(!Object.keys(e.timelineToDatetimeMappings).length)return null;var a=null,s=null,l=XZ(i);o=o||0;for(var u=0;u<l.length;u++){var c=i.endList||o===0?u:l.length-(u+1),d=l[c],f=d.segment,h=e.timelineToDatetimeMappings[f.timeline];if(!(!h||!f.dateTimeObject)){var p=f.dateTimeObject.getTime()/1e3,g=p+h;if(f.parts&&typeof d.partIndex=="number")for(var v=0;v<d.partIndex;v++)g+=f.parts[v].duration;var y=Math.abs(o-g);if(s!==null&&(y===0||s<y))break;s=y,a={time:g,segmentIndex:d.segmentIndex,partIndex:d.partIndex}}}return a}},{name:"Segment",run:function(e,i,n,r,o){var a=null,s=null;o=o||0;for(var l=XZ(i),u=0;u<l.length;u++){var c=i.endList||o===0?u:l.length-(u+1),d=l[c],f=d.segment,h=d.part&&d.part.start||f&&f.start;if(f.timeline===r&&typeof h<"u"){var p=Math.abs(o-h);if(s!==null&&s<p)break;(!a||s===null||s>=p)&&(s=p,a={time:h,segmentIndex:d.segmentIndex,partIndex:d.partIndex})}}return a}},{name:"Discontinuity",run:function(e,i,n,r,o){var a=null;if(o=o||0,i.discontinuityStarts&&i.discontinuityStarts.length)for(var s=null,l=0;l<i.discontinuityStarts.length;l++){var u=i.discontinuityStarts[l],c=i.discontinuitySequence+l+1,d=e.discontinuities[c];if(d){var f=Math.abs(o-d.time);if(s!==null&&s<f)break;(!a||s===null||s>=f)&&(s=f,a={time:d.time,segmentIndex:u,partIndex:null})}}return a}},{name:"Playlist",run:function(e,i,n,r,o){if(i.syncInfo){var a={time:i.syncInfo.time,segmentIndex:i.syncInfo.mediaSequence-i.mediaSequence,partIndex:null};return a}return null}}],zTt=(function(t){qr(e,t);function e(n){var r;return r=t.call(this)||this,r.timelines=[],r.discontinuities=[],r.timelineToDatetimeMappings={},r.logger_=zv("SyncController"),r}var i=e.prototype;return i.getSyncPoint=function(r,o,a,s){var l=this.runStrategies_(r,o,a,s);return l.length?this.selectSyncPoint_(l,{key:"time",value:s}):null},i.getExpiredTime=function(r,o){if(!r||!r.segments)return null;var a=this.runStrategies_(r,o,r.discontinuitySequence,0);if(!a.length)return null;var s=this.selectSyncPoint_(a,{key:"segmentIndex",value:0});return s.segmentIndex>0&&(s.time*=-1),Math.abs(s.time+Dj({defaultDuration:r.targetDuration,durationList:r.segments,startIndex:s.segmentIndex,endIndex:0}))},i.runStrategies_=function(r,o,a,s){for(var l=[],u=0;u<Hde.length;u++){var c=Hde[u],d=c.run(this,r,o,a,s);d&&(d.strategy=c.name,l.push({strategy:c.name,syncPoint:d}))}return l},i.selectSyncPoint_=function(r,o){for(var a=r[0].syncPoint,s=Math.abs(r[0].syncPoint[o.key]-o.value),l=r[0].strategy,u=1;u<r.length;u++){var c=Math.abs(r[u].syncPoint[o.key]-o.value);c<s&&(s=c,a=r[u].syncPoint,l=r[u].strategy)}return this.logger_("syncPoint for ["+o.key+": "+o.value+"] chosen with strategy"+(" ["+l+"]: [time:"+a.time+",")+(" segmentIndex:"+a.segmentIndex)+(typeof a.partIndex=="number"?",partIndex:"+a.partIndex:"")+"]"),a},i.saveExpiredSegmentInfo=function(r,o){var a=o.mediaSequence-r.mediaSequence;if(a>UTt){Vt.log.warn("Not saving expired segment info. Media sequence gap "+a+" is too large.");return}for(var s=a-1;s>=0;s--){var l=r.segments[s];if(l&&typeof l.start<"u"){o.syncInfo={mediaSequence:r.mediaSequence+s,time:l.start},this.logger_("playlist refresh sync: [time:"+o.syncInfo.time+","+(" mediaSequence: "+o.syncInfo.mediaSequence+"]")),this.trigger("syncinfoupdate");break}}},i.setDateTimeMappingForStart=function(r){if(this.timelineToDatetimeMappings={},r.segments&&r.segments.length&&r.segments[0].dateTimeObject){var o=r.segments[0],a=o.dateTimeObject.getTime()/1e3;this.timelineToDatetimeMappings[o.timeline]=-a}},i.saveSegmentTimingInfo=function(r){var o=r.segmentInfo,a=r.shouldSaveTimelineMapping,s=this.calculateSegmentTimeMapping_(o,o.timingInfo,a),l=o.segment;s&&(this.saveDiscontinuitySyncInfo_(o),o.playlist.syncInfo||(o.playlist.syncInfo={mediaSequence:o.playlist.mediaSequence+o.mediaIndex,time:l.start}));var u=l.dateTimeObject;l.discontinuity&&a&&u&&(this.timelineToDatetimeMappings[l.timeline]=-(u.getTime()/1e3))},i.timestampOffsetForTimeline=function(r){return typeof this.timelines[r]>"u"?null:this.timelines[r].time},i.mappingForTimeline=function(r){return typeof this.timelines[r]>"u"?null:this.timelines[r].mapping},i.calculateSegmentTimeMapping_=function(r,o,a){var s=r.segment,l=r.part,u=this.timelines[r.timeline],c,d;if(typeof r.timestampOffset=="number")u={time:r.startOfSegment,mapping:r.startOfSegment-o.start},a&&(this.timelines[r.timeline]=u,this.trigger("timestampoffset"),this.logger_("time mapping for timeline "+r.timeline+": "+("[time: "+u.time+"] [mapping: "+u.mapping+"]"))),c=r.startOfSegment,d=o.end+u.mapping;else if(u)c=o.start+u.mapping,d=o.end+u.mapping;else return!1;return l&&(l.start=c,l.end=d),(!s.start||c<s.start)&&(s.start=c),s.end=d,!0},i.saveDiscontinuitySyncInfo_=function(r){var o=r.playlist,a=r.segment;if(a.discontinuity)this.discontinuities[a.timeline]={time:a.start,accuracy:0};else if(o.discontinuityStarts&&o.discontinuityStarts.length)for(var s=0;s<o.discontinuityStarts.length;s++){var l=o.discontinuityStarts[s],u=o.discontinuitySequence+s+1,c=l-r.mediaIndex,d=Math.abs(c);if(!this.discontinuities[u]||this.discontinuities[u].accuracy>d){var f=void 0;c<0?f=a.start-Dj({defaultDuration:o.targetDuration,durationList:o.segments,startIndex:r.mediaIndex,endIndex:l}):f=a.end+Dj({defaultDuration:o.targetDuration,durationList:o.segments,startIndex:r.mediaIndex+1,endIndex:l}),this.discontinuities[u]={time:f,accuracy:d}}}},i.dispose=function(){this.trigger("dispose"),this.off()},e})(Vt.EventTarget),$Tt=(function(t){qr(e,t);function e(){var n;return n=t.call(this)||this,n.pendingTimelineChanges_={},n.lastTimelineChanges_={},n}var i=e.prototype;return i.clearPendingTimelineChange=function(r){this.pendingTimelineChanges_[r]=null,this.trigger("pendingtimelinechange")},i.pendingTimelineChange=function(r){var o=r.type,a=r.from,s=r.to;return typeof a=="number"&&typeof s=="number"&&(this.pendingTimelineChanges_[o]={type:o,from:a,to:s},this.trigger("pendingtimelinechange")),this.pendingTimelineChanges_[o]},i.lastTimelineChange=function(r){var o=r.type,a=r.from,s=r.to;return typeof a=="number"&&typeof s=="number"&&(this.lastTimelineChanges_[o]={type:o,from:a,to:s},delete this.pendingTimelineChanges_[o],this.trigger("timelinechange")),this.lastTimelineChanges_[o]},i.dispose=function(){this.trigger("dispose"),this.pendingTimelineChanges_={},this.lastTimelineChanges_={},this.off()},e})(Vt.EventTarget),WTt=Q2e(eNe(function(){var t=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function e(S,_,C){return C={path:_,exports:{},require:function(x,E){return i(x,E??C.path)}},S(C,C.exports),C.exports}function i(){throw new Error("Dynamic requires are not currently supported by @rollup/plugin-commonjs")}var n=e(function(S){function _(P,x){for(var E=0;E<x.length;E++){var A=x[E];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(P,A.key,A)}}function C(P,x,E){return x&&_(P.prototype,x),E&&_(P,E),P}S.exports=C,S.exports.default=S.exports,S.exports.__esModule=!0}),r=e(function(S){function _(C,P){return S.exports=_=Object.setPrototypeOf||function(E,A){return E.__proto__=A,E},S.exports.default=S.exports,S.exports.__esModule=!0,_(C,P)}S.exports=_,S.exports.default=S.exports,S.exports.__esModule=!0}),o=e(function(S){function _(C,P){C.prototype=Object.create(P.prototype),C.prototype.constructor=C,r(C,P)}S.exports=_,S.exports.default=S.exports,S.exports.__esModule=!0}),a=(function(){function S(){this.listeners={}}var _=S.prototype;return _.on=function(P,x){this.listeners[P]||(this.listeners[P]=[]),this.listeners[P].push(x)},_.off=function(P,x){if(!this.listeners[P])return!1;var E=this.listeners[P].indexOf(x);return this.listeners[P]=this.listeners[P].slice(0),this.listeners[P].splice(E,1),E>-1},_.trigger=function(P){var x=this.listeners[P];if(x)if(arguments.length===2)for(var E=x.length,A=0;A<E;++A)x[A].call(this,arguments[1]);else for(var R=Array.prototype.slice.call(arguments,1),M=x.length,D=0;D<M;++D)x[D].apply(this,R)},_.dispose=function(){this.listeners={}},_.pipe=function(P){this.on("data",function(x){P.push(x)})},S})();/*! @name pkcs7 @version 1.0.4 @license Apache-2.0 */function s(S){return S.subarray(0,S.byteLength-S[S.byteLength-1])}/*! @name aes-decrypter @version 3.1.3 @license Apache-2.0 */var l=function(){var _=[[[],[],[],[],[]],[[],[],[],[],[]]],C=_[0],P=_[1],x=C[4],E=P[4],A,R,M,D=[],F=[],I,V,z,G,H,U;for(A=0;A<256;A++)F[(D[A]=A<<1^(A>>7)*283)^A]=A;for(R=M=0;!x[R];R^=I||1,M=F[M]||1)for(G=M^M<<1^M<<2^M<<3^M<<4,G=G>>8^G&255^99,x[R]=G,E[G]=R,z=D[V=D[I=D[R]]],U=z*16843009^V*65537^I*257^R*16843008,H=D[G]*257^G*16843008,A=0;A<4;A++)C[A][R]=H=H<<24^H>>>8,P[A][G]=U=U<<24^U>>>8;for(A=0;A<5;A++)C[A]=C[A].slice(0),P[A]=P[A].slice(0);return _},u=null,c=(function(){function S(C){u||(u=l()),this._tables=[[u[0][0].slice(),u[0][1].slice(),u[0][2].slice(),u[0][3].slice(),u[0][4].slice()],[u[1][0].slice(),u[1][1].slice(),u[1][2].slice(),u[1][3].slice(),u[1][4].slice()]];var P,x,E,A=this._tables[0][4],R=this._tables[1],M=C.length,D=1;if(M!==4&&M!==6&&M!==8)throw new Error("Invalid aes key size");var F=C.slice(0),I=[];for(this._key=[F,I],P=M;P<4*M+28;P++)E=F[P-1],(P%M===0||M===8&&P%M===4)&&(E=A[E>>>24]<<24^A[E>>16&255]<<16^A[E>>8&255]<<8^A[E&255],P%M===0&&(E=E<<8^E>>>24^D<<24,D=D<<1^(D>>7)*283)),F[P]=F[P-M]^E;for(x=0;P;x++,P--)E=F[x&3?P:P-4],P<=4||x<4?I[x]=E:I[x]=R[0][A[E>>>24]]^R[1][A[E>>16&255]]^R[2][A[E>>8&255]]^R[3][A[E&255]]}var _=S.prototype;return _.decrypt=function(P,x,E,A,R,M){var D=this._key[1],F=P^D[0],I=A^D[1],V=E^D[2],z=x^D[3],G,H,U,k=D.length/4-2,X,W=4,Y=this._tables[1],te=Y[0],oe=Y[1],de=Y[2],ge=Y[3],Ee=Y[4];for(X=0;X<k;X++)G=te[F>>>24]^oe[I>>16&255]^de[V>>8&255]^ge[z&255]^D[W],H=te[I>>>24]^oe[V>>16&255]^de[z>>8&255]^ge[F&255]^D[W+1],U=te[V>>>24]^oe[z>>16&255]^de[F>>8&255]^ge[I&255]^D[W+2],z=te[z>>>24]^oe[F>>16&255]^de[I>>8&255]^ge[V&255]^D[W+3],W+=4,F=G,I=H,V=U;for(X=0;X<4;X++)R[(3&-X)+M]=Ee[F>>>24]<<24^Ee[I>>16&255]<<16^Ee[V>>8&255]<<8^Ee[z&255]^D[W++],G=F,F=I,I=V,V=z,z=G},S})(),d=(function(S){o(_,S);function _(){var P;return P=S.call(this,a)||this,P.jobs=[],P.delay=1,P.timeout_=null,P}var C=_.prototype;return C.processJob_=function(){this.jobs.shift()(),this.jobs.length?this.timeout_=setTimeout(this.processJob_.bind(this),this.delay):this.timeout_=null},C.push=function(x){this.jobs.push(x),this.timeout_||(this.timeout_=setTimeout(this.processJob_.bind(this),this.delay))},_})(a),f=function(_){return _<<24|(_&65280)<<8|(_&16711680)>>8|_>>>24},h=function(_,C,P){var x=new Int32Array(_.buffer,_.byteOffset,_.byteLength>>2),E=new c(Array.prototype.slice.call(C)),A=new Uint8Array(_.byteLength),R=new Int32Array(A.buffer),M,D,F,I,V,z,G,H,U;for(M=P[0],D=P[1],F=P[2],I=P[3],U=0;U<x.length;U+=4)V=f(x[U]),z=f(x[U+1]),G=f(x[U+2]),H=f(x[U+3]),E.decrypt(V,z,G,H,R,U),R[U]=f(R[U]^M),R[U+1]=f(R[U+1]^D),R[U+2]=f(R[U+2]^F),R[U+3]=f(R[U+3]^I),M=V,D=z,F=G,I=H;return A},p=(function(){function S(C,P,x,E){var A=S.STEP,R=new Int32Array(C.buffer),M=new Uint8Array(C.byteLength),D=0;for(this.asyncStream_=new d,this.asyncStream_.push(this.decryptChunk_(R.subarray(D,D+A),P,x,M)),D=A;D<R.length;D+=A)x=new Uint32Array([f(R[D-4]),f(R[D-3]),f(R[D-2]),f(R[D-1])]),this.asyncStream_.push(this.decryptChunk_(R.subarray(D,D+A),P,x,M));this.asyncStream_.push(function(){E(null,s(M))})}var _=S.prototype;return _.decryptChunk_=function(P,x,E,A){return function(){var R=h(P,x,E);A.set(R,P.byteOffset)}},n(S,null,[{key:"STEP",get:function(){return 32e3}}]),S})(),g;typeof window<"u"?g=window:typeof t<"u"?g=t:typeof self<"u"?g=self:g={};var v=g,y=function(_){return ArrayBuffer.isView==="function"?ArrayBuffer.isView(_):_&&_.buffer instanceof ArrayBuffer},m=v.BigInt||Number;m("0x1"),m("0x100"),m("0x10000"),m("0x1000000"),m("0x100000000"),m("0x10000000000"),m("0x1000000000000"),m("0x100000000000000"),m("0x10000000000000000");var b=function(_){var C={};return Object.keys(_).forEach(function(P){var x=_[P];y(x)?C[P]={bytes:x.buffer,byteOffset:x.byteOffset,byteLength:x.byteLength}:C[P]=x}),C};self.onmessage=function(S){var _=S.data,C=new Uint8Array(_.encrypted.bytes,_.encrypted.byteOffset,_.encrypted.byteLength),P=new Uint32Array(_.key.bytes,_.key.byteOffset,_.key.byteLength/4),x=new Uint32Array(_.iv.bytes,_.iv.byteOffset,_.iv.byteLength/4);new p(C,P,x,function(E,A){self.postMessage(b({source:_.source,decrypted:A}),[A.buffer])})}})),GTt=J2e(WTt),YTt=function(e){var i=e.default?"main":"alternative";return e.characteristics&&e.characteristics.indexOf("public.accessibility.describes-video")>=0&&(i="main-desc"),i},Fz=function(e,i){e.abort(),e.pause(),i&&i.activePlaylistLoader&&(i.activePlaylistLoader.pause(),i.activePlaylistLoader=null)},oJ=function(e,i){i.activePlaylistLoader=e,e.load()},qTt=function(e,i){return function(){var n=i.segmentLoaders,r=n[e],o=n.main,a=i.mediaTypes[e],s=a.activeTrack(),l=a.getActiveGroup(),u=a.activePlaylistLoader,c=a.lastGroup_;if(!(l&&c&&l.id===c.id)&&(a.lastGroup_=l,a.lastTrack_=s,Fz(r,a),!(!l||l.isMasterPlaylist))){if(!l.playlistLoader){u&&o.resetEverything();return}r.resyncLoader(),oJ(l.playlistLoader,a)}}},XTt=function(e,i){return function(){var n=i.segmentLoaders[e],r=i.mediaTypes[e];r.lastGroup_=null,n.abort(),n.pause()}},KTt=function(e,i){return function(){var n=i.masterPlaylistLoader,r=i.segmentLoaders,o=r[e],a=r.main,s=i.mediaTypes[e],l=s.activeTrack(),u=s.getActiveGroup(),c=s.activePlaylistLoader,d=s.lastTrack_;if(!(d&&l&&d.id===l.id)&&(s.lastGroup_=u,s.lastTrack_=l,Fz(o,s),!!u)){if(u.isMasterPlaylist){if(!l||!d||l.id===d.id)return;var f=i.vhs.masterPlaylistController_,h=f.selectPlaylist();if(f.media()===h)return;s.logger_("track change. Switching master audio from "+d.id+" to "+l.id),n.pause(),a.resetEverything(),f.fastQualityChange_(h);return}if(e==="AUDIO"){if(!u.playlistLoader){a.setAudio(!0),a.resetEverything();return}o.setAudio(!0),a.setAudio(!1)}if(c===u.playlistLoader){oJ(u.playlistLoader,s);return}o.track&&o.track(l),o.resetEverything(),oJ(u.playlistLoader,s)}}},Bz={AUDIO:function(e,i){return function(){var n=i.segmentLoaders[e],r=i.mediaTypes[e],o=i.blacklistCurrentPlaylist;Fz(n,r);var a=r.activeTrack(),s=r.activeGroup(),l=(s.filter(function(d){return d.default})[0]||s[0]).id,u=r.tracks[l];if(a===u){o({message:"Problem encountered loading the default audio track."});return}Vt.log.warn("Problem encountered loading the alternate audio track.Switching back to default.");for(var c in r.tracks)r.tracks[c].enabled=r.tracks[c]===u;r.onTrackChanged()}},SUBTITLES:function(e,i){return function(){var n=i.segmentLoaders[e],r=i.mediaTypes[e];Vt.log.warn("Problem encountered loading the subtitle track.Disabling subtitle track."),Fz(n,r);var o=r.activeTrack();o&&(o.mode="disabled"),r.onTrackChanged()}}},Ude={AUDIO:function(e,i,n){if(i){var r=n.tech,o=n.requestOptions,a=n.segmentLoaders[e];i.on("loadedmetadata",function(){var s=i.media();a.playlist(s,o),(!r.paused()||s.endList&&r.preload()!=="none")&&a.load()}),i.on("loadedplaylist",function(){a.playlist(i.media(),o),r.paused()||a.load()}),i.on("error",Bz[e](e,n))}},SUBTITLES:function(e,i,n){var r=n.tech,o=n.requestOptions,a=n.segmentLoaders[e],s=n.mediaTypes[e];i.on("loadedmetadata",function(){var l=i.media();a.playlist(l,o),a.track(s.activeTrack()),(!r.paused()||l.endList&&r.preload()!=="none")&&a.load()}),i.on("loadedplaylist",function(){a.playlist(i.media(),o),r.paused()||a.load()}),i.on("error",Bz[e](e,n))}},ZTt={AUDIO:function(e,i){var n=i.vhs,r=i.sourceType,o=i.segmentLoaders[e],a=i.requestOptions,s=i.master.mediaGroups,l=i.mediaTypes[e],u=l.groups,c=l.tracks,d=l.logger_,f=i.masterPlaylistLoader,h=zV(f.master);(!s[e]||Object.keys(s[e]).length===0)&&(s[e]={main:{default:{default:!0}}},h&&(s[e].main.default.playlists=f.master.playlists));for(var p in s[e]){u[p]||(u[p]=[]);for(var g in s[e][p]){var v=s[e][p][g],y=void 0;if(h?(d("AUDIO group '"+p+"' label '"+g+"' is a master playlist"),v.isMasterPlaylist=!0,y=null):r==="vhs-json"&&v.playlists?y=new DL(v.playlists[0],n,a):v.resolvedUri?y=new DL(v.resolvedUri,n,a):v.playlists&&r==="dash"?y=new tJ(v.playlists[0],n,a,f):y=null,v=Vt.mergeOptions({id:g,playlistLoader:y},v),Ude[e](e,v.playlistLoader,i),u[p].push(v),typeof c[g]>"u"){var m=new Vt.AudioTrack({id:g,kind:YTt(v),enabled:!1,language:v.language,default:v.default,label:g});c[g]=m}}}o.on("error",Bz[e](e,i))},SUBTITLES:function(e,i){var n=i.tech,r=i.vhs,o=i.sourceType,a=i.segmentLoaders[e],s=i.requestOptions,l=i.master.mediaGroups,u=i.mediaTypes[e],c=u.groups,d=u.tracks,f=i.masterPlaylistLoader;for(var h in l[e]){c[h]||(c[h]=[]);for(var p in l[e][h])if(!l[e][h][p].forced){var g=l[e][h][p],v=void 0;if(o==="hls")v=new DL(g.resolvedUri,r,s);else if(o==="dash"){var y=g.playlists.filter(function(b){return b.excludeUntil!==1/0});if(!y.length)return;v=new tJ(g.playlists[0],r,s,f)}else o==="vhs-json"&&(v=new DL(g.playlists?g.playlists[0]:g.resolvedUri,r,s));if(g=Vt.mergeOptions({id:p,playlistLoader:v},g),Ude[e](e,g.playlistLoader,i),c[h].push(g),typeof d[p]>"u"){var m=n.addRemoteTextTrack({id:p,kind:"subtitles",default:g.default&&g.autoselect,language:g.language,label:p},!1).track;d[p]=m}}}a.on("error",Bz[e](e,i))},"CLOSED-CAPTIONS":function(e,i){var n=i.tech,r=i.master.mediaGroups,o=i.mediaTypes[e],a=o.groups,s=o.tracks;for(var l in r[e]){a[l]||(a[l]=[]);for(var u in r[e][l]){var c=r[e][l][u];if(/^(?:CC|SERVICE)/.test(c.instreamId)){var d=n.options_.vhs&&n.options_.vhs.captionServices||{},f={label:u,language:c.language,instreamId:c.instreamId,default:c.default&&c.autoselect};if(d[f.instreamId]&&(f=Vt.mergeOptions(f,d[f.instreamId])),f.default===void 0&&delete f.default,a[l].push(Vt.mergeOptions({id:u},c)),typeof s[u]>"u"){var h=n.addRemoteTextTrack({id:f.instreamId,kind:"captions",default:f.default,language:f.language,label:f.label},!1).track;s[u]=h}}}}}},JTt=function t(e,i){for(var n=0;n<e.length;n++)if(ere(i,e[n])||e[n].playlists&&t(e[n].playlists,i))return!0;return!1},QTt=function(e,i){return function(n){var r=i.masterPlaylistLoader,o=i.mediaTypes[e].groups,a=r.media();if(!a)return null;var s=null;a.attributes[e]&&(s=o[a.attributes[e]]);var l=Object.keys(o);if(!s)if(e==="AUDIO"&&l.length>1&&zV(i.master))for(var u=0;u<l.length;u++){var c=o[l[u]];if(JTt(c,a)){s=c;break}}else o.main?s=o.main:l.length===1&&(s=o[l[0]]);return typeof n>"u"?s:n===null||!s?null:s.filter(function(d){return d.id===n.id})[0]||null}},e1t={AUDIO:function(e,i){return function(){var n=i.mediaTypes[e].tracks;for(var r in n)if(n[r].enabled)return n[r];return null}},SUBTITLES:function(e,i){return function(){var n=i.mediaTypes[e].tracks;for(var r in n)if(n[r].mode==="showing"||n[r].mode==="hidden")return n[r];return null}}},t1t=function(e,i){var n=i.mediaTypes;return function(){var r=n[e].activeTrack();return r?n[e].activeGroup(r):null}},r1t=function(e){["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(p){ZTt[p](p,e)});var i=e.mediaTypes,n=e.masterPlaylistLoader,r=e.tech,o=e.vhs,a=e.segmentLoaders,s=a.AUDIO,l=a.main;["AUDIO","SUBTITLES"].forEach(function(p){i[p].activeGroup=QTt(p,e),i[p].activeTrack=e1t[p](p,e),i[p].onGroupChanged=qTt(p,e),i[p].onGroupChanging=XTt(p,e),i[p].onTrackChanged=KTt(p,e),i[p].getActiveGroup=t1t(p,e)});var u=i.AUDIO.activeGroup();if(u){var c=(u.filter(function(p){return p.default})[0]||u[0]).id;i.AUDIO.tracks[c].enabled=!0,i.AUDIO.onGroupChanged(),i.AUDIO.onTrackChanged();var d=i.AUDIO.getActiveGroup();d.playlistLoader?(l.setAudio(!1),s.setAudio(!0)):l.setAudio(!0)}n.on("mediachange",function(){["AUDIO","SUBTITLES"].forEach(function(p){return i[p].onGroupChanged()})}),n.on("mediachanging",function(){["AUDIO","SUBTITLES"].forEach(function(p){return i[p].onGroupChanging()})});var f=function(){i.AUDIO.onTrackChanged(),r.trigger({type:"usage",name:"vhs-audio-change"}),r.trigger({type:"usage",name:"hls-audio-change"})};r.audioTracks().addEventListener("change",f),r.remoteTextTracks().addEventListener("change",i.SUBTITLES.onTrackChanged),o.on("dispose",function(){r.audioTracks().removeEventListener("change",f),r.remoteTextTracks().removeEventListener("change",i.SUBTITLES.onTrackChanged)}),r.clearTracks("audio");for(var h in i.AUDIO.tracks)r.audioTracks().addTrack(i.AUDIO.tracks[h])},i1t=function(){var e={};return["AUDIO","SUBTITLES","CLOSED-CAPTIONS"].forEach(function(i){e[i]={groups:{},tracks:{},activePlaylistLoader:null,activeGroup:sS,activeTrack:sS,getActiveGroup:sS,onGroupChanged:sS,onTrackChanged:sS,lastTrack_:null,logger_:zv("MediaGroups["+i+"]")}}),e},n1t=120,M0,o1t=["mediaRequests","mediaRequestsAborted","mediaRequestsTimedout","mediaRequestsErrored","mediaTransferDuration","mediaBytesTransferred","mediaAppends"],a1t=function(e){return this.audioSegmentLoader_[e]+this.mainSegmentLoader_[e]},s1t=function(e){var i=e.currentPlaylist,n=e.buffered,r=e.currentTime,o=e.nextPlaylist,a=e.bufferLowWaterLine,s=e.bufferHighWaterLine,l=e.duration,u=e.experimentalBufferBasedABR,c=e.log;if(!o)return Vt.log.warn("We received no playlist to switch to. Please check your stream."),!1;var d="allowing switch "+(i&&i.id||"null")+" -> "+o.id;if(!i)return c(d+" as current playlist is not set"),!0;if(o.id===i.id)return!1;var f=!!OL(n,r).length;if(!i.endList)return!f&&typeof i.partTargetDuration=="number"?(c("not "+d+" as current playlist is live llhls, but currentTime isn't in buffered."),!1):(c(d+" as current playlist is live"),!0);var h=Zte(n,r),p=u?Pc.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE:Pc.MAX_BUFFER_LOW_WATER_LINE;if(l<p)return c(d+" as duration < max low water line ("+l+" < "+p+")"),!0;var g=o.attributes.BANDWIDTH,v=i.attributes.BANDWIDTH;if(g<v&&(!u||h<s)){var y=d+" as next bandwidth < current bandwidth ("+g+" < "+v+")";return u&&(y+=" and forwardBuffer < bufferHighWaterLine ("+h+" < "+s+")"),c(y),!0}if((!u||g>v)&&h>=a){var m=d+" as forwardBuffer >= bufferLowWaterLine ("+h+" >= "+a+")";return u&&(m+=" and next bandwidth > current bandwidth ("+g+" > "+v+")"),c(m),!0}return c("not "+d+" as no switching criteria met"),!1},l1t=(function(t){qr(e,t);function e(n){var r;r=t.call(this)||this;var o=n.src,a=n.handleManifestRedirects,s=n.withCredentials,l=n.tech,u=n.bandwidth,c=n.externVhs,d=n.useCueTags,f=n.blacklistDuration,h=n.enableLowInitialPlaylist,p=n.sourceType,g=n.cacheEncryptionKeys,v=n.experimentalBufferBasedABR,y=n.experimentalLeastPixelDiffSelector,m=n.captionServices;if(!o)throw new Error("A non-empty playlist URL or JSON manifest string is required");var b=n.maxPlaylistRetries;(b===null||typeof b>"u")&&(b=1/0),M0=c,r.experimentalBufferBasedABR=!!v,r.experimentalLeastPixelDiffSelector=!!y,r.withCredentials=s,r.tech_=l,r.vhs_=l.vhs,r.sourceType_=p,r.useCueTags_=d,r.blacklistDuration=f,r.maxPlaylistRetries=b,r.enableLowInitialPlaylist=h,r.useCueTags_&&(r.cueTagsTrack_=r.tech_.addTextTrack("metadata","ad-cues"),r.cueTagsTrack_.inBandMetadataTrackDispatchType=""),r.requestOptions_={withCredentials:s,handleManifestRedirects:a,maxPlaylistRetries:b,timeout:null},r.on("error",r.pauseLoading),r.mediaTypes_=i1t(),r.mediaSource=new Ct.MediaSource,r.handleDurationChange_=r.handleDurationChange_.bind(bn(r)),r.handleSourceOpen_=r.handleSourceOpen_.bind(bn(r)),r.handleSourceEnded_=r.handleSourceEnded_.bind(bn(r)),r.mediaSource.addEventListener("durationchange",r.handleDurationChange_),r.mediaSource.addEventListener("sourceopen",r.handleSourceOpen_),r.mediaSource.addEventListener("sourceended",r.handleSourceEnded_),r.seekable_=Vt.createTimeRanges(),r.hasPlayed_=!1,r.syncController_=new zTt(n),r.segmentMetadataTrack_=l.addRemoteTextTrack({kind:"metadata",label:"segment-metadata"},!1).track,r.decrypter_=new GTt,r.sourceUpdater_=new hNe(r.mediaSource),r.inbandTextTracks_={},r.timelineChangeController_=new $Tt;var S={vhs:r.vhs_,parse708captions:n.parse708captions,useDtsForTimestampOffset:n.useDtsForTimestampOffset,captionServices:m,mediaSource:r.mediaSource,currentTime:r.tech_.currentTime.bind(r.tech_),seekable:function(){return r.seekable()},seeking:function(){return r.tech_.seeking()},duration:function(){return r.duration()},hasPlayed:function(){return r.hasPlayed_},goalBufferLength:function(){return r.goalBufferLength()},bandwidth:u,syncController:r.syncController_,decrypter:r.decrypter_,sourceType:r.sourceType_,inbandTextTracks:r.inbandTextTracks_,cacheEncryptionKeys:g,sourceUpdater:r.sourceUpdater_,timelineChangeController:r.timelineChangeController_,experimentalExactManifestTimings:n.experimentalExactManifestTimings};r.masterPlaylistLoader_=r.sourceType_==="dash"?new tJ(o,r.vhs_,r.requestOptions_):new DL(o,r.vhs_,r.requestOptions_),r.setupMasterPlaylistLoaderListeners_(),r.mainSegmentLoader_=new iJ(Vt.mergeOptions(S,{segmentMetadataTrack:r.segmentMetadataTrack_,loaderType:"main"}),n),r.audioSegmentLoader_=new iJ(Vt.mergeOptions(S,{loaderType:"audio"}),n),r.subtitleSegmentLoader_=new jTt(Vt.mergeOptions(S,{loaderType:"vtt",featuresNativeTextTracks:r.tech_.featuresNativeTextTracks,loadVttJs:function(){return new Promise(function(P,x){function E(){l.off("vttjserror",A),P()}function A(){l.off("vttjsloaded",E),x()}l.one("vttjsloaded",E),l.one("vttjserror",A),l.addWebVttScript_()})}}),n),r.setupSegmentLoaderListeners_(),r.experimentalBufferBasedABR&&(r.masterPlaylistLoader_.one("loadedplaylist",function(){return r.startABRTimer_()}),r.tech_.on("pause",function(){return r.stopABRTimer_()}),r.tech_.on("play",function(){return r.startABRTimer_()})),o1t.forEach(function(C){r[C+"_"]=a1t.bind(bn(r),C)}),r.logger_=zv("MPC"),r.triggeredFmp4Usage=!1,r.tech_.preload()==="none"?(r.loadOnPlay_=function(){r.loadOnPlay_=null,r.masterPlaylistLoader_.load()},r.tech_.one("play",r.loadOnPlay_)):r.masterPlaylistLoader_.load(),r.timeToLoadedData__=-1,r.mainAppendsToLoadedData__=-1,r.audioAppendsToLoadedData__=-1;var _=r.tech_.preload()==="none"?"play":"loadstart";return r.tech_.one(_,function(){var C=Date.now();r.tech_.one("loadeddata",function(){r.timeToLoadedData__=Date.now()-C,r.mainAppendsToLoadedData__=r.mainSegmentLoader_.mediaAppends,r.audioAppendsToLoadedData__=r.audioSegmentLoader_.mediaAppends})}),r}var i=e.prototype;return i.mainAppendsToLoadedData_=function(){return this.mainAppendsToLoadedData__},i.audioAppendsToLoadedData_=function(){return this.audioAppendsToLoadedData__},i.appendsToLoadedData_=function(){var r=this.mainAppendsToLoadedData_(),o=this.audioAppendsToLoadedData_();return r===-1||o===-1?-1:r+o},i.timeToLoadedData_=function(){return this.timeToLoadedData__},i.checkABR_=function(r){r===void 0&&(r="abr");var o=this.selectPlaylist();o&&this.shouldSwitchToMedia_(o)&&this.switchMedia_(o,r)},i.switchMedia_=function(r,o,a){var s=this.media(),l=s&&(s.id||s.uri),u=r.id||r.uri;l&&l!==u&&(this.logger_("switch media "+l+" -> "+u+" from "+o),this.tech_.trigger({type:"usage",name:"vhs-rendition-change-"+o})),this.masterPlaylistLoader_.media(r,a)},i.startABRTimer_=function(){var r=this;this.stopABRTimer_(),this.abrTimer_=Ct.setInterval(function(){return r.checkABR_()},250)},i.stopABRTimer_=function(){this.tech_.scrubbing&&this.tech_.scrubbing()||(Ct.clearInterval(this.abrTimer_),this.abrTimer_=null)},i.getAudioTrackPlaylists_=function(){var r=this.master(),o=r&&r.playlists||[];if(!r||!r.mediaGroups||!r.mediaGroups.AUDIO)return o;var a=r.mediaGroups.AUDIO,s=Object.keys(a),l;if(Object.keys(this.mediaTypes_.AUDIO.groups).length)l=this.mediaTypes_.AUDIO.activeTrack();else{var u=a.main||s.length&&a[s[0]];for(var c in u)if(u[c].default){l={label:c};break}}if(!l)return o;var d=[];for(var f in a)if(a[f][l.label]){var h=a[f][l.label];if(h.playlists&&h.playlists.length)d.push.apply(d,h.playlists);else if(h.uri)d.push(h);else if(r.playlists.length)for(var p=0;p<r.playlists.length;p++){var g=r.playlists[p];g.attributes&&g.attributes.AUDIO&&g.attributes.AUDIO===f&&d.push(g)}}return d.length?d:o},i.setupMasterPlaylistLoaderListeners_=function(){var r=this;this.masterPlaylistLoader_.on("loadedmetadata",function(){var o=r.masterPlaylistLoader_.media(),a=o.targetDuration*1.5*1e3;KZ(r.masterPlaylistLoader_.master,r.masterPlaylistLoader_.media())?r.requestOptions_.timeout=0:r.requestOptions_.timeout=a,o.endList&&r.tech_.preload()!=="none"&&(r.mainSegmentLoader_.playlist(o,r.requestOptions_),r.mainSegmentLoader_.load()),r1t({sourceType:r.sourceType_,segmentLoaders:{AUDIO:r.audioSegmentLoader_,SUBTITLES:r.subtitleSegmentLoader_,main:r.mainSegmentLoader_},tech:r.tech_,requestOptions:r.requestOptions_,masterPlaylistLoader:r.masterPlaylistLoader_,vhs:r.vhs_,master:r.master(),mediaTypes:r.mediaTypes_,blacklistCurrentPlaylist:r.blacklistCurrentPlaylist.bind(r)}),r.triggerPresenceUsage_(r.master(),o),r.setupFirstPlay(),!r.mediaTypes_.AUDIO.activePlaylistLoader||r.mediaTypes_.AUDIO.activePlaylistLoader.media()?r.trigger("selectedinitialmedia"):r.mediaTypes_.AUDIO.activePlaylistLoader.one("loadedmetadata",function(){r.trigger("selectedinitialmedia")})}),this.masterPlaylistLoader_.on("loadedplaylist",function(){r.loadOnPlay_&&r.tech_.off("play",r.loadOnPlay_);var o=r.masterPlaylistLoader_.media();if(!o){r.excludeUnsupportedVariants_();var a;if(r.enableLowInitialPlaylist&&(a=r.selectInitialPlaylist()),a||(a=r.selectPlaylist()),!a||!r.shouldSwitchToMedia_(a))return;r.initialMedia_=a,r.switchMedia_(r.initialMedia_,"initial");var s=r.sourceType_==="vhs-json"&&r.initialMedia_.segments;if(!s)return;o=r.initialMedia_}r.handleUpdatedMediaPlaylist(o)}),this.masterPlaylistLoader_.on("error",function(){r.blacklistCurrentPlaylist(r.masterPlaylistLoader_.error)}),this.masterPlaylistLoader_.on("mediachanging",function(){r.mainSegmentLoader_.abort(),r.mainSegmentLoader_.pause()}),this.masterPlaylistLoader_.on("mediachange",function(){var o=r.masterPlaylistLoader_.media(),a=o.targetDuration*1.5*1e3;KZ(r.masterPlaylistLoader_.master,r.masterPlaylistLoader_.media())?r.requestOptions_.timeout=0:r.requestOptions_.timeout=a,r.masterPlaylistLoader_.load(),r.mainSegmentLoader_.playlist(o,r.requestOptions_),r.mainSegmentLoader_.load(),r.tech_.trigger({type:"mediachange",bubbles:!0})}),this.masterPlaylistLoader_.on("playlistunchanged",function(){var o=r.masterPlaylistLoader_.media();if(o.lastExcludeReason_!=="playlist-unchanged"){var a=r.stuckAtPlaylistEnd_(o);a&&(r.blacklistCurrentPlaylist({message:"Playlist no longer updating.",reason:"playlist-unchanged"}),r.tech_.trigger("playliststuck"))}}),this.masterPlaylistLoader_.on("renditiondisabled",function(){r.tech_.trigger({type:"usage",name:"vhs-rendition-disabled"}),r.tech_.trigger({type:"usage",name:"hls-rendition-disabled"})}),this.masterPlaylistLoader_.on("renditionenabled",function(){r.tech_.trigger({type:"usage",name:"vhs-rendition-enabled"}),r.tech_.trigger({type:"usage",name:"hls-rendition-enabled"})})},i.handleUpdatedMediaPlaylist=function(r){this.useCueTags_&&this.updateAdCues_(r),this.mainSegmentLoader_.playlist(r,this.requestOptions_),this.updateDuration(!r.endList),this.tech_.paused()||(this.mainSegmentLoader_.load(),this.audioSegmentLoader_&&this.audioSegmentLoader_.load())},i.triggerPresenceUsage_=function(r,o){var a=r.mediaGroups||{},s=!0,l=Object.keys(a.AUDIO);for(var u in a.AUDIO)for(var c in a.AUDIO[u]){var d=a.AUDIO[u][c];d.uri||(s=!1)}s&&(this.tech_.trigger({type:"usage",name:"vhs-demuxed"}),this.tech_.trigger({type:"usage",name:"hls-demuxed"})),Object.keys(a.SUBTITLES).length&&(this.tech_.trigger({type:"usage",name:"vhs-webvtt"}),this.tech_.trigger({type:"usage",name:"hls-webvtt"})),M0.Playlist.isAes(o)&&(this.tech_.trigger({type:"usage",name:"vhs-aes"}),this.tech_.trigger({type:"usage",name:"hls-aes"})),l.length&&Object.keys(a.AUDIO[l[0]]).length>1&&(this.tech_.trigger({type:"usage",name:"vhs-alternate-audio"}),this.tech_.trigger({type:"usage",name:"hls-alternate-audio"})),this.useCueTags_&&(this.tech_.trigger({type:"usage",name:"vhs-playlist-cue-tags"}),this.tech_.trigger({type:"usage",name:"hls-playlist-cue-tags"}))},i.shouldSwitchToMedia_=function(r){var o=this.masterPlaylistLoader_.media()||this.masterPlaylistLoader_.pendingMedia_,a=this.tech_.currentTime(),s=this.bufferLowWaterLine(),l=this.bufferHighWaterLine(),u=this.tech_.buffered();return s1t({buffered:u,currentTime:a,currentPlaylist:o,nextPlaylist:r,bufferLowWaterLine:s,bufferHighWaterLine:l,duration:this.duration(),experimentalBufferBasedABR:this.experimentalBufferBasedABR,log:this.logger_})},i.setupSegmentLoaderListeners_=function(){var r=this;this.mainSegmentLoader_.on("bandwidthupdate",function(){r.checkABR_("bandwidthupdate"),r.tech_.trigger("bandwidthupdate")}),this.mainSegmentLoader_.on("timeout",function(){r.experimentalBufferBasedABR&&r.mainSegmentLoader_.load()}),this.experimentalBufferBasedABR||this.mainSegmentLoader_.on("progress",function(){r.trigger("progress")}),this.mainSegmentLoader_.on("error",function(){r.blacklistCurrentPlaylist(r.mainSegmentLoader_.error())}),this.mainSegmentLoader_.on("appenderror",function(){r.error=r.mainSegmentLoader_.error_,r.trigger("error")}),this.mainSegmentLoader_.on("syncinfoupdate",function(){r.onSyncInfoUpdate_()}),this.mainSegmentLoader_.on("timestampoffset",function(){r.tech_.trigger({type:"usage",name:"vhs-timestamp-offset"}),r.tech_.trigger({type:"usage",name:"hls-timestamp-offset"})}),this.audioSegmentLoader_.on("syncinfoupdate",function(){r.onSyncInfoUpdate_()}),this.audioSegmentLoader_.on("appenderror",function(){r.error=r.audioSegmentLoader_.error_,r.trigger("error")}),this.mainSegmentLoader_.on("ended",function(){r.logger_("main segment loader ended"),r.onEndOfStream()}),this.mainSegmentLoader_.on("earlyabort",function(a){r.experimentalBufferBasedABR||(r.delegateLoaders_("all",["abort"]),r.blacklistCurrentPlaylist({message:"Aborted early because there isn't enough bandwidth to complete the request without rebuffering."},n1t))});var o=function(){if(!r.sourceUpdater_.hasCreatedSourceBuffers())return r.tryToCreateSourceBuffers_();var s=r.getCodecsOrExclude_();s&&r.sourceUpdater_.addOrChangeSourceBuffers(s)};this.mainSegmentLoader_.on("trackinfo",o),this.audioSegmentLoader_.on("trackinfo",o),this.mainSegmentLoader_.on("fmp4",function(){r.triggeredFmp4Usage||(r.tech_.trigger({type:"usage",name:"vhs-fmp4"}),r.tech_.trigger({type:"usage",name:"hls-fmp4"}),r.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("fmp4",function(){r.triggeredFmp4Usage||(r.tech_.trigger({type:"usage",name:"vhs-fmp4"}),r.tech_.trigger({type:"usage",name:"hls-fmp4"}),r.triggeredFmp4Usage=!0)}),this.audioSegmentLoader_.on("ended",function(){r.logger_("audioSegmentLoader ended"),r.onEndOfStream()})},i.mediaSecondsLoaded_=function(){return Math.max(this.audioSegmentLoader_.mediaSecondsLoaded+this.mainSegmentLoader_.mediaSecondsLoaded)},i.load=function(){this.mainSegmentLoader_.load(),this.mediaTypes_.AUDIO.activePlaylistLoader&&this.audioSegmentLoader_.load(),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&this.subtitleSegmentLoader_.load()},i.smoothQualityChange_=function(r){r===void 0&&(r=this.selectPlaylist()),this.fastQualityChange_(r)},i.fastQualityChange_=function(r){var o=this;if(r===void 0&&(r=this.selectPlaylist()),r===this.masterPlaylistLoader_.media()){this.logger_("skipping fastQualityChange because new media is same as old");return}this.switchMedia_(r,"fast-quality"),this.mainSegmentLoader_.resetEverything(function(){Vt.browser.IE_VERSION||Vt.browser.IS_EDGE?o.tech_.setCurrentTime(o.tech_.currentTime()+.04):o.tech_.setCurrentTime(o.tech_.currentTime())})},i.play=function(){if(!this.setupFirstPlay()){this.tech_.ended()&&this.tech_.setCurrentTime(0),this.hasPlayed_&&this.load();var r=this.tech_.seekable();if(this.tech_.duration()===1/0&&this.tech_.currentTime()<r.start(0))return this.tech_.setCurrentTime(r.end(r.length-1))}},i.setupFirstPlay=function(){var r=this,o=this.masterPlaylistLoader_.media();if(!o||this.tech_.paused()||this.hasPlayed_)return!1;if(!o.endList){var a=this.seekable();if(!a.length)return!1;if(Vt.browser.IE_VERSION&&this.tech_.readyState()===0)return this.tech_.one("loadedmetadata",function(){r.trigger("firstplay"),r.tech_.setCurrentTime(a.end(0)),r.hasPlayed_=!0}),!1;this.trigger("firstplay"),this.tech_.setCurrentTime(a.end(0))}return this.hasPlayed_=!0,this.load(),!0},i.handleSourceOpen_=function(){if(this.tryToCreateSourceBuffers_(),this.tech_.autoplay()){var r=this.tech_.play();typeof r<"u"&&typeof r.then=="function"&&r.then(null,function(o){})}this.trigger("sourceopen")},i.handleSourceEnded_=function(){if(this.inbandTextTracks_.metadataTrack_){var r=this.inbandTextTracks_.metadataTrack_.cues;if(!(!r||!r.length)){var o=this.duration();r[r.length-1].endTime=isNaN(o)||Math.abs(o)===1/0?Number.MAX_VALUE:o}}},i.handleDurationChange_=function(){this.tech_.trigger("durationchange")},i.onEndOfStream=function(){var r=this.mainSegmentLoader_.ended_;if(this.mediaTypes_.AUDIO.activePlaylistLoader){var o=this.mainSegmentLoader_.getCurrentMediaInfo_();!o||o.hasVideo?r=r&&this.audioSegmentLoader_.ended_:r=this.audioSegmentLoader_.ended_}r&&(this.stopABRTimer_(),this.sourceUpdater_.endOfStream())},i.stuckAtPlaylistEnd_=function(r){var o=this.seekable();if(!o.length)return!1;var a=this.syncController_.getExpiredTime(r,this.duration());if(a===null)return!1;var s=M0.Playlist.playlistEnd(r,a),l=this.tech_.currentTime(),u=this.tech_.buffered();if(!u.length)return s-l<=em;var c=u.end(u.length-1);return c-l<=em&&s-c<=em},i.blacklistCurrentPlaylist=function(r,o){r===void 0&&(r={});var a=r.playlist||this.masterPlaylistLoader_.media();if(o=o||r.blacklistDuration||this.blacklistDuration,!a){this.error=r,this.mediaSource.readyState!=="open"?this.trigger("error"):this.sourceUpdater_.endOfStream("network");return}a.playlistErrors_++;var s=this.masterPlaylistLoader_.master.playlists,l=s.filter(rW),u=l.length===1&&l[0]===a;if(s.length===1&&o!==1/0)return Vt.log.warn("Problem encountered with playlist "+a.id+". Trying again since it is the only playlist."),this.tech_.trigger("retryplaylist"),this.masterPlaylistLoader_.load(u);if(u){var c=!1;s.forEach(function(y){if(y!==a){var m=y.excludeUntil;typeof m<"u"&&m!==1/0&&(c=!0,delete y.excludeUntil)}}),c&&(Vt.log.warn("Removing other playlists from the exclusion list because the last rendition is about to be excluded."),this.tech_.trigger("retryplaylist"))}var d;a.playlistErrors_>this.maxPlaylistRetries?d=1/0:d=Date.now()+o*1e3,a.excludeUntil=d,r.reason&&(a.lastExcludeReason_=r.reason),this.tech_.trigger("blacklistplaylist"),this.tech_.trigger({type:"usage",name:"vhs-rendition-blacklisted"}),this.tech_.trigger({type:"usage",name:"hls-rendition-blacklisted"});var f=this.selectPlaylist();if(!f){this.error="Playback cannot continue. No available working or supported playlists.",this.trigger("error");return}var h=r.internal?this.logger_:Vt.log.warn,p=r.message?" "+r.message:"";h((r.internal?"Internal problem":"Problem")+" encountered with playlist "+a.id+"."+(p+" Switching to playlist "+f.id+".")),f.attributes.AUDIO!==a.attributes.AUDIO&&this.delegateLoaders_("audio",["abort","pause"]),f.attributes.SUBTITLES!==a.attributes.SUBTITLES&&this.delegateLoaders_("subtitle",["abort","pause"]),this.delegateLoaders_("main",["abort","pause"]);var g=f.targetDuration/2*1e3||5*1e3,v=typeof f.lastRequest=="number"&&Date.now()-f.lastRequest<=g;return this.switchMedia_(f,"exclude",u||v)},i.pauseLoading=function(){this.delegateLoaders_("all",["abort","pause"]),this.stopABRTimer_()},i.delegateLoaders_=function(r,o){var a=this,s=[],l=r==="all";(l||r==="main")&&s.push(this.masterPlaylistLoader_);var u=[];(l||r==="audio")&&u.push("AUDIO"),(l||r==="subtitle")&&(u.push("CLOSED-CAPTIONS"),u.push("SUBTITLES")),u.forEach(function(c){var d=a.mediaTypes_[c]&&a.mediaTypes_[c].activePlaylistLoader;d&&s.push(d)}),["main","audio","subtitle"].forEach(function(c){var d=a[c+"SegmentLoader_"];d&&(r===c||r==="all")&&s.push(d)}),s.forEach(function(c){return o.forEach(function(d){typeof c[d]=="function"&&c[d]()})})},i.setCurrentTime=function(r){var o=OL(this.tech_.buffered(),r);if(!(this.masterPlaylistLoader_&&this.masterPlaylistLoader_.media())||!this.masterPlaylistLoader_.media().segments)return 0;if(o&&o.length)return r;this.mainSegmentLoader_.resetEverything(),this.mainSegmentLoader_.abort(),this.mediaTypes_.AUDIO.activePlaylistLoader&&(this.audioSegmentLoader_.resetEverything(),this.audioSegmentLoader_.abort()),this.mediaTypes_.SUBTITLES.activePlaylistLoader&&(this.subtitleSegmentLoader_.resetEverything(),this.subtitleSegmentLoader_.abort()),this.load()},i.duration=function(){if(!this.masterPlaylistLoader_)return 0;var r=this.masterPlaylistLoader_.media();return r?r.endList?this.mediaSource?this.mediaSource.duration:M0.Playlist.duration(r):1/0:0},i.seekable=function(){return this.seekable_},i.onSyncInfoUpdate_=function(){var r;if(this.masterPlaylistLoader_){var o=this.masterPlaylistLoader_.media();if(o){var a=this.syncController_.getExpiredTime(o,this.duration());if(a!==null){var s=this.masterPlaylistLoader_.master,l=M0.Playlist.seekable(o,a,M0.Playlist.liveEdgeDelay(s,o));if(l.length!==0&&!(this.mediaTypes_.AUDIO.activePlaylistLoader&&(o=this.mediaTypes_.AUDIO.activePlaylistLoader.media(),a=this.syncController_.getExpiredTime(o,this.duration()),a===null||(r=M0.Playlist.seekable(o,a,M0.Playlist.liveEdgeDelay(s,o)),r.length===0)))){var u,c;this.seekable_&&this.seekable_.length&&(u=this.seekable_.end(0),c=this.seekable_.start(0)),r?r.start(0)>l.end(0)||l.start(0)>r.end(0)?this.seekable_=l:this.seekable_=Vt.createTimeRanges([[r.start(0)>l.start(0)?r.start(0):l.start(0),r.end(0)<l.end(0)?r.end(0):l.end(0)]]):this.seekable_=l,!(this.seekable_&&this.seekable_.length&&this.seekable_.end(0)===u&&this.seekable_.start(0)===c)&&(this.logger_("seekable updated ["+D2e(this.seekable_)+"]"),this.tech_.trigger("seekablechanged"))}}}}},i.updateDuration=function(r){if(this.updateDuration_&&(this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.updateDuration_=null),this.mediaSource.readyState!=="open"){this.updateDuration_=this.updateDuration.bind(this,r),this.mediaSource.addEventListener("sourceopen",this.updateDuration_);return}if(r){var o=this.seekable();if(!o.length)return;(isNaN(this.mediaSource.duration)||this.mediaSource.duration<o.end(o.length-1))&&this.sourceUpdater_.setDuration(o.end(o.length-1));return}var a=this.tech_.buffered(),s=M0.Playlist.duration(this.masterPlaylistLoader_.media());a.length>0&&(s=Math.max(s,a.end(a.length-1))),this.mediaSource.duration!==s&&this.sourceUpdater_.setDuration(s)},i.dispose=function(){var r=this;this.trigger("dispose"),this.decrypter_.terminate(),this.masterPlaylistLoader_.dispose(),this.mainSegmentLoader_.dispose(),this.loadOnPlay_&&this.tech_.off("play",this.loadOnPlay_),["AUDIO","SUBTITLES"].forEach(function(o){var a=r.mediaTypes_[o].groups;for(var s in a)a[s].forEach(function(l){l.playlistLoader&&l.playlistLoader.dispose()})}),this.audioSegmentLoader_.dispose(),this.subtitleSegmentLoader_.dispose(),this.sourceUpdater_.dispose(),this.timelineChangeController_.dispose(),this.stopABRTimer_(),this.updateDuration_&&this.mediaSource.removeEventListener("sourceopen",this.updateDuration_),this.mediaSource.removeEventListener("durationchange",this.handleDurationChange_),this.mediaSource.removeEventListener("sourceopen",this.handleSourceOpen_),this.mediaSource.removeEventListener("sourceended",this.handleSourceEnded_),this.off()},i.master=function(){return this.masterPlaylistLoader_.master},i.media=function(){return this.masterPlaylistLoader_.media()||this.initialMedia_},i.areMediaTypesKnown_=function(){var r=!!this.mediaTypes_.AUDIO.activePlaylistLoader,o=!!this.mainSegmentLoader_.getCurrentMediaInfo_(),a=r?!!this.audioSegmentLoader_.getCurrentMediaInfo_():!0;return!(!o||!a)},i.getCodecsOrExclude_=function(){var r=this,o={main:this.mainSegmentLoader_.getCurrentMediaInfo_()||{},audio:this.audioSegmentLoader_.getCurrentMediaInfo_()||{}},a=this.mainSegmentLoader_.getPendingSegmentPlaylist()||this.media();o.video=o.main;var s=Rj(this.master(),a),l={},u=!!this.mediaTypes_.AUDIO.activePlaylistLoader;if(o.main.hasVideo&&(l.video=s.video||o.main.videoCodec||Qbt),o.main.isMuxed&&(l.video+=","+(s.audio||o.main.audioCodec||Rce)),(o.main.hasAudio&&!o.main.isMuxed||o.audio.hasAudio||u)&&(l.audio=s.audio||o.main.audioCodec||o.audio.audioCodec||Rce,o.audio.isFmp4=o.main.hasAudio&&!o.main.isMuxed?o.main.isFmp4:o.audio.isFmp4),!l.audio&&!l.video){this.blacklistCurrentPlaylist({playlist:a,message:"Could not determine codecs for playlist.",blacklistDuration:1/0});return}var c=function(y,m){return y?XU(m):UY(m)},d={},f;if(["video","audio"].forEach(function(v){if(l.hasOwnProperty(v)&&!c(o[v].isFmp4,l[v])){var y=o[v].isFmp4?"browser":"muxer";d[y]=d[y]||[],d[y].push(l[v]),v==="audio"&&(f=y)}}),u&&f&&a.attributes.AUDIO){var h=a.attributes.AUDIO;this.master().playlists.forEach(function(v){var y=v.attributes&&v.attributes.AUDIO;y===h&&v!==a&&(v.excludeUntil=1/0)}),this.logger_("excluding audio group "+h+" as "+f+' does not support codec(s): "'+l.audio+'"')}if(Object.keys(d).length){var p=Object.keys(d).reduce(function(v,y){return v&&(v+=", "),v+=y+' does not support codec(s): "'+d[y].join(",")+'"',v},"")+".";this.blacklistCurrentPlaylist({playlist:a,internal:!0,message:p,blacklistDuration:1/0});return}if(this.sourceUpdater_.hasCreatedSourceBuffers()&&!this.sourceUpdater_.canChangeType()){var g=[];if(["video","audio"].forEach(function(v){var y=(Ly(r.sourceUpdater_.codecs[v]||"")[0]||{}).type,m=(Ly(l[v]||"")[0]||{}).type;y&&m&&y.toLowerCase()!==m.toLowerCase()&&g.push('"'+r.sourceUpdater_.codecs[v]+'" -> "'+l[v]+'"')}),g.length){this.blacklistCurrentPlaylist({playlist:a,message:"Codec switching not supported: "+g.join(", ")+".",blacklistDuration:1/0,internal:!0});return}}return l},i.tryToCreateSourceBuffers_=function(){if(!(this.mediaSource.readyState!=="open"||this.sourceUpdater_.hasCreatedSourceBuffers())&&this.areMediaTypesKnown_()){var r=this.getCodecsOrExclude_();if(r){this.sourceUpdater_.createSourceBuffers(r);var o=[r.video,r.audio].filter(Boolean).join(",");this.excludeIncompatibleVariants_(o)}}},i.excludeUnsupportedVariants_=function(){var r=this,o=this.master().playlists,a=[];Object.keys(o).forEach(function(s){var l=o[s];if(a.indexOf(l.id)===-1){a.push(l.id);var u=Rj(r.master,l),c=[];u.audio&&!UY(u.audio)&&!XU(u.audio)&&c.push("audio codec "+u.audio),u.video&&!UY(u.video)&&!XU(u.video)&&c.push("video codec "+u.video),u.text&&u.text==="stpp.ttml.im1t"&&c.push("text codec "+u.text),c.length&&(l.excludeUntil=1/0,r.logger_("excluding "+l.id+" for unsupported: "+c.join(", ")))}})},i.excludeIncompatibleVariants_=function(r){var o=this,a=[],s=this.master().playlists,l=Iz(Ly(r)),u=Rde(l),c=l.video&&Ly(l.video)[0]||null,d=l.audio&&Ly(l.audio)[0]||null;Object.keys(s).forEach(function(f){var h=s[f];if(!(a.indexOf(h.id)!==-1||h.excludeUntil===1/0)){a.push(h.id);var p=[],g=Rj(o.masterPlaylistLoader_.master,h),v=Rde(g);if(!(!g.audio&&!g.video)){if(v!==u&&p.push('codec count "'+v+'" !== "'+u+'"'),!o.sourceUpdater_.canChangeType()){var y=g.video&&Ly(g.video)[0]||null,m=g.audio&&Ly(g.audio)[0]||null;y&&c&&y.type.toLowerCase()!==c.type.toLowerCase()&&p.push('video codec "'+y.type+'" !== "'+c.type+'"'),m&&d&&m.type.toLowerCase()!==d.type.toLowerCase()&&p.push('audio codec "'+m.type+'" !== "'+d.type+'"')}p.length&&(h.excludeUntil=1/0,o.logger_("blacklisting "+h.id+": "+p.join(" && ")))}}})},i.updateAdCues_=function(r){var o=0,a=this.seekable();a.length&&(o=a.start(0)),HTt(r,this.cueTagsTrack_,o)},i.goalBufferLength=function(){var r=this.tech_.currentTime(),o=Pc.GOAL_BUFFER_LENGTH,a=Pc.GOAL_BUFFER_LENGTH_RATE,s=Math.max(o,Pc.MAX_GOAL_BUFFER_LENGTH);return Math.min(o+r*a,s)},i.bufferLowWaterLine=function(){var r=this.tech_.currentTime(),o=Pc.BUFFER_LOW_WATER_LINE,a=Pc.BUFFER_LOW_WATER_LINE_RATE,s=Math.max(o,Pc.MAX_BUFFER_LOW_WATER_LINE),l=Math.max(o,Pc.EXPERIMENTAL_MAX_BUFFER_LOW_WATER_LINE);return Math.min(o+r*a,this.experimentalBufferBasedABR?l:s)},i.bufferHighWaterLine=function(){return Pc.BUFFER_HIGH_WATER_LINE},e})(Vt.EventTarget),u1t=function(e,i,n){return function(r){var o=e.master.playlists[i],a=Qte(o),s=rW(o);return typeof r>"u"?s:(r?delete o.disabled:o.disabled=!0,r!==s&&!a&&(n(),r?e.trigger("renditionenabled"):e.trigger("renditiondisabled")),r)}},c1t=function(e,i,n){var r=e.masterPlaylistController_,o=e.options_.smoothQualityChange,a=o?"smooth":"fast",s=r[a+"QualityChange_"].bind(r);if(i.attributes){var l=i.attributes.RESOLUTION;this.width=l&&l.width,this.height=l&&l.height,this.bandwidth=i.attributes.BANDWIDTH,this.frameRate=i.attributes["FRAME-RATE"]}this.codecs=Rj(r.master(),i),this.playlist=i,this.id=n,this.enabled=u1t(e.playlists,i.id,s)},d1t=function(e){e.representations=function(){var i=e.masterPlaylistController_.master(),n=zV(i)?e.masterPlaylistController_.getAudioTrackPlaylists_():i.playlists;return n?n.filter(function(r){return!Qte(r)}).map(function(r,o){return new c1t(e,r,r.id)}):[]}},zde=["seeking","seeked","pause","playing","error"],f1t=(function(){function t(i){var n=this;this.masterPlaylistController_=i.masterPlaylistController,this.tech_=i.tech,this.seekable=i.seekable,this.allowSeeksWithinUnsafeLiveWindow=i.allowSeeksWithinUnsafeLiveWindow,this.liveRangeSafeTimeDelta=i.liveRangeSafeTimeDelta,this.media=i.media,this.consecutiveUpdates=0,this.lastRecordedTime=null,this.timer_=null,this.checkCurrentTimeTimeout_=null,this.logger_=zv("PlaybackWatcher"),this.logger_("initialize");var r=function(){return n.monitorCurrentTime_()},o=function(){return n.monitorCurrentTime_()},a=function(){return n.techWaiting_()},s=function(){return n.cancelTimer_()},l=this.masterPlaylistController_,u=["main","subtitle","audio"],c={};u.forEach(function(f){c[f]={reset:function(){return n.resetSegmentDownloads_(f)},updateend:function(){return n.checkSegmentDownloads_(f)}},l[f+"SegmentLoader_"].on("appendsdone",c[f].updateend),l[f+"SegmentLoader_"].on("playlistupdate",c[f].reset),n.tech_.on(["seeked","seeking"],c[f].reset)});var d=function(h){["main","audio"].forEach(function(p){l[p+"SegmentLoader_"][h]("appended",n.seekingAppendCheck_)})};this.seekingAppendCheck_=function(){n.fixesBadSeeks_()&&(n.consecutiveUpdates=0,n.lastRecordedTime=n.tech_.currentTime(),d("off"))},this.clearSeekingAppendCheck_=function(){return d("off")},this.watchForBadSeeking_=function(){n.clearSeekingAppendCheck_(),d("on")},this.tech_.on("seeked",this.clearSeekingAppendCheck_),this.tech_.on("seeking",this.watchForBadSeeking_),this.tech_.on("waiting",a),this.tech_.on(zde,s),this.tech_.on("canplay",o),this.tech_.one("play",r),this.dispose=function(){n.clearSeekingAppendCheck_(),n.logger_("dispose"),n.tech_.off("waiting",a),n.tech_.off(zde,s),n.tech_.off("canplay",o),n.tech_.off("play",r),n.tech_.off("seeking",n.watchForBadSeeking_),n.tech_.off("seeked",n.clearSeekingAppendCheck_),u.forEach(function(f){l[f+"SegmentLoader_"].off("appendsdone",c[f].updateend),l[f+"SegmentLoader_"].off("playlistupdate",c[f].reset),n.tech_.off(["seeked","seeking"],c[f].reset)}),n.checkCurrentTimeTimeout_&&Ct.clearTimeout(n.checkCurrentTimeTimeout_),n.cancelTimer_()}}var e=t.prototype;return e.monitorCurrentTime_=function(){this.checkCurrentTime_(),this.checkCurrentTimeTimeout_&&Ct.clearTimeout(this.checkCurrentTimeTimeout_),this.checkCurrentTimeTimeout_=Ct.setTimeout(this.monitorCurrentTime_.bind(this),250)},e.resetSegmentDownloads_=function(n){var r=this.masterPlaylistController_[n+"SegmentLoader_"];this[n+"StalledDownloads_"]>0&&this.logger_("resetting possible stalled download count for "+n+" loader"),this[n+"StalledDownloads_"]=0,this[n+"Buffered_"]=r.buffered_()},e.checkSegmentDownloads_=function(n){var r=this.masterPlaylistController_,o=r[n+"SegmentLoader_"],a=o.buffered_(),s=iCt(this[n+"Buffered_"],a);if(this[n+"Buffered_"]=a,s){this.resetSegmentDownloads_(n);return}this[n+"StalledDownloads_"]++,this.logger_("found #"+this[n+"StalledDownloads_"]+" "+n+" appends that did not increase buffer (possible stalled download)",{playlistId:o.playlist_&&o.playlist_.id,buffered:WO(a)}),!(this[n+"StalledDownloads_"]<10)&&(this.logger_(n+" loader stalled download exclusion"),this.resetSegmentDownloads_(n),this.tech_.trigger({type:"usage",name:"vhs-"+n+"-download-exclusion"}),n!=="subtitle"&&r.blacklistCurrentPlaylist({message:"Excessive "+n+" segment downloading detected."},1/0))},e.checkCurrentTime_=function(){if(!(this.tech_.paused()||this.tech_.seeking())){var n=this.tech_.currentTime(),r=this.tech_.buffered();if(this.lastRecordedTime===n&&(!r.length||n+em>=r.end(r.length-1)))return this.techWaiting_();this.consecutiveUpdates>=5&&n===this.lastRecordedTime?(this.consecutiveUpdates++,this.waiting_()):n===this.lastRecordedTime?this.consecutiveUpdates++:(this.consecutiveUpdates=0,this.lastRecordedTime=n)}},e.cancelTimer_=function(){this.consecutiveUpdates=0,this.timer_&&(this.logger_("cancelTimer_"),clearTimeout(this.timer_)),this.timer_=null},e.fixesBadSeeks_=function(){var n=this.tech_.seeking();if(!n)return!1;var r=this.seekable(),o=this.tech_.currentTime(),a=this.afterSeekableWindow_(r,o,this.media(),this.allowSeeksWithinUnsafeLiveWindow),s;if(a){var l=r.end(r.length-1);s=l}if(this.beforeSeekableWindow_(r,o)){var u=r.start(0);s=u+(u===r.end(0)?0:em)}if(typeof s<"u")return this.logger_("Trying to seek outside of seekable at time "+o+" with "+("seekable range "+D2e(r)+". Seeking to ")+(s+".")),this.tech_.setCurrentTime(s),!0;for(var c=this.masterPlaylistController_.sourceUpdater_,d=this.tech_.buffered(),f=c.audioBuffer?c.audioBuffered():null,h=c.videoBuffer?c.videoBuffered():null,p=this.media(),g=p.partTargetDuration?p.partTargetDuration:(p.targetDuration-OP)*2,v=[f,h],y=0;y<v.length;y++)if(v[y]){var m=Zte(v[y],o);if(m<g)return!1}var b=C4(d,o);return b.length===0?!1:(s=b.start(0)+em,this.logger_("Buffered region starts ("+b.start(0)+") "+(" just beyond seek point ("+o+"). Seeking to "+s+".")),this.tech_.setCurrentTime(s),!0)},e.waiting_=function(){if(!this.techWaiting_()){var n=this.tech_.currentTime(),r=this.tech_.buffered(),o=OL(r,n);if(o.length&&n+3<=o.end(0)){this.cancelTimer_(),this.tech_.setCurrentTime(n),this.logger_("Stopped at "+n+" while inside a buffered region "+("["+o.start(0)+" -> "+o.end(0)+"]. Attempting to resume ")+"playback by seeking to the current time."),this.tech_.trigger({type:"usage",name:"vhs-unknown-waiting"}),this.tech_.trigger({type:"usage",name:"hls-unknown-waiting"});return}}},e.techWaiting_=function(){var n=this.seekable(),r=this.tech_.currentTime();if(this.tech_.seeking()||this.timer_!==null)return!0;if(this.beforeSeekableWindow_(n,r)){var o=n.end(n.length-1);return this.logger_("Fell out of live window at time "+r+". Seeking to "+("live point (seekable end) "+o)),this.cancelTimer_(),this.tech_.setCurrentTime(o),this.tech_.trigger({type:"usage",name:"vhs-live-resync"}),this.tech_.trigger({type:"usage",name:"hls-live-resync"}),!0}var a=this.tech_.vhs.masterPlaylistController_.sourceUpdater_,s=this.tech_.buffered(),l=this.videoUnderflow_({audioBuffered:a.audioBuffered(),videoBuffered:a.videoBuffered(),currentTime:r});if(l)return this.cancelTimer_(),this.tech_.setCurrentTime(r),this.tech_.trigger({type:"usage",name:"vhs-video-underflow"}),this.tech_.trigger({type:"usage",name:"hls-video-underflow"}),!0;var u=C4(s,r);if(u.length>0){var c=u.start(0)-r;return this.logger_("Stopped at "+r+", setting timer for "+c+", seeking "+("to "+u.start(0))),this.cancelTimer_(),this.timer_=setTimeout(this.skipTheGap_.bind(this),c*1e3,r),!0}return!1},e.afterSeekableWindow_=function(n,r,o,a){if(a===void 0&&(a=!1),!n.length)return!1;var s=n.end(n.length-1)+em,l=!o.endList;return l&&a&&(s=n.end(n.length-1)+o.targetDuration*3),r>s},e.beforeSeekableWindow_=function(n,r){return!!(n.length&&n.start(0)>0&&r<n.start(0)-this.liveRangeSafeTimeDelta)},e.videoUnderflow_=function(n){var r=n.videoBuffered,o=n.audioBuffered,a=n.currentTime;if(r){var s;if(r.length&&o.length){var l=OL(r,a-3),u=OL(r,a),c=OL(o,a);c.length&&!u.length&&l.length&&(s={start:l.end(0),end:c.end(0)})}else{var d=C4(r,a);d.length||(s=this.gapFromVideoUnderflow_(r,a))}return s?(this.logger_("Encountered a gap in video from "+s.start+" to "+s.end+". "+("Seeking to current time "+a)),!0):!1}},e.skipTheGap_=function(n){var r=this.tech_.buffered(),o=this.tech_.currentTime(),a=C4(r,o);this.cancelTimer_(),!(a.length===0||o!==n)&&(this.logger_("skipTheGap_:","currentTime:",o,"scheduled currentTime:",n,"nextRange start:",a.start(0)),this.tech_.setCurrentTime(a.start(0)+OP),this.tech_.trigger({type:"usage",name:"vhs-gap-skip"}),this.tech_.trigger({type:"usage",name:"hls-gap-skip"}))},e.gapFromVideoUnderflow_=function(n,r){for(var o=eCt(n),a=0;a<o.length;a++){var s=o.start(a),l=o.end(a);if(r-s<4&&r-s>2)return{start:s,end:l}}return null},t})(),h1t={errorInterval:30,getSource:function(e){var i=this.tech({IWillNotUseThisInPlugins:!0}),n=i.currentSource_||this.currentSource();return e(n)}},p1t=function t(e,i){var n=0,r=0,o=Vt.mergeOptions(h1t,i);e.ready(function(){e.trigger({type:"usage",name:"vhs-error-reload-initialized"}),e.trigger({type:"usage",name:"hls-error-reload-initialized"})});var a=function(){r&&e.currentTime(r)},s=function(f){f!=null&&(r=e.duration()!==1/0&&e.currentTime()||0,e.one("loadedmetadata",a),e.src(f),e.trigger({type:"usage",name:"vhs-error-reload"}),e.trigger({type:"usage",name:"hls-error-reload"}),e.play())},l=function(){if(Date.now()-n<o.errorInterval*1e3){e.trigger({type:"usage",name:"vhs-error-reload-canceled"}),e.trigger({type:"usage",name:"hls-error-reload-canceled"});return}if(!o.getSource||typeof o.getSource!="function"){Vt.log.error("ERROR: reloadSourceOnError - The option getSource must be a function!");return}return n=Date.now(),o.getSource.call(e,s)},u=function d(){e.off("loadedmetadata",a),e.off("error",l),e.off("dispose",d)},c=function(f){u(),t(e,f)};e.on("error",l),e.on("dispose",u),e.reloadSourceOnError=c},g1t=function(e){p1t(this,e)},pNe="2.16.3",v1t="6.0.1",y1t="0.22.1",m1t="4.8.0",b1t="3.1.3",nd={PlaylistLoader:DL,Playlist:wh,utils:ACt,STANDARD_PLAYLIST_SELECTOR:Lde,INITIAL_PLAYLIST_SELECTOR:yTt,lastBandwidthSelector:Lde,movingAverageBandwidthSelector:gTt,comparePlaylistBandwidth:ire,comparePlaylistResolution:pTt,xhr:W2e()};Object.keys(Pc).forEach(function(t){Object.defineProperty(nd,t,{get:function(){return Vt.log.warn("using Vhs."+t+" is UNSAFE be sure you know what you are doing"),Pc[t]},set:function(i){if(Vt.log.warn("using Vhs."+t+" is UNSAFE be sure you know what you are doing"),typeof i!="number"||i<0){Vt.log.warn("value of Vhs."+t+" must be greater than or equal to 0");return}Pc[t]=i}})});var gNe="videojs-vhs",vNe=function(e,i){for(var n=i.media(),r=-1,o=0;o<e.length;o++)if(e[o].id===n.id){r=o;break}e.selectedIndex_=r,e.trigger({selectedIndex:r,type:"change"})},S1t=function(e,i){i.representations().forEach(function(n){e.addQualityLevel(n)}),vNe(e,i.playlists)};nd.canPlaySource=function(){return Vt.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var _1t=function(e,i,n){if(!e)return e;var r={};i&&i.attributes&&i.attributes.CODECS&&(r=Iz(Ly(i.attributes.CODECS))),n&&n.attributes&&n.attributes.CODECS&&(r.audio=n.attributes.CODECS);var o=R3(r.video),a=R3(r.audio),s={};for(var l in e)s[l]={},a&&(s[l].audioContentType=a),o&&(s[l].videoContentType=o),i.contentProtection&&i.contentProtection[l]&&i.contentProtection[l].pssh&&(s[l].pssh=i.contentProtection[l].pssh),typeof e[l]=="string"&&(s[l].url=e[l]);return Vt.mergeOptions(e,s)},P1t=function(e,i){return e.reduce(function(n,r){if(!r.contentProtection)return n;var o=i.reduce(function(a,s){var l=r.contentProtection[s];return l&&l.pssh&&(a[s]={pssh:l.pssh}),a},{});return Object.keys(o).length&&n.push(o),n},[])},C1t=function(e){var i=e.player,n=e.sourceKeySystems,r=e.audioMedia,o=e.mainPlaylists;if(!i.eme.initializeMediaKeys)return Promise.resolve();var a=r?o.concat([r]):o,s=P1t(a,Object.keys(n)),l=[],u=[];return s.forEach(function(c){u.push(new Promise(function(d,f){i.tech_.one("keysessioncreated",d)})),l.push(new Promise(function(d,f){i.eme.initializeMediaKeys({keySystems:c},function(h){if(h){f(h);return}d()})}))}),Promise.race([Promise.all(l),Promise.race(u)])},T1t=function(e){var i=e.player,n=e.sourceKeySystems,r=e.media,o=e.audioMedia,a=_1t(n,r,o);return a?(i.currentSource().keySystems=a,a&&!i.eme?(Vt.log.warn("DRM encrypted source cannot be decrypted without a DRM plugin"),!1):!0):!1},yNe=function(){if(!Ct.localStorage)return null;var e=Ct.localStorage.getItem(gNe);if(!e)return null;try{return JSON.parse(e)}catch{return null}},x1t=function(e){if(!Ct.localStorage)return!1;var i=yNe();i=i?Vt.mergeOptions(i,e):e;try{Ct.localStorage.setItem(gNe,JSON.stringify(i))}catch{return!1}return i},E1t=function(e){return e.toLowerCase().indexOf("data:application/vnd.videojs.vhs+json,")===0?JSON.parse(e.substring(e.indexOf(",")+1)):e};nd.supportsNativeHls=(function(){if(!$r||!$r.createElement)return!1;var t=$r.createElement("video");if(!Vt.getTech("Html5").isSupported())return!1;var e=["application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","application/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"];return e.some(function(i){return/maybe|probably/i.test(t.canPlayType(i))})})();nd.supportsNativeDash=(function(){return!$r||!$r.createElement||!Vt.getTech("Html5").isSupported()?!1:/maybe|probably/i.test($r.createElement("video").canPlayType("application/dash+xml"))})();nd.supportsTypeNatively=function(t){return t==="hls"?nd.supportsNativeHls:t==="dash"?nd.supportsNativeDash:!1};nd.isSupported=function(){return Vt.log.warn("HLS is no longer a tech. Please remove it from your player's techOrder.")};var w1t=Vt.getComponent("Component"),ore=(function(t){qr(e,t);function e(n,r,o){var a;if(a=t.call(this,r,Vt.mergeOptions(o.hls,o.vhs))||this,o.hls&&Object.keys(o.hls).length&&Vt.log.warn("Using hls options is deprecated. Please rename `hls` to `vhs` in your options object."),typeof o.initialBandwidth=="number"&&(a.options_.bandwidth=o.initialBandwidth),a.logger_=zv("VhsHandler"),r.options_&&r.options_.playerId){var s=Vt(r.options_.playerId);s.hasOwnProperty("hls")||Object.defineProperty(s,"hls",{get:function(){return Vt.log.warn("player.hls is deprecated. Use player.tech().vhs instead."),r.trigger({type:"usage",name:"hls-player-access"}),bn(a)},configurable:!0}),s.hasOwnProperty("vhs")||Object.defineProperty(s,"vhs",{get:function(){return Vt.log.warn("player.vhs is deprecated. Use player.tech().vhs instead."),r.trigger({type:"usage",name:"vhs-player-access"}),bn(a)},configurable:!0}),s.hasOwnProperty("dash")||Object.defineProperty(s,"dash",{get:function(){return Vt.log.warn("player.dash is deprecated. Use player.tech().vhs instead."),bn(a)},configurable:!0}),a.player_=s}if(a.tech_=r,a.source_=n,a.stats={},a.ignoreNextSeekingEvent_=!1,a.setOptions_(),a.options_.overrideNative&&r.overrideNativeAudioTracks&&r.overrideNativeVideoTracks)r.overrideNativeAudioTracks(!0),r.overrideNativeVideoTracks(!0);else if(a.options_.overrideNative&&(r.featuresNativeVideoTracks||r.featuresNativeAudioTracks))throw new Error("Overriding native HLS requires emulated tracks. See https://git.io/vMpjB");return a.on($r,["fullscreenchange","webkitfullscreenchange","mozfullscreenchange","MSFullscreenChange"],function(l){var u=$r.fullscreenElement||$r.webkitFullscreenElement||$r.mozFullScreenElement||$r.msFullscreenElement;u&&u.contains(a.tech_.el())?a.masterPlaylistController_.fastQualityChange_():a.masterPlaylistController_.checkABR_()}),a.on(a.tech_,"seeking",function(){if(this.ignoreNextSeekingEvent_){this.ignoreNextSeekingEvent_=!1;return}this.setCurrentTime(this.tech_.currentTime())}),a.on(a.tech_,"error",function(){this.tech_.error()&&this.masterPlaylistController_&&this.masterPlaylistController_.pauseLoading()}),a.on(a.tech_,"play",a.play),a}var i=e.prototype;return i.setOptions_=function(){var r=this;if(this.options_.withCredentials=this.options_.withCredentials||!1,this.options_.handleManifestRedirects=this.options_.handleManifestRedirects!==!1,this.options_.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions!==!1,this.options_.useDevicePixelRatio=this.options_.useDevicePixelRatio||!1,this.options_.smoothQualityChange=this.options_.smoothQualityChange||!1,this.options_.useBandwidthFromLocalStorage=typeof this.source_.useBandwidthFromLocalStorage<"u"?this.source_.useBandwidthFromLocalStorage:this.options_.useBandwidthFromLocalStorage||!1,this.options_.useNetworkInformationApi=this.options_.useNetworkInformationApi||!1,this.options_.useDtsForTimestampOffset=this.options_.useDtsForTimestampOffset||!1,this.options_.customTagParsers=this.options_.customTagParsers||[],this.options_.customTagMappers=this.options_.customTagMappers||[],this.options_.cacheEncryptionKeys=this.options_.cacheEncryptionKeys||!1,typeof this.options_.blacklistDuration!="number"&&(this.options_.blacklistDuration=300),typeof this.options_.bandwidth!="number"&&this.options_.useBandwidthFromLocalStorage){var o=yNe();o&&o.bandwidth&&(this.options_.bandwidth=o.bandwidth,this.tech_.trigger({type:"usage",name:"vhs-bandwidth-from-local-storage"}),this.tech_.trigger({type:"usage",name:"hls-bandwidth-from-local-storage"})),o&&o.throughput&&(this.options_.throughput=o.throughput,this.tech_.trigger({type:"usage",name:"vhs-throughput-from-local-storage"}),this.tech_.trigger({type:"usage",name:"hls-throughput-from-local-storage"}))}typeof this.options_.bandwidth!="number"&&(this.options_.bandwidth=Pc.INITIAL_BANDWIDTH),this.options_.enableLowInitialPlaylist=this.options_.enableLowInitialPlaylist&&this.options_.bandwidth===Pc.INITIAL_BANDWIDTH,["withCredentials","useDevicePixelRatio","limitRenditionByPlayerDimensions","bandwidth","smoothQualityChange","customTagParsers","customTagMappers","handleManifestRedirects","cacheEncryptionKeys","playlistSelector","initialPlaylistSelector","experimentalBufferBasedABR","liveRangeSafeTimeDelta","experimentalLLHLS","useNetworkInformationApi","useDtsForTimestampOffset","experimentalExactManifestTimings","experimentalLeastPixelDiffSelector"].forEach(function(a){typeof r.source_[a]<"u"&&(r.options_[a]=r.source_[a])}),this.limitRenditionByPlayerDimensions=this.options_.limitRenditionByPlayerDimensions,this.useDevicePixelRatio=this.options_.useDevicePixelRatio},i.src=function(r,o){var a=this;if(r){this.setOptions_(),this.options_.src=E1t(this.source_.src),this.options_.tech=this.tech_,this.options_.externVhs=nd,this.options_.sourceType=lIe(o),this.options_.seekTo=function(u){a.tech_.setCurrentTime(u)},this.options_.smoothQualityChange&&Vt.log.warn("smoothQualityChange is deprecated and will be removed in the next major version"),this.masterPlaylistController_=new l1t(this.options_);var s=Vt.mergeOptions({liveRangeSafeTimeDelta:em},this.options_,{seekable:function(){return a.seekable()},media:function(){return a.masterPlaylistController_.media()},masterPlaylistController:this.masterPlaylistController_});this.playbackWatcher_=new f1t(s),this.masterPlaylistController_.on("error",function(){var u=Vt.players[a.tech_.options_.playerId],c=a.masterPlaylistController_.error;typeof c=="object"&&!c.code?c.code=3:typeof c=="string"&&(c={message:c,code:3}),u.error(c)});var l=this.options_.experimentalBufferBasedABR?nd.movingAverageBandwidthSelector(.55):nd.STANDARD_PLAYLIST_SELECTOR;this.masterPlaylistController_.selectPlaylist=this.selectPlaylist?this.selectPlaylist.bind(this):l.bind(this),this.masterPlaylistController_.selectInitialPlaylist=nd.INITIAL_PLAYLIST_SELECTOR.bind(this),this.playlists=this.masterPlaylistController_.masterPlaylistLoader_,this.mediaSource=this.masterPlaylistController_.mediaSource,Object.defineProperties(this,{selectPlaylist:{get:function(){return this.masterPlaylistController_.selectPlaylist},set:function(c){this.masterPlaylistController_.selectPlaylist=c.bind(this)}},throughput:{get:function(){return this.masterPlaylistController_.mainSegmentLoader_.throughput.rate},set:function(c){this.masterPlaylistController_.mainSegmentLoader_.throughput.rate=c,this.masterPlaylistController_.mainSegmentLoader_.throughput.count=1}},bandwidth:{get:function(){var c=this.masterPlaylistController_.mainSegmentLoader_.bandwidth,d=Ct.navigator.connection||Ct.navigator.mozConnection||Ct.navigator.webkitConnection,f=1e7;if(this.options_.useNetworkInformationApi&&d){var h=d.downlink*1e3*1e3;h>=f&&c>=f?c=Math.max(c,h):c=h}return c},set:function(c){this.masterPlaylistController_.mainSegmentLoader_.bandwidth=c,this.masterPlaylistController_.mainSegmentLoader_.throughput={rate:0,count:0}}},systemBandwidth:{get:function(){var c=1/(this.bandwidth||1),d;this.throughput>0?d=1/this.throughput:d=0;var f=Math.floor(1/(c+d));return f},set:function(){Vt.log.error('The "systemBandwidth" property is read-only')}}}),this.options_.bandwidth&&(this.bandwidth=this.options_.bandwidth),this.options_.throughput&&(this.throughput=this.options_.throughput),Object.defineProperties(this.stats,{bandwidth:{get:function(){return a.bandwidth||0},enumerable:!0},mediaRequests:{get:function(){return a.masterPlaylistController_.mediaRequests_()||0},enumerable:!0},mediaRequestsAborted:{get:function(){return a.masterPlaylistController_.mediaRequestsAborted_()||0},enumerable:!0},mediaRequestsTimedout:{get:function(){return a.masterPlaylistController_.mediaRequestsTimedout_()||0},enumerable:!0},mediaRequestsErrored:{get:function(){return a.masterPlaylistController_.mediaRequestsErrored_()||0},enumerable:!0},mediaTransferDuration:{get:function(){return a.masterPlaylistController_.mediaTransferDuration_()||0},enumerable:!0},mediaBytesTransferred:{get:function(){return a.masterPlaylistController_.mediaBytesTransferred_()||0},enumerable:!0},mediaSecondsLoaded:{get:function(){return a.masterPlaylistController_.mediaSecondsLoaded_()||0},enumerable:!0},mediaAppends:{get:function(){return a.masterPlaylistController_.mediaAppends_()||0},enumerable:!0},mainAppendsToLoadedData:{get:function(){return a.masterPlaylistController_.mainAppendsToLoadedData_()||0},enumerable:!0},audioAppendsToLoadedData:{get:function(){return a.masterPlaylistController_.audioAppendsToLoadedData_()||0},enumerable:!0},appendsToLoadedData:{get:function(){return a.masterPlaylistController_.appendsToLoadedData_()||0},enumerable:!0},timeToLoadedData:{get:function(){return a.masterPlaylistController_.timeToLoadedData_()||0},enumerable:!0},buffered:{get:function(){return WO(a.tech_.buffered())},enumerable:!0},currentTime:{get:function(){return a.tech_.currentTime()},enumerable:!0},currentSource:{get:function(){return a.tech_.currentSource_},enumerable:!0},currentTech:{get:function(){return a.tech_.name_},enumerable:!0},duration:{get:function(){return a.tech_.duration()},enumerable:!0},master:{get:function(){return a.playlists.master},enumerable:!0},playerDimensions:{get:function(){return a.tech_.currentDimensions()},enumerable:!0},seekable:{get:function(){return WO(a.tech_.seekable())},enumerable:!0},timestamp:{get:function(){return Date.now()},enumerable:!0},videoPlaybackQuality:{get:function(){return a.tech_.getVideoPlaybackQuality()},enumerable:!0}}),this.tech_.one("canplay",this.masterPlaylistController_.setupFirstPlay.bind(this.masterPlaylistController_)),this.tech_.on("bandwidthupdate",function(){a.options_.useBandwidthFromLocalStorage&&x1t({bandwidth:a.bandwidth,throughput:Math.round(a.throughput)})}),this.masterPlaylistController_.on("selectedinitialmedia",function(){d1t(a)}),this.masterPlaylistController_.sourceUpdater_.on("createdsourcebuffers",function(){a.setupEme_()}),this.on(this.masterPlaylistController_,"progress",function(){this.tech_.trigger("progress")}),this.on(this.masterPlaylistController_,"firstplay",function(){this.ignoreNextSeekingEvent_=!0}),this.setupQualityLevels_(),this.tech_.el()&&(this.mediaSourceUrl_=Ct.URL.createObjectURL(this.masterPlaylistController_.mediaSource),this.tech_.src(this.mediaSourceUrl_))}},i.createKeySessions_=function(){var r=this,o=this.masterPlaylistController_.mediaTypes_.AUDIO.activePlaylistLoader;this.logger_("waiting for EME key session creation"),C1t({player:this.player_,sourceKeySystems:this.source_.keySystems,audioMedia:o&&o.media(),mainPlaylists:this.playlists.master.playlists}).then(function(){r.logger_("created EME key session"),r.masterPlaylistController_.sourceUpdater_.initializedEme()}).catch(function(a){r.logger_("error while creating EME key session",a),r.player_.error({message:"Failed to initialize media keys for EME",code:3})})},i.handleWaitingForKey_=function(){this.logger_("waitingforkey fired, attempting to create any new key sessions"),this.createKeySessions_()},i.setupEme_=function(){var r=this,o=this.masterPlaylistController_.mediaTypes_.AUDIO.activePlaylistLoader,a=T1t({player:this.player_,sourceKeySystems:this.source_.keySystems,media:this.playlists.media(),audioMedia:o&&o.media()});if(this.player_.tech_.on("keystatuschange",function(s){if(s.status==="output-restricted"){var l=r.masterPlaylistController_.master();if(!(!l||!l.playlists)){var u=[];if(l.playlists.forEach(function(d){d&&d.attributes&&d.attributes.RESOLUTION&&d.attributes.RESOLUTION.height>=720&&(!d.excludeUntil||d.excludeUntil<1/0)&&(d.excludeUntil=1/0,u.push(d))}),u.length){var c;(c=Vt.log).warn.apply(c,['DRM keystatus changed to "output-restricted." Removing the following HD playlists that will most likely fail to play and clearing the buffer. This may be due to HDCP restrictions on the stream and the capabilities of the current device.'].concat(u)),r.masterPlaylistController_.fastQualityChange_()}}}}),this.handleWaitingForKey_=this.handleWaitingForKey_.bind(this),this.player_.tech_.on("waitingforkey",this.handleWaitingForKey_),Vt.browser.IE_VERSION===11||!a){this.masterPlaylistController_.sourceUpdater_.initializedEme();return}this.createKeySessions_()},i.setupQualityLevels_=function(){var r=this,o=Vt.players[this.tech_.options_.playerId];!o||!o.qualityLevels||this.qualityLevels_||(this.qualityLevels_=o.qualityLevels(),this.masterPlaylistController_.on("selectedinitialmedia",function(){S1t(r.qualityLevels_,r)}),this.playlists.on("mediachange",function(){vNe(r.qualityLevels_,r.playlists)}))},e.version=function(){return{"@videojs/http-streaming":pNe,"mux.js":v1t,"mpd-parser":y1t,"m3u8-parser":m1t,"aes-decrypter":b1t}},i.version=function(){return this.constructor.version()},i.canChangeType=function(){return hNe.canChangeType()},i.play=function(){this.masterPlaylistController_.play()},i.setCurrentTime=function(r){this.masterPlaylistController_.setCurrentTime(r)},i.duration=function(){return this.masterPlaylistController_.duration()},i.seekable=function(){return this.masterPlaylistController_.seekable()},i.dispose=function(){this.playbackWatcher_&&this.playbackWatcher_.dispose(),this.masterPlaylistController_&&this.masterPlaylistController_.dispose(),this.qualityLevels_&&this.qualityLevels_.dispose(),this.player_&&(delete this.player_.vhs,delete this.player_.dash,delete this.player_.hls),this.tech_&&this.tech_.vhs&&delete this.tech_.vhs,this.tech_&&delete this.tech_.hls,this.mediaSourceUrl_&&Ct.URL.revokeObjectURL&&(Ct.URL.revokeObjectURL(this.mediaSourceUrl_),this.mediaSourceUrl_=null),this.tech_&&this.tech_.off("waitingforkey",this.handleWaitingForKey_),t.prototype.dispose.call(this)},i.convertToProgramTime=function(r,o){return ICt({playlist:this.masterPlaylistController_.media(),time:r,callback:o})},i.seekToProgramTime=function(r,o,a,s){return a===void 0&&(a=!0),s===void 0&&(s=2),NCt({programTime:r,playlist:this.masterPlaylistController_.media(),retryCount:s,pauseAfterSeek:a,seekTo:this.options_.seekTo,tech:this.options_.tech,callback:o})},e})(w1t),F3={name:"videojs-http-streaming",VERSION:pNe,canHandleSource:function(e,i){i===void 0&&(i={});var n=Vt.mergeOptions(Vt.options,i);return F3.canPlayType(e.type,n)},handleSource:function(e,i,n){n===void 0&&(n={});var r=Vt.mergeOptions(Vt.options,n);return i.vhs=new ore(e,i,r),Vt.hasOwnProperty("hls")||Object.defineProperty(i,"hls",{get:function(){return Vt.log.warn("player.tech().hls is deprecated. Use player.tech().vhs instead."),i.vhs},configurable:!0}),i.vhs.xhr=W2e(),i.vhs.src(e.src,e.type),i.vhs},canPlayType:function(e,i){var n=lIe(e);if(!n)return"";var r=F3.getOverrideNative(i),o=nd.supportsTypeNatively(n),a=!o||r;return a?"maybe":""},getOverrideNative:function(e){e===void 0&&(e={});var i=e,n=i.vhs,r=n===void 0?{}:n,o=i.hls,a=o===void 0?{}:o,s=!(Vt.browser.IS_ANY_SAFARI||Vt.browser.IS_IOS),l=r.overrideNative,u=l===void 0?s:l,c=a.overrideNative,d=c===void 0?!1:c;return d||u}},A1t=function(){return XU("avc1.4d400d,mp4a.40.2")};A1t()&&Vt.getTech("Html5").registerSourceHandler(F3,0);Vt.VhsHandler=ore;Object.defineProperty(Vt,"HlsHandler",{get:function(){return Vt.log.warn("videojs.HlsHandler is deprecated. Use videojs.VhsHandler instead."),ore},configurable:!0});Vt.VhsSourceHandler=F3;Object.defineProperty(Vt,"HlsSourceHandler",{get:function(){return Vt.log.warn("videojs.HlsSourceHandler is deprecated. Use videojs.VhsSourceHandler instead."),F3},configurable:!0});Vt.Vhs=nd;Object.defineProperty(Vt,"Hls",{get:function(){return Vt.log.warn("videojs.Hls is deprecated. Use videojs.Vhs instead."),nd},configurable:!0});Vt.use||(Vt.registerComponent("Hls",nd),Vt.registerComponent("Vhs",nd));Vt.options.vhs=Vt.options.vhs||{};Vt.options.hls=Vt.options.hls||{};if(!Vt.getPlugin||!Vt.getPlugin("reloadSourceOnError")){var O1t=Vt.registerPlugin||Vt.plugin;O1t("reloadSourceOnError",g1t)}const D1t={autoplay:!1,controls:!1,responsive:!0,fluid:!0};function R1t(t){const e=J.useRef(null),i=J.useRef(void 0),n=J.useRef(void 0),[r]=J.useState(),[o,a]=J.useState(!1),[s,l]=J.useState(t.videoFile);s!==t.videoFile&&(l(t.videoFile),a(!1));const u=t.videoFile.url,c=t.onVideoLoadedCallback,d=t.soundMuted,f=t.testOffset,h=t.videoFile,p=t.playbackState,g=t.videoStatusCallback,v=t.syncModeEnabled;J.useEffect(()=>{var b;i!=null&&i.current&&((b=i.current)==null||b.muted(d))},[d]),J.useEffect(()=>{n.current&&(f!==void 0?n.current.setVideoOffsetSeconds(f):n.current.setVideoOffsetSeconds((h==null?void 0:h.offsetMs)/1e3))},[f,h]),J.useEffect(()=>{var S;if(!u||!h)return;const b={...D1t,sources:[{src:u}]};if(i.current)i.current.src(b.sources);else{const _=document.createElement("video-js");_.classList.add("vjs-big-play-centered"),(S=e.current)==null||S.appendChild(_),i.current=Vt(_,b,()=>{c()}),i.current.fill(!0),i.current.playsinline(!0),i.current.muted(d),i.current.on("loadedmetadata",()=>{a(!0)});const C=localStorage.getItem("maxDriftTimeSeconds"),P=localStorage.getItem("videoSyncEnabled"),x={play(){i.current.play()},pause(){i.current.pause()},paused(){return i.current.paused()},currentTime(){return i.current.currentTime()},setCurrentTime(E){i.current.currentTime(E)},duration(){return i.current.duration()},setMuted(E){i.current.muted(E)},muted(){return i.current.muted()}};n.current=Wyt.createSession(x,h.offsetMs/1e3,C!=null?parseFloat(C):void 0,!(P!=null&&P==="no"))}},[u]);const y=J.useRef(p);y.current=p;const m=500;return J.useEffect(()=>{if(!v&&n.current&&i.current&&o){const b=async()=>{var C;const _=y.current;if(!(!_||!n.current)&&!((C=i.current)!=null&&C.seeking()))try{const P=await n.current.syncVideoWithRecording(_);g(P)}catch(P){typeof P=="object"&&P!==null&&"name"in P&&P.name==="FailedToPlayError"&&i.current&&(console.log("Failed to play, this is likely a permission error?"),console.log(`muted ${i.current.muted()}, inline? ${i.current.playsinline()}`),console.log(P),i.current.muted(!0),i.current.playsinline(!0),i.current.play())}};b();const S=setInterval(b,m);return()=>clearInterval(S)}},[p,o,v,g]),J.useEffect(()=>{var b;i.current!==void 0&&(i.current.controls(v),(b=n.current)==null||b.enable(!v))},[v]),L.jsx("div",{className:"h-full",children:L.jsxs("div",{"data-vjs-player":!0,className:"h-full",children:[r===!0&&L.jsx("p",{children:"Failed to load video. Please remove this panel and add it again."}),!r&&L.jsx("div",{className:"h-full",ref:e})]})})}J.createContext(void 0);const M1t=["xxl","xl","lg","md","sm","xs"],L1t="xs",are=J.createContext({prefixes:{},breakpoints:M1t,minBreakpoint:L1t}),{Consumer:rFt,Provider:iFt}=are;function sre(t,e){const{prefixes:i}=J.useContext(are);return t||i[e]||e}function k1t(){const{dir:t}=J.useContext(are);return t==="rtl"}const mNe=J.forwardRef(({className:t,bsPrefix:e,as:i="div",...n},r)=>(e=sre(e,"popover-header"),L.jsx(i,{ref:r,className:hm(t,e),...n})));mNe.displayName="PopoverHeader";const lre=J.forwardRef(({className:t,bsPrefix:e,as:i="div",...n},r)=>(e=sre(e,"popover-body"),L.jsx(i,{ref:r,className:hm(t,e),...n})));lre.displayName="PopoverBody";function I1t(t,e){let i=t;return t==="left"?i=e?"end":"start":t==="right"&&(i=e?"start":"end"),i}function N1t(t="absolute"){return{position:t,top:"0",left:"0",opacity:"0",pointerEvents:"none"}}const bNe=J.forwardRef(({bsPrefix:t,placement:e="right",className:i,style:n,children:r,body:o,arrowProps:a,hasDoneInitialMeasure:s,popper:l,show:u,...c},d)=>{const f=sre(t,"popover"),h=k1t(),[p]=(e==null?void 0:e.split("-"))||[],g=I1t(p,h);let v=n;return u&&!s&&(v={...n,...N1t(l==null?void 0:l.strategy)}),L.jsxs("div",{ref:d,role:"tooltip",style:v,"x-placement":p,className:hm(i,f,p&&`bs-popover-${g}`),...c,children:[L.jsx("div",{className:"popover-arrow",...a}),o?L.jsx(lre,{children:r}):r]})});bNe.displayName="Popover";const $de=Object.assign(bNe,{Header:mNe,Body:lre,POPPER_OFFSET:[0,8]});function F1t(t){return L.jsxs(L.Fragment,{children:[L.jsxs("div",{className:"d-flex justify-content-between align-items-center rounded px-2 py-1 m-1 remotive-primary-20-background flex-truncate",style:{minWidth:230},children:[L.jsx("div",{className:"d-flex align-items-start flex-column flex-truncate",children:t.titleElement}),L.jsx("div",{className:"d-flex justify-content-center align-items-center flex-row align-items-center",children:t.actionElement})]}),t.footer]})}J.forwardRef(function(e,i){const n=qt.c(24);let r,o,a,s;n[0]!==e?({titleElement:s,items:o,footer:r,...a}=e,n[0]=e,n[1]=r,n[2]=o,n[3]=a,n[4]=s):(r=n[1],o=n[2],a=n[3],s=n[4]);const l=a.show,u=`settings-popover ${a.className||""}`;let c;n[5]!==s?(c=s&&L.jsx("div",{className:"mb-1",children:s}),n[5]=s,n[6]=c):c=n[6];let d;n[7]!==o?(d=o.map(B1t),n[7]=o,n[8]=d):d=n[8];let f;n[9]!==d?(f=L.jsx("div",{className:"d-flex justify-content-center remotive-font-md flex-column",children:d}),n[9]=d,n[10]=f):f=n[10];let h;n[11]!==r?(h=L.jsx(L.Fragment,{children:r}),n[11]=r,n[12]=h):h=n[12];let p;n[13]!==f||n[14]!==h?(p=L.jsxs("div",{className:"text-center",children:[f,h]}),n[13]=f,n[14]=h,n[15]=p):p=n[15];let g;n[16]!==c||n[17]!==p?(g=L.jsxs($de.Body,{className:"p-2 shadow-sm",children:[c,p]}),n[16]=c,n[17]=p,n[18]=g):g=n[18];let v;return n[19]!==a||n[20]!==i||n[21]!==u||n[22]!==g?(v=L.jsx($de,{show:l,ref:i,...a,className:u,children:g}),n[19]=a,n[20]=i,n[21]=u,n[22]=g,n[23]=v):v=n[23],v});function B1t(t,e){return L.jsx(F1t,{titleElement:t.titleElement,actionElement:t.actionElement,footer:t.footer},e)}const cq=(t="",e="")=>L.jsx(L.Fragment,{children:L.jsxs("p",{className:"text-start m-0",children:[L.jsx("span",{className:"font-bold",children:t})," ",L.jsx("br",{})," ",L.jsx("span",{className:"text-xs",children:e})]})}),ure=t=>typeof t=="number"&&!isNaN(t),Mj=t=>typeof t=="string",SNe=t=>typeof t=="function",j1t=t=>J.isValidElement(t)||Mj(t)||SNe(t)||ure(t);function V1t(t,e,i){i===void 0&&(i=300);const{scrollHeight:n,style:r}=t;requestAnimationFrame(()=>{r.minHeight="initial",r.height=n+"px",r.transition=`all ${i}ms`,requestAnimationFrame(()=>{r.height="0",r.padding="0",r.margin="0",setTimeout(e,i)})})}function iW(t){let{enter:e,exit:i,appendPosition:n=!1,collapse:r=!0,collapseDuration:o=300}=t;return function(a){let{children:s,position:l,preventExitTransition:u,done:c,nodeRef:d,isIn:f,playToast:h}=a;const p=n?`${e}--${l}`:e,g=n?`${i}--${l}`:i,v=J.useRef(0);return J.useLayoutEffect(()=>{const y=d.current,m=p.split(" "),b=S=>{S.target===d.current&&(h(),y.removeEventListener("animationend",b),y.removeEventListener("animationcancel",b),v.current===0&&S.type!=="animationcancel"&&y.classList.remove(...m))};y.classList.add(...m),y.addEventListener("animationend",b),y.addEventListener("animationcancel",b)},[]),J.useEffect(()=>{const y=d.current,m=()=>{y.removeEventListener("animationend",m),r?V1t(y,c,o):c()};f||(u?m():(v.current=1,y.className+=` ${g}`,y.addEventListener("animationend",m)))},[f]),Wn.createElement(Wn.Fragment,null,s)}}const Wy=new Map;let aJ=[];const Wde=new Set,_Ne=()=>Wy.size>0;function H1t(t,e){var i;if(e)return!((i=Wy.get(e))==null||!i.isToastActive(t));let n=!1;return Wy.forEach(r=>{r.isToastActive(t)&&(n=!0)}),n}function U1t(t,e){j1t(t)&&(_Ne()||aJ.push({content:t,options:e}),Wy.forEach(i=>{i.buildToast(t,e)}))}function Gde(t,e){Wy.forEach(i=>{e!=null&&e!=null&&e.containerId?(e==null?void 0:e.containerId)===i.id&&i.toggle(t,e==null?void 0:e.id):i.toggle(t,e==null?void 0:e.id)})}let z1t=1;const PNe=()=>""+z1t++;function $1t(t){return t&&(Mj(t.toastId)||ure(t.toastId))?t.toastId:PNe()}function Lj(t,e){return U1t(t,e),e.toastId}function jz(t,e){return{...e,type:e&&e.type||t,toastId:$1t(e)}}function E4(t){return(e,i)=>Lj(e,jz(t,i))}function $s(t,e){return Lj(t,jz("default",e))}$s.loading=(t,e)=>Lj(t,jz("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...e})),$s.promise=function(t,e,i){let n,{pending:r,error:o,success:a}=e;r&&(n=Mj(r)?$s.loading(r,i):$s.loading(r.render,{...i,...r}));const s={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},l=(c,d,f)=>{if(d==null)return void $s.dismiss(n);const h={type:c,...s,...i,data:f},p=Mj(d)?{render:d}:d;return n?$s.update(n,{...h,...p}):$s(p.render,{...h,...p}),f},u=SNe(t)?t():t;return u.then(c=>l("success",a,c)).catch(c=>l("error",o,c)),u},$s.success=E4("success"),$s.info=E4("info"),$s.error=E4("error"),$s.warning=E4("warning"),$s.warn=$s.warning,$s.dark=(t,e)=>Lj(t,jz("default",{theme:"dark",...e})),$s.dismiss=function(t){(function(e){var i;if(_Ne()){if(e==null||Mj(i=e)||ure(i))Wy.forEach(n=>{n.removeToast(e)});else if(e&&("containerId"in e||"id"in e)){const n=Wy.get(e.containerId);n?n.removeToast(e.id):Wy.forEach(r=>{r.removeToast(e.id)})}}else aJ=aJ.filter(n=>e!=null&&n.options.toastId!==e)})(t)},$s.clearWaitingQueue=function(t){t===void 0&&(t={}),Wy.forEach(e=>{!e.props.limit||t.containerId&&e.id!==t.containerId||e.clearQueue()})},$s.isActive=H1t,$s.update=function(t,e){e===void 0&&(e={});const i=((n,r)=>{var o;let{containerId:a}=r;return(o=Wy.get(a||1))==null?void 0:o.toasts.get(n)})(t,e);if(i){const{props:n,content:r}=i,o={delay:100,...n,...e,toastId:e.toastId||t,updateId:PNe()};o.toastId!==t&&(o.staleId=t);const a=o.render||r;delete o.render,Lj(a,o)}},$s.done=t=>{$s.update(t,{progress:1})},$s.onChange=function(t){return Wde.add(t),()=>{Wde.delete(t)}},$s.play=t=>Gde(!0,t),$s.pause=t=>Gde(!1,t);const nW=function(t,e){return e===void 0&&(e=!1),{enter:`Toastify--animate Toastify__${t}-enter`,exit:`Toastify--animate Toastify__${t}-exit`,appendPosition:e}};iW(nW("bounce",!0));iW(nW("slide",!0));iW(nW("zoom"));iW(nW("flip"));const oW=J.createContext(null);class W1t{constructor(e,i){this.brokerUrl=e,this.accessToken=i,this._networkServiceClient=new Id.NetworkServicePromiseClient(this.brokerUrl),this._systemServiceClient=new Id.SystemServicePromiseClient(this.brokerUrl)}_authHeaders(){const e={};return this.accessToken&&(e["x-api-key"]=this.accessToken),e}async getNamespaceNames(){try{return(await this._systemServiceClient.getConfiguration(new Id.Empty,this._authHeaders())).getNetworkinfoList().filter(i=>i.getType()!=="virtual").map(i=>{var n;return((n=i.getNamespace())==null?void 0:n.getName())??""})}catch(e){return console.error("[BrokerService] Failed to get namespaces:",e),[]}}_onDataCallback(e){return{frameIdFrequency:e.map(n=>({frameId:n.getFrameid(),frequency:`${n.getCount()}`})),receivedTimestamp:Date.now()}}subscribeToFrameDistribution(e,i,n){this.frameDistributionStream!==void 0&&(this.frameDistributionStream.cancel(),console.debug("[BrokerService] Killing previous frame distribution stream and setting up a new one"));const r=new Id.FramesDistributionConfig,o=new Id.NameSpace;return o.setName(e),r.setNamespace(o),this.frameDistributionStream=this._networkServiceClient.subscribeToFramesDistribution(r,this._authHeaders()),this.frameDistributionStream.on("data",a=>{try{const s=this._onDataCallback(a.getCountsbyframeidList());i(s)}catch(s){console.debug("[BrokerService] Error processing frame distribution data:",s)}}),this.frameDistributionStream.on("end",()=>{console.debug("[BrokerService] Frame distribution subscription ended"),n()}),this.frameDistributionStream.on("error",a=>{console.debug("[BrokerService] Frame distribution stream error:",a)}),()=>{this.frameDistributionStream&&(this.frameDistributionStream.cancel(),this.frameDistributionStream=void 0)}}}const Yde=5e3;async function G1t(t){const e=new Y1t(t);return await e.init(),e}class Y1t{constructor(e){this._pendingSubscriptions=[],this._subscriptions=[],this._stream=void 0,this._onSignalStreamEndCallback=()=>{},this._onSignalStreamErrorCallback=()=>{},this._shouldAutoReconnect=!1,this._retryTimeoutId=void 0,this.createCombinedSubscribeConfig=()=>{const i=new Id.SubscriberConfig,n=new Id.SignalIds;n.setSignalidList(this._subscriptions.map(o=>o.signalId));const r=new Id.ClientId;return r.setId(this._clientId),i.setSignals(n),i.setClientid(r),i.setOnchange(this._subscriptions.some(o=>o.callbackOnlyOnChange)),i},this.broadcastSignalsToClientSubscribers=i=>{var d,f,h,p,g,v,y,m;const n=i.getSignalList().find(b=>b.getRaw_asU8().length!==0),r=((f=(d=n==null?void 0:n.getId())==null?void 0:d.getNamespace())==null?void 0:f.getName())??"",o=i.getSignalList().filter(b=>b.getRaw_asU8().length===0).map(b=>{const S=b.getId(),_=S==null?void 0:S.getName();return{value:b.getDouble()||b.getInteger(),namespace:r,name:_,timestampeUs:b.getTimestamp()}}),a=(g=(p=(h=i.getSignalList().find(b=>{var S;return((S=b==null?void 0:b.getId())==null?void 0:S.getNamespace())!==void 0}))==null?void 0:h.getId())==null?void 0:p.getNamespace())==null?void 0:g.getName(),l={name:((v=n==null?void 0:n.getId())==null?void 0:v.getName())??(o.length>0?o[0].name.split(".")[0]:(m=(y=i.getSignalList()[0])==null?void 0:y.getId())==null?void 0:m.getName()),namespace:r,timestampUs:(n==null?void 0:n.getTimestamp())??0,signals:o,value:n==null?void 0:n.getRaw_asU8()},u=this._subscriptions.filter(b=>{var S;return b.signalId.getName().split(".")[0]===l.name&&((S=b.signalId.getNamespace())==null?void 0:S.getName())===a}).map(b=>b.onSignalCallback);[...new Set(u)].forEach(b=>b(l))},this.authenticationHeaders=()=>({...this.accessToken!==void 0?{"x-api-key":this.accessToken}:{},deadline:""+(new Date().getMilliseconds()+5e3)}),this.refreshSubscriptions=()=>{if(this._retryTimeoutId!==void 0&&(clearTimeout(this._retryTimeoutId),this._retryTimeoutId=void 0),this._subscriptions.length>0){this._shouldAutoReconnect=!0;const i=this.createCombinedSubscribeConfig();this._stream!==void 0&&(console.debug("Killing old stream"),this._stream.cancel()),console.debug("Creating new stream, reapplying all subscriptions"),this._stream=this._networkServiceClient.subscribeToSignals(i,this.authenticationHeaders()),this._stream.on("data",n=>{try{this.broadcastSignalsToClientSubscribers(n)}catch{console.debug(`Received broker signal data, but an error occurred error=${JSON.stringify(n)}`)}}),this._stream.on("metadata",n=>{console.debug(`Received broker metadata=${JSON.stringify(n)}`)}),this._stream.on("end",()=>{console.debug("Signal subscription ended normally"),this._onSignalStreamEndCallback(),this._subscriptions.forEach(n=>{n.onEndCallback&&n.onEndCallback()}),this.scheduleReconnect()}),this._stream.on("status",n=>{console.debug(`Received broker status=${JSON.stringify(n)}`)}),this._stream.on("error",n=>{console.debug(`Received broker signal stream error=${JSON.stringify(n)}`),this._onSignalStreamErrorCallback(),this.scheduleReconnect()})}else this._shouldAutoReconnect=!1,this._stream!==void 0&&(console.debug("No subscriptions, killing stream"),this._stream.cancel(),this._stream=void 0)},this.applyPendingSubscriptions=()=>{this._subscriptions=[...this._pendingSubscriptions,...this._subscriptions],this._pendingSubscriptions=[],this.refreshSubscriptions()},this.removeSubscriptions=i=>{const n=new Set(i),r=this._subscriptions.filter(o=>n.has(o.subscriptionId)).length;this._subscriptions=this._subscriptions.filter(o=>!n.has(o.subscriptionId)),this._pendingSubscriptions=this._pendingSubscriptions.filter(o=>!n.has(o.subscriptionId)),r>0&&(console.debug(`Removed ${r} subscriptions, refreshing stream`),this.refreshSubscriptions())},this.addPendingSubscription=i=>{console.log("Adding pending subscription",i);for(const n of i.signalId){const r=new Id.SignalId,o=new Id.NameSpace;if(n.type==="signal")o.setName(n.frameId.namespace),r.setName(n.signalName),r.setNamespace(o);else if(n.type==="frame"){const s=n;o.setName(s.namespace),r.setName(s.name),r.setNamespace(o)}const a={signalId:r,subscriptionId:i.subscriptionId,onSignalCallback:i.onSignalCallback,callbackOnlyOnChange:!1,onEndCallback:i.onEndCallback};this._pendingSubscriptions.push(a)}return i.subscriptionId},this.brokerUrl=e,this._clientId=crypto.randomUUID(),this.systemClient=new Id.SystemServicePromiseClient(this.brokerUrl),this._networkServiceClient=new Id.NetworkServicePromiseClient(this.brokerUrl),this.accessToken=void 0,this._namespaces=[],this._frames=[]}listSignals(){throw new Error("Method not implemented.")}getBrokerUrl(){return this.brokerUrl}scheduleReconnect(){!this._shouldAutoReconnect||this._subscriptions.length===0||(console.debug(`Signal stream disconnected, reconnecting in ${Yde}ms...`),this._retryTimeoutId=setTimeout(()=>{this._retryTimeoutId=void 0,this._shouldAutoReconnect&&this.refreshSubscriptions()},Yde))}async init(){const e=await this.systemClient.getConfiguration(new Id.Empty,this._authHeaders());this._namespaces=e.getNetworkinfoList().map(r=>{var o;return{name:((o=r.getNamespace())==null?void 0:o.getName())??"Unknown",type:r.getType()}});const i=this._namespaces.map(r=>this._getFrames(r.name)),n=await Promise.all(i);this._frames=n.flat()}listNamespaces(){return this._namespaces}listFrames(e){return e?this._frames.filter(i=>!e||i.namespace===e):this._frames}_authHeaders(){const e={};return this.accessToken&&(e["x-api-key"]=this.accessToken),e}_parseNamedValues(e){if(!e)return;const i={};return e.forEach((n,r)=>{i[r]=n}),Object.keys(i).length>0?i:void 0}async _getFrames(e){const i=new Id.NameSpace;return i.setName(e),(await this.systemClient.listSignals(i,this._authHeaders())).getFrameList().map(o=>{var h;const a=o.getSignalinfo().getId(),s=o.getSignalinfo().getMetadata(),l=o.getChildinfoList(),u=a.getName(),c=((h=a==null?void 0:a.getNamespace())==null?void 0:h.getName())??e,d=s==null?void 0:s.getFrameid(),f={namespace:c,name:u,type:"frame",toString(){return`${c}:${u}`}};return{longName:()=>`${a.getNamespace().getName()}:${(a==null?void 0:a.getName())??"Unknown"}`,isBrokerFrame:()=>!0,frameId:d,id:f,name:u,namespace:c,description:s.getDescription(),max:s.getMax(),min:s.getMin(),unit:s.getUnit(),size:s.getSize(),isRaw:s.getIsraw(),factor:s.getFactor(),offset:s.getOffset(),cycleTime:s.getCycletime(),receivers:s.getReceiverList(),senders:s.getSenderList(),signals:l.map(p=>{const g=p.getMetadata(),v=p.getId().getName();return{id:{frameId:f,type:"signal",signalName:v,toString:()=>`${f.namespace}:${v}`},frameName:u,namespace:c,name:v,description:g==null?void 0:g.getDescription(),unit:g==null?void 0:g.getUnit(),min:g==null?void 0:g.getMin(),max:g==null?void 0:g.getMax(),namedValues:this._parseNamedValues(g==null?void 0:g.getNamedvaluesMap()),longName:()=>`${c}:${v}`}})}})}}function q1t(t){const e=qt.c(8),{connectedBroker:i,disconnectBroker:n}=F6();let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r={broker:void 0},e[0]=r):r=e[0];const[o,a]=J.useState(r);let s,l;e[1]!==i||e[2]!==n?(s=()=>{if(!i){a({broker:void 0});return}let c=!1;return G1t(i.grpcUrl).then(d=>{c||a({broker:{frameDistributionService:new W1t(i.grpcUrl),liveSignalService:d}})}).catch(d=>{n(),console.error("Failed to connect to LiveSignalService:",d),$s.error("Error when connecting to RemotiveBroker",{autoClose:1e4})}),()=>{c=!0}},l=[i,n],e[1]=i,e[2]=n,e[3]=s,e[4]=l):(s=e[3],l=e[4]),J.useEffect(s,l);let u;return e[5]!==o||e[6]!==t.children?(u=L.jsx(oW.Provider,{value:o,children:t.children}),e[5]=o,e[6]=t.children,e[7]=u):u=e[7],u}function CNe(){const t=J.useContext(oW);if(!t)throw new Error("useLiveSignalService must be used within a BrokerConnectionContext");return t}function $V(){const t=J.useContext(oW);if(!t)throw new Error("useLiveSignalService must be used within a BrokerConnectionContext");if(!t.broker)throw new Error("useLiveSignalService must be used with active BrokerConnection");return t.broker.liveSignalService}function WV(){const t=qt.c(2),e=$V();let i;return t[0]!==e?(i=e.listFrames(),t[0]=e,t[1]=i):i=t[1],i}function X1t(){const t=qt.c(2),e=WV();let i;return t[0]!==e?(i=e.flatMap(K1t),t[0]=e,t[1]=i):i=t[1],i}function K1t(t){return t.signals}function Z1t(){var e;const t=J.useContext(oW);if(!t)throw new Error("useFrameDistributionService must be used within a BrokerConnectionContext");return(e=t.broker)==null?void 0:e.frameDistributionService}class B3{constructor(e,i,n){this.subscriptionId=crypto.randomUUID(),this.signalId=e,this.onSignalCallback=i,this.onEndCallback=n}}function j3(t){"@babel/helpers - typeof";return j3=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},j3(t)}function J1t(t,e){if(j3(t)!="object"||!t)return t;var i=t[Symbol.toPrimitive];if(i!==void 0){var n=i.call(t,e);if(j3(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Q1t(t){var e=J1t(t,"string");return j3(e)=="symbol"?e:e+""}function br(t,e,i){return(e=Q1t(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function TNe(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var dq,qde;function ext(){if(qde)return dq;qde=1;var t=function(i,n,r,o,a,s,l,u){if(!i){var c;if(n===void 0)c=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var d=[r,o,a,s,l,u],f=0;c=new Error(n.replace(/%s/g,function(){return d[f++]})),c.name="Invariant Violation"}throw c.framesToPop=1,c}};return dq=t,dq}var txt=ext(),ec=TNe(txt),Yn=J.createContext(null);function rxt(){ec(!!J.useContext,"useGoogleMap is React hook and requires React version 16.8+");var t=J.useContext(Yn);return ec(!!t,"useGoogleMap needs a GoogleMap available up in the tree"),t}function ixt(t,e,i){return Object.keys(t).reduce(function(r,o){return e(r,t[o],o)},i)}function nxt(t,e){Object.keys(t).forEach(i=>e(t[i],i))}function oxt(t,e,i,n){var r={},o=(a,s)=>{var l=i[s];l!==e[s]&&(r[s]=l,a(n,l))};return nxt(t,o),r}function axt(t,e,i){var n=ixt(i,function(o,a,s){return typeof t[s]=="function"&&o.push(google.maps.event.addListener(e,a,t[s])),o},[]);return n}function sxt(t){google.maps.event.removeListener(t)}function So(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];t.forEach(sxt)}function co(t){var{updaterMap:e,eventMap:i,prevProps:n,nextProps:r,instance:o}=t,a=axt(r,o,i);return oxt(e,n,r,o),a}var Xde={onDblClick:"dblclick",onDragEnd:"dragend",onDragStart:"dragstart",onMapTypeIdChanged:"maptypeid_changed",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseDown:"mousedown",onMouseUp:"mouseup",onRightClick:"rightclick",onTilesLoaded:"tilesloaded",onBoundsChanged:"bounds_changed",onCenterChanged:"center_changed",onClick:"click",onDrag:"drag",onHeadingChanged:"heading_changed",onIdle:"idle",onProjectionChanged:"projection_changed",onResize:"resize",onTiltChanged:"tilt_changed",onZoomChanged:"zoom_changed"},Kde={extraMapTypes(t,e){e.forEach(function(n,r){t.mapTypes.set(String(r),n)})},center(t,e){t.setCenter(e)},clickableIcons(t,e){t.setClickableIcons(e)},heading(t,e){t.setHeading(e)},mapTypeId(t,e){t.setMapTypeId(e)},options(t,e){t.setOptions(e)},streetView(t,e){t.setStreetView(e)},tilt(t,e){t.setTilt(e)},zoom(t,e){t.setZoom(e)}};function lxt(t){var{children:e,options:i,id:n,mapContainerStyle:r,mapContainerClassName:o,center:a,onClick:s,onDblClick:l,onDrag:u,onDragEnd:c,onDragStart:d,onMouseMove:f,onMouseOut:h,onMouseOver:p,onMouseDown:g,onMouseUp:v,onRightClick:y,onCenterChanged:m,onLoad:b,onUnmount:S}=t,[_,C]=J.useState(null),P=J.useRef(null),[x,E]=J.useState(null),[A,R]=J.useState(null),[M,D]=J.useState(null),[F,I]=J.useState(null),[V,z]=J.useState(null),[G,H]=J.useState(null),[U,k]=J.useState(null),[X,W]=J.useState(null),[Y,te]=J.useState(null),[oe,de]=J.useState(null),[ge,Ee]=J.useState(null),[Re,Ae]=J.useState(null);return J.useEffect(()=>{i&&_!==null&&_.setOptions(i)},[_,i]),J.useEffect(()=>{_!==null&&typeof a<"u"&&_.setCenter(a)},[_,a]),J.useEffect(()=>{_&&l&&(A!==null&&google.maps.event.removeListener(A),R(google.maps.event.addListener(_,"dblclick",l)))},[l]),J.useEffect(()=>{_&&c&&(M!==null&&google.maps.event.removeListener(M),D(google.maps.event.addListener(_,"dragend",c)))},[c]),J.useEffect(()=>{_&&d&&(F!==null&&google.maps.event.removeListener(F),I(google.maps.event.addListener(_,"dragstart",d)))},[d]),J.useEffect(()=>{_&&g&&(V!==null&&google.maps.event.removeListener(V),z(google.maps.event.addListener(_,"mousedown",g)))},[g]),J.useEffect(()=>{_&&f&&(G!==null&&google.maps.event.removeListener(G),H(google.maps.event.addListener(_,"mousemove",f)))},[f]),J.useEffect(()=>{_&&h&&(U!==null&&google.maps.event.removeListener(U),k(google.maps.event.addListener(_,"mouseout",h)))},[h]),J.useEffect(()=>{_&&p&&(X!==null&&google.maps.event.removeListener(X),W(google.maps.event.addListener(_,"mouseover",p)))},[p]),J.useEffect(()=>{_&&v&&(Y!==null&&google.maps.event.removeListener(Y),te(google.maps.event.addListener(_,"mouseup",v)))},[v]),J.useEffect(()=>{_&&y&&(oe!==null&&google.maps.event.removeListener(oe),de(google.maps.event.addListener(_,"rightclick",y)))},[y]),J.useEffect(()=>{_&&s&&(ge!==null&&google.maps.event.removeListener(ge),Ee(google.maps.event.addListener(_,"click",s)))},[s]),J.useEffect(()=>{_&&u&&(Re!==null&&google.maps.event.removeListener(Re),Ae(google.maps.event.addListener(_,"drag",u)))},[u]),J.useEffect(()=>{_&&m&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(_,"center_changed",m)))},[s]),J.useEffect(()=>{var Pe=P.current===null?null:new google.maps.Map(P.current,i);return C(Pe),Pe!==null&&b&&b(Pe),()=>{Pe!==null&&S&&S(Pe)}},[]),L.jsx("div",{id:n,ref:P,style:r,className:o,children:L.jsx(Yn.Provider,{value:_,children:_!==null?e:null})})}J.memo(lxt);class uxt extends J.PureComponent{constructor(){super(...arguments),br(this,"state",{map:null}),br(this,"registeredEvents",[]),br(this,"mapRef",null),br(this,"getInstance",()=>this.mapRef===null?null:new google.maps.Map(this.mapRef,this.props.options)),br(this,"panTo",e=>{var i=this.getInstance();i&&i.panTo(e)}),br(this,"setMapCallback",()=>{this.state.map!==null&&this.props.onLoad&&this.props.onLoad(this.state.map)}),br(this,"getRef",e=>{this.mapRef=e})}componentDidMount(){var e=this.getInstance();this.registeredEvents=co({updaterMap:Kde,eventMap:Xde,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{map:e}},this.setMapCallback)}componentDidUpdate(e){this.state.map!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Kde,eventMap:Xde,prevProps:e,nextProps:this.props,instance:this.state.map}))}componentWillUnmount(){this.state.map!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.map),So(this.registeredEvents))}render(){return L.jsx("div",{id:this.props.id,ref:this.getRef,style:this.props.mapContainerStyle,className:this.props.mapContainerClassName,children:L.jsx(Yn.Provider,{value:this.state.map,children:this.state.map!==null?this.props.children:null})})}}function Zde(t,e,i,n,r,o,a){try{var s=t[o](a),l=s.value}catch(u){return void i(u)}s.done?e(l):Promise.resolve(l).then(n,r)}function xNe(t){return function(){var e=this,i=arguments;return new Promise(function(n,r){var o=t.apply(e,i);function a(l){Zde(o,n,r,a,s,"next",l)}function s(l){Zde(o,n,r,a,s,"throw",l)}a(void 0)})}}function ENe(t){var{googleMapsApiKey:e,googleMapsClientId:i,version:n="weekly",language:r,region:o,libraries:a,channel:s,mapIds:l,authReferrerPolicy:u,apiUrl:c="https://maps.googleapis.com"}=t,d=[];return ec(e&&i||!(e&&i),"You need to specify either googleMapsApiKey or googleMapsClientId for @react-google-maps/api load script to work. You cannot use both at the same time."),e?d.push("key=".concat(e)):i&&d.push("client=".concat(i)),n&&d.push("v=".concat(n)),r&&d.push("language=".concat(r)),o&&d.push("region=".concat(o)),a&&a.length&&d.push("libraries=".concat(a.sort().join(","))),s&&d.push("channel=".concat(s)),l&&l.length&&d.push("map_ids=".concat(l.join(","))),u&&d.push("auth_referrer_policy=".concat(u)),d.push("loading=async"),d.push("callback=initMap"),"".concat(c,"/maps/api/js?").concat(d.join("&"))}var uP=typeof document<"u";function wNe(t){var{url:e,id:i,nonce:n}=t;return uP?new Promise(function(o,a){var s=document.getElementById(i),l=window;if(s){var u=s.getAttribute("data-state");if(s.src===e&&u!=="error"){if(u==="ready")return o(i);var c=l.initMap,d=s.onerror;l.initMap=function(){c&&c(),o(i)},s.onerror=function(h){d&&d(h),a(h)};return}else s.remove()}var f=document.createElement("script");f.type="text/javascript",f.src=e,f.id=i,f.async=!0,f.nonce=n||"",f.onerror=function(p){f.setAttribute("data-state","error"),a(p)},l.initMap=function(){f.setAttribute("data-state","ready"),o(i)},document.head.appendChild(f)}).catch(r=>{throw console.error("injectScript error: ",r),r}):Promise.reject(new Error("document is undefined"))}function Jde(t){var e=t.href;return e&&(e.indexOf("https://fonts.googleapis.com/css?family=Roboto")===0||e.indexOf("https://fonts.googleapis.com/css?family=Google+Sans+Text")===0)?!0:t.tagName.toLowerCase()==="style"&&t.styleSheet&&t.styleSheet.cssText&&t.styleSheet.cssText.replace(`\r
`,"").indexOf(".gm-style")===0?(t.styleSheet.cssText="",!0):t.tagName.toLowerCase()==="style"&&t.innerHTML&&t.innerHTML.replace(`\r
`,"").indexOf(".gm-style")===0?(t.innerHTML="",!0):t.tagName.toLowerCase()==="style"&&!t.styleSheet&&!t.innerHTML}function cre(){var t=document.getElementsByTagName("head")[0];if(t){var e=t.insertBefore.bind(t);t.insertBefore=function(r,o){return Jde(r)||Reflect.apply(e,t,[r,o]),r};var i=t.appendChild.bind(t);t.appendChild=function(r){return Jde(r)||Reflect.apply(i,t,[r]),r}}}var aN=!1;function ANe(){return L.jsx("div",{children:"Loading..."})}var V3={id:"script-loader",version:"weekly"};class cxt extends J.PureComponent{constructor(){super(...arguments),br(this,"check",null),br(this,"state",{loaded:!1}),br(this,"cleanupCallback",()=>{delete window.google.maps,this.injectScript()}),br(this,"isCleaningUp",xNe(function*(){function e(i){if(!aN)i();else if(uP)var n=window.setInterval(function(){aN||(window.clearInterval(n),i())},1)}return new Promise(e)})),br(this,"cleanup",()=>{aN=!0;var e=document.getElementById(this.props.id);e&&e.parentNode&&e.parentNode.removeChild(e),Array.prototype.slice.call(document.getElementsByTagName("script")).filter(function(n){return typeof n.src=="string"&&n.src.includes("maps.googleapis")}).forEach(function(n){n.parentNode&&n.parentNode.removeChild(n)}),Array.prototype.slice.call(document.getElementsByTagName("link")).filter(function(n){return n.href==="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700|Google+Sans"}).forEach(function(n){n.parentNode&&n.parentNode.removeChild(n)}),Array.prototype.slice.call(document.getElementsByTagName("style")).filter(function(n){return n.innerText!==void 0&&n.innerText.length>0&&n.innerText.includes(".gm-")}).forEach(function(n){n.parentNode&&n.parentNode.removeChild(n)})}),br(this,"injectScript",()=>{this.props.preventGoogleFontsLoading&&cre(),ec(!!this.props.id,'LoadScript requires "id" prop to be a string: %s',this.props.id);var e={id:this.props.id,nonce:this.props.nonce,url:ENe(this.props)};wNe(e).then(()=>{this.props.onLoad&&this.props.onLoad(),this.setState(function(){return{loaded:!0}})}).catch(i=>{this.props.onError&&this.props.onError(i),console.error(`
          There has been an Error with loading Google Maps API script, please check that you provided correct google API key (`.concat(this.props.googleMapsApiKey||"-",") or Client ID (").concat(this.props.googleMapsClientId||"-",`) to <LoadScript />
          Otherwise it is a Network issue.
        `))})}),br(this,"getRef",e=>{this.check=e})}componentDidMount(){if(uP){if(window.google&&window.google.maps&&!aN){console.error("google api is already presented");return}this.isCleaningUp().then(this.injectScript).catch(function(i){console.error("Error at injecting script after cleaning up: ",i)})}}componentDidUpdate(e){this.props.libraries!==e.libraries&&console.warn("Performance warning! LoadScript has been reloaded unintentionally! You should not pass `libraries` prop as new array. Please keep an array of libraries as static class property for Components and PureComponents, or just a const variable outside of component, or somewhere in config files or ENV variables"),uP&&e.language!==this.props.language&&(this.cleanup(),this.setState(function(){return{loaded:!1}},this.cleanupCallback))}componentWillUnmount(){if(uP){this.cleanup();var e=()=>{this.check||(delete window.google,aN=!1)};window.setTimeout(e,1),this.props.onUnmount&&this.props.onUnmount()}}render(){return L.jsxs(L.Fragment,{children:[L.jsx("div",{ref:this.getRef}),this.state.loaded?this.props.children:this.props.loadingElement||L.jsx(ANe,{})]})}}br(cxt,"defaultProps",V3);function dxt(t,e){if(t==null)return{};var i={};for(var n in t)if({}.hasOwnProperty.call(t,n)){if(e.includes(n))continue;i[n]=t[n]}return i}function dre(t,e){if(t==null)return{};var i,n,r=dxt(t,e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);for(n=0;n<o.length;n++)i=o[n],e.includes(i)||{}.propertyIsEnumerable.call(t,i)&&(r[i]=t[i])}return r}var Qde;function fxt(t){var{id:e=V3.id,version:i=V3.version,nonce:n,googleMapsApiKey:r,googleMapsClientId:o,language:a,region:s,libraries:l,preventGoogleFontsLoading:u,channel:c,mapIds:d,authReferrerPolicy:f,apiUrl:h="https://maps.googleapis.com"}=t,p=J.useRef(!1),[g,v]=J.useState(!1),[y,m]=J.useState(void 0);J.useEffect(function(){return p.current=!0,()=>{p.current=!1}},[]),J.useEffect(function(){uP&&u&&cre()},[u]),J.useEffect(function(){g&&ec(!!window.google,"useLoadScript was marked as loaded, but window.google is not present. Something went wrong.")},[g]);var b=ENe({version:i,googleMapsApiKey:r,googleMapsClientId:o,language:a,region:s,libraries:l,channel:c,mapIds:d,authReferrerPolicy:f,apiUrl:h});J.useEffect(function(){if(!uP)return;function C(){p.current&&(v(!0),Qde=b)}if(window.google&&window.google.maps&&Qde===b){C();return}wNe({id:e,url:b,nonce:n}).then(C).catch(function(x){p.current&&m(x),console.warn(`
        There has been an Error with loading Google Maps API script, please check that you provided correct google API key (`.concat(r||"-",") or Client ID (").concat(o||"-",`)
        Otherwise it is a Network issue.
      `)),console.error(x)})},[e,b,n]);var S=J.useRef(void 0);return J.useEffect(function(){S.current&&l!==S.current&&console.warn("Performance warning! LoadScript has been reloaded unintentionally! You should not pass `libraries` prop as new array. Please keep an array of libraries as static class property for Components and PureComponents, or just a const variable outside of component, or somewhere in config files or ENV variables"),S.current=l},[l]),{isLoaded:g,loadError:y,url:b}}var hxt=["loadingElement","onLoad","onError","onUnmount","children"],pxt=L.jsx(ANe,{});function gxt(t){var{loadingElement:e,onLoad:i,onError:n,onUnmount:r,children:o}=t,a=dre(t,hxt),{isLoaded:s,loadError:l}=fxt(a);return J.useEffect(function(){s&&typeof i=="function"&&i()},[s,i]),J.useEffect(function(){l&&typeof n=="function"&&n(l)},[l,n]),J.useEffect(function(){return()=>{r&&r()}},[r]),s?o:e||pxt}J.memo(gxt);function vxt(t,e,i,n){function r(o){return o instanceof i?o:new i(function(a){a(o)})}return new(i||(i=Promise))(function(o,a){function s(c){try{u(n.next(c))}catch(d){a(d)}}function l(c){try{u(n.throw(c))}catch(d){a(d)}}function u(c){c.done?o(c.value):r(c.value).then(s,l)}u((n=n.apply(t,[])).next())})}function yxt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var mxt=function t(e,i){if(e===i)return!0;if(e&&i&&typeof e=="object"&&typeof i=="object"){if(e.constructor!==i.constructor)return!1;var n,r,o;if(Array.isArray(e)){if(n=e.length,n!=i.length)return!1;for(r=n;r--!==0;)if(!t(e[r],i[r]))return!1;return!0}if(e.constructor===RegExp)return e.source===i.source&&e.flags===i.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===i.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===i.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(i).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(i,o[r]))return!1;for(r=n;r--!==0;){var a=o[r];if(!t(e[a],i[a]))return!1}return!0}return e!==e&&i!==i},bxt=yxt(mxt),efe="__googleMapsScriptId",RL;(function(t){t[t.INITIALIZED=0]="INITIALIZED",t[t.LOADING=1]="LOADING",t[t.SUCCESS=2]="SUCCESS",t[t.FAILURE=3]="FAILURE"})(RL||(RL={}));class HO{constructor(e){var{apiKey:i,authReferrerPolicy:n,channel:r,client:o,id:a=efe,language:s,libraries:l=[],mapIds:u,nonce:c,region:d,retries:f=3,url:h="https://maps.googleapis.com/maps/api/js",version:p}=e;if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=i,this.authReferrerPolicy=n,this.channel=r,this.client=o,this.id=a||efe,this.language=s,this.libraries=l,this.mapIds=u,this.nonce=c,this.region=d,this.retries=f,this.url=h,this.version=p,HO.instance){if(!bxt(this.options,HO.instance.options))throw new Error("Loader must not be called again with different options. ".concat(JSON.stringify(this.options)," !== ").concat(JSON.stringify(HO.instance.options)));return HO.instance}HO.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?RL.FAILURE:this.done?RL.SUCCESS:this.loading?RL.LOADING:RL.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){var e=this.url;return e+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(e+="&key=".concat(this.apiKey)),this.channel&&(e+="&channel=".concat(this.channel)),this.client&&(e+="&client=".concat(this.client)),this.libraries.length>0&&(e+="&libraries=".concat(this.libraries.join(","))),this.language&&(e+="&language=".concat(this.language)),this.region&&(e+="&region=".concat(this.region)),this.version&&(e+="&v=".concat(this.version)),this.mapIds&&(e+="&map_ids=".concat(this.mapIds.join(","))),this.authReferrerPolicy&&(e+="&auth_referrer_policy=".concat(this.authReferrerPolicy)),e}deleteScript(){var e=document.getElementById(this.id);e&&e.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((e,i)=>{this.loadCallback(n=>{n?i(n.error):e(window.google)})})}importLibrary(e){return this.execute(),google.maps.importLibrary(e)}loadCallback(e){this.callbacks.push(e),this.execute()}setScript(){var e,i;if(document.getElementById(this.id)){this.callback();return}var n={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};Object.keys(n).forEach(o=>!n[o]&&delete n[o]),!((i=(e=window==null?void 0:window.google)===null||e===void 0?void 0:e.maps)===null||i===void 0)&&i.importLibrary||(o=>{var a,s,l,u="The Google Maps JavaScript API",c="google",d="importLibrary",f="__ib__",h=document,p=window;p=p[c]||(p[c]={});var g=p.maps||(p.maps={}),v=new Set,y=new URLSearchParams,m=()=>a||(a=new Promise((b,S)=>vxt(this,void 0,void 0,function*(){var _;yield s=h.createElement("script"),s.id=this.id,y.set("libraries",[...v]+"");for(l in o)y.set(l.replace(/[A-Z]/g,C=>"_"+C[0].toLowerCase()),o[l]);y.set("callback",c+".maps."+f),s.src=this.url+"?"+y,g[f]=b,s.onerror=()=>a=S(Error(u+" could not load.")),s.nonce=this.nonce||((_=h.querySelector("script[nonce]"))===null||_===void 0?void 0:_.nonce)||"",h.head.append(s)})));g[d]?console.warn(u+" only loads once. Ignoring:",o):g[d]=function(b){for(var S=arguments.length,_=new Array(S>1?S-1:0),C=1;C<S;C++)_[C-1]=arguments[C];return v.add(b)&&m().then(()=>g[d](b,..._))}})(n);var r=this.libraries.map(o=>this.importLibrary(o));r.length||r.push(this.importLibrary("core")),Promise.all(r).then(()=>this.callback(),o=>{var a=new ErrorEvent("error",{error:o});this.loadErrorCallback(a)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(e){if(this.errors.push(e),this.errors.length<=this.retries){var i=this.errors.length*Math.pow(2,this.errors.length);console.error("Failed to load Google Maps script, retrying in ".concat(i," ms.")),setTimeout(()=>{this.deleteScript(),this.setScript()},i)}else this.onerrorEvent=e,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(e=>{e(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),!this.loading)if(this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader. This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading=!0,this.setScript()}}}var Sxt=["maps"];function _xt(t){var{id:e=V3.id,version:i=V3.version,nonce:n,googleMapsApiKey:r,language:o,region:a,libraries:s=Sxt,preventGoogleFontsLoading:l,mapIds:u,authReferrerPolicy:c}=t,d=J.useRef(!1),[f,h]=J.useState(!1),[p,g]=J.useState(void 0);J.useEffect(function(){return d.current=!0,()=>{d.current=!1}},[]);var v=J.useMemo(()=>new HO({id:e,apiKey:r,version:i,libraries:s,language:o||"en",region:a||"US",mapIds:u||[],nonce:n||"",authReferrerPolicy:c||"origin"}),[e,r,i,s,o,a,u,n,c]);J.useEffect(function(){f||v.load().then(()=>{d.current&&h(!0)}).catch(b=>{g(b)})},[]),J.useEffect(()=>{uP&&l&&cre()},[l]);var y=J.useRef();return J.useEffect(()=>{y.current&&s!==y.current&&console.warn("Performance warning! LoadScript has been reloaded unintentionally! You should not pass `libraries` prop as new array. Please keep an array of libraries as static class property for Components and PureComponents, or just a const variable outside of component, or somewhere in config files or ENV variables"),y.current=s},[s]),{isLoaded:f,loadError:p}}function tfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Vz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?tfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):tfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var rfe={},ife={options(t,e){t.setOptions(e)}};function Pxt(t){var{options:e,onLoad:i,onUnmount:n}=t,r=J.useContext(Yn),[o,a]=J.useState(null);return J.useEffect(()=>{o!==null&&o.setMap(r)},[r]),J.useEffect(()=>{e&&o!==null&&o.setOptions(e)},[o,e]),J.useEffect(()=>{var s=new google.maps.TrafficLayer(Vz(Vz({},e),{},{map:r}));return a(s),i&&i(s),()=>{o!==null&&(n&&n(o),o.setMap(null))}},[]),null}J.memo(Pxt);class Cxt extends J.PureComponent{constructor(){super(...arguments),br(this,"state",{trafficLayer:null}),br(this,"setTrafficLayerCallback",()=>{this.state.trafficLayer!==null&&this.props.onLoad&&this.props.onLoad(this.state.trafficLayer)}),br(this,"registeredEvents",[])}componentDidMount(){var e=new google.maps.TrafficLayer(Vz(Vz({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:ife,eventMap:rfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{trafficLayer:e}},this.setTrafficLayerCallback)}componentDidUpdate(e){this.state.trafficLayer!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:ife,eventMap:rfe,prevProps:e,nextProps:this.props,instance:this.state.trafficLayer}))}componentWillUnmount(){this.state.trafficLayer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.trafficLayer),So(this.registeredEvents),this.state.trafficLayer.setMap(null))}render(){return null}}br(Cxt,"contextType",Yn);function Txt(t){var{onLoad:e,onUnmount:i}=t,n=J.useContext(Yn),[r,o]=J.useState(null);return J.useEffect(()=>{r!==null&&r.setMap(n)},[n]),J.useEffect(()=>{var a=new google.maps.BicyclingLayer;return o(a),a.setMap(n),e&&e(a),()=>{a!==null&&(i&&i(a),a.setMap(null))}},[]),null}J.memo(Txt);class xxt extends J.PureComponent{constructor(){super(...arguments),br(this,"state",{bicyclingLayer:null}),br(this,"setBicyclingLayerCallback",()=>{this.state.bicyclingLayer!==null&&(this.state.bicyclingLayer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.bicyclingLayer))})}componentDidMount(){var e=new google.maps.BicyclingLayer;this.setState(()=>({bicyclingLayer:e}),this.setBicyclingLayerCallback)}componentWillUnmount(){this.state.bicyclingLayer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.bicyclingLayer),this.state.bicyclingLayer.setMap(null))}render(){return null}}br(xxt,"contextType",Yn);function Ext(t){var{onLoad:e,onUnmount:i}=t,n=J.useContext(Yn),[r,o]=J.useState(null);return J.useEffect(()=>{r!==null&&r.setMap(n)},[n]),J.useEffect(()=>{var a=new google.maps.TransitLayer;return o(a),a.setMap(n),e&&e(a),()=>{r!==null&&(i&&i(r),r.setMap(null))}},[]),null}J.memo(Ext);class wxt extends J.PureComponent{constructor(){super(...arguments),br(this,"state",{transitLayer:null}),br(this,"setTransitLayerCallback",()=>{this.state.transitLayer!==null&&(this.state.transitLayer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.transitLayer))})}componentDidMount(){var e=new google.maps.TransitLayer;this.setState(function(){return{transitLayer:e}},this.setTransitLayerCallback)}componentWillUnmount(){this.state.transitLayer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.transitLayer),this.state.transitLayer.setMap(null))}render(){return null}}br(wxt,"contextType",Yn);function nfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Hz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?nfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):nfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var ofe={onCircleComplete:"circlecomplete",onMarkerComplete:"markercomplete",onOverlayComplete:"overlaycomplete",onPolygonComplete:"polygoncomplete",onPolylineComplete:"polylinecomplete",onRectangleComplete:"rectanglecomplete"},afe={drawingMode(t,e){t.setDrawingMode(e)},options(t,e){t.setOptions(e)}};function Axt(t){var{options:e,drawingMode:i,onCircleComplete:n,onMarkerComplete:r,onOverlayComplete:o,onPolygonComplete:a,onPolylineComplete:s,onRectangleComplete:l,onLoad:u,onUnmount:c}=t,d=J.useContext(Yn),[f,h]=J.useState(null),[p,g]=J.useState(null),[v,y]=J.useState(null),[m,b]=J.useState(null),[S,_]=J.useState(null),[C,P]=J.useState(null),[x,E]=J.useState(null);return J.useEffect(()=>{f!==null&&f.setMap(d)},[d]),J.useEffect(()=>{e&&f!==null&&f.setOptions(e)},[f,e]),J.useEffect(()=>{f!==null&&f.setDrawingMode(i??null)},[f,i]),J.useEffect(()=>{f&&n&&(p!==null&&google.maps.event.removeListener(p),g(google.maps.event.addListener(f,"circlecomplete",n)))},[f,n]),J.useEffect(()=>{f&&r&&(v!==null&&google.maps.event.removeListener(v),y(google.maps.event.addListener(f,"markercomplete",r)))},[f,r]),J.useEffect(()=>{f&&o&&(m!==null&&google.maps.event.removeListener(m),b(google.maps.event.addListener(f,"overlaycomplete",o)))},[f,o]),J.useEffect(()=>{f&&a&&(S!==null&&google.maps.event.removeListener(S),_(google.maps.event.addListener(f,"polygoncomplete",a)))},[f,a]),J.useEffect(()=>{f&&s&&(C!==null&&google.maps.event.removeListener(C),P(google.maps.event.addListener(f,"polylinecomplete",s)))},[f,s]),J.useEffect(()=>{f&&l&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(f,"rectanglecomplete",l)))},[f,l]),J.useEffect(()=>{ec(!!google.maps.drawing,"Did you include prop libraries={['drawing']} in the URL? %s",google.maps.drawing);var A=new google.maps.drawing.DrawingManager(Hz(Hz({},e),{},{map:d}));return i&&A.setDrawingMode(i),n&&g(google.maps.event.addListener(A,"circlecomplete",n)),r&&y(google.maps.event.addListener(A,"markercomplete",r)),o&&b(google.maps.event.addListener(A,"overlaycomplete",o)),a&&_(google.maps.event.addListener(A,"polygoncomplete",a)),s&&P(google.maps.event.addListener(A,"polylinecomplete",s)),l&&E(google.maps.event.addListener(A,"rectanglecomplete",l)),h(A),u&&u(A),()=>{f!==null&&(p&&google.maps.event.removeListener(p),v&&google.maps.event.removeListener(v),m&&google.maps.event.removeListener(m),S&&google.maps.event.removeListener(S),C&&google.maps.event.removeListener(C),x&&google.maps.event.removeListener(x),c&&c(f),f.setMap(null))}},[]),null}J.memo(Axt);class Oxt extends J.PureComponent{constructor(e){super(e),br(this,"registeredEvents",[]),br(this,"state",{drawingManager:null}),br(this,"setDrawingManagerCallback",()=>{this.state.drawingManager!==null&&this.props.onLoad&&this.props.onLoad(this.state.drawingManager)}),ec(!!google.maps.drawing,"Did you include prop libraries={['drawing']} in the URL? %s",google.maps.drawing)}componentDidMount(){var e=new google.maps.drawing.DrawingManager(Hz(Hz({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:afe,eventMap:ofe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{drawingManager:e}},this.setDrawingManagerCallback)}componentDidUpdate(e){this.state.drawingManager!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:afe,eventMap:ofe,prevProps:e,nextProps:this.props,instance:this.state.drawingManager}))}componentWillUnmount(){this.state.drawingManager!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.drawingManager),So(this.registeredEvents),this.state.drawingManager.setMap(null))}render(){return null}}br(Oxt,"contextType",Yn);function sfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function KL(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?sfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):sfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var lfe={onAnimationChanged:"animation_changed",onClick:"click",onClickableChanged:"clickable_changed",onCursorChanged:"cursor_changed",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDraggableChanged:"draggable_changed",onDragStart:"dragstart",onFlatChanged:"flat_changed",onIconChanged:"icon_changed",onMouseDown:"mousedown",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onPositionChanged:"position_changed",onRightClick:"rightclick",onShapeChanged:"shape_changed",onTitleChanged:"title_changed",onVisibleChanged:"visible_changed",onZindexChanged:"zindex_changed"},ufe={animation(t,e){t.setAnimation(e)},clickable(t,e){t.setClickable(e)},cursor(t,e){t.setCursor(e)},draggable(t,e){t.setDraggable(e)},icon(t,e){t.setIcon(e)},label(t,e){t.setLabel(e)},map(t,e){t.setMap(e)},opacity(t,e){t.setOpacity(e)},options(t,e){t.setOptions(e)},position(t,e){t.setPosition(e)},shape(t,e){t.setShape(e)},title(t,e){t.setTitle(e)},visible(t,e){t.setVisible(e)},zIndex(t,e){t.setZIndex(e)}},Uz={};function Dxt(t){var{position:e,options:i,clusterer:n,noClustererRedraw:r,children:o,draggable:a,visible:s,animation:l,clickable:u,cursor:c,icon:d,label:f,opacity:h,shape:p,title:g,zIndex:v,onClick:y,onDblClick:m,onDrag:b,onDragEnd:S,onDragStart:_,onMouseOut:C,onMouseOver:P,onMouseUp:x,onMouseDown:E,onRightClick:A,onClickableChanged:R,onCursorChanged:M,onAnimationChanged:D,onDraggableChanged:F,onFlatChanged:I,onIconChanged:V,onPositionChanged:z,onShapeChanged:G,onTitleChanged:H,onVisibleChanged:U,onZindexChanged:k,onLoad:X,onUnmount:W}=t,Y=J.useContext(Yn),[te,oe]=J.useState(null),[de,ge]=J.useState(null),[Ee,Re]=J.useState(null),[Ae,Pe]=J.useState(null),[we,Te]=J.useState(null),[ke,$e]=J.useState(null),[Ne,ve]=J.useState(null),[pe,fe]=J.useState(null),[me,Ce]=J.useState(null),[Ue,Qe]=J.useState(null),[it,xt]=J.useState(null),[wt,$t]=J.useState(null),[Mt,rt]=J.useState(null),[qe,vt]=J.useState(null),[kt,Xe]=J.useState(null),[_t,Ht]=J.useState(null),[Pt,Jt]=J.useState(null),[zt,Bt]=J.useState(null),[Mr,Be]=J.useState(null),[We,dt]=J.useState(null),[Tt,nr]=J.useState(null),[Ar,Qr]=J.useState(null);J.useEffect(()=>{te!==null&&te.setMap(Y)},[Y]),J.useEffect(()=>{typeof i<"u"&&te!==null&&te.setOptions(i)},[te,i]),J.useEffect(()=>{typeof a<"u"&&te!==null&&te.setDraggable(a)},[te,a]),J.useEffect(()=>{e&&te!==null&&te.setPosition(e)},[te,e]),J.useEffect(()=>{typeof s<"u"&&te!==null&&te.setVisible(s)},[te,s]),J.useEffect(()=>{te==null||te.setAnimation(l)},[te,l]),J.useEffect(()=>{te&&u!==void 0&&te.setClickable(u)},[te,u]),J.useEffect(()=>{te&&c!==void 0&&te.setCursor(c)},[te,c]),J.useEffect(()=>{te&&d!==void 0&&te.setIcon(d)},[te,d]),J.useEffect(()=>{te&&f!==void 0&&te.setLabel(f)},[te,f]),J.useEffect(()=>{te&&h!==void 0&&te.setOpacity(h)},[te,h]),J.useEffect(()=>{te&&p!==void 0&&te.setShape(p)},[te,p]),J.useEffect(()=>{te&&g!==void 0&&te.setTitle(g)},[te,g]),J.useEffect(()=>{te&&v!==void 0&&te.setZIndex(v)},[te,v]),J.useEffect(()=>{te&&m&&(de!==null&&google.maps.event.removeListener(de),ge(google.maps.event.addListener(te,"dblclick",m)))},[m]),J.useEffect(()=>{te&&S&&(Ee!==null&&google.maps.event.removeListener(Ee),Re(google.maps.event.addListener(te,"dragend",S)))},[S]),J.useEffect(()=>{te&&_&&(Ae!==null&&google.maps.event.removeListener(Ae),Pe(google.maps.event.addListener(te,"dragstart",_)))},[_]),J.useEffect(()=>{te&&E&&(we!==null&&google.maps.event.removeListener(we),Te(google.maps.event.addListener(te,"mousedown",E)))},[E]),J.useEffect(()=>{te&&C&&(ke!==null&&google.maps.event.removeListener(ke),$e(google.maps.event.addListener(te,"mouseout",C)))},[C]),J.useEffect(()=>{te&&P&&(Ne!==null&&google.maps.event.removeListener(Ne),ve(google.maps.event.addListener(te,"mouseover",P)))},[P]),J.useEffect(()=>{te&&x&&(pe!==null&&google.maps.event.removeListener(pe),fe(google.maps.event.addListener(te,"mouseup",x)))},[x]),J.useEffect(()=>{te&&A&&(me!==null&&google.maps.event.removeListener(me),Ce(google.maps.event.addListener(te,"rightclick",A)))},[A]),J.useEffect(()=>{te&&y&&(Ue!==null&&google.maps.event.removeListener(Ue),Qe(google.maps.event.addListener(te,"click",y)))},[y]),J.useEffect(()=>{te&&b&&(it!==null&&google.maps.event.removeListener(it),xt(google.maps.event.addListener(te,"drag",b)))},[b]),J.useEffect(()=>{te&&R&&(wt!==null&&google.maps.event.removeListener(wt),$t(google.maps.event.addListener(te,"clickable_changed",R)))},[R]),J.useEffect(()=>{te&&M&&(Mt!==null&&google.maps.event.removeListener(Mt),rt(google.maps.event.addListener(te,"cursor_changed",M)))},[M]),J.useEffect(()=>{te&&D&&(qe!==null&&google.maps.event.removeListener(qe),vt(google.maps.event.addListener(te,"animation_changed",D)))},[D]),J.useEffect(()=>{te&&F&&(kt!==null&&google.maps.event.removeListener(kt),Xe(google.maps.event.addListener(te,"draggable_changed",F)))},[F]),J.useEffect(()=>{te&&I&&(_t!==null&&google.maps.event.removeListener(_t),Ht(google.maps.event.addListener(te,"flat_changed",I)))},[I]),J.useEffect(()=>{te&&V&&(Pt!==null&&google.maps.event.removeListener(Pt),Jt(google.maps.event.addListener(te,"icon_changed",V)))},[V]),J.useEffect(()=>{te&&z&&(zt!==null&&google.maps.event.removeListener(zt),Bt(google.maps.event.addListener(te,"position_changed",z)))},[z]),J.useEffect(()=>{te&&G&&(Mr!==null&&google.maps.event.removeListener(Mr),Be(google.maps.event.addListener(te,"shape_changed",G)))},[G]),J.useEffect(()=>{te&&H&&(We!==null&&google.maps.event.removeListener(We),dt(google.maps.event.addListener(te,"title_changed",H)))},[H]),J.useEffect(()=>{te&&U&&(Tt!==null&&google.maps.event.removeListener(Tt),nr(google.maps.event.addListener(te,"visible_changed",U)))},[U]),J.useEffect(()=>{te&&k&&(Ar!==null&&google.maps.event.removeListener(Ar),Qr(google.maps.event.addListener(te,"zindex_changed",k)))},[k]),J.useEffect(()=>{var oi=KL(KL(KL({},i||Uz),n?Uz:{map:Y}),{},{position:e}),Yr=new google.maps.Marker(oi);return n?n.addMarker(Yr,!!r):Yr.setMap(Y),e&&Yr.setPosition(e),typeof s<"u"&&Yr.setVisible(s),typeof a<"u"&&Yr.setDraggable(a),typeof u<"u"&&Yr.setClickable(u),typeof c=="string"&&Yr.setCursor(c),d&&Yr.setIcon(d),typeof f<"u"&&Yr.setLabel(f),typeof h<"u"&&Yr.setOpacity(h),p&&Yr.setShape(p),typeof g=="string"&&Yr.setTitle(g),typeof v=="number"&&Yr.setZIndex(v),m&&ge(google.maps.event.addListener(Yr,"dblclick",m)),S&&Re(google.maps.event.addListener(Yr,"dragend",S)),_&&Pe(google.maps.event.addListener(Yr,"dragstart",_)),E&&Te(google.maps.event.addListener(Yr,"mousedown",E)),C&&$e(google.maps.event.addListener(Yr,"mouseout",C)),P&&ve(google.maps.event.addListener(Yr,"mouseover",P)),x&&fe(google.maps.event.addListener(Yr,"mouseup",x)),A&&Ce(google.maps.event.addListener(Yr,"rightclick",A)),y&&Qe(google.maps.event.addListener(Yr,"click",y)),b&&xt(google.maps.event.addListener(Yr,"drag",b)),R&&$t(google.maps.event.addListener(Yr,"clickable_changed",R)),M&&rt(google.maps.event.addListener(Yr,"cursor_changed",M)),D&&vt(google.maps.event.addListener(Yr,"animation_changed",D)),F&&Xe(google.maps.event.addListener(Yr,"draggable_changed",F)),I&&Ht(google.maps.event.addListener(Yr,"flat_changed",I)),V&&Jt(google.maps.event.addListener(Yr,"icon_changed",V)),z&&Bt(google.maps.event.addListener(Yr,"position_changed",z)),G&&Be(google.maps.event.addListener(Yr,"shape_changed",G)),H&&dt(google.maps.event.addListener(Yr,"title_changed",H)),U&&nr(google.maps.event.addListener(Yr,"visible_changed",U)),k&&Qr(google.maps.event.addListener(Yr,"zindex_changed",k)),oe(Yr),X&&X(Yr),()=>{de!==null&&google.maps.event.removeListener(de),Ee!==null&&google.maps.event.removeListener(Ee),Ae!==null&&google.maps.event.removeListener(Ae),we!==null&&google.maps.event.removeListener(we),ke!==null&&google.maps.event.removeListener(ke),Ne!==null&&google.maps.event.removeListener(Ne),pe!==null&&google.maps.event.removeListener(pe),me!==null&&google.maps.event.removeListener(me),Ue!==null&&google.maps.event.removeListener(Ue),wt!==null&&google.maps.event.removeListener(wt),Mt!==null&&google.maps.event.removeListener(Mt),qe!==null&&google.maps.event.removeListener(qe),kt!==null&&google.maps.event.removeListener(kt),_t!==null&&google.maps.event.removeListener(_t),Pt!==null&&google.maps.event.removeListener(Pt),zt!==null&&google.maps.event.removeListener(zt),We!==null&&google.maps.event.removeListener(We),Tt!==null&&google.maps.event.removeListener(Tt),Ar!==null&&google.maps.event.removeListener(Ar),W&&W(Yr),n?n.removeMarker(Yr,!!r):Yr&&Yr.setMap(null)}},[]);var Si=J.useMemo(()=>o?J.Children.map(o,oi=>{if(!J.isValidElement(oi))return oi;var Yr=oi;return J.cloneElement(Yr,{anchor:te})}):null,[o,te]);return L.jsx(L.Fragment,{children:Si})||null}J.memo(Dxt);class ONe extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[])}componentDidMount(){var e=this;return xNe(function*(){var i=KL(KL(KL({},e.props.options||Uz),e.props.clusterer?Uz:{map:e.context}),{},{position:e.props.position});e.marker=new google.maps.Marker(i),e.props.clusterer?e.props.clusterer.addMarker(e.marker,!!e.props.noClustererRedraw):e.marker.setMap(e.context),e.registeredEvents=co({updaterMap:ufe,eventMap:lfe,prevProps:{},nextProps:e.props,instance:e.marker}),e.props.onLoad&&e.props.onLoad(e.marker)})()}componentDidUpdate(e){this.marker&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:ufe,eventMap:lfe,prevProps:e,nextProps:this.props,instance:this.marker}))}componentWillUnmount(){this.marker&&(this.props.onUnmount&&this.props.onUnmount(this.marker),So(this.registeredEvents),this.props.clusterer?this.props.clusterer.removeMarker(this.marker,!!this.props.noClustererRedraw):this.marker&&this.marker.setMap(null))}render(){var e=this.props.children?J.Children.map(this.props.children,i=>{if(!J.isValidElement(i))return i;var n=i;return J.cloneElement(n,{anchor:this.marker})}):null;return e||null}}br(ONe,"contextType",Yn);var Rxt=(function(){function t(e,i){e.getClusterer().extend(t,google.maps.OverlayView),this.cluster=e,this.clusterClassName=this.cluster.getClusterer().getClusterClass(),this.className=this.clusterClassName,this.styles=i,this.center=void 0,this.div=null,this.sums=null,this.visible=!1,this.boundsChangedListener=null,this.url="",this.height=0,this.width=0,this.anchorText=[0,0],this.anchorIcon=[0,0],this.textColor="black",this.textSize=11,this.textDecoration="none",this.fontWeight="bold",this.fontStyle="normal",this.fontFamily="Arial,sans-serif",this.backgroundPosition="0 0",this.cMouseDownInCluster=null,this.cDraggingMapByCluster=null,this.timeOut=null,this.setMap(e.getMap()),this.onBoundsChanged=this.onBoundsChanged.bind(this),this.onMouseDown=this.onMouseDown.bind(this),this.onClick=this.onClick.bind(this),this.onMouseOver=this.onMouseOver.bind(this),this.onMouseOut=this.onMouseOut.bind(this),this.onAdd=this.onAdd.bind(this),this.onRemove=this.onRemove.bind(this),this.draw=this.draw.bind(this),this.hide=this.hide.bind(this),this.show=this.show.bind(this),this.useStyle=this.useStyle.bind(this),this.setCenter=this.setCenter.bind(this),this.getPosFromLatLng=this.getPosFromLatLng.bind(this)}return t.prototype.onBoundsChanged=function(){this.cDraggingMapByCluster=this.cMouseDownInCluster},t.prototype.onMouseDown=function(){this.cMouseDownInCluster=!0,this.cDraggingMapByCluster=!1},t.prototype.onClick=function(e){if(this.cMouseDownInCluster=!1,!this.cDraggingMapByCluster){var i=this.cluster.getClusterer();if(google.maps.event.trigger(i,"click",this.cluster),google.maps.event.trigger(i,"clusterclick",this.cluster),i.getZoomOnClick()){var n=i.getMaxZoom(),r=this.cluster.getBounds(),o=i.getMap();o!==null&&"fitBounds"in o&&o.fitBounds(r),this.timeOut=window.setTimeout(function(){var a=i.getMap();if(a!==null){"fitBounds"in a&&a.fitBounds(r);var s=a.getZoom()||0;n!==null&&s>n&&a.setZoom(n+1)}},100)}e.cancelBubble=!0,e.stopPropagation&&e.stopPropagation()}},t.prototype.onMouseOver=function(){google.maps.event.trigger(this.cluster.getClusterer(),"mouseover",this.cluster)},t.prototype.onMouseOut=function(){google.maps.event.trigger(this.cluster.getClusterer(),"mouseout",this.cluster)},t.prototype.onAdd=function(){var e;this.div=document.createElement("div"),this.div.className=this.className,this.visible&&this.show(),(e=this.getPanes())===null||e===void 0||e.overlayMouseTarget.appendChild(this.div);var i=this.getMap();i!==null&&(this.boundsChangedListener=google.maps.event.addListener(i,"bounds_changed",this.onBoundsChanged),this.div.addEventListener("mousedown",this.onMouseDown),this.div.addEventListener("click",this.onClick),this.div.addEventListener("mouseover",this.onMouseOver),this.div.addEventListener("mouseout",this.onMouseOut))},t.prototype.onRemove=function(){this.div&&this.div.parentNode&&(this.hide(),this.boundsChangedListener!==null&&google.maps.event.removeListener(this.boundsChangedListener),this.div.removeEventListener("mousedown",this.onMouseDown),this.div.removeEventListener("click",this.onClick),this.div.removeEventListener("mouseover",this.onMouseOver),this.div.removeEventListener("mouseout",this.onMouseOut),this.div.parentNode.removeChild(this.div),this.timeOut!==null&&(window.clearTimeout(this.timeOut),this.timeOut=null),this.div=null)},t.prototype.draw=function(){if(this.visible&&this.div!==null&&this.center){var e=this.getPosFromLatLng(this.center);this.div.style.top=e!==null?"".concat(e.y,"px"):"0",this.div.style.left=e!==null?"".concat(e.x,"px"):"0"}},t.prototype.hide=function(){this.div&&(this.div.style.display="none"),this.visible=!1},t.prototype.show=function(){var e,i,n,r,o,a;if(this.div&&this.center){var s=this.sums===null||typeof this.sums.title>"u"||this.sums.title===""?this.cluster.getClusterer().getTitle():this.sums.title,l=this.backgroundPosition.split(" "),u=parseInt(((e=l[0])===null||e===void 0?void 0:e.replace(/^\s+|\s+$/g,""))||"0",10),c=parseInt(((i=l[1])===null||i===void 0?void 0:i.replace(/^\s+|\s+$/g,""))||"0",10),d=this.getPosFromLatLng(this.center);this.div.className=this.className,this.div.setAttribute("style","cursor: pointer; position: absolute; top: ".concat(d!==null?"".concat(d.y,"px"):"0","; left: ").concat(d!==null?"".concat(d.x,"px"):"0","; width: ").concat(this.width,"px; height: ").concat(this.height,"px; "));var f=document.createElement("img");f.alt=s,f.src=this.url,f.width=this.width,f.height=this.height,f.setAttribute("style","position: absolute; top: ".concat(c,"px; left: ").concat(u,"px")),this.cluster.getClusterer().enableRetinaIcons||(f.style.clip="rect(-".concat(c,"px, -").concat(u+this.width,"px, -").concat(c+this.height,", -").concat(u,")"));var h=document.createElement("div");h.setAttribute("style","position: absolute; top: ".concat(this.anchorText[0],"px; left: ").concat(this.anchorText[1],"px; color: ").concat(this.textColor,"; font-size: ").concat(this.textSize,"px; font-family: ").concat(this.fontFamily,"; font-weight: ").concat(this.fontWeight,"; fontStyle: ").concat(this.fontStyle,"; text-decoration: ").concat(this.textDecoration,"; text-align: center; width: ").concat(this.width,"px; line-height: ").concat(this.height,"px")),!((n=this.sums)===null||n===void 0)&&n.text&&(h.innerText="".concat((r=this.sums)===null||r===void 0?void 0:r.text)),!((o=this.sums)===null||o===void 0)&&o.html&&(h.innerHTML="".concat((a=this.sums)===null||a===void 0?void 0:a.html)),this.div.innerHTML="",this.div.appendChild(f),this.div.appendChild(h),this.div.title=s,this.div.style.display=""}this.visible=!0},t.prototype.useStyle=function(e){this.sums=e;var i=this.cluster.getClusterer().getStyles(),n=i[Math.min(i.length-1,Math.max(0,e.index-1))];n&&(this.url=n.url,this.height=n.height,this.width=n.width,n.className&&(this.className="".concat(this.clusterClassName," ").concat(n.className)),this.anchorText=n.anchorText||[0,0],this.anchorIcon=n.anchorIcon||[this.height/2,this.width/2],this.textColor=n.textColor||"black",this.textSize=n.textSize||11,this.textDecoration=n.textDecoration||"none",this.fontWeight=n.fontWeight||"bold",this.fontStyle=n.fontStyle||"normal",this.fontFamily=n.fontFamily||"Arial,sans-serif",this.backgroundPosition=n.backgroundPosition||"0 0")},t.prototype.setCenter=function(e){this.center=e},t.prototype.getPosFromLatLng=function(e){var i=this.getProjection().fromLatLngToDivPixel(e);return i!==null&&(i.x-=this.anchorIcon[1],i.y-=this.anchorIcon[0]),i},t})(),Mxt=(function(){function t(e){this.markerClusterer=e,this.map=this.markerClusterer.getMap(),this.gridSize=this.markerClusterer.getGridSize(),this.minClusterSize=this.markerClusterer.getMinimumClusterSize(),this.averageCenter=this.markerClusterer.getAverageCenter(),this.markers=[],this.center=void 0,this.bounds=null,this.clusterIcon=new Rxt(this,this.markerClusterer.getStyles()),this.getSize=this.getSize.bind(this),this.getMarkers=this.getMarkers.bind(this),this.getCenter=this.getCenter.bind(this),this.getMap=this.getMap.bind(this),this.getClusterer=this.getClusterer.bind(this),this.getBounds=this.getBounds.bind(this),this.remove=this.remove.bind(this),this.addMarker=this.addMarker.bind(this),this.isMarkerInClusterBounds=this.isMarkerInClusterBounds.bind(this),this.calculateBounds=this.calculateBounds.bind(this),this.updateIcon=this.updateIcon.bind(this),this.isMarkerAlreadyAdded=this.isMarkerAlreadyAdded.bind(this)}return t.prototype.getSize=function(){return this.markers.length},t.prototype.getMarkers=function(){return this.markers},t.prototype.getCenter=function(){return this.center},t.prototype.getMap=function(){return this.map},t.prototype.getClusterer=function(){return this.markerClusterer},t.prototype.getBounds=function(){for(var e=new google.maps.LatLngBounds(this.center,this.center),i=this.getMarkers(),n=0,r=i;n<r.length;n++){var o=r[n],a=o.getPosition();a&&e.extend(a)}return e},t.prototype.remove=function(){this.clusterIcon.setMap(null),this.markers=[],delete this.markers},t.prototype.addMarker=function(e){var i;if(this.isMarkerAlreadyAdded(e))return!1;if(this.center){if(this.averageCenter){var n=e.getPosition();if(n){var r=this.markers.length+1;this.center=new google.maps.LatLng((this.center.lat()*(r-1)+n.lat())/r,(this.center.lng()*(r-1)+n.lng())/r),this.calculateBounds()}}}else{var n=e.getPosition();n&&(this.center=n,this.calculateBounds())}e.isAdded=!0,this.markers.push(e);var o=this.markers.length,a=this.markerClusterer.getMaxZoom(),s=(i=this.map)===null||i===void 0?void 0:i.getZoom();if(a!==null&&typeof s<"u"&&s>a)e.getMap()!==this.map&&e.setMap(this.map);else if(o<this.minClusterSize)e.getMap()!==this.map&&e.setMap(this.map);else if(o===this.minClusterSize)for(var l=0,u=this.markers;l<u.length;l++){var c=u[l];c.setMap(null)}else e.setMap(null);return!0},t.prototype.isMarkerInClusterBounds=function(e){if(this.bounds!==null){var i=e.getPosition();if(i)return this.bounds.contains(i)}return!1},t.prototype.calculateBounds=function(){this.bounds=this.markerClusterer.getExtendedBounds(new google.maps.LatLngBounds(this.center,this.center))},t.prototype.updateIcon=function(){var e,i=this.markers.length,n=this.markerClusterer.getMaxZoom(),r=(e=this.map)===null||e===void 0?void 0:e.getZoom();if(n!==null&&typeof r<"u"&&r>n){this.clusterIcon.hide();return}if(i<this.minClusterSize){this.clusterIcon.hide();return}this.center&&this.clusterIcon.setCenter(this.center),this.clusterIcon.useStyle(this.markerClusterer.getCalculator()(this.markers,this.markerClusterer.getStyles().length)),this.clusterIcon.show()},t.prototype.isMarkerAlreadyAdded=function(e){if(this.markers.includes)return this.markers.includes(e);for(var i=0;i<this.markers.length;i++)if(e===this.markers[i])return!0;return!1},t})();function Lxt(t,e){var i=t.length,n=i.toString().length,r=Math.min(n,e);return{text:i.toString(),index:r,title:""}}var kxt=2e3,Ixt=500,Nxt="https://developers.google.com/maps/documentation/javascript/examples/markerclusterer/m",Fxt="png",Bxt=[53,56,66,78,90],jxt="cluster",DNe=(function(){function t(e,i,n){i===void 0&&(i=[]),n===void 0&&(n={}),this.getMinimumClusterSize=this.getMinimumClusterSize.bind(this),this.setMinimumClusterSize=this.setMinimumClusterSize.bind(this),this.getEnableRetinaIcons=this.getEnableRetinaIcons.bind(this),this.setEnableRetinaIcons=this.setEnableRetinaIcons.bind(this),this.addToClosestCluster=this.addToClosestCluster.bind(this),this.getImageExtension=this.getImageExtension.bind(this),this.setImageExtension=this.setImageExtension.bind(this),this.getExtendedBounds=this.getExtendedBounds.bind(this),this.getAverageCenter=this.getAverageCenter.bind(this),this.setAverageCenter=this.setAverageCenter.bind(this),this.getTotalClusters=this.getTotalClusters.bind(this),this.fitMapToMarkers=this.fitMapToMarkers.bind(this),this.getIgnoreHidden=this.getIgnoreHidden.bind(this),this.setIgnoreHidden=this.setIgnoreHidden.bind(this),this.getClusterClass=this.getClusterClass.bind(this),this.setClusterClass=this.setClusterClass.bind(this),this.getTotalMarkers=this.getTotalMarkers.bind(this),this.getZoomOnClick=this.getZoomOnClick.bind(this),this.setZoomOnClick=this.setZoomOnClick.bind(this),this.getBatchSizeIE=this.getBatchSizeIE.bind(this),this.setBatchSizeIE=this.setBatchSizeIE.bind(this),this.createClusters=this.createClusters.bind(this),this.onZoomChanged=this.onZoomChanged.bind(this),this.getImageSizes=this.getImageSizes.bind(this),this.setImageSizes=this.setImageSizes.bind(this),this.getCalculator=this.getCalculator.bind(this),this.setCalculator=this.setCalculator.bind(this),this.removeMarkers=this.removeMarkers.bind(this),this.resetViewport=this.resetViewport.bind(this),this.getImagePath=this.getImagePath.bind(this),this.setImagePath=this.setImagePath.bind(this),this.pushMarkerTo=this.pushMarkerTo.bind(this),this.removeMarker=this.removeMarker.bind(this),this.clearMarkers=this.clearMarkers.bind(this),this.setupStyles=this.setupStyles.bind(this),this.getGridSize=this.getGridSize.bind(this),this.setGridSize=this.setGridSize.bind(this),this.getClusters=this.getClusters.bind(this),this.getMaxZoom=this.getMaxZoom.bind(this),this.setMaxZoom=this.setMaxZoom.bind(this),this.getMarkers=this.getMarkers.bind(this),this.addMarkers=this.addMarkers.bind(this),this.getStyles=this.getStyles.bind(this),this.setStyles=this.setStyles.bind(this),this.addMarker=this.addMarker.bind(this),this.onRemove=this.onRemove.bind(this),this.getTitle=this.getTitle.bind(this),this.setTitle=this.setTitle.bind(this),this.repaint=this.repaint.bind(this),this.onIdle=this.onIdle.bind(this),this.redraw=this.redraw.bind(this),this.onAdd=this.onAdd.bind(this),this.draw=this.draw.bind(this),this.extend=this.extend.bind(this),this.extend(t,google.maps.OverlayView),this.markers=[],this.clusters=[],this.listeners=[],this.activeMap=null,this.ready=!1,this.gridSize=n.gridSize||60,this.minClusterSize=n.minimumClusterSize||2,this.maxZoom=n.maxZoom||null,this.styles=n.styles||[],this.title=n.title||"",this.zoomOnClick=!0,n.zoomOnClick!==void 0&&(this.zoomOnClick=n.zoomOnClick),this.averageCenter=!1,n.averageCenter!==void 0&&(this.averageCenter=n.averageCenter),this.ignoreHidden=!1,n.ignoreHidden!==void 0&&(this.ignoreHidden=n.ignoreHidden),this.enableRetinaIcons=!1,n.enableRetinaIcons!==void 0&&(this.enableRetinaIcons=n.enableRetinaIcons),this.imagePath=n.imagePath||Nxt,this.imageExtension=n.imageExtension||Fxt,this.imageSizes=n.imageSizes||Bxt,this.calculator=n.calculator||Lxt,this.batchSize=n.batchSize||kxt,this.batchSizeIE=n.batchSizeIE||Ixt,this.clusterClass=n.clusterClass||jxt,navigator.userAgent.toLowerCase().indexOf("msie")!==-1&&(this.batchSize=this.batchSizeIE),this.timerRefStatic=null,this.setupStyles(),this.addMarkers(i,!0),this.setMap(e)}return t.prototype.onZoomChanged=function(){var e,i;this.resetViewport(!1),(((e=this.getMap())===null||e===void 0?void 0:e.getZoom())===(this.get("minZoom")||0)||((i=this.getMap())===null||i===void 0?void 0:i.getZoom())===this.get("maxZoom"))&&google.maps.event.trigger(this,"idle")},t.prototype.onIdle=function(){this.redraw()},t.prototype.onAdd=function(){var e=this.getMap();this.activeMap=e,this.ready=!0,this.repaint(),e!==null&&(this.listeners=[google.maps.event.addListener(e,"zoom_changed",this.onZoomChanged),google.maps.event.addListener(e,"idle",this.onIdle)])},t.prototype.onRemove=function(){for(var e=0,i=this.markers;e<i.length;e++){var n=i[e];n.getMap()!==this.activeMap&&n.setMap(this.activeMap)}for(var r=0,o=this.clusters;r<o.length;r++){var a=o[r];a.remove()}this.clusters=[];for(var s=0,l=this.listeners;s<l.length;s++){var u=l[s];google.maps.event.removeListener(u)}this.listeners=[],this.activeMap=null,this.ready=!1},t.prototype.draw=function(){},t.prototype.getMap=function(){return null},t.prototype.getPanes=function(){return null},t.prototype.getProjection=function(){return{fromContainerPixelToLatLng:function(){return null},fromDivPixelToLatLng:function(){return null},fromLatLngToContainerPixel:function(){return null},fromLatLngToDivPixel:function(){return null},getVisibleRegion:function(){return null},getWorldWidth:function(){return 0}}},t.prototype.setMap=function(){},t.prototype.addListener=function(){return{remove:function(){}}},t.prototype.bindTo=function(){},t.prototype.get=function(){},t.prototype.notify=function(){},t.prototype.set=function(){},t.prototype.setValues=function(){},t.prototype.unbind=function(){},t.prototype.unbindAll=function(){},t.prototype.setupStyles=function(){if(!(this.styles.length>0))for(var e=0;e<this.imageSizes.length;e++)this.styles.push({url:"".concat(this.imagePath+(e+1),".").concat(this.imageExtension),height:this.imageSizes[e]||0,width:this.imageSizes[e]||0})},t.prototype.fitMapToMarkers=function(){for(var e=this.getMarkers(),i=new google.maps.LatLngBounds,n=0,r=e;n<r.length;n++){var o=r[n],a=o.getPosition();a&&i.extend(a)}var s=this.getMap();s!==null&&"fitBounds"in s&&s.fitBounds(i)},t.prototype.getGridSize=function(){return this.gridSize},t.prototype.setGridSize=function(e){this.gridSize=e},t.prototype.getMinimumClusterSize=function(){return this.minClusterSize},t.prototype.setMinimumClusterSize=function(e){this.minClusterSize=e},t.prototype.getMaxZoom=function(){return this.maxZoom},t.prototype.setMaxZoom=function(e){this.maxZoom=e},t.prototype.getStyles=function(){return this.styles},t.prototype.setStyles=function(e){this.styles=e},t.prototype.getTitle=function(){return this.title},t.prototype.setTitle=function(e){this.title=e},t.prototype.getZoomOnClick=function(){return this.zoomOnClick},t.prototype.setZoomOnClick=function(e){this.zoomOnClick=e},t.prototype.getAverageCenter=function(){return this.averageCenter},t.prototype.setAverageCenter=function(e){this.averageCenter=e},t.prototype.getIgnoreHidden=function(){return this.ignoreHidden},t.prototype.setIgnoreHidden=function(e){this.ignoreHidden=e},t.prototype.getEnableRetinaIcons=function(){return this.enableRetinaIcons},t.prototype.setEnableRetinaIcons=function(e){this.enableRetinaIcons=e},t.prototype.getImageExtension=function(){return this.imageExtension},t.prototype.setImageExtension=function(e){this.imageExtension=e},t.prototype.getImagePath=function(){return this.imagePath},t.prototype.setImagePath=function(e){this.imagePath=e},t.prototype.getImageSizes=function(){return this.imageSizes},t.prototype.setImageSizes=function(e){this.imageSizes=e},t.prototype.getCalculator=function(){return this.calculator},t.prototype.setCalculator=function(e){this.calculator=e},t.prototype.getBatchSizeIE=function(){return this.batchSizeIE},t.prototype.setBatchSizeIE=function(e){this.batchSizeIE=e},t.prototype.getClusterClass=function(){return this.clusterClass},t.prototype.setClusterClass=function(e){this.clusterClass=e},t.prototype.getMarkers=function(){return this.markers},t.prototype.getTotalMarkers=function(){return this.markers.length},t.prototype.getClusters=function(){return this.clusters},t.prototype.getTotalClusters=function(){return this.clusters.length},t.prototype.addMarker=function(e,i){this.pushMarkerTo(e),i||this.redraw()},t.prototype.addMarkers=function(e,i){for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=e[n];r&&this.pushMarkerTo(r)}i||this.redraw()},t.prototype.pushMarkerTo=function(e){var i=this;e.getDraggable()&&google.maps.event.addListener(e,"dragend",function(){i.ready&&(e.isAdded=!1,i.repaint())}),e.isAdded=!1,this.markers.push(e)},t.prototype.removeMarker_=function(e){var i=-1;if(this.markers.indexOf)i=this.markers.indexOf(e);else for(var n=0;n<this.markers.length;n++)if(e===this.markers[n]){i=n;break}return i===-1?!1:(e.setMap(null),this.markers.splice(i,1),!0)},t.prototype.removeMarker=function(e,i){var n=this.removeMarker_(e);return!i&&n&&this.repaint(),n},t.prototype.removeMarkers=function(e,i){for(var n=!1,r=0,o=e;r<o.length;r++){var a=o[r];n=n||this.removeMarker_(a)}return!i&&n&&this.repaint(),n},t.prototype.clearMarkers=function(){this.resetViewport(!0),this.markers=[]},t.prototype.repaint=function(){var e=this.clusters.slice();this.clusters=[],this.resetViewport(!1),this.redraw(),setTimeout(function(){for(var n=0,r=e;n<r.length;n++){var o=r[n];o.remove()}},0)},t.prototype.getExtendedBounds=function(e){var i=this.getProjection(),n=i.fromLatLngToDivPixel(new google.maps.LatLng(e.getNorthEast().lat(),e.getNorthEast().lng()));n!==null&&(n.x+=this.gridSize,n.y-=this.gridSize);var r=i.fromLatLngToDivPixel(new google.maps.LatLng(e.getSouthWest().lat(),e.getSouthWest().lng()));if(r!==null&&(r.x-=this.gridSize,r.y+=this.gridSize),n!==null){var o=i.fromDivPixelToLatLng(n);o!==null&&e.extend(o)}if(r!==null){var a=i.fromDivPixelToLatLng(r);a!==null&&e.extend(a)}return e},t.prototype.redraw=function(){this.createClusters(0)},t.prototype.resetViewport=function(e){for(var i=0,n=this.clusters;i<n.length;i++){var r=n[i];r.remove()}this.clusters=[];for(var o=0,a=this.markers;o<a.length;o++){var s=a[o];s.isAdded=!1,e&&s.setMap(null)}},t.prototype.distanceBetweenPoints=function(e,i){var n=6371,r=(i.lat()-e.lat())*Math.PI/180,o=(i.lng()-e.lng())*Math.PI/180,a=Math.sin(r/2)*Math.sin(r/2)+Math.cos(e.lat()*Math.PI/180)*Math.cos(i.lat()*Math.PI/180)*Math.sin(o/2)*Math.sin(o/2);return n*(2*Math.atan2(Math.sqrt(a),Math.sqrt(1-a)))},t.prototype.isMarkerInBounds=function(e,i){var n=e.getPosition();return n?i.contains(n):!1},t.prototype.addToClosestCluster=function(e){for(var i,n=4e4,r=null,o=0,a=this.clusters;o<a.length;o++){var s=a[o];i=s;var l=i.getCenter(),u=e.getPosition();if(l&&u){var c=this.distanceBetweenPoints(l,u);c<n&&(n=c,r=i)}}r&&r.isMarkerInClusterBounds(e)?r.addMarker(e):(i=new Mxt(this),i.addMarker(e),this.clusters.push(i))},t.prototype.createClusters=function(e){var i=this;if(this.ready){e===0&&(google.maps.event.trigger(this,"clusteringbegin",this),this.timerRefStatic!==null&&(window.clearTimeout(this.timerRefStatic),delete this.timerRefStatic));for(var n=this.getMap(),r=n!==null&&("getBounds"in n)?n.getBounds():null,o=(n==null?void 0:n.getZoom())||0,a=o>3?new google.maps.LatLngBounds(r==null?void 0:r.getSouthWest(),r==null?void 0:r.getNorthEast()):new google.maps.LatLngBounds(new google.maps.LatLng(85.02070771743472,-178.48388434375),new google.maps.LatLng(-85.08136444384544,178.00048865625)),s=this.getExtendedBounds(a),l=Math.min(e+this.batchSize,this.markers.length),u=e;u<l;u++){var c=this.markers[u];c&&!c.isAdded&&this.isMarkerInBounds(c,s)&&(!this.ignoreHidden||this.ignoreHidden&&c.getVisible())&&this.addToClosestCluster(c)}if(l<this.markers.length)this.timerRefStatic=window.setTimeout(function(){i.createClusters(l)},0);else{this.timerRefStatic=null,google.maps.event.trigger(this,"clusteringend",this);for(var d=0,f=this.clusters;d<f.length;d++){var h=f[d];h.updateIcon()}}}},t.prototype.extend=function(e,i){return(function(r){for(var o in r.prototype){var a=o;this.prototype[a]=r.prototype[a]}return this}).apply(e,[i])},t})();function cfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Vxt(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?cfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):cfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var yg={onClick:"click",onClusteringBegin:"clusteringbegin",onClusteringEnd:"clusteringend",onMouseOut:"mouseout",onMouseOver:"mouseover"},Qo={averageCenter(t,e){t.setAverageCenter(e)},batchSizeIE(t,e){t.setBatchSizeIE(e)},calculator(t,e){t.setCalculator(e)},clusterClass(t,e){t.setClusterClass(e)},enableRetinaIcons(t,e){t.setEnableRetinaIcons(e)},gridSize(t,e){t.setGridSize(e)},ignoreHidden(t,e){t.setIgnoreHidden(e)},imageExtension(t,e){t.setImageExtension(e)},imagePath(t,e){t.setImagePath(e)},imageSizes(t,e){t.setImageSizes(e)},maxZoom(t,e){t.setMaxZoom(e)},minimumClusterSize(t,e){t.setMinimumClusterSize(e)},styles(t,e){t.setStyles(e)},title(t,e){t.setTitle(e)},zoomOnClick(t,e){t.setZoomOnClick(e)}},Hxt={};function Uxt(t){var{children:e,options:i,averageCenter:n,batchSizeIE:r,calculator:o,clusterClass:a,enableRetinaIcons:s,gridSize:l,ignoreHidden:u,imageExtension:c,imagePath:d,imageSizes:f,maxZoom:h,minimumClusterSize:p,styles:g,title:v,zoomOnClick:y,onClick:m,onClusteringBegin:b,onClusteringEnd:S,onMouseOver:_,onMouseOut:C,onLoad:P,onUnmount:x}=t,[E,A]=J.useState(null),R=J.useContext(Yn),[M,D]=J.useState(null),[F,I]=J.useState(null),[V,z]=J.useState(null),[G,H]=J.useState(null),[U,k]=J.useState(null);return J.useEffect(()=>{E&&C&&(G!==null&&google.maps.event.removeListener(G),H(google.maps.event.addListener(E,yg.onMouseOut,C)))},[C]),J.useEffect(()=>{E&&_&&(U!==null&&google.maps.event.removeListener(U),k(google.maps.event.addListener(E,yg.onMouseOver,_)))},[_]),J.useEffect(()=>{E&&m&&(M!==null&&google.maps.event.removeListener(M),D(google.maps.event.addListener(E,yg.onClick,m)))},[m]),J.useEffect(()=>{E&&b&&(F!==null&&google.maps.event.removeListener(F),I(google.maps.event.addListener(E,yg.onClusteringBegin,b)))},[b]),J.useEffect(()=>{E&&S&&(V!==null&&google.maps.event.removeListener(V),I(google.maps.event.addListener(E,yg.onClusteringEnd,S)))},[S]),J.useEffect(()=>{typeof n<"u"&&E!==null&&Qo.averageCenter(E,n)},[E,n]),J.useEffect(()=>{typeof r<"u"&&E!==null&&Qo.batchSizeIE(E,r)},[E,r]),J.useEffect(()=>{typeof o<"u"&&E!==null&&Qo.calculator(E,o)},[E,o]),J.useEffect(()=>{typeof a<"u"&&E!==null&&Qo.clusterClass(E,a)},[E,a]),J.useEffect(()=>{typeof s<"u"&&E!==null&&Qo.enableRetinaIcons(E,s)},[E,s]),J.useEffect(()=>{typeof l<"u"&&E!==null&&Qo.gridSize(E,l)},[E,l]),J.useEffect(()=>{typeof u<"u"&&E!==null&&Qo.ignoreHidden(E,u)},[E,u]),J.useEffect(()=>{typeof c<"u"&&E!==null&&Qo.imageExtension(E,c)},[E,c]),J.useEffect(()=>{typeof d<"u"&&E!==null&&Qo.imagePath(E,d)},[E,d]),J.useEffect(()=>{typeof f<"u"&&E!==null&&Qo.imageSizes(E,f)},[E,f]),J.useEffect(()=>{typeof h<"u"&&E!==null&&Qo.maxZoom(E,h)},[E,h]),J.useEffect(()=>{typeof p<"u"&&E!==null&&Qo.minimumClusterSize(E,p)},[E,p]),J.useEffect(()=>{typeof g<"u"&&E!==null&&Qo.styles(E,g)},[E,g]),J.useEffect(()=>{typeof v<"u"&&E!==null&&Qo.title(E,v)},[E,v]),J.useEffect(()=>{typeof y<"u"&&E!==null&&Qo.zoomOnClick(E,y)},[E,y]),J.useEffect(()=>{if(R){var X=Vxt({},i||Hxt),W=new DNe(R,[],X);return n&&Qo.averageCenter(W,n),r&&Qo.batchSizeIE(W,r),o&&Qo.calculator(W,o),a&&Qo.clusterClass(W,a),s&&Qo.enableRetinaIcons(W,s),l&&Qo.gridSize(W,l),u&&Qo.ignoreHidden(W,u),c&&Qo.imageExtension(W,c),d&&Qo.imagePath(W,d),f&&Qo.imageSizes(W,f),h&&Qo.maxZoom(W,h),p&&Qo.minimumClusterSize(W,p),g&&Qo.styles(W,g),v&&Qo.title(W,v),y&&Qo.zoomOnClick(W,y),C&&H(google.maps.event.addListener(W,yg.onMouseOut,C)),_&&k(google.maps.event.addListener(W,yg.onMouseOver,_)),m&&D(google.maps.event.addListener(W,yg.onClick,m)),b&&I(google.maps.event.addListener(W,yg.onClusteringBegin,b)),S&&z(google.maps.event.addListener(W,yg.onClusteringEnd,S)),A(W),P&&P(W),()=>{G!==null&&google.maps.event.removeListener(G),U!==null&&google.maps.event.removeListener(U),M!==null&&google.maps.event.removeListener(M),F!==null&&google.maps.event.removeListener(F),V!==null&&google.maps.event.removeListener(V),x&&x(W)}}},[]),E!==null&&e(E)||null}J.memo(Uxt);class zxt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{markerClusterer:null}),br(this,"setClustererCallback",()=>{this.state.markerClusterer!==null&&this.props.onLoad&&this.props.onLoad(this.state.markerClusterer)})}componentDidMount(){if(this.context){var e=new DNe(this.context,[],this.props.options);this.registeredEvents=co({updaterMap:Qo,eventMap:yg,prevProps:{},nextProps:this.props,instance:e}),this.setState(()=>({markerClusterer:e}),this.setClustererCallback)}}componentDidUpdate(e){this.state.markerClusterer&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Qo,eventMap:yg,prevProps:e,nextProps:this.props,instance:this.state.markerClusterer}))}componentWillUnmount(){this.state.markerClusterer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.markerClusterer),So(this.registeredEvents),this.state.markerClusterer.setMap(null))}render(){return this.state.markerClusterer!==null?this.props.children(this.state.markerClusterer):null}}br(zxt,"contextType",Yn);function dfe(t){t.cancelBubble=!0,t.stopPropagation&&t.stopPropagation()}var RNe=(function(){function t(e){e===void 0&&(e={}),this.getCloseClickHandler=this.getCloseClickHandler.bind(this),this.closeClickHandler=this.closeClickHandler.bind(this),this.createInfoBoxDiv=this.createInfoBoxDiv.bind(this),this.addClickHandler=this.addClickHandler.bind(this),this.getCloseBoxImg=this.getCloseBoxImg.bind(this),this.getBoxWidths=this.getBoxWidths.bind(this),this.setBoxStyle=this.setBoxStyle.bind(this),this.setPosition=this.setPosition.bind(this),this.getPosition=this.getPosition.bind(this),this.setOptions=this.setOptions.bind(this),this.setContent=this.setContent.bind(this),this.setVisible=this.setVisible.bind(this),this.getContent=this.getContent.bind(this),this.getVisible=this.getVisible.bind(this),this.setZIndex=this.setZIndex.bind(this),this.getZIndex=this.getZIndex.bind(this),this.onRemove=this.onRemove.bind(this),this.panBox=this.panBox.bind(this),this.extend=this.extend.bind(this),this.close=this.close.bind(this),this.draw=this.draw.bind(this),this.show=this.show.bind(this),this.hide=this.hide.bind(this),this.open=this.open.bind(this),this.extend(t,google.maps.OverlayView),this.content=e.content||"",this.disableAutoPan=e.disableAutoPan||!1,this.maxWidth=e.maxWidth||0,this.pixelOffset=e.pixelOffset||new google.maps.Size(0,0),this.position=e.position||new google.maps.LatLng(0,0),this.zIndex=e.zIndex||null,this.boxClass=e.boxClass||"infoBox",this.boxStyle=e.boxStyle||{},this.closeBoxMargin=e.closeBoxMargin||"2px",this.closeBoxURL=e.closeBoxURL||"http://www.google.com/intl/en_us/mapfiles/close.gif",e.closeBoxURL===""&&(this.closeBoxURL=""),this.infoBoxClearance=e.infoBoxClearance||new google.maps.Size(1,1),typeof e.visible>"u"&&(typeof e.isHidden>"u"?e.visible=!0:e.visible=!e.isHidden),this.isHidden=!e.visible,this.alignBottom=e.alignBottom||!1,this.pane=e.pane||"floatPane",this.enableEventPropagation=e.enableEventPropagation||!1,this.div=null,this.closeListener=null,this.moveListener=null,this.mapListener=null,this.contextListener=null,this.eventListeners=null,this.fixedWidthSet=null}return t.prototype.createInfoBoxDiv=function(){var e=this,i=function(c){c.returnValue=!1,c.preventDefault&&c.preventDefault(),e.enableEventPropagation||dfe(c)};if(!this.div){this.div=document.createElement("div"),this.setBoxStyle(),typeof this.content=="string"?this.div.innerHTML=this.getCloseBoxImg()+this.content:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(this.content));var n=this.getPanes();if(n!==null&&n[this.pane].appendChild(this.div),this.addClickHandler(),this.div.style.width)this.fixedWidthSet=!0;else if(this.maxWidth!==0&&this.div.offsetWidth>this.maxWidth)this.div.style.width=this.maxWidth+"px",this.fixedWidthSet=!0;else{var r=this.getBoxWidths();this.div.style.width=this.div.offsetWidth-r.left-r.right+"px",this.fixedWidthSet=!1}if(this.panBox(this.disableAutoPan),!this.enableEventPropagation){this.eventListeners=[];for(var o=["mousedown","mouseover","mouseout","mouseup","click","dblclick","touchstart","touchend","touchmove"],a=0,s=o;a<s.length;a++){var l=s[a];this.eventListeners.push(google.maps.event.addListener(this.div,l,dfe))}this.eventListeners.push(google.maps.event.addListener(this.div,"mouseover",function(){e.div&&(e.div.style.cursor="default")}))}this.contextListener=google.maps.event.addListener(this.div,"contextmenu",i),google.maps.event.trigger(this,"domready")}},t.prototype.getCloseBoxImg=function(){var e="";return this.closeBoxURL!==""&&(e='<img alt=""',e+=' aria-hidden="true"',e+=" src='"+this.closeBoxURL+"'",e+=" align=right",e+=" style='",e+=" position: relative;",e+=" cursor: pointer;",e+=" margin: "+this.closeBoxMargin+";",e+="'>"),e},t.prototype.addClickHandler=function(){this.closeListener=this.div&&this.div.firstChild&&this.closeBoxURL!==""?google.maps.event.addListener(this.div.firstChild,"click",this.getCloseClickHandler()):null},t.prototype.closeClickHandler=function(e){e.cancelBubble=!0,e.stopPropagation&&e.stopPropagation(),google.maps.event.trigger(this,"closeclick"),this.close()},t.prototype.getCloseClickHandler=function(){return this.closeClickHandler},t.prototype.panBox=function(e){if(this.div&&!e){var i=this.getMap();if(i instanceof google.maps.Map){var n=0,r=0,o=i.getBounds();o&&!o.contains(this.position)&&i.setCenter(this.position);var a=i.getDiv(),s=a.offsetWidth,l=a.offsetHeight,u=this.pixelOffset.width,c=this.pixelOffset.height,d=this.div.offsetWidth,f=this.div.offsetHeight,h=this.infoBoxClearance.width,p=this.infoBoxClearance.height,g=this.getProjection(),v=g.fromLatLngToContainerPixel(this.position);v!==null&&(v.x<-u+h?n=v.x+u-h:v.x+d+u+h>s&&(n=v.x+d+u+h-s),this.alignBottom?v.y<-c+p+f?r=v.y+c-p-f:v.y+c+p>l&&(r=v.y+c+p-l):v.y<-c+p?r=v.y+c-p:v.y+f+c+p>l&&(r=v.y+f+c+p-l)),n===0&&r===0||i.panBy(n,r)}}},t.prototype.setBoxStyle=function(){if(this.div){this.div.className=this.boxClass,this.div.style.cssText="";var e=this.boxStyle;for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(this.div.style[i]=e[i]);if(this.div.style.webkitTransform="translateZ(0)",typeof this.div.style.opacity<"u"&&this.div.style.opacity!==""){var n=parseFloat(this.div.style.opacity||"");this.div.style.msFilter='"progid:DXImageTransform.Microsoft.Alpha(Opacity='+n*100+')"',this.div.style.filter="alpha(opacity="+n*100+")"}this.div.style.position="absolute",this.div.style.visibility="hidden",this.zIndex!==null&&(this.div.style.zIndex=this.zIndex+""),this.div.style.overflow||(this.div.style.overflow="auto")}},t.prototype.getBoxWidths=function(){var e={top:0,bottom:0,left:0,right:0};if(!this.div)return e;if(document.defaultView){var i=this.div.ownerDocument,n=i&&i.defaultView?i.defaultView.getComputedStyle(this.div,""):null;n&&(e.top=parseInt(n.borderTopWidth||"",10)||0,e.bottom=parseInt(n.borderBottomWidth||"",10)||0,e.left=parseInt(n.borderLeftWidth||"",10)||0,e.right=parseInt(n.borderRightWidth||"",10)||0)}else if(document.documentElement.currentStyle){var r=this.div.currentStyle;r&&(e.top=parseInt(r.borderTopWidth||"",10)||0,e.bottom=parseInt(r.borderBottomWidth||"",10)||0,e.left=parseInt(r.borderLeftWidth||"",10)||0,e.right=parseInt(r.borderRightWidth||"",10)||0)}return e},t.prototype.onRemove=function(){this.div&&this.div.parentNode&&(this.div.parentNode.removeChild(this.div),this.div=null)},t.prototype.draw=function(){if(this.createInfoBoxDiv(),this.div){var e=this.getProjection(),i=e.fromLatLngToDivPixel(this.position);i!==null&&(this.div.style.left=i.x+this.pixelOffset.width+"px",this.alignBottom?this.div.style.bottom=-(i.y+this.pixelOffset.height)+"px":this.div.style.top=i.y+this.pixelOffset.height+"px"),this.isHidden?this.div.style.visibility="hidden":this.div.style.visibility="visible"}},t.prototype.setOptions=function(e){e===void 0&&(e={}),typeof e.boxClass<"u"&&(this.boxClass=e.boxClass,this.setBoxStyle()),typeof e.boxStyle<"u"&&(this.boxStyle=e.boxStyle,this.setBoxStyle()),typeof e.content<"u"&&this.setContent(e.content),typeof e.disableAutoPan<"u"&&(this.disableAutoPan=e.disableAutoPan),typeof e.maxWidth<"u"&&(this.maxWidth=e.maxWidth),typeof e.pixelOffset<"u"&&(this.pixelOffset=e.pixelOffset),typeof e.alignBottom<"u"&&(this.alignBottom=e.alignBottom),typeof e.position<"u"&&this.setPosition(e.position),typeof e.zIndex<"u"&&this.setZIndex(e.zIndex),typeof e.closeBoxMargin<"u"&&(this.closeBoxMargin=e.closeBoxMargin),typeof e.closeBoxURL<"u"&&(this.closeBoxURL=e.closeBoxURL),typeof e.infoBoxClearance<"u"&&(this.infoBoxClearance=e.infoBoxClearance),typeof e.isHidden<"u"&&(this.isHidden=e.isHidden),typeof e.visible<"u"&&(this.isHidden=!e.visible),typeof e.enableEventPropagation<"u"&&(this.enableEventPropagation=e.enableEventPropagation),this.div&&this.draw()},t.prototype.setContent=function(e){this.content=e,this.div&&(this.closeListener&&(google.maps.event.removeListener(this.closeListener),this.closeListener=null),this.fixedWidthSet||(this.div.style.width=""),typeof e=="string"?this.div.innerHTML=this.getCloseBoxImg()+e:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(e)),this.fixedWidthSet||(this.div.style.width=this.div.offsetWidth+"px",typeof e=="string"?this.div.innerHTML=this.getCloseBoxImg()+e:(this.div.innerHTML=this.getCloseBoxImg(),this.div.appendChild(e))),this.addClickHandler()),google.maps.event.trigger(this,"content_changed")},t.prototype.setPosition=function(e){this.position=e,this.div&&this.draw(),google.maps.event.trigger(this,"position_changed")},t.prototype.setVisible=function(e){this.isHidden=!e,this.div&&(this.div.style.visibility=this.isHidden?"hidden":"visible")},t.prototype.setZIndex=function(e){this.zIndex=e,this.div&&(this.div.style.zIndex=e+""),google.maps.event.trigger(this,"zindex_changed")},t.prototype.getContent=function(){return this.content},t.prototype.getPosition=function(){return this.position},t.prototype.getZIndex=function(){return this.zIndex},t.prototype.getVisible=function(){var e=this.getMap();return typeof e>"u"||e===null?!1:!this.isHidden},t.prototype.show=function(){this.isHidden=!1,this.div&&(this.div.style.visibility="visible")},t.prototype.hide=function(){this.isHidden=!0,this.div&&(this.div.style.visibility="hidden")},t.prototype.open=function(e,i){var n=this;i&&(this.position=i.getPosition(),this.moveListener=google.maps.event.addListener(i,"position_changed",function(){var r=i.getPosition();n.setPosition(r)}),this.mapListener=google.maps.event.addListener(i,"map_changed",function(){n.setMap(i.map)})),this.setMap(e),this.div&&this.panBox()},t.prototype.close=function(){if(this.closeListener&&(google.maps.event.removeListener(this.closeListener),this.closeListener=null),this.eventListeners){for(var e=0,i=this.eventListeners;e<i.length;e++){var n=i[e];google.maps.event.removeListener(n)}this.eventListeners=null}this.moveListener&&(google.maps.event.removeListener(this.moveListener),this.moveListener=null),this.mapListener&&(google.maps.event.removeListener(this.mapListener),this.mapListener=null),this.contextListener&&(google.maps.event.removeListener(this.contextListener),this.contextListener=null),this.setMap(null)},t.prototype.extend=function(e,i){return(function(r){for(var o in r.prototype)Object.prototype.hasOwnProperty.call(this,o)||(this.prototype[o]=r.prototype[o]);return this}).apply(e,[i])},t})(),$xt=["position"],Wxt=["position"];function ffe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function zz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?ffe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):ffe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var hfe={onCloseClick:"closeclick",onContentChanged:"content_changed",onDomReady:"domready",onPositionChanged:"position_changed",onZindexChanged:"zindex_changed"},pfe={options(t,e){t.setOptions(e)},position(t,e){e instanceof google.maps.LatLng?t.setPosition(e):t.setPosition(new google.maps.LatLng(e.lat,e.lng))},visible(t,e){t.setVisible(e)},zIndex(t,e){t.setZIndex(e)}},Gxt={};function Yxt(t){var{children:e,anchor:i,options:n,position:r,zIndex:o,onCloseClick:a,onDomReady:s,onContentChanged:l,onPositionChanged:u,onZindexChanged:c,onLoad:d,onUnmount:f}=t,h=J.useContext(Yn),[p,g]=J.useState(null),[v,y]=J.useState(null),[m,b]=J.useState(null),[S,_]=J.useState(null),[C,P]=J.useState(null),[x,E]=J.useState(null),A=J.useRef(null);return J.useEffect(()=>{h&&p!==null&&(p.close(),i?p.open(h,i):p.getPosition()&&p.open(h))},[h,p,i]),J.useEffect(()=>{n&&p!==null&&p.setOptions(n)},[p,n]),J.useEffect(()=>{if(r&&p!==null){var R=r instanceof google.maps.LatLng?r:new google.maps.LatLng(r.lat,r.lng);p.setPosition(R)}},[r]),J.useEffect(()=>{typeof o=="number"&&p!==null&&p.setZIndex(o)},[o]),J.useEffect(()=>{p&&a&&(v!==null&&google.maps.event.removeListener(v),y(google.maps.event.addListener(p,"closeclick",a)))},[a]),J.useEffect(()=>{p&&s&&(m!==null&&google.maps.event.removeListener(m),b(google.maps.event.addListener(p,"domready",s)))},[s]),J.useEffect(()=>{p&&l&&(S!==null&&google.maps.event.removeListener(S),_(google.maps.event.addListener(p,"content_changed",l)))},[l]),J.useEffect(()=>{p&&u&&(C!==null&&google.maps.event.removeListener(C),P(google.maps.event.addListener(p,"position_changed",u)))},[u]),J.useEffect(()=>{p&&c&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(p,"zindex_changed",c)))},[c]),J.useEffect(()=>{if(h){var R=n||Gxt,{position:M}=R,D=dre(R,$xt),F;M&&!(M instanceof google.maps.LatLng)&&(F=new google.maps.LatLng(M.lat,M.lng));var I=new RNe(zz(zz({},D),F?{position:F}:{}));A.current=document.createElement("div"),g(I),a&&y(google.maps.event.addListener(I,"closeclick",a)),s&&b(google.maps.event.addListener(I,"domready",s)),l&&_(google.maps.event.addListener(I,"content_changed",l)),u&&P(google.maps.event.addListener(I,"position_changed",u)),c&&E(google.maps.event.addListener(I,"zindex_changed",c)),I.setContent(A.current),i?I.open(h,i):I.getPosition()?I.open(h):ec(!1,"You must provide either an anchor or a position prop for <InfoBox>."),d&&d(I)}return()=>{p!==null&&(v&&google.maps.event.removeListener(v),S&&google.maps.event.removeListener(S),m&&google.maps.event.removeListener(m),C&&google.maps.event.removeListener(C),x&&google.maps.event.removeListener(x),f&&f(p),p.close())}},[]),A.current?zf.createPortal(J.Children.only(e),A.current):null}J.memo(Yxt);class qxt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"containerElement",null),br(this,"state",{infoBox:null}),br(this,"open",(e,i)=>{i?this.context!==null&&e.open(this.context,i):e.getPosition()?this.context!==null&&e.open(this.context):ec(!1,"You must provide either an anchor or a position prop for <InfoBox>.")}),br(this,"setInfoBoxCallback",()=>{this.state.infoBox!==null&&this.containerElement!==null&&(this.state.infoBox.setContent(this.containerElement),this.open(this.state.infoBox,this.props.anchor),this.props.onLoad&&this.props.onLoad(this.state.infoBox))})}componentDidMount(){var e=this.props.options||{},{position:i}=e,n=dre(e,Wxt),r;i&&!(i instanceof google.maps.LatLng)&&(r=new google.maps.LatLng(i.lat,i.lng));var o=new RNe(zz(zz({},n),r?{position:r}:{}));this.containerElement=document.createElement("div"),this.registeredEvents=co({updaterMap:pfe,eventMap:hfe,prevProps:{},nextProps:this.props,instance:o}),this.setState({infoBox:o},this.setInfoBoxCallback)}componentDidUpdate(e){var{infoBox:i}=this.state;i!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:pfe,eventMap:hfe,prevProps:e,nextProps:this.props,instance:i}))}componentWillUnmount(){var{onUnmount:e}=this.props,{infoBox:i}=this.state;i!==null&&(e&&e(i),So(this.registeredEvents),i.close())}render(){return this.containerElement?zf.createPortal(J.Children.only(this.props.children),this.containerElement):null}}br(qxt,"contextType",Yn);var fq,gfe;function Xxt(){return gfe||(gfe=1,fq=function t(e,i){if(e===i)return!0;if(e&&i&&typeof e=="object"&&typeof i=="object"){if(e.constructor!==i.constructor)return!1;var n,r,o;if(Array.isArray(e)){if(n=e.length,n!=i.length)return!1;for(r=n;r--!==0;)if(!t(e[r],i[r]))return!1;return!0}if(e.constructor===RegExp)return e.source===i.source&&e.flags===i.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===i.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===i.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(i).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(i,o[r]))return!1;for(r=n;r--!==0;){var a=o[r];if(!t(e[a],i[a]))return!1}return!0}return e!==e&&i!==i}),fq}var Kxt=Xxt(),vfe=TNe(Kxt),yfe=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],hq=1,sN=8;class fre{static from(e){if(!(e instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");var[i,n]=new Uint8Array(e,0,2);if(i!==219)throw new Error("Data does not appear to be in a KDBush format.");var r=n>>4;if(r!==hq)throw new Error("Got v".concat(r," data when expected v").concat(hq,"."));var o=yfe[n&15];if(!o)throw new Error("Unrecognized array type.");var[a]=new Uint16Array(e,2,1),[s]=new Uint32Array(e,4,1);return new fre(s,a,o,e)}constructor(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:64,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Float64Array,r=arguments.length>3?arguments[3]:void 0;if(isNaN(e)||e<0)throw new Error("Unpexpected numItems value: ".concat(e,"."));this.numItems=+e,this.nodeSize=Math.min(Math.max(+i,2),65535),this.ArrayType=n,this.IndexArrayType=e<65536?Uint16Array:Uint32Array;var o=yfe.indexOf(this.ArrayType),a=e*2*this.ArrayType.BYTES_PER_ELEMENT,s=e*this.IndexArrayType.BYTES_PER_ELEMENT,l=(8-s%8)%8;if(o<0)throw new Error("Unexpected typed array class: ".concat(n,"."));r&&r instanceof ArrayBuffer?(this.data=r,this.ids=new this.IndexArrayType(this.data,sN,e),this.coords=new this.ArrayType(this.data,sN+s+l,e*2),this._pos=e*2,this._finished=!0):(this.data=new ArrayBuffer(sN+a+s+l),this.ids=new this.IndexArrayType(this.data,sN,e),this.coords=new this.ArrayType(this.data,sN+s+l,e*2),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,(hq<<4)+o]),new Uint16Array(this.data,2,1)[0]=i,new Uint32Array(this.data,4,1)[0]=e)}add(e,i){var n=this._pos>>1;return this.ids[n]=n,this.coords[this._pos++]=e,this.coords[this._pos++]=i,n}finish(){var e=this._pos>>1;if(e!==this.numItems)throw new Error("Added ".concat(e," items when expected ").concat(this.numItems,"."));return sJ(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(e,i,n,r){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var{ids:o,coords:a,nodeSize:s}=this,l=[0,o.length-1,0],u=[];l.length;){var c=l.pop()||0,d=l.pop()||0,f=l.pop()||0;if(d-f<=s){for(var h=f;h<=d;h++){var p=a[2*h],g=a[2*h+1];p>=e&&p<=n&&g>=i&&g<=r&&u.push(o[h])}continue}var v=f+d>>1,y=a[2*v],m=a[2*v+1];y>=e&&y<=n&&m>=i&&m<=r&&u.push(o[v]),(c===0?e<=y:i<=m)&&(l.push(f),l.push(v-1),l.push(1-c)),(c===0?n>=y:r>=m)&&(l.push(v+1),l.push(d),l.push(1-c))}return u}within(e,i,n){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");for(var{ids:r,coords:o,nodeSize:a}=this,s=[0,r.length-1,0],l=[],u=n*n;s.length;){var c=s.pop()||0,d=s.pop()||0,f=s.pop()||0;if(d-f<=a){for(var h=f;h<=d;h++)mfe(o[2*h],o[2*h+1],e,i)<=u&&l.push(r[h]);continue}var p=f+d>>1,g=o[2*p],v=o[2*p+1];mfe(g,v,e,i)<=u&&l.push(r[p]),(c===0?e-n<=g:i-n<=v)&&(s.push(f),s.push(p-1),s.push(1-c)),(c===0?e+n>=g:i+n>=v)&&(s.push(p+1),s.push(d),s.push(1-c))}return l}}function sJ(t,e,i,n,r,o){if(!(r-n<=i)){var a=n+r>>1;MNe(t,e,a,n,r,o),sJ(t,e,i,n,a-1,1-o),sJ(t,e,i,a+1,r,1-o)}}function MNe(t,e,i,n,r,o){for(;r>n;){if(r-n>600){var a=r-n+1,s=i-n+1,l=Math.log(a),u=.5*Math.exp(2*l/3),c=.5*Math.sqrt(l*u*(a-u)/a)*(s-a/2<0?-1:1),d=Math.max(n,Math.floor(i-s*u/a+c)),f=Math.min(r,Math.floor(i+(a-s)*u/a+c));MNe(t,e,i,d,f,o)}var h=e[2*i+o],p=n,g=r;for(lN(t,e,n,i),e[2*r+o]>h&&lN(t,e,n,r);p<g;){for(lN(t,e,p,g),p++,g--;e[2*p+o]<h;)p++;for(;e[2*g+o]>h;)g--}e[2*n+o]===h?lN(t,e,n,g):(g++,lN(t,e,g,r)),g<=i&&(n=g+1),i<=g&&(r=g-1)}}function lN(t,e,i,n){pq(t,i,n),pq(e,2*i,2*n),pq(e,2*i+1,2*n+1)}function pq(t,e,i){var n=t[e];t[e]=t[i],t[i]=n}function mfe(t,e,i,n){var r=t-i,o=e-n;return r*r+o*o}var Zxt={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:t=>t},bfe=Math.fround||(t=>e=>(t[0]=+e,t[0]))(new Float32Array(1)),PT=2,W_=3,gq=4,H_=5,LNe=6;class Jxt{constructor(e){this.options=Object.assign(Object.create(Zxt),e),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(e){var{log:i,minZoom:n,maxZoom:r}=this.options;i&&console.time("total time");var o="prepare ".concat(e.length," points");i&&console.time(o),this.points=e;for(var a=[],s=0;s<e.length;s++){var l=e[s];if(l.geometry){var[u,c]=l.geometry.coordinates,d=bfe(w4(u)),f=bfe(A4(c));a.push(d,f,1/0,s,-1,1),this.options.reduce&&a.push(0)}}var h=this.trees[r+1]=this._createTree(a);i&&console.timeEnd(o);for(var p=r;p>=n;p--){var g=+Date.now();h=this.trees[p]=this._createTree(this._cluster(h,p)),i&&console.log("z%d: %d clusters in %dms",p,h.numItems,+Date.now()-g)}return i&&console.timeEnd("total time"),this}getClusters(e,i){var n=((e[0]+180)%360+360)%360-180,r=Math.max(-90,Math.min(90,e[1])),o=e[2]===180?180:((e[2]+180)%360+360)%360-180,a=Math.max(-90,Math.min(90,e[3]));if(e[2]-e[0]>=360)n=-180,o=180;else if(n>o){var s=this.getClusters([n,r,180,a],i),l=this.getClusters([-180,r,o,a],i);return s.concat(l)}var u=this.trees[this._limitZoom(i)],c=u.range(w4(n),A4(a),w4(o),A4(r)),d=u.data,f=[];for(var h of c){var p=this.stride*h;f.push(d[p+H_]>1?Sfe(d,p,this.clusterProps):this.points[d[p+W_]])}return f}getChildren(e){var i=this._getOriginId(e),n=this._getOriginZoom(e),r="No cluster with the specified id.",o=this.trees[n];if(!o)throw new Error(r);var a=o.data;if(i*this.stride>=a.length)throw new Error(r);var s=this.options.radius/(this.options.extent*Math.pow(2,n-1)),l=a[i*this.stride],u=a[i*this.stride+1],c=o.within(l,u,s),d=[];for(var f of c){var h=f*this.stride;a[h+gq]===e&&d.push(a[h+H_]>1?Sfe(a,h,this.clusterProps):this.points[a[h+W_]])}if(d.length===0)throw new Error(r);return d}getLeaves(e,i,n){i=i||10,n=n||0;var r=[];return this._appendLeaves(r,e,i,n,0),r}getTile(e,i,n){var r=this.trees[this._limitZoom(e)],o=Math.pow(2,e),{extent:a,radius:s}=this.options,l=s/a,u=(n-l)/o,c=(n+1+l)/o,d={features:[]};return this._addTileFeatures(r.range((i-l)/o,u,(i+1+l)/o,c),r.data,i,n,o,d),i===0&&this._addTileFeatures(r.range(1-l/o,u,1,c),r.data,o,n,o,d),i===o-1&&this._addTileFeatures(r.range(0,u,l/o,c),r.data,-1,n,o,d),d.features.length?d:null}getClusterExpansionZoom(e){for(var i=this._getOriginZoom(e)-1;i<=this.options.maxZoom;){var n=this.getChildren(e);if(i++,n.length!==1)break;e=n[0].properties.cluster_id}return i}_appendLeaves(e,i,n,r,o){var a=this.getChildren(i);for(var s of a){var l=s.properties;if(l&&l.cluster?o+l.point_count<=r?o+=l.point_count:o=this._appendLeaves(e,l.cluster_id,n,r,o):o<r?o++:e.push(s),e.length===n)break}return o}_createTree(e){for(var i=new fre(e.length/this.stride|0,this.options.nodeSize,Float32Array),n=0;n<e.length;n+=this.stride)i.add(e[n],e[n+1]);return i.finish(),i.data=e,i}_addTileFeatures(e,i,n,r,o,a){for(var s of e){var l=s*this.stride,u=i[l+H_]>1,c=void 0,d=void 0,f=void 0;if(u)c=kNe(i,l,this.clusterProps),d=i[l],f=i[l+1];else{var h=this.points[i[l+W_]];c=h.properties;var[p,g]=h.geometry.coordinates;d=w4(p),f=A4(g)}var v={type:1,geometry:[[Math.round(this.options.extent*(d*o-n)),Math.round(this.options.extent*(f*o-r))]],tags:c},y=void 0;u||this.options.generateId?y=i[l+W_]:y=this.points[i[l+W_]].id,y!==void 0&&(v.id=y),a.features.push(v)}}_limitZoom(e){return Math.max(this.options.minZoom,Math.min(Math.floor(+e),this.options.maxZoom+1))}_cluster(e,i){for(var{radius:n,extent:r,reduce:o,minPoints:a}=this.options,s=n/(r*Math.pow(2,i)),l=e.data,u=[],c=this.stride,d=0;d<l.length;d+=c)if(!(l[d+PT]<=i)){l[d+PT]=i;var f=l[d],h=l[d+1],p=e.within(l[d],l[d+1],s),g=l[d+H_],v=g;for(var y of p){var m=y*c;l[m+PT]>i&&(v+=l[m+H_])}if(v>g&&v>=a){var b=f*g,S=h*g,_=void 0,C=-1,P=((d/c|0)<<5)+(i+1)+this.points.length;for(var x of p){var E=x*c;if(!(l[E+PT]<=i)){l[E+PT]=i;var A=l[E+H_];b+=l[E]*A,S+=l[E+1]*A,l[E+gq]=P,o&&(_||(_=this._map(l,d,!0),C=this.clusterProps.length,this.clusterProps.push(_)),o(_,this._map(l,E)))}}l[d+gq]=P,u.push(b/v,S/v,1/0,P,-1,v),o&&u.push(C)}else{for(var R=0;R<c;R++)u.push(l[d+R]);if(v>1)for(var M of p){var D=M*c;if(!(l[D+PT]<=i)){l[D+PT]=i;for(var F=0;F<c;F++)u.push(l[D+F])}}}}return u}_getOriginId(e){return e-this.points.length>>5}_getOriginZoom(e){return(e-this.points.length)%32}_map(e,i,n){if(e[i+H_]>1){var r=this.clusterProps[e[i+LNe]];return n?Object.assign({},r):r}var o=this.points[e[i+W_]].properties,a=this.options.map(o);return n&&a===o?Object.assign({},a):a}}function Sfe(t,e,i){return{type:"Feature",id:t[e+W_],properties:kNe(t,e,i),geometry:{type:"Point",coordinates:[Qxt(t[e]),eEt(t[e+1])]}}}function kNe(t,e,i){var n=t[e+H_],r=n>=1e4?"".concat(Math.round(n/1e3),"k"):n>=1e3?"".concat(Math.round(n/100)/10,"k"):n,o=t[e+LNe],a=o===-1?{}:Object.assign({},i[o]);return Object.assign(a,{cluster:!0,cluster_id:t[e+W_],point_count:n,point_count_abbreviated:r})}function w4(t){return t/360+.5}function A4(t){var e=Math.sin(t*Math.PI/180),i=.5-.25*Math.log((1+e)/(1-e))/Math.PI;return i<0?0:i>1?1:i}function Qxt(t){return(t-.5)*360}function eEt(t){var e=(180-t*360)*Math.PI/180;return 360*Math.atan(Math.exp(e))/Math.PI-90}/*! *****************************************************************************
Copyright (c) Microsoft Corporation.

Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted.

THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
***************************************************************************** */function tEt(t,e){var i={};for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0&&(i[n]=t[n]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var r=0,n=Object.getOwnPropertySymbols(t);r<n.length;r++)e.indexOf(n[r])<0&&Object.prototype.propertyIsEnumerable.call(t,n[r])&&(i[n[r]]=t[n[r]]);return i}class Pp{static isAdvancedMarkerAvailable(e){return google.maps.marker&&e.getMapCapabilities().isAdvancedMarkersAvailable===!0}static isAdvancedMarker(e){return google.maps.marker&&e instanceof google.maps.marker.AdvancedMarkerElement}static setMap(e,i){this.isAdvancedMarker(e)?e.map=i:e.setMap(i)}static getPosition(e){if(this.isAdvancedMarker(e)){if(e.position){if(e.position instanceof google.maps.LatLng)return e.position;if(e.position.lat&&e.position.lng)return new google.maps.LatLng(e.position.lat,e.position.lng)}return new google.maps.LatLng(null)}return e.getPosition()}static getVisible(e){return this.isAdvancedMarker(e)?!0:e.getVisible()}}class lJ{constructor(e){var{markers:i,position:n}=e;this.markers=i,n&&(n instanceof google.maps.LatLng?this._position=n:this._position=new google.maps.LatLng(n))}get bounds(){if(!(this.markers.length===0&&!this._position)){var e=new google.maps.LatLngBounds(this._position,this._position);for(var i of this.markers)e.extend(Pp.getPosition(i));return e}}get position(){return this._position||this.bounds.getCenter()}get count(){return this.markers.filter(e=>Pp.getVisible(e)).length}push(e){this.markers.push(e)}delete(){this.marker&&(Pp.setMap(this.marker,null),this.marker=void 0),this.markers.length=0}}class rEt{constructor(e){var{maxZoom:i=16}=e;this.maxZoom=i}noop(e){var{markers:i}=e;return iEt(i)}}var iEt=t=>{var e=t.map(i=>new lJ({position:Pp.getPosition(i),markers:[i]}));return e};class nEt extends rEt{constructor(e){var{maxZoom:i,radius:n=60}=e,r=tEt(e,["maxZoom","radius"]);super({maxZoom:i}),this.state={zoom:-1},this.superCluster=new Jxt(Object.assign({maxZoom:this.maxZoom,radius:n},r))}calculate(e){var i=!1,n={zoom:e.map.getZoom()};if(!vfe(e.markers,this.markers)){i=!0,this.markers=[...e.markers];var r=this.markers.map(o=>{var a=Pp.getPosition(o),s=[a.lng(),a.lat()];return{type:"Feature",geometry:{type:"Point",coordinates:s},properties:{marker:o}}});this.superCluster.load(r)}return i||(this.state.zoom<=this.maxZoom||n.zoom<=this.maxZoom)&&(i=!vfe(this.state,n)),this.state=n,i&&(this.clusters=this.cluster(e)),{clusters:this.clusters,changed:i}}cluster(e){var{map:i}=e;return this.superCluster.getClusters([-180,-90,180,90],Math.round(i.getZoom())).map(n=>this.transformCluster(n))}transformCluster(e){var{geometry:{coordinates:[i,n]},properties:r}=e;if(r.cluster)return new lJ({markers:this.superCluster.getLeaves(r.cluster_id,1/0).map(a=>a.properties.marker),position:{lat:n,lng:i}});var o=r.marker;return new lJ({markers:[o],position:Pp.getPosition(o)})}}class oEt{constructor(e,i){this.markers={sum:e.length};var n=i.map(o=>o.count),r=n.reduce((o,a)=>o+a,0);this.clusters={count:i.length,markers:{mean:r/i.length,sum:r,min:Math.min(...n),max:Math.max(...n)}}}}class aEt{render(e,i,n){var{count:r,position:o}=e,a=r>Math.max(10,i.clusters.markers.mean)?"#ff0000":"#0000ff",s='<svg fill="'.concat(a,`" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 240 240" width="50" height="50">
<circle cx="120" cy="120" opacity=".6" r="70" />
<circle cx="120" cy="120" opacity=".3" r="90" />
<circle cx="120" cy="120" opacity=".2" r="110" />
<text x="50%" y="50%" style="fill:#fff" text-anchor="middle" font-size="50" dominant-baseline="middle" font-family="roboto,arial,sans-serif">`).concat(r,`</text>
</svg>`),l="Cluster of ".concat(r," markers"),u=Number(google.maps.Marker.MAX_ZINDEX)+r;if(Pp.isAdvancedMarkerAvailable(n)){var c=new DOMParser,d=c.parseFromString(s,"image/svg+xml").documentElement;d.setAttribute("transform","translate(0 25)");var f={map:n,position:o,zIndex:u,title:l,content:d};return new google.maps.marker.AdvancedMarkerElement(f)}var h={position:o,zIndex:u,title:l,icon:{url:"data:image/svg+xml;base64,".concat(btoa(s)),anchor:new google.maps.Point(25,25)}};return new google.maps.Marker(h)}}function sEt(t,e){for(var i in e.prototype)t.prototype[i]=e.prototype[i]}class hre{constructor(){sEt(hre,google.maps.OverlayView)}}var kj;(function(t){t.CLUSTERING_BEGIN="clusteringbegin",t.CLUSTERING_END="clusteringend",t.CLUSTER_CLICK="click"})(kj||(kj={}));var lEt=(t,e,i)=>{i.fitBounds(e.bounds)};class uEt extends hre{constructor(e){var{map:i,markers:n=[],algorithmOptions:r={},algorithm:o=new nEt(r),renderer:a=new aEt,onClusterClick:s=lEt}=e;super(),this.markers=[...n],this.clusters=[],this.algorithm=o,this.renderer=a,this.onClusterClick=s,i&&this.setMap(i)}addMarker(e,i){this.markers.includes(e)||(this.markers.push(e),i||this.render())}addMarkers(e,i){e.forEach(n=>{this.addMarker(n,!0)}),i||this.render()}removeMarker(e,i){var n=this.markers.indexOf(e);return n===-1?!1:(Pp.setMap(e,null),this.markers.splice(n,1),i||this.render(),!0)}removeMarkers(e,i){var n=!1;return e.forEach(r=>{n=this.removeMarker(r,!0)||n}),n&&!i&&this.render(),n}clearMarkers(e){this.markers.length=0,e||this.render()}render(){var e=this.getMap();if(e instanceof google.maps.Map&&e.getProjection()){google.maps.event.trigger(this,kj.CLUSTERING_BEGIN,this);var{clusters:i,changed:n}=this.algorithm.calculate({markers:this.markers,map:e,mapCanvasProjection:this.getProjection()});if(n||n==null){var r=new Set;for(var o of i)o.markers.length==1&&r.add(o.markers[0]);var a=[];for(var s of this.clusters)s.marker!=null&&(s.markers.length==1?r.has(s.marker)||Pp.setMap(s.marker,null):a.push(s.marker));this.clusters=i,this.renderClusters(),requestAnimationFrame(()=>a.forEach(l=>Pp.setMap(l,null)))}google.maps.event.trigger(this,kj.CLUSTERING_END,this)}}onAdd(){this.idleListener=this.getMap().addListener("idle",this.render.bind(this)),this.render()}onRemove(){google.maps.event.removeListener(this.idleListener),this.reset()}reset(){this.markers.forEach(e=>Pp.setMap(e,null)),this.clusters.forEach(e=>e.delete()),this.clusters=[]}renderClusters(){var e=new oEt(this.markers,this.clusters),i=this.getMap();this.clusters.forEach(n=>{n.markers.length===1?n.marker=n.markers[0]:(n.marker=this.renderer.render(n,e,i),n.markers.forEach(r=>Pp.setMap(r,null)),this.onClusterClick&&n.marker.addListener("click",r=>{google.maps.event.trigger(this,kj.CLUSTER_CLICK,n),this.onClusterClick(r,n,i)})),Pp.setMap(n.marker,i)})}}function _fe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Pfe(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?_fe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):_fe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}function cEt(t){var e=rxt(),[i,n]=J.useState(null);return J.useEffect(()=>{if(e&&i===null){var r=new uEt(Pfe(Pfe({},t),{},{map:e}));n(r)}},[e]),i}function dEt(t){var{children:e,options:i}=t,n=cEt(i);return n!==null?e(n):null}J.memo(dEt);var Cfe={onCloseClick:"closeclick",onContentChanged:"content_changed",onDomReady:"domready",onPositionChanged:"position_changed",onZindexChanged:"zindex_changed"},Tfe={options(t,e){t.setOptions(e)},position(t,e){t.setPosition(e)},zIndex(t,e){t.setZIndex(e)}};function fEt(t){var{children:e,anchor:i,options:n,position:r,zIndex:o,onCloseClick:a,onDomReady:s,onContentChanged:l,onPositionChanged:u,onZindexChanged:c,onLoad:d,onUnmount:f}=t,h=J.useContext(Yn),[p,g]=J.useState(null),[v,y]=J.useState(null),[m,b]=J.useState(null),[S,_]=J.useState(null),[C,P]=J.useState(null),[x,E]=J.useState(null),A=J.useRef(null);return J.useEffect(()=>{p!==null&&(p.close(),i?p.open(h,i):p.getPosition()&&p.open(h))},[h,p,i]),J.useEffect(()=>{n&&p!==null&&p.setOptions(n)},[p,n]),J.useEffect(()=>{r&&p!==null&&p.setPosition(r)},[r]),J.useEffect(()=>{typeof o=="number"&&p!==null&&p.setZIndex(o)},[o]),J.useEffect(()=>{p&&a&&(v!==null&&google.maps.event.removeListener(v),y(google.maps.event.addListener(p,"closeclick",a)))},[a]),J.useEffect(()=>{p&&s&&(m!==null&&google.maps.event.removeListener(m),b(google.maps.event.addListener(p,"domready",s)))},[s]),J.useEffect(()=>{p&&l&&(S!==null&&google.maps.event.removeListener(S),_(google.maps.event.addListener(p,"content_changed",l)))},[l]),J.useEffect(()=>{p&&u&&(C!==null&&google.maps.event.removeListener(C),P(google.maps.event.addListener(p,"position_changed",u)))},[u]),J.useEffect(()=>{p&&c&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(p,"zindex_changed",c)))},[c]),J.useEffect(()=>{var R=new google.maps.InfoWindow(n);return g(R),A.current=document.createElement("div"),a&&y(google.maps.event.addListener(R,"closeclick",a)),s&&b(google.maps.event.addListener(R,"domready",s)),l&&_(google.maps.event.addListener(R,"content_changed",l)),u&&P(google.maps.event.addListener(R,"position_changed",u)),c&&E(google.maps.event.addListener(R,"zindex_changed",c)),R.setContent(A.current),r&&R.setPosition(r),o&&R.setZIndex(o),i?R.open(h,i):R.getPosition()?R.open(h):ec(!1,"You must provide either an anchor (typically render it inside a <Marker>) or a position props for <InfoWindow>."),d&&d(R),()=>{v&&google.maps.event.removeListener(v),S&&google.maps.event.removeListener(S),m&&google.maps.event.removeListener(m),C&&google.maps.event.removeListener(C),x&&google.maps.event.removeListener(x),f&&f(R),R.close()}},[]),A.current?zf.createPortal(J.Children.only(e),A.current):null}J.memo(fEt);class hEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"containerElement",null),br(this,"state",{infoWindow:null}),br(this,"open",(e,i)=>{i?e.open(this.context,i):e.getPosition()?e.open(this.context):ec(!1,"You must provide either an anchor (typically render it inside a <Marker>) or a position props for <InfoWindow>.")}),br(this,"setInfoWindowCallback",()=>{this.state.infoWindow!==null&&this.containerElement!==null&&(this.state.infoWindow.setContent(this.containerElement),this.open(this.state.infoWindow,this.props.anchor),this.props.onLoad&&this.props.onLoad(this.state.infoWindow))})}componentDidMount(){var e=new google.maps.InfoWindow(this.props.options);this.containerElement=document.createElement("div"),this.registeredEvents=co({updaterMap:Tfe,eventMap:Cfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(()=>({infoWindow:e}),this.setInfoWindowCallback)}componentDidUpdate(e){this.state.infoWindow!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Tfe,eventMap:Cfe,prevProps:e,nextProps:this.props,instance:this.state.infoWindow}))}componentWillUnmount(){this.state.infoWindow!==null&&(So(this.registeredEvents),this.props.onUnmount&&this.props.onUnmount(this.state.infoWindow),this.state.infoWindow.close())}render(){return this.containerElement?zf.createPortal(J.Children.only(this.props.children),this.containerElement):null}}br(hEt,"contextType",Yn);function xfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function $z(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?xfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):xfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var Efe={onClick:"click",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDragStart:"dragstart",onMouseDown:"mousedown",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick"},wfe={draggable(t,e){t.setDraggable(e)},editable(t,e){t.setEditable(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},path(t,e){t.setPath(e)},visible(t,e){t.setVisible(e)}},pEt={};function gEt(t){var{options:e,draggable:i,editable:n,visible:r,path:o,onDblClick:a,onDragEnd:s,onDragStart:l,onMouseDown:u,onMouseMove:c,onMouseOut:d,onMouseOver:f,onMouseUp:h,onRightClick:p,onClick:g,onDrag:v,onLoad:y,onUnmount:m}=t,b=J.useContext(Yn),[S,_]=J.useState(null),[C,P]=J.useState(null),[x,E]=J.useState(null),[A,R]=J.useState(null),[M,D]=J.useState(null),[F,I]=J.useState(null),[V,z]=J.useState(null),[G,H]=J.useState(null),[U,k]=J.useState(null),[X,W]=J.useState(null),[Y,te]=J.useState(null),[oe,de]=J.useState(null);return J.useEffect(()=>{S!==null&&S.setMap(b)},[b]),J.useEffect(()=>{typeof e<"u"&&S!==null&&S.setOptions(e)},[S,e]),J.useEffect(()=>{typeof i<"u"&&S!==null&&S.setDraggable(i)},[S,i]),J.useEffect(()=>{typeof n<"u"&&S!==null&&S.setEditable(n)},[S,n]),J.useEffect(()=>{typeof r<"u"&&S!==null&&S.setVisible(r)},[S,r]),J.useEffect(()=>{typeof o<"u"&&S!==null&&S.setPath(o)},[S,o]),J.useEffect(()=>{S&&a&&(C!==null&&google.maps.event.removeListener(C),P(google.maps.event.addListener(S,"dblclick",a)))},[a]),J.useEffect(()=>{S&&s&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(S,"dragend",s)))},[s]),J.useEffect(()=>{S&&l&&(A!==null&&google.maps.event.removeListener(A),R(google.maps.event.addListener(S,"dragstart",l)))},[l]),J.useEffect(()=>{S&&u&&(M!==null&&google.maps.event.removeListener(M),D(google.maps.event.addListener(S,"mousedown",u)))},[u]),J.useEffect(()=>{S&&c&&(F!==null&&google.maps.event.removeListener(F),I(google.maps.event.addListener(S,"mousemove",c)))},[c]),J.useEffect(()=>{S&&d&&(V!==null&&google.maps.event.removeListener(V),z(google.maps.event.addListener(S,"mouseout",d)))},[d]),J.useEffect(()=>{S&&f&&(G!==null&&google.maps.event.removeListener(G),H(google.maps.event.addListener(S,"mouseover",f)))},[f]),J.useEffect(()=>{S&&h&&(U!==null&&google.maps.event.removeListener(U),k(google.maps.event.addListener(S,"mouseup",h)))},[h]),J.useEffect(()=>{S&&p&&(X!==null&&google.maps.event.removeListener(X),W(google.maps.event.addListener(S,"rightclick",p)))},[p]),J.useEffect(()=>{S&&g&&(Y!==null&&google.maps.event.removeListener(Y),te(google.maps.event.addListener(S,"click",g)))},[g]),J.useEffect(()=>{S&&v&&(oe!==null&&google.maps.event.removeListener(oe),de(google.maps.event.addListener(S,"drag",v)))},[v]),J.useEffect(()=>{var ge=new google.maps.Polyline($z($z({},e||pEt),{},{map:b}));return o&&ge.setPath(o),typeof r<"u"&&ge.setVisible(r),typeof n<"u"&&ge.setEditable(n),typeof i<"u"&&ge.setDraggable(i),a&&P(google.maps.event.addListener(ge,"dblclick",a)),s&&E(google.maps.event.addListener(ge,"dragend",s)),l&&R(google.maps.event.addListener(ge,"dragstart",l)),u&&D(google.maps.event.addListener(ge,"mousedown",u)),c&&I(google.maps.event.addListener(ge,"mousemove",c)),d&&z(google.maps.event.addListener(ge,"mouseout",d)),f&&H(google.maps.event.addListener(ge,"mouseover",f)),h&&k(google.maps.event.addListener(ge,"mouseup",h)),p&&W(google.maps.event.addListener(ge,"rightclick",p)),g&&te(google.maps.event.addListener(ge,"click",g)),v&&de(google.maps.event.addListener(ge,"drag",v)),_(ge),y&&y(ge),()=>{C!==null&&google.maps.event.removeListener(C),x!==null&&google.maps.event.removeListener(x),A!==null&&google.maps.event.removeListener(A),M!==null&&google.maps.event.removeListener(M),F!==null&&google.maps.event.removeListener(F),V!==null&&google.maps.event.removeListener(V),G!==null&&google.maps.event.removeListener(G),U!==null&&google.maps.event.removeListener(U),X!==null&&google.maps.event.removeListener(X),Y!==null&&google.maps.event.removeListener(Y),m&&m(ge),ge.setMap(null)}},[]),null}J.memo(gEt);class vEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{polyline:null}),br(this,"setPolylineCallback",()=>{this.state.polyline!==null&&this.props.onLoad&&this.props.onLoad(this.state.polyline)})}componentDidMount(){var e=new google.maps.Polyline($z($z({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:wfe,eventMap:Efe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{polyline:e}},this.setPolylineCallback)}componentDidUpdate(e){this.state.polyline!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:wfe,eventMap:Efe,prevProps:e,nextProps:this.props,instance:this.state.polyline}))}componentWillUnmount(){this.state.polyline!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.polyline),So(this.registeredEvents),this.state.polyline.setMap(null))}render(){return null}}br(vEt,"contextType",Yn);function Afe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Ofe(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Afe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Afe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var Dfe={onClick:"click",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDragStart:"dragstart",onMouseDown:"mousedown",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick"},Rfe={draggable(t,e){t.setDraggable(e)},editable(t,e){t.setEditable(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},path(t,e){t.setPath(e)},paths(t,e){t.setPaths(e)},visible(t,e){t.setVisible(e)}};function yEt(t){var{options:e,draggable:i,editable:n,visible:r,path:o,paths:a,onDblClick:s,onDragEnd:l,onDragStart:u,onMouseDown:c,onMouseMove:d,onMouseOut:f,onMouseOver:h,onMouseUp:p,onRightClick:g,onClick:v,onDrag:y,onLoad:m,onUnmount:b,onEdit:S}=t,_=J.useContext(Yn),[C,P]=J.useState(null),[x,E]=J.useState(null),[A,R]=J.useState(null),[M,D]=J.useState(null),[F,I]=J.useState(null),[V,z]=J.useState(null),[G,H]=J.useState(null),[U,k]=J.useState(null),[X,W]=J.useState(null),[Y,te]=J.useState(null),[oe,de]=J.useState(null),[ge,Ee]=J.useState(null);return J.useEffect(()=>{C!==null&&C.setMap(_)},[_]),J.useEffect(()=>{typeof e<"u"&&C!==null&&C.setOptions(e)},[C,e]),J.useEffect(()=>{typeof i<"u"&&C!==null&&C.setDraggable(i)},[C,i]),J.useEffect(()=>{typeof n<"u"&&C!==null&&C.setEditable(n)},[C,n]),J.useEffect(()=>{typeof r<"u"&&C!==null&&C.setVisible(r)},[C,r]),J.useEffect(()=>{typeof o<"u"&&C!==null&&C.setPath(o)},[C,o]),J.useEffect(()=>{typeof a<"u"&&C!==null&&C.setPaths(a)},[C,a]),J.useEffect(()=>{C&&typeof s=="function"&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(C,"dblclick",s)))},[s]),J.useEffect(()=>{C&&(google.maps.event.addListener(C.getPath(),"insert_at",()=>{S==null||S(C)}),google.maps.event.addListener(C.getPath(),"set_at",()=>{S==null||S(C)}),google.maps.event.addListener(C.getPath(),"remove_at",()=>{S==null||S(C)}))},[C,S]),J.useEffect(()=>{C&&typeof l=="function"&&(A!==null&&google.maps.event.removeListener(A),R(google.maps.event.addListener(C,"dragend",l)))},[l]),J.useEffect(()=>{C&&typeof u=="function"&&(M!==null&&google.maps.event.removeListener(M),D(google.maps.event.addListener(C,"dragstart",u)))},[u]),J.useEffect(()=>{C&&typeof c=="function"&&(F!==null&&google.maps.event.removeListener(F),I(google.maps.event.addListener(C,"mousedown",c)))},[c]),J.useEffect(()=>{C&&typeof d=="function"&&(V!==null&&google.maps.event.removeListener(V),z(google.maps.event.addListener(C,"mousemove",d)))},[d]),J.useEffect(()=>{C&&typeof f=="function"&&(G!==null&&google.maps.event.removeListener(G),H(google.maps.event.addListener(C,"mouseout",f)))},[f]),J.useEffect(()=>{C&&typeof h=="function"&&(U!==null&&google.maps.event.removeListener(U),k(google.maps.event.addListener(C,"mouseover",h)))},[h]),J.useEffect(()=>{C&&typeof p=="function"&&(X!==null&&google.maps.event.removeListener(X),W(google.maps.event.addListener(C,"mouseup",p)))},[p]),J.useEffect(()=>{C&&typeof g=="function"&&(Y!==null&&google.maps.event.removeListener(Y),te(google.maps.event.addListener(C,"rightclick",g)))},[g]),J.useEffect(()=>{C&&typeof v=="function"&&(oe!==null&&google.maps.event.removeListener(oe),de(google.maps.event.addListener(C,"click",v)))},[v]),J.useEffect(()=>{C&&typeof y=="function"&&(ge!==null&&google.maps.event.removeListener(ge),Ee(google.maps.event.addListener(C,"drag",y)))},[y]),J.useEffect(()=>{var Re=new google.maps.Polygon(Ofe(Ofe({},e),{},{map:_}));return o&&Re.setPath(o),a&&Re.setPaths(a),typeof r<"u"&&Re.setVisible(r),typeof n<"u"&&Re.setEditable(n),typeof i<"u"&&Re.setDraggable(i),s&&E(google.maps.event.addListener(Re,"dblclick",s)),l&&R(google.maps.event.addListener(Re,"dragend",l)),u&&D(google.maps.event.addListener(Re,"dragstart",u)),c&&I(google.maps.event.addListener(Re,"mousedown",c)),d&&z(google.maps.event.addListener(Re,"mousemove",d)),f&&H(google.maps.event.addListener(Re,"mouseout",f)),h&&k(google.maps.event.addListener(Re,"mouseover",h)),p&&W(google.maps.event.addListener(Re,"mouseup",p)),g&&te(google.maps.event.addListener(Re,"rightclick",g)),v&&de(google.maps.event.addListener(Re,"click",v)),y&&Ee(google.maps.event.addListener(Re,"drag",y)),P(Re),m&&m(Re),()=>{x!==null&&google.maps.event.removeListener(x),A!==null&&google.maps.event.removeListener(A),M!==null&&google.maps.event.removeListener(M),F!==null&&google.maps.event.removeListener(F),V!==null&&google.maps.event.removeListener(V),G!==null&&google.maps.event.removeListener(G),U!==null&&google.maps.event.removeListener(U),X!==null&&google.maps.event.removeListener(X),Y!==null&&google.maps.event.removeListener(Y),oe!==null&&google.maps.event.removeListener(oe),b&&b(Re),Re.setMap(null)}},[]),null}J.memo(yEt);class mEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[])}componentDidMount(){var e=this.props.options||{};this.polygon=new google.maps.Polygon(e),this.polygon.setMap(this.context),this.registeredEvents=co({updaterMap:Rfe,eventMap:Dfe,prevProps:{},nextProps:this.props,instance:this.polygon}),this.props.onLoad&&this.props.onLoad(this.polygon)}componentDidUpdate(e){this.polygon&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Rfe,eventMap:Dfe,prevProps:e,nextProps:this.props,instance:this.polygon}))}componentWillUnmount(){this.polygon&&(this.props.onUnmount&&this.props.onUnmount(this.polygon),So(this.registeredEvents),this.polygon&&this.polygon.setMap(null))}render(){return null}}br(mEt,"contextType",Yn);function Mfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Wz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Mfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Mfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var Lfe={onBoundsChanged:"bounds_changed",onClick:"click",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDragStart:"dragstart",onMouseDown:"mousedown",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick"},kfe={bounds(t,e){t.setBounds(e)},draggable(t,e){t.setDraggable(e)},editable(t,e){t.setEditable(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},visible(t,e){t.setVisible(e)}};function bEt(t){var{options:e,bounds:i,draggable:n,editable:r,visible:o,onDblClick:a,onDragEnd:s,onDragStart:l,onMouseDown:u,onMouseMove:c,onMouseOut:d,onMouseOver:f,onMouseUp:h,onRightClick:p,onClick:g,onDrag:v,onBoundsChanged:y,onLoad:m,onUnmount:b}=t,S=J.useContext(Yn),[_,C]=J.useState(null),[P,x]=J.useState(null),[E,A]=J.useState(null),[R,M]=J.useState(null),[D,F]=J.useState(null),[I,V]=J.useState(null),[z,G]=J.useState(null),[H,U]=J.useState(null),[k,X]=J.useState(null),[W,Y]=J.useState(null),[te,oe]=J.useState(null),[de,ge]=J.useState(null),[Ee,Re]=J.useState(null);return J.useEffect(()=>{_!==null&&_.setMap(S)},[S]),J.useEffect(()=>{typeof e<"u"&&_!==null&&_.setOptions(e)},[_,e]),J.useEffect(()=>{typeof n<"u"&&_!==null&&_.setDraggable(n)},[_,n]),J.useEffect(()=>{typeof r<"u"&&_!==null&&_.setEditable(r)},[_,r]),J.useEffect(()=>{typeof o<"u"&&_!==null&&_.setVisible(o)},[_,o]),J.useEffect(()=>{typeof i<"u"&&_!==null&&_.setBounds(i)},[_,i]),J.useEffect(()=>{_&&a&&(P!==null&&google.maps.event.removeListener(P),x(google.maps.event.addListener(_,"dblclick",a)))},[a]),J.useEffect(()=>{_&&s&&(E!==null&&google.maps.event.removeListener(E),A(google.maps.event.addListener(_,"dragend",s)))},[s]),J.useEffect(()=>{_&&l&&(R!==null&&google.maps.event.removeListener(R),M(google.maps.event.addListener(_,"dragstart",l)))},[l]),J.useEffect(()=>{_&&u&&(D!==null&&google.maps.event.removeListener(D),F(google.maps.event.addListener(_,"mousedown",u)))},[u]),J.useEffect(()=>{_&&c&&(I!==null&&google.maps.event.removeListener(I),V(google.maps.event.addListener(_,"mousemove",c)))},[c]),J.useEffect(()=>{_&&d&&(z!==null&&google.maps.event.removeListener(z),G(google.maps.event.addListener(_,"mouseout",d)))},[d]),J.useEffect(()=>{_&&f&&(H!==null&&google.maps.event.removeListener(H),U(google.maps.event.addListener(_,"mouseover",f)))},[f]),J.useEffect(()=>{_&&h&&(k!==null&&google.maps.event.removeListener(k),X(google.maps.event.addListener(_,"mouseup",h)))},[h]),J.useEffect(()=>{_&&p&&(W!==null&&google.maps.event.removeListener(W),Y(google.maps.event.addListener(_,"rightclick",p)))},[p]),J.useEffect(()=>{_&&g&&(te!==null&&google.maps.event.removeListener(te),oe(google.maps.event.addListener(_,"click",g)))},[g]),J.useEffect(()=>{_&&v&&(de!==null&&google.maps.event.removeListener(de),ge(google.maps.event.addListener(_,"drag",v)))},[v]),J.useEffect(()=>{_&&y&&(Ee!==null&&google.maps.event.removeListener(Ee),Re(google.maps.event.addListener(_,"bounds_changed",y)))},[y]),J.useEffect(()=>{var Ae=new google.maps.Rectangle(Wz(Wz({},e),{},{map:S}));return typeof o<"u"&&Ae.setVisible(o),typeof r<"u"&&Ae.setEditable(r),typeof n<"u"&&Ae.setDraggable(n),typeof i<"u"&&Ae.setBounds(i),a&&x(google.maps.event.addListener(Ae,"dblclick",a)),s&&A(google.maps.event.addListener(Ae,"dragend",s)),l&&M(google.maps.event.addListener(Ae,"dragstart",l)),u&&F(google.maps.event.addListener(Ae,"mousedown",u)),c&&V(google.maps.event.addListener(Ae,"mousemove",c)),d&&G(google.maps.event.addListener(Ae,"mouseout",d)),f&&U(google.maps.event.addListener(Ae,"mouseover",f)),h&&X(google.maps.event.addListener(Ae,"mouseup",h)),p&&Y(google.maps.event.addListener(Ae,"rightclick",p)),g&&oe(google.maps.event.addListener(Ae,"click",g)),v&&ge(google.maps.event.addListener(Ae,"drag",v)),y&&Re(google.maps.event.addListener(Ae,"bounds_changed",y)),C(Ae),m&&m(Ae),()=>{P!==null&&google.maps.event.removeListener(P),E!==null&&google.maps.event.removeListener(E),R!==null&&google.maps.event.removeListener(R),D!==null&&google.maps.event.removeListener(D),I!==null&&google.maps.event.removeListener(I),z!==null&&google.maps.event.removeListener(z),H!==null&&google.maps.event.removeListener(H),k!==null&&google.maps.event.removeListener(k),W!==null&&google.maps.event.removeListener(W),te!==null&&google.maps.event.removeListener(te),de!==null&&google.maps.event.removeListener(de),Ee!==null&&google.maps.event.removeListener(Ee),b&&b(Ae),Ae.setMap(null)}},[]),null}J.memo(bEt);class SEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{rectangle:null}),br(this,"setRectangleCallback",()=>{this.state.rectangle!==null&&this.props.onLoad&&this.props.onLoad(this.state.rectangle)})}componentDidMount(){var e=new google.maps.Rectangle(Wz(Wz({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:kfe,eventMap:Lfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{rectangle:e}},this.setRectangleCallback)}componentDidUpdate(e){this.state.rectangle!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:kfe,eventMap:Lfe,prevProps:e,nextProps:this.props,instance:this.state.rectangle}))}componentWillUnmount(){this.state.rectangle!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.rectangle),So(this.registeredEvents),this.state.rectangle.setMap(null))}render(){return null}}br(SEt,"contextType",Yn);function Ife(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Gz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Ife(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Ife(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var Nfe={onCenterChanged:"center_changed",onRadiusChanged:"radius_changed",onClick:"click",onDblClick:"dblclick",onDrag:"drag",onDragEnd:"dragend",onDragStart:"dragstart",onMouseDown:"mousedown",onMouseMove:"mousemove",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick"},Ffe={center(t,e){t.setCenter(e)},draggable(t,e){t.setDraggable(e)},editable(t,e){t.setEditable(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},radius(t,e){t.setRadius(e)},visible(t,e){t.setVisible(e)}},_Et={};function PEt(t){var{options:e,center:i,radius:n,draggable:r,editable:o,visible:a,onDblClick:s,onDragEnd:l,onDragStart:u,onMouseDown:c,onMouseMove:d,onMouseOut:f,onMouseOver:h,onMouseUp:p,onRightClick:g,onClick:v,onDrag:y,onCenterChanged:m,onRadiusChanged:b,onLoad:S,onUnmount:_}=t,C=J.useContext(Yn),[P,x]=J.useState(null),[E,A]=J.useState(null),[R,M]=J.useState(null),[D,F]=J.useState(null),[I,V]=J.useState(null),[z,G]=J.useState(null),[H,U]=J.useState(null),[k,X]=J.useState(null),[W,Y]=J.useState(null),[te,oe]=J.useState(null),[de,ge]=J.useState(null),[Ee,Re]=J.useState(null),[Ae,Pe]=J.useState(null),[we,Te]=J.useState(null);return J.useEffect(()=>{P!==null&&P.setMap(C)},[C]),J.useEffect(()=>{typeof e<"u"&&P!==null&&P.setOptions(e)},[P,e]),J.useEffect(()=>{typeof r<"u"&&P!==null&&P.setDraggable(r)},[P,r]),J.useEffect(()=>{typeof o<"u"&&P!==null&&P.setEditable(o)},[P,o]),J.useEffect(()=>{typeof a<"u"&&P!==null&&P.setVisible(a)},[P,a]),J.useEffect(()=>{typeof n=="number"&&P!==null&&P.setRadius(n)},[P,n]),J.useEffect(()=>{typeof i<"u"&&P!==null&&P.setCenter(i)},[P,i]),J.useEffect(()=>{P&&s&&(E!==null&&google.maps.event.removeListener(E),A(google.maps.event.addListener(P,"dblclick",s)))},[s]),J.useEffect(()=>{P&&l&&(R!==null&&google.maps.event.removeListener(R),M(google.maps.event.addListener(P,"dragend",l)))},[l]),J.useEffect(()=>{P&&u&&(D!==null&&google.maps.event.removeListener(D),F(google.maps.event.addListener(P,"dragstart",u)))},[u]),J.useEffect(()=>{P&&c&&(I!==null&&google.maps.event.removeListener(I),V(google.maps.event.addListener(P,"mousedown",c)))},[c]),J.useEffect(()=>{P&&d&&(z!==null&&google.maps.event.removeListener(z),G(google.maps.event.addListener(P,"mousemove",d)))},[d]),J.useEffect(()=>{P&&f&&(H!==null&&google.maps.event.removeListener(H),U(google.maps.event.addListener(P,"mouseout",f)))},[f]),J.useEffect(()=>{P&&h&&(k!==null&&google.maps.event.removeListener(k),X(google.maps.event.addListener(P,"mouseover",h)))},[h]),J.useEffect(()=>{P&&p&&(W!==null&&google.maps.event.removeListener(W),Y(google.maps.event.addListener(P,"mouseup",p)))},[p]),J.useEffect(()=>{P&&g&&(te!==null&&google.maps.event.removeListener(te),oe(google.maps.event.addListener(P,"rightclick",g)))},[g]),J.useEffect(()=>{P&&v&&(de!==null&&google.maps.event.removeListener(de),ge(google.maps.event.addListener(P,"click",v)))},[v]),J.useEffect(()=>{P&&y&&(Ee!==null&&google.maps.event.removeListener(Ee),Re(google.maps.event.addListener(P,"drag",y)))},[y]),J.useEffect(()=>{P&&m&&(Ae!==null&&google.maps.event.removeListener(Ae),Pe(google.maps.event.addListener(P,"center_changed",m)))},[v]),J.useEffect(()=>{P&&b&&(we!==null&&google.maps.event.removeListener(we),Te(google.maps.event.addListener(P,"radius_changed",b)))},[b]),J.useEffect(()=>{var ke=new google.maps.Circle(Gz(Gz({},e||_Et),{},{map:C}));return typeof n=="number"&&ke.setRadius(n),typeof i<"u"&&ke.setCenter(i),typeof n=="number"&&ke.setRadius(n),typeof a<"u"&&ke.setVisible(a),typeof o<"u"&&ke.setEditable(o),typeof r<"u"&&ke.setDraggable(r),s&&A(google.maps.event.addListener(ke,"dblclick",s)),l&&M(google.maps.event.addListener(ke,"dragend",l)),u&&F(google.maps.event.addListener(ke,"dragstart",u)),c&&V(google.maps.event.addListener(ke,"mousedown",c)),d&&G(google.maps.event.addListener(ke,"mousemove",d)),f&&U(google.maps.event.addListener(ke,"mouseout",f)),h&&X(google.maps.event.addListener(ke,"mouseover",h)),p&&Y(google.maps.event.addListener(ke,"mouseup",p)),g&&oe(google.maps.event.addListener(ke,"rightclick",g)),v&&ge(google.maps.event.addListener(ke,"click",v)),y&&Re(google.maps.event.addListener(ke,"drag",y)),m&&Pe(google.maps.event.addListener(ke,"center_changed",m)),b&&Te(google.maps.event.addListener(ke,"radius_changed",b)),x(ke),S&&S(ke),()=>{E!==null&&google.maps.event.removeListener(E),R!==null&&google.maps.event.removeListener(R),D!==null&&google.maps.event.removeListener(D),I!==null&&google.maps.event.removeListener(I),z!==null&&google.maps.event.removeListener(z),H!==null&&google.maps.event.removeListener(H),k!==null&&google.maps.event.removeListener(k),W!==null&&google.maps.event.removeListener(W),te!==null&&google.maps.event.removeListener(te),de!==null&&google.maps.event.removeListener(de),Ae!==null&&google.maps.event.removeListener(Ae),we!==null&&google.maps.event.removeListener(we),_&&_(ke),ke.setMap(null)}},[]),null}J.memo(PEt);class CEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{circle:null}),br(this,"setCircleCallback",()=>{this.state.circle!==null&&this.props.onLoad&&this.props.onLoad(this.state.circle)})}componentDidMount(){var e=new google.maps.Circle(Gz(Gz({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:Ffe,eventMap:Nfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{circle:e}},this.setCircleCallback)}componentDidUpdate(e){this.state.circle!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Ffe,eventMap:Nfe,prevProps:e,nextProps:this.props,instance:this.state.circle}))}componentWillUnmount(){if(this.state.circle!==null){var e;this.props.onUnmount&&this.props.onUnmount(this.state.circle),So(this.registeredEvents),(e=this.state.circle)===null||e===void 0||e.setMap(null)}}render(){return null}}br(CEt,"contextType",Yn);function Bfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Yz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Bfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Bfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var jfe={onClick:"click",onDblClick:"dblclick",onMouseDown:"mousedown",onMouseOut:"mouseout",onMouseOver:"mouseover",onMouseUp:"mouseup",onRightClick:"rightclick",onAddFeature:"addfeature",onRemoveFeature:"removefeature",onRemoveProperty:"removeproperty",onSetGeometry:"setgeometry",onSetProperty:"setproperty"},Vfe={add(t,e){t.add(e)},addgeojson(t,e,i){t.addGeoJson(e,i)},contains(t,e){t.contains(e)},foreach(t,e){t.forEach(e)},loadgeojson(t,e,i,n){t.loadGeoJson(e,i,n)},overridestyle(t,e,i){t.overrideStyle(e,i)},remove(t,e){t.remove(e)},revertstyle(t,e){t.revertStyle(e)},controlposition(t,e){t.setControlPosition(e)},controls(t,e){t.setControls(e)},drawingmode(t,e){t.setDrawingMode(e)},map(t,e){t.setMap(e)},style(t,e){t.setStyle(e)},togeojson(t,e){t.toGeoJson(e)}};function TEt(t){var{options:e,onClick:i,onDblClick:n,onMouseDown:r,onMouseMove:o,onMouseOut:a,onMouseOver:s,onMouseUp:l,onRightClick:u,onAddFeature:c,onRemoveFeature:d,onRemoveProperty:f,onSetGeometry:h,onSetProperty:p,onLoad:g,onUnmount:v}=t,y=J.useContext(Yn),[m,b]=J.useState(null),[S,_]=J.useState(null),[C,P]=J.useState(null),[x,E]=J.useState(null),[A,R]=J.useState(null),[M,D]=J.useState(null),[F,I]=J.useState(null),[V,z]=J.useState(null),[G,H]=J.useState(null),[U,k]=J.useState(null),[X,W]=J.useState(null),[Y,te]=J.useState(null),[oe,de]=J.useState(null),[ge,Ee]=J.useState(null);return J.useEffect(()=>{m!==null&&m.setMap(y)},[y]),J.useEffect(()=>{m&&n&&(S!==null&&google.maps.event.removeListener(S),_(google.maps.event.addListener(m,"dblclick",n)))},[n]),J.useEffect(()=>{m&&r&&(C!==null&&google.maps.event.removeListener(C),P(google.maps.event.addListener(m,"mousedown",r)))},[r]),J.useEffect(()=>{m&&o&&(x!==null&&google.maps.event.removeListener(x),E(google.maps.event.addListener(m,"mousemove",o)))},[o]),J.useEffect(()=>{m&&a&&(A!==null&&google.maps.event.removeListener(A),R(google.maps.event.addListener(m,"mouseout",a)))},[a]),J.useEffect(()=>{m&&s&&(M!==null&&google.maps.event.removeListener(M),D(google.maps.event.addListener(m,"mouseover",s)))},[s]),J.useEffect(()=>{m&&l&&(F!==null&&google.maps.event.removeListener(F),I(google.maps.event.addListener(m,"mouseup",l)))},[l]),J.useEffect(()=>{m&&u&&(V!==null&&google.maps.event.removeListener(V),z(google.maps.event.addListener(m,"rightclick",u)))},[u]),J.useEffect(()=>{m&&i&&(G!==null&&google.maps.event.removeListener(G),H(google.maps.event.addListener(m,"click",i)))},[i]),J.useEffect(()=>{m&&c&&(U!==null&&google.maps.event.removeListener(U),k(google.maps.event.addListener(m,"addfeature",c)))},[c]),J.useEffect(()=>{m&&d&&(X!==null&&google.maps.event.removeListener(X),W(google.maps.event.addListener(m,"removefeature",d)))},[d]),J.useEffect(()=>{m&&f&&(Y!==null&&google.maps.event.removeListener(Y),te(google.maps.event.addListener(m,"removeproperty",f)))},[f]),J.useEffect(()=>{m&&h&&(oe!==null&&google.maps.event.removeListener(oe),de(google.maps.event.addListener(m,"setgeometry",h)))},[h]),J.useEffect(()=>{m&&p&&(ge!==null&&google.maps.event.removeListener(ge),Ee(google.maps.event.addListener(m,"setproperty",p)))},[p]),J.useEffect(()=>{if(y!==null){var Re=new google.maps.Data(Yz(Yz({},e),{},{map:y}));n&&_(google.maps.event.addListener(Re,"dblclick",n)),r&&P(google.maps.event.addListener(Re,"mousedown",r)),o&&E(google.maps.event.addListener(Re,"mousemove",o)),a&&R(google.maps.event.addListener(Re,"mouseout",a)),s&&D(google.maps.event.addListener(Re,"mouseover",s)),l&&I(google.maps.event.addListener(Re,"mouseup",l)),u&&z(google.maps.event.addListener(Re,"rightclick",u)),i&&H(google.maps.event.addListener(Re,"click",i)),c&&k(google.maps.event.addListener(Re,"addfeature",c)),d&&W(google.maps.event.addListener(Re,"removefeature",d)),f&&te(google.maps.event.addListener(Re,"removeproperty",f)),h&&de(google.maps.event.addListener(Re,"setgeometry",h)),p&&Ee(google.maps.event.addListener(Re,"setproperty",p)),b(Re),g&&g(Re)}return()=>{m&&(S!==null&&google.maps.event.removeListener(S),C!==null&&google.maps.event.removeListener(C),x!==null&&google.maps.event.removeListener(x),A!==null&&google.maps.event.removeListener(A),M!==null&&google.maps.event.removeListener(M),F!==null&&google.maps.event.removeListener(F),V!==null&&google.maps.event.removeListener(V),G!==null&&google.maps.event.removeListener(G),U!==null&&google.maps.event.removeListener(U),X!==null&&google.maps.event.removeListener(X),Y!==null&&google.maps.event.removeListener(Y),oe!==null&&google.maps.event.removeListener(oe),ge!==null&&google.maps.event.removeListener(ge),v&&v(m),m.setMap(null))}},[]),null}J.memo(TEt);class xEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{data:null}),br(this,"setDataCallback",()=>{this.state.data!==null&&this.props.onLoad&&this.props.onLoad(this.state.data)})}componentDidMount(){if(this.context!==null){var e=new google.maps.Data(Yz(Yz({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:Vfe,eventMap:jfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(()=>({data:e}),this.setDataCallback)}}componentDidUpdate(e){this.state.data!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Vfe,eventMap:jfe,prevProps:e,nextProps:this.props,instance:this.state.data}))}componentWillUnmount(){this.state.data!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.data),So(this.registeredEvents),this.state.data&&this.state.data.setMap(null))}render(){return null}}br(xEt,"contextType",Yn);function Hfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Ufe(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Hfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Hfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var zfe={onClick:"click",onDefaultViewportChanged:"defaultviewport_changed",onStatusChanged:"status_changed"},$fe={options(t,e){t.setOptions(e)},url(t,e){t.setUrl(e)},zIndex(t,e){t.setZIndex(e)}};class EEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{kmlLayer:null}),br(this,"setKmlLayerCallback",()=>{this.state.kmlLayer!==null&&this.props.onLoad&&this.props.onLoad(this.state.kmlLayer)})}componentDidMount(){var e=new google.maps.KmlLayer(Ufe(Ufe({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:$fe,eventMap:zfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{kmlLayer:e}},this.setKmlLayerCallback)}componentDidUpdate(e){this.state.kmlLayer!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:$fe,eventMap:zfe,prevProps:e,nextProps:this.props,instance:this.state.kmlLayer}))}componentWillUnmount(){this.state.kmlLayer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.kmlLayer),So(this.registeredEvents),this.state.kmlLayer.setMap(null))}render(){return null}}br(EEt,"contextType",Yn);function INe(t,e){return typeof e=="function"?e(t.offsetWidth,t.offsetHeight):{x:0,y:0}}function wEt(t,e){return new e(t.lat,t.lng)}function AEt(t,e){return new e(new google.maps.LatLng(t.ne.lat,t.ne.lng),new google.maps.LatLng(t.sw.lat,t.sw.lng))}function OEt(t,e,i){return t instanceof e?t:i(t,e)}function DEt(t,e,i){return t instanceof e?t:i(t,e)}function REt(t,e,i){var n=t&&t.fromLatLngToDivPixel(i.getNorthEast()),r=t&&t.fromLatLngToDivPixel(i.getSouthWest());return n&&r?{left:"".concat(r.x+e.x,"px"),top:"".concat(n.y+e.y,"px"),width:"".concat(n.x-r.x-e.x,"px"),height:"".concat(r.y-n.y-e.y,"px")}:{left:"-9999px",top:"-9999px"}}function MEt(t,e,i){var n=t&&t.fromLatLngToDivPixel(i);if(n){var{x:r,y:o}=n;return{left:"".concat(r+e.x,"px"),top:"".concat(o+e.y,"px")}}return{left:"-9999px",top:"-9999px"}}function NNe(t,e,i,n){return i!==void 0?REt(t,e,DEt(i,google.maps.LatLngBounds,AEt)):MEt(t,e,OEt(n,google.maps.LatLng,wEt))}function LEt(t,e){return t.left===e.left&&t.top===e.top&&t.width===e.height&&t.height===e.height}function Wfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function kEt(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Wfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Wfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}function IEt(t,e,i,n,r){class o extends google.maps.OverlayView{constructor(s,l,u,c){super(),this.container=s,this.pane=l,this.position=u,this.bounds=c}onAdd(){var s,l=(s=this.getPanes())===null||s===void 0?void 0:s[this.pane];l==null||l.appendChild(this.container)}draw(){var s=this.getProjection(),l=kEt({},this.container?INe(this.container,r):{x:0,y:0}),u=NNe(s,l,this.bounds,this.position);for(var[c,d]of Object.entries(u))this.container.style[c]=d}onRemove(){this.container.parentNode!==null&&this.container.parentNode.removeChild(this.container)}}return new o(t,e,i,n)}function Gfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function NEt(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Gfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Gfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}function Yfe(t){if(!t)return"";var e=t instanceof google.maps.LatLng?t:new google.maps.LatLng(t.lat,t.lng);return e+""}function qfe(t){if(!t)return"";var e=t instanceof google.maps.LatLngBounds?t:new google.maps.LatLngBounds(new google.maps.LatLng(t.south,t.east),new google.maps.LatLng(t.north,t.west));return e+""}function FEt(t){var{position:e,bounds:i,mapPaneName:n,zIndex:r,onLoad:o,onUnmount:a,getPixelPositionOffset:s,children:l}=t,u=J.useContext(Yn),c=J.useMemo(()=>{var f=document.createElement("div");return f.style.position="absolute",f},[]),d=J.useMemo(()=>IEt(c,n,e,i,s),[c,n,e,i]);return J.useEffect(()=>(o==null||o(d),d==null||d.setMap(u),()=>{a==null||a(d),d==null||d.setMap(null)}),[u,d]),J.useEffect(()=>{c.style.zIndex="".concat(r)},[r,c]),zf.createPortal(l,c)}J.memo(FEt);class wI extends J.PureComponent{constructor(e){super(e),br(this,"state",{paneEl:null,containerStyle:{position:"absolute"}}),br(this,"updatePane",()=>{var n=this.props.mapPaneName,r=this.overlayView.getPanes();ec(!!n,"OverlayView requires props.mapPaneName but got %s",n),r?this.setState({paneEl:r[n]}):this.setState({paneEl:null})}),br(this,"onAdd",()=>{var n,r;this.updatePane(),(n=(r=this.props).onLoad)===null||n===void 0||n.call(r,this.overlayView)}),br(this,"onPositionElement",()=>{var n=this.overlayView.getProjection(),r=NEt({x:0,y:0},this.containerRef.current?INe(this.containerRef.current,this.props.getPixelPositionOffset):{}),o=NNe(n,r,this.props.bounds,this.props.position);if(!LEt(o,{left:this.state.containerStyle.left,top:this.state.containerStyle.top,width:this.state.containerStyle.width,height:this.state.containerStyle.height})){var a,s,l,u;this.setState({containerStyle:{top:(a=o.top)!==null&&a!==void 0?a:0,left:(s=o.left)!==null&&s!==void 0?s:0,width:(l=o.width)!==null&&l!==void 0?l:0,height:(u=o.height)!==null&&u!==void 0?u:0,position:"absolute"}})}}),br(this,"draw",()=>{this.onPositionElement()}),br(this,"onRemove",()=>{var n,r;this.setState(()=>({paneEl:null})),(n=(r=this.props).onUnmount)===null||n===void 0||n.call(r,this.overlayView)}),this.containerRef=J.createRef();var i=new google.maps.OverlayView;i.onAdd=this.onAdd,i.draw=this.draw,i.onRemove=this.onRemove,this.overlayView=i}componentDidMount(){this.overlayView.setMap(this.context)}componentDidUpdate(e){var i=Yfe(e.position),n=Yfe(this.props.position),r=qfe(e.bounds),o=qfe(this.props.bounds);(i!==n||r!==o)&&this.overlayView.draw(),e.mapPaneName!==this.props.mapPaneName&&this.updatePane()}componentWillUnmount(){this.overlayView.setMap(null)}render(){var e=this.state.paneEl;return e?zf.createPortal(L.jsx("div",{ref:this.containerRef,style:this.state.containerStyle,children:J.Children.only(this.props.children)}),e):null}}br(wI,"FLOAT_PANE","floatPane");br(wI,"MAP_PANE","mapPane");br(wI,"MARKER_LAYER","markerLayer");br(wI,"OVERLAY_LAYER","overlayLayer");br(wI,"OVERLAY_MOUSE_TARGET","overlayMouseTarget");br(wI,"contextType",Yn);function BEt(){}function Xfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function Kfe(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Xfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Xfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var Zfe={onDblClick:"dblclick",onClick:"click"},Jfe={opacity(t,e){t.setOpacity(e)}};function jEt(t){var{url:e,bounds:i,options:n,visible:r}=t,o=J.useContext(Yn),a=new google.maps.LatLngBounds(new google.maps.LatLng(i.south,i.west),new google.maps.LatLng(i.north,i.east)),s=J.useMemo(()=>new google.maps.GroundOverlay(e,a,n),[]);return J.useEffect(()=>{s!==null&&s.setMap(o)},[o]),J.useEffect(()=>{typeof e<"u"&&s!==null&&(s.set("url",e),s.setMap(o))},[s,e]),J.useEffect(()=>{typeof r<"u"&&s!==null&&s.setOpacity(r?1:0)},[s,r]),J.useEffect(()=>{var l=new google.maps.LatLngBounds(new google.maps.LatLng(i.south,i.west),new google.maps.LatLng(i.north,i.east));typeof i<"u"&&s!==null&&(s.set("bounds",l),s.setMap(o))},[s,i]),null}J.memo(jEt);class FNe extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{groundOverlay:null}),br(this,"setGroundOverlayCallback",()=>{this.state.groundOverlay!==null&&this.props.onLoad&&this.props.onLoad(this.state.groundOverlay)})}componentDidMount(){ec(!!this.props.url||!!this.props.bounds,"For GroundOverlay, url and bounds are passed in to constructor and are immutable after instantiated. This is the behavior of Google Maps JavaScript API v3 ( See https://developers.google.com/maps/documentation/javascript/reference#GroundOverlay) Hence, use the corresponding two props provided by `react-google-maps-api`, url and bounds. In some cases, you'll need the GroundOverlay component to reflect the changes of url and bounds. You can leverage the React's key property to remount the component. Typically, just `key={url}` would serve your need. See https://github.com/tomchentw/react-google-maps/issues/655");var e=new google.maps.GroundOverlay(this.props.url,this.props.bounds,Kfe(Kfe({},this.props.options),{},{map:this.context}));this.registeredEvents=co({updaterMap:Jfe,eventMap:Zfe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{groundOverlay:e}},this.setGroundOverlayCallback)}componentDidUpdate(e){this.state.groundOverlay!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:Jfe,eventMap:Zfe,prevProps:e,nextProps:this.props,instance:this.state.groundOverlay}))}componentWillUnmount(){this.state.groundOverlay&&(this.props.onUnmount&&this.props.onUnmount(this.state.groundOverlay),this.state.groundOverlay.setMap(null))}render(){return null}}br(FNe,"defaultProps",{onLoad:BEt});br(FNe,"contextType",Yn);function Qfe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(t,r).enumerable})),i.push.apply(i,n)}return i}function qz(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?Qfe(Object(i),!0).forEach(function(n){br(t,n,i[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):Qfe(Object(i)).forEach(function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(i,n))})}return t}var ehe={},the={data(t,e){t.setData(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)}};function VEt(t){var{data:e,onLoad:i,onUnmount:n,options:r}=t,o=J.useContext(Yn),[a,s]=J.useState(null);return J.useEffect(()=>{google.maps.visualization||ec(!!google.maps.visualization,'Did you include prop libraries={["visualization"]} in useJsApiScript? %s',google.maps.visualization)},[]),J.useEffect(()=>{ec(!!e,"data property is required in HeatmapLayer %s",e)},[e]),J.useEffect(()=>{a!==null&&a.setMap(o)},[o]),J.useEffect(()=>{r&&a!==null&&a.setOptions(r)},[a,r]),J.useEffect(()=>{var l=new google.maps.visualization.HeatmapLayer(qz(qz({},r),{},{data:e,map:o}));return s(l),i&&i(l),()=>{a!==null&&(n&&n(a),a.setMap(null))}},[]),null}J.memo(VEt);class HEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{heatmapLayer:null}),br(this,"setHeatmapLayerCallback",()=>{this.state.heatmapLayer!==null&&this.props.onLoad&&this.props.onLoad(this.state.heatmapLayer)})}componentDidMount(){ec(!!google.maps.visualization,'Did you include prop libraries={["visualization"]} to <LoadScript />? %s',google.maps.visualization),ec(!!this.props.data,"data property is required in HeatmapLayer %s",this.props.data);var e=new google.maps.visualization.HeatmapLayer(qz(qz({},this.props.options),{},{data:this.props.data,map:this.context}));this.registeredEvents=co({updaterMap:the,eventMap:ehe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{heatmapLayer:e}},this.setHeatmapLayerCallback)}componentDidUpdate(e){So(this.registeredEvents),this.registeredEvents=co({updaterMap:the,eventMap:ehe,prevProps:e,nextProps:this.props,instance:this.state.heatmapLayer})}componentWillUnmount(){this.state.heatmapLayer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.heatmapLayer),So(this.registeredEvents),this.state.heatmapLayer.setMap(null))}render(){return null}}br(HEt,"contextType",Yn);var rhe={onCloseClick:"closeclick",onPanoChanged:"pano_changed",onPositionChanged:"position_changed",onPovChanged:"pov_changed",onResize:"resize",onStatusChanged:"status_changed",onVisibleChanged:"visible_changed",onZoomChanged:"zoom_changed"},ihe={register(t,e,i){t.registerPanoProvider(e,i)},links(t,e){t.setLinks(e)},motionTracking(t,e){t.setMotionTracking(e)},options(t,e){t.setOptions(e)},pano(t,e){t.setPano(e)},position(t,e){t.setPosition(e)},pov(t,e){t.setPov(e)},visible(t,e){t.setVisible(e)},zoom(t,e){t.setZoom(e)}};class UEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{streetViewPanorama:null}),br(this,"setStreetViewPanoramaCallback",()=>{this.state.streetViewPanorama!==null&&this.props.onLoad&&this.props.onLoad(this.state.streetViewPanorama)})}componentDidMount(){var e,i,n=(e=(i=this.context)===null||i===void 0?void 0:i.getStreetView())!==null&&e!==void 0?e:null;this.registeredEvents=co({updaterMap:ihe,eventMap:rhe,prevProps:{},nextProps:this.props,instance:n}),this.setState(()=>({streetViewPanorama:n}),this.setStreetViewPanoramaCallback)}componentDidUpdate(e){this.state.streetViewPanorama!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:ihe,eventMap:rhe,prevProps:e,nextProps:this.props,instance:this.state.streetViewPanorama}))}componentWillUnmount(){this.state.streetViewPanorama!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.streetViewPanorama),So(this.registeredEvents),this.state.streetViewPanorama.setVisible(!1))}render(){return null}}br(UEt,"contextType",Yn);class zEt extends J.PureComponent{constructor(){super(...arguments),br(this,"state",{streetViewService:null}),br(this,"setStreetViewServiceCallback",()=>{this.state.streetViewService!==null&&this.props.onLoad&&this.props.onLoad(this.state.streetViewService)})}componentDidMount(){var e=new google.maps.StreetViewService;this.setState(function(){return{streetViewService:e}},this.setStreetViewServiceCallback)}componentWillUnmount(){this.state.streetViewService!==null&&this.props.onUnmount&&this.props.onUnmount(this.state.streetViewService)}render(){return null}}br(zEt,"contextType",Yn);var nhe={onDirectionsChanged:"directions_changed"},ohe={directions(t,e){t.setDirections(e)},map(t,e){t.setMap(e)},options(t,e){t.setOptions(e)},panel(t,e){t.setPanel(e)},routeIndex(t,e){t.setRouteIndex(e)}};class $Et extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"state",{directionsRenderer:null}),br(this,"setDirectionsRendererCallback",()=>{this.state.directionsRenderer!==null&&(this.state.directionsRenderer.setMap(this.context),this.props.onLoad&&this.props.onLoad(this.state.directionsRenderer))})}componentDidMount(){var e=new google.maps.DirectionsRenderer(this.props.options);this.registeredEvents=co({updaterMap:ohe,eventMap:nhe,prevProps:{},nextProps:this.props,instance:e}),this.setState(function(){return{directionsRenderer:e}},this.setDirectionsRendererCallback)}componentDidUpdate(e){this.state.directionsRenderer!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:ohe,eventMap:nhe,prevProps:e,nextProps:this.props,instance:this.state.directionsRenderer}))}componentWillUnmount(){this.state.directionsRenderer!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.directionsRenderer),So(this.registeredEvents),this.state.directionsRenderer&&this.state.directionsRenderer.setMap(null))}render(){return null}}br($Et,"contextType",Yn);var ahe={onPlacesChanged:"places_changed"},she={bounds(t,e){t.setBounds(e)}};class WEt extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"containerElement",J.createRef()),br(this,"state",{searchBox:null}),br(this,"setSearchBoxCallback",()=>{this.state.searchBox!==null&&this.props.onLoad&&this.props.onLoad(this.state.searchBox)})}componentDidMount(){if(ec(!!google.maps.places,'You need to provide libraries={["places"]} prop to <LoadScript /> component %s',google.maps.places),this.containerElement!==null&&this.containerElement.current!==null){var e=this.containerElement.current.querySelector("input");if(e!==null){var i=new google.maps.places.SearchBox(e,this.props.options);this.registeredEvents=co({updaterMap:she,eventMap:ahe,prevProps:{},nextProps:this.props,instance:i}),this.setState(function(){return{searchBox:i}},this.setSearchBoxCallback)}}}componentDidUpdate(e){this.state.searchBox!==null&&(So(this.registeredEvents),this.registeredEvents=co({updaterMap:she,eventMap:ahe,prevProps:e,nextProps:this.props,instance:this.state.searchBox}))}componentWillUnmount(){this.state.searchBox!==null&&(this.props.onUnmount&&this.props.onUnmount(this.state.searchBox),So(this.registeredEvents))}render(){return L.jsx("div",{ref:this.containerElement,children:J.Children.only(this.props.children)})}}br(WEt,"contextType",Yn);var lhe={onPlaceChanged:"place_changed"},uhe={bounds(t,e){t.setBounds(e)},restrictions(t,e){t.setComponentRestrictions(e)},fields(t,e){t.setFields(e)},options(t,e){t.setOptions(e)},types(t,e){t.setTypes(e)}};class BNe extends J.PureComponent{constructor(){super(...arguments),br(this,"registeredEvents",[]),br(this,"containerElement",J.createRef()),br(this,"state",{autocomplete:null}),br(this,"setAutocompleteCallback",()=>{this.state.autocomplete!==null&&this.props.onLoad&&this.props.onLoad(this.state.autocomplete)})}componentDidMount(){var e;ec(!!google.maps.places,'You need to provide libraries={["places"]} prop to <LoadScript /> component %s',google.maps.places);var i=(e=this.containerElement.current)===null||e===void 0?void 0:e.querySelector("input");if(i){var n=new google.maps.places.Autocomplete(i,this.props.options);this.registeredEvents=co({updaterMap:uhe,eventMap:lhe,prevProps:{},nextProps:this.props,instance:n}),this.setState(()=>({autocomplete:n}),this.setAutocompleteCallback)}}componentDidUpdate(e){So(this.registeredEvents),this.registeredEvents=co({updaterMap:uhe,eventMap:lhe,prevProps:e,nextProps:this.props,instance:this.state.autocomplete})}componentWillUnmount(){this.state.autocomplete!==null&&So(this.registeredEvents)}render(){return L.jsx("div",{ref:this.containerElement,className:this.props.className,children:J.Children.only(this.props.children)})}}br(BNe,"defaultProps",{className:""});br(BNe,"contextType",Yn);const GEt=17,YEt=25,qEt=15,XEt="M 37 12.5 c 0 6.63 -5.37 12 -12 12 s -12 -5.37 -12 -12 S 18.37 0.5 25 0.5 s 12 5.37 12 12 Z";function KEt(t){const e=J.useRef(null),[i,n]=J.useState(!1),[r,o]=J.useState(),{isLoaded:a}=_xt({id:"google-map-script",googleMapsApiKey:t.googleMapsApiKey});J.useEffect(()=>{console.log(`Mounting Google Maps map, ${e.current}`)},[]),J.useEffect(()=>{r!==void 0&&console.error(r,"Double check the settings in the map panel and make sure that the selected latitude and longitude signals correspond to the actual latitude and longitude values.")},[r]);const s=J.useCallback(u=>{const c=new google.maps.LatLngBounds;e.current=u,u.fitBounds(c)},[]);J.useEffect(()=>{if(a){const u=e.current;u&&(t.latitude<=90&&t.longitude<=180?(o(void 0),u.panTo(new google.maps.LatLng(t.latitude,t.longitude))):o("Invalid latitude or longitude signal value"))}},[t.latitude,t.longitude,a]),J.useEffect(()=>{a&&!i&&t.longitude!==181&&t.latitude!==91&&(l(),n(!0))},[a,i,t.latitude,t.longitude]);const l=()=>{if(a){const u=e.current;u&&(u.setCenter(new google.maps.LatLng(t.latitude,t.longitude)),u.setZoom(GEt))}};return L.jsxs(L.Fragment,{children:[a&&L.jsx(uxt,{options:{streetViewControl:!1,mapTypeControl:!1,fullscreenControl:!1},mapContainerClassName:"w-full h-full",onLoad:s,children:L.jsx(ONe,{onClick:()=>{l()},icon:{path:XEt,strokeColor:"white",fillColor:"#4086f5",fillOpacity:1,strokeWeight:3,anchor:new window.google.maps.Point(YEt,qEt),scale:1},position:{lat:t.latitude,lng:t.longitude}})}),!a&&L.jsxs("div",{className:"h-full w-full flex flex-col items-center justify-center",children:[L.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-2 border-primary border-t-transparent"}),L.jsx("p",{className:"mt-2 text-sm text-muted-foreground",children:"Loading map..."})]})]})}function ZEt(t){const e=qt.c(12),i=J.useRef(void 0),n=J.useRef(void 0),[r,o]=J.useState(181),[a,s]=J.useState(91),l=$V();let u;e[0]!==l?(u=()=>(console.debug("Mounted map panel"),()=>{const g=[i.current,n.current].filter(Boolean);g.length>0&&l.removeSubscriptions(g)}),e[0]=l,e[1]=u):u=e[1];let c;e[2]===Symbol.for("react.memo_cache_sentinel")?(c=[],e[2]=c):c=e[2],J.useEffect(u,c);let d,f;if(e[3]!==l||e[4]!==t.latitudeSignal||e[5]!==t.longitudeSignal?(d=()=>{if(t.latitudeSignal&&t.longitudeSignal){const g=[i.current,n.current].filter(Boolean);g.length>0&&l.removeSubscriptions(g);const v=new B3([t.longitudeSignal.id],m=>{const b=m.signals.find(S=>{var _;return S.name===((_=t.longitudeSignal)==null?void 0:_.name)});b&&o(b.value)},QEt);i.current=v.subscriptionId,l.addPendingSubscription(v);const y=new B3([t.latitudeSignal.id],m=>{const b=m.signals.find(S=>{var _;return S.name===((_=t.latitudeSignal)==null?void 0:_.name)});b&&s(b.value)},JEt);n.current=y.subscriptionId,l.addPendingSubscription(y),l.applyPendingSubscriptions()}},f=[t.longitudeSignal,t.latitudeSignal,l],e[3]=l,e[4]=t.latitudeSignal,e[5]=t.longitudeSignal,e[6]=d,e[7]=f):(d=e[6],f=e[7]),J.useEffect(d,f),!(t.latitudeSignal!==void 0&&t.longitudeSignal!==void 0))return null;let p;return e[8]!==a||e[9]!==r||e[10]!==t.googleMapsApiKey?(p=L.jsx("div",{className:"shadow-sm w-full h-full",children:L.jsx(KEt,{latitude:a,longitude:r,googleMapsApiKey:t.googleMapsApiKey})}),e[8]=a,e[9]=r,e[10]=t.googleMapsApiKey,e[11]=p):p=e[11],p}function JEt(){}function QEt(){}const ewt=t=>{try{return typeof window<"u"&&window.location&&new URLSearchParams(window.location.search).has(t)?!0:localStorage.getItem(t)!==null}catch{return!1}},jNe=()=>ewt("DEV_MODE");function twt(t){const e=qt.c(106),i=Qke(t.videoPanelSettings.recordingSessionPath??""),[n,r]=J.useState(),[o,a]=J.useState("0"),[s,l]=J.useState(0),[u,c]=J.useState(!1),[d,f]=J.useState(!1),[h,p]=J.useState(!0),[g,v]=J.useState(),[y,m]=J.useState(!1),b=t.soundMuted!==void 0?t.soundMuted:h,S=t.onSoundMutedChange||p,_=t.testOffset!==void 0?t.testOffset:g,C=t.onTestOffsetChange||v,P=t.showDebugPanel!==void 0?t.showDebugPanel:y,x=t.onShowDebugPanelChange||m,E=J.useRef(null),A=J.useRef(null);let R;e:{if(n&&i){R=isNaN(n.videoPlayerCurrentTimeSecs)?0:n.videoPlayerCurrentTimeSecs;break e}R=0}const M=R;let D;e:{if(n&&i){D=isNaN(n.videoLengthSeconds)?0:n.videoLengthSeconds;break e}D=0}const F=D,I=i==null?void 0:i.recordingSessionInfo.videos;let V;e:{if(!I){V=void 0;break e}let rt;if(e[0]!==t.videoPanelSettings.videoFilePath||e[1]!==I){let vt;e[3]!==t.videoPanelSettings.videoFilePath?(vt=kt=>kt.location===t.videoPanelSettings.videoFilePath,e[3]=t.videoPanelSettings.videoFilePath,e[4]=vt):vt=e[4],rt=I.filter(vt),e[0]=t.videoPanelSettings.videoFilePath,e[1]=I,e[2]=rt}else rt=e[2];const qe=rt;V=qe.length>0?qe[0]:void 0}const z=V,[G,H]=J.useState(z);G!==z&&(H(z),z&&(l(z.offsetMs),a(z.offsetMs.toFixed(2))));const[U,k]=J.useState(s);if(U!==s){k(s);const rt=Math.round(s*100)/100;a(`${rt}`)}let X;e[5]!==z||e[6]!==_?(X=()=>_!==void 0?_:z?Math.round(z.offsetMs/1e3):0,e[5]=z,e[6]=_,e[7]=X):X=e[7];const W=X;let Y;e[8]!==i?(Y=()=>i?i.playbackControls.elapsedTimeMs/1e3:0,e[8]=i,e[9]=Y):Y=e[9];const te=Y,oe=t.onVideoInfoChange,de=t.videoPanelSettings.videoFilePath;let ge,Ee;e[10]!==oe||e[11]!==i||e[12]!==z||e[13]!==_||e[14]!==M||e[15]!==de||e[16]!==F?(ge=()=>{if(oe){const rt=_!==void 0?_:z?Math.round(z.offsetMs/1e3):0,qe=i?i.playbackControls.elapsedTimeMs/1e3:0;oe({videoFilePath:de,offsetSeconds:rt,lengthSeconds:F,currentTimeSeconds:M,hasEnded:qe-rt>=F})}},Ee=[M,F,de,z,i,_,oe],e[10]=oe,e[11]=i,e[12]=z,e[13]=_,e[14]=M,e[15]=de,e[16]=F,e[17]=ge,e[18]=Ee):(ge=e[17],Ee=e[18]),J.useEffect(ge,Ee);let Re,Ae;e[19]!==u?(Re=()=>{const rt=function(vt){E.current&&!E.current.contains(vt.target)&&A.current&&!A.current.contains(vt.target)&&c(!1)};if(u)return document.addEventListener("mousedown",rt),()=>document.removeEventListener("mousedown",rt)},Ae=[u],e[19]=u,e[20]=Re,e[21]=Ae):(Re=e[20],Ae=e[21]),J.useEffect(Re,Ae);let Pe;e[22]!==te||e[23]!==F||e[24]!==W?(Pe=()=>te()-W()>=F,e[22]=te,e[23]=F,e[24]=W,e[25]=Pe):Pe=e[25];const we=Pe;let Te;e[26]!==te?(Te=()=>te()>0,e[26]=te,e[27]=Te):Te=e[27];const ke=Te;let $e,Ne,ve,pe,fe;if(e[28]!==o||e[29]!==te||e[30]!==ke||e[31]!==t||e[32]!==i||e[33]!==x||e[34]!==S||e[35]!==C||e[36]!==P||e[37]!==u||e[38]!==b||e[39]!==d||e[40]!==_||e[41]!==M||e[42]!==we||e[43]!==F||e[44]!==W||e[45]!==n){const rt=()=>L.jsxs("div",{ref:E,className:yo("absolute right-0 top-full mt-1 z-50","min-w-[200px] py-2 px-3","bg-white dark:bg-neutral-800","border border-neutral-200 dark:border-neutral-700","rounded-md shadow-lg"),children:[jNe()&&L.jsxs("div",{className:"flex items-center justify-between py-1",children:[L.jsx("p",{className:"m-0 text-sm font-semibold text-foreground dark:text-neutral-200",children:"Debug mode"}),L.jsx("input",{type:"checkbox",checked:P,onChange:We=>x==null?void 0:x(We.target.checked),className:"w-4 h-4 rounded border-neutral-400 dark:border-neutral-500 text-primary"})]}),P&&L.jsxs(L.Fragment,{children:[L.jsxs("div",{className:"flex items-center justify-between py-1",children:[L.jsx("p",{className:"m-0 text-sm font-semibold text-foreground dark:text-neutral-200",children:"Offset (test only)"}),L.jsxs("div",{className:"flex items-center",children:[L.jsx("button",{className:"p-0.5 bg-transparent border-0 text-primary hover:text-primary/80",title:"Decrease offset",onClick:()=>{const We=_!==void 0?_-.5:W()-.5;C==null||C(We)},children:L.jsx(Mct,{sx:{fontSize:14}})}),L.jsx("p",{className:"mb-0 px-1 text-sm text-foreground dark:text-neutral-200",children:W().toFixed(1)}),L.jsx("button",{className:"p-0.5 bg-transparent border-0 text-primary hover:text-primary/80",title:"Increase offset",onClick:()=>{const We=_!==void 0?_+.5:W()+.5;C==null||C(We)},children:L.jsx(Cct,{sx:{fontSize:14}})})]})]}),L.jsxs("div",{className:"flex items-center justify-between py-1",children:[L.jsx("p",{className:"m-0 text-sm font-semibold text-foreground dark:text-neutral-200",children:"Restore offset"}),L.jsx("button",{onClick:()=>C==null?void 0:C(void 0),className:yo("px-2 py-1 rounded","bg-primary text-primary-foreground text-xs","hover:bg-primary/90"),children:L.jsx(Ect,{sx:{fontSize:14}})})]})]}),L.jsxs("div",{className:"flex items-center justify-between py-1",children:[L.jsx("p",{className:"m-0 text-sm font-semibold text-foreground dark:text-neutral-200",children:"Sound"}),L.jsxs("button",{onClick:()=>S==null?void 0:S(!b),className:yo("px-2 py-1 rounded","bg-primary text-primary-foreground text-xs","hover:bg-primary/90"),children:[!b&&L.jsx(Nct,{sx:{fontSize:16}}),b&&L.jsx(Ict,{sx:{fontSize:16}})]})]})]});let qe;e[51]!==o||e[52]!==i?(qe=()=>L.jsx("div",{className:"flex justify-center",style:{marginTop:2,marginBottom:1,height:35},children:L.jsx("div",{className:"rounded-lg bg-green-100 dark:bg-green-900/30 ps-1 mx-1",style:{marginTop:4,marginBottom:3},children:L.jsxs("div",{className:"flex items-center flex-grow-0 ps-2 pe-0",children:[L.jsx(kct,{sx:{fontSize:17},className:"text-green-600 dark:text-green-400 me-3"}),L.jsx("p",{className:"hidden md:block mb-0 text-sm text-green-800 dark:text-green-300 me-2",children:"To sync, drag video slider or enter seconds"}),L.jsx("p",{className:"block md:hidden mb-0 text-sm text-green-800 dark:text-green-300 me-2",children:"Set delay"}),L.jsx("input",{type:"text",className:yo("w-[50px] px-1 py-1 m-0 ms-1 me-2","bg-white dark:bg-neutral-800","border border-neutral-300 dark:border-neutral-600","rounded text-xs","text-foreground dark:text-neutral-200"),value:o===void 0?"":o,onChange:We=>{console.log("desiredVideoOffsetSecondsInput changed",o);const dt=We.target.value;/^-?\d*[.,]?\d{0,2}$/.test(dt)&&a(dt)}}),L.jsx("button",{disabled:i&&i.playbackControls.isPaused,className:"p-0 bg-transparent border-0 text-neutral-600 dark:text-neutral-400 hover:text-neutral-800 dark:hover:text-neutral-200",style:{paddingRight:0},onClick:()=>{f(!1)},children:L.jsx(uz,{sx:{fontSize:15}})})]})})}),e[51]=o,e[52]=i,e[53]=qe):qe=e[53];const vt=qe;let kt;e[54]!==te||e[55]!==ke||e[56]!==M||e[57]!==F||e[58]!==W?(kt=()=>{if(ke()&&W()-te()>1&&W()>0)return L.jsxs("span",{className:"text-xs m-0 text-foreground dark:text-neutral-200",children:["Starts in ",(W()-te()).toFixed(0),"s"]});const We=`${Hk(M*1e3)} / ${Hk(Math.round(F*1e3))}`;return L.jsx("span",{className:"text-xs m-0 truncate text-foreground dark:text-neutral-200",title:We,children:We})},e[54]=te,e[55]=ke,e[56]=M,e[57]=F,e[58]=W,e[59]=kt):kt=e[59];const Xe=kt;let _t;e[60]!==t.videoPanelSettings.videoFilePath||e[61]!==vt||e[62]!==d||e[63]!==Xe||e[64]!==we||e[65]!==W?(_t=()=>{if(d)return L.jsx(L.Fragment,{children:vt()});const We=we()?"Video has ended":`Offset: ${W()}s`;return L.jsx("div",{className:"flex ps-2 h-full flex-col justify-center items-start",style:{minWidth:0},children:L.jsxs("p",{className:"m-0 text-sm text-left text-foreground dark:text-neutral-200 truncate",title:t.videoPanelSettings.videoFilePath,children:[t.videoPanelSettings.videoFilePath,L.jsxs("span",{className:"flex justify-between",style:{minWidth:0,maxWidth:"300px"},children:[L.jsx("span",{className:"m-0 text-xs text-muted-foreground truncate",title:We,children:We}),Xe()]})]})})},e[60]=t.videoPanelSettings.videoFilePath,e[61]=vt,e[62]=d,e[63]=Xe,e[64]=we,e[65]=W,e[66]=_t):_t=e[66];const Ht=_t;let Pt;e[67]!==n?(Pt=()=>L.jsx("div",{className:"flex items-start truncate",children:L.jsxs("p",{className:"text-xs m-1 p-1 text-left text-foreground dark:text-neutral-200 truncate w-full",children:["Player time: ",(n==null?void 0:n.videoPlayerCurrentTimeSecs)??"N/A",L.jsx("br",{}),"Expected player time: ",(n==null?void 0:n.expectedSecsIntoVideo)??"N/A",L.jsx("br",{}),"Recording time: ",(n==null?void 0:n.recordingElapsedTime)??"N/A",L.jsx("br",{}),"Max allowed drift: ",(n==null?void 0:n.currentMaxDriftSeconds)??"N/A",L.jsx("br",{}),"Current drift:"," ",(n==null?void 0:n.videoPlayerCurrentTimeSecs)!==void 0&&(n==null?void 0:n.expectedSecsIntoVideo)!==void 0?n.videoPlayerCurrentTimeSecs-n.expectedSecsIntoVideo:"N/A",L.jsx("br",{}),"Offset: ",n!=null&&n.currentOffset?n.currentOffset:"N/A"]})}),e[67]=n,e[68]=Pt):Pt=e[68],$e=Pt,Ne=iwt;let Jt;e[69]!==t||e[70]!==d?(Jt=()=>L.jsx(L.Fragment,{children:!d&&L.jsx("button",{onClick:()=>t.removePanelFunction(t.panelKey),className:"p-1 bg-transparent border-0 text-neutral-600 dark:text-neutral-400 hover:text-neutral-800 dark:hover:text-neutral-200 rounded",children:L.jsx(uz,{sx:{fontSize:24}})})}),e[69]=t,e[70]=d,e[71]=Jt):Jt=e[71];const zt=Jt,Bt=()=>L.jsx(L.Fragment,{children:!d&&L.jsxs("div",{className:"relative",children:[L.jsx("button",{ref:A,onClick:()=>c(!u),className:yo("p-1 rounded border-0","bg-neutral-100 dark:bg-neutral-700","text-neutral-600 dark:text-neutral-300","hover:bg-neutral-200 dark:hover:bg-neutral-600"),children:L.jsxs("div",{className:"flex items-center",children:[L.jsx(Lct,{sx:{fontSize:20}}),L.jsx("p",{className:"m-0 ms-1 hidden md:inline lg:hidden text-sm",children:"Settings"}),L.jsx("p",{className:"m-0 ms-1 hidden xl:inline text-sm",children:"Settings"})]})}),u&&rt()]})}),Mr=t.height??400,Be=t.hideHeader&&"pb-0 m-0";e[72]!==Be?(ve=yo("shadow-sm rounded-lg border-0 m-1 mx-0 pb-2","bg-white dark:bg-neutral-900",Be),e[72]=Be,e[73]=ve):ve=e[73],e[74]!==Mr?(pe={height:Mr},e[74]=Mr,e[75]=pe):pe=e[75],fe=!t.hideHeader&&L.jsxs("div",{style:{height:"38px"},className:`flex ${d?"justify-center":"justify-between"} p-0 m-0 flex-nowrap`,children:[L.jsx("div",{className:"flex flex-col overflow-hidden flex-grow",style:{minWidth:"0"},children:Ht()}),L.jsxs("div",{className:"flex items-center flex-nowrap gap-1",children:[Bt(),zt()]})]}),e[28]=o,e[29]=te,e[30]=ke,e[31]=t,e[32]=i,e[33]=x,e[34]=S,e[35]=C,e[36]=P,e[37]=u,e[38]=b,e[39]=d,e[40]=_,e[41]=M,e[42]=we,e[43]=F,e[44]=W,e[45]=n,e[46]=$e,e[47]=Ne,e[48]=ve,e[49]=pe,e[50]=fe}else $e=e[46],Ne=e[47],ve=e[48],pe=e[49],fe=e[50];const me=t.hideHeader?"h-full":"h-[calc(100%-38px)]";let Ce;e[76]!==me?(Ce=yo("flex flex-col",me),e[76]=me,e[77]=Ce):Ce=e[77];let Ue;e[78]!==$e||e[79]!==P?(Ue=P&&$e(),e[78]=$e,e[79]=P,e[80]=Ue):Ue=e[80];let Qe;e[81]!==t.videoPanelSettings.videoFilePath?(Qe=!t.videoPanelSettings.videoFilePath&&L.jsx("p",{children:"Loading video..."}),e[81]=t.videoPanelSettings.videoFilePath,e[82]=Qe):Qe=e[82];let it;e[83]!==s||e[84]!==Ne||e[85]!==i||e[86]!==z||e[87]!==b||e[88]!==d||e[89]!==_?(it=i&&z?L.jsx(R1t,{onVideoLoadedCallback:rwt,playbackState:i,videoFile:z,testOffset:_,videoStatusCallback:r,syncModeEnabled:d,desiredVideoOffsetSecondsSlider:s,setDesiredVideoOffsetSecondsSlider:l,soundMuted:b}):Ne(),e[83]=s,e[84]=Ne,e[85]=i,e[86]=z,e[87]=b,e[88]=d,e[89]=_,e[90]=it):it=e[90];let xt;e[91]!==Qe||e[92]!==it?(xt=L.jsxs("div",{className:"flex-grow overflow-hidden",children:[Qe,it]}),e[91]=Qe,e[92]=it,e[93]=xt):xt=e[93];let wt;e[94]!==Ce||e[95]!==Ue||e[96]!==xt?(wt=L.jsxs("div",{className:Ce,children:[Ue,xt]}),e[94]=Ce,e[95]=Ue,e[96]=xt,e[97]=wt):wt=e[97];let $t;e[98]!==n?($t=(n==null?void 0:n.problemDescription)&&L.jsx("div",{children:L.jsx("p",{className:"m-0 text-xs text-muted-foreground",children:n.problemDescription})}),e[98]=n,e[99]=$t):$t=e[99];let Mt;return e[100]!==ve||e[101]!==pe||e[102]!==fe||e[103]!==wt||e[104]!==$t?(Mt=L.jsxs("div",{className:ve,style:pe,children:[fe,wt,$t]}),e[100]=ve,e[101]=pe,e[102]=fe,e[103]=wt,e[104]=$t,e[105]=Mt):Mt=e[105],Mt}function rwt(){return console.log("Video loaded")}function iwt(){return L.jsx("div",{className:"h-full flex justify-center items-center p-4",children:L.jsx("div",{className:"w-full max-w-md rounded-xl border-2 border-dashed border-neutral-300 dark:border-neutral-600 bg-neutral-100/30 dark:bg-neutral-800/30 flex items-center justify-center p-8",children:L.jsxs("div",{className:"flex flex-col items-center gap-2 text-neutral-600 dark:text-neutral-400",children:[L.jsx("div",{className:"w-12 h-12 rounded-full bg-neutral-200 dark:bg-neutral-700 flex items-center justify-center",children:L.jsx(Rct,{className:"text-neutral-500 dark:text-neutral-400",sx:{fontSize:24}})}),L.jsx("span",{className:"text-sm font-medium text-center",children:"No video available"}),L.jsx("span",{className:"text-xs text-center text-neutral-500 dark:text-neutral-500",children:"Recording session is not open or video has been removed"})]})})})}function lL(t,e,i){let n=i.initialDeps??[],r;function o(){var a,s,l,u;let c;i.key&&((a=i.debug)!=null&&a.call(i))&&(c=Date.now());const d=t();if(!(d.length!==n.length||d.some((p,g)=>n[g]!==p)))return r;n=d;let h;if(i.key&&((s=i.debug)!=null&&s.call(i))&&(h=Date.now()),r=e(...d),i.key&&((l=i.debug)!=null&&l.call(i))){const p=Math.round((Date.now()-c)*100)/100,g=Math.round((Date.now()-h)*100)/100,v=g/16,y=(m,b)=>{for(m=String(m);m.length<b;)m=" "+m;return m};console.info(`%c⏱ ${y(g,5)} /${y(p,5)} ms`,`
            font-size: .6rem;
            font-weight: bold;
            color: hsl(${Math.max(0,Math.min(120-120*v,120))}deg 100% 31%);`,i==null?void 0:i.key)}return(u=i==null?void 0:i.onChange)==null||u.call(i,r),r}return o.updateDeps=a=>{n=a},o}function che(t,e){if(t===void 0)throw new Error("Unexpected undefined");return t}const nwt=(t,e)=>Math.abs(t-e)<1.01,owt=(t,e,i)=>{let n;return function(...r){t.clearTimeout(n),n=t.setTimeout(()=>e.apply(this,r),i)}},dhe=t=>{const{offsetWidth:e,offsetHeight:i}=t;return{width:e,height:i}},awt=t=>t,swt=t=>{const e=Math.max(t.startIndex-t.overscan,0),i=Math.min(t.endIndex+t.overscan,t.count-1),n=[];for(let r=e;r<=i;r++)n.push(r);return n},lwt=(t,e)=>{const i=t.scrollElement;if(!i)return;const n=t.targetWindow;if(!n)return;const r=a=>{const{width:s,height:l}=a;e({width:Math.round(s),height:Math.round(l)})};if(r(dhe(i)),!n.ResizeObserver)return()=>{};const o=new n.ResizeObserver(a=>{const s=()=>{const l=a[0];if(l!=null&&l.borderBoxSize){const u=l.borderBoxSize[0];if(u){r({width:u.inlineSize,height:u.blockSize});return}}r(dhe(i))};t.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(s):s()});return o.observe(i,{box:"border-box"}),()=>{o.unobserve(i)}},fhe={passive:!0},hhe=typeof window>"u"?!0:"onscrollend"in window,uwt=(t,e)=>{const i=t.scrollElement;if(!i)return;const n=t.targetWindow;if(!n)return;let r=0;const o=t.options.useScrollendEvent&&hhe?()=>{}:owt(n,()=>{e(r,!1)},t.options.isScrollingResetDelay),a=c=>()=>{const{horizontal:d,isRtl:f}=t.options;r=d?i.scrollLeft*(f&&-1||1):i.scrollTop,o(),e(r,c)},s=a(!0),l=a(!1);l(),i.addEventListener("scroll",s,fhe);const u=t.options.useScrollendEvent&&hhe;return u&&i.addEventListener("scrollend",l,fhe),()=>{i.removeEventListener("scroll",s),u&&i.removeEventListener("scrollend",l)}},cwt=(t,e,i)=>{if(e!=null&&e.borderBoxSize){const n=e.borderBoxSize[0];if(n)return Math.round(n[i.options.horizontal?"inlineSize":"blockSize"])}return t[i.options.horizontal?"offsetWidth":"offsetHeight"]},dwt=(t,{adjustments:e=0,behavior:i},n)=>{var r,o;const a=t+e;(o=(r=n.scrollElement)==null?void 0:r.scrollTo)==null||o.call(r,{[n.options.horizontal?"left":"top"]:a,behavior:i})};class fwt{constructor(e){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let i=null;const n=()=>i||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:i=new this.targetWindow.ResizeObserver(r=>{r.forEach(o=>{const a=()=>{this._measureElement(o.target,o)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(a):a()})}));return{disconnect:()=>{var r;(r=n())==null||r.disconnect(),i=null},observe:r=>{var o;return(o=n())==null?void 0:o.observe(r,{box:"border-box"})},unobserve:r=>{var o;return(o=n())==null?void 0:o.unobserve(r)}}})(),this.range=null,this.setOptions=i=>{Object.entries(i).forEach(([n,r])=>{typeof r>"u"&&delete i[n]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:awt,rangeExtractor:swt,onChange:()=>{},measureElement:cwt,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...i}},this.notify=i=>{var n,r;(r=(n=this.options).onChange)==null||r.call(n,this,i)},this.maybeNotify=lL(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),i=>{this.notify(i)},{key:!1,debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(i=>i()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var i;const n=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==n){if(this.cleanup(),!n){this.maybeNotify();return}this.scrollElement=n,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((i=this.scrollElement)==null?void 0:i.window)??null,this.elementsCache.forEach(r=>{this.observer.observe(r)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,r=>{this.scrollRect=r,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(r,o)=>{this.scrollAdjustments=0,this.scrollDirection=o?this.getScrollOffset()<r?"forward":"backward":null,this.scrollOffset=r,this.isScrolling=o,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(i,n)=>{const r=new Map,o=new Map;for(let a=n-1;a>=0;a--){const s=i[a];if(r.has(s.lane))continue;const l=o.get(s.lane);if(l==null||s.end>l.end?o.set(s.lane,s):s.end<l.end&&r.set(s.lane,!0),r.size===this.options.lanes)break}return o.size===this.options.lanes?Array.from(o.values()).sort((a,s)=>a.end===s.end?a.index-s.index:a.end-s.end)[0]:void 0},this.getMeasurementOptions=lL(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(i,n,r,o,a)=>(this.pendingMeasuredCacheIndexes=[],{count:i,paddingStart:n,scrollMargin:r,getItemKey:o,enabled:a}),{key:!1}),this.getMeasurements=lL(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:i,paddingStart:n,scrollMargin:r,getItemKey:o,enabled:a},s)=>{if(!a)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(c=>{this.itemSizeCache.set(c.key,c.size)}));const l=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const u=this.measurementsCache.slice(0,l);for(let c=l;c<i;c++){const d=o(c),f=this.options.lanes===1?u[c-1]:this.getFurthestMeasurement(u,c),h=f?f.end+this.options.gap:n+r,p=s.get(d),g=typeof p=="number"?p:this.options.estimateSize(c),v=h+g,y=f?f.lane:c%this.options.lanes;u[c]={index:c,start:h,size:g,end:v,key:d,lane:y}}return this.measurementsCache=u,u},{key:!1,debug:()=>this.options.debug}),this.calculateRange=lL(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(i,n,r,o)=>this.range=i.length>0&&n>0?hwt({measurements:i,outerSize:n,scrollOffset:r,lanes:o}):null,{key:!1,debug:()=>this.options.debug}),this.getVirtualIndexes=lL(()=>{let i=null,n=null;const r=this.calculateRange();return r&&(i=r.startIndex,n=r.endIndex),this.maybeNotify.updateDeps([this.isScrolling,i,n]),[this.options.rangeExtractor,this.options.overscan,this.options.count,i,n]},(i,n,r,o,a)=>o===null||a===null?[]:i({startIndex:o,endIndex:a,overscan:n,count:r}),{key:!1,debug:()=>this.options.debug}),this.indexFromElement=i=>{const n=this.options.indexAttribute,r=i.getAttribute(n);return r?parseInt(r,10):(console.warn(`Missing attribute name '${n}={index}' on measured element.`),-1)},this._measureElement=(i,n)=>{const r=this.indexFromElement(i),o=this.measurementsCache[r];if(!o)return;const a=o.key,s=this.elementsCache.get(a);s!==i&&(s&&this.observer.unobserve(s),this.observer.observe(i),this.elementsCache.set(a,i)),i.isConnected&&this.resizeItem(r,this.options.measureElement(i,n,this))},this.resizeItem=(i,n)=>{const r=this.measurementsCache[i];if(!r)return;const o=this.itemSizeCache.get(r.key)??r.size,a=n-o;a!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(r,a,this):r.start<this.getScrollOffset()+this.scrollAdjustments)&&this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=a,behavior:void 0}),this.pendingMeasuredCacheIndexes.push(r.index),this.itemSizeCache=new Map(this.itemSizeCache.set(r.key,n)),this.notify(!1))},this.measureElement=i=>{if(!i){this.elementsCache.forEach((n,r)=>{n.isConnected||(this.observer.unobserve(n),this.elementsCache.delete(r))});return}this._measureElement(i,void 0)},this.getVirtualItems=lL(()=>[this.getVirtualIndexes(),this.getMeasurements()],(i,n)=>{const r=[];for(let o=0,a=i.length;o<a;o++){const s=i[o],l=n[s];r.push(l)}return r},{key:!1,debug:()=>this.options.debug}),this.getVirtualItemForOffset=i=>{const n=this.getMeasurements();if(n.length!==0)return che(n[VNe(0,n.length-1,r=>che(n[r]).start,i)])},this.getOffsetForAlignment=(i,n,r=0)=>{const o=this.getSize(),a=this.getScrollOffset();n==="auto"&&(n=i>=a+o?"end":"start"),n==="center"?i+=(r-o)/2:n==="end"&&(i-=o);const s=this.getTotalSize()+this.options.scrollMargin-o;return Math.max(Math.min(s,i),0)},this.getOffsetForIndex=(i,n="auto")=>{i=Math.max(0,Math.min(i,this.options.count-1));const r=this.measurementsCache[i];if(!r)return;const o=this.getSize(),a=this.getScrollOffset();if(n==="auto")if(r.end>=a+o-this.options.scrollPaddingEnd)n="end";else if(r.start<=a+this.options.scrollPaddingStart)n="start";else return[a,n];const s=n==="end"?r.end+this.options.scrollPaddingEnd:r.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(s,n,r.size),n]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(i,{align:n="start",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(i,n),{adjustments:void 0,behavior:r})},this.scrollToIndex=(i,{align:n="auto",behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),i=Math.max(0,Math.min(i,this.options.count-1));let o=0;const a=10,s=u=>{if(!this.targetWindow)return;const c=this.getOffsetForIndex(i,u);if(!c){console.warn("Failed to get offset for index:",i);return}const[d,f]=c;this._scrollToOffset(d,{adjustments:void 0,behavior:r}),this.targetWindow.requestAnimationFrame(()=>{const h=this.getScrollOffset(),p=this.getOffsetForIndex(i,f);if(!p){console.warn("Failed to get offset for index:",i);return}nwt(p[0],h)||l(f)})},l=u=>{this.targetWindow&&(o++,o<a?this.targetWindow.requestAnimationFrame(()=>s(u)):console.warn(`Failed to scroll to index ${i} after ${a} attempts.`))};s(n)},this.scrollBy=(i,{behavior:n}={})=>{n==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+i,{adjustments:void 0,behavior:n})},this.getTotalSize=()=>{var i;const n=this.getMeasurements();let r;if(n.length===0)r=this.options.paddingStart;else if(this.options.lanes===1)r=((i=n[n.length-1])==null?void 0:i.end)??0;else{const o=Array(this.options.lanes).fill(null);let a=n.length-1;for(;a>=0&&o.some(s=>s===null);){const s=n[a];o[s.lane]===null&&(o[s.lane]=s.end),a--}r=Math.max(...o.filter(s=>s!==null))}return Math.max(r-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(i,{adjustments:n,behavior:r})=>{this.options.scrollToFn(i,{behavior:r,adjustments:n},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(e)}}const VNe=(t,e,i,n)=>{for(;t<=e;){const r=(t+e)/2|0,o=i(r);if(o<n)t=r+1;else if(o>n)e=r-1;else return r}return t>0?t-1:0};function hwt({measurements:t,outerSize:e,scrollOffset:i,lanes:n}){const r=t.length-1,o=l=>t[l].start;if(t.length<=n)return{startIndex:0,endIndex:r};let a=VNe(0,r,o,i),s=a;if(n===1)for(;s<r&&t[s].end<i+e;)s++;else if(n>1){const l=Array(n).fill(0);for(;s<r&&l.some(c=>c<i+e);){const c=t[s];l[c.lane]=c.end,s++}const u=Array(n).fill(i+e);for(;a>=0&&u.some(c=>c>=i);){const c=t[a];u[c.lane]=c.start,a--}a=Math.max(0,a-a%n),s=Math.min(r,s+(n-1-s%n))}return{startIndex:a,endIndex:s}}const phe=typeof document<"u"?J.useLayoutEffect:J.useEffect;function pwt(t){const e=J.useReducer(()=>({}),{})[1],i={...t,onChange:(r,o)=>{var a;o?zf.flushSync(e):e(),(a=t.onChange)==null||a.call(t,r,o)}},[n]=J.useState(()=>new fwt(i));return n.setOptions(i),phe(()=>n._didMount(),[]),phe(()=>n._willUpdate()),n}function pre(t){return pwt({observeElementRect:lwt,observeElementOffset:uwt,scrollToFn:dwt,...t})}const HNe=(t,e,i)=>({enabled:t,term:ML(e,i)}),ML=(t,e)=>({term:t.trim().toLowerCase(),fields:e});var cj={exports:{}};/**
 * @license
 * Lodash <https://lodash.com/>
 * Copyright OpenJS Foundation and other contributors <https://openjsf.org/>
 * Released under MIT license <https://lodash.com/license>
 * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>
 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors
 */var gwt=cj.exports,ghe;function vwt(){return ghe||(ghe=1,(function(t,e){(function(){var i,n="4.17.23",r=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",s="Invalid `variable` option passed into `_.template`",l="__lodash_hash_undefined__",u=500,c="__lodash_placeholder__",d=1,f=2,h=4,p=1,g=2,v=1,y=2,m=4,b=8,S=16,_=32,C=64,P=128,x=256,E=512,A=30,R="...",M=800,D=16,F=1,I=2,V=3,z=1/0,G=9007199254740991,H=17976931348623157e292,U=NaN,k=4294967295,X=k-1,W=k>>>1,Y=[["ary",P],["bind",v],["bindKey",y],["curry",b],["curryRight",S],["flip",E],["partial",_],["partialRight",C],["rearg",x]],te="[object Arguments]",oe="[object Array]",de="[object AsyncFunction]",ge="[object Boolean]",Ee="[object Date]",Re="[object DOMException]",Ae="[object Error]",Pe="[object Function]",we="[object GeneratorFunction]",Te="[object Map]",ke="[object Number]",$e="[object Null]",Ne="[object Object]",ve="[object Promise]",pe="[object Proxy]",fe="[object RegExp]",me="[object Set]",Ce="[object String]",Ue="[object Symbol]",Qe="[object Undefined]",it="[object WeakMap]",xt="[object WeakSet]",wt="[object ArrayBuffer]",$t="[object DataView]",Mt="[object Float32Array]",rt="[object Float64Array]",qe="[object Int8Array]",vt="[object Int16Array]",kt="[object Int32Array]",Xe="[object Uint8Array]",_t="[object Uint8ClampedArray]",Ht="[object Uint16Array]",Pt="[object Uint32Array]",Jt=/\b__p \+= '';/g,zt=/\b(__p \+=) '' \+/g,Bt=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Mr=/&(?:amp|lt|gt|quot|#39);/g,Be=/[&<>"']/g,We=RegExp(Mr.source),dt=RegExp(Be.source),Tt=/<%-([\s\S]+?)%>/g,nr=/<%([\s\S]+?)%>/g,Ar=/<%=([\s\S]+?)%>/g,Qr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Si=/^\w*$/,oi=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Yr=/[\\^$.*+?()[\]{}|]/g,vi=RegExp(Yr.source),rr=/^\s+/,Ji=/\s/,qn=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ri=/\{\n\/\* \[wrapped with (.+)\] \*/,eo=/,? & /,xn=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,mt=/[()=,{}\[\]\/\s]/,gr=/\\(\\)?/g,ce=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,fr=/\w*$/,Yt=/^[-+]0x[0-9a-f]+$/i,Lr=/^0b[01]+$/i,Cr=/^\[object .+?Constructor\]$/,zr=/^0o[0-7]+$/i,fi=/^(?:0|[1-9]\d*)$/,to=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,st=/($^)/,zo=/['\n\r\u2028\u2029\\]/g,hi="\\ud800-\\udfff",si="\\u0300-\\u036f",sr="\\ufe20-\\ufe2f",Ns="\\u20d0-\\u20ff",ts=si+sr+Ns,Z="\\u2700-\\u27bf",re="a-z\\xdf-\\xf6\\xf8-\\xff",ye="\\xac\\xb1\\xd7\\xf7",Ye="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",gt="\\u2000-\\u206f",Dt=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",pr="A-Z\\xc0-\\xd6\\xd8-\\xde",Gr="\\ufe0e\\ufe0f",rn=ye+Ye+gt+Dt,ro="['’]",na="["+hi+"]",yl="["+rn+"]",Ga="["+ts+"]",ys="\\d+",tc="["+Z+"]",rs="["+re+"]",rc="[^"+hi+rn+ys+Z+re+pr+"]",Hl="\\ud83c[\\udffb-\\udfff]",fu="(?:"+Ga+"|"+Hl+")",hu="[^"+hi+"]",ic="(?:\\ud83c[\\udde6-\\uddff]){2}",rl="[\\ud800-\\udbff][\\udc00-\\udfff]",oa="["+pr+"]",Wd="\\u200d",Ya="(?:"+rs+"|"+rc+")",cd="(?:"+oa+"|"+rc+")",ml="(?:"+ro+"(?:d|ll|m|re|s|t|ve))?",Fs="(?:"+ro+"(?:D|LL|M|RE|S|T|VE))?",Ul=fu+"?",wo="["+Gr+"]?",Ta="(?:"+Wd+"(?:"+[hu,ic,rl].join("|")+")"+wo+Ul+")*",Lo="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ao="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",bl=wo+Ul+Ta,nc="(?:"+[tc,ic,rl].join("|")+")"+bl,Vu="(?:"+[hu+Ga+"?",Ga,ic,rl,na].join("|")+")",dd=RegExp(ro,"g"),xa=RegExp(Ga,"g"),Fa=RegExp(Hl+"(?="+Hl+")|"+Vu+bl,"g"),va=RegExp([oa+"?"+rs+"+"+ml+"(?="+[yl,oa,"$"].join("|")+")",cd+"+"+Fs+"(?="+[yl,oa+Ya,"$"].join("|")+")",oa+"?"+Ya+"+"+ml,oa+"+"+Fs,ao,Lo,ys,nc].join("|"),"g"),Gd=RegExp("["+Wd+hi+ts+Gr+"]"),Oc=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,il=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],aa=-1,Qi={};Qi[Mt]=Qi[rt]=Qi[qe]=Qi[vt]=Qi[kt]=Qi[Xe]=Qi[_t]=Qi[Ht]=Qi[Pt]=!0,Qi[te]=Qi[oe]=Qi[wt]=Qi[ge]=Qi[$t]=Qi[Ee]=Qi[Ae]=Qi[Pe]=Qi[Te]=Qi[ke]=Qi[Ne]=Qi[fe]=Qi[me]=Qi[Ce]=Qi[it]=!1;var mn={};mn[te]=mn[oe]=mn[wt]=mn[$t]=mn[ge]=mn[Ee]=mn[Mt]=mn[rt]=mn[qe]=mn[vt]=mn[kt]=mn[Te]=mn[ke]=mn[Ne]=mn[fe]=mn[me]=mn[Ce]=mn[Ue]=mn[Xe]=mn[_t]=mn[Ht]=mn[Pt]=!0,mn[Ae]=mn[Pe]=mn[it]=!1;var oc={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",Ĳ:"IJ",ĳ:"ij",Œ:"Oe",œ:"oe",ŉ:"'n",ſ:"s"},_e={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},He={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},et={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ht=parseFloat,Ft=parseInt,ur=typeof xp=="object"&&xp&&xp.Object===Object&&xp,Lt=typeof self=="object"&&self&&self.Object===Object&&self,Kt=ur||Lt||Function("return this")(),Zr=e&&!e.nodeType&&e,ni=Zr&&!0&&t&&!t.nodeType&&t,pi=ni&&ni.exports===Zr,Oi=pi&&ur.process,Bi=(function(){try{var ze=ni&&ni.require&&ni.require("util").types;return ze||Oi&&Oi.binding&&Oi.binding("util")}catch{}})(),ms=Bi&&Bi.isArrayBuffer,Ba=Bi&&Bi.isDate,Sl=Bi&&Bi.isMap,zl=Bi&&Bi.isRegExp,Hu=Bi&&Bi.isSet,fd=Bi&&Bi.isTypedArray;function Bs(ze,at,tt){switch(tt.length){case 0:return ze.call(at);case 1:return ze.call(at,tt[0]);case 2:return ze.call(at,tt[0],tt[1]);case 3:return ze.call(at,tt[0],tt[1],tt[2])}return ze.apply(at,tt)}function jg(ze,at,tt,pt){for(var Ut=-1,vr=ze==null?0:ze.length;++Ut<vr;){var Ir=ze[Ut];at(pt,Ir,tt(Ir),ze)}return pt}function js(ze,at){for(var tt=-1,pt=ze==null?0:ze.length;++tt<pt&&at(ze[tt],tt,ze)!==!1;);return ze}function qf(ze,at){for(var tt=ze==null?0:ze.length;tt--&&at(ze[tt],tt,ze)!==!1;);return ze}function hd(ze,at){for(var tt=-1,pt=ze==null?0:ze.length;++tt<pt;)if(!at(ze[tt],tt,ze))return!1;return!0}function is(ze,at){for(var tt=-1,pt=ze==null?0:ze.length,Ut=0,vr=[];++tt<pt;){var Ir=ze[tt];at(Ir,tt,ze)&&(vr[Ut++]=Ir)}return vr}function Xf(ze,at){var tt=ze==null?0:ze.length;return!!tt&&Di(ze,at,0)>-1}function Yd(ze,at,tt){for(var pt=-1,Ut=ze==null?0:ze.length;++pt<Ut;)if(tt(at,ze[pt]))return!0;return!1}function ko(ze,at){for(var tt=-1,pt=ze==null?0:ze.length,Ut=Array(pt);++tt<pt;)Ut[tt]=at(ze[tt],tt,ze);return Ut}function ac(ze,at){for(var tt=-1,pt=at.length,Ut=ze.length;++tt<pt;)ze[Ut+tt]=at[tt];return ze}function Nh(ze,at,tt,pt){var Ut=-1,vr=ze==null?0:ze.length;for(pt&&vr&&(tt=ze[++Ut]);++Ut<vr;)tt=at(tt,ze[Ut],Ut,ze);return tt}function pd(ze,at,tt,pt){var Ut=ze==null?0:ze.length;for(pt&&Ut&&(tt=ze[--Ut]);Ut--;)tt=at(tt,ze[Ut],Ut,ze);return tt}function Fh(ze,at){for(var tt=-1,pt=ze==null?0:ze.length;++tt<pt;)if(at(ze[tt],tt,ze))return!0;return!1}var Vg=sc("length");function Hg(ze){return ze.split("")}function Kf(ze){return ze.match(xn)||[]}function gd(ze,at,tt){var pt;return tt(ze,function(Ut,vr,Ir){if(at(Ut,vr,Ir))return pt=vr,!1}),pt}function Zf(ze,at,tt,pt){for(var Ut=ze.length,vr=tt+(pt?1:-1);pt?vr--:++vr<Ut;)if(at(ze[vr],vr,ze))return vr;return-1}function Di(ze,at,tt){return at===at?Qd(ze,at,tt):Zf(ze,qd,tt)}function Ip(ze,at,tt,pt){for(var Ut=tt-1,vr=ze.length;++Ut<vr;)if(pt(ze[Ut],at))return Ut;return-1}function qd(ze){return ze!==ze}function Xd(ze,at){var tt=ze==null?0:ze.length;return tt?Dc(ze,at)/tt:U}function sc(ze){return function(at){return at==null?i:at[ze]}}function Kd(ze){return function(at){return ze==null?i:ze[at]}}function Jf(ze,at,tt,pt,Ut){return Ut(ze,function(vr,Ir,Nt){tt=pt?(pt=!1,vr):at(tt,vr,Ir,Nt)}),tt}function Bh(ze,at){var tt=ze.length;for(ze.sort(at);tt--;)ze[tt]=ze[tt].value;return ze}function Dc(ze,at){for(var tt,pt=-1,Ut=ze.length;++pt<Ut;){var vr=at(ze[pt]);vr!==i&&(tt=tt===i?vr:tt+vr)}return tt}function Rc(ze,at){for(var tt=-1,pt=Array(ze);++tt<ze;)pt[tt]=at(tt);return pt}function Np(ze,at){return ko(at,function(tt){return[tt,ze[tt]]})}function Mc(ze){return ze&&ze.slice(0,le(ze)+1).replace(rr,"")}function nl(ze){return function(at){return ze(at)}}function jh(ze,at){return ko(at,function(tt){return ze[tt]})}function Zd(ze,at){return ze.has(at)}function Uu(ze,at){for(var tt=-1,pt=ze.length;++tt<pt&&Di(at,ze[tt],0)>-1;);return tt}function Vh(ze,at){for(var tt=ze.length;tt--&&Di(at,ze[tt],0)>-1;);return tt}function Jd(ze,at){for(var tt=ze.length,pt=0;tt--;)ze[tt]===at&&++pt;return pt}var pu=Kd(oc),io=Kd(_e);function gu(ze){return"\\"+et[ze]}function ns(ze,at){return ze==null?i:ze[at]}function os(ze){return Gd.test(ze)}function Hh(ze){return Oc.test(ze)}function Qf(ze){for(var at,tt=[];!(at=ze.next()).done;)tt.push(at.value);return tt}function eh(ze){var at=-1,tt=Array(ze.size);return ze.forEach(function(pt,Ut){tt[++at]=[Ut,pt]}),tt}function Uh(ze,at){return function(tt){return ze(at(tt))}}function zu(ze,at){for(var tt=-1,pt=ze.length,Ut=0,vr=[];++tt<pt;){var Ir=ze[tt];(Ir===at||Ir===c)&&(ze[tt]=c,vr[Ut++]=tt)}return vr}function th(ze){var at=-1,tt=Array(ze.size);return ze.forEach(function(pt){tt[++at]=pt}),tt}function Ug(ze){var at=-1,tt=Array(ze.size);return ze.forEach(function(pt){tt[++at]=[pt,pt]}),tt}function Qd(ze,at,tt){for(var pt=tt-1,Ut=ze.length;++pt<Ut;)if(ze[pt]===at)return pt;return-1}function Fp(ze,at,tt){for(var pt=tt+1;pt--;)if(ze[pt]===at)return pt;return pt}function Lc(ze){return os(ze)?be(ze):Vg(ze)}function Ke(ze){return os(ze)?xe(ze):Hg(ze)}function le(ze){for(var at=ze.length;at--&&Ji.test(ze.charAt(at)););return at}var Se=Kd(He);function be(ze){for(var at=Fa.lastIndex=0;Fa.test(ze);)++at;return at}function xe(ze){return ze.match(Fa)||[]}function Le(ze){return ze.match(va)||[]}var je=(function ze(at){at=at==null?Kt:ct.defaults(Kt.Object(),at,ct.pick(Kt,il));var tt=at.Array,pt=at.Date,Ut=at.Error,vr=at.Function,Ir=at.Math,Nt=at.Object,hr=at.RegExp,Ao=at.String,ho=at.TypeError,$l=tt.prototype,rh=vr.prototype,kc=Nt.prototype,ef=at["__core-js_shared__"],tf=rh.toString,Mn=kc.hasOwnProperty,ya=0,Po=(function(){var B=/[^.]+$/.exec(ef&&ef.keys&&ef.keys.IE_PROTO||"");return B?"Symbol(src)_1."+B:""})(),po=kc.toString,so=tf.call(Nt),_l=Kt._,as=hr("^"+tf.call(Mn).replace(Yr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),rf=pi?at.Buffer:i,Or=at.Symbol,nf=at.Uint8Array,Bp=rf?rf.allocUnsafe:i,Rr=Uh(Nt.getPrototypeOf,Nt),zg=Nt.create,zh=kc.propertyIsEnumerable,Ic=$l.splice,qv=Or?Or.isConcatSpreadable:i,bs=Or?Or.iterator:i,Nc=Or?Or.toStringTag:i,Wl=(function(){try{var B=Jp(Nt,"defineProperty");return B({},"",{}),B}catch{}})(),Tr=at.clearTimeout!==Kt.clearTimeout&&at.clearTimeout,Ln=pt&&pt.now!==Kt.Date.now&&pt.now,vd=at.setTimeout!==Kt.setTimeout&&at.setTimeout,_r=Ir.ceil,_n=Ir.floor,$h=Nt.getOwnPropertySymbols,Xv=rf?rf.isBuffer:i,Pl=at.isFinite,ih=$l.join,nh=Uh(Nt.keys,Nt),ma=Ir.max,ja=Ir.min,Cl=pt.now,vu=at.parseInt,Gl=Ir.random,yu=$l.reverse,mu=Jp(at,"DataView"),Ss=Jp(at,"Map"),jp=Jp(at,"Promise"),yd=Jp(at,"Set"),of=Jp(at,"WeakMap"),oh=Jp(Nt,"create"),Va=of&&new of,lo={},kn=Eu(mu),md=Eu(Ss),bu=Eu(jp),$g=Eu(yd),bd=Eu(of),Wh=Or?Or.prototype:i,ah=Wh?Wh.valueOf:i,af=Wh?Wh.toString:i;function nt(B){if(us(B)&&!on(B)&&!(B instanceof nn)){if(B instanceof Tl)return B;if(Mn.call(B,"__wrapped__"))return l_(B)}return new Tl(B)}var Sd=(function(){function B(){}return function(K){if(!za(K))return{};if(zg)return zg(K);B.prototype=K;var se=new B;return B.prototype=i,se}})();function _d(){}function Tl(B,K){this.__wrapped__=B,this.__actions__=[],this.__chain__=!!K,this.__index__=0,this.__values__=i}nt.templateSettings={escape:Tt,evaluate:nr,interpolate:Ar,variable:"",imports:{_:nt}},nt.prototype=_d.prototype,nt.prototype.constructor=nt,Tl.prototype=Sd(_d.prototype),Tl.prototype.constructor=Tl;function nn(B){this.__wrapped__=B,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=k,this.__views__=[]}function Fc(){var B=new nn(this.__wrapped__);return B.__actions__=Gu(this.__actions__),B.__dir__=this.__dir__,B.__filtered__=this.__filtered__,B.__iteratees__=Gu(this.__iteratees__),B.__takeCount__=this.__takeCount__,B.__views__=Gu(this.__views__),B}function Pd(){if(this.__filtered__){var B=new nn(this);B.__dir__=-1,B.__filtered__=!0}else B=this.clone(),B.__dir__*=-1;return B}function Bc(){var B=this.__wrapped__.value(),K=this.__dir__,se=on(B),De=K<0,Je=se?B.length:0,ut=i2(0,Je,this.__views__),bt=ut.start,Rt=ut.end,Xt=Rt-bt,xr=De?Rt:bt-1,wr=this.__iteratees__,Nr=wr.length,ti=0,mi=ja(Xt,this.__takeCount__);if(!se||!De&&Je==Xt&&mi==Xt)return No(B,this.__actions__);var Gi=[];e:for(;Xt--&&ti<mi;){xr+=K;for(var Vn=-1,Yi=B[xr];++Vn<Nr;){var no=wr[Vn],go=no.iteratee,vf=no.type,Jc=go(Yi);if(vf==I)Yi=Jc;else if(!Jc){if(vf==F)continue e;break e}}Gi[ti++]=Yi}return Gi}nn.prototype=Sd(_d.prototype),nn.prototype.constructor=nn;function jc(B){var K=-1,se=B==null?0:B.length;for(this.clear();++K<se;){var De=B[K];this.set(De[0],De[1])}}function Wg(){this.__data__=oh?oh(null):{},this.size=0}function sh(B){var K=this.has(B)&&delete this.__data__[B];return this.size-=K?1:0,K}function Vp(B){var K=this.__data__;if(oh){var se=K[B];return se===l?i:se}return Mn.call(K,B)?K[B]:i}function sf(B){var K=this.__data__;return oh?K[B]!==i:Mn.call(K,B)}function _s(B,K){var se=this.__data__;return this.size+=this.has(B)?0:1,se[B]=oh&&K===i?l:K,this}jc.prototype.clear=Wg,jc.prototype.delete=sh,jc.prototype.get=Vp,jc.prototype.has=sf,jc.prototype.set=_s;function Su(B){var K=-1,se=B==null?0:B.length;for(this.clear();++K<se;){var De=B[K];this.set(De[0],De[1])}}function Kv(){this.__data__=[],this.size=0}function Fm(B){var K=this.__data__,se=lc(K,B);if(se<0)return!1;var De=K.length-1;return se==De?K.pop():Ic.call(K,se,1),--this.size,!0}function Bm(B){var K=this.__data__,se=lc(K,B);return se<0?i:K[se][1]}function jm(B){return lc(this.__data__,B)>-1}function Ha(B,K){var se=this.__data__,De=lc(se,B);return De<0?(++this.size,se.push([B,K])):se[De][1]=K,this}Su.prototype.clear=Kv,Su.prototype.delete=Fm,Su.prototype.get=Bm,Su.prototype.has=jm,Su.prototype.set=Ha;function $u(B){var K=-1,se=B==null?0:B.length;for(this.clear();++K<se;){var De=B[K];this.set(De[0],De[1])}}function Gh(){this.size=0,this.__data__={hash:new jc,map:new(Ss||Su),string:new jc}}function Yh(B){var K=Km(this,B).delete(B);return this.size-=K?1:0,K}function Gg(B){return Km(this,B).get(B)}function lh(B){return Km(this,B).has(B)}function uh(B,K){var se=Km(this,B),De=se.size;return se.set(B,K),this.size+=se.size==De?0:1,this}$u.prototype.clear=Gh,$u.prototype.delete=Yh,$u.prototype.get=Gg,$u.prototype.has=lh,$u.prototype.set=uh;function lf(B){var K=-1,se=B==null?0:B.length;for(this.__data__=new $u;++K<se;)this.add(B[K])}function Zv(B){return this.__data__.set(B,l),this}function Vm(B){return this.__data__.has(B)}lf.prototype.add=lf.prototype.push=Zv,lf.prototype.has=Vm;function _u(B){var K=this.__data__=new Su(B);this.size=K.size}function uf(){this.__data__=new Su,this.size=0}function Yg(B){var K=this.__data__,se=K.delete(B);return this.size=K.size,se}function Hp(B){return this.__data__.get(B)}function Jv(B){return this.__data__.has(B)}function ch(B,K){var se=this.__data__;if(se instanceof Su){var De=se.__data__;if(!Ss||De.length<r-1)return De.push([B,K]),this.size=++se.size,this;se=this.__data__=new $u(De)}return se.set(B,K),this.size=se.size,this}_u.prototype.clear=uf,_u.prototype.delete=Yg,_u.prototype.get=Hp,_u.prototype.has=Jv,_u.prototype.set=ch;function Up(B,K){var se=on(B),De=!se&&tv(B),Je=!se&&!De&&og(B),ut=!se&&!De&&!Je&&ag(B),bt=se||De||Je||ut,Rt=bt?Rc(B.length,Ao):[],Xt=Rt.length;for(var xr in B)(K||Mn.call(B,xr))&&!(bt&&(xr=="length"||Je&&(xr=="offset"||xr=="parent")||ut&&(xr=="buffer"||xr=="byteLength"||xr=="byteOffset")||ff(xr,Xt)))&&Rt.push(xr);return Rt}function qh(B){var K=B.length;return K?B[Oe(0,K-1)]:i}function Xh(B,K){return n0(Gu(B),xl(K,0,B.length))}function Qv(B){return n0(Gu(B))}function zp(B,K,se){(se!==i&&!Xc(B[K],se)||se===i&&!(K in B))&&Yl(B,K,se)}function Pu(B,K,se){var De=B[K];(!(Mn.call(B,K)&&Xc(De,se))||se===i&&!(K in B))&&Yl(B,K,se)}function lc(B,K){for(var se=B.length;se--;)if(Xc(B[se][0],K))return se;return-1}function ey(B,K,se,De){return uc(B,function(Je,ut,bt){K(De,Je,se(Je),bt)}),De}function qg(B,K){return B&&wd(K,Rl(K),B)}function Vc(B,K){return B&&wd(K,bc(K),B)}function Yl(B,K,se){K=="__proto__"&&Wl?Wl(B,K,{configurable:!0,enumerable:!0,value:se,writable:!0}):B[K]=se}function dh(B,K){for(var se=-1,De=K.length,Je=tt(De),ut=B==null;++se<De;)Je[se]=ut?i:sg(B,K[se]);return Je}function xl(B,K,se){return B===B&&(se!==i&&(B=B<=se?B:se),K!==i&&(B=B>=K?B:K)),B}function Vs(B,K,se,De,Je,ut){var bt,Rt=K&d,Xt=K&f,xr=K&h;if(se&&(bt=Je?se(B,De,Je,ut):se(B)),bt!==i)return bt;if(!za(B))return B;var wr=on(B);if(wr){if(bt=wR(B),!Rt)return Gu(B,bt)}else{var Nr=Xl(B),ti=Nr==Pe||Nr==we;if(og(B))return sC(B,Rt);if(Nr==Ne||Nr==te||ti&&!Je){if(bt=Xt||ti?{}:_C(B),!Rt)return Xt?PR(B,Vc(bt,B)):_R(B,qg(bt,B))}else{if(!mn[Nr])return Je?B:{};bt=AR(B,Nr,Rt)}}ut||(ut=new _u);var mi=ut.get(B);if(mi)return mi;ut.set(B,bt),S0(B)?B.forEach(function(Yi){bt.add(Vs(Yi,K,se,Yi,B,ut))}):cM(B)&&B.forEach(function(Yi,no){bt.set(no,Vs(Yi,K,se,no,B,ut))});var Gi=xr?Xt?SC:e_:Xt?bc:Rl,Vn=wr?i:Gi(B);return js(Vn||B,function(Yi,no){Vn&&(no=Yi,Yi=B[no]),Pu(bt,no,Vs(Yi,K,se,no,B,ut))}),bt}function ty(B){var K=Rl(B);return function(se){return Cd(se,B,K)}}function Cd(B,K,se){var De=se.length;if(B==null)return!De;for(B=Nt(B);De--;){var Je=se[De],ut=K[Je],bt=B[Je];if(bt===i&&!(Je in B)||!ut(bt))return!1}return!0}function $p(B,K,se){if(typeof B!="function")throw new ho(a);return i0(function(){B.apply(i,se)},K)}function Cu(B,K,se,De){var Je=-1,ut=Xf,bt=!0,Rt=B.length,Xt=[],xr=K.length;if(!Rt)return Xt;se&&(K=ko(K,nl(se))),De?(ut=Yd,bt=!1):K.length>=r&&(ut=Zd,bt=!1,K=new lf(K));e:for(;++Je<Rt;){var wr=B[Je],Nr=se==null?wr:se(wr);if(wr=De||wr!==0?wr:0,bt&&Nr===Nr){for(var ti=xr;ti--;)if(K[ti]===Nr)continue e;Xt.push(wr)}else ut(K,Nr,De)||Xt.push(wr)}return Xt}var uc=dC(Wu),Wp=dC(Yp,!0);function Td(B,K){var se=!0;return uc(B,function(De,Je,ut){return se=!!K(De,Je,ut),se}),se}function Tu(B,K,se){for(var De=-1,Je=B.length;++De<Je;){var ut=B[De],bt=K(ut);if(bt!=null&&(Rt===i?bt===bt&&!mc(bt):se(bt,Rt)))var Rt=bt,Xt=ut}return Xt}function fh(B,K,se,De){var Je=B.length;for(se=Wi(se),se<0&&(se=-se>Je?0:Je+se),De=De===i||De>Je?Je:Wi(De),De<0&&(De+=Je),De=se>De?0:aT(De);se<De;)B[se++]=K;return B}function Gp(B,K){var se=[];return uc(B,function(De,Je,ut){K(De,Je,ut)&&se.push(De)}),se}function Ua(B,K,se,De,Je){var ut=-1,bt=B.length;for(se||(se=CC),Je||(Je=[]);++ut<bt;){var Rt=B[ut];K>0&&se(Rt)?K>1?Ua(Rt,K-1,se,De,Je):ac(Je,Rt):De||(Je[Je.length]=Rt)}return Je}var xd=fC(),hh=fC(!0);function Wu(B,K){return B&&xd(B,K,Rl)}function Yp(B,K){return B&&hh(B,K,Rl)}function Hc(B,K){return is(K,function(se){return Kc(B[se])})}function cc(B,K){K=In(K,B);for(var se=0,De=K.length;B!=null&&se<De;)B=B[fc(K[se++])];return se&&se==De?B:i}function Xg(B,K,se){var De=K(B);return on(B)?De:ac(De,se(B))}function Ps(B){return B==null?B===i?Qe:$e:Nc&&Nc in Nt(B)?Zm(B):xC(B)}function Kh(B,K){return B>K}function ql(B,K){return B!=null&&Mn.call(B,K)}function El(B,K){return B!=null&&K in Nt(B)}function Uc(B,K,se){return B>=ja(K,se)&&B<ma(K,se)}function ph(B,K,se){for(var De=se?Yd:Xf,Je=B[0].length,ut=B.length,bt=ut,Rt=tt(ut),Xt=1/0,xr=[];bt--;){var wr=B[bt];bt&&K&&(wr=ko(wr,nl(K))),Xt=ja(wr.length,Xt),Rt[bt]=!se&&(K||Je>=120&&wr.length>=120)?new lf(bt&&wr):i}wr=B[0];var Nr=-1,ti=Rt[0];e:for(;++Nr<Je&&xr.length<Xt;){var mi=wr[Nr],Gi=K?K(mi):mi;if(mi=se||mi!==0?mi:0,!(ti?Zd(ti,Gi):De(xr,Gi,se))){for(bt=ut;--bt;){var Vn=Rt[bt];if(!(Vn?Zd(Vn,Gi):De(B[bt],Gi,se)))continue e}ti&&ti.push(Gi),xr.push(mi)}}return xr}function qp(B,K,se,De){return Wu(B,function(Je,ut,bt){K(De,se(Je),ut,bt)}),De}function wl(B,K,se){K=In(K,B),B=t0(B,K);var De=B==null?B:B[fc(Aa(K))];return De==null?i:Bs(De,B,se)}function ol(B){return us(B)&&Ps(B)==te}function Ea(B){return us(B)&&Ps(B)==wt}function Io(B){return us(B)&&Ps(B)==Ee}function Al(B,K,se,De,Je){return B===K?!0:B==null||K==null||!us(B)&&!us(K)?B!==B&&K!==K:xi(B,K,se,De,Al,Je)}function xi(B,K,se,De,Je,ut){var bt=on(B),Rt=on(K),Xt=bt?oe:Xl(B),xr=Rt?oe:Xl(K);Xt=Xt==te?Ne:Xt,xr=xr==te?Ne:xr;var wr=Xt==Ne,Nr=xr==Ne,ti=Xt==xr;if(ti&&og(B)){if(!og(K))return!1;bt=!0,wr=!1}if(ti&&!wr)return ut||(ut=new _u),bt||ag(B)?qm(B,K,se,De,Je,ut):ER(B,K,Xt,se,De,Je,ut);if(!(se&p)){var mi=wr&&Mn.call(B,"__wrapped__"),Gi=Nr&&Mn.call(K,"__wrapped__");if(mi||Gi){var Vn=mi?B.value():B,Yi=Gi?K.value():K;return ut||(ut=new _u),Je(Vn,Yi,se,De,ut)}}return ti?(ut||(ut=new _u),bC(B,K,se,De,Je,ut)):!1}function yi(B){return us(B)&&Xl(B)==Te}function Xo(B,K,se,De){var Je=se.length,ut=Je,bt=!De;if(B==null)return!ut;for(B=Nt(B);Je--;){var Rt=se[Je];if(bt&&Rt[2]?Rt[1]!==B[Rt[0]]:!(Rt[0]in B))return!1}for(;++Je<ut;){Rt=se[Je];var Xt=Rt[0],xr=B[Xt],wr=Rt[1];if(bt&&Rt[2]){if(xr===i&&!(Xt in B))return!1}else{var Nr=new _u;if(De)var ti=De(xr,wr,Xt,B,K,Nr);if(!(ti===i?Al(wr,xr,p|g,De,Nr):ti))return!1}}return!0}function Cs(B){if(!za(B)||OR(B))return!1;var K=Kc(B)?as:Cr;return K.test(Eu(B))}function Ol(B){return us(B)&&Ps(B)==fe}function zc(B){return us(B)&&Xl(B)==me}function Ed(B){return us(B)&&__(B.length)&&!!Qi[Ps(B)]}function cf(B){return typeof B=="function"?B:B==null?qu:typeof B=="object"?on(B)?Xp(B[0],B[1]):Zh(B):ot(B)}function $c(B){if(!oy(B))return nh(B);var K=[];for(var se in Nt(B))Mn.call(B,se)&&se!="constructor"&&K.push(se);return K}function ry(B){if(!za(B))return Jh(B);var K=oy(B),se=[];for(var De in B)De=="constructor"&&(K||!Mn.call(B,De))||se.push(De);return se}function Ko(B,K){return B<K}function df(B,K){var se=-1,De=yc(B)?tt(B.length):[];return uc(B,function(Je,ut,bt){De[++se]=K(Je,ut,bt)}),De}function Zh(B){var K=t_(B);return K.length==1&&K[0][2]?a_(K[0][0],K[0][1]):function(se){return se===B||Xo(se,B,K)}}function Xp(B,K){return Qm(B)&&vh(K)?a_(fc(B),K):function(se){var De=sg(se,B);return De===i&&De===K?lT(se,B):Al(K,De,p|g)}}function Wc(B,K,se,De,Je){B!==K&&xd(K,function(ut,bt){if(Je||(Je=new _u),za(ut))$(B,K,bt,se,Wc,De,Je);else{var Rt=De?De(la(B,bt),ut,bt+"",B,K,Je):i;Rt===i&&(Rt=ut),zp(B,bt,Rt)}},bc)}function $(B,K,se,De,Je,ut,bt){var Rt=la(B,se),Xt=la(K,se),xr=bt.get(Xt);if(xr){zp(B,se,xr);return}var wr=ut?ut(Rt,Xt,se+"",B,K,bt):i,Nr=wr===i;if(Nr){var ti=on(Xt),mi=!ti&&og(Xt),Gi=!ti&&!mi&&ag(Xt);wr=Xt,ti||mi||Gi?on(Rt)?wr=Rt:Ts(Rt)?wr=Gu(Rt):mi?(Nr=!1,wr=sC(Xt,!0)):Gi?(Nr=!1,wr=lC(Xt,!0)):wr=[]:m0(Xt)||tv(Xt)?(wr=Rt,tv(Rt)?wr=P_(Rt):(!za(Rt)||Kc(Rt))&&(wr=_C(Xt))):Nr=!1}Nr&&(bt.set(Xt,wr),Je(wr,Xt,De,ut,bt),bt.delete(Xt)),zp(B,se,wr)}function ee(B,K){var se=B.length;if(se)return K+=K<0?se:0,ff(K,se)?B[K]:i}function ae(B,K,se){K.length?K=ko(K,function(ut){return on(ut)?function(bt){return cc(bt,ut.length===1?ut[0]:ut)}:ut}):K=[qu];var De=-1;K=ko(K,nl(Mi()));var Je=df(B,function(ut,bt,Rt){var Xt=ko(K,function(xr){return xr(ut)});return{criteria:Xt,index:++De,value:ut}});return Bh(Je,function(ut,bt){return SR(ut,bt,se)})}function O(B,K){return j(B,K,function(se,De){return lT(B,De)})}function j(B,K,se){for(var De=-1,Je=K.length,ut={};++De<Je;){var bt=K[De],Rt=cc(B,bt);se(Rt,bt)&&jt(ut,In(bt,B),Rt)}return ut}function Q(B){return function(K){return cc(K,B)}}function ie(B,K,se,De){var Je=De?Ip:Di,ut=-1,bt=K.length,Rt=B;for(B===K&&(K=Gu(K)),se&&(Rt=ko(B,nl(se)));++ut<bt;)for(var Xt=0,xr=K[ut],wr=se?se(xr):xr;(Xt=Je(Rt,wr,Xt,De))>-1;)Rt!==B&&Ic.call(Rt,Xt,1),Ic.call(B,Xt,1);return B}function he(B,K){for(var se=B?K.length:0,De=se-1;se--;){var Je=K[se];if(se==De||Je!==ut){var ut=Je;ff(Je)?Ic.call(B,Je,1):Ai(B,Je)}}return B}function Oe(B,K){return B+_n(Gl()*(K-B+1))}function Fe(B,K,se,De){for(var Je=-1,ut=ma(_r((K-B)/(se||1)),0),bt=tt(ut);ut--;)bt[De?ut:++Je]=B,B+=se;return bt}function Ge(B,K){var se="";if(!B||K<1||K>G)return se;do K%2&&(se+=B),K=_n(K/2),K&&(B+=B);while(K);return se}function lt(B,K){return s_(EC(B,K,qu),B+"")}function Ot(B){return qh(by(B))}function St(B,K){var se=by(B);return n0(se,xl(K,0,se.length))}function jt(B,K,se,De){if(!za(B))return B;K=In(K,B);for(var Je=-1,ut=K.length,bt=ut-1,Rt=B;Rt!=null&&++Je<ut;){var Xt=fc(K[Je]),xr=se;if(Xt==="__proto__"||Xt==="constructor"||Xt==="prototype")return B;if(Je!=bt){var wr=Rt[Xt];xr=De?De(wr,Xt,Rt):i,xr===i&&(xr=za(wr)?wr:ff(K[Je+1])?[]:{})}Pu(Rt,Xt,xr),Rt=Rt[Xt]}return B}var cr=Va?function(B,K){return Va.set(B,K),B}:qu,or=Wl?function(B,K){return Wl(B,"toString",{configurable:!0,enumerable:!1,value:_y(K),writable:!0})}:qu;function mr(B){return n0(by(B))}function Vr(B,K,se){var De=-1,Je=B.length;K<0&&(K=-K>Je?0:Je+K),se=se>Je?Je:se,se<0&&(se+=Je),Je=K>se?0:se-K>>>0,K>>>=0;for(var ut=tt(Je);++De<Je;)ut[De]=B[De+K];return ut}function ei(B,K){var se;return uc(B,function(De,Je,ut){return se=K(De,Je,ut),!se}),!!se}function ui(B,K,se){var De=0,Je=B==null?De:B.length;if(typeof K=="number"&&K===K&&Je<=W){for(;De<Je;){var ut=De+Je>>>1,bt=B[ut];bt!==null&&!mc(bt)&&(se?bt<=K:bt<K)?De=ut+1:Je=ut}return Je}return Ei(B,K,qu,se)}function Ei(B,K,se,De){var Je=0,ut=B==null?0:B.length;if(ut===0)return 0;K=se(K);for(var bt=K!==K,Rt=K===null,Xt=mc(K),xr=K===i;Je<ut;){var wr=_n((Je+ut)/2),Nr=se(B[wr]),ti=Nr!==i,mi=Nr===null,Gi=Nr===Nr,Vn=mc(Nr);if(bt)var Yi=De||Gi;else xr?Yi=Gi&&(De||ti):Rt?Yi=Gi&&ti&&(De||!mi):Xt?Yi=Gi&&ti&&!mi&&(De||!Vn):mi||Vn?Yi=!1:Yi=De?Nr<=K:Nr<K;Yi?Je=wr+1:ut=wr}return ja(ut,X)}function jr(B,K){for(var se=-1,De=B.length,Je=0,ut=[];++se<De;){var bt=B[se],Rt=K?K(bt):bt;if(!se||!Xc(Rt,Xt)){var Xt=Rt;ut[Je++]=bt===0?0:bt}}return ut}function cn(B){return typeof B=="number"?B:mc(B)?U:+B}function ji(B){if(typeof B=="string")return B;if(on(B))return ko(B,ji)+"";if(mc(B))return af?af.call(B):"";var K=B+"";return K=="0"&&1/B==-z?"-0":K}function Kr(B,K,se){var De=-1,Je=Xf,ut=B.length,bt=!0,Rt=[],Xt=Rt;if(se)bt=!1,Je=Yd;else if(ut>=r){var xr=K?null:TR(B);if(xr)return th(xr);bt=!1,Je=Zd,Xt=new lf}else Xt=K?[]:Rt;e:for(;++De<ut;){var wr=B[De],Nr=K?K(wr):wr;if(wr=se||wr!==0?wr:0,bt&&Nr===Nr){for(var ti=Xt.length;ti--;)if(Xt[ti]===Nr)continue e;K&&Xt.push(Nr),Rt.push(wr)}else Je(Xt,Nr,se)||(Xt!==Rt&&Xt.push(Nr),Rt.push(wr))}return Rt}function Ai(B,K){K=In(K,B);var se=-1,De=K.length;if(!De)return!0;for(var Je=B==null||typeof B!="object"&&typeof B!="function";++se<De;){var ut=K[se];if(typeof ut=="string"){if(ut==="__proto__"&&!Mn.call(B,"__proto__"))return!1;if(ut==="constructor"&&se+1<De&&typeof K[se+1]=="string"&&K[se+1]==="prototype"){if(Je&&se===0)continue;return!1}}}var bt=t0(B,K);return bt==null||delete bt[fc(Aa(K))]}function qa(B,K,se,De){return jt(B,K,se(cc(B,K)),De)}function sa(B,K,se,De){for(var Je=B.length,ut=De?Je:-1;(De?ut--:++ut<Je)&&K(B[ut],ut,B););return se?Vr(B,De?0:ut,De?ut+1:Je):Vr(B,De?ut+1:0,De?Je:ut)}function No(B,K){var se=B;return se instanceof nn&&(se=se.value()),Nh(K,function(De,Je){return Je.func.apply(Je.thisArg,ac([De],Je.args))},se)}function al(B,K,se){var De=B.length;if(De<2)return De?Kr(B[0]):[];for(var Je=-1,ut=tt(De);++Je<De;)for(var bt=B[Je],Rt=-1;++Rt<De;)Rt!=Je&&(ut[Je]=Cu(ut[Je]||bt,B[Rt],K,se));return Kr(Ua(ut,1),K,se)}function pn(B,K,se){for(var De=-1,Je=B.length,ut=K.length,bt={};++De<Je;){var Rt=De<ut?K[De]:i;se(bt,B[De],Rt)}return bt}function sl(B){return Ts(B)?B:[]}function Hs(B){return typeof B=="function"?B:qu}function In(B,K){return on(B)?B:Qm(B,K)?[B]:wC(Fo(B))}var dc=lt;function ss(B,K,se){var De=B.length;return se=se===i?De:se,!K&&se>=De?B:Vr(B,K,se)}var Hm=Tr||function(B){return Kt.clearTimeout(B)};function sC(B,K){if(K)return B.slice();var se=B.length,De=Bp?Bp(se):new B.constructor(se);return B.copy(De),De}function Um(B){var K=new B.constructor(B.byteLength);return new nf(K).set(new nf(B)),K}function t2(B,K){var se=K?Um(B.buffer):B.buffer;return new B.constructor(se,B.byteOffset,B.byteLength)}function mR(B){var K=new B.constructor(B.source,fr.exec(B));return K.lastIndex=B.lastIndex,K}function bR(B){return ah?Nt(ah.call(B)):{}}function lC(B,K){var se=K?Um(B.buffer):B.buffer;return new B.constructor(se,B.byteOffset,B.length)}function uC(B,K){if(B!==K){var se=B!==i,De=B===null,Je=B===B,ut=mc(B),bt=K!==i,Rt=K===null,Xt=K===K,xr=mc(K);if(!Rt&&!xr&&!ut&&B>K||ut&&bt&&Xt&&!Rt&&!xr||De&&bt&&Xt||!se&&Xt||!Je)return 1;if(!De&&!ut&&!xr&&B<K||xr&&se&&Je&&!De&&!ut||Rt&&se&&Je||!bt&&Je||!Xt)return-1}return 0}function SR(B,K,se){for(var De=-1,Je=B.criteria,ut=K.criteria,bt=Je.length,Rt=se.length;++De<bt;){var Xt=uC(Je[De],ut[De]);if(Xt){if(De>=Rt)return Xt;var xr=se[De];return Xt*(xr=="desc"?-1:1)}}return B.index-K.index}function XS(B,K,se,De){for(var Je=-1,ut=B.length,bt=se.length,Rt=-1,Xt=K.length,xr=ma(ut-bt,0),wr=tt(Xt+xr),Nr=!De;++Rt<Xt;)wr[Rt]=K[Rt];for(;++Je<bt;)(Nr||Je<ut)&&(wr[se[Je]]=B[Je]);for(;xr--;)wr[Rt++]=B[Je++];return wr}function cC(B,K,se,De){for(var Je=-1,ut=B.length,bt=-1,Rt=se.length,Xt=-1,xr=K.length,wr=ma(ut-Rt,0),Nr=tt(wr+xr),ti=!De;++Je<wr;)Nr[Je]=B[Je];for(var mi=Je;++Xt<xr;)Nr[mi+Xt]=K[Xt];for(;++bt<Rt;)(ti||Je<ut)&&(Nr[mi+se[bt]]=B[Je++]);return Nr}function Gu(B,K){var se=-1,De=B.length;for(K||(K=tt(De));++se<De;)K[se]=B[se];return K}function wd(B,K,se,De){var Je=!se;se||(se={});for(var ut=-1,bt=K.length;++ut<bt;){var Rt=K[ut],Xt=De?De(se[Rt],B[Rt],Rt,se,B):i;Xt===i&&(Xt=B[Rt]),Je?Yl(se,Rt,Xt):Pu(se,Rt,Xt)}return se}function _R(B,K){return wd(B,r_(B),K)}function PR(B,K){return wd(B,Jm(B),K)}function KS(B,K){return function(se,De){var Je=on(se)?jg:ey,ut=K?K():{};return Je(se,B,Mi(De,2),ut)}}function Kp(B){return lt(function(K,se){var De=-1,Je=se.length,ut=Je>1?se[Je-1]:i,bt=Je>2?se[2]:i;for(ut=B.length>3&&typeof ut=="function"?(Je--,ut):i,bt&&xu(se[0],se[1],bt)&&(ut=Je<3?i:ut,Je=1),K=Nt(K);++De<Je;){var Rt=se[De];Rt&&B(K,Rt,De,ut)}return K})}function dC(B,K){return function(se,De){if(se==null)return se;if(!yc(se))return B(se,De);for(var Je=se.length,ut=K?Je:-1,bt=Nt(se);(K?ut--:++ut<Je)&&De(bt[ut],ut,bt)!==!1;);return se}}function fC(B){return function(K,se,De){for(var Je=-1,ut=Nt(K),bt=De(K),Rt=bt.length;Rt--;){var Xt=bt[B?Rt:++Je];if(se(ut[Xt],Xt,ut)===!1)break}return K}}function hC(B,K,se){var De=K&v,Je=zm(B);function ut(){var bt=this&&this!==Kt&&this instanceof ut?Je:B;return bt.apply(De?se:this,arguments)}return ut}function pC(B){return function(K){K=Fo(K);var se=os(K)?Ke(K):i,De=se?se[0]:K.charAt(0),Je=se?ss(se,1).join(""):K.slice(1);return De[B]()+Je}}function Kg(B){return function(K){return Nh(FM(Sy(K).replace(dd,"")),B,"")}}function zm(B){return function(){var K=arguments;switch(K.length){case 0:return new B;case 1:return new B(K[0]);case 2:return new B(K[0],K[1]);case 3:return new B(K[0],K[1],K[2]);case 4:return new B(K[0],K[1],K[2],K[3]);case 5:return new B(K[0],K[1],K[2],K[3],K[4]);case 6:return new B(K[0],K[1],K[2],K[3],K[4],K[5]);case 7:return new B(K[0],K[1],K[2],K[3],K[4],K[5],K[6])}var se=Sd(B.prototype),De=B.apply(se,K);return za(De)?De:se}}function r2(B,K,se){var De=zm(B);function Je(){for(var ut=arguments.length,bt=tt(ut),Rt=ut,Xt=ls(Je);Rt--;)bt[Rt]=arguments[Rt];var xr=ut<3&&bt[0]!==Xt&&bt[ut-1]!==Xt?[]:zu(bt,Xt);if(ut-=xr.length,ut<se)return QS(B,K,ny,Je.placeholder,i,bt,xr,i,i,se-ut);var wr=this&&this!==Kt&&this instanceof Je?De:B;return Bs(wr,this,bt)}return Je}function gC(B){return function(K,se,De){var Je=Nt(K);if(!yc(K)){var ut=Mi(se,3);K=Rl(K),se=function(Rt){return ut(Je[Rt],Rt,Je)}}var bt=B(K,se,De);return bt>-1?Je[ut?K[bt]:bt]:i}}function iy(B){return gh(function(K){var se=K.length,De=se,Je=Tl.prototype.thru;for(B&&K.reverse();De--;){var ut=K[De];if(typeof ut!="function")throw new ho(a);if(Je&&!bt&&Xa(ut)=="wrapper")var bt=new Tl([],!0)}for(De=bt?De:se;++De<se;){ut=K[De];var Rt=Xa(ut),Xt=Rt=="wrapper"?Xm(ut):i;Xt&&e0(Xt[0])&&Xt[1]==(P|b|_|x)&&!Xt[4].length&&Xt[9]==1?bt=bt[Xa(Xt[0])].apply(bt,Xt[3]):bt=ut.length==1&&e0(ut)?bt[Rt]():bt.thru(ut)}return function(){var xr=arguments,wr=xr[0];if(bt&&xr.length==1&&on(wr))return bt.plant(wr).value();for(var Nr=0,ti=se?K[Nr].apply(this,xr):wr;++Nr<se;)ti=K[Nr].call(this,ti);return ti}})}function ny(B,K,se,De,Je,ut,bt,Rt,Xt,xr){var wr=K&P,Nr=K&v,ti=K&y,mi=K&(b|S),Gi=K&E,Vn=ti?i:zm(B);function Yi(){for(var no=arguments.length,go=tt(no),vf=no;vf--;)go[vf]=arguments[vf];if(mi)var Jc=ls(Yi),yf=Jd(go,Jc);if(De&&(go=XS(go,De,Je,mi)),ut&&(go=cC(go,ut,bt,mi)),no-=yf,mi&&no<xr){var ul=zu(go,Jc);return QS(B,K,ny,Yi.placeholder,se,go,ul,Rt,Xt,xr-no)}var sp=Nr?se:this,iv=ti?sp[B]:B;return no=go.length,Rt?go=r0(go,Rt):Gi&&no>1&&go.reverse(),wr&&Xt<no&&(go.length=Xt),this&&this!==Kt&&this instanceof Yi&&(iv=Vn||zm(iv)),iv.apply(sp,go)}return Yi}function $m(B,K){return function(se,De){return qp(se,B,K(De),{})}}function Wm(B,K){return function(se,De){var Je;if(se===i&&De===i)return K;if(se!==i&&(Je=se),De!==i){if(Je===i)return De;typeof se=="string"||typeof De=="string"?(se=ji(se),De=ji(De)):(se=cn(se),De=cn(De)),Je=B(se,De)}return Je}}function ZS(B){return gh(function(K){return K=ko(K,nl(Mi())),lt(function(se){var De=this;return B(K,function(Je){return Bs(Je,De,se)})})})}function Zp(B,K){K=K===i?" ":ji(K);var se=K.length;if(se<2)return se?Ge(K,B):K;var De=Ge(K,_r(B/Lc(K)));return os(K)?ss(Ke(De),0,B).join(""):De.slice(0,B)}function CR(B,K,se,De){var Je=K&v,ut=zm(B);function bt(){for(var Rt=-1,Xt=arguments.length,xr=-1,wr=De.length,Nr=tt(wr+Xt),ti=this&&this!==Kt&&this instanceof bt?ut:B;++xr<wr;)Nr[xr]=De[xr];for(;Xt--;)Nr[xr++]=arguments[++Rt];return Bs(ti,Je?se:this,Nr)}return bt}function JS(B){return function(K,se,De){return De&&typeof De!="number"&&xu(K,se,De)&&(se=De=i),K=op(K),se===i?(se=K,K=0):se=op(se),De=De===i?K<se?1:-1:op(De),Fe(K,se,De,B)}}function Gm(B){return function(K,se){return typeof K=="string"&&typeof se=="string"||(K=Zc(K),se=Zc(se)),B(K,se)}}function QS(B,K,se,De,Je,ut,bt,Rt,Xt,xr){var wr=K&b,Nr=wr?bt:i,ti=wr?i:bt,mi=wr?ut:i,Gi=wr?i:ut;K|=wr?_:C,K&=~(wr?C:_),K&m||(K&=-4);var Vn=[B,K,Je,mi,Nr,Gi,ti,Rt,Xt,xr],Yi=se.apply(i,Vn);return e0(B)&&RR(Yi,Vn),Yi.placeholder=De,ay(Yi,B,K)}function Ym(B){var K=Ir[B];return function(se,De){if(se=Zc(se),De=De==null?0:ja(Wi(De),292),De&&Pl(se)){var Je=(Fo(se)+"e").split("e"),ut=K(Je[0]+"e"+(+Je[1]+De));return Je=(Fo(ut)+"e").split("e"),+(Je[0]+"e"+(+Je[1]-De))}return K(se)}}var TR=yd&&1/th(new yd([,-0]))[1]==z?function(B){return new yd(B)}:N;function vC(B){return function(K){var se=Xl(K);return se==Te?eh(K):se==me?Ug(K):Np(K,B(K))}}function Yu(B,K,se,De,Je,ut,bt,Rt){var Xt=K&y;if(!Xt&&typeof B!="function")throw new ho(a);var xr=De?De.length:0;if(xr||(K&=-97,De=Je=i),bt=bt===i?bt:ma(Wi(bt),0),Rt=Rt===i?Rt:Wi(Rt),xr-=Je?Je.length:0,K&C){var wr=De,Nr=Je;De=Je=i}var ti=Xt?i:Xm(B),mi=[B,K,se,De,Je,wr,Nr,ut,bt,Rt];if(ti&&DR(mi,ti),B=mi[0],K=mi[1],se=mi[2],De=mi[3],Je=mi[4],Rt=mi[9]=mi[9]===i?Xt?0:B.length:ma(mi[9]-xr,0),!Rt&&K&(b|S)&&(K&=-25),!K||K==v)var Gi=hC(B,K,se);else K==b||K==S?Gi=r2(B,K,Rt):(K==_||K==(v|_))&&!Je.length?Gi=CR(B,K,se,De):Gi=ny.apply(i,mi);var Vn=ti?cr:RR;return ay(Vn(Gi,mi),B,K)}function yC(B,K,se,De){return B===i||Xc(B,kc[se])&&!Mn.call(De,se)?K:B}function mC(B,K,se,De,Je,ut){return za(B)&&za(K)&&(ut.set(K,B),Wc(B,K,i,mC,ut),ut.delete(K)),B}function xR(B){return m0(B)?i:B}function qm(B,K,se,De,Je,ut){var bt=se&p,Rt=B.length,Xt=K.length;if(Rt!=Xt&&!(bt&&Xt>Rt))return!1;var xr=ut.get(B),wr=ut.get(K);if(xr&&wr)return xr==K&&wr==B;var Nr=-1,ti=!0,mi=se&g?new lf:i;for(ut.set(B,K),ut.set(K,B);++Nr<Rt;){var Gi=B[Nr],Vn=K[Nr];if(De)var Yi=bt?De(Vn,Gi,Nr,K,B,ut):De(Gi,Vn,Nr,B,K,ut);if(Yi!==i){if(Yi)continue;ti=!1;break}if(mi){if(!Fh(K,function(no,go){if(!Zd(mi,go)&&(Gi===no||Je(Gi,no,se,De,ut)))return mi.push(go)})){ti=!1;break}}else if(!(Gi===Vn||Je(Gi,Vn,se,De,ut))){ti=!1;break}}return ut.delete(B),ut.delete(K),ti}function ER(B,K,se,De,Je,ut,bt){switch(se){case $t:if(B.byteLength!=K.byteLength||B.byteOffset!=K.byteOffset)return!1;B=B.buffer,K=K.buffer;case wt:return!(B.byteLength!=K.byteLength||!ut(new nf(B),new nf(K)));case ge:case Ee:case ke:return Xc(+B,+K);case Ae:return B.name==K.name&&B.message==K.message;case fe:case Ce:return B==K+"";case Te:var Rt=eh;case me:var Xt=De&p;if(Rt||(Rt=th),B.size!=K.size&&!Xt)return!1;var xr=bt.get(B);if(xr)return xr==K;De|=g,bt.set(B,K);var wr=qm(Rt(B),Rt(K),De,Je,ut,bt);return bt.delete(B),wr;case Ue:if(ah)return ah.call(B)==ah.call(K)}return!1}function bC(B,K,se,De,Je,ut){var bt=se&p,Rt=e_(B),Xt=Rt.length,xr=e_(K),wr=xr.length;if(Xt!=wr&&!bt)return!1;for(var Nr=Xt;Nr--;){var ti=Rt[Nr];if(!(bt?ti in K:Mn.call(K,ti)))return!1}var mi=ut.get(B),Gi=ut.get(K);if(mi&&Gi)return mi==K&&Gi==B;var Vn=!0;ut.set(B,K),ut.set(K,B);for(var Yi=bt;++Nr<Xt;){ti=Rt[Nr];var no=B[ti],go=K[ti];if(De)var vf=bt?De(go,no,ti,K,B,ut):De(no,go,ti,B,K,ut);if(!(vf===i?no===go||Je(no,go,se,De,ut):vf)){Vn=!1;break}Yi||(Yi=ti=="constructor")}if(Vn&&!Yi){var Jc=B.constructor,yf=K.constructor;Jc!=yf&&"constructor"in B&&"constructor"in K&&!(typeof Jc=="function"&&Jc instanceof Jc&&typeof yf=="function"&&yf instanceof yf)&&(Vn=!1)}return ut.delete(B),ut.delete(K),Vn}function gh(B){return s_(EC(B,i,wa),B+"")}function e_(B){return Xg(B,Rl,r_)}function SC(B){return Xg(B,bc,Jm)}var Xm=Va?function(B){return Va.get(B)}:N;function Xa(B){for(var K=B.name+"",se=lo[K],De=Mn.call(lo,K)?se.length:0;De--;){var Je=se[De],ut=Je.func;if(ut==null||ut==B)return Je.name}return K}function ls(B){var K=Mn.call(nt,"placeholder")?nt:B;return K.placeholder}function Mi(){var B=nt.iteratee||E0;return B=B===E0?cf:B,arguments.length?B(arguments[0],arguments[1]):B}function Km(B,K){var se=B.__data__;return o_(K)?se[typeof K=="string"?"string":"hash"]:se.map}function t_(B){for(var K=Rl(B),se=K.length;se--;){var De=K[se],Je=B[De];K[se]=[De,Je,vh(Je)]}return K}function Jp(B,K){var se=ns(B,K);return Cs(se)?se:i}function Zm(B){var K=Mn.call(B,Nc),se=B[Nc];try{B[Nc]=i;var De=!0}catch{}var Je=po.call(B);return De&&(K?B[Nc]=se:delete B[Nc]),Je}var r_=$h?function(B){return B==null?[]:(B=Nt(B),is($h(B),function(K){return zh.call(B,K)}))}:Pr,Jm=$h?function(B){for(var K=[];B;)ac(K,r_(B)),B=Rr(B);return K}:Pr,Xl=Ps;(mu&&Xl(new mu(new ArrayBuffer(1)))!=$t||Ss&&Xl(new Ss)!=Te||jp&&Xl(jp.resolve())!=ve||yd&&Xl(new yd)!=me||of&&Xl(new of)!=it)&&(Xl=function(B){var K=Ps(B),se=K==Ne?B.constructor:i,De=se?Eu(se):"";if(De)switch(De){case kn:return $t;case md:return Te;case bu:return ve;case $g:return me;case bd:return it}return K});function i2(B,K,se){for(var De=-1,Je=se.length;++De<Je;){var ut=se[De],bt=ut.size;switch(ut.type){case"drop":B+=bt;break;case"dropRight":K-=bt;break;case"take":K=ja(K,B+bt);break;case"takeRight":B=ma(B,K-bt);break}}return{start:B,end:K}}function i_(B){var K=B.match(ri);return K?K[1].split(eo):[]}function n_(B,K,se){K=In(K,B);for(var De=-1,Je=K.length,ut=!1;++De<Je;){var bt=fc(K[De]);if(!(ut=B!=null&&se(B,bt)))break;B=B[bt]}return ut||++De!=Je?ut:(Je=B==null?0:B.length,!!Je&&__(Je)&&ff(bt,Je)&&(on(B)||tv(B)))}function wR(B){var K=B.length,se=new B.constructor(K);return K&&typeof B[0]=="string"&&Mn.call(B,"index")&&(se.index=B.index,se.input=B.input),se}function _C(B){return typeof B.constructor=="function"&&!oy(B)?Sd(Rr(B)):{}}function AR(B,K,se){var De=B.constructor;switch(K){case wt:return Um(B);case ge:case Ee:return new De(+B);case $t:return t2(B,se);case Mt:case rt:case qe:case vt:case kt:case Xe:case _t:case Ht:case Pt:return lC(B,se);case Te:return new De;case ke:case Ce:return new De(B);case fe:return mR(B);case me:return new De;case Ue:return bR(B)}}function PC(B,K){var se=K.length;if(!se)return B;var De=se-1;return K[De]=(se>1?"& ":"")+K[De],K=K.join(se>2?", ":" "),B.replace(qn,`{
/* [wrapped with `+K+`] */
`)}function CC(B){return on(B)||tv(B)||!!(qv&&B&&B[qv])}function ff(B,K){var se=typeof B;return K=K??G,!!K&&(se=="number"||se!="symbol"&&fi.test(B))&&B>-1&&B%1==0&&B<K}function xu(B,K,se){if(!za(se))return!1;var De=typeof K;return(De=="number"?yc(se)&&ff(K,se.length):De=="string"&&K in se)?Xc(se[K],B):!1}function Qm(B,K){if(on(B))return!1;var se=typeof B;return se=="number"||se=="symbol"||se=="boolean"||B==null||mc(B)?!0:Si.test(B)||!Qr.test(B)||K!=null&&B in Nt(K)}function o_(B){var K=typeof B;return K=="string"||K=="number"||K=="symbol"||K=="boolean"?B!=="__proto__":B===null}function e0(B){var K=Xa(B),se=nt[K];if(typeof se!="function"||!(K in nn.prototype))return!1;if(B===se)return!0;var De=Xm(se);return!!De&&B===De[0]}function OR(B){return!!Po&&Po in B}var TC=ef?Kc:ir;function oy(B){var K=B&&B.constructor,se=typeof K=="function"&&K.prototype||kc;return B===se}function vh(B){return B===B&&!za(B)}function a_(B,K){return function(se){return se==null?!1:se[B]===K&&(K!==i||B in Nt(se))}}function n2(B){var K=p0(B,function(De){return se.size===u&&se.clear(),De}),se=K.cache;return K}function DR(B,K){var se=B[1],De=K[1],Je=se|De,ut=Je<(v|y|P),bt=De==P&&se==b||De==P&&se==x&&B[7].length<=K[8]||De==(P|x)&&K[7].length<=K[8]&&se==b;if(!(ut||bt))return B;De&v&&(B[2]=K[2],Je|=se&v?0:m);var Rt=K[3];if(Rt){var Xt=B[3];B[3]=Xt?XS(Xt,Rt,K[4]):Rt,B[4]=Xt?zu(B[3],c):K[4]}return Rt=K[5],Rt&&(Xt=B[5],B[5]=Xt?cC(Xt,Rt,K[6]):Rt,B[6]=Xt?zu(B[5],c):K[6]),Rt=K[7],Rt&&(B[7]=Rt),De&P&&(B[8]=B[8]==null?K[8]:ja(B[8],K[8])),B[9]==null&&(B[9]=K[9]),B[0]=K[0],B[1]=Je,B}function Jh(B){var K=[];if(B!=null)for(var se in Nt(B))K.push(se);return K}function xC(B){return po.call(B)}function EC(B,K,se){return K=ma(K===i?B.length-1:K,0),function(){for(var De=arguments,Je=-1,ut=ma(De.length-K,0),bt=tt(ut);++Je<ut;)bt[Je]=De[K+Je];Je=-1;for(var Rt=tt(K+1);++Je<K;)Rt[Je]=De[Je];return Rt[K]=se(bt),Bs(B,this,Rt)}}function t0(B,K){return K.length<2?B:cc(B,Vr(K,0,-1))}function r0(B,K){for(var se=B.length,De=ja(K.length,se),Je=Gu(B);De--;){var ut=K[De];B[De]=ff(ut,se)?Je[ut]:i}return B}function la(B,K){if(!(K==="constructor"&&typeof B[K]=="function")&&K!="__proto__")return B[K]}var RR=Qh(cr),i0=vd||function(B,K){return Kt.setTimeout(B,K)},s_=Qh(or);function ay(B,K,se){var De=K+"";return s_(B,PC(De,MR(i_(De),se)))}function Qh(B){var K=0,se=0;return function(){var De=Cl(),Je=D-(De-se);if(se=De,Je>0){if(++K>=M)return arguments[0]}else K=0;return B.apply(i,arguments)}}function n0(B,K){var se=-1,De=B.length,Je=De-1;for(K=K===i?De:K;++se<K;){var ut=Oe(se,Je),bt=B[ut];B[ut]=B[se],B[se]=bt}return B.length=K,B}var wC=n2(function(B){var K=[];return B.charCodeAt(0)===46&&K.push(""),B.replace(oi,function(se,De,Je,ut){K.push(Je?ut.replace(gr,"$1"):De||se)}),K});function fc(B){if(typeof B=="string"||mc(B))return B;var K=B+"";return K=="0"&&1/B==-z?"-0":K}function Eu(B){if(B!=null){try{return tf.call(B)}catch{}try{return B+""}catch{}}return""}function MR(B,K){return js(Y,function(se){var De="_."+se[0];K&se[1]&&!Xf(B,De)&&B.push(De)}),B.sort()}function l_(B){if(B instanceof nn)return B.clone();var K=new Tl(B.__wrapped__,B.__chain__);return K.__actions__=Gu(B.__actions__),K.__index__=B.__index__,K.__values__=B.__values__,K}function LR(B,K,se){(se?xu(B,K,se):K===i)?K=1:K=ma(Wi(K),0);var De=B==null?0:B.length;if(!De||K<1)return[];for(var Je=0,ut=0,bt=tt(_r(De/K));Je<De;)bt[ut++]=Vr(B,Je,Je+=K);return bt}function AC(B){for(var K=-1,se=B==null?0:B.length,De=0,Je=[];++K<se;){var ut=B[K];ut&&(Je[De++]=ut)}return Je}function OC(){var B=arguments.length;if(!B)return[];for(var K=tt(B-1),se=arguments[0],De=B;De--;)K[De-1]=arguments[De];return ac(on(se)?Gu(se):[se],Ua(K,1))}var u_=lt(function(B,K){return Ts(B)?Cu(B,Ua(K,1,Ts,!0)):[]}),kR=lt(function(B,K){var se=Aa(K);return Ts(se)&&(se=i),Ts(B)?Cu(B,Ua(K,1,Ts,!0),Mi(se,2)):[]}),ep=lt(function(B,K){var se=Aa(K);return Ts(se)&&(se=i),Ts(B)?Cu(B,Ua(K,1,Ts,!0),i,se):[]});function Us(B,K,se){var De=B==null?0:B.length;return De?(K=se||K===i?1:Wi(K),Vr(B,K<0?0:K,De)):[]}function DC(B,K,se){var De=B==null?0:B.length;return De?(K=se||K===i?1:Wi(K),K=De-K,Vr(B,0,K<0?0:K)):[]}function IR(B,K){return B&&B.length?sa(B,Mi(K,3),!0,!0):[]}function Dl(B,K){return B&&B.length?sa(B,Mi(K,3),!0):[]}function o2(B,K,se,De){var Je=B==null?0:B.length;return Je?(se&&typeof se!="number"&&xu(B,K,se)&&(se=0,De=Je),fh(B,K,se,De)):[]}function RC(B,K,se){var De=B==null?0:B.length;if(!De)return-1;var Je=se==null?0:Wi(se);return Je<0&&(Je=ma(De+Je,0)),Zf(B,Mi(K,3),Je)}function MC(B,K,se){var De=B==null?0:B.length;if(!De)return-1;var Je=De-1;return se!==i&&(Je=Wi(se),Je=se<0?ma(De+Je,0):ja(Je,De-1)),Zf(B,Mi(K,3),Je,!0)}function wa(B){var K=B==null?0:B.length;return K?Ua(B,1):[]}function hc(B){var K=B==null?0:B.length;return K?Ua(B,z):[]}function tp(B,K){var se=B==null?0:B.length;return se?(K=K===i?1:Wi(K),Ua(B,K)):[]}function NR(B){for(var K=-1,se=B==null?0:B.length,De={};++K<se;){var Je=B[K];De[Je[0]]=Je[1]}return De}function LC(B){return B&&B.length?B[0]:i}function FR(B,K,se){var De=B==null?0:B.length;if(!De)return-1;var Je=se==null?0:Wi(se);return Je<0&&(Je=ma(De+Je,0)),Di(B,K,Je)}function a2(B){var K=B==null?0:B.length;return K?Vr(B,0,-1):[]}var c_=lt(function(B){var K=ko(B,sl);return K.length&&K[0]===B[0]?ph(K):[]}),pc=lt(function(B){var K=Aa(B),se=ko(B,sl);return K===Aa(se)?K=i:se.pop(),se.length&&se[0]===B[0]?ph(se,Mi(K,2)):[]}),hf=lt(function(B){var K=Aa(B),se=ko(B,sl);return K=typeof K=="function"?K:i,K&&se.pop(),se.length&&se[0]===B[0]?ph(se,i,K):[]});function BR(B,K){return B==null?"":ih.call(B,K)}function Aa(B){var K=B==null?0:B.length;return K?B[K-1]:i}function jR(B,K,se){var De=B==null?0:B.length;if(!De)return-1;var Je=De;return se!==i&&(Je=Wi(se),Je=Je<0?ma(De+Je,0):ja(Je,De-1)),K===K?Fp(B,K,Je):Zf(B,qd,Je,!0)}function rp(B,K){return B&&B.length?ee(B,Wi(K)):i}var Zg=lt(yh);function yh(B,K){return B&&B.length&&K&&K.length?ie(B,K):B}function kC(B,K,se){return B&&B.length&&K&&K.length?ie(B,K,Mi(se,2)):B}function IC(B,K,se){return B&&B.length&&K&&K.length?ie(B,K,i,se):B}var pf=gh(function(B,K){var se=B==null?0:B.length,De=dh(B,K);return he(B,ko(K,function(Je){return ff(Je,se)?+Je:Je}).sort(uC)),De});function VR(B,K){var se=[];if(!(B&&B.length))return se;var De=-1,Je=[],ut=B.length;for(K=Mi(K,3);++De<ut;){var bt=B[De];K(bt,De,B)&&(se.push(bt),Je.push(De))}return he(B,Je),se}function Qp(B){return B==null?B:yu.call(B)}function o0(B,K,se){var De=B==null?0:B.length;return De?(se&&typeof se!="number"&&xu(B,K,se)?(K=0,se=De):(K=K==null?0:Wi(K),se=se===i?De:Wi(se)),Vr(B,K,se)):[]}function a0(B,K){return ui(B,K)}function sy(B,K,se){return Ei(B,K,Mi(se,2))}function HR(B,K){var se=B==null?0:B.length;if(se){var De=ui(B,K);if(De<se&&Xc(B[De],K))return De}return-1}function UR(B,K){return ui(B,K,!0)}function s0(B,K,se){return Ei(B,K,Mi(se,2),!0)}function zR(B,K){var se=B==null?0:B.length;if(se){var De=ui(B,K,!0)-1;if(Xc(B[De],K))return De}return-1}function d_(B){return B&&B.length?jr(B):[]}function $R(B,K){return B&&B.length?jr(B,Mi(K,2)):[]}function s2(B){var K=B==null?0:B.length;return K?Vr(B,1,K):[]}function l2(B,K,se){return B&&B.length?(K=se||K===i?1:Wi(K),Vr(B,0,K<0?0:K)):[]}function Oo(B,K,se){var De=B==null?0:B.length;return De?(K=se||K===i?1:Wi(K),K=De-K,Vr(B,K<0?0:K,De)):[]}function ua(B,K){return B&&B.length?sa(B,Mi(K,3),!1,!0):[]}function Un(B,K){return B&&B.length?sa(B,Mi(K,3)):[]}var Xn=lt(function(B){return Kr(Ua(B,1,Ts,!0))}),$o=lt(function(B){var K=Aa(B);return Ts(K)&&(K=i),Kr(Ua(B,1,Ts,!0),Mi(K,2))}),Gc=lt(function(B){var K=Aa(B);return K=typeof K=="function"?K:i,Kr(Ua(B,1,Ts,!0),i,K)});function eg(B){return B&&B.length?Kr(B):[]}function ly(B,K){return B&&B.length?Kr(B,Mi(K,2)):[]}function NC(B,K){return K=typeof K=="function"?K:i,B&&B.length?Kr(B,i,K):[]}function gf(B){if(!(B&&B.length))return[];var K=0;return B=is(B,function(se){if(Ts(se))return K=ma(se.length,K),!0}),Rc(K,function(se){return ko(B,sc(se))})}function Ka(B,K){if(!(B&&B.length))return[];var se=gf(B);return K==null?se:ko(se,function(De){return Bs(K,i,De)})}var tg=lt(function(B,K){return Ts(B)?Cu(B,K):[]}),Jg=lt(function(B){return al(is(B,Ts))}),FC=lt(function(B){var K=Aa(B);return Ts(K)&&(K=i),al(is(B,Ts),Mi(K,2))}),Yc=lt(function(B){var K=Aa(B);return K=typeof K=="function"?K:i,al(is(B,Ts),i,K)}),uy=lt(gf);function l0(B,K){return pn(B||[],K||[],Pu)}function gc(B,K){return pn(B||[],K||[],jt)}var BC=lt(function(B){var K=B.length,se=K>1?B[K-1]:i;return se=typeof se=="function"?(B.pop(),se):i,Ka(B,se)});function u0(B){var K=nt(B);return K.__chain__=!0,K}function WR(B,K){return K(B),B}function Qg(B,K){return K(B)}var f_=gh(function(B){var K=B.length,se=K?B[0]:0,De=this.__wrapped__,Je=function(ut){return dh(ut,B)};return K>1||this.__actions__.length||!(De instanceof nn)||!ff(se)?this.thru(Je):(De=De.slice(se,+se+(K?1:0)),De.__actions__.push({func:Qg,args:[Je],thisArg:i}),new Tl(De,this.__chain__).thru(function(ut){return K&&!ut.length&&ut.push(i),ut}))});function rg(){return u0(this)}function ll(){return new Tl(this.value(),this.__chain__)}function ig(){this.__values__===i&&(this.__values__=gM(this.value()));var B=this.__index__>=this.__values__.length,K=B?i:this.__values__[this.__index__++];return{done:B,value:K}}function cy(){return this}function ip(B){for(var K,se=this;se instanceof _d;){var De=l_(se);De.__index__=0,De.__values__=i,K?Je.__wrapped__=De:K=De;var Je=De;se=se.__wrapped__}return Je.__wrapped__=B,K}function jC(){var B=this.__wrapped__;if(B instanceof nn){var K=B;return this.__actions__.length&&(K=new nn(this)),K=K.reverse(),K.__actions__.push({func:Qg,args:[Qp],thisArg:i}),new Tl(K,this.__chain__)}return this.thru(Qp)}function VC(){return No(this.__wrapped__,this.__actions__)}var GR=KS(function(B,K,se){Mn.call(B,se)?++B[se]:Yl(B,se,1)});function c0(B,K,se){var De=on(B)?hd:Td;return se&&xu(B,K,se)&&(K=i),De(B,Mi(K,3))}function HC(B,K){var se=on(B)?is:Gp;return se(B,Mi(K,3))}var qc=gC(RC),YR=gC(MC);function vc(B,K){return Ua(d0(B,K),1)}function qR(B,K){return Ua(d0(B,K),z)}function XR(B,K,se){return se=se===i?1:Wi(se),Ua(d0(B,K),se)}function KR(B,K){var se=on(B)?js:uc;return se(B,Mi(K,3))}function np(B,K){var se=on(B)?qf:Wp;return se(B,Mi(K,3))}var h_=KS(function(B,K,se){Mn.call(B,se)?B[se].push(K):Yl(B,se,[K])});function UC(B,K,se,De){B=yc(B)?B:by(B),se=se&&!De?Wi(se):0;var Je=B.length;return se<0&&(se=ma(Je+se,0)),_0(B)?se<=Je&&B.indexOf(K,se)>-1:!!Je&&Di(B,K,se)>-1}var dy=lt(function(B,K,se){var De=-1,Je=typeof K=="function",ut=yc(B)?tt(B.length):[];return uc(B,function(bt){ut[++De]=Je?Bs(K,bt,se):wl(bt,K,se)}),ut}),ZR=KS(function(B,K,se){Yl(B,se,K)});function d0(B,K){var se=on(B)?ko:df;return se(B,Mi(K,3))}function JR(B,K,se,De){return B==null?[]:(on(K)||(K=K==null?[]:[K]),se=De?i:se,on(se)||(se=se==null?[]:[se]),ae(B,K,se))}var QR=KS(function(B,K,se){B[se?0:1].push(K)},function(){return[[],[]]});function p_(B,K,se){var De=on(B)?Nh:Jf,Je=arguments.length<3;return De(B,Mi(K,4),se,Je,uc)}function zC(B,K,se){var De=on(B)?pd:Jf,Je=arguments.length<3;return De(B,Mi(K,4),se,Je,Wp)}function u2(B,K){var se=on(B)?is:Gp;return se(B,y_(Mi(K,3)))}function c2(B){var K=on(B)?qh:Ot;return K(B)}function d2(B,K,se){(se?xu(B,K,se):K===i)?K=1:K=Wi(K);var De=on(B)?Xh:St;return De(B,K)}function eM(B){var K=on(B)?Qv:mr;return K(B)}function tM(B){if(B==null)return 0;if(yc(B))return _0(B)?Lc(B):B.length;var K=Xl(B);return K==Te||K==me?B.size:$c(B).length}function fy(B,K,se){var De=on(B)?Fh:ei;return se&&xu(B,K,se)&&(K=i),De(B,Mi(K,3))}var g_=lt(function(B,K){if(B==null)return[];var se=K.length;return se>1&&xu(B,K[0],K[1])?K=[]:se>2&&xu(K[0],K[1],K[2])&&(K=[K[0]]),ae(B,Ua(K,1),[])}),f0=Ln||function(){return Kt.Date.now()};function rM(B,K){if(typeof K!="function")throw new ho(a);return B=Wi(B),function(){if(--B<1)return K.apply(this,arguments)}}function $C(B,K,se){return K=se?i:K,K=B&&K==null?B.length:K,Yu(B,P,i,i,i,i,K)}function WC(B,K){var se;if(typeof K!="function")throw new ho(a);return B=Wi(B),function(){return--B>0&&(se=K.apply(this,arguments)),B<=1&&(K=i),se}}var v_=lt(function(B,K,se){var De=v;if(se.length){var Je=zu(se,ls(v_));De|=_}return Yu(B,De,K,se,Je)}),GC=lt(function(B,K,se){var De=v|y;if(se.length){var Je=zu(se,ls(GC));De|=_}return Yu(K,De,B,se,Je)});function h0(B,K,se){K=se?i:K;var De=Yu(B,b,i,i,i,i,i,K);return De.placeholder=h0.placeholder,De}function YC(B,K,se){K=se?i:K;var De=Yu(B,S,i,i,i,i,i,K);return De.placeholder=YC.placeholder,De}function qC(B,K,se){var De,Je,ut,bt,Rt,Xt,xr=0,wr=!1,Nr=!1,ti=!0;if(typeof B!="function")throw new ho(a);K=Zc(K)||0,za(se)&&(wr=!!se.leading,Nr="maxWait"in se,ut=Nr?ma(Zc(se.maxWait)||0,K):ut,ti="trailing"in se?!!se.trailing:ti);function mi(ul){var sp=De,iv=Je;return De=Je=i,xr=ul,bt=B.apply(iv,sp),bt}function Gi(ul){return xr=ul,Rt=i0(no,K),wr?mi(ul):bt}function Vn(ul){var sp=ul-Xt,iv=ul-xr,cH=K-sp;return Nr?ja(cH,ut-iv):cH}function Yi(ul){var sp=ul-Xt,iv=ul-xr;return Xt===i||sp>=K||sp<0||Nr&&iv>=ut}function no(){var ul=f0();if(Yi(ul))return go(ul);Rt=i0(no,Vn(ul))}function go(ul){return Rt=i,ti&&De?mi(ul):(De=Je=i,bt)}function vf(){Rt!==i&&Hm(Rt),xr=0,De=Xt=Je=Rt=i}function Jc(){return Rt===i?bt:go(f0())}function yf(){var ul=f0(),sp=Yi(ul);if(De=arguments,Je=this,Xt=ul,sp){if(Rt===i)return Gi(Xt);if(Nr)return Hm(Rt),Rt=i0(no,K),mi(Xt)}return Rt===i&&(Rt=i0(no,K)),bt}return yf.cancel=vf,yf.flush=Jc,yf}var Wo=lt(function(B,K){return $p(B,1,K)}),XC=lt(function(B,K,se){return $p(B,Zc(K)||0,se)});function f2(B){return Yu(B,E)}function p0(B,K){if(typeof B!="function"||K!=null&&typeof K!="function")throw new ho(a);var se=function(){var De=arguments,Je=K?K.apply(this,De):De[0],ut=se.cache;if(ut.has(Je))return ut.get(Je);var bt=B.apply(this,De);return se.cache=ut.set(Je,bt)||ut,bt};return se.cache=new(p0.Cache||$u),se}p0.Cache=$u;function y_(B){if(typeof B!="function")throw new ho(a);return function(){var K=arguments;switch(K.length){case 0:return!B.call(this);case 1:return!B.call(this,K[0]);case 2:return!B.call(this,K[0],K[1]);case 3:return!B.call(this,K[0],K[1],K[2])}return!B.apply(this,K)}}function h2(B){return WC(2,B)}var p2=dc(function(B,K){K=K.length==1&&on(K[0])?ko(K[0],nl(Mi())):ko(Ua(K,1),nl(Mi()));var se=K.length;return lt(function(De){for(var Je=-1,ut=ja(De.length,se);++Je<ut;)De[Je]=K[Je].call(this,De[Je]);return Bs(B,this,De)})}),hy=lt(function(B,K){var se=zu(K,ls(hy));return Yu(B,_,i,K,se)}),ev=lt(function(B,K){var se=zu(K,ls(ev));return Yu(B,C,i,K,se)}),KC=gh(function(B,K){return Yu(B,x,i,i,i,K)});function m_(B,K){if(typeof B!="function")throw new ho(a);return K=K===i?K:Wi(K),lt(B,K)}function ZC(B,K){if(typeof B!="function")throw new ho(a);return K=K==null?0:ma(Wi(K),0),lt(function(se){var De=se[K],Je=ss(se,0,K);return De&&ac(Je,De),Bs(B,this,Je)})}function ng(B,K,se){var De=!0,Je=!0;if(typeof B!="function")throw new ho(a);return za(se)&&(De="leading"in se?!!se.leading:De,Je="trailing"in se?!!se.trailing:Je),qC(B,K,{leading:De,maxWait:K,trailing:Je})}function mh(B){return $C(B,1)}function g0(B,K){return hy(Hs(K),B)}function g2(){if(!arguments.length)return[];var B=arguments[0];return on(B)?B:[B]}function iM(B){return Vs(B,h)}function nM(B,K){return K=typeof K=="function"?K:i,Vs(B,h,K)}function oM(B){return Vs(B,d|h)}function aM(B,K){return K=typeof K=="function"?K:i,Vs(B,d|h,K)}function v2(B,K){return K==null||Cd(B,K,Rl(K))}function Xc(B,K){return B===K||B!==B&&K!==K}var sM=Gm(Kh),lM=Gm(function(B,K){return B>=K}),tv=ol((function(){return arguments})())?ol:function(B){return us(B)&&Mn.call(B,"callee")&&!zh.call(B,"callee")},on=tt.isArray,JC=ms?nl(ms):Ea;function yc(B){return B!=null&&__(B.length)&&!Kc(B)}function Ts(B){return us(B)&&yc(B)}function v0(B){return B===!0||B===!1||us(B)&&Ps(B)==ge}var og=Xv||ir,uM=Ba?nl(Ba):Io;function zn(B){return us(B)&&B.nodeType===1&&!m0(B)}function QC(B){if(B==null)return!0;if(yc(B)&&(on(B)||typeof B=="string"||typeof B.splice=="function"||og(B)||ag(B)||tv(B)))return!B.length;var K=Xl(B);if(K==Te||K==me)return!B.size;if(oy(B))return!$c(B).length;for(var se in B)if(Mn.call(B,se))return!1;return!0}function b_(B,K){return Al(B,K)}function eT(B,K,se){se=typeof se=="function"?se:i;var De=se?se(B,K):i;return De===i?Al(B,K,i,se):!!De}function S_(B){if(!us(B))return!1;var K=Ps(B);return K==Ae||K==Re||typeof B.message=="string"&&typeof B.name=="string"&&!m0(B)}function tT(B){return typeof B=="number"&&Pl(B)}function Kc(B){if(!za(B))return!1;var K=Ps(B);return K==Pe||K==we||K==de||K==pe}function y0(B){return typeof B=="number"&&B==Wi(B)}function __(B){return typeof B=="number"&&B>-1&&B%1==0&&B<=G}function za(B){var K=typeof B;return B!=null&&(K=="object"||K=="function")}function us(B){return B!=null&&typeof B=="object"}var cM=Sl?nl(Sl):yi;function dM(B,K){return B===K||Xo(B,K,t_(K))}function fM(B,K,se){return se=typeof se=="function"?se:i,Xo(B,K,t_(K),se)}function Zo(B){return iT(B)&&B!=+B}function rT(B){if(TC(B))throw new Ut(o);return Cs(B)}function Kl(B){return B===null}function y2(B){return B==null}function iT(B){return typeof B=="number"||us(B)&&Ps(B)==ke}function m0(B){if(!us(B)||Ps(B)!=Ne)return!1;var K=Rr(B);if(K===null)return!0;var se=Mn.call(K,"constructor")&&K.constructor;return typeof se=="function"&&se instanceof se&&tf.call(se)==so}var b0=zl?nl(zl):Ol;function nT(B){return y0(B)&&B>=-G&&B<=G}var S0=Hu?nl(Hu):zc;function _0(B){return typeof B=="string"||!on(B)&&us(B)&&Ps(B)==Ce}function mc(B){return typeof B=="symbol"||us(B)&&Ps(B)==Ue}var ag=fd?nl(fd):Ed;function oT(B){return B===i}function m2(B){return us(B)&&Xl(B)==it}function hM(B){return us(B)&&Ps(B)==xt}var b2=Gm(Ko),pM=Gm(function(B,K){return B<=K});function gM(B){if(!B)return[];if(yc(B))return _0(B)?Ke(B):Gu(B);if(bs&&B[bs])return Qf(B[bs]());var K=Xl(B),se=K==Te?eh:K==me?th:by;return se(B)}function op(B){if(!B)return B===0?B:0;if(B=Zc(B),B===z||B===-z){var K=B<0?-1:1;return K*H}return B===B?B:0}function Wi(B){var K=op(B),se=K%1;return K===K?se?K-se:K:0}function aT(B){return B?xl(Wi(B),0,k):0}function Zc(B){if(typeof B=="number")return B;if(mc(B))return U;if(za(B)){var K=typeof B.valueOf=="function"?B.valueOf():B;B=za(K)?K+"":K}if(typeof B!="string")return B===0?B:+B;B=Mc(B);var se=Lr.test(B);return se||zr.test(B)?Ft(B.slice(2),se?2:8):Yt.test(B)?U:+B}function P_(B){return wd(B,bc(B))}function S2(B){return B?xl(Wi(B),-G,G):B===0?B:0}function Fo(B){return B==null?"":ji(B)}var vM=Kp(function(B,K){if(oy(K)||yc(K)){wd(K,Rl(K),B);return}for(var se in K)Mn.call(K,se)&&Pu(B,se,K[se])}),C_=Kp(function(B,K){wd(K,bc(K),B)}),py=Kp(function(B,K,se,De){wd(K,bc(K),B,De)}),_2=Kp(function(B,K,se,De){wd(K,Rl(K),B,De)}),Ad=gh(dh);function sT(B,K){var se=Sd(B);return K==null?se:qg(se,K)}var yM=lt(function(B,K){B=Nt(B);var se=-1,De=K.length,Je=De>2?K[2]:i;for(Je&&xu(K[0],K[1],Je)&&(De=1);++se<De;)for(var ut=K[se],bt=bc(ut),Rt=-1,Xt=bt.length;++Rt<Xt;){var xr=bt[Rt],wr=B[xr];(wr===i||Xc(wr,kc[xr])&&!Mn.call(B,xr))&&(B[xr]=ut[xr])}return B}),mM=lt(function(B){return B.push(i,mC),Bs(vy,i,B)});function bM(B,K){return gd(B,Mi(K,3),Wu)}function P0(B,K){return gd(B,Mi(K,3),Yp)}function Od(B,K){return B==null?B:xd(B,Mi(K,3),bc)}function SM(B,K){return B==null?B:hh(B,Mi(K,3),bc)}function T_(B,K){return B&&Wu(B,Mi(K,3))}function ap(B,K){return B&&Yp(B,Mi(K,3))}function P2(B){return B==null?[]:Hc(B,Rl(B))}function C2(B){return B==null?[]:Hc(B,bc(B))}function sg(B,K,se){var De=B==null?i:cc(B,K);return De===i?se:De}function _M(B,K){return B!=null&&n_(B,K,ql)}function lT(B,K){return B!=null&&n_(B,K,El)}var T2=$m(function(B,K,se){K!=null&&typeof K.toString!="function"&&(K=po.call(K)),B[K]=se},_y(qu)),x2=$m(function(B,K,se){K!=null&&typeof K.toString!="function"&&(K=po.call(K)),Mn.call(B,K)?B[K].push(se):B[K]=[se]},Mi),E2=lt(wl);function Rl(B){return yc(B)?Up(B):$c(B)}function bc(B){return yc(B)?Up(B,!0):ry(B)}function w2(B,K){var se={};return K=Mi(K,3),Wu(B,function(De,Je,ut){Yl(se,K(De,Je,ut),De)}),se}function PM(B,K){var se={};return K=Mi(K,3),Wu(B,function(De,Je,ut){Yl(se,Je,K(De,Je,ut))}),se}var gy=Kp(function(B,K,se){Wc(B,K,se)}),vy=Kp(function(B,K,se,De){Wc(B,K,se,De)}),CM=gh(function(B,K){var se={};if(B==null)return se;var De=!1;K=ko(K,function(ut){return ut=In(ut,B),De||(De=ut.length>1),ut}),wd(B,SC(B),se),De&&(se=Vs(se,d|f|h,xR));for(var Je=K.length;Je--;)Ai(se,K[Je]);return se});function A2(B,K){return my(B,y_(Mi(K)))}var yy=gh(function(B,K){return B==null?{}:O(B,K)});function my(B,K){if(B==null)return{};var se=ko(SC(B),function(De){return[De]});return K=Mi(K),j(B,se,function(De,Je){return K(De,Je[0])})}function TM(B,K,se){K=In(K,B);var De=-1,Je=K.length;for(Je||(Je=1,B=i);++De<Je;){var ut=B==null?i:B[fc(K[De])];ut===i&&(De=Je,ut=se),B=Kc(ut)?ut.call(B):ut}return B}function x_(B,K,se){return B==null?B:jt(B,K,se)}function uT(B,K,se,De){return De=typeof De=="function"?De:i,B==null?B:jt(B,K,se,De)}var E_=vC(Rl),C0=vC(bc);function xM(B,K,se){var De=on(B),Je=De||og(B)||ag(B);if(K=Mi(K,4),se==null){var ut=B&&B.constructor;Je?se=De?new ut:[]:za(B)?se=Kc(ut)?Sd(Rr(B)):{}:se={}}return(Je?js:Wu)(B,function(bt,Rt,Xt){return K(se,bt,Rt,Xt)}),se}function EM(B,K){return B==null?!0:Ai(B,K)}function O2(B,K,se){return B==null?B:qa(B,K,Hs(se))}function wM(B,K,se,De){return De=typeof De=="function"?De:i,B==null?B:qa(B,K,Hs(se),De)}function by(B){return B==null?[]:jh(B,Rl(B))}function cT(B){return B==null?[]:jh(B,bc(B))}function D2(B,K,se){return se===i&&(se=K,K=i),se!==i&&(se=Zc(se),se=se===se?se:0),K!==i&&(K=Zc(K),K=K===K?K:0),xl(Zc(B),K,se)}function w_(B,K,se){return K=op(K),se===i?(se=K,K=0):se=op(se),B=Zc(B),Uc(B,K,se)}function A_(B,K,se){if(se&&typeof se!="boolean"&&xu(B,K,se)&&(K=se=i),se===i&&(typeof K=="boolean"?(se=K,K=i):typeof B=="boolean"&&(se=B,B=i)),B===i&&K===i?(B=0,K=1):(B=op(B),K===i?(K=B,B=0):K=op(K)),B>K){var De=B;B=K,K=De}if(se||B%1||K%1){var Je=Gl();return ja(B+Je*(K-B+ht("1e-"+((Je+"").length-1))),K)}return Oe(B,K)}var O_=Kg(function(B,K,se){return K=K.toLowerCase(),B+(se?AM(K):K)});function AM(B){return rv(Fo(B).toLowerCase())}function Sy(B){return B=Fo(B),B&&B.replace(to,pu).replace(xa,"")}function R2(B,K,se){B=Fo(B),K=ji(K);var De=B.length;se=se===i?De:xl(Wi(se),0,De);var Je=se;return se-=K.length,se>=0&&B.slice(se,Je)==K}function OM(B){return B=Fo(B),B&&dt.test(B)?B.replace(Be,io):B}function DM(B){return B=Fo(B),B&&vi.test(B)?B.replace(Yr,"\\$&"):B}var RM=Kg(function(B,K,se){return B+(se?"-":"")+K.toLowerCase()}),MM=Kg(function(B,K,se){return B+(se?" ":"")+K.toLowerCase()}),dT=pC("toLowerCase");function LM(B,K,se){B=Fo(B),K=Wi(K);var De=K?Lc(B):0;if(!K||De>=K)return B;var Je=(K-De)/2;return Zp(_n(Je),se)+B+Zp(_r(Je),se)}function kM(B,K,se){B=Fo(B),K=Wi(K);var De=K?Lc(B):0;return K&&De<K?B+Zp(K-De,se):B}function D_(B,K,se){B=Fo(B),K=Wi(K);var De=K?Lc(B):0;return K&&De<K?Zp(K-De,se)+B:B}function M2(B,K,se){return se||K==null?K=0:K&&(K=+K),vu(Fo(B).replace(rr,""),K||0)}function L2(B,K,se){return(se?xu(B,K,se):K===i)?K=1:K=Wi(K),Ge(Fo(B),K)}function fT(){var B=arguments,K=Fo(B[0]);return B.length<3?K:K.replace(B[1],B[2])}var hT=Kg(function(B,K,se){return B+(se?"_":"")+K.toLowerCase()});function R_(B,K,se){return se&&typeof se!="number"&&xu(B,K,se)&&(K=se=i),se=se===i?k:se>>>0,se?(B=Fo(B),B&&(typeof K=="string"||K!=null&&!b0(K))&&(K=ji(K),!K&&os(B))?ss(Ke(B),0,se):B.split(K,se)):[]}var pT=Kg(function(B,K,se){return B+(se?" ":"")+rv(K)});function IM(B,K,se){return B=Fo(B),se=se==null?0:xl(Wi(se),0,B.length),K=ji(K),B.slice(se,se+K.length)==K}function gT(B,K,se){var De=nt.templateSettings;se&&xu(B,K,se)&&(K=i),B=Fo(B),K=py({},K,De,yC);var Je=py({},K.imports,De.imports,yC),ut=Rl(Je),bt=jh(Je,ut),Rt,Xt,xr=0,wr=K.interpolate||st,Nr="__p += '",ti=hr((K.escape||st).source+"|"+wr.source+"|"+(wr===Ar?ce:st).source+"|"+(K.evaluate||st).source+"|$","g"),mi="//# sourceURL="+(Mn.call(K,"sourceURL")?(K.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++aa+"]")+`
`;B.replace(ti,function(Yi,no,go,vf,Jc,yf){return go||(go=vf),Nr+=B.slice(xr,yf).replace(zo,gu),no&&(Rt=!0,Nr+=`' +
__e(`+no+`) +
'`),Jc&&(Xt=!0,Nr+=`';
`+Jc+`;
__p += '`),go&&(Nr+=`' +
((__t = (`+go+`)) == null ? '' : __t) +
'`),xr=yf+Yi.length,Yi}),Nr+=`';
`;var Gi=Mn.call(K,"variable")&&K.variable;if(!Gi)Nr=`with (obj) {
`+Nr+`
}
`;else if(mt.test(Gi))throw new Ut(s);Nr=(Xt?Nr.replace(Jt,""):Nr).replace(zt,"$1").replace(Bt,"$1;"),Nr="function("+(Gi||"obj")+`) {
`+(Gi?"":`obj || (obj = {});
`)+"var __t, __p = ''"+(Rt?", __e = _.escape":"")+(Xt?`, __j = Array.prototype.join;
function print() { __p += __j.call(arguments, '') }
`:`;
`)+Nr+`return __p
}`;var Vn=vT(function(){return vr(ut,mi+"return "+Nr).apply(i,bt)});if(Vn.source=Nr,S_(Vn))throw Vn;return Vn}function lg(B){return Fo(B).toLowerCase()}function ug(B){return Fo(B).toUpperCase()}function cg(B,K,se){if(B=Fo(B),B&&(se||K===i))return Mc(B);if(!B||!(K=ji(K)))return B;var De=Ke(B),Je=Ke(K),ut=Uu(De,Je),bt=Vh(De,Je)+1;return ss(De,ut,bt).join("")}function T0(B,K,se){if(B=Fo(B),B&&(se||K===i))return B.slice(0,le(B)+1);if(!B||!(K=ji(K)))return B;var De=Ke(B),Je=Vh(De,Ke(K))+1;return ss(De,0,Je).join("")}function x0(B,K,se){if(B=Fo(B),B&&(se||K===i))return B.replace(rr,"");if(!B||!(K=ji(K)))return B;var De=Ke(B),Je=Uu(De,Ke(K));return ss(De,Je).join("")}function dg(B,K){var se=A,De=R;if(za(K)){var Je="separator"in K?K.separator:Je;se="length"in K?Wi(K.length):se,De="omission"in K?ji(K.omission):De}B=Fo(B);var ut=B.length;if(os(B)){var bt=Ke(B);ut=bt.length}if(se>=ut)return B;var Rt=se-Lc(De);if(Rt<1)return De;var Xt=bt?ss(bt,0,Rt).join(""):B.slice(0,Rt);if(Je===i)return Xt+De;if(bt&&(Rt+=Xt.length-Rt),b0(Je)){if(B.slice(Rt).search(Je)){var xr,wr=Xt;for(Je.global||(Je=hr(Je.source,Fo(fr.exec(Je))+"g")),Je.lastIndex=0;xr=Je.exec(wr);)var Nr=xr.index;Xt=Xt.slice(0,Nr===i?Rt:Nr)}}else if(B.indexOf(ji(Je),Rt)!=Rt){var ti=Xt.lastIndexOf(Je);ti>-1&&(Xt=Xt.slice(0,ti))}return Xt+De}function k2(B){return B=Fo(B),B&&We.test(B)?B.replace(Mr,Se):B}var NM=Kg(function(B,K,se){return B+(se?" ":"")+K.toUpperCase()}),rv=pC("toUpperCase");function FM(B,K,se){return B=Fo(B),K=se?i:K,K===i?Hh(B)?Le(B):Kf(B):B.match(K)||[]}var vT=lt(function(B,K){try{return Bs(B,i,K)}catch(se){return S_(se)?se:new Ut(se)}}),M_=gh(function(B,K){return js(K,function(se){se=fc(se),Yl(B,se,v_(B[se],B))}),B});function BM(B){var K=B==null?0:B.length,se=Mi();return B=K?ko(B,function(De){if(typeof De[1]!="function")throw new ho(a);return[se(De[0]),De[1]]}):[],lt(function(De){for(var Je=-1;++Je<K;){var ut=B[Je];if(Bs(ut[0],this,De))return Bs(ut[1],this,De)}})}function I2(B){return ty(Vs(B,d))}function _y(B){return function(){return B}}function L_(B,K){return B==null||B!==B?K:B}var jM=iy(),Py=iy(!0);function qu(B){return B}function E0(B){return cf(typeof B=="function"?B:Vs(B,d))}function k_(B){return Zh(Vs(B,d))}function VM(B,K){return Xp(B,Vs(K,d))}var N2=lt(function(B,K){return function(se){return wl(se,B,K)}}),I_=lt(function(B,K){return function(se){return wl(B,se,K)}});function T(B,K,se){var De=Rl(K),Je=Hc(K,De);se==null&&!(za(K)&&(Je.length||!De.length))&&(se=K,K=B,B=this,Je=Hc(K,Rl(K)));var ut=!(za(se)&&"chain"in se)||!!se.chain,bt=Kc(B);return js(Je,function(Rt){var Xt=K[Rt];B[Rt]=Xt,bt&&(B.prototype[Rt]=function(){var xr=this.__chain__;if(ut||xr){var wr=B(this.__wrapped__),Nr=wr.__actions__=Gu(this.__actions__);return Nr.push({func:Xt,args:arguments,thisArg:B}),wr.__chain__=xr,wr}return Xt.apply(B,ac([this.value()],arguments))})}),B}function w(){return Kt._===this&&(Kt._=_l),this}function N(){}function q(B){return B=Wi(B),lt(function(K){return ee(K,B)})}var ne=ZS(ko),ue=ZS(hd),Ie=ZS(Fh);function ot(B){return Qm(B)?sc(fc(B)):Q(B)}function Et(B){return function(K){return B==null?i:cc(B,K)}}var tr=JS(),yr=JS(!0);function Pr(){return[]}function ir(){return!1}function ar(){return{}}function li(){return""}function Ii(){return!0}function Jo(B,K){if(B=Wi(B),B<1||B>G)return[];var se=k,De=ja(B,k);K=Mi(K),B-=k;for(var Je=Rc(De,K);++se<B;)K(se);return Je}function Wt(B){return on(B)?ko(B,fc):mc(B)?[B]:Gu(wC(Fo(B)))}function It(B){var K=++ya;return Fo(B)+K}var Qt=Wm(function(B,K){return B+K},0),Sr=Ym("ceil"),wi=Wm(function(B,K){return B/K},1),Co=Ym("floor");function gi(B){return B&&B.length?Tu(B,qu,Kh):i}function Pn(B,K){return B&&B.length?Tu(B,Mi(K,2),Kh):i}function Kn(B){return Xd(B,qu)}function To(B,K){return Xd(B,Mi(K,2))}function fg(B){return B&&B.length?Tu(B,qu,Ko):i}function F2(B,K){return B&&B.length?Tu(B,Mi(K,2),Ko):i}var _G=Wm(function(B,K){return B*K},1),PG=Ym("round"),CG=Wm(function(B,K){return B-K},0);function TG(B){return B&&B.length?Dc(B,qu):0}function xG(B,K){return B&&B.length?Dc(B,Mi(K,2)):0}return nt.after=rM,nt.ary=$C,nt.assign=vM,nt.assignIn=C_,nt.assignInWith=py,nt.assignWith=_2,nt.at=Ad,nt.before=WC,nt.bind=v_,nt.bindAll=M_,nt.bindKey=GC,nt.castArray=g2,nt.chain=u0,nt.chunk=LR,nt.compact=AC,nt.concat=OC,nt.cond=BM,nt.conforms=I2,nt.constant=_y,nt.countBy=GR,nt.create=sT,nt.curry=h0,nt.curryRight=YC,nt.debounce=qC,nt.defaults=yM,nt.defaultsDeep=mM,nt.defer=Wo,nt.delay=XC,nt.difference=u_,nt.differenceBy=kR,nt.differenceWith=ep,nt.drop=Us,nt.dropRight=DC,nt.dropRightWhile=IR,nt.dropWhile=Dl,nt.fill=o2,nt.filter=HC,nt.flatMap=vc,nt.flatMapDeep=qR,nt.flatMapDepth=XR,nt.flatten=wa,nt.flattenDeep=hc,nt.flattenDepth=tp,nt.flip=f2,nt.flow=jM,nt.flowRight=Py,nt.fromPairs=NR,nt.functions=P2,nt.functionsIn=C2,nt.groupBy=h_,nt.initial=a2,nt.intersection=c_,nt.intersectionBy=pc,nt.intersectionWith=hf,nt.invert=T2,nt.invertBy=x2,nt.invokeMap=dy,nt.iteratee=E0,nt.keyBy=ZR,nt.keys=Rl,nt.keysIn=bc,nt.map=d0,nt.mapKeys=w2,nt.mapValues=PM,nt.matches=k_,nt.matchesProperty=VM,nt.memoize=p0,nt.merge=gy,nt.mergeWith=vy,nt.method=N2,nt.methodOf=I_,nt.mixin=T,nt.negate=y_,nt.nthArg=q,nt.omit=CM,nt.omitBy=A2,nt.once=h2,nt.orderBy=JR,nt.over=ne,nt.overArgs=p2,nt.overEvery=ue,nt.overSome=Ie,nt.partial=hy,nt.partialRight=ev,nt.partition=QR,nt.pick=yy,nt.pickBy=my,nt.property=ot,nt.propertyOf=Et,nt.pull=Zg,nt.pullAll=yh,nt.pullAllBy=kC,nt.pullAllWith=IC,nt.pullAt=pf,nt.range=tr,nt.rangeRight=yr,nt.rearg=KC,nt.reject=u2,nt.remove=VR,nt.rest=m_,nt.reverse=Qp,nt.sampleSize=d2,nt.set=x_,nt.setWith=uT,nt.shuffle=eM,nt.slice=o0,nt.sortBy=g_,nt.sortedUniq=d_,nt.sortedUniqBy=$R,nt.split=R_,nt.spread=ZC,nt.tail=s2,nt.take=l2,nt.takeRight=Oo,nt.takeRightWhile=ua,nt.takeWhile=Un,nt.tap=WR,nt.throttle=ng,nt.thru=Qg,nt.toArray=gM,nt.toPairs=E_,nt.toPairsIn=C0,nt.toPath=Wt,nt.toPlainObject=P_,nt.transform=xM,nt.unary=mh,nt.union=Xn,nt.unionBy=$o,nt.unionWith=Gc,nt.uniq=eg,nt.uniqBy=ly,nt.uniqWith=NC,nt.unset=EM,nt.unzip=gf,nt.unzipWith=Ka,nt.update=O2,nt.updateWith=wM,nt.values=by,nt.valuesIn=cT,nt.without=tg,nt.words=FM,nt.wrap=g0,nt.xor=Jg,nt.xorBy=FC,nt.xorWith=Yc,nt.zip=uy,nt.zipObject=l0,nt.zipObjectDeep=gc,nt.zipWith=BC,nt.entries=E_,nt.entriesIn=C0,nt.extend=C_,nt.extendWith=py,T(nt,nt),nt.add=Qt,nt.attempt=vT,nt.camelCase=O_,nt.capitalize=AM,nt.ceil=Sr,nt.clamp=D2,nt.clone=iM,nt.cloneDeep=oM,nt.cloneDeepWith=aM,nt.cloneWith=nM,nt.conformsTo=v2,nt.deburr=Sy,nt.defaultTo=L_,nt.divide=wi,nt.endsWith=R2,nt.eq=Xc,nt.escape=OM,nt.escapeRegExp=DM,nt.every=c0,nt.find=qc,nt.findIndex=RC,nt.findKey=bM,nt.findLast=YR,nt.findLastIndex=MC,nt.findLastKey=P0,nt.floor=Co,nt.forEach=KR,nt.forEachRight=np,nt.forIn=Od,nt.forInRight=SM,nt.forOwn=T_,nt.forOwnRight=ap,nt.get=sg,nt.gt=sM,nt.gte=lM,nt.has=_M,nt.hasIn=lT,nt.head=LC,nt.identity=qu,nt.includes=UC,nt.indexOf=FR,nt.inRange=w_,nt.invoke=E2,nt.isArguments=tv,nt.isArray=on,nt.isArrayBuffer=JC,nt.isArrayLike=yc,nt.isArrayLikeObject=Ts,nt.isBoolean=v0,nt.isBuffer=og,nt.isDate=uM,nt.isElement=zn,nt.isEmpty=QC,nt.isEqual=b_,nt.isEqualWith=eT,nt.isError=S_,nt.isFinite=tT,nt.isFunction=Kc,nt.isInteger=y0,nt.isLength=__,nt.isMap=cM,nt.isMatch=dM,nt.isMatchWith=fM,nt.isNaN=Zo,nt.isNative=rT,nt.isNil=y2,nt.isNull=Kl,nt.isNumber=iT,nt.isObject=za,nt.isObjectLike=us,nt.isPlainObject=m0,nt.isRegExp=b0,nt.isSafeInteger=nT,nt.isSet=S0,nt.isString=_0,nt.isSymbol=mc,nt.isTypedArray=ag,nt.isUndefined=oT,nt.isWeakMap=m2,nt.isWeakSet=hM,nt.join=BR,nt.kebabCase=RM,nt.last=Aa,nt.lastIndexOf=jR,nt.lowerCase=MM,nt.lowerFirst=dT,nt.lt=b2,nt.lte=pM,nt.max=gi,nt.maxBy=Pn,nt.mean=Kn,nt.meanBy=To,nt.min=fg,nt.minBy=F2,nt.stubArray=Pr,nt.stubFalse=ir,nt.stubObject=ar,nt.stubString=li,nt.stubTrue=Ii,nt.multiply=_G,nt.nth=rp,nt.noConflict=w,nt.noop=N,nt.now=f0,nt.pad=LM,nt.padEnd=kM,nt.padStart=D_,nt.parseInt=M2,nt.random=A_,nt.reduce=p_,nt.reduceRight=zC,nt.repeat=L2,nt.replace=fT,nt.result=TM,nt.round=PG,nt.runInContext=ze,nt.sample=c2,nt.size=tM,nt.snakeCase=hT,nt.some=fy,nt.sortedIndex=a0,nt.sortedIndexBy=sy,nt.sortedIndexOf=HR,nt.sortedLastIndex=UR,nt.sortedLastIndexBy=s0,nt.sortedLastIndexOf=zR,nt.startCase=pT,nt.startsWith=IM,nt.subtract=CG,nt.sum=TG,nt.sumBy=xG,nt.template=gT,nt.times=Jo,nt.toFinite=op,nt.toInteger=Wi,nt.toLength=aT,nt.toLower=lg,nt.toNumber=Zc,nt.toSafeInteger=S2,nt.toString=Fo,nt.toUpper=ug,nt.trim=cg,nt.trimEnd=T0,nt.trimStart=x0,nt.truncate=dg,nt.unescape=k2,nt.uniqueId=It,nt.upperCase=NM,nt.upperFirst=rv,nt.each=KR,nt.eachRight=np,nt.first=LC,T(nt,(function(){var B={};return Wu(nt,function(K,se){Mn.call(nt.prototype,se)||(B[se]=K)}),B})(),{chain:!1}),nt.VERSION=n,js(["bind","bindKey","curry","curryRight","partial","partialRight"],function(B){nt[B].placeholder=nt}),js(["drop","take"],function(B,K){nn.prototype[B]=function(se){se=se===i?1:ma(Wi(se),0);var De=this.__filtered__&&!K?new nn(this):this.clone();return De.__filtered__?De.__takeCount__=ja(se,De.__takeCount__):De.__views__.push({size:ja(se,k),type:B+(De.__dir__<0?"Right":"")}),De},nn.prototype[B+"Right"]=function(se){return this.reverse()[B](se).reverse()}}),js(["filter","map","takeWhile"],function(B,K){var se=K+1,De=se==F||se==V;nn.prototype[B]=function(Je){var ut=this.clone();return ut.__iteratees__.push({iteratee:Mi(Je,3),type:se}),ut.__filtered__=ut.__filtered__||De,ut}}),js(["head","last"],function(B,K){var se="take"+(K?"Right":"");nn.prototype[B]=function(){return this[se](1).value()[0]}}),js(["initial","tail"],function(B,K){var se="drop"+(K?"":"Right");nn.prototype[B]=function(){return this.__filtered__?new nn(this):this[se](1)}}),nn.prototype.compact=function(){return this.filter(qu)},nn.prototype.find=function(B){return this.filter(B).head()},nn.prototype.findLast=function(B){return this.reverse().find(B)},nn.prototype.invokeMap=lt(function(B,K){return typeof B=="function"?new nn(this):this.map(function(se){return wl(se,B,K)})}),nn.prototype.reject=function(B){return this.filter(y_(Mi(B)))},nn.prototype.slice=function(B,K){B=Wi(B);var se=this;return se.__filtered__&&(B>0||K<0)?new nn(se):(B<0?se=se.takeRight(-B):B&&(se=se.drop(B)),K!==i&&(K=Wi(K),se=K<0?se.dropRight(-K):se.take(K-B)),se)},nn.prototype.takeRightWhile=function(B){return this.reverse().takeWhile(B).reverse()},nn.prototype.toArray=function(){return this.take(k)},Wu(nn.prototype,function(B,K){var se=/^(?:filter|find|map|reject)|While$/.test(K),De=/^(?:head|last)$/.test(K),Je=nt[De?"take"+(K=="last"?"Right":""):K],ut=De||/^find/.test(K);Je&&(nt.prototype[K]=function(){var bt=this.__wrapped__,Rt=De?[1]:arguments,Xt=bt instanceof nn,xr=Rt[0],wr=Xt||on(bt),Nr=function(no){var go=Je.apply(nt,ac([no],Rt));return De&&ti?go[0]:go};wr&&se&&typeof xr=="function"&&xr.length!=1&&(Xt=wr=!1);var ti=this.__chain__,mi=!!this.__actions__.length,Gi=ut&&!ti,Vn=Xt&&!mi;if(!ut&&wr){bt=Vn?bt:new nn(this);var Yi=B.apply(bt,Rt);return Yi.__actions__.push({func:Qg,args:[Nr],thisArg:i}),new Tl(Yi,ti)}return Gi&&Vn?B.apply(this,Rt):(Yi=this.thru(Nr),Gi?De?Yi.value()[0]:Yi.value():Yi)})}),js(["pop","push","shift","sort","splice","unshift"],function(B){var K=$l[B],se=/^(?:push|sort|unshift)$/.test(B)?"tap":"thru",De=/^(?:pop|shift)$/.test(B);nt.prototype[B]=function(){var Je=arguments;if(De&&!this.__chain__){var ut=this.value();return K.apply(on(ut)?ut:[],Je)}return this[se](function(bt){return K.apply(on(bt)?bt:[],Je)})}}),Wu(nn.prototype,function(B,K){var se=nt[K];if(se){var De=se.name+"";Mn.call(lo,De)||(lo[De]=[]),lo[De].push({name:K,func:se})}}),lo[ny(i,y).name]=[{name:"wrapper",func:i}],nn.prototype.clone=Fc,nn.prototype.reverse=Pd,nn.prototype.value=Bc,nt.prototype.at=f_,nt.prototype.chain=rg,nt.prototype.commit=ll,nt.prototype.next=ig,nt.prototype.plant=ip,nt.prototype.reverse=jC,nt.prototype.toJSON=nt.prototype.valueOf=nt.prototype.value=VC,nt.prototype.first=nt.prototype.head,bs&&(nt.prototype[bs]=cy),nt}),ct=je();ni?((ni.exports=ct)._=ct,Zr._=ct):Kt._=ct}).call(gwt)})(cj,cj.exports)),cj.exports}var ywt=vwt();function mwt(...t){return qJ(Rv(t))}const bwt=J.forwardRef((t,e)=>{const[i,n]=J.useState(!1),r=J.useRef(null),[o,a]=J.useState(""),s=J.useCallback(ywt.debounce(async p=>{r.current&&r.current.abort();const g=new AbortController;r.current=g;try{t.setSearchValue(p)}catch(v){v.name!=="AbortError"&&console.error("Search error:",v)}finally{n(!1)}},300),[t.setSearchValue]);J.useEffect(()=>{t.forceSearchValueChange!==void 0&&a("")},[t.forceSearchValueChange]),J.useEffect(()=>(o!==void 0&&(n(!0),s(o)),()=>{s.cancel(),r.current&&r.current.abort()}),[o]);const l=p=>{const g=p.target.value;a(g)},u=p=>{p.key==="Backspace"&&o===""&&t.termFilters.length>0&&c(t.termFilters.length-1),t.onKeyDown&&t.onKeyDown(p)},c=p=>{t.deleteTerm(p)},d=()=>L.jsxs(Dqe,{delayDuration:0,children:[L.jsx(Rqe,{asChild:!0,children:L.jsx("button",{type:"button",className:"p-0 m-0 border-0 bg-transparent cursor-pointer hover:opacity-70 focus:outline-none flex items-center mx-1","aria-label":"Search help",children:L.jsx(NEe,{size:20,className:"text-gray-500 dark:text-gray-400"})})}),L.jsx(Mqe,{children:L.jsxs(Lqe,{side:"bottom",sideOffset:8,align:"end",className:"z-[10002] w-80 rounded-lg bg-white dark:bg-neutral-800 text-gray-900 dark:text-gray-100 shadow-lg ring-1 ring-black/5 dark:ring-white/10 p-4 text-sm",children:[L.jsx("div",{className:"font-semibold text-gray-900 dark:text-gray-100 mb-2",children:"Search Help"}),L.jsxs("ul",{className:"list-disc pl-4 space-y-1 text-gray-700 dark:text-gray-300",children:[L.jsx("li",{children:"Start writing to get suggestions and filter signals"}),L.jsx("li",{children:"Pick a suggestion to create a filter"}),L.jsx("li",{children:"'Escape' to clear suggestions"}),L.jsx("li",{children:"You can create any number of filters"}),L.jsx("li",{children:"Exact match will force terms to match exact"}),L.jsxs("li",{children:["Combine with ",L.jsx("b",{children:"and"})," to force all terms to match - ",L.jsx("b",{children:"or"})," to match any term."]}),L.jsx("li",{children:"Choose which fields to search in"})]}),L.jsx("hr",{className:"my-2 border-gray-200 dark:border-neutral-700"}),L.jsx("ul",{className:"list-disc pl-4 text-gray-600 dark:text-gray-400",children:L.jsx("li",{children:"Using suggestions is more performant than free text search"})})]})})]}),f=()=>L.jsx(L.Fragment,{children:i?L.jsx(FEe,{size:18,className:"animate-spin text-gray-500 dark:text-gray-400"}):L.jsx(BEe,{size:18,className:"text-gray-500 dark:text-gray-400"})}),h=()=>L.jsxs(L.Fragment,{children:[t.termFilters.map((p,g)=>L.jsxs("div",{className:"bg-blue-100 dark:bg-slate-700/90 text-gray-800 dark:text-gray-200 border border-blue-300 dark:border-slate-600 pl-3 pr-2 py-1 flex items-center gap-1 flex-grow-0 my-0.5 rounded-lg",children:[L.jsx("input",{onChange:()=>t.toggleTerm(g),type:"checkbox",checked:p.enabled,className:"w-3.5 h-3.5 shrink-0 rounded border-gray-300 dark:border-neutral-600 text-blue-600 focus:ring-blue-500 cursor-pointer bg-white dark:bg-neutral-700","aria-hidden":!0}),L.jsxs("span",{className:"flex items-center gap-1.5 py-0.5 px-1 text-sm whitespace-nowrap leading-none",children:[t.getFieldLabel(p.term.fields[0]),": ",p.term.term,L.jsx("button",{type:"button",onClick:()=>c(g),className:"flex items-center justify-center p-0 border-0 bg-transparent cursor-pointer hover:text-red-500 dark:hover:text-red-400 rounded","aria-label":"Remove filter",children:L.jsx(zj,{size:16,className:"shrink-0"})})]})]},g)),L.jsx("div",{className:"inline-flex min-w-[140px] flex-1",children:L.jsx("input",{ref:e,type:"text",className:"w-full px-0 border-0 bg-transparent focus:outline-none focus:ring-0 text-gray-900 dark:text-gray-100 placeholder-gray-400 dark:placeholder-gray-500",autoFocus:t.autoFocus,placeholder:t.termFilters.length>0?"Search...":t.placeHolder??"Search...",value:o,onChange:l,onKeyDown:u})})]});return L.jsxs("div",{className:mwt("flex flex-row justify-start content-center w-full text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-neutral-600",t.className),children:[L.jsx("div",{className:"flex items-center justify-center ps-3 pe-1",children:f()}),L.jsx("div",{className:"flex-1 py-1 px-2 flex flex-row flex-wrap items-center gap-1 min-h-[38px]",children:h()}),L.jsx("div",{className:"flex items-center justify-center px-2",children:d()})]})});var aW="Collapsible",[Swt]=kS(aW),[_wt,gre]=Swt(aW),UNe=J.forwardRef((t,e)=>{const{__scopeCollapsible:i,open:n,defaultOpen:r,disabled:o,onOpenChange:a,...s}=t,[l,u]=ND({prop:n,defaultProp:r??!1,onChange:a,caller:aW});return L.jsx(_wt,{scope:i,disabled:o,contentId:Mv(),open:l,onOpenToggle:J.useCallback(()=>u(c=>!c),[u]),children:L.jsx(es.div,{"data-state":yre(l),"data-disabled":o?"":void 0,...s,ref:e})})});UNe.displayName=aW;var zNe="CollapsibleTrigger",$Ne=J.forwardRef((t,e)=>{const{__scopeCollapsible:i,...n}=t,r=gre(zNe,i);return L.jsx(es.button,{type:"button","aria-controls":r.contentId,"aria-expanded":r.open||!1,"data-state":yre(r.open),"data-disabled":r.disabled?"":void 0,disabled:r.disabled,...n,ref:e,onClick:tn(t.onClick,r.onOpenToggle)})});$Ne.displayName=zNe;var vre="CollapsibleContent",Pwt=J.forwardRef((t,e)=>{const{forceMount:i,...n}=t,r=gre(vre,t.__scopeCollapsible);return L.jsx(Mp,{present:i||r.open,children:({present:o})=>L.jsx(Cwt,{...n,ref:e,present:o})})});Pwt.displayName=vre;var Cwt=J.forwardRef((t,e)=>{const{__scopeCollapsible:i,present:n,children:r,...o}=t,a=gre(vre,i),[s,l]=J.useState(n),u=J.useRef(null),c=Bl(e,u),d=J.useRef(0),f=d.current,h=J.useRef(0),p=h.current,g=a.open||s,v=J.useRef(g),y=J.useRef(void 0);return J.useEffect(()=>{const m=requestAnimationFrame(()=>v.current=!1);return()=>cancelAnimationFrame(m)},[]),bS(()=>{const m=u.current;if(m){y.current=y.current||{transitionDuration:m.style.transitionDuration,animationName:m.style.animationName},m.style.transitionDuration="0s",m.style.animationName="none";const b=m.getBoundingClientRect();d.current=b.height,h.current=b.width,v.current||(m.style.transitionDuration=y.current.transitionDuration,m.style.animationName=y.current.animationName),l(n)}},[a.open,n]),L.jsx(es.div,{"data-state":yre(a.open),"data-disabled":a.disabled?"":void 0,id:a.contentId,hidden:!g,...o,ref:c,style:{"--radix-collapsible-content-height":f?`${f}px`:void 0,"--radix-collapsible-content-width":p?`${p}px`:void 0,...t.style},children:g&&r})});function yre(t){return t?"open":"closed"}var Twt=UNe,xwt=$Ne,vq={exports:{}};/**
 * lunr - http://lunrjs.com - A bit like Solr, but much smaller and not as bright - 2.3.9
 * Copyright (C) 2020 Oliver Nightingale
 * @license MIT
 */var vhe;function Ewt(){return vhe||(vhe=1,(function(t,e){(function(){var i=function(n){var r=new i.Builder;return r.pipeline.add(i.trimmer,i.stopWordFilter,i.stemmer),r.searchPipeline.add(i.stemmer),n.call(r,r),r.build()};i.version="2.3.9";/*!
 * lunr.utils
 * Copyright (C) 2020 Oliver Nightingale
 */i.utils={},i.utils.warn=(function(n){return function(r){n.console&&console.warn&&console.warn(r)}})(this),i.utils.asString=function(n){return n==null?"":n.toString()},i.utils.clone=function(n){if(n==null)return n;for(var r=Object.create(null),o=Object.keys(n),a=0;a<o.length;a++){var s=o[a],l=n[s];if(Array.isArray(l)){r[s]=l.slice();continue}if(typeof l=="string"||typeof l=="number"||typeof l=="boolean"){r[s]=l;continue}throw new TypeError("clone is not deep and does not support nested objects")}return r},i.FieldRef=function(n,r,o){this.docRef=n,this.fieldName=r,this._stringValue=o},i.FieldRef.joiner="/",i.FieldRef.fromString=function(n){var r=n.indexOf(i.FieldRef.joiner);if(r===-1)throw"malformed field ref string";var o=n.slice(0,r),a=n.slice(r+1);return new i.FieldRef(a,o,n)},i.FieldRef.prototype.toString=function(){return this._stringValue==null&&(this._stringValue=this.fieldName+i.FieldRef.joiner+this.docRef),this._stringValue};/*!
 * lunr.Set
 * Copyright (C) 2020 Oliver Nightingale
 */i.Set=function(n){if(this.elements=Object.create(null),n){this.length=n.length;for(var r=0;r<this.length;r++)this.elements[n[r]]=!0}else this.length=0},i.Set.complete={intersect:function(n){return n},union:function(){return this},contains:function(){return!0}},i.Set.empty={intersect:function(){return this},union:function(n){return n},contains:function(){return!1}},i.Set.prototype.contains=function(n){return!!this.elements[n]},i.Set.prototype.intersect=function(n){var r,o,a,s=[];if(n===i.Set.complete)return this;if(n===i.Set.empty)return n;this.length<n.length?(r=this,o=n):(r=n,o=this),a=Object.keys(r.elements);for(var l=0;l<a.length;l++){var u=a[l];u in o.elements&&s.push(u)}return new i.Set(s)},i.Set.prototype.union=function(n){return n===i.Set.complete?i.Set.complete:n===i.Set.empty?this:new i.Set(Object.keys(this.elements).concat(Object.keys(n.elements)))},i.idf=function(n,r){var o=0;for(var a in n)a!="_index"&&(o+=Object.keys(n[a]).length);var s=(r-o+.5)/(o+.5);return Math.log(1+Math.abs(s))},i.Token=function(n,r){this.str=n||"",this.metadata=r||{}},i.Token.prototype.toString=function(){return this.str},i.Token.prototype.update=function(n){return this.str=n(this.str,this.metadata),this},i.Token.prototype.clone=function(n){return n=n||function(r){return r},new i.Token(n(this.str,this.metadata),this.metadata)};/*!
 * lunr.tokenizer
 * Copyright (C) 2020 Oliver Nightingale
 */i.tokenizer=function(n,r){if(n==null||n==null)return[];if(Array.isArray(n))return n.map(function(h){return new i.Token(i.utils.asString(h).toLowerCase(),i.utils.clone(r))});for(var o=n.toString().toLowerCase(),a=o.length,s=[],l=0,u=0;l<=a;l++){var c=o.charAt(l),d=l-u;if(c.match(i.tokenizer.separator)||l==a){if(d>0){var f=i.utils.clone(r)||{};f.position=[u,d],f.index=s.length,s.push(new i.Token(o.slice(u,l),f))}u=l+1}}return s},i.tokenizer.separator=/[\s\-]+/;/*!
 * lunr.Pipeline
 * Copyright (C) 2020 Oliver Nightingale
 */i.Pipeline=function(){this._stack=[]},i.Pipeline.registeredFunctions=Object.create(null),i.Pipeline.registerFunction=function(n,r){r in this.registeredFunctions&&i.utils.warn("Overwriting existing registered function: "+r),n.label=r,i.Pipeline.registeredFunctions[n.label]=n},i.Pipeline.warnIfFunctionNotRegistered=function(n){var r=n.label&&n.label in this.registeredFunctions;r||i.utils.warn(`Function is not registered with pipeline. This may cause problems when serialising the index.
`,n)},i.Pipeline.load=function(n){var r=new i.Pipeline;return n.forEach(function(o){var a=i.Pipeline.registeredFunctions[o];if(a)r.add(a);else throw new Error("Cannot load unregistered function: "+o)}),r},i.Pipeline.prototype.add=function(){var n=Array.prototype.slice.call(arguments);n.forEach(function(r){i.Pipeline.warnIfFunctionNotRegistered(r),this._stack.push(r)},this)},i.Pipeline.prototype.after=function(n,r){i.Pipeline.warnIfFunctionNotRegistered(r);var o=this._stack.indexOf(n);if(o==-1)throw new Error("Cannot find existingFn");o=o+1,this._stack.splice(o,0,r)},i.Pipeline.prototype.before=function(n,r){i.Pipeline.warnIfFunctionNotRegistered(r);var o=this._stack.indexOf(n);if(o==-1)throw new Error("Cannot find existingFn");this._stack.splice(o,0,r)},i.Pipeline.prototype.remove=function(n){var r=this._stack.indexOf(n);r!=-1&&this._stack.splice(r,1)},i.Pipeline.prototype.run=function(n){for(var r=this._stack.length,o=0;o<r;o++){for(var a=this._stack[o],s=[],l=0;l<n.length;l++){var u=a(n[l],l,n);if(!(u==null||u===""))if(Array.isArray(u))for(var c=0;c<u.length;c++)s.push(u[c]);else s.push(u)}n=s}return n},i.Pipeline.prototype.runString=function(n,r){var o=new i.Token(n,r);return this.run([o]).map(function(a){return a.toString()})},i.Pipeline.prototype.reset=function(){this._stack=[]},i.Pipeline.prototype.toJSON=function(){return this._stack.map(function(n){return i.Pipeline.warnIfFunctionNotRegistered(n),n.label})};/*!
 * lunr.Vector
 * Copyright (C) 2020 Oliver Nightingale
 */i.Vector=function(n){this._magnitude=0,this.elements=n||[]},i.Vector.prototype.positionForIndex=function(n){if(this.elements.length==0)return 0;for(var r=0,o=this.elements.length/2,a=o-r,s=Math.floor(a/2),l=this.elements[s*2];a>1&&(l<n&&(r=s),l>n&&(o=s),l!=n);)a=o-r,s=r+Math.floor(a/2),l=this.elements[s*2];if(l==n||l>n)return s*2;if(l<n)return(s+1)*2},i.Vector.prototype.insert=function(n,r){this.upsert(n,r,function(){throw"duplicate index"})},i.Vector.prototype.upsert=function(n,r,o){this._magnitude=0;var a=this.positionForIndex(n);this.elements[a]==n?this.elements[a+1]=o(this.elements[a+1],r):this.elements.splice(a,0,n,r)},i.Vector.prototype.magnitude=function(){if(this._magnitude)return this._magnitude;for(var n=0,r=this.elements.length,o=1;o<r;o+=2){var a=this.elements[o];n+=a*a}return this._magnitude=Math.sqrt(n)},i.Vector.prototype.dot=function(n){for(var r=0,o=this.elements,a=n.elements,s=o.length,l=a.length,u=0,c=0,d=0,f=0;d<s&&f<l;)u=o[d],c=a[f],u<c?d+=2:u>c?f+=2:u==c&&(r+=o[d+1]*a[f+1],d+=2,f+=2);return r},i.Vector.prototype.similarity=function(n){return this.dot(n)/this.magnitude()||0},i.Vector.prototype.toArray=function(){for(var n=new Array(this.elements.length/2),r=1,o=0;r<this.elements.length;r+=2,o++)n[o]=this.elements[r];return n},i.Vector.prototype.toJSON=function(){return this.elements};/*!
 * lunr.stemmer
 * Copyright (C) 2020 Oliver Nightingale
 * Includes code from - http://tartarus.org/~martin/PorterStemmer/js.txt
 */i.stemmer=(function(){var n={ational:"ate",tional:"tion",enci:"ence",anci:"ance",izer:"ize",bli:"ble",alli:"al",entli:"ent",eli:"e",ousli:"ous",ization:"ize",ation:"ate",ator:"ate",alism:"al",iveness:"ive",fulness:"ful",ousness:"ous",aliti:"al",iviti:"ive",biliti:"ble",logi:"log"},r={icate:"ic",ative:"",alize:"al",iciti:"ic",ical:"ic",ful:"",ness:""},o="[^aeiou]",a="[aeiouy]",s=o+"[^aeiouy]*",l=a+"[aeiou]*",u="^("+s+")?"+l+s,c="^("+s+")?"+l+s+"("+l+")?$",d="^("+s+")?"+l+s+l+s,f="^("+s+")?"+a,h=new RegExp(u),p=new RegExp(d),g=new RegExp(c),v=new RegExp(f),y=/^(.+?)(ss|i)es$/,m=/^(.+?)([^s])s$/,b=/^(.+?)eed$/,S=/^(.+?)(ed|ing)$/,_=/.$/,C=/(at|bl|iz)$/,P=new RegExp("([^aeiouylsz])\\1$"),x=new RegExp("^"+s+a+"[^aeiouwxy]$"),E=/^(.+?[^aeiou])y$/,A=/^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/,R=/^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/,M=/^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/,D=/^(.+?)(s|t)(ion)$/,F=/^(.+?)e$/,I=/ll$/,V=new RegExp("^"+s+a+"[^aeiouwxy]$"),z=function(H){var U,k,X,W,Y,te,oe;if(H.length<3)return H;if(X=H.substr(0,1),X=="y"&&(H=X.toUpperCase()+H.substr(1)),W=y,Y=m,W.test(H)?H=H.replace(W,"$1$2"):Y.test(H)&&(H=H.replace(Y,"$1$2")),W=b,Y=S,W.test(H)){var de=W.exec(H);W=h,W.test(de[1])&&(W=_,H=H.replace(W,""))}else if(Y.test(H)){var de=Y.exec(H);U=de[1],Y=v,Y.test(U)&&(H=U,Y=C,te=P,oe=x,Y.test(H)?H=H+"e":te.test(H)?(W=_,H=H.replace(W,"")):oe.test(H)&&(H=H+"e"))}if(W=E,W.test(H)){var de=W.exec(H);U=de[1],H=U+"i"}if(W=A,W.test(H)){var de=W.exec(H);U=de[1],k=de[2],W=h,W.test(U)&&(H=U+n[k])}if(W=R,W.test(H)){var de=W.exec(H);U=de[1],k=de[2],W=h,W.test(U)&&(H=U+r[k])}if(W=M,Y=D,W.test(H)){var de=W.exec(H);U=de[1],W=p,W.test(U)&&(H=U)}else if(Y.test(H)){var de=Y.exec(H);U=de[1]+de[2],Y=p,Y.test(U)&&(H=U)}if(W=F,W.test(H)){var de=W.exec(H);U=de[1],W=p,Y=g,te=V,(W.test(U)||Y.test(U)&&!te.test(U))&&(H=U)}return W=I,Y=p,W.test(H)&&Y.test(H)&&(W=_,H=H.replace(W,"")),X=="y"&&(H=X.toLowerCase()+H.substr(1)),H};return function(G){return G.update(z)}})(),i.Pipeline.registerFunction(i.stemmer,"stemmer");/*!
 * lunr.stopWordFilter
 * Copyright (C) 2020 Oliver Nightingale
 */i.generateStopWordFilter=function(n){var r=n.reduce(function(o,a){return o[a]=a,o},{});return function(o){if(o&&r[o.toString()]!==o.toString())return o}},i.stopWordFilter=i.generateStopWordFilter(["a","able","about","across","after","all","almost","also","am","among","an","and","any","are","as","at","be","because","been","but","by","can","cannot","could","dear","did","do","does","either","else","ever","every","for","from","get","got","had","has","have","he","her","hers","him","his","how","however","i","if","in","into","is","it","its","just","least","let","like","likely","may","me","might","most","must","my","neither","no","nor","not","of","off","often","on","only","or","other","our","own","rather","said","say","says","she","should","since","so","some","than","that","the","their","them","then","there","these","they","this","tis","to","too","twas","us","wants","was","we","were","what","when","where","which","while","who","whom","why","will","with","would","yet","you","your"]),i.Pipeline.registerFunction(i.stopWordFilter,"stopWordFilter");/*!
 * lunr.trimmer
 * Copyright (C) 2020 Oliver Nightingale
 */i.trimmer=function(n){return n.update(function(r){return r.replace(/^\W+/,"").replace(/\W+$/,"")})},i.Pipeline.registerFunction(i.trimmer,"trimmer");/*!
 * lunr.TokenSet
 * Copyright (C) 2020 Oliver Nightingale
 */i.TokenSet=function(){this.final=!1,this.edges={},this.id=i.TokenSet._nextId,i.TokenSet._nextId+=1},i.TokenSet._nextId=1,i.TokenSet.fromArray=function(n){for(var r=new i.TokenSet.Builder,o=0,a=n.length;o<a;o++)r.insert(n[o]);return r.finish(),r.root},i.TokenSet.fromClause=function(n){return"editDistance"in n?i.TokenSet.fromFuzzyString(n.term,n.editDistance):i.TokenSet.fromString(n.term)},i.TokenSet.fromFuzzyString=function(n,r){for(var o=new i.TokenSet,a=[{node:o,editsRemaining:r,str:n}];a.length;){var s=a.pop();if(s.str.length>0){var l=s.str.charAt(0),u;l in s.node.edges?u=s.node.edges[l]:(u=new i.TokenSet,s.node.edges[l]=u),s.str.length==1&&(u.final=!0),a.push({node:u,editsRemaining:s.editsRemaining,str:s.str.slice(1)})}if(s.editsRemaining!=0){if("*"in s.node.edges)var c=s.node.edges["*"];else{var c=new i.TokenSet;s.node.edges["*"]=c}if(s.str.length==0&&(c.final=!0),a.push({node:c,editsRemaining:s.editsRemaining-1,str:s.str}),s.str.length>1&&a.push({node:s.node,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)}),s.str.length==1&&(s.node.final=!0),s.str.length>=1){if("*"in s.node.edges)var d=s.node.edges["*"];else{var d=new i.TokenSet;s.node.edges["*"]=d}s.str.length==1&&(d.final=!0),a.push({node:d,editsRemaining:s.editsRemaining-1,str:s.str.slice(1)})}if(s.str.length>1){var f=s.str.charAt(0),h=s.str.charAt(1),p;h in s.node.edges?p=s.node.edges[h]:(p=new i.TokenSet,s.node.edges[h]=p),s.str.length==1&&(p.final=!0),a.push({node:p,editsRemaining:s.editsRemaining-1,str:f+s.str.slice(2)})}}}return o},i.TokenSet.fromString=function(n){for(var r=new i.TokenSet,o=r,a=0,s=n.length;a<s;a++){var l=n[a],u=a==s-1;if(l=="*")r.edges[l]=r,r.final=u;else{var c=new i.TokenSet;c.final=u,r.edges[l]=c,r=c}}return o},i.TokenSet.prototype.toArray=function(){for(var n=[],r=[{prefix:"",node:this}];r.length;){var o=r.pop(),a=Object.keys(o.node.edges),s=a.length;o.node.final&&(o.prefix.charAt(0),n.push(o.prefix));for(var l=0;l<s;l++){var u=a[l];r.push({prefix:o.prefix.concat(u),node:o.node.edges[u]})}}return n},i.TokenSet.prototype.toString=function(){if(this._str)return this._str;for(var n=this.final?"1":"0",r=Object.keys(this.edges).sort(),o=r.length,a=0;a<o;a++){var s=r[a],l=this.edges[s];n=n+s+l.id}return n},i.TokenSet.prototype.intersect=function(n){for(var r=new i.TokenSet,o=void 0,a=[{qNode:n,output:r,node:this}];a.length;){o=a.pop();for(var s=Object.keys(o.qNode.edges),l=s.length,u=Object.keys(o.node.edges),c=u.length,d=0;d<l;d++)for(var f=s[d],h=0;h<c;h++){var p=u[h];if(p==f||f=="*"){var g=o.node.edges[p],v=o.qNode.edges[f],y=g.final&&v.final,m=void 0;p in o.output.edges?(m=o.output.edges[p],m.final=m.final||y):(m=new i.TokenSet,m.final=y,o.output.edges[p]=m),a.push({qNode:v,output:m,node:g})}}}return r},i.TokenSet.Builder=function(){this.previousWord="",this.root=new i.TokenSet,this.uncheckedNodes=[],this.minimizedNodes={}},i.TokenSet.Builder.prototype.insert=function(n){var r,o=0;if(n<this.previousWord)throw new Error("Out of order word insertion");for(var a=0;a<n.length&&a<this.previousWord.length&&n[a]==this.previousWord[a];a++)o++;this.minimize(o),this.uncheckedNodes.length==0?r=this.root:r=this.uncheckedNodes[this.uncheckedNodes.length-1].child;for(var a=o;a<n.length;a++){var s=new i.TokenSet,l=n[a];r.edges[l]=s,this.uncheckedNodes.push({parent:r,char:l,child:s}),r=s}r.final=!0,this.previousWord=n},i.TokenSet.Builder.prototype.finish=function(){this.minimize(0)},i.TokenSet.Builder.prototype.minimize=function(n){for(var r=this.uncheckedNodes.length-1;r>=n;r--){var o=this.uncheckedNodes[r],a=o.child.toString();a in this.minimizedNodes?o.parent.edges[o.char]=this.minimizedNodes[a]:(o.child._str=a,this.minimizedNodes[a]=o.child),this.uncheckedNodes.pop()}};/*!
 * lunr.Index
 * Copyright (C) 2020 Oliver Nightingale
 */i.Index=function(n){this.invertedIndex=n.invertedIndex,this.fieldVectors=n.fieldVectors,this.tokenSet=n.tokenSet,this.fields=n.fields,this.pipeline=n.pipeline},i.Index.prototype.search=function(n){return this.query(function(r){var o=new i.QueryParser(n,r);o.parse()})},i.Index.prototype.query=function(n){for(var r=new i.Query(this.fields),o=Object.create(null),a=Object.create(null),s=Object.create(null),l=Object.create(null),u=Object.create(null),c=0;c<this.fields.length;c++)a[this.fields[c]]=new i.Vector;n.call(r,r);for(var c=0;c<r.clauses.length;c++){var d=r.clauses[c],f=null,h=i.Set.empty;d.usePipeline?f=this.pipeline.runString(d.term,{fields:d.fields}):f=[d.term];for(var p=0;p<f.length;p++){var g=f[p];d.term=g;var v=i.TokenSet.fromClause(d),y=this.tokenSet.intersect(v).toArray();if(y.length===0&&d.presence===i.Query.presence.REQUIRED){for(var m=0;m<d.fields.length;m++){var b=d.fields[m];l[b]=i.Set.empty}break}for(var S=0;S<y.length;S++)for(var _=y[S],C=this.invertedIndex[_],P=C._index,m=0;m<d.fields.length;m++){var b=d.fields[m],x=C[b],E=Object.keys(x),A=_+"/"+b,R=new i.Set(E);if(d.presence==i.Query.presence.REQUIRED&&(h=h.union(R),l[b]===void 0&&(l[b]=i.Set.complete)),d.presence==i.Query.presence.PROHIBITED){u[b]===void 0&&(u[b]=i.Set.empty),u[b]=u[b].union(R);continue}if(a[b].upsert(P,d.boost,function(Ae,Pe){return Ae+Pe}),!s[A]){for(var M=0;M<E.length;M++){var D=E[M],F=new i.FieldRef(D,b),I=x[D],V;(V=o[F])===void 0?o[F]=new i.MatchData(_,b,I):V.add(_,b,I)}s[A]=!0}}}if(d.presence===i.Query.presence.REQUIRED)for(var m=0;m<d.fields.length;m++){var b=d.fields[m];l[b]=l[b].intersect(h)}}for(var z=i.Set.complete,G=i.Set.empty,c=0;c<this.fields.length;c++){var b=this.fields[c];l[b]&&(z=z.intersect(l[b])),u[b]&&(G=G.union(u[b]))}var H=Object.keys(o),U=[],k=Object.create(null);if(r.isNegated()){H=Object.keys(this.fieldVectors);for(var c=0;c<H.length;c++){var F=H[c],X=i.FieldRef.fromString(F);o[F]=new i.MatchData}}for(var c=0;c<H.length;c++){var X=i.FieldRef.fromString(H[c]),W=X.docRef;if(z.contains(W)&&!G.contains(W)){var Y=this.fieldVectors[X],te=a[X.fieldName].similarity(Y),oe;if((oe=k[W])!==void 0)oe.score+=te,oe.matchData.combine(o[X]);else{var de={ref:W,score:te,matchData:o[X]};k[W]=de,U.push(de)}}}return U.sort(function(ge,Ee){return Ee.score-ge.score})},i.Index.prototype.toJSON=function(){var n=Object.keys(this.invertedIndex).sort().map(function(o){return[o,this.invertedIndex[o]]},this),r=Object.keys(this.fieldVectors).map(function(o){return[o,this.fieldVectors[o].toJSON()]},this);return{version:i.version,fields:this.fields,fieldVectors:r,invertedIndex:n,pipeline:this.pipeline.toJSON()}},i.Index.load=function(n){var r={},o={},a=n.fieldVectors,s=Object.create(null),l=n.invertedIndex,u=new i.TokenSet.Builder,c=i.Pipeline.load(n.pipeline);n.version!=i.version&&i.utils.warn("Version mismatch when loading serialised index. Current version of lunr '"+i.version+"' does not match serialized index '"+n.version+"'");for(var d=0;d<a.length;d++){var f=a[d],h=f[0],p=f[1];o[h]=new i.Vector(p)}for(var d=0;d<l.length;d++){var f=l[d],g=f[0],v=f[1];u.insert(g),s[g]=v}return u.finish(),r.fields=n.fields,r.fieldVectors=o,r.invertedIndex=s,r.tokenSet=u.root,r.pipeline=c,new i.Index(r)};/*!
 * lunr.Builder
 * Copyright (C) 2020 Oliver Nightingale
 */i.Builder=function(){this._ref="id",this._fields=Object.create(null),this._documents=Object.create(null),this.invertedIndex=Object.create(null),this.fieldTermFrequencies={},this.fieldLengths={},this.tokenizer=i.tokenizer,this.pipeline=new i.Pipeline,this.searchPipeline=new i.Pipeline,this.documentCount=0,this._b=.75,this._k1=1.2,this.termIndex=0,this.metadataWhitelist=[]},i.Builder.prototype.ref=function(n){this._ref=n},i.Builder.prototype.field=function(n,r){if(/\//.test(n))throw new RangeError("Field '"+n+"' contains illegal character '/'");this._fields[n]=r||{}},i.Builder.prototype.b=function(n){n<0?this._b=0:n>1?this._b=1:this._b=n},i.Builder.prototype.k1=function(n){this._k1=n},i.Builder.prototype.add=function(n,r){var o=n[this._ref],a=Object.keys(this._fields);this._documents[o]=r||{},this.documentCount+=1;for(var s=0;s<a.length;s++){var l=a[s],u=this._fields[l].extractor,c=u?u(n):n[l],d=this.tokenizer(c,{fields:[l]}),f=this.pipeline.run(d),h=new i.FieldRef(o,l),p=Object.create(null);this.fieldTermFrequencies[h]=p,this.fieldLengths[h]=0,this.fieldLengths[h]+=f.length;for(var g=0;g<f.length;g++){var v=f[g];if(p[v]==null&&(p[v]=0),p[v]+=1,this.invertedIndex[v]==null){var y=Object.create(null);y._index=this.termIndex,this.termIndex+=1;for(var m=0;m<a.length;m++)y[a[m]]=Object.create(null);this.invertedIndex[v]=y}this.invertedIndex[v][l][o]==null&&(this.invertedIndex[v][l][o]=Object.create(null));for(var b=0;b<this.metadataWhitelist.length;b++){var S=this.metadataWhitelist[b],_=v.metadata[S];this.invertedIndex[v][l][o][S]==null&&(this.invertedIndex[v][l][o][S]=[]),this.invertedIndex[v][l][o][S].push(_)}}}},i.Builder.prototype.calculateAverageFieldLengths=function(){for(var n=Object.keys(this.fieldLengths),r=n.length,o={},a={},s=0;s<r;s++){var l=i.FieldRef.fromString(n[s]),u=l.fieldName;a[u]||(a[u]=0),a[u]+=1,o[u]||(o[u]=0),o[u]+=this.fieldLengths[l]}for(var c=Object.keys(this._fields),s=0;s<c.length;s++){var d=c[s];o[d]=o[d]/a[d]}this.averageFieldLength=o},i.Builder.prototype.createFieldVectors=function(){for(var n={},r=Object.keys(this.fieldTermFrequencies),o=r.length,a=Object.create(null),s=0;s<o;s++){for(var l=i.FieldRef.fromString(r[s]),u=l.fieldName,c=this.fieldLengths[l],d=new i.Vector,f=this.fieldTermFrequencies[l],h=Object.keys(f),p=h.length,g=this._fields[u].boost||1,v=this._documents[l.docRef].boost||1,y=0;y<p;y++){var m=h[y],b=f[m],S=this.invertedIndex[m]._index,_,C,P;a[m]===void 0?(_=i.idf(this.invertedIndex[m],this.documentCount),a[m]=_):_=a[m],C=_*((this._k1+1)*b)/(this._k1*(1-this._b+this._b*(c/this.averageFieldLength[u]))+b),C*=g,C*=v,P=Math.round(C*1e3)/1e3,d.insert(S,P)}n[l]=d}this.fieldVectors=n},i.Builder.prototype.createTokenSet=function(){this.tokenSet=i.TokenSet.fromArray(Object.keys(this.invertedIndex).sort())},i.Builder.prototype.build=function(){return this.calculateAverageFieldLengths(),this.createFieldVectors(),this.createTokenSet(),new i.Index({invertedIndex:this.invertedIndex,fieldVectors:this.fieldVectors,tokenSet:this.tokenSet,fields:Object.keys(this._fields),pipeline:this.searchPipeline})},i.Builder.prototype.use=function(n){var r=Array.prototype.slice.call(arguments,1);r.unshift(this),n.apply(this,r)},i.MatchData=function(n,r,o){for(var a=Object.create(null),s=Object.keys(o||{}),l=0;l<s.length;l++){var u=s[l];a[u]=o[u].slice()}this.metadata=Object.create(null),n!==void 0&&(this.metadata[n]=Object.create(null),this.metadata[n][r]=a)},i.MatchData.prototype.combine=function(n){for(var r=Object.keys(n.metadata),o=0;o<r.length;o++){var a=r[o],s=Object.keys(n.metadata[a]);this.metadata[a]==null&&(this.metadata[a]=Object.create(null));for(var l=0;l<s.length;l++){var u=s[l],c=Object.keys(n.metadata[a][u]);this.metadata[a][u]==null&&(this.metadata[a][u]=Object.create(null));for(var d=0;d<c.length;d++){var f=c[d];this.metadata[a][u][f]==null?this.metadata[a][u][f]=n.metadata[a][u][f]:this.metadata[a][u][f]=this.metadata[a][u][f].concat(n.metadata[a][u][f])}}}},i.MatchData.prototype.add=function(n,r,o){if(!(n in this.metadata)){this.metadata[n]=Object.create(null),this.metadata[n][r]=o;return}if(!(r in this.metadata[n])){this.metadata[n][r]=o;return}for(var a=Object.keys(o),s=0;s<a.length;s++){var l=a[s];l in this.metadata[n][r]?this.metadata[n][r][l]=this.metadata[n][r][l].concat(o[l]):this.metadata[n][r][l]=o[l]}},i.Query=function(n){this.clauses=[],this.allFields=n},i.Query.wildcard=new String("*"),i.Query.wildcard.NONE=0,i.Query.wildcard.LEADING=1,i.Query.wildcard.TRAILING=2,i.Query.presence={OPTIONAL:1,REQUIRED:2,PROHIBITED:3},i.Query.prototype.clause=function(n){return"fields"in n||(n.fields=this.allFields),"boost"in n||(n.boost=1),"usePipeline"in n||(n.usePipeline=!0),"wildcard"in n||(n.wildcard=i.Query.wildcard.NONE),n.wildcard&i.Query.wildcard.LEADING&&n.term.charAt(0)!=i.Query.wildcard&&(n.term="*"+n.term),n.wildcard&i.Query.wildcard.TRAILING&&n.term.slice(-1)!=i.Query.wildcard&&(n.term=""+n.term+"*"),"presence"in n||(n.presence=i.Query.presence.OPTIONAL),this.clauses.push(n),this},i.Query.prototype.isNegated=function(){for(var n=0;n<this.clauses.length;n++)if(this.clauses[n].presence!=i.Query.presence.PROHIBITED)return!1;return!0},i.Query.prototype.term=function(n,r){if(Array.isArray(n))return n.forEach(function(a){this.term(a,i.utils.clone(r))},this),this;var o=r||{};return o.term=n.toString(),this.clause(o),this},i.QueryParseError=function(n,r,o){this.name="QueryParseError",this.message=n,this.start=r,this.end=o},i.QueryParseError.prototype=new Error,i.QueryLexer=function(n){this.lexemes=[],this.str=n,this.length=n.length,this.pos=0,this.start=0,this.escapeCharPositions=[]},i.QueryLexer.prototype.run=function(){for(var n=i.QueryLexer.lexText;n;)n=n(this)},i.QueryLexer.prototype.sliceString=function(){for(var n=[],r=this.start,o=this.pos,a=0;a<this.escapeCharPositions.length;a++)o=this.escapeCharPositions[a],n.push(this.str.slice(r,o)),r=o+1;return n.push(this.str.slice(r,this.pos)),this.escapeCharPositions.length=0,n.join("")},i.QueryLexer.prototype.emit=function(n){this.lexemes.push({type:n,str:this.sliceString(),start:this.start,end:this.pos}),this.start=this.pos},i.QueryLexer.prototype.escapeCharacter=function(){this.escapeCharPositions.push(this.pos-1),this.pos+=1},i.QueryLexer.prototype.next=function(){if(this.pos>=this.length)return i.QueryLexer.EOS;var n=this.str.charAt(this.pos);return this.pos+=1,n},i.QueryLexer.prototype.width=function(){return this.pos-this.start},i.QueryLexer.prototype.ignore=function(){this.start==this.pos&&(this.pos+=1),this.start=this.pos},i.QueryLexer.prototype.backup=function(){this.pos-=1},i.QueryLexer.prototype.acceptDigitRun=function(){var n,r;do n=this.next(),r=n.charCodeAt(0);while(r>47&&r<58);n!=i.QueryLexer.EOS&&this.backup()},i.QueryLexer.prototype.more=function(){return this.pos<this.length},i.QueryLexer.EOS="EOS",i.QueryLexer.FIELD="FIELD",i.QueryLexer.TERM="TERM",i.QueryLexer.EDIT_DISTANCE="EDIT_DISTANCE",i.QueryLexer.BOOST="BOOST",i.QueryLexer.PRESENCE="PRESENCE",i.QueryLexer.lexField=function(n){return n.backup(),n.emit(i.QueryLexer.FIELD),n.ignore(),i.QueryLexer.lexText},i.QueryLexer.lexTerm=function(n){if(n.width()>1&&(n.backup(),n.emit(i.QueryLexer.TERM)),n.ignore(),n.more())return i.QueryLexer.lexText},i.QueryLexer.lexEditDistance=function(n){return n.ignore(),n.acceptDigitRun(),n.emit(i.QueryLexer.EDIT_DISTANCE),i.QueryLexer.lexText},i.QueryLexer.lexBoost=function(n){return n.ignore(),n.acceptDigitRun(),n.emit(i.QueryLexer.BOOST),i.QueryLexer.lexText},i.QueryLexer.lexEOS=function(n){n.width()>0&&n.emit(i.QueryLexer.TERM)},i.QueryLexer.termSeparator=i.tokenizer.separator,i.QueryLexer.lexText=function(n){for(;;){var r=n.next();if(r==i.QueryLexer.EOS)return i.QueryLexer.lexEOS;if(r.charCodeAt(0)==92){n.escapeCharacter();continue}if(r==":")return i.QueryLexer.lexField;if(r=="~")return n.backup(),n.width()>0&&n.emit(i.QueryLexer.TERM),i.QueryLexer.lexEditDistance;if(r=="^")return n.backup(),n.width()>0&&n.emit(i.QueryLexer.TERM),i.QueryLexer.lexBoost;if(r=="+"&&n.width()===1||r=="-"&&n.width()===1)return n.emit(i.QueryLexer.PRESENCE),i.QueryLexer.lexText;if(r.match(i.QueryLexer.termSeparator))return i.QueryLexer.lexTerm}},i.QueryParser=function(n,r){this.lexer=new i.QueryLexer(n),this.query=r,this.currentClause={},this.lexemeIdx=0},i.QueryParser.prototype.parse=function(){this.lexer.run(),this.lexemes=this.lexer.lexemes;for(var n=i.QueryParser.parseClause;n;)n=n(this);return this.query},i.QueryParser.prototype.peekLexeme=function(){return this.lexemes[this.lexemeIdx]},i.QueryParser.prototype.consumeLexeme=function(){var n=this.peekLexeme();return this.lexemeIdx+=1,n},i.QueryParser.prototype.nextClause=function(){var n=this.currentClause;this.query.clause(n),this.currentClause={}},i.QueryParser.parseClause=function(n){var r=n.peekLexeme();if(r!=null)switch(r.type){case i.QueryLexer.PRESENCE:return i.QueryParser.parsePresence;case i.QueryLexer.FIELD:return i.QueryParser.parseField;case i.QueryLexer.TERM:return i.QueryParser.parseTerm;default:var o="expected either a field or a term, found "+r.type;throw r.str.length>=1&&(o+=" with value '"+r.str+"'"),new i.QueryParseError(o,r.start,r.end)}},i.QueryParser.parsePresence=function(n){var r=n.consumeLexeme();if(r!=null){switch(r.str){case"-":n.currentClause.presence=i.Query.presence.PROHIBITED;break;case"+":n.currentClause.presence=i.Query.presence.REQUIRED;break;default:var o="unrecognised presence operator'"+r.str+"'";throw new i.QueryParseError(o,r.start,r.end)}var a=n.peekLexeme();if(a==null){var o="expecting term or field, found nothing";throw new i.QueryParseError(o,r.start,r.end)}switch(a.type){case i.QueryLexer.FIELD:return i.QueryParser.parseField;case i.QueryLexer.TERM:return i.QueryParser.parseTerm;default:var o="expecting term or field, found '"+a.type+"'";throw new i.QueryParseError(o,a.start,a.end)}}},i.QueryParser.parseField=function(n){var r=n.consumeLexeme();if(r!=null){if(n.query.allFields.indexOf(r.str)==-1){var o=n.query.allFields.map(function(l){return"'"+l+"'"}).join(", "),a="unrecognised field '"+r.str+"', possible fields: "+o;throw new i.QueryParseError(a,r.start,r.end)}n.currentClause.fields=[r.str];var s=n.peekLexeme();if(s==null){var a="expecting term, found nothing";throw new i.QueryParseError(a,r.start,r.end)}switch(s.type){case i.QueryLexer.TERM:return i.QueryParser.parseTerm;default:var a="expecting term, found '"+s.type+"'";throw new i.QueryParseError(a,s.start,s.end)}}},i.QueryParser.parseTerm=function(n){var r=n.consumeLexeme();if(r!=null){n.currentClause.term=r.str.toLowerCase(),r.str.indexOf("*")!=-1&&(n.currentClause.usePipeline=!1);var o=n.peekLexeme();if(o==null){n.nextClause();return}switch(o.type){case i.QueryLexer.TERM:return n.nextClause(),i.QueryParser.parseTerm;case i.QueryLexer.FIELD:return n.nextClause(),i.QueryParser.parseField;case i.QueryLexer.EDIT_DISTANCE:return i.QueryParser.parseEditDistance;case i.QueryLexer.BOOST:return i.QueryParser.parseBoost;case i.QueryLexer.PRESENCE:return n.nextClause(),i.QueryParser.parsePresence;default:var a="Unexpected lexeme type '"+o.type+"'";throw new i.QueryParseError(a,o.start,o.end)}}},i.QueryParser.parseEditDistance=function(n){var r=n.consumeLexeme();if(r!=null){var o=parseInt(r.str,10);if(isNaN(o)){var a="edit distance must be numeric";throw new i.QueryParseError(a,r.start,r.end)}n.currentClause.editDistance=o;var s=n.peekLexeme();if(s==null){n.nextClause();return}switch(s.type){case i.QueryLexer.TERM:return n.nextClause(),i.QueryParser.parseTerm;case i.QueryLexer.FIELD:return n.nextClause(),i.QueryParser.parseField;case i.QueryLexer.EDIT_DISTANCE:return i.QueryParser.parseEditDistance;case i.QueryLexer.BOOST:return i.QueryParser.parseBoost;case i.QueryLexer.PRESENCE:return n.nextClause(),i.QueryParser.parsePresence;default:var a="Unexpected lexeme type '"+s.type+"'";throw new i.QueryParseError(a,s.start,s.end)}}},i.QueryParser.parseBoost=function(n){var r=n.consumeLexeme();if(r!=null){var o=parseInt(r.str,10);if(isNaN(o)){var a="boost must be numeric";throw new i.QueryParseError(a,r.start,r.end)}n.currentClause.boost=o;var s=n.peekLexeme();if(s==null){n.nextClause();return}switch(s.type){case i.QueryLexer.TERM:return n.nextClause(),i.QueryParser.parseTerm;case i.QueryLexer.FIELD:return n.nextClause(),i.QueryParser.parseField;case i.QueryLexer.EDIT_DISTANCE:return i.QueryParser.parseEditDistance;case i.QueryLexer.BOOST:return i.QueryParser.parseBoost;case i.QueryLexer.PRESENCE:return n.nextClause(),i.QueryParser.parsePresence;default:var a="Unexpected lexeme type '"+s.type+"'";throw new i.QueryParseError(a,s.start,s.end)}}},(function(n,r){t.exports=r()})(this,function(){return i})})()})(vq)),vq.exports}var WNe=Ewt();const Ws=wc(WNe),wwt=function(t){t.pipeline.remove(Ws.stemmer),t.searchPipeline.remove(Ws.stemmer);const e=Ws.tokenizer,i=function(n){return!arguments.length||n==null?[]:Array.isArray(n)?n.map(o=>new WNe.Token(o.toLowerCase(),{})):n.toString().split(".").reduce((o,a)=>o.concat(e(a)),[])};i.separator=e.separator,Ws.tokenizer=i},UO=class UO{constructor(e,i,n){this.combineWith="AND",this.exactMatch=!1,this.index=Ws(function(){this.use(wwt),this.ref("_id"),e.forEach(r=>{n.includes(r)?this.field(r,{extractor:function(o){return[o[r]]}}):this.field(r)}),i.forEach(r=>this.add(r))}),this.docCount=i.length}documentCount(){return this.docCount}async search(e,i){const n=this.combineWith,r=!this.exactMatch;console.time("lunr-search");const o=this.index.query(function(a){e.term.length>1&&Ws.tokenizer(e.term).map(s=>s.toString()).forEach(s=>{a.term(s,{presence:n==="AND"?Ws.Query.presence.REQUIRED:Ws.Query.presence.OPTIONAL,fields:e.fields,boost:10,usePipeline:!1,wildcard:r?Ws.Query.wildcard.LEADING|Ws.Query.wildcard.TRAILING:Ws.Query.wildcard.NONE})}),i.filter(s=>s.enabled).map(s=>s.term).forEach(s=>{a.term(s.term,{presence:n==="AND"?Ws.Query.presence.REQUIRED:Ws.Query.presence.OPTIONAL,fields:s.fields,boost:10,usePipeline:!1,wildcard:r?Ws.Query.wildcard.TRAILING:Ws.Query.wildcard.NONE})})}).map(a=>({id:a.ref,score:a.score,key:[],terms:[]}));return console.timeEnd("lunr-search"),o}async suggest(e,i){const n=Ws.tokenizer(e.term).map(c=>c.toString()).filter(c=>c.length>1);if(n.length===0)return{suggestions:[],total:0};const r=n[n.length-1],o=this.combineWith;console.time("lunr-suggest-total"),console.time("lunr-suggest-query");const a=this.index.query(function(c){c.term(r,{presence:o==="AND"?Ws.Query.presence.REQUIRED:Ws.Query.presence.OPTIONAL,fields:e.fields,boost:50,usePipeline:!1,wildcard:Ws.Query.wildcard.LEADING|Ws.Query.wildcard.TRAILING}),i.filter(d=>d.enabled).map(d=>d.term).forEach(d=>{c.term(d.term.toLowerCase(),{presence:o==="AND"?Ws.Query.presence.REQUIRED:Ws.Query.presence.OPTIONAL,fields:d.fields,boost:10,usePipeline:!1,wildcard:Ws.Query.wildcard.LEADING|Ws.Query.wildcard.TRAILING})})});console.timeEnd("lunr-suggest-query");const s=a.length>UO.MAX_SUGGEST_RESULTS?a.slice(0,UO.MAX_SUGGEST_RESULTS):a;console.time("lunr-extract-suggestions");const l=await this.extractSuggestionsFromResults(s,e.fields,i);console.timeEnd("lunr-extract-suggestions"),console.timeEnd("lunr-suggest-total");const u=l.length;return{suggestions:l.slice(0,UO.MAX_DISPLAY_SUGGESTIONS),total:u}}async extractSuggestionsFromResults(e,i,n){const r=n.filter(o=>o.enabled).map(o=>o.term.term);return e.map(o=>{const a=[];return Object.keys(o.matchData.metadata).forEach(s=>{Object.keys(o.matchData.metadata[s]).forEach(l=>{i.includes(l)&&a.push({field:l,suggestion:s,terms:[],score:o.score})})}),a}).flat().filter(o=>o.suggestion.trim().length>0).filter(o=>!r.includes(o.suggestion)).filter((o,a,s)=>s.findIndex(l=>l.suggestion===o.suggestion&&l.field===o.field)===a)}setExactMatch(e){this.exactMatch=e}setCombineWith(e){this.combineWith=e}};UO.MAX_SUGGEST_RESULTS=500,UO.MAX_DISPLAY_SUGGESTIONS=100;let Xz=UO;const Awt=["frame_id","frame_name","name","namespace","unit","description","cycle_time","senders","receivers","named_values"],Owt=["namespace"];function Dwt(t){const e=t.map(n=>({...n,frame_id:n.frameId,frame_name:n.name,cycle_time:n.cycleTime,_id:n.longName()})),i=t.flatMap(n=>n.signals.map(r=>({...r,_id:r.longName(),frame_id:n.frameId,frame_name:n.name,namespace:n.namespace??"",cycle_time:n.cycleTime,senders:n.senders,receivers:n.receivers,named_values:Object.entries(r.namedValues??{}).map(([o,a])=>`${o} ${a}`).join(" "),description:[r.description,n.description].filter(Boolean).join(" ")})));return new Xz(Awt,e.concat(i),Owt)}var e5={exports:{}},Rwt=e5.exports,yhe;function Mwt(){return yhe||(yhe=1,(function(t,e){(function(i,n){t.exports=n(ld())})(typeof self<"u"?self:Rwt,function(i){return(function(n){function r(a){if(o[a])return o[a].exports;var s=o[a]={i:a,l:!1,exports:{}};return n[a].call(s.exports,s,s.exports,r),s.l=!0,s.exports}var o={};return r.m=n,r.c=o,r.d=function(a,s,l){r.o(a,s)||Object.defineProperty(a,s,{configurable:!1,enumerable:!0,get:l})},r.n=function(a){var s=a&&a.__esModule?function(){return a.default}:function(){return a};return r.d(s,"a",s),s},r.o=function(a,s){return Object.prototype.hasOwnProperty.call(a,s)},r.p="",r(r.s=0)})([function(n,r,o){function a(){return a=Object.assign?Object.assign.bind():function(m){for(var b=1;b<arguments.length;b++){var S=arguments[b];for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(m[_]=S[_])}return m},a.apply(this,arguments)}function s(m){return d(m)||c(m)||u(m)||l()}function l(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function u(m,b){if(m){if(typeof m=="string")return f(m,b);var S=Object.prototype.toString.call(m).slice(8,-1);return S==="Object"&&m.constructor&&(S=m.constructor.name),S==="Map"||S==="Set"?Array.from(m):S==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(S)?f(m,b):void 0}}function c(m){if(typeof Symbol<"u"&&m[Symbol.iterator]!=null||m["@@iterator"]!=null)return Array.from(m)}function d(m){if(Array.isArray(m))return f(m)}function f(m,b){(b==null||b>m.length)&&(b=m.length);for(var S=0,_=new Array(b);S<b;S++)_[S]=m[S];return _}function h(m){"@babel/helpers - typeof";return(h=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(b){return typeof b}:function(b){return b&&typeof Symbol=="function"&&b.constructor===Symbol&&b!==Symbol.prototype?"symbol":typeof b})(m)}Object.defineProperty(r,"__esModule",{value:!0}),o.d(r,"HighchartsReact",function(){return y});var p=o(1),g=o.n(p),v=typeof window<"u"?p.useLayoutEffect:p.useEffect,y=Object(p.memo)(Object(p.forwardRef)(function(m,b){var S=Object(p.useRef)(),_=Object(p.useRef)(),C=Object(p.useRef)(m.constructorType),P=Object(p.useRef)(m.highcharts);return v(function(){function x(){var A=m.highcharts||(typeof window>"u"?"undefined":h(window))==="object"&&window.Highcharts,R=m.constructorType||"chart";A?A[R]?m.options?_.current=A[R](S.current,m.options,m.callback):console.warn('The "options" property was not passed.'):console.warn('The "constructorType" property is incorrect or some required module is not imported.'):console.warn('The "highcharts" property was not passed.')}if(_.current){if(m.allowChartUpdate!==!1)if(m.constructorType!==C.current||m.highcharts!==P.current)C.current=m.constructorType,P.current=m.highcharts,x();else if(!m.immutable&&_.current){var E;(E=_.current).update.apply(E,[m.options].concat(s(m.updateArgs||[!0,!0])))}else x()}else x()},[m.options,m.allowChartUpdate,m.updateArgs,m.containerProps,m.highcharts,m.constructorType]),v(function(){return function(){_.current&&(_.current.destroy(),_.current=null)}},[]),Object(p.useImperativeHandle)(b,function(){return{get chart(){return _.current},container:S}},[]),g.a.createElement("div",a({},m.containerProps,{ref:S}))}));r.default=y},function(n,r){n.exports=i}])})})(e5)),e5.exports}Mwt();const Lwt=()=>(Math.random()+1).toString(36).substring(2),mhe=500;function GNe(t){var ge,Ee,Re,Ae;const e=J.useRef(void 0),i=J.useRef(null),n=J.useRef(null),r=J.useRef(null),o=J.useRef(null),[a,s]=J.useState([]),[l,u]=J.useState(!1),[c,d]=J.useState([]),[f,h]=J.useState(0),[p,g]=J.useState(""),[v,y]=J.useState(),[m,b]=J.useState("AND"),[S,_]=J.useState(!0),[C,P]=J.useState(!1),[x,E]=J.useState([]),[A,R]=J.useState(-1),[M,D]=J.useState({frame_id:{selected:!1,label:"Frame id"},frame_name:{selected:!1,label:"Frame name"},signal_name:{selected:!1,label:"Signal name"},namespace:{selected:!1,label:"Interface",tokenize:!1},unit:{selected:!1,label:"Unit",tokenize:!1},description:{selected:!1,label:"Description"},cycle_time:{selected:!1,label:"Cycletime"},senders:{selected:!1,label:"Senders"},receivers:{selected:!1,label:"Receivers"},named_values:{selected:!1,label:"Named values"}});function F(Pe){const we=M[Pe];return we?we.label:"unknown field"}J.useEffect(()=>{D(Pe=>{var Te;const we={...Pe};if(t.showChannelField)delete we.namespace,we.channel={selected:!1,label:"Channel",tokenize:!1};else{delete we.channel;const ke=(Te=t.frameEntries)==null?void 0:Te[0];(t.showNamespaceField===!1||t.showNamespaceField===void 0&&ke!=null&&typeof ke.isBrokerFrame=="function"&&!ke.isBrokerFrame())&&delete we.namespace}return we})},[t.frameEntries,t.showNamespaceField,t.showChannelField]);const I=Pe=>{var we;(we=e.current)==null||we.setExactMatch(Pe),P(Pe)},V=Pe=>{var we;(we=e.current)==null||we.setCombineWith(Pe),b(Pe)};function z(Pe){E(we=>we.map((Te,ke)=>ke===Pe?{...Te,enabled:!Te.enabled}:Te))}const G=Pe=>{D(we=>({...we,[Pe]:{...we[Pe],selected:!we[Pe].selected}}))},H=()=>{let Pe=Object.keys(M).filter(we=>M[we].selected);return Pe.length===0&&(Pe=Object.keys(M)),Pe};J.useEffect(()=>{t.searchApi?e.current=t.searchApi:t.frameEntries&&t.frameEntries.length>0&&!e.current?(console.log("Indexing data"),e.current=Dwt(t.frameEntries)):console.log("Data already indexed")},[t.searchApi,t.frameEntries]),J.useEffect(()=>{const Pe=p.trim()!=="",we=x.some(Te=>Te.enabled);!Pe&&!we?t.setFoundSignals(t.frameEntries):te(a)},[a,p,x,t.frameEntries]),J.useEffect(()=>(o.current&&clearTimeout(o.current),p===""?(k(ML(p,H()),x),y(Lwt())):o.current=setTimeout(()=>{k(ML(p,H()),x)},150),()=>{o.current&&clearTimeout(o.current)}),[x,m,p]),J.useEffect(()=>(r.current&&clearTimeout(r.current),r.current=setTimeout(()=>U(),300),()=>{r.current&&clearTimeout(r.current)}),[p,M]),J.useEffect(()=>{},[M,m,C]),J.useEffect(()=>{e.current&&k(ML(p,H()),x)},[C,m]),J.useEffect(()=>{S?U():X()},[S]);const U=async()=>{if(!e.current||!S)return;const Pe=H(),we=ML(p,Pe),Te=await e.current.suggest(we,x);d(Te.suggestions),h(Te.total)},k=async(Pe,we)=>{e.current&&s(await e.current.search(Pe,we))},X=()=>{d([]),h(0),R(-1)},W=Pe=>{if(c.length)switch(Pe.key){case"Escape":Pe.preventDefault(),X();break}};J.useEffect(()=>{if(A===-1)setTimeout(()=>{i.current&&i.current.focus()},0);else if(n.current){const Pe=n.current.querySelector(`[data-index="${A}"]`);Pe==null||Pe.scrollIntoView({block:"nearest"})}},[A]);const Y=Pe=>{if(c.length)switch(Pe.key){case"ArrowDown":Pe.preventDefault(),R(we=>we===c.length-1?we:we+1);break;case"ArrowUp":Pe.preventDefault(),R(we=>Math.max(-1,we-1));break;case"Enter":Pe.preventDefault(),A>=0&&A<c.length?oe(c[A]):X();break;case"Escape":Pe.preventDefault(),X();break;default:X();break}},te=async Pe=>{const we=new Set(Pe.map($e=>$e.id));if(t.filterEntries){t.setFoundSignals(t.filterEntries(t.frameEntries,we));return}const Te=[],ke=t.frameEntries;for(let $e=0;$e<ke.length;$e+=mhe){const Ne=ke.slice($e,$e+mhe);for(const ve of Ne)if(we.has(ve.longName()))Te.push(ve);else{const pe=ve.signals.filter(fe=>we.has(fe.longName()));pe.length>0&&Te.push({...ve,signals:pe})}await new Promise(ve=>setTimeout(ve,0))}t.setFoundSignals(Te)},oe=Pe=>{E([...x,HNe(!0,Pe.suggestion,[Pe.field])]),setTimeout(()=>{i.current&&(i.current.focus(),X(),g(""))},0)},de=()=>L.jsx(L.Fragment,{children:L.jsxs("div",{onKeyDown:W,className:"absolute left-0 right-0 mt-0 z-50 bg-white dark:bg-neutral-800 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-neutral-600 border-t-0 rounded-b-xl shadow-lg text-xs overflow-hidden",style:{minWidth:"300px"},children:[L.jsx("div",{ref:n,className:"max-h-[150px] overflow-y-auto",children:c.sort((Pe,we)=>we.score-Pe.score).map((Pe,we)=>L.jsxs("div",{"data-index":we,onClick:()=>oe(Pe),onMouseMove:()=>R(we),onFocus:()=>R(we),className:`px-3 py-2 cursor-pointer flex justify-between ${A===we?"bg-gray-100 dark:bg-neutral-700":""}`,children:[L.jsx("span",{children:Pe.suggestion}),L.jsx("span",{className:"ml-2 text-gray-500 dark:text-gray-400",children:F(Pe.field)})]},`${Pe.suggestion}-${Pe.field}`))}),f>c.length&&L.jsx("div",{className:"px-3 py-2 text-gray-400 dark:text-gray-500 italic border-t border-gray-100 dark:border-neutral-700",children:`There are ${f} suggestions, showing ${c.length}`})]})});return L.jsxs("div",{className:"text-gray-900 dark:text-gray-100",children:[L.jsxs("div",{className:"relative",children:[L.jsx(bwt,{ref:i,onKeyDown:Y,autoFocus:!0,placeHolder:`Search, e.g ${t.placeholderHint??((Ae=(Re=(Ee=(ge=t.frameEntries)==null?void 0:ge[0])==null?void 0:Ee.signals)==null?void 0:Re[0])==null?void 0:Ae.name)??"Speed"}`,forceSearchValueChange:v,setSearchValue:g,termFilters:x,className:c.length>0?"rounded-t-xl rounded-b-0 bg-white dark:bg-neutral-800":"rounded-xl bg-white dark:bg-neutral-800",getFieldLabel:F,toggleTerm:z,deleteTerm:Pe=>E(x.filter((we,Te)=>Te!==Pe))}),c.length>0&&de()]}),L.jsxs(Twt,{open:l,onOpenChange:u,children:[L.jsxs("div",{className:"flex justify-between items-center mt-1 mx-4 text-xs text-gray-500 dark:text-gray-400",children:[L.jsx("span",{children:t.status??null}),L.jsxs(xwt,{className:"group flex items-center py-0.5 px-1 text-sm text-gray-700 dark:text-gray-300 hover:text-gray-900 dark:hover:text-gray-100 focus:outline-none",children:[L.jsx("span",{className:"mr-1 text-xs",children:"Search options"}),L.jsx(A$,{size:16,className:"transform transition-transform duration-200 group-data-[state=open]:rotate-180"})]})]}),L.jsx("div",{className:"mt-1 grid w-full origin-top",style:{gridTemplateRows:l?"1fr":"0fr",transition:"grid-template-rows 200ms ease-out, opacity 200ms ease-out, transform 200ms ease-out",opacity:l?1:0},children:L.jsx("div",{className:"min-h-0 overflow-hidden",children:L.jsxs("div",{className:"p-3 text-sm border border-gray-200 dark:border-neutral-700 rounded-md bg-gray-50 dark:bg-neutral-800",children:[L.jsxs("div",{className:"flex items-center mb-2",children:[L.jsx("input",{id:"exact-match",type:"checkbox",checked:C,onChange:()=>I(!C),className:"w-4 h-4 rounded border-gray-300 dark:border-neutral-600 text-blue-600 focus:ring-blue-500 bg-white dark:bg-neutral-700"}),L.jsx("label",{htmlFor:"exact-match",className:"ml-2 text-gray-700 dark:text-gray-300 cursor-pointer",children:"Exact match"})]}),L.jsxs("div",{className:"flex items-center mb-2",children:[L.jsx("input",{id:"suggestions",type:"checkbox",checked:S,onChange:()=>_(!S),className:"w-4 h-4 rounded border-gray-300 dark:border-neutral-600 text-blue-600 focus:ring-blue-500 bg-white dark:bg-neutral-700"}),L.jsx("label",{htmlFor:"suggestions",className:"ml-2 text-gray-700 dark:text-gray-300 cursor-pointer",children:"Search suggestions"})]}),L.jsxs("div",{className:"flex items-center mb-4",children:[L.jsx("span",{className:"text-gray-700 dark:text-gray-300 mr-3",children:"Combine With:"}),L.jsxs("label",{className:"flex items-center mr-4 cursor-pointer",children:[L.jsx("input",{type:"radio",name:"combineWith",value:"AND",checked:m==="AND",onChange:Pe=>V(Pe.target.value),className:"w-4 h-4 text-blue-600 border-gray-300 dark:border-neutral-600 focus:ring-blue-500"}),L.jsx("span",{className:"ml-1",children:"AND"})]}),L.jsxs("label",{className:"flex items-center cursor-pointer",children:[L.jsx("input",{type:"radio",name:"combineWith",value:"OR",checked:m==="OR",onChange:Pe=>V(Pe.target.value),className:"w-4 h-4 text-blue-600 border-gray-300 dark:border-neutral-600 focus:ring-blue-500"}),L.jsx("span",{className:"ml-1",children:"OR"})]})]}),L.jsx("p",{className:"mb-2 text-gray-700 dark:text-gray-300",children:"Fields to search in:"}),L.jsx("div",{className:"flex flex-wrap items-center gap-1",children:Object.keys(M).map(Pe=>L.jsx("button",{type:"button",onClick:()=>G(Pe),className:`px-3 py-1 text-xs rounded-md border transition-colors ${M[Pe].selected?"bg-blue-600 text-white border-blue-600 dark:bg-blue-900 dark:border-blue-700":"bg-white dark:bg-neutral-700 text-gray-700 dark:text-gray-300 border-gray-300 dark:border-neutral-600 hover:bg-gray-100 dark:hover:bg-neutral-600"}`,children:F(Pe)},Pe))})]})})})]})]})}const LL=(t,e)=>t+"/"+e;async function kwt(t,e,i){if(i==null||i==="")return[];const n=t.replace(/\/$/,""),r=new URLSearchParams({slim:"false",exact:"false",substring:"false",mode:"search"});r.set("_f_file_path",i);const o=await fetch(`${LL(n,e)}?${r}`);if(!o.ok)return[];const s=(await o.json()).channels??{},l=[];for(const[u,c]of Object.entries(s)){const d=c.frames??{},f=c.type==="broker";for(const[h,p]of Object.entries(d)){const g={namespace:u,name:h,type:"frame",toString(){return`${this.namespace}:${this.name}`}},v=p.signals??{},y=Object.entries(v).map(([b,S])=>{const _={frameId:g,signalName:b,type:"signal",toString(){return`${g.namespace}:${this.signalName}`}},C=`${u}:${b}`,P=S.named_values?Object.fromEntries(Object.entries(S.named_values).map(([x,E])=>[Number(x),E])):void 0;return{id:_,frameName:h,namespace:u,name:b,description:S.description??void 0,unit:S.unit??void 0,min:S.min??void 0,max:S.max??void 0,namedValues:P,longName:()=>C}}),m=p.id??void 0;l.push({name:h,frameId:m,namespace:u,description:p.description??"",max:0,min:0,unit:"",size:p.payload_size??0,isRaw:!1,factor:0,offset:0,cycleTime:p.cycle_time??void 0,senders:p.senders??[],receivers:[],id:g,signals:y,longName:()=>`${u}:${h}`,isBrokerFrame:()=>f})}}return l}async function Iwt(t,e,i){if(i==null||i==="")return[];const n=new URLSearchParams({slim:"false",exact:"false",substring:"false",mode:"search"});n.set("_f_file_path",i);const r=await fetch(`${LL(t,e)}?${n}`);if(!r.ok)return[];const a=(await r.json()).channels??{},s=[];for(const[l,u]of Object.entries(a)){const c=u.frames??{},d=u.type==="lin"?"lin":"can";for(const[f,h]of Object.entries(c)){const p=[];for(const[g,v]of Object.entries(h.signals??{}))p.push({name:g,channel:l,frameName:f,signal:v});s.push({name:f,channel:l,channelType:d,frame:h,signals:p})}}return s}function O4(t,e){return e.length===0?t:`${e.join(",")}:${t}`}class YNe{constructor(e,i,n){this.combineWith="AND",this.exactMatch=!1,this.substringMatch=!1,this._documentCount=0,this.baseUrl=e.replace(/\/$/,""),this.type=i,this.path=n,this.refreshDocumentCount()}async refreshDocumentCount(){try{const e=new URLSearchParams({slim:"false",mode:"status"});this.path&&e.set("_f_file_path",this.path);const i=await fetch(`${LL(this.baseUrl,this.type)}?${e}`);if(i.ok){const n=await i.json();this._documentCount=n.total??0}}catch{}}documentCount(){return this._documentCount}buildQuery(e,i){const n=[];return e.term.length>0&&n.push(O4(e.term,e.fields)),i.filter(r=>r.enabled).forEach(r=>n.push(O4(r.term.term,r.term.fields))),n.join(" ")}async search(e,i){const n=this.buildQuery(e,i).trim();if(!n)return[];const r=new URLSearchParams({q:n,slim:"true",exact:String(this.exactMatch),substring:String(this.substringMatch),mode:"search",operator:this.combineWith.toLowerCase()});this.path&&r.set("_f_file_path",this.path);try{const o=await fetch(`${LL(this.baseUrl,this.type)}?${r}`);if(!o.ok)return[];const a=await o.json();return this._documentCount=a.total,a.ids.map(s=>({id:s,score:0,terms:[]}))}catch{return[]}}async suggest(e,i){const n=e.term.trim()?O4(e.term,e.fields):"";if(!n)return{suggestions:[],total:0};const r=new URLSearchParams({q:n,mode:"suggest",substring:String(this.substringMatch)});this.path&&r.set("_f_file_path",this.path),i.filter(o=>o.enabled).forEach(o=>r.append("selected",O4(o.term.term,o.term.fields)));try{const o=await fetch(`${LL(this.baseUrl,this.type)}?${r}`);if(!o.ok)return{suggestions:[],total:0};const a=await o.json();return{suggestions:a.suggestions.map(s=>({field:s.field,suggestion:s.suggestion,terms:[],score:0})),total:a.total}}catch{return{suggestions:[],total:0}}}async fetchAllFrames(){return kwt(this.baseUrl,this.type,this.path)}async fetchParsedFrames(){return Iwt(this.baseUrl,this.type,this.path)}setExactMatch(e){this.exactMatch=e}setCombineWith(e){this.combineWith=e}setSubstringMatch(e){this.substringMatch=e}hasIndexedFiles(){return this.documentCount()>0}async reindex(){const e=new URLSearchParams;this.path&&e.set("path",this.path);const i=await fetch(`${LL(this.baseUrl,this.type)}/index?${e}`,{method:"POST"});if(!i.ok)throw new Error(`Reindex failed: ${i.status}`);const n=await i.json();return await this.refreshDocumentCount(),n}}function Nwt(t){return new YNe(t,"topology")}function Fwt(t,e){return new YNe(t,"files/signaldb",e)}function qNe(){const t=Bwt(),e=mre();return t||e}function mre(){return XNe("(max-width: 767px)")}function Bwt(){return XNe("(min-width: 768px) and (max-width: 1023px)")}function XNe(t){const e=qt.c(4);let i;e[0]!==t?(i=a=>{const s=window.matchMedia(t);return s.addEventListener("change",a),()=>s.removeEventListener("change",a)},e[0]=t,e[1]=i):i=e[1];const n=i;let r;e[2]!==t?(r=()=>window.matchMedia(t).matches,e[2]=t,e[3]=r):r=e[3];const o=r;return J.useSyncExternalStore(n,o)}const bre="bg-blue-100/60 dark:bg-neutral-700/60",KNe="bg-blue-200/60 dark:bg-zinc-900/80",jwt="mb-1";function Vwt(t){const e=n=>{n.target.checked?t.addSelectedSignalFunction(t.thisSignalEntry):t.removeSelectedSignalFunction(t.thisSignalEntry)};return(n=>{const r=t.selectedSignals.some(s=>s.frameName===n.frameName&&s.name===n.name&&s.namespace===n.namespace),o=t.isLastInFrame?"rounded-b-sm rounded-t-none":"rounded-none",a=L.jsx("fieldset",{children:L.jsxs("div",{className:"grid grid-cols-12 break-words items-center p-1 m-0",children:[L.jsx("div",{className:"col-span-6 min-w-0",children:L.jsxs("div",{className:"flex items-center min-w-0",children:[L.jsx("input",{id:`${n.namespace}-${n.frameName}-${n.name}-signal-item`,type:t.singleSignalSelectionOnly?"radio":"checkbox",checked:r,onChange:s=>e(s),className:"w-4 h-4 shrink-0 border-gray-300 dark:border-neutral-600 text-blue-600 focus:ring-blue-500 cursor-pointer disabled:cursor-not-allowed disabled:opacity-50 bg-white dark:bg-neutral-800"}),L.jsxs("label",{htmlFor:`${n.namespace}-${n.frameName}-${n.name}-signal-item`,title:n.name,className:"min-w-0 truncate text-sm ml-2 cursor-pointer block",children:[n.name," "]})]})}),L.jsx("div",{className:"col-span-1 text-xs flex items-center",children:L.jsx("p",{className:"text-gray-500 dark:text-gray-400 pl-1 m-0 truncate",children:`${n.unit??""}`})}),L.jsx("div",{className:"col-span-3 text-xs flex items-center",children:L.jsx("p",{className:"text-gray-500 dark:text-gray-400 pl-1 m-0 truncate",children:`${n.min??"N/A"} / ${n.max??"N/A"}`})}),L.jsx("div",{className:"col-span-2","aria-hidden":"true"}),L.jsx("div",{className:"col-span-12",children:n.description!=null&&n.description!==""&&L.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-1 pb-0 mb-0 py-0 ml-0 text-wrap",children:n.description})})]})});return L.jsx("div",{className:`${o} p-0.5 ${t.isLastInFrame?`pb-1.5 ${jwt}`:""} ${bre} w-full ${t.className??""}`,children:L.jsx("div",{className:`${KNe} px-1 py-0.5 mx-1 rounded-sm text-gray-900 dark:text-gray-100`,children:a})},`${n.namespace}-${n.frameName}-${n.name}-signal-item`)})(t.thisSignalEntry)}function Hwt(t){const e=qt.c(66),i=t.isFrameSelectable!==!1;let n;e[0]!==t?(n=X=>{var W,Y;X.target.checked?(W=t.addSelectedSignalFunction)==null||W.call(t,t.thisSignalEntry):(Y=t.removeSelectedFrameFunction)==null||Y.call(t,t.thisSignalEntry)},e[0]=t,e[1]=n):n=e[1];const r=n,o=t.thisSignalEntry;let a;e[2]!==t.selectedFrames?(a=t.selectedFrames??[],e[2]=t.selectedFrames,e[3]=a):a=e[3];const s=a;let l;if(e[4]!==o.name||e[5]!==o.namespace||e[6]!==s){let X;e[8]!==o.name||e[9]!==o.namespace?(X=W=>W.name===o.name&&W.namespace===o.namespace,e[8]=o.name,e[9]=o.namespace,e[10]=X):X=e[10],l=s.some(X),e[4]=o.name,e[5]=o.namespace,e[6]=s,e[7]=l}else l=e[7];const u=l,c=u&&t.isFrameRemovalDisabled,d=t.hasSignalsBelow?"rounded-t-sm rounded-b-none":"rounded-sm",f=Uwt,h=`${o.namespace}--${o.name}-signal-item`,p=`${d} p-1 ps-2 pe-1 ${t.isExpanded?"":"pb-1.5"} ${bre} w-full text-gray-900 dark:text-gray-100 ${t.className??""}`;let g;e[11]!==o.name||e[12]!==o.namespace||e[13]!==c||e[14]!==u||e[15]!==i||e[16]!==r?(g=i&&L.jsx("input",{id:`${o.namespace}-${o.name}-signal-item`,type:"checkbox",checked:u,onChange:X=>r(X),disabled:c,className:"w-4 h-4 shrink-0 rounded border-gray-300 dark:border-neutral-600 text-blue-600 focus:ring-blue-500 cursor-pointer disabled:cursor-not-allowed disabled:opacity-50 bg-white dark:bg-neutral-800"}),e[11]=o.name,e[12]=o.namespace,e[13]=c,e[14]=u,e[15]=i,e[16]=r,e[17]=g):g=e[17];const v=i?`${o.namespace}-${o.name}-signal-item`:void 0,y=`${o.frameId} ${o.name} (${o.namespace})`,m=`min-w-0 truncate text-sm ${i?"ml-2":""} font-semibold block ${i&&c?"cursor-not-allowed opacity-70":i?"cursor-pointer":""}`;let b;e[18]!==o.namespace?(b=L.jsx("span",{className:"ml-2 font-normal text-xs text-gray-500 dark:text-gray-400",children:o.namespace}),e[18]=o.namespace,e[19]=b):b=e[19];let S;e[20]!==o.frameId||e[21]!==o.name||e[22]!==v||e[23]!==y||e[24]!==m||e[25]!==b?(S=L.jsxs("label",{htmlFor:v,title:y,className:m,children:[o.frameId," ",o.name," ",b]}),e[20]=o.frameId,e[21]=o.name,e[22]=v,e[23]=y,e[24]=m,e[25]=b,e[26]=S):S=e[26];let _;e[27]!==S||e[28]!==g?(_=L.jsx("div",{className:"col-span-6 min-w-0",children:L.jsxs("div",{className:"flex items-center min-w-0",children:[g,S]})}),e[27]=S,e[28]=g,e[29]=_):_=e[29];const C=`${o.unit??""}`;let P;e[30]!==C?(P=L.jsx("div",{className:"col-span-1 text-xs flex items-center",children:L.jsx("p",{className:"text-gray-500 dark:text-gray-400 m-0 truncate",children:C})}),e[30]=C,e[31]=P):P=e[31];const x=`${o.min??"N/A"} / ${o.max??"N/A"}`;let E;e[32]!==x?(E=L.jsx("div",{className:"col-span-3 text-xs flex items-center",children:L.jsx("p",{className:"text-gray-500 dark:text-gray-400 m-0 truncate",children:x})}),e[32]=x,e[33]=E):E=e[33];let A;e[34]!==t.isExpanded||e[35]!==t.onToggle||e[36]!==t.thisSignalEntry.signals.length?(A=L.jsx("div",{className:"col-span-2 text-sm flex items-center justify-end",children:t.thisSignalEntry.signals.length>0?L.jsx("button",{onClick:t.onToggle,className:"px-1 border-0 bg-transparent cursor-pointer text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 flex-shrink-0 rounded hover:bg-black/5 dark:hover:bg-white/5 transition-colors","aria-expanded":t.isExpanded,"aria-label":t.isExpanded?"Collapse frame":"Expand frame",children:t.isExpanded?L.jsx(IEe,{size:22}):L.jsx(A$,{size:22})}):L.jsx("div",{className:"min-w-[4.5rem] text-right pe-1",children:L.jsx("p",{className:"text-xxs text-gray-500 dark:text-orange-400 m-0 whitespace-nowrap",children:"Frame only"})})}),e[34]=t.isExpanded,e[35]=t.onToggle,e[36]=t.thisSignalEntry.signals.length,e[37]=A):A=e[37];const R=`col-span-12 mb-0 ${t.isFrameSelectable?"ms-6":"ms-0"}`;let M;e[38]!==o.senders?(M=f("Senders",o.senders),e[38]=o.senders,e[39]=M):M=e[39];let D;e[40]!==o.receivers?(D=f("Receivers",o.receivers),e[40]=o.receivers,e[41]=D):D=e[41];const F=o.cycleTime?`${o.cycleTime}ms`:"Not set";let I;e[42]!==F?(I=L.jsx("p",{title:"Cycle Time",className:"m-0 text-xs text-blue-600 dark:text-blue-400",children:F}),e[42]=F,e[43]=I):I=e[43];let V;e[44]!==M||e[45]!==D||e[46]!==I?(V=L.jsxs("div",{className:"flex flex-row text-xs gap-3",children:[M,D,I]}),e[44]=M,e[45]=D,e[46]=I,e[47]=V):V=e[47];let z;e[48]!==R||e[49]!==V?(z=L.jsx("div",{className:R,children:V}),e[48]=R,e[49]=V,e[50]=z):z=e[50];let G;e[51]!==o.description?(G=o.description!=null&&o.description!==""&&L.jsx("p",{className:"text-xs text-gray-500 dark:text-gray-400 mt-0 pb-0 mb-1 py-0 ml-0 text-wrap",children:o.description}),e[51]=o.description,e[52]=G):G=e[52];let H;e[53]!==G?(H=L.jsx("div",{className:"col-span-12 ms-6 me-2",children:G}),e[53]=G,e[54]=H):H=e[54];let U;e[55]!==_||e[56]!==P||e[57]!==E||e[58]!==A||e[59]!==z||e[60]!==H?(U=L.jsx("fieldset",{children:L.jsxs("div",{className:"grid grid-cols-12 break-words items-center p-0 m-0",children:[_,P,E,A,z,H]})}),e[55]=_,e[56]=P,e[57]=E,e[58]=A,e[59]=z,e[60]=H,e[61]=U):U=e[61];let k;return e[62]!==U||e[63]!==h||e[64]!==p?(k=L.jsx("div",{className:p,children:U},h),e[62]=U,e[63]=h,e[64]=p,e[65]=k):k=e[65],k}function Uwt(t,e){return L.jsx(L.Fragment,{children:L.jsxs("div",{className:"flex flex-row items-end text-xs text-gray-500 dark:text-gray-400",title:t,children:[L.jsx("span",{"aria-hidden":"true",className:"-translate-y-[0.08em]",children:"["}),L.jsx("p",{className:"m-0 ",children:e?`${e.map((i,n)=>n===e.length-1?i:`${i}, `)}`:"-"}),L.jsx("span",{"aria-hidden":"true",className:"-translate-y-[0.08em]",children:"]"})]})})}const zwt=20,$wt=48,Wwt=32;function sW(t){"use no memo";const{track:e}=el(),i=WV(),n=mre(),{environment:r}=Lp(),o=J.useMemo(()=>Nwt(r.studioBackendUrl),[r.studioBackendUrl]),[a,s]=J.useState(!1);J.useEffect(()=>{let Te=!1;return o.refreshDocumentCount().then(async()=>{if(!o.hasIndexedFiles()){Te||s(!0);try{await o.reindex(),Te||s(!1)}catch(ke){console.error(ke),Te||s(!1)}}}),()=>{Te=!0}},[o]);const l=J.useRef(null),[u,c]=J.useState(i),[d,f]=J.useState([]),[h,p]=J.useState([]),[g,v]=J.useState(new Set),[y,m]=J.useState(!1),b=Te=>`${Te.namespace}-${Te.name}`,S=Te=>{v(ke=>{const $e=new Set(ke),Ne=b(Te);return $e.has(Ne)?$e.delete(Ne):$e.add(Ne),$e})},_=()=>{u&&v(new Set(u.map(b)))},C=()=>{v(new Set)},P=J.useMemo(()=>!u||u.length===0?!1:u.every(Te=>g.has(b(Te))),[u,g]);J.useEffect(()=>{t.show&&(t.selectedFramesAsOnlySourceOfSignals?f(t.selectedFrames.flatMap(Te=>Te.signals)):f(t.selectedSignals),p(t.selectedFrames),c(i),v(new Set(i.map(b))))},[t.show,t.selectedSignals,t.selectedFrames,t.selectedFramesAsOnlySourceOfSignals,i]);const x=J.useMemo(()=>{if(!u)return[];const Te=[];for(const ke of u)if(Te.push({type:"frame",frame:ke}),g.has(b(ke))){const $e=[...ke.signals].sort((Ne,ve)=>Ne.name.localeCompare(ve.name));for(const Ne of $e)Te.push({type:"signal",signal:Ne,parentFrame:ke})}return Te},[u,g]),E=pre({count:x.length,enabled:t.show??!1,initialRect:{width:100,height:100},getScrollElement:()=>l.current,estimateSize:Te=>{var ke;return((ke=x[Te])==null?void 0:ke.type)==="frame"?$wt:Wwt},getItemKey:Te=>{const ke=x[Te];return ke?ke.type==="frame"?`frame-${b(ke.frame)}`:`signal-${ke.parentFrame.namespace}-${ke.parentFrame.name}-${ke.signal.name}`:Te},overscan:5});J.useEffect(()=>{var Te;(Te=l.current)==null||Te.scrollTo({top:0})},[u]);const A=()=>h.map(ke=>{const $e=d.filter(Ne=>Ne.frameName===ke.name&&Ne.namespace===ke.namespace);return{...ke,signals:$e}}),R=(Te,ke)=>{const $e=Te.frame,Ne=t.enforceFrameSelection&&z($e),ve=g.has(b($e));return L.jsx("div",{className:"text-base flex items-center w-full flex-wrap",children:L.jsx(Hwt,{className:"",thisSignalEntry:$e,isFrameSelectable:t.isFramesSelectable,selectedFrames:h,removeSelectedFrameFunction:k,addSelectedSignalFunction:H,isFrameRemovalDisabled:Ne,isExpanded:ve,hasSignalsBelow:ke,onToggle:()=>S($e)},`${$e.namespace}-${$e.name}`)})},M=(Te,ke,$e)=>L.jsx(L.Fragment,{children:L.jsx(Vwt,{parentFrameEntry:Te.parentFrame,thisSignalEntry:Te.signal,selectedSignals:d,removeSelectedSignalFunction:U,addSelectedSignalFunction:H,singleSignalSelectionOnly:t.singleSignalSelectionOnly,isFirstInFrame:ke,isLastInFrame:$e})}),D=()=>a?L.jsxs("div",{className:"flex-1 min-h-0 flex items-center justify-center gap-2",children:[L.jsx("div",{className:"h-4 w-4 animate-spin rounded-full border-2 border-gray-400 border-t-transparent dark:border-neutral-500 dark:border-t-transparent"}),L.jsx("p",{className:"text-sm text-gray-700 dark:text-gray-300",children:"Indexing signals…"})]}):x.length>0?L.jsx("div",{style:{height:E.getTotalSize(),width:"100%",position:"relative"},children:E.getVirtualItems().map(Te=>{var fe,me,Ce;const ke=x[Te.index];if(!ke)return null;const $e=ke.type==="frame",Ne=$e&&((fe=x[Te.index+1])==null?void 0:fe.type)==="signal",ve=!$e&&((me=x[Te.index-1])==null?void 0:me.type)==="frame",pe=!$e&&(((Ce=x[Te.index+1])==null?void 0:Ce.type)==="frame"||Te.index===x.length-1);return L.jsx("div",{"data-index":Te.index,ref:E.measureElement,style:{position:"absolute",top:0,left:0,width:"100%",transform:`translateY(${Te.start}px)`},className:$e?`pt-0.5 ${Ne?"pb-0":"pb-2"}`:`pt-0 ${pe?"pb-1":"pb-0"}`,children:$e?R(ke,Ne):M(ke,ve,pe)},Te.key)})}):u!==void 0?L.jsxs("div",{className:"flex-1 min-h-0 flex items-center justify-center",children:[L.jsx(jEe,{size:20,className:"text-yellow-500 mr-2"}),L.jsx("p",{className:"my-5 text-sm text-gray-700 dark:text-gray-300",children:"No signals match the current query"})]}):L.jsx(L.Fragment,{children:L.jsx("p",{className:"text-gray-700 dark:text-gray-300",children:"Loading..."})}),F=()=>{t.handleCloseFunction(t.selectedSignals.length)},I=()=>{t.handleCloseFunction(d.length),c(i)},V=()=>{const Te=d.length;if(t.enforceFrameSelection){const ke=A();t.selectEnforcedFramesFunction(ke)}else t.selectSignalsFunction(d,h);e(Fi.AddSignalToPanel,{signalCount:Te}),I()},z=Te=>d.some(ke=>ke.frameName===Te.name&&ke.namespace===Te.namespace),G=Te=>"signals"in Te,H=Te=>{const ke=t.signalLimit??zwt,$e=d.length+h.length;if(G(Te))$e<ke?p([...h,Te]):Ki.warning(cq("Signal limit reached",`You can not have more than ${ke} signal(s) selected. Add another panel to visualize more signal(s).`),{autoClose:1e4,toastId:"signal.picker.limit"});else{if(t.singleSignalSelectionOnly){f([Te]);return}if($e<ke){if(f([...d,Te]),t.autoSelectParentFrame&&t.isFramesSelectable){const Ne=Te.frameName!==Te.name,ve=h.some(pe=>pe.name===Te.frameName&&pe.namespace===Te.namespace);if(Ne&&!ve){const pe=i.find(fe=>fe.name===Te.frameName&&fe.namespace===Te.namespace);pe&&p([...h,pe])}}}else Ki.warning(cq("Signal limit reached",`You can not have more than ${ke} signal(s) selected. Add another panel to visualize more signal(s).`),{autoClose:1e4,toastId:"signal.picker.limit"})}},U=Te=>{f(d.filter(ke=>X(ke)!==X(Te)))},k=Te=>{if(t.enforceFrameSelection&&z(Te)){Ki.warning(cq("Cannot deselect frame","Please deselect all signals in this frame before deselecting the frame itself."),{autoClose:5e3,toastId:"frame.deselect.blocked"});return}p(h.filter(ke=>!(ke.name===Te.name&&ke.namespace===Te.namespace)))},X=Te=>W(Te.name,Te.frameName),W=(Te,ke)=>`${ke}::${Te}`.toLowerCase(),Y=Te=>L.jsx(L.Fragment,{children:L.jsx("div",{className:"min-w-0 max-w-full",children:L.jsx("div",{className:`rounded-sm ${G(Te)?bre:KNe} border p-1 px-2 leading-tight min-w-0`,children:L.jsx("div",{children:L.jsxs("div",{className:"flex items-center justify-between min-w-0",children:[L.jsxs("div",{className:"flex items-end min-w-0 flex-1 overflow-hidden",children:[L.jsx("p",{className:"m-0 text-sm text-gray-900 dark:text-gray-100 truncate min-w-0",children:Te.name}),L.jsx("p",{className:"m-0 text-xs ml-1 text-gray-500 dark:text-gray-400 truncate min-w-0",children:Te.namespace})]}),L.jsx("button",{className:"ml-2 p-0 border-0 bg-transparent cursor-pointer text-gray-500 hover:text-red-500 dark:text-gray-400 dark:hover:text-red-400",onClick:()=>G(Te)?k(Te):U(Te),children:L.jsx(zj,{size:20})})]})})})},`${Te.namespace}-${G(Te)?"":Te.frameName}-${Te.name}`)}),te=()=>{const Te=d.map($e=>Y($e)),ke=h.map($e=>Y($e));return L.jsxs(L.Fragment,{children:[Te,ke]})},oe=()=>L.jsx("div",{className:"my-2",children:L.jsx(GNe,{searchApi:o,frameEntries:i,setFoundSignals:Te=>c(Te),clear:()=>c(i),status:`Showing ${(u==null?void 0:u.map(Te=>Te.signals.length).reduce((Te,ke)=>Te+ke,0))??0} of ${i.map(Te=>Te.signals.length).reduce((Te,ke)=>Te+ke,0)} results`})}),de=()=>L.jsxs("div",{className:"flex-1 min-h-0 flex flex-col",children:[L.jsxs("div",{className:"grid grid-cols-12 gap-0 mb-0 px-0 text-sm items-baseline",title:"Information about Senders, Receivers and Cycle time is displayed below each frame name.",children:[L.jsxs("div",{className:"col-span-6 flex items-baseline",children:[L.jsx("p",{className:"m-0 font-bold text-gray-900 dark:text-gray-100",children:"Name"}),L.jsx("p",{className:"m-0 ml-2 text-xs text-gray-500 dark:text-gray-400",children:"Namespace"})]}),L.jsx("div",{className:"col-span-1 flex flex-col items-start truncate",children:L.jsx("p",{className:"m-0 font-bold truncate text-gray-900 dark:text-gray-100",children:"Unit"})}),L.jsx("div",{className:"col-span-3 flex flex-col items-start truncate",children:L.jsx("p",{className:"m-0 font-bold truncate text-gray-900 dark:text-gray-100",children:"Min/max"})}),L.jsx("div",{className:"col-span-2 flex items-center justify-end",children:L.jsx(Za,{type:fn.NO_BACKGROUND,size:_a.SM,icon:P?dr.NAV_CHEVRON_UP:dr.NAV_CHEVRON_DOWN,label:n?P?"Collapse":"Expand":P?"Collapse all":"Expand all",title:P?"Collapse all frames":"Expand all frames",onClick:()=>P?C():_()})})]}),L.jsx("div",{ref:l,className:"w-full border-b border-t border-gray-200 dark:border-neutral-700 py-1 px-0 flex-1 min-h-0 overflow-y-auto flex flex-col",children:D()})]}),ge=()=>{const Te=d.length+h.length;return L.jsxs("div",{className:"flex-grow min-w-0",children:[L.jsxs("button",{type:"button",title:y?"Collapse selected signals":"Expand selected signals",onClick:()=>m(ke=>!ke),className:"p-0 mr-1 border-0 bg-transparent cursor-pointer text-gray-500 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-200 flex items-center",children:[y?L.jsx(Wr,{type:dr.NAV_CHEVRON_UP,size:16}):L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,size:16}),L.jsxs("span",{className:"text-sm font-bold ml-1 text-gray-900 dark:text-gray-100",children:["Selected signals (",Te,")"]})]}),L.jsx("div",{className:"overflow-hidden transition-all duration-200 ease-out",style:{maxHeight:y?240:0,opacity:y?1:0},children:L.jsx("div",{className:"border-b border-t border-gray-200 dark:border-neutral-700 p-1 mt-1 mb-3 overflow-y-auto min-w-0",children:L.jsx("div",{className:"flex max-h-[150px] min-w-0 flex-wrap content-start gap-1",children:te()})})})]})},Ee=()=>L.jsxs("div",{className:"hidden w-full justify-end lg:flex gap-2",children:[L.jsx(Za,{type:fn.PRIMARY,label:"Cancel",onClick:F}),L.jsx(Za,{type:fn.SUCCESS,label:"Apply",onClick:V})]}),Re=()=>L.jsx(L.Fragment,{children:L.jsx("div",{className:"lg:hidden",children:L.jsxs("div",{className:"flex justify-center ml-3 mt-2 gap-2",children:[L.jsx(Za,{type:fn.PRIMARY,label:"Cancel",onClick:F}),L.jsx(Za,{type:fn.SUCCESS,label:"Apply",onClick:V})]})})}),Ae=()=>L.jsx("div",{className:"pt-2 px-1 pb-0 flex-shrink-0",children:oe()}),Pe=()=>L.jsx("div",{className:"flex-1 min-h-0 flex flex-col",children:de()}),we=()=>L.jsxs("div",{className:"border-0 px-1 my-3 text-left flex-shrink-0",children:[L.jsx("div",{className:"flex justify-between",children:ge()}),Ee(),Re()]});return L.jsxs(yI,{show:t.show,onClose:F,size:"7xl",className:"w-full px-2 flex flex-col min-h-[min(65rem,calc(100vh-1rem))] max-h-[min(65rem,calc(100vh-1rem))] text-gray-900 dark:text-gray-100 m-2",children:[Ae(),Pe(),we()]})}var yq={},uN={},CT={},cN={},dN={},bhe;function kp(){if(bhe)return dN;bhe=1,Object.defineProperty(dN,"__esModule",{value:!0}),dN.isRealNumber=void 0;function t(e){return!isNaN(e)&&isFinite(e)&&e!==Number.MAX_VALUE&&e!==Number.MIN_VALUE&&e!==Number.NEGATIVE_INFINITY}return dN.isRealNumber=t,dN}var She;function ci(){if(She)return cN;She=1,Object.defineProperty(cN,"__esModule",{value:!0}),cN.Guard=void 0;var t=kp(),e=(function(){function i(){}return i.notNull=function(n,r){if(n==null)throw new Error("Argument "+r+" must not be undefined")},i.isTrue=function(n,r){if(!n)throw new Error(r)},i.arraysSameLength=function(n,r,o,a){if(this.notNull(n,r),this.notNull(o,a),n.length!==o.length)throw new Error("Arrays ".concat(r," and ").concat(a," must have the same length"))},i.arraysSameLengthArr=function(n){var r=this;if(n===void 0&&(n=[]),n.forEach(function(s){r.notNull(s.arg,s.name)}),n.length>=0){var o=n[0].arg.length,a=n[0].name;n.forEach(function(s){if(s.arg.length!==o)throw new Error("Arrays ".concat(a," and ").concat(s.name," must have the same length"))})}},i.argumentIsRealNumber=function(n,r){if(!(0,t.isRealNumber)(n))throw new Error("Argument ".concat(r,' must be a real number (not infinite, not NAN). Current value="').concat(n,'".'))},i.argumentIsRealInteger=function(n,r){if(!Number.isInteger(n)||!(0,t.isRealNumber)(n))throw new Error("Argument ".concat(r," must be a real integer number (not infinite, not NAN)"))},i})();return cN.Guard=e,cN}var fN={},_he;function $i(){if(_he)return fN;_he=1,Object.defineProperty(fN,"__esModule",{value:!0}),fN.Point=void 0;var t=(function(){function e(i,n){this.x=i,this.y=n}return e.isEqual=function(i,n){return!((i==null?void 0:i.x)!==(n==null?void 0:n.x)||(i==null?void 0:i.y)!==(n==null?void 0:n.y))},e})();return fN.Point=t,fN}var mq={},Phe;function vs(){return Phe||(Phe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getIs3DSurfaceType=t.getIs2DSurfaceType=t.ESurfaceType=void 0;var e;(function(r){r.SciChartSurfaceType="SciChartSurfaceType",r.SciChartPolarSurfaceType="SciChartPolarSurfaceType",r.SciChart3DSurfaceType="SciChart3DSurfaceType",r.SciChartPieSurfaceType="SciChartPieSurfaceType"})(e=t.ESurfaceType||(t.ESurfaceType={}));function i(r){return r===e.SciChartSurfaceType||e.SciChartPolarSurfaceType}t.getIs2DSurfaceType=i;function n(r){return r===e.SciChart3DSurfaceType}t.getIs3DSurfaceType=n})(mq)),mq}var bq={},Che;function pl(){return Che||(Che=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EXyDirection=void 0,(function(e){e.XDirection="XDirection",e.YDirection="YDirection",e.XyDirection="XyDirection"})(t.EXyDirection||(t.EXyDirection={}))})(bq)),bq}var Sq={},_q={},The;function od(){return The||(The=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.handleInvalidAxisAlignment=t.getIsVertical=t.getIsHorizontal=t.EAxisAlignment=void 0;var e;(function(o){o.Right="Right",o.Left="Left",o.Top="Top",o.Bottom="Bottom"})(e=t.EAxisAlignment||(t.EAxisAlignment={}));var i=function(o){if([e.Bottom,e.Top].includes(o))return!0;if([e.Right,e.Left].includes(o))return!1};t.getIsHorizontal=i;var n=function(o){if((0,t.getIsHorizontal)(o)===!1)return!0;if((0,t.getIsHorizontal)(o)===!0)return!1};t.getIsVertical=n;var r=function(o){throw new Error('Invalid Axis Alignment value: "'.concat(o,'"!'))};t.handleInvalidAxisAlignment=r})(_q)),_q}var xhe;function Eo(){return xhe||(xhe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.testPointInTriangle=t.calcDistanceFromLineSegment=t.calcDotProduct=t.testIsInInterval=t.testIsInXBounds=t.calcAnnotationBordersForAxisMarker=t.testIsInBounds=t.calcDistance=t.calcCrossProduct=t.calcDistanceFromLine=void 0;var e=od(),i=function(p,g,v,y,m,b){return Math.abs((0,t.calcCrossProduct)(v,y,m,b,p,g)/(0,t.calcDistance)(v,y,m,b))};t.calcDistanceFromLine=i;var n=function(p,g,v,y,m,b){return(v-p)*(b-g)-(y-g)*(m-p)};t.calcCrossProduct=n;var r=function(p,g,v,y){var m=p-v,b=g-y;return Math.sqrt(m*m+b*b)};t.calcDistance=r;var o=function(p,g,v,y,m,b,S){return S===void 0&&(S=0),a(p,v-S,m+S)&&a(g,b+S,y-S)};t.testIsInBounds=o;var a=function(p,g,v){return p>=g&&p<=v||p>=v&&p<=g},s=function(p,g,v,y,m,b,S,_,C,P,x,E,A,R){var M={x1:0,x2:0,y1:0,y2:0};return p?g?y.axisAlignment===e.EAxisAlignment.Top?m.axisAlignment===e.EAxisAlignment.Left?(M.x1=b-S.y,M.y1=C-S.y,M.x2=0,M.y2=C+P-S.y):m.axisAlignment===e.EAxisAlignment.Right&&(M.x1=S.width-b+S.y,M.y1=C-S.y,M.x2=S.width,M.y2=C+P-S.y):m.axisAlignment===e.EAxisAlignment.Left?(M.x1=b-S.x+x,M.y1=C-S.y,M.x2=0,M.y2=C+P-S.y):m.axisAlignment===e.EAxisAlignment.Right&&(M.x1=_-x,M.y1=C-S.y,M.x2=S.width,M.y2=C+P-S.y):v&&(y.axisAlignment===e.EAxisAlignment.Top?(M.x1=_+b/2-S.x+E,M.y1=P-S.y+E,M.x2=_-b/2-S.x+E,M.y2=0):(M.x1=_-b/2-S.x+E,M.y1=C-E,M.x2=_+b/2-S.x+E,M.y2=S.height)):g?A?(M.x1=_-b/2+E,M.y1=C+P-S.y,M.x2=_+b/2,M.y2=C):R?(M.x1=_-b/2+x-S.x,M.y1=C-x,M.x2=_+b/2+x-S.x,M.y2=S.height):(M.x1=_-b/2-E,M.y1=C-x,M.x2=_+b/2-E,M.y2=C+P-S.y):v&&(R?(M.x1=b-S.x+E,M.y1=C-P/2,M.x2=0,M.y2=C+P/2):(M.x1=_-E,M.y1=C-P/2-x,M.x2=_+b,M.y2=C+P/2-x)),M};t.calcAnnotationBordersForAxisMarker=s;var l=function(p,g,v){var y=Math.abs(p-g);return y<v};t.testIsInXBounds=l;var u=function(p,g,v,y){return y===void 0&&(y=0),g<=v?g-y<=p&&p<=v+y:v-y<=p&&p<=g+y};t.testIsInInterval=u;var c=function(p,g,v,y,m,b){return(v-p)*(m-v)+(y-g)*(b-y)};t.calcDotProduct=c;var d=function(p,g,v,y,m,b){return(0,t.calcDotProduct)(v,y,m,b,p,g)>0?(0,t.calcDistance)(m,b,p,g):(0,t.calcDotProduct)(m,b,v,y,p,g)>0?(0,t.calcDistance)(v,y,p,g):(0,t.calcDistanceFromLine)(p,g,v,y,m,b)};t.calcDistanceFromLineSegment=d;var f=function(p,g,v,y,m,b){return Math.abs((p*(y-b)+v*(b-g)+m*(g-y))/2)},h=function(p,g,v,y,m,b,S,_){var C=1e-6,P=f(v,y,m,b,S,_),x=f(p,g,m,b,S,_),E=f(v,y,p,g,S,_),A=f(v,y,m,b,p,g);return Math.abs(x+E+A-P)<C};t.testPointInTriangle=h})(Sq)),Sq}var hN={},pN={},Ehe;function Br(){if(Ehe)return pN;Ehe=1,Object.defineProperty(pN,"__esModule",{value:!0}),pN.deleteSafe=void 0;function t(e){e==null||e.delete()}return pN.deleteSafe=t,pN}var Qc={},whe;function Th(){if(whe)return Qc;whe=1,Object.defineProperty(Qc,"__esModule",{value:!0}),Qc.appendRangeFifo=Qc.makeIncArray=Qc.isArraySorted=Qc.arrayRemove=Qc.areArraysEqual=Qc.countUnique=Qc.getUniqueValues=void 0;function t(s){var l=function(u,c,d){return u==null?!1:d.indexOf(u)===c};return s.filter(l)}Qc.getUniqueValues=t;function e(s){return new Set(s).size}Qc.countUnique=e;var i=function(s,l){if(s===l)return!0;if((s==null?void 0:s.length)!==(l==null?void 0:l.length))return!1;if(s&&l){for(var u=0;u<s.length;++u)if(s[u]!==l[u])return!1}return!0};Qc.areArraysEqual=i;function n(s,l){for(var u=0;u<s.length;u++)if(s[u]===l){s.splice(u,1);break}return s}Qc.arrayRemove=n;function r(s,l){l===void 0&&(l=!0);for(var u=!0,c=l?function(f){return s[f]>s[f+1]}:function(f){return s[f]<s[f+1]},d=0;d<s.length-1;d++)if(c(d)){u=!1;break}return u}Qc.isArraySorted=r;function o(s,l,u){var c=Array.from(Array(s)).map(function(d,f){return(l??1)*f});return u?c.map(u):c}Qc.makeIncArray=o;function a(s,l,u,c){var d=l.length,f=s.length;if(u>=d+f){l.length+=f;for(var h=0;h<f;++h)l[d+h]=s[h]}else if(f>u){var p=f-u,g=s.slice(p);l=g}else if(u>d){var v=u-d;l.length=u;for(var h=0;h<f;++h)h<v?l[d+h]=s[h]:l[v-h]=s[h]}else{var v=f;c+f>u&&(v=u-c);for(var h=0;h<f;++h)h<v?l[c+h]=s[h]:l[v-h]=s[h]}}return Qc.appendRangeFifo=a,Qc}var Pq={},Ahe;function Ti(){return Ahe||(Ahe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.webColors=t.parseTArgbToHtmlColor=t.parseArgbToHtmlColor=t.parseColorToTArgb=t.toHex=t.parseColorToUIntAbgr=t.parseColorToUIntArgb=t.parseColorToHexStringAbgr=t.parseColorToHexStringArgb=void 0;function e(h,p){var g=a(h);return"0x"+o(p??g.opacity)+o(g.red)+o(g.green)+o(g.blue)}t.parseColorToHexStringArgb=e;function i(h,p){var g=a(h);return"0x"+o(p||g.opacity)+o(g.blue)+o(g.green)+o(g.red)}t.parseColorToHexStringAbgr=i;function n(h,p){return parseInt(e(h,p),16)}t.parseColorToUIntArgb=n;function r(h,p){return parseInt(i(h,p),16)}t.parseColorToUIntAbgr=r;function o(h){var p=h.toString(16);return p.length===1?"0"+p:p}t.toHex=o;function a(h){if(!h||!h.length||h.length>50)throw Error("'"+h+"' is not a valid color...");var p=h.match(/^#?([0-9a-f]{3})$/i);if(p){var g=p[1],v=255,y=parseInt(g.charAt(0),16)*17,m=parseInt(g.charAt(1),16)*17,b=parseInt(g.charAt(2),16)*17;return u([y,m,b],["red","green","blue"]),{opacity:v,red:y,green:m,blue:b}}var S=h.match(/^#?([0-9a-f]{6})$/i);if(S){var g=S[1],v=255,y=parseInt(g.substr(0,2),16),m=parseInt(g.substr(2,2),16),b=parseInt(g.substr(4,2),16);return u([y,m,b],["red","green","blue"]),{opacity:v,red:y,green:m,blue:b}}var _=h.match(/^#?([0-9a-f]{8})$/i);if(_){var g=_[1],y=parseInt(g.substr(0,2),16),m=parseInt(g.substr(2,2),16),b=parseInt(g.substr(4,2),16),v=parseInt(g.substr(6,2),16);return u([v,y,m,b],["opacity","red","green","blue"]),{opacity:v,red:y,green:m,blue:b}}var C=h.match(/^rgba\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d*\.?\d*)\s*\)$/i);if(C){var P=parseFloat(C[4]);c(P);var v=d(P),y=parseInt(C[1],10),m=parseInt(C[2],10),b=parseInt(C[3],10);return u([y,m,b],["red","green","blue"]),{opacity:v,red:y,green:m,blue:b}}var x=t.webColors[h.toLowerCase()];if(x)return a(x);throw Error("'"+h+"' is not a valid color...")}t.parseColorToTArgb=a;var s=function(h){var p=h.toString(16),g=p.length;if(g>8)throw new Error("HTML color length cannot be greater than 8");var v=function(b,S){var _=S-b.length,C=new Array(_+1).join("0");return C+b},y=v(p.substr(-6),6),m=v(p.substring(0,p.length-6),2);return"#"+y+m};t.parseArgbToHtmlColor=s;var l=function(h){var p=f(h.red),g=f(h.green),v=f(h.blue),y=f(h.opacity);return("#"+p+g+v+y).toUpperCase()};t.parseTArgbToHtmlColor=l;function u(h,p){h.forEach(function(g,v){var y=p[v];if(g===void 0)throw Error("parseColor error ".concat(y," color should not be null"));if(Number.isNaN(g))throw Error("parseColor error ".concat(y," color should not be NaN"));if(g<0||g>255)throw Error("parseColor error ".concat(y," color should be within [0, 255] range"))})}function c(h){if(h===void 0)throw Error("parseColor error opacity should not be null");if(Number.isNaN(h))throw Error("parseColor error opacity should not be NaN");if(h<0||h>1)throw Error("parseColor error opacity should be within [0, 1] range")}var d=function(h){return h>=1?255:h<=0?0:Math.floor(h*256)},f=function(h){if(h>=256)return"ff";if(h<=0)return"00";var p=h.toString(16);return p.length===1?"0"+p:p};t.webColors={transparent:"#00000000",aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgrey:"#a9a9a9",darkgreen:"#006400",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#adff2f",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgrey:"#d3d3d3",lightgreen:"#90ee90",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"}})(Pq)),Pq}var gN={},bh={},Ohe;function Uo(){if(Ohe)return bh;Ohe=1;var t={},e;Object.defineProperty(bh,"__esModule",{value:!0}),bh.NEUTRAL_COLOR=bh.EPSILON=bh.DEFAULT_HEIGHT=bh.DEFAULT_WIDTH=bh.IS_TEST_ENV=void 0;var i=!1;return bh.IS_TEST_ENV=i,typeof process<"u"&&(bh.IS_TEST_ENV=i=((e=t)===null||e===void 0?void 0:e.TEST_ENV)==="1"),bh.DEFAULT_WIDTH=900,bh.DEFAULT_HEIGHT=600,bh.EPSILON=1e-4,bh.NEUTRAL_COLOR=4294967295,bh}var Cq={},vN={},yN={},Dhe;function pa(){if(Dhe)return yN;Dhe=1,Object.defineProperty(yN,"__esModule",{value:!0}),yN.Thickness=void 0;var t=ci(),e=(function(){function i(n,r,o,a){this.top=n,this.right=r,this.bottom=o,this.left=a}return i.fromString=function(n){t.Guard.notNull(n,"str");var r=n.split(" ").map(function(o){return parseFloat(o)});if(r.length!==4)throw new Error("Expected string in the format '1 2 3 4' where values are top, right bottom and left");return new i(r[0],r[1],r[2],r[3])},i.fromNumber=function(n){return new i(n,n,n,n)},i.areEqual=function(n,r){return!n||!r?!1:n.top===r.top&&n.right===r.right&&n.bottom===r.bottom&&n.left===r.left},i.mergeMax=function(n,r){var o=new i(0,0,0,0);return o.top=Math.max(n.top,r.top),o.left=Math.max(n.left,r.left),o.bottom=Math.max(n.bottom,r.bottom),o.right=Math.max(n.right,r.right),o},i.mergeAdd=function(n,r){return new i(n.top+r.top,n.right+r.right,n.bottom+r.bottom,n.left+r.left)},i.mergeSubtract=function(n,r){return new i(n.top-r.top,n.right-r.right,n.bottom-r.bottom,n.left-r.left)},i})();return yN.Thickness=e,yN}var TT={},Rhe;function kh(){if(Rhe)return TT;Rhe=1;var t=TT&&TT.__spreadArray||function(i,n,r){if(r||arguments.length===2)for(var o=0,a=n.length,s;o<a;o++)(s||!(o in n))&&(s||(s=Array.prototype.slice.call(n,0,o)),s[o]=n[o]);return i.concat(s||Array.prototype.slice.call(n))};Object.defineProperty(TT,"__esModule",{value:!0}),TT.Logger=void 0;var e=(function(){function i(){}return i.log=function(n){for(var r=[],o=1;o<arguments.length;o++)r[o-1]=arguments[o];console.log(n,r)},i.debug=function(n){for(var r=[],o=1;o<arguments.length;o++)r[o-1]=arguments[o];i.enableDebug&&console.debug.apply(console,t([n],r,!1))},i.enableDebug=!1,i})();return TT.Logger=e,TT}var Mhe;function ZD(){if(Mhe)return vN;Mhe=1,Object.defineProperty(vN,"__esModule",{value:!0}),vN.labelCache=void 0;var t=Br(),e=pa(),i=kh(),n=new Map,r={},o=0,a=function(x){for(var E in r)if(r.hasOwnProperty(E)){var A=r[E];if(A&&_(x,A.style))return A.uses++,E}o++;var R=o.toString();return r[R]={style:x,uses:1},R},s=function(x){var E=r[x];if(E){E.uses--;var A=r[x];A&&A.uses===0&&h(x)}},l=function(x,E){return"".concat(x,"|:|").concat(E)},u=function(x){var E=x.indexOf("|:|"),A=x.substring(0,E-1),R=x.substring(E+3);return{text:A,styleId:R}},c=function(x,E){var A=l(x,E),R=n.get(A);return R&&(R.lastUsed=Date.now()),R},d=function(x,E,A){var R=l(x,E);n.set(R,A)},f=function(x,E){var A=r[x.toString()];return A?_(A.style,E):!1},h=function(x){for(var E=0,A=Array.from(n.keys());E<A.length;E++){var R=A[E],M=u(R);M.text;var D=M.styleId;if(D===x){var F=n.get(R);n.delete(R);try{(0,t.deleteSafe)(F.bitmapTexture)}catch(I){i.Logger.debug(I)}}}},p=200,g=1e3*60,v=function(){return p},y=function(x){p=x},m=function(){return g},b=function(x){g=x},S=function(){if(n.size>p)try{var x=Math.min(Math.floor(n.size/2),(n.size-p)*2),E=Array.from(n.entries());E.sort(function(F,I){return F[1].lastUsed-I[1].lastUsed});for(var A=0;A<x;A++){var R=E[A],M=R[0],D=R[1];D.bitmapTexture=(0,t.deleteSafe)(D.bitmapTexture),n.delete(M)}}catch(F){console.warn(F)}},_=function(x,E){return x.alignment===E.alignment&&x.multilineAlignment===E.multilineAlignment&&x.color===E.color&&x.fontFamily===E.fontFamily&&x.fontSize===E.fontSize&&x.fontStyle===E.fontStyle&&x.fontWeight===E.fontWeight&&(x.padding===void 0&&E.padding===void 0||e.Thickness.areEqual(x.padding,E.padding))&&x.extras===E.extras&&x.rotation===E.rotation&&x.providerId===E.providerId},C=function(){n.clear();for(var x in r)delete r[x]},P=function(){return n.size};return vN.labelCache={getStyleId:a,freeStyle:s,getLabel:c,setLabel:d,checkStyle:f,getMaxSize:v,setMaxSize:y,getSize:P,getMinAge:m,setMinAge:b,pruneCache:S,resetCache:C},vN}var Tq={},Lhe;function $v(){return Lhe||(Lhe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getOtherPieDestinations=t.getOther3DDestinations=t.getOther2DDestinations=t.getOther3DMultiChartDestinations=t.getOther2DMultiChartDestinations=t.sciChartPieDestinations=t.sciChart3DSingleDestinations=t.sciChartSingleDestinations=t.sciChart3DDestinations=t.sciChartDestinations=void 0,t.sciChartDestinations=[],t.sciChart3DDestinations=[],t.sciChartSingleDestinations=[],t.sciChart3DSingleDestinations=[],t.sciChartPieDestinations=[];function e(a){return t.sciChartDestinations.filter(function(s){return s.sciChartSurface!==a})}t.getOther2DMultiChartDestinations=e;function i(a){return t.sciChart3DDestinations.filter(function(s){return s.sciChartSurface!==a})}t.getOther3DMultiChartDestinations=i;function n(a){return t.sciChartDestinations.concat(t.sciChartSingleDestinations).filter(function(s){return s.sciChartSurface!==a})}t.getOther2DDestinations=n;function r(a){return t.sciChart3DDestinations.concat(t.sciChart3DSingleDestinations).filter(function(s){return s.sciChartSurface!==a})}t.getOther3DDestinations=r;function o(a){return t.sciChartPieDestinations.filter(function(s){return s.sciChartSurface!==a})}t.getOtherPieDestinations=o})(Tq)),Tq}var xT={},khe;function hl(){if(khe)return xT;khe=1,Object.defineProperty(xT,"__esModule",{value:!0}),xT.base64Id=xT.generateGuid=void 0;var t=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(i){var n=Math.random()*16|0,r=i==="x"?n:n&3|8;return r.toString(16)})};xT.generateGuid=t;var e=function(i){i===void 0&&(i=22);for(var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r="";r.length<i;){var o=Math.floor(Math.random()*64);r+=n.charAt(o)}return r};return xT.base64Id=e,xT}var Ihe;function gm(){return Ihe||(Ihe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.MemoryUsageHelper=t.generateIdentifier=t.ObjectRegistry=void 0;var e=ZD(),i=$v(),n=hl(),r=(function(){function s(){var l=this;this.weakMapRegistry=new WeakMap,this.undeletedObjectsMap=new Map,this.uncollectedObjectsMap=new Map,this.finalizationRegistry=new FinalizationRegistry(function(u){l.uncollectedObjectsMap.delete(u),l.onCollect(u)})}return s.prototype.add=function(l,u,c){var d,f;c===void 0&&(c={isWasmObject:!1});var h=c.isWasmObject;this.weakMapRegistry.has(l)&&console.warn("Adding existing entry to the registry!",u),this.undeletedObjectsMap.has(u)&&console.warn("Adding existing entry id to the registry!",u),this.finalizationRegistry.register(l,u),this.weakMapRegistry.set(l,u);var p=(f=(d=c==null?void 0:c.revocableToken)===null||d===void 0?void 0:d.proxy)!==null&&f!==void 0?f:c==null?void 0:c.proxy,g=c==null?void 0:c.revocableToken;p&&this.weakMapRegistry.set(p,u);var v=new WeakRef(l),y=p&&new WeakRef(p),m=g&&new WeakRef(g),b={isWasmObject:h,objectRef:v,proxyRef:y,revocableTokenRef:m};l.delete&&this.undeletedObjectsMap.set(u,b),this.uncollectedObjectsMap.set(u,b)},s.prototype.remove=function(l){return!this.undeletedObjectsMap.has(l)&&!this.uncollectedObjectsMap.has(l)&&console.warn("".concat(l," was not found in the ObjectRegistry!")),this.undeletedObjectsMap.delete(l)},s.prototype.getObjectId=function(l){return this.weakMapRegistry.get(l)},s.prototype.deleteIDeletableObjects=function(){var l=this;this.undeletedObjectsMap.forEach(function(u,c){u.isWasmObject||l.deleteEntry(u,c)})},s.prototype.deleteWasmObjects=function(){var l=this;this.undeletedObjectsMap.forEach(function(u,c){u.isWasmObject&&l.deleteEntry(u,c)})},s.prototype.log=function(){var l=this,u=Array.from(this.undeletedObjectsMap.keys()),c=Array.from(this.uncollectedObjectsMap.keys()),d=u.filter(function(p){return!l.uncollectedObjectsMap.has(p)}),f=c.filter(function(p){return!l.undeletedObjectsMap.has(p)}),h=e.labelCache.getSize();console.log("Object Registry Log Start:"),console.log("undeletedObjectsMap",this.undeletedObjectsMap),console.log("uncollectedObjectsMap",this.uncollectedObjectsMap),console.log("collectedNotDeleted",d),console.log("deletedNotCollected",f),console.log("weakMap",this.weakMapRegistry),console.log("axisLabelCacheSize",h),console.log("Object Registry Log End")},s.prototype.getState=function(){var l=Array.from(this.undeletedObjectsMap.keys()),u=Array.from(this.uncollectedObjectsMap.keys()),c={};return l.length&&(c.undeletedObjectsIds=l),u.length&&(c.uncollectedObjectsIds=u),c},s.prototype.deleteEntry=function(l,u){var c=l.objectRef.deref();c?(c.delete(),this.remove(u)):console.warn("Looks like the ".concat(u," has already been garbage collected, thus the proper cleanup could not be executed!"))},s.prototype.onCollect=function(l){},s})();t.ObjectRegistry=r;var o=function(s){return"".concat(s==null?void 0:s.constructor.name,"_").concat((0,n.generateGuid)())};t.generateIdentifier=o;var a=(function(){function s(){}return Object.defineProperty(s,"isMemoryUsageDebugEnabled",{get:function(){return this.isMemoryUsageDebugEnabledProperty},set:function(l){l&&console.warn("Memory usage debug enabled! Make sure to disable it for production build!")},enumerable:!1,configurable:!0}),s.register=function(l,u){var c;if(!l){console.warn('Registering invalid object "'.concat(l,'"!'));return}(c=s.objectRegistry)===null||c===void 0||c.add(l,u??(0,t.generateIdentifier)(l))},s.unregister=function(l){var u;(u=s.objectRegistry)===null||u===void 0||u.remove(l)},s.destroyMultiChart=function(){i.sciChartDestinations.forEach(function(l){return l.sciChartSurface.delete(!0)}),i.sciChart3DDestinations.forEach(function(l){return l.sciChartSurface.delete(!0)})},s.destroySingleCharts=function(){i.sciChartSingleDestinations.forEach(function(l){return l.sciChartSurface.delete(!0)}),i.sciChart3DSingleDestinations.forEach(function(l){return l.sciChartSurface.delete(!0)})},s.destroyPieCharts=function(){i.sciChartPieDestinations.forEach(function(l){return l.sciChartSurface.delete(!0)})},s.destroyAllCharts=function(){s.destroyMultiChart(),s.destroySingleCharts(),s.destroyPieCharts()},s.isMemoryUsageDebugEnabledProperty=!1,s})();t.MemoryUsageHelper=a})(Cq)),Cq}var Xu={},xq={},Nhe;function ZNe(){return Nhe||(Nhe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EColorMapMode=void 0,(function(e){e.Interpolated="Interpolated",e.Stepped="Stepped"})(t.EColorMapMode||(t.EColorMapMode={}))})(xq)),xq}var Fhe;function Ju(){if(Fhe)return Xu;Fhe=1,Object.defineProperty(Xu,"__esModule",{value:!0}),Xu.applyOpacityToHtmlColor=Xu.uintArgbColorIsTransparent=Xu.uintArgbColorOverrideOpacity=Xu.uintArgbColorMultiplyOpacity=Xu.uintArgbColorToAbgr=Xu.linearColorMapLerp=Xu.uintArgbColorLerp=Xu.uintArgbColorLerp24bit=void 0;var t=ZNe(),e=Ti();function i(c,d,f){var h=16711935,p=4278255360,g=256*f,v=256-g;return(c&h)*v+(d&h)*g>>8&h|(c&p)*v+(d&p)*g>>8&p}Xu.uintArgbColorLerp24bit=i;function n(c,d,f){var h=c>>>16,p=(c&65535)>>>0,g=d>>>16,v=(d&65535)>>>0,y=i(h,g,f),m=i(p,v,f);return(y<<16>>>0)+m}Xu.uintArgbColorLerp=n;function r(c,d){if(d<c.Minimum)return(0,e.parseColorToUIntArgb)(c.GradientStops[0].color);var f=1/(c.Maximum-c.Minimum),h=(d-c.Minimum)*f,p=c.GradientStops,g=[],v;for(v=1;v<p.length;v++)g.push(1/(p[v].offset-p[v-1].offset));for(v=0;v<p.length-1;v++){var y=p[v],m=p[v+1];if(h>=y.offset&&h<m.offset){if(c.Mode===t.EColorMapMode.Stepped)return(0,e.parseColorToUIntArgb)(y.color);var b=(h-y.offset)*g[v];return n((0,e.parseColorToUIntArgb)(y.color),(0,e.parseColorToUIntArgb)(m.color),b)}}return(0,e.parseColorToUIntArgb)(c.GradientStops[v].color)}Xu.linearColorMapLerp=r;function o(c){var d=(c&16711680)>>16,f=(c&65280)>>8,h=c&255,p=c-(c&16777215);return p+=h<<16,p+=f<<8,p+=d,p}Xu.uintArgbColorToAbgr=o;function a(c,d){var f=c-(c&16777215);f=f>>>24,f*=d,f=Math.floor(f),f=f*16777216;var h=c&16777215;return f+h}Xu.uintArgbColorMultiplyOpacity=a;function s(c,d){var f=d*255;f=Math.floor(f),f=f*16777216;var h=c&16777215;return f+h}Xu.uintArgbColorOverrideOpacity=s;function l(c){var d=c-(c&16777215);return d!==4278190080}Xu.uintArgbColorIsTransparent=l;function u(c,d){var f=(0,e.parseColorToTArgb)(c);return f.opacity=Math.floor(d*256),(0,e.parseTArgbToHtmlColor)(f)}return Xu.applyOpacityToHtmlColor=u,Xu}var Bhe;function JNe(){if(Bhe)return gN;Bhe=1,Object.defineProperty(gN,"__esModule",{value:!0}),gN.createSCRTPen=void 0;var t=Uo();gm();var e=Ju(),i=Ti(),n=function(r,o,a,s,l,u){if(u===void 0&&(u=!0),!(t.IS_TEST_ENV||!o)){var c=(0,e.uintArgbColorMultiplyOpacity)((0,i.parseColorToUIntArgb)(o),s);if(isNaN(c))throw new Error("Color code ".concat(o," cannot be converted to an ARGB integer"));var d=new r.SCRTPenDescriptor;if(d.m_uiColor=c,d.m_fThickness=a,d.m_bAntiAliased=u,l&&l.length){var f=new r.FloatVector;l.forEach(function(p){return f.push_back(p)}),d.SetDashPattern(f)}var h=new r.SCRTPen(d);return d.delete(),h}};return gN.createSCRTPen=n,gN}var ET={},wT={},jhe;function ps(){if(jhe)return wT;jhe=1,Object.defineProperty(wT,"__esModule",{value:!0}),wT.receiveNextEvent=wT.EventHandler=void 0;var t=(function(){function i(){this.handlers=[]}return i.prototype.subscribe=function(n){this.handlers.includes(n)||this.handlers.push(n)},i.prototype.unsubscribe=function(n){this.handlers=this.handlers.filter(function(r){return r!==n})},i.prototype.unsubscribeAll=function(){this.handlers=[]},i.prototype.raiseEvent=function(n){this.handlers.slice(0).forEach(function(r){return r(n)})},i})();wT.EventHandler=t;function e(i){return new Promise(function(n,r){var o=function(a){try{i.unsubscribe(o),n(a)}catch(s){r(s)}};try{i.subscribe(o)}catch(a){r(a)}})}return wT.receiveNextEvent=e,wT}var L0={},bf={},Vhe;function mo(){if(Vhe)return bf;Vhe=1,Object.defineProperty(bf,"__esModule",{value:!0}),bf.getSubTypes=bf.createType=bf.getFunction=bf.registerFunction=bf.registerWasmType=bf.registerType=void 0;var t=new Map,e=function(s,l,u,c){c===void 0&&(c=!1);var d=s+":"+l;if(t.has(d)&&!c)throw new Error("Type "+d+" is already registered.  Call with overWrite: true if you intended to replace it.");t.set(d,{func:u})};bf.registerType=e;var i=function(s,l,u,c){c===void 0&&(c=!1);var d=s+":"+l;if(t.has(d)&&!c)throw new Error("Type "+d+" is already registered.  Call with overWrite: true if you intended to replace it.");t.set(d,{wasm:!0,func:u})};bf.registerWasmType=i;var n=function(s,l,u,c){c===void 0&&(c=!1);var d=s+":"+l;if(t.has(d)&&!c)throw new Error("Function "+d+" is already registered.  Call with overWrite: true if you intended to replace it.");t.set(d,{func:u})};bf.registerFunction=n;var r=function(s,l){var u=s+":"+l,c=t.get(u);if(c)return c.func;throw new Error("Nothing registered for "+u)};bf.getFunction=r;var o=function(s,l,u,c){var d=s+":"+l,f=t.get(d);if(f){var h=f.wasm,p=f.func;return h?p(u,c):p(c)}else throw new Error("Nothing registered for "+d)};bf.createType=o;var a=function(s){var l=Array.from(t.keys());return l.map(function(u){return u.split(":")}).filter(function(u){return u[0]===s}).map(function(u){return u[1]})};return bf.getSubTypes=a,bf}var AT={},OT={},Hhe;function vm(){if(Hhe)return OT;Hhe=1,Object.defineProperty(OT,"__esModule",{value:!0}),OT.checkBuildStamp=OT.libraryVersion=void 0;var t="2026-02-02T00:00:00",e;OT.libraryVersion="5.0.178";var i=function(n){if(e!==void 0)return e;if(!n)return!1;if(n.SCRTCredentials.GetBuildStamp){var r=n.SCRTCredentials.GetBuildStamp();if(r===t)return e=!0,e;console.warn("Build stamp diff: JS - ".concat(t,"; WASM - ").concat(r))}return console.warn(`The SciChart webassembly module is from a different version than the javascript that is calling it.
    Ensure that your build process is copying the correct wasm and data files.`),e=!1,e};return OT.checkBuildStamp=i,OT}var mN={},Uhe;function Sre(){if(Uhe)return mN;Uhe=1,Object.defineProperty(mN,"__esModule",{value:!0}),mN.Dictionary=void 0;var t=(function(){function e(){this.items={},this.countProperty=0}return e.prototype.containsKey=function(i){return this.items.hasOwnProperty(i)},Object.defineProperty(e.prototype,"count",{get:function(){return this.countProperty},enumerable:!1,configurable:!0}),e.prototype.add=function(i,n){this.items.hasOwnProperty(i)||this.countProperty++,this.items[i]=n},e.prototype.remove=function(i){var n=this.items[i];return delete this.items[i],this.countProperty--,n},e.prototype.item=function(i){return this.items[i]},Object.defineProperty(e.prototype,"keys",{get:function(){return Object.keys(this.items)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"values",{get:function(){var i=this;return this.keys.map(function(n){return i.items[n]})},enumerable:!1,configurable:!0}),e.prototype.clear=function(){this.items={},this.countProperty=0},e})();return mN.Dictionary=t,mN}var bN={},zhe;function QNe(){if(zhe)return bN;zhe=1,Object.defineProperty(bN,"__esModule",{value:!0}),bN.localStorageApi=void 0;var t=void 0;function e(){if(t!==void 0)return t;try{var s=window.localStorage,l="__storage_test__";return s.setItem(l,l),s.removeItem(l),t=!0,!0}catch{return t=!1,!1}}function i(){if(e())return localStorage.getItem("LICENSE_DEBUG")==="1"}function n(s){e()&&localStorage.setItem("LICENSE_DEBUG",s?"1":"0")}function r(){e()&&localStorage.removeItem("LICENSE_DEBUG")}function o(){if(e()){var s=localStorage.getItem("LICENSE_WIZARD_PORT"),l=Number(s);if(!isNaN(l))return l}}function a(){if(e()){var s=localStorage.getItem("LICENSE_WIZARD_MAXPORT"),l=Number(s);if(!isNaN(l))return l}}return bN.localStorageApi={storageAvailable:e,getIsLicenseDebug:i,setIsLicenseDebug:n,clearLicensingDebug:r,getLicenseWizardMaxPort:a,getLicenseWizardPort:o},bN}var Eq={},SN={},wq={},$he;function _re(){return $he||($he=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.LicenseCheckStatus=t.LicenseType=void 0,(function(e){e[e.NoLicense=0]="NoLicense",e[e.Trial=1]="Trial",e[e.Full=2]="Full",e[e.Full_Expired=3]="Full_Expired",e[e.Trial_Expired=4]="Trial_Expired",e[e.Subscription_Expired=5]="Subscription_Expired",e[e.Invalid_Developer=6]="Invalid_Developer",e[e.Requres_Validation=7]="Requres_Validation",e[e.Invalid=8]="Invalid",e[e.Community=9]="Community"})(t.LicenseType||(t.LicenseType={})),(function(e){e[e.NoLicense=0]="NoLicense",e[e.FetchingFromServer=1]="FetchingFromServer",e[e.StartLookingForLicenseWizard=2]="StartLookingForLicenseWizard",e[e.LookingForLicenseWizard=3]="LookingForLicenseWizard",e[e.ValidatingDeveloperLicense=4]="ValidatingDeveloperLicense",e[e.NoLicenseInWizard=5]="NoLicenseInWizard",e[e.FailedToFindLicenseWizard=6]="FailedToFindLicenseWizard",e[e.FailedToValidateDeveloperLicense=7]="FailedToValidateDeveloperLicense",e[e.DevKeyInRuntimeKey=8]="DevKeyInRuntimeKey",e[e.LicenseOK=9]="LicenseOK"})(t.LicenseCheckStatus||(t.LicenseCheckStatus={}))})(wq)),wq}var Whe;function lW(){if(Whe)return SN;Whe=1,Object.defineProperty(SN,"__esModule",{value:!0}),SN.licenseManager2dState=void 0;var t=_re(),e=(function(){function i(){this.isDev=!1,this.orderId="",this.productCode="",this.devCount=1,this.licenseType=t.LicenseType.NoLicense,this.licenseType3D=t.LicenseType.NoLicense,this.telemetryEnabled=!1,this.error=""}return i})();return SN.licenseManager2dState=new e,SN}var k0={},Ghe;function eFe(){if(Ghe)return k0;Ghe=1,Object.defineProperty(k0,"__esModule",{value:!0}),k0.deleteCookie=k0.getCookie=k0.setCookie=void 0;function t(n,r,o){var a=new Date,s=r;a.setTime(a.getTime()+o*24*60*60*1e3),typeof document<"u"&&(document.cookie=n+"="+s+"; expires="+a.toUTCString()+"; path=/")}k0.setCookie=t;function e(n){if(typeof document>"u")return null;var r="; "+document.cookie,o=r.split("; "+n+"=");return o.length===2?o.pop().split(";").shift():""}k0.getCookie=e;function i(n){if(!(typeof document>"u")){var r=new Date;r.setTime(r.getTime()+-1440*60*1e3),document.cookie=n+"=; expires="+r.toUTCString()+"; path=/"}}return k0.deleteCookie=i,k0}var Yhe;function t5(){return Yhe||(Yhe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.sendTelemetry=t.shouldSendTelemetry=t.getUserCookie=void 0;var e=lW(),i=eFe(),n=vm(),r=Uo(),o=hl(),a=_re(),s=3600*1e3,l=!1,u=function(h,p,g){var v="".concat(h,",").concat(p,",").concat(g);return(0,i.setCookie)("scUser",v,365)},c=function(){var h=(0,i.getCookie)("scUser");if(h){var p=h.split(",");if(p.length===3)return{userId:p[0],sessionId:p[1],sessionStart:Number.parseInt(p[2],10)}}return{userId:(0,o.base64Id)(),sessionId:(0,o.base64Id)(),sessionStart:0}};t.getUserCookie=c;var d=function(){return!(r.IS_TEST_ENV||l||e.licenseManager2dState.licenseType!==a.LicenseType.Community&&!e.licenseManager2dState.isDev||!e.licenseManager2dState.telemetryEnabled||window&&!window.navigator.onLine)};t.shouldSendTelemetry=d;var f=function(){if((0,t.shouldSendTelemetry)()){var h=(0,t.getUserCookie)(),p=new Date().toISOString();if(!(Date.now()-h.sessionStart<s)){h.sessionId=(0,o.base64Id)(),h.sessionStart=Date.now(),u(h.userId,h.sessionId,h.sessionStart);var g={time:p,iKey:"210b4d64-8147-471e-b6cb-244a2c939455",name:"Microsoft.ApplicationInsights.210b4d648147471eb6cb244a2c939455.Event",tags:{"ai.user.id":h.userId,"ai.session.id":h.sessionId,"ai.device.id":"browser","ai.device.type":"Browser"},data:{baseType:"EventData",baseData:{ver:2,name:"LicenseSet",properties:{platform:"JS",licenseType:e.licenseManager2dState.licenseType,orderId:e.licenseManager2dState.orderId,productCode:e.licenseManager2dState.productCode,isDev:e.licenseManager2dState.isDev,devCount:e.licenseManager2dState.devCount,sciChartVersion:n.libraryVersion},measurements:{}}}};e.licenseManager2dState.licenseType===a.LicenseType.Community&&(g.data.baseData.properties.url=window.location.href);var v="https://dc.services.visualstudio.com/v2/track",y=JSON.stringify([g]);fetch(v,{method:"POST",headers:{"Content-Type":"application/json"},body:y}).catch(function(m){}),l=!0}}};t.sendTelemetry=f})(Eq)),Eq}var Aq={},qhe;function tFe(){return qhe||(qhe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EColor=void 0,(function(e){e.Aqua="#00ffff",e.BackgroundColor="#1c1c1e",e.Blue="#368BC1",e.DarkGreen="#03925e",e.DarkRed="#be0000",e.DarkGrey="#7e8486",e.DefaultGridBandsColor="#202123",e.DefaultTextColor="#c8c7c3",e.DodgerBlue="#1E90FF",e.Green="#228B22",e.LightGrey="#eeeeee",e.LightSteelBlue="#b0c4de",e.LimeGreen="#32CD32",e.Orange="#ff6600",e.OrangeRed="#FF4500",e.Purple="#B200FF",e.Red="#ff0000",e.White="#ffffff",e.Yellow="#FFFF00"})(t.EColor||(t.EColor={}))})(Aq)),Aq}var Xhe;function AI(){return Xhe||(Xhe=1,(function(t){var e=AT&&AT.__awaiter||function(rt,qe,vt,kt){function Xe(_t){return _t instanceof vt?_t:new vt(function(Ht){Ht(_t)})}return new(vt||(vt=Promise))(function(_t,Ht){function Pt(Bt){try{zt(kt.next(Bt))}catch(Mr){Ht(Mr)}}function Jt(Bt){try{zt(kt.throw(Bt))}catch(Mr){Ht(Mr)}}function zt(Bt){Bt.done?_t(Bt.value):Xe(Bt.value).then(Pt,Jt)}zt((kt=kt.apply(rt,qe||[])).next())})},i=AT&&AT.__generator||function(rt,qe){var vt={label:0,sent:function(){if(_t[0]&1)throw _t[1];return _t[1]},trys:[],ops:[]},kt,Xe,_t,Ht;return Ht={next:Pt(0),throw:Pt(1),return:Pt(2)},typeof Symbol=="function"&&(Ht[Symbol.iterator]=function(){return this}),Ht;function Pt(zt){return function(Bt){return Jt([zt,Bt])}}function Jt(zt){if(kt)throw new TypeError("Generator is already executing.");for(;vt;)try{if(kt=1,Xe&&(_t=zt[0]&2?Xe.return:zt[0]?Xe.throw||((_t=Xe.return)&&_t.call(Xe),0):Xe.next)&&!(_t=_t.call(Xe,zt[1])).done)return _t;switch(Xe=0,_t&&(zt=[zt[0]&2,_t.value]),zt[0]){case 0:case 1:_t=zt;break;case 4:return vt.label++,{value:zt[1],done:!1};case 5:vt.label++,Xe=zt[1],zt=[0];continue;case 7:zt=vt.ops.pop(),vt.trys.pop();continue;default:if(_t=vt.trys,!(_t=_t.length>0&&_t[_t.length-1])&&(zt[0]===6||zt[0]===2)){vt=0;continue}if(zt[0]===3&&(!_t||zt[1]>_t[0]&&zt[1]<_t[3])){vt.label=zt[1];break}if(zt[0]===6&&vt.label<_t[1]){vt.label=_t[1],_t=zt;break}if(_t&&vt.label<_t[2]){vt.label=_t[2],vt.ops.push(zt);break}_t[2]&&vt.ops.pop(),vt.trys.pop();continue}zt=qe.call(rt,vt)}catch(Bt){zt=[6,Bt],Xe=0}finally{kt=_t=0}if(zt[0]&5)throw zt[1];return{value:zt[0]?zt[1]:void 0,done:!0}}};Object.defineProperty(t,"__esModule",{value:!0}),t.licenseManager=t.getLicenseInfo=t.applyLicense=t.getLicenseCookie=t.setUseLicenseWizard=t.setRuntimeLicenseKey=t.setLicenseCallback=t.setIsDebugLicensing=t.setDependencies=void 0;var n=Uo(),r=vm(),o=Sre(),a=$v(),s=QNe(),l=t5(),u=tFe(),c=_re(),d=vs(),f=eFe(),h=lW(),p=24278,g=24279,v=s.localStorageApi.getLicenseWizardPort();v&&(p=v,g=p+1);var y=function(rt){return e(void 0,void 0,void 0,function(){var kt,Xe,qe,vt,kt,Xe;return i(this,function(_t){switch(_t.label){case 0:return _t.trys.push([0,2,,9]),kt="http://localhost:"+p.toString()+rt,[4,fetch(kt)];case 1:return Xe=_t.sent(),[2,Xe];case 2:if(qe=_t.sent(),C("Could not connect to license wizard on port "+p.toString()),!(typeof localStorage<"u"))return[3,8];if(vt=s.localStorageApi.getLicenseWizardMaxPort(),!vt)return[3,8];_t.label=3;case 3:if(!(g<=vt))return[3,8];_t.label=4;case 4:return _t.trys.push([4,6,,7]),kt="http://localhost:"+g.toString()+rt,[4,fetch(kt)];case 5:return Xe=_t.sent(),p=g,[2,Xe];case 6:return _t.sent(),C("Could not connect to license wizard on port "+g.toString()),g=g+1,[3,7];case 7:return[3,3];case 8:throw qe;case 9:return[2]}})})},m={fetchFromWizard:function(rt){return y(rt)},setCookie:function(rt,qe,vt){return(0,f.setCookie)(rt,qe,vt)},getCookie:function(rt){return(0,f.getCookie)(rt)},fetchForChallenge:function(rt){return fetch(rt)},debug:function(rt){return console.log(rt)}},b=function(rt){return m=rt};t.setDependencies=b;var S=null,_=function(rt,qe){qe===void 0&&(qe=!1),S=rt,(qe||!rt)&&s.localStorageApi.setIsLicenseDebug(rt)};t.setIsDebugLicensing=_;var C=function(rt){S===null&&(S=s.localStorageApi.getIsLicenseDebug()),(n.IS_TEST_ENV||S)&&m.debug(rt)};C("SciChart version "+r.libraryVersion);var P,x=function(rt){P=rt};t.setLicenseCallback=x;var E="",A=function(){return E},R=function(rt){var qe=E;E=rt,E!==qe&&E!==""&&Y().forEach(function(vt){return(0,t.applyLicense)(vt,"setRuntimeLicenseKey")})};t.setRuntimeLicenseKey=R;var M=!0,D=function(rt){M=rt};t.setUseLicenseWizard=D;var F=n.IS_TEST_ENV?.1:5,I=n.IS_TEST_ENV?12:10,V="api/license",z=function(rt){V=rt},G=0,H,U,k=function(rt){return e(void 0,void 0,void 0,function(){var qe,vt,kt,Xe,_t,Ht;return i(this,function(Pt){switch(Pt.label){case 0:return Pt.trys.push([0,5,,6]),Ee!==c.LicenseCheckStatus.StartLookingForLicenseWizard&&Ee!==c.LicenseCheckStatus.LookingForLicenseWizard&&Ee!==c.LicenseCheckStatus.NoLicenseInWizard?[2]:(C("Trying to get license from local license wizard"),qe=void 0,[4,m.fetchFromWizard("/license")]);case 1:return qe=Pt.sent(),qe.ok?[4,qe.text()]:[3,3];case 2:return vt=Pt.sent(),kt=ke(vt,rt),Xe=kt.requiresValidation,_t=kt.trialExpired,Xe?(C("Got a developer license from local license wizard.  Validating..."),Ee=c.LicenseCheckStatus.ValidatingDeveloperLicense,ge(rt)):_t?(Ee=c.LicenseCheckStatus.NoLicenseInWizard,C("No valid license available in licensing wizard. Trying again in ".concat(F," seconds")),H=setTimeout(function(){return k(rt)},F*1e3)):(C("Got a valid license from local license wizard."),Ee=c.LicenseCheckStatus.LicenseOK),[3,4];case 3:Ee=c.LicenseCheckStatus.NoLicenseInWizard,C("No license available in licensing wizard. Trying again in ".concat(F," seconds")),H=setTimeout(function(){return k(rt)},F*1e3),Pt.label=4;case 4:return[3,6];case 5:return Pt.sent(),Ee=c.LicenseCheckStatus.LookingForLicenseWizard,G+=1,G<I?(C("Could not find licensing wizard. Trying again in ".concat(F," seconds")),H=setTimeout(function(){return k(rt)},F*1e3)):(console.log("Failed to connect to licensing wizard. Refresh page to retry."),G=0,Ee=c.LicenseCheckStatus.FailedToFindLicenseWizard),[3,6];case 6:return Ht=(0,t.getLicenseInfo)(rt),Ht.hasChanged&&te().forEach(function(Jt){wt(Ht,Jt,Jt.surfaceType!==d.ESurfaceType.SciChart3DSurfaceType)}),[2]}})})},X=function(rt,qe,vt,kt){var Xe="".concat(rt,",").concat(qe,",").concat(vt,",").concat(kt);return m.setCookie("scLicense",Xe,365)},W=function(){var rt;rt=m.getCookie("scLicense");var qe=rt.split(",");return qe.length===4?{key:qe[0],token:qe[1],expiry:new Date(Number.parseInt(qe[2],10)*1e3),lastValidated:new Date(Number.parseInt(qe[3],10)*1e3)}:{key:qe[0],token:null,expiry:null,lastValidated:null}};t.getLicenseCookie=W;var Y=function(){var rt=[];return a.sciChartDestinations.length>0&&rt.push(a.sciChartDestinations[0].sciChartSurface.getLicenseContext()),a.sciChart3DDestinations.length>0&&rt.push(a.sciChart3DDestinations[0].sciChartSurface.getLicenseContext()),a.sciChartSingleDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface.getLicenseContext())}),a.sciChart3DSingleDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface.getLicenseContext())}),rt},te=function(){var rt=[];return a.sciChartDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface)}),a.sciChart3DDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface)}),a.sciChartSingleDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface)}),a.sciChart3DSingleDestinations.forEach(function(qe){return rt.push(qe.sciChartSurface)}),rt},oe=function(rt,qe){var vt=-1;return vt=qe.SCRTCredentials.ApplyLicenseResponse(rt),Y().forEach(function(kt){return kt.SCRTCredentials.ApplyLicenseResponse(rt)}),vt},de=0,ge=function(rt){return e(void 0,void 0,void 0,function(){var qe,vt,kt,Xe,_t,Ht,Pt,Pt,Jt,zt,Bt,Mr,Be,We,dt,Tt,nr;return i(this,function(Ar){switch(Ar.label){case 0:if(qe=Y(),rt===void 0)if(qe.length>0)rt=qe[0];else return[2];vt=h.licenseManager2dState.isDev?"license wizard":"server",Ar.label=1;case 1:return Ar.trys.push([1,11,,12]),Ee!==c.LicenseCheckStatus.ValidatingDeveloperLicense?[2]:(C("Attempting to validate license with ".concat(vt)),kt=rt.SCRTCredentials.GetLicenseChallenge(),Xe=rt.SCRTCredentials.GetOrderId(),_t=void 0,Ht="orderid=".concat(Xe,"&challenge=").concat(kt),h.licenseManager2dState.isDev?(Pt="/validate?".concat(Ht),[4,m.fetchFromWizard(Pt)]):[3,3]);case 2:return _t=Ar.sent(),[3,7];case 3:return typeof P<"u"?[4,P(Ht)]:[3,5];case 4:return _t=Ar.sent(),[3,7];case 5:return Pt="/"+V+(V.indexOf("?")>0?"&":"?")+Ht,[4,m.fetchForChallenge(Pt)];case 6:_t=Ar.sent(),Ar.label=7;case 7:return _t.ok?[4,_t.text()]:[3,9];case 8:return Jt=Ar.sent(),Jt.startsWith("Error")?(C("Server rejected the license challenge: "+Jt),Ee=c.LicenseCheckStatus.FailedToValidateDeveloperLicense):(zt=oe(Jt,rt),zt>0?(Bt=(0,t.getLicenseCookie)().key,Bt||(Bt=A()),Mr=Math.floor(new Date().getTime()/1e3),X(Bt,Jt,zt,Mr),C("License validated"),Ee=c.LicenseCheckStatus.LicenseOK,Be=zt-Mr,de=0,U=setTimeout(function(){Ee=c.LicenseCheckStatus.ValidatingDeveloperLicense,h.licenseManager2dState.checkStatus=c.LicenseCheckStatus.ValidatingDeveloperLicense,ge(void 0)},Math.floor(Be*.95*1e3))):(C("license challenge response was invalid: ".concat(Jt," ").concat(zt)),Ee=c.LicenseCheckStatus.FailedToValidateDeveloperLicense)),[3,10];case 9:if(h.licenseManager2dState.isDev)console.warn("Error during license validation: "+_t.statusText),Ee=c.LicenseCheckStatus.FailedToValidateDeveloperLicense;else throw new Error(_t.statusText);Ar.label=10;case 10:return[3,12];case 11:return Ar.sent(),h.licenseManager2dState.isDev?(de+=1,de<I?(C("Could not find ".concat(vt,"/").concat(V,". Trying again in ").concat(F," seconds")),U=setTimeout(function(){return ge(rt)},F*1e3)):(dt=(0,t.getLicenseCookie)().expiry,Tt=h.licenseManager2dState.isDev?"Please run the license wizard, ensure your license is activated, then refresh page to retry.":"Please check that the endpoint is configured correctly.",console.error("Failed to connect to ".concat(vt,"/").concat(V,".  ").concat(Tt)),dt&&console.warn("License must be revalidated before ".concat(dt.toLocaleString(),".")),de=0,new Date>dt&&(Ee=c.LicenseCheckStatus.FailedToFindLicenseWizard)),[3,12]):(console.warn("Server license validation failed.  Looking for local developer license"),E="",Ee=c.LicenseCheckStatus.NoLicense,rt.SCRTCredentials.ResetRuntimeLicense(),qe.forEach(function(Qr){return Qr.SCRTCredentials.ResetRuntimeLicense()}),Re=!1,h.licenseManager2dState.isDev=!0,Ee=c.LicenseCheckStatus.StartLookingForLicenseWizard,We=(0,t.getLicenseInfo)(rt),We.hasChanged&&te().forEach(function(Qr){wt(We,Qr,Qr.surfaceType!==d.ESurfaceType.SciChart3DSurfaceType)}),k(rt),[2]);case 12:return nr=(0,t.getLicenseInfo)(rt),nr.hasChanged&&te().forEach(function(Qr){wt(nr,Qr,Qr.surfaceType!==d.ESurfaceType.SciChart3DSurfaceType)}),[2]}})})},Ee=c.LicenseCheckStatus.NoLicense,Re=!1,Ae=!1,Pe=function(rt,qe){var vt,kt,Xe,_t;C("applyLicense from "+qe);var Ht="",Pt=rt.SCRTCredentials.GetLicenseType();C("Initial license status is "+c.LicenseType[it(Pt,rt)]);var Jt=A();if((Ee===c.LicenseCheckStatus.NoLicense||Ee===c.LicenseCheckStatus.LicenseOK||Ee===c.LicenseCheckStatus.StartLookingForLicenseWizard||Ee===c.LicenseCheckStatus.LookingForLicenseWizard)&&Jt){C("Runtime license found");var zt=Jt.indexOf(";");if(zt>0){var Bt=Math.floor(new Date().getTime()/1e3),Mr=Jt.substring(zt+1);X(Jt.substr(0,zt),Mr,Bt+60,Bt)}else{rt.SCRTCredentials.SetRuntimeLicenseKeyW(Jt),Pt=rt.SCRTCredentials.GetLicenseType();var Be=it(Pt,rt);if(C("Runtime license status is "+c.LicenseType[Be]),Pt===rt.SCRTLicenseType.LICENSE_TYPE_FULL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_TRIAL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY||Pt===rt.SCRTLicenseType.LICENSE_TYPE_REQUIRES_VALIDATION)Re=!0,Ht=Jt;else{var We=rt.SCRTCredentials.GetLicenseErrors();window&&(!((vt=window.location)===null||vt===void 0)&&vt.hostname)&&!(!((Xe=(kt=window.location)===null||kt===void 0?void 0:kt.hostname)===null||Xe===void 0)&&Xe.includes("localhost"))||!We.startsWith("License is not valid for this domain")?S?C("Runtime license is invalid: "+We):console.warn("Runtime license is invalid.  Call setIsDebugLicensing(true) for details."):C("Runtime license is invalid: "+We),Ht=""}}}var dt=(0,t.getLicenseCookie)();if(Ht===""&&dt&&dt.key!==""?(C("Found license in cookie."),Ht=dt.key,rt.SCRTCredentials.SetRuntimeLicenseKeyW(Ht),Pt=rt.SCRTCredentials.GetLicenseType(),Pt===rt.SCRTLicenseType.LICENSE_TYPE_FULL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_TRIAL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_REQUIRES_VALIDATION||(C("License cookie is invalid. "+rt.SCRTCredentials.GetLicenseErrors()),(0,f.deleteCookie)("scLicense"),Ht="",Pt=rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY)):Ee===c.LicenseCheckStatus.FetchingFromServer&&(Ee=c.LicenseCheckStatus.NoLicense),Ht!=="")if(Pt===rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY&&(rt.SCRTCredentials.SetRuntimeLicenseKeyW(Ht),Pt=rt.SCRTCredentials.GetLicenseType()),h.licenseManager2dState.isDev=rt.SCRTCredentials.GetAllowDebugging(),Pt===rt.SCRTLicenseType.LICENSE_TYPE_FULL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_TRIAL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY){if(Ee=c.LicenseCheckStatus.LicenseOK,C("license ok"),Pt===rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY&&Re&&!Ae){console.log("Using SciChart Community Edition. To use a license from the License Wizard, remove the call to UseCommunityLicense");var Tt=rt.SCRTCredentials.GetLicenseDaysRemaining();console.log("The community license is valid for 6 months from the date the version in use was released.  This version ".concat(r.libraryVersion," has ").concat(Tt," day").concat(Tt===1?"":"s"," remaining")),Ae=!0}}else if(rt.SCRTCredentials.RequiresValidation())if(C("license requires validation"),Re&&h.licenseManager2dState.isDev)rt.SCRTCredentials.ResetRuntimeLicense(),(0,f.deleteCookie)("scLicense"),Ee=c.LicenseCheckStatus.DevKeyInRuntimeKey;else if(dt.expiry>new Date&&dt.key===Ht){C("current token in cookie");var nr=oe(dt.token,rt);Pt=rt.SCRTCredentials.GetLicenseType(),(Pt===rt.SCRTLicenseType.LICENSE_TYPE_FULL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_TRIAL)&&(Ee=c.LicenseCheckStatus.LicenseOK);var Bt=Math.floor(new Date().getTime()/1e3);nr*1e3>dt.expiry.getTime()&&X(Ht,dt.token,nr,Bt);var Ar=3600*24,Qr=(new Date().getTime()-dt.lastValidated.getTime())/1e3;C("License expires in ".concat(nr-Bt," seconds.  Last validated ").concat(Qr," seconds ago")),Qr>Ar&&Ee!==c.LicenseCheckStatus.ValidatingDeveloperLicense?(Ee=c.LicenseCheckStatus.ValidatingDeveloperLicense,h.licenseManager2dState.checkStatus=c.LicenseCheckStatus.ValidatingDeveloperLicense,ge(rt)):U===void 0&&(U=setTimeout(function(){Ee=c.LicenseCheckStatus.ValidatingDeveloperLicense,h.licenseManager2dState.checkStatus=c.LicenseCheckStatus.ValidatingDeveloperLicense,ge(void 0)},Math.floor((nr-Bt)*.95*1e3)))}else Ee===c.LicenseCheckStatus.NoLicense&&(Ee=c.LicenseCheckStatus.ValidatingDeveloperLicense,ge(rt));else C("license is invalid: "+rt.SCRTCredentials.GetLicenseErrors());if(C("checkstatus: "+c.LicenseCheckStatus[Ee]),Ee===c.LicenseCheckStatus.NoLicense){if(Pt===rt.SCRTLicenseType.LICENSE_TYPE_COMMUNITY&&!Ae){console.log("Defaulting to SciChart Community Edition. Usage constitutes acceptance of our EULA and terms at https://www.scichart.com/community-licensing. See https://store.scichart.com for commercial licensing options.");var Tt=rt.SCRTCredentials.GetLicenseDaysRemaining();console.log("The community license is valid for 6 months from the date the version in use was released.  This version ".concat(r.libraryVersion," has ").concat(Tt," day").concat(Tt===1?"":"s"," remaining")),!n.IS_TEST_ENV&&(!((_t=document==null?void 0:document.location)===null||_t===void 0)&&_t.hostname.startsWith("localhost"))&&M&&console.log("SciChart is looking for a paid developer activation from the scichart licensing wizard... To disable this call SciChartSurface.UseCommunityLicense()"),Ae=!0}H===void 0&&M&&(Ee=c.LicenseCheckStatus.StartLookingForLicenseWizard,h.licenseManager2dState.isDev=!0,k(rt))}};t.applyLicense=Pe;var we,Te=function(){console.error("Modal not initialized")},ke=function(rt,qe){var vt=!1,kt;return we&&(we.style.display="none"),Re=!1,X(rt,null,null,null),qe.SCRTCredentials.SetRuntimeLicenseKeyW(rt),vt=qe.SCRTCredentials.RequiresValidation(),kt=qe.SCRTCredentials.GetLicenseType()===qe.SCRTLicenseType.LICENSE_TYPE_TRIAL_EXPIRED,Y().forEach(function(Xe){return Xe.SCRTCredentials.SetRuntimeLicenseKeyW(rt)}),{requiresValidation:vt,trialExpired:kt}},$e=new o.Dictionary,Ne=function(rt,qe){if(!$e.containsKey(rt)){var vt=document.styleSheets;if(vt.length===0){var kt=document.createElement("style");kt.appendChild(document.createTextNode("")),document.head.appendChild(kt)}var Xe=vt[vt.length-1],_t=Xe.insertRule(qe,Xe.cssRules.length);$e.add(rt,_t)}},ve=function(){Ne("licenseModalClose",`.licenseModalClose {
        color: #aaa;
        float: right;
        font-size: 28px;
        font-weight: bold;
      }`),Ne("licenseModalClose:hover",`.licenseModalClose:hover {
        color: black;
        text-decoration: none;
        cursor: pointer;
      }`),Ne("licenseModalClose:focus",`.licenseModalClose:focus {
        color: black;
        text-decoration: none;
        cursor: pointer;
      }`)},pe=function(rt,qe){we=document.createElement("div"),we.id="scichartLicenseModal",we.style.display="none",we.style.position="fixed",we.style.zIndex="100",we.style.left="0",we.style.top="0",we.style.width="100%",we.style.height="100%",we.style.overflow="auto",we.style.backgroundColor="rgb(0,0,0)",we.style.backgroundColor="rgba(0,0,0,0.4)";var vt=document.createElement("div");vt.style.backgroundColor="#fefefe",vt.style.position="absolute",vt.style.left="50%",vt.style.top="50%",vt.style.transform="translate(-50%, -50%)",vt.style.borderRadius="4px",vt.style.padding="20px",vt.style.maxWidth="460px",we.appendChild(vt);var kt=document.createElement("div");kt.style.display="block",vt.appendChild(kt);var Xe=document.createElement("div");Xe.style.display="none",vt.appendChild(Xe),Te=function(){we.style.display="block",kt.style.display="block",Xe.style.display="none"};var _t=document.createElement("div");_t.style.display="flex",_t.style.padding="8px 16px",_t.style.backgroundColor="#5cb85c",_t.style.color="white",kt.appendChild(_t);var Ht=document.createElement("div");Ht.style.flexGrow="1",Ht.innerHTML=rt,_t.appendChild(Ht),ve();var Pt=document.createElement("span");Pt.innerHTML="&times;",Pt.className="licenseModalClose",_t.appendChild(Pt);var Jt=document.createElement("div");Jt.innerHTML=`If you contact support with a licensing issue, we will ask you to send us the license debug log.
    To toggle License debug mode use the button below and refresh the page, then check the console output.  
    When copying the log, make sure to start from the beginning, indicated by the reported version number`;var zt=document.createElement("button");zt.style.margin="10px";var Bt=function(){zt.textContent=S?"Disable licensing debug mode":"Enable licensing debug mode"};Bt(),zt.onclick=function(){(0,t.setIsDebugLicensing)(!S,!0),Bt()},kt.appendChild(Jt),kt.appendChild(zt);var Mr=document.createElement("div");Mr.innerHTML=qe,Mr.style.padding="8px 16px",Mr.style.backgroundColor="#5cb85c",Mr.style.color="white",kt.appendChild(Mr),window.onclick=function(We){We.target===we&&(we.style.display="none")};var Be=document.querySelector("[id='".concat(we.id,"']"));return Be==null?document.body.appendChild(we):document.body.replaceChild(we,Be),Pt.onclick=function(){we.style.display="none"},we},fe="licenseMessage",me="licenseMessageChild",Ce=null,Ue=null,Qe=function(rt,qe){if(rt){var vt=qe.cloneNode(!0),kt=Array.from(rt.children).find(function(Xe){return Xe.className===fe});kt?rt.replaceChild(vt,kt):rt.appendChild(vt),M&&(vt.onclick=Te)}},it=function(rt,qe){var vt=c.LicenseType.NoLicense;switch(rt){case qe.SCRTLicenseType.LICENSE_TYPE_NO_LICENSE:{vt=c.LicenseType.NoLicense;break}case qe.SCRTLicenseType.LICENSE_TYPE_TRIAL:{vt=c.LicenseType.Trial;break}case qe.SCRTLicenseType.LICENSE_TYPE_COMMUNITY:{vt=c.LicenseType.Community;break}case qe.SCRTLicenseType.LICENSE_TYPE_FULL:{vt=c.LicenseType.Full;break}case qe.SCRTLicenseType.LICENSE_TYPE_FULL_EXPIRED:{vt=c.LicenseType.Full_Expired;break}case qe.SCRTLicenseType.LICENSE_TYPE_TRIAL_EXPIRED:{vt=c.LicenseType.Trial_Expired;break}case qe.SCRTLicenseType.LICENSE_TYPE_SUBSCRIPTION_EXPIRED:{vt=c.LicenseType.Subscription_Expired;break}case qe.SCRTLicenseType.LICENSE_TYPE_INVALID_DEVELOPER_LICENSE:{vt=c.LicenseType.Invalid_Developer;break}case qe.SCRTLicenseType.LICENSE_TYPE_REQUIRES_VALIDATION:{vt=c.LicenseType.Requres_Validation;break}case qe.SCRTLicenseType.LICENSE_TYPE_INVALID_LICENSE:{vt=c.LicenseType.Invalid;break}}return vt},xt=function(rt){var qe=rt.SCRTCredentials.GetLicenseType(),vt=it(qe,rt),kt=rt.SCRTCredentials.GetLicenseDaysRemaining(),Xe=!1;if(Ee!==h.licenseManager2dState.checkStatus||vt!==h.licenseManager2dState.licenseType){Xe=!0,C("License status updated ".concat(c.LicenseCheckStatus[Ee]," ").concat(c.LicenseType[vt])),vt===c.LicenseType.Community?h.licenseManager2dState.orderId="Community":h.licenseManager2dState.orderId=rt.SCRTCredentials.GetEncryptedOrderId(),h.licenseManager2dState.productCode=rt.SCRTCredentials.GetProductCode(),h.licenseManager2dState.licenseType=vt,h.licenseManager2dState.checkStatus=Ee,h.licenseManager2dState.devCount=rt.SCRTCredentials.GetDeveloperCount();var _t=it(rt.SCRTCredentials.HasFeature("JS-3D"),rt);vt!==c.LicenseType.Full&&vt!==c.LicenseType.Trial&&(_t=vt),h.licenseManager2dState.licenseType3D=_t;var Ht=rt.SCRTCredentials.GetLicenseErrors();h.licenseManager2dState.error=Ht;var Pt=rt.SCRTCredentials.HasFeature("TE");h.licenseManager2dState.telemetryEnabled=Pt===rt.SCRTLicenseType.LICENSE_TYPE_FULL||Pt===rt.SCRTLicenseType.LICENSE_TYPE_TRIAL,S&&C(rt.SCRTCredentials.Dump())}return{hasChanged:Xe,licenseType:vt,licenseType3D:h.licenseManager2dState.licenseType3D,daysRemaining:kt,error:h.licenseManager2dState.error}};t.getLicenseInfo=xt;var wt=function(rt,qe,vt,kt){var Xe;kt===void 0&&(kt=!1),Ce==null&&(Ce=document.createElement("div"),Ce.className=fe,Ue=document.createElement("div"),Ue.className=me,Ue.innerHTML="",Ce.appendChild(Ue));var _t="",Ht="",Pt="",Jt=rt.hasChanged,zt=rt.licenseType,Bt=rt.licenseType3D,Mr=rt.daysRemaining,Be=rt.error;if(Jt||kt||Ee==c.LicenseCheckStatus.LicenseOK&&zt!==Bt){C("updateLicenseDisplay for ".concat((Xe=qe.domChartRoot)===null||Xe===void 0?void 0:Xe.id));var We=vt?zt:Bt;if(qe.invalidateElement(),We===c.LicenseType.Community&&Ee===c.LicenseCheckStatus.StartLookingForLicenseWizard)return;var dt=!vt&&zt!==Bt,Tt='<a href="https://www.scichart.com/licensing-scichart-js"  target="_blank" style="color: white">www.scichart.com/licensing-scichart-js</a>',nr='<a href="https://www.scichart.com/contact-us/"  target="_blank" style="color: orange">contact support</a>';We===c.LicenseType.NoLicense?(_t="You need to have a license to use SciChart.  ",Pt="Instructions can be seen at ".concat(Tt)):We===c.LicenseType.Invalid?(Be.startsWith("License is not valid for this domain")?_t=`Sorry! The runtime license key is not valid for this domain</br>
                Please `.concat(nr,` with your OrderID if you believe this to be incorrect. <u>Click for more information</u></br>
                For local development, make sure the Licensing Wizard is running and activated.</br>
                To use Community Edition, remove the call to setRuntimeLicenseKey`):Be.startsWith("This version of SciChart can no longer be trialed")?_t="Sorry! This version of SciChart is too old to be trialed.  Please update to the latest version":Be.startsWith("This version of SciChart can no longer be used for the community edition")?_t="Sorry! This version of SciChart is too old to be used for the community edition.  Please update to the latest version":dt?_t="Sorry! Your license is for ".concat(h.licenseManager2dState.productCode," which does not support 3D Charts."):_t="Sorry! Your license key appears to be invalid</br>Please ".concat(nr," with your OrderID if you believe this to be incorrect."),Pt="Instructions can be seen at ".concat(Tt)):We===c.LicenseType.Invalid_Developer?(_t="Sorry! You need a developer license to use SciChart on a domain not included in your runtime key.",Pt="Instructions can be seen at ".concat(Tt,`</br>
                    Please `).concat(nr," with your OrderID if you are experiencing issues.")):We===c.LicenseType.Requres_Validation?(h.licenseManager2dState.isDev?_t="Your developer license must be validated by the SciChart Licensing Wizard running locally":_t="This runtime key must be validated by a server side key.",Pt="Instructions can be seen at ".concat(Tt,`</br>
                    Please `).concat(nr," with your OrderID if you are experiencing issues.")):We===c.LicenseType.Subscription_Expired?(_t="Sorry! Your support subscription has expired.<br>",Pt="Please ".concat(nr," if you would like to renew your subscription.")):We===c.LicenseType.Trial_Expired&&Mr<1?(_t="Sorry! Your trial has expired.",Pt="Please ".concat(nr," if you require an extension.")):We===c.LicenseType.Trial_Expired&&Mr>1?(_t="This version is too old to trial.",Pt="Please ".concat(nr," if you require an extension.")):We===c.LicenseType.Trial&&Mr<=7?_t="You have ".concat(Mr," day").concat(Mr===1?"":"s"," remaining of the trial."):We===c.LicenseType.Community&&Mr<=7?_t="You have ".concat(Mr," day").concat(Mr===1?"":"s"," remaining on the community license for this version.  Please update to the latest version of SciChart"):(We===c.LicenseType.Full||(We===c.LicenseType.Trial||We===c.LicenseType.Community)&&Mr>7)&&(Ce.style.display="none",Ue.innerHTML=""),Ee!==c.LicenseCheckStatus.LicenseOK||dt?(Ee===c.LicenseCheckStatus.FetchingFromServer?Ht="<br>Fetching license from server...":Ee===c.LicenseCheckStatus.LookingForLicenseWizard?(We===c.LicenseType.Community&&(0,l.sendTelemetry)(),Ht="<br>Looking for Licensing Wizard..."):Ee===c.LicenseCheckStatus.FailedToFindLicenseWizard?h.licenseManager2dState.isDev?Ht="<br><u>Could not connect to the Licensing Wizard.  Please run it, then reload this page.</u>":Ht="<br><u>Could not connect to the server licensing endpoint</u>":Ee===c.LicenseCheckStatus.ValidatingDeveloperLicense?h.licenseManager2dState.isDev?Ht="<br><u>Trying to validate your license...":Ht="<br><u>Trying to validate your license with the server...</u>.":Ee===c.LicenseCheckStatus.FailedToValidateDeveloperLicense?h.licenseManager2dState.isDev?Ht="<br><u>Failed to validate your developer license with the Licensing Wizard.  If you have changed your activated license, try clearing your cookies for this site.</u>.":Ht="<br><u>Failed to validate the runtime license with the server</u>.":Ee===c.LicenseCheckStatus.NoLicenseInWizard&&We===c.LicenseType.NoLicense?Ht="<br><u>Please use the Licensing wizard to start a trial or activate a serial key.  Click for more information</u>.":Ee===c.LicenseCheckStatus.DevKeyInRuntimeKey?Ht="<br><u>You have set a developer key as a runtime key, which will not work on any other machine.  Click for more information</u>":We===c.LicenseType.Trial_Expired&&Mr>1?Ht="<br><u>Please update to the latest version of SciChart. Click for more information</u>.":Ee===c.LicenseCheckStatus.NoLicenseInWizard&&We===c.LicenseType.Trial_Expired&&(Ht="<br><u>Please activate a serial key in the Licensing Wizard, or contact sales for an extension.  Click for more information</u>."),_t&&(Ce.style.width="100%",Ce.style.height="100%",Ce.style.top="0",Ce.style.left="0",Ce.style.position="absolute",Ce.style.pointerEvents="auto",Ce.style.cursor="pointer",Ce.style.background=u.EColor.BackgroundColor,Ce.style.zIndex="10",Ce.style.display="block",Ue.style.display="block",Ue.style.color="orange",Ue.style.width="80%",Ue.style.position="absolute",Ue.style.left="50%",Ue.style.top="50%",Ue.style.transform="translate(-50%, -50%)",Ue.style.textAlign="center",Ue.style.pointerEvents="auto",M?(Ue.innerHTML=_t+Ht,pe(_t,Pt)):Ue.innerHTML=_t+'<br><a href="https://www.scichart.com/licensing-scichart-js/"  target="_blank" style="color: white">Click here for licensing information</a>',C(_t+`
`+Ht))):(0,l.sendTelemetry)()}Qe(qe.domDivContainer,Ce)},$t=function(){!a.sciChartDestinations.length&&!a.sciChartSingleDestinations.length&&!a.sciChart3DDestinations.length&&(clearTimeout(H),clearTimeout(U),Ue=null,Ce=null)},Mt=function(rt){var qe=(0,t.getLicenseInfo)(rt.getLicenseContext()),vt=rt.surfaceType!==d.ESurfaceType.SciChart3DSurfaceType;wt(qe,rt,vt,!0)};t.licenseManager={clear:$t,setRuntimeLicenseKey:function(rt){return(0,t.setRuntimeLicenseKey)(rt)},setIsDebugLicensing:function(rt){return(0,t.setIsDebugLicensing)(rt)},setLicenseCallback:function(rt){return(0,t.setLicenseCallback)(rt)},setServerLicenseEndpoint:function(rt){return z(rt)},applyLicense:function(rt,qe){return(0,t.applyLicense)(rt,qe)},updateLicenseDisplay:function(rt){return Mt(rt)}}})(AT)),AT}var DT={},I0={},_N={},Khe;function rFe(){if(Khe)return _N;Khe=1,Object.defineProperty(_N,"__esModule",{value:!0}),_N.ModifierArgsBase=void 0;var t=(function(){function e(){this.handled=!1}return e})();return _N.ModifierArgsBase=t,_N}var Zhe;function iFe(){if(Zhe)return I0;Zhe=1;var t=I0&&I0.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=I0&&I0.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(I0,"__esModule",{value:!0}),I0.ModifierMouseArgs=void 0;var i=ci(),n=$i(),r=Zi(),o=rFe(),a=(function(s){t(l,s);function l(u,c){var d=this,f;return d=s.call(this)||this,d.isActiveSubChartEvent=!0,d.mousePoint=u,d.button=c==null?void 0:c.button,d.mouseWheelDelta=(f=c==null?void 0:c.mouseWheelDelta)!==null&&f!==void 0?f:0,d.pointerId=c==null?void 0:c.pointerId,d.pointerType=c==null?void 0:c.pointerType,d.target=c==null?void 0:c.target,d.isMaster=c==null?void 0:c.isMaster,d.modifierGroup=c==null?void 0:c.modifierGroup,d.shiftKey=c==null?void 0:c.shiftKey,d.altKey=c==null?void 0:c.altKey,d.ctrlKey=c==null?void 0:c.ctrlKey,d.nativeEvent=c==null?void 0:c.nativeEvent,d}return l.fromMouseEvent=function(u){i.Guard.notNull(u,"mouseEvent");var c=new n.Point(u.offsetX*r.DpiHelper.PIXEL_RATIO,u.offsetY*r.DpiHelper.PIXEL_RATIO),d={target:u.target,isMaster:!0,shiftKey:u.shiftKey,ctrlKey:u.ctrlKey,altKey:u.altKey,nativeEvent:u};return new l(c,d)},l.fromWheelEvent=function(u){i.Guard.notNull(u,"wheelEvent");var c=new n.Point(u.offsetX*r.DpiHelper.PIXEL_RATIO,u.offsetY*r.DpiHelper.PIXEL_RATIO),d={mouseWheelDelta:u.deltaY,target:u.target,isMaster:!0,shiftKey:u.shiftKey,ctrlKey:u.ctrlKey,altKey:u.altKey,nativeEvent:u};return new l(c,d)},l.fromPointerEvent=function(u){i.Guard.notNull(u,"pointerEvent");var c=new n.Point(u.offsetX*r.DpiHelper.PIXEL_RATIO,u.offsetY*r.DpiHelper.PIXEL_RATIO),d={button:u.button,pointerId:u.pointerId,pointerType:u.pointerType,target:u.target,isMaster:!0,shiftKey:u.shiftKey,ctrlKey:u.ctrlKey,altKey:u.altKey,nativeEvent:u};return new l(c,d)},l.copy=function(u,c,d,f,h){var p=u.mousePoint;if(d&&f){var g=u.mousePoint.x-d.x,v=u.mousePoint.y-d.y,y=f.width/d.width,m=f.height/d.height;p=new n.Point(f.x+g*y,f.y+v*m)}return e(e({},u),{isMaster:!1,masterData:h,handled:!1,modifierGroup:c,mousePoint:p})},l.copyForSubChart=function(u,c,d,f,h){var p=u.mousePoint;if(d&&f){var g=f.width/d.width,v=f.height/d.height;p=new n.Point((u.mousePoint.x-d.x)*g+f.x,(u.mousePoint.y-d.y)*v+f.y)}return e(e({},u),{isMaster:!1,masterData:h,handled:!1,modifierGroup:c,mousePoint:p})},l})(o.ModifierArgsBase);return I0.ModifierMouseArgs=a,I0}var PN={},Jhe;function La(){return Jhe||(Jhe=1,(function(t){var e=PN&&PN.__rest||function(a,s){var l={};for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&s.indexOf(u)<0&&(l[u]=a[u]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,u=Object.getOwnPropertySymbols(a);c<u.length;c++)s.indexOf(u[c])<0&&Object.prototype.propertyIsEnumerable.call(a,u[c])&&(l[u[c]]=a[u[c]]);return l};Object.defineProperty(t,"__esModule",{value:!0}),t.runAfterFramePaint=t.PerformanceDebugHelper=t.EPerformanceDebugLevel=t.EPerformanceMarkType=void 0;var i=hl();(function(a){a.InitializationStart="InitializationStart",a.InitializationEnd="InitializationEnd",a.EngineInitStart="EngineInitStart",a.EngineInitEnd="EngineInitEnd",a.LeadingInvalidate="LeadingInvalidate",a.Invalidate="Invalidate",a.DataUpdateStart="DataUpdateStart",a.DataUpdateEnd="DataUpdateEnd",a.RenderStart="RenderStart",a.RenderEnd="RenderEnd",a.Rendered="Rendered",a.FullStateRendered="FullStateRendered",a.Painted="Painted",a.Resize="Resize",a.DpiChange="DpiChange",a.SetupStart="SetupStart",a.SetupEnd="SetupEnd",a.CanvasInitializationStart="CanvasInitializationStart",a.CanvasInitializationEnd="CanvasInitializationEnd",a.AddSubSurfaceStart="AddSubSurfaceStart",a.AddSubSurfaceEnd="AddSubSurfaceEnd",a.RenderSurfaceDrawStart="RenderSurfaceDrawStart",a.RenderSurfaceDrawEnd="RenderSurfaceDrawEnd",a.DrawingLoopStart="DrawingLoopStart",a.DrawingLoopEnd="DrawingLoopEnd",a.CopyToCanvasStart="CopyToCanvasStart",a.CopyToCanvasEnd="CopyToCanvasEnd",a.GenericAnimationStart="GenericAnimationStart",a.GenericAnimationEnd="GenericAnimationEnd",a.AutoRangeStart="AutoRangeStart",a.AutoRangeEnd="AutoRangeEnd",a.LayoutStart="LayoutStart",a.LayoutEnd="LayoutEnd",a.GetTicksStart="GetTicksStart",a.GetTicksEnd="GetTicksEnd",a.DrawAxisBorderStart="DrawAxisBorderStart",a.DrawAxisBorderEnd="DrawAxisBorderEnd",a.DrawAxisBandsStart="DrawAxisBandsStart",a.DrawAxisBandsEnd="DrawAxisBandsEnd",a.DrawMinorGridLinesStart="DrawMinorGridLinesStart",a.DrawMinorGridLinesEnd="DrawMinorGridLinesEnd",a.DrawMajorGridLinesStart="DrawMajorGridLinesStart",a.DrawMajorGridLinesEnd="DrawMajorGridLinesEnd",a.DrawAxisBackgroundStart="DrawAxisBackgroundStart",a.DrawAxisBackgroundEnd="DrawAxisBackgroundEnd",a.DrawAxisLabelsStart="DrawAxisLabelsStart",a.DrawAxisLabelsEnd="DrawAxisLabelsEnd",a.DrawMinorTicksStart="DrawMinorTicksStart",a.DrawMinorTicksEnd="DrawMinorTicksEnd",a.DrawMajorTicksStart="DrawMajorTicksStart",a.DrawMajorTicksEnd="DrawMajorTicksEnd",a.DrawNativeTextStart="DrawNativeTextStart",a.DrawNativeTextEnd="DrawNativeTextEnd",a.DrawAnnotationStart="DrawAnnotationStart",a.DrawAnnotationEnd="DrawAnnotationEnd",a.ResampleSingleSeriesStart="ResampleSingleSeriesStart",a.ResampleSingleSeriesEnd="ResampleSingleSeriesEnd",a.DrawSingleSeriesStart="DrawSingleSeriesStart",a.DrawSingleSeriesEnd="DrawSingleSeriesEnd",a.DrawCollectionSeriesStart="DrawCollectionSeriesStart",a.DrawCollectionSeriesEnd="DrawCollectionSeriesEnd",a.PerformTextLayoutStart="PerformTextLayoutStart",a.PerformTextLayoutEnd="PerformTextLayoutEnd",a.DrawDataLabelsStart="DrawDataLabelsStart",a.DrawDataLabelsEnd="DrawDataLabelsEnd",a.SingleLayerDrawStart="SingleLayerDrawStart",a.SingleLayerDrawEnd="SingleLayerDrawEnd",a.AllLayersDrawStart="AllLayersDrawStart",a.AllLayersDrawEnd="AllLayersDrawEnd",a.PostDrawActionsStart="PostDrawActionsStart",a.PostDrawActionsEnd="PostDrawActionsEnd",a.PointerMoveStart="PointerMoveStart",a.PointerMoveEnd="PointerMoveEnd",a.PointerDownStart="PointerDownStart",a.PointerDownEnd="PointerDownEnd",a.PointerUpStart="PointerUpStart",a.PointerUpEnd="PointerUpEnd",a.ScrollStart="ScrollStart",a.ScrollEnd="ScrollEnd",a.DoubleClickStart="DoubleClickStart",a.DoubleClickEnd="DoubleClickEnd",a.MouseLeaveStart="MouseLeaveStart",a.MouseLeaveEnd="MouseLeaveEnd",a.MouseEnterStart="MouseEnterStart",a.MouseEnterEnd="MouseEnterEnd",a.PaletteProviderStart="PaletteProviderStart",a.PaletteProviderEnd="PaletteProviderEnd",a.GenerateDataLabelsStart="GenerateDataLabelsStart",a.GenerateDataLabelsEnd="GenerateDataLabelsEnd",a.RenderDataTransformStart="RenderDataTransformStart",a.RenderDataTransformEnd="RenderDataTransformEnd",a.DataFilterStart="DataFilterStart",a.DataFilterEnd="DataFilterEnd",a.AccumulatedVectorStart="AccumulatedVectorStart",a.AccumulatedVectorEnd="AccumulatedVectorEnd"})(t.EPerformanceMarkType||(t.EPerformanceMarkType={}));var n;(function(a){a[a.Info=0]="Info",a[a.Verbose=1]="Verbose"})(n=t.EPerformanceDebugLevel||(t.EPerformanceDebugLevel={}));var r=(function(){function a(){this.separator="_"}return a.mark=function(s,l){if(a.enableDebug){var u=a.instance.addMark(s,l),c=s.replace("End","Start");return s.includes("End")&&(a.measuredMarks.includes(s)||a.measuredMarks.includes(c))&&a.instance.createMeasureFromEndMark(u),u}},a.getMarks=function(){return a.instance.getMarks()},a.clearMarks=function(s){return a.instance.clearMarks(s)},a.outputLogs=function(){var s=a.instance.getMarks();s.forEach(function(l){console.log(l.name,l.startTime)})},a.getMeasures=function(){return a.instance.getMeasures()},a.toJSON=function(){var s=a.instance.getMarks(),l=s.map(function(u){var c=u.name,d=u.startTime,f=u.detail;return{name:c,startTime:d,detail:f}});return{name:self.name,timeOrigin:performance.timeOrigin,marks:l}},a.measure=function(s,l,u){return a.instance.createMeasure(s,l,u)},a.prototype.getMarks=function(){return performance.getEntriesByType("mark")},a.prototype.getMeasures=function(){return performance.getEntriesByType("measure")},a.prototype.clearMarks=function(s){performance.clearMarks(s)},a.prototype.addMark=function(s,l){var u,c=l??{level:n.Info},d=c.level,f=e(c,["level"]),h=d??n.Info,p=s.includes("Start")?s.replace("Start","End"):s.replace("End","Start");if(h<=a.debugLevel||a.measuredMarks.includes(s)||a.measuredMarks.includes(p)){var g=(u=l==null?void 0:l.relatedId)!==null&&u!==void 0?u:(0,i.generateGuid)();return f.relatedId=g,this.createMark(s,g,f)}return null},a.prototype.createMeasure=function(s,l,u){var c=this.getMarks().filter(function(g){return g.name.startsWith(s)});if(c.length>0){var d=c[c.length-1];if(u&&(d=c.find(function(g){return g.detail.contextId===u})),!d)return;var f=d.name.replace("End","Start"),h=d.name.replace("Start","End"),p=l??h.replace("End","Time");return performance.measure(p,f,h)}},a.prototype.createMeasureFromEndMark=function(s,l){var u=s.name.replace("End","Start"),c=l??u.replace("Start","Time");return performance.measure(c,u,s.name)},a.prototype.createMark=function(s,l,u){return performance.mark("".concat(s).concat(this.separator).concat(l),{detail:u})},a.enableDebug=!1,a.debugLevel=n.Info,a.instance=new a,a.measuredMarks=[],a})();t.PerformanceDebugHelper=r;function o(a){var s=new MessageChannel;s.port1.onmessage=a,s.port2.postMessage(void 0)}t.runAfterFramePaint=o})(PN)),PN}var Qhe;function nFe(){if(Qhe)return DT;Qhe=1;var t=DT&&DT.__assign||function(){return t=Object.assign||function(u){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(u[h]=c[h])}return u},t.apply(this,arguments)};Object.defineProperty(DT,"__esModule",{value:!0}),DT.MouseManager=void 0;var e=iFe(),i=vs(),n=Th(),r=La(),o=ci(),a;(function(u){u[u.Move=0]="Move",u[u.Down=1]="Down",u[u.Up=2]="Up",u[u.Wheel=3]="Wheel",u[u.Click=4]="Click",u[u.Leave=5]="Leave",u[u.Enter=6]="Enter",u[u.Cancel=7]="Cancel",u[u.Drop=8]="Drop"})(a||(a={}));var s=[i.ESurfaceType.SciChartSurfaceType,i.ESurfaceType.SciChartPolarSurfaceType],l=(function(){function u(c){this.isOver=!1,this.maxTapDuration=500,this.enableDoubleTapPolyfill=!0,this.forceDoubleTapPolyfill=!1,this.sciChartSurface=c,this.onPointerMove=this.onPointerMove.bind(this),this.onPointerDown=this.onPointerDown.bind(this),this.onPointerUp=this.onPointerUp.bind(this),this.onMouseWheel=this.onMouseWheel.bind(this),this.onDoubleClick=this.onDoubleClick.bind(this),this.onMouseLeave=this.onMouseLeave.bind(this),this.onMouseEnter=this.onMouseEnter.bind(this),this.onContextMenu=this.onContextMenu.bind(this),this.onPointerCancel=this.onPointerCancel.bind(this),this.onDrop=this.onDrop.bind(this)}return u.prototype.subscribe=function(c){o.Guard.notNull(c,"source"),this.unsubscribe(),this.canvas=c,c.addEventListener("pointermove",this.onPointerMove),c.addEventListener("pointerdown",this.onPointerDown),c.addEventListener("pointerup",this.onPointerUp),c.addEventListener("pointercancel",this.onPointerCancel),c.addEventListener("wheel",this.onMouseWheel),c.addEventListener("dblclick",this.onDoubleClick),c.addEventListener("mouseleave",this.onMouseLeave),c.addEventListener("mouseenter",this.onMouseEnter),c.addEventListener("contextmenu",this.onContextMenu),c.addEventListener("drop",this.onDrop)},u.prototype.unsubscribe=function(){this.canvas&&(this.canvas.removeEventListener("pointermove",this.onPointerMove),this.canvas.removeEventListener("pointerdown",this.onPointerDown),this.canvas.removeEventListener("pointerup",this.onPointerUp),this.canvas.removeEventListener("pointercancel",this.onPointerCancel),this.canvas.removeEventListener("wheel",this.onMouseWheel),this.canvas.removeEventListener("dblclick",this.onDoubleClick),this.canvas.removeEventListener("mouseleave",this.onMouseLeave),this.canvas.removeEventListener("mouseenter",this.onMouseEnter),this.canvas.removeEventListener("contextmenu",this.onContextMenu),this.canvas.removeEventListener("drop",this.onDrop)),this.canvas=null},u.prototype.onPointerCancel=function(c){var d=e.ModifierMouseArgs.fromPointerEvent(c);this.modifierPointerCancel(d)},u.prototype.onPointerMove=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerMoveStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromPointerEvent(c);this.modifierMouseMove(h),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerMoveEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onPointerDown=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerDownStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromPointerEvent(c);this.modifierMouseDown(h);var p=this.forceDoubleTapPolyfill||this.enableDoubleTapPolyfill&&!this.supportsDoubleTap,g=c.pointerType==="touch"||c.pointerType==="pen";if(p&&g){var v=new Date().getTime(),y=!!this.lastTapTime,m=v-this.lastTapTime<this.maxTapDuration,b=c.isPrimary;if(y&&b&&m){this.lastTapTime=void 0,this.doubleTapHandled=!0;var S=e.ModifierMouseArgs.fromPointerEvent(c);this.modifierDoubleClick(S)}else this.lastTapTime=v,this.doubleTapHandled=!1}else this.doubleTapHandled=!1;r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerDownEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onPointerUp=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerUpStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromPointerEvent(c);this.modifierMouseUp(h),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.PointerUpEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onDoubleClick=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.DoubleClickStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose});if(this.doubleTapHandled){this.supportsDoubleTap=!0;return}var h=e.ModifierMouseArgs.fromMouseEvent(c);this.modifierDoubleClick(h),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.DoubleClickEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onMouseWheel=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.ScrollStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromWheelEvent(c);this.modifierMouseWheel(h),h.handled&&c.preventDefault(),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.ScrollEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onMouseLeave=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.MouseLeaveStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromMouseEvent(c);this.modifierMouseLeave(h),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.MouseLeaveEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onMouseEnter=function(c){var d,f=r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.MouseEnterStart,{contextId:this.sciChartSurface.id,level:r.EPerformanceDebugLevel.Verbose}),h=e.ModifierMouseArgs.fromMouseEvent(c);this.modifierMouseEnter(h),r.PerformanceDebugHelper.mark(r.EPerformanceMarkType.MouseEnterEnd,{contextId:this.sciChartSurface.id,relatedId:(d=f==null?void 0:f.detail)===null||d===void 0?void 0:d.relatedId,level:r.EPerformanceDebugLevel.Verbose})},u.prototype.onContextMenu=function(c){c.preventDefault()},u.prototype.onDrop=function(c){var d=e.ModifierMouseArgs.fromMouseEvent(c);this.modifierDrop(d)},u.prototype.modifierPointerCancel=function(c){var d=this;if(c.isMaster&&c.target.releasePointerCapture(c.pointerId),this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierPointerCancel(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierPointerCancel(g)})}),this.updateSubCharts(c,a.Cancel)}},u.prototype.modifierMouseMove=function(c){var d=this;if(s.includes(this.sciChartSurface.surfaceType)){var f=this.sciChartSurface;if(f.adornerLayer.isAnnotationSelected){var h=f.adornerLayer.selectedAnnotation;h.isDraggingStarted&&h.onDragAdorner(c)}}if(this.chartModifiers.forEach(function(g){g.canReceiveMouseEvents&&(!c.handled||g.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&g.modifierGroup===c.modifierGroup)&&g.modifierMouseMove(c,d.sciChartSurface)}),c.isMaster){var p=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(g){d.sciChartSurface.otherSurfaces.forEach(function(v){var y=e.ModifierMouseArgs.copy(c,g,d.sciChartSurface.seriesViewRect,v.seriesViewRect,p);v.mouseManager.modifierMouseMove(y)})}),this.updateSubCharts(c,a.Move)}},u.prototype.modifierMouseDown=function(c){var d=this,f;c.isMaster&&((f=c.target)===null||f===void 0||f.setPointerCapture(c.pointerId));var h=function(){if(d.chartModifiers.forEach(function(S){S.canReceiveMouseEvents&&(!c.handled||S.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&S.modifierGroup===c.modifierGroup)&&S.modifierMouseDown(c,d.sciChartSurface)}),c.isMaster){var b=d.getMasterData(d.sciChartSurface,c);d.chartModifierGroups.forEach(function(S){d.sciChartSurface.otherSurfaces.forEach(function(_){var C=e.ModifierMouseArgs.copy(c,S,d.sciChartSurface.seriesViewRect,_.seriesViewRect,b);_.mouseManager.modifierMouseDown(C)})}),d.updateSubCharts(c,a.Down)}};if(c.isMaster){var p=function(b){b.adornerLayer.selectAnnotation(c);var S=b.adornerLayer.selectedAnnotation;S?S.onDragStarted(c)&&d.modifierMouseMove(c):h()};if(s.includes(this.sciChartSurface.surfaceType)){var g=this.sciChartSurface,v=g.adornerLayer.selectedAnnotation;if(v){var y=v.checkIsPointWithinClipArea(c.mousePoint),m=y&&v.onDragStarted(c);m||p(g)}else p(g)}else h()}else h()},u.prototype.modifierMouseUp=function(c){var d=this,f;if(c.isMaster&&((f=c.target)===null||f===void 0||f.releasePointerCapture(c.pointerId)),s.includes(this.sciChartSurface.surfaceType)){var h=this.sciChartSurface;if(h.adornerLayer.isAnnotationSelected){var p=h.adornerLayer.selectedAnnotation;p.isDraggingStarted&&p.onDragEnded()}}if(this.chartModifiers.forEach(function(v){v.canReceiveMouseEvents&&(!c.handled||v.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&v.modifierGroup===c.modifierGroup)&&v.modifierMouseUp(c,d.sciChartSurface)}),c.isMaster){var g=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(v){d.sciChartSurface.otherSurfaces.forEach(function(y){var m=e.ModifierMouseArgs.copy(c,v,d.sciChartSurface.seriesViewRect,y.seriesViewRect,g);y.mouseManager.modifierMouseUp(m)})}),this.updateSubCharts(c,a.Up)}},u.prototype.modifierMouseWheel=function(c){var d=this;if(this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierMouseWheel(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierMouseWheel(g)})}),this.updateSubCharts(c,a.Wheel)}},u.prototype.modifierDoubleClick=function(c){var d=this;if(this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierDoubleClick(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierDoubleClick(g)})}),this.updateSubCharts(c,a.Click)}},u.prototype.modifierMouseLeave=function(c){var d=this;if(this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierMouseLeave(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierMouseLeave(g)})}),this.updateSubCharts(c,a.Leave)}},u.prototype.modifierMouseEnter=function(c){var d=this;if(this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierMouseEnter(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierMouseEnter(g)})}),this.updateSubCharts(c,a.Enter)}},u.prototype.modifierDrop=function(c){var d=this;if(this.chartModifiers.forEach(function(h){h.canReceiveMouseEvents&&(!c.handled||h.receiveHandledEvents)&&(c.isMaster||!c.isMaster&&h.modifierGroup===c.modifierGroup)&&h.modifierDrop(c,d.sciChartSurface)}),c.isMaster){var f=this.getMasterData(this.sciChartSurface,c);this.chartModifierGroups.forEach(function(h){d.sciChartSurface.otherSurfaces.forEach(function(p){var g=e.ModifierMouseArgs.copy(c,h,d.sciChartSurface.seriesViewRect,p.seriesViewRect,f);p.mouseManager.modifierDrop(g)})}),this.updateSubCharts(c,a.Drop)}},u.prototype.getMasterData=function(c,d){return{}},Object.defineProperty(u.prototype,"chartModifiers",{get:function(){return this.sciChartSurface.chartModifiers.asArray()},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"chartModifierGroups",{get:function(){var c=this.chartModifiers.filter(function(d){return d.modifierGroup!==void 0}).map(function(d){return d.modifierGroup});return(0,n.getUniqueValues)(c)},enumerable:!1,configurable:!0}),u.prototype.updateSubCharts=function(c,d){var f=this,h=this.sciChartSurface.subCharts;if(!(!h||h.length===0)){var p=h==null?void 0:h.find(function(v){if(!v.offset)return!1;var y=v.offset,m=y.top,b=y.left,S=y.bottom,_=y.right,C=c.mousePoint,P=C.x,x=C.y,E=f.sciChartSurface.renderSurface.viewportSize,A=E.width,R=E.height;return b<=P&&P<=A-_&&m<=x&&x<=R-S}),g=!1;h==null||h.forEach(function(v){if(v.offset){var y=d,m=!0;if(v.mouseManager.isOver){if(v!==p){if(v.mouseManager.isOver=!1,y===a.Move){var b=new e.ModifierMouseArgs(c.mousePoint,c);g=g||f.processSubChartEvent(a.Leave,v,b,h,void 0)}y!==a.Cancel&&y!==a.Up&&(y=void 0)}}else if(v===p){if(v.mouseManager.isOver=!0,y===a.Move){var S=new e.ModifierMouseArgs(c.mousePoint,c);g=g||f.processSubChartEvent(a.Enter,v,S,h,void 0)}}else[a.Cancel,a.Up,a.Move].includes(y)||(y=void 0),m=!1;if(y!==void 0){var _=f.getMasterData(p,c);g=g||f.processSubChartEvent(y,v,t(t({},c),{isActiveSubChartEvent:m}),h,_)}}}),c.handled=c.handled||g}},u.prototype.processSubChartEvent=function(c,d,f,h,p){var g=this;f.handled=!1,this.callEvent(c,d,f);var v=f.handled;return f.isActiveSubChartEvent&&d.chartModifierGroups.forEach(function(y){h.filter(function(m){return m.id!==d.id}).forEach(function(m){var b=e.ModifierMouseArgs.copyForSubChart(f,y,d.seriesViewRect,m.seriesViewRect,p);g.callEvent(c,m,b),v=v||b.handled})}),v},u.prototype.callEvent=function(c,d,f){switch(c){case a.Cancel:d.mouseManager.modifierPointerCancel(f);break;case a.Click:d.mouseManager.modifierDoubleClick(f);break;case a.Down:d.mouseManager.modifierMouseDown(f);break;case a.Enter:d.mouseManager.modifierMouseEnter(f);break;case a.Leave:d.mouseManager.modifierMouseLeave(f);break;case a.Move:d.mouseManager.modifierMouseMove(f);break;case a.Up:d.mouseManager.modifierMouseUp(f);break;case a.Wheel:d.mouseManager.modifierMouseWheel(f);break;case a.Drop:d.mouseManager.modifierDrop(f);break}},u})();return DT.MouseManager=l,DT}var N0={},Oq={},epe;function uJ(){return epe||(epe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ObservableArrayChangedArgs=t.EObservableArrayChangedAction=void 0,(function(i){i[i.Add=0]="Add",i[i.Remove=1]="Remove",i[i.Replace=2]="Replace",i[i.Reset=3]="Reset"})(t.EObservableArrayChangedAction||(t.EObservableArrayChangedAction={}));var e=(function(){function i(n,r,o){this.action=n,this.oldItems=o,this.newItems=r}return i.prototype.getAction=function(){return this.action},i.prototype.getNewItems=function(){return this.newItems},i.prototype.getOldItems=function(){return this.oldItems},i})();t.ObservableArrayChangedArgs=e})(Oq)),Oq}var tpe;function DP(){if(tpe)return N0;tpe=1;var t=N0&&N0.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(N0,"__esModule",{value:!0}),N0.ObservableArray=N0.ObservableArrayBase=void 0;var e=ps(),i=uJ(),n=(function(){function o(){this.items=[],this.collectionChanged=new e.EventHandler}return o.prototype.size=function(){return this.items.length},o.prototype.add=function(){for(var a=this,s=[],l=0;l<arguments.length;l++)s[l]=arguments[l];s.forEach(function(u){return a.items.push(u)}),this.collectionChanged.raiseEvent(new i.ObservableArrayChangedArgs(i.EObservableArrayChangedAction.Add,s,void 0))},o.prototype.asArray=function(){return this.items},o.prototype.insert=function(a,s){if(a<0&&(a=0),a>=this.items.length){this.add(s);return}this.items.splice(a,0,s),this.collectionChanged.raiseEvent(new i.ObservableArrayChangedArgs(i.EObservableArrayChangedAction.Add,[s],void 0))},o.prototype.contains=function(a){return this.items.includes(a)},o.prototype.removeAt=function(a,s){if(s===void 0&&(s=!0),!(a<0||a>=this.items.length)){var l=this.items[a];this.items.splice(a,1),this.collectionChanged.raiseEvent(new i.ObservableArrayChangedArgs(i.EObservableArrayChangedAction.Remove,void 0,[l])),s&&(l!=null&&l.delete)&&l.delete()}},o.prototype.remove=function(a,s){s===void 0&&(s=!0);for(var l=0;l<this.size();l++)if(this.items[l]===a){this.removeAt(l,s);break}},o.prototype.clear=function(a){a===void 0&&(a=!0);var s=this.items;this.items=[],this.collectionChanged.raiseEvent(new i.ObservableArrayChangedArgs(i.EObservableArrayChangedAction.Reset,void 0,s)),a&&(s==null||s.forEach(function(l){l!=null&&l.delete&&l.delete()}))},o.prototype.get=function(a){return this.items[a]},o.prototype.set=function(a,s){this.items[a]=s,this.collectionChanged.raiseEvent(new i.ObservableArrayChangedArgs(i.EObservableArrayChangedAction.Replace,[s],void 0))},o})();N0.ObservableArrayBase=n;var r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.getById=function(s){return this.items.find(function(l){return l.id===s})},a.prototype.checkIdUniqueness=function(s){return this.items.filter(function(l){return l.id===s}).length<=1},a})(n);return N0.ObservableArray=r,N0}var CN={},rpe;function Gwt(){if(rpe)return CN;rpe=1,Object.defineProperty(CN,"__esModule",{value:!0}),CN.VisibilityObserver=void 0;var t=(function(){function e(i,n){this.callback=n,this.element=i}return e.observe=function(i,n){var r=new e(i,n);return r.init(),r},e.prototype.disconnect=function(){this.observer.disconnect()},e.prototype.init=function(){var i=this;this.observer=new IntersectionObserver(function(n){for(var r=0,o=n;r<o.length;r++){var a=o[r];i.callback(a.isIntersecting)}},{root:null,threshold:.01}),this.observer.observe(this.element)},e})();return CN.VisibilityObserver=t,CN}var TN={},ipe;function KP(){if(ipe)return TN;ipe=1,Object.defineProperty(TN,"__esModule",{value:!0}),TN.PropertyChangedEventArgs=void 0;var t=(function(){function e(i){this.propertyName=i}return e})();return TN.PropertyChangedEventArgs=t,TN}var xN={},npe;function oFe(){if(npe)return xN;npe=1,Object.defineProperty(xN,"__esModule",{value:!0}),xN.SimdHelper=void 0;var t=(function(){function e(){}return e.supportsWasmSIMD=function(){if(e.supportsSimd!==void 0)return e.supportsSimd;try{if(typeof WebAssembly>"u"||typeof WebAssembly.validate!="function")return e.supportsSimd=!1,!1;var i=new Uint8Array([0,97,115,109,1,0,0,0,1,5,1,96,0,1,123,3,2,1,0,10,10,1,8,0,65,0,253,15,253,98,11]);return e.supportsSimd=WebAssembly.validate(i),e.supportsSimd}catch{return e.supportsSimd=!1,!1}},e.supportsSimd=void 0,e})();return xN.SimdHelper=t,xN}var EN={},ope;function LD(){return ope||(ope=1,(function(t){var e=EN&&EN.__assign||function(){return e=Object.assign||function(o){for(var a,s=1,l=arguments.length;s<l;s++){a=arguments[s];for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&(o[u]=a[u])}return o},e.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.WebGlHelper=t.EWebGLSupport=void 0;var i=Uo(),n;(function(o){o.WebGL2="WebGL 2",o.WebGL1="WebGL 1",o.NoWebGL="No WebGL support"})(n=t.EWebGLSupport||(t.EWebGLSupport={}));var r=(function(){function o(){}return o.initialize=function(){if(!o.initialized){if(!o.webGlSupport&&!i.IS_TEST_ENV){var a=document.createElement("canvas");a.getContext("webgl2",{powerPreference:"high-performance"})?o.webGlSupport=n.WebGL2:a.getContext("webgl")?o.webGlSupport=n.WebGL1:o.webGlSupport=n.NoWebGL}if(o.initialized=!0,o.webGlSupport!==n.WebGL2)throw new Error("SciChart.js requires WebGL2 support.  This browser has "+o.webGlSupport)}},o.getWebGlSupport=function(){return o.initialize(),o.webGlSupport},o.getContext=function(a,s){if(!(!a||i.IS_TEST_ENV)){if(o.webGlSupport===n.WebGL1)return a.getContext("webgl",e({},s));if(o.webGlSupport===n.WebGL2)return a.getContext("webgl2",e(e({},s),{powerPreference:"high-performance"}));throw new Error("SciChart: WebGL not supported!")}},o.webGlSupport=void 0,o.initialized=!1,o})();t.WebGlHelper=r})(EN)),EN}var Dq={},ape;function ga(){return ape||(ape=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EBaseType=void 0,(function(e){e.Axis="Axis",e.Annotation="Annotation",e.RenderableSeries="RenderableSeries",e.LayoutManager="LayoutManager",e.ThemeProvider="ThemeProvider",e.Chart2DModifier="Chart2DModifier",e.Chart3DModifier="Chart3DModifier",e.LabelProvider="LabelProvider",e.PointMarker="PointMarker",e.PointMarker3D="PointMarker3D",e.ShaderEffect="ShaderEffect",e.PaletteProvider="PaletteProvider",e.Animation="Animation",e.Loader="Loader",e.MetadataGenerator="MetadataGenerator",e.OptionFunction="OptionFunction",e.OnCreateFunction="OnCreateFunction",e.DataFilter="DataFilter",e.LayoutStrategy="LayoutStrategy",e.DataLabelProvider="DataLabelProvider"})(t.EBaseType||(t.EBaseType={}))})(Dq)),Dq}var Rq={},spe;function $f(){return spe||(spe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EModifierType=void 0,(function(e){e.Chart2DModifier="2D Chart Modifier",e.Chart2DPolarModifier="2D Polar Chart Modifier",e.Chart3DModifier="3D Chart Modifier",e.MultiChart2DModifier="Multiple 2D Chart Modifier"})(t.EModifierType||(t.EModifierType={}))})(Rq)),Rq}var Mq={},lpe;function Pre(){return lpe||(lpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EUseWasmSimd=void 0,(function(e){e.Always="Always",e.Auto="Auto",e.Never="Never"})(t.EUseWasmSimd||(t.EUseWasmSimd={}))})(Mq)),Mq}var RT={},Lq={},upe;function OI(){return upe||(upe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EThemeProviderType=void 0,(function(e){e.Light="Light",e.Dark="Dark",e.DarkV2="DarkV2",e.Navy="Navy",e.Custom="Custom"})(t.EThemeProviderType||(t.EThemeProviderType={}))})(Lq)),Lq}var MT={},wN={},AN={},kq={},cpe;function JD(){return cpe||(cpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPaletteProviderType=void 0,(function(e){e.Gradient="Gradient",e.DataPointSelection="DataPointSelection",e.Custom="Custom",e.Gradient3D="Gradient3D",e.Solid3D="Solid3D"})(t.EPaletteProviderType||(t.EPaletteProviderType={}))})(kq)),kq}var Iq={},dpe;function vS(){return dpe||(dpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DefaultPaletteProvider=t.EFillPaletteMode=t.EStrokePaletteMode=void 0;var e;(function(r){r.GRADIENT="GRADIENT",r.SOLID="SOLID"})(e=t.EStrokePaletteMode||(t.EStrokePaletteMode={}));var i;(function(r){r.GRADIENT="GRADIENT",r.SOLID="SOLID"})(i=t.EFillPaletteMode||(t.EFillPaletteMode={}));var n=(function(){function r(){this.strokePaletteMode=e.GRADIENT,this.fillPaletteMode=i.GRADIENT}return r.createEmpty=function(){var o=new r;return o.overrideFillArgb=void 0,o.overrideStrokeArgb=void 0,o.overridePointMarkerArgb=void 0,o},r.prototype.onAttached=function(o){this.parentSeries=o},r.prototype.onDetached=function(){this.parentSeries=void 0},Object.defineProperty(r.prototype,"isRangeIndependant",{get:function(){return!1},enumerable:!1,configurable:!0}),r.prototype.shouldUpdatePalette=function(){return!0},r.prototype.overrideFillArgb=function(o,a,s,l,u,c){},r.prototype.overrideStrokeArgb=function(o,a,s,l,u,c){},r.prototype.overridePointMarkerArgb=function(o,a,s,l,u,c){},r.prototype.toJSON=function(){},r})();t.DefaultPaletteProvider=n})(Iq)),Iq}var fpe;function Cre(){if(fpe)return AN;fpe=1,Object.defineProperty(AN,"__esModule",{value:!0}),AN.PaletteFactory=void 0;var t=JD(),e=Ju(),i=Ti(),n=vS(),r=(function(){function o(){}return o.createGradient=function(a,s,l){s.endPoint.x-s.startPoint.x,s.endPoint.y-s.startPoint.y;var u=o.createColorMap(a,s.gradientStops.slice(0)),c,d=function(v,y,m,b){b===void 0&&(b=1);var S=c.getDataSeriesValuesCount(),_=m/(S-1),C=a.NumberUtil.Constrain(Math.round(_*(u.length-1)),0,u.length-1),P=u[C];return(0,e.uintArgbColorMultiplyOpacity)(P,b)},f=l===void 0||(l==null?void 0:l.enableStroke)===!0,h=(l==null?void 0:l.enableFill)===!0,p=(l==null?void 0:l.enablePointMarkers)===!0,g={strokePaletteMode:n.EStrokePaletteMode.GRADIENT,fillPaletteMode:n.EFillPaletteMode.GRADIENT,onAttached:function(v){c=v},onDetached:function(){},overrideStrokeArgb:function(v,y,m){var b;return f?d(v,y,m,(b=l==null?void 0:l.strokeOpacity)!==null&&b!==void 0?b:1):void 0},overrideFillArgb:function(v,y,m,b,S){var _;return h?d(v,y,m,(_=l==null?void 0:l.fillOpacity)!==null&&_!==void 0?_:1):void 0},overridePointMarkerArgb:function(v,y,m,b,S){var _,C=(_=l==null?void 0:l.pointMarkerOpacity)!==null&&_!==void 0?_:1;return p?{fill:d(v,y,m,C),stroke:d(v,y,m,C)}:void 0},toJSON:function(){return{type:t.EPaletteProviderType.Gradient,options:s}}};return g},o.createYGradient=function(a,s,l,u){var c=o.createColorMap(a,s.gradientStops.slice(0)),d=function(v,y){y===void 0&&(y=1);var m=(v-l.min)/l.diff,b=a.NumberUtil.Constrain(Math.round(m*(c.length-1)),0,c.length-1),S=c[b];return(0,e.uintArgbColorMultiplyOpacity)(S,y)},f=u===void 0||(u==null?void 0:u.enableStroke)===!0,h=(u==null?void 0:u.enableFill)===!0,p=(u==null?void 0:u.enablePointMarkers)===!0,g={strokePaletteMode:n.EStrokePaletteMode.GRADIENT,fillPaletteMode:n.EFillPaletteMode.GRADIENT,onAttached:function(v){},onDetached:function(){},overrideStrokeArgb:function(v,y,m){var b;return f?d(y,(b=u==null?void 0:u.strokeOpacity)!==null&&b!==void 0?b:1):void 0},overrideFillArgb:function(v,y,m,b,S){var _;return h?d(y,(_=u==null?void 0:u.strokeOpacity)!==null&&_!==void 0?_:1):void 0},overridePointMarkerArgb:function(v,y,m,b,S){var _,C=(_=u==null?void 0:u.pointMarkerOpacity)!==null&&_!==void 0?_:1;return p?{fill:d(y,C),stroke:d(y,C)}:void 0},toJSON:function(){return{type:t.EPaletteProviderType.Gradient,options:s}}};return g},o.createColorMap=function(a,s){var l=[],u=s.length,c=s[0].offset,d=s[s.length-1].offset,f=d-c,h=f/(o.precision-1),p=(0,i.parseColorToUIntArgb)(s[0].color),g=s[0].offset,v=p,y=g;u>1&&(v=(0,i.parseColorToUIntArgb)(s[1].color),y=s[1].offset),f=y-g;for(var m=0,b=0;b<o.precision;++b){var S=c+b*h;S>=y&&(m++,g=y,p=v,m+1<u&&(v=(0,i.parseColorToUIntArgb)(s[m+1].color),y=s[m+1].offset),f=y-g);var _=0;if(p===v||f<=1e-11)_=v;else{var C=(S-g)/f;_=a.NumberUtil.LinearInterpolateI(p,v,C)}l.push(_)}return l},o.precision=500,o})();return AN.PaletteFactory=r,AN}var hpe;function Xs(){return hpe||(hpe=1,(function(t){var e=wN&&wN.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.stripAutoColor=t.ThemeProvider=t.AUTO_COLOR=void 0;var i=Ti(),n=Cre();t.AUTO_COLOR="auto";var r=(function(){function a(){this.strokePalette=[],this.fillPalette=[]}return a.prototype.getStrokeColor=function(s,l,u){return this.getPaletteColor(s,l,u,!0)},a.prototype.getFillColor=function(s,l,u){return this.getPaletteColor(s,l,u,!1)},a.prototype.applyOverrides=function(s){this.overrides=s,Object.assign(this,s)},a.prototype.toJSON=function(){return e({type:this.type},this.overrides)},a.prototype.getPaletteColor=function(s,l,u,c){var d=c?this.strokePalette:this.fillPalette;if(!d||d.length===0)throw new Error("".concat(c?"stroke":"fill","Palette must not be empty to use get").concat(c?"Stroke":"Fill","Color"));if(d.length<2)return this.toColor(d[0]);if(s>l)throw new Error("index must be less than or equal to max");if(l<=d.length)return this.toColor(d[s]);var f=c?this.strokeGradient:this.fillGradient;if(!f){var h=typeof d[0]=="string"?d.map(function(y,m){return{color:y,offset:m/d.length-1}}):d;f=n.PaletteFactory.createColorMap(u,h),c?this.strokeGradient=f:this.fillGradient=f}var p=s/l,g=u.NumberUtil.Constrain(Math.round(p*(f.length-1)),0,f.length-1),v=f[g];return(0,i.parseArgbToHtmlColor)(v)},a.prototype.toColor=function(s){return typeof s=="string"?s:s.color},a})();t.ThemeProvider=r;var o=function(a){return a===t.AUTO_COLOR?"#00000000":a&&a.startsWith(t.AUTO_COLOR)?a.substring(t.AUTO_COLOR.length):a};t.stripAutoColor=o})(wN)),wN}var ppe;function uW(){if(ppe)return MT;ppe=1;var t=MT&&MT.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(MT,"__esModule",{value:!0}),MT.SciChartJSDarkTheme=void 0;var e=OI(),i=Xs(),n=(function(r){t(o,r);function o(){var a=r!==null&&r.apply(this,arguments)||this;return a.type=e.EThemeProviderType.Dark,a.sciChartBackground="#1C1C1EFF",a.loadingAnimationBackground="#1C1C1EFF",a.loadingAnimationForeground="#AAA",a.gridBorderBrush="#5A5B5BFF",a.axisBandsFill="#202123E1",a.axisBorder="#00000000",a.tickTextBrush="#A6A7ACFF",a.majorGridLineBrush="#323539FF",a.minorGridLineBrush="#232426FF",a.polarMajorGridLineBrush="#323539FF",a.polarMinorGridLineBrush="#232426FF",a.gridBackgroundBrush="TRANSPARENT",a.rolloverLineBrush="#42b64933",a.cursorLineBrush="#228B22FF",a.rubberBandFillBrush="#42b64933",a.rubberBandStrokeBrush="#42b64977",a.legendBackgroundBrush="#1D2C35FF",a.labelBackgroundBrush="#42b649AA",a.labelBorderBrush="#42b649FF",a.labelForegroundBrush="#EEEEEEFF",a.textAnnotationForeground="#EEEEEEFF",a.textAnnotationBackground="#42b649AA",a.annotationsGripsBorderBrush="#CDCDCD99",a.annotationsGripsBackgroundBrush="#CDCDCD22",a.annotationSelectionStroke="#f00e0e66",a.overviewFillBrush="#262728BB",a.scrollbarBackgroundBrush="#262728FF",a.scrollbarBorderBrush="#121212FF",a.scrollbarGripsBackgroundBrush="#535353FF",a.scrollbarViewportBackgroundBrush="#222222FF",a.scrollbarViewportBorderBrush="#232323FF",a.upWickColor="#50ff50FF",a.downWickColor="#ff5050FF",a.upBodyBrush="#50ff50B2",a.downBodyBrush="#ff5050B2",a.upBandSeriesLineColor="#279B27FF",a.downBandSeriesLineColor="#FF1919FF",a.upBandSeriesFillColor="#279B2733",a.downBandSeriesFillColor="#FF191933",a.mountainAreaBrush="#4083B777",a.mountainLineColor="#C6E6FFFF",a.lineSeriesColor="#C6E6FFFF",a.columnLineColor="#FFFFFFFF",a.columnFillBrush="#FFFFFFFF",a.impulseFillBrush="#FFFFFFFF",a.defaultColorMapBrush=[{offset:0,color:"DARKBLUE"},{offset:.5,color:"CORNFLOWERBLUE"},{offset:1,color:"#FF22AAFF"}],a.axisTitleColor="#C8C7C3FF",a.chartTitleColor="#C8C7C3FF",a.shadowEffectColor="#000000FF",a.planeBorderColor="#333333FF",a.axisPlaneBackgroundFill="TRANSPARENT",a.axis3DBandsFill="#202123E1",a.isLightBackground=!1,a}return o})(i.ThemeProvider);return MT.SciChartJSDarkTheme=n,MT}var gpe;function cW(){if(gpe)return RT;gpe=1;var t=RT&&RT.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(RT,"__esModule",{value:!0}),RT.SciChartJSDarkv2Theme=void 0;var e=OI(),i=uW(),n=(function(r){t(o,r);function o(){var a=r.call(this)||this;return a.type=e.EThemeProviderType.DarkV2,a.sciChartBackground="radial-gradient(circle, #3C3C3FFF 0%, #1C1C1EFF 100%)",a.loadingAnimationBackground="radial-gradient(circle, #3C3C3FFF 0%, #1C1C1EFF 100%)",a.axisBandsFill="#20212333",a.strokePalette=["#F48420","#AE408E","#209FD9","#264B93"],a.fillPalette=["#F4842077","#AE408E77","#209FD977","#264B9377"],a.isLightBackground=!1,a.majorGridLineBrush="#AAAAAA37",a.minorGridLineBrush="#77777719",a.polarMajorGridLineBrush="#494949",a.polarMinorGridLineBrush="#393939",a}return o})(i.SciChartJSDarkTheme);return RT.SciChartJSDarkv2Theme=n,RT}var ON={},Nq={},vpe;function Tre(){return vpe||(vpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EWatermarkPosition=void 0,(function(e){e.BottomLeft="BottomLeft",e.BottomRight="BottomRight",e.TopLeft="TopLeft",e.TopRight="TopRight"})(t.EWatermarkPosition||(t.EWatermarkPosition={}))})(Nq)),Nq}var DN={},ype;function xre(){if(ype)return DN;ype=1,Object.defineProperty(DN,"__esModule",{value:!0}),DN.DefaultSciChartLoader=void 0;var t=ci(),e=(function(){function n(){}return n.prototype.addChartLoader=function(r,o){this.addLoaderStyles(),t.Guard.notNull(r,"domDivContainer"),t.Guard.notNull(o,"theme");var a=document.createElement("div");a.style.background=o.loadingAnimationBackground,a.style.height="100%",a.style.width="100%",a.style.position="relative",a.style.zIndex="11";var s=document.createElement("div"),l='<div><span style="background: '.concat(o.loadingAnimationForeground,'"/></div>');return s.innerHTML=l.repeat(8),s.classList.add("scichart_loader"),a.appendChild(s),r.appendChild(a),a},n.prototype.removeChartLoader=function(r,o){try{r.removeChild(o)}catch(a){console.error(a)}},n.prototype.toJSON=function(){return{type:this.type}},n.prototype.addLoaderStyles=function(){if(!n.hasStyles){var r=document.head,o=document.createElement("style");o.id=n.sciChartLoaderStylesId,r.appendChild(o),o.appendChild(document.createTextNode(i)),n.hasStyles=!0}},n.hasStyles=!1,n.sciChartLoaderStylesId="scichart_default_loader_styles_id",n})();DN.DefaultSciChartLoader=e;var i=`
    .scichart_loader {
      display: inline-block;
      position: relative;
      width: 80px;
      height: 80px;
      top: 50%;
      transform: translateY(-50%);
    }
    .scichart_loader div {
      animation: scichart_loader 1.2s cubic-bezier(0.5, 0, 0.5, 1) infinite;
      transform-origin: 40px 40px;
    }
    .scichart_loader div span {
      display: block;
      position: absolute;
      width: 7px;
      height: 7px;
      border-radius: 50%;
      margin: -4px 0 0 -4px;
    }
    .scichart_loader div:nth-child(1) {
      animation-delay: -0.036s;
    }
    .scichart_loader div:nth-child(1) span {
      top: 63px;
      left: 63px;
    }
    .scichart_loader div:nth-child(2) {
      animation-delay: -0.072s;
    }
    .scichart_loader div:nth-child(2) span {
      top: 68px;
      left: 56px;
    }
    .scichart_loader div:nth-child(3) {
      animation-delay: -0.108s;
    }
    .scichart_loader div:nth-child(3) span {
      top: 71px;
      left: 48px;
    }
    .scichart_loader div:nth-child(4) {
      animation-delay: -0.144s;
    }
    .scichart_loader div:nth-child(4) span {
      top: 72px;
      left: 40px;
    }
    .scichart_loader div:nth-child(5) {
      animation-delay: -0.18s;
    }
    .scichart_loader div:nth-child(5) span {
      top: 71px;
      left: 32px;
    }
    .scichart_loader div:nth-child(6) {
      animation-delay: -0.216s;
    }
    .scichart_loader div:nth-child(6) span {
      top: 68px;
      left: 24px;
    }
    .scichart_loader div:nth-child(7) {
      animation-delay: -0.252s;
    }
    .scichart_loader div:nth-child(7) span {
      top: 63px;
      left: 17px;
    }
    .scichart_loader div:nth-child(8) {
      animation-delay: -0.288s;
    }
    .scichart_loader div:nth-child(8) span {
      top: 56px;
      left: 12px;
    }
    @keyframes scichart_loader {
      0% {
        transform: rotate(0deg);
      }
      100% {
        transform: rotate(360deg);
      }
    }
`;return DN}var mpe;function Wf(){if(mpe)return ON;mpe=1,Object.defineProperty(ON,"__esModule",{value:!0}),ON.SciChartDefaults=void 0;var t=Pre(),e=Tre(),i=xre(),n=(function(){function r(){}return r.useSharedCache=!0,r.debugDisableResampling=!1,r.performanceWarnings=!0,r.useNativeText=!0,r.nativeFontTimeout=2e3,r.watermarkPosition=e.EWatermarkPosition.BottomLeft,r.watermarkRelativeToCanvas=!1,r.defaultLoader=new i.DefaultSciChartLoader,r.disableAspect=!1,r.wasmBufferSizesKb=1024*8,r.createSuspended=!1,r.useWasmSimd=t.EUseWasmSimd.Auto,r.autoFontName="auto",r.nativeFontFamily="default",r.canvasFontFamily="Arial",r.alwaysRedrawFullChartOnSvgChange=!1,r})();return ON.SciChartDefaults=n,ON}var RN={},bpe;function aFe(){if(bpe)return RN;bpe=1,Object.defineProperty(RN,"__esModule",{value:!0}),RN.UpdateSuspender=void 0;var t=ps(),e=(function(){function i(){this.onResumed=new t.EventHandler,this.suspendCounter=0,this.locks=new Set}return Object.defineProperty(i.prototype,"isSuspended",{get:function(){return this.suspendCounter>0||this.locks.size>0},enumerable:!1,configurable:!0}),i.prototype.suspend=function(){this.suspendCounter++},i.prototype.resume=function(n){n===void 0&&(n=!1),this.suspendCounter=n?0:Math.max(this.suspendCounter-1,0),this.suspendCounter===0&&this.onResumed.raiseEvent()},i.prototype.lock=function(){var n=this,r=function(){var o=n.locks.delete(r);return o||console.warn('Seems like a suspender unlock token has been called multiple times. Make sure the logic is correct."'),o};return this.locks.add(r),r},i})();return RN.UpdateSuspender=e,RN}var MN={},LN={},Spe;function sFe(){if(Spe)return LN;Spe=1,Object.defineProperty(LN,"__esModule",{value:!0}),LN.OneTimePerformanceWarning=void 0;var t=lW(),e=Wf(),i=(function(){function n(r,o){o===void 0&&(o=!0),this.warnedProperty=!1,this.messageProperty=r,this.checkLicense=o}return n.prototype.warn=function(){return!e.SciChartDefaults.performanceWarnings||this.warnedProperty||this.checkLicense&&!t.licenseManager2dState.isDev?!1:(console.warn(this.messageProperty),this.warnedProperty=!0,!0)},n})();return LN.OneTimePerformanceWarning=i,LN}var _pe;function GV(){if(_pe)return MN;_pe=1,Object.defineProperty(MN,"__esModule",{value:!0}),MN.performanceWarnings=void 0;var t=sFe(),e=". To disable this warning set SciChartDefaults.performanceWarnings = false";return MN.performanceWarnings={dataDistributionFlagNaN:new t.OneTimePerformanceWarning("Data Distribution flag (BaseDataSeries.containsNaN = false) can be applied to improve performance. Read this website article https://www.scichart.com/documentation/js/current/DataSeries_Resampling.html for more info"+e),dataDistributionFlagSortedAscending:new t.OneTimePerformanceWarning("Data Distribution flag (BaseDataSeries.isSorted = true) can be applied to improve performance. Read this website article https://www.scichart.com/documentation/js/current/DataSeries_Resampling.html for more info"+e),subchartBackgroundNotSimpleColor:new t.OneTimePerformanceWarning("When using isTransparent: false on a SubChart, the background needs to be a simple color, not an html gradient (which the default theme uses)"+e),dataLabelsSkippingMany:new t.OneTimePerformanceWarning("DataLabelProvider generated many more labels than it could display.  To improve performance consider increasing the pointGapThreshold, increasing the skipNumber, or decreasing the pointCountThreshold"+e),dateTimeDeltaCalculatorBadDelta:new t.OneTimePerformanceWarning("The DateTimeDeltaCalculator could not find a suitable delta given the current settings. Either increase axis.maxAutoTicks, set axis.deltaCalculator.minTicks less than maxAutoTicks / 3, or set possibleDeltas to an array containing more closely spaced values"+e),wasmSimdWarning:new t.OneTimePerformanceWarning("WebAssembly SIMD is not supported by your browser or disabled by config. Ensure you serve the files scichart2d-nosimd.wasm and scichart3d-nosimd.wasm"+e,!1)},MN}var LT={},kN={},Ppe;function fo(){return Ppe||(Ppe=1,(function(t){var e=kN&&kN.__spreadArray||function(d,f,h){if(h||arguments.length===2)for(var p=0,g=f.length,v;p<g;p++)(v||!(p in f))&&(v||(v=Array.prototype.slice.call(f,0,p)),v[p]=f[p]);return d.concat(v||Array.prototype.slice.call(f))};Object.defineProperty(t,"__esModule",{value:!0}),t.createWasmContextRevocableProxy=t.WasmContextProxyHandler=t.WasmObjectConstructorProxyHandler=t.DeletableEntityProxyHandler=t.DeletableEntity=t.createTrackableProxy=void 0;var i=gm(),n=function(d,f){f===void 0&&(f=!1);var h=(0,i.generateIdentifier)(d),p=Proxy.revocable(d,new o(h));return i.MemoryUsageHelper.objectRegistry.add(d,h,{proxy:p.proxy,revocableToken:p,isWasmObject:f}),p.proxy};t.createTrackableProxy=n;var r=(function(){function d(f){try{var h}catch(p){console.warn("Error while creating an object proxy: ".concat(p," "))}}return d})();t.DeletableEntity=r;var o=(function(){function d(f){this.disposableEntityId=f}return d.prototype.construct=function(f,h){return console.warn("construct called on Deletable",this.disposableEntityId),f},d.prototype.apply=function(f,h,p){console.warn("apply called on Deletable",this.disposableEntityId)},d.prototype.get=function(f,h,p){var g=this;return h==="delete"?function(){for(var v=[],y=0;y<arguments.length;y++)v[y]=arguments[y];var m=i.MemoryUsageHelper.objectRegistry.remove(g.disposableEntityId);return m||console.warn("Failed to remove ".concat(g.disposableEntityId," from the Object Registry Probably it has been already deleted!")),f[h].apply(f,v)}:f[h]},d})();t.DeletableEntityProxyHandler=o;var a=(function(){function d(){}return d.prototype.construct=function(f,h,p){var g=new(f.bind.apply(f,e([void 0],h,!1)));return(0,t.createTrackableProxy)(g,!0)},d})();t.WasmObjectConstructorProxyHandler=a;var s={construct:function(){return s}},l=function(d){try{return!!new new Proxy(d,s)}catch{return!1}},u=(function(){function d(){this.constructorProxyHandler=new a}return d.prototype.get=function(f,h,p){var g=f[h],v=l(g);return v?new Proxy(g,this.constructorProxyHandler):g},d})();t.WasmContextProxyHandler=u;var c=function(d,f){i.MemoryUsageHelper.register(d,"wasmContext_".concat(f));var h={};return Proxy.revocable(d,h)};t.createWasmContextRevocableProxy=c})(kN)),kN}var IN={},Cpe;function Ig(){if(Cpe)return IN;Cpe=1,Object.defineProperty(IN,"__esModule",{value:!0}),IN.Size=void 0;var t=(function(){function e(i,n){this.width=i,this.height=n}return e.isEqual=function(i,n){return(i==null?void 0:i.width)===(n==null?void 0:n.width)&&(i==null?void 0:i.height)===(n==null?void 0:n.height)},e.EMPTY=new e(0,0),e})();return IN.Size=t,IN}var Tpe;function Ere(){if(Tpe)return LT;Tpe=1;var t=LT&&LT.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(LT,"__esModule",{value:!0}),LT.SciChartSurfaceCore=void 0;var e=fo(),i=ps(),n=$v(),r=Ig(),o=vs(),a=hl(),s=kh(),l=La(),u=(function(c){t(d,c);function d(f){var h=c.call(this)||this;return h.preRender=new i.EventHandler,h.rendered=new i.EventHandler,h.painted=new i.EventHandler,h.resized=new i.EventHandler,h.idProperty=(0,a.generateGuid)(),h.isDeletedProperty=!1,h.deletables=[],h.domChartRoot=f.domChartRoot,h.domCanvas2D=f.domCanvas2D,h.domSvgContainer=f.domSvgContainer,h.domSvgAdornerLayer=f.domSvgAdornerLayer,h.domDivContainer=f.domDivContainer,h.domBackgroundSvgContainer=f.domBackgroundSvgContainer,h}return Object.defineProperty(d.prototype,"id",{get:function(){return this.idProperty},set:function(f){this.idProperty=f},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"isDeleted",{get:function(){return this.isDeletedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"otherSurfaces",{get:function(){return this.getOtherSurfaces()},enumerable:!1,configurable:!0}),d.prototype.addDeletable=function(f){this.deletables.push(f)},d.prototype.onResize=function(f,h){l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.Resize,{contextId:this.id}),s.Logger.debug("onResize",f,h),this.changeViewportSize(f,h),this.resized.raiseEvent(new r.Size(f,h))},d.prototype.getOtherSurfaces=function(){var f;return(0,o.getIs2DSurfaceType)(this.surfaceType)?f=(0,n.getOther2DDestinations)(this):(0,o.getIs3DSurfaceType)(this.surfaceType)?f=(0,n.getOther3DDestinations)(this):f=(0,n.getOtherPieDestinations)(this),f.map(function(h){return h.sciChartSurface})},d})(e.DeletableEntity);return LT.SciChartSurfaceCore=u,LT}var xpe;function Sn(){return xpe||(xpe=1,(function(t){var e=L0&&L0.__extends||(function(){var G=function(H,U){return G=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(k,X){k.__proto__=X}||function(k,X){for(var W in X)Object.prototype.hasOwnProperty.call(X,W)&&(k[W]=X[W])},G(H,U)};return function(H,U){if(typeof U!="function"&&U!==null)throw new TypeError("Class extends value "+String(U)+" is not a constructor or null");G(H,U);function k(){this.constructor=H}H.prototype=U===null?Object.create(U):(k.prototype=U.prototype,new k)}})(),i=L0&&L0.__awaiter||function(G,H,U,k){function X(W){return W instanceof U?W:new U(function(Y){Y(W)})}return new(U||(U=Promise))(function(W,Y){function te(ge){try{de(k.next(ge))}catch(Ee){Y(Ee)}}function oe(ge){try{de(k.throw(ge))}catch(Ee){Y(Ee)}}function de(ge){ge.done?W(ge.value):X(ge.value).then(te,oe)}de((k=k.apply(G,H||[])).next())})},n=L0&&L0.__generator||function(G,H){var U={label:0,sent:function(){if(W[0]&1)throw W[1];return W[1]},trys:[],ops:[]},k,X,W,Y;return Y={next:te(0),throw:te(1),return:te(2)},typeof Symbol=="function"&&(Y[Symbol.iterator]=function(){return this}),Y;function te(de){return function(ge){return oe([de,ge])}}function oe(de){if(k)throw new TypeError("Generator is already executing.");for(;U;)try{if(k=1,X&&(W=de[0]&2?X.return:de[0]?X.throw||((W=X.return)&&W.call(X),0):X.next)&&!(W=W.call(X,de[1])).done)return W;switch(X=0,W&&(de=[de[0]&2,W.value]),de[0]){case 0:case 1:W=de;break;case 4:return U.label++,{value:de[1],done:!1};case 5:U.label++,X=de[1],de=[0];continue;case 7:de=U.ops.pop(),U.trys.pop();continue;default:if(W=U.trys,!(W=W.length>0&&W[W.length-1])&&(de[0]===6||de[0]===2)){U=0;continue}if(de[0]===3&&(!W||de[1]>W[0]&&de[1]<W[3])){U.label=de[1];break}if(de[0]===6&&U.label<W[1]){U.label=W[1],W=de;break}if(W&&U.label<W[2]){U.label=W[2],U.ops.push(de);break}W[2]&&U.ops.pop(),U.trys.pop();continue}de=H.call(G,U)}catch(ge){de=[6,ge],X=0}finally{k=W=0}if(de[0]&5)throw de[1];return{value:de[0]?de[1]:void 0,done:!0}}};Object.defineProperty(t,"__esModule",{value:!0}),t.getLocateFile=t.getMasterCanvas=t.createChartDestination=t.SciChartSurfaceBase=t.DebugForDpi=void 0;var r=mo(),o=AI(),a=Uo(),s=Br(),l=ps(),u=$v(),c=ci(),d=nFe(),f=DP(),h=Gwt(),p=KP(),g=oFe(),v=LD(),y=ga(),m=$f(),b=vs(),S=Pre(),_=Th(),C=gm(),P=cW(),x=Wf(),E=Zi(),A=aFe(),R=GV(),M=Ere();t.DebugForDpi=!1;var D="http://www.w3.org/2000/svg",F=(function(G){e(H,G);function H(U,k){k===void 0&&(k={});var X=G.call(this,k)||this;X.suspender=new A.UpdateSuspender,X.redrawRequested=new l.EventHandler,X.layoutMeasured=new l.EventHandler,X.genericAnimationsRun=new l.EventHandler,X.renderedToWebGl=new l.EventHandler,X.renderedToDestination=new l.EventHandler,X.hasInvalidState=!1,X.isWebGLContextActive=!0,X.themeProviderProperty=H.DEFAULT_THEME,X.previousThemeProviderProperty=H.DEFAULT_THEME,X.isInitializedProperty=!1,X.freezeWhenOutOfViewProperty=!1,c.Guard.notNull(U,"webAssemblyContext"),X.domCanvasWebGL=k.domCanvasWebGL,X.domSeriesBackground=k.domSeriesBackground,X.sharedWasmContext=U,X.propertyChanged=new l.EventHandler,X.detachChartModifier=X.detachChartModifier.bind(X),X.attachChartModifier=X.attachChartModifier.bind(X),X.chartModifiers=new f.ObservableArray,X.chartModifiers.collectionChanged.subscribe(function(de){var ge,Ee;(ge=de.getOldItems())===null||ge===void 0||ge.forEach(function(Re){return X.detachChartModifier(Re)}),(Ee=de.getNewItems())===null||Ee===void 0||Ee.forEach(function(Re){return X.attachChartModifier(Re)})}),X.detachAnnotation=X.detachAnnotation.bind(X),X.attachAnnotation=X.attachAnnotation.bind(X),X.annotations=new f.ObservableArray,X.modifierAnnotations=new f.ObservableArray,X.annotations.collectionChanged.subscribe(function(de){var ge,Ee;(ge=de.getOldItems())===null||ge===void 0||ge.forEach(function(Re){return X.detachAnnotation(Re)}),(Ee=de.getNewItems())===null||Ee===void 0||Ee.forEach(function(Re){return X.attachAnnotation(Re)})}),X.modifierAnnotations.collectionChanged.subscribe(function(de){var ge,Ee;(ge=de.getOldItems())===null||ge===void 0||ge.forEach(function(Re){return X.detachAnnotation(Re)}),(Ee=de.getNewItems())===null||Ee===void 0||Ee.forEach(function(Re){return X.attachAnnotation(Re)})}),X.mouseManager=new d.MouseManager(X),k.domCanvasWebGL?X.mouseManager.subscribe(k.domCanvasWebGL):k.domCanvas2D&&X.mouseManager.subscribe(k.domCanvas2D),X.onDpiChanged=X.onDpiChanged.bind(X),E.DpiHelper.dpiChanged.subscribe(X.onDpiChanged);try{var W,Y,te}catch(de){console.warn(de)}if(!a.IS_TEST_ENV&&H.invalidateOnTabVisible){var oe=function(){document.visibilityState==="visible"&&X.invalidateElement({force:!0})};document.addEventListener("visibilitychange",oe),X.addDeletable({delete:function(){return document.removeEventListener("visibilitychange",oe)}})}return X}return H.disposeSharedWasmContext=function(){u.sciChart3DDestinations.length===0&&u.sciChartDestinations.length===0&&H.domMasterCanvas&&(document.body.removeChild(H.domMasterCanvas),H.domMasterCanvas=void 0)},H.setRuntimeLicenseKey=function(U){o.licenseManager.setRuntimeLicenseKey(U)},H.UseCommunityLicense=function(){o.licenseManager.setRuntimeLicenseKey("community")},H.setServerLicenseEndpoint=function(U){o.licenseManager.setServerLicenseEndpoint(U)},H.setLicenseCallback=function(U){o.licenseManager.setLicenseCallback(U)},H.resolveOptions=function(U){if(U!=null&&U.theme&&"type"in U.theme){if(!("applyOverrides"in U.theme)){var k=(0,r.createType)(y.EBaseType.ThemeProvider,U.theme.type,null,U.theme);"applyOverrides"in k&&k.applyOverrides(U.theme),U.theme=k}}else U?U.theme=H.DEFAULT_THEME:U={theme:H.DEFAULT_THEME};return U!=null&&U.loader&&("addChartLoader"in U.loader||(U.loader=(0,r.createType)(y.EBaseType.Loader,U.loader.type,null,U.loader))),U},Object.defineProperty(H.prototype,"background",{get:function(){return this.backgroundProperty},set:function(U){this.backgroundProperty!==U&&(this.backgroundProperty=U,this.notifyPropertyChanged("Background"))},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"isCopyCanvasSurface",{get:function(){return!this.domCanvasWebGL&&this.domCanvas2D},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"seriesViewRect",{get:function(){return this.seriesViewRectProperty},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"viewRect",{get:function(){return this.chartViewRect},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"clipRect",{get:function(){return this.viewRect},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"otherSurfaces",{get:function(){return this.getOtherSurfaces()},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"isInitialized",{get:function(){return this.isInitializedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"isSuspended",{get:function(){return this.suspender.isSuspended},enumerable:!1,configurable:!0}),H.prototype.resumeUpdates=function(U){var k;this.suspender.resume(U==null?void 0:U.force),(!((k=U==null?void 0:U.invalidateOnResume)!==null&&k!==void 0)||k)&&this.invalidateElement()},H.prototype.suspendUpdates=function(){this.suspender.suspend()},H.prototype.applyTheme=function(U){this.previousThemeProviderProperty=this.themeProviderProperty,this.themeProviderProperty=U,this.chartModifiers.asArray().forEach(function(k){return k.applyTheme(U)}),this.invalidateElement()},Object.defineProperty(H.prototype,"themeProvider",{get:function(){return this.themeProviderProperty},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"previousThemeProvider",{get:function(){return this.previousThemeProviderProperty},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"isPolar",{get:function(){return this.surfaceType===b.ESurfaceType.SciChartPolarSurfaceType},enumerable:!1,configurable:!0}),Object.defineProperty(H.prototype,"freezeWhenOutOfView",{get:function(){return this.freezeWhenOutOfViewProperty},set:function(U){var k=this,X,W;this.freezeWhenOutOfViewProperty=U,U&&!this.visibilityObserver?this.visibilityObserver=h.VisibilityObserver.observe(this.domChartRoot,function(Y){!Y&&!k.cleanupLockToken?k.cleanupLockToken=k.suspender.lock():Y&&k.cleanupLockToken&&(k.cleanupLockToken(),k.cleanupLockToken=void 0)}):!U&&this.visibilityObserver&&((X=this.visibilityObserver)===null||X===void 0||X.disconnect(),this.visibilityObserver=void 0,(W=this.cleanupLockToken)===null||W===void 0||W.call(this))},enumerable:!1,configurable:!0}),H.prototype.delete=function(U){var k=this,X,W;this.isDeletedProperty=!0;var Y=(X=this.destinations)===null||X===void 0?void 0:X.findIndex(function(ge){return ge.sciChartSurface.id===k.id});Y>=0&&this.destinations.splice(Y,1),E.DpiHelper.dpiChanged.unsubscribe(this.onDpiChanged),this.mouseManager.unsubscribe(),this.mouseManager=void 0,this.chartModifiers.asArray().forEach(function(ge){return ge.delete()}),this.modifierAnnotations.asArray().forEach(function(ge){return ge.delete()}),this.annotations.asArray().forEach(function(ge){return ge.delete()}),this.adornerLayer=void 0;for(var te=0,oe=this.deletables;te<oe.length;te++){var de=oe[te];(0,s.deleteSafe)(de)}this.domChartRoot=void 0,this.domCanvasWebGL=void 0,this.domCanvas2D=void 0,this.domSvgContainer=void 0,this.domSvgAdornerLayer=void 0,this.domBackgroundSvgContainer=void 0,this.domSeriesBackground=void 0,this.domDivContainer=void 0,this.sharedWasmContext=void 0,this.deletables=[],(W=this.visibilityObserver)===null||W===void 0||W.disconnect(),this.visibilityObserver=void 0},H.prototype.getMainCanvas=function(){return this.domCanvasWebGL||this.domCanvas2D},H.prototype.setSeriesViewRect=function(U){this.seriesViewRectProperty=U},H.prototype.setDestinations=function(U){this.destinations=U},H.prototype.setIsInitialized=function(){this.isInitializedProperty=!0},H.prototype.getLicenseContext=function(){return this.sharedWasmContext},H.prototype.onDpiChanged=function(U){this.annotations.asArray().forEach(function(k){return k.onDpiChanged(U)}),this.modifierAnnotations.asArray().forEach(function(k){return k.onDpiChanged(U)}),this.invalidateElement()},H.prototype.nextStateRender=function(U){return i(this,void 0,void 0,function(){var k=this;return n(this,function(X){return[2,new Promise(function(W,Y){var te=function(oe){try{if(!oe){if(U!=null&&U.suspendAfter){var de=k.suspendUpdates();W(de)}else W(null);k.rendered.unsubscribe(te)}}catch(ge){console.error(ge),Y(ge)}};k.rendered.subscribe(te),U!=null&&U.resumeBefore&&(k.resumeUpdates(),U!=null&&U.invalidateOnResume&&k.invalidateElement())})]})})},Object.defineProperty(H.prototype,"chartModifierGroups",{get:function(){var U=this.chartModifiers.asArray().filter(function(k){return k.modifierGroup!==void 0}).map(function(k){return k.modifierGroup});return(0,_.getUniqueValues)(U)},enumerable:!1,configurable:!0}),H.prototype.clearRootElement=function(U){if(U&&this.domChartRoot){var k=this.domChartRoot.style;k&&(k.background="",k.position=""),this.domChartRoot.hasOwnProperty("replaceChildren")?this.domChartRoot.replaceChildren():this.domChartRoot.innerHTML=""}},H.prototype.applyOptions=function(U){var k,X;this.idProperty=(k=U==null?void 0:U.id)!==null&&k!==void 0?k:this.idProperty,this.widthAspect=U==null?void 0:U.widthAspect,this.heightAspect=U==null?void 0:U.heightAspect,this.disableAspect=U==null?void 0:U.disableAspect,this.freezeWhenOutOfView=(X=U==null?void 0:U.freezeWhenOutOfView)!==null&&X!==void 0?X:!1},H.prototype.detachChartModifier=function(U){U.modifierType!==m.EModifierType.MultiChart2DModifier&&(U.invalidateParentCallback=void 0,U.onDetach(),U.setParentSurface(void 0),this.invalidateElement())},H.prototype.attachChartModifier=function(U){if(U.modifierType===m.EModifierType.MultiChart2DModifier){if(this.chartModifiers.asArray().filter(function(k){return k===U}).length>1)throw Error("Invalid operation in sciChartSurface.attachChartModifier, this FinChartModifier has already been attached to this SciChartSurface.")}else if(U.invalidateParentCallback)throw Error("Invalid operation in sciChartSurface.attachChartModifier, this chartModifier has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.themeProviderProperty&&U.applyTheme(this.themeProviderProperty)},H.prototype.notifyPropertyChanged=function(U){var k;(k=this.propertyChanged)===null||k===void 0||k.raiseEvent(new p.PropertyChangedEventArgs(U)),this.invalidateElement()},H.prototype.changeMasterCanvasViewportSize=function(U,k,X){if(H.domMasterCanvas){var W=k,Y=X,te=H.domMasterCanvas.width/E.DpiHelper.PIXEL_RATIO,oe=H.domMasterCanvas.height/E.DpiHelper.PIXEL_RATIO;te>W&&(W=te),oe>Y&&(Y=oe),E.DpiHelper.setSize(H.domMasterCanvas,W,Y);var de=H.domMasterCanvas.width,ge=H.domMasterCanvas.height;U.SCRTSetMainWindowSize(de,ge)}},H.prototype.changeWebGLCanvasViewportSize=function(U,k,X){if(this.domCanvasWebGL){var W=k*E.DpiHelper.PIXEL_RATIO,Y=X*E.DpiHelper.PIXEL_RATIO;E.DpiHelper.setSize(this.domCanvasWebGL,k,X),U.SCRTSetMainWindowSize(W,Y)}},H.prototype.setSvgClipPathDefinitions=function(U,k,X){var W=U.querySelector("defs"),Y="seriesViewRectClip_".concat(this.id),te="surfaceViewRectClip_".concat(this.id);if(W||(W=document.createElementNS(D,"defs")),!W.querySelector("[id='".concat(Y,"']"))){var oe=document.createElementNS(D,"clipPath");oe.setAttribute("id",Y);var de=document.createElementNS(D,"rect");oe.appendChild(document.createElementNS(D,"rect")),oe.appendChild(de),W.appendChild(oe);var ge=document.createElementNS(D,"clipPath");ge.setAttribute("id",te);var Ee=document.createElementNS(D,"rect");ge.appendChild(document.createElementNS(D,"rect")),ge.appendChild(Ee),W.appendChild(ge),U.appendChild(W)}var Re=W.querySelector("[id='".concat(Y,"']")).firstElementChild,Ae=W.querySelector("[id='".concat(te,"']")).firstElementChild;Re.setAttribute("x","".concat(k.x)),Re.setAttribute("y","".concat(k.y)),Re.setAttribute("width","".concat(k.width)),Re.setAttribute("height","".concat(k.height)),Ae.setAttribute("x","".concat(X.x)),Ae.setAttribute("y","".concat(X.y)),Ae.setAttribute("width","".concat(X.width)),Ae.setAttribute("height","".concat(X.height))},H.prototype.detachAnnotation=function(U){U.onDetach(),U.invalidateParentCallback=void 0,U.parentSurface=void 0,this.invalidateElement()},H.prototype.attachAnnotation=function(U){if(U.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachAnnotation, this annotation has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");U.parentSurface=this,U.invalidateParentCallback=this.invalidateElement,U.onAttach(this),this.invalidateElement()},H.DEFAULT_THEME=new P.SciChartJSDarkv2Theme,H.AntiAliasWebGlBackbuffer=!1,H.wasmContextDisposeTimeout=0,H.autoDisposeWasmContext=!1,H.invalidateOnTabVisible=!0,H})(M.SciChartSurfaceCore);t.SciChartSurfaceBase=F;var I=function(G){if(G)return{canvas:G,GetHeight:function(){return this.canvas.height},GetWidth:function(){return this.canvas.width},GetID:function(){return this.canvas.id}}};t.createChartDestination=I;var V=function(){var G="SciChartMasterCanvas";if(!F.domMasterCanvas){var H=document.createElement("canvas");H.id=G,H.style.display="none",H.style.position="absolute",H.style.left="0",H.style.top="0",t.DebugForDpi&&(H.style.background="#00000077",H.style.pointerEvents="none",H.style.left="",H.style.top="",H.style.display="inline"),H.addEventListener("webglcontextcreationerror",function(U){console.warn("WebGL Context creation error: ",U.statusMessage||"Unknown error")},!1),document.body.appendChild(H),v.WebGlHelper.getContext(H,{premultipliedAlpha:!0,antialias:F.AntiAliasWebGlBackbuffer}),F.domMasterCanvas=H}return F.domMasterCanvas};t.getMasterCanvas=V;var z=function(G){return function(H,U){var k,X;if(H.endsWith(".wasm")){var W=void 0;switch(x.SciChartDefaults.useWasmSimd){case S.EUseWasmSimd.Always:W=!0;break;case S.EUseWasmSimd.Never:W=!1;break;case S.EUseWasmSimd.Auto:default:W=g.SimdHelper.supportsWasmSIMD();break}if(G!=null&&G.wasmUrl){var Y=G.wasmUrl;return W||(R.performanceWarnings.wasmSimdWarning.warn(),Y=(k=G==null?void 0:G.wasmNoSimdUrl)!==null&&k!==void 0?k:Y.replace(/\.wasm(\?|$)/,"-nosimd.wasm$1")),Y}else{var te=H;return W||(R.performanceWarnings.wasmSimdWarning.warn(),te=(X=G==null?void 0:G.wasmNoSimdUrl)!==null&&X!==void 0?X:H.replace(/\.wasm(\?|$)/,"-nosimd.wasm$1")),U+te}}return U+H}};t.getLocateFile=z})(L0)),L0}var Epe;function Zi(){if(Epe)return ET;Epe=1;var t=ET&&ET.__assign||function(){return t=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},t.apply(this,arguments)};Object.defineProperty(ET,"__esModule",{value:!0}),ET.DpiHelper=void 0;var e=Uo(),i=ps(),n=pa(),r=Sn(),o=(function(){function a(){}return a.initialize=function(){a.initialized||(a.PIXEL_RATIO=1,a.IsDpiScaleEnabled&&typeof window<"u"&&window.devicePixelRatio&&(a.PIXEL_RATIO=window.devicePixelRatio),r.DebugForDpi&&console.log("Initializing Dpi Helper. Scaling factor = "+a.PIXEL_RATIO),a.IsDpiScaleEnabled&&!e.IS_TEST_ENV&&window.addEventListener("resize",function(){var s=window.devicePixelRatio||1,l=a.PIXEL_RATIO;l!==s&&(r.DebugForDpi&&console.log("Dpi Changing, was ".concat(l,", now ").concat(s)),a.PIXEL_RATIO=s,a.dpiChanged.raiseEvent({newValue:s,oldValue:l}))}),a.initialized=!0)},a.createCanvas=function(s,l){s===void 0&&(s=0),l===void 0&&(l=0);var u=document.createElement("canvas");return s&&l&&a.setSize(u,s,l),u},a.setSize=function(s,l,u){a.setWidth(s,l),a.setHeight(s,u)},a.setWidth=function(s,l){r.DebugForDpi&&console.log("setWidth ".concat(s.id," backBuffer=").concat(l*a.PIXEL_RATIO," display=").concat(l)),s.width=l*a.PIXEL_RATIO},a.setHeight=function(s,l){r.DebugForDpi&&console.log("setHeight ".concat(s.id," backBuffer=").concat(l*a.PIXEL_RATIO," display=").concat(l)),s.height=l*a.PIXEL_RATIO},a.adjustLineStyle=function(s,l){l===void 0&&(l=a.PIXEL_RATIO);var u=t({},s);return u.end*=l,u.start*=l,u.strokeThickness*=l,u},a.adjustTextStyle=function(s,l){l===void 0&&(l=a.PIXEL_RATIO);var u=t({},s);return u.fontSize=Math.round(u.fontSize*l),s.padding&&(u.padding=a.adjustThickness(s.padding,l)),u},a.adjustStrokeSize=function(s,l){var u;l===void 0&&(l=a.PIXEL_RATIO);var c=t({},s),d=Math.round(s.strokeThickness*l);return c.strokeDashArray=(u=s.strokeDashArray)===null||u===void 0?void 0:u.map(function(f){return Math.round(f*l)}),c.strokeThickness=d>0||s.strokeThickness===0?d:1,c},a.adjustThickness=function(s,l){return l===void 0&&(l=a.PIXEL_RATIO),new n.Thickness(Math.round(s.top*l),Math.round(s.right*l),Math.round(s.bottom*l),Math.round(s.left*l))},a.IsDpiScaleEnabled=!0,a.dpiChanged=new i.EventHandler,a})();return ET.DpiHelper=o,ET}var kT={},NN={},FN={},wpe;function Rn(){if(wpe)return FN;wpe=1,Object.defineProperty(FN,"__esModule",{value:!0}),FN.Rect=void 0;var t=$i(),e=(function(){function i(n,r,o,a){if(o<0||a<0)throw new Error("Can not create Rect with negative width/height");this.x=n,this.y=r,this.width=o,this.height=a}return i.create=function(n,r,o,a){if(o<0||a<0)throw new Error("Rect.create width and height cannot be less than zero");return new i(n,r,o,a)},i.createWithCoords=function(n,r,o,a){var s=n,l=r,u=o-n,c=a-r;return new i(s,l,u,c)},i.createWithPoints=function(n,r){var o=Math.min(n.x,r.x),a=Math.min(n.y,r.y),s=Math.max(Math.max(n.x,r.x)-o,0),l=Math.max(Math.max(n.y,r.y)-a,0);return i.create(o,a,s,l)},i.createCopy=function(n){return new i(n.x,n.y,n.width,n.height)},i.createZero=function(){return new i(0,0,0,0)},i.isEqual=function(n,r){return n.x===r.x&&n.y===r.y&&n.width===r.width&&n.height===r.height},i.clipPointToRect=function(n,r){var o=n.x<r.x?r.x:n.x>r.x+r.width?r.x+r.width:n.x,a=n.y<r.y?r.y:n.y>r.y+r.height?r.y+r.height:n.y;return new t.Point(o,a)},i.intersect=function(n,r){var o=Math.max(n.left,r.left),a=Math.max(n.top,r.top),s=Math.min(n.right,r.right),l=Math.min(n.bottom,r.bottom);return o>s||a>l?i.createZero():i.createWithCoords(o,a,s,l)},Object.defineProperty(i.prototype,"left",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"top",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"right",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"bottom",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),i.hydrate=function(n){if(n){var r=n.x,o=n.y,a=n.width,s=n.height;return new i(r,o,a,s)}else return},i})();return FN.Rect=e,FN}var BN={},jN={},Fq={},Ape;function Vf(){return Ape||(Ape=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getFontFamily=t.getDefaultFontName=t.getFontString=void 0;var e=Wf(),i=function(o,a,s,l){var u=(0,t.getFontFamily)(l,!1);return a?"".concat(o," ").concat(a," ").concat(s,"px ").concat(u):"".concat(o," ").concat(s,"px ").concat(u)};t.getFontString=i;var n=function(){return e.SciChartDefaults.autoFontName.toLowerCase()};t.getDefaultFontName=n;var r=function(o,a){return o.toLowerCase()===(0,t.getDefaultFontName)()?a?e.SciChartDefaults.nativeFontFamily:e.SciChartDefaults.canvasFontFamily:o};t.getFontFamily=r})(Fq)),Fq}var Ope;function an(){return Ope||(Ope=1,(function(t){var e=jN&&jN.__extends||(function(){var M=function(D,F){return M=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(I,V){I.__proto__=V}||function(I,V){for(var z in V)Object.prototype.hasOwnProperty.call(V,z)&&(I[z]=V[z])},M(D,F)};return function(D,F){if(typeof F!="function"&&F!==null)throw new TypeError("Class extends value "+String(F)+" is not a constructor or null");M(D,F);function I(){this.constructor=D}D.prototype=F===null?Object.create(F):(I.prototype=F.prototype,new I)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.getAllFontKeys=t.getFontKey=t.getVector3=t.getVector2=t.getVector4=t.getNativeRect=t.getTextBounds=t.getTextureVertex=t.getArcParams=t.getArcVertex=t.getVertex=t.getVectorArcVertex=t.getVectorColorTextureVertex=t.getVectorColorVertex=t.getVectorRectVertex=t.freeCache=t.deleteCache=t.FontKey=void 0;var i=Uo(),n=fo(),r=Br(),o=Vf(),a=ZD(),s=Wf(),l=(function(M){e(D,M);function D(F){var I=M.call(this)||this;return I.firstLoadTime=Date.now(),I.nativeKey=F,I}return D.prototype.delete=function(){(0,r.deleteSafe)(this.nativeKey)},D})(n.DeletableEntity);t.FontKey=l;var u=new Map,c=function(M){var D,F,I=(F=(D=M==null?void 0:M.canvas)===null||D===void 0?void 0:D.id)!==null&&F!==void 0?F:"TEST";return u.has(I)||u.set(I,{vecRects:void 0,vecColorVertex:void 0,vecColorTextureVertex:void 0,vecArcVertex:void 0,vertex:void 0,arcVertex:void 0,textureVertex:void 0,rect:void 0,vector4:void 0,vector2:void 0,vector3:void 0,textBounds:void 0,arcParams:void 0,keyCache:new Map}),u.get(I)},d=function(M){if(M.canvas){var D=M.canvas.id,F=u.get(D);F&&((0,r.deleteSafe)(F.vecRects),(0,r.deleteSafe)(F.vecColorVertex),(0,r.deleteSafe)(F.vecColorTextureVertex),(0,r.deleteSafe)(F.vecArcVertex),(0,r.deleteSafe)(F.vertex),(0,r.deleteSafe)(F.arcVertex),(0,r.deleteSafe)(F.textureVertex),(0,r.deleteSafe)(F.rect),(0,r.deleteSafe)(F.vector4),(0,r.deleteSafe)(F.vector2),(0,r.deleteSafe)(F.vector3),(0,r.deleteSafe)(F.arcParams),(0,r.deleteSafe)(F.textBounds),F.keyCache.forEach(function(I){return(0,r.deleteSafe)(I)})),u.delete(D)}};t.deleteCache=d;var f=function(M){return{delete:function(){return(0,t.deleteCache)(M)}}};t.freeCache=f;var h=function(M,D){D===void 0&&(D=100);var F=c(M);if(F){var I=F.vecRects;return I||(I=new M.VectorRectVertex,I.reserve(D),F.vecRects=I),I.clear(),I}};t.getVectorRectVertex=h;var p=function(M,D){D===void 0&&(D=100);var F=c(M);if(F){var I=F.vecColorVertex;return I||(I=new M.VectorColorVertex,I.reserve(D),F.vecColorVertex=I),I.clear(),I}};t.getVectorColorVertex=p;var g=function(M,D){D===void 0&&(D=100);var F=c(M);if(F){var I=F.vecColorTextureVertex;return I||(I=new M.VectorColorTextureVertex,I.reserve(D),F.vecColorTextureVertex=I),I.clear(),I}};t.getVectorColorTextureVertex=g;var v=function(M,D){D===void 0&&(D=100);var F=c(M);if(F){var I=F.vecArcVertex;return I||(I=new M.VectorArcVertex,I.reserve(D),F.vecArcVertex=I),I.clear(),I}};t.getVectorArcVertex=v;var y=function(M,D,F,I){var V=c(M);if(V){var z=V.vertex;return z?(z.SetPosition(D,F),z.m_uiColor=I??i.NEUTRAL_COLOR):(z=new M.SCRTColorVertex(D,F),V.vertex=z),z}};t.getVertex=y;var m=function(M){var D=c(M);if(D){var F=D.arcVertex;return F||(F=new M.SCRTArcVertex,D.arcVertex=F),F}};t.getArcVertex=m;var b=function(M,D,F,I,V,z,G,H,U,k){var X=c(M);if(X){var W=X.arcParams;return W||(W=new M.SCRTArcParams,X.arcParams=W),W.m_fCenterX=D,W.m_fCenterY=F,W.m_fStartAngle=I,W.m_fEndAngle=V,W.m_fRadius=z,W.m_fInnerRadius=G,W.m_fIsGridLineMode=H,W.m_fAspectRatio=U,W.m_fLineThickness=k,W}};t.getArcParams=b;var S=function(M,D,F,I,V,z){var G=c(M);if(G){var H=G.textureVertex;return H?(H.SetPosition(D,F),H.m_uiColor=I??i.NEUTRAL_COLOR):(H=new M.SCRTColorTextureVertex(D,F),G.textureVertex=H),V!==void 0&&z!==void 0&&H.SetTexCoord(V,z),H}};t.getTextureVertex=S;var _=function(M){var D=c(M);if(D){var F=D.textBounds;return F||(F=new M.TSRTextBounds,D.textBounds=F),F}};t.getTextBounds=_;var C=function(M,D,F,I,V){var z=c(M),G=z.rect;return G?G.Assign(D,F,I-D,V-F):(G=new M.SCRTRectVertex(D,F,I-D,V-F),z.rect=G),G};t.getNativeRect=C;var P=function(M,D,F,I,V){var z=c(M),G=z.vector4;return G?G.Assign(D,F,I,V):(G=new M.TSRVector4(D,F,I,V),z.vector4=G),G};t.getVector4=P;var x=function(M,D,F){D===void 0&&(D=0),F===void 0&&(F=0);var I=c(M),V=I.vector2;return V?(V.x=D,V.y=F):(V=new M.TSRVector2(D,F),I.vector2=V),V};t.getVector2=x;var E=function(M,D,F,I){var V=c(M),z=V.vector3;return z?z.Assign(D,F,I):(z=new M.TSRVector3(D,F,I),V.vector3=z),z};t.getVector3=E;var A=function(M,D,F,I){F===void 0&&(F=!1),I===void 0&&(I=!1);var V=c(M);if(V){var z=V.keyCache,G=(0,o.getFontFamily)(D.fontFamily,!0),H={fontFamily:G,fontSize:D.fontSize,extras:(F?"advanced":"")+(I?"transformed":""),providerId:void 0},U=a.labelCache.getStyleId(H);if(!z.has(U)){var k=new l(new M.SCRTFontKey(G,D.fontSize,I,F));z.set(U,k)}var X=z.get(U),W=Date.now()-X.firstLoadTime;return W>s.SciChartDefaults.nativeFontTimeout&&(X.nativeKey.m_reload=!1),X.nativeKey}};t.getFontKey=A;var R=function(M){var D=c(M);return Array.from(D.keyCache.values()).map(function(F){return F.nativeKey})};t.getAllFontKeys=R})(jN)),jN}var Dpe;function ZP(){if(Dpe)return BN;Dpe=1,Object.defineProperty(BN,"__esModule",{value:!0}),BN.createNativeRect=void 0;var t=an(),e=function(i,n,r,o,a){return(0,t.getNativeRect)(i,n,r,o,a)};return BN.createNativeRect=e,BN}var Bq={},Rpe;function jv(){return Rpe||(Rpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EVerticalAnchorPoint=t.EHorizontalAnchorPoint=void 0,(function(e){e.Left="Left",e.Center="Center",e.Right="Right"})(t.EHorizontalAnchorPoint||(t.EHorizontalAnchorPoint={})),(function(e){e.Top="Top",e.Center="Center",e.Bottom="Bottom"})(t.EVerticalAnchorPoint||(t.EVerticalAnchorPoint={}))})(Bq)),Bq}var jq={},Mpe;function Tc(){return Mpe||(Mpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertMultiLineAlignment=t.EMultiLineAlignment=t.EVerticalTextPosition=t.EHorizontalTextPosition=void 0,(function(n){n.Left="Left",n.Center="Center",n.Right="Right"})(t.EHorizontalTextPosition||(t.EHorizontalTextPosition={})),(function(n){n.Above="Above",n.Center="Center",n.Below="Below"})(t.EVerticalTextPosition||(t.EVerticalTextPosition={}));var e;(function(n){n.Left="Left",n.Right="Right",n.Center="Center"})(e=t.EMultiLineAlignment||(t.EMultiLineAlignment={}));var i=function(n,r){var o=r.eTSRTextAlignMode.Left;switch(n){case e.Left:o=r.eTSRTextAlignMode.Left;break;case e.Right:o=r.eTSRTextAlignMode.Right;break;case e.Center:o=r.eTSRTextAlignMode.Center;break}return o};t.convertMultiLineAlignment=i})(jq)),jq}var Vq={},Lpe;function id(){return Lpe||(Lpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getNativeTextPosition=t.getMultilineTextHeight=t.getTextHeightToBaseline=t.getFirstLineHeightToBaseline=t.getNativeTextSize=t.convertToNativeLineSpacing=t.wrapNativeText=void 0;var e=an(),i=jv(),n=function(c,d,f,h){if(d===0)return c;if(!c)return"";var p=[],g=c.split(" "),v=g[0].trim(),y=v+" "+v+`
`+g.map(function(M){return M.trim()}).join(`
`);f.CalculateStringBounds(y??"",h,0);var m="",b=0,S=h.GetLineBounds(0),_=h.GetLineBounds(1),C=S.m_fWidth-2*_.m_fWidth;S.delete(),_.delete();for(var P=0;P<g.length;P++){var x=g[P],E=h.GetLineBounds(P+1),A=E.m_fWidth;E.delete();var R=m+(m!==""?" ":"")+x;b+=(m!==""?C:0)+A,b>d?m===""?(p.push(x),b=0):(p.push(m),m=x,b=A):m=R,m.endsWith(`
`)&&(b=0)}return p.push(m),p.join(`
`)};t.wrapNativeText=n;var r=function(c,d){var f=2;return Math.round(c*(d-1))+f};t.convertToNativeLineSpacing=r;var o=function(c,d,f,h,p){p===void 0&&(p=0);var g=(0,e.getTextBounds)(h);d.CalculateStringBounds(c,g,0);for(var v=0,y=0;y<g.GetLinesCount();y++){var m=g.GetLineBounds(y),b=m.m_fHeight;v<b&&(v=b),m.delete()}var S=(0,t.convertToNativeLineSpacing)(v,f.lineSpacing),_=Math.round(g.m_fHeight+(g.GetLinesCount()-1)*S+f.padding.top+f.padding.bottom),C=Math.round(g.m_fWidth+f.padding.left+f.padding.right),P=g.GetLineBounds(0),x=(0,t.getFirstLineHeightToBaseline)(P);P.delete();var E=p%360*Math.PI/180,A=Math.sin(E),R=Math.cos(E),M=Math.round(C*Math.abs(R)+_*Math.abs(A)),D=Math.round(C*Math.abs(A)+_*Math.abs(R)),F=0,I=0;return p>=0&&p<90?(F=(_-f.padding.top-x)*A+f.padding.left*R,I=f.padding.left*A+(f.padding.top+x)*R):p>=90&&p<=180?(F=M-(f.padding.top+x)*A+f.padding.left*R,I=-(_-f.padding.top-x)*R+f.padding.left*A):p>180&&p<=270?(F=M-(f.padding.top+x-_)*A+f.padding.left*R,I=D+(f.padding.top+x)*R+f.padding.left*A):p>270&&p<360&&(F=-(f.padding.top+x)*A+f.padding.left*R,I=D-(_-x-f.padding.top)*R+f.padding.left*A),{textHeight:D,textWidth:M,nativeLineSpacing:S,deltaX:F,deltaY:I}};t.getNativeTextSize=o;var a=function(c){return c.m_fHeight+c.m_fOffsetY};t.getFirstLineHeightToBaseline=a;var s=function(c){var d=c.GetLinesCount();if(d<1)return 0;if(d===1){var f=c.GetLineBounds(0),h=(0,t.getFirstLineHeightToBaseline)(f);return f.delete(),h}return(0,t.getMultilineTextHeight)(c)};t.getTextHeightToBaseline=s;var l=function(c){var d=c.GetLinesCount();if(d<1)return 0;if(d===1)return c.m_fHeight;for(var f=c.m_fHeight,h=0;h<d-1;h++){var p=c.GetLineBounds(h);f+=p.m_fOffsetY,p.delete()}return f};t.getMultilineTextHeight=l;var u=function(c,d,f,h,p,g){var v=c,y=d;f===i.EHorizontalAnchorPoint.Center?v-=p.m_fWidth/2+(g.right-g.left)/2:f===i.EHorizontalAnchorPoint.Right?v-=p.m_fWidth+g.right:v+=g.left;var m=p.GetLinesCount()>1,b=p.GetLineBounds(0);return m?h===i.EVerticalAnchorPoint.Center?y+=(0,t.getFirstLineHeightToBaseline)(b)-(0,t.getMultilineTextHeight)(p)/2+(g.top-g.bottom)/2:h===i.EVerticalAnchorPoint.Top?y+=(0,t.getFirstLineHeightToBaseline)(b)+g.top:(y+=(0,t.getFirstLineHeightToBaseline)(b)-(0,t.getMultilineTextHeight)(p),y-=g.bottom):h===i.EVerticalAnchorPoint.Center?y+=(0,t.getFirstLineHeightToBaseline)(b)/2+(g.top-g.bottom)/2:h===i.EVerticalAnchorPoint.Top?y+=(0,t.getFirstLineHeightToBaseline)(b)+g.top:y-=g.bottom,b.delete(),{x:v,y}};t.getNativeTextPosition=u})(Vq)),Vq}var kpe;function Iu(){return kpe||(kpe=1,(function(t){var e=NN&&NN.__extends||(function(){var b=function(S,_){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(C,P){C.__proto__=P}||function(C,P){for(var x in P)Object.prototype.hasOwnProperty.call(P,x)&&(C[x]=P[x])},b(S,_)};return function(S,_){if(typeof _!="function"&&_!==null)throw new TypeError("Class extends value "+String(_)+" is not a constructor or null");b(S,_);function C(){this.constructor=S}S.prototype=_===null?Object.create(_):(C.prototype=_.prototype,new C)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.WebGlRenderContext2D=t.ELineDrawMode=t.calculateAbsoluteRenderLayer=void 0;var i=Uo(),n=ci(),r=Rn(),o=ZP(),a=an(),s=fo(),l=La(),u=$i(),c=jv(),d=Tc(),f=Ju(),h=Ti(),p=id(),g=1e3,v=function(b,S,_){return b*g+_*S};t.calculateAbsoluteRenderLayer=v;var y;(function(b){b.PolyLine="PolyLine",b.DiscontinuousLine="DiscontinuousLine"})(y=t.ELineDrawMode||(t.ELineDrawMode={}));var m=(function(b){e(S,b);function S(_,C,P){var x=b.call(this)||this;return x.layers=new Map,x.effects=[],x.webAssemblyContext=_,x.viewportSize=C,x.canvasId=P,x.currentClipRect=r.Rect.create(0,0,C.width,C.height),x.currentRotation=0,x.currentTranslationX=0,x.currentTranslationY=0,x}return S.prototype.getNativeContext=function(){return this.nativeContext||(this.nativeContext=this.webAssemblyContext.SCRTGetMainRenderContext2D()),this.nativeContext},S.prototype.drawLinesNative=function(_,C,P,x,E,A){E===void 0&&(E=0),A===void 0&&(A=0);var R=P===y.PolyLine,M=this.getNativeContext();this.resetTransform(),this.translate(E,A),this.setClipRect(x);var D=new this.webAssemblyContext.SCRTDrawLinesParams;D.m_Type=R?this.webAssemblyContext.SCRTLineType.Strip:this.webAssemblyContext.SCRTLineType.List,D.SetPen(C),D.SetPointsVec(_),M.DrawLines(D),D.delete()},S.prototype.drawRects=function(_,C,P,x,E){x===void 0&&(x=0),E===void 0&&(E=0);var A=(0,a.getVector4)(this.webAssemblyContext,0,0,0,0),R=this.getNativeContext();this.resetTransform(),this.translate(x,E),this.setClipRect(P);var M=new this.webAssemblyContext.SCRTDrawRectsParams;M.SetVerticesVec(_),M.SetBrush(C),M.m_vAnchorParams=A,R.DrawRects(M),M==null||M.delete()},S.prototype.drawEllipses=function(_,C,P,x){P===void 0&&(P=0),x===void 0&&(x=0);var E=this.getNativeContext();this.resetTransform(),this.translate(P,x);var A=new this.webAssemblyContext.SCRTDrawRectsParams;A.SetVerticesVec(_),A.SetPen(C),A.SetBrush(null),A.m_bIsEllipses=!0,E.DrawRects(A),A==null||A.delete()},S.prototype.drawArcs=function(_,C,P,x,E,A,R,M,D){M===void 0&&(M=0),D===void 0&&(D=0);var F=this.getNativeContext(),I=0,V=0;if(x!==0){var z=Math.sqrt(C*C+P*P),G=Math.atan2(P,C);I=C-z*Math.cos(G+x),V=P-z*Math.sin(G+x)}this.resetTransform(),this.translate(I+M,V-D),this.rotate(x*180/Math.PI),this.setClipRect(E);var H=new this.webAssemblyContext.SCRTDrawArcsParams;H.SetVerticesVec(_),H.SetPen(A),H.SetBrush(R||null),F.DrawArcs(H),H==null||H.delete()},S.prototype.enqueueLayeredDraw=function(_,C){this.layers.has(C)||this.layers.set(C,[]),this.layers.get(C).push(_)},S.prototype.drawLayers=function(){for(var _,C,P=this.canvasId,x=l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.AllLayersDrawStart,{parentContextId:P,level:l.EPerformanceDebugLevel.Verbose}),E=Array.from(this.layers.keys()).sort(function(G,H){return G-H}),A=0,R=E;A<R.length;A++){for(var M=R[A],D=l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.SingleLayerDrawStart,{contextId:"Layer-".concat(M),parentContextId:P,level:l.EPerformanceDebugLevel.Verbose}),F=this.layers.get(M),I=0,V=F;I<V.length;I++){var z=V[I];z()}l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.SingleLayerDrawEnd,{relatedId:(_=D==null?void 0:D.detail)===null||_===void 0?void 0:_.relatedId,contextId:"Layer-".concat(M),parentContextId:P,level:l.EPerformanceDebugLevel.Verbose})}l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.AllLayersDrawEnd,{relatedId:(C=x==null?void 0:x.detail)===null||C===void 0?void 0:C.relatedId,parentContextId:P,level:l.EPerformanceDebugLevel.Verbose})},S.prototype.pushShaderEffect=function(_){_&&(this.effects.push(_),i.IS_TEST_ENV||this.getNativeContext().AddSeriesEffect(_.getNativeEffect()))},S.prototype.popShaderEffect=function(){var _=this.effects.pop();_&&!i.IS_TEST_ENV&&this.getNativeContext().RemoveSeriesEffect(_.getNativeEffect())},S.prototype.createPen=function(_,C,P,x){throw new Error("Use Pen2DCache for creating pens instead!")},S.prototype.createSolidBrush=function(_,C){throw new Error("Use BrushCache for creating brushes instead!")},S.prototype.delete=function(){},S.prototype.drawLine=function(_,C,P,x,E,A,R){if(!(!_&&!C&&!P&&!x)){n.Guard.notNull(E,"pen"),n.Guard.isTrue(E.getPenType()==="WasmPen","pen must be an instance of WasmPen to be used with the WasmRenderContext");var M=E.scrtPen;n.Guard.notNull(M,"WasmPen.scrtPen");var D=this.getNativeContext(),F=(0,a.getVectorColorVertex)(this.webAssemblyContext),I=(0,a.getVertex)(this.webAssemblyContext,_,C);F.push_back(I);var V=(0,a.getVertex)(this.webAssemblyContext,P,x);F.push_back(V),this.resetTransform(),this.translate(A.x,A.y),this.setClipRect(R);var z=new this.webAssemblyContext.SCRTDrawLinesParams;z.m_Type=this.webAssemblyContext.SCRTLineType.Strip,z.SetPen(M),z.SetPointsVec(F),D.DrawLines(z),z.delete()}},S.prototype.drawLines=function(_,C,P,x,E){E===void 0&&(E=y.PolyLine),n.Guard.notNull(C,"pen"),n.Guard.notNull(_,"xyValues"),n.Guard.isTrue(C.getPenType()==="WasmPen","pen must be an instance of WasmPen to be used with the WasmRenderContext"),n.Guard.isTrue(_.length>0&&_.length%2===0,"xyValues length must be a multiple of 2, values arranged as x0y0 x1y1 x2y2...");var A=C.scrtPen;n.Guard.notNull(A,"WebGlPen.scrtPen");for(var R=E===y.PolyLine,M=this.getNativeContext(),D=(0,a.getVectorColorVertex)(this.webAssemblyContext),F=0;F<_.length;F+=2){var I=(0,a.getVertex)(this.webAssemblyContext,_[F],_[F+1]);D.push_back(I)}this.resetTransform(),this.translate(P.x,P.y),this.setClipRect(x);var V=new this.webAssemblyContext.SCRTDrawLinesParams;V.m_Type=R?this.webAssemblyContext.SCRTLineType.Strip:this.webAssemblyContext.SCRTLineType.List,V.SetPen(A),V.SetPointsVec(D),M.DrawLines(V),V.delete()},S.prototype.drawTriangleStrip=function(_,C,P,x,E){if(E){n.Guard.arraysSameLength(_,"xValues",C,"yValues");var A=this.getNativeContext(),R=E.scrtBrush;n.Guard.notNull(R,"WebGlBrush.scrtBrush");for(var M=(0,a.getVectorColorTextureVertex)(this.webAssemblyContext),D=_.length,F=0;F<D;F++){var I=_[F],V=C[F],z=(0,a.getTextureVertex)(this.webAssemblyContext,I,V);M.push_back(z)}this.resetTransform(),this.translate(P.x,P.y),this.setClipRect(x);var G=new this.webAssemblyContext.SCRTDrawPrimitivesParams;G.SetVerticesVec(M),G.SetBrush(R),A.DrawPrimitives(G),G.delete()}},S.prototype.drawTexture=function(_,C,P,x,E){var A=this.getNativeContext(),R=new this.webAssemblyContext.SCRTTextureBrush(_,this.webAssemblyContext.eSCRTBrushMappingMode.PerPrimitive,1),M=(0,a.getVectorColorTextureVertex)(this.webAssemblyContext),D=(0,a.getTextureVertex)(this.webAssemblyContext,C,P,i.NEUTRAL_COLOR,0,0);M.push_back(D);var F=(0,a.getTextureVertex)(this.webAssemblyContext,C+x,P,i.NEUTRAL_COLOR,1,0);M.push_back(F);var I=(0,a.getTextureVertex)(this.webAssemblyContext,C,P+E,i.NEUTRAL_COLOR,0,1);M.push_back(I);var V=(0,a.getTextureVertex)(this.webAssemblyContext,C+x,P+E,i.NEUTRAL_COLOR,1,1);M.push_back(V);var z=new this.webAssemblyContext.SCRTDrawPrimitivesParams;z.SetVerticesVec(M),z.SetBrush(R),A.DrawPrimitives(z),R==null||R.delete(),z.delete()},S.prototype.drawRotatedRect=function(_,C,P,x,E,A,R,M,D,F){var I=F.scrtBrush;n.Guard.notNull(I,"WebGlBrush.scrtBrush");var V,z;switch(E){case c.EVerticalAnchorPoint.Bottom:V=P+x.bottom+x.top,z=C-P;break;case c.EVerticalAnchorPoint.Top:V=0,z=C+x.bottom+x.top;break;default:V=P/2+(x.bottom+x.top)/2,z=C-P/2+(x.bottom+x.top)/2}var G,H;switch(A){case c.EHorizontalAnchorPoint.Right:G=_+x.left+x.right,H=0;break;case c.EHorizontalAnchorPoint.Left:G=0,H=_+x.left+x.right;break;default:G=_/2+x.left,H=_/2+x.right}var U=r.Rect.createWithPoints(new u.Point(-G,-V),new u.Point(H,z)),k=this.getNativeContext(),X=(0,a.getVectorRectVertex)(this.webAssemblyContext),W=(0,a.getVector4)(this.webAssemblyContext,0,0,0,0),Y=(0,o.createNativeRect)(this.webAssemblyContext,U.x,U.y,U.right,U.bottom);X.push_back(Y),this.resetTransform(),this.translate(R.x,R.y),this.rotate(M),this.setClipRect(D);var te=new this.webAssemblyContext.SCRTDrawRectsParams;te.SetVerticesVec(X),te.SetBrush(I),te.m_vAnchorParams=W,k.DrawRects(te),te==null||te.delete()},S.prototype.drawRect=function(_,C,P,x,E,A,R){if(E){var M=this.getNativeContext(),D=E.scrtBrush;n.Guard.notNull(D,"WebGlBrush.scrtBrush");var F=(0,a.getVectorRectVertex)(this.webAssemblyContext),I=(0,a.getVector4)(this.webAssemblyContext,0,0,0,0),V=(0,o.createNativeRect)(this.webAssemblyContext,_.x,_.y,_.right,_.bottom);F.push_back(V),this.resetTransform(),this.translate(C.x,C.y),this.setClipRect(P);var z=new this.webAssemblyContext.SCRTDrawRectsParams;z.SetVerticesVec(F),z.SetBrush(D),z.m_vAnchorParams=I,M.DrawRects(z),z==null||z.delete()}if(x)if(A)this.drawLines([_.right,_.top,_.right,_.bottom,_.left,_.bottom,_.left,_.top,_.right,_.top,_.right,_.bottom],x,C,P,y.PolyLine);else{var G=Math.round(R/2)-1;this.drawLines([_.right,_.top-G,_.right,_.bottom+G,_.right,_.bottom,_.left,_.bottom,_.left,_.bottom+G,_.left,_.top-G,_.left,_.top,_.right,_.top],x,C,P,y.DiscontinuousLine)}},S.prototype.drawTextBackground=function(_,C,P,x,E,A,R,M,D){this.drawRotatedRect(_,C,C,M,A,R,x,P,E,D)},S.prototype.drawNativeText=function(_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U){H===void 0&&(H=1),U===void 0&&(U=3);var k=(0,h.parseColorToUIntArgb)(M),X=(0,f.uintArgbColorOverrideOpacity)(k,D),W={fontFamily:A,fontSize:R},Y=this.getFont(W,!1,!1),te=(0,a.getTextBounds)(this.webAssemblyContext);Y.CalculateStringBounds(z??"",te,U);var oe=C+x.x,de=P+x.y,ge=(0,p.getNativeTextPosition)(C,P,V,I,te,G),Ee=ge.x,Re=ge.y,Ae=te.m_fWidth,Pe=te.m_fHeight,we=(0,d.convertMultiLineAlignment)(d.EMultiLineAlignment.Center,this.webAssemblyContext),Te=Y.GetScale(),ke=!1;Te!==H&&(Y.SetScale(H),ke=!0);var $e=Ee+x.x,Ne=Re+x.y;F&&(this.drawTextBackground(Ae,Pe,-(_*180/Math.PI),new u.Point(oe,de),E,I,V,G,F),this.resetTransform());var ve=(0,a.getVector4)(this.webAssemblyContext,oe,de,_,0);Y.DrawStringAdvanced(z,X,Math.round($e),Math.round(Ne),ve,we,U),ke&&Y.SetScale(Te),Y.End()},S.prototype.printBlendMode=function(){var _=this.getNativeContext().GetBlendMode();switch(_){case this.webAssemblyContext.eSCRTBlendMode.BlendDefault:console.log("BlendDefault");break;case this.webAssemblyContext.eSCRTBlendMode.BlendAdditiveOneAlpha:console.log("BlendAdditiveOneAlpha");break;case this.webAssemblyContext.eSCRTBlendMode.BlendAdditiveColor:console.log("BlendAdditiveColor");break;case this.webAssemblyContext.eSCRTBlendMode.BlendAdditiveAlpha:console.log("BlendAdditiveAlpha");break;case this.webAssemblyContext.eSCRTBlendMode.BlendDisabled:console.log("BlendDisabled");break;default:throw new Error("Unhandled blendmode ")}},S.prototype.getFont=function(_,C,P){var x=this;C===void 0&&(C=!1),P===void 0&&(P=!1);var E=(0,a.getFontKey)(this.webAssemblyContext,_,C,P),A=this.getNativeContext(),R=A.AquireFont(E);if(R)R.m_isDrawing||R.Begin();else throw new Error("Could not create font "+E.m_strName);var M=R.GetFaceName();return M==="SCRT_Loading"?setTimeout(function(){var D;l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.Invalidate,{parentContextId:x.canvasId}),x.webAssemblyContext.TSRRequestCanvasDraw((D=x.canvasId)!==null&&D!==void 0?D:"undefinedCanvasId")},100):M!==E.m_strName&&(E.warned||(console.warn("Font ".concat(E.m_strName,` could not be found on the server and has not been registered. Falling back to default font.
                Use await scichartSurface.registerFont if you need to load the font from a remote url`)),E.warned=!0)),R},S.prototype.endFonts=function(_){for(var C,P=l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.DrawNativeTextStart,{contextId:this.canvasId,level:l.EPerformanceDebugLevel.Verbose}),x=this.getNativeContext(),E=(0,a.getAllFontKeys)(this.webAssemblyContext),A=0,R=E;A<R.length;A++){var M=R[A],D=x.AquireFont(M);D&&D.m_isDrawing&&D.End()}l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.DrawNativeTextEnd,{contextId:this.canvasId,relatedId:(C=P==null?void 0:P.detail)===null||C===void 0?void 0:C.relatedId,level:l.EPerformanceDebugLevel.Verbose})},S.prototype.setClipRect=function(_){var C=this.getNativeContext();C.SetClipRect(_.x,_.y,_.width,_.height),this.currentClipRect=_},S.prototype.setTranslationRotationAndClip=function(_,C,P,x){x===void 0&&(x=0),this.resetTransform(),this.translate(C,P),x!==0&&this.rotate(x),this.setClipRect(_)},S.prototype.resetAndClip=function(_){this.resetTransform(),this.setClipRect(_)},S.prototype.rotate=function(_){var C=this.getNativeContext();C.Rotate(_)},S.prototype.translate=function(_,C){var P=this.getNativeContext();P.Translate(_,C)},S.prototype.resetTransform=function(){var _=this.getNativeContext();_.ResetTransform()},S.webGlResourcesRefs=new Set,S})(s.DeletableEntity);t.WebGlRenderContext2D=m})(NN)),NN}var Ipe;function dW(){if(Ipe)return kT;Ipe=1;var t=kT&&kT.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(kT,"__esModule",{value:!0}),kT.BaseCache=void 0;var e=fo(),i=Br(),n=gm(),r=Iu(),o=(function(a){t(s,a);function s(l){var u=a.call(this)||this;return u.webAssemblyContext=l,l&&r.WebGlRenderContext2D.webGlResourcesRefs.add(u),u}return Object.defineProperty(s.prototype,"value",{get:function(){return this.cachedEntity},enumerable:!1,configurable:!0}),s.prototype.invalidateCache=function(){this.cachedEntity=(0,i.deleteSafe)(this.cachedEntity)},s.prototype.resetCache=function(){this.invalidateCache()},s.prototype.delete=function(){var l=this;this.cachedEntity=(0,i.deleteSafe)(this.cachedEntity),r.WebGlRenderContext2D.webGlResourcesRefs.delete(this),this.webAssemblyContext=void 0},s})(e.DeletableEntity);return kT.BaseCache=o,kT}var IT={},Hq={},Npe;function lFe(){return Npe||(Npe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDrawingTypes=void 0,(function(e){e.WasmBrush="WasmBrush",e.WasmPen="WasmPen"})(t.EDrawingTypes||(t.EDrawingTypes={}))})(Hq)),Hq}var Fpe;function uFe(){if(Fpe)return IT;Fpe=1;var t=IT&&IT.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(IT,"__esModule",{value:!0}),IT.WebGlPen=void 0;var e=Uo(),i=fo(),n=Br(),r=Ju(),o=lFe(),a=(function(s){t(l,s);function l(u,c){var d=s.call(this)||this;return d.scrtPenProperty=u,d.originalColor=c??(u==null?void 0:u.m_uiColor),d}return Object.defineProperty(l.prototype,"scrtPen",{get:function(){return this.scrtPenProperty},enumerable:!1,configurable:!0}),l.prototype.delete=function(){this.scrtPenProperty=(0,n.deleteSafe)(this.scrtPenProperty)},l.prototype.getPenType=function(){return o.EDrawingTypes.WasmPen},l.prototype.setOpacity=function(u){e.IS_TEST_ENV||(this.scrtPen.m_uiColor=(0,r.uintArgbColorMultiplyOpacity)(this.originalColor,u))},l})(i.DeletableEntity);return IT.WebGlPen=a,IT}var Bpe;function Ls(){return Bpe||(Bpe=1,(function(t){var e=hN&&hN.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.createPenInCache=t.getScrtPenFromCache=t.getWebGlPenFromCache=t.Pen2DCache=void 0;var i=Br(),n=ci(),r=Th(),o=Ti(),a=JNe(),s=Zi(),l=dW(),u=uFe(),c=(function(p){e(g,p);function g(){return p!==null&&p.apply(this,arguments)||this}return Object.defineProperty(g.prototype,"value",{get:function(){var v=!this.cachedEntity&&this.stroke;if(v){var y=this,m=y.stroke,b=y.strokeThickness,S=y.strokeDashArray,_=y.antiAliased,C=y.opacity;this.cachedEntity=this.create({stroke:m,strokeThickness:b,strokeDashArray:S,antiAliased:_,opacity:C})}return this.cachedEntity},enumerable:!1,configurable:!0}),g.prototype.create=function(v){var y=v.stroke,m=v.strokeThickness,b=m===void 0?1:m,S=v.strokeDashArray,_=v.antiAliased,C=_===void 0?!0:_,P=v.opacity,x=P===void 0?1:P,E=s.DpiHelper.adjustStrokeSize({strokeThickness:b,strokeDashArray:S}),A=E.strokeThickness,R=E.strokeDashArray;if(this.cachedEntity&&y===this.stroke&&A===this.adjustedStrokeThickness&&C===this.antiAliased&&(0,r.areArraysEqual)(R,this.adjustedStrokeDashArray))return x!==this.opacity&&(this.opacity=x,this.cachedEntity.setOpacity(x)),this.strokeThickness=b,this.strokeDashArray=S,this.cachedEntity;(0,i.deleteSafe)(this.cachedEntity),this.stroke=y,this.opacity=x,this.antiAliased=C,this.strokeThickness=b,this.adjustedStrokeThickness=A,this.strokeDashArray=S,this.adjustedStrokeDashArray=R;var M=(0,a.createSCRTPen)(this.webAssemblyContext,y,A,x,R,C);return this.cachedEntity=new u.WebGlPen(M,y?(0,o.parseColorToUIntArgb)(y):void 0)},g})(l.BaseCache);t.Pen2DCache=c;var d=function(p){return n.Guard.notNull(p,"penCache"),p.value};t.getWebGlPenFromCache=d;var f=function(p){var g=(0,t.getWebGlPenFromCache)(p);return g==null?void 0:g.scrtPen};t.getScrtPenFromCache=f;var h=function(p,g,v,y,m,b){n.Guard.notNull(p,"penCache");var S=p.create({stroke:g,strokeThickness:v,opacity:y,strokeDashArray:m,antiAliased:b});return S.scrtPen};t.createPenInCache=h})(hN)),hN}var VN={},HN={},jpe;function fW(){if(jpe)return HN;jpe=1,Object.defineProperty(HN,"__esModule",{value:!0}),HN.updateAxisIds=void 0;function t(e){var i,n;e.parentSurface&&(e.xAxisId||(e.xAxisId=(i=e.parentSurface.getDefaultXAxis())===null||i===void 0?void 0:i.id),e.yAxisId||(e.yAxisId=(n=e.parentSurface.getDefaultYAxis())===null||n===void 0?void 0:n.id))}return HN.updateAxisIds=t,HN}var Uq={},Vpe;function QD(){return Vpe||(Vpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDefaultRenderLayer=void 0,(function(e){e[e.Background=0]="Background",e[e.AxisBandsLayer=1]="AxisBandsLayer",e[e.MinorGridLinesLayer=2]="MinorGridLinesLayer",e[e.MajorGridLinesLayer=3]="MajorGridLinesLayer",e[e.AnnotationsBelowSeriesLayer=4]="AnnotationsBelowSeriesLayer",e[e.SeriesLayer=5]="SeriesLayer",e[e.HoveredSeriesLayer=6]="HoveredSeriesLayer",e[e.SelectedSeriesLayer=7]="SelectedSeriesLayer",e[e.AxisBordersLayer=8]="AxisBordersLayer",e[e.AxesLayer=9]="AxesLayer",e[e.AnnotationsAboveSeriesLayer=10]="AnnotationsAboveSeriesLayer",e[e.Foreground=11]="Foreground"})(t.EDefaultRenderLayer||(t.EDefaultRenderLayer={}))})(Uq)),Uq}var zq={},Hpe;function An(){return Hpe||(Hpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.fitSvgToViewRect=t.fitElementToViewRect=t.convertToHtmlPx=t.translateDataValueRectToAbsolute=t.translateToNotScaledRect=t.translateToScaledRect=t.translateToNotScaled=t.translateToScaled=t.translateFromSeriesViewRectToCanvasY=t.translateFromSeriesViewRectToCanvasX=t.translateFromCanvasToSeriesViewRectY=t.translateFromCanvasToSeriesViewRectX=t.translateFromSeriesViewRectToCanvas=t.translateFromCanvasToSeriesViewRect=void 0;var e=Zi(),i=$i(),n=Rn(),r=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m.x-b.x,C=m.y-b.y;if(!(!S&&(_<0||_>b.width||C<0||C>b.height)))return new i.Point(_,C)}};t.translateFromCanvasToSeriesViewRect=r;var o=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m.x+b.x,C=m.y+b.y;if(!(!S&&(_<0||_>b.width||C<0||C>b.height)))return new i.Point(_,C)}};t.translateFromSeriesViewRectToCanvas=o;var a=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m-b.x;if(!(!S&&(_<0||_>b.width)))return _}};t.translateFromCanvasToSeriesViewRectX=a;var s=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m-b.y;if(!(!S&&(_<0||_>b.height)))return _}};t.translateFromCanvasToSeriesViewRectY=s;var l=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m+b.x;if(!(!S&&(_<0||_>b.width)))return _}};t.translateFromSeriesViewRectToCanvasX=l;var u=function(m,b,S){if(S===void 0&&(S=!1),!!b){var _=m+b.y;if(!(!S&&(_<0||_>b.height)))return _}};t.translateFromSeriesViewRectToCanvasY=u;var c=function(m){return m*e.DpiHelper.PIXEL_RATIO};t.translateToScaled=c;var d=function(m){return m/e.DpiHelper.PIXEL_RATIO};t.translateToNotScaled=d;var f=function(m){return new n.Rect(m.x*e.DpiHelper.PIXEL_RATIO,m.y*e.DpiHelper.PIXEL_RATIO,m.width*e.DpiHelper.PIXEL_RATIO,m.height*e.DpiHelper.PIXEL_RATIO)};t.translateToScaledRect=f;var h=function(m){return new n.Rect(m.x/e.DpiHelper.PIXEL_RATIO,m.y/e.DpiHelper.PIXEL_RATIO,m.width/e.DpiHelper.PIXEL_RATIO,m.height/e.DpiHelper.PIXEL_RATIO)};t.translateToNotScaledRect=h;var p=function(m,b,S,_){var C=m.x,P=m.y,x=m.width,E=m.height,A=(0,t.translateToNotScaled)(_.left),R=(0,t.translateToNotScaled)(_.top),M=b.getCurrentCoordinateCalculator(),D=S.getCurrentCoordinateCalculator(),F=b.isVerticalChart?D.getCoordinate(C):M.getCoordinate(C),I=b.isVerticalChart?M.getCoordinate(P):D.getCoordinate(P);F=Math.max((0,t.translateToNotScaled)(F),0),I=Math.max((0,t.translateToNotScaled)(I),0);var V=b.flippedCoordinates?C-x:C+x,z=S.flippedCoordinates?P+E:P-E,G=(0,t.translateToNotScaled)(b.isVerticalChart?M.getCoordinate(z):D.getCoordinate(z)),H=(0,t.translateToNotScaled)(b.isVerticalChart?D.getCoordinate(V):M.getCoordinate(V));return F+=A,I+=R,H+=A,G+=R,new n.Rect(F,I,Math.abs(H-F),Math.abs(I-G))};t.translateDataValueRectToAbsolute=p;var g=function(m){return"".concat(m,"px")};t.convertToHtmlPx=g;var v=function(m,b){m.style.marginLeft="".concat(b.x,"px"),m.style.marginTop="".concat(b.y,"px"),m.setAttribute("width",b.width.toString()),m.setAttribute("height",b.height.toString()),m.style.width=b.width+"px",m.style.height=b.height+"px"};t.fitElementToViewRect=v;var y=function(m,b){(0,t.fitElementToViewRect)(m,b),m.currentScale=1};t.fitSvgToViewRect=y})(zq)),zq}var cp={},NT={},Upe;function ad(){return Upe||(Upe=1,Object.defineProperty(NT,"__esModule",{value:!0}),NT.autoReverseEasing=NT.easing=void 0,NT.easing={linear:function(t){return t},quadratic:function(t){return t*(-(t*t)*t+4*t*t-6*t+4)},cubic:function(t){return t*(4*t*t-9*t+6)},elastic:function(t){return t*(33*t*t*t*t-106*t*t*t+126*t*t-67*t+15)},inQuad:function(t){return t*t},outQuad:function(t){return t*(2-t)},inOutQuad:function(t){return t<.5?2*t*t:-1+(4-2*t)*t},inCubic:function(t){return t*t*t},outCubic:function(t){return--t*t*t+1},inOutCubic:function(t){return t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1},inQuart:function(t){return t*t*t*t},outQuart:function(t){return 1- --t*t*t*t},inOutQuart:function(t){return t<.5?8*t*t*t*t:1-8*--t*t*t*t},inQuint:function(t){return t*t*t*t*t},outQuint:function(t){return 1+--t*t*t*t*t},inOutQuint:function(t){return t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t},inSine:function(t){return-Math.cos(t*(Math.PI/2))+1},outSine:function(t){return Math.sin(t*(Math.PI/2))},inOutSine:function(t){return-(Math.cos(Math.PI*t)-1)/2},inExpo:function(t){return Math.pow(2,10*(t-1))},outExpo:function(t){return t===1?1:-Math.pow(2,-10*t)+1},inOutExpo:function(t){return t/=.5,t<1?Math.pow(2,10*(t-1))/2:(t--,(-Math.pow(2,-10*t)+2)/2)},inCirc:function(t){return-Math.sqrt(1-t*t)+1},outCirc:function(t){return Math.sqrt(1-(t=t-1)*t)},inOutCirc:function(t){return t/=.5,t<1?-(Math.sqrt(1-t*t)-1)/2:(t-=2,(Math.sqrt(1-t*t)+1)/2)}},NT.autoReverseEasing={linear:function(t){return t<.5?t*2:2-t*2}}),NT}var $q={},zpe;function cFe(){return zpe||(zpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAutoColorMode=void 0,(function(e){e.Never="Never",e.Once="Once",e.OnAddRemoveSeries="OnAddRemoveSeries",e.Always="Always"})(t.EAutoColorMode||(t.EAutoColorMode={}))})($q)),$q}var Wq={},$pe;function hn(){return $pe||($pe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESeriesType=void 0,(function(e){e.BandSeries="BandSeries",e.PolarBandSeries="PolarBandSeries",e.SplineBandSeries="SplineBandSeries",e.BubbleSeries="BubbleSeries",e.CandlestickSeries="CandlestickSeries",e.ColumnSeries="ColumnSeries",e.PolarColumnSeries="PolarColumnSeries",e.ImpulseSeries="ImpulseSeries",e.LineSeries="LineSeries",e.PolarLineSeries="PolarLineSeries",e.LineSegmentSeries="LineSegmentSeries",e.SplineLineSeries="SplineLineSeries",e.MountainSeries="MountainSeries",e.PolarMountainSeries="PolarMountainSeries",e.SplineMountainSeries="SplineMountainSeries",e.OhlcSeries="OhlcSeries",e.StackedColumnSeries="StackedColumnSeries",e.PolarStackedColumnSeries="PolarStackedColumnSeries",e.StackedMountainSeries="StackedMountainSeries",e.PolarStackedMountainSeries="PolarStackedMountainSeries",e.SmoothStackedMountainSeries="SmoothStackedMountainSeries",e.UniformContoursSeries="UniformContoursSeries",e.UniformHeatmapSeries="UniformHeatmapSeries",e.PolarUniformHeatmapSeries="PolarUniformHeatmapSeries",e.NonUniformHeatmapSeries="NonUniformHeatmapSeries",e.StackedMountainCollection="StackedMountainCollection",e.PolarStackedMountainCollection="PolarStackedMountainCollection",e.StackedColumnCollection="StackedColumnCollection",e.PolarStackedColumnCollection="PolarStackedColumnCollection",e.ScatterSeries="ScatterSeries",e.PolarScatterSeries="PolarScatterSeries",e.ErrorBarsSeries="ErrorBarsSeries",e.TextSeries="TextSeries",e.RectangleSeries="RectangleSeries",e.BoxPlotSeries="BoxPlotSeries",e.TriangleSeries="TriangleSeries",e.PolarTriangleSeries="PolarTriangleSeries",e.PolarTextSeries="PolarTextSeries",e.Custom="Custom"})(t.ESeriesType||(t.ESeriesType={}))})(Wq)),Wq}var Gq={},Wpe;function xm(){return Wpe||(Wpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EZoomState=void 0,(function(e){e.AtExtents="AtExtents",e.UserZooming="UserZooming"})(t.EZoomState||(t.EZoomState={}))})(Gq)),Gq}var FT={},Gpe;function dFe(){if(Gpe)return FT;Gpe=1;var t=FT&&FT.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(FT,"__esModule",{value:!0}),FT.BatchRenderContext=void 0;var e=Iu(),i=(function(n){t(r,n);function r(){var o=n!==null&&n.apply(this,arguments)||this;return o.doDraw=!1,o}return r.prototype.drawLayers=function(){this.doDraw&&n.prototype.drawLayers.call(this)},r.prototype.endFonts=function(o){o===void 0&&(o=!1),(this.doDraw||o)&&n.prototype.endFonts.call(this)},r})(e.WebGlRenderContext2D);return FT.BatchRenderContext=i,FT}var UN={},Ype;function Ywt(){if(Ype)return UN;Ype=1,Object.defineProperty(UN,"__esModule",{value:!0}),UN.RenderSurface=void 0;var t=Uo(),e=Iu(),i=(function(){function n(r,o,a){this.webAssemblyContext=r,this.viewportSize=o,this.canvasId=a}return n.prototype.getRenderContext=function(){return this.renderContextProperty||(this.renderContextProperty=new e.WebGlRenderContext2D(this.webAssemblyContext,this.viewportSize,this.canvasId)),this.renderContextProperty},n.prototype.invalidateElement=function(r){return t.IS_TEST_ENV||this.webAssemblyContext.TSRRequestCanvasDraw(r),!0},n.prototype.onRenderTimeElapsed=function(){this.handleDraw(),this.renderContextProperty=void 0},n})();return UN.RenderSurface=i,UN}var BT={},qpe;function fFe(){if(qpe)return BT;qpe=1;var t=BT&&BT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(BT,"__esModule",{value:!0}),BT.SolidBrushCache=void 0;var e=fo(),i=Br(),n=Ti(),r=(function(o){t(a,o);function a(s){var l=o.call(this)||this;return l.webAssemblyContext=s,l}return a.prototype.newBrush=function(s,l){return l===void 0&&(l=!1),this.brush&&s===this.color&&l===this.transparent?this.brush:(this.brush&&this.brush.delete(),this.color=s,this.transparent=l,this.brush=new this.webAssemblyContext.SCRTSolidBrush((0,n.parseColorToUIntArgb)(s),l),this.brush)},a.prototype.delete=function(){this.brush=(0,i.deleteSafe)(this.brush),this.webAssemblyContext=void 0},a})(e.DeletableEntity);return BT.SolidBrushCache=r,BT}var zN={},Yq={},Xpe;function zS(){return Xpe||(Xpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ELayoutManagerType=void 0,(function(e){e.Default="Default",e.CentralAxes="CentralAxes",e.Synchronised="Synchronised",e.Polar="Polar"})(t.ELayoutManagerType||(t.ELayoutManagerType={}))})(Yq)),Yq}var qq={},Kpe;function $d(){return Kpe||(Kpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ELayoutStrategyType=void 0,(function(e){e.LeftOuter="LeftOuter",e.RightOuter="RightOuter",e.TopOuter="TopOuter",e.BottomOuter="BottomOuter",e.LeftInner="LeftInner",e.RightInner="RightInner",e.TopInner="TopInner",e.BottomInner="BottomInner",e.LeftStacked="LeftStacked",e.RightStacked="RightStacked",e.TopStacked="TopStacked",e.BottomStacked="BottomStacked",e.AngularOuter="AngularOuter",e.AngularInner="AngularInner",e.RadialOuter="RadialOuter",e.RadialInner="RadialInner",e.Custom="Custom"})(t.ELayoutStrategyType||(t.ELayoutStrategyType={}))})(qq)),qq}var jT={},Oa={},Xq={},Zpe;function hW(){return Zpe||(Zpe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EInnerAxisPlacementCoordinateMode=void 0,(function(e){e[e.DataValue=0]="DataValue",e[e.Pixel=1]="Pixel",e[e.Relative=2]="Relative"})(t.EInnerAxisPlacementCoordinateMode||(t.EInnerAxisPlacementCoordinateMode={}))})(Xq)),Xq}var Jpe;function fs(){if(Jpe)return Oa;Jpe=1,Object.defineProperty(Oa,"__esModule",{value:!0}),Oa.testLayoutManager=Oa.getCoordinateWithCoordinateMode=Oa.getValueWithCoordinateMode=Oa.updateTopAndBottomChartLayoutState=Oa.updateLeftAndRightChartLayoutState=Oa.getVerticalAxisRequiredSize=Oa.getHorizontalAxisRequiredSize=Oa.layoutAxisPartsBottomStrategy=Oa.layoutAxisPartsTopStrategy=Oa.layoutAxisPartsRightStrategy=Oa.layoutAxisPartsLeftStrategy=Oa.layoutAxisParts=Oa.updateAxisLayoutState=void 0;var t=ci(),e=Rn(),i=hW();function n(g){var v=g.axisRenderer,y=g.axisTitleRenderer,m=g.axisLayoutState,b=g.isHorizontalAxis,S=g.axisBorder;m.clear(),m.axisSize=b?v.desiredHeight+y.desiredHeight:v.desiredWidth+y.desiredWidth,m.additionalBottomSize=S.borderBottom,m.additionalTopSize=S.borderTop,m.additionalRightSize=S.borderRight,m.additionalLeftSize=S.borderLeft}Oa.updateAxisLayoutState=n;function r(g,v){var y=g.isHorizontalAxis,m=g.viewRect,b=g.axisRenderer,S=g.axisTitleRenderer,_=g.axisBorder,C=y?m.width:b.desiredWidth,P=y?b.desiredHeight:m.height,x=S.desiredWidth,E=S.desiredHeight,A=v(C,P,x,E,m,_),R=A.axisRendererViewRect,M=A.axisTitleRendererViewRect;b.layout(R),S.layout(M)}Oa.layoutAxisParts=r;function o(g,v,y,m,b){return{axisTitleRendererViewRect:e.Rect.createWithCoords(b.left,b.top,b.left+y,b.bottom),axisRendererViewRect:e.Rect.createWithCoords(b.left+y,b.top,b.right,b.bottom)}}Oa.layoutAxisPartsLeftStrategy=o;function a(g,v,y,m,b){return{axisRendererViewRect:e.Rect.createWithCoords(b.left,b.top,b.left+g,b.bottom),axisTitleRendererViewRect:e.Rect.createWithCoords(b.left+g,b.top,b.right,b.bottom)}}Oa.layoutAxisPartsRightStrategy=a;function s(g,v,y,m,b){return{axisTitleRendererViewRect:e.Rect.createWithCoords(b.left,b.top,b.right,b.top+m),axisRendererViewRect:e.Rect.createWithCoords(b.left,b.top+m,b.right,b.bottom)}}Oa.layoutAxisPartsTopStrategy=s;function l(g,v,y,m,b){return{axisRendererViewRect:e.Rect.createWithCoords(b.left,b.top,b.right,b.top+v),axisTitleRendererViewRect:e.Rect.createWithCoords(b.left,b.top+v,b.right,b.bottom)}}Oa.layoutAxisPartsBottomStrategy=l;function u(g){return g.axisSize+g.additionalTopSize+g.additionalBottomSize}Oa.getHorizontalAxisRequiredSize=u;function c(g){return g.axisSize+g.additionalLeftSize+g.additionalRightSize}Oa.getVerticalAxisRequiredSize=c;function d(g,v,y){v===void 0&&(v=0),y===void 0&&(y=0),g.leftOuterAreaSize=g.leftOuterAreaSize<0?g.leftOuterAreaSize+v:Math.max(g.leftOuterAreaSize,v),g.rightOuterAreaSize=g.rightOuterAreaSize<0?g.rightOuterAreaSize+y:Math.max(g.rightOuterAreaSize,y)}Oa.updateLeftAndRightChartLayoutState=d;function f(g,v,y){v===void 0&&(v=0),y===void 0&&(y=0),g.topOuterAreaSize=g.topOuterAreaSize<0?g.topOuterAreaSize+v:Math.max(g.topOuterAreaSize,v),g.bottomOuterAreaSize=g.bottomOuterAreaSize<0?g.bottomOuterAreaSize+y:Math.max(g.bottomOuterAreaSize,y)}Oa.updateTopAndBottomChartLayoutState=f;var h=function(g,v,y){switch(y){case i.EInnerAxisPlacementCoordinateMode.Pixel:return v.getDataValue(g);case i.EInnerAxisPlacementCoordinateMode.DataValue:return g;case i.EInnerAxisPlacementCoordinateMode.Relative:return(v.visibleMax-v.visibleMin)*g+v.visibleMin;default:throw new Error("CoordinateMode ".concat(y," is not supported"))}};Oa.getValueWithCoordinateMode=h;var p=function(g,v,y){switch(t.Guard.notNull(y,"coordinateMode"),t.Guard.notNull(v,"calculator"),y){case i.EInnerAxisPlacementCoordinateMode.Pixel:return g;case i.EInnerAxisPlacementCoordinateMode.DataValue:return v.getCoordinate(g);case i.EInnerAxisPlacementCoordinateMode.Relative:return g*v.viewportDimension;default:throw new Error("CoordinateMode ".concat(y," is not supported"))}};return Oa.getCoordinateWithCoordinateMode=p,Oa.testLayoutManager={updateAxisLayoutState:n,layoutAxisPartsLeftStrategy:o,layoutAxisPartsRightStrategy:a,layoutAxisPartsTopStrategy:s,layoutAxisPartsBottomStrategy:l},Oa}var VT={},$N={},Qpe;function eR(){if(Qpe)return $N;Qpe=1,Object.defineProperty($N,"__esModule",{value:!0}),$N.BaseAxisLayoutStrategy=void 0;var t=Rn(),e=fs(),i=(function(){function o(){this.isStacked=!1}return o.prototype.toJSON=function(){return{type:this.type}},o.prototype.updateAxisLayoutState=function(a){(0,e.updateAxisLayoutState)(a)},o.prototype.updateLeftAndRightChartLayoutState=function(a,s,l){(0,e.updateLeftAndRightChartLayoutState)(a,s,l)},o.prototype.updateTopAndBottomChartLayoutState=function(a,s,l){(0,e.updateTopAndBottomChartLayoutState)(a,s,l)},o.prototype.layoutAxesFromBottomToTop=function(a,s,l,u,c){var d=this,f=u;c.forEach(function(h){var p=h.axisLayoutState,g=p.axisSize,v=p.additionalTopSize,y=p.additionalBottomSize,m=f-g-y-v;h.viewRect=t.Rect.createWithCoords(a,m+v,l,f-y),f=m,(0,e.layoutAxisParts)(h,d.layoutAxisPartsStrategy)})},o.prototype.layoutAxesFromTopToBottom=function(a,s,l,u,c){var d=this,f=s;c.forEach(function(h){var p=h.axisLayoutState,g=p.axisSize,v=p.additionalTopSize,y=p.additionalBottomSize,m=f+g+y+v;h.viewRect=t.Rect.createWithCoords(a,f+v,l,m-y),f=m,(0,e.layoutAxisParts)(h,d.layoutAxisPartsStrategy)})},o.prototype.layoutAxesFromLeftToRight=function(a,s,l,u,c){var d=this,f=a;c.forEach(function(h){var p=h.axisLayoutState,g=p.axisSize,v=p.additionalLeftSize,y=p.additionalRightSize,m=f+g+v+y;h.viewRect=t.Rect.createWithCoords(f+v,s,m-y,u),f=m,(0,e.layoutAxisParts)(h,d.layoutAxisPartsStrategy)})},o.prototype.layoutAxesFromRightToLeft=function(a,s,l,u,c){var d=this,f=l;c.forEach(function(h){var p=h.axisLayoutState,g=p.axisSize,v=p.additionalLeftSize,y=p.additionalRightSize,m=f-g-v-y;h.viewRect=t.Rect.createWithCoords(m+v,s,f-y,u),f=m,(0,e.layoutAxisParts)(h,d.layoutAxisPartsStrategy)})},o.prototype.calculateTotalAxisHeight=function(a,s){return n(a.stackedAxisLength,s)+a.axisLayoutState.additionalBottomSize+a.axisLayoutState.additionalTopSize},o.prototype.calculateTotalAxisWidth=function(a,s){return n(a.stackedAxisLength,s)+a.axisLayoutState.additionalRightSize+a.axisLayoutState.additionalLeftSize},o})();$N.BaseAxisLayoutStrategy=i;var n=function(o,a){if(typeof o=="number"){if(o<0)throw new Error("stackedAxisLength must be a positive value!");return o}if(o.includes("%"))return r(o,a);var s=parseFloat(o);if(!isNaN(s))return s;throw new Error("stackedAxisLength must be a number or a percentage")},r=function(o,a){var s=parseFloat(o);if(s<0||s>100)throw new Error("stackedAxisLength percentage must be from 0 to 100");return Math.round(a*s/10)/10};return $N}var Kq={},ege;function hFe(){return ege||(ege=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.AXIS_POSITION_COORDINATE="AXIS_POSITION_COORDINATE",e.COORDINATE_MODE="COORDINATE_MODE",e.VERTICAL_AXIS_ID="VERTICAL_AXIS_ID"})(t.PROPERTY||(t.PROPERTY={}))})(Kq)),Kq}var tge;function YV(){if(tge)return VT;tge=1;var t=VT&&VT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(VT,"__esModule",{value:!0}),VT.BaseCenteredAxisLayoutStrategy=void 0;var e=eR(),i=hFe(),n=hW(),r=(function(o){t(a,o);function a(s){var l=this,u,c,d;return l=o.call(this)||this,l.coordinateModeProperty=n.EInnerAxisPlacementCoordinateMode.DataValue,l.orthogonalAxisIdProperty=(u=s==null?void 0:s.orthogonalAxisId)!==null&&u!==void 0?u:l.orthogonalAxisIdProperty,l.coordinateModeProperty=(c=s==null?void 0:s.coordinateMode)!==null&&c!==void 0?c:l.coordinateModeProperty,l.axisPositionProperty=(d=s==null?void 0:s.axisPosition)!==null&&d!==void 0?d:l.axisPositionProperty,l}return Object.defineProperty(a.prototype,"orthogonalAxisId",{get:function(){return this.orthogonalAxisIdProperty},set:function(s){this.orthogonalAxisId!==s&&(this.orthogonalAxisIdProperty=s,this.notifyPropertyChanged(i.PROPERTY.VERTICAL_AXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"coordinateMode",{get:function(){return this.coordinateModeProperty},set:function(s){this.coordinateModeProperty!==s&&(this.coordinateModeProperty=s,this.notifyPropertyChanged(i.PROPERTY.COORDINATE_MODE))},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"axisPosition",{get:function(){return this.axisPositionProperty},set:function(s){this.axisPositionProperty!==s&&(this.axisPositionProperty=s,this.notifyPropertyChanged(i.PROPERTY.AXIS_POSITION_COORDINATE))},enumerable:!1,configurable:!0}),a.prototype.toJSON=function(){var s={axisPosition:this.axisPosition,coordinateMode:this.coordinateMode,orthogonalAxisId:this.orthogonalAxisId};return{type:this.type,options:s}},a.prototype.notifyPropertyChanged=function(s){var l;!((l=this.sciChartSurface)===null||l===void 0)&&l.invalidateElement&&this.sciChartSurface.invalidateElement()},a})(e.BaseAxisLayoutStrategy);return VT.BaseCenteredAxisLayoutStrategy=r,VT}var rge;function pW(){if(rge)return jT;rge=1;var t=jT&&jT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(jT,"__esModule",{value:!0}),jT.BottomAlignedInnerAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=YV(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.ELayoutStrategyType.BottomInner,l.layoutAxisPartsStrategy=i.layoutAxisPartsTopStrategy,l}return a.prototype.measureAxes=function(s,l,u){var c=this;this.sciChartSurface=s;var d=0;return u.forEach(function(f){f.measure(),c.updateAxisLayoutState(f),d+=(0,i.getHorizontalAxisRequiredSize)(f.axisLayoutState)}),d},a.prototype.updateAreaSize=function(s,l){s.bottomInnerAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){var f;if(d.forEach(function(m){m.axisLength=void 0,m.offset=0}),d.length!==0){var h=c;if(this.axisPosition!==void 0){var p=(f=this.sciChartSurface.getYAxisById(this.orthogonalAxisId))!==null&&f!==void 0?f:this.sciChartSurface.getDefaultYAxis();if(!p||p.isHorizontalAxis)throw new Error("orthogonalAxisId should be a valid id of vertical axis on the surface!");var g=p.getCurrentCoordinateCalculator(),v=(0,i.getCoordinateWithCoordinateMode)(this.axisPosition,g,this.coordinateMode),y=p.viewRect.top;h=v+y}this.layoutAxesFromBottomToTop(s,l,u,h,d)}},a})(n.BaseCenteredAxisLayoutStrategy);return jT.BottomAlignedInnerAxisLayoutStrategy=r,jT}var HT={},ige;function gW(){if(ige)return HT;ige=1;var t=HT&&HT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(HT,"__esModule",{value:!0}),HT.BottomAlignedOuterAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=eR(),r=(function(o){t(a,o);function a(){var s=o.call(this)||this;return s.type=e.ELayoutStrategyType.BottomOuter,s.layoutAxisPartsStrategy=i.layoutAxisPartsBottomStrategy,s}return a.prototype.measureAxes=function(s,l,u){var c=this,d,f,h=(f=(d=s.adjustedPadding)===null||d===void 0?void 0:d.bottom)!==null&&f!==void 0?f:0;return h+=s.bottomViewportBorder+s.bottomCanvasBorder,u.forEach(function(p){p.measure(),c.updateAxisLayoutState(p),h+=(0,i.getHorizontalAxisRequiredSize)(p.axisLayoutState),c.updateLeftAndRightChartLayoutState(l,p.axisLayoutState.additionalLeftSize,p.axisLayoutState.additionalRightSize)}),h},a.prototype.updateAreaSize=function(s,l){s.bottomOuterAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){d.forEach(function(f){f.axisLength=void 0,f.offset=0}),this.layoutAxesFromTopToBottom(s,l,u,c,d)},a})(n.BaseAxisLayoutStrategy);return HT.BottomAlignedOuterAxisLayoutStrategy=r,HT}var WN={},nge;function pFe(){if(nge)return WN;nge=1,Object.defineProperty(WN,"__esModule",{value:!0}),WN.ChartLayoutState=void 0;var t=(function(){function e(){this.leftInnerAreaSize=e.DEFAULT_SIZE,this.topInnerAreaSize=e.DEFAULT_SIZE,this.bottomInnerAreaSize=e.DEFAULT_SIZE,this.rightInnerAreaSize=e.DEFAULT_SIZE,this.leftOuterAreaSize=e.DEFAULT_SIZE,this.topOuterAreaSize=e.DEFAULT_SIZE,this.bottomOuterAreaSize=e.DEFAULT_SIZE,this.rightOuterAreaSize=e.DEFAULT_SIZE}return e.prototype.clear=function(){this.leftInnerAreaSize=e.DEFAULT_SIZE,this.topInnerAreaSize=e.DEFAULT_SIZE,this.bottomInnerAreaSize=e.DEFAULT_SIZE,this.rightInnerAreaSize=e.DEFAULT_SIZE,this.leftOuterAreaSize=e.DEFAULT_SIZE,this.topOuterAreaSize=e.DEFAULT_SIZE,this.bottomOuterAreaSize=e.DEFAULT_SIZE,this.rightOuterAreaSize=e.DEFAULT_SIZE},e.DEFAULT_SIZE=0,e})();return WN.ChartLayoutState=t,WN}var GN={},oge;function qwt(){if(oge)return GN;oge=1,Object.defineProperty(GN,"__esModule",{value:!0}),GN.LayoutStrategyAxes=void 0;var t=(function(){function e(){this.topInnerAxes=[],this.bottomInnerAxes=[],this.leftInnerAxes=[],this.rightInnerAxes=[],this.topOuterAxes=[],this.bottomOuterAxes=[],this.leftOuterAxes=[],this.rightOuterAxes=[]}return e.prototype.clear=function(){this.topInnerAxes=[],this.bottomInnerAxes=[],this.leftInnerAxes=[],this.rightInnerAxes=[],this.topOuterAxes=[],this.bottomOuterAxes=[],this.leftOuterAxes=[],this.rightOuterAxes=[]},e})();return GN.LayoutStrategyAxes=t,GN}var UT={},age;function vW(){if(age)return UT;age=1;var t=UT&&UT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(UT,"__esModule",{value:!0}),UT.LeftAlignedInnerAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=YV(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.ELayoutStrategyType.LeftInner,l.layoutAxisPartsStrategy=i.layoutAxisPartsRightStrategy,l}return a.prototype.measureAxes=function(s,l,u){var c=this;this.sciChartSurface=s;var d=0;return u.forEach(function(f){f.measure(),c.updateAxisLayoutState(f),d+=(0,i.getVerticalAxisRequiredSize)(f.axisLayoutState)}),d},a.prototype.updateAreaSize=function(s,l){s.leftInnerAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){var f;if(d.forEach(function(m){m.axisLength=void 0,m.offset=0}),d.length!==0){var h=s;if(this.axisPosition!==void 0){var p=(f=this.sciChartSurface.getXAxisById(this.orthogonalAxisId))!==null&&f!==void 0?f:this.sciChartSurface.getDefaultXAxis();if(!p||!p.isHorizontalAxis)throw new Error("orthogonalAxisId should be a valid id of horizontal axis on the surface!");var g=p.getCurrentCoordinateCalculator(),v=(0,i.getCoordinateWithCoordinateMode)(this.axisPosition,g,this.coordinateMode),y=p.parentSurface.seriesViewRect.left;h=v+y}this.layoutAxesFromLeftToRight(h,l,u,c,d)}},a})(n.BaseCenteredAxisLayoutStrategy);return UT.LeftAlignedInnerAxisLayoutStrategy=r,UT}var zT={},sge;function yW(){if(sge)return zT;sge=1;var t=zT&&zT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(zT,"__esModule",{value:!0}),zT.LeftAlignedOuterAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=eR(),r=(function(o){t(a,o);function a(){var s=o.call(this)||this;return s.type=e.ELayoutStrategyType.LeftOuter,s.layoutAxisPartsStrategy=i.layoutAxisPartsLeftStrategy,s}return a.prototype.measureAxes=function(s,l,u){var c=this,d,f,h=(f=(d=s.adjustedPadding)===null||d===void 0?void 0:d.left)!==null&&f!==void 0?f:0;return h+=s.leftViewportBorder+s.leftCanvasBorder,u.forEach(function(p){p.measure(),c.updateAxisLayoutState(p),h+=(0,i.getVerticalAxisRequiredSize)(p.axisLayoutState),c.updateTopAndBottomChartLayoutState(l,p.axisLayoutState.additionalTopSize,p.axisLayoutState.additionalBottomSize)}),h},a.prototype.updateAreaSize=function(s,l){s.leftOuterAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){d.forEach(function(f){f.axisLength=void 0,f.offset=0}),this.layoutAxesFromRightToLeft(s,l,u,c,d)},a})(n.BaseAxisLayoutStrategy);return zT.LeftAlignedOuterAxisLayoutStrategy=r,zT}var $T={},lge;function mW(){if(lge)return $T;lge=1;var t=$T&&$T.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty($T,"__esModule",{value:!0}),$T.RightAlignedInnerAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=YV(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.ELayoutStrategyType.RightInner,l.layoutAxisPartsStrategy=i.layoutAxisPartsLeftStrategy,l}return a.prototype.measureAxes=function(s,l,u){var c=this;this.sciChartSurface=s;var d=0;return u.forEach(function(f){f.measure(),c.updateAxisLayoutState(f),d+=(0,i.getVerticalAxisRequiredSize)(f.axisLayoutState)}),d},a.prototype.updateAreaSize=function(s,l){s.rightInnerAreaSize=Math.max(s.rightInnerAreaSize,l)},a.prototype.layoutAxes=function(s,l,u,c,d){var f;if(d.forEach(function(m){m.axisLength=void 0,m.offset=0}),d.length!==0){var h=u;if(this.axisPosition!==void 0){var p=(f=this.sciChartSurface.getXAxisById(this.orthogonalAxisId))!==null&&f!==void 0?f:this.sciChartSurface.getDefaultXAxis();if(!p||!p.isHorizontalAxis)throw new Error("orthogonalAxisId should be a valid id of horizontal axis on the surface!");var g=p.getCurrentCoordinateCalculator(),v=(0,i.getCoordinateWithCoordinateMode)(this.axisPosition,g,this.coordinateMode),y=p.parentSurface.seriesViewRect.left;h=v+y}this.layoutAxesFromRightToLeft(s,l,h,c,d)}},a})(n.BaseCenteredAxisLayoutStrategy);return $T.RightAlignedInnerAxisLayoutStrategy=r,$T}var WT={},uge;function bW(){if(uge)return WT;uge=1;var t=WT&&WT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(WT,"__esModule",{value:!0}),WT.RightAlignedOuterAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=eR(),r=(function(o){t(a,o);function a(){var s=o.call(this)||this;return s.type=e.ELayoutStrategyType.RightOuter,s.layoutAxisPartsStrategy=i.layoutAxisPartsRightStrategy,s}return a.prototype.measureAxes=function(s,l,u){var c=this,d,f,h=(f=(d=s.adjustedPadding)===null||d===void 0?void 0:d.right)!==null&&f!==void 0?f:0;return h+=s.rightViewportBorder+s.rightCanvasBorder,u.forEach(function(p){p.measure(),c.updateAxisLayoutState(p),h+=(0,i.getVerticalAxisRequiredSize)(p.axisLayoutState),c.updateTopAndBottomChartLayoutState(l,p.axisLayoutState.additionalTopSize,p.axisLayoutState.additionalBottomSize)}),h},a.prototype.updateAreaSize=function(s,l){s.rightOuterAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){d.forEach(function(f){f.axisLength=void 0,f.offset=0}),this.layoutAxesFromLeftToRight(s,l,u,c,d)},a})(n.BaseAxisLayoutStrategy);return WT.RightAlignedOuterAxisLayoutStrategy=r,WT}var GT={},cge;function SW(){if(cge)return GT;cge=1;var t=GT&&GT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(GT,"__esModule",{value:!0}),GT.TopAlignedInnerAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=YV(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.ELayoutStrategyType.TopInner,l.layoutAxisPartsStrategy=i.layoutAxisPartsBottomStrategy,l}return a.prototype.measureAxes=function(s,l,u){var c=this;this.sciChartSurface=s;var d=0;return u.forEach(function(f){f.measure(),c.updateAxisLayoutState(f),d+=(0,i.getHorizontalAxisRequiredSize)(f.axisLayoutState)}),d},a.prototype.updateAreaSize=function(s,l){s.topInnerAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){var f;if(d.forEach(function(m){m.axisLength=void 0,m.offset=0}),d.length!==0){var h=l;if(this.axisPosition!==void 0){var p=(f=this.sciChartSurface.getYAxisById(this.orthogonalAxisId))!==null&&f!==void 0?f:this.sciChartSurface.getDefaultYAxis();if(!p||p.isHorizontalAxis)throw new Error("orthogonalAxisId should be a valid id of vertical axis on the surface!");var g=p.getCurrentCoordinateCalculator(),v=(0,i.getCoordinateWithCoordinateMode)(this.axisPosition,g,this.coordinateMode),y=p.viewRect.top;h=v+y}this.layoutAxesFromTopToBottom(s,h,u,c,d)}},a})(n.BaseCenteredAxisLayoutStrategy);return GT.TopAlignedInnerAxisLayoutStrategy=r,GT}var YT={},dge;function _W(){if(dge)return YT;dge=1;var t=YT&&YT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(YT,"__esModule",{value:!0}),YT.TopAlignedOuterAxisLayoutStrategy=void 0;var e=$d(),i=fs(),n=eR(),r=(function(o){t(a,o);function a(){var s=o.call(this)||this;return s.type=e.ELayoutStrategyType.TopOuter,s.layoutAxisPartsStrategy=i.layoutAxisPartsTopStrategy,s}return a.prototype.measureAxes=function(s,l,u){var c=this,d,f,h=(f=(d=s.adjustedPadding)===null||d===void 0?void 0:d.top)!==null&&f!==void 0?f:0;return h+=s.topViewportBorder+s.topCanvasBorder,u.forEach(function(p){p.measure(),c.updateAxisLayoutState(p),h+=(0,i.getHorizontalAxisRequiredSize)(p.axisLayoutState),c.updateLeftAndRightChartLayoutState(l,p.axisLayoutState.additionalLeftSize,p.axisLayoutState.additionalRightSize)}),h},a.prototype.updateAreaSize=function(s,l){s.topOuterAreaSize=l},a.prototype.layoutAxes=function(s,l,u,c,d){d.forEach(function(f){f.axisLength=void 0,f.offset=0}),this.layoutAxesFromBottomToTop(s,l,u,c,d)},a})(n.BaseAxisLayoutStrategy);return YT.TopAlignedOuterAxisLayoutStrategy=r,YT}var fge;function JP(){if(fge)return zN;fge=1,Object.defineProperty(zN,"__esModule",{value:!0}),zN.LayoutManager=void 0;var t=mo(),e=Rn(),i=od(),n=ga(),r=zS(),o=$d(),a=pW(),s=gW(),l=pFe(),u=qwt(),c=vW(),d=yW(),f=mW(),h=bW(),p=SW(),g=_W(),v=10,y=(function(){function m(b){this.type=r.ELayoutManagerType.Default,this.leftOuterAxesLayoutStrategyProperty=new d.LeftAlignedOuterAxisLayoutStrategy,this.rightOuterAxesLayoutStrategyProperty=new h.RightAlignedOuterAxisLayoutStrategy,this.topOuterAxesLayoutStrategyProperty=new g.TopAlignedOuterAxisLayoutStrategy,this.bottomOuterAxesLayoutStrategyProperty=new s.BottomAlignedOuterAxisLayoutStrategy,this.leftInnerAxesLayoutStrategy=new c.LeftAlignedInnerAxisLayoutStrategy,this.rightInnerAxesLayoutStrategy=new f.RightAlignedInnerAxisLayoutStrategy,this.topInnerAxesLayoutStrategy=new p.TopAlignedInnerAxisLayoutStrategy,this.bottomInnerAxesLayoutStrategy=new a.BottomAlignedInnerAxisLayoutStrategy,this.chartLayoutState=new l.ChartLayoutState,this.axesGroupedByLayoutStrategy=new u.LayoutStrategyAxes,this.leftOuterAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.LeftOuter,this.leftOuterAxesLayoutStrategy),this.rightOuterAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.RightOuter,this.rightOuterAxesLayoutStrategy),this.topOuterAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.TopOuter,this.topOuterAxesLayoutStrategy),this.bottomOuterAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.BottomOuter,this.bottomOuterAxesLayoutStrategy),this.leftInnerAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.LeftInner,this.leftInnerAxesLayoutStrategy),this.rightInnerAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.RightInner,this.rightInnerAxesLayoutStrategy),this.topInnerAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.TopInner,this.topInnerAxesLayoutStrategy),this.bottomInnerAxesLayoutStrategy=this.createStrategy(b==null?void 0:b.BottomInner,this.bottomInnerAxesLayoutStrategy)}return Object.defineProperty(m.prototype,"leftOuterAxesLayoutStrategy",{get:function(){return this.leftOuterAxesLayoutStrategyProperty},set:function(b){var S,_=this.leftOuterAxesLayoutStrategyProperty;_!==b&&(this.leftOuterAxesLayoutStrategyProperty=b,_.isStacked&&!b.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.leftOuterAxes)),(S=this.sciChartSurface)===null||S===void 0||S.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"rightOuterAxesLayoutStrategy",{get:function(){return this.rightOuterAxesLayoutStrategyProperty},set:function(b){var S,_=this.rightOuterAxesLayoutStrategyProperty;_!==b&&(this.rightOuterAxesLayoutStrategyProperty=b,_.isStacked&&!b.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.rightOuterAxes)),(S=this.sciChartSurface)===null||S===void 0||S.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"topOuterAxesLayoutStrategy",{get:function(){return this.topOuterAxesLayoutStrategyProperty},set:function(b){var S,_=this.topOuterAxesLayoutStrategyProperty;_!==b&&(this.topOuterAxesLayoutStrategyProperty=b,_.isStacked&&!b.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.topOuterAxes)),(S=this.sciChartSurface)===null||S===void 0||S.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"bottomOuterAxesLayoutStrategy",{get:function(){return this.bottomOuterAxesLayoutStrategyProperty},set:function(b){var S,_=this.bottomOuterAxesLayoutStrategyProperty;_!==b&&(this.bottomOuterAxesLayoutStrategyProperty=b,_.isStacked&&!b.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.bottomOuterAxes)),(S=this.sciChartSurface)===null||S===void 0||S.invalidateElement())},enumerable:!1,configurable:!0}),m.prototype.getAxisLayoutStrategy=function(b){var S=b.axisAlignment,_=b.isInnerAxis;switch(S){case i.EAxisAlignment.Left:return _?this.leftInnerAxesLayoutStrategy:this.leftOuterAxesLayoutStrategy;case i.EAxisAlignment.Right:return _?this.rightInnerAxesLayoutStrategy:this.rightOuterAxesLayoutStrategy;case i.EAxisAlignment.Top:return _?this.topInnerAxesLayoutStrategy:this.topOuterAxesLayoutStrategy;case i.EAxisAlignment.Bottom:return _?this.bottomInnerAxesLayoutStrategy:this.bottomOuterAxesLayoutStrategy;default:return(0,i.handleInvalidAxisAlignment)(S)}},m.prototype.layoutChart=function(b,S){var _,C,P,x;this.groupAxesByLayoutStrategy();var E=(_=S==null?void 0:S.right)!==null&&_!==void 0?_:0,A=(C=S==null?void 0:S.left)!==null&&C!==void 0?C:0,R=(P=S==null?void 0:S.top)!==null&&P!==void 0?P:0,M=(x=S==null?void 0:S.bottom)!==null&&x!==void 0?x:0,D=b.width-A-E,F=b.height-R-M;try{this.measureTopOuterAxes(),this.measureBottomOuterAxes(),this.measureLeftOuterAxes(),this.measureRightOuterAxes(),this.measureTopInnerAxes(),this.measureBottomInnerAxes(),this.measureLeftInnerAxes(),this.measureRightInnerAxes();var I=D-this.chartLayoutState.leftOuterAreaSize-this.chartLayoutState.rightOuterAreaSize,V=F-this.chartLayoutState.topOuterAreaSize-this.chartLayoutState.bottomOuterAreaSize,z=A,G=z+this.chartLayoutState.leftOuterAreaSize,H=G+(I<v?v:I),U=H+this.chartLayoutState.rightOuterAreaSize,k=R,X=k+this.chartLayoutState.topOuterAreaSize,W=X+(V<v?v:V),Y=W+this.chartLayoutState.bottomOuterAreaSize;this.sciChartSurface.drawSeriesBehindAxis?this.layoutChartCenter(z,k,U,Y):this.layoutChartCenter(G,X,H,W),this.leftOuterAxesLayoutStrategy.layoutAxes(z,X,G-this.sciChartSurface.leftViewportBorder,W,this.axesGroupedByLayoutStrategy.leftOuterAxes),this.rightOuterAxesLayoutStrategy.layoutAxes(H+this.sciChartSurface.rightViewportBorder,X,U,W,this.axesGroupedByLayoutStrategy.rightOuterAxes),this.topOuterAxesLayoutStrategy.layoutAxes(G,k,H,X-this.sciChartSurface.topViewportBorder,this.axesGroupedByLayoutStrategy.topOuterAxes),this.bottomOuterAxesLayoutStrategy.layoutAxes(G,W+this.sciChartSurface.bottomViewportBorder,H,Y,this.axesGroupedByLayoutStrategy.bottomOuterAxes);var te=G+this.chartLayoutState.leftInnerAreaSize,oe=H-this.chartLayoutState.rightInnerAreaSize,de=X+this.chartLayoutState.topInnerAreaSize,ge=W-this.chartLayoutState.bottomInnerAreaSize;return this.leftInnerAxesLayoutStrategy.layoutAxes(G,X,te,W,this.axesGroupedByLayoutStrategy.leftInnerAxes),this.rightInnerAxesLayoutStrategy.layoutAxes(oe,X,H,W,this.axesGroupedByLayoutStrategy.rightInnerAxes),this.topInnerAxesLayoutStrategy.layoutAxes(G,X,H,de,this.axesGroupedByLayoutStrategy.topInnerAxes),this.bottomInnerAxesLayoutStrategy.layoutAxes(G,ge,H,W,this.axesGroupedByLayoutStrategy.bottomInnerAxes),this.sciChartSurface.seriesViewRect}finally{this.chartLayoutState.clear()}},m.prototype.toJSON=function(){var b={BottomInner:this.bottomInnerAxesLayoutStrategy.toJSON(),BottomOuter:this.bottomOuterAxesLayoutStrategy.toJSON(),LeftInner:this.leftInnerAxesLayoutStrategy.toJSON(),LeftOuter:this.leftOuterAxesLayoutStrategy.toJSON(),RightInner:this.rightInnerAxesLayoutStrategy.toJSON(),RightOuter:this.rightOuterAxesLayoutStrategy.toJSON(),TopInner:this.topInnerAxesLayoutStrategy.toJSON(),TopOuter:this.topOuterAxesLayoutStrategy.toJSON()};return{type:this.type,options:b}},m.prototype.measureLeftOuterAxes=function(){var b=this.leftOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.leftOuterAxes);this.leftOuterAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureRightOuterAxes=function(){var b=this.rightOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.rightOuterAxes);this.rightOuterAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureTopOuterAxes=function(){var b=this.topOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.topOuterAxes);this.topOuterAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureBottomOuterAxes=function(){var b=this.bottomOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.bottomOuterAxes);this.bottomOuterAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureLeftInnerAxes=function(){var b=this.leftInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.leftInnerAxes);this.leftInnerAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureRightInnerAxes=function(){var b=this.rightInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.rightInnerAxes);this.rightInnerAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureTopInnerAxes=function(){var b=this.topInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.topInnerAxes);this.topInnerAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.measureBottomInnerAxes=function(){var b=this.bottomInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.bottomInnerAxes);this.bottomInnerAxesLayoutStrategy.updateAreaSize(this.chartLayoutState,b)},m.prototype.groupAxesByLayoutStrategy=function(){this.axesGroupedByLayoutStrategy.clear();var b=this.axesGroupedByLayoutStrategy,S=b.topInnerAxes,_=b.bottomInnerAxes,C=b.leftInnerAxes,P=b.rightInnerAxes,x=b.topOuterAxes,E=b.bottomOuterAxes,A=b.leftOuterAxes,R=b.rightOuterAxes,M=function(D){D.forEach(function(F){var I=F.axisAlignment,V=F.isInnerAxis;if(F.isVisible,V)switch(I){case i.EAxisAlignment.Top:S.push(F);break;case i.EAxisAlignment.Bottom:_.push(F);break;case i.EAxisAlignment.Left:C.push(F);break;case i.EAxisAlignment.Right:P.push(F);break}else switch(I){case i.EAxisAlignment.Top:x.push(F);break;case i.EAxisAlignment.Bottom:E.push(F);break;case i.EAxisAlignment.Left:A.push(F);break;case i.EAxisAlignment.Right:R.push(F);break}})};M(this.sciChartSurface.xAxes.asArray()),M(this.sciChartSurface.yAxes.asArray())},m.prototype.layoutChartCenter=function(b,S,_,C){this.setSeriesViewRect(b,S,_,C),this.sciChartSurface.annotationUnderlaySurfaceViewRect=e.Rect.createWithCoords(b,S,_,C),this.sciChartSurface.annotationOverlaySurfaceViewRect=e.Rect.createWithCoords(b,S,_,C),this.sciChartSurface.chartModifierSurfaceViewRect=e.Rect.createWithCoords(b,S,_,C)},m.prototype.setSeriesViewRect=function(b,S,_,C){var P=this.sciChartSurface.seriesViewRect,x=e.Rect.createWithCoords(b,S,_,C);(!P||!e.Rect.isEqual(P,x))&&this.sciChartSurface.setSeriesViewRect(x)},m.prototype.createStrategy=function(b,S){return b&&b.type!==S.type?"measureAxes"in b?b:b.type===o.ELayoutStrategyType.Custom?(0,t.createType)(n.EBaseType.LayoutStrategy,b.customType,void 0,b.options):(0,t.createType)(n.EBaseType.LayoutStrategy,b.type,void 0,b.options):S},m.prototype.resetAxes=function(b){b.length>0&&(b[0].isPrimaryAxis=!0)},m})();return zN.LayoutManager=y,zN}var qT={},Zq={},hge;function tR(){return hge||(hge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAutoRange=void 0,(function(e){e.Once="Once",e.Always="Always",e.Never="Never"})(t.EAutoRange||(t.EAutoRange={}))})(Zq)),Zq}var YN={},pge;function QP(){if(pge)return YN;pge=1,Object.defineProperty(YN,"__esModule",{value:!0}),YN.RenderPassData=void 0;var t=(function(){function e(i,n,r,o,a,s){this.indexRange=i,this.getxCoordinateCalculator=n,this.getyCoordinateCalculator=r,this.isVerticalChart=o,this.pointSeries=a,this.resamplingHash=s}return Object.defineProperty(e.prototype,"xCoordinateCalculator",{get:function(){return this.getxCoordinateCalculator()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"yCoordinateCalculator",{get:function(){return this.getyCoordinateCalculator()},enumerable:!1,configurable:!0}),e})();return YN.RenderPassData=t,YN}var qN={},XN={},KN={},ZN={},gge;function wre(){if(gge)return ZN;gge=1,Object.defineProperty(ZN,"__esModule",{value:!0}),ZN.NumberUtil=void 0;var t=(function(){function e(){}return e.constrain=function(i,n,r){return Math.max(Math.min(i,r),n)},e})();return ZN.NumberUtil=t,ZN}var vge;function cP(){return vge||(vge=1,(function(t){var e=KN&&KN.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.SeriesAnimationFiniteStateMachine=t.AnimationFiniteStateMachine=t.EAnimationStateTransition=t.EAnimationState=void 0;var i=wre(),n;(function(s){s.InitialState="InitialState",s.Delayed="Delayed",s.Running="Running",s.Completed="Completed"})(n=t.EAnimationState||(t.EAnimationState={}));var r;(function(s){s.NoChange="NoChange",s.InitialState_Delayed="InitialState_Delayed",s.InitialState_Running="InitialState_Running",s.InitialState_Completed="InitialState_Completed",s.Delayed_Running="Delayed_Running",s.Running_Completed="Running_Completed"})(r=t.EAnimationStateTransition||(t.EAnimationStateTransition={}));var o=(function(){function s(l){this.stateProperty=n.InitialState,this.animationProperty=l}return Object.defineProperty(s.prototype,"state",{get:function(){return this.stateProperty},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"animation",{get:function(){return this.animationProperty},enumerable:!1,configurable:!0}),s.prototype.is=function(l){return l.includes(this.stateProperty)},s.prototype.update=function(l){return this.stateProperty===n.InitialState?this.animationProperty.delay?(this.toDelayed(),r.InitialState_Delayed):this.animationProperty.duration?(this.toRunning(),r.InitialState_Running):(this.toCompleted(),r.InitialState_Completed):this.stateProperty===n.Delayed?this.updateDelayedState(l):this.stateProperty===n.Running?this.updateRunningState(l):r.NoChange},Object.defineProperty(s.prototype,"animationProgress",{get:function(){if(this.stateProperty===n.Running){var l=i.NumberUtil.constrain(this.animationElapsed/this.animationProperty.duration,0,1);return this.animationProperty.ease(l)}else return this.stateProperty===n.Completed?1:0},enumerable:!1,configurable:!0}),s.prototype.toCompleted=function(){this.stateProperty=n.Completed},s.prototype.validate=function(l,u){if(!l.includes(this.stateProperty))throw Error("Transition from state ".concat(this.stateProperty," to ").concat(u," if forbidden"))},s.prototype.toDelayed=function(){this.animationDelayStartTimestamp=Date.now(),this.animationDelayElapsed=0,this.stateProperty=n.Delayed},s.prototype.toRunning=function(){this.animationStartTimestamp=Date.now(),this.animationElapsed=0,this.stateProperty=n.Running},s.prototype.updateDelayedState=function(l){return this.animationDelayElapsed+=l,this.animationDelayElapsed>=this.animationProperty.delay?(this.toRunning(),r.Delayed_Running):r.NoChange},s.prototype.updateRunningState=function(l){return this.animationElapsed+=l,this.animationElapsed>=this.animationProperty.duration?(this.toCompleted(),r.Running_Completed):r.NoChange},s})();t.AnimationFiniteStateMachine=o;var a=(function(s){e(l,s);function l(u,c){var d=s.call(this,u)||this;return c&&(d.initialStylesProperty=u.getSeriesStyle(c)),d}return Object.defineProperty(l.prototype,"animation",{get:function(){return this.animationProperty},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"initialStyles",{get:function(){return this.initialStylesProperty},enumerable:!1,configurable:!0}),l})(o);t.SeriesAnimationFiniteStateMachine=a})(KN)),KN}var JN={},F0={},yge;function Ij(){if(yge)return F0;yge=1,Object.defineProperty(F0,"__esModule",{value:!0}),F0.logToBase=F0.fillNoisySinewave=F0.getNoisySinewave=void 0;var t=function(n,r,o,a,s){for(var l=[],u=[],c=o/r,d=2*Math.PI*c,f=0;f<n;f++){var h=f*r/(n-1);l.push(h);var p=a*Math.sin(h*d),g=(Math.random()-.5)*s;u.push(p+g)}return[l,u]};F0.getNoisySinewave=t;var e=function(n,r,o,a,s,l){var u=o/r,c=2*Math.PI*u,d=l.getNativeXValues(),f=l.getNativeYValues();d.reserve(n),f.reserve(n);for(var h=0;h<n;h++){var p=h*r/(n-1),g=a*Math.sin(p*c),v=(Math.random()-.5)*s;d.push_back(p),f.push_back(g+v)}};F0.fillNoisySinewave=e;var i=function(n,r){return r===10?Math.log10(n):Math.log(n)/(r?Math.log(r):1)};return F0.logToBase=i,F0}var mge;function di(){if(mge)return JN;mge=1,Object.defineProperty(JN,"__esModule",{value:!0}),JN.NumberRange=void 0;var t=kp(),e=Ij(),i=(function(){function n(r,o){r===void 0&&(r=0),o===void 0&&(o=10),this.min=r,this.max=o}return n.prototype.union=function(r){var o=Math.min(this.min,r.min),a=Math.max(this.max,r.max);return new n(o,a)},n.prototype.clip=function(r){var o=Math.max(this.min,r.min),a=Math.min(this.max,r.max);return new n(o,a)},n.prototype.growBy=function(r){var o=this.max-this.min,a=this.min-r.min*(this.isZero()?this.min:o),s=this.max+r.max*(this.isZero()?this.max:o);if(a>s){var l=a;a=s,s=l}return new n(a,s)},n.prototype.growByLog=function(r,o){var a=this.min<0?-1:1,s=this.min!==0?(0,e.logToBase)(Math.abs(this.min),o):0,l=this.max!==0?(0,e.logToBase)(Math.abs(this.max),o):0,u=l-s,c=u*r.min,d=u*r.max,f=a*(this.min!==0?Math.pow(o,s-c):0),h=a*(this.max!==0?Math.pow(o,l+d):0);if(f>h){var p=h;h=f,f=p}return new n(f,h)},n.prototype.isDefined=function(){return(0,t.isRealNumber)(this.max)&&(0,t.isRealNumber)(this.min)},n.prototype.equals=function(r){return r?r.min===this.min&&r.max===this.max:!1},n.prototype.toString=function(){return"NumberRange (".concat(this.min,", ").concat(this.max,")")},Object.defineProperty(n.prototype,"diff",{get:function(){return this.max-this.min},enumerable:!1,configurable:!0}),n.prototype.isZero=function(){return this.min===this.max},n.areEqual=function(r,o){return r===o?!0:r&&!o||!r&&o?!1:o.min===r.min&&o.max===r.max},n.hydrate=function(r){return r&&!("growBy"in r)?new n(r.min,r.max):r},n})();return JN.NumberRange=i,JN}var Jq={},bge;function Gf(){return bge||(bge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAnimationType=void 0,(function(e){e.Fade="Fade",e.Scale="Scale",e.Sweep="Sweep",e.Wave="Wave",e.Style="Style",e.Custom="Custom"})(t.EAnimationType||(t.EAnimationType={}))})(Jq)),Jq}var Qq={},Sge;function Vd(){return Sge||(Sge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertYColumnMode=t.EColumnYMode=t.convertColumnMode=t.EColumnMode=void 0;var e;(function(o){o.Mid="Mid",o.MidWidth="MidWidth",o.Start="Start",o.StartWidth="StartWidth",o.StartEnd="StartEnd"})(e=t.EColumnMode||(t.EColumnMode={}));function i(o,a){switch(o){case e.Mid:return a.SCRTColumnXMode.ColumnXMode_Mid;case e.MidWidth:return a.SCRTColumnXMode.ColumnXMode_MidX2Width;case e.Start:return a.SCRTColumnXMode.ColumnXMode_Start;case e.StartEnd:return a.SCRTColumnXMode.ColumnXMode_StartX2End;case e.StartWidth:return a.SCRTColumnXMode.ColumnXMode_StartX2Width;default:return a.SCRTColumnXMode.ColumnXMode_Mid}}t.convertColumnMode=i;var n;(function(o){o.TopBottom="TopBottom",o.TopHeight="TopHeight",o.CenterHeight="CenterHeight"})(n=t.EColumnYMode||(t.EColumnYMode={}));function r(o,a){switch(o){case n.TopBottom:return a.SCRTColumnYMode.ColumnYMode_TopBottom;case n.TopHeight:return a.SCRTColumnYMode.ColumnYMode_TopHeight;case n.CenterHeight:return a.SCRTColumnYMode.ColumnYMode_CenterHeight;default:return a.SCRTColumnYMode.ColumnYMode_TopBottom}}t.convertYColumnMode=r})(Qq)),Qq}var e9={},_ge;function Ac(){return _ge||(_ge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDataLabelProviderType=void 0,(function(e){e.Default="Default",e.Line="Line",e.Column="Column",e.Rectangle="Rectangle",e.Text="Text",e.Heatmap="Heatmap",e.Band="Band",e.Bubble="Bubble",e.NonUniformHeatmap="NonUniformHeatmap",e.Contours="Contours",e.StackedCollection="StackedCollection",e.Custom="Custom",e.PolarDefault="PolarDefault",e.PolarColumn="PolarColumn",e.PolarText="PolarText"})(t.EDataLabelProviderType||(t.EDataLabelProviderType={}))})(e9)),e9}var t9={},Pge;function Em(){return Pge||(Pge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDataPointWidthMode=void 0,(function(e){e.Absolute="Absolute",e.Relative="Relative",e.Range="Range"})(t.EDataPointWidthMode||(t.EDataPointWidthMode={}))})(t9)),t9}var r9={},Cge;function Ng(){return Cge||(Cge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPointMarkerType=void 0,(function(e){e.Ellipse="Ellipse",e.Cross="Cross",e.Sprite="Sprite",e.Square="Square",e.Triangle="Triangle",e.X="X",e.Custom="Custom"})(t.EPointMarkerType||(t.EPointMarkerType={}))})(r9)),r9}var i9={},Tge;function eC(){return Tge||(Tge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EYRangeMode=void 0,(function(e){e.Visible="Visible",e.Drawn="Drawn"})(t.EYRangeMode||(t.EYRangeMode={}))})(i9)),i9}var XT={},B0={},xge;function ZL(){if(xge)return B0;xge=1,Object.defineProperty(B0,"__esModule",{value:!0}),B0.subArray=B0.isNumberArray=B0.isTypedArray=void 0;function t(n){return n instanceof Float64Array}B0.isTypedArray=t;function e(n){return Array.isArray(n)&&(n.length>0?typeof n[0]=="number":!0)}B0.isNumberArray=e;function i(n,r,o){return t(n)?n.subarray(r,o):n.slice(r,o)}return B0.subArray=i,B0}var n9={},Ege;function ym(){return Ege||(Ege=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertSearchMode=t.ESearchMode=void 0;var e;(function(n){n.Exact="Exact",n.Nearest="Nearest",n.RoundDown="RoundDown",n.RoundUp="RoundUp"})(e=t.ESearchMode||(t.ESearchMode={}));var i=function(n,r){switch(r){case e.Exact:return n.SCRTFindIndexSearchMode.Exact;case e.Nearest:return n.SCRTFindIndexSearchMode.Nearest;case e.RoundDown:return n.SCRTFindIndexSearchMode.RoundDown;case e.RoundUp:return n.SCRTFindIndexSearchMode.RoundUp}};t.convertSearchMode=i})(n9)),n9}var o9={},wge;function Yo(){return wge||(wge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.generateValueNamesForDataSeries=t.EValueName=void 0,(function(i){i.Y="y",i.Y1="y1",i.X1="x1",i.Z="z",i.BoxPlotMedian="median",i.BoxPlotMax="max",i.BoxPlotUpper="upper",i.BoxPlotLower="lower",i.BoxPlotMinimum="minimum",i.Close="close",i.High="high",i.Low="low",i.Open="open"})(t.EValueName||(t.EValueName={}));function e(i){for(var n=[],r=0;r<i;r++)n.push("y"+(r>0?r.toString():""));return n}t.generateValueNamesForDataSeries=e})(o9)),o9}var a9={},Age;function Rf(){return Age||(Age=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.appendDoubleVectorFromBuffer=t.appendDoubleVectorFromJsArray=t.memCopyFloat32=t.insertDoubleVectorFromJsArray=t.SIZEOF_FLOAT32=t.SIZEOF_NUMBER=void 0;var e=ci(),i=kh();t.SIZEOF_NUMBER=8,t.SIZEOF_FLOAT32=4;function n(s,l,u,c){e.Guard.notNull(s,"wasmContext"),e.Guard.notNull(l,"source"),e.Guard.notNull(u,"dest"),e.Guard.isTrue(c>=0,"destIndex must be greater than or equal to zero"),e.Guard.isTrue(c<=u.size(),"destIndex must be less than or equal to dest.size()");var d=l.length;if(d!==0){var f=u.size();u.resizeFast(f+d),c<f&&s.SCRTMemMove(u.dataPtr(c+d),u.dataPtr(c),(f-c)*t.SIZEOF_NUMBER),s.HEAPF64.set(l,u.dataPtr(c)/t.SIZEOF_NUMBER)}}t.insertDoubleVectorFromJsArray=n;function r(s,l,u,c){e.Guard.notNull(s,"wasmContext"),e.Guard.notNull(l,"source"),e.Guard.notNull(u,"dest"),e.Guard.isTrue(c>=0,"destIndex must be greater than or equal to zero"),e.Guard.isTrue(c<=u.size()+l.length,"destIndex must be less than or equal to dest.size() + source.Length");var d=l.length;d!==0&&s.HEAPF32.set(l,u.dataPtr(c)/t.SIZEOF_FLOAT32)}t.memCopyFloat32=r;function o(s,l,u){var c=l.size(),d=u.length,f=c,h=f+d;try{l.resizeFast(h)}catch(g){throw new Error("Out of memory exception. Heap size: ".concat(s.HEAPF64.buffer.byteLength/(1024*1024)," mb"),g)}var p=l.dataPtr(f);s.HEAPF64.set(u,p/t.SIZEOF_NUMBER)}t.appendDoubleVectorFromJsArray=o;function a(s,l,u){try{var c=l.size(),d=u.byteLength/Float64Array.BYTES_PER_ELEMENT,f=c,h=f+d;l.resizeFast(h);var p=l.dataPtr(f),g=s.HEAPF64;g.set(u,p/t.SIZEOF_NUMBER)}catch(v){throw i.Logger.log("Append Error",v),v}}t.appendDoubleVectorFromBuffer=a})(a9)),a9}var QN={},Oge;function qV(){if(Oge)return QN;Oge=1,Object.defineProperty(QN,"__esModule",{value:!0}),QN.copyDoubleVector=void 0;var t=Rf(),e=function(i,n,r){var o=i.size();n.resizeFast(o),r.SCRTMemCopy(n.dataPtr(0),i.dataPtr(0),o*t.SIZEOF_NUMBER)};return QN.copyDoubleVector=e,QN}var eF={},Dge;function Are(){if(Dge)return eF;Dge=1,Object.defineProperty(eF,"__esModule",{value:!0}),eF.memoize=void 0;function t(e,i){var n,r,o=function(s,l){return!s.some(function(u,c){return u!==l[c]})},a=i??o;return function(){for(var s=[],l=0;l<arguments.length;l++)s[l]=arguments[l];var u=r&&a(s,r);return(!r||!u)&&(r=s,n=e.apply(void 0,s)),n}}return eF.memoize=t,eF}var tF={},s9={},l9={},Rge;function Fg(){return Rge||(Rge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ENumericFormat=void 0,(function(e){e.NoFormat="NoFormat",e.Decimal="Decimal",e.SignificantFigures="SignificantFigures",e.Date_DDMMYYYY="Date_DDMMYYYY",e.Date_DDMMYY="Date_DDMMYY",e.Date_DDMMHHMM="Date_DDMMHHMM",e.Date_DDMM="Date_DDMM",e.Date_HHMM="Date_HHMM",e.Date_HHMMSS="Date_HHMMSS",e.Date_SSms="Date_SSms",e.Exponential="Exponential",e.Scientific="Scientific",e.Engineering="Engineering"})(t.ENumericFormat||(t.ENumericFormat={}))})(l9)),l9}var u9={},Mge;function Tf(){return Mge||(Mge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.formatUnixDateToHumanStringSSns=t.formatUnixDateToHumanStringSSus=t.formatUnixDateToHumanStringYYYY=t.formatUnixDateToHumanStringDD=t.formatUnixDateToHumanStringMMM=t.formatUnixDateToHumanStringMMMDD=t.formatUnixDateToHumanStringHHMM=t.formatUnixDateToHumanStringSSms=t.formatUnixDateToHumanStringHHMMSS=t.formatUnixDateToHumanStringDDMM=t.formatUnixDateToHumanStringDDMMHHMM=t.formatUnixDateToHumanStringDDMMYY=t.formatUnixDateToHumanString=void 0;var e=function(y,m){m===void 0&&(m="en-US");var b=new Date(y*1e3).toLocaleDateString(m,{month:"numeric",year:"numeric",day:"numeric"});return b==="Invalid Date"?"":b};t.formatUnixDateToHumanString=e;var i=function(y){var m=new Date(y*1e3).toLocaleDateString("en-GB",{timeZone:"utc",year:"2-digit",month:"2-digit",day:"2-digit"});return m==="Invalid Date"?"":m};t.formatUnixDateToHumanStringDDMMYY=i;var n=function(y){var m=(0,t.formatUnixDateToHumanStringDDMM)(y),b=(0,t.formatUnixDateToHumanStringHHMM)(y);return"".concat(m," ").concat(b)};t.formatUnixDateToHumanStringDDMMHHMM=n;var r=function(y){var m=new Date(y*1e3).toLocaleDateString("en-GB",{timeZone:"utc",day:"numeric",month:"numeric"});return m==="Invalid Date"?"":m};t.formatUnixDateToHumanStringDDMM=r;var o=function(y){var m=new Date(y*1e3),b=m.getUTCHours(),S=m.getUTCMinutes(),_=m.getUTCSeconds();if(isNaN(b)||isNaN(S)||isNaN(_))return"";var C=b<=9?"0".concat(b):b.toString(10),P=S<=9?"0".concat(S):S.toString(10),x=_<=9?"0".concat(_):_.toString(10);return"".concat(C,":").concat(P,":").concat(x)};t.formatUnixDateToHumanStringHHMMSS=o;var a=function(y,m){var b=new Date(y*1e3),S=b.getUTCSeconds(),_=m!==void 0?m:b.getUTCMilliseconds();if(isNaN(S)||isNaN(_))return"";var C=S<=9?"0".concat(S):S.toString(10),P=p(_,3);return"".concat(C,".").concat(P)};t.formatUnixDateToHumanStringSSms=a;var s=function(y){var m=new Date(y*1e3),b=m.getUTCHours(),S=m.getUTCMinutes();if(isNaN(b)||isNaN(S))return"";var _=b<=9?"0".concat(b):b.toString(10),C=S<=9?"0".concat(S):S.toString(10);return"".concat(_,":").concat(C)};t.formatUnixDateToHumanStringHHMM=s;var l=function(y){var m=new Date(y*1e3),b=m.getUTCMonth(),S=m.getUTCDate();return isNaN(b)||isNaN(S)?"":"".concat(h(b)," ").concat(S)};t.formatUnixDateToHumanStringMMMDD=l;var u=function(y){var m=new Date(y*1e3),b=m.getUTCMonth();return isNaN(b)?"":h(b)};t.formatUnixDateToHumanStringMMM=u;var c=function(y){var m=new Date(y*1e3),b=m.getUTCDate();if(isNaN(b))return"";var S=b.toString();return S.length===2?S:S.length===1?"0".concat(S):""};t.formatUnixDateToHumanStringDD=c;var d=function(y){var m=new Date(y*1e3),b=m.getUTCFullYear();return isNaN(b)?"":b.toString(10)};t.formatUnixDateToHumanStringYYYY=d;var f=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],h=function(y){if(y<0||y>11)throw new Error("Invalid month index");return f[y]},p=function(y,m){for(var b=Math.floor(Math.abs(y)).toString();b.length<m;)b="0"+b;return b},g=function(y,m){var b=new Date(y*1e3),S=b.getUTCSeconds();return isNaN(S)?"":"".concat(p(S,2),".").concat(p(m,6))};t.formatUnixDateToHumanStringSSus=g;var v=function(y,m){var b=new Date(y*1e3),S=b.getUTCSeconds();return isNaN(S)?"":"".concat(p(S,2),".").concat(p(m,9))};t.formatUnixDateToHumanStringSSns=v})(u9)),u9}var Lge;function Du(){return Lge||(Lge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.checkIsNaN=t.toEngineering=t.toScientific=t.toSuperScript=t.formatNumber=t.numericHashCode=t.formatNumber2Digits=void 0;var e=Fg(),i=Tf(),n=Ij(),r=function(f){return(Math.round((f+Number.EPSILON)*100)/100).toFixed(2)};t.formatNumber2Digits=r;var o=function(f,h){return f=f*31-f+h,f|=0,f};t.numericHashCode=o;var a=function(f,h,p,g){if(f===void 0)return"";switch(h){case e.ENumericFormat.NoFormat:return f.toString();case e.ENumericFormat.Decimal:return f.toFixed(p);case e.ENumericFormat.SignificantFigures:return Number(f.toPrecision(p)).toString();case e.ENumericFormat.Exponential:return f.toExponential(p);case e.ENumericFormat.Scientific:return(0,t.toScientific)(f,p,10);case e.ENumericFormat.Date_DDMMYYYY:return(0,i.formatUnixDateToHumanString)(f);case e.ENumericFormat.Date_DDMMYY:return(0,i.formatUnixDateToHumanStringDDMMYY)(f);case e.ENumericFormat.Date_DDMMHHMM:return(0,i.formatUnixDateToHumanStringDDMMHHMM)(f);case e.ENumericFormat.Date_DDMM:return(0,i.formatUnixDateToHumanStringDDMM)(f);case e.ENumericFormat.Date_HHMM:return(0,i.formatUnixDateToHumanStringHHMM)(f);case e.ENumericFormat.Date_HHMMSS:return(0,i.formatUnixDateToHumanStringHHMMSS)(f);case e.ENumericFormat.Date_SSms:return(0,i.formatUnixDateToHumanStringSSms)(f);case e.ENumericFormat.Engineering:return(0,t.toEngineering)(f,g==null?void 0:g.large,g==null?void 0:g.small,p)}};t.formatNumber=a;var s=["⁰","¹","²","³","⁴","⁵","⁶","⁷","⁸","⁹"],l=function(f){for(var h="",p=f<0,g=Math.abs(f).toString(),v=0,y=g;v<y.length;v++){var m=y[v],b=Number.parseInt(m);isNaN(b)||(h+=s[b])}return(p?"⁻":"")+h};t.toSuperScript=l;var u=function(f,h,p){if(f===0)return"0";var g=(0,n.logToBase)(Math.abs(f),p);g=Math.floor(g);var v=f/Math.pow(p,g);return v.toPrecision(h).toString()+"x"+p.toString()+(0,t.toSuperScript)(g)};t.toScientific=u;var c=function(f,h,p,g){if(g===void 0&&(g=1),f===0)return"0";var v=Math.abs(f);if(h??(h=["K","M","B","T"]),p??(p=["m","µ","n","p"]),h.length===0&&p.length===0)return f.toString();var y=function(_){var C=Math.pow(10,g),P=Math.trunc(_*C)/C,x=P.toFixed(g);return x.replace(/\.?0+$/,"")};if(v>=1&&v<1e3)return y(f);if(v>=1e3&&h.length>0)for(var m=1;m<=h.length;m++){var b=Math.pow(10,3*(m+1));if(v<b||m===h.length){var S=f/Math.pow(10,3*m);return y(S)+h[m-1]}}if(v<1&&v>0&&p.length>0)for(var m=0;m<p.length;m++){var b=Math.pow(10,-3*(m+1));if(v>=b||m===p.length-1){var S=f*Math.pow(10,3*(m+1));return y(S)+p[m]}}return f.toString()};t.toEngineering=c;var d=function(f){return f!==f};t.checkIsNaN=d})(s9)),s9}var kge;function gFe(){if(kge)return tF;kge=1,Object.defineProperty(tF,"__esModule",{value:!0}),tF.DataDistributionCalculator=void 0;var t=GV(),e=Th(),i=Du(),n=(function(){function r(){this.containsNanProperty=!1,this.isSortedAscendingProperty=!0}return Object.defineProperty(r.prototype,"containsNaN",{get:function(){return this.containsNanProperty},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"isSortedAscending",{get:function(){return this.isSortedAscendingProperty},enumerable:!1,configurable:!0}),r.prototype.onAppend=function(o,a,s,l,u){if(a!==void 0?this.containsNanProperty=a:this.containsNanProperty===!1&&u&&(this.containsNanProperty=u.some(i.checkIsNaN),this.containsNanProperty===!1&&t.performanceWarnings.dataDistributionFlagNaN.warn()),o!==void 0)this.isSortedAscendingProperty=o;else if(this.isSortedAscendingProperty===!0){var c=(0,e.isArraySorted)(l),d=s.size(),f=d===0||s.get(d-1)<l[0];this.isSortedAscendingProperty=c&&f,this.isSortedAscendingProperty===!0&&t.performanceWarnings.dataDistributionFlagSortedAscending.warn()}},r.prototype.onInsert=function(o,a,s,l,u,c){if(a!==void 0?this.containsNanProperty=a:this.containsNanProperty===!1&&u&&(this.containsNanProperty=u.some(i.checkIsNaN),this.containsNanProperty===!1&&t.performanceWarnings.dataDistributionFlagNaN.warn()),o!==void 0)this.isSortedAscendingProperty=o;else if(this.isSortedAscendingProperty===!0&&l){var d=(0,e.isArraySorted)(l),f=c===0||s.get(c-1)<l[0],h=c>=s.size()||l[l.length-1]<s.get(c);this.isSortedAscendingProperty=d&&f&&h,this.isSortedAscendingProperty===!0&&t.performanceWarnings.dataDistributionFlagSortedAscending.warn()}},r.prototype.onUpdate=function(o,a,s,l,u,c){if(a!==void 0?this.containsNanProperty=a:this.containsNanProperty===!1&&u&&(this.containsNanProperty=u.some(i.checkIsNaN)),o!==void 0)this.isSortedAscendingProperty=o;else if(this.isSortedAscendingProperty===!0&&l){var d=(0,e.isArraySorted)(l),f=c===0||s.get(c-1)<l[0],h=s.size(),p=c+l.length,g=p>=h||l[l.length-1]<s.get(p);this.isSortedAscendingProperty=d&&f&&g}},r.prototype.clear=function(o,a){this.isSortedAscendingProperty=o??!0,this.containsNanProperty=a??!1},r.prototype.setIsSortedAscending=function(o){this.isSortedAscendingProperty=o},r.prototype.setContainsNaN=function(o){this.containsNanProperty=o},r})();return tF.DataDistributionCalculator=n,tF}var KT={},Ige;function cJ(){if(Ige)return KT;Ige=1,Object.defineProperty(KT,"__esModule",{value:!0}),KT.FIFOVectorProvider=KT.DoubleVectorProvider=void 0;var t=ZL(),e=Rf(),i=(function(){function r(){}return r.prototype.getDoubleVector=function(o){return this.capacity?new o.SCRTDoubleVector(this.capacity):new o.SCRTDoubleVector},r.prototype.appendArray=function(o,a,s){(0,e.appendDoubleVectorFromJsArray)(o,a,s)},r.prototype.appendBuffer=function(o,a,s){(0,e.appendDoubleVectorFromBuffer)(o,a,s)},r})();KT.DoubleVectorProvider=i;var n=(function(){function r(o){this.capacity=o}return r.prototype.getDoubleVector=function(o){return new o.SCRTFifoVector(this.capacity)},r.prototype.appendArray=function(o,a,s){var l=a.size(),u=a.capacity(),c=s.length,d=a.getStartIndex();if(u>=l+c){var f=a.dataPtr(l);o.HEAPF64.set(s,f/e.SIZEOF_NUMBER),a.notifyAppend(c)}else if(c>u){var h=c-u,p=(0,t.subArray)(s,h),g=a.dataPtrZero();o.HEAPF64.set(p,g/e.SIZEOF_NUMBER),a.notifyAppend(u)}else if(u>l){var v=u-l,y=(0,t.subArray)(s,0,v),m=a.dataPtr(l);o.HEAPF64.set(y,m/e.SIZEOF_NUMBER);var b=(0,t.subArray)(s,v),g=a.dataPtrZero();o.HEAPF64.set(b,g/e.SIZEOF_NUMBER),a.notifyAppend(c)}else{if(d+c>u){var v=u-d,y=(0,t.subArray)(s,0,v),m=a.dataPtr(0);o.HEAPF64.set(y,m/e.SIZEOF_NUMBER);var b=(0,t.subArray)(s,v),g=a.dataPtrZero();o.HEAPF64.set(b,g/e.SIZEOF_NUMBER)}else{var m=a.dataPtr(0);o.HEAPF64.set(s,m/e.SIZEOF_NUMBER)}a.notifyAppend(c)}},r.prototype.appendBuffer=function(o,a,s){(0,e.appendDoubleVectorFromBuffer)(o,a,s)},r})();return KT.FIFOVectorProvider=n,KT}var c9={},Nge;function zi(){return Nge||(Nge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDataSeriesValueType=t.EDataChangeType=t.EDataSeriesType=void 0,(function(e){e.XyN="XyN",e.Xy="Xy",e.Xyy="Xyy",e.Xyz="Xyz",e.Ohlc="Ohlc",e.HeatmapUniform="UniformHeatmap",e.HeatmapNonUniform="NonUniformHeatmap",e.Hlc="Hlc",e.XyText="XyText",e.Xyxy="Xyxy",e.Xyx="Xyx",e.X="X",e.BoxPlot="BoxPlot"})(t.EDataSeriesType||(t.EDataSeriesType={})),(function(e){e[e.Append=0]="Append",e[e.Insert=1]="Insert",e[e.Update=2]="Update",e[e.Remove=3]="Remove",e[e.Clear=4]="Clear",e[e.Property=5]="Property"})(t.EDataChangeType||(t.EDataChangeType={})),(function(e){e.Default="Default",e.InitialAnimationValues="InitialAnimationValues",e.FinalAnimationValues="FinalAnimationValues"})(t.EDataSeriesValueType||(t.EDataSeriesValueType={}))})(c9)),c9}var rF={},Fge;function XV(){if(Fge)return rF;Fge=1,Object.defineProperty(rF,"__esModule",{value:!0}),rF.TemplateMetadataGenerator=void 0;var t=(function(){function e(i){this.template=i}return e.prototype.getSingleMetadata=function(){return Object.assign({},this.template)},e.prototype.getMetadata=function(){},e.prototype.toJSON=function(){return"toJSON"in this.template?this.template.toJSON():this.template},e})();return rF.TemplateMetadataGenerator=t,rF}var iF={},Bge;function wm(){if(Bge)return iF;Bge=1,Object.defineProperty(iF,"__esModule",{value:!0}),iF.BasePointSeriesWrapped=void 0;var t=zi(),e=(function(){function i(n,r,o,a){var s;if(this.type=t.EDataSeriesType.XyN,this.yValuesArray=[],this.resampled=!1,this.dataSeries=n,this.xValues=this.dataSeries.getXValues(o),!r||r.length===0||r[0]===void 0)this.count=n.count(),this.yValuesArray=n.getYValuesArray(o);else{this.count=r.length;for(var l=0;l<r.length;l++)this.yValuesArray.push((s=r[l])!==null&&s!==void 0?s:n.yValuesArray[l])}this.valueNamesProperty=a??this.dataSeries.valueNames,this.fifoStartIndex=n.fifoStartIndex}return Object.defineProperty(i.prototype,"indexes",{get:function(){return this.indexesProperty||(this.indexesProperty=this.dataSeries.getNativeIndexes()),this.indexesProperty},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"valueNames",{get:function(){return this.valueNamesProperty},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"arrayCount",{get:function(){return this.dataSeries.arrayCount},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"yValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),i.prototype.getYValues=function(n){return this.yValuesArray[n??0]},i.prototype.getYValuesByName=function(n){var r=this.valueNames.indexOf(n);if(r>=0)return this.yValuesArray[r]},i.prototype.delete=function(){},i})();return iF.BasePointSeriesWrapped=e,iF}var jge;function Bu(){return jge||(jge=1,(function(t){var e=XT&&XT.__extends||(function(){var D=function(F,I){return D=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(V,z){V.__proto__=z}||function(V,z){for(var G in z)Object.prototype.hasOwnProperty.call(z,G)&&(V[G]=z[G])},D(F,I)};return function(F,I){if(typeof I!="function"&&I!==null)throw new TypeError("Class extends value "+String(I)+" is not a constructor or null");D(F,I);function V(){this.constructor=F}F.prototype=I===null?Object.create(I):(V.prototype=I.prototype,new V)}})(),i=XT&&XT.__assign||function(){return i=Object.assign||function(D){for(var F,I=1,V=arguments.length;I<V;I++){F=arguments[I];for(var z in F)Object.prototype.hasOwnProperty.call(F,z)&&(D[z]=F[z])}return D},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.getWindowedYRange=t.getIndicesRange=t.BaseDataSeries=void 0;var n=mo(),r=fo(),o=Br(),a=ps(),s=ci(),l=di(),u=ga(),c=ZL(),d=ym(),f=Yo(),h=eC(),p=Th(),g=Rf(),v=qV(),y=hl(),m=kp(),b=Are(),S=La(),_=gFe(),C=cJ(),P=zi(),x=XV(),E=wm(),A=(function(D){e(F,D);function F(I,V){var z=this,G,H,U,k,X,W,Y,te,oe,de;if(z=D.call(this)||this,z.dataChanged=new a.EventHandler,z.dataDistributionCalculator=new _.DataDistributionCalculator,z.minXSpacing=0,z.yInitialAnimationValuesArray=[],z.yFinalAnimationValuesArray=[],z.yValuesArray=[],z.arrayCount=1,z.doubleVectorProvider=new C.DoubleVectorProvider,z.isSortedProperty=void 0,z.containsNaNProperty=void 0,z.isEvenlySpacedProperty=!1,z.metadataGeneratorProperty=void 0,z.changeCountProperty=0,z.fifoCapacityProperty=void 0,z.fifoSweepingProperty=!1,z.fifoSweepingGapProperty=1,z.webAssemblyContext=I,z.id=(G=V==null?void 0:V.id)!==null&&G!==void 0?G:(0,y.generateGuid)(),V!=null&&V.fifoCapacity)z.fifoCapacityProperty=V.fifoCapacity,z.doubleVectorProvider=new C.FIFOVectorProvider(V.fifoCapacity);else{var ge=z.calculateInitialCapacity(V);s.Guard.argumentIsRealInteger(ge,"initialCapacity"),z.doubleVectorProvider.capacity=ge}z.fifoSweepingProperty=(V==null?void 0:V.fifoSweeping)||z.fifoSweepingProperty,z.fifoSweepingGapProperty=(V==null?void 0:V.fifoSweepingGap)||z.fifoSweepingGapProperty,z.xValues=z.doubleVectorProvider.getDoubleVector(I),z.arrayCount=(H=V==null?void 0:V.arrayCount)!==null&&H!==void 0?H:z.arrayCount;for(var Ee=0;Ee<z.arrayCount;Ee++)z.yValuesArray.push(z.doubleVectorProvider.getDoubleVector(I));return z.valueNames=(U=V==null?void 0:V.valueNames)!==null&&U!==void 0?U:(0,f.generateValueNamesForDataSeries)(z.yValuesArray.length),z.indexes=new I.SCRTDoubleVector,z.dataSeriesNameProperty=(k=V==null?void 0:V.dataSeriesName)!==null&&k!==void 0?k:z.dataSeriesNameProperty,z.isSorted=(W=(X=V==null?void 0:V.dataIsSortedInX)!==null&&X!==void 0?X:V==null?void 0:V.isSorted)!==null&&W!==void 0?W:z.isSortedProperty,z.containsNaN=(Y=V==null?void 0:V.containsNaN)!==null&&Y!==void 0?Y:z.containsNaNProperty,z.isEvenlySpaced=(te=V==null?void 0:V.dataEvenlySpacedInX)!==null&&te!==void 0?te:z.isEvenlySpacedProperty,z.includeInYRange=(oe=V==null?void 0:V.includeInYRange)!==null&&oe!==void 0?oe:z.valueNames.map(function(Re){return!0}),V!=null&&V.metadata&&("type"in V.metadata?(z.metadataGeneratorProperty=(0,n.createType)(u.EBaseType.MetadataGenerator,V.metadata.type,I,V.metadata.data),V.metadata=(de=z.metadataGeneratorProperty)===null||de===void 0?void 0:de.getMetadata()):Array.isArray(V==null?void 0:V.metadata)||(z.metadataGeneratorProperty=new x.TemplateMetadataGenerator(V==null?void 0:V.metadata),V.metadata=void 0)),z}return F.prototype.getYValuesByName=function(I,V){V===void 0&&(V=P.EDataSeriesValueType.Default);var z=this.valueNames.indexOf(I);if(z>=0)switch(V){case P.EDataSeriesValueType.FinalAnimationValues:return this.yFinalAnimationValuesArray[z];case P.EDataSeriesValueType.InitialAnimationValues:return this.yInitialAnimationValuesArray[z];default:return this.yValuesArray[z]}else return},F.prototype.appendN=function(I,V,z,G){var H,U=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){var k=this.getNativeXValues();this.dataDistributionCalculator.onAppend(this.isSorted,this.containsNaN,k,[I],[V[0]]),this.appendMetadata(z),k.push_back(I);for(var X=0;X<this.arrayCount;X++)this.yValuesArray[X].push_back(V[X]);G&&G(),this.notifyDataChanged(P.EDataChangeType.Append,null,1)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(H=U==null?void 0:U.detail)===null||H===void 0?void 0:H.relatedId,contextId:this.id})},F.prototype.appendRangeN=function(I,V,z,G){var H,U=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){s.Guard.isTrue((0,c.isNumberArray)(I)||(0,c.isTypedArray)(I),"xValues must be an array of numbers");for(var k=0;k<this.arrayCount;k++){var X=this.valueNames[k];if(s.Guard.isTrue((0,c.isNumberArray)(V[k])||(0,c.isTypedArray)(V[k]),"".concat(X,"Values must be an array of numbers")),V[k].length!==I.length)throw new Error("Arrays xValues and ".concat(X," must have the same length"))}z&&(s.Guard.isTrue(Array.isArray(z),"metadata must be an array of IPointMetadata"),s.Guard.arraysSameLength(I,"xValues",z,"metadata"));var W=this.getNativeXValues();this.dataDistributionCalculator.onAppend(this.isSorted,this.containsNaN,W,I,V[0]),this.appendMetadataRange(z,I.length),this.doubleVectorProvider.appendArray(this.webAssemblyContext,W,I);for(var k=0;k<this.arrayCount;k++)this.doubleVectorProvider.appendArray(this.webAssemblyContext,this.yValuesArray[k],V[k]);G&&G(),this.notifyDataChanged(P.EDataChangeType.Append,null,I.length)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(H=U==null?void 0:U.detail)===null||H===void 0?void 0:H.relatedId,contextId:this.id})},F.prototype.appendBufferRangeN=function(I,V,z,G){var H,U=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){s.Guard.isTrue(I instanceof ArrayBuffer,"xValues must be a valid ArrayBuffer");for(var k=0;k<this.arrayCount;k++){var X=this.valueNames[k];if(s.Guard.isTrue(V[k]instanceof ArrayBuffer,"".concat(X,"Values must be a valid ArrayBuffer")),V[k].byteLength!==I.byteLength)throw new Error("Arrays xValues and ".concat(X," must have the same length"))}z&&(s.Guard.isTrue(Array.isArray(z),"metadata must be an array of IPointMetadata"),s.Guard.isTrue(I.byteLength/Float64Array.BYTES_PER_ELEMENT===z.length,"Arrays xValues and metadata must have the same length"));var W=this.getNativeXValues();this.appendMetadataRange(z,I.byteLength/Float64Array.BYTES_PER_ELEMENT),this.doubleVectorProvider.appendBuffer(this.webAssemblyContext,W,I);for(var k=0;k<this.arrayCount;k++)this.doubleVectorProvider.appendBuffer(this.webAssemblyContext,this.yValuesArray[k],V[k]);G&&G(),this.notifyDataChanged(P.EDataChangeType.Append,null,I.byteLength/Float64Array.BYTES_PER_ELEMENT)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(H=U==null?void 0:U.detail)===null||H===void 0?void 0:H.relatedId,contextId:this.id})},F.prototype.updateN=function(I,V,z,G){var H,U=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){this.validateIndex(I),this.dataDistributionCalculator.onUpdate(this.isSorted,this.containsNaN,void 0,void 0,[V[0]],I);for(var k=0;k<this.arrayCount;k++)this.yValuesArray[k].set(I,V[k]);G&&G(),this.setMetadataAt(I,z),this.notifyDataChanged(P.EDataChangeType.Update,I,1)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(H=U==null?void 0:U.detail)===null||H===void 0?void 0:H.relatedId,contextId:this.id})},F.prototype.updateXyN=function(I,V,z,G,H){var U,k=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){this.validateIndex(I);var X=this.getNativeXValues();this.dataDistributionCalculator.onUpdate(this.isSorted,this.containsNaN,X,[V],[z[0]],I),X.set(I,V);for(var W=0;W<this.arrayCount;W++)this.yValuesArray[W].set(I,z[W]);H&&H(),this.setMetadataAt(I,G),this.notifyDataChanged(P.EDataChangeType.Update,I,1)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(U=k==null?void 0:k.detail)===null||U===void 0?void 0:U.relatedId,contextId:this.id})},F.prototype.insertN=function(I,V,z,G,H){var U,k=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){this.validateIndex(I,"Start index is out of range"),this.throwIfFifo("insert");var X=this.getNativeXValues();this.getNativeYValues(),this.dataDistributionCalculator.onInsert(this.isSorted,this.containsNaN,X,[V],[z[0]],I),X.insertAt(I,V);for(var W=0;W<this.arrayCount;W++)this.yValuesArray[W].insertAt(I,z[W]);H&&H(),this.insertMetadata(I,G),this.notifyDataChanged(P.EDataChangeType.Insert,I,1)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(U=k==null?void 0:k.detail)===null||U===void 0?void 0:U.relatedId,contextId:this.id})},F.prototype.insertRangeN=function(I,V,z,G,H){var U,k=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){s.Guard.isTrue((0,c.isNumberArray)(V)||(0,c.isTypedArray)(V),"xValues must be an array of numbers"),this.validateIndex(I,"Start index is out of range");for(var X=0;X<this.arrayCount;X++){var W=this.valueNames[X];if(s.Guard.isTrue((0,c.isNumberArray)(z[X])||(0,c.isTypedArray)(z[X]),"".concat(W,"Values must be an array of numbers")),z[X].length!==V.length)throw new Error("Arrays xValues and ".concat(W," must have the same length"))}this.throwIfFifo("insertRange"),G&&(s.Guard.isTrue(Array.isArray(G),"metadata must be an array of IPointMetadata"),s.Guard.arraysSameLength(V,"xValues",G,"metadata"));var Y=this.getNativeXValues();this.dataDistributionCalculator.onInsert(this.isSorted,this.containsNaN,Y,V,z[0],I),(0,g.insertDoubleVectorFromJsArray)(this.webAssemblyContext,V,this.getNativeXValues(),I);for(var X=0;X<this.arrayCount;X++)(0,g.insertDoubleVectorFromJsArray)(this.webAssemblyContext,z[X],this.yValuesArray[X],I);H&&H(),this.insertMetadataRange(I,G),this.notifyDataChanged(P.EDataChangeType.Insert,I,V.length)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(U=k==null?void 0:k.detail)===null||U===void 0?void 0:U.relatedId,contextId:this.id})},F.prototype.removeAt=function(I){var V,z=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){this.validateIndex(I),this.throwIfFifo("removeAt"),this.getNativeXValues().removeAt(I);for(var G=0;G<this.arrayCount;G++)this.yValuesArray[G].removeAt(I);this.removeMetadataAt(I),this.notifyDataChanged(P.EDataChangeType.Remove,I,1)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(V=z==null?void 0:z.detail)===null||V===void 0?void 0:V.relatedId,contextId:this.id})},F.prototype.removeRange=function(I,V){var z,G=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){this.validateIndex(I,"Start index is out of range"),this.throwIfFifo("removeRange"),this.getNativeXValues().removeRange(I,V);for(var H=0;H<this.arrayCount;H++)this.yValuesArray[H].removeRange(I,V);this.removeMetadataRange(I,V),this.notifyDataChanged(P.EDataChangeType.Remove,I,V)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(z=G==null?void 0:G.detail)===null||z===void 0?void 0:z.relatedId,contextId:this.id})},F.prototype.clear=function(){var I,V,z=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateStart,{contextId:this.id});if(!this.getIsDeleted()){(I=this.indexes)===null||I===void 0||I.clear(),this.dataDistributionCalculator.clear(this.isSorted,this.containsNaN),this.getNativeXValues().clear();for(var G=0;G<this.arrayCount;G++)this.yValuesArray[G].clear();this.setMetadata(void 0),this.notifyDataChanged(P.EDataChangeType.Clear,null,null)}S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.DataUpdateEnd,{relatedId:(V=z==null?void 0:z.detail)===null||V===void 0?void 0:V.relatedId,contextId:this.id})},Object.defineProperty(F.prototype,"capacity",{get:function(){return this.xValues.capacity()},set:function(I){I>this.capacity&&this.reserve(I)},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"containsNaN",{get:function(){return this.containsNaNProperty},set:function(I){this.containsNaNProperty=I,I!==void 0&&this.dataDistributionCalculator.setContainsNaN(I),this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"containsNaN")},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isSorted",{get:function(){return this.isSortedProperty},set:function(I){this.isSortedProperty=I,I!==void 0&&this.dataDistributionCalculator.setIsSortedAscending(I),this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"isSorted")},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isEvenlySpaced",{get:function(){return this.isEvenlySpacedProperty},set:function(I){this.isEvenlySpacedProperty=I,this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"isEvenlySpaced")},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"dataSeriesName",{get:function(){return this.dataSeriesNameProperty},set:function(I){this.dataSeriesNameProperty=I,this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"dataSeriesName")},enumerable:!1,configurable:!0}),F.prototype.count=function(){return this.xValues?this.xValues.size():0},F.prototype.getIsDeleted=function(){return this.isDeleted},Object.defineProperty(F.prototype,"fifoCapacity",{get:function(){return this.fifoCapacityProperty},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"fifoStartIndex",{get:function(){return this.fifoCapacity>0?this.xValues.getStartIndex():0},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"fifoSweeping",{get:function(){return this.fifoCapacity&&this.fifoSweepingProperty},set:function(I){this.fifoSweepingProperty=I,this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"fifoSweeping")},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"fifoSweepingGap",{get:function(){return this.fifoSweepingGapProperty},set:function(I){this.fifoSweepingGapProperty=I,this.notifyDataChanged(P.EDataChangeType.Property,void 0,void 0,"fifoSweepingGap")},enumerable:!1,configurable:!0}),F.prototype.getNativeIndexes=function(){if(this.indexes){var I=this.count(),V=this.indexes.size();return V<I?this.webAssemblyContext.SCRTFillVectorSequential(this.indexes,I):V>I&&this.indexes.resizeFast(I),this.indexes}},F.prototype.getNativeXValues=function(){return this.xValues},F.prototype.getNativeYValues=function(I){return I===void 0&&(I=0),this.yValuesArray[I]},Object.defineProperty(F.prototype,"yInitialAnimationValues",{get:function(){return this.yInitialAnimationValuesArray[0]},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"yFinalAnimationValues",{get:function(){return this.yFinalAnimationValuesArray[0]},enumerable:!1,configurable:!0}),F.prototype.getNativeValue=function(I,V){if(I)return!this.fifoSweeping||!I.getRaw?I.get(V):I.getRaw(V)},F.prototype.delete=function(){this.isDeleted||(this.xValues=(0,o.deleteSafe)(this.xValues),this.yValuesArray.forEach(function(I){return(0,o.deleteSafe)(I)}),this.yValuesArray.length=0,this.indexes=(0,o.deleteSafe)(this.indexes),this.xInitialAnimationValues=(0,o.deleteSafe)(this.xInitialAnimationValues),this.yInitialAnimationValuesArray.forEach(function(I){return(0,o.deleteSafe)(I)}),this.xFinalAnimationValues=(0,o.deleteSafe)(this.xFinalAnimationValues),this.yFinalAnimationValuesArray.forEach(function(I){return(0,o.deleteSafe)(I)}),this.setMetadata(void 0),this.isDeleted=!0)},F.prototype.notifyDataChanged=function(I,V,z,G){this.changeCountProperty++,this.dataChanged.raiseEvent({changeType:I,index:V,count:z})},Object.defineProperty(F.prototype,"xRange",{get:function(){return this.getXRange()},enumerable:!1,configurable:!0}),F.prototype.getXRange=function(I){return this.getXRangeByName(I)},F.prototype.getXRangeByName=function(I,V){var z=this;return this.memoizedgetXRange||(this.memoizedgetXRange=(0,b.memoize)(function(G,H,U){var k=U?z.getYValuesByName(U,H):z.getXValues(H),X;if(z.count()===1){var W=k.get(0)-1,Y=k.get(0)+1;return new l.NumberRange(W,Y)}else if(z.count()>1){var W=k.get(0),Y=k.get(z.count()-1);if(!z.dataDistributionCalculator.isSortedAscending){var te=void 0;try{if(te=z.webAssemblyContext.NumberUtil.MinMax(k,!1),!(0,m.isRealNumber)(te.minD)||!(0,m.isRealNumber)(te.maxD))return new l.NumberRange(0,0);W=te.minD,Y=te.maxD}finally{(0,o.deleteSafe)(te)}}return W===Y?new l.NumberRange(W-1,Y+1):(W>Y&&(X=W,W=Y,Y=X),new l.NumberRange(W,Y))}return new l.NumberRange(0,0)})),this.memoizedgetXRange(this.changeCount,I,V)},F.prototype.getWindowedYRange=function(I,V,z,G,H){var U=this;return z===void 0&&(z=!1),G===void 0&&(G=P.EDataSeriesValueType.Default),H===void 0&&(H=h.EYRangeMode.Visible),this.memoizedGetWindowedYRange||(this.memoizedGetWindowedYRange=(0,b.memoize)(function(k){var X=k._xRange;k._getPositiveRange;var W=k._isXCategoryAxis,Y=k._dataSeriesValueType,te=k._yRangeMode,oe=Number.MAX_VALUE,de=Number.NEGATIVE_INFINITY,ge=te===h.EYRangeMode.Visible?d.ESearchMode.RoundUp:d.ESearchMode.RoundDown,Ee=te===h.EYRangeMode.Visible?d.ESearchMode.RoundDown:d.ESearchMode.RoundUp;if(U.count()===1){for(var Re=0;Re<U.arrayCount;Re++)if(U.includeInYRange[Re]){var Ae=U.yValuesArray[Re].get(0);oe=Math.min(oe,Ae),de=Math.max(de,Ae)}return new l.NumberRange(oe,de)}var Pe=U.getXValues(Y),we=W?X:(0,t.getIndicesRange)(U.webAssemblyContext,Pe,X,U.dataDistributionCalculator.isSortedAscending,ge,Ee),Te=Math.max(Math.floor(we.min),0),ke=Math.min(Math.ceil(we.max),U.count()-1);if(!(ke<Te)){var $e;try{for(var Re=0;Re<U.arrayCount;Re++)if(U.includeInYRange[Re]){if($e=U.webAssemblyContext.NumberUtil.MinMaxWithIndex(U.getYValues(Y,Re),Te,ke-Te+1,U.dataDistributionCalculator.containsNaN),!(0,m.isRealNumber)($e.minD)||!(0,m.isRealNumber)($e.maxD))return;oe=Math.min(oe,$e.minD),de=Math.max(de,$e.maxD)}return new l.NumberRange(oe,de)}finally{(0,o.deleteSafe)($e)}}},function(k,X){var W=k[0],Y=X[0];return W._xRange.equals(Y._xRange)&&W._changeCount===Y._changeCount&&W._dataSeriesValueType===Y._dataSeriesValueType&&W._isXCategoryAxis===Y._isXCategoryAxis&&W._yRangeMode===Y._yRangeMode})),this.memoizedGetWindowedYRange({_changeCount:this.changeCount,_xRange:I,_getPositiveRange:V,_isXCategoryAxis:z,_dataSeriesValueType:G,_yRangeMode:H})},F.prototype.getIndicesRange=function(I,V,z,G){V===void 0&&(V=!1),z===void 0&&(z=d.ESearchMode.RoundDown),G===void 0&&(G=d.ESearchMode.RoundUp);var H=V?this.getNativeIndexes():this.xValues;return(0,t.getIndicesRange)(this.webAssemblyContext,H,I,this.dataDistributionCalculator.isSortedAscending,z,G)},Object.defineProperty(F.prototype,"hasValues",{get:function(){return this.count()>0},enumerable:!1,configurable:!0}),F.prototype.hasMetadataGenerator=function(){return typeof this.metadataGeneratorProperty<"u"},F.prototype.setMetadataGenerator=function(I){var V=this,z=!this.hasMetadataGenerator();if(this.metadataGeneratorProperty=I,z&&!this.metadataProperty){var G=Array(this.xValues.size()).fill(1).map(function(H){return V.metadataGeneratorProperty.getSingleMetadata()});this.metadataProperty=G}},F.prototype.getMetadataAt=function(I,V){if(V===void 0&&(V=!1),this.validateIndex(I),!!this.metadataProperty)if(this.fifoCapacity&&!V){var z=(this.xValues.getStartIndex()+I)%this.fifoCapacity;return this.metadataProperty[z]}else return this.metadataProperty[I]},F.prototype.getMetadataLength=function(){return this.metadataProperty?this.metadataProperty.length:this.count()},Object.defineProperty(F.prototype,"hasMetadata",{get:function(){return this.metadataProperty!==void 0},enumerable:!1,configurable:!0}),F.prototype.createAnimationVectors=function(){this.xInitialAnimationValues=this.doubleVectorProvider.getDoubleVector(this.webAssemblyContext),this.xFinalAnimationValues=this.doubleVectorProvider.getDoubleVector(this.webAssemblyContext);for(var I=0;I<this.arrayCount;I++)this.yInitialAnimationValuesArray.push(this.doubleVectorProvider.getDoubleVector(this.webAssemblyContext)),this.yFinalAnimationValuesArray.push(this.doubleVectorProvider.getDoubleVector(this.webAssemblyContext))},F.prototype.setInitialAnimationVectors=function(I){var V=this;if(!I){this.xInitialAnimationValues.resize(0,0),this.yInitialAnimationValuesArray.forEach(function(z){return z.resize(0,0)});return}(0,v.copyDoubleVector)(I.getNativeXValues(),this.xInitialAnimationValues,this.webAssemblyContext),this.yInitialAnimationValuesArray.forEach(function(z,G){return(0,v.copyDoubleVector)(I.getNativeYValues(G),z,V.webAssemblyContext)})},F.prototype.setFinalAnimationVectors=function(I){var V=this;if(!I){this.xFinalAnimationValues.resize(0,0),this.yFinalAnimationValuesArray.forEach(function(z){return z.resize(0,0)});return}(0,v.copyDoubleVector)(I.getNativeXValues(),this.xFinalAnimationValues,this.webAssemblyContext),this.yFinalAnimationValuesArray.forEach(function(z,G){return(0,v.copyDoubleVector)(I.getNativeYValues(G),z,V.webAssemblyContext)})},F.prototype.revertAnimationVectors=function(I){I=I??this,(0,v.copyDoubleVector)(this.xFinalAnimationValues,I.getNativeXValues(),this.webAssemblyContext),(0,v.copyDoubleVector)(this.yFinalAnimationValues,I.getNativeYValues(),this.webAssemblyContext)},F.prototype.validateAnimationVectors=function(){var I=this.xInitialAnimationValues.size();if(this.yInitialAnimationValuesArray.some(function(V){return V.size()!==I})||I!==this.xFinalAnimationValues.size()||this.yFinalAnimationValuesArray.some(function(V){return V.size()!==I}))throw Error("initialAnimationValues and finalAnimationValues must have the same length")},F.prototype.updateAnimationProperties=function(I,V){var z=this;if(V.isOnStartAnimation)this.yFinalAnimationValuesArray.forEach(function(H,U){return V.calculateAnimationValues(z.webAssemblyContext,H,z.getNativeYValues(U),I)});else if(V.isDataSeriesAnimation){V.calculateDataSeriesAnimationValues(this.webAssemblyContext,this.xInitialAnimationValues,this.xFinalAnimationValues,this.getNativeXValues(),I);for(var G=0;G<this.arrayCount;G++)V.calculateDataSeriesAnimationValues(this.webAssemblyContext,this.yInitialAnimationValuesArray[G],this.yFinalAnimationValuesArray[G],this.getNativeYValues(G),I)}},F.prototype.isUsedForYRange=function(I){var V=this.valueNames.indexOf(I);return V>=0?this.includeInYRange[V]:!1},F.prototype.setUsedForYRange=function(I,V){var z=this.valueNames.indexOf(I);z>=0&&(this.includeInYRange[z]=V)},F.prototype.toJSON=function(I){I===void 0&&(I=!1);var V=this.getOptions(I);return{type:this.type,options:V}},Object.defineProperty(F.prototype,"changeCount",{get:function(){return this.changeCountProperty},enumerable:!1,configurable:!0}),F.prototype.getOptions=function(I){I===void 0&&(I=!1);var V=i({id:this.id,containsNaN:this.containsNaN,isSorted:this.isSorted,dataIsSortedInX:this.isSorted,dataEvenlySpacedInX:this.isEvenlySpaced,dataSeriesName:this.dataSeriesName,fifoCapacity:this.fifoCapacity,fifoSweeping:this.fifoSweeping,fifoSweepingGap:this.fifoSweepingGap,fifoStartIndex:this.fifoSweeping?this.fifoStartIndex:0,capacity:this.capacity,metadata:void 0,arrayCount:this.arrayCount,valueNames:this.valueNames,includeInYRange:this.includeInYRange,xValues:void 0,yValues:void 0},this.dataIds);return V.metadata=I?void 0:this.metadataProperty,V},F.prototype.toPointSeries=function(I,V,z){return new E.BasePointSeriesWrapped(this)},F.prototype.findIndex=function(I,V){var z,G;if(V===void 0&&(V=d.ESearchMode.Nearest),this.count()===0)return-1;var H=(G=(z=this.dataDistributionCalculator)===null||z===void 0?void 0:z.isSortedAscending)!==null&&G!==void 0?G:!1,U=H?(0,d.convertSearchMode)(this.webAssemblyContext,V):this.webAssemblyContext.SCRTFindIndexSearchMode.Exact;return this.webAssemblyContext.NumberUtil.FindIndex(this.xValues,I,U,H)},F.prototype.validateIndex=function(I,V){if(Math.round(I)!==I)throw Error("Index must be an integer");var z=V??"Index is out of range";if(I<0||I>=this.count())throw new Error(z)},F.prototype.setMetadataAt=function(I,V){if(V)if(this.validateIndex(I),this.fillMetadataIfUndefined(),this.fifoCapacity){var z=(this.xValues.getStartIndex()+I)%this.fifoCapacity;this.metadataProperty[z]=V}else this.metadataProperty[I]=V},F.prototype.appendMetadata=function(I){if(!I)if(this.metadataGeneratorProperty)I=this.metadataGeneratorProperty.getSingleMetadata();else return;this.fillMetadataIfUndefined(),this.fifoCapacity&&this.count()===this.fifoCapacity?this.metadataProperty[this.xValues.getStartIndex()]=I:this.metadataProperty.push(I)},F.prototype.appendMetadataRange=function(I,V){var z=this;if(!I)if(this.metadataGeneratorProperty)I=Array(V).fill(1).map(function(U){return z.metadataGeneratorProperty.getSingleMetadata()});else return;if(this.fillMetadataIfUndefined(),this.fifoCapacity)(0,p.appendRangeFifo)(I,this.metadataProperty,this.fifoCapacity,this.xValues.getStartIndex());else{var G=this.metadataProperty.length;this.metadataProperty.length+=V;for(var H=0;H<V;++H)this.metadataProperty[G+H]=I[H]}},F.prototype.insertMetadata=function(I,V){if(!V)if(this.metadataGeneratorProperty)V=this.metadataGeneratorProperty.getSingleMetadata();else return;this.fillMetadataIfUndefined(),this.metadataProperty.splice(I,0,V)},F.prototype.insertMetadataRange=function(I,V){var z=this;if(!V)if(this.metadataGeneratorProperty)V=Array(length).fill(1).map(function(U){return z.metadataGeneratorProperty.getSingleMetadata()});else return;this.fillMetadataIfUndefined();var G=this.metadataProperty.slice(0,I),H=this.metadataProperty.slice(I);this.metadataProperty=G.concat(V,H)},F.prototype.removeMetadataAt=function(I){this.metadataProperty&&this.metadataProperty.splice(I,1)},F.prototype.removeMetadataRange=function(I,V){this.metadataProperty&&this.metadataProperty.splice(I,V)},F.prototype.setMetadata=function(I){this.metadataProperty=I},F.prototype.getXValues=function(I){var V;switch(I){case P.EDataSeriesValueType.FinalAnimationValues:V=this.xFinalAnimationValues;break;case P.EDataSeriesValueType.InitialAnimationValues:V=this.xInitialAnimationValues;break;default:V=this.xValues}return V},F.prototype.getYValuesArray=function(I){var V;switch(I){case P.EDataSeriesValueType.FinalAnimationValues:V=this.yFinalAnimationValuesArray;break;case P.EDataSeriesValueType.InitialAnimationValues:V=this.yInitialAnimationValuesArray;break;default:V=this.yValuesArray}return V},F.prototype.throwIfFifo=function(I){if(this.fifoCapacity)throw new Error("".concat(I," is not supported in fifo mode"))},F.prototype.reserve=function(I){if(this.fifoCapacity)throw new Error("Resizing a fifo dataSeries is not currently supported.");s.Guard.argumentIsRealInteger(I,"capacity"),this.xValues.reserve(I),this.yValuesArray.forEach(function(V){return V.reserve(I)})},F.prototype.calculateInitialCapacity=function(I){var V,z,G;return Math.max((V=I==null?void 0:I.capacity)!==null&&V!==void 0?V:0,(G=(z=I==null?void 0:I.xValues)===null||z===void 0?void 0:z.length)!==null&&G!==void 0?G:0)},F.prototype.fillMetadataIfUndefined=function(){if(this.metadataProperty===void 0){var I=this.count();this.metadataProperty=Array(I).fill(void 0)}},F.prototype.getYValues=function(I,V){V===void 0&&(V=0);var z;switch(I){case P.EDataSeriesValueType.FinalAnimationValues:z=this.yFinalAnimationValuesArray[V];break;case P.EDataSeriesValueType.InitialAnimationValues:z=this.yInitialAnimationValuesArray[V];break;default:z=this.getNativeYValues(V)}return z},F})(r.DeletableEntity);t.BaseDataSeries=A;var R=function(D,F,I,V,z,G){z===void 0&&(z=d.ESearchMode.RoundDown),G===void 0&&(G=d.ESearchMode.RoundUp);var H=F.size(),U=new l.NumberRange(0,-1);if(H>0){if(!V)return new l.NumberRange(0,H-1);var k=function(Y){switch(Y){case d.ESearchMode.Exact:return D.SCRTFindIndexSearchMode.Exact;case d.ESearchMode.Nearest:return D.SCRTFindIndexSearchMode.Nearest;case d.ESearchMode.RoundDown:return D.SCRTFindIndexSearchMode.RoundDown;case d.ESearchMode.RoundUp:return D.SCRTFindIndexSearchMode.RoundUp}},X=D.NumberUtil.FindIndex(F,I.min,k(z),!0),W=D.NumberUtil.FindIndex(F,I.max,k(G),!0);U=new l.NumberRange(X,W)}return U};t.getIndicesRange=R;var M=function(D,F,I,V,z,G,H,U,k,X){k===void 0&&(k=d.ESearchMode.RoundUp),X===void 0&&(X=d.ESearchMode.RoundDown);var W=F.size();if(W===1){var Y=I.get(0);return new l.NumberRange(Y,Y)}var te=0,oe=W;if(G)te=Math.max(Math.floor(V.min),0),oe=Math.min(Math.ceil(V.max),W-1);else{var de=(0,t.getIndicesRange)(D,F,V,H,k,X);te=Math.max(Math.floor(de.min),0),oe=Math.min(Math.ceil(de.max),W-1)}if(!(oe<te)){var ge;try{return ge=D.NumberUtil.MinMaxWithIndex(I,te,oe-te+1,U),!(0,m.isRealNumber)(ge.minD)||!(0,m.isRealNumber)(ge.maxD)?void 0:new l.NumberRange(ge.minD,ge.maxD)}finally{(0,o.deleteSafe)(ge)}}};t.getWindowedYRange=M})(XT)),XT}var ZT={},nF={},Vge;function Am(){if(Vge)return nF;Vge=1,Object.defineProperty(nF,"__esModule",{value:!0}),nF.SeriesInfo=void 0;var t=$i(),e=hn(),i=(function(){function n(r,o){this.renderableSeries=r,this.seriesName=r.seriesName,this.stroke=r.stroke,this.dataSeriesType=o.dataSeriesType,this.dataSeriesIndex=o.dataSeriesIndex,this.isHit=o.isHit,this.isWithinDataBounds=o.isWithinDataBounds,this.hitTestPointValues=o.hitTestPointValues,this.xValue=o.isCategoryAxis?o.xCategoryValue:o.xValue,this.point2xValue=o.point2xValue,this.yValue=o.yValue,this.point2yValue=o.point2yValue,this.xCoordinate=o.xCoord,this.yCoordinate=o.yCoord,this.point2xCoordinate=o.point2xCoord,this.point2yCoordinate=o.point2yCoord,this.pointMetadata=o.metadata,this.point2metadata=o.point2metadata,this.distance=o.distance,r.type===e.ESeriesType.ColumnSeries?this.fill=r.fill:r.type===e.ESeriesType.MountainSeries?this.fill=r.fill:r.type===e.ESeriesType.BandSeries&&(this.fill=r.fill),this.hitTestInfo=o}return Object.defineProperty(n.prototype,"isVisible",{get:function(){return this.renderableSeries.isVisible},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"formattedYValue",{get:function(){return this.getYCursorFormattedValue(this.yValue)},enumerable:!1,configurable:!0}),Object.defineProperty(n.prototype,"formattedXValue",{get:function(){return this.getXCursorFormattedValue(this.xValue)},enumerable:!1,configurable:!0}),n.prototype.getYCursorFormattedValue=function(r){return this.renderableSeries.yAxis.labelProvider.formatCursorLabel(r)},n.prototype.getXCursorFormattedValue=function(r){return this.renderableSeries.xAxis.labelProvider.formatCursorLabel(r)},n.prototype.equals=function(r){return r?r&&this.renderableSeries.id===r.renderableSeries.id&&this.isHit===r.isHit&&t.Point.isEqual(this.hitTestPointValues,r.hitTestPointValues)&&this.formattedYValue===r.formattedYValue&&this.formattedXValue===r.formattedXValue&&this.pointMetadata===r.pointMetadata:!1},n.prototype.getValuesWithLabels=function(r,o,a,s){var l=[];return r&&l.push(r),l},n.prototype.concatValueWithLabel=function(r,o){return"".concat(o,": ").concat(r)},n.prototype.concatTwoValuesWithLabels=function(r,o,a,s){if(a){var l=s??"Y";return"".concat(a,": ").concat(r," ").concat(l,": ").concat(o)}else{var l=s?"".concat(s,": "):"";return"".concat(l).concat(o)}},n})();return nF.SeriesInfo=i,nF}var Hge;function vFe(){if(Hge)return ZT;Hge=1;var t=ZT&&ZT.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(ZT,"__esModule",{value:!0}),ZT.BoxPlotSeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=this,l;return s=n.call(this,o,a)||this,((l=a.yValues)===null||l===void 0?void 0:l.length)===5&&(s.max=a.yValues[0],s.upper=a.yValues[1],s.median=a.yValues[2],s.lower=a.yValues[3],s.minimum=a.yValues[4]),s}return Object.defineProperty(r.prototype,"formattedMaxValue",{get:function(){return this.getYCursorFormattedValue(this.max)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedUpperValue",{get:function(){return this.getYCursorFormattedValue(this.upper)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedMedianValue",{get:function(){return this.getYCursorFormattedValue(this.median)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedLowerValue",{get:function(){return this.getYCursorFormattedValue(this.lower)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedMinimumValue",{get:function(){return this.getYCursorFormattedValue(this.minimum)},enumerable:!1,configurable:!0}),r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return a&&u.push(this.concatValueWithLabel(this.formattedXValue,a)),u.push(this.concatValueWithLabel(this.formattedMaxValue,"Max")),u.push(this.concatValueWithLabel(this.formattedUpperValue,"Upper")),u.push(this.concatValueWithLabel(this.formattedMedianValue,"Median")),u.push(this.concatValueWithLabel(this.formattedLowerValue,"Lower")),u.push(this.concatValueWithLabel(this.formattedMinimumValue,"Minimum")),u},r})(e.SeriesInfo);return ZT.BoxPlotSeriesInfo=i,ZT}var JT={},Uge;function yFe(){if(Uge)return JT;Uge=1;var t=JT&&JT.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(JT,"__esModule",{value:!0}),JT.HeatmapSeriesInfo=void 0;var e=Fg(),i=Du(),n=Am(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.xIndex=l.heatmapXIndex,u.yIndex=l.heatmapYIndex,u.zValue=l.zValue,u.color=void 0,u}return Object.defineProperty(a.prototype,"formattedZValue",{get:function(){var s=this.renderableSeries;return s?s.zLabelProvider.formatCursorLabel(this.zValue):(0,i.formatNumber)(this.zValue,e.ENumericFormat.Decimal,2)},enumerable:!1,configurable:!0}),a.prototype.getValuesWithLabels=function(s,l,u,c){var d=o.prototype.getValuesWithLabels.call(this,s,l,u,c);return l&&d.push(this.concatValueWithLabel(this.formattedXValue,l)),u&&d.push(this.concatValueWithLabel(this.formattedYValue,u)),this.zValue!==null&&this.zValue!==void 0&&d.push(this.concatValueWithLabel(this.formattedZValue,"Z")),d},a})(n.SeriesInfo);return JT.HeatmapSeriesInfo=r,JT}var QT={},zge;function mFe(){if(zge)return QT;zge=1;var t=QT&&QT.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(QT,"__esModule",{value:!0}),QT.HlcSeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=n.call(this,o,a)||this;return s.highValue=a.highValue,s.lowValue=a.lowValue,s.closeValue=a.closeValue,s}return Object.defineProperty(r.prototype,"formattedHighValue",{get:function(){return this.getYCursorFormattedValue(this.highValue)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedLowValue",{get:function(){return this.getYCursorFormattedValue(this.lowValue)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedCloseValue",{get:function(){return this.getYCursorFormattedValue(this.closeValue)},enumerable:!1,configurable:!0}),r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return a&&u.push(this.concatValueWithLabel(this.formattedXValue,a)),u.push(this.concatValueWithLabel(this.formattedHighValue,"High")),u.push(this.concatValueWithLabel(this.formattedLowValue,"Low")),u},r})(e.SeriesInfo);return QT.HlcSeriesInfo=i,QT}var e1={},$ge;function bFe(){if($ge)return e1;$ge=1;var t=e1&&e1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(e1,"__esModule",{value:!0}),e1.OhlcSeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=n.call(this,o,a)||this;return s.openValue=a.openValue,s.highValue=a.highValue,s.lowValue=a.lowValue,s.closeValue=a.closeValue,s}return Object.defineProperty(r.prototype,"formattedOpenValue",{get:function(){return this.getYCursorFormattedValue(this.openValue)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedHighValue",{get:function(){return this.getYCursorFormattedValue(this.highValue)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedLowValue",{get:function(){return this.getYCursorFormattedValue(this.lowValue)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formattedCloseValue",{get:function(){return this.getYCursorFormattedValue(this.closeValue)},enumerable:!1,configurable:!0}),r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return a&&u.push(this.concatValueWithLabel(this.formattedXValue,a)),u.push(this.concatValueWithLabel(this.formattedOpenValue,"Open")),u.push(this.concatValueWithLabel(this.formattedHighValue,"Highest")),u.push(this.concatValueWithLabel(this.formattedLowValue,"Lowest")),u.push(this.concatValueWithLabel(this.formattedCloseValue,"Close")),u},r})(e.SeriesInfo);return e1.OhlcSeriesInfo=i,e1}var t1={},Wge;function SFe(){if(Wge)return t1;Wge=1;var t=t1&&t1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(t1,"__esModule",{value:!0}),t1.XySeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){return n.call(this,o,a)||this}return r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return u.push(this.concatTwoValuesWithLabels(this.formattedXValue,this.formattedYValue,a,s)),u},r})(e.SeriesInfo);return t1.XySeriesInfo=i,t1}var r1={},Gge;function _Fe(){if(Gge)return r1;Gge=1;var t=r1&&r1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(r1,"__esModule",{value:!0}),r1.XyySeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=n.call(this,o,a)||this;return s.isFirstSeries=!0,s.y1Value=a.y1Value,s.point2y1Value=a.point2y1Value,s.y1Coordinate=a.y1Coord,s.point2y1Coordinate=a.point2y1Coord,s}return Object.defineProperty(r.prototype,"formattedY1Value",{get:function(){return this.getYCursorFormattedValue(this.y1Value)},enumerable:!1,configurable:!0}),r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return l?this.isFirstSeries?u.push(this.concatTwoValuesWithLabels(this.formattedXValue,this.formattedYValue,a,s)):u.push(this.concatTwoValuesWithLabels(this.formattedXValue,this.formattedY1Value,a,s)):(u.push(this.concatValueWithLabel(this.formattedXValue,"X")),u.push(this.concatValueWithLabel(this.formattedYValue,"Y")),u.push(this.concatValueWithLabel(this.formattedY1Value,"Y1"))),u},r})(e.SeriesInfo);return r1.XyySeriesInfo=i,r1}var i1={},Yge;function PFe(){if(Yge)return i1;Yge=1;var t=i1&&i1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(i1,"__esModule",{value:!0}),i1.XyzSeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=n.call(this,o,a)||this;return s.zValue=a.zValue,s}return Object.defineProperty(r.prototype,"formattedZValue",{get:function(){return this.getYCursorFormattedValue(this.zValue)},enumerable:!1,configurable:!0}),r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return l?(u.push(this.concatTwoValuesWithLabels(this.formattedXValue,this.formattedYValue,a,s)),u.push(this.concatValueWithLabel(this.formattedZValue,"Z"))):(u.push(this.concatValueWithLabel(this.formattedXValue,"X")),u.push(this.concatValueWithLabel(this.formattedYValue,"Y")),u.push(this.concatValueWithLabel(this.formattedZValue,"Z"))),u},r})(e.SeriesInfo);return i1.XyzSeriesInfo=i,i1}var n1={},qge;function DI(){if(qge)return n1;qge=1;var t=n1&&n1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(n1,"__esModule",{value:!0}),n1.XyPointSeriesWrapped=void 0;var e=zi(),i=wm(),n=Yo(),r=(function(o){t(a,o);function a(s,l,u){var c=o.call(this,s,[l],u,[n.EValueName.Y])||this;return c.type=e.EDataSeriesType.Xy,c}return a})(i.BasePointSeriesWrapped);return n1.XyPointSeriesWrapped=r,n1}var o1={},oF={},Xge;function CFe(){if(Xge)return oF;Xge=1,Object.defineProperty(oF,"__esModule",{value:!0}),oF.hashUtils=void 0;var t=function(o){return o.split("").reduce(function(a,s){return a=(a<<5)-a+s.charCodeAt(0),a&a},0)},e=function(o){var a=JSON.stringify(o);return t(a)},i=function(o){return t(o===!1?"0":o===!0?"1":"-1")},n=function(o){var a=o.toString(10);return t(a)},r=function(o){return o.reduce(function(a,s){return a*397^s},0)};return oF.hashUtils={generateHash:t,generateObjectHash:e,generateBooleanHash:i,generateNumberHash:n,generateCombinedHash:r},oF}var d9={},Kge;function Om(){return Kge||(Kge=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EResamplingMode=void 0,(function(e){e.None="None",e.MinMax="MinMax",e.Mid="Mid",e.Max="Max",e.Min="Min",e.MinMaxWithUnevenSpacing="MinMaxWithUnevenSpacing",e.Auto="Auto",e.MinOrMax="MinOrMax"})(t.EResamplingMode||(t.EResamplingMode={}))})(d9)),d9}var aF={},Zge;function Ore(){if(Zge)return aF;Zge=1,Object.defineProperty(aF,"__esModule",{value:!0}),aF.ResamplingParams=void 0;var t=tR(),e=(function(){function i(n,r,o){if(this.zeroLineY=0,this.precision=0,this.enableExperimentalResampling=!1,this.fifoCapacity=0,this.fifoStartIndex=0,r){var a=r.dataSeries;this.resamplingMode=r.resamplingMode,this.precision=r.resamplingPrecision,o&&(this.indexesRange=r.getIndicesRange(o.visibleRange,o.isCategoryAxis),this.isCategoryAxis=o.isCategoryAxis,this.isXAxisAutoRanged=o.autoRange===t.EAutoRange.Always,this.xVisibleRange=o.visibleRange,this.viewportSize=o.isVerticalChart?n.height:n.width),a&&(this.dataHasNaN=a==null?void 0:a.dataDistributionCalculator.containsNaN,this.dataEvenlySpaced=a==null?void 0:a.isEvenlySpaced,this.fifoCapacity=a.fifoCapacity,this.fifoStartIndex=a.fifoStartIndex,this.dataIsFifo=a.fifoCapacity>0&&!a.fifoSweeping)}}return i.prototype.clone=function(n){var r,o,a,s,l,u,c,d,f,h,p,g,v,y,m=new i(void 0,void 0,void 0);return m.zeroLineY=(r=n==null?void 0:n.zeroLineY)!==null&&r!==void 0?r:this.zeroLineY,m.precision=(o=n==null?void 0:n.precision)!==null&&o!==void 0?o:this.precision,m.xVisibleRange=(a=n==null?void 0:n.xVisibleRange)!==null&&a!==void 0?a:this.xVisibleRange,m.indexesRange=(s=n==null?void 0:n.indicesRange)!==null&&s!==void 0?s:this.indexesRange,m.viewportSize=(l=n==null?void 0:n.viewportSize)!==null&&l!==void 0?l:this.viewportSize,m.isCategoryAxis=(u=n==null?void 0:n.isCategoryAxis)!==null&&u!==void 0?u:this.isCategoryAxis,m.isXAxisAutoRanged=(c=n==null?void 0:n.isXAxisAutoRanged)!==null&&c!==void 0?c:this.isXAxisAutoRanged,m.resamplingMode=(d=n==null?void 0:n.resamplingMode)!==null&&d!==void 0?d:this.resamplingMode,m.enableExperimentalResampling=(f=n==null?void 0:n.enableExperimentalResampling)!==null&&f!==void 0?f:this.enableExperimentalResampling,m.dataHasNaN=(h=n==null?void 0:n.dataHasNaN)!==null&&h!==void 0?h:this.dataHasNaN,m.dataEvenlySpaced=(p=n==null?void 0:n.dataEvenlySpaced)!==null&&p!==void 0?p:this.dataEvenlySpaced,m.fifoCapacity=(g=n.fifoCapacity)!==null&&g!==void 0?g:this.fifoCapacity,m.fifoStartIndex=(v=n.fifoStartIndex)!==null&&v!==void 0?v:this.fifoStartIndex,m.dataIsFifo=(y=n.dataIsFifo)!==null&&y!==void 0?y:this.dataIsFifo,m},i})();return aF.ResamplingParams=e,aF}var Jge;function Dre(){if(Jge)return o1;Jge=1;var t=o1&&o1.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(o1,"__esModule",{value:!0}),o1.ExtremeResamplerHelper=void 0;var e=fo(),i=Br(),n=ci(),r=CFe(),o=Om(),a=Ore(),s=(function(l){t(u,l);function u(c){var d=l.call(this)||this;return d.isDeleted=!1,d.nativeMergeIndexParams=new c.SCRTDoubleResamplerMergeIndicesParams,d.wasmContext=c,d.nativeResampler=new d.wasmContext.SCRTDoubleResampler,d.xInput=new d.wasmContext.SCRTXvaluesProvider,d.nativeArgs=new d.wasmContext.ResamplingArgs,d.output=new d.wasmContext.SCRTDoubleArraysXyResampleOutput,d}return u.resampleSeries=function(c,d,f){if(!d.supportsResampling)return{pointSeries:d.toPointSeries(),renderableSeries:d,indicesRange:d.isStacked?void 0:d.getIndicesRange(c.visibleRange,c.isCategoryAxis),resamplingHash:void 0};var h=d.getResamplingParams(),p=d.getCurrentRenderPassData();if(!h||h.resampleRequired&&!p){if(h=new a.ResamplingParams(f,d,c),!d.needsResampling(h))return{pointSeries:d.toPointSeries(),renderableSeries:d,indicesRange:h.indexesRange,resamplingHash:void 0};var g=u.calculateResamplingHash(d,h),v=d.getCurrentRenderPassData(),y=!!(v&&v.resamplingHash===g),m=y?v.pointSeries:d.toPointSeries(h);return{pointSeries:m,renderableSeries:d,indicesRange:h.indexesRange,resamplingHash:g}}else return h.resampleRequired?{pointSeries:p.pointSeries,renderableSeries:d,indicesRange:h.indexesRange,resamplingHash:h.hash}:{pointSeries:d.toPointSeries(),renderableSeries:d,indicesRange:h.indexesRange,resamplingHash:void 0}},u.calculateResamplingHash=function(c,d){var f=[],h=c.dataSeries;if(h){var p=r.hashUtils.generateHash(h.id);f.push(p);var g=r.hashUtils.generateNumberHash(h.count());f.push(g);var v=r.hashUtils.generateBooleanHash(h.dataDistributionCalculator.isSortedAscending);f.push(v);var y=r.hashUtils.generateNumberHash(h.changeCount);f.push(y)}var m=r.hashUtils.generateObjectHash(d);return f.push(m),d.hash=r.hashUtils.generateCombinedHash(f),d.hash},u.prototype.needsResampling=function(c,d,f,h){f===void 0&&(f=!0),h===void 0&&(h=!1),f&&this.resetAndFillBasicNativeArgs(c,d);var p=this.nativeResampler.RequiresReduction(this.nativeArgs),g=c.dataIsFifo||p;return(h&&!g||g&&!p)&&(this.nativeArgs.Resampling=this.getNativeResamplingMode(o.EResamplingMode.None)),g},u.prototype.resampleIntoPointSeries=function(c,d,f,h,p,g,v,y,m){if(m===void 0&&(m=!0),this.isDeleted)throw new Error("should not call resampleIntoPointSeries() if deleted");n.Guard.notNull(f,"xDataValues"),n.Guard.notNull(h,"yDataValues"),n.Guard.notNull(f,"xOriginalValues"),n.Guard.notNull(h,"yOriginalValues"),n.Guard.notNull(d,"resamplingParams"),m&&this.resetAndFillBasicNativeArgs(d,f),this.xInput.SetInput(f),this.nativeArgs.ResamplingPrecision=d.precision,this.nativeArgs.ZeroLineY=d.zeroLineY,this.nativeArgs.NewDataPointCount=-1,m===!0&&this.needsResampling(d,f,!1,!0);var b=this.nativeResampler.UpdateIndices(p,this.xInput,h,this.nativeArgs.Resampling,this.nativeArgs);g&&g.resizeFast(b+1),v.resizeFast(b+1),y.resizeFast(b+1),g?this.output.ResetWithIndices(g,v,y):this.output.Reset(v,y),this.nativeResampler.Execute(this.xInput,h,this.output,p,this.nativeArgs.Resampling,this.nativeArgs);var S=p.size();return g&&g.resizeFast(S),v.resizeFast(S),y.resizeFast(S),{OutputSplitIndex:this.output.OutputSplitIndex||this.nativeArgs.OutputSplitIndex}},u.prototype.mergeIndexes=function(c,d,f,h){return this.nativeResampler.MergeIndices(c,d,f,h)},u.prototype.copyValuesByIndexes=function(c,d,f,h,p,g,v,y,m,b,S,_){_===void 0&&(_=0);var C=this.nativeMergeIndexParams;C.SetIndices(c),C.SetXInput(d),C.SetYInput(f),C.SetY1Input(h),C.SetY1Offset(_),C.count=p,C.isCategoryData=g,C.isFifoSweeping=v,C.SetIndicesOut(y),C.SetXOut(m),C.SetYOut(b),C.SetY1Out(S),this.nativeResampler.CopyValuesByIndices(C)},u.prototype.delete=function(){this.isDeleted||((0,i.deleteSafe)(this.nativeResampler),(0,i.deleteSafe)(this.xInput),(0,i.deleteSafe)(this.nativeArgs),(0,i.deleteSafe)(this.output),(0,i.deleteSafe)(this.nativeMergeIndexParams),this.isDeleted=!0,this.wasmContext=void 0)},u.prototype.getNativeResamplingMode=function(c){switch(c){case o.EResamplingMode.Auto:return this.wasmContext.ResamplingMode.Auto;case o.EResamplingMode.Max:return this.wasmContext.ResamplingMode.Max;case o.EResamplingMode.Mid:return this.wasmContext.ResamplingMode.Mid;case o.EResamplingMode.Min:return this.wasmContext.ResamplingMode.Min;case o.EResamplingMode.MinMax:return this.wasmContext.ResamplingMode.MinMax;case o.EResamplingMode.MinOrMax:return this.wasmContext.ResamplingMode.MinOrMax;case o.EResamplingMode.None:return this.wasmContext.ResamplingMode.None;default:throw new Error("Unknown resamplingMode ".concat(c))}},u.prototype.resetAndFillBasicNativeArgs=function(c,d){if(this.nativeArgs.Reset(),this.nativeArgs.Data=this.getDataDistribution(c.dataEvenlySpaced,c.isCategoryAxis),this.nativeArgs.StartIndex=c.indexesRange.min,this.nativeArgs.EndIndex=c.indexesRange.max,this.nativeArgs.MaxXInclusive=c.xVisibleRange.max,this.nativeArgs.MinXInclusive=c.xVisibleRange.min,this.nativeArgs.Resampling=this.getNativeResamplingMode(c.resamplingMode),this.nativeArgs.ViewportWidth=c.viewportSize,this.nativeArgs.FifoCapacity=c.fifoCapacity||0,this.nativeArgs.HasNaN=c.dataHasNaN,this.nativeArgs.IsFifo=c.dataIsFifo,this.nativeArgs.InputBaseIndex=c.fifoStartIndex||0,c.isCategoryAxis)this.nativeArgs.MinXInclusive=c.indexesRange.min,this.nativeArgs.MaxXInclusive=c.indexesRange.max;else if(c.fifoCapacity&&!c.dataIsFifo){var f=d.getRaw(c.indexesRange.min),h=d.getRaw(c.indexesRange.max);this.nativeArgs.MinXInclusive=Math.max(f,c.xVisibleRange.min),this.nativeArgs.MaxXInclusive=Math.min(h,c.xVisibleRange.max)}else{var f=d.get(c.indexesRange.min),h=d.get(c.indexesRange.max);this.nativeArgs.MinXInclusive=Math.max(f,c.xVisibleRange.min),this.nativeArgs.MaxXInclusive=Math.min(h,c.xVisibleRange.max)}},u.prototype.debugParameters=function(c,d){console.log("ResamplingParams:"),console.log(".. zeroLineY: ".concat(c.zeroLineY)),console.log(".. resamplingPrecision: ".concat(c.precision)),console.log(".. xVisibleRange: ".concat(c.xVisibleRange)),console.log(".. indicesRange: ".concat(c.indexesRange)),console.log(".. viewportSize: ".concat(c.viewportSize)),console.log(".. isCategoryAxis: ".concat(c.isCategoryAxis)),console.log(".. isXAxisAutoRanged: ".concat(c.isXAxisAutoRanged)),console.log(".. resamplingMode: ".concat(c.resamplingMode)),console.log(".. enableExperimentalResampling: ".concat(c.enableExperimentalResampling)),console.log(".. dataHasNan: ".concat(c.dataHasNaN)),console.log(".. dataIsFifo: ".concat(c.dataIsFifo)),console.log(".. fifoCapacity: ".concat(c.fifoCapacity)),console.log(".. dataEvenlySpaced: ".concat(c.dataEvenlySpaced)),console.log("native Resampling Args:"),console.log(".. ResamplingData: ".concat(this.debugResamplingDataEnum(d.Data))),console.log(".. StartIndex: ".concat(d.StartIndex)),console.log(".. EndIndex: ".concat(d.EndIndex)),console.log(".. FifoCapacity: ".concat(d.FifoCapacity)),console.log(".. HasNaN: ".concat(d.HasNaN)),console.log(".. IsFifo: ".concat(d.IsFifo)),console.log(".. MaxXInclusive: ".concat(d.MaxXInclusive)),console.log(".. MinXInclusive: ".concat(d.MinXInclusive)),console.log(".. ResamplingMode: ".concat(this.debugResamplingModeEnum(d.Resampling))),console.log(".. ResamplingPrecision: ".concat(d.ResamplingPrecision)),console.log(".. ViewportWidth: ".concat(d.ViewportWidth)),console.log(".. ZeroLineY: ".concat(d.ZeroLineY)),console.log(".. NewDataPointCount: ".concat(d.NewDataPointCount)),console.log(".. InputBaseIndex: ".concat(d.InputBaseIndex))},u.prototype.debugRect=function(c){return"X ".concat(c.x," Y ").concat(c.y," Width ").concat(c.width," Height ").concat(c.height)},u.prototype.debugResamplingDataEnum=function(c){return c===this.wasmContext.ResamplingData.LinearData?"LinearData":c===this.wasmContext.ResamplingData.CategoryData?"CategoryData":c===this.wasmContext.ResamplingData.UnsortedData?"UnsortedData":c===this.wasmContext.ResamplingData.UnevenlySpacedData?"UnevenlySpacedData":"Unknown"},u.prototype.debugResamplingModeEnum=function(c){return c===this.wasmContext.ResamplingMode.MinMax?"MinMax":c===this.wasmContext.ResamplingMode.Auto?"Auto":"Unknown"},u.prototype.getDataDistribution=function(c,d){return d?this.wasmContext.ResamplingData.CategoryData:c?this.wasmContext.ResamplingData.LinearData:this.wasmContext.ResamplingData.UnevenlySpacedData},u})(e.DeletableEntity);return o1.ExtremeResamplerHelper=s,o1}var j0={},a1={},s1={},l1={},sF={},Qge;function Rre(){if(Qge)return sF;Qge=1,Object.defineProperty(sF,"__esModule",{value:!0}),sF.BasePointMarkerStyle=void 0;var t=Ng(),e=(function(){function i(n){var r,o,a;this.width=0,this.height=0,this.type=(r=n==null?void 0:n.type)!==null&&r!==void 0?r:this.type,this.width=(o=n==null?void 0:n.width)!==null&&o!==void 0?o:this.width,this.height=(a=n==null?void 0:n.height)!==null&&a!==void 0?a:this.height}return Object.defineProperty(i.prototype,"isCustomPointMarker",{get:function(){return this.type===t.EPointMarkerType.Sprite},enumerable:!1,configurable:!0}),i})();return sF.BasePointMarkerStyle=e,sF}var eve;function RI(){if(eve)return l1;eve=1;var t=l1&&l1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(l1,"__esModule",{value:!0}),l1.PointMarkerStyle=void 0;var e=Ti(),i=Rre(),n=(function(r){t(o,r);function o(a){var s=this,l,u,c;return s=r.call(this,a)||this,s.strokeThickness=0,s.strokeThickness=(l=a==null?void 0:a.strokeThickness)!==null&&l!==void 0?l:s.strokeThickness,s.stroke=(u=a==null?void 0:a.stroke)!==null&&u!==void 0?u:"#ffffff00",s.fill=(c=a==null?void 0:a.fill)!==null&&c!==void 0?c:"#ffffff00",s}return Object.defineProperty(o.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(a){this.strokeProperty=a,a&&(this.strokeARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeARGB",{get:function(){return this.strokeARGBProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fill",{get:function(){return this.fillProperty},set:function(a){this.fillProperty=a,a&&(this.fillARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillARGB",{get:function(){return this.fillARGBProperty},enumerable:!1,configurable:!0}),o})(i.BasePointMarkerStyle);return l1.PointMarkerStyle=n,l1}var u1={},c1={},tve;function PW(){if(tve)return c1;tve=1;var t=c1&&c1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(c1,"__esModule",{value:!0}),c1.TextureCache=void 0;var e=Br(),i=dW(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.wasmContext=a,s}return Object.defineProperty(o.prototype,"value",{get:function(){return!this.cachedEntity&&this.textureFormat&&(this.cachedEntity=this.create(this.width,this.height,this.textureFormat)),this.cachedEntity},enumerable:!1,configurable:!0}),o.prototype.create=function(a,s,l){return this.cachedEntity&&a===this.width&&s===this.height&&l===this.textureFormat?this.cachedEntity:(this.cachedEntity=(0,e.deleteSafe)(this.cachedEntity),this.width=a,this.height=s,this.textureFormat=l,this.cachedEntity=this.wasmContext.SCRTCreateBitmapTexture(this.width,this.height,l),this.cachedEntity)},o.prototype.resetCache=function(){this.invalidateCache(),this.width=void 0,this.height=void 0,this.textureFormat=void 0},o})(i.BaseCache);return c1.TextureCache=n,c1}var rve;function rR(){if(rve)return u1;rve=1;var t=u1&&u1.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(u1,"__esModule",{value:!0}),u1.CanvasTexture=void 0;var e=Uo(),i=Br(),n=PW(),r=ci(),o=fo(),a=(function(s){t(l,s);function l(u,c,d){var f=s.call(this)||this;f.width=Math.floor(c),f.height=Math.floor(d),r.Guard.isTrue(f.width>0,"CanvasTexture.width must be greater than zero"),r.Guard.isTrue(f.height>0,"CanvasTexture.height must be greater than zero"),e.IS_TEST_ENV||(f.canvas=document.createElement("canvas"),f.canvas.width=f.width,f.canvas.height=f.height),f.wasmContext=u,f.intermediateVector=new f.wasmContext.UIntVector,f.intermediateVector.resize(f.height*f.width,0),f.originalIntermediateVector=new f.wasmContext.UIntVector,f.originalIntermediateVector.resize(f.height*f.width,0);var h=f.wasmContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_A8B8G8R8;return f.tsrTextureCache=new n.TextureCache(u),f.tsrTextureCache.create(f.width,f.height,h),f}return l.prototype.getContext=function(){return this.canvas.getContext("2d",{willReadFrequently:!0})},l.prototype.getTexture=function(){return this.tsrTextureCache.value},l.prototype.clear=function(){this.getContext().clearRect(0,0,this.width,this.height),this.intermediateVector.fill(0),this.originalIntermediateVector.fill(0)},l.prototype.delete=function(){this.intermediateVector=(0,i.deleteSafe)(this.intermediateVector),this.originalIntermediateVector=(0,i.deleteSafe)(this.originalIntermediateVector),this.tsrTextureCache=(0,i.deleteSafe)(this.tsrTextureCache),this.wasmContext=void 0},l.prototype.copyTexture=function(){var u,c=this.width*this.height;if(!this.intermediateVector||this.intermediateVector.size()!==c)throw new Error("CanvasTexture.ts: IntermediateVector size is ".concat((u=this.intermediateVector)===null||u===void 0?void 0:u.size()," and expected ").concat(c));for(var d=this.getContext().getImageData(0,0,this.width,this.height),f=d.data,h=this.width*this.height,p=0;p<h;p++){var g=p*4,v=f[g+3];if(v!==0){var y=f[g],m=f[g+1],b=f[g+2],S=v<<24|y<<16|m<<8|b;this.intermediateVector.set(p,S>>>0),this.originalIntermediateVector.set(p,S>>>0)}}var _=this.tsrTextureCache.value;this.wasmContext.SCRTFillTextureAbgr(_,this.width,this.height,this.intermediateVector)},l.prototype.applyOpacity=function(u){this.wasmContext.SCRTMultiplyColorVectorOpacity(this.originalIntermediateVector,this.intermediateVector,u);var c=this.tsrTextureCache.value;this.wasmContext.SCRTFillTextureAbgr(c,this.width,this.height,this.intermediateVector)},l})(o.DeletableEntity);return u1.CanvasTexture=a,u1}var f9={},ive;function TFe(){return ive||(ive=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.FILL="fill",e.HEIGHT="height",e.IMAGE="image",e.SIZE_TO_IMAGE="size_to_image",e.STROKE="stroke",e.STROKE_THICKNESS="strokeThickness",e.WIDTH="width",e.OPACITY="opacity",e.LAST_POINT_ONLY="lastPointOnly",e.ANTIALIAS="antiAlias"})(t.PROPERTY||(t.PROPERTY={}))})(f9)),f9}var nve;function iR(){if(nve)return s1;nve=1;var t=s1&&s1.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(s1,"__esModule",{value:!0}),s1.BasePointMarker=void 0;var e=Uo(),i=fo(),n=Br(),r=gm(),o=Iu(),a=Xs(),s=RI(),l=Sn(),u=rR(),c=Zi(),d=TFe(),f=(function(h){t(p,h);function p(g,v){var y=this,m,b,S,_,C,P,x,E;return y=h.call(this)||this,y.fillProperty="#5555FF",y.heightProperty=5,y.opacityProperty=1,y.strokeProperty="#3333FF",y.strokeThicknessProperty=1,y.widthProperty=5,y.lastPointOnlyProperty=!1,y.isUpdateSuspended=!1,y.antiAliasProperty=!0,y.webAssemblyContext=g,y.widthProperty=(m=v==null?void 0:v.width)!==null&&m!==void 0?m:y.widthProperty,y.heightProperty=(b=v==null?void 0:v.height)!==null&&b!==void 0?b:y.heightProperty,y.fillProperty=(S=v==null?void 0:v.fill)!==null&&S!==void 0?S:y.fillProperty,y.strokeProperty=(_=v==null?void 0:v.stroke)!==null&&_!==void 0?_:y.strokeProperty,y.strokeThicknessProperty=(C=v==null?void 0:v.strokeThickness)!==null&&C!==void 0?C:y.strokeThicknessProperty,y.opacityProperty=(P=v==null?void 0:v.opacity)!==null&&P!==void 0?P:y.opacityProperty,y.lastPointOnlyProperty=(x=v==null?void 0:v.lastPointOnly)!==null&&x!==void 0?x:y.lastPointOnlyProperty,y.antiAliasProperty=(E=v==null?void 0:v.antiAlias)!==null&&E!==void 0?E:y.antiAliasProperty,o.WebGlRenderContext2D.webGlResourcesRefs.add(y),y}return Object.defineProperty(p.prototype,"fill",{get:function(){return this.fillProperty===a.AUTO_COLOR?"#00000000":this.fillProperty.startsWith(a.AUTO_COLOR)?this.fillProperty.substring(a.AUTO_COLOR.length):this.fillProperty},set:function(g){var v=this.fillProperty;this.fillProperty=g,this.notifyPropertyChanged(d.PROPERTY.FILL,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"stroke",{get:function(){return this.strokeProperty===a.AUTO_COLOR?"#00000000":this.strokeProperty.startsWith(a.AUTO_COLOR)?this.strokeProperty.substring(a.AUTO_COLOR.length):this.strokeProperty},set:function(g){var v=this.strokeProperty;this.strokeProperty=g,this.notifyPropertyChanged(d.PROPERTY.STROKE,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"width",{get:function(){return this.widthProperty},set:function(g){var v=this.widthProperty;this.widthProperty=g,this.notifyPropertyChanged(d.PROPERTY.WIDTH,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"height",{get:function(){return this.heightProperty},set:function(g){var v=this.heightProperty;this.heightProperty=g,this.notifyPropertyChanged(d.PROPERTY.HEIGHT,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(g){var v=this.strokeThicknessProperty;this.strokeThicknessProperty=g,this.notifyPropertyChanged(d.PROPERTY.STROKE_THICKNESS,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"opacity",{get:function(){return this.opacityProperty},set:function(g){var v=this.opacityProperty;this.opacityProperty=g,this.applyOpacity(g),this.notifyPropertyChanged(d.PROPERTY.OPACITY,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"lastPointOnly",{get:function(){return this.lastPointOnlyProperty},set:function(g){var v=this.lastPointOnlyProperty;this.lastPointOnlyProperty=g,this.notifyPropertyChanged(d.PROPERTY.LAST_POINT_ONLY,g,v)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"antiAlias",{get:function(){return this.antiAliasProperty},set:function(g){var v=this.antiAliasProperty;this.antiAliasProperty=g,this.notifyPropertyChanged(d.PROPERTY.ANTIALIAS,g,v)},enumerable:!1,configurable:!0}),p.prototype.getSprite=function(){return this.spriteTextures===void 0&&(this.spriteTextures=this.createCanvasTexture(),this.applyOpacity(this.opacityProperty)),this.spriteTextures.spriteTexture},p.prototype.getStrokeMask=function(){return this.spriteTextures===void 0&&(this.spriteTextures=this.createCanvasTexture(),this.applyOpacity(this.opacityProperty)),this.spriteTextures.strokeMask},p.prototype.getFillMask=function(){return this.spriteTextures===void 0&&(this.spriteTextures=this.createCanvasTexture(),this.applyOpacity(this.opacityProperty)),this.spriteTextures.fillMask},p.prototype.invalidateCache=function(){this.spriteTextures&&((0,n.deleteSafe)(this.spriteTextures.spriteTexture),(0,n.deleteSafe)(this.spriteTextures.strokeMask),(0,n.deleteSafe)(this.spriteTextures.fillMask),this.spriteTextures=void 0)},p.prototype.resetCache=function(){this.invalidateCache(),this.widthProperty=void 0,this.heightProperty=void 0,this.fillProperty=void 0,this.strokeProperty=void 0,this.strokeThicknessProperty=void 0,this.opacityProperty=void 0},p.prototype.delete=function(){var g=this;this.invalidateCache(),o.WebGlRenderContext2D.webGlResourcesRefs.delete(this)},p.prototype.createCanvasTexture=function(){if(e.IS_TEST_ENV)return{spriteTexture:void 0,strokeMask:void 0,fillMask:void 0};var g=c.DpiHelper.PIXEL_RATIO*(this.width+this.strokeThickness)+1,v=c.DpiHelper.PIXEL_RATIO*(this.height+this.strokeThickness)+1,y=new u.CanvasTexture(this.webAssemblyContext,g,v);y.clear(),this.drawSprite(y.getContext(),this.width*c.DpiHelper.PIXEL_RATIO,this.height*c.DpiHelper.PIXEL_RATIO,this.stroke,this.strokeThickness*c.DpiHelper.PIXEL_RATIO,this.fill),y.copyTexture();var m=new u.CanvasTexture(this.webAssemblyContext,g,v);m.clear(),this.drawSprite(m.getContext(),this.width*c.DpiHelper.PIXEL_RATIO,this.height*c.DpiHelper.PIXEL_RATIO,"#ffffffff",this.strokeThickness*c.DpiHelper.PIXEL_RATIO,"#00000000"),m.copyTexture();var b=new u.CanvasTexture(this.webAssemblyContext,g,v);return b.clear(),this.drawSprite(b.getContext(),this.width*c.DpiHelper.PIXEL_RATIO-3,this.height*c.DpiHelper.PIXEL_RATIO-3,"#00000000",0,"#ffffffff"),b.copyTexture(),{spriteTexture:y,strokeMask:m,fillMask:b}},p.prototype.getPointMarkerStyle=function(){return new s.PointMarkerStyle({type:this.type,width:this.width,height:this.height,fill:this.fill,stroke:this.stroke,strokeThickness:this.strokeThickness})},p.prototype.toJSON=function(){var g={fill:this.fill,height:this.height,opacity:this.opacity,stroke:this.stroke,strokeThickness:this.strokeThickness,width:this.width,lastPointOnly:this.lastPointOnly,antiAlias:this.antiAlias};return{type:this.type,options:g}},p.prototype.onDpiChanged=function(g){l.DebugForDpi&&console.log("basePointMarker onDpiChanged Scaling factor = "+g.newValue),this.invalidateCache()},p.prototype.resolveAutoColors=function(g,v,y){if(this.strokeProperty.startsWith(a.AUTO_COLOR)){var m=y.getStrokeColor(g,v,this.webAssemblyContext);this.stroke=a.AUTO_COLOR+this.adjustAutoColor("stroke",m)}if(this.fillProperty.startsWith(a.AUTO_COLOR)){var m=y.getFillColor(g,v,this.webAssemblyContext);this.fill=a.AUTO_COLOR+this.adjustAutoColor("fill",m)}},p.prototype.adjustAutoColor=function(g,v){return v},p.prototype.resumeUpdates=function(){this.isUpdateSuspended=!1,this.recreateSpriteTextures()},p.prototype.suspendUpdates=function(){this.isUpdateSuspended=!0},p.prototype.notifyPropertyChanged=function(g,v,y){v===y||g===d.PROPERTY.OPACITY||this.isUpdateSuspended||this.recreateSpriteTextures()},p.prototype.recreateSpriteTextures=function(){var g,v,y;this.spriteTextures&&((g=this.spriteTextures.spriteTexture)===null||g===void 0||g.delete(),(v=this.spriteTextures.strokeMask)===null||v===void 0||v.delete(),(y=this.spriteTextures.fillMask)===null||y===void 0||y.delete(),this.spriteTextures=void 0),this.spriteTextures=this.createCanvasTexture(),this.invalidateParentCallback&&this.invalidateParentCallback()},p.prototype.applyOpacity=function(g){var v,y,m;this.spriteTextures&&((v=this.spriteTextures.spriteTexture)===null||v===void 0||v.applyOpacity(g),(y=this.spriteTextures.strokeMask)===null||y===void 0||y.applyOpacity(g),(m=this.spriteTextures.fillMask)===null||m===void 0||m.applyOpacity(g))},p})(i.DeletableEntity);return s1.BasePointMarker=f,s1}var ove;function Mre(){if(ove)return a1;ove=1;var t=a1&&a1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(a1,"__esModule",{value:!0}),a1.CrossPointMarker=void 0;var e=Ng(),i=iR(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this,a,s)||this;return l.type=e.EPointMarkerType.Cross,l}return o.prototype.drawSprite=function(a,s,l,u,c,d){if(c>0){a.strokeStyle=u,a.lineWidth=c;var f=a.canvas.width/2,h=a.canvas.height/2,p=l/2,g=s/2;a.beginPath(),a.moveTo(f,h-p),a.lineTo(f,h+p),a.stroke(),a.beginPath(),a.moveTo(f-g,h),a.lineTo(f+g,h),a.stroke()}},o})(i.BasePointMarker);return a1.CrossPointMarker=n,a1}var d1={},ave;function MI(){if(ave)return d1;ave=1;var t=d1&&d1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(d1,"__esModule",{value:!0}),d1.EllipsePointMarker=void 0;var e=Ng(),i=iR(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this,a,s)||this;return l.type=e.EPointMarkerType.Ellipse,l}return o.prototype.drawSprite=function(a,s,l,u,c,d){var f=a.canvas.width/2,h=a.canvas.height/2,p=c/2,g=s/2-p<0?0:s/2-p,v=l/2-p<0?0:l/2-p;a.fillStyle=d,a.ellipse(f,h,g,v,0,0,2*Math.PI,!1),a.fill(),c>0&&(a.strokeStyle=u,a.lineWidth=c,a.stroke())},o})(i.BasePointMarker);return d1.EllipsePointMarker=n,d1}var f1={},h1={},sve;function Lre(){if(sve)return h1;sve=1;var t=h1&&h1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(h1,"__esModule",{value:!0}),h1.CustomPointMarkerStyle=void 0;var e=Rre(),i=(function(n){t(r,n);function r(o){var a=this,s;return a=n.call(this,o)||this,a.image=(s=o==null?void 0:o.image)!==null&&s!==void 0?s:a.image,a}return r})(e.BasePointMarkerStyle);return h1.CustomPointMarkerStyle=i,h1}var lve;function kre(){if(lve)return f1;lve=1;var t=f1&&f1.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(f1,"__esModule",{value:!0}),f1.SpritePointMarker=void 0;var e=Ng(),i=Lre(),n=iR(),r=TFe(),o=(function(a){t(s,a);function s(l,u){var c=a.call(this,l,u)||this;return c.type=e.EPointMarkerType.Sprite,c.image=u==null?void 0:u.image,u!=null&&u.width&&(c.width=u.width),u!=null&&u.height&&(c.height=u.height),c}return Object.defineProperty(s.prototype,"image",{get:function(){return this.imageProperty},set:function(l){var u=this.imageProperty;this.imageProperty=l,this.imageProperty&&(this.width=this.imageProperty.width,this.height=this.imageProperty.height),this.notifyPropertyChanged(r.PROPERTY.IMAGE,l,u)},enumerable:!1,configurable:!0}),s.prototype.drawSprite=function(l,u,c,d,f,h){var p=l.canvas.width/2,g=l.canvas.height/2,v=this.height/2,y=this.width/2;this.image&&l.drawImage(this.image,p-y,g-v,this.width,this.height)},s.prototype.getPointMarkerStyle=function(){return new i.CustomPointMarkerStyle({type:this.type,width:this.width,height:this.height,image:this.image})},s.prototype.toJSON=function(){var l=a.prototype.toJSON.call(this),u={image:this.image};return Object.assign(l.options,u),l},s})(n.BasePointMarker);return f1.SpritePointMarker=o,f1}var p1={},uve;function Ire(){if(uve)return p1;uve=1;var t=p1&&p1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(p1,"__esModule",{value:!0}),p1.SquarePointMarker=void 0;var e=$i(),i=Ng(),n=iR(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.type=i.EPointMarkerType.Square,u}return a.prototype.drawSprite=function(s,l,u,c,d,f){var h=s.canvas.width/2,p=s.canvas.height/2,g=u/2,v=l/2,y=d/2,m=new e.Point(h-v+y,p-g+y),b=new e.Point(h+v-y,p+g-y);s.fillStyle=f,s.beginPath(),s.moveTo(m.x,m.y),s.lineTo(b.x,m.y),s.lineTo(b.x,b.y),s.lineTo(m.x,b.y),s.closePath(),s.fill(),d>0&&(s.strokeStyle=c,s.lineWidth=d,s.stroke())},a})(n.BasePointMarker);return p1.SquarePointMarker=r,p1}var g1={},cve;function Nre(){if(cve)return g1;cve=1;var t=g1&&g1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(g1,"__esModule",{value:!0}),g1.TrianglePointMarker=void 0;var e=$i(),i=Ng(),n=iR(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.type=i.EPointMarkerType.Triangle,u}return a.prototype.drawSprite=function(s,l,u,c,d,f){var h=s.canvas.width/2,p=s.canvas.height/2,g=u/2,v=l/2,y=d/2,m=new e.Point(h,p-g+y),b=new e.Point(h+v-y,p+g-y),S=new e.Point(h-v+y,p+g-y);s.fillStyle=f,s.beginPath(),s.moveTo(m.x,m.y),s.lineTo(b.x,b.y),s.lineTo(S.x,S.y),s.lineTo(m.x,m.y),s.closePath(),s.fill(),d>0&&(s.strokeStyle=c,s.lineWidth=d,s.stroke())},a})(n.BasePointMarker);return g1.TrianglePointMarker=r,g1}var v1={},dve;function Fre(){if(dve)return v1;dve=1;var t=v1&&v1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(v1,"__esModule",{value:!0}),v1.XPointMarker=void 0;var e=Ng(),i=iR(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this,a,s)||this;return l.type=e.EPointMarkerType.X,l}return o.prototype.drawSprite=function(a,s,l,u,c,d){var f=a.canvas.width/2,h=a.canvas.height/2,p=l/2,g=s/2,v=c/4;c>0&&(a.strokeStyle=u,a.lineWidth=c*1.5,a.beginPath(),a.moveTo(f-g+v,h-p+v),a.lineTo(f+g-v,h+p-v),a.stroke(),a.beginPath(),a.moveTo(f+g-v,h-p+v),a.lineTo(f-g+v,h+p-v),a.stroke())},o})(i.BasePointMarker);return v1.XPointMarker=n,v1}var fve;function $S(){if(fve)return j0;fve=1;var t=j0&&j0.__assign||function(){return t=Object.assign||function(y){for(var m,b=1,S=arguments.length;b<S;b++){m=arguments[b];for(var _ in m)Object.prototype.hasOwnProperty.call(m,_)&&(y[_]=m[_])}return y},t.apply(this,arguments)},e=j0&&j0.__rest||function(y,m){var b={};for(var S in y)Object.prototype.hasOwnProperty.call(y,S)&&m.indexOf(S)<0&&(b[S]=y[S]);if(y!=null&&typeof Object.getOwnPropertySymbols=="function")for(var _=0,S=Object.getOwnPropertySymbols(y);_<S.length;_++)m.indexOf(S[_])<0&&Object.prototype.propertyIsEnumerable.call(y,S[_])&&(b[S[_]]=y[S[_]]);return b};Object.defineProperty(j0,"__esModule",{value:!0}),j0.animationHelpers=void 0;var i=cP(),n=Ng(),r=Ju(),o=Mre(),a=MI(),s=kre(),l=Ire(),u=Nre(),c=Fre(),d=function(y){return y?y.is([i.EAnimationState.Running,i.EAnimationState.Completed]):!0},f=function(y,m){return y.length>0?!0:m?!m.is([i.EAnimationState.Completed]):!1},h=function(y,m,b,S,_){var C=y.update(m);y.animation.isOnStartAnimation&&C===i.EAnimationStateTransition.InitialState_Delayed&&(b(),_(0,y)),(C===i.EAnimationStateTransition.InitialState_Running||!y.animation.isOnStartAnimation&&C===i.EAnimationStateTransition.Delayed_Running)&&b(),y.is([i.EAnimationState.Running,i.EAnimationState.Completed])&&_(y.animationProgress,y),[i.EAnimationStateTransition.Running_Completed,i.EAnimationStateTransition.InitialState_Completed].includes(C)&&y.animation.onCompleted&&y.animation.onCompleted(),C===i.EAnimationStateTransition.Running_Completed&&S()},p=function(y,m){if(m)if(m.type===n.EPointMarkerType.Sprite){var b=m,S=b.type,_=e(b,["type"]);return new s.SpritePointMarker(y,t({},_))}else{var C=m,S=C.type,_=e(C,["type"]);switch(S){case n.EPointMarkerType.Cross:return new o.CrossPointMarker(y,t({},_));case n.EPointMarkerType.Ellipse:return new a.EllipsePointMarker(y,t({},_));case n.EPointMarkerType.X:return new c.XPointMarker(y,t({},_));case n.EPointMarkerType.Square:return new l.SquarePointMarker(y,t({},_));case n.EPointMarkerType.Triangle:return new u.TrianglePointMarker(y,t({},_))}}},g=function(y,m,b){return b<0?y:b>1?m:y+(m-y)*b},v=function(y,m,b){return b<0?y:b>1?m:(0,r.uintArgbColorLerp)(y,m,b)};return j0.animationHelpers={checkCanDraw:d,checkIsAnimationRunning:f,animationUpdate:h,createPointMarker:p,interpolateNumber:g,interpolateColor:v},j0}var h9={},hve;function un(){return hve||(hve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.BOTTOM_CORNER_RADIUS="BOTTOM_CORNER_RADIUS",e.BOX_SERIES_CAP="BOX_SERIES_CAP",e.BOX_SERIES_WHISKERS="BOX_SERIES_WHISKERS",e.BOX_SERIES_MEDIAN="BOX_SERIES_MEDIAN",e.BRUSH_UP="BRUSH_UP",e.BRUSH_DOWN="BRUSH_DOWN",e.COLOR="COLOR",e.COLOR_MAP="COLOR_MAP",e.CONTOUR_DRAWING_MODE="CONTOUR_DRAWING_MODE",e.CONTOUR_MINORS_PER_MAJOR="CONTOUR_MINORS_PER_MAJOR",e.CONTOUR_MINOR_LINE_STYLE="CONTOUR_MINOR_LINE_STYLE",e.CONTOUR_MAJOR_LINE_STYLE="CONTOUR_MAJOR_LINE_STYLE",e.CONTOUR_COLOR_MAP_MODE="CONTOUR_COLOR_MAP_MODE",e.CORNER_RADIUS="CORNER_RADIUS",e.DATA_POINT_WIDTH="dataPointWidth",e.DATA_POINT_WIDTH_MODE="DATA_POINT_WIDTH_MODE",e.DATA_SERIES="dataSeries",e.DEFAULT_Y1="DEFAULT_Y1",e.DRAWING_PROVIDERS="DRAWING_PROVIDERS",e.DRAW_NAN_AS="drawNaNAs",e.DRAW_CONNECTOR="DRAW_CONNECTOR",e.DRAW_WHISKERS="DRAW_WHISKERS",e.EFFECT="EFFECT",e.ENABLE_DRAWING_OPTIMISATIONS="ENABLE_DRAWING_OPTIMISATIONS",e.ERROR_DIRECTION="ERROR_DIRECTION",e.ERROR_MODE="ERROR_MODE",e.FILL="fill",e.FILL_Y1="FILL_Y1",e.FILL_LINEAR_GRADIENT="FILL_LINEAR_GRADIENT",e.FILL_LINEAR_GRADIENT_Y1="FILL_LINEAR_GRADIENT_Y1",e.FILL_VALUES_OUT_OF_RANGE="FILL_VALUES_OUT_OF_RANGE",e.GRADIENT_STOPS="GRADIENT_STOPS",e.HOVERED="HOVERED",e.INTERPOLATION_POINTS="INTERPOLATION_POINTS",e.IS_DIGITAL_LINE="IS_DIGITAL_LINE",e.IS_ONE_HUNDRED_PERCENT="IS_ONE_HUNDRED_PERCENT",e.IS_SELECTED="IS_SELECTED",e.IS_VISIBLE="IS_VISIBLE",e.INTENSITY="INTENSITY",e.LINE_TYPE="LINE_TYPE",e.MAXIMUM="MAXIMUM",e.MINIMUM="MINIMUM",e.OFFSET="OFFSET",e.OPACITY="OPACITY",e.PALETTE_PROVIDER="PALETTE_PROVIDER",e.PARENT_SURFACE="PARENT_SURFACE",e.POINT_MARKER="pointMarker",e.POLYGON_VERTICES="POLYGON_VERTICES",e.RANGE="RANGE",e.RESAMPLING_MODE="RESAMPLING_MODE",e.RESAMPLING_PRECISION="RESAMPLING_PRECISION",e.SERIES_NAME="SERIES_NAME",e.SPACING="SPACING",e.STACKED_GROUP_ID="STACKED_GROUP_ID",e.STROKE="STROKE",e.STROKE_Y1="STROKE_Y1",e.STROKE_DASH_ARRAY="STROKE_DASH_ARRAY",e.STROKE_Y1_DASH_ARRAY="STROKE_Y1_DASH_ARRAY",e.STROKE_DOWN="STROKE_DOWN",e.STROKE_UP="STROKE_UP",e.STROKE_THICKNESS="STROKE_THICKNESS",e.TOP_CORNER_RADIUS="TOP_CORNER_RADIUS",e.TRIANGLE_DRAW_MODE="TRIANGLE_DRAW_MODE",e.STROKE_THICKNESS_Y1="STROKE_THICKNESS_Y1",e.USE_LINEAR_TEXTURE_FILTERING="USE_LINEAR_TEXTURE_FILTERING",e.XAXIS_ID="XAXIS_ID",e.YAXIS_ID="YAXIS_ID",e.ZERO_LINE_Y="ZERO_LINE_Y",e.Z_CONTOUR_START="Z_CONTOUR_START",e.Z_MAX="Z_MAX",e.Z_MIN="Z_MIN",e.Z_OFFSET="Z_OFFSET",e.Z_STEP="Z_STEP",e.Z_MULTIPLIER="Z_MULTIPLIER",e.Z_LABEL_PROVIDER="Z_LABEL_PROVIDER",e.Z_LIMITS="Z_LIMITS",e.SERIES_TEXT_PROVIDER="SERIES_TEXT_PROVIDER",e.CLIPTOYRANGE="CLIPTOYRANGE",e.YRANGEMODE="YRANGEMODE",e.IS_REVERSE_HEIGHT="IS_REVERSE_HEIGHT",e.CUSTOM_TEXTURE_OPTIONS="CUSTOM_TEXTURE_OPTIONS",e.YARRAYFILTER="YARRAYFILTER",e.SURFACE_RENDER_ORDER="SURFACE_RENDER_ORDER",e.RENDER_LAYER="RENDER_LAYER"})(t.PROPERTY||(t.PROPERTY={}))})(h9)),h9}var lF={},p9={},pve;function Xwt(){return pve||(pve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.MARKER_COLOR="MARKER_COLOR",e.SHOWS_ROLLOVER="SHOWS_ROLLOVER",e.TOOLTIP_COLOR="TOOLTIP_COLOR",e.TOOLTIP_DATA_TEMPLATE="TOOLTIP_DATA_TEMPLATE",e.TOOLTIP_TEXT_COLOR="TOOLTIP_TEXT_COLOR",e.TOOLTIP_TITLE="TOOLTIP_TITLE",e.TOOLTIP_SHADOW_COLOR="TOOLTIP_SHADOW_COLOR"})(t.PROPERTY||(t.PROPERTY={}))})(p9)),p9}var gve;function CW(){if(gve)return lF;gve=1,Object.defineProperty(lF,"__esModule",{value:!0}),lF.RolloverModifierRenderableSeriesProps=void 0;var t=Br(),e=Sn(),i=Xwt(),n=(function(){function r(o,a){a===void 0&&(a=!1),this.tooltipLegendOffsetX=20,this.tooltipLegendOffsetY=20,this.showsRolloverProperty=!0,this.tooltipTextColorProperty=e.SciChartSurfaceBase.DEFAULT_THEME.textAnnotationForeground,this.renderableSeries=o,this.isY1=a}return r.copy=function(o,a){a.markerColorProperty=o.markerColor,a.showsRolloverProperty=o.showRollover,a.tooltipColorProperty=o.tooltipColor,a.tooltipDataTemplateProperty=o.tooltipDataTemplate,a.tooltipLabelX=o.tooltipLabelX,a.tooltipLabelY=o.tooltipLabelY,a.tooltipLegendOffsetX=o.tooltipLegendOffsetX,a.tooltipLegendOffsetY=o.tooltipLegendOffsetY,a.tooltipTemplate=o.tooltipTemplate,a.tooltipTextColorProperty=o.tooltipTextColorProperty,a.tooltipTitleProperty=o.tooltipTitle,a.shadowColorProperty=o.shadowColorProperty,a.invalidateParentCallback=o.invalidateParentCallback},r.prototype.setInvalidateParentCallback=function(o){this.invalidateParentCallback=o},Object.defineProperty(r.prototype,"showRollover",{get:function(){return this.showsRolloverProperty},set:function(o){this.showsRolloverProperty=o,this.notifyPropertyChanged(i.PROPERTY.SHOWS_ROLLOVER)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tooltipColor",{get:function(){return this.tooltipColorProperty?this.tooltipColorProperty:this.getRenderableSeriesStroke()?this.getRenderableSeriesStroke():e.SciChartSurfaceBase.DEFAULT_THEME.textAnnotationBackground},set:function(o){this.tooltipColorProperty=o,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tooltipTextColor",{get:function(){return this.tooltipTextColorProperty},set:function(o){this.tooltipTextColorProperty=o,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_TEXT_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tooltipTitle",{get:function(){return this.tooltipTitleProperty},set:function(o){this.tooltipTitleProperty=o,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_TITLE)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"markerColor",{get:function(){return this.markerColorProperty?this.markerColorProperty:this.getRenderableSeriesStroke()?this.getRenderableSeriesStroke():e.SciChartSurfaceBase.DEFAULT_THEME.textAnnotationBackground},set:function(o){this.markerColorProperty=o,this.notifyPropertyChanged(i.PROPERTY.MARKER_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"shadowColor",{get:function(){return this.shadowColorProperty},set:function(o){this.shadowColorProperty=o,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_SHADOW_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(o){this.tooltipDataTemplateProperty=o,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_DATA_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"tooltipLegendTemplate",{get:function(){return this.tooltipLegendTemplateProperty},set:function(o){console.warn("tooltipLegendTemplate property on the RolloverModifierRenderableSeriesProps will be removed in version 2.0, please set tooltipLegendTemplate on the RolloverModifier instead"),this.tooltipLegendTemplateProperty=o},enumerable:!1,configurable:!0}),r.prototype.delete=function(){var o,a;this.rolloverModifier=void 0,!((o=this.marker)===null||o===void 0)&&o.isDeleted||(this.marker=(0,t.deleteSafe)(this.marker)),this.marker=void 0,!((a=this.tooltip)===null||a===void 0)&&a.isDeleted||(this.tooltip=(0,t.deleteSafe)(this.tooltip)),this.tooltip=void 0},r.prototype.notifyPropertyChanged=function(o){this.invalidateParentCallback&&this.invalidateParentCallback()},r.prototype.getRenderableSeriesStroke=function(){if(this.isY1){var o=this.renderableSeries;return o.strokeY1Property}return this.renderableSeries.strokeProperty},r})();return lF.RolloverModifierRenderableSeriesProps=n,lF}var uF={},vve;function xFe(){if(vve)return uF;vve=1,Object.defineProperty(uF,"__esModule",{value:!0}),uF.SeriesHoveredArgs=void 0;var t=(function(){function e(i,n){this.sourceSeries=i,this.hovered=n}return e})();return uF.SeriesHoveredArgs=t,uF}var cF={},yve;function EFe(){if(yve)return cF;yve=1,Object.defineProperty(cF,"__esModule",{value:!0}),cF.SeriesSelectedArgs=void 0;var t=(function(){function e(i,n){this.sourceSeries=i,this.isSelected=n}return e})();return cF.SeriesSelectedArgs=t,cF}var dF={},mve;function wFe(){if(mve)return dF;mve=1,Object.defineProperty(dF,"__esModule",{value:!0}),dF.SeriesVisibleChangedArgs=void 0;var t=(function(){function e(i,n){this.sourceSeries=i,this.isVisible=n}return e})();return dF.SeriesVisibleChangedArgs=t,dF}var bve;function ju(){return bve||(bve=1,(function(t){var e=XN&&XN.__extends||(function(){var ve=function(pe,fe){return ve=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(me,Ce){me.__proto__=Ce}||function(me,Ce){for(var Ue in Ce)Object.prototype.hasOwnProperty.call(Ce,Ue)&&(me[Ue]=Ce[Ue])},ve(pe,fe)};return function(pe,fe){if(typeof fe!="function"&&fe!==null)throw new TypeError("Class extends value "+String(fe)+" is not a constructor or null");ve(pe,fe);function me(){this.constructor=pe}pe.prototype=fe===null?Object.create(fe):(me.prototype=fe.prototype,new me)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.getDataPointWidthAdjustment=t.adjustRangeByStrokeThickness=t.getDelta=t.getDataPointWidth=t.BaseRenderableSeries=void 0;var i=mo(),n=cP(),r=fo(),o=Br(),a=ps(),s=fW(),l=di(),u=Rn(),c=Gf(),d=ga(),f=Vd(),h=Ac(),p=Em(),g=QD(),v=JD(),y=Ng(),m=hn(),b=vs(),S=eC(),_=hl(),C=La(),P=Iu(),x=Bu(),E=vFe(),A=yFe(),R=mFe(),M=bFe(),D=SFe(),F=_Fe(),I=PFe(),V=zi(),z=vS(),G=DI(),H=Dre(),U=Om(),k=Ore(),X=QP(),W=Xs(),Y=Wf(),te=Sn(),oe=Zi(),de=$S(),ge=un(),Ee=CW(),Re=xFe(),Ae=EFe(),Pe=wFe(),we=(function(ve){e(pe,ve);function pe(fe,me){var Ce=this,Ue,Qe,it,xt,wt,$t,Mt,rt,qe,vt,kt,Xe,_t,Ht,Pt,Jt,zt,Bt,Mr,Be,We,dt,Tt,nr;if(Ce=ve.call(this)||this,Ce.isCollection=!1,Ce.isPolar=!1,Ce.rolloverModifierProps=new Ee.RolloverModifierRenderableSeriesProps(Ce),Ce.rolloverModifierProps1=new Ee.RolloverModifierRenderableSeriesProps(Ce,!0),Ce.selected=new a.EventHandler,Ce.hovered=new a.EventHandler,Ce.isVisibleChanged=new a.EventHandler,Ce.animationQueue=[],Ce.paletteProviderProperty=z.DefaultPaletteProvider.createEmpty(),Ce.typeMap=new Map,Ce.opacityProperty=1,Ce.drawingProvidersProperty=[],Ce.strokeThicknessProperty=2,Ce.strokeProperty=te.SciChartSurfaceBase.DEFAULT_THEME.lineSeriesColor,Ce.drawNaNAsProperty=P.ELineDrawMode.DiscontinuousLine,Ce.isVisibleProperty=!0,Ce.isDigitalLineProperty=!1,Ce.resamplingModeProperty=U.EResamplingMode.Auto,Ce.resamplingPrecisionProperty=0,Ce.clipToYRangeProperty=!1,Ce.yRangeModeProperty=S.EYRangeMode.Drawn,Ce.yArrayFilterProperty=void 0,Ce.seriesNameProperty=void 0,Ce.surfaceRenderOrderProperty=void 0,Ce.renderLayerProperty=g.EDefaultRenderLayer.SeriesLayer,Ce.renderOrderProperty=void 0,Ce.isStacked=!1,Ce.webAssemblyContext=fe,Ce.id=(Ue=me==null?void 0:me.id)!==null&&Ue!==void 0?Ue:(0,_.generateGuid)(),Ce.dataSeriesDataChanged=Ce.dataSeriesDataChanged.bind(Ce),Ce.effectPropertyChanged=Ce.effectPropertyChanged.bind(Ce),Ce.invalidateParent=Ce.invalidateParent.bind(Ce),Ce.getDataPointWidth=Ce.getDataPointWidth.bind(Ce),Ce.updateAnimationProperties=Ce.updateAnimationProperties.bind(Ce),Ce.beforeAnimationStart=Ce.beforeAnimationStart.bind(Ce),Ce.afterAnimationComplete=Ce.afterAnimationComplete.bind(Ce),Ce.dataSeries=(Qe=me==null?void 0:me.dataSeries)!==null&&Qe!==void 0?Qe:Ce.dataSeriesProperty,me!=null&&me.pointMarker&&("drawSprite"in me.pointMarker||(me.pointMarker.type===y.EPointMarkerType.Custom?me.pointMarker=(0,i.createType)(d.EBaseType.PointMarker,me.pointMarker.customType,fe,me.pointMarker.options):me.pointMarker=(0,i.createType)(d.EBaseType.PointMarker,me.pointMarker.type,fe,me.pointMarker.options))),Ce.pointMarkerProperty=(it=me==null?void 0:me.pointMarker)!==null&&it!==void 0?it:Ce.pointMarkerProperty,Ce.strokeProperty=(xt=me==null?void 0:me.stroke)!==null&&xt!==void 0?xt:Ce.strokeProperty,Ce.strokeThicknessProperty=(wt=me==null?void 0:me.strokeThickness)!==null&&wt!==void 0?wt:Ce.strokeThicknessProperty,Ce.opacityProperty=($t=me==null?void 0:me.opacity)!==null&&$t!==void 0?$t:Ce.opacityProperty,Ce.xAxisIdProperty=(Mt=me==null?void 0:me.xAxisId)!==null&&Mt!==void 0?Mt:Ce.xAxisIdProperty,Ce.yAxisIdProperty=(rt=me==null?void 0:me.yAxisId)!==null&&rt!==void 0?rt:Ce.yAxisIdProperty,Ce.isVisibleProperty=(qe=me==null?void 0:me.isVisible)!==null&&qe!==void 0?qe:Ce.isVisibleProperty,Ce.isDigitalLineProperty=(vt=me==null?void 0:me.isDigitalLine)!==null&&vt!==void 0?vt:Ce.isDigitalLineProperty,Ce.resamplingModeProperty=(kt=me==null?void 0:me.resamplingMode)!==null&&kt!==void 0?kt:Ce.resamplingModeProperty,Ce.resamplingPrecisionProperty=(Xe=me==null?void 0:me.resamplingPrecision)!==null&&Xe!==void 0?Xe:Ce.resamplingPrecisionProperty,Ce.surfaceRenderOrderProperty=(_t=me==null?void 0:me.surfaceRenderOrder)!==null&&_t!==void 0?_t:Ce.surfaceRenderOrderProperty,Ce.renderLayerProperty=(Ht=me==null?void 0:me.renderLayer)!==null&&Ht!==void 0?Ht:Ce.renderLayerProperty,Ce.renderOrderProperty=(Pt=me==null?void 0:me.renderOrder)!==null&&Pt!==void 0?Pt:Ce.renderOrderProperty,Ce.renderNextToProperty=(Jt=me==null?void 0:me.renderNextTo)!==null&&Jt!==void 0?Jt:Ce.renderNextToProperty,me!=null&&me.effect&&("getNativeEffect"in me.effect||(me.effect=(0,i.createType)(d.EBaseType.ShaderEffect,me.effect.type,fe,me.effect.options))),Ce.effectProperty=me==null?void 0:me.effect,me!=null&&me.paletteProvider&&("onAttached"in me.paletteProvider||(me.paletteProvider.type===v.EPaletteProviderType.Custom?me.paletteProvider=(0,i.createType)(d.EBaseType.PaletteProvider,me.paletteProvider.customType,fe,me.paletteProvider.options):me.paletteProvider=(0,i.createType)(d.EBaseType.PaletteProvider,me.paletteProvider.type,fe,me.paletteProvider.options))),Ce.paletteProviderProperty=(zt=me==null?void 0:me.paletteProvider)!==null&&zt!==void 0?zt:Ce.paletteProviderProperty,Ce.drawNaNAsProperty=(Bt=me==null?void 0:me.drawNaNAs)!==null&&Bt!==void 0?Bt:Ce.drawNaNAsProperty,Ce.hitTestProvider=Ce.newHitTestProvider(),Ce.isSelected=(Mr=me==null?void 0:me.isSelected)!==null&&Mr!==void 0?Mr:!1,Ce.isHovered=(Be=me==null?void 0:me.isHovered)!==null&&Be!==void 0?Be:!1,Ce.clipToYRangeProperty=(We=me==null?void 0:me.clipToYRange)!==null&&We!==void 0?We:Ce.clipToYRangeProperty,Ce.yRangeModeProperty=(dt=me==null?void 0:me.yRangeMode)!==null&&dt!==void 0?dt:Ce.yRangeModeProperty,Ce.yArrayFilterProperty=(Tt=me==null?void 0:me.yArrayFilter)!==null&&Tt!==void 0?Tt:Ce.yArrayFilterProperty,Ce.seriesNameProperty=(nr=me==null?void 0:me.seriesName)!==null&&nr!==void 0?nr:Ce.seriesNameProperty,me!=null&&me.onIsVisibleChanged)if(typeof me.onIsVisibleChanged=="string"){Ce.typeMap.set("onIsVisibleChanged",me.onIsVisibleChanged);var Ar=(0,i.getFunction)(d.EBaseType.OptionFunction,me.onIsVisibleChanged);Ce.isVisibleChanged.subscribe(function(rr){return Ar(rr.sourceSeries,rr.isVisible)})}else{var Qr=me==null?void 0:me.onIsVisibleChanged;Ce.isVisibleChanged.subscribe(function(rr){return Qr(rr.sourceSeries,rr.isVisible)})}if(me!=null&&me.onSelectedChanged)if(typeof me.onSelectedChanged=="string"){Ce.typeMap.set("onSelectedChanged",me.onSelectedChanged);var Si=(0,i.getFunction)(d.EBaseType.OptionFunction,me.onSelectedChanged);Ce.selected.subscribe(function(rr){return Si(rr.sourceSeries,rr.isSelected)})}else{var oi=me==null?void 0:me.onSelectedChanged;Ce.selected.subscribe(function(rr){return oi(rr.sourceSeries,rr.isSelected)})}if(me!=null&&me.onHoveredChanged)if(typeof me.onHoveredChanged=="string"){Ce.typeMap.set("onHoveredChanged",me.onHoveredChanged);var Yr=(0,i.getFunction)(d.EBaseType.OptionFunction,me.onHoveredChanged);Ce.hovered.subscribe(function(rr){return Yr(rr.sourceSeries,rr.hovered)})}else{var vi=me==null?void 0:me.onHoveredChanged;Ce.hovered.subscribe(function(rr){return vi(rr.sourceSeries,rr.hovered)})}return me!=null&&me.animation&&("toJSON"in me.animation||(me.animation.type===c.EAnimationType.Custom?me.animation=(0,i.createType)(d.EBaseType.Animation,me.animation.customType,fe,me.animation.options):me.animation=(0,i.createType)(d.EBaseType.Animation,me.animation.type,fe,me.animation.options))),Ce.onDpiChanged=Ce.onDpiChanged.bind(Ce),Ce.resamplerHelper=new H.ExtremeResamplerHelper(fe),me!=null&&me.dataLabelProvider&&("draw"in me.dataLabelProvider||(me.dataLabelProvider.type===h.EDataLabelProviderType.Custom?me.dataLabelProvider=(0,i.createType)(d.EBaseType.DataLabelProvider,me.dataLabelProvider.customType,fe,me.dataLabelProvider.options):me.dataLabelProvider=(0,i.createType)(d.EBaseType.DataLabelProvider,me.dataLabelProvider.type,fe,me.dataLabelProvider.options))),Ce.dataLabelProviderProperty=me==null?void 0:me.dataLabelProvider,Ce.dataLabelProviderProperty&&Ce.dataLabelProviderProperty.onAttach(fe,Ce),Ce.addDrawingProviders(fe,me),Ce}return pe.prototype.applyTheme=function(fe){var me=this.parentSurface.previousThemeProvider;this.rolloverModifierProps.tooltipTextColor===me.textAnnotationForeground&&(this.rolloverModifierProps.tooltipTextColor=fe.textAnnotationForeground),this.rolloverModifierProps.tooltipColor===me.textAnnotationBackground&&(this.rolloverModifierProps.tooltipColor=fe.textAnnotationBackground),this.rolloverModifierProps.markerColor===me.textAnnotationBackground&&(this.rolloverModifierProps.markerColor=fe.textAnnotationBackground)},Object.defineProperty(pe.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},set:function(fe){this.parentSurfaceProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.PARENT_SURFACE)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"drawingProviders",{get:function(){return this.drawingProvidersProperty},set:function(fe){this.drawingProvidersProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.DRAWING_PROVIDERS)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isSelected",{get:function(){return this.isSelectedProperty},set:function(fe){var me;this.valueChanged(this.isSelectedProperty,fe)&&(this.isSelectedProperty=fe,(me=this.selected)===null||me===void 0||me.raiseEvent(new Ae.SeriesSelectedArgs(this,fe)),this.notifyPropertyChanged(ge.PROPERTY.IS_SELECTED))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isHovered",{get:function(){return this.isHoveredProperty},set:function(fe){var me;this.valueChanged(this.isHoveredProperty,fe)&&(this.isHoveredProperty=fe,(me=this.hovered)===null||me===void 0||me.raiseEvent(new Re.SeriesHoveredArgs(this,fe)),this.notifyPropertyChanged(ge.PROPERTY.HOVERED))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"paletteProvider",{get:function(){return this.paletteProviderProperty},set:function(fe){this.setPaletteProvider(fe)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isDigitalLine",{get:function(){return this.isDigitalLineProperty},set:function(fe){this.isDigitalLineProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.IS_DIGITAL_LINE)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(fe){var me;this.valueChanged(this.isVisibleProperty,fe)&&(this.isVisibleProperty=fe,fe?this.resamplingParams=void 0:(this.rolloverModifierProps.marker&&this.rolloverModifierProps.tooltip&&(this.rolloverModifierProps.marker.suspendInvalidate(),this.rolloverModifierProps.tooltip.suspendInvalidate(),this.rolloverModifierProps.marker.isHidden=!0,this.rolloverModifierProps.tooltip.isHidden=!0,this.rolloverModifierProps.tooltip.x1=void 0,this.rolloverModifierProps.tooltip.y1=void 0),this.type===m.ESeriesType.BandSeries&&this.rolloverModifierProps1.marker&&this.rolloverModifierProps1.tooltip&&(this.rolloverModifierProps1.marker.suspendInvalidate(),this.rolloverModifierProps1.tooltip.suspendInvalidate(),this.rolloverModifierProps1.marker.isHidden=!0,this.rolloverModifierProps1.tooltip.isHidden=!0,this.rolloverModifierProps1.tooltip.x1=void 0,this.rolloverModifierProps1.tooltip.y1=void 0)),(me=this.isVisibleChanged)===null||me===void 0||me.raiseEvent(new Pe.SeriesVisibleChangedArgs(this,fe)),this.notifyPropertyChanged(ge.PROPERTY.IS_VISIBLE))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"pointMarker",{get:function(){return this.pointMarkerProperty},set:function(fe){this.pointMarkerProperty&&(this.pointMarkerProperty.invalidateParentCallback=void 0),this.pointMarkerProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.POINT_MARKER),this.pointMarkerProperty&&(this.pointMarkerProperty.invalidateParentCallback=this.invalidateParent)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"drawNaNAs",{get:function(){return this.drawNaNAsProperty},set:function(fe){this.drawNaNAsProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.DRAW_NAN_AS)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"stroke",{get:function(){return(0,W.stripAutoColor)(this.strokeProperty)},set:function(fe){this.strokeProperty!==fe&&(this.strokeProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(fe){this.strokeThicknessProperty!==fe&&(this.strokeThicknessProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.STROKE_THICKNESS))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"opacity",{get:function(){return this.opacityProperty},set:function(fe){this.opacityProperty!==fe&&(this.opacityProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.OPACITY))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"xAxisId",{get:function(){return this.xAxisIdProperty},set:function(fe){fe!==this.xAxisIdProperty&&(this.xAxisIdProperty=fe,this.xAxisProperty=void 0,this.notifyPropertyChanged(ge.PROPERTY.XAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"xAxis",{get:function(){return this.xAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"yAxis",{get:function(){return this.yAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"yAxisId",{get:function(){return this.yAxisIdProperty},set:function(fe){fe!==this.yAxisIdProperty&&(this.yAxisIdProperty=fe,this.yAxisProperty=void 0,this.notifyPropertyChanged(ge.PROPERTY.YAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"dataSeries",{get:function(){return this.dataSeriesProperty},set:function(fe){var me,Ce;if(this.dataSeriesProperty){var Ue=this.xAxis;Ue&&Ue.isCategoryAxis&&Ue.clearCoordCalcCache()}(me=this.dataSeriesProperty)===null||me===void 0||me.dataChanged.unsubscribe(this.dataSeriesDataChanged),this.dataSeriesProperty=fe,(Ce=this.dataSeriesProperty)===null||Ce===void 0||Ce.dataChanged.subscribe(this.dataSeriesDataChanged),this.notifyPropertyChanged(ge.PROPERTY.DATA_SERIES)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"enableDrawingOptimisations",{get:function(){return this.resamplingModeProperty!==U.EResamplingMode.None},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"effect",{get:function(){return this.effectProperty},set:function(fe){var me,Ce;(me=this.effectProperty)===null||me===void 0||me.propertyChanged.unsubscribe(this.effectPropertyChanged),this.effectProperty=fe,(Ce=this.effectProperty)===null||Ce===void 0||Ce.propertyChanged.subscribe(this.effectPropertyChanged),this.notifyPropertyChanged(ge.PROPERTY.EFFECT)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"resamplingMode",{get:function(){return this.resamplingModeProperty},set:function(fe){this.resamplingModeProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.RESAMPLING_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"resamplingPrecision",{get:function(){return this.resamplingPrecisionProperty},set:function(fe){this.resamplingPrecisionProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.RESAMPLING_PRECISION)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"clipToYRange",{get:function(){return this.clipToYRangeProperty},set:function(fe){this.clipToYRangeProperty!==fe&&(this.clipToYRangeProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.CLIPTOYRANGE))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"yRangeMode",{get:function(){return this.yRangeModeProperty},set:function(fe){this.yRangeModeProperty!==fe&&(this.yRangeModeProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.YRANGEMODE))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"yArrayFilter",{get:function(){return this.yArrayFilterProperty},set:function(fe){this.yArrayFilterProperty!==fe&&(this.yArrayFilterProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.YARRAYFILTER))},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"seriesName",{get:function(){var fe;return(fe=this.seriesNameProperty)!==null&&fe!==void 0?fe:this.getDataSeriesName()},set:function(fe){this.seriesNameProperty!==fe&&(this.seriesNameProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.SERIES_NAME))},enumerable:!1,configurable:!0}),pe.prototype.getSurfaceRenderOrder=function(){var fe,me;return(fe=this.surfaceRenderOrderProperty)!==null&&fe!==void 0?fe:(me=this.parentSurface)===null||me===void 0?void 0:me.getSurfaceRenderOrder()},pe.prototype.setSurfaceRenderOrder=function(fe){this.surfaceRenderOrderProperty!=fe&&(this.surfaceRenderOrderProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.SURFACE_RENDER_ORDER))},pe.prototype.getRenderLayer=function(){if(this.renderLayerProperty===g.EDefaultRenderLayer.SeriesLayer){if(this.isSelected)return g.EDefaultRenderLayer.SelectedSeriesLayer;if(this.isHovered)return g.EDefaultRenderLayer.HoveredSeriesLayer}return this.renderLayerProperty},pe.prototype.setRenderLayer=function(fe){this.renderLayerProperty!=fe&&(this.renderLayerProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.RENDER_LAYER))},pe.prototype.getRenderOrder=function(){return this.renderOrderProperty},pe.prototype.setRenderOrder=function(fe){this.renderOrderProperty!=fe&&(this.renderOrderProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.RENDER_LAYER))},pe.prototype.setRenderNextTo=function(fe,me){me===void 0&&(me=0),fe===void 0?this.renderNextToProperty=void 0:this.renderNextToProperty={renderable:fe,offset:me}},pe.prototype.getRenderNextTo=function(){return this.renderNextToProperty},Object.defineProperty(pe.prototype,"isSpline",{get:function(){return[m.ESeriesType.SplineBandSeries,m.ESeriesType.SplineLineSeries,m.ESeriesType.SplineMountainSeries].includes(this.type)},enumerable:!1,configurable:!0}),pe.prototype.getResamplingParams=function(){return this.resamplingParams},pe.prototype.draw=function(fe,me){var Ce=this,Ue,Qe,it,xt,wt,$t,Mt,rt,qe=C.PerformanceDebugHelper.mark(C.EPerformanceMarkType.DrawSingleSeriesStart,{contextId:this.id,parentContextId:(Ue=this.parentSurface)===null||Ue===void 0?void 0:Ue.id,level:C.EPerformanceDebugLevel.Verbose});if(this.currentRenderPassData=me,(Qe=this.hitTestProvider)===null||Qe===void 0||Qe.update(me),this.canDraw){fe.getNativeContext();var vt=(it=this.parentSurface)===null||it===void 0?void 0:it.seriesViewRect;try{if(fe.pushShaderEffect(this.effect),this.clipToYRange){var kt=me.xCoordinateCalculator,Xe=kt.offset,_t=kt.viewportDimension,Ht=me.yCoordinateCalculator,Pt=Ht.offset,Jt=Ht.viewportDimension;if(me.isVerticalChart){var zt=new u.Rect(vt.x+Pt,vt.y+Xe,Jt,_t);fe.setClipRect(zt)}else{var zt=new u.Rect(vt.x+Xe,vt.y+Pt,_t,Jt);fe.setClipRect(zt)}}this.drawingProviders.forEach(function(Mr){var Be;if(!((Be=Ce.xAxis)===null||Be===void 0)&&Be.isVerticalChart&&vt&&fe.setTranslationRotationAndClip(vt,vt.x,vt.y),Ce.renderDataTransform&&Ce.renderDataTransform.drawingProviders.includes(Mr)){var We=Ce.renderDataTransform.runTransform(me);Mr.draw(fe,We)}else Mr.draw(fe,me)})}finally{this.clipToYRange&&fe.setClipRect(vt),fe.popShaderEffect()}if(this.dataLabelProvider){var Bt=C.PerformanceDebugHelper.mark(C.EPerformanceMarkType.GenerateDataLabelsStart,{contextId:this.id,parentContextId:(xt=this.parentSurface)===null||xt===void 0?void 0:xt.id,level:C.EPerformanceDebugLevel.Verbose});this.dataLabelProvider.generateDataLabels(fe,me),C.PerformanceDebugHelper.mark(C.EPerformanceMarkType.GenerateDataLabelsEnd,{contextId:this.id,parentContextId:(wt=this.parentSurface)===null||wt===void 0?void 0:wt.id,relatedId:($t=Bt==null?void 0:Bt.detail)===null||$t===void 0?void 0:$t.relatedId,level:C.EPerformanceDebugLevel.Verbose})}}this.resamplingParams=void 0,C.PerformanceDebugHelper.mark(C.EPerformanceMarkType.DrawSingleSeriesEnd,{contextId:this.id,parentContextId:(Mt=this.parentSurface)===null||Mt===void 0?void 0:Mt.id,relatedId:(rt=qe==null?void 0:qe.detail)===null||rt===void 0?void 0:rt.relatedId,level:C.EPerformanceDebugLevel.Verbose})},pe.prototype.delete=function(){this.drawingProviders.forEach(function(fe){return fe.delete()}),this.drawingProviders=[],this.dataSeries=(0,o.deleteSafe)(this.dataSeries),this.effect=(0,o.deleteSafe)(this.effect),this.pointMarker=(0,o.deleteSafe)(this.pointMarker),this.resamplerHelper=(0,o.deleteSafe)(this.resamplerHelper),this.pointSeries=(0,o.deleteSafe)(this.pointSeries),this.dataLabelProviderProperty=(0,o.deleteSafe)(this.dataLabelProvider),this.renderDataTransformProperty=(0,o.deleteSafe)(this.renderDataTransform)},pe.prototype.getXRange=function(){return this.dataSeries.getXRange(V.EDataSeriesValueType.Default)},pe.prototype.getYRange=function(fe,me){me===void 0&&(me=!1);var Ce=this.isRunningDataAnimation?V.EDataSeriesValueType.FinalAnimationValues:V.EDataSeriesValueType.Default,Ue=this.getResampledPointSeries(me);return this.renderDataTransform&&this.renderDataTransform.useForYRange?(this.updateTransformedValues(Ce),(0,x.getWindowedYRange)(this.webAssemblyContext,this.transformedRenderPassData.pointSeries.xValues,this.transformedRenderPassData.pointSeries.yValues,Ue&&me?new l.NumberRange(0,Ue.count-1):fe,!0,me,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.dataSeries.dataDistributionCalculator.containsNaN)):Ue?(0,x.getWindowedYRange)(this.webAssemblyContext,Ue.xValues,Ue.yValues,me?new l.NumberRange(0,Ue.count-1):fe,!0,me,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.dataSeries.dataDistributionCalculator.containsNaN):this.dataSeries.getWindowedYRange(fe,!0,me,Ce,this.yRangeMode)},pe.prototype.getResampledPointSeries=function(fe){var me,Ce;fe===void 0&&(fe=!1);var Ue;if(!((me=this.parentSurface)===null||me===void 0)&&me.renderSurface&&this.supportsResampling){var Qe=this.getCurrentRenderPassData();if(this.resamplingParams)this.resamplingParams.resampleRequired&&(Ue=this.currentRenderPassData.pointSeries);else{var it=this.parentSurface.renderSurface.viewportSize,xt=it.width,wt=it.height,$t=(Ce=this.parentSurface.seriesViewRect)!==null&&Ce!==void 0?Ce:u.Rect.create(0,0,xt,wt),Mt=this.xAxis,rt=new k.ResamplingParams($t,this,Mt);if(this.needsResampling(rt)){var qe=H.ExtremeResamplerHelper.calculateResamplingHash(this,rt),vt=!!(Qe&&Qe.resamplingHash===qe);Ue=vt?Qe.pointSeries:this.toPointSeries(rt),this.currentRenderPassData=new X.RenderPassData(this.getIndicesRange(this.xAxis.visibleRange,fe),this.xAxis.getCurrentCoordinateCalculator,this.yAxis.getCurrentCoordinateCalculator,this.xAxis.isVerticalChart,Ue,qe)}}}return Ue},pe.prototype.notifyPropertyChanged=function(fe){this.drawingProviders.forEach(function(me){return me.onSeriesPropertyChange(fe)}),this.invalidateParent()},pe.prototype.getDataPointWidth=function(fe,me,Ce){var Ue=this.dataSeries.getNativeXValues(),Qe=fe.viewportDimension,it=fe.isCategoryCoordinateCalculator;if(Ce===p.EDataPointWidthMode.Range){var xt=fe.visibleMax-fe.visibleMin;return fe.viewportDimension/xt*me}else{if(Ce===p.EDataPointWidthMode.Absolute)return me;var wt=Math.floor((0,t.getDataPointWidth)(Ue,fe,Qe,me,it,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.webAssemblyContext));return wt%2!==0&&(wt-=1),wt<=1&&(wt=1),wt}},pe.prototype.onDetach=function(){this.invalidateParentCallback=void 0,this.parentSurface=void 0,this.drawingProviders.forEach(function(fe){return fe.onDetachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(void 0)},pe.prototype.setParentSurface=function(fe){if(fe.surfaceType===b.ESurfaceType.SciChartSurfaceType&&this.isPolar)throw new Error("Polar renderable series can not be attached to a 2D SciChartSurface. Please check ".concat(this.constructor.name," to match SciChartSurface.surfaceType"));if(fe.surfaceType===b.ESurfaceType.SciChartPolarSurfaceType&&!this.isPolar)throw new Error("Only polar renderable series can be attached to a 2D SciChartPolarSurface. Please check ".concat(this.constructor.name," to match SciChartSurface.surfaceType"));if(this.parentSurface=fe,this.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachSeries, this series has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.invalidateParentCallback=fe.invalidateElement},pe.prototype.onAttach=function(fe){this.setParentSurface(fe),this.linkAxes(),this.drawingProviders.forEach(function(me){return me.onAttachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(fe.invalidateElement),this.resamplingParams=void 0},pe.prototype.hasStrokePaletteProvider=function(){var fe=this.paletteProvider;return(fe==null?void 0:fe.overrideStrokeArgb)!==void 0},pe.prototype.hasFillPaletteProvider=function(){var fe=this.paletteProvider;return(fe==null?void 0:fe.overrideFillArgb)!==void 0},pe.prototype.hasPointMarkerPaletteProvider=function(){var fe=this.paletteProvider;return(fe==null?void 0:fe.overridePointMarkerArgb)!==void 0},pe.prototype.hasDataSeriesValues=function(){var fe;return(fe=this.dataSeries)===null||fe===void 0?void 0:fe.hasValues},pe.prototype.hasDataSeries=function(){return!!this.dataSeries},pe.prototype.getDataSeriesValuesCount=function(){return this.dataSeries.count()},pe.prototype.getDataSeriesName=function(){var fe;return(fe=this.dataSeries)===null||fe===void 0?void 0:fe.dataSeriesName},pe.prototype.getNativeXValues=function(){return this.dataSeries.getNativeXValues()},pe.prototype.getNativeYValues=function(){var fe;return this.yArrayFilter?typeof this.yArrayFilter=="number"?this.dataSeries.getNativeYValues(this.yArrayFilter):(fe=this.dataSeries.getYValuesByName(this.yArrayFilter,V.EDataSeriesValueType.Default))!==null&&fe!==void 0?fe:this.getNativeYValues():this.dataSeries.getNativeYValues()},pe.prototype.checkIsOutOfDataRange=function(fe,me){var Ce=this.getDataSeriesValuesCount(),Ue=this.xAxis.getCurrentCoordinateCalculator().isCategoryCoordinateCalculator,Qe=Ue?0:this.getNativeXValues().get(0),it=Ue?Ce-1:this.getNativeXValues().get(Ce-1);return fe<Qe||fe>it},pe.prototype.pushPalettedColors=function(fe,me){me.palettedColors.push_back(fe)},pe.prototype.getSeriesInfo=function(fe){switch(fe.dataSeriesType){case V.EDataSeriesType.Ohlc:return new M.OhlcSeriesInfo(this,fe);case V.EDataSeriesType.Xyy:return new F.XyySeriesInfo(this,fe);case V.EDataSeriesType.Xyz:return new I.XyzSeriesInfo(this,fe);case V.EDataSeriesType.HeatmapUniform:return new A.HeatmapSeriesInfo(this,fe);case V.EDataSeriesType.HeatmapNonUniform:return new A.HeatmapSeriesInfo(this,fe);case V.EDataSeriesType.Hlc:return new R.HlcSeriesInfo(this,fe);case V.EDataSeriesType.BoxPlot:return new E.BoxPlotSeriesInfo(this,fe);default:return new D.XySeriesInfo(this,fe)}},pe.prototype.onDpiChanged=function(fe){var me,Ce;(me=this.drawingProviders)===null||me===void 0||me.forEach(function(Ue){Ue.onDpiChanged(fe)}),(Ce=this.pointMarker)===null||Ce===void 0||Ce.onDpiChanged(fe)},pe.prototype.toJSON=function(fe){var me,Ce,Ue,Qe,it,xt;fe===void 0&&(fe=!1);var wt;if(this.paletteProvider)if("toJSON"in this.paletteProvider)wt=this.paletteProvider.toJSON();else throw new Error("Series contains a palletProvider.  This must implement toJSON to be correctly serialized");var $t=this.getRenderNextTo(),Mt=$t&&{renderable:typeof $t.renderable=="string"?$t.renderable:$t.renderable.id,offset:$t.offset},rt={id:this.id,drawNaNAs:this.drawNaNAs,effect:(me=this.effect)===null||me===void 0?void 0:me.toJSON(),isDigitalLine:this.isDigitalLine,isHovered:this.isHovered,isSelected:this.isSelected,isVisible:this.isVisible,opacity:this.opacity,paletteProvider:wt,pointMarker:(Ce=this.pointMarker)===null||Ce===void 0?void 0:Ce.toJSON(),stroke:this.stroke,strokeThickness:this.strokeThickness,xAxisId:this.xAxisId,yAxisId:this.yAxisId,animation:this.animationQueue.length>0?this.animationQueue[0].toJSON():void 0,resamplingMode:this.resamplingMode,resamplingPrecision:this.resamplingPrecision,clipToYRange:this.clipToYRange,yRangeMode:this.yRangeMode,surfaceRenderOrder:this.surfaceRenderOrderProperty,renderLayer:this.getRenderLayer(),renderOrder:this.getRenderOrder(),renderNextTo:Mt,onIsVisibleChanged:this.typeMap.get("onIsVisibleChanged"),onSelectedChanged:this.typeMap.get("onSelectedChanged"),onHoveredChanged:this.typeMap.get("onHoveredChanged"),dataLabelProvider:(Ue=this.dataLabelProvider)===null||Ue===void 0?void 0:Ue.toJSON()},qe=(Qe=this.dataSeries)===null||Qe===void 0?void 0:Qe.toJSON(fe),vt=qe==null?void 0:qe.options;if(this.type===m.ESeriesType.ColumnSeries||this.type===m.ESeriesType.ImpulseSeries||this.type===m.ESeriesType.LineSeries||this.type===m.ESeriesType.PolarLineSeries||this.type===m.ESeriesType.TriangleSeries||this.type===m.ESeriesType.MountainSeries||this.type===m.ESeriesType.PolarMountainSeries||this.type===m.ESeriesType.ScatterSeries||this.type===m.ESeriesType.PolarScatterSeries||this.type===m.ESeriesType.SplineLineSeries||this.type===m.ESeriesType.SplineMountainSeries||this.type===m.ESeriesType.SmoothStackedMountainSeries||this.type===m.ESeriesType.StackedColumnSeries||this.type===m.ESeriesType.PolarStackedColumnSeries||this.type===m.ESeriesType.StackedMountainSeries||this.type===m.ESeriesType.PolarStackedMountainSeries)return{type:this.type,options:rt,xyData:vt};if(this.type===m.ESeriesType.LineSegmentSeries)return((it=this.dataSeries)===null||it===void 0?void 0:it.type)===V.EDataSeriesType.Xyxy?{type:this.type,options:rt,xyxyData:vt}:{type:this.type,options:rt,xyData:vt};if(this.type===m.ESeriesType.PolarColumnSeries){var kt=this.columnXMode;return kt===f.EColumnMode.MidWidth||kt===f.EColumnMode.StartWidth||kt===f.EColumnMode.StartEnd?{type:this.type,options:rt,xyxData:vt}:{type:this.type,options:rt,xyData:vt}}else return this.type===m.ESeriesType.BandSeries||this.type===m.ESeriesType.SplineBandSeries||this.type===m.ESeriesType.PolarBandSeries?{type:this.type,options:rt,xyyData:vt}:this.type===m.ESeriesType.BubbleSeries?{type:this.type,options:rt,xyzData:vt}:this.type===m.ESeriesType.CandlestickSeries||this.type===m.ESeriesType.OhlcSeries?{type:this.type,options:rt,ohlcData:vt}:this.type===m.ESeriesType.ErrorBarsSeries?{type:this.type,options:rt,hlcData:vt}:this.type===m.ESeriesType.TextSeries?{type:this.type,options:rt,xyTextData:vt}:this.type===m.ESeriesType.UniformHeatmapSeries||this.type===m.ESeriesType.UniformContoursSeries||this.type===m.ESeriesType.PolarUniformHeatmapSeries?{type:this.type,options:rt,heatmapData:vt}:this.type===m.ESeriesType.NonUniformHeatmapSeries?{type:this.type,options:rt,heatmapData:vt}:this.type===m.ESeriesType.RectangleSeries?((xt=this.dataSeries)===null||xt===void 0?void 0:xt.type)===V.EDataSeriesType.Xyxy?{type:this.type,options:rt,xyxyData:vt}:{type:this.type,options:rt,xyxData:vt}:this.type===m.ESeriesType.BoxPlotSeries?{type:this.type,options:rt,boxPlotData:vt}:{type:this.type,options:rt}},pe.prototype.enqueueAnimation=function(fe){this.animationQueue.push(fe),this.invalidateParent()},pe.prototype.runAnimation=function(fe){var me;this.animationQueue=[],(me=this.animationFSM)===null||me===void 0||me.toCompleted(),this.enqueueAnimation(fe)},Object.defineProperty(pe.prototype,"animation",{set:function(fe){fe&&this.animationQueue.push(fe),this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isRunningAnimation",{get:function(){return de.animationHelpers.checkIsAnimationRunning(this.animationQueue,this.animationFSM)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"isRunningDataAnimation",{get:function(){return this.isRunningAnimation&&this.animationFSM&&(this.animationFSM.animation.isDataSeriesAnimation||this.animationFSM.animation.isOnStartAnimation)},enumerable:!1,configurable:!0}),pe.prototype.onAnimate=function(fe){var me;if(!this.animationFSM||!((me=this.animationFSM)===null||me===void 0)&&me.is([n.EAnimationState.Completed]))if(this.animationQueue.length>=1){var Ce=this.animationQueue.shift();this.animationFSM=new n.SeriesAnimationFiniteStateMachine(Ce,this)}else this.animationFSM=void 0;this.animationFSM&&(this.dataSeries.xInitialAnimationValues||this.dataSeries.createAnimationVectors(),de.animationHelpers.animationUpdate(this.animationFSM,fe,this.beforeAnimationStart,this.afterAnimationComplete,this.updateAnimationProperties))},pe.prototype.toPointSeries=function(fe){return fe?(this.pointSeries=this.dataSeries.toPointSeries(fe,this.pointSeries,this.resamplerHelper),this.pointSeries.type===V.EDataSeriesType.XyN&&this.yArrayFilter!==void 0?typeof this.yArrayFilter=="number"?this.pointSeries.subSeries[this.yArrayFilter]:this.pointSeries.getSubSeriesByName(this.yArrayFilter):this.pointSeries):this.dataSeries.toPointSeries()},pe.prototype.getIndicesRange=function(fe,me){var Ce;return me===void 0&&(me=!1),(Ce=this.dataSeries)===null||Ce===void 0?void 0:Ce.getIndicesRange(fe,me)},pe.prototype.getCurrentRenderPassData=function(){return this.currentRenderPassData},pe.prototype.setCurrentRenderPassData=function(fe){var me;this.currentRenderPassData=fe,(me=this.hitTestProvider)===null||me===void 0||me.update(fe)},Object.defineProperty(pe.prototype,"supportsResampling",{get:function(){var fe=![m.ESeriesType.UniformContoursSeries,m.ESeriesType.UniformHeatmapSeries,m.ESeriesType.PolarUniformHeatmapSeries,m.ESeriesType.NonUniformHeatmapSeries,m.ESeriesType.BubbleSeries,m.ESeriesType.ErrorBarsSeries,m.ESeriesType.BoxPlotSeries,m.ESeriesType.LineSegmentSeries].includes(this.type);return fe&&!Y.SciChartDefaults.debugDisableResampling&&!this.isStacked&&this.dataSeries&&this.dataSeries.count()>0&&(this.enableDrawingOptimisations||this.dataSeries.fifoCapacity)&&(this.dataSeries.dataDistributionCalculator.isSortedAscending||this.xAxis.isCategoryAxis)},enumerable:!1,configurable:!0}),pe.prototype.needsResampling=function(fe){return this.resamplingParams=fe,this.resamplingParams.resampleRequired=this.resamplerHelper.needsResampling(fe,this.getNativeXValues()),this.resamplingParams.resampleRequired},Object.defineProperty(pe.prototype,"dataLabelProvider",{get:function(){return this.dataLabelProviderProperty},set:function(fe){this.dataLabelProviderProperty=fe,fe.onAttach(this.webAssemblyContext,this),this.notifyPropertyChanged(ge.PROPERTY.SERIES_TEXT_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(pe.prototype,"renderDataTransform",{get:function(){return this.renderDataTransformProperty},set:function(fe){if(fe.parentSeries!==this)throw new Error("renderDataTransform can only be added to the series it was created with");this.renderDataTransformProperty=fe,this.notifyPropertyChanged(ge.PROPERTY.SERIES_TEXT_PROVIDER)},enumerable:!1,configurable:!0}),pe.prototype.resolveAutoColors=function(fe,me,Ce){if(this.strokeProperty&&this.strokeProperty.startsWith(W.AUTO_COLOR)){var Ue=this.parentSurface.themeProvider.getStrokeColor(fe,me,this.webAssemblyContext);this.stroke=W.AUTO_COLOR+this.adjustAutoColor("stroke",Ue)}this.pointMarker&&this.pointMarker.resolveAutoColors(fe,me,Ce),this.dataLabelProvider&&this.dataLabelProvider.resolveAutoColors(fe,me,Ce)},pe.prototype.adjustAutoColor=function(fe,me){return me},pe.prototype.linkAxes=function(){if((0,s.updateAxisIds)(this),!!this.parentSurface){if(!this.xAxisProperty&&this.xAxisId){var fe=this.parentSurface.getXAxisById(this.xAxisId);fe?this.xAxisProperty=fe:(console.warn('RenderableSeries looked for xAxis Id "'.concat(this.xAxisId,'" but did not find. Default xAxis will be used')),this.xAxisProperty=this.parentSurface.getDefaultXAxis())}if(!this.yAxisProperty&&this.yAxisId){var me=this.parentSurface.getYAxisById(this.yAxisId);me?this.yAxisProperty=me:(console.warn('RenderableSeries looked for yAxis Id "'.concat(this.yAxisId,'" but did not find. Default yAxis will be used')),this.yAxisProperty=this.parentSurface.getDefaultYAxis())}}},pe.prototype.addDrawingProviders=function(fe,me){},pe.prototype.updateTransformedValues=function(fe){var me;if(!(!this.dataSeries||!this.parentSurface||!this.renderDataTransform)){var Ce;if(this.currentRenderPassData&&(fe??V.EDataSeriesValueType.Default)===V.EDataSeriesValueType.Default)Ce=this.currentRenderPassData;else{var Ue=!((me=this.resamplingParams)===null||me===void 0)&&me.resampleRequired?this.pointSeries:new G.XyPointSeriesWrapped(this.dataSeries,void 0,fe);Ce=new X.RenderPassData(this.getIndicesRange(this.xAxis.visibleRange,this.xAxis.isCategoryAxis),this.xAxis.getCurrentCoordinateCalculator,this.yAxis.getCurrentCoordinateCalculator,this.xAxis.isVerticalChart,Ue)}this.transformedRenderPassData=this.renderDataTransform.runTransform(Ce)}},pe.prototype.setAnimationVectors=function(fe){var me=this.dataSeries;fe.isOnStartAnimation?me.setFinalAnimationVectors(me):fe.isDataSeriesAnimation&&(me.setInitialAnimationVectors(me),me.setFinalAnimationVectors(fe.dataSeries),me.validateAnimationVectors())},pe.prototype.beforeAnimationStart=function(){var fe,me=this.animationFSM.animation;this.setAnimationVectors(me);var Ce=(fe=me==null?void 0:me.styles)===null||fe===void 0?void 0:fe.pointMarker;Ce&&(this.pointMarker=de.animationHelpers.createPointMarker(this.webAssemblyContext,Ce))},pe.prototype.afterAnimationComplete=function(){if(this.dataSeries){var fe=this.dataSeries;fe.setInitialAnimationVectors(void 0),fe.setFinalAnimationVectors(void 0)}},pe.prototype.updateAnimationProperties=function(fe,me){var Ce=me.animation;Ce.updateSeriesProperties(this,me.initialStyles,me.animationProgress);var Ue=this.dataSeries;Ue&&(Ue.updateAnimationProperties(fe,Ce),this.currentRenderPassData=void 0),this.renderDataTransform&&(this.renderDataTransform.requiresTransform=!0),this.invalidateParentCallback&&this.invalidateParentCallback()},pe.prototype.dataSeriesDataChanged=function(fe){this.renderDataTransform&&this.renderDataTransform.onDataChange(fe),this.invalidateParent()},pe.prototype.valueChanged=function(fe,me){return fe!==me},pe.prototype.setPaletteProvider=function(fe){var me,Ce;!((me=this.paletteProviderProperty)===null||me===void 0)&&me.onDetached&&this.paletteProviderProperty.onDetached(),this.paletteProviderProperty=fe,!((Ce=this.paletteProviderProperty)===null||Ce===void 0)&&Ce.onAttached&&this.paletteProviderProperty.onAttached(this),this.notifyPropertyChanged(ge.PROPERTY.PALETTE_PROVIDER)},pe.prototype.invalidateParent=function(){this.invalidateParentCallback&&this.invalidateParentCallback()},pe.prototype.effectPropertyChanged=function(){this.invalidateParent()},Object.defineProperty(pe.prototype,"canDraw",{get:function(){return de.animationHelpers.checkCanDraw(this.animationFSM)},enumerable:!1,configurable:!0}),pe})(r.DeletableEntity);t.BaseRenderableSeries=we;var Te=function(ve,pe,fe,me,Ce,Ue,Qe){if(me<0||me>1)throw new Error("WidthFraction should be between 0.0 and 1.0 inclusive");var it=ve.size(),xt=fe,wt=it;if(wt>1){var $t=Number.NEGATIVE_INFINITY,Mt=Number.MAX_VALUE;if(Ce)$t=pe.getCoordinate(it-1),Mt=pe.getCoordinate(0);else if(Ue)$t=pe.getCoordinate(ve.get(it-1)),Mt=pe.getCoordinate(ve.get(0));else{var rt=void 0;try{rt=Qe.NumberUtil.MinMax(ve,!1),Mt=rt.minD,$t=rt.maxD}finally{(0,o.deleteSafe)(rt)}$t=pe.getCoordinate($t),Mt=pe.getCoordinate(Mt)}xt=Math.abs($t-Mt)/(wt-1)}return xt*me};t.getDataPointWidth=Te;var ke=function(ve){var pe=ve.pointSize,fe=ve.areaSize,me=ve.range;if(fe===0)return 0;var Ce=pe*oe.DpiHelper.PIXEL_RATIO,Ue=fe/(fe-Ce);return Math.abs(me.diff)*(Ue-1)/2};t.getDelta=ke;var $e=function(ve,pe,fe){fe===void 0&&(fe=0);var me=fe&&(0,t.getDelta)({pointSize:pe,areaSize:fe,range:ve});return new l.NumberRange(ve.min-me,ve.max+me)};t.adjustRangeByStrokeThickness=$e;var Ne=function(ve,pe,fe,me,Ce){var Ue=pe/2;return ve===p.EDataPointWidthMode.Relative&&(fe>1?Ue=me.diff/(fe-1)*pe/2:Ue=0),ve===p.EDataPointWidthMode.Absolute&&(Ue=Ce.getDataWidth(pe)/2),Ue};t.getDataPointWidthAdjustment=Ne})(XN)),XN}var Sve;function AFe(){if(Sve)return qN;Sve=1,Object.defineProperty(qN,"__esModule",{value:!0}),qN.RenderPassInfo=void 0;var t=QD(),e=ju(),i=(function(){function n(r,o){this.renderableSeriesArray=[],this.rendermap=new Map,this.reverseMap=new Map,this.relativeItems=[],this.hasOtherSeriesLayerRenderables=!1,this.seriesViewRect=o}return n.prototype.addRenderable=function(r,o){var a;this.hasOtherSeriesLayerRenderables||!(r instanceof e.BaseRenderableSeries)&&r.getRenderOrder()===t.EDefaultRenderLayer.SeriesLayer&&(this.hasOtherSeriesLayerRenderables=!0);var s=r.getSurfaceRenderOrder(),l=r.getRenderLayer();if(r.getRenderNextTo()){this.hasOtherSeriesLayerRenderables||r.getRenderNextTo().renderable instanceof e.BaseRenderableSeries&&(this.hasOtherSeriesLayerRenderables=!0),this.relativeItems.push({renderable:r,drawFunction:o,tries:0});return}this.rendermap.has(s)||this.rendermap.set(s,new Map),this.rendermap.get(s).get(l)||this.rendermap.get(s).set(l,[]);var u=this.rendermap.get(s).get(l),c=(a=r.getRenderOrder())!==null&&a!==void 0?a:u.length;u.push({renderable:r,resolvedOrder:c,drawFunction:o}),this.reverseMap.set(r.id,{surfaceOrder:s,layer:l,resolvedOrder:c})},n.prototype.resolveNextTo=function(){for(;this.relativeItems.length>0;){var r=this.relativeItems.shift(),o=r.renderable.getRenderNextTo(),a=typeof o.renderable=="string"?o.renderable:o.renderable.id;if(r.tries<this.relativeItems.length+3)if(this.reverseMap.has(a)){var s=this.reverseMap.get(a),l=s.surfaceOrder,u=s.layer,c=s.resolvedOrder,d=this.rendermap.get(l).get(u),f=c+o.offset;d.push({renderable:r.renderable,resolvedOrder:f,drawFunction:r.drawFunction}),this.reverseMap.set(r.renderable.id,{surfaceOrder:l,layer:u,resolvedOrder:f})}else r.tries+=1,this.relativeItems.push(r);else console.warn("Could not find relative item ".concat(a," "))}},n})();return qN.RenderPassInfo=i,qN}var fF={},_ve;function Bre(){if(_ve)return fF;_ve=1,Object.defineProperty(fF,"__esModule",{value:!0}),fF.watermarkHelpers=void 0;var t=Rn(),e=Ig(),i=Tre();function n(r,o,a,s,l,u){var c=l??t.Rect.create(0,0,r,o),d=u??new e.Size(r,o),f=r>500,h=0,p=0,g=0,v=0;if(f){var y=32,m=42,b=124;h=y+b,p=m,g=5,v=10}else{var y=16,m=21,b=63;h=y+b,p=m,g=3,v=6}var S=c.x+g,_=o-(c.top+c.height)+v;if(s)switch(a){case i.EWatermarkPosition.BottomRight:S=r-h-g,_=o-d.height+v;break;case i.EWatermarkPosition.TopLeft:S=g,_=o-(v+p);break;case i.EWatermarkPosition.TopRight:S=r-h-g,_=o-(v+p);break;case i.EWatermarkPosition.BottomLeft:S=g,_=o-d.height+v;break}else switch(a){case i.EWatermarkPosition.BottomRight:S=c.left+c.width-h-g;break;case i.EWatermarkPosition.TopLeft:_=o-(c.top+v+p);break;case i.EWatermarkPosition.TopRight:S=c.left+c.width-h-g,_=o-(c.top+v+p);break;case i.EWatermarkPosition.BottomLeft:}return{left:S,bottom:_}}return fF.watermarkHelpers={calcPosition:n},fF}var hF={},Pve;function OFe(){if(Pve)return hF;Pve=1,Object.defineProperty(hF,"__esModule",{value:!0}),hF.OrderedRenderable=void 0;var t=hl(),e=(function(){function i(n,r,o){this.isVisible=!0,this.setRenderNextTo=function(a,s){},this.getRenderNextTo=function(){},this.id=(0,t.generateGuid)(),this.surfaceRenderOrder=n,this.renderLayer=r,this.renderOrder=o}return i.prototype.getSurfaceRenderOrder=function(){return this.surfaceRenderOrder},i.prototype.getRenderLayer=function(){return this.renderLayer},i.prototype.getRenderOrder=function(){return this.renderOrder},i.prototype.setRenderOrder=function(n){this.renderOrder=n},i})();return hF.OrderedRenderable=e,hF}var Cve;function DFe(){if(Cve)return qT;Cve=1;var t=qT&&qT.__spreadArray||function(P,x,E){if(E||arguments.length===2)for(var A=0,R=x.length,M;A<R;A++)(M||!(A in x))&&(M||(M=Array.prototype.slice.call(x,0,A)),M[A]=x[A]);return P.concat(M||Array.prototype.slice.call(x))};Object.defineProperty(qT,"__esModule",{value:!0}),qT.SciChartRenderer=void 0;var e=Uo(),i=Rn(),n=tR(),r=QD(),o=Iu(),a=Rg(),s=Sn(),l=Zi(),u=QP(),c=AFe(),d=an(),f=ZP(),h=Ti(),p=kh(),g=La(),v=Dre(),y=$f(),m=An(),b=Bre(),S=pa(),_=OFe(),C=(function(){function P(x){this.isInvalidated=!1,this.svgRenderRequestId=void 0,this.domRenderRun=!1,this.sciChartSurface=x}return P.prototype.renderDomOnly=function(){var x=this,E;if(!this.sciChartSurface.isDeleted){p.Logger.debug("svg only render start"),this.domRenderRun=!0,this.sciChartSurface.preRender.raiseEvent(void 0);var A=this.previousTime?Date.now()-this.previousTime:0;this.previousTime=Date.now();var R=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.GenericAnimationStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});if(this.sciChartSurface.onAnimate(A),this.sciChartSurface.genericAnimationsRun.raiseEvent(),this.domRenderRun=!0,g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.GenericAnimationEnd,{contextId:this.sciChartSurface.id,relatedId:(E=R==null?void 0:R.detail)===null||E===void 0?void 0:E.relatedId,level:g.EPerformanceDebugLevel.Verbose}),this.sciChartSurface.layoutMeasured.raiseEvent(),this.isInvalidated){p.Logger.debug("main chart invalidated during dom prerender.  Reverting to full render"),this.sciChartSurface.webAssemblyContext2D.TSRRequestDraw();return}var M=this.sciChartSurface.annotations.asArray(),D=this.sciChartSurface.modifierAnnotations.asArray(),F=t(t([],M,!0),D,!0),I=F.filter(function(V){return V.isDomAnnotation});I.length>0&&this.drawSvgAnnotations(I,this.sciChartSurface.getCoordSvgTranslation()),this.sciChartSurface.rendered.raiseEvent(!1),this.domRenderRun=!1,this.sciChartSurface.isRunningAnimation&&setTimeout(function(){return x.sciChartSurface.invalidateElement({svgOnly:!0})},0),p.Logger.debug("dom only render end")}},P.prototype.render=function(x){var E=this,A,R,M,D,F,I,V;if(!this.sciChartSurface.isDeleted){if(this.sciChartSurface.hasInvalidState){this.displayErrorMessage();return}var z=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.RenderStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});p.Logger.debug("render start");var G=x.getNativeContext(),H=this.sciChartSurface.webAssemblyContext2D,U;if(e.IS_TEST_ENV||(U=G.GetBlendMode(),G.SetBlendMode(H.eSCRTBlendMode.BlendAdditiveOneAlpha)),this.validate(),!this.domRenderRun){var k=this.previousTime?Date.now()-this.previousTime:0;this.previousTime=Date.now();var X=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.GenericAnimationStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});this.isInvalidated=!1,this.sciChartSurface.onAnimate(k),this.sciChartSurface.genericAnimationsRun.raiseEvent(),this.isInvalidated=!0,g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.GenericAnimationEnd,{contextId:this.sciChartSurface.id,relatedId:(A=X==null?void 0:X.detail)===null||A===void 0?void 0:A.relatedId,level:g.EPerformanceDebugLevel.Verbose})}this.sciChartSurface.updateStackedCollectionAccumulatedVectors();var W=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.AutoRangeStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});this.sciChartSurface.xAxes.asArray().forEach(function(we){return E.tryPerformAutoRangeOn(we,E.sciChartSurface)});var Y=(R=this.sciChartSurface.seriesViewRect)!==null&&R!==void 0?R:i.Rect.create(0,0,x.viewportSize.width,x.viewportSize.height),te=this.prepareSeriesRenderData(Y);this.sciChartSurface.yAxes.asArray().forEach(function(we){return E.tryPerformAutoRangeOn(we,E.sciChartSurface)}),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.AutoRangeEnd,{contextId:this.sciChartSurface.id,relatedId:(M=W==null?void 0:W.detail)===null||M===void 0?void 0:M.relatedId,level:g.EPerformanceDebugLevel.Verbose});var oe=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.LayoutStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});a.SciChartSurface.isSubSurface(this.sciChartSurface)&&this.sciChartSurface.updateSubLayout();var de=this.measureTitle(x),ge=S.Thickness.mergeAdd((D=this.sciChartSurface.offset)!==null&&D!==void 0?D:S.Thickness.fromNumber(0),de),Ee=this.sciChartSurface.layoutManager.layoutChart(x.viewportSize,ge);if(this.sciChartSurface.setCoordSvgTranslation(Ee.x,Ee.y),this.resizeAnnotationRootElements(Ee),this.prepareAxesRenderData(),x.enqueueLayeredDraw(function(){E.sciChartSurface.updateBackground(x)},this.getAbsoluteLayer(r.EDefaultRenderLayer.Background)),this.layoutTitle(Ee),this.scheduleTitleDraw(x),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.LayoutEnd,{contextId:this.sciChartSurface.id,relatedId:(F=oe==null?void 0:oe.detail)===null||F===void 0?void 0:F.relatedId,level:g.EPerformanceDebugLevel.Verbose}),this.sciChartSurface.isSubSurface||this.sciChartSurface.chartModifiers.asArray().forEach(function(we){we.modifierType!==y.EModifierType.Chart3DModifier&&we.linkAxes(),we.onParentSurfaceLayoutComplete()}),this.domRenderRun||this.sciChartSurface.layoutMeasured.raiseEvent(),this.isInvalidated=!1,this.domRenderRun=!1,x.enqueueLayeredDraw(function(){E.sciChartSurface.drawBorder(x)},this.getAbsoluteLayer(r.EDefaultRenderLayer.AxisBandsLayer)),this.sciChartSurface.debugRendering&&this.drawDebugAxes(this.sciChartSurface,x),this.drawAxes(this.sciChartSurface,x),this.getSeriesDrawFunctions(this.sciChartSurface,te,x),this.getAnnotationDrawFunctions(this.sciChartSurface,te,x),this.sciChartSurface.dataLabelLayoutManager){var Re=new _.OrderedRenderable(this.sciChartSurface.getSurfaceRenderOrder(),r.EDefaultRenderLayer.AxesLayer,void 0);te.addRenderable(Re,function(){var we,Te=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PerformTextLayoutStart,{contextId:E.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});E.sciChartSurface.dataLabelLayoutManager.performTextLayout(E.sciChartSurface,te),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PerformTextLayoutEnd,{contextId:E.sciChartSurface.id,relatedId:(we=Te==null?void 0:Te.detail)===null||we===void 0?void 0:we.relatedId,level:g.EPerformanceDebugLevel.Verbose})})}var Ae=new _.OrderedRenderable(this.sciChartSurface.getSurfaceRenderOrder(),r.EDefaultRenderLayer.AxesLayer,void 0);te.addRenderable(Ae,function(){te.renderableSeriesArray.forEach(function(we,Te){var ke;if(we.dataLabelProvider){var $e=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawDataLabelsStart,{contextId:we.id,parentContextId:E.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});we.dataLabelProvider.draw(x),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawDataLabelsEnd,{contextId:we.id,parentContextId:E.sciChartSurface.id,relatedId:(ke=$e==null?void 0:$e.detail)===null||ke===void 0?void 0:ke.relatedId,level:g.EPerformanceDebugLevel.Verbose})}})}),this.enqueueRenderables(x,te),x.enqueueLayeredDraw(function(){var we=E.sciChartSurface.clipRect;x.resetAndClip(we),x.endFonts()},this.getAbsoluteLayer(r.EDefaultRenderLayer.AxesLayer)),x.enqueueLayeredDraw(function(){},this.getAbsoluteLayer(r.EDefaultRenderLayer.Foreground)),x.drawLayers(),a.SciChartSurface.isSubSurface(this.sciChartSurface)?x.doDraw&&this.updateWatermark(x,this.sciChartSurface.parentSurface.seriesViewRect):this.updateWatermark(x,Ee);var Pe=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PostDrawActionsStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});this.onParentSurfaceRendered(),e.IS_TEST_ENV||G.SetBlendMode(U),this.sciChartSurface.isRunningAnimation&&this.svgRenderRequestId===void 0&&setTimeout(this.sciChartSurface.invalidateElement,0),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PostDrawActionsEnd,{contextId:this.sciChartSurface.id,relatedId:(I=Pe==null?void 0:Pe.detail)===null||I===void 0?void 0:I.relatedId,level:g.EPerformanceDebugLevel.Verbose}),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.RenderEnd,{contextId:this.sciChartSurface.id,relatedId:(V=z==null?void 0:z.detail)===null||V===void 0?void 0:V.relatedId,level:g.EPerformanceDebugLevel.Verbose}),p.Logger.debug("render end")}},P.prototype.getSeriesDrawFunctions=function(x,E,A){for(var R=E.renderableSeriesArray,M=this.sciChartSurface.seriesViewRect,D=i.Rect.intersect(this.sciChartSurface.seriesViewRect,this.sciChartSurface.clipRect),F=x.xAxes.asArray().some(function(U){return U.isVerticalChart}),I=!0,V=function(U){if(!U.isVisible)return"continue";var k=function(){(F||E.hasOtherSeriesLayerRenderables||I)&&A.setTranslationRotationAndClip(D,M.x,M.y),U.draw(A,U.getCurrentRenderPassData()),I=!1};E.addRenderable(U,k)},z=0,G=R;z<G.length;z++){var H=G[z];V(H)}},P.prototype.getAnnotationDrawFunctions=function(x,E,A){for(var R=this.sciChartSurface.seriesViewRect,M=this.sciChartSurface.annotations.asArray(),D=this.sciChartSurface.modifierAnnotations.asArray(),F=this.sciChartSurface.getCoordSvgTranslation(),I=0,V=M;I<V.length;I++){var z=V[I];z.isDomAnnotation?this.getHTMLAnnotationDrawFunction(z,F):z.isVisible&&this.getRenderContextAnnotationDrawFunction(z,A,R,E)}for(var G=0,H=D;G<H.length;G++){var z=H[G];z.isDomAnnotation?this.getHTMLAnnotationDrawFunction(z,F):z.isVisible&&this.getRenderContextAnnotationDrawFunction(z,A,R,E)}},P.prototype.getHTMLAnnotationDrawFunction=function(x,E){var A;x.linkAxes();var R=x.xAxis,M=x.yAxis;if(!R||!M)console.error("Cannot draw annotations before axes have been configured. Add axes first, or use suspendUpdates to pause drawing until axes are available.");else{var D=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationStart,{contextId:x.id,parentContextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});x.update(R.getCurrentCoordinateCalculator(),M.getCurrentCoordinateCalculator(),E.x/l.DpiHelper.PIXEL_RATIO,E.y/l.DpiHelper.PIXEL_RATIO),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationEnd,{contextId:x.id,parentContextId:this.sciChartSurface.id,relatedId:(A=D==null?void 0:D.detail)===null||A===void 0?void 0:A.relatedId,level:g.EPerformanceDebugLevel.Verbose})}},P.prototype.getRenderContextAnnotationDrawFunction=function(x,E,A,R){var M=this,D=this.sciChartSurface.viewRect,F=this.sciChartSurface.chartViewRect;if(x.isVisible){var I=function(){var V,z,G;x.linkAxes();var H=x.xAxis,U=x.yAxis;if(!H||!U)console.error("Cannot draw annotations before axes have been configured. Add axes first, or use suspendUpdates to pause drawing until axes are available.");else if(!H.parentSurface)console.error("Cannot draw annotation ".concat((V=x==null?void 0:x.constructor)===null||V===void 0?void 0:V.name," with X-axis detached from sciChartSurface. Set a correct xAxisId on the annotation."));else if(!U.parentSurface)console.error("Cannot draw annotation ".concat((z=x==null?void 0:x.constructor)===null||z===void 0?void 0:z.name," with Y-axis detached from sciChartSurface. Set a correct yAxisId on the annotation."));else{var k=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationStart,{contextId:x.id,parentContextId:M.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});x.drawWithContext(E,H.getCurrentCoordinateCalculator(),U.getCurrentCoordinateCalculator(),A,D,F),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationEnd,{contextId:x.id,parentContextId:M.sciChartSurface.id,relatedId:(G=k==null?void 0:k.detail)===null||G===void 0?void 0:G.relatedId,level:g.EPerformanceDebugLevel.Verbose})}};R.addRenderable(x,I)}},P.prototype.enqueueRenderables=function(x,E){E.resolveNextTo();var A=Array.from(E.rendermap.keys());A.sort(function(W,Y){return W-Y});for(var R=0,M=A;R<M.length;R++){var D=M[R],F=Array.from(E.rendermap.get(D).keys());F.sort(function(W,Y){return W-Y});for(var I=0,V=F;I<V.length;I++){var z=V[I],G=E.rendermap.get(D).get(z);G.sort(function(W,Y){return W.resolvedOrder-Y.resolvedOrder});for(var H=(0,o.calculateAbsoluteRenderLayer)(D,this.sciChartSurface.stepBetweenLayers,z),U=0,k=G;U<k.length;U++){var X=k[U];X!=null&&X.drawFunction&&this.enqueueRenderable(x,X,H)}}}},P.prototype.enqueueRenderable=function(x,E,A){x.enqueueLayeredDraw(E.drawFunction,A)},P.prototype.displayErrorMessage=function(){var x=document.createElement("div");x.style.width="100%",x.style.height="100%",x.style.color="white",x.style.background="black",x.style.display="flex",x.style.justifyContent="center",x.style.alignItems="center";var E=document.createElement("span");E.innerText="The surface with id ".concat(this.sciChartSurface.id," has an invalid state. Check the console for errors."),x.appendChild(E),this.sciChartSurface.domDivContainer.style.background="black",this.sciChartSurface.domDivContainer.appendChild(x)},P.prototype.drawRenderContextAnnotations=function(x,E,A,R){var M=this,D=this.sciChartSurface.viewRect,F=this.sciChartSurface.chartViewRect;x.filter(function(I){return I.annotationLayer===E}).forEach(function(I){var V;I.linkAxes();var z=I.xAxis,G=I.yAxis;if(!z||!G)console.error("Cannot draw annotations before axes have been configured. Add axes first, or use suspendUpdates to pause drawing until axes are available.");else if(!I.isHidden){var H=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationStart,{contextId:I.id,parentContextId:M.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});I.drawWithContext(A,z.getCurrentCoordinateCalculator(),G.getCurrentCoordinateCalculator(),R,D,F),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationEnd,{contextId:I.id,parentContextId:M.sciChartSurface.id,relatedId:(V=H==null?void 0:H.detail)===null||V===void 0?void 0:V.relatedId,level:g.EPerformanceDebugLevel.Verbose})}})},P.prototype.drawHtmlBasedAnnotations=function(x,E){var A=this;x.forEach(function(R){var M;R.linkAxes();var D=R.xAxis,F=R.yAxis;if(!D||!F)console.error("Cannot draw annotations before axes have been configured. Add axes first, or use suspendUpdates to pause drawing until axes are available.");else{var I=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationStart,{contextId:A.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});R.update(D.getCurrentCoordinateCalculator(),F.getCurrentCoordinateCalculator(),E.x/l.DpiHelper.PIXEL_RATIO,E.y/l.DpiHelper.PIXEL_RATIO),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationEnd,{contextId:A.sciChartSurface.id,relatedId:(M=I==null?void 0:I.detail)===null||M===void 0?void 0:M.relatedId,level:g.EPerformanceDebugLevel.Verbose})}})},P.prototype.drawSvgAnnotations=function(x,E){var A=this;x.forEach(function(R){var M,D,F;R.linkAxes();var I=R.xAxis,V=R.yAxis;if(!I||!V){console.error("Cannot draw SVG annotations before axes have been configured. Add axes first, or use suspendUpdates to pause drawing until axes are available.");return}(I.id!==R.xAxisId||V.id!==R.yAxisId)&&p.Logger.log("SVG Annotation ".concat((D=(M=R.constructor)===null||M===void 0?void 0:M.name)!==null&&D!==void 0?D:""," has mismatched axis IDs. Expected xAxisId=").concat(R.xAxisId,", yAxisId=").concat(R.yAxisId," but got xAxis=").concat(I.id,", yAxis=").concat(V.id));var z=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationStart,{contextId:R.id,parentContextId:A.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});R.update(I.getCurrentCoordinateCalculator(),V.getCurrentCoordinateCalculator(),E.x/l.DpiHelper.PIXEL_RATIO,E.y/l.DpiHelper.PIXEL_RATIO),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawAnnotationEnd,{contextId:R.id,parentContextId:A.sciChartSurface.id,relatedId:(F=z==null?void 0:z.detail)===null||F===void 0?void 0:F.relatedId,level:g.EPerformanceDebugLevel.Verbose})})},P.prototype.validate=function(){if(this.sciChartSurface.xAxes.asArray().forEach(function(E){return E.isMeasured=!1}),this.sciChartSurface.yAxes.asArray().forEach(function(E){return E.isMeasured=!1}),this.sciChartSurface.renderableSeries.size()>0){var x=this.sciChartSurface.validateAndLink();if(x.length>0)throw new Error(x.join(`
`))}},P.prototype.resizeAnnotationRootElements=function(x){var E=this.sciChartSurface.clipRect,A=(0,m.translateToNotScaledRect)(E),R=i.Rect.intersect((0,m.translateToNotScaledRect)(x),A),M=this.sciChartSurface.viewRect,D=i.Rect.intersect((0,m.translateToNotScaledRect)(M),A);if(!this.prevRect||!this.prevSurfaceRect)this.prevRect=R,this.prevSurfaceRect=D;else if(i.Rect.isEqual(this.prevRect,R)&&i.Rect.isEqual(this.prevSurfaceRect,D))return;this.prevRect=R,this.prevSurfaceRect=M;var F=this.sciChartSurface.domSvgContainer;F&&this.sciChartSurface.setSvgClipPathDefinitions(F,R,D);var I=this.sciChartSurface.domBackgroundSvgContainer;I&&this.sciChartSurface.setSvgClipPathDefinitions(I,R,D);var V=this.sciChartSurface.domSvgAdornerLayer;V&&this.sciChartSurface.setSvgClipPathDefinitions(V,R,D)},P.prototype.prepareAxesRenderData=function(){this.sciChartSurface.xAxes.asArray().forEach(function(x){x.prepareRenderData()}),this.sciChartSurface.yAxes.asArray().forEach(function(x){x.prepareRenderData()})},P.prototype.prepareSeriesRenderData=function(x){for(var E,A,R,M=this.sciChartSurface.renderableSeries.size(),D=new c.RenderPassInfo(M,x),F=0;F<this.sciChartSurface.renderableSeries.size();F++){var I=this.sciChartSurface.renderableSeries.get(F);if(!(!I.isCollection&&!I.dataSeries)){if(!I.isCollection&&I.dataSeries.getIsDeleted())throw new Error("SciChartSurface.renderableSeries[index=".concat(F,"] dataSeries has been deleted. ")+"This is an invalid state for SciChart. Have you shared this DataSeries between chart surfaces?");var V=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.ResampleSingleSeriesStart,{contextId:I.id,parentContextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose}),z=I.xAxis;if(!z.parentSurface){console.error("Cannot draw series ".concat((E=I==null?void 0:I.constructor)===null||E===void 0?void 0:E.name," with X-axis detached from sciChartSurface. Set a correct xAxisId on the series"));continue}var G=I.yAxis;if(!G.parentSurface){console.error("Cannot draw series ".concat((A=I==null?void 0:I.constructor)===null||A===void 0?void 0:A.name," with Y-axis detached from sciChartSurface. Set a correct yAxisId on the series"));continue}var H=v.ExtremeResamplerHelper.resampleSeries(z,I,x);D.renderableSeriesArray.push(H.renderableSeries);var U=new u.RenderPassData(H.indicesRange,z.getCurrentCoordinateCalculator,G.getCurrentCoordinateCalculator,z.isVerticalChart,H.pointSeries,H.resamplingHash);I.setCurrentRenderPassData(U),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.ResampleSingleSeriesEnd,{contextId:I.id,parentContextId:this.sciChartSurface.id,relatedId:(R=V==null?void 0:V.detail)===null||R===void 0?void 0:R.relatedId,level:g.EPerformanceDebugLevel.Verbose})}}return D},P.prototype.drawAxes=function(x,E){x.xAxes.asArray().forEach(function(A){A.draw(E)}),x.yAxes.asArray().forEach(function(A){A.draw(E)})},P.prototype.drawSeries=function(x,E,A){var R=this,M,D=E.renderableSeriesArray,F=this.sciChartSurface.seriesViewRect,I=i.Rect.intersect(this.sciChartSurface.seriesViewRect,this.sciChartSurface.clipRect);if(A.setTranslationRotationAndClip(I,F.x,F.y),D.forEach(function(z,G){z.isVisible&&!z.isSelected&&!z.isHovered&&z.draw(A,z.getCurrentRenderPassData())}),D.forEach(function(z,G){z.isVisible&&z.isHovered&&z.draw(A,z.getCurrentRenderPassData())}),D.forEach(function(z,G){z.isVisible&&z.isSelected&&z.draw(A,z.getCurrentRenderPassData())}),this.sciChartSurface.dataLabelLayoutManager){var V=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PerformTextLayoutStart,{contextId:this.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});this.sciChartSurface.dataLabelLayoutManager.performTextLayout(this.sciChartSurface,E),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.PerformTextLayoutEnd,{contextId:this.sciChartSurface.id,relatedId:(M=V==null?void 0:V.detail)===null||M===void 0?void 0:M.relatedId,level:g.EPerformanceDebugLevel.Verbose})}D.forEach(function(z,G){var H;if(z.isVisible&&z.dataLabelProvider){var U=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawDataLabelsStart,{contextId:z.id,parentContextId:R.sciChartSurface.id,level:g.EPerformanceDebugLevel.Verbose});z.dataLabelProvider.draw(A),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.DrawDataLabelsEnd,{contextId:z.id,parentContextId:R.sciChartSurface.id,relatedId:(H=U==null?void 0:U.detail)===null||H===void 0?void 0:H.relatedId,level:g.EPerformanceDebugLevel.Verbose})}})},P.prototype.drawDebugAxes=function(x,E){E.enqueueLayeredDraw(function(){x.xAxes.asArray().forEach(function(A){A.drawDebug(E)}),x.yAxes.asArray().forEach(function(A){A.drawDebug(E)})})},P.prototype.tryPerformAutoRangeOn=function(x,E){var A=!x.hasValidVisibleRange()||x.hasDefaultVisibleRange(),R=x.autoRange===n.EAutoRange.Always||x.autoRange===n.EAutoRange.Once&&A;if(R){var M=x.getMaximumRange();M.equals(x.visibleRange)||(!x.autoRangeAnimation||A&&!x.autoRangeAnimation.animateInitialRanging||!A&&!x.autoRangeAnimation.animateSubsequentRanging?x.visibleRange=M:M.equals(x.animatedVisibleRange)||x.animateVisibleRange(M,x.autoRangeAnimation.duration,x.autoRangeAnimation.easing))}},P.prototype.onParentSurfaceRendered=function(){var x;this.sciChartSurface.isSubSurface||this.sciChartSurface.chartModifiers.asArray().forEach(function(E){E.modifierType!==y.EModifierType.Chart3DModifier&&E.linkAxes(),E.onParentSurfaceRendered()}),(x=this.sciChartSurface.subCharts)===null||x===void 0||x.forEach(function(E){E.hasInvalidState||E.chartModifiers.asArray().forEach(function(A){A.onParentSurfaceRendered()})})},P.prototype.updateWatermark=function(x,E){var A=this.sciChartSurface.isCopyCanvasSurface?s.SciChartSurfaceBase.domMasterCanvas.height:x.viewportSize.height,R=this.sciChartSurface.isCopyCanvasSurface?s.SciChartSurfaceBase.domMasterCanvas.width:x.viewportSize.width,M=b.watermarkHelpers.calcPosition(R,A,this.sciChartSurface.watermarkPosition,this.sciChartSurface.watermarkRelativeToCanvas,E,x.viewportSize),D=M.left,F=M.bottom;this.sciChartSurface.updateWatermark(D,F)},P.prototype.scheduleTitleDraw=function(x){var E=this;x.enqueueLayeredDraw(function(){E.sciChartSurface.chartTitleRenderer.draw(x,E.sciChartSurface.clipRect)},this.getAbsoluteLayer(r.EDefaultRenderLayer.AnnotationsAboveSeriesLayer))},P.prototype.measureTitle=function(x){return this.sciChartSurface.chartTitleRenderer.measure(this.sciChartSurface.title,this.sciChartSurface.titleStyle,x),this.sciChartSurface.chartTitleRenderer.titleOffset},P.prototype.layoutTitle=function(x){var E=this.sciChartSurface.titleStyle.placeWithinChart?x:this.sciChartSurface.viewRect;this.sciChartSurface.chartTitleRenderer.layout(E)},P.prototype.getAbsoluteLayer=function(x){return(0,o.calculateAbsoluteRenderLayer)(this.sciChartSurface.getSurfaceRenderOrder(),this.sciChartSurface.stepBetweenLayers,x)},P.prototype.drawDebugSurfaceRect=function(x,E,A){var R=(0,d.getVectorRectVertex)(A),M=new A.SCRTSolidBrush((0,h.parseColorToUIntArgb)("rgba(0,255,0,0.7)"),!1),D=(0,f.createNativeRect)(A,0,0,E.width,E.height);R.push_back(D),x.drawRects(R,M,this.sciChartSurface.chartViewRect,E.left,E.top),M.delete()},P})();return qT.SciChartRenderer=C,qT}var pF={},Tve;function RFe(){if(Tve)return pF;Tve=1,Object.defineProperty(pF,"__esModule",{value:!0}),pF.AdornerLayer=void 0;var t=(function(){function e(i){this.parentSurface=i}return e.prototype.selectAnnotation=function(i){var n=this.parentSurface,r,o=function(a){for(var s=a.length-1;s>=0;s--){var l=a[s],u=l.click(i,!r&&l.isEditable);u&&(r=l)}};return o(n.annotations.asArray()),o(n.modifierAnnotations.asArray()),this.selectedAnnotationProperty=r,!!r},e.prototype.deselectAnnotation=function(i){this.selectedAnnotationProperty===i&&(this.selectedAnnotationProperty=void 0)},Object.defineProperty(e.prototype,"selectedAnnotation",{get:function(){return this.selectedAnnotationProperty},set:function(i){this.selectedAnnotationProperty=i},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isAnnotationSelected",{get:function(){return!!this.selectedAnnotationProperty},enumerable:!1,configurable:!0}),e})();return pF.AdornerLayer=t,pF}var y1={},g9={exports:{}},xve;function MFe(){return xve||(xve=1,(function(t,e){var i=(()=>{var r;var n=typeof document<"u"?(r=document.currentScript)==null?void 0:r.src:void 0;return(function(o={}){var a,s=o,l,u,c=new Promise(($,ee)=>{l=$,u=ee}),d=Object.assign({},s),f=[],h="./this.program",p=($,ee)=>{throw ee},g="";function v($){return s.locateFile?s.locateFile($,g):g+$}var y,m;typeof document<"u"&&document.currentScript&&(g=document.currentScript.src),n&&(g=n),g.startsWith("blob:")?g="":g=g.substr(0,g.replace(/[?#].*/,"").lastIndexOf("/")+1),y=async $=>{var ee=await fetch($,{credentials:"same-origin"});if(ee.ok)return ee.arrayBuffer();throw new Error(ee.status+" : "+ee.url)};var b=s.print||console.log.bind(console),S=s.printErr||console.error.bind(console);Object.assign(s,d),d=null,s.arguments&&(f=s.arguments),s.thisProgram&&(h=s.thisProgram);var _=s.wasmBinary,C,P=!1,x,E,A,R,M,D,F,I,V;function z(){var $=C.buffer;s.HEAP8=E=new Int8Array($),s.HEAP16=R=new Int16Array($),s.HEAPU8=A=new Uint8Array($),s.HEAPU16=M=new Uint16Array($),s.HEAP32=D=new Int32Array($),s.HEAPU32=F=new Uint32Array($),s.HEAPF32=I=new Float32Array($),s.HEAPF64=V=new Float64Array($)}var G=[],H=[],U=[],k=[];function X(){if(s.preRun)for(typeof s.preRun=="function"&&(s.preRun=[s.preRun]);s.preRun.length;)oe(s.preRun.shift());Mt(G)}function W(){!s.noFSInit&&!ce.initialized&&ce.init(),ce.ignorePermissions=!1,Mt(H)}function Y(){Mt(U)}function te(){if(s.postRun)for(typeof s.postRun=="function"&&(s.postRun=[s.postRun]);s.postRun.length;)ge(s.postRun.shift());Mt(k)}function oe($){G.unshift($)}function de($){H.unshift($)}function ge($){k.unshift($)}var Ee=0,Re=null;function Ae($){var ee;Ee++,(ee=s.monitorRunDependencies)==null||ee.call(s,Ee)}function Pe($){var ae;if(Ee--,(ae=s.monitorRunDependencies)==null||ae.call(s,Ee),Ee==0&&Re){var ee=Re;Re=null,ee()}}function we($){var ae;(ae=s.onAbort)==null||ae.call(s,$),$="Aborted("+$+")",S($),P=!0,$+=". Build with -sASSERTIONS for more info.";var ee=new WebAssembly.RuntimeError($);throw u(ee),ee}var Te="data:application/octet-stream;base64,",ke=$=>$.startsWith(Te);function $e(){var $="scichart2d.wasm";return ke($)?$:v($)}var Ne;function ve($){if($==Ne&&_)return new Uint8Array(_);throw"both async and sync fetching of the wasm failed"}async function pe($){if(!_)try{var ee=await y($);return new Uint8Array(ee)}catch{}return ve($)}async function fe($,ee){try{var ae=await pe($),O=await WebAssembly.instantiate(ae,ee);return O}catch(j){S(`failed to asynchronously prepare wasm: ${j}`),we(j)}}async function me($,ee,ae){if(!$&&typeof WebAssembly.instantiateStreaming=="function"&&!ke(ee)&&typeof fetch=="function")try{var O=fetch(ee,{credentials:"same-origin"}),j=await WebAssembly.instantiateStreaming(O,ae);return j}catch(Q){S(`wasm streaming compile failed: ${Q}`),S("falling back to ArrayBuffer instantiation")}return fe(ee,ae)}function Ce(){return{a:Ea}}async function Ue(){function $(j,Q){return Io=j.exports,Io=Ko(Io),C=Io.lb,z(),Lt=Io.qb,de(Io.mb),Pe(),Io}Ae();function ee(j){$(j.instance)}var ae=Ce();if(s.instantiateWasm)try{return s.instantiateWasm(ae,$)}catch(j){S(`Module.instantiateWasm callback failed with error: ${j}`),u(j)}Ne??(Ne=$e());try{var O=await me(_,Ne,ae);return ee(O),O}catch(j){u(j);return}}var Qe,it,xt={458517:()=>s.getRandomValue(),458533:()=>s.getRandomValue(),458553:()=>{if(s.getRandomValue===void 0)try{var $=typeof window=="object"?window:self,ee=typeof $.crypto<"u"?$.crypto:$.msCrypto,ae=function(){var Q=new Uint32Array(1);return ee.getRandomValues(Q),Q[0]>>>0};ae(),s.getRandomValue=ae}catch{try{var O=Math.pow(2,32),j=function(){var ie=Math.floor(Math.random()*Math.floor(O));return ie>>>0};j(),s.getRandomValue=j}catch{throw"No secure random number generator found"}}},458569:()=>{if(s.getRandomValue===void 0)try{var $=typeof window=="object"?window:self,ee=typeof $.crypto<"u"?$.crypto:$.msCrypto,ae=function(){var Q=new Uint32Array(1);return ee.getRandomValues(Q),Q[0]>>>0};ae(),s.getRandomValue=ae}catch{try{var O=Math.pow(2,32),j=function(){var ie=Math.floor(Math.random()*Math.floor(O));return ie>>>0};j(),s.getRandomValue=j}catch{throw"No secure random number generator found"}}}};function wt(){var $="";typeof window<"u"?$=window.location.hostname:typeof process<"u"&&($="node");var ee=nr($)+1,ae=yi(ee);return Di($,ae,ee),ae}class $t{constructor(ee){Go(this,"name","ExitStatus");this.message=`Program terminated with exit(${ee})`,this.status=ee}}var Mt=$=>{for(;$.length>0;)$.shift()(s)},rt=s.noExitRuntime||!0,qe=$=>Ol($),vt=()=>Ed();class kt{constructor(ee){this.excPtr=ee,this.ptr=ee-24}set_type(ee){F[this.ptr+4>>>2>>>0]=ee}get_type(){return F[this.ptr+4>>>2>>>0]}set_destructor(ee){F[this.ptr+8>>>2>>>0]=ee}get_destructor(){return F[this.ptr+8>>>2>>>0]}set_caught(ee){ee=ee?1:0,E[this.ptr+12>>>0]=ee}get_caught(){return E[this.ptr+12>>>0]!=0}set_rethrown(ee){ee=ee?1:0,E[this.ptr+13>>>0]=ee}get_rethrown(){return E[this.ptr+13>>>0]!=0}init(ee,ae){this.set_adjusted_ptr(0),this.set_type(ee),this.set_destructor(ae)}set_adjusted_ptr(ee){F[this.ptr+16>>>2>>>0]=ee}get_adjusted_ptr(){return F[this.ptr+16>>>2>>>0]}}var Xe=0,_t=($,ee)=>ee+2097152>>>0<4194305-!!$?($>>>0)+ee*4294967296:NaN;function Ht($,ee,ae){$>>>=0,ee>>>=0,ae>>>=0;var O=new kt($);throw O.init(ee,ae),Xe=$,Xe}var Pt=()=>{var $=D[+Yt.varargs>>>2>>>0];return Yt.varargs+=4,$},Jt=Pt,zt={isAbs:$=>$.charAt(0)==="/",splitPath:$=>{var ee=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;return ee.exec($).slice(1)},normalizeArray:($,ee)=>{for(var ae=0,O=$.length-1;O>=0;O--){var j=$[O];j==="."?$.splice(O,1):j===".."?($.splice(O,1),ae++):ae&&($.splice(O,1),ae--)}if(ee)for(;ae;ae--)$.unshift("..");return $},normalize:$=>{var ee=zt.isAbs($),ae=$.substr(-1)==="/";return $=zt.normalizeArray($.split("/").filter(O=>!!O),!ee).join("/"),!$&&!ee&&($="."),$&&ae&&($+="/"),(ee?"/":"")+$},dirname:$=>{var ee=zt.splitPath($),ae=ee[0],O=ee[1];return!ae&&!O?".":(O&&(O=O.substr(0,O.length-1)),ae+O)},basename:$=>{if($==="/")return"/";$=zt.normalize($),$=$.replace(/\/$/,"");var ee=$.lastIndexOf("/");return ee===-1?$:$.substr(ee+1)},join:(...$)=>zt.normalize($.join("/")),join2:($,ee)=>zt.normalize($+"/"+ee)},Bt=()=>{if(typeof crypto=="object"&&typeof crypto.getRandomValues=="function")return $=>crypto.getRandomValues($);we("initRandomDevice")},Mr=$=>(Mr=Bt())($),Be={resolve:(...$)=>{for(var ee="",ae=!1,O=$.length-1;O>=-1&&!ae;O--){var j=O>=0?$[O]:ce.cwd();if(typeof j!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!j)return"";ee=j+"/"+ee,ae=zt.isAbs(j)}return ee=zt.normalizeArray(ee.split("/").filter(Q=>!!Q),!ae).join("/"),(ae?"/":"")+ee||"."},relative:($,ee)=>{$=Be.resolve($).substr(1),ee=Be.resolve(ee).substr(1);function ae(Fe){for(var Ge=0;Ge<Fe.length&&Fe[Ge]==="";Ge++);for(var lt=Fe.length-1;lt>=0&&Fe[lt]==="";lt--);return Ge>lt?[]:Fe.slice(Ge,lt-Ge+1)}for(var O=ae($.split("/")),j=ae(ee.split("/")),Q=Math.min(O.length,j.length),ie=Q,he=0;he<Q;he++)if(O[he]!==j[he]){ie=he;break}for(var Oe=[],he=ie;he<O.length;he++)Oe.push("..");return Oe=Oe.concat(j.slice(ie)),Oe.join("/")}},We=typeof TextDecoder<"u"?new TextDecoder:void 0,dt=($,ee=0,ae=NaN)=>{ee>>>=0;for(var O=ee+ae,j=ee;$[j]&&!(j>=O);)++j;if(j-ee>16&&$.buffer&&We)return We.decode($.subarray(ee,j));for(var Q="";ee<j;){var ie=$[ee++];if(!(ie&128)){Q+=String.fromCharCode(ie);continue}var he=$[ee++]&63;if((ie&224)==192){Q+=String.fromCharCode((ie&31)<<6|he);continue}var Oe=$[ee++]&63;if((ie&240)==224?ie=(ie&15)<<12|he<<6|Oe:ie=(ie&7)<<18|he<<12|Oe<<6|$[ee++]&63,ie<65536)Q+=String.fromCharCode(ie);else{var Fe=ie-65536;Q+=String.fromCharCode(55296|Fe>>10,56320|Fe&1023)}}return Q},Tt=[],nr=$=>{for(var ee=0,ae=0;ae<$.length;++ae){var O=$.charCodeAt(ae);O<=127?ee++:O<=2047?ee+=2:O>=55296&&O<=57343?(ee+=4,++ae):ee+=3}return ee},Ar=($,ee,ae,O)=>{if(ae>>>=0,!(O>0))return 0;for(var j=ae,Q=ae+O-1,ie=0;ie<$.length;++ie){var he=$.charCodeAt(ie);if(he>=55296&&he<=57343){var Oe=$.charCodeAt(++ie);he=65536+((he&1023)<<10)|Oe&1023}if(he<=127){if(ae>=Q)break;ee[ae++>>>0]=he}else if(he<=2047){if(ae+1>=Q)break;ee[ae++>>>0]=192|he>>6,ee[ae++>>>0]=128|he&63}else if(he<=65535){if(ae+2>=Q)break;ee[ae++>>>0]=224|he>>12,ee[ae++>>>0]=128|he>>6&63,ee[ae++>>>0]=128|he&63}else{if(ae+3>=Q)break;ee[ae++>>>0]=240|he>>18,ee[ae++>>>0]=128|he>>12&63,ee[ae++>>>0]=128|he>>6&63,ee[ae++>>>0]=128|he&63}}return ee[ae>>>0]=0,ae-j};function Qr($,ee,ae){var O=nr($)+1,j=new Array(O),Q=Ar($,j,0,j.length);return j.length=Q,j}var Si=()=>{if(!Tt.length){var $=null;if(typeof window<"u"&&typeof window.prompt=="function"&&($=window.prompt("Input: "),$!==null&&($+=`
`)),!$)return null;Tt=Qr($)}return Tt.shift()},oi={ttys:[],init(){},shutdown(){},register($,ee){oi.ttys[$]={input:[],output:[],ops:ee},ce.registerDevice($,oi.stream_ops)},stream_ops:{open($){var ee=oi.ttys[$.node.rdev];if(!ee)throw new ce.ErrnoError(43);$.tty=ee,$.seekable=!1},close($){$.tty.ops.fsync($.tty)},fsync($){$.tty.ops.fsync($.tty)},read($,ee,ae,O,j){if(!$.tty||!$.tty.ops.get_char)throw new ce.ErrnoError(60);for(var Q=0,ie=0;ie<O;ie++){var he;try{he=$.tty.ops.get_char($.tty)}catch{throw new ce.ErrnoError(29)}if(he===void 0&&Q===0)throw new ce.ErrnoError(6);if(he==null)break;Q++,ee[ae+ie]=he}return Q&&($.node.atime=Date.now()),Q},write($,ee,ae,O,j){if(!$.tty||!$.tty.ops.put_char)throw new ce.ErrnoError(60);try{for(var Q=0;Q<O;Q++)$.tty.ops.put_char($.tty,ee[ae+Q])}catch{throw new ce.ErrnoError(29)}return O&&($.node.mtime=$.node.ctime=Date.now()),Q}},default_tty_ops:{get_char($){return Si()},put_char($,ee){ee===null||ee===10?(b(dt($.output)),$.output=[]):ee!=0&&$.output.push(ee)},fsync($){$.output&&$.output.length>0&&(b(dt($.output)),$.output=[])},ioctl_tcgets($){return{c_iflag:25856,c_oflag:5,c_cflag:191,c_lflag:35387,c_cc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}},ioctl_tcsets($,ee,ae){return 0},ioctl_tiocgwinsz($){return[24,80]}},default_tty1_ops:{put_char($,ee){ee===null||ee===10?(S(dt($.output)),$.output=[]):ee!=0&&$.output.push(ee)},fsync($){$.output&&$.output.length>0&&(S(dt($.output)),$.output=[])}}},Yr=($,ee)=>Math.ceil($/ee)*ee,vi=$=>{we()},rr={ops_table:null,mount($){return rr.createNode(null,"/",16895,0)},createNode($,ee,ae,O){if(ce.isBlkdev(ae)||ce.isFIFO(ae))throw new ce.ErrnoError(63);rr.ops_table||(rr.ops_table={dir:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr,lookup:rr.node_ops.lookup,mknod:rr.node_ops.mknod,rename:rr.node_ops.rename,unlink:rr.node_ops.unlink,rmdir:rr.node_ops.rmdir,readdir:rr.node_ops.readdir,symlink:rr.node_ops.symlink},stream:{llseek:rr.stream_ops.llseek}},file:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr},stream:{llseek:rr.stream_ops.llseek,read:rr.stream_ops.read,write:rr.stream_ops.write,allocate:rr.stream_ops.allocate,mmap:rr.stream_ops.mmap,msync:rr.stream_ops.msync}},link:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr,readlink:rr.node_ops.readlink},stream:{}},chrdev:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr},stream:ce.chrdev_stream_ops}});var j=ce.createNode($,ee,ae,O);return ce.isDir(j.mode)?(j.node_ops=rr.ops_table.dir.node,j.stream_ops=rr.ops_table.dir.stream,j.contents={}):ce.isFile(j.mode)?(j.node_ops=rr.ops_table.file.node,j.stream_ops=rr.ops_table.file.stream,j.usedBytes=0,j.contents=null):ce.isLink(j.mode)?(j.node_ops=rr.ops_table.link.node,j.stream_ops=rr.ops_table.link.stream):ce.isChrdev(j.mode)&&(j.node_ops=rr.ops_table.chrdev.node,j.stream_ops=rr.ops_table.chrdev.stream),j.atime=j.mtime=j.ctime=Date.now(),$&&($.contents[ee]=j,$.atime=$.mtime=$.ctime=j.atime),j},getFileDataAsTypedArray($){return $.contents?$.contents.subarray?$.contents.subarray(0,$.usedBytes):new Uint8Array($.contents):new Uint8Array(0)},expandFileStorage($,ee){var ae=$.contents?$.contents.length:0;if(!(ae>=ee)){var O=1024*1024;ee=Math.max(ee,ae*(ae<O?2:1.125)>>>0),ae!=0&&(ee=Math.max(ee,256));var j=$.contents;$.contents=new Uint8Array(ee),$.usedBytes>0&&$.contents.set(j.subarray(0,$.usedBytes),0)}},resizeFileStorage($,ee){if($.usedBytes!=ee)if(ee==0)$.contents=null,$.usedBytes=0;else{var ae=$.contents;$.contents=new Uint8Array(ee),ae&&$.contents.set(ae.subarray(0,Math.min(ee,$.usedBytes))),$.usedBytes=ee}},node_ops:{getattr($){var ee={};return ee.dev=ce.isChrdev($.mode)?$.id:1,ee.ino=$.id,ee.mode=$.mode,ee.nlink=1,ee.uid=0,ee.gid=0,ee.rdev=$.rdev,ce.isDir($.mode)?ee.size=4096:ce.isFile($.mode)?ee.size=$.usedBytes:ce.isLink($.mode)?ee.size=$.link.length:ee.size=0,ee.atime=new Date($.atime),ee.mtime=new Date($.mtime),ee.ctime=new Date($.ctime),ee.blksize=4096,ee.blocks=Math.ceil(ee.size/ee.blksize),ee},setattr($,ee){for(const ae of["mode","atime","mtime","ctime"])ee[ae]&&($[ae]=ee[ae]);ee.size!==void 0&&rr.resizeFileStorage($,ee.size)},lookup($,ee){throw rr.doesNotExistError},mknod($,ee,ae,O){return rr.createNode($,ee,ae,O)},rename($,ee,ae){var O;try{O=ce.lookupNode(ee,ae)}catch{}if(O){if(ce.isDir($.mode))for(var j in O.contents)throw new ce.ErrnoError(55);ce.hashRemoveNode(O)}delete $.parent.contents[$.name],ee.contents[ae]=$,$.name=ae,ee.ctime=ee.mtime=$.parent.ctime=$.parent.mtime=Date.now()},unlink($,ee){delete $.contents[ee],$.ctime=$.mtime=Date.now()},rmdir($,ee){var ae=ce.lookupNode($,ee);for(var O in ae.contents)throw new ce.ErrnoError(55);delete $.contents[ee],$.ctime=$.mtime=Date.now()},readdir($){return[".","..",...Object.keys($.contents)]},symlink($,ee,ae){var O=rr.createNode($,ee,41471,0);return O.link=ae,O},readlink($){if(!ce.isLink($.mode))throw new ce.ErrnoError(28);return $.link}},stream_ops:{read($,ee,ae,O,j){var Q=$.node.contents;if(j>=$.node.usedBytes)return 0;var ie=Math.min($.node.usedBytes-j,O);if(ie>8&&Q.subarray)ee.set(Q.subarray(j,j+ie),ae);else for(var he=0;he<ie;he++)ee[ae+he]=Q[j+he];return ie},write($,ee,ae,O,j,Q){if(ee.buffer===E.buffer&&(Q=!1),!O)return 0;var ie=$.node;if(ie.mtime=ie.ctime=Date.now(),ee.subarray&&(!ie.contents||ie.contents.subarray)){if(Q)return ie.contents=ee.subarray(ae,ae+O),ie.usedBytes=O,O;if(ie.usedBytes===0&&j===0)return ie.contents=ee.slice(ae,ae+O),ie.usedBytes=O,O;if(j+O<=ie.usedBytes)return ie.contents.set(ee.subarray(ae,ae+O),j),O}if(rr.expandFileStorage(ie,j+O),ie.contents.subarray&&ee.subarray)ie.contents.set(ee.subarray(ae,ae+O),j);else for(var he=0;he<O;he++)ie.contents[j+he]=ee[ae+he];return ie.usedBytes=Math.max(ie.usedBytes,j+O),O},llseek($,ee,ae){var O=ee;if(ae===1?O+=$.position:ae===2&&ce.isFile($.node.mode)&&(O+=$.node.usedBytes),O<0)throw new ce.ErrnoError(28);return O},allocate($,ee,ae){rr.expandFileStorage($.node,ee+ae),$.node.usedBytes=Math.max($.node.usedBytes,ee+ae)},mmap($,ee,ae,O,j){if(!ce.isFile($.node.mode))throw new ce.ErrnoError(43);var Q,ie,he=$.node.contents;if(!(j&2)&&he&&he.buffer===E.buffer)ie=!1,Q=he.byteOffset;else{if(ie=!0,Q=vi(),!Q)throw new ce.ErrnoError(48);he&&((ae>0||ae+ee<he.length)&&(he.subarray?he=he.subarray(ae,ae+ee):he=Array.prototype.slice.call(he,ae,ae+ee)),E.set(he,Q>>>0))}return{ptr:Q,allocated:ie}},msync($,ee,ae,O,j){return rr.stream_ops.write($,ee,0,O,ae,!1),0}}},Ji=async $=>{var ee=await y($);return new Uint8Array(ee)},qn=($,ee,ae,O,j,Q)=>{ce.createDataFile($,ee,ae,O,j,Q)},ri=s.preloadPlugins||[],eo=($,ee,ae,O)=>{typeof Browser<"u"&&Browser.init();var j=!1;return ri.forEach(Q=>{j||Q.canHandle(ee)&&(Q.handle($,ee,ae,O),j=!0)}),j},xn=($,ee,ae,O,j,Q,ie,he,Oe,Fe)=>{var Ge=ee?Be.resolve(zt.join2($,ee)):$;function lt(Ot){function St(jt){Fe==null||Fe(),he||qn($,ee,jt,O,j,Oe),Q==null||Q(),Pe()}eo(Ot,Ge,St,()=>{ie==null||ie(),Pe()})||St(Ot)}Ae(),typeof ae=="string"?Ji(ae).then(lt,ie):lt(ae)},mt=$=>{var ee={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090},ae=ee[$];if(typeof ae>"u")throw new Error(`Unknown file open mode: ${$}`);return ae},gr=($,ee)=>{var ae=0;return $&&(ae|=365),ee&&(ae|=146),ae},ce={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,ErrnoError:class{constructor($){Go(this,"name","ErrnoError");this.errno=$}},filesystems:null,syncFSRequests:0,readFiles:{},FSStream:class{constructor(){Go(this,"shared",{})}get object(){return this.node}set object($){this.node=$}get isRead(){return(this.flags&2097155)!==1}get isWrite(){return(this.flags&2097155)!==0}get isAppend(){return this.flags&1024}get flags(){return this.shared.flags}set flags($){this.shared.flags=$}get position(){return this.shared.position}set position($){this.shared.position=$}},FSNode:class{constructor($,ee,ae,O){Go(this,"node_ops",{});Go(this,"stream_ops",{});Go(this,"readMode",365);Go(this,"writeMode",146);Go(this,"mounted",null);$||($=this),this.parent=$,this.mount=$.mount,this.id=ce.nextInode++,this.name=ee,this.mode=ae,this.rdev=O,this.atime=this.mtime=this.ctime=Date.now()}get read(){return(this.mode&this.readMode)===this.readMode}set read($){$?this.mode|=this.readMode:this.mode&=~this.readMode}get write(){return(this.mode&this.writeMode)===this.writeMode}set write($){$?this.mode|=this.writeMode:this.mode&=~this.writeMode}get isFolder(){return ce.isDir(this.mode)}get isDevice(){return ce.isChrdev(this.mode)}},lookupPath($,ee={}){if(!$)return{path:"",node:null};ee.follow_mount??(ee.follow_mount=!0),zt.isAbs($)||($=ce.cwd()+"/"+$);e:for(var ae=0;ae<40;ae++){for(var O=$.split("/").filter(Fe=>!!Fe&&Fe!=="."),j=ce.root,Q="/",ie=0;ie<O.length;ie++){var he=ie===O.length-1;if(he&&ee.parent)break;if(O[ie]===".."){Q=zt.dirname(Q),j=j.parent;continue}Q=zt.join2(Q,O[ie]);try{j=ce.lookupNode(j,O[ie])}catch(Fe){if((Fe==null?void 0:Fe.errno)===44&&he&&ee.noent_okay)return{path:Q};throw Fe}if(ce.isMountpoint(j)&&(!he||ee.follow_mount)&&(j=j.mounted.root),ce.isLink(j.mode)&&(!he||ee.follow)){if(!j.node_ops.readlink)throw new ce.ErrnoError(52);var Oe=j.node_ops.readlink(j);zt.isAbs(Oe)||(Oe=zt.dirname(Q)+"/"+Oe),$=Oe+"/"+O.slice(ie+1).join("/");continue e}}return{path:Q,node:j}}throw new ce.ErrnoError(32)},getPath($){for(var ee;;){if(ce.isRoot($)){var ae=$.mount.mountpoint;return ee?ae[ae.length-1]!=="/"?`${ae}/${ee}`:ae+ee:ae}ee=ee?`${$.name}/${ee}`:$.name,$=$.parent}},hashName($,ee){for(var ae=0,O=0;O<ee.length;O++)ae=(ae<<5)-ae+ee.charCodeAt(O)|0;return($+ae>>>0)%ce.nameTable.length},hashAddNode($){var ee=ce.hashName($.parent.id,$.name);$.name_next=ce.nameTable[ee],ce.nameTable[ee]=$},hashRemoveNode($){var ee=ce.hashName($.parent.id,$.name);if(ce.nameTable[ee]===$)ce.nameTable[ee]=$.name_next;else for(var ae=ce.nameTable[ee];ae;){if(ae.name_next===$){ae.name_next=$.name_next;break}ae=ae.name_next}},lookupNode($,ee){var ae=ce.mayLookup($);if(ae)throw new ce.ErrnoError(ae);for(var O=ce.hashName($.id,ee),j=ce.nameTable[O];j;j=j.name_next){var Q=j.name;if(j.parent.id===$.id&&Q===ee)return j}return ce.lookup($,ee)},createNode($,ee,ae,O){var j=new ce.FSNode($,ee,ae,O);return ce.hashAddNode(j),j},destroyNode($){ce.hashRemoveNode($)},isRoot($){return $===$.parent},isMountpoint($){return!!$.mounted},isFile($){return($&61440)===32768},isDir($){return($&61440)===16384},isLink($){return($&61440)===40960},isChrdev($){return($&61440)===8192},isBlkdev($){return($&61440)===24576},isFIFO($){return($&61440)===4096},isSocket($){return($&49152)===49152},flagsToPermissionString($){var ee=["r","w","rw"][$&3];return $&512&&(ee+="w"),ee},nodePermissions($,ee){return ce.ignorePermissions?0:ee.includes("r")&&!($.mode&292)||ee.includes("w")&&!($.mode&146)||ee.includes("x")&&!($.mode&73)?2:0},mayLookup($){if(!ce.isDir($.mode))return 54;var ee=ce.nodePermissions($,"x");return ee||($.node_ops.lookup?0:2)},mayCreate($,ee){if(!ce.isDir($.mode))return 54;try{var ae=ce.lookupNode($,ee);return 20}catch{}return ce.nodePermissions($,"wx")},mayDelete($,ee,ae){var O;try{O=ce.lookupNode($,ee)}catch(Q){return Q.errno}var j=ce.nodePermissions($,"wx");if(j)return j;if(ae){if(!ce.isDir(O.mode))return 54;if(ce.isRoot(O)||ce.getPath(O)===ce.cwd())return 10}else if(ce.isDir(O.mode))return 31;return 0},mayOpen($,ee){return $?ce.isLink($.mode)?32:ce.isDir($.mode)&&(ce.flagsToPermissionString(ee)!=="r"||ee&512)?31:ce.nodePermissions($,ce.flagsToPermissionString(ee)):44},MAX_OPEN_FDS:4096,nextfd(){for(var $=0;$<=ce.MAX_OPEN_FDS;$++)if(!ce.streams[$])return $;throw new ce.ErrnoError(33)},getStreamChecked($){var ee=ce.getStream($);if(!ee)throw new ce.ErrnoError(8);return ee},getStream:$=>ce.streams[$],createStream($,ee=-1){return $=Object.assign(new ce.FSStream,$),ee==-1&&(ee=ce.nextfd()),$.fd=ee,ce.streams[ee]=$,$},closeStream($){ce.streams[$]=null},dupStream($,ee=-1){var O,j;var ae=ce.createStream($,ee);return(j=(O=ae.stream_ops)==null?void 0:O.dup)==null||j.call(O,ae),ae},chrdev_stream_ops:{open($){var ae,O;var ee=ce.getDevice($.node.rdev);$.stream_ops=ee.stream_ops,(O=(ae=$.stream_ops).open)==null||O.call(ae,$)},llseek(){throw new ce.ErrnoError(70)}},major:$=>$>>8,minor:$=>$&255,makedev:($,ee)=>$<<8|ee,registerDevice($,ee){ce.devices[$]={stream_ops:ee}},getDevice:$=>ce.devices[$],getMounts($){for(var ee=[],ae=[$];ae.length;){var O=ae.pop();ee.push(O),ae.push(...O.mounts)}return ee},syncfs($,ee){typeof $=="function"&&(ee=$,$=!1),ce.syncFSRequests++,ce.syncFSRequests>1&&S(`warning: ${ce.syncFSRequests} FS.syncfs operations in flight at once, probably just doing extra work`);var ae=ce.getMounts(ce.root.mount),O=0;function j(ie){return ce.syncFSRequests--,ee(ie)}function Q(ie){if(ie)return Q.errored?void 0:(Q.errored=!0,j(ie));++O>=ae.length&&j(null)}ae.forEach(ie=>{if(!ie.type.syncfs)return Q(null);ie.type.syncfs(ie,$,Q)})},mount($,ee,ae){var O=ae==="/",j=!ae,Q;if(O&&ce.root)throw new ce.ErrnoError(10);if(!O&&!j){var ie=ce.lookupPath(ae,{follow_mount:!1});if(ae=ie.path,Q=ie.node,ce.isMountpoint(Q))throw new ce.ErrnoError(10);if(!ce.isDir(Q.mode))throw new ce.ErrnoError(54)}var he={type:$,opts:ee,mountpoint:ae,mounts:[]},Oe=$.mount(he);return Oe.mount=he,he.root=Oe,O?ce.root=Oe:Q&&(Q.mounted=he,Q.mount&&Q.mount.mounts.push(he)),Oe},unmount($){var ee=ce.lookupPath($,{follow_mount:!1});if(!ce.isMountpoint(ee.node))throw new ce.ErrnoError(28);var ae=ee.node,O=ae.mounted,j=ce.getMounts(O);Object.keys(ce.nameTable).forEach(ie=>{for(var he=ce.nameTable[ie];he;){var Oe=he.name_next;j.includes(he.mount)&&ce.destroyNode(he),he=Oe}}),ae.mounted=null;var Q=ae.mount.mounts.indexOf(O);ae.mount.mounts.splice(Q,1)},lookup($,ee){return $.node_ops.lookup($,ee)},mknod($,ee,ae){var O=ce.lookupPath($,{parent:!0}),j=O.node,Q=zt.basename($);if(!Q||Q==="."||Q==="..")throw new ce.ErrnoError(28);var ie=ce.mayCreate(j,Q);if(ie)throw new ce.ErrnoError(ie);if(!j.node_ops.mknod)throw new ce.ErrnoError(63);return j.node_ops.mknod(j,Q,ee,ae)},statfs($){var ee={bsize:4096,frsize:4096,blocks:1e6,bfree:5e5,bavail:5e5,files:ce.nextInode,ffree:ce.nextInode-1,fsid:42,flags:2,namelen:255},ae=ce.lookupPath($,{follow:!0}).node;return ae!=null&&ae.node_ops.statfs&&Object.assign(ee,ae.node_ops.statfs(ae.mount.opts.root)),ee},create($,ee=438){return ee&=4095,ee|=32768,ce.mknod($,ee,0)},mkdir($,ee=511){return ee&=1023,ee|=16384,ce.mknod($,ee,0)},mkdirTree($,ee){for(var ae=$.split("/"),O="",j=0;j<ae.length;++j)if(ae[j]){O+="/"+ae[j];try{ce.mkdir(O,ee)}catch(Q){if(Q.errno!=20)throw Q}}},mkdev($,ee,ae){return typeof ae>"u"&&(ae=ee,ee=438),ee|=8192,ce.mknod($,ee,ae)},symlink($,ee){if(!Be.resolve($))throw new ce.ErrnoError(44);var ae=ce.lookupPath(ee,{parent:!0}),O=ae.node;if(!O)throw new ce.ErrnoError(44);var j=zt.basename(ee),Q=ce.mayCreate(O,j);if(Q)throw new ce.ErrnoError(Q);if(!O.node_ops.symlink)throw new ce.ErrnoError(63);return O.node_ops.symlink(O,j,$)},rename($,ee){var ae=zt.dirname($),O=zt.dirname(ee),j=zt.basename($),Q=zt.basename(ee),ie,he,Oe;if(ie=ce.lookupPath($,{parent:!0}),he=ie.node,ie=ce.lookupPath(ee,{parent:!0}),Oe=ie.node,!he||!Oe)throw new ce.ErrnoError(44);if(he.mount!==Oe.mount)throw new ce.ErrnoError(75);var Fe=ce.lookupNode(he,j),Ge=Be.relative($,O);if(Ge.charAt(0)!==".")throw new ce.ErrnoError(28);if(Ge=Be.relative(ee,ae),Ge.charAt(0)!==".")throw new ce.ErrnoError(55);var lt;try{lt=ce.lookupNode(Oe,Q)}catch{}if(Fe!==lt){var Ot=ce.isDir(Fe.mode),St=ce.mayDelete(he,j,Ot);if(St)throw new ce.ErrnoError(St);if(St=lt?ce.mayDelete(Oe,Q,Ot):ce.mayCreate(Oe,Q),St)throw new ce.ErrnoError(St);if(!he.node_ops.rename)throw new ce.ErrnoError(63);if(ce.isMountpoint(Fe)||lt&&ce.isMountpoint(lt))throw new ce.ErrnoError(10);if(Oe!==he&&(St=ce.nodePermissions(he,"w"),St))throw new ce.ErrnoError(St);ce.hashRemoveNode(Fe);try{he.node_ops.rename(Fe,Oe,Q),Fe.parent=Oe}catch(jt){throw jt}finally{ce.hashAddNode(Fe)}}},rmdir($){var ee=ce.lookupPath($,{parent:!0}),ae=ee.node,O=zt.basename($),j=ce.lookupNode(ae,O),Q=ce.mayDelete(ae,O,!0);if(Q)throw new ce.ErrnoError(Q);if(!ae.node_ops.rmdir)throw new ce.ErrnoError(63);if(ce.isMountpoint(j))throw new ce.ErrnoError(10);ae.node_ops.rmdir(ae,O),ce.destroyNode(j)},readdir($){var ee=ce.lookupPath($,{follow:!0}),ae=ee.node;if(!ae.node_ops.readdir)throw new ce.ErrnoError(54);return ae.node_ops.readdir(ae)},unlink($){var ee=ce.lookupPath($,{parent:!0}),ae=ee.node;if(!ae)throw new ce.ErrnoError(44);var O=zt.basename($),j=ce.lookupNode(ae,O),Q=ce.mayDelete(ae,O,!1);if(Q)throw new ce.ErrnoError(Q);if(!ae.node_ops.unlink)throw new ce.ErrnoError(63);if(ce.isMountpoint(j))throw new ce.ErrnoError(10);ae.node_ops.unlink(ae,O),ce.destroyNode(j)},readlink($){var ee=ce.lookupPath($),ae=ee.node;if(!ae)throw new ce.ErrnoError(44);if(!ae.node_ops.readlink)throw new ce.ErrnoError(28);return ae.node_ops.readlink(ae)},stat($,ee){var ae=ce.lookupPath($,{follow:!ee}),O=ae.node;if(!O)throw new ce.ErrnoError(44);if(!O.node_ops.getattr)throw new ce.ErrnoError(63);return O.node_ops.getattr(O)},lstat($){return ce.stat($,!0)},chmod($,ee,ae){var O;if(typeof $=="string"){var j=ce.lookupPath($,{follow:!ae});O=j.node}else O=$;if(!O.node_ops.setattr)throw new ce.ErrnoError(63);O.node_ops.setattr(O,{mode:ee&4095|O.mode&-4096,ctime:Date.now()})},lchmod($,ee){ce.chmod($,ee,!0)},fchmod($,ee){var ae=ce.getStreamChecked($);ce.chmod(ae.node,ee)},chown($,ee,ae,O){var j;if(typeof $=="string"){var Q=ce.lookupPath($,{follow:!O});j=Q.node}else j=$;if(!j.node_ops.setattr)throw new ce.ErrnoError(63);j.node_ops.setattr(j,{timestamp:Date.now()})},lchown($,ee,ae){ce.chown($,ee,ae,!0)},fchown($,ee,ae){var O=ce.getStreamChecked($);ce.chown(O.node,ee,ae)},truncate($,ee){if(ee<0)throw new ce.ErrnoError(28);var ae;if(typeof $=="string"){var O=ce.lookupPath($,{follow:!0});ae=O.node}else ae=$;if(!ae.node_ops.setattr)throw new ce.ErrnoError(63);if(ce.isDir(ae.mode))throw new ce.ErrnoError(31);if(!ce.isFile(ae.mode))throw new ce.ErrnoError(28);var j=ce.nodePermissions(ae,"w");if(j)throw new ce.ErrnoError(j);ae.node_ops.setattr(ae,{size:ee,timestamp:Date.now()})},ftruncate($,ee){var ae=ce.getStreamChecked($);if((ae.flags&2097155)===0)throw new ce.ErrnoError(28);ce.truncate(ae.node,ee)},utime($,ee,ae){var O=ce.lookupPath($,{follow:!0}),j=O.node;j.node_ops.setattr(j,{atime:ee,mtime:ae})},open($,ee,ae=438){if($==="")throw new ce.ErrnoError(44);ee=typeof ee=="string"?mt(ee):ee,ee&64?ae=ae&4095|32768:ae=0;var O;if(typeof $=="object")O=$;else{var j=ce.lookupPath($,{follow:!(ee&131072),noent_okay:!0});O=j.node,$=j.path}var Q=!1;if(ee&64)if(O){if(ee&128)throw new ce.ErrnoError(20)}else O=ce.mknod($,ae,0),Q=!0;if(!O)throw new ce.ErrnoError(44);if(ce.isChrdev(O.mode)&&(ee&=-513),ee&65536&&!ce.isDir(O.mode))throw new ce.ErrnoError(54);if(!Q){var ie=ce.mayOpen(O,ee);if(ie)throw new ce.ErrnoError(ie)}ee&512&&!Q&&ce.truncate(O,0),ee&=-131713;var he=ce.createStream({node:O,path:ce.getPath(O),flags:ee,seekable:!0,position:0,stream_ops:O.stream_ops,ungotten:[],error:!1});return he.stream_ops.open&&he.stream_ops.open(he),s.logReadFiles&&!(ee&1)&&($ in ce.readFiles||(ce.readFiles[$]=1)),he},close($){if(ce.isClosed($))throw new ce.ErrnoError(8);$.getdents&&($.getdents=null);try{$.stream_ops.close&&$.stream_ops.close($)}catch(ee){throw ee}finally{ce.closeStream($.fd)}$.fd=null},isClosed($){return $.fd===null},llseek($,ee,ae){if(ce.isClosed($))throw new ce.ErrnoError(8);if(!$.seekable||!$.stream_ops.llseek)throw new ce.ErrnoError(70);if(ae!=0&&ae!=1&&ae!=2)throw new ce.ErrnoError(28);return $.position=$.stream_ops.llseek($,ee,ae),$.ungotten=[],$.position},read($,ee,ae,O,j){if(O<0||j<0)throw new ce.ErrnoError(28);if(ce.isClosed($))throw new ce.ErrnoError(8);if(($.flags&2097155)===1)throw new ce.ErrnoError(8);if(ce.isDir($.node.mode))throw new ce.ErrnoError(31);if(!$.stream_ops.read)throw new ce.ErrnoError(28);var Q=typeof j<"u";if(!Q)j=$.position;else if(!$.seekable)throw new ce.ErrnoError(70);var ie=$.stream_ops.read($,ee,ae,O,j);return Q||($.position+=ie),ie},write($,ee,ae,O,j,Q){if(O<0||j<0)throw new ce.ErrnoError(28);if(ce.isClosed($))throw new ce.ErrnoError(8);if(($.flags&2097155)===0)throw new ce.ErrnoError(8);if(ce.isDir($.node.mode))throw new ce.ErrnoError(31);if(!$.stream_ops.write)throw new ce.ErrnoError(28);$.seekable&&$.flags&1024&&ce.llseek($,0,2);var ie=typeof j<"u";if(!ie)j=$.position;else if(!$.seekable)throw new ce.ErrnoError(70);var he=$.stream_ops.write($,ee,ae,O,j,Q);return ie||($.position+=he),he},allocate($,ee,ae){if(ce.isClosed($))throw new ce.ErrnoError(8);if(ee<0||ae<=0)throw new ce.ErrnoError(28);if(($.flags&2097155)===0)throw new ce.ErrnoError(8);if(!ce.isFile($.node.mode)&&!ce.isDir($.node.mode))throw new ce.ErrnoError(43);if(!$.stream_ops.allocate)throw new ce.ErrnoError(138);$.stream_ops.allocate($,ee,ae)},mmap($,ee,ae,O,j){if((O&2)!==0&&(j&2)===0&&($.flags&2097155)!==2)throw new ce.ErrnoError(2);if(($.flags&2097155)===1)throw new ce.ErrnoError(2);if(!$.stream_ops.mmap)throw new ce.ErrnoError(43);if(!ee)throw new ce.ErrnoError(28);return $.stream_ops.mmap($,ee,ae,O,j)},msync($,ee,ae,O,j){return $.stream_ops.msync?$.stream_ops.msync($,ee,ae,O,j):0},ioctl($,ee,ae){if(!$.stream_ops.ioctl)throw new ce.ErrnoError(59);return $.stream_ops.ioctl($,ee,ae)},readFile($,ee={}){if(ee.flags=ee.flags||0,ee.encoding=ee.encoding||"binary",ee.encoding!=="utf8"&&ee.encoding!=="binary")throw new Error(`Invalid encoding type "${ee.encoding}"`);var ae,O=ce.open($,ee.flags),j=ce.stat($),Q=j.size,ie=new Uint8Array(Q);return ce.read(O,ie,0,Q,0),ee.encoding==="utf8"?ae=dt(ie):ee.encoding==="binary"&&(ae=ie),ce.close(O),ae},writeFile($,ee,ae={}){ae.flags=ae.flags||577;var O=ce.open($,ae.flags,ae.mode);if(typeof ee=="string"){var j=new Uint8Array(nr(ee)+1),Q=Ar(ee,j,0,j.length);ce.write(O,j,0,Q,void 0,ae.canOwn)}else if(ArrayBuffer.isView(ee))ce.write(O,ee,0,ee.byteLength,void 0,ae.canOwn);else throw new Error("Unsupported data type");ce.close(O)},cwd:()=>ce.currentPath,chdir($){var ee=ce.lookupPath($,{follow:!0});if(ee.node===null)throw new ce.ErrnoError(44);if(!ce.isDir(ee.node.mode))throw new ce.ErrnoError(54);var ae=ce.nodePermissions(ee.node,"x");if(ae)throw new ce.ErrnoError(ae);ce.currentPath=ee.path},createDefaultDirectories(){ce.mkdir("/tmp"),ce.mkdir("/home"),ce.mkdir("/home/web_user")},createDefaultDevices(){ce.mkdir("/dev"),ce.registerDevice(ce.makedev(1,3),{read:()=>0,write:(O,j,Q,ie,he)=>ie,llseek:()=>0}),ce.mkdev("/dev/null",ce.makedev(1,3)),oi.register(ce.makedev(5,0),oi.default_tty_ops),oi.register(ce.makedev(6,0),oi.default_tty1_ops),ce.mkdev("/dev/tty",ce.makedev(5,0)),ce.mkdev("/dev/tty1",ce.makedev(6,0));var $=new Uint8Array(1024),ee=0,ae=()=>(ee===0&&(ee=Mr($).byteLength),$[--ee]);ce.createDevice("/dev","random",ae),ce.createDevice("/dev","urandom",ae),ce.mkdir("/dev/shm"),ce.mkdir("/dev/shm/tmp")},createSpecialDirectories(){ce.mkdir("/proc");var $=ce.mkdir("/proc/self");ce.mkdir("/proc/self/fd"),ce.mount({mount(){var ee=ce.createNode($,"fd",16895,73);return ee.stream_ops={llseek:rr.stream_ops.llseek},ee.node_ops={lookup(ae,O){var j=+O,Q=ce.getStreamChecked(j),ie={parent:null,mount:{mountpoint:"fake"},node_ops:{readlink:()=>Q.path},id:j+1};return ie.parent=ie,ie},readdir(){return Array.from(ce.streams.entries()).filter(([ae,O])=>O).map(([ae,O])=>ae.toString())}},ee}},{},"/proc/self/fd")},createStandardStreams($,ee,ae){$?ce.createDevice("/dev","stdin",$):ce.symlink("/dev/tty","/dev/stdin"),ee?ce.createDevice("/dev","stdout",null,ee):ce.symlink("/dev/tty","/dev/stdout"),ae?ce.createDevice("/dev","stderr",null,ae):ce.symlink("/dev/tty1","/dev/stderr"),ce.open("/dev/stdin",0),ce.open("/dev/stdout",1),ce.open("/dev/stderr",1)},staticInit(){ce.nameTable=new Array(4096),ce.mount(rr,{},"/"),ce.createDefaultDirectories(),ce.createDefaultDevices(),ce.createSpecialDirectories(),ce.filesystems={MEMFS:rr}},init($,ee,ae){ce.initialized=!0,$??($=s.stdin),ee??(ee=s.stdout),ae??(ae=s.stderr),ce.createStandardStreams($,ee,ae)},quit(){ce.initialized=!1;for(var $=0;$<ce.streams.length;$++){var ee=ce.streams[$];ee&&ce.close(ee)}},findObject($,ee){var ae=ce.analyzePath($,ee);return ae.exists?ae.object:null},analyzePath($,ee){try{var ae=ce.lookupPath($,{follow:!ee});$=ae.path}catch{}var O={isRoot:!1,exists:!1,error:0,name:null,path:null,object:null,parentExists:!1,parentPath:null,parentObject:null};try{var ae=ce.lookupPath($,{parent:!0});O.parentExists=!0,O.parentPath=ae.path,O.parentObject=ae.node,O.name=zt.basename($),ae=ce.lookupPath($,{follow:!ee}),O.exists=!0,O.path=ae.path,O.object=ae.node,O.name=ae.node.name,O.isRoot=ae.path==="/"}catch(j){O.error=j.errno}return O},createPath($,ee,ae,O){$=typeof $=="string"?$:ce.getPath($);for(var j=ee.split("/").reverse();j.length;){var Q=j.pop();if(Q){var ie=zt.join2($,Q);try{ce.mkdir(ie)}catch{}$=ie}}return ie},createFile($,ee,ae,O,j){var Q=zt.join2(typeof $=="string"?$:ce.getPath($),ee),ie=gr(O,j);return ce.create(Q,ie)},createDataFile($,ee,ae,O,j,Q){var ie=ee;$&&($=typeof $=="string"?$:ce.getPath($),ie=ee?zt.join2($,ee):$);var he=gr(O,j),Oe=ce.create(ie,he);if(ae){if(typeof ae=="string"){for(var Fe=new Array(ae.length),Ge=0,lt=ae.length;Ge<lt;++Ge)Fe[Ge]=ae.charCodeAt(Ge);ae=Fe}ce.chmod(Oe,he|146);var Ot=ce.open(Oe,577);ce.write(Ot,ae,0,ae.length,0,Q),ce.close(Ot),ce.chmod(Oe,he)}},createDevice($,ee,ae,O){var he;var j=zt.join2(typeof $=="string"?$:ce.getPath($),ee),Q=gr(!!ae,!!O);(he=ce.createDevice).major??(he.major=64);var ie=ce.makedev(ce.createDevice.major++,0);return ce.registerDevice(ie,{open(Oe){Oe.seekable=!1},close(Oe){var Fe;(Fe=O==null?void 0:O.buffer)!=null&&Fe.length&&O(10)},read(Oe,Fe,Ge,lt,Ot){for(var St=0,jt=0;jt<lt;jt++){var cr;try{cr=ae()}catch{throw new ce.ErrnoError(29)}if(cr===void 0&&St===0)throw new ce.ErrnoError(6);if(cr==null)break;St++,Fe[Ge+jt]=cr}return St&&(Oe.node.atime=Date.now()),St},write(Oe,Fe,Ge,lt,Ot){for(var St=0;St<lt;St++)try{O(Fe[Ge+St])}catch{throw new ce.ErrnoError(29)}return lt&&(Oe.node.mtime=Oe.node.ctime=Date.now()),St}}),ce.mkdev(j,Q,ie)},forceLoadFile($){if($.isDevice||$.isFolder||$.link||$.contents)return!0;if(typeof XMLHttpRequest<"u")throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");try{$.contents=m($.url),$.usedBytes=$.contents.length}catch{throw new ce.ErrnoError(29)}},createLazyFile($,ee,ae,O,j){class Q{constructor(){Go(this,"lengthKnown",!1);Go(this,"chunks",[])}get(St){if(!(St>this.length-1||St<0)){var jt=St%this.chunkSize,cr=St/this.chunkSize|0;return this.getter(cr)[jt]}}setDataGetter(St){this.getter=St}cacheLength(){var St=new XMLHttpRequest;if(St.open("HEAD",ae,!1),St.send(null),!(St.status>=200&&St.status<300||St.status===304))throw new Error("Couldn't load "+ae+". Status: "+St.status);var jt=Number(St.getResponseHeader("Content-length")),cr,or=(cr=St.getResponseHeader("Accept-Ranges"))&&cr==="bytes",mr=(cr=St.getResponseHeader("Content-Encoding"))&&cr==="gzip",Vr=1024*1024;or||(Vr=jt);var ei=(Ei,jr)=>{if(Ei>jr)throw new Error("invalid range ("+Ei+", "+jr+") or no bytes requested!");if(jr>jt-1)throw new Error("only "+jt+" bytes available! programmer error!");var cn=new XMLHttpRequest;if(cn.open("GET",ae,!1),jt!==Vr&&cn.setRequestHeader("Range","bytes="+Ei+"-"+jr),cn.responseType="arraybuffer",cn.overrideMimeType&&cn.overrideMimeType("text/plain; charset=x-user-defined"),cn.send(null),!(cn.status>=200&&cn.status<300||cn.status===304))throw new Error("Couldn't load "+ae+". Status: "+cn.status);return cn.response!==void 0?new Uint8Array(cn.response||[]):Qr(cn.responseText||"")},ui=this;ui.setDataGetter(Ei=>{var jr=Ei*Vr,cn=(Ei+1)*Vr-1;if(cn=Math.min(cn,jt-1),typeof ui.chunks[Ei]>"u"&&(ui.chunks[Ei]=ei(jr,cn)),typeof ui.chunks[Ei]>"u")throw new Error("doXHR failed!");return ui.chunks[Ei]}),(mr||!jt)&&(Vr=jt=1,jt=this.getter(0).length,Vr=jt,b("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=jt,this._chunkSize=Vr,this.lengthKnown=!0}get length(){return this.lengthKnown||this.cacheLength(),this._length}get chunkSize(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}if(typeof XMLHttpRequest<"u"){throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var ie,he}else var he={isDevice:!1,url:ae};var Oe=ce.createFile($,ee,he,O,j);he.contents?Oe.contents=he.contents:he.url&&(Oe.contents=null,Oe.url=he.url),Object.defineProperties(Oe,{usedBytes:{get:function(){return this.contents.length}}});var Fe={},Ge=Object.keys(Oe.stream_ops);Ge.forEach(Ot=>{var St=Oe.stream_ops[Ot];Fe[Ot]=(...jt)=>(ce.forceLoadFile(Oe),St(...jt))});function lt(Ot,St,jt,cr,or){var mr=Ot.node.contents;if(or>=mr.length)return 0;var Vr=Math.min(mr.length-or,cr);if(mr.slice)for(var ei=0;ei<Vr;ei++)St[jt+ei]=mr[or+ei];else for(var ei=0;ei<Vr;ei++)St[jt+ei]=mr.get(or+ei);return Vr}return Fe.read=(Ot,St,jt,cr,or)=>(ce.forceLoadFile(Oe),lt(Ot,St,jt,cr,or)),Fe.mmap=(Ot,St,jt,cr,or)=>{ce.forceLoadFile(Oe);var mr=vi();if(!mr)throw new ce.ErrnoError(48);return lt(Ot,E,mr,St,jt),{ptr:mr,allocated:!0}},Oe.stream_ops=Fe,Oe}},fr=($,ee)=>($>>>=0,$?dt(A,$,ee):""),Yt={DEFAULT_POLLMASK:5,calculateAt($,ee,ae){if(zt.isAbs(ee))return ee;var O;if($===-100)O=ce.cwd();else{var j=Yt.getStreamFromFD($);O=j.path}if(ee.length==0){if(!ae)throw new ce.ErrnoError(44);return O}return O+"/"+ee},doStat($,ee,ae){var O=$(ee);D[ae>>>2>>>0]=O.dev,D[ae+4>>>2>>>0]=O.mode,F[ae+8>>>2>>>0]=O.nlink,D[ae+12>>>2>>>0]=O.uid,D[ae+16>>>2>>>0]=O.gid,D[ae+20>>>2>>>0]=O.rdev,it=[O.size>>>0,(Qe=O.size,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ae+24>>>2>>>0]=it[0],D[ae+28>>>2>>>0]=it[1],D[ae+32>>>2>>>0]=4096,D[ae+36>>>2>>>0]=O.blocks;var j=O.atime.getTime(),Q=O.mtime.getTime(),ie=O.ctime.getTime();return it=[Math.floor(j/1e3)>>>0,(Qe=Math.floor(j/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ae+40>>>2>>>0]=it[0],D[ae+44>>>2>>>0]=it[1],F[ae+48>>>2>>>0]=j%1e3*1e3*1e3,it=[Math.floor(Q/1e3)>>>0,(Qe=Math.floor(Q/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ae+56>>>2>>>0]=it[0],D[ae+60>>>2>>>0]=it[1],F[ae+64>>>2>>>0]=Q%1e3*1e3*1e3,it=[Math.floor(ie/1e3)>>>0,(Qe=Math.floor(ie/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ae+72>>>2>>>0]=it[0],D[ae+76>>>2>>>0]=it[1],F[ae+80>>>2>>>0]=ie%1e3*1e3*1e3,it=[O.ino>>>0,(Qe=O.ino,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ae+88>>>2>>>0]=it[0],D[ae+92>>>2>>>0]=it[1],0},doMsync($,ee,ae,O,j){if(!ce.isFile(ee.node.mode))throw new ce.ErrnoError(43);if(O&2)return 0;var Q=A.slice($,$+ae);ce.msync(ee,Q,j,ae,O)},getStreamFromFD($){var ee=ce.getStreamChecked($);return ee},varargs:void 0,getStr($){var ee=fr($);return ee}};function Lr($,ee,ae){ae>>>=0,Yt.varargs=ae;try{var O=Yt.getStreamFromFD($);switch(ee){case 0:{var j=Pt();if(j<0)return-28;for(;ce.streams[j];)j++;var Q;return Q=ce.dupStream(O,j),Q.fd}case 1:case 2:return 0;case 3:return O.flags;case 4:{var j=Pt();return O.flags|=j,0}case 12:{var j=Jt(),ie=0;return R[j+ie>>>1>>>0]=2,0}case 13:case 14:return 0}return-28}catch(he){if(typeof ce>"u"||he.name!=="ErrnoError")throw he;return-he.errno}}function Cr($,ee,ae){ae>>>=0,Yt.varargs=ae;try{var O=Yt.getStreamFromFD($);switch(ee){case 21509:return O.tty?0:-59;case 21505:{if(!O.tty)return-59;if(O.tty.ops.ioctl_tcgets){var j=O.tty.ops.ioctl_tcgets(O),Q=Jt();D[Q>>>2>>>0]=j.c_iflag||0,D[Q+4>>>2>>>0]=j.c_oflag||0,D[Q+8>>>2>>>0]=j.c_cflag||0,D[Q+12>>>2>>>0]=j.c_lflag||0;for(var ie=0;ie<32;ie++)E[Q+ie+17>>>0]=j.c_cc[ie]||0;return 0}return 0}case 21510:case 21511:case 21512:return O.tty?0:-59;case 21506:case 21507:case 21508:{if(!O.tty)return-59;if(O.tty.ops.ioctl_tcsets){for(var Q=Jt(),he=D[Q>>>2>>>0],Oe=D[Q+4>>>2>>>0],Fe=D[Q+8>>>2>>>0],Ge=D[Q+12>>>2>>>0],lt=[],ie=0;ie<32;ie++)lt.push(E[Q+ie+17>>>0]);return O.tty.ops.ioctl_tcsets(O.tty,ee,{c_iflag:he,c_oflag:Oe,c_cflag:Fe,c_lflag:Ge,c_cc:lt})}return 0}case 21519:{if(!O.tty)return-59;var Q=Jt();return D[Q>>>2>>>0]=0,0}case 21520:return O.tty?-28:-59;case 21531:{var Q=Jt();return ce.ioctl(O,ee,Q)}case 21523:{if(!O.tty)return-59;if(O.tty.ops.ioctl_tiocgwinsz){var Ot=O.tty.ops.ioctl_tiocgwinsz(O.tty),Q=Jt();R[Q>>>1>>>0]=Ot[0],R[Q+2>>>1>>>0]=Ot[1]}return 0}case 21524:return O.tty?0:-59;case 21515:return O.tty?0:-59;default:return-28}}catch(St){if(typeof ce>"u"||St.name!=="ErrnoError")throw St;return-St.errno}}function zr($,ee,ae,O){ee>>>=0,O>>>=0,Yt.varargs=O;try{ee=Yt.getStr(ee),ee=Yt.calculateAt($,ee);var j=O?Pt():0;return ce.open(ee,ae,j).fd}catch(Q){if(typeof ce>"u"||Q.name!=="ErrnoError")throw Q;return-Q.errno}}function fi($,ee){$>>>=0,ee>>>=0;try{return $=Yt.getStr($),Yt.doStat(ce.stat,$,ee)}catch(ae){if(typeof ce>"u"||ae.name!=="ErrnoError")throw ae;return-ae.errno}}var to=()=>we(""),st=($,ee)=>Object.defineProperty(ee,"name",{value:$}),zo=[],hi=[],si,sr=$=>{throw new si($)},Ns=()=>hi.length/2-5-zo.length,ts=()=>{hi.push(0,1,void 0,1,null,1,!0,1,!1,1),s.count_emval_handles=Ns},Z={toValue:$=>($||sr("Cannot use deleted val. handle = "+$),hi[$]),toHandle:$=>{switch($){case void 0:return 2;case null:return 4;case!0:return 6;case!1:return 8;default:{const ee=zo.pop()||hi.length;return hi[ee]=$,hi[ee+1]=1,ee}}}},re=($,ee)=>{var ae=st(ee,function(O){this.name=ee,this.message=O;var j=new Error(O).stack;j!==void 0&&(this.stack=this.toString()+`
`+j.replace(/^Error(:[^\n]*)?\n/,""))});return ae.prototype=Object.create($.prototype),ae.prototype.constructor=ae,ae.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},ae},ye,Ye=()=>{for(var $=new Array(256),ee=0;ee<256;++ee)$[ee]=String.fromCharCode(ee);gt=$},gt,Dt=$=>{for(var ee="",ae=$;A[ae>>>0];)ee+=gt[A[ae++>>>0]];return ee},pr={},Gr=($,ee)=>{for(ee===void 0&&sr("ptr should not be undefined");$.baseClass;)ee=$.upcast(ee),$=$.baseClass;return ee},rn=($,ee,ae)=>{ee=Gr($,ee),pr.hasOwnProperty(ee)?sr(`Tried to register registered instance: ${ee}`):pr[ee]=ae},ro={},na=$=>{var ee=Al($),ae=Dt(ee);return xi(ee),ae},yl=($,ee)=>{var ae=ro[$];return ae===void 0&&sr(`${ee} has unknown type ${na($)}`),ae},Ga=($,ee)=>{ee=Gr($,ee),pr.hasOwnProperty(ee)?delete pr[ee]:sr(`Tried to unregister unregistered instance: ${ee}`)},ys=$=>{},tc=!1,rs=$=>{$.smartPtr?$.smartPtrType.rawDestructor($.smartPtr):$.ptrType.registeredClass.rawDestructor($.ptr)},rc=$=>{$.count.value-=1;var ee=$.count.value===0;ee&&rs($)},Hl=($,ee,ae)=>{if(ee===ae)return $;if(ae.baseClass===void 0)return null;var O=Hl($,ee,ae.baseClass);return O===null?null:ae.downcast(O)},fu={},hu=($,ee)=>(ee=Gr($,ee),pr[ee]),ic,rl=$=>{throw new ic($)},oa=($,ee)=>{(!ee.ptrType||!ee.ptr)&&rl("makeClassHandle requires ptr and ptrType");var ae=!!ee.smartPtrType,O=!!ee.smartPtr;return ae!==O&&rl("Both smartPtrType and smartPtr must be specified"),ee.count={value:1},Ya(Object.create($,{$$:{value:ee,writable:!0}}))};function Wd($){var ee=this.getPointee($);if(!ee)return this.destructor($),null;var ae=hu(this.registeredClass,ee);if(ae!==void 0){if(ae.$$.count.value===0)return ae.$$.ptr=ee,ae.$$.smartPtr=$,ae.clone();var O=ae.clone();return this.destructor($),O}function j(){return this.isSmartPointer?oa(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:ee,smartPtrType:this,smartPtr:$}):oa(this.registeredClass.instancePrototype,{ptrType:this,ptr:$})}var Q=this.registeredClass.getActualType(ee),ie=fu[Q];if(!ie)return j.call(this);var he;this.isConst?he=ie.constPointerType:he=ie.pointerType;var Oe=Hl(ee,this.registeredClass,he.registeredClass);return Oe===null?j.call(this):this.isSmartPointer?oa(he.registeredClass.instancePrototype,{ptrType:he,ptr:Oe,smartPtrType:this,smartPtr:$}):oa(he.registeredClass.instancePrototype,{ptrType:he,ptr:Oe})}var Ya=$=>typeof FinalizationRegistry>"u"?(Ya=ee=>ee,$):(tc=new FinalizationRegistry(ee=>{rc(ee.$$)}),Ya=ee=>{var ae=ee.$$,O=!!ae.smartPtr;if(O){var j={$$:ae};tc.register(ee,j,ee)}return ee},ys=ee=>tc.unregister(ee),Ya($));function cd($,ee,ae){$>>>=0,ee>>>=0,ae>>>=0,$=Dt($),ee=yl(ee,"wrapper"),ae=Z.toValue(ae);var O=ee.registeredClass,j=O.instancePrototype,Q=O.baseClass,ie=Q.instancePrototype,he=O.baseClass.constructor,Oe=st($,function(...Fe){O.baseClass.pureVirtualFunctions.forEach((function(Ge){if(this[Ge]===ie[Ge])throw new ye(`Pure virtual function ${Ge} must be implemented in JavaScript`)}).bind(this)),Object.defineProperty(this,"__parent",{value:j}),this.__construct(...Fe)});return j.__construct=function(...Ge){this===j&&sr("Pass correct 'this' to __construct");var lt=he.implement(this,...Ge);ys(lt);var Ot=lt.$$;lt.notifyOnDestruction(),Ot.preservePointerOnDelete=!0,Object.defineProperties(this,{$$:{value:Ot}}),Ya(this),rn(O,Ot.ptr,this)},j.__destruct=function(){this===j&&sr("Pass correct 'this' to __destruct"),ys(this),Ga(O,this.$$.ptr)},Oe.prototype=Object.create(j),Object.assign(Oe.prototype,ae),Z.toHandle(Oe)}function ml($,ee,ae,O,j){}var Fs={},Ul={},wo=($,ee,ae)=>{$.forEach(he=>Ul[he]=ee);function O(he){var Oe=ae(he);Oe.length!==$.length&&rl("Mismatched type converter count");for(var Fe=0;Fe<$.length;++Fe)Lo($[Fe],Oe[Fe])}var j=new Array(ee.length),Q=[],ie=0;ee.forEach((he,Oe)=>{ro.hasOwnProperty(he)?j[Oe]=ro[he]:(Q.push(he),Fs.hasOwnProperty(he)||(Fs[he]=[]),Fs[he].push(()=>{j[Oe]=ro[he],++ie,ie===Q.length&&O(j)}))}),Q.length===0&&O(j)};function Ta($,ee,ae={}){var O=ee.name;if($||sr(`type "${O}" must have a positive integer typeid pointer`),ro.hasOwnProperty($)){if(ae.ignoreDuplicateRegistrations)return;sr(`Cannot register type '${O}' twice`)}if(ro[$]=ee,delete Ul[$],Fs.hasOwnProperty($)){var j=Fs[$];delete Fs[$],j.forEach(Q=>Q())}}function Lo($,ee,ae={}){return Ta($,ee,ae)}var ao=8;function bl($,ee,ae,O){$>>>=0,ee>>>=0,ee=Dt(ee),Lo($,{name:ee,fromWireType:function(j){return!!j},toWireType:function(j,Q){return Q?ae:O},argPackAdvance:ao,readValueFromPointer:function(j){return this.fromWireType(A[j>>>0])},destructorFunction:null})}var nc=$=>({count:$.count,deleteScheduled:$.deleteScheduled,preservePointerOnDelete:$.preservePointerOnDelete,ptr:$.ptr,ptrType:$.ptrType,smartPtr:$.smartPtr,smartPtrType:$.smartPtrType}),Vu=$=>{function ee(ae){return ae.$$.ptrType.registeredClass.name}sr(ee($)+" instance already deleted")},dd=()=>{Object.assign(xa.prototype,{isAliasOf($){if(!(this instanceof xa)||!($ instanceof xa))return!1;var ee=this.$$.ptrType.registeredClass,ae=this.$$.ptr;$.$$=$.$$;for(var O=$.$$.ptrType.registeredClass,j=$.$$.ptr;ee.baseClass;)ae=ee.upcast(ae),ee=ee.baseClass;for(;O.baseClass;)j=O.upcast(j),O=O.baseClass;return ee===O&&ae===j},clone(){if(this.$$.ptr||Vu(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var $=Ya(Object.create(Object.getPrototypeOf(this),{$$:{value:nc(this.$$)}}));return $.$$.count.value+=1,$.$$.deleteScheduled=!1,$},delete(){this.$$.ptr||Vu(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&sr("Object already scheduled for deletion"),ys(this),rc(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)},isDeleted(){return!this.$$.ptr},deleteLater(){return this.$$.ptr||Vu(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&sr("Object already scheduled for deletion"),this.$$.deleteScheduled=!0,this}})};function xa(){}var Fa=($,ee,ae)=>{if($[ee].overloadTable===void 0){var O=$[ee];$[ee]=function(...j){return $[ee].overloadTable.hasOwnProperty(j.length)||sr(`Function '${ae}' called with an invalid number of arguments (${j.length}) - expects one of (${$[ee].overloadTable})!`),$[ee].overloadTable[j.length].apply(this,j)},$[ee].overloadTable=[],$[ee].overloadTable[O.argCount]=O}},va=($,ee,ae)=>{s.hasOwnProperty($)?((ae===void 0||s[$].overloadTable!==void 0&&s[$].overloadTable[ae]!==void 0)&&sr(`Cannot register public name '${$}' twice`),Fa(s,$,$),s[$].overloadTable.hasOwnProperty(ae)&&sr(`Cannot register multiple overloads of a function with the same number of arguments (${ae})!`),s[$].overloadTable[ae]=ee):(s[$]=ee,s[$].argCount=ae)},Gd=48,Oc=57,il=$=>{$=$.replace(/[^a-zA-Z0-9_]/g,"$");var ee=$.charCodeAt(0);return ee>=Gd&&ee<=Oc?`_${$}`:$};function aa($,ee,ae,O,j,Q,ie,he){this.name=$,this.constructor=ee,this.instancePrototype=ae,this.rawDestructor=O,this.baseClass=j,this.getActualType=Q,this.upcast=ie,this.downcast=he,this.pureVirtualFunctions=[]}var Qi=($,ee,ae)=>{for(;ee!==ae;)ee.upcast||sr(`Expected null or instance of ${ae.name}, got an instance of ${ee.name}`),$=ee.upcast($),ee=ee.baseClass;return $};function mn($,ee){if(ee===null)return this.isReference&&sr(`null is not a valid ${this.name}`),0;ee.$$||sr(`Cannot pass "${pd(ee)}" as a ${this.name}`),ee.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`);var ae=ee.$$.ptrType.registeredClass,O=Qi(ee.$$.ptr,ae,this.registeredClass);return O}function oc($,ee){var ae;if(ee===null)return this.isReference&&sr(`null is not a valid ${this.name}`),this.isSmartPointer?(ae=this.rawConstructor(),$!==null&&$.push(this.rawDestructor,ae),ae):0;(!ee||!ee.$$)&&sr(`Cannot pass "${pd(ee)}" as a ${this.name}`),ee.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`),!this.isConst&&ee.$$.ptrType.isConst&&sr(`Cannot convert argument of type ${ee.$$.smartPtrType?ee.$$.smartPtrType.name:ee.$$.ptrType.name} to parameter type ${this.name}`);var O=ee.$$.ptrType.registeredClass;if(ae=Qi(ee.$$.ptr,O,this.registeredClass),this.isSmartPointer)switch(ee.$$.smartPtr===void 0&&sr("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:ee.$$.smartPtrType===this?ae=ee.$$.smartPtr:sr(`Cannot convert argument of type ${ee.$$.smartPtrType?ee.$$.smartPtrType.name:ee.$$.ptrType.name} to parameter type ${this.name}`);break;case 1:ae=ee.$$.smartPtr;break;case 2:if(ee.$$.smartPtrType===this)ae=ee.$$.smartPtr;else{var j=ee.clone();ae=this.rawShare(ae,Z.toHandle(()=>j.delete())),$!==null&&$.push(this.rawDestructor,ae)}break;default:sr("Unsupporting sharing policy")}return ae}function _e($,ee){if(ee===null)return this.isReference&&sr(`null is not a valid ${this.name}`),0;ee.$$||sr(`Cannot pass "${pd(ee)}" as a ${this.name}`),ee.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`),ee.$$.ptrType.isConst&&sr(`Cannot convert argument of type ${ee.$$.ptrType.name} to parameter type ${this.name}`);var ae=ee.$$.ptrType.registeredClass,O=Qi(ee.$$.ptr,ae,this.registeredClass);return O}function He($){return this.fromWireType(F[$>>>2>>>0])}var et=()=>{Object.assign(ht.prototype,{getPointee($){return this.rawGetPointee&&($=this.rawGetPointee($)),$},destructor($){var ee;(ee=this.rawDestructor)==null||ee.call(this,$)},argPackAdvance:ao,readValueFromPointer:He,fromWireType:Wd})};function ht($,ee,ae,O,j,Q,ie,he,Oe,Fe,Ge){this.name=$,this.registeredClass=ee,this.isReference=ae,this.isConst=O,this.isSmartPointer=j,this.pointeeType=Q,this.sharingPolicy=ie,this.rawGetPointee=he,this.rawConstructor=Oe,this.rawShare=Fe,this.rawDestructor=Ge,!j&&ee.baseClass===void 0?O?(this.toWireType=mn,this.destructorFunction=null):(this.toWireType=_e,this.destructorFunction=null):this.toWireType=oc}var Ft=($,ee,ae)=>{s.hasOwnProperty($)||rl("Replacing nonexistent public symbol"),s[$].overloadTable!==void 0&&ae!==void 0?s[$].overloadTable[ae]=ee:(s[$]=ee,s[$].argCount=ae)},ur=($,ee,ae)=>{$=$.replace(/p/g,"i");var O=s["dynCall_"+$];return O(ee,...ae)},Lt,Kt=$=>Lt.get($),Zr=($,ee,ae=[])=>{if($.includes("j"))return ur($,ee,ae);var O=Kt(ee)(...ae);return $[0]=="p"?O>>>0:O},ni=($,ee)=>(...ae)=>Zr($,ee,ae),pi=($,ee)=>{$=Dt($);function ae(){return $.includes("j")||$.includes("p")?ni($,ee):Kt(ee)}var O=ae();return typeof O!="function"&&sr(`unknown function pointer with signature ${$}: ${ee}`),O},Oi,Bi=($,ee)=>{var ae=[],O={};function j(Q){if(!O[Q]&&!ro[Q]){if(Ul[Q]){Ul[Q].forEach(j);return}ae.push(Q),O[Q]=!0}}throw ee.forEach(j),new Oi(`${$}: `+ae.map(na).join([", "]))};function ms($,ee,ae,O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot){$>>>=0,ee>>>=0,ae>>>=0,O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0,Ge>>>=0,lt>>>=0,Ot>>>=0,Ge=Dt(Ge),Q=pi(j,Q),he&&(he=pi(ie,he)),Fe&&(Fe=pi(Oe,Fe)),Ot=pi(lt,Ot);var St=il(Ge);va(St,function(){Bi(`Cannot construct ${Ge} due to unbound types`,[O])}),wo([$,ee,ae],O?[O]:[],jt=>{var cn;jt=jt[0];var cr,or;O?(cr=jt.registeredClass,or=cr.instancePrototype):or=xa.prototype;var mr=st(Ge,function(...ji){if(Object.getPrototypeOf(this)!==Vr)throw new si("Use 'new' to construct "+Ge);if(ei.constructor_body===void 0)throw new si(Ge+" has no accessible constructor");var Kr=ei.constructor_body[ji.length];if(Kr===void 0)throw new si(`Tried to invoke ctor of ${Ge} with invalid number of parameters (${ji.length}) - expected (${Object.keys(ei.constructor_body).toString()}) parameters instead!`);return Kr.apply(this,ji)}),Vr=Object.create(or,{constructor:{value:mr}});mr.prototype=Vr;var ei=new aa(Ge,mr,Vr,Ot,cr,Q,he,Fe);ei.baseClass&&((cn=ei.baseClass).__derivedClasses??(cn.__derivedClasses=[]),ei.baseClass.__derivedClasses.push(ei));var ui=new ht(Ge,ei,!0,!1,!1),Ei=new ht(Ge+"*",ei,!1,!1,!1),jr=new ht(Ge+" const*",ei,!1,!0,!1);return fu[$]={pointerType:Ei,constPointerType:jr},Ft(St,mr),[ui,Ei,jr]})}var Ba=$=>{for(;$.length;){var ee=$.pop(),ae=$.pop();ae(ee)}};function Sl($){for(var ee=1;ee<$.length;++ee)if($[ee]!==null&&$[ee].destructorFunction===void 0)return!0;return!1}function zl($,ee,ae,O,j,Q){var ie=ee.length;ie<2&&sr("argTypes array size mismatch! Must at least get return value and 'this' types!");var he=ee[1]!==null&&ae!==null,Oe=Sl(ee),Fe=ee[0].name!=="void",Ge=ie-2,lt=new Array(Ge),Ot=[],St=[],jt=function(...cr){St.length=0;var or;Ot.length=he?2:1,Ot[0]=j,he&&(or=ee[1].toWireType(St,this),Ot[1]=or);for(var mr=0;mr<Ge;++mr)lt[mr]=ee[mr+2].toWireType(St,cr[mr]),Ot.push(lt[mr]);var Vr=O(...Ot);function ei(ui){if(Oe)Ba(St);else for(var Ei=he?1:2;Ei<ee.length;Ei++){var jr=Ei===1?or:lt[Ei-2];ee[Ei].destructorFunction!==null&&ee[Ei].destructorFunction(jr)}if(Fe)return ee[0].fromWireType(ui)}return ei(Vr)};return st($,jt)}var Hu=($,ee)=>{for(var ae=[],O=0;O<$;O++)ae.push(F[ee+O*4>>>2>>>0]);return ae},fd=$=>{$=$.trim();const ee=$.indexOf("(");return ee!==-1?$.substr(0,ee):$},Bs=function($,ee,ae,O,j,Q,ie,he,Oe){$>>>=0,ee>>>=0,O>>>=0,j>>>=0,Q>>>=0,ie>>>=0;var Fe=Hu(ae,O);ee=Dt(ee),ee=fd(ee),Q=pi(j,Q),wo([],[$],Ge=>{Ge=Ge[0];var lt=`${Ge.name}.${ee}`;function Ot(){Bi(`Cannot call ${lt} due to unbound types`,Fe)}ee.startsWith("@@")&&(ee=Symbol[ee.substring(2)]);var St=Ge.registeredClass.constructor;return St[ee]===void 0?(Ot.argCount=ae-1,St[ee]=Ot):(Fa(St,ee,lt),St[ee].overloadTable[ae-1]=Ot),wo([],Fe,jt=>{var cr=[jt[0],null].concat(jt.slice(1)),or=zl(lt,cr,null,Q,ie);if(St[ee].overloadTable===void 0?(or.argCount=ae-1,St[ee]=or):St[ee].overloadTable[ae-1]=or,Ge.registeredClass.__derivedClasses)for(const mr of Ge.registeredClass.__derivedClasses)mr.constructor.hasOwnProperty(ee)||(mr.constructor[ee]=or);return[]}),[]})},jg=function($,ee,ae,O,j,Q){$>>>=0,ae>>>=0,O>>>=0,j>>>=0,Q>>>=0;var ie=Hu(ee,ae);j=pi(O,j),wo([],[$],he=>{he=he[0];var Oe=`constructor ${he.name}`;if(he.registeredClass.constructor_body===void 0&&(he.registeredClass.constructor_body=[]),he.registeredClass.constructor_body[ee-1]!==void 0)throw new si(`Cannot register multiple constructors with identical number of parameters (${ee-1}) for class '${he.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return he.registeredClass.constructor_body[ee-1]=()=>{Bi(`Cannot construct ${he.name} due to unbound types`,ie)},wo([],ie,Fe=>(Fe.splice(1,0,null),he.registeredClass.constructor_body[ee-1]=zl(Oe,Fe,null,j,Q),[])),[]})},js=function($,ee,ae,O,j,Q,ie,he,Oe,Fe){$>>>=0,ee>>>=0,O>>>=0,j>>>=0,Q>>>=0,ie>>>=0;var Ge=Hu(ae,O);ee=Dt(ee),ee=fd(ee),Q=pi(j,Q),wo([],[$],lt=>{lt=lt[0];var Ot=`${lt.name}.${ee}`;ee.startsWith("@@")&&(ee=Symbol[ee.substring(2)]),he&&lt.registeredClass.pureVirtualFunctions.push(ee);function St(){Bi(`Cannot call ${Ot} due to unbound types`,Ge)}var jt=lt.registeredClass.instancePrototype,cr=jt[ee];return cr===void 0||cr.overloadTable===void 0&&cr.className!==lt.name&&cr.argCount===ae-2?(St.argCount=ae-2,St.className=lt.name,jt[ee]=St):(Fa(jt,ee,Ot),jt[ee].overloadTable[ae-2]=St),wo([],Ge,or=>{var mr=zl(Ot,or,lt,Q,ie);return jt[ee].overloadTable===void 0?(mr.argCount=ae-2,jt[ee]=mr):jt[ee].overloadTable[ae-2]=mr,[]}),[]})},qf=($,ee,ae)=>($ instanceof Object||sr(`${ae} with invalid "this": ${$}`),$ instanceof ee.registeredClass.constructor||sr(`${ae} incompatible with "this" of type ${$.constructor.name}`),$.$$.ptr||sr(`cannot call emscripten binding method ${ae} on deleted object`),Qi($.$$.ptr,$.$$.ptrType.registeredClass,ee.registeredClass)),hd=function($,ee,ae,O,j,Q,ie,he,Oe,Fe){$>>>=0,ee>>>=0,ae>>>=0,O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0,ee=Dt(ee),j=pi(O,j),wo([],[$],Ge=>{Ge=Ge[0];var lt=`${Ge.name}.${ee}`,Ot={get(){Bi(`Cannot access ${lt} due to unbound types`,[ae,ie])},enumerable:!0,configurable:!0};return Oe?Ot.set=()=>Bi(`Cannot access ${lt} due to unbound types`,[ae,ie]):Ot.set=St=>sr(lt+" is a read-only property"),Object.defineProperty(Ge.registeredClass.instancePrototype,ee,Ot),wo([],Oe?[ae,ie]:[ae],St=>{var jt=St[0],cr={get(){var mr=qf(this,Ge,lt+" getter");return jt.fromWireType(j(Q,mr))},enumerable:!0};if(Oe){Oe=pi(he,Oe);var or=St[1];cr.set=function(mr){var Vr=qf(this,Ge,lt+" setter"),ei=[];Oe(Fe,Vr,or.toWireType(ei,mr)),Ba(ei)}}return Object.defineProperty(Ge.registeredClass.instancePrototype,ee,cr),[]}),[]})};function is($){$>>>=0,$>9&&--hi[$+1]===0&&(hi[$]=void 0,zo.push($))}var Xf={name:"emscripten::val",fromWireType:$=>{var ee=Z.toValue($);return is($),ee},toWireType:($,ee)=>Z.toHandle(ee),argPackAdvance:ao,readValueFromPointer:He,destructorFunction:null};function Yd($){return $>>>=0,Lo($,Xf)}var ko=($,ee,ae)=>{switch(ee){case 1:return ae?function(O){return this.fromWireType(E[O>>>0])}:function(O){return this.fromWireType(A[O>>>0])};case 2:return ae?function(O){return this.fromWireType(R[O>>>1>>>0])}:function(O){return this.fromWireType(M[O>>>1>>>0])};case 4:return ae?function(O){return this.fromWireType(D[O>>>2>>>0])}:function(O){return this.fromWireType(F[O>>>2>>>0])};default:throw new TypeError(`invalid integer width (${ee}): ${$}`)}};function ac($,ee,ae,O){$>>>=0,ee>>>=0,ae>>>=0,ee=Dt(ee);function j(){}j.values={},Lo($,{name:ee,constructor:j,fromWireType:function(Q){return this.constructor.values[Q]},toWireType:(Q,ie)=>ie.value,argPackAdvance:ao,readValueFromPointer:ko(ee,ae,O),destructorFunction:null}),va(ee,j)}function Nh($,ee,ae){$>>>=0,ee>>>=0;var O=yl($,"enum");ee=Dt(ee);var j=O.constructor,Q=Object.create(O.constructor.prototype,{value:{value:ae},constructor:{value:st(`${O.name}_${ee}`,function(){})}});j.values[ae]=Q,j[ee]=Q}var pd=$=>{if($===null)return"null";var ee=typeof $;return ee==="object"||ee==="array"||ee==="function"?$.toString():""+$},Fh=($,ee)=>{switch(ee){case 4:return function(ae){return this.fromWireType(I[ae>>>2>>>0])};case 8:return function(ae){return this.fromWireType(V[ae>>>3>>>0])};default:throw new TypeError(`invalid float width (${ee}): ${$}`)}},Vg=function($,ee,ae){$>>>=0,ee>>>=0,ae>>>=0,ee=Dt(ee),Lo($,{name:ee,fromWireType:O=>O,toWireType:(O,j)=>j,argPackAdvance:ao,readValueFromPointer:Fh(ee,ae),destructorFunction:null})};function Hg($,ee,ae,O,j,Q,ie,he){$>>>=0,ae>>>=0,O>>>=0,j>>>=0,Q>>>=0;var Oe=Hu(ee,ae);$=Dt($),$=fd($),j=pi(O,j),va($,function(){Bi(`Cannot call ${$} due to unbound types`,Oe)},ee-1),wo([],Oe,Fe=>{var Ge=[Fe[0],null].concat(Fe.slice(1));return Ft($,zl($,Ge,null,j,Q),ee-1),[]})}var Kf=($,ee,ae)=>{switch(ee){case 1:return ae?O=>E[O>>>0]:O=>A[O>>>0];case 2:return ae?O=>R[O>>>1>>>0]:O=>M[O>>>1>>>0];case 4:return ae?O=>D[O>>>2>>>0]:O=>F[O>>>2>>>0];default:throw new TypeError(`invalid integer width (${ee}): ${$}`)}};function gd($,ee,ae,O,j){$>>>=0,ee>>>=0,ae>>>=0,ee=Dt(ee);var Q=Ge=>Ge;if(O===0){var ie=32-8*ae;Q=Ge=>Ge<<ie>>>ie}var he=ee.includes("unsigned"),Oe=(Ge,lt)=>{},Fe;he?Fe=function(Ge,lt){return Oe(lt,this.name),lt>>>0}:Fe=function(Ge,lt){return Oe(lt,this.name),lt},Lo($,{name:ee,fromWireType:Q,toWireType:Fe,argPackAdvance:ao,readValueFromPointer:Kf(ee,ae,O!==0),destructorFunction:null})}function Zf($,ee,ae){$>>>=0,ae>>>=0;var O=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],j=O[ee];function Q(ie){var he=F[ie>>>2>>>0],Oe=F[ie+4>>>2>>>0];return new j(E.buffer,Oe,he)}ae=Dt(ae),Lo($,{name:ae,fromWireType:Q,argPackAdvance:ao,readValueFromPointer:Q},{ignoreDuplicateRegistrations:!0})}var Di=($,ee,ae)=>Ar($,A,ee,ae);function Ip($,ee){$>>>=0,ee>>>=0,ee=Dt(ee),Lo($,{name:ee,fromWireType(ae){for(var O=F[ae>>>2>>>0],j=ae+4,Q,ie,he=j,ie=0;ie<=O;++ie){var Oe=j+ie;if(ie==O||A[Oe>>>0]==0){var Fe=Oe-he,Ge=fr(he,Fe);Q===void 0?Q=Ge:(Q+="\0",Q+=Ge),he=Oe+1}}return xi(ae),Q},toWireType(ae,O){O instanceof ArrayBuffer&&(O=new Uint8Array(O));var j,Q=typeof O=="string";Q||O instanceof Uint8Array||O instanceof Uint8ClampedArray||O instanceof Int8Array||sr("Cannot pass non-string to std::string"),Q?j=nr(O):j=O.length;var ie=yi(4+j+1),he=ie+4;if(F[ie>>>2>>>0]=j,Q)Di(O,he,j+1);else if(Q)for(var Oe=0;Oe<j;++Oe){var Fe=O.charCodeAt(Oe);Fe>255&&(xi(he),sr("String has UTF-16 code units that do not fit in 8 bits")),A[he+Oe>>>0]=Fe}else for(var Oe=0;Oe<j;++Oe)A[he+Oe>>>0]=O[Oe];return ae!==null&&ae.push(xi,ie),ie},argPackAdvance:ao,readValueFromPointer:He,destructorFunction(ae){xi(ae)}})}var qd=typeof TextDecoder<"u"?new TextDecoder("utf-16le"):void 0,Xd=($,ee)=>{for(var ae=$,O=ae>>1,j=O+ee/2;!(O>=j)&&M[O>>>0];)++O;if(ae=O<<1,ae-$>32&&qd)return qd.decode(A.subarray($>>>0,ae>>>0));for(var Q="",ie=0;!(ie>=ee/2);++ie){var he=R[$+ie*2>>>1>>>0];if(he==0)break;Q+=String.fromCharCode(he)}return Q},sc=($,ee,ae)=>{if(ae??(ae=2147483647),ae<2)return 0;ae-=2;for(var O=ee,j=ae<$.length*2?ae/2:$.length,Q=0;Q<j;++Q){var ie=$.charCodeAt(Q);R[ee>>>1>>>0]=ie,ee+=2}return R[ee>>>1>>>0]=0,ee-O},Kd=$=>$.length*2,Jf=($,ee)=>{for(var ae=0,O="";!(ae>=ee/4);){var j=D[$+ae*4>>>2>>>0];if(j==0)break;if(++ae,j>=65536){var Q=j-65536;O+=String.fromCharCode(55296|Q>>10,56320|Q&1023)}else O+=String.fromCharCode(j)}return O},Bh=($,ee,ae)=>{if(ee>>>=0,ae??(ae=2147483647),ae<4)return 0;for(var O=ee,j=O+ae-4,Q=0;Q<$.length;++Q){var ie=$.charCodeAt(Q);if(ie>=55296&&ie<=57343){var he=$.charCodeAt(++Q);ie=65536+((ie&1023)<<10)|he&1023}if(D[ee>>>2>>>0]=ie,ee+=4,ee+4>j)break}return D[ee>>>2>>>0]=0,ee-O},Dc=$=>{for(var ee=0,ae=0;ae<$.length;++ae){var O=$.charCodeAt(ae);O>=55296&&O<=57343&&++ae,ee+=4}return ee},Rc=function($,ee,ae){$>>>=0,ee>>>=0,ae>>>=0,ae=Dt(ae);var O,j,Q,ie;ee===2?(O=Xd,j=sc,ie=Kd,Q=he=>M[he>>>1>>>0]):ee===4&&(O=Jf,j=Bh,ie=Dc,Q=he=>F[he>>>2>>>0]),Lo($,{name:ae,fromWireType:he=>{for(var Oe=F[he>>>2>>>0],Fe,Ge=he+4,lt=0;lt<=Oe;++lt){var Ot=he+4+lt*ee;if(lt==Oe||Q(Ot)==0){var St=Ot-Ge,jt=O(Ge,St);Fe===void 0?Fe=jt:(Fe+="\0",Fe+=jt),Ge=Ot+ee}}return xi(he),Fe},toWireType:(he,Oe)=>{typeof Oe!="string"&&sr(`Cannot pass non-string to C++ string type ${ae}`);var Fe=ie(Oe),Ge=yi(4+Fe+ee);return F[Ge>>>2>>>0]=Fe/ee,j(Oe,Ge+4,Fe+ee),he!==null&&he.push(xi,Ge),Ge},argPackAdvance:ao,readValueFromPointer:He,destructorFunction(he){xi(he)}})},Np=function($,ee){$>>>=0,ee>>>=0,ee=Dt(ee),Lo($,{isVoid:!0,name:ee,argPackAdvance:0,fromWireType:()=>{},toWireType:(ae,O)=>{}})};function Mc($){if(ya.xhrs.has($)){var ee=ya.xhrs.get($);ya.xhrs.free($),ee.readyState>0&&ee.readyState<4&&ee.abort()}}var nl=()=>{throw 1/0},jh={},Zd=$=>{var ee=jh[$];return ee===void 0?Dt($):ee},Uu=[];function Vh($,ee,ae,O,j){return $>>>=0,ee>>>=0,ae>>>=0,O>>>=0,j>>>=0,$=Uu[$],ee=Z.toValue(ee),ae=Zd(ae),$(ee,ee[ae],O,j)}var Jd=$=>{var ee=Uu.length;return Uu.push($),ee},pu=($,ee)=>{for(var ae=new Array($),O=0;O<$;++O)ae[O]=yl(F[ee+O*4>>>2>>>0],"parameter "+O);return ae},io=Reflect.construct,gu=($,ee,ae)=>{var O=[],j=$.toWireType(O,ae);return O.length&&(F[ee>>>2>>>0]=Z.toHandle(O)),j},ns=function($,ee,ae){ee>>>=0;var O=pu($,ee),j=O.shift();$--;var Q=new Array($),ie=(Oe,Fe,Ge,lt)=>{for(var Ot=0,St=0;St<$;++St)Q[St]=O[St].readValueFromPointer(lt+Ot),Ot+=O[St].argPackAdvance;var jt=ae===1?io(Fe,Q):Fe.apply(Oe,Q);return gu(j,Ge,jt)},he=`methodCaller<(${O.map(Oe=>Oe.name).join(", ")}) => ${j.name}>`;return Jd(st(he,ie))};function os($){$>>>=0;var ee=Z.toValue($);Ba(ee),is($)}function Hh($,ee){$>>>=0,ee>>>=0,$=yl($,"_emval_take_value");var ae=$.readValueFromPointer(ee);return Z.toHandle(ae)}var Qf=$=>$%4===0&&($%100!==0||$%400===0),eh=[0,31,60,91,121,152,182,213,244,274,305,335],Uh=[0,31,59,90,120,151,181,212,243,273,304,334],zu=$=>{var ee=Qf($.getFullYear()),ae=ee?eh:Uh,O=ae[$.getMonth()]+$.getDate()-1;return O};function th($,ee,ae){var O=_t($,ee);ae>>>=0;var j=new Date(O*1e3);D[ae>>>2>>>0]=j.getSeconds(),D[ae+4>>>2>>>0]=j.getMinutes(),D[ae+8>>>2>>>0]=j.getHours(),D[ae+12>>>2>>>0]=j.getDate(),D[ae+16>>>2>>>0]=j.getMonth(),D[ae+20>>>2>>>0]=j.getFullYear()-1900,D[ae+24>>>2>>>0]=j.getDay();var Q=zu(j)|0;D[ae+28>>>2>>>0]=Q,D[ae+36>>>2>>>0]=-(j.getTimezoneOffset()*60);var ie=new Date(j.getFullYear(),0,1),he=new Date(j.getFullYear(),6,1).getTimezoneOffset(),Oe=ie.getTimezoneOffset(),Fe=(he!=Oe&&j.getTimezoneOffset()==Math.min(Oe,he))|0;D[ae+32>>>2>>>0]=Fe}var Ug=function($,ee,ae,O){$>>>=0,ee>>>=0,ae>>>=0,O>>>=0;var j=new Date().getFullYear(),Q=new Date(j,0,1),ie=new Date(j,6,1),he=Q.getTimezoneOffset(),Oe=ie.getTimezoneOffset(),Fe=Math.max(he,Oe);F[$>>>2>>>0]=Fe*60,D[ee>>>2>>>0]=+(he!=Oe);var Ge=St=>{var jt=St>=0?"-":"+",cr=Math.abs(St),or=String(Math.floor(cr/60)).padStart(2,"0"),mr=String(cr%60).padStart(2,"0");return`UTC${jt}${or}${mr}`},lt=Ge(he),Ot=Ge(Oe);Oe<he?(Di(lt,ae,17),Di(Ot,O,17)):(Di(lt,O,17),Di(Ot,ae,17))},Qd=()=>performance.now(),Fp=()=>Date.now(),Lc=$=>$>=0&&$<=3;function Ke($,ee,ae,O){if(O>>>=0,!Lc($))return 28;var j;$===0?j=Fp():j=Qd();var Q=Math.round(j*1e3*1e3);return it=[Q>>>0,(Qe=Q,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[O>>>2>>>0]=it[0],D[O+4>>>2>>>0]=it[1],0}var le=[],Se=($,ee)=>{le.length=0;for(var ae;ae=A[$++>>>0];){var O=ae!=105;O&=ae!=112,ee+=O&&ee%8?4:0,le.push(ae==112?F[ee>>>2>>>0]:ae==105?D[ee>>>2>>>0]:V[ee>>>3>>>0]),ee+=O?8:4}return le},be=($,ee,ae)=>{var O=Se(ee,ae);return xt[$](...O)};function xe($,ee,ae){return $>>>=0,ee>>>=0,ae>>>=0,be($,ee,ae)}var Le=($,ee)=>{if(Nt.timingMode=$,Nt.timingValue=ee,!Nt.func)return 1;if(Nt.running||(Nt.running=!0),$==0)Nt.scheduler=function(){var ie=Math.max(0,Nt.tickStartTime+ee-Qd())|0;setTimeout(Nt.runner,ie)},Nt.method="timeout";else if($==1)Nt.scheduler=function(){Nt.requestAnimationFrame(Nt.runner)},Nt.method="rAF";else if($==2){if(typeof Nt.setImmediate>"u")if(typeof setImmediate>"u"){var ae=[],O="setimmediate",j=Q=>{(Q.data===O||Q.data.target===O)&&(Q.stopPropagation(),ae.shift()())};addEventListener("message",j,!0),Nt.setImmediate=Q=>{ae.push(Q),postMessage(O,"*")}}else Nt.setImmediate=setImmediate;Nt.scheduler=function(){Nt.setImmediate(Nt.runner)},Nt.method="immediate"}return 0},je=0,ct=()=>rt||je>0,ze=$=>{var ee;x=$,ct()||((ee=s.onExit)==null||ee.call(s,$),P=!0),p($,new $t($))},at=($,ee)=>{x=$,ze($)},tt=at,pt=$=>{if($ instanceof $t||$=="unwind")return x;p(1,$)},Ut=()=>{if(!ct())try{tt(x)}catch($){pt($)}},vr=($,ee,ae,O,j)=>{Nt.func=$,Nt.arg=O;var Q=Nt.currentlyRunningMainloop;function ie(){return Q<Nt.currentlyRunningMainloop?(Ut(),!1):!0}if(Nt.running=!1,Nt.runner=function(){if(!P){if(Nt.queue.length>0){var Oe=Nt.queue.shift();if(Oe.func(Oe.arg),Nt.remainingBlockers){var Fe=Nt.remainingBlockers,Ge=Fe%1==0?Fe-1:Math.floor(Fe);Oe.counted?Nt.remainingBlockers=Ge:(Ge=Ge+.5,Nt.remainingBlockers=(8*Fe+Ge)/9)}if(Nt.updateStatus(),!ie())return;setTimeout(Nt.runner,0);return}if(ie()){if(Nt.currentFrameNumber=Nt.currentFrameNumber+1|0,Nt.timingMode==1&&Nt.timingValue>1&&Nt.currentFrameNumber%Nt.timingValue!=0){Nt.scheduler();return}else Nt.timingMode==0&&(Nt.tickStartTime=Qd());Nt.runIter($),ie()&&Nt.scheduler()}}},j||(ee&&ee>0?Le(0,1e3/ee):Le(1,1),Nt.scheduler()),ae)throw"unwind"},Ir=$=>{if(!P)try{$(),Ut()}catch(ee){pt(ee)}},Nt={running:!1,scheduler:null,method:"",currentlyRunningMainloop:0,func:null,arg:0,timingMode:0,timingValue:0,currentFrameNumber:0,queue:[],preMainLoop:[],postMainLoop:[],pause(){Nt.scheduler=null,Nt.currentlyRunningMainloop++},resume(){Nt.currentlyRunningMainloop++;var $=Nt.timingMode,ee=Nt.timingValue,ae=Nt.func;Nt.func=null,vr(ae,0,!1,Nt.arg,!0),Le($,ee),Nt.scheduler()},updateStatus(){if(s.setStatus){var $=s.statusMessage||"Please wait...",ee=Nt.remainingBlockers??0,ae=Nt.expectedBlockers??0;ee?ee<ae?s.setStatus("{message} ({expected - remaining}/{expected})"):s.setStatus($):s.setStatus("")}},init(){s.preMainLoop&&Nt.preMainLoop.push(s.preMainLoop),s.postMainLoop&&Nt.postMainLoop.push(s.postMainLoop)},runIter($){if(!P){for(var ee of Nt.preMainLoop)if(ee()===!1)return;Ir($);for(var ae of Nt.postMainLoop)ae()}},nextRAF:0,fakeRequestAnimationFrame($){var ee=Date.now();if(Nt.nextRAF===0)Nt.nextRAF=ee+1e3/60;else for(;ee+2>=Nt.nextRAF;)Nt.nextRAF+=1e3/60;var ae=Math.max(Nt.nextRAF-ee,0);setTimeout($,ae)},requestAnimationFrame($){if(typeof requestAnimationFrame=="function"){requestAnimationFrame($);return}var ee=Nt.fakeRequestAnimationFrame;ee($)}},hr=()=>{Nt.pause(),Nt.func=null},Ao=()=>{rt=!1,je=0},ho=$=>{Ao(),tt($)},$l=()=>!0,rh=()=>4294901760,kc=$=>{var ee=C.buffer,ae=($-ee.byteLength+65535)/65536|0;try{return C.grow(ae),z(),1}catch{}};function ef($){$>>>=0;var ee=A.length,ae=rh();if($>ae)return!1;for(var O=1;O<=4;O*=2){var j=ee*(1+.2/O);j=Math.min(j,$+100663296);var Q=Math.min(ae,Yr(Math.max($,j),65536)),ie=kc(Q);if(ie)return!0}return!1}function tf($,ee,ae){$>>>=0;var O=Kt($);vr(O,ee,ae)}class Mn{constructor(){Go(this,"allocated",[void 0]);Go(this,"freelist",[])}get(ee){return this.allocated[ee]}has(ee){return this.allocated[ee]!==void 0}allocate(ee){var ae=this.freelist.pop()||this.allocated.length;return this.allocated[ae]=ee,ae}free(ee){this.allocated[ee]=void 0,this.freelist.push(ee)}}var ya={openDatabase($,ee,ae,O){try{var j=indexedDB.open($,ee)}catch(Q){return O(Q)}j.onupgradeneeded=Q=>{var ie=Q.target.result;ie.objectStoreNames.contains("FILES")&&ie.deleteObjectStore("FILES"),ie.createObjectStore("FILES")},j.onsuccess=Q=>ae(Q.target.result),j.onerror=O},init(){ya.xhrs=new Mn;var $=ae=>{ya.dbInstance=ae,Pe()},ee=()=>{ya.dbInstance=!1,Pe()};Ae(),ya.openDatabase("emscripten_filesystem",1,$,ee)}};function Po($,ee,ae,O,j){var Q=F[$+8>>>2>>>0];if(!Q){ae($,0,"no url specified!");return}var ie=fr(Q),he=$+108,Oe=fr(he+0);Oe||(Oe="GET");var Fe=F[he+56>>>2>>>0],Ge=F[he+68>>>2>>>0],lt=F[he+72>>>2>>>0],Ot=F[he+76>>>2>>>0],St=F[he+80>>>2>>>0],jt=F[he+84>>>2>>>0],cr=F[he+88>>>2>>>0],or=F[he+52>>>2>>>0],mr=!!(or&1),Vr=!!(or&2),ei=!!(or&64),ui=Ge?fr(Ge):void 0,Ei=lt?fr(lt):void 0,jr=new XMLHttpRequest;if(jr.withCredentials=!!A[he+60>>>0],jr.open(Oe,ie,!ei,ui,Ei),ei||(jr.timeout=Fe),jr.url_=ie,jr.responseType="arraybuffer",St){var cn=fr(St);jr.overrideMimeType(cn)}if(Ot)for(;;){var ji=F[Ot>>>2>>>0];if(!ji)break;var Kr=F[Ot+4>>>2>>>0];if(!Kr)break;Ot+=8;var Ai=fr(ji),qa=fr(Kr);jr.setRequestHeader(Ai,qa)}var sa=ya.xhrs.allocate(jr);F[$>>>2>>>0]=sa;var No=jt&&cr?A.slice(jt,jt+cr):null;function al(){var pn=0,sl=0;jr.response&&mr&&F[$+12>>>2>>>0]===0&&(sl=jr.response.byteLength),sl>0&&(pn=yi(sl),A.set(new Uint8Array(jr.response),pn>>>0)),F[$+12>>>2>>>0]=pn,po($+16,sl),po($+24,0);var Hs=jr.response?jr.response.byteLength:0;Hs&&po($+32,Hs),R[$+40>>>1>>>0]=jr.readyState,R[$+42>>>1>>>0]=jr.status,jr.statusText&&Di(jr.statusText,$+44,64)}jr.onload=pn=>{ya.xhrs.has(sa)&&(al(),jr.status>=200&&jr.status<300?ee==null||ee($,jr,pn):ae==null||ae($,jr,pn))},jr.onerror=pn=>{ya.xhrs.has(sa)&&(al(),ae==null||ae($,jr,pn))},jr.ontimeout=pn=>{ya.xhrs.has(sa)&&(ae==null||ae($,jr,pn))},jr.onprogress=pn=>{if(ya.xhrs.has(sa)){var sl=mr&&Vr&&jr.response?jr.response.byteLength:0,Hs=0;sl>0&&mr&&Vr&&(Hs=yi(sl),A.set(new Uint8Array(jr.response),Hs>>>0)),F[$+12>>>2>>>0]=Hs,po($+16,sl),po($+24,pn.loaded-sl),po($+32,pn.total),R[$+40>>>1>>>0]=jr.readyState,jr.readyState>=3&&jr.status===0&&pn.loaded>0&&(jr.status=200),R[$+42>>>1>>>0]=jr.status,jr.statusText&&Di(jr.statusText,$+44,64),O==null||O($,jr,pn),Hs&&xi(Hs)}},jr.onreadystatechange=pn=>{ya.xhrs.has(sa)&&(R[$+40>>>1>>>0]=jr.readyState,jr.readyState>=2&&(R[$+42>>>1>>>0]=jr.status),j==null||j($,jr,pn))};try{jr.send(No)}catch(pn){ae==null||ae($,jr,pn)}}var po=($,ee)=>{F[$>>>2>>>0]=ee;var ae=F[$>>>2>>>0];F[$+4>>>2>>>0]=(ee-ae)/4294967296};function so($,ee,ae,O,j){if(!$){j(ee,0,"IndexedDB not available!");return}var Q=ee+108,ie=F[Q+64>>>2>>>0];ie||(ie=F[ee+8>>>2>>>0]);var he=fr(ie);try{var Oe=$.transaction(["FILES"],"readwrite"),Fe=Oe.objectStore("FILES"),Ge=Fe.put(ae,he);Ge.onsuccess=lt=>{R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=200,Di("OK",ee+44,64),O(ee,0,he)},Ge.onerror=lt=>{R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=413,Di("Payload Too Large",ee+44,64),j(ee,0,lt)}}catch(lt){j(ee,0,lt)}}function _l($,ee,ae,O){if(!$){O(ee,0,"IndexedDB not available!");return}var j=ee+108,Q=F[j+64>>>2>>>0];Q||(Q=F[ee+8>>>2>>>0]);var ie=fr(Q);try{var he=$.transaction(["FILES"],"readonly"),Oe=he.objectStore("FILES"),Fe=Oe.get(ie);Fe.onsuccess=Ge=>{if(Ge.target.result){var lt=Ge.target.result,Ot=lt.byteLength||lt.length,St=yi(Ot);A.set(new Uint8Array(lt),St>>>0),F[ee+12>>>2>>>0]=St,po(ee+16,Ot),po(ee+24,0),po(ee+32,Ot),R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=200,Di("OK",ee+44,64),ae(ee,0,lt)}else R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=404,Di("Not Found",ee+44,64),O(ee,0,"no data")},Fe.onerror=Ge=>{R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=404,Di("Not Found",ee+44,64),O(ee,0,Ge)}}catch(Ge){O(ee,0,Ge)}}function as($,ee,ae,O){if(!$){O(ee,0,"IndexedDB not available!");return}var j=ee+108,Q=F[j+64>>>2>>>0];Q||(Q=F[ee+8>>>2>>>0]);var ie=fr(Q);try{var he=$.transaction(["FILES"],"readwrite"),Oe=he.objectStore("FILES"),Fe=Oe.delete(ie);Fe.onsuccess=Ge=>{var lt=Ge.target.result;F[ee+12>>>2>>>0]=0,po(ee+16,0),po(ee+24,0),po(ee+32,0),R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=200,Di("OK",ee+44,64),ae(ee,0,lt)},Fe.onerror=Ge=>{R[ee+40>>>1>>>0]=4,R[ee+42>>>1>>>0]=404,Di("Not Found",ee+44,64),O(ee,0,Ge)}}catch(Ge){O(ee,0,Ge)}}function rf($,ee,ae,O,j){$>>>=0;var Q=$+108,ie=F[Q+36>>>2>>>0],he=F[Q+40>>>2>>>0],Oe=F[Q+44>>>2>>>0],Fe=F[Q+48>>>2>>>0],Ge=F[Q+52>>>2>>>0],lt=!!(Ge&64);function Ot(Ai){lt?Ai():Ir(Ai)}var St=(Ai,qa,sa)=>{Ot(()=>{ie?Kt(ie)(Ai):ee==null||ee(Ai)})},jt=(Ai,qa,sa)=>{Ot(()=>{Oe?Kt(Oe)(Ai):O==null||O(Ai)})},cr=(Ai,qa,sa)=>{Ot(()=>{he?Kt(he)(Ai):ae==null||ae(Ai)})},or=(Ai,qa,sa)=>{Ot(()=>{Fe?Kt(Fe)(Ai):j==null||j(Ai)})},mr=(Ai,qa,sa)=>{Po(Ai,St,cr,jt,or)},Vr=(Ai,qa,sa)=>{var No=(pn,sl,Hs)=>{Ot(()=>{ie?Kt(ie)(pn):ee==null||ee(pn)})},al=(pn,sl,Hs)=>{Ot(()=>{ie?Kt(ie)(pn):ee==null||ee(pn)})};so(ya.dbInstance,Ai,qa.response,No,al)},ei=(Ai,qa,sa)=>{Po(Ai,Vr,cr,jt,or)},ui=fr(Q+0),Ei=!!(Ge&16),jr=!!(Ge&4),cn=!!(Ge&32);if(ui==="EM_IDB_STORE"){var ji=F[Q+84>>>2>>>0],Kr=F[Q+88>>>2>>>0];so(ya.dbInstance,$,A.slice(ji,ji+Kr),St,cr)}else if(ui==="EM_IDB_DELETE")as(ya.dbInstance,$,St,cr);else if(!Ei)_l(ya.dbInstance,$,St,cn?cr:jr?ei:mr);else if(!cn)Po($,jr?Vr:St,cr,jt,or);else return 0;return $}var Or,nf=$=>{var ee=$.getExtension("ANGLE_instanced_arrays");if(ee)return $.vertexAttribDivisor=(ae,O)=>ee.vertexAttribDivisorANGLE(ae,O),$.drawArraysInstanced=(ae,O,j,Q)=>ee.drawArraysInstancedANGLE(ae,O,j,Q),$.drawElementsInstanced=(ae,O,j,Q,ie)=>ee.drawElementsInstancedANGLE(ae,O,j,Q,ie),1},Bp=$=>{var ee=$.getExtension("OES_vertex_array_object");if(ee)return $.createVertexArray=()=>ee.createVertexArrayOES(),$.deleteVertexArray=ae=>ee.deleteVertexArrayOES(ae),$.bindVertexArray=ae=>ee.bindVertexArrayOES(ae),$.isVertexArray=ae=>ee.isVertexArrayOES(ae),1},Rr=$=>{var ee=$.getExtension("WEBGL_draw_buffers");if(ee)return $.drawBuffers=(ae,O)=>ee.drawBuffersWEBGL(ae,O),1},zg=$=>!!($.dibvbi=$.getExtension("WEBGL_draw_instanced_base_vertex_base_instance")),zh=$=>!!($.mdibvbi=$.getExtension("WEBGL_multi_draw_instanced_base_vertex_base_instance")),Ic=$=>!!($.extPolygonOffsetClamp=$.getExtension("EXT_polygon_offset_clamp")),qv=$=>!!($.extClipControl=$.getExtension("EXT_clip_control")),bs=$=>!!($.webglPolygonMode=$.getExtension("WEBGL_polygon_mode")),Nc=$=>!!($.multiDrawWebgl=$.getExtension("WEBGL_multi_draw")),Wl=$=>{var ee=["ANGLE_instanced_arrays","EXT_blend_minmax","EXT_disjoint_timer_query","EXT_frag_depth","EXT_shader_texture_lod","EXT_sRGB","OES_element_index_uint","OES_fbo_render_mipmap","OES_standard_derivatives","OES_texture_float","OES_texture_half_float","OES_texture_half_float_linear","OES_vertex_array_object","WEBGL_color_buffer_float","WEBGL_depth_texture","WEBGL_draw_buffers","EXT_color_buffer_float","EXT_conservative_depth","EXT_disjoint_timer_query_webgl2","EXT_texture_norm16","NV_shader_noperspective_interpolation","WEBGL_clip_cull_distance","EXT_clip_control","EXT_color_buffer_half_float","EXT_depth_clamp","EXT_float_blend","EXT_polygon_offset_clamp","EXT_texture_compression_bptc","EXT_texture_compression_rgtc","EXT_texture_filter_anisotropic","KHR_parallel_shader_compile","OES_texture_float_linear","WEBGL_blend_func_extended","WEBGL_compressed_texture_astc","WEBGL_compressed_texture_etc","WEBGL_compressed_texture_etc1","WEBGL_compressed_texture_s3tc","WEBGL_compressed_texture_s3tc_srgb","WEBGL_debug_renderer_info","WEBGL_debug_shaders","WEBGL_lose_context","WEBGL_multi_draw","WEBGL_polygon_mode"];return($.getSupportedExtensions()||[]).filter(ae=>ee.includes(ae))},Tr={counter:1,buffers:[],programs:[],framebuffers:[],renderbuffers:[],textures:[],shaders:[],vaos:[],contexts:[],offscreenCanvases:{},queries:[],samplers:[],transformFeedbacks:[],syncs:[],stringCache:{},stringiCache:{},unpackAlignment:4,unpackRowLength:0,recordError:$=>{Tr.lastError||(Tr.lastError=$)},getNewId:$=>{for(var ee=Tr.counter++,ae=$.length;ae<ee;ae++)$[ae]=null;return ee},genObject:($,ee,ae,O)=>{for(var j=0;j<$;j++){var Q=Or[ae](),ie=Q&&Tr.getNewId(O);Q?(Q.name=ie,O[ie]=Q):Tr.recordError(1282),D[ee+j*4>>>2>>>0]=ie}},getSource:($,ee,ae,O)=>{for(var j="",Q=0;Q<ee;++Q){var ie=O?F[O+Q*4>>>2>>>0]:void 0;j+=fr(F[ae+Q*4>>>2>>>0],ie)}return j},createContext:($,ee)=>{var ae=ee.majorVersion>1?$.getContext("webgl2",ee):$.getContext("webgl",ee);if(!ae)return 0;var O=Tr.registerContext(ae,ee);return O},registerContext:($,ee)=>{var ae=Tr.getNewId(Tr.contexts),O={handle:ae,attributes:ee,version:ee.majorVersion,GLctx:$};return $.canvas&&($.canvas.GLctxObject=O),Tr.contexts[ae]=O,(typeof ee.enableExtensionsByDefault>"u"||ee.enableExtensionsByDefault)&&Tr.initExtensions(O),ae},makeContextCurrent:$=>{var ee;return Tr.currentContext=Tr.contexts[$],s.ctx=Or=(ee=Tr.currentContext)==null?void 0:ee.GLctx,!($&&!Or)},getContext:$=>Tr.contexts[$],deleteContext:$=>{Tr.currentContext===Tr.contexts[$]&&(Tr.currentContext=null),typeof Ln=="object"&&Ln.removeAllHandlersOnTarget(Tr.contexts[$].GLctx.canvas),Tr.contexts[$]&&Tr.contexts[$].GLctx.canvas&&(Tr.contexts[$].GLctx.canvas.GLctxObject=void 0),Tr.contexts[$]=null},initExtensions:$=>{if($||($=Tr.currentContext),!$.initExtensionsDone){$.initExtensionsDone=!0;var ee=$.GLctx;Nc(ee),Ic(ee),qv(ee),bs(ee),nf(ee),Bp(ee),Rr(ee),zg(ee),zh(ee),$.version>=2&&(ee.disjointTimerQueryExt=ee.getExtension("EXT_disjoint_timer_query_webgl2")),($.version<2||!ee.disjointTimerQueryExt)&&(ee.disjointTimerQueryExt=ee.getExtension("EXT_disjoint_timer_query")),Wl(ee).forEach(ae=>{!ae.includes("lose_context")&&!ae.includes("debug")&&ee.getExtension(ae)})}}},Ln={memcpy($,ee,ae){E.set(E.subarray(ee>>>0,ee+ae>>>0),$>>>0)},removeAllEventListeners(){for(;Ln.eventHandlers.length;)Ln._removeHandler(Ln.eventHandlers.length-1);Ln.deferredCalls=[]},inEventHandler:0,deferredCalls:[],deferCall($,ee,ae){function O(Q,ie){if(Q.length!=ie.length)return!1;for(var he in Q)if(Q[he]!=ie[he])return!1;return!0}for(var j of Ln.deferredCalls)if(j.targetFunction==$&&O(j.argsList,ae))return;Ln.deferredCalls.push({targetFunction:$,precedence:ee,argsList:ae}),Ln.deferredCalls.sort((Q,ie)=>Q.precedence<ie.precedence)},removeDeferredCalls($){Ln.deferredCalls=Ln.deferredCalls.filter(ee=>ee.targetFunction!=$)},canPerformEventHandlerRequests(){return navigator.userActivation?navigator.userActivation.isActive:Ln.inEventHandler&&Ln.currentEventHandler.allowsDeferredCalls},runDeferredCalls(){if(Ln.canPerformEventHandlerRequests()){var $=Ln.deferredCalls;Ln.deferredCalls=[];for(var ee of $)ee.targetFunction(...ee.argsList)}},eventHandlers:[],removeAllHandlersOnTarget:($,ee)=>{for(var ae=0;ae<Ln.eventHandlers.length;++ae)Ln.eventHandlers[ae].target==$&&(!ee||ee==Ln.eventHandlers[ae].eventTypeString)&&Ln._removeHandler(ae--)},_removeHandler($){var ee=Ln.eventHandlers[$];ee.target.removeEventListener(ee.eventTypeString,ee.eventListenerFunc,ee.useCapture),Ln.eventHandlers.splice($,1)},registerOrRemoveHandler($){if(!$.target)return-4;if($.callbackfunc)$.eventListenerFunc=function(ae){++Ln.inEventHandler,Ln.currentEventHandler=$,Ln.runDeferredCalls(),$.handlerFunc(ae),Ln.runDeferredCalls(),--Ln.inEventHandler},$.target.addEventListener($.eventTypeString,$.eventListenerFunc,$.useCapture),Ln.eventHandlers.push($);else for(var ee=0;ee<Ln.eventHandlers.length;++ee)Ln.eventHandlers[ee].target==$.target&&Ln.eventHandlers[ee].eventTypeString==$.eventTypeString&&Ln._removeHandler(ee--);return 0},getNodeNameForTarget($){return $?$==window?"#window":$==screen?"#screen":($==null?void 0:$.nodeName)||"":""},fullscreenEnabled(){return document.fullscreenEnabled||document.webkitFullscreenEnabled}},vd=["default","low-power","high-performance"],_r=$=>$>2?fr($):$,_n=[0,document,window],$h=$=>{$=_r($);var ee=_n[$]||document.querySelector($);return ee},Xv=$h;function Pl($,ee){$>>>=0,ee>>>=0;var ae=ee>>>2,O=D[ae+2>>>0],j={alpha:!!E[ee+0>>>0],depth:!!E[ee+1>>>0],stencil:!!E[ee+2>>>0],antialias:!!E[ee+3>>>0],premultipliedAlpha:!!E[ee+4>>>0],preserveDrawingBuffer:!!E[ee+5>>>0],powerPreference:vd[O],failIfMajorPerformanceCaveat:!!E[ee+12>>>0],majorVersion:D[ae+4>>>0],minorVersion:D[ae+5>>>0],enableExtensionsByDefault:E[ee+24>>>0],explicitSwapControl:E[ee+25>>>0],proxyContextToMainThread:D[ae+7>>>0],renderViaOffscreenBackBuffer:E[ee+32>>>0]},Q=Xv($);if(!Q||j.explicitSwapControl)return 0;var ie=Tr.createContext(Q,j);return ie}var ih=Pl;function nh(){return Tr.currentContext?Tr.currentContext.handle:0}var ma=nh;function ja($){$>>>=0;var ee=Tr.makeContextCurrent($);return ee?0:-5}var Cl={},vu=()=>h||"./this.program",Gl=()=>{if(!Gl.strings){var $=(typeof navigator=="object"&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",ee={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:$,_:vu()};for(var ae in Cl)Cl[ae]===void 0?delete ee[ae]:ee[ae]=Cl[ae];var O=[];for(var ae in ee)O.push(`${ae}=${ee[ae]}`);Gl.strings=O}return Gl.strings},yu=($,ee)=>{for(var ae=0;ae<$.length;++ae)E[ee++>>>0]=$.charCodeAt(ae);E[ee>>>0]=0},mu=function($,ee){$>>>=0,ee>>>=0;var ae=0;return Gl().forEach((O,j)=>{var Q=ee+ae;F[$+j*4>>>2>>>0]=Q,yu(O,Q),ae+=O.length+1}),0},Ss=function($,ee){$>>>=0,ee>>>=0;var ae=Gl();F[$>>>2>>>0]=ae.length;var O=0;return ae.forEach(j=>O+=j.length+1),F[ee>>>2>>>0]=O,0};function jp($){try{var ee=Yt.getStreamFromFD($);return ce.close(ee),0}catch(ae){if(typeof ce>"u"||ae.name!=="ErrnoError")throw ae;return ae.errno}}var yd=($,ee,ae,O)=>{for(var j=0,Q=0;Q<ae;Q++){var ie=F[ee>>>2>>>0],he=F[ee+4>>>2>>>0];ee+=8;var Oe=ce.read($,E,ie,he,O);if(Oe<0)return-1;if(j+=Oe,Oe<he)break}return j};function of($,ee,ae,O){ee>>>=0,ae>>>=0,O>>>=0;try{var j=Yt.getStreamFromFD($),Q=yd(j,ee,ae);return F[O>>>2>>>0]=Q,0}catch(ie){if(typeof ce>"u"||ie.name!=="ErrnoError")throw ie;return ie.errno}}function oh($,ee,ae,O,j){var Q=_t(ee,ae);j>>>=0;try{if(isNaN(Q))return 61;var ie=Yt.getStreamFromFD($);return ce.llseek(ie,Q,O),it=[ie.position>>>0,(Qe=ie.position,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[j>>>2>>>0]=it[0],D[j+4>>>2>>>0]=it[1],ie.getdents&&Q===0&&O===0&&(ie.getdents=null),0}catch(he){if(typeof ce>"u"||he.name!=="ErrnoError")throw he;return he.errno}}var Va=($,ee,ae,O)=>{for(var j=0,Q=0;Q<ae;Q++){var ie=F[ee>>>2>>>0],he=F[ee+4>>>2>>>0];ee+=8;var Oe=ce.write($,E,ie,he,O);if(Oe<0)return-1;if(j+=Oe,Oe<he)break}return j};function lo($,ee,ae,O){ee>>>=0,ae>>>=0,O>>>=0;try{var j=Yt.getStreamFromFD($),Q=Va(j,ee,ae);return F[O>>>2>>>0]=Q,0}catch(ie){if(typeof ce>"u"||ie.name!=="ErrnoError")throw ie;return ie.errno}}var kn=$=>Or.activeTexture($),md=($,ee)=>{Or.attachShader(Tr.programs[$],Tr.shaders[ee])};function bu($,ee,ae){ae>>>=0,Or.bindAttribLocation(Tr.programs[$],ee,fr(ae))}var $g=($,ee)=>{$==35051?Or.currentPixelPackBufferBinding=ee:$==35052&&(Or.currentPixelUnpackBufferBinding=ee),Or.bindBuffer($,Tr.buffers[ee])},bd=($,ee,ae)=>{Or.bindBufferBase($,ee,Tr.buffers[ae])},Wh=($,ee)=>{Or.bindFramebuffer($,Tr.framebuffers[ee])},ah=($,ee)=>{Or.bindTexture($,Tr.textures[ee])},af=($,ee,ae,O)=>Or.blendColor($,ee,ae,O),nt=$=>Or.blendEquation($),Sd=($,ee,ae,O)=>Or.blendFuncSeparate($,ee,ae,O);function _d($,ee,ae,O){ee>>>=0,ae>>>=0,Or.bufferData($,ae?A.subarray(ae>>>0,ae+ee>>>0):ee,O)}function Tl($,ee,ae,O){ee>>>=0,ae>>>=0,O>>>=0,Or.bufferSubData($,ee,A.subarray(O>>>0,O+ae>>>0))}var nn=$=>Or.checkFramebufferStatus($),Fc=$=>Or.clear($),Pd=($,ee,ae,O)=>Or.clearColor($,ee,ae,O),Bc=($,ee,ae,O)=>{Or.colorMask(!!$,!!ee,!!ae,!!O)},jc=$=>{Or.compileShader(Tr.shaders[$])};function Wg($,ee,ae,O,j,Q,ie,he){if(he>>>=0,Tr.currentContext.version>=2&&(Or.currentPixelUnpackBufferBinding||!ie)){Or.compressedTexImage2D($,ee,ae,O,j,Q,ie,he);return}Or.compressedTexImage2D($,ee,ae,O,j,Q,A.subarray(he>>>0,he+ie>>>0))}var sh=()=>{var $=Tr.getNewId(Tr.programs),ee=Or.createProgram();return ee.name=$,ee.maxUniformLength=ee.maxAttributeLength=ee.maxUniformBlockNameLength=0,ee.uniformIdCounter=1,Tr.programs[$]=ee,$},Vp=$=>{var ee=Tr.getNewId(Tr.shaders);return Tr.shaders[ee]=Or.createShader($),ee},sf=$=>Or.cullFace($);function _s($,ee){ee>>>=0;for(var ae=0;ae<$;ae++){var O=D[ee+ae*4>>>2>>>0],j=Tr.buffers[O];j&&(Or.deleteBuffer(j),j.name=0,Tr.buffers[O]=null,O==Or.currentPixelPackBufferBinding&&(Or.currentPixelPackBufferBinding=0),O==Or.currentPixelUnpackBufferBinding&&(Or.currentPixelUnpackBufferBinding=0))}}function Su($,ee){ee>>>=0;for(var ae=0;ae<$;++ae){var O=D[ee+ae*4>>>2>>>0],j=Tr.framebuffers[O];j&&(Or.deleteFramebuffer(j),j.name=0,Tr.framebuffers[O]=null)}}var Kv=$=>{if($){var ee=Tr.programs[$];if(!ee){Tr.recordError(1281);return}Or.deleteProgram(ee),ee.name=0,Tr.programs[$]=null}};function Fm($,ee){ee>>>=0;for(var ae=0;ae<$;ae++){var O=D[ee+ae*4>>>2>>>0],j=Tr.renderbuffers[O];j&&(Or.deleteRenderbuffer(j),j.name=0,Tr.renderbuffers[O]=null)}}var Bm=$=>{if($){var ee=Tr.shaders[$];if(!ee){Tr.recordError(1281);return}Or.deleteShader(ee),Tr.shaders[$]=null}};function jm($,ee){ee>>>=0;for(var ae=0;ae<$;ae++){var O=D[ee+ae*4>>>2>>>0],j=Tr.textures[O];j&&(Or.deleteTexture(j),j.name=0,Tr.textures[O]=null)}}var Ha=$=>Or.depthFunc($),$u=$=>{Or.depthMask(!!$)},Gh=($,ee)=>{Or.detachShader(Tr.programs[$],Tr.shaders[ee])},Yh=$=>Or.disable($),Gg=$=>{Or.disableVertexAttribArray($)},lh=($,ee,ae)=>{Or.drawArrays($,ee,ae)};function uh($,ee,ae,O){O>>>=0,Or.drawElements($,ee,ae,O)}function lf($,ee,ae,O,j){O>>>=0,Or.drawElementsInstanced($,ee,ae,O,j)}var Zv=$=>Or.enable($),Vm=$=>{Or.enableVertexAttribArray($)},_u=($,ee,ae,O,j)=>{Or.framebufferTexture2D($,ee,ae,Tr.textures[O],j)},uf=$=>Or.frontFace($);function Yg($,ee){ee>>>=0,Tr.genObject($,ee,"createBuffer",Tr.buffers)}function Hp($,ee){ee>>>=0,Tr.genObject($,ee,"createFramebuffer",Tr.framebuffers)}function Jv($,ee){ee>>>=0,Tr.genObject($,ee,"createTexture",Tr.textures)}var ch=$=>Or.generateMipmap($),Up=($,ee,ae,O,j,Q,ie,he)=>{ee=Tr.programs[ee];var Oe=Or[$](ee,ae);if(Oe){var Fe=he&&Di(Oe.name,he,O);j&&(D[j>>>2>>>0]=Fe),Q&&(D[Q>>>2>>>0]=Oe.size),ie&&(D[ie>>>2>>>0]=Oe.type)}};function qh($,ee,ae,O,j,Q,ie){return O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,Up("getActiveUniform",$,ee,ae,O,j,Q,ie)}var Xh=()=>{var $=Wl(Or);return $=$.concat($.map(ee=>"GL_"+ee)),$},Qv=($,ee,ae)=>{if(!ee){Tr.recordError(1281);return}var O=void 0;switch($){case 36346:O=1;break;case 36344:return;case 34814:case 36345:O=0;break;case 34466:var j=Or.getParameter(34467);O=j?j.length:0;break;case 33309:if(Tr.currentContext.version<2){Tr.recordError(1282);return}O=Xh().length;break;case 33307:case 33308:if(Tr.currentContext.version<2){Tr.recordError(1280);return}O=$==33307?3:0;break}if(O===void 0){var Q=Or.getParameter($);switch(typeof Q){case"number":O=Q;break;case"boolean":O=Q?1:0;break;case"string":Tr.recordError(1280);return;case"object":if(Q===null)switch($){case 34964:case 35725:case 34965:case 36006:case 36007:case 32873:case 34229:case 36662:case 36663:case 35053:case 35055:case 36010:case 35097:case 35869:case 32874:case 36389:case 35983:case 35368:case 34068:{O=0;break}default:{Tr.recordError(1280);return}}else if(Q instanceof Float32Array||Q instanceof Uint32Array||Q instanceof Int32Array||Q instanceof Array){for(var ie=0;ie<Q.length;++ie)switch(ae){case 0:D[ee+ie*4>>>2>>>0]=Q[ie];break;case 2:I[ee+ie*4>>>2>>>0]=Q[ie];break;case 4:E[ee+ie>>>0]=Q[ie]?1:0;break}return}else try{O=Q.name|0}catch(he){Tr.recordError(1280),S(`GL_INVALID_ENUM in glGet${ae}v: Unknown object returned from WebGL getParameter(${$})! (error: ${he})`);return}break;default:Tr.recordError(1280),S(`GL_INVALID_ENUM in glGet${ae}v: Native code calling glGet${ae}v(${$}) and it returns ${Q} of type ${typeof Q}!`);return}}switch(ae){case 1:po(ee,O);break;case 0:D[ee>>>2>>>0]=O;break;case 2:I[ee>>>2>>>0]=O;break;case 4:E[ee>>>0]=O?1:0;break}};function zp($,ee){return ee>>>=0,Qv($,ee,0)}function Pu($,ee,ae,O){ae>>>=0,O>>>=0;var j=Or.getProgramInfoLog(Tr.programs[$]);j===null&&(j="(unknown error)");var Q=ee>0&&O?Di(j,O,ee):0;ae&&(D[ae>>>2>>>0]=Q)}function lc($,ee,ae){if(ae>>>=0,!ae){Tr.recordError(1281);return}if($>=Tr.counter){Tr.recordError(1281);return}if($=Tr.programs[$],ee==35716){var O=Or.getProgramInfoLog($);O===null&&(O="(unknown error)"),D[ae>>>2>>>0]=O.length+1}else if(ee==35719){if(!$.maxUniformLength)for(var j=Or.getProgramParameter($,35718),Q=0;Q<j;++Q)$.maxUniformLength=Math.max($.maxUniformLength,Or.getActiveUniform($,Q).name.length+1);D[ae>>>2>>>0]=$.maxUniformLength}else if(ee==35722){if(!$.maxAttributeLength)for(var ie=Or.getProgramParameter($,35721),Q=0;Q<ie;++Q)$.maxAttributeLength=Math.max($.maxAttributeLength,Or.getActiveAttrib($,Q).name.length+1);D[ae>>>2>>>0]=$.maxAttributeLength}else if(ee==35381){if(!$.maxUniformBlockNameLength)for(var he=Or.getProgramParameter($,35382),Q=0;Q<he;++Q)$.maxUniformBlockNameLength=Math.max($.maxUniformBlockNameLength,Or.getActiveUniformBlockName($,Q).length+1);D[ae>>>2>>>0]=$.maxUniformBlockNameLength}else D[ae>>>2>>>0]=Or.getProgramParameter($,ee)}function ey($,ee,ae,O){ae>>>=0,O>>>=0;var j=Or.getShaderInfoLog(Tr.shaders[$]);j===null&&(j="(unknown error)");var Q=ee>0&&O?Di(j,O,ee):0;ae&&(D[ae>>>2>>>0]=Q)}function qg($,ee,ae){if(ae>>>=0,!ae){Tr.recordError(1281);return}if(ee==35716){var O=Or.getShaderInfoLog(Tr.shaders[$]);O===null&&(O="(unknown error)");var j=O?O.length+1:0;D[ae>>>2>>>0]=j}else if(ee==35720){var Q=Or.getShaderSource(Tr.shaders[$]),ie=Q?Q.length+1:0;D[ae>>>2>>>0]=ie}else D[ae>>>2>>>0]=Or.getShaderParameter(Tr.shaders[$],ee)}var Vc=$=>{var ee=nr($)+1,ae=yi(ee);return ae&&Di($,ae,ee),ae};function Yl($){var ee=Tr.stringCache[$];if(!ee){switch($){case 7939:ee=Vc(Xh().join(" "));break;case 7936:case 7937:case 37445:case 37446:var ae=Or.getParameter($);ae||Tr.recordError(1280),ee=ae?Vc(ae):0;break;case 7938:var O=Or.getParameter(7938),j=`OpenGL ES 2.0 (${O})`;Tr.currentContext.version>=2&&(j=`OpenGL ES 3.0 (${O})`),ee=Vc(j);break;case 35724:var Q=Or.getParameter(35724),ie=/^WebGL GLSL ES ([0-9]\.[0-9][0-9]?)(?:$| .*)/,he=Q.match(ie);he!==null&&(he[1].length==3&&(he[1]=he[1]+"0"),Q=`OpenGL ES GLSL ES ${he[1]} (${Q})`),ee=Vc(Q);break;default:Tr.recordError(1280)}Tr.stringCache[$]=ee}return ee}function dh($,ee){return ee>>>=0,Or.getUniformBlockIndex(Tr.programs[$],fr(ee))}var xl=$=>parseInt($),Vs=$=>$.slice(-1)=="]"&&$.lastIndexOf("["),ty=$=>{var ee=$.uniformLocsById,ae=$.uniformSizeAndIdsByName,O,j;if(!ee){$.uniformLocsById=ee={},$.uniformArrayNamesById={};var Q=Or.getProgramParameter($,35718);for(O=0;O<Q;++O){var ie=Or.getActiveUniform($,O),he=ie.name,Oe=ie.size,Fe=Vs(he),Ge=Fe>0?he.slice(0,Fe):he,lt=$.uniformIdCounter;for($.uniformIdCounter+=Oe,ae[Ge]=[Oe,lt],j=0;j<Oe;++j)ee[lt]=j,$.uniformArrayNamesById[lt++]=Ge}}};function Cd($,ee){if(ee>>>=0,ee=fr(ee),$=Tr.programs[$]){ty($);var ae=$.uniformLocsById,O=0,j=ee,Q=Vs(ee);Q>0&&(O=xl(ee.slice(Q+1))>>>0,j=ee.slice(0,Q));var ie=$.uniformSizeAndIdsByName[j];if(ie&&O<ie[0]&&(O+=ie[1],ae[O]=ae[O]||Or.getUniformLocation($,ee)))return O}else Tr.recordError(1281);return-1}var $p=$=>{$=Tr.programs[$],Or.linkProgram($),$.uniformLocsById=0,$.uniformSizeAndIdsByName={}},Cu=($,ee)=>{$==3317?Tr.unpackAlignment=ee:$==3314&&(Tr.unpackRowLength=ee),Or.pixelStorei($,ee)},uc=($,ee,ae)=>{function O(ie,he){return ie+he-1&-he}var j=(Tr.unpackRowLength||$)*ae,Q=O(j,Tr.unpackAlignment);return ee*Q},Wp=$=>{var ee={5:3,6:4,8:2,29502:3,29504:4,26917:2,26918:2,29846:3,29847:4};return ee[$-6402]||1},Td=$=>($-=5120,$==0?E:$==1?A:$==2?R:$==4?D:$==6?I:$==5||$==28922||$==28520||$==30779||$==30782?F:M),Tu=($,ee)=>$>>>31-Math.clz32(ee.BYTES_PER_ELEMENT),fh=($,ee,ae,O,j,Q)=>{var ie=Td($),he=Wp(ee)*ie.BYTES_PER_ELEMENT,Oe=uc(ae,O,he);return ie.subarray(Tu(j,ie)>>>0,Tu(j+Oe,ie)>>>0)};function Gp($,ee,ae,O,j,Q,ie){if(ie>>>=0,Tr.currentContext.version>=2&&Or.currentPixelPackBufferBinding){Or.readPixels($,ee,ae,O,j,Q,ie);return}var he=fh(Q,j,ae,O,ie);if(!he){Tr.recordError(1280);return}Or.readPixels($,ee,ae,O,j,Q,he)}var Ua=($,ee,ae,O)=>Or.scissor($,ee,ae,O);function xd($,ee,ae,O){ae>>>=0,O>>>=0;var j=Tr.getSource($,ee,ae,O);Or.shaderSource(Tr.shaders[$],j)}function hh($,ee,ae,O,j,Q,ie,he,Oe){if(Oe>>>=0,Tr.currentContext.version>=2&&Or.currentPixelUnpackBufferBinding){Or.texImage2D($,ee,ae,O,j,Q,ie,he,Oe);return}var Fe=Oe?fh(he,ie,O,j,Oe):null;Or.texImage2D($,ee,ae,O,j,Q,ie,he,Fe)}var Wu=($,ee,ae)=>Or.texParameteri($,ee,ae),Yp=$=>{var ee=Or.currentProgram;if(ee){var ae=ee.uniformLocsById[$];return typeof ae=="number"&&(ee.uniformLocsById[$]=ae=Or.getUniformLocation(ee,ee.uniformArrayNamesById[$]+(ae>0?`[${ae}]`:""))),ae}else Tr.recordError(1282)},Hc=($,ee)=>{Or.uniform1i(Yp($),ee)},cc=($,ee,ae)=>{$=Tr.programs[$],Or.uniformBlockBinding($,ee,ae)},Xg=$=>{$=Tr.programs[$],Or.useProgram($),Or.currentProgram=$},Ps=($,ee)=>{Or.vertexAttribDivisor($,ee)};function Kh($,ee,ae,O,j,Q){Q>>>=0,Or.vertexAttribPointer($,ee,ae,!!O,j,Q)}var ql=($,ee,ae,O)=>Or.viewport($,ee,ae,O),El=$=>zc($),Uc=$=>{var ee=nr($)+1,ae=El(ee);return Di($,ae,ee),ae},ph=$=>{var ee=s["_"+$];return ee},qp=($,ee)=>{E.set($,ee>>>0)},wl=($,ee,ae,O,j)=>{var Q={string:jt=>{var cr=0;return jt!=null&&jt!==0&&(cr=Uc(jt)),cr},array:jt=>{var cr=El(jt.length);return qp(jt,cr),cr}};function ie(jt){return ee==="string"?fr(jt):ee==="boolean"?!!jt:jt}var he=ph($),Oe=[],Fe=0;if(O)for(var Ge=0;Ge<O.length;Ge++){var lt=Q[ae[Ge]];lt?(Fe===0&&(Fe=vt()),Oe[Ge]=lt(O[Ge])):Oe[Ge]=O[Ge]}var Ot=he(...Oe);function St(jt){return Fe!==0&&qe(Fe),ie(jt)}return Ot=St(Ot),Ot},ol=($,ee,ae,O)=>{var j=!ae||ae.every(ie=>ie==="number"||ie==="boolean"),Q=ee!=="string";return Q&&j&&!O?ph($):(...ie)=>wl($,ee,ae,ie)};ce.createPreloadedFile=xn,ce.staticInit(),rr.doesNotExistError=new ce.ErrnoError(44),rr.doesNotExistError.stack="<generic error, no stack>",si=s.BindingError=class extends Error{constructor(ee){super(ee),this.name="BindingError"}},ts(),ye=s.PureVirtualError=re(Error,"PureVirtualError"),Ye(),ic=s.InternalError=class extends Error{constructor(ee){super(ee),this.name="InternalError"}},dd(),et(),Oi=s.UnboundTypeError=re(Error,"UnboundTypeError"),s.requestAnimationFrame=Nt.requestAnimationFrame,s.pauseMainLoop=Nt.pause,s.resumeMainLoop=Nt.resume,Nt.init(),ya.init();var Ea={g:Ht,U:Lr,ib:Cr,jb:zr,gb:fi,W:to,$:cd,Za:ml,Z:bl,c:ms,f:Bs,d:jg,a:js,b:hd,X:Yd,j:ac,e:Nh,H:Vg,i:Hg,o:gd,k:Zf,Y:Ip,D:Rc,_:Np,Ca:Mc,bb:nl,u:Vh,ba:is,t:ns,aa:os,r:Hh,Wa:th,db:Ug,Ya:Ke,K:xe,wa:hr,kb:ho,Sa:$l,cb:ef,na:tf,La:rf,J:ih,ha:ma,I:ja,eb:mu,fb:Ss,V:jp,hb:of,Xa:oh,T:lo,ca:wt,ra:kn,P:md,l:bu,m:$g,ua:bd,s:Wh,q:ah,Ka:af,Ja:nt,Ma:Sd,w:_d,da:Tl,L:nn,Ta:Fc,Ua:Pd,Ga:Bc,oa:jc,B:Wg,Ba:sh,qa:Vp,Qa:sf,S:_s,Ea:Su,Q:Kv,Da:Fm,O:Bm,Fa:jm,Na:Ha,Oa:$u,R:Gh,z:Yh,Ra:Gg,fa:lh,ga:uh,ea:lf,y:Zv,ka:Vm,E:_u,Pa:uf,x:Yg,M:Hp,C:Jv,Va:ch,xa:qh,p:zp,za:Pu,F:lc,ma:ey,N:qg,v:Yl,ya:dh,va:Cd,Aa:$p,la:Cu,Ia:Gp,Ha:Ua,pa:xd,n:hh,h:Wu,sa:Hc,ta:cc,G:Xg,ia:Ps,ja:Kh,A:ql,$a:$c,ab:cf,_a:ry},Io;Ue();var Al=$=>(Al=Io.nb)($),xi=s._free=$=>(xi=s._free=Io.ob)($),yi=s._malloc=$=>(yi=s._malloc=Io.pb)($);s._SCRTFillActiveTextureCharArray=($,ee,ae)=>(s._SCRTFillActiveTextureCharArray=Io.rb)($,ee,ae),s._SCRTFillActiveTextureFloat=($,ee,ae)=>(s._SCRTFillActiveTextureFloat=Io.sb)($,ee,ae);var Xo=s._main=($,ee)=>(Xo=s._main=Io.tb)($,ee),Cs=s._setThrew=($,ee)=>(Cs=s._setThrew=Io.ub)($,ee),Ol=$=>(Ol=Io.vb)($),zc=$=>(zc=Io.wb)($),Ed=()=>(Ed=Io.xb)();s.dynCall_jiji=($,ee,ae,O,j)=>(s.dynCall_jiji=Io.yb)($,ee,ae,O,j),s.dynCall_viijii=($,ee,ae,O,j,Q,ie)=>(s.dynCall_viijii=Io.zb)($,ee,ae,O,j,Q,ie),s.dynCall_iiiiij=($,ee,ae,O,j,Q,ie)=>(s.dynCall_iiiiij=Io.Ab)($,ee,ae,O,j,Q,ie),s.dynCall_iiiiijj=($,ee,ae,O,j,Q,ie,he,Oe)=>(s.dynCall_iiiiijj=Io.Bb)($,ee,ae,O,j,Q,ie,he,Oe),s.dynCall_iiiiiijj=($,ee,ae,O,j,Q,ie,he,Oe,Fe)=>(s.dynCall_iiiiiijj=Io.Cb)($,ee,ae,O,j,Q,ie,he,Oe,Fe);function cf($,ee,ae,O){var j=vt();try{return Kt($)(ee,ae,O)}catch(Q){if(qe(j),Q!==Q+0)throw Q;Cs(1,0)}}function $c($,ee,ae){var O=vt();try{return Kt($)(ee,ae)}catch(j){if(qe(O),j!==j+0)throw j;Cs(1,0)}}function ry($,ee,ae,O,j){var Q=vt();try{return Kt($)(ee,ae,O,j)}catch(ie){if(qe(Q),ie!==ie+0)throw ie;Cs(1,0)}}function Ko($){$=Object.assign({},$);var ee=O=>j=>O(j)>>>0,ae=O=>()=>O()>>>0;return $.nb=ee($.nb),$.pb=ee($.pb),$.wb=ee($.wb),$.xb=ae($.xb),$}s.callMain=Zh,s.ccall=wl,s.cwrap=ol,s.UTF8ToString=fr,s.stringToUTF8=Di,s.lengthBytesUTF8=nr,s.specialHTMLTargets=_n;var df;Re=function $(){df||Xp(),df||(Re=$)};function Zh($=[]){var ee=Xo;$.unshift(h);var ae=$.length,O=El((ae+1)*4),j=O;$.forEach(ie=>{F[j>>>2>>>0]=Uc(ie),j+=4}),F[j>>>2>>>0]=0;try{var Q=ee(ae,O);return at(Q,!0),Q}catch(ie){return pt(ie)}}function Xp($=f){if(Ee>0||(X(),Ee>0))return;function ee(){var ae;df||(df=!0,s.calledRun=!0,!P&&(W(),Y(),l(s),(ae=s.onRuntimeInitialized)==null||ae.call(s),Wc&&Zh($),te()))}s.setStatus?(s.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>s.setStatus(""),1),ee()},1)):ee()}if(s.preInit)for(typeof s.preInit=="function"&&(s.preInit=[s.preInit]);s.preInit.length>0;)s.preInit.pop()();var Wc=!0;return s.noInitialRun&&(Wc=!1),Xp(),Tr&&(Tr.getNewId=function($){Tr.counter++;var ee=$.length;if(ee===0)return 1;for(var ae=1;ae<ee;++ae)if($[ae]===null)return ae;return ee}),a=c,a})})();t.exports=i,t.exports.default=i})(g9)),g9.exports}var v9={},Eve;function tC(){return Eve||(Eve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.createSvgLayer=t.ELayerClass=void 0;var e=LD(),i=La(),n=Sn(),r=Zi(),o;(function(y){y[y.canvasWebGL=0]="canvasWebGL",y[y.canvas2D=1]="canvas2D",y[y.svg=2]="svg"})(o||(o={}));var a;(function(y){y.DIV_ROOT="div-root",y.SVG_ROOT="svg-root",y.BACK_DIV_ROOT="back-div-root",y.FRONT_DIV_ROOT="front-div-root",y.BACK_SVG_ROOT="back-svg-root",y.FRONT_SVG_ROOT="front-svg-root",y.ADORNER_SVG_ROOT="adorner-svg-root",y.CANVAS_ROOT="canvas-root"})(a=t.ELayerClass||(t.ELayerClass={}));var s=1.5,l=function(y){return"".concat(y,"_2D")},u=function(y,m,b,S,_){S===void 0&&(S=0),_===void 0&&(_=0);var C;S&&_?C=S/_:y&&m?C=void 0:C=s;var P=Math.round(y||600);if(C){var x=Math.round(P/C);return x>b&&(x=b),{width:P,height:x,aspectRatio:C}}else{var x=Math.round(m);return{width:P,height:x,aspectRatio:C}}},c=function(y){var m=typeof y=="string"?document.querySelector("#".concat(y)):y;if(!m)throw new Error('Check div element with id "'.concat(m.id,'" exists'));if(m.nodeName.toLowerCase()!=="div")throw new Error('Element with id "'.concat(m.id,'" should be of type div'));return m},d=function(y){var m=y.style.maxHeight;if(m){var b=m.includes("px");if(b){var S=parseInt(m.replace("px",""),10);if(!isNaN(S))return S}}},f=function(y,m,b,S,_,C){var P;S===void 0&&(S=o.canvasWebGL);var x=i.PerformanceDebugHelper.mark(i.EPerformanceMarkType.CanvasInitializationStart,{level:i.EPerformanceDebugLevel.Verbose});e.WebGlHelper.initialize(),r.DpiHelper.initialize();var E=c(y);E.innerHTML="",E.style.position===""&&(E.style.position="relative"),E.style.overflow===""&&(E.style.overflow="hidden");var A=E.id,R=E.offsetWidth,M=E.offsetHeight,D=d(E),F=u(R,M,D,m,b),I=F.width,V=F.height,z=F.aspectRatio;!_&&z&&(E.style.aspectRatio="".concat(z));var G=document.createElement("div");G.id="".concat(A,"_background_div"),G.classList.add(a.DIV_ROOT,a.BACK_DIV_ROOT),G.style.width="100%",G.style.height="100%",G.style.position="absolute",G.style.pointerEvents="none",E.appendChild(G);var H=(0,t.createSvgLayer)("".concat(A,"_BACKGROUND_SVG"),I,V);H.style.width="100%",H.style.height="100%",H.style.pointerEvents="none",H.classList.add(a.BACK_SVG_ROOT),E.appendChild(H);var U;S===o.canvasWebGL&&(U=document.createElement("canvas"),U.id="".concat(A,"_WebGL"),U.classList.add(a.CANVAS_ROOT),U.style.position="absolute",U.style.display="block",U.style.width="100%",U.style.height="100%",e.WebGlHelper.getContext(U,{premultipliedAlpha:!0,antialias:n.SciChartSurfaceBase.AntiAliasWebGlBackbuffer}),E.appendChild(U));var k=document.createElement("canvas");k.id=l(A),k.classList.add(a.CANVAS_ROOT),k.style.width="100%",k.style.height="100%",r.DpiHelper.setSize(k,I,V),k.style.position="absolute",S!==o.canvas2D&&(k.style.pointerEvents="none"),S===o.canvasWebGL?k.style.display="none":k.style.display="block",E.appendChild(k),k.style.touchAction=C??"none",k.onselectstart=function(){return!1};var X=(0,t.createSvgLayer)("".concat(A,"_SVG"),I,V);X.style.width="100%",X.style.height="100%",S!==o.svg&&(X.style.pointerEvents="none"),X.classList.add(a.FRONT_SVG_ROOT),E.appendChild(X);var W=(0,t.createSvgLayer)("".concat(A,"_Adorner"),I,V);W.style.pointerEvents="none",W.style.width="100%",W.style.height="100%",W.style.zIndex="1",W.classList.add(a.ADORNER_SVG_ROOT),E.appendChild(W);var Y=document.createElement("div");return Y.id="".concat(A,"_div"),Y.classList.add(a.DIV_ROOT,a.FRONT_DIV_ROOT),Y.style.width="100%",Y.style.height="100%",Y.style.position="relative",Y.style.pointerEvents="none",Y.style.textAlign="center",E.appendChild(Y),S===o.canvasWebGL&&U.addEventListener("webglcontextlost",function(te){console.warn("WebGL context lost. Reloading the page."),te.preventDefault(),location.reload()},!1),i.PerformanceDebugHelper.mark(i.EPerformanceMarkType.CanvasInitializationEnd,{level:i.EPerformanceDebugLevel.Verbose,contextId:k.id,relatedId:(P=x==null?void 0:x.detail)===null||P===void 0?void 0:P.relatedId}),{domChartRoot:E,domCanvasWebGL:U,domCanvas2D:k,domSvgContainer:X,domSvgAdornerLayer:W,domDivContainer:Y,domSeriesBackground:G,domBackgroundSvgContainer:H,aspect:z,disableAspect:_}},h=function(y,m,b,S){var _=new ResizeObserver(function(P){for(var x=function(M){var D,F;M.contentRect?(D=M.contentRect.width,F=M.contentRect.height):M.contentBoxSize?M.contentBoxSize.inlineSize?D=M.contentBoxSize.inlineSize:M.contentBoxSize[0]&&(D=M.contentBoxSize[0].inlineSize):(console.error("ResizeObserver is not supported"),D=900);var I=d(y);I&&F>I&&(F=I);var V=D!==0&&F!==0,z=b.domCanvas2D.width!==D*r.DpiHelper.PIXEL_RATIO||b.domCanvas2D.height!==F*r.DpiHelper.PIXEL_RATIO;V&&z&&setTimeout(function(){b.onResize(D,F)},0)},E=0,A=P;E<A.length;E++){var R=A[E];x(R)}});_.observe(y,{box:"border-box"});var C={delete:function(){return _.disconnect()}};return C},p=function(y){if(typeof y=="string"){var m=document.querySelectorAll("[id=".concat(y,"]")).length;m>1?console.error('Please provide a unique ID for each chart div element, "'.concat(y,'" it is not a unique identifier')):m===0&&console.error('Chart div element with the ID "'.concat(y,'" is not present in the DOM'))}else if(!y)throw new Error("Provided div element doesn't exist!")},g=function(y,m,b){var S=document.createElementNS("http://www.w3.org/2000/svg","svg");return S.id=y,S.setAttribute("width",m.toString()),S.setAttribute("height",b.toString()),S.setAttribute("role","img"),S.setAttribute("xmlns","http://www.w3.org/2000/svg"),S.style.position="absolute",S.style.display="block",S.classList.add(a.SVG_ROOT),S};t.createSvgLayer=g;var v={checkChartDivExists:p,ECanvasType:o,getCanvas2dId:l,initCanvas:f,subscribeToResize:h};t.default=v})(v9)),v9}var gF={},wve;function LFe(){if(wve)return gF;wve=1,Object.defineProperty(gF,"__esModule",{value:!0}),gF.copyToCanvas=void 0;var t=kh(),e=La(),i=function(n,r){return function(o){var a;t.Logger.debug("copyToCanvas");var s=e.PerformanceDebugHelper.mark(e.EPerformanceMarkType.CopyToCanvasStart,{parentContextId:o,level:e.EPerformanceDebugLevel.Verbose}),l=r(o),u=l==null?void 0:l.sciChartSurface,c=l==null?void 0:l.sciChartSurface.domCanvas2D;if(c){var d=c.getContext("2d");d.globalCompositeOperation="copy",d.drawImage(n,0,0,c.width,c.height,0,0,c.width,c.height),e.PerformanceDebugHelper.mark(e.EPerformanceMarkType.CopyToCanvasEnd,{contextId:u.id,parentContextId:o,relatedId:(a=s==null?void 0:s.detail)===null||a===void 0?void 0:a.relatedId,level:e.EPerformanceDebugLevel.Verbose});var f=u.isInvalidated;u.renderedToDestination.raiseEvent(f)}}};return gF.copyToCanvas=i,gF}var vF={},Ave;function TW(){if(Ave)return vF;Ave=1,Object.defineProperty(vF,"__esModule",{value:!0}),vF.preRun=void 0;var t=function(e){e.specialHTMLTargets[0]=e.canvas};return vF.preRun=t,vF}var Ove;function H3(){return Ove||(Ove=1,(function(t){var e=y1&&y1.__awaiter||function(z,G,H,U){function k(X){return X instanceof H?X:new H(function(W){W(X)})}return new(H||(H=Promise))(function(X,W){function Y(de){try{oe(U.next(de))}catch(ge){W(ge)}}function te(de){try{oe(U.throw(de))}catch(ge){W(ge)}}function oe(de){de.done?X(de.value):k(de.value).then(Y,te)}oe((U=U.apply(z,G||[])).next())})},i=y1&&y1.__generator||function(z,G){var H={label:0,sent:function(){if(X[0]&1)throw X[1];return X[1]},trys:[],ops:[]},U,k,X,W;return W={next:Y(0),throw:Y(1),return:Y(2)},typeof Symbol=="function"&&(W[Symbol.iterator]=function(){return this}),W;function Y(oe){return function(de){return te([oe,de])}}function te(oe){if(U)throw new TypeError("Generator is already executing.");for(;H;)try{if(U=1,k&&(X=oe[0]&2?k.return:oe[0]?k.throw||((X=k.return)&&X.call(k),0):k.next)&&!(X=X.call(k,oe[1])).done)return X;switch(k=0,X&&(oe=[oe[0]&2,X.value]),oe[0]){case 0:case 1:X=oe;break;case 4:return H.label++,{value:oe[1],done:!1};case 5:H.label++,k=oe[1],oe=[0];continue;case 7:oe=H.ops.pop(),H.trys.pop();continue;default:if(X=H.trys,!(X=X.length>0&&X[X.length-1])&&(oe[0]===6||oe[0]===2)){H=0;continue}if(oe[0]===3&&(!X||oe[1]>X[0]&&oe[1]<X[3])){H.label=oe[1];break}if(oe[0]===6&&H.label<X[1]){H.label=X[1],X=oe;break}if(X&&H.label<X[2]){H.label=X[2],H.ops.push(oe);break}X[2]&&H.ops.pop(),H.trys.pop();continue}oe=G.call(z,H)}catch(de){oe=[6,de],k=0}finally{U=X=0}if(oe[0]&5)throw oe[1];return{value:oe[0]?oe[1]:void 0,done:!0}}};Object.defineProperty(t,"__esModule",{value:!0}),t.monitorWebGL=t.disposeMultiChart=t.initializeChartEngine2D=t.getSharedWasmContext=t.createMultichart=void 0;var n=MFe(),r=vm(),o=ci(),a=Iu(),s=AI(),l=Wf(),u=tC(),c=Rg(),d=Sn(),f=$v(),h=fo(),p=an(),g=ZD(),v=gm(),y=LD(),m=kh(),b=LFe(),S=La(),_=hl(),C=TW(),P={id:void 0,wasmContext:void 0,getChildSurfaces:void 0,createChildSurface:void 0},x,E=function(z,G,H){return e(void 0,void 0,void 0,function(){var U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te;return i(this,function(ke){switch(ke.label){case 0:u.default.checkChartDivExists(z),U=u.default.initCanvas(z,(ge=H==null?void 0:H.widthAspect)!==null&&ge!==void 0?ge:0,(Ee=H==null?void 0:H.heightAspect)!==null&&Ee!==void 0?Ee:0,u.default.ECanvasType.canvas2D,(Re=H==null?void 0:H.disableAspect)!==null&&Re!==void 0?Re:l.SciChartDefaults.disableAspect,H==null?void 0:H.touchAction),k=(Ae=H==null?void 0:H.loader)!==null&&Ae!==void 0?Ae:l.SciChartDefaults.defaultLoader,X=(Pe=k.addChartLoader)===null||Pe===void 0?void 0:Pe.call(k,U.domDivContainer,H==null?void 0:H.theme),ke.label=1;case 1:return ke.trys.push([1,3,,4]),[4,(0,t.initializeChartEngine2D)({destinationCanvas:U.domCanvas2D})];case 2:return ke.sent(),W=P.createChildSurface,Y=P.wasmContext,Y.TSRSetDrawRequestsEnabled((we=!(H!=null&&H.disableEngineLoop))!==null&&we!==void 0?we:!0),te=U?U.domChartRoot.id:"divElementId",oe=W(te,U,H==null?void 0:H.theme,G),[2,new Promise(function($e){setTimeout(function(){var Ne,ve;((Ne=H==null?void 0:H.createSuspended)!==null&&Ne!==void 0?Ne:l.SciChartDefaults.createSuspended)&&oe.suspendUpdates(),(ve=k.removeChartLoader)===null||ve===void 0||ve.call(k,U.domDivContainer,X),X=void 0,oe.setIsInitialized(),$e({wasmContext:Y,sciChartSurface:oe})},0)})];case 3:return de=ke.sent(),console.error(de),(Te=k.removeChartLoader)===null||Te===void 0||Te.call(k,U.domDivContainer,X),X=void 0,[2,Promise.reject(de)];case 4:return[2]}})})};t.createMultichart=E;var A=function(){return e(void 0,void 0,void 0,function(){var z;return i(this,function(G){switch(G.label){case 0:return[4,(0,t.initializeChartEngine2D)()];case 1:return z=G.sent().wasmContext,[2,z]}})})};t.getSharedWasmContext=A;var R=function(z){return e(void 0,void 0,void 0,function(){var G,H,U,k,X;return i(this,function(W){switch(W.label){case 0:return G=(k=z==null?void 0:z.destinationCanvas)===null||k===void 0?void 0:k.id,H=S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.EngineInitStart,{parentContextId:G}),y.WebGlHelper.initialize(),!P.wasmContext||!P.createChildSurface||!P.getChildSurfaces?(x||(x=I()),[4,x]):[3,2];case 1:U=W.sent(),P.id=U.id,P.wasmContext=U.wasmContext,(0,r.checkBuildStamp)(U.wasmContext),P.createChildSurface=U.createChildSurface,P.getChildSurfaces=U.getChildSurfaces,(0,t.monitorWebGL)(U.wasmContext,!0),W.label=2;case 2:return S.PerformanceDebugHelper.mark(S.EPerformanceMarkType.EngineInitEnd,{relatedId:(X=H==null?void 0:H.detail)===null||X===void 0?void 0:X.relatedId,contextId:P.id,parentContextId:G}),[2,x]}})})};t.initializeChartEngine2D=R;var M,D=function(){M&&M(),P.createChildSurface=void 0,P.getChildSurfaces=void 0,P.wasmContext=void 0,P.id=void 0,x=void 0,s.licenseManager.clear()};t.disposeMultiChart=D;var F=function(z,G){var H=function(){return G?f.sciChartDestinations:f.sciChartSingleDestinations},U=function(){z.SCRTInitEngine2D();for(var W=0,Y=H();W<Y.length;W++){var te=Y[W];te.sciChartSurface.isWebGLContextActive=!0,te.sciChartSurface.invalidateElement({force:!0})}},k=function(W){console.warn("WebGL context lost: ",W.statusMessage),W.preventDefault();for(var Y=0,te=H();Y<te.length;Y++){var oe=te[Y];oe.sciChartSurface.isWebGLContextActive=!1}a.WebGlRenderContext2D.webGlResourcesRefs.forEach(function(de){de.invalidateCache()}),g.labelCache.resetCache(),(0,p.deleteCache)(z),z.SCRTShutdownEngine2D()},X=function(W){console.warn("WebGL context restored: ",W.statusMessage),U()};z.canvas.addEventListener("webglcontextlost",k,!1),z.canvas.addEventListener("webglcontextrestored",X,!1)};t.monitorWebGL=F;var I=function(){var z=function(H,U,k,X){o.Guard.notNull(X,"theme");var W=k(H,{canvases:U});W.applyTheme(X);var Y=u.default.subscribeToResize(U.domChartRoot,U.aspect,W,U.disableAspect);return W.addDeletable(Y),W.setDestinations(f.sciChartDestinations),W},G=function(H,U,k,X,W,Y){var te=(0,d.createChartDestination)(k.domCanvas2D);if(!te){k.delete();return}var oe=H.SCRTSurfaceDestination.implement(te);Y.AddDestination(oe),Y.SetFPSCounterEnabled(!1),f.sciChartDestinations.push({canvasElementId:U,sciChartSurface:k,width:X,height:W})};return new Promise(function(H,U){var k=(0,d.getMasterCanvas)(),X=(0,d.getLocateFile)(c.sciChartConfig);new n({locateFile:X,noInitialRun:!0,canvas:k,preRun:C.preRun}).then(function(W,Y){var te=(0,_.generateGuid)(),oe=(0,h.createWasmContextRevocableProxy)(W,te),de=oe.proxy;s.licenseManager.applyLicense(de,"2D master"),M=function(){g.labelCache.resetCache(),de.TSRRequestExit(),ge.delete(),de.SCRTGetGlobalSampleChartInterface().SetFrameRenderer(null),de.SCRTGetGlobalSampleChartInterface().delete(),de.SCRTSetGlobalSampleChartInterface(null),(0,p.deleteCache)(de),Ee.delete(),de.SCRTSetGlobalCopyToDestinationInterface(null),oe.revoke(),oe=void 0,M=void 0};var ge=new de.SCRTFrameRenderer2D,Ee=de.SCRTCopyToDestinationInterface.implement({CopyToDestination:(0,b.copyToCanvas)(d.SciChartSurfaceBase.domMasterCanvas,V)}),Re=function(){return f.sciChartDestinations.map(function(Te){return Te.sciChartSurface})},Ae=function(Te,ke,$e,Ne){o.Guard.notNull($e,"theme");var ve=u.default.getCanvas2dId(Te),pe=f.sciChartDestinations.filter(function(Ce){return Ce.canvasElementId===ve}),fe=f.sciChartDestinations.filter(function(Ce){return Ce.canvasElementId!==ve});for(we.ClearDestinations();f.sciChartDestinations.length>0;)f.sciChartDestinations.pop();fe.forEach(function(Ce){return G(de,Ce.canvasElementId,Ce.sciChartSurface,Ce.width,Ce.height,we)});var me=z(de,ke,Ne,$e);return me.addDeletable({delete:function(){c.SciChartSurface.autoDisposeWasmContext&&(0,f.getOther2DMultiChartDestinations)(me).length===0&&(c.SciChartSurface.wasmContextDisposeTimeout?setTimeout(function(){f.sciChartDestinations.length===0&&c.SciChartSurface.disposeSharedWasmContext()},c.SciChartSurface.wasmContextDisposeTimeout):c.SciChartSurface.disposeSharedWasmContext())}}),G(de,ve,me,ke.domCanvas2D.width,ke.domCanvas2D.height,we),pe.forEach(function(Ce){return Ce.sciChartSurface.delete(!1)}),s.licenseManager.updateLicenseDisplay(me),me},Pe={InitializeChart:function(){m.Logger.debug("InitializeChart"),H({id:te,getChildSurfaces:Re,createChildSurface:Ae,wasmContext:de})},Draw:function(Te){m.Logger.debug("Draw",Te);var ke=f.sciChartDestinations.find(function($e){return $e.canvasElementId===Te});ke&&ke.sciChartSurface.renderSurface.onRenderTimeElapsed()},Update:function(Te){m.Logger.debug("sciChartInitCommon.ts Update",Te)},ShutDownChart:function(){m.Logger.debug("sciChartInitCommon.ts ShutDownChart")}},we=de.SCRTSampleChartInterface.implement(Pe);we.SetFrameRenderer(ge),we.SetWasmBufferSizesKb(l.SciChartDefaults.wasmBufferSizesKb),de.SCRTSetGlobalSampleChartInterface(we),de.SCRTSetGlobalCopyToDestinationInterface(Ee),d.SciChartSurfaceBase.domMasterCanvas&&de.SCRTSetMainWindowSize(d.SciChartSurfaceBase.domMasterCanvas.width,d.SciChartSurfaceBase.domMasterCanvas.height),de.callMain()}).catch(function(W){console.error(W),U(`Could not load SciChart WebAssembly module.
                Check your build process and ensure that your "scichart2d.wasm" and "scichart2d.js" files are from the same version`)})})},V=function(z){return f.sciChartDestinations.find(function(G){return G.canvasElementId===z})}})(y1)),y1}var y9={},Dve;function kFe(){return Dve||(Dve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.initDrawEngineSingleChart=t.createSingleInternal=void 0;var e=MFe(),i=vm(),n=ci(),r=kh(),o=AI(),a=Wf(),s=tC(),l=Rg(),u=Sn(),c=an(),d=fo(),f=$v(),h=ZD(),p=H3(),g=La(),v=TW(),y=function(b,S,_){return new Promise(function(C,P){var x,E,A,R=s.default.initCanvas(b,_==null?void 0:_.widthAspect,_==null?void 0:_.heightAspect,void 0,(x=_==null?void 0:_.disableAspect)!==null&&x!==void 0?x:a.SciChartDefaults.disableAspect,_==null?void 0:_.touchAction),M=(E=_==null?void 0:_.loader)!==null&&E!==void 0?E:a.SciChartDefaults.defaultLoader,D=(A=M.addChartLoader)===null||A===void 0?void 0:A.call(M,R.domDivContainer,_==null?void 0:_.theme),F=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.EngineInitStart,{parentContextId:R.domCanvas2D.id}),I=(0,u.getLocateFile)(l.sciChartConfig);new e({locateFile:I,noInitialRun:!0,canvas:R.domCanvasWebGL,preRun:v.preRun}).then(function(V){var z,G;(z=M.removeChartLoader)===null||z===void 0||z.call(M,R.domDivContainer,D),V.doNotCaptureKeyboard=!0,o.licenseManager.applyLicense(V,"2D single");var H=(0,d.createWasmContextRevocableProxy)(V,R.domCanvas2D.id),U=function(k){var X;((X=_==null?void 0:_.createSuspended)!==null&&X!==void 0?X:a.SciChartDefaults.createSuspended)&&k.sciChartSurface.suspendUpdates(),k.sciChartSurface.addDeletable({delete:function(){H.revoke(),H=void 0}}),g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.EngineInitEnd,{relatedId:F==null?void 0:F.detail.relatedId,contextId:k.sciChartSurface.id,parentContextId:R.domCanvas2D.id}),C(k)};(0,t.initDrawEngineSingleChart)(H.proxy,R,U,_==null?void 0:_.theme,S),V.TSRSetDrawRequestsEnabled((G=!(_!=null&&_.disableEngineLoop))!==null&&G!==void 0?G:!0),(0,i.checkBuildStamp)(V),(0,p.monitorWebGL)(V,!1)}).catch(function(V){var z;r.Logger.debug(V),(z=M.removeChartLoader)===null||z===void 0||z.call(M,R.domDivContainer,D),P(`Could not load SciChart WebAssembly module.
                Check your build process and ensure that your "scichart2d.wasm" and "scichart2d.js" files are from the same version`)})})};t.createSingleInternal=y;var m=function(b,S,_,C,P){n.Guard.notNull(C,"theme");var x=S.domCanvas2D.width,E=S.domCanvas2D.height,A;b.canvas=S.domCanvasWebGL;var R=new b.SCRTFrameRenderer2D,M=S.domCanvasWebGL.id,D={InitializeChart:function(){A=P(b,{canvases:S}),A.applyTheme(C),f.sciChartSingleDestinations.push({canvasElementId:M,sciChartSurface:A,width:x,height:E}),A.setDestinations(f.sciChartSingleDestinations),A.addDeletable({delete:function(){b.TSRRequestExit(),R.delete(),b.SCRTGetGlobalSampleChartInterface().SetFrameRenderer(null),b.SCRTGetGlobalSampleChartInterface().delete(),b.SCRTSetGlobalSampleChartInterface(null),h.labelCache.resetCache()}}),setTimeout(function(){A.invalidateElement(),o.licenseManager.updateLicenseDisplay(A);var I=s.default.subscribeToResize(S.domChartRoot,S.aspect,A,S.disableAspect);A.addDeletable(I),A.addDeletable((0,c.freeCache)(b)),A.setIsInitialized(),_({wasmContext:b,sciChartSurface:A})},0)},Draw:function(I){A.renderSurface.onRenderTimeElapsed()},Update:function(I){},ShutDownChart:function(){}},F=b.SCRTSampleChartInterface.implement(D);F.SetFrameRenderer(R),F.SetFPSCounterEnabled(!1),F.SetWasmBufferSizesKb(a.SciChartDefaults.wasmBufferSizesKb),b.SCRTSetGlobalSampleChartInterface(F),b.callMain()};t.initDrawEngineSingleChart=m})(y9)),y9}var yF={},Rve;function jre(){if(Rve)return yF;Rve=1,Object.defineProperty(yF,"__esModule",{value:!0}),yF.drawBorder=void 0;var t=ZP(),e=an(),i=function(n,r,o,a,s,l,u,c,d,f){if(!(d===0&&u===0&&l===0&&c===0)){var h=o.newBrush(f,!0),p=(0,e.getVectorRectVertex)(r);p.push_back((0,t.createNativeRect)(r,a.x,a.y-u,a.x+a.width+c,a.y)),p.push_back((0,t.createNativeRect)(r,a.x+a.width,a.y,a.x+a.width+c,a.y+a.height+d)),p.push_back((0,t.createNativeRect)(r,a.x-l,a.y+a.height,a.x+a.width,a.y+a.height+d)),p.push_back((0,t.createNativeRect)(r,a.x-l,a.y-u,a.x,a.y+a.height)),n.drawRects(p,h,s,0,0)}};return yF.drawBorder=i,yF}var m1={},b1={},Mve;function Vre(){if(Mve)return b1;Mve=1;var t=b1&&b1.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(b1,"__esModule",{value:!0}),b1.BaseStackedCollection=void 0;var e=cP(),i=fo(),n=Br(),r=fW(),o=di(),a=DP(),s=QD(),l=ym(),u=eC(),c=qV(),d=hl(),f=gm(),h=Bu(),p=$S(),g=un(),v=(function(y){t(m,y);function m(b,S){var _=this,C,P,x,E,A,R,M,D,F;return _=y.call(this)||this,_.id=(0,d.generateGuid)(),_.isStacked=!0,_.isCollection=!0,_.isPolar=!1,_.supportsResampling=!1,_.isSpline=!1,_.enableDrawingOptimisations=!0,_.isAccumulatedVectorDirty=!0,_.firstAnimationRender=!1,_.isVisibleProperty=!0,_.isOneHundredPercentProperty=!1,_.animationQueue=[],_.yRangeModeProperty=u.EYRangeMode.Drawn,_.seriesNameProperty=void 0,_.surfaceRenderOrderProperty=void 0,_.renderLayerProperty=s.EDefaultRenderLayer.SeriesLayer,_.renderOrderProperty=void 0,_.webAssemblyContext=b,_.isVisibleProperty=(C=S==null?void 0:S.isVisible)!==null&&C!==void 0?C:_.isVisibleProperty,_.xAxisIdProperty=(P=S==null?void 0:S.xAxisId)!==null&&P!==void 0?P:_.xAxisIdProperty,_.yAxisIdProperty=(x=S==null?void 0:S.yAxisId)!==null&&x!==void 0?x:_.yAxisIdProperty,_.isOneHundredPercentProperty=(E=S==null?void 0:S.isOneHundredPercent)!==null&&E!==void 0?E:_.isOneHundredPercentProperty,_.yRangeModeProperty=(A=S==null?void 0:S.yRangeMode)!==null&&A!==void 0?A:_.yRangeModeProperty,_.updateAnimationProperties=_.updateAnimationProperties.bind(_),_.notifyPropertyChanged=_.notifyPropertyChanged.bind(_),_.getParentSurface=_.getParentSurface.bind(_),_.beforeAnimationStart=_.beforeAnimationStart.bind(_),_.afterAnimationComplete=_.afterAnimationComplete.bind(_),_.updateAnimationProperties=_.updateAnimationProperties.bind(_),_.surfaceRenderOrderProperty=(R=S==null?void 0:S.surfaceRenderOrder)!==null&&R!==void 0?R:_.surfaceRenderOrderProperty,_.renderLayerProperty=(M=S==null?void 0:S.renderLayer)!==null&&M!==void 0?M:_.renderLayerProperty,_.renderOrderProperty=(D=S==null?void 0:S.renderOrder)!==null&&D!==void 0?D:_.renderOrderProperty,_.renderNextToProperty=(F=S==null?void 0:S.renderNextTo)!==null&&F!==void 0?F:_.renderNextToProperty,_.accumulatedValues0=new _.webAssemblyContext.SCRTDoubleVector,_.accumulatedFinalAnimationValues0=new _.webAssemblyContext.SCRTDoubleVector,_}return Object.defineProperty(m.prototype,"isVisibleChanged",{get:function(){throw new Error("getting visibleChanged event is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"selected",{get:function(){throw new Error("getting selected event is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"hovered",{get:function(){throw new Error("getting hovered event is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isSelected",{get:function(){return!1},set:function(b){throw new Error("Setting isSelected is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isHovered",{get:function(){return!1},set:function(b){throw new Error("Setting isHovered is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isDigitalLine",{get:function(){throw new Error("Setting or getting isDigitalLine is not supported for BaseStackedCollection")},set:function(b){throw new Error("Setting or getting isDigitalLine is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(b){this.isVisibleProperty=b,this.notifyPropertyChanged(g.PROPERTY.IS_VISIBLE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"xAxisId",{get:function(){return this.xAxisIdProperty},set:function(b){b!==this.xAxisIdProperty&&(this.xAxisIdProperty=b,this.xAxisProperty=void 0,this.notifyPropertyChanged(g.PROPERTY.XAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"xAxis",{get:function(){return this.xAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"yAxis",{get:function(){return this.yAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"yAxisId",{get:function(){return this.yAxisIdProperty},set:function(b){b!==this.yAxisIdProperty&&(this.yAxisIdProperty=b,this.yAxisProperty=void 0,this.notifyPropertyChanged(g.PROPERTY.YAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"seriesName",{get:function(){var b;return(b=this.seriesNameProperty)!==null&&b!==void 0?b:this.getDataSeriesName()},set:function(b){this.seriesNameProperty!==b&&(this.seriesNameProperty=b,this.notifyPropertyChanged(g.PROPERTY.SERIES_NAME))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isOneHundredPercent",{get:function(){return this.isOneHundredPercentProperty},set:function(b){this.isOneHundredPercentProperty=b,this.notifyPropertyChanged(g.PROPERTY.IS_ONE_HUNDRED_PERCENT)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"yRangeMode",{get:function(){return this.yRangeModeProperty},set:function(b){this.yRangeModeProperty!==b&&(this.yRangeModeProperty=b,this.notifyPropertyChanged(g.PROPERTY.YRANGEMODE))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataSeries",{get:function(){throw Error("dataSeries property is not supported for BaseStackedCollection")},set:function(b){throw Error("dataSeries property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"drawNaNAs",{get:function(){throw Error("drawNaNAs property is not supported for BaseStackedCollection")},set:function(b){throw Error("drawNaNAs property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"drawingProviders",{get:function(){throw Error("drawingProviders property is not supported for BaseStackedCollection")},set:function(b){throw Error("drawingProviders property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"hitTestProvider",{get:function(){throw Error("hitTestProvider property is not supported for BaseStackedCollection, call hitTestProvider on BaseStackedRenderableSeries instead")},set:function(b){throw Error("hitTestProvider property is not supported for BaseStackedCollection, call hitTestProvider on BaseStackedRenderableSeries instead")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"paletteProvider",{get:function(){throw Error("paletteProvider property is not supported for BaseStackedCollection")},set:function(b){throw Error("paletteProvider property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"pointMarker",{get:function(){throw Error("pointMarker property is not supported for BaseStackedCollection")},set:function(b){throw Error("pointMarker property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"rolloverModifierProps",{get:function(){throw Error("rolloverModifierProps property is not supported for BaseStackedCollection")},set:function(b){throw Error("rolloverModifierProps property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"stroke",{get:function(){throw Error("stroke property is not supported for BaseStackedCollection")},set:function(b){throw Error("stroke property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeThickness",{get:function(){throw Error("strokeThickness property is not supported for BaseStackedCollection")},set:function(b){throw Error("strokeThickness property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"effect",{get:function(){throw Error("effect property is not supported for BaseStackedCollection")},set:function(b){throw Error("effect property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"opacity",{get:function(){throw Error("opacity property is not supported for BaseStackedCollection")},set:function(b){throw Error("effect property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"rolloverModifierProps1",{get:function(){throw Error("rolloverModifierProps1() method is not supported for BaseStackedCollection")},set:function(b){throw Error("rolloverModifierProps1() method is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"resamplingMode",{get:function(){throw Error("resamplingMode property is not supported for BaseStackedCollection")},set:function(b){throw Error("resamplingMode property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"resamplingPrecision",{get:function(){throw Error("resamplingPrecision property is not supported for BaseStackedCollection")},set:function(b){throw Error("resamplingPrecision property is not supported for BaseStackedCollection")},enumerable:!1,configurable:!0}),m.prototype.getSurfaceRenderOrder=function(){var b,S;return(b=this.surfaceRenderOrderProperty)!==null&&b!==void 0?b:(S=this.parentSurface)===null||S===void 0?void 0:S.getSurfaceRenderOrder()},m.prototype.setSurfaceRenderOrder=function(b){this.surfaceRenderOrderProperty!=b&&(this.surfaceRenderOrderProperty=b,this.notifyPropertyChanged(g.PROPERTY.SURFACE_RENDER_ORDER))},m.prototype.getRenderLayer=function(){if(this.renderLayerProperty===s.EDefaultRenderLayer.SeriesLayer){if(this.isSelected)return s.EDefaultRenderLayer.SelectedSeriesLayer;if(this.isHovered)return s.EDefaultRenderLayer.HoveredSeriesLayer}return this.renderLayerProperty},m.prototype.setRenderLayer=function(b){this.renderLayerProperty!=b&&(this.renderLayerProperty=b,this.notifyPropertyChanged(g.PROPERTY.RENDER_LAYER))},m.prototype.getRenderOrder=function(){return this.renderOrderProperty},m.prototype.setRenderOrder=function(b){this.renderOrderProperty!=b&&(this.renderOrderProperty=b,this.notifyPropertyChanged(g.PROPERTY.RENDER_LAYER))},m.prototype.setRenderNextTo=function(b,S){S===void 0&&(S=0),b===void 0?this.renderNextToProperty=void 0:this.renderNextToProperty={renderable:b,offset:S}},m.prototype.getRenderNextTo=function(){return this.renderNextToProperty},m.prototype.setAccumulatedValuesDirty=function(){this.isAccumulatedVectorDirty=!0},m.prototype.getIndicesRange=function(b){throw Error("getIndicesRange() method is not supported for BaseStackedCollection")},m.prototype.getDataPointWidth=function(b,S,_){throw Error("getDataPointWidth() method is not supported for BaseStackedCollection")},Object.defineProperty(m.prototype,"canDraw",{get:function(){return p.animationHelpers.checkCanDraw(this.animationFSM)},enumerable:!1,configurable:!0}),m.prototype.pushPalettedColors=function(b,S){throw new Error("Method not implemented.")},m.prototype.getSeriesInfo=function(b){throw new Error("Method not implemented.")},m.prototype.applyTheme=function(b){this.asArray().forEach(function(S){S.applyTheme(b)})},m.prototype.delete=function(){this.accumulatedValues0=(0,n.deleteSafe)(this.accumulatedValues0),this.accumulatedFinalAnimationValues0=(0,n.deleteSafe)(this.accumulatedFinalAnimationValues0),this.dataLabelProviderProperty=(0,n.deleteSafe)(this.dataLabelProvider),this.asArray().forEach(function(b){b.delete()})},m.prototype.notifyPropertyChanged=function(b){this.invalidateParent()},m.prototype.onDpiChanged=function(b){this.asArray().forEach(function(S){return S.onDpiChanged(b)})},m.prototype.getBaseXValues=function(){return[]},m.prototype.getDataSeriesName=function(){return"Stacked Collection"},m.prototype.getDataSeriesValuesCount=function(){if(this.getNativeXValues())return this.getNativeXValues().size()},Object.defineProperty(m.prototype,"isRunningDataAnimation",{get:function(){return this.isRunningAnimation&&this.animationFSM&&(this.animationFSM.animation.isDataSeriesAnimation||this.animationFSM.animation.isOnStartAnimation)},enumerable:!1,configurable:!0}),m.prototype.getNativeXValues=function(){var b;if(this.size()!==0)return(b=this.get(0).dataSeries)===null||b===void 0?void 0:b.getNativeXValues()},m.prototype.getNativeYValues=function(){throw Error("getNativeYValues() method is not supported for BaseStackedCollection")},m.prototype.getYRange=function(b,S){var _=this;if(!this.isEnoughDataToDraw())return new o.NumberRange;this.updateAccumulatedVectors();var C;return this.getVisibleSeries().forEach(function(P){if(P.accumulatedValues.size()===_.getNativeXValues().size()){var x=(0,h.getWindowedYRange)(_.webAssemblyContext,_.getNativeXValues(),P.getAccumulatedValues(_.isRunningDataAnimation),b,!0,S,P.dataSeries.dataDistributionCalculator.isSortedAscending,!0,_.yRangeMode===u.EYRangeMode.Visible?l.ESearchMode.RoundUp:l.ESearchMode.RoundDown,_.yRangeMode===u.EYRangeMode.Visible?l.ESearchMode.RoundDown:l.ESearchMode.RoundUp);x&&(C=C?C.union(x):x)}}),C||new o.NumberRange},m.prototype.hasDataSeries=function(){return!!this.getNativeXValues()},m.prototype.hasStrokePaletteProvider=function(){return!1},m.prototype.hasFillPaletteProvider=function(){return!1},m.prototype.hasPointMarkerPaletteProvider=function(){return!1},m.prototype.onAttach=function(b){if(this.parentSurface=b,this.linkAxes(),this.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachSeries, this series has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.invalidateParentCallback=b.invalidateElement},m.prototype.onDetach=function(){this.invalidateParentCallback=void 0,this.parentSurface=void 0},m.prototype.getVisibleSeries=function(){return this.asArray().filter(function(b){return b.isVisible})},m.prototype.enqueueAnimation=function(b){this.animationQueue.push(b),this.invalidateParent()},m.prototype.runAnimation=function(b){this.animationQueue=[],this.animationFSM.toCompleted(),this.afterAnimationComplete()},Object.defineProperty(m.prototype,"animation",{set:function(b){b&&this.animationQueue.push(b),this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isRunningAnimation",{get:function(){return!!(p.animationHelpers.checkIsAnimationRunning(this.animationQueue,this.animationFSM)||this.getVisibleSeries().some(function(b){return b.isRunningAnimation}))},enumerable:!1,configurable:!0}),m.prototype.onAnimate=function(b){var S;if(!this.animationFSM||!((S=this.animationFSM)===null||S===void 0)&&S.is([e.EAnimationState.Completed]))if(this.animationQueue.length>=1){var _=this.animationQueue.shift();this.animationFSM=new e.SeriesAnimationFiniteStateMachine(_,void 0)}else this.animationFSM=void 0;this.getVisibleSeries().forEach(function(C){C.isRunningAnimation&&C.onAnimate(b)}),this.animationFSM&&p.animationHelpers.animationUpdate(this.animationFSM,b,this.beforeAnimationStart,this.afterAnimationComplete,this.updateAnimationProperties)},m.prototype.checkIsOutOfDataRange=function(b,S){throw Error("checkIsOutOfDataRange() method is not supported for BaseStackedCollection")},m.prototype.toPointSeries=function(b){},m.prototype.getCurrentRenderPassData=function(){return this.currentRenderPassData},m.prototype.setCurrentRenderPassData=function(b){this.currentRenderPassData=b},m.prototype.getResamplingParams=function(){},Object.defineProperty(m.prototype,"dataLabelProvider",{get:function(){return this.dataLabelProviderProperty},set:function(b){this.dataLabelProviderProperty=b,b.onAttach(this.webAssemblyContext,this),this.notifyPropertyChanged(g.PROPERTY.SERIES_TEXT_PROVIDER)},enumerable:!1,configurable:!0}),m.prototype.toJSON=function(b){var S;b===void 0&&(b=!1);for(var _=[],C=0,P=this.asArray();C<P.length;C++){var x=P[C];_.push(x.toJSON(b))}var E=this.getRenderNextTo(),A=E&&{renderable:typeof E.renderable=="string"?E.renderable:E.renderable.id,offset:E.offset},R={isVisible:this.isVisible,isOneHundredPercent:this.isOneHundredPercent,xAxisId:this.xAxisId,yAxisId:this.yAxisId,yRangeMode:this.yRangeMode,dataLabelProvider:(S=this.dataLabelProvider)===null||S===void 0?void 0:S.toJSON(),surfaceRenderOrder:this.surfaceRenderOrderProperty,renderLayer:this.getRenderLayer(),renderOrder:this.getRenderOrder(),renderNextTo:A};return{type:this.type,series:_,options:R}},m.prototype.resolveAutoColors=function(b,S,_){throw Error("resolveAutoColors method is not supported for BaseStackedCollection.  Call on collection items individually")},m.prototype.adjustAutoColor=function(b,S){return S},m.prototype.linkAxes=function(){if((0,r.updateAxisIds)(this),!!this.parentSurface){if(!this.xAxisProperty&&this.xAxisId){var b=this.parentSurface.getXAxisById(this.xAxisId);b?this.xAxisProperty=b:(console.warn('StackedCollection looked for xAxis Id "'.concat(this.xAxisId,'" but did not find. Default xAxis will be used')),this.xAxisProperty=this.parentSurface.getDefaultXAxis())}if(!this.yAxisProperty&&this.yAxisId){var S=this.parentSurface.getYAxisById(this.yAxisId);S?this.yAxisProperty=S:(console.warn('StackedCollection looked for yAxis Id "'.concat(this.yAxisId,'" but did not find. Default yAxis will be used')),this.yAxisProperty=this.parentSurface.getDefaultYAxis())}}},m.prototype.isAllDataSeriesSet=function(){var b=!0;return this.asArray().forEach(function(S){S.dataSeries||(b=!1)}),b},m.prototype.invalidateParent=function(){this.invalidateParentCallback&&this.invalidateParentCallback()},m.prototype.getFirstSeries=function(){if(this.size()!==0)return this.get(0)},m.prototype.getParentSurface=function(){return this.parentSurface},m.prototype.beforeAnimationStart=function(){this.updateAccumulatedVectors(),(0,c.copyDoubleVector)(this.accumulatedValues0,this.accumulatedFinalAnimationValues0,this.webAssemblyContext),this.getVisibleSeries().forEach(function(b){b.beforeAnimationStart()})},m.prototype.afterAnimationComplete=function(){this.getVisibleSeries().forEach(function(b){b.afterAnimationComplete()})},m.prototype.updateAnimationProperties=function(b,S){this.isAllDataSeriesSet()&&(S.animation.calculateAnimationValues(this.webAssemblyContext,this.accumulatedFinalAnimationValues0,this.accumulatedValues0,b),this.getVisibleSeries().forEach(function(_){_.updateAnimationProperties(b,S)})),this.invalidateParentCallback&&this.invalidateParentCallback()},m.prototype.updateHitTestProviders=function(b){this.getVisibleSeries().forEach(function(S){var _;(_=S.hitTestProvider)===null||_===void 0||_.update(b)})},m.prototype.isEnoughDataToDraw=function(){var b=this.getVisibleSeries().length;if(b<1)return!1;for(var S=0;S<b;S++)if(!this.get(S).dataSeries)return!1;for(var S=0;S<b;S++)if(this.get(S).dataSeries.count()===0)return!1;return!0},m})(a.ObservableArray);return b1.BaseStackedCollection=v,b1}var S1={},_1={},Lve;function LI(){if(Lve)return _1;Lve=1;var t=_1&&_1.__assign||function(){return t=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},t.apply(this,arguments)};Object.defineProperty(_1,"__esModule",{value:!0}),_1.BaseDataLabelProvider=void 0;var e=ci(),i=Tc(),n=Ti(),r=Xs(),o=an(),a=Zi(),s=(function(){function l(u){var c=this,d;this.dataLabels=[],this.drawImmediate=!1,this.getstyleProxy=function(f){return new Proxy(f,{set:function(h,p,g){return h[p]=g,c.invalidateParent(),!0}})},this.styleProperty=t({fontFamily:"Default"},u==null?void 0:u.style),this.colorProperty=u==null?void 0:u.color,this.drawImmediate=(d=u==null?void 0:u.drawImmediate)!==null&&d!==void 0?d:this.drawImmediate}return Object.defineProperty(l.prototype,"useRotation",{get:function(){return!1},enumerable:!1,configurable:!0}),l.prototype.onAttach=function(u,c){e.Guard.notNull(u,"webAssemblyContext"),e.Guard.notNull(c,"parentSeries"),this.webAssemblyContext=u,this.parentSeries=c},l.prototype.onDetach=function(){this.webAssemblyContext=void 0,this.parentSeries=void 0},l.prototype.delete=function(){},Object.defineProperty(l.prototype,"style",{get:function(){return this.styleProperty},set:function(u){this.styleProperty=this.getstyleProxy(u),this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"color",{get:function(){var u,c,d;return this.colorProperty?(0,r.stripAutoColor)(this.colorProperty):(d=(c=(u=this.parentSeries)===null||u===void 0?void 0:u.parentSurface)===null||c===void 0?void 0:c.themeProvider)===null||d===void 0?void 0:d.tickTextBrush},set:function(u){this.colorProperty=u,this.invalidateParent()},enumerable:!1,configurable:!0}),l.prototype.updateStyle=function(u){this.styleProperty=this.getstyleProxy(t(t({},this.styleProperty),u)),this.invalidateParent()},l.prototype.generateDataLabels=function(u,c){},l.prototype.draw=function(u){var c,d;if(!(!this.dataLabels||this.dataLabels.length===0)&&!(!this.style||!this.style.fontFamily||!this.style.fontSize)){for(var f=(0,n.parseColorToUIntArgb)(this.color),h=a.DpiHelper.adjustTextStyle(this.style),p=u.getFont(h,this.useRotation),g=(0,i.convertMultiLineAlignment)(this.style.multiLineAlignment,this.webAssemblyContext),v=0,y=this.dataLabels;v<y.length;v++){var m=y[v],b=this.parentSeries.parentSurface.seriesViewRect,S=b.left,_=b.top,C=(0,o.getVector4)(this.webAssemblyContext,m.rotationCenter.x+S,m.rotationCenter.y+_,m.rotationAngle,0);p.DrawStringAdvanced((c=m.text)!==null&&c!==void 0?c:"",(d=m.color)!==null&&d!==void 0?d:f,Math.round(S+m.position.x),Math.round(_+m.position.y),C,g,this.getLineSpacing())}this.drawImmediate&&p.End(),this.dataLabels=[]}},l.prototype.resolveAutoColors=function(u,c,d){if(this.colorProperty&&this.colorProperty.startsWith(r.AUTO_COLOR)){var f=d.getStrokeColor(u,c,this.webAssemblyContext);this.color=r.AUTO_COLOR+f}},l.prototype.toJSON=function(){return{type:this.type,options:{style:this.style,color:this.color}}},l.prototype.invalidateParent=function(){var u;!((u=this.parentSeries)===null||u===void 0)&&u.invalidateParentCallback&&this.parentSeries.invalidateParentCallback()},l.prototype.getLineSpacing=function(){var u,c;return(c=(u=this.style)===null||u===void 0?void 0:u.lineSpacing)!==null&&c!==void 0?c:3},l})();return _1.BaseDataLabelProvider=s,_1}var kve;function IFe(){if(kve)return S1;kve=1;var t=S1&&S1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(S1,"__esModule",{value:!0}),S1.StackedCollectionDataLabelProvider=void 0;var e=LI(),i=(function(n){t(r,n);function r(){return n.call(this)||this}return r.prototype.generateDataLabels=function(o,a){},r.prototype.draw=function(o){for(var a=0,s=this.parentSeries.asArray();a<s.length;a++){var l=s[a];l.isVisible&&l.dataLabelProvider.draw(o)}},r})(e.BaseDataLabelProvider);return S1.StackedCollectionDataLabelProvider=i,S1}var dp={},Ive;function bo(){if(Ive)return dp;Ive=1,Object.defineProperty(dp,"__esModule",{value:!0}),dp.vectorToArrayViewI32=dp.vectorToArrayViewUi32=dp.vectorToArrayViewF32=dp.vectorToArrayViewF64=dp.vectorToArray=void 0;function t(o,a){var s;return a.UIntVector&&o instanceof a.UIntVector||a.SCRTUintVector&&o instanceof a.SCRTUintVector?s=n(o,a):a.IntVector&&o instanceof a.IntVector?s=r(o,a):a.FloatVector&&o instanceof a.FloatVector||a.SCRTFloatVector&&o instanceof a.SCRTFloatVector?s=i(o,a):s=e(o,a),Array.from(s)}dp.vectorToArray=t;function e(o,a){if(o){var s=o.dataPtrZero?o.dataPtrZero():o.dataPtr(0),l=o.size();return new Float64Array(a.HEAPF64.buffer,s,l)}}dp.vectorToArrayViewF64=e;function i(o,a){var s=o.dataPtr(0),l=o.size();return new Float32Array(a.HEAPF32.buffer,s,l)}dp.vectorToArrayViewF32=i;function n(o,a){var s=o.dataPtr(0),l=o.size();return new Uint32Array(a.HEAPU32.buffer,s,l)}dp.vectorToArrayViewUi32=n;function r(o,a){var s=o.dataPtr(0),l=o.size();return new Int32Array(a.HEAP32.buffer,s,l)}return dp.vectorToArrayViewI32=r,dp}var P1={},Nve;function KV(){if(Nve)return P1;Nve=1;var t=P1&&P1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(P1,"__esModule",{value:!0}),P1.XyyPointSeriesWrapped=void 0;var e=Yo(),i=zi(),n=wm(),r=(function(o){t(a,o);function a(s,l,u){var c=o.call(this,s,[l,u],i.EDataSeriesValueType.Default,[e.EValueName.Y,e.EValueName.Y1])||this;return c.type=i.EDataSeriesType.Xyy,c}return Object.defineProperty(a.prototype,"y1Values",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),a.prototype.getYValues=function(s){return s===1?this.y1Values:this.yValues},a})(n.BasePointSeriesWrapped);return P1.XyyPointSeriesWrapped=r,P1}var V0={},C1={},mF={},Fve;function Hre(){if(Fve)return mF;Fve=1,Object.defineProperty(mF,"__esModule",{value:!0}),mF.createSolidBrush=void 0;var t=Uo(),e=Ju(),i=Ti(),n=function(r,o,a){if(!(t.IS_TEST_ENV||!o)){var s=(0,e.uintArgbColorMultiplyOpacity)((0,i.parseColorToUIntArgb)(o),a),l=(0,e.uintArgbColorIsTransparent)(s);if(isNaN(s))throw new Error("Color code ".concat(o," cannot be converted to an ARGB integer"));return new r.SCRTSolidBrush(s,l)}};return mF.createSolidBrush=n,mF}var T1={},Bve;function NFe(){if(Bve)return T1;Bve=1;var t=T1&&T1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(T1,"__esModule",{value:!0}),T1.WebGlBrush=void 0;var e=fo(),i=Br(),n=lFe(),r=(function(o){t(a,o);function a(s){var l=o.call(this)||this;return l.scrtBrushProperty=s,l}return Object.defineProperty(a.prototype,"scrtBrush",{get:function(){return this.scrtBrushProperty},enumerable:!1,configurable:!0}),a.prototype.delete=function(){this.scrtBrushProperty=(0,i.deleteSafe)(this.scrtBrushProperty)},a.prototype.getBrushType=function(){return n.EDrawingTypes.WasmBrush},a.prototype.setOpacity=function(s){var l;(l=this.scrtBrushProperty)===null||l===void 0||l.SetOpacity(s)},a})(e.DeletableEntity);return T1.WebGlBrush=r,T1}var jve;function tu(){return jve||(jve=1,(function(t){var e=C1&&C1.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})(),i=C1&&C1.__assign||function(){return i=Object.assign||function(g){for(var v,y=1,m=arguments.length;y<m;y++){v=arguments[y];for(var b in v)Object.prototype.hasOwnProperty.call(v,b)&&(g[b]=v[b])}return g},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.createBrushInCache=t.getScrtBrushFromCache=t.getWebGlBrushFromCache=t.BrushCache=void 0;var n=Br(),r=ci(),o=Hre(),a=rR(),s=dW(),l=NFe(),u=256,c=(function(g){e(v,g);function v(){return g!==null&&g.apply(this,arguments)||this}return Object.defineProperty(v.prototype,"value",{get:function(){return!this.cachedEntity&&(this.fill||this.fillLinearGradient||this.customTextureOptions)&&(this.cachedEntity=this.create(this.fill,this.opacity,this.textureHeightRatio,this.textureWidthRatio,this.fillLinearGradient,this.customTextureOptions)),this.cachedEntity},enumerable:!1,configurable:!0}),v.prototype.defaultCustomEquals=function(y,m){return y===m},v.prototype.create=function(y,m,b,S,_,C){var P,x,E,A;b=(P=C==null?void 0:C.textureHeight)!==null&&P!==void 0?P:b,S=(x=C==null?void 0:C.textureWidth)!==null&&x!==void 0?x:S;var R=(E=C==null?void 0:C.areEqual)!==null&&E!==void 0?E:this.defaultCustomEquals;if(this.cachedEntity&&y===this.fill&&m===this.opacity&&b===this.textureHeightRatio&&S===this.textureWidthRatio&&_===this.fillLinearGradient&&C===this.customTextureOptions&&R((A=this.customTextureOptions)===null||A===void 0?void 0:A.options,C==null?void 0:C.options))return this.cachedEntity;this.invalidateCache(),this.fill=y,this.opacity=m,this.textureHeightRatio=b,this.textureWidthRatio=S,this.fillLinearGradient=_,this.customTextureOptions=C;var M;return C?M=this.createCustomBrush():_?M=this.createGradientBrush():M=this.createSolidBrush(y,m),this.cachedEntity=new l.WebGlBrush(M)},v.prototype.createCustomBrush=function(){var y;this.canvasTexture=new a.CanvasTexture(this.webAssemblyContext,this.textureWidthRatio,this.textureHeightRatio),this.canvasTexture.clear();var m=this.canvasTexture.getContext();this.customTextureOptions.createTexture(m,i({fill:this.fill,opacity:this.opacity},this.customTextureOptions.options)),this.canvasTexture.copyTexture();var b=this.canvasTexture.getTexture(),S=new this.webAssemblyContext.SCRTTextureBrush(b,(y=this.customTextureOptions.isPerPrimitive)!==null&&y!==void 0&&y?this.webAssemblyContext.eSCRTBrushMappingMode.PerPrimitive:this.webAssemblyContext.eSCRTBrushMappingMode.PerScreen,1);return this.customTextureOptions.repeat&&(S.SetSamplerMode(this.webAssemblyContext.SCRTTextureBrushSamplerMode.Wrap),S.SetMappingMode(this.webAssemblyContext.eSCRTBrushMappingMode.PerScreen)),S},v.prototype.invalidateCache=function(){g.prototype.invalidateCache.call(this),this.canvasTexture=(0,n.deleteSafe)(this.canvasTexture)},v.prototype.reset=function(){this.invalidateCache(),this.fill=void 0,this.opacity=void 0,this.fillLinearGradient=void 0},v.prototype.delete=function(){this.invalidateCache()},v.prototype.createSolidBrush=function(y,m){return(0,o.createSolidBrush)(this.webAssemblyContext,y,m)},v.prototype.createGradientBrush=function(){var y=this.createGradientTexture().getTexture();return new this.webAssemblyContext.SCRTTextureBrush(y,this.webAssemblyContext.eSCRTBrushMappingMode.PerPrimitive,1)},v.prototype.createGradientTexture=function(){r.Guard.notNull(this.fillLinearGradient,"fillLinearGradient");var y=this.fillLinearGradient,m=y.startPoint,b=y.endPoint,S=y.gradientStops;this.canvasTexture=new a.CanvasTexture(this.webAssemblyContext,u,u),this.canvasTexture.clear();var _=this.canvasTexture.getContext(),C=p(m.x,u*this.textureWidthRatio),P=p(m.y,u*this.textureHeightRatio),x=p(b.x,u*this.textureWidthRatio),E=p(b.y,u*this.textureHeightRatio),A=_.createLinearGradient(C,P,x,E);return S.forEach(function(R){A.addColorStop(R.offset,R.color)}),_.fillStyle=A,_.fillRect(0,0,u,u),this.canvasTexture.copyTexture(),this.canvasTexture},v})(s.BaseCache);t.BrushCache=c;var d=function(g){return r.Guard.notNull(g,"cache"),g.value};t.getWebGlBrushFromCache=d;var f=function(g){var v=(0,t.getWebGlBrushFromCache)(g);return v==null?void 0:v.scrtBrush};t.getScrtBrushFromCache=f;var h=function(g,v,y,m,b,S,_){r.Guard.notNull(g,"brushCache");var C=g.create(v,y,m,b,S,_);return C.scrtBrush};t.createBrushInCache=h;var p=function(g,v){return g*v}})(C1)),C1}var x1={},E1={},Vve;function Kwt(){if(Vve)return E1;Vve=1;var t=E1&&E1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(E1,"__esModule",{value:!0}),E1.PaletteCache=void 0;var e=Br(),i=dW(),n=(function(r){t(o,r);function o(){return r!==null&&r.apply(this,arguments)||this}return Object.defineProperty(o.prototype,"value",{get:function(){return!this.cachedEntity&&this.fillColors&&(this.cachedEntity=this.create(this.fillColors)),this.cachedEntity},enumerable:!1,configurable:!0}),o.prototype.create=function(a){return this.cachedEntity&&a===this.fillColors?this.cachedEntity:((0,e.deleteSafe)(this.cachedEntity),this.fillColors=a,this.cachedEntity=new this.webAssemblyContext.SCRTCreatePalette(a))},o.prototype.reset=function(){this.invalidateCache(),this.fillColors=void 0},o})(i.BaseCache);return E1.PaletteCache=n,E1}var Hve;function du(){if(Hve)return x1;Hve=1;var t=x1&&x1.__extends||(function(){var v=function(y,m){return v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,S){b.__proto__=S}||function(b,S){for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(b[_]=S[_])},v(y,m)};return function(y,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");v(y,m);function b(){this.constructor=y}y.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}})();Object.defineProperty(x1,"__esModule",{value:!0}),x1.BaseSeriesDrawingProvider=void 0;var e=Uo(),i=fo(),n=Br(),r=ci(),o=Yo(),a=Ju(),s=Du(),l=Ti(),u=La(),c=bo(),d=Kwt(),f=vS(),h=Hre(),p=un(),g=(function(v){t(y,v);function y(m,b,S,_){var C=this,P;return C=v.call(this)||this,r.Guard.notNull(m,"webAssemblyContext"),r.Guard.notNull(b,"parentSeries"),C.webAssemblyContext=m,C.parentSeries=b,_&&(C.xSelector=_),S&&(C.ySelector=S),C.palettingState={palettedColors:void 0,palettedColorsHashCode:0,gradientPaletting:!1,paletteTextureCache:new d.PaletteCache(m),requiresUpdate:!0},C.seriesHasDataChanges=C.seriesHasDataChanges.bind(C),C.parentDataSeries=C.parentSeries.dataSeries,(P=C.parentDataSeries)===null||P===void 0||P.dataChanged.subscribe(C.seriesHasDataChanges),C}return y.prototype.xSelector=function(m){return m.xValues},y.prototype.ySelector=function(m){var b=this.parentSeries.yArrayFilter;return b?typeof b=="number"?m.getYValues(b,!1):m.getYValuesByName(b,!1):m.yValues},y.prototype.getStartAndCount=function(m,b){var S,_,C,P=m==null?void 0:m.pointSeries,x=(S=this.parentSeries)===null||S===void 0?void 0:S.xAxis,E=(_=x==null?void 0:x.clipToXRange)!==null&&_!==void 0?_:!0,A=b.size(),R=Math.min(P?P.xValues.size():A,A),M=0;return E&&!(P!=null&&P.resampled)&&((C=m==null?void 0:m.indexRange)===null||C===void 0?void 0:C.diff)>=0&&(m.indexRange.diff+1<R&&(M=m.indexRange.min),R=Math.min(m.indexRange.diff+1,R)),{startIndex:M,count:R}},y.prototype.applyStrokePaletting=function(m,b){var S,_,C,P,x,E,A,R=u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.PaletteProviderStart,{contextId:this.parentSeries.id,parentContextId:(S=this.parentSeries.parentSurface)===null||S===void 0?void 0:S.id,level:u.EPerformanceDebugLevel.Verbose}),M=this.parentSeries.paletteProvider;if(this.parentSeries.hasStrokePaletteProvider()||M.applyPaletting!==void 0){var D=(0,a.uintArgbColorMultiplyOpacity)((0,l.parseColorToUIntArgb)(this.parentSeries.stroke),this.parentSeries.opacity);if(isNaN(D))throw Error("applyStrokePaletting(): renderSeries.stroke "+this.parentSeries.stroke+" cannot be converted to a valid color");var F=this.parentSeries.paletteProvider,I=this.parentSeries.dataSeries;b=b??this.parentSeries.getCurrentRenderPassData();var V=b==null?void 0:b.pointSeries,z=(_=V?this.xSelector(V):void 0)!==null&&_!==void 0?_:I.getNativeXValues(),G=(C=V?this.ySelector(V):void 0)!==null&&C!==void 0?C:I.getNativeYValues(),H=this.getStartAndCount(b,z),U=H.startIndex,k=H.count;this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector),this.palettingState.originalPenColor=m.m_uiColor,m.m_uiColor=e.NEUTRAL_COLOR,m.m_bGradient=F.strokePaletteMode===f.EStrokePaletteMode.GRADIENT;for(var X=new Map,W=0,Y=I.valueNames;W<Y.length;W++){var te=Y[W];te!==o.EValueName.Y&&X.set(te,(0,c.vectorToArrayViewF64)(I.getYValuesByName(te),this.webAssemblyContext))}if(M.applyPaletting){M.applyPaletting(this.palettingState,z,G,(P=V==null?void 0:V.indexes)!==null&&P!==void 0?P:I.getNativeIndexes(),U,k,X);return}if(this.shouldUpdatePalette(b,F,U,k,!1),!this.palettingState.requiresUpdate)return;this.palettingState.palettedColors.resize(k,0);for(var oe=I.count(),de=V&&V.indexes.size()>0,ge=(0,c.vectorToArrayViewF64)(V==null?void 0:V.indexes,this.webAssemblyContext),Ee=(0,c.vectorToArrayViewF64)(z,this.webAssemblyContext),Re=(0,c.vectorToArrayViewF64)(G,this.webAssemblyContext),Ae=(0,c.vectorToArrayViewUi32)(this.palettingState.palettedColors,this.webAssemblyContext),Pe=0,we=U;we<U+k;we++){var Te=de?ge[we]:we;Te<0?Te=0:Te>=oe&&(Te=oe-1);var ke=Ee[we],$e=G?Re[we]:void 0,Ne=F.overrideStrokeArgb(ke,$e,Te,this.parentSeries.opacity,I.getMetadataAt(Te),X);Ae[Pe]=Ne||D,Pe++}this.palettingState.requiresUpdate=!1}else this.palettingState.originalPenColor&&(m.m_uiColor=this.palettingState.originalPenColor,this.palettingState.originalPenColor=void 0),(x=this.palettingState.palettedColors)===null||x===void 0||x.clear();this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector),u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.PaletteProviderEnd,{contextId:this.parentSeries.id,parentContextId:(E=this.parentSeries.parentSurface)===null||E===void 0?void 0:E.id,relatedId:(A=R==null?void 0:R.detail)===null||A===void 0?void 0:A.relatedId,level:u.EPerformanceDebugLevel.Verbose})},y.prototype.applyStrokeFillPaletting=function(m,b,S,_,C,P,x,E){var A,R,M,D,F,I,V,z,G;P===void 0&&(P=!1),x===void 0&&(x=!0);var H=u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.PaletteProviderStart,{contextId:this.parentSeries.id,parentContextId:(A=this.parentSeries.parentSurface)===null||A===void 0?void 0:A.id,level:u.EPerformanceDebugLevel.Verbose}),U=this.parentSeries.hasStrokePaletteProvider(),k=this.parentSeries.hasFillPaletteProvider(),X=this.parentSeries.hasPointMarkerPaletteProvider(),W=this.parentSeries.paletteProvider,Y=this.parentSeries.paletteProvider,te=(Y==null?void 0:Y.applyPaletting)!==void 0;if(U||k||X||te){var oe=void 0,de=void 0;if(P)oe=de=this.webAssemblyContext.SCRTPalette.GetNoOverrideColorCode();else{var ge=C!==void 0;oe=m&&ge?(0,a.uintArgbColorMultiplyOpacity)((0,l.parseColorToUIntArgb)(m),C):e.NEUTRAL_COLOR,de=S&&ge?(0,a.uintArgbColorMultiplyOpacity)((0,l.parseColorToUIntArgb)(S),C):e.NEUTRAL_COLOR}if(isNaN(oe))throw Error("updatePalette(): parentSeries.stroke "+m+" cannot be converted to a valid color");if(isNaN(de))throw Error("updatePalette(): fillColor "+de+" cannot be converted to a valid color");var Ee=this.parentSeries.dataSeries;E=E??this.parentSeries.getCurrentRenderPassData();var Re=E==null?void 0:E.pointSeries,Ae=(R=Re?this.xSelector(Re):void 0)!==null&&R!==void 0?R:Ee.getNativeXValues(),Pe=(M=Re?this.ySelector(Re):void 0)!==null&&M!==void 0?M:Ee.getNativeYValues(),we=this.getStartAndCount(E,Ae),Te=we.startIndex,ke=we.count;this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector);for(var $e=new Map,Ne=0,ve=Ee.valueNames;Ne<ve.length;Ne++){var pe=ve[Ne];pe!==o.EValueName.Y&&$e.set(pe,(0,c.vectorToArrayViewF64)(Ee.getYValuesByName(pe),this.webAssemblyContext))}if(Y.applyPaletting){Y.applyPaletting(this.palettingState,Ae,Pe,(D=Re==null?void 0:Re.indexes)!==null&&D!==void 0?D:Ee.getNativeIndexes(),Te,ke,$e);return}if(this.shouldUpdatePalette(E,W,Te,ke,!0),!this.palettingState.requiresUpdate)return;this.palettingState.paletteTextureCache.reset(),this.palettingState.palettedColors.resize(ke*2,0),x&&(b&&U&&(this.palettingState.originalPenColor=b.m_uiColor,b.m_uiColor=e.NEUTRAL_COLOR,this.palettingState.originalPenGradient=b.m_bGradient,b.m_bGradient=W.strokePaletteMode===f.EStrokePaletteMode.GRADIENT),_&&(this.palettingState.originalBrushColor=_.GetColor(),_.SetColor(e.NEUTRAL_COLOR)));for(var fe=0,me=Re&&Re.indexes.size()>0,Ce=(0,c.vectorToArrayViewF64)(Re==null?void 0:Re.indexes,this.webAssemblyContext),Ue=(0,c.vectorToArrayViewF64)(Ae,this.webAssemblyContext),Qe=(0,c.vectorToArrayViewF64)(Pe,this.webAssemblyContext),it=(0,c.vectorToArrayViewUi32)(this.palettingState.palettedColors,this.webAssemblyContext),xt=0,wt=Ee.count(),$t=Te;$t<Te+ke;$t++){var Mt=me?Ce[$t]:$t;Mt<0?Mt=0:Mt>=wt&&(Mt=wt-1);var rt=Ue[$t],qe=Pe?Qe[$t]:void 0,vt=this.overridePaletteProviderColors(this.parentSeries,rt,qe,Mt,C,Ee.getMetadataAt(Mt),$e),kt=(F=vt.stroke)!==null&&F!==void 0?F:oe,Xe=(I=vt.fill)!==null&&I!==void 0?I:de;it[xt]=kt,xt++,it[xt]=Xe,xt++,P&&(fe=(0,s.numericHashCode)(fe,kt),fe=(0,s.numericHashCode)(fe,Xe))}P&&(this.palettingState.palettedColorsHashCode!==fe&&this.palettingState.paletteTextureCache.reset(),this.palettingState.paletteTextureCache.create(this.palettingState.palettedColors),this.palettingState.palettedColorsHashCode=fe),this.palettingState.requiresUpdate=!1}else this.palettingState.paletteTextureCache.reset(),(V=this.palettingState.palettedColors)===null||V===void 0||V.clear(),b&&(this.palettingState.originalPenColor&&(b.m_uiColor=this.palettingState.originalPenColor,this.palettingState.originalPenColor=void 0),this.palettingState.originalPenGradient&&(b.m_bGradient=this.palettingState.originalPenGradient,this.palettingState.originalPenGradient=void 0)),_&&this.palettingState.originalBrushColor&&(_.SetColor(this.palettingState.originalBrushColor),this.palettingState.originalBrushColor=void 0);this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector),this.palettingState.gradientPaletting=this.isGradientFillPaletting(this.parentSeries),u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.PaletteProviderEnd,{contextId:this.parentSeries.id,parentContextId:(z=this.parentSeries.parentSurface)===null||z===void 0?void 0:z.id,relatedId:(G=H==null?void 0:H.detail)===null||G===void 0?void 0:G.relatedId,level:u.EPerformanceDebugLevel.Verbose})},y.prototype.createSolidBrush=function(m,b){return(0,h.createSolidBrush)(this.webAssemblyContext,m,b)},y.prototype.delete=function(){var m;this.palettingState.palettedColors&&(this.palettingState.palettedColors=(0,n.deleteSafe)(this.palettingState.palettedColors)),this.palettingState.paletteTextureCache=(0,n.deleteSafe)(this.palettingState.paletteTextureCache),this.parentDataSeries=this.parentSeries.dataSeries,(m=this.parentDataSeries)===null||m===void 0||m.dataChanged.unsubscribe(this.seriesHasDataChanges)},y.prototype.onSeriesPropertyChange=function(m){var b,S;m===p.PROPERTY.DATA_SERIES&&((b=this.parentDataSeries)===null||b===void 0||b.dataChanged.unsubscribe(this.seriesHasDataChanges),this.parentDataSeries=this.parentSeries.dataSeries,(S=this.parentDataSeries)===null||S===void 0||S.dataChanged.subscribe(this.seriesHasDataChanges),this.palettingState.requiresUpdate=!0)},y.prototype.onDpiChanged=function(m){},y.prototype.onAttachSeries=function(){},y.prototype.onDetachSeries=function(){},y.prototype.updateArgs=function(m){},y.prototype.seriesHasDataChanges=function(){this.palettingState.requiresUpdate=!0},y.prototype.shouldUpdatePalette=function(m,b,S,_,C){var P,x,E,A,R,M;!((P=m==null?void 0:m.pointSeries)===null||P===void 0)&&P.resampled&&(m==null?void 0:m.resamplingHash)!==this.palettingState.lastResamplingHash&&(this.palettingState.lastResamplingHash=m==null?void 0:m.resamplingHash,this.palettingState.requiresUpdate=!0),(x=b.isRangeIndependant)!==null&&x!==void 0&&x?((R=this.palettingState.lastStartIndex)!==null&&R!==void 0?R:Number.MAX_SAFE_INTEGER)>S||((M=this.palettingState.lastCount)!==null&&M!==void 0?M:0)<_||S+_>this.palettingState.lastStartIndex+this.palettingState.lastCount?(this.palettingState.lastStartIndex=S,this.palettingState.lastCount=_,this.palettingState.requiresUpdate=!0,this.palettingState.paletteStartIndex=0):this.palettingState.paletteStartIndex=S*(C?2:1)-this.palettingState.lastStartIndex:(((E=this.palettingState.lastStartIndex)!==null&&E!==void 0?E:0)!==S||((A=this.palettingState.lastCount)!==null&&A!==void 0?A:0)!==_)&&(this.palettingState.lastStartIndex=S,this.palettingState.lastCount=_,this.palettingState.requiresUpdate=!0,this.palettingState.paletteStartIndex=0),(!b.shouldUpdatePalette||b.shouldUpdatePalette())&&(this.palettingState.requiresUpdate=!0)},y.prototype.overridePaletteProviderColors=function(m,b,S,_,C,P,x){var E,A;if(m.hasStrokePaletteProvider()){var R=m.paletteProvider;E=R.overrideStrokeArgb(b,S,_,C,P,x)}if(m.hasFillPaletteProvider()){var M=m.paletteProvider;A=M.overrideFillArgb(b,S,_,C,P,x)}return{stroke:E,fill:A}},y.prototype.isGradientFillPaletting=function(m){if(m.hasFillPaletteProvider()){var b=m.paletteProvider;return b.fillPaletteMode===f.EFillPaletteMode.GRADIENT}return!1},y})(i.DeletableEntity);return x1.BaseSeriesDrawingProvider=g,x1}var Uve;function Kz(){if(Uve)return V0;Uve=1;var t=V0&&V0.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(V0,"__esModule",{value:!0}),V0.StackedColumnSeriesDrawingProvider=V0.StackedColumnRenderPassData=void 0;var e=Br(),i=tu(),n=Ls(),r=QP(),o=Sn(),a=un(),s=du(),l=(function(c){t(d,c);function d(f,h,p,g,v,y,m,b,S,_){var C=c.call(this,f,h,p,g,S,_)||this;return C.columnWidth=v,C.stackedGroupCount=y,C.groupIndex=m,C.spacing=b,C}return d})(r.RenderPassData);V0.StackedColumnRenderPassData=l;var u=(function(c){t(d,c);function d(f,h,p,g){var v=c.call(this,f,h,p,g)||this;return v.nativeDrawingProvider=new f.SCRTStackedColumnSeriesDrawingProvider,v.args=new v.webAssemblyContext.SCRTStackedColumnDrawingParams,v.strokePenCache=new n.Pen2DCache(f),v.strokePenFillColoredCache=new n.Pen2DCache(f),v.fillBrushCache=new i.BrushCache(f),v}return d.prototype.onAttachSeries=function(){c.prototype.onAttachSeries.call(this);var f=this.getProperties(this.parentSeries),h=f.stroke,p=f.strokeThickness,g=f.fill,v=f.opacity;(0,n.createPenInCache)(this.strokePenCache,h,p,v),p===0&&(0,n.createPenInCache)(this.strokePenFillColoredCache,g,1,v),this.createBrush()},d.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.strokePenFillColoredCache=(0,e.deleteSafe)(this.strokePenFillColoredCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),c.prototype.delete.call(this)},d.prototype.getProperties=function(f){var h=f.stroke,p=f.strokeThickness,g=f.opacity,v=f.fill,y=f.fillLinearGradient,m=f.customTextureOptions;return{stroke:h,strokeThickness:p,opacity:g,fill:v,fillLinearGradient:y,customTextureOptions:m}},d.prototype.draw=function(f,h){var p=h.pointSeries,g=this.parentSeries.parentSurface.seriesViewRect,v=this.getProperties(this.parentSeries),y=v.strokeThickness;v.fill,this.args.Reset(),this.args.forceShaderMethod=!0,this.args.verticalChart=h.isVerticalChart,this.args.columnWidth=h.columnWidth,this.args.spacing=h.spacing,this.args.stackedGroupCount=h.stackedGroupCount,this.args.stackedGroupIndex=h.groupIndex;var m=this.strokePenCache;h.columnWidth===1&&y===0&&(this.args.columnWidth=0,m=this.strokePenFillColoredCache);var b=(0,n.getScrtPenFromCache)(m);b&&this.args.SetLinesPen(b);var S=(0,i.getScrtBrushFromCache)(this.fillBrushCache);S&&this.args.SetFillBrush(S),this.args.viewportWidth=g.width,this.args.viewportHeight=g.height,c.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,b,this.parentSeries.fill,S,this.parentSeries.opacity,!1,this.parentSeries.fillLinearGradient!==void 0,h),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=this.palettingState.paletteStartIndex;var _=h.xCoordinateCalculator.isCategoryCoordinateCalculator,C=_?p.indexes:p.xValues,P=this.getStartAndCount(h,C),x=P.startIndex,E=P.count;this.args.count=E,this.args.startIndex=x;var A=f.getNativeContext();this.args.SetNativeContext(A),this.args.SetXValues(C),this.args.SetYValues(p.yValues),this.args.SetZValues(p.y1Values),this.args.SetXCoordinateCalculator(h.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(h.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args)},d.prototype.onDpiChanged=function(f){c.prototype.onDpiChanged.call(this,f),this.onSeriesPropertyChange(a.PROPERTY.STROKE)},d.prototype.onSeriesPropertyChange=function(f){c.prototype.onSeriesPropertyChange.call(this,f);var h=this.getProperties(this.parentSeries),p=h.stroke,g=h.strokeThickness,v=h.opacity,y=h.fill;(f===a.PROPERTY.STROKE||f===a.PROPERTY.STROKE_THICKNESS||f===a.PROPERTY.OPACITY)&&(0,n.createPenInCache)(this.strokePenCache,p,g,v),(f===a.PROPERTY.FILL||f===a.PROPERTY.OPACITY||f===a.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&this.createBrush(),g===0&&(f===a.PROPERTY.STROKE_THICKNESS||f===a.PROPERTY.STROKE||f===a.PROPERTY.OPACITY||f===a.PROPERTY.FILL)&&(0,n.createPenInCache)(this.strokePenFillColoredCache,y,1,v)},d.prototype.createBrush=function(){var f=this.parentSeries.parentSurface,h=this.getProperties(this.parentSeries),p=h.fillLinearGradient,g=h.fill,v=h.opacity,y=h.customTextureOptions,m=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.height/o.SciChartSurfaceBase.domMasterCanvas.height:1,b=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.width/o.SciChartSurfaceBase.domMasterCanvas.width:1,S=this.fillBrushCache.create(g,v,m,b,p,y);return S.scrtBrush},d})(s.BaseSeriesDrawingProvider);return V0.StackedColumnSeriesDrawingProvider=u,V0}var zve;function Ure(){if(zve)return m1;zve=1;var t=m1&&m1.__extends||(function(){var v=function(y,m){return v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,S){b.__proto__=S}||function(b,S){for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(b[_]=S[_])},v(y,m)};return function(y,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");v(y,m);function b(){this.constructor=y}y.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}})();Object.defineProperty(m1,"__esModule",{value:!0}),m1.StackedColumnCollection=void 0;var e=Br(),i=di(),n=hn(),r=QP(),o=ju(),a=Vre(),s=un(),l=DI(),u=IFe(),c=Em(),d=La(),f=bo(),h=KV(),p=Kz(),g=(function(v){t(y,v);function y(m,b){var S=this,_,C,P,x,E;return S=v.call(this,m,b)||this,S.type=n.ESeriesType.StackedColumnCollection,S.seriesGroups={},S.dataPointWidthProperty=.5,S.dataPointWidthModeProperty=c.EDataPointWidthMode.Relative,S.zeroLineYProperty=0,S.dataPointWidthProperty=(_=b==null?void 0:b.dataPointWidth)!==null&&_!==void 0?_:S.dataPointWidthProperty,S.dataPointWidthMode=(C=b==null?void 0:b.dataPointWidthMode)!==null&&C!==void 0?C:S.dataPointWidthModeProperty,S.zeroLineYProperty=(P=b==null?void 0:b.zeroLineY)!==null&&P!==void 0?P:S.zeroLineYProperty,S.spacingProperty=(E=(x=b==null?void 0:b.spacing)!==null&&x!==void 0?x:S.spacingProperty)!==null&&E!==void 0?E:0,S.getColumnWidth=S.getColumnWidth.bind(S),S.detachChildSeries=S.detachChildSeries.bind(S),S.attachChildSeries=S.attachChildSeries.bind(S),S.collectionChanged.subscribe(function(A){var R,M;(R=A.getOldItems())===null||R===void 0||R.forEach(S.detachChildSeries),(M=A.getNewItems())===null||M===void 0||M.forEach(S.attachChildSeries)}),S.dataLabelProvider=new u.StackedCollectionDataLabelProvider,S.dataLabelProviderProperty.onAttach(S.webAssemblyContext,S),S}return y.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),v.prototype.delete.call(this)},y.prototype.updateAccumulatedVectors=function(){var m=this,b=this.getDataSeriesValuesCount();if(!(!this.isAccumulatedVectorDirty||!b)){this.checkXValuesCorrect(),this.isAccumulatedVectorDirty=!1,this.clearAccumulatedVectors(b),this.updateGroups();var S=this.seriesGroups,_=this.getGroupsCount(),C=new Map;Object.keys(S).forEach(function(A,R){var M=S[A];M.forEach(function(D){D.setGroupsCount(_),D.setGroupIndex(R)}),C.set(A,M.map(function(D){return(0,f.vectorToArrayViewF64)(D.dataSeries.getNativeYValues(),m.webAssemblyContext)}))});for(var P=function(A){x.accumulatedValues0.push_back(x.zeroLineY),Object.keys(S).forEach(function(R){var M=S[R],D=C.get(R),F;m.isOneHundredPercent&&(F=D.reduce(function(V,z){return V+z[A]},0));var I=0;M.forEach(function(V,z){var G=D[z][A];m.isOneHundredPercent&&(G=G*100/F);var H=I+G;V.accumulatedValues.push_back(H),I=H})})},x=this,E=0;E<b;E++)P(E)}},y.prototype.draw=function(m,b){var S=this,_,C,P,x,E,A;if(this.canDraw){if(this.updateHitTestProviders(b),!this.isEnoughDataToDraw())return;var R=d.PerformanceDebugHelper.mark(d.EPerformanceMarkType.DrawCollectionSeriesStart,{contextId:this.id,parentContextId:(_=this.parentSurface)===null||_===void 0?void 0:_.id,level:d.EPerformanceDebugLevel.Verbose}),M=d.PerformanceDebugHelper.mark(d.EPerformanceMarkType.AccumulatedVectorStart,{contextId:this.id,parentContextId:(C=this.parentSurface)===null||C===void 0?void 0:C.id,level:d.EPerformanceDebugLevel.Verbose});this.updateAccumulatedVectors(),d.PerformanceDebugHelper.mark(d.EPerformanceMarkType.AccumulatedVectorEnd,{contextId:this.id,parentContextId:(P=this.parentSurface)===null||P===void 0?void 0:P.id,relatedId:(x=M==null?void 0:M.detail)===null||x===void 0?void 0:x.relatedId,level:d.EPerformanceDebugLevel.Verbose});var D=this.getFirstSeries().dataSeries;if(D!=null&&D.fifoCapacity)throw new Error("Sorry, fifo is not currently supported for stacked series");var F=this.seriesGroups,I=this.getGroupsCount(),V=this.getColumnWidth(b.xCoordinateCalculator);Object.keys(F).forEach(function(z,G){var H=F[z],U;H.forEach(function(k,X){var W,Y=X===0?S.accumulatedValues0:U.accumulatedValues,te=k.accumulatedValues,oe=new h.XyyPointSeriesWrapped(k.dataSeries,k.accumulatedValues,Y);S.setDataLabelProviderProperties(k.dataLabelProvider,te,G,I,V,S.spacingProperty,S.isOneHundredPercent),k.dataLabelProvider.generateDataLabels(m,new r.RenderPassData((W=k.dataSeries)===null||W===void 0?void 0:W.getIndicesRange(S.xAxis.visibleRange,S.xAxis.isCategoryAxis),S.xAxis.getCurrentCoordinateCalculator,S.yAxis.getCurrentCoordinateCalculator,S.xAxis.isVerticalChart,new l.XyPointSeriesWrapped(k.dataSeries)));var de=new p.StackedColumnRenderPassData(b.indexRange,b.getxCoordinateCalculator,b.getyCoordinateCalculator,b.isVerticalChart,V,I,G,S.spacingProperty,oe,b.resamplingHash);k.draw(m,de),U=k})}),d.PerformanceDebugHelper.mark(d.EPerformanceMarkType.DrawCollectionSeriesEnd,{contextId:this.id,parentContextId:(E=this.parentSurface)===null||E===void 0?void 0:E.id,relatedId:(A=R==null?void 0:R.detail)===null||A===void 0?void 0:A.relatedId,level:d.EPerformanceDebugLevel.Verbose})}},y.prototype.getXRange=function(){if(!this.isEnoughDataToDraw())return new i.NumberRange;var m=this.getFirstSeries().dataSeries.xRange,b=this.getFirstSeries().dataSeries.count(),S=this.dataPointWidth/2;if(this.dataPointWidthMode===c.EDataPointWidthMode.Relative&&(b>1?S=m.diff/(b-1)*this.dataPointWidth/2:S=0),this.dataPointWidthMode===c.EDataPointWidthMode.Absolute){var _=this.xAxis.getCurrentCoordinateCalculator();S=_.getDataWidth(this.dataPointWidth)/2}return new i.NumberRange(m.min-S,m.max+S)},y.prototype.getYRange=function(m,b){var S=v.prototype.getYRange.call(this,m,b);return new i.NumberRange(Math.min(S.min,this.zeroLineY),Math.max(S.max,this.zeroLineY))},y.prototype.onAttach=function(m){v.prototype.onAttach.call(this,m),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTStackedColumnSeriesDrawingProvider},y.prototype.notifyPropertyChanged=function(m){v.prototype.notifyPropertyChanged.call(this,m),(m===s.PROPERTY.DATA_SERIES||m===s.PROPERTY.IS_VISIBLE||m===s.PROPERTY.IS_ONE_HUNDRED_PERCENT||m===s.PROPERTY.STACKED_GROUP_ID)&&(this.isAccumulatedVectorDirty=!0)},y.prototype.hasDataSeriesValues=function(){return this.isEnoughDataToDraw()},y.prototype.getColumnWidth=function(m){var b=this.dataPointWidth,S=this.dataPointWidthMode,_=this.getFirstSeries().dataSeries,C=m.isCategoryCoordinateCalculator,P=C?_.getNativeIndexes():_.getNativeXValues(),x=this.parentSurface.seriesViewRect,E=this.getGroupsCount();if(S===c.EDataPointWidthMode.Range){var A=m.visibleMax-m.visibleMin;return m.viewportDimension/A*b/E}else return S===c.EDataPointWidthMode.Absolute?b/E:(0,o.getDataPointWidth)(P,m,x.width,b,C,_.dataDistributionCalculator.isSortedAscending,this.webAssemblyContext)/E},y.prototype.toJSON=function(m){m===void 0&&(m=!1);var b=v.prototype.toJSON.call(this,m),S={dataPointWidth:this.dataPointWidth,dataPointWidthMode:this.dataPointWidthMode,zeroLineY:this.zeroLineY,spacing:this.spacingProperty};return Object.assign(b.options,S),b},Object.defineProperty(y.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(m){this.dataPointWidthProperty=m,this.notifyPropertyChanged(s.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(m){this.dataPointWidthModeProperty=m,this.notifyPropertyChanged(s.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"zeroLineY",{get:function(){return this.zeroLineYProperty},set:function(m){this.zeroLineYProperty=m,this.notifyPropertyChanged(s.PROPERTY.ZERO_LINE_Y)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"spacing",{get:function(){return this.spacingProperty},set:function(m){this.spacingProperty=m,this.notifyPropertyChanged(s.PROPERTY.SPACING)},enumerable:!1,configurable:!0}),y.prototype.detachChildSeries=function(m){m.onDetachFromParentCollection(),this.isAccumulatedVectorDirty=!0,this.invalidateParent()},y.prototype.attachChildSeries=function(m){m.onAttachToParentCollection(this,this.getParentSurface,this.notifyPropertyChanged,this.getColumnWidth),this.isAccumulatedVectorDirty=!0,this.invalidateParent()},y.prototype.checkXValuesCorrect=function(){var m=this.getDataSeriesValuesCount();this.getVisibleSeries().forEach(function(b){var S;if(((S=b.dataSeries)===null||S===void 0?void 0:S.count())!==m)throw Error("All stacked series in on collection should have the same amount of X Values")})},y.prototype.setDataLabelProviderProperties=function(m,b,S,_,C,P,x){m.topVector=b,m.groupIndex=S,m.groupSize=_,m.columnWidth=C,m.spacing=P,m.isOneHundredPercent=x},y.prototype.clearAccumulatedVectors=function(m){this.accumulatedValues0.clear(),this.accumulatedValues0.reserve(m),this.asArray().forEach(function(b){b.accumulatedValues.clear(),b.accumulatedValues.reserve(m)})},y.prototype.getLastVisibleSeries=function(){var m=this.getVisibleSeries().slice(-1)[0];return m},y.prototype.updateGroups=function(){var m={};this.getVisibleSeries().forEach(function(b){var S=b.stackedGroupId;m[S]||(m[S]=[]),m[S].push(b)}),this.seriesGroups=m},y.prototype.getGroupsCount=function(){return Object.keys(this.seriesGroups).length},y})(a.BaseStackedCollection);return m1.StackedColumnCollection=g,m1}var w1={},A1={},$ve;function zre(){if($ve)return A1;$ve=1;var t=A1&&A1.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(A1,"__esModule",{value:!0}),A1.StackedXyCollection=void 0;var e=di(),i=qV(),n=La(),r=bo(),o=KV(),a=QP(),s=Vre(),l=un(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,h)||this;return p.detachChildSeries=p.detachChildSeries.bind(p),p.attachChildSeries=p.attachChildSeries.bind(p),p.collectionChanged.subscribe(function(g){var v,y;(v=g.getOldItems())===null||v===void 0||v.forEach(p.detachChildSeries),(y=g.getNewItems())===null||y===void 0||y.forEach(p.attachChildSeries)}),p}return d.prototype.updateAccumulatedVectors=function(){var f=this,h=this.getDataSeriesValuesCount();if(!(!this.isAccumulatedVectorDirty||!h)){this.checkXValuesCorrect(),this.isAccumulatedVectorDirty=!1,this.clearAccumulatedVectors(h);for(var p=this.getVisibleSeries().map(function(m){return(0,r.vectorToArrayViewF64)(m.dataSeries.getNativeYValues(),f.webAssemblyContext)}),g=function(m){v.accumulatedValues0.push_back(0);var b=0,S;v.isOneHundredPercent&&(S=v.getVisibleSeries().reduce(function(_,C,P){return _+p[P][m]},0)),v.getVisibleSeries().forEach(function(_,C){var P=p[C][m];f.isOneHundredPercent&&(P=P*100/S);var x=b+P;_.accumulatedValues.push_back(x),b=x,_.renderDataTransform&&(_.renderDataTransform.requiresTransform=!0)})},v=this,y=0;y<h;y++)g(y)}},d.prototype.draw=function(f,h){var p=this,g,v,y,m;if(this.canDraw){if(this.updateHitTestProviders(h),!this.isEnoughDataToDraw())return;if(!((g=this.getFirstSeries().dataSeries)===null||g===void 0)&&g.fifoCapacity)throw new Error("Sorry, fifo is not currently supported for stacked series");var b=n.PerformanceDebugHelper.mark(n.EPerformanceMarkType.DrawCollectionSeriesStart,{contextId:this.id,parentContextId:(v=this.parentSurface)===null||v===void 0?void 0:v.id,level:n.EPerformanceDebugLevel.Verbose});this.updateAccumulatedVectors();var S=this.xAxis,_=this.getVisibleSeries();_.reduceRight(function(C,P,x,E){var A=P.accumulatedValues,R=x===0?p.accumulatedValues0:E[x-1].accumulatedValues,M=new o.XyyPointSeriesWrapped(P.dataSeries,R,A),D=new a.RenderPassData(P.getIndicesRange(S.visibleRange),h.getxCoordinateCalculator,h.getyCoordinateCalculator,S.isVerticalChart,M);if(P.renderDataTransform){var F=new a.RenderPassData(P.getIndicesRange(S.visibleRange),h.getxCoordinateCalculator,h.getyCoordinateCalculator,S.isVerticalChart,M);return F=P.renderDataTransform.runTransform(F),x<_.length-1&&(0,i.copyDoubleVector)(E[x+1].renderDataTransform.pointSeries.yValues,F.pointSeries.y1Values,p.webAssemblyContext),"strokeY1"in P&&(P.strokeY1=x===0?"transparent":E[x-1].stroke,P.strokeY1DashArray=x===0?[]:E[x-1].strokeDashArray),P.drawingProviders[0].draw(f,F),P}return"strokeY1"in P&&(P.strokeY1=x===0?"transparent":E[x-1].stroke,P.strokeY1DashArray=x===0?[]:E[x-1].strokeDashArray),P.draw(f,D),P},void 0),n.PerformanceDebugHelper.mark(n.EPerformanceMarkType.DrawCollectionSeriesEnd,{contextId:this.id,parentContextId:(y=this.parentSurface)===null||y===void 0?void 0:y.id,relatedId:(m=b==null?void 0:b.detail)===null||m===void 0?void 0:m.relatedId,level:n.EPerformanceDebugLevel.Verbose})}},d.prototype.getXRange=function(){return this.isEnoughDataToDraw()?this.getFirstSeries().dataSeries.xRange:new e.NumberRange},d.prototype.onAttach=function(f){c.prototype.onAttach.call(this,f),this.getVisibleSeries().forEach(function(h){h.onAttach(f)})},d.prototype.onDetach=function(){this.getVisibleSeries().forEach(function(f){f.onDetach()}),c.prototype.onDetach.call(this)},d.prototype.notifyPropertyChanged=function(f){c.prototype.notifyPropertyChanged.call(this,f),(f===l.PROPERTY.DATA_SERIES||f===l.PROPERTY.IS_VISIBLE||f===l.PROPERTY.IS_ONE_HUNDRED_PERCENT)&&(this.isAccumulatedVectorDirty=!0)},d.prototype.hasDataSeriesValues=function(){return this.isEnoughDataToDraw()},d.prototype.detachChildSeries=function(f){f.onDetachFromParentCollection(),this.isAccumulatedVectorDirty=!0,this.invalidateParent()},d.prototype.attachChildSeries=function(f){f.onAttachToParentCollection(this,this.getParentSurface,this.notifyPropertyChanged),this.parentSurface&&f.onAttach(this.parentSurface),this.isAccumulatedVectorDirty=!0,this.invalidateParent()},d.prototype.checkXValuesCorrect=function(){var f=this.getDataSeriesValuesCount();this.getVisibleSeries().forEach(function(h){if(h.dataSeries.count()!==f)throw Error("All stacked series in on collection should have the same amount of X Values")})},d.prototype.clearAccumulatedVectors=function(f){this.accumulatedValues0.clear(),this.accumulatedValues0.reserve(f),this.asArray().forEach(function(h){h.accumulatedValues.clear(),h.accumulatedValues.reserve(f)})},d.prototype.getLastVisibleSeries=function(){var f=this.getVisibleSeries().slice(-1)[0];return f},d})(s.BaseStackedCollection);return A1.StackedXyCollection=u,A1}var Wve;function xW(){if(Wve)return w1;Wve=1;var t=w1&&w1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(w1,"__esModule",{value:!0}),w1.StackedMountainCollection=void 0;var e=hn(),i=zre(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this,a,s)||this;return l.type=e.ESeriesType.StackedMountainCollection,l}return o})(i.StackedXyCollection);return w1.StackedMountainCollection=n,w1}var H0={},m9={},Gve;function eI(){return Gve||(Gve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.adjustTextStyle=t.areEqualTextStyles=t.areEqualSimpleTextStyles=t.areEqualNativeTextStyles=t.areEqualTextureTextStyles=t.handleInvalidTextAlignment=t.handleInvalidChartTitlePosition=t.getIsHorizontalPlacement=t.ETitlePosition=t.ETextAlignment=void 0;var e=Zi(),i=pa();(function(f){f.Center="Center",f.Left="Left",f.Right="Right"})(t.ETextAlignment||(t.ETextAlignment={}));var n;(function(f){f.Top="Top",f.Bottom="Bottom",f.Right="Right",f.Left="Left"})(n=t.ETitlePosition||(t.ETitlePosition={}));var r=function(f){return f===n.Top||f===n.Bottom};t.getIsHorizontalPlacement=r;var o=function(f){throw new Error("Invalid chart title position: ".concat(f,"!"))};t.handleInvalidChartTitlePosition=o;var a=function(f){throw new Error('Invalid text alignment "'.concat(f,'"!'))};t.handleInvalidTextAlignment=a;var s=function(f,h){return f.color===h.color&&f.fontFamily===h.fontFamily&&f.fontSize===h.fontSize&&f.fontStyle===h.fontStyle&&f.fontWeight===h.fontWeight&&f.lineSpacing===h.lineSpacing&&(f.padding===void 0&&h.padding===void 0||i.Thickness.areEqual(f.padding,h.padding))};t.areEqualTextureTextStyles=s;var l=function(f,h){return f.color===h.color&&f.fontFamily===h.fontFamily&&f.fontSize===h.fontSize&&f.lineSpacing===h.lineSpacing&&(f.padding===void 0&&h.padding===void 0||i.Thickness.areEqual(f.padding,h.padding))};t.areEqualNativeTextStyles=l;var u=function(f,h){return!f||!h||!f.useNativeText!=!h.useNativeText?!1:f.useNativeText&&h.useNativeText?(0,t.areEqualNativeTextStyles)(f,h):(0,t.areEqualTextureTextStyles)(f,h)};t.areEqualSimpleTextStyles=u;var c=function(f,h){var p=(0,t.areEqualSimpleTextStyles)(f,h);return p&&f.rotation===h.rotation&&f.multilineAlignment===h.multilineAlignment};t.areEqualTextStyles=c;var d=function(f){var h=e.DpiHelper.adjustTextStyle(f);return h};t.adjustTextStyle=d})(m9)),m9}var bF={},SF={},b9={},Yve;function kI(){return Yve||(Yve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ELabelAlignment=void 0,(function(e){e.Auto="Auto",e.Left="Left",e.Right="Right",e.Center="Center"})(t.ELabelAlignment||(t.ELabelAlignment={}))})(b9)),b9}var qve;function gD(){return qve||(qve=1,(function(t){var e=SF&&SF.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.measureTextWidth=t.measureTextHeight=t.TextureManager=void 0;var i=Uo(),n=fo(),r=od(),o=kI(),a=Vf(),s=Ti(),l=id(),u=an(),c=Zi(),d=1080,f=1920,h=(function(y){e(m,y);function m(b){var S=y.call(this)||this;return S.webAssemblyContext=b,i.IS_TEST_ENV||(S.canvas=document.createElement("canvas"),S.canvas.width=f,S.canvas.height=d,S.ctx=S.canvas.getContext("2d",{willReadFrequently:!0})),S}return m.prototype.createSimpleTextTexture=function(b,S,_,C,P,x,E){var A=0;return C&&(P?A=90:A=-90),this.createTextTexture([b],S,A,void 0,_,x,E)},m.prototype.createTextTextureNative=function(b,S,_,C,P,x){S.fontStyle,S.fontWeight;var E=S.fontFamily,A=S.fontSize;S.padding,S.alignment;var R=S.color,M=this.webAssemblyContext.SCRTGetMainRenderContext2D(),D=(0,u.getFontKey)(this.webAssemblyContext,{fontFamily:E,fontSize:A??12}),F=P?(0,s.parseColorToUIntArgb)(P):0,I=M.CreateTextTexture(D,b.join(`
`),(0,s.parseColorToUIntArgb)(R),F);this.webAssemblyContext.SCRTSetTextureLinearSamplerEnabled(I,!1);var V=I.GetWidth(),z=I.GetHeight();return{bitmapTexture:I,textureWidth:V,textureHeight:z}},m.prototype.createTextTexture=function(b,S,_,C,P,x,E){var A;if(i.IS_TEST_ENV)return{bitmapTexture:void 0,textureWidth:1,textureHeight:1};var R=S.fontStyle,M=S.fontWeight,D=S.fontFamily,F=S.fontSize,I=S.padding,V=S.alignment,z=S.color;this.ctx.save(),this.ctx.globalAlpha=x??1,this.ctx.textBaseline="alphabetic",this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.ctx.fillStyle=z,this.ctx.font=(0,a.getFontString)(R,M,F,D);for(var G=0,H=I.top+I.bottom,U=0,k=0,X=[],W=0;W<b.length;W++){var Y=b[W],te=this.ctx.measureText(Y),oe=Math.round(te.actualBoundingBoxAscent+te.actualBoundingBoxDescent);X.push(oe),oe>U&&(U=oe),W===0&&(k=te.actualBoundingBoxAscent);var de=Math.round(te.width+I.left+I.right);de>G&&(G=de),H+=oe}var ge=(0,l.convertToNativeLineSpacing)(U,C??1.1);H+=(b.length-1)*ge;var Ee=I.top+k,Re=I.left;if(!G||!H)return{bitmapTexture:void 0,textureWidth:G,textureHeight:H};var Ae=G,Pe=H;if(_){var we=_*Math.PI/180;Ae=Math.round(G*Math.abs(Math.cos(we))+H*Math.abs(Math.sin(we))),Pe=Math.round(G*Math.abs(Math.sin(we))+H*Math.abs(Math.cos(we))),this.ctx.translate(Ae/2,Pe/2),this.ctx.rotate(we),this.ctx.translate(-G/2,-H/2)}if(P){this.ctx.save(),this.ctx.fillStyle=P;var Te=G,ke=H,$e=Math.min(E*c.DpiHelper.PIXEL_RATIO,Te/2,ke/2);$e>0?(this.ctx.beginPath(),this.ctx.moveTo($e,0),this.ctx.lineTo(Te-$e,0),this.ctx.quadraticCurveTo(Te,0,Te,$e),this.ctx.lineTo(Te,ke-$e),this.ctx.quadraticCurveTo(Te,ke,Te-$e,ke),this.ctx.lineTo($e,ke),this.ctx.quadraticCurveTo(0,ke,0,ke-$e),this.ctx.lineTo(0,$e),this.ctx.quadraticCurveTo(0,0,$e,0),this.ctx.closePath(),this.ctx.fill()):this.ctx.fillRect(0,0,Te,ke),this.ctx.restore()}for(var Ne=(A=S.multilineAlignment)!==null&&A!==void 0?A:V,ve=G-I.right-I.left,W=0;W<b.length;W++){var Y=b[W];if(Ne===o.ELabelAlignment.Center||Ne===o.ELabelAlignment.Right){var de=(0,t.measureTextWidth)(this.ctx,Y);Re=Ne===o.ELabelAlignment.Right?G-de-I.right:(ve-de)/2+I.left}this.ctx.fillText(Y,Math.round(Re),Math.round(Ee)),Ee+=X[W]+ge}return this.ctx.strokeStyle=z,this.ctx.restore(),this.createTextureFromCtxBuffer(Ae,Pe)},m.prototype.createAxisMarkerTexture=function(b,S,_,C,P,x,E,A,R,M){A===void 0&&(A=0),this.ctx.globalAlpha=M??1,this.ctx.textBaseline="top",this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.ctx.font=(0,a.getFontString)(_,C,P,x);var D=(0,t.measureTextWidth)(this.ctx,S)+4*A,F=(0,t.measureTextHeight)(P)+2*A,I=v(F,D,S,b),V=I.angle,z=I.alignmentLeft,G=I.alignmentTop,H=I.finalTextureWidth,U=I.finalTextureHeight,k=I.halfHeight;if(this.ctx.save(),this.ctx.translate((D+k)/2,F/2),this.ctx.rotate(V),this.ctx.translate(z,G),R){var X=new Path2D,W=F,Y=D;X.moveTo(0,0),X.lineTo(Y,0),X.lineTo(k+Y,k),X.lineTo(Y,W),X.lineTo(0,W),X.closePath(),this.ctx.fillStyle=R,this.ctx.fill(X)}return b!==r.EAxisAlignment.Right&&(this.ctx.fillStyle=E,this.ctx.fillText(S,2*A,A)),this.ctx.restore(),b===r.EAxisAlignment.Right&&(this.ctx.fillStyle=E,this.ctx.fillText(S,2*A+k,A)),this.createTextureFromCtxBuffer(H,U)},m.prototype.createTextureFromImage=function(b,S,_){this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height);var C=(S??b.width)*c.DpiHelper.PIXEL_RATIO,P=(_??b.height)*c.DpiHelper.PIXEL_RATIO;return this.ctx.drawImage(b,0,0,C,P),this.createTextureFromCtxBuffer(C,P)},m.prototype.getTextureContext=function(b,S){if(!i.IS_TEST_ENV)return b>this.canvas.width&&(this.canvas.width=b),S>this.canvas.height&&(this.canvas.height=S),this.ctx.clearRect(0,0,this.canvas.width,this.canvas.height),this.ctx},m.prototype.createTextureFromCtxBuffer=function(b,S){var _=this.ctx.getImageData(0,0,b,S);return this.createTextureFromImageData(_,b,S)},m.prototype.createTextureFromImageData=function(b,S,_){var C=this.webAssemblyContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_A8B8G8R8,P=this.webAssemblyContext.SCRTCreateBitmapTexture(S,_,C),x;try{var E=b.data;this.webAssemblyContext.SCRTSetActiveTexture(P),x=this.webAssemblyContext._malloc(E.length),this.webAssemblyContext.HEAP8.set(E,x);var A=this.webAssemblyContext.ccall("SCRTFillActiveTextureCharArray",null,["number","number","number"],[S,_,x])}catch(R){console.error(R)}finally{this.webAssemblyContext._free(x),this.webAssemblyContext.SCRTSetTextureLinearSamplerEnabled(P,!1)}return{bitmapTexture:P,textureWidth:S,textureHeight:_}},m.prototype.delete=function(){this.canvas=void 0,this.ctx=void 0,this.webAssemblyContext=void 0},m.prototype.createTextureFromCtx=function(b,S){var _=this.ctx.getImageData(0,0,b,S),C=_.data,P=b*S,x=new this.webAssemblyContext.UIntVector;x.resize(P,0);for(var E=0;E<P;E++){var A=E*4,R=C[A+3];if(R!==0){var M=C[A],D=C[A+1],F=C[A+2],I=R<<24|F<<16|D<<8|M;x.set(E,I>>>0)}}var V=this.webAssemblyContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_A8B8G8R8,z=this.webAssemblyContext.SCRTCreateBitmapTexture(b,S,V);return this.webAssemblyContext.SCRTFillTextureAbgr(z,b,S,x),x.delete(),{bitmapTexture:z,textureWidth:b,textureHeight:S}},m})(n.DeletableEntity);t.TextureManager=h;var p=function(y){return y};t.measureTextHeight=p;var g=function(y,m){if(i.IS_TEST_ENV)return 1;if(y){var b=y.measureText(m);return Math.ceil(b.width)}return 0};t.measureTextWidth=g;var v=function(y,m,b,S){var _=Math.ceil(y/2),C=0,P=0,x=0,E=m+_,A=y;switch(S){case r.EAxisAlignment.Left:C=0,P=-(m+_)/2,x=-y/2;break;case r.EAxisAlignment.Top:C=Math.PI*.5,P=-y/2,x=(m+_)/2-y,E=y,A=m+_;break;case r.EAxisAlignment.Right:C=Math.PI,P=-(m+_)/2,x=-y/2;break;case r.EAxisAlignment.Bottom:C=Math.PI*1.5,P=-m,x=-(m+_)/2,E=y,A=m+_;break}return{angle:C,alignmentLeft:P,alignmentTop:x,finalTextureWidth:E,finalTextureHeight:A,halfHeight:_}}})(SF)),SF}var Xve;function Zz(){return Xve||(Xve=1,(function(t){var e=bF&&bF.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.getAdjustedRotation=t.TitleRendererBase=void 0;var i=Uo(),n=fo(),r=Br(),o=Rn(),a=Tc(),s=eI(),l=Ti(),u=id(),c=ZP(),d=an(),f=Wf(),h=Zi(),p=gD(),g=(function(y){e(m,y);function m(b){var S=y.call(this)||this;return S.drawDebug=!1,S.useCache=!0,S.viewRectProperty=o.Rect.createZero(),S.textHeight=0,S.textWidth=0,S.desiredHeightProperty=0,S.desiredWidthProperty=0,S.useNativeTextProperty=f.SciChartDefaults.useNativeText,S.webAssemblyContext=b,S.textureManager=new p.TextureManager(b),S.onDpiChanged=S.onDpiChanged.bind(S),h.DpiHelper.dpiChanged.subscribe(S.onDpiChanged),S}return Object.defineProperty(m.prototype,"viewRect",{get:function(){return this.viewRectProperty},enumerable:!1,configurable:!0}),m.prototype.measure=function(){},m.prototype.layout=function(b){},m.prototype.draw=function(){},m.prototype.delete=function(){this.resetCache(),this.textureManager=(0,r.deleteSafe)(this.textureManager),this.webAssemblyContext=void 0,h.DpiHelper.dpiChanged.unsubscribe(this.onDpiChanged)},m.prototype.resetCache=function(){this.invalidateCache(),this.textStyle=void 0,this.originalTextStyle=void 0},m.prototype.invalidateCache=function(){var b;(0,r.deleteSafe)((b=this.texture)===null||b===void 0?void 0:b.bitmapTexture),this.texture=void 0},m.prototype.onDpiChanged=function(b){this.resetCache()},m.prototype.drawInternal=function(b,S,_,C){!this.text||this.text.length===0||(S?this.drawWithNativeText(b,_,C):this.drawWithTexture(b,_,C))},m.prototype.drawWithNativeText=function(b,S,_){var C=Array.isArray(this.text)?this.text.join(`
`):this.text,P=b.getFont(this.textStyle,!0),x=this.viewRect.left+this.nativeTextShiftX,E=this.viewRect.top+this.nativeTextShiftY,A=(0,t.getAdjustedRotation)(this.textStyle.rotation,S),R=-(A*Math.PI)/180,M=(0,a.convertMultiLineAlignment)(this.textStyle.multilineAlignment,this.webAssemblyContext),D=(0,l.parseColorToUIntArgb)(this.textStyle.color);b.resetAndClip(_),P.DrawStringAdvanced(C,D,Math.round(x),Math.round(E),(0,d.getVector4)(this.webAssemblyContext,x,E,R,0),M,this.nativeLineSpacing),P.End()},m.prototype.drawWithTexture=function(b,S,_){var C=this.texture,P=C.bitmapTexture,x=C.textureHeight,E=C.textureWidth;if(P)try{b.resetAndClip(_),b.drawTexture(P,Math.round(this.viewRect.left),Math.round(this.viewRect.top),E,x),this.useCache||(P.delete(),this.texture=void 0)}catch(A){console.error("Error while drawing title: ",A),this.resetCache()}},m.prototype.getTextSize=function(b,S,_){if(b===void 0&&(b=""),!b||b.length===0){this.desiredHeightProperty=0,this.desiredWidthProperty=0,this.textHeight=0,this.textWidth=0;return}var C=(0,s.getIsHorizontalPlacement)(this.titlePosition);if(i.IS_TEST_ENV)C?(this.desiredHeightProperty=(0,p.measureTextHeight)(S.fontSize)+this.textStyle.padding.top+this.textStyle.padding.bottom,this.desiredWidthProperty=0):(this.desiredHeightProperty=0,this.desiredWidthProperty=(0,p.measureTextHeight)(S.fontSize)+this.textStyle.padding.top+this.textStyle.padding.bottom);else if(this.useNativeTextProperty){var P=_.getFont(S,!C);this.currentNativeFontName=P.GetFaceName();var x=Array.isArray(b)?b.join(`
`):b,E=(0,t.getAdjustedRotation)(S.rotation,this.titlePosition),A=(0,u.getNativeTextSize)(x,P,S,this.webAssemblyContext,E),R=A.textHeight,M=A.textWidth,D=A.nativeLineSpacing,F=A.deltaX,I=A.deltaY;this.textHeight=C?R:M,this.textWidth=C?M:R,this.nativeLineSpacing=D,this.nativeTextShiftX=F,this.nativeTextShiftY=I,this.desiredHeightProperty=C?this.textHeight:this.textWidth,this.desiredWidthProperty=C?this.textWidth:this.textHeight}else{var V=this.getTitleTexture();this.texture=V,this.desiredHeightProperty=V.textureHeight,this.desiredWidthProperty=V.textureWidth,this.textHeight=C?this.desiredHeightProperty:this.desiredWidthProperty,this.textWidth=C?this.desiredWidthProperty:this.desiredHeightProperty}},m.prototype.getTitleTexture=function(){var b=Array.isArray(this.text)?this.text:this.text.split(`
`),S=this.textureManager.createTextTexture(b,this.textStyle);return S},m.prototype.getViewRect=function(b,S,_,C){if(b===void 0&&(b=""),!b||b.length===0)return o.Rect.createZero();var P=(0,s.getIsHorizontalPlacement)(_),x=this.getAlignmentAdjustmentDelta(P?S.width:S.height,_,C);switch(_){case s.ETitlePosition.Top:return new o.Rect(S.x+x,S.y,this.textWidth,this.textHeight);case s.ETitlePosition.Bottom:return new o.Rect(S.x+x,S.bottom-this.textHeight,this.textWidth,this.textHeight);case s.ETitlePosition.Left:return new o.Rect(S.x,S.y+x,this.textHeight,this.textWidth);case s.ETitlePosition.Right:return new o.Rect(S.right-this.textHeight,S.y+x,this.textHeight,this.textWidth);default:return(0,s.handleInvalidChartTitlePosition)(_)}},m.prototype.drawTitleDebugViewRect=function(b){var S=this.viewRect,_=(0,d.getVectorRectVertex)(this.webAssemblyContext),C=new this.webAssemblyContext.SCRTSolidBrush((0,l.parseColorToUIntArgb)("rgba(0,255,0,0.7)"),!1),P=(0,c.createNativeRect)(this.webAssemblyContext,0,0,S.width,S.height);_.push_back(P),b.drawRects(_,C,S,S.left,S.top),C.delete()},m.prototype.getAlignmentAdjustmentDelta=function(b,S,_){switch(_){case s.ETextAlignment.Center:return b/2-this.textWidth/2;case s.ETextAlignment.Left:return S===s.ETitlePosition.Left?b-this.textWidth:0;case s.ETextAlignment.Right:return S===s.ETitlePosition.Left?0:b-this.textWidth;default:return(0,s.handleInvalidTextAlignment)(_)}},m})(n.DeletableEntity);t.TitleRendererBase=g;var v=function(y,m){if(y!==void 0)return(y+360)%360;var b=0;return m===s.ETitlePosition.Left?b+=-90:m===s.ETitlePosition.Right&&(b+=90),(b+360)%360};t.getAdjustedRotation=v})(bF)),bF}var Kve;function FFe(){if(Kve)return H0;Kve=1;var t=H0&&H0.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=H0&&H0.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(H0,"__esModule",{value:!0}),H0.ChartTitleRenderer=void 0;var i=pa(),n=eI(),r=Sn(),o=Zz(),a=(function(s){t(l,s);function l(){var u=s!==null&&s.apply(this,arguments)||this;return u.titleOffsetProperty=i.Thickness.fromNumber(0),u}return Object.defineProperty(l.prototype,"titleOffset",{get:function(){return this.titleOffsetProperty},enumerable:!1,configurable:!0}),l.prototype.measure=function(u,c,d){var f,h=u!==this.text||!(0,n.areEqualTextStyles)(c,this.originalTextStyle)||((f=this.originalTextStyle)===null||f===void 0?void 0:f.position)!==c.position;if(this.currentNativeFontName==="SCRT_Loading"){var p=(0,n.getIsHorizontalPlacement)(this.titlePosition),g=d.getFont(this.textStyle,!p);g.GetFaceName()!==this.currentNativeFontName&&(h=!0)}u&&u.length>0?!this.useCache||!this.texture&&!c.useNativeText||h?(this.invalidateCache(),this.text=u,this.originalTextStyle=e({},c),this.textStyle=(0,n.adjustTextStyle)(c),this.useNativeTextProperty=c.useNativeText,this.titlePosition=c.position,this.getTextSize(u,this.textStyle,d)):(this.textStyle.alignment=c.alignment,this.textStyle.placeWithinChart=c.placeWithinChart):this.text=u,this.titleOffsetProperty=this.getTitleOffset(u,this.textStyle)},l.prototype.layout=function(u){if(!this.text||this.text.length===0){this.viewRectProperty=void 0;return}this.viewRectProperty=this.getViewRect(this.text,u,this.textStyle.position,this.textStyle.alignment)},l.prototype.draw=function(u,c){if(!(!this.text||this.text.length===0)){r.DebugForDpi&&console.log("ChartTitleRenderer.draw fontSize: ".concat(this.textStyle.fontSize));var d=this.textStyle,f=d.useNativeText,h=d.position;d.lineSpacing,this.drawInternal(u,f,h,c),this.drawDebug&&this.drawTitleDebugViewRect(u)}},l.prototype.getTitleTexture=function(){var u=this.textStyle.position,c=(0,o.getAdjustedRotation)(this.textStyle.rotation,u),d=Array.isArray(this.text)?this.text:this.text.split(`
`),f=this.textureManager.createTextTexture(d,this.textStyle,c,this.textStyle.lineSpacing);return f},l.prototype.getTitleOffset=function(u,c){if(!this.text||this.text.length===0||c.placeWithinChart)return i.Thickness.fromNumber(0);var d=this.textHeight;switch(c.position){case n.ETitlePosition.Top:return new i.Thickness(d,0,0,0);case n.ETitlePosition.Bottom:return new i.Thickness(0,0,d,0);case n.ETitlePosition.Left:return new i.Thickness(0,0,0,d);case n.ETitlePosition.Right:return new i.Thickness(0,d,0,0);default:return(0,n.handleInvalidChartTitlePosition)(c.position)}},l})(o.TitleRendererBase);return H0.ChartTitleRenderer=a,H0}var S9={},Zve;function WS(){return Zve||(Zve=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESciChartSurfaceType=void 0,(function(e){e.Default2D="Default2D",e.Pie2D="Pie2D",e.Polar2D="Polar2D",e.Default3D="Default3D"})(t.ESciChartSurfaceType||(t.ESciChartSurfaceType={}))})(S9)),S9}var Jve;function Rg(){return Jve||(Jve=1,(function(t){var e=cp&&cp.__extends||(function(){var $e=function(Ne,ve){return $e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(pe,fe){pe.__proto__=fe}||function(pe,fe){for(var me in fe)Object.prototype.hasOwnProperty.call(fe,me)&&(pe[me]=fe[me])},$e(Ne,ve)};return function(Ne,ve){if(typeof ve!="function"&&ve!==null)throw new TypeError("Class extends value "+String(ve)+" is not a constructor or null");$e(Ne,ve);function pe(){this.constructor=Ne}Ne.prototype=ve===null?Object.create(ve):(pe.prototype=ve.prototype,new pe)}})(),i=cp&&cp.__assign||function(){return i=Object.assign||function($e){for(var Ne,ve=1,pe=arguments.length;ve<pe;ve++){Ne=arguments[ve];for(var fe in Ne)Object.prototype.hasOwnProperty.call(Ne,fe)&&($e[fe]=Ne[fe])}return $e},i.apply(this,arguments)},n=cp&&cp.__awaiter||function($e,Ne,ve,pe){function fe(me){return me instanceof ve?me:new ve(function(Ce){Ce(me)})}return new(ve||(ve=Promise))(function(me,Ce){function Ue(xt){try{it(pe.next(xt))}catch(wt){Ce(wt)}}function Qe(xt){try{it(pe.throw(xt))}catch(wt){Ce(wt)}}function it(xt){xt.done?me(xt.value):fe(xt.value).then(Ue,Qe)}it((pe=pe.apply($e,Ne||[])).next())})},r=cp&&cp.__generator||function($e,Ne){var ve={label:0,sent:function(){if(me[0]&1)throw me[1];return me[1]},trys:[],ops:[]},pe,fe,me,Ce;return Ce={next:Ue(0),throw:Ue(1),return:Ue(2)},typeof Symbol=="function"&&(Ce[Symbol.iterator]=function(){return this}),Ce;function Ue(it){return function(xt){return Qe([it,xt])}}function Qe(it){if(pe)throw new TypeError("Generator is already executing.");for(;ve;)try{if(pe=1,fe&&(me=it[0]&2?fe.return:it[0]?fe.throw||((me=fe.return)&&me.call(fe),0):fe.next)&&!(me=me.call(fe,it[1])).done)return me;switch(fe=0,me&&(it=[it[0]&2,me.value]),it[0]){case 0:case 1:me=it;break;case 4:return ve.label++,{value:it[1],done:!1};case 5:ve.label++,fe=it[1],it=[0];continue;case 7:it=ve.ops.pop(),ve.trys.pop();continue;default:if(me=ve.trys,!(me=me.length>0&&me[me.length-1])&&(it[0]===6||it[0]===2)){ve=0;continue}if(it[0]===3&&(!me||it[1]>me[0]&&it[1]<me[3])){ve.label=it[1];break}if(it[0]===6&&ve.label<me[1]){ve.label=me[1],me=it;break}if(me&&ve.label<me[2]){ve.label=me[2],ve.ops.push(it);break}me[2]&&ve.ops.pop(),ve.trys.pop();continue}it=Ne.call($e,ve)}catch(xt){it=[6,xt],fe=0}finally{pe=me=0}if(it[0]&5)throw it[1];return{value:it[0]?it[1]:void 0,done:!0}}},o=cp&&cp.__spreadArray||function($e,Ne,ve){if(ve||arguments.length===2)for(var pe=0,fe=Ne.length,me;pe<fe;pe++)(me||!(pe in Ne))&&(me||(me=Array.prototype.slice.call(Ne,0,pe)),me[pe]=Ne[pe]);return $e.concat(me||Array.prototype.slice.call(Ne))};Object.defineProperty(t,"__esModule",{value:!0}),t.SciChartSurface=t.sciChartConfig=void 0;var a=mo(),s=Uo(),l=ad(),u=vm(),c=Br(),d=Sre(),f=ps(),h=DP(),p=Rn(),g=pa(),v=cFe(),y=ga(),m=hn(),b=Ig(),S=xm(),_=dFe(),C=Ywt(),P=fFe(),x=JP(),E=DFe(),A=RFe(),R=H3(),M=kFe(),D=jre(),F=an(),I=Ure(),V=xW(),z=tC(),G=Sn(),H=Zi(),U=$i(),k=Wf(),X=FFe(),W=eI(),Y=Tc(),te=$v(),oe=zS(),de=kh(),ge=La(),Ee=vs(),Re=$f(),Ae=od(),Pe=Vf(),we=WS(),Te={wasmUrl:"scichart2d.wasm",wasmNoSimdUrl:void 0};t.sciChartConfig=Te;var ke=(function($e){e(Ne,$e);function Ne(ve,pe){var fe=this,me,Ce,Ue,Qe,it;fe=$e.call(this,ve,pe==null?void 0:pe.canvases)||this,fe.preRender=new f.EventHandler,fe.preRenderAll=new f.EventHandler,fe.stepBetweenLayers=10,fe.isSubSurface=!1,fe.renderNativeAxisLabelsImmediately=!1,fe.watermarkPosition=k.SciChartDefaults.watermarkPosition,fe.watermarkRelativeToCanvas=!1,fe.animationList=[],fe.titleStyleProperty={fontSize:60,fontFamily:(0,Pe.getDefaultFontName)(),color:G.SciChartSurfaceBase.DEFAULT_THEME.chartTitleColor,fontWeight:"normal",fontStyle:"normal",lineSpacing:1.1,padding:g.Thickness.fromString("10 4 10 4"),multilineAlignment:Y.EMultiLineAlignment.Center,rotation:void 0,alignment:W.ETextAlignment.Center,position:W.ETitlePosition.Top,placeWithinChart:!1,useNativeText:k.SciChartDefaults.useNativeText},fe.getPaddingProxy=function(vt){return new Proxy(vt,{set:function(kt,Xe,_t){return kt[Xe]!==_t&&(kt[Xe]=_t,fe.invalidateElement()),!0}})},fe.paddingProperty=fe.getPaddingProxy(g.Thickness.fromNumber(10)),fe.zoomStateProperty=S.EZoomState.AtExtents,fe.viewportBorderProperty={borderBottom:void 0,borderLeft:void 0,borderRight:void 0,borderTop:void 0,color:"#00000000",border:void 0},fe.canvasBorderProperty={borderBottom:void 0,borderLeft:void 0,borderRight:void 0,borderTop:void 0,color:"#00000000",border:void 0},fe.subChartsProperty=[],fe.drawSeriesBehindAxisProperty=!1,fe.autoColorModeProperty=v.EAutoColorMode.OnAddRemoveSeries,fe.autoColorRequired=!0,fe.xCoordSvgTrans=0,fe.yCoordSvgTrans=0,fe.subChartCounterProperty=1,fe.surfaceRenderOrderProperty=void 0,fe.resolvedSurfaceRenderOrder=0;var xt=(Ce=(me=fe.domCanvas2D)===null||me===void 0?void 0:me.width)!==null&&Ce!==void 0?Ce:s.DEFAULT_WIDTH,wt=(Qe=(Ue=fe.domCanvas2D)===null||Ue===void 0?void 0:Ue.height)!==null&&Qe!==void 0?Qe:s.DEFAULT_HEIGHT;if(fe.webAssemblyContext2D=ve,!s.IS_TEST_ENV){var $t=xt/H.DpiHelper.PIXEL_RATIO,Mt=wt/H.DpiHelper.PIXEL_RATIO;fe.isCopyCanvasSurface?fe.changeMasterCanvasViewportSize(ve,$t,Mt):fe.changeWebGLCanvasViewportSize(ve,$t,Mt)}fe.invalidateElement=fe.invalidateElement.bind(fe),fe.onRenderSurfaceDraw=fe.onRenderSurfaceDraw.bind(fe);var rt=fe.domCanvas2D?new b.Size(xt,wt):new b.Size(s.DEFAULT_WIDTH,s.DEFAULT_HEIGHT);fe.renderSurface=new C.RenderSurface(ve,rt,(it=fe.domCanvas2D)===null||it===void 0?void 0:it.id),fe.renderSurface.handleDraw=fe.onRenderSurfaceDraw,fe.sciChartRenderer=new E.SciChartRenderer(fe),fe.chartTitleRendererProperty=new X.ChartTitleRenderer(fe.webAssemblyContext2D),fe.layoutManager=new x.LayoutManager,fe.detachSeries=fe.detachSeries.bind(fe),fe.attachSeries=fe.attachSeries.bind(fe),fe.renderableSeries=new h.ObservableArray,fe.renderableSeries.collectionChanged.subscribe(function(vt){var kt,Xe;(kt=vt.getOldItems())===null||kt===void 0||kt.forEach(fe.detachSeries),(Xe=vt.getNewItems())===null||Xe===void 0||Xe.forEach(fe.attachSeries)}),fe.detachAxis=fe.detachAxis.bind(fe),fe.attachAxis=fe.attachAxis.bind(fe),fe.xAxes=new h.ObservableArray,fe.yAxes=new h.ObservableArray;var qe=function(vt,kt){var Xe,_t;(Xe=vt.getOldItems())===null||Xe===void 0||Xe.forEach(function(Ht){Ht.visibleRangeChanged.unsubscribeAll(),fe.detachAxis(Ht)}),(_t=vt.getNewItems())===null||_t===void 0||_t.forEach(function(Ht){return fe.attachAxis(Ht,kt)})};return fe.xAxes.collectionChanged.subscribe(function(vt){return qe(vt,!0)}),fe.yAxes.collectionChanged.subscribe(function(vt){return qe(vt,!1)}),fe.adornerLayer=new A.AdornerLayer(fe),fe.solidBrushCacheViewportBorder=new P.SolidBrushCache(ve),fe.solidBrushCacheCanvasBorder=new P.SolidBrushCache(ve),s.IS_TEST_ENV||(fe.watermarkProperties=new ve.SCRTWaterMarkProperties,fe.watermarkPropertyPosition=new ve.TSRVector2(0,0),fe.watermarkProperties.SetPosition(fe.watermarkPropertyPosition),fe.watermarkProperties.SetOpacity(.5),ve.SCRTSetWaterMarkProperties(fe.watermarkProperties)),fe}return Ne.create=function(ve,pe){var fe=ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.InitializationStart,{contextId:pe==null?void 0:pe.id});if(pe=Ne.resolveOptions(pe),s.IS_TEST_ENV)return this.createTest(ve,pe);var me=function(Ce,Ue){return new Ne(Ce,Ue)};return(0,R.createMultichart)(ve,me,pe).then(function(Ce){var Ue,Qe;return Ce.sciChartSurface.applyOptions(pe),ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.InitializationEnd,{parentContextId:(Ue=Ce.sciChartSurface.domCanvas2D)===null||Ue===void 0?void 0:Ue.id,contextId:Ce.sciChartSurface.id,relatedId:(Qe=fe==null?void 0:fe.detail)===null||Qe===void 0?void 0:Qe.relatedId}),Ce})},Ne.disposeSharedWasmContext=function(){te.sciChartDestinations.length===0&&(0,R.disposeMultiChart)(),$e.disposeSharedWasmContext.call(this)},Ne.createSingle=function(ve,pe){var fe=ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.InitializationStart,{contextId:pe==null?void 0:pe.id});if(pe=Ne.resolveOptions(pe),s.IS_TEST_ENV)return this.createTest(ve,pe);var me=function(Ce,Ue){return new Ne(Ce,Ue)};return(0,M.createSingleInternal)(ve,me,pe).then(function(Ce){var Ue,Qe;return Ce.sciChartSurface.applyOptions(pe),ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.InitializationEnd,{parentContextId:(Ue=Ce.sciChartSurface.domCanvas2D)===null||Ue===void 0?void 0:Ue.id,contextId:Ce.sciChartSurface.id,relatedId:(Qe=fe==null?void 0:fe.detail)===null||Qe===void 0?void 0:Qe.relatedId}),Ce})},Ne.configure=function(ve){var pe,fe;t.sciChartConfig.wasmUrl=(pe=ve==null?void 0:ve.wasmUrl)!==null&&pe!==void 0?pe:Te.wasmUrl,t.sciChartConfig.wasmNoSimdUrl=(fe=ve==null?void 0:ve.wasmNoSimdUrl)!==null&&fe!==void 0?fe:Te.wasmNoSimdUrl},Ne.useWasmFromCDN=function(){t.sciChartConfig.wasmUrl="https://cdn.jsdelivr.net/npm/scichart@".concat(u.libraryVersion,"/_wasm/scichart2d.wasm"),t.sciChartConfig.wasmNoSimdUrl="https://cdn.jsdelivr.net/npm/scichart@".concat(u.libraryVersion,"/_wasm/scichart2d-nosimd.wasm")},Ne.useWasmLocal=function(){Ne.configure(Te)},Ne.loadWasmFromCDN=function(){return Ne.useWasmFromCDN()},Ne.loadWasmLocal=function(){return Ne.useWasmLocal()},Ne.isSubSurface=function(ve){return ve.isSubSurface},Ne.createTest=function(ve,pe){var fe,me,Ce=z.default.initCanvas(ve,(fe=pe==null?void 0:pe.widthAspect)!==null&&fe!==void 0?fe:0,(me=pe==null?void 0:pe.heightAspect)!==null&&me!==void 0?me:0,z.default.ECanvasType.canvas2D),Ue=new Ne(t.sciChartConfig.testWasm,{canvases:Ce});return Ue.applyTheme(pe==null?void 0:pe.theme),Ue.applyOptions(pe),new Promise(function(Qe){return Qe({wasmContext:Ue.webAssemblyContext2D,sciChartSurface:Ue})})},Object.defineProperty(Ne.prototype,"subChartCounter",{get:function(){return this.subChartCounterProperty},enumerable:!1,configurable:!0}),Ne.prototype.addSubChartInternal=function(ve){var pe;if(this.isSubSurface)throw new Error("Can not add subChart to subChart.");this.subChartCounterProperty++,(pe=ve.mouseManager)===null||pe===void 0||pe.unsubscribe(),this.subChartsProperty.push(ve),this.onAttachSubSurface(ve),ve.setIsInitialized()},Ne.prototype.removeSubChart=function(ve){var pe=this.subChartsProperty.findIndex(function(fe){return fe===ve});pe>-1&&(this.subChartsProperty.splice(pe,1),ve.delete(!0))},Object.defineProperty(Ne.prototype,"subCharts",{get:function(){return this.subChartsProperty},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"surfaceType",{get:function(){return Ee.ESurfaceType.SciChartSurfaceType},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"layoutManager",{get:function(){return this.layoutManagerProperty},set:function(ve){this.layoutManagerProperty&&(this.layoutManagerProperty.sciChartSurface=void 0),this.layoutManagerProperty=ve,this.layoutManagerProperty.sciChartSurface=this,this.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"chartTitleRenderer",{get:function(){return this.chartTitleRendererProperty},set:function(ve){var pe;(pe=this.chartTitleRendererProperty)===null||pe===void 0||pe.delete(),this.chartTitleRendererProperty=ve,this.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"dataLabelLayoutManager",{get:function(){return this.dataLabelLayoutManagerProperty},set:function(ve){this.dataLabelLayoutManagerProperty=ve,this.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"title",{get:function(){return this.titleProperty},set:function(ve){this.titleProperty!==ve&&(this.titleProperty=ve,this.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"titleStyle",{get:function(){return this.titleStyleProperty},set:function(ve){this.titleStyleProperty!==ve&&(this.titleStyleProperty=Object.assign({},this.titleStyleProperty,ve),this.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"padding",{get:function(){return this.paddingProperty},set:function(ve){g.Thickness.areEqual(this.paddingProperty,ve)||(this.paddingProperty=this.getPaddingProxy(ve),this.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"adjustedPadding",{get:function(){return H.DpiHelper.adjustThickness(this.padding)},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"debugRendering",{get:function(){return this.debugRenderingProperty},set:function(ve){this.debugRenderingProperty=ve,this.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"autoColorMode",{get:function(){return this.autoColorModeProperty},set:function(ve){this.autoColorModeProperty=ve,ve!==v.EAutoColorMode.Never&&!this.autoColorRequired?this.autoColorRequired=!0:ve===v.EAutoColorMode.Never&&(this.autoColorRequired=!1),this.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"isInvalidated",{get:function(){var ve;return(ve=this.sciChartRenderer)===null||ve===void 0?void 0:ve.isInvalidated},enumerable:!1,configurable:!0}),Ne.prototype.applyTheme=function(ve){var pe=this.previousThemeProvider;this.titleStyle.color===pe.chartTitleColor&&(this.titleStyle={color:ve.chartTitleColor}),$e.prototype.applyTheme.call(this,ve),this.renderableSeries.asArray().forEach(function(fe){return fe.applyTheme(ve)}),this.xAxes.asArray().forEach(function(fe){return fe.applyTheme(ve)}),this.yAxes.asArray().forEach(function(fe){return fe.applyTheme(ve)})},Ne.prototype.changeViewportSize=function(ve,pe){if(de.Logger.debug("changeViewportSize"),!(!ve||!pe||this.isDeleted)){var fe=ve*H.DpiHelper.PIXEL_RATIO,me=pe*H.DpiHelper.PIXEL_RATIO;this.renderSurface.viewportSize=new b.Size(fe,me),this.isCopyCanvasSurface?(this.changeMasterCanvasViewportSize(this.webAssemblyContext2D,ve,pe),this.domCanvas2D&&H.DpiHelper.setSize(this.domCanvas2D,ve,pe)):this.changeWebGLCanvasViewportSize(this.webAssemblyContext2D,ve,pe);for(var Ce=0,Ue=this.subChartsProperty;Ce<Ue.length;Ce++){var Qe=Ue[Ce];Qe.changeViewportSize(fe,me)}this.invalidateElement({force:!0})}},Ne.prototype.invalidateElement=function(ve){var pe=this,fe,me,Ce;if(de.Logger.debug("Invalidating ".concat((fe=this.id)!==null&&fe!==void 0?fe:(me=this.domChartRoot)===null||me===void 0?void 0:me.id,": force=").concat(ve==null?void 0:ve.force," isSuspended=").concat(this.isSuspended," isInitialized=").concat(this.isInitialized,". svgOnly: ").concat(ve==null?void 0:ve.svgOnly," isInvalidated: ").concat((Ce=this.sciChartRenderer)===null||Ce===void 0?void 0:Ce.isInvalidated)),!(!(ve!=null&&ve.force)&&(this.isSuspended||this.isDeleted||!this.isInitialized||!this.isWebGLContextActive))){if(ge.PerformanceDebugHelper.mark(this.sciChartRenderer.isInvalidated?ge.EPerformanceMarkType.Invalidate:ge.EPerformanceMarkType.LeadingInvalidate,{contextId:this.id}),ve!=null&&ve.svgOnly){if(this.sciChartRenderer.isInvalidated||this.sciChartRenderer.svgRenderRequestId)return;this.sciChartRenderer.svgRenderRequestId=requestAnimationFrame(function(){pe.sciChartRenderer.svgRenderRequestId=void 0,pe.sciChartRenderer.isInvalidated||pe.sciChartRenderer.renderDomOnly()})}else if(this.sciChartRenderer.svgRenderRequestId&&(cancelAnimationFrame(this.sciChartRenderer.svgRenderRequestId),this.sciChartRenderer.svgRenderRequestId=void 0),!this.sciChartRenderer.isInvalidated){var Ue=this.domCanvas2D?this.domCanvas2D.id:"undefinedCanvasId";this.sciChartRenderer.isInvalidated=this.renderSurface.invalidateElement(Ue),this.redrawRequested.raiseEvent(this.sciChartRenderer.isInvalidated)}}},Ne.prototype.doDrawingLoop=function(ve){var pe;if(!this.isDeleted){var fe=ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.DrawingLoopStart,{contextId:this.id,parentContextId:Ne.isSubSurface(this)?this.parentSurface.id:void 0,level:ge.EPerformanceDebugLevel.Verbose});ve=ve??this.renderSurface.getRenderContext(),this.currentWebGlRenderContextProperty=ve;try{var me=this.suspender.lock();try{this.autoColorRequired&&(this.themeProvider.strokePalette&&this.themeProvider.strokePalette.length>0||this.themeProvider.fillPalette&&this.themeProvider.fillPalette.length>0)&&(this.resolveAutoColors(),this.autoColorMode!==v.EAutoColorMode.Always&&(this.autoColorRequired=!1)),this.sciChartRenderer.domRenderRun||this.preRender.raiseEvent(ve)}catch(Ue){Ue!=null&&Ue.message&&console.error(Ue==null?void 0:Ue.message),console.error(Ue)}finally{me()}this.sciChartRenderer.render(ve);var Ce=this.isInvalidated;ge.PerformanceDebugHelper.mark(Ce?ge.EPerformanceMarkType.Rendered:ge.EPerformanceMarkType.FullStateRendered,{contextId:this.id}),this.rendered.raiseEvent(Ce)}catch(Ue){if(Ue.name==="BindingError")console.error(Ue),console.warn("Binding errors can occur if a previous chart using the same div id was not deleted correctly, or if you try to share data or series between charts that use different webassembly contexts."),(0,F.freeCache)(this.webAssemblyContext2D).delete();else if(this.domChartRoot)console.error("Error from chart in div ".concat(this.domChartRoot.id,":"),Ue);else throw Ue}ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.DrawingLoopEnd,{contextId:this.id,parentContextId:Ne.isSubSurface(this)?this.parentSurface.id:void 0,relatedId:(pe=fe==null?void 0:fe.detail)===null||pe===void 0?void 0:pe.relatedId,level:ge.EPerformanceDebugLevel.Verbose})}},Ne.prototype.delete=function(ve){if(ve===void 0&&(ve=!0),!this.isDeleted){this.sciChartRenderer.svgRenderRequestId&&(cancelAnimationFrame(this.sciChartRenderer.svgRenderRequestId),this.sciChartRenderer.svgRenderRequestId=void 0);for(var pe=0,fe=this.subChartsProperty;pe<fe.length;pe++){var me=fe[pe];me.delete(!0)}this.subChartsProperty=[],this.layoutManagerProperty.type===oe.ELayoutManagerType.Synchronised&&(this.layoutManagerProperty.verticalGroup&&this.layoutManagerProperty.verticalGroup.removeSurface(this),this.layoutManagerProperty.horizontalGroup&&this.layoutManagerProperty.horizontalGroup.removeSurface(this)),this.layoutManagerProperty.sciChartSurface=void 0,this.layoutManagerProperty=void 0,this.renderableSeries.asArray().forEach(function(Ce){return Ce.delete()}),this.renderableSeries.clear(!1),this.xAxes.asArray().forEach(function(Ce){return Ce.delete()}),this.yAxes.asArray().forEach(function(Ce){return Ce.delete()}),this.solidBrushCacheViewportBorder=(0,c.deleteSafe)(this.solidBrushCacheViewportBorder),this.solidBrushCacheCanvasBorder=(0,c.deleteSafe)(this.solidBrushCacheCanvasBorder),this.watermarkProperties=(0,c.deleteSafe)(this.watermarkProperties),this.watermarkPropertyPosition=(0,c.deleteSafe)(this.watermarkPropertyPosition),this.chartTitleRendererProperty=(0,c.deleteSafe)(this.chartTitleRenderer),this.sciChartRenderer=void 0,this.renderSurface=void 0,this.clearRootElement(ve),$e.prototype.delete.call(this)}},Ne.prototype.onDpiChanged=function(ve){var pe,fe;ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.DpiChange,{contextId:this.id}),de.Logger.debug("onDpiChanged"),this.renderableSeries.asArray().forEach(function(me){return me.onDpiChanged(ve)}),this.xAxes.asArray().forEach(function(me){return me.onDpiChanged()}),this.yAxes.asArray().forEach(function(me){return me.onDpiChanged()}),this.isSubSurface||this.changeViewportSize((pe=this.getMainCanvas())===null||pe===void 0?void 0:pe.clientWidth,(fe=this.getMainCanvas())===null||fe===void 0?void 0:fe.clientHeight),$e.prototype.onDpiChanged.call(this,ve)},Ne.prototype.getXAxisById=function(ve){return this.xAxes.getById(ve)},Ne.prototype.getDefaultXAxis=function(){return this.xAxes.get(0)},Ne.prototype.getYAxisById=function(ve){return this.yAxes.getById(ve)},Ne.prototype.getDefaultYAxis=function(){return this.yAxes.get(0)},Ne.prototype.updateStackedCollectionAccumulatedVectors=function(){var ve=this.renderableSeries.asArray().filter(function(pe){return pe.isCollection});ve.forEach(function(pe){return pe.updateAccumulatedVectors()})},Ne.prototype.zoomExtents=function(ve,pe,fe,me,Ce){ve===void 0&&(ve=0),pe===void 0&&(pe=l.easing.outExpo),fe===void 0&&(fe=function(){}),me===void 0&&(me=function(){return!0}),Ce===void 0&&(Ce=function(){return!0}),this.updateStackedCollectionAccumulatedVectors();var Ue=this.xAxes===void 0?0:this.xAxes.size(),Qe=this.yAxes===void 0?0:this.yAxes.size();if(Ue===0||Qe===0)throw new Error("Cannot ZoomExtents when XAxes or YAxes is undefined or empty");var it=this.zoomExtentsXInternal(ve,pe,me,fe);this.zoomExtentsYInternal(it,ve,pe,Ce,fe)},Ne.prototype.zoomExtentsX=function(ve,pe,fe){ve===void 0&&(ve=0),pe===void 0&&(pe=l.easing.outExpo),fe===void 0&&(fe=function(){return!0}),this.zoomExtentsXInternal(ve,pe,fe)},Ne.prototype.zoomExtentsY=function(ve,pe,fe){ve===void 0&&(ve=0),pe===void 0&&(pe=l.easing.outExpo),fe===void 0&&(fe=function(){return!0}),this.zoomExtentsYInternal(void 0,ve,pe,fe)},Ne.prototype.updateWatermark=function(ve,pe){var fe;if(!s.IS_TEST_ENV){this.watermarkPropertyPosition.x=ve,this.watermarkPropertyPosition.y=pe,this.watermarkProperties.m_fCanvasWidth=this.renderSurface.viewportSize.width,this.watermarkProperties.SetPosition(this.watermarkPropertyPosition);var me=(fe=this.themeProvider)===null||fe===void 0?void 0:fe.isLightBackground;this.watermarkProperties.m_bIsDarkBackground=me!==void 0?!me:!1,this.webAssemblyContext2D.SCRTSetWaterMarkProperties(this.watermarkProperties)}},Ne.prototype.setZoomState=function(ve){this.zoomStateProperty=ve},Object.defineProperty(Ne.prototype,"zoomState",{get:function(){return this.zoomStateProperty},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"viewportBorder",{get:function(){return this.viewportBorderProperty},set:function(ve){this.viewportBorderProperty=i(i({},this.viewportBorderProperty),ve),this.notifyPropertyChanged("ViewportBorder")},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"canvasBorder",{get:function(){return this.canvasBorderProperty},set:function(ve){this.canvasBorderProperty=i(i({},this.canvasBorderProperty),ve),this.notifyPropertyChanged("canvasBorder")},enumerable:!1,configurable:!0}),Ne.prototype.getSurfaceRenderOrder=function(){var ve;return(ve=this.surfaceRenderOrderProperty)!==null&&ve!==void 0?ve:this.resolvedSurfaceRenderOrder},Ne.prototype.setSurfaceRenderOrder=function(ve){this.surfaceRenderOrderProperty!=ve&&(this.surfaceRenderOrderProperty=ve,this.notifyPropertyChanged("surfaceRenderOrder"))},Ne.prototype.drawBorder=function(ve){(0,D.drawBorder)(ve,this.webAssemblyContext2D,this.solidBrushCacheViewportBorder,this.seriesViewRect,this.clipRect,this.leftViewportBorder,this.topViewportBorder,this.rightViewportBorder,this.bottomViewportBorder,this.viewportBorder.color);var pe=ve.viewportSize,fe=Ne.isSubSurface(this)?this.getSubChartRect():p.Rect.create(this.leftCanvasBorder,this.topCanvasBorder,Math.floor(pe.width-this.leftCanvasBorder-this.rightCanvasBorder),Math.floor(pe.height-this.topCanvasBorder-this.bottomCanvasBorder));(0,D.drawBorder)(ve,this.webAssemblyContext2D,this.solidBrushCacheCanvasBorder,fe,this.clipRect,this.leftCanvasBorder,this.topCanvasBorder,this.rightCanvasBorder,this.bottomCanvasBorder,this.canvasBorder.color)},Object.defineProperty(Ne.prototype,"leftViewportBorder",{get:function(){var ve,pe;return(pe=(ve=this.viewportBorder.borderLeft)!==null&&ve!==void 0?ve:this.viewportBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"rightViewportBorder",{get:function(){var ve,pe;return(pe=(ve=this.viewportBorder.borderRight)!==null&&ve!==void 0?ve:this.viewportBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"topViewportBorder",{get:function(){var ve,pe;return(pe=(ve=this.viewportBorder.borderTop)!==null&&ve!==void 0?ve:this.viewportBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"bottomViewportBorder",{get:function(){var ve,pe;return(pe=(ve=this.viewportBorder.borderBottom)!==null&&ve!==void 0?ve:this.viewportBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"leftCanvasBorder",{get:function(){var ve,pe;return(pe=(ve=this.canvasBorder.borderLeft)!==null&&ve!==void 0?ve:this.canvasBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"rightCanvasBorder",{get:function(){var ve,pe;return(pe=(ve=this.canvasBorder.borderRight)!==null&&ve!==void 0?ve:this.canvasBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"topCanvasBorder",{get:function(){var ve,pe;return(pe=(ve=this.canvasBorder.borderTop)!==null&&ve!==void 0?ve:this.canvasBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"bottomCanvasBorder",{get:function(){var ve,pe;return(pe=(ve=this.canvasBorder.borderBottom)!==null&&ve!==void 0?ve:this.canvasBorder.border)!==null&&pe!==void 0?pe:0},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"currentWebGlRenderContext",{get:function(){return this.currentWebGlRenderContextProperty},enumerable:!1,configurable:!0}),Object.defineProperty(Ne.prototype,"chartViewRect",{get:function(){var ve=this.renderSurface.viewportSize;return new p.Rect(0,0,ve.width,ve.height)},enumerable:!1,configurable:!0}),Ne.prototype.updateBackground=function(ve){var pe;this.applySciChartBackground((pe=this.background)!==null&&pe!==void 0?pe:this.themeProvider.sciChartBackground,ve)},Ne.prototype.onAnimate=function(ve){this.renderableSeries.asArray().forEach(function(Ce){return Ce.onAnimate(ve)});for(var pe=[],fe=0;fe<this.animationList.length;fe++){var me=this.animationList[fe];me.isComplete||(me.update(ve),me.isComplete||pe.push(me))}this.animationList=pe},Ne.prototype.getAnimations=function(){return this.animationList},Ne.prototype.addAnimation=function(){for(var ve=this,pe=[],fe=0;fe<arguments.length;fe++)pe[fe]=arguments[fe];pe!==void 0&&(pe.forEach(function(me){return ve.animationList.push(me)}),this.invalidateElement())},Object.defineProperty(Ne.prototype,"isRunningAnimation",{get:function(){for(var ve=0;ve<this.renderableSeries.size();ve++)if(this.renderableSeries.get(ve).isRunningAnimation)return!0;return this.animationList.some(function(pe){return!pe.isComplete})},enumerable:!1,configurable:!0}),Ne.prototype.getSeriesViewRectPadding=function(ve){if(ve===void 0&&(ve=!0),!this.seriesViewRect)throw new Error("Cannot get seriesViewRect before layout has ocurred. Move code that calls to be triggered by sciChartSurface.rendered");var pe=ve?1:H.DpiHelper.PIXEL_RATIO,fe=this.seriesViewRect,me=fe.left/pe,Ce=fe.top/pe,Ue=(this.domCanvas2D.width-fe.right)/pe,Qe=(this.domCanvas2D.height-fe.bottom)/pe;return new g.Thickness(Ce,Ue,Qe,me)},Ne.prototype.resolveAutoColors=function(){var ve=this,pe=0;if(this.autoColorFilter){var fe=this.renderableSeries.asArray().filter(function(vt){return vt.isCollection&&ve.autoColorFilter(vt)});pe=this.renderableSeries.asArray().filter(this.autoColorFilter).length-fe.length;for(var me=0,Ce=fe;me<Ce.length;me++){var Ue=Ce[me];pe+=Ue.asArray().filter(this.autoColorFilter).length}}else{var fe=this.renderableSeries.asArray().filter(function(kt){return kt.isCollection});pe=this.renderableSeries.size()-fe.length;for(var Qe=0,it=fe;Qe<it.length;Qe++){var Ue=it[Qe];pe+=Ue.size()}}for(var xt=0,wt=0;wt<this.renderableSeries.size();wt++){var $t=this.renderableSeries.get(wt);if(!(this.autoColorFilter&&!this.autoColorFilter($t)))if($t.isCollection)for(var Mt=0,rt=$t.asArray();Mt<rt.length;Mt++){var qe=rt[Mt];this.autoColorFilter&&!this.autoColorFilter(qe)||(qe.resolveAutoColors(xt,pe,this.themeProvider),xt+=1)}else $t.resolveAutoColors(xt,pe,this.themeProvider),xt+=1}},Ne.prototype.registerFont=function(ve,pe){return n(this,void 0,void 0,function(){var fe=this;return r(this,function(me){return ve.includes(".")||(ve+=".ttf"),[2,new Promise(function(Ce,Ue){var Qe=fe.webAssemblyContext2D.SCRTFileLoadCallbackInterface.implement({OnLoadComplete:function(it,xt){it?Ce(!0):(console.error("Failed to load ".concat(ve," from ").concat(pe,".  Error: ").concat(xt)),Ce(!1))}});fe.webAssemblyContext2D.SCRTRegisterFile(ve,pe,Qe)})]})})},Ne.prototype.setCoordSvgTranslation=function(ve,pe){this.xCoordSvgTrans=ve,this.yCoordSvgTrans=pe},Ne.prototype.getCoordSvgTranslation=function(){return new U.Point(this.xCoordSvgTrans,this.yCoordSvgTrans)},Ne.prototype.getOptions=function(){var ve,pe;"toJSON"in this.themeProvider?pe=this.themeProvider.toJSON():pe=this.themeProvider;var fe={id:this.id,title:this.title,titleStyle:this.titleStyle,background:this.background,canvasBorder:this.canvasBorder,heightAspect:this.heightAspect,widthAspect:this.widthAspect,layoutManager:(ve=this.layoutManager)===null||ve===void 0?void 0:ve.toJSON(),padding:this.padding,theme:pe,viewportBorder:this.viewportBorder,loader:this.loaderJson,drawSeriesBehindAxis:this.drawSeriesBehindAxis,disableAspect:this.disableAspect,createSuspended:this.createSuspended,autoColorMode:this.autoColorMode,touchAction:this.touchActionProperty,freezeWhenOutOfView:this.freezeWhenOutOfView};return fe},Ne.prototype.toJSON=function(ve){ve===void 0&&(ve=!1);var pe=this.getOptions(),fe={type:we.ESciChartSurfaceType.Default2D,surface:pe,xAxes:this.xAxes.asArray().map(function(me){return me.toJSON()}),yAxes:this.yAxes.asArray().map(function(me){return me.toJSON()}),series:this.renderableSeries.asArray().map(function(me){return me.toJSON(ve)}),modifiers:this.chartModifiers.asArray().map(function(me){return me.toJSON()}),annotations:this.annotations.asArray().map(function(me){return me.toJSON()}),onCreated:this.onCreatedName,subCharts:this.subCharts.map(function(me){return me.toJSON(!1)}),createSingle:!this.isCopyCanvasSurface};return fe},Ne.prototype.getNextState=function(ve){return ve===void 0&&(ve=!1),n(this,void 0,void 0,function(){return r(this,function(pe){switch(pe.label){case 0:return[4,this.nextStateRender({resumeBefore:!0,invalidateOnResume:!0,suspendAfter:!0})];case 1:return pe.sent(),[2,this.toJSON(ve)]}})})},Ne.prototype.validateAndLink=function(){var ve=[];return this.renderableSeries.size()>0&&(this.xAxes.size()===0&&ve.push("Chart must have at least one X axis"),this.yAxes.size()===0&&ve.push("Chart must have at least one Y axis"),this.renderableSeries.asArray().forEach(function(pe,fe){pe.linkAxes();var me=pe.xAxis;me||ve.push("".concat(pe.type,", index ").concat(fe,", id ").concat(pe.id," references xAxisId ").concat(pe.xAxisId," which does not exist on the surface"));var Ce=pe.yAxis;Ce||ve.push("".concat(pe.type,", index ").concat(fe,", id ").concat(pe.id," references yAxisId ").concat(pe.yAxisId," which does not exist on the surface")),me&&Ce&&(me.isVerticalChart&&![Ae.EAxisAlignment.Top,Ae.EAxisAlignment.Bottom].includes(Ce.axisAlignment)&&ve.push("For vertical chart (chart with X Axis alignment Left or Right) Y Axis alignment should be Top or Bottom, X Axis ID = ".concat(me.id)),(0,Ae.getIsVertical)(me.axisAlignment)&&(0,Ae.getIsVertical)(Ce.axisAlignment)&&ve.push("Both x and y axes can't have vertical alignment"),(0,Ae.getIsHorizontal)(me.axisAlignment)&&(0,Ae.getIsHorizontal)(Ce.axisAlignment)&&ve.push("Both x and y axes can't have horizontal alignment"))})),ve},Ne.prototype.getWasmId=function(){return this.webAssemblyContext2D.canvas.id},Ne.prototype.applyOptions=function(ve){$e.prototype.applyOptions.call(this,ve),ve!=null&&ve.layoutManager&&("layoutChart"in ve.layoutManager||(ve.layoutManager=(0,a.createType)(y.EBaseType.LayoutManager,ve.layoutManager.type,null,ve.layoutManager.options)),this.layoutManager=ve.layoutManager),ve!=null&&ve.padding&&(this.padding=ve.padding),ve!=null&&ve.viewportBorder&&(this.viewportBorder=ve.viewportBorder),ve!=null&&ve.canvasBorder&&(this.canvasBorder=ve.canvasBorder),ve!=null&&ve.loader&&"toJSON"in ve.loader?this.loaderJson=ve.loader.toJSON():(ve==null?void 0:ve.loader)===!1&&(this.loaderJson=!1),ve!=null&&ve.drawSeriesBehindAxis&&(this.drawSeriesBehindAxisProperty=ve.drawSeriesBehindAxis),ve!=null&&ve.autoColorMode&&(this.autoColorMode=ve.autoColorMode),ve!=null&&ve.title&&(this.title=ve.title),ve!=null&&ve.titleStyle&&(this.titleStyle=ve.titleStyle),ve!=null&&ve.background&&(this.background=ve.background),ve!=null&&ve.touchAction&&(this.touchActionProperty=ve.touchAction)},Ne.prototype.resolveSurfaceOrders=function(){var ve;if(this.isSubSurface)throw new Error("resolveSurfaceOrders should only be called on a parent surface");for(var pe=o([this],this.subCharts.filter(function(it){return it.isVisible}),!0),fe=[],me=0,Ce=pe;me<Ce.length;me++){var Ue=Ce[me];Ue.resolvedSurfaceRenderOrder=void 0;var Qe=(ve=Ue.getSurfaceRenderOrder())!==null&&ve!==void 0?ve:fe.length;Ue.resolvedSurfaceRenderOrder=Qe,fe.push(Ue)}return fe.sort(function(it,xt){return it.getSurfaceRenderOrder()-xt.getSurfaceRenderOrder()}),fe},Ne.prototype.detachChartModifier=function(ve){$e.prototype.detachChartModifier.call(this,ve),this.subCharts.forEach(function(pe){ve.onDetachSubSurface(pe)})},Ne.prototype.attachChartModifier=function(ve){$e.prototype.attachChartModifier.call(this,ve),ve.modifierType!==Re.EModifierType.MultiChart2DModifier&&(ve.setParentSurface(this),ve.invalidateParentCallback=this.invalidateElement,ve.onAttach(),this.subCharts.forEach(function(pe){ve.onAttachSubSurface(pe)}),this.invalidateElement())},Ne.prototype.applySciChartBackground=function(ve,pe){var fe=pe.getNativeContext();this.domChartRoot&&(this.domChartRoot.style.background=ve),fe&&(fe.SetClearColor(0,0,0,0),fe.Clear())},Ne.prototype.setClearAlphaParams=function(ve,pe){this.webAssemblyContext2D.SCRTSetClearAlphaParams(ve,pe)},Ne.prototype.zoomExtentsYInternal=function(ve,pe,fe,me,Ce){pe===void 0&&(pe=0),fe===void 0&&(fe=l.easing.outExpo),me===void 0&&(me=function(){return!0}),Ce===void 0&&(Ce=function(){}),this.yAxes.asArray().forEach(function(Ue){if(me(Ue)){var Qe=Ue.getWindowedYRange(ve);Qe&&Ue.animateVisibleRange(Qe,pe,fe,Ce)}})},Ne.prototype.zoomExtentsXInternal=function(ve,pe,fe,me){ve===void 0&&(ve=0),pe===void 0&&(pe=l.easing.outExpo),fe===void 0&&(fe=function(){return!0}),me===void 0&&(me=function(){});var Ce=new d.Dictionary;return this.xAxes.asArray().forEach(function(Ue){if(fe(Ue)){var Qe=Ue.getMaximumRange();Ue.animateVisibleRange(Qe,ve,pe,me),Ce.add(Ue.id,Qe)}}),Ce},Ne.prototype.onRenderSurfaceDraw=function(){var ve=this,pe,fe,me=ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.RenderSurfaceDrawStart,{contextId:this.id}),Ce=this.suspender.lock();try{this.preRenderAll.raiseEvent()}finally{Ce()}if(this.subChartsProperty.length>0){var Ue=new _.BatchRenderContext(this.webAssemblyContext2D,this.renderSurface.viewportSize,(pe=this.domCanvas2D)===null||pe===void 0?void 0:pe.id),Qe=this.resolveSurfaceOrders();Qe.forEach(function(it,xt){xt===Qe.length-1&&(Ue.doDraw=!0),it.doDrawingLoop(Ue)})}else this.doDrawingLoop();this.renderedToWebGl.raiseEvent(this.sciChartRenderer.isInvalidated),this.isCopyCanvasSurface||this.renderedToDestination.raiseEvent(this.sciChartRenderer.isInvalidated),(this.painted.handlers.length>0||ge.PerformanceDebugHelper.enableDebug)&&(0,ge.runAfterFramePaint)(function(){var it;ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.Painted,{contextId:ve.id}),ve.painted.raiseEvent((it=ve.sciChartRenderer)===null||it===void 0?void 0:it.isInvalidated)}),this.currentWebGlRenderContextProperty=(0,c.deleteSafe)(this.currentWebGlRenderContext),ge.PerformanceDebugHelper.mark(ge.EPerformanceMarkType.RenderSurfaceDrawEnd,{contextId:this.id,relatedId:(fe=me==null?void 0:me.detail)===null||fe===void 0?void 0:fe.relatedId})},Ne.prototype.detachSeries=function(ve){ve.type===m.ESeriesType.StackedColumnSeries||ve.type===m.ESeriesType.StackedMountainSeries||(this.chartModifiers.asArray().forEach(function(pe){pe.onDetachSeries(ve)}),ve.onDetach(),this.autoColorMode===v.EAutoColorMode.OnAddRemoveSeries&&(this.autoColorRequired=!0),this.invalidateElement())},Ne.prototype.attachSeries=function(ve){if(ve.type===m.ESeriesType.StackedColumnSeries){var pe=this.renderableSeries.asArray().find(function(me){return me.type===m.ESeriesType.StackedColumnCollection});if(!pe){pe=new I.StackedColumnCollection(this.webAssemblyContext2D);var fe=this.renderableSeries.asArray().findIndex(function(me){return me===ve});this.renderableSeries.insert(fe,pe)}pe.add(ve),this.renderableSeries.remove(ve,!1);return}else if(ve.type===m.ESeriesType.StackedMountainSeries||ve.type===m.ESeriesType.SmoothStackedMountainSeries){var pe=this.renderableSeries.asArray().find(function(Ce){return Ce.type===m.ESeriesType.StackedMountainCollection});if(!pe){pe=new V.StackedMountainCollection(this.webAssemblyContext2D);var fe=this.renderableSeries.asArray().findIndex(function(Ue){return Ue===ve});this.renderableSeries.insert(fe,pe)}pe.add(ve),this.renderableSeries.remove(ve,!1)}(!ve.isStacked||ve.isCollection)&&ve.onAttach(this),this.themeProviderProperty&&ve.applyTheme(this.themeProviderProperty),this.chartModifiers.asArray().forEach(function(me){me.onAttachSeries(ve)}),this.autoColorMode===v.EAutoColorMode.OnAddRemoveSeries&&(this.autoColorRequired=!0),this.invalidateElement()},Ne.prototype.detachAxis=function(ve){ve.onDetach(),this.invalidateElement()},Ne.prototype.checkAxisIdUniqueness=function(ve,pe){pe&&!this.xAxes.checkIdUniqueness(ve)&&console.error("The X axis Id ".concat(ve," is not unique")),!pe&&!this.yAxes.checkIdUniqueness(ve)&&console.error("The Y axis Id ".concat(ve," is not unique"))},Ne.prototype.attachAxis=function(ve,pe){if(ve.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachAxis, this axis has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.checkAxisIdUniqueness(ve.id,pe);var fe=!1;pe&&!this.xAxes.asArray().some(function(me){return me.isPrimaryAxis})&&(fe=!0),!pe&&!this.yAxes.asArray().some(function(me){return me.isPrimaryAxis})&&(fe=!0),ve.onAttach(this,pe,fe),this.themeProviderProperty&&ve.applyTheme(this.themeProviderProperty),ve.invalidateParentCallback=this.invalidateElement,this.invalidateElement()},Ne.prototype.onAttachSubSurface=function(ve){this.chartModifiers.asArray().forEach(function(pe){pe.onAttachSubSurface(ve)})},Ne.prototype.onDetachSubSurface=function(ve){this.chartModifiers.asArray().forEach(function(pe){pe.onDetachSubSurface(ve)})},Object.defineProperty(Ne.prototype,"drawSeriesBehindAxis",{get:function(){return this.drawSeriesBehindAxisProperty},set:function(ve){this.drawSeriesBehindAxisProperty=ve,this.invalidateElement()},enumerable:!1,configurable:!0}),Ne})(G.SciChartSurfaceBase);t.SciChartSurface=ke})(cp)),cp}var _F={},Qve;function BFe(){if(Qve)return _F;Qve=1,Object.defineProperty(_F,"__esModule",{value:!0}),_F.AnnotationClickEventArgs=void 0;var t=(function(){function e(i,n,r){this.sender=i,this.mouseArgs=n,this.relativeCoords=r}return e})();return _F.AnnotationClickEventArgs=t,_F}var _9={},eye;function II(){return eye||(eye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAnnotationClippingMode=void 0,(function(e){e.SeriesViewRect="SeriesViewRect",e.SubChart="SubChart",e.Chart="Chart"})(t.EAnnotationClippingMode||(t.EAnnotationClippingMode={}))})(_9)),_9}var PF={},tye;function jFe(){if(tye)return PF;tye=1,Object.defineProperty(PF,"__esModule",{value:!0}),PF.AnnotationDragDeltaEventArgs=void 0;var t=(function(){function e(i){this.sender=i}return e})();return PF.AnnotationDragDeltaEventArgs=t,PF}var CF={},rye;function gl(){if(rye)return CF;rye=1,Object.defineProperty(CF,"__esModule",{value:!0}),CF.annotationHelpers=void 0;var t=an(),e=Zi(),i=Ca(),n=function(s,l,u){var c=document.createRange().createContextualFragment(s);return u?(l.insertBefore(c,u),u.previousElementSibling):(l.appendChild(c),l.lastChild)},r=function(s){var l="http://www.w3.org/2000/svg",u=document.createElementNS(l,"svg"),c=document.createElementNS(l,"g"),d=document.createElementNS(l,"line");c.appendChild(d);var f=void 0;return s&&(f=document.createElementNS(l,"g"),f.setAttribute("class","scichart__line-annotation-labels"),f.setAttribute("pointer-events","none"),c.appendChild(f)),u.appendChild(c),{svgElement:u,svgLine:d,svgLabelsContainer:f}},o=function(s,l,u,c,d){var f={x:s,y:l},h=d?{x:s,y:c}:{x:u,y:l},p=d?{x:u,y:l}:{x:s,y:c},g={x:u,y:c};return{x1y1:f,x2y1:h,x1y2:p,x2y2:g}},a=function(s,l,u,c,d,f){var h=s.getTransform(l),p=(0,t.getVector2)(u);if(l){var g=c!==i.ECoordinateMode.Pixel?d*e.DpiHelper.PIXEL_RATIO:d;h.TransformPoint(f,g,p)}else{var g=c!==i.ECoordinateMode.Pixel?d:d/e.DpiHelper.PIXEL_RATIO;h.TransformPoint(f,g,p)}var v=p.x,y=p.y;return{x:v,y}};return CF.annotationHelpers={createSvg:n,calcNewApex:o,convertPolarToCartesian:a,createSvgLineAndLabel:r},CF}var TF={},iye;function VFe(){if(iye)return TF;iye=1,Object.defineProperty(TF,"__esModule",{value:!0}),TF.AnnotationHoverEventArgs=void 0;var t=$i(),e=Zi(),i=(function(){function n(r){var o=r.sender,a=r.mouseArgs,s=r.isHovered;this.sender=o,this.mouseArgs=a,this.isHovered=s}return n.prototype.getRelativeCoordinates=function(){var r=this.sender.getAdornerAnnotationBorders(!0),o=this.mouseArgs.mousePoint.x/e.DpiHelper.PIXEL_RATIO,a=this.mouseArgs.mousePoint.y/e.DpiHelper.PIXEL_RATIO;return new t.Point(o-r.x1,a-r.y1)},n})();return TF.AnnotationHoverEventArgs=i,TF}var P9={},nye;function jl(){return nye||(nye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DISTANCE_TO_LINE=t.ADORNER_GRIP_RADIUS=t.PROPERTY=void 0,(function(e){e.ADORNER_TEMPLATE="ADORNER_TEMPLATE",e.ANNOTATION_CANVAS="ANNOTATION_CANVAS",e.RESIZE_DIRECTIONS="RESIZE_DIRECTIONS",e.AXIS_LABELS_FILL="AXIS_LABELS_FILL",e.AXIS_LABELS_STROKE="AXIS_LABELS_STROKE",e.AXIS_FONT_FAMILY="AXIS_FONT_FAMILY",e.AXIS_FONT_SIZE="AXIS_FONT_SIZE",e.BACKGROUND_COLOR="BACKGROUND_COLOR",e.CENTER_X="CENTER_X",e.CENTER_Y="CENTER_Y",e.CLASS_NAME="CLASS_NAME",e.COLOR="COLOR",e.CONTAINER_BACKGROUND="CONTAINER_BACKGROUND",e.CLIPPING="CLIPPING",e.FILL="FILL",e.FONT_FAMILY="FONT_FAMILY",e.FONT_SIZE="FONT_SIZE",e.FONT_STYLE="FONT_STYLE",e.FONT_WEIGHT="FONT_WEIGHT",e.FORMATTED_VALUE="FORMATTED_VALUE",e.HEIGHT="HEIGHT",e.HORIZONTAL_ANCHOR_POINT="HORIZONTAL_ANCHOR_POINT",e.IMAGE="IMAGE",e.IMAGE_HEIGHT="IMAGE_HEIGHT",e.IMAGE_WIDTH="IMAGE_WIDTH",e.IS_EDITABLE="IS_EDITABLE",e.IS_LINE_MODE="IS_LINE_MODE",e.IS_HIDDEN="IS_HIDDEN",e.IS_SELECTED="IS_SELECTED",e.IS_HOVERED="IS_HOVERED",e.LABEL_PLACEMENT="LABEL_PLACEMENT",e.LABEL_VALUE="LABEL_VALUE",e.MINIMUM_WIDTH="MINIMUM_WIDTH",e.MINIMUM_HEIGHT="MINIMUM_HEIGHT",e.OPACITY="OPACITY",e.PADDING="PADDING",e.PARENT_SURFACE="PARENT_SURFACE",e.SERIES_INFO="SERIES_INFO",e.SERIES_INFOS="SERIES_INFOS",e.STROKE="STROKE",e.STROKE_THICKNESS="STROKE_THICKNESS",e.STROKE_DASH_ARRAY="STROKE_DASH_ARRAY",e.SHOW_LABEL="SHOW_LABEL",e.TEXT="TEXT",e.TEXT_STROKE="TEXT_STROKE",e.TEXT_STYLE="TEXT_STYLE",e.TITLE="TITLE",e.TOOLTIP_LEGEND_OFFSET_X="TOOLTIP_LEGEND_OFFSET_X",e.TOOLTIP_LEGEND_OFFSET_Y="TOOLTIP_LEGEND_OFFSET_Y",e.TOOLTIP_LEGEND_TEMPLATE="TOOLTIP_LEGEND_TEMPLATE",e.TOOLTIP_DATA_TEMPLATE="TOOLTIP_DATA_TEMPLATE",e.TOOLTIP_SVG_TEMPLATE="TOOLTIP_SVG_TEMPLATE",e.VERTICAL_ANCHOR_POINT="VERTICAL_ANCHOR_POINT",e.X1="X1",e.X2="X2",e.XAXIS_ID="XAXIS_ID",e.X_COORDINATE_MODE="X_COORDINATE_MODE",e.X_COORD_SHIFT="X_COORD_SHIFT",e.Y1="Y1",e.Y2="Y2",e.YAXIS_ID="YAXIS_ID",e.Y_COORDINATE_MODE="Y_COORDINATE_MODE",e.Y_COORD_SHIFT="Y_COORD_SHIFT",e.PLACEMENT_DIV_ID="PLACEMENT_DIV_ID",e.ROTATION="ROTATION",e.ADORNER_STROKE="ADORNER_STROKE",e.ADORNER_FILL="ADORNER_FILL",e.ADORNER_RADIUS="ADORNER_RADIUS",e.SELECTION_STROKE="SELECTION_STROKE",e.SELECTION_DELTA="SELECTION_DELTA",e.SELECTION_THICKNESS="SELECTION_THICKNESS",e.DRAGPOINTS="DRAGPOINTS",e.MULTILINE_ALIGNMENT="MULTILINE_ALIGNMENT",e.WRAP_TO="WRAP_TO",e.LINE_SPACING="LINE_SPACING",e.SCALE="SCALE",e.OUTLINE="OUTLINE",e.RADIUS="RADIUS",e.INNER_RADIUS="INNER_RADIUS",e.ARC_COORDINATE_MODE="ARC_COORDINATE_MODE",e.VIEW_BOX_SIZE="VIEW_BOX_SIZE",e.SVG_STRING="SVG_STRING",e.ARROW_HEAD_LENGTH="ARROW_HEAD_LENGTH",e.ARROW_HEAD_WIDTH="ARROW_HEAD_WIDTH",e.ARROW_HEAD_DEPTH="ARROW_HEAD_DEPTH",e.ARROW_HEAD_STROKE_THICKNESS="ARROW_HEAD_STROKE_THICKNESS",e.ARROW_HEAD_COLOR="ARROW_HEAD_COLOR",e.ARROW_HEAD_POSITION="ARROW_HEAD_POSITION",e.IS_ARROW_HEAD_RELATIVE="IS_ARROW_HEAD_RELATIVE",e.SURFACE_RENDER_ORDER="SURFACE_RENDER_ORDER",e.RENDER_LAYER="RENDER_LAYER",e.LABEL_PADDING="LABEL_PADDING",e.LABEL_CORNER_RADIUS="LABEL_CORNER_RADIUS"})(t.PROPERTY||(t.PROPERTY={})),t.ADORNER_GRIP_RADIUS=10,t.DISTANCE_TO_LINE=10})(P9)),P9}var C9={},oye;function Qa(){return oye||(oye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAnnotationType=t.EAnnotationLayer=void 0,(function(e){e.AboveChart="AboveChart",e.BelowChart="BelowChart",e.Background="Background"})(t.EAnnotationLayer||(t.EAnnotationLayer={})),(function(e){e.SVG="SVG",e.RenderContextBoxAnnotation="RenderContextBoxAnnotation",e.RenderContextLineAnnotation="RenderContextLineAnnotation",e.RenderContextHorizontalLineAnnotation="RenderContextHorizontalLineAnnotation",e.RenderContextVerticalLineAnnotation="RenderContextVerticalLineAnnotation",e.RenderContextLineArrowAnnotation="RenderContextLineArrowAnnotation",e.RenderContextArcAnnotation="RenderContextArcAnnotation",e.RenderContextPolarArcAnnotation="RenderContextPolarArcAnnotation",e.RenderContextAxisMarkerAnnotation="RenderContextAxisMarkerAnnotation",e.RenderContextNativeTextAnnotation="RenderContextNativeTextAnnotation",e.RenderContextCustomAnnotation="RenderContextCustomAnnotation",e.SVGTextAnnotation="SVGTextAnnotation",e.SVGCustomAnnotation="SVGCustomAnnotation",e.SVGPolarPointerAnnotation="SVGPolarPointerAnnotation",e.HtmlCustomAnnotation="HtmlCustomAnnotation",e.HtmlTextAnnotation="HtmlTextAnnotation",e.SvgLineAnnotation="SvgLineAnnotation"})(t.EAnnotationType||(t.EAnnotationType={}))})(C9)),C9}var aye;function Ca(){return aye||(aye=1,(function(t){var e=VN&&VN.__extends||(function(){var D=function(F,I){return D=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(V,z){V.__proto__=z}||function(V,z){for(var G in z)Object.prototype.hasOwnProperty.call(z,G)&&(V[G]=z[G])},D(F,I)};return function(F,I){if(typeof I!="function"&&I!==null)throw new TypeError("Class extends value "+String(I)+" is not a constructor or null");D(F,I);function V(){this.constructor=F}F.prototype=I===null?Object.create(I):(V.prototype=I.prototype,new V)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.AnnotationBase=t.ECoordinateMode=t.EDraggingGripPoint=void 0;var i=mo(),n=fo(),r=ps(),o=ci(),a=fW(),s=$i(),l=Rn(),u=ga(),c=QD(),d=vs(),f=pl(),h=hl(),p=Eo(),g=An(),v=Rg(),y=Sn(),m=Zi(),b=BFe(),S=II(),_=jFe(),C=gl(),P=VFe(),x=jl(),E=Qa(),A;(function(D){D.x1y1="x1y1",D.x1y2="x1y2",D.x2y2="x2y2",D.x2y1="x2y1",D.x3y3="x3y3",D.Body="Body"})(A=t.EDraggingGripPoint||(t.EDraggingGripPoint={}));var R;(function(D){D.DataValue="DataValue",D.Pixel="Pixel",D.Relative="Relative"})(R=t.ECoordinateMode||(t.ECoordinateMode={}));var M=(function(D){e(F,D);function F(I){var V=this,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e,Ne,ve,pe,fe,me,Ce,Ue;return V=D.call(this)||this,V.surfaceTypes=[d.ESurfaceType.SciChartSurfaceType],V.prevIsSelected=!0,V.annotationBorders={x1:0,x2:0,y1:0,y2:0},V.typeMap=new Map,V.isHiddenProperty=!1,V.annotationsGripsStrokeProperty=y.SciChartSurfaceBase.DEFAULT_THEME.annotationsGripsBorderBrush,V.annotationsGripsFillProperty=y.SciChartSurfaceBase.DEFAULT_THEME.annotationsGripsBackgroundBrush,V.annotationsGripsRadiusProperty=x.ADORNER_GRIP_RADIUS,V.selectionBoxStrokeProperty=y.SciChartSurfaceBase.DEFAULT_THEME.annotationSelectionStroke,V.selectionBoxDeltaProperty=1.5,V.selectionBoxThicknessProperty=6,V.dragPointsProperty=[A.Body,A.x1y1,A.x2y2,A.x2y1,A.x1y2],V.clippingProperty=S.EAnnotationClippingMode.SeriesViewRect,V.adornerClippingProperty=S.EAnnotationClippingMode.Chart,V.surfaceRenderOrderProperty=void 0,V.renderOrderProperty=void 0,V.annotationLayerProperty=E.EAnnotationLayer.AboveChart,V.isEditableProperty=!1,V.xCoordinateModeProperty=R.DataValue,V.yCoordinateModeProperty=R.DataValue,V.isSelectedProperty=!1,V.isHoveredProperty=!1,V.resizeDirectionsProperty=f.EXyDirection.XyDirection,V.id=(z=I==null?void 0:I.id)!==null&&z!==void 0?z:(0,h.generateGuid)(),V.dragStarted=new r.EventHandler,V.dragEnded=new r.EventHandler,V.dragDelta=new r.EventHandler,V.selectedChanged=new r.EventHandler,V.clicked=new r.EventHandler,V.hovered=new r.EventHandler,V.annotationLayerProperty=(G=I==null?void 0:I.annotationLayer)!==null&&G!==void 0?G:V.annotationLayerProperty,V.resizeDirectionsProperty=(H=I==null?void 0:I.resizeDirections)!==null&&H!==void 0?H:V.resizeDirectionsProperty,V.isEditableProperty=(U=I==null?void 0:I.isEditable)!==null&&U!==void 0?U:V.isEditableProperty,V.isHiddenProperty=(k=I==null?void 0:I.isHidden)!==null&&k!==void 0?k:V.isHiddenProperty,V.x1Property=(X=I==null?void 0:I.x1)!==null&&X!==void 0?X:V.x1Property,V.y1Property=(W=I==null?void 0:I.y1)!==null&&W!==void 0?W:V.y1Property,V.x2Property=(Y=I==null?void 0:I.x2)!==null&&Y!==void 0?Y:V.x2Property,V.y2Property=(te=I==null?void 0:I.y2)!==null&&te!==void 0?te:V.y2Property,V.xAxisIdProperty=(oe=I==null?void 0:I.xAxisId)!==null&&oe!==void 0?oe:V.xAxisIdProperty,V.yAxisIdProperty=(de=I==null?void 0:I.yAxisId)!==null&&de!==void 0?de:V.yAxisIdProperty,V.xCoordinateModeProperty=(ge=I==null?void 0:I.xCoordinateMode)!==null&&ge!==void 0?ge:V.xCoordinateModeProperty,V.yCoordinateModeProperty=(Ee=I==null?void 0:I.yCoordinateMode)!==null&&Ee!==void 0?Ee:V.yCoordinateModeProperty,V.isSelectedProperty=(Re=I==null?void 0:I.isSelected)!==null&&Re!==void 0?Re:V.isSelectedProperty,V.opacityProperty=(Ae=I==null?void 0:I.opacity)!==null&&Ae!==void 0?Ae:1,V.annotationsGripsStrokeProperty=(Pe=I==null?void 0:I.annotationsGripsStroke)!==null&&Pe!==void 0?Pe:V.annotationsGripsStrokeProperty,V.annotationsGripsFillProperty=(we=I==null?void 0:I.annotationsGripsFill)!==null&&we!==void 0?we:V.annotationsGripsFillProperty,V.annotationsGripsRadiusProperty=(Te=I==null?void 0:I.annotationsGripsRadius)!==null&&Te!==void 0?Te:V.annotationsGripsRadius,V.selectionBoxStroke=(ke=I==null?void 0:I.selectionBoxStroke)!==null&&ke!==void 0?ke:V.selectionBoxStrokeProperty,V.selectionBoxDelta=($e=I==null?void 0:I.selectionBoxDelta)!==null&&$e!==void 0?$e:V.selectionBoxDeltaProperty,V.selectionBoxThickness=(Ne=I==null?void 0:I.selectionBoxThickness)!==null&&Ne!==void 0?Ne:V.selectionBoxThicknessProperty,V.dragPointsProperty=(ve=I==null?void 0:I.dragPoints)!==null&&ve!==void 0?ve:V.dragPointsProperty,V.clippingProperty=(pe=I==null?void 0:I.clipping)!==null&&pe!==void 0?pe:V.clippingProperty,V.surfaceRenderOrderProperty=(fe=I==null?void 0:I.surfaceRenderOrder)!==null&&fe!==void 0?fe:V.surfaceRenderOrderProperty,V.renderLayerProperty=(me=I==null?void 0:I.renderLayer)!==null&&me!==void 0?me:V.renderLayerProperty,V.renderOrderProperty=(Ce=I==null?void 0:I.renderOrder)!==null&&Ce!==void 0?Ce:V.renderOrderProperty,V.renderNextToProperty=(Ue=I==null?void 0:I.renderNextTo)!==null&&Ue!==void 0?Ue:V.renderNextToProperty,I!=null&&I.onDragStarted&&(typeof I.onDragStarted=="string"?(V.typeMap.set("onDragStarted",I.onDragStarted),V.dragStarted.subscribe((0,i.getFunction)(u.EBaseType.OptionFunction,I.onDragStarted))):V.dragStarted.subscribe(I.onDragStarted)),I!=null&&I.onDragEnded&&(typeof I.onDragEnded=="string"?(V.typeMap.set("onDragEnded",I.onDragEnded),V.dragEnded.subscribe((0,i.getFunction)(u.EBaseType.OptionFunction,I.onDragEnded))):V.dragEnded.subscribe(I.onDragEnded)),I!=null&&I.onDrag&&(typeof I.onDrag=="string"?(V.typeMap.set("onDrag",I.onDrag),V.dragDelta.subscribe((0,i.getFunction)(u.EBaseType.OptionFunction,I.onDrag))):V.dragDelta.subscribe(I.onDrag)),I!=null&&I.onClick&&(typeof I.onClick=="string"?(V.typeMap.set("onClick",I.onClick),V.clicked.subscribe((0,i.getFunction)(u.EBaseType.OptionFunction,I.onClick))):V.clicked.subscribe(I.onClick)),I!=null&&I.onHover&&(typeof I.onHover=="string"?(V.typeMap.set("onHover",I.onHover),V.hovered.subscribe((0,i.getFunction)(u.EBaseType.OptionFunction,I.onHover))):V.hovered.subscribe(I.onHover)),V}return Object.defineProperty(F.prototype,"annotationLayer",{get:function(){return this.annotationLayerProperty},set:function(I){this.annotationLayerProperty!==I&&(this.annotationLayerProperty=I,this.notifyPropertyChanged(x.PROPERTY.ANNOTATION_CANVAS))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"adornerDraggingPoint",{get:function(){return this.adornerDraggingPointProperty},set:function(I){var V;this.adornerDraggingPointProperty!==I&&(this.adornerDraggingPointProperty=I,I&&((V=this.dragStarted)===null||V===void 0||V.raiseEvent()))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},set:function(I){this.parentSurfaceProperty!==I&&(this.parentSurfaceProperty=I,this.notifyPropertyChanged(x.PROPERTY.PARENT_SURFACE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isEditable",{get:function(){return this.isEditableProperty},set:function(I){this.isEditableProperty!==I&&(this.isEditableProperty=I,this.notifyPropertyChanged(x.PROPERTY.IS_EDITABLE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isHidden",{get:function(){return this.isHiddenProperty},set:function(I){this.isHiddenProperty!==I&&(this.isHiddenProperty=I,this.notifyPropertyChanged(x.PROPERTY.IS_HIDDEN))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isVisible",{get:function(){return!this.isHidden},set:function(I){this.isHidden=!I},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"xCoordinateMode",{get:function(){return this.xCoordinateModeProperty},set:function(I){this.xCoordinateModeProperty!==I&&(this.xCoordinateModeProperty=I,this.notifyPropertyChanged(x.PROPERTY.X_COORDINATE_MODE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"yCoordinateMode",{get:function(){return this.yCoordinateModeProperty},set:function(I){this.yCoordinateModeProperty!==I&&(this.yCoordinateModeProperty=I,this.notifyPropertyChanged(x.PROPERTY.Y_COORDINATE_MODE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"x1",{get:function(){return this.x1Property},set:function(I){this.x1Property!==I&&(this.x1Property=I,this.notifyPropertyChanged(x.PROPERTY.X1))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"x2",{get:function(){return this.x2Property},set:function(I){this.x2Property!==I&&(this.x2Property=I,this.notifyPropertyChanged(x.PROPERTY.X2))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"y1",{get:function(){return this.y1Property},set:function(I){this.y1Property!==I&&(this.y1Property=I,this.notifyPropertyChanged(x.PROPERTY.Y1))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"y2",{get:function(){return this.y2Property},set:function(I){this.y2Property!==I&&(this.y2Property=I,this.notifyPropertyChanged(x.PROPERTY.Y2))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"xAxisId",{get:function(){return this.xAxisIdProperty},set:function(I){this.xAxisIdProperty!==I&&(this.xAxisIdProperty=I,this.xAxisProperty=void 0,this.notifyPropertyChanged(x.PROPERTY.XAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"yAxisId",{get:function(){return this.yAxisIdProperty},set:function(I){this.yAxisIdProperty!==I&&(this.yAxisIdProperty=I,this.yAxisProperty=void 0,this.notifyPropertyChanged(x.PROPERTY.YAXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"xAxis",{get:function(){return this.xAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"yAxis",{get:function(){return this.yAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isVerticalChart",{get:function(){var I;return(I=this.xAxis)===null||I===void 0?void 0:I.isVerticalChart},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"resizeDirections",{get:function(){return this.resizeDirectionsProperty},set:function(I){this.resizeDirectionsProperty!==I&&(this.resizeDirectionsProperty=I,this.notifyPropertyChanged(x.PROPERTY.RESIZE_DIRECTIONS))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isSelected",{get:function(){return this.isSelectedProperty},set:function(I){this.isSelectedProperty!==I&&(this.isSelectedProperty=I,this.selectedChanged.raiseEvent(this.isSelectedProperty),this.notifyPropertyChanged(x.PROPERTY.IS_SELECTED))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isHovered",{get:function(){return this.isHoveredProperty},set:function(I){this.isHoveredProperty!==I&&(this.isHoveredProperty=I,this.hovered.raiseEvent(new P.AnnotationHoverEventArgs({sender:this,mouseArgs:void 0,isHovered:I})),this.notifyPropertyChanged(x.PROPERTY.IS_HOVERED))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"annotationsGripsStroke",{get:function(){return this.annotationsGripsStrokeProperty},set:function(I){this.annotationsGripsStrokeProperty!==I&&(this.annotationsGripsStrokeProperty=I,this.notifyPropertyChanged(x.PROPERTY.ADORNER_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"annotationsGripsFill",{get:function(){return this.annotationsGripsFillProperty},set:function(I){this.annotationsGripsFillProperty!==I&&(this.annotationsGripsFillProperty=I,this.notifyPropertyChanged(x.PROPERTY.ADORNER_FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"annotationsGripsRadius",{get:function(){return this.annotationsGripsRadiusProperty},set:function(I){this.annotationsGripsRadiusProperty!==I&&(this.annotationsGripsRadiusProperty=I,this.notifyPropertyChanged(x.PROPERTY.ADORNER_RADIUS))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"selectionBoxStroke",{get:function(){return this.selectionBoxStrokeProperty},set:function(I){this.selectionBoxStrokeProperty!==I&&(this.selectionBoxStrokeProperty=I,this.notifyPropertyChanged(x.PROPERTY.SELECTION_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"selectionBoxDelta",{get:function(){return this.selectionBoxDeltaProperty},set:function(I){this.selectionBoxDeltaProperty!==I&&(this.selectionBoxDeltaProperty=I,this.notifyPropertyChanged(x.PROPERTY.SELECTION_DELTA))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"selectionBoxThickness",{get:function(){return this.selectionBoxThicknessProperty},set:function(I){this.selectionBoxThicknessProperty!==I&&(this.selectionBoxThicknessProperty=I,this.notifyPropertyChanged(x.PROPERTY.SELECTION_DELTA))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"isDraggingStarted",{get:function(){return!!this.adornerDraggingPoint},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"opacity",{get:function(){return this.opacityProperty},set:function(I){this.opacityProperty!==I&&(this.opacityProperty=I,this.notifyPropertyChanged(x.PROPERTY.OPACITY))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"clipping",{get:function(){return this.clippingProperty},set:function(I){this.clippingProperty!==I&&(this.clippingProperty=I,this.notifyPropertyChanged(x.PROPERTY.CLIPPING))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"adornerClipping",{get:function(){return this.adornerClippingProperty},set:function(I){this.adornerClippingProperty!==I&&(this.adornerClippingProperty=I,this.notifyPropertyChanged(x.PROPERTY.CLIPPING))},enumerable:!1,configurable:!0}),Object.defineProperty(F.prototype,"svgAdornerRoot",{get:function(){return this.svgAdornerRootProperty},enumerable:!1,configurable:!0}),F.prototype.onAttach=function(I){if(!this.surfaceTypes.includes(I.surfaceType))throw I.hasInvalidState=!0,new Error("Annotation's type does not match SciChartSurface type. Please check ".concat(this.constructor.name,".surfaceTypes property to match ").concat(I.constructor.name,".surfaceType"));this.linkAxes(),this.svgAdornerRootProperty=I.domSvgAdornerLayer,this.isSelected&&(this.parentSurface.adornerLayer.selectedAnnotation=this)},F.prototype.onDetach=function(){this.isSelected&&(this.isSelected=!1,this.parentSurface.adornerLayer.deselectAnnotation(this)),this.isHovered&&(this.isHovered=!1),this.selectedChanged.unsubscribeAll(),this.deleteAdorner(),this.svgAdornerRootProperty=void 0},Object.defineProperty(F.prototype,"dragPoints",{get:function(){return this.dragPointsProperty},set:function(I){this.dragPointsProperty=I,this.notifyPropertyChanged(x.PROPERTY.DRAGPOINTS)},enumerable:!1,configurable:!0}),F.prototype.checkIsWithinBounds=function(I){var V=(0,g.translateFromCanvasToSeriesViewRect)(I.mousePoint,this.parentSurface.seriesViewRect,!0);return V?this.checkIsClickedOnAnnotationInternal(V.x,V.y):!1},F.prototype.hover=function(I){var V=I.args,z=I.notifyPositionUpdate,G=I.notifyOutEvent,H=I.isHovered!==void 0?I.isHovered:this.checkIsWithinBounds(V),U=this.isHovered;this.isHoveredProperty=H;var k=H&&!U,X=U&&!H&&G,W=H&&U&&z;(k||X||W)&&this.hovered.raiseEvent(new P.AnnotationHoverEventArgs({sender:this,mouseArgs:V,isHovered:H})),H!==U&&this.notifyPropertyChanged(x.PROPERTY.IS_HOVERED)},F.prototype.click=function(I,V){var z=(0,g.translateFromCanvasToSeriesViewRect)(I.mousePoint,this.parentSurface.seriesViewRect,!0);if(!z)return!1;var G=this.checkIsPointWithinClipArea(I.mousePoint);if(G&&this.checkIsClickedOnAnnotationInternal(z.x,z.y)){var H=this.getAdornerAnnotationBorders(!0),U=I.mousePoint.x/m.DpiHelper.PIXEL_RATIO,k=I.mousePoint.y/m.DpiHelper.PIXEL_RATIO,X=new s.Point(U-H.x1,k-H.y1);return this.isSelected=V,this.clicked.raiseEvent(new b.AnnotationClickEventArgs(this,I,X)),this.isSelected}else this.isSelected=!1;return this.isSelected},F.prototype.clickToSelect=function(I){var V=(0,g.translateFromCanvasToSeriesViewRect)(I.mousePoint,this.parentSurface.seriesViewRect,!0);return V?(this.isSelected=this.checkIsClickedOnAnnotationInternal(V.x,V.y),this.isSelected):!1},F.prototype.calcDragDistance=function(I){},F.prototype.onDragStarted=function(I){return!1},F.prototype.checkIsClickedOnAnnotation=function(I,V){var z=(0,g.translateFromCanvasToSeriesViewRect)(new s.Point(I*m.DpiHelper.PIXEL_RATIO,V*m.DpiHelper.PIXEL_RATIO),this.parentSurface.seriesViewRect,!0);return z?this.checkIsClickedOnAnnotationInternal(z.x,z.y):!1},F.prototype.checkIsPointWithinClipArea=function(I){var V=this.getClippingRect(this.adornerClipping,this.parentSurface.seriesViewRect,this.parentSurface.viewRect,this.parentSurface.chartViewRect),z=V.left,G=V.bottom,H=V.right,U=V.top;return(0,p.testIsInBounds)(I.x,I.y,z,G,H,U)},F.prototype.onDragAdorner=function(I){var V=this.getValuesFromCoordinates(I.mousePoint,!0);V&&this.calcDragDistance(V),this.dragDelta.raiseEvent(new _.AnnotationDragDeltaEventArgs(this))},F.prototype.onDragEnded=function(){var I;(I=this.dragEnded)===null||I===void 0||I.raiseEvent(),this.adornerDraggingPoint=void 0,this.prevValue=void 0},F.prototype.onDpiChanged=function(I){},F.prototype.suspendInvalidate=function(){this.invalidateState={isHidden:this.isHidden,x1:this.x1,y1:this.y1}},F.prototype.resumeInvalidate=function(){this.invalidateState&&((this.isHidden!==this.invalidateState.isHidden||this.x1!==this.invalidateState.x1||this.y1!==this.invalidateState.y1)&&this.invalidateParentCallback&&this.invalidateParentCallback(),this.invalidateState=void 0)},F.prototype.getSurfaceRenderOrder=function(){var I,V,z;return(I=this.surfaceRenderOrderProperty)!==null&&I!==void 0?I:(z=(V=this.parentSurface)===null||V===void 0?void 0:V.getSurfaceRenderOrder)===null||z===void 0?void 0:z.call(V)},F.prototype.setSurfaceRenderOrder=function(I){this.surfaceRenderOrderProperty!=I&&(this.surfaceRenderOrderProperty=I,this.notifyPropertyChanged(x.PROPERTY.SURFACE_RENDER_ORDER))},F.prototype.getRenderLayer=function(){if(this.renderLayerProperty)return this.renderLayerProperty;switch(this.annotationLayer){case E.EAnnotationLayer.AboveChart:return c.EDefaultRenderLayer.AnnotationsAboveSeriesLayer;case E.EAnnotationLayer.BelowChart:return c.EDefaultRenderLayer.AnnotationsBelowSeriesLayer;case E.EAnnotationLayer.Background:return c.EDefaultRenderLayer.Background;default:throw new Error("Invalid annotationLayer ".concat(this.annotationLayer,"!"))}},F.prototype.setRenderLayer=function(I){this.renderLayerProperty!=I&&(this.renderLayerProperty=I,this.notifyPropertyChanged(x.PROPERTY.RENDER_LAYER))},F.prototype.getRenderOrder=function(){return this.renderOrderProperty},F.prototype.setRenderOrder=function(I){this.renderOrderProperty!=I&&(this.renderOrderProperty=I,this.notifyPropertyChanged(x.PROPERTY.RENDER_LAYER))},F.prototype.setRenderNextTo=function(I,V){V===void 0&&(V=0),I===void 0?this.renderNextToProperty=void 0:this.renderNextToProperty={renderable:I,offset:V}},F.prototype.getRenderNextTo=function(){return this.renderNextToProperty},F.prototype.toJSON=function(){var I=this.getRenderNextTo(),V=I&&{renderable:typeof I.renderable=="string"?I.renderable:I.renderable.id,offset:I.offset},z={id:this.id,annotationLayer:this.annotationLayer,isEditable:this.isEditable,isHidden:this.isHidden,isSelected:this.isSelected,onDrag:this.typeMap.get("onDrag"),onDragEnded:this.typeMap.get("onDragEnded"),onDragStarted:this.typeMap.get("onDragStarted"),onClick:this.typeMap.get("onClick"),onHover:this.typeMap.get("onHover"),opacity:this.opacity,resizeDirections:this.resizeDirections,x1:this.x1Property,x2:this.x2Property,y1:this.y1Property,y2:this.y2Property,xAxisId:this.xAxisId,yAxisId:this.yAxisId,xCoordinateMode:this.xCoordinateMode,yCoordinateMode:this.yCoordinateMode,surfaceRenderOrder:this.surfaceRenderOrderProperty,renderLayer:this.getRenderLayer(),renderOrder:this.getRenderOrder(),renderNextTo:V,annotationsGripsStroke:this.annotationsGripsStroke,annotationsGripsFill:this.annotationsGripsFill,annotationsGripsRadius:this.annotationsGripsRadius,selectionBoxStroke:this.selectionBoxStroke,selectionBoxDelta:this.selectionBoxDelta,selectionBoxThickness:this.selectionBoxThickness,dragPoints:this.dragPointsProperty,clipping:this.clippingProperty};return{type:this.type,options:z}},F.prototype.getAnnotationBorders=function(I,V){var z,G;if(I===void 0&&(I=!1),V===void 0&&(V=!1),!I&&!V)return this.annotationBorders;var H=this.annotationBorders,U=H.x1,k=H.x2,X=H.y1,W=H.y2,Y=V?this.selectionBoxDelta:0;return I?(k<U?(z=[k-Y,U+Y],U=z[0],k=z[1]):(U-=Y,k+=Y),W<X?(G=[W-Y,X+Y],X=G[0],W=G[1]):(X-=Y,W+=Y)):(k<U?(U+=Y,k-=Y):(U-=Y,k+=Y),W<X?(X+=Y,W-=Y):(X-=Y,W+=Y)),{x1:U,x2:k,y1:X,y2:W}},F.prototype.getAdornerAnnotationBorders=function(I,V){I===void 0&&(I=!1),V===void 0&&(V=!1);var z=this.getAnnotationBorders(I,V),G=this.isDomAnnotation?z.x1*m.DpiHelper.PIXEL_RATIO:z.x1,H=this.isDomAnnotation?z.x2*m.DpiHelper.PIXEL_RATIO:z.x2,U=this.isDomAnnotation?z.y1*m.DpiHelper.PIXEL_RATIO:z.y1,k=this.isDomAnnotation?z.y2*m.DpiHelper.PIXEL_RATIO:z.y2,X=(0,g.translateFromSeriesViewRectToCanvas)(new s.Point(G,U),this.parentSurface.seriesViewRect,!0),W=(0,g.translateFromSeriesViewRectToCanvas)(new s.Point(H,k),this.parentSurface.seriesViewRect,!0);return{x1:X.x/m.DpiHelper.PIXEL_RATIO,x2:W.x/m.DpiHelper.PIXEL_RATIO,y1:X.y/m.DpiHelper.PIXEL_RATIO,y2:W.y/m.DpiHelper.PIXEL_RATIO}},F.prototype.getAnnotationGripSvg=function(I,V){return'<circle cx="'.concat(I,'" cy="').concat(V,'" r="').concat(this.annotationsGripsRadius,'" fill="').concat(this.annotationsGripsFill,'" stroke="').concat(this.annotationsGripsStroke,'"/>')},F.prototype.canDragPoint=function(I){return this.dragPointsProperty.includes(I)},F.prototype.svgStringAdornerTemplate=function(I,V,z,G){return'<svg xmlns="http://www.w3.org/2000/svg"></svg>'},F.prototype.getClippingRect=function(I,V,z,G){var H;switch(I){case S.EAnnotationClippingMode.SeriesViewRect:{H=V;break}case S.EAnnotationClippingMode.SubChart:{H=z;break}case S.EAnnotationClippingMode.Chart:{H=G;break}default:throw new Error('Unhandled clipping value: "'.concat(I,'"'))}var U=this.parentSurface.clipRect;return l.Rect.intersect(H,U)},F.prototype.linkAxes=function(){if((0,a.updateAxisIds)(this),!!this.parentSurface){if(!this.xAxisProperty&&this.xAxisId){var I=this.parentSurface.getXAxisById(this.xAxisId);I?this.xAxisProperty=I:(console.warn('Annotation looked for xAxis Id "'.concat(this.xAxisId,'" but did not find. Default xAxis will be used')),this.xAxisProperty=this.parentSurface.getDefaultXAxis())}if(!this.yAxisProperty&&this.yAxisId){var V=this.parentSurface.getYAxisById(this.yAxisId);V?this.yAxisProperty=V:(console.warn('Annotation looked for yAxis Id "'.concat(this.yAxisId,'" but did not find. Default yAxis will be used')),this.yAxisProperty=this.parentSurface.getDefaultYAxis())}}},F.prototype.getClipPath=function(I){switch(I){case S.EAnnotationClippingMode.Chart:{var V=this.parentSurface,z=v.SciChartSurface.isSubSurface(V)?V.parentSurface.id:V.id;return"url(#surfaceViewRectClip_".concat(z,")")}case S.EAnnotationClippingMode.SeriesViewRect:return"url(#seriesViewRectClip_".concat(this.parentSurface.id,")");case S.EAnnotationClippingMode.SubChart:return"url(#surfaceViewRectClip_".concat(this.parentSurface.id,")");default:return I}},F.prototype.applySvgClipping=function(I,V){var z=this.getClipPath(V);return z?'<svg clip-path="'.concat(z,'" >').concat(I,"</svg>"):"<svg>".concat(I,"</svg>")},F.prototype.notifyPropertyChanged=function(I){this.invalidateParentCallback&&!this.invalidateState&&this.invalidateParentCallback({svgOnly:this.isDomAnnotation})},F.prototype.getCoordinate=function(I,V,z){if(o.Guard.notNull(z,"coordinateMode"),o.Guard.notNull(V,"calculator"),I!==void 0)switch(z){case R.Pixel:return this.isDomAnnotation?I:I*m.DpiHelper.PIXEL_RATIO;case R.DataValue:{var G=I!=null?V.getCoordinate(I):void 0;return this.isDomAnnotation?G/m.DpiHelper.PIXEL_RATIO:G}case R.Relative:return this.isDomAnnotation?(I*V.viewportDimension+V.offset)/m.DpiHelper.PIXEL_RATIO:I*V.viewportDimension+V.offset;default:throw new Error("AnnotationBase.getCoordinate with CoordinateMode.".concat(z," is not implemented"))}},F.prototype.getResolvedCoordinate=function(I,V,z,G,H){var U=H?this.isVerticalChart:!this.isVerticalChart;return U?this.getCoordinate(G??0,V,this.yCoordinateMode):this.getCoordinate(z??0,I,this.xCoordinateMode)},F.prototype.getX1Coordinate=function(I,V){return this.getResolvedCoordinate(I,V,this.x1,this.y1,!0)},F.prototype.getX2Coordinate=function(I,V){return this.getResolvedCoordinate(I,V,this.x2,this.y2,!0)},F.prototype.getY1Coordinate=function(I,V){return this.getResolvedCoordinate(I,V,this.x1,this.y1,!1)},F.prototype.getY2Coordinate=function(I,V){return this.getResolvedCoordinate(I,V,this.x2,this.y2,!1)},F.prototype.getValue=function(I,V,z){switch(z){case R.Pixel:return this.isDomAnnotation?V.getDataValue(I*m.DpiHelper.PIXEL_RATIO):V.getDataValue(I);case R.DataValue:return I;case R.Relative:return(V.visibleMax-V.visibleMin)*I+V.visibleMin;default:throw new Error("Not implemented")}},F.prototype.checkIsClickedOnAnnotationInternal=function(I,V){return!1},F.prototype.deleteAdorner=function(){!this.svgAdorner||!this.parentSurface||this.parentSurface.isDeleted||(this.svgAdornerRoot.removeChild(this.svgAdorner),this.svgAdorner=void 0)},F.prototype.getValuesFromCoordinates=function(I,V){var z=this.parentSurface.seriesViewRect,G=V?(0,g.translateFromCanvasToSeriesViewRect)(I,z,!0):I;if(G){var H=this.convertCartesianToPolar(G.x,G.y),U=H.x,k=H.y,X=this.xAxis.getCurrentCoordinateCalculator(),W=this.yAxis.getCurrentCoordinateCalculator(),Y=this.convertFromCoordinate(this.xAxis.isHorizontalAxis?U:k,X,this.xCoordinateMode),te=this.convertFromCoordinate(this.yAxis.isHorizontalAxis?U:k,W,this.yCoordinateMode);return new s.Point(Y,te)}},F.prototype.getXYCoordinatesFromValues=function(I){var V=this.parentSurface.seriesViewRect,z=this.getAbsoluteCoordinates(I),G=z.x,H=z.y,U=this.convertPolarToCartesian(G,H,this.isDomAnnotation),k=(0,g.translateFromSeriesViewRectToCanvas)(new s.Point(U.x,U.y),V,!0);if(k)return new s.Point(k.x,k.y)},F.prototype.convertFromCoordinate=function(I,V,z){switch(z){case R.Pixel:return I/m.DpiHelper.PIXEL_RATIO;case R.DataValue:return I!=null?V.getDataValue(I):void 0;case R.Relative:return(I-V.offset)/V.viewportDimension;default:throw new Error("Not implemented")}},F.prototype.getAbsoluteCoordinates=function(I){var V=this.xAxis.getCurrentCoordinateCalculator(),z=this.yAxis.getCurrentCoordinateCalculator(),G=this.getCoordinate(I.x,V,this.xCoordinateMode),H=this.getCoordinate(I.y,z,this.yCoordinateMode);return this.isVerticalChart?new s.Point(H,G):new s.Point(G,H)},F.prototype.getAbsoluteHorizontalCoordinate=function(I){var V=this.xAxis.getCurrentCoordinateCalculator(),z=this.yAxis.getCurrentCoordinateCalculator();return this.isVerticalChart?this.getCoordinate(I,z,this.yCoordinateMode):this.getCoordinate(I,V,this.xCoordinateMode)},F.prototype.getAbsoluteVerticalCoordinate=function(I){var V=this.xAxis.getCurrentCoordinateCalculator(),z=this.yAxis.getCurrentCoordinateCalculator();return this.isVerticalChart?this.getCoordinate(I,V,this.xCoordinateMode):this.getCoordinate(I,z,this.yCoordinateMode)},F.prototype.setAnnotationBorders=function(I,V,z,G){this.annotationBorders={x1:I,x2:V,y1:z,y2:G}},F.prototype.convertPolarToCartesian=function(I,V,z){if(z===void 0&&(z=!1),!this.parentSurface.isPolar)return{x:I,y:V};var G=this.parentSurface;return C.annotationHelpers.convertPolarToCartesian(this.xAxis,z,G.webAssemblyContext2D,this.xCoordinateMode,I,V)},F.prototype.convertCartesianToPolar=function(I,V){if(!this.parentSurface.isPolar)return{x:I,y:V};var z=this.parentSurface,G=this.xAxis.getTransform(),H=new z.webAssemblyContext2D.TSRVector2;G.ReverseTransformPoint(I,V,H);var U=-H.y,k=H.x;return H.delete(),{x:U,y:k}},F.prototype.applyPixelRatioToDragDist=function(I){return this.parentSurface.isPolar&&this.xCoordinateMode===R.Pixel?I*m.DpiHelper.PIXEL_RATIO:I},F})(n.DeletableEntity);t.AnnotationBase=M})(VN)),VN}var O1={},T9={},x9={},sye;function Gy(){return sye||(sye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ERadialAxisLabelPlacement=t.EAngularAxisLabelPlacement=t.EVerticalAlignment=t.EHorizontalAlignment=t.ELabelPlacement=void 0,(function(e){e.Right="Right",e.TopRight="TopRight",e.BottomRight="BottomRight",e.Bottom="Bottom",e.Left="Left",e.TopLeft="TopLeft",e.BottomLeft="BottomLeft",e.Top="Top",e.Axis="Axis",e.Auto="Auto"})(t.ELabelPlacement||(t.ELabelPlacement={})),(function(e){e.Right="Right",e.Left="Left"})(t.EHorizontalAlignment||(t.EHorizontalAlignment={})),(function(e){e.Top="Top",e.Bottom="Bottom"})(t.EVerticalAlignment||(t.EVerticalAlignment={})),(function(e){e.Inner="Inner",e.Outer="Outer",e.Center="Center"})(t.EAngularAxisLabelPlacement||(t.EAngularAxisLabelPlacement={})),(function(e){e.Top="Top",e.Bottom="Bottom",e.Center="Center"})(t.ERadialAxisLabelPlacement||(t.ERadialAxisLabelPlacement={}))})(x9)),x9}var E9={},lye;function NI(){return lye||(lye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPolarLabelMode=void 0,(function(e){e.Horizontal="Horizontal",e.Parallel="Parallel",e.Perpendicular="Perpendicular"})(t.EPolarLabelMode||(t.EPolarLabelMode={}))})(E9)),E9}var uye;function nR(){return uye||(uye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.labelHelper=void 0;var e=jv(),i=Gy(),n=NI();function r(d){return 180*d/Math.PI}function o(d){for(var f=d;f<0;)f+=2*Math.PI;return f=f%(2*Math.PI),f}function a(d,f){if(d===n.EPolarLabelMode.Parallel){var h=Math.round(r(o(f)));return h%360<=180?f-Math.PI/2:f-3*Math.PI/2}else if(d===n.EPolarLabelMode.Perpendicular)return Math.cos(f)>0?f:f-Math.PI;return 0}function s(d){return d===i.ERadialAxisLabelPlacement.Top?e.EVerticalAnchorPoint.Bottom:d===i.ERadialAxisLabelPlacement.Bottom?e.EVerticalAnchorPoint.Top:e.EVerticalAnchorPoint.Center}function l(d,f){return d===i.EAngularAxisLabelPlacement.Outer?f?e.EHorizontalAnchorPoint.Right:e.EHorizontalAnchorPoint.Left:d===i.EAngularAxisLabelPlacement.Inner?f?e.EHorizontalAnchorPoint.Left:e.EHorizontalAnchorPoint.Right:e.EHorizontalAnchorPoint.Center}function u(d,f){return d===i.EAngularAxisLabelPlacement.Outer?f?e.EVerticalAnchorPoint.Top:e.EVerticalAnchorPoint.Bottom:d===i.EAngularAxisLabelPlacement.Inner?f?e.EVerticalAnchorPoint.Bottom:e.EVerticalAnchorPoint.Top:e.EVerticalAnchorPoint.Center}function c(d,f,h){if(f===n.EPolarLabelMode.Parallel){var p=t.labelHelper.radiansToDegrees(Math.PI/2-d),g=p<-90;return{resultAngle:g?p+180:p,horizontalAnchorPoint:e.EHorizontalAnchorPoint.Center,verticalAnchorPoint:u(h,g)}}else if(f===n.EPolarLabelMode.Perpendicular){var p=t.labelHelper.radiansToDegrees(-d),g=p<-90&&p>-270;return{resultAngle:g?p+180:p,horizontalAnchorPoint:l(h,g),verticalAnchorPoint:e.EVerticalAnchorPoint.Center}}return{resultAngle:0,horizontalAnchorPoint:e.EHorizontalAnchorPoint.Center,verticalAnchorPoint:e.EVerticalAnchorPoint.Center}}t.labelHelper={getPolarLabelRotation:a,radiansToDegrees:r,getLabelPlacementForRadialAxis:s,getLabelRotationAndPlacementForAngularAxis:c,normalizeAngle:o}})(T9)),T9}var D1={},cye;function FI(){if(cye)return D1;cye=1;var t=D1&&D1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(D1,"__esModule",{value:!0}),D1.RenderContextAnnotationBase=void 0;var e=Ca(),i=jl(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.isSvgAnnotation=!1,s.isDomAnnotation=!1,s}return Object.defineProperty(o.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},set:function(a){this.parentSurfaceProperty!==a&&(this.parentSurfaceProperty=a,this.notifyPropertyChanged(i.PROPERTY.PARENT_SURFACE))},enumerable:!1,configurable:!0}),o})(e.AnnotationBase);return D1.RenderContextAnnotationBase=n,D1}var dye;function $re(){if(dye)return O1;dye=1;var t=O1&&O1.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(O1,"__esModule",{value:!0}),O1.ArcAnnotationBase=void 0;var e=Br(),i=$i(),n=Eo(),r=An(),o=tu(),a=Ls(),s=nR(),l=Sn(),u=Zi(),c=Ca(),d=gl(),f=jl(),h=FI(),p=(function(g){t(v,g);function v(y){var m=this,b,S,_,C,P;return m=g.call(this,y)||this,m.dragPointsProperty=[c.EDraggingGripPoint.Body,c.EDraggingGripPoint.x1y1,c.EDraggingGripPoint.x2y2,c.EDraggingGripPoint.x3y3],m.arcAnnotationBorders={x1:0,x2:0,y1:0,y2:0,xCenter:0,yCenter:0},m.strokeThicknessProperty=1,m.strokeDashArrayProperty=[],m.strokeProperty="#FFFFFF",m.isLineModeProperty=!1,m.strokeProperty=(b=y==null?void 0:y.stroke)!==null&&b!==void 0?b:m.strokeProperty,m.strokeThicknessProperty=(S=y==null?void 0:y.strokeThickness)!==null&&S!==void 0?S:m.strokeThicknessProperty,m.strokeDashArrayProperty=(_=y==null?void 0:y.strokeDashArray)!==null&&_!==void 0?_:m.strokeDashArrayProperty,m.isLineModeProperty=(C=y==null?void 0:y.isLineMode)!==null&&C!==void 0?C:m.isLineModeProperty,m.fillProperty=(P=y==null?void 0:y.fill)!==null&&P!==void 0?P:m.fillProperty,m}return Object.defineProperty(v.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(y){y!==this.strokeProperty&&(this.strokeProperty=y,this.notifyPropertyChanged(f.PROPERTY.STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(y){y!==this.strokeThicknessProperty&&(this.strokeThicknessProperty=y,this.notifyPropertyChanged(f.PROPERTY.STROKE_THICKNESS))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(y){y!==this.strokeDashArrayProperty&&(this.strokeDashArrayProperty=y,this.notifyPropertyChanged(f.PROPERTY.STROKE_DASH_ARRAY))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isLineMode",{get:function(){return this.isLineModeProperty},set:function(y){y!==this.isLineModeProperty&&(this.isLineModeProperty=y,this.notifyPropertyChanged(f.PROPERTY.IS_LINE_MODE))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fill",{get:function(){return this.fillProperty},set:function(y){y!==this.fillProperty&&(this.fillProperty=y,this.notifyPropertyChanged(f.PROPERTY.FILL))},enumerable:!1,configurable:!0}),v.prototype.delete=function(){this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache)},v.prototype.onAttach=function(y){g.prototype.onAttach.call(this,y),this.strokePenCache||(this.strokePenCache=new a.Pen2DCache(y.webAssemblyContext2D)),(0,a.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness>0?this.strokeThickness+1:0,this.opacity,this.strokeDashArray),this.fillBrushCache||(this.fillBrushCache=new o.BrushCache(y.webAssemblyContext2D)),(0,o.createBrushInCache)(this.fillBrushCache,this.fill,this.opacity)},v.prototype.onDpiChanged=function(y){g.prototype.onDpiChanged.call(this,y),this.notifyPropertyChanged(f.PROPERTY.STROKE)},v.prototype.toJSON=function(){var y=g.prototype.toJSON.call(this),m={stroke:this.stroke,strokeDashArray:this.strokeDashArray,strokeThickness:this.strokeThickness,isLineMode:this.isLineMode,fill:this.fill};return Object.assign(y.options,m),y},v.prototype.onDragStarted=function(y){g.prototype.onDragStarted.call(this,y);var m=this.getArcAnnotationBorders(!0),b=m.x1,S=m.x2,_=m.xCenter,C=m.y1,P=m.y2,x=m.yCenter,E=y.mousePoint.x,A=y.mousePoint.y;if(this.canDragPoint(c.EDraggingGripPoint.x1y1)){var R=(0,n.calcDistance)(b,C,E,A);if(R<this.annotationsGripsRadius*u.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=c.EDraggingGripPoint.x1y1,!0}if(this.canDragPoint(c.EDraggingGripPoint.x2y2)){var R=(0,n.calcDistance)(S,P,E,A);if(R<this.annotationsGripsRadius*u.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=c.EDraggingGripPoint.x2y2,!0}if(this.canDragPoint(c.EDraggingGripPoint.x3y3)){var R=(0,n.calcDistance)(_,x,E,A);if(R<this.annotationsGripsRadius*u.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=c.EDraggingGripPoint.x3y3,!0}return this.canDragPoint(c.EDraggingGripPoint.Body)&&this.clickToSelect(y)?(this.adornerDraggingPoint=c.EDraggingGripPoint.Body,!0):!1},v.prototype.notifyPropertyChanged=function(y){g.prototype.notifyPropertyChanged.call(this,y);var m=[f.PROPERTY.STROKE,f.PROPERTY.STROKE_THICKNESS,f.PROPERTY.STROKE_DASH_ARRAY,f.PROPERTY.OPACITY];m.includes(y)&&this.strokePenCache&&(0,a.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness,this.opacity,this.strokeDashArray);var b=[f.PROPERTY.FILL,f.PROPERTY.OPACITY];b.includes(y)&&this.fillBrushCache&&(0,o.createBrushInCache)(this.fillBrushCache,this.fill,this.opacity)},v.prototype.getBrush=function(){if(!this.isLineMode){var y=this.fill?(0,o.getWebGlBrushFromCache)(this.fillBrushCache):void 0;return y==null||y.setOpacity(this.opacity),y?y.scrtBrush:void 0}},v.prototype.getDrawMode=function(){return this.isLineMode?1:0},v.prototype.setArcAnnotationBorders=function(y,m,b,S,_,C){this.arcAnnotationBorders={x1:y,x2:m,xCenter:b,y1:S,y2:_,yCenter:C}},v.prototype.getArcAnnotationBorders=function(y,m){if(y===void 0&&(y=!1),m===void 0&&(m=1),y){var b=this.parentSurface.seriesViewRect,S=this.arcAnnotationBorders,_=S.x1,C=S.x2,P=S.xCenter,x=S.y1,E=S.y2,A=S.yCenter,R=(0,r.translateFromSeriesViewRectToCanvas)(new i.Point(_,x),b,!0),M=(0,r.translateFromSeriesViewRectToCanvas)(new i.Point(C,E),b,!0),D=(0,r.translateFromSeriesViewRectToCanvas)(new i.Point(P,A),b,!0);return{x1:R.x*m,y1:R.y*m,x2:M.x*m,y2:M.y*m,xCenter:D.x*m,yCenter:D.y*m}}return this.arcAnnotationBorders},v.prototype.svgStringArcAdornerTemplate=function(y,m,b,S,_,C){var P=this.selectionBoxStroke;return`<svg xmlns="http://www.w3.org/2000/svg">
    <line x1="`.concat(y,'" y1="').concat(m,'" x2="').concat(b,'" y2="').concat(S,'" stroke="').concat(P,`" stroke-width="6" />
    <line x1="`).concat(y,'" y1="').concat(m,'" x2="').concat(_,'" y2="').concat(C,'" stroke="').concat(P,`" stroke-width="6" />
    <line x1="`).concat(_,'" y1="').concat(C,'" x2="').concat(b,'" y2="').concat(S,'" stroke="').concat(P,`" stroke-width="6" />
    `).concat(this.canDragPoint(c.EDraggingGripPoint.x1y1)?this.getAnnotationGripSvg(y,m):"",`
    `).concat(this.canDragPoint(c.EDraggingGripPoint.x2y2)?this.getAnnotationGripSvg(b,S):"",`
    `).concat(this.getAnnotationGripSvg(_,C),`
    </svg>`)},v.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var y=this.getArcAnnotationBorders(!0,1/u.DpiHelper.PIXEL_RATIO),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=y.xCenter,P=y.yCenter,x=this.svgStringArcAdornerTemplate(m,S,b,_,C,P);this.svgAdorner=d.annotationHelpers.createSvg(x,this.svgAdornerRoot)}},v.prototype.getViewportHeight=function(){return this.parentSurface.isCopyCanvasSurface?l.SciChartSurfaceBase.domMasterCanvas.height:this.parentSurface.renderSurface.viewportSize.height},v.prototype.normalizeAnglesAndHitTest=function(y,m,b){var S=s.labelHelper.normalizeAngle(y),_=s.labelHelper.normalizeAngle(m);S>_&&(_+=2*Math.PI);var C=!1;if(b){var P=s.labelHelper.normalizeAngle(b);P<S&&(P+=2*Math.PI),S<=P&&P<=_&&(C=!0)}return{startAngle:S,endAngle:_,isHit:C}},v.prototype.isDataValueMode=function(){return this.xCoordinateMode===c.ECoordinateMode.DataValue},v})(h.RenderContextAnnotationBase);return O1.ArcAnnotationBase=p,O1}var fye;function HFe(){if(fye)return CT;fye=1;var t=CT&&CT.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(CT,"__esModule",{value:!0}),CT.ArcAnnotation=void 0;var e=ci(),i=$i(),n=vs(),r=pl(),o=Eo(),a=Ls(),s=an(),l=Zi(),u=Ca(),c=$re(),d=jl(),f=Qa(),h=(function(p){t(g,p);function g(v){var y=this,m,b;if(y=p.call(this,v)||this,y.type=f.EAnnotationType.RenderContextArcAnnotation,y.surfaceTypes=[n.ESurfaceType.SciChartSurfaceType],y.innerRadiusProperty=0,y.heightProperty=0,y.xCoordinateMode===u.ECoordinateMode.Relative)throw new Error("ECoordinateMode.Relative is not supported for ArcAnnotation use DataValue or Pixel mode");if(y.xCoordinateMode!==y.yCoordinateMode)throw new Error("xCoordinateMode and yCoordinateMode should be the same for ArcAnnotation");return y.innerRadiusProperty=(m=v==null?void 0:v.innerRadius)!==null&&m!==void 0?m:y.innerRadiusProperty,y.heightProperty=(b=v==null?void 0:v.height)!==null&&b!==void 0?b:y.heightProperty,y}return Object.defineProperty(g.prototype,"innerRadius",{get:function(){return this.innerRadiusProperty},set:function(v){v!==this.innerRadiusProperty&&(this.innerRadiusProperty=v,this.notifyPropertyChanged(d.PROPERTY.INNER_RADIUS))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"height",{get:function(){return this.heightProperty},set:function(v){v!==this.heightProperty&&(this.heightProperty=v,this.notifyPropertyChanged(d.PROPERTY.HEIGHT))},enumerable:!1,configurable:!0}),g.prototype.drawWithContext=function(v,y,m,b,S,_){e.Guard.notNull(v,"renderContext"),e.Guard.notNull(y,"xCalc"),e.Guard.notNull(m,"yCalc");var C=this.stroke&&this.strokeThickness!==void 0?(0,a.getWebGlPenFromCache)(this.strokePenCache):void 0,P=this.getResolvedCoordinate(y,m,this.x1,this.y1,!0),x=this.getResolvedCoordinate(y,m,this.x1,this.y1,!1),E=this.getResolvedCoordinate(y,m,this.x2,this.y2,!0),A=this.getResolvedCoordinate(y,m,this.x2,this.y2,!1),R=v.webAssemblyContext,M=(0,s.getVectorArcVertex)(R),D=(0,s.getArcVertex)(R),F=this.getCircleCenterXCoordinate(y,m),I=F,V=this.getCircleCenterYCoordinate(y,m),z=this.getViewportHeight()-V,G=this.calcStartEndAngles(y.isFlipped,m.isFlipped),H=G.startAngle,U=G.endAngle,k=(0,s.getArcParams)(R,I,z,H,U,this.getRadius(y,m),this.getInnerRadius(y,m),this.getDrawMode(),this.getAspectRatio(y,m),this.strokeThickness);D.MakeCircularArc(k),M.push_back(D);var X=this.getClippingRect(this.clipping,b,S,_);v.drawArcs(M,I,z,0,X,C.scrtPen,this.getBrush(),b.left,b.top),this.setArcAnnotationBorders(P,E,F,x,A,V),this.updateAdornerInner()},g.prototype.calcDragDistance=function(v){if(!this.prevValue){this.prevValue=v;return}if(this.adornerDraggingPoint===u.EDraggingGripPoint.Body?(this.x1=this.x1-(this.prevValue.x-v.x),this.x2=this.x2-(this.prevValue.x-v.x),this.y1=this.y1-(this.prevValue.y-v.y),this.y2=this.y2-(this.prevValue.y-v.y)):this.adornerDraggingPoint===u.EDraggingGripPoint.x1y1?this.resizeDirections===r.EXyDirection.XDirection?this.x1-=this.prevValue.x-v.x:this.resizeDirections===r.EXyDirection.YDirection?this.y1-=this.prevValue.y-v.y:(this.x1-=this.prevValue.x-v.x,this.y1-=this.prevValue.y-v.y):this.adornerDraggingPoint===u.EDraggingGripPoint.x2y2&&(this.resizeDirections===r.EXyDirection.XDirection?this.x2-=this.prevValue.x-v.x:this.resizeDirections===r.EXyDirection.YDirection?this.y2-=this.prevValue.y-v.y:(this.x2-=this.prevValue.x-v.x,this.y2-=this.prevValue.y-v.y)),this.adornerDraggingPoint===u.EDraggingGripPoint.x3y3){var y=(0,o.calcDistanceFromLineSegment)(v.x,v.y,this.x1,this.y1,this.x2,this.y2),m=(0,o.calcCrossProduct)(v.x,v.y,this.x1,this.y1,this.x2,this.y2)>0?1:-1;this.height=m*y}this.prevValue=v},g.prototype.toJSON=function(){var v=p.prototype.toJSON.call(this),y={innerRadius:this.innerRadius,height:this.height};return Object.assign(v.options,y),v},g.prototype.checkIsClickedOnAnnotationInternal=function(v,y){var m=this.getArcAnnotationBorders(),b=m.x1,S=m.x2,_=m.y1,C=m.y2,P=m.xCenter,x=m.yCenter;if((0,o.calcDistance)(v,y,b,_)<=d.DISTANCE_TO_LINE*l.DpiHelper.PIXEL_RATIO||(0,o.calcDistance)(v,y,S,C)<=d.DISTANCE_TO_LINE*l.DpiHelper.PIXEL_RATIO||(0,o.calcDistance)(v,y,P,x)<=d.DISTANCE_TO_LINE)return!0;var E=this.getDataValuesFromCoordinates(v,y),A=E.x,R=E.y,M=this.getCircleCenterDataCoords(),D=M.x,F=M.y,I=(0,o.calcDistance)(A,R,D,F)<this.calcDataRadius(),V=this.calcStartEndAngles(this.xAxis.getCurrentCoordinateCalculator().isFlipped,this.yAxis.getCurrentCoordinateCalculator().isFlipped,new i.Point(A,R)).isHit,z=I&&V,G=(0,o.testPointInTriangle)(v,y,b,_,S,C,P,x);return z||G},g.prototype.getCircleCenterDataCoords=function(){var v=(this.x1+this.x2)/2,y=(this.y1+this.y2)/2,m=this.x1-this.x2,b=this.y1-this.y2,S=Math.sqrt(m*m+b*b),_=b/S,C=-m/S,P=this.height,x=v+_*P,E=y+C*P;return{x,y:E}},g.prototype.getCircleCenterXCoordinate=function(v,y){var m=this.getCircleCenterDataCoords();return this.getResolvedCoordinate(v,y,m.x,m.y,!0)},g.prototype.getCircleCenterYCoordinate=function(v,y){var m=this.getCircleCenterDataCoords();return this.getResolvedCoordinate(v,y,m.x,m.y,!1)},g.prototype.calcDataRadius=function(){var v=this.x1-this.x2,y=this.y1-this.y2,m=Math.sqrt(v*v+y*y)/2;return Math.sqrt(m*m+this.height*this.height)},g.prototype.getRadius=function(v,y){var m=this.calcDataRadius();return this.isDataValueMode()?this.isVerticalChart?v.getCoordWidth(m):y.getCoordWidth(m):m*l.DpiHelper.PIXEL_RATIO},g.prototype.getInnerRadius=function(v,y){return this.isLineMode?0:this.getRadius(v,y)*this.innerRadius},g.prototype.getAspectRatio=function(v,y){return this.isDataValueMode()?this.isVerticalChart?y.getCoordWidth(1)/v.getCoordWidth(1):v.getCoordWidth(1)/y.getCoordWidth(1):1},g.prototype.calcStartEndAngles=function(v,y,m){var b=this.getCircleCenterDataCoords(),S=0,_=0,C=0,P=!1,x=!1;if(this.isVerticalChart?(_=Math.atan2(this.x1-b.x,this.y1-b.y),S=Math.atan2(this.x2-b.x,this.y2-b.y),C=m?Math.atan2(m.x-b.x,m.y-b.y):0,P=!y,x=v):(S=Math.atan2(this.y1-b.y,this.x1-b.x),_=Math.atan2(this.y2-b.y,this.x2-b.x),C=m?Math.atan2(m.y-b.y,m.x-b.x):0,P=!v,x=y),this.isDataValueMode()){if(!x){var E=S;S=2*Math.PI-_,_=2*Math.PI-E,C=2*Math.PI-C}if(!P){var E=S;S=Math.PI-_,_=Math.PI-E,C=Math.PI-C}}else{var E=S;S=2*Math.PI-_,_=2*Math.PI-E,C=2*Math.PI-C}return this.normalizeAnglesAndHitTest(S,_,m?C:void 0)},g.prototype.getDataValuesFromCoordinates=function(v,y){var m=0,b=0;if(this.isDataValueMode()){var S=this.xAxis.getCurrentCoordinateCalculator(),_=this.yAxis.getCurrentCoordinateCalculator();return m=S.getDataValue(this.isVerticalChart?y:v),b=_.getDataValue(this.isVerticalChart?v:y),{x:m,y:b}}else return m=v/l.DpiHelper.PIXEL_RATIO,b=y/l.DpiHelper.PIXEL_RATIO,this.isVerticalChart?{x:b,y:m}:{x:m,y:b}},g})(c.ArcAnnotationBase);return CT.ArcAnnotation=h,CT}var R1={},hye;function EW(){if(hye)return R1;hye=1;var t=R1&&R1.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(R1,"__esModule",{value:!0}),R1.PolarArcAnnotation=void 0;var e=ci(),i=vs(),n=pl(),r=Eo(),o=Ls(),a=an(),s=Zi(),l=Ca(),u=$re(),c=jl(),d=Qa(),f=(function(h){t(p,h);function p(g){var v=this,y,m;return v=h.call(this,g)||this,v.type=d.EAnnotationType.RenderContextPolarArcAnnotation,v.surfaceTypes=[i.ESurfaceType.SciChartPolarSurfaceType],v.centerXProperty=(y=g==null?void 0:g.centerX)!==null&&y!==void 0?y:v.centerXProperty,v.centerYProperty=(m=g==null?void 0:g.centerY)!==null&&m!==void 0?m:v.centerYProperty,v}return Object.defineProperty(p.prototype,"centerX",{get:function(){var g;return(g=this.centerXProperty)!==null&&g!==void 0?g:this.xAxis.visibleRange.min},set:function(g){g!==this.centerXProperty&&(this.centerXProperty=g,this.notifyPropertyChanged(c.PROPERTY.CENTER_X))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"centerY",{get:function(){var g;return(g=this.centerYProperty)!==null&&g!==void 0?g:this.yAxis.visibleRange.min},set:function(g){g!==this.centerYProperty&&(this.centerYProperty=g,this.notifyPropertyChanged(c.PROPERTY.CENTER_Y))},enumerable:!1,configurable:!0}),p.prototype.drawWithContext=function(g,v,y,m,b,S){var _,C,P,x;e.Guard.notNull(g,"renderContext"),e.Guard.notNull(v,"xCalc"),e.Guard.notNull(y,"yCalc");var E=this.stroke&&this.strokeThickness!==void 0?(0,o.getWebGlPenFromCache)(this.strokePenCache):void 0,A=0,R=this.getAngleSign()*this.getX1Coordinate(v,y),M=this.getAngleSign()*this.getX2Coordinate(v,y),D=this.getY1Coordinate(v,y),F=this.convertPolarToCartesian(R,D,!1),I=this.convertPolarToCartesian(M,D,!1),V=this.xAxis,z=this.yAxis,G=V.visibleRange.min,H=z.visibleRange.min,U=this.getResolvedCoordinate(v,y,G,H,!0),k=this.getResolvedCoordinate(v,y,G,H,!1),X=this.convertPolarToCartesian(U,k,!1),W=this.getResolvedCoordinate(v,y,this.centerX,this.centerY,!0),Y=this.getResolvedCoordinate(v,y,this.centerX,this.centerY,!1),te=this.convertPolarToCartesian(W,Y,!1),oe=te.x-X.x,de=te.y-X.y;A=this.isVerticalChart?z.startAngle:V.startAngle;var ge=g.webAssemblyContext,Ee=(0,a.getVectorArcVertex)(ge),Re=(0,a.getArcVertex)(ge),Ae=((C=(_=this.parentSurface.padding)===null||_===void 0?void 0:_.left)!==null&&C!==void 0?C:0)*s.DpiHelper.PIXEL_RATIO,Pe=((x=(P=this.parentSurface.padding)===null||P===void 0?void 0:P.top)!==null&&x!==void 0?x:0)*s.DpiHelper.PIXEL_RATIO,we=this.transformAngles(R,M,this.isVerticalChart,v.isFlipped,y.isFlipped),Te=this.normalizeAnglesAndHitTest(we.startAngle,we.endAngle),ke=Te.startAngle,$e=Te.endAngle,Ne=te.x,ve=this.getViewportHeight()-te.y,pe=(0,a.getArcParams)(ge,Ne,ve,ke,$e,this.getRadius(v,y),this.getInnerRadius(v,y),this.getDrawMode()?1:0,1,this.strokeThickness);Re.MakeCircularArc(pe),Ee.push_back(Re);var fe=this.getClippingRect(this.clipping,m,b,S);g.drawArcs(Ee,Ne,ve,A,fe,E.scrtPen,this.getBrush(),Ae,Pe),this.setArcAnnotationBorders(F.x+oe,I.x+oe,te.x,F.y+de,I.y+de,te.y),this.updateAdornerInner()},p.prototype.calcDragDistance=function(g){var v=this.xAxis,y=this.yAxis;if(!this.prevValue){this.prevValue=g;return}this.adornerDraggingPoint===l.EDraggingGripPoint.Body?(this.resizeDirections!==n.EXyDirection.YDirection&&(this.x1=this.x1-this.multByPixelRatio(this.prevValue.x-g.x,v),this.x2=this.x2-this.multByPixelRatio(this.prevValue.x-g.x,v)),this.resizeDirections!==n.EXyDirection.XDirection&&(this.y1=this.y1-this.multByPixelRatio(this.prevValue.y-g.y,y),this.y2=this.y2-this.multByPixelRatio(this.prevValue.y-g.y,y))):this.adornerDraggingPoint===l.EDraggingGripPoint.x1y1?(this.resizeDirections!==n.EXyDirection.YDirection&&(this.x1-=this.multByPixelRatio(this.prevValue.x-g.x,v)),this.resizeDirections!==n.EXyDirection.XDirection&&(this.y1-=this.multByPixelRatio(this.prevValue.y-g.y,y))):this.adornerDraggingPoint===l.EDraggingGripPoint.x2y2&&(this.resizeDirections!==n.EXyDirection.YDirection&&(this.x2-=this.multByPixelRatio(this.prevValue.x-g.x,v)),this.resizeDirections!==n.EXyDirection.XDirection&&(this.y2-=this.multByPixelRatio(this.prevValue.y-g.y,y))),this.adornerDraggingPoint===l.EDraggingGripPoint.x3y3&&(this.centerX=this.multByPixelRatio(g.x,v,!0),this.centerY=this.multByPixelRatio(g.y,y,!0)),this.validateInnerRadius(),this.prevValue=g},p.prototype.toJSON=function(){var g=h.prototype.toJSON.call(this),v={centerX:this.centerX,centerY:this.centerY};return Object.assign(g.options,v),g},p.prototype.onDragStarted=function(g){h.prototype.onDragStarted.call(this,g);var v=this.getArcAnnotationBorders(!0),y=v.x1,m=v.x2,b=v.xCenter,S=v.y1,_=v.y2,C=v.yCenter,P=g.mousePoint.x,x=g.mousePoint.y;if(this.canDragPoint(l.EDraggingGripPoint.x1y1)){var E=(0,r.calcDistance)(y,S,P,x);if(E<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x1y1,!0}if(this.canDragPoint(l.EDraggingGripPoint.x2y2)){var A=(m+b)/2,R=(_+C)/2,E=(0,r.calcDistance)(A,R,P,x);if(E<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x2y2,!0}if(this.canDragPoint(l.EDraggingGripPoint.x3y3)){var E=(0,r.calcDistance)(b,C,P,x);if(E<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x3y3,!0}return this.canDragPoint(l.EDraggingGripPoint.Body)&&this.clickToSelect(g)?(this.adornerDraggingPoint=l.EDraggingGripPoint.Body,!0):!1},p.prototype.checkIsClickedOnAnnotationInternal=function(g,v){var y=this.getArcAnnotationBorders(),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=y.xCenter,P=y.yCenter;if((0,r.calcDistance)(g,v,m,S)<=c.DISTANCE_TO_LINE*s.DpiHelper.PIXEL_RATIO||(0,r.calcDistance)(g,v,b,_)<=c.DISTANCE_TO_LINE*s.DpiHelper.PIXEL_RATIO||(0,r.calcDistance)(g,v,C,P)<=c.DISTANCE_TO_LINE)return!0;var x=(0,r.calcDistance)(m,S,C,P),E=(0,r.calcDistance)(g,v,C,P)<x,A=this.transformAngles(this.calcAngleFromCoordinates(C,P,m,S),this.calcAngleFromCoordinates(C,P,b,_),this.isVerticalChart,this.xAxis.getCurrentCoordinateCalculator().isFlipped,this.yAxis.getCurrentCoordinateCalculator().isFlipped),R=A.startAngle,M=A.endAngle,D=this.calcAngleFromCoordinates(C,P,g,v),F=this.normalizeAnglesAndHitTest(R,M,D).isHit,I=E&&F,V=(0,r.testPointInTriangle)(g,v,m,S,b,_,C,P);return I||V},p.prototype.svgStringArcAdornerTemplate=function(g,v,y,m,b,S){var _=this.selectionBoxStroke,C=(y+b)/2,P=(m+S)/2;return`<svg xmlns="http://www.w3.org/2000/svg">
    <line x1="`.concat(g,'" y1="').concat(v,'" x2="').concat(y,'" y2="').concat(m,'" stroke="').concat(_,`" stroke-width="6" />
    <line x1="`).concat(g,'" y1="').concat(v,'" x2="').concat(b,'" y2="').concat(S,'" stroke="').concat(_,`" stroke-width="6" />
    <line x1="`).concat(b,'" y1="').concat(S,'" x2="').concat(y,'" y2="').concat(m,'" stroke="').concat(_,`" stroke-width="6" />
    `).concat(this.canDragPoint(l.EDraggingGripPoint.x1y1)?this.getAnnotationGripSvg(g,v):"",`
    `).concat(this.canDragPoint(l.EDraggingGripPoint.x2y2)?this.getAnnotationGripSvg(C,P):"",`
    `).concat(this.getAnnotationGripSvg(b,S),`
    </svg>`)},p.prototype.getRadius=function(g,v){return this.getY1Coordinate(g,v)},p.prototype.getInnerRadius=function(g,v){return this.isLineMode?0:this.getY2Coordinate(g,v)},p.prototype.calcAngleFromCoordinates=function(g,v,y,m){return-Math.atan2(m-v,y-g)},p.prototype.transformAngles=function(g,v,y,m,b){var S=this.isDataValueMode()?g:g/s.DpiHelper.PIXEL_RATIO,_=this.isDataValueMode()?v:v/s.DpiHelper.PIXEL_RATIO;if(y){if(b)return{startAngle:_,endAngle:S}}else if(m)return{startAngle:_,endAngle:S};return{startAngle:S,endAngle:_}},p.prototype.multByPixelRatio=function(g,v,y){if(y===void 0&&(y=!1),v.isAngular&&!this.isDataValueMode()){var m=1;return!y&&v.getCurrentCoordinateCalculator().isFlipped&&(m=-1),m*s.DpiHelper.PIXEL_RATIO*g}return g},p.prototype.validateInnerRadius=function(){this.isVerticalChart?this.x1<this.x2&&(this.x2=this.x1):this.y1<this.y2&&(this.y2=this.y1)},p.prototype.getAngleSign=function(){if(this.isDataValueMode())return 1;var g=this.xAxis;if(g.isAngular)return g.getCurrentCoordinateCalculator().isFlipped?-1:1;var v=this.yAxis;return v.getCurrentCoordinateCalculator().isFlipped?-1:1},p})(u.ArcAnnotationBase);return R1.PolarArcAnnotation=f,R1}var M1={},xF={},pye;function _v(){return pye||(pye=1,(function(t){var e=xF&&xF.__assign||function(){return e=Object.assign||function(d){for(var f,h=1,p=arguments.length;h<p;h++){f=arguments[h];for(var g in f)Object.prototype.hasOwnProperty.call(f,g)&&(d[g]=f[g])}return d},e.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.getLabelValue=t.getLineCoordinates=t.getLabelCoordinates=t.drawAxisMarkerAnnotation=t.drawLineAnnotation=t.drawModifiersAxisLabel=void 0;var i=Rn(),n=od(),r=Gy(),o=function(d,f,h,p,g,v,y){if(d.isVisible){var m=(0,t.getLabelValue)(d,h),b=e(e({},d.dpiAdjustedLabelStyle),{color:g});return d.axisRenderer.drawModifiersAxisLabel(f,m,h,d.axisAlignment,b,p,v,y)}};t.drawModifiersAxisLabel=o;var a=function(d,f,h,p,g,v,y,m,b,S,_,C,P,x,E,A){f.getNativeContext();var R=d.axisAlignment,M=(R===n.EAxisAlignment.Top||R===n.EAxisAlignment.Bottom)&&![r.ELabelPlacement.Top,r.ELabelPlacement.Bottom,r.ELabelPlacement.Auto,r.ELabelPlacement.Axis].includes(h),D=[r.ELabelPlacement.Right,r.ELabelPlacement.TopRight,r.ELabelPlacement.BottomRight].includes(h),F=R===n.EAxisAlignment.Top||R===n.EAxisAlignment.Bottom?g:y,I=p||(0,t.getLabelValue)(d,F),V=h===r.ELabelPlacement.Auto||h===r.ELabelPlacement.Axis,z=V?S:null,G=V?b:e(e({},b),{color:S}),H=0,U=0,k,X=(0,t.getLineCoordinates)(g,y,v,m,H,U,h,d),W=X.x1LineCoord,Y=X.y1LineCoord,te=X.x2LineCoord,oe=X.y2LineCoord;if(_&&f.drawLine(W,Y,te,oe,_,C,C),P){var de=d.axisRenderer.createAnnotationLabelTexture(I,G,z,M,D,x),ge=de.bitmapTexture,Ee=de.textureHeight,Re=de.textureWidth,Ae=(0,t.getLabelCoordinates)(d,h,g,v,y,m,Ee,Re,E,A),Pe=Ae.xPosition,we=Ae.yPosition;H=Ee,U=Re,k=new i.Rect(Pe,we,Re,Ee);var Te=d.parentSurface.viewRect;f.resetAndClip(Te),f.drawTexture(ge,Math.round(Pe),Math.round(we),Re,Ee),ge.delete()}return k};t.drawLineAnnotation=a;var s=function(d,f,h,p,g,v,y,m,b,S,_,C){f.getNativeContext();var P=d.axisAlignment,x=h||(0,t.getLabelValue)(d,p),E=S?d.axisRenderer.createAxisMarkerFromImage(S,_,C):d.axisRenderer.createAxisMarker(P,x,y,m,b),A=E.bitmapTexture,R=E.textureHeight,M=E.textureWidth,D=(0,t.getLabelCoordinates)(d,r.ELabelPlacement.Axis,g,g,v,v,R,M),F=D.xPosition,I=D.yPosition;if(A){var V=d.parentSurface.clipRect;f.resetAndClip(V),f.drawTexture(A,Math.round(F),Math.round(I),M,R),A.delete()}return{xPosition:F,yPosition:I,textureWidth:M,textureHeight:R}};t.drawAxisMarkerAnnotation=s;var l=function(d,f,h,p,g,v,y,m,b,S){var _=d.axisAlignment,C=d.parentSurface.seriesViewRect,P=d.viewRect,x=0,E=0,A=function(){switch(_){case n.EAxisAlignment.Right:case n.EAxisAlignment.Left:E=C.top+g-y/2;break;case n.EAxisAlignment.Top:E=C.top+v/2-y/2;break;case n.EAxisAlignment.Bottom:E=C.top+g+(v-g)/2-y/2;break}},R=function(){switch(_){case n.EAxisAlignment.Right:x=C.left+p+(h-p)/2-m/2;break;case n.EAxisAlignment.Left:x=C.left+p/2-m/2;break;case n.EAxisAlignment.Top:case n.EAxisAlignment.Bottom:x=C.left+p-m/2;break}},M=function(){switch(_){case n.EAxisAlignment.Right:x=C.left+h-m;break;case n.EAxisAlignment.Left:x=C.left+p-m;break;case n.EAxisAlignment.Top:case n.EAxisAlignment.Bottom:x=C.left+h;break}},D=function(){switch(_){case n.EAxisAlignment.Right:x=C.left+p;break;case n.EAxisAlignment.Left:x=C.left;break;case n.EAxisAlignment.Top:case n.EAxisAlignment.Bottom:x=C.left+h-m;break}},F=function(){switch(_){case n.EAxisAlignment.Right:case n.EAxisAlignment.Left:E=C.top+g-y;break;case n.EAxisAlignment.Top:E=C.top;break;case n.EAxisAlignment.Bottom:E=C.top+v;break}},I=function(){switch(_){case n.EAxisAlignment.Right:case n.EAxisAlignment.Left:E=C.top+g;break;case n.EAxisAlignment.Top:E=C.top+v-y;break;case n.EAxisAlignment.Bottom:E=C.top+g-y;break}},V=function(){switch(_){case n.EAxisAlignment.Right:A(),b===r.EHorizontalAlignment.Left?x=C.left:x=P.width<m?x=P.right-m:P.left;break;case n.EAxisAlignment.Left:A(),b===r.EHorizontalAlignment.Right?x=C.left+C.width-m:x=P.width<m?x=P.left:P.right-m;break;case n.EAxisAlignment.Top:S===r.EVerticalAlignment.Bottom?E=C.top+C.height-y:E=P.height<y?P.top:P.bottom-y,R();break;case n.EAxisAlignment.Bottom:S===r.EVerticalAlignment.Top?E=C.top:E=P.height<y?P.bottom-y:P.top,R();break}};switch(f){case r.ELabelPlacement.Right:A(),M();break;case r.ELabelPlacement.TopRight:F(),M();break;case r.ELabelPlacement.BottomRight:I(),M();break;case r.ELabelPlacement.Bottom:I(),R();break;case r.ELabelPlacement.Left:A(),D();break;case r.ELabelPlacement.TopLeft:F(),D();break;case r.ELabelPlacement.BottomLeft:I(),D();break;case r.ELabelPlacement.Top:F(),R();break;case r.ELabelPlacement.Axis:case r.ELabelPlacement.Auto:V();break;default:throw Error("Unexpected LabelPlacement "+f)}return f!==r.ELabelPlacement.Auto&&f!==r.ELabelPlacement.Axis&&(E<C.top&&(E=C.top),E+y>C.bottom&&(E=C.bottom-y),x<C.left&&(x=C.left),x+m>C.right&&(x=C.right-m)),{xPosition:x,yPosition:E}};t.getLabelCoordinates=l;var u=function(d,f,h,p,g,v,y,m){var b=m.axisAlignment,S=m.parentSurface.seriesViewRect,_=m.viewRect,C=d,P=f,x=h,E=p;switch(y){case r.ELabelPlacement.Right:switch(b){case n.EAxisAlignment.Right:C=Math.abs(d-h)<v?x:d-v;break;case n.EAxisAlignment.Left:x=h>S.width?S.width-v:h-v;break}break;case r.ELabelPlacement.Bottom:switch(b){case n.EAxisAlignment.Top:E=p>S.height?S.height-g:p-g;break;case n.EAxisAlignment.Bottom:P=Math.abs(f-p)<g?E:f-g;break}break;case r.ELabelPlacement.Left:switch(b){case n.EAxisAlignment.Right:x=h<0?v:h+v;break;case n.EAxisAlignment.Left:C=Math.abs(d-h)<v?x:d+v;break}break;case r.ELabelPlacement.Top:switch(b){case n.EAxisAlignment.Top:P=Math.abs(f-p)<g?E:f+g;break;case n.EAxisAlignment.Bottom:E=p<0?g:p+g;break}break;case r.ELabelPlacement.Auto:case r.ELabelPlacement.Axis:switch(b){case n.EAxisAlignment.Right:C=_.width<v?S.width+_.width-v:S.width,x>C&&(x=C);break;case n.EAxisAlignment.Left:C=_.width<v?v-_.width:0,x<C&&(x=C);break;case n.EAxisAlignment.Top:P=_.height<g?g-_.height:0,E<P&&(E=P);break;case n.EAxisAlignment.Bottom:P=_.height<g?_.bottom-g:S.bottom,E>P&&(E=P);break}break}return{x1LineCoord:C,y1LineCoord:P,x2LineCoord:x,y2LineCoord:E}};t.getLineCoordinates=u;var c=function(d,f){var h,p=d.getCurrentCoordinateCalculator();if(d.isCategoryAxis){var g=p.getDataValue(f);h=p.transformIndexToData(g)}else h=p.getDataValue(f);return d.labelProvider.formatCursorLabel(h)};t.getLabelValue=c})(xF)),xF}var gye;function UFe(){if(gye)return M1;gye=1;var t=M1&&M1.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(M1,"__esModule",{value:!0}),M1.AxisMarkerAnnotation=void 0;var e=ci(),i=$i(),n=Vf(),r=Eo(),o=An(),a=_v(),s=Zi(),l=Ca(),u=II(),c=gl(),d=jl(),f=Qa(),h=FI(),p=(function(g){t(v,g);function v(y){var m=this,b,S,_,C,P,x,E,A,R,M,D;return m=g.call(this,y)||this,m.type=f.EAnnotationType.RenderContextAxisMarkerAnnotation,m.clippingProperty=u.EAnnotationClippingMode.Chart,m.fontSizeProperty=14,m.fontFamilyProperty=(0,n.getDefaultFontName)(),m.fontWeightProperty="Normal",m.fontStyleProperty="Normal",m.colorProperty="#FFFFFF",m.backgroundColorProperty="#b36200",m.fontSizeProperty=(b=y==null?void 0:y.fontSize)!==null&&b!==void 0?b:m.fontSizeProperty,m.fontFamilyProperty=(S=y==null?void 0:y.fontFamily)!==null&&S!==void 0?S:m.fontFamilyProperty,m.fontWeightProperty=(_=y==null?void 0:y.fontWeight)!==null&&_!==void 0?_:m.fontWeightProperty,m.fontStyleProperty=(C=y==null?void 0:y.fontStyle)!==null&&C!==void 0?C:m.fontStyleProperty,m.colorProperty=(P=y==null?void 0:y.color)!==null&&P!==void 0?P:m.colorProperty,m.paddingProperty=(x=y==null?void 0:y.padding)!==null&&x!==void 0?x:m.paddingProperty,m.backgroundColorProperty=(E=y==null?void 0:y.backgroundColor)!==null&&E!==void 0?E:m.backgroundColorProperty,m.formattedValueProperty=(A=y==null?void 0:y.formattedValue)!==null&&A!==void 0?A:m.formattedValueProperty,m.imageProperty=(R=y==null?void 0:y.image)!==null&&R!==void 0?R:m.imageProperty,m.imageWidthProperty=(M=y==null?void 0:y.imageWidth)!==null&&M!==void 0?M:m.imageWidthProperty,m.imageHeightProperty=(D=y==null?void 0:y.imageHeight)!==null&&D!==void 0?D:m.imageHeightProperty,y!=null&&y.x1&&(m.x1=y.x1),y!=null&&y.x2&&(m.x2=y.x2),y!=null&&y.y2&&(m.y2=y.y2),m}return v.prototype.delete=function(){},Object.defineProperty(v.prototype,"y2",{get:function(){throw Error("y2 property is not supported for AxisMarkerAnnotation")},set:function(y){throw Error("y2 property is not supported for AxisMarkerAnnotation")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"x2",{get:function(){throw Error("x2 property is not supported for AxisMarkerAnnotation")},set:function(y){throw Error("x2 property is not supported for AxisMarkerAnnotation")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"backgroundColor",{get:function(){return this.backgroundColorProperty},set:function(y){this.backgroundColorProperty=y,this.notifyPropertyChanged(d.PROPERTY.BACKGROUND_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"color",{get:function(){return this.colorProperty},set:function(y){this.colorProperty=y,this.notifyPropertyChanged(d.PROPERTY.COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fontSize",{get:function(){return this.fontSizeProperty},set:function(y){this.fontSizeProperty=y,this.notifyPropertyChanged(d.PROPERTY.FONT_SIZE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fontFamily",{get:function(){return this.fontFamilyProperty},set:function(y){this.fontFamilyProperty=y,this.notifyPropertyChanged(d.PROPERTY.FONT_FAMILY)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fontWeight",{get:function(){return this.fontWeightProperty},set:function(y){this.fontWeightProperty=y,this.notifyPropertyChanged(d.PROPERTY.FONT_WEIGHT)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fontStyle",{get:function(){return this.fontStyleProperty},set:function(y){this.fontStyleProperty=y,this.notifyPropertyChanged(d.PROPERTY.FONT_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"padding",{get:function(){return this.paddingProperty},set:function(y){this.paddingProperty=y,this.notifyPropertyChanged(d.PROPERTY.PADDING)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"formattedValue",{get:function(){return this.formattedValueProperty},set:function(y){this.formattedValueProperty=y,this.notifyPropertyChanged(d.PROPERTY.FORMATTED_VALUE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"image",{get:function(){return this.imageProperty},set:function(y){this.imageProperty=y,this.notifyPropertyChanged(d.PROPERTY.IMAGE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"imageWidth",{get:function(){return this.imageWidthProperty},set:function(y){this.imageWidthProperty=y,this.notifyPropertyChanged(d.PROPERTY.IMAGE_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"imageHeight",{get:function(){return this.imageHeightProperty},set:function(y){this.imageHeightProperty=y,this.notifyPropertyChanged(d.PROPERTY.IMAGE_HEIGHT)},enumerable:!1,configurable:!0}),v.prototype.drawWithContext=function(y,m,b,S,_,C){e.Guard.notNull(y,"renderContext"),e.Guard.notNull(m,"xCalc"),e.Guard.notNull(b,"yCalc");var P=this.getX1Coordinate(m,b),x=this.getY1Coordinate(m,b),E=function(k){return k==null},A=E(this.x1),R=A?this.y1:this.x1;e.Guard.argumentIsRealNumber(R,"x1 or y1");var M=A?this.yAxis:this.xAxis;if(!(!M||M.isVisible===!1)){var D=A?this.yCoordinateMode:this.xCoordinateMode,F=A?b:m,I=this.getCoordinate(R,F,D),V=M.isHorizontalAxis?I>=0&&I<=S.width:I>=0&&I<=S.height;if(V){var z={fontFamily:this.fontFamilyProperty,fontSize:this.fontSizeProperty*s.DpiHelper.PIXEL_RATIO,fontStyle:this.fontStyleProperty,color:this.colorProperty},G=(0,a.drawAxisMarkerAnnotation)(M,y,this.formattedValueProperty,I,P,x,z,this.backgroundColorProperty,this.opacity,this.image,this.imageWidth,this.imageHeight),H=(0,o.translateFromCanvasToSeriesViewRect)(new i.Point(G.xPosition,G.yPosition),S,!0),U=(0,o.translateFromCanvasToSeriesViewRect)(new i.Point(G.xPosition+G.textureWidth,G.yPosition+G.textureHeight),S,!0);this.setAnnotationBorders(H.x,U.x,H.y,U.y),this.updateAdornerInner()}else this.deleteAdorner()}},v.prototype.onDragStarted=function(y){g.prototype.onDragStarted.call(this,y);var m=this.calculateAdornerCenter(),b=m.x,S=m.y,_=(0,o.translateFromCanvasToSeriesViewRect)(new i.Point(y.mousePoint.x,y.mousePoint.y),this.parentSurface.seriesViewRect,!0),C=(0,o.translateFromCanvasToSeriesViewRect)(new i.Point(b*s.DpiHelper.PIXEL_RATIO,S*s.DpiHelper.PIXEL_RATIO),this.parentSurface.seriesViewRect,!0);if(_){if(C){var P=(0,r.calcDistance)(C.x,C.y,_.x,_.y);if(P<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x1y1,!0}if(this.clickToSelect(y))return this.adornerDraggingPoint=l.EDraggingGripPoint.Body,!0}return!1},v.prototype.calcDragDistance=function(y){if(!this.prevValue){this.prevValue=y;return}this.x1!==void 0?this.x1-=this.prevValue.x-y.x:this.y1!==void 0&&(this.y1-=this.prevValue.y-y.y),this.prevValue=y},v.prototype.toJSON=function(){var y=g.prototype.toJSON.call(this),m={backgroundColor:this.backgroundColor,color:this.color,fontFamily:this.fontFamily,fontSize:this.fontSize,fontStyle:this.fontStyle,fontWeight:this.fontWeight,formattedValue:this.formattedValue,padding:this.padding,image:void 0,imageHeight:this.imageHeight,imageWidth:this.imageWidth};return Object.assign(y.options,m),y},v.prototype.checkIsClickedOnAnnotationInternal=function(y,m){var b=this.getAnnotationBorders(!0),S=b.x1,_=b.x2,C=b.y1,P=b.y2;return(0,r.testIsInBounds)(y,m,S,P,_,C)},v.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var y=this.getAdornerAnnotationBorders(!0,!0),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=this.svgStringAdornerTemplate(m,S,b,_),P=this.applySvgClipping(C,this.adornerClipping);this.svgAdorner=c.annotationHelpers.createSvg(P,this.svgAdornerRoot)}},v.prototype.svgStringAdornerTemplate=function(y,m,b,S){var _=this.selectionBoxStroke,C=this.calculateAdornerCenter(),P=C.x,x=C.y,E=b-y,A=S-m;return`<svg xmlns="http://www.w3.org/2000/svg">
        <rect x="`.concat(y,'" y="').concat(m,'" width="').concat(E,'" height="').concat(A,'" stroke="').concat(_,'" stroke-width="').concat(this.selectionBoxThickness,`px" fill="none" />
        `).concat(this.getAnnotationGripSvg(P,x),`
        </svg>`)},v.prototype.calculateAdornerCenter=function(){var y=this.getAdornerAnnotationBorders(),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=Math.abs((m+b)/2),P=Math.abs((S+_)/2);return{x:C,y:P}},v})(h.RenderContextAnnotationBase);return M1.AxisMarkerAnnotation=p,M1}var L1={},vye;function zFe(){if(vye)return L1;vye=1;var t=L1&&L1.__extends||(function(){var b=function(S,_){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(C,P){C.__proto__=P}||function(C,P){for(var x in P)Object.prototype.hasOwnProperty.call(P,x)&&(C[x]=P[x])},b(S,_)};return function(S,_){if(typeof _!="function"&&_!==null)throw new TypeError("Class extends value "+String(_)+" is not a constructor or null");b(S,_);function C(){this.constructor=S}S.prototype=_===null?Object.create(_):(C.prototype=_.prototype,new C)}})();Object.defineProperty(L1,"__esModule",{value:!0}),L1.BoxAnnotation=void 0;var e=Uo(),i=Br(),n=ci(),r=$i(),o=Rn(),a=vs(),s=pl(),l=Eo(),u=An(),c=tu(),d=Ls(),f=Zi(),h=Ca(),p=gl(),g=jl(),v=Qa(),y=FI(),m=(function(b){t(S,b);function S(_){var C=this,P,x,E;return C=b.call(this,_)||this,C.type=v.EAnnotationType.RenderContextBoxAnnotation,C.surfaceTypes=[a.ESurfaceType.SciChartSurfaceType,a.ESurfaceType.SciChartPolarSurfaceType],C.strokeThicknessProperty=1,C.stroke=(P=_==null?void 0:_.stroke)!==null&&P!==void 0?P:"#ffffff",C.strokeThickness=(x=_==null?void 0:_.strokeThickness)!==null&&x!==void 0?x:1,C.fill=(E=_==null?void 0:_.fill)!==null&&E!==void 0?E:"#777777",C}return Object.defineProperty(S.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(_){this.strokeProperty=_,this.notifyPropertyChanged(g.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(S.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(_){this.strokeThicknessProperty=_,this.notifyPropertyChanged(g.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(S.prototype,"fill",{get:function(){return this.fillProperty},set:function(_){this.fillProperty=_,this.notifyPropertyChanged(g.PROPERTY.FILL)},enumerable:!1,configurable:!0}),S.prototype.delete=function(){this.strokePenCache=(0,i.deleteSafe)(this.strokePenCache),this.fillBrushCache=(0,i.deleteSafe)(this.fillBrushCache),this.nativeDrawingProvider=(0,i.deleteSafe)(this.nativeDrawingProvider),this.xValues=(0,i.deleteSafe)(this.xValues),this.yValues=(0,i.deleteSafe)(this.yValues)},S.prototype.drawWithContext=function(_,C,P,x,E,A){n.Guard.notNull(_,"renderContext"),n.Guard.notNull(C,"xCalc"),n.Guard.notNull(P,"yCalc");var R=this.stroke&&this.strokeThickness?(0,d.getWebGlPenFromCache)(this.strokePenCache):void 0;R==null||R.setOpacity(this.opacity);var M=this.fill?(0,c.getWebGlBrushFromCache)(this.fillBrushCache):void 0;M==null||M.setOpacity(this.opacity);var D=this.convertPolarToCartesian(this.getX1Coordinate(C,P),this.getY1Coordinate(C,P)),F=D.x,I=D.y,V=this.convertPolarToCartesian(this.getX2Coordinate(C,P),this.getY2Coordinate(C,P)),z=V.x,G=V.y;this.setAnnotationBorders(F,z,I,G);var H=o.Rect.createWithPoints(new r.Point(F,I),new r.Point(z,G));if(!e.IS_TEST_ENV){var U=this.getClippingRect(this.clipping,x,E,A);this.strokeThickness>0?this.drawWithProvider(_,R.scrtPen,M.scrtBrush,C,P,H,x,U):_.drawRect(H,x,U,R,M,!1,this.strokeThickness)}this.updateAdornerInner()},S.prototype.onAttach=function(_){b.prototype.onAttach.call(this,_),this.nativeDrawingProvider=new _.webAssemblyContext2D.SCRTColumnSeriesDrawingProvider,this.strokePenCache||(this.strokePenCache=new d.Pen2DCache(_.webAssemblyContext2D)),(0,d.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness,this.opacity),this.fillBrushCache||(this.fillBrushCache=new c.BrushCache(_.webAssemblyContext2D)),(0,c.createBrushInCache)(this.fillBrushCache,this.fill,this.opacity)},S.prototype.onDragStarted=function(_){b.prototype.onDragStarted.call(this,_);var C=this.getAnnotationBorders(!1,!0),P=C.x1,x=C.x2,E=C.y1,A=C.y2,R=p.annotationHelpers.calcNewApex(P,E,x,A,this.isVerticalChart),M=R.x1y1,D=R.x2y1,F=R.x1y2,I=R.x2y2,V=(0,u.translateFromCanvasToSeriesViewRect)(new r.Point(_.mousePoint.x,_.mousePoint.y),this.parentSurface.seriesViewRect,!0);if(M&&this.canDragPoint(h.EDraggingGripPoint.x1y1)){var z=(0,l.calcDistance)(M.x,M.y,V.x,V.y);if(z<this.annotationsGripsRadius*f.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=h.EDraggingGripPoint.x1y1,!0}if(D&&this.canDragPoint(h.EDraggingGripPoint.x2y1)){var z=(0,l.calcDistance)(D.x,D.y,V.x,V.y);if(z<this.annotationsGripsRadius*f.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=h.EDraggingGripPoint.x2y1,!0}if(F&&this.canDragPoint(h.EDraggingGripPoint.x1y2)){var z=(0,l.calcDistance)(F.x,F.y,V.x,V.y);if(z<this.annotationsGripsRadius*f.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=h.EDraggingGripPoint.x1y2,!0}if(I&&this.canDragPoint(h.EDraggingGripPoint.x2y2)){var z=(0,l.calcDistance)(I.x,I.y,V.x,V.y);if(z<this.annotationsGripsRadius*f.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=h.EDraggingGripPoint.x2y2,!0}return V&&this.canDragPoint(h.EDraggingGripPoint.Body)&&this.clickToSelect(_)?(this.adornerDraggingPoint=h.EDraggingGripPoint.Body,!0):!1},S.prototype.calcDragDistance=function(_){if(!this.prevValue){this.prevValue=_;return}this.adornerDraggingPoint===h.EDraggingGripPoint.Body?(this.x1=this.x1-(this.prevValue.x-_.x),this.x2=this.x2-(this.prevValue.x-_.x),this.y1=this.y1-(this.prevValue.y-_.y),this.y2=this.y2-(this.prevValue.y-_.y)):this.adornerDraggingPoint===h.EDraggingGripPoint.x1y1?this.resizeDirections===s.EXyDirection.XDirection?this.x1-=this.prevValue.x-_.x:this.resizeDirections===s.EXyDirection.YDirection?this.y1-=this.prevValue.y-_.y:(this.x1-=this.prevValue.x-_.x,this.y1-=this.prevValue.y-_.y):this.adornerDraggingPoint===h.EDraggingGripPoint.x2y2?this.resizeDirections===s.EXyDirection.XDirection?this.x2-=this.prevValue.x-_.x:this.resizeDirections===s.EXyDirection.YDirection?this.y2-=this.prevValue.y-_.y:(this.x2-=this.prevValue.x-_.x,this.y2-=this.prevValue.y-_.y):this.adornerDraggingPoint===h.EDraggingGripPoint.x2y1?this.resizeDirections===s.EXyDirection.XDirection?this.x2-=this.prevValue.x-_.x:this.resizeDirections===s.EXyDirection.YDirection?this.y1-=this.prevValue.y-_.y:(this.x2-=this.prevValue.x-_.x,this.y1-=this.prevValue.y-_.y):this.adornerDraggingPoint===h.EDraggingGripPoint.x1y2&&(this.resizeDirections===s.EXyDirection.XDirection?this.x1-=this.prevValue.x-_.x:this.resizeDirections===s.EXyDirection.YDirection?this.y2-=this.prevValue.y-_.y:(this.x1-=this.prevValue.x-_.x,this.y2-=this.prevValue.y-_.y)),this.prevValue=_},S.prototype.onDpiChanged=function(_){b.prototype.onDpiChanged.call(this,_),this.notifyPropertyChanged(g.PROPERTY.STROKE)},S.prototype.toJSON=function(){var _=b.prototype.toJSON.call(this),C={fill:this.fill,stroke:this.stroke,strokeThickness:this.strokeThickness};return Object.assign(_.options,C),_},S.prototype.checkIsClickedOnAnnotationInternal=function(_,C){var P=this.getAnnotationBorders(!0),x=P.x1,E=P.x2,A=P.y1,R=P.y2;return(0,l.testIsInBounds)(_,C,x,R,E,A)},S.prototype.notifyPropertyChanged=function(_){b.prototype.notifyPropertyChanged.call(this,_);var C=[g.PROPERTY.STROKE,g.PROPERTY.STROKE_THICKNESS,g.PROPERTY.STROKE_DASH_ARRAY,g.PROPERTY.OPACITY];this.strokePenCache&&C.includes(_)&&(0,d.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness,this.opacity);var P=[g.PROPERTY.FILL,g.PROPERTY.OPACITY];this.fillBrushCache&&P.includes(_)&&(0,c.createBrushInCache)(this.fillBrushCache,this.fill,this.opacity)},S.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var _=this.getAdornerAnnotationBorders(!0,!0),C=_.x1,P=_.x2,x=_.y1,E=_.y2,A=this.svgStringAdornerTemplate(C,x,P,E),R=this.applySvgClipping(A,this.adornerClipping);this.svgAdorner=p.annotationHelpers.createSvg(R,this.svgAdornerRoot)}},S.prototype.svgStringAdornerTemplate=function(_,C,P,x){var E=this.selectionBoxStroke,A=P-_,R=x-C,M=`<svg xmlns="http://www.w3.org/2000/svg">
        <rect x="`.concat(_,'" y="').concat(C,'" width="').concat(A,'" height="').concat(R,'" stroke="').concat(E,'" stroke-width="').concat(this.selectionBoxThickness,`px" fill="none" />
        `),D=this.getAdornerAnnotationBorders(!1,!0);return this.canDragPoint(h.EDraggingGripPoint.x1y1)&&(M+=this.getAnnotationGripSvg(D.x1,D.y1)),this.canDragPoint(h.EDraggingGripPoint.x2y2)&&(M+=this.getAnnotationGripSvg(D.x2,D.y2)),this.canDragPoint(h.EDraggingGripPoint.x2y1)&&(M+=this.getAnnotationGripSvg(D.x2,D.y1)),this.canDragPoint(h.EDraggingGripPoint.x1y2)&&(M+=this.getAnnotationGripSvg(D.x1,D.y2)),M+="</svg>",M},S.prototype.drawWithProvider=function(_,C,P,x,E,A,R,M){var D=this.parentSurface.webAssemblyContext2D,F=new D.SCRTColumnDrawingParams;F.forceShaderMethod=!0,F.verticalChart=this.isVerticalChart,F.zeroLineY=this.isVerticalChart?E.getDataValue(A.left):E.getDataValue(A.bottom),F.columnWidth=this.isVerticalChart?A.height:A.width,F.clipCoordinates=!1,C&&F.SetLinesPen(C),P&&F.SetFillBrush(P),F.viewportWidth=R.width,F.viewportHeight=R.height;var I=this.isVerticalChart?(A.top+A.bottom)/2:(A.left+A.right)/2,V=x.getDataValue(I);this.xValues?this.xValues.clear():this.xValues=new D.SCRTDoubleVector(1),this.xValues.push_back(V);var z=this.isVerticalChart?E.getDataValue(A.right):E.getDataValue(A.top);this.yValues?this.yValues.clear():this.yValues=new D.SCRTDoubleVector(1),this.yValues.push_back(z),F.count=1;var G=_,H=G.getNativeContext();G.setTranslationRotationAndClip(M,R.x,R.y),F.SetNativeContext(H),F.SetXValues(this.xValues),F.SetYValues(this.yValues),F.SetXCoordinateCalculator(x.nativeCalculator),F.SetYCoordinateCalculator(E.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(F),F.delete()},S})(y.RenderContextAnnotationBase);return L1.BoxAnnotation=m,L1}var k1={},I1={},N1={},yye;function Wre(){if(yye)return N1;yye=1;var t=N1&&N1.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(N1,"__esModule",{value:!0}),N1.DomAnnotationBase=void 0;var e=$i(),i=jv(),n=II(),r=Eo(),o=An(),a=Wf(),s=Zi(),l=Ca(),u=gl(),c=jl(),d=(function(p){t(g,p);function g(v){var y=this,m,b,S,_,C;return y=p.call(this,v)||this,y.isDomAnnotation=!0,y.isDeleted=!1,y.xCoordShiftProperty=0,y.yCoordShiftProperty=0,y.verticalAnchorPointProperty=i.EVerticalAnchorPoint.Top,y.horizontalAnchorPointProperty=i.EHorizontalAnchorPoint.Left,y.prevX1Coordinate=0,y.prevY1Coordinate=0,y.xCoordSvgTransProperty=0,y.yCoordSvgTransProperty=0,y.reDrawChartOnChange=!1,y.xCoordShiftProperty=(m=v==null?void 0:v.xCoordShift)!==null&&m!==void 0?m:y.xCoordShiftProperty,y.yCoordShiftProperty=(b=v==null?void 0:v.yCoordShift)!==null&&b!==void 0?b:y.yCoordShiftProperty,y.verticalAnchorPointProperty=(S=v==null?void 0:v.verticalAnchorPoint)!==null&&S!==void 0?S:y.verticalAnchorPointProperty,y.horizontalAnchorPointProperty=(_=v==null?void 0:v.horizontalAnchorPoint)!==null&&_!==void 0?_:y.horizontalAnchorPointProperty,y.reDrawChartOnChange=(C=v==null?void 0:v.reDrawChartOnChange)!==null&&C!==void 0?C:a.SciChartDefaults.alwaysRedrawFullChartOnSvgChange,y}return g.prototype.onAttach=function(v){p.prototype.onAttach.call(this,v),this.selectLayerRoot()},Object.defineProperty(g.prototype,"xCoordShift",{get:function(){return this.xCoordShiftProperty},set:function(v){this.xCoordShiftProperty!==v&&(this.xCoordShiftProperty=v,this.notifyPropertyChanged(c.PROPERTY.X_COORD_SHIFT))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"yCoordShift",{get:function(){return this.yCoordShiftProperty},set:function(v){this.yCoordShiftProperty!==v&&(this.yCoordShiftProperty=v,this.notifyPropertyChanged(c.PROPERTY.Y_COORD_SHIFT))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"verticalAnchorPoint",{get:function(){return this.verticalAnchorPointProperty},set:function(v){this.verticalAnchorPointProperty!==v&&(this.verticalAnchorPointProperty=v,this.notifyPropertyChanged(c.PROPERTY.VERTICAL_ANCHOR_POINT))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"horizontalAnchorPoint",{get:function(){return this.horizontalAnchorPointProperty},set:function(v){this.horizontalAnchorPointProperty!==v&&(this.horizontalAnchorPointProperty=v,this.notifyPropertyChanged(c.PROPERTY.HORIZONTAL_ANCHOR_POINT))},enumerable:!1,configurable:!0}),g.prototype.suspendInvalidate=function(){p.prototype.suspendInvalidate.call(this),this.invalidateState.xCoordShift=this.xCoordShift,this.invalidateState.yCoordShift=this.yCoordShift},g.prototype.resumeInvalidate=function(){this.invalidateState&&((this.isHidden!==this.invalidateState.isHidden||this.x1!==this.invalidateState.x1||this.y1!==this.invalidateState.y1||this.xCoordShift!==this.invalidateState.xCoordShift||this.yCoordShift!==this.invalidateState.yCoordShift)&&this.invalidateParentCallback&&this.invalidateParentCallback({svgOnly:!this.reDrawChartOnChange}),this.invalidateState=void 0,p.prototype.resumeInvalidate.call(this))},g.prototype.calcDragDistance=function(v){if(!this.prevValue){this.prevValue=v;return}if(this.adornerDraggingPoint===l.EDraggingGripPoint.Body||this.adornerDraggingPoint===l.EDraggingGripPoint.x1y1){var y=this.x1+this.applyPixelRatioToDragDist(v.x-this.prevValue.x),m=this.y1+v.y-this.prevValue.y;this.x2!==void 0&&(this.x2=this.x2+this.applyPixelRatioToDragDist(v.x-this.prevValue.x)),this.y2!==void 0&&(this.y2=this.y2+v.y-this.prevValue.y),this.parentSurface.isPolar&&this.x1===0&&this.y1===0&&(y=v.x,m=v.y),this.x1=y,this.y1=m}this.prevValue=v},g.prototype.getAnnotationBorders=function(v,y){var m=p.prototype.getAnnotationBorders.call(this,v,y),b=m.x1,S=m.x2,_=m.y1,C=m.y2;return{x1:b+this.xCoordSvgTransProperty,x2:S+this.xCoordSvgTransProperty,y1:_+this.yCoordSvgTransProperty,y2:C+this.yCoordSvgTransProperty}},g.prototype.getAdornerAnnotationBorders=function(v){var y=p.prototype.getAdornerAnnotationBorders.call(this,v),m=y.x1,b=y.x2,S=y.y1,_=y.y2;return{x1:m+this.xCoordSvgTransProperty,x2:b+this.xCoordSvgTransProperty,y1:S+this.yCoordSvgTransProperty,y2:_+this.yCoordSvgTransProperty}},g.prototype.onDragStarted=function(v){p.prototype.onDragStarted.call(this,v);var y=this.getAnnotationBorders(),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=new e.Point(m,S),P=m,x=S,E=Math.abs((S-_)/2),A=Math.abs((m-b)/2);this.verticalAnchorPoint===i.EVerticalAnchorPoint.Center&&(x=x+E),this.horizontalAnchorPoint===i.EHorizontalAnchorPoint.Center&&(P=P+A);var R=(0,o.translateFromCanvasToSeriesViewRect)(new e.Point(v.mousePoint.x,v.mousePoint.y),this.parentSurface.seriesViewRect,this.clipping!==n.EAnnotationClippingMode.SeriesViewRect);if(!R)return!1;if(C&&this.canDragPoint(l.EDraggingGripPoint.x1y1)){var M=(0,r.calcDistance)(P,x,(0,o.translateToNotScaled)(R.x),(0,o.translateToNotScaled)(R.y));if(M<this.annotationsGripsRadius)return this.adornerDraggingPoint=l.EDraggingGripPoint.x1y1,!0}return this.canDragPoint(l.EDraggingGripPoint.Body)&&this.clickToSelect(v)?(this.adornerDraggingPoint=l.EDraggingGripPoint.Body,!0):!1},g.prototype.delete=function(){this.isDeleted=!0},g.prototype.toJSON=function(){var v=p.prototype.toJSON.call(this),y={xCoordShift:this.xCoordShift,yCoordShift:this.yCoordShift,verticalAnchorPoint:this.verticalAnchorPoint,horizontalAnchorPoint:this.horizontalAnchorPoint,reDrawChartOnChange:this.reDrawChartOnChange};return Object.assign(v.options,y),v},g.prototype.checkIsClickedOnAnnotationInternal=function(v,y){var m=this.getAnnotationBorders(!0),b=m.x1,S=m.x2,_=m.y1,C=m.y2,P=v/s.DpiHelper.PIXEL_RATIO+this.xCoordSvgTransProperty,x=y/s.DpiHelper.PIXEL_RATIO+this.yCoordSvgTransProperty;return(0,r.testIsInBounds)(P,x,b,C,S,_)},g.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var v=this.getAnnotationBorders(!0),y=v.x1,m=v.x2,b=v.y1,S=v.y2,_=this.svgStringAdornerTemplate(y,b,m,S),C=this.applySvgClipping(_,this.adornerClipping);this.svgAdorner=u.annotationHelpers.createSvg(C,this.svgAdornerRoot)}},g.prototype.notifyPropertyChanged=function(v){v===c.PROPERTY.ANNOTATION_CANVAS&&this.selectLayerRoot(),this.invalidateParentCallback&&!this.invalidateState&&this.invalidateParentCallback({svgOnly:!this.reDrawChartOnChange})},g.prototype.calcAndSetAnnotationBorders=function(v,y){var m=this.getSize();if(m){var b=m.width,S=m.height,_=this.convertPolarToCartesian(this.getX1Coordinate(v,y),this.getY1Coordinate(v,y),!0),C=_.x,P=_.y,x=this.convertPolarToCartesian(this.getX2Coordinate(v,y),this.getY2Coordinate(v,y),!0),E=x.x,A=x.y,R=C+this.xCoordShift,M=P+this.yCoordShift,D=R+b,F=M+S;if(this.isVerticalChart?this.y2===void 0:this.x2===void 0){var I=h(this.horizontalAnchorPoint,R,D,b),V=I.x1,z=I.x2;R=V,D=z}else D=E+this.xCoordShift;if(this.isVerticalChart?this.x2===void 0:this.y2===void 0){var G=f(this.verticalAnchorPoint,M,F,S),H=G.y1,U=G.y2;M=H,F=U}else F=A+this.yCoordShift;this.setAnnotationBorders(R,D,M,F)}},g.prototype.svgStringAdornerTemplate=function(v,y,m,b){var S=v,_=y,C=Math.abs((y-b)/2),P=Math.abs((v-m)/2);return this.verticalAnchorPoint===i.EVerticalAnchorPoint.Center&&(_=_+C),this.horizontalAnchorPoint===i.EHorizontalAnchorPoint.Center&&(S=S+P),`<svg xmlns="http://www.w3.org/2000/svg">
        <rect x="`.concat(v,'" y="').concat(y,'" width="').concat(Math.abs(v-m),'" height="').concat(Math.abs(y-b),'" stroke="').concat(this.selectionBoxStroke,'" stroke-width="').concat(this.selectionBoxThickness,`px" fill="none" />
        `).concat(this.canDragPoint(l.EDraggingGripPoint.x1y1)?this.getAnnotationGripSvg(S,_):"",`
      </svg>`)},g})(l.AnnotationBase);N1.DomAnnotationBase=d;function f(p,g,v,y){return p===i.EVerticalAnchorPoint.Bottom&&(v=g-y),p===i.EVerticalAnchorPoint.Center&&(v=g+y/2,g=g-y/2),{y1:g,y2:v}}function h(p,g,v,y){return p===i.EHorizontalAnchorPoint.Right?(v=g-y,{x1:v,x2:g}):(p===i.EHorizontalAnchorPoint.Center&&(v=g+y/2,g=g-y/2),{x1:g,x2:v})}return N1}var mye;function Dm(){if(mye)return I1;mye=1;var t=I1&&I1.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(I1,"__esModule",{value:!0}),I1.SvgAnnotationBase=void 0;var e=jv(),i=jl(),n=Wre(),r=Qa(),o=(function(a){t(s,a);function s(l){var u=a.call(this,l)||this;return u.isSvgAnnotation=!0,u}return s.prototype.onDetach=function(){a.prototype.onDetach.call(this),this.delete()},s.prototype.update=function(l,u,c,d){var f,h;this.xCoordSvgTransProperty=c,this.yCoordSvgTransProperty=d,this.create(l,u,c,d);var p=(f=this.xCoordShift)!==null&&f!==void 0?f:0,g=(h=this.yCoordShift)!==null&&h!==void 0?h:0,v=this.getSvgDomRect(),y=v.width,m=v.height;this.horizontalAnchorPointProperty===e.EHorizontalAnchorPoint.Center?p-=y/2:this.horizontalAnchorPointProperty===e.EHorizontalAnchorPoint.Right&&(p-=y),this.verticalAnchorPointProperty===e.EVerticalAnchorPoint.Center?g-=m/2:this.verticalAnchorPointProperty===e.EVerticalAnchorPoint.Bottom&&(g-=m),this.svg.style.visibility=this.isHidden?"hidden":"visible",this.svg.style.opacity=this.opacity.toString();var b=this.convertPolarToCartesian(this.getX1Coordinate(l,u),this.getY1Coordinate(l,u),!0),S=b.x,_=b.y,C=p+S+c,P=g+_+d;isNaN(C)||isNaN(P)||!isFinite(C)||!isFinite(P)?this.svg.style.display="none":(this.setSvgAttribute("x",C),this.setSvgAttribute("y",P))},s.prototype.delete=function(){this.clear(),a.prototype.delete.call(this)},Object.defineProperty(s.prototype,"svg",{get:function(){return this.svgProperty},enumerable:!1,configurable:!0}),s.prototype.getSvgDomRect=function(){var l,u,c;return this.svgDOMRect||(this.svgDOMRect=(c=(u=(l=this.svg.firstChild)===null||l===void 0?void 0:l.getBBox)===null||u===void 0?void 0:u.call(l))!==null&&c!==void 0?c:this.svg.getBBox()),this.svgDOMRect},s.prototype.clear=function(){!this.parentSurface||this.parentSurface.isDeleted||!this.svg||(this.nextSibling=this.svg.nextElementSibling,this.svg.parentNode.removeChild(this.svg),this.svgDOMRect=void 0,this.setSvg(void 0))},s.prototype.create=function(l,u,c,d){this.xCoordSvgTransProperty=c,this.yCoordSvgTransProperty=d},Object.defineProperty(s.prototype,"svgRoot",{get:function(){return this.svgRootProperty},enumerable:!1,configurable:!0}),s.prototype.selectLayerRoot=function(){if(this.annotationLayer===r.EAnnotationLayer.AboveChart)this.svgRootProperty=this.parentSurface.domSvgContainer;else if(this.annotationLayer===r.EAnnotationLayer.BelowChart)this.svgRootProperty=this.parentSurface.domSvgContainer;else if(this.annotationLayer===r.EAnnotationLayer.Background)this.svgRootProperty=this.parentSurface.domBackgroundSvgContainer;else throw new Error('Unexpected annotationLayer value: "'.concat(this.annotationLayer,'!"'))},s.prototype.setSvgAttribute=function(l,u){var c=u.toString(10);this.svg.firstElementChild.setAttribute(l,c)},s.prototype.setSvg=function(l){this.svgProperty=l},s.prototype.applyClipping=function(l,u){return this.applySvgClipping(l,u)},s.prototype.notifyPropertyChanged=function(l){var u;l===i.PROPERTY.ANNOTATION_CANVAS&&!(!((u=this.svgRootProperty)===null||u===void 0)&&u.isConnected)&&(this.clear(),this.nextSibling=void 0),a.prototype.notifyPropertyChanged.call(this,l)},s.prototype.getSize=function(){if(this.svg){var l=this.getSvgDomRect(),u=l.width,c=l.height;return{width:u,height:c}}},s})(n.DomAnnotationBase);return I1.SvgAnnotationBase=o,I1}var bye;function Gre(){if(bye)return k1;bye=1;var t=k1&&k1.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(k1,"__esModule",{value:!0}),k1.CustomAnnotation=void 0;var e=vs(),i=gl(),n=Qa(),r=Dm(),o=(function(a){t(s,a);function s(l){var u=this,c;return u=a.call(this,l)||this,u.type=n.EAnnotationType.SVGCustomAnnotation,u.surfaceTypes=[e.ESurfaceType.SciChartSurfaceType,e.ESurfaceType.SciChartPolarSurfaceType],u.isPositionDependent=!1,u.isDirty=!0,u.svgStringProperty=(c=l==null?void 0:l.svgString)!==null&&c!==void 0?c:void 0,u}return Object.defineProperty(s.prototype,"svgString",{get:function(){return this.svgStringProperty},set:function(l){this.svgStringProperty!==l&&(this.isDirty=!0,this.svgStringProperty=l,this.notifyPropertyChanged("svgString"))},enumerable:!1,configurable:!0}),s.prototype.getSvgString=function(l){return l.svgString},s.prototype.updateSvg=function(l,u){return u},s.prototype.toJSON=function(){var l=a.prototype.toJSON.call(this),u={svgString:this.svgString};return Object.assign(l.options,u),l},s.prototype.create=function(l,u,c,d){if(this.svg&&!this.isDirty&&!this.isPositionDependent){this.calcAndSetAnnotationBorders(l,u),(this.isSelected||this.prevIsSelected!==this.isSelected)&&(this.updateAdornerInner(),this.prevIsSelected=this.isSelected);return}if(this.isDirty||!this.svg||this.svg&&this.isPositionDependent&&(this.prevX1Coordinate!==this.getX1Coordinate(l,u)||this.prevY1Coordinate!==this.getY1Coordinate(l,u))){this.prevX1Coordinate=this.getX1Coordinate(l,u),this.prevY1Coordinate=this.getY1Coordinate(l,u),this.svg&&this.clear();var f=this.getSvgString(this),h=this.applyClipping(f,this.clipping),p=i.annotationHelpers.createSvg(h,this.svgRoot,this.nextSibling);this.updateSvg(this,p.firstChild),this.setSvg(p),this.calcAndSetAnnotationBorders(l,u),this.updateAdornerInner(),this.prevIsSelected=this.isSelected,this.isDirty=!1}this.prevIsSelected!==this.isSelected&&this.svg&&this.isEditable&&(this.updateAdornerInner(),this.prevIsSelected=this.isSelected)},s})(r.SvgAnnotationBase);return k1.CustomAnnotation=o,k1}var F1={},Sye;function Yre(){if(Sye)return F1;Sye=1;var t=F1&&F1.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(F1,"__esModule",{value:!0}),F1.HtmlCustomAnnotation=void 0;var e=Qa(),i=Wre(),n=jl(),r=Ig(),o=vs(),a=(function(s){t(l,s);function l(u){var c=s.call(this,u)||this;return c.type=e.EAnnotationType.HtmlCustomAnnotation,c.isSvgAnnotation=!1,c.isDomAnnotation=!0,c.surfaceTypes=[o.ESurfaceType.SciChartSurfaceType,o.ESurfaceType.SciChartPolarSurfaceType],c.create(),c}return l.prototype.onAttach=function(u){s.prototype.onAttach.call(this,u),this.attachToLayerRoot()},l.prototype.onDetach=function(){s.prototype.onDetach.call(this),this.layerRoot.removeChild(this.htmlElement.parentElement)},Object.defineProperty(l.prototype,"htmlElement",{get:function(){return this.htmlElementProperty},enumerable:!1,configurable:!0}),l.prototype.update=function(u,c,d,f){var h=this;this.xCoordSvgTransProperty=d,this.yCoordSvgTransProperty=f,this.calcAndSetAnnotationBorders(u,c);var p=this.getAnnotationBorders(),g=p.x1,v=p.x2,y=p.y1,m=p.y2;if(this.htmlElementProperty.parentElement.style.opacity=this.opacity.toString(),isNaN(g)||isNaN(y)||!isFinite(g)||!isFinite(y))this.htmlElementProperty.parentElement.style.visibility="hidden";else if(this.htmlElementProperty.parentElement.style.visibility=this.isHidden?"hidden":"visible",this.htmlElementProperty.style.left="".concat(g,"px"),this.htmlElementProperty.style.top="".concat(y,"px"),this.x2!==void 0||this.y2!==void 0){(this.isVerticalChart?this.y2!==void 0:this.x2!==void 0)&&(this.htmlElementProperty.style.width="".concat(v-g,"px")),(this.isVerticalChart?this.x2!==void 0:this.y2!==void 0)&&(this.htmlElementProperty.style.height="".concat(m-y,"px")),this.calcAndSetAnnotationBorders(u,c);var b=this.getAnnotationBorders(),S=b.x1,_=b.y1;this.htmlElementProperty.style.left="".concat(S,"px"),this.htmlElementProperty.style.top="".concat(_,"px")}this.updateAdornerInner(),this.resizeObserver||(this.resizeObserver=new ResizeObserver(function(C){var P,x=h.measure();r.Size.isEqual(h.sizeProperty,x)||(h.sizeProperty=x,(P=h.invalidateParentCallback)===null||P===void 0||P.call(h,{svgOnly:!h.reDrawChartOnChange}))}),this.resizeObserver.observe(this.htmlElement,{box:"border-box"}))},l.prototype.delete=function(){var u,c;(c=(u=this.resizeObserver)===null||u===void 0?void 0:u.disconnect)===null||c===void 0||c.call(u),s.prototype.delete.call(this)},l.prototype.create=function(){if(!this.htmlElementProperty){var u=document.createElement("div");u.id="sciChartHtmlAnnotationContainer_".concat(this.id),u.className="sciChartHtmlAnnotationContainer",u.style.position="absolute",this.htmlElementProperty=u}},Object.defineProperty(l.prototype,"layerRoot",{get:function(){return this.layerRootProperty},enumerable:!1,configurable:!0}),l.prototype.attachToLayerRoot=function(){if(this.layerRoot){var u=document.createElement("div");u.style.visibility="hidden";var c=this.getClipPath(this.clipping);c&&(u.style.clipPath=c),u.appendChild(this.htmlElement),this.layerRoot.appendChild(u)}},l.prototype.selectLayerRoot=function(){var u,c,d;if(this.annotationLayer===e.EAnnotationLayer.AboveChart)this.layerRootProperty=(u=this.parentSurface)===null||u===void 0?void 0:u.domDivContainer;else if(this.annotationLayer===e.EAnnotationLayer.BelowChart)this.layerRootProperty=(c=this.parentSurface)===null||c===void 0?void 0:c.domDivContainer;else if(this.annotationLayer===e.EAnnotationLayer.Background)this.layerRootProperty=(d=this.parentSurface)===null||d===void 0?void 0:d.domSeriesBackground;else throw new Error('Unexpected annotationLayer value: "'.concat(this.annotationLayer,'!"'))},l.prototype.notifyPropertyChanged=function(u){var c,d;if(u===n.PROPERTY.ANNOTATION_CANVAS){(d=(c=this.layerRoot)===null||c===void 0?void 0:c.removeChild)===null||d===void 0||d.call(c,this.htmlElement.parentElement),s.prototype.notifyPropertyChanged.call(this,u),this.attachToLayerRoot();return}s.prototype.notifyPropertyChanged.call(this,u)},l.prototype.getSize=function(){if(this.htmlElementProperty)return this.sizeProperty||(this.sizeProperty=this.measure()),this.sizeProperty},l.prototype.measure=function(){var u=this.htmlElementProperty.getBoundingClientRect(),c=u.width,d=u.height;return new r.Size(c,d)},l})(i.DomAnnotationBase);return F1.HtmlCustomAnnotation=a,F1}var U0={},z0={},_ye;function rC(){if(_ye)return z0;_ye=1;var t=z0&&z0.__extends||(function(){var _=function(C,P){return _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(x,E){x.__proto__=E}||function(x,E){for(var A in E)Object.prototype.hasOwnProperty.call(E,A)&&(x[A]=E[A])},_(C,P)};return function(C,P){if(typeof P!="function"&&P!==null)throw new TypeError("Class extends value "+String(P)+" is not a constructor or null");_(C,P);function x(){this.constructor=C}C.prototype=P===null?Object.create(P):(x.prototype=P.prototype,new x)}})(),e=z0&&z0.__spreadArray||function(_,C,P){if(P||arguments.length===2)for(var x=0,E=C.length,A;x<E;x++)(A||!(x in C))&&(A||(A=Array.prototype.slice.call(C,0,x)),A[x]=C[x]);return _.concat(A||Array.prototype.slice.call(C))};Object.defineProperty(z0,"__esModule",{value:!0}),z0.LineAnnotation=void 0;var i=Br(),n=ci(),r=$i(),o=pa(),a=od(),s=Gy(),l=vs(),u=pl(),c=Vf(),d=Eo(),f=Ls(),h=_v(),p=Zi(),g=Ca(),v=gl(),y=jl(),m=Qa(),b=FI(),S=(function(_){t(C,_);function C(P){var x=this,E,A,R,M,D,F,I,V,z,G,H,U;return x=_.call(this,P)||this,x.type=m.EAnnotationType.RenderContextLineAnnotation,x.surfaceTypes=[l.ESurfaceType.SciChartSurfaceType,l.ESurfaceType.SciChartPolarSurfaceType],x.axisFontSizeProperty=14,x.axisFontFamilyProperty=(0,c.getDefaultFontName)(),x.strokeThicknessProperty=1,x.strokeDashArrayProperty=[],x.strokeProperty="#FFFFFF",x.showLabelProperty=!1,x.axisLabelStrokeProperty="#ffffff",x.axisLabelFillProperty="#b36200",x.labelPlacementProperty=s.ELabelPlacement.Auto,x.labelValueProperty="",x.labelPaddingProperty=new o.Thickness(3,4,3,4),x.labelCornerRadiusProperty=2,x.stroke=(E=P==null?void 0:P.stroke)!==null&&E!==void 0?E:x.strokeProperty,x.strokeThickness=(A=P==null?void 0:P.strokeThickness)!==null&&A!==void 0?A:x.strokeThicknessProperty,x.strokeDashArray=(R=P==null?void 0:P.strokeDashArray)!==null&&R!==void 0?R:x.strokeDashArrayProperty,x.showLabelProperty=(M=P==null?void 0:P.showLabel)!==null&&M!==void 0?M:x.showLabelProperty,x.axisLabelStrokeProperty=(D=P==null?void 0:P.axisLabelStroke)!==null&&D!==void 0?D:x.axisLabelStrokeProperty,x.axisLabelFillProperty=(F=P==null?void 0:P.axisLabelFill)!==null&&F!==void 0?F:x.axisLabelFillProperty,x.axisFontSizeProperty=(I=P==null?void 0:P.axisFontSize)!==null&&I!==void 0?I:x.axisFontSizeProperty,x.axisFontFamilyProperty=(V=P==null?void 0:P.axisFontFamily)!==null&&V!==void 0?V:x.axisFontFamilyProperty,x.labelPlacementProperty=(z=P==null?void 0:P.labelPlacement)!==null&&z!==void 0?z:x.labelPlacementProperty,x.labelValueProperty=(G=P==null?void 0:P.labelValue)!==null&&G!==void 0?G:x.labelValueProperty,x.labelPaddingProperty=(H=P==null?void 0:P.labelPadding)!==null&&H!==void 0?H:x.labelPaddingProperty,x.labelCornerRadiusProperty=(U=P==null?void 0:P.labelCornerRadius)!==null&&U!==void 0?U:x.labelCornerRadiusProperty,x}return Object.defineProperty(C.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(P){this.strokeProperty=P,this.notifyPropertyChanged(y.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(P){this.strokeThicknessProperty=P,this.notifyPropertyChanged(y.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(P){this.strokeDashArrayProperty=P,this.notifyPropertyChanged(y.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"showLabel",{get:function(){return this.showLabelProperty},set:function(P){this.showLabelProperty=P,this.notifyPropertyChanged(y.PROPERTY.SHOW_LABEL)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"axisLabelStroke",{get:function(){return this.axisLabelStrokeProperty},set:function(P){this.axisLabelStrokeProperty=P,this.notifyPropertyChanged(y.PROPERTY.AXIS_LABELS_STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"axisLabelFill",{get:function(){return this.axisLabelFillProperty},set:function(P){this.axisLabelFillProperty=P,this.notifyPropertyChanged(y.PROPERTY.AXIS_LABELS_FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"axisFontSize",{get:function(){return this.axisFontSizeProperty},set:function(P){this.axisFontSizeProperty=P,this.notifyPropertyChanged(y.PROPERTY.AXIS_FONT_SIZE)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"axisFontFamily",{get:function(){return this.axisFontFamilyProperty},set:function(P){this.axisFontFamilyProperty=P,this.notifyPropertyChanged(y.PROPERTY.AXIS_FONT_FAMILY)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"labelPlacement",{get:function(){return this.labelPlacementProperty},set:function(P){this.labelPlacementProperty=P,this.notifyPropertyChanged(y.PROPERTY.LABEL_PLACEMENT)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"labelValue",{get:function(){return this.labelValueProperty},set:function(P){this.labelValueProperty=P,this.notifyPropertyChanged(y.PROPERTY.LABEL_VALUE)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"labelPadding",{get:function(){return this.labelPaddingProperty},set:function(P){this.labelPaddingProperty=P,this.notifyPropertyChanged(y.PROPERTY.LABEL_PADDING)},enumerable:!1,configurable:!0}),Object.defineProperty(C.prototype,"labelCornerRadius",{get:function(){return this.labelCornerRadiusProperty},set:function(P){this.labelCornerRadiusProperty=P,this.notifyPropertyChanged(y.PROPERTY.LABEL_CORNER_RADIUS)},enumerable:!1,configurable:!0}),C.prototype.delete=function(){this.strokePenCache=(0,i.deleteSafe)(this.strokePenCache)},C.prototype.onAttach=function(P){_.prototype.onAttach.call(this,P),this.strokePenCache||(this.strokePenCache=new f.Pen2DCache(P.webAssemblyContext2D)),(0,f.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness,this.opacity,this.strokeDashArray)},C.prototype.drawWithContext=function(P,x,E,A,R,M){var D,F,I,V;n.Guard.notNull(P,"renderContext"),n.Guard.notNull(x,"xCalc"),n.Guard.notNull(E,"yCalc");var z=this.stroke&&this.strokeThickness&&this.strokePenCache?(0,f.getWebGlPenFromCache)(this.strokePenCache):void 0,G=this.convertPolarToCartesian(this.getX1Coordinate(x,E),this.getY1Coordinate(x,E)),H=G.x,U=G.y,k=this.convertPolarToCartesian(this.getX2Coordinate(x,E),this.getY2Coordinate(x,E)),X=k.x,W=k.y;if(this.setAnnotationBorders(H,X,U,W),!this.parentSurface.isPolar&&this.showLabel){var Y=this.parentSurface.xAxes.asArray().filter(function(Ce){return Ce.isVisible}),te=this.parentSurface.yAxes.asArray().filter(function(Ce){return Ce.isVisible}),oe=e(e([],Y.filter(function(Ce){return!Ce.isVerticalChart}),!0),te.filter(function(Ce){return Ce.isVerticalChart}),!0),de=e(e([],te.filter(function(Ce){return!Ce.isVerticalChart}),!0),Y.filter(function(Ce){return Ce.isVerticalChart}),!0),ge=void 0,Ee=[];if(H===X&&U===0){W-=this.parentSurface.seriesViewRect.y,ge=H,Ee=oe;var Re=oe.find(function(Ce){return Ce.axisAlignment===a.EAxisAlignment.Top}),Ae=oe.find(function(Ce){return Ce.axisAlignment===a.EAxisAlignment.Bottom}),Pe=(D=Re==null?void 0:Re.axisRenderer.getAxisReservedSpace(!0))!==null&&D!==void 0?D:0,we=(F=Ae==null?void 0:Ae.axisRenderer.getAxisReservedSpace(!0))!==null&&F!==void 0?F:0;U-=Pe*p.DpiHelper.PIXEL_RATIO,W+=we*p.DpiHelper.PIXEL_RATIO}else if(U===W&&H===0){X-=this.parentSurface.seriesViewRect.x,ge=U,Ee=de;var Te=de.find(function(Ce){return Ce.axisAlignment===a.EAxisAlignment.Left}),ke=de.find(function(Ce){return Ce.axisAlignment===a.EAxisAlignment.Right}),$e=(I=Te==null?void 0:Te.axisRenderer.getAxisReservedSpace(!0))!==null&&I!==void 0?I:0,Ne=(V=ke==null?void 0:ke.axisRenderer.getAxisReservedSpace(!0))!==null&&V!==void 0?V:0;H-=$e*p.DpiHelper.PIXEL_RATIO,X+=Ne*p.DpiHelper.PIXEL_RATIO}if(z){var ve=this.getClippingRect(this.clipping,R,R,M);P.drawLine(H,U,X,W,z,A,ve)}if(ge!==void 0)for(var pe=0,fe=Ee;pe<fe.length;pe++){var me=fe[pe];me.drawLabels&&(!me.isStackedAxis||me.offset<ge&&me.offset+me.getAxisSize()>ge)&&(0,h.drawModifiersAxisLabel)(me,P,ge,this.axisLabelFill,this.axisLabelStroke,this.labelPaddingProperty,this.labelCornerRadiusProperty)}}else if(z){var ve=this.getClippingRect(this.clipping,R,R,M);P.drawLine(H,U,X,W,z,A,ve)}this.updateAdornerInner()},C.prototype.onDragStarted=function(P){_.prototype.onDragStarted.call(this,P);var x=this.x1,E=this.type===m.EAnnotationType.RenderContextHorizontalLineAnnotation||this.type===m.EAnnotationType.RenderContextVerticalLineAnnotation?this.x1:this.x2,A=this.y1,R=this.type===m.EAnnotationType.RenderContextHorizontalLineAnnotation||this.type===m.EAnnotationType.RenderContextVerticalLineAnnotation?this.y1:this.y2,M=this.getXYCoordinatesFromValues(new r.Point(x,A)),D=this.getXYCoordinatesFromValues(new r.Point(E,R)),F=new r.Point(P.mousePoint.x,P.mousePoint.y);if(M&&this.canDragPoint(g.EDraggingGripPoint.x1y1)){var I=(0,d.calcDistance)(M.x,M.y,P.mousePoint.x,P.mousePoint.y);if(I<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x1y1,!0}if(D&&this.canDragPoint(g.EDraggingGripPoint.x2y2)){var I=(0,d.calcDistance)(D.x,D.y,P.mousePoint.x,P.mousePoint.y);if(I<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x2y2,!0}return F&&this.canDragPoint(g.EDraggingGripPoint.Body)&&this.clickToSelect(P)?(this.adornerDraggingPoint=g.EDraggingGripPoint.Body,!0):!1},C.prototype.calcDragDistance=function(P){if(!this.prevValue){this.prevValue=P;return}var x=this.yAxis.isVerticalChart;this.adornerDraggingPoint===g.EDraggingGripPoint.Body?this.type===m.EAnnotationType.RenderContextHorizontalLineAnnotation?x?this.x1=this.x1-(this.prevValue.x-P.x):this.y1=this.y1-(this.prevValue.y-P.y):this.type===m.EAnnotationType.RenderContextVerticalLineAnnotation?x?this.y1=this.y1-(this.prevValue.y-P.y):this.x1=this.x1-(this.prevValue.x-P.x):this.type===m.EAnnotationType.RenderContextLineAnnotation&&(this.x1=this.x1+this.applyPixelRatioToDragDist(P.x-this.prevValue.x),this.x2=this.x2+this.applyPixelRatioToDragDist(P.x-this.prevValue.x),this.y1=this.y1+(P.y-this.prevValue.y),this.y2=this.y2+(P.y-this.prevValue.y)):this.adornerDraggingPoint===g.EDraggingGripPoint.x1y1?this.resizeDirections===u.EXyDirection.XDirection?this.x1+=this.applyPixelRatioToDragDist(P.x-this.prevValue.x):this.resizeDirections===u.EXyDirection.YDirection?this.y1+=P.y-this.prevValue.y:(this.x1+=this.applyPixelRatioToDragDist(P.x-this.prevValue.x),this.y1+=P.y-this.prevValue.y):this.adornerDraggingPoint===g.EDraggingGripPoint.x2y2&&(this.resizeDirections===u.EXyDirection.XDirection?this.x2+=this.applyPixelRatioToDragDist(P.x-this.prevValue.x):this.resizeDirections===u.EXyDirection.YDirection?this.y2+=P.y-this.prevValue.y:(this.x2+=this.applyPixelRatioToDragDist(P.x-this.prevValue.x),this.y2+=P.y-this.prevValue.y)),this.prevValue=P},C.prototype.onDpiChanged=function(P){_.prototype.onDpiChanged.call(this,P),this.notifyPropertyChanged(y.PROPERTY.STROKE)},C.prototype.toJSON=function(){var P=_.prototype.toJSON.call(this),x={axisFontFamily:this.axisFontFamily,axisFontSize:this.axisFontSize,axisLabelFill:this.axisLabelFill,axisLabelStroke:this.axisLabelStroke,labelPlacement:this.labelPlacement,labelValue:this.labelValue,showLabel:this.showLabel,stroke:this.stroke,strokeDashArray:this.strokeDashArray,strokeThickness:this.strokeThickness,labelPadding:this.labelPadding,labelCornerRadius:this.labelCornerRadius};return Object.assign(P.options,x),P},C.prototype.checkIsClickedOnAnnotationInternal=function(P,x){var E=this.getAnnotationBorders(),A=E.x1,R=E.x2,M=E.y1,D=E.y2,F=(0,d.calcDistanceFromLineSegment)(P,x,A,M,R,D);return F<=y.DISTANCE_TO_LINE*p.DpiHelper.PIXEL_RATIO},C.prototype.notifyPropertyChanged=function(P){_.prototype.notifyPropertyChanged.call(this,P);var x=[y.PROPERTY.STROKE,y.PROPERTY.STROKE_THICKNESS,y.PROPERTY.STROKE_DASH_ARRAY,y.PROPERTY.OPACITY];x.includes(P)&&this.strokePenCache&&(0,f.createPenInCache)(this.strokePenCache,this.stroke,this.strokeThickness,this.opacity,this.strokeDashArray)},C.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var P=this.getAdornerAnnotationBorders(),x=P.x1,E=P.x2,A=P.y1,R=P.y2,M=this.svgStringAdornerTemplate(x,A,E,R),D=this.applySvgClipping(M,this.adornerClipping);this.svgAdorner=v.annotationHelpers.createSvg(D,this.svgAdornerRoot)}},C.prototype.svgStringAdornerTemplate=function(P,x,E,A){var R=this.selectionBoxStroke;return`<svg xmlns="http://www.w3.org/2000/svg">
    <line x1="`.concat(P,'" y1="').concat(x,'" x2="').concat(E,'" y2="').concat(A,'" stroke="').concat(R,`" stroke-width="6" />
    `).concat(this.canDragPoint(g.EDraggingGripPoint.x1y1)?this.getAnnotationGripSvg(P,x):"",`
    `).concat(this.canDragPoint(g.EDraggingGripPoint.x2y2)?this.getAnnotationGripSvg(E,A):"",`
    </svg>`)},C})(b.RenderContextAnnotationBase);return z0.LineAnnotation=S,z0}var Pye;function $Fe(){if(Pye)return U0;Pye=1;var t=U0&&U0.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})(),e=U0&&U0.__assign||function(){return e=Object.assign||function(y){for(var m,b=1,S=arguments.length;b<S;b++){m=arguments[b];for(var _ in m)Object.prototype.hasOwnProperty.call(m,_)&&(y[_]=m[_])}return y},e.apply(this,arguments)};Object.defineProperty(U0,"__esModule",{value:!0}),U0.HorizontalLineAnnotation=void 0;var i=ci(),n=$i(),r=Rn(),o=pa(),a=od(),s=vs(),l=Eo(),u=An(),c=Ls(),d=_v(),f=Zi(),h=Ca(),p=Qa(),g=rC(),v=(function(y){t(m,y);function m(b){var S=this,_,C,P;return S=y.call(this,b)||this,S.type=p.EAnnotationType.RenderContextHorizontalLineAnnotation,S.surfaceTypes=[s.ESurfaceType.SciChartSurfaceType],S.dragOnLine=!0,S.dragOnLabel=!0,b!=null&&b.x2&&(S.x2=b.x2),b!=null&&b.y2&&(S.y2=b.y2),S.dragOnLine=(_=b==null?void 0:b.dragOnLine)!==null&&_!==void 0?_:S.dragOnLine,S.dragOnLabel=(C=b==null?void 0:b.dragOnLabel)!==null&&C!==void 0?C:S.dragOnLabel,S.horizontalAlignment=(P=b==null?void 0:b.horizontalAlignment)!==null&&P!==void 0?P:S.horizontalAlignment,S}return Object.defineProperty(m.prototype,"y2",{get:function(){throw Error("y2 property is not supported for HorizontalLineAnnotation")},set:function(b){throw Error("y2 property is not supported for HorizontalLineAnnotation")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"x2",{get:function(){throw Error("x2 property is not supported for HorizontalLineAnnotation")},set:function(b){throw Error("x2 property is not supported for HorizontalLineAnnotation")},enumerable:!1,configurable:!0}),m.prototype.drawWithContext=function(b,S,_,C,P,x){i.Guard.notNull(b,"renderContext"),i.Guard.notNull(S,"xCalc"),i.Guard.notNull(_,"yCalc");var E=this.stroke&&this.strokeThickness?(0,c.getWebGlPenFromCache)(this.strokePenCache):void 0,A=this.getDrawConfig(S,_),R=A.annotationCoord,M=A.lineAnnotationEdgeCoord,D=A.horizontalAxis,F=A.verticalAxis,I=A.horizontalAxisCoordinateMode,V=A.verticalAxisCoordinateMode,z=A.horizontalCoordinateCalculator,G=A.verticalCoordinateCalculator,H=A.isAlignmentRight;if(!(!D||!F)){var U=0,k=C.width;H&&(U=C.width,k=0);var X=this.getValue(M,z,I),W=X||X===0;W&&(k=k=this.getX1Coordinate(S,_));var Y=this.getY1Coordinate(S,_),te=Y;this.setAnnotationBorders(U,k,Y,te);var oe=this.getCoordinate(M,z,I),de=this.getCoordinate(R,G,V),ge=de>=0&&de<=F.parentSurface.seriesViewRect.height,Ee=H?oe<=D.parentSurface.seriesViewRect.width:oe>=0,Re=!W||Ee;if(ge&&Re){var Ae=e(e({},F.labelStyle),{padding:new o.Thickness(2,2,2,2),color:this.axisLabelStroke,fontSize:this.axisFontSize*f.DpiHelper.PIXEL_RATIO,fontFamily:this.axisFontFamily}),Pe=(0,d.drawLineAnnotation)(F,b,this.labelPlacement,this.labelValue,U,k,Y,te,Ae,this.axisLabelFill,E,C,this.showLabel,this.opacity,this.horizontalAlignment);if(Pe){var we=(0,u.translateFromCanvasToSeriesViewRect)(new n.Point(Pe.left,Pe.top),C,!0),Te=(0,u.translateFromCanvasToSeriesViewRect)(new n.Point(Pe.right,Pe.bottom),C,!0);this.labelRect=r.Rect.createWithPoints(we,Te)}}this.dragOnLine&&this.updateAdornerInner()}},m.prototype.onDragStarted=function(b){return this.dragOnLine?y.prototype.onDragStarted.call(this,b):this.dragOnLabel&&this.labelRect&&this.clickToSelect(b)?(this.adornerDraggingPoint=h.EDraggingGripPoint.Body,!0):!1},m.prototype.toJSON=function(){var b=y.prototype.toJSON.call(this),S={dragOnLabel:this.dragOnLabel,dragOnLine:this.dragOnLine,horizontalAlignment:this.horizontalAlignment,verticalAlignment:void 0};return Object.assign(b.options,S),b},m.prototype.checkIsClickedOnAnnotationInternal=function(b,S){if(this.dragOnLine&&y.prototype.checkIsClickedOnAnnotationInternal.call(this,b,S))return!0;if(this.dragOnLabel&&this.labelRect){var _=this.labelRect,C=_.left,P=_.top,x=_.right,E=_.bottom;if((0,l.testIsInBounds)(b,S,C,E,x,P))return!0}return!1},m.prototype.getDrawConfig=function(b,S){var _=this.xAxis,C=this.yAxis,P={annotationCoord:this.y1,lineAnnotationEdgeCoord:this.x1,horizontalAxis:_,verticalAxis:C,horizontalAxisCoordinateMode:this.xCoordinateMode,verticalAxisCoordinateMode:this.yCoordinateMode,horizontalCoordinateCalculator:b,verticalCoordinateCalculator:S,isAlignmentRight:(C==null?void 0:C.axisAlignment)===a.EAxisAlignment.Right},x={annotationCoord:this.x1,lineAnnotationEdgeCoord:this.y1,horizontalAxis:C,verticalAxis:_,horizontalAxisCoordinateMode:this.yCoordinateMode,verticalAxisCoordinateMode:this.xCoordinateMode,horizontalCoordinateCalculator:S,verticalCoordinateCalculator:b,isAlignmentRight:(_==null?void 0:_.axisAlignment)===a.EAxisAlignment.Right};return this.isVerticalChart?x:P},m})(g.LineAnnotation);return U0.HorizontalLineAnnotation=v,U0}var B1={},Cye;function WFe(){if(Cye)return B1;Cye=1;var t=B1&&B1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(B1,"__esModule",{value:!0}),B1.HtmlTextAnnotation=void 0;var e=jl(),i=Yre(),n=Qa(),r=(function(o){t(a,o);function a(s){var l=this,u,c;return l=o.call(this,s)||this,l.type=n.EAnnotationType.HtmlTextAnnotation,l.textProperty=null,l.text=(u=s==null?void 0:s.text)!==null&&u!==void 0?u:l.textProperty,l.textContainerStyle=(c=s==null?void 0:s.textContainerStyle)!==null&&c!==void 0?c:l.textContainerStyleProperty,l}return Object.defineProperty(a.prototype,"text",{get:function(){return this.textProperty},set:function(s){this.textProperty!==s&&(this.textProperty=s,this.setText(this.textProperty),this.notifyPropertyChanged(e.PROPERTY.TEXT_STYLE))},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"textContainerStyle",{get:function(){return this.textContainerStyleProperty},set:function(s){this.textContainerStyleProperty!==s&&(this.textContainerStyleProperty=s,this.setStyle(this.textContainerStyle),this.notifyPropertyChanged(e.PROPERTY.TEXT))},enumerable:!1,configurable:!0}),a.prototype.toJSON=function(){var s=o.prototype.toJSON.call(this),l={textContainerStyle:this.textContainerStyle,text:this.text};return Object.assign(s.options,l),s},a.prototype.setText=function(s){this.htmlElement.innerText=s},a.prototype.setStyle=function(s){var l=this;Object.entries(s).forEach(function(u){var c=u[0],d=u[1],f=c.replace(/[A-Z]/g,function(h){return"-"+h.toLowerCase()});l.htmlElement.style.setProperty(f,d)})},a})(i.HtmlCustomAnnotation);return B1.HtmlTextAnnotation=r,B1}var j1={},EF={},Tye;function GFe(){if(Tye)return EF;Tye=1,Object.defineProperty(EF,"__esModule",{value:!0}),EF.geometryHelpers=void 0;function t(e,i,n,r,o,a){var s=o/2,l=Math.cos(n),u=Math.sin(n),c=e-r*l,d=i-r*u,f=c+s*u,h=d-s*l,p=c-s*u,g=d+s*l,v=e-a*l,y=i-a*u;return{baseMidX:v,baseMidY:y,leftX:f,leftY:h,rightX:p,rightY:g}}return EF.geometryHelpers={calcArrowHeadParameters:t},EF}var xye;function dJ(){return xye||(xye=1,(function(t){var e=j1&&j1.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})(),i=j1&&j1.__assign||function(){return i=Object.assign||function(y){for(var m,b=1,S=arguments.length;b<S;b++){m=arguments[b];for(var _ in m)Object.prototype.hasOwnProperty.call(m,_)&&(y[_]=m[_])}return y},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.LineArrowAnnotation=t.EArrowHeadPosition=void 0;var n=mo(),r=Br(),o=ci(),a=ga(),s=GFe(),l=tu(),u=Ls(),c=Zi(),d=jl(),f=Qa(),h=rC(),p;(function(y){y.End="End",y.Start="Start",y.StartEnd="StartEnd"})(p=t.EArrowHeadPosition||(t.EArrowHeadPosition={}));var g="transparent",v=(function(y){e(m,y);function m(b){var S=this,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U;return S=y.call(this,b)||this,S.type=f.EAnnotationType.RenderContextLineArrowAnnotation,S.arrowHeadPositionProperty=p.End,S.isArrowHeadScalableProperty=!1,S.getArrowStyleProxy=function(k){return new Proxy(k,{set:function(X,W,Y){return X[W]=Y,S.notifyPropertyChanged("arrowStyle"),!0}})},S.arrowHeadPositionProperty=(_=b==null?void 0:b.arrowHeadPosition)!==null&&_!==void 0?_:p.End,S.isArrowHeadScalable=(C=b==null?void 0:b.isArrowHeadScalable)!==null&&C!==void 0?C:!1,S.arrowStyleProperty=S.getArrowStyleProxy({headLength:(x=(P=b==null?void 0:b.arrowStyle)===null||P===void 0?void 0:P.headLength)!==null&&x!==void 0?x:10,headWidth:(A=(E=b==null?void 0:b.arrowStyle)===null||E===void 0?void 0:E.headWidth)!==null&&A!==void 0?A:8,headDepth:(M=(R=b==null?void 0:b.arrowStyle)===null||R===void 0?void 0:R.headDepth)!==null&&M!==void 0?M:0,fill:(F=(D=b==null?void 0:b.arrowStyle)===null||D===void 0?void 0:D.fill)!==null&&F!==void 0?F:g,stroke:(z=(V=(I=b==null?void 0:b.arrowStyle)===null||I===void 0?void 0:I.stroke)!==null&&V!==void 0?V:S.stroke)!==null&&z!==void 0?z:"#FFFFFF",strokeThickness:(U=(H=(G=b==null?void 0:b.arrowStyle)===null||G===void 0?void 0:G.strokeThickness)!==null&&H!==void 0?H:S.strokeThickness)!==null&&U!==void 0?U:1}),b!=null&&b.onArrowHeadSizeChanged&&(typeof b.onArrowHeadSizeChanged=="string"?(S.typeMap.set("onArrowHeadSizeChanged",b.onArrowHeadSizeChanged),S.onArrowHeadSizeChangedCallback=(0,n.getFunction)(a.EBaseType.OptionFunction,b.onArrowHeadSizeChanged)):S.onArrowHeadSizeChangedCallback=b.onArrowHeadSizeChanged),S}return Object.defineProperty(m.prototype,"arrowStyle",{get:function(){return this.arrowStyleProperty},set:function(b){var S=i(i({},this.arrowStyle),b);this.arrowStyleProperty=this.getArrowStyleProxy(S),this.notifyPropertyChanged("arrowStyle")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"arrowHeadPosition",{get:function(){return this.arrowHeadPositionProperty},set:function(b){this.arrowHeadPositionProperty=b,this.notifyPropertyChanged(d.PROPERTY.ARROW_HEAD_POSITION)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isArrowHeadScalable",{get:function(){return this.isArrowHeadScalableProperty},set:function(b){this.isArrowHeadScalableProperty=b,this.notifyPropertyChanged(d.PROPERTY.IS_ARROW_HEAD_RELATIVE)},enumerable:!1,configurable:!0}),m.prototype.onAttach=function(b){y.prototype.onAttach.call(this,b),this.updateArrowheadBrushes(b)},m.prototype.updateArrowheadBrushes=function(b){this.arrowheadStrokePenCache||(this.arrowheadStrokePenCache=new u.Pen2DCache(b.webAssemblyContext2D)),(0,u.createPenInCache)(this.arrowheadStrokePenCache,this.arrowStyle.stroke,this.arrowStyle.strokeThickness,this.opacity),this.arrowStyle.fill&&this.arrowStyle.fill!==g&&(this.arrowheadFillBrushCache||(this.arrowheadFillBrushCache=new l.BrushCache(b.webAssemblyContext2D)),(0,l.createBrushInCache)(this.arrowheadFillBrushCache,this.arrowStyle.fill,this.opacity))},m.prototype.delete=function(){y.prototype.delete.call(this),this.arrowheadFillBrushCache=(0,r.deleteSafe)(this.arrowheadFillBrushCache),this.arrowheadStrokePenCache=(0,r.deleteSafe)(this.arrowheadStrokePenCache)},m.prototype.drawWithContext=function(b,S,_,C,P,x){o.Guard.notNull(b,"renderContext"),o.Guard.notNull(S,"xCalc"),o.Guard.notNull(_,"yCalc");var E=this.convertPolarToCartesian(this.getX1Coordinate(S,_),this.getY1Coordinate(S,_)),A=E.x,R=E.y,M=this.convertPolarToCartesian(this.getX2Coordinate(S,_),this.getY2Coordinate(S,_)),D=M.x,F=M.y;this.setAnnotationBorders(A,D,R,F);var I=this.getClippingRect(this.clipping,C,P,x),V=this.getAnnotationBorders(),z=V.x1,G=V.x2,H=V.y1,U=V.y2,k=G-z,X=U-H;if(!(k===0&&X===0)){var W=Math.atan2(X,k),Y,te;if(this.isArrowHeadScalable){var oe=this.xAxis.visibleRange.max-this.xAxis.visibleRange.min,de=this.yAxis.visibleRange.max-this.yAxis.visibleRange.min;(!this.storedXRange||!this.storedYRange)&&(this.storedXRange=oe,this.storedYRange=de);var ge=oe/this.storedXRange,Ee=de/this.storedYRange,Re=(ge+Ee)/2;Y=this.arrowStyle.headLength/Re*c.DpiHelper.PIXEL_RATIO,te=this.arrowStyle.headWidth/Re*c.DpiHelper.PIXEL_RATIO}else Y=this.arrowStyle.headLength*c.DpiHelper.PIXEL_RATIO,te=this.arrowStyle.headWidth*c.DpiHelper.PIXEL_RATIO;var Ae=this.arrowStyle.headDepth*Y;if(this.onArrowHeadSizeChangedCallback){var Pe={headLength:this.arrowStyle.headLength,headWidth:this.arrowStyle.headWidth,headDepth:this.arrowStyle.headDepth,angle:W,x1:z,y1:H,x2:G,y2:U},we=this.onArrowHeadSizeChangedCallback(Pe);we&&(we.headLength!==void 0&&(Y=we.headLength*c.DpiHelper.PIXEL_RATIO),we.headWidth!==void 0&&(te=we.headWidth*c.DpiHelper.PIXEL_RATIO),we.headDepth!==void 0&&(Ae=we.headDepth*Y))}var Te=s.geometryHelpers.calcArrowHeadParameters(z,H,W+Math.PI,Y,te,Ae),ke=Te.baseMidX,$e=Te.baseMidY,Ne=Te.leftX,ve=Te.leftY,pe=Te.rightX,fe=Te.rightY,me=s.geometryHelpers.calcArrowHeadParameters(G,U,W,Y,te,Ae),Ce=me.baseMidX,Ue=me.baseMidY,Qe=me.leftX,it=me.leftY,xt=me.rightX,wt=me.rightY,$t=z,Mt=H,rt=G,qe=U;this.arrowStyle.headWidth>0&&this.arrowStyle.headLength>0&&([p.Start,p.StartEnd].includes(this.arrowHeadPosition)&&($t=ke,Mt=$e,this.drawArrowHead(b,z,H,Ae===0,ke,$e,Ne,ve,pe,fe,C,I)),[p.End,p.StartEnd].includes(this.arrowHeadPosition)&&(rt=Ce,qe=Ue,this.drawArrowHead(b,G,U,Ae===0,Ce,Ue,Qe,it,xt,wt,C,I))),this.drawLine(b,$t,Mt,rt,qe,C,P,x)}},m.prototype.drawLine=function(b,S,_,C,P,x,E,A){var R=this.stroke&&this.strokeThickness&&this.strokePenCache?(0,u.getWebGlPenFromCache)(this.strokePenCache):void 0;if(R){var M=this.getClippingRect(this.clipping,x,E,A);b.drawLine(S,_,C,P,R,x,M)}this.updateAdornerInner()},m.prototype.drawArrowHead=function(b,S,_,C,P,x,E,A,R,M,D,F){var I=(0,u.getWebGlPenFromCache)(this.arrowheadStrokePenCache);if(I){var V=this.arrowStyle.fill&&this.arrowStyle.fill!==g,z=V?(0,l.getWebGlBrushFromCache)(this.arrowheadFillBrushCache):void 0;C?b.drawLines([E,A,S,_,R,M],I,D,F):(V&&b.drawTriangleStrip([E,P,S,R],[A,x,_,M],D,F,z),b.drawLines([P,x,E,A,S,_,R,M,P,x],I,D,F))}},m.prototype.notifyPropertyChanged=function(b){y.prototype.notifyPropertyChanged.call(this,b),(b==="arrowStyle"||b===d.PROPERTY.OPACITY)&&this.updateArrowheadBrushes(this.parentSurface)},m.prototype.toJSON=function(){var b=y.prototype.toJSON.call(this),S={arrowStyle:{headLength:this.arrowStyle.headLength,headWidth:this.arrowStyle.headWidth,headDepth:this.arrowStyle.headDepth,fill:this.arrowStyle.fill,stroke:this.arrowStyle.stroke,strokeThickness:this.arrowStyle.strokeThickness},arrowHeadPosition:this.arrowHeadPosition,isArrowHeadScalable:this.isArrowHeadScalable,onArrowHeadSizeChanged:this.typeMap.get("onArrowHeadSizeChanged")};return Object.assign(b.options,S),b},m})(h.LineAnnotation);t.LineArrowAnnotation=v})(j1)),j1}var wF={},Eye;function Jz(){return Eye||(Eye=1,(function(t){var e=wF&&wF.__extends||(function(){var A=function(R,M){return A=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(D,F){D.__proto__=F}||function(D,F){for(var I in F)Object.prototype.hasOwnProperty.call(F,I)&&(D[I]=F[I])},A(R,M)};return function(R,M){if(typeof M!="function"&&M!==null)throw new TypeError("Class extends value "+String(M)+" is not a constructor or null");A(R,M);function D(){this.constructor=R}R.prototype=M===null?Object.create(M):(D.prototype=M.prototype,new D)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.NativeTextAnnotation=t.EWrapTo=void 0;var i=Br(),n=ci(),r=$i(),o=jv(),a=Tc(),s=pl(),l=Ju(),u=Ti(),c=Eo(),d=id(),f=An(),h=an(),p=Zi(),g=Ca(),v=gl(),y=jl(),m=Qa(),b=FI(),S=tu(),_=pa(),C=vs(),P=Vf(),x;(function(A){A.ViewRect="ViewRect",A.Annotation="Annotation"})(x=t.EWrapTo||(t.EWrapTo={}));var E=(function(A){e(R,A);function R(M){var D=this,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de;return D=A.call(this,M)||this,D.type=m.EAnnotationType.RenderContextNativeTextAnnotation,D.surfaceTypes=[C.ESurfaceType.SciChartSurfaceType,C.ESurfaceType.SciChartPolarSurfaceType],D.scaleOnResize=!1,D.fontSizeProperty=14,D.fontFamilyProperty=(0,P.getDefaultFontName)(),D.textColorProperty="#ffffff",D.rotationProperty=0,D.textProperty="",D.verticalAnchorPointProperty=o.EVerticalAnchorPoint.Top,D.horizontalAnchorPointProperty=o.EHorizontalAnchorPoint.Left,D.multiLineAlignmentProperty=a.EMultiLineAlignment.Center,D.lineSpacingProperty=3,D.scaleProperty=1,D.paddingProperty=_.Thickness.fromNumber(2),D.textColorProperty=(F=M==null?void 0:M.textColor)!==null&&F!==void 0?F:D.textColorProperty,D.fontSizeProperty=(I=M==null?void 0:M.fontSize)!==null&&I!==void 0?I:D.fontSizeProperty,D.fontFamilyProperty=(V=M==null?void 0:M.fontFamily)!==null&&V!==void 0?V:D.fontFamilyProperty,D.rotationProperty=(z=M==null?void 0:M.rotation)!==null&&z!==void 0?z:D.rotationProperty,D.textProperty=(G=M==null?void 0:M.text)!==null&&G!==void 0?G:D.textProperty,D.verticalAnchorPointProperty=(H=M==null?void 0:M.verticalAnchorPoint)!==null&&H!==void 0?H:D.verticalAnchorPointProperty,D.horizontalAnchorPointProperty=(U=M==null?void 0:M.horizontalAnchorPoint)!==null&&U!==void 0?U:D.horizontalAnchorPointProperty,D.multiLineAlignmentProperty=(k=M==null?void 0:M.multiLineAlignment)!==null&&k!==void 0?k:D.multiLineAlignmentProperty,D.wrapToProperty=(X=M==null?void 0:M.wrapTo)!==null&&X!==void 0?X:D.wrapToProperty,D.lineSpacingProperty=(W=M==null?void 0:M.lineSpacing)!==null&&W!==void 0?W:D.lineSpacingProperty,D.scaleProperty=(Y=M==null?void 0:M.scale)!==null&&Y!==void 0?Y:D.scaleProperty,D.initialWidth=Math.abs(D.x2-D.x1),D.scaleOnResize=(te=M==null?void 0:M.scaleOnResize)!==null&&te!==void 0?te:D.scaleOnResize,D.backgroundProperty=(oe=M==null?void 0:M.background)!==null&&oe!==void 0?oe:D.backgroundProperty,D.paddingProperty=(de=M==null?void 0:M.padding)!==null&&de!==void 0?de:D.paddingProperty,D}return Object.defineProperty(R.prototype,"textColor",{get:function(){return this.textColorProperty},set:function(M){this.textColorProperty!==M&&(this.textColorProperty=M,this.notifyPropertyChanged(y.PROPERTY.COLOR))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"background",{get:function(){return this.backgroundProperty},set:function(M){this.backgroundProperty!==M&&(this.backgroundProperty=M,this.notifyPropertyChanged(y.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"padding",{get:function(){return this.paddingProperty},set:function(M){this.paddingProperty!==M&&(this.paddingProperty=M,this.notifyPropertyChanged(y.PROPERTY.PADDING))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"fontSize",{get:function(){return this.fontSizeProperty},set:function(M){this.fontSizeProperty!==M&&(this.fontSizeProperty=M,this.notifyPropertyChanged(y.PROPERTY.AXIS_FONT_SIZE))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"fontFamily",{get:function(){return this.fontFamilyProperty},set:function(M){this.fontFamilyProperty!==M&&(this.fontFamilyProperty=M,this.notifyPropertyChanged(y.PROPERTY.AXIS_FONT_FAMILY))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"rotation",{get:function(){return this.rotationProperty},set:function(M){this.rotationProperty!==M&&(this.rotationProperty=M,this.notifyPropertyChanged(y.PROPERTY.ROTATION))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"text",{get:function(){return this.textProperty},set:function(M){this.textProperty!==M&&(this.textProperty=M,this.notifyPropertyChanged(y.PROPERTY.TEXT))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"verticalAnchorPoint",{get:function(){return this.verticalAnchorPointProperty},set:function(M){this.verticalAnchorPointProperty!==M&&(this.verticalAnchorPointProperty=M,this.notifyPropertyChanged(y.PROPERTY.VERTICAL_ANCHOR_POINT))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"horizontalAnchorPoint",{get:function(){return this.horizontalAnchorPointProperty},set:function(M){this.horizontalAnchorPointProperty!==M&&(this.horizontalAnchorPointProperty=M,this.notifyPropertyChanged(y.PROPERTY.HORIZONTAL_ANCHOR_POINT))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"multiLineAlignment",{get:function(){return this.multiLineAlignmentProperty},set:function(M){this.multiLineAlignmentProperty!==M&&(this.multiLineAlignmentProperty=M,this.notifyPropertyChanged(y.PROPERTY.MULTILINE_ALIGNMENT))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"wrapTo",{get:function(){return this.wrapToProperty},set:function(M){this.wrapToProperty!==M&&(this.wrapToProperty=M,this.notifyPropertyChanged(y.PROPERTY.WRAP_TO))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"lineSpacing",{get:function(){return this.lineSpacingProperty},set:function(M){this.lineSpacingProperty!==M&&(this.lineSpacingProperty=M,this.notifyPropertyChanged(y.PROPERTY.LINE_SPACING))},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"scale",{get:function(){return this.scaleProperty},set:function(M){M!==this.scaleProperty&&(this.scaleProperty=M,this.notifyPropertyChanged(y.PROPERTY.SCALE))},enumerable:!1,configurable:!0}),R.prototype.delete=function(){this.fillBrushCache=(0,i.deleteSafe)(this.fillBrushCache)},R.prototype.onAttach=function(M){A.prototype.onAttach.call(this,M),this.background&&(this.fillBrushCache||(this.fillBrushCache=new S.BrushCache(M.webAssemblyContext2D)),(0,S.createBrushInCache)(this.fillBrushCache,this.background,this.opacity))},R.prototype.getRotationCenter=function(M,D,F){return new r.Point(M,D)},R.prototype.drawWithContext=function(M,D,F,I,V,z){n.Guard.notNull(M,"renderContext"),n.Guard.notNull(D,"xCalc"),n.Guard.notNull(F,"yCalc"),M.getNativeContext();var G=this.convertPolarToCartesian(this.getX1Coordinate(D,F),this.getY1Coordinate(D,F)),H=G.x,U=G.y,k={fontFamily:this.fontFamily,fontSize:Math.round(this.fontSize*p.DpiHelper.PIXEL_RATIO)},X=(0,u.parseColorToUIntArgb)(this.textColor);X=(0,l.uintArgbColorOverrideOpacity)(X,this.opacity);var W,Y=-(this.rotation*Math.PI)/180,te=this.rotation!==0||this.scale!==1,oe=M.getFont(k,te,!0),de=(0,h.getTextBounds)(this.parentSurface.webAssemblyContext2D),ge=this.text;if(this.wrapTo){var Ee=1/0;if(typeof this.wrapTo=="number")Ee=this.wrapTo;else if(this.wrapTo===x.ViewRect)this.horizontalAnchorPoint===o.EHorizontalAnchorPoint.Left?Ee=this.parentSurface.seriesViewRect.width-H:this.horizontalAnchorPoint===o.EHorizontalAnchorPoint.Center?Ee=2*Math.min(H,this.parentSurface.seriesViewRect.width-H):this.horizontalAnchorPoint===o.EHorizontalAnchorPoint.Right&&(Ee=H);else if(this.wrapTo===x.Annotation){var Re=this.getX2Coordinate(D,F);Re>H&&(Ee=Re-H)}ge=(0,d.wrapNativeText)(this.text,Ee,oe,de)}var Ae=this.lineSpacing;oe.CalculateStringBounds(ge??"",de,Ae);var Pe=de.GetLineBounds(0);Ae<1&&(Ae=this.lineSpacing*(Pe.m_fHeight-Pe.m_fOffsetY),oe.CalculateStringBounds(ge??"",de,Ae)),Pe.delete();var we=this.getRotationCenter(H+I.x,U+I.y,de);W=(0,h.getVector4)(this.parentSurface.webAssemblyContext2D,we.x,we.y,Y,0);var Te=(0,d.getNativeTextPosition)(H,U,this.horizontalAnchorPointProperty,this.verticalAnchorPointProperty,de,this.padding),ke=Te.x,$e=Te.y,Ne=de.GetLineBounds(0),ve=de.m_fWidth,pe=(0,d.getFirstLineHeightToBaseline)(Ne);Ne.delete();var fe=(0,d.getTextHeightToBaseline)(de),me=(0,d.getMultilineTextHeight)(de),Ce=ke,Ue=$e-pe,Qe=ke+ve,it=Ue+me;if(this.rotation!==0){var xt=Math.sin(Y),wt=Math.cos(Y),$t=this.getRotationCenter(H,U,de),Mt=function(Bt,Mr){var Be=(Bt-$t.x)*wt+(Mr-$t.y)*xt,We=(Mr-$t.y)*wt-(Bt-$t.x)*xt;return{x:Be,y:We}},rt=Mt(Ce,Ue),qe=Mt(Qe,Ue),vt=Mt(Ce,it),kt=Mt(Qe,it);Ce=Math.min(rt.x,qe.x,vt.x,kt.x)+$t.x,Qe=Math.max(rt.x,qe.x,vt.x,kt.x)+$t.x,Ue=Math.min(rt.y,qe.y,vt.y,kt.y)+$t.y,it=Math.max(rt.y,qe.y,vt.y,kt.y)+$t.y}var Xe=(0,a.convertMultiLineAlignment)(this.multiLineAlignment,this.parentSurface.webAssemblyContext2D),_t=oe.GetScale(),Ht=!1;_t!==this.scale&&(oe.SetScale(this.scale),Ht=!0),this.setAnnotationBorders(Ce,Ce+(Qe-Ce)*this.scale,Ue,Ue+(it-Ue)*this.scale);var Pt=ke+I.x,Jt=$e+I.y;oe.DrawStringAdvanced(ge,X,Math.round(Pt),Math.round(Jt),W,Xe,Ae),Ht&&oe.SetScale(_t);var zt=this.getClippingRect(this.clipping,I,V,z);this.background&&this.drawBackground(M,ve,me,fe,we,zt),M.resetAndClip(zt),oe.End(),this.updateAdornerInner()},R.prototype.onDragStarted=function(M){A.prototype.onDragStarted.call(this,M);var D=this.getAnnotationBorders(!1,!0),F=D.x1,I=D.x2,V=D.y1,z=D.y2,G=v.annotationHelpers.calcNewApex(F,V,I,z,this.isVerticalChart),H=G.x1y1,U=G.x2y1,k=G.x1y2,X=G.x2y2,W=(0,f.translateFromCanvasToSeriesViewRect)(new r.Point(M.mousePoint.x,M.mousePoint.y),this.parentSurface.seriesViewRect,!0);if(H&&this.canDragPoint(g.EDraggingGripPoint.x1y1)){var Y=(0,c.calcDistance)(H.x,H.y,W.x,W.y);if(Y<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x1y1,!0}if(U&&this.canDragPoint(g.EDraggingGripPoint.x2y1)){var Y=(0,c.calcDistance)(U.x,U.y,W.x,W.y);if(Y<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x2y1,!0}if(k&&this.canDragPoint(g.EDraggingGripPoint.x1y2)){var Y=(0,c.calcDistance)(k.x,k.y,W.x,W.y);if(Y<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x1y2,!0}if(X&&this.canDragPoint(g.EDraggingGripPoint.x2y2)){var Y=(0,c.calcDistance)(X.x,X.y,W.x,W.y);if(Y<this.annotationsGripsRadius*p.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=g.EDraggingGripPoint.x2y2,!0}return W&&this.canDragPoint(g.EDraggingGripPoint.Body)&&this.clickToSelect(M)?(this.adornerDraggingPoint=g.EDraggingGripPoint.Body,!0):!1},R.prototype.calcDragDistance=function(M){if(!this.prevValue){this.prevValue=M;return}this.adornerDraggingPoint===g.EDraggingGripPoint.Body?(this.x1+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.x2+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.y1+=M.y-this.prevValue.y,this.y2+=M.y-this.prevValue.y):this.adornerDraggingPoint===g.EDraggingGripPoint.x1y1?this.resizeDirections===s.EXyDirection.XDirection?this.x1+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x):this.resizeDirections===s.EXyDirection.YDirection?this.y1+=M.y-this.prevValue.y:(this.x1+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.y1+=M.y-this.prevValue.y):this.adornerDraggingPoint===g.EDraggingGripPoint.x2y2?this.resizeDirections===s.EXyDirection.XDirection?this.x2+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x):this.resizeDirections===s.EXyDirection.YDirection?this.y2+=M.y-this.prevValue.y:(this.x2+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.y2+=M.y-this.prevValue.y):this.adornerDraggingPoint===g.EDraggingGripPoint.x2y1?this.resizeDirections===s.EXyDirection.XDirection?this.x2+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x):this.resizeDirections===s.EXyDirection.YDirection?this.y1+=M.y-this.prevValue.y:(this.x2+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.y1+=M.y-this.prevValue.y):this.adornerDraggingPoint===g.EDraggingGripPoint.x1y2&&(this.resizeDirections===s.EXyDirection.XDirection?this.x1+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x):this.resizeDirections===s.EXyDirection.YDirection?this.y2+=M.y-this.prevValue.y:(this.x1+=this.applyPixelRatioToDragDist(M.x-this.prevValue.x),this.y2+=M.y-this.prevValue.y));var D=Math.abs(this.x2-this.x1)/this.initialWidth;this.scaleOnResize&&D&&(this.scale=D),this.prevValue=M},R.prototype.onDpiChanged=function(M){A.prototype.onDpiChanged.call(this,M),this.notifyPropertyChanged(y.PROPERTY.STROKE)},R.prototype.toJSON=function(){var M=A.prototype.toJSON.call(this),D={fontFamily:this.fontFamily,fontSize:this.fontSize,textColor:this.textColor,padding:this.padding,verticalAnchorPoint:this.verticalAnchorPoint,horizontalAnchorPoint:this.horizontalAnchorPoint,wrapTo:this.wrapTo,scale:this.scale,scaleOnResize:this.scaleOnResize,multiLineAlignment:this.multiLineAlignment,lineSpacing:this.lineSpacing,background:this.background,rotation:this.rotation,text:this.text};return Object.assign(M.options,D),M},R.prototype.checkIsClickedOnAnnotationInternal=function(M,D){var F=this.getAnnotationBorders(!0),I=F.x1,V=F.x2,z=F.y1,G=F.y2;return(0,c.testIsInBounds)(M,D,I,G,V,z)},R.prototype.notifyPropertyChanged=function(M){A.prototype.notifyPropertyChanged.call(this,M);var D=[y.PROPERTY.FILL,y.PROPERTY.OPACITY];D.includes(M)&&this.background&&this.fillBrushCache&&(0,S.createBrushInCache)(this.fillBrushCache,this.background,this.opacity)},R.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.isSelected){var M=this.getAdornerAnnotationBorders(),D=M.x1,F=M.x2,I=M.y1,V=M.y2,z=this.svgStringAdornerTemplate(D,I,F,V),G=this.applySvgClipping(z,this.adornerClipping);this.svgAdorner=v.annotationHelpers.createSvg(G,this.svgAdornerRoot)}},R.prototype.drawBackground=function(M,D,F,I,V,z){var G=(0,S.getWebGlBrushFromCache)(this.fillBrushCache);M.drawRotatedRect(D,F,I,this.padding,this.verticalAnchorPoint,this.horizontalAnchorPoint,V,this.rotation,z,G)},R.prototype.svgStringAdornerTemplate=function(M,D,F,I){var V=this.selectionBoxStroke,z=F-M,G=I-D,H=`<svg xmlns="http://www.w3.org/2000/svg">
        <rect x="`.concat(M,'" y="').concat(D,'" width="').concat(z,'" height="').concat(G,'" stroke="').concat(V,'" stroke-width="').concat(this.selectionBoxThickness,`px" fill="none" />
        `),U=this.getAdornerAnnotationBorders(!1,!0);return this.canDragPoint(g.EDraggingGripPoint.x1y1)&&(H+=this.getAnnotationGripSvg(U.x1,U.y1)),this.canDragPoint(g.EDraggingGripPoint.x2y2)&&(H+=this.getAnnotationGripSvg(U.x2,U.y2)),this.canDragPoint(g.EDraggingGripPoint.x2y1)&&(H+=this.getAnnotationGripSvg(U.x2,U.y1)),this.canDragPoint(g.EDraggingGripPoint.x1y2)&&(H+=this.getAnnotationGripSvg(U.x1,U.y2)),H+="</svg>",H},R.prototype.getAnnotationBorders=function(M,D){M===void 0&&(M=!1),D===void 0&&(D=!1);var F=A.prototype.getAnnotationBorders.call(this,M,D);return{x1:F.x1-this.padding.left,x2:F.x2+this.padding.right,y1:F.y1-this.padding.top,y2:F.y2+this.padding.bottom}},R})(b.RenderContextAnnotationBase);t.NativeTextAnnotation=E})(wF)),wF}var $0={},w9={},wye;function YFe(){return wye||(wye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EStrokeLineJoin=void 0,(function(e){e.Arcs="arcs",e.Bevel="bevel",e.Miter="miter",e.MiterClip="miter-clip",e.Round="round"})(t.EStrokeLineJoin||(t.EStrokeLineJoin={}))})(w9)),w9}var Aye;function qFe(){if(Aye)return $0;Aye=1;var t=$0&&$0.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})(),e=$0&&$0.__assign||function(){return e=Object.assign||function(f){for(var h,p=1,g=arguments.length;p<g;p++){h=arguments[p];for(var v in h)Object.prototype.hasOwnProperty.call(h,v)&&(f[v]=h[v])}return f},e.apply(this,arguments)};Object.defineProperty($0,"__esModule",{value:!0}),$0.PolarPointerAnnotation=void 0;var i=jv(),n=YFe(),r=vs(),o=Zi(),a=Ca(),s=gl(),l=jl(),u=Qa(),c=Dm(),d=(function(f){t(h,f);function h(p){var g=this,v,y,m,b,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae;return g=f.call(this,p)||this,g.type=u.EAnnotationType.SVGPolarPointerAnnotation,g.surfaceTypes=[r.ESurfaceType.SciChartPolarSurfaceType],g.isDirty=!0,g.isStrokeAboveCenterProperty=!1,g.strokeLineJoinProperty=n.EStrokeLineJoin.Miter,g.getPointerStyleProxy=function(Pe){return new Proxy(Pe,{set:function(we,Te,ke){return we[Te]=ke,g.isDirty=!0,g.notifyPropertyChanged("pointerStyle"),!0}})},g.getPointerCenterStyleProxy=function(Pe){return new Proxy(Pe,{set:function(we,Te,ke){return we[Te]=ke,g.isDirty=!0,g.notifyPropertyChanged("pointerCenterStyle"),!0}})},g.getPointerArrowStyleProxy=function(Pe){return new Proxy(Pe,{set:function(we,Te,ke){return we[Te]=ke,g.isDirty=!0,g.notifyPropertyChanged("pointerArrowStyle"),!0}})},g.strokeLineJoinProperty=(v=p==null?void 0:p.strokeLineJoin)!==null&&v!==void 0?v:g.strokeLineJoinProperty,g.isStrokeAboveCenterProperty=(y=p==null?void 0:p.isStrokeAboveCenter)!==null&&y!==void 0?y:g.isStrokeAboveCenterProperty,g.pointerStyleProperty=g.getPointerStyleProxy({baseSize:(b=(m=p==null?void 0:p.pointerStyle)===null||m===void 0?void 0:m.baseSize)!==null&&b!==void 0?b:.1,stroke:(_=(S=p==null?void 0:p.pointerStyle)===null||S===void 0?void 0:S.stroke)!==null&&_!==void 0?_:"black",strokeWidth:(P=(C=p==null?void 0:p.pointerStyle)===null||C===void 0?void 0:C.strokeWidth)!==null&&P!==void 0?P:3,fill:(E=(x=p==null?void 0:p.pointerStyle)===null||x===void 0?void 0:x.fill)!==null&&E!==void 0?E:"gray",backExtensionSize:(R=(A=p==null?void 0:p.pointerStyle)===null||A===void 0?void 0:A.backExtensionSize)!==null&&R!==void 0?R:0}),g.pointerCenterStyleProperty=g.getPointerCenterStyleProxy({size:(D=(M=p==null?void 0:p.pointerCenterStyle)===null||M===void 0?void 0:M.size)!==null&&D!==void 0?D:0,stroke:(I=(F=p==null?void 0:p.pointerCenterStyle)===null||F===void 0?void 0:F.stroke)!==null&&I!==void 0?I:"black",strokeWidth:(z=(V=p==null?void 0:p.pointerCenterStyle)===null||V===void 0?void 0:V.strokeWidth)!==null&&z!==void 0?z:3,fill:(H=(G=p==null?void 0:p.pointerCenterStyle)===null||G===void 0?void 0:G.fill)!==null&&H!==void 0?H:"gray"}),g.pointerArrowStyleProperty=g.getPointerArrowStyleProxy({height:(k=(U=p==null?void 0:p.pointerArrowStyle)===null||U===void 0?void 0:U.height)!==null&&k!==void 0?k:0,width:(W=(X=p==null?void 0:p.pointerArrowStyle)===null||X===void 0?void 0:X.width)!==null&&W!==void 0?W:0,headDepth:(te=(Y=p==null?void 0:p.pointerArrowStyle)===null||Y===void 0?void 0:Y.headDepth)!==null&&te!==void 0?te:1,stroke:(de=(oe=p==null?void 0:p.pointerArrowStyle)===null||oe===void 0?void 0:oe.stroke)!==null&&de!==void 0?de:"black",strokeWidth:(Ee=(ge=p==null?void 0:p.pointerArrowStyle)===null||ge===void 0?void 0:ge.strokeWidth)!==null&&Ee!==void 0?Ee:3,fill:(Ae=(Re=p==null?void 0:p.pointerArrowStyle)===null||Re===void 0?void 0:Re.fill)!==null&&Ae!==void 0?Ae:"none"}),g}return Object.defineProperty(h.prototype,"pointerStyle",{get:function(){return this.pointerStyleProperty},set:function(p){var g=e(e({},this.pointerStyle),p);this.pointerStyleProperty=this.getPointerStyleProxy(g),this.isDirty=!0,this.notifyPropertyChanged("pointerStyle")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"pointerCenterStyle",{get:function(){return this.pointerCenterStyleProperty},set:function(p){var g=e(e({},this.pointerCenterStyle),p);this.pointerCenterStyleProperty=this.getPointerCenterStyleProxy(g),this.isDirty=!0,this.notifyPropertyChanged("pointerCenterStyle")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"pointerArrowStyle",{get:function(){return this.pointerArrowStyleProperty},set:function(p){var g=e(e({},this.pointerArrowStyle),p);this.pointerArrowStyleProperty=this.getPointerArrowStyleProxy(g),this.isDirty=!0,this.notifyPropertyChanged("pointerArrowStyle")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"horizontalAnchorPoint",{get:function(){return i.EHorizontalAnchorPoint.Center},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"verticalAnchorPoint",{get:function(){return i.EVerticalAnchorPoint.Center},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"isStrokeAboveCenter",{get:function(){return this.isStrokeAboveCenterProperty},set:function(p){this.isStrokeAboveCenterProperty!==p&&(this.isStrokeAboveCenterProperty=p,this.isDirty=!0,this.notifyPropertyChanged("isStrokeAboveCenter"))},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"strokeLineJoin",{get:function(){return this.strokeLineJoinProperty},set:function(p){this.strokeLineJoinProperty!==p&&(this.strokeLineJoinProperty=p,this.isDirty=!0,this.notifyPropertyChanged("strokeLineJoin"))},enumerable:!1,configurable:!0}),h.prototype.getAngularAxis=function(){var p=this.xAxis,g=this.yAxis;return p.isAngular?p:g},h.prototype.getRadialAxis=function(){var p=this.xAxis,g=this.yAxis;return p.isAngular?g:p},h.prototype.getSvgString=function(p){var g=this.getAngularAxis(),v=this.getRadialAxis(),y=this.getState(),m=y.axisSize,b=y.startAngle,S=y.direction,_;this.yCoordinateMode===a.ECoordinateMode.Relative?_=this.y1*m:this.yCoordinateMode===a.ECoordinateMode.DataValue?_=v.getCurrentCoordinateCalculator().getCoordinate(this.y1)/o.DpiHelper.PIXEL_RATIO:_=this.y1;var C;this.xCoordinateMode===a.ECoordinateMode.DataValue?C=b+g.getCurrentCoordinateCalculator().getCoordinate(this.x1):C=b+S*this.x1;var P=this.parentSurface,x=s.annotationHelpers.convertPolarToCartesian(g,!0,P.webAssemblyContext2D,a.ECoordinateMode.DataValue,0,0);this.state={axisSize:m,startAngle:b,direction:S,seriesViewRect:P.seriesViewRect};var E=-(180*C)/Math.PI,A=this.pointerStyleProperty.baseSize*_,R=this.pointerCenterStyleProperty.size*_,M=this.pointerArrowStyleProperty.height*_,D=this.pointerArrowStyleProperty.width*_,F=this.getPointerStickSvg(_,A,this.pointerStyleProperty.backExtensionSize),I=this.getPointerCenterSvg(_,R),V=this.getPointerArrowSvg(_,M,D,this.pointerArrowStyleProperty.headDepth),z=this.isStrokeAboveCenterProperty?I+F+V:F+V+I,G=x.x+P.seriesViewRect.left/o.DpiHelper.PIXEL_RATIO-_,H=x.y+P.seriesViewRect.top/o.DpiHelper.PIXEL_RATIO-_,U=P.viewRect,k=U.width,X=U.height,W=k/o.DpiHelper.PIXEL_RATIO,Y=X/o.DpiHelper.PIXEL_RATIO,te='<svg height="'.concat(Y,'" width="').concat(W,'" viewBox="0 0 ').concat(W," ").concat(Y,`">
            <g id="pointer" style="padding:100;" transform="translate(`).concat(G," ").concat(H,") rotate(").concat(E," ").concat(_," ").concat(_,`)">
                `).concat(z,`
            </g>
        </svg>`);return te},h.prototype.getPointerStickSvg=function(p,g,v){var y,m=p*2,b=Math.max((y=this.pointerStyle.strokeWidth)!==null&&y!==void 0?y:1.5,0);return"<path stroke-linejoin=".concat(this.strokeLineJoinProperty,`
            d="
                M`).concat(m-b," ").concat(p,`
                L`).concat(p-p*v," ").concat(p-g/2,`
                l0 `).concat(g,`
                L`).concat(m-b," ").concat(p,`Z
            " 
            fill="`).concat(this.pointerStyleProperty.fill,`"
            stroke="`).concat(this.pointerStyleProperty.stroke,`"  
            stroke-width="`).concat(this.pointerStyleProperty.strokeWidth,`"
        />`)},h.prototype.getPointerCenterSvg=function(p,g){return`<rect
            x="`.concat(p-g/2,`" 
            y="`).concat(p-g/2,`"
            width=`).concat(g,` 
            height=`).concat(g,`
            rx=`).concat(g/2,`
            ry=`).concat(g/2,`
            stroke=`).concat(this.pointerCenterStyleProperty.stroke,`
            stroke-width=`).concat(this.pointerCenterStyleProperty.strokeWidth,`
            fill=`).concat(this.pointerCenterStyleProperty.fill,`
        />`)},h.prototype.getPointerArrowSvg=function(p,g,v,y){var m,b=2*p,S=Math.max((m=this.pointerArrowStyleProperty.strokeWidth)!==null&&m!==void 0?m:1.5,0);return`<path 
            stroke="`.concat(this.pointerArrowStyleProperty.stroke,`"
            stroke-width="`).concat(this.pointerArrowStyleProperty.strokeWidth,`"
            fill="`).concat(this.pointerArrowStyleProperty.fill,`"
            stroke-linejoin=`).concat(this.strokeLineJoinProperty,`
            d="
                M`).concat(b-g/2-S," ").concat(p-v/2,`
                l`).concat(g/2," ").concat(v/2,`
                l-`).concat(g/2," ").concat(v/2,`
                `).concat(y===0?"":`
                    l`.concat((1-y)*g/2," ").concat(-v/2,`
                    l`).concat(-(1-y)*g/2," ").concat(-v/2,`Z
                `),`
            " 
        />`)},h.prototype.notifyPropertyChanged=function(p){(p===l.PROPERTY.X_COORDINATE_MODE||p===l.PROPERTY.Y_COORDINATE_MODE||p===l.PROPERTY.X1||p===l.PROPERTY.Y1)&&(this.isDirty=!0),f.prototype.notifyPropertyChanged.call(this,p)},h.prototype.toJSON=function(){var p=f.prototype.toJSON.call(this),g={isStrokeAboveCenter:this.isStrokeAboveCenter,pointerArrowStyle:this.pointerArrowStyle,pointerCenterStyle:this.pointerCenterStyle,pointerStyle:this.pointerStyle,strokeLineJoin:this.strokeLineJoin};return Object.assign(p.options,g),p},h.prototype.getX1Coordinate=function(p,g){return 0},h.prototype.getY1Coordinate=function(p,g){return 0},h.prototype.getState=function(){var p=this.getAngularAxis(),g=this.getRadialAxis(),v=g.getAxisSize(),y=p.flippedCoordinates?-1:1,m=p.startAngle,b=this.parentSurface.seriesViewRect;return{axisSize:v,startAngle:m,direction:y,seriesViewRect:b}},h.prototype.create=function(p,g,v,y){var m=this.getState(),b=m.axisSize,S=m.startAngle,_=m.direction,C=m.seriesViewRect;if((!this.state||b!==this.state.axisSize||S!==this.state.startAngle||_!==this.state.direction||C!==this.state.seriesViewRect)&&(this.isDirty=!0),this.svg&&!this.isEditable&&!this.isDirty){this.calcAndSetAnnotationBorders(p,g);return}if(this.isDirty||!this.svg||this.svg&&this.isSelected){this.svg&&this.clear();var P=s.annotationHelpers.createSvg(this.getSvgString(this),this.svgRoot,this.nextSibling);this.setSvg(P),this.calcAndSetAnnotationBorders(p,g),this.updateAdornerInner(),this.prevIsSelected=this.isSelected,this.isDirty=!1}else this.calcAndSetAnnotationBorders(p,g);this.prevIsSelected!==this.isSelected&&this.svg&&this.isEditable&&(this.updateAdornerInner(),this.prevIsSelected=this.isSelected)},h})(c.SvgAnnotationBase);return $0.PolarPointerAnnotation=d,$0}var V1={},Oye;function XFe(){if(Oye)return V1;Oye=1;var t=V1&&V1.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(V1,"__esModule",{value:!0}),V1.TextAnnotation=void 0;var e=pa(),i=vs(),n=Vf(),r=gl(),o=jl(),a=Qa(),s=Dm(),l=(function(u){t(c,u);function c(d){var f=this,h,p,g,v,y,m,b,S;return f=u.call(this,d)||this,f.type=a.EAnnotationType.SVGTextAnnotation,f.surfaceTypes=[i.ESurfaceType.SciChartSurfaceType,i.ESurfaceType.SciChartPolarSurfaceType],f.textProperty="DEFAULT TEXT",f.textColorProperty="#ffffff",f.fontSizeProperty=14,f.fontFamilyProperty=(0,n.getDefaultFontName)(),f.fontWeightProperty="Normal",f.paddingProperty=e.Thickness.fromNumber(0),f.classNameProperty="scichart__text-annotation",f.isDirty=!0,f.textProperty=(h=d==null?void 0:d.text)!==null&&h!==void 0?h:f.textProperty,f.textColorProperty=(p=d==null?void 0:d.textColor)!==null&&p!==void 0?p:f.textColorProperty,f.fontSizeProperty=(g=d==null?void 0:d.fontSize)!==null&&g!==void 0?g:f.fontSizeProperty,f.fontFamilyProperty=(v=d==null?void 0:d.fontFamily)!==null&&v!==void 0?v:f.fontFamilyProperty,f.backgroundProperty=(y=d==null?void 0:d.background)!==null&&y!==void 0?y:f.backgroundProperty,f.paddingProperty=(m=d==null?void 0:d.padding)!==null&&m!==void 0?m:f.paddingProperty,f.classNameProperty=(b=d==null?void 0:d.className)!==null&&b!==void 0?b:f.classNameProperty,f.fontWeight=(S=d==null?void 0:d.fontWeight)!==null&&S!==void 0?S:f.fontWeight,f}return Object.defineProperty(c.prototype,"text",{get:function(){return this.textProperty},set:function(d){this.textProperty!==d&&(this.textProperty=d,this.notifyPropertyChanged(o.PROPERTY.TEXT))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"background",{get:function(){return this.backgroundProperty},set:function(d){this.backgroundProperty!==d&&(this.backgroundProperty=d,this.notifyPropertyChanged(o.PROPERTY.BACKGROUND_COLOR))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"padding",{get:function(){return this.paddingProperty},set:function(d){this.paddingProperty!==d&&(this.paddingProperty=d,this.notifyPropertyChanged(o.PROPERTY.PADDING))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"className",{get:function(){return this.classNameProperty},set:function(d){this.classNameProperty!==d&&(this.classNameProperty=d,this.notifyPropertyChanged(o.PROPERTY.CLASS_NAME))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"textColor",{get:function(){return this.textColorProperty},set:function(d){this.textColorProperty!==d&&(this.textColorProperty=d,this.notifyPropertyChanged(o.PROPERTY.TEXT_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"fontSize",{get:function(){return this.fontSizeProperty},set:function(d){this.fontSizeProperty!==d&&(this.fontSizeProperty=d,this.notifyPropertyChanged(o.PROPERTY.FONT_SIZE))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"fontFamily",{get:function(){return this.fontFamilyProperty},set:function(d){this.fontFamilyProperty!==d&&(this.fontFamilyProperty=d,this.notifyPropertyChanged(o.PROPERTY.FONT_FAMILY))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"fontWeight",{get:function(){return this.fontWeightProperty},set:function(d){this.fontWeightProperty!==d&&(this.fontWeightProperty=d,this.notifyPropertyChanged(o.PROPERTY.FONT_WEIGHT))},enumerable:!1,configurable:!0}),c.prototype.toJSON=function(){var d=u.prototype.toJSON.call(this),f={fontFamily:this.fontFamily,fontSize:this.fontSize,fontWeight:this.fontWeight,text:this.text,textColor:this.textColor,background:this.background,className:this.className,padding:this.padding};return Object.assign(d.options,f),d},c.prototype.notifyPropertyChanged=function(d){d!==o.PROPERTY.IS_HIDDEN&&d!==o.PROPERTY.X_COORD_SHIFT&&d!==o.PROPERTY.Y_COORD_SHIFT&&d!==o.PROPERTY.HORIZONTAL_ANCHOR_POINT&&d!==o.PROPERTY.VERTICAL_ANCHOR_POINT&&d!==o.PROPERTY.X1&&d!==o.PROPERTY.X2&&d!==o.PROPERTY.Y1&&d!==o.PROPERTY.Y2&&(this.isDirty=!0),this.invalidateParentCallback&&this.invalidateParentCallback({svgOnly:!this.reDrawChartOnChange})},c.prototype.create=function(d,f,h,p){if(this.svg&&!this.isDirty){this.calcAndSetAnnotationBorders(d,f),(this.isSelected||this.prevIsSelected!==this.isSelected)&&(this.updateAdornerInner(),this.prevIsSelected=this.isSelected);return}this.svg&&this.clear(),this.setSvg(this.createSvg()),this.calcAndSetAnnotationBorders(d,f),this.updateAdornerInner(),this.isDirty=!1},c.prototype.createSvg=function(){var d=this.padding.left,f=this.fontSize+this.padding.top,h=(0,n.getFontFamily)(this.fontFamily,!1),p='<svg id="scichart__text-annotation-'.concat(this.id,'" class="').concat(this.className,`">
            <text x="`).concat(d,'" y="').concat(f,'" fill="').concat(this.textColor,'"  font-size="').concat(this.fontSize,'" font-family="').concat(h,'" font-weight="').concat(this.fontWeight,'">').concat(this.text,`</text>
        </svg>`),g=this.applyClipping(p,this.clipping),v=r.annotationHelpers.createSvg(g,this.svgRoot,this.nextSibling);return this.background&&this.attachSvgBackgroundRect(v,this.background,this.padding),v},c.prototype.getSize=function(){var d=u.prototype.getSize.call(this);return d&&!this.background?{width:d.width+this.padding.left+this.padding.right,height:d.height+this.padding.top+this.padding.bottom}:d},c.prototype.attachSvgBackgroundRect=function(d,f,h){var p=d.getBBox(),g=p.width+h.left+h.right,v=p.height+h.top+h.bottom,y="http://www.w3.org/2000/svg",m=document.createElementNS(y,"rect");m.setAttribute("x","0"),m.setAttribute("y","0"),m.setAttribute("width","".concat(g)),m.setAttribute("height","".concat(v)),m.setAttribute("fill","".concat(f)),d.firstChild.insertBefore(m,d.firstChild.firstChild)},c})(s.SvgAnnotationBase);return V1.TextAnnotation=l,V1}var W0={},Dye;function KFe(){if(Dye)return W0;Dye=1;var t=W0&&W0.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})(),e=W0&&W0.__assign||function(){return e=Object.assign||function(y){for(var m,b=1,S=arguments.length;b<S;b++){m=arguments[b];for(var _ in m)Object.prototype.hasOwnProperty.call(m,_)&&(y[_]=m[_])}return y},e.apply(this,arguments)};Object.defineProperty(W0,"__esModule",{value:!0}),W0.VerticalLineAnnotation=void 0;var i=ci(),n=$i(),r=Rn(),o=pa(),a=od(),s=vs(),l=Eo(),u=An(),c=Ls(),d=_v(),f=Zi(),h=Ca(),p=Qa(),g=rC(),v=(function(y){t(m,y);function m(b){var S=this,_,C,P;return S=y.call(this,b)||this,S.type=p.EAnnotationType.RenderContextVerticalLineAnnotation,S.surfaceTypes=[s.ESurfaceType.SciChartSurfaceType],S.dragOnLine=!0,S.dragOnLabel=!0,b!=null&&b.x2&&(S.x2=b.x2),b!=null&&b.y2&&(S.y2=b.y2),S.dragOnLine=(_=b==null?void 0:b.dragOnLine)!==null&&_!==void 0?_:S.dragOnLine,S.dragOnLabel=(C=b==null?void 0:b.dragOnLabel)!==null&&C!==void 0?C:S.dragOnLabel,S.verticalAlignment=(P=b==null?void 0:b.verticalAlignment)!==null&&P!==void 0?P:S.verticalAlignment,S}return Object.defineProperty(m.prototype,"y2",{get:function(){throw Error("y2 property is not supported for VerticalLineAnnotation")},set:function(b){throw Error("y2 property is not supported for VerticalLineAnnotation")},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"x2",{get:function(){throw Error("x2 property is not supported for VerticalLineAnnotation")},set:function(b){throw Error("x2 property is not supported for VerticalLineAnnotation")},enumerable:!1,configurable:!0}),m.prototype.drawWithContext=function(b,S,_,C,P,x){i.Guard.notNull(b,"renderContext"),i.Guard.notNull(S,"xCalc"),i.Guard.notNull(_,"yCalc");var E=(0,c.getWebGlPenFromCache)(this.strokePenCache),A=this.getDrawConfig(S,_),R=A.annotationCoord,M=A.lineAnnotationEdgeCoord,D=A.horizontalAxis,F=A.verticalAxis,I=A.horizontalAxisCoordinateMode,V=A.verticalAxisCoordinateMode,z=A.horizontalCoordinateCalculator,G=A.verticalCoordinateCalculator,H=A.isAlignmentTop;if(!(!D||!F)){var U=C.height,k=0;H&&(U=U=0,k=k=C.height);var X=this.getValue(M,G,V),W=X||X===0;W&&(k=k=this.getY1Coordinate(S,_));var Y=this.getX1Coordinate(S,_),te=Y;this.setAnnotationBorders(Y,te,U,k);var oe=this.getCoordinate(M,G,V),de=this.getCoordinate(R,z,I),ge=de>=0&&de<=D.parentSurface.seriesViewRect.width,Ee=H?oe>=0:oe<=F.parentSurface.seriesViewRect.height,Re=!W||Ee;if(ge&&Re){var Ae=e(e({},F.labelStyle),{padding:new o.Thickness(2,2,2,2),color:this.axisLabelStroke,fontSize:this.axisFontSize*f.DpiHelper.PIXEL_RATIO,fontFamily:this.axisFontFamily}),Pe=(0,d.drawLineAnnotation)(D,b,this.labelPlacement,this.labelValue,Y,te,U,k,Ae,this.axisLabelFill,E,C,this.showLabel,this.opacity,null,this.verticalAlignment);if(Pe){var we=(0,u.translateFromCanvasToSeriesViewRect)(new n.Point(Pe.left,Pe.top),C,!0),Te=(0,u.translateFromCanvasToSeriesViewRect)(new n.Point(Pe.right,Pe.bottom),C,!0);this.labelRect=r.Rect.createWithPoints(we,Te)}}this.dragOnLine&&this.updateAdornerInner()}},m.prototype.onDragStarted=function(b){return this.dragOnLine?y.prototype.onDragStarted.call(this,b):this.dragOnLabel&&this.labelRect&&this.clickToSelect(b)?(this.adornerDraggingPoint=h.EDraggingGripPoint.Body,!0):!1},m.prototype.toJSON=function(){var b=y.prototype.toJSON.call(this),S={dragOnLabel:this.dragOnLabel,dragOnLine:this.dragOnLine,horizontalAlignment:void 0,verticalAlignment:this.verticalAlignment};return Object.assign(b.options,S),b},m.prototype.checkIsClickedOnAnnotationInternal=function(b,S){if(this.dragOnLine&&y.prototype.checkIsClickedOnAnnotationInternal.call(this,b,S))return!0;if(this.dragOnLabel&&this.labelRect){var _=this.labelRect,C=_.left,P=_.top,x=_.right,E=_.bottom;if((0,l.testIsInBounds)(b,S,C,E,x,P))return!0}return!1},m.prototype.getDrawConfig=function(b,S){var _=this.xAxis,C=this.yAxis,P={annotationCoord:this.x1,lineAnnotationEdgeCoord:this.y1,horizontalAxis:_,verticalAxis:C,horizontalAxisCoordinateMode:this.xCoordinateMode,verticalAxisCoordinateMode:this.yCoordinateMode,horizontalCoordinateCalculator:b,verticalCoordinateCalculator:S,isAlignmentTop:(_==null?void 0:_.axisAlignment)===a.EAxisAlignment.Top},x={annotationCoord:this.y1,lineAnnotationEdgeCoord:this.x1,horizontalAxis:C,verticalAxis:_,horizontalAxisCoordinateMode:this.yCoordinateMode,verticalAxisCoordinateMode:this.xCoordinateMode,horizontalCoordinateCalculator:S,verticalCoordinateCalculator:b,isAlignmentTop:(C==null?void 0:C.axisAlignment)===a.EAxisAlignment.Top};return this.isVerticalChart?x:P},m})(g.LineAnnotation);return W0.VerticalLineAnnotation=v,W0}var A9={},H1={},U1={},O9={},Rye;function ud(){return Rye||(Rye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAxisType=void 0,(function(e){e.CategoryAxis="CategoryAxis",e.NumericAxis="NumericAxis",e.LogarithmicAxis="LogarithmicAxis",e.NumericAxis3D="NumericAxis3D",e.DateTimeNumericAxis="DateTimeNumericAxis",e.PolarNumericAxis="PolarNumericAxis",e.PolarCategoryAxis="PolarCategoryAxis",e.BaseValueAxis="BaseValueAxis",e.DiscontinuousDateAxis="DiscontinuousDateAxis"})(t.EAxisType||(t.EAxisType={}))})(O9)),O9}var z1={},$1={},W1={},Mye;function iC(){if(Mye)return W1;Mye=1;var t=W1&&W1.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(W1,"__esModule",{value:!0}),W1.CoordinateCalculatorBase=void 0;var e=fo(),i=di(),n=(function(r){t(o,r);function o(a,s,l,u,c,d,f){f===void 0&&(f=!1);var h=r.call(this)||this;return h.webAssemblyContext=a,h.visibleMax=u,h.visibleMin=l,h.viewportDimension=s,h.offset=c,h.hasFlippedCoordinates=d,h.isCategoryCoordinateCalculator=f,h}return o.prototype.getCoordinate=function(a){return this.nativeCalculator.GetCoordinate(a)},o.prototype.getDataValue=function(a){return this.nativeCalculator.GetDataValue(a)},o.prototype.translateBy=function(a,s){var l=this.getDataValue(a)-this.getDataValue(0);return this.hasFlippedCoordinates&&(l=-l),new i.NumberRange(s.min+l,s.max+l)},o.prototype.zoomTranslateBy=function(a,s,l){return l.growBy(new i.NumberRange(a,s))},o.prototype.getDataWidth=function(a){return Math.abs(this.getDataValue(a)-this.getDataValue(0))},o.prototype.getCoordWidth=function(a){return Math.abs(this.getCoordinate(a)-this.getCoordinate(0))},Object.defineProperty(o.prototype,"isFlipped",{get:function(){return this.nativeCalculator.IsFlipped()},enumerable:!1,configurable:!0}),o.prototype.delete=function(){var a;(a=this.nativeCalculator)===null||a===void 0||a.delete(),this.nativeCalculator=void 0,this.webAssemblyContext=void 0},o})(e.DeletableEntity);return W1.CoordinateCalculatorBase=n,W1}var Lye;function ZFe(){if(Lye)return $1;Lye=1;var t=$1&&$1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty($1,"__esModule",{value:!0}),$1.CategoryCoordinateCalculator=void 0;var e=iC(),i=(function(n){t(r,n);function r(o,a,s,l,u){u===void 0&&(u=0);var c=n.call(this,o,a,s,l,u,!0,!0)||this;return c.indexMin=s,c.indexMax=l,c.nativeCalculator=new o.CategoryCoordinateCalculatorDouble(c.viewportDimension,c.visibleMin,c.visibleMax,-1,c.offset,c.indexMin,c.indexMax),c}return r.prototype.transformIndexToData=function(o){var a=this.nativeCalculator.TransformIndexToData(o,this.baseXValues);return a},r.prototype.transformDataToIndex=function(o){var a=this.nativeCalculator.TransformDataToIndex(o,this.baseXValues);return a},r})(e.CoordinateCalculatorBase);return $1.CategoryCoordinateCalculator=i,$1}var G1={},kye;function JFe(){if(kye)return G1;kye=1;var t=G1&&G1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(G1,"__esModule",{value:!0}),G1.FlippedCategoryCoordinateCalculator=void 0;var e=iC(),i=(function(n){t(r,n);function r(o,a,s,l,u){u===void 0&&(u=0);var c=n.call(this,o,a,s,l,u,!1,!0)||this;return c.indexMin=s,c.indexMax=l,c.nativeCalculator=new o.FlippedCategoryCoordinateCalculatorDouble(c.viewportDimension,c.visibleMin,c.visibleMax,-1,c.offset,c.indexMin,c.indexMax),c}return r.prototype.transformIndexToData=function(o){var a=this.nativeCalculator.TransformIndexToData(o,this.baseXValues);return a},r.prototype.transformDataToIndex=function(o){var a=this.nativeCalculator.TransformDataToIndex(o,this.baseXValues);return a},r})(e.CoordinateCalculatorBase);return G1.FlippedCategoryCoordinateCalculator=i,G1}var Y1={},AF={},Iye;function wW(){if(Iye)return AF;Iye=1,Object.defineProperty(AF,"__esModule",{value:!0}),AF.TickProvider=void 0;var t=(function(){function e(){}return e.prototype.attachedToAxis=function(i){this.parentAxis=i},e.prototype.detachedFromAxis=function(){this.parentAxis=void 0},e})();return AF.TickProvider=t,AF}var Nye;function oR(){if(Nye)return Y1;Nye=1;var t=Y1&&Y1.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Y1,"__esModule",{value:!0}),Y1.NumericTickProvider=void 0;var e=ci(),i=di(),n=kp(),r=wW(),o=(function(a){t(s,a);function s(l){var u=a.call(this)||this;return u.minDeltaValue=1e-13,u.webAssemblyContext=l,u}return s.prototype.getMinorTicks=function(l,u,c){var d=new i.NumberRange(l,u),f=c;return this.isParamsValid(f,d)?this.calculateTicks(f,d.min,d.max):[]},s.prototype.getMajorTicks=function(l,u,c){var d=new i.NumberRange(l,u),f=c;return this.isParamsValid(f,d)?this.calculateTicks(f,d.max,d.max):[]},s.prototype.isParamsValid=function(l,u){return e.Guard.notNull(l,"visibleRange"),e.Guard.notNull(u,"deltaRange"),(0,n.isRealNumber)(l.min)&&(0,n.isRealNumber)(l.max)&&u.min>0&&u.max>0},s.prototype.calculateTicks=function(l,u,c){for(var d=[],f=l.min,h=l.max,p=u===c,g=this.webAssemblyContext.NumberUtil,v=g.RoundUp(f,u),y=v,m=0;v<=h;)g.IsDivisibleBy(v,c)===p&&d.push(v),v=y+ ++m*u;return d},s})(r.TickProvider);return Y1.NumericTickProvider=o,Y1}var q1={},OF={},DF={},Fye;function ZV(){if(Fye)return DF;Fye=1,Object.defineProperty(DF,"__esModule",{value:!0}),DF.GenericAnimation=void 0;var t=hl(),e=cP(),i=ad(),n=(function(){function r(o){var a,s,l,u;this.delay=0,this.duration=1e3,this.ease=i.easing.linear,this.id=(a=o==null?void 0:o.id)!==null&&a!==void 0?a:(0,t.generateGuid)(),this.delay=(s=o==null?void 0:o.delay)!==null&&s!==void 0?s:this.delay,this.duration=(l=o==null?void 0:o.duration)!==null&&l!==void 0?l:this.duration,o!=null&&o.ease&&typeof o.ease=="string"&&(o.ease=i.easing[o.ease]),this.ease=(u=o==null?void 0:o.ease)!==null&&u!==void 0?u:this.ease,this.from=o.from,this.to=o.to,this.onAnimate=o.onAnimate,this.onCompleted=o==null?void 0:o.onCompleted,this.animationFSM=new e.AnimationFiniteStateMachine(this),o!=null&&o.setInitialValueImmediately&&this.onAnimate(this.from,this.to,0)}return Object.defineProperty(r.prototype,"isComplete",{get:function(){return this.animationFSM.is([e.EAnimationState.Completed])},enumerable:!1,configurable:!0}),r.prototype.reset=function(){this.animationFSM=new e.AnimationFiniteStateMachine(this)},r.prototype.update=function(o){var a=this.animationFSM.update(o);[e.EAnimationStateTransition.InitialState_Running,e.EAnimationStateTransition.Delayed_Running].includes(a)&&this.onAnimate(this.from,this.to,0),this.animationFSM.is([e.EAnimationState.Running,e.EAnimationState.Completed])&&this.onAnimate(this.from,this.to,this.animationFSM.animationProgress),[e.EAnimationStateTransition.Running_Completed,e.EAnimationStateTransition.InitialState_Completed].includes(a)&&this.onCompleted&&this.onCompleted()},r.prototype.cancel=function(){this.animationFSM.toCompleted()},r})();return DF.GenericAnimation=n,DF}var Bye;function JV(){if(Bye)return OF;Bye=1,Object.defineProperty(OF,"__esModule",{value:!0}),OF.NumberRangeAnimator=void 0;var t=ci(),e=di(),i=ad(),n=ZV(),r=(function(){function o(){}return o.animate=function(a,s,l,u,c,d,f){d===void 0&&(d=i.easing.outExpo),f===void 0&&(f=!1);var h=new n.GenericAnimation({from:a,to:s,duration:l,onAnimate:function(p,g,v){var y=f?o.interpolateLog:o.interpolate,m=y(p,g,v);u(m)},delay:0,ease:d,onCompleted:c});return h},o.interpolate=function(a,s,l){t.Guard.notNull(a,"from"),t.Guard.notNull(s,"to");var u=(s.min-a.min)*l+a.min,c=(s.max-a.max)*l+a.max,d=new e.NumberRange(u,c);return d},o.interpolateLog=function(a,s,l){t.Guard.notNull(a,"from"),t.Guard.notNull(s,"to");var u=Math.pow(s.min/a.min,l)*a.min,c=Math.pow(s.max/a.max,l)*a.max,d=new e.NumberRange(u,c);return d},o})();return OF.NumberRangeAnimator=r,OF}var X1={},RF={},jye;function qre(){if(jye)return RF;jye=1,Object.defineProperty(RF,"__esModule",{value:!0}),RF.TickCoordinatesProvider=void 0;var t=(function(){function e(){}return e.prototype.attachedToAxis=function(i){this.parentAxis=i},e.prototype.detachedFromAxis=function(){this.parentAxis=void 0},e})();return RF.TickCoordinatesProvider=t,RF}var Vye;function Xre(){if(Vye)return X1;Vye=1;var t=X1&&X1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(X1,"__esModule",{value:!0}),X1.DefaultTickCoordinatesProvider=void 0;var e=qre(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.getTickCoordinates=function(o,a){if(o===void 0)return{majorTickCoords:void 0,minorTickCoords:void 0,majorTickOverrides:void 0,minorTickOverRides:void 0};var s=this.parentAxis.getCurrentCoordinateCalculator(),l=o.map(function(c){return Math.round(s.getCoordinate(c))+.5}),u=a.map(function(c){return Math.round(s.getCoordinate(c))+.5});return{majorTickCoords:l,minorTickCoords:u,majorTickOverrides:o,minorTickOverRides:a}},r})(e.TickCoordinatesProvider);return X1.DefaultTickCoordinatesProvider=i,X1}var K1={},Hye;function QFe(){if(Hye)return K1;Hye=1;var t=K1&&K1.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(K1,"__esModule",{value:!0}),K1.StaticTickCoordinatesProvider=void 0;var e=Xre(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.getTickCoordinates=function(o,a){var s=!this.parentAxis.visibleRange.equals(this.prevRange),l=this.parentAxis.getAxisSize()!==this.prevSize,u=this.parentAxis.getCurrentCoordinateCalculator(),c,d;if(this.tickCoords===void 0||l){if(o===void 0)return{majorTickCoords:void 0,minorTickCoords:void 0,majorTickOverrides:void 0,minorTickOverRides:void 0};var f=o.map(function(p){return u.getCoordinate(p)}),h=a.map(function(p){return u.getCoordinate(p)});this.tickCoords={majorTickCoords:f,minorTickCoords:h,majorTicks:o,minorTicks:a,majorTickLabels:void 0}}else s?(this.OverrideTickValues(this.tickCoords),c=this.tickCoords.majorTicks,d=this.tickCoords.minorTicks):this.OverrideTickCoordinates(this.tickCoords);return this.prevRange=this.parentAxis.visibleRange,this.prevSize=this.parentAxis.getAxisSize(),{majorTickCoords:this.tickCoords.majorTickCoords.map(function(p){return Math.round(p+.5)}),minorTickCoords:this.tickCoords.minorTickCoords.map(function(p){return Math.round(p+.5)}),majorTickOverrides:c,minorTickOverRides:d}},r.prototype.forceRecalculateCoords=function(){this.tickCoords=void 0},r.prototype.OverrideTickValues=function(o){var a=this.parentAxis.getCurrentCoordinateCalculator();a!=null&&(o.minorTickCoords.forEach(function(s,l){return o.minorTicks[l]=a.getDataValue(s)}),o.majorTickCoords.forEach(function(s,l){return o.majorTicks[l]=a.getDataValue(s)}))},r.prototype.OverrideTickCoordinates=function(o){var a=this.parentAxis.getCurrentCoordinateCalculator();a!=null&&a!=null&&(o.minorTicks.forEach(function(s,l){return o.minorTickCoords[l]=a.getCoordinate(s)}),o.majorTicks.forEach(function(s,l){return o.majorTickCoords[l]=a.getCoordinate(s)}))},r})(e.DefaultTickCoordinatesProvider);return K1.StaticTickCoordinatesProvider=i,K1}var G0={},D9={},Uye;function AW(){return Uye||(Uye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.ALLOW_FAST_MATH="ALLOW_FAST_MATH",e.AUTO_RANGE="AUTO_RANGE",e.AUTO_TICKS="AUTO_TICKS",e.AXIS_ALIGNMENT="AXIS_ALIGNMENT",e.AXIS_BANDS_FILL="AXIS_BANDS_FILL",e.AXIS_TITLE="AXIS_TITLE",e.AXIS_LENGTH="AXIS_LENGTH",e.AXIS_THICKNESS="AXIS_THICKNESS",e.BORDER="BORDER",e.CURSOR_TEXT_FORMATTING="CURSOR_TEXT_FORMATTING",e.DELTA_CALCULATOR="DELTA_CALCULATOR",e.TICK_COORDINATES_CALCULATOR="TICK_COORDINATES_CALCULATOR",e.DRAW_MAJOR_GRID_LINES="DRAW_MAJOR_GRID_LINES",e.DRAW_MINOR_GRID_LINES="DRAW_MINOR_GRID_LINES",e.DRAW_MAJOR_TICK_LINES="DRAW_MAJOR_TICK_LINES",e.DRAW_MINOR_TICK_LINES="DRAW_MINOR_TICK_LINES",e.DRAW_MAJOR_BANDS="DRAW_MAJOR_BANDS",e.DRAW_LABELS="DRAW_LABELS",e.FLIPPED_COORDINATES="FLIPPED_COORDINATES",e.GROW_BY="GROW_BY",e.ID="ID",e.IS_AXIS_FLIPPED="IS_AXIS_FLIPPED",e.IS_NEGATIVE="IS_NEGATIVE",e.IS_INNER_AXIS="IS_INNER_AXIS",e.IS_PRIMARY_AXIS="IS_PRIMARY_AXIS",e.IS_VISIBLE="IS_VISIBLE",e.IS_XAXIS="IS_XAXIS",e.LABEL_PROVIDER="LABEL_PROVIDER",e.AXIS_RENDERER="LABEL_PROVIDER",e.LOG_BASE="LOG_BASE",e.MAJOR_DELTA="MAJOR_DELTA",e.MAJOR_GRID_LINE_STYLE="MAJOR_GRID_LINE_STYLE",e.MAJOR_TICK_LINE_STYLE="MAJOR_TICK_LINE_STYLE",e.MAX_AUTO_TICKS="MAX_AUTO_TICKS",e.MINOR_DELTA="MINOR_DELTA",e.MINOR_GRID_LINE_STYLE="MINOR_GRID_LINE_STYLE",e.MINOR_TICK_LINE_STYLE="MINOR_TICK_LINE_STYLE",e.MINORS_PER_MAJOR="MINORS_PER_MAJOR",e.OFFSET="OFFSET",e.TEXT_FORMATTING="TEXT_FORMATTING",e.TEXT_STYLE="TEXT_STYLE",e.TICK_TEXT_BRUSH="TICK_TEXT_BRUSH",e.VISIBLE_RANGE="VISIBLE_RANGE",e.VISIBLE_RANGE_LIMIT="VISIBLE_RANGE_LIMIT",e.VISIBLE_RANGE_SIZE_LIMIT="VISIBLE_RANGE_SIZE_LIMIT",e.TICK_PROVIDER="TICK_PROVIDER",e.VIEW_RECT="VIEW_RECT",e.ZOOMEXTENTS_RANGE="ZOOMEXTENTS_RANGE",e.DRAW_ONLY_WITHIN_XRANGE="DRAW_ONLY_WITHIN_XRANGE",e.HIGH_PRECISION_TICKS="HIGH_PRECISION_TICKS"})(t.PROPERTY||(t.PROPERTY={}))})(D9)),D9}var MF={},zye;function eBe(){if(zye)return MF;zye=1,Object.defineProperty(MF,"__esModule",{value:!0}),MF.VisibleRangeChangedArgs=void 0;var t=(function(){function e(i){this.visibleRange=i}return e})();return MF.VisibleRangeChangedArgs=t,MF}var $ye;function Kre(){if($ye)return G0;$ye=1;var t=G0&&G0.__extends||(function(){var m=function(b,S){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,C){_.__proto__=C}||function(_,C){for(var P in C)Object.prototype.hasOwnProperty.call(C,P)&&(_[P]=C[P])},m(b,S)};return function(b,S){if(typeof S!="function"&&S!==null)throw new TypeError("Class extends value "+String(S)+" is not a constructor or null");m(b,S);function _(){this.constructor=b}b.prototype=S===null?Object.create(S):(_.prototype=S.prototype,new _)}})(),e=G0&&G0.__assign||function(){return e=Object.assign||function(m){for(var b,S=1,_=arguments.length;S<_;S++){b=arguments[S];for(var C in b)Object.prototype.hasOwnProperty.call(b,C)&&(m[C]=b[C])}return m},e.apply(this,arguments)};Object.defineProperty(G0,"__esModule",{value:!0}),G0.AxisCore=void 0;var i=fo(),n=Br(),r=ps(),o=ci(),a=di(),s=pa(),l=tR(),u=kI(),c=Vf(),d=hl(),f=kp(),h=Sn(),p=Zi(),g=AW(),v=eBe(),y=(function(m){t(b,m);function b(S){var _=this,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y;return _=m.call(this)||this,_.visibleRangeChanged=new r.EventHandler,_.isMeasured=!1,_.ZeroRangeGrowBy=.01,_.isXAxisProperty=!0,_.minorsPerMajorProperty=5,_.drawMajorGridLinesProperty=!0,_.drawMinorGridLinesProperty=!0,_.drawMajorTickLinesProperty=!0,_.drawMinorTickLinesProperty=!0,_.drawMajorBandsProperty=!0,_.drawLabelsProperty=!0,_.flippedCoordinatesProperty=!1,_.tickTextBrushProperty=h.SciChartSurfaceBase.DEFAULT_THEME.tickTextBrush,_.axisBandsFillProperty=h.SciChartSurfaceBase.DEFAULT_THEME.axisBandsFill,_.autoRangeProperty=l.EAutoRange.Once,_.majorTickLineStyleProperty={tickSize:5,strokeThickness:1,color:h.SciChartSurfaceBase.DEFAULT_THEME.majorGridLineBrush},_.minorTickLineStyleProperty={tickSize:3,strokeThickness:1,color:h.SciChartSurfaceBase.DEFAULT_THEME.minorGridLineBrush},_.majorGridLineStyleProperty={strokeThickness:1,color:h.SciChartSurfaceBase.DEFAULT_THEME.majorGridLineBrush,strokeDashArray:void 0},_.minorGridLineStyleProperty={strokeThickness:1,color:h.SciChartSurfaceBase.DEFAULT_THEME.minorGridLineBrush,strokeDashArray:void 0},_.axisTitleStyleProperty={fontSize:24,fontFamily:(0,c.getDefaultFontName)(),color:h.SciChartSurfaceBase.DEFAULT_THEME.axisTitleColor,fontStyle:"normal",fontWeight:"normal",padding:s.Thickness.fromNumber(6),alignment:u.ELabelAlignment.Center},_.isVisibleProperty=!0,_.autoTicksProperty=!0,_.maxAutoTicksProperty=10,_.defaultVisibleRange=new a.NumberRange(0,10),_.allowFastMathProperty=!1,_.hasVisibleRangeSet=!1,_.visibleRange=a.NumberRange.hydrate(S==null?void 0:S.visibleRange)||_.defaultVisibleRange,S!=null&&S.visibleRange||(_.hasVisibleRangeSet=!1),_.id=(C=S==null?void 0:S.id)!==null&&C!==void 0?C:(0,d.generateGuid)(),_.growBy=(P=a.NumberRange.hydrate(S==null?void 0:S.growBy))!==null&&P!==void 0?P:_.growBy,_.autoRange=(x=S==null?void 0:S.autoRange)!==null&&x!==void 0?x:_.autoRange,_.isVisible=(E=S==null?void 0:S.isVisible)!==null&&E!==void 0?E:_.isVisible,_.axisTitle=(A=S==null?void 0:S.axisTitle)!==null&&A!==void 0?A:_.axisTitle,_.axisTitleStyle=S==null?void 0:S.axisTitleStyle,_.allowFastMath=(R=S==null?void 0:S.allowFastMath)!==null&&R!==void 0?R:_.allowFastMathProperty,_.autoTicksProperty=(M=S==null?void 0:S.autoTicks)!==null&&M!==void 0?M:_.autoTicksProperty,_.maxAutoTicksProperty=(D=S==null?void 0:S.maxAutoTicks)!==null&&D!==void 0?D:_.maxAutoTicksProperty,_.minorsPerMajorProperty=(F=S==null?void 0:S.minorsPerMajor)!==null&&F!==void 0?F:_.minorsPerMajorProperty,_.majorDeltaProperty=(I=S==null?void 0:S.majorDelta)!==null&&I!==void 0?I:_.majorDeltaProperty,_.minorDeltaProperty=(V=S==null?void 0:S.minorDelta)!==null&&V!==void 0?V:_.minorDeltaProperty,_.drawLabelsProperty=(z=S==null?void 0:S.drawLabels)!==null&&z!==void 0?z:_.drawLabelsProperty,_.drawMajorTickLinesProperty=(G=S==null?void 0:S.drawMajorTickLines)!==null&&G!==void 0?G:_.drawMajorTickLinesProperty,_.drawMinorTickLinesProperty=(H=S==null?void 0:S.drawMinorTickLines)!==null&&H!==void 0?H:_.drawMinorTickLinesProperty,_.drawMinorGridLinesProperty=(U=S==null?void 0:S.drawMinorGridLines)!==null&&U!==void 0?U:_.drawMinorGridLinesProperty,_.drawMajorGridLinesProperty=(k=S==null?void 0:S.drawMajorGridLines)!==null&&k!==void 0?k:_.drawMajorGridLinesProperty,_.majorGridLineStyle=S==null?void 0:S.majorGridLineStyle,_.minorGridLineStyle=S==null?void 0:S.minorGridLineStyle,_.majorTickLineStyle=S==null?void 0:S.majorTickLineStyle,_.minorTickLineStyle=S==null?void 0:S.minorTickLineStyle,_.drawMajorBandsProperty=(X=S==null?void 0:S.drawMajorBands)!==null&&X!==void 0?X:_.drawMajorBandsProperty,_.axisBandsFillProperty=(W=S==null?void 0:S.axisBandsFill)!==null&&W!==void 0?W:_.axisBandsFillProperty,_.flippedCoordinatesProperty=(Y=S==null?void 0:S.flippedCoordinates)!==null&&Y!==void 0?Y:_.flippedCoordinatesProperty,_.getCurrentCoordinateCalculator=_.getCurrentCoordinateCalculator.bind(_),_}return Object.defineProperty(b.prototype,"isCategoryAxis",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"isXAxis",{get:function(){return this.isXAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"allowFastMath",{get:function(){return this.allowFastMathProperty},set:function(S){this.allowFastMathProperty=S,this.notifyPropertyChanged(g.PROPERTY.ALLOW_FAST_MATH)},enumerable:!1,configurable:!0}),b.prototype.hasValidVisibleRange=function(){if(this.visibleRange===void 0)return!1;var S=this.visibleRange.diff===0;return!S&&(0,f.isRealNumber)(this.visibleRange.max)&&(0,f.isRealNumber)(this.visibleRange.min)},b.prototype.hasDefaultVisibleRange=function(){return!this.hasVisibleRangeSet},Object.defineProperty(b.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(S){this.isVisibleProperty=S,this.notifyPropertyChanged(g.PROPERTY.IS_VISIBLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"growBy",{get:function(){return this.growByProperty},set:function(S){this.growByProperty=S,this.notifyPropertyChanged(g.PROPERTY.GROW_BY)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"visibleRange",{get:function(){return this.visibleRangeProperty},set:function(S){var _;this.hasVisibleRangeSet=!0,!((_=this.visibleRangeProperty)===null||_===void 0)&&_.equals(S)||(this.visibleRangeProperty=S,this.clearCoordCalcCache(),this.visibleRangeChanged.raiseEvent(new v.VisibleRangeChangedArgs(S)),this.notifyPropertyChanged(g.PROPERTY.VISIBLE_RANGE))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"animatedVisibleRange",{get:function(){if(!this.visibleRangeAnimationToken)return this.visibleRange;var S=this.visibleRangeAnimationToken;return S.to},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"majorDelta",{get:function(){return this.majorDeltaProperty},set:function(S){this.majorDeltaProperty=S,this.notifyPropertyChanged(g.PROPERTY.MAJOR_DELTA)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"minorDelta",{get:function(){return this.minorDeltaProperty},set:function(S){this.minorDeltaProperty=S,this.notifyPropertyChanged(g.PROPERTY.MINOR_DELTA)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"minorsPerMajor",{get:function(){return this.minorsPerMajorProperty},set:function(S){this.minorsPerMajorProperty=S,this.notifyPropertyChanged(g.PROPERTY.MINORS_PER_MAJOR)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"textFormatting",{get:function(){return this.textFormattingProperty},set:function(S){this.textFormattingProperty=S,this.notifyPropertyChanged(g.PROPERTY.TEXT_FORMATTING)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"cursorTextFormatting",{get:function(){return this.cursorTextFormattingProperty},set:function(S){this.cursorTextFormattingProperty=S,this.notifyPropertyChanged(g.PROPERTY.CURSOR_TEXT_FORMATTING)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawMajorGridLines",{get:function(){return this.drawMajorGridLinesProperty},set:function(S){this.drawMajorGridLinesProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_MAJOR_GRID_LINES)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawMinorGridLines",{get:function(){return this.drawMinorGridLinesProperty},set:function(S){this.drawMinorGridLinesProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_MINOR_GRID_LINES)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawMajorTickLines",{get:function(){return this.drawMajorTickLinesProperty},set:function(S){this.drawMajorTickLinesProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_MAJOR_TICK_LINES)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawMinorTickLines",{get:function(){return this.drawMinorTickLinesProperty},set:function(S){this.drawMinorTickLinesProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_MINOR_TICK_LINES)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawMajorBands",{get:function(){return this.drawMajorBandsProperty},set:function(S){this.drawMajorBandsProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_MAJOR_BANDS)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"drawLabels",{get:function(){return this.drawLabelsProperty},set:function(S){this.drawLabelsProperty=S,this.notifyPropertyChanged(g.PROPERTY.DRAW_LABELS)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"flippedCoordinates",{get:function(){return this.flippedCoordinatesProperty},set:function(S){this.flippedCoordinatesProperty!==S&&(this.flippedCoordinatesProperty=S,this.clearCoordCalcCache(),this.notifyPropertyChanged(g.PROPERTY.FLIPPED_COORDINATES))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"axisBandsFill",{get:function(){return this.axisBandsFillProperty},set:function(S){this.axisBandsFillProperty=S,this.notifyPropertyChanged(g.PROPERTY.AXIS_BANDS_FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"autoRange",{get:function(){return this.autoRangeProperty},set:function(S){this.autoRangeProperty=S,this.notifyPropertyChanged(g.PROPERTY.AUTO_RANGE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"majorTickLineStyle",{get:function(){return this.majorTickLineStyleProperty},set:function(S){this.majorTickLineStyleProperty=e(e({},this.majorTickLineStyle),S),this.notifyPropertyChanged(g.PROPERTY.MAJOR_TICK_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"minorTickLineStyle",{get:function(){return this.minorTickLineStyleProperty},set:function(S){this.minorTickLineStyleProperty=e(e({},this.minorTickLineStyle),S),this.notifyPropertyChanged(g.PROPERTY.MINOR_TICK_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"majorGridLineStyle",{get:function(){return this.majorGridLineStyleProperty},set:function(S){this.majorGridLineStyleProperty=e(e({},this.majorGridLineStyle),S),this.notifyPropertyChanged(g.PROPERTY.MAJOR_GRID_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"minorGridLineStyle",{get:function(){return this.minorGridLineStyleProperty},set:function(S){this.minorGridLineStyleProperty=e(e({},this.minorGridLineStyle),S),this.notifyPropertyChanged(g.PROPERTY.MINOR_GRID_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"dpiAdjustedAxisTitleStyle",{get:function(){return p.DpiHelper.adjustTextStyle(this.axisTitleStyleProperty)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"axisTitleStyle",{get:function(){return this.axisTitleStyleProperty},set:function(S){this.axisTitleStyleProperty=e(e({},this.axisTitleStyle),S),this.notifyPropertyChanged(g.PROPERTY.TEXT_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"axisTitle",{get:function(){return this.axisTitleProperty},set:function(S){this.axisTitleProperty=S,this.notifyPropertyChanged(g.PROPERTY.AXIS_TITLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"tickProvider",{get:function(){return this.tickProviderProperty},set:function(S){var _;(_=this.tickProviderProperty)===null||_===void 0||_.detachedFromAxis(),this.tickProviderProperty=S,this.notifyPropertyChanged(g.PROPERTY.TICK_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"labelProvider",{get:function(){return this.labelProviderProperty},set:function(S){var _;(_=this.labelProviderProperty)===null||_===void 0||_.detachedFromAxis(),this.labelProviderProperty=S,this.notifyPropertyChanged(g.PROPERTY.LABEL_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"deltaCalculator",{get:function(){return this.deltaCalculatorProperty},set:function(S){var _;(_=this.deltaCalculator)===null||_===void 0||_.detachedFromAxis(),this.deltaCalculatorProperty=S,this.notifyPropertyChanged(g.PROPERTY.DELTA_CALCULATOR)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"tickCoordinatesProvider",{get:function(){return this.tickCoordinatesProviderProperty},set:function(S){var _;(_=this.tickCoordinatesProviderProperty)===null||_===void 0||_.detachedFromAxis(),this.tickCoordinatesProviderProperty=S,this.notifyPropertyChanged(g.PROPERTY.TICK_COORDINATES_CALCULATOR)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"maxAutoTicks",{get:function(){return this.maxAutoTicksProperty},set:function(S){this.maxAutoTicksProperty=S,this.notifyPropertyChanged(g.PROPERTY.MAX_AUTO_TICKS)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"autoTicks",{get:function(){return this.autoTicksProperty},set:function(S){this.autoTicksProperty=S,this.notifyPropertyChanged(g.PROPERTY.AUTO_TICKS)},enumerable:!1,configurable:!0}),b.prototype.getCurrentCoordinateCalculator=function(){return this.coordCalcCache&&this.coordCalcCache.viewportDimension!==this.getAxisSize()&&this.clearCoordCalcCache(),this.coordCalcCache||(this.coordCalcCache=this.getCurrentCoordinateCalculatorInternal()),this.coordCalcCache},b.prototype.clearCoordCalcCache=function(){this.coordCalcCache=(0,n.deleteSafe)(this.coordCalcCache)},b.prototype.delete=function(){this.deltaCalculator=void 0,this.tickProvider=void 0,this.tickCoordinatesProvider=void 0,this.labelProviderProperty=(0,n.deleteSafe)(this.labelProvider),this.coordCalcCache=(0,n.deleteSafe)(this.coordCalcCache)},b.prototype.isValidRange=function(S){var _=!S||!S.isDefined()||S.min>S.max;return!_},Object.defineProperty(b.prototype,"isVerticalChart",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"isHorizontalAxis",{get:function(){return this.isXAxis},enumerable:!1,configurable:!0}),b.prototype.setIsXAxis=function(S){this.isXAxisProperty=S,this.notifyPropertyChanged(g.PROPERTY.IS_XAXIS)},b.prototype.coerceZeroVisibleRange=function(S){return o.Guard.notNull(S,"range"),S.isZero()?S.min===0?new a.NumberRange(-1,1):S.growBy(new a.NumberRange(this.ZeroRangeGrowBy,this.ZeroRangeGrowBy)):S},b.prototype.notifyPropertyChanged=function(S){var _,C,P,x;S===g.PROPERTY.DELTA_CALCULATOR&&((_=this.deltaCalculator)===null||_===void 0||_.attachedToAxis(this)),S===g.PROPERTY.TICK_PROVIDER&&((C=this.tickProvider)===null||C===void 0||C.attachedToAxis(this)),S===g.PROPERTY.LABEL_PROVIDER&&((P=this.labelProvider)===null||P===void 0||P.attachedToAxis(this)),S===g.PROPERTY.TICK_COORDINATES_CALCULATOR&&((x=this.tickCoordinatesProvider)===null||x===void 0||x.attachedToAxis(this)),this.isMeasured&&this.invalidateParentCallback&&this.invalidateParentCallback()},b.prototype.getMaxAutoTicks=function(){return Math.max(1,this.maxAutoTicks)},b})(i.DeletableEntity);return G0.AxisCore=y,G0}var Y0={},Wye;function Qz(){if(Wye)return Y0;Wye=1;var t=Y0&&Y0.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(Y0,"__esModule",{value:!0}),Y0.PolarAxisLayoutState=Y0.AxisLayoutState=void 0;var e=(function(){function n(){this.axisSize=0,this.additionalLeftSize=0,this.additionalRightSize=0,this.additionalTopSize=0,this.additionalBottomSize=0}return n.prototype.clear=function(){this.axisSize=0,this.additionalLeftSize=0,this.additionalRightSize=0,this.additionalTopSize=0,this.additionalBottomSize=0},n})();Y0.AxisLayoutState=e;var i=(function(n){t(r,n);function r(){var o=n!==null&&n.apply(this,arguments)||this;return o.leftScale=-1,o.rightScale=1,o.topScale=1,o.bottomScale=-1,o}return r.prototype.clear=function(){this.leftScale=-1,this.rightScale=1,this.topScale=1,this.bottomScale=-1},r})(e);return Y0.PolarAxisLayoutState=i,Y0}var Z1={},Gye;function Zre(){return Gye||(Gye=1,(function(t){var e=Z1&&Z1.__extends||(function(){var C=function(P,x){return C=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(E,A){E.__proto__=A}||function(E,A){for(var R in A)Object.prototype.hasOwnProperty.call(A,R)&&(E[R]=A[R])},C(P,x)};return function(P,x){if(typeof x!="function"&&x!==null)throw new TypeError("Class extends value "+String(x)+" is not a constructor or null");C(P,x);function E(){this.constructor=P}P.prototype=x===null?Object.create(x):(E.prototype=x.prototype,new E)}})(),i=Z1&&Z1.__assign||function(){return i=Object.assign||function(C){for(var P,x=1,E=arguments.length;x<E;x++){P=arguments[x];for(var A in P)Object.prototype.hasOwnProperty.call(P,A)&&(C[A]=P[A])}return C},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.layoutLabelsHelper=t.AxisRenderer=void 0;var n=Uo(),r=fo(),o=Br(),a=Rn(),s=pa(),l=od(),u=kI(),c=Tc(),d=kh(),f=Ti(),h=id(),p=Iu(),g=ZP(),v=an(),y=Sn(),m=Zi(),b=gD(),S=(function(C){e(P,C);function P(x){var E=C.call(this)||this;return E.viewRect=a.Rect.createZero(),E.drawDebug=!1,E.desiredLabelsSize=0,E.desiredTicksSize=0,E.desiredHeightProperty=0,E.desiredWidthProperty=0,E.axisThicknessProperty=0,E.keepLabelsWithinAxisProperty=!0,E.hideOverlappingLabelsProperty=!0,E.webAssemblyContext=x,E.textureManager=new b.TextureManager(x),n.IS_TEST_ENV||(E.measureTextCanvas=document.createElement("canvas"),E.measureTextCanvas.width=1,E.measureTextCanvas.height=1),E}return P.prototype.delete=function(){this.webAssemblyContext=void 0,this.measureTextCanvas=void 0,this.parentAxis=void 0,this.textureManager=(0,o.deleteSafe)(this.textureManager)},P.prototype.attachedToAxis=function(x){this.parentAxis=x},P.prototype.measure=function(x,E,A,R,M,D,F){y.DebugForDpi&&console.log("AxisRenderer.measure. fontSize: ".concat(E.fontSize)),this.desiredLabelsSize=D?this.calcDesiredLabelsSize(x,M,E,A):0,this.desiredTicksSize=F?R:0;var I=Math.max(this.desiredLabelsSize,this.axisThicknessProperty*m.DpiHelper.PIXEL_RATIO),V=I+this.desiredTicksSize;x?this.desiredHeightProperty=V:this.desiredWidthProperty=V},P.prototype.calcDesiredLabelsSize=function(x,E,A,R){if(n.IS_TEST_ENV)return 0;var M,D=this.measureTextCanvas.getContext("2d");return x?M=E.getMaxLabelHeightForHorizontalAxis(R,D,A):M=E.getMaxLabelWidthForVerticalAxis(R,D,A),M},Object.defineProperty(P.prototype,"desiredHeight",{get:function(){return this.desiredHeightProperty},set:function(x){this.desiredHeightProperty=x},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"desiredWidth",{get:function(){return this.desiredWidthProperty},set:function(x){this.desiredWidthProperty=x},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"keepLabelsWithinAxis",{get:function(){return this.keepLabelsWithinAxisProperty},set:function(x){this.keepLabelsWithinAxisProperty=x,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"hideOverlappingLabels",{get:function(){return this.hideOverlappingLabelsProperty},set:function(x){this.hideOverlappingLabelsProperty=x,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"axisThickness",{get:function(){return this.axisThicknessProperty},set:function(x){this.axisThicknessProperty=x,this.invalidateParent()},enumerable:!1,configurable:!0}),P.prototype.layout=function(x){this.viewRect=x},P.prototype.getClipRect=function(){return this.parentAxis.parentSurface.clipRect},P.prototype.drawLabels=function(x,E,A,R,M,D,F,I,V,z){y.DebugForDpi&&console.log("AxisRenderer.drawLabels. fontSize: ".concat(F.fontSize));var G=this,H=G.viewRect,U=G.textureManager,k=I?(0,l.getIsHorizontal)(E):(0,l.getIsVertical)(E),X=Math.floor(H.width),W=Math.floor(H.height),Y=this.desiredTicksSize,te,oe=F.padding,de=F.alignment,ge=F.multilineAlignment;k&&(M=M.reverse(),R=R.reverse());var Ee=[],Re=(0,f.parseColorToUIntArgb)(F.color),Ae=z.useNativeText?x.getFont(F,z.rotation!==0):null,Pe=z.useNativeText?(0,v.getTextBounds)(this.webAssemblyContext):null;Ae||(te=U.getTextureContext(X,W));var we=z.rotation;we>90?we-=180:we<-90&&(we+=180);var Te=-(we*Math.PI)/180;M=M.map(function(mt){return mt-D});var ke=(0,c.convertMultiLineAlignment)(ge,this.webAssemblyContext),$e=z.lineSpacing,Ne=this.calculateLineHightForNativeFont(Ae,Pe),ve=this.getClipRect();if((0,l.getIsHorizontal)(E)){var pe=[],fe=[];if(!z.useCache&&z.useNativeText)for(var me=0,Ce=R;me<Ce.length;me++){var Ue=Ce[me];Ae.CalculateStringBounds(Ue??"",Pe,$e),pe.push(Pe.m_fHeight+F.padding.top+F.padding.bottom),fe.push(Pe.m_fWidth+F.padding.left+F.padding.right)}else pe=R.map(function(mt){return z.getLabelHeight(te,mt,F)}),fe=R.map(function(mt){return z.getLabelWidth(te,mt,F)});for(var Qe=this.layoutLabels(X,M,fe,V,oe==null?void 0:oe.top,oe==null?void 0:oe.bottom),it=Qe.labelCoords,xt=Qe.labelIndexes,wt=0;wt<xt.length;wt++){var $t=it[wt],Mt=R[xt[wt]],rt=pe[xt[wt]],qe=fe[xt[wt]],vt=0;E===l.EAxisAlignment.Bottom&&!A||E===l.EAxisAlignment.Top&&A?vt+=Y:vt+=W-rt-Y,this.drawDebug&&Ee.push(a.Rect.create($t,vt,qe,rt));try{if(Ae){var kt=$t+H.left+oe.left,Xe=vt+H.top+Ne+oe.top,_t=kt,Ht=Xe-Ne;if(Te!==0){var Pt=z.getNativeLabelInfo(Mt),Jt=Pt.textWidth,zt=Pt.textHeight;kt=M[xt[wt]]+H.left-zt*Math.sin(Te)/2,_t=kt,Te>0&&(kt-=Jt)}var Bt=z.adjustLabel(wt,Mt,qe,rt,kt,Xe,_t,Ht,Te),Mr=Bt.text,Be=Bt.x,We=Bt.y,dt=Bt.rx,Tt=Bt.ry,nr=Bt.rotationRadians,Ar=Bt.color;Ae.DrawStringAdvanced(Mr??"",Ar??Re,Math.round(Be),Math.round(We),(0,v.getVector4)(this.webAssemblyContext,dt,Tt,nr,0),ke,$e)}else{var Qr=z.getCachedLabelTexture(Mt,U,F),Si=Qr.bitmapTexture,oi=Qr.textureHeight,Yr=Qr.textureWidth;if(Si){x.resetAndClip(ve);var vi=z.adjustLabel(wt,Mt,qe,rt,$t+H.left,vt+H.top,0,0,0),Be=vi.x,We=vi.y;x.drawTexture(Si,Math.round(Be),Math.round(We),Yr,oi),z.useCache||Si.delete()}}}catch(mt){d.Logger.debug(mt),z.delete()}}}else{var pe=[],fe=[];if(!z.useCache&&z.useNativeText)for(var rr=0,Ji=R;rr<Ji.length;rr++){var Ue=Ji[rr];Ae.CalculateStringBounds(Ue??"",Pe,$e),pe.push(Pe.m_fHeight+F.padding.top+F.padding.bottom),fe.push(Pe.m_fWidth+F.padding.left+F.padding.right)}else pe=R.map(function(Yt){return z.getLabelHeight(te,Yt,F)}),fe=R.map(function(Yt){return z.getLabelWidth(te,Yt,F)});for(var qn=this.layoutLabels(W,M,pe,V,oe==null?void 0:oe.left,oe==null?void 0:oe.right),it=qn.labelCoords,xt=qn.labelIndexes,wt=0;wt<xt.length;wt++){var $t=0,Mt=R[xt[wt]],qe=fe[xt[wt]],rt=pe[xt[wt]];$t=this.adjustForLabelAlignment($t,qe,de,E,A,X,Y);var vt=it[wt];this.drawDebug&&Ee.push(a.Rect.create($t,vt,qe,rt));try{if(Ae){var kt=$t+H.left+oe.left,Xe=vt+H.top+Ne+oe.top,ri=z.adjustLabel(wt,Mt,qe,rt,kt,Xe,kt,Xe,Te),Mr=ri.text,Be=ri.x,We=ri.y,dt=ri.rx,Tt=ri.ry,nr=ri.rotationRadians,Ar=ri.color;Ae.DrawStringAdvanced(Mr??"",Ar??Re,Math.round(Be),Math.round(We),(0,v.getVector4)(this.webAssemblyContext,dt,Tt,nr,0),ke,$e)}else{var eo=z.getCachedLabelTexture(Mt,U,F),Si=eo.bitmapTexture,oi=eo.textureHeight,Yr=eo.textureWidth;if(Si){x.resetAndClip(ve);var xn=z.adjustLabel(wt,Mt,qe,rt,$t+H.left,vt+H.top,0,0,0),Be=xn.x,We=xn.y;x.drawTexture(Si,Math.round(Be),Math.round(We),Yr,oi),z.useCache||Si.delete()}}}catch(st){d.Logger.debug(st),z.delete()}}}this.drawDebug&&this.drawLabelViewRects(x,H,Ee)},P.prototype.adjustForLabelAlignment=function(x,E,A,R,M,D,F){var I=D-F-E;return R===l.EAxisAlignment.Left&&!M||R===l.EAxisAlignment.Right&&M?A===u.ELabelAlignment.Right||A===u.ELabelAlignment.Auto?x+=I:A===u.ELabelAlignment.Center&&(x+=I/2):A===u.ELabelAlignment.Left||A===u.ELabelAlignment.Auto?x+=F:A===u.ELabelAlignment.Center?x+=F+I/2:x+=D-E,x},P.prototype.layoutLabels=function(x,E,A,R,M,D){var F,I;return(0,t.layoutLabelsHelper)(this.keepLabelsWithinAxis,this.hideOverlappingLabels,x,E,A,R,(I=(F=this.parentAxis)===null||F===void 0?void 0:F.labelProvider)===null||I===void 0?void 0:I.alwaysShowFirstLabel)},P.prototype.drawTicks=function(x,E,A,R,M,D,F){if(!(!R||R.length===0)){var I=this.viewRect,V=F.tickSize,z=(0,v.getVectorColorVertex)(this.webAssemblyContext),G=(0,l.getIsHorizontal)(E),H=(0,v.getVertex)(this.webAssemblyContext,0,0);if(G!==void 0){R.forEach(function(X){var W,Y,te,oe;A?G?(W=X,Y=X,te=E===l.EAxisAlignment.Top?0:I.height,oe=E===l.EAxisAlignment.Top?V:I.height-V):(W=E===l.EAxisAlignment.Left?0:I.width,Y=E===l.EAxisAlignment.Left?V:I.width-V,te=X,oe=X):G?(W=X,Y=X,te=E===l.EAxisAlignment.Bottom?0:I.height,oe=E===l.EAxisAlignment.Bottom?V:I.height-V):(W=E===l.EAxisAlignment.Right?0:I.width,Y=E===l.EAxisAlignment.Right?V:I.width-V,te=X,oe=X),H.SetPosition(W,te),z.push_back(H),H.SetPosition(Y,oe),z.push_back(H)});var U=I.left-(G?M:0),k=I.top-(G?0:M);x.drawLinesNative(z,D,p.ELineDrawMode.DiscontinuousLine,this.getClipRect(),U,k)}}},P.prototype.getAxisReservedSpace=function(x){var E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe=0;!((E=this.parentAxis)===null||E===void 0)&&E.drawMajorTickLines&&(Pe=Math.max(Pe,(R=(A=this.parentAxis.majorTickLineStyle)===null||A===void 0?void 0:A.tickSize)!==null&&R!==void 0?R:0)),!((M=this.parentAxis)===null||M===void 0)&&M.drawMinorTickLines&&(Pe=Math.max(Pe,(F=(D=this.parentAxis.minorTickLineStyle)===null||D===void 0?void 0:D.tickSize)!==null&&F!==void 0?F:0));var we=(I=this.parentAxis)===null||I===void 0?void 0:I.axisAlignment;switch(we){case l.EAxisAlignment.Left:Pe+=(z=(V=this.parentAxis.labelStyle)===null||V===void 0?void 0:V.padding.right)!==null&&z!==void 0?z:0,Pe+=(H=(G=this.parentAxis.axisBorder.borderRight)!==null&&G!==void 0?G:this.parentAxis.axisBorder.border)!==null&&H!==void 0?H:0;break;case l.EAxisAlignment.Right:Pe+=(k=(U=this.parentAxis.labelStyle)===null||U===void 0?void 0:U.padding.left)!==null&&k!==void 0?k:0,Pe+=(W=(X=this.parentAxis.axisBorder.borderLeft)!==null&&X!==void 0?X:this.parentAxis.axisBorder.border)!==null&&W!==void 0?W:0;break;case l.EAxisAlignment.Top:Pe+=(te=(Y=this.parentAxis.labelStyle)===null||Y===void 0?void 0:Y.padding.bottom)!==null&&te!==void 0?te:0,Pe+=(de=(oe=this.parentAxis.axisBorder.borderBottom)!==null&&oe!==void 0?oe:this.parentAxis.axisBorder.border)!==null&&de!==void 0?de:0;break;case l.EAxisAlignment.Bottom:Pe+=(Ee=(ge=this.parentAxis.labelStyle)===null||ge===void 0?void 0:ge.padding.top)!==null&&Ee!==void 0?Ee:0,Pe+=(Ae=(Re=this.parentAxis.axisBorder.borderTop)!==null&&Re!==void 0?Re:this.parentAxis.axisBorder.border)!==null&&Ae!==void 0?Ae:0;break}Pe-=1.5,(we===l.EAxisAlignment.Top||we===l.EAxisAlignment.Bottom)&&(Pe-=4/m.DpiHelper.PIXEL_RATIO);var Te=this.parentAxis.isInnerAxis?-1:1;return Pe*Te},P.prototype.drawModifiersAxisLabel=function(x,E,A,R,M,D,F,I){if(E){var V=this.parentAxis.parentSurface,z=a.Rect.intersect(V.viewRect,V.clipRect);x.resetAndClip(z);var G=this.textureManager.createSimpleTextTexture(E,i(i({},M),{padding:new s.Thickness(F.top+2*m.DpiHelper.PIXEL_RATIO,F.right,F.bottom+2*m.DpiHelper.PIXEL_RATIO,F.left)}),D,void 0,void 0,void 0,I),H=G.bitmapTexture,U=G.textureHeight,k=G.textureWidth,X=function(de,ge,Ee){return de+ge-Ee/2},W=this.parentAxis.offset,Y=0,te=0,oe=this.getAxisReservedSpace()*m.DpiHelper.PIXEL_RATIO;switch(R){case l.EAxisAlignment.Top:{Y=X(this.viewRect.x-W,A,k),this.parentAxis.isInnerAxis?te=this.viewRect.y:te=this.viewRect.y+this.viewRect.height-U,te-=oe;break}case l.EAxisAlignment.Bottom:{Y=X(this.viewRect.x-W,A,k),this.parentAxis.isInnerAxis?te=this.viewRect.y+this.viewRect.height-U:te=this.viewRect.y,te+=oe;break}case l.EAxisAlignment.Left:{te=X(this.viewRect.y-W,A,U),this.parentAxis.isInnerAxis?Y=this.viewRect.x:Y=this.viewRect.x+this.viewRect.width-k,Y-=oe;break}case l.EAxisAlignment.Right:{te=X(this.viewRect.y-W,A,U),this.parentAxis.isInnerAxis?Y=this.viewRect.x+this.viewRect.width-k:Y=this.viewRect.x,Y+=oe;break}}return x.drawTexture(H,Math.round(Y),Math.round(te),k,U),H.delete(),new a.Rect(Y,te,k,U)}},P.prototype.createAxisMarker=function(x,E,A,R,M){var D=A.fontStyle,F=A.fontWeight,I=A.fontSize,V=A.fontFamily,z=A.color;return this.textureManager.createAxisMarkerTexture(x,E,D,F,I,V,z,2*m.DpiHelper.PIXEL_RATIO,R,M)},P.prototype.createAxisMarkerFromImage=function(x,E,A){return this.textureManager.createTextureFromImage(x,E,A)},P.prototype.createAnnotationLabelTexture=function(x,E,A,R,M,D){return this.textureManager.createSimpleTextTexture(x,E,A,R,M,D)},P.prototype.invalidateParent=function(){this.parentAxis&&this.parentAxis.invalidateParentCallback&&this.parentAxis.invalidateParentCallback()},P.prototype.drawLabelViewRects=function(x,E,A){for(var R=(0,v.getVectorRectVertex)(this.webAssemblyContext),M=new this.webAssemblyContext.SCRTSolidBrush((0,f.parseColorToUIntArgb)("rgba(30,30,255,0.7)"),!1),D=0,F=A;D<F.length;D++){var I=F[D],V=(0,g.createNativeRect)(this.webAssemblyContext,I.left,I.top,I.right,I.bottom);R.push_back(V)}x.drawRects(R,M,this.getClipRect(),E.left,E.top),M.delete()},P.prototype.calculateLineHightForNativeFont=function(x,E){if(x&&E){x.CalculateStringBounds("Ag",E,0);var A=E.GetLineBounds(0),R=(0,h.getFirstLineHeightToBaseline)(A);return A.delete(),R}return 0},P})(r.DeletableEntity);t.AxisRenderer=S;var _=function(C,P,x,E,A,R,M){M===void 0&&(M=!1);for(var D=0,F=[],I=[],V=A.length,z=function(Re){return R?E[V-1-Re]:E[Re]},G=function(Re){return R?A[V-1-Re]:A[Re]},H=function(Re){return R?I.push(V-1-Re):I.push(Re)},U=0,k=0;k<V;k++){var X=k===0,W=k===V-1,Y=G(k),te=Math.ceil(Y/2),oe=z(k),de=0;if(C&&X){if(oe>te?(de=oe+te,oe=oe-te):(oe=0,de=oe+Y),!M){var ge=z(1),Ee=G(1)/2;if(P&&de>=ge-Ee-D)continue}}else C&&W?oe=oe+te<x?oe-te:x-Y:(de=oe+te,oe-=te);P&&k>0&&oe<U+D||(U=de,F.push(oe),H(k))}return{labelCoords:F,labelIndexes:I}};t.layoutLabelsHelper=_})(Z1)),Z1}var J1={},Yye;function tBe(){if(Yye)return J1;Yye=1;var t=J1&&J1.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(J1,"__esModule",{value:!0}),J1.AxisTitleRenderer=void 0;var e=pa(),i=kI(),n=eI(),r=Zz(),o=(function(l){t(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.lineSpacing=1.1,c}return u.prototype.measure=function(c,d,f){var h;c===void 0&&(c=""),this.text=c;var p=(h=d.useNativeText)!==null&&h!==void 0?h:this.useNativeText,g=!this.useCache||!this.texture&&!p||this.text!==this.previousText||this.lineSpacing!==this.previousLineSpacing||f!==this.previousAxisAlignment||this.previousNativeTextMode!==p||!a(d,this.textStyle);if(this.currentNativeFontName==="SCRT_Loading"){var v=(0,n.getIsHorizontalPlacement)(this.titlePosition),y=this.parentSurface.currentWebGlRenderContext,m=y.getFont(this.textStyle,!v);m.GetFaceName()!==this.currentNativeFontName&&(g=!0)}if(g){this.invalidateCache(),this.previousLineSpacing=this.lineSpacing,this.previousNativeTextMode=p,this.previousAxisAlignment=f,this.previousText=c,this.textStyle=d,this.titlePosition=n.ETitlePosition[f],this.textStyle=d,this.textStyle.lineSpacing=this.lineSpacing;var b=this.useNativeTextProperty;this.useNativeTextProperty=p;var y=this.parentSurface.currentWebGlRenderContext;this.getTextSize(c,this.textStyle,y),this.useNativeTextProperty=b}},Object.defineProperty(u.prototype,"useNativeText",{get:function(){return this.useNativeTextProperty},set:function(c){this.useNativeTextProperty=c},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"desiredHeight",{get:function(){return this.desiredHeightProperty},set:function(c){this.desiredWidthProperty!==c&&this.invalidateCache(),this.desiredHeightProperty=c},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"desiredWidth",{get:function(){return this.desiredWidthProperty},set:function(c){this.desiredWidthProperty!==c&&this.invalidateCache(),this.desiredWidthProperty=c},enumerable:!1,configurable:!0}),u.prototype.layout=function(c){if(!this.text){this.viewRectProperty=c;return}var d=s(this.textStyle.alignment);this.viewRectProperty=this.getViewRect(this.text,c,this.titlePosition,d)},u.prototype.getTitleTexture=function(){var c=this.titlePosition,d=(0,r.getAdjustedRotation)(this.textStyle.rotation,c),f=Array.isArray(this.text)?this.text:this.text.split(`
`),h=this.textureManager.createTextTexture(f,this.textStyle,d,this.lineSpacing);return h},u.prototype.draw=function(c){var d;this.drawDebug&&this.drawTitleDebugViewRect(c);var f=(d=this.textStyle.useNativeText)!==null&&d!==void 0?d:this.useNativeText;return this.drawInternal(c,f,this.titlePosition,this.parentSurface.clipRect)},u.prototype.delete=function(){this.parentSurface=void 0,l.prototype.delete.call(this)},u})(r.TitleRendererBase);J1.AxisTitleRenderer=o;var a=function(l,u){return!l||!u?!1:l.color===u.color&&l.fontFamily===u.fontFamily&&l.fontSize===u.fontSize&&l.fontStyle===u.fontStyle&&l.fontWeight===u.fontWeight&&l.alignment===u.alignment&&l.rotation===u.rotation&&l.multilineAlignment===u.multilineAlignment&&l.useNativeText===u.useNativeText&&(l.padding===void 0&&u.padding===void 0||e.Thickness.areEqual(l.padding,u.padding))},s=function(l){return l===i.ELabelAlignment.Auto?n.ETextAlignment.Center:n.ETextAlignment[l]};return J1}var qye;function Vv(){return qye||(qye=1,(function(t){var e=q1&&q1.__extends||(function(){var z=function(G,H){return z=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(U,k){U.__proto__=k}||function(U,k){for(var X in k)Object.prototype.hasOwnProperty.call(k,X)&&(U[X]=k[X])},z(G,H)};return function(G,H){if(typeof H!="function"&&H!==null)throw new TypeError("Class extends value "+String(H)+" is not a constructor or null");z(G,H);function U(){this.constructor=G}G.prototype=H===null?Object.create(H):(U.prototype=H.prototype,new U)}})(),i=q1&&q1.__assign||function(){return i=Object.assign||function(z){for(var G,H=1,U=arguments.length;H<U;H++){G=arguments[H];for(var k in G)Object.prototype.hasOwnProperty.call(G,k)&&(z[k]=G[k])}return z},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.AxisBase2D=t.EClipMode=void 0;var n=mo(),r=ad(),o=JV(),a=Br(),s=di(),l=pa(),u=od(),c=ga(),d=QD(),f=kI(),h=pl(),p=Vf(),g=Ti(),v=La(),y=Ls(),m=fFe(),b=Iu(),S=Xre(),_=QFe(),C=ZP(),P=jre(),x=an(),E=Sn(),A=Zi(),R=Kre(),M=Qz(),D=Zre(),F=tBe(),I=AW();(function(z){z.None="None",z.StretchAtExtents="StretchAtExtents",z.ClipAtMin="ClipAtMin",z.ClipAtMax="ClipAtMax",z.ClipAtExtents="ClipAtExtents"})(t.EClipMode||(t.EClipMode={}));var V=(function(z){e(G,z);function G(H,U){var k=this,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te;return k=z.call(this,U)||this,k.axisLayoutState=new M.AxisLayoutState,k.isPolarAxis=!1,k.getlabelStyleProxy=function(ke){return new Proxy(ke,{set:function($e,Ne,ve){return $e[Ne]=ve,k.notifyPropertyChanged(I.PROPERTY.TEXT_STYLE),k.dpiAdjustedLabelStyleCache=void 0,!0}})},k.labelStyleProperty=k.getlabelStyleProxy({fontSize:14,fontFamily:(0,p.getDefaultFontName)(),color:E.SciChartSurfaceBase.DEFAULT_THEME.tickTextBrush,fontWeight:"normal",fontStyle:"normal",padding:l.Thickness.fromString("2 4 2 4"),alignment:f.ELabelAlignment.Auto}),k.isInnerAxisProperty=!1,k.isPrimaryAxisProperty=!1,k.axisBorderProperty={borderBottom:0,borderLeft:0,borderRight:0,borderTop:0,color:E.SciChartSurfaceBase.DEFAULT_THEME.axisBorder,border:0},k.offsetProperty=0,k.offsetOverrideProperty=void 0,k.tickCache=void 0,k.clipToXRangeProperty=!0,k.isStaticAxisProperty=!1,k.webAssemblyContext2D=H,k.penCacheForMajorGridLines=new y.Pen2DCache(H),k.penCacheForMinorGridLines=new y.Pen2DCache(H),k.penCacheForMajorTickLines=new y.Pen2DCache(H),k.penCacheForMinorTickLines=new y.Pen2DCache(H),k.solidBrushCacheAxisBands=new m.SolidBrushCache(H),k.solidBrushCacheAxisBackground=new m.SolidBrushCache(H),k.axisRenderer=k.createAxisRender(),k.axisRenderer.keepLabelsWithinAxis=(X=U==null?void 0:U.keepLabelsWithinAxis)!==null&&X!==void 0?X:k.axisRenderer.keepLabelsWithinAxis,k.axisRenderer.hideOverlappingLabels=(W=U==null?void 0:U.hideOverlappingLabels)!==null&&W!==void 0?W:k.axisRenderer.hideOverlappingLabels,k.axisRenderer.axisThickness=(Y=U==null?void 0:U.axisThickness)!==null&&Y!==void 0?Y:k.axisRenderer.axisThickness,k.axisTitleRenderer=new F.AxisTitleRenderer(H),k.axisTitleRenderer.useNativeText=(te=U==null?void 0:U.useNativeText)!==null&&te!==void 0?te:k.axisTitleRenderer.useNativeText,k.isStaticAxis=(oe=U==null?void 0:U.isStaticAxis)!==null&&oe!==void 0?oe:k.isStaticAxisProperty,k.visibleRangeLimit=(de=s.NumberRange.hydrate(U==null?void 0:U.visibleRangeLimit))!==null&&de!==void 0?de:k.visibleRangeLimit,k.visibleRangeSizeLimit=(ge=s.NumberRange.hydrate(U==null?void 0:U.visibleRangeSizeLimit))!==null&&ge!==void 0?ge:k.visibleRangeSizeLimit,k.zoomExtentsRange=U!=null&&U.zoomExtentsToInitialRange?k.visibleRange:s.NumberRange.hydrate(U==null?void 0:U.zoomExtentsRange),k.axisAlignment=(Ee=U==null?void 0:U.axisAlignment)!==null&&Ee!==void 0?Ee:k.axisAlignment,k.axisTitle=(Re=U==null?void 0:U.axisTitle)!==null&&Re!==void 0?Re:k.axisTitle,k.labelStyle=k.getlabelStyleProxy(i(i({},k.labelStyle),U==null?void 0:U.labelStyle)),k.axisBorder=U==null?void 0:U.axisBorder,k.isInnerAxis=(Ae=U==null?void 0:U.isInnerAxis)!==null&&Ae!==void 0?Ae:k.isInnerAxis,k.stackedAxisLength=(Pe=U==null?void 0:U.stackedAxisLength)!==null&&Pe!==void 0?Pe:k.stackedAxisLength,k.solidBrushCacheBorder=new m.SolidBrushCache(H),U!=null&&U.labelProvider&&("getLabels"in(U==null?void 0:U.labelProvider)||(U.labelProvider=(0,n.createType)(c.EBaseType.LabelProvider,U.labelProvider.type,H,U.labelProvider.options))),k.autoRangeAnimationProperty=U==null?void 0:U.autoRangeAnimation,k.backgroundColor=(we=U==null?void 0:U.backgroundColor)!==null&&we!==void 0?we:k.backgroundColor,k.offsetOverrideProperty=U==null?void 0:U.overrideOffset,k.clipToXRangeProperty=(Te=U==null?void 0:U.clipToXRange)!==null&&Te!==void 0?Te:k.clipToXRange,k}return Object.defineProperty(G.prototype,"isLinearAxis",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"labelProvider",{get:function(){return this.labelProviderProperty},set:function(H){var U;(U=this.labelProviderProperty)===null||U===void 0||U.detachedFromAxis(),this.labelProviderProperty=H,this.notifyPropertyChanged(I.PROPERTY.LABEL_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"axisRenderer",{get:function(){return this.axisRendererProperty},set:function(H){this.axisRendererProperty=H,this.notifyPropertyChanged(I.PROPERTY.AXIS_RENDERER)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isHorizontalAxis",{get:function(){return(0,u.getIsHorizontal)(this.axisAlignment)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isAxisFlipped",{get:function(){return!this.isXAxis},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"axisAlignment",{get:function(){return this.axisAlignmentProperty},set:function(H){this.axisAlignmentProperty!==H&&(this.axisAlignmentProperty=H,this.notifyPropertyChanged(I.PROPERTY.AXIS_ALIGNMENT))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"visibleRangeLimit",{get:function(){return this.visibleRangeLimitProperty},set:function(H){s.NumberRange.areEqual(this.visibleRangeLimitProperty,H)||(this.visibleRangeLimitProperty=H,this.notifyPropertyChanged(I.PROPERTY.VISIBLE_RANGE_LIMIT))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"visibleRangeSizeLimit",{get:function(){return this.visibleRangeSizeLimitProperty},set:function(H){if(!s.NumberRange.areEqual(this.visibleRangeSizeLimitProperty,H)){if(H.min<0)throw Error("visibleRangeSizeLimit min value must be more or equal 0");if(H.min>=H.max)throw Error("visibleRangeSizeLimit min value must be less than max value");this.visibleRangeSizeLimitProperty=H,this.notifyPropertyChanged(I.PROPERTY.VISIBLE_RANGE_SIZE_LIMIT)}},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"zoomExtentsRange",{get:function(){return this.zoomExtentsRangeProperty},set:function(H){s.NumberRange.areEqual(this.zoomExtentsRangeProperty,H)||(this.zoomExtentsRangeProperty=H,this.notifyPropertyChanged(I.PROPERTY.ZOOMEXTENTS_RANGE))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isInnerAxis",{get:function(){return this.isInnerAxisProperty},set:function(H){this.isInnerAxisProperty!==H&&(this.isInnerAxisProperty=H,this.notifyPropertyChanged(I.PROPERTY.IS_INNER_AXIS))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isPrimaryAxis",{get:function(){return this.isPrimaryAxisProperty},set:function(H){var U=this;if(this.isPrimaryAxisProperty!==H&&(this.isPrimaryAxisProperty=H,this.notifyPropertyChanged(I.PROPERTY.IS_PRIMARY_AXIS)),H&&!this.isStackedAxis){var k=this.isXAxis?this.parentSurface.xAxes:this.parentSurface.yAxes;k.asArray().forEach(function(X){X!==U&&!X.isStackedAxis&&(X.isPrimaryAxis=!1)})}},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isStackedAxis",{get:function(){var H=this.parentSurface.layoutManager.getAxisLayoutStrategy(this);return H.isStacked},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"backgroundColor",{get:function(){return this.backgroundColorProperty},set:function(H){this.backgroundColorProperty=H,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"stackedAxisLength",{get:function(){return this.stackedAxisLengthProperty},set:function(H){this.stackedAxisLengthProperty!==H&&(this.stackedAxisLengthProperty=H,this.notifyPropertyChanged(I.PROPERTY.AXIS_LENGTH))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"axisLength",{get:function(){var H,U,k=this.parentSurface.seriesViewRect;if(!k)return(H=this.axisLengthProperty)!==null&&H!==void 0?H:0;var X=this.isHorizontalAxis?k.width:k.height;return(U=this.axisLengthProperty)!==null&&U!==void 0?U:X},set:function(H){this.axisLengthProperty!==H&&(this.axisLengthProperty=H,this.notifyPropertyChanged(I.PROPERTY.AXIS_LENGTH))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"axisThickness",{get:function(){return this.axisRenderer.axisThickness},set:function(H){this.axisRenderer.axisThickness!==H&&(this.axisLengthProperty=H,this.notifyPropertyChanged(I.PROPERTY.AXIS_THICKNESS))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"offset",{get:function(){var H;return(H=this.offsetOverrideProperty)!==null&&H!==void 0?H:this.offsetProperty},set:function(H){this.offsetProperty!==H&&(this.offsetProperty=H,this.offsetOverrideProperty===void 0&&(this.clearCoordCalcCache(),this.notifyPropertyChanged(I.PROPERTY.OFFSET)))},enumerable:!1,configurable:!0}),G.prototype.overrideOffset=function(H){this.offsetOverrideProperty!==H&&(this.offsetOverrideProperty=H,this.clearCoordCalcCache(),this.notifyPropertyChanged(I.PROPERTY.OFFSET))},Object.defineProperty(G.prototype,"isVerticalChart",{get:function(){return this.isXAxis?!![u.EAxisAlignment.Left,u.EAxisAlignment.Right].includes(this.axisAlignment):!![u.EAxisAlignment.Top,u.EAxisAlignment.Bottom].includes(this.axisAlignment)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"dpiAdjustedLabelStyle",{get:function(){return this.dpiAdjustedLabelStyleCache||(this.dpiAdjustedLabelStyleCache=A.DpiHelper.adjustTextStyle(this.labelStyleProperty)),this.dpiAdjustedLabelStyleCache},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"labelStyle",{get:function(){return this.labelStyleProperty},set:function(H){var U=i(i({},this.labelStyle),H);this.labelStyleProperty=this.getlabelStyleProxy(U),this.notifyPropertyChanged(I.PROPERTY.TEXT_STYLE),this.dpiAdjustedLabelStyleCache=void 0},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"axisBorder",{get:function(){return this.axisBorderProperty},set:function(H){var U,k,X,W,Y,te,oe,de,ge,Ee;this.axisBorder.borderTop=(k=(U=H==null?void 0:H.borderTop)!==null&&U!==void 0?U:H==null?void 0:H.border)!==null&&k!==void 0?k:this.axisBorder.borderTop,this.axisBorder.borderLeft=(W=(X=H==null?void 0:H.borderLeft)!==null&&X!==void 0?X:H==null?void 0:H.border)!==null&&W!==void 0?W:this.axisBorder.borderLeft,this.axisBorder.borderBottom=(te=(Y=H==null?void 0:H.borderBottom)!==null&&Y!==void 0?Y:H==null?void 0:H.border)!==null&&te!==void 0?te:this.axisBorder.borderBottom,this.axisBorder.borderRight=(de=(oe=H==null?void 0:H.borderRight)!==null&&oe!==void 0?oe:H==null?void 0:H.border)!==null&&de!==void 0?de:this.axisBorder.borderRight,this.axisBorder.border=(ge=H==null?void 0:H.border)!==null&&ge!==void 0?ge:this.axisBorder.border,this.axisBorder.color=(Ee=H==null?void 0:H.color)!==null&&Ee!==void 0?Ee:this.axisBorder.color,this.notifyPropertyChanged(I.PROPERTY.BORDER)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"autoRangeAnimation",{get:function(){return this.autoRangeAnimationProperty},set:function(H){this.autoRangeAnimationProperty=i(i({},this.autoRangeAnimation),H)},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"clipToXRange",{get:function(){return this.clipToXRangeProperty},set:function(H){this.clipToXRangeProperty!==H&&(this.clipToXRangeProperty=H,this.notifyPropertyChanged(I.PROPERTY.DRAW_ONLY_WITHIN_XRANGE))},enumerable:!1,configurable:!0}),Object.defineProperty(G.prototype,"isStaticAxis",{get:function(){return this.isStaticAxisProperty},set:function(H){this.isStaticAxisProperty=H,H?this.tickCoordinatesProvider=new _.StaticTickCoordinatesProvider:this.tickCoordinatesProvider=new S.DefaultTickCoordinatesProvider},enumerable:!1,configurable:!0}),G.prototype.applyTheme=function(H){var U=this.parentSurface.previousThemeProvider;this.axisBandsFill===U.axisBandsFill&&(this.axisBandsFill=H.axisBandsFill),this.labelStyle.color===U.tickTextBrush&&(this.labelStyle={color:H.tickTextBrush}),this.minorGridLineStyle.color===U.minorGridLineBrush&&(this.minorGridLineStyle={color:H.minorGridLineBrush}),this.majorGridLineStyle.color===U.majorGridLineBrush&&(this.majorGridLineStyle={color:H.majorGridLineBrush}),this.minorTickLineStyle.color===U.minorGridLineBrush&&(this.minorTickLineStyle={color:H.minorGridLineBrush}),this.majorTickLineStyle.color===U.majorGridLineBrush&&(this.majorTickLineStyle={color:H.majorGridLineBrush}),this.axisTitleStyle.color===U.axisTitleColor&&(this.axisTitleStyle={color:H.axisTitleColor})},G.prototype.setParentSurface=function(H){this.parentSurface=H,this.axisTitleRenderer.parentSurface=H},G.prototype.onAttach=function(H,U,k){this.setParentSurface(H),this.setIsXAxis(U),this.isPrimaryAxisProperty=k},G.prototype.onDetach=function(){this.removeLinksToAxis(),this.parentSurface=void 0,this.isPrimaryAxisProperty=!1,this.invalidateParentCallback=void 0},G.prototype.measure=function(){if(this.isVisible){var H=this.getTicks(!0).majorTickLabels,U=this.drawMinorTickLines||this.drawMajorTickLines;E.DebugForDpi&&console.log("Measure. fontSize: ".concat(this.labelStyle.fontSize,", dpiAdjusted: ").concat(this.dpiAdjustedLabelStyle.fontSize)),this.axisRenderer.measure(this.isHorizontalAxis,this.dpiAdjustedLabelStyle,H,this.getTicksMaxSize(),this.labelProvider,this.drawLabels,U),this.axisTitleRenderer.measure(this.axisTitle,this.dpiAdjustedAxisTitleStyle,this.axisAlignment)}else this.axisRenderer.desiredHeight=0,this.axisRenderer.desiredWidth=0,this.axisTitleRenderer.desiredHeight=0,this.axisTitleRenderer.desiredWidth=0;this.isMeasured=!0},G.prototype.onDpiChanged=function(){this.dpiAdjustedLabelStyleCache=void 0},G.prototype.prepareRenderData=function(){this.getCurrentCoordinateCalculator()},G.prototype.getCurrentCoordinateCalculator=function(){var H=z.prototype.getCurrentCoordinateCalculator.call(this);return H},G.prototype.draw=function(H){var U=this,k,X,W;if(this.getIsValidForDrawing()){var Y=this.parentSurface.clipRect,te=(0,b.calculateAbsoluteRenderLayer)(this.parentSurface.getSurfaceRenderOrder(),this.parentSurface.stepBetweenLayers,d.EDefaultRenderLayer.AxisBordersLayer);this.isPolarAxis||H.enqueueLayeredDraw(function(){var Ne,ve,pe,fe=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBorderStart,{contextId:U.id,parentContextId:(Ne=U.parentSurface)===null||Ne===void 0?void 0:Ne.id,level:v.EPerformanceDebugLevel.Verbose});(0,P.drawBorder)(H,U.webAssemblyContext2D,U.solidBrushCacheBorder,U.viewRect,Y,U.axisBorder.borderLeft||U.axisBorder.border,U.axisBorder.borderTop||U.axisBorder.border,U.axisBorder.borderRight||U.axisBorder.border,U.axisBorder.borderBottom||U.axisBorder.border,U.axisBorder.color),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBorderEnd,{contextId:U.id,parentContextId:(ve=U.parentSurface)===null||ve===void 0?void 0:ve.id,relatedId:(pe=fe==null?void 0:fe.detail)===null||pe===void 0?void 0:pe.relatedId,level:v.EPerformanceDebugLevel.Verbose})},te);var oe=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.GetTicksStart,{contextId:this.id,parentContextId:(k=this.parentSurface)===null||k===void 0?void 0:k.id,level:v.EPerformanceDebugLevel.Verbose}),de=this.getTicksWithCoords();v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.GetTicksEnd,{contextId:this.id,parentContextId:(X=this.parentSurface)===null||X===void 0?void 0:X.id,relatedId:(W=oe==null?void 0:oe.detail)===null||W===void 0?void 0:W.relatedId,level:v.EPerformanceDebugLevel.Verbose});var ge=this.minorGridLineStyle,Ee=this.majorGridLineStyle,Re=this.minorTickLineStyle,Ae=this.majorTickLineStyle,Pe=this.getPenForLines(this.penCacheForMinorGridLines,ge.color,ge.strokeThickness,ge.strokeDashArray),we=this.getPenForLines(this.penCacheForMajorGridLines,Ee.color,Ee.strokeThickness,Ee.strokeDashArray),Te=this.getPenForLines(this.penCacheForMinorTickLines,Re.color,Re.strokeThickness),ke=this.getPenForLines(this.penCacheForMajorTickLines,Ae.color,Ae.strokeThickness);this.isPrimaryAxis&&this.drawAxisBandsAndGridLines(H,de,Pe,we);var $e=(0,b.calculateAbsoluteRenderLayer)(this.parentSurface.getSurfaceRenderOrder(),this.parentSurface.stepBetweenLayers,d.EDefaultRenderLayer.AxesLayer);H.enqueueLayeredDraw(function(){var Ne,ve,pe,fe,me,Ce,Ue,Qe,it,xt,wt,$t;if(U.backgroundColorProperty){var Mt=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBackgroundStart,{contextId:U.id,parentContextId:(Ne=U.parentSurface)===null||Ne===void 0?void 0:Ne.id,level:v.EPerformanceDebugLevel.Verbose});U.axisRenderer.viewRect,U.axisTitleRenderer.viewRect;var rt=U.solidBrushCacheAxisBackground.newBrush(U.backgroundColorProperty,!1),qe=void 0;if(qe=(0,C.createNativeRect)(U.webAssemblyContext2D,0,0,U.viewRect.width,U.viewRect.height),qe){var vt=(0,x.getVectorRectVertex)(U.webAssemblyContext2D);vt.push_back(qe),H.drawRects(vt,rt,Y,U.viewRect.x,U.viewRect.y)}v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBackgroundEnd,{contextId:U.id,parentContextId:(ve=U.parentSurface)===null||ve===void 0?void 0:ve.id,relatedId:(pe=Mt==null?void 0:Mt.detail)===null||pe===void 0?void 0:pe.relatedId,level:v.EPerformanceDebugLevel.Verbose})}if(U.drawLabels){E.DebugForDpi&&console.log("Draw. fontSize: ".concat(U.labelStyle.fontSize,", dpiAdjusted: ").concat(U.dpiAdjustedLabelStyle.fontSize));var Mt=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisLabelsStart,{contextId:U.id,parentContextId:(fe=U.parentSurface)===null||fe===void 0?void 0:fe.id,level:v.EPerformanceDebugLevel.Verbose});U.axisRenderer.drawLabels(H,U.axisAlignment,U.isInnerAxis,de.majorTickLabels,de.majorTickCoords,U.offset,U.dpiAdjustedLabelStyle,U.isVerticalChart,U.flippedCoordinates,U.labelProvider),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisLabelsEnd,{contextId:U.id,parentContextId:(me=U.parentSurface)===null||me===void 0?void 0:me.id,relatedId:(Ce=Mt==null?void 0:Mt.detail)===null||Ce===void 0?void 0:Ce.relatedId,level:v.EPerformanceDebugLevel.Verbose})}if(U.drawMinorTickLines){var Mt=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMinorTicksStart,{contextId:U.id,parentContextId:(Ue=U.parentSurface)===null||Ue===void 0?void 0:Ue.id,level:v.EPerformanceDebugLevel.Verbose});U.axisRenderer.drawTicks(H,U.axisAlignment,U.isInnerAxis,de.minorTickCoords,U.offset,Te,Re),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMinorTicksEnd,{contextId:U.id,parentContextId:(Qe=U.parentSurface)===null||Qe===void 0?void 0:Qe.id,relatedId:(it=Mt==null?void 0:Mt.detail)===null||it===void 0?void 0:it.relatedId,level:v.EPerformanceDebugLevel.Verbose})}if(U.drawMajorTickLines){var Mt=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMajorTicksStart,{contextId:U.id,parentContextId:(xt=U.parentSurface)===null||xt===void 0?void 0:xt.id,level:v.EPerformanceDebugLevel.Verbose});U.axisRenderer.drawTicks(H,U.axisAlignment,U.isInnerAxis,de.majorTickCoords,U.offset,ke,Ae),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMajorTicksEnd,{contextId:U.id,parentContextId:(wt=U.parentSurface)===null||wt===void 0?void 0:wt.id,relatedId:($t=Mt==null?void 0:Mt.detail)===null||$t===void 0?void 0:$t.relatedId,level:v.EPerformanceDebugLevel.Verbose})}U.axisTitleRenderer.draw(H),U.labelProvider.useNativeText&&U.parentSurface.renderNativeAxisLabelsImmediately&&(H.resetAndClip(Y),H.endFonts(!0))},$e)}},G.prototype.drawDebug=function(H){var U=this;this.axisRenderer.drawDebug=!0;var k=this.parentSurface.chartViewRect,X=function(){var Y=U.axisRenderer.viewRect,te=(0,x.getVectorRectVertex)(U.webAssemblyContext2D),oe=new U.webAssemblyContext2D.SCRTSolidBrush((0,g.parseColorToUIntArgb)("rgba(255,0,0,0.3)"),!1),de=(0,C.createNativeRect)(U.webAssemblyContext2D,0,0,Y.width,Y.height);te.push_back(de),H.drawRects(te,oe,k,Y.left,Y.top),oe.delete()};X();var W=function(){var Y=U.axisTitleRenderer.viewRect,te=(0,x.getVectorRectVertex)(U.webAssemblyContext2D),oe=new U.webAssemblyContext2D.SCRTSolidBrush((0,g.parseColorToUIntArgb)("rgba(0,255,0,0.7)"),!1),de=(0,C.createNativeRect)(U.webAssemblyContext2D,0,0,Y.width,Y.height);te.push_back(de),H.drawRects(te,oe,k,Y.left,Y.top),oe.delete()};W()},G.prototype.getDefaultNonZeroRange=function(){return new s.NumberRange(0,10)},G.prototype.getMaximumRange=function(){if(this.zoomExtentsRange)return this.zoomExtentsRange;var H;this.parentSurface&&this.parentSurface.renderableSeries.size()>0&&(H=this.isXAxis?this.getMaxXRange():this.getWindowedYRange(void 0));var U=this.visibleRange||this.getDefaultNonZeroRange();return H||U},G.prototype.getWindowedYRange=function(H){var U=this;if(this.zoomExtentsRange)return this.zoomExtentsRange;var k;return this.parentSurface&&this.getVisibleRenderableSeriesByYAxis().forEach(function(X){var W=X.xAxisId,Y=H!=null&&H.containsKey(W)?H.item(W):U.getXVisibleRange(W),te=U.getIsXCategoryAxis(W);if(Y){var oe=X.getYRange(Y,te);oe&&(k=k?k.union(oe):oe)}}),k!=null&&k.isZero()&&(k=this.coerceZeroVisibleRange(k)),this.growBy&&k&&(k=k.growBy(this.growBy)),k=this.applyVisibleRangeLimit(k),k=this.applyVisibleRangeSizeLimit(k),k||new s.NumberRange},G.prototype.scroll=function(H,U){var k=this.visibleRange;if(k===void 0)return!1;var X=this.getCurrentCoordinateCalculator().translateBy(H,k);if(this.visibleRangeLimit){var W=0;X.min<this.visibleRangeLimit.min?W=this.visibleRangeLimit.min-X.min:this.visibleRangeLimit.max<X.max&&(W=this.visibleRangeLimit.max-X.max),W&&(X=new s.NumberRange(X.min+W,X.max+W))}return this.visibleRange=this.applyVisibleRangeSizeLimit(X),!0},G.prototype.setVisibleRangeWithLimits=function(H){var U=this.applyVisibleRangeLimit(H);this.visibleRange=this.applyVisibleRangeSizeLimit(U)},G.prototype.zoomBy=function(H,U){var k=this.getCurrentCoordinateCalculator(),X=k.zoomTranslateBy(H,U,this.visibleRange);if(!(X.max<X.min)){var W=this.applyVisibleRangeLimit(X);this.visibleRange=this.applyVisibleRangeSizeLimit(W)}},G.prototype.zoom=function(H,U,k,X){k===void 0&&(k=0),X===void 0&&(X=r.easing.outExpo);var W=this.getCurrentCoordinateCalculator(),Y=W.getDataValue(H),te=W.getDataValue(U),oe=Y<te?Y:te,de=Y<te?te:Y,ge=this.applyVisibleRangeLimit(new s.NumberRange(oe,de)),Ee=this.applyVisibleRangeSizeLimit(ge);this.animateVisibleRange(Ee,k,X)},G.prototype.scale=function(H,U,k){var X=H.max-H.min,W,Y,te=this.flippedCoordinates?!k:k,oe=this.flippedCoordinates?-U:U;te?(W=H.min,Y=oe>0?W+X/(1+oe):W+X*(1+Math.abs(oe))):(Y=H.max,W=oe>0?Y-X*(1+oe):Y-X/(1+Math.abs(oe)));var de=this.applyVisibleRangeLimit(new s.NumberRange(W,Y));this.visibleRange=this.applyVisibleRangeSizeLimit(de)},G.prototype.animateVisibleRange=function(H,U,k,X){var W=this,Y;if(k===void 0&&(k=r.easing.outCubic),X===void 0&&(X=function(){}),U<=0){this.visibleRange=H||this.visibleRange,X();return}return(Y=this.visibleRangeAnimationToken)===null||Y===void 0||Y.cancel(),this.visibleRangeAnimationToken=o.NumberRangeAnimator.animate(this.visibleRange,H,U,function(te){W.visibleRange=te},function(){W.visibleRangeAnimationToken=void 0,X()},k),this.parentSurface.addAnimation(this.visibleRangeAnimationToken),this.visibleRangeAnimationToken},G.prototype.getVisibleRenderableSeriesByXAxis=function(){var H=this;return this.parentSurface?this.parentSurface.renderableSeries.asArray().filter(function(U){return U.xAxis===H&&U.isVisible&&U.hasDataSeriesValues()}):[]},G.prototype.getVisibleRenderableSeriesByYAxis=function(){var H=this;if(!this.parentSurface)return[];var U=this.parentSurface.renderableSeries.asArray();return U.filter(function(k){return k.linkAxes(),k.yAxis===H&&k.isVisible&&k.hasDataSeriesValues()})},G.prototype.delete=function(){this.penCacheForMajorGridLines=(0,a.deleteSafe)(this.penCacheForMajorGridLines),this.penCacheForMinorGridLines=(0,a.deleteSafe)(this.penCacheForMinorGridLines),this.penCacheForMajorTickLines=(0,a.deleteSafe)(this.penCacheForMajorTickLines),this.penCacheForMinorTickLines=(0,a.deleteSafe)(this.penCacheForMinorTickLines),this.solidBrushCacheBorder=(0,a.deleteSafe)(this.solidBrushCacheBorder),this.solidBrushCacheAxisBands=(0,a.deleteSafe)(this.solidBrushCacheAxisBands),this.solidBrushCacheAxisBackground=(0,a.deleteSafe)(this.solidBrushCacheAxisBackground),this.axisRendererProperty=(0,a.deleteSafe)(this.axisRenderer),this.axisTitleRenderer=(0,a.deleteSafe)(this.axisTitleRenderer),this.webAssemblyContext2D=void 0,this.parentSurface=void 0,z.prototype.delete.call(this)},G.prototype.toJSON=function(){var H=this.labelProvider.toJSON(),U={autoRange:this.autoRange,autoTicks:this.autoTicks,axisAlignment:this.axisAlignment,axisBandsFill:this.axisBandsFill,axisBorder:this.axisBorder,axisTitle:this.axisTitle,axisTitleStyle:this.axisTitleStyle,drawLabels:this.drawLabels,drawMajorBands:this.drawMajorBands,drawMajorGridLines:this.drawMajorGridLines,drawMajorTickLines:this.drawMajorTickLines,drawMinorGridLines:this.drawMinorGridLines,drawMinorTickLines:this.drawMinorTickLines,flippedCoordinates:this.flippedCoordinates,growBy:this.growBy,id:this.id,isInnerAxis:this.isInnerAxis,isVisible:this.isVisible,labelStyle:this.labelStyle,majorGridLineStyle:this.majorGridLineStyle,majorTickLineStyle:this.majorTickLineStyle,maxAutoTicks:this.maxAutoTicks,minorGridLineStyle:this.minorGridLineStyle,minorTickLineStyle:this.minorTickLineStyle,visibleRange:this.hasDefaultVisibleRange()?void 0:this.visibleRange,visibleRangeLimit:this.visibleRangeLimit,zoomExtentsRange:this.zoomExtentsRange,minorsPerMajor:this.minorsPerMajor,majorDelta:this.majorDelta,minorDelta:this.minorDelta,labelProvider:H,keepLabelsWithinAxis:this.axisRenderer.keepLabelsWithinAxis,clipToXRange:this.clipToXRange,isStaticAxis:this.isStaticAxis,stackedAxisLength:this.stackedAxisLength,axisThickness:this.axisThickness,autoRangeAnimation:this.autoRangeAnimation,visibleRangeSizeLimit:this.visibleRangeSizeLimit,hideOverlappingLabels:this.axisRenderer.hideOverlappingLabels,backgroundColor:this.backgroundColor,overrideOffset:this.offsetOverrideProperty,allowFastMath:this.allowFastMath};return{type:this.type,options:U}},G.prototype.createAxisRender=function(){return new D.AxisRenderer(this.webAssemblyContext2D)},G.prototype.getTicksMaxSize=function(){var H,U,k=!((H=this.majorTickLineStyle)===null||H===void 0)&&H.tickSize?this.majorTickLineStyle.tickSize*A.DpiHelper.PIXEL_RATIO:0,X=!((U=this.minorTickLineStyle)===null||U===void 0)&&U.tickSize?this.minorTickLineStyle.tickSize*A.DpiHelper.PIXEL_RATIO:0;return Math.max(k,X)},G.prototype.getIsValidForDrawing=function(){return this.isVisible},G.prototype.drawAxisBandsAndGridLines=function(H,U,k,X){var W=this;if(this.drawMajorBands){var Y=this.solidBrushCacheAxisBands.newBrush(this.axisBandsFill,!0),te=(0,b.calculateAbsoluteRenderLayer)(this.parentSurface.getSurfaceRenderOrder(),this.parentSurface.stepBetweenLayers,d.EDefaultRenderLayer.AxisBandsLayer);H.enqueueLayeredDraw(function(){var ge,Ee,Re,Ae=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBandsStart,{contextId:W.id,parentContextId:(ge=W.parentSurface)===null||ge===void 0?void 0:ge.id,level:v.EPerformanceDebugLevel.Verbose});W.drawAxisBands(H,U.majorTicks,U.majorTickCoords,Y),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawAxisBandsEnd,{contextId:W.id,parentContextId:(Ee=W.parentSurface)===null||Ee===void 0?void 0:Ee.id,relatedId:(Re=Ae==null?void 0:Ae.detail)===null||Re===void 0?void 0:Re.relatedId,level:v.EPerformanceDebugLevel.Verbose})},te)}if(this.drawMinorGridLines){var oe=(0,b.calculateAbsoluteRenderLayer)(this.parentSurface.getSurfaceRenderOrder(),this.parentSurface.stepBetweenLayers,d.EDefaultRenderLayer.MinorGridLinesLayer);H.enqueueLayeredDraw(function(){var ge,Ee,Re,Ae=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMinorGridLinesStart,{contextId:W.id,parentContextId:(ge=W.parentSurface)===null||ge===void 0?void 0:ge.id,level:v.EPerformanceDebugLevel.Verbose});W.drawGridLines(H,U.minorTickCoords,k,!1),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMinorGridLinesEnd,{contextId:W.id,parentContextId:(Ee=W.parentSurface)===null||Ee===void 0?void 0:Ee.id,relatedId:(Re=Ae==null?void 0:Ae.detail)===null||Re===void 0?void 0:Re.relatedId,level:v.EPerformanceDebugLevel.Verbose})},oe)}if(this.drawMajorGridLines){var de=(0,b.calculateAbsoluteRenderLayer)(this.parentSurface.getSurfaceRenderOrder(),this.parentSurface.stepBetweenLayers,d.EDefaultRenderLayer.MajorGridLinesLayer);H.enqueueLayeredDraw(function(){var ge,Ee,Re,Ae=v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMajorGridLinesStart,{contextId:W.id,parentContextId:(ge=W.parentSurface)===null||ge===void 0?void 0:ge.id,level:v.EPerformanceDebugLevel.Verbose});W.drawGridLines(H,U.majorTickCoords,X,!0),v.PerformanceDebugHelper.mark(v.EPerformanceMarkType.DrawMajorGridLinesEnd,{contextId:W.id,parentContextId:(Ee=W.parentSurface)===null||Ee===void 0?void 0:Ee.id,relatedId:(Re=Ae==null?void 0:Ae.detail)===null||Re===void 0?void 0:Re.relatedId,level:v.EPerformanceDebugLevel.Verbose})},de)}},G.prototype.drawAxisBands=function(H,U,k,X){var W=this;if(!(!U||U.length===0)){var Y=this.parentSurface.seriesViewRect,te=this.isHorizontalAxis?h.EXyDirection.XDirection:h.EXyDirection.YDirection,oe=this.offset,de=this.axisLength+this.offset,ge=this.isAxisFlipped!==this.flippedCoordinates;if(ge){var Ee=de;de=oe,oe=Ee}var Re=this.getMajorTickIndex(U[0]),Ae=Re%2===0,Pe=(0,x.getVectorRectVertex)(this.webAssemblyContext2D),we=function(Te,ke,$e){if($e){var Ne=(0,C.createNativeRect)(W.webAssemblyContext2D,te===h.EXyDirection.YDirection?0:Te,te===h.EXyDirection.YDirection?Te:0,te===h.EXyDirection.YDirection?Y.width:ke,te===h.EXyDirection.YDirection?ke:Y.height);Pe.push_back(Ne)}};U.forEach(function(Te,ke){var $e=ke===0?oe:k[ke-1],Ne=k[ke];we($e,Ne,Ae),Ae=!Ae}),we(de,k[U.length-1],Ae),H.drawRects(Pe,X,this.parentSurface.clipRect,Y.left,Y.top)}},G.prototype.drawGridLines=function(H,U,k,X){var W=this;if(!(!U||U.length===0)){var Y=this.parentSurface.seriesViewRect,te=(0,x.getVectorColorVertex)(this.webAssemblyContext2D),oe=(0,x.getVertex)(this.webAssemblyContext2D,0,0);U.forEach(function(de){var ge=W.isHorizontalAxis?de:0,Ee=W.isHorizontalAxis?de:Y.width,Re=W.isHorizontalAxis?0:de,Ae=W.isHorizontalAxis?Y.height:de;oe.SetPosition(ge,Re),te.push_back(oe),oe.SetPosition(Ee,Ae),te.push_back(oe)}),H.drawLinesNative(te,k,b.ELineDrawMode.DiscontinuousLine,this.parentSurface.clipRect,Y.left,Y.top)}},G.prototype.getXVisibleRange=function(H){return this.parentSurface.getXAxisById(H).visibleRange},G.prototype.getIsXCategoryAxis=function(H){return this.parentSurface.getXAxisById(H).isCategoryAxis},G.prototype.getLabels=function(H){return this.labelProvider.getLabels(H)},G.prototype.getXDataRange=function(){var H;return this.parentSurface&&this.getVisibleRenderableSeriesByXAxis().forEach(function(U){var k=U.getXRange();k&&(H=H?H.union(k):k)}),H},G.prototype.notifyPropertyChanged=function(H){H===I.PROPERTY.IS_XAXIS&&this.axisAlignmentProperty===void 0&&(this.axisAlignmentProperty=this.isXAxisProperty?u.EAxisAlignment.Bottom:u.EAxisAlignment.Right),H===I.PROPERTY.AXIS_RENDERER&&this.axisRendererProperty.attachedToAxis(this),z.prototype.notifyPropertyChanged.call(this,H)},G.prototype.getMaxXRange=function(){var H=this.getXDataRange();if(H)return this.growBy&&(H=H.growBy(this.growBy)),H=this.applyVisibleRangeLimit(H??this.visibleRange),H=this.applyVisibleRangeSizeLimit(H),H},G.prototype.removeLinksToAxis=function(){var H=this,U=this.parentSurface;U&&(this.isXAxis?(U.renderableSeries.asArray().forEach(function(k){k.xAxisId===H.id&&(k.xAxisId=void 0)}),U.annotations.asArray().forEach(function(k){k.xAxisId===H.id&&(k.xAxisId=void 0)}),U.chartModifiers.asArray().forEach(function(k){var X=k;X.xAxisId===H.id&&(X.xAxisId=void 0),X.includedXAxes.removeId(H.id)})):(U.renderableSeries.asArray().forEach(function(k){k.yAxisId===H.id&&(k.yAxisId=void 0)}),U.annotations.asArray().forEach(function(k){k.yAxisId===H.id&&(k.yAxisId=void 0)}),U.chartModifiers.asArray().forEach(function(k){var X=k;X.yAxisId===H.id&&(X.yAxisId=void 0),X.includedYAxes.removeId(H.id)})))},G.prototype.getAxisSize=function(){return this.axisLength},G.prototype.getMajorTickIndex=function(H){var U=this.majorDeltaProperty,k=H/U;return Math.round(k)},G.prototype.getTicks=function(H){var U,k;if(H||!this.tickCache){var X=this.getMaxAutoTicks();if(this.autoTicks){var W=this.deltaCalculator.getDeltaFromRange(this.visibleRange.min,this.visibleRange.max,this.minorsPerMajor,X);this.minorDeltaProperty=W.min,this.majorDeltaProperty=W.max}var Y=this.tickCoordinatesProvider.getTickCoordinates(void 0,void 0),te=Y.majorTickCoords,oe=Y.minorTickCoords,de=Y.majorTickOverrides,ge=Y.minorTickOverRides,Ee=this.drawLabels||this.drawMajorGridLines||this.drawMajorTickLines?de??this.tickProvider.getMajorTicks((U=this.minorDeltaProperty)!==null&&U!==void 0?U:this.majorDeltaProperty/this.minorsPerMajor,this.majorDeltaProperty,this.visibleRange,this.getCurrentCoordinateCalculator()):[],Re=this.drawMinorGridLines||this.drawMinorTickLines?ge??this.tickProvider.getMinorTicks((k=this.minorDeltaProperty)!==null&&k!==void 0?k:this.majorDeltaProperty/this.minorsPerMajor,this.majorDeltaProperty,this.visibleRange,this.getCurrentCoordinateCalculator()):[],Ae=this.visibleRange,Pe=Ae.min,we=Ae.max;Ee=Ee.filter(function(ke){return ke>=Pe&&ke<=we}),Re=Re.filter(function(ke){return ke>=Pe&&ke<=we});var Te=[];Ee.length>1e3&&this.drawLabels?console.warn("Axis settings result in more than 1000 labels.  Label drawing is disabled.  If using autoTicks: false, check that you have set sensible deltas."):Te=this.drawLabels?this.getLabels(Ee):[],this.tickCache={majorTicks:Ee,majorTickLabels:Te,majorTickCoords:te,minorTicks:Re,minorTickCoords:oe}}return this.tickCache},G.prototype.getTicksWithCoords=function(){if(this.tickCache||this.getTicks(!0),this.tickCache.majorTickCoords===void 0){var H=this.tickCoordinatesProvider.getTickCoordinates(this.tickCache.majorTicks,this.tickCache.minorTicks),U=H.majorTickCoords,k=H.minorTickCoords;this.tickCache.majorTickCoords=U,this.tickCache.minorTickCoords=k}return this.tickCache},G.prototype.getPenForLines=function(H,U,k,X){return(0,y.createPenInCache)(H,U,k,1,X,!1)},G.prototype.applyVisibleRangeLimit=function(H){if(H){if(!this.visibleRangeLimit)return H;var U=H.clip(this.visibleRangeLimit);return U.min>=U.max?(console.warn("Can not apply visibleRangeLimit for the ".concat(this.isXAxis?"xAxis":"yAxis"," with ID ").concat(this.id)),H):U}},G.prototype.applyVisibleRangeSizeLimit=function(H){if(H){var U=Math.abs(H.min)/Math.pow(10,14),k=H.diff;if(k<U){var X=H.min+k/2;return new s.NumberRange(X-U/2,X+U/2)}if(!this.visibleRangeSizeLimit)return H;if(k<0)return console.warn("Can not apply visibleRangeSizeLimit for the ".concat(this.isXAxis?"xAxis":"yAxis"," with ID ").concat(this.id)),H;var W=H,Y=this.visibleRangeSizeLimit,te=Y.min,oe=Y.max,X=H.min+k/2;return k<te?W=new s.NumberRange(X-te/2,X+te/2):k>oe&&(W=new s.NumberRange(X-oe/2,X+oe/2)),W}},G})(R.AxisCore);t.AxisBase2D=V})(q1)),q1}var Q1={},ex={},LF={},Xye;function OW(){if(Xye)return LF;Xye=1,Object.defineProperty(LF,"__esModule",{value:!0}),LF.DeltaCalculator=void 0;var t=(function(){function e(){}return e.prototype.attachedToAxis=function(i){this.parentAxis=i},e.prototype.detachedFromAxis=function(){this.parentAxis=void 0},e})();return LF.DeltaCalculator=t,LF}var Kye;function aR(){if(Kye)return ex;Kye=1;var t=ex&&ex.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(ex,"__esModule",{value:!0}),ex.NumericDeltaCalculator=void 0;var e=ci(),i=di(),n=OW(),r=(function(o){t(a,o);function a(s){var l=o.call(this)||this;return l.webAssemblyContext=s,l}return a.prototype.getDeltaFromRange=function(s,l,u,c){e.Guard.argumentIsRealNumber(s,"min"),e.Guard.argumentIsRealNumber(l,"max");var d=this.webAssemblyContext.NiceDoubleScale.CalculateTickSpacing(s,l,u,c),f=new i.NumberRange(d.minD,d.maxD);return d.delete(),f},a})(n.DeltaCalculator);return ex.NumericDeltaCalculator=r,ex}var Zye;function Jre(){if(Zye)return Q1;Zye=1;var t=Q1&&Q1.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Q1,"__esModule",{value:!0}),Q1.CategoryDeltaCalculator=void 0;var e=ci(),i=di(),n=aR(),r=(function(o){t(a,o);function a(s){return o.call(this,s)||this}return a.prototype.getDeltaFromRange=function(s,l,u,c){return e.Guard.argumentIsRealNumber(s,"min"),e.Guard.argumentIsRealNumber(l,"max"),l<=c?new i.NumberRange(1/u,1):o.prototype.getDeltaFromRange.call(this,s,l,u,c)},a})(n.NumericDeltaCalculator);return Q1.CategoryDeltaCalculator=r,Q1}var Jye;function rBe(){if(Jye)return z1;Jye=1;var t=z1&&z1.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(z1,"__esModule",{value:!0}),z1.CategoryAxisBase=void 0;var e=Br(),i=di(),n=hn(),r=Rf(),o=ZFe(),a=JFe(),s=oR(),l=Vv(),u=Jre(),c=(function(d){t(f,d);function f(h,p){var g=this,v,y,m;return g=d.call(this,h,p)||this,g.defaultXValuesProperty=[],g.defaultXStartProperty=0,g.defaultXStepProperty=1,g.defaultXValuesProperty=(v=p==null?void 0:p.defaultXValues)!==null&&v!==void 0?v:g.defaultXValuesProperty,g.defaultXStartProperty=(y=p==null?void 0:p.defaultXStart)!==null&&y!==void 0?y:g.defaultXStartProperty,g.defaultXStepProperty=(m=p==null?void 0:p.defaultXStep)!==null&&m!==void 0?m:g.defaultXStepProperty,g.tickProvider=new s.NumericTickProvider(g.webAssemblyContext2D),g.deltaCalculator=new u.CategoryDeltaCalculator(g.webAssemblyContext2D),g.defaultBaseXValues=new g.webAssemblyContext2D.SCRTDoubleVector,g}return Object.defineProperty(f.prototype,"isCategoryAxis",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXValues",{get:function(){return this.defaultXValuesProperty},set:function(h){this.defaultXValuesProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXStart",{get:function(){return this.defaultXStartProperty},set:function(h){this.defaultXStartProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXStep",{get:function(){return this.defaultXStepProperty},set:function(h){this.defaultXStepProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),f.prototype.prepareRenderData=function(){(0,e.deleteSafe)(this.coordCalcCache);var h=this.getCurrentCoordinateCalculatorInternal();this.coordCalcCache=h},f.prototype.delete=function(){this.defaultBaseXValues=(0,e.deleteSafe)(this.defaultBaseXValues),d.prototype.delete.call(this)},f.prototype.getCurrentCoordinateCalculatorInternal=function(){var h=this.visibleRange.min,p=this.visibleRange.max,g=this.axisLength,v=this.isXAxis!==this.flippedCoordinates?new o.CategoryCoordinateCalculator(this.webAssemblyContext2D,g,h,p,this.offset):new a.FlippedCategoryCoordinateCalculator(this.webAssemblyContext2D,g,h,p,this.offset);return this.updateBaseXValues(v),v},f.prototype.getXDataRange=function(){var h;return this.parentSurface&&this.getVisibleRenderableSeriesByXAxis().forEach(function(p){var g=p.getDataSeriesValuesCount(),v=1/2,y=new i.NumberRange(0-v,g-1+v);y&&(h=h?h.union(y):y)}),h},f.prototype.getMaxAutoTicks=function(){var h=this.getCurrentCoordinateCalculator();return Math.min(Math.max(1,this.maxAutoTicks),h.baseXValues.size())},f.prototype.generateDefaultXValuesForCategoryAxis=function(h,p){if(this.defaultBaseXValues.clear(),this.defaultXValues&&this.defaultXValues.length>0)(0,r.appendDoubleVectorFromJsArray)(this.webAssemblyContext2D,this.defaultBaseXValues,this.defaultXValues);else{for(var g=[],v=10,y=0;y<v;y++)g.push(h+y*p);(0,r.appendDoubleVectorFromJsArray)(this.webAssemblyContext2D,this.defaultBaseXValues,g)}return this.defaultBaseXValues},f.prototype.updateBaseXValues=function(h){var p=this,g=this.parentSurface,v=g.renderableSeries.asArray().find(function(C){return C.xAxisId===p.id});if((v==null?void 0:v.type)===n.ESeriesType.UniformHeatmapSeries)throw Error("Category Axis is not supported for UniformHeatmapRenderableSeries");if(v!=null&&v.isCollection){var y=v;if(y.size()===0)throw Error("BaseStackedCollection should have at least one BaseStackedRenderableSeries");var m=y.get(0);if(!(m!=null&&m.dataSeries)){h.baseXValues||(h.baseXValues=this.generateDefaultXValuesForCategoryAxis(this.defaultXStart,this.defaultXStep));return}h.baseXValues=m.dataSeries.getNativeXValues()}else{if(!(v!=null&&v.dataSeries)||v.dataSeries.count()<10){var b=this.defaultXStart,S=this.defaultXStep;if(v!=null&&v.dataSeries&&(v==null?void 0:v.dataSeries.count())>0){var _=v.dataSeries.getNativeXValues();b=_.get(0),v.dataSeries.count()>0&&(S=_.get(1)-_.get(0))}h.baseXValues||(h.baseXValues=this.generateDefaultXValuesForCategoryAxis(b,S));return}h.baseXValues=v.dataSeries.getNativeXValues()}},f})(l.AxisBase2D);return z1.CategoryAxisBase=c,z1}var q0={},R9={},Qye;function sR(){return Qye||(Qye=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ELabelProviderType=void 0,(function(e){e.Numeric="Numeric",e.Logarithmic="Logarithmic",e.Date="Date",e.SmartDate="SmartDate",e.Text="Text",e.Pie="Pie"})(t.ELabelProviderType||(t.ELabelProviderType={}))})(R9)),R9}var Sf={},tx={},eme;function Qre(){if(eme)return tx;eme=1;var t=tx&&tx.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(tx,"__esModule",{value:!0}),tx.LabelProvider=void 0;var e=fo(),i=(function(n){t(r,n);function r(o){var a=n.call(this)||this;return a.numericFormatProperty=o==null?void 0:o.labelFormat,a.precisionProperty=o==null?void 0:o.labelPrecision,a.cursorNumericFormatProperty=o==null?void 0:o.cursorLabelFormat,a.cursorPrecisionProperty=o==null?void 0:o.cursorLabelPrecision,a.prefixProperty=o==null?void 0:o.labelPrefix,a.postfixProperty=o==null?void 0:o.labelPostfix,a}return r.prototype.attachedToAxis=function(o){this.parentAxis=o},r.prototype.detachedFromAxis=function(){this.parentAxis=void 0},Object.defineProperty(r.prototype,"numericFormat",{get:function(){return this.numericFormatProperty},set:function(o){this.numericFormatProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"precision",{get:function(){return this.precisionProperty},set:function(o){this.precisionProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"cursorNumericFormat",{get:function(){return this.cursorNumericFormatProperty},set:function(o){this.cursorNumericFormatProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"cursorPrecision",{get:function(){return this.cursorPrecisionProperty},set:function(o){this.cursorPrecisionProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"prefix",{get:function(){return this.prefixProperty},set:function(o){this.prefixProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"postfix",{get:function(){return this.postfixProperty},set:function(o){this.postfixProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formatLabel",{get:function(){return this.formatLabelProperty},set:function(o){this.formatLabelProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"formatCursorLabel",{get:function(){return this.formatCursorLabelProperty},set:function(o){this.formatCursorLabelProperty=o,this.invalidateParent()},enumerable:!1,configurable:!0}),r.prototype.applyFormat=function(o){var a,s;return((a=this.prefix)!==null&&a!==void 0?a:"")+o+((s=this.postfix)!==null&&s!==void 0?s:"")},r.prototype.toJSON=function(){var o={cursorLabelFormat:this.cursorNumericFormat,cursorLabelPrecision:this.cursorPrecision,labelFormat:this.numericFormat,labelPrecision:this.precision,labelPrefix:this.prefix,labelPostfix:this.postfix};return{type:this.type,options:o}},r.prototype.invalidateParent=function(){this.parentAxis&&this.parentAxis.invalidateParentCallback&&this.parentAxis.invalidateParentCallback()},r})(e.DeletableEntity);return tx.LabelProvider=i,tx}var tme;function tI(){if(tme)return Sf;tme=1;var t=Sf&&Sf.__extends||(function(){var v=function(y,m){return v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,S){b.__proto__=S}||function(b,S){for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(b[_]=S[_])},v(y,m)};return function(y,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");v(y,m);function b(){this.constructor=y}y.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}})(),e=Sf&&Sf.__assign||function(){return e=Object.assign||function(v){for(var y,m=1,b=arguments.length;m<b;m++){y=arguments[m];for(var S in y)Object.prototype.hasOwnProperty.call(y,S)&&(v[S]=y[S])}return v},e.apply(this,arguments)},i=Sf&&Sf.__awaiter||function(v,y,m,b){function S(_){return _ instanceof m?_:new m(function(C){C(_)})}return new(m||(m=Promise))(function(_,C){function P(A){try{E(b.next(A))}catch(R){C(R)}}function x(A){try{E(b.throw(A))}catch(R){C(R)}}function E(A){A.done?_(A.value):S(A.value).then(P,x)}E((b=b.apply(v,y||[])).next())})},n=Sf&&Sf.__generator||function(v,y){var m={label:0,sent:function(){if(_[0]&1)throw _[1];return _[1]},trys:[],ops:[]},b,S,_,C;return C={next:P(0),throw:P(1),return:P(2)},typeof Symbol=="function"&&(C[Symbol.iterator]=function(){return this}),C;function P(E){return function(A){return x([E,A])}}function x(E){if(b)throw new TypeError("Generator is already executing.");for(;m;)try{if(b=1,S&&(_=E[0]&2?S.return:E[0]?S.throw||((_=S.return)&&_.call(S),0):S.next)&&!(_=_.call(S,E[1])).done)return _;switch(S=0,_&&(E=[E[0]&2,_.value]),E[0]){case 0:case 1:_=E;break;case 4:return m.label++,{value:E[1],done:!1};case 5:m.label++,S=E[1],E=[0];continue;case 7:E=m.ops.pop(),m.trys.pop();continue;default:if(_=m.trys,!(_=_.length>0&&_[_.length-1])&&(E[0]===6||E[0]===2)){m=0;continue}if(E[0]===3&&(!_||E[1]>_[0]&&E[1]<_[3])){m.label=E[1];break}if(E[0]===6&&m.label<_[1]){m.label=_[1],_=E;break}if(_&&m.label<_[2]){m.label=_[2],m.ops.push(E);break}_[2]&&m.ops.pop(),m.trys.pop();continue}E=y.call(v,m)}catch(A){E=[6,A],S=0}finally{b=_=0}if(E[0]&5)throw E[1];return{value:E[0]?E[1]:void 0,done:!0}}};Object.defineProperty(Sf,"__esModule",{value:!0}),Sf.LabelProviderBase2D=Sf.LabelInfo=void 0;var r=Uo(),o=hl(),a=id(),s=an(),l=Wf(),u=gD(),c=ZD(),d=Qre(),f=1.1,h=3,p=(function(){function v(y,m,b,S,_){this.tick=y,this.text=m,this.bitmapTexture=b,this.textureHeight=S,this.textureWidth=_,this.lastUsed=Date.now()}return v})();Sf.LabelInfo=p;var g=(function(v){t(y,v);function y(m){var b=this,S,_,C,P,x;return b=v.call(this,m)||this,b.useCache=!r.IS_TEST_ENV,b.alwaysShowFirstLabel=!1,b.tickToText=new Map,b.textVariesForSameTick=!1,b.rotationProperty=0,b.lineSpacingProperty=f,b.providerId=(0,o.generateGuid)(),b.rotationProperty=(S=m==null?void 0:m.rotation)!==null&&S!==void 0?S:b.rotationProperty,b.lineSpacing=(_=m==null?void 0:m.lineSpacing)!==null&&_!==void 0?_:b.lineSpacing,b.alwaysShowFirstLabel=(C=m==null?void 0:m.alwaysShowFirstLabel)!==null&&C!==void 0?C:b.alwaysShowFirstLabel,b.useSharedCache=(P=m==null?void 0:m.useSharedCache)!==null&&P!==void 0?P:l.SciChartDefaults.useSharedCache,b.useNativeText=(x=m==null?void 0:m.useNativeText)!==null&&x!==void 0?x:l.SciChartDefaults.useNativeText,b}return Object.defineProperty(y.prototype,"rotation",{get:function(){return this.rotationProperty},set:function(m){this.rotationProperty!==m&&(this.rotationProperty=m,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"lineSpacing",{get:function(){return this.useNativeText?this.lineSpacingProperty===f?h:this.lineSpacingProperty:this.lineSpacingProperty},set:function(m){this.lineSpacingProperty=m,this.invalidateParent()},enumerable:!1,configurable:!0}),y.prototype.getLabels=function(m){var b=this,S=this.parentAxis;this.useCache&&(this.styleId?c.labelCache.checkStyle(this.styleId,this.getCachedStyle())||(this.resetCache(),this.styleId=c.labelCache.getStyleId(this.getCachedStyle())):this.styleId=c.labelCache.getStyleId(this.getCachedStyle()));var _=m;if(this.parentAxis.isCategoryAxis){var C=this.parentAxis.getCurrentCoordinateCalculator();_=m.map(function(U){return C.transformIndexToData(U)})}var P=[];if(this.useCache){if(this.useNativeText){if(this.currentNativeFontName==="SCRT_Loading"){var I=this.parentAxis.parentSurface.currentWebGlRenderContext,V=I.getFont(this.getCachedStyle(),this.rotation!==0,!1);V.GetFaceName()!==this.currentNativeFontName&&this.invalidateCache()}for(var z=[],G=0,H=_;G<H.length;G++){var A=H[G],D=this.tickToText.get(A);if(this.textVariesForSameTick){var M=this.formatLabel(A);D&&D===M?P.push(D):(this.tickToText.set(A,M),z.push(M),P.push(M))}else if(D){P.push(D);var R=c.labelCache.getLabel(D,this.styleId);R||z.push(D)}else{var M=this.formatLabel(A);this.tickToText.set(A,M),z.push(M),P.push(M)}}this.getLabelSizesNative(z,S.dpiAdjustedLabelStyle)}else for(var x=0,E=_;x<E.length;x++){var A=E[x],R=void 0,M=void 0,D=this.tickToText.get(A);if(this.textVariesForSameTick?(M=this.formatLabel(A),D&&D===M?(R=c.labelCache.getLabel(D,this.styleId),R&&P.push(D)):this.tickToText.set(A,M)):D?(M=D,R=c.labelCache.getLabel(D,this.styleId),R&&P.push(D)):(M=this.formatLabel(A),this.tickToText.set(A,M)),!R){var F=this.getCachedLabelTexture(M,S.axisRenderer.textureManager,S.dpiAdjustedLabelStyle);F.textureWidth!==null&&(R=new p(A,M,F.bitmapTexture,F.textureHeight,F.textureWidth),c.labelCache.setLabel(M,this.styleId,R)),P.push(M)}}c.labelCache.pruneCache(),this.pruneTickTextCache()}else P=_.map(function(U){return b.formatLabel(U)});return P},y.prototype.getLabelHeight=function(m,b,S){if(this.rotationProperty%90===0||this.parentAxis.isHorizontalAxis){var _=this.useCache?c.labelCache.getLabel(b,this.styleId):void 0;if(!_||!_.textureHeight){var C=S.fontSize,P=S.padding;if(!m){var x=this.parentAxis.axisRenderer,E=x.viewRect,A=x.textureManager;m=A.getTextureContext(Math.floor(E.width),Math.floor(E.height))}return(0,u.measureTextHeight)(C)+(P==null?void 0:P.top)+(P==null?void 0:P.bottom)}return _.textureHeight}else return S.fontSize+S.padding.top+S.padding.bottom},y.prototype.getLabelWidth=function(m,b,S){if(this.rotationProperty%90===0||!this.parentAxis.isHorizontalAxis){var _=this.useCache?c.labelCache.getLabel(b,this.styleId):void 0;if(!_||!_.textureWidth){var C=S.padding;return(0,u.measureTextWidth)(m,b)+C.left+C.right}return _.textureWidth}else return S.fontSize+S.padding.left+S.padding.right},y.prototype.getMaxLabelHeightForHorizontalAxis=function(m,b,S){var _=this,C=0;return m.forEach(function(P){var x=_.getLabelHeight(b,P,S);C=x>C?x:C}),C},y.prototype.getMaxLabelWidthForVerticalAxis=function(m,b,S){var _=this,C=0;return m.forEach(function(P){var x=_.getLabelWidth(b,P,S);C=x>C?x:C}),C},y.prototype.getCachedLabelTexture=function(m,b,S){var _,C=c.labelCache.getLabel(m,this.styleId);return C?{textureWidth:(_=C.textureWidth)!==null&&_!==void 0?_:null,textureHeight:C.textureHeight,bitmapTexture:C.bitmapTexture}:this.getLabelTexture(m,b,S)},y.prototype.getLabelTextureAsync=function(m,b,S){return i(this,void 0,void 0,function(){return n(this,function(_){return[2,this.getLabelTexture(m,b,S)]})})},y.prototype.getLabelTexture=function(m,b,S){return b.createTextTexture([m],S,this.rotationProperty)},y.prototype.getNativeLabelInfo=function(m){return c.labelCache.getLabel(m,this.styleId)},y.prototype.invalidateCache=function(){this.styleId&&c.labelCache.freeStyle(this.styleId),this.tickToText.clear(),this.styleId=null},y.prototype.resetCache=function(){this.invalidateCache()},y.prototype.delete=function(){this.resetCache()},y.prototype.adjustLabel=function(m,b,S,_,C,P,x,E,A){return{text:b,x:C,y:P,rx:x,ry:E,rotationRadians:A,color:void 0}},y.prototype.toJSON=function(){var m=v.prototype.toJSON.call(this),b={rotation:this.rotation,lineSpacing:this.lineSpacing,asyncLabels:!1,useSharedCache:this.useSharedCache,useNativeText:this.useNativeText,alwaysShowFirstLabel:this.alwaysShowFirstLabel};return Object.assign(m.options,b),m},y.prototype.getLabelSizesNative=function(m,b){var S=this;if(!(!m||m.length===0||r.IS_TEST_ENV)){var _="",C=[],P=this.parentAxis.parentSurface.currentWebGlRenderContext;if(P){var x=P.getFont(this.getCachedStyle(),this.rotation!==0,!1),E=this.parentAxis.parentSurface.webAssemblyContext2D,A=(0,s.getTextBounds)(E);this.currentNativeFontName=x.GetFaceName();var R=this.rotation*(Math.PI/180),M=Math.abs(Math.sin(R)),D=Math.abs(Math.cos(R)),F=function(G,H,U){var k,X,W=G,Y=H;S.rotation!==0&&(Y=G*M+H*D,W=G*D+H*M);var te=new p(void 0,U,void 0,Y+((k=b.padding)===null||k===void 0?void 0:k.top)+(b==null?void 0:b.padding.bottom),W+((X=b.padding)===null||X===void 0?void 0:X.left)+(b==null?void 0:b.padding.right));te.textWidth=G,te.textHeight=H,c.labelCache.setLabel(U,S.styleId,te)};if(m.forEach(function(G){G&&!G.includes(`
`)?(C.push(G),_+=G+`
`):(x.CalculateStringBounds(G??"",A,S.lineSpacing),F(A.m_fWidth,(0,a.getMultilineTextHeight)(A),G))}),C.length>0){x.CalculateStringBounds(_??"",A,this.lineSpacing);for(var I=0;I<C.length;I++){var V=C[I],z=A.GetLineBounds(I);F(z.m_fWidth,z.m_fHeight,V),z.delete()}}}}},y.prototype.pruneTickTextCache=function(){this.tickToText.size>1e3&&this.tickToText.clear()},y.prototype.getCachedStyle=function(){var m=this.parentAxis,b=m.parentSurface.getWasmId();return e(e({},m.dpiAdjustedLabelStyle),{rotation:this.rotation,providerId:this.useSharedCache?this.useNativeText?"native":b:this.providerId})},y.prototype.clearCache=function(){this.useCache&&this.styleId&&(c.labelCache.freeStyle(this.styleId),this.styleId=void 0),this.tickToText.clear()},y.prototype.invalidateParent=function(){this.clearCache(),v.prototype.invalidateParent.call(this)},y})(d.LabelProvider);return Sf.LabelProviderBase2D=g,Sf}var rme;function DW(){if(rme)return q0;rme=1;var t=q0&&q0.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=q0&&q0.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(q0,"__esModule",{value:!0}),q0.DateLabelProvider=void 0;var i=sR(),n=Fg(),r=Du(),o=tI(),a=(function(s){t(l,s);function l(u){var c=this,d,f;return c=s.call(this,e({labelFormat:(d=u==null?void 0:u.labelFormat)!==null&&d!==void 0?d:n.ENumericFormat.Date_DDMMYYYY,cursorLabelFormat:(f=u==null?void 0:u.cursorLabelFormat)!==null&&f!==void 0?f:n.ENumericFormat.Date_DDMMYYYY},u))||this,c.type=i.ELabelProviderType.Date,c.formatLabelProperty=function(h){return c.applyFormat((0,r.formatNumber)(h,c.numericFormat,c.precision))},c.formatCursorLabelProperty=function(h){var p,g;return c.applyFormat((0,r.formatNumber)(h,(p=c.cursorNumericFormat)!==null&&p!==void 0?p:c.numericFormat,(g=c.cursorPrecision)!==null&&g!==void 0?g:c.precision))},c}return l.prototype.onBeginAxisDraw=function(){},l})(o.LabelProviderBase2D);return q0.DateLabelProvider=a,q0}var rx={},ime;function U3(){return ime||(ime=1,(function(t){var e=rx&&rx.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})(),i=rx&&rx.__assign||function(){return i=Object.assign||function(u){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(u[h]=c[h])}return u},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.wrapText=t.TextLabelProvider=void 0;var n=sR(),r=gD(),o=ZD(),a=tI(),s=(function(u){e(c,u);function c(d){var f=this,h,p;return f=u.call(this,d)||this,f.type=n.ELabelProviderType.Text,f.maxLengthProperty=0,f.labelsProperty=(h=d==null?void 0:d.labels)!==null&&h!==void 0?h:[],f.maxLength=(p=d==null?void 0:d.maxLength)!==null&&p!==void 0?p:f.maxLength,f.formatLabelProperty=function(g){var v,y;if(f.parentAxis.isCategoryAxis&&Array.isArray(f.labels)){var m=f.parentAxis.getCurrentCoordinateCalculator(),b=m.transformDataToIndex(g);return f.wrapText((v=f.labels[b])!==null&&v!==void 0?v:"")}return f.wrapText((y=f.labels[g])!==null&&y!==void 0?y:"")},f.formatCursorLabelProperty=f.formatLabelProperty,f}return Object.defineProperty(c.prototype,"labels",{get:function(){return this.labelsProperty},set:function(d){this.labelsProperty=d,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"maxLength",{get:function(){return this.maxLengthProperty},set:function(d){this.maxLengthProperty=d,this.invalidateParent()},enumerable:!1,configurable:!0}),c.prototype.onBeginAxisDraw=function(){},c.prototype.getLabelWidth=function(d,f,h){if(this.useNativeText||this.rotation%90===0||!this.parentAxis.isHorizontalAxis){var p=o.labelCache.getLabel(f,this.styleId);if(!p){var g=h.padding;return(0,r.measureTextWidth)(d,f)+g.left+g.right}return p.textureWidth}else{var v=Array.isArray(f)?f:f.split(`
`);return v.length*this.lineSpacing*h.fontSize+h.padding.left+h.padding.right}},c.prototype.getLabelTexture=function(d,f,h){var p=d.split(`
`);return f.createTextTexture(p,h,this.rotation,this.lineSpacing)},c.prototype.wrapText=function(d){return d&&Array.isArray(d)?d.join(`
`):(0,t.wrapText)(d,this.maxLength).join(`
`)},c.prototype.toJSON=function(){var d=u.prototype.toJSON.call(this),f={labels:this.labels,maxLength:this.maxLength};return Object.assign(d.options,f),d},c.prototype.getCachedStyle=function(){var d=this.parentAxis;return i(i({},d.dpiAdjustedLabelStyle),{rotation:this.rotation,extras:"ls".concat(this.lineSpacing,",ml").concat(this.maxLength),providerId:this.useSharedCache?void 0:this.providerId})},c})(a.LabelProviderBase2D);t.TextLabelProvider=s;var l=function(u,c){if(c===0)return[u];var d=[];if(!u)return d;for(var f=u.split(" "),h="",p=0,g=f;p<g.length;p++){var v=g[p],y=h+(h!==""?" ":"")+v;y.length>c?h===""?d.push(v):(d.push(h),h=v):h=y}return d.push(h),d};t.wrapText=l})(rx)),rx}var nme;function RW(){if(nme)return U1;nme=1;var t=U1&&U1.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(U1,"__esModule",{value:!0}),U1.CategoryAxis=void 0;var e=ud(),i=rBe(),n=DW(),r=U3(),o=(function(a){t(s,a);function s(l,u){var c=a.call(this,l,u)||this;return c.type=e.EAxisType.CategoryAxis,u!=null&&u.labelProvider?c.labelProvider=u==null?void 0:u.labelProvider:u!=null&&u.labels?c.labelProvider=new r.TextLabelProvider(u):c.labelProvider=new n.DateLabelProvider(u),c}return s})(i.CategoryAxisBase);return U1.CategoryAxis=o,U1}var ix={},nx={},ox={},ome;function lS(){return ome||(ome=1,(function(t){var e=ox&&ox.__extends||(function(){var S=function(_,C){return S=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(P,x){P.__proto__=x}||function(P,x){for(var E in x)Object.prototype.hasOwnProperty.call(x,E)&&(P[E]=x[E])},S(_,C)};return function(_,C){if(typeof C!="function"&&C!==null)throw new TypeError("Class extends value "+String(C)+" is not a constructor or null");S(_,C);function P(){this.constructor=_}_.prototype=C===null?Object.create(C):(P.prototype=C.prototype,new P)}})(),i=ox&&ox.__assign||function(){return i=Object.assign||function(S){for(var _,C=1,P=arguments.length;C<P;C++){_=arguments[C];for(var x in _)Object.prototype.hasOwnProperty.call(_,x)&&(S[x]=_[x])}return S},i.apply(this,arguments)},n;Object.defineProperty(t,"__esModule",{value:!0}),t.SmartDateLabelProvider=t.DEFAULT_LABEL_THRESHOLDS=t.EHighPrecisionLabelMode=t.EDatePrecision=t.ETradeChartLabelFormat=void 0;var r=sR(),o=Fg(),a=Tf(),s=Du(),l=tI(),u;(function(S){S.Nanoseconds="Nanoseconds",S.Microseconds="Microseconds",S.MilliSeconds="MilliSeconds",S.Seconds="Seconds",S.Minutes="Minutes",S.Days="Days",S.Months="Months"})(u=t.ETradeChartLabelFormat||(t.ETradeChartLabelFormat={}));var c;(function(S){S[S.Seconds=1]="Seconds",S[S.Milliseconds=1e3]="Milliseconds",S[S.Microseconds=1e6]="Microseconds",S[S.Nanoseconds=1e9]="Nanoseconds"})(c=t.EDatePrecision||(t.EDatePrecision={}));var d;(function(S){S.Suffix="Suffix",S.Fractional="Fractional",S.Scientific="Scientific"})(d=t.EHighPrecisionLabelMode||(t.EHighPrecisionLabelMode={}));var f=1e-5,h=.01,p=10,g=3600,v=3600*24*5,y=3600*24*50;t.DEFAULT_LABEL_THRESHOLDS=(n={},n[u.Nanoseconds]=f,n[u.Microseconds]=h,n[u.MilliSeconds]=p,n[u.Seconds]=g,n[u.Minutes]=v,n[u.Days]=y,n[u.Months]=1/0,n);var m=[u.Nanoseconds,u.Microseconds,u.MilliSeconds,u.Seconds,u.Minutes,u.Days,u.Months],b=(function(S){e(_,S);function _(C){var P=this,x,E,A,R,M,D,F,I,V,z,G;return P=S.call(this,i(i({},C),{labelFormat:(x=C==null?void 0:C.labelFormat)!==null&&x!==void 0?x:o.ENumericFormat.Date_DDMMYYYY,cursorLabelFormat:(E=C==null?void 0:C.cursorLabelFormat)!==null&&E!==void 0?E:o.ENumericFormat.Date_DDMMYYYY,alwaysShowFirstLabel:(A=C==null?void 0:C.alwaysShowFirstLabel)!==null&&A!==void 0?A:!0}))||this,P.type=r.ELabelProviderType.SmartDate,P.textVariesForSameTick=!0,P.showWiderDateOnFirstLabelProperty=!0,P.showYearOnWiderDateProperty=!1,P.dateOffsetProperty=0,P.datePrecisionProperty=c.Seconds,P.highPrecisionLabelModeProperty=d.Suffix,P.labelThresholdsProperty=t.DEFAULT_LABEL_THRESHOLDS,P.labelThresholdsUpdated=!1,P.splitWideDateWithCommaProperty=!0,P.showSecondsOnWideDateProperty=!0,P.showSecondsOnPreciseDateProperty=!1,P.firstLabel=!0,P.showWiderDateOnFirstLabelProperty=(R=C==null?void 0:C.showWiderDateOnFirstLabel)!==null&&R!==void 0?R:P.showWiderDateOnFirstLabelProperty,P.showYearOnWiderDateProperty=(M=C==null?void 0:C.showYearOnWiderDate)!==null&&M!==void 0?M:P.showYearOnWiderDateProperty,P.dateOffsetProperty=(D=C==null?void 0:C.dateOffset)!==null&&D!==void 0?D:P.dateOffsetProperty,P.datePrecisionProperty=(F=C==null?void 0:C.datePrecision)!==null&&F!==void 0?F:P.datePrecisionProperty,P.highPrecisionLabelModeProperty=(I=C==null?void 0:C.highPrecisionLabelMode)!==null&&I!==void 0?I:P.highPrecisionLabelModeProperty,P.splitWideDateWithCommaProperty=(V=C==null?void 0:C.splitWideDateWithComma)!==null&&V!==void 0?V:P.splitWideDateWithCommaProperty,P.showSecondsOnWideDateProperty=(z=C==null?void 0:C.showSecondsOnWideDate)!==null&&z!==void 0?z:P.showSecondsOnWideDateProperty,P.showSecondsOnPreciseDateProperty=(G=C==null?void 0:C.showSecondsOnPreciseDate)!==null&&G!==void 0?G:P.showSecondsOnPreciseDateProperty,C!=null&&C.labelThresholds&&(P.labelThresholdsProperty=i(i({},t.DEFAULT_LABEL_THRESHOLDS),C.labelThresholds),P.labelThresholdsUpdated=!0),P.formatCursorLabelProperty=function(H){var U,k,X=P.convertToUnixSeconds(H)+P.dateOffset;return P.applyFormat((0,s.formatNumber)(X,(U=P.cursorNumericFormat)!==null&&U!==void 0?U:P.numericFormat,(k=P.cursorPrecision)!==null&&k!==void 0?k:P.precision))},P.doFormat=P.doFormat.bind(P),P.formatLabelProperty=P.doFormat,P}return _.prototype.convertToUnixSeconds=function(C){return C/this.datePrecisionProperty},_.prototype.getWholeSeconds=function(C){var P=this.datePrecisionProperty;return Math.floor(C/P)},Object.defineProperty(_.prototype,"showWiderDateOnFirstLabel",{get:function(){return this.showWiderDateOnFirstLabelProperty},set:function(C){this.showWiderDateOnFirstLabelProperty!==C&&(this.showWiderDateOnFirstLabelProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"dateOffset",{get:function(){var C;return(C=this.dateOffsetProperty)!==null&&C!==void 0?C:0},set:function(C){this.dateOffsetProperty!==C&&(this.dateOffsetProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"datePrecision",{get:function(){return this.datePrecisionProperty},set:function(C){this.datePrecisionProperty!==C&&(this.datePrecisionProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"highPrecisionLabelMode",{get:function(){return this.highPrecisionLabelModeProperty},set:function(C){this.highPrecisionLabelModeProperty!==C&&(this.highPrecisionLabelModeProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"showYearOnWiderDate",{get:function(){return this.showYearOnWiderDateProperty},set:function(C){this.showYearOnWiderDateProperty!==C&&(this.showYearOnWiderDateProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"labelThresholds",{get:function(){return this.labelThresholdsProperty},set:function(C){this.labelThresholdsProperty!==C&&(this.labelThresholdsProperty=i(i({},this.labelThresholdsProperty),C),this.labelThresholdsUpdated=!0,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"splitWideDateWithComma",{get:function(){return this.splitWideDateWithCommaProperty},set:function(C){this.splitWideDateWithCommaProperty!==C&&(this.splitWideDateWithCommaProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"showSecondsOnWideDate",{get:function(){return this.showSecondsOnWideDateProperty},set:function(C){this.showSecondsOnWideDateProperty!==C&&(this.showSecondsOnWideDateProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"showSecondsOnPreciseDate",{get:function(){return this.showSecondsOnPreciseDateProperty},set:function(C){this.showSecondsOnPreciseDateProperty!==C&&(this.showSecondsOnPreciseDateProperty=C,this.invalidateParent())},enumerable:!1,configurable:!0}),Object.defineProperty(_.prototype,"numericFormat",{get:function(){},set:function(C){},enumerable:!1,configurable:!0}),_.prototype.onBeginAxisDraw=function(){},_.prototype.getLabels=function(C){var P=C[0],x=C.length,E=C[x-1];if(this.parentAxis.isCategoryAxis){var A=this.parentAxis.getCurrentCoordinateCalculator();P=A.transformIndexToData(P),E=A.transformIndexToData(E)}this.prevPrevValue=void 0,this.prevValue=void 0,this.firstLabel=!0;var R=E-P,M=R/this.datePrecisionProperty;this.format=this.getLabelRange(M,x);var D=S.prototype.getLabels.call(this,C);return this.format=void 0,D},_.prototype.formatDateWide=function(C,P){var x=(0,a.formatUnixDateToHumanStringYYYY)(P),E=this.showYearOnWiderDate?" "+x:"",A=this.splitWideDateWithComma?",":"";switch(C){case u.Nanoseconds:case u.Microseconds:case u.MilliSeconds:{var R=this.showSecondsOnWideDate?(0,a.formatUnixDateToHumanStringHHMMSS)(P):(0,a.formatUnixDateToHumanStringHHMM)(P);return(0,a.formatUnixDateToHumanStringMMMDD)(P)+A+E+" "+R}case u.Seconds:case u.Minutes:return(0,a.formatUnixDateToHumanStringMMMDD)(P)+(this.showYearOnWiderDateProperty?A+E:"");case u.Days:return(0,a.formatUnixDateToHumanStringMMM)(P)+E;default:return x}},_.prototype.formatDatePrecise=function(C,P,x){var E=x??0;switch(C){case u.Nanoseconds:case u.Microseconds:case u.MilliSeconds:{var A=this.getTicksPerSecond(),R=this.getTicksWithinSecond(E),M=R/A,D=this.showSecondsOnPreciseDate?"".concat(this.getWholeSeconds(E)%60):"";switch(this.highPrecisionLabelModeProperty){case d.Scientific:return"".concat(M.toExponential(2),"s");case d.Fractional:return C===u.Nanoseconds?"".concat(D,".").concat(this.getNanosecondsWithinSecond(E)):C===u.Microseconds?"".concat(D,".").concat(this.getMicrosecondsWithinSecond(E)):"".concat(D,".").concat(this.getMillisecondsWithinSecond(E));case d.Suffix:default:{var F=D?D+"s":"";return C===u.Nanoseconds?"".concat(F).concat(Math.round(M*1e9),"ns"):C===u.Microseconds?"".concat(F).concat(Math.round(M*1e6),"µs"):"".concat(F).concat(Math.round(M*1e3),"ms")}}}case u.Seconds:return(0,a.formatUnixDateToHumanStringHHMMSS)(P);case u.Minutes:return(0,a.formatUnixDateToHumanStringHHMM)(P);case u.Days:case u.Months:return(0,a.formatUnixDateToHumanStringDD)(P);default:return(0,s.formatNumber)(P,o.ENumericFormat.Date_DDMMYY,0)}},_.prototype.toJSON=function(){var C=S.prototype.toJSON.call(this),P={dateOffset:this.dateOffset,highPrecisionLabelMode:this.highPrecisionLabelMode,showWiderDateOnFirstLabel:this.showWiderDateOnFirstLabel,showYearOnWiderDate:this.showYearOnWiderDate,datePrecision:this.datePrecision,splitWideDateWithComma:this.splitWideDateWithComma,showSecondsOnWideDate:this.showSecondsOnWideDate,showSecondsOnPreciseDate:this.showSecondsOnPreciseDate,labelThresholds:this.labelThresholdsUpdated?this.labelThresholds:void 0};return Object.assign(C.options,P),C},_.prototype.doFormat=function(C){var P,x,E=this.convertToUnixSeconds(C)+this.dateOffset;if(this.format){var A=this.formatSmartLabel(this.format,E,this.prevValue,this.prevPrevValue,C);return this.prevPrevValue=this.prevValue,this.prevValue=E,A}else return this.applyFormat((0,s.formatNumber)(E,(P=this.cursorNumericFormat)!==null&&P!==void 0?P:this.numericFormat,(x=this.cursorPrecision)!==null&&x!==void 0?x:this.precision))},_.prototype.getLabelRange=function(C,P){for(var x=0,E=m;x<E.length;x++){var A=E[x],R=this.labelThresholdsProperty[A];if(R!==void 0&&C<=R)return A}return u.Months},_.prototype.formatSmartLabel=function(C,P,x,E,A){var R=!this.firstLabel||this.showWiderDateOnFirstLabel;this.firstLabel=!1;var M=this.formatDateWide(C,P),D=x!==void 0?this.formatDateWide(C,x):void 0,F=D===void 0||M!==D;if(C!==u.Months)return F&&R?M:this.formatDatePrecise(C,P,A);if(F&&R)return M;var I=E!==void 0&&x!==void 0?this.formatDateWide(C,E):void 0,V=I===void 0||D!==I,z=V||(0,a.formatUnixDateToHumanStringMMM)(P)!==(0,a.formatUnixDateToHumanStringMMM)(x);return z?(0,a.formatUnixDateToHumanStringMMM)(P):this.formatDatePrecise(C,P,A)},_.prototype.getTicksPerSecond=function(){return this.datePrecisionProperty},_.prototype.getTicksWithinSecond=function(C){var P=this.getTicksPerSecond();if(!P)return 0;var x=Math.floor(C/P);return C-x*P},_.prototype.getMillisecondsWithinSecond=function(C){var P=this.getTicksPerSecond();if(!P)return 0;var x=this.getTicksWithinSecond(C);return Math.floor(x*1e3/P)},_.prototype.getMicrosecondsWithinSecond=function(C){var P=this.getTicksPerSecond();if(!P)return 0;var x=this.getTicksWithinSecond(C);return Math.floor(x*1e6/P)},_.prototype.getNanosecondsWithinSecond=function(C){var P=this.getTicksPerSecond();if(!P)return 0;var x=this.getTicksWithinSecond(C);return Math.floor(x*1e9/P)},_})(l.LabelProviderBase2D);t.SmartDateLabelProvider=b})(ox)),ox}var ame;function eie(){if(ame)return nx;ame=1;var t=nx&&nx.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(nx,"__esModule",{value:!0}),nx.DateTimeDeltaCalculator=void 0;var e=GV(),i=di(),n=lS(),r=aR(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;return c=a.call(this,l)||this,c.possibleDeltasProperty=[1,2,5,10,15,30,60,120,300,600,900,1800,3600,7200,10800,360*60,720*60,1440*60,2880*60,4320*60,7200*60,14400*60,360*60*60,480*60*60,720*60*60,1440*60*60,2880*60*60,4320*60*60,365.25*24*60*60],c.currIndex=1,c.possibleDeltasProperty=(d=u==null?void 0:u.possibleDeltas)!==null&&d!==void 0?d:c.possibleDeltasProperty,c.minTicks=u==null?void 0:u.minTicks,c.datePrecisionProperty=(f=u==null?void 0:u.datePrecision)!==null&&f!==void 0?f:n.EDatePrecision.Seconds,c.currIndex=Math.floor(c.possibleDeltas.length/2),c}return Object.defineProperty(s.prototype,"datePrecisionValue",{get:function(){return this.datePrecisionProperty},set:function(l){this.datePrecisionProperty!==l&&(this.datePrecisionProperty=l)},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"possibleDeltas",{get:function(){return this.possibleDeltasProperty},set:function(l){this.possibleDeltasProperty!==l&&(this.possibleDeltasProperty=l,this.currIndex=Math.floor(this.possibleDeltas.length/2))},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"minTicks",{get:function(){return this.minTicksProperty},set:function(l){this.minTicksProperty!==l&&(this.minTicksProperty=l)},enumerable:!1,configurable:!0}),s.prototype.getDeltaFromRange=function(l,u,c,d){var f=this,h=u-l;this.prevIndex=void 0,this.currIndex>=this.possibleDeltas.length&&(this.currIndex=Math.floor(this.possibleDeltas.length/2));var p=0,g=function(y){var m,b,S=f.possibleDeltasProperty[y];if(p++,p>f.possibleDeltas.length+1)return e.performanceWarnings.dateTimeDeltaCalculatorBadDelta.warn(),S;var _=Math.floor(h/S);if(_<((m=f.minTicks)!==null&&m!==void 0?m:d/3)&&y===0&&y!==f.prevIndex)return f.prevIndex||(f.prevIndex=y),a.prototype.getDeltaFromRange.call(f,l,u,c,d).max;if(_<((b=f.minTicks)!==null&&b!==void 0?b:d/3)&&y>0&&y!==f.prevIndex)return f.prevIndex||(f.prevIndex=y),g(y-1);if(_>d&&y<f.possibleDeltasProperty.length-1&&y!==f.prevIndex)return f.prevIndex||(f.prevIndex=y),g(y+1);if(_>d&&y===f.possibleDeltasProperty.length-1){var C=a.prototype.getDeltaFromRange.call(f,l/S,u/S,c,d);return C.max*S}else return f.currIndex!==y&&(f.currIndex=y),S},v=g(this.currIndex);return new i.NumberRange(v/c,v)},s})(r.NumericDeltaCalculator);return nx.DateTimeDeltaCalculator=o,nx}var ax={},sx={},sme;function MW(){if(sme)return sx;sme=1;var t=sx&&sx.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(sx,"__esModule",{value:!0}),sx.FlippedNumericCoordinateCalculator=void 0;var e=iC(),i=(function(n){t(r,n);function r(o,a,s,l,u,c,d){u===void 0&&(u=0),c===void 0&&(c=!1),d===void 0&&(d=-1);var f=n.call(this,o,a,s,l,u,!0)||this;return f.nativeCalculator=c?new o.FlippedLinearCoordinateCalculatorSingle(f.viewportDimension,f.visibleMin,f.visibleMax,d,f.offset):new o.FlippedLinearCoordinateCalculatorDouble(f.viewportDimension,f.visibleMin,f.visibleMax,d,f.offset),f}return r})(e.CoordinateCalculatorBase);return sx.FlippedNumericCoordinateCalculator=i,sx}var lx={},lme;function LW(){if(lme)return lx;lme=1;var t=lx&&lx.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(lx,"__esModule",{value:!0}),lx.NumericCoordinateCalculator=void 0;var e=iC(),i=(function(n){t(r,n);function r(o,a,s,l,u,c,d,f){u===void 0&&(u=0),c===void 0&&(c=!1),d===void 0&&(d=-1),f===void 0&&(f=1);var h=n.call(this,o,a,s,l,u,!1)||this,p=c?new o.LinearCoordinateCalculatorSingle(h.viewportDimension,h.visibleMin,h.visibleMax,d,h.offset):new o.LinearCoordinateCalculatorDouble(h.viewportDimension,h.visibleMin,h.visibleMax,d,h.offset);return p.extraOffset=f,h.nativeCalculator=p,h}return r})(e.CoordinateCalculatorBase);return lx.NumericCoordinateCalculator=i,lx}var X0={},ume;function Rm(){if(ume)return X0;ume=1;var t=X0&&X0.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=X0&&X0.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(X0,"__esModule",{value:!0}),X0.NumericLabelProvider=void 0;var i=sR(),n=Fg(),r=Du(),o=tI(),a=(function(s){t(l,s);function l(u){var c=this,d,f;return c=s.call(this,e({labelFormat:(d=u==null?void 0:u.labelFormat)!==null&&d!==void 0?d:n.ENumericFormat.Decimal,labelPrecision:(f=u==null?void 0:u.labelPrecision)!==null&&f!==void 0?f:1},u))||this,c.type=i.ELabelProviderType.Numeric,c.formatLabelProperty=function(h){return c.applyFormat((0,r.formatNumber)(h,c.numericFormat,c.precision,c.engineeringPrefix))},c.formatCursorLabelProperty=function(h){var p,g;return c.applyFormat((0,r.formatNumber)(h,(p=c.cursorNumericFormat)!==null&&p!==void 0?p:c.numericFormat,(g=c.cursorPrecision)!==null&&g!==void 0?g:c.precision,c.engineeringPrefix))},c}return Object.defineProperty(l.prototype,"engineeringPrefix",{get:function(){return this.engineeringPrefixProperty},set:function(u){this.engineeringPrefixProperty=u,this.invalidateParent()},enumerable:!1,configurable:!0}),l.prototype.onBeginAxisDraw=function(){},l})(o.LabelProviderBase2D);return X0.NumericLabelProvider=a,X0}var cme;function BI(){if(cme)return ax;cme=1;var t=ax&&ax.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(ax,"__esModule",{value:!0}),ax.NumericAxis=void 0;var e=ud(),i=MW(),n=LW(),r=oR(),o=Vv(),a=aR(),s=Rm(),l=(function(u){t(c,u);function c(d,f){var h=this,p;return h=u.call(this,d,f)||this,h.type=e.EAxisType.NumericAxis,h.tickProvider=new r.NumericTickProvider(h.webAssemblyContext2D),h.labelProvider=(p=f==null?void 0:f.labelProvider)!==null&&p!==void 0?p:new s.NumericLabelProvider(f),h.deltaCalculator=new a.NumericDeltaCalculator(h.webAssemblyContext2D),h}return c.prototype.getCurrentCoordinateCalculatorInternal=function(){var d=this.visibleRange.min,f=this.visibleRange.max,h=this.offset,p=this.axisLength;return this.isXAxis!==this.flippedCoordinates?new i.FlippedNumericCoordinateCalculator(this.webAssemblyContext2D,p,d,f,h,this.allowFastMath):new n.NumericCoordinateCalculator(this.webAssemblyContext2D,p,d,f,h,this.allowFastMath)},c})(o.AxisBase2D);return ax.NumericAxis=l,ax}var dme;function iBe(){if(dme)return ix;dme=1;var t=ix&&ix.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(ix,"__esModule",{value:!0}),ix.DateTimeNumericAxis=void 0;var e=ud(),i=eie(),n=lS(),r=BI(),o=(function(a){t(s,a);function s(l,u){var c=this;return u!=null&&u.labelProvider||(u=u??{},u.labelProvider=new n.SmartDateLabelProvider(u)),c=a.call(this,l,u)||this,c.type=e.EAxisType.DateTimeNumericAxis,c.possibleDeltasOption=u==null?void 0:u.possibleDeltas,c.minTicksOption=u==null?void 0:u.minTicks,c.deltaCalculator=new i.DateTimeDeltaCalculator(l,{possibleDeltas:u==null?void 0:u.possibleDeltas,minTicks:u==null?void 0:u.minTicks,datePrecision:u==null?void 0:u.datePrecision}),c}return s.prototype.toJSON=function(){var l=a.prototype.toJSON.call(this),u={possibleDeltas:this.possibleDeltasOption,minTicks:this.minTicksOption};return Object.assign(l.options,u),l},s})(r.NumericAxis);return ix.DateTimeNumericAxis=o,ix}var K0={},fme;function tie(){if(fme)return K0;fme=1;var t=K0&&K0.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=K0&&K0.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(K0,"__esModule",{value:!0}),K0.LogarithmicLabelProvider=void 0;var i=Fg(),n=Du(),r=Rm(),o=(function(a){t(s,a);function s(l){var u=this,c,d;return u=a.call(this,e({labelFormat:(c=l==null?void 0:l.labelFormat)!==null&&c!==void 0?c:i.ENumericFormat.Scientific,labelPrecision:(d=l==null?void 0:l.labelPrecision)!==null&&d!==void 0?d:1},l))||this,u.formatLabelProperty=function(f){return u.numericFormat===i.ENumericFormat.Scientific?u.applyFormat((0,n.toScientific)(f,u.precision,u.logarithmicBase)):u.applyFormat((0,n.formatNumber)(f,u.numericFormat,u.precision,u.engineeringPrefix))},u}return s})(r.NumericLabelProvider);return K0.LogarithmicLabelProvider=o,K0}var Z0={},J0={},ux={},kF={},cx={},hme;function fJ(){if(hme)return cx;hme=1,Object.defineProperty(cx,"__esModule",{value:!0}),cx.stringOccurrences=cx.htmlToElement=void 0;function t(i){var n=document.createElement("template");return i=i.trim(),n.innerHTML=i,n.content.firstChild}cx.htmlToElement=t;function e(i,n,r){if(r===void 0&&(r=!1),i+="",n+="",n.length<=0)return i.length+1;for(var o=0,a=0,s=r?1:n.length;a=i.indexOf(n,a),a>=0;)++o,a+=s;return o}return cx.stringOccurrences=e,cx}var dx={},M9={},pme;function rie(){return pme||(pme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESubChartClippingMode=void 0,(function(e){e.SeriesViewRect="SeriesViewRect",e.Chart="Chart"})(t.ESubChartClippingMode||(t.ESubChartClippingMode={}))})(M9)),M9}var L9={},gme;function kW(){return gme||(gme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESubSurfacePositionCoordinateMode=void 0,(function(e){e.DataValue="DataValue",e.Pixel="Pixel",e.Relative="Relative"})(t.ESubSurfacePositionCoordinateMode||(t.ESubSurfacePositionCoordinateMode={}))})(L9)),L9}var fx={},vme;function iie(){if(vme)return fx;vme=1,Object.defineProperty(fx,"__esModule",{value:!0}),fx.hasProperties=fx.areEqual=void 0;function t(i,n){if(i===n)return!0;var r=Object.keys(i),o=Object.keys(i);return r.length===o.length&&r.every(function(a){return Object.prototype.hasOwnProperty.call(n,a)&&i[a]===n[a]})}fx.areEqual=t;var e=function(i,n){return n.every(function(r){return Object.prototype.hasOwnProperty.call(i,r)})};return fx.hasProperties=e,fx}var hx={},px={},gx={},vx={},yme;function nie(){if(yme)return vx;yme=1;var t=vx&&vx.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(vx,"__esModule",{value:!0}),vx.BasePolarAxisLayoutStrategy=void 0;var e=eR(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.updateAreaSize=function(o,a){},r})(e.BaseAxisLayoutStrategy);return vx.BasePolarAxisLayoutStrategy=i,vx}var mme;function nBe(){if(mme)return gx;mme=1;var t=gx&&gx.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(gx,"__esModule",{value:!0}),gx.AngularAxisLayoutStrategy=void 0;var e=Rn(),i=$d(),n=nie(),r=nR(),o=2*Math.PI,a=Math.PI/2,s=(function(l){t(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=i.ELayoutStrategyType.TopOuter,c}return u.prototype.measureAxes=function(c,d,f){if(!f||f.length===0)return 0;var h=f[0],p=h.isXAxis?c.yAxes.get(0):c.xAxes.get(0),g=f[0].startAngle,v=f[0].totalAngle,y=this.partialArcLayout(p.innerRadius,g,v),m=y.rightScale,b=y.topScale,S=y.leftScale,_=y.bottomScale;return f.forEach(function(C){var P=C;if(g!==P.startAngle||v!==P.totalAngle)throw new Error("AngularAxisLayoutStrategy assumes all angular axes have the same startAngle and totalAngle.  To vary this use StackedAngularAxisLayoutStrategy.");C.measure();var x=P.axisRenderer,E=P.axisLayoutState,A=P.axisBorder;E.clear();var R=A.borderBottom+A.borderTop,M=0,D=M+x.desiredHeight+R;E.axisSize=D;var F=A.borderLeft+A.borderRight,I=M+x.desiredWidth+F;E.leftScale=S,E.rightScale=m,E.topScale=b,E.bottomScale=_,P.isAngular&&(d.topOuterAreaSize+=D,d.bottomOuterAreaSize+=D,d.leftOuterAreaSize+=I,d.rightOuterAreaSize+=I)}),0},u.prototype.layoutAxes=function(c,d,f,h,p){if(!(!p||p.length===0)){var g=p[0],v=g.axisLayoutState,y=v.leftScale,m=v.rightScale,b=v.topScale,S=v.bottomScale;v.axisSize;var _=m-y,C=b-S,P=_/C,x=h-d,E=f-c,A=E/x,R=A>P?x*P:E,M=A>P?x:E/P,D=R/_,F=c+(E-R)/2-R*y/(m-y),I=d+(x-M)/2+M*(1+S/(b-S));p.forEach(function(V){V.axisLength=V.totalAngle,V.offset=0;var z=V,G=z.axisLayoutState.axisSize,H=z.axisRenderer,U=z.xCenterOffset,k=z.yCenterOffset;V.viewRect=e.Rect.create(F+U,I+k,D,D+G),H.layout(V.viewRect),D+=G})}},u.prototype.partialArcLayout=function(c,d,f){var h=1,p=1,g=-1,v=-1;if(f<o){var y=r.labelHelper.normalizeAngle(d),m=y+f,b=Math.cos(y),S=Math.cos(m),_=Math.sin(y),C=Math.sin(m),P=y===0||o<=m;P||(h=Math.max(b,S,b*c,S*c));var x=y<=Math.PI&&Math.PI<=m||3*Math.PI<=m;x||(g=Math.min(b,S,b*c,S*c));var E=y<=a&&a<=m||o+a<=m;E||(p=Math.max(_,C,_*c,C*c));var A=y<=3*a&&3*a<=m||o+3*a<=m;A||(v=Math.min(_,C,_*c,C*c))}return{rightScale:h,leftScale:g,topScale:p,bottomScale:v}},u})(n.BasePolarAxisLayoutStrategy);return gx.AngularAxisLayoutStrategy=s,gx}var yx={},bme;function oBe(){if(bme)return yx;bme=1;var t=yx&&yx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(yx,"__esModule",{value:!0}),yx.RadialAxisLayoutStrategy=void 0;var e=Rn(),i=nie(),n=(function(r){t(o,r);function o(){return r!==null&&r.apply(this,arguments)||this}return o.prototype.measureAxes=function(a,s,l){return l.forEach(function(u){u.measure()}),0},o.prototype.layoutAxes=function(a,s,l,u,c){c.forEach(function(d){d.axisLength=l,d.offset=0,d.viewRect=e.Rect.create(a,s,l,1)})},o})(i.BasePolarAxisLayoutStrategy);return yx.RadialAxisLayoutStrategy=n,yx}var Sme;function oie(){if(Sme)return px;Sme=1;var t=px&&px.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(px,"__esModule",{value:!0}),px.PolarLayoutManager=void 0;var e=Rn(),i=zS(),n=nBe(),r=JP(),o=oBe(),a=10,s=(function(l){t(u,l);function u(){var c=l!==null&&l.apply(this,arguments)||this;return c.type=i.ELayoutManagerType.Polar,c.angularOuterAxesLayoutStrategyProperty=new n.AngularAxisLayoutStrategy,c.angularInnerAxesLayoutStrategyProperty=new n.AngularAxisLayoutStrategy,c.radialOuterAxesLayoutStrategyProperty=new o.RadialAxisLayoutStrategy,c.radialInnerAxesLayoutStrategyProperty=new o.RadialAxisLayoutStrategy,c}return Object.defineProperty(u.prototype,"angularOuterAxesLayoutStrategy",{get:function(){return this.angularOuterAxesLayoutStrategyProperty},set:function(c){var d,f=this.angularOuterAxesLayoutStrategyProperty;f!==c&&(this.angularOuterAxesLayoutStrategyProperty=c,f.isStacked&&!c.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.topOuterAxes)),(d=this.sciChartSurface)===null||d===void 0||d.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"angularInnerAxesLayoutStrategy",{get:function(){return this.angularInnerAxesLayoutStrategyProperty},set:function(c){var d,f=this.angularInnerAxesLayoutStrategyProperty;f!==c&&(this.angularInnerAxesLayoutStrategyProperty=c,f.isStacked&&!c.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.topInnerAxes)),(d=this.sciChartSurface)===null||d===void 0||d.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"radialOuterAxesLayoutStrategy",{get:function(){return this.radialOuterAxesLayoutStrategyProperty},set:function(c){var d,f=this.radialOuterAxesLayoutStrategyProperty;f!==c&&(this.radialOuterAxesLayoutStrategyProperty=c,f.isStacked&&!c.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.rightOuterAxes)),(d=this.sciChartSurface)===null||d===void 0||d.invalidateElement())},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"radialInnerAxesLayoutStrategy",{get:function(){return this.radialInnerAxesLayoutStrategyProperty},set:function(c){var d,f=this.radialInnerAxesLayoutStrategyProperty;f!==c&&(this.radialInnerAxesLayoutStrategyProperty=c,f.isStacked&&!c.isStacked&&(this.groupAxesByLayoutStrategy(),this.resetAxes(this.axesGroupedByLayoutStrategy.rightInnerAxes)),(d=this.sciChartSurface)===null||d===void 0||d.invalidateElement())},enumerable:!1,configurable:!0}),u.prototype.getAxisLayoutStrategy=function(c){if(!c.isPolarAxis)throw new Error("Cannot get Polar LayoutStrategy for a non-polar axis");return c.isAngular?c.isInnerAxis?this.angularInnerAxesLayoutStrategy:this.angularOuterAxesLayoutStrategy:c.isInnerAxis?this.radialInnerAxesLayoutStrategy:this.radialOuterAxesLayoutStrategy},u.prototype.layoutChart=function(c,d){var f,h,p,g,v,y,m,b,S,_,C,P;this.groupAxesByLayoutStrategy();var x=(f=d==null?void 0:d.right)!==null&&f!==void 0?f:0,E=(h=d==null?void 0:d.left)!==null&&h!==void 0?h:0,A=(p=d==null?void 0:d.top)!==null&&p!==void 0?p:0,R=(g=d==null?void 0:d.bottom)!==null&&g!==void 0?g:0,M=c.width-E-x,D=c.height-A-R,F=this.sciChartSurface.adjustedPadding;this.chartLayoutState.leftOuterAreaSize=((v=F==null?void 0:F.left)!==null&&v!==void 0?v:0)+this.sciChartSurface.leftViewportBorder+this.sciChartSurface.leftCanvasBorder,this.chartLayoutState.rightOuterAreaSize=((y=F==null?void 0:F.right)!==null&&y!==void 0?y:0)+this.sciChartSurface.rightViewportBorder+this.sciChartSurface.rightCanvasBorder,this.chartLayoutState.topOuterAreaSize=((m=F==null?void 0:F.top)!==null&&m!==void 0?m:0)+this.sciChartSurface.topViewportBorder+this.sciChartSurface.topCanvasBorder,this.chartLayoutState.bottomOuterAreaSize=((b=F==null?void 0:F.bottom)!==null&&b!==void 0?b:0)+this.sciChartSurface.bottomViewportBorder+this.sciChartSurface.bottomCanvasBorder,this.setSeriesViewRect(this.chartLayoutState.leftOuterAreaSize,this.chartLayoutState.topOuterAreaSize,c.width-this.chartLayoutState.rightOuterAreaSize,c.height-this.chartLayoutState.bottomOuterAreaSize);try{this.angularOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.topOuterAxes),this.angularInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.topInnerAxes),this.radialOuterAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.rightOuterAxes),this.radialInnerAxesLayoutStrategy.measureAxes(this.sciChartSurface,this.chartLayoutState,this.axesGroupedByLayoutStrategy.rightInnerAxes);var I=M-this.chartLayoutState.leftOuterAreaSize-this.chartLayoutState.rightOuterAreaSize,V=D-this.chartLayoutState.topOuterAreaSize-this.chartLayoutState.bottomOuterAreaSize,z=E,G=z+this.chartLayoutState.leftOuterAreaSize,H=G+(I<a?a:I),U=H+this.chartLayoutState.rightOuterAreaSize,k=A,X=k+this.chartLayoutState.topOuterAreaSize,W=X+(V<a?a:V),Y=W+this.chartLayoutState.bottomOuterAreaSize;this.sciChartSurface.annotationUnderlaySurfaceViewRect=e.Rect.createWithCoords(z,k,U,Y),this.sciChartSurface.annotationOverlaySurfaceViewRect=e.Rect.createWithCoords(z,k,U,Y),this.sciChartSurface.chartModifierSurfaceViewRect=e.Rect.createWithCoords(z,k,U,Y),this.angularOuterAxesLayoutStrategy.layoutAxes(G,X,H,W,this.axesGroupedByLayoutStrategy.topOuterAxes);var te=(P=(_=(S=this.axesGroupedByLayoutStrategy.rightOuterAxes[0])===null||S===void 0?void 0:S.offset)!==null&&_!==void 0?_:(C=this.axesGroupedByLayoutStrategy.rightInnerAxes[0])===null||C===void 0?void 0:C.offset)!==null&&P!==void 0?P:0;this.angularInnerAxesLayoutStrategy.layoutAxes(G+te,X+te,H-te,W-te,this.axesGroupedByLayoutStrategy.topInnerAxes);var oe=e.Rect.createZero();return this.axesGroupedByLayoutStrategy.topOuterAxes.length>0?oe=this.axesGroupedByLayoutStrategy.topOuterAxes[0].viewRect:this.axesGroupedByLayoutStrategy.topInnerAxes.length>0&&(oe=this.axesGroupedByLayoutStrategy.topInnerAxes[0].viewRect),this.radialOuterAxesLayoutStrategy.layoutAxes(oe.left,oe.top,oe.width,oe.height,this.axesGroupedByLayoutStrategy.rightOuterAxes),this.radialInnerAxesLayoutStrategy.layoutAxes(oe.left,oe.top,oe.width,oe.height,this.axesGroupedByLayoutStrategy.rightInnerAxes),this.sciChartSurface.seriesViewRect}finally{this.chartLayoutState.clear()}},u.prototype.groupAxesByLayoutStrategy=function(){this.axesGroupedByLayoutStrategy.clear();var c=this.axesGroupedByLayoutStrategy,d=c.topOuterAxes,f=c.topInnerAxes,h=c.rightOuterAxes,p=c.rightInnerAxes,g=function(v){v.forEach(function(y){if(y.isPolarAxis){var m=y.isAngular;m?y.isInnerAxis?f.push(y):d.push(y):y.isInnerAxis?p.push(y):h.push(y)}})};g(this.sciChartSurface.xAxes.asArray()),g(this.sciChartSurface.yAxes.asArray())},u})(r.LayoutManager);return px.PolarLayoutManager=s,px}var _me;function aie(){if(_me)return hx;_me=1;var t=hx&&hx.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(hx,"__esModule",{value:!0}),hx.SciChartPolarSurface=void 0;var e=Uo(),i=WS(),n=vs(),r=oie(),o=H3(),a=kFe(),s=tC(),l=Rg(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,h)||this;return p.layoutManager=new r.PolarLayoutManager,p}return d.create=function(f,h){if(h=l.SciChartSurface.resolveOptions(h),e.IS_TEST_ENV)return this.createPolarTest(f,h);var p=function(g,v){return new d(g,v)};return(0,o.createMultichart)(f,p,h).then(function(g){return g.sciChartSurface.applyOptions(h),g})},d.createSingle=function(f,h){if(h=l.SciChartSurface.resolveOptions(h),e.IS_TEST_ENV)return this.createPolarTest(f,h);var p=function(g,v){return new d(g,v)};return(0,a.createSingleInternal)(f,p,h).then(function(g){return g.sciChartSurface.applyOptions(h),g})},Object.defineProperty(d.prototype,"surfaceType",{get:function(){return n.ESurfaceType.SciChartPolarSurfaceType},enumerable:!1,configurable:!0}),d.createPolarTest=function(f,h){var p,g,v=s.default.initCanvas(f,(p=h==null?void 0:h.widthAspect)!==null&&p!==void 0?p:0,(g=h==null?void 0:h.heightAspect)!==null&&g!==void 0?g:0,s.default.ECanvasType.canvas2D),y=new d(l.sciChartConfig.testWasm,{canvases:v});return y.applyTheme(h==null?void 0:h.theme),y.applyOptions(h),new Promise(function(m){return m({wasmContext:y.webAssemblyContext2D,sciChartSurface:y})})},d.prototype.toJSON=function(f){f===void 0&&(f=!1);var h=c.prototype.toJSON.call(this,f);return h.type=i.ESciChartSurfaceType.Polar2D,h},d})(l.SciChartSurface);return hx.SciChartPolarSurface=u,hx}var IF={},Q0={},Pme;function Zwt(){return Pme||(Pme=1,Object.defineProperty(Q0,"__esModule",{value:!0}),Q0.polygonFormatRequiredFieldNames=Q0.ltrbFormatRequiredFieldNames=Q0.xywhFormatRequiredFieldNames=void 0,Q0.xywhFormatRequiredFieldNames=["x","y","width","height"],Q0.ltrbFormatRequiredFieldNames=["left","top","right","bottom"],Q0.polygonFormatRequiredFieldNames=["x1","x2","y1","y2"]),Q0}var Cme;function sie(){if(Cme)return IF;Cme=1,Object.defineProperty(IF,"__esModule",{value:!0}),IF.sciChartSubSurfaceCommon=void 0;var t=GV(),e=Br(),i=Rn(),n=pa(),r=Zwt(),o=kW(),a=iie(),s=Ti(),l=An(),u=tu(),c=ZP(),d=an();function f(P){var x={domChartRoot:P.domChartRoot,domCanvasWebGL:P.domCanvasWebGL,domCanvas2D:P.domCanvas2D,domSvgContainer:P.domSvgContainer,domSvgAdornerLayer:P.domSvgAdornerLayer,domDivContainer:P.domDivContainer,domBackgroundSvgContainer:P.domBackgroundSvgContainer,domSeriesBackground:P.domSeriesBackground};return x}function h(P){var x=P.renderSurface.viewportSize,E=x.width,A=x.height,R=P.offset,M=R.top,D=R.left,F=R.bottom,I=R.right,V=E-D-I>0?E-D-I:0,z=A-M-F>0?A-M-F:0;return new i.Rect(D,M,V,z)}function p(P,x){P.backgroundFillBrushCache=(0,e.deleteSafe)(P.backgroundFillBrushCache)}function g(P){var x=Array.isArray(P);if(x){if(P.length===1)return[P[0],P[0],P[0],P[0]];if(P.length===2)return[P[0],P[1],P[0],P[1]];if(P.length===4)return P;throw new Error("Invalid subChart coordinate mode provided: ".concat(P))}else return[P,P,P,P]}function v(P){var x=P.parentSurface.viewRect,E=x.width,A=x.height,R=g(P.coordinateMode),M=P.coordinateMode===o.ESubSurfacePositionCoordinateMode.DataValue||P.coordinateMode.includes(o.ESubSurfacePositionCoordinateMode.DataValue),D=P.subPosition,F=(0,a.hasProperties)(D,r.xywhFormatRequiredFieldNames),I=(0,a.hasProperties)(D,r.ltrbFormatRequiredFieldNames),V=(0,a.hasProperties)(D,r.polygonFormatRequiredFieldNames),z=P.parentSurface.seriesViewRect,G=z.left,H=z.top,U=S(P),k=U.horizontalCalc,X=U.verticalCalc,W=U.xFlipped,Y=U.yFlipped;if(F&&M){var te=R[0],oe=R[1],de=R[2],ge=R[3],Ee=D.x,Re=D.y,Ae=D.width,Pe=D.height,we=_(Ee,te,E,k,G),Te=_(Re,oe,A,X,H),ke=C(we,de,E,k,G),$e=W?ke-Ae:ke+Ae,Ne=_($e,de,E,k,G),ve=C(Te,ge,A,X,H),pe=Y?ve+Pe:ve-Pe,fe=_(pe,ge,A,X,H);return new n.Thickness(Te,E-Ne,A-fe,we)}else if(F&&!M){var te=R[0],oe=R[1],de=R[2],ge=R[3],Ee=D.x,Re=D.y,Ae=D.width,Pe=D.height,we=_(Ee,te,E),Te=_(Re,oe,A),me=_(Ae,de,E),Ce=_(Pe,ge,A),Ne=we+me,Ue=Te+Ce;return new n.Thickness(Te,E-Ne,A-Ue,we)}else if(I){var Qe=R[0],it=R[1],xt=R[2],wt=R[3],$t=D.left,Mt=D.top,$e=D.right,pe=D.bottom,we=_($t,Qe,E,k,G),Te=_(Mt,it,A,X,H),Ne=_($e,xt,E,k,G),fe=_(pe,wt,A,X,H);return new n.Thickness(Te,E-Ne,A-fe,we)}else if(V){var rt=R[0],qe=R[1],vt=R[2],kt=R[3],Xe=D.x1,_t=D.y1,Ht=D.x2,Pt=D.y2,Jt=_(Xe,rt,E,k,G),zt=_(_t,qe,A,X,H),Bt=_(Ht,vt,E,k,G),Mr=_(Pt,kt,A,X,H),we=Math.min(Jt,Bt),Te=Math.min(zt,Mr),Ne=Math.max(Jt,Bt),fe=Math.max(zt,Mr);return new n.Thickness(Te,E-Ne,A-fe,we)}throw new Error("Unexpected position format or coordinate mode ".concat(P.coordinateMode,"!"))}function y(P,x,E){if(!P.isTransparent&&P.isSubSurface){var A=E.getNativeContext(),R=P.viewRect,M=i.Rect.intersect(R,P.clipRect);E.setTranslationRotationAndClip(M,R.x,R.y),A.SetClearColor(0,0,0,0),A.Clear();try{var D=(0,s.parseColorToUIntArgb)(x),F=(0,d.getVectorRectVertex)(P.webAssemblyContext2D);F.push_back((0,c.createNativeRect)(P.webAssemblyContext2D,R.left,R.top,R.right,R.bottom));var I=(0,u.createBrushInCache)(P.backgroundFillBrushCache,x,1);E.drawRects(F,I,M,0,0)}catch{t.performanceWarnings.subchartBackgroundNotSimpleColor.warn()}}}function m(P,x){if(!(!P.parentSurface||!P.subChartContainer)){var E=(0,l.translateToNotScaledRect)(P.parentSurface.viewRect),A=E.width,R=E.height;P.subChartContainer.style.left=(0,l.convertToHtmlPx)(x.left),P.subChartContainer.style.top=(0,l.convertToHtmlPx)(x.top),P.subChartContainer.style.width=(0,l.convertToHtmlPx)(A-x.left-x.right),P.subChartContainer.style.height=(0,l.convertToHtmlPx)(R-x.top-x.bottom)}}function b(P,x){var E,A,R,M;if(!x)return n.Thickness.fromNumber(0);var D=x.getElementsByClassName(P.leftSectionClass)[0],F=x.getElementsByClassName(P.topSectionClass)[0],I=x.getElementsByClassName(P.rightSectionClass)[0],V=x.getElementsByClassName(P.bottomSectionClass)[0],z=(E=D==null?void 0:D.clientWidth)!==null&&E!==void 0?E:0,G=(A=F==null?void 0:F.clientHeight)!==null&&A!==void 0?A:0,H=(R=I==null?void 0:I.clientWidth)!==null&&R!==void 0?R:0,U=(M=V==null?void 0:V.clientHeight)!==null&&M!==void 0?M:0;return new n.Thickness((0,l.translateToScaled)(G*P.sectionScale),(0,l.translateToScaled)(H*P.sectionScale),(0,l.translateToScaled)(U*P.sectionScale),(0,l.translateToScaled)(z*P.sectionScale))}IF.sciChartSubSurfaceCommon={createSubSurfaceCanvases:f,getSubChartRect:h,deleteSubChart:p,calcPadding:v,applySciChartBackground:y,updateWrapper:m,getOffsets:b};var S=function(P){var x,E,A=P.coordinateMode===o.ESubSurfacePositionCoordinateMode.DataValue||P.coordinateMode.includes(o.ESubSurfacePositionCoordinateMode.DataValue);if(!A)return{};var R=(x=P.parentSurface.getXAxisById(P.parentXAxisId))!==null&&x!==void 0?x:P.parentSurface.getDefaultXAxis();if(!R)throw new Error("No x axis with id ".concat(P.parentXAxisId," found on parent surface"));var M=R.getCurrentCoordinateCalculator(),D=(E=P.parentSurface.getYAxisById(P.parentYAxisId))!==null&&E!==void 0?E:P.parentSurface.getDefaultYAxis();if(!D)throw new Error("No y axis with id ".concat(P.parentYAxisId," found on parent surface"));var F=D.getCurrentCoordinateCalculator(),I=R.isVerticalChart?F:M,V=R.isVerticalChart?M:F,z=R.flippedCoordinates,G=D.flippedCoordinates;return{horizontalCalc:I,verticalCalc:V,xFlipped:z,yFlipped:G}};function _(P,x,E,A,R){switch(x){case o.ESubSurfacePositionCoordinateMode.Pixel:return(0,l.translateToScaled)(P);case o.ESubSurfacePositionCoordinateMode.Relative:return E*P;case o.ESubSurfacePositionCoordinateMode.DataValue:return R+A.getCoordinate(P)}}function C(P,x,E,A,R){switch(x){case o.ESubSurfacePositionCoordinateMode.Pixel:return(0,l.translateToNotScaled)(P);case o.ESubSurfacePositionCoordinateMode.Relative:return P/E;case o.ESubSurfacePositionCoordinateMode.DataValue:return A.getDataValue(P-R)}}return IF}var Tme;function lie(){if(Tme)return dx;Tme=1;var t=dx&&dx.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(dx,"__esModule",{value:!0}),dx.SciChartPolarSubSurface=void 0;var e=Br(),i=Rn(),n=pa(),r=WS(),o=Ig(),a=rie(),s=kW(),l=iie(),u=An(),c=tu(),d=aie(),f=sie(),h=Rg(),p=(function(g){t(v,g);function v(y,m){var b=this,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U;return b=g.call(this,y,m)||this,b.isSubSurface=!0,b.topSectionClass="top-section",b.leftSectionClass="left-section",b.bottomSectionClass="bottom-section",b.rightSectionClass="right-section",b.isTransparentProperty=!0,b.clippingModeProperty=a.ESubChartClippingMode.Chart,b.subPositionProperty=new i.Rect(0,0,1,1),b.coordinateModeProperty=s.ESubSurfacePositionCoordinateMode.Relative,b.isVisibleProperty=!0,b.sectionScaleProperty=1,b.parentSurfaceProperty=m.parentSurface,b.subChartContainerId=(S=m.subSurfaceOptions)===null||S===void 0?void 0:S.subChartContainerId,b.isTransparentProperty=(C=(_=m==null?void 0:m.subSurfaceOptions)===null||_===void 0?void 0:_.isTransparent)!==null&&C!==void 0?C:b.isTransparent,b.coordinateModeProperty=(x=(P=m==null?void 0:m.subSurfaceOptions)===null||P===void 0?void 0:P.coordinateMode)!==null&&x!==void 0?x:b.coordinateMode,b.parentXAxisIdProperty=(A=(E=m==null?void 0:m.subSurfaceOptions)===null||E===void 0?void 0:E.parentXAxisId)!==null&&A!==void 0?A:b.parentXAxisId,b.parentYAxisIdProperty=(M=(R=m==null?void 0:m.subSurfaceOptions)===null||R===void 0?void 0:R.parentYAxisId)!==null&&M!==void 0?M:b.parentYAxisId,b.sectionScaleProperty=(F=(D=m==null?void 0:m.subSurfaceOptions)===null||D===void 0?void 0:D.sectionScale)!==null&&F!==void 0?F:b.sectionScaleProperty,b.isVisible=(V=(I=m==null?void 0:m.subSurfaceOptions)===null||I===void 0?void 0:I.isVisible)!==null&&V!==void 0?V:b.isVisible,b.clippingModeProperty=(G=(z=m==null?void 0:m.subSurfaceOptions)===null||z===void 0?void 0:z.clippingMode)!==null&&G!==void 0?G:b.clippingMode,b.subChartContainerId&&(b.subChartContainer=typeof b.subChartContainerId=="string"?document.querySelector("[id='".concat(b.subChartContainerId,"']")):b.subChartContainerId),b.applyOptions(m.subSurfaceOptions),b.subPosition=(U=(H=m.subSurfaceOptions)===null||H===void 0?void 0:H.position)!==null&&U!==void 0?U:b.subPositionProperty,b.backgroundFillBrushCache=new c.BrushCache(y),b}return v.createSubSurface=function(y,m){var b=f.sciChartSubSurfaceCommon.createSubSurfaceCanvases(y),S=new v(y.webAssemblyContext2D,{canvases:b,parentSurface:y,subSurfaceOptions:h.SciChartSurface.resolveOptions(m)});return m!=null&&m.theme&&S.applyTheme(m.theme),y.addSubChartInternal(S),S},Object.defineProperty(v.prototype,"viewRect",{get:function(){return this.getSubChartRect()},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"clipRect",{get:function(){return this.clippingMode===a.ESubChartClippingMode.Chart?this.parentSurface.viewRect:this.parentSurface.seriesViewRect},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"clippingMode",{get:function(){return this.clippingModeProperty},set:function(y){this.clippingModeProperty!==y&&(this.clippingModeProperty=y,this.notifyPropertyChanged("clippingMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isTransparent",{get:function(){return this.isTransparentProperty},set:function(y){this.isTransparentProperty!==y&&(this.isTransparentProperty=y,this.offset=void 0,this.notifyPropertyChanged("isTransparent"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"coordinateMode",{get:function(){return this.coordinateModeProperty},set:function(y){this.coordinateMode!==y&&(this.coordinateModeProperty=y,this.offset=void 0,this.notifyPropertyChanged("coordinateMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"parentXAxisId",{get:function(){return this.parentXAxisIdProperty},set:function(y){this.parentXAxisIdProperty!==y&&(this.parentXAxisIdProperty=y,this.offset=void 0,this.notifyPropertyChanged("parentXAxisId"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"parentYAxisId",{get:function(){return this.parentYAxisIdProperty},set:function(y){this.parentYAxisIdProperty!==y&&(this.parentYAxisIdProperty=y,this.offset=void 0,this.notifyPropertyChanged("parentYAxisId"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"subPosition",{get:function(){return this.subPositionProperty},set:function(y){if(this.subPositionProperty!==y){if(!this.parentSurface)throw new Error("subPosition can only be changed for subCharts.");(0,l.areEqual)(this.subPositionProperty,y)||(this.subPositionProperty=y,this.offset=void 0,this.notifyPropertyChanged("subPosition"))}},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(y){this.isVisibleProperty!==y&&(this.isVisibleProperty=y,this.offset=void 0,this.notifyPropertyChanged("isVisible"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"sectionScale",{get:function(){return this.sectionScaleProperty},set:function(y){this.sectionScaleProperty!==y&&(this.sectionScaleProperty=y,this.offset=void 0,this.notifyPropertyChanged("sectionScale"))},enumerable:!1,configurable:!0}),v.prototype.updateSubLayout=function(){if(!this.offset||this.coordinateMode===s.ESubSurfacePositionCoordinateMode.DataValue||this.coordinateMode.includes(s.ESubSurfacePositionCoordinateMode.DataValue)){var y=this.calcPadding(),m=new n.Thickness((0,u.translateToNotScaled)(y.top),(0,u.translateToNotScaled)(y.right),(0,u.translateToNotScaled)(y.bottom),(0,u.translateToNotScaled)(y.left));this.updateWrapper(m);var b=this.getOffsets(this.subChartContainer);this.offset=n.Thickness.mergeAdd(y,b)}},Object.defineProperty(v.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},enumerable:!1,configurable:!0}),v.prototype.changeViewportSize=function(y,m){this.offset=void 0,this.renderSurface.viewportSize=new o.Size(y,m)},v.prototype.getSubChartContainer=function(){return this.subChartContainer},v.prototype.getSubChartRect=function(){return f.sciChartSubSurfaceCommon.getSubChartRect(this)},Object.defineProperty(v.prototype,"currentWebGlRenderContext",{get:function(){return this.parentSurface.currentWebGlRenderContext},enumerable:!1,configurable:!0}),v.prototype.delete=function(y){y===void 0&&(y=!0),f.sciChartSubSurfaceCommon.deleteSubChart(this,y),this.backgroundFillBrushCache=(0,e.deleteSafe)(this.backgroundFillBrushCache),g.prototype.delete.call(this,!1)},v.prototype.getOptions=function(){var y;"toJSON"in this.themeProvider?this.themeProvider.toJSON():this.themeProvider;var m=g.prototype.getOptions.call(this),b={surfaceType:r.ESciChartSurfaceType.Polar2D,clippingMode:this.clippingMode,isTransparent:this.isTransparent,isVisible:this.isVisible,sectionScale:this.sectionScale,position:this.subPosition,subChartContainerId:typeof this.subChartContainerId=="string"?this.subChartContainerId:(y=this.subChartContainerId)===null||y===void 0?void 0:y.id,coordinateMode:this.coordinateMode,parentXAxisId:this.parentXAxisId,parentYAxisId:this.parentYAxisId},S=Object.assign(m,b);return S},v.prototype.toJSON=function(y){y===void 0&&(y=!1);var m=this.getOptions(),b={type:r.ESciChartSurfaceType.Polar2D,surface:m,xAxes:this.xAxes.asArray().map(function(S){return S.toJSON()}),yAxes:this.yAxes.asArray().map(function(S){return S.toJSON()}),series:this.renderableSeries.asArray().map(function(S){return S.toJSON(y)}),modifiers:this.chartModifiers.asArray().map(function(S){return S.toJSON()}),annotations:this.annotations.asArray().map(function(S){return S.toJSON()})};return b},v.prototype.calcPadding=function(){return f.sciChartSubSurfaceCommon.calcPadding(this)},v.prototype.applySciChartBackground=function(y,m){f.sciChartSubSurfaceCommon.applySciChartBackground(this,y,m)},v.prototype.updateWrapper=function(y){f.sciChartSubSurfaceCommon.updateWrapper(this,y)},v.prototype.getOffsets=function(y){return f.sciChartSubSurfaceCommon.getOffsets(this,y)},v})(d.SciChartPolarSurface);return dx.SciChartPolarSubSurface=p,dx}var mx={},xme;function uie(){if(xme)return mx;xme=1;var t=mx&&mx.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(mx,"__esModule",{value:!0}),mx.SciChartSubSurface=void 0;var e=Br(),i=Rn(),n=pa(),r=WS(),o=Ig(),a=rie(),s=kW(),l=iie(),u=La(),c=An(),d=tu(),f=sie(),h=Rg(),p=(function(g){t(v,g);function v(y,m){var b=this,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U;return b=g.call(this,y,m)||this,b.isSubSurface=!0,b.topSectionClass="top-section",b.leftSectionClass="left-section",b.bottomSectionClass="bottom-section",b.rightSectionClass="right-section",b.isTransparentProperty=!0,b.clippingModeProperty=a.ESubChartClippingMode.Chart,b.subPositionProperty=new i.Rect(0,0,1,1),b.coordinateModeProperty=s.ESubSurfacePositionCoordinateMode.Relative,b.isVisibleProperty=!0,b.sectionScaleProperty=1,b.parentSurfaceProperty=m.parentSurface,b.subChartContainerId=(S=m.subSurfaceOptions)===null||S===void 0?void 0:S.subChartContainerId,b.isTransparentProperty=(C=(_=m==null?void 0:m.subSurfaceOptions)===null||_===void 0?void 0:_.isTransparent)!==null&&C!==void 0?C:b.isTransparent,b.coordinateModeProperty=(x=(P=m==null?void 0:m.subSurfaceOptions)===null||P===void 0?void 0:P.coordinateMode)!==null&&x!==void 0?x:b.coordinateMode,b.parentXAxisIdProperty=(A=(E=m==null?void 0:m.subSurfaceOptions)===null||E===void 0?void 0:E.parentXAxisId)!==null&&A!==void 0?A:b.parentXAxisId,b.parentYAxisIdProperty=(M=(R=m==null?void 0:m.subSurfaceOptions)===null||R===void 0?void 0:R.parentYAxisId)!==null&&M!==void 0?M:b.parentYAxisId,b.sectionScaleProperty=(F=(D=m==null?void 0:m.subSurfaceOptions)===null||D===void 0?void 0:D.sectionScale)!==null&&F!==void 0?F:b.sectionScaleProperty,b.isVisible=(V=(I=m==null?void 0:m.subSurfaceOptions)===null||I===void 0?void 0:I.isVisible)!==null&&V!==void 0?V:b.isVisible,b.clippingModeProperty=(G=(z=m==null?void 0:m.subSurfaceOptions)===null||z===void 0?void 0:z.clippingMode)!==null&&G!==void 0?G:b.clippingMode,b.subChartContainerId&&(b.subChartContainer=typeof b.subChartContainerId=="string"?document.querySelector("[id='".concat(b.subChartContainerId,"']")):b.subChartContainerId),b.applyOptions(m.subSurfaceOptions),b.subPosition=(U=(H=m.subSurfaceOptions)===null||H===void 0?void 0:H.position)!==null&&U!==void 0?U:b.subPositionProperty,b.backgroundFillBrushCache=new d.BrushCache(y),b}return v.createSubSurface=function(y,m){var b,S=u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.AddSubSurfaceStart,{contextId:m==null?void 0:m.id,parentContextId:y.id,level:u.EPerformanceDebugLevel.Verbose}),_=f.sciChartSubSurfaceCommon.createSubSurfaceCanvases(y),C=new v(y.webAssemblyContext2D,{canvases:_,parentSurface:y,subSurfaceOptions:h.SciChartSurface.resolveOptions(m)});return m!=null&&m.theme&&C.applyTheme(m.theme),y.addSubChartInternal(C),u.PerformanceDebugHelper.mark(u.EPerformanceMarkType.AddSubSurfaceEnd,{contextId:C.id,relatedId:(b=S==null?void 0:S.detail)===null||b===void 0?void 0:b.relatedId,parentContextId:y.id,level:u.EPerformanceDebugLevel.Verbose}),C},Object.defineProperty(v.prototype,"viewRect",{get:function(){return this.getSubChartRect()},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"clipRect",{get:function(){return this.clippingMode===a.ESubChartClippingMode.Chart?this.parentSurface.viewRect:this.parentSurface.seriesViewRect},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"clippingMode",{get:function(){return this.clippingModeProperty},set:function(y){this.clippingModeProperty!==y&&(this.clippingModeProperty=y,this.notifyPropertyChanged("clippingMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isTransparent",{get:function(){return this.isTransparentProperty},set:function(y){this.isTransparentProperty!==y&&(this.isTransparentProperty=y,this.offset=void 0,this.notifyPropertyChanged("isTransparent"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"coordinateMode",{get:function(){return this.coordinateModeProperty},set:function(y){this.coordinateMode!==y&&(this.coordinateModeProperty=y,this.offset=void 0,this.notifyPropertyChanged("coordinateMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"parentXAxisId",{get:function(){return this.parentXAxisIdProperty},set:function(y){this.parentXAxisIdProperty!==y&&(this.parentXAxisIdProperty=y,this.offset=void 0,this.notifyPropertyChanged("parentXAxisId"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"parentYAxisId",{get:function(){return this.parentYAxisIdProperty},set:function(y){this.parentYAxisIdProperty!==y&&(this.parentYAxisIdProperty=y,this.offset=void 0,this.notifyPropertyChanged("parentYAxisId"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"subPosition",{get:function(){return this.subPositionProperty},set:function(y){if(this.subPositionProperty!==y){if(!this.parentSurface)throw new Error("subPosition can only be changed for subCharts.");(0,l.areEqual)(this.subPositionProperty,y)||(this.subPositionProperty=y,this.offset=void 0,this.notifyPropertyChanged("subPosition"))}},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(y){this.isVisibleProperty!==y&&(this.isVisibleProperty=y,this.offset=void 0,this.notifyPropertyChanged("isVisible"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"sectionScale",{get:function(){return this.sectionScaleProperty},set:function(y){this.sectionScaleProperty!==y&&(this.sectionScaleProperty=y,this.offset=void 0,this.notifyPropertyChanged("sectionScale"))},enumerable:!1,configurable:!0}),v.prototype.updateSubLayout=function(){if(!this.offset||this.coordinateMode===s.ESubSurfacePositionCoordinateMode.DataValue||this.coordinateMode.includes(s.ESubSurfacePositionCoordinateMode.DataValue)){var y=this.calcPadding(),m=new n.Thickness((0,c.translateToNotScaled)(y.top),(0,c.translateToNotScaled)(y.right),(0,c.translateToNotScaled)(y.bottom),(0,c.translateToNotScaled)(y.left));this.updateWrapper(m);var b=this.getOffsets(this.subChartContainer);this.offset=n.Thickness.mergeAdd(y,b)}},Object.defineProperty(v.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},enumerable:!1,configurable:!0}),v.prototype.changeViewportSize=function(y,m){this.offset=void 0,this.renderSurface.viewportSize=new o.Size(y,m)},v.prototype.getSubChartContainer=function(){return this.subChartContainer},v.prototype.getSubChartRect=function(){return f.sciChartSubSurfaceCommon.getSubChartRect(this)},Object.defineProperty(v.prototype,"currentWebGlRenderContext",{get:function(){return this.parentSurface.currentWebGlRenderContext},enumerable:!1,configurable:!0}),v.prototype.delete=function(y){y===void 0&&(y=!0),f.sciChartSubSurfaceCommon.deleteSubChart(this,y),this.backgroundFillBrushCache=(0,e.deleteSafe)(this.backgroundFillBrushCache),g.prototype.delete.call(this,!1)},v.prototype.getOptions=function(){var y,m=g.prototype.getOptions.call(this),b={surfaceType:r.ESciChartSurfaceType.Default2D,clippingMode:this.clippingMode,isTransparent:this.isTransparent,isVisible:this.isVisible,sectionScale:this.sectionScale,position:this.subPosition,subChartContainerId:typeof this.subChartContainerId=="string"?this.subChartContainerId:(y=this.subChartContainerId)===null||y===void 0?void 0:y.id,coordinateMode:this.coordinateMode,parentXAxisId:this.parentXAxisId,parentYAxisId:this.parentYAxisId},S=Object.assign(m,b);return S},v.prototype.toJSON=function(y){y===void 0&&(y=!1);var m=this.getOptions(),b={type:r.ESciChartSurfaceType.Default2D,surface:m,xAxes:this.xAxes.asArray().map(function(S){return S.toJSON()}),yAxes:this.yAxes.asArray().map(function(S){return S.toJSON()}),series:this.renderableSeries.asArray().map(function(S){return S.toJSON(y)}),modifiers:this.chartModifiers.asArray().map(function(S){return S.toJSON()}),annotations:this.annotations.asArray().map(function(S){return S.toJSON()})};return b},v.prototype.calcPadding=function(){return f.sciChartSubSurfaceCommon.calcPadding(this)},v.prototype.applySciChartBackground=function(y,m){f.sciChartSubSurfaceCommon.applySciChartBackground(this,y,m)},v.prototype.updateWrapper=function(y){f.sciChartSubSurfaceCommon.updateWrapper(this,y)},v.prototype.getOffsets=function(y){return f.sciChartSubSurfaceCommon.getOffsets(this,y)},v})(h.SciChartSurface);return mx.SciChartSubSurface=p,mx}var Eme;function zy(){return Eme||(Eme=1,(function(t){var e=kF&&kF.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.getLegendContainerHtml=t.getLegendItemHtml=t.SciChartLegendBase=t.ELegendType=t.ELegendPlacement=t.ELegendOrientation=void 0;var i=Uo(),n=fo(),r=Ig(),o=fJ(),a=lie(),s=uie(),l;(function(h){h.Vertical="Vertical",h.Horizontal="Horizontal"})(l=t.ELegendOrientation||(t.ELegendOrientation={}));var u;(function(h){h.TopLeft="TopLeft",h.TopRight="TopRight",h.BottomLeft="BottomLeft",h.BottomRight="BottomRight"})(u=t.ELegendPlacement||(t.ELegendPlacement={})),(function(h){h.SciChartLegend="SciChartLegend",h.ManualLegend="ManualLegend",h.SciChartPieLegend="SciChartPieLegend",h.SciChart3DLegend="SciChart3DLegend"})(t.ELegendType||(t.ELegendType={}));var c=(function(h){e(p,h);function p(g){var v=this,y,m,b,S,_;return v=h.call(this)||this,v.orientationProperty=l.Vertical,v.showLegendProperty=!0,v.placementProperty=u.TopLeft,v.marginProperty=10,v.isDirty=!0,v.eventListenersCollection=new Map,v.removeEventListenerFromSeries=function(C){var P;(P=v.eventListenersCollection.get(C))===null||P===void 0||P.forEach(function(x){var E=x.element,A=x.eventListener,R=x.eventType;E.removeEventListener(R,A)}),v.eventListenersCollection.delete(C)},v.orientationProperty=(y=g==null?void 0:g.orientation)!==null&&y!==void 0?y:v.orientationProperty,v.showLegendProperty=(m=g==null?void 0:g.showLegend)!==null&&m!==void 0?m:v.showLegend,v.placementProperty=(b=g==null?void 0:g.placement)!==null&&b!==void 0?b:v.placement,v.marginProperty=(S=g==null?void 0:g.margin)!==null&&S!==void 0?S:v.margin,v.placementDivIdProperty=(_=g==null?void 0:g.placementDivId)!==null&&_!==void 0?_:v.placementDivId,v.backgroundColorProperty=g==null?void 0:g.backgroundColor,v.textColorProperty=g==null?void 0:g.textColor,v.update=v.update.bind(v),v.onResize=v.onResize.bind(v),v}return p.prototype.setInvalidateParentSurface=function(g){this.invalidateParentSurface=g},p.prototype.setRootDiv=function(g){this.rootDiv=g},p.prototype.setSeriesViewRect=function(g){},p.prototype.setParentSurface=function(g){this.parentSurfaceProperty=g},p.prototype.attachTo=function(g){this.setParentSurface(g),this.setRootDiv(g.domDivContainer),this.setInvalidateParentSurface(g.invalidateElement),g.rendered.subscribe(this.update),(g instanceof s.SciChartSubSurface||g instanceof a.SciChartPolarSubSurface)&&(this.lastViewportSize=g.renderSurface.viewportSize,g.preRender.subscribe(this.onResize))},p.prototype.detach=function(){this.setRootDiv(void 0),this.parentSurfaceProperty.rendered.unsubscribe(this.update),this.lastViewportSize&&this.parentSurfaceProperty.preRender.unsubscribe(this.onResize),this.setInvalidateParentSurface(void 0),this.setParentSurface(void 0),this.delete()},p.prototype.onResize=function(){var g=this.parentSurface.renderSurface.viewportSize;r.Size.isEqual(this.lastViewportSize,g)||(this.invalidateLegend(),this.lastViewportSize=g)},p.prototype.update=function(){if(!(!this.isDirty&&this.div))try{this.clear(),this.showLegend&&this.create(),this.isDirty=!1}catch{}},p.prototype.invalidateLegend=function(){this.isDirty=!0},Object.defineProperty(p.prototype,"orientation",{get:function(){return this.orientationProperty},set:function(g){this.orientationProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"showLegend",{get:function(){return this.showLegendProperty},set:function(g){this.showLegendProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"placement",{get:function(){return this.placementProperty},set:function(g){this.placementProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"margin",{get:function(){return this.marginProperty},set:function(g){this.marginProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(g){this.clear(),this.placementDivIdProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"backgroundColor",{get:function(){return this.backgroundColorProperty},set:function(g){this.backgroundColorProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"textColor",{get:function(){return this.textColorProperty},set:function(g){this.textColorProperty=g,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},enumerable:!1,configurable:!0}),p.prototype.clear=function(){var g;this.div&&(this.removeEventListeners(),(g=this.parentDiv)===null||g===void 0||g.removeChild(this.div),this.div=void 0,this.parentDiv=void 0)},p.prototype.delete=function(){this.clear()},p.prototype.isExternal=function(){return!!this.placementDivId},p.prototype.getLegendHTML=function(g,v,y,m,b,S,_,C){var P=this,x=C.reduce(function(E,A){var R;return E+P.getLegendItemHTML(b,S,(R=A.showMarker)!==null&&R!==void 0?R:_,A)},"");return(0,t.getLegendContainerHtml)(g,v,y,m,x,this.isExternal())},p.prototype.getLegendItemHTML=function(g,v,y,m){return(0,t.getLegendItemHtml)(g,v,y,m)},p.prototype.notifyPropertyChanged=function(){this.isDirty=!0,this.invalidateParentSurface&&this.invalidateParentSurface()},p.prototype.create=function(){var g=this.getInnerHTML();if(g){var v=(0,o.htmlToElement)(g);this.parentDiv=this.getParentDiv(),this.parentDiv.appendChild(v),this.div=v,i.IS_TEST_ENV||this.addEventListeners()}},p.prototype.getParentDiv=function(){return this.placementDivId?typeof this.placementDivId=="string"?document.querySelector("[id='".concat(this.placementDivId,"']")):this.placementDivId:this.rootDiv},p})(n.DeletableEntity);t.SciChartLegendBase=c;var d=function(h,p,g,v){var y=h===l.Vertical?"flex":"inline-flex",m='<span class="scichart__legend-item" style="display: '.concat(y,'; align-items: center; margin-right: 4px; white-space: nowrap;">');if(p){var b=v.checked?"checked":"";m+="<input ".concat(b,' type="checkbox" id="').concat(v.id,'">')}if(g)if(v.gradient){var S="";v.gradient.gradientStops.forEach(function(_){S+=",".concat(_.color)}),m+='<label for="'.concat(v.id,'" style="background-image: linear-gradient(to right').concat(S,'); margin: 4px; width: 30px; height: 13px;"></label>')}else m+='<label for="'.concat(v.id,'" style="background-color: ').concat(v.color,'; margin: 4px; width: 30px; height: 13px;"></label>');return m+='<label for="'.concat(v.id,'" style="margin-left: 4px;">').concat(v.name,"</label>"),m+="</span>",m};t.getLegendItemHtml=d;var f=function(h,p,g,v,y,m){if(m===void 0&&(m=!1),!y)return"";var b="",S="";m||(b="position: absolute;"),h===u.TopLeft?S="left: 0; top: 0;":h===u.TopRight?S="right: 0; top: 0;":h===u.BottomLeft?S="left: 0; bottom: 0;":h===u.BottomRight&&(S="right: 0; bottom: 0;");var _='<div class="scichart__legend" style="height: 100%; '.concat(b," display: flex; ").concat(S,' text-align: center;">'),C=[u.TopLeft,u.TopRight].includes(h)?"flex-start":"flex-end",P=v.left,x=v.right,E=v.bottom,A=v.top,R="margin-left: ".concat(P,"px; margin-top: ").concat(A,"px; margin-right: ").concat(x,"px; margin-bottom: ").concat(E,"px;");return _+='<div style="display: block; align-self: '.concat(C,"; width: fit-content; pointer-events: auto; ").concat(R," padding: 5px; border-radius: 3px; background-color: ").concat(g,"; color: ").concat(p,'">'),_+=y,_+="</div></div>",_};t.getLegendContainerHtml=f})(kF)),kF}var wme;function aBe(){if(wme)return ux;wme=1;var t=ux&&ux.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(ux,"__esModule",{value:!0}),ux.SciChartPieLegend=void 0;var e=pa(),i=GO(),n=zy(),r=(function(a){t(s,a);function s(){var l=a!==null&&a.apply(this,arguments)||this;return l.type=n.ELegendType.SciChartPieLegend,l.animate=!0,l.showCheckboxesProperty=!1,l.showSeriesMarkersProperty=!0,l}return Object.defineProperty(s.prototype,"showCheckboxes",{get:function(){return this.showCheckboxesProperty},set:function(l){this.showCheckboxesProperty=l,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"showSeriesMarkers",{get:function(){return this.showSeriesMarkersProperty},set:function(l){this.showSeriesMarkersProperty=l,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),s.prototype.applyTheme=function(){},s.prototype.setPieSegmentArray=function(l){this.pieSegmentArray=l},s.prototype.update=function(){this.clear(),this.showLegend&&this.create()},s.prototype.addEventListeners=function(){var l=this;this.pieSegmentArray.forEach(function(u){var c=l.parentDiv.querySelector("#".concat(o(u.id)));if(c){var d=(0,i.addEventListenerToPieSegment)(u,c,l.animate),f=l.eventListenersCollection.get(u.id);f?f.push(d):l.eventListenersCollection.set(u.id,[d])}})},s.prototype.removeEventListeners=function(){var l=this;this.pieSegmentArray.forEach(function(u){return l.removeEventListenerFromSeries(u.id)})},s.prototype.getInnerHTML=function(){var l=this.parentSurfaceProperty.themeProvider.legendBackgroundBrush,u=this.parentSurfaceProperty.themeProvider.labelForegroundBrush,c=this.pieSegmentArray.map(function(f,h){var p;return{id:o(f.id),name:(p=f.text)!==null&&p!==void 0?p:"Segment ".concat(h+1),color:f.color,checked:f.isSelected,gradient:f.colorLinearGradient}}),d=new e.Thickness(this.margin,this.margin,this.margin,this.margin);return this.getLegendHTML(this.placement,u,l,d,this.orientation,this.showCheckboxes,this.showSeriesMarkers,c)},s})(n.SciChartLegendBase);ux.SciChartPieLegend=r;var o=function(a){return"check".concat(a)};return ux}var k9={},Ame;function Jwt(){return Ame||(Ame=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.HOLE_RADIUS="HOLE_RADIUS",e.HOLE_RADIUS_SIZING_MODE="HOLE_RADIUS_SIZING_MODE",e.PIE_TYPE="PIE_TYPE",e.SERIES_SPACING="SERIES_SPACING",e.PADDING="PADDING",e.CANVAS_BORDER="CANVAS_BORDER",e.LABEL_PROVIDER="LABEL_PROVIDER",e.VALUE_MODE="VALUE_MODE",e.LABEL_RADIUS="LABEL_RADIUS",e.TEXT_STYLE="TEXT_STYLE"})(t.PROPERTY||(t.PROPERTY={}))})(k9)),k9}var I9={},Ome;function sBe(){return Ome||(Ome=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.COLOR="COLOR",e.COLOR_LINEAR_GRADIENT="COLOR_LINEAR_GRADIENT",e.DELTA="DELTA",e.IS_SELECTED="IS_SELECTED",e.PERCENTAGE="PERCENTAGE",e.TEXT="TEXT",e.VALUE="VALUE",e.SHIFT="SHIFT",e.LABEL_PROVIDER="LABEL_PROVIDER",e.LABEL_STYLE="LABEL_STYLE",e.LABEL_OFFSET="LABEL_OFFSET",e.RADIUS_ADJUSTMENT="RADIUS_ADJUSTMENT",e.SHOW_LABEL="SHOW_LABEL"})(t.PROPERTY||(t.PROPERTY={}))})(I9)),I9}var Dme;function GO(){return Dme||(Dme=1,(function(t){var e=J0&&J0.__extends||(function(){var U=function(k,X){return U=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(W,Y){W.__proto__=Y}||function(W,Y){for(var te in Y)Object.prototype.hasOwnProperty.call(Y,te)&&(W[te]=Y[te])},U(k,X)};return function(k,X){if(typeof X!="function"&&X!==null)throw new TypeError("Class extends value "+String(X)+" is not a constructor or null");U(k,X);function W(){this.constructor=k}k.prototype=X===null?Object.create(X):(W.prototype=X.prototype,new W)}})(),i=J0&&J0.__assign||function(){return i=Object.assign||function(U){for(var k,X=1,W=arguments.length;X<W;X++){k=arguments[X];for(var Y in k)Object.prototype.hasOwnProperty.call(k,Y)&&(U[Y]=k[Y])}return U},i.apply(this,arguments)},n=J0&&J0.__spreadArray||function(U,k,X){if(X||arguments.length===2)for(var W=0,Y=k.length,te;W<Y;W++)(te||!(W in k))&&(te||(te=Array.prototype.slice.call(k,0,W)),te[W]=k[W]);return U.concat(te||Array.prototype.slice.call(k))};Object.defineProperty(t,"__esModule",{value:!0}),t.addEventListenerToPieSegment=t.SciChartPieSurface=t.EPieValueMode=t.EPieType=t.ESizingMode=void 0;var r=mo(),o=Uo(),a=ad(),s=Br(),l=$v(),u=DP(),c=Rn(),d=ga(),f=WS(),h=vs(),p=Vf(),g=hl(),v=uW(),y=gl(),m=IW(),b=aBe(),S=tC(),_=Sn(),C=Ere(),P=Zi(),x=Jwt(),E=sBe(),A=Math.PI/180,R=90,M;(function(U){U.Absolute="Absolute",U.Relative="Relative"})(M=t.ESizingMode||(t.ESizingMode={}));var D;(function(U){U.Pie="Pie",U.Donut="Donut"})(D=t.EPieType||(t.EPieType={}));var F;(function(U){U.Percentage="Percentage",U.Raw="Raw"})(F=t.EPieValueMode||(t.EPieValueMode={}));var I=(function(U){e(k,U);function k(X,W){X===void 0&&(X={});var Y=this,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e,Ne,ve,pe,fe;Y=U.call(this,X)||this,Y.animate=!0,Y.animationFrames=30,Y.surfaceType=h.ESurfaceType.SciChartPieSurfaceType,Y.pieTypeProperty=D.Pie,Y.holeRadiusProperty=.5,Y.holeRadiusSizingModeProperty=M.Relative,Y.seriesSpacingProperty=0,Y.labelRadiusProperty=1,Y.titleDivs=[],Y.sweepAnimationDone=!1,Y.suspendUpdate=!1,Y.themeProviderProperty=new v.SciChartJSDarkTheme,Y.previousThemeProviderProperty=new v.SciChartJSDarkTheme,Y.valueModeProperty=F.Percentage,Y.labelStyleProperty={fontSize:14,fontFamily:(0,p.getDefaultFontName)(),color:"#1e323d",fontWeight:"bold"},Y.id=(te=W==null?void 0:W.id)!==null&&te!==void 0?te:(0,g.generateGuid)();var me=Y.domCanvas2D.width/P.DpiHelper.PIXEL_RATIO,Ce=Y.domCanvas2D.height/P.DpiHelper.PIXEL_RATIO;return Y.viewRectProperty=new c.Rect(0,0,me,Ce),o.IS_TEST_ENV||(Y.resizeSubscriptionToken=S.default.subscribeToResize(X.domCanvas2D,X.aspect,Y)),Y.drawChart=Y.drawChart.bind(Y),Y.deleteInternals=Y.deleteInternals.bind(Y),Y.invalidateElement=Y.invalidateElement.bind(Y),Y.detachPieSegment=Y.detachPieSegment.bind(Y),Y.attachPieSegment=Y.attachPieSegment.bind(Y),Y.pieSegments=new u.ObservableArray,o.IS_TEST_ENV||Y.pieSegments.collectionChanged.subscribe(function(Ue){var Qe,it;(Qe=Ue.getOldItems())===null||Qe===void 0||Qe.forEach(Y.detachPieSegment),(it=Ue.getNewItems())===null||it===void 0||it.forEach(Y.attachPieSegment),Y.invalidateElement()}),Y.applySciChartBackground(_.SciChartSurfaceBase.DEFAULT_THEME.sciChartBackground),Y.legend=new b.SciChartPieLegend,Y.legend.setRootDiv(Y.domDivContainer),Y.legend.setPieSegmentArray(Y.pieSegments.asArray()),Y.legend.setInvalidateParentSurface(Y.invalidateElement),Y.legend.setParentSurface(Y),Y.heightAspect=(oe=W==null?void 0:W.heightAspect)!==null&&oe!==void 0?oe:0,Y.widthAspect=(de=W==null?void 0:W.widthAspect)!==null&&de!==void 0?de:0,Y.pieTypeProperty=(ge=W==null?void 0:W.pieType)!==null&&ge!==void 0?ge:Y.pieType,Y.holeRadiusProperty=(Ee=W==null?void 0:W.holeRadius)!==null&&Ee!==void 0?Ee:Y.holeRadius,Y.animate=(Re=W==null?void 0:W.animate)!==null&&Re!==void 0?Re:Y.animate,Y.holeRadiusSizingModeProperty=(Ae=W==null?void 0:W.holeRadiusSizingMode)!==null&&Ae!==void 0?Ae:Y.holeRadiusSizingModeProperty,Y.seriesSpacingProperty=(Pe=W==null?void 0:W.seriesSpacing)!==null&&Pe!==void 0?Pe:Y.seriesSpacingProperty,Y.labelRadiusProperty=(we=W==null?void 0:W.labelRadiusAdjustment)!==null&&we!==void 0?we:Y.labelRadiusProperty,Y.legend.showLegend=(Te=W==null?void 0:W.showLegend)!==null&&Te!==void 0?Te:Y.legend.showLegend,Y.legend.animate=(ke=W==null?void 0:W.animateLegend)!==null&&ke!==void 0?ke:Y.legend.animate,Y.legend.showCheckboxes=($e=W==null?void 0:W.showLegendCheckBoxes)!==null&&$e!==void 0?$e:Y.legend.showCheckboxes,Y.legend.showSeriesMarkers=(Ne=W==null?void 0:W.showLegendSeriesMarkers)!==null&&Ne!==void 0?Ne:Y.legend.showSeriesMarkers,Y.paddingProperty=(ve=W==null?void 0:W.padding)!==null&&ve!==void 0?ve:Y.paddingProperty,W!=null&&W.labelProvider&&("getSegmentText"in(W==null?void 0:W.labelProvider)||(W.labelProvider=(0,r.createType)(d.EBaseType.LabelProvider,W.labelProvider.type,void 0,W.labelProvider.options))),Y.labelProvider=(pe=W==null?void 0:W.labelProvider)!==null&&pe!==void 0?pe:new m.PieLabelProvider,Y.valueModeProperty=(fe=W==null?void 0:W.valueMode)!==null&&fe!==void 0?fe:Y.valueModeProperty,Y}return k.create=function(X,W){var Y,te,oe=S.default.initCanvas(X,(Y=W==null?void 0:W.widthAspect)!==null&&Y!==void 0?Y:0,(te=W==null?void 0:W.heightAspect)!==null&&te!==void 0?te:0,S.default.ECanvasType.svg,void 0,W==null?void 0:W.touchAction);return new Promise(function(de){var ge,Ee,Re,Ae=n(n(n(n([],l.sciChartDestinations,!0),l.sciChart3DDestinations,!0),l.sciChartSingleDestinations,!0),l.sciChartPieDestinations,!0).filter(function(we){return we.sciChartSurface.domChartRoot.id===oe.domChartRoot.id});Ae.forEach(function(we){return we.sciChartSurface.delete()}),W=_.SciChartSurfaceBase.resolveOptions(W);var Pe=new k(oe,W);Pe.applyTheme(W==null?void 0:W.theme),l.sciChartPieDestinations.push({canvasElementId:(ge=oe.domCanvas2D)===null||ge===void 0?void 0:ge.id,sciChartSurface:Pe,width:(Ee=oe.domCanvas2D)===null||Ee===void 0?void 0:Ee.width,height:(Re=oe.domCanvas2D)===null||Re===void 0?void 0:Re.height}),Pe.setDestinations(l.sciChartPieDestinations),setTimeout(function(){return de(Pe)},0)})},Object.defineProperty(k.prototype,"isDeleted",{get:function(){return this.isDeletedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"labelProvider",{get:function(){return this.labelProviderProperty},set:function(X){X&&this.labelProviderProperty!==X&&(this.labelProviderProperty=X,this.notifyPropertyChanged(x.PROPERTY.LABEL_PROVIDER))},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"labelStyle",{get:function(){return this.labelStyleProperty},set:function(X){this.labelStyleProperty=i(i({},this.labelStyle),X),this.notifyPropertyChanged(x.PROPERTY.TEXT_STYLE)},enumerable:!1,configurable:!0}),k.prototype.applyTheme=function(X){this.previousThemeProviderProperty=this.themeProviderProperty,this.themeProviderProperty=X,this.applySciChartBackground(X.sciChartBackground),this.labelStyle.color===this.previousThemeProvider.tickTextBrush&&(this.labelStyle={color:X.tickTextBrush}),this.invalidateElement()},Object.defineProperty(k.prototype,"themeProvider",{get:function(){return this.themeProviderProperty},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"previousThemeProvider",{get:function(){return this.previousThemeProviderProperty},enumerable:!1,configurable:!0}),k.prototype.setDestinations=function(X){this.destinations=X},k.prototype.invalidateElement=function(X){this.isValidToDraw()&&(typeof X=="string"&&X===E.PROPERTY.VALUE&&(this.sweepAnimationDone=!1),this.update())},k.prototype.update=function(){var X;this.suspendUpdate||(this.draw(),(X=this.legend)===null||X===void 0||X.update())},k.prototype.delete=function(){var X=this,W;this.deleteInternals(),this.legend=(0,s.deleteSafe)(this.legend),this.labelProvider=(0,s.deleteSafe)(this.labelProvider),this.resizeSubscriptionToken=(0,s.deleteSafe)(this.resizeSubscriptionToken);var Y=(W=this.destinations)===null||W===void 0?void 0:W.findIndex(function(te){return te.sciChartSurface.id===X.id});Y>=0&&this.destinations.splice(Y,1),this.isDeletedProperty=!0},k.prototype.deleteInternals=function(X){var W=this;this.svg&&(this.domSvgContainer.removeChild(this.svg),this.svg=void 0),X||(this.titleDivs.forEach(function(de){W.domDivContainer.removeChild(de)}),this.titleDivs=[]);for(var Y=0,te=this.deletables;Y<te.length;Y++){var oe=te[Y];(0,s.deleteSafe)(oe)}this.deletables=[]},k.prototype.changeViewportSize=function(X,W){var Y=X,te=W;this.viewRectProperty=new c.Rect(0,0,X,W),this.changeDomViewportSize(Y,te),this.invalidateElement()},Object.defineProperty(k.prototype,"pieType",{get:function(){return this.pieTypeProperty},set:function(X){this.pieTypeProperty=X,this.notifyPropertyChanged(x.PROPERTY.PIE_TYPE)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"holeRadius",{get:function(){return this.holeRadiusProperty},set:function(X){this.holeRadiusProperty=X,this.notifyPropertyChanged(x.PROPERTY.HOLE_RADIUS)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"holeRadiusSizingMode",{get:function(){return this.holeRadiusSizingModeProperty},set:function(X){this.holeRadiusSizingModeProperty=X,this.notifyPropertyChanged(x.PROPERTY.HOLE_RADIUS_SIZING_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"padding",{get:function(){return this.paddingProperty},set:function(X){this.paddingProperty!==X&&(this.paddingProperty=X,this.updateLegendMargin(),this.notifyPropertyChanged(x.PROPERTY.PADDING))},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"canvasBorder",{get:function(){return this.canvasBorderProperty},set:function(X){this.canvasBorderProperty!==X&&(this.canvasBorderProperty=X,this.updateLegendMargin(),this.notifyPropertyChanged(x.PROPERTY.PADDING))},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"seriesSpacing",{get:function(){return this.seriesSpacingProperty},set:function(X){this.seriesSpacingProperty!==X&&(this.seriesSpacingProperty=X,this.notifyPropertyChanged(x.PROPERTY.SERIES_SPACING))},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"valueMode",{get:function(){return this.valueModeProperty},set:function(X){this.valueModeProperty=X,this.notifyPropertyChanged(x.PROPERTY.VALUE_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"labelRadiusAdjustment",{get:function(){return this.labelRadiusProperty},set:function(X){this.labelRadiusProperty=X,this.notifyPropertyChanged(x.PROPERTY.VALUE_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(k.prototype,"viewRect",{get:function(){return this.viewRectProperty},enumerable:!1,configurable:!0}),k.prototype.getOptions=function(){var X;"toJSON"in this.themeProvider?X=this.themeProvider.toJSON():X=this.themeProvider;var W={animate:this.animate,animateLegend:this.legend.animate,heightAspect:this.heightAspect,widthAspect:this.widthAspect,holeRadius:this.holeRadius,holeRadiusSizingMode:this.holeRadiusSizingMode,pieType:this.pieType,showLegend:this.legend.showLegend,showLegendCheckBoxes:this.legend.showCheckboxes,showLegendSeriesMarkers:this.legend.showSeriesMarkers,padding:this.padding,canvasBorder:this.canvasBorder,seriesSpacing:this.seriesSpacing,labelProvider:this.labelProvider.toJSON(),valueMode:this.valueMode,labelRadiusAdjustment:this.labelRadiusAdjustment,animationFrames:this.animationFrames,theme:X};return W},k.prototype.toJSON=function(X){X===void 0&&(X=!1);var W=this.getOptions(),Y={type:f.ESciChartSurfaceType.Pie2D,surface:W,onCreated:this.onCreatedName,segments:X?void 0:this.pieSegments.asArray().map(function(te){return te.toJSON()})};return Y},k.prototype.calcTitlePosition=function(X,W,Y,te,oe,de,ge,Ee,Re){var Ae=te<Y/2?Y*2/3+te/6:(Y+te)/2,Pe=(oe+de)/2,we=X+Math.cos(A*Pe)*(Ae*this.labelRadiusProperty+ge)-Ee/2,Te=W+Math.sin(A*Pe)*(Ae*this.labelRadiusProperty+ge)-Re/2;return{left:we,top:Te}},k.prototype.changeDomViewportSize=function(X,W){this.domSvgContainer&&(this.domSvgContainer.setAttribute("width",X.toString()),this.domSvgContainer.setAttribute("height",W.toString())),this.domSvgAdornerLayer&&(this.domSvgAdornerLayer.setAttribute("width",X.toString()),this.domSvgAdornerLayer.setAttribute("height",W.toString()))},k.prototype.notifyPropertyChanged=function(X){this.invalidateElement(),X===x.PROPERTY.LABEL_PROVIDER&&this.labelProviderProperty&&this.labelProviderProperty.attachedToSurface(this)},k.prototype.isValidToDraw=function(){return!0},k.prototype.detachPieSegment=function(X){X.onDetach()},k.prototype.attachPieSegment=function(X){X.onAttach(this)},k.prototype.updateLegendMargin=function(){var X,W,Y,te=((X=this.padding)===null||X===void 0?void 0:X.top)||0,oe=((W=this.canvasBorder)===null||W===void 0?void 0:W.border)||((Y=this.canvasBorder)===null||Y===void 0?void 0:Y.borderTop)||0;this.legend.margin=te+oe+10},k.prototype.calculateViewRectWidth=function(X){var W,Y,te,oe,de;return!((W=this.padding)===null||W===void 0)&&W.left&&(X-=this.padding.left),!((Y=this.padding)===null||Y===void 0)&&Y.right&&(X-=this.padding.right),!((te=this.canvasBorder)===null||te===void 0)&&te.border?X-=this.canvasBorder.border*2:(!((oe=this.canvasBorder)===null||oe===void 0)&&oe.borderLeft&&(X-=this.canvasBorder.borderLeft),!((de=this.canvasBorder)===null||de===void 0)&&de.borderRight&&(X-=this.canvasBorder.borderRight)),X},k.prototype.calculateViewRectHeight=function(X){var W,Y,te,oe,de;return!((W=this.padding)===null||W===void 0)&&W.top&&(X-=this.padding.top),!((Y=this.padding)===null||Y===void 0)&&Y.bottom&&(X-=this.padding.bottom),!((te=this.canvasBorder)===null||te===void 0)&&te.border?X-=this.canvasBorder.border*2:(!((oe=this.canvasBorder)===null||oe===void 0)&&oe.borderTop&&(X-=this.canvasBorder.borderTop),!((de=this.canvasBorder)===null||de===void 0)&&de.borderBottom&&(X-=this.canvasBorder.borderBottom)),X},k.prototype.draw=function(){var X=this;if(this.preRender.raiseEvent(),this.pieSegments.size()!==0){if(this.sweepAnimationDone||!this.animate)this.deleteInternals(),this.drawChart();else{var W=this.animationFrames;this.suspendUpdate=!0;var Y=function(){return X.suspendUpdate=!1},te=function(){return X.sweepAnimationDone=!0},oe=this.invalidateElement,de=this.drawChart,ge=this.deleteInternals;(function Ee(Re){setTimeout(function(){var Ae=Re/W;ge(!0),de(Ae),Re===W&&(Y(),te(),oe()),++Re<=W&&Ee(Re)},20)})(1)}o.IS_TEST_ENV||this.pieSegments.asArray().forEach(function(Ee){var Re=X.domChartRoot.querySelector("[id='".concat(Ee.id,"']"));if(Re){var Ae=(0,t.addEventListenerToPieSegment)(Ee,Re,X.animate);X.addDeletable(Ae)}}),this.rendered.raiseEvent()}},k.prototype.drawChart=function(X){var W=this;X===void 0&&(X=1);var Y=this.pieSegmentsTotalValue();if(Y){var te=2,oe=this.themeProviderProperty.sciChartBackground,de=this.pieSegments.asArray(),ge=this.pieSegmentsTotalOldValue(),Ee=Math.min(this.calculateViewRectWidth(this.viewRect.width),this.calculateViewRectHeight(this.viewRect.height))*.8/2,Re=0;this.pieType===D.Donut&&(Re=this.holeRadiusSizingMode===M.Absolute?this.holeRadius:Ee*this.holeRadius);var Ae=this.calculateViewRectWidth(this.viewRect.width)/2,Pe=this.calculateViewRectHeight(this.viewRect.height)/2,we="<defs>",Te="",ke=0,$e=0;de.forEach(function(pe,fe){var me;if(pe.value!==0){var Ce=(me=pe.oldValue)!==null&&me!==void 0?me:0,Ue=360*ke/Y-R,Qe=360*(ke+pe.value)/Y-R-1e-4,it=360*$e/ge-R,xt=360*($e+Ce)/ge-R;ke+=pe.value,$e+=Ce;var wt=it+(Ue-it)*a.easing.inOutCubic(X),$t=xt+(Qe-xt)*a.easing.inOutCubic(X),Mt=!!pe.colorLinearGradient,rt="grad".concat(pe.id);if(Mt){var qe=pe.colorLinearGradient.startPoint.x*100,vt=pe.colorLinearGradient.startPoint.y*100,kt=pe.colorLinearGradient.endPoint.x*100,Xe=pe.colorLinearGradient.endPoint.y*100,_t='<linearGradient id="'.concat(rt,'" x1="').concat(qe,'%" y1="').concat(vt,'%" x2="').concat(kt,'%" y2="').concat(Xe,'%">');pe.colorLinearGradient.gradientStops.forEach(function(Jt){var zt=Jt.offset*100;_t+='<stop offset="'.concat(zt,'%" style="stop-color:').concat(Jt.color,';stop-opacity:1" />')}),_t+="</linearGradient>",we+=_t}var Ht=W.pieType===D.Donut?z(Ae,Pe,Ee*pe.radiusAdjustment,Re,wt,$t,pe.shift+W.seriesSpacing):V(Ae,Pe,Ee*pe.radiusAdjustment,wt,$t,pe.shift+W.seriesSpacing),Pt=Mt?'<g fill="url(#'.concat(rt,')"><path id="').concat(pe.id,'" stroke="').concat(oe,'" stroke-width="').concat(te,'" d="').concat(Ht,'" /></g>'):'<path id="'.concat(pe.id,'" stroke="').concat(oe,'" stroke-width="').concat(te,'" d="').concat(Ht,'" fill="').concat(pe.color,'" />');Te+=Pt,(X===1||pe.oldValue)&&W.drawSegmentLabel(pe,fe,Y,wt,$t,Ae,Pe,Ee*pe.radiusAdjustment,Re)}}),we+="</defs>",this.adjustDomContainer();var Ne='<svg width="'.concat(this.calculateViewRectWidth(this.viewRect.width),'" height="').concat(this.calculateViewRectHeight(this.viewRect.height),'">').concat(we).concat(Te,"</svg>"),ve=y.annotationHelpers.createSvg(Ne,this.domSvgContainer);this.svg=ve}},k.prototype.adjustDomContainer=function(){var X,W,Y,te,oe,de;this.padding&&this.padding.left&&(this.domSvgContainer.style.paddingLeft=this.padding.left+"px"),this.padding&&this.padding.right&&(this.domSvgContainer.style.paddingRight=this.padding.right+"px"),this.padding&&this.padding.top&&(this.domSvgContainer.style.paddingTop=this.padding.top+"px"),this.padding&&this.padding.bottom&&(this.domSvgContainer.style.paddingBottom=this.padding.bottom+"px"),this.canvasBorder&&(this.domSvgContainer.style.borderStyle="solid"),!((X=this.canvasBorder)===null||X===void 0)&&X.border&&(this.domSvgContainer.style.borderWidth=this.canvasBorder.border+"px"),!((W=this.canvasBorder)===null||W===void 0)&&W.color&&(this.domSvgContainer.style.borderColor=this.canvasBorder.color),!((Y=this.canvasBorder)===null||Y===void 0)&&Y.borderBottom&&(this.domSvgContainer.style.borderBottomWidth=this.canvasBorder.borderBottom+"px"),!((te=this.canvasBorder)===null||te===void 0)&&te.borderTop&&(this.domSvgContainer.style.borderTopWidth=this.canvasBorder.borderTop+"px"),!((oe=this.canvasBorder)===null||oe===void 0)&&oe.borderLeft&&(this.domSvgContainer.style.borderLeftWidth=this.canvasBorder.borderLeft+"px"),!((de=this.canvasBorder)===null||de===void 0)&&de.borderRight&&(this.domSvgContainer.style.borderRightWidth=this.canvasBorder.borderRight+"px")},k.prototype.drawSegmentLabel=function(X,W,Y,te,oe,de,ge,Ee,Re){var Ae,Pe,we,Te,ke,$e,Ne,ve,pe,fe,me;if(X.showLabel!==!1){var Ce="segment"+W,Ue=this.titleDivs.find(function(Mt){return Mt.id===Ce});Ue||(Ue=document.createElement("div"),Ue.className="scichart-pie-text-container",Ue.id=Ce,Ue.style.position="absolute",Ue.style.pointerEvents="none",Ue.style.padding="5px",Ue.style.borderRadius="3px",this.titleDivs.push(Ue),this.domDivContainer.appendChild(Ue),Ue.style.display="block"),Ue.style.color=X.labelStyle.color,Ue.style.fontWeight=X.labelStyle.fontWeight,Ue.style.fontFamily=(0,p.getFontFamily)(X.labelStyle.fontFamily,!1),Ue.style.fontSize=X.labelStyle.fontSize.toString()+"px",Ue.innerHTML=X.getLabelText(Y);var Qe=Ue.offsetWidth,it=Ue.offsetHeight,xt=0,wt=0;!((Ae=this.padding)===null||Ae===void 0)&&Ae.left&&(xt+=(Pe=this.padding)===null||Pe===void 0?void 0:Pe.left),!((we=this.padding)===null||we===void 0)&&we.top&&(wt+=(Te=this.padding)===null||Te===void 0?void 0:Te.top),!((ke=this.canvasBorder)===null||ke===void 0)&&ke.border?(xt+=($e=this.canvasBorder)===null||$e===void 0?void 0:$e.border,wt+=(Ne=this.canvasBorder)===null||Ne===void 0?void 0:Ne.border):(!((ve=this.canvasBorder)===null||ve===void 0)&&ve.borderLeft&&(xt+=(pe=this.canvasBorder)===null||pe===void 0?void 0:pe.borderLeft),!((fe=this.canvasBorder)===null||fe===void 0)&&fe.borderTop&&(xt+=(me=this.canvasBorder)===null||me===void 0?void 0:me.borderTop));var $t=this.calcTitlePosition(de+xt,ge+wt,Ee,Re,te,oe,X.shift+this.seriesSpacing,Qe,it);Ue.style.left="".concat($t.left+X.labelOffset.x,"px"),Ue.style.top="".concat($t.top+X.labelOffset.y,"px")}},k.prototype.pieSegmentsTotalValue=function(){return this.pieSegments.asArray().reduce(function(X,W){return X+W.value},0)},k.prototype.pieSegmentsTotalOldValue=function(){var X=this.pieSegments.asArray().reduce(function(W,Y){var te;return W+((te=Y.oldValue)!==null&&te!==void 0?te:0)},0);return X>0?X:1},k.prototype.applySciChartBackground=function(X){this.domCanvas2D.style.background=X},k})(C.SciChartSurfaceCore);t.SciChartPieSurface=I;var V=function(U,k,X,W,Y,te){var oe=Math.abs(Y-W)>180?1:0,de=(W+Y)/2,ge=Math.cos(A*de)*te,Ee=Math.sin(A*de)*te,Re=Math.cos(A*Y)*X+U+ge,Ae=Math.sin(A*Y)*X+k+Ee,Pe=Math.cos(A*W)*X+U+ge,we=Math.sin(A*W)*X+k+Ee;return Math.abs(Re-Pe)<1e-4&&(Pe+=.001),"M".concat(U+ge," ").concat(k+Ee," ").concat(Re," ").concat(Ae," A").concat(X," ").concat(X," 0 ").concat(oe," 0 ").concat(Pe," ").concat(we,"Z")},z=function(U,k,X,W,Y,te,oe){var de=Math.abs(te-Y)>180?1:0,ge=(Y+te)/2,Ee=Math.cos(A*ge)*oe,Re=Math.sin(A*ge)*oe,Ae=Math.cos(A*te)*X+U+Ee,Pe=Math.sin(A*te)*X+k+Re,we=Math.cos(A*Y)*X+U+Ee,Te=Math.sin(A*Y)*X+k+Re,ke=Math.cos(A*te)*W+U+Ee,$e=Math.sin(A*te)*W+k+Re,Ne=Math.cos(A*Y)*W+U+Ee,ve=Math.sin(A*Y)*W+k+Re;return"M".concat(Ae," ").concat(Pe," A").concat(X," ").concat(X," 0 ").concat(de," 0 ").concat(we," ").concat(Te," L").concat(Ne," ").concat(ve," A").concat(W," ").concat(W," 0 ").concat(de," 1 ").concat(ke," ").concat($e,"Z")},G=!1,H=function(U,k,X){var W=function(Y){if(!X){U.isSelected=!U.isSelected;return}if(!G){var te=10,oe=U.isSelected,de=oe?U.delta:0,ge=oe?-U.delta/te:U.delta/te;G=!0,U.isSelected=!U.isSelected,(function Ee(Re){setTimeout(function(){U.shift=de+ge*Re,Re===te&&(G=!1),++Re<=te&&Ee(Re)},20)})(1)}};return k.addEventListener("click",W),{eventListener:W,eventType:"click",element:k,delete:function(){return k.removeEventListener("click",W)}}};t.addEventListenerToPieSegment=H})(J0)),J0}var Rme;function IW(){if(Rme)return Z0;Rme=1;var t=Z0&&Z0.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=Z0&&Z0.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(Z0,"__esModule",{value:!0}),Z0.PieLabelProvider=void 0;var i=sR(),n=Fg(),r=Du(),o=GO(),a=Qre(),s=(function(l){t(u,l);function u(c){var d=this,f,h;return d=l.call(this,e({labelFormat:(f=c==null?void 0:c.labelFormat)!==null&&f!==void 0?f:n.ENumericFormat.Decimal,labelPrecision:(h=c==null?void 0:c.labelPrecision)!==null&&h!==void 0?h:2},c))||this,d.type=i.ELabelProviderType.Pie,d.formatLabelProperty=function(p){return d.applyFormat((0,r.formatNumber)(p,d.numericFormat,d.precision))+(d.parentSurface.valueMode===o.EPieValueMode.Percentage?" %":"")},d}return u.prototype.delete=function(){},u.prototype.getSegmentText=function(c,d){var f=this.parentSurface.valueMode===o.EPieValueMode.Percentage?c.getPercentage(d):c.value;return this.formatLabel(f)},u.prototype.attachedToSurface=function(c){this.parentSurface=c},u.prototype.onBeginAxisDraw=function(){},u.prototype.invalidateParent=function(){this.parentSurface&&this.parentSurface.invalidateElement&&this.parentSurface.invalidateElement()},u})(a.LabelProvider);return Z0.PieLabelProvider=s,Z0}var NF={},bx={},Mme;function lBe(){if(Mme)return bx;Mme=1;var t=bx&&bx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(bx,"__esModule",{value:!0}),bx.LogarithmicCoordinateCalculator=void 0;var e=di(),i=pl(),n=iC(),r=(function(o){t(a,o);function a(s,l,u,c,d,f,h,p){p===void 0&&(p=0);var g=this;return i.EXyDirection.XDirection,g=o.call(this,s,l,u,c,p,h)||this,g.logBaseProperty=f,g.nativeCalculator=h?new s.FlippedLogarithmicCoordinateCalculator(g.viewportDimension,g.visibleMin,g.visibleMax,-1,g.offset,g.logBase):new s.LogarithmicCoordinateCalculator(g.viewportDimension,g.visibleMin,g.visibleMax,-1,g.offset,g.logBase),g}return Object.defineProperty(a.prototype,"logBase",{get:function(){return this.logBaseProperty},enumerable:!1,configurable:!0}),a.prototype.translateBy=function(s,l){if(s===0)return l;var u=Math.abs(this.nativeCalculator.GetDataValue(0)),c=Math.abs(this.nativeCalculator.GetDataValue(s)),d=this.webAssemblyContext.NumberUtil,f=l.min<0;f&&(l=new e.NumberRange(Math.abs(l.max),Math.abs(l.min)));var h=d.Log(c,this.logBase)-d.Log(u,this.logBase);this.hasFlippedCoordinates&&(h=-h);var p=d.Log(l.min,this.logBase),g=d.Log(l.max,this.logBase),v=Math.pow(this.logBase,p+h),y=Math.pow(this.logBase,g+h);return f?new e.NumberRange(-y,-v):new e.NumberRange(v,y)},a.prototype.zoomTranslateBy=function(s,l,u){return u.growByLog(new e.NumberRange(s,l),this.logBase)},a})(n.CoordinateCalculatorBase);return bx.LogarithmicCoordinateCalculator=r,bx}var FF={},Lme;function r5(){return Lme||(Lme=1,(function(t){var e=FF&&FF.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.LogarithmicTickProvider=t.ELogarithmicMajorTickMode=t.ELogarithmicMinorTickMode=void 0;var i=ci(),n=di(),r=kp(),o=wW(),a;(function(u){u.Linear="Linear",u.Logarithmic="Logarithmic",u.Auto="Auto"})(a=t.ELogarithmicMinorTickMode||(t.ELogarithmicMinorTickMode={}));var s;(function(u){u.EqualSpacing="EqualSpacing",u.RoundNumbers="RoundNumbers"})(s=t.ELogarithmicMajorTickMode||(t.ELogarithmicMajorTickMode={}));var l=(function(u){e(c,u);function c(d){var f=u.call(this)||this;return f.logarithmicBase=10,f.isHighPrecisionTicks=!0,f.majorTickModeProperty=s.EqualSpacing,f.minorTickModeProperty=a.Linear,f.wasmContext=d,f}return Object.defineProperty(c.prototype,"majorTickMode",{get:function(){return this.majorTickModeProperty},set:function(d){var f;this.majorTickModeProperty=d,!((f=this.parentAxis)===null||f===void 0)&&f.invalidateParentCallback&&this.parentAxis.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"minorTickMode",{get:function(){return this.minorTickModeProperty},set:function(d){var f;this.minorTickModeProperty=d,!((f=this.parentAxis)===null||f===void 0)&&f.invalidateParentCallback&&this.parentAxis.invalidateParentCallback()},enumerable:!1,configurable:!0}),c.prototype.getMajorTicks=function(d,f,h){var p=new n.NumberRange(d,f),g=this.parentAxis,v=1;if(g!=null&&g.isNegative&&h.min<0&&(v=-1,h=new n.NumberRange(Math.abs(h.max),Math.abs(h.min))),!this.isParamsValid(h,p))return[];if(this.majorTickMode===s.RoundNumbers)return this.getRoundNumberMajorTicks(d,f,h);var y=[];if(this.logarithmicBase===0)return y;var m=h.min;h.min;var b=h.max,S=this.wasmContext.NumberUtil;!this.isHighPrecisionTicks&&!S.IsPowerOf(m,this.logarithmicBase,this.logarithmicBase)&&(m=S.RoundDownPower(m,this.logarithmicBase,this.logarithmicBase));var _=S.Log(m,this.logarithmicBase);_=S.RoundToDigits(_,10),S.IsDivisibleBy(_,f)||(_=S.RoundUp(_,f));var C=_;m=Math.pow(this.logarithmicBase,C);for(var P=0;m<=b;)S.IsDivisibleBy(C,f)&&y.push(v*m),C=_+ ++P*f,m=Math.pow(this.logarithmicBase,C);return v===-1?y.reverse():y},c.prototype.getRoundNumberMajorTicks=function(d,f,h){var p=[],g=h.min,v=h.min,y=h.max,m=Math.pow(this.logarithmicBase,f),b=this.roundNum(v*(m-1));for(g=this.roundNum(g,b),p.push(g);g<=y;){for(var S=g*(m-1),_=this.roundNum(g*m,S),C=_;_===g;)C=C*m,_=this.roundNum(C,S);g=_,p.push(g)}return p},c.prototype.roundNum=function(d,f){if(d===0)return 0;var h=Math.floor(Math.log10(d));f&&(h=Math.min(h,Math.round(Math.log10(f))));var p=this.wasmContext.NumberUtil.RoundToDigits(d/Math.pow(10,h),1),g=Math.floor(p),v=p-g,y=NaN;return v<.3?y=0:v<.7?y=.5:y=1,(g+y)*Math.pow(10,h)},c.prototype.getMinorTicks=function(d,f,h){var p=this.parentAxis,g=1;p!=null&&p.isNegative&&(g=-1,h=new n.NumberRange(Math.abs(h.max),Math.abs(h.min)));var v=h.min*d,y=h.min*Math.pow(this.logarithmicBase,f*.7),m=(Math.pow(this.logarithmicBase,f)-1)/d,b=this.minorTickMode===a.Logarithmic||this.minorTickMode===a.Auto&&y<v,S=[],_=this.getMajorTicks(d,f,h),C=_.length,P=Math.pow(this.logarithmicBase,f);if(C>0)for(var x=0;x<=C;x++){var E=x<C?_[x]:_[x-1]*P,A=Math.max(E/P,h.min),R=A*d;if(b){var M=this.getMajorTicks(1,f/m,new n.NumberRange(A,E));M.forEach(function(F){return S.push(g*F)})}else for(var D=A+R;D<E&&R>0;)S.push(g*D),D+=R}return S},c.prototype.isParamsValid=function(d,f){return i.Guard.notNull(d,"visibleRange"),i.Guard.notNull(f,"deltaRange"),(0,r.isRealNumber)(d.min)&&(0,r.isRealNumber)(d.max)&&(0,r.isRealNumber)(f.min)&&(0,r.isRealNumber)(f.max)},c})(o.TickProvider);t.LogarithmicTickProvider=l})(FF)),FF}var Sx={},kme;function uBe(){if(kme)return Sx;kme=1;var t=Sx&&Sx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Sx,"__esModule",{value:!0}),Sx.LogarithmicDeltaCalculator=void 0;var e=ci(),i=di(),n=OW(),r=(function(o){t(a,o);function a(s){var l=o.call(this)||this;return l.logarithmicBase=10,l.isHighPrecisionTicks=!0,l.webAssemblyContext=s,l}return a.prototype.getDeltaFromRange=function(s,l,u,c){if(e.Guard.argumentIsRealNumber(s,"min"),e.Guard.argumentIsRealNumber(l,"max"),s=Math.abs(s),l=Math.abs(l),s>l){var d=s;s=l,l=d}if(this.isHighPrecisionTicks){var f=this.webAssemblyContext.NiceLogScale.CalculateTickSpacing(s,l,this.logarithmicBase,u,c),h=new i.NumberRange(f.minD,f.maxD);return f.delete(),h}else{var f=this.webAssemblyContext.NiceLogScale.CalculateLowPrecisionTickSpacing(s,l,this.logarithmicBase,u,c),h=new i.NumberRange(f.minD,f.maxD);return f.delete(),h}},a})(n.DeltaCalculator);return Sx.LogarithmicDeltaCalculator=r,Sx}var Ime;function z3(){return Ime||(Ime=1,(function(t){var e=NF&&NF.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.LogarithmicAxis=t.MIN_LOG_AXIS_VALUE=void 0;var i=ad(),n=JV(),r=di(),o=ud(),a=pl(),s=lBe(),l=r5(),u=Vv(),c=AW(),d=uBe(),f=tie();t.MIN_LOG_AXIS_VALUE=1e-10;var h=(function(p){e(g,p);function g(v,y){var m=this,b,S,_,C,P;return m=p.call(this,v,y)||this,m.type=o.EAxisType.LogarithmicAxis,m.logBaseProperty=10,m.isHighPrecisionTicksProperty=!0,m.tickProvider=new l.LogarithmicTickProvider(v),m.deltaCalculator=new d.LogarithmicDeltaCalculator(v),m.labelProvider=(b=y==null?void 0:y.labelProvider)!==null&&b!==void 0?b:new f.LogarithmicLabelProvider(y),m.logBase=(S=y==null?void 0:y.logBase)!==null&&S!==void 0?S:m.logBaseProperty,m.isNegativeProperty=(_=y==null?void 0:y.isNegative)!==null&&_!==void 0?_:!1,m.visibleRange=r.NumberRange.hydrate(y==null?void 0:y.visibleRange)||m.getDefaultNonZeroRange(),y!=null&&y.visibleRange||(m.hasVisibleRangeSet=!1),m.majorTickMode=(y==null?void 0:y.majorTickMode)||m.majorTickMode,m.minorTickMode=(y==null?void 0:y.minorTickMode)||m.minorTickMode,m.isHighPrecisionTicks=(C=y==null?void 0:y.isHighPrecisionTicks)!==null&&C!==void 0?C:m.isHighPrecisionTicksProperty,y!=null&&y.visibleRangeLimit?m.visibleRangeLimit=(P=r.NumberRange.hydrate(y==null?void 0:y.visibleRangeLimit))!==null&&P!==void 0?P:y.visibleRangeLimit:m.isNegativeProperty?m.visibleRangeLimit=new r.NumberRange(-1/0,-t.MIN_LOG_AXIS_VALUE):m.visibleRangeLimit=new r.NumberRange(t.MIN_LOG_AXIS_VALUE,1/0),m}return Object.defineProperty(g.prototype,"isLinearAxis",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"logBase",{get:function(){return this.logBaseProperty},set:function(v){this.logBaseProperty!==v&&(this.logBaseProperty=v,this.clearCoordCalcCache(),this.updateProviders(),this.notifyPropertyChanged(c.PROPERTY.LOG_BASE))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"isNegative",{get:function(){return this.isNegativeProperty},set:function(v){this.isNegativeProperty=v,this.isNegativeProperty?this.visibleRangeLimit=new r.NumberRange(-1/0,-1e-10):this.visibleRangeLimit=new r.NumberRange(1e-10,1/0),this.notifyPropertyChanged(c.PROPERTY.IS_NEGATIVE)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"isHighPrecisionTicks",{get:function(){return this.isHighPrecisionTicksProperty},set:function(v){this.isHighPrecisionTicksProperty=v,this.updateProviders(),this.notifyPropertyChanged(c.PROPERTY.HIGH_PRECISION_TICKS)},enumerable:!1,configurable:!0}),g.prototype.getDefaultNonZeroRange=function(){var v=this.isNegativeProperty?-1:1;return new r.NumberRange(v*Math.pow(this.logBase,-1),v*Math.pow(this.logBase,2))},g.prototype.hasValidVisibleRange=function(){return p.prototype.hasValidVisibleRange.call(this)&&this.visibleRange.min*this.visibleRange.max>0},Object.defineProperty(g.prototype,"tickProvider",{get:function(){return this.tickProviderProperty},set:function(v){this.tickProviderProperty=v,this.updateProviders(),this.notifyPropertyChanged(c.PROPERTY.TICK_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"deltaCalculator",{get:function(){return this.deltaCalculatorProperty},set:function(v){this.deltaCalculatorProperty=v,this.updateProviders(),this.notifyPropertyChanged(c.PROPERTY.DELTA_CALCULATOR)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"labelProvider",{get:function(){return this.labelProviderProperty},set:function(v){this.labelProviderProperty=v,this.updateProviders(),this.notifyPropertyChanged(c.PROPERTY.LABEL_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"majorTickMode",{get:function(){return this.logTickProvider.majorTickMode},set:function(v){this.logTickProvider.majorTickMode=v},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"minorTickMode",{get:function(){return this.logTickProvider.minorTickMode},set:function(v){this.logTickProvider.minorTickMode=v},enumerable:!1,configurable:!0}),g.prototype.getWindowedYRange=function(v){var y=this,m;return this.parentSurface&&this.getVisibleRenderableSeriesByYAxis().forEach(function(b){var S=b.xAxisId,_=v!=null&&v.containsKey(S)?v.item(S):y.getXVisibleRange(S),C=y.getIsXCategoryAxis(S);if(_){var P=b.getYRange(_,C);P&&(m=m?m.union(P):P)}}),m!=null&&m.isZero()&&(m=this.coerceZeroVisibleRange(m)),this.growBy&&m&&(m=m.growByLog(this.growBy,this.logBase)),this.visibleRangeLimit&&m&&(m=m.clip(this.visibleRangeLimit)),m},g.prototype.animateVisibleRange=function(v,y,m,b){var S=this,_;if(m===void 0&&(m=i.easing.outCubic),b===void 0&&(b=function(){}),y<=0){this.visibleRange=v||this.visibleRange,b();return}return(_=this.visibleRangeAnimationToken)===null||_===void 0||_.cancel(),this.visibleRangeAnimationToken=n.NumberRangeAnimator.animate(this.visibleRange,v,y,function(C){S.visibleRange=C},b,m,!0),this.parentSurface.addAnimation(this.visibleRangeAnimationToken),this.visibleRangeAnimationToken},g.prototype.scale=function(v,y,m){var b=v.max/v.min,S,_,C=this.flippedCoordinates?!m:m,P=this.flippedCoordinates?-y:y;if(C){S=v.min;var x=P>0?Math.pow(b,1-P):Math.pow(b,1+Math.abs(P));_=x*S}else{_=v.max;var x=(P>0,Math.pow(b,1+P));S=_/x}this.visibleRange=new r.NumberRange(S,_)},g.prototype.toJSON=function(){var v=p.prototype.toJSON.call(this),y={logBase:this.logBase,isNegative:this.isNegative,majorTickMode:this.majorTickMode,minorTickMode:this.minorTickMode,isHighPrecisionTicks:this.isHighPrecisionTicks};return Object.assign(v.options,y),v},g.prototype.getCurrentCoordinateCalculatorInternal=function(){var v=this.visibleRange.min,y=this.visibleRange.max,m=this.axisLength,b=this.isXAxis?a.EXyDirection.XDirection:a.EXyDirection.YDirection;return new s.LogarithmicCoordinateCalculator(this.webAssemblyContext2D,m,v,y,b,this.logBase,this.isXAxis!==this.flippedCoordinates,this.offset)},g.prototype.getMaxXRange=function(){var v=this.getXDataRange();if(v)return this.growBy&&v&&(v=v.growByLog(this.growBy,this.logBase)),this.visibleRangeLimit&&v&&(v=v.clip(this.visibleRangeLimit)),v},Object.defineProperty(g.prototype,"logTickProvider",{get:function(){return this.tickProvider},enumerable:!1,configurable:!0}),g.prototype.updateProviders=function(){var v=this.tickProvider;v&&(v.logarithmicBase=this.logBase,v.isHighPrecisionTicks=this.isHighPrecisionTicks);var y=this.deltaCalculator;y&&(y.logarithmicBase=this.logBase,y.isHighPrecisionTicks=this.isHighPrecisionTicks);var m=this.labelProvider;m&&(m.logarithmicBase=this.logBase)},g})(u.AxisBase2D);t.LogarithmicAxis=h})(NF)),NF}var _x={},Px={},Nme;function cie(){if(Nme)return Px;Nme=1;var t=Px&&Px.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(Px,"__esModule",{value:!0}),Px.PolarTickCoordinatesProvider=void 0;var e=qre(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.getTickCoordinates=function(o,a){if(o===void 0)return{majorTickCoords:void 0,minorTickCoords:void 0,majorTickOverrides:void 0,minorTickOverRides:void 0};var s=this.parentAxis.getCurrentCoordinateCalculator(),l=o.map(function(c){return s.getCoordinate(c)}),u=a.map(function(c){return s.getCoordinate(c)});return{majorTickCoords:l,minorTickCoords:u,majorTickOverrides:o,minorTickOverRides:a}},r})(e.TickCoordinatesProvider);return Px.PolarTickCoordinatesProvider=i,Px}var eb={},Cx={},BF={},Fme;function cBe(){if(Fme)return BF;Fme=1,Object.defineProperty(BF,"__esModule",{value:!0}),BF.polarChartHelper=void 0;function t(i,n,r,o){var a=n?r+o:r;return n?i?{direction:1,tickRotation:o,startAngle:a}:{direction:-1,tickRotation:o,startAngle:a}:i?{direction:-1,tickRotation:0,startAngle:a}:{direction:1,tickRotation:0,startAngle:a}}function e(i,n,r,o){var a=!n&&i||n&&!i,s=n?r+o:r,l=n?o:0;return{isAntiClockWise:a,labelRotation:l,startAngle:s}}return BF.polarChartHelper={calcTickDirection:t,calcLabelPosition:e},BF}var Bme;function dBe(){if(Bme)return Cx;Bme=1;var t=Cx&&Cx.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(Cx,"__esModule",{value:!0}),Cx.PolarAxisRenderer=void 0;var e=Rn(),i=Tc(),n=kh(),r=Ti(),o=Iu(),a=nR(),s=an(),l=cBe(),u=Sn(),c=Zi(),d=Zre(),f=NI(),h=(function(p){t(g,p);function g(){return p!==null&&p.apply(this,arguments)||this}return g.prototype.layout=function(v){this.outerRadius=v.width},g.prototype.measure=function(v,y,m,b,S,_,C){var P=this.parentAxis,x=this.measureTextCanvas.getContext("2d");this.desiredTicksSize=C?b:0,_&&P.isAngular&&(P.isInnerAxis?(this.desiredHeight=0,this.desiredWidth=0):P.polarLabelMode===f.EPolarLabelMode.Parallel?(this.desiredHeight=S.getMaxLabelHeightForHorizontalAxis(m,x,y)+this.desiredTicksSize,this.desiredWidth=this.desiredHeight):P.polarLabelMode===f.EPolarLabelMode.Perpendicular?(this.desiredHeight=S.getMaxLabelWidthForVerticalAxis(m,x,y)+this.desiredTicksSize,this.desiredWidth=this.desiredHeight):(this.desiredHeight=S.getMaxLabelHeightForHorizontalAxis(m,x,y)+this.desiredTicksSize,this.desiredWidth=S.getMaxLabelWidthForVerticalAxis(m,x,y)+this.desiredTicksSize))},g.prototype.drawLabels=function(v,y,m,b,S,_,C,P,x,E){u.DebugForDpi&&console.log("AxisRenderer.drawLabels. fontSize: ".concat(C.fontSize));var A=this;A.viewRect;var R=A.textureManager;v.getNativeContext();var M,D=C.padding;C.alignment;var F=C.multilineAlignment,I=this.parentAxis,V=I.parentSurface.seriesViewRect;v.resetAndClip(V);var z=[],G=(0,r.parseColorToUIntArgb)(C.color),H=E.useNativeText?v.getFont(C,!0):null,U=E.useNativeText?(0,s.getTextBounds)(this.webAssemblyContext):null;if(!H&&(M=R.getTextureContext(V.width,V.height),I.polarLabelMode!==f.EPolarLabelMode.Horizontal))throw new Error("Original text drawing only supports EPolarLabelMode.Horizontal.  To use rotated labels, set useNativeText: true");S=S.map(function(mt){return mt-_});var k=(0,i.convertMultiLineAlignment)(F,this.webAssemblyContext),X=E.lineSpacing,W=this.calculateLineHightForNativeFont(H,U),Y=new this.webAssemblyContext.TSRVector2;if(I.isAngular){var te=(C.padding.left+C.padding.right)/2,oe=[],de=[];if(!E.useCache&&E.useNativeText)for(var ge=0,Ee=b;ge<Ee.length;ge++){var Re=Ee[ge];H.CalculateStringBounds(Re??"",U,X),oe.push(U.m_fHeight),de.push(U.m_fWidth)}else if(E.useNativeText){var Ae=(C.padding.top+C.padding.bottom)/2;oe=b.map(function(mt){return E.getLabelHeight(M,mt,C)-2*Ae}),de=b.map(function(mt){return E.getLabelWidth(M,mt,C)-2*te})}else oe=b.map(function(mt){return E.getLabelHeight(M,mt,C)}),de=b.map(function(mt){return E.getLabelWidth(M,mt,C)});for(var Pe=m?this.outerRadius*Math.min(I.otherAxis.lengthScale,1)-this.desiredTicksSize:this.outerRadius*Math.min(I.otherAxis.lengthScale,1)+this.desiredTicksSize,we=I.getTransform(),Te=10,ke=I.totalAngle<2*Math.PI?S.length:S.length-1,$e=0;$e<ke;$e++){var Ne=S[$e],ve=b[$e],pe=oe[$e],fe=de[$e],me=Pe;if(I.polarLabelMode===f.EPolarLabelMode.Parallel){var Ce=m?-C.padding.top:C.padding.bottom;me=Pe+(m?-1:1)*.5*pe+Ce}else if(I.polarLabelMode===f.EPolarLabelMode.Perpendicular){var Ue=Math.cos(Ne+I.startAngle)<0?m?0:1:m?-1:0;me=Pe+Ue*fe+(m?-1:1)*te}else I.polarLabelMode===f.EPolarLabelMode.Horizontal&&E.useNativeText&&(me=Pe+(m?-C.padding.top:C.padding.bottom));we.TransformPoint(me,Ne,Y),Ne+=I.startAngle;var Qe=Y.x,it=Y.y,xt=0,wt=0;if(I.polarLabelMode===f.EPolarLabelMode.Horizontal){m&&(Ne=Ne+Math.PI);var $t=Math.round(Ne*180/Math.PI),Mt=Math.abs($t)%90<Te||Math.abs($t)%90>90-Te,rt=(($t+Te)/90%4+4)%4;Mt?rt<1?it-=pe/2:rt<2?(Qe-=fe/2,it-=pe):rt<3?(Qe-=fe,it-=pe/2):Qe-=fe/2:(Math.cos(Ne)<0&&(Qe-=fe),Math.sin(Ne)>0&&(it-=pe))}else I.polarLabelMode===f.EPolarLabelMode.Parallel?(xt=Qe+V.left,wt=it+V.top,Qe-=fe/2,Math.sin(Ne)>=0?it-=pe/2:it+=pe/2-W):I.polarLabelMode===f.EPolarLabelMode.Perpendicular&&(xt=Qe+V.left,wt=it+V.top,it-=pe/2);var qe=a.labelHelper.getPolarLabelRotation(I.polarLabelMode,Ne);try{if(H){var vt=Qe+V.left,kt=it+V.top+W,Xe=E.adjustLabel($e,ve,fe,pe,vt,kt,xt,wt,qe),_t=Xe.text,Ht=Xe.x,Pt=Xe.y,Jt=Xe.rx,zt=Xe.ry,Bt=Xe.rotationRadians,Mr=Xe.color;this.drawDebug&&z.push(e.Rect.create(Ht,Pt,fe,pe)),H.DrawStringAdvanced(_t??"",Mr??G,Math.round(Ht),Math.round(Pt),(0,s.getVector4)(this.webAssemblyContext,Jt,zt,Bt,0),k,X)}else{var Be=E.getCachedLabelTexture(ve,R,C),We=Be.bitmapTexture,dt=Be.textureHeight,Tt=Be.textureWidth,nr=E.adjustLabel($e,ve,fe,pe,Qe+V.left,it+V.top,0,0,0),Ht=nr.x,Pt=nr.y;We&&(v.drawTexture(We,Math.round(Ht),Math.round(Pt),Tt,dt),E.useCache||We.delete())}}catch(mt){n.Logger.debug(mt),E.delete()}}}else{var Ar=l.polarChartHelper.calcLabelPosition(m,I.otherAxis.flippedCoordinates,I.startAngle,I.otherAxis.totalAngle),Qr=Ar.isAntiClockWise,Si=Ar.labelRotation,oi=Ar.startAngle,Ne=oi,we=I.getTransform(),oe=[],de=[];if(!E.useCache&&E.useNativeText)for(var Yr=0,vi=b;Yr<vi.length;Yr++){var Re=vi[Yr];H.CalculateStringBounds(Re??"",U,X),oe.push(U.m_fHeight+C.padding.top+C.padding.bottom),de.push(U.m_fWidth+C.padding.left+C.padding.right)}else oe=b.map(function(Yt){return E.getLabelHeight(M,Yt,C)}),de=b.map(function(Yt){return E.getLabelWidth(M,Yt,C)});for(var rr=this.desiredTicksSize,$e=0;$e<S.length;$e++){var Pe=S[$e]+_,ve=b[$e],fe=de[$e],pe=oe[$e];we.TransformPoint(Pe,Si,Y);var Qe=Y.x,it=Y.y;Qr&&(Ne=oi+Math.PI),Qe+=(Math.sin(Ne)/2-.5)*fe,Qe+=Math.sin(Ne)*rr;var Ji=(Ne<0?2*Math.PI-Ne:Ne)%(2*Math.PI),qn=Ji<Math.PI?Ji/Math.PI:2-Ji/Math.PI;it-=qn*pe,it+=Math.cos(Ne)*rr,this.drawDebug&&z.push(e.Rect.create(Qe,it,fe,pe));try{if(H){var vt=Qe+V.left+D.left,kt=it+V.top+W+D.top,ri=E.adjustLabel($e,ve,fe,pe,vt,kt,vt,kt,0),_t=ri.text,Ht=ri.x,Pt=ri.y,Jt=ri.rx,zt=ri.ry,Bt=ri.rotationRadians,Mr=ri.color;H.DrawStringAdvanced(_t??"",Mr??G,Math.round(Ht),Math.round(Pt),(0,s.getVector4)(this.webAssemblyContext,Jt,zt,Bt,0),k,X)}else{var eo=E.getCachedLabelTexture(ve,R,C),We=eo.bitmapTexture,dt=eo.textureHeight,Tt=eo.textureWidth;if(We){var xn=E.adjustLabel($e,ve,fe,pe,Qe+V.left,it+V.top,0,0,0),Ht=xn.x,Pt=xn.y;v.drawTexture(We,Math.round(Ht),Math.round(Pt),Tt,dt),E.useCache||We.delete()}}}catch(zo){n.Logger.debug(zo),E.delete()}}}Y.delete(),this.drawDebug&&this.drawLabelViewRects(v,new e.Rect(0,0,0,0),z),H&&H.End()},g.prototype.drawTicks=function(v,y,m,b,S,_,C){var P,x,E,A;if(!(!b||b.length===0)){var R=c.DpiHelper.PIXEL_RATIO*((x=(P=this.parentAxis.parentSurface.padding)===null||P===void 0?void 0:P.left)!==null&&x!==void 0?x:0),M=c.DpiHelper.PIXEL_RATIO*((A=(E=this.parentAxis.parentSurface.padding)===null||E===void 0?void 0:E.top)!==null&&A!==void 0?A:0),D=this.parentAxis,F=C.tickSize,I=D.getTransform(),V=e.Rect.intersect(this.parentAxis.parentSurface.viewRect,this.parentAxis.parentSurface.seriesViewRect);if(D.isAngular){var z=D.otherAxis.offset,G=D.otherAxis.axisLength+z,H=m?G-F*c.DpiHelper.PIXEL_RATIO:G+F*c.DpiHelper.PIXEL_RATIO,U=(0,s.getVectorColorVertex)(this.webAssemblyContext),k=(0,s.getVertex)(this.webAssemblyContext,0,0),X=(0,s.getVector2)(this.webAssemblyContext);b.forEach(function(Pe){I.TransformPoint(G,Pe,X),k.SetPosition(X.x,X.y),U.push_back(k),I.TransformPoint(H,Pe,X),k.SetPosition(X.x,X.y),U.push_back(k)}),v.drawLinesNative(U,_,o.ELineDrawMode.DiscontinuousLine,V,R,M)}else{var W=(0,s.getVectorColorVertex)(this.webAssemblyContext),Y=(0,s.getVertex)(this.webAssemblyContext,0,0),te=(0,s.getVector2)(this.webAssemblyContext),oe=l.polarChartHelper.calcTickDirection(m,D.otherAxis.flippedCoordinates,D.startAngle,D.otherAxis.totalAngle),de=oe.direction,ge=oe.tickRotation,Ee=oe.startAngle,Re=de*Math.sin(Ee)*F,Ae=de*Math.cos(Ee)*F;b.forEach(function(Pe){I.TransformPoint(Pe,ge,te),Y.SetPosition(te.x,te.y),W.push_back(Y),Y.SetPosition(te.x+Re,te.y+Ae),W.push_back(Y)}),v.drawLinesNative(W,_,o.ELineDrawMode.DiscontinuousLine,V,R,M)}}},g})(d.AxisRenderer);return Cx.PolarAxisRenderer=h,Cx}var N9={},jme;function die(){return jme||(jme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPolarAxisMode=void 0,(function(e){e.Angular="Angular",e.Radial="Radial"})(t.EPolarAxisMode||(t.EPolarAxisMode={}))})(N9)),N9}var F9={},Vme;function fBe(){return Vme||(Vme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPolarGridlineMode=void 0,(function(e){e.Circles="Circles",e.Polygons="Polygons"})(t.EPolarGridlineMode||(t.EPolarGridlineMode={}))})(F9)),F9}var Hme;function fie(){if(Hme)return eb;Hme=1;var t=eb&&eb.__extends||(function(){var m=function(b,S){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,C){_.__proto__=C}||function(_,C){for(var P in C)Object.prototype.hasOwnProperty.call(C,P)&&(_[P]=C[P])},m(b,S)};return function(b,S){if(typeof S!="function"&&S!==null)throw new TypeError("Class extends value "+String(S)+" is not a constructor or null");m(b,S);function _(){this.constructor=b}b.prototype=S===null?Object.create(S):(_.prototype=S.prototype,new _)}})(),e=eb&&eb.__assign||function(){return e=Object.assign||function(m){for(var b,S=1,_=arguments.length;S<_;S++){b=arguments[S];for(var C in b)Object.prototype.hasOwnProperty.call(b,C)&&(m[C]=b[C])}return m},e.apply(this,arguments)};Object.defineProperty(eb,"__esModule",{value:!0}),eb.PolarAxisBase=void 0;var i=Br(),n=$i(),r=Rn(),o=Ls(),a=Iu(),s=an(),l=Sn(),u=Zi(),c=Vv(),d=Qz(),f=AW(),h=dBe(),p=die(),g=fBe(),v=NI(),y=(function(m){t(b,m);function b(S,_){var C=this,P,x,E,A,R,M,D,F,I,V;return Object.assign(_??{},{majorGridLineStyle:e({strokeThickness:1,color:(P=l.SciChartSurfaceBase.DEFAULT_THEME.polarMajorGridLineBrush)!==null&&P!==void 0?P:l.SciChartSurfaceBase.DEFAULT_THEME.majorGridLineBrush},_==null?void 0:_.majorGridLineStyle),minorGridLineStyle:e({strokeThickness:1,color:(x=l.SciChartSurfaceBase.DEFAULT_THEME.polarMinorGridLineBrush)!==null&&x!==void 0?x:l.SciChartSurfaceBase.DEFAULT_THEME.minorGridLineBrush},_==null?void 0:_.minorGridLineStyle)}),C=m.call(this,S,_)||this,C.isPolarAxis=!0,C.axisLayoutState=new d.PolarAxisLayoutState,C.startAngleProperty=0,C.totalAngleProperty=2*Math.PI,C.xCenterOffsetProperty=0,C.yCenterOffsetProperty=0,C.lengthScaleProperty=1,C.gridlineModeProperty=g.EPolarGridlineMode.Circles,C.polarLabelModeProperty=v.EPolarLabelMode.Horizontal,C.innerRadiusProperty=0,C.polarAxisModeProperty=_==null?void 0:_.polarAxisMode,C.gridlineMode=(E=_==null?void 0:_.gridlineMode)!==null&&E!==void 0?E:C.gridlineModeProperty,C.coordTransform=new S.SCRTPolarCoordinateTransform(0,0,0),C.drawMajorBandsProperty=!1,C.innerRadius=(A=_==null?void 0:_.innerRadius)!==null&&A!==void 0?A:C.innerRadiusProperty,C.xCenterOffset=(R=_==null?void 0:_.xCenterOffset)!==null&&R!==void 0?R:C.xCenterOffsetProperty,C.yCenterOffset=(M=_==null?void 0:_.yCenterOffset)!==null&&M!==void 0?M:C.yCenterOffsetProperty,C.lengthScaleProperty=(D=_==null?void 0:_.lengthScale)!==null&&D!==void 0?D:C.lengthScaleProperty,C.polarLabelMode=(F=_==null?void 0:_.polarLabelMode)!==null&&F!==void 0?F:C.polarLabelModeProperty,C.startAngleProperty=(I=_==null?void 0:_.startAngle)!==null&&I!==void 0?I:(_==null?void 0:_.startAngleDegrees)!==void 0?C.toRadians(_.startAngleDegrees):C.startAngleProperty,C.totalAngleProperty=(V=_==null?void 0:_.totalAngle)!==null&&V!==void 0?V:(_==null?void 0:_.totalAngleDegrees)!==void 0?C.toRadians(_.totalAngleDegrees):C.totalAngleProperty,C}return b.prototype.onAttach=function(S,_,C){m.prototype.onAttach.call(this,S,_,C),this.polarAxisMode===void 0&&(this.polarAxisModeProperty=_?p.EPolarAxisMode.Angular:p.EPolarAxisMode.Radial)},Object.defineProperty(b.prototype,"isAngular",{get:function(){return this.polarAxisModeProperty===p.EPolarAxisMode.Angular},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"polarAxisMode",{get:function(){return this.polarAxisModeProperty},set:function(S){this.polarAxisMode!==S&&(this.polarAxisModeProperty=S,this.notifyPropertyChanged("polarAxisMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"gridlineMode",{get:function(){return this.gridlineModeProperty},set:function(S){if(this.gridlineMode!==S){if(this.isAngular){console.warn("PolarAxisBase.gridlineMode property is ignored for the angular axis");return}this.gridlineModeProperty=S,this.notifyPropertyChanged("gridlineMode")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"startAngle",{get:function(){return this.startAngleProperty},set:function(S){this.startAngleProperty!==S&&(this.startAngleProperty=S,this.notifyPropertyChanged("startAngle"))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"totalAngle",{get:function(){return this.totalAngleProperty},set:function(S){if(this.totalAngleProperty!==S){if(!this.isAngular){console.warn("PolarAxisBase.totalAngle property is ignored for the radial axis");return}S===0&&console.warn("PolarAxisBase.totalAngle can not be zero"),this.totalAngleProperty=S,this.notifyPropertyChanged("totalAngle")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"startAngleDegrees",{get:function(){return Math.round(this.startAngleProperty*180/Math.PI*10)/10},set:function(S){S!==void 0&&(this.startAngleProperty=this.toRadians(S),this.notifyPropertyChanged("startAngle"))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"totalAngleDegrees",{get:function(){return Math.round(this.totalAngleProperty*180/Math.PI*10)/10},set:function(S){if(S!==void 0){if(!this.isAngular){console.warn("PolarAxisBase.totalAngleDegrees property is ignored for the radial axis");return}S===0&&console.warn("PolarAxisBase.totalAngleDegrees can not be zero"),this.totalAngleProperty=this.toRadians(S),this.notifyPropertyChanged("totalAngle")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"xCenterOffset",{get:function(){return this.xCenterOffsetProperty},set:function(S){if(this.xCenterOffsetProperty!==S){if(!this.isAngular){console.warn("PolarAxisBase.xCenterOffset property is ignored for the radial axis");return}this.xCenterOffsetProperty=S,this.notifyPropertyChanged("xCenterOffset")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"yCenterOffset",{get:function(){return this.yCenterOffsetProperty},set:function(S){if(this.yCenterOffsetProperty!==S){if(!this.isAngular){console.warn("PolarAxisBase.yCenterOffset property is ignored for the radial axis");return}this.yCenterOffsetProperty=S,this.notifyPropertyChanged("yCenterOffset")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"lengthScale",{get:function(){return this.lengthScaleProperty},set:function(S){this.lengthScaleProperty!==S&&(this.lengthScaleProperty=S,this.notifyPropertyChanged("lengthScale"))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"axisLength",{get:function(){var S;return((S=this.axisLengthProperty)!==null&&S!==void 0?S:1)*this.lengthScale-this.offset},set:function(S){this.axisLengthProperty!==S&&(this.axisLengthProperty=S,this.notifyPropertyChanged(f.PROPERTY.AXIS_LENGTH))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"maxRadius",{get:function(){var S;return(S=this.axisLengthProperty)!==null&&S!==void 0?S:1},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"polarLabelMode",{get:function(){return this.polarLabelModeProperty},set:function(S){if(this.polarLabelMode!==S){if(!this.isAngular){console.warn("PolarAxisBase.polarLabelMode property is ignored for the radial axis");return}this.polarLabelModeProperty=S,this.notifyPropertyChanged("polarLabelMode")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"offset",{get:function(){var S,_=this.offsetProperty;return this.offsetOverrideProperty?_=this.offsetOverrideProperty:this.innerRadius!==void 0&&(_=this.innerRadius*((S=this.axisLengthProperty)!==null&&S!==void 0?S:1)),_*this.lengthScale},set:function(S){this.offsetProperty!==S&&(this.offsetProperty=S,this.innerRadius===void 0&&(this.clearCoordCalcCache(),this.notifyPropertyChanged(f.PROPERTY.OFFSET)))},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"innerRadius",{get:function(){return this.innerRadiusProperty},set:function(S){if(this.innerRadius!==S){if(this.isAngular){console.warn("PolarAxisBase.innerRadius property is ignored for the angular axis");return}if(S<0||S>1)throw Error("innerRadius must be between 0 and 1");this.innerRadiusProperty=S,this.clearCoordCalcCache(),this.notifyPropertyChanged("innerRadius")}},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"otherAxis",{get:function(){return this.otherAxisProperty},enumerable:!1,configurable:!0}),b.prototype.measure=function(){var S=this;if(this.isXAxis){var _=this.parentSurface.yAxes.asArray().find(function(P){return P.isPolarAxis&&P.isAngular!==S.isAngular});if(!_)throw new Error("Could not find a polar y axis with isAngluar: ".concat(!this.isAngular));this.otherAxisProperty=_,this.isAngular||(this.xCenterOffsetProperty=_.xCenterOffset,this.yCenterOffsetProperty=_.yCenterOffset)}else{var C=this.parentSurface.xAxes.asArray().find(function(P){return P.isPolarAxis&&P.isAngular!==S.isAngular});if(!C)throw new Error("Could not find a polar x axis with isAngluar: ".concat(!this.isAngular));this.otherAxisProperty=C,this.isAngular||(this.xCenterOffsetProperty=C.xCenterOffset,this.yCenterOffsetProperty=C.yCenterOffset)}m.prototype.measure.call(this)},b.prototype.zoomBy=function(S,_){return this.isAngular?m.prototype.zoomBy.call(this,S,_):m.prototype.zoomBy.call(this,0,_/10)},b.prototype.scroll=function(S,_){return this.isAngular?m.prototype.scroll.call(this,S/this.otherAxis.axisLength*this.axisLength,_):m.prototype.scroll.call(this,S,c.EClipMode.ClipAtMin)},b.prototype.getTransform=function(S){S===void 0&&(S=!1);var _=this.viewRect,C=_.x,P=_.y;this.coordTransform.yIsPolar=this.isAngular&&!this.isXAxisProperty;var x=S?u.DpiHelper.PIXEL_RATIO:1;return this.coordTransform.XCenter=(C-this.parentSurface.seriesViewRect.left)/x,this.coordTransform.YCenter=(P-this.parentSurface.seriesViewRect.top)/x,this.coordTransform.StartAngle=this.startAngle,this.coordTransform},Object.defineProperty(b.prototype,"isHorizontalAxis",{get:function(){return this.isAngular},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"isVerticalChart",{get:function(){return this.isXAxis&&!this.isAngular},enumerable:!1,configurable:!0}),b.prototype.applyTheme=function(S){var _,C,P,x,E=this.parentSurface.previousThemeProvider;this.axisBandsFill===E.axisBandsFill&&(this.axisBandsFill=S.axisBandsFill),this.labelStyle.color===E.tickTextBrush&&(this.labelStyle={color:S.tickTextBrush});var A=(_=E.polarMinorGridLineBrush)!==null&&_!==void 0?_:E.minorGridLineBrush,R=(C=S.polarMinorGridLineBrush)!==null&&C!==void 0?C:S.minorGridLineBrush;this.minorGridLineStyle.color===A&&(this.minorGridLineStyle={color:R});var M=(P=E.polarMajorGridLineBrush)!==null&&P!==void 0?P:E.majorGridLineBrush,D=(x=S.polarMajorGridLineBrush)!==null&&x!==void 0?x:S.majorGridLineBrush;this.majorGridLineStyle.color===M&&(this.majorGridLineStyle={color:D}),this.minorTickLineStyle.color===E.minorGridLineBrush&&(this.minorTickLineStyle={color:S.minorGridLineBrush}),this.majorTickLineStyle.color===E.majorGridLineBrush&&(this.majorTickLineStyle={color:S.majorGridLineBrush}),this.axisTitleStyle.color===E.axisTitleColor&&(this.axisTitleStyle={color:S.axisTitleColor})},b.prototype.toJSON=function(){var S=m.prototype.toJSON.call(this),_={gridlineMode:this.gridlineMode,innerRadius:this.innerRadius,lengthScale:this.lengthScale,polarAxisMode:this.polarAxisMode,polarLabelMode:this.polarLabelMode,startAngle:this.startAngle,totalAngle:this.totalAngle,xCenterOffset:this.xCenterOffset,yCenterOffset:this.yCenterOffset},C=e(e({},S),{options:e(e({},S.options),_)});return C},b.prototype.delete=function(){this.coordTransform=(0,i.deleteSafe)(this.coordTransform),m.prototype.delete.call(this)},b.prototype.drawAxisBands=function(S,_,C,P){},b.prototype.getPenForLines=function(S,_,C,P){if((S===this.penCacheForMajorGridLines||S===this.penCacheForMinorGridLines)&&!this.isAngular&&this.gridlineMode===g.EPolarGridlineMode.Circles){var x=C>0?C+1:0;return(0,o.createPenInCache)(S,_,x,1,P,!1)}var E=C>0?C+1:0;return(0,o.createPenInCache)(S,_,E,1,P,!0)},b.prototype.drawGridLines=function(S,_,C,P){var x=this,E,A,R,M;if(!(!_||_.length===0)){var D=((A=(E=this.parentSurface.padding)===null||E===void 0?void 0:E.left)!==null&&A!==void 0?A:0)*u.DpiHelper.PIXEL_RATIO,F=((M=(R=this.parentSurface.padding)===null||R===void 0?void 0:R.top)!==null&&M!==void 0?M:0)*u.DpiHelper.PIXEL_RATIO,I=this.viewRect;I.x,I.y;var V=I.width,z=this.getTransform();V=V*this.otherAxis.lengthScale;var G=r.Rect.intersect(this.parentSurface.clipRect,this.parentSurface.seriesViewRect);if(this.isAngular){var H=(0,s.getVectorColorVertex)(this.webAssemblyContext2D),U=(0,s.getVector2)(this.webAssemblyContext2D),k=(0,s.getVertex)(this.webAssemblyContext2D,0,0),X=15;_.forEach(function(Pe,we){z.TransformPoint(V,Pe,U),k.SetPosition(U.x,U.y),H.push_back(k),x.otherAxis.offset>0?(z.TransformPoint(x.otherAxis.offset,Pe,U),k.SetPosition(U.x,U.y),H.push_back(k)):P?(k.SetPosition(z.XCenter,z.YCenter),H.push_back(k)):(z.TransformPoint(X,Pe,U),k.SetPosition(U.x,U.y),H.push_back(k))}),S.drawLinesNative(H,C,a.ELineDrawMode.DiscontinuousLine,G,D,F)}else if(this.gridlineMode===g.EPolarGridlineMode.Polygons){var W=this.otherAxis.getTicksWithCoords().majorTickCoords,Y=(0,s.getVectorColorVertex)(this.webAssemblyContext2D),te=(0,s.getVector2)(this.webAssemblyContext2D),oe=(0,s.getVertex)(this.webAssemblyContext2D,0,0);_.forEach(function(Pe){W.forEach(function(we,Te){z.TransformPoint(Pe,we,te),oe.SetPosition(te.x,te.y),Y.push_back(oe),Te>0&&Te<W.length-1&&Y.push_back(oe)})}),S.drawLinesNative(Y,C,a.ELineDrawMode.DiscontinuousLine,G,D,F)}else{var de=(0,s.getVectorArcVertex)(this.webAssemblyContext2D),ge=(0,s.getArcVertex)(this.webAssemblyContext2D),Ee=0;this.parentSurface.isCopyCanvasSurface?Ee=l.SciChartSurfaceBase.domMasterCanvas.height:Ee=this.parentSurface.renderSurface.viewportSize.height;var Re=this.otherAxis.startAngle,Ae=this.otherAxis.axisLength;_.forEach(function(Pe){var we=(0,s.getArcParams)(x.webAssemblyContext2D,z.XCenter,Ee-z.YCenter,0,Ae,Pe,0,1,1,C.m_fThickness);ge.MakeCircularArc(we),de.push_back(ge)}),S.drawArcs(de,z.XCenter,Ee-z.YCenter,Re,G,C,void 0,D,F)}}},b.prototype.toRadians=function(S){return S*Math.PI/180},b.prototype.reverseTransform=function(S,_,C){C===void 0&&(C=!0);var P=this.getTransform(),x=new this.webAssemblyContext2D.TSRVector2;P.ReverseTransformPoint(S,_,x);var E;return C?this.isXAxis&&this.isAngular?E=new n.Point(-x.y,x.x):E=new n.Point(x.x,-x.y):this.isXAxis?E=new n.Point(-x.y,x.x):E=new n.Point(x.x,-x.y),x.delete(),E},b.prototype.createAxisRender=function(){return new h.PolarAxisRenderer(this.webAssemblyContext2D)},b})(c.AxisBase2D);return eb.PolarAxisBase=y,eb}var Ume;function hBe(){if(Ume)return _x;Ume=1;var t=_x&&_x.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(_x,"__esModule",{value:!0}),_x.PolarCategoryAxis=void 0;var e=di(),i=ud(),n=cie(),r=oR(),o=RW(),a=Jre(),s=DW(),l=U3(),u=fie(),c=(function(d){t(f,d);function f(h,p){var g=this,v,y,m;return g=d.call(this,h,p)||this,g.type=i.EAxisType.PolarCategoryAxis,g.defaultXValuesProperty=[],g.defaultXStartProperty=0,g.defaultXStepProperty=1,g.defaultXValuesProperty=(v=p==null?void 0:p.defaultXValues)!==null&&v!==void 0?v:g.defaultXValuesProperty,g.defaultXStartProperty=(y=p==null?void 0:p.defaultXStart)!==null&&y!==void 0?y:g.defaultXStartProperty,g.defaultXStepProperty=(m=p==null?void 0:p.defaultXStep)!==null&&m!==void 0?m:g.defaultXStepProperty,g.tickProvider=new r.NumericTickProvider(g.webAssemblyContext2D),g.deltaCalculator=new a.CategoryDeltaCalculator(g.webAssemblyContext2D),g.defaultBaseXValues=new g.webAssemblyContext2D.SCRTDoubleVector,g.tickCoordinatesProvider=new n.PolarTickCoordinatesProvider,p!=null&&p.labelProvider?g.labelProvider=p==null?void 0:p.labelProvider:p!=null&&p.labels?g.labelProvider=new l.TextLabelProvider(p):g.labelProvider=new s.DateLabelProvider(p),g}return Object.defineProperty(f.prototype,"isCategoryAxis",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXValues",{get:function(){return this.defaultXValuesProperty},set:function(h){this.defaultXValuesProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXStart",{get:function(){return this.defaultXStartProperty},set:function(h){this.defaultXStartProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"defaultXStep",{get:function(){return this.defaultXStepProperty},set:function(h){this.defaultXStepProperty=h,this.invalidateParentCallback&&this.invalidateParentCallback()},enumerable:!1,configurable:!0}),f.prototype.prepareRenderData=function(){o.CategoryAxis.prototype.prepareRenderData.call(this)},f.prototype.delete=function(){d.prototype.delete.call(this),o.CategoryAxis.prototype.delete.call(this)},f.prototype.getCurrentCoordinateCalculatorInternal=function(){return o.CategoryAxis.prototype.getCurrentCoordinateCalculatorInternal.call(this)},f.prototype.getXDataRange=function(){var h;return this.parentSurface&&this.getVisibleRenderableSeriesByXAxis().forEach(function(p){var g=p.getDataSeriesValuesCount(),v=new e.NumberRange(0,g-1);v&&(h=h?h.union(v):v)}),h},f.prototype.getMaxAutoTicks=function(){return o.CategoryAxis.prototype.getMaxAutoTicks.call(this)},f.prototype.generateDefaultXValuesForCategoryAxis=function(h,p){return o.CategoryAxis.prototype.generateDefaultXValuesForCategoryAxis.call(this,h,p)},f.prototype.updateBaseXValues=function(h){return o.CategoryAxis.prototype.updateBaseXValues.call(this,h)},f})(u.PolarAxisBase);return _x.PolarCategoryAxis=c,_x}var Tx={},zme;function hie(){if(zme)return Tx;zme=1;var t=Tx&&Tx.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(Tx,"__esModule",{value:!0}),Tx.PolarNumericAxis=void 0;var e=ud(),i=MW(),n=LW(),r=cie(),o=oR(),a=aR(),s=Rm(),l=fie(),u=(function(c){t(d,c);function d(f,h){var p=this,g;return p=c.call(this,f,h)||this,p.type=e.EAxisType.PolarNumericAxis,p.tickProvider=new o.NumericTickProvider(p.webAssemblyContext2D),p.tickCoordinatesProvider=new r.PolarTickCoordinatesProvider,p.labelProvider=(g=h==null?void 0:h.labelProvider)!==null&&g!==void 0?g:new s.NumericLabelProvider(h),p.deltaCalculator=new a.NumericDeltaCalculator(p.webAssemblyContext2D),p}return d.prototype.getCurrentCoordinateCalculatorInternal=function(){var f=this.visibleRange.min,h=this.visibleRange.max,p=this.getAxisSize(),g=this.offset;return this.flippedCoordinates?new n.NumericCoordinateCalculator(this.webAssemblyContext2D,p,f,h,g,this.allowFastMath,0,0):new i.FlippedNumericCoordinateCalculator(this.webAssemblyContext2D,p,f,h,g,this.allowFastMath,0)},d})(l.PolarAxisBase);return Tx.PolarNumericAxis=u,Tx}var xx={},Ex={},B9={},$me;function dj(){return $me||($me=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convert3DTitleRotationMode=t.convert3DLabelOrientationMode=t.E3DTitleRotationMode=t.E3DLabelOrientationMode=void 0;var e;(function(o){o.Auto="Auto",o.Horizontal="Horizontal"})(e=t.E3DLabelOrientationMode||(t.E3DLabelOrientationMode={}));var i;(function(o){o.Auto="Auto",o.Horizontal="Horizontal",o.Vertical="Vertical"})(i=t.E3DTitleRotationMode||(t.E3DTitleRotationMode={}));var n=function(o,a){var s=a.eSCRTTickLabelOrientationMode.TickLabelOrientationHorizontal;switch(o){case e.Auto:s=a.eSCRTTickLabelOrientationMode.TickLabelOrientationAuto;break;case e.Horizontal:s=a.eSCRTTickLabelOrientationMode.TickLabelOrientationHorizontal;break}return s};t.convert3DLabelOrientationMode=n;var r=function(o,a){var s=a.eSCRTAxisTitleRotationMode.AxisTitleRotationHorizontal;switch(o){case i.Auto:s=a.eSCRTAxisTitleRotationMode.AxisTitleRotationAuto;break;case i.Horizontal:s=a.eSCRTAxisTitleRotationMode.AxisTitleRotationHorizontal;break;case i.Vertical:s=a.eSCRTAxisTitleRotationMode.AxisTitleRotationVertical;break}return s};t.convert3DTitleRotationMode=r})(B9)),B9}var j9={},Wme;function Qwt(){return Wme||(Wme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TEXT_STYLE_PROPERTY=t.PROPERTY=void 0,(function(e){e.AXIS_PLANE_BACKGROUND_FILL="AXIS_PLANE_BACKGROUND_FILL",e.IS_Y_AXIS="IS_Y_AXIS",e.IS_Z_AXIS="IS_Z_AXIS",e.LABEL_DEPTH_TEST="LABEL_DEPTH_TEST",e.LABEL_ORIENTATION_MODE="LABEL_ORIENTATION_MODE",e.NEGATIVE_SIDE_CLIPPING="NEGATIVE_SIDE_CLIPPING",e.PLANE_BORDER_COLOR="PLANE_BORDER_COLOR",e.PLANE_BORDER_THICKNESS="PLANE_BORDER_THICKNESS",e.POSITIVE_SIDE_CLIPPING="POSITIVE_SIDE_CLIPPING",e.TEXT_STYLE="TEXT_STYLE",e.TICK_LABEL_ALIGNMENT="TICK_LABEL_ALIGNMENT",e.TICK_LABELS_OFFSET="TICK_LABELS_OFFSET",e.TITLE_OFFSET="TITLE_OFFSET",e.TITLE_ORIENTATION_MODE="TITLE_ORIENTATION_MODE",e.BACKGROUND_COLOR="BACKGROUND_COLOR"})(t.PROPERTY||(t.PROPERTY={})),(function(e){e.ALIGNMENT="ALIGNMENT",e.DPI_SCALING="DPI_SCALING",e.FONT_FAMILY="FONT_FAMILY",e.FONT_SIZE="FONT_SIZE",e.FOREGROUND="FOREGROUND"})(t.TEXT_STYLE_PROPERTY||(t.TEXT_STYLE_PROPERTY={}))})(j9)),j9}var Gme;function hJ(){return Gme||(Gme=1,(function(t){var e=Ex&&Ex.__extends||(function(){var m=function(b,S){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,C){_.__proto__=C}||function(_,C){for(var P in C)Object.prototype.hasOwnProperty.call(C,P)&&(_[P]=C[P])},m(b,S)};return function(b,S){if(typeof S!="function"&&S!==null)throw new TypeError("Class extends value "+String(S)+" is not a constructor or null");m(b,S);function _(){this.constructor=b}b.prototype=S===null?Object.create(S):(_.prototype=S.prototype,new _)}})(),i=Ex&&Ex.__assign||function(){return i=Object.assign||function(m){for(var b,S=1,_=arguments.length;S<_;S++){b=arguments[S];for(var C in b)Object.prototype.hasOwnProperty.call(b,C)&&(m[C]=b[C])}return m},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.AxisBase3D=t.EWhichAxis=void 0;var n=mo(),r=Kre(),o=Sn(),a=Zi(),s=di(),l=ga(),u=dj(),c=Vf(),d=Ti(),f=Qwt(),h=Tc(),p;(function(m){m.xAxis="xAxis",m.yAxis="yAxis",m.zAxis="zAxis"})(p=t.EWhichAxis||(t.EWhichAxis={}));var g=(function(m){e(b,m);function b(S,_){var C=this,P,x,E,A,R,M,D;return C=m.call(this,_)||this,C.getlabelStyleProxy=function(F){return new Proxy(F,{set:function(I,V,z){return I[V]=z,C.notifyPropertyChanged(f.PROPERTY.TEXT_STYLE),!0}})},C.labelDepthTestEnabledProperty=!1,C.planeBorderColorProperty=o.SciChartSurfaceBase.DEFAULT_THEME.planeBorderColor,C.axisPlaneBackgroundFillProperty=o.SciChartSurfaceBase.DEFAULT_THEME.axisPlaneBackgroundFill,C.isYAxisProperty=!1,C.isZAxisProperty=!1,C.titleOffsetProperty=10,C.tickLabelsOffsetProperty=10,C.labelStyleProperty=C.getlabelStyleProxy(i({dpiScaling:96,fontFamily:(0,c.getFontFamily)((0,c.getDefaultFontName)(),!0),fontSize:14,color:o.SciChartSurfaceBase.DEFAULT_THEME.labelForegroundBrush,multilineAlignment:h.EMultiLineAlignment.Center,multilineSpacing:3},_==null?void 0:_.labelStyle)),C.titleStyleProperty=C.getlabelStyleProxy(i({dpiScaling:96,fontFamily:(0,c.getFontFamily)((0,c.getDefaultFontName)(),!0),fontSize:14,color:o.SciChartSurfaceBase.DEFAULT_THEME.labelForegroundBrush,multilineAlignment:h.EMultiLineAlignment.Center,multilineSpacing:3},_==null?void 0:_.axisTitleStyle)),_!=null&&_.labelProvider&&("getLabels"in(_==null?void 0:_.labelProvider)||(_.labelProvider=(0,n.createType)(l.EBaseType.LabelProvider,_.labelProvider.type,S,_.labelProvider.options))),C.webAssemblyContext3D=S,C.isXAxisProperty=!1,C.tickLabelsOffsetProperty=(P=_==null?void 0:_.tickLabelsOffset)!==null&&P!==void 0?P:C.tickLabelsOffsetProperty,C.titleOffsetProperty=(x=_==null?void 0:_.titleOffset)!==null&&x!==void 0?x:C.titleOffsetProperty,C.planeBorderColorProperty=(E=_==null?void 0:_.planeBorderColor)!==null&&E!==void 0?E:C.planeBorderColorProperty,C.planeBorderThicknessProperty=(A=_==null?void 0:_.planeBorderThickness)!==null&&A!==void 0?A:2,C.axisPlaneBackgroundFillProperty=(R=_==null?void 0:_.planeBackgroundFill)!==null&&R!==void 0?R:C.axisPlaneBackgroundFillProperty,C.labelOrientationModeProperty=(M=_==null?void 0:_.labelOrientationMode)!==null&&M!==void 0?M:C.labelOrientationModeProperty,C.titleOrientationModeProperty=(D=_==null?void 0:_.titleOrientationMode)!==null&&D!==void 0?D:C.titleOrientationModeProperty,C}return Object.defineProperty(b.prototype,"labelStyle",{get:function(){return this.labelStyleProperty},set:function(S){var _=i(i({},this.labelStyle),S);this.labelStyleProperty=this.getlabelStyleProxy(_),this.notifyPropertyChanged(f.PROPERTY.TEXT_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"titleStyle",{get:function(){return this.titleStyleProperty},set:function(S){var _=i(i({},this.titleStyle),S);this.titleStyleProperty=this.getlabelStyleProxy(_),this.notifyPropertyChanged(f.PROPERTY.TEXT_STYLE)},enumerable:!1,configurable:!0}),b.prototype.applyTheme=function(S){var _,C,P,x,E,A,R=this.parentSurface.previousThemeProvider;this.axisBandsFill===R.axisBandsFill&&(this.axisBandsFill=S.axisBandsFill),((_=this.majorGridLineStyle)===null||_===void 0?void 0:_.color)===R.majorGridLineBrush&&(this.majorGridLineStyle={color:S.majorGridLineBrush}),((C=this.majorTickLineStyle)===null||C===void 0?void 0:C.color)===R.majorGridLineBrush&&(this.majorTickLineStyle={color:S.majorGridLineBrush}),((P=this.minorGridLineStyle)===null||P===void 0?void 0:P.color)===R.minorGridLineBrush&&(this.minorGridLineStyle={color:S.minorGridLineBrush}),((x=this.minorTickLineStyle)===null||x===void 0?void 0:x.color)===R.minorGridLineBrush&&(this.minorTickLineStyle={color:S.minorGridLineBrush}),((E=this.axisTitleStyle)===null||E===void 0?void 0:E.color)===R.axisTitleColor&&(this.axisTitleStyle={color:S.axisTitleColor}),this.planeBorderColor===R.planeBorderColor&&(this.planeBorderColor=S.planeBorderColor),this.axisPlaneBackgroundFill===R.axisPlaneBackgroundFill&&(this.axisPlaneBackgroundFill=S.axisPlaneBackgroundFill),((A=this.labelStyle)===null||A===void 0?void 0:A.color)===R.labelForegroundBrush&&(this.labelStyle.color=S.labelForegroundBrush)},Object.defineProperty(b.prototype,"isYAxis",{get:function(){return this.isYAxisProperty},enumerable:!1,configurable:!0}),b.prototype.setIsYAxis=function(S){this.isYAxisProperty=S,this.notifyPropertyChanged(f.PROPERTY.IS_Y_AXIS)},Object.defineProperty(b.prototype,"isZAxis",{get:function(){return this.isZAxisProperty},enumerable:!1,configurable:!0}),b.prototype.setIsZAxis=function(S){this.isZAxisProperty=S,this.notifyPropertyChanged(f.PROPERTY.IS_Z_AXIS)},Object.defineProperty(b.prototype,"labelDepthTestEnabled",{get:function(){return this.labelDepthTestEnabledProperty},set:function(S){this.labelDepthTestEnabledProperty=S,this.notifyPropertyChanged(f.PROPERTY.LABEL_DEPTH_TEST)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"planeBorderThickness",{get:function(){return this.planeBorderThicknessProperty},set:function(S){this.planeBorderThicknessProperty=S,this.notifyPropertyChanged(f.PROPERTY.PLANE_BORDER_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"planeBorderColor",{get:function(){return this.planeBorderColorProperty},set:function(S){this.planeBorderColorProperty=S,this.notifyPropertyChanged(f.PROPERTY.PLANE_BORDER_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"tickLabelAlignment",{get:function(){return this.tickLabelAlignmentProperty},set:function(S){this.tickLabelAlignmentProperty=S,this.notifyPropertyChanged(f.PROPERTY.TICK_LABEL_ALIGNMENT)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"positiveSideClipping",{get:function(){return this.positiveSideClippingProperty},set:function(S){this.positiveSideClippingProperty=S,this.notifyPropertyChanged(f.PROPERTY.POSITIVE_SIDE_CLIPPING)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"negativeSideClipping",{get:function(){return this.negativeSideClippingProperty},set:function(S){this.negativeSideClippingProperty=S,this.notifyPropertyChanged(f.PROPERTY.NEGATIVE_SIDE_CLIPPING)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"axisPlaneBackgroundFill",{get:function(){return this.axisPlaneBackgroundFillProperty},set:function(S){this.axisPlaneBackgroundFillProperty=S,this.notifyPropertyChanged(f.PROPERTY.AXIS_PLANE_BACKGROUND_FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"titleOffset",{get:function(){return this.titleOffsetProperty},set:function(S){this.titleOffsetProperty=S,this.notifyPropertyChanged(f.PROPERTY.TITLE_OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"backgroundColor",{get:function(){return this.axisPlaneBackgroundFill},set:function(S){this.axisPlaneBackgroundFill=S,this.notifyPropertyChanged(f.PROPERTY.BACKGROUND_COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"tickLabelsOffset",{get:function(){return this.tickLabelsOffsetProperty},set:function(S){this.tickLabelsOffsetProperty=S,this.notifyPropertyChanged(f.PROPERTY.TICK_LABELS_OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"labelOrientationMode",{get:function(){return this.labelOrientationModeProperty},set:function(S){this.labelOrientationModeProperty=S,this.notifyPropertyChanged(f.PROPERTY.LABEL_ORIENTATION_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"titleOrientationMode",{get:function(){return this.titleOrientationModeProperty},set:function(S){this.titleOrientationModeProperty=S,this.notifyPropertyChanged(f.PROPERTY.TITLE_ORIENTATION_MODE)},enumerable:!1,configurable:!0}),b.prototype.onAttach=function(S,_,C,P){this.parentSurface=S,this.setIsXAxis(_),this.setIsYAxis(C),this.setIsZAxis(P)},b.prototype.toAxisDescriptor=function(){var S,_,C="transparent",P="#202123",x=this.getTickCoordsAndLabels(),E=x.majorTickCoords,A=x.minorTickCoords,R=x.majorTickLabels,M={axisTitle:this.isVisible?Array.isArray(this.axisTitle)?this.axisTitle.join(" "):this.axisTitle:"",axisSize:this.getAxisSize(),backgroundColor:(0,d.parseColorToTArgb)(this.axisPlaneBackgroundFill||C),bandColor:(0,d.parseColorToTArgb)(this.axisBandsFill||P),borderColor:(0,d.parseColorToTArgb)(this.planeBorderColor||C),borderThickness:this.planeBorderThickness,drawBands:this.isVisible&&this.drawMajorBands,drawLabels:this.isVisible&&this.drawLabels,drawMajorGridlines:this.isVisible&&this.drawMajorGridLines,drawMajorTicks:this.isVisible&&this.drawMajorTickLines,drawMinorGridlines:this.isVisible&&this.drawMinorGridLines,drawMinorTicks:this.isVisible&&this.drawMinorTickLines,isVisible:this.isVisible,labelDepthTestEnabled:this.labelDepthTestEnabled,labelStyle:{dpiScaling:this.labelStyle.dpiScaling/96,fontFamily:this.labelStyle.fontFamily,fontSize:this.labelStyle.fontSize*a.DpiHelper.PIXEL_RATIO,foreground:(0,d.parseColorToUIntAbgr)((S=this.labelStyle.color)!==null&&S!==void 0?S:this.parentSurface.themeProvider.labelForegroundBrush),multilineSpacing:this.labelStyle.multilineSpacing,multilineAlignment:(0,h.convertMultiLineAlignment)(this.labelStyle.multilineAlignment,this.webAssemblyContext3D)},majorCoordinates:E,majorLineStyle:v(this.majorGridLineStyle),minorLineStyle:v(this.minorGridLineStyle),majorTickStyle:y(this.majorTickLineStyle),minorTickStyle:y(this.minorTickLineStyle),minorCoordinates:A,smoothLabelOverlapAvoidance:!1,tickLabels:R,tickLabelsOffset:this.tickLabelsOffset*a.DpiHelper.PIXEL_RATIO,titleOffset:this.titleOffset*a.DpiHelper.PIXEL_RATIO,titleStyle:{dpiScaling:this.titleStyle.dpiScaling/96,fontFamily:this.titleStyle.fontFamily,fontSize:this.titleStyle.fontSize*a.DpiHelper.PIXEL_RATIO,foreground:(0,d.parseColorToUIntAbgr)((_=this.titleStyle.color)!==null&&_!==void 0?_:this.parentSurface.themeProvider.labelForegroundBrush),multilineSpacing:this.titleStyle.multilineSpacing,multilineAlignment:(0,h.convertMultiLineAlignment)(this.titleStyle.multilineAlignment,this.webAssemblyContext3D)},labelOrientationMode:(0,u.convert3DLabelOrientationMode)(this.labelOrientationMode,this.webAssemblyContext3D),titleOrientationMode:(0,u.convert3DTitleRotationMode)(this.titleOrientationMode,this.webAssemblyContext3D)};return M},b.prototype.validateAxis=function(){},b.prototype.getMaximumRange=function(){var S,_,C,P,x,E=new s.NumberRange(NaN,NaN);if(((_=(S=this.parentSurface)===null||S===void 0?void 0:S.renderableSeries)===null||_===void 0?void 0:_.size())>0){var A=void 0;if(this.isXAxis)A=p.xAxis;else if(this.isYAxis)A=p.yAxis;else if(this.isZAxis)A=p.zAxis;else throw Error("AxisBase3D: isXAxis, isYAxis, isZAxis flag are not set");E=(C=this.getMaximumRangeAs(this.parentSurface.renderableSeries,A))!==null&&C!==void 0?C:E,E.isZero()&&(E=this.coerceZeroVisibleRange(E)),!((P=this.growBy)===null||P===void 0)&&P.isDefined()&&(E=E.growBy(this.growBy))}var R=!((x=this.visibleRange)===null||x===void 0)&&x.isDefined()?this.visibleRange:this.getDefaultNonZeroRange();return E!=null&&E.isDefined()?E:R},b.prototype.getMaximumRangeAs=function(S,_){var C;return S.asArray().forEach(function(P){if(P.isVisible&&P.dataSeries){var x=_===p.xAxis?P.dataSeries.xRange:_===p.yAxis?P.dataSeries.yRange:P.dataSeries.zRange;x!=null&&x.isDefined()&&(C=C?x.union(C):x)}}),C},b.prototype.getAxisSize=function(){if(!this.parentSurface)return 0;var S=this.parentSurface.worldDimensions;if(!S)throw new Error("Must set property sciChart3DSurface.worldDimensions to a valid Vector3 with X,Y,Z world size");var _=this.isXAxis?S.x:this.isYAxis?S.y:S.z;return _},b.prototype.getLabels=function(S){var _=this;return S.map(function(C){return _.labelProvider.formatLabel(C)})},b.prototype.getTicks=function(){var S=this.getMaxAutoTicks();if(this.autoTicks){var _=this.deltaCalculator.getDeltaFromRange(this.visibleRange.min,this.visibleRange.max,this.minorsPerMajor,S);this.minorDeltaProperty=_.min,this.majorDeltaProperty=_.max}var C=this.tickProvider.getMajorTicks(this.minorDeltaProperty,this.majorDeltaProperty,this.visibleRange),P=this.tickProvider.getMinorTicks(this.minorDeltaProperty,this.majorDeltaProperty,this.visibleRange);return{majorTicks:C,minorTicks:P}},b.prototype.getTickCoordsAndLabels=function(){var S=this.getCurrentCoordinateCalculator(),_=function(M){return M.map(function(D){return S.getCoordinate(D)})},C=this.getTicks(),P=C.majorTicks,x=C.minorTicks,E=this.getLabels(P),A=_(P),R=_(x);return{majorTicks:P,majorTickLabels:E,majorTickCoords:A,minorTicks:x,minorTickCoords:R}},b.prototype.toJSON=function(){var S={autoRange:this.autoRange,autoTicks:this.autoTicks,axisTitle:this.axisTitle,axisTitleStyle:this.titleStyle,drawLabels:this.drawLabels,drawMajorBands:this.drawMajorBands,drawMajorGridLines:this.drawMajorGridLines,drawMajorTickLines:this.drawMajorTickLines,drawMinorGridLines:this.drawMinorGridLines,drawMinorTickLines:this.drawMinorTickLines,flippedCoordinates:this.flippedCoordinates,growBy:this.growBy,id:this.id,isVisible:this.isVisible,labelStyle:this.labelStyle,majorGridLineStyle:this.majorGridLineStyle,majorTickLineStyle:this.majorTickLineStyle,maxAutoTicks:this.maxAutoTicks,minorGridLineStyle:this.minorGridLineStyle,minorTickLineStyle:this.minorTickLineStyle,visibleRange:this.hasDefaultVisibleRange()?void 0:this.visibleRange,minorsPerMajor:this.minorsPerMajor,majorDelta:this.majorDelta,minorDelta:this.minorDelta,labelProvider:this.labelProvider.toJSON()};return{type:this.type,options:S}},b})(r.AxisCore);t.AxisBase3D=g;var v=function(m){return{stroke:(0,d.parseColorToTArgb)(m.color),strokeThickness:m.strokeThickness*a.DpiHelper.PIXEL_RATIO,start:1,end:1}},y=function(m){return{stroke:(0,d.parseColorToTArgb)(m.color),strokeThickness:m.strokeThickness*a.DpiHelper.PIXEL_RATIO,start:0,end:m.tickSize*a.DpiHelper.PIXEL_RATIO}}})(Ex)),Ex}var Yme;function pie(){if(Yme)return xx;Yme=1;var t=xx&&xx.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(xx,"__esModule",{value:!0}),xx.NumericAxis3D=void 0;var e=MW(),i=LW(),n=oR(),r=aR(),o=Rm(),a=ad(),s=JV(),l=di(),u=ud(),c=hJ(),d=(function(f){t(h,f);function h(p,g){var v=this,y;return v=f.call(this,p,g)||this,v.type=u.EAxisType.NumericAxis3D,v.tickProvider=new n.NumericTickProvider(v.webAssemblyContext3D),v.deltaCalculator=new r.NumericDeltaCalculator(v.webAssemblyContext3D),g!=null&&g.precision&&(g.labelPrecision=g.precision),v.labelProvider=(y=g==null?void 0:g.labelProvider)!==null&&y!==void 0?y:new o.NumericLabelProvider(g),v}return h.prototype.getDefaultNonZeroRange=function(){return new l.NumberRange(0,10)},h.prototype.animateVisibleRange=function(p,g,v,y){var m=this,b;if(v===void 0&&(v=a.easing.outCubic),y===void 0&&(y=function(){}),g<=0){this.visibleRange=p||this.visibleRange,y();return}return(b=this.visibleRangeAnimationToken)===null||b===void 0||b.cancel(),this.visibleRangeAnimationToken=s.NumberRangeAnimator.animate(this.visibleRange,p,g,function(S){m.visibleRange=S},function(){m.visibleRangeAnimationToken=void 0,y()},v),this.parentSurface.addAnimation(this.visibleRangeAnimationToken),this.visibleRangeAnimationToken},h.prototype.getCurrentCoordinateCalculatorInternal=function(){var p=this.visibleRange.min,g=this.visibleRange.max,v=this.getAxisSize(),y=!this.flippedCoordinatesProperty;return y?new e.FlippedNumericCoordinateCalculator(this.webAssemblyContext3D,v,p,g):new i.NumericCoordinateCalculator(this.webAssemblyContext3D,v,p,g)},h})(c.AxisBase3D);return xx.NumericAxis3D=d,xx}var wx={},Ax={},tb={},rb={},qme;function pBe(){if(qme)return rb;qme=1;var t=rb&&rb.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=rb&&rb.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(rb,"__esModule",{value:!0}),rb.BoxPlotDataSeries=void 0;var i=di(),n=ym(),r=Yo(),o=eC(),a=bo(),s=Bu(),l=zi(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,e(e({},h),{arrayCount:5,valueNames:[r.EValueName.BoxPlotMedian,r.EValueName.BoxPlotMax,r.EValueName.BoxPlotUpper,r.EValueName.BoxPlotLower,r.EValueName.BoxPlotMinimum],includeInYRange:[!0,!0,!0,!0,!0]}))||this;return p.type=l.EDataSeriesType.BoxPlot,h!=null&&h.xValues&&(p.appendRange(h.xValues,h.maximumValues,h.upperQuartileValues,h.medianValues,h.lowerQuartileValues,h.minimumValues,h.metadata),h!=null&&h.fifoCapacity&&(h!=null&&h.fifoStartIndex)&&(p.xValues.notifyAppend(h==null?void 0:h.fifoStartIndex),p.medianValues.notifyAppend(h==null?void 0:h.fifoStartIndex),p.maximumValues.notifyAppend(h==null?void 0:h.fifoStartIndex),p.upperQuartileValues.notifyAppend(h==null?void 0:h.fifoStartIndex),p.lowerQuartileValues.notifyAppend(h==null?void 0:h.fifoStartIndex),p.minimumValues.notifyAppend(h==null?void 0:h.fifoStartIndex))),p}return Object.defineProperty(d.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"medianValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"maximumValues",{get:function(){return this.getNativeMaximumValues()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"upperQuartileValues",{get:function(){return this.getNativeUpperQuartileValues()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"lowerQuartileValues",{get:function(){return this.getNativeLowerQuartileValues()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"minimumValues",{get:function(){return this.getNativeMinimumValues()},enumerable:!1,configurable:!0}),d.prototype.getNativeMaximumValues=function(){return this.getNativeYValues(1)},d.prototype.getNativeUpperQuartileValues=function(){return this.getNativeYValues(2)},d.prototype.getNativeMedianValues=function(){return this.getNativeYValues()},d.prototype.getNativeLowerQuartileValues=function(){return this.getNativeYValues(3)},d.prototype.getNativeMinimumValues=function(){return this.getNativeYValues(4)},d.prototype.append=function(f,h,p,g,v,y,m){c.prototype.appendN.call(this,f,[g,h,p,v,y],m)},d.prototype.appendRange=function(f,h,p,g,v,y,m){c.prototype.appendRangeN.call(this,f,[g,h,p,v,y],m)},d.prototype.update=function(f,h,p,g,v,y,m){c.prototype.updateN.call(this,f,[h,p,g,v,y],m)},d.prototype.updateXBoxPlot=function(f,h,p,g,v,y,m,b){c.prototype.updateXyN.call(this,f,h,[v,p,g,y,m],b)},d.prototype.insert=function(f,h,p,g,v,y,m,b){c.prototype.insertN.call(this,f,h,[v,p,g,y,m],b)},d.prototype.insertRange=function(f,h,p,g,v,y,m,b){c.prototype.insertRangeN.call(this,f,h,[v,p,g,y,m],b)},d.prototype.getWindowedYRange=function(f,h,p,g,v){p===void 0&&(p=!1),g===void 0&&(g=l.EDataSeriesValueType.Default),v===void 0&&(v=o.EYRangeMode.Visible);var y=this.getBoxPlotValues(g),m=y.maximumValues,b=y.minimumValues;if(this.count()===1)return new i.NumberRange(m.get(0),b.get(0));var S=p?f:this.getIndicesRange(f,!1,v===o.EYRangeMode.Visible?n.ESearchMode.RoundUp:n.ESearchMode.RoundDown,v===o.EYRangeMode.Visible?n.ESearchMode.RoundDown:n.ESearchMode.RoundUp),_=Number.MAX_VALUE,C=Number.NEGATIVE_INFINITY,P=Math.max(S.min,0),x=Math.min(S.max,this.count()-1);if(!(x<P)){for(var E=P;E<=x;E++){var A=m.get(E),R=b.get(E);R<_&&(_=R),A>C&&(C=A)}return new i.NumberRange(_,C)}},d.prototype.getOptions=function(f){f===void 0&&(f=!1);var h=c.prototype.getOptions.call(this,f);if(!f){var p=(0,a.vectorToArray)(this.xValues,this.webAssemblyContext),g=(0,a.vectorToArray)(this.maximumValues,this.webAssemblyContext),v=(0,a.vectorToArray)(this.upperQuartileValues,this.webAssemblyContext),y=(0,a.vectorToArray)(this.medianValues,this.webAssemblyContext),m=(0,a.vectorToArray)(this.lowerQuartileValues,this.webAssemblyContext),b=(0,a.vectorToArray)(this.minimumValues,this.webAssemblyContext),S={xValues:p,maximumValues:g,upperQuartileValues:v,medianValues:y,lowerQuartileValues:m,minimumValues:b};Object.assign(h,S)}return h},d.prototype.getBoxPlotValues=function(f){var h,p;switch(f){case l.EDataSeriesValueType.FinalAnimationValues:h=this.yFinalAnimationValuesArray[1],p=this.yFinalAnimationValuesArray[4];break;case l.EDataSeriesValueType.InitialAnimationValues:h=this.yInitialAnimationValuesArray[1],p=this.yInitialAnimationValuesArray[4];break;default:h=this.maximumValues,p=this.minimumValues}return{maximumValues:h,minimumValues:p}},d})(s.BaseDataSeries);return rb.BoxPlotDataSeries=u,rb}var ib={},V9={},Xme;function Mm(){return Xme||(Xme=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDataFilterType=void 0,(function(e){e.XyLinearTrend="XyLinearTrend",e.XyMovingAverage="XyMovingAverage",e.XyRatio="XyRatio",e.XyScaleOffset="XyScaleOffset",e.XyyScaleOffset="XyyScaleOffset",e.XyzScaleOffset="XyzScaleOffset",e.HlcScaleOffset="HlcScaleOffset",e.OhlcScaleOffset="OhlcScaleOffset"})(t.EDataFilterType||(t.EDataFilterType={}))})(V9)),V9}var Ox={},Dx={},nb={},Kme;function gie(){if(Kme)return nb;Kme=1;var t=nb&&nb.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})(),e=nb&&nb.__assign||function(){return e=Object.assign||function(h){for(var p,g=1,v=arguments.length;g<v;g++){p=arguments[g];for(var y in p)Object.prototype.hasOwnProperty.call(p,y)&&(h[y]=p[y])}return h},e.apply(this,arguments)};Object.defineProperty(nb,"__esModule",{value:!0}),nb.HlcDataSeries=void 0;var i=Br(),n=ci(),r=di(),o=ym(),a=Yo(),s=eC(),l=kp(),u=bo(),c=Bu(),d=zi(),f=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,e(e({},v),{arrayCount:3,valueNames:[a.EValueName.Close,a.EValueName.High,a.EValueName.Low],includeInYRange:[!0,!0,!0]}))||this;return y.type=d.EDataSeriesType.Hlc,v!=null&&v.xValues&&(n.Guard.notNull(v.yValues,"options.yValues"),n.Guard.notNull(v.highValues,"options.highValues"),n.Guard.notNull(v.lowValues,"options.lowValues"),y.appendRange(v.xValues,v.yValues,v.highValues,v.lowValues,v.metadata),v!=null&&v.fifoCapacity&&(v!=null&&v.fifoStartIndex)&&(y.xValues.notifyAppend(v==null?void 0:v.fifoStartIndex),y.yValues.notifyAppend(v==null?void 0:v.fifoStartIndex),y.highValues.notifyAppend(v==null?void 0:v.fifoStartIndex),y.lowValues.notifyAppend(v==null?void 0:v.fifoStartIndex))),y}return Object.defineProperty(p.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"highValues",{get:function(){return this.getNativeYValues(1)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"lowValues",{get:function(){return this.getNativeYValues(2)},enumerable:!1,configurable:!0}),p.prototype.getNativeHighValues=function(){return this.highValues},p.prototype.getNativeLowValues=function(){return this.lowValues},p.prototype.append=function(g,v,y,m,b){h.prototype.appendN.call(this,g,[v,y,m],b)},p.prototype.appendRange=function(g,v,y,m,b){h.prototype.appendRangeN.call(this,g,[v,y,m],b)},p.prototype.update=function(g,v,y,m,b){h.prototype.updateN.call(this,g,[v,y,m],b)},p.prototype.updateXyhl=function(g,v,y,m,b,S){h.prototype.updateXyN.call(this,g,v,[y,m,b],S)},p.prototype.insert=function(g,v,y,m,b,S){h.prototype.insertN.call(this,g,v,[y,m,b],S)},p.prototype.insertRange=function(g,v,y,m,b,S){h.prototype.insertRangeN.call(this,g,v,[y,m,b],S)},p.prototype.getXRange=function(g,v,y,m){var b=this.getXValues(g),S=this.getHlcValues(g),_=S.hValues,C=S.lValues,P;if(v){if(this.count()===1){var x=m?C:b,E=y?_:b,A=x.get(0)-1,R=E.get(0)+1;return new r.NumberRange(A,R)}else if(this.count()>1){var A=void 0,R=void 0,M=void 0;try{if(M=this.webAssemblyContext.NumberUtil.MinMax(m?this.getNativeLowValues():this.getNativeXValues(),this.dataDistributionCalculator.containsNaN),A=M.minD,M=this.webAssemblyContext.NumberUtil.MinMax(y?this.getNativeHighValues():this.getNativeXValues(),this.dataDistributionCalculator.containsNaN),R=M.maxD,!(0,l.isRealNumber)(A)||!(0,l.isRealNumber)(R))return new r.NumberRange(0,0)}finally{(0,i.deleteSafe)(M)}return A===R?new r.NumberRange(A-1,R+1):(A>R&&(P=A,A=R,R=P),new r.NumberRange(A,R))}}else if(this.count()===1){var A=b.get(0)-1,R=b.get(0)+1;return new r.NumberRange(A,R)}else if(this.count()>1){var A=b.get(0),R=b.get(this.count()-1);if(!this.dataDistributionCalculator.isSortedAscending){var M=void 0;try{if(M=this.webAssemblyContext.NumberUtil.MinMax(this.getNativeXValues(),!1),!(0,l.isRealNumber)(M.minD)||!(0,l.isRealNumber)(M.maxD))return new r.NumberRange(0,0);A=M.minD,R=M.maxD}finally{(0,i.deleteSafe)(M)}}return A===R?new r.NumberRange(A-1,R+1):(A>R&&(P=A,A=R,R=P),new r.NumberRange(A,R))}return new r.NumberRange(0,0)},p.prototype.getWindowedYRange=function(g,v,y,m,b,S,_,C){y===void 0&&(y=!1),m===void 0&&(m=d.EDataSeriesValueType.Default),b===void 0&&(b=s.EYRangeMode.Visible),S===void 0&&(S=!1);var P=this.getHlcValues(m),x=P.hValues,E=P.lValues,A=P.yValues;if(this.count()===1&&!S)if(S){var R=A.get(0);return new r.NumberRange(R,R)}else{var M=Math.min(x.get(0),E.get(0)),D=Math.max(x.get(0),E.get(0));return new r.NumberRange(M,D)}var F=y?g:this.getIndicesRange(g,!1,b===s.EYRangeMode.Visible?o.ESearchMode.RoundUp:o.ESearchMode.RoundDown,b===s.EYRangeMode.Visible?o.ESearchMode.RoundDown:o.ESearchMode.RoundUp),I=Number.MAX_VALUE,V=Number.NEGATIVE_INFINITY,z=Math.max(Math.floor(F.min),0),G=Math.min(Math.ceil(F.max),this.count()-1);if(!(G<z)){if(S){var H=void 0;try{if(H=this.webAssemblyContext.NumberUtil.MinMaxWithIndex(A,z,G-z+1,this.dataDistributionCalculator.containsNaN),!(0,l.isRealNumber)(H.minD)||!(0,l.isRealNumber)(H.maxD))return;I=H.minD,V=H.maxD}finally{(0,i.deleteSafe)(H)}}else{var U=_?x:A,k=C?E:A,H=void 0;try{if(H=this.webAssemblyContext.NumberUtil.MinMaxWithIndex(U,z,G-z+1,this.dataDistributionCalculator.containsNaN),!(0,l.isRealNumber)(H.minD)||!(0,l.isRealNumber)(H.maxD)||(V=H.maxD,H=this.webAssemblyContext.NumberUtil.MinMaxWithIndex(k,z,G-z+1,this.dataDistributionCalculator.containsNaN),!(0,l.isRealNumber)(H.minD)||!(0,l.isRealNumber)(H.maxD)))return;I=H.minD}finally{(0,i.deleteSafe)(H)}}return new r.NumberRange(I,V)}},p.prototype.getOptions=function(g){g===void 0&&(g=!1);var v=h.prototype.getOptions.call(this,g);if(!g){var y=(0,u.vectorToArray)(this.xValues,this.webAssemblyContext),m=(0,u.vectorToArray)(this.yValues,this.webAssemblyContext),b=(0,u.vectorToArray)(this.highValues,this.webAssemblyContext),S=(0,u.vectorToArray)(this.lowValues,this.webAssemblyContext),_={xValues:y,yValues:m,highValues:b,lowValues:S};Object.assign(v,_)}return v},p.prototype.getHlcValues=function(g){var v,y,m;switch(g){case d.EDataSeriesValueType.FinalAnimationValues:v=this.yFinalAnimationValuesArray[1],y=this.yFinalAnimationValuesArray[2],m=this.yFinalAnimationValuesArray[0];break;case d.EDataSeriesValueType.InitialAnimationValues:v=this.yInitialAnimationValuesArray[1],y=this.yInitialAnimationValuesArray[2],m=this.yInitialAnimationValuesArray[0];break;default:v=this.highValues,y=this.lowValues,m=this.yValues}return{hValues:v,lValues:y,yValues:m}},p})(c.BaseDataSeries);return nb.HlcDataSeries=f,nb}var jF={},ob={},Rx={},Mx={},Zme;function jI(){if(Zme)return Mx;Zme=1;var t=Mx&&Mx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Mx,"__esModule",{value:!0}),Mx.BasePointSeriesResampled=void 0;var e=fo(),i=Yo(),n=zi(),r=(function(o){t(a,o);function a(s,l,u,c){u===void 0&&(u=1);var d=o.call(this)||this;d.type=n.EDataSeriesType.Xy,d.yValuesArray=[],d.arrayCount=1,d.resampled=!0,d.wasmContext=s,d.arrayCount=u,d.intIndexes=new s.IntVector,d.indexes=new s.SCRTDoubleVector,d.xValues=new s.SCRTDoubleVector;for(var f=0;f<d.arrayCount;f++)d.yValuesArray.push(new s.SCRTDoubleVector);return d.valueNames=c??(0,i.generateValueNamesForDataSeries)(d.yValuesArray.length),d.xRange=l,d}return Object.defineProperty(a.prototype,"count",{get:function(){return this.xValues.size()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"yValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),a.prototype.getYValues=function(s,l){return l===void 0&&(l=!0),s<this.arrayCount?this.yValuesArray[s]:l&&s!==void 0?void 0:this.yValuesArray[0]},a.prototype.getYValuesByName=function(s,l){l===void 0&&(l=!0);var u=this.valueNames.indexOf(s);return u>=0?this.getYValues(u,l):l?void 0:this.yValuesArray[0]},a.prototype.delete=function(){this.intIndexes.delete(),this.indexes.delete(),this.xValues.delete(),this.yValuesArray.forEach(function(s){return s.delete()}),this.yValuesArray.length=0,this.wasmContext=void 0},a.prototype.clearIntIndexes=function(){this.intIndexes.clear()},a.prototype.debugOutputForUnitTests=function(){console.log("points count ".concat(this.count)),console.log("xResampled at min",this.xValues.get(0)),console.log("openResampled at min",this.yValues.get(0));var s=Math.round(this.count/2);console.log("middle",s),console.log("xResampled at middle",this.xValues.get(s)),console.log("yValues at middle",this.yValues.get(s));var l=this.count-1;console.log("xResampled at end",this.xValues.get(l)),console.log("yValues at end",this.yValues.get(l))},a})(e.DeletableEntity);return Mx.BasePointSeriesResampled=r,Mx}var Jme;function lR(){if(Jme)return Rx;Jme=1;var t=Rx&&Rx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Rx,"__esModule",{value:!0}),Rx.XyPointSeriesResampled=void 0;var e=Yo(),i=zi(),n=jI(),r=(function(o){t(a,o);function a(s,l,u){u===void 0&&(u=e.EValueName.Y);var c=o.call(this,s,l,1,[u])||this;return c.type=i.EDataSeriesType.Xy,c}return a})(n.BasePointSeriesResampled);return Rx.XyPointSeriesResampled=r,Rx}var Qme;function vie(){if(Qme)return ob;Qme=1;var t=ob&&ob.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=ob&&ob.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(ob,"__esModule",{value:!0}),ob.XyDataSeries=void 0;var i=ci(),n=Yo(),r=bo(),o=Bu(),a=zi(),s=lR(),l=DI(),u=(function(c){t(d,c);function d(f,h){var p=this,g=e(e({},h),{arrayCount:1,valueNames:[n.EValueName.Y],includeInYRange:[!0]});return p=c.call(this,f,g)||this,p.type=a.EDataSeriesType.Xy,g!=null&&g.xValues&&(i.Guard.notNull(g.yValues,"options.yValues"),p.appendRange(g.xValues,g.yValues,g.metadata),g!=null&&g.fifoCapacity&&(g!=null&&g.fifoStartIndex)&&(p.xValues.notifyAppend(g==null?void 0:g.fifoStartIndex),p.yValues.notifyAppend(g==null?void 0:g.fifoStartIndex))),p}return Object.defineProperty(d.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),d.prototype.append=function(f,h,p){c.prototype.appendN.call(this,f,[h],p,void 0)},d.prototype.appendRange=function(f,h,p){c.prototype.appendRangeN.call(this,f,[h],p)},d.prototype.update=function(f,h,p){c.prototype.updateN.call(this,f,[h],p)},d.prototype.updateXy=function(f,h,p,g){c.prototype.updateXyN.call(this,f,h,[p],g)},d.prototype.insert=function(f,h,p,g){c.prototype.insertN.call(this,f,h,[p],g)},d.prototype.insertRange=function(f,h,p,g){c.prototype.insertRangeN.call(this,f,h,[p],g)},d.prototype.toPointSeries=function(f,h,p){if(f){h?h.xRange=f.xVisibleRange:h=new s.XyPointSeriesResampled(this.webAssemblyContext,f.xVisibleRange),i.Guard.notNull(p,"resamplerHelper");var g=p.resampleIntoPointSeries(this.webAssemblyContext,f,this.getNativeXValues(),this.getNativeYValues(),h.intIndexes,h.indexes,h.xValues,h.yValues,!1);return h.fifoStartIndex=g.OutputSplitIndex,h.clearIntIndexes(),h}else return new l.XyPointSeriesWrapped(this)},d.prototype.getOptions=function(f){f===void 0&&(f=!1);var h=c.prototype.getOptions.call(this,f);if(!f){var p=(0,r.vectorToArray)(this.xValues,this.webAssemblyContext),g=(0,r.vectorToArray)(this.yValues,this.webAssemblyContext),v={xValues:p,yValues:g};Object.assign(h,v)}return h},d})(o.BaseDataSeries);return ob.XyDataSeries=u,ob}var e0e;function sm(){return e0e||(e0e=1,(function(t){var e=jF&&jF.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.switchData=t.XyFilterBase=t.EDataSeriesField=void 0;var i=Br(),n=zi(),r=vie(),o;(function(l){l.X="x",l.Open="open",l.High="high",l.Low="low",l.Close="close",l.Y="y",l.Y1="y1",l.Z="z"})(o=t.EDataSeriesField||(t.EDataSeriesField={}));var a=(function(l){e(u,l);function u(c,d){var f=this,h,p;switch(f=l.call(this,c.webAssemblyContext,d)||this,f.field=o.Y,f.xField=o.X,f.originalSeriesProperty=c,f.field=(h=d==null?void 0:d.field)!==null&&h!==void 0?h:f.field,f.xField=(p=d==null?void 0:d.xField)!==null&&p!==void 0?p:f.xField,f.onBaseDataChanged=f.onBaseDataChanged.bind(f),c.dataChanged.subscribe(f.onBaseDataChanged),f.originalSeries.type){case n.EDataSeriesType.Xy:f.xField===o.Y&&(f.getOriginalXValues=function(){return f.originalSeries.getNativeYValues()}),f.field===o.X&&(f.getOriginalYValues=function(){return f.originalSeries.getNativeXValues()});break;case n.EDataSeriesType.Ohlc:f.getOriginalXValues=function(){return f.getValuesFromOHLC(f.xField,f.originalSeries)},f.getOriginalYValues=function(){return f.getValuesFromOHLC(f.field,f.originalSeries)};break;case n.EDataSeriesType.Xyy:f.getOriginalXValues=function(){return f.getValuesFromXyy(f.xField,f.originalSeries)},f.getOriginalYValues=function(){return f.getValuesFromXyy(f.field,f.originalSeries)};break;case n.EDataSeriesType.Xyz:f.getOriginalXValues=function(){return f.getValuesFromXyz(f.xField,f.originalSeries)},f.getOriginalYValues=function(){return f.getValuesFromXyz(f.field,f.originalSeries)};break;case n.EDataSeriesType.Hlc:f.getOriginalXValues=function(){return f.getValuesFromHlc(f.xField,f.originalSeries)},f.getOriginalYValues=function(){return f.getValuesFromHlc(f.field,f.originalSeries)};break}return f}return Object.defineProperty(u.prototype,"originalSeries",{get:function(){return this.originalSeriesProperty},enumerable:!1,configurable:!0}),u.prototype.detachFromOriginalSeries=function(){this.originalSeries.dataChanged.unsubscribe(this.onBaseDataChanged),this.originalSeriesProperty=void 0},u.prototype.delete=function(){this.originalSeriesProperty=(0,i.deleteSafe)(this.originalSeries),l.prototype.delete.call(this)},u.prototype.getOriginalXValues=function(){return this.originalSeries.getNativeXValues()},u.prototype.getOriginalYValues=function(){return this.originalSeries.getNativeYValues()},u.prototype.getOriginalCount=function(){return this.originalSeries.count()},u.prototype.onOriginalPropertyChanged=function(c){},u.prototype.filterOnAppend=function(c){this.filterAll()},u.prototype.filterOnUpdate=function(c){this.filterAll()},u.prototype.filterOnInsert=function(c,d){this.filterAll()},u.prototype.filterOnRemove=function(c,d){this.filterAll()},u.prototype.onClear=function(){this.clear()},u.prototype.onBaseDataChanged=function(c){var d=c.changeType,f=c.name,h=c.index,p=c.count;switch(d){case n.EDataChangeType.Property:this.onOriginalPropertyChanged(f);return;case n.EDataChangeType.Append:this.filterOnAppend(p);break;case n.EDataChangeType.Clear:this.onClear();break;case n.EDataChangeType.Insert:this.filterOnInsert(h,p);break;case n.EDataChangeType.Remove:this.filterOnRemove(h,p);break;case n.EDataChangeType.Update:this.filterOnUpdate(h);break}},u.prototype.getValuesFromOHLC=function(c,d){return(0,t.switchData)(c,d.getNativeXValues(),d.getNativeYValues(),d.getNativeOpenValues(),d.getNativeHighValues(),d.getNativeLowValues())},u.prototype.getValuesFromXyy=function(c,d){return(0,t.switchData)(c,d.getNativeXValues(),d.getNativeYValues(),d.getNativeY1Values())},u.prototype.getValuesFromXyz=function(c,d){return(0,t.switchData)(c,d.getNativeXValues(),d.getNativeYValues(),d.getNativeZValues())},u.prototype.getValuesFromHlc=function(c,d){return(0,t.switchData)(c,d.getNativeXValues(),d.getNativeYValues(),void 0,d.getNativeHighValues(),d.getNativeLowValues())},u})(r.XyDataSeries);t.XyFilterBase=a;var s=function(l,u,c,d,f,h){var p;switch(l){case o.X:p=u;break;case o.Close:case o.Y:p=c;break;case o.Open:case o.Y1:case o.Z:p=d;break;case o.High:p=f;break;case o.Low:p=h;break}if(!p)throw new Error("".concat(l," does not exist"));return p};t.switchData=s})(jF)),jF}var t0e;function gBe(){if(t0e)return Dx;t0e=1;var t=Dx&&Dx.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Dx,"__esModule",{value:!0}),Dx.HlcFilterBase=void 0;var e=Br(),i=gie(),n=zi(),r=sm(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;switch(c=a.call(this,l.webAssemblyContext,u)||this,c.closefield=r.EDataSeriesField.Close,c.highfield=r.EDataSeriesField.High,c.lowfield=r.EDataSeriesField.Low,c.originalSeriesProperty=l,c.closefield=(d=u==null?void 0:u.closefield)!==null&&d!==void 0?d:c.closefield,c.highfield=(f=u==null?void 0:u.highfield)!==null&&f!==void 0?f:c.highfield,c.onBaseDataChanged=c.onBaseDataChanged.bind(c),l.dataChanged.subscribe(c.onBaseDataChanged),c.originalSeries.type){case n.EDataSeriesType.Ohlc:var h=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.closefield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())},c.getOriginalHighValues=function(){return(0,r.switchData)(c.highfield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())},c.getOriginalLowValues=function(){return(0,r.switchData)(c.lowfield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())};break;case n.EDataSeriesType.Xy:var p=c.originalSeries;c.getOriginalYValues=function(){return p.getNativeYValues()},c.getOriginalHighValues=function(){return p.getNativeYValues()},c.getOriginalLowValues=function(){return p.getNativeYValues()};break;case n.EDataSeriesType.Xyy:var g=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.closefield,g.getNativeYValues(),g.getNativeY1Values())},c.getOriginalHighValues=function(){return(0,r.switchData)(c.highfield,g.getNativeYValues(),g.getNativeY1Values())},c.getOriginalLowValues=function(){return(0,r.switchData)(c.lowfield,g.getNativeYValues(),g.getNativeY1Values())};break;case n.EDataSeriesType.Xyz:var v=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.closefield,v.getNativeYValues(),v.getNativeZValues())},c.getOriginalHighValues=function(){return(0,r.switchData)(c.highfield,v.getNativeYValues(),v.getNativeZValues())},c.getOriginalLowValues=function(){return(0,r.switchData)(c.lowfield,v.getNativeYValues(),v.getNativeZValues())};break}return c}return Object.defineProperty(s.prototype,"originalSeries",{get:function(){return this.originalSeriesProperty},enumerable:!1,configurable:!0}),s.prototype.detachFromOriginalSeries=function(){this.originalSeries.dataChanged.unsubscribe(this.onBaseDataChanged),this.originalSeriesProperty=void 0},s.prototype.delete=function(){this.originalSeriesProperty=(0,e.deleteSafe)(this.originalSeries),a.prototype.delete.call(this)},s.prototype.getOriginalXValues=function(){return this.originalSeries.getNativeXValues()},s.prototype.getOriginalYValues=function(){return this.originalSeries.getNativeYValues()},s.prototype.getOriginalHighValues=function(){return this.originalSeries.getNativeHighValues()},s.prototype.getOriginalLowValues=function(){return this.originalSeries.getNativeLowValues()},s.prototype.getOriginalCount=function(){return this.originalSeries.count()},s.prototype.onOriginalPropertyChanged=function(l){},s.prototype.filterOnAppend=function(l){this.filterAll()},s.prototype.filterOnUpdate=function(l){this.filterAll()},s.prototype.filterOnInsert=function(l,u){this.filterAll()},s.prototype.filterOnRemove=function(l,u){this.filterAll()},s.prototype.onClear=function(){this.clear()},s.prototype.onBaseDataChanged=function(l){var u=l.changeType,c=l.name,d=l.index,f=l.count;switch(u){case n.EDataChangeType.Property:this.onOriginalPropertyChanged(c);return;case n.EDataChangeType.Append:this.filterOnAppend(f);break;case n.EDataChangeType.Clear:this.onClear();break;case n.EDataChangeType.Insert:this.filterOnInsert(d,f);break;case n.EDataChangeType.Remove:this.filterOnRemove(d,f);break;case n.EDataChangeType.Update:this.filterOnUpdate(d);break}},s})(i.HlcDataSeries);return Dx.HlcFilterBase=o,Dx}var r0e;function vBe(){if(r0e)return Ox;r0e=1;var t=Ox&&Ox.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Ox,"__esModule",{value:!0}),Ox.HlcCustomFilter=void 0;var e=zi(),i=gBe(),n=bo(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d,f;if(u=o.call(this,s,l)||this,s.type!==e.EDataSeriesType.Hlc)throw new Error("HlcCustomFilter only supports Hlc original series");return u.closefilterFunctionProperty=(c=l==null?void 0:l.closefilterFunction)!==null&&c!==void 0?c:u.closefilterFunctionProperty,u.highfilterFunctionProperty=(d=l==null?void 0:l.highfilterFunction)!==null&&d!==void 0?d:u.closefilterFunction,u.lowfilterFunctionProperty=(f=l==null?void 0:l.lowfilterFunction)!==null&&f!==void 0?f:u.closefilterFunction,u.getOriginalCount()>0&&(l!=null&&l.closefilterFunction||l!=null&&l.highfilterFunction||l!=null&&l.lowfilterFunction)&&u.filterAll(),u}return Object.defineProperty(a.prototype,"closefilterFunction",{get:function(){return this.closefilterFunctionProperty},set:function(s){this.closefilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"highfilterFunction",{get:function(){return this.highfilterFunctionProperty},set:function(s){this.highfilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowfilterFunction",{get:function(){return this.lowfilterFunctionProperty},set:function(s){this.lowfilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),a.prototype.highfilterFunctionProperty=function(s,l){return l},a.prototype.lowfilterFunctionProperty=function(s,l){return l},a.prototype.closefilterFunctionProperty=function(s,l){return l},a.prototype.filterOnAppend=function(s){var l=this.filter(this.count(),s),u=l.xValues,c=l.highValues,d=l.lowValues,f=l.closeValues,h=l.metadata;this.appendRange(u,f,c,d,h)},a.prototype.filterOnUpdate=function(s){var l=this.originalSeries;this.update(s,this.highfilterFunction(s,l.getNativeHighValues().get(s)),this.lowfilterFunction(s,l.getNativeLowValues().get(s)),this.closefilterFunction(s,l.getNativeYValues().get(s)),this.originalSeries.getMetadataAt(s))},a.prototype.filterOnInsert=function(s,l){var u=this.filter(s,l),c=u.xValues,d=u.highValues,f=u.lowValues,h=u.closeValues,p=u.metadata;this.insertRange(s,c,h,d,f,p)},a.prototype.filterOnRemove=function(s,l){this.removeRange(s,l)},a.prototype.filterAll=function(){this.clear();var s=this.filter(0,this.getOriginalCount()),l=s.xValues,u=s.highValues,c=s.lowValues,d=s.closeValues,f=s.metadata;this.appendRange(l,d,u,c,f)},a.prototype.filter=function(s,l){var u=(0,n.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),c=(0,n.vectorToArrayViewF64)(this.getOriginalHighValues(),this.webAssemblyContext),d=(0,n.vectorToArrayViewF64)(this.getOriginalLowValues(),this.webAssemblyContext),f=(0,n.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),h=[],p=[],g=[],v=[],y=void 0;if(this.originalSeries.hasMetadata){y=[];for(var m=s;m<s+l;m++)h.push(u[m]),p.push(this.highfilterFunction(m,c[m])),g.push(this.lowfilterFunction(m,d[m])),v.push(this.closefilterFunction(m,f[m])),y.push(this.originalSeries.getMetadataAt(m))}else for(var m=s;m<s+l;m++)h.push(u[m]),p.push(this.highfilterFunction(m,c[m])),g.push(this.lowfilterFunction(m,d[m])),v.push(this.closefilterFunction(m,f[m]));return{xValues:h,highValues:p,lowValues:g,closeValues:v,metadata:y}},a})(i.HlcFilterBase);return Ox.HlcCustomFilter=r,Ox}var i0e;function yBe(){if(i0e)return ib;i0e=1;var t=ib&&ib.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=ib&&ib.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(ib,"__esModule",{value:!0}),ib.HlcScaleOffsetFilter=void 0;var i=Mm(),n=zi(),r=vBe(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;if(c=a.call(this,l,u)||this,c.scaleProperty=1,c.offsetProperty=0,l.type!==n.EDataSeriesType.Hlc)throw new Error("HlcScaleOffsetFilter only supports Hlc original series");return c.scaleProperty=(d=u==null?void 0:u.scale)!==null&&d!==void 0?d:c.scaleProperty,c.offsetProperty=(f=u==null?void 0:u.offset)!==null&&f!==void 0?f:c.offsetProperty,c.getOriginalCount()>0&&c.filterAll(),c}return Object.defineProperty(s.prototype,"scale",{get:function(){return this.scaleProperty},set:function(l){this.scaleProperty=l,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"offset",{get:function(){return this.offsetProperty},set:function(l){this.offsetProperty=l,this.filterAll()},enumerable:!1,configurable:!0}),s.prototype.toJSON=function(l){l===void 0&&(l=!1);var u=this.originalSeries.toJSON(l);return e(e({},u),{filter:{type:i.EDataFilterType.HlcScaleOffset,options:{scale:this.scale,offset:this.offset}}})},s.prototype.defaultFunction=function(l,u){return u*this.scaleProperty+this.offsetProperty},s})(r.HlcCustomFilter);return ib.HlcScaleOffsetFilter=o,ib}var ab={},Lx={},kx={},ov={},n0e;function $3(){if(n0e)return ov;n0e=1;var t=ov&&ov.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})(),e=ov&&ov.__assign||function(){return e=Object.assign||function(d){for(var f,h=1,p=arguments.length;h<p;h++){f=arguments[h];for(var g in f)Object.prototype.hasOwnProperty.call(f,g)&&(d[g]=f[g])}return d},e.apply(this,arguments)};Object.defineProperty(ov,"__esModule",{value:!0}),ov.getOHLCYRange=ov.OhlcDataSeries=void 0;var i=di(),n=ym(),r=Yo(),o=eC(),a=bo(),s=Bu(),l=zi(),u=(function(d){t(f,d);function f(h,p){var g=this,v=e(e({},p),{arrayCount:4,valueNames:[r.EValueName.Close,r.EValueName.Open,r.EValueName.High,r.EValueName.Low],includeInYRange:[!0,!0,!0,!0]});return g=d.call(this,h,v)||this,g.type=l.EDataSeriesType.Ohlc,v!=null&&v.xValues&&(g.appendRange(v.xValues,v.openValues,v.highValues,v.lowValues,v.closeValues,v.metadata),v!=null&&v.fifoCapacity&&(v!=null&&v.fifoStartIndex)&&(g.xValues.notifyAppend(v==null?void 0:v.fifoStartIndex),g.yValues.notifyAppend(v==null?void 0:v.fifoStartIndex),g.openValues.notifyAppend(v==null?void 0:v.fifoStartIndex),g.highValues.notifyAppend(v==null?void 0:v.fifoStartIndex),g.lowValues.notifyAppend(v==null?void 0:v.fifoStartIndex))),g}return Object.defineProperty(f.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"openValues",{get:function(){return this.getNativeOpenValues()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"highValues",{get:function(){return this.getNativeHighValues()},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"lowValues",{get:function(){return this.getNativeLowValues()},enumerable:!1,configurable:!0}),f.prototype.getNativeOpenValues=function(){return this.getNativeYValues(1)},f.prototype.getNativeHighValues=function(){return this.getNativeYValues(2)},f.prototype.getNativeLowValues=function(){return this.getNativeYValues(3)},f.prototype.getNativeCloseValues=function(){return this.getNativeYValues()},f.prototype.append=function(h,p,g,v,y,m){d.prototype.appendN.call(this,h,[y,p,g,v],m)},f.prototype.appendRange=function(h,p,g,v,y,m){d.prototype.appendRangeN.call(this,h,[y,p,g,v],m)},f.prototype.update=function(h,p,g,v,y,m){d.prototype.updateN.call(this,h,[y,p,g,v],m)},f.prototype.updateXohlc=function(h,p,g,v,y,m,b){d.prototype.updateXyN.call(this,h,p,[m,g,v,y],b)},f.prototype.insert=function(h,p,g,v,y,m,b){d.prototype.insertN.call(this,h,p,[m,g,v,y],b)},f.prototype.insertRange=function(h,p,g,v,y,m,b){d.prototype.insertRangeN.call(this,h,p,[m,g,v,y],b)},f.prototype.getWindowedYRange=function(h,p,g,v,y){g===void 0&&(g=!1),v===void 0&&(v=l.EDataSeriesValueType.Default),y===void 0&&(y=o.EYRangeMode.Visible);var m=this.getOHLCValues(v),b=m.openValues,S=m.closeValues,_=m.highValues,C=m.lowValues;if(this.count()===1){var P=Math.min(b.get(0),C.get(0)),x=Math.max(S.get(0),_.get(0));return new i.NumberRange(P,x)}var E=g?h:this.getIndicesRange(h,!1,y===o.EYRangeMode.Visible?n.ESearchMode.RoundUp:n.ESearchMode.RoundDown,y===o.EYRangeMode.Visible?n.ESearchMode.RoundDown:n.ESearchMode.RoundUp);return c(E,b,_,C)},f.prototype.getOptions=function(h){h===void 0&&(h=!1);var p=d.prototype.getOptions.call(this,h);if(!h){var g=(0,a.vectorToArray)(this.xValues,this.webAssemblyContext),v=(0,a.vectorToArray)(this.openValues,this.webAssemblyContext),y=(0,a.vectorToArray)(this.highValues,this.webAssemblyContext),m=(0,a.vectorToArray)(this.lowValues,this.webAssemblyContext),b=(0,a.vectorToArray)(this.yValues,this.webAssemblyContext),S={xValues:g,openValues:v,highValues:y,lowValues:m,closeValues:b};Object.assign(p,S)}return p},f.prototype.getOHLCValues=function(h){var p,g,v,y;switch(h){case l.EDataSeriesValueType.FinalAnimationValues:p=this.yFinalAnimationValuesArray[1],g=this.yFinalAnimationValuesArray[2],v=this.yFinalAnimationValuesArray[3],y=this.yFinalAnimationValuesArray[0];break;case l.EDataSeriesValueType.InitialAnimationValues:p=this.yInitialAnimationValuesArray[1],g=this.yInitialAnimationValuesArray[2],v=this.yInitialAnimationValuesArray[3],y=this.yInitialAnimationValuesArray[0];break;default:p=this.openValues,g=this.highValues,v=this.lowValues,y=this.yValues}return{openValues:p,highValues:g,lowValues:v,closeValues:y}},f})(s.BaseDataSeries);ov.OhlcDataSeries=u;function c(d,f,h,p,g){var v=Number.MAX_VALUE,y=Number.NEGATIVE_INFINITY,m=Math.max(d.min,0),b=Math.min(d.max,f.size()-1);if(!(b<m)){for(var S=m;S<=b;S++){var _=h.get(S),C=p.get(S);C<v&&(v=C),_>y&&(y=_)}return new i.NumberRange(v,y)}}return ov.getOHLCYRange=c,ov}var o0e;function mBe(){if(o0e)return kx;o0e=1;var t=kx&&kx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(kx,"__esModule",{value:!0}),kx.OhlcFilterBase=void 0;var e=Br(),i=zi(),n=$3(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s.webAssemblyContext,l)||this;return u.originalSeriesProperty=s,u.onBaseDataChanged=u.onBaseDataChanged.bind(u),s.dataChanged.subscribe(u.onBaseDataChanged),u}return Object.defineProperty(a.prototype,"originalSeries",{get:function(){return this.originalSeriesProperty},enumerable:!1,configurable:!0}),a.prototype.detachFromOriginalSeries=function(){this.originalSeries.dataChanged.unsubscribe(this.onBaseDataChanged),this.originalSeriesProperty=void 0},a.prototype.delete=function(){this.originalSeriesProperty=(0,e.deleteSafe)(this.originalSeries),o.prototype.delete.call(this)},a.prototype.getOriginalXValues=function(){return this.originalSeries.getNativeXValues()},a.prototype.getOriginalOpenValues=function(){return this.originalSeries.getNativeOpenValues()},a.prototype.getOriginalYValues=function(){return this.originalSeries.getNativeYValues()},a.prototype.getOriginalHighValues=function(){return this.originalSeries.getNativeHighValues()},a.prototype.getOriginalLowValues=function(){return this.originalSeries.getNativeLowValues()},a.prototype.getOriginalCount=function(){return this.originalSeries.count()},a.prototype.onOriginalPropertyChanged=function(s){},a.prototype.filterOnAppend=function(s){this.filterAll()},a.prototype.filterOnUpdate=function(s){this.filterAll()},a.prototype.filterOnInsert=function(s,l){this.filterAll()},a.prototype.filterOnRemove=function(s,l){this.filterAll()},a.prototype.onClear=function(){this.clear()},a.prototype.onBaseDataChanged=function(s){var l=s.changeType,u=s.name,c=s.index,d=s.count;switch(l){case i.EDataChangeType.Property:this.onOriginalPropertyChanged(u);return;case i.EDataChangeType.Append:this.filterOnAppend(d);break;case i.EDataChangeType.Clear:this.onClear();break;case i.EDataChangeType.Insert:this.filterOnInsert(c,d);break;case i.EDataChangeType.Remove:this.filterOnRemove(c,d);break;case i.EDataChangeType.Update:this.filterOnUpdate(c);break}},a})(n.OhlcDataSeries);return kx.OhlcFilterBase=r,kx}var a0e;function bBe(){if(a0e)return Lx;a0e=1;var t=Lx&&Lx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Lx,"__esModule",{value:!0}),Lx.OhlcCustomFilter=void 0;var e=zi(),i=mBe(),n=bo(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d,f,h;if(u=o.call(this,s,l)||this,s.type!==e.EDataSeriesType.Ohlc)throw new Error("OhlcCustomFilter only supports Ohlc original series");return u.closefilterFunctionProperty=(c=l==null?void 0:l.closefilterFunction)!==null&&c!==void 0?c:u.closefilterFunctionProperty,u.openfilterFunctionProperty=(d=l==null?void 0:l.openfilterFunction)!==null&&d!==void 0?d:u.closefilterFunction,u.highfilterFunctionProperty=(f=l==null?void 0:l.highfilterFunction)!==null&&f!==void 0?f:u.closefilterFunction,u.lowfilterFunctionProperty=(h=l==null?void 0:l.lowfilterFunction)!==null&&h!==void 0?h:u.closefilterFunction,u.getOriginalCount()>0&&(l!=null&&l.closefilterFunction||l!=null&&l.openfilterFunction||l!=null&&l.highfilterFunction||l!=null&&l.lowfilterFunction)&&u.filterAll(),u}return Object.defineProperty(a.prototype,"closefilterFunction",{get:function(){return this.closefilterFunctionProperty},set:function(s){this.closefilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"openfilterFunction",{get:function(){return this.openfilterFunctionProperty},set:function(s){this.openfilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"highfilterFunction",{get:function(){return this.highfilterFunctionProperty},set:function(s){this.highfilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowfilterFunction",{get:function(){return this.lowfilterFunctionProperty},set:function(s){this.lowfilterFunctionProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),a.prototype.openfilterFunctionProperty=function(s,l){return l},a.prototype.highfilterFunctionProperty=function(s,l){return l},a.prototype.lowfilterFunctionProperty=function(s,l){return l},a.prototype.closefilterFunctionProperty=function(s,l){return l},a.prototype.filterOnAppend=function(s){var l=this.filter(this.count(),s),u=l.xValues,c=l.openValues,d=l.highValues,f=l.lowValues,h=l.closeValues,p=l.metadata;this.appendRange(u,c,d,f,h,p)},a.prototype.filterOnUpdate=function(s){var l=this.originalSeries;this.update(s,this.openfilterFunction(s,l.getNativeOpenValues().get(s)),this.highfilterFunction(s,l.getNativeHighValues().get(s)),this.lowfilterFunction(s,l.getNativeLowValues().get(s)),this.closefilterFunction(s,l.getNativeCloseValues().get(s)),this.originalSeries.getMetadataAt(s))},a.prototype.filterOnInsert=function(s,l){var u=this.filter(s,l),c=u.xValues,d=u.openValues,f=u.highValues,h=u.lowValues,p=u.closeValues,g=u.metadata;this.insertRange(s,c,d,f,h,p,g)},a.prototype.filterOnRemove=function(s,l){this.removeRange(s,l)},a.prototype.filterAll=function(){this.clear();var s=this.filter(0,this.getOriginalCount()),l=s.xValues,u=s.openValues,c=s.highValues,d=s.lowValues,f=s.closeValues,h=s.metadata;this.appendRange(l,u,c,d,f,h)},a.prototype.filter=function(s,l){var u=(0,n.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),c=(0,n.vectorToArrayViewF64)(this.getOriginalOpenValues(),this.webAssemblyContext),d=(0,n.vectorToArrayViewF64)(this.getOriginalHighValues(),this.webAssemblyContext),f=(0,n.vectorToArrayViewF64)(this.getOriginalLowValues(),this.webAssemblyContext),h=(0,n.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),p=[],g=[],v=[],y=[],m=[],b=void 0;if(this.originalSeries.hasMetadata){b=[];for(var S=s;S<s+l;S++)p.push(u[S]),g.push(this.openfilterFunction(S,c[S])),v.push(this.highfilterFunction(S,d[S])),y.push(this.lowfilterFunction(S,f[S])),m.push(this.closefilterFunction(S,h[S])),b.push(this.originalSeries.getMetadataAt(S))}else for(var S=s;S<s+l;S++)p.push(u[S]),g.push(this.openfilterFunction(S,c[S])),v.push(this.highfilterFunction(S,d[S])),y.push(this.lowfilterFunction(S,f[S])),m.push(this.closefilterFunction(S,h[S]));return{xValues:p,openValues:g,highValues:v,lowValues:y,closeValues:m,metadata:b}},a})(i.OhlcFilterBase);return Lx.OhlcCustomFilter=r,Lx}var s0e;function SBe(){if(s0e)return ab;s0e=1;var t=ab&&ab.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=ab&&ab.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(ab,"__esModule",{value:!0}),ab.OhlcScaleOffsetFilter=void 0;var i=Mm(),n=zi(),r=bBe(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;if(c=a.call(this,l,u)||this,c.scaleProperty=1,c.offsetProperty=0,l.type!==n.EDataSeriesType.Ohlc)throw new Error("OhlcScaleOffsetFilter only supports Ohlc original series");return c.scaleProperty=(d=u==null?void 0:u.scale)!==null&&d!==void 0?d:c.scaleProperty,c.offsetProperty=(f=u==null?void 0:u.offset)!==null&&f!==void 0?f:c.offsetProperty,c.getOriginalCount()>0&&c.filterAll(),c}return Object.defineProperty(s.prototype,"scale",{get:function(){return this.scaleProperty},set:function(l){this.scaleProperty=l,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"offset",{get:function(){return this.offsetProperty},set:function(l){this.offsetProperty=l,this.filterAll()},enumerable:!1,configurable:!0}),s.prototype.toJSON=function(l){l===void 0&&(l=!1);var u=this.originalSeries.toJSON(l);return e(e({},u),{filter:{type:i.EDataFilterType.OhlcScaleOffset,options:{scale:this.scale,offset:this.offset}}})},s.prototype.defaultFunction=function(l,u){return u*this.scaleProperty+this.offsetProperty},s})(r.OhlcCustomFilter);return ab.OhlcScaleOffsetFilter=o,ab}var sb={},l0e;function _Be(){if(l0e)return sb;l0e=1;var t=sb&&sb.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=sb&&sb.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(sb,"__esModule",{value:!0}),sb.XyLinearTrendFilter=void 0;var i=Mm(),n=sm(),r=bo(),o=(function(a){t(s,a);function s(l,u){var c=a.call(this,l,u)||this;return c.getOriginalCount()>0&&c.filterAll(),c}return Object.defineProperty(s.prototype,"slope",{get:function(){return this.slopeProperty},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"intercept",{get:function(){return this.interceptProperty},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"correlation",{get:function(){return this.correlationProperty},enumerable:!1,configurable:!0}),s.prototype.toJSON=function(l){l===void 0&&(l=!1);var u=a.prototype.toJSON.call(this,l);return e(e({},u),{filter:{type:i.EDataFilterType.XyLinearTrend,options:{field:this.field,slope:this.slope,intercept:this.intercept}}})},s.prototype.filterAll=function(){for(var l=0,u=0,c=0,d=0,f=0,h=this.getOriginalCount(),p=(0,r.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),g=(0,r.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),v=0;v<this.getOriginalCount();v++){var y=g[v],m=p[v];l+=m*y,u+=m,c+=y,d+=Math.pow(m,2),f+=Math.pow(y,2)}var b=l*h,S=u*c,_=d*h,C=Math.pow(u,2);this.correlationProperty=(b-S)/Math.sqrt((_-C)*(f*h-Math.pow(c,2))),this.slopeProperty=(b-S)/(_-C);var P=this.slopeProperty*u;this.interceptProperty=(c-P)/h;for(var x=[],E=[],v=0;v<h;v++){var A=p[v];E.push(A),x.push(A*this.slopeProperty+this.interceptProperty)}this.clear(),this.appendRange(E,x)},s})(n.XyFilterBase);return sb.XyLinearTrendFilter=o,sb}var lb={},u0e;function PBe(){if(u0e)return lb;u0e=1;var t=lb&&lb.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=lb&&lb.__assign||function(){return e=Object.assign||function(a){for(var s,l=1,u=arguments.length;l<u;l++){s=arguments[l];for(var c in s)Object.prototype.hasOwnProperty.call(s,c)&&(a[c]=s[c])}return a},e.apply(this,arguments)};Object.defineProperty(lb,"__esModule",{value:!0}),lb.XyMovingAverageFilter=void 0;var i=Mm(),n=sm(),r=bo(),o=(function(a){t(s,a);function s(l,u){var c=this,d;if(c=a.call(this,l,u)||this,c.lengthProperty=30,c.lengthProperty=(d=u==null?void 0:u.length)!==null&&d!==void 0?d:c.lengthProperty,!l.dataDistributionCalculator.isSortedAscending)throw new Error("XyMovingAverageFilter requires original data to be sorted in X");return c.getOriginalCount()>0&&c.calculate(0),c}return Object.defineProperty(s.prototype,"length",{get:function(){return this.lengthProperty},set:function(l){this.lengthProperty=l,this.calculate(0)},enumerable:!1,configurable:!0}),s.prototype.toJSON=function(l){l===void 0&&(l=!1);var u=this.originalSeries.toJSON(l);return e(e({},u),{filter:{type:i.EDataFilterType.XyMovingAverage,options:{field:this.field,length:this.length}}})},s.prototype.onOriginalPropertyChanged=function(l){},s.prototype.filterOnAppend=function(l){this.calculate(this.count())},s.prototype.filterOnUpdate=function(l){var u=this.getOriginalYValues().get(l)||0;this.calculateUpdate(l,u)},s.prototype.filterOnInsert=function(l,u){this.calculate(l)},s.prototype.filterOnRemove=function(l,u){this.calculate(l)},s.prototype.filterAll=function(){this.calculate(0)},s.prototype.calculateUpdate=function(l,u){if(l<this.count()-1)this.calculate(l);else if(l>=this.length-1){for(var c=0,d=(0,r.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),f=l-(this.length-1);f<=l;f++)c+=d[f];this.update(l,c/this.length)}},s.prototype.calculate=function(l){var u=(0,r.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),c=(0,r.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),d=0;l<this.count()&&(l===0?this.clear():this.removeRange(l,this.count()-l));for(var f=Math.max(0,l-this.length),h=f;h<l;h++)d+=c[h]||0;var p=this.getOriginalCount(),g=[],v=[];if(this.originalSeries.dataDistributionCalculator.containsNaN)for(var h=l;h<p;h++){var y=u[h],m=c[h]||0;if(g.push(y),h>this.length-1){var b=h-this.length,S=c[b]||0;d=d+m-S,v.push(d/this.length)}else h===this.length-1?(d=d+m,v.push(d/this.length)):(d=d+m,v.push(NaN))}else for(var h=l;h<p;h++){var y=u[h],m=c[h];if(g.push(y),h>this.length-1){var b=h-this.length,S=c[b];d=d+m-S,v.push(d/this.length)}else h===this.length-1?(d=d+m,v.push(d/this.length)):(d=d+m,v.push(NaN))}this.appendRange(g,v)},s})(n.XyFilterBase);return lb.XyMovingAverageFilter=o,lb}var ub={},c0e;function CBe(){if(c0e)return ub;c0e=1;var t=ub&&ub.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=ub&&ub.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(ub,"__esModule",{value:!0}),ub.XyRatioFilter=void 0;var i=ci(),n=Mm(),r=zi(),o=sm(),a=bo(),s=(function(l){t(u,l);function u(c,d){var f=this,h;return f=l.call(this,c,d)||this,f.divisorField=o.EDataSeriesField.Y,i.Guard.notNull(d.divisorSeries,"divisorSeries"),f.divisorSeries=d.divisorSeries,f.divisorField=(h=d.divisorField)!==null&&h!==void 0?h:f.divisorField,f.onDivisorDataChanged=f.onDivisorDataChanged.bind(f),f.divisorSeries.dataChanged.subscribe(f.onDivisorDataChanged),f.getOriginalCount()>0&&f.filterAll(),f}return u.prototype.toJSON=function(c){c===void 0&&(c=!1);for(var d=this.originalSeries.toJSON(c),f=[],h=this.getDivisorYValues(),p=(0,a.vectorToArrayViewF64)(h,this.webAssemblyContext),g=0;g<this.divisorSeries.count();g++)f.push(p[g]);return e(e({},d),{filter:{type:n.EDataFilterType.XyRatio,options:{field:this.field,divisorSeries:f}}})},u.prototype.filterOnAppend=function(c){if(this.getOriginalCount()===this.divisorSeries.count()){var d=this.filter(this.count(),c),f=d.xValues,h=d.yValues;this.appendRange(f,h)}},u.prototype.filterOnUpdate=function(c){this.update(c,this.getOriginalYValues().get(c)/this.getDivisorYValues().get(c))},u.prototype.filterOnInsert=function(c,d){if(this.getOriginalCount()===this.divisorSeries.count()){var f=this.filter(c,d),h=f.xValues,p=f.yValues;this.insertRange(c,h,p)}},u.prototype.filterOnRemove=function(c,d){this.getOriginalCount()===this.divisorSeries.count()&&this.removeRange(c,d)},u.prototype.filterAll=function(){if(this.getOriginalCount()===this.divisorSeries.count()){this.clear();var c=this.filter(0,this.getOriginalCount()),d=c.xValues,f=c.yValues;this.appendRange(d,f)}},u.prototype.filter=function(c,d){for(var f=[],h=[],p=(0,a.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),g=(0,a.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),v=(0,a.vectorToArrayViewF64)(this.getDivisorYValues(),this.webAssemblyContext),y=c;y<c+d;y++)f.push(p[y]),h.push(g[y]/v[y]);return{xValues:f,yValues:h}},u.prototype.getDivisorYValues=function(){var c=this.divisorSeries.getNativeYValues();if(this.divisorSeries.type===r.EDataSeriesType.Xyy){var d=this.divisorSeries;c=(0,o.switchData)(this.divisorField,d.getNativeYValues(),d.getNativeY1Values())}else if(this.divisorSeries.type===r.EDataSeriesType.Xyz){var f=this.divisorSeries;c=(0,o.switchData)(this.field,f.getNativeYValues(),f.getNativeZValues())}else if(this.divisorSeries.type===r.EDataSeriesType.Ohlc){var h=this.divisorSeries;c=(0,o.switchData)(this.field,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())}return c},u.prototype.onDivisorDataChanged=function(c){var d=c.changeType;c.name;var f=c.index,h=c.count;switch(d){case r.EDataChangeType.Append:this.filterOnAppend(h);break;case r.EDataChangeType.Clear:this.onClear();break;case r.EDataChangeType.Insert:this.filterOnInsert(f,h);break;case r.EDataChangeType.Remove:this.filterOnRemove(f,h);break;case r.EDataChangeType.Update:this.filterOnUpdate(f);break}},u})(o.XyFilterBase);return ub.XyRatioFilter=s,ub}var cb={},Ix={},d0e;function TBe(){if(d0e)return Ix;d0e=1;var t=Ix&&Ix.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Ix,"__esModule",{value:!0}),Ix.XyCustomFilter=void 0;var e=sm(),i=bo(),n=(function(r){t(o,r);function o(a,s){var l=this,u;return l=r.call(this,a,s)||this,l.filterFunctionProperty=(u=s==null?void 0:s.filterFunction)!==null&&u!==void 0?u:l.filterFunctionProperty,l.getOriginalCount()>0&&(s!=null&&s.filterFunction)&&l.filterAll(),l}return Object.defineProperty(o.prototype,"filterFunction",{get:function(){return this.filterFunctionProperty},set:function(a){this.filterFunctionProperty=a,this.filterAll()},enumerable:!1,configurable:!0}),o.prototype.filterFunctionProperty=function(a,s){return s},o.prototype.filterOnAppend=function(a){var s=this.filter(this.count(),a),l=s.xValues,u=s.yValues,c=s.metadata;this.appendRange(l,u,c)},o.prototype.filterOnUpdate=function(a){this.update(a,this.filterFunction(a,this.getOriginalYValues().get(a)),this.originalSeries.getMetadataAt(a))},o.prototype.filterOnInsert=function(a,s){var l=this.filter(a,s),u=l.xValues,c=l.yValues,d=l.metadata;this.insertRange(a,u,c,d)},o.prototype.filterOnRemove=function(a,s){this.removeRange(a,s)},o.prototype.filterAll=function(){this.clear();var a=this.filter(0,this.getOriginalCount()),s=a.xValues,l=a.yValues,u=a.metadata;this.appendRange(s,l,u)},o.prototype.filter=function(a,s){var l=[],u=[],c=(0,i.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),d=(0,i.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),f=void 0;if(this.originalSeries.hasMetadata){f=[];for(var h=a;h<a+s;h++)l.push(c[h]),u.push(this.filterFunction(h,d[h])),f.push(this.originalSeries.getMetadataAt(h))}else for(var h=a;h<a+s;h++)l.push(c[h]),u.push(this.filterFunction(h,d[h]));return{xValues:l,yValues:u,metadata:f}},o})(e.XyFilterBase);return Ix.XyCustomFilter=n,Ix}var f0e;function xBe(){if(f0e)return cb;f0e=1;var t=cb&&cb.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})(),e=cb&&cb.__assign||function(){return e=Object.assign||function(o){for(var a,s=1,l=arguments.length;s<l;s++){a=arguments[s];for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&(o[u]=a[u])}return o},e.apply(this,arguments)};Object.defineProperty(cb,"__esModule",{value:!0}),cb.XyScaleOffsetFilter=void 0;var i=Mm(),n=TBe(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.scaleProperty=1,u.offsetProperty=0,u.scaleProperty=(c=l==null?void 0:l.scale)!==null&&c!==void 0?c:u.scaleProperty,u.offsetProperty=(d=l==null?void 0:l.offset)!==null&&d!==void 0?d:u.offsetProperty,u.getOriginalCount()>0&&u.filterAll(),u}return Object.defineProperty(a.prototype,"scale",{get:function(){return this.scaleProperty},set:function(s){this.scaleProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"offset",{get:function(){return this.offsetProperty},set:function(s){this.offsetProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),a.prototype.toJSON=function(s){s===void 0&&(s=!1);var l=this.originalSeries.toJSON(s);return e(e({},l),{filter:{type:i.EDataFilterType.XyScaleOffset,options:{field:this.field,scale:this.scale,offset:this.offset}}})},a.prototype.filterFunctionProperty=function(s,l){return l*this.scaleProperty+this.offsetProperty},a})(n.XyCustomFilter);return cb.XyScaleOffsetFilter=r,cb}var db={},Nx={},Fx={},av={},h0e;function W3(){if(h0e)return av;h0e=1;var t=av&&av.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})(),e=av&&av.__assign||function(){return e=Object.assign||function(p){for(var g,v=1,y=arguments.length;v<y;v++){g=arguments[v];for(var m in g)Object.prototype.hasOwnProperty.call(g,m)&&(p[m]=g[m])}return p},e.apply(this,arguments)};Object.defineProperty(av,"__esModule",{value:!0}),av.getYyYRange=av.XyyDataSeries=void 0;var i=Br(),n=ci(),r=di(),o=ym(),a=Yo(),s=eC(),l=kp(),u=bo(),c=Bu(),d=zi(),f=(function(p){t(g,p);function g(v,y){var m=this,b=e(e({},y),{arrayCount:2,valueNames:[a.EValueName.Y,a.EValueName.Y1],includeInYRange:[!0,!0]});return m=p.call(this,v,b)||this,m.type=d.EDataSeriesType.Xyy,b!=null&&b.xValues&&(n.Guard.notNull(b.yValues,"baseOptions.yValues"),n.Guard.notNull(b.y1Values,"baseOptions.y1Values"),m.appendRange(b.xValues,b.yValues,b.y1Values,b.metadata),b!=null&&b.fifoCapacity&&(b!=null&&b.fifoStartIndex)&&(m.xValues.notifyAppend(b==null?void 0:b.fifoStartIndex),m.yValues.notifyAppend(b==null?void 0:b.fifoStartIndex),m.y1Values.notifyAppend(b==null?void 0:b.fifoStartIndex))),m}return Object.defineProperty(g.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"y1Values",{get:function(){return this.getNativeY1Values()},enumerable:!1,configurable:!0}),g.prototype.getNativeY1Values=function(){return this.getNativeYValues(1)},g.prototype.append=function(v,y,m,b){p.prototype.appendN.call(this,v,[y,m],b)},g.prototype.appendRange=function(v,y,m,b){p.prototype.appendRangeN.call(this,v,[y,m],b)},g.prototype.update=function(v,y,m,b){p.prototype.updateN.call(this,v,[y,m],b)},g.prototype.updateXyy1=function(v,y,m,b,S){p.prototype.updateXyN.call(this,v,y,[m,b],S)},g.prototype.insert=function(v,y,m,b,S){p.prototype.insertN.call(this,v,y,[m,b],S)},g.prototype.insertRange=function(v,y,m,b,S){p.prototype.insertRangeN.call(this,v,y,[m,b],S)},g.prototype.getWindowedYRange=function(v,y,m,b,S){m===void 0&&(m=!1),b===void 0&&(b=d.EDataSeriesValueType.Default),S===void 0&&(S=s.EYRangeMode.Visible);var _=this.getYY1Values(b),C=_.yValues,P=_.y1Values;if(this.count()===1){var x=Math.min(C.get(0),P.get(0)),E=Math.max(C.get(0),P.get(0));return new r.NumberRange(x,E)}var A=m?v:this.getIndicesRange(v,!1,S===s.EYRangeMode.Visible?o.ESearchMode.RoundUp:o.ESearchMode.RoundDown,S===s.EYRangeMode.Visible?o.ESearchMode.RoundDown:o.ESearchMode.RoundUp);return h(this.webAssemblyContext,A,C,P,this.dataDistributionCalculator.containsNaN)},g.prototype.getOptions=function(v){v===void 0&&(v=!1);var y=p.prototype.getOptions.call(this,v);if(!v){var m=(0,u.vectorToArray)(this.xValues,this.webAssemblyContext),b=(0,u.vectorToArray)(this.yValues,this.webAssemblyContext),S=(0,u.vectorToArray)(this.y1Values,this.webAssemblyContext),_={xValues:m,yValues:b,y1Values:S};Object.assign(y,_)}return y},g.prototype.getYY1Values=function(v){var y,m;switch(v){case d.EDataSeriesValueType.FinalAnimationValues:y=this.yFinalAnimationValuesArray[0],m=this.yFinalAnimationValuesArray[1];break;case d.EDataSeriesValueType.InitialAnimationValues:y=this.yInitialAnimationValuesArray[0],m=this.yInitialAnimationValuesArray[1];break;default:y=this.yValues,m=this.y1Values}return{yValues:y,y1Values:m}},g})(c.BaseDataSeries);av.XyyDataSeries=f;function h(p,g,v,y,m){var b=Math.max(Math.floor(g.min),0),S=Math.min(Math.ceil(g.max),v.size()-1);if(!(S<b)){var _,C;try{return _=p.NumberUtil.MinMaxWithIndex(v,b,S-b+1,m),!(0,l.isRealNumber)(_.minD)||!(0,l.isRealNumber)(_.maxD)||(C=p.NumberUtil.MinMaxWithIndex(y,b,S-b+1,m),!(0,l.isRealNumber)(C.minD)||!(0,l.isRealNumber)(C.maxD))?void 0:new r.NumberRange(Math.min(_.minD,C.minD),Math.max(_.maxD,C.maxD))}finally{(0,i.deleteSafe)(_),(0,i.deleteSafe)(C)}}}return av.getYyYRange=h,av}var p0e;function EBe(){if(p0e)return Fx;p0e=1;var t=Fx&&Fx.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Fx,"__esModule",{value:!0}),Fx.XyyFilterBase=void 0;var e=Br(),i=zi(),n=W3(),r=sm(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;switch(c=a.call(this,l.webAssemblyContext,u)||this,c.yfield=r.EDataSeriesField.Y,c.y1field=r.EDataSeriesField.Y1,c.originalSeriesProperty=l,c.yfield=(d=u==null?void 0:u.yfield)!==null&&d!==void 0?d:c.yfield,c.yfield=(f=u==null?void 0:u.yfield)!==null&&f!==void 0?f:c.yfield,c.onBaseDataChanged=c.onBaseDataChanged.bind(c),l.dataChanged.subscribe(c.onBaseDataChanged),c.originalSeries.type){case i.EDataSeriesType.Ohlc:var h=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())},c.getOriginalY1Values=function(){return(0,r.switchData)(c.y1field,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())};break;case i.EDataSeriesType.Xy:var p=c.originalSeries;c.getOriginalYValues=function(){return p.getNativeYValues()},c.getOriginalY1Values=function(){return p.getNativeYValues()};break;case i.EDataSeriesType.Xyz:var g=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,g.getNativeYValues(),g.getNativeZValues())},c.getOriginalY1Values=function(){return(0,r.switchData)(c.y1field,g.getNativeYValues(),g.getNativeZValues())};break;case i.EDataSeriesType.Hlc:var v=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,v.getNativeYValues(),void 0,v.getNativeHighValues(),v.getNativeLowValues())},c.getOriginalY1Values=function(){return(0,r.switchData)(c.y1field,v.getNativeYValues(),void 0,v.getNativeHighValues(),v.getNativeLowValues())};break}return c}return Object.defineProperty(s.prototype,"originalSeries",{get:function(){return this.originalSeriesProperty},enumerable:!1,configurable:!0}),s.prototype.detachFromOriginalSeries=function(){this.originalSeries.dataChanged.unsubscribe(this.onBaseDataChanged),this.originalSeriesProperty=void 0},s.prototype.delete=function(){this.originalSeriesProperty=(0,e.deleteSafe)(this.originalSeries),a.prototype.delete.call(this)},s.prototype.getOriginalXValues=function(){return this.originalSeries.getNativeXValues()},s.prototype.getOriginalYValues=function(){return this.originalSeries.getNativeYValues()},s.prototype.getOriginalY1Values=function(){return this.originalSeries.getNativeY1Values()},s.prototype.getOriginalCount=function(){return this.originalSeries.count()},s.prototype.onOriginalPropertyChanged=function(l){},s.prototype.filterOnAppend=function(l){this.filterAll()},s.prototype.filterOnUpdate=function(l){this.filterAll()},s.prototype.filterOnInsert=function(l,u){this.filterAll()},s.prototype.filterOnRemove=function(l,u){this.filterAll()},s.prototype.onClear=function(){this.clear()},s.prototype.onBaseDataChanged=function(l){var u=l.changeType,c=l.name,d=l.index,f=l.count;switch(u){case i.EDataChangeType.Property:this.onOriginalPropertyChanged(c);return;case i.EDataChangeType.Append:this.filterOnAppend(f);break;case i.EDataChangeType.Clear:this.onClear();break;case i.EDataChangeType.Insert:this.filterOnInsert(d,f);break;case i.EDataChangeType.Remove:this.filterOnRemove(d,f);break;case i.EDataChangeType.Update:this.filterOnUpdate(d);break}},s})(n.XyyDataSeries);return Fx.XyyFilterBase=o,Fx}var g0e;function wBe(){if(g0e)return Nx;g0e=1;var t=Nx&&Nx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Nx,"__esModule",{value:!0}),Nx.XyyCustomFilter=void 0;var e=EBe(),i=bo(),n=(function(r){t(o,r);function o(a,s){var l=this,u,c;return l=r.call(this,a,s)||this,l.filterFunctionProperty=(u=s==null?void 0:s.filterFunction)!==null&&u!==void 0?u:l.filterFunctionProperty,l.y1filterFunctionProperty=(c=s==null?void 0:s.y1filterFunction)!==null&&c!==void 0?c:l.filterFunctionProperty,l.getOriginalCount()>0&&(s!=null&&s.filterFunction||s!=null&&s.y1filterFunction)&&l.filterAll(),l}return Object.defineProperty(o.prototype,"filterFunction",{get:function(){return this.filterFunctionProperty},set:function(a){this.filterFunctionProperty=a,this.filterAll()},enumerable:!1,configurable:!0}),o.prototype.filterFunctionProperty=function(a,s){return s},Object.defineProperty(o.prototype,"y1filterFunction",{get:function(){return this.y1filterFunctionProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"y1yfilterFunction",{set:function(a){this.y1filterFunctionProperty=a,this.filterAll()},enumerable:!1,configurable:!0}),o.prototype.y1filterFunctionProperty=function(a,s){return s},o.prototype.filterOnAppend=function(a){var s=this.filter(this.count(),a),l=s.xValues,u=s.yValues,c=s.y1Values,d=s.metadata;this.appendRange(l,u,c,d)},o.prototype.filterOnUpdate=function(a){this.update(a,this.filterFunction(a,this.getOriginalYValues().get(a)),this.y1filterFunction(a,this.getOriginalY1Values().get(a)),this.originalSeries.getMetadataAt(a))},o.prototype.filterOnInsert=function(a,s){var l=this.filter(a,s),u=l.xValues,c=l.yValues,d=l.y1Values,f=l.metadata;this.insertRange(a,u,c,d,f)},o.prototype.filterOnRemove=function(a,s){this.removeRange(a,s)},o.prototype.filterAll=function(){this.clear();var a=this.filter(0,this.getOriginalCount()),s=a.xValues,l=a.yValues,u=a.y1Values,c=a.metadata;this.appendRange(s,l,u,c)},o.prototype.filter=function(a,s){var l=[],u=[],c=[],d=(0,i.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),f=(0,i.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),h=(0,i.vectorToArrayViewF64)(this.getOriginalY1Values(),this.webAssemblyContext),p=void 0;if(this.originalSeries.hasMetadata){p=[];for(var g=a;g<a+s;g++)l.push(d[g]),u.push(this.filterFunction(g,f[g])),c.push(this.y1filterFunction(g,h[g])),p.push(this.originalSeries.getMetadataAt(g))}else for(var g=a;g<a+s;g++)l.push(d[g]),u.push(this.filterFunction(g,f[g])),c.push(this.y1filterFunction(g,h[g]));return{xValues:l,yValues:u,y1Values:c,metadata:p}},o})(e.XyyFilterBase);return Nx.XyyCustomFilter=n,Nx}var v0e;function ABe(){if(v0e)return db;v0e=1;var t=db&&db.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})(),e=db&&db.__assign||function(){return e=Object.assign||function(o){for(var a,s=1,l=arguments.length;s<l;s++){a=arguments[s];for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&(o[u]=a[u])}return o},e.apply(this,arguments)};Object.defineProperty(db,"__esModule",{value:!0}),db.XyyScaleOffsetFilter=void 0;var i=Mm(),n=wBe(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.scaleProperty=1,u.offsetProperty=0,u.scaleProperty=(c=l==null?void 0:l.scale)!==null&&c!==void 0?c:u.scaleProperty,u.offsetProperty=(d=l==null?void 0:l.offset)!==null&&d!==void 0?d:u.offsetProperty,u.getOriginalCount()>0&&u.filterAll(),u}return Object.defineProperty(a.prototype,"scale",{get:function(){return this.scaleProperty},set:function(s){this.scaleProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"offset",{get:function(){return this.offsetProperty},set:function(s){this.offsetProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),a.prototype.toJSON=function(s){s===void 0&&(s=!1);var l=this.originalSeries.toJSON(s);return e(e({},l),{filter:{type:i.EDataFilterType.XyyScaleOffset,options:{yfield:this.yfield,y1field:this.y1field,scale:this.scale,offset:this.offset}}})},a.prototype.filterFunctionProperty=function(s,l){return l*this.scaleProperty+this.offsetProperty},a})(n.XyyCustomFilter);return db.XyyScaleOffsetFilter=r,db}var fb={},Bx={},jx={},hb={},y0e;function yie(){if(y0e)return hb;y0e=1;var t=hb&&hb.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=hb&&hb.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(hb,"__esModule",{value:!0}),hb.XyzDataSeries=void 0;var i=ci(),n=Yo(),r=bo(),o=Bu(),a=zi(),s=(function(l){t(u,l);function u(c,d){var f=this,h=e(e({},d),{arrayCount:2,valueNames:[n.EValueName.Y,n.EValueName.Z],includeInYRange:[!0,!1]});return f=l.call(this,c,h)||this,f.type=a.EDataSeriesType.Xyz,h!=null&&h.xValues&&(i.Guard.notNull(h.yValues,"baseOptions.yValues"),i.Guard.notNull(h.zValues,"baseOptions.zValues"),f.appendRange(h.xValues,h.yValues,h.zValues,h.metadata),h!=null&&h.fifoCapacity&&(h!=null&&h.fifoStartIndex)&&(f.xValues.notifyAppend(h==null?void 0:h.fifoStartIndex),f.yValues.notifyAppend(h==null?void 0:h.fifoStartIndex),f.zValues.notifyAppend(h==null?void 0:h.fifoStartIndex))),f}return Object.defineProperty(u.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"zValues",{get:function(){return this.getNativeZValues()},enumerable:!1,configurable:!0}),u.prototype.getNativeZValues=function(){return this.getNativeYValues(1)},u.prototype.append=function(c,d,f,h){l.prototype.appendN.call(this,c,[d,f],h)},u.prototype.appendRange=function(c,d,f,h){l.prototype.appendRangeN.call(this,c,[d,f],h)},u.prototype.update=function(c,d,f,h){l.prototype.updateN.call(this,c,[d,f],h)},u.prototype.updateXyz=function(c,d,f,h,p){l.prototype.updateXyN.call(this,c,d,[f,h],p)},u.prototype.insert=function(c,d,f,h,p){l.prototype.insertN.call(this,c,d,[f,h],p)},u.prototype.insertRange=function(c,d,f,h,p){l.prototype.insertRangeN.call(this,c,d,[f,h],p)},u.prototype.getOptions=function(c){c===void 0&&(c=!1);var d=l.prototype.getOptions.call(this,c);if(!c){var f=(0,r.vectorToArray)(this.xValues,this.webAssemblyContext),h=(0,r.vectorToArray)(this.yValues,this.webAssemblyContext),p=(0,r.vectorToArray)(this.zValues,this.webAssemblyContext),g={xValues:f,yValues:h,zValues:p};Object.assign(d,g)}return d},u})(o.BaseDataSeries);return hb.XyzDataSeries=s,hb}var m0e;function OBe(){if(m0e)return jx;m0e=1;var t=jx&&jx.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(jx,"__esModule",{value:!0}),jx.XyzFilterBase=void 0;var e=Br(),i=zi(),n=yie(),r=sm(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f;switch(c=a.call(this,l.webAssemblyContext,u)||this,c.yfield=r.EDataSeriesField.Y,c.zfield=r.EDataSeriesField.Z,c.originalSeriesProperty=l,c.yfield=(d=u==null?void 0:u.yfield)!==null&&d!==void 0?d:c.yfield,c.zfield=(f=u==null?void 0:u.zfield)!==null&&f!==void 0?f:c.zfield,c.onBaseDataChanged=c.onBaseDataChanged.bind(c),l.dataChanged.subscribe(c.onBaseDataChanged),c.originalSeries.type){case i.EDataSeriesType.Ohlc:var h=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())},c.getOriginalZValues=function(){return(0,r.switchData)(c.zfield,h.getNativeYValues(),h.getNativeOpenValues(),h.getNativeHighValues(),h.getNativeLowValues())};break;case i.EDataSeriesType.Xy:var p=c.originalSeries;c.getOriginalYValues=function(){return p.getNativeYValues()},c.getOriginalZValues=function(){return p.getNativeYValues()};break;case i.EDataSeriesType.Xyy:var g=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,g.getNativeYValues(),g.getNativeY1Values())},c.getOriginalZValues=function(){return(0,r.switchData)(c.zfield,g.getNativeYValues(),g.getNativeY1Values())};break;case i.EDataSeriesType.Hlc:var v=c.originalSeries;c.getOriginalYValues=function(){return(0,r.switchData)(c.yfield,v.getNativeYValues(),void 0,v.getNativeHighValues(),v.getNativeLowValues())},c.getOriginalZValues=function(){return(0,r.switchData)(c.zfield,v.getNativeYValues(),void 0,v.getNativeHighValues(),v.getNativeLowValues())};break}return c}return Object.defineProperty(s.prototype,"originalSeries",{get:function(){return this.originalSeriesProperty},enumerable:!1,configurable:!0}),s.prototype.detachFromOriginalSeries=function(){this.originalSeries.dataChanged.unsubscribe(this.onBaseDataChanged),this.originalSeriesProperty=void 0},s.prototype.delete=function(){this.originalSeriesProperty=(0,e.deleteSafe)(this.originalSeries),a.prototype.delete.call(this)},s.prototype.getOriginalXValues=function(){return this.originalSeries.getNativeXValues()},s.prototype.getOriginalYValues=function(){return this.originalSeries.getNativeYValues()},s.prototype.getOriginalZValues=function(){return this.originalSeries.getNativeZValues()},s.prototype.getOriginalCount=function(){return this.originalSeries.count()},s.prototype.onOriginalPropertyChanged=function(l){},s.prototype.filterOnAppend=function(l){this.filterAll()},s.prototype.filterOnUpdate=function(l){this.filterAll()},s.prototype.filterOnInsert=function(l,u){this.filterAll()},s.prototype.filterOnRemove=function(l,u){this.filterAll()},s.prototype.onClear=function(){this.clear()},s.prototype.onBaseDataChanged=function(l){var u=l.changeType,c=l.name,d=l.index,f=l.count;switch(u){case i.EDataChangeType.Property:this.onOriginalPropertyChanged(c);return;case i.EDataChangeType.Append:this.filterOnAppend(f);break;case i.EDataChangeType.Clear:this.onClear();break;case i.EDataChangeType.Insert:this.filterOnInsert(d,f);break;case i.EDataChangeType.Remove:this.filterOnRemove(d,f);break;case i.EDataChangeType.Update:this.filterOnUpdate(d);break}},s})(n.XyzDataSeries);return jx.XyzFilterBase=o,jx}var b0e;function DBe(){if(b0e)return Bx;b0e=1;var t=Bx&&Bx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Bx,"__esModule",{value:!0}),Bx.XyzCustomFilter=void 0;var e=OBe(),i=bo(),n=(function(r){t(o,r);function o(a,s){var l=this,u,c;return l=r.call(this,a,s)||this,l.filterFunctionProperty=(u=s==null?void 0:s.filterFunction)!==null&&u!==void 0?u:l.filterFunctionProperty,l.zfilterFunctionProperty=(c=s==null?void 0:s.zfilterFunction)!==null&&c!==void 0?c:l.filterFunctionProperty,l.getOriginalCount()>0&&(s!=null&&s.filterFunction||s!=null&&s.zfilterFunction)&&l.filterAll(),l}return Object.defineProperty(o.prototype,"filterFunction",{get:function(){return this.filterFunctionProperty},set:function(a){this.filterFunctionProperty=a,this.filterAll()},enumerable:!1,configurable:!0}),o.prototype.filterFunctionProperty=function(a,s){return s},Object.defineProperty(o.prototype,"zfilterFunction",{get:function(){return this.zfilterFunctionProperty},set:function(a){this.zfilterFunctionProperty=a,this.filterAll()},enumerable:!1,configurable:!0}),o.prototype.zfilterFunctionProperty=function(a,s){return s},o.prototype.filterOnAppend=function(a){var s=this.filter(this.count(),a),l=s.xValues,u=s.yValues,c=s.zValues,d=s.metadata;this.appendRange(l,u,c,d)},o.prototype.filterOnUpdate=function(a){this.update(a,this.filterFunction(a,this.getOriginalYValues().get(a)),this.zfilterFunction(a,this.getOriginalZValues().get(a)),this.originalSeries.getMetadataAt(a))},o.prototype.filterOnInsert=function(a,s){var l=this.filter(a,s),u=l.xValues,c=l.yValues,d=l.zValues,f=l.metadata;this.insertRange(a,u,c,d,f)},o.prototype.filterOnRemove=function(a,s){this.removeRange(a,s)},o.prototype.filterAll=function(){this.clear();var a=this.filter(0,this.getOriginalCount()),s=a.xValues,l=a.yValues,u=a.zValues,c=a.metadata;this.appendRange(s,l,u,c)},o.prototype.filter=function(a,s){var l=(0,i.vectorToArrayViewF64)(this.getOriginalXValues(),this.webAssemblyContext),u=(0,i.vectorToArrayViewF64)(this.getOriginalYValues(),this.webAssemblyContext),c=(0,i.vectorToArrayViewF64)(this.getOriginalZValues(),this.webAssemblyContext),d=[],f=[],h=[],p=void 0;if(this.originalSeries.hasMetadata){p=[];for(var g=a;g<a+s;g++)d.push(l[g]),f.push(this.filterFunction(g,u[g])),h.push(this.zfilterFunction(g,c[g])),p.push(this.originalSeries.getMetadataAt(g))}else for(var g=a;g<a+s;g++)d.push(l[g]),f.push(this.filterFunction(g,u[g])),h.push(this.zfilterFunction(g,c[g]));return{xValues:d,yValues:f,zValues:h,metadata:p}},o})(e.XyzFilterBase);return Bx.XyzCustomFilter=n,Bx}var S0e;function RBe(){if(S0e)return fb;S0e=1;var t=fb&&fb.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})(),e=fb&&fb.__assign||function(){return e=Object.assign||function(o){for(var a,s=1,l=arguments.length;s<l;s++){a=arguments[s];for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&(o[u]=a[u])}return o},e.apply(this,arguments)};Object.defineProperty(fb,"__esModule",{value:!0}),fb.XyzScaleOffsetFilter=void 0;var i=Mm(),n=DBe(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.scaleProperty=1,u.offsetProperty=0,u.scaleProperty=(c=l==null?void 0:l.scale)!==null&&c!==void 0?c:u.scaleProperty,u.offsetProperty=(d=l==null?void 0:l.offset)!==null&&d!==void 0?d:u.offsetProperty,u.getOriginalCount()>0&&u.filterAll(),u}return Object.defineProperty(a.prototype,"scale",{get:function(){return this.scaleProperty},set:function(s){this.scaleProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"offset",{get:function(){return this.offsetProperty},set:function(s){this.offsetProperty=s,this.filterAll()},enumerable:!1,configurable:!0}),a.prototype.toJSON=function(s){s===void 0&&(s=!1);var l=this.originalSeries.toJSON(s);return e(e({},l),{filter:{type:i.EDataFilterType.XyzScaleOffset,options:{yfield:this.yfield,zfield:this.zfield,scale:this.scale,offset:this.offset}}})},a.prototype.filterFunctionProperty=function(s,l){return l*this.scaleProperty+this.offsetProperty},a})(n.XyzCustomFilter);return fb.XyzScaleOffsetFilter=r,fb}var Vx={},H9={},_0e;function eAt(){return _0e||(_0e=1,Object.defineProperty(H9,"__esModule",{value:!0})),H9}var VF={},P0e;function mie(){if(P0e)return VF;P0e=1,Object.defineProperty(VF,"__esModule",{value:!0}),VF.BaseHeatmapDataSeries=void 0;var t=mo(),e=Br(),i=ps(),n=ci(),r=di(),o=ga(),a=Rf(),s=hl(),l=kp(),u=zi(),c=XV(),d=(function(){function h(p,g){var v,y,m,b;this.dataChanged=new i.EventHandler,this.minXSpacing=0,this.arrayWidth=0,this.arrayHeight=0,this.hasDataChangesProperty=!1,this.hasNaNsProperty=!1,this.lastZMin=-1,this.lastZMax=-1,this.lastFillValuesOutOfRange=void 0,this.metadataGeneratorProperty=void 0,this.changeCountProperty=0,this.cachedZRange=void 0,this.lastChangeCountForZRange=-1,this.webAssemblyContext=p,this.id=(v=g==null?void 0:g.id)!==null&&v!==void 0?v:(0,s.generateGuid)(),this.dataSeriesNameProperty=(y=g==null?void 0:g.dataSeriesName)!==null&&y!==void 0?y:this.dataSeriesNameProperty,this.hasNaNsProperty=(m=g==null?void 0:g.containsNaN)!==null&&m!==void 0?m:this.hasNaNsProperty,this.normalizedVector=new this.webAssemblyContext.SCRTFloatVector,g!=null&&g.metadata&&("type"in g.metadata?(this.metadataGeneratorProperty=(0,t.createType)(o.EBaseType.MetadataGenerator,g.metadata.type,p,g.metadata.data),g.metadata=(b=this.metadataGeneratorProperty)===null||b===void 0?void 0:b.getMetadata()):Array.isArray(g==null?void 0:g.metadata)||(this.metadataGeneratorProperty=new c.TemplateMetadataGenerator(g==null?void 0:g.metadata),g.metadata=void 0)),this.setZValues(g==null?void 0:g.zValues,g==null?void 0:g.metadata)}return Object.defineProperty(h.prototype,"isSorted",{get:function(){return!0},set:function(p){throw new Error("setting isSorted on a heatmap series is not supported")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"isEvenlySpaced",{get:function(){return!0},set:function(p){throw new Error("setting isEvenlySpaced on a heatmap series is not supported")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"containsNaN",{get:function(){return!1},set:function(p){throw new Error("setting containsNaN is not supported on BaseHeatmapDataSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"dataDistributionCalculator",{get:function(){throw new Error("dataDistributionCalculator is not supported on BaseHeatmapDataSeries")},enumerable:!1,configurable:!0}),h.prototype.getNativeValue=function(p,g){throw new Error("getNativeValue not supported for HeatmapDataSeries")},Object.defineProperty(h.prototype,"hasDataChanges",{get:function(){return this.hasDataChangesProperty},enumerable:!1,configurable:!0}),h.prototype.getZValues=function(){return this.zValuesProperty},h.prototype.setZValues=function(p,g){if(!p||!p[0]){this.zValuesProperty=void 0,this.arrayHeight=0,this.arrayWidth=0,this.size=0;return}var v=p[0].length;p.forEach(function(b){if(!b)throw new Error("Each row in zValues must be defined. See how to declare a 2D array in Javascript here https://stackoverflow.com/a/966234/303612");if(b.length!==v)throw new Error("Each row in zValues must be the same length, so that the overall 2D array is square")}),g&&f(p,g);var y=p[0].length,m=p.length;this.arrayWidth=y,this.arrayHeight=m,this.size=y*m,this.zValuesProperty=p,this.setMetadata(g),this.notifyDataChanged(u.EDataChangeType.Append)},h.prototype.getZValue=function(p,g){return this.zValuesProperty[p][g]},h.prototype.setZValue=function(p,g,v,y){this.zValuesProperty[p][g]=v,this.setMetadataAt(p,g,y),this.notifyDataChanged(u.EDataChangeType.Update,g,p)},h.prototype.clear=function(){this.getIsDeleted()||(this.setZValues(void 0),this.setMetadata(void 0),this.notifyDataChanged(u.EDataChangeType.Clear,null,null))},Object.defineProperty(h.prototype,"xMin",{get:function(){return this.xRange.min},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"xMax",{get:function(){return this.xRange.max},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"yMin",{get:function(){return this.yRange.min},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"yMax",{get:function(){return this.yRange.max},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"zMin",{get:function(){return this.zRange.min},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"zMax",{get:function(){return this.zRange.max},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"xRange",{get:function(){return this.getXRange()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"yRange",{get:function(){return this.getYRange()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"zRange",{get:function(){return(this.cachedZRange===void 0||this.lastChangeCountForZRange!==this.changeCountProperty)&&(this.cachedZRange=this.getZRange(),this.lastChangeCountForZRange=this.changeCountProperty),this.cachedZRange},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"dataSeriesName",{get:function(){return this.dataSeriesNameProperty},set:function(p){this.dataSeriesNameProperty=p,this.notifyDataChanged(u.EDataChangeType.Property,null,null,"dataSeriesName")},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"hasValues",{get:function(){return this.arrayWidth>0&&this.arrayHeight>0},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"hasNaNs",{get:function(){return this.hasNaNsProperty},set:function(p){this.hasNaNsProperty=p,this.notifyDataChanged(u.EDataChangeType.Property,null,null,"hasNaNs")},enumerable:!1,configurable:!0}),h.prototype.count=function(){return this.arrayWidth*this.arrayHeight},h.prototype.setMetadataGenerator=function(p){var g=typeof this.metadataGeneratorProperty>"u";this.metadataGeneratorProperty=p,g&&this.setMetadata(null)},h.prototype.delete=function(){this.isDeleted=!0,this.cachedZRange=void 0,this.normalizedVector=(0,e.deleteSafe)(this.normalizedVector)},h.prototype.getIsDeleted=function(){return this.isDeleted},h.prototype.getNativeIndexes=function(){throw new Error("getNativeIndexes is invalid for heatmap type series. Try getting or setting zValues instead")},h.prototype.getNativeXValues=function(){throw new Error("getNativeXValues is invalid for heatmap type series. Try getting or setting zValues instead")},h.prototype.getNativeYValues=function(){throw new Error("getNativeYValues is invalid for heatmap type series. Try getting or setting zValues instead")},h.prototype.getWindowedYRange=function(p,g,v){return this.yRange},h.prototype.notifyDataChanged=function(p,g,v,y){this.changeCountProperty++,this.hasDataChangesProperty=!0,this.dataChanged.raiseEvent({changeType:p,index:g,yIndex:v,name:y})},h.prototype.getNormalizedVector=function(p,g){n.Guard.notNull(p,"colorMap"),n.Guard.argumentIsRealNumber(p.minimum,"colorMap.minimum"),n.Guard.argumentIsRealNumber(p.maximum,"colorMap.maximum");var v=this.arrayWidth*this.arrayHeight;return(this.hasDataChangesProperty||v!==this.normalizedVector.size()||p.minimum!==this.lastZMin||p.maximum!==this.lastZMax||g!==this.lastFillValuesOutOfRange)&&(this.recreateNormalizedVector(p.minimum,p.maximum,g),this.lastZMin=p.minimum,this.lastZMax=p.maximum,this.lastFillValuesOutOfRange=g,this.hasDataChangesProperty=!1),this.normalizedVector},h.prototype.recreateNormalizedVector=function(p,g,v){var y=this.arrayWidth*this.arrayHeight;this.normalizedVector.clear(),this.normalizedVector.resizeFast(y);var m=this.hasNaNs?p-(g-p)/128:p;if(!(0,l.isRealNumber)(m))throw Error("Can not create newZMin for try to use different zMin and zMax values");for(var b=0,S=1/(g-m),_=new Float32Array(this.arrayWidth),C=0;C<this.arrayHeight;C++){for(var P=0;P<this.arrayWidth;P++){var x=this.zValuesProperty[C][P],E=x-m;x!==x?E=0:E<p-m?E=v?p-m:0:E>g-m&&(E=v?g-m:0);var A=E*S;_[P]=A}(0,a.memCopyFloat32)(this.webAssemblyContext,_,this.normalizedVector,b),b+=this.arrayWidth}},h.prototype.getMetadataAt=function(p,g){if(this.validateIndexes(p,g),!!this.metadataProperty)return this.metadataProperty[p][g]},h.prototype.getMetadataHeight=function(){return this.metadataProperty?this.metadataProperty.length:this.arrayHeight},h.prototype.getMetadataWidth=function(){return this.metadataProperty?this.metadataProperty[0].length:this.arrayWidth},h.prototype.toJSON=function(p){p===void 0&&(p=!1);var g=this.getOptions(p);return{type:this.type,options:g}},h.prototype.getIndicesRange=function(p,g,v,y){},Object.defineProperty(h.prototype,"changeCount",{get:function(){return this.changeCountProperty},enumerable:!1,configurable:!0}),h.prototype.getOptions=function(p){p===void 0&&(p=!1);var g={id:this.id,containsNaN:this.hasNaNs,dataSeriesName:this.dataSeriesName,zValues:p?void 0:this.zValuesProperty,metadata:this.metadataGeneratorProperty?this.metadataGeneratorProperty.toJSON():p?void 0:this.metadataProperty};return g},h.prototype.getZRange=function(){var p=this.getZValues();if(p){for(var g=Number.MAX_VALUE,v=-Number.MAX_VALUE,y=0;y<this.arrayHeight;++y)for(var m=0;m<this.arrayWidth;m++){var b=p[y][m];b<g&&(g=b),b>v&&(v=b)}return new r.NumberRange(g,v)}},h.prototype.validateIndexes=function(p,g){if(Math.round(p)!==p)throw Error("yIndex must be an integer");if(Math.round(g)!==g)throw Error("xIndex must be an integer");if(p<0||p>=this.arrayHeight)throw new Error("yIndex is out of range");if(g<0||g>=this.arrayWidth)throw new Error("xIndex is out of range")},h.prototype.setMetadata=function(p){if(!p&&this.metadataGeneratorProperty){p=[];for(var g=0;g<this.arrayHeight;g++){p[g]=[];for(var v=0;v<this.arrayWidth;v++)p[g][v]=this.metadataGeneratorProperty.getSingleMetadata()}}this.metadataProperty=p},h.prototype.setMetadataAt=function(p,g,v){v&&(this.validateIndexes(p,g),this.fillMetadataIfUndefined(),this.metadataProperty[p][g]=v)},h.prototype.fillMetadataIfUndefined=function(){if(this.metadataProperty===void 0)for(var p=Array(this.arrayHeight).fill(void 0),g=0;g<this.arrayHeight;g++)p[g]=Array(this.arrayWidth).fill(void 0)},h})();VF.BaseHeatmapDataSeries=d;var f=function(h,p){n.Guard.arraysSameLengthArr([{arg:h,name:"zValues"},{arg:p,name:"metadata"}]);for(var g=0;g<h.length;g++)n.Guard.arraysSameLengthArr([{arg:h[g],name:"zValues[".concat(g,"]")},{arg:p[g],name:"metadata[".concat(g,"]")}])};return VF}var C0e;function MBe(){if(C0e)return Vx;C0e=1;var t=Vx&&Vx.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(Vx,"__esModule",{value:!0}),Vx.NonUniformHeatmapDataSeries=void 0;var e=Br(),i=ci(),n=di(),r=eAt(),o=Rf(),a=Bu(),s=mie(),l=zi(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,h)||this;if(p.type=l.EDataSeriesType.HeatmapNonUniform,i.Guard.notNull(h.xCellOffsets,"options.xCellOffsets"),i.Guard.notNull(h.yCellOffsets,"options.yCellOffsets"),!Array.isArray(h.xCellOffsets))p.xCellOffsetsGeneratorFunction=h.xCellOffsets;else{if(h.xCellOffsets.length<p.arrayWidth+1)throw new Error("xCellOffsets array should not be smaller than zValues width!");p.xCellOffsetsProperty=h.xCellOffsets}if(!Array.isArray(h.yCellOffsets))p.yCellOffsetsGeneratorFunction=h.yCellOffsets;else{if(h.yCellOffsets.length<p.arrayHeight+1)throw new Error("yCellOffsets array should not be smaller than zValues height!");p.yCellOffsetsProperty=h.yCellOffsets}return p.nativeXOffsetsProperty=new p.webAssemblyContext.SCRTDoubleVector,p.nativeYOffsetsProperty=new p.webAssemblyContext.SCRTDoubleVector,p.getZValues()&&p.notifyDataChanged(l.EDataChangeType.Append),p}return d.prototype.getXCellSizes=function(f){return this.xCellSizesProperty||(this.xCellSizesProperty=this.calculateCellSizes(this.xCellOffsetsProperty,f)),this.xCellSizesProperty},d.prototype.getYCellSizes=function(){return this.yCellSizesProperty||(this.yCellSizesProperty=this.calculateCellSizes(this.yCellOffsetsProperty,function(f){return f})),this.yCellSizesProperty},Object.defineProperty(d.prototype,"xCellOffsets",{get:function(){return this.xCellOffsetsProperty},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"yCellOffsets",{get:function(){return this.yCellOffsetsProperty},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"nativeXCellOffsets",{get:function(){return this.nativeXOffsetsProperty||(this.nativeXOffsetsProperty=new r.SCRTDoubleVector,(0,o.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.nativeXOffsetsProperty,this.xCellOffsets)),this.nativeXOffsetsProperty},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"nativeYCellOffsets",{get:function(){return this.nativeYOffsetsProperty||(this.nativeYOffsetsProperty=new r.SCRTDoubleVector,(0,o.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.nativeYOffsetsProperty,this.yCellOffsets)),this.nativeYOffsetsProperty},enumerable:!1,configurable:!0}),d.prototype.getXValue=function(f){var h=this.xCellOffsetsProperty[f];return h},d.prototype.getYValue=function(f){var h=this.yCellOffsetsProperty[f];return h},d.prototype.notifyDataChanged=function(f,h){!this.xCellOffsets&&!this.xCellOffsetsGeneratorFunction||!this.yCellOffsets&&!this.yCellOffsetsGeneratorFunction||(f===l.EDataChangeType.Append&&(this.xCellOffsetsGeneratorFunction&&(this.xCellOffsetsProperty=this.mapCellSizes(this.arrayWidth,this.xCellOffsetsGeneratorFunction),this.xCellSizesProperty=void 0),this.yCellOffsetsGeneratorFunction&&(this.yCellOffsetsProperty=this.mapCellSizes(this.arrayHeight,this.yCellOffsetsGeneratorFunction),this.yCellSizesProperty=void 0),this.nativeXOffsetsProperty.clear(),this.nativeYOffsetsProperty.clear(),(0,o.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.nativeXOffsetsProperty,this.xCellOffsetsProperty),(0,o.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.nativeYOffsetsProperty,this.yCellOffsetsProperty)),this.xRangeProperty=new n.NumberRange(this.getXValue(0),this.getXValue(this.arrayWidth)),this.yRangeProperty=new n.NumberRange(this.getYValue(0),this.getYValue(this.arrayHeight)),c.prototype.notifyDataChanged.call(this,f,h))},d.prototype.getXRange=function(){return this.xRangeProperty},d.prototype.getYRange=function(){return this.yRangeProperty},d.prototype.getXIndicesRange=function(f,h,p,g){return(0,a.getIndicesRange)(this.webAssemblyContext,this.nativeXCellOffsets,f,!0)},d.prototype.getYIndicesRange=function(f,h,p,g){return(0,a.getIndicesRange)(this.webAssemblyContext,this.nativeYCellOffsets,f,!0)},d.prototype.delete=function(){c.prototype.delete.call(this),this.nativeXOffsetsProperty=(0,e.deleteSafe)(this.nativeXOffsetsProperty),this.nativeYOffsetsProperty=(0,e.deleteSafe)(this.nativeYOffsetsProperty)},d.prototype.getOptions=function(f){var h=c.prototype.getOptions.call(this,f),p={xCellOffsets:this.xCellOffsetsProperty,yCellOffsets:this.yCellOffsetsProperty};return Object.assign(h,p)},d.prototype.mapCellSizes=function(f,h){for(var p=[],g=f+1,v=0;v<g;++v)p.push(h(v));return p},d.prototype.calculateCellSizes=function(f,h){if(!f||f.length===0)return[];for(var p=f.length,g=h(f[p-1])-h(f[0]),v=[],y=0;y<p-1;++y){var m=h(f[y+1])-h(f[y]);v.push(m/g)}return v},d})(s.BaseHeatmapDataSeries);return Vx.NonUniformHeatmapDataSeries=u,Vx}var Hx={},T0e;function bie(){if(T0e)return Hx;T0e=1;var t=Hx&&Hx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Hx,"__esModule",{value:!0}),Hx.UniformHeatmapDataSeries=void 0;var e=di(),i=mie(),n=zi(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.type=n.EDataSeriesType.HeatmapUniform,u.xStartProperty=l.xStart,u.xStepProperty=l.xStep,u.yStartProperty=l.yStart,u.yStepProperty=l.yStep,u.xRangeProperty=new e.NumberRange(u.xStart,u.getXValue(u.arrayWidth)),u.yRangeProperty=new e.NumberRange(u.yStart,u.getYValue(u.arrayHeight)),u}return Object.defineProperty(a.prototype,"xStart",{get:function(){return this.xStartProperty},set:function(s){this.xStartProperty=s,this.notifyDataChanged(n.EDataChangeType.Update)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"xStep",{get:function(){return this.xStepProperty},set:function(s){this.xStepProperty=s,this.notifyDataChanged(n.EDataChangeType.Update)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"yStart",{get:function(){return this.yStartProperty},set:function(s){this.yStartProperty=s,this.notifyDataChanged(n.EDataChangeType.Update)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"yStep",{get:function(){return this.yStepProperty},set:function(s){this.yStepProperty=s,this.notifyDataChanged(n.EDataChangeType.Update)},enumerable:!1,configurable:!0}),a.prototype.getXValue=function(s){var l=this.xStep*s;return this.xStart+l},a.prototype.getYValue=function(s){var l=this.yStep*s;return this.yStart+l},a.prototype.notifyDataChanged=function(s,l){this.xRangeProperty=new e.NumberRange(this.xStart,this.getXValue(this.arrayWidth)),this.yRangeProperty=new e.NumberRange(this.yStart,this.getYValue(this.arrayHeight)),o.prototype.notifyDataChanged.call(this,s,l)},a.prototype.getXRange=function(){return this.xRangeProperty},a.prototype.getYRange=function(){return this.yRangeProperty},a.prototype.getOptions=function(s){var l=o.prototype.getOptions.call(this,s),u={xStart:this.xStart,xStep:this.xStep,yStart:this.yStart,yStep:this.yStep};return Object.assign(l,u)},a})(i.BaseHeatmapDataSeries);return Hx.UniformHeatmapDataSeries=r,Hx}var pb={},x0e;function Sie(){if(x0e)return pb;x0e=1;var t=pb&&pb.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=pb&&pb.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(pb,"__esModule",{value:!0}),pb.XDataSeries=void 0;var i=di(),n=bo(),r=Bu(),o=zi(),a=(function(s){t(l,s);function l(u,c){var d=this,f=e(e({},c),{arrayCount:0});return d=s.call(this,u,f)||this,d.type=o.EDataSeriesType.X,f!=null&&f.xValues&&(d.appendRange(f.xValues,f.metadata),f!=null&&f.fifoCapacity&&(f!=null&&f.fifoStartIndex)&&d.xValues.notifyAppend(f==null?void 0:f.fifoStartIndex)),d}return l.prototype.append=function(u,c){s.prototype.appendN.call(this,u,[],c,void 0)},l.prototype.appendRange=function(u,c){s.prototype.appendRangeN.call(this,u,[],c)},l.prototype.updateX=function(u,c,d){s.prototype.updateXyN.call(this,u,c,[],d)},l.prototype.insert=function(u,c,d){s.prototype.insertN.call(this,u,c,[],d)},l.prototype.insertRange=function(u,c,d){s.prototype.insertRangeN.call(this,u,c,[],d)},l.prototype.getWindowedYRange=function(u,c,d,f,h){return new i.NumberRange(0,1)},l.prototype.getOptions=function(u){u===void 0&&(u=!1);var c=s.prototype.getOptions.call(this,u);if(!u){var d=(0,n.vectorToArray)(this.xValues,this.webAssemblyContext),f={xValues:d,yValues:void 0};Object.assign(c,f)}return c},l})(r.BaseDataSeries);return pb.XDataSeries=a,pb}var gb={},Ux={},E0e;function LBe(){if(E0e)return Ux;E0e=1;var t=Ux&&Ux.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Ux,"__esModule",{value:!0}),Ux.XyNPointSeriesResampled=void 0;var e=fo(),i=Yo(),n=zi(),r=lR(),o=(function(a){t(s,a);function s(l,u,c,d){c===void 0&&(c=1);var f=a.call(this)||this;f.type=n.EDataSeriesType.XyN,f.subSeries=[],f.arrayCount=1,f.resampled=!0,f.wasmContext=l,f.arrayCount=c,f.valueNames=d??(0,i.generateValueNamesForDataSeries)(f.arrayCount);for(var h=0;h<f.arrayCount;h++)f.subSeries.push(new r.XyPointSeriesResampled(l,u,f.valueNames[h]));return f.xRange=u,f}return Object.defineProperty(s.prototype,"intIndexes",{get:function(){return this.subSeries[0].intIndexes},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"indexes",{get:function(){return this.subSeries[0].indexes},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"xValues",{get:function(){return this.subSeries[0].xValues},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"count",{get:function(){return this.subSeries[0].xValues.size()},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"yValues",{get:function(){return this.subSeries[0].yValues},enumerable:!1,configurable:!0}),s.prototype.getYValues=function(l){return this.subSeries[0].getYValues(l)},s.prototype.getYValuesByName=function(l){return this.subSeries[0].getYValuesByName(l)},s.prototype.getSubSeriesByName=function(l){var u=this.valueNames.indexOf(l);if(u>=0)return this.subSeries[u]},s.prototype.delete=function(){this.subSeries.forEach(function(l){return l.delete()}),this.subSeries.length=0,this.wasmContext=void 0},s.prototype.clearIntIndexes=function(){},s})(e.DeletableEntity);return Ux.XyNPointSeriesResampled=o,Ux}var w0e;function kBe(){if(w0e)return gb;w0e=1;var t=gb&&gb.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=gb&&gb.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(gb,"__esModule",{value:!0}),gb.XyNDataSeries=void 0;var i=ci(),n=bo(),r=Om(),o=Bu(),a=zi(),s=wm(),l=LBe(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y,m=e(e({},h),{arrayCount:(v=(g=h.yValuesArray)===null||g===void 0?void 0:g.length)!==null&&v!==void 0?v:h.arrayCount});if(p=c.call(this,f,m)||this,p.type=a.EDataSeriesType.XyN,!m.arrayCount&&!m.yValuesArray)throw new Error("XyNDataSeries requres either arrayCount or yValuesArray to initialize the size");return p.resamplingModes=(y=m==null?void 0:m.resamplingModes)!==null&&y!==void 0?y:p.valueNames.map(function(b){return r.EResamplingMode.Auto}),m!=null&&m.xValues&&(m!=null&&m.yValuesArray)&&(p.appendRangeN(m.xValues,m.yValuesArray,m.metadata),m!=null&&m.fifoCapacity&&(m!=null&&m.fifoStartIndex)&&(p.xValues.notifyAppend(m==null?void 0:m.fifoStartIndex),p.yValuesArray.forEach(function(b){b.notifyAppend(m==null?void 0:m.fifoStartIndex)}))),p}return d.prototype.notifyDataChanged=function(f,h,p,g){this.resamplingParams=void 0,c.prototype.notifyDataChanged.call(this,f,h,p,g)},d.prototype.toPointSeries=function(f,h,p){if(f&&(f.dataIsFifo||f.resamplingMode!==r.EResamplingMode.None)){if(this.pointSeries?this.pointSeries.xRange=f.xVisibleRange:this.pointSeries=new l.XyNPointSeriesResampled(this.webAssemblyContext,f.xVisibleRange,this.arrayCount,this.valueNames),!this.resamplingParams)this.resamplingParams=f;else if(this.resamplingParams.indexesRange.equals(f.indexesRange)&&this.resamplingParams.precision==f.precision&&this.resamplingParams.viewportSize===f.viewportSize)return this.pointSeries;this.resamplingParams=f;var g=this.pointSeries;i.Guard.notNull(p,"resamplerHelper");for(var v=0;v<this.arrayCount;v++){var y=g.subSeries[v],m=f.clone({resamplingMode:this.resamplingModes[v]}),b=p.resampleIntoPointSeries(this.webAssemblyContext,m,this.getNativeXValues(),this.getNativeYValues(v),y.intIndexes,y.indexes,y.xValues,y.yValues,!1);y.fifoStartIndex=b.OutputSplitIndex,y.clearIntIndexes()}return this.pointSeries}else return new s.BasePointSeriesWrapped(this)},d.prototype.getOptions=function(f){f===void 0&&(f=!1);var h=c.prototype.getOptions.call(this,f);if(!f){for(var p=(0,n.vectorToArray)(this.xValues,this.webAssemblyContext),g=[],v=0;v<this.arrayCount;v++)g[v]=(0,n.vectorToArray)(this.yValuesArray[v],this.webAssemblyContext);var y={xValues:p,yValuesArray:g,resamplingModes:this.resamplingModes,yValues:void 0};Object.assign(h,y)}return h},d})(o.BaseDataSeries);return gb.XyNDataSeries=u,gb}var vb={},A0e;function IBe(){if(A0e)return vb;A0e=1;var t=vb&&vb.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=vb&&vb.__spreadArray||function(l,u,c){if(c||arguments.length===2)for(var d=0,f=u.length,h;d<f;d++)(h||!(d in u))&&(h||(h=Array.prototype.slice.call(u,0,d)),h[d]=u[d]);return l.concat(h||Array.prototype.slice.call(u))};Object.defineProperty(vb,"__esModule",{value:!0}),vb.XyTextDataSeries=void 0;var i=ci(),n=Th(),r=bo(),o=Bu(),a=zi(),s=(function(l){t(u,l);function u(c,d){var f=l.call(this,c,d)||this;return f.type=a.EDataSeriesType.XyText,f.textValuesProperty=[],d!=null&&d.xValues&&(i.Guard.notNull(d.yValues,"options.yValues"),f.appendRange(d.xValues,d.yValues,d.textValues,d.metadata)),f}return Object.defineProperty(u.prototype,"textValues",{get:function(){return this.textValuesProperty},enumerable:!1,configurable:!0}),u.prototype.getTextValue=function(c){if(!this.fifoCapacity)return this.textValuesProperty[c];if(this.fifoSweeping)return this.fifoCapacity-c<this.fifoSweepingGap?"":this.textValuesProperty[c];var d=(this.xValues.getStartIndex()+c)%this.fifoCapacity;return this.textValuesProperty[d]},u.prototype.append=function(c,d,f,h){var p=this,g=function(){p.fifoCapacity&&p.count()===p.fifoCapacity?p.textValuesProperty[p.xValues.getStartIndex()]=f:p.textValuesProperty.push(f)};l.prototype.appendN.call(this,c,[d],h,g)},u.prototype.appendRange=function(c,d,f,h){var p=this,g=function(){p.fifoCapacity?(0,n.appendRangeFifo)(f,p.textValuesProperty,p.fifoCapacity,p.xValues.getStartIndex()):p.textValuesProperty=p.textValuesProperty.concat(f)};l.prototype.appendRangeN.call(this,c,[d],h,g)},u.prototype.update=function(c,d,f,h){var p=this,g=function(){return p.textValuesProperty[c]=f};l.prototype.updateN.call(this,c,[d],h,g)},u.prototype.updateXyText=function(c,d,f,h,p){var g=this,v=function(){return g.textValuesProperty[c]=h};l.prototype.updateXyN.call(this,c,d,[f],p,v)},u.prototype.insert=function(c,d,f,h,p){var g=this,v=function(){return g.textValuesProperty.splice(c,0,h)};l.prototype.insertN.call(this,c,d,[f],p,v)},u.prototype.insertRange=function(c,d,f,h,p){var g=this,v=function(){var y;return(y=g.textValuesProperty).splice.apply(y,e([c,0],h,!1))};l.prototype.insertRangeN.call(this,c,d,[f],p,v)},u.prototype.removeAt=function(c){this.getIsDeleted()||(this.textValuesProperty.splice(c,1),l.prototype.removeAt.call(this,c))},u.prototype.removeRange=function(c,d){this.getIsDeleted()||(this.textValuesProperty.splice(c,d),l.prototype.removeRange.call(this,c,d))},u.prototype.clear=function(){this.getIsDeleted()||(this.textValuesProperty=[],l.prototype.clear.call(this))},Object.defineProperty(u.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),u.prototype.getOptions=function(c){c===void 0&&(c=!1);var d=l.prototype.getOptions.call(this);if(!c){var f=(0,r.vectorToArray)(this.xValues,this.webAssemblyContext),h=(0,r.vectorToArray)(this.yValues,this.webAssemblyContext),p={xValues:f,yValues:h,textValues:this.textValuesProperty};Object.assign(d,p)}return d},u})(o.BaseDataSeries);return vb.XyTextDataSeries=s,vb}var yb={},O0e;function NBe(){if(O0e)return yb;O0e=1;var t=yb&&yb.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=yb&&yb.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(yb,"__esModule",{value:!0}),yb.XyxDataSeries=void 0;var i=ci(),n=Yo(),r=bo(),o=Bu(),a=zi(),s=(function(l){t(u,l);function u(c,d){var f=this,h=e(e({},d),{arrayCount:2,valueNames:[n.EValueName.Y,n.EValueName.X1],includeInYRange:[!0,!1]});return f=l.call(this,c,h)||this,f.type=a.EDataSeriesType.Xyx,h!=null&&h.xValues&&(i.Guard.notNull(h.yValues,"baseOptions.yValues"),i.Guard.notNull(h.x1Values,"baseOptions.x1Values"),f.appendRange(h.xValues,h.yValues,h.x1Values,h.metadata),h!=null&&h.fifoCapacity&&(h!=null&&h.fifoStartIndex)&&(f.xValues.notifyAppend(h==null?void 0:h.fifoStartIndex),f.yValues.notifyAppend(h==null?void 0:h.fifoStartIndex),f.x1Values.notifyAppend(h==null?void 0:h.fifoStartIndex))),f}return Object.defineProperty(u.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"x1Values",{get:function(){return this.getNativeYValues(1)},enumerable:!1,configurable:!0}),u.prototype.append=function(c,d,f,h){l.prototype.appendN.call(this,c,[d,f],h)},u.prototype.appendRange=function(c,d,f,h){l.prototype.appendRangeN.call(this,c,[d,f],h)},u.prototype.update=function(c,d,f,h){l.prototype.updateN.call(this,c,[d,f],h)},u.prototype.updateXyz=function(c,d,f,h,p){l.prototype.updateXyN.call(this,c,d,[f,h],p)},u.prototype.insert=function(c,d,f,h,p){l.prototype.insertN.call(this,c,d,[f,h],p)},u.prototype.insertRange=function(c,d,f,h,p){l.prototype.insertRangeN.call(this,c,d,[f,h],p)},u.prototype.getOptions=function(c){c===void 0&&(c=!1);var d=l.prototype.getOptions.call(this,c);if(!c){var f=(0,r.vectorToArray)(this.xValues,this.webAssemblyContext),h=(0,r.vectorToArray)(this.yValues,this.webAssemblyContext),p=(0,r.vectorToArray)(this.x1Values,this.webAssemblyContext),g={xValues:f,yValues:h,x1Values:p};Object.assign(d,g)}return d},u})(o.BaseDataSeries);return yb.XyxDataSeries=s,yb}var mb={},D0e;function FBe(){if(D0e)return mb;D0e=1;var t=mb&&mb.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})(),e=mb&&mb.__assign||function(){return e=Object.assign||function(f){for(var h,p=1,g=arguments.length;p<g;p++){h=arguments[p];for(var v in h)Object.prototype.hasOwnProperty.call(h,v)&&(f[v]=h[v])}return f},e.apply(this,arguments)};Object.defineProperty(mb,"__esModule",{value:!0}),mb.XyxyDataSeries=void 0;var i=Br(),n=ci(),r=di(),o=ym(),a=Yo(),s=kp(),l=bo(),u=Bu(),c=zi(),d=(function(f){t(h,f);function h(p,g){var v=this,y=e(e({},g),{arrayCount:3,valueNames:[a.EValueName.Y,a.EValueName.X1,a.EValueName.Y1],includeInYRange:[!0,!1,!0]});return v=f.call(this,p,y)||this,v.type=c.EDataSeriesType.Xyxy,y!=null&&y.xValues&&(n.Guard.notNull(y.yValues,"baseOptions.yValues"),n.Guard.notNull(y.x1Values,"baseOptions.x1Values"),n.Guard.notNull(y.y1Values,"baseOptions.y1Values"),v.appendRange(y.xValues,y.yValues,y.x1Values,y.y1Values,y.metadata),y!=null&&y.fifoCapacity&&(y!=null&&y.fifoStartIndex)&&(v.xValues.notifyAppend(y==null?void 0:y.fifoStartIndex),v.yValues.notifyAppend(y==null?void 0:y.fifoStartIndex),v.x1Values.notifyAppend(y==null?void 0:y.fifoStartIndex),v.y1Values.notifyAppend(y==null?void 0:y.fifoStartIndex))),v}return Object.defineProperty(h.prototype,"yValues",{get:function(){return this.getNativeYValues()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"x1Values",{get:function(){return this.getNativeYValues(1)},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"y1Values",{get:function(){return this.getNativeYValues(2)},enumerable:!1,configurable:!0}),h.prototype.append=function(p,g,v,y,m){f.prototype.appendN.call(this,p,[g,v,y],m)},h.prototype.appendRange=function(p,g,v,y,m){f.prototype.appendRangeN.call(this,p,[g,v,y],m)},h.prototype.update=function(p,g,v,y,m){f.prototype.updateN.call(this,p,[g,v,y],m)},h.prototype.updateXyz=function(p,g,v,y,m,b){f.prototype.updateXyN.call(this,p,g,[v,y,m],b)},h.prototype.insert=function(p,g,v,y,m,b){f.prototype.insertN.call(this,p,g,[v,y,m],b)},h.prototype.insertRange=function(p,g,v,y,m,b){f.prototype.insertRangeN.call(this,p,g,[v,y,m],b)},h.prototype.getIndicesRange=function(p,g,v,y){g===void 0&&(g=!1),v===void 0&&(v=o.ESearchMode.RoundDown),y===void 0&&(y=o.ESearchMode.RoundUp);var m=g?this.getNativeIndexes():this.xValues,b=(0,u.getIndicesRange)(this.webAssemblyContext,m,p,this.dataDistributionCalculator.isSortedAscending,v,y),S=g?this.getNativeIndexes():this.x1Values,_=(0,u.getIndicesRange)(this.webAssemblyContext,S,p,this.dataDistributionCalculator.isSortedAscending,v,y);return b.union(_)},h.prototype.getXRange=function(p){var g=this.getXValues(p),v=this.getXyxyValues(p).x1Values,y;if(this.count()===1){var m=g.get(0),b=v.get(0),S=Math.min(m,b),_=Math.max(m,b);return S===_&&(S-=1,_+=1),new r.NumberRange(S,_)}else if(this.count()>1){var S=void 0,_=void 0,C=void 0,P=void 0;try{if(C=this.webAssemblyContext.NumberUtil.MinMax(g,!1),P=this.webAssemblyContext.NumberUtil.MinMax(v,!1),S=Math.min(C.minD,P.minD),_=Math.max(C.maxD,P.maxD),!(0,s.isRealNumber)(S)||!(0,s.isRealNumber)(_))return new r.NumberRange(0,0)}finally{(0,i.deleteSafe)(C),(0,i.deleteSafe)(P)}return S===_?new r.NumberRange(S-1,_+1):(S>_&&(y=S,S=_,_=y),new r.NumberRange(S,_))}return new r.NumberRange(0,0)},h.prototype.getOptions=function(p){p===void 0&&(p=!1);var g=f.prototype.getOptions.call(this,p);if(!p){var v=(0,l.vectorToArray)(this.xValues,this.webAssemblyContext),y=(0,l.vectorToArray)(this.yValues,this.webAssemblyContext),m=(0,l.vectorToArray)(this.x1Values,this.webAssemblyContext),b=(0,l.vectorToArray)(this.y1Values,this.webAssemblyContext),S={xValues:v,yValues:y,x1Values:m,y1Values:b};Object.assign(g,S)}return g},h.prototype.getXyxyValues=function(p){var g,v,y;switch(p){case c.EDataSeriesValueType.FinalAnimationValues:g=this.yFinalAnimationValuesArray[0],v=this.yFinalAnimationValuesArray[1],y=this.yFinalAnimationValuesArray[2];break;case c.EDataSeriesValueType.InitialAnimationValues:g=this.yInitialAnimationValuesArray[0],v=this.yInitialAnimationValuesArray[1],y=this.yInitialAnimationValuesArray[2];break;default:g=this.yValues,v=this.x1Values,y=this.y1Values}return{yValues:g,x1Values:v,y1Values:y}},h})(u.BaseDataSeries);return mb.XyxyDataSeries=d,mb}var HF={},R0e;function Uf(){return R0e||(R0e=1,(function(t){var e=HF&&HF.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.BaseDataSeries3D=t.EDataSeriesType3D=void 0;var i=fo(),n=ps();(function(o){o.Xyz3D="Xyz",o.UniformGrid3D="UniformGrid3D",o.NonUniformGrid3D="NonUniformGrid3D"})(t.EDataSeriesType3D||(t.EDataSeriesType3D={}));var r=(function(o){e(a,o);function a(s,l){var u=this,c;return u=o.call(this)||this,u.webAssemblyContext=s,u.dataSeriesNameProperty=(c=l==null?void 0:l.dataSeriesName)!==null&&c!==void 0?c:u.dataSeriesNameProperty,u.dataChanged=new n.EventHandler,u.isModifiedProperty=!0,u}return Object.defineProperty(a.prototype,"dataSeriesName",{get:function(){return this.dataSeriesNameProperty},set:function(s){this.dataSeriesNameProperty=s,this.notifyDataChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"isModified",{get:function(){return this.isModifiedProperty},enumerable:!1,configurable:!0}),a.prototype.getIsDeleted=function(){return this.isDeleted},a.prototype.delete=function(){this.isDeleted=!0,this.webAssemblyContext=void 0},a.prototype.notifyDataChanged=function(){this.isModifiedProperty=!0,this.dataChanged.raiseEvent()},a.prototype.resetModified=function(){this.isModifiedProperty=!1},a.prototype.toJSON=function(s){s===void 0&&(s=!1);var l=this.getOptions(s);return{type:this.type,options:l}},a.prototype.getOptions=function(s){var l={dataSeriesName:this.dataSeriesName};return l},a})(i.DeletableEntity);t.BaseDataSeries3D=r})(HF)),HF}var zx={},$x={},M0e;function BBe(){if(M0e)return $x;M0e=1;var t=$x&&$x.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty($x,"__esModule",{value:!0}),$x.BaseGridDataSeries3D=void 0;var e=ci(),i=di(),n=Uf(),r=(function(a){t(s,a);function s(l,u){var c=a.call(this,l,u)||this;return c.setYValues(u==null?void 0:u.yValues,u==null?void 0:u.metadata),c}return Object.defineProperty(s.prototype,"yRange",{get:function(){if(!this.yRangeCached){for(var l=-Number.MAX_VALUE,u=Number.MAX_VALUE,c=0;c<this.zSizeProperty;c++)for(var d=0;d<this.xSizeProperty;d++){var f=this.yValuesProperty[c][d];l=Math.max(f,l),u=Math.min(f,u)}this.yRangeCached=new i.NumberRange(u,l)}return this.yRangeCached},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"zSize",{get:function(){return this.zSizeProperty},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"xSize",{get:function(){return this.xSizeProperty},enumerable:!1,configurable:!0}),s.prototype.getMetadataValues=function(){return this.metadataProperty},s.prototype.setYValues=function(l,u){if(!l||!l[0]){this.yValuesProperty=void 0,this.xSizeProperty=0,this.zSizeProperty=0;return}var c=l[0].length;l.forEach(function(h){if(!h)throw new Error("Each row in YValues must be defined. See how to declare a 2D array in Javascript here https://stackoverflow.com/a/966234/303612");if(h.length!==c)throw new Error("Each row in YValues must be the same length, so that the overall 2D array is square")}),u&&(o(l,u),this.metadataProperty=u);var d=l[0].length,f=l.length;this.xSizeProperty=d,this.zSizeProperty=f,this.yValuesProperty=l,this.notifyDataChanged()},s.prototype.getYValues=function(){return this.yValuesProperty},s.prototype.getYValue=function(l,u){try{return this.yValuesProperty[l][u]}catch{return console.log("error at get z,x ".concat(l,", ").concat(u)),0}},s.prototype.setYValue=function(l,u,c,d){this.yValuesProperty[l][u]=c,d&&(this.validateIndexes(l,u),this.metadataProperty[l][u]=d),this.notifyDataChanged()},s.prototype.notifyDataChanged=function(){a.prototype.notifyDataChanged.call(this),this.yRangeCached=void 0},s.prototype.getMetadataAt=function(l,u){if(this.metadataProperty)return this.validateIndexes(l,u),this.metadataProperty[l][u]},s.prototype.getMetadataHeight=function(){return this.metadataProperty?this.metadataProperty.length:this.zSizeProperty},s.prototype.getMetadataWidth=function(){return this.metadataProperty?this.metadataProperty[0].length:this.xSizeProperty},s.prototype.setMetadata=function(l){this.metadataProperty=l},s.prototype.setMetadataAt=function(l,u,c){c&&(this.metadataProperty[l][u]=c)},s.prototype.delete=function(){this.yValuesProperty=void 0,this.metadataProperty=void 0,this.yRangeCached=void 0,a.prototype.delete.call(this)},s.prototype.getOptions=function(l){var u=a.prototype.getOptions.call(this,l);if(l)return u;var c={yValues:this.getYValues(),metadata:this.metadataProperty};return Object.assign(u,c)},s.prototype.validateIndexes=function(l,u){if(Math.round(l)!==l)throw Error("zIndex must be an integer");if(Math.round(u)!==u)throw Error("xIndex must be an integer");if(l<0||l>=this.zSizeProperty)throw new Error("zIndex is out of range");if(u<0||u>=this.xSizeProperty)throw new Error("xIndex is out of range")},s})(n.BaseDataSeries3D);$x.BaseGridDataSeries3D=r;var o=function(a,s){e.Guard.arraysSameLengthArr([{arg:a,name:"yValues"},{arg:s,name:"metadata"}]);for(var l=0;l<a.length;l++)e.Guard.arraysSameLengthArr([{arg:a[l],name:"yValues[".concat(l,"]")},{arg:s[l],name:"metadata[".concat(l,"]")}])};return $x}var L0e;function jBe(){if(L0e)return zx;L0e=1;var t=zx&&zx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(zx,"__esModule",{value:!0}),zx.UniformGridDataSeries3D=void 0;var e=di(),i=Uf(),n=BBe(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.type=i.EDataSeriesType3D.UniformGrid3D,u.xStartProperty=(l==null?void 0:l.xStart)||0,u.xStepProperty=(l==null?void 0:l.xStep)||1,u.zStartProperty=(l==null?void 0:l.zStart)||0,u.zStepProperty=(l==null?void 0:l.zStep)||1,u}return Object.defineProperty(a.prototype,"xStart",{get:function(){return this.xStartProperty},set:function(s){this.xStartProperty=s,this.notifyDataChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"xStep",{get:function(){return this.xStepProperty},set:function(s){this.xStepProperty=s,this.notifyDataChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"zStart",{get:function(){return this.zStartProperty},set:function(s){this.zStartProperty=s,this.notifyDataChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"zStep",{get:function(){return this.zStepProperty},set:function(s){this.zStepProperty=s,this.notifyDataChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"xRange",{get:function(){return new e.NumberRange(this.xStart,this.xStart+this.xStep*(this.xSize-1))},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"zRange",{get:function(){return new e.NumberRange(this.zStart,this.zStart+this.zStep*(this.zSize-1))},enumerable:!1,configurable:!0}),a.prototype.getX=function(s){return this.xStart+s*this.xStep},a.prototype.getZ=function(s){return this.zStart+s*this.zStep},a.prototype.getOptions=function(s){var l=o.prototype.getOptions.call(this,s);if(s)return l;var u={xStart:this.xStart,xStep:this.xStep,zStart:this.zStart,zStep:this.zStep};return Object.assign(l,u)},a})(n.BaseGridDataSeries3D);return zx.UniformGridDataSeries3D=r,zx}var Wx={},k0e;function VBe(){if(k0e)return Wx;k0e=1;var t=Wx&&Wx.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(Wx,"__esModule",{value:!0}),Wx.XyzDataSeries3D=void 0;var e=Br(),i=ci(),n=di(),r=Rf(),o=La(),a=bo(),s=Uf(),l=(function(u){t(c,u);function c(d,f){var h=u.call(this,d,f)||this;return h.type=s.EDataSeriesType3D.Xyz3D,h.xValues=new d.SCRTDoubleVector,h.yValues=new d.SCRTDoubleVector,h.zValues=new d.SCRTDoubleVector,h.metadata=[],f!=null&&f.xValues&&(f!=null&&f.yValues)&&(f!=null&&f.zValues)&&h.appendRange(f.xValues,f.yValues,f.zValues,f==null?void 0:f.metadata),h}return c.prototype.getNativeXValues=function(){return this.xValues},c.prototype.getNativeYValues=function(){return this.yValues},c.prototype.getNativeZValues=function(){return this.zValues},c.prototype.getMetadataValues=function(){return this.metadata},Object.defineProperty(c.prototype,"xRange",{get:function(){var d=this.webAssemblyContext.NumberUtil.MinMax(this.xValues,!0),f=new n.NumberRange(d.minD,d.maxD);return d.delete(),f},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"yRange",{get:function(){var d=this.webAssemblyContext.NumberUtil.MinMax(this.yValues,!0),f=new n.NumberRange(d.minD,d.maxD);return d.delete(),f},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"zRange",{get:function(){var d=this.webAssemblyContext.NumberUtil.MinMax(this.zValues,!0),f=new n.NumberRange(d.minD,d.maxD);return d.delete(),f},enumerable:!1,configurable:!0}),c.prototype.append=function(d,f,h,p){this.getIsDeleted()||(this.xValues.push_back(d),this.yValues.push_back(f),this.zValues.push_back(h),this.metadata.push(p),this.notifyDataChanged())},c.prototype.appendRange=function(d,f,h,p){if(!this.getIsDeleted()){if(i.Guard.arraysSameLength(d,"xValues",f,"yValues"),i.Guard.arraysSameLength(f,"yValues",h,"zValues"),p){i.Guard.arraysSameLength(p,"metadatas",d,"xValues");var g=this.metadata.length;this.metadata.length=g+d.length;for(var v=0;v<d.length;v++)this.metadata[g+v]=p[v]}else{var g=this.metadata.length;this.metadata.length=g+d.length}(0,r.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.xValues,d),(0,r.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.yValues,f),(0,r.appendDoubleVectorFromJsArray)(this.webAssemblyContext,this.zValues,h),this.notifyDataChanged()}},c.prototype.update=function(d,f,h,p,g){this.getIsDeleted()||(this.xValues.set(d,f),this.yValues.set(d,h),this.zValues.set(d,p),this.metadata[d]=g,this.notifyDataChanged())},c.prototype.insert=function(d,f,h,p,g){var v,y=o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.DataUpdateStart,{contextId:this.dataSeriesName});if(!this.getIsDeleted()){if(d<0||d>this.count())throw new Error("Start index is out of range");this.xValues.insertAt(d,f),this.yValues.insertAt(d,h),this.zValues.insertAt(d,p),this.metadata.splice(d,0,g),this.notifyDataChanged()}o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.DataUpdateEnd,{relatedId:(v=y==null?void 0:y.detail)===null||v===void 0?void 0:v.relatedId,contextId:this.dataSeriesName})},c.prototype.insertRange=function(d,f,h,p,g){var v,y=o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.DataUpdateStart,{contextId:this.dataSeriesName});if(!this.getIsDeleted()){if(i.Guard.arraysSameLength(f,"xValues",h,"yValues"),i.Guard.arraysSameLength(p,"zValues",h,"yValues"),d<0||d>this.count())throw new Error("Start index is out of range");if((0,r.insertDoubleVectorFromJsArray)(this.webAssemblyContext,f,this.xValues,d),(0,r.insertDoubleVectorFromJsArray)(this.webAssemblyContext,h,this.yValues,d),(0,r.insertDoubleVectorFromJsArray)(this.webAssemblyContext,p,this.zValues,d),g){var m=this.metadata.slice(0,d),b=this.metadata.slice(d);this.metadata=m.concat(g,b)}else{var S=Array(f.length).fill(void 0),m=this.metadata.slice(0,d),b=this.metadata.slice(d);this.metadata=m.concat(S,b)}this.notifyDataChanged()}o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.DataUpdateEnd,{relatedId:(v=y==null?void 0:y.detail)===null||v===void 0?void 0:v.relatedId,contextId:this.dataSeriesName})},c.prototype.removeAt=function(d){if(!this.getIsDeleted()){if(d<0||d>=this.count())throw new Error("index is out of range");this.xValues.removeAt(d),this.yValues.removeAt(d),this.zValues.removeAt(d),this.metadata.splice(d,1),this.notifyDataChanged()}},c.prototype.removeRange=function(d,f){if(!this.getIsDeleted()){if(d<0||d+f>this.count())throw new Error("index is out of range");this.xValues.removeRange(d,f),this.yValues.removeRange(d,f),this.zValues.removeRange(d,f),this.metadata.splice(d,f),this.notifyDataChanged()}},c.prototype.clear=function(){this.getIsDeleted()||(this.xValues.clear(),this.yValues.clear(),this.zValues.clear(),this.metadata=[],this.notifyDataChanged())},c.prototype.delete=function(){this.xValues=(0,e.deleteSafe)(this.xValues),this.yValues=(0,e.deleteSafe)(this.yValues),this.zValues=(0,e.deleteSafe)(this.zValues),this.metadata=[],u.prototype.delete.call(this)},c.prototype.count=function(){return this.xValues?this.xValues.size():0},Object.defineProperty(c.prototype,"capacity",{get:function(){return this.xValues.capacity()},set:function(d){d>this.capacity&&this.reserve(d)},enumerable:!1,configurable:!0}),c.prototype.reserve=function(d){i.Guard.argumentIsRealInteger(d,"capacity"),this.xValues.reserve(d),this.yValues.reserve(d),this.zValues.reserve(d)},c.prototype.getOptions=function(d){var f=u.prototype.getOptions.call(this,d);if(d)return f;var h=(0,a.vectorToArray)(this.xValues,this.webAssemblyContext),p=(0,a.vectorToArray)(this.yValues,this.webAssemblyContext),g=(0,a.vectorToArray)(this.zValues,this.webAssemblyContext),v={xValues:h,yValues:p,zValues:g,metadata:this.metadata};return Object.assign(f,v)},c})(s.BaseDataSeries3D);return Wx.XyzDataSeries3D=l,Wx}var I0e;function G3(){if(I0e)return tb;I0e=1;var t=tb&&tb.__assign||function(){return t=Object.assign||function(z){for(var G,H=1,U=arguments.length;H<U;H++){G=arguments[H];for(var k in G)Object.prototype.hasOwnProperty.call(G,k)&&(z[k]=G[k])}return z},t.apply(this,arguments)};Object.defineProperty(tb,"__esModule",{value:!0}),tb.buildDataSeries3D=tb.buildDataSeries=void 0;var e=pBe(),i=yBe(),n=SBe(),r=_Be(),o=PBe(),a=CBe(),s=xBe(),l=ABe(),u=RBe(),c=gie(),d=zi(),f=MBe(),h=$3(),p=bie(),g=Sie(),v=vie(),y=kBe(),m=IBe(),b=NBe(),S=FBe(),_=W3(),C=yie(),P=Uf(),x=jBe(),E=VBe(),A=Mm(),R=Tv(),M=function(z,G,H,U){if(G){typeof G=="string"&&(G=JSON.parse(G,R.chartReviver)),typeof H=="string"&&(H=JSON.parse(H,R.chartReviver));var k,X;if(k=F(z,G,H),"filter"in G.options&&(X=G.options.filter),X&&G.type!==d.EDataSeriesType.HeatmapUniform&&G.type!==d.EDataSeriesType.HeatmapNonUniform&&k){var W=D(U??k,X);W&&(k=W)}return k}};tb.buildDataSeries=M;var D=function(z,G){if(G.type===A.EDataFilterType.HlcScaleOffset)return new i.HlcScaleOffsetFilter(z,G.options);if(G.type===A.EDataFilterType.OhlcScaleOffset)return new n.OhlcScaleOffsetFilter(z,G.options);if(G.type===A.EDataFilterType.XyLinearTrend)return new r.XyLinearTrendFilter(z,G.options);if(G.type===A.EDataFilterType.XyMovingAverage)return new o.XyMovingAverageFilter(z,G.options);if(G.type===A.EDataFilterType.XyRatio){var H=G.options;if(Array.isArray(H.divisorSeries)){var U=new Array(z.count()).fill(0);G.options.divisorSeries=new v.XyDataSeries(z.webAssemblyContext,{xValues:U,yValues:H.divisorSeries})}return new a.XyRatioFilter(z,G.options)}else return G.type===A.EDataFilterType.XyScaleOffset?new s.XyScaleOffsetFilter(z,G.options):G.type===A.EDataFilterType.XyyScaleOffset?new l.XyyScaleOffsetFilter(z,G.options):G.type===A.EDataFilterType.XyzScaleOffset?new u.XyzScaleOffsetFilter(z,G.options):void 0},F=function(z,G,H){var U=t({},G.options);switch(G.type){case d.EDataSeriesType.Xy:{var k=U;return k.arrayCount=1,H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId]),new v.XyDataSeries(z,k)}case d.EDataSeriesType.Xyy:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId],k.y1Values=H[k.y1DataId]),new _.XyyDataSeries(z,k)}case d.EDataSeriesType.Xyz:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId],k.zValues=H[k.zDataId]),new C.XyzDataSeries(z,k)}case d.EDataSeriesType.Xyxy:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId],k.x1Values=H[k.x1DataId],k.y1Values=H[k.y1DataId]),new S.XyxyDataSeries(z,k)}case d.EDataSeriesType.XyN:{var k=U;return H&&k.xDataId,new y.XyNDataSeries(z,k)}case d.EDataSeriesType.XyText:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId]),new m.XyTextDataSeries(z,k)}case d.EDataSeriesType.Hlc:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.highValues=H[k.highDataId],k.lowValues=H[k.lowDataId],k.yValues=H[k.closeDataId]),new c.HlcDataSeries(z,k)}case d.EDataSeriesType.Ohlc:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.openValues=H[k.openDataId],k.highValues=H[k.highDataId],k.lowValues=H[k.lowDataId],k.closeValues=H[k.closeDataId]),new h.OhlcDataSeries(z,k)}case d.EDataSeriesType.HeatmapUniform:{var k=U;return new p.UniformHeatmapDataSeries(z,k)}case d.EDataSeriesType.HeatmapNonUniform:{var k=U;return new f.NonUniformHeatmapDataSeries(z,k)}case d.EDataSeriesType.XyN:throw new Error("XyN data series is not supported yet!");case d.EDataSeriesType.Xyx:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId],k.x1Values=H[k.x1DataId]),new b.XyxDataSeries(z,k)}case d.EDataSeriesType.X:return new g.XDataSeries(z,U);case d.EDataSeriesType.BoxPlot:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.lowerQuartileValues=H[k.lowerDataId],k.upperQuartileValues=H[k.upperDataId],k.maximumValues=H[k.maxDataId],k.minimumValues=H[k.minDataId],k.yValues=H[k.medianDataId],k.medianValues=H[k.medianDataId]),new e.BoxPlotDataSeries(z,k)}default:{var X=function(W){throw new Error('Invalid Data Series Type value: "'.concat(W,'"!'))};return X(G.type)}}},I=function(z,G,H){if(G)return typeof G=="string"&&(G=JSON.parse(G,R.chartReviver)),typeof H=="string"&&(H=JSON.parse(H,R.chartReviver)),V(z,G,H)};tb.buildDataSeries3D=I;var V=function(z,G,H){var U=t({},G.options);switch(G.type){case P.EDataSeriesType3D.Xyz3D:{var k=U;return H&&k.xDataId&&(k.xValues=H[k.xDataId],k.yValues=H[k.yDataId],k.zValues=H[k.zDataId]),new E.XyzDataSeries3D(z,k)}case P.EDataSeriesType3D.UniformGrid3D:{var k=U;return new x.UniformGridDataSeries3D(z,k)}case P.EDataSeriesType3D.NonUniformGrid3D:throw new Error("NonUniformGrid3D data series is not supported yet!");default:{var X=function(W){throw new Error('Invalid Data Series Type value: "'.concat(W,'"!'))};return X(G.type)}}};return tb}var Gx={},N0e;function HBe(){if(N0e)return Gx;N0e=1;var t=Gx&&Gx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Gx,"__esModule",{value:!0}),Gx.FlippedIndexCoordinateCalculator=void 0;var e=di(),i=iC(),n=(function(r){t(o,r);function o(a,s,l,u,c,d,f,h,p){h===void 0&&(h=0),p===void 0&&(p=-1);var g=r.call(this,a,l,u,c,h,!1)||this,v=new a.IndexCalculatorParams;v.SetIndexCalculator(s),v.m_dViewportDimension=l,v.m_dVisibleMin=u,v.m_dVisibleMax=c,v.m_dViewportOffset=p,v.m_dCoordOffset=g.offset,v.m_dIndexMin=d,v.m_dIndexMax=f;var y=new a.FlippedIndexCoordinateCalculator(v);return v.delete(),g.nativeCalculator=y,g.indexCalculator=s,g.indexRange=new e.NumberRange(s.GetIndex(u),s.GetIndex(c)),g.dimensionOverMaxMinusMin=l/(g.indexRange.max-g.indexRange.min),g.minEdgeCoord=-g.indexRange.min*g.dimensionOverMaxMinusMin,g}return o.prototype.getCoordinate=function(a){var s=this.indexCalculator.GetIndex(a);return this.viewportDimension-(this.minEdgeCoord+s*this.dimensionOverMaxMinusMin)+this.offset},o.prototype.getDataValue=function(a){var s=(this.viewportDimension-a-this.offset-this.minEdgeCoord)/this.dimensionOverMaxMinusMin;return this.indexCalculator.GetValue(s)},o.prototype.translateBy=function(a,s){var l=this.getCoordinate(s.min)+a,u=this.getCoordinate(s.max)+a;return new e.NumberRange(this.getDataValue(l),this.getDataValue(u))},o.prototype.transformIndexToData=function(a){return this.indexCalculator.GetValue(a)},o.prototype.transformDataToIndex=function(a){return this.indexCalculator.GetIndex(a)},o.prototype.zoomTranslateBy=function(a,s,l){var u=this.transformDataToIndex(l.min),c=this.transformDataToIndex(l.max),d=c-u,f=d==0;return u-=a*(f?u:d),c+=s*(f?c:d),c>=u?new e.NumberRange(this.transformIndexToData(u),this.transformIndexToData(c)):new e.NumberRange(this.transformIndexToData(c),this.transformIndexToData(u))},o})(i.CoordinateCalculatorBase);return Gx.FlippedIndexCoordinateCalculator=n,Gx}var Yx={},F0e;function UBe(){if(F0e)return Yx;F0e=1;var t=Yx&&Yx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Yx,"__esModule",{value:!0}),Yx.IndexCoordinateCalculator=void 0;var e=di(),i=iC(),n=(function(r){t(o,r);function o(a,s,l,u,c,d,f,h,p){h===void 0&&(h=0),p===void 0&&(p=-1);var g=r.call(this,a,l,u,c,h,!0)||this,v=new a.IndexCalculatorParams;v.SetIndexCalculator(s),v.m_dViewportDimension=l,v.m_dVisibleMin=u,v.m_dVisibleMax=c,v.m_dViewportOffset=p,v.m_dCoordOffset=g.offset,v.m_dIndexMin=d,v.m_dIndexMax=f;var y=new a.IndexCoordinateCalculator(v);return v.delete(),g.nativeCalculator=y,g.indexCalculator=s,g.indexRange=new e.NumberRange(s.GetIndex(u),s.GetIndex(c)),g.dimensionOverMaxMinusMin=l/(g.indexRange.max-g.indexRange.min),g.minEdgeCoord=-g.indexRange.min*g.dimensionOverMaxMinusMin,g}return o.prototype.getCoordinate=function(a){var s=this.indexCalculator.GetIndex(a);return this.minEdgeCoord+s*this.dimensionOverMaxMinusMin+this.offset},o.prototype.getDataValue=function(a){var s=(a-this.offset-this.minEdgeCoord)/this.dimensionOverMaxMinusMin;return this.indexCalculator.GetValue(s)},o.prototype.translateBy=function(a,s){var l=this.getCoordinate(s.min)-a,u=this.getCoordinate(s.max)-a;return new e.NumberRange(this.getDataValue(l),this.getDataValue(u))},o.prototype.transformIndexToData=function(a){return this.indexCalculator.GetValue(a)},o.prototype.transformDataToIndex=function(a){return this.indexCalculator.GetIndex(a)},o.prototype.zoomTranslateBy=function(a,s,l){var u=this.transformDataToIndex(l.min),c=this.transformDataToIndex(l.max),d=c-u,f=d==0;return u-=a*(f?u:d),c+=s*(f?c:d),c>=u?new e.NumberRange(this.transformIndexToData(u),this.transformIndexToData(c)):new e.NumberRange(this.transformIndexToData(c),this.transformIndexToData(u))},o})(i.CoordinateCalculatorBase);return Yx.IndexCoordinateCalculator=n,Yx}var qx={},B0e;function zBe(){if(B0e)return qx;B0e=1;var t=qx&&qx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(qx,"__esModule",{value:!0}),qx.IndexTickProvider=void 0;var e=di(),i=oR(),n=wW(),r=(function(o){t(a,o);function a(s){var l=o.call(this)||this;return l.webAssemblyContext=s,l.numericTickProvider=new i.NumericTickProvider(s),l}return a.prototype.getMinorTicks=function(s,l,u,c){var d=this.parentAxis.dataGap;if(d===0)return this.numericTickProvider.getMinorTicks(s,l,u);var f=c,h=this.numericTickProvider.getMinorTicks(s/d,l/d,this.getIndexRange(f,u));return h.map(function(p){return f.transformIndexToData(p)})},a.prototype.getMajorTicks=function(s,l,u,c){var d=this.parentAxis.dataGap;if(d===0)return this.numericTickProvider.getMajorTicks(s,l,u);var f=c,h=this.numericTickProvider.getMajorTicks(s/d,l/d,this.getIndexRange(f,u));return h.map(function(p){return f.transformIndexToData(p)})},a.prototype.getIndexRange=function(s,l){var u=s.transformDataToIndex(l.min),c=s.transformDataToIndex(l.max);return new e.NumberRange(u,c)},a})(n.TickProvider);return qx.IndexTickProvider=r,qx}var j0e;function NW(){if(j0e)return Ax;j0e=1;var t=Ax&&Ax.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(Ax,"__esModule",{value:!0}),Ax.BaseValueAxis=void 0;var e=G3(),i=Br(),n=ud(),r=ZL(),o=hn(),a=Sie(),s=HBe(),l=UBe(),u=zBe(),c=Vv(),d=aR(),f=Rm(),h=(function(p){t(g,p);function g(v,y){var m=this,b,S;if(m=p.call(this,v,y)||this,m.type=n.EAxisType.BaseValueAxis,m.baseValuesDataSeries=void 0,m.lastBaseValuesDataSeries=void 0,m.lastBaseValuesDataSeriesChangeCount=0,m.baseValuesDataSeriesFromArray=void 0,m.labelProvider=(b=y==null?void 0:y.labelProvider)!==null&&b!==void 0?b:new f.NumericLabelProvider(y),m.tickProvider=new u.IndexTickProvider(m.webAssemblyContext2D),m.deltaCalculator=new d.NumericDeltaCalculator(v),m.indexCalculator=new v.IndexCalculator,m.emptyVector=new v.SCRTDoubleVector,m.dataGap=(S=y==null?void 0:y.dataGap)!==null&&S!==void 0?S:0,y!=null&&y.baseValues){if("options"in y.baseValues){var _=(0,e.buildDataSeries)(v,y.baseValues);m.baseValuesDataSeries=_}if("changeCount"in y.baseValues)m.baseValuesDataSeries=y.baseValues;else if((0,r.isNumberArray)(y.baseValues))m.setBaseValuesFromArray(y.baseValues);else throw new Error("Invalid baseXValues type. Expected IDataSeries or NumberArray")}return m}return Object.defineProperty(g.prototype,"isLinearAxis",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"dataGap",{get:function(){return this.indexCalculator.dataPointWidth},set:function(v){this.indexCalculator.dataPointWidth!==v&&(this.indexCalculator.dataPointWidth=v,this.notifyPropertyChanged("dataGap"))},enumerable:!1,configurable:!0}),g.prototype.getMajorTickIndex=function(v){if(this.autoTicks&&this.dataGap>0){var y=this.getCurrentCoordinateCalculator(),m=y.transformDataToIndex(v),b=this.majorDelta/this.dataGap,S=m/b;return Math.round(S)}else return p.prototype.getMajorTickIndex.call(this,v)},g.prototype.prepareRenderData=function(){this.updateIndexCalculatorBaseValues(),p.prototype.prepareRenderData.call(this)},g.prototype.getCurrentCoordinateCalculatorInternal=function(){var v=this.visibleRange.min,y=this.visibleRange.max,m=this.indexCalculator.GetIndex(v),b=this.indexCalculator.GetIndex(y),S=this.offset,_=this.axisLength,C=this.isXAxis!==this.flippedCoordinates?new l.IndexCoordinateCalculator(this.webAssemblyContext2D,this.indexCalculator,_,v,y,m,b,S):new s.FlippedIndexCoordinateCalculator(this.webAssemblyContext2D,this.indexCalculator,_,v,y,m,b,S);return this.updateIndexCalculatorBaseValues(),C},g.prototype.delete=function(){this.indexCalculator=(0,i.deleteSafe)(this.indexCalculator),this.baseValuesDataSeriesFromArray=(0,i.deleteSafe)(this.baseValuesDataSeriesFromArray),this.emptyVector=(0,i.deleteSafe)(this.emptyVector),p.prototype.delete.call(this)},g.prototype.getBaseValues=function(){var v=this,y;if(this.baseValuesDataSeries&&!this.baseValuesDataSeries.getIsDeleted())y=this.baseValuesDataSeries;else{var m=this.parentSurface,b=m.renderableSeries.asArray().find(function(C){return C.xAxisId===v.id});if(b){if((b==null?void 0:b.type)===o.ESeriesType.UniformHeatmapSeries)throw Error("Index Axis is not supported for UniformHeatmapRenderableSeries use NonUniformHeatmapSeries instead");if((b==null?void 0:b.type)===o.ESeriesType.NonUniformHeatmapSeries)throw Error("In order to use NonUniformHeatmapSeries with BaseValueAxis please set base X values using xBaseValueAxis.setBaseXValuesFromArray() method");if(b!=null&&b.isCollection){var S=b;if(S.size()===0)throw Error("BaseStackedCollection should have at least one BaseStackedRenderableSeries");var _=S.get(0);_.dataSeries&&!_.dataSeries.getIsDeleted()&&(y=_.dataSeries)}else b.dataSeries&&!b.dataSeries.getIsDeleted()&&(y=b.dataSeries)}}return y},g.prototype.setBaseValues=function(v){this.baseValuesDataSeries=v,this.notifyPropertyChanged("baseValues")},g.prototype.setBaseValuesFromArray=function(v){(0,i.deleteSafe)(this.baseValuesDataSeriesFromArray),this.baseValuesDataSeriesFromArray=new a.XDataSeries(this.webAssemblyContext2D,{xValues:v}),this.setBaseValues(this.baseValuesDataSeriesFromArray)},g.prototype.updateIndexCalculatorBaseValues=function(){var v=this.getBaseValues();v&&!v.getIsDeleted()?(v!==this.lastBaseValuesDataSeries||v.changeCount!==this.lastBaseValuesDataSeriesChangeCount)&&(this.updateIndexCalculatorBaseValuesInternal(v.getNativeXValues()),this.lastBaseValuesDataSeries=v,this.lastBaseValuesDataSeriesChangeCount=v.changeCount):this.updateIndexCalculatorBaseValuesInternal(this.emptyVector)},g.prototype.updateIndexCalculatorBaseValuesInternal=function(v){this.indexCalculator.UpdateVec(v,!1)},g.prototype.toJSON=function(){var v,y=p.prototype.toJSON.call(this),m=(v=this.baseValuesDataSeries)===null||v===void 0?void 0:v.toJSON(!1),b={baseValues:m,dataGap:this.dataGap};return Object.assign(y.options,b),y},g})(c.AxisBase2D);return Ax.BaseValueAxis=h,Ax}var Xx={},V0e;function $Be(){if(V0e)return Xx;V0e=1;var t=Xx&&Xx.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Xx,"__esModule",{value:!0}),Xx.IndexDeltaCalculator=void 0;var e=eie(),i=OW(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this)||this;return l.baseDeltaCalculator=new e.DateTimeDeltaCalculator(a,s),l}return o.prototype.getDeltaFromRange=function(a,s,l,u){var c=this.parentAxis.dataGap,d=this.parentAxis.getCurrentCoordinateCalculator();if(c>0){var f=d.transformDataToIndex(a),h=d.transformDataToIndex(s),p=a+c*(h-f);return this.baseDeltaCalculator.getDeltaFromRange(a,p,l,u)}else return this.baseDeltaCalculator.getDeltaFromRange(a,s,l,u)},o})(i.DeltaCalculator);return Xx.IndexDeltaCalculator=n,Xx}var H0e;function _ie(){if(H0e)return wx;H0e=1;var t=wx&&wx.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(wx,"__esModule",{value:!0}),wx.DiscontinuousDateAxis=void 0;var e=ud(),i=NW(),n=$Be(),r=lS(),o=(function(a){t(s,a);function s(l,u){var c=this;return u!=null&&u.labelProvider||(u=u??{},u.labelProvider=new r.SmartDateLabelProvider(u)),c=a.call(this,l,u)||this,c.type=e.EAxisType.DiscontinuousDateAxis,c.possibleDeltasOption=u==null?void 0:u.possibleDeltas,c.minTicksOption=u==null?void 0:u.minTicks,c.deltaCalculator=new n.IndexDeltaCalculator(l,{possibleDeltas:u==null?void 0:u.possibleDeltas,minTicks:u==null?void 0:u.minTicks,datePrecision:u==null?void 0:u.datePrecision}),c}return s.prototype.setBaseXValues=function(l){a.prototype.setBaseValues.call(this,l)},s.prototype.toJSON=function(){var l=a.prototype.toJSON.call(this),u={possibleDeltas:this.possibleDeltasOption,minTicks:this.minTicksOption};return Object.assign(l.options,u),l},s.prototype.updateIndexCalculatorBaseValuesInternal=function(l){this.indexCalculator.UpdateVec(l,this.dataGap===0)},s})(i.BaseValueAxis);return wx.DiscontinuousDateAxis=o,wx}var U0e;function e$(){if(U0e)return H1;U0e=1,Object.defineProperty(H1,"__esModule",{value:!0}),H1.buildAxis3D=H1.buildAxes=void 0;var t=RW(),e=iBe(),i=DW(),n=tie(),r=Rm(),o=IW(),a=lS(),s=U3(),l=z3(),u=BI(),c=hBe(),d=hie(),f=pie(),h=ud(),p=ga(),g=sR(),v=Tv(),y=mo(),m=_ie(),b=NW();(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.Numeric,function(P){return new r.NumericLabelProvider(P)},!0),(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.Date,function(P){return new i.DateLabelProvider(P)},!0),(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.Logarithmic,function(P){return new n.LogarithmicLabelProvider(P)},!0),(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.SmartDate,function(P){return new a.SmartDateLabelProvider(P)},!0),(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.Text,function(P){return new s.TextLabelProvider(P)},!0),(0,y.registerType)(p.EBaseType.LabelProvider,g.ELabelProviderType.Pie,function(P){return new o.PieLabelProvider(P)},!0);var S=function(P,x){typeof x=="string"&&(x=JSON.parse(x,v.chartReviver));var E=[];if(Array.isArray(x))for(var A=0,R=x;A<R.length;A++){var M=R[A];E.push(_(P,M))}else E.push(_(P,x));return E};H1.buildAxes=S;var _=function(P,x){var E;switch(x.type){case h.EAxisType.CategoryAxis:E=new t.CategoryAxis(P,x.options);break;case h.EAxisType.BaseValueAxis:E=new b.BaseValueAxis(P,x.options);break;case h.EAxisType.DiscontinuousDateAxis:E=new m.DiscontinuousDateAxis(P,x.options);break;case h.EAxisType.NumericAxis:E=new u.NumericAxis(P,x.options);break;case h.EAxisType.LogarithmicAxis:E=new l.LogarithmicAxis(P,x.options);break;case h.EAxisType.DateTimeNumericAxis:E=new e.DateTimeNumericAxis(P,x.options);break;case h.EAxisType.PolarNumericAxis:E=new d.PolarNumericAxis(P,x.options);break;case h.EAxisType.PolarCategoryAxis:E=new c.PolarCategoryAxis(P,x.options);break;default:E=new u.NumericAxis(P,{});break}return E},C=function(P,x){var E;switch(x.type){case h.EAxisType.NumericAxis3D:E=new f.NumericAxis3D(P,x.options);break;default:E=new f.NumericAxis3D(P,{});break}return E};return H1.buildAxis3D=C,H1}var Kx={},UF={},U9={},z0e;function Ho(){return z0e||(z0e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EChart3DModifierType=t.EChart2DModifierType=void 0,(function(e){e.Cursor="Cursor",e.PolarCursor="PolarCursor",e.DataPointSelection="DataPointSelection",e.PolarDataPointSelection="PolarDataPointSelection",e.Legend="Legend",e.PolarLegend="PolarLegend",e.MouseWheelZoom="MouseWheelZoom",e.PolarMouseWheelZoom="PolarMouseWheelZoom",e.PinchZoom="PinchZoom",e.Rollover="Rollover",e.VerticalSlice="VerticalSlice",e.RubberBandXYZoom="RubberBandXYZoom",e.PolarArcZoom="PolarArcZoom",e.SeriesSelection="SeriesSelection",e.PolarSeriesSelection="PolarSeriesSelection",e.XAxisDrag="XAxisDrag",e.YAxisDrag="YAxisDrag",e.ZoomExtents="ZoomExtents",e.PolarZoomExtents="PolarZoomExtents",e.ZoomPan="ZoomPan",e.PolarPan="PolarPan",e.OverviewRangeSelection="OverviewRangeSelection",e.AnnotationHover="AnnotationHover",e.Custom="Custom"})(t.EChart2DModifierType||(t.EChart2DModifierType={})),(function(e){e.MouseWheelZoom="MouseWheelZoom",e.Orbit="Orbit",e.ZoomExtents="ZoomExtents",e.Tooltip="Tooltip",e.PinchZoom="PinchZoom",e.Legend="Legend",e.Custom="Custom"})(t.EChart3DModifierType||(t.EChart3DModifierType={}))})(U9)),U9}var z9={},$0e;function GS(){return $0e||($0e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EMousePosition=void 0,(function(e){e.OutOfCanvas="OutOfCanvas",e.AxisArea="AxisArea",e.SeriesArea="SeriesArea"})(t.EMousePosition||(t.EMousePosition={}))})(z9)),z9}var Zx={},W0e;function Pie(){if(W0e)return Zx;W0e=1;var t=Zx&&Zx.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(Zx,"__esModule",{value:!0}),Zx.CursorTooltipSvgAnnotation=void 0;var e=GS(),i=vs(),n=gl(),r=jl(),o=Qa(),a=Dm(),s=(function(l){t(u,l);function u(c){var d=this,f,h,p,g,v,y,m,b,S;if(d=l.call(this,c)||this,d.type=o.EAnnotationType.SVG,d.surfaceTypes=[i.ESurfaceType.SciChartSurfaceType,i.ESurfaceType.SciChartPolarSurfaceType],d.showTooltipProperty=!1,d.seriesInfosProperty=[],d.isHidden=!0,d.titleProperty=(f=c==null?void 0:c.title)!==null&&f!==void 0?f:d.titleProperty,d.tooltipSvgTemplateProperty=(h=c==null?void 0:c.tooltipSvgTemplate)!==null&&h!==void 0?h:d.tooltipSvgTemplateProperty,d.tooltipLegendTemplateProperty=(p=c==null?void 0:c.tooltipLegendTemplate)!==null&&p!==void 0?p:d.tooltipLegendTemplateProperty,d.seriesInfosProperty=(g=c==null?void 0:c.seriesInfos)!==null&&g!==void 0?g:d.seriesInfosProperty,d.containerBackgroundProperty=(v=c==null?void 0:c.containerBackground)!==null&&v!==void 0?v:d.containerBackgroundProperty,d.textStrokeProperty=(y=c==null?void 0:c.textStroke)!==null&&y!==void 0?y:d.textStrokeProperty,d.tooltipLegendOffsetXProperty=(m=c==null?void 0:c.tooltipLegendOffsetX)!==null&&m!==void 0?m:d.tooltipLegendOffsetXProperty,d.tooltipLegendOffsetYProperty=(b=c==null?void 0:c.tooltipLegendOffsetY)!==null&&b!==void 0?b:d.tooltipLegendOffsetYProperty,d.cursorModifier=c.cursorModifier,d.placementDivId=(S=c==null?void 0:c.placementDivId)!==null&&S!==void 0?S:d.placementDivId,d.placementDivId){var _=document.querySelector("[id='".concat(d.placementDivId,"']"));d.svgDivRoot=_}return d}return Object.defineProperty(u.prototype,"seriesInfos",{get:function(){return this.seriesInfosProperty},set:function(c){if(c){var d=this.tooltipSvgTemplate(c,this);d!==this.svgString&&(this.svgString=d,this.notifyPropertyChanged(r.PROPERTY.SERIES_INFOS)),this.seriesInfosProperty=c}},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"title",{get:function(){return this.titleProperty},set:function(c){this.titleProperty!==c&&(this.titleProperty=c,this.notifyPropertyChanged(r.PROPERTY.TITLE))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipSvgTemplate",{get:function(){return this.tooltipSvgTemplateProperty},set:function(c){this.tooltipSvgTemplateProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_SVG_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendTemplate",{get:function(){return this.tooltipLegendTemplateProperty},set:function(c){this.tooltipLegendTemplateProperty=c,this.svgString=void 0,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"containerBackground",{get:function(){return this.containerBackgroundProperty},set:function(c){this.containerBackgroundProperty!==c&&(this.containerBackgroundProperty=c,this.notifyPropertyChanged(r.PROPERTY.CONTAINER_BACKGROUND))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendOffsetX",{get:function(){return this.tooltipLegendOffsetXProperty},set:function(c){this.tooltipLegendOffsetXProperty!==c&&(this.tooltipLegendOffsetXProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_OFFSET_X))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendOffsetY",{get:function(){return this.tooltipLegendOffsetYProperty},set:function(c){this.tooltipLegendOffsetYProperty!==c&&(this.tooltipLegendOffsetYProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_OFFSET_Y))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"textStroke",{get:function(){return this.textStrokeProperty},set:function(c){this.textStrokeProperty!==c&&(this.textStrokeProperty=c,this.notifyPropertyChanged(r.PROPERTY.TEXT_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"showTooltip",{get:function(){return this.showTooltipProperty},set:function(c){this.showTooltipProperty!==c&&(this.showTooltipProperty=c,this.notifyPropertyChanged(r.PROPERTY.SHOW_LABEL))},enumerable:!1,configurable:!0}),u.prototype.update=function(c,d,f,h){var p=this.cursorModifier.getMousePosition();this.previousMousePosition===p&&p!==e.EMousePosition.SeriesArea||(this.previousMousePosition=this.cursorModifier.getMousePosition(),this.svg&&this.clear(),this.create(c,d,f,h),this.placementDivId?this.updateExternalLegendTooltip():(this.updateTooltip(f,h),this.updateLegendTooltip(f,h)))},u.prototype.clear=function(){!this.parentSurface||this.parentSurface.isDeleted||!this.svg||(this.placementDivId?this.svgDivRoot.removeChild(this.svg):this.svgRoot.removeChild(this.svg),this.setSvg(void 0),this.svgLegend&&(this.svgRoot.removeChild(this.svgLegend),this.svgLegend=void 0))},u.prototype.create=function(c,d,f,h){var p;if(!this.tooltipSvgTemplate)throw Error("Please provide a tooltipSvgTemplate for CursorTooltipSvgAnnotation");var g=(p=this.svgString)!==null&&p!==void 0?p:this.tooltipSvgTemplate(this.seriesInfos,this),v=this.applyClipping(g,this.clipping);if(this.placementDivId){var y=n.annotationHelpers.createSvg(v,this.svgDivRoot);this.setSvg(y)}else{var y=n.annotationHelpers.createSvg(v,this.svgRoot,this.nextSibling);this.setSvg(y)}},u.prototype.updateTooltip=function(c,d){var f,h,p,g,v=(f=this.xCoordShift)!==null&&f!==void 0?f:0,y=(h=this.yCoordShift)!==null&&h!==void 0?h:0;this.svg.style.display=this.showTooltip?"block":"none";var m=(p=this.x1)!==null&&p!==void 0?p:0,b=(g=this.y1)!==null&&g!==void 0?g:0,S=v+m+c,_=y+b+d;isNaN(S)||isNaN(_)?this.svg.style.display="none":(this.setSvgAttribute("x",S),this.setSvgAttribute("y",_))},u.prototype.updateLegendTooltip=function(c,d){if(this.tooltipLegendTemplate){var f=this.seriesInfos?this.tooltipLegendTemplate(this.seriesInfos,this):"<svg></svg>";this.svgLegend&&this.svgRoot.removeChild(this.svgLegend);var h=this.applyClipping(f,this.clipping),p=n.annotationHelpers.createSvg(h,this.svgRoot);this.svgLegend=p,this.svgLegend.setAttribute("x",(this.tooltipLegendOffsetX+c).toString()),this.svgLegend.setAttribute("y",(this.tooltipLegendOffsetY+d).toString())}},u.prototype.updateExternalLegendTooltip=function(){if(this.tooltipLegendTemplate){var c=this.seriesInfos?this.tooltipLegendTemplate(this.seriesInfos,this):"<svg style='display: none'></svg>";this.svgLegend&&this.svgLegend.removeChild(this.svgLegend);var d=this.applyClipping(c,this.clipping),f=n.annotationHelpers.createSvg(d,this.svgRoot);this.svgLegend=f}},u})(a.SvgAnnotationBase);return Zx.CursorTooltipSvgAnnotation=s,Zx}var sv={},Jx={},$9={},G0e;function uR(){return G0e||(G0e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EModifierMouseArgKey=void 0,(function(e){e.Shift="Shift",e.Ctrl="Ctrl",e.Alt="Alt",e.None="None"})(t.EModifierMouseArgKey||(t.EModifierMouseArgKey={}))})($9)),$9}var W9={},Y0e;function Lm(){return Y0e||(Y0e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EExecuteOn=void 0,(function(e){e[e.MouseLeftButton=0]="MouseLeftButton",e[e.MouseMiddleButton=1]="MouseMiddleButton",e[e.MouseRightButton=2]="MouseRightButton",e[e.BrowserBackButton=3]="BrowserBackButton",e[e.BrowserForwardButton=4]="BrowserForwardButton"})(t.EExecuteOn||(t.EExecuteOn={}))})(W9)),W9}var G9={},q0e;function km(){return q0e||(q0e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.ALLOWS_MULTI_SELECTION="ALLOWS_MULTI_SELECTION",e.ALLOW_TOOLTIP_OVERLAPPING="ALLOW_TOOLTIP_OVERLAPPING",e.CROSSHAIR_STROKE="CROSSHAIR_STROKE",e.EXECUTE_CONDITION="EXECUTE_CONDITION",e.FILL="FILL",e.HIT_TEST_RADIUS="HIT_TEST_RADIUS",e.IS_ATTACHED="IS_ATTACHED",e.IS_ENABLED="IS_ENABLED",e.PARENT_SURFACE="PARENT_SURFACE",e.RECEIVE_HANDLED_EVENTS="RECEIVE_HANDLED_EVENTS",e.SHOW_ROLLOVER_LINE="SHOW_ROLLOVER_LINE",e.SHOW_TOOLTIP="SHOW_TOOLTIP",e.SECONDARY_EXECUTE_CONDITION="SECONDARY_EXECUTE_CONDITION",e.SELECTED_AREA="SELECTED_AREA",e.SELECTION_FILL="SELECTION_FILL",e.SELECTION_STROKE="SELECTION_STROKE",e.SELECTION_STROKE_THICKNESS="SELECTION_STROKE_THICKNESS",e.STROKE="STROKE",e.STROKE_THICKNESS="STROKE_THICKNESS",e.STROKE_DASH_ARRAY="STROKE_DASH_ARRAY",e.TOOLTIP_DATA_TEMPLATE="TOOLTIP_DATA_TEMPLATE",e.X_AXIS_ID="X_AXIS_ID",e.Y_AXIS_ID="Y_AXIS_ID",e.PLACEMENT_DIV_ID="PLACEMENT_DIV_ID",e.X_LINE="X_LINE",e.Y_LINE="Y_LINE",e.AXIS_LABELS="AXIS_LABELS",e.ANGULAR_AXIS_LABELS_PLACEMENT="ANGULAR_AXIS_LABELS_PLACEMENT",e.RADIAL_AXIS_LABELS_PLACEMENT="RADIAL_AXIS_LABELS_PLACEMENT",e.X1="X1",e.X_COORDINATE_MODE="X_COORDINATE_MODE",e.IS_DRAGGABLE="IS_DRAGGABLE",e.LINE_ANNOTATIONS_OPTIONS="LINE_ANNOTATIONS_OPTIONS",e.LINE_SELECTION_COLOR="LINE_SELECTION_COLOR",e.TOOLTIP_SHADOW="TOOLTIP_SHADOW",e.IS_SVG_ONLY="IS_SVG_ONLY"})(t.PROPERTY||(t.PROPERTY={}))})(G9)),G9}var X0e;function Cie(){if(X0e)return Jx;X0e=1;var t=Jx&&Jx.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(Jx,"__esModule",{value:!0}),Jx.ChartModifierBase=void 0;var e=fo(),i=uR(),n=Lm(),r=$f(),o=vs(),a=hl(),s=km(),l=(function(u){t(c,u);function c(d){var f=this,h,p;return f=u.call(this)||this,f.isEnabledProperty=!0,f.executeConditionProperty={button:n.EExecuteOn.MouseLeftButton},f.activePointerEvents=new Map,f.id=(h=d==null?void 0:d.id)!==null&&h!==void 0?h:(0,a.generateGuid)(),f.executeConditionProperty=(p=d==null?void 0:d.executeCondition)!==null&&p!==void 0?p:f.executeConditionProperty,f.secondaryExecuteConditionProperty=d==null?void 0:d.secondaryExecuteCondition,f}return c.prototype.applyTheme=function(d){},Object.defineProperty(c.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"isEnabled",{get:function(){return this.isEnabledProperty},set:function(d){this.isEnabledProperty=d,this.notifyPropertyChanged(s.PROPERTY.IS_ENABLED)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"isAttached",{get:function(){return this.isAttachedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"receiveHandledEvents",{get:function(){return this.receiveHandledEventsProperty},set:function(d){this.receiveHandledEventsProperty=d,this.notifyPropertyChanged(s.PROPERTY.RECEIVE_HANDLED_EVENTS)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"executeCondition",{get:function(){return this.executeConditionProperty},set:function(d){this.executeConditionProperty=d,this.notifyPropertyChanged(s.PROPERTY.EXECUTE_CONDITION)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"secondaryExecuteCondition",{get:function(){return this.secondaryExecuteConditionProperty},set:function(d){this.secondaryExecuteConditionProperty=d,this.notifyPropertyChanged(s.PROPERTY.SECONDARY_EXECUTE_CONDITION)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"canReceiveMouseEvents",{get:function(){return this.isEnabled&&this.isAttached&&this.parentSurfaceProperty!==void 0},enumerable:!1,configurable:!0}),c.prototype.onAttach=function(){},c.prototype.onDetach=function(){},c.prototype.onAttachSeries=function(d){},c.prototype.onDetachSeries=function(d){},c.prototype.onAttachSubSurface=function(d){},c.prototype.onDetachSubSurface=function(d){},c.prototype.onParentSurfaceRendered=function(){},c.prototype.onParentSurfaceLayoutComplete=function(){},c.prototype.modifierMouseDown=function(d){var f;((f=this.executeCondition)===null||f===void 0?void 0:f.button)===n.EExecuteOn.MouseMiddleButton&&d.nativeEvent.preventDefault();var h=d.pointerType==="touch"||d.pointerType==="pen";h&&this.activePointerEvents.set(d.pointerId,d)},c.prototype.modifierMouseMove=function(d){this.updatePointerInfo(d)},c.prototype.modifierMouseUp=function(d){var f=d.pointerType==="touch"||d.pointerType==="pen";f&&this.activePointerEvents.delete(d.pointerId)},c.prototype.modifierMouseWheel=function(d){},c.prototype.modifierDoubleClick=function(d){},c.prototype.modifierMouseEnter=function(d){},c.prototype.modifierMouseLeave=function(d){this.activePointerEvents.delete(d.pointerId)},c.prototype.modifierDrop=function(d){},c.prototype.modifierPointerCancel=function(d){this.activePointerEvents.delete(d.pointerId)},c.prototype.setParentSurface=function(d){if(!d)this.parentSurfaceProperty=void 0;else{if(d.surfaceType===o.ESurfaceType.SciChartSurfaceType&&this.modifierType!==r.EModifierType.Chart2DModifier)throw d.hasInvalidState=!0,new Error("Only 2D Chart Modifiers can be attached to a 2D SciChartSurface. Please check ".concat(this.constructor.name,".modifierType property to match SciChartSurface.surfaceType"));if(d.surfaceType===o.ESurfaceType.SciChartPolarSurfaceType&&this.modifierType!==r.EModifierType.Chart2DPolarModifier)throw d.hasInvalidState=!0,new Error("Only 2D Polar Chart Modifiers can be attached to a 2D SciChartPolarSurface. Please check ".concat(this.constructor.name,".modifierType property to match SciChartSurface.surfaceType"));if(d.surfaceType===o.ESurfaceType.SciChart3DSurfaceType&&this.modifierType!==r.EModifierType.Chart3DModifier)throw d.hasInvalidState=!0,new Error("Only 3D Chart Modifiers can be attached to a 3D SciChartSurface. Please check ".concat(this.constructor.name,".modifierType property to match SciChartSurface.surfaceType"));this.parentSurfaceProperty=d}this.isAttachedProperty=this.parentSurfaceProperty!==void 0,this.notifyPropertyChanged(s.PROPERTY.PARENT_SURFACE)},c.prototype.checkExecuteCondition=function(d,f){if(f){if(f.button!==void 0&&f.button!==d.button)return!1;if(f.key!==void 0){if(f.key===i.EModifierMouseArgKey.Ctrl){if(!d.ctrlKey)return!1}else if(f.key===i.EModifierMouseArgKey.Alt){if(!d.altKey)return!1}else if(f.key===i.EModifierMouseArgKey.Shift){if(!d.shiftKey)return!1}else if(f.key===i.EModifierMouseArgKey.None&&(d.ctrlKey||d.altKey||d.shiftKey))return!1}return!0}},c.prototype.checkExecuteConditions=function(d){var f=this.checkExecuteCondition(d,this.executeCondition),h=this.checkExecuteCondition(d,this.secondaryExecuteCondition);return{isPrimary:f,isSecondary:h}},c.prototype.delete=function(){},c.prototype.notifyPropertyChanged=function(d){this.invalidateParentCallback&&this.invalidateParentCallback()},c.prototype.updatePointerInfo=function(d){var f;(this.activePointerEvents.size===0||this.activePointerEvents.keys().next().value===d.pointerId)&&(this.mousePoint=d.mousePoint),this.previousPoint=(f=this.activePointerEvents.get(d.pointerId))===null||f===void 0?void 0:f.mousePoint,this.activePointerEvents.has(d.pointerId)&&this.activePointerEvents.set(d.pointerId,d)},c.prototype.getIsActionAllowed=function(d){return!0},c})(e.DeletableEntity);return Jx.ChartModifierBase=l,Jx}var zF={},K0e;function Tie(){if(K0e)return zF;K0e=1,Object.defineProperty(zF,"__esModule",{value:!0}),zF.IncludedItems=void 0;var t=(function(){function e(){this.itemIdsSet=new Set,this.isInclusionSet=!1}return e.prototype.include=function(i){var n=this.itemIdsSet.size===0;return n&&(this.isInclusionSet=!0),this.isInclusionSet?this.itemIdsSet.has(i)?!1:(this.itemIdsSet.add(i),!0):this.itemIdsSet.has(i)?(this.itemIdsSet.delete(i),!0):!1},e.prototype.includeList=function(i){var n=this,r=!1;return i.forEach(function(o){n.include(o)===!0&&(r=!0)}),r},e.prototype.exclude=function(i){var n=this.itemIdsSet.size===0;if(n&&(this.isInclusionSet=!1),this.isInclusionSet)if(this.itemIdsSet.has(i))this.itemIdsSet.delete(i);else return!1;else return this.itemIdsSet.has(i)?!1:(this.itemIdsSet.add(i),!0);return!0},e.prototype.excludeList=function(i){var n=this,r=!1;return i.forEach(function(o){n.exclude(o)===!0&&(r=!0)}),r},e.prototype.testIsIncluded=function(i){return this.isInclusionSet?this.itemIdsSet.has(i):!this.itemIdsSet.has(i)},e.prototype.getIncludedItems=function(i){var n=this;return this.isInclusionSet?i.filter(function(r){return n.itemIdsSet.has(r.id)}):i.filter(function(r){return!n.itemIdsSet.has(r.id)})},e.prototype.getIncludedItemIds=function(){return this.isInclusionSet?Array.from(this.itemIdsSet):[]},e.prototype.getExcludedItemIds=function(){return this.isInclusionSet?[]:Array.from(this.itemIdsSet)},e.prototype.includeAll=function(){this.itemIdsSet.clear(),this.isInclusionSet=!1},e.prototype.excludeAll=function(){this.itemIdsSet.clear(),this.isInclusionSet=!0},e.prototype.reconcile=function(i){var n=this,r=new Set;i.forEach(function(a){return r.add(a.id)});var o=[];this.itemIdsSet.forEach(function(a){r.has(a)||o.push(a)}),o.forEach(function(a){return n.itemIdsSet.delete(a)})},e.prototype.getItemIdsSetSize=function(){return this.itemIdsSet.size},e.prototype.removeId=function(i){this.itemIdsSet.has(i)&&this.itemIdsSet.delete(i)},e})();return zF.IncludedItems=t,zF}var Z0e;function Qu(){if(Z0e)return sv;Z0e=1;var t=sv&&sv.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(sv,"__esModule",{value:!0}),sv.getActiveAxes=sv.testIsOverAxes=sv.ChartModifierBase2D=void 0;var e=$f(),i=pl(),n=Eo(),r=Cie(),o=km(),a=Tie(),s=fW(),l=(function(d){t(f,d);function f(h){var p=this,g,v,y,m,b,S,_,C,P,x,E,A,R,M,D,F;if(p=d.call(this,h)||this,p.xyDirection=i.EXyDirection.XyDirection,p.includedSeries=new a.IncludedItems,p.includedXAxes=new a.IncludedItems,p.includedYAxes=new a.IncludedItems,p.changedPropertiesList=[],p.typeMap=new Map,p.xyDirection=(g=h==null?void 0:h.xyDirection)!==null&&g!==void 0?g:p.xyDirection,p.modifierGroup=(v=h==null?void 0:h.modifierGroup)!==null&&v!==void 0?v:p.modifierGroup,p.xAxisIdProperty=(y=h==null?void 0:h.xAxisId)!==null&&y!==void 0?y:p.xAxisIdProperty,p.yAxisIdProperty=(m=h==null?void 0:h.yAxisId)!==null&&m!==void 0?m:p.yAxisIdProperty,((b=h==null?void 0:h.includedSeriesIds)===null||b===void 0?void 0:b.length)>0&&((S=h==null?void 0:h.excludedSeriesIds)===null||S===void 0?void 0:S.length)>0)throw new Error("You should either use `includedSeriesIds` or `excludedSeriesIds`, not both.");if(((_=h==null?void 0:h.includedXAxisIds)===null||_===void 0?void 0:_.length)>0&&((C=h==null?void 0:h.excludedXAxisIds)===null||C===void 0?void 0:C.length)>0)throw new Error("You should either use `includedXAxisIds` or `excludedXAxisIds`, not both.");if(((P=h==null?void 0:h.includedYAxisIds)===null||P===void 0?void 0:P.length)>0&&((x=h==null?void 0:h.excludedYAxisIds)===null||x===void 0?void 0:x.length)>0)throw new Error("You should either use `includedYAxisIds` or `excludedYAxisIds`, not both.");return((E=h==null?void 0:h.includedSeriesIds)===null||E===void 0?void 0:E.length)>0&&p.includedSeries.includeList(h.includedSeriesIds),((A=h==null?void 0:h.excludedSeriesIds)===null||A===void 0?void 0:A.length)>0&&p.includedSeries.excludeList(h.excludedSeriesIds),((R=h==null?void 0:h.includedXAxisIds)===null||R===void 0?void 0:R.length)>0&&p.includedXAxes.includeList(h.includedXAxisIds),((M=h==null?void 0:h.excludedXAxisIds)===null||M===void 0?void 0:M.length)>0&&p.includedXAxes.excludeList(h.excludedXAxisIds),((D=h==null?void 0:h.includedYAxisIds)===null||D===void 0?void 0:D.length)>0&&p.includedYAxes.includeList(h.includedYAxisIds),((F=h==null?void 0:h.excludedYAxisIds)===null||F===void 0?void 0:F.length)>0&&p.includedYAxes.excludeList(h.excludedYAxisIds),p}return Object.defineProperty(f.prototype,"modifierType",{get:function(){return e.EModifierType.Chart2DModifier},enumerable:!1,configurable:!0}),f.prototype.onAttach=function(){d.prototype.onAttach.call(this),this.linkAxes()},Object.defineProperty(f.prototype,"xAxisId",{get:function(){return this.xAxisIdProperty},set:function(h){h!==this.xAxisIdProperty&&(this.xAxisIdProperty=h,this.xAxisProperty=void 0,this.notifyPropertyChanged(o.PROPERTY.X_AXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"yAxisId",{get:function(){return this.yAxisIdProperty},set:function(h){h!==this.yAxisIdProperty&&(this.yAxisIdProperty=h,this.yAxisProperty=void 0,this.notifyPropertyChanged(o.PROPERTY.Y_AXIS_ID))},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"xAxis",{get:function(){return this.xAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"yAxis",{get:function(){return this.yAxisProperty},enumerable:!1,configurable:!0}),f.prototype.getAllSeries=function(){return this.parentSurface.renderableSeries.asArray()},f.prototype.getIncludedXAxis=function(){return this.includedXAxes.getIncludedItems(this.parentSurface.xAxes.asArray())},f.prototype.getIncludedYAxis=function(){return this.includedYAxes.getIncludedItems(this.parentSurface.yAxes.asArray())},f.prototype.includeXAxis=function(h,p){p?this.includedXAxes.include(h.id):this.includedXAxes.exclude(h.id)},f.prototype.includeYAxis=function(h,p){p?this.includedYAxes.include(h.id):this.includedYAxes.exclude(h.id)},f.prototype.includeAllAxes=function(){this.includedXAxes.includeAll(),this.includedYAxes.includeAll()},f.prototype.testIsIncludedSeries=function(h){return h.isVisible&&this.includedSeries.testIsIncluded(h.id)},f.prototype.includeSeries=function(h,p){if(p){var g=this.includedSeries.include(h.id);return g&&this.isAttached&&this.onAttachSeries(h),g}else{var g=this.includedSeries.exclude(h.id);return g&&this.isAttached&&this.onDetachSeries(h),g}},f.prototype.getIncludedRenderableSeries=function(){var h=this,p=this.getAllSeries().filter(function(y){return!y.isCollection&&h.testIsIncludedSeries(y)}),g=this.getAllSeries().filter(function(y){return y.isCollection}),v=p;return g.forEach(function(y){y.getVisibleSeries().forEach(function(m){h.testIsIncludedSeries(m)&&v.push(m)})}),v},f.prototype.toJSON=function(){var h={id:this.id,modifierGroup:this.modifierGroup,executeCondition:this.executeCondition,secondaryExecuteCondition:this.secondaryExecuteCondition,xyDirection:this.xyDirection,xAxisId:this.xAxisId,yAxisId:this.yAxisId,includedXAxisIds:this.includedXAxes.getIncludedItemIds(),excludedXAxisIds:this.includedXAxes.getExcludedItemIds(),includedYAxisIds:this.includedYAxes.getIncludedItemIds(),excludedYAxisIds:this.includedYAxes.getExcludedItemIds(),includedSeriesIds:this.includedSeries.getIncludedItemIds(),excludedSeriesIds:this.includedSeries.getExcludedItemIds()};return{type:this.type,options:h}},f.prototype.linkAxes=function(){if((0,s.updateAxisIds)(this),!!this.parentSurface){if(!this.xAxisProperty&&this.xAxisId){var h=this.parentSurface.getXAxisById(this.xAxisId);h?this.xAxisProperty=h:(console.warn('ChartModifier looked for xAxis Id "'.concat(this.xAxisId,'" but did not find. Default xAxis will be used')),this.xAxisProperty=this.parentSurface.getDefaultXAxis())}if(!this.yAxisProperty&&this.yAxisId){var p=this.parentSurface.getYAxisById(this.yAxisId);p?this.yAxisProperty=p:(console.warn('ChartModifier looked for yAxis Id "'.concat(this.yAxisId,'" but did not find. Default yAxis will be used')),this.yAxisProperty=this.parentSurface.getDefaultYAxis())}}},f.prototype.testPropertyChanged=function(h){return this.changedPropertiesList.includes(h)},f.prototype.notifyPropertyChanged=function(h){this.changedPropertiesList.includes(h)||this.changedPropertiesList.push(h),d.prototype.notifyPropertyChanged.call(this,h)},f.prototype.growBy=function(h,p,g){var v=p.isHorizontalAxis,y=p.isAxisFlipped,m=p.viewRect,b=p.flippedCoordinates,S=this.parentSurface.seriesViewRect,_=v?m.width:m.height;p.isStackedAxis&&this.parentSurface&&(_=v?S.width:S.height);var C=v?h.x:h.y,P=C/_*g,x=(1-C/_)*g,E=y&&!b||!y&&b;E?p.zoomBy(x,P):p.zoomBy(P,x)},f})(r.ChartModifierBase);sv.ChartModifierBase2D=l;var u=function(d,f){var h=!1;return d.forEach(function(p){if(p.viewRect){var g=p.viewRect,v=g.left,y=g.right,m=g.top,b=g.bottom;(0,n.testIsInBounds)(f.x,f.y,v,b,y,m)&&(h=!0)}}),h};sv.testIsOverAxes=u;var c=function(d,f){var h=[];return d.forEach(function(p){if(p.viewRect){var g=p.viewRect,v=g.left,y=g.right,m=g.top,b=g.bottom;(0,n.testIsInBounds)(f.x,f.y,v,b,y,m)&&h.push(p)}}),h};return sv.getActiveAxes=c,sv}var bb={},J0e;function FW(){if(J0e)return bb;J0e=1;var t=bb&&bb.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})(),e=bb&&bb.__spreadArray||function(y,m,b){if(b||arguments.length===2)for(var S=0,_=m.length,C;S<_;S++)(C||!(S in m))&&(C||(C=Array.prototype.slice.call(m,0,S)),C[S]=m[S]);return y.concat(C||Array.prototype.slice.call(m))};Object.defineProperty(bb,"__esModule",{value:!0}),bb.SvgLineAnnotation=void 0;var i=Gy(),n=vs(),r=pl(),o=_v(),a=od(),s=Zi(),l=Ca(),u=jl(),c=Qa(),d=Dm(),f=pa(),h=Vf(),p=gl(),g=Eo(),v=(function(y){t(m,y);function m(b){var S=this,_,C,P,x,E,A,R,M,D,F,I,V;return S=y.call(this,b)||this,S.type=c.EAnnotationType.SvgLineAnnotation,S.surfaceTypes=[n.ESurfaceType.SciChartSurfaceType,n.ESurfaceType.SciChartPolarSurfaceType],S.strokeProperty="#FFFFFF",S.strokeThicknessProperty=1,S.strokeDashArrayProperty=[],S.showLabelProperty=!1,S.axisLabelStrokeProperty="#ffffff",S.axisLabelFillProperty="#b36200",S.labelPlacementProperty=i.ELabelPlacement.Top,S.labelValueProperty="",S.labelPaddingProperty=new f.Thickness(2,4,2,4),S.labelCornerRadiusProperty=2,S.labelCache=new Map,S.axisFontSizeProperty=13,S.axisFontFamilyProperty="Arial",S.stroke=(_=b==null?void 0:b.stroke)!==null&&_!==void 0?_:S.strokeProperty,S.strokeThickness=(C=b==null?void 0:b.strokeThickness)!==null&&C!==void 0?C:S.strokeThicknessProperty,S.strokeDashArray=(P=b==null?void 0:b.strokeDashArray)!==null&&P!==void 0?P:S.strokeDashArrayProperty,S.showLabelProperty=(x=b==null?void 0:b.showLabel)!==null&&x!==void 0?x:S.showLabelProperty,S.axisLabelStrokeProperty=(E=b==null?void 0:b.axisLabelStroke)!==null&&E!==void 0?E:S.axisLabelStrokeProperty,S.axisLabelFillProperty=(A=b==null?void 0:b.axisLabelFill)!==null&&A!==void 0?A:S.axisLabelFillProperty,S.axisFontSizeProperty=(R=b==null?void 0:b.axisFontSize)!==null&&R!==void 0?R:S.axisFontSizeProperty,S.axisFontFamilyProperty=(M=b==null?void 0:b.axisFontFamily)!==null&&M!==void 0?M:S.axisFontFamilyProperty,S.labelPlacementProperty=(D=b==null?void 0:b.labelPlacement)!==null&&D!==void 0?D:S.labelPlacementProperty,S.labelValueProperty=(F=b==null?void 0:b.labelValue)!==null&&F!==void 0?F:S.labelValueProperty,S.labelPaddingProperty=(I=b==null?void 0:b.labelPadding)!==null&&I!==void 0?I:S.labelPaddingProperty,S.labelCornerRadiusProperty=(V=b==null?void 0:b.labelCornerRadius)!==null&&V!==void 0?V:S.labelCornerRadiusProperty,S.resizeDirections=r.EXyDirection.XyDirection,S}return Object.defineProperty(m.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(b){this.strokeProperty=b,this.notifyPropertyChanged(u.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(b){this.strokeThicknessProperty=b,this.notifyPropertyChanged(u.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(b){this.strokeDashArrayProperty=b,this.notifyPropertyChanged(u.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"showLabel",{get:function(){return this.showLabelProperty},set:function(b){this.showLabelProperty=b,this.notifyPropertyChanged(u.PROPERTY.SHOW_LABEL)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"axisLabelStroke",{get:function(){return this.axisLabelStrokeProperty},set:function(b){this.axisLabelStrokeProperty=b,this.notifyPropertyChanged(u.PROPERTY.AXIS_LABELS_STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"axisLabelFill",{get:function(){return this.axisLabelFillProperty},set:function(b){this.axisLabelFillProperty=b,this.notifyPropertyChanged(u.PROPERTY.AXIS_LABELS_FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"axisFontSize",{get:function(){return this.axisFontSizeProperty},set:function(b){this.axisFontSizeProperty=b,this.notifyPropertyChanged(u.PROPERTY.AXIS_FONT_SIZE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"axisFontFamily",{get:function(){return this.axisFontFamilyProperty},set:function(b){this.axisFontFamilyProperty=b,this.notifyPropertyChanged(u.PROPERTY.AXIS_FONT_FAMILY)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"labelPlacement",{get:function(){return this.labelPlacementProperty},set:function(b){this.labelPlacementProperty=b,this.notifyPropertyChanged(u.PROPERTY.LABEL_PLACEMENT)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"labelValue",{get:function(){return this.labelValueProperty},set:function(b){this.labelValueProperty=b,this.notifyPropertyChanged(u.PROPERTY.LABEL_VALUE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"labelPadding",{get:function(){return this.labelPaddingProperty},set:function(b){this.labelPaddingProperty=b,this.notifyPropertyChanged(u.PROPERTY.LABEL_PADDING)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"labelCornerRadius",{get:function(){return this.labelCornerRadiusProperty},set:function(b){this.labelCornerRadiusProperty=b,this.notifyPropertyChanged(u.PROPERTY.LABEL_CORNER_RADIUS)},enumerable:!1,configurable:!0}),m.prototype.create=function(b,S,_,C){this.clear();var P=p.annotationHelpers.createSvgLineAndLabel(this.showLabel),x=P.svgElement,E=P.svgLine,A=P.svgLabelsContainer;this.lineEl=E,this.updateLineStyle(),A&&(this.labelsContainer=A),this.setSvg(x),this.svgRoot&&this.svg&&(this.nextSibling?this.svgRoot.insertBefore(this.svg,this.nextSibling):this.svgRoot.appendChild(this.svg)),this.update(b,S,_,C)},m.prototype.update=function(b,S,_,C){var P=this;if(!this.svg||!this.lineEl){this.create(b,S,_,C);return}this.xCoordSvgTransProperty=_,this.yCoordSvgTransProperty=C;var x=this.convertPolarToCartesian(this.getX1Coordinate(b,S),this.getY1Coordinate(b,S),!0),E=x.x,A=x.y,R=this.convertPolarToCartesian(this.getX2Coordinate(b,S),this.getY2Coordinate(b,S),!0),M=R.x,D=R.y,F=Math.floor(E),I=Math.floor(A),V=Math.floor(M),z=Math.floor(D),G=this.parentSurface.xAxes.asArray().filter(function(Pe){return Pe.isVisible}),H=this.parentSurface.yAxes.asArray().filter(function(Pe){return Pe.isVisible}),U=e(e([],G.filter(function(Pe){return!Pe.isVerticalChart}),!0),H.filter(function(Pe){return Pe.isVerticalChart}),!0),k=e(e([],H.filter(function(Pe){return!Pe.isVerticalChart}),!0),G.filter(function(Pe){return Pe.isVerticalChart}),!0);if(this.showLabel&&this.labelsContainer&&!this.parentSurface.isPolar){this.labelCache.forEach(function(Pe){return Pe.inUse=!1});var X,W=[];F===V&&I===0?(X=E,W=U):I===z&&F===0&&(X=A,W=k),W.forEach(function(Pe){var we=X*s.DpiHelper.PIXEL_RATIO;Pe.drawLabels&&(!Pe.isStackedAxis||Pe.offset<we&&Pe.offset+Pe.getAxisSize()>we)&&P.drawSvgAxisLabel(Pe,we)}),this.labelCache.forEach(function(Pe){Pe.inUse||(Pe.group.remove(),P.labelCache.delete(Pe.axisId))}),this.labelsContainer.style.display="block"}else this.labelsContainer&&(this.labelsContainer.style.display="none");if(F===V&&I===0&&(z-=C,this.showLabel&&U.length>0)){var Y=U.find(function(Pe){return Pe.axisAlignment===a.EAxisAlignment.Top}),te=Y?Y.axisRenderer.getAxisReservedSpace(!0):0,oe=U.find(function(Pe){return Pe.axisAlignment===a.EAxisAlignment.Bottom}),de=oe?oe.axisRenderer.getAxisReservedSpace(!0):0;I-=te,z+=de}if(I===z&&F===0&&(V-=_,this.showLabel&&k.length>0)){var ge=k.find(function(Pe){return Pe.axisAlignment===a.EAxisAlignment.Left}),Ee=ge?ge.axisRenderer.getAxisReservedSpace(!0):0,Re=k.find(function(Pe){return Pe.axisAlignment===a.EAxisAlignment.Right}),Ae=Re?Re.axisRenderer.getAxisReservedSpace(!0):0;F-=Ee,V+=Ae}F+=_,I+=C,V+=_,z+=C,this.lineEl.setAttribute("x1",F.toString()),this.lineEl.setAttribute("y1",I.toString()),this.lineEl.setAttribute("x2",V.toString()),this.lineEl.setAttribute("y2",z.toString()),this.svg.style.visibility=this.isHidden?"hidden":"visible",this.svg.style.opacity=this.opacity.toString(),this.setAnnotationBorders(F,I,V,z),this.updateAdornerInner()},m.prototype.drawSvgAxisLabel=function(b,S){var _,C,P,x;if(this.labelsContainer){var E=this.labelValue||(0,o.getLabelValue)(b,S);if(E){var A=this.labelCache.get(b.id);if(!A){var R="http://www.w3.org/2000/svg",M=document.createElementNS(R,"g"),D=document.createElementNS(R,"rect"),F=document.createElementNS(R,"text");M.appendChild(D),M.appendChild(F),this.labelsContainer.appendChild(M),A={group:M,rect:D,text:F,axisId:b.id,inUse:!0},this.labelCache.set(b.id,A)}A.inUse=!0,A.group.style.display="block";var I=this.axisLabelFill,V=this.axisLabelStroke,z=(0,h.getFontFamily)((C=(_=b.labelStyle)===null||_===void 0?void 0:_.fontFamily)!==null&&C!==void 0?C:this.axisFontFamily,!1),G=(x=(P=b.labelStyle)===null||P===void 0?void 0:P.fontSize)!==null&&x!==void 0?x:this.axisFontSize;A.text.setAttribute("font-family",z),A.text.setAttribute("font-size",G.toString()),A.text.setAttribute("fill",V),A.text.setAttribute("text-anchor","middle"),A.text.setAttribute("dominant-baseline","central"),A.text.textContent=E,A.rect.setAttribute("fill",I),A.rect.setAttribute("stroke","none"),A.rect.setAttribute("rx",this.labelCornerRadiusProperty.toString());var H=A.text.getBBox(),U=s.DpiHelper.PIXEL_RATIO,k=new f.Thickness(this.labelPaddingProperty.top/U,this.labelPaddingProperty.right/U,this.labelPaddingProperty.bottom/U,this.labelPaddingProperty.left/U),X=H.width+k.left+k.right,W=H.height+k.top+k.bottom,Y=b.viewRect,te=b.offset,oe=0,de=0,ge=function(ve,pe,fe){var me=fe*U;return ve+pe-me/2},Ee=Y.y/U,Re=Y.height/U,Ae=Y.x/U,Pe=Y.width/U,we=b.axisRenderer.getAxisReservedSpace(!0);switch(b.axisAlignment){case a.EAxisAlignment.Top:oe=ge(Y.x-te,S,X)/U,b.isInnerAxis?de=Ee:de=Ee+Re-W,de-=we;break;case a.EAxisAlignment.Bottom:oe=ge(Y.x-te,S,X)/U,b.isInnerAxis?de=Ee+Re-W:de=Ee,de+=we;break;case a.EAxisAlignment.Left:de=ge(Y.y-te,S,W)/U,b.isInnerAxis?oe=Ae:oe=Ae+Pe-X,oe-=we;break;case a.EAxisAlignment.Right:de=ge(Y.y-te,S,W)/U,b.isInnerAxis?oe=Ae+Pe-X:oe=Ae,oe+=we;break}var Te=Math.round(oe),ke=Math.round(de);A.rect.setAttribute("x",Te.toString()),A.rect.setAttribute("y",ke.toString()),A.rect.setAttribute("width",X.toString()),A.rect.setAttribute("height",W.toString());var $e=Te+X/2,Ne=ke+W/2;A.text.setAttribute("x",$e.toString()),A.text.setAttribute("y",Ne.toString())}}},m.prototype.getAnnotationBorders=function(){var b=this.xAxis.getCurrentCoordinateCalculator(),S=this.yAxis.getCurrentCoordinateCalculator(),_=this.convertPolarToCartesian(this.getX1Coordinate(b,S),this.getY1Coordinate(b,S),!0),C=_.x,P=_.y,x=this.convertPolarToCartesian(this.getX2Coordinate(b,S),this.getY2Coordinate(b,S),!0),E=x.x,A=x.y;return{x1:C+this.xCoordSvgTransProperty,x2:E+this.xCoordSvgTransProperty,y1:P+this.yCoordSvgTransProperty,y2:A+this.yCoordSvgTransProperty}},m.prototype.getAdornerAnnotationBorders=function(b,S){var _=this.getAnnotationBorders(),C=_.x1,P=_.x2,x=_.y1,E=_.y2;if(S){var A=this.strokeThickness/2,R=this.strokeThickness/2;C-=A,P+=A,x-=R,E+=R}return{x1:C,x2:P,y1:x,y2:E}},m.prototype.svgStringAdornerTemplate=function(b,S,_,C){var P=this.selectionBoxStroke;return`<svg xmlns="http://www.w3.org/2000/svg">
    <line x1="`.concat(b,'" y1="').concat(S,'" x2="').concat(_,'" y2="').concat(C,'" stroke="').concat(P,`" stroke-width="6" />
    `).concat(this.canDragPoint(l.EDraggingGripPoint.x1y1)?this.getAnnotationGripSvg(b,S):"",`
    `).concat(this.canDragPoint(l.EDraggingGripPoint.x2y2)?this.getAnnotationGripSvg(_,C):"",`
    </svg>`)},m.prototype.onDragStarted=function(b){y.prototype.onDragStarted.call(this,b);var S=this.getAnnotationBorders(),_=S.x1,C=S.x2,P=S.y1,x=S.y2,E=b.mousePoint.x/s.DpiHelper.PIXEL_RATIO,A=b.mousePoint.y/s.DpiHelper.PIXEL_RATIO;if(this.canDragPoint(l.EDraggingGripPoint.x1y1)){var R=(0,g.calcDistance)(_,P,E,A);if(R<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x1y1,!0}if(this.canDragPoint(l.EDraggingGripPoint.x2y2)){var R=(0,g.calcDistance)(C,x,E,A);if(R<this.annotationsGripsRadius*s.DpiHelper.PIXEL_RATIO)return this.adornerDraggingPoint=l.EDraggingGripPoint.x2y2,!0}return this.canDragPoint(l.EDraggingGripPoint.Body)&&this.clickToSelect(b)?(this.adornerDraggingPoint=l.EDraggingGripPoint.Body,!0):!1},m.prototype.calcDragDistance=function(b){if(!this.prevValue){this.prevValue=b;return}this.adornerDraggingPoint===l.EDraggingGripPoint.Body?(this.x1=this.x1+this.applyPixelRatioToDragDist(b.x-this.prevValue.x),this.x2=this.x2+this.applyPixelRatioToDragDist(b.x-this.prevValue.x),this.y1=this.y1+(b.y-this.prevValue.y),this.y2=this.y2+(b.y-this.prevValue.y)):this.adornerDraggingPoint===l.EDraggingGripPoint.x1y1?this.resizeDirections===r.EXyDirection.XDirection?this.x1+=this.applyPixelRatioToDragDist(b.x-this.prevValue.x):this.resizeDirections===r.EXyDirection.YDirection?this.y1+=b.y-this.prevValue.y:(this.x1+=this.applyPixelRatioToDragDist(b.x-this.prevValue.x),this.y1+=b.y-this.prevValue.y):this.adornerDraggingPoint===l.EDraggingGripPoint.x2y2&&(this.resizeDirections===r.EXyDirection.XDirection?this.x2+=this.applyPixelRatioToDragDist(b.x-this.prevValue.x):this.resizeDirections===r.EXyDirection.YDirection?this.y2+=b.y-this.prevValue.y:(this.x2+=this.applyPixelRatioToDragDist(b.x-this.prevValue.x),this.y2+=b.y-this.prevValue.y)),this.prevValue=b},m.prototype.checkIsClickedOnAnnotationInternal=function(b,S){var _=this.getAnnotationBorders(),C=_.x1,P=_.x2,x=_.y1,E=_.y2,A=b/s.DpiHelper.PIXEL_RATIO+this.xCoordSvgTransProperty,R=S/s.DpiHelper.PIXEL_RATIO+this.yCoordSvgTransProperty,M=(0,g.calcDistanceFromLineSegment)(A,R,C,x,P,E);return M<=m.DISTANCE_TO_LINE},m.prototype.notifyPropertyChanged=function(b){y.prototype.notifyPropertyChanged.call(this,b);var S=[u.PROPERTY.STROKE,u.PROPERTY.STROKE_THICKNESS,u.PROPERTY.STROKE_DASH_ARRAY,u.PROPERTY.OPACITY],_=[u.PROPERTY.AXIS_LABELS_FILL,u.PROPERTY.AXIS_LABELS_STROKE,u.PROPERTY.SHOW_LABEL];S.includes(b)&&this.updateLineStyle(),_.includes(b)&&(this.labelsContainer&&(this.labelsContainer.innerHTML=""),this.labelCache.clear())},m.prototype.updateLineStyle=function(){this.lineEl&&(this.lineEl.setAttribute("stroke",this.stroke),this.lineEl.setAttribute("stroke-width",this.strokeThickness.toString()),this.lineEl.setAttribute("stroke-opacity",this.opacity.toString()),this.lineEl.setAttribute("shape-rendering","crispEdges"),this.strokeDashArray&&this.strokeDashArray.length>0?this.lineEl.setAttribute("stroke-dasharray",this.strokeDashArray.join(" ")):this.lineEl.removeAttribute("stroke-dasharray"))},m.prototype.toJSON=function(){var b=y.prototype.toJSON.call(this),S={axisFontFamily:this.axisFontFamily,axisFontSize:this.axisFontSize,axisLabelFill:this.axisLabelFill,axisLabelStroke:this.axisLabelStroke,labelPlacement:this.labelPlacement,labelValue:this.labelValue,showLabel:this.showLabel,stroke:this.stroke,strokeDashArray:this.strokeDashArray,strokeThickness:this.strokeThickness,labelPadding:this.labelPadding,labelCornerRadius:this.labelCornerRadius};return Object.assign(b.options,S),b},m.DISTANCE_TO_LINE=10,m})(d.SvgAnnotationBase);return bb.SvgLineAnnotation=v,bb}var Q0e;function YO(){return Q0e||(Q0e=1,(function(t){var e=UF&&UF.__extends||(function(){var C=function(P,x){return C=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(E,A){E.__proto__=A}||function(E,A){for(var R in A)Object.prototype.hasOwnProperty.call(A,R)&&(E[R]=A[R])},C(P,x)};return function(P,x){if(typeof x!="function"&&x!==null)throw new TypeError("Class extends value "+String(x)+" is not a constructor or null");C(P,x);function E(){this.constructor=P}P.prototype=x===null?Object.create(x):(E.prototype=x.prototype,new E)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.adjustTooltipPosition=t.calcTooltipSize=t.defaultCursorTooltipSvgTemplate=t.CursorModifier=void 0;var i=mo(),n=Br(),r=ga(),o=Ho(),a=GS(),s=Ti(),l=An(),u=Ca(),c=II(),d=Pie(),f=rC(),h=Sn(),p=Qu(),g=km(),v=FW(),y=(function(C){e(P,C);function P(x){var E=this,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e;return E=C.call(this,x)||this,E.type=o.EChart2DModifierType.Cursor,E.tooltipSvgTemplate=t.defaultCursorTooltipSvgTemplate,E.crosshairStrokeThickness=2,E.crosshairStrokeDashArray=[],E.tooltipContainerBackground="#228B22",E.tooltipTextStroke="#fff",E.showTooltip=!1,E.axisLabelStroke="#fff",E.axisLabelFill="#228B22",E.xAxisLabelStroke=void 0,E.xAxisLabelFill=void 0,E.yAxisLabelStroke=void 0,E.yAxisLabelFill=void 0,E.tooltipLegendOffsetX=0,E.tooltipLegendOffsetY=0,E.axisLabelPadding=void 0,E.axisLabelCornerRadius=2,E.hitTestRadius=0,E.showOnOthersInGroup={xLine:!0,yLine:!0,tooltip:!0},E.mousePosition=a.EMousePosition.OutOfCanvas,E.crosshairStrokeProperty=h.SciChartSurfaceBase.DEFAULT_THEME.cursorLineBrush,E.tooltipShadowProperty=h.SciChartSurfaceBase.DEFAULT_THEME.shadowEffectColor,E.showXLineProperty=!0,E.showYLineProperty=!0,E.showAxisLabelsProperty=!0,E.isSvgOnlyProperty=!0,x!=null&&x.tooltipSvgTemplate&&typeof x.tooltipSvgTemplate=="string"&&(E.typeMap.set("tooltipSvgTemplate",x.tooltipSvgTemplate),x.tooltipSvgTemplate=(0,i.getFunction)(r.EBaseType.OptionFunction,x.tooltipSvgTemplate)),E.tooltipSvgTemplate=(A=x==null?void 0:x.tooltipSvgTemplate)!==null&&A!==void 0?A:E.tooltipSvgTemplate,E.crosshairStrokeThickness=(R=x==null?void 0:x.crosshairStrokeThickness)!==null&&R!==void 0?R:E.crosshairStrokeThickness,E.crosshairStrokeDashArray=(M=x==null?void 0:x.crosshairStrokeDashArray)!==null&&M!==void 0?M:E.crosshairStrokeDashArray,E.crosshairStroke=(D=x==null?void 0:x.crosshairStroke)!==null&&D!==void 0?D:E.crosshairStroke,E.tooltipContainerBackground=(F=x==null?void 0:x.tooltipContainerBackground)!==null&&F!==void 0?F:E.tooltipContainerBackground,E.tooltipTextStroke=(I=x==null?void 0:x.tooltipTextStroke)!==null&&I!==void 0?I:E.tooltipTextStroke,E.tooltipShadow=(V=x==null?void 0:x.tooltipShadow)!==null&&V!==void 0?V:E.tooltipShadowProperty,E.showTooltip=(z=x==null?void 0:x.showTooltip)!==null&&z!==void 0?z:E.showTooltip,E.showAxisLabels=(G=x==null?void 0:x.showAxisLabels)!==null&&G!==void 0?G:E.showAxisLabels,E.axisLabelFill=(H=x==null?void 0:x.axisLabelFill)!==null&&H!==void 0?H:E.axisLabelFill,E.axisLabelStroke=(U=x==null?void 0:x.axisLabelStroke)!==null&&U!==void 0?U:E.axisLabelStroke,E.xAxisLabelStroke=(k=x==null?void 0:x.xAxisLabelStroke)!==null&&k!==void 0?k:E.xAxisLabelStroke,E.xAxisLabelFill=(X=x==null?void 0:x.xAxisLabelFill)!==null&&X!==void 0?X:E.xAxisLabelFill,E.yAxisLabelStroke=(W=x==null?void 0:x.yAxisLabelStroke)!==null&&W!==void 0?W:E.yAxisLabelStroke,E.yAxisLabelFill=(Y=x==null?void 0:x.yAxisLabelFill)!==null&&Y!==void 0?Y:E.yAxisLabelFill,E.axisLabelPadding=(te=x==null?void 0:x.axisLabelPadding)!==null&&te!==void 0?te:E.axisLabelPadding,E.axisLabelCornerRadius=(oe=x==null?void 0:x.axisLabelCornerRadius)!==null&&oe!==void 0?oe:E.axisLabelCornerRadius,E.isSvgOnlyProperty=(de=x==null?void 0:x.isSvgOnly)!==null&&de!==void 0?de:E.isSvgOnlyProperty,E.placementDivIdProperty=(ge=x==null?void 0:x.placementDivId)!==null&&ge!==void 0?ge:E.placementDivIdProperty,E.showOnOthersInGroup=(Ee=x==null?void 0:x.showOnOthersInGroup)!==null&&Ee!==void 0?Ee:E.showOnOthersInGroup,x!=null&&x.tooltipLegendTemplate&&typeof x.tooltipLegendTemplate=="string"&&(E.typeMap.set("tooltipLegendTemplate",x.tooltipLegendTemplate),x.tooltipLegendTemplate=(0,i.getFunction)(r.EBaseType.OptionFunction,x.tooltipLegendTemplate)),E.tooltipLegendTemplate=(Re=x==null?void 0:x.tooltipLegendTemplate)!==null&&Re!==void 0?Re:E.tooltipLegendTemplate,E.tooltipLegendOffsetX=(Ae=x==null?void 0:x.tooltipLegendOffsetX)!==null&&Ae!==void 0?Ae:E.tooltipLegendOffsetX,E.tooltipLegendOffsetY=(Pe=x==null?void 0:x.tooltipLegendOffsetY)!==null&&Pe!==void 0?Pe:E.tooltipLegendOffsetY,x!=null&&x.tooltipDataTemplate&&typeof x.tooltipDataTemplate=="string"&&(E.typeMap.set("tooltipDataTemplate",x.tooltipDataTemplate),x.tooltipDataTemplate=(0,i.getFunction)(r.EBaseType.OptionFunction,x.tooltipDataTemplate)),E.tooltipDataTemplateProperty=(we=x==null?void 0:x.tooltipDataTemplate)!==null&&we!==void 0?we:E.tooltipDataTemplateProperty,E.showXLine=(Te=x==null?void 0:x.showXLine)!==null&&Te!==void 0?Te:E.showXLine,E.showYLine=(ke=x==null?void 0:x.showYLine)!==null&&ke!==void 0?ke:E.showYLine,E.hitTestRadius=($e=x==null?void 0:x.hitTestRadius)!==null&&$e!==void 0?$e:E.hitTestRadius,E}return P.prototype.applyTheme=function(x){this.testPropertyChanged(g.PROPERTY.CROSSHAIR_STROKE)||(this.crosshairStroke=x.cursorLineBrush),this.testPropertyChanged(g.PROPERTY.TOOLTIP_SHADOW)||(this.tooltipShadow=x.shadowEffectColor)},P.prototype.onAttach=function(){var x;C.prototype.onAttach.call(this);var E=this.xAxisLabelFill?this.xAxisLabelFill:this.axisLabelFill,A=this.yAxisLabelFill?this.yAxisLabelFill:this.axisLabelFill,R=this.xAxisLabelStroke?this.xAxisLabelStroke:this.axisLabelStroke,M=this.yAxisLabelStroke?this.yAxisLabelStroke:this.axisLabelStroke;this.showXLine&&(this.xLineAnnotation=this.newLineAnnotation(E,R),this.parentSurface.modifierAnnotations.add(this.xLineAnnotation)),this.showYLine&&(this.yLineAnnotation=this.newLineAnnotation(A,M),this.parentSurface.modifierAnnotations.add(this.yLineAnnotation)),this.tooltipAnnotation=new d.CursorTooltipSvgAnnotation({cursorModifier:this,xCoordinateMode:u.ECoordinateMode.Pixel,yCoordinateMode:u.ECoordinateMode.Pixel,tooltipSvgTemplate:(x=this.tooltipSvgTemplate)!==null&&x!==void 0?x:t.defaultCursorTooltipSvgTemplate,containerBackground:this.tooltipContainerBackground,textStroke:this.tooltipTextStroke,tooltipLegendTemplate:this.tooltipLegendTemplate,tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,xAxisId:this.xAxisId,yAxisId:this.yAxisId,placementDivId:this.placementDivId,clipping:c.EAnnotationClippingMode.Chart}),this.parentSurface.modifierAnnotations.add(this.tooltipAnnotation)},P.prototype.onDetach=function(){C.prototype.onDetach.call(this),this.xLineAnnotation&&this.parentSurface.modifierAnnotations.remove(this.xLineAnnotation,!0),this.yLineAnnotation&&this.parentSurface.modifierAnnotations.remove(this.yLineAnnotation,!0),this.parentSurface.modifierAnnotations.remove(this.tooltipAnnotation,!0)},P.prototype.onAttachSeries=function(x){this.tooltipAnnotation.seriesInfos=this.getSeriesInfos()},P.prototype.onDetachSeries=function(x){this.tooltipAnnotation.seriesInfos=this.getSeriesInfos()},P.prototype.modifierMouseMove=function(x){if(!(this.parentSurface.isSubSurface&&!x.isActiveSubChartEvent)){this.isMasterEvent=x.isMaster,this.activePointerEvents.set(x.pointerId,x),C.prototype.modifierMouseMove.call(this,x);var E;this.mousePoint?(E=(0,l.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect),E?this.mousePosition=a.EMousePosition.SeriesArea:this.mousePosition=a.EMousePosition.AxisArea):this.mousePosition=a.EMousePosition.OutOfCanvas;var A=this.getIsActionAllowed(x);A&&this.update()}},P.prototype.modifierMouseLeave=function(x){C.prototype.modifierMouseLeave.call(this,x),this.mousePosition=a.EMousePosition.OutOfCanvas,this.update()},P.prototype.onParentSurfaceRendered=function(){},P.prototype.onParentSurfaceLayoutComplete=function(){this.update()},Object.defineProperty(P.prototype,"crosshairStroke",{get:function(){return this.crosshairStrokeProperty},set:function(x){this.crosshairStrokeProperty!==x&&(this.crosshairStrokeProperty=x,this.notifyPropertyChanged(g.PROPERTY.CROSSHAIR_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"tooltipShadow",{get:function(){return this.tooltipShadowProperty},set:function(x){this.tooltipShadowProperty!==x&&(this.tooltipShadowProperty=x,this.notifyPropertyChanged(g.PROPERTY.TOOLTIP_SHADOW))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"showXLine",{get:function(){return this.showXLineProperty},set:function(x){if(this.showXLineProperty!==x){if(this.showXLineProperty=x,this.showXLineProperty&&!this.xLineAnnotation){var E=this.xAxisLabelFill?this.xAxisLabelFill:this.axisLabelFill,A=this.xAxisLabelStroke?this.xAxisLabelStroke:this.axisLabelStroke;this.xLineAnnotation=this.newLineAnnotation(E,A),this.parentSurface.modifierAnnotations.add(this.xLineAnnotation)}else!this.showXLineProperty&&this.xLineAnnotation&&(this.parentSurface.modifierAnnotations.remove(this.xLineAnnotation,!1),this.xLineAnnotation=(0,n.deleteSafe)(this.xLineAnnotation));this.notifyPropertyChanged(g.PROPERTY.X_LINE)}},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"showYLine",{get:function(){return this.showYLineProperty},set:function(x){if(this.showYLineProperty!==x){if(this.showYLineProperty=x,this.showYLineProperty&&!this.yLineAnnotation){var E=this.yAxisLabelFill?this.yAxisLabelFill:this.axisLabelFill,A=this.yAxisLabelStroke?this.yAxisLabelStroke:this.axisLabelStroke;this.yLineAnnotation=this.newLineAnnotation(E,A),this.parentSurface.modifierAnnotations.add(this.yLineAnnotation)}else!this.showYLineProperty&&this.yLineAnnotation&&(this.parentSurface.modifierAnnotations.remove(this.yLineAnnotation,!1),this.yLineAnnotation=(0,n.deleteSafe)(this.yLineAnnotation));this.notifyPropertyChanged(g.PROPERTY.Y_LINE)}},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"showAxisLabels",{get:function(){return this.showAxisLabelsProperty},set:function(x){this.showAxisLabelsProperty!==x&&(this.showAxisLabelsProperty=x,this.xLineAnnotation&&(this.xLineAnnotation.showLabel=this.showAxisLabelsProperty),this.yLineAnnotation&&(this.yLineAnnotation.showLabel=this.showAxisLabelsProperty),this.notifyPropertyChanged(g.PROPERTY.AXIS_LABELS))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"isSvgOnly",{get:function(){return this.isSvgOnlyProperty},set:function(x){this.isSvgOnlyProperty!==x&&(this.isSvgOnlyProperty=x,this.notifyPropertyChanged(g.PROPERTY.IS_SVG_ONLY))},enumerable:!1,configurable:!0}),Object.defineProperty(P.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(x){this.placementDivIdProperty!==x&&(this.placementDivIdProperty=x,this.notifyPropertyChanged(g.PROPERTY.PLACEMENT_DIV_ID))},enumerable:!1,configurable:!0}),P.prototype.includeSeries=function(x,E){return C.prototype.includeSeries.call(this,x,E)?(this.isAttached&&(this.tooltipAnnotation.seriesInfos=this.getSeriesInfos()),!0):!1},Object.defineProperty(P.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(x){this.tooltipDataTemplateProperty=x,this.notifyPropertyChanged(g.PROPERTY.TOOLTIP_DATA_TEMPLATE)},enumerable:!1,configurable:!0}),P.prototype.hitTestRenderableSeries=function(x,E){if(E)return this.hitTestRadius<=0?x.hitTestProvider.hitTestXSlice(E.x,E.y):x.hitTestProvider.hitTestDataPoint(E.x,E.y,this.hitTestRadius)},P.prototype.getMousePosition=function(){return this.mousePosition},P.prototype.toJSON=function(){var x=C.prototype.toJSON.call(this),E={axisLabelFill:this.axisLabelFill,axisLabelStroke:this.axisLabelStroke,xAxisLabelFill:this.xAxisLabelFill,xAxisLabelStroke:this.xAxisLabelStroke,yAxisLabelFill:this.yAxisLabelFill,yAxisLabelStroke:this.yAxisLabelStroke,crosshairStroke:this.crosshairStroke,crosshairStrokeDashArray:this.crosshairStrokeDashArray,crosshairStrokeThickness:this.crosshairStrokeThickness,hitTestRadius:this.hitTestRadius,placementDivId:this.placementDivId,showAxisLabels:this.showAxisLabels,axisLabelPadding:this.axisLabelPadding,axisLabelCornerRadius:this.axisLabelCornerRadius,showTooltip:this.showTooltip,showXLine:this.showXLine,showYLine:this.showYLine,tooltipContainerBackground:this.tooltipContainerBackground,tooltipDataTemplate:this.typeMap.get("tooltipDataTemplate"),tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,tooltipLegendTemplate:this.typeMap.get("tooltipLegendTemplate"),tooltipSvgTemplate:this.typeMap.get("tooltipSvgTemplate"),tooltipTextStroke:this.tooltipTextStroke,tooltipShadow:this.tooltipShadow,isSvgOnly:this.isSvgOnlyProperty,showOnOthersInGroup:this.showOnOthersInGroup};return Object.assign(x.options,E),x},P.prototype.notifyPropertyChanged=function(x){C.prototype.notifyPropertyChanged.call(this,x),x===g.PROPERTY.X_AXIS_ID&&(this.tooltipAnnotation&&(this.tooltipAnnotation.xAxisId=this.xAxisId),this.xLineAnnotation&&(this.xLineAnnotation.xAxisId=this.xAxisId),this.yLineAnnotation&&(this.yLineAnnotation.xAxisId=this.xAxisId)),x===g.PROPERTY.Y_AXIS_ID&&(this.tooltipAnnotation&&(this.tooltipAnnotation.yAxisId=this.yAxisId),this.xLineAnnotation&&(this.xLineAnnotation.yAxisId=this.yAxisId),this.yLineAnnotation&&(this.yLineAnnotation.yAxisId=this.yAxisId))},P.prototype.getSeriesInfos=function(){var x=this;return this.getIncludedRenderableSeries().map(function(E){var A=x.hitTestRenderableSeries(E,x.mousePoint);if(A)return E.getSeriesInfo(A)}).filter(function(E){return E!==void 0})},P.prototype.update=function(){var x,E,A,R,M,D;if(this.mousePosition!==a.EMousePosition.SeriesArea){this.xLineAnnotation&&(this.xLineAnnotation.isHidden=!0),this.yLineAnnotation&&(this.yLineAnnotation.isHidden=!0),this.tooltipAnnotation.isHidden=!0,this.tooltipAnnotation.seriesInfos=[],this.placementDivId&&this.tooltipAnnotation.delete();return}var F=(0,l.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect);this.xLineAnnotation&&(this.isMasterEvent||(!((E=(x=this.showOnOthersInGroup)===null||x===void 0?void 0:x.xLine)!==null&&E!==void 0)||E))&&(this.xLineAnnotation.isHidden=!1),this.yLineAnnotation&&(this.isMasterEvent||(!((R=(A=this.showOnOthersInGroup)===null||A===void 0?void 0:A.yLine)!==null&&R!==void 0)||R))&&(this.yLineAnnotation.isHidden=!1);var I=this.showTooltip&&(this.isMasterEvent||((D=(M=this.showOnOthersInGroup)===null||M===void 0?void 0:M.tooltip)!==null&&D!==void 0?D:!0));if(this.tooltipAnnotation.isHidden=!1,this.tooltipAnnotation.showTooltip=I,F){var V=(0,l.translateToNotScaled)(F.x),z=(0,l.translateToNotScaled)(F.y);if(this.xLineAnnotation&&(this.xLineAnnotation.y1=0),this.yLineAnnotation&&(this.yLineAnnotation.x1=0),this.parentSurface.isPolar){var G=this.yAxis,H=G.reverseTransform(V,z);this.xLineAnnotation&&(this.xLineAnnotation.x1=0,this.xLineAnnotation.x2=H.y,this.xLineAnnotation.y2=G.getAxisSize())}else this.isVerticalChart()?(this.xLineAnnotation&&(this.xLineAnnotation.y2=(0,l.translateToNotScaled)(this.parentSurface.seriesViewRect.right),this.xLineAnnotation.x1=z,this.xLineAnnotation.x2=z),this.yLineAnnotation&&(this.yLineAnnotation.x2=(0,l.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom),this.yLineAnnotation.y1=V,this.yLineAnnotation.y2=V)):(this.xLineAnnotation&&(this.xLineAnnotation.y2=(0,l.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom),this.xLineAnnotation.x1=V,this.xLineAnnotation.x2=V),this.yLineAnnotation&&(this.yLineAnnotation.x2=(0,l.translateToNotScaled)(this.parentSurface.seriesViewRect.right),this.yLineAnnotation.y1=z,this.yLineAnnotation.y2=z));I&&(this.tooltipAnnotation.x1=V,this.tooltipAnnotation.y1=z),(I||this.tooltipLegendTemplate)&&(this.tooltipAnnotation.seriesInfos=this.getSeriesInfos())}},P.prototype.newLineAnnotation=function(x,E){var A={xCoordinateMode:u.ECoordinateMode.Pixel,yCoordinateMode:u.ECoordinateMode.Pixel,strokeThickness:this.crosshairStrokeThickness,strokeDashArray:this.crosshairStrokeDashArray,stroke:this.crosshairStroke,isHidden:!0,showLabel:this.showAxisLabels,axisLabelFill:x,axisLabelStroke:E,xAxisId:this.xAxisId,yAxisId:this.yAxisId,labelPadding:this.axisLabelPadding,labelCornerRadius:this.axisLabelCornerRadius};return this.isSvgOnlyProperty?new v.SvgLineAnnotation(A):new f.LineAnnotation(A)},P.prototype.isVerticalChart=function(){var x,E;return(E=(x=this.xAxis)===null||x===void 0?void 0:x.isVerticalChart)!==null&&E!==void 0?E:!1},P})(p.ChartModifierBase2D);t.CursorModifier=y;var m=function(C,P){var x=[];return P&&x.push(P),C.forEach(function(E,A){var R;if(E.isHit){var M=(R=E.seriesName)!==null&&R!==void 0?R:"Series #".concat(A+1);x.push.apply(x,E.getValuesWithLabels(M,"X","Y",!1))}}),x},b=function(C,P){var x,E="id_".concat(Date.now()),A=(x=P.cursorModifier.tooltipDataTemplate)!==null&&x!==void 0?x:m,R=A(C,P.title);if(R.length===0)return"<svg></svg>";var M=(0,t.calcTooltipSize)(R,13),D=M.width,F=M.height;(0,t.adjustTooltipPosition)(D,F,P);var I="";R.forEach(function(W,Y){I+='<tspan x="8" dy="1.2em">'.concat(W,"</tspan>")});var V="95%";if(P.yCoordShift<0){var z=(0,l.translateToNotScaled)(P.parentSurface.seriesViewRect.height)-P.y1;F>z&&(V=(F-5).toFixed(0))}var G=P.containerBackground,H=P.textStroke,U=P.cursorModifier.tooltipShadow,k='<feGaussianBlur result="blurOut" in="offOut" stdDeviation="3" />';if(U!==void 0){var X=(0,s.parseColorToTArgb)(U);k=`<feColorMatrix result="matrixOut" in="offOut" type="matrix"
        values="0 0 0 0 `.concat(X.red/255,`
                0 0 0 0 `).concat(X.green/255,`
                0 0 0 0 `).concat(X.blue/255,`
                0 0 0 `).concat(X.opacity/255,` 0" />
        <feGaussianBlur result="blurOut" in="matrixOut" stdDeviation="3" />`)}return'<svg class="scichart__cursor-tooltip" width="'.concat(D,'" height="').concat(F,`">
        <defs>
            <filter id="`).concat(E,`" x="0" y="0" width="200%" height="200%">
                <feOffset result="offOut" in="SourceAlpha" dx="3" dy="3" />
                `).concat(k,`
                <feBlend in="SourceGraphic" in2="blurOut" mode="normal" />
            </filter>
        </defs>
        <rect rx="4" ry="4" width="95%" height="`).concat(V,'" fill="').concat(G,'" filter="url(#').concat(E,`)" />
        <svg width="100%">
            <text x="8" y="3" font-size="13" font-family="Verdana" dy="0" fill="`).concat(H,'">').concat(I,`</text>
        </svg>
    </svg>`)};t.defaultCursorTooltipSvgTemplate=b;var S=function(C,P){P===void 0&&(P=13);var x=C.reduce(function(R,M){return(M==null?void 0:M.length)>R?M.length:R},0),E=x*8+20,A=P*1.2*C.length+16;return{width:E,height:A}};t.calcTooltipSize=S;var _=function(C,P,x){var E=x.parentSurface.seriesViewRect,A=x.x1,R=x.y1,M=(0,l.translateToNotScaled)(E.width)-A<C?-C:5,D=(0,l.translateToNotScaled)(E.height)-R<P?-P:5;x.xCoordShift=M,x.yCoordShift=D};t.adjustTooltipPosition=_})(UF)),UF}var $F={},WF={},GF={},Y9={},ebe;function QV(){return ebe||(ebe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EErrorDirection=void 0,(function(e){e.Horizontal="Horizontal",e.Vertical="Vertical"})(t.EErrorDirection||(t.EErrorDirection={}))})(Y9)),Y9}var YF={},tbe;function tl(){if(tbe)return YF;tbe=1,Object.defineProperty(YF,"__esModule",{value:!0}),YF.HitTestInfo=void 0;var t=(function(){function e(i,n){n===void 0&&(n=!1),this.isEmpty=n,this.associatedSeries=i}return e.empty=function(){return new e(void 0,!0)},e.prototype.getEuclideanDistance=function(){var i,n,r=((i=this.hitTestPoint)===null||i===void 0?void 0:i.x)-this.xCoord,o=((n=this.hitTestPoint)===null||n===void 0?void 0:n.y)-this.yCoord;return Math.sqrt(r*r+o*o)},Object.defineProperty(e.prototype,"distance",{get:function(){return this.distanceProperty!==void 0?this.distanceProperty:this.getEuclideanDistance()},set:function(i){this.distanceProperty=i},enumerable:!1,configurable:!0}),e})();return YF.HitTestInfo=t,YF}var q9={},rbe;function VI(){return rbe||(rbe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ETriangleSeriesDrawMode=void 0,(function(e){e.List="List",e.Polygon="Polygon",e.Strip="Strip"})(t.ETriangleSeriesDrawMode||(t.ETriangleSeriesDrawMode={}))})(q9)),q9}var ibe;function vl(){if(ibe)return GF;ibe=1,Object.defineProperty(GF,"__esModule",{value:!0}),GF.hitTestHelpers=void 0;var t=Br(),e=$i(),i=QV(),n=Eo();Vd();var r=tl(),o=VI(),a=function(E,A,R,M,D){return R+(D-R)*(E-A)/(M-A)},s=function(E,A,R,M,D,F,I,V,z,G,H,U,k){var X=A.isCategoryCoordinateCalculator,W=new r.HitTestInfo(E);W.seriesName=E.seriesName,W.dataSeriesType=D.type,W.hitTestPoint=new e.Point(V,z);var Y=A.getDataValue(V),te=R.getDataValue(z);if(W.hitTestPointValues=new e.Point(Y,te),W.dataSeriesIndex=G,W.hitTestRadius=H,W.isCategoryAxis=X,W.distance=U,G>=0){var oe=D.valueNames.reduce(function(Ae,Pe){return Ae[Pe]=D.getNativeValue(D.getYValuesByName(Pe),G),Ae},{}),de=X?G:D.getNativeValue(F,G),ge=D.getNativeValue(I,G);W.xCoord=A.getCoordinate(de),W.yCoord=R.getCoordinate(ge),W.xValue=de,X&&(W.xCategoryValue=F.get(G)),W.yValueByName=oe,W.yValue=ge;var Ee=X?D.getIndicesRange(D.getXRange()):D.getXRange(),Re=k!==void 0?A.getDataWidth(k):0;W.isWithinDataBounds=(0,n.testIsInInterval)(Y,Ee.min,Ee.max,Re/2),W.metadata=D.getMetadataAt(G)}else W.isWithinDataBounds=!1;return W.isHit=void 0,W},l=function(E,A,R,M,D){var F=u(E,A,A,R,M,0,0);return F.nearestPointIndex},u=function(E,A,R,M,D,F,I){var V=A.isCategoryCoordinateCalculator,z=V?M.getNativeIndexes():M.getNativeXValues(),G=M.getNativeYValues();return c(E,A,R,z,G,M.dataDistributionCalculator.isSortedAscending,D,F,I)},c=function(E,A,R,M,D,F,I,V,z){var G;try{return G=E.SCRTHitTestHelper.GetNearestXyPoint(A.nativeCalculator,R.nativeCalculator,M,D,F,I,V,z??1),{nearestPointIndex:G.minD,distance:G.maxD}}finally{(0,t.deleteSafe)(G)}},d=function(E,A,R,M,D,F,I){var V=A.isCategoryCoordinateCalculator,z=V?M.getNativeIndexes():M.getNativeXValues(),G=M.getNativeYValues(),H,U,k;try{H=E.SCRTHitTestHelper.GetNearestXyPoint(A.nativeCalculator,R.nativeCalculator,z,G,M.dataDistributionCalculator.isSortedAscending,D,F,I??1),U=H.minD,k=H.maxD}finally{(0,t.deleteSafe)(H)}try{return H=E.SCRTHitTestHelper.GetNearestXyPoint(A.nativeCalculator,R.nativeCalculator,z,M.getNativeY1Values(),M.dataDistributionCalculator.isSortedAscending,D,F,I??1),k<H.maxD?{nearestPointIndex:U,distance:k}:{nearestPointIndex:H.minD,distance:H.maxD}}finally{(0,t.deleteSafe)(H)}},f=function(E,A,R,M,D){var F=E.getDataValue(M),I=A.getDataValue(D),V=Math.floor((F-R.xStart)/R.xStep),z=Math.floor((I-R.yStart)/R.yStep);if(V<0||V>=R.arrayWidth||z<0||z>=R.arrayHeight)return{xIndex:-1,yIndex:-1,zValue:void 0};var G=R.getZValue(z,V);return{xIndex:V,yIndex:z,zValue:G}},h=function(E,A,R,M,D){var F=E.getDataValue(M),I=A.getDataValue(D),V=R.xCellOffsets,z=R.yCellOffsets,G=-1;if(F>=V[0]&&F<=V[V.length-1])for(var H=0;H<V.length;H++){var U=F>=V[H]&&F<=V[H+1];if(U){G=H;break}}var k=-1;if(I>=z[0]&&I<=z[z.length-1])for(var H=0;H<z.length-1;H++){var U=I>=z[H]&&I<=z[H+1];if(U){k=H;break}}if(G<0||G>=R.arrayWidth||k<0||k>=R.arrayHeight)return{xIndex:-1,yIndex:-1,zValue:void 0};var X=R.getZValue(k,G);return{xIndex:G,yIndex:k,zValue:X}},p=function(E,A,R,M,D,F,I,V,z){var G=V===o.ETriangleSeriesDrawMode.Polygon||V===o.ETriangleSeriesDrawMode.List,H=V===o.ETriangleSeriesDrawMode.List?3:z,U=E.SCRTHitTestHelper.GetNearestTriangle(G,H,A.nativeCalculator,R.nativeCalculator,M,D,F,I);return{nearestPointIndex:U.minD,nearestPointIndex2:U.maxD,isHit:U.minD>=0}},g=function(E,A,R,M,D,F,I,V,z,G){var H=Number.MAX_VALUE,U=Number.NEGATIVE_INFINITY,k=Number.MAX_VALUE,X=Number.NEGATIVE_INFINITY,W=function(Ce,Ue){for(var Qe=0;Qe<R;Qe++){var it=Ce(Qe),xt=Ue(Qe);H=it<H?it:H,U=it>U?it:U,k=xt<k?xt:k,X=xt>X?xt:X}};W(M,D),W(F,I);for(var Y=E.getDataValue(V),te=A.getDataValue(z),oe=H<=Y&&Y<=U&&k<=te&&te<=X,de=Number.MAX_VALUE,ge=-1,Ee=0;Ee<R;Ee++){var Re=M(Ee),Ae=D(Ee),Pe=F(Ee),we=I(Ee),Te=E.getCoordinate(Re),ke=A.getCoordinate(Ae),$e=E.getCoordinate(Pe),Ne=A.getCoordinate(we),ve=(0,n.calcDistance)(Te,ke,$e,Ne),pe=(0,n.calcDistance)(Te,ke,V,z),fe=(0,n.calcDistance)($e,Ne,V,z);if(pe<=ve+G&&fe<=ve+G){var me=(0,n.calcDistanceFromLine)(V,z,Te,ke,$e,Ne);me<=de&&(de=me,ge=Ee)}}return{isHit:de<=G,isWithinDataBounds:oe,nearestPointIndex:ge,nearestDistance:ge>=0?de:void 0}},v=function(E,A,R,M,D,F,I,V,z){var G=E.isCategoryCoordinateCalculator,H=G?D:z.getNativeValue(R,D),U=z.getNativeValue(M,D),k=E.getCoordinate(H),X=A.getCoordinate(U),W=(0,n.calcDistance)(F,I,k,X);return W<V},y=function(E,A,R,M,D,F,I,V,z){var G,H,U,k,X,W,Y=E.isCategoryCoordinateCalculator,te=Y?D:z.getNativeValue(R,D),oe=z.getNativeValue(M,D),de=E.getDataValue(F);te<=de?(U=te,X=oe,k=Y?D+1:z.getNativeValue(R,D+1),W=z.getNativeValue(M,D+1),H=D+1):(U=Y?D-1:z.getNativeValue(R,D-1),X=z.getNativeValue(M,D-1),H=D-1,k=te,W=oe);var ge=E.getCoordinate(U),Ee=E.getCoordinate(k),Re=A.getCoordinate(X),Ae=A.getCoordinate(W),Pe=(0,n.calcDistance)(ge,Re,Ee,Ae),we=(0,n.calcDistance)(ge,Re,F,I),Te=(0,n.calcDistance)(Ee,Ae,F,I);return we>Pe+V||Te>Pe+V?G=!1:G=(0,n.calcDistanceFromLine)(F,I,ge,Re,Ee,Ae)<V,{isHit:G,secondPointIndex:H}},m=function(E,A,R,M,D,F,I,V,z,G){var H,U=A.getDataValue(V),k=A.isCategoryCoordinateCalculator,X=k?I:G.getNativeValue(M,I),W=X<=U,Y=W?I+1:I-1;if(Y<0||Y>=M.size())return{isHit:!1,secondPointIndex:void 0};var te=k?Y:G.getNativeValue(M,Y),oe=W?X:te,de=D(W?I:Y),ge=F(W?I:Y),Ee=W?te:X,Re=D(W?Y:I),Ae=F(W?Y:I),Pe=A.getCoordinate(oe),we=A.getCoordinate(Ee),Te=R.getCoordinate(de),ke=R.getCoordinate(Re),$e=R.getCoordinate(ge),Ne=R.getCoordinate(Ae);if(E)Te<$e?H=z>=Te&&z<=$e:H=z>=$e&&z<=Te;else{var ve=a(V,Pe,Te,we,ke),pe=a(V,Pe,$e,we,Ne);ve<pe?H=z>=ve&&z<=pe:H=z>=pe&&z<=ve}return{isHit:H,secondPointIndex:Y}},b=function(E,A,R,M,D,F,I,V,z,G,H){H===void 0&&(H=void 0);var U=E.isCategoryCoordinateCalculator,k=U?V:D.getNativeValue(F,V),X=D.getNativeValue(I,V),W=E.getCoordinate(k),Y=A.getCoordinate(X),te=A.getCoordinate(M),oe=R/2,de=te>Y?te:Y,ge=te>Y?Y:te;if(H!==void 0){var Ee=H<=oe,Re=G<=de&&G>=ge;return Ee&&Re}else return(0,n.testIsInBounds)(z,G,W-oe,de,W+oe,ge)},S=function(E,A,R,M,D,F,I,V,z,G){var H=E.isCategoryCoordinateCalculator,U=H?V:M.getNativeValue(D,V),k=M.getNativeValue(F,V),X=M.getNativeValue(I,V),W=E.getCoordinate(U),Y=A.getCoordinate(k),te=A.getCoordinate(X),oe=R/2,de=te>Y?te:Y,ge=te>Y?Y:te;return(0,n.testIsInBounds)(z,G,W-oe,de,W+oe,ge)},_=function(E,A,R,M,D,F,I,V){var z=R.getDataPointWidth,G=R.dataPointWidth,H=R.errorDirection,U=R.dataSeries,k=R.dataPointWidthMode,X=E.isCategoryCoordinateCalculator,W=H===i.EErrorDirection.Vertical,Y=X?F:U.getNativeValue(M,F),te=U.getNativeValue(D,F),oe=U.getNativeValue(U.getNativeHighValues(),F),de=U.getNativeValue(U.getNativeLowValues(),F);isNaN(oe)&&(oe=te),isNaN(de)&&(de=te);var ge=E.getCoordinate(Y),Ee=A.getCoordinate(te),Re=W?A.getCoordinate(oe):E.getCoordinate(oe),Ae=W?A.getCoordinate(de):E.getCoordinate(de),Pe=z(W?E:A,G,k),we=Pe/2,Te=!1,ke=Re>Ae?Re:Ae,$e=Re>Ae?Ae:Re;return W?Te=(0,n.testIsInBounds)(I,V,ge-we,ke,ge+we,$e):Te=(0,n.testIsInBounds)(I,V,$e,Ee+we,ke,Ee-we),{isHit:Te,highValue:oe,lowValue:de}},C=function(E,A,R,M,D,F,I,V,z){var G=R.zeroLineY,H=R.dataSeries,U=E.isCategoryCoordinateCalculator,k=U?F:H.getNativeValue(M,F),X=H.getNativeValue(D,F),W=E.getCoordinate(k),Y=A.getCoordinate(X),te=A.getCoordinate(G),oe=te>Y?te:Y,de=te>Y?Y:te;return(0,n.testIsInBounds)(I,V,W,oe,W,de,z)},P=function(E,A,R,M,D,F,I,V){var z=R.getDataPointWidth,G=R.dataPointWidth,H=R.dataPointWidthMode,U=E.isCategoryCoordinateCalculator,k=U?D:M.getNativeValue(M.getNativeXValues(),D),X=E.getCoordinate(k),W=M.getNativeValue(M.getNativeOpenValues(),D),Y=A.getCoordinate(W),te=M.getNativeValue(M.getNativeHighValues(),D),oe=A.getCoordinate(te),de=M.getNativeValue(M.getNativeLowValues(),D),ge=A.getCoordinate(de),Ee=M.getNativeValue(M.getNativeCloseValues(),D),Re=A.getCoordinate(Ee),Ae=z(E,G,H),Pe=Ae/2,we=Re>Y?Re:Y,Te=Re>Y?Y:Re,ke=(0,n.testIsInBounds)(F,I,X-Pe,we,X+Pe,Te),$e=(0,n.calcDistanceFromLineSegment)(F,I,X,oe,X,ge),Ne=ke||$e<V;return{isHit:Ne,openValue:W,highValue:te,lowValue:de,closeValue:Ee}},x=function(E,A,R,M,D,F,I,V){var z,G=M.getNativeXValues(),H=A.isCategoryCoordinateCalculator,U=H?F:M.getNativeValue(G,F),k=M.getNativeYValues(),X=A.getDataValue(I),W=U<=X,Y=W?F+1:F-1;if(Y<0||Y>=M.count())return{isHit:!1,secondPointIndex:void 0};var te=H?Y:G.get(Y),oe=W?U:te,de=W?M.getNativeValue(k,F):M.getNativeValue(k,Y),ge=W?te:U,Ee=W?M.getNativeValue(k,Y):M.getNativeValue(k,F),Re=A.getCoordinate(oe),Ae=A.getCoordinate(ge),Pe=R.getCoordinate(de),we=R.getCoordinate(Ee),Te=R.getCoordinate(D);if(E)Pe<Te?z=V>=Pe&&V<=Te:z=V>=Te&&V<=Pe;else{var ke=a(I,Re,Pe,Ae,we);ke<Te?z=V>=ke&&V<=Te:z=V>=Te&&V<=ke}return{isHit:z,secondPointIndex:Y}};return GF.hitTestHelpers={createHitTestInfo:s,getNearestPoint:c,getNearestXPoint:l,getNearestXyPoint:u,getNearestXyyPoint:d,getNearestUniformHeatmapPoint:f,getNearestNonUniformHeatmapPoint:h,getNearestTriangle:p,getNearestLineSegment:g,testIsHitForPoint:v,testIsHitForLine:y,testIsHitForBand:m,testIsHitForColumn:b,testIsHitForOHLC:P,testIsHitForMountain:x,testIsHitForErrorBars:_,testIsHitForImpulse:C,testIsHitForBoxPlot:S},GF}var nbe;function Vl(){if(nbe)return WF;nbe=1,Object.defineProperty(WF,"__esModule",{value:!0}),WF.BaseHitTestProvider=void 0;var t=ci(),e=$i(),i=An(),n=vl(),r=tl(),o=(function(){function a(s,l){t.Guard.notNull(s,"parentSeries"),this.parentSeries=s,this.webAssemblyContext=l}return a.prototype.update=function(s){this.currentRenderPassData=s},a.prototype.hitTestDataPoint=function(s,l,u){u===void 0&&(u=a.DEFAULT_HIT_TEST_RADIUS);var c=this.getTranslatedHitTestPoint(s,l);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=f.isCategoryCoordinateCalculator,b=m?y.getNativeIndexes():y.getNativeXValues(),S=this.parentSeries.getNativeYValues(),_=n.hitTestHelpers.getNearestPoint(this.webAssemblyContext,f,h,b,S,y.dataDistributionCalculator.isSortedAscending,g,v,u),C=y.getNativeXValues(),P=this.parentSeries.getNativeYValues(),x=n.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,C,P,g,v,_.nearestPointIndex,u,_.distance);return _.nearestPointIndex>=0?x.isHit=n.hitTestHelpers.testIsHitForPoint(f,h,C,P,_.nearestPointIndex,g,v,u,y):x.isHit=!1,x},a.prototype.hitTestForDataPointSelectionModifier=function(s,l,u){return u===void 0&&(u=a.DEFAULT_HIT_TEST_RADIUS),this.hitTestDataPoint(s,l,u)},a.prototype.hitTestXSlice=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return r.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return r.HitTestInfo.empty();var y=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=this.parentSeries.getNativeYValues(),S=n.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0,void 0);if(S.isHit=S.isWithinDataBounds,v.dataDistributionCalculator.isSortedAscending&&y>=0){var _=m.size(),C=d.getCoordinate(d.isCategoryCoordinateCalculator?y:m.get(y));if(!(y===_-1&&(d.hasFlippedCoordinates?p>=C:p<=C))&&!(y===0&&(d.hasFlippedCoordinates?p<=C:p>=C))){var P=n.hitTestHelpers.testIsHitForLine(d,f,m,b,y,p,g,0,v);S.point2dataSeriesIndex=P.secondPointIndex,S.point2xValue=m.get(P.secondPointIndex),S.point2xCoord=d.getCoordinate(S.point2xValue),S.point2yValue=b.get(P.secondPointIndex),S.point2yCoord=f.getCoordinate(S.point2yValue),S.point2metadata=v.getMetadataAt(P.secondPointIndex);var x=v.valueNames.reduce(function(E,A){return E[A]=v.getNativeValue(v.getYValuesByName(A),S.point2dataSeriesIndex),E},{});S.point2yValueByName=x}}return S},a.prototype.getTranslatedHitTestPoint=function(s,l){if(!(!this.currentRenderPassData||s===void 0||l===void 0))return(0,i.translateFromCanvasToSeriesViewRect)(new e.Point(s,l),this.parentSeries.parentSurface.seriesViewRect)},a.DEFAULT_HIT_TEST_RADIUS=7.07,a})();return WF.BaseHitTestProvider=o,WF}var Qx={},X9={},obe;function tAt(){return obe||(obe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.IS_HIDDEN="IS_HIDDEN",e.X1="X1",e.X2="X2",e.Y1="Y1",e.Y2="Y2"})(t.PROPERTY||(t.PROPERTY={}))})(X9)),X9}var abe;function xie(){if(abe)return Qx;abe=1;var t=Qx&&Qx.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Qx,"__esModule",{value:!0}),Qx.RubberBandSvgRect=void 0;var e=fo(),i=tAt(),n=(function(o){t(a,o);function a(s,l,u,c){var d=o.call(this)||this;return d.svgTemplate=r,d.x1Property=0,d.x2Property=0,d.y1Property=0,d.y2Property=0,d.isHiddenProperty=!0,d.svgRoot=s,d.create(l,u,c),d}return Object.defineProperty(a.prototype,"x1",{get:function(){return this.x1Property},set:function(s){this.x1Property=s,this.notifyPropertyChanged(i.PROPERTY.X1)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"x2",{get:function(){return this.x2Property},set:function(s){this.x2Property=s,this.notifyPropertyChanged(i.PROPERTY.X2)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"y1",{get:function(){return this.y1Property},set:function(s){this.y1Property=s,this.notifyPropertyChanged(i.PROPERTY.Y1)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"y2",{get:function(){return this.y2Property},set:function(s){this.y2Property=s,this.notifyPropertyChanged(i.PROPERTY.Y2)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"isHidden",{get:function(){return this.isHiddenProperty},set:function(s){this.isHiddenProperty=s,this.notifyPropertyChanged(i.PROPERTY.IS_HIDDEN)},enumerable:!1,configurable:!0}),a.prototype.clear=function(){this.svgRoot.removeChild(this.svg)},a.prototype.delete=function(){this.clear()},a.prototype.create=function(s,l,u){if(this.svg&&this.clear(),this.svgRoot){var c=this.svgTemplate(s,l,u,0,0);this.svgRoot.appendChild(c),this.svg=c,this.svg.setAttribute("x","100px"),this.svg.setAttribute("y","100px")}},a.prototype.update=function(s){if(this.svgRoot){if(s===i.PROPERTY.IS_HIDDEN&&(this.svg.style.display=this.isHidden?"none":"block"),s===i.PROPERTY.X1||s===i.PROPERTY.X2){var l=Math.abs(this.x2-this.x1);this.svg.setAttribute("x",this.x1.toString()),this.svg.setAttribute("width","".concat(l,"px"))}if(s===i.PROPERTY.Y1||s===i.PROPERTY.Y2){var u=Math.abs(this.y2-this.y1);this.svg.setAttribute("y",this.y1.toString()),this.svg.setAttribute("height","".concat(u,"px"))}}},a.prototype.notifyPropertyChanged=function(s){this.update(s)},a})(e.DeletableEntity);Qx.RubberBandSvgRect=n;var r=function(o,a,s,l,u){l===void 0&&(l=0),u===void 0&&(u=0);var c="http://www.w3.org/2000/svg",d=document.createElementNS(c,"svg");d.setAttributeNS(null,"width",l.toString()),d.setAttributeNS(null,"height",u.toString()),d.style.display="none";var f=document.createElementNS(c,"rect");return d.appendChild(f),f.setAttributeNS(null,"width","100%"),f.setAttributeNS(null,"height","100%"),f.setAttributeNS(null,"fill",o),f.setAttributeNS(null,"stroke",a),f.setAttributeNS(null,"stroke-width",s.toString()),d};return Qx}var qF={},sbe;function WBe(){if(sbe)return qF;sbe=1,Object.defineProperty(qF,"__esModule",{value:!0}),qF.DataPointInfo=void 0;var t=(function(){function e(i,n,r){this.renderableSeriesProperty=i,this.indexProperty=r,this.metadataProperty=n}return Object.defineProperty(e.prototype,"metadata",{get:function(){return this.metadataProperty},set:function(i){this.metadataProperty=i},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"index",{get:function(){return this.indexProperty},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"xValue",{get:function(){return this.dataSeries.getNativeXValues().get(this.index)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"yValue",{get:function(){return this.dataSeries.getNativeYValues().get(this.index)},enumerable:!1,configurable:!0}),e.prototype.getValueByName=function(i){var n=this.dataSeries.getYValuesByName(i);if(n)return this.dataSeries.getNativeValue(n,this.index)},Object.defineProperty(e.prototype,"renderableSeries",{get:function(){return this.renderableSeriesProperty},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dataSeries",{get:function(){return this.renderableSeries.dataSeries},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"seriesName",{get:function(){return this.renderableSeries.seriesName},enumerable:!1,configurable:!0}),e})();return qF.DataPointInfo=t,qF}var XF={},lbe;function GBe(){if(lbe)return XF;lbe=1,Object.defineProperty(XF,"__esModule",{value:!0}),XF.DataPointSelectionChangedArgs=void 0;var t=(function(){function e(i,n){this.source=i,this.selectedDataPoints=n}return e})();return XF.DataPointSelectionChangedArgs=t,XF}var Sb={},ube;function Y3(){if(ube)return Sb;ube=1;var t=Sb&&Sb.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(Sb,"__esModule",{value:!0}),Sb.getRubberBandRect=Sb.RubberBandXyZoomModifier=void 0;var e=ad(),i=Br(),n=$i(),r=Rn(),o=Lm(),a=Ho(),s=pl(),l=xm(),u=An(),c=xie(),d=Qu(),f=km(),h=(function(g){t(v,g);function v(y){var m=this,b,S,_,C,P,x,E;return m=g.call(this,y)||this,m.type=a.EChart2DModifierType.RubberBandXYZoom,m.isAnimated=!0,m.animationDuration=400,m.easingFunction=e.easing.outExpo,m.isClicked=!1,m.fillProperty="#42b64933",m.strokeProperty="#42b64977",m.strokeThicknessProperty=2,m.fill=(b=y==null?void 0:y.fill)!==null&&b!==void 0?b:m.fillProperty,m.stroke=(S=y==null?void 0:y.stroke)!==null&&S!==void 0?S:m.strokeProperty,m.strokeThickness=(_=y==null?void 0:y.strokeThickness)!==null&&_!==void 0?_:m.strokeThicknessProperty,m.isAnimated=(C=y==null?void 0:y.isAnimated)!==null&&C!==void 0?C:!0,m.animationDuration=(P=y==null?void 0:y.animationDuration)!==null&&P!==void 0?P:400,y!=null&&y.easingFunction&&typeof y.easingFunction=="string"&&(y.easingFunction=e.easing[y.easingFunction]),m.easingFunction=(x=y==null?void 0:y.easingFunction)!==null&&x!==void 0?x:e.easing.outExpo,m.executeCondition=(E=y==null?void 0:y.executeCondition)!==null&&E!==void 0?E:{button:o.EExecuteOn.MouseLeftButton},m}return v.prototype.applyTheme=function(y){this.testPropertyChanged(f.PROPERTY.FILL)||(this.fill=y.rubberBandFillBrush),this.testPropertyChanged(f.PROPERTY.STROKE)||(this.stroke=y.rubberBandStrokeBrush)},v.prototype.onDetach=function(){g.prototype.onDetach.call(this),this.rubberBandRect=(0,i.deleteSafe)(this.rubberBandRect)},v.prototype.modifierMouseDown=function(y){if(g.prototype.modifierMouseDown.call(this,y),!!this.checkExecuteConditions(y).isPrimary){if(!this.isAttached)throw new Error("Should not call RubberBandXyZoomModifier.modifierMouseDown if not attached");this.parentSurface.setZoomState(l.EZoomState.UserZooming);var m=(0,u.translateFromCanvasToSeriesViewRect)(y.mousePoint,this.parentSurface.seriesViewRect);m&&(this.pointFrom=m,this.isClicked=!0)}},v.prototype.modifierMouseMove=function(y){g.prototype.modifierMouseMove.call(this,y);var m=this.parentSurface.seriesViewRect;if(this.isClicked){this.pointTo=(0,u.translateFromCanvasToSeriesViewRect)(r.Rect.clipPointToRect(y.mousePoint,m),m);var b=this.parentSurface.getCoordSvgTranslation(),S=p(this.pointFrom,this.pointTo,this.xyDirection,this.parentSurface.seriesViewRect),_=S.x,C=S.right,P=S.y,x=S.bottom;this.rubberBandRect.isHidden=!1,this.rubberBandRect.x1=(0,u.translateToNotScaled)(_+b.x),this.rubberBandRect.x2=(0,u.translateToNotScaled)(C+b.x),this.rubberBandRect.y1=(0,u.translateToNotScaled)(P+b.y),this.rubberBandRect.y2=(0,u.translateToNotScaled)(x+b.y)}},v.prototype.modifierMouseUp=function(y){if(g.prototype.modifierMouseUp.call(this,y),!!this.checkExecuteConditions(y).isPrimary&&this.isClicked){var m=this.parentSurface.seriesViewRect;this.pointTo=(0,u.translateFromCanvasToSeriesViewRect)(r.Rect.clipPointToRect(y.mousePoint,m),m);var b=p(this.pointFrom,this.pointTo,this.xyDirection,this.parentSurface.seriesViewRect),S=b.x,_=b.right,C=b.y,P=b.bottom;this.isClicked=!1,this.rubberBandRect.isHidden=!0,this.calculateDraggedDistance()>v.MIN_DRAG_SENSITIVITY&&this.performZoom(new n.Point(S,C),new n.Point(_,P))}},Object.defineProperty(v.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(y){this.strokeThicknessProperty=y,this.notifyPropertyChanged(f.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(y){this.strokeProperty=y,this.notifyPropertyChanged(f.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fill",{get:function(){return this.fillProperty},set:function(y){this.fillProperty=y,this.notifyPropertyChanged(f.PROPERTY.FILL)},enumerable:!1,configurable:!0}),v.prototype.toJSON=function(){var y=g.prototype.toJSON.call(this),m={animationDuration:this.animationDuration,easingFunction:this.easingFunction.name,fill:this.fill,isAnimated:this.isAnimated,stroke:this.stroke,strokeThickness:this.strokeThickness};return Object.assign(y.options,m),y},v.prototype.delete=function(){this.parentSurfaceProperty=void 0,this.rubberBandRect=(0,i.deleteSafe)(this.rubberBandRect),g.prototype.delete.call(this)},v.prototype.performZoom=function(y,m){var b=this,S=[s.EXyDirection.XDirection,s.EXyDirection.XyDirection].includes(this.xyDirection),_=[s.EXyDirection.YDirection,s.EXyDirection.XyDirection].includes(this.xyDirection);this.parentSurface.xAxes.asArray().forEach(function(C){(!C.isVerticalChart&&S||C.isVerticalChart&&_)&&b.performZoomOnAxis(C,C.isVerticalChart?y.y:y.x,C.isVerticalChart?m.y:m.x)}),this.parentSurface.yAxes.asArray().forEach(function(C){(!C.isVerticalChart&&_||C.isVerticalChart&&S)&&b.performZoomOnAxis(C,C.isVerticalChart?y.x:y.y,C.isVerticalChart?m.x:m.y)})},v.prototype.performZoomOnAxis=function(y,m,b){y.zoom(m,b,this.isAnimated?this.animationDuration:0,this.easingFunction)},v.prototype.notifyPropertyChanged=function(y){g.prototype.notifyPropertyChanged.call(this,y),this.updateRubberBandRect()},v.prototype.calculateDraggedDistance=function(){var y=Math.pow(this.pointFrom.x-this.pointTo.x,2),m=Math.pow(this.pointFrom.y-this.pointTo.y,2);return Math.sqrt(y+m)},v.prototype.updateRubberBandRect=function(){this.parentSurface&&(this.rubberBandRect=(0,i.deleteSafe)(this.rubberBandRect),this.rubberBandRect=new c.RubberBandSvgRect(this.parentSurface.domSvgContainer,this.fill,this.stroke,this.strokeThickness))},v.MIN_DRAG_SENSITIVITY=5,v})(d.ChartModifierBase2D);Sb.RubberBandXyZoomModifier=h;function p(g,v,y,m){var b=v.x<=g.x?v.x:g.x,S=v.x<=g.x?g.x:v.x,_=v.y<=g.y?v.y:g.y,C=v.y<=g.y?g.y:v.y;return y===s.EXyDirection.XDirection&&(_=0,C=m.height),y===s.EXyDirection.YDirection&&(b=0,S=m.width),r.Rect.createWithPoints(new n.Point(b,_),new n.Point(S,C))}return Sb.getRubberBandRect=p,Sb}var cbe;function t$(){return cbe||(cbe=1,(function(t){var e=$F&&$F.__extends||(function(){var A=function(R,M){return A=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(D,F){D.__proto__=F}||function(D,F){for(var I in F)Object.prototype.hasOwnProperty.call(F,I)&&(D[I]=F[I])},A(R,M)};return function(R,M){if(typeof M!="function"&&M!==null)throw new TypeError("Class extends value "+String(M)+" is not a constructor or null");A(R,M);function D(){this.constructor=R}R.prototype=M===null?Object.create(M):(D.prototype=M.prototype,new D)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.DataPointSelectionModifier=t.ESelectionMode=void 0;var i=mo(),n=Br(),r=ps(),o=di(),a=Rn(),s=ga(),l=Lm(),u=Ho(),c=ym(),d=Eo(),f=An(),h=bo(),p=zi(),g=XV(),v=Vl(),y=xie(),m=Qu(),b=km(),S=WBe(),_=GBe(),C=Y3(),P;(function(A){A.Union="Union",A.Inverse="Inverse",A.Replace="Replace"})(P=t.ESelectionMode||(t.ESelectionMode={}));var x=(function(A){e(R,A);function R(M){var D=this,F,I,V,z,G;return D=A.call(this,M)||this,D.type=u.EChart2DModifierType.DataPointSelection,D.selectionChanged=new r.EventHandler,D.selectedDataPointsMap=new Map,D.selectionHasChanged=!1,D.hitTestRadius=v.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS,D.allowClickSelect=(F=M==null?void 0:M.allowClickSelect)!==null&&F!==void 0?F:!0,D.allowDragSelect=(I=M==null?void 0:M.allowDragSelect)!==null&&I!==void 0?I:!0,D.executeCondition=(V=M==null?void 0:M.executeCondition)!==null&&V!==void 0?V:{button:l.EExecuteOn.MouseLeftButton},D.hitTestRadius=(z=M==null?void 0:M.hitTestRadius)!==null&&z!==void 0?z:D.hitTestRadius,M!=null&&M.selectionStroke&&(D.selectionStroke=M.selectionStroke),M!=null&&M.selectionFill&&(D.selectionFill=M==null?void 0:M.selectionFill),D.selectionStrokeThicknessProperty=(G=M==null?void 0:M.selectionStrokeThickness)!==null&&G!==void 0?G:1,M!=null&&M.onSelectionChanged&&(typeof M.onSelectionChanged=="string"?(D.typeMap.set("onSelectionChanged",M.onSelectionChanged),D.selectionChanged.subscribe((0,i.getFunction)(s.EBaseType.OptionFunction,M.onSelectionChanged))):D.selectionChanged.subscribe(M.onSelectionChanged)),M!=null&&M.getSelectionMode&&(typeof M.getSelectionMode=="string"?(D.typeMap.set("getSelectionMode",M.getSelectionMode),D.getSelectionMode=(0,i.getFunction)(s.EBaseType.OptionFunction,M.getSelectionMode)):D.getSelectionMode=M.getSelectionMode),D}return R.prototype.applyTheme=function(M){this.testPropertyChanged(b.PROPERTY.SELECTION_FILL)||(this.selectionFill=M.rubberBandFillBrush),this.testPropertyChanged(b.PROPERTY.SELECTION_STROKE)||(this.selectionStroke=M.rubberBandStrokeBrush)},R.prototype.onAttach=function(){var M=this,D,F;A.prototype.onAttach.call(this),this.selectionRect=new y.RubberBandSvgRect((D=this.parentSurface)===null||D===void 0?void 0:D.domSvgContainer,this.selectionFill,this.selectionStroke,this.selectionStrokeThickness),this.clearSelectedDataPoints(),(F=this.getIncludedRenderableSeries())===null||F===void 0||F.forEach(function(I){return M.onAttachSeries(I)})},R.prototype.onDetach=function(){var M=this,D;A.prototype.onDetach.call(this),this.selectionRect=(0,n.deleteSafe)(this.selectionRect),this.clearSelectedDataPoints(),(D=this.getIncludedRenderableSeries())===null||D===void 0||D.forEach(function(F){return M.onDetachSeries(F)})},Object.defineProperty(R.prototype,"selectedDataPoints",{get:function(){return Array.from(this.selectedDataPointsMap.values())},enumerable:!1,configurable:!0}),R.prototype.onAttachSeries=function(M){if(A.prototype.onAttachSeries.call(this,M),!(!M.dataSeries||M.dataSeries.type===p.EDataSeriesType.HeatmapUniform)){var D=M.dataSeries;D.hasMetadataGenerator()||D.setMetadataGenerator(new g.TemplateMetadataGenerator({isSelected:!1}));for(var F=0;F<D.getMetadataLength();F++){var I=D.getMetadataAt(F);if(I!=null&&I.isSelected){var V=new S.DataPointInfo(M,I,F);this.addSelectedDataPoint(M,F,V)}}this.raiseSelectionChanged(!1)}},R.prototype.onDetachSeries=function(M){A.prototype.onDetachSeries.call(this,M),!(M.isStacked||!M.dataSeries)&&(this.removeSelectedDataPointsForSeries(M),this.raiseSelectionChanged(!1))},R.prototype.modifierMouseDown=function(M){if(A.prototype.modifierMouseDown.call(this,M),!!this.checkExecuteConditions(M).isPrimary){if(!this.isAttached)throw new Error("Should not call DataPointSelectionModifier.modifierMouseDown if not attached");var D=(0,f.translateFromCanvasToSeriesViewRect)(M.mousePoint,this.parentSurface.seriesViewRect);D&&(this.startPoint=D,this.isClicked=!0,M.handled=!0)}},R.prototype.modifierMouseMove=function(M){A.prototype.modifierMouseMove.call(this,M);var D=this.parentSurface.seriesViewRect;if(this.isClicked){this.endPoint=(0,f.translateFromCanvasToSeriesViewRect)(a.Rect.clipPointToRect(M.mousePoint,D),D);var F=this.parentSurface.getCoordSvgTranslation(),I=(0,C.getRubberBandRect)(this.startPoint,this.endPoint,this.xyDirection,this.parentSurface.seriesViewRect),V=I.x,z=I.right,G=I.y,H=I.bottom;this.selectionRect.isHidden=!this.allowDragSelect,this.selectionRect.x1=(0,f.translateToNotScaled)(V+F.x),this.selectionRect.x2=(0,f.translateToNotScaled)(z+F.x),this.selectionRect.y1=(0,f.translateToNotScaled)(G+F.y),this.selectionRect.y2=(0,f.translateToNotScaled)(H+F.y)}},R.prototype.modifierMouseUp=function(M){if(A.prototype.modifierMouseUp.call(this,M),!!this.checkExecuteConditions(M).isPrimary){if(!this.isAttached)throw new Error("Should not call DataPointSelectionModifier.modifierMouseUp if not attached");if(this.isClicked){var D=this.parentSurface.seriesViewRect;this.endPoint=(0,f.translateFromCanvasToSeriesViewRect)(a.Rect.clipPointToRect(M.mousePoint,D),D);var F=(0,C.getRubberBandRect)(this.startPoint,this.endPoint,this.xyDirection,this.parentSurface.seriesViewRect),I=F.width>=3&&F.height>=3&&this.allowDragSelect,V=this.getSelectionMode(M,I);I&&this.allowDragSelect?this.selectManyPoints(F,V):this.allowClickSelect&&this.selectSinglePoint(M.mousePoint,V),this.isClicked=!1,this.selectionRect.isHidden=!0}}},Object.defineProperty(R.prototype,"selectionStrokeThickness",{get:function(){return this.selectionStrokeThicknessProperty},set:function(M){this.selectionStrokeThicknessProperty=M,this.notifyPropertyChanged(b.PROPERTY.SELECTION_STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"selectionStroke",{get:function(){return this.selectionStrokeProperty},set:function(M){this.selectionStrokeProperty=M,this.notifyPropertyChanged(b.PROPERTY.SELECTION_STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(R.prototype,"selectionFill",{get:function(){return this.selectionFillProperty},set:function(M){this.selectionFillProperty=M,this.notifyPropertyChanged(b.PROPERTY.SELECTION_FILL)},enumerable:!1,configurable:!0}),R.prototype.getSelectionMode=function(M,D){return M.ctrlKey?P.Union:M.shiftKey?P.Inverse:P.Replace},R.prototype.toJSON=function(){var M=A.prototype.toJSON.call(this),D={allowClickSelect:this.allowClickSelect,allowDragSelect:this.allowDragSelect,getSelectionMode:this.typeMap.get("getSelectionMode"),onSelectionChanged:this.typeMap.get("onSelectionChanged"),selectionFill:this.selectionFill,selectionStroke:this.selectionStroke,selectionStrokeThickness:this.selectionStrokeThickness};return Object.assign(M.options,D),M},R.prototype.delete=function(){this.selectionChanged.unsubscribeAll(),this.selectionRect=(0,n.deleteSafe)(this.selectionRect),A.prototype.delete.call(this)},R.prototype.selectManyPoints=function(M,D){var F=this;if(this.parentSurface){var I=D!==P.Replace;I||this.deselectAllPoints(!1),this.getIncludedRenderableSeries().filter(function(V){return V.isVisible&&V.dataSeries}).forEach(function(V,z){var G=V.xAxis.getCurrentCoordinateCalculator(),H=V.yAxis.getCurrentCoordinateCalculator(),U,k;G.getDataValue(M.left)<=G.getDataValue(M.right)?(U=G.getDataValue(M.left),k=G.getDataValue(M.right)):(U=G.getDataValue(M.right),k=G.getDataValue(M.left));var X,W;if(H.getDataValue(M.top)<=H.getDataValue(M.bottom)?(X=H.getDataValue(M.top),W=H.getDataValue(M.bottom)):(X=H.getDataValue(M.bottom),W=H.getDataValue(M.top)),V.dataSeries.type!==p.EDataSeriesType.HeatmapUniform){var Y=V.dataSeries,te=0,oe=Y.count();if(Y.dataDistributionCalculator.isSortedAscending){var de=Y.getIndicesRange(new o.NumberRange(U,k),G.isCategoryCoordinateCalculator,c.ESearchMode.RoundDown,c.ESearchMode.RoundUp);te=de.min,oe=de.max}for(var ge=(0,h.vectorToArrayViewF64)(Y.getNativeXValues(),Y.webAssemblyContext),Ee=(0,h.vectorToArrayViewF64)(Y.getNativeYValues(),Y.webAssemblyContext),Re=te;Re<oe;Re++){var Ae=ge[Re],Pe=Ee[Re];if((0,d.testIsInBounds)(Ae,Pe,U,W,k,X)){var we=Y.getMetadataAt(Re);D!==P.Inverse?(we.isSelected=!0,F.addSelectedDataPoint(V,Re,new S.DataPointInfo(V,we,Re))):we.isSelected?(we.isSelected=!1,F.removeSelectedDataPoint(V,Re)):(we.isSelected=!0,F.addSelectedDataPoint(V,Re,new S.DataPointInfo(V,we,Re)))}}}}),this.raiseSelectionChanged(!0)}},R.prototype.selectSinglePoint=function(M,D){var F=this;if(this.parentSurface){var I=this.getIncludedRenderableSeries().filter(function(z){return z.isVisible&&z.dataSeries}).map(function(z){return{renderableSeries:z,hitTestInfo:z.hitTestProvider.hitTestForDataPointSelectionModifier(M.x,M.y,F.hitTestRadius)}}),V=D!==P.Replace;V||this.deselectAllPoints(!1),I.forEach(function(z){var G=z.hitTestInfo,H=z.renderableSeries;if(G.isHit){if(!G.metadata){console.warn("Cannot select datapoint for series ".concat(G.seriesName,` as it does not have metadata. To solve this either:
Configure metadata when you create the series or when you add data eg renderableSeries.dataSeries = new XyDataSeries(wasmContext, { metadata: { isSelected: false }}), or:
Add the DataPointSelectionModifier after all series have had their dataSeries set.`));return}if(D===P.Union){G.metadata.isSelected=!0;var U=new S.DataPointInfo(G.associatedSeries,G.metadata,G.dataSeriesIndex);F.addSelectedDataPoint(G.associatedSeries,G.dataSeriesIndex,U)}else G.metadata.isSelected=!G.metadata.isSelected,G.metadata.isSelected?F.addSelectedDataPoint(H,G.dataSeriesIndex,new S.DataPointInfo(G.associatedSeries,G.metadata,G.dataSeriesIndex)):F.removeSelectedDataPoint(H,G.dataSeriesIndex)}}),this.raiseSelectionChanged(!0)}},R.prototype.deselectAllPoints=function(M){M===void 0&&(M=!0),this.selectedDataPoints.forEach(function(D){D.renderableSeries&&D.metadata&&(D.metadata.isSelected=!1)}),this.clearSelectedDataPoints(),M&&this.raiseSelectionChanged(!0)},R.prototype.selectPoint=function(M,D){var F=M.dataSeries.getMetadataAt(D);F.isSelected=!0,this.addSelectedDataPoint(M,D,new S.DataPointInfo(M,F,D))},R.prototype.addSelectedDataPoint=function(M,D,F){F||(F=new S.DataPointInfo(M,M.dataSeries.getMetadataAt(D),D)),this.selectedDataPointsMap.set(E(M,D),F),this.selectionHasChanged=!0},R.prototype.removeSelectedDataPoint=function(M,D){this.selectedDataPointsMap.delete(E(M,D)),this.selectionHasChanged=!0},R.prototype.clearSelectedDataPoints=function(){this.selectedDataPointsMap.size>0&&(this.selectionHasChanged=!0),this.selectedDataPointsMap.clear()},R.prototype.removeSelectedDataPointsForSeries=function(M){var D=this;this.selectedDataPointsMap.forEach(function(F,I){F.renderableSeries===M&&(D.selectedDataPointsMap.delete(I),D.selectionHasChanged=!0)})},R.prototype.raiseSelectionChanged=function(M){var D;this.selectionHasChanged&&(this.selectionChanged.raiseEvent(new _.DataPointSelectionChangedArgs(this,this.selectedDataPoints)),this.selectionHasChanged=!1,M&&((D=this.parentSurface)===null||D===void 0||D.invalidateElement()))},R})(m.ChartModifierBase2D);t.DataPointSelectionModifier=x;var E=function(A,R){return"".concat(A.id,"_").concat(R)}})($F)),$F}var _b={},eE={},dbe;function YBe(){if(dbe)return eE;dbe=1;var t=eE&&eE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(eE,"__esModule",{value:!0}),eE.SciChartLegend=void 0;var e=pa(),i=zy(),n=(function(r){t(o,r);function o(){var a=r!==null&&r.apply(this,arguments)||this;return a.type=i.ELegendType.SciChartLegend,a.showCheckboxesProperty=!1,a.showSeriesMarkersProperty=!0,a}return o.prototype.applyTheme=function(){},Object.defineProperty(o.prototype,"showCheckboxes",{get:function(){return this.showCheckboxesProperty},set:function(a){this.showCheckboxesProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"showSeriesMarkers",{get:function(){return this.showSeriesMarkersProperty},set:function(a){this.showSeriesMarkersProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),o.prototype.setRenderableSeriesArray=function(a){this.renderableSeriesArray=a,this.invalidateLegend()},o.prototype.addEventListeners=function(){var a=this;this.renderableSeriesArray.forEach(function(s){return a.addEventListenerToSeries(s)})},o.prototype.removeEventListeners=function(){var a=this;this.renderableSeriesArray.forEach(function(s){return a.removeEventListenerFromSeries(s.id)})},o.prototype.addEventListenerToSeries=function(a){var s=this,l=this.parentDiv.querySelector("[id='".concat(a.id,"']"));if(l){var u=function(h){a.isVisible=h.target.checked,s.legendItemCheckedChangedCallback&&s.legendItemCheckedChangedCallback(a,a.isVisible)};l.addEventListener("change",u);var c=function(h){s.invalidateLegend()};a.isVisibleChanged.subscribe(c);var d={element:l,eventType:"change",eventListener:u,delete:function(){l.removeEventListener("change",u),a.isVisibleChanged.unsubscribe(c)}},f=this.eventListenersCollection.get(a.id);f?f.push(d):this.eventListenersCollection.set(a.id,[d])}},o.prototype.getInnerHTML=function(){var a,s,l,u,c,d,f=(a=this.backgroundColor)!==null&&a!==void 0?a:(l=(s=this.parentSurfaceProperty)===null||s===void 0?void 0:s.themeProvider)===null||l===void 0?void 0:l.legendBackgroundBrush,h=(u=this.textColor)!==null&&u!==void 0?u:(d=(c=this.parentSurfaceProperty)===null||c===void 0?void 0:c.themeProvider)===null||d===void 0?void 0:d.labelForegroundBrush,p=this.renderableSeriesArray.map(function(_,C){var P;return{id:_.id,name:(P=_.seriesName)!==null&&P!==void 0?P:"Series ".concat(C+1),color:_.isStacked?_.fill:_.stroke,checked:_.isVisible,gradient:void 0}}),g=this.parentSurfaceProperty.getSeriesViewRectPadding(!1),v=g.left,y=g.top,m=g.right,b=g.bottom,S=this.isExternal()?new e.Thickness(this.margin,this.margin,this.margin,this.margin):new e.Thickness(y+this.margin,m+this.margin,b+this.margin,v+this.margin);return this.getLegendHTML(this.placement,h,f,S,this.orientation,this.showCheckboxes,this.showSeriesMarkers,p)},o})(i.SciChartLegendBase);return eE.SciChartLegend=n,eE}var fbe;function Eie(){if(fbe)return _b;fbe=1;var t=_b&&_b.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=_b&&_b.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(_b,"__esModule",{value:!0}),_b.LegendModifier=void 0;var i=ps(),n=Ho(),r=YBe(),o=Qu(),a=(function(s){t(l,s);function l(u){var c=this,d;return c=s.call(this,u)||this,c._legendOptions={},c.type=n.EChart2DModifierType.Legend,c.isCheckedChanged=new i.EventHandler,c._legendOptions=e({},u),c.legendItemCheckedChanged=c.legendItemCheckedChanged.bind(c),c.sciChartLegend=(d=u==null?void 0:u.legend)!==null&&d!==void 0?d:new r.SciChartLegend(u),c.applyLegendOptions(c.sciChartLegend,u),c}return l.prototype.applyLegendOptions=function(u,c){var d,f,h,p,g,v;u.showCheckboxes=(d=c==null?void 0:c.showCheckboxes)!==null&&d!==void 0?d:u.showCheckboxes,u.showSeriesMarkers=(f=c==null?void 0:c.showSeriesMarkers)!==null&&f!==void 0?f:u.showSeriesMarkers,u.margin=(h=c==null?void 0:c.margin)!==null&&h!==void 0?h:u.margin,u.orientation=(p=c==null?void 0:c.orientation)!==null&&p!==void 0?p:u.orientation,u.placement=(g=c==null?void 0:c.placement)!==null&&g!==void 0?g:u.placement,u.showLegend=(v=c==null?void 0:c.showLegend)!==null&&v!==void 0?v:u.showLegend,u.legendItemCheckedChangedCallback=this.legendItemCheckedChanged,c!=null&&c.isCheckedChangedCallback&&this.isCheckedChanged.subscribe(function(y){return c.isCheckedChangedCallback(y.series,y.isChecked,u)})},l.prototype.applyTheme=function(u){var c;s.prototype.applyTheme.call(this,u),(c=this.sciChartLegend)===null||c===void 0||c.applyTheme()},l.prototype.onAttachSeries=function(u){s.prototype.onAttachSeries.call(this,u),this.sciChartLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries())},l.prototype.onDetachSeries=function(u){s.prototype.onDetachSeries.call(this,u),this.sciChartLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries())},l.prototype.onParentSurfaceRendered=function(){s.prototype.onParentSurfaceRendered.call(this)},l.prototype.onAttach=function(){var u;s.prototype.onAttach.call(this),this.sciChartLegend||(this.sciChartLegend=(u=this._legendOptions.legend)!==null&&u!==void 0?u:new r.SciChartLegend(this._legendOptions),this.applyLegendOptions(this.sciChartLegend,this._legendOptions)),this.sciChartLegend.attachTo(this.parentSurface),this.sciChartLegend.setInvalidateParentSurface(this.parentSurface.invalidateElement),this.sciChartLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries())},l.prototype.onDetach=function(){var u,c;this.sciChartLegend&&(this._legendOptions.margin=this.sciChartLegend.margin,this._legendOptions.orientation=this.sciChartLegend.orientation,this._legendOptions.placement=this.sciChartLegend.placement,this._legendOptions.showCheckboxes=this.sciChartLegend.showCheckboxes,this._legendOptions.showLegend=this.sciChartLegend.showLegend,this._legendOptions.showSeriesMarkers=this.sciChartLegend.showSeriesMarkers),s.prototype.onDetach.call(this),(u=this.sciChartLegend)===null||u===void 0||u.setRenderableSeriesArray([]),(c=this.sciChartLegend)===null||c===void 0||c.detach(),this.sciChartLegend=void 0},l.prototype.includeSeries=function(u,c){var d;return s.prototype.includeSeries.call(this,u,c)?(this.isAttached&&this.sciChartLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries()),(d=this.parentSurface)===null||d===void 0||d.invalidateElement(),!0):!1},l.prototype.testIsIncludedSeries=function(u){return this.includedSeries.testIsIncluded(u.id)},l.prototype.toJSON=function(){var u=s.prototype.toJSON.call(this),c={margin:this.sciChartLegend.margin,orientation:this.sciChartLegend.orientation,placement:this.sciChartLegend.placement,showCheckboxes:this.sciChartLegend.showCheckboxes,showLegend:this.sciChartLegend.showLegend,showSeriesMarkers:this.sciChartLegend.showSeriesMarkers};return Object.assign(u.options,c),u},l.prototype.delete=function(){s.prototype.delete.call(this),this.onDetach()},l.prototype.legendItemCheckedChanged=function(u,c){var d;(d=this.isCheckedChanged)===null||d===void 0||d.raiseEvent({series:u,isChecked:c})},l})(o.ChartModifierBase2D);return _b.LegendModifier=a,_b}var KF={},hbe;function r$(){return hbe||(hbe=1,(function(t){var e=KF&&KF.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.MouseWheelZoomModifier=t.EActionType=void 0;var i=uR(),n=Ho(),r=pl(),o=xm(),a=An(),s=Vv(),l=Qu(),u;(function(d){d.Zoom="Zoom",d.Pan="Pan"})(u=t.EActionType||(t.EActionType={}));var c=(function(d){e(f,d);function f(h){var p=this,g,v,y,m,b;return p=d.call(this,h)||this,p.type=n.EChart2DModifierType.MouseWheelZoom,p.growFactor=.001,p.actionType=u.Zoom,p.applyToSeriesViewRect=!0,p.applyToAxes=!0,p.growFactor=(g=h==null?void 0:h.growFactor)!==null&&g!==void 0?g:p.growFactor,p.actionType=(v=h==null?void 0:h.actionType)!==null&&v!==void 0?v:p.actionType,p.applyToSeriesViewRect=(y=h==null?void 0:h.applyToSeriesViewRect)!==null&&y!==void 0?y:p.applyToSeriesViewRect,p.applyToAxes=(m=h==null?void 0:h.applyToAxes)!==null&&m!==void 0?m:p.applyToAxes,p.actionType===u.Pan&&p.xyDirection===r.EXyDirection.XyDirection&&(console.warn("SciChart MouseWheelZoomModifier: actionType=Pan and xyDirection=Xy conflict. Auto setting XyDirection to X"),p.xyDirection=r.EXyDirection.XDirection),p.executeCondition=(b=h==null?void 0:h.executeCondition)!==null&&b!==void 0?b:{button:void 0,key:i.EModifierMouseArgKey.None},p}return f.prototype.modifierMouseWheel=function(h){var p=this;if(this.checkExecuteConditions(h).isPrimary){d.prototype.modifierMouseWheel.call(this,h);var g=(0,a.translateFromCanvasToSeriesViewRect)(h.mousePoint,this.parentSurface.seriesViewRect);if(g&&this.applyToSeriesViewRect)this.actionType===u.Zoom?h.handled=this.performZoom(g,h.mouseWheelDelta):this.actionType===u.Pan&&(h.handled=this.performPan(h.mouseWheelDelta));else if(this.applyToAxes){var v=[];[r.EXyDirection.XDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&v.push.apply(v,this.getIncludedXAxis()),[r.EXyDirection.YDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&v.push.apply(v,this.getIncludedYAxis());var y=(0,l.getActiveAxes)(v,h.mousePoint);if(y.length>0)if(h.handled=!0,this.actionType===u.Zoom){var m=this.growFactor*h.mouseWheelDelta,b=(0,a.translateFromCanvasToSeriesViewRect)(h.mousePoint,this.parentSurface.seriesViewRect,!0);y.forEach(function(S){p.growBy(b,S,m)})}else this.actionType===u.Pan&&y.forEach(function(S){var _=p.getAxisSize(S),C=h.mouseWheelDelta*p.growFactor*_;S.scroll(C,s.EClipMode.None)})}h.handled&&this.parentSurface.setZoomState(o.EZoomState.UserZooming)}},f.prototype.performZoom=function(h,p){var g=this,v=this.growFactor*p,y=!1;return[r.EXyDirection.XDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedXAxis().forEach(function(m){g.growBy(h,m,v),y=!0}),[r.EXyDirection.YDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedYAxis().forEach(function(m){g.growBy(h,m,v),y=!0}),y},f.prototype.performPan=function(h){var p=this,g=!1;return[r.EXyDirection.XDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedXAxis().forEach(function(v){var y=p.getAxisSize(v),m=h*p.growFactor*y;v.scroll(m,s.EClipMode.None),g=!0}),[r.EXyDirection.YDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedYAxis().forEach(function(v){var y=p.getAxisSize(v),m=h*p.growFactor*y;v.scroll(m,s.EClipMode.None),g=!0}),g},f.prototype.toJSON=function(){var h=d.prototype.toJSON.call(this),p={actionType:this.actionType,growFactor:this.growFactor,applyToSeriesViewRect:this.applyToSeriesViewRect,applyToAxes:this.applyToAxes};return Object.assign(h.options,p),h},f.prototype.getAxisSize=function(h){var p=h.isHorizontalAxis?h.viewRect.width:h.viewRect.height;return Math.abs(p)<1e-8&&this.parentSurface&&(p=h.isHorizontalAxis?this.parentSurface.seriesViewRect.width:this.parentSurface.seriesViewRect.height),p},f})(l.ChartModifierBase2D);t.MouseWheelZoomModifier=c})(KF)),KF}var Pb={},vo={},pbe;function Ku(){if(pbe)return vo;pbe=1,Object.defineProperty(vo,"__esModule",{value:!0}),vo.convertCoordinateFromRelativeValue=vo.convertCoordinateFromPixelValue=vo.convertCoordinateFromDataValue=vo.convertToRelativeCoordinate=vo.convertToPixelCoordinate=vo.convertToDataValue=vo.convertCoordinateMode=vo.convertFromAbsoluteCoordinate=vo.convertAbsoluteCoordinateToRelativeValue=vo.convertAbsoluteCoordinateToPixelValue=vo.convertAbsoluteCoordinateToDataValue=vo.convertToAbsoluteCoordinate=vo.convertRelativeValueToAbsoluteCoordinate=vo.convertPixelValueToAbsoluteCoordinate=vo.convertDataValueToAbsoluteCoordinate=vo.subtractCoord=vo.addCoord=void 0;var t=Ca(),e=An();function i(b,S){return b+S}vo.addCoord=i;function n(b,S){return b-S}vo.subtractCoord=n;function r(b,S){return S.getCoordinate(b)}vo.convertDataValueToAbsoluteCoordinate=r;function o(b){return(0,e.translateToScaled)(b)}vo.convertPixelValueToAbsoluteCoordinate=o;function a(b,S){return b*S.viewportDimension}vo.convertRelativeValueToAbsoluteCoordinate=a;function s(b,S,_){switch(_){case t.ECoordinateMode.DataValue:return r(b,S);case t.ECoordinateMode.Pixel:return o(b);case t.ECoordinateMode.Relative:return a(b,S);default:throw new Error('Unexpected coordinate mode: "'.concat(_,'"!'))}}vo.convertToAbsoluteCoordinate=s;function l(b,S){return S.getDataValue(b)}vo.convertAbsoluteCoordinateToDataValue=l;function u(b){return(0,e.translateToNotScaled)(b)}vo.convertAbsoluteCoordinateToPixelValue=u;function c(b,S){return b/S.viewportDimension}vo.convertAbsoluteCoordinateToRelativeValue=c;function d(b,S,_){switch(_){case t.ECoordinateMode.DataValue:return l(b,S);case t.ECoordinateMode.Pixel:return u(b);case t.ECoordinateMode.Relative:return c(b,S);default:throw new Error('Unexpected coordinate mode: "'.concat(_,'"!'))}}vo.convertFromAbsoluteCoordinate=d;function f(b,S,_,C){if(_===C)return b;var P=s(b,S,_);return d(P,S,C)}vo.convertCoordinateMode=f;function h(b,S,_){return f(b,S,_,t.ECoordinateMode.DataValue)}vo.convertToDataValue=h;function p(b,S,_){return f(b,S,_,t.ECoordinateMode.Pixel)}vo.convertToPixelCoordinate=p;function g(b,S,_){return f(b,S,_,t.ECoordinateMode.Relative)}vo.convertToRelativeCoordinate=g;function v(b,S,_){return f(b,S,t.ECoordinateMode.DataValue,_)}vo.convertCoordinateFromDataValue=v;function y(b,S,_){return f(b,S,t.ECoordinateMode.Pixel,_)}vo.convertCoordinateFromPixelValue=y;function m(b,S,_){return f(b,S,t.ECoordinateMode.Relative,_)}return vo.convertCoordinateFromRelativeValue=m,vo}var tE={},ZF={},gbe;function rAt(){if(gbe)return ZF;gbe=1,Object.defineProperty(ZF,"__esModule",{value:!0}),ZF.TypedPoint=void 0;var t=(function(){function e(i,n){this.x=i,this.y=n}return e})();return ZF.TypedPoint=t,ZF}var vbe;function qBe(){if(vbe)return tE;vbe=1;var t=tE&&tE.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(tE,"__esModule",{value:!0}),tE.OverviewCustomResizableAnnotation=void 0;var e=rAt(),i=Ku(),n=pl(),r=Eo(),o=An(),a=Ca(),s=gl(),l=jl(),u=Gre(),c=a.ECoordinateMode.DataValue,d=(function(h){t(p,h);function p(g){var v=this,y,m,b;return v=h.call(this,g)||this,v.minWidthProperty=10,v.minHeightProperty=10,v.adornerSvgStringTemplateProperty=(y=g==null?void 0:g.adornerSvgStringTemplate)!==null&&y!==void 0?y:v.adornerSvgStringTemplateProperty,v.minWidthProperty=(m=g==null?void 0:g.minWidth)!==null&&m!==void 0?m:v.minWidthProperty,v.minHeightProperty=(b=g==null?void 0:g.minHeight)!==null&&b!==void 0?b:v.minHeightProperty,v}return Object.defineProperty(p.prototype,"minWidth",{get:function(){return this.minWidthProperty},set:function(g){this.minWidthProperty=g,this.notifyPropertyChanged(l.PROPERTY.MINIMUM_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"minHeight",{get:function(){return this.minHeightProperty},set:function(g){this.minHeightProperty=g,this.notifyPropertyChanged(l.PROPERTY.MINIMUM_HEIGHT)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"adornerSvgStringTemplate",{get:function(){return this.adornerSvgStringTemplateProperty},set:function(g){this.adornerSvgStringTemplateProperty=g,this.notifyPropertyChanged(l.PROPERTY.ADORNER_TEMPLATE)},enumerable:!1,configurable:!0}),p.prototype.setCoordinates=function(g){var v,y,m,b;if(this.parentSurface){var S=this.xAxis,_=S.getCurrentCoordinateCalculator(),C=this.yAxis,P=C.getCurrentCoordinateCalculator(),x=(0,i.convertCoordinateMode)(this.x1,_,this.xCoordinateMode,c),E=(0,i.convertCoordinateMode)(this.x2,_,this.xCoordinateMode,c),A=(0,i.convertCoordinateMode)(this.y1,P,this.yCoordinateMode,c),R=(0,i.convertCoordinateMode)(this.y2,P,this.yCoordinateMode,c),M=g.x1,D=M===void 0?x:M,F=g.x2,I=F===void 0?E:F,V=g.y1,z=V===void 0?A:V,G=g.y2,H=G===void 0?R:G,U=this.convertPointToAbsoluteCoordinates(new e.TypedPoint(D,z),c,c),k=this.convertPointToAbsoluteCoordinates(new e.TypedPoint(I,H),c,c),X=S.isHorizontalAxis?_:P,W=C.isHorizontalAxis?_:P,Y=X.hasFlippedCoordinates?D:I,te=X.hasFlippedCoordinates?I:D,oe=W.hasFlippedCoordinates?D:I,de=W.hasFlippedCoordinates?I:D,ge=(0,i.convertToAbsoluteCoordinate)(Y,X,c),Ee=(0,i.convertToAbsoluteCoordinate)(te,X,c),Re=(0,i.convertToAbsoluteCoordinate)(oe,W,c),Ae=(0,i.convertToAbsoluteCoordinate)(de,W,c),Pe=this.isVerticalChart?new e.TypedPoint(Re,ge):new e.TypedPoint(ge,Re),we=this.isVerticalChart?new e.TypedPoint(Ae,Ee):new e.TypedPoint(Ee,Ae);S.isHorizontalAxis?D-x>=E-I?(this.x2=(v=(0,i.convertFromAbsoluteCoordinate)(k.x,_,this.xCoordinateMode))!==null&&v!==void 0?v:this.x2,_.hasFlippedCoordinates?this.adjustLeftSideToLimits(k.x,Pe,_):this.adjustRightSideToLimits(k.x,we,_)):(this.x1=(y=(0,i.convertFromAbsoluteCoordinate)(U.x,_,this.xCoordinateMode))!==null&&y!==void 0?y:this.x1,_.hasFlippedCoordinates?this.adjustRightSideToLimits(U.x,we,_):this.adjustLeftSideToLimits(U.x,Pe,_)):(0,i.subtractCoord)(D,x)>=(0,i.subtractCoord)(E,I)?(this.x2=(m=(0,i.convertFromAbsoluteCoordinate)(k.y,_,this.xCoordinateMode))!==null&&m!==void 0?m:this.x2,_.hasFlippedCoordinates?this.adjustTopSideToLimits(k.y,Pe,_):this.adjustBottomSideToLimits(k.y,we,_)):(this.x1=(b=(0,i.convertFromAbsoluteCoordinate)(U.y,_,this.xCoordinateMode))!==null&&b!==void 0?b:this.x1,_.hasFlippedCoordinates?this.adjustBottomSideToLimits(U.y,we,_):this.adjustTopSideToLimits(U.y,Pe,_))}},p.prototype.onDragStarted=function(g){var v;g.nativeEvent.preventDefault(),(v=this.dragStarted)===null||v===void 0||v.raiseEvent();var y=this.getAnnotationBorders(!0),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=(0,o.translateFromCanvasToSeriesViewRect)(new e.TypedPoint(g.mousePoint.x,g.mousePoint.y),this.parentSurface.seriesViewRect,!0);if(!C)return!1;var P=(0,o.translateToNotScaled)(C.x),x=(0,o.translateToNotScaled)(C.y),E=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.XDirection:this.resizeDirections!==n.EXyDirection.YDirection,A=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.YDirection:this.resizeDirections!==n.EXyDirection.XDirection;if(E){if((0,r.testIsInBounds)(P,x,m-l.ADORNER_GRIP_RADIUS,_,m+l.ADORNER_GRIP_RADIUS,S))return this.adornerDraggingPoint=a.EDraggingGripPoint.x1y1,!0;if((0,r.testIsInBounds)(P,x,b-l.ADORNER_GRIP_RADIUS,_,b+l.ADORNER_GRIP_RADIUS,S))return this.adornerDraggingPoint=a.EDraggingGripPoint.x2y2,!0}if(A){if((0,r.testIsInBounds)(P,x,m,S+l.ADORNER_GRIP_RADIUS,b,S-l.ADORNER_GRIP_RADIUS))return this.adornerDraggingPoint=a.EDraggingGripPoint.x2y1,!0;if((0,r.testIsInBounds)(P,x,m,_+l.ADORNER_GRIP_RADIUS,b,_-l.ADORNER_GRIP_RADIUS))return this.adornerDraggingPoint=a.EDraggingGripPoint.x1y2,!0}return this.clickToSelect(g)?(this.adornerDraggingPoint=a.EDraggingGripPoint.Body,!0):!1},p.prototype.update=function(g,v,y,m){this.create(g,v,y,m),this.svg.style.display=this.isHidden?"none":"block",this.svg.style.opacity=this.opacity.toString();var b=this.getX1Coordinate(g,v),S=this.getY1Coordinate(g,v),_=this.getX2Coordinate(g,v),C=this.getY2Coordinate(g,v);if(this.setAnnotationBorders(b,_,S,C),isNaN(b)||isNaN(S)||!isFinite(b)||!isFinite(S)||isNaN(_)||isNaN(C)||!isFinite(_)||!isFinite(C))this.svg.style.display="none";else{var P=Math.abs(_-b),x=Math.abs(C-S),E=(b<_?b:_)+y,A=(S<C?S:C)+m;this.setSvgAttribute("x",E),this.setSvgAttribute("y",A),this.setSvgAttribute("width",P),this.setSvgAttribute("height",x),this.svgDOMRect=this.svg.getBoundingClientRect()}this.updateAdornerInner()},p.prototype.calcDragDistance=function(g){var v=this.xAxis,y=v.getCurrentCoordinateCalculator(),m=this.yAxis,b=m.getCurrentCoordinateCalculator(),S=v.isHorizontalAxis?y:b,_=m.isHorizontalAxis?y:b,C=this.convertPointToAbsoluteCoordinates(new e.TypedPoint(this.x1,this.y1),this.xCoordinateMode,this.yCoordinateMode),P=C.x,x=C.y,E=this.convertPointToAbsoluteCoordinates(new e.TypedPoint(this.x2,this.y2),this.xCoordinateMode,this.yCoordinateMode),A=E.x,R=E.y,M=this.convertPointToAbsoluteCoordinates(g,this.xCoordinateMode,this.yCoordinateMode),D=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.XDirection:this.resizeDirections!==n.EXyDirection.YDirection,F=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.YDirection:this.resizeDirections!==n.EXyDirection.XDirection;switch(this.adornerDraggingPoint){case a.EDraggingGripPoint.Body:{if(!this.prevValue){this.prevValue=g;return}var I=this.x1-(this.prevValue.x-g.x),V=this.x2-(this.prevValue.x-g.x),z=this.y1-(this.prevValue.y-g.y),G=this.y2-(this.prevValue.y-g.y),H=(0,i.convertToAbsoluteCoordinate)(I,y,this.xCoordinateMode),U=(0,i.convertToAbsoluteCoordinate)(V,y,this.xCoordinateMode),k=(0,i.convertToAbsoluteCoordinate)(z,b,this.yCoordinateMode),X=(0,i.convertToAbsoluteCoordinate)(G,b,this.yCoordinateMode),W=(0,i.convertAbsoluteCoordinateToDataValue)(H,y),Y=(0,i.convertAbsoluteCoordinateToDataValue)(U,y),te=(0,i.convertAbsoluteCoordinateToDataValue)(k,b),oe=(0,i.convertAbsoluteCoordinateToDataValue)(X,b),de=(0,i.convertDataValueToAbsoluteCoordinate)(v.visibleRange.min,y),ge=(0,i.convertDataValueToAbsoluteCoordinate)(v.visibleRange.max,y),Ee=(0,i.convertDataValueToAbsoluteCoordinate)(m.visibleRange.min,b),Re=(0,i.convertDataValueToAbsoluteCoordinate)(m.visibleRange.max,b),Ae=(0,i.convertFromAbsoluteCoordinate)(de,y,this.xCoordinateMode),Pe=(0,i.convertFromAbsoluteCoordinate)(ge,y,this.xCoordinateMode),we=(0,i.convertFromAbsoluteCoordinate)(Ee,b,this.yCoordinateMode),Te=(0,i.convertFromAbsoluteCoordinate)(Re,b,this.yCoordinateMode);if(this.resizeDirections!==n.EXyDirection.YDirection)if(W<v.visibleRange.min){var ke=(0,i.subtractCoord)(H,de);this.x1=Ae,this.x2=(0,i.convertFromAbsoluteCoordinate)((0,i.subtractCoord)(U,ke),y,this.xCoordinateMode)}else if(Y>v.visibleRange.max){var ke=(0,i.subtractCoord)(ge,U);this.x1=(0,i.convertFromAbsoluteCoordinate)((0,i.addCoord)(H,ke),y,this.xCoordinateMode),this.x2=Pe}else this.x1=I,this.x2=V;if(this.resizeDirections!==n.EXyDirection.XDirection)if(oe>m.visibleRange.max){var ke=(0,i.subtractCoord)(X,Re);this.y2=Te,this.y1=(0,i.convertFromAbsoluteCoordinate)((0,i.addCoord)(k,ke),b,this.yCoordinateMode)}else if(te<m.visibleRange.min){var ke=(0,i.subtractCoord)(k,Ee);this.y2=(0,i.convertFromAbsoluteCoordinate)((0,i.subtractCoord)(X,ke),b,this.yCoordinateMode),this.y1=we}else this.y1=z,this.y2=G;this.prevValue=g;break}case a.EDraggingGripPoint.x1y1:{D&&(S.hasFlippedCoordinates?this.adjustLeftSideToLimits(A,M,S):this.adjustLeftSideToLimits(P,M,S));break}case a.EDraggingGripPoint.x2y2:{D&&(S.hasFlippedCoordinates?this.adjustRightSideToLimits(P,M,S):this.adjustRightSideToLimits(A,M,S));break}case a.EDraggingGripPoint.x2y1:{F&&(_.hasFlippedCoordinates?this.adjustTopSideToLimits(R,M,_):this.adjustTopSideToLimits(x,M,_));break}case a.EDraggingGripPoint.x1y2:{F&&(_.hasFlippedCoordinates?this.adjustBottomSideToLimits(x,M,_):this.adjustBottomSideToLimits(R,M,_));break}default:throw new Error("Unexpected adornerDraggingPoint value ".concat(this.adornerDraggingPoint))}},p.prototype.create=function(g,v,y,m){if(!this.svg){var b=this.applyClipping(this.svgString,this.clipping);this.setSvg(s.annotationHelpers.createSvg(b,this.svgRoot,this.nextSibling));var S=this.svg.getBBox(),_=this.getX1Coordinate(g,v),C=this.getY1Coordinate(g,v);this.isVerticalChart?(this.x2===void 0&&(this.x2=this.getValue(_+S.width,g,a.ECoordinateMode.Pixel)),this.y2===void 0&&(this.y2=this.getValue(C+S.height,v,a.ECoordinateMode.Pixel))):(this.x2===void 0&&(this.x2=this.getValue(C+S.height,g,a.ECoordinateMode.Pixel)),this.y2===void 0&&(this.y2=this.getValue(_+S.width,v,a.ECoordinateMode.Pixel)));var P=this.getX2Coordinate(g,v),x=this.getY2Coordinate(g,v),E=Math.abs(P-_),A=Math.abs(x-C);if(this.isVerticalChart){if(E<this.minWidth){var R=this.isVerticalChart?v:g;this.y2=this.getValue(_+this.minWidth,R,a.ECoordinateMode.Pixel)}if(A<this.minHeight){var M=this.isVerticalChart?g:v;this.x2=this.getValue(C+this.minHeight,M,a.ECoordinateMode.Pixel)}}else{if(E<this.minWidth){var R=this.isVerticalChart?v:g;this.x2=this.getValue(_+this.minWidth,R,a.ECoordinateMode.Pixel)}if(A<this.minHeight){var M=this.isVerticalChart?g:v;this.y2=this.getValue(C+this.minHeight,M,a.ECoordinateMode.Pixel)}}}},p.prototype.updateAdornerInner=function(){if(this.deleteAdorner(),this.adornerSvgStringTemplate){var g=this.getAdornerAnnotationBorders(!0),v=g.x1,y=g.x2,m=g.y1,b=g.y2,S=this.adornerSvgStringTemplate(v,m,y,b),_=this.applySvgClipping(S,this.adornerClipping);this.svgAdorner=s.annotationHelpers.createSvg(_,this.svgAdornerRoot)}},p.prototype.checkIsClickedOnAnnotationInternal=function(g,v){var y=this.getAnnotationBorders(!0),m=y.x1,b=y.x2,S=y.y1,_=y.y2,C=(0,o.translateToNotScaled)(g),P=(0,o.translateToNotScaled)(v);if((0,r.testIsInBounds)(C,P,m,_,b,S))return!0;var x=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.XDirection:this.resizeDirections!==n.EXyDirection.YDirection,E=this.isVerticalChart?this.resizeDirections!==n.EXyDirection.YDirection:this.resizeDirections!==n.EXyDirection.XDirection;if(x){if((0,r.testIsInBounds)(C,P,m-l.ADORNER_GRIP_RADIUS,_,m+l.ADORNER_GRIP_RADIUS,S))return!0;if((0,r.testIsInBounds)(C,P,b-l.ADORNER_GRIP_RADIUS,_,b+l.ADORNER_GRIP_RADIUS,S))return!0}if(E){if((0,r.testIsInBounds)(C,P,m,S+l.ADORNER_GRIP_RADIUS,b,S-l.ADORNER_GRIP_RADIUS))return!0;if((0,r.testIsInBounds)(C,P,m,_+l.ADORNER_GRIP_RADIUS,b,_-l.ADORNER_GRIP_RADIUS))return!0}return!1},p.prototype.adjustLeftSideToLimits=function(g,v,y){var m=this.isVerticalChart?v.y:v.x,b=f(m,y),S=g-b>=(0,o.translateToScaled)(this.minWidth),_=S?b:g-(0,o.translateToScaled)(this.minWidth),C=(0,i.convertFromAbsoluteCoordinate)(_,y,this.isVerticalChart?this.yCoordinateMode:this.xCoordinateMode);this.isVerticalChart?y.hasFlippedCoordinates?this.y1=C:this.y2=C:y.hasFlippedCoordinates?this.x1=C:this.x2=C},p.prototype.adjustRightSideToLimits=function(g,v,y){var m=this.isVerticalChart?v.y:v.x,b=f(m,y),S=b-g>=(0,o.translateToScaled)(this.minWidth),_=S?b:g+(0,o.translateToScaled)(this.minWidth),C=(0,i.convertFromAbsoluteCoordinate)(_,y,this.isVerticalChart?this.yCoordinateMode:this.xCoordinateMode);this.isVerticalChart?y.hasFlippedCoordinates?this.y2=C:this.y1=C:y.hasFlippedCoordinates?this.x2=C:this.x1=C},p.prototype.adjustTopSideToLimits=function(g,v,y){var m=this.isVerticalChart?v.x:v.y,b=f(m,y),S=g-b>=(0,o.translateToScaled)(this.minHeight),_=S?b:g-(0,o.translateToScaled)(this.minHeight),C=this.convertFromCoordinate(_,y,this.isVerticalChart?this.xCoordinateMode:this.yCoordinateMode);this.isVerticalChart?y.hasFlippedCoordinates?this.x1=C:this.x2=C:y.hasFlippedCoordinates?this.y1=C:this.y2=C},p.prototype.adjustBottomSideToLimits=function(g,v,y){var m=this.isVerticalChart?v.x:v.y,b=f(m,y),S=b-g>=(0,o.translateToScaled)(this.minHeight),_=S?b:g+(0,o.translateToScaled)(this.minHeight),C=this.convertFromCoordinate(_,y,this.isVerticalChart?this.xCoordinateMode:this.yCoordinateMode);this.isVerticalChart?y.hasFlippedCoordinates?this.x2=C:this.x1=C:y.hasFlippedCoordinates?this.y2=C:this.y1=C},p.prototype.convertPointToAbsoluteCoordinates=function(g,v,y){var m=this.xAxis,b=m.getCurrentCoordinateCalculator(),S=this.yAxis,_=S.getCurrentCoordinateCalculator(),C=(0,i.convertToAbsoluteCoordinate)(g.x,b,v),P=(0,i.convertToAbsoluteCoordinate)(g.y,_,y);return this.isVerticalChart?new e.TypedPoint(P,C):new e.TypedPoint(C,P)},p})(u.CustomAnnotation);tE.OverviewCustomResizableAnnotation=d;var f=function(h,p){return h<=0?0:h>=p.viewportDimension?p.viewportDimension:h};return tE}var ybe;function wie(){if(ybe)return Pb;ybe=1;var t=Pb&&Pb.__extends||(function(){var b=function(S,_){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(C,P){C.__proto__=P}||function(C,P){for(var x in P)Object.prototype.hasOwnProperty.call(P,x)&&(C[x]=P[x])},b(S,_)};return function(S,_){if(typeof _!="function"&&_!==null)throw new TypeError("Class extends value "+String(_)+" is not a constructor or null");b(S,_);function C(){this.constructor=S}S.prototype=_===null?Object.create(_):(C.prototype=_.prototype,new C)}})(),e=Pb&&Pb.__assign||function(){return e=Object.assign||function(b){for(var S,_=1,C=arguments.length;_<C;_++){S=arguments[_];for(var P in S)Object.prototype.hasOwnProperty.call(S,P)&&(b[P]=S[P])}return b},e.apply(this,arguments)};Object.defineProperty(Pb,"__esModule",{value:!0}),Pb.OverviewRangeSelectionModifier=void 0;var i=JV(),n=Br(),r=di(),o=Rn(),a=Lm(),s=Ho(),l=Ku(),u=pl(),c=An(),d=Ca(),f=qBe(),h=Qu(),p=(function(b){t(S,b);function S(_){var C=this,P,x,E;return C=b.call(this,_)||this,C.type=s.EChart2DModifierType.OverviewRangeSelection,C.animationDuration=1e3,C.animate=!0,C.isClicked=!1,C.onSelectedAreaChanged=_==null?void 0:_.onSelectedAreaChanged,C.xAxisId=(P=_==null?void 0:_.xAxisId)!==null&&P!==void 0?P:C.xAxisId,C.yAxisId=(x=_==null?void 0:_.yAxisId)!==null&&x!==void 0?x:C.yAxisId,C.executeCondition=(E=_==null?void 0:_.executeCondition)!==null&&E!==void 0?E:{button:a.EExecuteOn.MouseLeftButton},C}return S.prototype.onAttach=function(){var _=this;b.prototype.onAttach.call(this),this.updateSelectionAnnotation();var C=function(){_.setInitialAnnotationCoordinates(),_.parentSurface.layoutMeasured.unsubscribe(C)};this.parentSurface.layoutMeasured.subscribe(C)},S.prototype.modifierMouseDown=function(_){if(b.prototype.modifierMouseDown.call(this,_),!!this.checkExecuteConditions(_).isPrimary){if(!this.isAttached)throw new Error("Should not call OverviewRangeSelectionModifier.modifierMouseDown if not attached");var C=(0,c.translateFromCanvasToSeriesViewRect)(_.mousePoint,this.parentSurface.seriesViewRect);C&&(this.isClicked=!0)}},S.prototype.modifierMouseUp=function(_){var C=this,P;if(b.prototype.modifierMouseUp.call(this,_),!!this.checkExecuteConditions(_).isPrimary){if(!this.isAttached)throw new Error("Should not call OverviewRangeSelectionModifier.modifierMouseUp if not attached");if(this.isClicked){_.handled=!0,(P=this.overviewPositionAnimation)===null||P===void 0||P.cancel();var x=this.parentSurface.seriesViewRect;this.pointTo=(0,c.translateFromCanvasToSeriesViewRect)(o.Rect.clipPointToRect(_.mousePoint,x),x),this.isClicked=!1;var E=(0,c.translateToNotScaled)(this.xAxis.isHorizontalAxis?this.pointTo.x:this.pointTo.y),A=(0,l.subtractCoord)(E,(this.rangeSelectionAnnotation.x1+this.rangeSelectionAnnotation.x2)/2),R=new r.NumberRange(this.rangeSelectionAnnotation.x1,this.rangeSelectionAnnotation.x2),M=new r.NumberRange(this.rangeSelectionAnnotation.x1+A,this.rangeSelectionAnnotation.x2+A),D=function(F){var I,V,z,G=C.xAxis.getCurrentCoordinateCalculator(),H=C.rangeSelectionAnnotation.xCoordinateMode;(I=C.rangeSelectionAnnotation)===null||I===void 0||I.setCoordinates({x1:(0,l.convertToDataValue)(F.min,G,H),x2:(0,l.convertToDataValue)(F.max,G,H)}),C.annotationBeforeSelectedAreaProperty.x2=(V=C.rangeSelectionAnnotation)===null||V===void 0?void 0:V.x1,C.annotationAfterSelectedAreaProperty.x1=(z=C.rangeSelectionAnnotation)===null||z===void 0?void 0:z.x2,C.onSelectedAreaChanged(new r.NumberRange((0,l.convertToDataValue)(C.rangeSelectionAnnotation.x1,G,H),(0,l.convertToDataValue)(C.rangeSelectionAnnotation.x2,G,H)))};this.animate?(this.overviewPositionAnimation=i.NumberRangeAnimator.animate(R,M,this.animationDuration,D,null),this.parentSurface.addAnimation(this.overviewPositionAnimation)):D(M)}}},Object.defineProperty(S.prototype,"rangeSelectionAnnotation",{get:function(){return this.rangeSelectionAnnotationProperty},enumerable:!1,configurable:!0}),Object.defineProperty(S.prototype,"unselectedsvgString",{get:function(){return this.annotationBeforeSelectedAreaProperty.svgString},set:function(_){this.annotationBeforeSelectedAreaProperty.svgString=_,this.annotationAfterSelectedAreaProperty.svgString=_},enumerable:!1,configurable:!0}),Object.defineProperty(S.prototype,"selectedArea",{get:function(){return this.selectedAreaProperty},set:function(_){var C,P;this.selectedAreaProperty=_;var x=this.xAxis;if(x){var E=x.getCurrentCoordinateCalculator();(C=this.rangeSelectionAnnotation)===null||C===void 0||C.setCoordinates({x1:_.min,x2:_.max}),this.annotationBeforeSelectedAreaProperty&&(this.annotationBeforeSelectedAreaProperty.x1=(0,l.convertCoordinateFromDataValue)(x.visibleRange.min,E,this.annotationAfterSelectedAreaProperty.xCoordinateMode),this.annotationBeforeSelectedAreaProperty.x2=this.rangeSelectionAnnotation.x1),this.annotationAfterSelectedAreaProperty&&(this.annotationAfterSelectedAreaProperty.x1=(P=this.rangeSelectionAnnotation)===null||P===void 0?void 0:P.x2,this.annotationAfterSelectedAreaProperty.x2=(0,l.convertCoordinateFromDataValue)(x.visibleRange.max,E,this.annotationAfterSelectedAreaProperty.xCoordinateMode))}},enumerable:!1,configurable:!0}),S.prototype.createAnnotation=function(_){return new f.OverviewCustomResizableAnnotation(_)},S.prototype.updateSelectionAnnotation=function(){var _=this;if(this.parentSurface){var C=function(){var M;(M=_.overviewPositionAnimation)===null||M===void 0||M.cancel();var D=_.xAxis,F=D.getCurrentCoordinateCalculator(),I=new r.NumberRange((0,l.convertToDataValue)(_.rangeSelectionAnnotation.x1,F,_.rangeSelectionAnnotation.xCoordinateMode),(0,l.convertToDataValue)(_.rangeSelectionAnnotation.x2,F,_.rangeSelectionAnnotation.xCoordinateMode));_.selectedAreaProperty=I,_.annotationBeforeSelectedAreaProperty.x2=_.rangeSelectionAnnotation.x1,_.annotationAfterSelectedAreaProperty.x1=_.rangeSelectionAnnotation.x2,_.onSelectedAreaChanged(I)},P=this.xAxis,x={xAxisId:this.xAxisId,yAxisId:this.yAxisId,opacity:.5,y1:0,y2:1,xCoordinateMode:d.ECoordinateMode.Pixel,yCoordinateMode:d.ECoordinateMode.Relative,resizeDirections:u.EXyDirection.XDirection},E=this.createAnnotation(e(e({},x),{isEditable:!0,svgString:y,onDrag:C})),A=this.createAnnotation(e(e({},x),{svgString:m})),R=this.createAnnotation(e(e({},x),{svgString:m}));P.isHorizontalAxis?(E.adornerSvgStringTemplate=g,A.minWidth=0,R.minWidth=0):(E.adornerSvgStringTemplate=v,A.minHeight=0,R.minHeight=0),this.rangeSelectionAnnotationProperty=(0,n.deleteSafe)(this.rangeSelectionAnnotation),this.annotationBeforeSelectedAreaProperty=(0,n.deleteSafe)(this.annotationBeforeSelectedAreaProperty),this.annotationAfterSelectedAreaProperty=(0,n.deleteSafe)(this.annotationAfterSelectedAreaProperty),this.parentSurface.modifierAnnotations.remove(this.rangeSelectionAnnotation,!1),this.parentSurface.modifierAnnotations.remove(this.annotationBeforeSelectedAreaProperty,!1),this.parentSurface.modifierAnnotations.remove(this.annotationAfterSelectedAreaProperty,!1),this.parentSurface.modifierAnnotations.add(E),this.parentSurface.modifierAnnotations.add(A),this.parentSurface.modifierAnnotations.add(R),this.rangeSelectionAnnotationProperty=E,this.annotationBeforeSelectedAreaProperty=A,this.annotationAfterSelectedAreaProperty=R}},S.prototype.setInitialAnnotationCoordinates=function(){var _=this.xAxis,C=_.getCurrentCoordinateCalculator();this.rangeSelectionAnnotation.x1=(0,l.convertCoordinateFromDataValue)(this.selectedArea.min,C,this.rangeSelectionAnnotation.xCoordinateMode),this.rangeSelectionAnnotation.x2=(0,l.convertCoordinateFromDataValue)(this.selectedArea.max,C,this.rangeSelectionAnnotation.xCoordinateMode),this.annotationBeforeSelectedAreaProperty.x1=(0,l.convertCoordinateFromDataValue)(_.visibleRange.min,C,this.annotationBeforeSelectedAreaProperty.xCoordinateMode),this.annotationBeforeSelectedAreaProperty.x2=(0,l.convertCoordinateFromDataValue)(this.selectedArea.min,C,this.annotationBeforeSelectedAreaProperty.xCoordinateMode),this.annotationAfterSelectedAreaProperty.x1=(0,l.convertCoordinateFromDataValue)(this.selectedArea.max,C,this.annotationAfterSelectedAreaProperty.xCoordinateMode),this.annotationAfterSelectedAreaProperty.x2=(0,l.convertCoordinateFromDataValue)(_.visibleRange.max,C,this.annotationAfterSelectedAreaProperty.xCoordinateMode)},S})(h.ChartModifierBase2D);Pb.OverviewRangeSelectionModifier=p;var g=function(b,S,_,C){var P="black",x="#2e2e2e",E=3,A="40%",R="30%",M=_-b,D=C-S;return'<svg x="'.concat(b,'" y="').concat(S,'" width="').concat(M,'px" height="').concat(D,'px" viewBox="0 0 ').concat(M," ").concat(D,`" overflow="visible" xmlns="http://www.w3.org/2000/svg">
        <line x1="0" y1="0" x2="`).concat(M,'" y2="0" stroke="').concat(P,`" stroke-width="1" />
        <line x1="0" y1="`).concat(D,'" x2="').concat(M,'" y2="').concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <line x1="0" y1="0" x2="0" y2="`).concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <line x1="`).concat(M,'" y1="0" x2="').concat(M,'" y2="').concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <rect x="`).concat(0-E,'" y="').concat(R,'" width="7" height="').concat(A,'" fill="').concat(x,'" rx="5" stroke="').concat(P,`" />
        <rect x="`).concat(M-E,'" y="').concat(R,'" width="7" height="').concat(A,'" fill="').concat(x,'" rx="5" stroke="').concat(P,`" />
        </svg>`)},v=function(b,S,_,C){var P="black",x="#2e2e2e",E="40%",A=3,R="30%",M=_-b,D=C-S;return'<svg x="'.concat(b,'" y="').concat(S,'" width="').concat(M,'px" height="').concat(D,'px" viewBox="0 0 ').concat(M," ").concat(D,`" overflow="visible" xmlns="http://www.w3.org/2000/svg">
        <line x1="0" y1="0" x2="`).concat(M,'" y2="0" stroke="').concat(P,`" stroke-width="1" />
        <line x1="0" y1="`).concat(D,'" x2="').concat(M,'" y2="').concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <line x1="0" y1="0" x2="0" y2="`).concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <line x1="`).concat(M,'" y1="0" x2="').concat(M,'" y2="').concat(D,'" stroke="').concat(P,`" stroke-width="1" />
        <rect x="`).concat(R,'" y="').concat(0-A,'" width="').concat(E,'" height="7" fill="').concat(x,'" rx="5" stroke="').concat(P,`" />
        <rect x="`).concat(R,'" y="').concat(D-A,'" width="').concat(E,'" height="7" fill="').concat(x,'" rx="5" stroke="').concat(P,`" />
        </svg>`)},y=`<svg width="50" height="50" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg">
    <rect width="100%" height="100%" style="fill:transparent">
    </rect>
</svg>`,m=`<svg width="50" height="50" preserveAspectRatio="none" xmlns="http://www.w3.org/2000/svg">
        <rect width="100%" height="100%" style="fill:black">
        </rect>
    </svg>`;return Pb}var rE={},mbe;function BW(){if(mbe)return rE;mbe=1;var t=rE&&rE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(rE,"__esModule",{value:!0}),rE.PinchZoomModifier=void 0;var e=$i(),i=Ho(),n=pl(),r=xm(),o=An(),a=Qu(),s=(function(l){t(u,l);function u(c){var d=this,f,h;return d=l.call(this,c)||this,d.horizontalGrowFactor=.005,d.verticalGrowFactor=.005,d.getMiddlePoint=function(p,g){return new e.Point((p.x+g.x)/2,(p.y+g.y)/2)},d.type=i.EChart2DModifierType.PinchZoom,d.horizontalGrowFactor=(f=c==null?void 0:c.horizontalGrowFactor)!==null&&f!==void 0?f:d.horizontalGrowFactor,d.verticalGrowFactor=(h=c==null?void 0:c.verticalGrowFactor)!==null&&h!==void 0?h:d.verticalGrowFactor,d}return u.prototype.modifierMouseDown=function(c){if(l.prototype.modifierMouseDown.call(this,c),!this.isAttached)throw new Error("Should not call PinchZoomModifier.modifierMouseDown if not attached");var d=(0,o.translateFromCanvasToSeriesViewRect)(c.mousePoint,this.parentSurface.seriesViewRect);if(d){var f=c.pointerType==="touch"||c.pointerType==="pen";f&&this.activePointerEvents.set(c.pointerId,c)}},u.prototype.modifierMouseMove=function(c){l.prototype.modifierMouseMove.call(this,c);var d=this.getIsActionAllowed(c);d&&(this.parentSurface.setZoomState(r.EZoomState.UserZooming),this.performModifierAction(c))},u.prototype.modifierMouseUp=function(c){l.prototype.modifierMouseUp.call(this,c),this.removeFromActiveTouchEvents(c)},u.prototype.modifierPointerCancel=function(c){l.prototype.modifierPointerCancel.call(this,c),this.removeFromActiveTouchEvents(c)},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={horizontalGrowFactor:this.horizontalGrowFactor,verticalGrowFactor:this.verticalGrowFactor};return Object.assign(c.options,d),c},u.prototype.performZoom=function(c,d,f,h,p){var g=this,v=h*d,y=p*f;[n.EXyDirection.XDirection,n.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedXAxis().forEach(function(m){g.growBy(c,m,v)}),[n.EXyDirection.YDirection,n.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedYAxis().forEach(function(m){g.growBy(c,m,y)})},u.prototype.removeFromActiveTouchEvents=function(c){this.activePointerEvents.delete(c.pointerId),this.activePointerEvents.size<2&&(this.previousHorizontalTouchPointsDistance=void 0,this.previousVerticalTouchPointsDistance=void 0)},u.prototype.performModifierAction=function(c){var d=Array.from(this.activePointerEvents.values()),f=d[0].mousePoint,h=d[1].mousePoint,p=Math.abs(f.x-h.x),g=Math.abs(f.y-h.y),v=this.getMiddlePoint(f,h),y=(0,o.translateFromCanvasToSeriesViewRect)(v,this.parentSurface.seriesViewRect);if(y&&this.previousHorizontalTouchPointsDistance!==void 0&&this.previousVerticalTouchPointsDistance!==void 0){var m=this.previousHorizontalTouchPointsDistance-p,b=this.previousVerticalTouchPointsDistance-g;this.performZoom(y,m,b,this.horizontalGrowFactor,this.verticalGrowFactor)}this.previousHorizontalTouchPointsDistance=p,this.previousVerticalTouchPointsDistance=g},u.prototype.getIsActionAllowed=function(c){var d=c.pointerType==="touch"||c.pointerType==="pen";return d&&this.activePointerEvents.size>=2},u})(a.ChartModifierBase2D);return rE.PinchZoomModifier=s,rE}var iE={},K9={},bbe;function i5(){return bbe||(bbe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.getTooltipPositionProperties=t.getUpdatedPoints=t.getEndPoint=t.getStartPoint=t.getTotalSpacing=t.getTotalSize=t.checkHasOverlap=t.spreadTooltips=t.EShift=t.ECoord=t.ESize=void 0;var e;(function(f){f.width="width",f.height="height"})(e=t.ESize||(t.ESize={}));var i;(function(f){f.xCoord="xCoord",f.yCoord="yCoord"})(i=t.ECoord||(t.ECoord={}));var n;(function(f){f.xCoordShift="xCoordShift",f.yCoordShift="yCoordShift"})(n=t.EShift||(t.EShift={}));var r=function(f,h,p,g,v){var y=new Map,m=f.length,b=(0,t.getTotalSize)(f,p.sizePropertyName),S=(0,t.getTotalSpacing)(f,g),_=b+S,C=f[0],P=f[m-1],x=(0,t.getStartPoint)(C[p.coordPropertyName],C[p.shiftPropertyName],h),E=(0,t.getEndPoint)(P[p.coordPropertyName],P[p.shiftPropertyName],h,P[p.sizePropertyName]),A=(0,t.getUpdatedPoints)(x,E,_,v[p.sizePropertyName]);x=A.start,E=A.end;var R=(E-x-b)/(f.length-1);return f.reduce(function(M,D){return y.set(D.index,(M-D[p.coordPropertyName])/h),M+D[p.sizePropertyName]+R},x),y};t.spreadTooltips=r;var o=function(f,h,p,g){for(var v=f.length,y=0;y<v-1;y++){var m=f[y],b=m[g.coordPropertyName]+m[g.sizePropertyName]+m[g.shiftPropertyName]*p,S=f[y+1],_=S[g.coordPropertyName]+S[g.shiftPropertyName]*p,C=_-b;if(C<h)return!0}return!1};t.checkHasOverlap=o;var a=function(f,h){return f.reduce(function(p,g){var v=g[h];return typeof v=="number"?p+v:p},0)};t.getTotalSize=a;var s=function(f,h){return(f.length-1)*h};t.getTotalSpacing=s;var l=function(f,h,p){return f+h*p};t.getStartPoint=l;var u=function(f,h,p,g){return f+h*p+g};t.getEndPoint=u;var c=function(f,h,p,g){var v=p-(h-f),y=v/2,m=f,b=g-h,S=f-y,_=h+y;return m<y&&(S=0,_=h+(v-m)),b<y&&(S=f-(v-b),_=g),{start:S,end:_}};t.getUpdatedPoints=c;var d=function(f){return f?{sizePropertyName:e.width,coordPropertyName:i.xCoord,shiftPropertyName:n.xCoordShift}:{sizePropertyName:e.height,coordPropertyName:i.yCoord,shiftPropertyName:n.yCoordShift}};t.getTooltipPositionProperties=d})(K9)),K9}var nE={},Sbe;function XBe(){if(Sbe)return nE;Sbe=1;var t=nE&&nE.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(nE,"__esModule",{value:!0}),nE.RolloverLegendSvgAnnotation=void 0;var e=gl(),i=jl(),n=Qa(),r=Dm(),o=(function(a){t(s,a);function s(l){var u=this,c,d,f;return u=a.call(this,l)||this,u.type=n.EAnnotationType.SVG,u.seriesInfosProperty=[],u.tooltipLegendTemplateProperty=(c=l==null?void 0:l.tooltipLegendTemplate)!==null&&c!==void 0?c:u.tooltipLegendTemplateProperty,u.tooltipLegendOffsetXProperty=(d=l==null?void 0:l.tooltipLegendOffsetX)!==null&&d!==void 0?d:u.tooltipLegendOffsetXProperty,u.tooltipLegendOffsetYProperty=(f=l==null?void 0:l.tooltipLegendOffsetY)!==null&&f!==void 0?f:u.tooltipLegendOffsetYProperty,u}return Object.defineProperty(s.prototype,"seriesInfos",{get:function(){return this.seriesInfosProperty},set:function(l){this.seriesInfosProperty&&l&&(l.length!==this.seriesInfosProperty.length||this.seriesInfosProperty.map(function(u){return u.equals(l.find(function(c){return c.renderableSeries.id===u.renderableSeries.id}))}).some(function(u){return u===!1}))&&(this.seriesInfosProperty=l,this.notifyPropertyChanged(i.PROPERTY.SERIES_INFOS))},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"tooltipLegendTemplate",{get:function(){return this.tooltipLegendTemplateProperty},set:function(l){this.tooltipLegendTemplateProperty=l,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_LEGEND_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"tooltipLegendOffsetX",{get:function(){return this.tooltipLegendOffsetXProperty},set:function(l){this.tooltipLegendOffsetXProperty=l,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_LEGEND_OFFSET_X)},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"tooltipLegendOffsetY",{get:function(){return this.tooltipLegendOffsetYProperty},set:function(l){this.tooltipLegendOffsetYProperty=l,this.notifyPropertyChanged(i.PROPERTY.TOOLTIP_LEGEND_OFFSET_Y)},enumerable:!1,configurable:!0}),s.prototype.update=function(l,u,c,d){this.tooltipLegendTemplate&&(this.svg&&this.delete(),this.create(l,u,c,d))},s.prototype.create=function(l,u,c,d){var f=this.tooltipLegendTemplate(this.seriesInfos,this),h=this.applyClipping(f,this.clipping),p=e.annotationHelpers.createSvg(h,this.svgRoot,this.nextSibling);this.setSvg(p),this.setSvgAttribute("x",this.tooltipLegendOffsetX+c),this.setSvgAttribute("y",this.tooltipLegendOffsetY+d)},s})(r.SvgAnnotationBase);return nE.RolloverLegendSvgAnnotation=o,nE}var oE={},_be;function KBe(){if(_be)return oE;_be=1;var t=oE&&oE.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(oE,"__esModule",{value:!0}),oE.RolloverMarkerSvgAnnotation=void 0;var e=GS(),i=gl(),n=Qa(),r=Dm(),o=(function(s){t(l,s);function l(u){var c=s.call(this)||this;return c.type=n.EAnnotationType.SVG,c.tooltipProps=u,c.isHiddenProperty=!0,c.x1=0,c.y1=0,c.xCoordShift=-4,c.yCoordShift=-4,c}return l.prototype.update=function(u,c,d,f){var h=this.tooltipProps.rolloverModifier.getMousePosition();this.previousMousePosition===h&&h!==e.EMousePosition.SeriesArea||(this.previousMousePosition=this.tooltipProps.rolloverModifier.getMousePosition(),s.prototype.update.call(this,u,c,d,f))},l.prototype.create=function(u,c,d,f){var h=this.tooltipProps,p=h.tooltipColor,g=h.markerColor,v=g??p;if(this.svg&&this.currentColor!==v&&this.clear(),!this.svg){this.currentColor;var y=a(v),m=this.applyClipping(y,this.clipping),b=i.annotationHelpers.createSvg(m,this.svgRoot,this.nextSibling);this.setSvg(b)}},l})(r.SvgAnnotationBase);oE.RolloverMarkerSvgAnnotation=o;var a=function(s){return'<svg width="8" height="8"><circle cx="50%" cy="50%" r="4" fill="'.concat(s,'"/></svg>')};return oE}var aE={},Pbe;function ZBe(){if(Pbe)return aE;Pbe=1;var t=aE&&aE.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(aE,"__esModule",{value:!0}),aE.RolloverTooltipSvgAnnotation=void 0;var e=GS(),i=Ca(),n=gl(),r=jl(),o=Qa(),a=Dm(),s=Ti(),l=(function(h){t(p,h);function p(g,v){var y=this,m,b;return y=h.call(this,v)||this,y.type=o.EAnnotationType.SVG,y.width=0,y.height=0,y.tooltipProps=g,y.height=(m=v==null?void 0:v.height)!==null&&m!==void 0?m:y.height,y.xCoordinateMode=i.ECoordinateMode.DataValue,y.yCoordinateMode=i.ECoordinateMode.DataValue,y.isHidden=!0,y.updateSize=y.updateSize.bind(y),y.placementDivIdProperty=(b=v==null?void 0:v.placementDivId)!==null&&b!==void 0?b:y.placementDivIdProperty,y}return Object.defineProperty(p.prototype,"seriesInfo",{get:function(){return this.seriesInfoProperty},set:function(g){(g&&!this.seriesInfoProperty||!this.seriesInfoProperty.equals(g))&&(this.seriesInfoProperty=g,this.notifyPropertyChanged(r.PROPERTY.SERIES_INFO))},enumerable:!1,configurable:!0}),p.prototype.update=function(g,v,y,m){var b=this.tooltipProps.rolloverModifier.getMousePosition();this.previousMousePosition===b&&b!==e.EMousePosition.SeriesArea||(this.previousMousePosition=this.tooltipProps.rolloverModifier.getMousePosition(),this.svg&&this.clear(),this.placementDivId?this.updateExternalLegendTooltip():(h.prototype.update.call(this,g,v,y,m),this.updateLegendTooltip(y,m)))},p.prototype.updateSize=function(g,v){this.width=g,this.height=v},p.prototype.clear=function(){var g,v,y,m;if(!(!this.parentSurface||this.parentSurface.isDeleted)){if(this.svg){if(this.placementDivId){(v=(g=this.svg)===null||g===void 0?void 0:g.parentNode)===null||v===void 0||v.removeChild(this.svg);return}(y=this.svgRoot)===null||y===void 0||y.removeChild(this.svg)}this.svgLegend&&((m=this.svgLegend.parentNode)===null||m===void 0||m.removeChild(this.svgLegend))}},p.prototype.create=function(g,v,y,m){var b;this.seriesInfo?b=this.generateSvgString():b="<svg></svg>";var S=this.applyClipping(b,this.clipping),_=n.annotationHelpers.createSvg(S,this.svgRoot,this.nextSibling);this.setSvg(_)},p.prototype.generateSvgString=function(){var g,v=this.tooltipProps.tooltipTitle,y=(""+v).replace(/\s/g,""),m="id".concat(Math.floor(this.y1),"_").concat(y,"_").concat(Date.now()),b=(g=this.tooltipProps.tooltipTemplate)!==null&&g!==void 0?g:c;return b(m,this.seriesInfo,this)},p.prototype.updateLegendTooltip=function(g,v){if(this.tooltipProps.tooltipLegendTemplate){var y=this.seriesInfo?this.tooltipProps.tooltipLegendTemplate(this.tooltipProps,this.seriesInfo):"<svg></svg>",m=this.applyClipping(y,this.clipping),b=n.annotationHelpers.createSvg(m,this.svgRoot,this.nextSibling);this.svgLegend=b,this.svgLegend.setAttribute("x",this.tooltipProps.tooltipLegendOffsetX.toString()+g),this.svgLegend.setAttribute("y",this.tooltipProps.tooltipLegendOffsetY.toString()+v)}},p.prototype.updateExternalLegendTooltip=function(){var g;this.seriesInfo?g=this.generateSvgString():g="<svg style='display: none;'></svg>",this.svgDivRoot=document.querySelector("[id='".concat(this.placementDivId,"']"));var v=this.applyClipping(g,this.clipping),y=n.annotationHelpers.createSvg(v,this.svgDivRoot,this.nextSibling);this.setSvg(y)},Object.defineProperty(p.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(g){this.placementDivIdProperty!==g&&(this.placementDivIdProperty=g,this.notifyPropertyChanged(r.PROPERTY.PLACEMENT_DIV_ID))},enumerable:!1,configurable:!0}),p})(a.SvgAnnotationBase);aE.RolloverTooltipSvgAnnotation=l;var u=function(h,p,g,v){return h.getValuesWithLabels(p,g,v,!0)},c=function(h,p,g){var v,y,m,b,S,_="",C=g.tooltipProps,P=C.tooltipTitle,x=C.tooltipColor,E=C.tooltipTextColor,A=C.tooltipLabelX,R=C.tooltipLabelY,M=C.shadowColor,D=(m=(v=g.tooltipProps.tooltipDataTemplate)!==null&&v!==void 0?v:(y=g.tooltipProps.rolloverModifier)===null||y===void 0?void 0:y.tooltipDataTemplate)!==null&&m!==void 0?m:u,F=D(p,P,A,R),I=(b=C.width)!==null&&b!==void 0?b:d(F.reduce(function(H,U){return(U==null?void 0:U.length)>H?U.length:H},0)),V=(S=C.height)!==null&&S!==void 0?S:f(F.length);g.updateSize(I,V),F.forEach(function(H,U){_+='<tspan x="8" dy="1.2em">'.concat(H,"</tspan>")});var z='<feGaussianBlur result="blurOut" in="offOut" stdDeviation="3" />';if(M!==void 0){var G=(0,s.parseColorToTArgb)(M);z=`<feColorMatrix result="matrixOut" in="offOut" type="matrix"
        values="0 0 0 0 `.concat(G.red/255,`
                0 0 0 0 `).concat(G.green/255,`
                0 0 0 0 `).concat(G.blue/255,`
                0 0 0 `).concat(G.opacity/255,` 0" />
        <feGaussianBlur result="blurOut" in="matrixOut" stdDeviation="3" />`)}return'<svg class="scichart__rollover-tooltip" width="'.concat(I,'" height="').concat(V,`">
        <defs>
            <filter id="`).concat(h,`" x="0" y="0" width="200%" height="200%">
                <feOffset result="offOut" in="SourceAlpha" dx="3" dy="3" />
                `).concat(z,`
                <feBlend in="SourceGraphic" in2="blurOut" mode="normal" />
            </filter>
        </defs>
        <rect rx="4" ry="4" width="90%" height="90%" fill="`).concat(x,'" filter="url(#').concat(h,`)" />
        <svg width="100%">
            <text x="8" y="3" font-size="13" font-family="Verdana" dy="0" fill="`).concat(E,'">').concat(_,`</text>
        </svg>
    </svg>`)},d=function(h,p){return h===void 0&&(h=20),h*8+20},f=function(h,p){return h===void 0&&(h=2),17*h+16};return aE}var Cbe;function i$(){return Cbe||(Cbe=1,(function(t){var e=iE&&iE.__extends||(function(){var R=function(M,D){return R=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(F,I){F.__proto__=I}||function(F,I){for(var V in I)Object.prototype.hasOwnProperty.call(I,V)&&(F[V]=I[V])},R(M,D)};return function(M,D){if(typeof D!="function"&&D!==null)throw new TypeError("Class extends value "+String(D)+" is not a constructor or null");R(M,D);function F(){this.constructor=M}M.prototype=D===null?Object.create(D):(F.prototype=D.prototype,new F)}})(),i=iE&&iE.__spreadArray||function(R,M,D){if(D||arguments.length===2)for(var F=0,I=M.length,V;F<I;F++)(V||!(F in M))&&(V||(V=Array.prototype.slice.call(M,0,F)),V[F]=M[F]);return R.concat(V||Array.prototype.slice.call(M))};Object.defineProperty(t,"__esModule",{value:!0}),t.updateRolloverModifierProps=t.splitIntoClusters=t.calcTooltipPositions=t.calcTooltipProps=t.RolloverModifier=t.TOOLTIP_SPACING=void 0;var n=mo(),r=ga(),o=Ho(),a=GS(),s=hn(),l=i5(),u=An(),c=Xs(),d=Ca(),f=rC(),h=XBe(),p=KBe(),g=ZBe(),v=FW(),y=Sn(),m=Zi(),b=Qu(),S=km();t.TOOLTIP_SPACING=4;var _=(function(R){e(M,R);function M(D){var F=this,I,V,z,G,H,U,k,X,W,Y,te,oe,de;return F=R.call(this,D)||this,F.type=o.EChart2DModifierType.Rollover,F.tooltipLegendOffsetX=0,F.tooltipLegendOffsetY=0,F.snapToDataPoint=!1,F.hitTestRadius=0,F.axisLabelPadding=void 0,F.axisLabelCornerRadius=2,F.showRolloverLineProperty=!0,F.showTooltipProperty=!0,F.absoluteXCoord=0,F.isSvgOnlyProperty=!0,F.mousePosition=a.EMousePosition.OutOfCanvas,F.allowTooltipOverlappingProperty=!1,F.hitTestRenderableSeries=F.hitTestRenderableSeries.bind(F),F.placementDivIdProperty=(I=D==null?void 0:D.placementDivId)!==null&&I!==void 0?I:F.placementDivIdProperty,F.isSvgOnlyProperty=(V=D==null?void 0:D.isSvgOnly)!==null&&V!==void 0?V:F.isSvgOnlyProperty,F.axisLabelPadding=(z=D==null?void 0:D.axisLabelPadding)!==null&&z!==void 0?z:F.axisLabelPadding,F.axisLabelCornerRadius=(G=D==null?void 0:D.axisLabelCornerRadius)!==null&&G!==void 0?G:F.axisLabelCornerRadius,F.rolloverLineAnnotation=F.createLine(D),D!=null&&D.tooltipLegendTemplate&&typeof D.tooltipLegendTemplate=="string"&&(F.typeMap.set("tooltipLegendTemplate",D.tooltipLegendTemplate),D.tooltipLegendTemplate=(0,n.getFunction)(r.EBaseType.OptionFunction,D.tooltipLegendTemplate)),F.tooltipLegendTemplate=(H=D==null?void 0:D.tooltipLegendTemplate)!==null&&H!==void 0?H:F.tooltipLegendTemplate,F.tooltipLegendOffsetX=(U=D==null?void 0:D.tooltipLegendOffsetX)!==null&&U!==void 0?U:F.tooltipLegendOffsetX,F.tooltipLegendOffsetY=(k=D==null?void 0:D.tooltipLegendOffsetY)!==null&&k!==void 0?k:F.tooltipLegendOffsetY,D!=null&&D.tooltipDataTemplate&&typeof D.tooltipDataTemplate=="string"&&(F.typeMap.set("tooltipDataTemplate",D.tooltipDataTemplate),D.tooltipDataTemplate=(0,n.getFunction)(r.EBaseType.OptionFunction,D.tooltipDataTemplate)),F.tooltipDataTemplateProperty=(X=D==null?void 0:D.tooltipDataTemplate)!==null&&X!==void 0?X:F.tooltipDataTemplateProperty,F.showRolloverLineProperty=(W=D==null?void 0:D.showRolloverLine)!==null&&W!==void 0?W:F.showRolloverLineProperty,F.showTooltipProperty=(Y=D==null?void 0:D.showTooltip)!==null&&Y!==void 0?Y:F.showTooltipProperty,F.legendAnnotation=new h.RolloverLegendSvgAnnotation({tooltipLegendTemplate:F.tooltipLegendTemplate,tooltipLegendOffsetX:F.tooltipLegendOffsetX,tooltipLegendOffsetY:F.tooltipLegendOffsetY,xAxisId:F.xAxisId,yAxisId:F.yAxisId}),F.allowTooltipOverlappingProperty=(te=D==null?void 0:D.allowTooltipOverlapping)!==null&&te!==void 0?te:F.allowTooltipOverlappingProperty,F.snapToDataPoint=(oe=D==null?void 0:D.snapToDataPoint)!==null&&oe!==void 0?oe:F.snapToDataPoint,F.hitTestRadius=(de=D==null?void 0:D.hitTestRadius)!==null&&de!==void 0?de:F.hitTestRadius,F}return M.prototype.createLine=function(D){var F,I,V,z={xCoordinateMode:d.ECoordinateMode.Pixel,yCoordinateMode:d.ECoordinateMode.Pixel,strokeDashArray:D==null?void 0:D.rolloverLineStrokeDashArray,strokeThickness:(F=D==null?void 0:D.rolloverLineStrokeThickness)!==null&&F!==void 0?F:2,stroke:(I=D==null?void 0:D.rolloverLineStroke)!==null&&I!==void 0?I:y.SciChartSurfaceBase.DEFAULT_THEME.cursorLineBrush,xAxisId:this.xAxisId,yAxisId:this.yAxisId,showLabel:(V=D==null?void 0:D.showAxisLabel)!==null&&V!==void 0?V:!1,labelPadding:D==null?void 0:D.axisLabelPadding,labelCornerRadius:D==null?void 0:D.axisLabelCornerRadius,isHidden:!0};return this.isSvgOnlyProperty?new v.SvgLineAnnotation(z):new f.LineAnnotation(z)},M.prototype.applyTheme=function(D){if(this.parentSurface){var F=this.parentSurface.previousThemeProvider;this.rolloverLineAnnotation.stroke===F.cursorLineBrush&&(this.rolloverLineAnnotation.stroke=D.cursorLineBrush)}},Object.defineProperty(M.prototype,"rolloverLineStroke",{get:function(){return this.rolloverLineAnnotation.stroke},set:function(D){this.rolloverLineAnnotation.stroke=D,this.notifyPropertyChanged(S.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"rolloverLineStrokeThickness",{get:function(){return this.rolloverLineAnnotation.strokeThickness},set:function(D){this.rolloverLineAnnotation.strokeThickness=D,this.notifyPropertyChanged(S.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"rolloverLineStrokeDashArray",{get:function(){return this.rolloverLineAnnotation.strokeDashArray},set:function(D){this.rolloverLineAnnotation.strokeDashArray=D,this.notifyPropertyChanged(S.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"showRolloverLine",{get:function(){return this.showRolloverLineProperty},set:function(D){this.showRolloverLineProperty=D,this.notifyPropertyChanged(S.PROPERTY.SHOW_ROLLOVER_LINE)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(D){this.tooltipDataTemplateProperty=D,this.notifyPropertyChanged(S.PROPERTY.TOOLTIP_DATA_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"showTooltip",{get:function(){return this.showTooltipProperty},set:function(D){this.showTooltipProperty=D,this.notifyPropertyChanged(S.PROPERTY.SHOW_TOOLTIP)},enumerable:!1,configurable:!0}),Object.defineProperty(M.prototype,"allowTooltipOverlapping",{get:function(){return this.allowTooltipOverlappingProperty},set:function(D){this.allowTooltipOverlappingProperty=D,this.notifyPropertyChanged(S.PROPERTY.ALLOW_TOOLTIP_OVERLAPPING)},enumerable:!1,configurable:!0}),M.prototype.onAttach=function(){var D=this;R.prototype.onAttach.call(this),this.addLineAnnotationToSurface(),this.parentSurface.modifierAnnotations.add(this.legendAnnotation),this.getIncludedRenderableSeries().forEach(function(F){return D.addSeriesAnnotationsToParentSurface(F)})},M.prototype.addLineAnnotationToSurface=function(){this.parentSurface.modifierAnnotations.add(this.rolloverLineAnnotation)},M.prototype.onDetach=function(){var D=this;R.prototype.onDetach.call(this),this.parentSurface.modifierAnnotations.remove(this.rolloverLineAnnotation,!0),this.parentSurface.modifierAnnotations.remove(this.legendAnnotation,!1),this.getIncludedRenderableSeries().forEach(function(F){return D.removeSeriesAnnotationsFromParentSurface(F)})},M.prototype.onAttachSeries=function(D){R.prototype.onAttachSeries.call(this,D),this.getIncludedRenderableSeries().includes(D)&&(this.addSeriesAnnotationsToParentSurface(D),this.legendAnnotation.seriesInfos=this.getSeriesInfos())},M.prototype.onDetachSeries=function(D){R.prototype.onDetachSeries.call(this,D),this.removeSeriesAnnotationsFromParentSurface(D)},M.prototype.modifierMouseMove=function(D){if(!(this.parentSurface.isSubSurface&&!D.isActiveSubChartEvent)){this.activePointerEvents.set(D.pointerId,D),R.prototype.modifierMouseMove.call(this,D);var F;this.mousePoint?(F=(0,u.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect),F?this.mousePosition=a.EMousePosition.SeriesArea:this.mousePosition=a.EMousePosition.AxisArea):this.mousePosition=a.EMousePosition.OutOfCanvas;var I=this.getIsActionAllowed(D);I&&this.update()}},M.prototype.hideAllTooltips=function(){this.mousePosition=a.EMousePosition.OutOfCanvas,this.update()},M.prototype.modifierMouseLeave=function(D){R.prototype.modifierMouseLeave.call(this,D),this.hideAllTooltips()},M.prototype.onParentSurfaceRendered=function(){},M.prototype.onParentSurfaceLayoutComplete=function(){this.update()},M.prototype.includeSeries=function(D,F){var I,V;return R.prototype.includeSeries.call(this,D,F)?(this.isAttached&&(F===!0&&this.addSeriesAnnotationsToParentSurface(D),F===!1&&this.removeSeriesAnnotationsFromParentSurface(D),this.parentSurface&&(this.legendAnnotation.seriesInfos=this.getSeriesInfos()),(I=this.parentSurface)===null||I===void 0||I.invalidateElement()),(V=this.parentSurface)===null||V===void 0||V.invalidateElement(),!0):!1},M.prototype.getIncludedRenderableSeries=function(){var D=this,F=this.parentSurface.renderableSeries.asArray().filter(function(z){return!z.isStacked&&z.isVisible&&z.rolloverModifierProps.showRollover&&D.testIsIncludedSeries(z)}),I=this.parentSurface.renderableSeries.asArray().filter(function(z){return z.isCollection}),V=F;return I.forEach(function(z){z.getVisibleSeries().forEach(function(G){G.rolloverModifierProps.showRollover&&D.testIsIncludedSeries(G)&&V.push(G)})}),V},M.prototype.hitTestRenderableSeries=function(D,F){if(F)return this.hitTestRadius<=0?D.hitTestProvider.hitTestXSlice(F.x,F.y):D.hitTestProvider.hitTestDataPoint(F.x,F.y,this.hitTestRadius)},M.prototype.getMousePosition=function(){return this.mousePosition},M.prototype.toJSON=function(){var D,F,I,V,z=R.prototype.toJSON.call(this),G={snapToDataPoint:this.snapToDataPoint,placementDivId:this.placementDivId,hitTestRadius:this.hitTestRadius,allowTooltipOverlapping:this.allowTooltipOverlapping,rolloverLineStrokeDashArray:this.rolloverLineStrokeDashArray,rolloverLineStroke:this.rolloverLineStroke,rolloverLineStrokeThickness:this.rolloverLineStrokeThickness,showRolloverLine:this.showRolloverLine,showTooltip:this.showTooltip,showAxisLabel:(F=(D=this.rolloverLineAnnotation)===null||D===void 0?void 0:D.showLabel)!==null&&F!==void 0?F:!1,tooltipDataTemplate:this.typeMap.get("tooltipDataTemplate"),tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,tooltipLegendTemplate:this.typeMap.get("tooltipLegendTemplate"),isSvgOnly:this.isSvgOnlyProperty,axisLabelPadding:(I=this.rolloverLineAnnotation)===null||I===void 0?void 0:I.labelPadding,axisLabelCornerRadius:(V=this.rolloverLineAnnotation)===null||V===void 0?void 0:V.labelCornerRadius};return Object.assign(z.options,G),z},M.prototype.CalculateTooltipPositions=function(D,F,I,V,z,G){return G===void 0&&(G=!1),(0,t.calcTooltipPositions)(D,F,I,V,z,G)},M.prototype.notifyPropertyChanged=function(D){R.prototype.notifyPropertyChanged.call(this,D),D===S.PROPERTY.X_AXIS_ID&&(this.rolloverLineAnnotation.xAxisId=this.xAxisId,this.legendAnnotation.xAxisId=this.xAxisId),D===S.PROPERTY.Y_AXIS_ID&&(this.rolloverLineAnnotation.yAxisId=this.yAxisId,this.legendAnnotation.yAxisId=this.yAxisId)},M.prototype.isVerticalChart=function(){var D,F;return(F=(D=this.xAxis)===null||D===void 0?void 0:D.isVerticalChart)!==null&&F!==void 0?F:!1},M.prototype.removeSeriesAnnotationsFromParentSurface=function(D){var F=this;if(this.parentSurface)if(D.isCollection){var I=D;I.asArray().forEach(function(V){F.parentSurface.modifierAnnotations.remove(F.getRolloverProps(V).marker,!1),F.parentSurface.modifierAnnotations.remove(F.getRolloverProps(V).tooltip,!1),F.getRolloverProps(V).delete()})}else this.parentSurface.modifierAnnotations.remove(this.getRolloverProps(D).marker,!1),this.parentSurface.modifierAnnotations.remove(this.getRolloverProps(D).tooltip,!1),this.getRolloverProps(D).delete(),D.type===s.ESeriesType.BandSeries&&(this.parentSurface.modifierAnnotations.remove(this.getRolloverProps1(D).marker,!1),this.parentSurface.modifierAnnotations.remove(this.getRolloverProps1(D).tooltip,!1),this.getRolloverProps1(D).delete())},M.prototype.addSeriesAnnotationsToParentSurface=function(D){if(!(!this.parentSurface||D.type===s.ESeriesType.StackedMountainCollection||D.type===s.ESeriesType.StackedColumnCollection)){this.getRolloverProps(D).rolloverModifier=this,E(D,this.getRolloverProps(D),this.getRolloverProps1(D),this.placementDivIdProperty);var F=this.getRolloverProps(D).marker;this.parentSurface.modifierAnnotations.contains(F)||(this.parentSurface.modifierAnnotations.add(this.getRolloverProps(D).marker),this.parentSurface.modifierAnnotations.add(this.getRolloverProps(D).tooltip),D.type===s.ESeriesType.BandSeries&&(this.getRolloverProps1(D).rolloverModifier=this,this.parentSurface.modifierAnnotations.add(this.getRolloverProps1(D).marker),this.parentSurface.modifierAnnotations.add(this.getRolloverProps1(D).tooltip)))}},M.prototype.getRolloverProps=function(D){return D.rolloverModifierProps},M.prototype.getRolloverProps1=function(D){return D.rolloverModifierProps1},M.prototype.update=function(){this.updateLine(),this.updateSeriesAnnotations(),this.tooltipLegendTemplate&&(this.legendAnnotation.seriesInfos=this.getSeriesInfos())},M.prototype.updateLine=function(){if(this.mousePosition!==a.EMousePosition.SeriesArea){this.rolloverLineAnnotation.isHidden=!0;return}if(!this.showRolloverLineProperty){this.rolloverLineAnnotation.isHidden=!0;return}if(this.snapToDataPoint){var D=this.getIncludedRenderableSeries()[0];if(D){var F=this.hitTestRenderableSeries(D,this.mousePoint);if(F&&F.isWithinDataBounds){this.rolloverLineAnnotation.isHidden=!1;var I=(0,u.translateToNotScaled)(F.xCoord);this.rolloverLineAnnotation.x1=I,this.rolloverLineAnnotation.x2=I,this.rolloverLineAnnotation.y1=0,this.rolloverLineAnnotation.y2=this.isVerticalChart()?(0,u.translateToNotScaled)(this.parentSurface.seriesViewRect.right):(0,u.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom)}else this.rolloverLineAnnotation.isHidden=!0}else this.rolloverLineAnnotation.isHidden=!0}else{this.rolloverLineAnnotation.isHidden=!1;var V=(0,u.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect);if(V){var I=(0,u.translateToNotScaled)(V.x),z=(0,u.translateToNotScaled)(V.y);if(this.parentSurface.isPolar){var G=this.yAxis,H=G.reverseTransform(I,z);this.rolloverLineAnnotation.x1=0,this.rolloverLineAnnotation.x2=H.y,this.rolloverLineAnnotation.y1=0,this.rolloverLineAnnotation.y2=G.getAxisSize()}else this.isVerticalChart()?(this.rolloverLineAnnotation.x1=z,this.rolloverLineAnnotation.x2=z,this.rolloverLineAnnotation.y1=0,this.rolloverLineAnnotation.y2=(0,u.translateToNotScaled)(this.parentSurface.seriesViewRect.right)):(this.rolloverLineAnnotation.x1=I,this.rolloverLineAnnotation.x2=I,this.rolloverLineAnnotation.y1=0,this.rolloverLineAnnotation.y2=(0,u.translateToNotScaled)(this.parentSurface.seriesViewRect.bottom))}}},M.prototype.updateSeriesAnnotations=function(){var D=this,F=this.getIncludedRenderableSeries();if(F.forEach(function(H){var U=D.getRolloverProps(H);if(U.marker||D.addSeriesAnnotationsToParentSurface(H),U.marker.suspendInvalidate(),U.tooltip.suspendInvalidate(),U.marker.isHidden=!0,U.tooltip.isHidden=!0,U.tooltip.x1=void 0,U.tooltip.y1=void 0,H.type===s.ESeriesType.BandSeries){var k=D.getRolloverProps1(H);k.marker.suspendInvalidate(),k.tooltip.suspendInvalidate(),k.marker.isHidden=!0,k.tooltip.isHidden=!0,k.tooltip.x1=void 0,k.tooltip.y1=void 0}}),this.mousePosition!==a.EMousePosition.SeriesArea){F.forEach(function(H){var U=D.getRolloverProps(H);if(U.marker.resumeInvalidate(),U.tooltip.resumeInvalidate(),H.type===s.ESeriesType.BandSeries){var k=D.getRolloverProps1(H);k.marker.resumeInvalidate(),k.tooltip.resumeInvalidate()}});return}var I=[],V=this.isVerticalChart()?this.parentSurface.seriesViewRect.width:this.parentSurface.seriesViewRect.height;F.forEach(function(H,U){var k=D.hitTestRenderableSeries(H,D.mousePoint);if(k){if(D.hitTestRadius===0||k.isHit){var X=0<=k.yCoord&&k.yCoord<=V;if(X){D.absoluteXCoord=D.isVerticalChart()?k.yCoord:k.xCoord;var W=D.isVerticalChart()?k.xCoord:k.yCoord,Y=(0,t.calcTooltipProps)(U,H,D.getRolloverProps(H),D.parentSurface.seriesViewRect,k.xValue,k.yValue,D.absoluteXCoord,W,k,m.DpiHelper.PIXEL_RATIO,!1,D.isVerticalChart());Y&&I.push(Y)}}if(H.type===s.ESeriesType.BandSeries){var te=0<=k.y1Coord&&k.y1Coord<=V;if(te){var oe=D.isVerticalChart()?k.y1Coord:k.xCoord,W=D.isVerticalChart()?k.xCoord:k.y1Coord,de=(0,t.calcTooltipProps)(U,H,D.getRolloverProps1(H),D.parentSurface.seriesViewRect,k.xValue,k.y1Value,oe,W,k,m.DpiHelper.PIXEL_RATIO,!0,D.isVerticalChart());de&&I.push(de)}}}});var z;this.isVerticalChart()?z=I.sort(function(H,U){return H.xCoord>U.xCoord?1:U.xCoord>H.xCoord?-1:0}):z=I.sort(function(H,U){return H.yCoord>U.yCoord?1:U.yCoord>H.yCoord?-1:0});var G=this.CalculateTooltipPositions(z,this.allowTooltipOverlapping,t.TOOLTIP_SPACING*m.DpiHelper.PIXEL_RATIO,this.parentSurface.seriesViewRect,m.DpiHelper.PIXEL_RATIO,this.isVerticalChart());G.forEach(function(H){var U=F[H.index],k=D.showTooltip&&H.seriesInfo.isHit,X=H.seriesInfo.isHit;H.isY1?(0,t.updateRolloverModifierProps)(D.getRolloverProps1(U),U,H,k,X,D.placementDivId):(0,t.updateRolloverModifierProps)(D.getRolloverProps(U),U,H,k,X,D.placementDivId)}),F.forEach(function(H){D.getRolloverProps(H).marker.resumeInvalidate(),D.getRolloverProps(H).tooltip.resumeInvalidate(),H.type===s.ESeriesType.BandSeries&&(D.getRolloverProps1(H).marker.resumeInvalidate(),D.getRolloverProps1(H).tooltip.resumeInvalidate())})},M.prototype.getSeriesInfos=function(){var D=this;return this.getIncludedRenderableSeries().map(function(F){var I=D.hitTestRenderableSeries(F,D.mousePoint);if(I)return F.getSeriesInfo(I)}).filter(function(F){return F!==void 0})},Object.defineProperty(M.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(D){var F=this,I;this.placementDivIdProperty!==D&&(this.placementDivIdProperty=D,(I=this.parentSurface)===null||I===void 0||I.renderableSeries.asArray().forEach(function(V){F.getRolloverProps(V).tooltip.placementDivId=F.placementDivIdProperty,F.getRolloverProps1(V).tooltip.placementDivId=F.placementDivIdProperty}))},enumerable:!1,configurable:!0}),M})(b.ChartModifierBase2D);t.RolloverModifier=_;var C=function(R,M,D,F,I,V,z,G,H,U,k,X){k===void 0&&(k=!1),X===void 0&&(X=!1);var W=M.getSeriesInfo(H),Y=D.tooltip.width,te=Y*U,oe=D.tooltip.height,de=oe*U,ge=G,Ee=F.height-G,Re=5*U,Ae=F.width-z<te?-Y:5,Pe=X?Re:-oe/2;X?Ee<de+Re&&(Pe=(de+Re)/U*-1):ge<de/2?Pe=-ge/U:Ee<de/2&&(Pe=-(de-Ee)/U);var we={index:R,isY1:k,xValue:I,yValue:V,xCoord:z,yCoord:G,hitTestPointValues:H.hitTestPointValues,isCategoryAxis:H.isCategoryAxis,xCoordShift:Ae,yCoordShift:Pe,height:de,width:te,seriesInfo:W};return we};t.calcTooltipProps=C;var P=function(R,M,D,F,I,V){V===void 0&&(V=!1);var z=(0,l.getTooltipPositionProperties)(V);V&&R.forEach(function(Y){var te=Y.width/2/I;Y.xCoord>te&&(Y[z.shiftPropertyName]=-(Y.width/2)/I)});var G=(0,l.checkHasOverlap)(R,D,I,z),H=R.length;if(!M&&H>=2&&G)for(var U=0,k=0,X=3;k<X;){var W=(0,t.splitIntoClusters)(R,D,I,z);if(W.length===U)break;U=W.length,W.forEach(function(Y){if(Y.length>=2){var te=(0,l.spreadTooltips)(Y,I,z,D,F);Y.forEach(function(oe){oe[z.shiftPropertyName]=te.get(oe.index)})}}),k++}return R};t.calcTooltipPositions=P;var x=function(R,M,D,F){for(var I=i([],R,!0).sort(function(Y,te){return Y[F.coordPropertyName]-te[F.coordPropertyName]}),V=[],z=[],G=0,H=I;G<H.length;G++){var U=H[G];if(z.length===0)z.push(U);else{var k=(0,l.getStartPoint)(U[F.coordPropertyName],U[F.shiftPropertyName],D),X=z[z.length-1],W=(0,l.getEndPoint)(X[F.coordPropertyName],X[F.shiftPropertyName],D,X[F.sizePropertyName]);k<=W+M?z.push(U):(V.push(z),z=[U])}}return z.length>0&&V.push(z),V};t.splitIntoClusters=x;var E=function(R,M,D,F){var I,V,z,G;if(M.marker||(M.marker=new p.RolloverMarkerSvgAnnotation(M),M.marker.xAxisId=R.xAxisId,M.marker.yAxisId=R.yAxisId),M.tooltip||(M.tooltipTitle=(V=(I=M.tooltipTitle)!==null&&I!==void 0?I:R.seriesName)!==null&&V!==void 0?V:"",M.tooltipColor=M.tooltipColor,M.shadowColor=R.parentSurface.themeProvider.shadowEffectColor,M.tooltip=new g.RolloverTooltipSvgAnnotation(M,{seriesType:R.type,placementDivId:F}),M.tooltip.xAxisId=R.xAxisId,M.tooltip.yAxisId=R.yAxisId),R.type===s.ESeriesType.BandSeries){var H=R;D.marker||(D.marker=new p.RolloverMarkerSvgAnnotation(D),D.marker.xAxisId=H.xAxisId,D.marker.yAxisId=H.yAxisId),D.tooltip||(D.tooltipTitle=(G=(z=D.tooltipTitle)!==null&&z!==void 0?z:H.seriesName)!==null&&G!==void 0?G:"",D.tooltipColor=D.tooltipColor,D.tooltip=new g.RolloverTooltipSvgAnnotation(D,{placementDivId:F}),D.tooltip.xAxisId=H.xAxisId,D.tooltip.yAxisId=H.yAxisId)}},A=function(R,M,D,F,I,V){R.tooltip.seriesInfo=D.seriesInfo,D.isY1&&(R.tooltip.seriesInfo.isFirstSeries=!1),I&&(R.marker.isHidden=!1,R.marker.x1=D.xValue,R.marker.y1=D.yValue,R.markerColor.startsWith(c.AUTO_COLOR)&&(R.markerColor=D.isY1?M.strokeY1:M.stroke)),F?(R.tooltip.isHidden=!1,R.tooltip.x1=D.xValue,R.tooltip.y1=D.yValue,R.tooltip.xCoordShift=D.xCoordShift,R.tooltip.yCoordShift=D.yCoordShift,R.tooltipColor.startsWith(c.AUTO_COLOR)&&(R.tooltipColor=D.isY1?M.strokeY1:M.stroke)):V&&R.tooltip.delete()};t.updateRolloverModifierProps=A})(iE)),iE}var sE={},Tbe;function JBe(){if(Tbe)return sE;Tbe=1;var t=sE&&sE.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(sE,"__esModule",{value:!0}),sE.VerticalSliceModifier=void 0;var e=i$(),i=An(),n=$i(),r=GS(),o=CW(),a=Ca(),s=hn(),l=km(),u=Ho(),c=Zi(),d=(function(f){t(h,f);function h(p){var g=this,v,y,m;return g=f.call(this,p)||this,g.xCoordinateModeProperty=a.ECoordinateMode.Pixel,g.isDraggableProperty=!1,g.rmrsProps=new Map,g.rmrsProps1=new Map,g.type=u.EChart2DModifierType.VerticalSlice,g.x1Property=(v=p.x1)!==null&&v!==void 0?v:0,g.mousePosition=r.EMousePosition.SeriesArea,g.xCoordinateModeProperty=(y=p.xCoordinateMode)!==null&&y!==void 0?y:g.xCoordinateModeProperty,g.isDraggableProperty=(m=p.isDraggable)!==null&&m!==void 0?m:g.isDraggableProperty,g.lineSelectionColorProperty=p.lineSelectionColor,g.rolloverLineAnnotation.isEditable=g.isDraggableProperty,g.rolloverLineAnnotation.selectionBoxStroke=g.lineSelectionColor,g}return Object.defineProperty(h.prototype,"x1",{get:function(){return this.x1Property},set:function(p){p!==this.x1Property&&(this.x1Property=p,this.notifyPropertyChanged(l.PROPERTY.X1))},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"xCoordinateMode",{get:function(){return this.xCoordinateModeProperty},set:function(p){p!==this.xCoordinateModeProperty&&(this.xCoordinateModeProperty=p,this.notifyPropertyChanged(l.PROPERTY.X_COORDINATE_MODE))},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"verticalLine",{get:function(){return this.rolloverLineAnnotation},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"isDraggable",{get:function(){return this.isDraggableProperty},set:function(p){p!=this.isDraggableProperty&&(this.isDraggableProperty=p,this.notifyPropertyChanged(l.PROPERTY.IS_DRAGGABLE))},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"lineSelectionColor",{get:function(){return this.lineSelectionColorProperty},set:function(p){p!==this.lineSelectionColorProperty&&(this.lineSelectionColorProperty=p,this.notifyPropertyChanged(l.PROPERTY.LINE_SELECTION_COLOR))},enumerable:!1,configurable:!0}),h.prototype.modifierMouseMove=function(p){if(this.rolloverLineAnnotation.isDraggingStarted){this.mousePoint=new n.Point(p.mousePoint.x,p.mousePoint.y);var g=this.isVerticalChart(),v=g?p.mousePoint.y:p.mousePoint.x,y=this.xAxis,m=y.getCurrentCoordinateCalculator();switch(this.xCoordinateMode){case a.ECoordinateMode.Pixel:{var b=g?y.viewRect.top:y.viewRect.left,S=g?y.viewRect.height:y.viewRect.width;this.x1=Math.min(Math.max(0,(v-b)/c.DpiHelper.PIXEL_RATIO),S/c.DpiHelper.PIXEL_RATIO);break}case a.ECoordinateMode.Relative:{var b=g?y.viewRect.top:y.viewRect.left,_=(v-b)/m.viewportDimension;this.x1=Math.min(Math.max(0,_),1);break}case a.ECoordinateMode.DataValue:{var C=g?(0,i.translateFromCanvasToSeriesViewRectY)(v,this.parentSurface.seriesViewRect):(0,i.translateFromCanvasToSeriesViewRectX)(v,this.parentSurface.seriesViewRect),_=m.getDataValue(C);isNaN(_)||(this.x1=_);break}}this.update()}},h.prototype.modifierMouseLeave=function(p){},h.prototype.toJSON=function(){var p=f.prototype.toJSON.call(this),g={x1:this.x1,xCoordinateMode:this.xCoordinateMode,isDraggable:this.isDraggable,lineSelectionColor:this.lineSelectionColor};return Object.assign(p.options,g),p},h.prototype.getRolloverProps=function(p){return this.rmrsProps.get(p)},h.prototype.getRolloverProps1=function(p){return this.rmrsProps.get(p)},h.prototype.removeSeriesAnnotationsFromParentSurface=function(p){f.prototype.removeSeriesAnnotationsFromParentSurface.call(this,p),this.rmrsProps.get(p).delete(),this.rmrsProps.delete(p),p.type===s.ESeriesType.BandSeries&&(this.rmrsProps1.get(p).delete(),this.rmrsProps1.delete(p))},h.prototype.addSeriesAnnotationsToParentSurface=function(p){var g=new o.RolloverModifierRenderableSeriesProps(p,!1);if(o.RolloverModifierRenderableSeriesProps.copy(p.rolloverModifierProps,g),this.rmrsProps.set(p,g),p.type===s.ESeriesType.BandSeries){var v=new o.RolloverModifierRenderableSeriesProps(p,!1);o.RolloverModifierRenderableSeriesProps.copy(p.rolloverModifierProps1,v),this.rmrsProps1.set(p,v)}f.prototype.addSeriesAnnotationsToParentSurface.call(this,p)},h.prototype.createLine=function(p){var g=f.prototype.createLine.call(this,p);return g.annotationsGripsRadius=0,g},h.prototype.update=function(){this.calculateXPosition(),this.updateLine(),this.updateSeriesAnnotations(),Array.from(this.rmrsProps.values()).forEach(function(p){(!p.renderableSeries.isVisible||!p.showRollover)&&(p.tooltip.isHidden=!0,p.marker.isHidden=!0)}),this.tooltipLegendTemplate&&(this.legendAnnotation.seriesInfos=this.getSeriesInfos())},h.prototype.notifyPropertyChanged=function(p){switch(f.prototype.notifyPropertyChanged.call(this,p),p){case l.PROPERTY.X1:{this.calculateXPosition();break}case l.PROPERTY.X_COORDINATE_MODE:{this.calculateXPosition();break}case l.PROPERTY.IS_DRAGGABLE:{this.rolloverLineAnnotation.isEditable=this.isDraggableProperty;break}}},h.prototype.calculateXPosition=function(){var p=this.xAxis;if(p){var g=p.getCurrentCoordinateCalculator(),v=this.isVerticalChart(),y=v?p.viewRect.top:p.viewRect.left,m=this.isSvgOnlyProperty?c.DpiHelper.PIXEL_RATIO:1,b=this.rolloverLineAnnotation.getCoordinate(this.x1Property,g,this.xCoordinateModeProperty),S=b*m+y,_=v?this.parentSurface.seriesViewRect.width/2:this.parentSurface.seriesViewRect.height/2;this.mousePoint=v?new n.Point(_,S):new n.Point(S,_)}},h})(e.RolloverModifier);return sE.VerticalSliceModifier=d,sE}var Cb={},JF={},xbe;function QBe(){if(xbe)return JF;xbe=1,Object.defineProperty(JF,"__esModule",{value:!0}),JF.HoveredChangedArgs=void 0;var t=(function(){function e(i,n,r,o){this.source=i,this.hoveredSeries=n,this.allSeries=r,this.hitTestInfo=o}return e})();return JF.HoveredChangedArgs=t,JF}var QF={},Ebe;function eje(){if(Ebe)return QF;Ebe=1,Object.defineProperty(QF,"__esModule",{value:!0}),QF.SelectionChangedArgs=void 0;var t=(function(){function e(i,n,r,o){this.source=i,this.selectedSeries=n,this.allSeries=r,this.hitTestInfo=o}return e})();return QF.SelectionChangedArgs=t,QF}var wbe;function Aie(){if(wbe)return Cb;wbe=1;var t=Cb&&Cb.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})(),e=Cb&&Cb.__spreadArray||function(p,g,v){if(v||arguments.length===2)for(var y=0,m=g.length,b;y<m;y++)(b||!(y in g))&&(b||(b=Array.prototype.slice.call(g,0,y)),b[y]=g[y]);return p.concat(b||Array.prototype.slice.call(g))};Object.defineProperty(Cb,"__esModule",{value:!0}),Cb.SeriesSelectionModifier=void 0;var i=mo(),n=ps(),r=ga(),o=Lm(),a=Ho(),s=Th(),l=Vl(),u=QBe(),c=eje(),d=Qu(),f=km(),h=(function(p){t(g,p);function g(v){var y=this,m,b,S;if(y=p.call(this,v)||this,y.type=a.EChart2DModifierType.SeriesSelection,y.selectedSeries=[],y.hoveredSeries=[],y.selectionChanged=new n.EventHandler,y.hoverChanged=new n.EventHandler,y.hitTestRadiusProperty=(v==null?void 0:v.hitTestRadius)||l.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS,y.enableSelection=(m=v==null?void 0:v.enableSelection)!==null&&m!==void 0?m:!0,y.enableHover=(b=v==null?void 0:v.enableHover)!==null&&b!==void 0?b:!1,y.executeCondition=(S=v==null?void 0:v.executeCondition)!==null&&S!==void 0?S:{button:o.EExecuteOn.MouseLeftButton},v!=null&&v.onSelectionChanged)if(typeof v.onSelectionChanged=="string"){y.typeMap.set("onSelectionChanged",v.onSelectionChanged);var _=(0,i.getFunction)(r.EBaseType.OptionFunction,v.onSelectionChanged);y.selectionChanged.subscribe(_)}else y.selectionChanged.subscribe(v.onSelectionChanged);if(v!=null&&v.onHoverChanged)if(typeof v.onHoverChanged=="string"){y.typeMap.set("onHoverChanged",v.onHoverChanged);var C=(0,i.getFunction)(r.EBaseType.OptionFunction,v.onHoverChanged);y.hoverChanged.subscribe(C)}else y.hoverChanged.subscribe(v.onHoverChanged);return y.updateSeriesSelected=y.updateSeriesSelected.bind(y),y.updateSeriesHovered=y.updateSeriesHovered.bind(y),y}return Object.defineProperty(g.prototype,"hitTestRadius",{get:function(){return this.hitTestRadiusProperty},set:function(v){this.hitTestRadiusProperty=v,this.notifyPropertyChanged(f.PROPERTY.HIT_TEST_RADIUS)},enumerable:!1,configurable:!0}),g.prototype.onAttach=function(){var v=this,y;p.prototype.onAttach.call(this),this.selectedSeries=[],(y=this.getIncludedRenderableSeries())===null||y===void 0||y.forEach(function(m){return v.onAttachSeries(m)})},g.prototype.onDetach=function(){var v=this,y;p.prototype.onDetach.call(this),this.selectedSeries=[],(y=this.getIncludedRenderableSeries())===null||y===void 0||y.forEach(function(m){return v.onDetachSeries(m)})},g.prototype.onAttachSeries=function(v){p.prototype.onAttachSeries.call(this,v),!v.isCollection&&(v.isSelected&&this.selectedSeries.push(v),v.selected.subscribe(this.updateSeriesSelected),v.isHovered&&this.hoveredSeries.push(v),v.hovered.subscribe(this.updateSeriesHovered))},g.prototype.onDetachSeries=function(v){p.prototype.onDetachSeries.call(this,v),!v.isCollection&&(this.selectedSeries=(0,s.arrayRemove)(this.selectedSeries,v),v.selected.unsubscribe(this.updateSeriesSelected),this.hoveredSeries=(0,s.arrayRemove)(this.hoveredSeries,v),v.hovered.unsubscribe(this.updateSeriesHovered))},g.prototype.modifierMouseDown=function(v){if(p.prototype.modifierMouseDown.call(this,v),!!this.checkExecuteConditions(v).isPrimary&&!this.isAttached)throw new Error("Should not call SeriesSelectionModifier.modifierMouseDown if not attached")},g.prototype.modifierMouseMove=function(v){var y=this,m;if(p.prototype.modifierMouseMove.call(this,v),!!this.enableHover){var b=this.getIncludedRenderableSeries(),S=b.map(function(P){return P.hitTestProvider.hitTest(v.mousePoint.x,v.mousePoint.y,y.hitTestRadius)});try{this.preventReentrancy=!0;var _=e([],this.hoveredSeries,!0);this.hoveredSeries=[];var C;(S==null?void 0:S.length)>0?(C=S.filter(function(P){return P.isHit}).sort(function(P,x){return P.getEuclideanDistance()-x.getEuclideanDistance()})[0],C?(C.associatedSeries.isHovered=!0,this.hoveredSeries.push(C.associatedSeries)):b.forEach(function(P){return P.isHovered=!1}),S.filter(function(P){return P!==C}).forEach(function(P){P!=null&&P.associatedSeries&&(P.associatedSeries.isHovered=!1)})):b.forEach(function(P){return P.isHovered=!1}),(_.length!==this.hoveredSeries.length||_.some(function(P){return!y.hoveredSeries.includes(P)}))&&((m=this.hoverChanged)===null||m===void 0||m.raiseEvent(new u.HoveredChangedArgs(this,this.hoveredSeries,b,C)))}finally{this.preventReentrancy=!1}}},g.prototype.modifierMouseLeave=function(v){var y;this.preventReentrancy=!0;var m=this.getIncludedRenderableSeries(),b=e([],this.hoveredSeries,!0),S=void 0;b.length>0&&(m.forEach(function(_){return _.isHovered=!1}),(y=this.hoverChanged)===null||y===void 0||y.raiseEvent(new u.HoveredChangedArgs(this,this.hoveredSeries,m,S))),this.preventReentrancy=!1},g.prototype.modifierPointerCancel=function(v){this.modifierMouseLeave(v)},g.prototype.modifierMouseUp=function(v){var y=this,m;if(p.prototype.modifierMouseUp.call(this,v),!!this.checkExecuteConditions(v).isPrimary&&this.enableSelection){if(!this.isAttached)throw new Error("Should not call SeriesSelectionModifier.modifierMouseUp if not attached");var b=this.getIncludedRenderableSeries(),S=b.map(function(C){return C.hitTestProvider.hitTest(v.mousePoint.x,v.mousePoint.y,y.hitTestRadius)});try{this.preventReentrancy=!0,this.selectedSeries=[],b.forEach(function(C){return C.isSelected=!1});var _=void 0;(S==null?void 0:S.length)>0&&(_=S.filter(function(C){return C.isHit}).sort(function(C,P){return C.getEuclideanDistance()-P.getEuclideanDistance()})[0],_!=null&&_.isHit&&(_.associatedSeries.isSelected=!0,this.selectedSeries.push(_.associatedSeries))),(m=this.selectionChanged)===null||m===void 0||m.raiseEvent(new c.SelectionChangedArgs(this,this.selectedSeries,b,_))}finally{this.preventReentrancy=!1}}},g.prototype.toJSON=function(){var v=p.prototype.toJSON.call(this),y={enableHover:this.enableHover,enableSelection:this.enableSelection,hitTestRadius:this.hitTestRadius,onHoverChanged:this.typeMap.get("onHoverChanged"),onSelectionChanged:this.typeMap.get("onSelectionChanged")};return Object.assign(v.options,y),v},g.prototype.updateSeriesSelected=function(v){var y,m;this.preventReentrancy||(v.isSelected?(this.selectedSeries.push(v.sourceSeries),(y=this.selectionChanged)===null||y===void 0||y.raiseEvent(new c.SelectionChangedArgs(this,this.selectedSeries,this.getIncludedRenderableSeries(),void 0))):(this.selectedSeries=(0,s.arrayRemove)(this.selectedSeries,v.sourceSeries),(m=this.selectionChanged)===null||m===void 0||m.raiseEvent(new c.SelectionChangedArgs(this,this.selectedSeries,this.getIncludedRenderableSeries(),void 0))))},g.prototype.updateSeriesHovered=function(v){var y,m;this.preventReentrancy||(v.hovered?(this.hoveredSeries.push(v.sourceSeries),(y=this.hoverChanged)===null||y===void 0||y.raiseEvent(new u.HoveredChangedArgs(this,this.hoveredSeries,this.getIncludedRenderableSeries(),void 0))):(this.hoveredSeries=(0,s.arrayRemove)(this.hoveredSeries,v.sourceSeries),(m=this.hoverChanged)===null||m===void 0||m.raiseEvent(new u.HoveredChangedArgs(this,this.hoveredSeries,this.getIncludedRenderableSeries(),void 0))))},g})(d.ChartModifierBase2D);return Cb.SeriesSelectionModifier=h,Cb}var lE={},Z9={},Abe;function Oie(){return Abe||(Abe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ECursorStyle=void 0,(function(e){e.NS="ns-resize",e.EW="ew-resize",e.Defalut="auto"})(t.ECursorStyle||(t.ECursorStyle={}))})(Z9)),Z9}var J9={},Obe;function Die(){return Obe||(Obe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDragMode=void 0,(function(e){e.Scaling="Scaling",e.Panning="Panning"})(t.EDragMode||(t.EDragMode={}))})(J9)),J9}var Dbe;function tje(){if(Dbe)return lE;Dbe=1;var t=lE&&lE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(lE,"__esModule",{value:!0}),lE.XAxisDragModifier=void 0;var e=Oie(),i=Die(),n=An(),r=Vv(),o=Qu(),a=Ho(),s=(function(l){t(u,l);function u(c){var d=this,f;return d=l.call(this,c)||this,d.type=a.EChart2DModifierType.XAxisDrag,d.dragMode=i.EDragMode.Scaling,d.isClickedOverXAxis=!1,d.isVerticalChart=!1,d.cursorStyle=e.ECursorStyle.Defalut,d.dragMode=(f=c==null?void 0:c.dragMode)!==null&&f!==void 0?f:d.dragMode,d}return u.prototype.includeYAxis=function(c,d){throw Error("method includeYAxis() is not supported for XAxisDragModifier, use includeXAxis() instead")},u.prototype.getIncludedYAxis=function(){throw Error("method getIncludedYAxis() is not supported for XAxisDragModifier, use getIncludedXAxis() instead")},u.prototype.modifierMouseDown=function(c){if(l.prototype.modifierMouseDown.call(this,c),!this.isAttached)throw new Error("Should not call XAxisDragModifier.modifierMouseDown if not attached");(0,o.testIsOverAxes)(this.getHorizontalXAxes(),c.mousePoint)?(this.isVerticalChart=!1,this.startDragging(this.getHorizontalXAxes(),c)):(0,o.testIsOverAxes)(this.getVerticalXAxes(),c.mousePoint)&&(this.isVerticalChart=!0,this.startDragging(this.getVerticalXAxes(),c))},u.prototype.modifierMouseMove=function(c){if(this.isClickedOverXAxis){if(l.prototype.modifierMouseMove.call(this,c),this.pointFrom===void 0)return;this.dragMode===i.EDragMode.Panning?this.doPanning(c.mousePoint):this.dragMode===i.EDragMode.Scaling&&this.doScaling(c.mousePoint)}else this.updateCursor(c.mousePoint)},u.prototype.modifierMouseUp=function(c){l.prototype.modifierMouseUp.call(this,c),this.updateCursor(c.mousePoint),this.pointFrom=void 0,this.isClickedOverXAxis=!1},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={dragMode:this.dragMode};return Object.assign(c.options,d),c},u.prototype.updateCursor=function(c){var d=this.parentSurface.getMainCanvas();(0,o.testIsOverAxes)(this.getHorizontalXAxes(),c)?this.cursorStyle!==e.ECursorStyle.EW&&(d.style.cursor=e.ECursorStyle.EW,this.cursorStyle=e.ECursorStyle.EW):(0,o.testIsOverAxes)(this.getVerticalXAxes(),c)?this.cursorStyle!==e.ECursorStyle.NS&&(d.style.cursor=e.ECursorStyle.NS,this.cursorStyle=e.ECursorStyle.NS):this.cursorStyle!==e.ECursorStyle.Defalut&&(d.style.cursor=e.ECursorStyle.Defalut,this.cursorStyle=e.ECursorStyle.Defalut)},u.prototype.doPanning=function(c){var d=c;if(this.isVerticalChart){var f=d.y-this.pointFrom.y;this.activeAxes.forEach(function(p){var g=p.flippedCoordinates?-f:f;p.scroll(g,r.EClipMode.None)})}else{var h=d.x-this.pointFrom.x;this.activeAxes.forEach(function(p){var g=p.flippedCoordinates?-h:h;p.scroll(g,r.EClipMode.None)})}this.pointFrom=d},u.prototype.doScaling=function(c){var d=this;this.isVerticalChart?this.activeAxes.forEach(function(f,h){var p=f.viewRect,g=(0,n.translateFromCanvasToSeriesViewRectY)(d.pointFrom.y,p),v=g>=p.height/2,y=(c.y-d.pointFrom.y)/p.height;f.scale(d.initialVisibleRanges[h],y,v)}):this.activeAxes.forEach(function(f,h){var p=f.viewRect,g=(0,n.translateFromCanvasToSeriesViewRectX)(d.pointFrom.x,p),v=g>=p.width/2,y=(c.x-d.pointFrom.x)/p.width;f.scale(d.initialVisibleRanges[h],y,v)})},u.prototype.getHorizontalXAxes=function(){return this.getIncludedXAxis().filter(function(c){return c.isHorizontalAxis})},u.prototype.getVerticalXAxes=function(){return this.getIncludedXAxis().filter(function(c){return!c.isHorizontalAxis})},u.prototype.startDragging=function(c,d){this.isClickedOverXAxis=!0;var f=(0,o.getActiveAxes)(c,d.mousePoint),h=[];f.forEach(function(p){h.push(p.visibleRange)}),this.activeAxes=f,this.initialVisibleRanges=h,this.pointFrom=d.mousePoint,d.handled=!0},u})(o.ChartModifierBase2D);return lE.XAxisDragModifier=s,lE}var uE={},Rbe;function rje(){if(Rbe)return uE;Rbe=1;var t=uE&&uE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(uE,"__esModule",{value:!0}),uE.YAxisDragModifier=void 0;var e=Ho(),i=Oie(),n=Die(),r=An(),o=Vv(),a=Qu(),s=(function(l){t(u,l);function u(c){var d=this,f;return d=l.call(this,c)||this,d.type=e.EChart2DModifierType.YAxisDrag,d.dragMode=n.EDragMode.Scaling,d.isClickedOverYAxis=!1,d.isVerticalChart=!1,d.cursorStyle=i.ECursorStyle.Defalut,d.dragMode=(f=c==null?void 0:c.dragMode)!==null&&f!==void 0?f:d.dragMode,d}return u.prototype.includeXAxis=function(c,d){throw Error("method includeXAxis() is not supported for YAxisDragModifier, use includeYAxis() instead")},u.prototype.getIncludedXAxis=function(){throw Error("method getIncludedXAxis() is not supported for YAxisDragModifier, use getIncludedXAxis() instead")},u.prototype.modifierMouseDown=function(c){if(l.prototype.modifierMouseDown.call(this,c),!this.isAttached)throw new Error("Should not call YAxisDragModifier.modifierMouseDown if not attached");(0,a.testIsOverAxes)(this.getVerticalYAxes(),c.mousePoint)?(this.isVerticalChart=!1,this.startDragging(this.getVerticalYAxes(),c)):(0,a.testIsOverAxes)(this.getHorizontalYAxes(),c.mousePoint)&&(this.isVerticalChart=!0,this.startDragging(this.getHorizontalYAxes(),c))},u.prototype.modifierMouseMove=function(c){if(this.isClickedOverYAxis){if(l.prototype.modifierMouseMove.call(this,c),this.pointFrom===void 0)return;this.dragMode===n.EDragMode.Panning?this.doPanning(c.mousePoint):this.dragMode===n.EDragMode.Scaling&&this.doScaling(c.mousePoint)}else this.updateCursor(c.mousePoint)},u.prototype.modifierMouseUp=function(c){l.prototype.modifierMouseUp.call(this,c),this.updateCursor(c.mousePoint),this.pointFrom=void 0,this.isClickedOverYAxis=!1},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={dragMode:this.dragMode};return Object.assign(c.options,d),c},u.prototype.updateCursor=function(c){var d=this.parentSurface.getMainCanvas();(0,a.testIsOverAxes)(this.getVerticalYAxes(),c)?this.cursorStyle!==i.ECursorStyle.NS&&(d.style.cursor=i.ECursorStyle.NS,this.cursorStyle=i.ECursorStyle.NS):(0,a.testIsOverAxes)(this.getHorizontalYAxes(),c)?this.cursorStyle!==i.ECursorStyle.EW&&(d.style.cursor=i.ECursorStyle.EW,this.cursorStyle=i.ECursorStyle.EW):this.cursorStyle!==i.ECursorStyle.Defalut&&(d.style.cursor=i.ECursorStyle.Defalut,this.cursorStyle=i.ECursorStyle.Defalut)},u.prototype.doPanning=function(c){var d=c;if(this.isVerticalChart){var f=d.x-this.pointFrom.x;this.activeAxes.forEach(function(p){var g=p.flippedCoordinates?f:-f;p.scroll(g,o.EClipMode.None)})}else{var h=d.y-this.pointFrom.y;this.activeAxes.forEach(function(p){var g=p.flippedCoordinates?h:-h;p.scroll(g,o.EClipMode.None)})}this.pointFrom=d},u.prototype.doScaling=function(c){var d=this;this.isVerticalChart?this.activeAxes.forEach(function(f,h){var p=f.viewRect,g=(0,r.translateFromCanvasToSeriesViewRectX)(d.pointFrom.x,p),v=g<=p.width/2,y=-(c.x-d.pointFrom.x)/p.width;f.scale(d.initialVisibleRanges[h],y,v)}):this.activeAxes.forEach(function(f,h){var p=f.viewRect,g=(0,r.translateFromCanvasToSeriesViewRectY)(d.pointFrom.y,p),v=g<=p.height/2,y=-(c.y-d.pointFrom.y)/p.height;f.scale(d.initialVisibleRanges[h],y,v)})},u.prototype.getVerticalYAxes=function(){return this.getIncludedYAxis().filter(function(c){return!c.isHorizontalAxis})},u.prototype.getHorizontalYAxes=function(){return this.getIncludedYAxis().filter(function(c){return c.isHorizontalAxis})},u.prototype.startDragging=function(c,d){this.isClickedOverYAxis=!0;var f=(0,a.getActiveAxes)(c,d.mousePoint),h=[];f.forEach(function(p){h.push(p.visibleRange)}),this.activeAxes=f,this.initialVisibleRanges=h,this.pointFrom=d.mousePoint,d.handled=!0},u})(a.ChartModifierBase2D);return uE.YAxisDragModifier=s,uE}var cE={},Mbe;function Rie(){if(Mbe)return cE;Mbe=1;var t=cE&&cE.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(cE,"__esModule",{value:!0}),cE.ZoomExtentsModifier=void 0;var e=mo(),i=ad(),n=ga(),r=uR(),o=Ho(),a=pl(),s=xm(),l=An(),u=Qu(),c=(function(d){t(f,d);function f(h){var p=this,g,v,y,m,b,S;return p=d.call(this,h)||this,p.type=o.EChart2DModifierType.ZoomExtents,p.isAnimated=!0,p.animationDuration=400,p.easingFunction=i.easing.outExpo,p.applyToSeriesViewRect=!0,p.applyToAxes=!0,p.isAnimated=(g=h==null?void 0:h.isAnimated)!==null&&g!==void 0?g:p.isAnimated,p.animationDuration=(v=h==null?void 0:h.animationDuration)!==null&&v!==void 0?v:p.animationDuration,p.applyToSeriesViewRect=(y=h==null?void 0:h.applyToSeriesViewRect)!==null&&y!==void 0?y:p.applyToSeriesViewRect,p.applyToAxes=(m=h==null?void 0:h.applyToAxes)!==null&&m!==void 0?m:p.applyToAxes,h!=null&&h.easingFunction&&typeof h.easingFunction=="string"&&(h.easingFunction=i.easing[h.easingFunction]),p.easingFunction=(b=h==null?void 0:h.easingFunction)!==null&&b!==void 0?b:i.easing.outExpo,h!=null&&h.onZoomExtents&&typeof h.onZoomExtents=="string"&&(p.typeMap.set("onZoomExtents",h.onZoomExtents),h.onZoomExtents=(0,e.getFunction)(n.EBaseType.OptionFunction,h.onZoomExtents)),p.onZoomExtents=h==null?void 0:h.onZoomExtents,p.executeCondition=(S=h==null?void 0:h.executeCondition)!==null&&S!==void 0?S:{button:void 0,key:r.EModifierMouseArgKey.None},p}return f.prototype.modifierDoubleClick=function(h){var p=this;if(this.checkExecuteConditions(h).isPrimary){var g=this.parentSurface,v=this.isAnimated?this.animationDuration:0;if(g!==void 0){var y=(0,l.translateFromCanvasToSeriesViewRect)(h.mousePoint,this.parentSurface.seriesViewRect);if(y&&this.applyToSeriesViewRect){if(!this.onZoomExtents||this.onZoomExtents(g)){switch(this.xyDirection){case a.EXyDirection.XyDirection:g.zoomExtents(v,this.easingFunction,function(){return g.setZoomState(s.EZoomState.AtExtents)},function(S){return p.includedXAxes.testIsIncluded(S.id)},function(S){return p.includedYAxes.testIsIncluded(S.id)});break;case a.EXyDirection.XDirection:g.zoomExtentsX(v,this.easingFunction,function(S){return p.includedXAxes.testIsIncluded(S.id)});break;case a.EXyDirection.YDirection:g.zoomExtentsY(v,this.easingFunction,function(S){return p.includedYAxes.testIsIncluded(S.id)});break}h.handled=!0}}else if(this.applyToAxes){var m=[];[a.EXyDirection.XDirection,a.EXyDirection.XyDirection].includes(this.xyDirection)&&m.push.apply(m,this.getIncludedXAxis()),[a.EXyDirection.YDirection,a.EXyDirection.XyDirection].includes(this.xyDirection)&&m.push.apply(m,this.getIncludedYAxis());var b=(0,u.getActiveAxes)(m,h.mousePoint);b.length>0&&(h.handled=!0,b.forEach(function(S){if(S.isXAxis){var _=S.getMaximumRange();S.animateVisibleRange(_,v,p.easingFunction)}else{var C=S.getWindowedYRange(void 0);S.animateVisibleRange(C,v,p.easingFunction)}}))}}}},f.prototype.toJSON=function(){var h=d.prototype.toJSON.call(this),p={animationDuration:this.animationDuration,easingFunction:this.easingFunction.name,isAnimated:this.isAnimated,applyToSeriesViewRect:this.applyToSeriesViewRect,applyToAxes:this.applyToAxes,onZoomExtents:this.typeMap.get("onZoomExtents")};return Object.assign(h.options,p),h},f})(u.ChartModifierBase2D);return cE.ZoomExtentsModifier=c,cE}var dE={},Lbe;function ije(){if(Lbe)return dE;Lbe=1;var t=dE&&dE.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(dE,"__esModule",{value:!0}),dE.ZoomPanModifier=void 0;var e=Lm(),i=uR(),n=Ho(),r=pl(),o=xm(),a=An(),s=Vv(),l=BW(),u=(function(c){t(d,c);function d(f){var h=this,p,g;return h=c.call(this,f)||this,h.enableZoom=!0,h.type=n.EChart2DModifierType.ZoomPan,h.enableZoom=(p=f==null?void 0:f.enableZoom)!==null&&p!==void 0?p:h.enableZoom,h.executeCondition=(g=f==null?void 0:f.executeCondition)!==null&&g!==void 0?g:{button:e.EExecuteOn.MouseLeftButton,key:i.EModifierMouseArgKey.None},h}return d.prototype.modifierMouseDown=function(f){if(f.nativeEvent.preventDefault(),!!this.checkExecuteConditions(f).isPrimary){if(!this.isAttached)throw new Error("Should not call ZoomPanModifier.modifierMouseDown if not attached");c.prototype.modifierMouseDown.call(this,f);var h=(0,a.translateFromCanvasToSeriesViewRect)(f.mousePoint,this.parentSurface.seriesViewRect);h&&(this.activePointerEvents.set(f.pointerId,f),this.parentSurface.setZoomState(o.EZoomState.UserZooming))}},d.prototype.modifierMouseMove=function(f){if(!(this.parentSurface.isSubSurface&&!f.isActiveSubChartEvent)&&(this.updatePointerInfo(f),!!this.previousPoint)){this.enableZoom&&c.prototype.getIsActionAllowed.call(this,f)&&c.prototype.performModifierAction.call(this,f);var h=this.getIsActionAllowed(f);h&&this.performModifierAction(f)}},d.prototype.modifierMouseUp=function(f){if(c.prototype.modifierMouseUp.call(this,f),this.activePointerEvents.size>0){var h=this.activePointerEvents.values().next().value;f.target.setPointerCapture(h.pointerId)}},d.prototype.modifierPointerCancel=function(f){c.prototype.modifierPointerCancel.call(this,f),this.activePointerEvents.clear()},d.prototype.toJSON=function(){var f=c.prototype.toJSON.call(this),h={enableZoom:this.enableZoom};return Object.assign(f.options,h),f},d.prototype.performModifierAction=function(f){var h=f.mousePoint,p=h.x-this.previousPoint.x,g=this.previousPoint.y-h.y;this.performPan(p,g)},d.prototype.getIsActionAllowed=function(f){var h=this.activePointerEvents.values().next().value;return h.pointerId===f.pointerId},d.prototype.performPan=function(f,h){[r.EXyDirection.XDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedXAxis().forEach(function(p){var g=p.isHorizontalAxis?f:-h;p.scroll(p.flippedCoordinates?-g:g,s.EClipMode.None)}),[r.EXyDirection.YDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedYAxis().forEach(function(p){var g=p.isHorizontalAxis?-f:h;p.scroll(p.flippedCoordinates?-g:g,s.EClipMode.None)})},d})(l.PinchZoomModifier);return dE.ZoomPanModifier=u,dE}var Tb={},xb={},Q9={},kbe;function nje(){return kbe||(kbe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EHoverMode=void 0,(function(e){e.Multi="Multi",e.TopmostIncluded="TopmostIncluded",e.AbsoluteTopmost="AbsoluteTopmost"})(t.EHoverMode||(t.EHoverMode={}))})(Q9)),Q9}var Ibe;function oje(){if(Ibe)return xb;Ibe=1;var t=xb&&xb.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=xb&&xb.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(xb,"__esModule",{value:!0}),xb.PointerEventsMediatorModifier=void 0;var i=mo(),n=Qu(),r=ps(),o=ga(),a=nje(),s=GS(),l=An(),u=(function(c){t(d,c);function d(f){var h=this,p,g,v,y;if(h=c.call(this,f)||this,h.notifyOutEvent=!0,h.notifyPositionUpdate=!1,h.hoverChanged=new r.EventHandler,h.previousHoveredEntities=[],h.mousePosition=s.EMousePosition.OutOfCanvas,h.enableHoverProperty=!1,h.hoverModeProperty=a.EHoverMode.AbsoluteTopmost,h.enableHoverProperty=(p=f==null?void 0:f.enableHover)!==null&&p!==void 0?p:h.enableHoverProperty,h.hoverModeProperty=(g=f==null?void 0:f.hoverMode)!==null&&g!==void 0?g:h.hoverModeProperty,h.notifyOutEvent=(v=f==null?void 0:f.notifyOutEvent)!==null&&v!==void 0?v:h.notifyOutEvent,h.notifyPositionUpdate=(y=f==null?void 0:f.notifyPositionUpdate)!==null&&y!==void 0?y:h.notifyPositionUpdate,f!=null&&f.onHover&&(typeof f.onHover=="string"&&(h.typeMap.set("onHover",f.onHover),f.onHover=(0,i.getFunction)(o.EBaseType.OptionFunction,f.onHover)),h.hoverChanged.subscribe(f==null?void 0:f.onHover)),f!=null&&f.targets)if(Array.isArray(f.targets)&&typeof f.targets[0]!="string")h.targets=f.targets;else if(Array.isArray(f.targets)&&typeof f.targets[0]=="string"){var m=f.targets;h.includeList=new Map(m.map(function(b){return[b,!0]})),h.targetsSelector=function(){return h.getAllTargets().filter(function(b){return h.includeList.get(b.id)})}}else typeof f.targets=="string"&&(h.typeMap.set("targetsSelector",f.targets),f.targets=(0,i.getFunction)(o.EBaseType.OptionFunction,f.targets)),h.targetsSelector=f.targets;return h}return Object.defineProperty(d.prototype,"hoverMode",{get:function(){return this.hoverModeProperty},set:function(f){this.hoverModeProperty=f},enumerable:!1,configurable:!0}),d.prototype.toJSON=function(){var f,h=c.prototype.toJSON.call(this).options,p={hoverMode:this.hoverMode,enableHover:this.enableHoverProperty,notifyOutEvent:this.notifyOutEvent,notifyPositionUpdate:this.notifyPositionUpdate,onHover:this.typeMap.get("onHover"),targets:this.includeList?Array.from(this.includeList).filter(function(g){g[0];var v=g[1];return v}).map(function(g){var v=g[0];return v}):this.typeMap.get("targetsSelector")||((f=this.targets)===null||f===void 0?void 0:f.map(function(g){var v=g.id;return v}))};return{type:this.type,options:e(e({},h),p)}},d.prototype.modifierMouseMove=function(f){if(!(this.parentSurface.isSubSurface&&!f.isActiveSubChartEvent)){this.activePointerEvents.set(f.pointerId,f),c.prototype.modifierMouseMove.call(this,f);var h;if(this.mousePoint)h=(0,l.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect),h?this.mousePosition=s.EMousePosition.SeriesArea:this.mousePosition=s.EMousePosition.AxisArea;else{this.mousePosition=s.EMousePosition.OutOfCanvas;return}var p=this.getIsActionAllowed(f);p&&this.enableHoverProperty&&this.performHoverAction(f)}},d.prototype.modifierMouseLeave=function(f){if(c.prototype.modifierMouseLeave.call(this,f),this.mousePosition=s.EMousePosition.OutOfCanvas,this.enableHoverProperty){for(var h=this.getIncludedTargets(),p=h.length,g=null,v=!1,y=p-1;y>-1;--y)g=h[y],this.performHoverOnEntity(g,f,v);var m=this.previousHoveredEntities.length>0;m&&this.hoverChanged.raiseEvent({sender:this,mouseArgs:f,hoveredEntities:[],includedEntities:h,unhoveredEntities:this.previousHoveredEntities,previousHoveredEntities:this.previousHoveredEntities}),this.previousHoveredEntities=[]}},d.prototype.modifierPointerCancel=function(f){this.modifierMouseLeave(f)},d.prototype.getIncludedTargets=function(){var f,h,p;return(p=(f=this.targets)!==null&&f!==void 0?f:(h=this.targetsSelector)===null||h===void 0?void 0:h.call(this,this))!==null&&p!==void 0?p:this.getAllTargets()},d.prototype.performHoverAction=function(f){var h=this,p=this.getIncludedTargets(),g=[],v=[];if(this.hoverMode===a.EHoverMode.TopmostIncluded){for(var y=p.length,m=y-1;m>-1;--m){var b=p[m],S=b.checkIsWithinBounds(f);if(S){g.push(b),this.performHoverOnEntity(b,f,S);break}}this.previousHoveredEntities.forEach(function(D){D!==g[0]&&(v.push(D),h.performHoverOnEntity(D,f,!1))})}else if(this.hoverMode===a.EHoverMode.AbsoluteTopmost){for(var _=this.getAllTargets(),y=_.length,C=function(F){var I=_[F],V=I.checkIsWithinBounds(f);if(V){var z=p.find(function(G){return G===I});return z&&(g.push(I),P.performHoverOnEntity(I,f,V)),"break"}},P=this,m=y-1;m>-1;--m){var x=C(m);if(x==="break")break}this.previousHoveredEntities.forEach(function(F){F!==g[0]&&(v.push(F),h.performHoverOnEntity(F,f,!1))})}else if(this.hoverMode===a.EHoverMode.Multi)for(var y=p.length,m=y-1;m>-1;--m){var b=p[m],S=b.checkIsWithinBounds(f),E=b.isHovered;S?(g.push(b),this.performHoverOnEntity(b,f,S)):E&&(v.push(b),this.performHoverOnEntity(b,f,S))}var A=g.length>this.previousHoveredEntities.length||v.length&&g.length===this.previousHoveredEntities.length,R=this.notifyOutEvent&&v.length,M=this.notifyPositionUpdate&&g.length;(A||M||R)&&this.hoverChanged.raiseEvent({sender:this,mouseArgs:f,hoveredEntities:g,previousHoveredEntities:this.previousHoveredEntities,includedEntities:p,unhoveredEntities:v}),this.previousHoveredEntities=g},d.prototype.performHoverOnEntity=function(f,h,p){f.hover({args:h,isHovered:p,notifyOutEvent:this.notifyOutEvent,notifyPositionUpdate:this.notifyPositionUpdate})},d})(n.ChartModifierBase2D);return xb.PointerEventsMediatorModifier=u,xb}var Nbe;function aje(){if(Nbe)return Tb;Nbe=1;var t=Tb&&Tb.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})(),e=Tb&&Tb.__spreadArray||function(a,s,l){if(l||arguments.length===2)for(var u=0,c=s.length,d;u<c;u++)(d||!(u in s))&&(d||(d=Array.prototype.slice.call(s,0,u)),d[u]=s[u]);return a.concat(d||Array.prototype.slice.call(s))};Object.defineProperty(Tb,"__esModule",{value:!0}),Tb.AnnotationHoverModifier=void 0;var i=Qa(),n=Ho(),r=oje(),o=(function(a){t(s,a);function s(l){var u=a.call(this,l)||this;return u.type=n.EChart2DModifierType.AnnotationHover,u.enableHoverProperty=!0,u}return s.prototype.getAllTargets=function(){var l=this.parentSurface.annotations.asArray().filter(function(C){return!C.isHidden}),u=l.filter(function(C){return C.isDomAnnotation}),c=u.filter(function(C){return C.isSvgAnnotation}),d=u.filter(function(C){return!C.isSvgAnnotation}),f=l.filter(function(C){return!C.isSvgAnnotation}),h=d.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.Background}),p=d.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.BelowChart}),g=d.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.AboveChart}),v=c.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.Background}),y=c.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.BelowChart}),m=c.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.AboveChart}),b=f.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.Background}),S=f.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.BelowChart}),_=f.filter(function(C){return C.annotationLayer===i.EAnnotationLayer.AboveChart});return e(e(e(e(e(e(e(e(e([],h,!0),v,!0),b,!0),S,!0),_,!0),y,!0),p,!0),m,!0),g,!0)},s})(r.PointerEventsMediatorModifier);return Tb.AnnotationHoverModifier=o,Tb}var fE={},eB={},tB={},rB={},Fbe;function sje(){if(Fbe)return rB;Fbe=1,Object.defineProperty(rB,"__esModule",{value:!0}),rB.AnimationToken=void 0;var t=(function(){function e(i,n){this.token=i,this.onCompleted=n}return e.prototype.cancelAnimation=function(){this.token&&(clearInterval(this.token),this.token=void 0)},e.prototype.completeAnimation=function(){this.token&&(clearInterval(this.token),this.token=void 0),this.onCompleted&&this.onCompleted()},e})();return rB.AnimationToken=t,rB}var Bbe;function lje(){if(Bbe)return tB;Bbe=1,Object.defineProperty(tB,"__esModule",{value:!0}),tB.animateAny=void 0;var t=sje(),e=ci(),i=wre();function n(r,o,a,s,l,u,c){e.Guard.notNull(s,"onAnimate"),e.Guard.notNull(o,"from"),e.Guard.notNull(a,"to"),e.Guard.notNull(l,"interpolate");var d=new Date().getTime(),f=d+r;s(o);var h=new t.AnimationToken(setInterval(function(){var p=new Date().getTime(),g=i.NumberUtil.constrain(1-(f-p)/r,0,1),v=c(g),y=l(o,a,v);s(y),p>f&&(v!==1&&s(l(o,a,c(1))),h.completeAnimation())},16.67),u);return h}return tB.animateAny=n,tB}var jbe;function jW(){if(jbe)return eB;jbe=1,Object.defineProperty(eB,"__esModule",{value:!0}),eB.DoubleAnimator=void 0;var t=lje(),e=ad(),i=(function(){function n(){}return n.animate=function(r,o,a,s,l,u){return u===void 0&&(u=e.easing.outExpo),(0,t.animateAny)(a,r,o,s,n.interpolate,l,u)},n.interpolate=function(r,o,a){var s=(o-r)*a+r;return s},n})();return eB.DoubleAnimator=i,eB}var Vbe;function uje(){if(Vbe)return fE;Vbe=1;var t=fE&&fE.__extends||(function(){var m=function(b,S){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,C){_.__proto__=C}||function(_,C){for(var P in C)Object.prototype.hasOwnProperty.call(C,P)&&(_[P]=C[P])},m(b,S)};return function(b,S){if(typeof S!="function"&&S!==null)throw new TypeError("Class extends value "+String(S)+" is not a constructor or null");m(b,S);function _(){this.constructor=b}b.prototype=S===null?Object.create(S):(_.prototype=S.prototype,new _)}})();Object.defineProperty(fE,"__esModule",{value:!0}),fE.PolarArcZoomModifier=void 0;var e=jW(),i=ad(),n=ZV(),r=Br(),o=di(),a=$i(),s=Lm(),l=Ho(),u=$f(),c=pl(),d=xm(),f=An(),h=EW(),p=Qu(),g=km(),v=Y3(),y=(function(m){t(b,m);function b(S){var _=this,C,P,x,E,A,R,M;return _=m.call(this,S)||this,_.type=l.EChart2DModifierType.PolarArcZoom,_.isAnimated=!0,_.animationDuration=1e3,_.easingFunction=i.easing.outCubic,_.isClicked=!1,_.fillProperty="#42b64933",_.strokeProperty="#42b64977",_.strokeThicknessProperty=2,_.fill=(C=S==null?void 0:S.fill)!==null&&C!==void 0?C:_.fillProperty,_.stroke=(P=S==null?void 0:S.stroke)!==null&&P!==void 0?P:_.strokeProperty,_.strokeThickness=(x=S==null?void 0:S.strokeThickness)!==null&&x!==void 0?x:_.strokeThicknessProperty,_.isAnimated=(E=S==null?void 0:S.isAnimated)!==null&&E!==void 0?E:_.isAnimated,_.animationDuration=(A=S==null?void 0:S.animationDuration)!==null&&A!==void 0?A:_.animationDuration,S!=null&&S.easingFunction&&typeof S.easingFunction=="string"&&(S.easingFunction=i.easing[S.easingFunction]),_.easingFunction=(R=S==null?void 0:S.easingFunction)!==null&&R!==void 0?R:_.easingFunction,_.executeCondition=(M=S==null?void 0:S.executeCondition)!==null&&M!==void 0?M:{button:s.EExecuteOn.MouseLeftButton},_}return Object.defineProperty(b.prototype,"modifierType",{get:function(){return u.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),b.prototype.applyTheme=function(S){this.testPropertyChanged(g.PROPERTY.FILL)||(this.fill=S.rubberBandFillBrush),this.testPropertyChanged(g.PROPERTY.STROKE)||(this.stroke=S.rubberBandStrokeBrush)},b.prototype.onAttach=function(){m.prototype.onAttach.call(this),this.handleAddArcAnnotation()},b.prototype.onDetach=function(){m.prototype.onDetach.call(this),this.handleRemoveArcAnnotation()},b.prototype.modifierMouseDown=function(S){if(m.prototype.modifierMouseDown.call(this,S),!!this.checkExecuteConditions(S).isPrimary){if(!this.isAttached)throw new Error("Should not call PolarArcZoomModifier.modifierMouseDown if not attached");this.parentSurface.setZoomState(d.EZoomState.UserZooming);var _=(0,f.translateFromCanvasToSeriesViewRect)(S.mousePoint,this.parentSurface.seriesViewRect);if(_){var C=this.xAxis,P=this.yAxis,x=P.maxRadius,E=C.reverseTransform(_.x,_.y);E.y<=x&&(this.pointFrom=_,this.polarPointFrom=this.capPolarCoordinates(E),this.isClicked=!0)}}},b.prototype.capPolarCoordinates=function(S){var _=this.xAxis,C=this.yAxis,P=_.getCurrentCoordinateCalculator(),x=C.getCurrentCoordinateCalculator(),E=P.getDataValue(S.x),A=x.getDataValue(S.y),R=Math.max(_.visibleRange.min,Math.min(_.visibleRange.max,E)),M=Math.max(C.visibleRange.min,Math.min(C.visibleRange.max,A));return new a.Point(P.getCoordinate(R),x.getCoordinate(M))},b.prototype.getArcParams=function(){var S=this.xAxis,_=this.yAxis,C=S.getCurrentCoordinateCalculator(),P=_.getCurrentCoordinateCalculator(),x=this.polarPointFrom,E=this.polarPointTo,A=Math.min(C.getDataValue(x.x),C.getDataValue(E.x)),R=Math.max(C.getDataValue(x.x),C.getDataValue(E.x)),M=Math.min(P.getDataValue(x.y),P.getDataValue(E.y)),D=Math.max(P.getDataValue(x.y),P.getDataValue(E.y));return this.xyDirection===c.EXyDirection.XDirection?(M=_.visibleRange.min,D=_.visibleRange.max):this.xyDirection===c.EXyDirection.YDirection&&(A=S.visibleRange.min,R=S.visibleRange.max),{angleStart:A,angleEnd:R,radiusInner:M,radiusOuter:D}},b.prototype.updateArcAnnotation=function(S){var _=this.parentSurface.seriesViewRect,C=(0,f.translateFromCanvasToSeriesViewRect)(S,_);if(C){this.pointTo=C;var P=this.xAxis,x=P.reverseTransform(C.x,C.y);this.polarPointTo=this.capPolarCoordinates(x);var E=this.getArcParams();this.arcAnnotation.isHidden=!1,this.arcAnnotation.x1=E.angleStart,this.arcAnnotation.x2=E.angleEnd,this.arcAnnotation.y1=E.radiusOuter,this.arcAnnotation.y2=E.radiusInner;var A=this.calculateArcOrigin(),R=A.centerX,M=A.centerY;return this.arcAnnotation.centerX=R,this.arcAnnotation.centerY=M,E}else return this.getArcParams()},b.prototype.modifierMouseMove=function(S){m.prototype.modifierMouseMove.call(this,S),this.isClicked&&this.updateArcAnnotation(S.mousePoint)},b.prototype.clear=function(){this.pointFrom=void 0,this.polarPointFrom=void 0,this.pointTo=void 0,this.polarPointTo=void 0,this.isClicked=!1},b.prototype.modifierMouseUp=function(S){if(m.prototype.modifierMouseUp.call(this,S),!!this.checkExecuteConditions(S).isPrimary&&this.isClicked){var _=this.updateArcAnnotation(S.mousePoint);this.arcAnnotation.isHidden=!0;var C=this.calculateDraggedDistance();this.clear(),_&&C>v.RubberBandXyZoomModifier.MIN_DRAG_SENSITIVITY&&this.performZoom(_)}},Object.defineProperty(b.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(S){this.strokeThicknessProperty=S,this.notifyPropertyChanged(g.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(S){this.strokeProperty=S,this.notifyPropertyChanged(g.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"fill",{get:function(){return this.fillProperty},set:function(S){this.fillProperty=S,this.notifyPropertyChanged(g.PROPERTY.FILL)},enumerable:!1,configurable:!0}),b.prototype.toJSON=function(){var S=m.prototype.toJSON.call(this),_={animationDuration:this.animationDuration,easingFunction:this.easingFunction.name,fill:this.fill,isAnimated:this.isAnimated,stroke:this.stroke,strokeThickness:this.strokeThickness};return Object.assign(S.options,_),S},b.prototype.delete=function(){this.parentSurfaceProperty=void 0,this.handleRemoveArcAnnotation(),m.prototype.delete.call(this)},b.prototype.performZoom=function(S){var _=this.parentSurface;if(_){var C=S.angleStart,P=S.angleEnd,x=S.radiusInner,E=S.radiusOuter,A=this.xAxis,R=this.yAxis,M=A.visibleRange,D=M.min,F=M.max,I=R.visibleRange,V=I.min,z=I.max,G=A.startAngle,H=A.totalAngle,U=A.flippedCoordinates;if(this.isAnimated&&this.animationDuration>0){var k=new n.GenericAnimation({from:{x1:D,x2:F,y1:V,y2:z},to:{x1:C,x2:P,y1:x,y2:E},duration:this.animationDuration,ease:this.easingFunction,onAnimate:function(W,Y,te){var oe=e.DoubleAnimator.interpolate(W.x1,Y.x1,te),de=e.DoubleAnimator.interpolate(W.x2,Y.x2,te),ge=e.DoubleAnimator.interpolate(W.y1,Y.y1,te),Ee=e.DoubleAnimator.interpolate(W.y2,Y.y2,te);A.visibleRange=new o.NumberRange(oe,de),R.visibleRange=new o.NumberRange(ge,Ee);var Re=U?G-H*(de-F)/(F-D):G+H*(oe-D)/(F-D);A.startAngle=Re,R.startAngle=Re,A.totalAngle=H*(de-oe)/(F-D),R.innerRadius=ge/Ee}});_.addAnimation(k)}else{A.visibleRange=new o.NumberRange(C,P),R.visibleRange=new o.NumberRange(x,E);var X=U?G-H*(P-F)/(F-D):G+H*(C-D)/(F-D);A.startAngle=X,R.startAngle=X,A.totalAngle=H*(P-C)/(F-D),R.innerRadius=x/E}}},b.prototype.calculateDraggedDistance=function(){var S=Math.pow(this.pointFrom.x-this.pointTo.x,2),_=Math.pow(this.pointFrom.y-this.pointTo.y,2);return Math.sqrt(S+_)},b.prototype.calculateArcOrigin=function(){var S=this.xAxis,_=this.yAxis,C=S.isAngular?_:S,P=C.visibleRange.max-C.visibleRange.min,x=P*(C.innerRadius/(1-C.innerRadius)),E;return C.flippedCoordinates?(E=C.visibleRange.max,C.innerRadius>0&&(E+=x)):(E=C.visibleRange.min,C.innerRadius>0&&(E-=x)),{centerX:0,centerY:E}},b.prototype.handleAddArcAnnotation=function(){var S=this.calculateArcOrigin(),_=S.centerX,C=S.centerY;this.arcAnnotation=new h.PolarArcAnnotation({isHidden:!0,x1:0,x2:1,y2:0,y1:1,centerX:_,centerY:C,stroke:this.stroke,strokeThickness:this.strokeThickness,fill:this.fill,opacity:1,xAxisId:this.xAxisId,yAxisId:this.yAxisId}),this.parentSurface.modifierAnnotations.add(this.arcAnnotation)},b.prototype.handleRemoveArcAnnotation=function(){var S;(S=this.parentSurface)===null||S===void 0||S.modifierAnnotations.remove(this.arcAnnotation,!0),this.arcAnnotation=(0,r.deleteSafe)(this.arcAnnotation)},b.MIN_DRAG_SENSITIVITY=5,b})(p.ChartModifierBase2D);return fE.PolarArcZoomModifier=y,fE}var hE={},Hbe;function cje(){if(Hbe)return hE;Hbe=1;var t=hE&&hE.__extends||(function(){var x=function(E,A){return x=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(R,M){R.__proto__=M}||function(R,M){for(var D in M)Object.prototype.hasOwnProperty.call(M,D)&&(R[D]=M[D])},x(E,A)};return function(E,A){if(typeof A!="function"&&A!==null)throw new TypeError("Class extends value "+String(A)+" is not a constructor or null");x(E,A);function R(){this.constructor=E}E.prototype=A===null?Object.create(A):(R.prototype=A.prototype,new R)}})();Object.defineProperty(hE,"__esModule",{value:!0}),hE.PolarCursorModifier=void 0;var e=mo(),i=pa(),n=jv(),r=ga(),o=Ho(),a=Gy(),s=$f(),l=GS(),u=An(),c=Ca(),d=II(),f=Pie(),h=Qa(),p=rC(),g=Jz(),v=EW(),y=nR(),m=Sn(),b=Zi(),S=Qu(),_=km(),C=YO(),P=(function(x){t(E,x);function E(A){var R=this,M,D,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e;return R=x.call(this,A)||this,R.type=o.EChart2DModifierType.PolarCursor,R.tooltipSvgTemplate=C.defaultCursorTooltipSvgTemplate,R.lineThickness=2,R.lineDashArray=[],R.tooltipContainerBackground="#228B22",R.tooltipTextStroke="#fff",R.showTooltip=!1,R.axisLabelStroke="#fff",R.axisLabelFill="#228B22",R.xAxisLabelStroke=void 0,R.xAxisLabelFill=void 0,R.yAxisLabelStroke=void 0,R.yAxisLabelFill=void 0,R.tooltipLegendOffsetX=0,R.tooltipLegendOffsetY=0,R.hitTestRadius=0,R.mousePosition=l.EMousePosition.OutOfCanvas,R.lineColorProperty=m.SciChartSurfaceBase.DEFAULT_THEME.cursorLineBrush,R.tooltipShadowProperty=m.SciChartSurfaceBase.DEFAULT_THEME.shadowEffectColor,R.showRadialLineProperty=!0,R.showCircularLineProperty=!0,R.showAxisLabelsProperty=!0,R.angularAxisLabelPlacementProperty=a.EAngularAxisLabelPlacement.Outer,R.radialAxisLabelPlacementProperty=a.ERadialAxisLabelPlacement.Bottom,A!=null&&A.tooltipSvgTemplate&&typeof A.tooltipSvgTemplate=="string"&&(R.typeMap.set("tooltipSvgTemplate",A.tooltipSvgTemplate),A.tooltipSvgTemplate=(0,e.getFunction)(r.EBaseType.OptionFunction,A.tooltipSvgTemplate)),R.tooltipSvgTemplate=(M=A==null?void 0:A.tooltipSvgTemplate)!==null&&M!==void 0?M:R.tooltipSvgTemplate,R.lineThickness=(D=A==null?void 0:A.lineThickness)!==null&&D!==void 0?D:R.lineThickness,R.lineDashArray=(F=A==null?void 0:A.lineDashArray)!==null&&F!==void 0?F:R.lineDashArray,R.lineColor=(I=A==null?void 0:A.lineColor)!==null&&I!==void 0?I:R.lineColor,R.tooltipContainerBackground=(V=A==null?void 0:A.tooltipContainerBackground)!==null&&V!==void 0?V:R.tooltipContainerBackground,R.tooltipTextStroke=(z=A==null?void 0:A.tooltipTextStroke)!==null&&z!==void 0?z:R.tooltipTextStroke,R.tooltipShadow=(G=A==null?void 0:A.tooltipShadow)!==null&&G!==void 0?G:R.tooltipShadowProperty,R.showTooltip=(H=A==null?void 0:A.showTooltip)!==null&&H!==void 0?H:R.showTooltip,R.showAxisLabels=(U=A==null?void 0:A.showAxisLabels)!==null&&U!==void 0?U:R.showAxisLabels,R.axisLabelFill=(k=A==null?void 0:A.axisLabelFill)!==null&&k!==void 0?k:R.axisLabelFill,R.axisLabelStroke=(X=A==null?void 0:A.axisLabelStroke)!==null&&X!==void 0?X:R.axisLabelStroke,R.angularAxisLabelPlacement=(W=A==null?void 0:A.angularAxisLabelPlacement)!==null&&W!==void 0?W:R.angularAxisLabelPlacementProperty,R.radialAxisLabelPlacement=(Y=A==null?void 0:A.radialAxisLabelPlacement)!==null&&Y!==void 0?Y:R.radialAxisLabelPlacementProperty,R.xAxisLabelStroke=(te=A==null?void 0:A.xAxisLabelStroke)!==null&&te!==void 0?te:R.xAxisLabelStroke,R.xAxisLabelFill=(oe=A==null?void 0:A.xAxisLabelFill)!==null&&oe!==void 0?oe:R.xAxisLabelFill,R.yAxisLabelStroke=(de=A==null?void 0:A.yAxisLabelStroke)!==null&&de!==void 0?de:R.yAxisLabelStroke,R.yAxisLabelFill=(ge=A==null?void 0:A.yAxisLabelFill)!==null&&ge!==void 0?ge:R.yAxisLabelFill,R.placementDivIdProperty=(Ee=A==null?void 0:A.placementDivId)!==null&&Ee!==void 0?Ee:R.placementDivIdProperty,A!=null&&A.tooltipLegendTemplate&&typeof A.tooltipLegendTemplate=="string"&&(R.typeMap.set("tooltipLegendTemplate",A.tooltipLegendTemplate),A.tooltipLegendTemplate=(0,e.getFunction)(r.EBaseType.OptionFunction,A.tooltipLegendTemplate)),R.tooltipLegendTemplate=(Re=A==null?void 0:A.tooltipLegendTemplate)!==null&&Re!==void 0?Re:R.tooltipLegendTemplate,R.tooltipLegendOffsetX=(Ae=A==null?void 0:A.tooltipLegendOffsetX)!==null&&Ae!==void 0?Ae:R.tooltipLegendOffsetX,R.tooltipLegendOffsetY=(Pe=A==null?void 0:A.tooltipLegendOffsetY)!==null&&Pe!==void 0?Pe:R.tooltipLegendOffsetY,A!=null&&A.tooltipDataTemplate&&typeof A.tooltipDataTemplate=="string"&&(R.typeMap.set("tooltipDataTemplate",A.tooltipDataTemplate),A.tooltipDataTemplate=(0,e.getFunction)(r.EBaseType.OptionFunction,A.tooltipDataTemplate)),R.tooltipDataTemplateProperty=(we=A==null?void 0:A.tooltipDataTemplate)!==null&&we!==void 0?we:R.tooltipDataTemplateProperty,R.showRadialLine=(Te=A==null?void 0:A.showRadialLine)!==null&&Te!==void 0?Te:R.showRadialLine,R.showCircularLine=(ke=A==null?void 0:A.showCircularLine)!==null&&ke!==void 0?ke:R.showCircularLine,R.hitTestRadius=($e=A==null?void 0:A.hitTestRadius)!==null&&$e!==void 0?$e:R.hitTestRadius,R}return Object.defineProperty(E.prototype,"modifierType",{get:function(){return s.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),E.prototype.applyTheme=function(A){this.testPropertyChanged(_.PROPERTY.CROSSHAIR_STROKE)||(this.lineColor=A.cursorLineBrush),this.testPropertyChanged(_.PROPERTY.TOOLTIP_SHADOW)||(this.tooltipShadow=A.shadowEffectColor)},E.prototype.onAttach=function(){var A;x.prototype.onAttach.call(this),this.showRadialLine&&this.handleAddRadialLine(),this.showCircularLine&&this.handleAddCircularLine(),this.showRadialLine&&this.handleAddRadialLabel(),this.showCircularLine&&this.handleAddCircularLabel(),this.tooltipAnnotation=new f.CursorTooltipSvgAnnotation({cursorModifier:this,xCoordinateMode:c.ECoordinateMode.Pixel,yCoordinateMode:c.ECoordinateMode.Pixel,tooltipSvgTemplate:(A=this.tooltipSvgTemplate)!==null&&A!==void 0?A:C.defaultCursorTooltipSvgTemplate,containerBackground:this.tooltipContainerBackground,textStroke:this.tooltipTextStroke,tooltipLegendTemplate:this.tooltipLegendTemplate,tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,xAxisId:this.xAxisId,yAxisId:this.yAxisId,placementDivId:this.placementDivId}),this.parentSurface.modifierAnnotations.add(this.tooltipAnnotation)},E.prototype.onDetach=function(){x.prototype.onDetach.call(this),this.radialAnnotation&&(this.handleRemoveRadialLine(),this.handleRemoveRadialLabel()),this.circularAnnotation&&(this.handleRemoveCircularLine(),this.handleRemoveCircularLabel()),this.parentSurface.modifierAnnotations.remove(this.tooltipAnnotation,!0)},E.prototype.onAttachSeries=function(A){this.tooltipAnnotation.seriesInfos=this.getSeriesInfos()},E.prototype.onDetachSeries=function(A){this.tooltipAnnotation.seriesInfos=this.getSeriesInfos()},E.prototype.modifierMouseMove=function(A){if(!(this.parentSurface.isSubSurface&&!A.isActiveSubChartEvent)){this.activePointerEvents.set(A.pointerId,A),x.prototype.modifierMouseMove.call(this,A);var R;this.mousePoint?(R=(0,u.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect),R?this.mousePosition=l.EMousePosition.SeriesArea:this.mousePosition=l.EMousePosition.AxisArea):this.mousePosition=l.EMousePosition.OutOfCanvas;var M=this.getIsActionAllowed(A);M&&this.update()}},E.prototype.modifierMouseLeave=function(A){x.prototype.modifierMouseLeave.call(this,A),this.mousePosition=l.EMousePosition.OutOfCanvas,this.update()},E.prototype.onParentSurfaceRendered=function(){this.update()},Object.defineProperty(E.prototype,"lineColor",{get:function(){return this.lineColorProperty},set:function(A){this.lineColorProperty!==A&&(this.lineColorProperty=A,this.notifyPropertyChanged(_.PROPERTY.CROSSHAIR_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"tooltipShadow",{get:function(){return this.tooltipShadowProperty},set:function(A){this.tooltipShadowProperty!==A&&(this.tooltipShadowProperty=A,this.notifyPropertyChanged(_.PROPERTY.TOOLTIP_SHADOW))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"showRadialLine",{get:function(){return this.showRadialLineProperty},set:function(A){this.showRadialLineProperty!==A&&(this.showRadialLineProperty=A,this.showRadialLineProperty&&!this.radialAnnotation?(this.handleAddRadialLine(),this.handleRemoveCircularLabel(),this.handleAddCircularLabel(),this.handleAddRadialLabel()):!this.showRadialLineProperty&&this.radialAnnotation&&(this.handleRemoveRadialLine(),this.handleRemoveRadialLabel()),this.notifyPropertyChanged(_.PROPERTY.X_LINE))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"showCircularLine",{get:function(){return this.showCircularLineProperty},set:function(A){this.showCircularLineProperty!==A&&(this.showCircularLineProperty=A,this.showCircularLineProperty&&!this.circularAnnotation?(this.handleAddCircularLine(),this.handleRemoveRadialLabel(),this.handleAddRadialLabel(),this.handleAddCircularLabel()):!this.showCircularLineProperty&&this.circularAnnotation&&(this.handleRemoveCircularLine(),this.handleRemoveCircularLabel()),this.notifyPropertyChanged(_.PROPERTY.Y_LINE))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"showAxisLabels",{get:function(){return this.showAxisLabelsProperty},set:function(A){this.showAxisLabelsProperty!==A&&(this.showAxisLabelsProperty=A,this.notifyPropertyChanged(_.PROPERTY.AXIS_LABELS))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"angularAxisLabelPlacement",{get:function(){return this.angularAxisLabelPlacementProperty},set:function(A){this.angularAxisLabelPlacementProperty!==A&&(this.angularAxisLabelPlacementProperty=A,this.notifyPropertyChanged(_.PROPERTY.ANGULAR_AXIS_LABELS_PLACEMENT))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"radialAxisLabelPlacement",{get:function(){return this.radialAxisLabelPlacementProperty},set:function(A){this.radialAxisLabelPlacementProperty!==A&&(this.radialAxisLabelPlacementProperty=A,this.notifyPropertyChanged(_.PROPERTY.RADIAL_AXIS_LABELS_PLACEMENT))},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(A){this.placementDivIdProperty!==A&&(this.placementDivIdProperty=A,this.notifyPropertyChanged(_.PROPERTY.PLACEMENT_DIV_ID))},enumerable:!1,configurable:!0}),E.prototype.includeSeries=function(A,R){return x.prototype.includeSeries.call(this,A,R)?(this.tooltipAnnotation.seriesInfos=this.getSeriesInfos(),!0):!1},Object.defineProperty(E.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(A){this.tooltipDataTemplateProperty=A,this.notifyPropertyChanged(_.PROPERTY.TOOLTIP_DATA_TEMPLATE)},enumerable:!1,configurable:!0}),E.prototype.hitTestRenderableSeries=function(A,R){if(R)return this.hitTestRadius<=0?A.hitTestProvider.hitTestXSlice(R.x,R.y):A.hitTestProvider.hitTestDataPoint(R.x,R.y,this.hitTestRadius)},E.prototype.getMousePosition=function(){return this.mousePosition},E.prototype.toJSON=function(){var A=x.prototype.toJSON.call(this),R={axisLabelFill:this.axisLabelFill,axisLabelStroke:this.axisLabelStroke,angularAxisLabelPlacement:this.angularAxisLabelPlacement,radialAxisLabelPlacement:this.radialAxisLabelPlacement,xAxisLabelFill:this.xAxisLabelFill,xAxisLabelStroke:this.xAxisLabelStroke,yAxisLabelFill:this.yAxisLabelFill,yAxisLabelStroke:this.yAxisLabelStroke,lineColor:this.lineColor,lineDashArray:this.lineDashArray,lineThickness:this.lineThickness,hitTestRadius:this.hitTestRadius,placementDivId:this.placementDivId,showAxisLabels:this.showAxisLabels,showTooltip:this.showTooltip,showRadialLine:this.showRadialLine,showCircularLine:this.showCircularLine,tooltipContainerBackground:this.tooltipContainerBackground,tooltipDataTemplate:this.typeMap.get("tooltipDataTemplate"),tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,tooltipLegendTemplate:this.typeMap.get("tooltipLegendTemplate"),tooltipSvgTemplate:this.typeMap.get("tooltipSvgTemplate"),tooltipTextStroke:this.tooltipTextStroke,tooltipShadow:this.tooltipShadow};return Object.assign(A.options,R),A},E.prototype.notifyPropertyChanged=function(A){x.prototype.notifyPropertyChanged.call(this,A),A===_.PROPERTY.X_AXIS_ID&&(this.tooltipAnnotation&&(this.tooltipAnnotation.xAxisId=this.xAxisId),this.radialAnnotation&&(this.radialAnnotation.xAxisId=this.xAxisId,this.angularAxisLabelAnnotation.xAxisId=this.xAxisId),this.circularAnnotation&&(this.circularAnnotation.xAxisId=this.xAxisId,this.radialAxisLabelAnnotation.xAxisId=this.xAxisId)),A===_.PROPERTY.Y_AXIS_ID&&(this.tooltipAnnotation&&(this.tooltipAnnotation.yAxisId=this.yAxisId),this.radialAnnotation&&(this.radialAnnotation.yAxisId=this.yAxisId,this.angularAxisLabelAnnotation.yAxisId=this.yAxisId),this.circularAnnotation&&(this.circularAnnotation.yAxisId=this.yAxisId,this.radialAxisLabelAnnotation.yAxisId=this.yAxisId))},E.prototype.getSeriesInfos=function(){var A=this;return this.getIncludedRenderableSeries().map(function(R){var M=A.hitTestRenderableSeries(R,A.mousePoint);if(M)return R.getSeriesInfo(M)}).filter(function(R){return R!==void 0})},E.prototype.update=function(){if(this.mousePosition!==l.EMousePosition.SeriesArea){this.radialAnnotation&&(this.radialAnnotation.isHidden=!0,this.angularAxisLabelAnnotation.isHidden=!0),this.circularAnnotation&&(this.circularAnnotation.isHidden=!0,this.radialAxisLabelAnnotation.isHidden=!0),this.tooltipAnnotation&&(this.tooltipAnnotation.isHidden=!0,this.tooltipAnnotation.seriesInfos=[],this.placementDivId&&this.tooltipAnnotation.delete());return}var A=(0,u.translateFromCanvasToSeriesViewRect)(this.mousePoint,this.parentSurface.seriesViewRect);if(A){var R=A.x,M=A.y,D=this.xAxis,F=this.yAxis,I=D.reverseTransform(R,M);if(I.x>D.totalAngle){this.radialAnnotation.isHidden=!0,this.angularAxisLabelAnnotation.isHidden=!0,this.circularAnnotation.isHidden=!0,this.radialAxisLabelAnnotation.isHidden=!0,this.tooltipAnnotation.isHidden=!0;return}this.radialAnnotation&&(this.radialAnnotation.isHidden=!1,this.angularAxisLabelAnnotation.isHidden=!this.showAxisLabels),this.circularAnnotation&&(this.circularAnnotation.isHidden=!1,this.radialAxisLabelAnnotation.isHidden=!this.showAxisLabels),this.tooltipAnnotation.isHidden=!1,this.tooltipAnnotation.showTooltip=this.showTooltip;var V=F.getAxisSize(),z=D.getCurrentCoordinateCalculator(),G=F.getCurrentCoordinateCalculator();if(this.radialAnnotation){var H=z.getDataValue(I.x);this.radialAnnotation.x1=0,this.radialAnnotation.y1=0,this.radialAnnotation.x2=I.x,this.radialAnnotation.y2=V/b.DpiHelper.PIXEL_RATIO,this.angularAxisLabelAnnotation.x1=I.x,this.angularAxisLabelAnnotation.y1=V/b.DpiHelper.PIXEL_RATIO,this.angularAxisLabelAnnotation.text=H.toFixed(3);var U=y.labelHelper.getLabelRotationAndPlacementForAngularAxis(I.x+D.startAngle,D.polarLabelMode,this.angularAxisLabelPlacement),k=U.resultAngle,X=U.horizontalAnchorPoint,W=U.verticalAnchorPoint;this.angularAxisLabelAnnotation.verticalAnchorPoint=W,this.angularAxisLabelAnnotation.horizontalAnchorPoint=X,this.angularAxisLabelAnnotation.rotation=k}if(this.circularAnnotation){var Y=Math.min(I.y,V),te=G.getDataValue(Y),oe=this.circularAnnotation,de=z.isFlipped;oe.y1=G.getDataValue(Y),oe.x1=de?z.getDataValue(D.totalAngle-.001):z.getDataValue(0),oe.x2=de?z.getDataValue(0):z.getDataValue(D.totalAngle-.001),this.radialAxisLabelAnnotation.x1=F.startAngle-D.startAngle,this.radialAxisLabelAnnotation.y1=Y/b.DpiHelper.PIXEL_RATIO,this.radialAxisLabelAnnotation.text=te.toFixed(3),this.radialAxisLabelAnnotation.verticalAnchorPoint=y.labelHelper.getLabelPlacementForRadialAxis(this.radialAxisLabelPlacement),this.radialAxisLabelAnnotation.horizontalAnchorPoint=n.EHorizontalAnchorPoint.Center,this.radialAxisLabelAnnotation.rotation=0}this.showTooltip&&(this.tooltipAnnotation.x1=(0,u.translateToNotScaled)(A.x),this.tooltipAnnotation.y1=(0,u.translateToNotScaled)(A.y)),(this.showTooltip||this.tooltipLegendTemplate)&&(this.tooltipAnnotation.seriesInfos=this.getSeriesInfos())}},E.prototype.newLineAnnotation=function(A,R){return new p.LineAnnotation({xCoordinateMode:c.ECoordinateMode.Pixel,yCoordinateMode:c.ECoordinateMode.Pixel,strokeThickness:this.lineThickness,strokeDashArray:this.lineDashArray,stroke:this.lineColor,isHidden:!0,showLabel:this.showAxisLabels,axisLabelFill:A,axisLabelStroke:R,xAxisId:this.xAxisId,yAxisId:this.yAxisId})},E.prototype.newNativeTextAnnotation=function(A,R){return new g.NativeTextAnnotation({isHidden:!0,xCoordinateMode:c.ECoordinateMode.Pixel,yCoordinateMode:c.ECoordinateMode.Pixel,fontSize:18,textColor:R,background:A,padding:i.Thickness.fromNumber(4),isEditable:!1,annotationLayer:h.EAnnotationLayer.AboveChart,clipping:d.EAnnotationClippingMode.Chart})},E.prototype.newArcAnnotation=function(A,R){return new v.PolarArcAnnotation({isHidden:!0,y2:0,stroke:this.lineColor,strokeThickness:this.lineThickness,xAxisId:this.xAxisId,yAxisId:this.yAxisId,isLineMode:!0})},E.prototype.isVerticalChart=function(){var A,R;return(R=(A=this.xAxis)===null||A===void 0?void 0:A.isVerticalChart)!==null&&R!==void 0?R:!1},E.prototype.handleAddRadialLine=function(){var A,R,M=(A=this.xAxisLabelFill)!==null&&A!==void 0?A:this.axisLabelFill,D=(R=this.xAxisLabelStroke)!==null&&R!==void 0?R:this.axisLabelStroke;this.radialAnnotation=this.newLineAnnotation(M,D),this.parentSurface.modifierAnnotations.add(this.radialAnnotation)},E.prototype.handleRemoveRadialLine=function(){this.parentSurface.modifierAnnotations.remove(this.radialAnnotation,!0),this.radialAnnotation=void 0},E.prototype.handleAddRadialLabel=function(){var A,R,M=(A=this.xAxisLabelFill)!==null&&A!==void 0?A:this.axisLabelFill,D=(R=this.xAxisLabelStroke)!==null&&R!==void 0?R:this.axisLabelStroke;this.angularAxisLabelAnnotation=this.newNativeTextAnnotation(M,D),this.parentSurface.modifierAnnotations.add(this.angularAxisLabelAnnotation)},E.prototype.handleRemoveRadialLabel=function(){this.parentSurface.modifierAnnotations.remove(this.angularAxisLabelAnnotation,!0),this.angularAxisLabelAnnotation=void 0},E.prototype.handleAddCircularLine=function(){var A,R,M=(A=this.yAxisLabelFill)!==null&&A!==void 0?A:this.axisLabelFill,D=(R=this.yAxisLabelStroke)!==null&&R!==void 0?R:this.axisLabelStroke;this.circularAnnotation=this.newArcAnnotation(M,D),this.parentSurface.modifierAnnotations.add(this.circularAnnotation)},E.prototype.handleRemoveCircularLine=function(){this.parentSurface.modifierAnnotations.remove(this.circularAnnotation,!0),this.circularAnnotation=void 0},E.prototype.handleAddCircularLabel=function(){var A,R,M=(A=this.yAxisLabelFill)!==null&&A!==void 0?A:this.axisLabelFill,D=(R=this.yAxisLabelStroke)!==null&&R!==void 0?R:this.axisLabelStroke;this.radialAxisLabelAnnotation=this.newNativeTextAnnotation(M,D),this.parentSurface.modifierAnnotations.add(this.radialAxisLabelAnnotation)},E.prototype.handleRemoveCircularLabel=function(){this.parentSurface.modifierAnnotations.remove(this.radialAxisLabelAnnotation,!0),this.radialAxisLabelAnnotation=void 0},E})(S.ChartModifierBase2D);return hE.PolarCursorModifier=P,hE}var pE={},Ube;function dje(){if(Ube)return pE;Ube=1;var t=pE&&pE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(pE,"__esModule",{value:!0}),pE.PolarDataPointSelectionModifier=void 0;var e=Ho(),i=$f(),n=t$(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.EChart2DModifierType.PolarDataPointSelection,l}return Object.defineProperty(a.prototype,"modifierType",{get:function(){return i.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),a})(n.DataPointSelectionModifier);return pE.PolarDataPointSelectionModifier=r,pE}var gE={},zbe;function fje(){if(zbe)return gE;zbe=1;var t=gE&&gE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(gE,"__esModule",{value:!0}),gE.PolarSeriesSelectionModifier=void 0;var e=Ho(),i=$f(),n=Aie(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.EChart2DModifierType.PolarSeriesSelection,l}return Object.defineProperty(a.prototype,"modifierType",{get:function(){return i.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),a})(n.SeriesSelectionModifier);return gE.PolarSeriesSelectionModifier=r,gE}var vE={},$be;function hje(){if($be)return vE;$be=1;var t=vE&&vE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(vE,"__esModule",{value:!0}),vE.PolarLegendModifier=void 0;var e=Ho(),i=$f(),n=Eie(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.EChart2DModifierType.PolarLegend,l}return Object.defineProperty(a.prototype,"modifierType",{get:function(){return i.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),a})(n.LegendModifier);return vE.PolarLegendModifier=r,vE}var Eb={},Wbe;function pje(){if(Wbe)return Eb;Wbe=1;var t=Eb&&Eb.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})(),e=Eb&&Eb.__rest||function(u,c){var d={};for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&c.indexOf(f)<0&&(d[f]=u[f]);if(u!=null&&typeof Object.getOwnPropertySymbols=="function")for(var h=0,f=Object.getOwnPropertySymbols(u);h<f.length;h++)c.indexOf(f[h])<0&&Object.prototype.propertyIsEnumerable.call(u,f[h])&&(d[f[h]]=u[f[h]]);return d};Object.defineProperty(Eb,"__esModule",{value:!0}),Eb.PolarMouseWheelZoomModifier=void 0;var i=Ho(),n=$f(),r=pl(),o=uR(),a=r$(),s=di(),l=(function(u){t(c,u);function c(d){var f=this,h,p,g,v,y=d??{};y.executeCondition,y.secondaryExecuteCondition;var m=e(y,["executeCondition","secondaryExecuteCondition"]);return f=u.call(this,m)||this,f.type=i.EChart2DModifierType.PolarMouseWheelZoom,f.defaultActionType=a.EActionType.Zoom,f.zoomSize=!0,f.defaultActionType=(h=d==null?void 0:d.defaultActionType)!==null&&h!==void 0?h:f.defaultActionType,f.executeCondition=(p=d==null?void 0:d.executeCondition)!==null&&p!==void 0?p:{key:o.EModifierMouseArgKey.None},f.secondaryExecuteCondition=(g=d==null?void 0:d.secondaryExecuteCondition)!==null&&g!==void 0?g:{key:o.EModifierMouseArgKey.Ctrl},f.zoomSize=(v=d==null?void 0:d.zoomSize)!==null&&v!==void 0?v:f.zoomSize,f}return Object.defineProperty(c.prototype,"modifierType",{get:function(){return n.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),c.prototype.modifierMouseWheel=function(d){var f=this.checkExecuteConditions(d),h=f.isPrimary,p=f.isSecondary;h?this.actionType=this.defaultActionType:p?this.actionType=this.defaultActionType===a.EActionType.Pan?a.EActionType.Zoom:a.EActionType.Pan:this.actionType=void 0,this.xyDirection=r.EXyDirection.XyDirection,u.prototype.modifierMouseWheel.call(this,d)},c.prototype.performPan=function(d){var f=this,h=!1;return[r.EXyDirection.XDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedXAxis().forEach(function(p){var g=Math.PI,v=d*f.growFactor*g;p.startAngle+=v,h=!0}),[r.EXyDirection.YDirection,r.EXyDirection.XyDirection].includes(this.xyDirection)&&this.getIncludedYAxis().forEach(function(p){var g=Math.PI,v=d*f.growFactor*g;p.startAngle+=v,h=!0}),h},c.prototype.toJSON=function(){var d=u.prototype.toJSON.call(this),f={zoomSize:this.zoomSize,defaultActionType:this.defaultActionType};return Object.assign(d.options,f),d},c.prototype.growBy=function(d,f,h){var p=f;if(!p.isAngular)if(this.zoomSize)p.lengthScale-=h;else{var g=p.visibleRange,v=g.min,y=g.max,m=y*(1+h);p.visibleRange=new s.NumberRange(v,m)}},c})(a.MouseWheelZoomModifier);return Eb.PolarMouseWheelZoomModifier=l,Eb}var yE={},Gbe;function gje(){if(Gbe)return yE;Gbe=1;var t=yE&&yE.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(yE,"__esModule",{value:!0}),yE.PolarZoomExtentsModifier=void 0;var e=jW(),i=ad(),n=ZV(),r=$i(),o=Ho(),a=$f(),s=pl(),l=xm(),u=Rie(),c=(function(d){t(f,d);function f(h){var p=this,g,v,y,m,b,S;return p=d.call(this,h)||this,p.type=o.EChart2DModifierType.PolarZoomExtents,p.resetRanges=!0,p.resetStartAngles=!0,p.resetTotalAngle=!0,p.resetLengthScale=!0,p.resetCenterPoint=!0,p.resetInnerRadius=!0,p.xStartAngle=h==null?void 0:h.xStartAngle,p.yStartAngle=h==null?void 0:h.yStartAngle,p.totalAngle=h==null?void 0:h.totalAngle,p.lengthScale=h==null?void 0:h.lengthScale,p.centerPoint=h==null?void 0:h.centerPoint,p.innerRadius=h==null?void 0:h.innerRadius,p.resetRanges=(g=h==null?void 0:h.resetRanges)!==null&&g!==void 0?g:p.resetRanges,p.resetStartAngles=(v=h==null?void 0:h.resetStartAngles)!==null&&v!==void 0?v:p.resetStartAngles,p.resetTotalAngle=(y=h==null?void 0:h.resetTotalAngle)!==null&&y!==void 0?y:p.resetTotalAngle,p.resetLengthScale=(m=h==null?void 0:h.resetLengthScale)!==null&&m!==void 0?m:p.resetLengthScale,p.resetCenterPoint=(b=h==null?void 0:h.resetCenterPoint)!==null&&b!==void 0?b:p.resetCenterPoint,p.resetInnerRadius=(S=h==null?void 0:h.resetInnerRadius)!==null&&S!==void 0?S:p.resetInnerRadius,h!=null&&h.easingFunction||(p.easingFunction=i.easing.outCubic),p}return Object.defineProperty(f.prototype,"modifierType",{get:function(){return a.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),f.prototype.getAngularAxis=function(){var h=this.xAxis;return h.isAngular?h:this.yAxis},f.prototype.getRadialAxis=function(){var h=this.yAxis;return h.isAngular?this.xAxis:h},f.prototype.onAttach=function(){d.prototype.onAttach.call(this);var h=this.xAxis,p=this.yAxis;this.xStartAngle===void 0&&(this.xStartAngle=h.startAngle),this.yStartAngle===void 0&&(this.yStartAngle=p.startAngle),this.totalAngle===void 0&&(this.totalAngle=this.getAngularAxis().totalAngle),this.lengthScale===void 0&&(this.lengthScale=this.getRadialAxis().lengthScale),this.centerPoint===void 0&&(this.centerPoint=new r.Point(h.xCenterOffset,h.yCenterOffset)),this.innerRadius===void 0&&(this.innerRadius=this.getRadialAxis().innerRadius)},f.prototype.modifierDoubleClick=function(h){var p=this,g=this.parentSurface;if(g){var v=this.xAxis,y=this.yAxis;if(this.resetRanges&&(!this.onZoomExtents||this.onZoomExtents(g)))switch(this.xyDirection){case s.EXyDirection.XyDirection:g.zoomExtents(this.animationDuration,this.easingFunction,function(){return g.setZoomState(l.EZoomState.AtExtents)});break;case s.EXyDirection.XDirection:g.zoomExtentsX(this.animationDuration,this.easingFunction);break;case s.EXyDirection.YDirection:g.zoomExtentsY(this.animationDuration,this.easingFunction);break}var m=v.startAngle,b=y.startAngle,S=this.getAngularAxis().totalAngle,_=this.resetStartAngles?this.xStartAngle:m,C=this.resetStartAngles?this.yStartAngle:b,P=this.resetTotalAngle?this.totalAngle:S,x=this.getRadialAxis().lengthScale,E=this.resetLengthScale?this.lengthScale:x,A=v.xCenterOffset,R=v.yCenterOffset,M=this.resetCenterPoint?this.centerPoint.x:A,D=this.resetCenterPoint?this.centerPoint.y:R,F=this.getRadialAxis().innerRadius,I=this.resetInnerRadius?this.innerRadius:F,V=this.isAnimated?this.animationDuration:0,z=this.easingFunction;h.handled=!0;var G=new n.GenericAnimation({from:{xStartAngle:m,yStartAngle:b,totalAngle:S,lengthScale:x,xAxisXCenterOffset:A,xAxisYCenterOffset:R,innerRadius:F},to:{xStartAngle:_,yStartAngle:C,totalAngle:P,lengthScale:E,xAxisXCenterOffset:M,xAxisYCenterOffset:D,innerRadius:I},duration:V,ease:z,onAnimate:function(H,U,k){var X=e.DoubleAnimator.interpolate(H.xStartAngle,U.xStartAngle,k),W=e.DoubleAnimator.interpolate(H.yStartAngle,U.yStartAngle,k),Y=e.DoubleAnimator.interpolate(H.totalAngle,U.totalAngle,k),te=e.DoubleAnimator.interpolate(H.lengthScale,U.lengthScale,k);v.startAngle=X,y.startAngle=W;var oe=p.getAngularAxis();oe.totalAngle=Y,p.getRadialAxis().lengthScale=te;var de=e.DoubleAnimator.interpolate(H.xAxisXCenterOffset,U.xAxisXCenterOffset,k),ge=e.DoubleAnimator.interpolate(H.xAxisYCenterOffset,U.xAxisYCenterOffset,k),Ee=e.DoubleAnimator.interpolate(H.innerRadius,U.innerRadius,k);oe.xCenterOffset=de,oe.yCenterOffset=ge,p.getRadialAxis().innerRadius=Ee}});g.addAnimation(G)}},f.prototype.toJSON=function(){var h=d.prototype.toJSON.call(this),p={centerPoint:this.centerPoint,innerRadius:this.innerRadius,lengthScale:this.lengthScale,resetCenterPoint:this.resetCenterPoint,resetInnerRadius:this.resetInnerRadius,resetLengthScale:this.resetLengthScale,resetRanges:this.resetRanges,resetStartAngles:this.resetStartAngles,resetTotalAngle:this.resetTotalAngle,totalAngle:this.totalAngle,xStartAngle:this.xStartAngle,yStartAngle:this.yStartAngle};return Object.assign(h.options,p),h},f})(u.ZoomExtentsModifier);return yE.PolarZoomExtentsModifier=c,yE}var iB={},Ybe;function pJ(){return Ybe||(Ybe=1,(function(t){var e=iB&&iB.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.PolarPanModifier=t.EPolarPanModifierPanMode=void 0;var i=di(),n=Lm(),r=uR(),o=Ho(),a=$f(),s=pl(),l=xm(),u=An(),c=BW(),d;(function(h){h.PolarStartAngle="PolarStartAngle",h.PolarVisibleRange="PolarVisibleRange",h.Cartesian="Cartesian"})(d=t.EPolarPanModifierPanMode||(t.EPolarPanModifierPanMode={}));var f=(function(h){e(p,h);function p(g){var v=this,y,m,b,S,_,C;return v=h.call(this,g)||this,v.primaryPanMode=d.Cartesian,v.secondaryPanMode=d.PolarStartAngle,v.growFactor=1,v.zoomSize=!0,v.type=o.EChart2DModifierType.PolarPan,v.primaryPanMode=(y=g==null?void 0:g.primaryPanMode)!==null&&y!==void 0?y:v.primaryPanMode,v.secondaryPanMode=(m=g==null?void 0:g.secondaryPanMode)!==null&&m!==void 0?m:v.secondaryPanMode,v.growFactor=(b=g==null?void 0:g.growFactor)!==null&&b!==void 0?b:v.growFactor,v.executeCondition=(S=g==null?void 0:g.executeCondition)!==null&&S!==void 0?S:{button:n.EExecuteOn.MouseLeftButton,key:r.EModifierMouseArgKey.None},v.secondaryExecuteCondition=(_=g==null?void 0:g.secondaryExecuteCondition)!==null&&_!==void 0?_:{button:n.EExecuteOn.MouseRightButton,key:r.EModifierMouseArgKey.None},v.zoomSize=(C=g==null?void 0:g.zoomSize)!==null&&C!==void 0?C:v.zoomSize,v}return Object.defineProperty(p.prototype,"modifierType",{get:function(){return a.EModifierType.Chart2DPolarModifier},enumerable:!1,configurable:!0}),p.prototype.modifierMouseDown=function(g){g.nativeEvent.preventDefault();var v=this.checkExecuteConditions(g),y=v.isPrimary,m=v.isSecondary;if(y?this.panMode=this.primaryPanMode:m?this.panMode=this.secondaryPanMode:this.panMode=void 0,!!this.panMode){if(!this.isAttached)throw new Error("Should not call PolarPanModifier.modifierMouseDown if not attached");var b=(0,u.translateFromCanvasToSeriesViewRect)(g.mousePoint,this.parentSurface.seriesViewRect);b&&(this.activePointerEvents.set(g.pointerId,g),this.parentSurface.setZoomState(l.EZoomState.UserZooming))}},p.prototype.modifierMouseMove=function(g){if(!(this.parentSurface.isSubSurface&&!g.isActiveSubChartEvent)&&(this.updatePointerInfo(g),!!this.previousPoint)){var v=this.getIsActionAllowed(g);v&&(this.panMode===d.Cartesian?this.performCartesianPan(g):this.panMode===d.PolarStartAngle?this.performPolarPan(!0,this.zoomSize):this.panMode===d.PolarVisibleRange&&this.performPolarPan(!1,this.zoomSize))}},p.prototype.modifierPointerCancel=function(g){h.prototype.modifierPointerCancel.call(this,g),this.activePointerEvents.clear()},p.prototype.modifierMouseUp=function(g){h.prototype.modifierMouseUp.call(this,g),this.panMode=void 0},p.prototype.toJSON=function(){var g=h.prototype.toJSON.call(this),v={primaryPanMode:this.primaryPanMode,secondaryPanMode:this.secondaryPanMode,growFactor:this.growFactor,zoomSize:this.zoomSize};return Object.assign(g.options,v),g},p.prototype.getIsActionAllowed=function(g){var v=this.activePointerEvents.values().next().value;return v.pointerId===g.pointerId},p.prototype.performCartesianPan=function(g){var v=g.mousePoint,y=v.x-this.previousPoint.x,m=this.previousPoint.y-v.y;this.xyDirection===s.EXyDirection.XDirection&&(m=0),this.xyDirection===s.EXyDirection.YDirection&&(y=0),this.getIncludedXAxis().forEach(function(b){if(b.isPolarAxis){var S=b;S.isAngular&&(S.xCenterOffset+=y,S.yCenterOffset-=m)}}),this.getIncludedYAxis().forEach(function(b){if(b.isPolarAxis){var S=b;S.isAngular&&(S.xCenterOffset+=y,S.yCenterOffset-=m)}})},p.prototype.performPolarPan=function(g,v){var y=this,m=this.parentSurface.seriesViewRect,b=(0,u.translateFromCanvasToSeriesViewRect)(this.previousPoint,m),S=(0,u.translateFromCanvasToSeriesViewRect)(this.mousePoint,m);b&&S&&this.getIncludedXAxis().forEach(function(_){if(_.isPolarAxis){var C=_,P=C.otherAxis;if(C.isAngular){var x=C.reverseTransform(b.x,b.y),E=C.reverseTransform(S.x,S.y),A=E.x-x.x,R=C.startAngle;if(y.xyDirection!==s.EXyDirection.YDirection)if(g){var M=R+A*y.growFactor;C.startAngle=M,P.startAngle=M}else{var D=C.visibleRange,F=C.totalAngle,I=A*y.growFactor*(D.max-D.min)/F;C.visibleRange=new i.NumberRange(D.min-I,D.max-I)}if(y.xyDirection!==s.EXyDirection.XDirection)if(v)P.lengthScale=P.lengthScale+P.lengthScale*(E.y/x.y-1)*y.growFactor;else{var V=P.visibleRange,z=V.min,G=V.max,H=G+(G*x.y/E.y-G)*y.growFactor;P.visibleRange=new i.NumberRange(z,H)}}else{var x=C.reverseTransform(b.x,b.y),E=C.reverseTransform(S.x,S.y),A=E.y-x.y,R=C.startAngle;if(y.xyDirection!==s.EXyDirection.XDirection)if(g){var M=R+A*y.growFactor;C.startAngle=M,P.startAngle=M}else{var D=P.visibleRange,F=P.totalAngle,I=A*y.growFactor*(D.max-D.min)/F;P.visibleRange=new i.NumberRange(D.min-I,D.max-I)}if(y.xyDirection!==s.EXyDirection.YDirection)if(v)C.lengthScale=C.lengthScale+C.lengthScale*(E.x/x.x-1)*y.growFactor;else{var U=C.visibleRange,z=U.min,G=U.max,H=G+(G*x.x/E.x-G)*y.growFactor;C.visibleRange=new i.NumberRange(z,H)}}}})},p})(c.PinchZoomModifier);t.PolarPanModifier=f})(iB)),iB}var mE={},e7={},nB={},qbe;function cR(){if(qbe)return nB;qbe=1,Object.defineProperty(nB,"__esModule",{value:!0}),nB.Vector3=void 0;var t=ci(),e=(function(){function i(n,r,o){this.xProperty=n,this.yProperty=r,this.zProperty=o}return Object.defineProperty(i,"zero",{get:function(){return i.zeroVector},enumerable:!1,configurable:!0}),i.hydrate=function(n){if(n){var r=n.x,o=n.y,a=n.z;return new i(r,o,a)}else return},i.isEqual=function(n,r){return!((n==null?void 0:n.x)!==(r==null?void 0:r.x)||(n==null?void 0:n.y)!==(r==null?void 0:r.y)||(n==null?void 0:n.z)!==(r==null?void 0:r.z))},Object.defineProperty(i.prototype,"x",{get:function(){return this.xProperty},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"y",{get:function(){return this.yProperty},enumerable:!1,configurable:!0}),Object.defineProperty(i.prototype,"z",{get:function(){return this.zProperty},enumerable:!1,configurable:!0}),i.prototype.toTsrVector3=function(n){return t.Guard.notNull(n,"webAssemblyContext"),new n.TSRVector3(this.x,this.y,this.z)},i.prototype.subtract=function(n){return new i(this.x-n.x,this.y-n.y,this.z-n.z)},i.prototype.add=function(n){return new i(this.x+n.x,this.y+n.y,this.z+n.z)},i.prototype.scalarMultiply=function(n){return new i(this.x*n,this.y*n,this.z*n)},i.prototype.dotProduct=function(n){return this.x*n.x+this.y*n.y+this.z*n.z},i.prototype.crossProduct=function(n){return new i(this.y*n.z-this.z*n.y,this.z*n.x-this.x*n.z,this.x*n.y-this.y*n.x)},Object.defineProperty(i.prototype,"length",{get:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)},enumerable:!1,configurable:!0}),i.prototype.normalize=function(){var n=1/this.length;if(n===0)throw new Error("Vector3 magnitude is zero, cannot normalize!");this.xProperty=this.xProperty*n,this.yProperty=this.yProperty*n,this.zProperty=this.zProperty*n},i.prototype.toString=function(){return"Vector3 (".concat(this.xProperty.toFixed(2),", ").concat(this.yProperty.toFixed(2),", ").concat(this.zProperty.toFixed(2),")")},i.prototype.toJSON=function(){return{x:this.x,y:this.y,z:this.z}},i.zeroVector=new i(0,0,0),i})();return nB.Vector3=e,nB}var t7={},Xbe;function vje(){return Xbe||(Xbe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.CAMERA_POSITION="CAMERA_POSITION",e.CAMERA_TARGET="CAMERA_TARGET",e.CAMERA_ORTHOHEIGHT="CAMERA_ORTHOHEIGHT",e.CAMERA_ORTHOWIDTH="CAMERA_ORTHOWIDTH",e.CAMERA_FIELDOFVIEW="CAMERA_FIELDOFVIEW",e.CAMERA_PROJECTIONMODE="CAMERA_PROJECTIONMODE",e.CAMERA_ISATTACHED="CAMERA_ISATTACHED",e.CAMERA_ORBITALPITCH="CAMERA_ORBITALPITCH",e.CAMERA_ORBITALYAW="CAMERA_ORBITALYAW",e.CAMERA_RADIUS="CAMERA_RADIUS",e.CAMERA_FORWARD="CAMERA_FORWARD",e.CAMERA_SIDE="CAMERA_SIDE",e.CAMERA_UP="CAMERA_UP",e.CAMERA_UPGLOBAL="CAMERA_UPGLOBAL",e.CAMERA_ASPECTRATIO="CAMERA_ASPECTRATIO",e.CAMERA_ID="CAMERA_ID",e.CAMERA_FARCLIP="CAMERA_FARCLIP",e.CAMERA_NEARCLIP="CAMERA_NEARCLIP",e.PLANE_VISIBILITY="PLANE_VISIBILITY",e.PLANE_LABEL_MODE="PLANE_LABEL_MODE",e.PLANE_TITLE_MODE="PLANE_TITLE_MODE",e.SURFACE_CAMERA="SURFACE_CAMERA",e.SURFACE_XAXIS="SURFACE_XAXIS",e.SURFACE_YAXIS="SURFACE_YAXIS",e.SURFACE_ZAXIS="SURFACE_ZAXIS",e.SURFACE_VIEWPORT_MANAGER="SURFACE_VIEWPORT_MANAGER",e.SURFACE_WORLD_DIMENSIONS="SURFACE_WORLD_DIMENSIONS"})(t.PROPERTY||(t.PROPERTY={}))})(t7)),t7}var Kbe;function rI(){return Kbe||(Kbe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.CameraController=t.ECameraProjectionMode=void 0;var e=ps(),i=ci(),n=KP(),r=cR(),o=vje(),a;(function(l){l.Perspective="Perspective",l.Orthogonal="Orthogonal"})(a=t.ECameraProjectionMode||(t.ECameraProjectionMode={}));var s=(function(){function l(u,c){var d,f,h,p,g,v,y,m,b;this.aspectRatioProperty=1.5,this.idProperty="Default",this.farClipProperty=4e3,this.fieldOfViewProperty=60,this.isAttachedProperty=!1,this.nearClipProperty=1,this.orbitalPitchProperty=0,this.orbitalYawProperty=0,this.orthoHeightProperty=400,this.orthoWidthProperty=600,this.positionProperty=r.Vector3.zero,this.projectionModeProperty=a.Perspective,this.targetProperty=r.Vector3.zero,this.webAssemblyContext=u,this.propertyChanged=new e.EventHandler,this.resetToDefaults(),this.id=(d=c==null?void 0:c.id)!==null&&d!==void 0?d:this.id,this.farClipProperty=(f=c==null?void 0:c.farClip)!==null&&f!==void 0?f:this.farClip,this.fieldOfViewProperty=(h=c==null?void 0:c.fieldOfView)!==null&&h!==void 0?h:this.fieldOfView,this.nearClipProperty=(p=c==null?void 0:c.nearClip)!==null&&p!==void 0?p:this.nearClip,this.orthoHeightProperty=(g=c==null?void 0:c.orthoHeight)!==null&&g!==void 0?g:this.orthoHeight,this.orthoWidthProperty=(v=c==null?void 0:c.orthoWidth)!==null&&v!==void 0?v:this.orthoWidth,this.projectionModeProperty=(y=c==null?void 0:c.projectionMode)!==null&&y!==void 0?y:this.projectionMode,this.position=c!=null&&c.position?r.Vector3.hydrate(c==null?void 0:c.position):this.position,this.target=c!=null&&c.target?r.Vector3.hydrate(c==null?void 0:c.target):this.target,this.id=(m=c==null?void 0:c.id)!==null&&m!==void 0?m:this.id,this.debugPositionsProperty=(b=c==null?void 0:c.debugPositions)!==null&&b!==void 0?b:!1}return Object.defineProperty(l.prototype,"id",{get:function(){return this.idProperty},set:function(u){this.idProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_ID)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"orthoHeight",{get:function(){return this.orthoHeightProperty},set:function(u){this.orthoHeightProperty!==u&&(this.orthoHeightProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_ORTHOHEIGHT))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"orthoWidth",{get:function(){return this.orthoWidthProperty},set:function(u){this.orthoWidthProperty!==u&&(this.orthoWidthProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_ORTHOWIDTH))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"projectionMode",{get:function(){return this.projectionModeProperty},set:function(u){this.projectionModeProperty!==u&&(this.projectionModeProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_PROJECTIONMODE))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"aspectRatio",{get:function(){return this.aspectRatioProperty},set:function(u){this.aspectRatioProperty!==u&&(this.aspectRatioProperty=u,this.orthoWidth=this.orthoHeight*this.aspectRatioProperty,this.notifyPropertyChanged(o.PROPERTY.CAMERA_ASPECTRATIO))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"isAttached",{get:function(){return this.isAttachedProperty},set:function(u){this.isAttachedProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_ISATTACHED)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"radius",{get:function(){var u=this.target.subtract(this.position).length;return u},set:function(u){u<=1&&(u=1),this.radius!==u&&(this.position=this.target.subtract(this.forward.scalarMultiply(u)),this.notifyPropertyChanged(o.PROPERTY.CAMERA_RADIUS))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"orbitalPitch",{get:function(){return this.orbitalPitchProperty},set:function(u){if(this.orbitalPitchProperty!==u){this.orbitalPitchProperty=u>90?89.9:u<-90?-89.9:u;var c=this.webAssemblyContext.Math3D.PitchAndYawToDirection(this.orbitalPitchProperty,this.orbitalYawProperty);try{var d=new r.Vector3(c.x,c.y,c.z);d=d.scalarMultiply(this.radius),this.position=this.target.subtract(d),this.notifyPropertyChanged(o.PROPERTY.CAMERA_ORBITALPITCH)}finally{c==null||c.delete()}}},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"orbitalYaw",{get:function(){return this.orbitalYawProperty},set:function(u){if(this.orbitalYawProperty!==u){this.orbitalYawProperty=u;var c=this.webAssemblyContext.Math3D.PitchAndYawToDirection(this.orbitalPitchProperty,this.orbitalYawProperty);try{var d=new r.Vector3(c.x,c.y,c.z);d=d.scalarMultiply(this.radius),this.position=this.target.subtract(d),this.notifyPropertyChanged(o.PROPERTY.CAMERA_ORBITALYAW)}finally{c==null||c.delete()}}},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"farClip",{get:function(){return this.farClipProperty},set:function(u){this.farClipProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_FARCLIP)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"nearClip",{get:function(){return this.nearClipProperty},set:function(u){this.nearClipProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_NEARCLIP)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"fieldOfView",{get:function(){return this.fieldOfViewProperty},set:function(u){this.fieldOfViewProperty=u,this.notifyPropertyChanged(o.PROPERTY.CAMERA_FIELDOFVIEW)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"upGlobal",{get:function(){return new r.Vector3(0,1,0)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"side",{get:function(){var u=this.forward,c=u.crossProduct(this.upGlobal).crossProduct(u),d=c.crossProduct(u);return d.normalize(),d},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"forward",{get:function(){var u=this.target.subtract(this.position);return u.normalize(),u},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"up",{get:function(){var u=this.forward,c=u.crossProduct(this.upGlobal).crossProduct(u);return c.normalize(),c},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"target",{get:function(){return this.targetProperty},set:function(u){if(this.targetProperty!==u){this.targetProperty=u;var c,d;try{c=this.forward.toTsrVector3(this.webAssemblyContext),d=this.webAssemblyContext.Math3D.DirectionToPitchAndYaw(c),this.orbitalPitchProperty=d.pitch,this.orbitalYawProperty=d.yaw,this.notifyPropertyChanged(o.PROPERTY.CAMERA_TARGET)}finally{c==null||c.delete(),d==null||d.delete()}}},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"position",{get:function(){return this.positionProperty},set:function(u){if(this.positionProperty!==u){this.positionProperty=u;var c,d;try{c=this.forward.toTsrVector3(this.webAssemblyContext),d=this.webAssemblyContext.Math3D.DirectionToPitchAndYaw(c),this.orbitalPitchProperty=d.pitch,this.orbitalYawProperty=d.yaw,this.notifyPropertyChanged(o.PROPERTY.CAMERA_POSITION)}finally{c==null||c.delete(),d==null||d.delete()}}},enumerable:!1,configurable:!0}),l.prototype.toOrthogonal=function(){this.projectionModeProperty!==a.Orthogonal&&(this.projectionModeProperty=a.Orthogonal,this.orthoWidthProperty=this.radius,this.orthoHeightProperty=this.orthoWidth/this.aspectRatio,this.notifyPropertyChanged(o.PROPERTY.CAMERA_PROJECTIONMODE))},l.prototype.toPerspective=function(){this.projectionModeProperty!==a.Perspective&&(this.projectionModeProperty=a.Perspective,this.radius=this.orthoWidth,this.notifyPropertyChanged(o.PROPERTY.CAMERA_PROJECTIONMODE))},l.prototype.resetToDefaults=function(){this.positionProperty=new r.Vector3(-1e3,1e3,-1e3),this.targetProperty=new r.Vector3(0,0,0),this.fieldOfViewProperty=60,this.nearClipProperty=1,this.farClipProperty=4e3,this.projectionModeProperty=a.Perspective,this.aspectRatioProperty=1.5,this.orthoWidthProperty=600,this.orthoHeightProperty=400;var u,c;try{u=this.forward.toTsrVector3(this.webAssemblyContext),c=this.webAssemblyContext.Math3D.DirectionToPitchAndYaw(u),this.orbitalPitch=c.pitch,this.orbitalYaw=c.yaw}finally{c==null||c.delete(),u==null||u.delete()}},l.prototype.updateEngineCamera=function(u){i.Guard.notNull(u,"tsrCamera");var c,d,f;try{c=this.position.toTsrVector3(this.webAssemblyContext),d=this.target.toTsrVector3(this.webAssemblyContext),f=this.up.toTsrVector3(this.webAssemblyContext),u.SetLoc(c),u.SetAt(d),u.SetFarClip(this.farClip),u.SetNearClip(this.nearClip),u.SetFovAngle(this.webAssemblyContext.Math3D.DegToRad(this.fieldOfView)),u.SetProjectionMode(this.projectionMode===a.Perspective?this.webAssemblyContext.eTSRCameraProjectionMode.CAMERA_PROJECTIONMODE_PERSPECTIVE:this.webAssemblyContext.eTSRCameraProjectionMode.CAMERA_PROJECTIONMODE_ORTHOGONAL),u.SetOrthoWidth(this.orthoWidth),u.SetOrthoHeight(this.orthoHeight),u.SetAspectRatio(this.aspectRatio),u.SetYaw(this.webAssemblyContext.Math3D.DegToRad(this.orbitalYaw)),u.SetPitch(this.webAssemblyContext.Math3D.DegToRad(this.orbitalPitch)),u.SetUp(f)}finally{c==null||c.delete(),d==null||d.delete(),f==null||f.delete()}},l.prototype.notifyPropertyChanged=function(u){var c;this.debugPositionsProperty&&(u===o.PROPERTY.CAMERA_POSITION||u===o.PROPERTY.CAMERA_TARGET)&&console.log("SciChart.js Camera P=".concat(this.position.toString(),", T=").concat(this.target.toString())),(c=this.propertyChanged)===null||c===void 0||c.raiseEvent(new n.PropertyChangedEventArgs(u))},l.prototype.debugOutput=function(){var u=["Camera id='".concat(this.id,"': "),"  position: ".concat(this.position.toString()),"  target: ".concat(this.target.toString()),"  pitch: ".concat(this.orbitalPitch.toFixed(2)," degrees"),"  yaw: ".concat(this.orbitalYaw.toFixed(2)," degrees"),"  up Vector: ".concat(this.up.toString()),"  forward Vector: ".concat(this.forward.toString()),"  projectionMode: ".concat(this.projectionMode)];return this.projectionMode===a.Orthogonal?(u.push("  orthoWidth: ".concat(this.orthoWidth.toFixed(2))),u.push("  orthoHeight: ".concat(this.orthoHeight.toFixed(2)))):(u.push("  radius: ".concat(this.radius.toFixed(2))),u.push("  fieldOfView: ".concat(this.fieldOfView.toFixed(2)," degrees"))),u.forEach(function(c){return console.log(c)}),u},l.prototype.toJSON=function(){var u={id:this.id,position:this.position,target:this.target,fieldOfView:this.fieldOfView,nearClip:this.nearClip,farClip:this.farClip,projectionMode:this.projectionMode,orthoWidth:this.orthoWidth,orthoHeight:this.orthoHeight};return u},l})();t.CameraController=s})(e7)),e7}var bE={},Zbe;function dR(){if(Zbe)return bE;Zbe=1;var t=bE&&bE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(bE,"__esModule",{value:!0}),bE.ChartModifierBase3D=void 0;var e=Cie(),i=Tie(),n=$f(),r=(function(o){t(a,o);function a(s){var l=this,u,c,d,f;if(l=o.call(this,s)||this,l.typeMap=new Map,l.includedSeries=new i.IncludedItems,((u=s==null?void 0:s.includedSeriesIds)===null||u===void 0?void 0:u.length)>0&&((c=s==null?void 0:s.excludedSeriesIds)===null||c===void 0?void 0:c.length)>0)throw new Error("You should either use `includedSeriesIds` or `excludedSeriesIds`, not both.");return((d=s==null?void 0:s.includedSeriesIds)===null||d===void 0?void 0:d.length)>0&&l.includedSeries.includeList(s.includedSeriesIds),((f=s==null?void 0:s.excludedSeriesIds)===null||f===void 0?void 0:f.length)>0&&l.includedSeries.excludeList(s.excludedSeriesIds),l}return Object.defineProperty(a.prototype,"modifierType",{get:function(){return n.EModifierType.Chart3DModifier},enumerable:!1,configurable:!0}),a.prototype.getAllSeries=function(){return this.parentSurface.renderableSeries.asArray()},a.prototype.testIsIncludedSeries=function(s){return s.isVisible&&this.includedSeries.testIsIncluded(s.id)},a.prototype.includeSeries=function(s,l){return l?this.includedSeries.include(s.id):this.includedSeries.exclude(s.id)},a.prototype.getIncludedRenderableSeries=function(){var s=this;return this.getAllSeries().filter(function(l){return s.testIsIncludedSeries(l)})},a.prototype.toJSON=function(){var s={id:this.id,executeCondition:this.executeCondition,includedSeriesIds:this.includedSeries.getIncludedItemIds(),excludedSeriesIds:this.includedSeries.getExcludedItemIds()};return{type:this.type,options:s}},a})(e.ChartModifierBase);return bE.ChartModifierBase3D=r,bE}var Jbe;function yje(){if(Jbe)return mE;Jbe=1;var t=mE&&mE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(mE,"__esModule",{value:!0}),mE.MouseWheelZoomModifier3D=void 0;var e=Ho(),i=rI(),n=dR(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s)||this;return l.type=e.EChart3DModifierType.MouseWheelZoom,l.mouseWheelSensitivity=(s==null?void 0:s.mouseWheelSensitivity)||.1,l}return a.prototype.modifierMouseWheel=function(s){o.prototype.modifierMouseWheel.call(this,s);var l=this.parentSurface;if(l){var u=l.camera;if(u){var c=s.mouseWheelDelta,d=u.radius,f=(d+c*this.mouseWheelSensitivity)/d;u.projectionMode===i.ECameraProjectionMode.Perspective?u.radius*=f:(u.orthoWidth*=f,u.orthoHeight*=f),s.handled=!0}}},a.prototype.toJSON=function(){var s=o.prototype.toJSON.call(this),l={mouseWheelSensitivity:this.mouseWheelSensitivity};return Object.assign(s.options,l),s},a})(n.ChartModifierBase3D);return mE.MouseWheelZoomModifier3D=r,mE}var SE={},Qbe;function Mie(){if(Qbe)return SE;Qbe=1;var t=SE&&SE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(SE,"__esModule",{value:!0}),SE.PinchZoomModifier3D=void 0;var e=Ho(),i=rI(),n=dR(),r=(function(o){t(a,o);function a(s){var l=this,u;return l=o.call(this,s)||this,l.growFactor=.5,l.type=e.EChart3DModifierType.PinchZoom,l.growFactor=(u=s==null?void 0:s.growFactor)!==null&&u!==void 0?u:l.growFactor,l}return a.prototype.modifierMouseDown=function(s){if(o.prototype.modifierMouseDown.call(this,s),!this.isAttached)throw new Error("Should not call PinchZoomModifier3D.modifierMouseDown if not attached");var l=s.pointerType==="touch"||s.pointerType==="pen";l&&this.activePointerEvents.set(s.pointerId,s)},a.prototype.modifierMouseMove=function(s){var l;o.prototype.modifierMouseMove.call(this,s),(l=this.activePointerEvents.get(s.pointerId))===null||l===void 0||l.mousePoint,this.activePointerEvents.has(s.pointerId)&&this.activePointerEvents.set(s.pointerId,s);var u=this.getIsActionAllowed(s);u&&this.performModifierAction(s)},a.prototype.modifierMouseUp=function(s){o.prototype.modifierMouseUp.call(this,s),this.removeFromActiveTouchEvents(s)},a.prototype.toJSON=function(){var s=o.prototype.toJSON.call(this),l={growFactor:this.growFactor};return Object.assign(s.options,l),s},a.prototype.performZoom=function(s,l,u){var c=this.parentSurface;if(c){var d=c.camera;if(d){var f=Math.sqrt(Math.pow(l,2)+Math.pow(u,2)),h=Math.sqrt(Math.pow(this.previousHorizontalTouchPointsDistance,2)+Math.pow(this.previousVerticalTouchPointsDistance,2)),p=d.radius,g=(h-f)*this.growFactor,v=(p+g)/p;d.projectionMode===i.ECameraProjectionMode.Perspective?d.radius*=v:(d.orthoWidth*=v,d.orthoHeight*=v)}}},a.prototype.removeFromActiveTouchEvents=function(s){this.activePointerEvents.delete(s.pointerId),this.activePointerEvents.size<2&&(this.previousHorizontalTouchPointsDistance=void 0,this.previousVerticalTouchPointsDistance=void 0)},a.prototype.performModifierAction=function(s){var l=Array.from(this.activePointerEvents.values()),u=l[0].mousePoint,c=l[1].mousePoint,d=Math.abs(u.x-c.x),f=Math.abs(u.y-c.y);this.previousHorizontalTouchPointsDistance!==void 0&&this.previousVerticalTouchPointsDistance!==void 0&&this.performZoom(s.mousePoint,d,f),this.previousHorizontalTouchPointsDistance=d,this.previousVerticalTouchPointsDistance=f},a.prototype.getIsActionAllowed=function(s){var l=s.pointerType==="touch"||s.pointerType==="pen";return l&&this.activePointerEvents.size>=2},a})(n.ChartModifierBase3D);return SE.PinchZoomModifier3D=r,SE}var _E={},eSe;function mje(){if(eSe)return _E;eSe=1;var t=_E&&_E.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(_E,"__esModule",{value:!0}),_E.OrbitModifier3D=void 0;var e=Lm(),i=Ho(),n=Mie(),r=(function(o){t(a,o);function a(s){var l=this,u,c;return l=o.call(this,s)||this,l.type=i.EChart3DModifierType.Orbit,l.enableZoom=!0,l.enableZoom=(u=s==null?void 0:s.enableZoom)!==null&&u!==void 0?u:l.enableZoom,l.executeCondition=(c=s==null?void 0:s.executeCondition)!==null&&c!==void 0?c:{button:e.EExecuteOn.MouseLeftButton},l}return a.prototype.modifierMouseDown=function(s){if(!this.isAttached)throw new Error("Should not call OrbitModifier3D.modifierMouseDown if not attached");this.checkExecuteConditions(s).isPrimary&&(o.prototype.modifierMouseDown.call(this,s),this.activePointerEvents.set(s.pointerId,s))},a.prototype.modifierMouseMove=function(s){if(this.updatePointerInfo(s),!!this.previousPoint){this.enableZoom&&o.prototype.getIsActionAllowed.call(this,s)&&o.prototype.performModifierAction.call(this,s);var l=this.getIsActionAllowed(s);l&&this.performModifierAction(s)}},a.prototype.modifierMouseUp=function(s){if(o.prototype.modifierMouseUp.call(this,s),this.activePointerEvents.size>0){var l=this.activePointerEvents.values().next().value;s.target.setPointerCapture(l.pointerId)}},a.prototype.toJSON=function(){var s=o.prototype.toJSON.call(this),l={enableZoom:this.enableZoom};return Object.assign(s.options,l),s},a.prototype.performModifierAction=function(s){var l=this.parentSurface.camera;if(l){var u=.2,c=s.mousePoint,d=this.previousPoint.x-c.x,f=this.previousPoint.y-c.y,h=d*u,p=f*u;l.orbitalYaw+=h,l.orbitalPitch-=p}},a.prototype.getIsActionAllowed=function(s){var l=this.activePointerEvents.values().next().value;return!(l.pointerId!==s.pointerId||this.activePointerEvents.size>1)},a})(n.PinchZoomModifier3D);return _E.OrbitModifier3D=r,_E}var oB={},PE={},aB={},sB={},tSe;function VW(){if(tSe)return sB;tSe=1,Object.defineProperty(sB,"__esModule",{value:!0}),sB.HitTestInfo3D=void 0;var t=$i(),e=(function(){function i(n,r){r===void 0&&(r=!1),this.isEmpty=r,this.associatedSeries=n}return i.empty=function(){return new i(void 0,!0)},i.isEqual=function(n,r){return n===r?!0:n===void 0&&r!==void 0||n!==void 0&&r===void 0?!1:!(n.isEmpty!==r.isEmpty||n.associatedSeries!==r.associatedSeries||!t.Point.isEqual(n.hitTestPoint,r.hitTestPoint)||n.isHit!==r.isHit||n.selectionIndex!==r.selectionIndex||n.selectionIjIndices!==r.selectionIjIndices)},i})();return sB.HitTestInfo3D=e,sB}var rSe;function eH(){if(rSe)return aB;rSe=1,Object.defineProperty(aB,"__esModule",{value:!0}),aB.SeriesInfo3D=void 0;var t=cR(),e=VW(),i=(function(){function n(r,o){var a;this.isEmpty=!1,this.renderableSeries=r,this.dataSeriesName=(a=r==null?void 0:r.dataSeries)===null||a===void 0?void 0:a.dataSeriesName,this.isHit=o==null?void 0:o.isHit,this.hitTestInfo=o}return n.empty=function(){var r=new n(void 0,void 0);return r.isEmpty=!0,r},n.isEqual=function(r,o){return r===o?!0:r!==void 0&&o===void 0||r===void 0&&o!==void 0?!1:r.equals(o)},n.prototype.equals=function(r){return!(this.isHit!==r.isHit||this.isEmpty!==r.isEmpty||this.xValue!==r.xValue||this.yValue!==r.yValue||this.zValue!==r.zValue||this.dataSeriesName!==r.dataSeriesName||this.dataSeriesType!==r.dataSeriesType||this.renderableSeries!==r.renderableSeries||!t.Vector3.isEqual(this.hitWorldCoords,r.hitWorldCoords)||!e.HitTestInfo3D.isEqual(this.hitTestInfo,r.hitTestInfo))},n})();return aB.SeriesInfo3D=i,aB}var iSe;function bje(){if(iSe)return PE;iSe=1;var t=PE&&PE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(PE,"__esModule",{value:!0}),PE.TooltipSvgAnnotation3D=void 0;var e=gl(),i=Qa(),n=Dm(),r=jl(),o=eH(),a=vs(),s=(function(l){t(u,l);function u(c){var d=this,f,h,p,g,v,y,m,b;if(d=l.call(this,c)||this,d.type=i.EAnnotationType.SVG,d.surfaceTypes=[a.ESurfaceType.SciChart3DSurfaceType],d.tooltipLegendOffsetXProperty=10,d.tooltipLegendOffsetYProperty=10,d.isDirty=!0,d.isHidden=!0,d.titleProperty=(f=c==null?void 0:c.title)!==null&&f!==void 0?f:d.titleProperty,d.tooltipSvgTemplateProperty=(h=c==null?void 0:c.tooltipSvgTemplate)!==null&&h!==void 0?h:d.tooltipSvgTemplateProperty,d.containerBackgroundProperty=(p=c==null?void 0:c.containerBackground)!==null&&p!==void 0?p:d.containerBackgroundProperty,d.textStrokeProperty=(g=c==null?void 0:c.textStroke)!==null&&g!==void 0?g:d.textStrokeProperty,d.tooltipLegendTemplateProperty=(v=c==null?void 0:c.tooltipLegendTemplate)!==null&&v!==void 0?v:d.tooltipLegendTemplateProperty,d.tooltipLegendOffsetXProperty=(y=c==null?void 0:c.tooltipLegendOffsetX)!==null&&y!==void 0?y:d.tooltipLegendOffsetXProperty,d.tooltipLegendOffsetYProperty=(m=c==null?void 0:c.tooltipLegendOffsetY)!==null&&m!==void 0?m:d.tooltipLegendOffsetYProperty,d.placementDivIdProperty=(b=c==null?void 0:c.placementDivId)!==null&&b!==void 0?b:d.placementDivId,d.tooltipDataTemplateProperty=c==null?void 0:c.tooltipDataTemplate,d.placementDivId){var S=document.querySelector("[id='".concat(d.placementDivId,"']"));d.svgDivRoot=S}return d}return Object.defineProperty(u.prototype,"seriesInfo",{get:function(){return this.seriesInfoProperty},set:function(c){o.SeriesInfo3D.isEqual(this.seriesInfoProperty,c)||(this.seriesInfoProperty=c,this.notifyPropertyChanged(r.PROPERTY.SERIES_INFOS))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"title",{get:function(){return this.titleProperty},set:function(c){this.titleProperty!==c&&(this.titleProperty=c,this.notifyPropertyChanged(r.PROPERTY.TITLE))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipSvgTemplate",{get:function(){return this.tooltipSvgTemplateProperty},set:function(c){this.tooltipSvgTemplateProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_SVG_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendTemplate",{get:function(){return this.tooltipLegendTemplateProperty},set:function(c){this.tooltipLegendTemplateProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(c){this.tooltipDataTemplateProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_DATA_TEMPLATE)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"containerBackground",{get:function(){return this.containerBackgroundProperty},set:function(c){this.containerBackgroundProperty!==c&&(this.containerBackgroundProperty=c,this.notifyPropertyChanged(r.PROPERTY.CONTAINER_BACKGROUND))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendOffsetX",{get:function(){return this.tooltipLegendOffsetXProperty},set:function(c){this.tooltipLegendOffsetXProperty!==c&&(this.tooltipLegendOffsetXProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_OFFSET_X))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"tooltipLegendOffsetY",{get:function(){return this.tooltipLegendOffsetYProperty},set:function(c){this.tooltipLegendOffsetYProperty!==c&&(this.tooltipLegendOffsetYProperty=c,this.notifyPropertyChanged(r.PROPERTY.TOOLTIP_LEGEND_OFFSET_Y))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"textStroke",{get:function(){return this.textStrokeProperty},set:function(c){this.textStrokeProperty!==c&&(this.textStrokeProperty=c,this.notifyPropertyChanged(r.PROPERTY.TEXT_STROKE))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(c){this.placementDivIdProperty!==c&&(this.placementDivIdProperty=c,this.notifyPropertyChanged("PLACEMENT_DIV_ID"))},enumerable:!1,configurable:!0}),u.prototype.update=function(c,d,f,h){this.isDirty&&(this.isDirty=!1,this.svg&&this.clear(),this.create(c,d,f,h),this.placementDivId?this.updateExternalLegendTooltip():(this.updateTooltip(f,h),this.updateLegendTooltip()))},u.prototype.clear=function(){!this.parentSurface||this.parentSurface.isDeleted||!this.svg||(this.placementDivId?this.svgDivRoot.removeChild(this.svg):this.svgRoot.removeChild(this.svg),this.setSvg(void 0),this.svgLegend&&(this.svgRoot.removeChild(this.svgLegend),this.svgLegend=void 0))},u.prototype.notifyPropertyChanged=function(c){l.prototype.notifyPropertyChanged.call(this,c),this.isDirty=!0},u.prototype.create=function(c,d,f,h){if(!this.tooltipSvgTemplate)throw Error("Please provide a tooltipSvgTemplate for CursorTooltipSvgAnnotation");var p=this.tooltipSvgTemplate(this.seriesInfo,this),g=this.applySvgClipping(p,this.clipping);if(this.placementDivId){var v=e.annotationHelpers.createSvg(g,this.svgDivRoot,this.nextSibling);this.setSvg(v)}else{var v=e.annotationHelpers.createSvg(g,this.svgRoot,this.nextSibling);this.setSvg(v)}},u.prototype.updateTooltip=function(c,d){var f,h,p,g,v=(f=this.xCoordShift)!==null&&f!==void 0?f:0,y=(h=this.yCoordShift)!==null&&h!==void 0?h:0;this.svg.style.display=this.isHidden?"none":"block";var m=(p=this.x1)!==null&&p!==void 0?p:0,b=(g=this.y1)!==null&&g!==void 0?g:0,S=v+m+c,_=y+b+d;isNaN(S)||isNaN(_)?this.svg.style.display="none":(this.setSvgAttribute("x",S),this.setSvgAttribute("y",_))},u.prototype.updateLegendTooltip=function(){if(this.tooltipLegendTemplate){var c=this.seriesInfo?this.tooltipLegendTemplate(this.seriesInfo,this):"<svg></svg>";this.svgLegend&&this.svgRoot.removeChild(this.svgLegend);var d=this.applySvgClipping(c,this.clipping),f=e.annotationHelpers.createSvg(d,this.svgRoot,this.nextSibling);this.svgLegend=f,this.svgLegend.setAttribute("x",this.tooltipLegendOffsetX.toString()),this.svgLegend.setAttribute("y",this.tooltipLegendOffsetY.toString())}},u.prototype.updateExternalLegendTooltip=function(){if(this.tooltipLegendTemplate){var c=this.seriesInfo?this.tooltipLegendTemplate(this.seriesInfo,this):"<svg style='display: none'></svg>";this.svgLegend&&this.svgLegend.removeChild(this.svgLegend);var d=this.applySvgClipping(c,this.clipping),f=e.annotationHelpers.createSvg(d,this.svgRoot,this.nextSibling);this.svgLegend=f}},u})(n.SvgAnnotationBase);return PE.TooltipSvgAnnotation3D=s,PE}var CE={},r7={},nSe;function Im(){return nSe||(nSe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESceneEntityType=void 0,(function(e){e.AxisCubeEntity="AxisCubeEntity",e.Custom="Custom",e.GizmoEntity="GizmoEntity",e.RootSceneEntity="RootSceneEntity",e.ScatterPointsSceneEntity="ScatterPointsSceneEntity",e.SCRTSceneEntity="SCRTSceneEntity",e.SurfaceMeshSceneEntity="SurfaceMeshSceneEntity",e.PointLine3DSceneEntity="PointLine3DSceneEntity",e.ColumnSceneEntity="ColumnSceneEntity"})(t.ESceneEntityType||(t.ESceneEntityType={}))})(r7)),r7}var TE={},oSe;function HI(){if(oSe)return TE;oSe=1;var t=TE&&TE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(TE,"__esModule",{value:!0}),TE.BaseSceneEntity3D=void 0;var e=fo(),i=Br(),n=ci(),r=DP(),o=Im(),a=hl(),s=(function(l){t(u,l);function u(c){var d=l.call(this)||this;return d.id=(0,a.generateGuid)(),d.isVisibleProperty=!0,d.entityIdProperty=void 0,d.isDeletedProperty=!1,n.Guard.notNull(c,"webAssemblyContext"),d.webAssemblyContext=c,d.detachChild=d.detachChild.bind(d),d.attachChild=d.attachChild.bind(d),d.children=new r.ObservableArray,d.children.collectionChanged.subscribe(function(f){var h,p;(h=f.getOldItems())===null||h===void 0||h.forEach(d.detachChild),(p=f.getNewItems())===null||p===void 0||p.forEach(d.attachChild)}),d.onDpiChanged=d.onDpiChanged.bind(d),d}return Object.defineProperty(u.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(c){var d;this.isVisibleProperty!==c&&(this.isVisibleProperty=c,(d=this.nativeEntity)===null||d===void 0||d.SetVisible(this.isVisible))},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"entityIdProvider",{get:function(){return this.entityIdProviderProperty},set:function(c){var d=this;this.entityIdProviderProperty=c,!this.entityId&&this.entityIdProviderProperty&&(this.entityId=this.entityIdProviderProperty.getNextEntityId()),this.visitEntities(function(f){f!==d&&(f.entityIdProvider=c)})},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"entityId",{get:function(){return this.entityIdProperty},set:function(c){var d;this.entityIdProperty=c,(d=this.nativeEntityProperty)===null||d===void 0||d.SetEntityId(c),this.invalidateScene()},enumerable:!1,configurable:!0}),u.prototype.getRoot=function(){if(this.type===o.ESceneEntityType.RootSceneEntity)return this;for(var c=this.parent;c!==void 0;){if(c.type===o.ESceneEntityType.RootSceneEntity)return c;c=c.parent}},u.prototype.delete=function(){var c;this.isDeletedProperty=!0,this.children.asArray().forEach(function(d){return!d.isDeletedProperty&&d.delete()}),(c=this.entityIdProvider)===null||c===void 0||c.releaseEntityId(this.entityId),this.nativeEntity&&this.world&&this.world.RemoveEntity(this.nativeEntity),this.nativeEntityProperty=(0,i.deleteSafe)(this.nativeEntityProperty),this.webAssemblyContext=void 0},u.prototype.Update=function(c){if(this.currentRenderPassData){if(!this.nativeEntity)throw new Error("BaseSceneEntity.nativeSceneEntity must be set by calling setEntity() in the constructor");this.isVisible&&this.nativeEntity.Update(c)}},u.prototype.Render=function(){if(this.currentRenderPassData){if(!this.nativeEntity)throw new Error("BaseSceneEntity.nativeSceneEntity must be set by calling setEntity() in the constructor");this.isVisible&&this.nativeEntity.Render()}},u.prototype.onEngineRestart=function(){},u.prototype.onDpiChanged=function(c){},u.prototype.setRenderPassData=function(c){this.currentRenderPassData=c},u.prototype.getEntity=function(c){for(var d=0;d<this.children.size();d++){var f=this.children.get(d);if(f.type===c)return f}},u.prototype.invalidateScene=function(){var c,d;(d=(c=this.rootSceneEntity)===null||c===void 0?void 0:c.parentSurface)===null||d===void 0||d.invalidateElement()},u.prototype.onAttached=function(){this.parent.type,o.ESceneEntityType.SCRTSceneEntity},u.prototype.onDetached=function(){},u.prototype.visitEntities=function(c){c(this),this.children.asArray().forEach(function(d){d.visitEntities(c)})},Object.defineProperty(u.prototype,"nativeEntity",{get:function(){return this.nativeEntityProperty},enumerable:!1,configurable:!0}),u.prototype.attachChild=function(c){var d,f=this;(d=f.nativeEntity)===null||d===void 0||d.AddChildEntityInternal(c.nativeEntity),c.parent=f,c.entityIdProvider=this.entityIdProvider,c.onAttached()},u.prototype.detachChild=function(c){var d,f=this;(d=f.nativeEntity)===null||d===void 0||d.RemoveChildEntityInternal(c.nativeEntity),c.onDetached(),c.parent=void 0},u.prototype.setNativeEntity=function(c){var d;this.nativeEntityProperty=c,this.entityId&&((d=this.nativeEntityProperty)===null||d===void 0||d.SetEntityId(this.entityId))},Object.defineProperty(u.prototype,"world",{get:function(){var c,d;return(d=(c=this.getRoot())===null||c===void 0?void 0:c.parentSurface)===null||d===void 0?void 0:d.getSceneWorld()},enumerable:!1,configurable:!0}),u.prototype.getOrCreateVector=function(c,d,f,h){h===void 0&&(h=0);var p=c??new f;return p.size()!==d&&p.resize(d,h),p},u})(e.DeletableEntity);return TE.BaseSceneEntity3D=s,TE}var aSe;function Sje(){if(aSe)return CE;aSe=1;var t=CE&&CE.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(CE,"__esModule",{value:!0}),CE.CrosshairLinesSceneEntity=void 0;var e=Br(),i=Im(),n=Ti(),r=cR(),o=HI(),a=(function(s){t(l,s);function l(u){var c=s.call(this,u)||this;return c.type=i.ESceneEntityType.Custom,c.strokeThickness=2,c.stroke="#FF6600",c.antiAliased=!0,c.setNativeEntity(u.SCRTSceneEntity.implement(c)),c}return l.prototype.delete=function(){s.prototype.delete.call(this),this.linesMesh=(0,e.deleteSafe)(this.linesMesh)},l.prototype.Render=function(){if(!(!this.isVisible||!this.worldDimensions||!this.cameraPosition||!this.location)){var u=this.getWallVector();this.linesMesh=(0,e.deleteSafe)(this.linesMesh);var c=new this.webAssemblyContext.SCRTLinesMesh(this.strokeThickness,!1,this.antiAliased);c.SetVertexColor((0,n.parseColorToUIntArgb)(this.stroke)),this.inInWorldDimensions(this.location.x,this.location.y,0,this.worldDimensions)&&(c.SetVertex3(this.location.x,this.location.y,this.location.z),c.SetVertex3(this.location.x,this.location.y,u.z)),this.inInWorldDimensions(this.location.x,0,this.location.z,this.worldDimensions)&&(c.SetVertex3(this.location.x,this.location.y,this.location.z),c.SetVertex3(this.location.x,u.y,this.location.z)),this.inInWorldDimensions(0,this.location.y,0,this.worldDimensions)&&(c.SetVertex3(this.location.x,this.location.y,this.location.z),c.SetVertex3(u.x,this.location.y,this.location.z)),c.Freeze(),c.Render()}},l.prototype.inInWorldDimensions=function(u,c,d,f){return c>=0&&c<=f.y&&d>=-f.z/2&&d<=f.z/2&&u>=-f.x/2&&u<=f.x/2},l.prototype.getWallVector=function(){var u=this.cameraPosition.dotProduct(new r.Vector3(1,0,0))>0?-this.worldDimensions.x*.5:this.worldDimensions.x*.5,c=this.cameraPosition.dotProduct(new r.Vector3(0,1,0))>0?0:this.worldDimensions.y,d=this.cameraPosition.dotProduct(new r.Vector3(0,0,1))>0?-this.worldDimensions.z*.5:this.worldDimensions.z*.5;return new r.Vector3(u,c,d)},l})(o.BaseSceneEntity3D);return CE.CrosshairLinesSceneEntity=a,CE}var sSe;function gJ(){return sSe||(sSe=1,(function(t){var e=oB&&oB.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.adjustTooltipPosition3D=t.TooltipModifier3D=void 0;var i=YO(),n=Ca(),r=Br(),o=Ho(),a=An(),s=Uf(),l=bje(),u=Sje(),c=dR(),d=(function(g){e(v,g);function v(y){var m=this,b,S,_,C,P,x,E,A,R,M,D,F;return m=g.call(this,y)||this,m.type=o.EChart3DModifierType.Tooltip,m.showTooltip=!0,m.tooltipSvgTemplateProperty=h,m.tooltipContainerBackgroundProperty="#228B22",m.tooltipTextStrokeProperty="#fff",m.tooltipDataTemplateProperty=f,m.crosshairStrokeProperty=(b=y==null?void 0:y.crosshairStroke)!==null&&b!==void 0?b:"#FF6600",m.crosshairStrokeThicknessProperty=(S=y==null?void 0:y.crosshairStrokeThickness)!==null&&S!==void 0?S:2,m.isCrosshairVisibleProperty=(_=y==null?void 0:y.isCrosshairVisible)!==null&&_!==void 0?_:!0,y!=null&&y.tooltipSvgTemplate&&typeof y.tooltipSvgTemplate=="string"&&(m.typeMap.set("tooltipSvgTemplate",y.tooltipSvgTemplate),y.tooltipSvgTemplate=getFunction(EBaseType.OptionFunction,y.tooltipSvgTemplate)),m.tooltipSvgTemplateProperty=(C=y==null?void 0:y.tooltipSvgTemplate)!==null&&C!==void 0?C:m.tooltipSvgTemplateProperty,m.tooltipContainerBackgroundProperty=(P=y==null?void 0:y.tooltipContainerBackground)!==null&&P!==void 0?P:m.tooltipContainerBackgroundProperty,m.tooltipTextStrokeProperty=(x=y==null?void 0:y.tooltipTextStroke)!==null&&x!==void 0?x:m.tooltipTextStrokeProperty,m.showTooltip=(E=y==null?void 0:y.showTooltip)!==null&&E!==void 0?E:m.showTooltip,m.placementDivIdProperty=(A=y==null?void 0:y.placementDivId)!==null&&A!==void 0?A:m.placementDivIdProperty,y!=null&&y.tooltipLegendTemplate&&typeof y.tooltipLegendTemplate=="string"&&(m.typeMap.set("tooltipLegendTemplate",y.tooltipLegendTemplate),y.tooltipLegendTemplate=getFunction(EBaseType.OptionFunction,y.tooltipLegendTemplate)),m.tooltipLegendTemplateProperty=(R=y==null?void 0:y.tooltipLegendTemplate)!==null&&R!==void 0?R:m.tooltipLegendTemplateProperty,m.tooltipLegendOffsetXProperty=(M=y==null?void 0:y.tooltipLegendOffsetX)!==null&&M!==void 0?M:m.tooltipLegendOffsetX,m.tooltipLegendOffsetYProperty=(D=y==null?void 0:y.tooltipLegendOffsetY)!==null&&D!==void 0?D:m.tooltipLegendOffsetY,y!=null&&y.tooltipDataTemplate&&typeof y.tooltipDataTemplate=="string"&&(m.typeMap.set("tooltipDataTemplate",y.tooltipDataTemplate),y.tooltipDataTemplate=getFunction(EBaseType.OptionFunction,y.tooltipDataTemplate)),m.tooltipDataTemplateProperty=(F=y==null?void 0:y.tooltipDataTemplate)!==null&&F!==void 0?F:m.tooltipDataTemplateProperty,m}return Object.defineProperty(v.prototype,"isCrosshairVisible",{get:function(){return this.isCrosshairVisibleProperty},set:function(y){var m;this.isCrosshairVisibleProperty=y,(m=this.parentSurface)===null||m===void 0||m.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"crosshairStroke",{get:function(){return this.crosshairStrokeProperty},set:function(y){var m;this.crosshairStrokeProperty=y,(m=this.parentSurface)===null||m===void 0||m.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"crosshairStrokeThickness",{get:function(){return this.crosshairStrokeThicknessProperty},set:function(y){var m;this.crosshairStrokeThicknessProperty=y,(m=this.parentSurface)===null||m===void 0||m.invalidateElement()},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipSvgTemplate",{get:function(){return this.tooltipSvgTemplateProperty},set:function(y){this.tooltipSvgTemplateProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.tooltipSvgTemplate=y)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipLegendTemplate",{get:function(){return this.tooltipLegendTemplateProperty},set:function(y){this.tooltipLegendTemplateProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.tooltipLegendTemplate=y)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipDataTemplate",{get:function(){return this.tooltipDataTemplateProperty},set:function(y){this.tooltipDataTemplateProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.tooltipDataTemplate=y)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipContainerBackground",{get:function(){return this.tooltipContainerBackgroundProperty},set:function(y){this.tooltipContainerBackgroundProperty!==y&&(this.tooltipContainerBackgroundProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.containerBackground=y))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipLegendOffsetX",{get:function(){return this.tooltipLegendOffsetXProperty},set:function(y){this.tooltipLegendOffsetXProperty!==y&&(this.tooltipLegendOffsetXProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.tooltipLegendOffsetX=y))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipLegendOffsetY",{get:function(){return this.tooltipLegendOffsetYProperty},set:function(y){this.tooltipLegendOffsetYProperty!==y&&(this.tooltipLegendOffsetYProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.tooltipLegendOffsetY=y))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"tooltipTextStroke",{get:function(){return this.tooltipTextStrokeProperty},set:function(y){this.tooltipTextStrokeProperty!==y&&(this.tooltipTextStrokeProperty=y,this.tooltipAnnotation&&(this.tooltipAnnotation.textStroke=y))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"placementDivId",{get:function(){return this.placementDivIdProperty},set:function(y){this.placementDivIdProperty!==y&&(this.placementDivIdProperty=y,this.notifyPropertyChanged("PLACEMENT_DIV_ID"))},enumerable:!1,configurable:!0}),v.prototype.onAttach=function(){g.prototype.onAttach.call(this),this.parentSurface&&(this.parentSurface.isHitTestEnabled=!0,this.crosshairEntity=(0,r.deleteSafe)(this.crosshairEntity),this.crosshairEntity=new u.CrosshairLinesSceneEntity(this.parentSurface.webAssemblyContext3D),this.parentSurface.rootEntity.children.add(this.crosshairEntity),this.tooltipAnnotation=new l.TooltipSvgAnnotation3D({xCoordinateMode:n.ECoordinateMode.Pixel,yCoordinateMode:n.ECoordinateMode.Pixel,tooltipSvgTemplate:this.tooltipSvgTemplate,containerBackground:this.tooltipContainerBackground,textStroke:this.tooltipTextStroke,tooltipLegendTemplate:this.tooltipLegendTemplate,tooltipLegendOffsetX:this.tooltipLegendOffsetX,tooltipLegendOffsetY:this.tooltipLegendOffsetY,placementDivId:this.placementDivId,tooltipDataTemplate:this.tooltipDataTemplate}),this.parentSurface.modifierAnnotations.add(this.tooltipAnnotation))},v.prototype.onDetach=function(){g.prototype.onDetach.call(this),this.parentSurface&&(this.parentSurface.rootEntity.children.remove(this.crosshairEntity),this.parentSurface.modifierAnnotations.remove(this.tooltipAnnotation,!1),this.tooltipAnnotation=void 0),this.crosshairEntity=(0,r.deleteSafe)(this.crosshairEntity)},v.prototype.modifierMouseMove=function(y){this.activePointerEvents.set(y.pointerId,y),g.prototype.modifierMouseMove.call(this,y),this.getIsActionAllowed(y)&&this.update()},v.prototype.onParentSurfaceRendered=function(){this.update()},v.prototype.update=function(){var y=this,m,b,S;if(this.mousePoint){var _=this.mousePoint,C=_.x,P=_.y,x=this.getIncludedRenderableSeries().map(function(R){return R.hitTest(y.mousePoint)}).find(function(R){return R.isHit});if(x!=null&&x.isHit){if(this.crosshairEntity&&this.isCrosshairVisible&&(this.crosshairEntity.worldDimensions=(m=this.parentSurface)===null||m===void 0?void 0:m.worldDimensions,this.crosshairEntity.cameraPosition=(S=(b=this.parentSurface)===null||b===void 0?void 0:b.camera)===null||S===void 0?void 0:S.position,this.crosshairEntity.stroke=this.crosshairStroke,this.crosshairEntity.strokeThickness=this.crosshairStrokeThickness,this.crosshairEntity.location=x.hitWorldCoords,this.crosshairEntity.isVisible=this.isCrosshairVisible),this.tooltipAnnotation.isHidden=!this.showTooltip,this.showTooltip){var E=(0,a.translateToNotScaled)(C),A=(0,a.translateToNotScaled)(P);this.tooltipAnnotation.x1=E,this.tooltipAnnotation.y1=A}(this.showTooltip||this.tooltipLegendTemplate)&&(this.tooltipAnnotation.seriesInfo=x)}else this.tooltipAnnotation.seriesInfo=void 0,this.crosshairEntity.isVisible=!1,this.tooltipAnnotation.isHidden=!0}},v})(c.ChartModifierBase3D);t.TooltipModifier3D=d;var f=function(g,v){var y=[];return v.title&&y.push(v.title),g&&g.isHit&&(g.dataSeriesName&&y.push(g.dataSeriesName),(g.dataSeriesType===s.EDataSeriesType3D.Xyz3D||g.dataSeriesType===s.EDataSeriesType3D.UniformGrid3D)&&(y.push("X: ".concat(g.xValue)),y.push("Y: ".concat(g.yValue)),y.push("Z: ".concat(g.zValue)))),y},h=function(g,v){var y,m="id_".concat(Date.now()),b=(y=v.tooltipDataTemplate)!==null&&y!==void 0?y:f,S=b(g,v);if(S.length===0)return"<svg></svg>";var _=(0,i.calcTooltipSize)(S),C=_.width,P=_.height;(0,t.adjustTooltipPosition3D)(C,P,v);var x="";S.forEach(function(R,M){x+='<tspan x="8" dy="1.2em">'.concat(R,"</tspan>")});var E=v.containerBackground,A=v.textStroke;return'<svg class="scichart__cursor-tooltip" width="'.concat(C,'" height="').concat(P,`">
        <defs>
            <filter id="`).concat(m,`" x="0" y="0" width="200%" height="200%">
                <feOffset result="offOut" in="SourceAlpha" dx="3" dy="3" />
                <feGaussianBlur result="blurOut" in="offOut" stdDeviation="3" />
                <feBlend in="SourceGraphic" in2="blurOut" mode="normal" />
            </filter>
        </defs>
        <rect rx="4" ry="4" width="95%" height="90%" fill="`).concat(E,'" filter="url(#').concat(m,`)" />
        <svg width="100%">
            <text x="8" y="3" font-size="13" font-family="Verdana" dy="0" fill="`).concat(A,'">').concat(x,`</text>
        </svg>
    </svg>`)},p=function(g,v,y){var m=y.parentSurface.seriesViewRect,b=y.x1,S=y.y1,_=(0,a.translateToNotScaled)(m.width)-b<g?-g:5,C=(0,a.translateToNotScaled)(m.height)-S<v?-v:5;y.xCoordShift=_,y.yCoordShift=C};t.adjustTooltipPosition3D=p})(oB)),oB}var xE={},lSe;function _je(){if(lSe)return xE;lSe=1;var t=xE&&xE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(xE,"__esModule",{value:!0}),xE.ResetCamera3DModifier=void 0;var e=jW(),i=ad(),n=ZV(),r=Ho(),o=rI(),a=dR(),s=(function(l){t(u,l);function u(c){var d=this,f,h,p;return d=l.call(this,c)||this,d.type=r.EChart3DModifierType.ZoomExtents,d.isAnimated=!0,d.animationDuration=400,d.easingFunction=i.easing.outExpo,d.isAnimated=(f=c==null?void 0:c.isAnimated)!==null&&f!==void 0?f:!0,d.animationDuration=(h=c==null?void 0:c.animationDuration)!==null&&h!==void 0?h:400,c!=null&&c.easingFunction&&typeof c.easingFunction=="string"&&(c.easingFunction=i.easing[c.easingFunction]),d.easingFunction=(p=c==null?void 0:c.easingFunction)!==null&&p!==void 0?p:i.easing.outExpo,d.destination=c==null?void 0:c.destination,d}return u.prototype.onAttach=function(){if(!this.destination){var c=this.parentSurface;if(!c)return;var d=c.camera;if(!d)return;this.destination={radius:d.radius,pitch:d.orbitalPitch,yaw:d.orbitalYaw,width:d.orthoWidth,height:d.orthoHeight}}},u.prototype.modifierDoubleClick=function(c){var d,f,h=this.parentSurface;if(h){var p=h.camera;if(p){if(p.projectionMode===o.ECameraProjectionMode.Perspective){var g=new n.GenericAnimation({from:{radius:p.radius,pitch:p.orbitalPitch,yaw:p.orbitalYaw},to:(d=this.destination)!==null&&d!==void 0?d:{radius:1,pitch:0,yaw:0},onAnimate:function(v,y,m){p.radius=e.DoubleAnimator.interpolate(v.radius,y.radius,m),p.orbitalPitch=e.DoubleAnimator.interpolate(v.pitch,y.pitch,m),p.orbitalYaw=e.DoubleAnimator.interpolate(v.yaw,y.yaw,m)},duration:this.isAnimated?this.animationDuration:0,ease:this.easingFunction});h.addAnimation(g)}else{var g=new n.GenericAnimation({from:{width:p.orthoWidth,height:p.orthoHeight},to:(f=this.destination)!==null&&f!==void 0?f:{width:1,height:1},onAnimate:function(y,m,b){p.orthoWidth=e.DoubleAnimator.interpolate(y.width,m.width,b),p.orthoHeight=e.DoubleAnimator.interpolate(y.height,m.height,b)},duration:this.isAnimated?this.animationDuration:0,ease:this.easingFunction});h.addAnimation(g)}c.handled=!0}}},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={animationDuration:this.animationDuration,easingFunction:this.easingFunction.name,isAnimated:this.isAnimated,destination:this.destination};return Object.assign(c.options,d),c},u})(a.ChartModifierBase3D);return xE.ResetCamera3DModifier=s,xE}var wb={},EE={},uSe;function Pje(){if(uSe)return EE;uSe=1;var t=EE&&EE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(EE,"__esModule",{value:!0}),EE.SciChart3DLegend=void 0;var e=zy(),i=pa(),n=(function(r){t(o,r);function o(){var a=r!==null&&r.apply(this,arguments)||this;return a.type=e.ELegendType.SciChart3DLegend,a.showCheckboxesProperty=!1,a.showSeriesMarkersProperty=!0,a}return o.prototype.applyTheme=function(){},Object.defineProperty(o.prototype,"showCheckboxes",{get:function(){return this.showCheckboxesProperty},set:function(a){this.showCheckboxesProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"showSeriesMarkers",{get:function(){return this.showSeriesMarkersProperty},set:function(a){this.showSeriesMarkersProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),o.prototype.setRenderableSeriesArray=function(a){this.renderableSeriesArray=a,this.invalidateLegend()},o.prototype.addEventListeners=function(){var a=this;this.renderableSeriesArray.forEach(function(s){return a.addEventListenerToSeries(s)})},o.prototype.removeEventListeners=function(){var a=this;this.renderableSeriesArray.forEach(function(s){return a.removeEventListenerFromSeries(s.id)})},o.prototype.addEventListenerToSeries=function(a){var s=this,l=this.parentDiv.querySelector("[id='".concat(a.id,"']"));if(l){var u=function(h){a.isVisible=h.target.checked,s.legendItemCheckedChangedCallback&&s.legendItemCheckedChangedCallback(a,a.isVisible)};l.addEventListener("change",u);var c=function(h){s.invalidateLegend()};a.isVisibleChanged.subscribe(c);var d={element:l,eventType:"change",eventListener:u,delete:function(){l.removeEventListener("change",u),a.isVisibleChanged.unsubscribe(c)}},f=this.eventListenersCollection.get(a.id);f?f.push(d):this.eventListenersCollection.set(a.id,[d])}},o.prototype.getInnerHTML=function(){var a,s,l,u,c,d,f=(a=this.backgroundColor)!==null&&a!==void 0?a:(l=(s=this.parentSurfaceProperty)===null||s===void 0?void 0:s.themeProvider)===null||l===void 0?void 0:l.legendBackgroundBrush,h=(u=this.textColor)!==null&&u!==void 0?u:(d=(c=this.parentSurfaceProperty)===null||c===void 0?void 0:c.themeProvider)===null||d===void 0?void 0:d.labelForegroundBrush,p=this.renderableSeriesArray.map(function(_,C){var P;return{id:_.id,name:(P=_.seriesName)!==null&&P!==void 0?P:"Series ".concat(C+1),color:_.stroke,checked:_.isVisible,gradient:void 0}}),g=this.parentSurfaceProperty.getSeriesViewRectPadding(!1),v=g.left,y=g.top,m=g.right,b=g.bottom,S=this.isExternal()?new i.Thickness(this.margin,this.margin,this.margin,this.margin):new i.Thickness(y+this.margin,m+this.margin,b+this.margin,v+this.margin);return this.getLegendHTML(this.placement,h,f,S,this.orientation,this.showCheckboxes,this.showSeriesMarkers,p)},o})(e.SciChartLegendBase);return EE.SciChart3DLegend=n,EE}var cSe;function Cje(){if(cSe)return wb;cSe=1;var t=wb&&wb.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})(),e=wb&&wb.__assign||function(){return e=Object.assign||function(s){for(var l,u=1,c=arguments.length;u<c;u++){l=arguments[u];for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&(s[d]=l[d])}return s},e.apply(this,arguments)};Object.defineProperty(wb,"__esModule",{value:!0}),wb.LegendModifier3D=void 0;var i=ps(),n=Ho(),r=dR(),o=Pje(),a=(function(s){t(l,s);function l(u){var c=this,d;return c=s.call(this,u)||this,c._legendOptions={},c.type=n.EChart3DModifierType.Legend,c.isCheckedChanged=new i.EventHandler,c._legendOptions=e({},u),c.legendItemCheckedChanged=c.legendItemCheckedChanged.bind(c),c.sciChart3DLegend=(d=u==null?void 0:u.legend)!==null&&d!==void 0?d:new o.SciChart3DLegend(u),c.applyLegendOptions(c.sciChart3DLegend,u),c}return l.prototype.applyLegendOptions=function(u,c){var d,f,h,p,g,v;u.showCheckboxes=(d=c==null?void 0:c.showCheckboxes)!==null&&d!==void 0?d:u.showCheckboxes,u.showSeriesMarkers=(f=c==null?void 0:c.showSeriesMarkers)!==null&&f!==void 0?f:u.showSeriesMarkers,u.margin=(h=c==null?void 0:c.margin)!==null&&h!==void 0?h:u.margin,u.orientation=(p=c==null?void 0:c.orientation)!==null&&p!==void 0?p:u.orientation,u.placement=(g=c==null?void 0:c.placement)!==null&&g!==void 0?g:u.placement,u.showLegend=(v=c==null?void 0:c.showLegend)!==null&&v!==void 0?v:u.showLegend,u.legendItemCheckedChangedCallback=this.legendItemCheckedChanged,c!=null&&c.isCheckedChangedCallback&&this.isCheckedChanged.subscribe(function(y){return c.isCheckedChangedCallback(y.series,y.isChecked)})},l.prototype.applyTheme=function(u){var c;s.prototype.applyTheme.call(this,u),(c=this.sciChart3DLegend)===null||c===void 0||c.applyTheme()},l.prototype.onParentSurfaceRendered=function(){s.prototype.onParentSurfaceRendered.call(this)},l.prototype.onAttach=function(){var u;s.prototype.onAttach.call(this),this.sciChart3DLegend||(this.sciChart3DLegend=(u=this._legendOptions.legend)!==null&&u!==void 0?u:new o.SciChart3DLegend(this._legendOptions),this.applyLegendOptions(this.sciChart3DLegend,this._legendOptions)),this.sciChart3DLegend.attachTo(this.parentSurface),this.sciChart3DLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries())},l.prototype.onDetach=function(){var u,c;this.sciChart3DLegend&&(this._legendOptions.margin=this.sciChart3DLegend.margin,this._legendOptions.orientation=this.sciChart3DLegend.orientation,this._legendOptions.placement=this.sciChart3DLegend.placement,this._legendOptions.showCheckboxes=this.sciChart3DLegend.showCheckboxes,this._legendOptions.showLegend=this.sciChart3DLegend.showLegend,this._legendOptions.showSeriesMarkers=this.sciChart3DLegend.showSeriesMarkers),s.prototype.onDetach.call(this),(u=this.sciChart3DLegend)===null||u===void 0||u.setRenderableSeriesArray([]),(c=this.sciChart3DLegend)===null||c===void 0||c.detach(),this.sciChart3DLegend=void 0},l.prototype.includeSeries=function(u,c){var d;return s.prototype.includeSeries.call(this,u,c)?(this.isAttached&&this.sciChart3DLegend.setRenderableSeriesArray(this.getIncludedRenderableSeries()),(d=this.parentSurface)===null||d===void 0||d.invalidateElement(),!0):!1},l.prototype.testIsIncludedSeries=function(u){return this.includedSeries.testIsIncluded(u.id)},l.prototype.toJSON=function(){var u=s.prototype.toJSON.call(this),c={margin:this.sciChart3DLegend.margin,orientation:this.sciChart3DLegend.orientation,placement:this.sciChart3DLegend.placement,showCheckboxes:this.sciChart3DLegend.showCheckboxes,showLegend:this.sciChart3DLegend.showLegend,showSeriesMarkers:this.sciChart3DLegend.showSeriesMarkers};return Object.assign(u.options,c),u},l.prototype.delete=function(){s.prototype.delete.call(this),this.onDetach()},l.prototype.legendItemCheckedChanged=function(u,c){var d;(d=this.isCheckedChanged)===null||d===void 0||d.raiseEvent({series:u,isChecked:c})},l})(r.ChartModifierBase3D);return wb.LegendModifier3D=a,wb}var dSe;function n$(){if(dSe)return Kx;dSe=1,Object.defineProperty(Kx,"__esModule",{value:!0}),Kx.buildModifiers3D=Kx.buildModifiers=void 0;var t=YO(),e=t$(),i=Eie(),n=r$(),r=wie(),o=BW(),a=i$(),s=JBe(),l=Y3(),u=Aie(),c=tje(),d=rje(),f=Rie(),h=ije(),p=ga(),g=Ho(),v=Tv(),y=mo(),m=aje(),b=uje(),S=cje(),_=dje(),C=fje(),P=hje(),x=pje(),E=gje(),A=pJ(),R=yje(),M=Mie(),D=mje(),F=gJ(),I=_je(),V=Cje();(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.Cursor,function(k){return new t.CursorModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarCursor,function(k){return new S.PolarCursorModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.DataPointSelection,function(k){return new e.DataPointSelectionModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarDataPointSelection,function(k){return new _.PolarDataPointSelectionModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarSeriesSelection,function(k){return new C.PolarSeriesSelectionModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.MouseWheelZoom,function(k){return new n.MouseWheelZoomModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarMouseWheelZoom,function(k){return new x.PolarMouseWheelZoomModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PinchZoom,function(k){return new o.PinchZoomModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.Rollover,function(k){return new a.RolloverModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.VerticalSlice,function(k){return new s.VerticalSliceModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.RubberBandXYZoom,function(k){return new l.RubberBandXyZoomModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarArcZoom,function(k){return new b.PolarArcZoomModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.SeriesSelection,function(k){return new u.SeriesSelectionModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.AnnotationHover,function(k){return new m.AnnotationHoverModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.XAxisDrag,function(k){return new c.XAxisDragModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.YAxisDrag,function(k){return new d.YAxisDragModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.ZoomExtents,function(k){return new f.ZoomExtentsModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarZoomExtents,function(k){return new E.PolarZoomExtentsModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.ZoomPan,function(k){return new h.ZoomPanModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarPan,function(k){return new A.PolarPanModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.OverviewRangeSelection,function(k){return new r.OverviewRangeSelectionModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.Legend,function(k){return new i.LegendModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart2DModifier,g.EChart2DModifierType.PolarLegend,function(k){return new P.PolarLegendModifier(k)},!0);var z=function(k){typeof k=="string"&&(k=JSON.parse(k,v.chartReviver));var X=[];if(Array.isArray(k))for(var W=0,Y=k;W<Y.length;W++){var te=Y[W];X.push(G(te))}else X.push(G(k));return X};Kx.buildModifiers=z;var G=function(k){return k.type===g.EChart2DModifierType.Custom?(0,y.createType)(p.EBaseType.Chart2DModifier,k.customType,null,k.options):(0,y.createType)(p.EBaseType.Chart2DModifier,k.type,null,k.options)};(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.MouseWheelZoom,function(k){return new R.MouseWheelZoomModifier3D(k)},!0),(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.Orbit,function(k){return new D.OrbitModifier3D(k)},!0),(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.PinchZoom,function(k){return new M.PinchZoomModifier3D(k)},!0),(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.Tooltip,function(k){return new F.TooltipModifier3D(k)},!0),(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.ZoomExtents,function(k){return new I.ResetCamera3DModifier(k)},!0),(0,y.registerType)(p.EBaseType.Chart3DModifier,g.EChart3DModifierType.Legend,function(k){return new V.LegendModifier3D(k)},!0);var H=function(k){typeof k=="string"&&(k=JSON.parse(k,v.chartReviver));var X=[];if(Array.isArray(k))for(var W=0,Y=k;W<Y.length;W++){var te=Y[W];X.push(U(te))}else X.push(U(k));return X};Kx.buildModifiers3D=H;var U=function(k){return k.type===g.EChart3DModifierType.Custom?(0,y.createType)(p.EBaseType.Chart3DModifier,k.customType,null,k.options):(0,y.createType)(p.EBaseType.Chart3DModifier,k.type,null,k.options)};return Kx}var i7={},lB={},fSe;function Tje(){if(fSe)return lB;fSe=1,Object.defineProperty(lB,"__esModule",{value:!0}),lB.DataPointSelectionPaletteProvider=void 0;var t=JD(),e=hn(),i=Ti(),n=vS(),r=(function(){function a(s){this.strokePaletteMode=n.EStrokePaletteMode.SOLID,this.fillPaletteMode=n.EFillPaletteMode.SOLID,s!=null&&s.stroke&&(this.selectedStroke=(0,i.parseColorToUIntArgb)(s==null?void 0:s.stroke)),s!=null&&s.fill&&(this.selectedFill=(0,i.parseColorToUIntArgb)(s==null?void 0:s.fill)),this.selectedPointMarker={stroke:this.selectedStroke,fill:this.selectedFill}}return a.prototype.onAttached=function(s){this.seriesType?this.seriesType!==s.type&&(s.paletteProvider=n.DefaultPaletteProvider.createEmpty(),console.error("One instance of a DataPointSelectionPaletteProvider cannot be shared between series of different types")):this.seriesType=s.type;var l=[e.ESeriesType.OhlcSeries,e.ESeriesType.CandlestickSeries,e.ESeriesType.ColumnSeries,e.ESeriesType.StackedColumnSeries,e.ESeriesType.RectangleSeries];l.includes(this.seriesType)||(this.selectedStroke=void 0);var u=[e.ESeriesType.StackedColumnSeries,e.ESeriesType.ColumnSeries,e.ESeriesType.CandlestickSeries,e.ESeriesType.RectangleSeries];u.includes(this.seriesType)||(this.selectedFill=void 0)},a.prototype.onDetached=function(){},a.prototype.overridePointMarkerArgb=function(s,l,u,c,d){if(d!=null&&d.isSelected)return this.selectedPointMarker},a.prototype.overrideStrokeArgb=function(s,l,u,c,d){if(d!=null&&d.isSelected)return this.selectedStroke},a.prototype.overrideFillArgb=function(s,l,u,c,d){if(d!=null&&d.isSelected)return this.selectedFill},a.prototype.toJSON=function(){return{type:t.EPaletteProviderType.DataPointSelection,options:{stroke:o(this.selectedStroke,i.parseArgbToHtmlColor),fill:o(this.selectedFill,i.parseArgbToHtmlColor)}}},a})();lB.DataPointSelectionPaletteProvider=r;var o=function(a,s){if(a)return s(a)};return lB}var wE={},uB={},cB={},hSe;function YS(){if(hSe)return cB;hSe=1,Object.defineProperty(cB,"__esModule",{value:!0}),cB.BaseAnimationStyle=void 0;var t=Ng(),e=Ti(),i=Lre(),n=RI(),r=(function(){function o(a){var s,l,u;this.opacity=void 0,this.strokeProperty=void 0,this.strokeThickness=(s=a==null?void 0:a.strokeThickness)!==null&&s!==void 0?s:this.strokeThickness,this.stroke=(l=a==null?void 0:a.stroke)!==null&&l!==void 0?l:this.strokeProperty,a!=null&&a.pointMarker&&(this.pointMarker=a.pointMarker.type===t.EPointMarkerType.Sprite?new i.CustomPointMarkerStyle(a.pointMarker):new n.PointMarkerStyle(a.pointMarker)),this.opacity=(u=a==null?void 0:a.opacity)!==null&&u!==void 0?u:this.opacity}return Object.defineProperty(o.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(a){this.strokeProperty=a,a&&(this.strokeARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeARGB",{get:function(){return this.strokeARGBProperty},enumerable:!1,configurable:!0}),o})();return cB.BaseAnimationStyle=r,cB}var pSe;function Bg(){if(pSe)return uB;pSe=1,Object.defineProperty(uB,"__esModule",{value:!0}),uB.SeriesAnimation=void 0;var t=mo(),e=ad(),i=ga(),n=Ti(),r=bo(),o=$S(),a=YS(),s=RI(),l=(function(){function u(c){var d,f,h,p,g;if(this.delay=0,this.duration=3e3,this.ease=e.easing.linear,this.isFadeEffectAnimation=!1,this.isOnStartAnimation=!1,this.typeMap=new Map,this.delay=(d=c==null?void 0:c.delay)!==null&&d!==void 0?d:this.delay,this.duration=(f=c==null?void 0:c.duration)!==null&&f!==void 0?f:this.duration,this.isFadeEffectAnimation=(h=c==null?void 0:c.fadeEffect)!==null&&h!==void 0?h:this.isFadeEffectAnimation,c!=null&&c.ease&&typeof c.ease=="string"&&(c.ease=e.easing[c.ease]),this.ease=(p=c==null?void 0:c.ease)!==null&&p!==void 0?p:this.ease,this.reverse=(g=c==null?void 0:c.reverse)!==null&&g!==void 0?g:this.reverse,c!=null&&c.onCompleted)if(typeof c.onCompleted=="string"){this.typeMap.set("onCompleted",c.onCompleted);var v=(0,t.getFunction)(i.EBaseType.OptionFunction,c.onCompleted);this.onCompleted=v}else this.onCompleted=c.onCompleted}return u.prototype.toJSON=function(){var c={delay:this.delay,duration:this.duration,ease:this.ease.name,fadeEffect:this.isFadeEffectAnimation,reverse:this.reverse,onCompleted:this.typeMap.get("onCompleted")};return{type:this.type,options:c}},u.prototype.calculateAnimationValues=function(c,d,f,h,p){},u.prototype.calculateDataSeriesAnimationValues=function(c,d,f,h,p){var g=d.size();if(g!==f.size())throw new Error("DoubleVectors with initialValues and finalValues must have the same length");typeof h.getRaw!="function"&&h.resize(g,0);for(var v=(0,r.vectorToArrayViewF64)(d,c),y=(0,r.vectorToArrayViewF64)(f,c),m=(0,r.vectorToArrayViewF64)(h,c),b=0;b<g;b++)m[b]=o.animationHelpers.interpolateNumber(v[b],y[b],p)},u.prototype.getSeriesStyle=function(c){var d,f,h=c;if(!h.isStacked)return new a.BaseAnimationStyle({stroke:h.stroke,strokeThickness:h.strokeThickness,opacity:h.opacity,pointMarker:(f=(d=h.pointMarker)===null||d===void 0?void 0:d.getPointMarkerStyle())!==null&&f!==void 0?f:new s.PointMarkerStyle})},u.prototype.updateSeriesProperties=function(c,d,f){var h,p,g,v,y;this.reverse&&(f=1-f);var m=c,b=m.pointMarker;if(this.isStyleAnimation){if(this.styles.strokeThickness!==void 0){var S=d==null?void 0:d.strokeThickness,_=this.styles.strokeThickness;m.strokeThickness=S+(_-S)*f}if(this.styles.stroke!==void 0){var C=o.animationHelpers.interpolateColor(d.strokeARGB,this.styles.strokeARGB,f);m.stroke=(0,n.parseArgbToHtmlColor)(C)}if(this.styles.opacity!==void 0&&(m.opacity=o.animationHelpers.interpolateNumber(d.opacity,this.styles.opacity,f)),this.styles.pointMarker!==void 0){m.pointMarker.suspendUpdates();var P=(p=(h=d.pointMarker)===null||h===void 0?void 0:h.width)!==null&&p!==void 0?p:0,x=(v=(g=d.pointMarker)===null||g===void 0?void 0:g.height)!==null&&v!==void 0?v:0;if(m.pointMarker.width=o.animationHelpers.interpolateNumber(P,this.styles.pointMarker.width,f),m.pointMarker.height=o.animationHelpers.interpolateNumber(x,this.styles.pointMarker.height,f),!this.styles.pointMarker.isCustomPointMarker){var E=d.pointMarker,A=this.styles.pointMarker,R=(y=E==null?void 0:E.strokeThickness)!==null&&y!==void 0?y:0;m.pointMarker.strokeThickness=o.animationHelpers.interpolateNumber(R,A.strokeThickness,f);var M=o.animationHelpers.interpolateColor(E.fillARGB,A.fillARGB,f);m.pointMarker.fill=(0,n.parseArgbToHtmlColor)(M);var D=o.animationHelpers.interpolateColor(E.strokeARGB,A.strokeARGB,f);m.pointMarker.stroke=(0,n.parseArgbToHtmlColor)(D)}m.pointMarker.resumeUpdates()}}if(this.isFadeEffectAnimation){var F=d.opacity*f;m.opacity=F,b&&(b.opacity=F)}},Object.defineProperty(u.prototype,"isStyleAnimation",{get:function(){return!!this.styles},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"isDataSeriesAnimation",{get:function(){return!!this.dataSeries},enumerable:!1,configurable:!0}),u})();return uB.SeriesAnimation=l,uB}var gSe;function xje(){if(gSe)return wE;gSe=1;var t=wE&&wE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(wE,"__esModule",{value:!0}),wE.FadeAnimation=void 0;var e=Gf(),i=Bg(),n=(function(r){t(o,r);function o(a){var s=this,l;return s=r.call(this,a)||this,s.type=e.EAnimationType.Fade,s.isFadeEffectAnimation=(l=a==null?void 0:a.fadeEffect)!==null&&l!==void 0?l:!0,s}return o.prototype.calculateAnimationValues=function(a,s,l,u,c){a.SCRTAnimationHelperFade(s,u,l)},o})(i.SeriesAnimation);return wE.FadeAnimation=n,wE}var AE={},vSe;function Eje(){if(vSe)return AE;vSe=1;var t=AE&&AE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(AE,"__esModule",{value:!0}),AE.ScaleAnimation=void 0;var e=Gf(),i=Bg(),n=(function(r){t(o,r);function o(a){var s=this,l;return s=r.call(this,a)||this,s.type=e.EAnimationType.Scale,s.zeroLine=0,s.isOnStartAnimation=!0,s.zeroLine=(l=a==null?void 0:a.zeroLine)!==null&&l!==void 0?l:s.zeroLine,s}return o.prototype.calculateAnimationValues=function(a,s,l,u,c){c===void 0&&(c=!1);var d=c?0:this.zeroLine;a.SCRTAnimationHelperScale(s,d,this.reverse?1-u:u,l)},o.prototype.toJSON=function(){var a=r.prototype.toJSON.call(this),s={zeroLine:this.zeroLine};return Object.assign(a.options,s),a},o})(i.SeriesAnimation);return AE.ScaleAnimation=n,AE}var OE={},ySe;function wje(){if(ySe)return OE;ySe=1;var t=OE&&OE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(OE,"__esModule",{value:!0}),OE.SweepAnimation=void 0;var e=Gf(),i=Bg(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.type=e.EAnimationType.Sweep,s.isOnStartAnimation=!0,s}return o.prototype.updateSeriesProperties=function(a,s,l){r.prototype.updateSeriesProperties.call(this,a,s,l),l===0?a.dataSeries.containsNaN=!0:l===1&&(a.dataSeries.containsNaN=!1)},o.prototype.calculateAnimationValues=function(a,s,l,u,c){a.SCRTAnimationHelperSweep(s,this.reverse?1-u:u,l)},o})(i.SeriesAnimation);return OE.SweepAnimation=n,OE}var DE={},mSe;function Aje(){if(mSe)return DE;mSe=1;var t=DE&&DE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(DE,"__esModule",{value:!0}),DE.WaveAnimation=void 0;var e=Gf(),i=Bg(),n=(function(r){t(o,r);function o(a){var s=this,l,u;return s=r.call(this,a)||this,s.type=e.EAnimationType.Wave,s.pointDurationFraction=.2,s.zeroLine=0,s.isOnStartAnimation=!0,s.pointDurationFraction=(l=a==null?void 0:a.pointDurationFraction)!==null&&l!==void 0?l:s.pointDurationFraction,s.zeroLine=(u=a==null?void 0:a.zeroLine)!==null&&u!==void 0?u:s.zeroLine,s}return o.prototype.updateSeriesProperties=function(a,s,l){r.prototype.updateSeriesProperties.call(this,a,s,l),l===0?a.dataSeries.containsNaN=!0:l===1&&(a.dataSeries.containsNaN=!1)},o.prototype.calculateAnimationValues=function(a,s,l,u,c){c===void 0&&(c=!1);var d=this.pointDurationFraction,f=c?0:this.zeroLine;a.SCRTAnimationHelperWave(s,d,f,this.reverse?1-u:u,l)},o.prototype.toJSON=function(){var a=r.prototype.toJSON.call(this),s={zeroLine:this.zeroLine,pointDurationFraction:this.pointDurationFraction};return Object.assign(a.options,s),a},o})(i.SeriesAnimation);return DE.WaveAnimation=n,DE}var RE={},dB={},bSe;function UI(){if(bSe)return dB;bSe=1,Object.defineProperty(dB,"__esModule",{value:!0}),dB.DataLabelState=void 0;var t=di(),e=Ti(),i=bo(),n=Zi(),r=(function(){function o(a,s,l,u,c,d){var f,h,p,g,v,y,m,b,S,_,C;this.dataLabels=[],this.indexProperty=0,this.xCoordCache=void 0,this.yCoordCache=void 0;var P=s.pointSeries,x=s.xCoordinateCalculator.isCategoryCoordinateCalculator;if(this.style=n.DpiHelper.adjustTextStyle(l),this.color=(0,e.parseColorToUIntArgb)(u),this.xValues=(0,i.vectorToArrayViewF64)(x?P.indexes:P.xValues,a.webAssemblyContext),this.yValues=(0,i.vectorToArrayViewF64)(c,a.webAssemblyContext),this.indexes=(0,i.vectorToArrayViewF64)((f=s.pointSeries)===null||f===void 0?void 0:f.indexes,a.webAssemblyContext),this.parentSeries=d,this.renderPassData=s,!((h=this.parentSeries.dataSeries)===null||h===void 0)&&h.yFinalAnimationValues&&(this.yFinalValues=(0,i.vectorToArrayViewF64)((p=this.parentSeries.dataSeries)===null||p===void 0?void 0:p.yFinalAnimationValues,a.webAssemblyContext)),this.isXFlipped=(s.isVerticalChart?this.renderPassData.yCoordinateCalculator:this.renderPassData.xCoordinateCalculator).hasFlippedCoordinates,this.isYFlipped=(s.isVerticalChart?this.renderPassData.xCoordinateCalculator:this.renderPassData.yCoordinateCalculator).hasFlippedCoordinates,s.indexRange)this.indexStart=P.resampled?0:s.indexRange.min,this.pointCount=P.resampled?P.count:s.indexRange.diff+1,this.indexEnd=P.resampled?P.count-1:s.indexRange.max,this.pointCount>1?this.pointGap=s.isVerticalChart?Math.abs(this.yCoord(this.indexStart)-this.yCoord(this.indexEnd))/this.pointCount:Math.abs(this.xCoord(this.indexStart)-this.xCoord(this.indexEnd))/this.pointCount:this.pointGap=1/0;else{var E=this.parentSeries.getIndicesRange(new t.NumberRange(s.xCoordinateCalculator.visibleMin,s.xCoordinateCalculator.visibleMax),x);this.indexStart=E.min,this.indexEnd=E.max,this.pointCount=s.indexRange.diff+1,this.pointCount>1?this.pointGap=s.isVerticalChart?Math.abs(this.yCoord(this.indexStart)-this.yCoord(this.indexEnd))/this.pointCount:Math.abs(this.xCoord(this.indexStart)-this.xCoord(this.indexEnd))/this.pointCount:this.pointGap=1/0}this.index=this.indexStart,this.font=a.getFont(this.style),this.xPadding=((v=(g=this.style.padding)===null||g===void 0?void 0:g.left)!==null&&v!==void 0?v:0)+((m=(y=this.style.padding)===null||y===void 0?void 0:y.right)!==null&&m!==void 0?m:0),this.yPadding=((S=(b=this.style.padding)===null||b===void 0?void 0:b.top)!==null&&S!==void 0?S:0)+((C=(_=this.style.padding)===null||_===void 0?void 0:_.bottom)!==null&&C!==void 0?C:0),this.fifoSweeping=d.dataSeries.fifoSweeping}return Object.defineProperty(o.prototype,"index",{get:function(){return this.indexProperty},set:function(a){this.xCoordCache=void 0,this.yCoordCache=void 0,this.indexProperty=a},enumerable:!1,configurable:!0}),o.prototype.getIndexInternal=function(a){var s=a??this.indexProperty;return this.isXFlipped||(s=this.indexEnd-(s-this.indexStart)),s},o.prototype.xVal=function(a){return this.xValues[this.getIndexInternal(a)]},o.prototype.yVal=function(a){return this.yValues[this.getIndexInternal(a)]},o.prototype.yValAfterAnimation=function(a){return this.yFinalValues?this.yFinalValues[this.getIndexInternal(a)]:this.yVal(a)},o.prototype.xCoord=function(a){return this.renderPassData.isVerticalChart?this.yCoordInternal(a):this.xCoordInternal(a)},o.prototype.yCoord=function(a){return this.renderPassData.isVerticalChart?this.xCoordInternal(a):this.yCoordInternal(a)},o.prototype.hasNext=function(a){var s=a??this.indexProperty;return this.isXFlipped?s<this.indexEnd:s>0},Object.defineProperty(o.prototype,"lastLabel",{get:function(){if(this.dataLabels.length>0)return this.dataLabels[this.dataLabels.length-1]},enumerable:!1,configurable:!0}),o.prototype.getMetaData=function(){var a=this.indexes[this.getIndexInternal()];return this.parentSeries.dataSeries.getMetadataAt(a,this.fifoSweeping)},Object.defineProperty(o.prototype,"isVerticalChart",{get:function(){return this.renderPassData.isVerticalChart},enumerable:!1,configurable:!0}),o.prototype.getXCoord=function(a){return this.renderPassData.xCoordinateCalculator.getCoordinate(a)},o.prototype.getYCoord=function(a){return this.renderPassData.yCoordinateCalculator.getCoordinate(a)},o.prototype.xCoordInternal=function(a){return a!==void 0?this.renderPassData.xCoordinateCalculator.getCoordinate(this.xVal(a)):this.xCoordCache!==void 0?this.xCoordCache:(this.xCoordCache=this.renderPassData.xCoordinateCalculator.getCoordinate(this.xVal()),this.xCoordCache)},o.prototype.yCoordInternal=function(a){return a!==void 0?this.renderPassData.yCoordinateCalculator.getCoordinate(this.yVal(a)):this.yCoordCache!==void 0?this.yCoordCache:(this.yCoordCache=this.renderPassData.yCoordinateCalculator.getCoordinate(this.yVal()),this.yCoordCache)},o})();return dB.DataLabelState=r,dB}var ME={},LE={},n7={},SSe;function Lie(){return SSe||(SSe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EDataLabelSkipMode=void 0,(function(e){e.ShowAll="ShowAll",e.SkipIfOverlapPrevious="SkipIfOverlapPrevious",e.SkipIfOverlapNext="SkipIfOverlapNext",e.SkipIfSame="SkipIfSame"})(t.EDataLabelSkipMode||(t.EDataLabelSkipMode={}))})(n7)),n7}var _Se;function Wv(){if(_Se)return LE;_Se=1;var t=LE&&LE.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(LE,"__esModule",{value:!0}),LE.DataLabelProvider=void 0;var e=ci(),i=$i(),n=Rn(),r=Tc(),o=Ac(),a=Lie(),s=Fg(),l=Du(),u=an(),c=LI(),d=UI(),f=GV(),h=pa(),p=id(),g=jv(),v=(function(y){t(m,y);function m(b){var S=this,_,C,P,x,E,A,R,M,D,F,I,V;return S=y.call(this,b)||this,S.type=o.EDataLabelProviderType.Default,S.dataLabels=[],S.updateTextInAnimation=!1,S.pointGapThresholdProperty=0,S.pointCountThresholdProperty=1/0,S.numericFormatProperty=s.ENumericFormat.Decimal,S.engineeringPrefixProperty={},S.precisionProperty=1,S.skipModeProperty=a.EDataLabelSkipMode.SkipIfOverlapPrevious,S.skipNumberProperty=0,S.horizontalTextPositionProperty=r.EHorizontalTextPosition.Right,S.verticalTextPositionProperty=r.EVerticalTextPosition.Above,S.isEnabledProperty=!0,S.pointGapThresholdProperty=(_=b==null?void 0:b.pointGapThreshold)!==null&&_!==void 0?_:S.pointGapThresholdProperty,S.pointCountThresholdProperty=(C=b==null?void 0:b.pointCountThreshold)!==null&&C!==void 0?C:S.pointCountThresholdProperty,S.numericFormatProperty=(P=b==null?void 0:b.numericFormat)!==null&&P!==void 0?P:S.numericFormatProperty,S.engineeringPrefixProperty=(x=b==null?void 0:b.engineeringPrefix)!==null&&x!==void 0?x:S.engineeringPrefixProperty,S.precision=(E=b==null?void 0:b.precision)!==null&&E!==void 0?E:S.precisionProperty,S.skipNumberProperty=(A=b==null?void 0:b.skipNumber)!==null&&A!==void 0?A:S.skipNumberProperty,S.skipModeProperty=(R=b==null?void 0:b.skipMode)!==null&&R!==void 0?R:S.skipModeProperty,S.metaDataSelector=b==null?void 0:b.metaDataSelector,S.ySelector=(M=b==null?void 0:b.ySelector)!==null&&M!==void 0?M:(function(z){return z.yValues}),S.updateTextInAnimation=(D=b==null?void 0:b.updateTextInAnimation)!==null&&D!==void 0?D:S.updateTextInAnimation,S.horizontalTextPositionProperty=(F=b==null?void 0:b.horizontalTextPosition)!==null&&F!==void 0?F:S.horizontalTextPosition,S.verticalTextPositionProperty=(I=b==null?void 0:b.verticalTextPosition)!==null&&I!==void 0?I:S.verticalTextPosition,S.isEnabledProperty=(V=b==null?void 0:b.isEnabled)!==null&&V!==void 0?V:S.isEnabledProperty,S}return m.prototype.onAttach=function(b,S){e.Guard.notNull(b,"webAssemblyContext"),e.Guard.notNull(S,"parentSeries"),this.webAssemblyContext=b,this.parentSeries=S},Object.defineProperty(m.prototype,"pointGapThreshold",{get:function(){return this.pointGapThresholdProperty},set:function(b){this.pointGapThresholdProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"pointCountThreshold",{get:function(){return this.pointCountThresholdProperty},set:function(b){this.pointCountThresholdProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"skipMode",{get:function(){return this.skipModeProperty},set:function(b){this.skipModeProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"skipNumber",{get:function(){return this.skipNumberProperty},set:function(b){this.skipNumberProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"numericFormat",{get:function(){return this.numericFormatProperty},set:function(b){this.numericFormatProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"engineeringPrefix",{get:function(){return this.engineeringPrefixProperty},set:function(b){this.engineeringPrefixProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"precision",{get:function(){return this.precisionProperty},set:function(b){this.precisionProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"horizontalTextPosition",{get:function(){return this.horizontalTextPositionProperty},set:function(b){this.horizontalTextPositionProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"verticalTextPosition",{get:function(){return this.verticalTextPositionProperty},set:function(b){this.verticalTextPositionProperty=b,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"isEnabled",{get:function(){return this.isEnabledProperty},set:function(b){this.isEnabledProperty!==b&&(this.isEnabledProperty=b,this.invalidateParent())},enumerable:!1,configurable:!0}),m.prototype.getText=function(b){var S;if(this.metaDataSelector)return this.metaDataSelector(b.getMetaData());var _=!this.updateTextInAnimation&&b.parentSeries.isRunningAnimation,C=_?b.yValAfterAnimation():b.yVal();if(C===C)return this.engineeringPrefix?(0,l.formatNumber)(C,this.numericFormat,this.precision,this.engineeringPrefixProperty):(0,l.formatNumber)(C,(S=this.numericFormat)!==null&&S!==void 0?S:s.ENumericFormat.Decimal,this.precision)},m.prototype.shouldGenerate=function(b){if(b.pointCount>this.pointCountThresholdProperty||!b.font)return!1;var S=this.getText(b),_=(0,u.getTextBounds)(this.webAssemblyContext);return b.font.CalculateStringBounds(S??"",_,this.getLineSpacing()),b.pointGap>=_.m_fWidth*this.pointGapThreshold},m.prototype.getPosition=function(b,S){var _=b.xCoord(),C=b.yCoord(),P=new i.Point(_,C),x=(0,p.getNativeTextPosition)(_,C,this.horizontalTextPositionToAnchorPoint(this.horizontalTextPosition),this.verticalTextPositionToAnchorPoint(this.verticalTextPosition),S,this.getPadding());return{position:new i.Point(x.x,x.y),rotationAngle:0,rotationCenter:P}},m.prototype.getColor=function(b,S){return b.color},m.prototype.shouldSkipLabel=function(b,S){var _,C=b.parentSeries.parentSurface.seriesViewRect;if(S.rect.y<0||S.rect.bottom>C.height||S.rect.x<0||S.rect.right>C.width)return!0;switch(this.skipModeProperty){case a.EDataLabelSkipMode.SkipIfOverlapPrevious:return this.skipIfOverlapPrevious(b,S);case a.EDataLabelSkipMode.SkipIfOverlapNext:return this.skipIfOverlapNext(b,S);case a.EDataLabelSkipMode.SkipIfSame:return((_=b.lastLabel)===null||_===void 0?void 0:_.text)===S.text;case a.EDataLabelSkipMode.ShowAll:return!1;default:return!1}},m.prototype.getDataLabelState=function(b,S,_,C,P,x){return new d.DataLabelState(b,S,_,C,P,x)},m.prototype.generateDataLabels=function(b,S){if(this.dataLabels=[],!(!this.isEnabled||!this.style||!this.style.fontFamily||!this.style.fontSize)){var _=this.ySelector(S.pointSeries);if(!(!_||_.size()===0)){this.state=this.getDataLabelState(b,S,this.style,this.color,_,this.parentSeries);var C=this.parentSeries.dataSeries,P=C.fifoCapacity,x=C.fifoSweeping,E=C.fifoSweepingGap,A=C.fifoStartIndex,R=(0,u.getTextBounds)(this.webAssemblyContext);if(this.shouldGenerate(this.state)){for(var M=0,D=Math.max(0,this.skipNumberProperty),F=this.state.indexStart;F<=this.state.indexEnd;F+=D+1)if(this.state.index=this.skipModeProperty===a.EDataLabelSkipMode.SkipIfOverlapNext?this.state.indexEnd-(F-this.state.indexStart):F,!(x&&this.state.pointCount===P&&this.state.index>=A&&this.state.index<A+E)){var I=this.getText(this.state);if(I){this.state.font.CalculateStringBounds(I??"",R,this.getLineSpacing());var V=this.getPosition(this.state,R),z=V.position,G=V.rotationAngle,H=V.rotationCenter,U=this.getColor(this.state,I),k=R.GetLineBounds(0),X=k.m_fHeight;k.delete();var W={text:I,position:z,rect:new n.Rect(z.x,z.y-X,R.m_fWidth,R.m_fHeight),color:U,dataX:this.state.xCoord(),dataY:this.state.yCoord(),rotationAngle:G,rotationCenter:H};this.shouldSkipLabel(this.state,W)?M++:this.state.dataLabels.push(W)}}M>100&&M/(this.state.indexEnd-this.state.indexStart)>.8&&f.performanceWarnings.dataLabelsSkippingMany.warn(),this.dataLabels=this.state.dataLabels}}}},m.prototype.toJSON=function(){var b=y.prototype.toJSON.call(this),S={numericFormat:this.numericFormat,pointGapThreshold:this.pointGapThreshold,precision:this.precision,pointCountThreshold:this.pointCountThreshold,skipNumber:this.skipNumber,skipMode:this.skipMode,updateTextInAnimation:this.updateTextInAnimation,horizontalTextPosition:this.horizontalTextPosition,verticalTextPosition:this.verticalTextPosition,isEnabled:this.isEnabled,engineeringPrefix:this.engineeringPrefixProperty};return Object.assign(b.options,S),b},m.prototype.horizontalTextPositionToAnchorPoint=function(b){return b===r.EHorizontalTextPosition.Left?g.EHorizontalAnchorPoint.Right:b===r.EHorizontalTextPosition.Right?g.EHorizontalAnchorPoint.Left:g.EHorizontalAnchorPoint.Center},m.prototype.verticalTextPositionToAnchorPoint=function(b){return b===r.EVerticalTextPosition.Above?g.EVerticalAnchorPoint.Bottom:b===r.EVerticalTextPosition.Below?g.EVerticalAnchorPoint.Top:g.EVerticalAnchorPoint.Center},m.prototype.getPadding=function(){var b;return(b=this.style.padding)!==null&&b!==void 0?b:h.Thickness.fromNumber(0)},m.prototype.skipIfOverlapPrevious=function(b,S){var _=b.lastLabel;return!(!_||_.rect.right+b.xPadding<S.rect.left||Math.abs(_.rect.y-S.rect.y)>S.rect.height+b.yPadding)},m.prototype.skipIfOverlapNext=function(b,S){var _=b.lastLabel;return!(!_||S.rect.right+b.xPadding<_.rect.left||Math.abs(_.rect.y-S.rect.y)>S.rect.height+b.yPadding)},m})(c.BaseDataLabelProvider);return LE.DataLabelProvider=v,LE}var PSe;function fR(){if(PSe)return ME;PSe=1;var t=ME&&ME.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(ME,"__esModule",{value:!0}),ME.LineSeriesDataLabelProvider=void 0;var e=$i(),i=Ac(),n=id(),r=Wv(),o=(function(a){t(s,a);function s(l){var u=this,c;return u=a.call(this,l)||this,u.type=i.EDataLabelProviderType.Line,u.aboveBelowProperty=!0,u.aboveBelowProperty=(c=l==null?void 0:l.aboveBelow)!==null&&c!==void 0?c:u.aboveBelow,u}return Object.defineProperty(s.prototype,"aboveBelow",{get:function(){return this.aboveBelowProperty},set:function(l){this.aboveBelowProperty=l,this.invalidateParent()},enumerable:!1,configurable:!0}),s.prototype.generateDataLabels=function(l,u){var c=this.parentSeries;this.yAdj=Math.ceil(c.strokeThickness/2),c.pointMarker&&(this.yAdj=Math.max(this.yAdj,Math.ceil(c.pointMarker.height/2))),a.prototype.generateDataLabels.call(this,l,u)},s.prototype.getPosition=function(l,u){var c,d,f,h,p,g;if(this.aboveBelow){var v=l.xCoord(),y=l.yCoord(),m=new e.Point(v,y),b=u.GetLineBounds(0),S=u.m_fHeight-b.m_fHeight;if(b.delete(),y-=S,v+=(d=(c=this.style.padding)===null||c===void 0?void 0:c.left)!==null&&d!==void 0?d:0,l.hasNext()){var _=l.yCoord(l.index+1),C=l.xCoord(l.index+1);C>v&&_>y||C<v&&_<y?y-=this.yAdj+((h=(f=l.style.padding)===null||f===void 0?void 0:f.bottom)!==null&&h!==void 0?h:1):y+=(0,n.getTextHeightToBaseline)(u)+this.yAdj+((g=(p=l.style.padding)===null||p===void 0?void 0:p.top)!==null&&g!==void 0?g:1)}return{position:new e.Point(v,y),rotationAngle:0,rotationCenter:m}}else return a.prototype.getPosition.call(this,l,u)},s.prototype.toJSON=function(){var l=a.prototype.toJSON.call(this),u={aboveBelow:this.aboveBelow};return Object.assign(l.options,u),l},s})(r.DataLabelProvider);return ME.LineSeriesDataLabelProvider=o,ME}var CSe;function kie(){if(CSe)return RE;CSe=1;var t=RE&&RE.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(RE,"__esModule",{value:!0}),RE.BandSeriesDataLabelProvider=void 0;var e=$i(),i=Ac(),n=Fg(),r=Du(),o=id(),a=UI(),s=fR(),l=(function(u){t(c,u);function c(d){var f=this,h;return f=u.call(this,d)||this,f.type=i.EDataLabelProviderType.Band,f.singleLabelProperty=!1,f.singleLabelProperty=(h=d==null?void 0:d.singleLabel)!==null&&h!==void 0?h:f.singleLabelProperty,f}return Object.defineProperty(c.prototype,"singleLabel",{get:function(){return this.singleLabelProperty},set:function(d){this.singleLabelProperty=d,this.invalidateParent()},enumerable:!1,configurable:!0}),c.prototype.getText=function(d){if(this.singleLabel){if(this.state1.index=d.index,this.metaDataSelector){var f=d.renderPassData.pointSeries.indexes.get(d.index);return this.metaDataSelector(d.parentSeries.dataSeries.getMetadataAt(f))}var h=!this.updateTextInAnimation&&d.parentSeries.isRunningAnimation,p=h?d.yValAfterAnimation():d.yVal(),g=h?this.state1.yValAfterAnimation():this.state1.yVal();return this.getSingleLabelText(d.xVal(),p,g)}else return u.prototype.getText.call(this,d)},c.prototype.getSingleLabelText=function(d,f,h){var p,g,v,y;if(f===f||h===h){var m="";return f===f&&(m=(0,r.formatNumber)(f,(p=this.numericFormat)!==null&&p!==void 0?p:n.ENumericFormat.Decimal,(g=this.precision)!==null&&g!==void 0?g:1)),f===f&&h===h&&(m+=`
`),h===h&&(m+=(0,r.formatNumber)(h,(v=this.numericFormat)!==null&&v!==void 0?v:n.ENumericFormat.Decimal,(y=this.precision)!==null&&y!==void 0?y:1)),m}else return},c.prototype.getPosition=function(d,f){if(this.singleLabel){var h=d.xCoord(),p=d.yCoord(),g=this.state1.yCoord(),v=(p+g)/2,y=new e.Point(h,v),m=(0,o.getNativeTextPosition)(h,v,this.horizontalTextPositionToAnchorPoint(this.horizontalTextPosition),this.verticalTextPositionToAnchorPoint(this.verticalTextPosition),f,this.getPadding());return{position:new e.Point(m.x,m.y),rotationAngle:0,rotationCenter:y}}else return u.prototype.getPosition.call(this,d,f)},c.prototype.getY1Provider=function(d){return new s.LineSeriesDataLabelProvider(d.toJSON().options)},c.prototype.generateDataLabels=function(d,f){var h;if(this.singleLabel){var g=f.pointSeries.y1Values;this.state1=new a.DataLabelState(d,f,this.style,this.color,g,this.parentSeries),u.prototype.generateDataLabels.call(this,d,f)}else{u.prototype.generateDataLabels.call(this,d,f);var p=this.getY1Provider(this);p.ySelector=function(v){return v.y1Values},p.onAttach(this.webAssemblyContext,this.parentSeries),p.generateDataLabels(d,f),(h=this.dataLabels).push.apply(h,p.dataLabels)}},c.prototype.toJSON=function(){var d=u.prototype.toJSON.call(this),f={singleLabel:this.singleLabel};return Object.assign(d.options,f),d},c})(s.LineSeriesDataLabelProvider);return RE.BandSeriesDataLabelProvider=l,RE}var kE={},TSe;function Iie(){if(TSe)return kE;TSe=1;var t=kE&&kE.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(kE,"__esModule",{value:!0}),kE.BubbleSeriesDataLabelProvider=void 0;var e=$i(),i=Tc(),n=Ac(),r=Wv(),o=(function(a){t(s,a);function s(l){var u=this,c,d;return u=a.call(this,l)||this,u.type=n.EDataLabelProviderType.Bubble,u.horizontalTextPositionProperty=(c=l==null?void 0:l.horizontalTextPosition)!==null&&c!==void 0?c:i.EHorizontalTextPosition.Center,u.verticalTextPositionProperty=(d=l==null?void 0:l.verticalTextPosition)!==null&&d!==void 0?d:i.EVerticalTextPosition.Center,u}return s.prototype.getPosition=function(l,u){var c,d,f,h,p,g,v,y,m=l.xCoord(),b=l.yCoord(),S=new e.Point(m,b),_=u.GetLineBounds(0),C=u.m_fHeight-_.m_fHeight;_.delete(),b-=C;var P=Math.abs(l.parentSeries.getBubbleDiameter(l.getIndexInternal(l.index)))/2;return this.horizontalTextPosition===i.EHorizontalTextPosition.Center?m-=u.m_fWidth/2:this.horizontalTextPosition===i.EHorizontalTextPosition.Left?m-=u.m_fWidth+((d=(c=this.style.padding)===null||c===void 0?void 0:c.right)!==null&&d!==void 0?d:0)+P:m+=((h=(f=this.style.padding)===null||f===void 0?void 0:f.right)!==null&&h!==void 0?h:0)+P,this.verticalTextPosition===i.EVerticalTextPosition.Center?b+=u.m_fHeight/2:this.verticalTextPosition===i.EVerticalTextPosition.Below?b+=u.m_fHeight+((g=(p=this.style.padding)===null||p===void 0?void 0:p.top)!==null&&g!==void 0?g:0)+P:b-=((y=(v=this.style.padding)===null||v===void 0?void 0:v.bottom)!==null&&y!==void 0?y:0)+P,{position:new e.Point(m,b),rotationCenter:S,rotationAngle:0}},s})(r.DataLabelProvider);return kE.BubbleSeriesDataLabelProvider=o,kE}var IE={},xSe;function iI(){return xSe||(xSe=1,(function(t){var e=IE&&IE.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})(),i=IE&&IE.__assign||function(){return i=Object.assign||function(u){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(u[h]=c[h])}return u},i.apply(this,arguments)};Object.defineProperty(t,"__esModule",{value:!0}),t.ColumnSeriesDataLabelProvider=t.EColumnDataLabelPosition=void 0;var n=$i(),r=Ac(),o=Tc(),a=Wv(),s;(function(u){u.Outside="Outside",u.Inside="Inside",u.Position="Position"})(s=t.EColumnDataLabelPosition||(t.EColumnDataLabelPosition={}));var l=(function(u){e(c,u);function c(d){var f=this,h;return f=u.call(this,i({horizontalTextPosition:o.EHorizontalTextPosition.Center,verticalTextPosition:o.EVerticalTextPosition.Center},d))||this,f.type=r.EDataLabelProviderType.Column,f.positionModeProperty=s.Outside,f.positionModeProperty=(h=d==null?void 0:d.positionMode)!==null&&h!==void 0?h:f.positionMode,f}return Object.defineProperty(c.prototype,"positionMode",{get:function(){return this.positionModeProperty},set:function(d){this.positionModeProperty=d,this.invalidateParent()},enumerable:!1,configurable:!0}),c.prototype.generateDataLabels=function(d,f){var h=this.parentSeries;this.yAdj=Math.ceil(h.strokeThickness/2),h.pointMarker&&(this.yAdj=Math.max(this.yAdj,Math.ceil(h.pointMarker.height/2))),u.prototype.generateDataLabels.call(this,d,f)},c.prototype.getPosition=function(d,f){var h,p,g,v,y,m,b,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k=d.xCoord(),X=d.yCoord(),W=new n.Point(k,X),Y=f.GetLineBounds(0),te=f.m_fHeight-Y.m_fHeight;Y.delete(),X-=te;var oe=d.isXFlipped?-1:1,de=d.isYFlipped?-1:1;return d.isVerticalChart?(this.verticalTextPosition===o.EVerticalTextPosition.Center?X+=f.m_fHeight/2:this.verticalTextPosition===o.EVerticalTextPosition.Below?X+=f.m_fHeight+((p=(h=this.style.padding)===null||h===void 0?void 0:h.top)!==null&&p!==void 0?p:0):X-=(v=(g=this.style.padding)===null||g===void 0?void 0:g.bottom)!==null&&v!==void 0?v:0,this.positionMode===s.Outside?(d.yVal()*oe<0?k+=this.yAdj+((m=(y=d.style.padding)===null||y===void 0?void 0:y.left)!==null&&m!==void 0?m:1):k-=f.m_fWidth+this.yAdj+((S=(b=d.style.padding)===null||b===void 0?void 0:b.right)!==null&&S!==void 0?S:1),{position:new n.Point(k,X),rotationCenter:W,rotationAngle:0}):this.positionMode===s.Inside?(d.yVal()*oe<0?k-=f.m_fWidth+this.yAdj+((C=(_=d.style.padding)===null||_===void 0?void 0:_.right)!==null&&C!==void 0?C:1):k+=this.yAdj+((x=(P=d.style.padding)===null||P===void 0?void 0:P.left)!==null&&x!==void 0?x:1),{position:new n.Point(k,X),rotationCenter:W,rotationAngle:0}):u.prototype.getPosition.call(this,d,f)):(this.horizontalTextPosition===o.EHorizontalTextPosition.Center?k-=f.m_fWidth/2:this.horizontalTextPosition===o.EHorizontalTextPosition.Left?k-=f.m_fWidth+((A=(E=this.style.padding)===null||E===void 0?void 0:E.right)!==null&&A!==void 0?A:0):k+=(M=(R=this.style.padding)===null||R===void 0?void 0:R.left)!==null&&M!==void 0?M:0,this.positionMode===s.Outside?(d.yVal()*de>=0?X-=this.yAdj+((F=(D=d.style.padding)===null||D===void 0?void 0:D.bottom)!==null&&F!==void 0?F:1):X+=f.m_fHeight+this.yAdj+((V=(I=d.style.padding)===null||I===void 0?void 0:I.top)!==null&&V!==void 0?V:1),{position:new n.Point(k,X),rotationCenter:W,rotationAngle:0}):this.positionMode===s.Inside?(d.yVal()*de>=0?X+=f.m_fHeight+this.yAdj+((G=(z=d.style.padding)===null||z===void 0?void 0:z.top)!==null&&G!==void 0?G:1):X-=this.yAdj+((U=(H=d.style.padding)===null||H===void 0?void 0:H.bottom)!==null&&U!==void 0?U:1),{position:new n.Point(k,X),rotationCenter:W,rotationAngle:0}):u.prototype.getPosition.call(this,d,f))},c.prototype.toJSON=function(){var d=u.prototype.toJSON.call(this),f={positionMode:this.positionMode};return Object.assign(d.options,f),d},c})(a.DataLabelProvider);t.ColumnSeriesDataLabelProvider=l})(IE)),IE}var NE={},ESe;function Nie(){if(ESe)return NE;ESe=1;var t=NE&&NE.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(NE,"__esModule",{value:!0}),NE.ContoursDataLabelProvider=void 0;var e=$i(),i=Rn(),n=Ac(),r=Fg(),o=Ig(),a=Du(),s=Ti(),l=an(),u=Zi(),c=LI(),d=(function(f){t(h,f);function h(p){var g=this,v,y,m,b;return g=f.call(this,p)||this,g.type=n.EDataLabelProviderType.Contours,g.isEnabledProperty=!0,g.numericFormatProperty=r.ENumericFormat.Decimal,g.precisionProperty=1,g.labelRowCountProperty=10,g.numericFormatProperty=(v=p==null?void 0:p.numericFormat)!==null&&v!==void 0?v:g.numericFormatProperty,g.precision=(y=p==null?void 0:p.precision)!==null&&y!==void 0?y:g.precisionProperty,g.labelRowCountProperty=(m=p==null?void 0:p.labelRowCount)!==null&&m!==void 0?m:g.labelRowCountProperty,g.metaDataSelector=p==null?void 0:p.metaDataSelector,g.isEnabledProperty=(b=p==null?void 0:p.isEnabled)!==null&&b!==void 0?b:g.isEnabledProperty,g}return Object.defineProperty(h.prototype,"numericFormat",{get:function(){return this.numericFormatProperty},set:function(p){var g;this.numericFormatProperty=p,(g=this.parentSeries)===null||g===void 0||g.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"precision",{get:function(){return this.precisionProperty},set:function(p){var g;this.precisionProperty=p,(g=this.parentSeries)===null||g===void 0||g.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"labelRowCount",{get:function(){return this.labelRowCountProperty},set:function(p){var g;this.labelRowCountProperty=p,(g=this.parentSeries)===null||g===void 0||g.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"isEnabled",{get:function(){return this.isEnabledProperty},set:function(p){this.isEnabledProperty!==p&&(this.isEnabledProperty=p,this.invalidateParent())},enumerable:!1,configurable:!0}),h.prototype.getText=function(p,g){var v,y;if(this.metaDataSelector)return this.metaDataSelector(this.dataSeries.getMetadataAt(g,p));var m=this.zValues[g][p];if(m===m)return(0,a.formatNumber)(m,(v=this.numericFormat)!==null&&v!==void 0?v:r.ENumericFormat.Decimal,(y=this.precision)!==null&&y!==void 0?y:1)},h.prototype.getPosition=function(p,g,v,y,m,b){var S=b.xCoordinateCalculator.getCoordinate(v),_=b.yCoordinateCalculator.getCoordinate(y);if(b.isVerticalChart){var C=S;S=_,_=C}return new e.Point(S,_)},h.prototype.shouldGenerate=function(p,g,v){return p.height<v&&p.width<g},h.prototype.getColor=function(p,g,v){return this.colorValue},h.prototype.shouldSkipLabel=function(p,g,v,y,m){var b=this.parentSeries.parentSurface.seriesViewRect;return v.rect.y<0||v.rect.bottom>b.height||v.rect.x<0||v.rect.right>b.width},h.prototype.generateDataLabels=function(p,g){if(this.dataLabels=[],!(!this.isEnabled||!this.style||!this.style.fontFamily||!this.style.fontSize)){this.dataSeries=this.parentSeries.dataSeries,this.zValues=this.dataSeries.getZValues();var v=(0,l.getTextBounds)(this.webAssemblyContext),y=u.DpiHelper.adjustTextStyle(this.style),m=p.getFont(y);Math.abs(g.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(1))-g.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(0))),Math.abs(g.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(1))-g.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(0))),this.colorValue=(0,s.parseColorToUIntArgb)(this.color);var b=this.parentSeries.dataSeries,S=b.xStart,_=b.xStep,C=b.yStart,P=b.yStep,x=this.parentSeries.getContourDrawingParams();this.makeContourLabels(x,C,P,g,S,_,m,v)}},h.prototype.makeContourLabels=function(p,g,v,y,m,b,S,_){for(var C,P,x,E,A=p.majorStepZ,R=p.zOffset<0?A+p.zOffset:p.zOffset%A,M=(p.yMax-p.yMin)/(this.labelRowCount+1),D=g,F=0;F<this.dataSeries.arrayHeight;F++){var I=g+v*F;if(!(I<=D+M)&&(D=I,!(y.yCoordinateCalculator.visibleMin>I+v||y.yCoordinateCalculator.visibleMax<I)))for(var V=void 0,z=0;z<this.dataSeries.arrayWidth;z++){var G=m+b*z;if(!(y.xCoordinateCalculator.visibleMin>G+b||y.xCoordinateCalculator.visibleMax<G)){var H=this.zValues[F][z],U=void 0,k=G;if(!(H<p.zMin||H>p.zMax)){var X=!0;if(V!==void 0){var W=R+Math.floor((V-R)/A)*A,Y=W+A;W===V&&(W=W-A),H<=W?(U=(0,a.formatNumber)(W,(C=this.numericFormat)!==null&&C!==void 0?C:r.ENumericFormat.Decimal,(P=this.precision)!==null&&P!==void 0?P:1),k=X?G:b*(W-H)/(V-H)-b/2+G,X=!1):H>=Y&&(U=(0,a.formatNumber)(Y,(x=this.numericFormat)!==null&&x!==void 0?x:r.ENumericFormat.Decimal,(E=this.precision)!==null&&E!==void 0?E:1),k=X?G:b*(Y-H)/(H-V)-b/2+G,X=!1)}if(V=H,!!U){S.CalculateStringBounds(U??"",_,this.getLineSpacing());var te=new o.Size(_.m_fWidth,_.m_fHeight),oe=this.dataSeries.getXValue(z),de=this.dataSeries.getYValue(F),ge=this.getPosition(z,F,k,de,te,y),Ee=_.GetLineBounds(0),Re={text:U,position:ge,rect:new i.Rect(ge.x,ge.y-Ee.m_fHeight,te.width,te.height),color:this.getColor(z,F,U),dataX:oe,dataY:de,rotationAngle:0,rotationCenter:ge};Ee.delete(),this.dataLabels.push(Re)}}}}}},h.prototype.toJSON=function(){var p=f.prototype.toJSON.call(this),g={numericFormat:this.numericFormat,precision:this.precision,labelRowCount:this.labelRowCount,isEnabled:this.isEnabled};return Object.assign(p.options,g),p},h})(c.BaseDataLabelProvider);return NE.ContoursDataLabelProvider=d,NE}var FE={},wSe;function tH(){if(wSe)return FE;wSe=1;var t=FE&&FE.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(FE,"__esModule",{value:!0}),FE.HeatMapDataLabelProvider=void 0;var e=$i(),i=Rn(),n=Ac(),r=Fg(),o=Ig(),a=Du(),s=Ti(),l=an(),u=Zi(),c=LI(),d=(function(f){t(h,f);function h(p){var g=this,v,y,m;return g=f.call(this,p)||this,g.type=n.EDataLabelProviderType.Heatmap,g.isEnabledProperty=!0,g.numericFormatProperty=r.ENumericFormat.Decimal,g.precisionProperty=1,g.numericFormatProperty=(v=p==null?void 0:p.numericFormat)!==null&&v!==void 0?v:g.numericFormatProperty,g.precision=(y=p==null?void 0:p.precision)!==null&&y!==void 0?y:g.precisionProperty,g.metaDataSelector=p==null?void 0:p.metaDataSelector,g.isEnabledProperty=(m=p==null?void 0:p.isEnabled)!==null&&m!==void 0?m:g.isEnabledProperty,g}return Object.defineProperty(h.prototype,"numericFormat",{get:function(){return this.numericFormatProperty},set:function(p){var g;this.numericFormatProperty=p,(g=this.parentSeries)===null||g===void 0||g.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"precision",{get:function(){return this.precisionProperty},set:function(p){var g;this.precisionProperty=p,(g=this.parentSeries)===null||g===void 0||g.invalidateParentCallback()},enumerable:!1,configurable:!0}),Object.defineProperty(h.prototype,"isEnabled",{get:function(){return this.isEnabledProperty},set:function(p){this.isEnabledProperty!==p&&(this.isEnabledProperty=p,this.invalidateParent())},enumerable:!1,configurable:!0}),h.prototype.getText=function(p,g){var v,y;if(this.metaDataSelector)return this.metaDataSelector(this.dataSeries.getMetadataAt(g,p));var m=this.zValues[g][p];if(m===m)return(0,a.formatNumber)(m,(v=this.numericFormat)!==null&&v!==void 0?v:r.ENumericFormat.Decimal,(y=this.precision)!==null&&y!==void 0?y:1)},h.prototype.getPosition=function(p,g,v,y,m,b,S,_){var C=_.xCoordinateCalculator.getCoordinate(v),P=_.yCoordinateCalculator.getCoordinate(y);if(_.isVerticalChart){var x=C;C=P,P=x}return(_.isVerticalChart?_.yCoordinateCalculator.hasFlippedCoordinates:_.xCoordinateCalculator.hasFlippedCoordinates)?C+=(b-m.width)/2:C-=b-(b-m.width)/2,(_.isVerticalChart?_.xCoordinateCalculator.hasFlippedCoordinates:_.yCoordinateCalculator.hasFlippedCoordinates)?P+=S-(S-m.height)/2:P-=(S-m.height)/2,{position:new e.Point(C,P),rotationCenter:new e.Point(C,P),rotationAngle:0}},h.prototype.shouldGenerate=function(p,g,v){return p.height<v&&p.width<g},h.prototype.getColor=function(p,g,v){return this.colorValue},h.prototype.shouldSkipLabel=function(p,g,v,y,m){var b=this.parentSeries.parentSurface.seriesViewRect;return v.rect.y<0||v.rect.bottom>b.height||v.rect.x<0||v.rect.right>b.width},h.prototype.generateDataLabels=function(p,g){var v,y;if(this.dataLabels=[],!(!this.isEnabled||!this.style||!this.style.fontFamily||!this.style.fontSize)){this.dataSeries=this.parentSeries.dataSeries,this.zValues=this.dataSeries.getZValues();var m=(0,l.getTextBounds)(this.webAssemblyContext),b=u.DpiHelper.adjustTextStyle(this.style),S=p.getFont(b),_=Math.abs(g.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(1))-g.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(0))),C=Math.abs(g.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(1))-g.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(0)));if(S.CalculateStringBounds((y=this.getText(0,0))!==null&&y!==void 0?y:"",m,this.getLineSpacing()),g.isVerticalChart&&(v=[_,C],C=v[0],_=v[1]),!!this.shouldGenerate(new o.Size(m.m_fWidth,m.m_fHeight),_,C)){this.colorValue=(0,s.parseColorToUIntArgb)(this.color);for(var P=this.parentSeries.dataSeries,x=P.xStart,E=P.xStep,A=P.yStart,R=P.yStep,M=0;M<this.dataSeries.arrayHeight;M++){var D=A+R*M;if(!(g.yCoordinateCalculator.visibleMin>D+R||g.yCoordinateCalculator.visibleMax<D))for(var F=0;F<this.dataSeries.arrayWidth;F++){var I=x+E*F;if(!(g.xCoordinateCalculator.visibleMin>I+E||g.xCoordinateCalculator.visibleMax<I)){var V=this.getText(F,M);if(V){S.CalculateStringBounds(V??"",m,this.getLineSpacing());var z=new o.Size(m.m_fWidth,m.m_fHeight),G=this.dataSeries.getXValue(F),H=this.dataSeries.getYValue(M),U=this.getPosition(F,M,G,H,z,_,C,g),k=U.position,X=U.rotationCenter,W=U.rotationAngle,Y=m.GetLineBounds(0),te={text:V,position:k,rect:new i.Rect(k.x,k.y-Y.m_fHeight,z.width,z.height),color:this.getColor(F,M,V),dataX:this.dataSeries.getXValue(F),dataY:this.dataSeries.getYValue(M),rotationAngle:W,rotationCenter:X};Y.delete(),this.shouldSkipLabel(F,M,te,_,C)||this.dataLabels.push(te)}}}}}}},h.prototype.toJSON=function(){var p=f.prototype.toJSON.call(this),g={numericFormat:this.numericFormat,precision:this.precision,isEnabled:this.isEnabled};return Object.assign(p.options,g),p},h})(c.BaseDataLabelProvider);return FE.HeatMapDataLabelProvider=d,FE}var BE={},ASe;function Fie(){if(ASe)return BE;ASe=1;var t=BE&&BE.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(BE,"__esModule",{value:!0}),BE.NonUniformHeatMapDataLabelProvider=void 0;var e=$i(),i=Rn(),n=ud(),r=Ac(),o=Ig(),a=Ti(),s=an(),l=Zi(),u=tH(),c=(function(d){t(f,d);function f(){var h=d!==null&&d.apply(this,arguments)||this;return h.type=r.EDataLabelProviderType.NonUniformHeatmap,h.cellSizeThresholdCoefficient=1,h}return f.prototype.getPosition=function(h,p,g,v,y,m,b,S){var _=S.xCoordinateCalculator.getCoordinate(g),C=S.yCoordinateCalculator.getCoordinate(v);if(S.isVerticalChart){var P=_;_=C,C=P}var x=S.isVerticalChart?S.yCoordinateCalculator:S.xCoordinateCalculator,E=S.isVerticalChart?S.xCoordinateCalculator:S.yCoordinateCalculator;return x.hasFlippedCoordinates?_+=(m-y.width)/2:_-=m-(m-y.width)/2,E.hasFlippedCoordinates?C+=b-(b-y.height)/2:C-=(b-y.height)/2,{position:new e.Point(_,C),rotationCenter:new e.Point(_,C),rotationAngle:0}},f.prototype.generateDataLabels=function(h,p){var g;if(this.dataLabels=[],!(!this.style||!this.style.fontFamily||!this.style.fontSize)){this.dataSeries=this.parentSeries.dataSeries,this.zValues=this.dataSeries.getZValues();var v=(0,s.getTextBounds)(this.webAssemblyContext),y=l.DpiHelper.adjustTextStyle(this.style),m=h.getFont(y),b=Math.abs(p.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(this.dataSeries.arrayWidth))-p.xCoordinateCalculator.getCoordinate(this.dataSeries.getXValue(0))),S=Math.abs(p.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(this.dataSeries.arrayHeight))-p.yCoordinateCalculator.getCoordinate(this.dataSeries.getYValue(0))),_=function(ge){return ge};(this.parentSeries.xAxis.type===n.EAxisType.BaseValueAxis||this.parentSeries.xAxis.type===n.EAxisType.DiscontinuousDateAxis)&&(_=function(ge){return p.xCoordinateCalculator.getCoordinate(ge)});var C=this.dataSeries.getXCellSizes(_),P=this.dataSeries.getYCellSizes();m.CalculateStringBounds((g=this.getText(0,0))!==null&&g!==void 0?g:"",v,this.getLineSpacing());var x=v.m_fHeight*this.cellSizeThresholdCoefficient,E=v.m_fWidth*this.cellSizeThresholdCoefficient;this.colorValue=(0,a.parseColorToUIntArgb)(this.color);for(var A=0;A<this.dataSeries.arrayHeight;A++){var R=S*P[A];if(!(R<x)){var M=this.dataSeries.getYValue(A),D=this.dataSeries.yCellOffsets[A+1];if(!(p.yCoordinateCalculator.visibleMin>M||p.yCoordinateCalculator.visibleMax<D))for(var F=0;F<this.dataSeries.arrayWidth;F++){var I=b*C[F];if(!(I<E)){var V=this.dataSeries.getXValue(F),z=this.dataSeries.xCellOffsets[F+1];if(!(p.xCoordinateCalculator.visibleMin>V||p.xCoordinateCalculator.visibleMax<z)){var G=this.getText(F,A);if(G){m.CalculateStringBounds(G??"",v,this.getLineSpacing());var H=new o.Size(v.m_fWidth,v.m_fHeight),U=p.isVerticalChart?R:I,k=p.isVerticalChart?I:R,X=this.getPosition(F,A,V,M,H,U,k,p),W=X.position,Y=X.rotationAngle,te=X.rotationCenter,oe=v.GetLineBounds(0),de={text:G,position:W,rect:new i.Rect(W.x,W.y-oe.m_fHeight,H.width,H.height),color:this.getColor(F,A,G),dataX:V,dataY:M,rotationAngle:Y,rotationCenter:te};oe.delete(),this.shouldSkipLabel(F,A,de,I,R)||this.dataLabels.push(de)}}}}}}}},f})(u.HeatMapDataLabelProvider);return BE.NonUniformHeatMapDataLabelProvider=c,BE}var Ab={},OSe;function HW(){if(OSe)return Ab;OSe=1;var t=Ab&&Ab.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=Ab&&Ab.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(Ab,"__esModule",{value:!0}),Ab.TextDataLabelProvider=void 0;var i=$i(),n=Rn(),r=an(),o=LI(),a=Ac(),s=UI(),l=Tc(),u=(function(c){t(d,c);function d(f){var h=this,p,g,v,y;return h=c.call(this,e(e({},f),{style:e({fontSize:12},f==null?void 0:f.style)}))||this,h.type=a.EDataLabelProviderType.Text,h.calculateTextBounds=!1,h.horizontalTextPositionProperty=l.EHorizontalTextPosition.Right,h.verticalTextPositionProperty=l.EVerticalTextPosition.Above,h.isEnabledProperty=!0,h.calculateTextBounds=(p=f==null?void 0:f.calculateTextBounds)!==null&&p!==void 0?p:h.calculateTextBounds,h.horizontalTextPositionProperty=(g=f==null?void 0:f.horizontalTextPosition)!==null&&g!==void 0?g:h.horizontalTextPosition,h.verticalTextPositionProperty=(v=f==null?void 0:f.verticalTextPosition)!==null&&v!==void 0?v:h.verticalTextPosition,h.isEnabledProperty=(y=f==null?void 0:f.isEnabled)!==null&&y!==void 0?y:h.isEnabledProperty,h}return Object.defineProperty(d.prototype,"horizontalTextPosition",{get:function(){return this.horizontalTextPositionProperty},set:function(f){this.horizontalTextPositionProperty=f,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"verticalTextPosition",{get:function(){return this.verticalTextPositionProperty},set:function(f){this.verticalTextPositionProperty=f,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"isEnabled",{get:function(){return this.isEnabledProperty},set:function(f){this.isEnabledProperty!==f&&(this.isEnabledProperty=f,this.invalidateParent())},enumerable:!1,configurable:!0}),d.prototype.getPosition=function(f,h){var p,g,v,y,m,b,S,_,C=f.xCoord();this.horizontalTextPosition===l.EHorizontalTextPosition.Center?C-=h.m_fWidth/2:this.horizontalTextPosition===l.EHorizontalTextPosition.Left?C-=h.m_fWidth+((g=(p=this.style.padding)===null||p===void 0?void 0:p.right)!==null&&g!==void 0?g:0):C+=(y=(v=this.style.padding)===null||v===void 0?void 0:v.right)!==null&&y!==void 0?y:0;var P=h.GetLineBounds(0),x=h.m_fHeight-P.m_fHeight;P.delete();var E=f.yCoord()-x;return this.verticalTextPosition===l.EVerticalTextPosition.Center?E+=h.m_fHeight/2:this.verticalTextPosition===l.EVerticalTextPosition.Below?E+=h.m_fHeight+((b=(m=this.style.padding)===null||m===void 0?void 0:m.top)!==null&&b!==void 0?b:0):E-=(_=(S=this.style.padding)===null||S===void 0?void 0:S.bottom)!==null&&_!==void 0?_:0,new i.Point(C,E)},d.prototype.getColor=function(f,h){return f.color},d.prototype.getDataLabelState=function(f,h,p,g,v,y){return new s.DataLabelState(f,h,p,g,v,y)},d.prototype.shouldGenerate=function(f){return!0},d.prototype.generateDataLabels=function(f,h){var p;if(this.dataLabels=[],!(!this.isEnabled||!this.style||!this.style.fontFamily||!this.style.fontSize)){var g=this.parentSeries.dataSeries;if(!g||!g.textValues){console.warn("TextDataLabelProvider requires an XyTextDataSeries");return}if(this.state=this.getDataLabelState(f,h,this.style,this.color,h.pointSeries.yValues,this.parentSeries),!!this.shouldGenerate(this.state)){var v=(0,r.getTextBounds)(this.webAssemblyContext),y=this.parentSeries.dataSeries,m=y.fifoCapacity,b=y.fifoSweeping,S=y.fifoSweepingGap,_=y.fifoStartIndex,C=h.pointSeries.indexes,P=this.verticalTextPosition!==l.EVerticalTextPosition.Above||this.horizontalTextPosition!==l.EHorizontalTextPosition.Right||this.calculateTextBounds;if(g){this.state.font.CalculateStringBounds((p=g.getTextValue(0))!==null&&p!==void 0?p:"",v,this.getLineSpacing());for(var x=0;x<C.size();x++){this.state.index=x;var E=C.get(this.state.index);if(!(b&&this.state.pointCount===m&&this.state.index>=_&&this.state.index<_+S)){var A=g.getTextValue(this.state.getIndexInternal(E));P&&this.state.font.CalculateStringBounds(A??"",v,this.getLineSpacing());var R=this.getPosition(this.state,v),M=v.GetLineBounds(0),D=M.m_fHeight;M.delete();var F={text:A,position:R,rect:new n.Rect(R.x,R.y-D,v.m_fWidth,v.m_fHeight),color:this.getColor(this.state,A),dataX:this.state.xCoord(),dataY:this.state.yCoord(),rotationAngle:0,rotationCenter:R};this.dataLabels.push(F)}}}this.onAfterGenerate(this.dataLabels)}}},d.prototype.onAfterGenerate=function(f){},d.prototype.toJSON=function(){var f=c.prototype.toJSON.call(this),h={calculateTextBounds:this.calculateTextBounds,horizontalTextPosition:this.horizontalTextPosition,verticalTextPosition:this.verticalTextPosition,isEnabled:this.isEnabled};return Object.assign(f.options,h),f},d})(o.BaseDataLabelProvider);return Ab.TextDataLabelProvider=u,Ab}var jE={},VE={},HE={},DSe;function hR(){if(DSe)return HE;DSe=1;var t=HE&&HE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(HE,"__esModule",{value:!0}),HE.XyyPointSeriesResampled=void 0;var e=Yo(),i=zi(),n=jI(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l,2,[e.EValueName.Y,e.EValueName.Y1])||this;return u.type=i.EDataSeriesType.Xyy,u}return Object.defineProperty(a.prototype,"y1Values",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),a.prototype.debugOutputForUnitTests=function(){console.log("points count ".concat(this.count)),console.log("xResampled at min",this.xValues.get(0)),console.log("yValues at min",this.yValues.get(0)),console.log("y1Values at min",this.y1Values.get(0));var s=Math.round(this.count/2);console.log("middle",s),console.log("xResampled at middle",this.xValues.get(s)),console.log("yValues at middle",this.yValues.get(s)),console.log("y1Values at middle",this.y1Values.get(s));var l=this.count-1;console.log("xResampled at end",this.xValues.get(l)),console.log("yValues at end",this.yValues.get(l)),console.log("y1Values at end",this.y1Values.get(l))},a})(n.BasePointSeriesResampled);return HE.XyyPointSeriesResampled=r,HE}var UE={},RSe;function Bie(){if(RSe)return UE;RSe=1;var t=UE&&UE.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(UE,"__esModule",{value:!0}),UE.BandSeriesDrawingProvider=void 0;var e=Br(),i=tu(),n=Ls(),r=Iu(),o=Sn(),a=un(),s=du(),l=(function(u){t(c,u);function c(d,f,h,p){var g=u.call(this,d,f,h)||this;return g.args=new g.webAssemblyContext.SCRTBandDrawingParams,g.y1Selector=p??(function(v){return v.y1Values}),g.linesPenCache=new n.Pen2DCache(d),g.strokePenY1Cache=new n.Pen2DCache(d),g.fillBrushCache=new i.BrushCache(d),g.fillBrushY1Cache=new i.BrushCache(d),g}return c.prototype.onAttachSeries=function(){u.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTBandSeriesDrawingProvider;var d=this.parentSeries,f=d.parentSurface,h=d.stroke,p=d.strokeThickness,g=d.strokeY1Thickness,v=d.fill,y=d.strokeY1,m=d.fillY1,b=d.opacity,S=d.strokeDashArray,_=d.strokeY1DashArray,C=d.fillLinearGradient,P=d.fillLinearGradientY1,x=d.customTextureOptions,E=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.height/o.SciChartSurfaceBase.domMasterCanvas.height:1,A=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.width/o.SciChartSurfaceBase.domMasterCanvas.width:1;(0,n.createPenInCache)(this.linesPenCache,h,p,b,S),(0,n.createPenInCache)(this.strokePenY1Cache,y,g,b,_),this.fillBrushCache.create(v,b,E,A,C,x),this.fillBrushY1Cache.create(m,b,E,A,P,x)},c.prototype.onDetachSeries=function(){u.prototype.onDetachSeries.call(this),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider)},c.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.linesPenCache=(0,e.deleteSafe)(this.linesPenCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),this.strokePenY1Cache=(0,e.deleteSafe)(this.strokePenY1Cache),this.fillBrushY1Cache=(0,e.deleteSafe)(this.fillBrushY1Cache),u.prototype.delete.call(this)},c.prototype.draw=function(d,f){var h,p=f.pointSeries,g=this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN;this.args.Reset(),this.args.forceShaderMethod=!0,this.args.verticalChart=f.isVerticalChart,this.args.lineGaps=g?this.parentSeries.drawNaNAs===r.ELineDrawMode.DiscontinuousLine?this.webAssemblyContext.SCRTLineGapMode.DrawGaps:this.webAssemblyContext.SCRTLineGapMode.CloseGaps:this.webAssemblyContext.SCRTLineGapMode.Default,this.args.isDigitalLine=this.parentSeries.isDigitalLine;var v=(0,i.getScrtBrushFromCache)(this.fillBrushCache);v&&this.args.SetFillBrush(v);var y=(0,n.getScrtPenFromCache)(this.linesPenCache);y&&this.args.SetLinesPen(y);var m=(0,i.getScrtBrushFromCache)(this.fillBrushY1Cache);m&&this.args.SetFillBrush1(m);var b=(0,n.getScrtPenFromCache)(this.strokePenY1Cache);b&&this.args.SetLinesPen1(b);var S=f.xCoordinateCalculator.isCategoryCoordinateCalculator,_=p.xValues,C=this.parentSeries.dataSeries,P=C.fifoCapacity,x=C.fifoSweeping,E=C.fifoSweepingGap,A=p.fifoStartIndex,R=S?p.indexes:_,M=this.ySelector(p),D=this.y1Selector(p),F=this.getStartAndCount(f,R),I=F.startIndex,V=F.count;this.args.count=V,this.args.startIndex=I,P>0&&x&&P===this.parentSeries.dataSeries.count()&&(this.args.count=A),u.prototype.applyStrokeFillPaletting.call(this,void 0,void 0,void 0,void 0,this.parentSeries.opacity,!0,!0,f);var z=(h=this.palettingState.paletteTextureCache)===null||h===void 0?void 0:h.value;z&&this.args.SetPalette(z),this.args.isSmoothColors=this.palettingState.gradientPaletting;var G=d.getNativeContext();this.args.SetNativeContext(G),this.args.SetXValues(R),this.args.SetYValues(M),this.args.SetZValues(D),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args),P>0&&x&&P===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(M.size(),A+E),this.args.count=Math.max(0,M.size()-A-E),this.args.count>0&&this.nativeDrawingProvider.DrawPointsVec(this.args))},c.prototype.onDpiChanged=function(d){u.prototype.onDpiChanged.call(this,d),this.onSeriesPropertyChange(a.PROPERTY.STROKE),this.onSeriesPropertyChange(a.PROPERTY.STROKE_Y1)},c.prototype.onSeriesPropertyChange=function(d){u.prototype.onSeriesPropertyChange.call(this,d);var f=this.parentSeries,h=f.parentSurface,p=f.stroke,g=f.strokeY1,v=f.strokeThickness,y=f.strokeY1Thickness,m=f.fill,b=f.fillY1,S=f.opacity,_=f.strokeDashArray,C=f.strokeY1DashArray,P=f.fillLinearGradient,x=f.fillLinearGradientY1,E=f.customTextureOptions;if(d===a.PROPERTY.STROKE||d===a.PROPERTY.STROKE_THICKNESS||d===a.PROPERTY.OPACITY||d===a.PROPERTY.STROKE_DASH_ARRAY){this.palettingState.requiresUpdate=!0,(0,n.createPenInCache)(this.linesPenCache,p,v,S,_);return}if(d===a.PROPERTY.STROKE_Y1||d===a.PROPERTY.STROKE_THICKNESS||d===a.PROPERTY.OPACITY||d===a.PROPERTY.STROKE_Y1_DASH_ARRAY||d===a.PROPERTY.STROKE_THICKNESS_Y1){this.palettingState.requiresUpdate=!0,(0,n.createPenInCache)(this.strokePenY1Cache,g,y,S,C);return}var A=h!=null&&h.isCopyCanvasSurface?h.domCanvas2D.height/o.SciChartSurfaceBase.domMasterCanvas.height:1,R=h!=null&&h.isCopyCanvasSurface?h.domCanvas2D.width/o.SciChartSurfaceBase.domMasterCanvas.width:1;(d===a.PROPERTY.FILL||d===a.PROPERTY.OPACITY||d===a.PROPERTY.FILL_LINEAR_GRADIENT||d==a.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&(this.palettingState.requiresUpdate=!0,this.fillBrushCache.create(m,S,A,R,P,E)),(d===a.PROPERTY.FILL_Y1||d===a.PROPERTY.OPACITY||d===a.PROPERTY.FILL_LINEAR_GRADIENT_Y1||d==a.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&(this.palettingState.requiresUpdate=!0,this.fillBrushY1Cache.create(b,S,A,R,x,E))},c})(s.BaseSeriesDrawingProvider);return UE.BandSeriesDrawingProvider=l,UE}var zE={},MSe;function Yf(){if(MSe)return zE;MSe=1;var t=zE&&zE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(zE,"__esModule",{value:!0}),zE.PointMarkerDrawingProvider=void 0;var e=Br(),i=du(),n=(function(r){t(o,r);function o(a,s,l,u,c){var d=r.call(this,a,s,l,c)||this;return d.ySplineValuesSelector=u===void 0?function(f){return f.ySplineValues}:u,d.nativeDrawingProvider=new d.webAssemblyContext.SCRTScatterSeriesDrawingProvider,d.xAnimationPointMarkerValues=new d.webAssemblyContext.SCRTDoubleVector,d.yAnimationPointMarkerValues=new d.webAssemblyContext.SCRTDoubleVector,d.args=new d.webAssemblyContext.SCRTPointDrawingParams,d}return o.prototype.onSeriesPropertyChange=function(a){},o.prototype.getProperties=function(a){return a},o.prototype.draw=function(a,s){var l,u,c=(l=this.getProperties(this.parentSeries))===null||l===void 0?void 0:l.pointMarker;if(c!==void 0){var d,f;this.parentSeries.hasPointMarkerPaletteProvider()?(d=c.getFillMask(),f=c.getStrokeMask()):(d=c.getSprite(),f=void 0);var h=s.pointSeries,p=s.xCoordinateCalculator.isCategoryCoordinateCalculator,g=this.xSelector(h),v=this.ySelector(h);this.args.Reset(),this.args.verticalChart=s.isVerticalChart,this.args.forceShaderMethod=!0,this.args.usePointSampling=!c.antiAlias,this.args.SetSpriteTexture(d.getTexture()),f&&this.args.SetStrokeMask(f.getTexture());var y=this.parentSeries.dataSeries,m=y.fifoCapacity,b=y.fifoSweeping,S=y.fifoSweepingGap,_=h.fifoStartIndex;if(c.lastPointOnly&&v.size()>0)this.args.count=1,this.args.startIndex=b&&this.parentSeries.dataSeries.count()===m?_-1:v.size()-1;else{var C=this.getStartAndCount(s,g),P=C.startIndex,x=C.count;this.args.count=x,this.args.startIndex=P,b&&m===this.parentSeries.dataSeries.count()&&(this.args.count=_)}this.applyStrokeFillPaletting(c.stroke,void 0,c.fill,void 0,this.parentSeries.opacity),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=(u=this.palettingState.paletteStartIndex)!==null&&u!==void 0?u:0,this.updateArgs(s);var E=a.getNativeContext();this.drawPoints(E,p?h.indexes:g,v,s.xCoordinateCalculator.nativeCalculator,s.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect),b&&m===this.parentSeries.dataSeries.count()&&!c.lastPointOnly&&(this.args.startIndex=Math.min(v.size(),_+S),this.args.count=Math.max(0,v.size()-_-S),this.args.count>0&&this.drawPoints(E,p?h.indexes:g,v,s.xCoordinateCalculator.nativeCalculator,s.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect))}},o.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.xAnimationPointMarkerValues=(0,e.deleteSafe)(this.xAnimationPointMarkerValues),this.yAnimationPointMarkerValues=(0,e.deleteSafe)(this.yAnimationPointMarkerValues),this.args=(0,e.deleteSafe)(this.args),r.prototype.delete.call(this)},o.prototype.overridePaletteProviderColors=function(a,s,l,u,c,d,f){if(a.hasPointMarkerPaletteProvider()){var h=a.paletteProvider,p=h.overridePointMarkerArgb(s,l,u,c,d,f);if(p)return p}return{stroke:void 0,fill:void 0}},o.prototype.isGradientFillPaletting=function(a){return!1},o.prototype.drawPoints=function(a,s,l,u,c,d,f){d.SetNativeContext(a),d.SetXValues(s),d.SetYValues(l),d.SetXCoordinateCalculator(u),d.SetYCoordinateCalculator(c),this.nativeDrawingProvider.DrawPointsVec(d)},o})(i.BaseSeriesDrawingProvider);return zE.PointMarkerDrawingProvider=n,zE}var $E={},LSe;function Oje(){if(LSe)return $E;LSe=1;var t=$E&&$E.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty($E,"__esModule",{value:!0}),$E.BandSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=v.getNativeYValues(),S=v.getNativeY1Values(),_=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0);if(v.dataDistributionCalculator.isSortedAscending&&y>=0){_.y1Value=S.get(y),_.y1Coord=f.getCoordinate(_.y1Value);var C=i.hitTestHelpers.testIsHitForBand(this.parentSeries.isDigitalLine,d,f,v.getNativeXValues(),function(x){return b.get(x)},function(x){return S.get(x)},y,p,g,v);if(_.isHit=C.isHit,_.point2dataSeriesIndex=C.secondPointIndex,C.secondPointIndex!==void 0){_.point2xValue=m.get(C.secondPointIndex),_.point2xCoord=d.getCoordinate(_.point2xValue),_.point2yValue=b.get(C.secondPointIndex),_.point2yCoord=f.getCoordinate(_.point2yValue),_.point2y1Value=S.get(C.secondPointIndex),_.point2y1Coord=f.getCoordinate(_.point2y1Value),_.point2metadata=v.getMetadataAt(C.secondPointIndex);var P=v.valueNames.reduce(function(x,E){return x[E]=v.getNativeValue(v.getYValuesByName(E),_.point2dataSeriesIndex),x},{});_.point2yValueByName=P}}else _.isHit=!1;return _},a.prototype.hitTestDataPoint=function(s,l,u){u===void 0&&(u=e.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var c=this.getTranslatedHitTestPoint(s,l);if(!c)return n.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return n.HitTestInfo.empty();var m=i.hitTestHelpers.getNearestXyyPoint(this.webAssemblyContext,f,h,y,g,v,u),b=m.nearestPointIndex,S=m.distance,_=i.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,y.getNativeXValues(),y.getNativeYValues(),g,v,b,u,S);return b>=0?(_.y1Value=y.getNativeY1Values().get(b),_.y1Coord=h.getCoordinate(_.y1Value),_.isHit=i.hitTestHelpers.testIsHitForPoint(f,h,y.getNativeXValues(),y.getNativeYValues(),b,g,v,u,y)||i.hitTestHelpers.testIsHitForPoint(f,h,y.getNativeXValues(),y.getNativeY1Values(),b,g,v,u,y)):_.isHit=!1,_},a.prototype.hitTestXSlice=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=v.getNativeYValues(),S=v.getNativeY1Values(),_=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0);if(y>=0?(_.isHit=_.isWithinDataBounds,_.y1Value=S.get(y),_.y1Coord=f.getCoordinate(_.y1Value)):_.isHit=!1,v.dataDistributionCalculator.isSortedAscending&&y>=0){var C=m.size(),P=d.getCoordinate(d.isCategoryCoordinateCalculator?y:m.get(y));if(!(y===C-1&&(d.hasFlippedCoordinates?p>=P:p<=P))&&!(y===0&&(d.hasFlippedCoordinates?p<=P:p>=P))){var x=i.hitTestHelpers.testIsHitForLine(d,f,m,b,y,p,g,0,v);if(_.point2dataSeriesIndex=x.secondPointIndex,x.secondPointIndex!==void 0){_.point2xValue=m.get(x.secondPointIndex),_.point2xCoord=d.getCoordinate(_.point2xValue),_.point2yValue=b.get(x.secondPointIndex),_.point2yCoord=f.getCoordinate(_.point2yValue),_.point2y1Value=S.get(x.secondPointIndex),_.point2y1Coord=f.getCoordinate(_.point2y1Value),_.point2metadata=v.getMetadataAt(x.secondPointIndex);var E=v.valueNames.reduce(function(A,R){return A[R]=v.getNativeValue(v.getYValuesByName(R),_.point2dataSeriesIndex),A},{});_.point2yValueByName=E}}}return _},a})(e.BaseHitTestProvider);return $E.BandSeriesHitTestProvider=r,$E}var kSe;function UW(){if(kSe)return VE;kSe=1;var t=VE&&VE.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(VE,"__esModule",{value:!0}),VE.BaseBandRenderableSeries=void 0;var e=Br(),i=di(),n=Bu(),r=zi(),o=hR(),a=KV(),s=W3(),l=Xs(),u=Sn(),c=ju(),d=un(),f=kie(),h=Bie(),p=Yf(),g=Oje(),v=(function(y){t(m,y);function m(b,S){var _=this,C,P,x,E;return _=y.call(this,b,S)||this,_.stroke=(C=S==null?void 0:S.stroke)!==null&&C!==void 0?C:u.SciChartSurfaceBase.DEFAULT_THEME.downBandSeriesLineColor,_.strokeY1Property=(P=S==null?void 0:S.strokeY1)!==null&&P!==void 0?P:u.SciChartSurfaceBase.DEFAULT_THEME.upBandSeriesLineColor,_.fillProperty=(x=S==null?void 0:S.fill)!==null&&x!==void 0?x:u.SciChartSurfaceBase.DEFAULT_THEME.upBandSeriesFillColor,_.fillY1Property=(E=S==null?void 0:S.fillY1)!==null&&E!==void 0?E:u.SciChartSurfaceBase.DEFAULT_THEME.downBandSeriesFillColor,_.fillLinearGradient=S==null?void 0:S.fillLinearGradient,_.fillLinearGradientY1=S==null?void 0:S.fillLinearGradientY1,_.strokeY1DashArrayProperty=S==null?void 0:S.strokeY1DashArray,_.strokeDashArrayProperty=S==null?void 0:S.strokeDashArray,_.customTextureOptionsProperty=S==null?void 0:S.customTextureOptions,_.dataLabelProviderProperty||(_.dataLabelProviderProperty=new f.BandSeriesDataLabelProvider(S==null?void 0:S.dataLabels),_.dataLabelProviderProperty.onAttach(_.webAssemblyContext,_)),S!=null&&S.animation&&_.animationQueue.push(S.animation),_}return m.prototype.addDrawingProviders=function(b,S){this.drawingProviders.push(new h.BandSeriesDrawingProvider(b,this)),this.drawingProviders.push(new p.PointMarkerDrawingProvider(b,this)),this.drawingProviders.push(new p.PointMarkerDrawingProvider(b,this,function(_){return _.y1Values},function(_){return _.y1SplineValues}))},m.prototype.applyTheme=function(b){y.prototype.applyTheme.call(this,b);var S=this.parentSurface.previousThemeProvider;this.stroke===S.downBandSeriesLineColor&&(this.stroke=b.downBandSeriesLineColor),this.strokeY1===S.upBandSeriesLineColor&&(this.strokeY1=b.upBandSeriesLineColor),this.fill===S.upBandSeriesFillColor&&(this.fill=b.upBandSeriesFillColor),this.fillY1===S.downBandSeriesFillColor&&(this.fillY1=b.downBandSeriesFillColor)},Object.defineProperty(m.prototype,"fill",{get:function(){return(0,l.stripAutoColor)(this.fillProperty)},set:function(b){this.fillProperty!==b&&(this.fillProperty=b,this.notifyPropertyChanged(d.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeY1",{get:function(){return(0,l.stripAutoColor)(this.strokeY1Property)},set:function(b){this.strokeY1Property!==b&&(this.strokeY1Property=b,this.notifyPropertyChanged(d.PROPERTY.STROKE_Y1))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fillY1",{get:function(){return(0,l.stripAutoColor)(this.fillY1Property)},set:function(b){this.fillY1Property!==b&&(this.fillY1Property=b,this.notifyPropertyChanged(d.PROPERTY.FILL_Y1))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(b){this.strokeDashArrayProperty=b,this.notifyPropertyChanged(d.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeY1DashArray",{get:function(){return this.strokeY1DashArrayProperty},set:function(b){this.strokeY1DashArrayProperty=b,this.notifyPropertyChanged(d.PROPERTY.STROKE_Y1_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeY1Thickness",{get:function(){var b;return(b=this.strokeY1ThicknessProperty)!==null&&b!==void 0?b:this.strokeThickness},set:function(b){this.strokeY1ThicknessProperty!==b&&(this.strokeY1ThicknessProperty=b,this.notifyPropertyChanged(d.PROPERTY.STROKE_THICKNESS_Y1))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(b){b!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=b,this.notifyPropertyChanged(d.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(b){b!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=b,this.notifyPropertyChanged(d.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fillLinearGradientY1",{get:function(){return this.fillLinearGradientY1Property},set:function(b){b!==this.fillLinearGradientY1Property&&(this.fillLinearGradientY1Property=b,this.notifyPropertyChanged(d.PROPERTY.FILL_LINEAR_GRADIENT_Y1))},enumerable:!1,configurable:!0}),m.prototype.getNativeY1Values=function(){return this.dataSeries.getNativeY1Values()},m.prototype.delete=function(){this.xyyTempPointSeries=(0,e.deleteSafe)(this.xyyTempPointSeries),y.prototype.delete.call(this)},m.prototype.toPointSeries=function(b){if(b){this.xyyTempPointSeries?this.xyyTempPointSeries.xRange=b.xVisibleRange:this.xyyTempPointSeries=new o.XyyPointSeriesResampled(this.webAssemblyContext,b.xVisibleRange),this.pointSeries?this.pointSeries.xRange=b.xVisibleRange:this.pointSeries=new o.XyyPointSeriesResampled(this.webAssemblyContext,b.xVisibleRange);var S=this.pointSeries,_=this.dataSeries,C=_.getNativeXValues(),P=_.getNativeYValues(),x=_.getNativeY1Values(),E=this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext,b,C,P,this.xyyTempPointSeries.intIndexes,void 0,this.xyyTempPointSeries.xValues,this.xyyTempPointSeries.yValues,!1);this.pointSeries.fifoStartIndex=E.OutputSplitIndex;var A=this.xyyTempPointSeries.intIndexes.size();this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext,b,C,x,this.xyyTempPointSeries.intIndexes,void 0,this.xyyTempPointSeries.xValues,this.xyyTempPointSeries.y1Values);var R=this.xyyTempPointSeries.intIndexes.size()-A,M=this.resamplerHelper.mergeIndexes(this.xyyTempPointSeries.intIndexes,A,R,S.intIndexes);return this.xyyTempPointSeries.intIndexes.clear(),b.dataIsFifo?S.indexes.resizeFast(M):S.indexes.resizeFast(M+1),this.resamplerHelper.copyValuesByIndexes(S.intIndexes,C,P,x,M,b.isCategoryAxis,this.dataSeries.fifoSweeping,S.indexes,S.xValues,S.yValues,S.y1Values),S.clearIntIndexes(),S}else return new a.XyyPointSeriesWrapped(this.dataSeries)},m.prototype.getYRange=function(b,S){S===void 0&&(S=!1);var _=this.isRunningDataAnimation?r.EDataSeriesValueType.FinalAnimationValues:r.EDataSeriesValueType.Default,C=this.getResampledPointSeries(S);if(this.renderDataTransform&&this.renderDataTransform.useForYRange)return this.updateTransformedValues(_),(0,n.getWindowedYRange)(this.webAssemblyContext,this.transformedRenderPassData.pointSeries.xValues,this.transformedRenderPassData.pointSeries.yValues,b,!0,S,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.dataSeries.dataDistributionCalculator.containsNaN);if(C){var P=C,x=P.yValues,E=P.y1Values,A=new i.NumberRange(0,C.count-1);return(0,s.getYyYRange)(this.webAssemblyContext,A,x,E,this.dataSeries.dataDistributionCalculator.containsNaN)}return this.dataSeries.getWindowedYRange(b,!0,S,_,this.yRangeMode)},m.prototype.toJSON=function(b){b===void 0&&(b=!1);var S=y.prototype.toJSON.call(this,b),_={fill:this.fill,fillY1:this.fillY1,strokeDashArray:this.strokeDashArray,strokeY1:this.strokeY1,strokeY1DashArray:this.strokeY1DashArray};return Object.assign(S.options,_),S},m.prototype.resolveAutoColors=function(b,S,_){if(y.prototype.resolveAutoColors.call(this,b,S,_),this.fillProperty.startsWith(l.AUTO_COLOR)){var C=_.getFillColor(b,S,this.webAssemblyContext);this.fill=l.AUTO_COLOR+this.adjustAutoColor("fill",C)}var P=(b+Math.floor(S/2))%S;if(this.strokeY1Property.startsWith(l.AUTO_COLOR)){var C=_.getStrokeColor(P,S,this.webAssemblyContext);this.strokeY1=l.AUTO_COLOR+this.adjustAutoColor("strokeY1",C)}if(this.fillY1Property.startsWith(l.AUTO_COLOR)){var C=_.getFillColor(P,S,this.webAssemblyContext);this.fillY1=l.AUTO_COLOR+this.adjustAutoColor("fillY1",C)}},m.prototype.newHitTestProvider=function(){return new g.BandSeriesHitTestProvider(this,this.webAssemblyContext)},m})(c.BaseRenderableSeries);return VE.BaseBandRenderableSeries=v,VE}var ISe;function Dje(){if(ISe)return jE;ISe=1;var t=jE&&jE.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(jE,"__esModule",{value:!0}),jE.FastBandRenderableSeries=void 0;var e=hn(),i=UW(),n=(function(r){t(o,r);function o(a,s){var l=this,u,c;return l=r.call(this,a,s)||this,l.type=e.ESeriesType.BandSeries,!((u=l.paletteProvider)===null||u===void 0)&&u.onAttached&&((c=l.paletteProvider)===null||c===void 0||c.onAttached(l)),l}return o})(i.BaseBandRenderableSeries);return jE.FastBandRenderableSeries=n,jE}var WE={},GE={},NSe;function Rje(){if(NSe)return GE;NSe=1;var t=GE&&GE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(GE,"__esModule",{value:!0}),GE.XyzPointSeriesWrapped=void 0;var e=Yo(),i=zi(),n=wm(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s,void 0,i.EDataSeriesValueType.Default,[e.EValueName.Y,e.EValueName.Z])||this;return l.type=i.EDataSeriesType.Xyz,l}return Object.defineProperty(a.prototype,"zValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),a.prototype.getYValues=function(s){return s===1?this.zValues:this.yValues},a})(n.BasePointSeriesWrapped);return GE.XyzPointSeriesWrapped=r,GE}var YE={},FSe;function Mje(){if(FSe)return YE;FSe=1;var t=YE&&YE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(YE,"__esModule",{value:!0}),YE.BubbleSeriesDrawingProvider=void 0;var e=Br(),i=Zi(),n=du(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.nativeDrawingProvider=new u.webAssemblyContext.SCRTBubbleSeriesDrawingProvider,u.args=new u.webAssemblyContext.SCRTPointDrawingParams,u}return a.prototype.onSeriesPropertyChange=function(s){},a.prototype.draw=function(s,l){var u,c=this.parentSeries.pointMarker;if(c!==void 0){var d=c.getSprite(),f=l.pointSeries,h=l.xCoordinateCalculator.isCategoryCoordinateCalculator;this.args.Reset();var p=f.xValues,g=f.yValues,v=f.zValues,y=this.getStartAndCount(l,p),m=y.startIndex,b=y.count;this.args.count=b,this.args.startIndex=m;var S=this.parentSeries.dataSeries,_=S.fifoCapacity,C=S.fifoSweeping,P=S.fifoSweepingGap,x=f.fifoStartIndex;C&&_===this.parentSeries.dataSeries.count()&&(this.args.count=x),this.args.verticalChart=l.isVerticalChart,this.args.forceShaderMethod=!0,this.args.SetSpriteTexture(d.getTexture()),o.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,void 0,void 0,void 0,this.parentSeries.opacity),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=(u=this.palettingState.paletteStartIndex)!==null&&u!==void 0?u:0,this.args.zMultiplier=this.parentSeries.zMultiplier*i.DpiHelper.PIXEL_RATIO;var E=h?f.indexes:p,A=s.getNativeContext();this.drawPoints(A,E,g,v,l.xCoordinateCalculator.nativeCalculator,l.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect),C&&_===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(g.size(),x+P),this.args.count=Math.max(0,g.size()-x-P),this.args.count>0&&this.drawPoints(A,E,g,v,l.xCoordinateCalculator.nativeCalculator,l.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect))}},a.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),o.prototype.delete.call(this)},a.prototype.overridePaletteProviderColors=function(s,l,u,c,d,f,h){if(s.hasPointMarkerPaletteProvider()){var p=s.paletteProvider,g=p.overridePointMarkerArgb(l,u,c,d,f,h);if(g)return g}return{stroke:void 0,fill:void 0}},a.prototype.isGradientFillPaletting=function(s){return!1},a.prototype.drawPoints=function(s,l,u,c,d,f,h,p){h.SetNativeContext(s),h.SetXValues(l),h.SetYValues(u),h.SetZValues(c),h.SetXCoordinateCalculator(d),h.SetYCoordinateCalculator(f),this.nativeDrawingProvider.DrawPointsVec(h)},a})(n.BaseSeriesDrawingProvider);return YE.BubbleSeriesDrawingProvider=r,YE}var qE={},BSe;function Lje(){if(BSe)return qE;BSe=1;var t=qE&&qE.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(qE,"__esModule",{value:!0}),qE.BubbleSeriesHitTestProvider=void 0;var e=Eo(),i=Zi(),n=Vl(),r=vl(),o=tl(),a=(function(s){t(l,s);function l(){return s!==null&&s.apply(this,arguments)||this}return l.prototype.hitTest=function(u,c,d){d===void 0&&(d=0);var f=this.getTranslatedHitTestPoint(u,c);if(!f)return o.HitTestInfo.empty();var h=this.currentRenderPassData,p=h.xCoordinateCalculator,g=h.yCoordinateCalculator,v=h.isVerticalChart,y=v?f.y:f.x,m=v?f.x:f.y,b=this.parentSeries.dataSeries;if(!b)return o.HitTestInfo.empty();var S=r.hitTestHelpers.getNearestXyPoint(this.webAssemblyContext,p,g,b,y,m,d),_=b.getNativeXValues(),C=b.getNativeYValues(),P=b.getNativeZValues(),x=r.hitTestHelpers.createHitTestInfo(this.parentSeries,p,g,v,b,_,C,y,m,S.nearestPointIndex,d);if(S.nearestPointIndex>=0){x.zValue=P.get(S.nearestPointIndex);var E=(0,e.calcDistance)(y,m,x.xCoord,x.yCoord);x.isHit=E<x.zValue*i.DpiHelper.PIXEL_RATIO/2+d;var A=p.isCategoryCoordinateCalculator,R=A?0:_.get(0),M=p.getCoordinate(R),D=b.getNativeZValues().get(0)/2,F=A?_.size()-1:_.get(_.size()-1),I=p.getCoordinate(F),V=b.getNativeZValues().get(_.size()-1)/2;M<I?x.isWithinDataBounds=M-D<=x.hitTestPoint.x&&x.hitTestPoint.x<=I+V:x.isWithinDataBounds=I-V<=x.hitTestPoint.x&&x.hitTestPoint.x<=M+D}else x.isHit=!1;return x},l.prototype.hitTestDataPoint=function(u,c,d){return d===void 0&&(d=n.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(u,c,d)},l.prototype.hitTestXSlice=function(u,c){var d=this.getTranslatedHitTestPoint(u,c);if(!d)return o.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries;if(!m)return o.HitTestInfo.empty();var b=m.getNativeXValues(),S=m.getNativeYValues(),_=m.getNativeZValues(),C=r.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,h,m,v,m.dataDistributionCalculator.isSortedAscending),P=r.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,m,b,S,v,y,C,0);if(C>=0){P.zValue=_.get(C);var x=h.isCategoryCoordinateCalculator,E=x?0:b.get(0),A=h.getCoordinate(E),R=m.getNativeZValues().get(0)/2,M=x?b.size()-1:b.get(b.size()-1),D=h.getCoordinate(M),F=m.getNativeZValues().get(b.size()-1)/2;A<D?P.isWithinDataBounds=A-R<=P.hitTestPoint.x&&P.hitTestPoint.x<=D+F:P.isWithinDataBounds=D-F<=P.hitTestPoint.x&&P.hitTestPoint.x<=A+R,P.isHit=P.isWithinDataBounds}else P.isHit=!1;return P},l})(n.BaseHitTestProvider);return qE.BubbleSeriesHitTestProvider=a,qE}var jSe;function kje(){if(jSe)return WE;jSe=1;var t=WE&&WE.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(WE,"__esModule",{value:!0}),WE.FastBubbleRenderableSeries=void 0;var e=hn(),i=Rje(),n=MI(),r=ju(),o=Mje(),a=Lje(),s=Iie(),l=un(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y;return p=c.call(this,f,h)||this,p.type=e.ESeriesType.BubbleSeries,p.zMultiplierProperty=1,p.zMultiplierProperty=(g=h==null?void 0:h.zMultiplier)!==null&&g!==void 0?g:p.zMultiplierProperty,p.pointMarker||(p.pointMarker=new n.EllipsePointMarker(f,{width:64,height:64})),!((v=p.paletteProvider)===null||v===void 0)&&v.onAttached&&((y=p.paletteProvider)===null||y===void 0||y.onAttached(p)),p.drawingProviders=[],p.drawingProviders.push(new o.BubbleSeriesDrawingProvider(f,p)),p.dataLabelProviderProperty||(p.dataLabelProviderProperty=new s.BubbleSeriesDataLabelProvider(h==null?void 0:h.dataLabels),p.dataLabelProviderProperty.onAttach(p.webAssemblyContext,p)),h!=null&&h.animation&&p.animationQueue.push(h.animation),p}return Object.defineProperty(d.prototype,"paletteProvider",{get:function(){return this.paletteProviderProperty},set:function(f){this.setPaletteProvider(f)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"zMultiplier",{get:function(){return this.zMultiplierProperty},set:function(f){this.zMultiplierProperty=f,this.notifyPropertyChanged(l.PROPERTY.Z_MULTIPLIER)},enumerable:!1,configurable:!0}),d.prototype.applyTheme=function(f){c.prototype.applyTheme.call(this,f);var h=this.parentSurface.previousThemeProvider;this.stroke===h.lineSeriesColor&&(this.stroke=f.lineSeriesColor)},d.prototype.getBubbleDiameter=function(f){return this.dataSeries.getNativeZValues().get(f)},d.prototype.getNativeZValues=function(){return this.dataSeries.getNativeZValues()},d.prototype.toPointSeries=function(f){return new i.XyzPointSeriesWrapped(this.dataSeries)},d.prototype.newHitTestProvider=function(){return new a.BubbleSeriesHitTestProvider(this,this.webAssemblyContext)},d.prototype.toJSON=function(f){f===void 0&&(f=!1);var h=c.prototype.toJSON.call(this,f),p={zMultiplier:this.zMultiplier};return Object.assign(h.options,p),h},d})(r.BaseRenderableSeries);return WE.FastBubbleRenderableSeries=u,WE}var XE={},KE={},ZE={},VSe;function jie(){if(VSe)return ZE;VSe=1;var t=ZE&&ZE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(ZE,"__esModule",{value:!0}),ZE.OhlcPointSeriesResampled=void 0;var e=Yo(),i=zi(),n=jI(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l,4,[e.EValueName.Close,e.EValueName.Open,e.EValueName.High,e.EValueName.Low])||this;return u.type=i.EDataSeriesType.Ohlc,u}return Object.defineProperty(a.prototype,"closeValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"openValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"highValues",{get:function(){return this.yValuesArray[2]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowValues",{get:function(){return this.yValuesArray[3]},enumerable:!1,configurable:!0}),a.prototype.debugOutputForUnitTests=function(){console.log("points count ".concat(this.count)),console.log("xResampled at min",this.xValues.get(0)),console.log("openResampled at min",this.openValues.get(0)),console.log("highResampled at min",this.highValues.get(0)),console.log("lowResampled at min",this.lowValues.get(0)),console.log("closeResampled at min",this.closeValues.get(0));var s=Math.round(this.count/2);console.log("middle",s),console.log("xResampled at middle",this.xValues.get(s)),console.log("openResampled at middle",this.openValues.get(s)),console.log("highResampled at middle",this.highValues.get(s)),console.log("lowResampled at middle",this.lowValues.get(s)),console.log("closeResampled at middle",this.closeValues.get(s));var l=this.count-1;console.log("xResampled at end",this.xValues.get(l)),console.log("openResampled at end",this.openValues.get(l)),console.log("highResampled at end",this.highValues.get(l)),console.log("lowResampled at end",this.lowValues.get(l)),console.log("closeResampled at end",this.closeValues.get(l))},a})(n.BasePointSeriesResampled);return ZE.OhlcPointSeriesResampled=r,ZE}var JE={},HSe;function Ije(){if(HSe)return JE;HSe=1;var t=JE&&JE.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(JE,"__esModule",{value:!0}),JE.OhlcPointSeriesWrapped=void 0;var e=Yo(),i=zi(),n=wm(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s,void 0,i.EDataSeriesValueType.Default,[e.EValueName.Close,e.EValueName.Open,e.EValueName.High,e.EValueName.Low])||this;return l.type=i.EDataSeriesType.Ohlc,l}return Object.defineProperty(a.prototype,"closeValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"openValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"highValues",{get:function(){return this.yValuesArray[2]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowValues",{get:function(){return this.yValuesArray[3]},enumerable:!1,configurable:!0}),a})(n.BasePointSeriesWrapped);return JE.OhlcPointSeriesWrapped=r,JE}var QE={},USe;function Nje(){if(USe)return QE;USe=1;var t=QE&&QE.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(QE,"__esModule",{value:!0}),QE.OhlcSeriesHitTestProvider=void 0;var e=Eo(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u,c){c===void 0&&(c=0);var d=this.getTranslatedHitTestPoint(l,u);if(!d)return r.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries,b=this.parentSeries.dataSeries;if(!b)return r.HitTestInfo.empty();var S=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,h,b,v,b.dataDistributionCalculator.isSortedAscending),_=b.getNativeXValues(),C=b.getNativeYValues(),P=n.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,b,_,C,v,y,S,c);if(S>=0){var x=n.hitTestHelpers.testIsHitForOHLC(h,p,m,b,S,v,y,c);P.isHit=x.isHit,P.openValue=x.openValue,P.highValue=x.highValue,P.lowValue=x.lowValue,P.closeValue=x.closeValue}else P.isHit=!1;return P},s.prototype.hitTestForDataPointSelectionModifier=function(l,u,c){return c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(l,u,c)},s.prototype.hitTestXSlice=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=y.getNativeXValues(),b=y.getNativeYValues(),S=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,f,y,g,y.dataDistributionCalculator.isSortedAscending),_=n.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,m,b,g,v,S,0);if(S>=0){_.openValue=y.getNativeOpenValues().get(S),_.highValue=y.getNativeHighValues().get(S),_.lowValue=y.getNativeLowValues().get(S),_.closeValue=y.getNativeCloseValues().get(S);var C=f.isCategoryCoordinateCalculator,P=C?0:m.get(0),x=C?m.size()-1:m.get(m.size()-1),E=this.parentSeries.dataPointWidth;_.isWithinDataBounds=(0,e.testIsInInterval)(_.hitTestPointValues.x,P,x,E/2),_.isHit=_.isWithinDataBounds}else _.isHit=!1;return _},s})(i.BaseHitTestProvider);return QE.OhlcSeriesHitTestProvider=o,QE}var zSe;function Vie(){if(zSe)return KE;zSe=1;var t=KE&&KE.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(KE,"__esModule",{value:!0}),KE.BaseOhlcRenderableSeries=void 0;var e=Br(),i=di(),n=Em(),r=Bu(),o=zi(),a=$3(),s=jie(),l=Ije(),u=hR(),c=Om(),d=Xs(),f=Sn(),h=ju(),p=un(),g=Nje(),v=(function(y){t(m,y);function m(b,S){var _=this,C,P,x,E,A;return _=y.call(this,b,S)||this,_.dataPointWidthModeProperty=n.EDataPointWidthMode.Relative,_.strokeUp=(C=S==null?void 0:S.strokeUp)!==null&&C!==void 0?C:f.SciChartSurfaceBase.DEFAULT_THEME.upWickColor,_.strokeDown=(P=S==null?void 0:S.strokeDown)!==null&&P!==void 0?P:f.SciChartSurfaceBase.DEFAULT_THEME.downWickColor,_.dataPointWidth=(x=S==null?void 0:S.dataPointWidth)!==null&&x!==void 0?x:.5,_.dataPointWidthMode=(E=S==null?void 0:S.dataPointWidthMode)!==null&&E!==void 0?E:_.dataPointWidthModeProperty,_.strokeThickness=(A=S==null?void 0:S.strokeThickness)!==null&&A!==void 0?A:1,S!=null&&S.animation&&_.animationQueue.push(S.animation),_}return m.prototype.applyTheme=function(b){y.prototype.applyTheme.call(this,b);var S=this.parentSurface.previousThemeProvider;this.stroke===S.lineSeriesColor&&(this.stroke=b.lineSeriesColor),this.strokeUp===S.upWickColor&&(this.strokeUp=b.upWickColor),this.strokeDown===S.downWickColor&&(this.strokeDown=b.downWickColor)},Object.defineProperty(m.prototype,"strokeUp",{get:function(){return(0,d.stripAutoColor)(this.strokeUpProperty)},set:function(b){this.strokeUpProperty=b,this.notifyPropertyChanged(p.PROPERTY.STROKE_UP)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeDown",{get:function(){return(0,d.stripAutoColor)(this.strokeDownProperty)},set:function(b){this.strokeDownProperty=b,this.notifyPropertyChanged(p.PROPERTY.STROKE_DOWN)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(b){this.dataPointWidthProperty=b,this.notifyPropertyChanged(p.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(b){this.dataPointWidthModeProperty=b,this.notifyPropertyChanged(p.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),m.prototype.notifyPropertyChanged=function(b){if(y.prototype.notifyPropertyChanged.call(this,b),b===p.PROPERTY.DATA_SERIES&&this.dataSeries!==void 0&&this.dataSeries.type!==o.EDataSeriesType.Ohlc)throw new Error("DataSeries for Candlestick or Ohlc series must be type OhlcDataSeries")},m.prototype.getXRange=function(){var b=y.prototype.getXRange.call(this),S=(0,h.getDataPointWidthAdjustment)(this.dataPointWidthMode,this.dataPointWidth,this.dataSeries.count(),b,this.xAxis.getCurrentCoordinateCalculator());return new i.NumberRange(b.min-S,b.max+S)},m.prototype.delete=function(){this.resamplerHelper=(0,e.deleteSafe)(this.resamplerHelper),this.xyyTempPointSeries=(0,e.deleteSafe)(this.xyyTempPointSeries),this.pointSeries=(0,e.deleteSafe)(this.pointSeries),y.prototype.delete.call(this)},m.prototype.getNativeOpenValues=function(){return this.dataSeries.getNativeOpenValues()},m.prototype.getNativeHighValues=function(){return this.dataSeries.getNativeHighValues()},m.prototype.getNativeLowValues=function(){return this.dataSeries.getNativeLowValues()},m.prototype.getNativeCloseValues=function(){return this.dataSeries.getNativeYValues()},m.prototype.resolveAutoColors=function(b,S,_){if(this.strokeUpProperty.startsWith(d.AUTO_COLOR)){var C=_.getStrokeColor(b,S,this.webAssemblyContext);this.strokeUp=d.AUTO_COLOR+this.adjustAutoColor("strokeUp",C)}var P=(b+Math.floor(S/2))%S;if(this.strokeDownProperty.startsWith(d.AUTO_COLOR)){var C=_.getStrokeColor(P,S,this.webAssemblyContext);this.strokeDown=d.AUTO_COLOR+this.adjustAutoColor("strokeDown",C)}},m.prototype.toJSON=function(b){b===void 0&&(b=!1);var S=y.prototype.toJSON.call(this,b),_={dataPointWidth:this.dataPointWidth,dataPointWidthMode:this.dataPointWidthMode,strokeDown:this.strokeDown,strokeUp:this.strokeUp};return Object.assign(S.options,_),S},m.prototype.getYRange=function(b,S){S===void 0&&(S=!1);var _=this.isRunningDataAnimation?o.EDataSeriesValueType.FinalAnimationValues:o.EDataSeriesValueType.Default,C=this.getResampledPointSeries(S);if(this.renderDataTransform&&this.renderDataTransform.useForYRange)return this.updateTransformedValues(_),(0,r.getWindowedYRange)(this.webAssemblyContext,this.transformedRenderPassData.pointSeries.xValues,this.transformedRenderPassData.pointSeries.yValues,C?new i.NumberRange(0,C.count-1):b,!0,S,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.dataSeries.dataDistributionCalculator.containsNaN);if(C){var P=C,x=P.openValues,E=P.closeValues,A=P.highValues,R=P.lowValues,M=new i.NumberRange(0,C.count-1);return(0,a.getOHLCYRange)(M,x,A,R,E)}return this.dataSeries.getWindowedYRange(b,!0,S,_,this.yRangeMode)},m.prototype.toPointSeries=function(b){if(b){this.xyyTempPointSeries?this.xyyTempPointSeries.xRange=b.xVisibleRange:this.xyyTempPointSeries=new u.XyyPointSeriesResampled(this.webAssemblyContext,b.xVisibleRange),this.pointSeries?this.pointSeries.xRange=b.xVisibleRange:this.pointSeries=new s.OhlcPointSeriesResampled(this.webAssemblyContext,b.xVisibleRange);var S=this.pointSeries,_=this.dataSeries,C=_.getNativeXValues(),P=_.getNativeOpenValues(),x=_.getNativeHighValues(),E=_.getNativeLowValues(),A=_.getNativeCloseValues(),R=_.getNativeIndexes(),M=b.clone({resamplingMode:b.resamplingMode===c.EResamplingMode.None?c.EResamplingMode.None:c.EResamplingMode.Max}),D=this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext,M,C,x,this.xyyTempPointSeries.intIndexes,void 0,this.xyyTempPointSeries.xValues,S.highValues);this.pointSeries.fifoStartIndex=D.OutputSplitIndex,this.xyyTempPointSeries.clearIntIndexes();var F=b.clone({resamplingMode:b.resamplingMode===c.EResamplingMode.None?c.EResamplingMode.None:c.EResamplingMode.Min});this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext,F,C,E,this.xyyTempPointSeries.intIndexes,void 0,this.xyyTempPointSeries.xValues,S.lowValues),this.xyyTempPointSeries.clearIntIndexes(),this.xyyTempPointSeries.y1Values.clear();var I=b.clone({resamplingMode:b.resamplingMode===c.EResamplingMode.None?c.EResamplingMode.None:c.EResamplingMode.Min});this.resamplerHelper.resampleIntoPointSeries(this.webAssemblyContext,I,C,R,S.intIndexes,void 0,this.xyyTempPointSeries.xValues,this.xyyTempPointSeries.y1Values);var V=S.intIndexes.size();this.xyyTempPointSeries.y1Values.clear();var z=S.intIndexes.get(3)-S.intIndexes.get(2)-1;return S.indexes.resizeFast(V+1),this.resamplerHelper.copyValuesByIndexes(S.intIndexes,C,P,A,V,b.isCategoryAxis,this.dataSeries.fifoSweeping,S.indexes,S.xValues,S.openValues,S.closeValues,z),S.clearIntIndexes(),S}else return new l.OhlcPointSeriesWrapped(this.dataSeries)},m.prototype.newHitTestProvider=function(){return new g.OhlcSeriesHitTestProvider(this,this.webAssemblyContext)},m})(h.BaseRenderableSeries);return KE.BaseOhlcRenderableSeries=v,KE}var fB={},$Se;function o$(){return $Se||($Se=1,(function(t){var e=fB&&fB.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.OhlcSeriesDrawingProvider=t.EOhlcDrawingMode=void 0;var i=Br(),n=tu(),r=Ls(),o=un(),a=du(),s;(function(u){u.Candles="Candles",u.Ohlc="Ohlc"})(s=t.EOhlcDrawingMode||(t.EOhlcDrawingMode={}));var l=(function(u){e(c,u);function c(d,f,h){var p=u.call(this,d,f)||this;p.drawingMode=h,p.nativeDrawingProvider=new p.webAssemblyContext.SCRTCandlestickSeriesDrawingProvider,p.args=new p.webAssemblyContext.SCRTOhlcDrawingParams;var g=f.strokeThickness,v=f.strokeUp,y=f.strokeDown,m=f.opacity,b=f;return p.strokeUpPenCache=new r.Pen2DCache(d),p.strokeDownPenCache=new r.Pen2DCache(d),p.brushUpCache=new n.BrushCache(d),p.brushDownCache=new n.BrushCache(d),(0,r.createPenInCache)(p.strokeUpPenCache,v,g,m),(0,r.createPenInCache)(p.strokeDownPenCache,y,g,m),b.brushUp&&(0,n.createBrushInCache)(p.brushUpCache,b.brushUp,m),b.brushDown&&(0,n.createBrushInCache)(p.brushDownCache,b.brushDown,m),p}return c.prototype.onDpiChanged=function(d){u.prototype.onDpiChanged.call(this,d),this.onSeriesPropertyChange(o.PROPERTY.STROKE_UP),this.onSeriesPropertyChange(o.PROPERTY.STROKE_DOWN)},c.prototype.onSeriesPropertyChange=function(d){u.prototype.onSeriesPropertyChange.call(this,d);var f=this.parentSeries,h=f.strokeThickness,p=f.strokeUp,g=f.strokeDown,v=f.opacity;(d===o.PROPERTY.STROKE_UP||d===o.PROPERTY.STROKE_THICKNESS||d===o.PROPERTY.OPACITY)&&(0,r.createPenInCache)(this.strokeUpPenCache,p,h,v),(d===o.PROPERTY.STROKE_DOWN||d===o.PROPERTY.STROKE_THICKNESS||d===o.PROPERTY.OPACITY)&&(0,r.createPenInCache)(this.strokeDownPenCache,g,h,v);var y=this.parentSeries;(d===o.PROPERTY.BRUSH_DOWN||d===o.PROPERTY.OPACITY)&&(0,n.createBrushInCache)(this.brushDownCache,y==null?void 0:y.brushDown,v),(d===o.PROPERTY.BRUSH_UP||d===o.PROPERTY.OPACITY)&&(0,n.createBrushInCache)(this.brushUpCache,y==null?void 0:y.brushUp,v)},c.prototype.draw=function(d,f){var h=f.pointSeries;if(this.args.Reset(),this.drawingMode===s.Candles){var p=(0,n.getScrtBrushFromCache)(this.brushUpCache),g=(0,n.getScrtBrushFromCache)(this.brushDownCache);if(!p||!g)return;this.args.SetBrushes(p,g)}var v=(0,r.getScrtPenFromCache)(this.strokeUpPenCache),y=(0,r.getScrtPenFromCache)(this.strokeDownPenCache);if(!(!v||!y)){this.args.SetPens(v,y);var m="#ffffffff";u.prototype.applyStrokeFillPaletting.call(this,m,void 0,m,void 0,this.parentSeries.opacity),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.forceShaderMethod=!0,this.args.verticalChart=f.isVerticalChart,this.args.candleWidth=this.parentSeries.getDataPointWidth(f.xCoordinateCalculator,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),this.args.drawAsOhlc=this.drawingMode===s.Ohlc;var b=d.getNativeContext();this.parentSeries.parentSurface.seriesViewRect,this.parentSeries.dataSeries;var S=f.xCoordinateCalculator.isCategoryCoordinateCalculator,_=h.xValues,C=h.openValues,P=h.highValues,x=h.lowValues,E=h.closeValues,A=this.getStartAndCount(f,_),R=A.startIndex,M=A.count;this.args.count=M,this.args.startIndex=R;var D=this.parentSeries.dataSeries,F=D.fifoCapacity,I=D.fifoSweeping,V=D.fifoSweepingGap,z=h.fifoStartIndex;I&&F===this.parentSeries.dataSeries.count()&&(this.args.count=z);var G=S?h.indexes:_;this.args.SetValues(G,C,P,x,E),this.args.SetNativeContext(b),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args),I&&F===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(E.size(),z+V),this.args.count=Math.max(0,E.size()-z-V),this.args.count>0&&(this.args.SetNativeContext(b),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args)))}},c.prototype.delete=function(){this.strokeDownPenCache=(0,i.deleteSafe)(this.strokeDownPenCache),this.strokeUpPenCache=(0,i.deleteSafe)(this.strokeUpPenCache),this.brushUpCache=(0,i.deleteSafe)(this.brushUpCache),this.brushDownCache=(0,i.deleteSafe)(this.brushDownCache),this.nativeDrawingProvider=(0,i.deleteSafe)(this.nativeDrawingProvider),this.args=(0,i.deleteSafe)(this.args),u.prototype.delete.call(this)},c})(a.BaseSeriesDrawingProvider);t.OhlcSeriesDrawingProvider=l})(fB)),fB}var WSe;function Fje(){if(WSe)return XE;WSe=1;var t=XE&&XE.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(XE,"__esModule",{value:!0}),XE.FastCandlestickRenderableSeries=void 0;var e=hn(),i=Xs(),n=Sn(),r=Vie(),o=un(),a=o$(),s=(function(l){t(u,l);function u(c,d){var f=this,h,p;return f=l.call(this,c,d)||this,f.type=e.ESeriesType.CandlestickSeries,f.brushUp=(d==null?void 0:d.brushUp)||n.SciChartSurfaceBase.DEFAULT_THEME.upBodyBrush,f.brushDown=(d==null?void 0:d.brushDown)||n.SciChartSurfaceBase.DEFAULT_THEME.downBodyBrush,!((h=f.paletteProvider)===null||h===void 0)&&h.onAttached&&((p=f.paletteProvider)===null||p===void 0||p.onAttached(f)),f.drawingProviders=[],f.drawingProviders.push(new a.OhlcSeriesDrawingProvider(c,f,a.EOhlcDrawingMode.Candles)),f}return u.prototype.applyTheme=function(c){l.prototype.applyTheme.call(this,c);var d=this.parentSurface.previousThemeProvider;this.brushUp===d.upBodyBrush&&(this.brushUp=c.upBodyBrush),this.brushDown===d.downBodyBrush&&(this.brushDown=c.downBodyBrush)},Object.defineProperty(u.prototype,"brushUp",{get:function(){return(0,i.stripAutoColor)(this.brushUpProperty)},set:function(c){this.brushUpProperty=c,this.notifyPropertyChanged(o.PROPERTY.BRUSH_UP)},enumerable:!1,configurable:!0}),Object.defineProperty(u.prototype,"brushDown",{get:function(){return(0,i.stripAutoColor)(this.brushDownProperty)},set:function(c){this.brushDownProperty=c,this.notifyPropertyChanged(o.PROPERTY.BRUSH_DOWN)},enumerable:!1,configurable:!0}),u.prototype.toJSON=function(c){c===void 0&&(c=!1);var d=l.prototype.toJSON.call(this,c),f={brushDown:this.brushDown,brushUp:this.brushUp};return Object.assign(d.options,f),d},u.prototype.resolveAutoColors=function(c,d,f){if(l.prototype.resolveAutoColors.call(this,c,d,f),this.brushUpProperty.startsWith(i.AUTO_COLOR)){var h=f.getFillColor(c,d,this.webAssemblyContext);this.brushUp=i.AUTO_COLOR+this.adjustAutoColor("brushUp",h)}var p=(c+Math.floor(d/2))%d;if(this.brushDownProperty.startsWith(i.AUTO_COLOR)){var h=f.getFillColor(p,d,this.webAssemblyContext);this.brushDown=i.AUTO_COLOR+this.adjustAutoColor("brushDown",h)}},u})(r.BaseOhlcRenderableSeries);return XE.FastCandlestickRenderableSeries=s,XE}var Ob={},ew={},GSe;function Bje(){if(GSe)return ew;GSe=1;var t=ew&&ew.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(ew,"__esModule",{value:!0}),ew.ColumnSeriesDrawingProvider=void 0;var e=Br(),i=tu(),n=Ls(),r=Sn(),o=un(),a=du(),s=(function(l){t(u,l);function u(c,d,f,h){var p=l.call(this,c,d,f,h)||this;return p.nativeDrawingProvider=new c.SCRTColumnSeriesDrawingProvider,p.args=new p.webAssemblyContext.SCRTColumnDrawingParams,p.strokePenCache=new n.Pen2DCache(c),p.strokePenFillColoredCache=new n.Pen2DCache(c),p.fillBrushCache=new i.BrushCache(c),p}return u.prototype.onAttachSeries=function(){l.prototype.onAttachSeries.call(this);var c=this.getProperties(this.parentSeries),d=c.stroke,f=c.strokeThickness,h=c.fill,p=c.opacity;(0,n.createPenInCache)(this.strokePenCache,d,f,p),f===0&&(0,n.createPenInCache)(this.strokePenFillColoredCache,h,1,p),this.createBrush()},u.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.strokePenFillColoredCache=(0,e.deleteSafe)(this.strokePenFillColoredCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),l.prototype.delete.call(this)},u.prototype.getProperties=function(c){var d=c.stroke,f=c.strokeThickness,h=c.opacity,p=c.fill,g=c.fillLinearGradient,v=c.customTextureOptions;return{stroke:d,strokeThickness:f,opacity:h,fill:p,fillLinearGradient:g,customTextureOptions:v}},u.prototype.draw=function(c,d){var f=d.pointSeries,h=this.parentSeries.parentSurface.seriesViewRect,p=this.getProperties(this.parentSeries).strokeThickness;this.args.Reset(),this.args.forceShaderMethod=!0,this.args.verticalChart=d.isVerticalChart,this.args.zeroLineY=this.parentSeries.zeroLineY,this.args.columnWidth=this.parentSeries.getDataPointWidth(d.xCoordinateCalculator,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),this.args.bottomRadius=this.parentSeries.cornerRadius;var g=this.strokePenCache;this.args.columnWidth===1&&p===0&&(this.args.columnWidth=0,g=this.strokePenFillColoredCache);var v=(0,n.getScrtPenFromCache)(g);v&&this.args.SetLinesPen(v);var y=(0,i.getScrtBrushFromCache)(this.fillBrushCache);y&&this.args.SetFillBrush(y),this.args.viewportWidth=h.width,this.args.viewportHeight=h.height,l.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,v,this.parentSeries.fill,y,this.parentSeries.opacity,!1,this.parentSeries.fillLinearGradient!==void 0),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=this.palettingState.paletteStartIndex;var m=d.xCoordinateCalculator.isCategoryCoordinateCalculator,b=this.xSelector(f),S=this.ySelector(f),_=m?f.indexes:b,C=this.getStartAndCount(d,_),P=C.startIndex,x=C.count;this.args.count=x,this.args.startIndex=P;var E=this.parentSeries.dataSeries,A=E.fifoCapacity,R=E.fifoSweeping,M=E.fifoSweepingGap,D=f.fifoStartIndex;R&&A===this.parentSeries.dataSeries.count()&&(this.args.count=D);var F=c.getNativeContext();this.args.SetNativeContext(F),this.args.SetXValues(_),this.args.SetYValues(S),this.args.SetXCoordinateCalculator(d.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(d.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args),R&&A===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(S.size(),D+M),this.args.count=Math.max(0,S.size()-D-M),this.args.count>0&&this.nativeDrawingProvider.DrawPointsVec(this.args))},u.prototype.onDpiChanged=function(c){l.prototype.onDpiChanged.call(this,c),this.onSeriesPropertyChange(o.PROPERTY.STROKE)},u.prototype.onSeriesPropertyChange=function(c){l.prototype.onSeriesPropertyChange.call(this,c);var d=this.parentSeries,f=d.stroke,h=d.strokeThickness,p=d.opacity,g=d.fill;(c===o.PROPERTY.STROKE||c===o.PROPERTY.STROKE_THICKNESS||c===o.PROPERTY.OPACITY)&&(0,n.createPenInCache)(this.strokePenCache,f,h,p),(c===o.PROPERTY.FILL||c===o.PROPERTY.OPACITY||c===o.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&this.createBrush(),h===0&&(c===o.PROPERTY.STROKE_THICKNESS||c===o.PROPERTY.STROKE||c===o.PROPERTY.OPACITY||c===o.PROPERTY.FILL)&&(0,n.createPenInCache)(this.strokePenFillColoredCache,g,1,p)},u.prototype.createBrush=function(){var c=this.parentSeries.parentSurface,d=this.getProperties(this.parentSeries),f=d.fillLinearGradient,h=d.fill,p=d.opacity,g=d.customTextureOptions,v=c!=null&&c.isCopyCanvasSurface?c.domCanvas2D.height/r.SciChartSurfaceBase.domMasterCanvas.height:1,y=c!=null&&c.isCopyCanvasSurface?c.domCanvas2D.width/r.SciChartSurfaceBase.domMasterCanvas.width:1,m=this.fillBrushCache.create(h,p,v,y,f,g);return m.scrtBrush},u})(a.BaseSeriesDrawingProvider);return ew.ColumnSeriesDrawingProvider=s,ew}var tw={},YSe;function jje(){if(YSe)return tw;YSe=1;var t=tw&&tw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(tw,"__esModule",{value:!0}),tw.ColumnSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=v.getNativeYValues(),S=this.parentSeries,_=S.getDataPointWidth,C=S.dataPointWidth,P=S.zeroLineY,x=S.dataPointWidthMode,E=_(d,C,x),A=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0,void 0,E);return y>=0?A.isHit=i.hitTestHelpers.testIsHitForColumn(d,f,E,P,v,m,b,y,p,g):A.isHit=!1,A},a.prototype.hitTestForDataPointSelectionModifier=function(s,l,u){return u===void 0&&(u=e.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(s,l)},a.prototype.hitTestXSlice=function(s,l){var u=this.hitTest(s,l);return u.dataSeriesIndex>=0&&(u.isHit=u.isWithinDataBounds),u},a})(e.BaseHitTestProvider);return tw.ColumnSeriesHitTestProvider=r,tw}var qSe;function q3(){if(qSe)return Ob;qSe=1;var t=Ob&&Ob.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(Ob,"__esModule",{value:!0}),Ob.getXRange=Ob.FastColumnRenderableSeries=void 0;var e=di(),i=Em(),n=hn(),r=Xs(),o=Sn(),a=ju(),s=un(),l=iI(),u=Bje(),c=Yf(),d=jje(),f=(function(p){t(g,p);function g(v,y){var m=this,b,S,_,C,P,x,E,A;return m=p.call(this,v,y)||this,m.type=n.ESeriesType.ColumnSeries,m.fillProperty=o.SciChartSurfaceBase.DEFAULT_THEME.columnFillBrush,m.zeroLineYProperty=0,m.dataPointWidthProperty=.8,m.dataPointWidthModeProperty=i.EDataPointWidthMode.Relative,m.cornerRadiusProperty=0,m.fillProperty=(b=y==null?void 0:y.fill)!==null&&b!==void 0?b:m.fillProperty,m.zeroLineY=(S=y==null?void 0:y.zeroLineY)!==null&&S!==void 0?S:m.zeroLineYProperty,m.dataPointWidthProperty=(_=y==null?void 0:y.dataPointWidth)!==null&&_!==void 0?_:m.dataPointWidthProperty,m.dataPointWidthMode=(C=y==null?void 0:y.dataPointWidthMode)!==null&&C!==void 0?C:m.dataPointWidthModeProperty,m.fillLinearGradientProperty=(P=y==null?void 0:y.fillLinearGradient)!==null&&P!==void 0?P:m.fillLinearGradientProperty,m.cornerRadiusProperty=(x=y==null?void 0:y.cornerRadius)!==null&&x!==void 0?x:m.cornerRadiusProperty,m.customTextureOptionsProperty=y==null?void 0:y.customTextureOptions,!((E=m.paletteProvider)===null||E===void 0)&&E.onAttached&&((A=m.paletteProvider)===null||A===void 0||A.onAttached(m)),m.dataLabelProviderProperty||(m.dataLabelProviderProperty=new l.ColumnSeriesDataLabelProvider(y==null?void 0:y.dataLabels),m.dataLabelProviderProperty.onAttach(m.webAssemblyContext,m)),y!=null&&y.animation&&m.animationQueue.push(y.animation),m}return g.prototype.addDrawingProviders=function(v,y){this.drawingProviders.push(new u.ColumnSeriesDrawingProvider(v,this)),this.drawingProviders.push(new c.PointMarkerDrawingProvider(v,this))},g.prototype.applyTheme=function(v){p.prototype.applyTheme.call(this,v);var y=this.parentSurface.previousThemeProvider;this.fill===y.columnFillBrush&&(this.fill=v.columnFillBrush),this.stroke===y.columnLineColor&&(this.stroke=v.columnLineColor)},Object.defineProperty(g.prototype,"fill",{get:function(){return(0,r.stripAutoColor)(this.fillProperty)},set:function(v){this.fillProperty!==v&&(this.fillProperty=v,this.notifyPropertyChanged(s.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(v){v!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=v,this.notifyPropertyChanged(s.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"zeroLineY",{get:function(){return this.zeroLineYProperty},set:function(v){this.zeroLineYProperty=v,this.notifyPropertyChanged(s.PROPERTY.ZERO_LINE_Y)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(v){this.dataPointWidthProperty=v,this.notifyPropertyChanged(s.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(v){this.dataPointWidthModeProperty=v,this.notifyPropertyChanged(s.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"cornerRadius",{get:function(){return this.cornerRadiusProperty},set:function(v){this.cornerRadiusProperty=v,this.notifyPropertyChanged(s.PROPERTY.CORNER_RADIUS)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(v){v!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=v,this.notifyPropertyChanged(s.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),g.prototype.getXRange=function(){var v=p.prototype.getXRange.call(this),y=(0,a.getDataPointWidthAdjustment)(this.dataPointWidthMode,this.dataPointWidth,this.dataSeries.count(),v,this.xAxis.getCurrentCoordinateCalculator());return new e.NumberRange(v.min-y,v.max+y)},g.prototype.getYRange=function(v,y){y===void 0&&(y=!1);var m=p.prototype.getYRange.call(this,v,y);if(m)return new e.NumberRange(Math.min(m.min,this.zeroLineY),Math.max(m.max,this.zeroLineY))},g.prototype.resolveAutoColors=function(v,y,m){if(p.prototype.resolveAutoColors.call(this,v,y,m),this.fillProperty.startsWith(r.AUTO_COLOR)){var b=m.getFillColor(v,y,this.webAssemblyContext);this.fill=r.AUTO_COLOR+this.adjustAutoColor("fill",b)}},g.prototype.toJSON=function(v){v===void 0&&(v=!1);var y=p.prototype.toJSON.call(this,v),m={dataPointWidth:this.dataPointWidth,dataPointWidthMode:this.dataPointWidthMode,fill:this.fill,zeroLineY:this.zeroLineY,fillLinearGradient:this.fillLinearGradient,cornerRadius:this.cornerRadius};return Object.assign(y.options,m),y},g.prototype.newHitTestProvider=function(){return new d.ColumnSeriesHitTestProvider(this,this.webAssemblyContext)},g})(a.BaseRenderableSeries);Ob.FastColumnRenderableSeries=f;var h=function(p,g,v){if(g>1){var y=p.diff/(g-1)*v/2;return new e.NumberRange(p.min-y,p.max+y)}return p};return Ob.getXRange=h,Ob}var rw={},o7={},XSe;function zW(){return XSe||(XSe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EErrorMode=void 0,(function(e){e.Both="Both",e.High="High",e.Low="Low"})(t.EErrorMode||(t.EErrorMode={}))})(o7)),o7}var iw={},KSe;function Vje(){if(KSe)return iw;KSe=1;var t=iw&&iw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(iw,"__esModule",{value:!0}),iw.HlcPointSeriesWrapped=void 0;var e=Yo(),i=zi(),n=wm(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s,void 0,i.EDataSeriesValueType.Default,[e.EValueName.Close,e.EValueName.High,e.EValueName.Low])||this;return l.type=i.EDataSeriesType.Hlc,l}return Object.defineProperty(a.prototype,"closeValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"highValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowValues",{get:function(){return this.yValuesArray[2]},enumerable:!1,configurable:!0}),a})(n.BasePointSeriesWrapped);return iw.HlcPointSeriesWrapped=r,iw}var nw={},ZSe;function Hje(){if(ZSe)return nw;ZSe=1;var t=nw&&nw.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(nw,"__esModule",{value:!0}),nw.ErrorSeriesDrawingProvider=void 0;var e=qS(),i=Br(),n=Rn(),r=ud(),o=QV(),a=zW(),s=Ls(),l=Iu(),u=z3(),c=an(),d=un(),f=du(),h=(function(p){t(g,p);function g(v,y){var m=p.call(this,v,y)||this;return m.linesPenCache=new s.Pen2DCache(v),m.tempXVec=new m.webAssemblyContext.SCRTDoubleVector,m.tempYVec=new m.webAssemblyContext.SCRTDoubleVector,m}return g.prototype.onAttachSeries=function(){p.prototype.onAttachSeries.call(this),this.args=new this.webAssemblyContext.SCRTLineDrawingParams,this.nativeDrawingProvider=new this.webAssemblyContext.SCRTLineSegmentDrawingProvider;var v=this.parentSeries,y=v.stroke,m=v.strokeThickness,b=v.opacity,S=v.strokeDashArray;(0,s.createPenInCache)(this.linesPenCache,y,m,b,S)},g.prototype.onDetachSeries=function(){p.prototype.onDetachSeries.call(this)},g.prototype.delete=function(){this.nativeDrawingProvider=(0,i.deleteSafe)(this.nativeDrawingProvider),this.linesPenCache=(0,i.deleteSafe)(this.linesPenCache),this.args=(0,i.deleteSafe)(this.args),this.tempXVec=(0,i.deleteSafe)(this.tempXVec),this.tempYVec=(0,i.deleteSafe)(this.tempYVec),p.prototype.delete.call(this)},g.prototype.draw=function(v,y){var m=(0,s.getScrtPenFromCache)(this.linesPenCache);if(!(!m||m.m_fThickness===0)){var b=y.pointSeries,S=(0,c.getVectorColorVertex)(this.webAssemblyContext),_=y.xCoordinateCalculator.isCategoryCoordinateCalculator,C=b.xValues,P=_?b.indexes:C,x=b.yValues,E=b.highValues,A=b.lowValues,R=this.parentSeries.errorDirection===o.EErrorDirection.Vertical,M=R?y.xCoordinateCalculator:y.yCoordinateCalculator,D=this.parentSeries.getDataPointWidth(M,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),F=M.getDataWidth(D),I=D*.5,V=this.parentSeries.xAxis.type===r.EAxisType.LogarithmicAxis,z=this.parentSeries.yAxis.type===r.EAxisType.LogarithmicAxis,G=this.parentSeries.xAxis.isNegative,H=this.parentSeries.yAxis.isNegative,U=this.parentSeries.errorMode!==a.EErrorMode.Low,k=this.parentSeries.errorMode!==a.EErrorMode.High,X=P.size(),W=(0,e.vectorToArrayViewF64)(P,this.webAssemblyContext),Y=(0,e.vectorToArrayViewF64)(x,this.webAssemblyContext),te=(0,e.vectorToArrayViewF64)(E,this.webAssemblyContext),oe=(0,e.vectorToArrayViewF64)(A,this.webAssemblyContext);if(this.args.Reset(),this.args.SetLinesPen(m),this.args.forceShaderMethod=!0,this.args.verticalChart=y.isVerticalChart,this.args.startIndex=0,this.args.count=X,z){if(R)for(var ge=0;ge<X;++ge){var Ee=W[ge],Re=Y[ge],Ae=U?te[ge]:Re,Pe=k?oe[ge]:Re,we=z&&!H&&Pe<=0;we&&(Pe=this.parentSeries.yAxis.visibleRange.min);var Te=z&&H&&Ae>=0;Te&&(Ae=this.parentSeries.yAxis.visibleRange.max);var ke=y.xCoordinateCalculator.getCoordinate(Ee),$e=y.yCoordinateCalculator.getCoordinate(Re),Ne=y.yCoordinateCalculator.getCoordinate(Ae),ve=y.yCoordinateCalculator.getCoordinate(Pe),pe=ke-I,fe=ke+I;this.parentSeries.drawConnector&&this.addLineVertices(S,ke,isNaN(Ae)?$e:Ne,ke,isNaN(Pe)?$e:ve),U&&!Te&&this.parentSeries.drawWhiskers&&this.addLineVertices(S,pe,Ne,fe,Ne),k&&!we&&this.parentSeries.drawWhiskers&&this.addLineVertices(S,pe,ve,fe,ve)}else for(var ge=0;ge<X;++ge){var Ee=W[ge],Re=Y[ge],Ae=U?te[ge]:Ee,Pe=k?oe[ge]:Ee,we=V&&!G&&Pe<=0;we&&(Pe=u.MIN_LOG_AXIS_VALUE);var Te=V&&G&&Ae>=0;Te&&(Ae=-u.MIN_LOG_AXIS_VALUE);var ke=y.xCoordinateCalculator.getCoordinate(Ee),$e=y.yCoordinateCalculator.getCoordinate(Re),Ne=y.xCoordinateCalculator.getCoordinate(Ae),ve=y.xCoordinateCalculator.getCoordinate(Pe),pe=$e-I,fe=$e+I;this.parentSeries.drawConnector&&this.addLineVertices(S,isNaN(Pe)?ke:ve,$e,isNaN(Ae)?ke:Ne,$e),U&&!Te&&this.parentSeries.drawWhiskers&&this.addLineVertices(S,Ne,pe,Ne,fe),k&&!we&&this.parentSeries.drawWhiskers&&this.addLineVertices(S,ve,pe,ve,fe)}var me=this.parentSeries.parentSurface.seriesViewRect,Ce=n.Rect.intersect(this.parentSeries.parentSurface.clipRect,me);v.drawLinesNative(S,m,l.ELineDrawMode.DiscontinuousLine,Ce,me.x,me.y)}else if(R){this.parentSeries.drawConnector&&(this.args.fourVectorsMode=!0,this.args.SetXValues(P),this.args.SetYValues(U?E:x),this.args.SetZValues(P),this.args.SetWValues(k?A:x),this.args.SetNativeContext(v.getNativeContext()),this.args.SetXCoordinateCalculator(y.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(y.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawLinesVec(this.args));var de=this.prepareTempCapVectors(0,X,F,P,A,E,!0,U,k);this.drawCaps(v,y,m,de)}else{this.parentSeries.drawConnector&&(this.args.fourVectorsMode=!0,this.args.SetXValues(U?E:P),this.args.SetYValues(x),this.args.SetZValues(k?A:P),this.args.SetWValues(x),this.args.SetNativeContext(v.getNativeContext()),this.args.SetXCoordinateCalculator(y.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(y.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawLinesVec(this.args));var de=this.prepareTempCapVectors(0,X,F,x,A,E,!1,U,k);this.drawCaps(v,y,m,de)}}},g.prototype.onDpiChanged=function(v){p.prototype.onDpiChanged.call(this,v),this.onSeriesPropertyChange(d.PROPERTY.STROKE)},g.prototype.onSeriesPropertyChange=function(v){p.prototype.onSeriesPropertyChange.call(this,v);var y=this.parentSeries,m=y.stroke,b=y.strokeThickness,S=y.opacity,_=y.strokeDashArray;(v===d.PROPERTY.STROKE||v===d.PROPERTY.STROKE_THICKNESS||v===d.PROPERTY.OPACITY||v===d.PROPERTY.STROKE_DASH_ARRAY)&&(0,s.createPenInCache)(this.linesPenCache,m,b,S,_)},g.prototype.prepareTempCapVectors=function(v,y,m,b,S,_,C,P,x){var E=(P?2:0)+(x?2:0);this.tempXVec.resizeFast(y*E),this.tempYVec.resizeFast(y*E);var A=m/2,R=(0,e.vectorToArrayViewF64)(b,this.webAssemblyContext),M=(0,e.vectorToArrayViewF64)(C?this.tempXVec:this.tempYVec,this.webAssemblyContext),D=(0,e.vectorToArrayViewF64)(C?this.tempYVec:this.tempXVec,this.webAssemblyContext);if(P&&x)for(var F=(0,e.vectorToArrayViewF64)(S,this.webAssemblyContext),I=(0,e.vectorToArrayViewF64)(_,this.webAssemblyContext),V=v;V<v+y;V++){var z=R[V],G=F[V],H=I[V],U=V*4;M[U]=z-A,D[U]=H,M[U+1]=z+A,D[U+1]=H,M[U+2]=z-A,D[U+2]=G,M[U+3]=z+A,D[U+3]=G}else for(var I=(0,e.vectorToArrayViewF64)(P?_:S,this.webAssemblyContext),V=v;V<v+y;V++){var z=R[V],H=I[V],U=V*2;M[U]=z-A,D[U]=H,M[U+1]=z+A,D[U+1]=H}return y*E},g.prototype.drawCaps=function(v,y,m,b){m&&(this.args.Reset(),this.args.SetLinesPen(m),this.args.forceShaderMethod=!0,this.args.forceClamp=!0,this.args.verticalChart=!1,this.args.SetXValues(this.tempXVec),this.args.SetYValues(this.tempYVec),this.args.SetXCoordinateCalculator(y.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(y.yCoordinateCalculator.nativeCalculator),this.args.SetNativeContext(v.getNativeContext()),this.args.count=b,this.args.startIndex=0,this.args.SetNativeContext(v.getNativeContext()),this.args.SetXValues(this.tempXVec),this.args.SetYValues(this.tempYVec),this.args.SetXCoordinateCalculator(y.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(y.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawLinesVec(this.args))},g.prototype.addLineVertices=function(v,y,m,b,S){var _=this.parentSeries.xAxis.isVerticalChart;_?(v.push_back((0,c.getVertex)(this.webAssemblyContext,m,y)),v.push_back((0,c.getVertex)(this.webAssemblyContext,S,b))):(v.push_back((0,c.getVertex)(this.webAssemblyContext,y,m)),v.push_back((0,c.getVertex)(this.webAssemblyContext,b,S)))},g})(f.BaseSeriesDrawingProvider);return nw.ErrorSeriesDrawingProvider=h,nw}var ow={},JSe;function Uje(){if(JSe)return ow;JSe=1;var t=ow&&ow.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(ow,"__esModule",{value:!0}),ow.ErrorSeriesHitTestProvider=void 0;var e=QV(),i=zW(),n=Eo(),r=Vl(),o=vl(),a=tl(),s=(function(l){t(u,l);function u(){return l!==null&&l.apply(this,arguments)||this}return u.prototype.hitTest=function(c,d){var f=this.getTranslatedHitTestPoint(c,d);if(!f)return a.HitTestInfo.empty();var h=this.currentRenderPassData,p=h.xCoordinateCalculator,g=h.yCoordinateCalculator,v=h.isVerticalChart,y=v?f.y:f.x,m=v?f.x:f.y,b=this.parentSeries.dataSeries;if(!b)return a.HitTestInfo.empty();var S=o.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,p,b,y,b.dataDistributionCalculator.isSortedAscending),_=b.getNativeXValues(),C=b.getNativeYValues(),P=o.hitTestHelpers.createHitTestInfo(this.parentSeries,p,g,v,b,_,C,y,m,S,0);if(S>=0){var x=o.hitTestHelpers.testIsHitForErrorBars(p,g,this.parentSeries,_,C,S,y,m);P.isHit=x.isHit,P.highValue=x.highValue,P.lowValue=x.lowValue}else P.isHit=!1;return P},u.prototype.hitTestForDataPointSelectionModifier=function(c,d,f){return f===void 0&&(f=r.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(c,d)},u.prototype.hitTestXSlice=function(c,d){var f=this.getTranslatedHitTestPoint(c,d);if(!f)return a.HitTestInfo.empty();var h=this.currentRenderPassData,p=h.xCoordinateCalculator,g=h.yCoordinateCalculator,v=h.isVerticalChart,y=v?f.y:f.x,m=v?f.x:f.y,b=this.parentSeries.dataSeries;if(!b)return a.HitTestInfo.empty();var S=b.getNativeXValues(),_=b.getNativeYValues(),C=b.getNativeLowValues(),P=b.getNativeHighValues(),x=o.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,p,b,y,b.dataDistributionCalculator.isSortedAscending),E=o.hitTestHelpers.createHitTestInfo(this.parentSeries,p,g,v,b,S,_,y,m,x,0),A=p.isCategoryCoordinateCalculator;if(x>=0){var R=this.parentSeries.errorDirection===e.EErrorDirection.Vertical;E.highValue=P.get(x),E.lowValue=C.get(x);var M=this.parentSeries.errorMode!==i.EErrorMode.High,D=this.parentSeries.errorMode!==i.EErrorMode.Low,F=void 0,I=void 0;R?(F=A?0:S.get(0),I=A?S.size()-1:S.get(S.size()-1)):(F=M?C.get(0):S.get(0),I=D?P.get(S.size()-1):S.get(S.size()-1));var V=this.parentSeries.getDataPointWidth(R?p:g,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),z=V/2,G=p.getCoordinate(E.hitTestPointValues.x),H=p.getCoordinate(F),U=p.getCoordinate(I);E.isWithinDataBounds=(0,n.testIsInInterval)(G,H-z,U+z),E.isHit=E.isWithinDataBounds}else E.isHit=!1;return E},u})(r.BaseHitTestProvider);return ow.ErrorSeriesHitTestProvider=s,ow}var QSe;function zje(){if(QSe)return rw;QSe=1;var t=rw&&rw.__extends||(function(){var v=function(y,m){return v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,S){b.__proto__=S}||function(b,S){for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(b[_]=S[_])},v(y,m)};return function(y,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");v(y,m);function b(){this.constructor=y}y.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}})();Object.defineProperty(rw,"__esModule",{value:!0}),rw.FastErrorBarsRenderableSeries=void 0;var e=Br(),i=di(),n=ud(),r=Em(),o=QV(),a=zW(),s=hn(),l=zi(),u=Vje(),c=ju(),d=un(),f=Hje(),h=Yf(),p=Uje(),g=(function(v){t(y,v);function y(m,b){var S=this,_,C,P,x,E,A,R,M,D;return S=v.call(this,m,b)||this,S.type=s.ESeriesType.ErrorBarsSeries,S.dataPointWidthProperty=.5,S.dataPointWidthModeProperty=r.EDataPointWidthMode.Relative,S.errorModeProperty=a.EErrorMode.Both,S.errorDirectionProperty=o.EErrorDirection.Vertical,S.strokeDashArrayProperty=[],S.drawWhiskersProperty=!0,S.drawConnectorProperty=!0,S.dataPointWidth=(_=b==null?void 0:b.dataPointWidth)!==null&&_!==void 0?_:S.dataPointWidthProperty,S.errorModeProperty=(C=b==null?void 0:b.errorMode)!==null&&C!==void 0?C:S.errorModeProperty,S.errorDirectionProperty=(P=b==null?void 0:b.errorDirection)!==null&&P!==void 0?P:S.errorDirectionProperty,S.dataPointWidthMode=(x=b==null?void 0:b.dataPointWidthMode)!==null&&x!==void 0?x:S.dataPointWidthModeProperty,S.strokeDashArray=(E=b==null?void 0:b.strokeDashArray)!==null&&E!==void 0?E:S.strokeDashArrayProperty,S.drawWhiskers=(A=b==null?void 0:b.drawWhiskers)!==null&&A!==void 0?A:S.drawWhiskersProperty,S.drawConnector=(R=b==null?void 0:b.drawConnector)!==null&&R!==void 0?R:S.drawConnectorProperty,S.drawingProviders=[new f.ErrorSeriesDrawingProvider(m,S),new h.PointMarkerDrawingProvider(m,S)],!((M=S.paletteProvider)===null||M===void 0)&&M.onAttached&&((D=S.paletteProvider)===null||D===void 0||D.onAttached(S)),b!=null&&b.animation&&S.animationQueue.push(b.animation),S}return y.prototype.applyTheme=function(m){v.prototype.applyTheme.call(this,m);var b=this.parentSurface.previousThemeProvider;this.stroke===b.lineSeriesColor&&(this.stroke=m.lineSeriesColor)},Object.defineProperty(y.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(m){this.strokeDashArrayProperty=m,this.notifyPropertyChanged(d.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"drawWhiskers",{get:function(){return this.drawWhiskersProperty},set:function(m){this.drawWhiskersProperty=m,this.notifyPropertyChanged(d.PROPERTY.DRAW_WHISKERS)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"drawConnector",{get:function(){return this.drawConnectorProperty},set:function(m){this.drawConnectorProperty=m,this.notifyPropertyChanged(d.PROPERTY.DRAW_CONNECTOR)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"paletteProvider",{get:function(){},set:function(m){throw new Error("paletteProvider is not supported by FastErrorBarsRenderableSeries!")},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(m){this.dataPointWidthProperty=m,this.notifyPropertyChanged(d.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"errorMode",{get:function(){return this.errorModeProperty},set:function(m){this.errorModeProperty=m,this.notifyPropertyChanged(d.PROPERTY.ERROR_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"errorDirection",{get:function(){return this.errorDirectionProperty},set:function(m){this.errorDirectionProperty=m,this.notifyPropertyChanged(d.PROPERTY.ERROR_DIRECTION)},enumerable:!1,configurable:!0}),Object.defineProperty(y.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(m){this.dataPointWidthModeProperty=m,this.notifyPropertyChanged(d.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),y.prototype.delete=function(){v.prototype.delete.call(this),this.pointSeries=(0,e.deleteSafe)(this.pointSeries)},y.prototype.getDataPointWidth=function(m,b,S){var _=this.errorDirection===o.EErrorDirection.Vertical,C=_?this.dataSeries.getNativeXValues():this.dataSeries.getNativeYValues(),P=m.viewportDimension,x=m.isCategoryCoordinateCalculator;if(S===r.EDataPointWidthMode.Range){var E=m.visibleMax-m.visibleMin;return m.viewportDimension/E*b}else{if(S===r.EDataPointWidthMode.Absolute)return b;var A=Math.floor((0,c.getDataPointWidth)(C,m,P,b,x,_&&this.dataSeries.dataDistributionCalculator.isSortedAscending,this.webAssemblyContext));return A%2!==0&&(A-=1),A<=1&&(A=1),A}},y.prototype.getXRange=function(){var m,b=this.errorDirection===o.EErrorDirection.Vertical,S=this.errorMode!==a.EErrorMode.Low,_=this.errorMode!==a.EErrorMode.High,C=this.dataSeries.getXRange(l.EDataSeriesValueType.Default,!b,S,_);return this.xAxis.type===n.EAxisType.LogarithmicAxis?C:b?this.adjustRangeByDataPointWidth(C,this.xAxis):(0,c.adjustRangeByStrokeThickness)(C,this.strokeThickness,(m=this.parentSurface.seriesViewRect)===null||m===void 0?void 0:m.width)},y.prototype.getYRange=function(m,b){var S;b===void 0&&(b=!1);var _=this.errorDirection===o.EErrorDirection.Horizontal,C=this.errorMode!==a.EErrorMode.Low,P=this.errorMode!==a.EErrorMode.High,x=this.isRunningDataAnimation?l.EDataSeriesValueType.FinalAnimationValues:l.EDataSeriesValueType.Default,E=this.dataSeries.getWindowedYRange(m,!0,b,x,this.yRangeMode,_,C,P);if(E!==void 0)return this.yAxis.type===n.EAxisType.LogarithmicAxis?E:_?this.adjustRangeByDataPointWidth(E,this.yAxis):(0,c.adjustRangeByStrokeThickness)(E,this.strokeThickness,(S=this.parentSurface.seriesViewRect)===null||S===void 0?void 0:S.height)},y.prototype.toJSON=function(m){m===void 0&&(m=!1);var b=v.prototype.toJSON.call(this,m),S={dataPointWidth:this.dataPointWidth,dataPointWidthMode:this.dataPointWidthMode,errorDirection:this.errorDirection,errorMode:this.errorMode,drawWhiskers:this.drawWhiskers,drawConnector:this.drawConnector,strokeDashArray:this.strokeDashArray};return Object.assign(b.options,S),b},y.prototype.toPointSeries=function(m){if(m)throw new Error("Error Bars Series don't support resampling!");return new u.HlcPointSeriesWrapped(this.dataSeries)},y.prototype.newHitTestProvider=function(){return new p.ErrorSeriesHitTestProvider(this,this.webAssemblyContext)},y.prototype.adjustRangeByDataPointWidth=function(m,b){var S=(0,c.getDataPointWidthAdjustment)(this.dataPointWidthMode,this.dataPointWidth,this.dataSeries.count(),m,b.getCurrentCoordinateCalculator());return new i.NumberRange(m.min-S,m.max+S)},y})(c.BaseRenderableSeries);return rw.FastErrorBarsRenderableSeries=g,rw}var aw={},sw={},e_e;function $je(){if(e_e)return sw;e_e=1;var t=sw&&sw.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(sw,"__esModule",{value:!0}),sw.ImpulseSeriesHitTestProvider=void 0;var e=Eo(),i=Zi(),n=Vl(),r=vl(),o=tl(),a=(function(s){t(l,s);function l(){return s!==null&&s.apply(this,arguments)||this}return l.prototype.hitTest=function(u,c,d){d===void 0&&(d=n.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var f=this.getTranslatedHitTestPoint(u,c);if(!f)return o.HitTestInfo.empty();var h=this.currentRenderPassData,p=h.xCoordinateCalculator,g=h.yCoordinateCalculator,v=h.isVerticalChart,y=v?f.y:f.x,m=v?f.x:f.y,b=this.parentSeries.dataSeries;if(!b)return o.HitTestInfo.empty();var S=r.hitTestHelpers.getNearestXyPoint(this.webAssemblyContext,p,g,b,y,m,d),_=r.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,p,b,y,b.dataDistributionCalculator.isSortedAscending),C=b.getNativeXValues(),P=b.getNativeYValues(),x=r.hitTestHelpers.createHitTestInfo(this.parentSeries,p,g,v,b,C,P,y,m,_,0);return _>=0||S.nearestPointIndex>=0?x.isHit=r.hitTestHelpers.testIsHitForImpulse(p,g,this.parentSeries,C,P,_,y,m,d)||r.hitTestHelpers.testIsHitForPoint(p,g,C,P,S.nearestPointIndex,y,m,this.parentSeries.size,b):x.isHit=!1,x},l.prototype.hitTestForDataPointSelectionModifier=function(u,c,d){return d===void 0&&(d=n.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(u,c,d)},l.prototype.hitTestXSlice=function(u,c){var d,f=this.getTranslatedHitTestPoint(u,c);if(!f)return o.HitTestInfo.empty();var h=this.currentRenderPassData,p=h.xCoordinateCalculator,g=h.yCoordinateCalculator,v=h.isVerticalChart,y=v?f.y:f.x,m=v?f.x:f.y,b=this.parentSeries.dataSeries;if(!b)return o.HitTestInfo.empty();var S=b.getNativeXValues(),_=b.getNativeYValues(),C=r.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,p,b,y,b.dataDistributionCalculator.isSortedAscending),P=r.hitTestHelpers.createHitTestInfo(this.parentSeries,p,g,v,b,S,_,y,m,C,0),x=p.isCategoryCoordinateCalculator,E=((d=this.parentSeries.size)!==null&&d!==void 0?d:0)*i.DpiHelper.PIXEL_RATIO,A=p.getDataWidth(E);if(C>=0){var R=x?0:S.get(0),M=x?S.size()-1:S.get(S.size()-1);P.isWithinDataBounds=(0,e.testIsInInterval)(P.hitTestPointValues.x,R,M,A/2),P.isHit=P.isWithinDataBounds}else P.isHit=!1;return P},l})(n.BaseHitTestProvider);return sw.ImpulseSeriesHitTestProvider=a,sw}var t_e;function Wje(){if(t_e)return aw;t_e=1;var t=aw&&aw.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(aw,"__esModule",{value:!0}),aw.FastImpulseRenderableSeries=void 0;var e=di(),i=hn(),n=Xs(),r=MI(),o=Sn(),a=ju(),s=un(),l=q3(),u=$je(),c=(function(d){t(f,d);function f(h,p){var g=this,v,y,m,b;return g=d.call(this,h,p)||this,g.type=i.ESeriesType.ImpulseSeries,g.impulseFillProperty=o.SciChartSurfaceBase.DEFAULT_THEME.impulseFillBrush,g.impulseSizeProperty=10,g.impulseDataPointWidthProperty=0,g.impulseStrokeThicknessProperty=1,g.strokeThickness=(v=p==null?void 0:p.strokeThickness)!==null&&v!==void 0?v:g.impulseStrokeThicknessProperty,g.fill=(y=p==null?void 0:p.fill)!==null&&y!==void 0?y:g.impulseFillProperty,g.size=(m=p==null?void 0:p.size)!==null&&m!==void 0?m:g.impulseSizeProperty,g.stroke=(b=p==null?void 0:p.fill)!==null&&b!==void 0?b:g.impulseFillProperty,g.dataPointWidth=g.impulseDataPointWidthProperty,p!=null&&p.pointMarker||(g.pointMarker=new r.EllipsePointMarker(h,{width:g.impulseSizeProperty,height:g.impulseSizeProperty,fill:g.fill,stroke:g.fill})),g}return Object.defineProperty(f.prototype,"fill",{get:function(){return(0,n.stripAutoColor)(this.impulseFillProperty)},set:function(h){this.impulseFillProperty=h,this.stroke=h,this.pointMarker&&(this.pointMarker.fill=h,this.pointMarker.stroke=h),this.impulseFillProperty!==h&&this.notifyPropertyChanged(s.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"size",{get:function(){return this.impulseSizeProperty},set:function(h){this.impulseSizeProperty=h,this.pointMarker&&(this.pointMarker.width=h,this.pointMarker.height=h)},enumerable:!1,configurable:!0}),f.prototype.getXRange=function(){var h,p,g=d.prototype.getXRange.call(this),v=(0,a.getDelta)({pointSize:this.size,areaSize:(p=(h=this.parentSurface.seriesViewRect)===null||h===void 0?void 0:h.width)!==null&&p!==void 0?p:0,range:g});return new e.NumberRange(g.min-v,g.max+v)},f.prototype.getYRange=function(h,p){var g,v;p===void 0&&(p=!1);var y=d.prototype.getYRange.call(this,h,p);if(y){var m=(0,a.getDelta)({pointSize:this.size,areaSize:(v=(g=this.parentSurface.seriesViewRect)===null||g===void 0?void 0:g.height)!==null&&v!==void 0?v:0,range:y});return new e.NumberRange(y.min-m,y.max+m)}},f.prototype.toJSON=function(h){h===void 0&&(h=!1);var p=d.prototype.toJSON.call(this,h),g={fill:this.fill,size:this.size,zeroLineY:this.zeroLineY};return Object.assign(p.options,g),p},f.prototype.applyTheme=function(h){d.prototype.applyTheme.call(this,h);var p=this.parentSurface.previousThemeProvider;this.fill===p.impulseFillBrush&&(this.fill=h.impulseFillBrush)},f.prototype.resolveAutoColors=function(h,p,g){if(d.prototype.resolveAutoColors.call(this,h,p,g),this.impulseFillProperty.startsWith(n.AUTO_COLOR)){var v=g.getStrokeColor(h,p,this.webAssemblyContext);this.fill=n.AUTO_COLOR+this.adjustAutoColor("impulseFill",v)}},f.prototype.newHitTestProvider=function(){return new u.ImpulseSeriesHitTestProvider(this,this.webAssemblyContext)},f})(l.FastColumnRenderableSeries);return aw.FastImpulseRenderableSeries=c,aw}var lw={},hB={},uw={},r_e;function Hie(){if(r_e)return uw;r_e=1;var t=uw&&uw.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(uw,"__esModule",{value:!0}),uw.LineSeriesDrawingProvider=void 0;var e=Br(),i=Ls(),n=Iu(),r=mm(),o=un(),a=du(),s=(function(l){t(u,l);function u(c,d,f,h){var p=l.call(this,c,d,f,h)||this;return p.linesPenCache=new i.Pen2DCache(c),p.args=new c.SCRTLineDrawingParams,p}return u.prototype.onDpiChanged=function(c){l.prototype.onDpiChanged.call(this,c),this.onSeriesPropertyChange(o.PROPERTY.STROKE)},u.prototype.onSeriesPropertyChange=function(c){if(l.prototype.onSeriesPropertyChange.call(this,c),c===o.PROPERTY.PALETTE_PROVIDER&&this.linesPenCache.invalidateCache(),c===o.PROPERTY.STROKE||c===o.PROPERTY.STROKE_THICKNESS||c===o.PROPERTY.PALETTE_PROVIDER||c===o.PROPERTY.OPACITY||c===o.PROPERTY.STROKE_DASH_ARRAY){this.palettingState.requiresUpdate=!0;var d=this.getProperties(this.parentSeries),f=d.stroke,h=d.strokeThickness,p=d.opacity,g=d.strokeDashArray;f&&(0,i.createPenInCache)(this.linesPenCache,f,h,p??1,g)}},u.prototype.getProperties=function(c){var d=c.stroke,f=c.strokeThickness,h=c.opacity,p=c.strokeDashArray,g=c.isDigitalLine,v=c.drawNaNAs,y=c.lineType;return{stroke:d,strokeThickness:f,opacity:h,strokeDashArray:p,isDigitalLine:g,drawNaNAs:v,lineType:y,containsNaN:void 0}},u.prototype.onAttachSeries=function(){l.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTLineSeriesDrawingProvider;var c=this.getProperties(this.parentSeries),d=c.stroke,f=c.strokeThickness,h=c.opacity,p=c.strokeDashArray;d&&(0,i.createPenInCache)(this.linesPenCache,d,f,h??1,p)},u.prototype.onDetachSeries=function(){l.prototype.onDetachSeries.call(this),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider)},u.prototype.draw=function(c,d){var f,h=this.getProperties(this.parentSeries),p=h.stroke,g=h.isDigitalLine,v=h.lineType,y=h.drawNaNAs,m=h.containsNaN,b=(0,i.getScrtPenFromCache)(this.linesPenCache);if(!(!b||!p)){var S=d.pointSeries,_=this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN;_=m??_,this.args.Reset(),this.args.SetLinesPen(b),this.args.isDigitalLine=g||v!==r.ELineType.Normal,this.args.drawDigitalVertical=v!==r.ELineType.DigitalNoEdge,this.args.digitalYX=v===r.ELineType.DigitalYX,this.args.forceShaderMethod=!0,this.args.containsNaN=_,this.parentSeries.xAxis.isLinearAxis?this.args.forceClamp=!this.args.isDigitalLine:this.args.forceClamp=!1,this.args.lineGaps=_?y===n.ELineDrawMode.DiscontinuousLine?this.webAssemblyContext.SCRTLineGapMode.DrawGaps:this.webAssemblyContext.SCRTLineGapMode.CloseGaps:this.webAssemblyContext.SCRTLineGapMode.Default,this.args.verticalChart=d.isVerticalChart;var C=d.xCoordinateCalculator.isCategoryCoordinateCalculator,P=this.parentSeries.dataSeries,x=P.fifoCapacity,E=P.fifoSweeping,A=P.fifoSweepingGap,R=S.fifoStartIndex,M=this.xSelector(S),D=C?S.indexes:M,F=this.ySelector(S),I=this.getStartAndCount(d,D),V=I.startIndex,z=I.count;this.args.count=z,this.args.startIndex=V,E&&x===this.parentSeries.dataSeries.count()&&(this.args.count=R),this.applyStrokePaletting(b,d),this.palettingState.palettedColors&&(this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=(f=this.palettingState.paletteStartIndex)!==null&&f!==void 0?f:0),this.updateArgs(d);var G=c.getNativeContext();this.drawLines(c,G,D,F,d.xCoordinateCalculator.nativeCalculator,d.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect),E&&x===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(F.size(),R+A),this.args.count=Math.max(0,F.size()-R-A),this.args.count>0&&this.drawLines(c,G,D,F,d.xCoordinateCalculator.nativeCalculator,d.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect))}},u.prototype.delete=function(){this.linesPenCache=(0,e.deleteSafe)(this.linesPenCache),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),l.prototype.delete.call(this)},u.prototype.drawLines=function(c,d,f,h,p,g,v,y){v.SetNativeContext(d),v.SetXValues(f),v.SetYValues(h),v.SetXCoordinateCalculator(p),v.SetYCoordinateCalculator(g),this.nativeDrawingProvider.DrawLinesVec(v)},u})(a.BaseSeriesDrawingProvider);return uw.LineSeriesDrawingProvider=s,uw}var cw={},i_e;function Gje(){if(i_e)return cw;i_e=1;var t=cw&&cw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(cw,"__esModule",{value:!0}),cw.LineSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l,u){u===void 0&&(u=e.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var c=this.getTranslatedHitTestPoint(s,l);if(!c)return n.HitTestInfo.empty();var d=this.currentRenderPassData.isVerticalChart,f=d?c.y:c.x,h=d?c.x:c.y,p=this.parentSeries.dataSeries.dataDistributionCalculator.isSortedAscending;return p?this.hitTestSorted(f,h,u):this.hitTestUnsorted(f,h,u)},a.prototype.hitTestSorted=function(s,l,u){var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=this.parentSeries.dataSeries;if(!p)return n.HitTestInfo.empty();var g=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,p,s,p.dataDistributionCalculator.isSortedAscending),v=p.getNativeXValues(),y=this.parentSeries.getNativeYValues(),m=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,p,v,y,s,l,g,u,void 0);if(g>=0){var b=v.size(),S=d.getCoordinate(d.isCategoryCoordinateCalculator?g:v.get(g));if(g===b-1&&(d.hasFlippedCoordinates?s>=S:s<=S)||g===0&&(d.hasFlippedCoordinates?s<=S:s>=S))m.isHit=i.hitTestHelpers.testIsHitForPoint(d,f,v,y,g,s,l,u,p);else{var _=i.hitTestHelpers.testIsHitForLine(d,f,v,y,g,s,l,u,p);m.isHit=_.isHit,m.point2dataSeriesIndex=_.secondPointIndex,m.point2xValue=v.get(_.secondPointIndex),m.point2xCoord=d.getCoordinate(m.point2xValue),m.point2yValue=y.get(_.secondPointIndex),m.point2yCoord=f.getCoordinate(m.point2yValue),m.point2metadata=p.getMetadataAt(_.secondPointIndex);var C=p.valueNames.reduce(function(P,x){return P[x]=p.getNativeValue(p.getYValuesByName(x),m.point2dataSeriesIndex),P},{});m.point2yValueByName=C}}else m.isHit=!1;return m},a.prototype.hitTestUnsorted=function(s,l,u){var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=this.parentSeries.dataSeries;if(!p)return n.HitTestInfo.empty();var g=i.hitTestHelpers.getNearestXyPoint(this.webAssemblyContext,d,f,p,s,l,u),v=p.getNativeXValues(),y=this.parentSeries.getNativeYValues(),m=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,p,v,y,s,l,g.nearestPointIndex,u,g.distance);if(g.nearestPointIndex>=0){var b=v.size(),S=function(D){return v.get(D)},_=function(D){return y.get(D)},C=function(D){return v.get(D+1)},P=function(D){return y.get(D+1)},x=i.hitTestHelpers.getNearestLineSegment(d,f,b-1,S,_,C,P,s,l,u),E=x.isHit,A=x.isWithinDataBounds,R=x.nearestPointIndex;if(R!==-1){m.dataSeriesIndex=R,m.isWithinDataBounds=A,m.isHit=E,m.xValue=v.get(R),m.xCoord=d.getCoordinate(m.xValue),m.yValue=y.get(R),m.yCoord=f.getCoordinate(m.yValue),m.point2dataSeriesIndex=R+1,m.point2xValue=v.get(R+1),m.point2xCoord=d.getCoordinate(m.point2xValue),m.point2yValue=y.get(R+1),m.point2yCoord=f.getCoordinate(m.point2yValue),m.point2metadata=p.getMetadataAt(R+1);var M=p.valueNames.reduce(function(D,F){return D[F]=p.getNativeValue(p.getYValuesByName(F),m.point2dataSeriesIndex),D},{});return m.point2yValueByName=M,m}}return m.isHit=!1,m},a})(e.BaseHitTestProvider);return cw.LineSeriesHitTestProvider=r,cw}var n_e;function mm(){return n_e||(n_e=1,(function(t){var e=hB&&hB.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.BaseLineRenderableSeries=t.ELineType=void 0;var i=ju(),n=un(),r=Hie(),o=Yf(),a=Gje(),s;(function(u){u.Normal="Normal",u.Digital="Digital",u.DigitalNoEdge="DigitalNoEdge",u.DigitalYX="DigitalYX"})(s=t.ELineType||(t.ELineType={}));var l=(function(u){e(c,u);function c(d,f){var h=this,p;return h=u.call(this,d,f)||this,h.strokeDashArrayProperty=[],h.lineTypeProperty=s.Normal,h.strokeDashArrayProperty=f==null?void 0:f.strokeDashArray,h.lineTypeProperty=(p=f==null?void 0:f.lineType)!==null&&p!==void 0?p:h.lineTypeProperty,f!=null&&f.animation&&h.animationQueue.push(f.animation),h}return c.prototype.addDrawingProviders=function(d,f){this.drawingProviders.push(new r.LineSeriesDrawingProvider(d,this)),this.drawingProviders.push(new o.PointMarkerDrawingProvider(d,this))},c.prototype.applyTheme=function(d){u.prototype.applyTheme.call(this,d);var f=this.parentSurface.previousThemeProvider;this.stroke===f.lineSeriesColor&&(this.stroke=d.lineSeriesColor)},Object.defineProperty(c.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(d){this.strokeDashArrayProperty=d,this.notifyPropertyChanged(n.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"lineType",{get:function(){return this.lineTypeProperty},set:function(d){this.lineTypeProperty=d,this.notifyPropertyChanged(n.PROPERTY.LINE_TYPE)},enumerable:!1,configurable:!0}),c.prototype.toJSON=function(d){d===void 0&&(d=!1);var f=u.prototype.toJSON.call(this,d),h={strokeDashArray:this.strokeDashArray,lineType:this.lineTypeProperty};return Object.assign(f.options,h),f},c.prototype.newHitTestProvider=function(){return new a.LineSeriesHitTestProvider(this,this.webAssemblyContext)},c})(i.BaseRenderableSeries);t.BaseLineRenderableSeries=l})(hB)),hB}var o_e;function Yje(){if(o_e)return lw;o_e=1;var t=lw&&lw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(lw,"__esModule",{value:!0}),lw.FastLineRenderableSeries=void 0;var e=hn(),i=mm(),n=fR(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.type=e.ESeriesType.LineSeries,u.dataLabelProviderProperty||(u.dataLabelProviderProperty=new n.LineSeriesDataLabelProvider(l==null?void 0:l.dataLabels),u.dataLabelProviderProperty.onAttach(u.webAssemblyContext,u)),!((c=u.paletteProvider)===null||c===void 0)&&c.onAttached&&((d=u.paletteProvider)===null||d===void 0||d.onAttached(u)),u}return a})(i.BaseLineRenderableSeries);return lw.FastLineRenderableSeries=r,lw}var dw={},fw={},hw={},a_e;function qje(){if(a_e)return hw;a_e=1;var t=hw&&hw.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(hw,"__esModule",{value:!0}),hw.MountainSeriesDrawingProvider=void 0;var e=Br(),i=tu(),n=Ls(),r=Iu(),o=Sn(),a=un(),s=du(),l=(function(u){t(c,u);function c(d,f){var h=u.call(this,d,f)||this;return h.nativeDrawingProvider=new h.webAssemblyContext.SCRTMountainSeriesDrawingProvider,h.args=new h.webAssemblyContext.SCRTMountainDrawingParams,h.strokePenCache=new n.Pen2DCache(d),h.fillBrushCache=new i.BrushCache(d),h}return c.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),u.prototype.delete.call(this)},c.prototype.draw=function(d,f){var h,p=f.pointSeries,g=this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN;this.args.Reset(),this.args.forceShaderMethod=!0,this.args.lineGaps=g?this.parentSeries.drawNaNAs===r.ELineDrawMode.DiscontinuousLine?this.webAssemblyContext.SCRTLineGapMode.DrawGaps:this.webAssemblyContext.SCRTLineGapMode.CloseGaps:this.webAssemblyContext.SCRTLineGapMode.Default,this.args.verticalChart=f.isVerticalChart;var v=f.getyCoordinateCalculator(),y=v.visibleMin,m=v.visibleMax;this.args.zeroLineY=Math.max(Math.min(this.parentSeries.zeroLineY,m),y),this.args.isDigitalLine=this.parentSeries.isDigitalLine;var b=this.createBrush();b&&this.args.SetFillBrush(b);var S=(0,n.getScrtPenFromCache)(this.strokePenCache);S&&this.args.SetLinesPen(S),u.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,S,this.parentSeries.fill,b,this.parentSeries.opacity,!0,this.parentSeries.fillLinearGradient!==void 0,f);var _=(h=this.palettingState.paletteTextureCache)===null||h===void 0?void 0:h.value;_&&this.args.SetPalette(_),this.args.isSmoothColors=this.palettingState.gradientPaletting;var C=this.parentSeries.dataSeries,P=C.fifoCapacity,x=C.fifoSweeping,E=C.fifoSweepingGap,A=p.fifoStartIndex,R=f.xCoordinateCalculator.isCategoryCoordinateCalculator,M=p.xValues,D=R?p.indexes:M,F=p.yValues,I=this.getStartAndCount(f,D),V=I.startIndex,z=I.count;this.args.count=z,this.args.startIndex=V,x&&P===this.parentSeries.dataSeries.count()&&(this.args.count=A);var G=d.getNativeContext();this.parentSeries.parentSurface.seriesViewRect,this.args.SetNativeContext(G),this.args.SetXValues(D),this.args.SetYValues(F),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPointsVec(this.args),x&&P===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(F.size(),A+E),this.args.count=Math.max(0,F.size()-A-E),this.args.count>0&&this.nativeDrawingProvider.DrawPointsVec(this.args))},c.prototype.onDpiChanged=function(d){u.prototype.onDpiChanged.call(this,d),this.onSeriesPropertyChange(a.PROPERTY.STROKE)},c.prototype.onSeriesPropertyChange=function(d){u.prototype.onSeriesPropertyChange.call(this,d),(d===a.PROPERTY.STROKE||d===a.PROPERTY.STROKE_DASH_ARRAY||d===a.PROPERTY.STROKE_THICKNESS||d===a.PROPERTY.OPACITY)&&this.createPen(),(d===a.PROPERTY.FILL||d===a.PROPERTY.OPACITY||d===a.PROPERTY.FILL_LINEAR_GRADIENT)&&this.createBrush()},c.prototype.onAttachSeries=function(){u.prototype.onAttachSeries.call(this),this.createPen(),this.createBrush()},c.prototype.createBrush=function(){this.palettingState.requiresUpdate=!0;var d=this.parentSeries,f=d.fill,h=d.opacity,p=d.fillLinearGradient,g=d.parentSurface,v=d.customTextureOptions,y=g!=null&&g.isCopyCanvasSurface?g.domCanvas2D.height/o.SciChartSurfaceBase.domMasterCanvas.height:1,m=g!=null&&g.isCopyCanvasSurface?g.domCanvas2D.width/o.SciChartSurfaceBase.domMasterCanvas.width:1;return this.fillBrushCache.create(f,h,y,m,p,v),(0,i.getScrtBrushFromCache)(this.fillBrushCache)},c.prototype.createPen=function(){var d=this.parentSeries,f=d.stroke,h=d.strokeThickness,p=d.opacity,g=d.strokeDashArray;return this.palettingState.requiresUpdate=!0,(0,n.createPenInCache)(this.strokePenCache,f,h,p,g)},c})(s.BaseSeriesDrawingProvider);return hw.MountainSeriesDrawingProvider=l,hw}var pw={},s_e;function Xje(){if(s_e)return pw;s_e=1;var t=pw&&pw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(pw,"__esModule",{value:!0}),pw.MountainSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries,y=v.dataSeries;if(!y)return n.HitTestInfo.empty();var m=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,y,p,y.dataDistributionCalculator.isSortedAscending),b=y.getNativeXValues(),S=y.getNativeYValues(),_=i.hitTestHelpers.createHitTestInfo(v,d,f,h,y,b,S,p,g,m,0);if(y.dataDistributionCalculator.isSortedAscending&&m>=0){var C=i.hitTestHelpers.testIsHitForMountain(this.parentSeries.isDigitalLine,d,f,y,v.zeroLineY,m,p,g);if(_.isHit=C.isHit,_.point2dataSeriesIndex=C.secondPointIndex,C.secondPointIndex!==void 0){_.point2xValue=b.get(C.secondPointIndex),_.point2xCoord=d.getCoordinate(_.point2xValue),_.point2yValue=S.get(C.secondPointIndex),_.point2yCoord=f.getCoordinate(_.point2yValue),_.point2metadata=y.getMetadataAt(C.secondPointIndex);var P=y.valueNames.reduce(function(x,E){return x[E]=y.getNativeValue(y.getYValuesByName(E),_.point2dataSeriesIndex),x},{});_.point2yValueByName=P}}else _.isHit=!1;return _},a})(e.BaseHitTestProvider);return pw.MountainSeriesHitTestProvider=r,pw}var l_e;function $W(){if(l_e)return fw;l_e=1;var t=fw&&fw.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(fw,"__esModule",{value:!0}),fw.BaseMountainRenderableSeries=void 0;var e=Xs(),i=Sn(),n=ju(),r=un(),o=qje(),a=Yf(),s=Xje(),l=(function(u){t(c,u);function c(d,f){var h=this,p,g,v,y,m;return h=u.call(this,d,f)||this,h.zeroLineYProperty=0,h.fillProperty=i.SciChartSurfaceBase.DEFAULT_THEME.mountainAreaBrush,h.strokeDashArrayProperty=[],h.stroke=(p=f==null?void 0:f.stroke)!==null&&p!==void 0?p:i.SciChartSurfaceBase.DEFAULT_THEME.mountainLineColor,h.strokeDashArrayProperty=(g=f==null?void 0:f.strokeDashArray)!==null&&g!==void 0?g:h.strokeDashArrayProperty,h.fillProperty=(v=f==null?void 0:f.fill)!==null&&v!==void 0?v:h.fillProperty,h.zeroLineYProperty=(y=f==null?void 0:f.zeroLineY)!==null&&y!==void 0?y:h.zeroLineYProperty,h.fillLinearGradientProperty=(m=f==null?void 0:f.fillLinearGradient)!==null&&m!==void 0?m:h.fillLinearGradientProperty,h.customTextureOptionsProperty=f==null?void 0:f.customTextureOptions,f!=null&&f.animation&&h.animationQueue.push(f.animation),h}return c.prototype.addDrawingProviders=function(d,f){this.drawingProviders.push(new o.MountainSeriesDrawingProvider(d,this)),this.drawingProviders.push(new a.PointMarkerDrawingProvider(d,this))},c.prototype.applyTheme=function(d){u.prototype.applyTheme.call(this,d);var f=this.parentSurface.previousThemeProvider;this.fill===f.mountainAreaBrush&&(this.fill=d.mountainAreaBrush),this.stroke===f.mountainLineColor&&(this.stroke=d.mountainLineColor)},Object.defineProperty(c.prototype,"fill",{get:function(){return(0,e.stripAutoColor)(this.fillProperty)},set:function(d){this.fillProperty=d,this.notifyPropertyChanged(r.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"zeroLineY",{get:function(){return this.zeroLineYProperty},set:function(d){this.zeroLineYProperty=d,this.notifyPropertyChanged(r.PROPERTY.ZERO_LINE_Y)},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(d){d!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=d,this.notifyPropertyChanged(r.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(d){d!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=d,this.notifyPropertyChanged(r.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),Object.defineProperty(c.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(d){this.strokeDashArrayProperty=d,this.notifyPropertyChanged(r.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),c.prototype.toJSON=function(d){d===void 0&&(d=!1);var f=u.prototype.toJSON.call(this,d),h={fill:this.fill,fillLinearGradient:this.fillLinearGradient,strokeDashArray:this.strokeDashArray,zeroLineY:this.zeroLineY};return Object.assign(f.options,h),f},c.prototype.resolveAutoColors=function(d,f,h){if(u.prototype.resolveAutoColors.call(this,d,f,h),this.fillProperty.startsWith(e.AUTO_COLOR)){var p=h.getFillColor(d,f,this.webAssemblyContext);this.fill=e.AUTO_COLOR+this.adjustAutoColor("fill",p)}},c.prototype.newHitTestProvider=function(){return new s.MountainSeriesHitTestProvider(this,this.webAssemblyContext)},c})(n.BaseRenderableSeries);return fw.BaseMountainRenderableSeries=l,fw}var u_e;function Kje(){if(u_e)return dw;u_e=1;var t=dw&&dw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(dw,"__esModule",{value:!0}),dw.FastMountainRenderableSeries=void 0;var e=hn(),i=$W(),n=Wv(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.type=e.ESeriesType.MountainSeries,u.dataLabelProviderProperty||(u.dataLabelProviderProperty=new n.DataLabelProvider(l==null?void 0:l.dataLabels),u.dataLabelProviderProperty.onAttach(u.webAssemblyContext,u)),!((c=u.paletteProvider)===null||c===void 0)&&c.onAttached&&((d=u.paletteProvider)===null||d===void 0||d.onAttached(u)),u}return a})(i.BaseMountainRenderableSeries);return dw.FastMountainRenderableSeries=r,dw}var gw={},c_e;function Zje(){if(c_e)return gw;c_e=1;var t=gw&&gw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(gw,"__esModule",{value:!0}),gw.FastOhlcRenderableSeries=void 0;var e=hn(),i=Vie(),n=o$(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;return u=o.call(this,s,l)||this,u.type=e.ESeriesType.OhlcSeries,!((c=u.paletteProvider)===null||c===void 0)&&c.onAttached&&((d=u.paletteProvider)===null||d===void 0||d.onAttached(u)),u.drawingProviders=[],u.drawingProviders.push(new n.OhlcSeriesDrawingProvider(s,u,n.EOhlcDrawingMode.Ohlc)),u}return a})(i.BaseOhlcRenderableSeries);return gw.FastOhlcRenderableSeries=r,gw}var vw={},yw={},d_e;function Jje(){if(d_e)return yw;d_e=1;var t=yw&&yw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(yw,"__esModule",{value:!0}),yw.TextSeriesHitTestProvider=void 0;var e=Eo(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u,c){var d=this.getTranslatedHitTestPoint(l,u);if(!d)return r.HitTestInfo.empty();for(var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries,b=n.hitTestHelpers.getNearestXyPoint(this.webAssemblyContext,h,p,m,v,y,c),S=m.getNativeXValues(),_=m.getNativeYValues(),C=n.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,m,S,_,v,y,b.nearestPointIndex,c,b.distance),P=this.parentSeries.dataLabelProvider.dataLabels,x=!1,E=0,A=P;E<A.length;E++){var R=A[E],M=R.rect,D=M.left,F=M.top,I=M.right,V=M.bottom;if((0,e.testIsInBounds)(d.x,d.y,D,F,I,V)){x=!0;break}}return C.isHit=x,C},s})(i.BaseHitTestProvider);return yw.TextSeriesHitTestProvider=o,yw}var f_e;function Uie(){if(f_e)return vw;f_e=1;var t=vw&&vw.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(vw,"__esModule",{value:!0}),vw.FastTextRenderableSeries=void 0;var e=hn(),i=Om(),n=ju(),r=HW(),o=Yf(),a=Jje(),s=(function(l){t(u,l);function u(c,d){var f=l.call(this,c,d)||this;return f.type=e.ESeriesType.TextSeries,f.dataLabelProviderProperty||(f.dataLabelProviderProperty=new r.TextDataLabelProvider(d==null?void 0:d.dataLabels),f.dataLabelProviderProperty.onAttach(f.webAssemblyContext,f)),d!=null&&d.animation&&f.animationQueue.push(d.animation),f}return u.prototype.addDrawingProviders=function(c,d){this.drawingProviders.push(new o.PointMarkerDrawingProvider(c,this))},u.prototype.needsResampling=function(c){return this.dataSeries.fifoCapacity?(c.resamplingMode=i.EResamplingMode.None,this.resamplerHelper.resetAndFillBasicNativeArgs(c,this.getNativeXValues()),!0):!1},u.prototype.newHitTestProvider=function(){return new a.TextSeriesHitTestProvider(this,this.webAssemblyContext)},u})(n.BaseRenderableSeries);return vw.FastTextRenderableSeries=s,vw}var mw={},a7={},h_e;function WW(){return h_e||(h_e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EShaderEffectType=void 0,(function(e){e.Glow="Glow",e.Shadow="Shadow"})(t.EShaderEffectType||(t.EShaderEffectType={}))})(a7)),a7}var bw={},Sw={},p_e;function X3(){if(p_e)return Sw;p_e=1,Object.defineProperty(Sw,"__esModule",{value:!0}),Sw.fromTsrVector4=Sw.updateTsrVector4=void 0;var t=ci(),e=function(n,r){t.Guard.notNull(n,"color");var o=1/255;r.x=n.red*o,r.y=n.green*o,r.z=n.blue*o,r.w=n.opacity*o};Sw.updateTsrVector4=e;var i=function(n){return t.Guard.notNull(n,"tsrColor"),{red:Math.round(n.x*255),green:Math.round(n.y*255),blue:Math.round(n.z*255),opacity:Math.round(n.w*255)}};return Sw.fromTsrVector4=i,Sw}var g_e;function zie(){if(g_e)return bw;g_e=1;var t=bw&&bw.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(bw,"__esModule",{value:!0}),bw.ShaderEffect=void 0;var e=Uo(),i=Br(),n=ps(),r=ci(),o=$i(),a=KP(),s=Ti(),l=X3(),u=un(),c=an(),d=fo(),f=(function(h){t(p,h);function p(g,v,y){var m=h.call(this)||this;return r.Guard.notNull(g,"webAssemblyContext"),e.IS_TEST_ENV||r.Guard.notNull(v,"seriesEffect"),m.webAssemblyContext=g,m.propertyChanged=new n.EventHandler,m.nativeEffect=v,m.intensity=(y==null?void 0:y.intensity)||1,m.range=(y==null?void 0:y.range)||0,m.offset=(y==null?void 0:y.offset)||new o.Point(0,0),m.color=(y==null?void 0:y.color)||"#444444",m}return p.prototype.delete=function(){this.nativeEffect=(0,i.deleteSafe)(this.nativeEffect),this.webAssemblyContext=void 0},p.prototype.getNativeEffect=function(){return this.nativeEffect},Object.defineProperty(p.prototype,"intensity",{get:function(){return this.intensityProperty},set:function(g){this.intensityProperty=g,this.nativeEffect.SetIntensity(g),this.notifyPropertyChanged(u.PROPERTY.INTENSITY)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"offset",{get:function(){return this.offsetProperty},set:function(g){r.Guard.notNull(g,"offset"),this.offsetProperty=g;var v=new this.webAssemblyContext.TSRVector2(g.x,g.y);this.nativeEffect.SetOffset(v),v.delete(),this.notifyPropertyChanged(u.PROPERTY.OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"color",{get:function(){return this.colorProperty},set:function(g){this.colorProperty=g;var v=(0,s.parseColorToTArgb)(g),y=(0,c.getVector4)(this.webAssemblyContext,0,0,0,0);(0,l.updateTsrVector4)(v,y),this.nativeEffect.SetColor(y),this.notifyPropertyChanged(u.PROPERTY.COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"range",{get:function(){return this.rangeProperty},set:function(g){this.rangeProperty=g,this.nativeEffect.SetRange(g),this.notifyPropertyChanged(u.PROPERTY.RANGE)},enumerable:!1,configurable:!0}),p.prototype.notifyPropertyChanged=function(g){var v;(v=this.propertyChanged)===null||v===void 0||v.raiseEvent(new a.PropertyChangedEventArgs(g))},p.prototype.toJSON=function(){var g={color:this.color,intensity:this.intensity,offset:this.offset,range:this.range};return{type:this.type,options:g}},p})(d.DeletableEntity);return bw.ShaderEffect=f,bw}var v_e;function Qje(){if(v_e)return mw;v_e=1;var t=mw&&mw.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(mw,"__esModule",{value:!0}),mw.GlowEffect=void 0;var e=WW(),i=zie(),n=(function(r){t(o,r);function o(a,s){var l=r.call(this,a,new a.SCRTGlowEffect,{range:(s==null?void 0:s.range)||1,intensity:(s==null?void 0:s.intensity)||1})||this;return l.type=e.EShaderEffectType.Glow,l}return o})(i.ShaderEffect);return mw.GlowEffect=n,mw}var _w={},pB={},gB={},y_e;function GW(){if(y_e)return gB;y_e=1,Object.defineProperty(gB,"__esModule",{value:!0}),gB.HeatmapColorMap=void 0;var t=ps(),e=KP(),i=un(),n=(function(){function r(o){var a,s;this.minimumProperty=(a=o==null?void 0:o.minimum)!==null&&a!==void 0?a:0,this.maximumProperty=(s=o==null?void 0:o.maximum)!==null&&s!==void 0?s:100,this.gradientStops=(o==null?void 0:o.gradientStops)||[{offset:0,color:"Red"},{offset:1,color:"Green"}],this.propertyChanged=new t.EventHandler,this.calculateScaleFactor()}return Object.defineProperty(r.prototype,"gradientStops",{get:function(){return this.gradientStopsProperty},set:function(o){this.gradientStopsProperty=o,this.notifyPropertyChanged(i.PROPERTY.GRADIENT_STOPS)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"minimum",{get:function(){return this.minimumProperty},set:function(o){this.minimumProperty=o,this.notifyPropertyChanged(i.PROPERTY.MINIMUM)},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"maximum",{get:function(){return this.maximumProperty},set:function(o){this.maximumProperty=o,this.notifyPropertyChanged(i.PROPERTY.MAXIMUM)},enumerable:!1,configurable:!0}),r.prototype.toJSON=function(){return{minimum:this.minimum,maximum:this.maximum,gradientStops:this.gradientStops}},r.prototype.notifyPropertyChanged=function(o){var a;(a=this.propertyChanged)===null||a===void 0||a.raiseEvent(new e.PropertyChangedEventArgs(o))},r.prototype.calculateScaleFactor=function(){this.scaleFactorProperty=(r.DefaultPrecision-1)/Math.abs(this.maximumProperty-this.minimumProperty)},r.DefaultPrecision=1e3,r})();return gB.HeatmapColorMap=n,gB}var m_e;function zI(){return m_e||(m_e=1,(function(t){var e=pB&&pB.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.BaseHeatmapRenderableSeries=t.COLOR_MAP_PREFIX=void 0;var i=mo(),n=Br(),r=ga(),o=Rm(),a=ju(),s=un(),l=GW();t.COLOR_MAP_PREFIX="colorMap.";var u=(function(c){e(d,c);function d(f,h){var p=this,g,v,y,m,b;return p=c.call(this,f,h)||this,p.useLinearTextureFilteringProperty=!1,p.fillValuesOutOfRangeProperty=!0,p.colorMapPropertyChanged=p.colorMapPropertyChanged.bind(p),h!=null&&h.colorMap&&("toJSON"in h.colorMap||(h.colorMap=new l.HeatmapColorMap(h.colorMap))),p.colorMap=h==null?void 0:h.colorMap,p.xAxisId=h==null?void 0:h.xAxisId,p.yAxisId=h==null?void 0:h.yAxisId,p.useLinearTextureFilteringProperty=(g=h==null?void 0:h.useLinearTextureFiltering)!==null&&g!==void 0?g:p.useLinearTextureFilteringProperty,p.fillValuesOutOfRangeProperty=(v=h==null?void 0:h.fillValuesOutOfRange)!==null&&v!==void 0?v:p.fillValuesOutOfRangeProperty,p.dataSeries=h==null?void 0:h.dataSeries,!((y=p.paletteProvider)===null||y===void 0)&&y.onAttached&&((m=p.paletteProvider)===null||m===void 0||m.onAttached(p)),h!=null&&h.zLabelProvider&&("getLabels"in(h==null?void 0:h.zLabelProvider)||(h.zLabelProvider=(0,i.createType)(r.EBaseType.LabelProvider,h.zLabelProvider.type,f,h.zLabelProvider.options))),p.zLabelProviderProperty=(b=h==null?void 0:h.zLabelProvider)!==null&&b!==void 0?b:new o.NumericLabelProvider({labelPrecision:2}),p}return Object.defineProperty(d.prototype,"colorMap",{get:function(){return this.colorMapProperty},set:function(f){var h,p;(h=this.colorMapProperty)===null||h===void 0||h.propertyChanged.unsubscribe(this.colorMapPropertyChanged),this.colorMapProperty=f,(p=this.colorMapProperty)===null||p===void 0||p.propertyChanged.subscribe(this.colorMapPropertyChanged),this.notifyPropertyChanged(s.PROPERTY.COLOR_MAP)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"useLinearTextureFiltering",{get:function(){return this.useLinearTextureFilteringProperty},set:function(f){this.useLinearTextureFilteringProperty=f,this.notifyPropertyChanged(s.PROPERTY.USE_LINEAR_TEXTURE_FILTERING)},enumerable:!1,configurable:!0}),d.prototype.checkIsOutOfDataRange=function(f,h){var p=this.dataSeries;return!p||f<=p.xRange.min||f>=p.xRange.max||h<=p.yRange.min||h>=p.yRange.max},Object.defineProperty(d.prototype,"zLabelProvider",{get:function(){return this.zLabelProviderProperty},set:function(f){this.zLabelProviderProperty=f,this.notifyPropertyChanged(s.PROPERTY.Z_LABEL_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"fillValuesOutOfRange",{get:function(){return this.fillValuesOutOfRangeProperty},set:function(f){this.fillValuesOutOfRangeProperty=f,this.notifyPropertyChanged(s.PROPERTY.FILL_VALUES_OUT_OF_RANGE)},enumerable:!1,configurable:!0}),d.prototype.toPointSeries=function(f){},d.prototype.toJSON=function(f){var h,p;f===void 0&&(f=!1);var g=c.prototype.toJSON.call(this,f),v={colorMap:(h=this.colorMap)===null||h===void 0?void 0:h.toJSON(),fillValuesOutOfRange:this.fillValuesOutOfRange,useLinearTextureFiltering:this.useLinearTextureFiltering,zLabelProvider:(p=this.zLabelProvider)===null||p===void 0?void 0:p.toJSON()};return Object.assign(g.options,v),g},d.prototype.delete=function(){this.zLabelProviderProperty=(0,n.deleteSafe)(this.zLabelProviderProperty),c.prototype.delete.call(this)},d.prototype.colorMapPropertyChanged=function(f){this.notifyPropertyChanged(t.COLOR_MAP_PREFIX+f.propertyName)},d})(a.BaseRenderableSeries);t.BaseHeatmapRenderableSeries=u})(pB)),pB}var Db={},vB={},b_e;function NO(){return b_e||(b_e=1,(function(t){var e=vB&&vB.__spreadArray||function(f,h,p){if(p||arguments.length===2)for(var g=0,v=h.length,y;g<v;g++)(y||!(g in h))&&(y||(y=Array.prototype.slice.call(h,0,g)),y[g]=h[g]);return f.concat(y||Array.prototype.slice.call(h))};Object.defineProperty(t,"__esModule",{value:!0}),t.calculateHeatmapTexture=t.calculateCellCoordinates=t.calculateOffsets=t.createColorMap=t.getCellColor=t.getColor=t.getColorDataForTexture=void 0;var i=Ju(),n=Ti(),r=function(f,h,p){var g=f.xStartInd,v=f.textureWidth,y=f.xInc,m=f.yStartInd,b=f.textureHeight,S=f.yInc,_=f.zValues,C=f.webAssemblyContext,P=f.colorMap,x=f.opacity,E=f.horCellCount;f.vertCellCount;var A=f.horCellOffsets,R=f.vertCellOffsets,M=f.colorMin,D=f.colorMax,F=f.arrayWidth,I=f.arrayHeight,V=f.fillValuesOutOfRange;h.resize(v*b,0);for(var z=0,G=R[z],H=new Array(E),U=!1,k=g,X=m,W,Y=0;Y<b;Y++){var te=0,oe=A[te];if(Y>G){U=!1,z++,G=R[z];var de=Y-G;if(de>Number.EPSILON&&Math.floor(G)+1===Y){Y--;continue}}U?W=H[te]:(k=g+te*y,X=m+z*S,W=(0,t.getColor)(X,k,P,x,_,C,M,D,F,I,V,p),H[te]=W);for(var ge=0;ge<v;ge++){if(ge>oe){te++,oe=A[te];var Ee=ge-oe;if(Ee>Number.EPSILON&&Math.floor(oe)+1===ge){ge--;continue}U?W=H[te]:(k=g+te*y,W=(0,t.getColor)(X,k,P,x,_,C,M,D,F,I,V,p),H[te]=W)}h.set(Y*v+ge,W)}U=!0}return h};t.getColorDataForTexture=r;var o=function(f,h,p,g,v,y,m,b,S,_,C,P){if(f>=_||h>=S)return 0;var x=v[f][h],E=(0,t.getCellColor)(x,p,m,b,C,y,P);return(0,i.uintArgbColorMultiplyOpacity)(E,g)};t.getColor=o;var a=function(f,h,p,g,v,y,m){if(isNaN(f))return 0;if(v)f=f<p?p:f,f=f>g?g:f;else if(f<p||f>g)return 0;var b=(m-1)/Math.abs(g-p),S=(f-p)*b,_=Math.floor(S+Math.sign(f)*.5);return _=y.NumberUtil.Constrain(_,0,h.length-1),h[_]};t.getCellColor=a;var s=function(f,h){var p=Array.from(Array(h)),g=e([],f,!0);g.sort(function(F,I){return F.offset<I.offset?-1:F.offset>I.offset?1:0});var v=g.length,y=g[0].offset,m=g[g.length-1].offset,b=m-y,S=b/(h-1),_=g[0].color,C=g[0].offset,P=_,x=C;v>1&&(P=g[1].color,x=g[1].offset),b=x-C;for(var E=0,A=0;A<h;++A){var R=y+A*S;R>=x&&(E++,C=x,_=P,E+1<v&&(P=g[E+1].color,x=g[E+1].offset),b=x-C);var M=void 0;if(_===P||b<=Number.EPSILON)M=Number.parseInt((0,n.parseColorToHexStringArgb)(P),16);else{var D=(R-C)/b;M=l(_,P,D)}p[A]=M}return p};t.createColorMap=s;var l=function(f,h,p){var g=(0,n.parseColorToTArgb)(f),v=(0,n.parseColorToTArgb)(h),y=g.opacity,m=v.opacity,b=g.red,S=v.red,_=g.green,C=v.green,P=g.blue,x=v.blue,E=b+Math.floor((S-b)*p),A=_+Math.floor((C-_)*p),R=P+Math.floor((x-P)*p),M=y+Math.floor((m-y)*p);return Number.parseInt("0x"+(0,n.toHex)(M)+(0,n.toHex)(E)+(0,n.toHex)(A)+(0,n.toHex)(R),16)},u=function(f,h,p,g,v,y,m,b,S,_,C){var P=f.left<0?-f.left:0,x=f.top<0?-f.top:0;h&&(P=f.right>C.bottom?f.right-C.bottom:0);var E=(0,t.calculateCellCoordinates)(p,f.width,v,y,m,-P),A=(0,t.calculateCellCoordinates)(g,f.height,b,S,_,-x);return{horCellOffsets:E,vertCellOffsets:A}};t.calculateOffsets=u;var c=function(f,h,p,g,v,y){for(var m=0,b=p,S=0;S<g;S++,b+=v)m+=f[b];for(var _=1/m,C=new Array(g),P=y,S=0;S<g-1;S++){var x=S*v+p,E=f[x]*_*h;P=P+E,C[S]=P}return C[g-1]=h+y,C};t.calculateCellCoordinates=c;var d=function(f,h,p,g){var v=f.textureWidth,y=f.textureHeight,m=f.webAssemblyContext,b=f.useInterpolation,S=(0,t.getColorDataForTexture)(f,h,g),_=p.create(v,y,m.eTSRTextureFormat.TSR_TEXTUREFORMAT_A8B8G8R8);return m.SCRTSetTextureLinearSamplerEnabled(_,b),m.SCRTFillTextureAbgr(_,v,y,S),_};t.calculateHeatmapTexture=d})(vB)),vB}var S_e;function e3e(){if(S_e)return Db;S_e=1;var t=Db&&Db.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})(),e=Db&&Db.__rest||function(p,g){var v={};for(var y in p)Object.prototype.hasOwnProperty.call(p,y)&&g.indexOf(y)<0&&(v[y]=p[y]);if(p!=null&&typeof Object.getOwnPropertySymbols=="function")for(var m=0,y=Object.getOwnPropertySymbols(p);m<y.length;m++)g.indexOf(y[m])<0&&Object.prototype.propertyIsEnumerable.call(p,y[m])&&(v[y[m]]=p[y[m]]);return v};Object.defineProperty(Db,"__esModule",{value:!0}),Db.NonUniformHeatmapDrawingProvider=void 0;var i=Br(),n=di(),r=Rn(),o=Are(),a=PW(),s=zI(),l=un(),u=du(),c=NO(),d=ud(),f=100,h=(function(p){t(g,p);function g(v,y){var m=p.call(this,v,y)||this;return m.heatTextureCache=new a.TextureCache(v),m.colorDataVector=new v.UIntVector,m.onSeriesPropertyChange(l.PROPERTY.DATA_SERIES),m.onSeriesPropertyChange(l.PROPERTY.COLOR_MAP),m}return g.prototype.delete=function(){this.colorDataVector=(0,i.deleteSafe)(this.colorDataVector),this.heatTextureCache=(0,i.deleteSafe)(this.heatTextureCache),p.prototype.delete.call(this)},g.prototype.onSeriesPropertyChange=function(v){var y=v===l.PROPERTY.DATA_SERIES||v===l.PROPERTY.COLOR_MAP||v.includes(s.COLOR_MAP_PREFIX)||v===l.PROPERTY.OPACITY;y&&(this.colorGradientScale=(0,c.createColorMap)(this.parentSeries.colorMap.gradientStops,f))},g.prototype.draw=function(v,y){var m=y.isVerticalChart,b=this.parentSeries.dataSeries,S=this.parentSeries.parentSurface.seriesViewRect,_=this.parentSeries.colorMap,C=this.colorGradientScale,P=b.getZValues(),x=b.getXIndicesRange(new n.NumberRange(y.xCoordinateCalculator.visibleMin,y.xCoordinateCalculator.visibleMax),!1),E=b.getYIndicesRange(new n.NumberRange(y.yCoordinateCalculator.visibleMin,y.yCoordinateCalculator.visibleMax),!1),A=b.getXValue(x.min),R=b.getXValue(x.max),M=b.getYValue(E.min),D=b.getYValue(E.max),F=!y.xCoordinateCalculator.hasFlippedCoordinates,I=y.yCoordinateCalculator.hasFlippedCoordinates,V=y.xCoordinateCalculator.getCoordinate(F?R:A),z=y.xCoordinateCalculator.getCoordinate(F?A:R),G=y.yCoordinateCalculator.getCoordinate(I?M:D),H=y.yCoordinateCalculator.getCoordinate(I?D:M),U=Math.ceil(Math.abs(V-z)),k=Math.ceil(Math.abs(G-H)),X=U<=0||k<=0,W=V>(m?S.height:S.width)||G>(m?S.width:S.height)||z<0||H<0;if(!W&&!X){var Y=x,te=E,oe=F?Y.max-1:Y.min,de=I?te.min:te.max-1,ge=F?-1:1,Ee=I?1:-1;m&&(oe=F?Y.min:Y.max-1,ge=F?1:-1);var Re=Y.diff,Ae=te.diff;v.getNativeContext();var Pe=function(we){return we};(this.parentSeries.xAxis.type===d.EAxisType.BaseValueAxis||this.parentSeries.xAxis.type===d.EAxisType.DiscontinuousDateAxis)&&(Pe=function(we){return y.xCoordinateCalculator.getCoordinate(we)}),this.drawHeatmapInTypescript(v,b.xCellOffsets,b.yCellOffsets,P,y.xCoordinateCalculator,y.yCoordinateCalculator,{horCellCount:Re,vertCellCount:Ae,arrayWidth:b.arrayWidth,arrayHeight:b.arrayHeight,opacity:this.parentSeries.opacity,colorGradientScale:C,colorMin:_.minimum,colorMax:_.maximum,horStartInd:oe,vertStartInd:de,horInc:ge,vertInc:Ee,isVerticalChart:m,heatmapStartX:V,heatmapStartY:G,heatmapWidth:U,heatmapHeight:k,xCellSizes:b.getXCellSizes(Pe),yCellSizes:b.getYCellSizes(),seriesViewRect:S})}},g.prototype.drawHeatmapInTypescript=function(v,y,m,b,S,_,C){var P=C.horStartInd,x=C.horInc,E=C.vertStartInd,A=C.vertInc,R=C.horCellCount,M=C.vertCellCount,D=C.heatmapStartX,F=C.heatmapStartY,I=C.heatmapWidth,V=C.heatmapHeight,z=C.opacity,G=C.colorGradientScale,H=C.colorMin,U=C.colorMax,k=C.isVerticalChart,X=C.arrayWidth,W=C.arrayHeight,Y=C.xCellSizes,te=C.yCellSizes,oe=C.seriesViewRect,de=y[0],ge=y[y.length-1],Ee=m[0],Re=m[m.length-1],Ae=Math.max(de,S.visibleMin),Pe=Math.min(ge,S.visibleMax),we=Math.max(Ee,_.visibleMin),Te=Math.min(Re,_.visibleMax),ke=!S.hasFlippedCoordinates,$e=_.hasFlippedCoordinates,Ne=S.getCoordinate(ke?Pe:Ae),ve=S.getCoordinate(ke?Ae:Pe),pe=_.getCoordinate($e?Te:we),fe=_.getCoordinate($e?we:Te),me=Math.ceil(Math.abs(Ne-ve)),Ce=Math.ceil(Math.abs(pe-fe)),Ue=new r.Rect(D,F,I,V),Qe=(0,c.calculateOffsets)(Ue,k,Y,te,P,R,x,E,M,A,oe),it=Qe.horCellOffsets,xt=Qe.vertCellOffsets,wt=this.calculateHeatmapTexture({xStartInd:P,textureWidth:me,xInc:x,yStartInd:E,textureHeight:Ce,yInc:A,zValues:b,webAssemblyContext:this.webAssemblyContext,colorMap:G,opacity:z,horCellCount:R,vertCellCount:M,horCellOffsets:it,vertCellOffsets:xt,colorMin:H,colorMax:U,arrayWidth:X,arrayHeight:W,fillValuesOutOfRange:this.parentSeries.fillValuesOutOfRange,useInterpolation:this.parentSeries.useLinearTextureFiltering});if(v.getNativeContext(),k){var $t=r.Rect.intersect(this.parentSeries.parentSurface.clipRect,oe);v.setTranslationRotationAndClip($t,oe.x-Ce,oe.y+ve+(ke?0:me),-90);var Mt=ke?0:me,rt=pe;v.drawTexture(wt,Mt,rt,me,Ce);return}v.drawTexture(wt,Ne,fe,me,Ce)},g.prototype.calculateHeatmapTexture=function(v){if(!this.getMemoizedHeatmapTexture){var y=function(b,S){var _=b,C=_[0],P=C.horCellOffsets,x=C.vertCellOffsets,E=e(C,["horCellOffsets","vertCellOffsets"]),A=S[0],R=A.horCellOffsets,M=A.vertCellOffsets,D=e(A,["horCellOffsets","vertCellOffsets"]);return m(Object.values(E),Object.values(D))&&m(P,R)&&m(x,M)};this.getMemoizedHeatmapTexture=(0,o.memoize)(c.calculateHeatmapTexture,y)}var m=function(b,S){return!b.some(function(_,C){return _!==S[C]})};return this.getMemoizedHeatmapTexture(v,this.colorDataVector,this.heatTextureCache,f)},g})(u.BaseSeriesDrawingProvider);return Db.NonUniformHeatmapDrawingProvider=h,Db}var Pw={},__e;function t3e(){if(__e)return Pw;__e=1;var t=Pw&&Pw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Pw,"__esModule",{value:!0}),Pw.NonUniformHeatmapHitTestProvider=void 0;var e=$i(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=n.hitTestHelpers.getNearestNonUniformHeatmapPoint(f,h,y,g,v),b=m.xIndex,S=m.yIndex,_=m.zValue,C=new r.HitTestInfo(this.parentSeries);C.seriesName=this.parentSeries.seriesName,C.dataSeriesType=y.type,C.hitTestPoint=new e.Point(g,v);var P=f.getDataValue(g),x=h.getDataValue(v);return C.hitTestPointValues=new e.Point(P,x),C.xValue=P,C.yValue=x,C.heatmapXIndex=b,C.heatmapYIndex=S,C.zValue=_,C.heatmapValue=_,C.xCoord=g,C.yCoord=v,C.isHit=b!==-1&&S!==-1,C.isWithinDataBounds=C.isHit,b!==-1&&S!==-1&&(C.metadata=y.getMetadataAt(S,b)),C},s.prototype.hitTestDataPoint=function(l,u){return this.hitTest(l,u)},s.prototype.hitTestXSlice=function(l,u){return this.hitTest(l,u)},s})(i.BaseHitTestProvider);return Pw.NonUniformHeatmapHitTestProvider=o,Pw}var P_e;function r3e(){if(P_e)return _w;P_e=1;var t=_w&&_w.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(_w,"__esModule",{value:!0}),_w.NonUniformHeatmapRenderableSeries=void 0;var e=Uo(),i=hn(),n=zI(),r=Fie(),o=e3e(),a=t3e(),s=(function(l){t(u,l);function u(c,d){var f=l.call(this,c,d)||this;return f.type=i.ESeriesType.NonUniformHeatmapSeries,f.drawingProviders=[],e.IS_TEST_ENV||f.drawingProviders.push(new o.NonUniformHeatmapDrawingProvider(c,f)),f.dataLabelProviderProperty||(f.dataLabelProviderProperty=new r.NonUniformHeatMapDataLabelProvider(d==null?void 0:d.dataLabels),f.dataLabelProviderProperty.onAttach(f.webAssemblyContext,f)),f}return u.prototype.newHitTestProvider=function(){return new a.NonUniformHeatmapHitTestProvider(this,this.webAssemblyContext)},u})(n.BaseHeatmapRenderableSeries);return _w.NonUniformHeatmapRenderableSeries=s,_w}var Cw={},C_e;function i3e(){if(C_e)return Cw;C_e=1;var t=Cw&&Cw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Cw,"__esModule",{value:!0}),Cw.ShadowEffect=void 0;var e=$i(),i=WW(),n=zie(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,new s.SCRTShadowEffect,{offset:(l==null?void 0:l.offset)||new e.Point(10,10),range:(l==null?void 0:l.range)||1,color:l?"rgba(".concat((l==null?void 0:l.brightness)||68,",").concat((l==null?void 0:l.brightness)||68,",").concat((l==null?void 0:l.brightness)||68,",1)"):"#444444"})||this;return u.type=i.EShaderEffectType.Shadow,u}return a})(n.ShaderEffect);return Cw.ShadowEffect=r,Cw}var Tw={},xw={},_f={},Ew={},T_e;function n3e(){if(T_e)return Ew;T_e=1;var t=Ew&&Ew.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Ew,"__esModule",{value:!0}),Ew.XyzPointSeriesResampled=void 0;var e=Yo(),i=jI(),n=(function(r){t(o,r);function o(a,s){return r.call(this,a,s,2,[e.EValueName.Y,e.EValueName.Z])||this}return Object.defineProperty(o.prototype,"zValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),o})(i.BasePointSeriesResampled);return Ew.XyzPointSeriesResampled=n,Ew}var x_e;function Cv(){if(x_e)return _f;x_e=1;var t=_f&&_f.__extends||(function(){var v=function(y,m){return v=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(b,S){b.__proto__=S}||function(b,S){for(var _ in S)Object.prototype.hasOwnProperty.call(S,_)&&(b[_]=S[_])},v(y,m)};return function(y,m){if(typeof m!="function"&&m!==null)throw new TypeError("Class extends value "+String(m)+" is not a constructor or null");v(y,m);function b(){this.constructor=y}y.prototype=m===null?Object.create(m):(b.prototype=m.prototype,new b)}})();Object.defineProperty(_f,"__esModule",{value:!0}),_f.XyzBaseRenderDataTransform=_f.OhlcBaseRenderDataTransform=_f.XyyBaseRenderDataTransform=_f.XyBaseRenderDataTransform=_f.BaseRenderDataTransform=void 0;var e=fo(),i=Br(),n=ci(),r=di(),o=La(),a=jie(),s=lR(),l=hR(),u=n3e(),c=QP(),d=(function(v){t(y,v);function y(m,b,S){var _=v.call(this)||this;return _.requiresTransform=!0,_.useForYRange=!1,_.parentSeries=m,_.wasmContext=b,_.parentSeries.dataSeries,_.pointSeries=_.createPointSeries(),_.drawingProviders=S??[],_}return y.prototype.runTransform=function(m){var b,S,_;if(this.requiresTransform||m.indexRange&&!m.indexRange.equals(this.lastIndexRange)||m.resamplingHash&&m.resamplingHash!==this.lastResamplingHash){n.Guard.notNull(m,"renderPassData"),n.Guard.notNull(m.pointSeries,"renderPassData.pointSeries");var C=o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.RenderDataTransformStart,{contextId:this.parentSeries.id,parentContextId:(b=this.parentSeries.parentSurface)===null||b===void 0?void 0:b.id,level:o.EPerformanceDebugLevel.Verbose}),P=this.runTransformInternal(m);return o.PerformanceDebugHelper.mark(o.EPerformanceMarkType.RenderDataTransformEnd,{contextId:this.parentSeries.id,parentContextId:(S=this.parentSeries.parentSurface)===null||S===void 0?void 0:S.id,relatedId:(_=C==null?void 0:C.detail)===null||_===void 0?void 0:_.relatedId,level:o.EPerformanceDebugLevel.Verbose}),P===this.pointSeries&&(this.requiresTransform=!1),this.lastIndexRange=m.indexRange,this.lastResamplingHash=m.resamplingHash,this.makeRenderPassData(m,P)}return this.makeRenderPassData(m,this.pointSeries)},y.prototype.onDataChange=function(m){this.requiresTransform=!0},y.prototype.delete=function(){this.pointSeries=(0,i.deleteSafe)(this.pointSeries),this.wasmContext=void 0},y.prototype.makeRenderPassData=function(m,b){var S=new r.NumberRange(0,b.xValues.size()-1);return b.xRange=m.pointSeries.xRange,b.fifoStartIndex=m.pointSeries.fifoStartIndex,new c.RenderPassData(S,m.getxCoordinateCalculator,m.getyCoordinateCalculator,m.isVerticalChart,b,m.resamplingHash)},y})(e.DeletableEntity);_f.BaseRenderDataTransform=d;var f=(function(v){t(y,v);function y(){return v!==null&&v.apply(this,arguments)||this}return y.prototype.createPointSeries=function(){return new s.XyPointSeriesResampled(this.wasmContext,new r.NumberRange(0,0))},y.prototype.runTransformInternal=function(m){throw new Error("runTransformInternal not implemented.")},y})(d);_f.XyBaseRenderDataTransform=f;var h=(function(v){t(y,v);function y(){return v!==null&&v.apply(this,arguments)||this}return y.prototype.createPointSeries=function(){return new l.XyyPointSeriesResampled(this.wasmContext,new r.NumberRange(0,0))},y.prototype.runTransformInternal=function(m){throw new Error("runTransformInternal not implemented.")},y})(d);_f.XyyBaseRenderDataTransform=h;var p=(function(v){t(y,v);function y(){return v!==null&&v.apply(this,arguments)||this}return y.prototype.createPointSeries=function(){return new a.OhlcPointSeriesResampled(this.wasmContext,new r.NumberRange(0,0))},y.prototype.runTransformInternal=function(m){throw new Error("runTransformInternal not implemented.")},y})(d);_f.OhlcBaseRenderDataTransform=p;var g=(function(v){t(y,v);function y(){return v!==null&&v.apply(this,arguments)||this}return y.prototype.createPointSeries=function(){return new u.XyzPointSeriesResampled(this.wasmContext,new r.NumberRange(0,0))},y.prototype.runTransformInternal=function(m){throw new Error("runTransformInternal not implemented.")},y})(d);return _f.XyzBaseRenderDataTransform=g,_f}var E_e;function o3e(){if(E_e)return xw;E_e=1;var t=xw&&xw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(xw,"__esModule",{value:!0}),xw.XyySplineRenderDataTransform=void 0;var e=di(),i=hR(),n=Cv(),r=(function(o){t(a,o);function a(){var s=o!==null&&o.apply(this,arguments)||this;return s.interpolationPoints=10,s.warnOnSplineFailure=!0,s.useForYRange=!0,s}return a.prototype.createPointSeries=function(){return new i.XyyPointSeriesResampled(this.wasmContext,new e.NumberRange(0,0))},a.prototype.runTransformInternal=function(s){var l=this.parentSeries.xAxis.isCategoryAxis?s.pointSeries.indexes:s.pointSeries.xValues,u=s.pointSeries.yValues,c=s.pointSeries.y1Values,d=l.size();if(d==0)return s.pointSeries;var f=this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN;return this.wasmContext.SCRTSplineHelperCubicSpline(l,u,this.pointSeries.xValues,this.pointSeries.yValues,d,this.interpolationPoints,f),!f&&isNaN(this.pointSeries.yValues.get(0))?(this.warnOnSplineFailure&&console.warn(`Could not calculate spline values.  X data may contain duplicates.  Falling back to original values.
    To disable this warning set warnOnSplineFailure = false.`),s.pointSeries):(this.wasmContext.SCRTSplineHelperCubicSpline(l,c,this.pointSeries.xValues,this.pointSeries.y1Values,d,this.interpolationPoints,f),this.pointSeries)},a})(n.BaseRenderDataTransform);return xw.XyySplineRenderDataTransform=r,xw}var w_e;function a3e(){if(w_e)return Tw;w_e=1;var t=Tw&&Tw.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(Tw,"__esModule",{value:!0}),Tw.SplineBandRenderableSeries=void 0;var e=Br(),i=di(),n=hn(),r=kp(),o=Bu(),a=zi(),s=KV(),l=QP(),u=UW(),c=un(),d=o3e(),f=(function(h){t(p,h);function p(g,v){var y=this,m,b,S;return y=h.call(this,g,v)||this,y.type=n.ESeriesType.SplineBandSeries,y.isSplineProperty=!0,y.interpolationPointsProperty=10,y.interpolationPointsProperty=(m=v==null?void 0:v.interpolationPoints)!==null&&m!==void 0?m:y.interpolationPointsProperty,y.renderDataTransform=new d.XyySplineRenderDataTransform(y,g,[y.drawingProviders[0]]),y.renderDataTransform.interpolationPoints=y.interpolationPoints,!((b=y.paletteProvider)===null||b===void 0)&&b.onAttached&&((S=y.paletteProvider)===null||S===void 0||S.onAttached(y)),y}return Object.defineProperty(p.prototype,"isSpline",{get:function(){return this.isSplineProperty},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"interpolationPoints",{get:function(){return this.interpolationPointsProperty},set:function(g){this.interpolationPointsProperty=g,this.renderDataTransform.interpolationPoints=this.interpolationPoints,this.renderDataTransform.requiresTransform=!0,this.notifyPropertyChanged(c.PROPERTY.INTERPOLATION_POINTS)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"xSplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.xValues},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"ySplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.yValues},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"y1SplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.y1Values},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"warnOnSplineFailure",{get:function(){return this.renderDataTransform.warnOnSplineFailure},set:function(g){this.renderDataTransform.warnOnSplineFailure=g},enumerable:!1,configurable:!0}),p.prototype.updateTransformedValues=function(){var g;if(!(!this.dataSeries||!this.parentSurface)){if(!this.currentRenderPassData){var v=!((g=this.resamplingParams)===null||g===void 0)&&g.resampleRequired?this.pointSeries:new s.XyyPointSeriesWrapped(this.dataSeries,void 0);this.currentRenderPassData=new l.RenderPassData(this.getIndicesRange(this.xAxis.visibleRange,this.xAxis.isCategoryAxis),this.xAxis.getCurrentCoordinateCalculator,this.yAxis.getCurrentCoordinateCalculator,this.xAxis.isVerticalChart,v)}this.transformedRenderPassData=this.renderDataTransform.runTransform(this.currentRenderPassData)}},p.prototype.updateSplineValues=function(){this.updateTransformedValues()},p.prototype.onSplineFailure=function(){},p.prototype.getYRange=function(g,v){var y;if(v===void 0&&(v=!1),this.isRunningAnimation)return this.dataSeries.getWindowedYRange(g,!0,v,a.EDataSeriesValueType.Default,this.yRangeMode);this.updateSplineValues();var m=this.xSplineValues,b=this.ySplineValues,S=this.y1SplineValues;if(m.size()===1){var _=Math.min(b.get(0),S.get(0)),C=Math.max(b.get(0),S.get(0));return new i.NumberRange(_,C)}var P=v?g:(0,o.getIndicesRange)(this.webAssemblyContext,m,g,(y=this.dataSeries)===null||y===void 0?void 0:y.dataDistributionCalculator.isSortedAscending),x=Math.max(Math.floor(P.min),0),E=Math.min(Math.ceil(P.max),m.size()-1);if(!(E<x)){var A,R;try{return A=this.webAssemblyContext.NumberUtil.MinMaxWithIndex(b,x,E-x+1,this.dataSeries.dataDistributionCalculator.containsNaN),!(0,r.isRealNumber)(A.minD)||!(0,r.isRealNumber)(A.maxD)||(R=this.webAssemblyContext.NumberUtil.MinMaxWithIndex(S,x,E-x+1,this.dataSeries.dataDistributionCalculator.containsNaN),!(0,r.isRealNumber)(R.minD)||!(0,r.isRealNumber)(R.maxD))?void 0:new i.NumberRange(Math.min(A.minD,R.minD),Math.max(A.maxD,R.maxD))}finally{(0,e.deleteSafe)(A),(0,e.deleteSafe)(R)}}},p.prototype.toJSON=function(g){g===void 0&&(g=!1);var v=h.prototype.toJSON.call(this,g),y={interpolationPoints:this.interpolationPoints};return Object.assign(v.options,y),v},p})(u.BaseBandRenderableSeries);return Tw.SplineBandRenderableSeries=f,Tw}var ww={},Aw={},A_e;function $ie(){if(A_e)return Aw;A_e=1;var t=Aw&&Aw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Aw,"__esModule",{value:!0}),Aw.SplineRenderDataTransform=void 0;var e=di(),i=lR(),n=Cv(),r=(function(o){t(a,o);function a(){var s=o!==null&&o.apply(this,arguments)||this;return s.interpolationPoints=10,s.warnOnSplineFailure=!0,s.useForYRange=!0,s}return a.prototype.createPointSeries=function(){return new i.XyPointSeriesResampled(this.wasmContext,new e.NumberRange(0,0))},a.prototype.runTransformInternal=function(s){var l=this.parentSeries.xAxis.isCategoryAxis?s.pointSeries.indexes:s.pointSeries.xValues,u=l.size();if(u==0||u===1)return s.pointSeries;var c=s.pointSeries.yValues,d=this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN;return this.wasmContext.SCRTSplineHelperCubicSpline(l,c,this.pointSeries.xValues,this.pointSeries.yValues,u,this.interpolationPoints,this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN),!d&&isNaN(this.pointSeries.yValues.get(0))?(this.warnOnSplineFailure&&console.error(`Could not calculate spline values.  X data may contain duplicates.  Falling back to original values.
    To disable this warning set warnOnSplineFailure = false.`),s.pointSeries):this.pointSeries},a})(n.BaseRenderDataTransform);return Aw.SplineRenderDataTransform=r,Aw}var O_e;function s3e(){if(O_e)return ww;O_e=1;var t=ww&&ww.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(ww,"__esModule",{value:!0}),ww.SplineLineRenderableSeries=void 0;var e=hn(),i=mm(),n=un(),r=fR(),o=$ie(),a=(function(s){t(l,s);function l(u,c){var d=this,f,h,p;return d=s.call(this,u,c)||this,d.type=e.ESeriesType.SplineLineSeries,d.isSplineProperty=!0,d.interpolationPointsProperty=10,d.dataLabelProviderProperty||(d.dataLabelProviderProperty=new r.LineSeriesDataLabelProvider(c==null?void 0:c.dataLabels),d.dataLabelProviderProperty.onAttach(d.webAssemblyContext,d)),d.interpolationPointsProperty=(f=c==null?void 0:c.interpolationPoints)!==null&&f!==void 0?f:d.interpolationPointsProperty,d.renderDataTransform=new o.SplineRenderDataTransform(d,u,[d.drawingProviders[0]]),d.renderDataTransform.interpolationPoints=d.interpolationPoints,!((h=d.paletteProvider)===null||h===void 0)&&h.onAttached&&((p=d.paletteProvider)===null||p===void 0||p.onAttached(d)),d}return Object.defineProperty(l.prototype,"xSplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.xValues},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"ySplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.yValues},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"isSpline",{get:function(){return this.isSplineProperty},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"interpolationPoints",{get:function(){return this.interpolationPointsProperty},set:function(u){this.interpolationPointsProperty=u,this.renderDataTransform.interpolationPoints=this.interpolationPoints,this.renderDataTransform.requiresTransform=!0,this.notifyPropertyChanged(n.PROPERTY.INTERPOLATION_POINTS)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"warnOnSplineFailure",{get:function(){return this.renderDataTransform.warnOnSplineFailure},set:function(u){this.renderDataTransform.warnOnSplineFailure=u},enumerable:!1,configurable:!0}),l.prototype.updateSplineValues=function(){this.updateTransformedValues()},l.prototype.onSplineFailure=function(){},l.prototype.toJSON=function(u){u===void 0&&(u=!1);var c=s.prototype.toJSON.call(this,u),d={interpolationPoints:this.interpolationPoints};return Object.assign(c.options,d),c},l})(i.BaseLineRenderableSeries);return ww.SplineLineRenderableSeries=a,ww}var Ow={},D_e;function l3e(){if(D_e)return Ow;D_e=1;var t=Ow&&Ow.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(Ow,"__esModule",{value:!0}),Ow.SplineMountainRenderableSeries=void 0;var e=hn(),i=$W(),n=un(),r=Wv(),o=$ie(),a=(function(s){t(l,s);function l(u,c){var d=this,f,h,p;return d=s.call(this,u,c)||this,d.type=e.ESeriesType.SplineMountainSeries,d.isSplineProperty=!0,d.interpolationPointsProperty=10,d.dataLabelProviderProperty||(d.dataLabelProviderProperty=new r.DataLabelProvider(c==null?void 0:c.dataLabels),d.dataLabelProviderProperty.onAttach(d.webAssemblyContext,d)),d.interpolationPointsProperty=(f=c==null?void 0:c.interpolationPoints)!==null&&f!==void 0?f:d.interpolationPointsProperty,d.renderDataTransform=new o.SplineRenderDataTransform(d,u,[d.drawingProviders[0]]),d.renderDataTransform.interpolationPoints=d.interpolationPoints,!((h=d.paletteProvider)===null||h===void 0)&&h.onAttached&&((p=d.paletteProvider)===null||p===void 0||p.onAttached(d)),d}return Object.defineProperty(l.prototype,"isSpline",{get:function(){return this.isSplineProperty},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"interpolationPoints",{get:function(){return this.interpolationPointsProperty},set:function(u){this.interpolationPointsProperty=u,this.renderDataTransform.interpolationPoints=this.interpolationPoints,this.renderDataTransform.requiresTransform=!0,this.notifyPropertyChanged(n.PROPERTY.INTERPOLATION_POINTS)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"xSplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.xValues},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"ySplineValues",{get:function(){if(!this.transformedRenderPassData)throw Error("Spline values are not available until after first render, or call updateSplineValues");return this.transformedRenderPassData.pointSeries.yValues},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"warnOnSplineFailure",{get:function(){return this.renderDataTransform.warnOnSplineFailure},set:function(u){this.renderDataTransform.warnOnSplineFailure=u},enumerable:!1,configurable:!0}),l.prototype.updateSplineValues=function(){this.updateTransformedValues()},l.prototype.onSplineFailure=function(){},l.prototype.toJSON=function(u){u===void 0&&(u=!1);var c=s.prototype.toJSON.call(this,u),d={interpolationPoints:this.interpolationPoints};return Object.assign(c.options,d),c},l})(i.BaseMountainRenderableSeries);return Ow.SplineMountainRenderableSeries=a,Ow}var Dw={},yB={},R_e;function fj(){return R_e||(R_e=1,(function(t){var e=yB&&yB.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.SmoothStackedRenderDataTransform=t.XyyBezierRenderDataTransform=t.BezierRenderDataTransform=t.bezierTransform=void 0;var i=ad(),n=di(),r=Rf(),o=bo(),a=lR(),s=hR(),l=Cv(),u=function(h,p,g,v,y,m,b){for(var S,_,C=h.length,P=[],x=[],E=[],A=function(oe,de,ge,Ee,Re,Ae,Pe){if(Ee!==Ee)return{xc:oe,yc:de};if(oe===ge&&de===Ee)return{xc:oe,yc:de};var we=Number.MAX_VALUE;oe!==ge&&(we=(de-Ee)/(oe-ge));var Te,ke,$e=(Re-oe)*Pe;return Te=oe+$e,ke=de+we*$e,ke=Math.max(Math.min(ke,Math.max(de,Ae)),Math.min(de,Ae)),{xc:Te,yc:ke}},R=function(oe,de,ge,Ee,Re){var Ae=1-Re;return Math.pow(Ae,3)*oe+3*Ae*Ae*Re*de+3*Ae*Re*Re*ge+Math.pow(Re,3)*Ee},M=function(oe){return{x:h[oe],y:p[oe]}},D=function(oe){if(!b)return 1/0;var de=b[H];return de!==de?1/0:de},F=M(Math.max(g-1,0)),I=M(g),V=M(g+1),z=M(Math.min(g+2,C-1)),G,H=0,U=g;U<v;U++){P.push(I.x),E.push(H),x.push(Math.min(I.y,D())),H++;var k=A(I.x,I.y,(S=G==null?void 0:G.xc)!==null&&S!==void 0?S:F.x,(_=G==null?void 0:G.yc)!==null&&_!==void 0?_:F.y,V.x,V.y,m);G=A(V.x,V.y,z.x,z.y,I.x,I.y,m);for(var X=1;X<y;X++){var W=i.easing.inOutCubic(X/y),Y=R(I.x,k.xc,G.xc,V.x,W),te=R(I.y,k.yc,G.yc,V.y,W);P.push(Y),x.push(Math.min(te,D())),E.push(H),H++}U>g&&(F=I),I=V,V=z,U<C-3&&(z=M(U+3))}return P.push(V.x),x.push(Math.min(V.y,D())),E.push(H),{newxValues:P,newyValues:x,newindexes:E}};t.bezierTransform=u;var c=(function(h){e(p,h);function p(g,v,y,m){var b=this,S,_;return b=h.call(this,g,v,y)||this,b.interpolationPointsProperty=20,b.curvatureProperty=.5,b.interpolationPointsProperty=(S=m==null?void 0:m.interpolationPoints)!==null&&S!==void 0?S:b.interpolationPoints,b.curvatureProperty=(_=m==null?void 0:m.curvature)!==null&&_!==void 0?_:b.curvature,b}return Object.defineProperty(p.prototype,"interpolationPoints",{get:function(){return this.interpolationPointsProperty},set:function(g){var v,y;this.interpolationPointsProperty!==g&&(this.interpolationPointsProperty=g,this.requiresTransform=!0,!((v=this.parentSeries)===null||v===void 0)&&v.invalidateParentCallback&&((y=this.parentSeries)===null||y===void 0||y.invalidateParentCallback()))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"curvature",{get:function(){return this.curvatureProperty},set:function(g){var v,y;this.curvatureProperty!==g&&(this.curvatureProperty=g,this.requiresTransform=!0,!((v=this.parentSeries)===null||v===void 0)&&v.invalidateParentCallback&&((y=this.parentSeries)===null||y===void 0||y.invalidateParentCallback()))},enumerable:!1,configurable:!0}),p.prototype.createPointSeries=function(){return new a.XyPointSeriesResampled(this.wasmContext,new n.NumberRange(0,0))},p.prototype.runTransformInternal=function(g){var v,y=g.pointSeries,m=y.xValues,b=y.yValues;y.indexes;var S=y.resampled,_=this.pointSeries,C=_.xValues,P=_.yValues,x=_.indexes,E=S?0:g.indexRange.min,A=S?m.size()-1:(v=g.indexRange)===null||v===void 0?void 0:v.max;if(m.size()==0)return g.pointSeries;C.clear(),P.clear(),x.clear();var R=(0,t.bezierTransform)((0,o.vectorToArrayViewF64)(m,this.wasmContext),(0,o.vectorToArrayViewF64)(b,this.wasmContext),E,A,this.interpolationPoints,this.curvature),M=R.newxValues,D=R.newyValues,F=R.newindexes;return(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,C,M),(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,P,D),(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,x,F),this.pointSeries},p})(l.BaseRenderDataTransform);t.BezierRenderDataTransform=c;var d=(function(h){e(p,h);function p(g,v,y,m){var b=this,S,_;return b=h.call(this,g,v,y)||this,b.interpolationPointsProperty=20,b.curvatureProperty=.5,b.forceYGreaterThanY1=!1,b.interpolationPointsProperty=(S=m==null?void 0:m.interpolationPoints)!==null&&S!==void 0?S:b.interpolationPoints,b.curvatureProperty=(_=m==null?void 0:m.curvature)!==null&&_!==void 0?_:b.curvature,b}return Object.defineProperty(p.prototype,"interpolationPoints",{get:function(){return this.interpolationPointsProperty},set:function(g){var v,y;this.interpolationPointsProperty!==g&&(this.interpolationPointsProperty=g,this.requiresTransform=!0,!((v=this.parentSeries)===null||v===void 0)&&v.invalidateParentCallback&&((y=this.parentSeries)===null||y===void 0||y.invalidateParentCallback()))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"curvature",{get:function(){return this.curvatureProperty},set:function(g){var v,y;this.curvatureProperty!==g&&(this.curvatureProperty=g,this.requiresTransform=!0,!((v=this.parentSeries)===null||v===void 0)&&v.invalidateParentCallback&&((y=this.parentSeries)===null||y===void 0||y.invalidateParentCallback()))},enumerable:!1,configurable:!0}),p.prototype.createPointSeries=function(){return new s.XyyPointSeriesResampled(this.wasmContext,new n.NumberRange(0,0))},p.prototype.runTransformInternal=function(g){var v,y=g.pointSeries,m=y.xValues,b=y.yValues,S=y.y1Values;y.indexes;var _=y.resampled,C=this.pointSeries,P=C.xValues,x=C.yValues,E=C.y1Values,A=C.indexes,R=_?0:g.indexRange.min,M=_?m.size()-1:(v=g.indexRange)===null||v===void 0?void 0:v.max;if(m.size()==0)return g.pointSeries;P.clear(),x.clear(),E.clear(),A.clear();var D=(0,t.bezierTransform)((0,o.vectorToArrayViewF64)(m,this.wasmContext),(0,o.vectorToArrayViewF64)(S,this.wasmContext),R,M,this.interpolationPoints,this.curvature);D.newxValues;var F=D.newyValues;D.newindexes,(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,E,F);var I=(0,t.bezierTransform)((0,o.vectorToArrayViewF64)(m,this.wasmContext),(0,o.vectorToArrayViewF64)(b,this.wasmContext),R,M,this.interpolationPoints,this.curvature,this.forceYGreaterThanY1?(0,o.vectorToArrayViewF64)(E,this.wasmContext):void 0),V=I.newxValues,z=I.newyValues,G=I.newindexes;return(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,P,V),(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,x,z),(0,r.appendDoubleVectorFromJsArray)(this.wasmContext,A,G),this.pointSeries},p})(l.BaseRenderDataTransform);t.XyyBezierRenderDataTransform=d;var f=(function(h){e(p,h);function p(){var g=h!==null&&h.apply(this,arguments)||this;return g.forceYGreaterThanY1=!0,g}return p})(d);t.SmoothStackedRenderDataTransform=f})(yB)),yB}var Rw={},Mw={},Lw={},kw={},M_e;function u3e(){if(M_e)return kw;M_e=1;var t=kw&&kw.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(kw,"__esModule",{value:!0}),kw.StackedXySeriesInfo=void 0;var e=Am(),i=(function(n){t(r,n);function r(o,a){var s=n.call(this,o,a)||this;return s.yValue=a.y1Value,s.accumulatedValue=a.yValue,s}return r.prototype.getValuesWithLabels=function(o,a,s,l){var u=n.prototype.getValuesWithLabels.call(this,o,a,s,l);return u.push(this.concatTwoValuesWithLabels(this.formattedXValue,this.formattedYValue,a,s)),u},r})(e.SeriesInfo);return kw.StackedXySeriesInfo=i,kw}var L_e;function YW(){if(L_e)return Lw;L_e=1;var t=Lw&&Lw.__extends||(function(){var p=function(g,v){return p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(y,m){y.__proto__=m}||function(y,m){for(var b in m)Object.prototype.hasOwnProperty.call(m,b)&&(y[b]=m[b])},p(g,v)};return function(g,v){if(typeof v!="function"&&v!==null)throw new TypeError("Class extends value "+String(v)+" is not a constructor or null");p(g,v);function y(){this.constructor=g}g.prototype=v===null?Object.create(v):(y.prototype=v.prototype,new y)}})();Object.defineProperty(Lw,"__esModule",{value:!0}),Lw.BaseStackedRenderableSeries=void 0;var e=mo(),i=Br(),n=ga(),r=Ac(),o=qV(),a=La(),s=u3e(),l=zi(),u=Om(),c=ju(),d=un(),f=CW(),h=(function(p){t(g,p);function g(v,y){var m=p.call(this,v,y)||this;return m.isStacked=!0,m.rolloverModifierProps=new f.RolloverModifierRenderableSeriesProps(m),m.getParentSurfaceFn=function(){},m.typeMap=new Map,m.opacityOriginalValue=1,m.isStacked=!0,m.accumulatedValues=new v.SCRTDoubleVector,m.accumulatedFinalAnimationValues=new v.SCRTDoubleVector,y!=null&&y.dataLabelProvider&&("draw"in y.dataLabelProvider||(y.dataLabelProvider.type===r.EDataLabelProviderType.Custom?y.dataLabelProvider=(0,e.createType)(n.EBaseType.DataLabelProvider,y.dataLabelProvider.customType,v,y.dataLabelProvider.options):y.dataLabelProvider=(0,e.createType)(n.EBaseType.DataLabelProvider,y.dataLabelProvider.type,v,y.dataLabelProvider.options))),m.dataLabelProviderProperty=y==null?void 0:y.dataLabelProvider,m.dataLabelProviderProperty&&m.dataLabelProviderProperty.onAttach(v,m),y!=null&&y.animation&&m.animationQueue.push(y.animation),m}return g.prototype.dataSeriesDataChanged=function(){this.notifyPropertyChanged(d.PROPERTY.DATA_SERIES)},g.prototype.draw=function(v,y){var m,b,S,_,C=a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.DrawSingleSeriesStart,{contextId:this.id,parentContextId:(m=this.parentSurface)===null||m===void 0?void 0:m.id,level:a.EPerformanceDebugLevel.Verbose});this.currentRenderPassData=y,(b=this.hitTestProvider)===null||b===void 0||b.update(y),this.dataLabelProvider&&this.dataLabelProvider.generateDataLabels(v,y),a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.DrawSingleSeriesEnd,{contextId:this.id,parentContextId:(S=this.parentSurface)===null||S===void 0?void 0:S.id,relatedId:(_=C==null?void 0:C.detail)===null||_===void 0?void 0:_.relatedId,level:a.EPerformanceDebugLevel.Verbose})},g.prototype.delete=function(){this.accumulatedValues=(0,i.deleteSafe)(this.accumulatedValues),this.accumulatedFinalAnimationValues=(0,i.deleteSafe)(this.accumulatedFinalAnimationValues),p.prototype.delete.call(this)},g.prototype.onDetachFromParentCollection=function(){this.parentCollection=void 0,this.getParentSurfaceFn=void 0,this.notifyParentPropertyChangedFn=void 0},g.prototype.notifyPropertyChanged=function(v){this.drawingProviders.forEach(function(y){return y.onSeriesPropertyChange(v)}),this.notifyParentPropertyChangedFn&&this.notifyParentPropertyChangedFn(v)},g.prototype.checkIsOutOfDataRange=function(v,y){var m=this.getDataSeriesValuesCount(),b=this.xAxis.getCurrentCoordinateCalculator().isCategoryCoordinateCalculator,S=b?0:this.getNativeXValues().get(0),_=b?m-1:this.getNativeXValues().get(m-1);return v<S||v>_},g.prototype.getAccumulatedValues=function(v){return v?this.accumulatedFinalAnimationValues:this.accumulatedValues},g.prototype.getBaseXValues=function(){throw Error("getBaseXValues() is not supported for BaseStackedRenderableSeries")},g.prototype.onAttach=function(v){throw Error("onAttach() method is not supported for BaseStackedRenderableSeries")},g.prototype.onDetach=function(){throw Error("onDetach() method is not supported for BaseStackedRenderableSeries")},Object.defineProperty(g.prototype,"resamplingMode",{get:function(){return u.EResamplingMode.None},set:function(v){throw Error("Setting resamplingMode property is not supported for BaseStackedRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"resamplingPrecision",{get:function(){throw Error("resamplingPrecision property is not supported for BaseStackedRenderableSeries")},set:function(v){throw Error("resamplingPrecision property is not supported for BaseStackedRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"dataLabelProvider",{get:function(){return this.dataLabelProviderProperty},set:function(v){this.dataLabelProviderProperty=v,v.onAttach(this.webAssemblyContext,this),this.notifyPropertyChanged(d.PROPERTY.SERIES_TEXT_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"parentSurface",{get:function(){if(this.getParentSurfaceFn)return this.getParentSurfaceFn()},set:function(v){throw Error("set parentSurface property is not supported for BaseStackedRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"xAxis",{get:function(){return this.parentCollection.xAxis},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"yAxis",{get:function(){return this.parentCollection.yAxis},enumerable:!1,configurable:!0}),g.prototype.beforeAnimationStart=function(){if(this.opacityOriginalValue=this.opacity,this.isRunningAnimation){p.prototype.beforeAnimationStart.call(this);return}(0,o.copyDoubleVector)(this.accumulatedValues,this.accumulatedFinalAnimationValues,this.webAssemblyContext)},g.prototype.afterAnimationComplete=function(){this.opacityProperty=this.opacityOriginalValue,this.isRunningAnimation&&p.prototype.afterAnimationComplete.call(this)},g.prototype.updateAnimationProperties=function(v,y){if(this.isRunningAnimation){p.prototype.updateAnimationProperties.call(this,v,this.animationFSM),this.parentCollection.setAccumulatedValuesDirty();return}y.animation.isFadeEffectAnimation?this.opacity=v*this.opacityOriginalValue:this.opacity=this.opacityOriginalValue,y.animation.calculateAnimationValues(this.webAssemblyContext,this.accumulatedFinalAnimationValues,this.accumulatedValues,v),this.renderDataTransform&&(this.renderDataTransform.requiresTransform=!0)},g.prototype.getSeriesInfo=function(v){return new s.StackedXySeriesInfo(this,v)},g.prototype.toJSON=function(v){var y,m,b;v===void 0&&(v=!1);var S;if(this.paletteProvider)if("toJSON"in this.paletteProvider)S=this.paletteProvider.toJSON();else throw new Error("Series contains a palletProvider.  This must implement toJSON to be correctly serialized");var _={id:this.id,opacity:this.opacity,animation:this.animation,dataLabelProvider:(y=this.dataLabelProvider)===null||y===void 0?void 0:y.toJSON(),pointMarker:(m=this.pointMarker)===null||m===void 0?void 0:m.toJSON(),stroke:this.stroke,paletteProvider:S};return((b=this.dataSeries)===null||b===void 0?void 0:b.type)===l.EDataSeriesType.Xy?{type:this.type,options:_,xyData:this.dataSeries.toJSON(v).options}:{type:this.type,options:_}},g.prototype.toPointSeries=function(v){throw Error("toPointSeries method is not supported for BaseStackedRenderableSeries")},g.prototype.getCurrentRenderPassData=function(){throw Error("getCurrentRenderPassData method is not supported for BaseStackedRenderableSeries")},Object.defineProperty(g.prototype,"xAxisId",{get:function(){var v;return(v=this.parentCollection)===null||v===void 0?void 0:v.xAxisId},set:function(v){throw Error("Setting xAxisId property is not supported for BaseStackedRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(g.prototype,"yAxisId",{get:function(){var v;return(v=this.parentCollection)===null||v===void 0?void 0:v.yAxisId},set:function(v){throw Error("yAxisId property is not supported for BaseStackedRenderableSeries")},enumerable:!1,configurable:!0}),g.prototype.linkAxes=function(){},g})(c.BaseRenderableSeries);return Lw.BaseStackedRenderableSeries=h,Lw}var Iw={},k_e;function c3e(){if(k_e)return Iw;k_e=1;var t=Iw&&Iw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Iw,"__esModule",{value:!0}),Iw.StackedMountainSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=this.parentSeries.accumulatedValues,S=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0);if(y>=0){var _=function(E){return b.get(E)},C=function(E){return b.get(E)-v.getNativeYValues().get(E)},P=i.hitTestHelpers.testIsHitForBand(this.parentSeries.isDigitalLine,d,f,m,_,C,y,p,g,v);S.isHit=P.isHit,S.point2dataSeriesIndex=P.secondPointIndex;var x=v.valueNames.reduce(function(E,A){return E[A]=v.getNativeValue(v.getYValuesByName(A),S.point2dataSeriesIndex),E},{});S.point2yValueByName=x}else S.isHit=!1;return S},a.prototype.hitTestXSlice=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=v.getNativeYValues(),S=this.parentSeries.accumulatedValues,_=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,S,p,g,y,0);return y>=0?(_.y1Value=b.get(y),_.isHit=_.isWithinDataBounds):_.isHit=!1,_},a.prototype.hitTestDataPoint=function(s,l,u){return u===void 0&&(u=e.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(s,l)},a})(e.BaseHitTestProvider);return Iw.StackedMountainSeriesHitTestProvider=r,Iw}var I_e;function d3e(){if(I_e)return Mw;I_e=1;var t=Mw&&Mw.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(Mw,"__esModule",{value:!0}),Mw.BaseStackedMountainRenderableSeries=void 0;var e=La(),i=DI(),n=Xs(),r=Sn(),o=YW(),a=un(),s=Bie(),l=Yf(),u=c3e(),c=(function(d){t(f,d);function f(h,p){var g=this,v,y,m;return g=d.call(this,h,p)||this,g.fillProperty="#7e8486",g.strokeY1Property="transparent",g.strokeDashArrayProperty=[],g.strokeY1DashArrayProperty=[],g.fillProperty=(v=p==null?void 0:p.fill)!==null&&v!==void 0?v:g.fillProperty,g.stroke=(y=p==null?void 0:p.stroke)!==null&&y!==void 0?y:r.SciChartSurfaceBase.DEFAULT_THEME.mountainLineColor,g.strokeDashArrayProperty=(m=p==null?void 0:p.strokeDashArray)!==null&&m!==void 0?m:g.strokeDashArrayProperty,g.customTextureOptionsProperty=p==null?void 0:p.customTextureOptions,g}return f.prototype.onAttachToParentCollection=function(h,p,g){if(this.parentCollection)throw new Error("Invalid operation in StackedMountainRenderableSeries.onAttachToParentCollection, this series has been already attached to collection. Please detach it from the collection before attaching to another");this.parentCollection=h,this.getParentSurfaceFn=p,this.notifyParentPropertyChangedFn=g},f.prototype.onAttach=function(h){if(this.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachSeries, this series has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.invalidateParentCallback=h.invalidateElement,this.drawingProviders.forEach(function(p){return p.onAttachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(h.invalidateElement)},f.prototype.onDetach=function(){this.invalidateParentCallback=void 0,this.drawingProviders.forEach(function(h){return h.onDetachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(void 0)},f.prototype.draw=function(h,p){var g=this,v,y,m,b,S=e.PerformanceDebugHelper.mark(e.EPerformanceMarkType.DrawSingleSeriesStart,{contextId:this.id,parentContextId:(v=this.parentSurface)===null||v===void 0?void 0:v.id,level:e.EPerformanceDebugLevel.Verbose});this.currentRenderPassData=p,(y=this.hitTestProvider)===null||y===void 0||y.update(p);try{h.pushShaderEffect(this.effect);var _=this.parentSurface.seriesViewRect;this.drawingProviders.forEach(function(C){var P;if(!((P=g.xAxis)===null||P===void 0)&&P.isVerticalChart&&h.setTranslationRotationAndClip(_,_.x,_.y),g.renderDataTransform&&g.renderDataTransform.drawingProviders.includes(C)){var x=g.renderDataTransform.runTransform(p);C.draw(h,x)}else C.draw(h,p)})}finally{h.popShaderEffect()}e.PerformanceDebugHelper.mark(e.EPerformanceMarkType.DrawSingleSeriesEnd,{contextId:this.id,parentContextId:(m=this.parentSurface)===null||m===void 0?void 0:m.id,relatedId:(b=S==null?void 0:S.detail)===null||b===void 0?void 0:b.relatedId,level:e.EPerformanceDebugLevel.Verbose})},f.prototype.onDpiChanged=function(h){d.prototype.onDpiChanged.call(this,h),this.notifyPropertyChanged(a.PROPERTY.STROKE)},Object.defineProperty(f.prototype,"fill",{get:function(){return(0,n.stripAutoColor)(this.fillProperty)},set:function(h){this.fillProperty!==h&&(this.fillProperty=h,this.drawingProviders.forEach(function(p){return p.onSeriesPropertyChange(a.PROPERTY.FILL)}),this.drawingProviders.forEach(function(p){return p.onSeriesPropertyChange(a.PROPERTY.FILL_Y1)}),this.notifyPropertyChanged(a.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"strokeY1",{get:function(){return this.strokeY1Property},set:function(h){this.strokeY1Property!==h&&(this.strokeY1Property=h,this.drawingProviders.forEach(function(p){return p.onSeriesPropertyChange(a.PROPERTY.STROKE_Y1)}))},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"fillY1",{get:function(){return(0,n.stripAutoColor)(this.fillProperty)},set:function(h){throw new Error("Setting fillY1 property is not supported on StackedMountainRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(h){this.strokeDashArrayProperty=h,this.notifyPropertyChanged(a.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"strokeY1DashArray",{get:function(){return this.strokeY1DashArrayProperty},set:function(h){this.strokeY1DashArrayProperty=h,this.drawingProviders.forEach(function(p){return p.onSeriesPropertyChange(a.PROPERTY.STROKE_Y1_DASH_ARRAY)})},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(h){h!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=h,this.notifyPropertyChanged(a.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),f.prototype.getCurrentRenderPassData=function(){return this.currentRenderPassData},f.prototype.toJSON=function(h){h===void 0&&(h=!1);var p=d.prototype.toJSON.call(this,h),g={fill:this.fill,stroke:this.stroke,strokeThickness:this.strokeThickness,strokeDashArray:this.strokeDashArray};return Object.assign(p.options,g),p},f.prototype.toPointSeries=function(h){return new i.XyPointSeriesWrapped(this.dataSeries)},f.prototype.resolveAutoColors=function(h,p,g){if(d.prototype.resolveAutoColors.call(this,h,p,g),this.fillProperty.startsWith(n.AUTO_COLOR)){var v=g.getFillColor(h,p,this.webAssemblyContext);this.fill=n.AUTO_COLOR+this.adjustAutoColor("fill",v)}},f.prototype.newHitTestProvider=function(){return new u.StackedMountainSeriesHitTestProvider(this,this.webAssemblyContext)},f.prototype.addDrawingProviders=function(h){this.drawingProviders.push(new s.BandSeriesDrawingProvider(h,this,function(p){return p.y1Values},function(p){return p.yValues}),new l.PointMarkerDrawingProvider(h,this,function(p){return p.y1Values}))},f})(o.BaseStackedRenderableSeries);return Mw.BaseStackedMountainRenderableSeries=c,Mw}var N_e;function qW(){if(N_e)return Rw;N_e=1;var t=Rw&&Rw.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(Rw,"__esModule",{value:!0}),Rw.StackedMountainRenderableSeries=void 0;var e=hn(),i=d3e(),n=(function(r){t(o,r);function o(a,s){var l=this,u,c;return l=r.call(this,a,s)||this,l.type=e.ESeriesType.StackedMountainSeries,!((u=l.paletteProvider)===null||u===void 0)&&u.onAttached&&((c=l.paletteProvider)===null||c===void 0||c.onAttached(l)),l}return o})(i.BaseStackedMountainRenderableSeries);return Rw.StackedMountainRenderableSeries=n,Rw}var F_e;function f3e(){if(F_e)return Dw;F_e=1;var t=Dw&&Dw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Dw,"__esModule",{value:!0}),Dw.SmoothStackedMountainRenderableSeries=void 0;var e=hn(),i=fj(),n=qW(),r=(function(o){t(a,o);function a(s,l){var u=this,c,d;u=o.call(this,s,l)||this,u.type=e.ESeriesType.SmoothStackedMountainSeries;var f=new i.SmoothStackedRenderDataTransform(u,s,[]);return f.interpolationPoints=(c=l==null?void 0:l.interpolationPoints)!==null&&c!==void 0?c:f.interpolationPoints,f.curvature=(d=l==null?void 0:l.curvature)!==null&&d!==void 0?d:f.curvature,u.renderDataTransform=f,u}return a})(n.StackedMountainRenderableSeries);return Dw.SmoothStackedMountainRenderableSeries=r,Dw}var Nw={},Fw={},B_e;function h3e(){if(B_e)return Fw;B_e=1;var t=Fw&&Fw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Fw,"__esModule",{value:!0}),Fw.StackedColumnSeriesHitTestProvider=void 0;var e=Eo(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,f,y,g,y.dataDistributionCalculator.isSortedAscending),b=y.getNativeXValues(),S=y.getNativeYValues(),_=this.parentSeries,C=_.accumulatedValues,P=_.getGroupIndex,x=_.getGroupsCount,E=_.getColumnWidth,A=n.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,b,C,g,v,m,0);if(m>=0){var R=P(),M=x(),D=E(f),F=D/2,I=(.5+R-M/2)*D;A.xValue=f.getDataValue(A.xCoord+I);var V=S.get(m),z=C.get(m),G=h.getCoordinate(z),H=h.getCoordinate(z-V),U=A.xCoord+I;A.isHit=(0,e.testIsInBounds)(g,v,U-F,H,U+F,G);var k=f.isCategoryCoordinateCalculator,X=k?0:b.get(0),W=f.getCoordinate(X),Y=k?b.size()-1:b.get(b.size()-1),te=f.getCoordinate(Y);A.isWithinDataBounds=(0,e.testIsInInterval)(A.hitTestPoint.x,W,te,D*M/2),A.y1Value=S.get(m)}else A.isHit=!1;return A},s.prototype.hitTestDataPoint=function(l,u,c){return c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(l,u)},s.prototype.hitTestForDataPointSelectionModifier=function(l,u,c){return c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(l,u)},s.prototype.hitTestXSlice=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,f,y,g,y.dataDistributionCalculator.isSortedAscending),b=y.getNativeXValues(),S=y.getNativeYValues(),_=this.parentSeries,C=_.accumulatedValues,P=_.getGroupIndex,x=_.getGroupsCount,E=_.getColumnWidth,A=n.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,b,C,g,v,m,0);if(m>=0){var R=P(),M=x(),D=E(f),F=D/2,I=f.isCategoryCoordinateCalculator,V=I?0:b.get(0),z=f.getCoordinate(V),G=I?b.size()-1:b.get(b.size()-1),H=f.getCoordinate(G);A.isWithinDataBounds=(0,e.testIsInInterval)(A.hitTestPoint.x,z,H,D*M/2);var U=(.5+R-M/2)*D;A.xValue=f.getDataValue(A.xCoord+U);var k=A.xCoord+U;A.isHit=(0,e.testIsInInterval)(g,k-F,k+F),A.y1Value=S.get(m)}else A.isHit=!1;return A},s})(i.BaseHitTestProvider);return Fw.StackedColumnSeriesHitTestProvider=o,Fw}var Rb={},j_e;function p3e(){if(j_e)return Rb;j_e=1;var t=Rb&&Rb.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=Rb&&Rb.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(Rb,"__esModule",{value:!0}),Rb.StackedColumnSeriesDataLabelProvider=void 0;var i=$i(),n=Ac(),r=Tc(),o=iI(),a=Wv(),s=(function(l){t(u,l);function u(c){var d=this,f;return d=l.call(this,e({horizontalTextPosition:r.EHorizontalTextPosition.Center,verticalTextPosition:r.EVerticalTextPosition.Center},c))||this,d.type=n.EDataLabelProviderType.Column,d.positionModeProperty=o.EColumnDataLabelPosition.Outside,d.positionModeProperty=(f=c==null?void 0:c.positionMode)!==null&&f!==void 0?f:d.positionMode,d}return Object.defineProperty(u.prototype,"positionMode",{get:function(){return this.positionModeProperty},set:function(c){this.positionModeProperty=c,this.invalidateParent()},enumerable:!1,configurable:!0}),u.prototype.CalculateShift=function(c){var d=this.columnWidth,f=this.groupSize;return c-d*f/2-this.spacing*(f-1)/2+this.groupIndex*(this.spacing+d)+.5*d},u.prototype.generateDataLabels=function(c,d){var f=this.parentSeries;this.yAdj=Math.ceil(f.strokeThickness/2),f.pointMarker&&(this.yAdj=Math.max(this.yAdj,Math.ceil(f.pointMarker.height/2))),l.prototype.generateDataLabels.call(this,c,d)},u.prototype.getPosition=function(c,d){var f,h,p,g,v,y,m,b,S,_,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge=c.isXFlipped?c.index:c.indexEnd-(c.index-c.indexStart),Ee=this.topVector.get(ge),Re=c.xCoord(),Ae=c.yCoord(),Pe=c.renderPassData.yCoordinateCalculator;c.isVerticalChart?(Ae=this.CalculateShift(Ae),Re=Pe.getCoordinate(Ee)):(Re=this.CalculateShift(Re),Ae=Pe.getCoordinate(Ee));var we=d.GetLineBounds(0),Te=d.m_fHeight-we.m_fHeight;we.delete(),Ae=Ae-Te,c.isXFlipped;var ke=c.isYFlipped?-1:1;return c.isVerticalChart?(this.verticalTextPosition===r.EVerticalTextPosition.Center?Ae+=d.m_fHeight/2:this.verticalTextPosition===r.EVerticalTextPosition.Below?Ae+=d.m_fHeight+((h=(f=this.style.padding)===null||f===void 0?void 0:f.top)!==null&&h!==void 0?h:1):Ae-=(g=(p=this.style.padding)===null||p===void 0?void 0:p.bottom)!==null&&g!==void 0?g:0,this.positionMode===o.EColumnDataLabelPosition.Outside?(c.yVal()*ke>=0?(Re+=this.yAdj,c.isXFlipped?Re+=(b=(m=c.style.padding)===null||m===void 0?void 0:m.left)!==null&&b!==void 0?b:1:Re-=d.m_fWidth+((y=(v=c.style.padding)===null||v===void 0?void 0:v.right)!==null&&y!==void 0?y:1)):(Re-=this.yAdj-((_=(S=c.style.padding)===null||S===void 0?void 0:S.right)!==null&&_!==void 0?_:1),(c.isXFlipped||c.isYFlipped)&&(Re-=d.m_fWidth+((P=(C=c.style.padding)===null||C===void 0?void 0:C.left)!==null&&P!==void 0?P:1))),{position:new i.Point(Re,Ae),rotationCenter:new i.Point(Re,Ae),rotationAngle:0}):this.positionMode===o.EColumnDataLabelPosition.Inside?(c.yVal()*ke>=0?(Re-=this.yAdj+((E=(x=c.style.padding)===null||x===void 0?void 0:x.right)!==null&&E!==void 0?E:1),(c.isXFlipped||c.isYFlipped)&&(Re-=d.m_fWidth+((R=(A=c.style.padding)===null||A===void 0?void 0:A.left)!==null&&R!==void 0?R:1))):(Re+=this.yAdj+((D=(M=c.style.padding)===null||M===void 0?void 0:M.left)!==null&&D!==void 0?D:1),c.isXFlipped||(Re-=d.m_fWidth+((I=(F=c.style.padding)===null||F===void 0?void 0:F.right)!==null&&I!==void 0?I:1))),{position:new i.Point(Re,Ae),rotationCenter:new i.Point(Re,Ae),rotationAngle:0}):l.prototype.getPosition.call(this,c,d)):(this.horizontalTextPosition===r.EHorizontalTextPosition.Center?Re-=d.m_fWidth/2:this.horizontalTextPosition===r.EHorizontalTextPosition.Left?Re-=d.m_fWidth+((z=(V=this.style.padding)===null||V===void 0?void 0:V.right)!==null&&z!==void 0?z:0)+d.m_fWidth:Re+=(H=(G=this.style.padding)===null||G===void 0?void 0:G.left)!==null&&H!==void 0?H:0+d.m_fWidth,this.positionMode===o.EColumnDataLabelPosition.Outside?(c.yVal()*ke>=0?Ae-=this.yAdj+((k=(U=c.style.padding)===null||U===void 0?void 0:U.bottom)!==null&&k!==void 0?k:1):Ae+=d.m_fHeight+this.yAdj+((W=(X=c.style.padding)===null||X===void 0?void 0:X.top)!==null&&W!==void 0?W:1),{position:new i.Point(Re,Ae),rotationCenter:new i.Point(Re,Ae),rotationAngle:0}):this.positionMode===o.EColumnDataLabelPosition.Inside?(c.yVal()*ke>=0?Ae+=d.m_fHeight+this.yAdj+((te=(Y=c.style.padding)===null||Y===void 0?void 0:Y.top)!==null&&te!==void 0?te:1):Ae-=this.yAdj+((de=(oe=c.style.padding)===null||oe===void 0?void 0:oe.bottom)!==null&&de!==void 0?de:1),{position:new i.Point(Re,Ae),rotationCenter:new i.Point(Re,Ae),rotationAngle:0}):l.prototype.getPosition.call(this,c,d))},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={positionMode:this.positionMode};return Object.assign(c.options,d),c},u})(a.DataLabelProvider);return Rb.StackedColumnSeriesDataLabelProvider=s,Rb}var V_e;function g3e(){if(V_e)return Nw;V_e=1;var t=Nw&&Nw.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(Nw,"__esModule",{value:!0}),Nw.StackedColumnRenderableSeries=void 0;var e=hn(),i=Xs(),n=Sn(),r=YW(),o=un(),a=h3e(),s=p3e(),l=Kz(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y,m,b,S,_,C,P,x;return p=c.call(this,f,h)||this,p.type=e.ESeriesType.StackedColumnSeries,p.fillProperty="#7e8486",p.spacingProperty=0,p.stackedGroupIdProperty="default",p.getGroupIndex=p.getGroupIndex.bind(p),p.getGroupsCount=p.getGroupsCount.bind(p),p.getColumnWidth=p.getColumnWidth.bind(p),p.isOneHundredPercent=(v=(g=p.parentCollection)===null||g===void 0?void 0:g.isOneHundredPercent)!==null&&v!==void 0?v:!1,p.fill=(y=h==null?void 0:h.fill)!==null&&y!==void 0?y:p.fillProperty,p.stroke=(m=h==null?void 0:h.stroke)!==null&&m!==void 0?m:n.SciChartSurfaceBase.DEFAULT_THEME.mountainLineColor,p.strokeThickness=(b=h==null?void 0:h.strokeThickness)!==null&&b!==void 0?b:1,p.spacingProperty=(S=h==null?void 0:h.spacing)!==null&&S!==void 0?S:p.spacingProperty,p.stackedGroupIdProperty=(_=h==null?void 0:h.stackedGroupId)!==null&&_!==void 0?_:p.stackedGroupIdProperty,p.fillLinearGradientProperty=(C=h==null?void 0:h.fillLinearGradient)!==null&&C!==void 0?C:p.fillLinearGradientProperty,p.customTextureOptionsProperty=h==null?void 0:h.customTextureOptions,p.dataLabelProviderProperty||(p.dataLabelProviderProperty=new s.StackedColumnSeriesDataLabelProvider(h==null?void 0:h.dataLabels),p.dataLabelProviderProperty.onAttach(p.webAssemblyContext,p)),!((P=p.paletteProvider)===null||P===void 0)&&P.onAttached&&((x=p.paletteProvider)===null||x===void 0||x.onAttached(p)),p}return d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new l.StackedColumnSeriesDrawingProvider(f,this))},d.prototype.delete=function(){c.prototype.delete.call(this)},d.prototype.onAttachToParentCollection=function(f,h,p,g){if(this.parentCollection)throw new Error("Invalid operation in StackedColumnRenderableSeries.onAttachToParentCollection, this series has been already attached to collection. Please detach it from the collection before attaching to another");this.parentCollection=f,this.getParentSurfaceFn=h,this.notifyParentPropertyChangedFn=p,this.getColumnWidthFn=g},d.prototype.getGroupIndex=function(){return this.groupIndex},d.prototype.setGroupIndex=function(f){this.groupIndex=f},d.prototype.getGroupsCount=function(){return this.groupsCount},d.prototype.setGroupsCount=function(f){this.groupsCount=f},d.prototype.getColumnWidth=function(f){return this.getColumnWidthFn(f)},d.prototype.onDpiChanged=function(f){this.notifyPropertyChanged(o.PROPERTY.STROKE)},Object.defineProperty(d.prototype,"fill",{get:function(){return(0,i.stripAutoColor)(this.fillProperty)},set:function(f){this.fillProperty=f,this.notifyPropertyChanged(o.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"effect",{get:function(){},set:function(f){},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"spacing",{get:function(){return this.spacingProperty},set:function(f){this.spacingProperty=f,this.notifyPropertyChanged(o.PROPERTY.SPACING)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"stackedGroupId",{get:function(){return this.stackedGroupIdProperty},set:function(f){this.stackedGroupIdProperty=f,this.notifyPropertyChanged(o.PROPERTY.STACKED_GROUP_ID)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(f){f!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=f,this.notifyPropertyChanged(o.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(f){f!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=f,this.notifyPropertyChanged(o.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),d.prototype.draw=function(f,h){var p=this,g,v=(g=this.parentSurface)===null||g===void 0?void 0:g.seriesViewRect;this.drawingProviders.forEach(function(y){var m;if(!((m=p.xAxis)===null||m===void 0)&&m.isVerticalChart&&v&&f.setTranslationRotationAndClip(v,v.x,v.y),p.renderDataTransform&&p.renderDataTransform.drawingProviders.includes(y)){var b=p.renderDataTransform.runTransform(h);y.draw(f,b)}else y.draw(f,h)})},d.prototype.toJSON=function(f){f===void 0&&(f=!1);var h=c.prototype.toJSON.call(this,f),p={fill:this.fill,stroke:this.stroke,strokeThickness:this.strokeThickness,spacing:this.spacing,stackedGroupId:this.stackedGroupId,fillLinearGradient:this.fillLinearGradient};return Object.assign(h.options,p),h},d.prototype.resolveAutoColors=function(f,h,p){if(c.prototype.resolveAutoColors.call(this,f,h,p),this.fillProperty.startsWith(i.AUTO_COLOR)){var g=p.getFillColor(f,h,this.webAssemblyContext);this.fill=i.AUTO_COLOR+this.adjustAutoColor("fill",g)}},d.prototype.newHitTestProvider=function(){return new a.StackedColumnSeriesHitTestProvider(this,this.webAssemblyContext)},d})(r.BaseStackedRenderableSeries);return Nw.StackedColumnRenderableSeries=u,Nw}var mB={},Bw={},H_e;function v3e(){if(H_e)return Bw;H_e=1;var t=Bw&&Bw.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(Bw,"__esModule",{value:!0}),Bw.UniformContoursDrawingProvider=void 0;var e=Uo(),i=Br(),n=ci(),r=Rn(),o=Ti(),a=PW(),s=an(),l=rR(),u=zI(),c=un(),d=du(),f=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.heightsTextureCache=new a.TextureCache(g),y.onSeriesPropertyChange(c.PROPERTY.DATA_SERIES),y.onSeriesPropertyChange(c.PROPERTY.COLOR_MAP),y}return p.prototype.delete=function(){this.heightsTextureCache=(0,i.deleteSafe)(this.heightsTextureCache),this.heightData=(0,i.deleteSafe)(this.heightData),this.paletteTexture=(0,i.deleteSafe)(this.paletteTexture),h.prototype.delete.call(this)},p.prototype.onSeriesPropertyChange=function(g){var v=g===c.PROPERTY.COLOR_MAP||g.includes(u.COLOR_MAP_PREFIX),y=g===c.PROPERTY.DATA_SERIES;if(v&&(this.paletteTexture=(0,i.deleteSafe)(this.paletteTexture),this.parentSeries.colorMap&&this.parentSeries.colorMap.gradientStops?this.paletteTexture=this.createPaletteTexture(256,1,this.parentSeries.colorMap.gradientStops):this.paletteTexture=this.createPaletteTexture(256,1,void 0)),y){var m=this.parentSeries.dataSeries;if(m){var b=this.heightsTextureCache.create(m.arrayWidth,m.arrayHeight,this.webAssemblyContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_R32F);this.webAssemblyContext.SCRTSetTextureLinearSamplerEnabled(b,!0)}}},p.prototype.draw=function(g,v){var y=this,m,b,S=(m=this.heightsTextureCache)===null||m===void 0?void 0:m.value;if(S){var _=this.parentSeries.dataSeries;this.webAssemblyContext.SCRTFillTextureFloat32(S,_.arrayWidth,_.arrayHeight,_.getNormalizedVector((b=this.parentSeries.colorMap)!==null&&b!==void 0?b:this.getDefaultColorMap(_)));var C=this.parentSeries.getContourDrawingParams(),P=v.isVerticalChart,x=v.xCoordinateCalculator.getCoordinate(C.xMin),E=v.yCoordinateCalculator.getCoordinate(C.yMin),A=v.xCoordinateCalculator.getCoordinate(C.xMax),R=v.yCoordinateCalculator.getCoordinate(C.yMax),M=Math.abs(x-A),D=function(){y.parentSeries.minorsPerMajor>0&&y.drawContours(g,x,E,A,R,C.zMin,C.zMax,C.zOffset,C.minorStepZ,C.minorLineStyle,C.dataZRange),y.drawContours(g,x,E,A,R,C.zMin,C.zMax,C.zOffset,C.majorStepZ,C.majorLineStyle,C.dataZRange)};if(P){var F=!v.xCoordinateCalculator.hasFlippedCoordinates,I=this.parentSeries.parentSurface.seriesViewRect,V=r.Rect.intersect(this.parentSeries.parentSurface.clipRect,I);g.setTranslationRotationAndClip(V,I.x,I.y+M+(F?A:x),-90),A=F?M:0,x=F?0:M,D()}else D()}},p.prototype.drawContours=function(g,v,y,m,b,S,_,C,P,x,E){var A=(0,s.getVector4)(this.webAssemblyContext,0,1,0,0),R=new this.webAssemblyContext.SCRTContourParams,M=_-S,D=C/M,F=(0,o.parseColorToTArgb)(x.color);R.SetColorVector(F.red/255,F.green/255,F.blue/255,F.opacity/255);var I=E.diff/P;R.SetParamsAVector(x.strokeThickness,I,-D,0);var V=(S-E.min)/E.diff,z=(_-E.min)/E.diff;R.SetParamsBVector(V,z,0,0);var G=g.getNativeContext(),H=this.heightsTextureCache.value,U=(0,s.getVectorColorTextureVertex)(this.webAssemblyContext),k=(0,s.getTextureVertex)(this.webAssemblyContext,v,y,e.NEUTRAL_COLOR,0,0);U.push_back(k);var X=(0,s.getTextureVertex)(this.webAssemblyContext,m,y,e.NEUTRAL_COLOR,1,0);U.push_back(X);var W=(0,s.getTextureVertex)(this.webAssemblyContext,v,b,e.NEUTRAL_COLOR,0,1);U.push_back(W);var Y=(0,s.getTextureVertex)(this.webAssemblyContext,m,b,e.NEUTRAL_COLOR,1,1);U.push_back(Y);var te=new this.webAssemblyContext.SCRTDrawPrimitivesParams;te.SetVerticesVec(U),te.SetHeightMapTexture(H),te.m_vPackedFloatParams=A,te.SetContourParams(R),te.m_Effect=this.webAssemblyContext.SCRTPrimitivesEffect.Heatmap,G.DrawPrimitives(te),te.delete(),R.delete()},p.prototype.computeHeightMap=function(g,v,y,m,b,S){var _,C=g*v;((_=this.heightData)===null||_===void 0?void 0:_.size())!==C&&(this.heightData=(0,i.deleteSafe)(this.heightData),this.heightData=new this.webAssemblyContext.FloatVector,this.heightData.resize(C,0));for(var P=0;P<g;P++)for(var x=0;x<v;x++){var E=m?y[S?x:v-1-x][b?g-P-1:P]:y[S?P:g-1-P][b?v-x-1:x];this.heightData.set(P*v+x,isNaN(E)?-1:E)}return this.heightData},p.prototype.createPaletteTexture=function(g,v,y){if(!e.IS_TEST_ENV){n.Guard.isTrue(g>0,"width must be greater than 0"),n.Guard.isTrue(v>0,"height must be greater than 0");var m=new l.CanvasTexture(this.webAssemblyContext,g,v);m.clear();var b=m.getContext(),S=0,_=0,C=g,P=0;if(y){var x=b.createLinearGradient(S,_,C,P);y.forEach(function(E){x.addColorStop(E.offset,E.color)}),b.fillStyle=x}else b.fillStyle="black";return b.fillRect(0,0,g,v),m.copyTexture(),m}},p.prototype.getDefaultColorMap=function(g){var v=g.zRange;return{minimum:v.min,maximum:v.max}},p})(d.BaseSeriesDrawingProvider);return Bw.UniformContoursDrawingProvider=f,Bw}var jw={},U_e;function Wie(){if(U_e)return jw;U_e=1;var t=jw&&jw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(jw,"__esModule",{value:!0}),jw.UniformHeatmapHitTestProvider=void 0;var e=$i(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=n.hitTestHelpers.getNearestUniformHeatmapPoint(f,h,y,g,v),b=m.xIndex,S=m.yIndex,_=m.zValue,C=new r.HitTestInfo(this.parentSeries);C.seriesName=this.parentSeries.seriesName,C.dataSeriesType=y.type,C.hitTestPoint=new e.Point(g,v);var P=f.getDataValue(g),x=h.getDataValue(v);return C.hitTestPointValues=new e.Point(P,x),C.xValue=P,C.yValue=x,C.heatmapXIndex=b,C.heatmapYIndex=S,C.zValue=_,C.heatmapValue=_,C.xCoord=g,C.yCoord=v,C.isHit=b!==-1&&S!==-1,C.isWithinDataBounds=C.isHit,b!==-1&&S!==-1&&(C.metadata=y.getMetadataAt(S,b)),C},s.prototype.hitTestDataPoint=function(l,u){return this.hitTest(l,u)},s.prototype.hitTestXSlice=function(l,u){return this.hitTest(l,u)},s})(i.BaseHitTestProvider);return jw.UniformHeatmapHitTestProvider=o,jw}var z_e;function vJ(){return z_e||(z_e=1,(function(t){var e=mB&&mB.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.UniformContoursRenderableSeries=t.EContourColorMapMode=t.COLOR_MAP_PREFIX=void 0;var i=mo(),n=Br(),r=ga(),o=hn(),a=kp(),s=Rm(),l=ju(),u=un(),c=Nie(),d=v3e(),f=GW(),h=Wie();t.COLOR_MAP_PREFIX="colorMap.",(function(g){g.AlternateColors="AlternateColors",g.GradientColors="GradientColors"})(t.EContourColorMapMode||(t.EContourColorMapMode={}));var p=(function(g){e(v,g);function v(y,m){var b=this,S,_,C,P;return b=g.call(this,y,m)||this,b.type=o.ESeriesType.UniformContoursSeries,b.colorMapPropertyChanged=b.colorMapPropertyChanged.bind(b),m!=null&&m.colorMap&&("toJSON"in m.colorMap||(m.colorMap=new f.HeatmapColorMap(m.colorMap))),b.colorMap=m==null?void 0:m.colorMap,b.dataSeries=m==null?void 0:m.dataSeries,b.xAxisId=m==null?void 0:m.xAxisId,b.yAxisId=m==null?void 0:m.yAxisId,b.zMin=m==null?void 0:m.zMin,b.zMax=m==null?void 0:m.zMax,b.zStep=(m==null?void 0:m.zStep)||NaN,b.xOffsetProperty=(S=m==null?void 0:m.zOffset)!==null&&S!==void 0?S:0,b.majorLineStyle=(m==null?void 0:m.majorLineStyle)||v.DEFAULT_MAJOR_LINE_STYLE,b.minorLineStyle=(m==null?void 0:m.minorLineStyle)||v.DEFAULT_MINOR_LINE_STYLE,b.minorsPerMajor=(m==null?void 0:m.minorsPerMajor)||0,b.majorLineStyleProperty=m==null?void 0:m.majorLineStyle,b.minorLineStyleProperty=m==null?void 0:m.minorLineStyle,m!=null&&m.zLabelProvider&&("getLabels"in(m==null?void 0:m.zLabelProvider)||(m.zLabelProvider=(0,i.createType)(r.EBaseType.LabelProvider,m.zLabelProvider.type,y,m.zLabelProvider.options))),b.zLabelProviderProperty=(_=m==null?void 0:m.zLabelProvider)!==null&&_!==void 0?_:new s.NumericLabelProvider({labelPrecision:2}),!((C=b.paletteProvider)===null||C===void 0)&&C.onAttached&&((P=b.paletteProvider)===null||P===void 0||P.onAttached(b)),b.dataLabelProviderProperty||(b.dataLabelProviderProperty=new c.ContoursDataLabelProvider(m==null?void 0:m.dataLabels),b.dataLabelProviderProperty.onAttach(b.webAssemblyContext,b)),b.drawingProviders=[],b.drawingProviders.push(new d.UniformContoursDrawingProvider(y,b)),b}return Object.defineProperty(v.prototype,"zMin",{get:function(){return this.zMinProperty},set:function(y){this.zMinProperty=y,this.notifyPropertyChanged(u.PROPERTY.Z_MIN)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"zMax",{get:function(){return this.zMaxProperty},set:function(y){this.zMaxProperty=y,this.notifyPropertyChanged(u.PROPERTY.Z_MAX)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"zStep",{get:function(){return this.zStepProperty},set:function(y){this.zStepProperty=y,this.notifyPropertyChanged(u.PROPERTY.Z_STEP)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"zOffset",{get:function(){return this.xOffsetProperty},set:function(y){this.xOffsetProperty=y,this.notifyPropertyChanged(u.PROPERTY.Z_OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"colorMap",{get:function(){return this.colorMapProperty},set:function(y){var m,b;(m=this.colorMapProperty)===null||m===void 0||m.propertyChanged.unsubscribe(this.colorMapPropertyChanged),this.colorMapProperty=y,(b=this.colorMapProperty)===null||b===void 0||b.propertyChanged.subscribe(this.colorMapPropertyChanged),this.notifyPropertyChanged(u.PROPERTY.COLOR_MAP)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"colorMapMode",{get:function(){return this.colorMapModeProperty},set:function(y){this.colorMapModeProperty=y,this.notifyPropertyChanged(u.PROPERTY.CONTOUR_COLOR_MAP_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"zLabelProvider",{get:function(){return this.zLabelProviderProperty},set:function(y){this.zLabelProviderProperty=y,this.notifyPropertyChanged(u.PROPERTY.Z_LABEL_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"majorLineStyle",{get:function(){return this.majorLineStyleProperty},set:function(y){this.majorLineStyleProperty=y,this.notifyPropertyChanged(u.PROPERTY.CONTOUR_MAJOR_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"minorLineStyle",{get:function(){return this.minorLineStyleProperty},set:function(y){this.minorLineStyleProperty=y,this.notifyPropertyChanged(u.PROPERTY.CONTOUR_MINOR_LINE_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"minorsPerMajor",{get:function(){return this.minorsPerMajorProperty},set:function(y){this.minorsPerMajorProperty=y,this.notifyPropertyChanged(u.PROPERTY.CONTOUR_MINORS_PER_MAJOR)},enumerable:!1,configurable:!0}),v.prototype.getContourDrawingParams=function(){var y,m,b=this.dataSeries,S=b.zRange,_=this.zMin&&(0,a.isRealNumber)(this.zMin)?this.zMin:S.min,C=this.zMax&&(0,a.isRealNumber)(this.zMax)?this.zMax:S.max;_=Math.max(_,S.min),C=Math.min(C,S.max);var P=this.zStep&&(0,a.isRealNumber)(this.zStep)?this.zStep:Math.abs(C-_)/v.DEFAULT_CONTOURS_COUNT,x=this.minorsPerMajor&&this.minorsPerMajor>0?P/(this.minorsPerMajor+1):P,E=(y=this.minorLineStyle)!==null&&y!==void 0?y:{strokeThickness:this.strokeThickness,color:this.stroke},A=(m=this.majorLineStyle)!==null&&m!==void 0?m:{strokeThickness:this.strokeThickness,color:this.stroke},R=this.zOffset,M={xMax:b.xMax,yMin:b.yMin,yMax:b.yMax,xMin:b.xMin,zMin:_,zMax:C,majorStepZ:P,minorStepZ:x,minorLineStyle:E,majorLineStyle:A,zOffset:R,dataZRange:S};return M},v.prototype.toPointSeries=function(y){},v.prototype.delete=function(){g.prototype.delete.call(this),this.zLabelProviderProperty=(0,n.deleteSafe)(this.zLabelProviderProperty)},v.prototype.toJSON=function(y){var m,b;y===void 0&&(y=!1);var S=g.prototype.toJSON.call(this,y),_={colorMap:(m=this.colorMap)===null||m===void 0?void 0:m.toJSON(),majorLineStyle:this.majorLineStyle,minorLineStyle:this.minorLineStyle,zOffset:this.zOffset,zStep:this.zStep,zMax:this.zMax,zMin:this.zMin,minorsPerMajor:this.minorsPerMajor,zLabelProvider:(b=this.zLabelProvider)===null||b===void 0?void 0:b.toJSON()};return Object.assign(S.options,_),S},v.prototype.colorMapPropertyChanged=function(y){this.notifyPropertyChanged(t.COLOR_MAP_PREFIX+y.propertyName)},v.prototype.newHitTestProvider=function(){return new h.UniformHeatmapHitTestProvider(this,this.webAssemblyContext)},v.DEFAULT_CONTOURS_COUNT=15,v.DEFAULT_MAJOR_LINE_STYLE={strokeThickness:2,color:"white"},v.DEFAULT_MINOR_LINE_STYLE={strokeThickness:1,color:"white"},v})(l.BaseRenderableSeries);t.UniformContoursRenderableSeries=p})(mB)),mB}var Vw={},Hw={},$_e;function Gie(){if($_e)return Hw;$_e=1;var t=Hw&&Hw.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(Hw,"__esModule",{value:!0}),Hw.UniformHeatmapDrawingProvider=void 0;var e=Uo(),i=Br(),n=ci(),r=Rn(),o=PW(),a=rR(),s=zI(),l=un(),u=du(),c=an(),d=(function(f){t(h,f);function h(p,g){var v=f.call(this,p,g)||this;return v.heatTextureCache=new o.TextureCache(p),v.recreatePalette(),v.onSeriesPropertyChange(l.PROPERTY.DATA_SERIES),v.onSeriesPropertyChange(l.PROPERTY.COLOR_MAP),v}return h.prototype.delete=function(){this.paletteTexture=(0,i.deleteSafe)(this.paletteTexture),this.heatTextureCache=(0,i.deleteSafe)(this.heatTextureCache),f.prototype.delete.call(this)},h.prototype.onSeriesPropertyChange=function(p){var g=p===l.PROPERTY.COLOR_MAP||p.includes(s.COLOR_MAP_PREFIX)||p===l.PROPERTY.OPACITY,v=p===l.PROPERTY.DATA_SERIES||p===l.PROPERTY.USE_LINEAR_TEXTURE_FILTERING;if(g&&this.recreatePalette(),v){var y=this.parentSeries.dataSeries,m=this.parentSeries,b=m.useLinearTextureFiltering;if(y){var S=this.heatTextureCache.create(y.arrayWidth,y.arrayHeight,this.webAssemblyContext.eTSRTextureFormat.TSR_TEXTUREFORMAT_R32F);this.webAssemblyContext.SCRTSetTextureLinearSamplerEnabled(S,b)}}},h.prototype.draw=function(p,g){var v,y=g.isVerticalChart,m=!g.xCoordinateCalculator.hasFlippedCoordinates;g.yCoordinateCalculator.hasFlippedCoordinates;var b=(v=this.heatTextureCache)===null||v===void 0?void 0:v.value;if(b){var S=this.parentSeries.dataSeries,_=S.getNormalizedVector(this.parentSeries.colorMap,this.parentSeries.fillValuesOutOfRange);this.packedFloatParams=this.webAssemblyContext.SCRTFillTextureFloat32(b,S.arrayWidth,S.arrayHeight,_),this.packedFloatParams.x=0,this.packedFloatParams.y=1;var C=S.xRange,P=S.yRange,x=g.xCoordinateCalculator.getCoordinate(C.min),E=g.yCoordinateCalculator.getCoordinate(P.min),A=g.xCoordinateCalculator.getCoordinate(C.max),R=g.yCoordinateCalculator.getCoordinate(P.max),M=p.getNativeContext(),D=Math.abs(x-A);if(y){var F=this.parentSeries.parentSurface.seriesViewRect,I=r.Rect.intersect(this.parentSeries.parentSurface.clipRect,F);p.setTranslationRotationAndClip(I,F.x,F.y+D+(m?A:x),-90);var V=m?0:D,z=m?D:0,G=E,H=R;this.drawHeatmap(M,V,G,z,H)}else this.drawHeatmap(M,x,E,A,R)}},h.prototype.seriesHasDataChanges=function(){this.onSeriesPropertyChange(l.PROPERTY.DATA_SERIES)},h.prototype.createPaletteTexture=function(p,g,v,y,m){if(!e.IS_TEST_ENV){n.Guard.isTrue(p>0,"width must be greater than 0"),n.Guard.isTrue(g>0,"height must be greater than 0"),n.Guard.notNull(v,"gradientStops");var b=new a.CanvasTexture(this.webAssemblyContext,p,g);b.clear();var S=b.getContext();m&&(S.fillStyle="#ffffff00",S.fillRect(0,0,1,g));var _=0,C=0,P=p,x=0,E=S.createLinearGradient(_,C,P,x);v.forEach(function(R){E.addColorStop(R.offset,R.color)}),S.fillStyle=E,S.globalAlpha=y;var A=m?1:0;return S.fillRect(A,0,p,g),b.copyTexture(),b}},h.prototype.recreatePalette=function(){var p,g,v=(p=this.parentSeries.dataSeries)===null||p===void 0?void 0:p.hasNaNs;this.hasNaNs===v&&this.opacity===this.parentSeries.opacity&&this.gradientStops===((g=this.parentSeries.colorMap)===null||g===void 0?void 0:g.gradientStops)||(this.paletteTexture=(0,i.deleteSafe)(this.paletteTexture),this.parentSeries.colorMap&&this.parentSeries.colorMap.gradientStops&&(this.hasNaNs=v,this.opacity=this.parentSeries.opacity,this.gradientStops=this.parentSeries.colorMap.gradientStops,this.paletteTexture=this.createPaletteTexture(256,1,this.parentSeries.colorMap.gradientStops,this.parentSeries.opacity,v)))},h.prototype.drawHeatmap=function(p,g,v,y,m){var b=this.packedFloatParams,S=new this.webAssemblyContext.SCRTContourParams,_=this.heatTextureCache.value;this.recreatePalette();var C=(0,c.getVectorColorTextureVertex)(this.webAssemblyContext),P=(0,c.getTextureVertex)(this.webAssemblyContext,g,v,e.NEUTRAL_COLOR,0,0);C.push_back(P);var x=(0,c.getTextureVertex)(this.webAssemblyContext,y,v,e.NEUTRAL_COLOR,1,0);C.push_back(x);var E=(0,c.getTextureVertex)(this.webAssemblyContext,g,m,e.NEUTRAL_COLOR,0,1);C.push_back(E);var A=(0,c.getTextureVertex)(this.webAssemblyContext,y,m,e.NEUTRAL_COLOR,1,1);C.push_back(A);var R=new this.webAssemblyContext.SCRTDrawPrimitivesParams;R.SetVerticesVec(C),R.SetGradientTexture(this.paletteTexture.getTexture()),R.SetHeightMapTexture(_),R.m_vPackedFloatParams=b,R.SetContourParams(S),R.m_Effect=this.webAssemblyContext.SCRTPrimitivesEffect.Heatmap,p.DrawPrimitives(R),S.delete(),R.delete(),b.delete()},h})(u.BaseSeriesDrawingProvider);return Hw.UniformHeatmapDrawingProvider=d,Hw}var W_e;function XW(){if(W_e)return Vw;W_e=1;var t=Vw&&Vw.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(Vw,"__esModule",{value:!0}),Vw.UniformHeatmapRenderableSeries=void 0;var e=Uo(),i=hn(),n=zI(),r=tH(),o=Gie(),a=Wie(),s=(function(l){t(u,l);function u(c,d){var f=l.call(this,c,d)||this;return f.type=i.ESeriesType.UniformHeatmapSeries,f.dataLabelProviderProperty||(f.dataLabelProviderProperty=new r.HeatMapDataLabelProvider(d==null?void 0:d.dataLabels),f.dataLabelProviderProperty.onAttach(f.webAssemblyContext,f)),f}return u.prototype.addDrawingProviders=function(c,d){e.IS_TEST_ENV||this.drawingProviders.push(new o.UniformHeatmapDrawingProvider(c,this))},u.prototype.newHitTestProvider=function(){return new a.UniformHeatmapHitTestProvider(this,this.webAssemblyContext)},u})(n.BaseHeatmapRenderableSeries);return Vw.UniformHeatmapRenderableSeries=s,Vw}var Uw={},zw={},G_e;function y3e(){if(G_e)return zw;G_e=1;var t=zw&&zw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(zw,"__esModule",{value:!0}),zw.ScatterSeriesHitTestProvider=void 0;var e=Eo(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u,c){c===void 0&&(c=0);var d=this.getTranslatedHitTestPoint(l,u);if(!d)return r.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries;if(!m)return r.HitTestInfo.empty();var b=n.hitTestHelpers.getNearestXyPoint(this.webAssemblyContext,h,p,m,v,y,c),S=m.getNativeXValues(),_=m.getNativeYValues(),C=n.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,m,S,_,v,y,b.nearestPointIndex,c);if(b.nearestPointIndex>=0){var P=this.parentSeries.pointMarker,x=P.width,E=P.height,A=h.isCategoryCoordinateCalculator,R=A?0:S.get(0),M=h.getCoordinate(R),D=A?S.size()-1:S.get(S.size()-1),F=h.getCoordinate(D);C.isWithinDataBounds=(0,e.testIsInInterval)(v,M,F,x/2),C.isHit=(0,e.testIsInBounds)(v,y,C.xCoord-x/2-c,C.yCoord+E/2+c,C.xCoord+x/2+c,C.yCoord-E/2-c)}else C.isHit=!1;return C},s.prototype.hitTestXSlice=function(l,u){var c=this.getTranslatedHitTestPoint(l,u);if(!c)return r.HitTestInfo.empty();var d=this.currentRenderPassData,f=d.xCoordinateCalculator,h=d.yCoordinateCalculator,p=d.isVerticalChart,g=p?c.y:c.x,v=p?c.x:c.y,y=this.parentSeries.dataSeries;if(!y)return r.HitTestInfo.empty();var m=y.getNativeXValues(),b=y.getNativeYValues(),S=n.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,f,y,g,y.dataDistributionCalculator.isSortedAscending),_=n.hitTestHelpers.createHitTestInfo(this.parentSeries,f,h,p,y,m,b,g,v,S,0);if(S>=0){var C=this.parentSeries.pointMarker.width,P=f.isCategoryCoordinateCalculator,x=void 0,E=void 0;if(y.dataDistributionCalculator.isSortedAscending){var A=P?0:m.get(0);x=f.getCoordinate(A);var R=P?m.size()-1:m.get(m.size()-1);E=f.getCoordinate(R)}else{var M=y.getXRange();x=f.getCoordinate(M.min),E=f.getCoordinate(M.max)}_.isWithinDataBounds=(0,e.testIsInInterval)(g,x,E,C/2),_.isHit=_.isWithinDataBounds}else _.isHit=!1;return _},s})(i.BaseHitTestProvider);return zw.ScatterSeriesHitTestProvider=o,zw}var Y_e;function Yie(){if(Y_e)return Uw;Y_e=1;var t=Uw&&Uw.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(Uw,"__esModule",{value:!0}),Uw.XyScatterRenderableSeries=void 0;var e=hn(),i=Om(),n=MI(),r=ju(),o=un(),a=Wv(),s=Yf(),l=y3e(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y;return p=c.call(this,f,h)||this,p.type=e.ESeriesType.ScatterSeries,p.scatterOpacityProperty=1,p.pointMarker||(p.pointMarker=new n.EllipsePointMarker(f,{width:10,height:10})),h!=null&&h.animation&&p.animationQueue.push(h.animation),p.dataLabelProviderProperty||(p.dataLabelProviderProperty=new a.DataLabelProvider(h==null?void 0:h.dataLabels),p.dataLabelProviderProperty.onAttach(p.webAssemblyContext,p)),!((g=p.paletteProvider)===null||g===void 0)&&g.onAttached&&((v=p.paletteProvider)===null||v===void 0||v.onAttached(p)),p.scatterOpacityProperty=(y=h==null?void 0:h.opacity)!==null&&y!==void 0?y:p.scatterOpacityProperty,p}return d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new s.PointMarkerDrawingProvider(f,this))},d.prototype.needsResampling=function(f){return this.dataSeries.fifoCapacity?(f.resamplingMode=i.EResamplingMode.None,this.resamplerHelper.resetAndFillBasicNativeArgs(f,this.getNativeXValues()),!0):!1},d.prototype.newHitTestProvider=function(){return new l.ScatterSeriesHitTestProvider(this,this.webAssemblyContext)},Object.defineProperty(d.prototype,"opacity",{get:function(){return this.scatterOpacityProperty},set:function(f){this.scatterOpacityProperty=f,this.notifyPropertyChanged(o.PROPERTY.OPACITY),this.pointMarker&&(this.pointMarker.opacity=f,this.notifyPropertyChanged(o.PROPERTY.POINT_MARKER))},enumerable:!1,configurable:!0}),d})(r.BaseRenderableSeries);return Uw.XyScatterRenderableSeries=u,Uw}var $w={},Ww={},q_e;function m3e(){if(q_e)return Ww;q_e=1;var t=Ww&&Ww.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(Ww,"__esModule",{value:!0}),Ww.LineSegmentSeriesDrawingProvider=void 0;var e=Br(),i=Yo(),n=Ls(),r=zi(),o=un(),a=du(),s=(function(l){t(u,l);function u(c,d,f,h){var p=l.call(this,c,d,f,h)||this;return p.linesPenCache=new n.Pen2DCache(c),p.args=new c.SCRTLineDrawingParams,p}return u.prototype.onDpiChanged=function(c){l.prototype.onDpiChanged.call(this,c),this.onSeriesPropertyChange(o.PROPERTY.STROKE)},u.prototype.onSeriesPropertyChange=function(c){if(l.prototype.onSeriesPropertyChange.call(this,c),c===o.PROPERTY.PALETTE_PROVIDER&&this.linesPenCache.invalidateCache(),c===o.PROPERTY.STROKE||c===o.PROPERTY.STROKE_THICKNESS||c===o.PROPERTY.PALETTE_PROVIDER||c===o.PROPERTY.OPACITY||c===o.PROPERTY.STROKE_DASH_ARRAY){this.palettingState.requiresUpdate=!0;var d=this.getProperties(this.parentSeries),f=d.stroke,h=d.strokeThickness,p=d.opacity,g=d.strokeDashArray;f&&(0,n.createPenInCache)(this.linesPenCache,f,h,p??1,g,!0)}},u.prototype.getProperties=function(c){var d,f=c.stroke,h=c.strokeThickness,p=c.opacity,g=c.strokeDashArray,v=c.dataSeries;return{stroke:f,strokeThickness:h,opacity:p,strokeDashArray:g,dataSeriesType:(d=v==null?void 0:v.type)!==null&&d!==void 0?d:r.EDataSeriesType.Xy}},u.prototype.onAttachSeries=function(){l.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTLineSegmentDrawingProvider;var c=this.getProperties(this.parentSeries),d=c.stroke,f=c.strokeThickness,h=c.opacity,p=c.strokeDashArray;d&&(0,n.createPenInCache)(this.linesPenCache,d,f,h??1,p,!0)},u.prototype.onDetachSeries=function(){l.prototype.onDetachSeries.call(this),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider)},u.prototype.getStartAndCount=function(c,d){var f,h,p,g=c==null?void 0:c.pointSeries,v=(f=this.parentSeries)===null||f===void 0?void 0:f.xAxis,y=(h=v==null?void 0:v.clipToXRange)!==null&&h!==void 0?h:!0,m=d.size(),b=Math.min(g?g.xValues.size():m,m),S=0;return y&&!(g!=null&&g.resampled)&&((p=c==null?void 0:c.indexRange)===null||p===void 0?void 0:p.diff)>=0&&(c.indexRange.diff+1<b&&(S=c.indexRange.min),b=Math.min(c.indexRange.diff+1,b),S%2===1&&(S--,b++)),{startIndex:S,count:b}},u.prototype.updateArgs=function(c){},u.prototype.drawXy=function(c,d){var f=this.getProperties(this.parentSeries).stroke,h=(0,n.getScrtPenFromCache)(this.linesPenCache);if(!(!h||!f)){this.args.Reset(),this.args.SetLinesPen(h),this.args.forceShaderMethod=!0,this.args.forceClamp=!0,this.args.verticalChart=d.isVerticalChart;var p=d.xCoordinateCalculator.isCategoryCoordinateCalculator;if(p){console.error("Category Axis is not supported for LineSegmentRenderableSeries");return}var g=d.pointSeries,v=this.xSelector(g),y=this.ySelector(g),m=this.getStartAndCount(d,v),b=m.startIndex,S=m.count;this.args.count=S,this.args.startIndex=b,this.applyStrokePaletting(h,d),this.palettingState.palettedColors&&this.args.SetPalettedColors(this.palettingState.palettedColors),this.updateArgs(d);var _=c.getNativeContext();this.drawLines(c,_,v,y,d.xCoordinateCalculator.nativeCalculator,d.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect)}},u.prototype.drawXyXy=function(c,d){var f=this.getProperties(this.parentSeries).stroke,h=(0,n.getScrtPenFromCache)(this.linesPenCache);if(!(!h||!f)){this.args.Reset(),this.args.fourVectorsMode=!0,this.args.SetLinesPen(h),this.args.forceShaderMethod=!0,this.args.verticalChart=d.isVerticalChart;var p=d.xCoordinateCalculator.isCategoryCoordinateCalculator;if(p){console.error("Category Axis is not supported for LineSegmentRenderableSeries");return}var g=d.pointSeries,v=this.xSelector(g),y=this.ySelector(g),m=g.getYValuesByName(i.EValueName.X1),b=g.getYValuesByName(i.EValueName.Y1),S=this.getStartAndCount(d,v),_=S.startIndex,C=S.count;this.args.count=C,this.args.startIndex=_,this.args.SetZValues(m),this.args.SetWValues(b),this.applyStrokePaletting(h,d),this.palettingState.palettedColors&&(this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.SetPalettedColors2(this.palettingState.palettedColors)),this.updateArgs(d);var P=c.getNativeContext();this.drawLines(c,P,v,y,d.xCoordinateCalculator.nativeCalculator,d.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect)}},u.prototype.draw=function(c,d){var f=this.getProperties(this.parentSeries).dataSeriesType;f===r.EDataSeriesType.Xyxy?this.drawXyXy(c,d):this.drawXy(c,d)},u.prototype.delete=function(){this.linesPenCache=(0,e.deleteSafe)(this.linesPenCache),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),l.prototype.delete.call(this)},u.prototype.drawLines=function(c,d,f,h,p,g,v,y){v.count<=0||(v.SetNativeContext(d),v.SetXValues(f),v.SetYValues(h),v.SetXCoordinateCalculator(p),v.SetYCoordinateCalculator(g),this.nativeDrawingProvider.DrawLinesVec(v))},u})(a.BaseSeriesDrawingProvider);return Ww.LineSegmentSeriesDrawingProvider=s,Ww}var Gw={},X_e;function b3e(){if(X_e)return Gw;X_e=1;var t=Gw&&Gw.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(Gw,"__esModule",{value:!0}),Gw.LineSegmentSeriesHitTestProvider=void 0;var e=zi(),i=Vl(),n=vl(),r=tl(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.hitTest=function(l,u,c){c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var d=this.parentSeries.dataSeries.type;return d===e.EDataSeriesType.Xyxy?this.hitTestXyXy(l,u,c):this.hitTestXy(l,u,c)},s.prototype.hitTestXy=function(l,u,c){c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var d=this.getTranslatedHitTestPoint(l,u);if(!d)return r.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries;if(!m)return r.HitTestInfo.empty();var b=m.getNativeXValues(),S=m.getNativeYValues(),_=b.size();if(_<2)return r.HitTestInfo.empty();var C=function(G){return b.get(2*G)},P=function(G){return S.get(2*G)},x=function(G){return b.get(2*G+1)},E=function(G){return S.get(2*G+1)},A=n.hitTestHelpers.getNearestLineSegment(h,p,_/2,C,P,x,E,v,y,c),R=A.isHit,M=A.isWithinDataBounds,D=A.nearestPointIndex,F=A.nearestDistance,I=D>=0?D*2:-1,V=n.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,m,b,S,v,y,I,c,F);if(I!==-1){V.dataSeriesIndex=I,V.isWithinDataBounds=M,V.isHit=R,V.xValue=b.get(I),V.xCoord=h.getCoordinate(V.xValue),V.yValue=S.get(I),V.yCoord=p.getCoordinate(V.yValue),V.point2dataSeriesIndex=I+1,V.point2xValue=b.get(I+1),V.point2xCoord=h.getCoordinate(V.point2xValue),V.point2yValue=S.get(I+1),V.point2yCoord=p.getCoordinate(V.point2yValue),V.point2metadata=m.getMetadataAt(I+1);var z=m.valueNames.reduce(function(G,H){return G[H]=m.getNativeValue(m.getYValuesByName(H),V.point2dataSeriesIndex),G},{});V.point2yValueByName=z}return V},s.prototype.hitTestXyXy=function(l,u,c){c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS);var d=this.getTranslatedHitTestPoint(l,u);if(!d)return r.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries;if(!m)return r.HitTestInfo.empty();var b=m.getNativeXValues(),S=m.yValues,_=m.x1Values,C=m.y1Values,P=b.size();if(P<1)return r.HitTestInfo.empty();var x=function(H){return b.get(H)},E=function(H){return S.get(H)},A=function(H){return _.get(H)},R=function(H){return C.get(H)},M=n.hitTestHelpers.getNearestLineSegment(h,p,P,x,E,A,R,v,y,c),D=M.isHit,F=M.isWithinDataBounds,I=M.nearestPointIndex,V=M.nearestDistance,z=n.hitTestHelpers.createHitTestInfo(this.parentSeries,h,p,g,m,b,S,v,y,I,c,V);if(I!==-1){z.dataSeriesIndex=I,z.isWithinDataBounds=F,z.isHit=D,z.xValue=b.get(I),z.xCoord=h.getCoordinate(z.xValue),z.yValue=S.get(I),z.yCoord=p.getCoordinate(z.yValue),z.point2dataSeriesIndex=I,z.point2xValue=_.get(I),z.point2xCoord=h.getCoordinate(z.point2xValue),z.point2yValue=C.get(I),z.point2yCoord=p.getCoordinate(z.point2yValue),z.point2metadata=m.getMetadataAt(I);var G=m.valueNames.reduce(function(H,U){return H[U]=m.getNativeValue(m.getYValuesByName(U),z.point2dataSeriesIndex),H},{});z.point2yValueByName=G}return z},s.prototype.hitTestForDataPointSelectionModifier=function(l,u,c){return c===void 0&&(c=i.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(l,u,c)},s.prototype.hitTestXSlice=function(l,u){return this.hitTest(l,u)},s.prototype.hitTestDataPoint=function(l,u,c){return this.hitTest(l,u)},s})(i.BaseHitTestProvider);return Gw.LineSegmentSeriesHitTestProvider=o,Gw}var K_e;function S3e(){if(K_e)return $w;K_e=1;var t=$w&&$w.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty($w,"__esModule",{value:!0}),$w.FastLineSegmentRenderableSeries=void 0;var e=hn(),i=wm(),n=mm(),r=fR(),o=m3e(),a=Yf(),s=b3e(),l=(function(u){t(c,u);function c(d,f){var h=this,p,g;return h=u.call(this,d,f)||this,h.type=e.ESeriesType.LineSegmentSeries,h.dataLabelProviderProperty||(h.dataLabelProviderProperty=new r.LineSeriesDataLabelProvider(f==null?void 0:f.dataLabels),h.dataLabelProviderProperty.onAttach(h.webAssemblyContext,h)),!((p=h.paletteProvider)===null||p===void 0)&&p.onAttached&&((g=h.paletteProvider)===null||g===void 0||g.onAttached(h)),h}return c.prototype.toPointSeries=function(d){return new i.BasePointSeriesWrapped(this.dataSeries)},c.prototype.addDrawingProviders=function(d,f){this.drawingProviders.push(new o.LineSegmentSeriesDrawingProvider(d,this)),this.drawingProviders.push(new a.PointMarkerDrawingProvider(d,this))},c.prototype.newHitTestProvider=function(){return new s.LineSegmentSeriesHitTestProvider(this,this.webAssemblyContext)},c})(n.BaseLineRenderableSeries);return $w.FastLineSegmentRenderableSeries=l,$w}var Yw={},qw={},Z_e;function _3e(){if(Z_e)return qw;Z_e=1;var t=qw&&qw.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(qw,"__esModule",{value:!0}),qw.RectangleSeriesDrawingProvider=void 0;var e=Br(),i=Vd(),n=Yo(),r=tu(),o=Ls(),a=un(),s=du(),l=(function(u){t(c,u);function c(d,f,h,p){var g=u.call(this,d,f,h,p)||this;return g.nativeDrawingProvider=new d.SCRTRectangleSeriesDrawingProvider,g.args=new g.webAssemblyContext.SCRTRectangleDrawingParams,g.strokePenCache=new o.Pen2DCache(d),g.strokePenFillColoredCache=new o.Pen2DCache(d),g.fillBrushCache=new r.BrushCache(d),g}return c.prototype.onAttachSeries=function(){u.prototype.onAttachSeries.call(this);var d=this.getProperties(this.parentSeries),f=d.stroke,h=d.strokeThickness,p=d.fill,g=d.opacity;(0,o.createPenInCache)(this.strokePenCache,f,h,g),h===0&&(0,o.createPenInCache)(this.strokePenFillColoredCache,p,1,g),this.createBrush()},c.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.strokePenFillColoredCache=(0,e.deleteSafe)(this.strokePenFillColoredCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),u.prototype.delete.call(this)},c.prototype.getProperties=function(d){var f=d.stroke,h=d.strokeThickness,p=d.opacity,g=d.fill,v=d.fillLinearGradient,y=d.customTextureOptions;return{stroke:f,strokeThickness:h,opacity:p,fill:g,fillLinearGradient:v,customTextureOptions:y}},c.prototype.draw=function(d,f){var h=f.pointSeries,p=this.parentSeries.parentSurface.seriesViewRect,g=this.getProperties(this.parentSeries).strokeThickness;this.args.Reset(),this.args.verticalChart=f.isVerticalChart,this.args.columnWidth=this.parentSeries.getDataPointWidth(f.xCoordinateCalculator,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),this.args.bottomRadius=this.parentSeries.topCornerRadius,this.args.topRadius=this.parentSeries.bottomCornerRadius,this.args.xMode=(0,i.convertColumnMode)(this.parentSeries.columnXMode,this.webAssemblyContext),this.args.defaultY2=this.parentSeries.defaultY1,this.args.yMode=(0,i.convertYColumnMode)(this.parentSeries.columnYMode,this.webAssemblyContext);var v=this.strokePenCache;this.args.columnWidth===1&&g===0&&(this.args.columnWidth=0,v=this.strokePenFillColoredCache);var y=(0,o.getScrtPenFromCache)(v);y&&this.args.SetLinesPen(y);var m=(0,r.getScrtBrushFromCache)(this.fillBrushCache);m&&this.args.SetFillBrush(m),this.args.viewportWidth=p.width,this.args.viewportHeight=p.height,u.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,y,this.parentSeries.fill,m,this.parentSeries.opacity,!1,this.parentSeries.fillLinearGradient!==void 0),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=this.palettingState.paletteStartIndex;var b=f.xCoordinateCalculator.isCategoryCoordinateCalculator,S=this.xSelector(h),_=this.ySelector(h),C=b?h.indexes:S,P=this.getStartAndCount(f,C),x=P.startIndex,E=P.count;if(this.args.count=E,this.args.startIndex=x,this.args.SetXValues(C),_&&this.args.SetYValues(_),this.parentSeries.columnXMode===i.EColumnMode.MidWidth||this.parentSeries.columnXMode===i.EColumnMode.StartEnd||this.parentSeries.columnXMode===i.EColumnMode.StartWidth){var A=h.getYValuesByName(n.EValueName.X1);if(A)this.args.SetZValues(A);else throw new Error("columnMode ".concat(this.parentSeries.columnXMode," requires an DataSeries with a yValue called ").concat(n.EValueName.X1))}var R=h.getYValuesByName(n.EValueName.Y1);R&&this.args.SetWValues(R);var M=this.parentSeries.dataSeries,D=M.fifoCapacity,F=M.fifoSweeping,I=M.fifoSweepingGap,V=h.fifoStartIndex;F&&D===this.parentSeries.dataSeries.count()&&(this.args.count=V);var z=d.getNativeContext();this.args.SetNativeContext(z),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPoints(this.args),F&&D===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(_.size(),V+I),this.args.count=Math.max(0,_.size()-V-I),this.args.count>0&&this.nativeDrawingProvider.DrawPoints(this.args))},c.prototype.onDpiChanged=function(d){u.prototype.onDpiChanged.call(this,d),this.onSeriesPropertyChange(a.PROPERTY.STROKE)},c.prototype.onSeriesPropertyChange=function(d){u.prototype.onSeriesPropertyChange.call(this,d);var f=this.parentSeries,h=f.stroke,p=f.strokeThickness,g=f.opacity,v=f.fill;(d===a.PROPERTY.STROKE||d===a.PROPERTY.STROKE_THICKNESS||d===a.PROPERTY.OPACITY)&&(0,o.createPenInCache)(this.strokePenCache,h,p,g),(d===a.PROPERTY.FILL||d===a.PROPERTY.OPACITY||d===a.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&this.createBrush(),p===0&&(d===a.PROPERTY.STROKE_THICKNESS||d===a.PROPERTY.STROKE||d===a.PROPERTY.OPACITY||d===a.PROPERTY.FILL)&&(0,o.createPenInCache)(this.strokePenFillColoredCache,v,1,g)},c.prototype.createBrush=function(){this.parentSeries.parentSurface;var d=this.getProperties(this.parentSeries),f=d.fillLinearGradient,h=d.fill,p=d.opacity,g=d.customTextureOptions,v=this.fillBrushCache.create(h,p,1,1,f,g);return v.scrtBrush},c})(s.BaseSeriesDrawingProvider);return qw.RectangleSeriesDrawingProvider=l,qw}var Xw={},bB={},J_e;function P3e(){if(J_e)return bB;J_e=1,Object.defineProperty(bB,"__esModule",{value:!0}),bB.hitTestHelpersRectangleSeries=void 0;var t=Vd(),e=bo();function i(a,s,l,u,c,d,f){var h=a?a.get(d):1,p=s?s.get(d):c,g=h,v=p;switch(f){case t.EColumnYMode.TopBottom:break;case t.EColumnYMode.TopHeight:v=h-p;break;case t.EColumnYMode.CenterHeight:var y=p/2;g=h+y,v=h-y;break}var m=l.getCoordinate(g),b=l.getCoordinate(v),S=Math.max(m,b),_=Math.min(m,b);return _<=u&&u<=S}function n(a,s,l,u,c,d,f,h,p,g,v,y,m){var b,S=s.getDataValue(f),_=[[S,f]];if(m){var C=f-2*Math.PI,P=s.getDataValue(C);_.push([P,C]);var x=f+2*Math.PI,E=s.getDataValue(x);_.push([E,x])}var A=u.size(),R=s.isFlipped?-1:1,M=v===t.EColumnMode.Mid?0:g/2,D=s.getDataWidth(M),F=function(de,ge){var Ee=a.NumberUtil.FindIndex(u,de-D,a.SCRTFindIndexSearchMode.Nearest,!0);if(Ee===-1)return{index:-1,dist:Number.MAX_VALUE,xCoord:void 0,xHitCoord:void 0};var Re=s.getCoordinate(u.get(Ee)),Ae=Math.abs(Re+R*M-ge);return{index:Ee,dist:Ae,xCoord:Re,xHitCoord:ge}},I=-1,V=Number.MAX_VALUE,z=void 0,G=void 0;if(_.forEach(function(de){var ge=de[0],Ee=de[1],Re=F(ge,Ee);Re.index>=0&&Re.dist<V&&(I=Re.index,V=Re.dist,z=Re.xCoord,G=Re.xHitCoord)}),I===-1)return{isHit:!1,nearestPointIndex:-1,isWithinDataBounds:!1};var H=V<=g/2,U=i(c,d,l,h,p,I,y),k=!1;I>0&&I<A-1&&(k=!0),u.size()<=1?k=H:s.isFlipped?(I===0&&(G<=z+R*M||H)&&(k=!0),I===A-1&&(G>=z+R*M||H)&&(k=!0)):(I===0&&(G>=z+R*M||H)&&(k=!0),I===A-1&&(G<=z+R*M||H)&&(k=!0));var X=s.isCategoryCoordinateCalculator,W=X?I:u.get(I),Y=c.get(I),te=void 0,oe=(b=d==null?void 0:d.get)===null||b===void 0?void 0:b.call(d,I);return{nearestPointIndex:I,isHit:H&&U,isWithinDataBounds:k,xValue:W,yValue:Y,x1Value:te,y1Value:oe}}function r(a,s,l,u,c,d,f,h,p,g,v,y,m,b,S){var _,C,P=u.size(),x=v/2,E=-1,A=Number.MAX_VALUE,R=!1,M=void 0,D=Number.MAX_VALUE,F=Number.NEGATIVE_INFINITY,I=function(Ne,ve,pe){var fe=ve-pe,me=pe-Ne;return fe>=0&&me>=0?0:Math.min(Math.abs(fe),Math.abs(me))},V=function(Ne,ve){var pe=I(Ne,ve,h),fe=pe,me=h;if(S&&!b){var Ce=h-2*Math.PI,Ue=h+2*Math.PI;[Ce,Ue].forEach(function(Qe){var it=I(Ne,ve,Qe);it<fe&&(fe=it,me=Qe)})}return{xCoordDist:fe,xHitCoord:me,isHit:fe===0}},z=function(Ne,ve,pe){Ne<D&&(D=Ne),ve>F&&(F=ve);var fe=i(d,f,l,p,g,pe,m),me=V(Ne,ve),Ce=me.isHit,Ue=me.xCoordDist,Qe=me.xHitCoord,it=Ce&&fe;R?it&&Ue<A&&(E=pe,A=Ue,M=Qe):it?(R=!0,E=pe,A=Ue,M=Qe):Ue<A&&(E=pe,A=Ue,M=Qe)},G=s.isFlipped,H=(0,e.vectorToArrayViewF64)(u,a),U=c?(0,e.vectorToArrayViewF64)(c,a):void 0;switch(y){case t.EColumnMode.Mid:for(var k=0;k<P;k++){var X=H[k],W=s.getCoordinate(X),Y=W-x,te=W+x;z(Y,te,k)}break;case t.EColumnMode.Start:for(var k=0;k<P;k++){var oe=H[k],W=s.getCoordinate(oe),Y=G?W-v:W,te=G?W:W+v;z(Y,te,k)}break;case t.EColumnMode.MidWidth:for(var k=0;k<P;k++){var de=H[k],ge=U[k],Y=s.getCoordinate(de-ge/2),te=s.getCoordinate(de+ge/2);G?z(te,Y,k):z(Y,te,k)}break;case t.EColumnMode.StartWidth:for(var k=0;k<P;k++){var Ee=H[k],ge=U[k],Y=s.getCoordinate(Ee),te=s.getCoordinate(Ee+ge);G?z(te,Y,k):z(Y,te,k)}break;case t.EColumnMode.StartEnd:for(var k=0;k<P;k++){var Re=H[k],Ae=U[k],Y=s.getCoordinate(Re),te=s.getCoordinate(Ae);G?z(te,Y,k):z(Y,te,k)}break}if(E===-1)return{isHit:!1,nearestPointIndex:-1,isWithinDataBounds:!1};var Pe=s.isCategoryCoordinateCalculator,we=Pe?E:u.get(E),Te=d.get(E),ke=Pe?E:(_=c==null?void 0:c.get)===null||_===void 0?void 0:_.call(c,E),$e=(C=f==null?void 0:f.get)===null||C===void 0?void 0:C.call(f,E);return{isHit:A===0&&i(d,f,l,p,g,E,m),nearestPointIndex:E,isWithinDataBounds:D<=M&&M<=F,xValue:we,x1Value:ke,yValue:Te,y1Value:$e}}function o(a,s,l,u,c,d,f,h,p,g,v,y,m,b,S,_){return b?r(a,s,l,u,c,d,f,h,p,g,v,y,m,!0,_):S&&(y===t.EColumnMode.Mid||y===t.EColumnMode.Start)?n(a,s,l,u,d,f,h,p,g,v,y,m,_):r(a,s,l,u,c,d,f,h,p,g,v,y,m,!1,_)}return bB.hitTestHelpersRectangleSeries={hitTestForBoxSorted:n,hitTestForBoxUnsorted:r,hitTestForBox:o},bB}var Q_e;function KW(){if(Q_e)return Xw;Q_e=1;var t=Xw&&Xw.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(Xw,"__esModule",{value:!0}),Xw.RectangleSeriesHitTestProvider=void 0;var e=$i(),i=Yo(),n=An(),r=Vl(),o=vl(),a=P3e(),s=tl(),l=(function(u){t(c,u);function c(){return u!==null&&u.apply(this,arguments)||this}return c.prototype.getTranslatedHitTestPoint=function(d,f){if(!(!this.currentRenderPassData||d===void 0||f===void 0)){var h=(0,n.translateFromCanvasToSeriesViewRect)(new e.Point(d,f),this.parentSeries.parentSurface.seriesViewRect);if(h)return this.isPolar()?this.parentSeries.xAxis.reverseTransform(h.x,h.y,!1):h}},c.prototype.hitTest=function(d,f){var h=this.getTranslatedHitTestPoint(d,f);if(!h)return s.HitTestInfo.empty();var p=this.currentRenderPassData,g=p.xCoordinateCalculator,v=p.yCoordinateCalculator,y=p.isVerticalChart,m=y?h.y:h.x,b=y?h.x:h.y,S=this.parentSeries.dataSeries;if(!S)return s.HitTestInfo.empty();var _=S.getNativeXValues(),C=S.getYValuesByName(i.EValueName.X1),P=S.getYValuesByName(i.EValueName.Y),x=S.getYValuesByName(i.EValueName.Y1),E=this.parentSeries,A=E.getDataPointWidth,R=E.dataPointWidth,M=E.defaultY1,D=E.columnXMode,F=E.columnYMode,I=E.dataPointWidthMode,V=A(g,R,I),z=this.hitTestForBox(this.webAssemblyContext,g,v,_,C,P,x,m,b,M,V,D,F,y,this.isPolar()),G=z.nearestPointIndex,H=z.isHit,U=z.isWithinDataBounds,k=z.xValue,X=z.yValue,W=z.x1Value,Y=z.y1Value,te=o.hitTestHelpers.createHitTestInfo(this.parentSeries,g,v,y,S,_,P,m,b,G,0);return te.isHit=H,te.isWithinDataBounds=U,te.xValue=k,te.yValue=X,te.x1Value=W,te.y1Value=Y,te},c.prototype.hitTestForDataPointSelectionModifier=function(d,f,h){return h===void 0&&(h=r.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(d,f)},c.prototype.hitTestXSlice=function(d,f){return this.hitTest(d,f)},c.prototype.hitTestDataPoint=function(d,f,h){return this.hitTest(d,f)},c.prototype.hitTestForBox=function(d,f,h,p,g,v,y,m,b,S,_,C,P,x,E){return a.hitTestHelpersRectangleSeries.hitTestForBoxUnsorted(d,f,h,p,g,v,y,m,b,S,_,C,P,x,E)},c.prototype.isPolar=function(){return this.parentSeries.parentSurface.isPolar},c})(r.BaseHitTestProvider);return Xw.RectangleSeriesHitTestProvider=l,Xw}var Kw={},SB={},ePe;function C3e(){if(ePe)return SB;ePe=1,Object.defineProperty(SB,"__esModule",{value:!0}),SB.dataLabelHelpers=void 0;var t=Vd();function e(r,o,a,s){var l=Math.min(a,s),u=Math.max(a,s);return r===t.EColumnMode.Mid||r===t.EColumnMode.MidWidth?(l=a-s/2,u=a+s/2):r===t.EColumnMode.Start?(l=a,u=a+s):r===t.EColumnMode.StartWidth&&(o?(l=a-s,u=a):(l=a,u=a+s)),{min:l,max:u}}function i(r,o,a,s){var l=Math.min(a,s),u=Math.max(a,s);return r===t.EColumnYMode.CenterHeight?(l=a-s/2,u=a+s/2):r===t.EColumnYMode.TopHeight&&(o?(l=a-s,u=a):(l=a,u=a+s)),{min:l,max:u}}function n(r,o,a,s,l,u,c,d,f){if(f){var h=e(r,!a,u,d),p=h.min,g=h.max,v=i(o,!s,l,c),y=v.min,m=v.max;return{xMin:y,xMax:m,yMin:p,yMax:g}}else{var b=e(r,a,l,c),y=b.min,m=b.max,S=i(o,s,u,d),p=S.min,g=S.max;return{xMin:y,xMax:m,yMin:p,yMax:g}}}return SB.dataLabelHelpers={calcRectangleBorders:n},SB}var Zw={},tPe;function T3e(){if(tPe)return Zw;tPe=1;var t=Zw&&Zw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Zw,"__esModule",{value:!0}),Zw.RectangleDataLabelState=void 0;var e=Vd(),i=Yo(),n=UI(),r=(function(o){t(a,o);function a(s,l,u,c,d,f){var h=o.call(this,s,l,u,c,d,f)||this;h.x1CoordCache=void 0,h.y1CoordCache=void 0;var p=l.pointSeries;return h.x1Values=p.getYValuesByName(i.EValueName.X1),h.defaultY1=f.defaultY1,h.y1Values=p.getYValuesByName(i.EValueName.Y1),h.columnXMode=f.columnXMode,h.columnYMode=f.columnYMode,h.columnWidth=h.parentSeries.getDataPointWidth(l.xCoordinateCalculator,f.dataPointWidth,f.dataPointWidthMode),h}return a.prototype.x1Val=function(s){return this.parentSeries.dataSeries.getNativeValue(this.x1Values,this.getIndexInternal(s))},a.prototype.y1Val=function(s){return this.y1Values?this.parentSeries.dataSeries.getNativeValue(this.y1Values,this.getIndexInternal(s)):this.defaultY1},a.prototype.x1Coord=function(s){if(this.renderPassData.isVerticalChart)return this.y1CoordInternal(s);var l=this.x1CoordInternal(s);return l},Object.defineProperty(a.prototype,"index",{get:function(){return this.indexProperty},set:function(s){this.xCoordCache=void 0,this.yCoordCache=void 0,this.x1CoordCache=void 0,this.y1CoordCache=void 0,this.indexProperty=s},enumerable:!1,configurable:!0}),a.prototype.y1Coord=function(s){return this.renderPassData.isVerticalChart?this.x1CoordInternal(s):this.y1CoordInternal(s)},a.prototype.x1CoordForXColumnModes=function(s){return this.columnXMode===e.EColumnMode.MidWidth||this.columnXMode===e.EColumnMode.StartWidth?this.renderPassData.xCoordinateCalculator.getCoordWidth(this.x1Val(s)):this.columnXMode===e.EColumnMode.Start||this.columnXMode===e.EColumnMode.Mid?this.columnWidth:this.renderPassData.xCoordinateCalculator.getCoordinate(this.x1Val(s))},a.prototype.x1CoordInternal=function(s){return s!==void 0?this.x1CoordForXColumnModes(s):this.x1CoordCache!==void 0?this.x1CoordCache:(this.x1CoordCache=this.x1CoordForXColumnModes(),this.x1CoordCache)},a.prototype.y1CoordForYColumnModes=function(s){return this.columnYMode===e.EColumnYMode.CenterHeight||this.columnYMode===e.EColumnYMode.TopHeight?this.renderPassData.yCoordinateCalculator.getCoordWidth(this.y1Val(s)):this.renderPassData.yCoordinateCalculator.getCoordinate(this.y1Val(s))},a.prototype.y1CoordInternal=function(s){return s!==void 0?this.y1CoordForYColumnModes(s):this.y1CoordCache!==void 0?this.y1CoordCache:(this.y1CoordCache=this.y1CoordForYColumnModes(),this.y1CoordCache)},a})(n.DataLabelState);return Zw.RectangleDataLabelState=r,Zw}var rPe;function qie(){if(rPe)return Kw;rPe=1;var t=Kw&&Kw.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(Kw,"__esModule",{value:!0}),Kw.RectangleSeriesDataLabelProvider=void 0;var e=$i(),i=Ac(),n=C3e(),r=Wv(),o=T3e(),a=id(),s=(function(l){t(u,l);function u(c){var d=l.call(this,c)||this;return d.type=i.EDataLabelProviderType.Rectangle,d}return u.prototype.getDataLabelState=function(c,d,f,h,p,g){return new o.RectangleDataLabelState(c,d,f,h,p,g)},u.prototype.getPosition=function(c,d){var f=this.parentSeries,h=f.columnXMode,p=f.columnYMode,g=n.dataLabelHelpers.calcRectangleBorders(h,p,!c.isXFlipped,c.isYFlipped,c.xCoord(),c.yCoord(),c.x1Coord(),c.y1Coord(),c.isVerticalChart),v=g.xMin,y=g.xMax,m=g.yMin,b=g.yMax,S=(v+y)/2,_=(m+b)/2,C=new e.Point(S,_),P=d.GetLineBounds(0),x=d.m_fHeight-P.m_fHeight;P.delete();var E=S,A=_-x;return E-=d.m_fWidth/2,A+=(0,a.getTextHeightToBaseline)(d)/2,{position:new e.Point(E,A),rotationAngle:0,rotationCenter:C}},u.prototype.toJSON=function(){var c=l.prototype.toJSON.call(this),d={};return Object.assign(c.options,d),c},u})(r.DataLabelProvider);return Kw.RectangleSeriesDataLabelProvider=s,Kw}var iPe;function Xie(){if(iPe)return Yw;iPe=1;var t=Yw&&Yw.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})();Object.defineProperty(Yw,"__esModule",{value:!0}),Yw.FastRectangleRenderableSeries=void 0;var e=Br(),i=di(),n=Vd(),r=Em(),o=hn(),a=Yo(),s=zi(),l=Xs(),u=Sn(),c=ju(),d=un(),f=_3e(),h=KW(),p=qie(),g=Om(),v=(function(y){t(m,y);function m(b,S){var _=this,C,P,x,E,A,R,M,D,F,I,V,z;return S&&(S.resamplingMode=(C=S.resamplingMode)!==null&&C!==void 0?C:g.EResamplingMode.None),_=y.call(this,b,S)||this,_.type=o.ESeriesType.RectangleSeries,_.defaultY1Property=0,_.fillProperty=u.SciChartSurfaceBase.DEFAULT_THEME.columnFillBrush,_.dataPointWidthProperty=1,_.dataPointWidthModeProperty=r.EDataPointWidthMode.Range,_.columnXModeProperty=n.EColumnMode.Mid,_.columnYModeProperty=n.EColumnYMode.TopBottom,_.topCornerRadiusProperty=0,_.bottomCornerRadiusProperty=0,_.fillProperty=(P=S==null?void 0:S.fill)!==null&&P!==void 0?P:_.fillProperty,_.defaultY1Property=(x=S==null?void 0:S.defaultY1)!==null&&x!==void 0?x:_.defaultY1Property,_.dataPointWidthProperty=(E=S==null?void 0:S.dataPointWidth)!==null&&E!==void 0?E:_.dataPointWidthProperty,_.dataPointWidthModeProperty=(A=S==null?void 0:S.dataPointWidthMode)!==null&&A!==void 0?A:_.dataPointWidthModeProperty,_.fillLinearGradientProperty=(R=S==null?void 0:S.fillLinearGradient)!==null&&R!==void 0?R:_.fillLinearGradientProperty,_.topCornerRadiusProperty=(M=S==null?void 0:S.topCornerRadius)!==null&&M!==void 0?M:_.topCornerRadiusProperty,_.bottomCornerRadiusProperty=(D=S==null?void 0:S.bottomCornerRadius)!==null&&D!==void 0?D:_.bottomCornerRadiusProperty,_.columnXModeProperty=(F=S==null?void 0:S.columnXMode)!==null&&F!==void 0?F:_.columnXModeProperty,_.columnYModeProperty=(I=S==null?void 0:S.columnYMode)!==null&&I!==void 0?I:_.columnYModeProperty,_.customTextureOptionsProperty=S==null?void 0:S.customTextureOptions,!((V=_.paletteProvider)===null||V===void 0)&&V.onAttached&&((z=_.paletteProvider)===null||z===void 0||z.onAttached(_)),_.dataLabelProviderProperty||(_.dataLabelProviderProperty=new p.RectangleSeriesDataLabelProvider(S==null?void 0:S.dataLabels),_.dataLabelProviderProperty.onAttach(_.webAssemblyContext,_)),S!=null&&S.animation&&_.animationQueue.push(S.animation),_}return m.prototype.addDrawingProviders=function(b,S){this.drawingProviders.push(new f.RectangleSeriesDrawingProvider(b,this))},m.prototype.applyTheme=function(b){y.prototype.applyTheme.call(this,b);var S=this.parentSurface.previousThemeProvider;this.fill===S.columnFillBrush&&(this.fill=b.columnFillBrush),this.stroke===S.columnLineColor&&(this.stroke=b.columnLineColor)},Object.defineProperty(m.prototype,"defaultY1",{get:function(){return this.defaultY1Property},set:function(b){this.defaultY1Property=b,this.notifyPropertyChanged(d.PROPERTY.DEFAULT_Y1)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fill",{get:function(){return(0,l.stripAutoColor)(this.fillProperty)},set:function(b){this.fillProperty!==b&&(this.fillProperty=b,this.notifyPropertyChanged(d.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(b){b!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=b,this.notifyPropertyChanged(d.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"columnXMode",{get:function(){return this.columnXModeProperty},set:function(b){this.columnXModeProperty!==b&&(this.columnXModeProperty=b,this.notifyPropertyChanged("COLUMN_MODE"))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"columnYMode",{get:function(){return this.columnYModeProperty},set:function(b){this.columnYModeProperty!==b&&(this.columnYModeProperty=b,this.notifyPropertyChanged("COLUMN_MODE"))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(b){this.dataPointWidthProperty=b,this.notifyPropertyChanged(d.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(b){this.dataPointWidthModeProperty=b,this.notifyPropertyChanged(d.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"topCornerRadius",{get:function(){return this.topCornerRadiusProperty},set:function(b){this.topCornerRadiusProperty=b,this.notifyPropertyChanged(d.PROPERTY.TOP_CORNER_RADIUS)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"bottomCornerRadius",{get:function(){return this.bottomCornerRadiusProperty},set:function(b){this.bottomCornerRadiusProperty=b,this.notifyPropertyChanged(d.PROPERTY.BOTTOM_CORNER_RADIUS)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(b){b!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=b,this.notifyPropertyChanged(d.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),m.prototype.getXRange=function(){var b=this.dataSeries.count(),S=this.dataSeries;if([n.EColumnMode.MidWidth,n.EColumnMode.StartWidth].includes(this.columnXMode)){var _=S.getNativeXValues(),C=S.getYValuesByName(a.EValueName.X1);if(!C)throw new Error("columnXMode ".concat(this.columnXMode," requires x1 values.  Please use an Xyx or Xyxy dataseries"));var P=void 0,x=this.columnXMode===n.EColumnMode.MidWidth,E=_.get(0),A=_.get(S.count()-1),R=void 0;try{P=this.webAssemblyContext.NumberUtil.MinMaxPair(S.getNativeXValues(),C,x?.5:1,x?-.5:0,!1),E=P.minD,A=P.maxD}finally{(0,e.deleteSafe)(P)}return E===A?new i.NumberRange(E-1,A+1):(E>A&&(R=E,E=A,A=R),new i.NumberRange(E,A))}else if(this.columnXMode===n.EColumnMode.StartEnd){var M=S.getXRange(s.EDataSeriesValueType.Default),D=S.getXRangeByName(s.EDataSeriesValueType.Default,a.EValueName.X1);return new i.NumberRange(Math.min(M.min,D.min),Math.max(M.max,D.max))}else{var F=y.prototype.getXRange.call(this),I=this.dataPointWidth;if(this.dataPointWidthMode===r.EDataPointWidthMode.Relative&&(b>1?I=F.diff/(b-1)*this.dataPointWidth:I=0),this.dataPointWidthMode===r.EDataPointWidthMode.Absolute){var V=this.xAxis.getCurrentCoordinateCalculator();I=V.getDataWidth(this.dataPointWidth)/2}if(this.columnXMode===n.EColumnMode.Mid)return new i.NumberRange(F.min-I/2,F.max+I/2);if(this.columnXMode===n.EColumnMode.Start)return new i.NumberRange(F.min,F.max+I)}return new i.NumberRange(0,0)},m.prototype.getYRange=function(b,S){var _=this.dataSeries.getYValuesByName(a.EValueName.Y1);if([n.EColumnYMode.CenterHeight,n.EColumnYMode.TopHeight].includes(this.columnYMode)){var C=n.EColumnYMode.CenterHeight===this.columnYMode,P=S?b:this.getIndicesRange(b,!1),x=Math.max(Math.floor(P.min),0),E=Math.min(Math.ceil(P.max),this.dataSeries.count()-1);if(E<x)return;var A=void 0,R=this.dataSeries.getYValuesByName(a.EValueName.Y);if(_){var M=void 0,D=void 0,F=C?-.5:-1,I=C?.5:0;try{A=this.webAssemblyContext.NumberUtil.MinMaxPairWithIndex(R,_,F,I,x,E-x+1,this.dataSeries.dataDistributionCalculator.containsNaN),M=A.minD,D=A.maxD}finally{(0,e.deleteSafe)(A)}return new i.NumberRange(M,D)}else{var V=y.prototype.getYRange.call(this,b,S);return V?C?new i.NumberRange(V.min-this.defaultY1/2,V.max+this.defaultY1/2):new i.NumberRange(V.min-this.defaultY1,V.max):void 0}}else{var V=y.prototype.getYRange.call(this,b,S);return V?_?V:new i.NumberRange(Math.min(V.min,this.defaultY1),Math.max(V.max,this.defaultY1)):void 0}},m.prototype.getIndicesRange=function(b,S){return new i.NumberRange(0,this.dataSeries.count()-1)},m.prototype.resolveAutoColors=function(b,S,_){if(y.prototype.resolveAutoColors.call(this,b,S,_),this.fillProperty.startsWith(l.AUTO_COLOR)){var C=_.getFillColor(b,S,this.webAssemblyContext);this.fill=l.AUTO_COLOR+this.adjustAutoColor("fill",C)}},m.prototype.toJSON=function(b){b===void 0&&(b=!1);var S=y.prototype.toJSON.call(this,b),_={columnXMode:this.columnXMode,dataPointWidth:this.dataPointWidth,dataPointWidthMode:this.dataPointWidthMode,defaultY1:this.defaultY1,fill:this.fill,fillLinearGradient:this.fillLinearGradient,topCornerRadius:this.topCornerRadius,bottomCornerRadius:this.bottomCornerRadius,columnYMode:this.columnYMode};return Object.assign(S.options,_),S},m.prototype.newHitTestProvider=function(){return new h.RectangleSeriesHitTestProvider(this,this.webAssemblyContext)},m})(c.BaseRenderableSeries);return Yw.FastRectangleRenderableSeries=v,Yw}var Jw={},Qw={},eA={},nPe;function ZW(){if(nPe)return eA;nPe=1;var t=eA&&eA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(eA,"__esModule",{value:!0}),eA.PolarDataLabelState=void 0;var e=Ca(),i=gl(),n=Zi(),r=UI(),o=(function(a){t(s,a);function s(){return a!==null&&a.apply(this,arguments)||this}return s.prototype.toCartesian=function(l,u){var c=this.parentSeries.xAxis;return i.annotationHelpers.convertPolarToCartesian(c,!1,this.parentSeries.parentSurface.webAssemblyContext2D,e.ECoordinateMode.Pixel,l*n.DpiHelper.PIXEL_RATIO,u)},s.prototype.xCoord=function(l){return this.updateCache(l),this.cartesianCache.x},s.prototype.yCoord=function(l){return this.updateCache(l),this.cartesianCache.y},s.prototype.angleCoord=function(l){return a.prototype.xCoord.call(this,l)},s.prototype.radiusCoord=function(l){return a.prototype.yCoord.call(this,l)},s.prototype.updateCache=function(l){var u=l??this.index;if(!this.cartesianCache||this.cartesianCache.index!==u){var c=a.prototype.xCoord.call(this),d=a.prototype.yCoord.call(this),f=this.toCartesian(c,d),h=f.x,p=f.y;this.cartesianCache={index:u,x:h,y:p}}},s})(r.DataLabelState);return eA.PolarDataLabelState=o,eA}var oPe;function pR(){if(oPe)return Qw;oPe=1;var t=Qw&&Qw.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(Qw,"__esModule",{value:!0}),Qw.PolarDataLabelProvider=void 0;var e=Ac(),i=Wv(),n=ZW(),r=(function(o){t(a,o);function a(){var s=o!==null&&o.apply(this,arguments)||this;return s.type=e.EDataLabelProviderType.PolarDefault,s}return a.prototype.getDataLabelState=function(s,l,u,c,d,f){return new n.PolarDataLabelState(s,l,u,c,d,f)},a})(i.DataLabelProvider);return Qw.PolarDataLabelProvider=r,Qw}var tA={},aPe;function JW(){if(aPe)return tA;aPe=1;var t=tA&&tA.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(tA,"__esModule",{value:!0}),tA.PolarInterpolateLineRenderDataTransform=void 0;var e=Br(),i=di(),n=Iu(),r=lR(),o=Cv(),a=(function(s){t(l,s);function l(){var u=s!==null&&s.apply(this,arguments)||this;return u.pointsForWholeCircle=360,u}return l.prototype.runTransform=function(u){var c,d=(c=this.parentSeries.interpolateLine)!==null&&c!==void 0?c:!1,f=this.parentSeries.drawNaNAs===n.ELineDrawMode.PolyLine,h=this.parentSeries.xAxis.visibleRange.diff;return(d!==this.previnterpolateLine||this.prevDiff!==h||f!==this.prevCloseNanGaps)&&(this.requiresTransform=!0,this.previnterpolateLine=d,this.prevDiff=h,this.prevCloseNanGaps=f),s.prototype.runTransform.call(this,u)},l.prototype.createPointSeries=function(){var u=new r.XyPointSeriesResampled(this.wasmContext,new i.NumberRange(0,0));return this.inParams=new this.wasmContext.SCRTPolarInterpolationParams,this.outParams=new this.wasmContext.SCRTPolarInterpolationParams,this.outParams.SetIndexes(u.indexes),this.outParams.SetX(u.xValues),this.outParams.SetY(u.yValues),u},l.prototype.runTransformInternal=function(u){var c,d=(c=this.parentSeries.interpolateLine)!==null&&c!==void 0?c:!1;if(!d)return u.pointSeries;this.inParams.Reset();var f=u.isVerticalChart?u.pointSeries.xValues:u.pointSeries.yValues,h=u.isVerticalChart?u.pointSeries.yValues:u.pointSeries.xValues;this.inParams.SetIndexes(u.pointSeries.indexes),this.inParams.SetX(h),this.inParams.SetY(f);var p=u.isVerticalChart?this.parentSeries.xAxis:this.parentSeries.yAxis,g=u.isVerticalChart?this.parentSeries.yAxis:this.parentSeries.xAxis;return this.wasmContext.SCRTInterpolatePolarLine(this.inParams,this.outParams,p.getCurrentCoordinateCalculator().nativeCalculator,g.visibleRange.diff,this.pointsForWholeCircle,this.parentSeries.drawNaNAs===n.ELineDrawMode.PolyLine),this.pointSeries},l.prototype.delete=function(){this.inParams=(0,e.deleteSafe)(this.inParams),this.outParams=(0,e.deleteSafe)(this.outParams),s.prototype.delete.call(this)},l})(o.BaseRenderDataTransform);return tA.PolarInterpolateLineRenderDataTransform=a,tA}var rA={},sPe;function rH(){if(sPe)return rA;sPe=1;var t=rA&&rA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(rA,"__esModule",{value:!0}),rA.PolarLineSeriesDrawingProvider=void 0;var e=Hie(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.updateArgs=function(o){var a=this.parentSeries.xAxis;this.args.SetCoordinateTransform(a.getTransform())},r})(e.LineSeriesDrawingProvider);return rA.PolarLineSeriesDrawingProvider=i,rA}var iA={},lPe;function nC(){if(lPe)return iA;lPe=1;var t=iA&&iA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(iA,"__esModule",{value:!0}),iA.PolarPointMarkerDrawingProvider=void 0;var e=Yf(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.updateArgs=function(o){var a=this.parentSeries.xAxis;this.args.SetCoordinateTransform(a.getTransform())},r})(e.PointMarkerDrawingProvider);return iA.PolarPointMarkerDrawingProvider=i,iA}var nA={},_B={},uPe;function Kie(){if(uPe)return _B;uPe=1,Object.defineProperty(_B,"__esModule",{value:!0}),_B.polarHitTestHelpers=void 0;var t=Br();function e(n,r,o,a,s,l){var u=r.isCategoryCoordinateCalculator,c=u?a.getNativeIndexes():a.getNativeXValues(),d=a.getNativeYValues(),f;try{return f=n.SCRTHitTestHelper.GetNearestPolarXyPoint(r.nativeCalculator,o.nativeCalculator,c,d,s,l,!1,!1),{nearestPointIndex:f.minD,distance:f.maxD}}finally{(0,t.deleteSafe)(f)}}function i(n,r,o,a,s,l){var u=r.isCategoryCoordinateCalculator,c=u?a.getNativeIndexes():a.getNativeXValues(),d=a.getNativeYValues(),f;try{f=n.SCRTHitTestHelper.GetNearestPolarXyPoint(r.nativeCalculator,o.nativeCalculator,c,d,s,l,!0,!0);var h=f.minD,p=f.maxD;if(h===-1||a.count()===0)return{nearestPointIndex:-1,distance:void 0,secondNearestPointIndex:-1};if(a.count()===1)return{nearestPointIndex:h,distance:p,secondNearestPointIndex:-1};var g=c.get(1)-c.get(0)>0,v=r.getDataValue(s),y=v>=c.get(h)&&g||v<=c.get(h)&&!g?h+1:h-1;return y<0||y>=a.count()?{nearestPointIndex:h,distance:p,secondNearestPointIndex:-1}:!(c.get(h)<=v&&v<=c.get(y))&&!(c.get(h)>=v&&v>=c.get(y))?{nearestPointIndex:h,distance:p,secondNearestPointIndex:-1}:{nearestPointIndex:h,distance:p,secondNearestPointIndex:y}}finally{(0,t.deleteSafe)(f)}}return _B.polarHitTestHelpers={getNearestPolarPoint:e,getNearestPolarPointXDirSorted:i},_B}var cPe;function gR(){if(cPe)return nA;cPe=1;var t=nA&&nA.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(nA,"__esModule",{value:!0}),nA.PolarDataPointHitTestProvider=void 0;var e=Vl(),i=tl(),n=vl(),r=Kie(),o=10,a=(function(s){t(l,s);function l(){return s!==null&&s.apply(this,arguments)||this}return l.prototype.hitTest=function(u,c,d){return d===void 0&&(d=o),this.hitTestDataPointInternal(u,c,d)},l.prototype.hitTestDataPoint=function(u,c,d){var f=d>0?d:o;return this.hitTestDataPointInternal(u,c,f)},l.prototype.hitTestXSlice=function(u,c){return this.hitTest(u,c,o)},l.prototype.hitTestDataPointInternal=function(u,c,d){var f=this.getTranslatedHitTestPoint(u,c);if(!f)return i.HitTestInfo.empty();var h=this.parentSeries.xAxis.reverseTransform(f.x,f.y),p=this.currentRenderPassData,g=p.xCoordinateCalculator,v=p.yCoordinateCalculator,y=p.isVerticalChart,m=y?h.y:h.x,b=y?h.x:h.y,S=this.parentSeries.dataSeries;if(!S)return i.HitTestInfo.empty();var _=r.polarHitTestHelpers.getNearestPolarPoint(this.webAssemblyContext,g,v,S,m,b),C=S.getNativeXValues(),P=S.getNativeYValues(),x=n.hitTestHelpers.createHitTestInfo(this.parentSeries,g,v,y,S,C,P,m,b,_.nearestPointIndex,d);return x.isHit=_.distance<d,x},l})(e.BaseHitTestProvider);return nA.PolarDataPointHitTestProvider=a,nA}var dPe;function x3e(){if(dPe)return Jw;dPe=1;var t=Jw&&Jw.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(Jw,"__esModule",{value:!0}),Jw.PolarLineRenderableSeries=void 0;var e=di(),i=hn(),n=mm(),r=pR(),o=JW(),a=rH(),s=nC(),l=gR(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y,m;return p=c.call(this,f,h)||this,p.isPolar=!0,p.type=i.ESeriesType.PolarLineSeries,p.clipToTotalAngleProperty=!1,p.interpolateLineProperty=!1,p.dataLabelProviderProperty||(p.dataLabelProviderProperty=new r.PolarDataLabelProvider(h==null?void 0:h.dataLabels),p.dataLabelProviderProperty.onAttach(p.webAssemblyContext,p)),!((g=p.paletteProvider)===null||g===void 0)&&g.onAttached&&((v=p.paletteProvider)===null||v===void 0||v.onAttached(p)),p.renderDataTransformProperty=new o.PolarInterpolateLineRenderDataTransform(p,p.webAssemblyContext,[]),p.clipToTotalAngleProperty=(y=h==null?void 0:h.clipToTotalAngle)!==null&&y!==void 0?y:p.clipToTotalAngleProperty,p.interpolateLine=(m=h==null?void 0:h.interpolateLine)!==null&&m!==void 0?m:p.interpolateLineProperty,p}return Object.defineProperty(d.prototype,"interpolateLine",{get:function(){return this.interpolateLineProperty},set:function(f){this.interpolateLineProperty!==f&&(this.interpolateLineProperty=f,this.interpolateLineProperty?this.renderDataTransform.drawingProviders=[this.drawingProviders[0]]:this.renderDataTransform.drawingProviders=[],this.notifyPropertyChanged("interpolateLine"))},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"clipToTotalAngle",{get:function(){return this.clipToTotalAngleProperty},set:function(f){this.clipToTotalAngleProperty!==f&&(this.clipToTotalAngleProperty=f,this.notifyPropertyChanged("clipToTotalAngle"))},enumerable:!1,configurable:!0}),d.prototype.getIndicesRange=function(f,h){return this.clipToTotalAngle?c.prototype.getIndicesRange.call(this,f,h):new e.NumberRange(0,this.dataSeries.count()-1)},d.prototype.toJSON=function(f){f===void 0&&(f=!1);var h=c.prototype.toJSON.call(this,f),p={clipToTotalAngle:this.clipToTotalAngle,interpolateLine:this.interpolateLine};return Object.assign(h.options,p),h},d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new a.PolarLineSeriesDrawingProvider(f,this)),this.drawingProviders.push(new s.PolarPointMarkerDrawingProvider(f,this))},d.prototype.newHitTestProvider=function(){return new l.PolarDataPointHitTestProvider(this,this.webAssemblyContext)},d})(n.BaseLineRenderableSeries);return Jw.PolarLineRenderableSeries=u,Jw}var oA={},aA={},fPe;function E3e(){if(fPe)return aA;fPe=1;var t=aA&&aA.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(aA,"__esModule",{value:!0}),aA.PolarInterpolateBandRenderDataTransform=void 0;var e=Br(),i=di(),n=Iu(),r=hR(),o=Cv(),a=(function(s){t(l,s);function l(){var u=s!==null&&s.apply(this,arguments)||this;return u.pointsForWholeCircle=360,u}return l.prototype.runTransform=function(u){var c,d=(c=this.parentSeries.interpolateLine)!==null&&c!==void 0?c:!1,f=this.parentSeries.drawNaNAs===n.ELineDrawMode.PolyLine,h=this.parentSeries.xAxis.visibleRange.diff;return(d!==this.prevInterpolateLine||this.prevDiff!==h||f!==this.prevCloseNanGaps)&&(this.requiresTransform=!0,this.prevInterpolateLine=d,this.prevDiff=h,this.prevCloseNanGaps=f),s.prototype.runTransform.call(this,u)},l.prototype.createPointSeries=function(){var u=new r.XyyPointSeriesResampled(this.wasmContext,new i.NumberRange(0,0));return this.inParams=new this.wasmContext.SCRTPolarInterpolationParams,this.outParams=new this.wasmContext.SCRTPolarInterpolationParams,this.outParams.SetIndexes(u.indexes),this.outParams.SetX(u.xValues),this.outParams.SetY(u.yValues),this.outParams.SetY1(u.y1Values),u},l.prototype.runTransformInternal=function(u){var c,d=(c=this.parentSeries.interpolateLine)!==null&&c!==void 0?c:!1;return d?(this.inParams.Reset(),this.inParams.SetIndexes(u.pointSeries.indexes),this.inParams.SetX(u.pointSeries.xValues),this.inParams.SetY(u.pointSeries.yValues),this.inParams.SetY1(u.pointSeries.y1Values),this.wasmContext.SCRTInterpolatePolarBand(this.inParams,this.outParams,this.parentSeries.yAxis.getCurrentCoordinateCalculator().nativeCalculator,this.parentSeries.xAxis.visibleRange.diff,this.pointsForWholeCircle,this.parentSeries.drawNaNAs===n.ELineDrawMode.PolyLine),this.pointSeries):u.pointSeries},l.prototype.delete=function(){this.inParams=(0,e.deleteSafe)(this.inParams),this.outParams=(0,e.deleteSafe)(this.outParams),s.prototype.delete.call(this)},l})(o.BaseRenderDataTransform);return aA.PolarInterpolateBandRenderDataTransform=a,aA}var sA={},hPe;function QW(){if(hPe)return sA;hPe=1;var t=sA&&sA.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(sA,"__esModule",{value:!0}),sA.PolarBandSeriesDrawingProvider=void 0;var e=Br(),i=Ju(),n=Du(),r=Ti(),o=bo(),a=Yo(),s=tu(),l=Sn(),u=un(),c=du(),d=Uo(),f=(function(h){t(p,h);function p(g,v,y,m){var b=h.call(this,g,v,y)||this;return b.args=new b.webAssemblyContext.SCRTPolarBandDrawingParams,b.y1Selector=m??(function(S){return S.y1Values}),b.fillBrushCache=new s.BrushCache(g),b.fillBrushY1Cache=new s.BrushCache(g),b}return p.prototype.onAttachSeries=function(){h.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTPolarBandSeriesDrawingProvider,this.onSeriesPropertyChange(u.PROPERTY.FILL),(this.parentSeries.fillY1||this.parentSeries.fillLinearGradientY1)&&this.onSeriesPropertyChange(u.PROPERTY.FILL_Y1)},p.prototype.onDetachSeries=function(){h.prototype.onDetachSeries.call(this),this.delete()},p.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),this.fillBrushY1Cache=(0,e.deleteSafe)(this.fillBrushY1Cache),h.prototype.delete.call(this)},p.prototype.draw=function(g,v){var y,m,b=v.pointSeries;this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN,this.args.Reset();var S=(0,s.getScrtBrushFromCache)(this.fillBrushCache);S&&this.args.SetFillBrush(S);var _=(0,s.getScrtBrushFromCache)(this.fillBrushY1Cache);_&&this.args.SetFillBrush1(_);var C=v.xCoordinateCalculator.isCategoryCoordinateCalculator,P=b.xValues,x=this.parentSeries.dataSeries,E=x.fifoCapacity,A=x.fifoSweeping,R=x.fifoSweepingGap,M=b.fifoStartIndex,D=C?b.indexes:P,F=this.ySelector(b),I=this.y1Selector(b),V=this.getStartAndCount(v,D),z=V.startIndex,G=V.count;this.args.count=G,this.args.startIndex=z,E>0&&A&&E===this.parentSeries.dataSeries.count()&&(this.args.count=M);var H=this.parentSeries.xAxis;this.args.SetCoordinateTransform(H.getTransform()),this.args.SetXValues(D),this.args.SetYValues(F),I?this.args.SetZValues(I):this.args.zeroLineY=(y=this.parentSeries.zeroLineY)!==null&&y!==void 0?y:0,this.applyFillFillPaletting(this.parentSeries.fill,S,this.parentSeries.fillY1,_,this.parentSeries.opacity,z,G,b,D,F),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.scaleGradientToYRange=(m=this.parentSeries.scaleGradientToYRange)!==null&&m!==void 0?m:!1,this.args.isSmoothColors=this.palettingState.gradientPaletting;var U=g.getNativeContext();this.args.SetNativeContext(U),this.args.SetXCoordinateCalculator(v.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(v.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPoints(this.args),E>0&&A&&E===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(F.size(),M+R),this.args.count=Math.max(0,F.size()-M-R),this.args.count>0&&this.nativeDrawingProvider.DrawPoints(this.args))},p.prototype.applyFillFillPaletting=function(g,v,y,m,b,S,_,C,P,x){var E,A=this.parentSeries.hasFillPaletteProvider(),R=this.parentSeries.paletteProvider;if(A){var M=void 0,D=void 0,F=b!==void 0;if(M=g&&F?(0,i.uintArgbColorMultiplyOpacity)((0,r.parseColorToUIntArgb)(g),1):d.NEUTRAL_COLOR,D=y&&F?(0,i.uintArgbColorMultiplyOpacity)((0,r.parseColorToUIntArgb)(y),1):d.NEUTRAL_COLOR,isNaN(M))throw Error("updatePalette(): fillColor "+M+" cannot be converted to a valid color");if(isNaN(D))throw Error("updatePalette(): fillColor for y1 "+D+" cannot be converted to a valid color");this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector),this.palettingState.paletteTextureCache.reset(),this.palettingState.palettedColors.resize(_*2,0),v&&(this.palettingState.originalBrushColor=v.GetColor(),v.SetColor(d.NEUTRAL_COLOR)),m&&(this.palettingState.originalBrushColory1=m.GetColor(),m.SetColor(d.NEUTRAL_COLOR));for(var I=0,V=this.parentSeries.dataSeries,z=V.count(),G=C&&C.indexes.size()>0,H=(0,o.vectorToArrayViewF64)(C==null?void 0:C.indexes,this.webAssemblyContext),U=(0,o.vectorToArrayViewF64)(P,this.webAssemblyContext),k=(0,o.vectorToArrayViewF64)(x,this.webAssemblyContext),X=(0,o.vectorToArrayViewUi32)(this.palettingState.palettedColors,this.webAssemblyContext),W=new Map,Y=0,te=V.valueNames;Y<te.length;Y++){var oe=te[Y];oe!==a.EValueName.Y&&W.set(oe,(0,o.vectorToArrayViewF64)(V.getYValuesByName(oe),this.webAssemblyContext))}for(var de=0,ge=S;ge<S+_;ge++){var Ee=G?H[ge]:ge;Ee<0?Ee=0:Ee>=z&&(Ee=z-1);var Re=U[ge],Ae=k[ge],Pe=V.getMetadataAt(Ee),we=R.overrideFillArgb(Re,Ae,Ee,b,Pe,W);X[de]=we??M,de++,X[de]=we??D,de++,I=(0,n.numericHashCode)(I,we)}}else this.palettingState.paletteTextureCache.reset(),(E=this.palettingState.palettedColors)===null||E===void 0||E.clear(),v&&this.palettingState.originalBrushColor&&(v.SetColor(this.palettingState.originalBrushColor),this.palettingState.originalBrushColor=void 0),m&&this.palettingState.originalBrushColory1&&(m.SetColor(this.palettingState.originalBrushColory1),this.palettingState.originalBrushColory1=void 0);this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector),this.palettingState.gradientPaletting=this.isGradientFillPaletting(this.parentSeries)},p.prototype.onSeriesPropertyChange=function(g){h.prototype.onSeriesPropertyChange.call(this,g);var v=this.parentSeries,y=v.fill,m=v.fillY1,b=v.opacity,S=v.fillLinearGradient,_=v.fillLinearGradientY1,C=v.parentSurface,P=C!=null&&C.isCopyCanvasSurface?C.domCanvas2D.height/l.SciChartSurfaceBase.domMasterCanvas.height:1,x=C!=null&&C.isCopyCanvasSurface?C.domCanvas2D.width/l.SciChartSurfaceBase.domMasterCanvas.width:1;(g===u.PROPERTY.FILL||g===u.PROPERTY.OPACITY||g===u.PROPERTY.FILL_LINEAR_GRADIENT)&&(0,s.createBrushInCache)(this.fillBrushCache,y,b,P,x,S),(g===u.PROPERTY.FILL_Y1||g===u.PROPERTY.OPACITY||g===u.PROPERTY.FILL_LINEAR_GRADIENT)&&(0,s.createBrushInCache)(this.fillBrushY1Cache,m,b,P,x,_)},p})(c.BaseSeriesDrawingProvider);return sA.PolarBandSeriesDrawingProvider=f,sA}var pPe;function w3e(){if(pPe)return oA;pPe=1;var t=oA&&oA.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(oA,"__esModule",{value:!0}),oA.PolarBandRenderableSeries=void 0;var e=qS(),i=hn(),n=UW(),r=mm(),o=E3e(),a=QW(),s=rH(),l=nC(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y,m;return p=c.call(this,f,h)||this,p.isPolar=!0,p.type=i.ESeriesType.PolarBandSeries,p.lineType=r.ELineType.Normal,p.clipToTotalAngle=!1,p.interpolateLineProperty=!1,p.renderDataTransformProperty=new o.PolarInterpolateBandRenderDataTransform(p,p.webAssemblyContext,[]),p.interpolateLine=(g=h==null?void 0:h.interpolateLine)!==null&&g!==void 0?g:p.interpolateLineProperty,p.scaleGradientToYRangeProperty=(v=h==null?void 0:h.scaleGradientToYRange)!==null&&v!==void 0?v:p.scaleGradientToYRangeProperty,!((y=p.paletteProvider)===null||y===void 0)&&y.onAttached&&((m=p.paletteProvider)===null||m===void 0||m.onAttached(p)),p}return Object.defineProperty(d.prototype,"isDigitalLine",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"scaleGradientToYRange",{get:function(){return this.scaleGradientToYRangeProperty},set:function(f){this.scaleGradientToYRangeProperty!==f&&(this.scaleGradientToYRangeProperty=f,this.notifyPropertyChanged("SCALE_GRADIENT_TO_Y_RANGE"))},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"interpolateLine",{get:function(){return this.interpolateLineProperty},set:function(f){this.interpolateLineProperty!==f&&(this.interpolateLineProperty=f,this.interpolateLineProperty?this.renderDataTransform.drawingProviders=this.drawingProviders:this.renderDataTransform.drawingProviders=[],this.notifyPropertyChanged("interpolateLine"))},enumerable:!1,configurable:!0}),d.prototype.getIndicesRange=function(f,h){return this.clipToTotalAngle?c.prototype.getIndicesRange.call(this,f,h):new e.NumberRange(0,this.dataSeries.count()-1)},d.prototype.toJSON=function(f){f===void 0&&(f=!1);var h=c.prototype.toJSON.call(this,f),p={scaleGradientToYRange:this.scaleGradientToYRange,interpolateLine:this.interpolateLine};return Object.assign(h.options,p),h},d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new a.PolarBandSeriesDrawingProvider(f,this)),this.drawingProviders.push(new s.PolarLineSeriesDrawingProvider(f,this));var p=new s.PolarLineSeriesDrawingProvider(f,this,function(g){return g.y1Values});p.getProperties=function(g){var v=g,y=v.strokeY1,m=v.strokeThickness,b=v.opacity,S=v.strokeY1DashArray,_=v.isDigitalLine,C=v.drawNaNAs,P=v.lineType;return{stroke:y,strokeThickness:m,opacity:b,strokeDashArray:S,isDigitalLine:_,drawNaNAs:C,lineType:P,containsNaN:void 0}},this.drawingProviders.push(p),this.drawingProviders.push(new l.PolarPointMarkerDrawingProvider(f,this)),this.drawingProviders.push(new l.PolarPointMarkerDrawingProvider(f,this,function(g){return g.y1Values},void 0))},d})(n.BaseBandRenderableSeries);return oA.PolarBandRenderableSeries=u,oA}var Mb={},lA={},gPe;function Zie(){if(gPe)return lA;gPe=1;var t=lA&&lA.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(lA,"__esModule",{value:!0}),lA.PolarColumnSeriesDrawingProvider=void 0;var e=Br(),i=tu(),n=Ls(),r=un(),o=du(),a=Vd(),s=Yo(),l=(function(u){t(c,u);function c(d,f){var h=u.call(this,d,f)||this;return h.nativeDrawingProvider=new d.SCRTPolarColumnSeriesDrawingProvider,h.args=new h.webAssemblyContext.SCRTPolarColumnDrawingParams,h.strokePenCache=new n.Pen2DCache(d),h.strokePenFillColoredCache=new n.Pen2DCache(d),h.fillBrushCache=new i.BrushCache(d),h}return c.prototype.onAttachSeries=function(){u.prototype.onAttachSeries.call(this);var d=this.parentSeries,f=d.stroke,h=d.strokeThickness,p=d.fill,g=d.opacity;(0,n.createPenInCache)(this.strokePenCache,f,h,g),h===0&&(0,n.createPenInCache)(this.strokePenFillColoredCache,p,1,g),this.createBrush()},c.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.strokePenCache=(0,e.deleteSafe)(this.strokePenCache),this.strokePenFillColoredCache=(0,e.deleteSafe)(this.strokePenFillColoredCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),u.prototype.delete.call(this)},c.prototype.draw=function(d,f){var h=f.pointSeries,p=this.parentSeries.strokeThickness;this.args.Reset(),this.args.verticalChart=f.isVerticalChart,this.args.xMode=(0,a.convertColumnMode)(this.parentSeries.columnXMode,this.webAssemblyContext),this.args.defaultY2=this.parentSeries.defaultY1,this.args.columnWidth=this.parentSeries.getDataPointWidth(f.xCoordinateCalculator,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode);var g=this.strokePenCache;this.args.columnWidth===1&&p===0&&(this.args.columnWidth=0,g=this.strokePenFillColoredCache);var v=(0,n.getScrtPenFromCache)(g);v&&this.args.SetLinesPen(v);var y=(0,i.getScrtBrushFromCache)(this.fillBrushCache);y&&this.args.SetFillBrush(y);var m=this.parentSeries.xAxis;this.args.SetCoordinateTransform(m.getTransform()),u.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,v,this.parentSeries.fill,y,this.parentSeries.opacity,!1,this.parentSeries.fillLinearGradient!==void 0),this.args.SetPalettedColors(this.palettingState.palettedColors);var b=f.xCoordinateCalculator.isCategoryCoordinateCalculator,S=this.xSelector(h),_=this.ySelector(h),C=b?h.indexes:S,P=this.getStartAndCount(f,C),x=P.startIndex,E=P.count;this.args.count=E,this.args.startIndex=x;var A=this.parentSeries.dataSeries,R=A.fifoCapacity,M=A.fifoSweeping,D=A.fifoSweepingGap,F=h.fifoStartIndex;if(M&&R===this.parentSeries.dataSeries.count()&&(this.args.count=F),this.args.SetXValues(C),_&&this.args.SetYValues(_),this.parentSeries.columnXMode===a.EColumnMode.MidWidth||this.parentSeries.columnXMode===a.EColumnMode.StartEnd||this.parentSeries.columnXMode===a.EColumnMode.StartWidth){var I=h.getYValuesByName(s.EValueName.X1);if(I)this.args.SetZValues(I);else throw new Error("polarColumnMode ".concat(this.parentSeries.columnXMode," requires an DataSeries with a yValue called ").concat(s.EValueName.X1))}var V=h.getYValuesByName(s.EValueName.Y1);V&&this.args.SetWValues(V),this.args.segmentCount=180;var z=d.getNativeContext();this.args.SetNativeContext(z),this.args.SetXCoordinateCalculator(f.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(f.yCoordinateCalculator.nativeCalculator),this.nativeDrawingProvider.DrawPoints(this.args),M&&R===this.parentSeries.dataSeries.count()&&(this.args.startIndex=Math.min(_.size(),F+D),this.args.count=Math.max(0,_.size()-F-D),this.args.count>0&&this.nativeDrawingProvider.DrawPoints(this.args))},c.prototype.onDpiChanged=function(d){u.prototype.onDpiChanged.call(this,d),this.onSeriesPropertyChange(r.PROPERTY.STROKE)},c.prototype.onSeriesPropertyChange=function(d){u.prototype.onSeriesPropertyChange.call(this,d);var f=this.parentSeries,h=f.stroke,p=f.strokeThickness,g=f.opacity,v=f.fill;(d===r.PROPERTY.STROKE||d===r.PROPERTY.STROKE_THICKNESS||d===r.PROPERTY.OPACITY)&&(0,n.createPenInCache)(this.strokePenCache,h,p,g),(d===r.PROPERTY.FILL||d===r.PROPERTY.OPACITY||d===r.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&this.createBrush(),p===0&&(d===r.PROPERTY.STROKE_THICKNESS||d===r.PROPERTY.STROKE||d===r.PROPERTY.OPACITY||d===r.PROPERTY.FILL)&&(0,n.createPenInCache)(this.strokePenFillColoredCache,v,1,g)},c.prototype.createBrush=function(){var d=this.parentSeries,f=d.fill,h=d.opacity,p=d.fillLinearGradient;d.parentSurface;var g=d.customTextureOptions,v=this.fillBrushCache.create(f,h,1,1,p,g);return v.scrtBrush},c})(o.BaseSeriesDrawingProvider);return lA.PolarColumnSeriesDrawingProvider=l,lA}var Lb={},uA={},vPe;function A3e(){if(vPe)return uA;vPe=1;var t=uA&&uA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(uA,"__esModule",{value:!0}),uA.PolarColumnDataLabelState=void 0;var e=Yo(),i=bo(),n=ZW(),r=(function(o){t(a,o);function a(s,l,u,c,d,f){var h=o.call(this,s,l,u,c,d,f)||this;h.x1CoordCache=void 0,h.zeroXCoordCache=void 0,h.zeroYCoordCache=void 0,h.accumulatedWidthCoordCache=void 0,h.accumulatedWidthValues=[];var p=l.pointSeries;return h.x1Values=p.getYValuesByName(e.EValueName.X1)?(0,i.vectorToArrayViewF64)(p.getYValuesByName(e.EValueName.X1),s.webAssemblyContext):h.xValues,h.columnWidthProperty=f.getDataPointWidth(l.xCoordinateCalculator,f.dataPointWidth,f.dataPointWidthMode),h.isFlippedProperty=l.xCoordinateCalculator.isFlipped,h}return a.prototype.fillAccumulatedWidthValues=function(){this.accumulatedWidthValues=[];var s=0;this.accumulatedWidthValues.push(s);for(var l=0;l<this.xValues.length-1;l++)s+=this.xValues[l],this.accumulatedWidthValues.push(s)},Object.defineProperty(a.prototype,"columnWidth",{get:function(){return this.columnWidthProperty},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"isFlipped",{get:function(){return this.isFlippedProperty},enumerable:!1,configurable:!0}),a.prototype.x1Val=function(s){return this.x1Values[this.getIndexInternal(s)]},a.prototype.accumulatedWidth=function(s){return this.accumulatedWidthValues?this.accumulatedWidthValues[this.getIndexInternal(s)]:this.xVal(s)},a.prototype.accumulatedWidthCoord=function(s){return s!==void 0?this.renderPassData.xCoordinateCalculator.getCoordinate(this.accumulatedWidth(s)):this.accumulatedWidthCoordCache!==void 0?this.accumulatedWidthCoordCache:(this.accumulatedWidthCoordCache=this.renderPassData.xCoordinateCalculator.getCoordinate(this.accumulatedWidth()),this.accumulatedWidthCoordCache)},Object.defineProperty(a.prototype,"index",{get:function(){return this.indexProperty},set:function(s){this.xCoordCache=void 0,this.yCoordCache=void 0,this.x1CoordCache=void 0,this.accumulatedWidthCoordCache=void 0,this.indexProperty=s},enumerable:!1,configurable:!0}),a.prototype.x1Coord=function(s){return s!==void 0?this.renderPassData.xCoordinateCalculator.getCoordinate(this.x1Val(s)):this.x1CoordCache!==void 0?this.x1CoordCache:(this.x1CoordCache=this.renderPassData.xCoordinateCalculator.getCoordinate(this.x1Val()),this.x1CoordCache)},Object.defineProperty(a.prototype,"zeroXCoord",{get:function(){return this.zeroXCoordCache||(this.zeroXCoordCache=this.renderPassData.xCoordinateCalculator.getCoordinate(0)),this.zeroXCoordCache},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"zeroYCoord",{get:function(){return this.zeroYCoordCache||(this.zeroYCoordCache=this.renderPassData.yCoordinateCalculator.getCoordinate(0)),this.zeroYCoordCache},enumerable:!1,configurable:!0}),a})(n.PolarDataLabelState);return uA.PolarColumnDataLabelState=r,uA}var yPe;function Jie(){if(yPe)return Lb;yPe=1;var t=Lb&&Lb.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})(),e=Lb&&Lb.__assign||function(){return e=Object.assign||function(h){for(var p,g=1,v=arguments.length;g<v;g++){p=arguments[g];for(var y in p)Object.prototype.hasOwnProperty.call(p,y)&&(h[y]=p[y])}return h},e.apply(this,arguments)};Object.defineProperty(Lb,"__esModule",{value:!0}),Lb.PolarColumnSeriesDataLabelProvider=void 0;var i=$i(),n=Vd(),r=Ac(),o=Lie(),a=Tc(),s=NI(),l=nR(),u=iI(),c=A3e(),d=pR(),f=(function(h){t(p,h);function p(g){var v=this,y,m;return v=h.call(this,e({horizontalTextPosition:a.EHorizontalTextPosition.Center,verticalTextPosition:a.EVerticalTextPosition.Center,skipMode:o.EDataLabelSkipMode.ShowAll},g))||this,v.type=r.EDataLabelProviderType.PolarColumn,v.polarLabelModeProperty=s.EPolarLabelMode.Horizontal,v.yPositionMultiplierProperty=.5,v.labelYPositionModeProperty=u.EColumnDataLabelPosition.Outside,v.polarLabelModeProperty=(y=g==null?void 0:g.polarLabelMode)!==null&&y!==void 0?y:v.polarLabelModeProperty,v.yPositionMultiplierProperty=g==null?void 0:g.labelYPositionMultiplier,v.labelYPositionModeProperty=(m=g==null?void 0:g.labelYPositionMode)!==null&&m!==void 0?m:v.labelYPositionModeProperty,v}return p.prototype.shouldSkipLabel=function(g,v){return!1},Object.defineProperty(p.prototype,"polarLabelMode",{get:function(){return this.polarLabelModeProperty},set:function(g){this.polarLabelModeProperty=g,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"yPositionMultiplier",{get:function(){return this.yPositionMultiplierProperty},set:function(g){this.yPositionMultiplierProperty=g,this.invalidateParent()},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"labelYPositionMode",{get:function(){return this.labelYPositionModeProperty},set:function(g){this.labelYPositionModeProperty=g,this.invalidateParent()},enumerable:!1,configurable:!0}),p.prototype.getDataLabelState=function(g,v,y,m,b,S){return new c.PolarColumnDataLabelState(g,v,y,m,b,S)},p.prototype.getPosition=function(g,v){var y,m=this.parentSeries,b=m.columnXMode,S=m.defaultY1,_=g.getYCoord(S);if(g.isVerticalChart){var X=this.parentSeries.yAxis,C=X.startAngle,W=X.flippedCoordinates,x=g.angleCoord(),M=x+C,Y=g.getYCoord(S),F=void 0;if(b===n.EColumnMode.Start){var E=g.isFlipped?-1:1;F=g.radiusCoord()+E*g.columnWidth/2}else if(b===n.EColumnMode.StartEnd){var te=g.x1Coord();F=(g.radiusCoord()+te)/2}else if(b===n.EColumnMode.StartWidth){var oe=g.x1Coord()-g.zeroXCoord;F=g.radiusCoord()+oe/2}else if(b===n.EColumnMode.Mid||b===n.EColumnMode.MidWidth)F=g.radiusCoord();else throw new Error("PolarColumnSeriesDataLabelProvider EColumnMode ".concat(b," is not supported for vertical chart"));var de=0;if(this.polarLabelMode===s.EPolarLabelMode.Parallel)de=Math.atan2(v.m_fWidth,F);else if(this.polarLabelMode===s.EPolarLabelMode.Perpendicular)de=Math.atan2(v.m_fHeight,F);else if(this.polarLabelMode===s.EPolarLabelMode.Horizontal){var ge=Math.abs(Math.sin(M))*v.m_fWidth+Math.abs(Math.cos(M))*v.m_fHeight;de=Math.atan2(ge,F)}else throw new Error("PolarColumnSeriesDataLabelProvider EPolarLabelMode ".concat(this.polarLabelMode," is not supported for vertical chart"));this.labelYPositionMode===u.EColumnDataLabelPosition.Outside?x=W?x-de:x+de:this.labelYPositionMode===u.EColumnDataLabelPosition.Inside?x=W?x+de:x-de:this.labelYPositionMode===u.EColumnDataLabelPosition.Position&&(x=Y+(x-Y)*this.yPositionMultiplier);var Ee=g.toCartesian(x,F),V=Ee.x,z=Ee.y,G=new i.Point(V,z),H=l.labelHelper.getPolarLabelRotation(this.polarLabelMode,x+C);V-=v.m_fWidth/2;var U=v.GetLineBounds(0),k=v.m_fHeight-v.GetLineBounds(0).m_fHeight;return U.delete(),z-=k,z+=v.m_fHeight/2,{position:new i.Point(V,z),rotationCenter:G,rotationAngle:H}}else{var C=this.parentSeries.xAxis.startAngle,P=(y=this.yPositionMultiplier)!==null&&y!==void 0?y:.5,x=void 0;if(b===n.EColumnMode.Start){var E=g.isFlipped?-1:1;x=g.angleCoord()+E*g.columnWidth/2}else if(b===n.EColumnMode.StartEnd){var A=g.x1Coord();x=(g.angleCoord()+A)/2}else if(b===n.EColumnMode.StartWidth){var R=g.x1Coord()-g.zeroXCoord;x=g.angleCoord()+R/2}else x=g.angleCoord();var M=x+C,D=0;if(this.polarLabelMode===s.EPolarLabelMode.Parallel)D=v.m_fHeight;else if(this.polarLabelMode===s.EPolarLabelMode.Perpendicular)D=v.m_fWidth;else if(this.polarLabelMode===s.EPolarLabelMode.Horizontal)D=Math.abs(Math.sin(M))*v.m_fHeight+Math.abs(Math.cos(M))*v.m_fWidth;else throw new Error("PolarColumnSeriesDataLabelProvider EPolarLabelMode ".concat(this.polarLabelMode," is not supported for vertical chart"));var F=void 0;this.labelYPositionMode===u.EColumnDataLabelPosition.Outside?F=g.radiusCoord()+D:this.labelYPositionMode===u.EColumnDataLabelPosition.Inside?F=g.radiusCoord()-D:this.labelYPositionMode===u.EColumnDataLabelPosition.Position&&(F=_+(g.radiusCoord()-_)*P);var I=g.toCartesian(x,F),V=I.x,z=I.y,G=new i.Point(V,z),H=l.labelHelper.getPolarLabelRotation(this.polarLabelMode,M);V-=v.m_fWidth/2;var U=v.GetLineBounds(0),k=v.m_fHeight-U.m_fHeight;return U.delete(),z-=k,z+=v.m_fHeight/2,{position:new i.Point(V,z),rotationCenter:G,rotationAngle:H}}},p.prototype.toJSON=function(){var g=h.prototype.toJSON.call(this),v={polarLabelMode:this.polarLabelMode,labelYPositionMultiplier:this.yPositionMultiplier,labelYPositionMode:this.labelYPositionMode};return Object.assign(g.options,v),g},Object.defineProperty(p.prototype,"useRotation",{get:function(){return this.polarLabelMode!==s.EPolarLabelMode.Horizontal},enumerable:!1,configurable:!0}),p})(d.PolarDataLabelProvider);return Lb.PolarColumnSeriesDataLabelProvider=f,Lb}var mPe;function O3e(){if(mPe)return Mb;mPe=1;var t=Mb&&Mb.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})(),e=Mb&&Mb.__assign||function(){return e=Object.assign||function(h){for(var p,g=1,v=arguments.length;g<v;g++){p=arguments[g];for(var y in p)Object.prototype.hasOwnProperty.call(p,y)&&(h[y]=p[y])}return h},e.apply(this,arguments)};Object.defineProperty(Mb,"__esModule",{value:!0}),Mb.PolarColumnRenderableSeries=void 0;var i=hn(),n=ju(),r=Yf(),o=Zie(),a=Vd(),s=Em(),l=Jie(),u=Xie(),c=KW(),d=un(),f=(function(h){t(p,h);function p(g,v){var y=this,m,b,S;return y=h.call(this,g,e(e({},v),{dataLabelProvider:(m=v==null?void 0:v.dataLabelProvider)!==null&&m!==void 0?m:new l.PolarColumnSeriesDataLabelProvider(v==null?void 0:v.dataLabels)}))||this,y.type=i.ESeriesType.PolarColumnSeries,y.isPolar=!0,!((b=y.paletteProvider)===null||b===void 0)&&b.onAttached&&((S=y.paletteProvider)===null||S===void 0||S.onAttached(y)),y}return Object.defineProperty(p.prototype,"defaultY1",{get:function(){return this.defaultY1Property},set:function(g){this.defaultY1Property=g,this.notifyPropertyChanged(d.PROPERTY.DEFAULT_Y1)},enumerable:!1,configurable:!0}),p.prototype.addDrawingProviders=function(g,v){this.drawingProviders.push(new o.PolarColumnSeriesDrawingProvider(g,this)),this.drawingProviders.push(new r.PointMarkerDrawingProvider(g,this))},p.prototype.toJSON=function(g){g===void 0&&(g=!1);var v=h.prototype.toJSON.call(this,g),y={};return Object.assign(v.options,y),v},p.prototype.getDataPointWidth=function(g,v,y){var m=this.dataSeries.getNativeXValues(),b=g.viewportDimension,S=g.isCategoryCoordinateCalculator;if(y===s.EDataPointWidthMode.Range){var _=g.visibleMax-g.visibleMin;return g.viewportDimension/_*v}else return y===s.EDataPointWidthMode.Absolute?v:(0,n.getDataPointWidth)(m,g,b,v,S,this.dataSeries.dataDistributionCalculator.isSortedAscending,this.webAssemblyContext)},Object.defineProperty(p.prototype,"columnYMode",{get:function(){return a.EColumnYMode.TopBottom},set:function(g){throw Error("columnYMode is not supported for PolarColumnRenderableSeries")},enumerable:!1,configurable:!0}),p.prototype.newHitTestProvider=function(){return new c.RectangleSeriesHitTestProvider(this,this.webAssemblyContext)},p})(u.FastRectangleRenderableSeries);return Mb.PolarColumnRenderableSeries=f,Mb}var cA={},dA={},bPe;function D3e(){if(bPe)return dA;bPe=1;var t=dA&&dA.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(dA,"__esModule",{value:!0}),dA.PolarMountainSeriesHitTestProvider=void 0;var e=$i(),i=tl(),n=vl(),r=gl(),o=Ca(),a=Eo(),s=gR(),l=Zi(),u=Kie(),c=10,d=(function(f){t(h,f);function h(){return f!==null&&f.apply(this,arguments)||this}return h.prototype.hitTest=function(p,g){return this.hitTestMountainBody(p,g)},h.prototype.hitTestDataPoint=function(p,g,v){var y=v>0?v:c;return f.prototype.hitTestDataPoint.call(this,p,g,y)},h.prototype.hitTestXSlice=function(p,g){return this.hitTestMountainBody(p,g)},h.prototype.hitTestMountainBody=function(p,g){var v=this,y=this.getTranslatedHitTestPoint(p,g);if(!y)return i.HitTestInfo.empty();var m=this.parentSeries.xAxis,b=m.reverseTransform(y.x,y.y),S=this.currentRenderPassData,_=S.xCoordinateCalculator,C=S.yCoordinateCalculator,P=b.x,x=b.y,E=this.parentSeries.dataSeries;if(!E)return i.HitTestInfo.empty();var A=u.polarHitTestHelpers.getNearestPolarPointXDirSorted(this.webAssemblyContext,_,C,E,P,x),R=A.nearestPointIndex,M=A.distance,D=A.secondNearestPointIndex,F=_.isCategoryCoordinateCalculator,I=F?E.getNativeIndexes():E.getNativeXValues(),V=E.getNativeYValues(),z=!1,G=!1;if(D!=-1){G=!0;var H=function(Y,te){var oe=_.getCoordinate(Y),de=C.getCoordinate(te),ge=r.annotationHelpers.convertPolarToCartesian(m,!1,v.webAssemblyContext,o.ECoordinateMode.Pixel,oe*l.DpiHelper.PIXEL_RATIO,de);return new e.Point(ge.x,ge.y)},U=H(0,0),k=H(I.get(R),V.get(R)),X=H(I.get(D),V.get(D));z=(0,a.testPointInTriangle)(y.x,y.y,U.x,U.y,k.x,k.y,X.x,X.y)}var W=n.hitTestHelpers.createHitTestInfo(this.parentSeries,_,C,!1,E,I,V,P,x,R,M);return W.isHit=z,W.isWithinDataBounds=G,W},h})(s.PolarDataPointHitTestProvider);return dA.PolarMountainSeriesHitTestProvider=d,dA}var SPe;function R3e(){if(SPe)return cA;SPe=1;var t=cA&&cA.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(cA,"__esModule",{value:!0}),cA.PolarMountainRenderableSeries=void 0;var e=hn(),i=Xs(),n=mm(),r=$W(),o=un(),a=JW(),s=pR(),l=QW(),u=rH(),c=nC(),d=D3e(),f=(function(h){t(p,h);function p(g,v){var y=this,m,b,S;return y=h.call(this,g,v)||this,y.isPolar=!0,y.type=e.ESeriesType.PolarMountainSeries,y.lineType=n.ELineType.Normal,y.interpolateLineProperty=!1,y.dataLabelProviderProperty||(y.dataLabelProviderProperty=new s.PolarDataLabelProvider(v==null?void 0:v.dataLabels),y.dataLabelProviderProperty.onAttach(y.webAssemblyContext,y)),y.interpolateLineProperty=(m=v==null?void 0:v.interpolateLine)!==null&&m!==void 0?m:y.interpolateLineProperty,!((b=y.paletteProvider)===null||b===void 0)&&b.onAttached&&((S=y.paletteProvider)===null||S===void 0||S.onAttached(y)),y}return Object.defineProperty(p.prototype,"isDigitalLine",{get:function(){return!1},enumerable:!1,configurable:!0}),p.prototype.onAttach=function(g){h.prototype.onAttach.call(this,g),this.renderDataTransformProperty=new a.PolarInterpolateLineRenderDataTransform(this,this.webAssemblyContext,[this.drawingProviders[0],this.drawingProviders[1]])},Object.defineProperty(p.prototype,"interpolateLine",{get:function(){return this.interpolateLineProperty},set:function(g){this.interpolateLineProperty!==g&&(this.interpolateLineProperty=g,this.notifyPropertyChanged("interpolateLine"))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"fillY1",{get:function(){return(0,i.stripAutoColor)(this.fillY1Property)},set:function(g){this.fillY1Property=g,this.notifyPropertyChanged(o.PROPERTY.FILL_Y1)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"fillLinearGradient1",{get:function(){return this.fillLinearGradient1Property},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"fillLinear1Gradient",{set:function(g){g!==this.fillLinearGradient1Property&&(this.fillLinearGradient1Property=g,this.notifyPropertyChanged(o.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"zeroLineY",{get:function(){return Math.max(this.zeroLineYProperty,this.xAxis.visibleRange.min)},enumerable:!1,configurable:!0}),p.prototype.toJSON=function(g){g===void 0&&(g=!1);var v=h.prototype.toJSON.call(this,g),y={interpolateLine:this.interpolateLine};return Object.assign(v.options,y),v},p.prototype.addDrawingProviders=function(g,v){this.drawingProviders.push(new l.PolarBandSeriesDrawingProvider(g,this)),this.drawingProviders.push(new u.PolarLineSeriesDrawingProvider(g,this)),this.drawingProviders.push(new c.PolarPointMarkerDrawingProvider(g,this))},p.prototype.newHitTestProvider=function(){return new d.PolarMountainSeriesHitTestProvider(this,this.webAssemblyContext)},p})(r.BaseMountainRenderableSeries);return cA.PolarMountainRenderableSeries=f,cA}var fA={},_Pe;function M3e(){if(_Pe)return fA;_Pe=1;var t=fA&&fA.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(fA,"__esModule",{value:!0}),fA.PolarStackedMountainRenderableSeries=void 0;var e=hn(),i=Xs(),n=mm(),r=un(),o=qW(),a=QW(),s=rH(),l=nC(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v;return p=c.call(this,f,h)||this,p.isPolar=!0,p.type=e.ESeriesType.PolarStackedMountainSeries,p.lineType=n.ELineType.Normal,!((g=p.paletteProvider)===null||g===void 0)&&g.onAttached&&((v=p.paletteProvider)===null||v===void 0||v.onAttached(p)),p}return Object.defineProperty(d.prototype,"isDigitalLine",{get:function(){return!1},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"fillY1",{get:function(){return(0,i.stripAutoColor)(this.fillY1Property)},set:function(f){this.fillY1Property=f,this.notifyPropertyChanged(r.PROPERTY.FILL_Y1)},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"fillLinearGradient1",{get:function(){return this.fillLinearGradient1Property},enumerable:!1,configurable:!0}),Object.defineProperty(d.prototype,"fillLinear1Gradient",{set:function(f){f!==this.fillLinearGradient1Property&&(this.fillLinearGradient1Property=f,this.notifyPropertyChanged(r.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new a.PolarBandSeriesDrawingProvider(f,this,function(p){return p.y1Values},function(p){return p.yValues})),this.drawingProviders.push(new s.PolarLineSeriesDrawingProvider(f,this,function(p){return p.y1Values})),this.drawingProviders.push(new l.PolarPointMarkerDrawingProvider(f,this,function(p){return p.y1Values}))},d})(o.StackedMountainRenderableSeries);return fA.PolarStackedMountainRenderableSeries=u,fA}var kb={},hA={},PPe;function L3e(){if(PPe)return hA;PPe=1;var t=hA&&hA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(hA,"__esModule",{value:!0}),hA.BoxPlotPointSeriesWrapped=void 0;var e=Yo(),i=zi(),n=wm(),r=(function(o){t(a,o);function a(s){var l=o.call(this,s,void 0,i.EDataSeriesValueType.Default,[e.EValueName.BoxPlotMedian,e.EValueName.BoxPlotMax,e.EValueName.BoxPlotUpper,e.EValueName.BoxPlotLower,e.EValueName.BoxPlotMinimum])||this;return l.type=i.EDataSeriesType.BoxPlot,l}return Object.defineProperty(a.prototype,"medianValues",{get:function(){return this.yValuesArray[0]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"maximumValues",{get:function(){return this.yValuesArray[1]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"upperQuartileValues",{get:function(){return this.yValuesArray[2]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"lowerQuartileValues",{get:function(){return this.yValuesArray[3]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"minimumValues",{get:function(){return this.yValuesArray[4]},enumerable:!1,configurable:!0}),a})(n.BasePointSeriesWrapped);return hA.BoxPlotPointSeriesWrapped=r,hA}var pA={},CPe;function k3e(){if(CPe)return pA;CPe=1;var t=pA&&pA.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(pA,"__esModule",{value:!0}),pA.BoxPlotSeriesDrawingProvider=void 0;var e=Br(),i=Vd(),n=bo(),r=tu(),o=Ls(),a=Sn(),s=un(),l=du(),u=(function(c){t(d,c);function d(f,h,p,g){return c.call(this,f,h,p,g)||this}return d.prototype.onAttachSeries=function(){c.prototype.onAttachSeries.call(this),this.capPenCache=new o.Pen2DCache(this.webAssemblyContext),this.whiskersPenCache=new o.Pen2DCache(this.webAssemblyContext),this.medianLinePenCache=new o.Pen2DCache(this.webAssemblyContext),this.boxPenCache=new o.Pen2DCache(this.webAssemblyContext),this.boxFillBrushCache=new r.BrushCache(this.webAssemblyContext),this.nativeBoxDrawingProvider=new this.webAssemblyContext.SCRTRectangleSeriesDrawingProvider,this.boxArgs=new this.webAssemblyContext.SCRTRectangleDrawingParams,this.nativeLineDrawingProvider=new this.webAssemblyContext.SCRTLineSegmentDrawingProvider,this.lineArgs=new this.webAssemblyContext.SCRTLineDrawingParams,this.tempXVec=new this.webAssemblyContext.SCRTDoubleVector,this.tempYVec=new this.webAssemblyContext.SCRTDoubleVector;var f=this.getProperties(),h=f.capStroke,p=f.capStrokeDashArray,g=f.capStrokeThickness,v=f.whiskersStroke,y=f.whiskersStrokeDashArray,m=f.whiskersStrokeThickness,b=f.medianStroke,S=f.medianStrokeDashArray,_=f.medianStrokeThickness,C=f.boxStroke,P=f.boxStrokeThickness,x=f.boxStrokeDashArray,E=f.opacity;(0,o.createPenInCache)(this.capPenCache,h,g,E,p,!1),(0,o.createPenInCache)(this.whiskersPenCache,v,m,E,y,!1),(0,o.createPenInCache)(this.medianLinePenCache,b,_,E,S,!1),(0,o.createPenInCache)(this.boxPenCache,C,P,E,x,!1),this.createBoxBrush()},d.prototype.onDetachSeries=function(){c.prototype.onDetachSeries.call(this),this.delete()},d.prototype.getProperties=function(){var f=this.parentSeries,h=f.dataPointWidthMode,p=f.cap,g=p.dataPointWidth,v=p.stroke,y=p.strokeDashArray,m=p.strokeThickness,b=f.whiskers,S=b.stroke,_=b.strokeDashArray,C=b.strokeThickness,P=f.medianLine,x=P.stroke,E=P.strokeDashArray,A=P.strokeThickness,R=f.dataPointWidth,M=f.stroke,D=f.strokeThickness,F=f.strokeDashArray,I=f.fill,V=f.fillLinearGradient,z=f.opacity;return{dataPointWidthMode:h,capDataPointWidth:g,capStroke:v,capStrokeDashArray:y,capStrokeThickness:m,whiskersStroke:S,whiskersStrokeDashArray:_,whiskersStrokeThickness:C,medianStroke:x,medianStrokeDashArray:E,medianStrokeThickness:A,boxDataPointWidth:R,boxStroke:M,boxStrokeThickness:D,boxStrokeDashArray:F,boxFill:I,boxFillLinearGradient:V,opacity:z??1}},d.prototype.delete=function(){this.capPenCache=(0,e.deleteSafe)(this.capPenCache),this.whiskersPenCache=(0,e.deleteSafe)(this.whiskersPenCache),this.medianLinePenCache=(0,e.deleteSafe)(this.medianLinePenCache),this.boxPenCache=(0,e.deleteSafe)(this.boxPenCache),this.boxFillBrushCache=(0,e.deleteSafe)(this.boxFillBrushCache),this.nativeBoxDrawingProvider=(0,e.deleteSafe)(this.nativeBoxDrawingProvider),this.boxArgs=(0,e.deleteSafe)(this.boxArgs),this.nativeLineDrawingProvider=(0,e.deleteSafe)(this.nativeLineDrawingProvider),this.lineArgs=(0,e.deleteSafe)(this.lineArgs),this.tempXVec=(0,e.deleteSafe)(this.tempXVec),this.tempYVec=(0,e.deleteSafe)(this.tempYVec),c.prototype.delete.call(this)},d.prototype.drawBoxes=function(f,h){var p=h.pointSeries,g=this.parentSeries.parentSurface.seriesViewRect,v=this.getProperties(),y=v.boxStroke,m=v.boxFill,b=v.opacity,S=v.boxFillLinearGradient;this.boxArgs.Reset(),this.boxArgs.verticalChart=h.isVerticalChart,this.boxArgs.columnWidth=this.parentSeries.getDataPointWidth(h.xCoordinateCalculator,this.parentSeries.dataPointWidth,this.parentSeries.dataPointWidthMode),this.boxArgs.xMode=(0,i.convertColumnMode)(i.EColumnMode.Mid,this.webAssemblyContext),this.boxArgs.yMode=(0,i.convertYColumnMode)(i.EColumnYMode.TopBottom,this.webAssemblyContext);var _=(0,o.getScrtPenFromCache)(this.boxPenCache);_&&this.boxArgs.SetLinesPen(_);var C=(0,r.getScrtBrushFromCache)(this.boxFillBrushCache);C&&this.boxArgs.SetFillBrush(C),this.boxArgs.viewportWidth=g.width,this.boxArgs.viewportHeight=g.height,c.prototype.applyStrokeFillPaletting.call(this,y,_,m,C,b,!1,S!==void 0),this.boxArgs.SetPalettedColors(this.palettingState.palettedColors),this.boxArgs.paletteStart=this.palettingState.paletteStartIndex;var P=h.xCoordinateCalculator.isCategoryCoordinateCalculator,x=p.xValues,E=p.upperQuartileValues,A=p.lowerQuartileValues,R=P?p.indexes:x,M=this.getStartAndCount(h,R),D=M.startIndex,F=M.count;this.boxArgs.count=F,this.boxArgs.startIndex=D,this.boxArgs.SetXValues(R),this.boxArgs.SetYValues(E),this.boxArgs.SetWValues(A);var I=this.parentSeries.dataSeries,V=I.fifoCapacity,z=I.fifoSweeping,G=I.fifoSweepingGap,H=p.fifoStartIndex;z&&V===this.parentSeries.dataSeries.count()&&(this.boxArgs.count=H);var U=f.getNativeContext();this.boxArgs.SetNativeContext(U),this.boxArgs.SetXCoordinateCalculator(h.xCoordinateCalculator.nativeCalculator),this.boxArgs.SetYCoordinateCalculator(h.yCoordinateCalculator.nativeCalculator),this.nativeBoxDrawingProvider.DrawPoints(this.boxArgs),z&&V===this.parentSeries.dataSeries.count()&&(this.boxArgs.startIndex=Math.min(E.size(),H+G),this.boxArgs.count=Math.max(0,E.size()-H-G),this.boxArgs.count>0&&this.nativeBoxDrawingProvider.DrawPoints(this.boxArgs))},d.prototype.drawWhiskers=function(f,h,p,g){var v=h.pointSeries,y=h.xCoordinateCalculator.isCategoryCoordinateCalculator,m=this.getStartAndCount(h,v.xValues),b=m.startIndex,S=m.count,_=y?v.indexes:v.xValues,C=(0,o.getScrtPenFromCache)(this.whiskersPenCache);C&&(this.lineArgs.Reset(),this.lineArgs.fourVectorsMode=!0,this.lineArgs.SetWValues(g),this.lineArgs.SetLinesPen(C),this.lineArgs.forceShaderMethod=!0,this.lineArgs.verticalChart=h.isVerticalChart,this.lineArgs.count=S,this.lineArgs.startIndex=b,this.lineArgs.SetNativeContext(f.getNativeContext()),this.lineArgs.SetXValues(_),this.lineArgs.SetYValues(p),this.lineArgs.SetXCoordinateCalculator(h.xCoordinateCalculator.nativeCalculator),this.lineArgs.SetYCoordinateCalculator(h.yCoordinateCalculator.nativeCalculator),this.nativeLineDrawingProvider.DrawLinesVec(this.lineArgs))},d.prototype.drawLines=function(f,h,p,g){p&&(this.lineArgs.Reset(),this.lineArgs.SetLinesPen(p),this.lineArgs.forceShaderMethod=!0,this.lineArgs.forceClamp=!0,this.lineArgs.verticalChart=h.isVerticalChart,this.lineArgs.count=g,this.lineArgs.startIndex=0,this.lineArgs.SetNativeContext(f.getNativeContext()),this.lineArgs.SetXValues(this.tempXVec),this.lineArgs.SetYValues(this.tempYVec),this.lineArgs.SetXCoordinateCalculator(h.xCoordinateCalculator.nativeCalculator),this.lineArgs.SetYCoordinateCalculator(h.yCoordinateCalculator.nativeCalculator),this.nativeLineDrawingProvider.DrawLinesVec(this.lineArgs))},d.prototype.prepareTempCapVectors=function(f,h,p,g,v){this.tempXVec.resizeFast(h*4),this.tempYVec.resizeFast(h*4);for(var y=this.getProperties(),m=y.capDataPointWidth,b=y.dataPointWidthMode,S=this.parentSeries.getDataPointWidth(g,m,b),_=g.getDataWidth(S),C=_*.5,P=p.minimumValues,x=p.maximumValues,E=v?p.indexes:p.xValues,A=(0,n.vectorToArrayViewF64)(E,this.webAssemblyContext),R=(0,n.vectorToArrayViewF64)(P,this.webAssemblyContext),M=(0,n.vectorToArrayViewF64)(x,this.webAssemblyContext),D=(0,n.vectorToArrayViewF64)(this.tempXVec,this.webAssemblyContext),F=(0,n.vectorToArrayViewF64)(this.tempYVec,this.webAssemblyContext),I=f;I<f+h;I++){var V=A[I],z=R[I],G=M[I],H=I*4;D[H]=V-C,F[H]=G,D[H+1]=V+C,F[H+1]=G,D[H+2]=V-C,F[H+2]=z,D[H+3]=V+C,F[H+3]=z}return h*4},d.prototype.prepareTempMedianVectors=function(f,h,p,g,v){this.tempXVec.resizeFast(h*2),this.tempYVec.resizeFast(h*2);for(var y=this.getProperties(),m=y.boxDataPointWidth,b=y.dataPointWidthMode,S=this.parentSeries.getDataPointWidth(g,m,b),_=g.getDataWidth(S),C=_*.5,P=p.medianValues,x=v?p.indexes:p.xValues,E=(0,n.vectorToArrayViewF64)(x,this.webAssemblyContext),A=(0,n.vectorToArrayViewF64)(P,this.webAssemblyContext),R=(0,n.vectorToArrayViewF64)(this.tempXVec,this.webAssemblyContext),M=(0,n.vectorToArrayViewF64)(this.tempYVec,this.webAssemblyContext),D=f;D<f+h;D++){var F=E[D],I=A[D],V=D*2;R[V]=F-C,M[V]=I,R[V+1]=F+C,M[V+1]=I}return h*2},d.prototype.draw=function(f,h){var p,g,v,y,m=this.parentSeries.parentSurface,b=m.clipRect,S=m.seriesViewRect,_=h.pointSeries,C=h.xCoordinateCalculator.isCategoryCoordinateCalculator,P=this.getStartAndCount(h,_.xValues),x=P.startIndex,E=P.count;this.drawWhiskers(f,h,_.lowerQuartileValues,_.minimumValues),!((p=this.parentSeries.xAxis)===null||p===void 0)&&p.isVerticalChart&&f.setTranslationRotationAndClip(b,S.x,S.y),this.drawWhiskers(f,h,_.upperQuartileValues,_.maximumValues),!((g=this.parentSeries.xAxis)===null||g===void 0)&&g.isVerticalChart&&f.setTranslationRotationAndClip(b,S.x,S.y),this.drawLines(f,h,(0,o.getScrtPenFromCache)(this.capPenCache),this.prepareTempCapVectors(x,E,_,h.xCoordinateCalculator,C)),!((v=this.parentSeries.xAxis)===null||v===void 0)&&v.isVerticalChart&&f.setTranslationRotationAndClip(b,S.x,S.y),this.drawBoxes(f,h),!((y=this.parentSeries.xAxis)===null||y===void 0)&&y.isVerticalChart&&f.setTranslationRotationAndClip(b,S.x,S.y),this.drawLines(f,h,(0,o.getScrtPenFromCache)(this.medianLinePenCache),this.prepareTempMedianVectors(x,E,_,h.xCoordinateCalculator,C))},d.prototype.onDpiChanged=function(f){c.prototype.onDpiChanged.call(this,f),this.onSeriesPropertyChange(s.PROPERTY.OPACITY)},d.prototype.onSeriesPropertyChange=function(f){c.prototype.onSeriesPropertyChange.call(this,f);var h=this.getProperties(),p=h.boxStroke,g=h.boxStrokeThickness,v=h.opacity,y=h.boxStrokeDashArray,m=h.capStroke,b=h.capStrokeThickness,S=h.capStrokeDashArray,_=h.whiskersStroke,C=h.whiskersStrokeDashArray,P=h.whiskersStrokeThickness,x=h.medianStroke,E=h.medianStrokeDashArray,A=h.medianStrokeThickness;(f===s.PROPERTY.STROKE||f===s.PROPERTY.STROKE_THICKNESS||f===s.PROPERTY.OPACITY||f===s.PROPERTY.STROKE_DASH_ARRAY)&&(0,o.createPenInCache)(this.boxPenCache,p,g,v,y,!1),(f===s.PROPERTY.OPACITY||f===s.PROPERTY.FILL||f===s.PROPERTY.FILL_LINEAR_GRADIENT)&&this.createBoxBrush(),(f===s.PROPERTY.OPACITY||f===s.PROPERTY.BOX_SERIES_CAP)&&(0,o.createPenInCache)(this.capPenCache,m,b,v,S,!1),(f===s.PROPERTY.OPACITY||f===s.PROPERTY.BOX_SERIES_WHISKERS)&&(0,o.createPenInCache)(this.whiskersPenCache,_,P,v,C,!1),(f===s.PROPERTY.OPACITY||f===s.PROPERTY.BOX_SERIES_MEDIAN)&&(0,o.createPenInCache)(this.medianLinePenCache,x,A,v,E,!1)},d.prototype.createBoxBrush=function(){var f=this.parentSeries.parentSurface,h=this.getProperties(),p=h.opacity,g=h.boxFill,v=h.boxFillLinearGradient,y=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.height/a.SciChartSurfaceBase.domMasterCanvas.height:1,m=f!=null&&f.isCopyCanvasSurface?f.domCanvas2D.width/a.SciChartSurfaceBase.domMasterCanvas.width:1;return(0,r.createBrushInCache)(this.boxFillBrushCache,g,p,y,m,v)},d})(l.BaseSeriesDrawingProvider);return pA.BoxPlotSeriesDrawingProvider=u,pA}var gA={},TPe;function I3e(){if(TPe)return gA;TPe=1;var t=gA&&gA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(gA,"__esModule",{value:!0}),gA.BoxPlotSeriesHitTestProvider=void 0;var e=Vl(),i=vl(),n=tl(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.hitTest=function(s,l){var u=this.getTranslatedHitTestPoint(s,l);if(!u)return n.HitTestInfo.empty();var c=this.currentRenderPassData,d=c.xCoordinateCalculator,f=c.yCoordinateCalculator,h=c.isVerticalChart,p=h?u.y:u.x,g=h?u.x:u.y,v=this.parentSeries.dataSeries;if(!v)return n.HitTestInfo.empty();var y=i.hitTestHelpers.getNearestXPoint(this.webAssemblyContext,d,v,p,v.dataDistributionCalculator.isSortedAscending),m=v.getNativeXValues(),b=v.getNativeMedianValues(),S=this.parentSeries,_=S.getDataPointWidth,C=S.dataPointWidth,P=S.dataPointWidthMode,x=S.cap.dataPointWidth,E=_(d,Math.max(C,x),P),A=i.hitTestHelpers.createHitTestInfo(this.parentSeries,d,f,h,v,m,b,p,g,y,0,void 0,E),R=v.getNativeMinimumValues(),M=v.getNativeMaximumValues();if(y>=0){A.isHit=i.hitTestHelpers.testIsHitForBoxPlot(d,f,E,v,m,R,M,y,p,g);var D=M.get(y),F=v.getNativeUpperQuartileValues().get(y),I=b.get(y),V=v.getNativeLowerQuartileValues().get(y),z=R.get(y);A.yValues=[D,F,I,V,z]}else A.isHit=!1;return A},a.prototype.hitTestForDataPointSelectionModifier=function(s,l,u){return u===void 0&&(u=e.BaseHitTestProvider.DEFAULT_HIT_TEST_RADIUS),this.hitTest(s,l)},a.prototype.hitTestXSlice=function(s,l){var u=this.hitTest(s,l);return u.isHit=u.isWithinDataBounds,u},a})(e.BaseHitTestProvider);return gA.BoxPlotSeriesHitTestProvider=r,gA}var xPe;function N3e(){if(xPe)return kb;xPe=1;var t=kb&&kb.__extends||(function(){var y=function(m,b){return y=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(S,_){S.__proto__=_}||function(S,_){for(var C in _)Object.prototype.hasOwnProperty.call(_,C)&&(S[C]=_[C])},y(m,b)};return function(m,b){if(typeof b!="function"&&b!==null)throw new TypeError("Class extends value "+String(b)+" is not a constructor or null");y(m,b);function S(){this.constructor=m}m.prototype=b===null?Object.create(b):(S.prototype=b.prototype,new S)}})(),e=kb&&kb.__assign||function(){return e=Object.assign||function(y){for(var m,b=1,S=arguments.length;b<S;b++){m=arguments[b];for(var _ in m)Object.prototype.hasOwnProperty.call(m,_)&&(y[_]=m[_])}return y},e.apply(this,arguments)};Object.defineProperty(kb,"__esModule",{value:!0}),kb.FastBoxPlotRenderableSeries=void 0;var i=Br(),n=di(),r=ud(),o=Em(),a=hn(),s=zi(),l=L3e(),u=Xs(),c=Sn(),d=ju(),f=un(),h=k3e(),p=Yf(),g=I3e(),v=(function(y){t(m,y);function m(b,S){var _=this,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W;return _=y.call(this,b,S)||this,_.type=a.ESeriesType.BoxPlotSeries,_.dataPointWidthModeProperty=o.EDataPointWidthMode.Relative,_.capProperty={dataPointWidth:.25,stroke:c.SciChartSurfaceBase.DEFAULT_THEME.lineSeriesColor,strokeDashArray:[],strokeThickness:2},_.whiskersProperty={stroke:c.SciChartSurfaceBase.DEFAULT_THEME.lineSeriesColor,strokeDashArray:[],strokeThickness:2},_.medianLineProperty={stroke:c.SciChartSurfaceBase.DEFAULT_THEME.lineSeriesColor,strokeDashArray:[],strokeThickness:4},_.dataPointWidthProperty=.5,_.strokeDashArrayProperty=[],_.fillProperty=c.SciChartSurfaceBase.DEFAULT_THEME.columnFillBrush,_.dataPointWidthMode=(C=S==null?void 0:S.dataPointWidthMode)!==null&&C!==void 0?C:_.dataPointWidthModeProperty,S!=null&&S.cap&&(_.capProperty.dataPointWidth=(P=S.cap.dataPointWidth)!==null&&P!==void 0?P:_.capProperty.dataPointWidth,_.capProperty.stroke=(x=S.cap.stroke)!==null&&x!==void 0?x:_.capProperty.stroke,_.capProperty.strokeDashArray=(E=S.cap.strokeDashArray)!==null&&E!==void 0?E:_.capProperty.strokeDashArray,_.capProperty.strokeThickness=(A=S.cap.strokeThickness)!==null&&A!==void 0?A:_.capProperty.strokeThickness),S!=null&&S.whiskers&&(_.whiskersProperty.stroke=(R=S.whiskers.stroke)!==null&&R!==void 0?R:_.whiskersProperty.stroke,_.whiskersProperty.strokeDashArray=(M=S.whiskers.strokeDashArray)!==null&&M!==void 0?M:_.whiskersProperty.strokeDashArray,_.whiskersProperty.strokeThickness=(D=S.whiskers.strokeThickness)!==null&&D!==void 0?D:_.whiskersProperty.strokeThickness),S!=null&&S.medianLine&&(_.medianLineProperty.stroke=(F=S.medianLine.stroke)!==null&&F!==void 0?F:_.medianLineProperty.stroke,_.medianLineProperty.strokeDashArray=(I=S.medianLine.strokeDashArray)!==null&&I!==void 0?I:_.medianLineProperty.strokeDashArray,_.medianLineProperty.strokeThickness=(V=S.medianLine.strokeThickness)!==null&&V!==void 0?V:_.medianLineProperty.strokeThickness),_.strokeThickness=(z=S==null?void 0:S.strokeThickness)!==null&&z!==void 0?z:0,_.dataPointWidthProperty=(G=S==null?void 0:S.dataPointWidth)!==null&&G!==void 0?G:_.dataPointWidthProperty,_.strokeDashArrayProperty=(H=S==null?void 0:S.strokeDashArray)!==null&&H!==void 0?H:_.strokeDashArrayProperty,_.fillProperty=(U=S==null?void 0:S.fill)!==null&&U!==void 0?U:_.fillProperty,_.fillLinearGradientProperty=(k=S==null?void 0:S.fillLinearGradient)!==null&&k!==void 0?k:_.fillLinearGradientProperty,_.drawingProviders=[new h.BoxPlotSeriesDrawingProvider(b,_),new p.PointMarkerDrawingProvider(b,_)],!((X=_.paletteProvider)===null||X===void 0)&&X.onAttached&&((W=_.paletteProvider)===null||W===void 0||W.onAttached(_)),S!=null&&S.animation&&_.animationQueue.push(S.animation),_}return m.prototype.applyTheme=function(b){y.prototype.applyTheme.call(this,b);var S=this.parentSurface.previousThemeProvider;this.stroke===S.lineSeriesColor&&(this.stroke=b.lineSeriesColor)},Object.defineProperty(m.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(b){this.dataPointWidthModeProperty=b,this.notifyPropertyChanged(f.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"cap",{get:function(){return this.capProperty},set:function(b){this.capProperty=e(e({},this.capProperty),b),this.notifyPropertyChanged(f.PROPERTY.BOX_SERIES_CAP)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"whiskers",{get:function(){return this.whiskersProperty},set:function(b){this.whiskersProperty=e(e({},this.whiskersProperty),b),this.notifyPropertyChanged(f.PROPERTY.BOX_SERIES_WHISKERS)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"medianLine",{get:function(){return this.medianLineProperty},set:function(b){this.medianLineProperty=e(e({},this.medianLineProperty),b),this.notifyPropertyChanged(f.PROPERTY.BOX_SERIES_MEDIAN)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(b){this.dataPointWidthProperty=b,this.notifyPropertyChanged(f.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"strokeDashArray",{get:function(){return this.strokeDashArrayProperty},set:function(b){this.strokeDashArrayProperty=b,this.notifyPropertyChanged(f.PROPERTY.STROKE_DASH_ARRAY)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fill",{get:function(){return(0,u.stripAutoColor)(this.fillProperty)},set:function(b){this.fillProperty=b,this.notifyPropertyChanged(f.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(b){b!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=b,this.notifyPropertyChanged(f.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(m.prototype,"paletteProvider",{get:function(){},set:function(b){throw new Error("paletteProvider is not supported by FastBoxPlotRenderableSeries!")},enumerable:!1,configurable:!0}),m.prototype.delete=function(){y.prototype.delete.call(this),this.pointSeries=(0,i.deleteSafe)(this.pointSeries)},m.prototype.getXRange=function(){var b,S=y.prototype.getXRange.call(this),_=(0,d.getDataPointWidthAdjustment)(this.dataPointWidthMode,this.dataPointWidth,this.dataSeries.count(),S,this.xAxis.getCurrentCoordinateCalculator()),C=new n.NumberRange(S.min-_,S.max+_);return this.strokeThickness?(0,d.adjustRangeByStrokeThickness)(C,this.strokeThickness,(b=this.parentSurface.seriesViewRect)===null||b===void 0?void 0:b.height):C},m.prototype.getYRange=function(b,S){var _;S===void 0&&(S=!1);var C=this.isRunningDataAnimation?s.EDataSeriesValueType.FinalAnimationValues:s.EDataSeriesValueType.Default,P=this.dataSeries.getWindowedYRange(b,!0,S,C,this.yRangeMode);return this.yAxis.type===r.EAxisType.LogarithmicAxis?P:(0,d.adjustRangeByStrokeThickness)(P,this.cap.strokeThickness,(_=this.parentSurface.seriesViewRect)===null||_===void 0?void 0:_.height)},m.prototype.toJSON=function(b){b===void 0&&(b=!1);var S=y.prototype.toJSON.call(this,b),_={dataPointWidthMode:this.dataPointWidthMode,cap:this.capProperty,whiskers:this.whiskersProperty,medianLine:this.medianLineProperty,dataPointWidth:this.dataPointWidth,strokeDashArray:this.strokeDashArray,fill:this.fill,fillLinearGradient:this.fillLinearGradient};return Object.assign(S.options,_),S},m.prototype.toPointSeries=function(b){if(b)throw new Error("Box Plot Series does not support resampling!");return new l.BoxPlotPointSeriesWrapped(this.dataSeries)},m.prototype.newHitTestProvider=function(){return new g.BoxPlotSeriesHitTestProvider(this,this.webAssemblyContext)},m})(d.BaseRenderableSeries);return kb.FastBoxPlotRenderableSeries=v,kb}var vA={},yA={},EPe;function Qie(){if(EPe)return yA;EPe=1;var t=yA&&yA.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(yA,"__esModule",{value:!0}),yA.TriangleSeriesDrawingProvider=void 0;var e=Br(),i=tu(),n=un(),r=du(),o=VI(),a=Yo(),s=(function(l){t(u,l);function u(c,d,f,h){var p=l.call(this,c,d,f,h)||this;return p.brushCache=new i.BrushCache(c),p.args=new c.SCRTTriangleDrawingParams,p}return u.prototype.onDpiChanged=function(c){l.prototype.onDpiChanged.call(this,c),this.onSeriesPropertyChange(n.PROPERTY.STROKE)},u.prototype.onSeriesPropertyChange=function(c){if(l.prototype.onSeriesPropertyChange.call(this,c),c===n.PROPERTY.PALETTE_PROVIDER&&this.brushCache.invalidateCache(),c===n.PROPERTY.FILL||c===n.PROPERTY.OPACITY||c===n.PROPERTY.FILL_LINEAR_GRADIENT){this.palettingState.requiresUpdate=!0;var d=this.getProperties(this.parentSeries),f=d.fill,h=d.opacity,p=d.fillLinearGradient,g=d.customTextureOptions;this.brushCache.create(f,h??1,1,1,p,g)}},u.prototype.getProperties=function(c){var d=c.fill,f=c.opacity,h=c.drawMode,p=c.polygonVertices,g=c.fillLinearGradient,v=c.customTextureOptions;return{fill:d,opacity:f,drawMode:h,polygonVertices:p,fillLinearGradient:g,customTextureOptions:v}},u.prototype.onAttachSeries=function(){l.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTTriangleSeriesDrawingProvider;var c=this.getProperties(this.parentSeries),d=c.fill,f=c.opacity,h=c.fillLinearGradient,p=c.customTextureOptions;this.brushCache.create(d,f??1,1,1,h,p)},u.prototype.onDetachSeries=function(){l.prototype.onDetachSeries.call(this),this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider)},u.prototype.getBrushForDrawing=function(){return this.brushCache},u.prototype.draw=function(c,d){var f=this.getProperties(this.parentSeries),h=f.fill,p=f.drawMode,g=f.polygonVertices,v=(0,i.getScrtBrushFromCache)(this.getBrushForDrawing());if(!(!v||!h)){var y=d.pointSeries;this.args.Reset(),p===o.ETriangleSeriesDrawMode.Polygon?this.args.drawMode=this.webAssemblyContext.SCRTTriangleDrawMode.Polygon:p===o.ETriangleSeriesDrawMode.Strip?this.args.drawMode=this.webAssemblyContext.SCRTTriangleDrawMode.Strip:this.args.drawMode=this.webAssemblyContext.SCRTTriangleDrawMode.List,this.args.iPolygonVertices=g,this.args.SetFillBrush(v),this.args.verticalChart=d.isVerticalChart;var m=d.xCoordinateCalculator.isCategoryCoordinateCalculator,b=this.xSelector(y);this.parentSeries.hasFillPaletteProvider()&&(l.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,void 0,this.parentSeries.fill,v,this.parentSeries.opacity,!1,!0),this.args.SetPalettedColors(this.palettingState.palettedColors));var S=m?y.indexes:b,_=this.ySelector(y),C=this.getStartAndCount(d,S),P=C.startIndex,x=C.count;this.args.count=x,this.args.startIndex=P;var E=y.getYValuesByName(a.EValueName.X1),A=y.getYValuesByName(a.EValueName.Y1);if(E&&A)this.args.SetZValues(E),this.args.SetYValues(A);else if(E||A)throw new Error("You must either supply both x1 values and y1 values for texture coordinates, or neither to use screen coordinates for the texture");this.updateArgs(d);var R=c.getNativeContext();this.drawTriangles(c,R,S,_,d.xCoordinateCalculator.nativeCalculator,d.yCoordinateCalculator.nativeCalculator,this.args,this.parentSeries.parentSurface.seriesViewRect)}},u.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.brushCache=(0,e.deleteSafe)(this.brushCache),l.prototype.delete.call(this)},u.prototype.drawTriangles=function(c,d,f,h,p,g,v,y){v.SetNativeContext(d),v.SetXValues(f),v.SetYValues(h),v.SetXCoordinateCalculator(p),v.SetYCoordinateCalculator(g),this.nativeDrawingProvider.DrawTrianglesVec(v)},u})(r.BaseSeriesDrawingProvider);return yA.TriangleSeriesDrawingProvider=s,yA}var mA={},wPe;function F3e(){if(wPe)return mA;wPe=1;var t=mA&&mA.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(mA,"__esModule",{value:!0}),mA.TriangleSeriesHitTestProvider=void 0;var e=$i(),i=VI(),n=Vl(),r=vl(),o=tl(),a=(function(s){t(l,s);function l(){return s!==null&&s.apply(this,arguments)||this}return l.prototype.hitTest=function(u,c){var d=this.getTranslatedHitTestPoint(u,c);if(!d)return o.HitTestInfo.empty();var f=this.currentRenderPassData,h=f.xCoordinateCalculator,p=f.yCoordinateCalculator,g=f.isVerticalChart,v=g?d.y:d.x,y=g?d.x:d.y,m=this.parentSeries.dataSeries;if(!m)return o.HitTestInfo.empty();var b=m.getNativeXValues(),S=m.getNativeYValues(),_=this.parentSeries,C=_.drawMode,P=_.polygonVertices,x=r.hitTestHelpers.getNearestTriangle(this.webAssemblyContext,h,p,b,S,v,y,C,P),E=x.nearestPointIndex,A=x.nearestPointIndex2,R=x.isHit,M=new o.HitTestInfo(this.parentSeries);M.seriesName=this.parentSeries.seriesName,M.dataSeriesType=m.type,M.hitTestPoint=new e.Point(v,y);var D=h.getDataValue(v),F=p.getDataValue(y);if(M.hitTestPointValues=new e.Point(D,F),M.dataSeriesIndex=E,M.point2dataSeriesIndex=A,M.distance=R?0:1,E>=0){var I=m.getNativeValue(b,E),V=m.getNativeValue(S,E);M.xCoord=h.getCoordinate(I),M.yCoord=p.getCoordinate(V),M.xValue=I,M.yValue=V,M.metadata=m.getMetadataAt(E)}if(A>=0){var z=m.getNativeValue(b,A),G=m.getNativeValue(S,A);M.point2xCoord=h.getCoordinate(z),M.point2yCoord=p.getCoordinate(G),M.point2xValue=z,M.point2yValue=G,M.metadata=m.getMetadataAt(E);var H=m.valueNames.reduce(function(oe,de){return oe[de]=m.getNativeValue(m.getYValuesByName(de),M.point2dataSeriesIndex),oe},{});M.point2yValueByName=H}if(E>=0){for(var U=C===i.ETriangleSeriesDrawMode.Polygon?P:3,k=[],X=[],W=E;W<E+U;W++){var Y=m.getNativeValue(b,W),te=m.getNativeValue(S,W);k.push(Y),X.push(te)}M.xValues=k,M.yValues=X}return M.isHit=R,M},l.prototype.hitTestForDataPointSelectionModifier=function(u,c){return this.hitTest(u,c)},l.prototype.hitTestXSlice=function(u,c){return this.hitTest(u,c)},l.prototype.hitTestDataPoint=function(u,c,d){return this.hitTest(u,c)},l})(n.BaseHitTestProvider);return mA.TriangleSeriesHitTestProvider=a,mA}var Ib={},APe;function B3e(){if(APe)return Ib;APe=1;var t=Ib&&Ib.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})(),e=Ib&&Ib.__spreadArray||function(o,a,s){if(s||arguments.length===2)for(var l=0,u=a.length,c;l<u;l++)(c||!(l in a))&&(c||(c=Array.prototype.slice.call(a,0,l)),c[l]=a[l]);return o.concat(c||Array.prototype.slice.call(a))};Object.defineProperty(Ib,"__esModule",{value:!0}),Ib.TriangleSeriesInfo=void 0;var i=VI(),n=Am(),r=(function(o){t(a,o);function a(s,l,u,c){var d=this,f,h;return d=o.call(this,s,l)||this,d.drawMode=u,d.vertices=u===i.ETriangleSeriesDrawMode.Polygon?c:3,((f=l.xValues)===null||f===void 0?void 0:f.length)===d.vertices&&((h=l.yValues)===null||h===void 0?void 0:h.length)===d.vertices&&(d.xValues=e([],l.xValues,!0),d.yValues=e([],l.yValues,!0)),d}return Object.defineProperty(a.prototype,"formattedXValues",{get:function(){var s=this;return this.xValues?this.xValues.map(function(l){return s.getXCursorFormattedValue(l)}):[]},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"formattedYValues",{get:function(){var s=this;return this.yValues?this.yValues.map(function(l){return s.getYCursorFormattedValue(l)}):[]},enumerable:!1,configurable:!0}),a.prototype.getValuesWithLabels=function(s,l,u,c){var d=o.prototype.getValuesWithLabels.call(this,s,l,u,c);d.push(this.concatValueWithLabel(this.dataSeriesIndex.toFixed(0),"Index"));for(var f=this.formattedXValues,h=this.formattedYValues,p=0;p<f.length;p++){var g=p+1,v=f[p],y=h[p];d.push(this.concatTwoValuesWithLabels(v,y,"".concat(l).concat(g),"".concat(u).concat(g)))}return d},a})(n.SeriesInfo);return Ib.TriangleSeriesInfo=r,Ib}var OPe;function ene(){if(OPe)return vA;OPe=1;var t=vA&&vA.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(vA,"__esModule",{value:!0}),vA.FastTriangleRenderableSeries=void 0;var e=hn(),i=VI(),n=Xs(),r=Sn(),o=ju(),a=un(),s=fR(),l=Yf(),u=Qie(),c=F3e(),d=B3e(),f=(function(h){t(p,h);function p(g,v){var y=this,m,b,S;return y=h.call(this,g,v)||this,y.type=e.ESeriesType.TriangleSeries,y.drawModeProperty=i.ETriangleSeriesDrawMode.List,y.polygonVerticesProperty=0,y.fillProperty=r.SciChartSurfaceBase.DEFAULT_THEME.columnFillBrush,y.dataLabelProviderProperty||(y.dataLabelProviderProperty=new s.LineSeriesDataLabelProvider(v==null?void 0:v.dataLabels),y.dataLabelProviderProperty.onAttach(y.webAssemblyContext,y)),y.drawModeProperty=(m=v==null?void 0:v.drawMode)!==null&&m!==void 0?m:y.drawModeProperty,y.polygonVerticesProperty=(b=v==null?void 0:v.polygonVertices)!==null&&b!==void 0?b:y.polygonVerticesProperty,y.fillProperty=(S=v==null?void 0:v.fill)!==null&&S!==void 0?S:y.fillProperty,y.fillLinearGradientProperty=v==null?void 0:v.fillLinearGradient,y.customTextureOptionsProperty=v==null?void 0:v.customTextureOptions,y}return p.prototype.addDrawingProviders=function(g,v){this.drawingProviders.push(new u.TriangleSeriesDrawingProvider(g,this)),this.drawingProviders.push(new l.PointMarkerDrawingProvider(g,this))},Object.defineProperty(p.prototype,"drawMode",{get:function(){return this.drawModeProperty},set:function(g){this.drawModeProperty=g,this.notifyPropertyChanged(a.PROPERTY.TRIANGLE_DRAW_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"polygonVertices",{get:function(){return this.polygonVerticesProperty},set:function(g){this.polygonVerticesProperty=g,this.notifyPropertyChanged(a.PROPERTY.POLYGON_VERTICES)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"fill",{get:function(){return(0,n.stripAutoColor)(this.fillProperty)},set:function(g){this.fillProperty=g,this.notifyPropertyChanged(a.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(g){g!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=g,this.notifyPropertyChanged(a.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(g){g!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=g,this.notifyPropertyChanged(a.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),p.prototype.resolveAutoColors=function(g,v,y){if(h.prototype.resolveAutoColors.call(this,g,v,y),this.fillProperty.startsWith(n.AUTO_COLOR)){var m=y.getFillColor(g,v,this.webAssemblyContext);this.fill=n.AUTO_COLOR+this.adjustAutoColor("fill",m)}},p.prototype.getSeriesInfo=function(g){return new d.TriangleSeriesInfo(this,g,this.drawMode,this.polygonVertices)},p.prototype.toJSON=function(g){g===void 0&&(g=!1);var v=h.prototype.toJSON.call(this,g),y={fill:this.fill,drawMode:this.drawMode,polygonVertices:this.polygonVertices,customTextureOptions:this.customTextureOptions,fillLinearGradient:this.fillLinearGradient};return Object.assign(v.options,y),v},p.prototype.newHitTestProvider=function(){return new c.TriangleSeriesHitTestProvider(this,this.webAssemblyContext)},p})(o.BaseRenderableSeries);return vA.FastTriangleRenderableSeries=f,vA}var Nb={},DPe;function j3e(){if(DPe)return Nb;DPe=1;var t=Nb&&Nb.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})(),e=Nb&&Nb.__assign||function(){return e=Object.assign||function(c){for(var d,f=1,h=arguments.length;f<h;f++){d=arguments[f];for(var p in d)Object.prototype.hasOwnProperty.call(d,p)&&(c[p]=d[p])}return c},e.apply(this,arguments)};Object.defineProperty(Nb,"__esModule",{value:!0}),Nb.PolarXyScatterRenderableSeries=void 0;var i=di(),n=hn(),r=JW(),o=Yie(),a=pR(),s=nC(),l=gR(),u=(function(c){t(d,c);function d(f,h){var p=this,g,v,y;return p=c.call(this,f,e(e({},h),{dataLabelProvider:(g=h==null?void 0:h.dataLabelProvider)!==null&&g!==void 0?g:new a.PolarDataLabelProvider(h==null?void 0:h.dataLabels)}))||this,p.isPolar=!0,p.type=n.ESeriesType.PolarScatterSeries,p.clipToTotalAngle=!1,!((v=p.paletteProvider)===null||v===void 0)&&v.onAttached&&((y=p.paletteProvider)===null||y===void 0||y.onAttached(p)),p.renderDataTransformProperty=new r.PolarInterpolateLineRenderDataTransform(p,p.webAssemblyContext,[]),p}return d.prototype.getIndicesRange=function(f,h){return this.clipToTotalAngle?c.prototype.getIndicesRange.call(this,f,h):new i.NumberRange(0,this.dataSeries.count()-1)},d.prototype.addDrawingProviders=function(f,h){this.drawingProviders.push(new s.PolarPointMarkerDrawingProvider(f,this))},d.prototype.newHitTestProvider=function(){return new l.PolarDataPointHitTestProvider(this,this.webAssemblyContext)},d})(o.XyScatterRenderableSeries);return Nb.PolarXyScatterRenderableSeries=u,Nb}var bA={},RPe;function V3e(){if(RPe)return bA;RPe=1;var t=bA&&bA.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(bA,"__esModule",{value:!0}),bA.PolarStackedMountainCollection=void 0;var e=hn(),i=xW(),n=(function(r){t(o,r);function o(){var a=r!==null&&r.apply(this,arguments)||this;return a.type=e.ESeriesType.PolarStackedMountainCollection,a.isPolar=!0,a}return o})(i.StackedMountainCollection);return bA.PolarStackedMountainCollection=n,bA}var SA={},MPe;function H3e(){if(MPe)return SA;MPe=1;var t=SA&&SA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(SA,"__esModule",{value:!0}),SA.PolarStackedColumnCollection=void 0;var e=di(),i=hn(),n=zre(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.isPolar=!0,u.type=i.ESeriesType.PolarStackedColumnCollection,u}return a.prototype.getXRange=function(){return this.isEnoughDataToDraw()?this.getFirstSeries().getXRange():new e.NumberRange},a.prototype.getYRange=function(s,l){var u,c,d=o.prototype.getYRange.call(this,s,l),f=(c=(u=this.getFirstSeries())===null||u===void 0?void 0:u.defaultY1)!==null&&c!==void 0?c:0;return d.union(new e.NumberRange(f,f))},a})(n.StackedXyCollection);return SA.PolarStackedColumnCollection=r,SA}var _A={},LPe;function U3e(){if(LPe)return _A;LPe=1;var t=_A&&_A.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(_A,"__esModule",{value:!0}),_A.PolarStackedColumnRenderableSeries=void 0;var e=Br(),i=Vd(),n=Em(),r=hn(),o=DI(),a=Xs(),s=Sn(),l=YW(),u=un(),c=Yf(),d=q3(),f=KW(),h=Zie(),p=(function(g){t(v,g);function v(y,m){var b=this,S,_,C,P,x;return b=g.call(this,y,m)||this,b.type=r.ESeriesType.PolarStackedColumnSeries,b.isPolar=!0,b.fillProperty=s.SciChartSurfaceBase.DEFAULT_THEME.columnFillBrush,b.polarColumnXModeProperty=i.EColumnMode.Mid,b.polarColumnYModeProperty=i.EColumnYMode.TopBottom,b.dataPointWidthProperty=.8,b.dataPointWidthModeProperty=n.EDataPointWidthMode.Range,b.fill=(S=m==null?void 0:m.fill)!==null&&S!==void 0?S:b.fillProperty,b.fillLinearGradientProperty=(_=m==null?void 0:m.fillLinearGradient)!==null&&_!==void 0?_:b.fillLinearGradientProperty,b.polarColumnXModeProperty=(C=m==null?void 0:m.columnXMode)!==null&&C!==void 0?C:b.polarColumnXModeProperty,b.polarColumnYModeProperty=(P=m==null?void 0:m.columnYMode)!==null&&P!==void 0?P:b.polarColumnYModeProperty,b.dataPointWidthModeProperty=(x=m==null?void 0:m.dataPointWidthMode)!==null&&x!==void 0?x:b.dataPointWidthModeProperty,b.customTextureOptionsProperty=m==null?void 0:m.customTextureOptions,b}return v.prototype.addDrawingProviders=function(y,m){this.drawingProviders.push(new h.PolarColumnSeriesDrawingProvider(y,this)),this.drawingProviders.push(new c.PointMarkerDrawingProvider(y,this))},Object.defineProperty(v.prototype,"columnXMode",{get:function(){return this.polarColumnXModeProperty},set:function(y){this.polarColumnXModeProperty!==y&&(this.polarColumnXModeProperty=y,this.notifyPropertyChanged("POLAR_COLUMN_MODE"))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"dataPointWidthMode",{get:function(){return this.dataPointWidthModeProperty},set:function(y){this.dataPointWidthModeProperty=y,this.notifyPropertyChanged(u.PROPERTY.DATA_POINT_WIDTH_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"columnYMode",{get:function(){return i.EColumnYMode.TopBottom},set:function(y){throw Error("columnYMode is not supported for PolarColumnRenderableSeries")},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"defaultY1",{get:function(){return 0},set:function(y){},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"dataPointWidth",{get:function(){return this.dataPointWidthProperty},set:function(y){this.dataPointWidthProperty=y,this.notifyPropertyChanged(u.PROPERTY.DATA_POINT_WIDTH)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fillLinearGradient",{get:function(){return this.fillLinearGradientProperty},set:function(y){y!==this.fillLinearGradientProperty&&(this.fillLinearGradientProperty=y,this.notifyPropertyChanged(u.PROPERTY.FILL_LINEAR_GRADIENT))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"customTextureOptions",{get:function(){return this.customTextureOptionsProperty},set:function(y){y!==this.customTextureOptionsProperty&&(this.customTextureOptionsProperty=y,this.notifyPropertyChanged(u.PROPERTY.CUSTOM_TEXTURE_OPTIONS))},enumerable:!1,configurable:!0}),v.prototype.onAttachToParentCollection=function(y,m,b){if(this.parentCollection)throw new Error("Invalid operation in StackedMountainRenderableSeries.onAttachToParentCollection, this series has been already attached to collection. Please detach it from the collection before attaching to another");this.parentCollection=y,this.getParentSurfaceFn=m,this.notifyParentPropertyChangedFn=b},v.prototype.onAttach=function(y){if(this.invalidateParentCallback)throw new Error("Invalid operation in sciChartSurface.attachSeries, this series has already been attached to a SciChartSurface. Please detach it from a SciChartSurface before attaching to another");this.invalidateParentCallback=y.invalidateElement,this.drawingProviders.forEach(function(m){return m.onAttachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(y.invalidateElement)},v.prototype.onDetach=function(){this.invalidateParentCallback=void 0,this.drawingProviders.forEach(function(y){return y.onDetachSeries()}),this.rolloverModifierProps.setInvalidateParentCallback(void 0)},v.prototype.draw=function(y,m){var b;this.currentRenderPassData=m,(b=this.hitTestProvider)===null||b===void 0||b.update(m);try{y.pushShaderEffect(this.effect),this.drawingProviders.forEach(function(S){return S.draw(y,m)})}finally{y.popShaderEffect()}},v.prototype.onDpiChanged=function(y){g.prototype.onDpiChanged.call(this,y),this.notifyPropertyChanged(u.PROPERTY.STROKE)},Object.defineProperty(v.prototype,"fill",{get:function(){return(0,a.stripAutoColor)(this.fillProperty)},set:function(y){this.fillProperty!==y&&(this.fillProperty=y,this.drawingProviders.forEach(function(m){return m.onSeriesPropertyChange(u.PROPERTY.FILL)}),this.drawingProviders.forEach(function(m){return m.onSeriesPropertyChange(u.PROPERTY.FILL_Y1)}),this.notifyPropertyChanged(u.PROPERTY.FILL))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"fillY1",{set:function(y){throw new Error("Setting fillY1 property is not supported on StackedMountainRenderableSeries")},enumerable:!1,configurable:!0}),v.prototype.getCurrentRenderPassData=function(){return this.currentRenderPassData},v.prototype.toJSON=function(y){y===void 0&&(y=!1);var m=g.prototype.toJSON.call(this,y),b={columnXMode:this.columnXMode,columnYMode:this.columnYMode,dataPointWidthMode:this.dataPointWidthMode,stroke:this.stroke,strokeThickness:this.strokeThickness,fill:this.fill,fillLinearGradient:this.fillLinearGradient};return Object.assign(m.options,b),m},v.prototype.delete=function(){this.drawingProviders.forEach(function(y){return y.delete()}),this.drawingProviders=[],this.effect=(0,e.deleteSafe)(this.effect),g.prototype.delete.call(this)},v.prototype.toPointSeries=function(y){return new o.XyPointSeriesWrapped(this.dataSeries)},v.prototype.hasStrokePaletteProvider=function(){var y=this.paletteProvider;return(y==null?void 0:y.overrideStrokeArgb)!==void 0},v.prototype.hasFillPaletteProvider=function(){var y=this.paletteProvider;return(y==null?void 0:y.overrideFillArgb)!==void 0},v.prototype.hasPointMarkerPaletteProvider=function(){var y=this.paletteProvider;return(y==null?void 0:y.overridePointMarkerArgb)!==void 0},v.prototype.resolveAutoColors=function(y,m,b){if(g.prototype.resolveAutoColors.call(this,y,m,b),this.fillProperty.startsWith(a.AUTO_COLOR)){var S=b.getFillColor(y,m,this.webAssemblyContext);this.fill=a.AUTO_COLOR+this.adjustAutoColor("fill",S)}},v.prototype.getXRange=function(){var y=this.dataSeries.xRange,m=this.dataSeries.count();return(0,d.getXRange)(y,m,this.dataPointWidth)},v.prototype.getDataPointWidth=function(y,m){var b=this.dataSeries.getNativeXValues(),S=y.viewportDimension,_=y.isCategoryCoordinateCalculator;if(m<0||m>1)throw new Error("WidthFraction should be between 0.0 and 1.0 inclusive");var C=b.size(),P=S,x=C;if(x>1){var E=Number.NEGATIVE_INFINITY,A=Number.MAX_VALUE;if(_)E=y.getCoordinate(C-1),A=y.getCoordinate(0);else{var R=void 0;try{R=this.webAssemblyContext.NumberUtil.MinMax(b,!1),A=R.minD,E=R.maxD}finally{(0,e.deleteSafe)(R)}E=y.getCoordinate(E),A=y.getCoordinate(A)}P=Math.abs(E-A)/(x-1)}else x===1&&(P=Math.min(P,y.getCoordinate(b.get(0))*2));return P*m},v.prototype.newHitTestProvider=function(){return new f.RectangleSeriesHitTestProvider(this,this.webAssemblyContext)},v})(l.BaseStackedRenderableSeries);return _A.PolarStackedColumnRenderableSeries=p,_A}var Fb={},PA={},kPe;function z3e(){if(kPe)return PA;kPe=1;var t=PA&&PA.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(PA,"__esModule",{value:!0}),PA.PolarHeatMapDataLabelProvider=void 0;var e=$i(),i=Ca(),n=gl(),r=NI(),o=nR(),a=Zi(),s=tH(),l=(function(u){t(c,u);function c(d){var f=this,h;return f=u.call(this,d)||this,f.polarLabelModeProperty=r.EPolarLabelMode.Horizontal,f.polarLabelModeProperty=(h=d==null?void 0:d.polarLabelMode)!==null&&h!==void 0?h:f.polarLabelModeProperty,f}return Object.defineProperty(c.prototype,"polarLabelMode",{get:function(){return this.polarLabelModeProperty},set:function(d){this.polarLabelModeProperty=d,this.invalidateParent()},enumerable:!1,configurable:!0}),c.prototype.shouldGenerate=function(d,f,h){return!0},c.prototype.shouldSkipLabel=function(d,f,h,p,g){return!1},c.prototype.toCartesian=function(d,f){var h=this.parentSeries.xAxis;return n.annotationHelpers.convertPolarToCartesian(h,!1,this.parentSeries.parentSurface.webAssemblyContext2D,i.ECoordinateMode.Pixel,d*a.DpiHelper.PIXEL_RATIO,f)},c.prototype.getPosition=function(d,f,h,p,g,v,y,m){var b=this.parentSeries,S=m.isVerticalChart?b.yAxis:b.xAxis,_=m.xCoordinateCalculator.getCoordinate(h),C=m.xCoordinateCalculator.hasFlippedCoordinates?-1:1;_-=C*v/2;var P=m.yCoordinateCalculator.getCoordinate(p),x=m.yCoordinateCalculator.hasFlippedCoordinates?-1:1;P-=x*y/2;var E=m.isVerticalChart?P:_,A=m.isVerticalChart?_:P,R=this.toCartesian(E,A),M=R.x,D=R.y,F=new e.Point(M,D);M-=g.width/2,D+=g.height/2;var I=o.labelHelper.getPolarLabelRotation(this.polarLabelMode,S.startAngle+E);return{position:new e.Point(M,D),rotationCenter:F,rotationAngle:I}},Object.defineProperty(c.prototype,"useRotation",{get:function(){return this.polarLabelMode!==r.EPolarLabelMode.Horizontal},enumerable:!1,configurable:!0}),c})(s.HeatMapDataLabelProvider);return PA.PolarHeatMapDataLabelProvider=l,PA}var CA={},IPe;function $3e(){if(IPe)return CA;IPe=1;var t=CA&&CA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(CA,"__esModule",{value:!0}),CA.PolarHeatmapDrawingProvider=void 0;var e=Gie(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.draw=function(o,a){var s,l,u,c=(s=this.heatTextureCache)===null||s===void 0?void 0:s.value;if(c){var d=this.parentSeries.dataSeries,f=d.xStart,h=a.xCoordinateCalculator.getCoordinate(f),p=(u=(l=d.getZValues()[0])===null||l===void 0?void 0:l.length)!==null&&u!==void 0?u:0,g=f+d.xStep*p,v=a.xCoordinateCalculator.getCoordinate(g),y=d.getNormalizedVector(this.parentSeries.colorMap,this.parentSeries.fillValuesOutOfRange);this.packedFloatParams=this.webAssemblyContext.SCRTFillTextureFloat32(c,d.arrayWidth,d.arrayHeight,y),this.packedFloatParams.x=0,this.packedFloatParams.y=1;var m=d.yRange,b=a.yCoordinateCalculator.getCoordinate(m.min),S=a.yCoordinateCalculator.getCoordinate(m.max);o.getNativeContext();var _=this.packedFloatParams,C=new this.webAssemblyContext.SCRTContourParams,P=new this.webAssemblyContext.SCRTHeatmapSeriesDrawingProvider;this.recreatePalette();var x=this.parentSeries.xAxis,E=x.getTransform();P.DrawPolarHeatmap(E,b,S,h,this.paletteTexture.getTexture(),c,_,C,v),C.delete(),_.delete()}},r})(e.UniformHeatmapDrawingProvider);return CA.PolarHeatmapDrawingProvider=i,CA}var NPe;function W3e(){if(NPe)return Fb;NPe=1;var t=Fb&&Fb.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})(),e=Fb&&Fb.__assign||function(){return e=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},e.apply(this,arguments)};Object.defineProperty(Fb,"__esModule",{value:!0}),Fb.PolarUniformHeatmapRenderableSeries=void 0;var i=Uo(),n=hn(),r=XW(),o=z3e(),a=$3e(),s=(function(l){t(u,l);function u(c,d){var f=this,h,p=(h=d.dataLabelProvider)!==null&&h!==void 0?h:new o.PolarHeatMapDataLabelProvider(d==null?void 0:d.dataLabels);return f=l.call(this,c,e(e({},d),{dataLabelProvider:p}))||this,f.isPolar=!0,f.type=n.ESeriesType.PolarUniformHeatmapSeries,f}return u.prototype.addDrawingProviders=function(c,d){i.IS_TEST_ENV||this.drawingProviders.push(new a.PolarHeatmapDrawingProvider(c,this))},u})(r.UniformHeatmapRenderableSeries);return Fb.PolarUniformHeatmapRenderableSeries=s,Fb}var s7={},FPe;function vR(){return FPe||(FPe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ESeriesType3D=void 0,(function(e){e.ScatterRenderableSeries3D="ScatterRenderableSeries3D",e.SurfaceMeshRenderableSeries3D="SurfaceMeshRenderableSeries3D",e.PointLineRenderableSeries3D="PointLineRenderableSeries3D",e.ColumnRenderableSeries3D="ColumnRenderableSeries3D"})(t.ESeriesType3D||(t.ESeriesType3D={}))})(s7)),s7}var TA={},Zl={},l7={},BPe;function tne(){return BPe||(BPe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EPointMarker3DType=void 0,(function(e){e.Sphere="Sphere",e.Cube="Cube",e.Pyramid="Pyramid",e.Cylinder="Cylinder",e.Quad="Quad",e.Pixel="Pixel",e.Ellipse="Ellipse",e.Triangle="Triangle",e.Custom="Custom"})(t.EPointMarker3DType||(t.EPointMarker3DType={}))})(l7)),l7}var xA={},u7={},c7={},jPe;function iAt(){return jPe||(jPe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.FILL="Fill",e.SIZE="Size"})(t.PROPERTY||(t.PROPERTY={}))})(c7)),c7}var VPe;function kD(){return VPe||(VPe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.BasePointMarker3D=t.EMarkerType=void 0;var e=ps(),i=ci(),n=KP(),r=iAt();(function(a){a.Pixel="Pixel",a.TexturedQuad="TexturedQuad",a.InstancedMesh="InstancedMesh"})(t.EMarkerType||(t.EMarkerType={}));var o=(function(){function a(s,l){var u,c;this.fillProperty="#FF3333",this.sizeProperty=3,i.Guard.notNull(s,"webAssemblyContext"),this.webAssemblyContext=s,this.propertyChanged=new e.EventHandler,this.fillProperty=(u=l==null?void 0:l.fill)!==null&&u!==void 0?u:this.fillProperty,this.sizeProperty=(c=l==null?void 0:l.size)!==null&&c!==void 0?c:this.sizeProperty}return Object.defineProperty(a.prototype,"fill",{get:function(){return this.fillProperty},set:function(s){this.fillProperty=s,this.notifyPropertyChanged(r.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(a.prototype,"size",{get:function(){return this.sizeProperty},set:function(s){this.sizeProperty=s,this.notifyPropertyChanged(r.PROPERTY.SIZE)},enumerable:!1,configurable:!0}),a.prototype.notifyPropertyChanged=function(s){var l;(l=this.propertyChanged)===null||l===void 0||l.raiseEvent(new n.PropertyChangedEventArgs(s))},a.prototype.toJSON=function(){var s={fill:this.fill,size:this.size};return{type:this.type,options:s}},a})();t.BasePointMarker3D=o})(u7)),u7}var HPe;function G3e(){if(HPe)return xA;HPe=1;var t=xA&&xA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(xA,"__esModule",{value:!0}),xA.BaseMeshPointMarker3D=void 0;var e=kD(),i=(function(n){t(r,n);function r(o,a){return n.call(this,o,a)||this}return Object.defineProperty(r.prototype,"markerType",{get:function(){return e.EMarkerType.InstancedMesh},enumerable:!1,configurable:!0}),r.prototype.toJSON=function(){var o={fill:this.fill,size:this.size};return{type:this.type,options:o}},r})(e.BasePointMarker3D);return xA.BaseMeshPointMarker3D=i,xA}var EA={},UPe;function Y3e(){if(UPe)return EA;UPe=1;var t=EA&&EA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(EA,"__esModule",{value:!0}),EA.BaseTexturePointMarker3D=void 0;var e=kD(),i=(function(n){t(r,n);function r(o,a){return n.call(this,o,a)||this}return Object.defineProperty(r.prototype,"markerType",{get:function(){return e.EMarkerType.TexturedQuad},enumerable:!1,configurable:!0}),r})(e.BasePointMarker3D);return EA.BaseTexturePointMarker3D=i,EA}var zPe;function Ry(){if(zPe)return Zl;zPe=1;var t=Zl&&Zl.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(Zl,"__esModule",{value:!0}),Zl.TrianglePointMarker3D=Zl.EllipsePointMarker3D=Zl.QuadPointMarker=Zl.PixelPointMarker3D=Zl.CylinderPointMarker3D=Zl.PyramidPointMarker3D=Zl.CubePointMarker3D=Zl.SpherePointMarker3D=void 0;var e=tne(),i=G3e(),n=kD(),r=Y3e(),o=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Sphere,y}return Object.defineProperty(p.prototype,"pointsMesh",{get:function(){return this.webAssemblyContext.SCRTGetTemplateMesh(this.webAssemblyContext.eSCRTMesh.SCRT_MESH_SPHERE)},enumerable:!1,configurable:!0}),p})(i.BaseMeshPointMarker3D);Zl.SpherePointMarker3D=o;var a=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Cube,y}return Object.defineProperty(p.prototype,"pointsMesh",{get:function(){return this.webAssemblyContext.SCRTGetTemplateMesh(this.webAssemblyContext.eSCRTMesh.SCRT_MESH_CUBE)},enumerable:!1,configurable:!0}),p})(i.BaseMeshPointMarker3D);Zl.CubePointMarker3D=a;var s=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Pyramid,y}return Object.defineProperty(p.prototype,"pointsMesh",{get:function(){return this.webAssemblyContext.SCRTGetTemplateMesh(this.webAssemblyContext.eSCRTMesh.SCRT_MESH_PYRAMID)},enumerable:!1,configurable:!0}),p})(i.BaseMeshPointMarker3D);Zl.PyramidPointMarker3D=s;var l=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Cylinder,y}return Object.defineProperty(p.prototype,"pointsMesh",{get:function(){return this.webAssemblyContext.SCRTGetTemplateMesh(this.webAssemblyContext.eSCRTMesh.SCRT_MESH_CYLINDER)},enumerable:!1,configurable:!0}),p})(i.BaseMeshPointMarker3D);Zl.CylinderPointMarker3D=l;var u=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Pixel,y.size=0,y}return Object.defineProperty(p.prototype,"markerType",{get:function(){return n.EMarkerType.Pixel},enumerable:!1,configurable:!0}),p})(n.BasePointMarker3D);Zl.PixelPointMarker3D=u;var c=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Quad,y}return Object.defineProperty(p.prototype,"pointsTexture",{get:function(){return this.webAssemblyContext.SCRTGetTemplateTexture(this.webAssemblyContext.eSCRTTexture.SCRT_TEXTURE_SOLIDWHITE)},enumerable:!1,configurable:!0}),p})(r.BaseTexturePointMarker3D);Zl.QuadPointMarker=c;var d=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Ellipse,y}return Object.defineProperty(p.prototype,"pointsTexture",{get:function(){return this.webAssemblyContext.SCRTGetTemplateTexture(this.webAssemblyContext.eSCRTTexture.SCRT_TEXTURE_CIRCLE)},enumerable:!1,configurable:!0}),p})(r.BaseTexturePointMarker3D);Zl.EllipsePointMarker3D=d;var f=(function(h){t(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.type=e.EPointMarker3DType.Triangle,y}return Object.defineProperty(p.prototype,"pointsTexture",{get:function(){return this.webAssemblyContext.SCRTGetTemplateTexture(this.webAssemblyContext.eSCRTTexture.SCRT_TEXTURE_TRIANGLE)},enumerable:!1,configurable:!0}),p})(r.BaseTexturePointMarker3D);return Zl.TrianglePointMarker3D=f,Zl}var wA={},d7={},$Pe;function Nm(){return $Pe||($Pe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PROPERTY=void 0,(function(e){e.CELL_HARDNESS_FACTOR="CELL_HARDNESS_FACTOR",e.COLOR_MAP_TEXTURE_SIZE="COLOR_MAP_TEXTURE_SIZE",e.CONTOUR_STROKE="CONTOUR_STROKE",e.CONTOUR_OFFSET="CONTOUR_OFFSET",e.CONTOUR_INTERVAL="CONTOUR_INTERVAL",e.CONTOUR_STROKE_THICKNESS="CONTOUR_STROKE_THICKNESS",e.DATA_POINT_WIDTH_X="DATA_POINT_WIDTH_X",e.DATA_POINT_WIDTH_Z="DATA_POINT_WIDTH_Z",e.DATA_SERIES="DATA_SERIES",e.DRAW_MESH_AS="DRAW_MESH_AS",e.DRAW_SKIRT="DRAW_SKIRT",e.FILL="FILL",e.GRADIENT_STOPS="GRADIENT_STOPS",e.HEIGHT_SCALE_FACTOR="HEIGHT_SCALE_FACTOR",e.HIGHLIGHT="HIGHLIGHT",e.IS_ANTIALIASED="IS_ANTIALIASED",e.IS_LINE_STRIP="IS_LINE_STRIP",e.IS_VISIBLE="IS_VISIBLE",e.LIGHTING_FACTOR="LIGHTING_FACTOR",e.MAXIMUM="MAXIMUM",e.MESH_COLOR_PALETTE="MESH_COLOR_PALETTE",e.MESH_PALETTE_MODE="MESH_PALETTE_MODE",e.MESH_RESOLUTION="MESH_RESOLUTION",e.MINIMUM="MINIMUM",e.OPACITY="OPACITY",e.SERIES_NAME="SERIES_NAME",e.PALETTE_PROVIDER="PALETTE_PROVIDER",e.PARENT_SURFACE="PARENT_SURFACE",e.POINT_MARKER3D="POINT_MARKER3D",e.SCENE_ENTITY="SCENE_ENTITY",e.SHININESS="SHININESS",e.STROKE="STROKE",e.STROKE_THICKNESS="STROKE_THICKNESS",e.USE_METADATA_COLORS="USE_METADATA_COLORS",e.Y_OFFSET="Y_OFFSET"})(t.PROPERTY||(t.PROPERTY={}))})(d7)),d7}var AA={},WPe;function iH(){if(WPe)return AA;WPe=1;var t=AA&&AA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(AA,"__esModule",{value:!0}),AA.RenderableSeriesSceneEntity=void 0;var e=ci(),i=bo(),n=VW(),r=HI(),o=(function(a){t(s,a);function s(l,u,c){var d=a.call(this,l)||this;return d.parentSeries=u,d.state=c,d.state.setInitialState(),d.hitTest=d.hitTest.bind(d),d.rebuildPointMetadata=d.rebuildPointMetadata.bind(d),d}return s.prototype.Update=function(l){this.currentRenderPassData&&(this.state.validate(this.parentSeries,this.currentRenderPassData)||(this.updateSeries(),this.state.reset(this.parentSeries,this.currentRenderPassData)),a.prototype.Update.call(this,l))},s.prototype.onEngineRestart=function(){a.prototype.onEngineRestart.call(this),this.state.setInitialState()},s.prototype.notifySeriesPropertyChanged=function(l){this.state.setRenderableSeriesPropertyChanged()},s.prototype.hitTestXyz=function(l){var u,c=Math.round(l.x),d=Math.round(l.y),f=this.webAssemblyContext.SCRTGetSelectionInfo(c,d),h=new n.HitTestInfo3D(this.parentSeries,!1);return h.isHit=f.m_uiSelectionIndex>0&&((u=f.GetEntity())===null||u===void 0?void 0:u.GetEntityId())===this.entityId,h.selectionIndex=h.isHit?f.m_uiSelectionIndex:-1,h.hitTestPoint=l,h},s.prototype.rebuildPointMetadata=function(l,u,c,d,f){var h,p,g;e.Guard.notNull(l,"pointColors"),e.Guard.notNull(u,"pointScales"),e.Guard.isTrue(l.size()===d,"pointColors must have correct size"),e.Guard.isTrue(u.size()===d,"pointScales must have correct size");for(var v=!0,y=!0,m=(0,i.vectorToArrayViewUi32)(l,this.webAssemblyContext),b=(0,i.vectorToArrayViewF32)(u,this.webAssemblyContext),S=0;S<d;S++){var _=c[S],C=(p=(h=_==null?void 0:_.vertexColor)!==null&&h!==void 0?h:_==null?void 0:_.vertexColorAbgr)!==null&&p!==void 0?p:f,P=(g=_==null?void 0:_.pointScale)!==null&&g!==void 0?g:1;m[S]=C,b[S]=P,C!==f&&(y=!1),P!==1&&(v=!1)}return{hasDefaultColors:y,hasDefaultScales:v}},s})(r.BaseSceneEntity3D);return AA.RenderableSeriesSceneEntity=o,AA}var PB={},GPe;function nH(){if(GPe)return PB;GPe=1,Object.defineProperty(PB,"__esModule",{value:!0}),PB.RenderableSeriesSceneEntityState=void 0;var t=(function(){function e(i,n,r,o,a){i===void 0&&(i=!0),n===void 0&&(n=!0),r===void 0&&(r=!0),o===void 0&&(o=!0),a===void 0&&(a={xVisibleMin:0,xVisibleMax:0,yVisibleMin:0,yVisibleMax:0,zVisibleMin:0,zVisibleMax:0,xWorldDimension:0,yWorldDimension:0,zWorldDimension:0}),this.isInitialStateProperty=i,this.isDataSeriesModifiedProperty=n,this.isRenderableSeriesPropertyChangedProperty=r,this.isAxisCubeStateChangedProperty=o,this.axisCubeState=a}return Object.defineProperty(e.prototype,"isInitialState",{get:function(){return this.isInitialStateProperty},enumerable:!1,configurable:!0}),e.prototype.setInitialState=function(){this.isInitialStateProperty=!0},Object.defineProperty(e.prototype,"isDataSeriesModified",{get:function(){return this.isDataSeriesModifiedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isRenderableSeriesPropertyChanged",{get:function(){return this.isRenderableSeriesPropertyChangedProperty},enumerable:!1,configurable:!0}),e.prototype.setRenderableSeriesPropertyChanged=function(){this.isRenderableSeriesPropertyChangedProperty=!0},Object.defineProperty(e.prototype,"isAxisCubeStateChanged",{get:function(){return this.isAxisCubeStateChangedProperty},enumerable:!1,configurable:!0}),e.prototype.validate=function(i,n){var r;this.isDataSeriesModifiedProperty=(r=i.dataSeries)===null||r===void 0?void 0:r.isModified;var o=.001;return this.isAxisCubeStateChangedProperty=Math.abs(this.axisCubeState.xVisibleMin-n.xCalc.visibleMin)>o||Math.abs(this.axisCubeState.xVisibleMax-n.xCalc.visibleMax)>o||Math.abs(this.axisCubeState.yVisibleMin-n.yCalc.visibleMin)>o||Math.abs(this.axisCubeState.yVisibleMax-n.yCalc.visibleMax)>o||Math.abs(this.axisCubeState.zVisibleMin-n.zCalc.visibleMin)>o||Math.abs(this.axisCubeState.zVisibleMax-n.zCalc.visibleMax)>o||Math.abs(this.axisCubeState.xWorldDimension-n.worldDimensions.x)>o||Math.abs(this.axisCubeState.yWorldDimension-n.worldDimensions.y)>o||Math.abs(this.axisCubeState.zWorldDimension-n.worldDimensions.z)>o,!this.isInitialState&&!this.isDataSeriesModified&&!this.isAxisCubeStateChanged},e.prototype.reset=function(i,n){var r;this.isInitialStateProperty=!1,this.isDataSeriesModifiedProperty=!1,this.isRenderableSeriesPropertyChangedProperty=!1,this.isAxisCubeStateChangedProperty=!1,this.axisCubeState={xVisibleMin:n.xCalc.visibleMin,xVisibleMax:n.xCalc.visibleMax,yVisibleMin:n.yCalc.visibleMin,yVisibleMax:n.yCalc.visibleMax,zVisibleMin:n.zCalc.visibleMin,zVisibleMax:n.zCalc.visibleMax,xWorldDimension:n.worldDimensions.x,yWorldDimension:n.worldDimensions.y,zWorldDimension:n.worldDimensions.z},(r=i.dataSeries)===null||r===void 0||r.resetModified()},e})();return PB.RenderableSeriesSceneEntityState=t,PB}var YPe;function q3e(){if(YPe)return wA;YPe=1;var t=wA&&wA.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(wA,"__esModule",{value:!0}),wA.ColumnSceneEntity=void 0;var e=Br(),i=Im(),n=Ti(),r=Uf(),o=Nm(),a=iH(),s=nH(),l=(function(u){t(c,u);function c(d,f){var h=u.call(this,d,f,new s.RenderableSeriesSceneEntityState)||this;return h.type=i.ESceneEntityType.ColumnSceneEntity,h.setNativeEntity(d.SCRTColumnsSceneEntity.implement(h)),h.sceneEntityParams=new d.SCRTColumnsSceneEntityParams,h}return c.prototype.delete=function(){this.instanceColors=(0,e.deleteSafe)(this.instanceColors),this.instanceScales=(0,e.deleteSafe)(this.instanceScales),this.sceneEntityParams=(0,e.deleteSafe)(this.sceneEntityParams),u.prototype.delete.call(this)},c.prototype.Render=function(){u.prototype.Render.call(this)},c.prototype.notifySeriesPropertyChanged=function(d){d===o.PROPERTY.POINT_MARKER3D||d===o.PROPERTY.USE_METADATA_COLORS||d===o.PROPERTY.FILL?this.updateSeries():d===o.PROPERTY.OPACITY?this.nativeEntity.SetOpacity(this.parentSeries.opacity):(d===o.PROPERTY.DATA_POINT_WIDTH_X||d===o.PROPERTY.DATA_POINT_WIDTH_Z)&&this.updateSeries(),u.prototype.notifySeriesPropertyChanged.call(this,d)},c.prototype.hitTest=function(d){return u.prototype.hitTestXyz.call(this,d)},c.prototype.updateSeries=function(){var d=this.parentSeries.dataSeries;if(!(!d||!this.currentRenderPassData)){if(d.type!==r.EDataSeriesType3D.Xyz3D)throw new Error("DataSeries type for a ColumnRenderableSeries3D must be XyzDataSeries3D");var f=this.parentSeries.pointMarker;if(!f)throw new Error("To render 3D Columns you must provider a PointMarker on BaseRenderableSeries3D");this.parentSeries.fill&&(f.fill=this.parentSeries.fill),this.nativeEntity.SetInstanceSize(this.parentSeries.getDataPointWidth(this.currentRenderPassData,this.parentSeries.dataPointWidthX,this.parentSeries.dataPointWidthZ)),this.nativeEntity.SetInstanceMesh(f.pointsMesh);var h=(0,n.parseColorToUIntArgb)(f.fill);this.nativeEntity.SetColor(h);var p=d.getNativeXValues(),g=d.getNativeYValues(),v=d.getNativeZValues(),y=d.getMetadataValues(),m=d.count();this.instanceColors=this.getOrCreateVector(this.instanceColors,m,this.webAssemblyContext.SCRTUintVector,h),this.instanceScales=this.getOrCreateVector(this.instanceScales,m,this.webAssemblyContext.SCRTFloatVector,1);var b=this.rebuildPointMetadata(this.instanceColors,this.instanceScales,y,m,h),S=b.hasDefaultColors,_=b.hasDefaultScales;this.sceneEntityParams.m_bUseDefaultColors=S||!this.parentSeries.useMetadataColors,this.sceneEntityParams.m_bUseDefaultScale=_,this.sceneEntityParams.SetCoordinateCalculators(this.currentRenderPassData.xCalc.nativeCalculator,this.currentRenderPassData.yCalc.nativeCalculator,this.currentRenderPassData.zCalc.nativeCalculator),this.nativeEntity.UpdateMeshesVec(p,g,v,this.instanceScales,this.instanceColors,this.sceneEntityParams),this.nativeEntity.SetOpacity(this.parentSeries.opacity)}},c})(a.RenderableSeriesSceneEntity);return wA.ColumnSceneEntity=l,wA}var OA={},CB={},qPe;function X3e(){if(qPe)return CB;qPe=1,Object.defineProperty(CB,"__esModule",{value:!0}),CB.Series3DVisibleChangedArgs=void 0;var t=(function(){function e(i,n){this.sourceSeries=i,this.isVisible=n}return e})();return CB.Series3DVisibleChangedArgs=t,CB}var DA={},XPe;function K3e(){if(XPe)return DA;XPe=1;var t=DA&&DA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(DA,"__esModule",{value:!0}),DA.SurfaceMeshSeriesInfo3D=void 0;var e=Eo(),i=Uf(),n=cR(),r=eH(),o=(function(a){t(s,a);function s(l,u){var c=a.call(this,l,u)||this;return c.dataSeriesType=i.EDataSeriesType3D.UniformGrid3D,c.enrichSeriesInfo(),c}return s.prototype.enrichSeriesInfo=function(){if(!(!this.isHit||!this.renderableSeries)){var l=this.renderableSeries.dataSeries;if(l){var u={x:this.hitTestInfo.selectionIjIndices.x,z:this.hitTestInfo.selectionIjIndices.y},c={x:l.getX(u.x),y:l.getYValue(u.z,u.x),z:l.getZ(u.z)},d={x:l.getX(u.x+1),y:l.getYValue(u.z,u.x+1),z:l.getZ(u.z)},f={x:l.getX(u.x),y:l.getYValue(u.z+1,u.x),z:l.getZ(u.z+1)},h={x:l.getX(u.x+1),y:l.getYValue(u.z+1,u.x+1),z:l.getZ(u.z+1)},p=this.renderableSeries.parentSurface;if(!(!p||!p.xAxis||!p.yAxis||!p.zAxis)){var g=p.xAxis.getCurrentCoordinateCalculator(),v=p.yAxis.getCurrentCoordinateCalculator(),y=p.zAxis.getCurrentCoordinateCalculator(),m=new n.Vector3(g.getCoordinate(c.x),v.getCoordinate(c.y),y.getCoordinate(c.z)),b=new n.Vector3(g.getCoordinate(d.x),v.getCoordinate(d.y),y.getCoordinate(d.z)),S=new n.Vector3(g.getCoordinate(f.x),v.getCoordinate(f.y),y.getCoordinate(f.z)),_=new n.Vector3(g.getCoordinate(h.x),v.getCoordinate(h.y),y.getCoordinate(h.z)),C=p.worldToScreenCoord(m),P=p.worldToScreenCoord(b),x=p.worldToScreenCoord(S),E=p.worldToScreenCoord(_),A=(0,e.calcDistance)(C.x,C.y,this.hitTestInfo.hitTestPoint.x,this.hitTestInfo.hitTestPoint.y),R=(0,e.calcDistance)(P.x,P.y,this.hitTestInfo.hitTestPoint.x,this.hitTestInfo.hitTestPoint.y),M=(0,e.calcDistance)(x.x,x.y,this.hitTestInfo.hitTestPoint.x,this.hitTestInfo.hitTestPoint.y),D=(0,e.calcDistance)(E.x,E.y,this.hitTestInfo.hitTestPoint.x,this.hitTestInfo.hitTestPoint.y),F=p.worldDimensions.x*.5,I=p.worldDimensions.z*.5,V=Math.min(A,R,M,D);V===A&&(this.xIndex=u.x,this.zIndex=u.z,this.xValue=c.x,this.yValue=c.y,this.zValue=c.z,this.hitWorldCoords=new n.Vector3(m.x-F,m.y,m.z-I)),V===M&&(this.xIndex=u.x,this.zIndex=u.z+1,this.xValue=f.x,this.yValue=f.y,this.zValue=f.z,this.hitWorldCoords=new n.Vector3(S.x-F,S.y,S.z-I)),V===R&&(this.xIndex=u.x+1,this.zIndex=u.z,this.xValue=d.x,this.yValue=d.y,this.zValue=d.z,this.hitWorldCoords=new n.Vector3(b.x-F,b.y,b.z-I)),V===D&&(this.xIndex=u.x+1,this.zIndex=u.z+1,this.xValue=h.x,this.yValue=h.y,this.zValue=h.z,this.hitWorldCoords=new n.Vector3(_.x-F,_.y,_.z-I)),this.pointMetadata=l.getMetadataAt(this.zIndex,this.xIndex)}}}},s})(r.SeriesInfo3D);return DA.SurfaceMeshSeriesInfo3D=o,DA}var RA={},KPe;function Z3e(){if(KPe)return RA;KPe=1;var t=RA&&RA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(RA,"__esModule",{value:!0}),RA.XyzSeriesInfo3D=void 0;var e=Uf(),i=cR(),n=eH(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.dataSeriesType=e.EDataSeriesType3D.Xyz3D,u.enrichSeriesInfo(),u}return a.prototype.enrichSeriesInfo=function(){if(!(!this.isHit||!this.renderableSeries)){this.dataSeriesIndex=this.hitTestInfo.selectionIndex-1;var s=this.renderableSeries.dataSeries;if(s){this.xValue=s.getNativeXValues().get(this.dataSeriesIndex),this.yValue=s.getNativeYValues().get(this.dataSeriesIndex),this.zValue=s.getNativeZValues().get(this.dataSeriesIndex);var l=s.getMetadataValues();l&&l.length>this.dataSeriesIndex&&(this.pointMetadata=l[this.dataSeriesIndex]);var u=this.renderableSeries.parentSurface;if(u){var c=u.worldDimensions.x*.5,d=u.worldDimensions.z*.5,f=u.xAxis.getCurrentCoordinateCalculator().getCoordinate(this.xValue)-c,h=u.yAxis.getCurrentCoordinateCalculator().getCoordinate(this.yValue),p=u.zAxis.getCurrentCoordinateCalculator().getCoordinate(this.zValue)-d;this.hitWorldCoords=new i.Vector3(f,h,p)}}}},a})(n.SeriesInfo3D);return RA.XyzSeriesInfo3D=r,RA}var ZPe;function oH(){if(ZPe)return OA;ZPe=1;var t=OA&&OA.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})();Object.defineProperty(OA,"__esModule",{value:!0}),OA.BaseRenderableSeries3D=void 0;var e=mo(),i=X3e(),n=fo(),r=Br(),o=ps(),a=ga(),s=hl(),l=Uf(),u=Nm(),c=vR(),d=eH(),f=K3e(),h=Z3e(),p=(function(g){t(v,g);function v(y,m){var b=this,S,_,C,P;return b=g.call(this)||this,b.isVisibleChanged=new o.EventHandler,b.id=(S=m==null?void 0:m.id)!==null&&S!==void 0?S:(0,s.generateGuid)(),b.webAssemblyContext=y,b.dataSeriesDataChanged=b.dataSeriesDataChanged.bind(b),b.pointMarkerPropertyChanged=b.pointMarkerPropertyChanged.bind(b),b.onDpiChanged=b.onDpiChanged.bind(b),b.hitTest=b.hitTest.bind(b),b.enrichHitTest=b.enrichHitTest.bind(b),b.dataSeries=(m==null?void 0:m.dataSeries)||void 0,b.isVisibleProperty=(m==null?void 0:m.isVisible)!==void 0?m==null?void 0:m.isVisible:!0,m!=null&&m.pointMarker&&"options"in m.pointMarker&&(m.pointMarker=(0,e.createType)(a.EBaseType.PointMarker3D,m.pointMarker.type,y,m.pointMarker.options)),b.pointMarkerProperty=(_=m==null?void 0:m.pointMarker)!==null&&_!==void 0?_:b.pointMarkerProperty,b.seriesNameProperty=(C=m==null?void 0:m.seriesName)!==null&&C!==void 0?C:b.seriesNameProperty,b.strokeProperty=(m==null?void 0:m.stroke)||"#FFFFFF",b.shininessProperty=(m==null?void 0:m.shininess)===void 0?64:m.shininess,b.opacityProperty=(P=m==null?void 0:m.opacity)!==null&&P!==void 0?P:1,b}return v.prototype.applyTheme=function(y){},Object.defineProperty(v.prototype,"opacity",{get:function(){return this.opacityProperty},set:function(y){this.opacityProperty=y,this.notifyPropertyChanged(u.PROPERTY.OPACITY)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"sceneEntity",{get:function(){return this.sceneEntityProperty},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"shininess",{get:function(){return this.shininessProperty},set:function(y){this.shininessProperty=y,this.notifyPropertyChanged(u.PROPERTY.SHININESS)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"paletteProvider",{get:function(){return this.paletteProviderProperty},set:function(y){this.paletteProviderProperty=y,this.notifyPropertyChanged(u.PROPERTY.PALETTE_PROVIDER)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"stroke",{get:function(){return this.strokeProperty},set:function(y){this.strokeProperty=y,this.notifyPropertyChanged(u.PROPERTY.STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"dataSeries",{get:function(){return this.dataSeriesProperty},set:function(y){var m,b;this.dataSeriesProperty=y,(m=this.dataSeriesProperty)===null||m===void 0||m.dataChanged.unsubscribe(this.dataSeriesDataChanged),this.dataSeriesProperty=y,(b=this.dataSeriesProperty)===null||b===void 0||b.dataChanged.subscribe(this.dataSeriesDataChanged),this.notifyPropertyChanged(u.PROPERTY.DATA_SERIES)},enumerable:!1,configurable:!0}),v.prototype.getDataSeriesName=function(){var y;return(y=this.dataSeries)===null||y===void 0?void 0:y.dataSeriesName},Object.defineProperty(v.prototype,"seriesName",{get:function(){var y;return(y=this.seriesNameProperty)!==null&&y!==void 0?y:this.getDataSeriesName()},set:function(y){this.seriesNameProperty!==y&&(this.seriesNameProperty=y,this.notifyPropertyChanged(u.PROPERTY.SERIES_NAME))},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"pointMarker",{get:function(){return this.pointMarkerProperty},set:function(y){this.detachPointMarker(this.pointMarkerProperty),this.pointMarkerProperty=y,this.attachPointMarker(this.pointMarkerProperty),this.notifyPropertyChanged(u.PROPERTY.POINT_MARKER3D)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"parentSurface",{get:function(){return this.parentSurfaceProperty},set:function(y){this.parentSurfaceProperty=y,this.notifyPropertyChanged(u.PROPERTY.PARENT_SURFACE)},enumerable:!1,configurable:!0}),Object.defineProperty(v.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(y){var m,b=this.isVisibleProperty;this.isVisibleProperty=y,this.sceneEntityProperty&&(this.sceneEntityProperty.isVisible=y),b!==y&&((m=this.isVisibleChanged)===null||m===void 0||m.raiseEvent(new i.Series3DVisibleChangedArgs(this,y))),this.notifyPropertyChanged(u.PROPERTY.IS_VISIBLE)},enumerable:!1,configurable:!0}),v.prototype.onAttach=function(y){if(this.parentSurface=y,this.invalidateParentCallback)throw new Error("Invalid operation in sciChart3DSurface.attachSeries, this series has already been attached to a SciChart3DSurface. Please detach it from a SciChart3DSurface before attaching to another");this.invalidateParentCallback=y.invalidateElement},v.prototype.onDetach=function(){this.invalidateParentCallback=void 0,this.parentSurface=void 0},v.prototype.delete=function(){this.sceneEntityProperty=(0,r.deleteSafe)(this.sceneEntityProperty),this.dataSeries=(0,r.deleteSafe)(this.dataSeries)},v.prototype.onDpiChanged=function(y){var m;(m=this.sceneEntityProperty)===null||m===void 0||m.onDpiChanged(y)},v.prototype.hitTest=function(y){if(this.parentSurface&&!this.parentSurface.isHitTestEnabled)throw new Error("Enable hit-test functions by setting SciChart3DSurface.isHitTestEnabled = true");var m=this.sceneEntity.hitTest;return m?this.enrichHitTest(m(y)):d.SeriesInfo3D.empty()},v.prototype.dataSeriesDataChanged=function(){this.invalidateParentCallback&&this.invalidateParentCallback()},v.prototype.enrichHitTest=function(y){var m,b=(m=y.associatedSeries)===null||m===void 0?void 0:m.dataSeries;if(!b)return d.SeriesInfo3D.empty();switch(b.type){case l.EDataSeriesType3D.Xyz3D:return new h.XyzSeriesInfo3D(this,y);case l.EDataSeriesType3D.UniformGrid3D:return new f.SurfaceMeshSeriesInfo3D(this,y);default:throw new Error("Unknown data series type "+b.type)}},v.prototype.setSceneEntity=function(y){this.sceneEntityProperty=y,this.sceneEntityProperty&&(this.sceneEntityProperty.isVisible=this.isVisible),this.notifyPropertyChanged(u.PROPERTY.SCENE_ENTITY)},v.prototype.notifyPropertyChanged=function(y){var m;(m=this.sceneEntityProperty)===null||m===void 0||m.notifySeriesPropertyChanged(y),this.invalidateParentCallback&&this.invalidateParentCallback()},v.prototype.attachPointMarker=function(y){y&&y.propertyChanged.subscribe(this.pointMarkerPropertyChanged)},v.prototype.detachPointMarker=function(y){y&&y.propertyChanged.unsubscribe(this.pointMarkerPropertyChanged)},v.prototype.pointMarkerPropertyChanged=function(y){this.notifyPropertyChanged("pointMarker."+y.propertyName)},v.prototype.toJSON=function(y){var m;y===void 0&&(y=!1);var b=this.getOptions(),S=(m=this.dataSeries)===null||m===void 0?void 0:m.toJSON(y),_=S==null?void 0:S.options;return this.type===c.ESeriesType3D.PointLineRenderableSeries3D?{type:this.type,options:b,xyzData:_}:this.type===c.ESeriesType3D.ScatterRenderableSeries3D?{type:this.type,options:b,xyzData:_}:this.type===c.ESeriesType3D.ColumnRenderableSeries3D?{type:this.type,options:b,xyzData:_}:this.type===c.ESeriesType3D.SurfaceMeshRenderableSeries3D?{type:this.type,options:b,uniformGridData:_}:{type:this.type,options:b}},v.prototype.getOptions=function(){var y,m={id:this.id,isVisible:this.isVisible,opacity:this.opacity,pointMarker:(y=this.pointMarker)===null||y===void 0?void 0:y.toJSON(),stroke:this.stroke,shininess:this.shininess,seriesName:this.seriesNameProperty};return m},v})(n.DeletableEntity);return OA.BaseRenderableSeries3D=p,OA}var JPe;function J3e(){if(JPe)return TA;JPe=1;var t=TA&&TA.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(TA,"__esModule",{value:!0}),TA.ColumnRenderableSeries3D=void 0;var e=Ry(),i=q3e(),n=oH(),r=Nm(),o=vR(),a=(function(s){t(l,s);function l(u,c){var d=this,f,h,p,g;return d=s.call(this,u,c)||this,d.type=o.ESeriesType3D.ColumnRenderableSeries3D,d.dataPointWidthXProperty=1,d.dataPointWidthZProperty=1,d.useMetadataColorsProperty=!1,d.fillProperty="#FF3333",d.dataPointWidthXProperty=(f=c==null?void 0:c.dataPointWidthX)!==null&&f!==void 0?f:d.dataPointWidthXProperty,d.dataPointWidthZProperty=(h=c==null?void 0:c.dataPointWidthZ)!==null&&h!==void 0?h:d.dataPointWidthZProperty,d.useMetadataColors=(p=c==null?void 0:c.useMetadataColors)!==null&&p!==void 0?p:d.useMetadataColors,d.fillProperty=(g=c==null?void 0:c.fill)!==null&&g!==void 0?g:d.fill,c!=null&&c.pointMarker||(d.pointMarkerProperty=new e.CubePointMarker3D(u,{fill:d.fill})),d.setSceneEntity(new i.ColumnSceneEntity(u,d)),d}return Object.defineProperty(l.prototype,"pointMarker",{get:function(){return this.pointMarkerProperty},set:function(u){this.detachPointMarker(this.pointMarkerProperty),this.pointMarkerProperty=u,this.attachPointMarker(this.pointMarkerProperty),this.notifyPropertyChanged(r.PROPERTY.POINT_MARKER3D)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"fill",{get:function(){return this.fillProperty},set:function(u){this.fillProperty=u,this.notifyPropertyChanged(r.PROPERTY.FILL)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"dataPointWidthX",{get:function(){return this.dataPointWidthXProperty},set:function(u){this.dataPointWidthXProperty=u,this.notifyPropertyChanged(r.PROPERTY.DATA_POINT_WIDTH_X)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"dataPointWidthZ",{get:function(){return this.dataPointWidthZProperty},set:function(u){this.dataPointWidthZProperty=u,this.notifyPropertyChanged(r.PROPERTY.DATA_POINT_WIDTH_Z)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"useMetadataColors",{get:function(){return this.useMetadataColorsProperty},set:function(u){this.useMetadataColorsProperty=u,this.notifyPropertyChanged(r.PROPERTY.USE_METADATA_COLORS)},enumerable:!1,configurable:!0}),l.prototype.getDataPointWidth=function(u,c,d){if(!u)return 0;var f=Math.abs(u.xCalc.getCoordinate(0)-u.xCalc.getCoordinate(c)),h=Math.abs(u.zCalc.getCoordinate(0)-u.zCalc.getCoordinate(d));return Math.min(f,h)},l.prototype.getOptions=function(){var u=s.prototype.getOptions.call(this),c={pointMarker:this.pointMarker,dataPointWidthX:this.dataPointWidthX,dataPointWidthZ:this.dataPointWidthZ,useMetadataColors:this.useMetadataColors,fill:this.fill};return Object.assign(u,c)},l})(n.BaseRenderableSeries3D);return TA.ColumnRenderableSeries3D=a,TA}var MA={},LA={},QPe;function Q3e(){if(QPe)return LA;QPe=1;var t=LA&&LA.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(LA,"__esModule",{value:!0}),LA.PointLine3DSceneEntity=void 0;var e=Br(),i=Im(),n=Ti(),r=Uf(),o=Nm(),a=kD(),s=iH(),l=nH(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,h,new l.RenderableSeriesSceneEntityState)||this;return p.type=i.ESceneEntityType.PointLine3DSceneEntity,p.setNativeEntity(f.SCRTPointLine3DSceneEntity.implement(p)),p.sceneEntityParams=new f.SCRTPointLines3DSceneEntityParams,p}return d.prototype.delete=function(){this.pointColors=(0,e.deleteSafe)(this.pointColors),this.pointScales=(0,e.deleteSafe)(this.pointScales),this.sceneEntityParams=(0,e.deleteSafe)(this.sceneEntityParams),c.prototype.delete.call(this)},d.prototype.Render=function(){this.nativeEntity.SetOpacity(this.parentSeries.opacity),c.prototype.Render.call(this)},d.prototype.notifySeriesPropertyChanged=function(f){f===o.PROPERTY.STROKE_THICKNESS&&this.nativeEntity.SetLineStrokeThickness(this.parentSeries.strokeThickness),f===o.PROPERTY.STROKE&&this.nativeEntity.SetStrokeColor((0,n.parseColorToUIntArgb)(this.parentSeries.stroke)),f===o.PROPERTY.POINT_MARKER3D&&this.updateSeries(),c.prototype.notifySeriesPropertyChanged.call(this,f)},d.prototype.hitTest=function(f){return c.prototype.hitTestXyz.call(this,f)},d.prototype.updateSeries=function(){var f=this.parentSeries.dataSeries;if(!(!f||!this.currentRenderPassData)){if(f.type!==r.EDataSeriesType3D.Xyz3D)throw new Error("DataSeries type for a PointLineRenderableSeries3D must be XyzDataSeries3D");var h=(0,n.parseColorToUIntArgb)(this.parentSeries.stroke);this.nativeEntity.SetLineStrokeThickness(this.parentSeries.strokeThickness),this.nativeEntity.SetIsLineStrips(this.parentSeries.isLineStrip),this.nativeEntity.SetIsLineAntialiased(this.parentSeries.isAntiAliased),this.nativeEntity.SetStrokeColor(h),this.updatePointMarker(this.parentSeries.pointMarker);var p=f.getNativeXValues(),g=f.getNativeYValues(),v=f.getNativeZValues(),y=f.getMetadataValues(),m=f.count();this.pointColors=this.getOrCreateVector(this.pointColors,m,this.webAssemblyContext.SCRTUintVector,h),this.pointScales=this.getOrCreateVector(this.pointScales,m,this.webAssemblyContext.SCRTFloatVector,1);var b=this.rebuildPointMetadata(this.pointColors,this.pointScales,y,m,h),S=b.hasDefaultColors,_=b.hasDefaultScales;this.sceneEntityParams.useDefaultColors=S,this.sceneEntityParams.useDefaultScale=_,this.sceneEntityParams.SetCoordinateCalculators(this.currentRenderPassData.xCalc.nativeCalculator,this.currentRenderPassData.yCalc.nativeCalculator,this.currentRenderPassData.zCalc.nativeCalculator),this.nativeEntity.UpdateMeshesVec(p,g,v,this.pointColors,this.pointColors,this.pointScales,this.sceneEntityParams)}},d.prototype.updatePointMarker=function(f){var h=this.webAssemblyContext.eSCRT_POINT_MARKER_TYPE;if(f===void 0||f.markerType===a.EMarkerType.Pixel)this.nativeEntity.SetPointMarkerType(h.SCRT_POINT_MARKER_TYPE_PIXEL),this.nativeEntity.SetPointSize(0);else if(f.markerType===a.EMarkerType.InstancedMesh){var p=f;if(!p.pointsMesh)throw new Error("Expected a BaseMeshPointMarker3D.pointsMesh on 3D pointmarker of type InstancedMesh");this.nativeEntity.SetPointMarkerType(h.SCRT_POINT_MARKER_TYPE_INSTANCED_MESH),this.nativeEntity.SetPointSize(f.size),this.nativeEntity.SetPointMarkerMesh(p.pointsMesh)}else if(f.markerType===a.EMarkerType.TexturedQuad){var g=f;if(!g.pointsTexture)throw new Error("Expected a BaseTexturePointMarker3D.pointsTexture on 3D pointmarker of type TexturedQuad");this.nativeEntity.SetPointMarkerType(h.SCRT_POINT_MARKER_TYPE_TEXTURED_QUAD),this.nativeEntity.SetPointSize(f.size),this.nativeEntity.SetPointMarkerTexture(g.pointsTexture)}else throw new Error("PointLine3DSceneEntity: Unknown pointMarker.markerType "+f.markerType)},d})(s.RenderableSeriesSceneEntity);return LA.PointLine3DSceneEntity=u,LA}var eCe;function eVe(){if(eCe)return MA;eCe=1;var t=MA&&MA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(MA,"__esModule",{value:!0}),MA.PointLineRenderableSeries3D=void 0;var e=Q3e(),i=oH(),n=Nm(),r=vR(),o=(function(a){t(s,a);function s(l,u){var c=this,d,f,h;return c=a.call(this,l,u)||this,c.type=r.ESeriesType3D.PointLineRenderableSeries3D,c.strokeThicknessProperty=(d=u==null?void 0:u.strokeThickness)!==null&&d!==void 0?d:2,c.isLineStripProperty=(f=u==null?void 0:u.isLineStrip)!==null&&f!==void 0?f:!0,c.isAntiAliasedProperty=(h=u==null?void 0:u.isAntiAliased)!==null&&h!==void 0?h:!0,c.setSceneEntity(new e.PointLine3DSceneEntity(l,c)),c}return Object.defineProperty(s.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(l){this.strokeThicknessProperty=l,this.notifyPropertyChanged(n.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"isLineStrip",{get:function(){return this.isLineStripProperty},set:function(l){this.isLineStripProperty=l,this.notifyPropertyChanged(n.PROPERTY.IS_LINE_STRIP)},enumerable:!1,configurable:!0}),Object.defineProperty(s.prototype,"isAntiAliased",{get:function(){return this.isAntiAliasedProperty},set:function(l){this.isAntiAliasedProperty=l,this.notifyPropertyChanged(n.PROPERTY.IS_ANTIALIASED)},enumerable:!1,configurable:!0}),s.prototype.getOptions=function(){var l=a.prototype.getOptions.call(this),u={strokeThickness:this.strokeThickness,isLineStrip:this.isLineStrip,isAntiAliased:this.isAntiAliased};return Object.assign(l,u)},s})(i.BaseRenderableSeries3D);return MA.PointLineRenderableSeries3D=o,MA}var kA={},IA={},tCe;function tVe(){if(tCe)return IA;tCe=1;var t=IA&&IA.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(IA,"__esModule",{value:!0}),IA.ScatterPointsSceneEntity=void 0;var e=Br(),i=Im(),n=Ti(),r=Uf(),o=kD(),a=Nm(),s=iH(),l=nH(),u=(function(c){t(d,c);function d(f,h){var p=c.call(this,f,h,new l.RenderableSeriesSceneEntityState)||this;return p.type=i.ESceneEntityType.ScatterPointsSceneEntity,p.setNativeEntity(f.SCRTPoint3DSceneEntity.implement(p)),p.sceneEntityParams=new f.SCRTPoint3DSceneEntityParams,p.sceneEntityParams.useDefaultColors=!1,p.sceneEntityParams.useDefaultScale=!1,p}return d.prototype.delete=function(){this.pointColors=(0,e.deleteSafe)(this.pointColors),this.pointScales=(0,e.deleteSafe)(this.pointScales),this.sceneEntityParams=(0,e.deleteSafe)(this.sceneEntityParams),c.prototype.delete.call(this)},d.prototype.Render=function(){this.nativeEntity.SetOpacity(this.parentSeries.opacity),c.prototype.Render.call(this)},d.prototype.notifySeriesPropertyChanged=function(f){f===a.PROPERTY.POINT_MARKER3D&&this.updateSeries(),c.prototype.notifySeriesPropertyChanged.call(this,f)},d.prototype.hitTest=function(f){return c.prototype.hitTestXyz.call(this,f)},d.prototype.updateSeries=function(){var f=this.parentSeries.dataSeries;if(!(!f||!this.currentRenderPassData)){if(f.type!==r.EDataSeriesType3D.Xyz3D)throw new Error("DataSeries type for a ScatterRenderableSeries3D must be XyzDataSeries3D");var h=this.parentSeries.pointMarker;if(!h)throw new Error("To render 3D Scatter, bubble or point-clouds, you must provider a PointMarker on BaseRenderableSeries3D");var p=this.webAssemblyContext.eSCRT_POINT_MARKER_TYPE,g=(0,n.parseColorToUIntArgb)(h.fill);switch(h.markerType){case o.EMarkerType.Pixel:this.nativeEntity.SetPointMarkerType(p.SCRT_POINT_MARKER_TYPE_PIXEL),this.nativeEntity.SetPointSize(0),this.nativeEntity.SetPointColor(g);break;case o.EMarkerType.TexturedQuad:var v=h;if(!v.pointsTexture)throw new Error("Expected a BaseTexturePointMarker3D.pointsTexture on 3D pointmarker of type TexturedQuad");this.nativeEntity.SetPointMarkerType(p.SCRT_POINT_MARKER_TYPE_TEXTURED_QUAD),this.nativeEntity.SetPointSize(h.size),this.nativeEntity.SetPointColor(g),this.nativeEntity.SetPointMarkerTexture(v.pointsTexture);break;case o.EMarkerType.InstancedMesh:var y=h;if(!y.pointsMesh)throw new Error("Expected a BaseMeshPointMarker3D.pointsMesh on 3D pointmarker of type InstancedMesh");this.nativeEntity.SetPointMarkerType(p.SCRT_POINT_MARKER_TYPE_INSTANCED_MESH),this.nativeEntity.SetPointSize(h.size),this.nativeEntity.SetPointColor(g),this.nativeEntity.SetPointMarkerMesh(y.pointsMesh);break;default:throw new Error("Unknown pointMarker.markerType "+h.markerType)}var m=f.getNativeXValues(),b=f.getNativeYValues(),S=f.getNativeZValues(),_=f.getMetadataValues(),C=f.count();this.pointColors=this.getOrCreateVector(this.pointColors,C,this.webAssemblyContext.SCRTUintVector,g),this.pointScales=this.getOrCreateVector(this.pointScales,C,this.webAssemblyContext.SCRTFloatVector,1);var P=this.rebuildPointMetadata(this.pointColors,this.pointScales,_,C,g),x=P.hasDefaultColors,E=P.hasDefaultScales;this.sceneEntityParams.useDefaultColors=x,this.sceneEntityParams.useDefaultScale=E,this.sceneEntityParams.SetCoordinateCalculators(this.currentRenderPassData.xCalc.nativeCalculator,this.currentRenderPassData.yCalc.nativeCalculator,this.currentRenderPassData.zCalc.nativeCalculator),this.nativeEntity.UpdateMeshesVec(m,b,S,this.pointColors,this.pointScales,this.sceneEntityParams)}},d})(s.RenderableSeriesSceneEntity);return IA.ScatterPointsSceneEntity=u,IA}var rCe;function rVe(){if(rCe)return kA;rCe=1;var t=kA&&kA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(kA,"__esModule",{value:!0}),kA.ScatterRenderableSeries3D=void 0;var e=tVe(),i=oH(),n=vR(),r=(function(o){t(a,o);function a(s,l){var u=o.call(this,s,l)||this;return u.type=n.ESeriesType3D.ScatterRenderableSeries3D,u.setSceneEntity(new e.ScatterPointsSceneEntity(s,u)),u}return a})(i.BaseRenderableSeries3D);return kA.ScatterRenderableSeries3D=r,kA}var TB={},Bb={},iCe;function yJ(){if(iCe)return Bb;iCe=1;var t=Bb&&Bb.__extends||(function(){var b=function(S,_){return b=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(C,P){C.__proto__=P}||function(C,P){for(var x in P)Object.prototype.hasOwnProperty.call(P,x)&&(C[x]=P[x])},b(S,_)};return function(S,_){if(typeof _!="function"&&_!==null)throw new TypeError("Class extends value "+String(_)+" is not a constructor or null");b(S,_);function C(){this.constructor=S}S.prototype=_===null?Object.create(_):(C.prototype=_.prototype,new C)}})();Object.defineProperty(Bb,"__esModule",{value:!0}),Bb.SurfaceMeshSceneEntity=Bb.SurfaceMeshSceneEntityState=void 0;var e=Br(),i=ci(),n=di(),r=$i(),o=Im(),a=Rf(),s=Ti(),l=X3(),u=Uf(),c=Nm(),d=VW(),f=kL(),h=iH(),p=nH(),g;(function(b){b[b.SCRT_GRID_DRAWING_FEATURES_SOLID=1]="SCRT_GRID_DRAWING_FEATURES_SOLID",b[b.SCRT_GRID_DRAWING_FEATURES_WIREFRAME=2]="SCRT_GRID_DRAWING_FEATURES_WIREFRAME",b[b.SCRT_GRID_DRAWING_FEATURES_CONTOURS=4]="SCRT_GRID_DRAWING_FEATURES_CONTOURS",b[b.SCRT_GRID_DRAWING_FEATURES_SKIRT=8]="SCRT_GRID_DRAWING_FEATURES_SKIRT"})(g||(g={}));function v(b){}var y=(function(b){t(S,b);function S(){return b!==null&&b.apply(this,arguments)||this}return Object.defineProperty(S.prototype,"isColorMapTextureInvalid",{get:function(){return this.isColorMapTextureInvalidProperty},enumerable:!1,configurable:!0}),S.prototype.setColorMapTextureInvalid=function(){this.isColorMapTextureInvalidProperty=!0},S.prototype.validate=function(_,C){return b.prototype.validate.call(this,_,C)&&this.isColorMapTextureInvalid},S.prototype.reset=function(_,C){b.prototype.reset.call(this,_,C),this.isColorMapTextureInvalidProperty=!1},S})(p.RenderableSeriesSceneEntityState);Bb.SurfaceMeshSceneEntityState=y;var m=(function(b){t(S,b);function S(_,C){var P=this,x;return P=b.call(this,_,C,new y)||this,P.type=o.ESceneEntityType.SurfaceMeshSceneEntity,P.setNativeEntity(_.SCRTGridMeshEntity.implement(P)),P.colorMapTexture=(0,e.deleteSafe)(P.colorMapTexture),P.colorMapTexture=(x=P.parentSeries.meshColorPalette)===null||x===void 0?void 0:x.getTexture(P.parentSeries.colorMapTextureSize),P}return S.prototype.notifySeriesPropertyChanged=function(_){(_===c.PROPERTY.MESH_COLOR_PALETTE||_===c.PROPERTY.MESH_PALETTE_MODE||_===c.PROPERTY.MESH_RESOLUTION||_===c.PROPERTY.COLOR_MAP_TEXTURE_SIZE)&&this.state.setColorMapTextureInvalid(),b.prototype.notifySeriesPropertyChanged.call(this,_)},S.prototype.delete=function(){b.prototype.delete.call(this),this.colorMapTexture=(0,e.deleteSafe)(this.colorMapTexture),this.cellColors=(0,e.deleteSafe)(this.cellColors),this.heightCoords=(0,e.deleteSafe)(this.heightCoords),this.zOffsets=(0,e.deleteSafe)(this.zOffsets),this.sourceRowVec=(0,e.deleteSafe)(this.sourceRowVec)},S.prototype.hitTest=function(_){var C,P=Math.round(_.x),x=Math.round(_.y),E=this.webAssemblyContext.SCRTGetSelectionInfo(P,x),A=new d.HitTestInfo3D(this.parentSeries,!1);return A.isHit=((C=E.GetEntity())===null||C===void 0?void 0:C.GetEntityId())===this.entityId,A.selectionIjIndices=A.isHit?new r.Point(E.m_uiHeightMapIndexI,E.m_uiHeightMapIndexJ):void 0,A.hitTestPoint=_,A},S.prototype.Render=function(){if(this.currentRenderPassData){if(!this.colorMapTexture||!this.parentSeries.dataSeries){console.log("Cannot draw a SurfaceMeshRenderableSeries3D without a meshColorPalette or dataSeries!");return}this.nativeEntity.SetOpacity(this.parentSeries.opacity);var _;try{_=new this.webAssemblyContext.SCRTGridDrawingProperties;var C=0;this.hasFlag(this.parentSeries.drawMeshAs,[f.EDrawMeshAs.SOLID_WIREFRAME,f.EDrawMeshAs.SOLID_WIREFRAME,f.EDrawMeshAs.SOLID_WIREFRAME_WITH_CONTOURS])&&(C|=g.SCRT_GRID_DRAWING_FEATURES_WIREFRAME),this.hasFlag(this.parentSeries.drawMeshAs,[f.EDrawMeshAs.SOLID_WIREFRAME,f.EDrawMeshAs.SOLID_MESH,f.EDrawMeshAs.SOLID_WITH_CONTOURS,f.EDrawMeshAs.SOLID_WIREFRAME_WITH_CONTOURS])&&(C|=g.SCRT_GRID_DRAWING_FEATURES_SOLID),this.hasFlag(this.parentSeries.drawMeshAs,[f.EDrawMeshAs.CONTOURS,f.EDrawMeshAs.SOLID_WITH_CONTOURS,f.EDrawMeshAs.SOLID_WIREFRAME_WITH_CONTOURS])&&(C|=g.SCRT_GRID_DRAWING_FEATURES_CONTOURS),this.parentSeries.drawSkirt&&(C|=g.SCRT_GRID_DRAWING_FEATURES_SKIRT);var P=this.hasFlag(this.parentSeries.meshPaletteMode,[f.EMeshPaletteMode.HEIGHT_MAP_INTERPOLATED,f.EMeshPaletteMode.HEIGHT_MAP_SOLID_CELLS]),x=this.hasFlag(this.parentSeries.meshPaletteMode,[f.EMeshPaletteMode.HEIGHT_MAP_SOLID_CELLS,f.EMeshPaletteMode.TEXTURED_SOLID_CELLS]);if(_.SetDrawMeshAsInteger(C),_.m_bUseGradient=P,_.m_bUseSolidCells=x,_.m_fStrokeThickness=this.parentSeries.strokeThickness,_.m_fContourThickness=this.parentSeries.contourStrokeThickness,_.m_fContourInterval=this.parentSeries.contourInterval,_.m_fContourOffset=this.parentSeries.contourOffset,_.m_bNormalsPS=!1,this.parentSeries.stroke){var E=(0,s.parseColorToTArgb)(this.parentSeries.stroke);(0,l.updateTsrVector4)(E,_.GetWireframeStrokePtr())}this.parentSeries.contourStroke&&(0,l.updateTsrVector4)((0,s.parseColorToTArgb)(this.parentSeries.contourStroke),_.GetContourColorPtr()),_.m_fHardNormals=this.parentSeries.cellHardnessFactor,_.m_fHighlight=this.parentSeries.highlight,_.m_fShininess=this.parentSeries.shininess,_.m_fLightingAmount=this.parentSeries.lightingFactor,this.nativeEntity.SetGridDrawingProperties(_)}finally{(0,e.deleteSafe)(_)}var A=this.currentRenderPassData.xCalc,R=this.currentRenderPassData.yCalc,M=this.currentRenderPassData.zCalc,D,F,I,V,z,G;try{var H=new n.NumberRange(this.parentSeries.minimum,this.parentSeries.maximum);D=this.rangeToSCRTAxisRange(this.webAssemblyContext,A,this.parentSeries.dataSeries.xRange),F=this.rangeToSCRTAxisRange(this.webAssemblyContext,R,H),I=this.rangeToSCRTAxisRange(this.webAssemblyContext,M,this.parentSeries.dataSeries.zRange),this.nativeEntity.SetMeshRange(D,F,I),V=this.toSCRTAxisRange(this.webAssemblyContext,A,A.visibleMin,A.visibleMax),z=this.toSCRTAxisRange(this.webAssemblyContext,R,R.visibleMin,R.visibleMax),G=this.toSCRTAxisRange(this.webAssemblyContext,M,M.visibleMin,M.visibleMax),this.nativeEntity.SetVisibleRange(V,z,G)}finally{(0,e.deleteSafe)(D),(0,e.deleteSafe)(F),(0,e.deleteSafe)(I),(0,e.deleteSafe)(V),(0,e.deleteSafe)(z),(0,e.deleteSafe)(G)}var U=this.parentSeries.yOffset?R.getCoordinate(this.parentSeries.yOffset):0;this.nativeEntity.SetHeightmapScaleOffset(this.parentSeries.heightScaleFactor,U),this.nativeEntity.SetTexture(this.colorMapTexture.getTexture()),b.prototype.Render.call(this)}},S.prototype.updateSeries=function(){var _,C=this.parentSeries.dataSeries;if(C){i.Guard.isTrue(C.type===u.EDataSeriesType3D.UniformGrid3D||C.type===u.EDataSeriesType3D.NonUniformGrid3D,"SurfaceMeshSceneEntity dataSeries must be type UniformGrid3D or NonUniformGrid3D");var P=C.xSize,x=C.zSize;i.Guard.notNull(this.currentRenderPassData,"SurfaceMeshSceneEntity.currentRenderPassData"),this.state.isColorMapTextureInvalid&&(this.colorMapTexture=(0,e.deleteSafe)(this.colorMapTexture),this.colorMapTexture=(_=this.parentSeries.meshColorPalette)===null||_===void 0?void 0:_.getTexture(this.parentSeries.colorMapTextureSize));var E=this.state.isInitialState,A=this.state.isDataSeriesModified;if(E){var R=void 0;switch(this.parentSeries.meshResolution){case f.EMeshResolution.MESH_RESOLUTION_X1:R=this.webAssemblyContext.eSCRTGridMeshResolution.SCRT_GRID_MESH_RES_X1;break;case f.EMeshResolution.MESH_RESOLUTION_X2:R=this.webAssemblyContext.eSCRTGridMeshResolution.SCRT_GRID_MESH_RES_X2;break;case f.EMeshResolution.MESH_RESOLUTION_X4:R=this.webAssemblyContext.eSCRTGridMeshResolution.SCRT_GRID_MESH_RES_X4;break;default:throw Error("Unknown SurfaceMeshSceneEntity.meshResolution "+this.parentSeries.meshResolution)}var M=P*x;this.heightCoords=this.getOrCreateVector(this.heightCoords,M,this.webAssemblyContext.SCRTFloatVector),this.zOffsets=this.getOrCreateVector(this.zOffsets,M,this.webAssemblyContext.SCRTFloatVector),this.cellColors=this.getOrCreateVector(this.cellColors,M,this.webAssemblyContext.SCRTUintVector),this.nativeEntity.UpdateMeshesVec(this.heightCoords,this.zOffsets,this.cellColors,P,x,R)}if(A){this.heightCoords=this.getOrCreateVector(this.heightCoords,P*x,this.webAssemblyContext.SCRTFloatVector);var D=this.currentRenderPassData.yCalc;this.updateHeightMap(C.getYValues(),D,C.xSize,C.zSize,this.heightCoords),this.nativeEntity.UpdateHeightCoordinatesVec(this.heightCoords,P,x)}}},S.prototype.updateHeightMap=function(_,C,P,x,E){this.sourceRowVec=this.getOrCreateVector(this.sourceRowVec,P,this.webAssemblyContext.SCRTDoubleVector);for(var A=0,R=0;A<x;A++)this.webAssemblyContext.HEAPF64.set(_[A],this.sourceRowVec.dataPtr(0)/a.SIZEOF_NUMBER),C.nativeCalculator.GetCoordinatesVec(this.sourceRowVec,E,0,R,P,0),R+=P},S.prototype.hasFlag=function(_,C){return C.some(function(P){return P===_})},S.prototype.toSCRTAxisRange=function(_,C,P,x){var E=new _.SCRTAxisRange;return E.m_fMin=C?C.getCoordinate(P):P,E.m_fMax=C?C.getCoordinate(x):x,E.m_fDiff=C?C.getCoordinate(x-P):x-P,E},S.prototype.rangeToSCRTAxisRange=function(_,C,P){return this.toSCRTAxisRange(_,C,P.min,P.max)},S})(h.RenderableSeriesSceneEntity);return Bb.SurfaceMeshSceneEntity=m,Bb}var nCe;function kL(){return nCe||(nCe=1,(function(t){var e=TB&&TB.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.SurfaceMeshRenderableSeries3D=t.EMeshResolution=t.EMeshPaletteMode=t.EDrawMeshAs=void 0;var i=mo(),n=ga(),r=Ig(),o=yJ(),a=oH(),s=Nm(),l=vR(),u;(function(h){h.WIREFRAME="WIREFRAME",h.SOLID_WIREFRAME="SOLID_WIREFRAME",h.SOLID_WIREFRAME_WITH_CONTOURS="SOLID_WIREFRAME_WITH_CONTOURS",h.SOLID_MESH="SOLID_MESH",h.SOLID_WITH_CONTOURS="SOLID_WITH_CONTOURS",h.CONTOURS="CONTOURS"})(u=t.EDrawMeshAs||(t.EDrawMeshAs={}));var c;(function(h){h.HEIGHT_MAP_INTERPOLATED="HEIGHT_MAP_INTERPOLATED",h.HEIGHT_MAP_SOLID_CELLS="HEIGHT_MAP_SOLID_CELLS",h.TEXTURED_SOLID_CELLS="TEXTURED_SOLID_CELLS"})(c=t.EMeshPaletteMode||(t.EMeshPaletteMode={}));var d;(function(h){h[h.MESH_RESOLUTION_X1=1]="MESH_RESOLUTION_X1",h[h.MESH_RESOLUTION_X2=2]="MESH_RESOLUTION_X2",h[h.MESH_RESOLUTION_X4=4]="MESH_RESOLUTION_X4"})(d=t.EMeshResolution||(t.EMeshResolution={}));var f=(function(h){e(p,h);function p(g,v){var y=h.call(this,g,v)||this;return y.drawMeshAsProperty=(v==null?void 0:v.drawMeshAs)||u.SOLID_WIREFRAME,y.strokeThicknessProperty=(v==null?void 0:v.strokeThickness)!==void 0?v==null?void 0:v.strokeThickness:1,y.drawSkirtProperty=(v==null?void 0:v.drawSkirt)!==void 0?v==null?void 0:v.drawSkirt:!0,y.minimumProperty=(v==null?void 0:v.minimum)!==void 0?v==null?void 0:v.minimum:0,y.maximumProperty=(v==null?void 0:v.maximum)!==void 0?v==null?void 0:v.maximum:1,y.meshPaletteModeProperty=(v==null?void 0:v.meshPaletteMode)||c.HEIGHT_MAP_INTERPOLATED,y.colorMapTextureSizeProperty=(v==null?void 0:v.colorMapTextureSize)||new r.Size(1024,1),y.heightScaleFactorProperty=(v==null?void 0:v.heightScaleFactor)!==void 0?v==null?void 0:v.heightScaleFactor:1,y.meshResolutionProperty=(v==null?void 0:v.meshResolution)||d.MESH_RESOLUTION_X1,y.yOffsetProperty=(v==null?void 0:v.yOffset)!==void 0?v==null?void 0:v.yOffset:0,y.cellHardnessFactorProperty=(v==null?void 0:v.cellHardnessFactor)!==void 0?v==null?void 0:v.cellHardnessFactor:1,y.lightingFactorProperty=(v==null?void 0:v.lightingFactor)!==void 0?v==null?void 0:v.lightingFactor:.8,y.contourStrokeThicknessProperty=(v==null?void 0:v.contourStrokeThickness)!==void 0?v==null?void 0:v.contourStrokeThickness:2,y.contourIntervalProperty=(v==null?void 0:v.contourInterval)!==void 0?v==null?void 0:v.contourInterval:20,y.contourOffsetProperty=(v==null?void 0:v.contourOffset)!==void 0?v.contourOffset:.1,y.contourStrokeProperty=(v==null?void 0:v.contourStroke)||"#FFFFFF",y.highlightProperty=(v==null?void 0:v.highlight)!==void 0?v==null?void 0:v.highlight:.05,v!=null&&v.meshColorPalette&&("getTexture"in v.meshColorPalette||(v.meshColorPalette=(0,i.createType)(n.EBaseType.PaletteProvider,v.meshColorPalette.type,g,v.meshColorPalette.options))),y.meshColorPaletteProperty=v==null?void 0:v.meshColorPalette,y.setSceneEntity(new o.SurfaceMeshSceneEntity(g,y)),y}return Object.defineProperty(p.prototype,"type",{get:function(){return l.ESeriesType3D.SurfaceMeshRenderableSeries3D},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"colorMapTextureSize",{get:function(){return this.colorMapTextureSizeProperty},set:function(g){this.colorMapTextureSizeProperty=g,this.notifyPropertyChanged(s.PROPERTY.COLOR_MAP_TEXTURE_SIZE)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"drawMeshAs",{get:function(){return this.drawMeshAsProperty},set:function(g){this.drawMeshAsProperty=g,this.notifyPropertyChanged(s.PROPERTY.DRAW_MESH_AS)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"strokeThickness",{get:function(){return this.strokeThicknessProperty},set:function(g){this.strokeThicknessProperty=g,this.notifyPropertyChanged(s.PROPERTY.STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"drawSkirt",{get:function(){return this.drawSkirtProperty},set:function(g){this.drawSkirtProperty=g,this.notifyPropertyChanged(s.PROPERTY.DRAW_SKIRT)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"meshColorPalette",{get:function(){return this.meshColorPaletteProperty},set:function(g){this.meshColorPaletteProperty=g,this.notifyPropertyChanged(s.PROPERTY.MESH_COLOR_PALETTE)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"minimum",{get:function(){return this.minimumProperty},set:function(g){this.minimumProperty=g,this.notifyPropertyChanged(s.PROPERTY.MINIMUM)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"maximum",{get:function(){return this.maximumProperty},set:function(g){this.maximumProperty=g,this.notifyPropertyChanged(s.PROPERTY.MAXIMUM)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"meshPaletteMode",{get:function(){return this.meshPaletteModeProperty},set:function(g){this.meshPaletteModeProperty=g,this.notifyPropertyChanged(s.PROPERTY.MESH_PALETTE_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"heightScaleFactor",{get:function(){return this.heightScaleFactorProperty},set:function(g){this.heightScaleFactorProperty=g,this.notifyPropertyChanged(s.PROPERTY.HEIGHT_SCALE_FACTOR)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"meshResolution",{get:function(){return this.meshResolutionProperty},set:function(g){this.meshResolutionProperty=g,this.notifyPropertyChanged(s.PROPERTY.MESH_RESOLUTION)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"yOffset",{get:function(){return this.yOffsetProperty},set:function(g){this.yOffsetProperty=g,this.notifyPropertyChanged(s.PROPERTY.Y_OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"cellHardnessFactor",{get:function(){return this.cellHardnessFactorProperty},set:function(g){this.cellHardnessFactorProperty=g,this.notifyPropertyChanged(s.PROPERTY.CELL_HARDNESS_FACTOR)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"lightingFactor",{get:function(){return this.lightingFactorProperty},set:function(g){this.lightingFactorProperty=g,this.notifyPropertyChanged(s.PROPERTY.LIGHTING_FACTOR)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"contourStrokeThickness",{get:function(){return this.contourStrokeThicknessProperty},set:function(g){this.contourStrokeThicknessProperty=g,this.notifyPropertyChanged(s.PROPERTY.CONTOUR_STROKE_THICKNESS)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"contourInterval",{get:function(){return this.contourIntervalProperty},set:function(g){this.contourIntervalProperty=g,this.notifyPropertyChanged(s.PROPERTY.CONTOUR_INTERVAL)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"contourOffset",{get:function(){return this.contourOffsetProperty},set:function(g){this.contourOffsetProperty=g,this.notifyPropertyChanged(s.PROPERTY.CONTOUR_OFFSET)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"contourStroke",{get:function(){return this.contourStrokeProperty},set:function(g){this.contourStrokeProperty=g,this.notifyPropertyChanged(s.PROPERTY.CONTOUR_STROKE)},enumerable:!1,configurable:!0}),Object.defineProperty(p.prototype,"highlight",{get:function(){return this.highlightProperty},set:function(g){this.highlightProperty=g,this.notifyPropertyChanged(s.PROPERTY.HIGHLIGHT)},enumerable:!1,configurable:!0}),p.prototype.getOptions=function(){var g=h.prototype.getOptions.call(this),v={colorMapTextureSize:this.colorMapTextureSize,meshResolution:this.meshResolution,strokeThickness:this.strokeThickness,contourStrokeThickness:this.contourStrokeThickness,meshPaletteMode:this.meshPaletteMode,heightScaleFactor:this.heightScaleFactor,contourStroke:this.contourStroke,drawMeshAs:this.drawMeshAs,drawSkirt:this.drawSkirt,meshColorPalette:this.meshColorPalette,minimum:this.minimum,maximum:this.maximum,yOffset:this.yOffset,cellHardnessFactor:this.cellHardnessFactor,lightingFactor:this.lightingFactor,contourInterval:this.contourInterval,contourOffset:this.contourOffset,highlight:this.highlight};return Object.assign(g,v)},p})(a.BaseRenderableSeries3D);t.SurfaceMeshRenderableSeries3D=f})(TB)),TB}var NA={},xB={},oCe;function rne(){if(oCe)return xB;oCe=1,Object.defineProperty(xB,"__esModule",{value:!0}),xB.MeshColorPalette=void 0;var t=ps(),e=KP(),i=(function(){function n(r){this.webAssemblyContext=r,this.propertyChanged=new t.EventHandler}return n.prototype.notifyPropertyChanged=function(r){var o;(o=this.propertyChanged)===null||o===void 0||o.raiseEvent(new e.PropertyChangedEventArgs(r))},n.prototype.toJSON=function(){return{type:this.type,options:this.getOptions()}},n})();return xB.MeshColorPalette=i,xB}var aCe;function iVe(){if(aCe)return NA;aCe=1;var t=NA&&NA.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(NA,"__esModule",{value:!0}),NA.GradientColorPalette=void 0;var e=rR(),i=Uo(),n=ci(),r=JD(),o=Nm(),a=rne(),s=(function(l){t(u,l);function u(c,d){var f=l.call(this,c)||this;return f.type=r.EPaletteProviderType.Gradient3D,f.gradientStops=(d==null?void 0:d.gradientStops)||[{offset:0,color:"Red"},{offset:1,color:"Green"}],f}return Object.defineProperty(u.prototype,"gradientStops",{get:function(){return this.gradientStopsProperty},set:function(c){this.gradientStopsProperty=c,this.notifyPropertyChanged(o.PROPERTY.GRADIENT_STOPS)},enumerable:!1,configurable:!0}),u.prototype.getTexture=function(c){if(!i.IS_TEST_ENV){n.Guard.notNull(c,"size"),n.Guard.isTrue(c.width>0,"size.width must be greater than 0"),n.Guard.isTrue(c.height>0,"size.height must be greater than 0"),n.Guard.notNull(this.gradientStopsProperty,"GradientColorPalette.gradientStops");var d=new e.CanvasTexture(this.webAssemblyContext,c.width,c.height);d.clear();var f=d.getContext(),h=0,p=0,g=c.width,v=0,y=f.createLinearGradient(h,p,g,v);return this.gradientStops.forEach(function(m){y.addColorStop(m.offset,m.color)}),f.fillStyle=y,f.fillRect(0,0,c.width,c.height),d.copyTexture(),d}},u.prototype.getOptions=function(){return{gradientStops:this.gradientStops}},u})(a.MeshColorPalette);return NA.GradientColorPalette=s,NA}var FA={},sCe;function nVe(){if(sCe)return FA;sCe=1;var t=FA&&FA.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})();Object.defineProperty(FA,"__esModule",{value:!0}),FA.SolidColorBrushPalette=void 0;var e=rR(),i=Uo(),n=ci(),r=JD(),o=Ti(),a=Nm(),s=rne(),l=(function(u){t(c,u);function c(d,f){var h=u.call(this,d)||this;return h.type=r.EPaletteProviderType.Solid3D,h.fillProperty=(f==null?void 0:f.fill)||"#777777",h}return Object.defineProperty(c.prototype,"fill",{get:function(){return this.fillProperty},set:function(d){this.fillProperty=d,this.notifyPropertyChanged(a.PROPERTY.FILL)},enumerable:!1,configurable:!0}),c.prototype.getTexture=function(d){if(n.Guard.notNull(d,"size"),n.Guard.isTrue(d.width>0,"size.width must be greater than 0"),n.Guard.isTrue(d.height>0,"size.height must be greater than 0"),!i.IS_TEST_ENV){var f=(0,o.parseColorToUIntArgb)(this.fill);if(isNaN(f))throw Error("SolidColorBrushPalette.fill ".concat(this.fill," cannot be converted to an ABGR color"));var h=new e.CanvasTexture(this.webAssemblyContext,d.width,d.height);h.clear();var p=h.getContext();return p.fillStyle=this.fill,p.fillRect(0,0,d.width,d.height),h.copyTexture(),h}},c.prototype.getOptions=function(){return{fill:this.fill}},c})(s.MeshColorPalette);return FA.SolidColorBrushPalette=l,FA}var BA={},lCe;function ine(){if(lCe)return BA;lCe=1;var t=BA&&BA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(BA,"__esModule",{value:!0}),BA.PolarTextDataLabelProvider=void 0;var e=Ac(),i=ZW(),n=HW(),r=(function(o){t(a,o);function a(){var s=o!==null&&o.apply(this,arguments)||this;return s.type=e.EDataLabelProviderType.PolarText,s}return a.prototype.getDataLabelState=function(s,l,u,c,d,f){return new i.PolarDataLabelState(s,l,u,c,d,f)},a})(n.TextDataLabelProvider);return BA.PolarTextDataLabelProvider=r,BA}var jb={},jA={},uCe;function oVe(){if(uCe)return jA;uCe=1;var t=jA&&jA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(jA,"__esModule",{value:!0}),jA.PolarTriangleSeriesDrawingProvider=void 0;var e=Qie(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r.prototype.updateArgs=function(o){var a=this.parentSeries.xAxis;if(a.isAngular)return this.args.SetCoordinateTransform(a.getTransform());var s=this.parentSeries.yAxis;return this.args.SetCoordinateTransform(s.getTransform())},r})(e.TriangleSeriesDrawingProvider);return jA.PolarTriangleSeriesDrawingProvider=i,jA}var cCe;function aVe(){if(cCe)return jb;cCe=1;var t=jb&&jb.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})(),e=jb&&jb.__assign||function(){return e=Object.assign||function(u){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(u[h]=c[h])}return u},e.apply(this,arguments)};Object.defineProperty(jb,"__esModule",{value:!0}),jb.PolarTriangleRenderableSeries=void 0;var i=hn(),n=ene(),r=pR(),o=nC(),a=oVe(),s=gR(),l=(function(u){t(c,u);function c(d,f){var h=this,p;return h=u.call(this,d,e({dataLabelProvider:(p=f.dataLabelProvider)!==null&&p!==void 0?p:new r.PolarDataLabelProvider(f==null?void 0:f.dataLabels)},f))||this,h.isPolar=!0,h.type=i.ESeriesType.PolarTriangleSeries,h}return c.prototype.addDrawingProviders=function(d,f){this.drawingProviders.push(new a.PolarTriangleSeriesDrawingProvider(d,this)),this.drawingProviders.push(new o.PolarPointMarkerDrawingProvider(d,this))},c.prototype.newHitTestProvider=function(){return new s.PolarDataPointHitTestProvider(this,this.webAssemblyContext)},c})(n.FastTriangleRenderableSeries);return jb.PolarTriangleRenderableSeries=l,jb}var Vb={},dCe;function sVe(){if(dCe)return Vb;dCe=1;var t=Vb&&Vb.__extends||(function(){var u=function(c,d){return u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(f,h){f.__proto__=h}||function(f,h){for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(f[p]=h[p])},u(c,d)};return function(c,d){if(typeof d!="function"&&d!==null)throw new TypeError("Class extends value "+String(d)+" is not a constructor or null");u(c,d);function f(){this.constructor=c}c.prototype=d===null?Object.create(d):(f.prototype=d.prototype,new f)}})(),e=Vb&&Vb.__assign||function(){return e=Object.assign||function(u){for(var c,d=1,f=arguments.length;d<f;d++){c=arguments[d];for(var h in c)Object.prototype.hasOwnProperty.call(c,h)&&(u[h]=c[h])}return u},e.apply(this,arguments)};Object.defineProperty(Vb,"__esModule",{value:!0}),Vb.PolarTextRenderableSeries=void 0;var i=hn(),n=Om(),r=Uie(),o=ine(),a=nC(),s=gR(),l=(function(u){t(c,u);function c(d,f){var h=this,p;return h=u.call(this,d,e(e({},f),{dataLabelProvider:(p=f.dataLabelProvider)!==null&&p!==void 0?p:new o.PolarTextDataLabelProvider(f==null?void 0:f.dataLabels)}))||this,h.isPolar=!0,h.type=i.ESeriesType.PolarTextSeries,h}return c.prototype.addDrawingProviders=function(d,f){this.drawingProviders.push(new a.PolarPointMarkerDrawingProvider(d,this))},c.prototype.needsResampling=function(d){return this.dataSeries.fifoCapacity?(d.resamplingMode=n.EResamplingMode.None,this.resamplerHelper.resetAndFillBasicNativeArgs(d,this.getNativeXValues()),!0):!1},c.prototype.newHitTestProvider=function(){return new s.PolarDataPointHitTestProvider(this,this.webAssemblyContext)},c})(r.FastTextRenderableSeries);return Vb.PolarTextRenderableSeries=l,Vb}var fCe;function K3(){return fCe||(fCe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.buildSeries3D=t.buildSeries=void 0;var e=Tje(),i=zi(),n=XV(),r=Cre(),o=Mre(),a=MI(),s=kre(),l=Ire(),u=Nre(),c=Fre(),d=xje(),f=Eje(),h=wje(),p=Aje(),g=kie(),v=Iie(),y=iI(),m=Nie(),b=Wv(),S=tH(),_=fR(),C=Fie(),P=HW(),x=Dje(),E=kje(),A=Fje(),R=q3(),M=zje(),D=Wje(),F=Yje(),I=Kje(),V=Zje(),z=Uie(),G=Qje(),H=r3e(),U=i3e(),k=a3e(),X=s3e(),W=l3e(),Y=f3e(),te=Ure(),oe=g3e(),de=xW(),ge=qW(),Ee=vJ(),Re=XW(),Ae=Yie(),Pe=Gf(),we=ga(),Te=Ac(),ke=JD(),$e=Ng(),Ne=hn(),ve=WW(),pe=G3(),fe=Tv(),me=mo(),Ce=S3e(),Ue=Xie(),Qe=x3e(),it=w3e(),xt=O3e(),wt=R3e(),$t=M3e(),Mt=N3e(),rt=ene(),qe=j3e(),vt=pR(),kt=Jie(),Xe=V3e(),_t=H3e(),Ht=U3e(),Pt=W3e(),Jt=vR(),zt=J3e(),Bt=eVe(),Mr=rVe(),Be=kL(),We=Uf(),dt=tne(),Tt=Ry(),nr=qie(),Ar=iVe(),Qr=nVe(),Si=ine(),oi=aVe(),Yr=sVe();(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.Cross,function(mt,gr){return new o.CrossPointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.Ellipse,function(mt,gr){return new a.EllipsePointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.Sprite,function(mt,gr){return new s.SpritePointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.Square,function(mt,gr){return new l.SquarePointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.Triangle,function(mt,gr){return new u.TrianglePointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker,$e.EPointMarkerType.X,function(mt,gr){return new c.XPointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.ShaderEffect,ve.EShaderEffectType.Glow,function(mt,gr){return new G.GlowEffect(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.ShaderEffect,ve.EShaderEffectType.Shadow,function(mt,gr){return new U.ShadowEffect(mt,gr)},!0),(0,me.registerType)(we.EBaseType.Animation,Pe.EAnimationType.Fade,function(mt){return new d.FadeAnimation(mt)},!0),(0,me.registerType)(we.EBaseType.Animation,Pe.EAnimationType.Scale,function(mt){return new f.ScaleAnimation(mt)},!0),(0,me.registerType)(we.EBaseType.Animation,Pe.EAnimationType.Sweep,function(mt){return new h.SweepAnimation(mt)},!0),(0,me.registerType)(we.EBaseType.Animation,Pe.EAnimationType.Wave,function(mt){return new p.WaveAnimation(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Default,function(mt){return new b.DataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Line,function(mt){return new _.LineSeriesDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Column,function(mt){return new y.ColumnSeriesDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Rectangle,function(mt){return new nr.RectangleSeriesDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Text,function(mt){return new P.TextDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Heatmap,function(mt){return new S.HeatMapDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.NonUniformHeatmap,function(mt){return new C.NonUniformHeatMapDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Bubble,function(mt){return new v.BubbleSeriesDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Band,function(mt){return new g.BandSeriesDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.Contours,function(mt){return new m.ContoursDataLabelProvider(mt)},!0),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.PolarDefault,function(mt){return new vt.PolarDataLabelProvider(mt)}),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.PolarColumn,function(mt){return new kt.PolarColumnSeriesDataLabelProvider(mt)}),(0,me.registerType)(we.EBaseType.DataLabelProvider,Te.EDataLabelProviderType.PolarText,function(mt){return new Si.PolarTextDataLabelProvider(mt)}),(0,me.registerType)(we.EBaseType.MetadataGenerator,"Template",function(mt){return new n.TemplateMetadataGenerator(mt)},!0),(0,me.registerWasmType)(we.EBaseType.PaletteProvider,ke.EPaletteProviderType.Gradient,function(mt,gr){return r.PaletteFactory.createGradient(mt,gr)},!0),(0,me.registerType)(we.EBaseType.PaletteProvider,ke.EPaletteProviderType.DataPointSelection,function(mt){return new e.DataPointSelectionPaletteProvider(mt)},!0);function vi(mt,gr){return mt.hasOwnProperty(gr)}var rr=function(mt){return vi(mt,"xyData")?{type:i.EDataSeriesType.Xy,options:mt.xyData}:vi(mt,"xyyData")?{type:i.EDataSeriesType.Xyy,options:mt.xyyData}:vi(mt,"xyzData")?{type:i.EDataSeriesType.Xyz,options:mt.xyzData}:vi(mt,"xyxyData")?{type:i.EDataSeriesType.Xyxy,options:mt.xyxyData}:vi(mt,"xyxData")?{type:i.EDataSeriesType.Xyx,options:mt.xyxData}:vi(mt,"xynData")?{type:i.EDataSeriesType.XyN,options:mt.xynData}:vi(mt,"xyTextData")?{type:i.EDataSeriesType.XyText,options:mt.xyTextData}:vi(mt,"hlcData")?{type:i.EDataSeriesType.Hlc,options:mt.hlcData}:vi(mt,"ohlcData")?{type:i.EDataSeriesType.Ohlc,options:mt.ohlcData}:vi(mt,"boxPlotData")?{type:i.EDataSeriesType.BoxPlot,options:mt.boxPlotData}:vi(mt,"heatmapData")&&(mt.type===Ne.ESeriesType.UniformHeatmapSeries||mt.type===Ne.ESeriesType.UniformContoursSeries||mt.type===Ne.ESeriesType.PolarUniformHeatmapSeries)?{type:i.EDataSeriesType.HeatmapUniform,options:mt.heatmapData}:vi(mt,"heatmapData")&&mt.type===Ne.ESeriesType.NonUniformHeatmapSeries?{type:i.EDataSeriesType.HeatmapNonUniform,options:mt.heatmapData}:void 0},Ji=function(mt,gr,ce){typeof gr=="string"&&(gr=JSON.parse(gr,fe.chartReviver)),typeof ce=="string"&&(ce=JSON.parse(ce,fe.chartReviver));var fr=[];Array.isArray(gr)||(gr=[gr]);for(var Yt=0,Lr=gr;Yt<Lr.length;Yt++){var Cr=Lr[Yt],zr=void 0;if(Cr.type===Ne.ESeriesType.BandSeries)zr=new x.FastBandRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.BubbleSeries)zr=new E.FastBubbleRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.CandlestickSeries)zr=new A.FastCandlestickRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.ColumnSeries)zr=new R.FastColumnRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.ImpulseSeries)zr=new D.FastImpulseRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.LineSeries)zr=new F.FastLineRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.LineSegmentSeries)zr=new Ce.FastLineSegmentRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.MountainSeries)zr=new I.FastMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.ErrorBarsSeries)zr=new M.FastErrorBarsRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.BoxPlotSeries)zr=new Mt.FastBoxPlotRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.TriangleSeries)zr=new rt.FastTriangleRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.RectangleSeries)zr=new Ue.FastRectangleRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.OhlcSeries)zr=new V.FastOhlcRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.ScatterSeries)zr=new Ae.XyScatterRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.SplineBandSeries)zr=new k.SplineBandRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.SplineLineSeries)zr=new X.SplineLineRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.SplineMountainSeries)zr=new W.SplineMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.UniformHeatmapSeries)zr=new Re.UniformHeatmapRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.NonUniformHeatmapSeries)zr=new H.NonUniformHeatmapRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.UniformContoursSeries)zr=new Ee.UniformContoursRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.TextSeries)zr=new z.FastTextRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.StackedColumnSeries)zr=new oe.StackedColumnRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.StackedMountainSeries)zr=new ge.StackedMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.SmoothStackedMountainSeries)zr=new Y.SmoothStackedMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.StackedColumnCollection){var fi=new te.StackedColumnCollection(mt,Cr.options);fi.add.apply(fi,(0,t.buildSeries)(mt,Cr.series,ce)),zr=fi}else if(Cr.type===Ne.ESeriesType.StackedMountainCollection){var fi=new de.StackedMountainCollection(mt,Cr.options);fi.add.apply(fi,(0,t.buildSeries)(mt,Cr.series,ce)),zr=fi}else if(Cr.type===Ne.ESeriesType.PolarLineSeries)zr=new Qe.PolarLineRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarScatterSeries)zr=new qe.PolarXyScatterRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarBandSeries)zr=new it.PolarBandRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarColumnSeries)zr=new xt.PolarColumnRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarMountainSeries)zr=new wt.PolarMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarTriangleSeries)zr=new oi.PolarTriangleRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarTextSeries)zr=new Yr.PolarTextRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarUniformHeatmapSeries)zr=new Pt.PolarUniformHeatmapRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarStackedMountainSeries)zr=new $t.PolarStackedMountainRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarStackedColumnSeries)zr=new Ht.PolarStackedColumnRenderableSeries(mt,Cr.options);else if(Cr.type===Ne.ESeriesType.PolarStackedMountainCollection){var fi=new Xe.PolarStackedMountainCollection(mt,Cr.options);fi.add.apply(fi,(0,t.buildSeries)(mt,Cr.series,ce)),zr=fi}else if(Cr.type===Ne.ESeriesType.PolarStackedColumnCollection){var fi=new _t.PolarStackedColumnCollection(mt,Cr.options);fi.add.apply(fi,(0,t.buildSeries)(mt,Cr.series,ce)),zr=fi}if(zr){var to=qn(mt,Cr,ce);to&&(zr.dataSeries=to)}zr&&fr.push(zr)}return fr};t.buildSeries=Ji;var qn=function(mt,gr,ce){var fr=rr(gr);if(fr)return gr.options&&"dataSeries"in gr.options&&gr.options.dataSeries&&fr.options&&"filter"in fr.options&&fr.options.filter?(0,pe.buildDataSeries)(mt,fr,ce,gr.options.dataSeries):(0,pe.buildDataSeries)(mt,fr,ce)};(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Sphere,function(mt,gr){return new Tt.SpherePointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Cube,function(mt,gr){return new Tt.CubePointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Pyramid,function(mt,gr){return new Tt.PyramidPointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Cylinder,function(mt,gr){return new Tt.CylinderPointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Ellipse,function(mt,gr){return new Tt.EllipsePointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Pixel,function(mt,gr){return new Tt.PixelPointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Quad,function(mt,gr){return new Tt.QuadPointMarker(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PointMarker3D,dt.EPointMarker3DType.Triangle,function(mt,gr){return new Tt.TrianglePointMarker3D(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PaletteProvider,ke.EPaletteProviderType.Gradient3D,function(mt,gr){return new Ar.GradientColorPalette(mt,gr)},!0),(0,me.registerWasmType)(we.EBaseType.PaletteProvider,ke.EPaletteProviderType.Solid3D,function(mt,gr){return new Qr.SolidColorBrushPalette(mt,gr)},!0);var ri=function(mt,gr,ce){typeof gr=="string"&&(gr=JSON.parse(gr,fe.chartReviver)),typeof ce=="string"&&(ce=JSON.parse(ce,fe.chartReviver));var fr=[];Array.isArray(gr)||(gr=[gr]);for(var Yt=0,Lr=gr;Yt<Lr.length;Yt++){var Cr=Lr[Yt],zr=void 0;switch(Cr.type){case Jt.ESeriesType3D.ColumnRenderableSeries3D:zr=new zt.ColumnRenderableSeries3D(mt,Cr.options);break;case Jt.ESeriesType3D.PointLineRenderableSeries3D:zr=new Bt.PointLineRenderableSeries3D(mt,Cr.options);break;case Jt.ESeriesType3D.ScatterRenderableSeries3D:zr=new Mr.ScatterRenderableSeries3D(mt,Cr.options);break;case Jt.ESeriesType3D.SurfaceMeshRenderableSeries3D:zr=new Be.SurfaceMeshRenderableSeries3D(mt,Cr.options);break}if(zr){var fi=eo(mt,Cr,ce);fi&&(zr.dataSeries=fi)}zr&&fr.push(zr)}return fr};t.buildSeries3D=ri;var eo=function(mt,gr,ce){var fr=xn(gr);if(fr)return(0,pe.buildDataSeries3D)(mt,fr,ce)},xn=function(mt){return vi(mt,"xyzData")?{type:We.EDataSeriesType3D.Xyz3D,options:mt.xyzData}:vi(mt,"uniformGridData")?{type:We.EDataSeriesType3D.UniformGrid3D,options:mt.uniformGridData}:void 0}})(i7)),i7}var dl={},VA={},hCe;function lVe(){if(hCe)return VA;hCe=1;var t=VA&&VA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(VA,"__esModule",{value:!0}),VA.BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy=void 0;var e=Rn(),i=$d(),n=fs(),r=gW(),o=(function(a){t(s,a);function s(){var l=a!==null&&a.apply(this,arguments)||this;return l.type=i.ELayoutStrategyType.BottomStacked,l.isStacked=!0,l}return s.prototype.measureAxes=function(l,u,c){var d=this,f,h=0;c.forEach(function(b){b.measure(),d.updateAxisLayoutState(b);var S=(0,n.getHorizontalAxisRequiredSize)(b.axisLayoutState);h=S>h?S:h});var p=c[0],g=c[c.length-1];this.updateLeftAndRightChartLayoutState(u,p==null?void 0:p.axisLayoutState.additionalLeftSize,g==null?void 0:g.axisLayoutState.additionalRightSize);var v=l.bottomViewportBorder,y=l.bottomCanvasBorder,m=l.adjustedPadding;return h+=v+y+((f=m==null?void 0:m.bottom)!==null&&f!==void 0?f:0),h},s.prototype.layoutAxes=function(l,u,c,d,f){var h=this,p=c-l,g=f[0],v=f[f.length-1],y=f.filter(function(P){return P.stackedAxisLength}),m=f.reduce(function(P,x){return P-x.axisLayoutState.additionalBottomSize-x.axisLayoutState.additionalTopSize},p+(g==null?void 0:g.axisLayoutState.additionalLeftSize)+(v==null?void 0:v.axisLayoutState.additionalRightSize)),b=y.reduce(function(P,x){return P+h.calculateTotalAxisWidth(x,m)},0),S=p+(g==null?void 0:g.axisLayoutState.additionalLeftSize)+(v==null?void 0:v.axisLayoutState.additionalRightSize)-b;if(S<0)throw new Error("Bottom stacked axes with defined size total ".concat(b," pixels which is ").concat(-S," more than the space available"));var _=S/(f.length-y.length),C=l-(g==null?void 0:g.axisLayoutState.additionalLeftSize);f.forEach(function(P){var x=P.axisLayoutState,E=x.axisSize,A=x.additionalLeftSize,R=x.additionalRightSize,M=x.additionalTopSize,D=u+M,F=D+E,I=P.stackedAxisLength?h.calculateTotalAxisWidth(P,m):_,V=C+I-R;C+=A,P.offset=C-l,P.axisLength=V-C,P.isPrimaryAxis=!0,P.viewRect=e.Rect.createWithCoords(C,D,V,F),C=V+R,(0,n.layoutAxisParts)(P,h.layoutAxisPartsStrategy)})},s})(r.BottomAlignedOuterAxisLayoutStrategy);return VA.BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy=o,VA}var HA={},pCe;function uVe(){if(pCe)return HA;pCe=1;var t=HA&&HA.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(HA,"__esModule",{value:!0}),HA.CentralAxesLayoutManager=void 0;var e=od(),i=zS(),n=pW(),r=hFe(),o=hW(),a=JP(),s=vW(),l=mW(),u=SW(),c=(function(d){t(f,d);function f(h){var p=this,g,v,y,m;return p=d.call(this,h)||this,p.type=i.ELayoutManagerType.CentralAxes,p.horizontalAxisPositionCoordinateModeProperty=o.EInnerAxisPlacementCoordinateMode.Relative,p.verticalAxisPositionCoordinateModeProperty=o.EInnerAxisPlacementCoordinateMode.Relative,p.horizontalAxisPositionProperty=.5,p.verticalAxisPositionProperty=.5,p.verticalAxisPositionProperty=(g=h==null?void 0:h.verticalAxisPosition)!==null&&g!==void 0?g:p.verticalAxisPositionProperty,p.verticalAxisPositionCoordinateModeProperty=(v=h==null?void 0:h.verticalAxisPositionCoordinateMode)!==null&&v!==void 0?v:p.verticalAxisPositionCoordinateModeProperty,p.horizontalAxisPositionProperty=(y=h==null?void 0:h.horizontalAxisPosition)!==null&&y!==void 0?y:p.horizontalAxisPositionProperty,p.horizontalAxisPositionCoordinateModeProperty=(m=h==null?void 0:h.horizontalAxisPositionCoordinateMode)!==null&&m!==void 0?m:p.horizontalAxisPositionCoordinateModeProperty,p.leftInnerAxesLayoutStrategy=new s.LeftAlignedInnerAxisLayoutStrategy({axisPosition:p.verticalAxisPositionProperty,coordinateMode:p.verticalAxisPositionCoordinateModeProperty}),p.rightInnerAxesLayoutStrategy=new l.RightAlignedInnerAxisLayoutStrategy({axisPosition:p.verticalAxisPositionProperty,coordinateMode:p.verticalAxisPositionCoordinateModeProperty}),p.topInnerAxesLayoutStrategy=new u.TopAlignedInnerAxisLayoutStrategy({axisPosition:p.horizontalAxisPositionProperty,coordinateMode:p.horizontalAxisPositionCoordinateModeProperty}),p.bottomInnerAxesLayoutStrategy=new n.BottomAlignedInnerAxisLayoutStrategy({axisPosition:p.horizontalAxisPositionProperty,coordinateMode:p.horizontalAxisPositionCoordinateModeProperty}),p}return Object.defineProperty(f.prototype,"horizontalAxisPositionCoordinateMode",{get:function(){return this.horizontalAxisPositionCoordinateModeProperty},set:function(h){this.horizontalAxisPositionCoordinateModeProperty=h,this.topInnerAxesLayoutStrategy.coordinateMode=h,this.bottomInnerAxesLayoutStrategy.coordinateMode=h,this.notifyPropertyChanged(r.PROPERTY.COORDINATE_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"verticalAxisPositionCoordinateMode",{get:function(){return this.verticalAxisPositionCoordinateModeProperty},set:function(h){this.verticalAxisPositionCoordinateModeProperty=h,this.rightInnerAxesLayoutStrategy.coordinateMode=h,this.leftInnerAxesLayoutStrategy.coordinateMode=h,this.notifyPropertyChanged(r.PROPERTY.COORDINATE_MODE)},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"horizontalAxisPosition",{get:function(){return this.horizontalAxisPositionProperty},set:function(h){this.horizontalAxisPositionProperty=h,this.topInnerAxesLayoutStrategy.axisPosition=h,this.bottomInnerAxesLayoutStrategy.axisPosition=h,this.notifyPropertyChanged(r.PROPERTY.AXIS_POSITION_COORDINATE)},enumerable:!1,configurable:!0}),Object.defineProperty(f.prototype,"verticalAxisPosition",{get:function(){return this.verticalAxisPositionProperty},set:function(h){this.verticalAxisPositionProperty=h,this.rightInnerAxesLayoutStrategy.axisPosition=h,this.leftInnerAxesLayoutStrategy.axisPosition=h,this.notifyPropertyChanged(r.PROPERTY.AXIS_POSITION_COORDINATE)},enumerable:!1,configurable:!0}),f.prototype.toJSON=function(){var h=d.prototype.toJSON.call(this),p={horizontalAxisPosition:this.horizontalAxisPosition,horizontalAxisPositionCoordinateMode:this.horizontalAxisPositionCoordinateMode,verticalAxisPosition:this.verticalAxisPosition,verticalAxisPositionCoordinateMode:this.verticalAxisPositionCoordinateMode};return Object.assign(h,p),h},f.prototype.notifyPropertyChanged=function(h){var p;!((p=this.sciChartSurface)===null||p===void 0)&&p.invalidateElement&&this.sciChartSurface.invalidateElement()},f.prototype.groupAxesByLayoutStrategy=function(){this.axesGroupedByLayoutStrategy.clear();var h=this.axesGroupedByLayoutStrategy,p=h.topInnerAxes,g=h.bottomInnerAxes,v=h.leftInnerAxes,y=h.rightInnerAxes,m=function(b){b.forEach(function(S){var _=S.axisAlignment;switch(S.isInnerAxis=!0,_){case e.EAxisAlignment.Top:p.push(S);break;case e.EAxisAlignment.Bottom:g.push(S);break;case e.EAxisAlignment.Left:v.push(S);break;case e.EAxisAlignment.Right:y.push(S);break}})};m(this.sciChartSurface.xAxes.asArray()),m(this.sciChartSurface.yAxes.asArray())},f})(a.LayoutManager);return HA.CentralAxesLayoutManager=c,HA}var UA={},gCe;function cVe(){if(gCe)return UA;gCe=1;var t=UA&&UA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(UA,"__esModule",{value:!0}),UA.LeftAlignedOuterVerticallyStackedAxisLayoutStrategy=void 0;var e=Rn(),i=$d(),n=fs(),r=yW(),o=(function(a){t(s,a);function s(){var l=a!==null&&a.apply(this,arguments)||this;return l.type=i.ELayoutStrategyType.LeftStacked,l.isStacked=!0,l}return s.prototype.measureAxes=function(l,u,c){var d=this,f,h=0;c.forEach(function(b){b.measure(),d.updateAxisLayoutState(b);var S=(0,n.getVerticalAxisRequiredSize)(b.axisLayoutState);h=S>h?S:h});var p=c[0],g=c[c.length-1];this.updateTopAndBottomChartLayoutState(u,p==null?void 0:p.axisLayoutState.additionalTopSize,g==null?void 0:g.axisLayoutState.additionalBottomSize);var v=l.leftViewportBorder,y=l.leftCanvasBorder,m=l.adjustedPadding;return h+=v+y+((f=m==null?void 0:m.left)!==null&&f!==void 0?f:0),h},s.prototype.layoutAxes=function(l,u,c,d,f){var h=this,p=d-u,g=f[0],v=f[f.length-1],y=f.filter(function(P){return P.stackedAxisLength!==void 0}),m=f.reduce(function(P,x){return P-x.axisLayoutState.additionalBottomSize-x.axisLayoutState.additionalTopSize},p+(g==null?void 0:g.axisLayoutState.additionalTopSize)+(v==null?void 0:v.axisLayoutState.additionalBottomSize)),b=y.reduce(function(P,x){return P+h.calculateTotalAxisHeight(x,m)},0),S=p+(g==null?void 0:g.axisLayoutState.additionalTopSize)+(v==null?void 0:v.axisLayoutState.additionalBottomSize)-b;if(S<0)throw new Error("Left stacked axes with defined size total ".concat(b," pixels which is ").concat(-S," more than the space available"));var _=S/(f.length-y.length),C=u-(g==null?void 0:g.axisLayoutState.additionalTopSize);f.forEach(function(P){var x=P.axisLayoutState,E=x.axisSize,A=x.additionalRightSize,R=x.additionalBottomSize,M=x.additionalTopSize,D=c-A,F=D-E,I=P.stackedAxisLength!==void 0?h.calculateTotalAxisHeight(P,m):_,V=C+I-R;C+=M,P.offset=C-u,P.axisLength=V-C,P.isPrimaryAxis=!0,P.viewRect=e.Rect.createWithCoords(F,C,D,V),C=V+R,(0,n.layoutAxisParts)(P,h.layoutAxisPartsStrategy)})},s})(r.LeftAlignedOuterAxisLayoutStrategy);return UA.LeftAlignedOuterVerticallyStackedAxisLayoutStrategy=o,UA}var zA={},vCe;function dVe(){if(vCe)return zA;vCe=1;var t=zA&&zA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(zA,"__esModule",{value:!0}),zA.RightAlignedOuterVerticallyStackedAxisLayoutStrategy=void 0;var e=Rn(),i=$d(),n=fs(),r=bW(),o=(function(a){t(s,a);function s(){var l=a!==null&&a.apply(this,arguments)||this;return l.type=i.ELayoutStrategyType.RightStacked,l.isStacked=!0,l}return s.prototype.measureAxes=function(l,u,c){var d=this,f,h=0;c.forEach(function(b){b.measure(),d.updateAxisLayoutState(b);var S=(0,n.getVerticalAxisRequiredSize)(b.axisLayoutState);h=S>h?S:h});var p=c[0],g=c[c.length-1];this.updateTopAndBottomChartLayoutState(u,p==null?void 0:p.axisLayoutState.additionalTopSize,g==null?void 0:g.axisLayoutState.additionalBottomSize);var v=l.rightViewportBorder,y=l.rightCanvasBorder,m=l.adjustedPadding;return h+=v+y+((f=m==null?void 0:m.right)!==null&&f!==void 0?f:0),h},s.prototype.layoutAxes=function(l,u,c,d,f){var h=this,p=d-u,g=f[0],v=f[f.length-1],y=f.filter(function(P){return P.stackedAxisLength}),m=f.reduce(function(P,x){return P-x.axisLayoutState.additionalBottomSize-x.axisLayoutState.additionalTopSize},p+(g==null?void 0:g.axisLayoutState.additionalTopSize)+(v==null?void 0:v.axisLayoutState.additionalBottomSize)),b=y.reduce(function(P,x){return P+h.calculateTotalAxisHeight(x,m)},0),S=p+(g==null?void 0:g.axisLayoutState.additionalTopSize)+(v==null?void 0:v.axisLayoutState.additionalBottomSize)-b;if(S<0)throw new Error("Right stacked axes with defined size total ".concat(b," pixels which is ").concat(-S," more than the space available"));var _=S/(f.length-y.length),C=u-(g==null?void 0:g.axisLayoutState.additionalTopSize);f.forEach(function(P){var x=P.axisLayoutState,E=x.axisSize,A=x.additionalLeftSize,R=x.additionalBottomSize,M=x.additionalTopSize,D=l+A,F=D+E,I=P.stackedAxisLength?h.calculateTotalAxisHeight(P,m):_,V=C+I-R;C+=M,P.offset=C-u,P.axisLength=V-C,P.isPrimaryAxis=!0,P.viewRect=e.Rect.createWithCoords(D,C,F,V),C=V+R,(0,n.layoutAxisParts)(P,h.layoutAxisPartsStrategy)})},s})(r.RightAlignedOuterAxisLayoutStrategy);return zA.RightAlignedOuterVerticallyStackedAxisLayoutStrategy=o,zA}var $A={},yCe;function fVe(){if(yCe)return $A;yCe=1;var t=$A&&$A.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty($A,"__esModule",{value:!0}),$A.TopAlignedOuterHorizontallyStackedAxisLayoutStrategy=void 0;var e=Rn(),i=$d(),n=fs(),r=_W(),o=(function(a){t(s,a);function s(){var l=a!==null&&a.apply(this,arguments)||this;return l.type=i.ELayoutStrategyType.TopStacked,l.isStacked=!0,l}return s.prototype.measureAxes=function(l,u,c){var d=this,f,h=0;c.forEach(function(b){b.measure(),d.updateAxisLayoutState(b);var S=(0,n.getHorizontalAxisRequiredSize)(b.axisLayoutState);h=S>h?S:h});var p=c[0],g=c[c.length-1];this.updateLeftAndRightChartLayoutState(u,p==null?void 0:p.axisLayoutState.additionalLeftSize,g==null?void 0:g.axisLayoutState.additionalRightSize);var v=l.topViewportBorder,y=l.topCanvasBorder,m=l.adjustedPadding;return h+=v+y+((f=m==null?void 0:m.top)!==null&&f!==void 0?f:0),h},s.prototype.layoutAxes=function(l,u,c,d,f){var h=this,p=c-l,g=f[0],v=f[f.length-1],y=f.filter(function(P){return P.stackedAxisLength}),m=f.reduce(function(P,x){return P-x.axisLayoutState.additionalBottomSize-x.axisLayoutState.additionalTopSize},p+(g==null?void 0:g.axisLayoutState.additionalLeftSize)+(v==null?void 0:v.axisLayoutState.additionalRightSize)),b=y.reduce(function(P,x){return P+h.calculateTotalAxisWidth(x,m)},0),S=p+(g==null?void 0:g.axisLayoutState.additionalLeftSize)+(v==null?void 0:v.axisLayoutState.additionalRightSize)-b;if(S<0)throw new Error("Top stacked axes with defined size total ".concat(b," pixels which is ").concat(-S," more than the space available"));var _=S/(f.length-y.length),C=l-(g==null?void 0:g.axisLayoutState.additionalLeftSize);f.forEach(function(P){var x=P.axisLayoutState,E=x.axisSize,A=x.additionalLeftSize,R=x.additionalRightSize,M=x.additionalBottomSize,D=d-M,F=D-E,I=P.stackedAxisLength?h.calculateTotalAxisWidth(P,m):_,V=C+I-R;C+=A,P.offset=C-l,P.axisLength=V-C,P.isPrimaryAxis=!0,P.viewRect=e.Rect.createWithCoords(C,F,V,D),C=V+R,(0,n.layoutAxisParts)(P,h.layoutAxisPartsStrategy)})},s})(r.TopAlignedOuterAxisLayoutStrategy);return $A.TopAlignedOuterHorizontallyStackedAxisLayoutStrategy=o,$A}var WA={},mCe;function hVe(){if(mCe)return WA;mCe=1;var t=WA&&WA.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(WA,"__esModule",{value:!0}),WA.SciChartJsNavyTheme=void 0;var e=OI(),i=Xs(),n=cW(),r=(function(o){t(a,o);function a(){var s=o.call(this)||this;return s.type=e.EThemeProviderType.Navy,s.background1="#22365B",s.background2="#17243d",s.loadingBackground1="#21253D",s.loadingBackground2="#09090F",s.sciChartBackground="radial-gradient(circle, ".concat(s.background1," 0%, ").concat(s.background2," 100%)"),s.loadingAnimationBackground="radial-gradient(circle, ".concat(s.loadingBackground1," 0%, ").concat(s.loadingBackground2," 100%)"),s.loadingAnimationForeground="#2A2F4C",s.axisBandsFill="#52469503",s.tickTextBrush="#8398ba",s.strokePalette=["#274b92","#47bde6","#ae418d","#e97064","#68bcae","#634e96"],s.fillPalette=["#274b9288","#47bde688","#ae418d88","#e9706488","#68bcae88","#634e9688"],s.lineSeriesColor=i.AUTO_COLOR,s.planeBorderColor="#191C6D77",s.axisPlaneBackgroundFill="TRANSPARENT",s.axis3DBandsFill="#52469503",s.isLightBackground=!1,s.majorGridLineBrush="#191C6D77",s.minorGridLineBrush="#2B2D7077",s.polarMajorGridLineBrush="#191C6177",s.polarMinorGridLineBrush="#2E2F7077",s}return a})(n.SciChartJSDarkv2Theme);return WA.SciChartJsNavyTheme=r,WA}var GA={},bCe;function pVe(){if(bCe)return GA;bCe=1;var t=GA&&GA.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(GA,"__esModule",{value:!0}),GA.SciChartJSLightTheme=void 0;var e=OI(),i=Xs(),n=(function(r){t(o,r);function o(){var a=r!==null&&r.apply(this,arguments)||this;return a.strokePalette=["#F48420","#AE408E","#30BC9A","#209FD9","#264B93"],a.fillPalette=["#F4842077","#AE408E77","#30BC9A77","#209FD977","#264B9377"],a.type=e.EThemeProviderType.Light,a.sciChartBackground="#F9F9F9FF",a.loadingAnimationBackground="#F9F9F9FF",a.loadingAnimationForeground="#777777FF",a.gridBorderBrush="#33333399",a.axisBandsFill="#AAAAAA09",a.axisBorder="#00000000",a.tickTextBrush="#333333FF",a.majorGridLineBrush="#CFCFCFFF",a.minorGridLineBrush="#CFCFCF77",a.polarMajorGridLineBrush="#CFCFCFFF",a.polarMinorGridLineBrush="#E5E5E5FF",a.gridBackgroundBrush="#05333377",a.rolloverLineBrush="#33333333",a.cursorLineBrush="#33333355",a.rubberBandFillBrush="#33333333",a.rubberBandStrokeBrush="#33333377",a.legendBackgroundBrush="#33333333",a.labelBackgroundBrush="#D0D0D0BB",a.labelBorderBrush="#33333377",a.labelForegroundBrush="#555555FF",a.textAnnotationForeground="#000000FF",a.textAnnotationBackground="#FFFFFFFF",a.annotationsGripsBorderBrush="#232323FF",a.annotationsGripsBackgroundBrush="#FFFFFF33",a.annotationSelectionStroke="#f00e0e66",a.overviewFillBrush="#33333322",a.scrollbarBackgroundBrush="#33333322",a.scrollbarBorderBrush="#12121255",a.scrollbarGripsBackgroundBrush="#FFFFFF66",a.scrollbarViewportBackgroundBrush="#FFFFFF44",a.scrollbarViewportBorderBrush="#12121255",a.upWickColor="#52CC54FF",a.downWickColor="#E26565FF",a.upBodyBrush="#52CC54A0",a.downBodyBrush="#E26565D0",a.upBandSeriesLineColor="#52CC54FF",a.downBandSeriesLineColor="#E26565FF",a.upBandSeriesFillColor="#52CC5490",a.downBandSeriesFillColor="#E26565A0",a.mountainAreaBrush="#76B7E2B4",a.mountainLineColor="#777777FF",a.lineSeriesColor="#777777FF",a.columnLineColor="#777777FF",a.columnFillBrush="#777777FF",a.impulseFillBrush="#777777FF",a.defaultColorMapBrush=[{offset:0,color:"DARKBLUE"},{offset:.5,color:"CORNFLOWERBLUE"},{offset:1,color:"#FF22AAFF"}],a.axisTitleColor="#777777FF",a.chartTitleColor="#777777FF",a.shadowEffectColor="#A0AABAFA",a.planeBorderColor="#EEEEEEFF",a.axisPlaneBackgroundFill="TRANSPARENT",a.axis3DBandsFill="#33333333",a.isLightBackground=!0,a}return o})(i.ThemeProvider);return GA.SciChartJSLightTheme=n,GA}var YA={},SCe;function gVe(){if(SCe)return YA;SCe=1;var t=YA&&YA.__assign||function(){return t=Object.assign||function(l){for(var u,c=1,d=arguments.length;c<d;c++){u=arguments[c];for(var f in u)Object.prototype.hasOwnProperty.call(u,f)&&(l[f]=u[f])}return l},t.apply(this,arguments)};Object.defineProperty(YA,"__esModule",{value:!0}),YA.PieSegment=void 0;var e=mo(),i=$i(),n=ga(),r=hl(),o=IW(),a=sBe(),s=(function(){function l(u){var c,d,f,h,p,g,v,y,m,b;this.colorProperty="grey",this.isSelectedProperty=!1,this.textProperty="",this.deltaProperty=15,this.shiftProperty=0,this.labelOffsetProperty=new i.Point(0,0),this.radiusAdjustmentProperty=1,this.id=(c=u==null?void 0:u.id)!==null&&c!==void 0?c:(0,r.generateGuid)(),this.colorProperty=(d=u==null?void 0:u.color)!==null&&d!==void 0?d:this.colorProperty,this.colorLinearGradientProperty=(f=u==null?void 0:u.colorLinearGradient)!==null&&f!==void 0?f:this.colorLinearGradientProperty,this.isSelectedProperty=(h=u==null?void 0:u.isSelected)!==null&&h!==void 0?h:this.isSelectedProperty,this.textProperty=(p=u==null?void 0:u.text)!==null&&p!==void 0?p:this.textProperty,this.valueProperty=(g=u==null?void 0:u.value)!==null&&g!==void 0?g:this.valueProperty,this.deltaProperty=(v=u==null?void 0:u.delta)!==null&&v!==void 0?v:this.deltaProperty,this.showLabelProperty=(y=u==null?void 0:u.showLabel)!==null&&y!==void 0?y:!0,u!=null&&u.labelProvider&&("getSegmentText"in(u==null?void 0:u.labelProvider)||(u.labelProvider=(0,e.createType)(n.EBaseType.LabelProvider,u.labelProvider.type,void 0,u.labelProvider.options))),this.labelProviderProperty=u==null?void 0:u.labelProvider,this.labelOffsetProperty=(m=u==null?void 0:u.labelOffset)!==null&&m!==void 0?m:this.labelOffsetProperty,this.labelStyleProperty=u==null?void 0:u.labelStyle,this.radiusAdjustmentProperty=(b=u==null?void 0:u.radiusAdjustment)!==null&&b!==void 0?b:this.radiusAdjustmentProperty}return l.prototype.onAttach=function(u){this.parentSurface=u,this.labelProviderProperty&&this.labelProviderProperty.attachedToSurface(u),this.invalidateParentCallback=u.invalidateElement},l.prototype.onDetach=function(){this.invalidateParentCallback=void 0},Object.defineProperty(l.prototype,"showLabel",{get:function(){return this.showLabelProperty},set:function(u){this.showLabelProperty=u,this.notifyPropertyChanged(a.PROPERTY.SHOW_LABEL)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"colorLinearGradient",{get:function(){return this.colorLinearGradientProperty},set:function(u){this.colorLinearGradientProperty=u,this.notifyPropertyChanged(a.PROPERTY.COLOR_LINEAR_GRADIENT)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"color",{get:function(){return this.colorProperty},set:function(u){this.colorProperty=u,this.notifyPropertyChanged(a.PROPERTY.COLOR)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"isSelected",{get:function(){return this.isSelectedProperty},set:function(u){this.isSelectedProperty!==u&&(this.isSelectedProperty=u,this.notifyPropertyChanged(a.PROPERTY.IS_SELECTED))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"text",{get:function(){return this.textProperty},set:function(u){this.textProperty=u,this.notifyPropertyChanged(a.PROPERTY.TEXT)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"labelProvider",{get:function(){return this.labelProviderProperty===void 0&&(this.labelProvider=new o.PieLabelProvider),this.labelProviderProperty},set:function(u){this.labelProviderProperty=u,this.notifyPropertyChanged(a.PROPERTY.LABEL_PROVIDER)},enumerable:!1,configurable:!0}),l.prototype.getPercentage=function(u){return 100*this.value/u},Object.defineProperty(l.prototype,"value",{get:function(){return this.valueProperty},set:function(u){this.oldValueProperty=this.valueProperty,this.valueProperty=u,this.notifyPropertyChanged(a.PROPERTY.VALUE)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"oldValue",{get:function(){return this.oldValueProperty},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"delta",{get:function(){return this.deltaProperty},set:function(u){this.deltaProperty!==u&&(this.deltaProperty=u,this.notifyPropertyChanged(a.PROPERTY.DELTA))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"shift",{get:function(){return this.shiftProperty},set:function(u){this.shiftProperty!==u&&(this.shiftProperty=u,this.notifyPropertyChanged(a.PROPERTY.SHIFT))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"labelStyle",{get:function(){var u;return t(t({},(u=this.parentSurface)===null||u===void 0?void 0:u.labelStyle),this.labelStyleProperty)},set:function(u){this.labelStyleProperty=t(t({},this.labelStyleProperty),u),this.notifyPropertyChanged(a.PROPERTY.LABEL_STYLE)},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"labelOffset",{get:function(){return this.labelOffsetProperty},set:function(u){var c,d;((c=this.labelOffsetProperty)===null||c===void 0?void 0:c.x)!==u.x&&((d=this.labelOffsetProperty)===null||d===void 0?void 0:d.y)!==u.y&&(this.labelOffsetProperty=u,this.notifyPropertyChanged(a.PROPERTY.LABEL_OFFSET))},enumerable:!1,configurable:!0}),Object.defineProperty(l.prototype,"radiusAdjustment",{get:function(){return this.radiusAdjustmentProperty},set:function(u){this.radiusAdjustmentProperty=u,this.notifyPropertyChanged(a.PROPERTY.RADIUS_ADJUSTMENT)},enumerable:!1,configurable:!0}),l.prototype.toJSON=function(){var u;return{id:this.id,color:this.color,colorLinearGradient:this.colorLinearGradient,isSelected:this.isSelected,delta:this.delta,text:this.text,value:this.value,labelProvider:(u=this.labelProviderProperty)===null||u===void 0?void 0:u.toJSON(),labelOffset:this.labelOffset,labelStyle:this.labelStyle,radiusAdjustment:this.radiusAdjustment}},l.prototype.getLabelText=function(u){return this.labelProviderProperty?this.labelProvider.getSegmentText(this,u):this.parentSurface.labelProvider.getSegmentText(this,u)},l.prototype.notifyPropertyChanged=function(u){u===a.PROPERTY.LABEL_PROVIDER&&this.labelProviderProperty&&this.labelProviderProperty.attachedToSurface(this.parentSurface),this.invalidateParentCallback&&this.invalidateParentCallback(u)},l})();return YA.PieSegment=s,YA}var Hb={},EB={},f7={},_Ce;function Nj(){return _Ce||(_Ce=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convert3DPlaneModeForTitles=t.convert3DPlaneModeForLabels=t.EAxisPlaneDrawLabelsMode=void 0;var e;(function(r){r.Both="Both",r.Hidden="Hidden",r.LocalX="LocalX",r.LocalY="LocalY"})(e=t.EAxisPlaneDrawLabelsMode||(t.EAxisPlaneDrawLabelsMode={}));var i=function(r,o){switch(r){case e.Both:return o.eAxisPlaneDrawLabelsMode.AxisPlaneDrawLabelsBoth;case e.Hidden:return o.eAxisPlaneDrawLabelsMode.AxisPlaneDrawLabelsHidden;case e.LocalX:return o.eAxisPlaneDrawLabelsMode.AxisPlaneDrawLabelsLocalX;case e.LocalY:return o.eAxisPlaneDrawLabelsMode.AxisPlaneDrawLabelsLocalY}};t.convert3DPlaneModeForLabels=i;var n=function(r,o){switch(r){case e.Both:return o.eAxisPlaneDrawTitlesMode.AxisPlaneDrawTitlesBoth;case e.Hidden:return o.eAxisPlaneDrawTitlesMode.AxisPlaneDrawTitlesHidden;case e.LocalX:return o.eAxisPlaneDrawTitlesMode.AxisPlaneDrawTitlesLocalX;case e.LocalY:return o.eAxisPlaneDrawTitlesMode.AxisPlaneDrawTitlesLocalY}};t.convert3DPlaneModeForTitles=n})(f7)),f7}var h7={},PCe;function a$(){return PCe||(PCe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.convertAxisPlaneVisibilityMode=t.EAxisPlaneVisibilityMode=void 0;var e;(function(n){n.Auto="Auto",n.PositiveSide="PositiveSide",n.NegativeSide="NegativeSide"})(e=t.EAxisPlaneVisibilityMode||(t.EAxisPlaneVisibilityMode={}));var i=function(n,r){switch(n){case e.Auto:return r.AxisPlaneVisibilityMode.Auto;case e.PositiveSide:return r.AxisPlaneVisibilityMode.PositiveSide;case e.NegativeSide:return r.AxisPlaneVisibilityMode.NegativeSide}};t.convertAxisPlaneVisibilityMode=i})(h7)),h7}var fp={},CCe;function mL(){if(CCe)return fp;CCe=1,Object.defineProperty(fp,"__esModule",{value:!0}),fp.getArraysEqual=fp.getTextStylesEqual=fp.getTArgbEqual=fp.getLineStylesEqual=fp.getDescriptorsEqual=void 0;function t(o,a){return o===void 0?a===void 0:a===void 0?o===void 0:o.axisTitle===a.axisTitle&&o.axisSize===a.axisSize&&i(o.backgroundColor,a.backgroundColor)&&i(o.bandColor,a.bandColor)&&i(o.borderColor,a.borderColor)&&r(o.majorCoordinates,a.majorCoordinates)&&r(o.minorCoordinates,a.minorCoordinates)&&r(o.tickLabels,a.tickLabels)&&e(o.majorLineStyle,a.majorLineStyle)&&e(o.minorLineStyle,a.minorLineStyle)&&e(o.majorTickStyle,a.majorTickStyle)&&e(o.minorTickStyle,a.minorTickStyle)&&n(o.titleStyle,a.titleStyle)&&n(o.labelStyle,a.labelStyle)&&o.drawMajorGridlines===a.drawMajorGridlines&&o.drawMinorGridlines===a.drawMinorGridlines&&o.drawMajorTicks===a.drawMajorTicks&&o.drawMinorTicks===a.drawMinorTicks&&o.drawBands===a.drawBands&&o.drawLabels===a.drawLabels&&o.isVisible===a.isVisible&&o.borderThickness===a.borderThickness&&o.labelDepthTestEnabled===a.labelDepthTestEnabled&&o.titleOffset===a.titleOffset&&o.tickLabelsOffset===a.tickLabelsOffset&&o.smoothLabelOverlapAvoidance===a.smoothLabelOverlapAvoidance&&o.labelOrientationMode===a.labelOrientationMode&&o.titleOrientationMode===a.titleOrientationMode}fp.getDescriptorsEqual=t;function e(o,a){return o===void 0&&a!==void 0||a===void 0&&o!==void 0?!1:o===void 0&&a===void 0?!0:o.start===a.start&&o.end===a.end&&i(o.stroke,a.stroke)&&o.strokeThickness===a.strokeThickness}fp.getLineStylesEqual=e;function i(o,a){return o===void 0&&a!==void 0||a===void 0&&o!==void 0?!1:o===void 0&&a===void 0?!0:o.red===a.red&&o.green===a.green&&o.blue===a.blue&&o.opacity===a.opacity}fp.getTArgbEqual=i;function n(o,a){return o===void 0&&a!==void 0||a===void 0&&o!==void 0?!1:o===void 0&&a===void 0?!0:o.dpiScaling===a.dpiScaling&&o.fontFamily===a.fontFamily&&o.fontSize===a.fontSize&&o.foreground===a.foreground&&o.multilineAlignment===a.multilineAlignment&&o.multilineSpacing===o.multilineSpacing}fp.getTextStylesEqual=n;function r(o,a){if(o===void 0&&a!==void 0||a===void 0&&o!==void 0)return!1;if(a===void 0&&o===void 0)return!0;if(o.length!==a.length)return!1;for(var s=0;s<o.length;s++)if(o[s]!==a[s])return!1;return!0}return fp.getArraysEqual=r,fp}var TCe;function vVe(){return TCe||(TCe=1,(function(t){var e=EB&&EB.__extends||(function(){var f=function(h,p){return f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,v){g.__proto__=v}||function(g,v){for(var y in v)Object.prototype.hasOwnProperty.call(v,y)&&(g[y]=v[y])},f(h,p)};return function(h,p){if(typeof p!="function"&&p!==null)throw new TypeError("Class extends value "+String(p)+" is not a constructor or null");f(h,p);function g(){this.constructor=h}h.prototype=p===null?Object.create(p):(g.prototype=p.prototype,new g)}})();Object.defineProperty(t,"__esModule",{value:!0}),t.updateScrtTextStyle=t.updateScrtLineStyle=t.updateScrtAxisDescriptor=t.AxisCubeEntity=void 0;var i=Nj(),n=a$(),r=Im(),o=X3(),a=HI(),s=mL(),l=(function(f){e(h,f);function h(p,g){var v=f.call(this,p)||this;return v.type=r.ESceneEntityType.AxisCubeEntity,v.sciChart3DSurface=g,v.setNativeEntity(p.SCRTAxisCubeEntity.implement(v)),v}return h.prototype.Update=function(p){var g=this,v,y;if(this.currentRenderPassData){var m=this.nativeEntity,b=m.GetDescriptorPtr();b.m_bIsZxPlaneVisible=this.sciChart3DSurface.isZXPlaneVisible,b.m_bIsXyPlaneVisible=this.sciChart3DSurface.isXYPlaneVisible,b.m_bIsZyPlaneVisible=this.sciChart3DSurface.isZYPlaneVisible,b.m_eXyPlaneDrawLabelsMode=(0,i.convert3DPlaneModeForLabels)(this.sciChart3DSurface.xyAxisPlane.drawLabelsMode,this.webAssemblyContext),b.m_eZxPlaneDrawLabelsMode=(0,i.convert3DPlaneModeForLabels)(this.sciChart3DSurface.zxAxisPlane.drawLabelsMode,this.webAssemblyContext),b.m_eZyPlaneDrawLabelsMode=(0,i.convert3DPlaneModeForLabels)(this.sciChart3DSurface.zyAxisPlane.drawLabelsMode,this.webAssemblyContext),b.m_eXyPlaneDrawTitlesMode=(0,i.convert3DPlaneModeForTitles)(this.sciChart3DSurface.xyAxisPlane.drawTitlesMode,this.webAssemblyContext),b.m_eZxPlaneDrawTitlesMode=(0,i.convert3DPlaneModeForTitles)(this.sciChart3DSurface.zxAxisPlane.drawTitlesMode,this.webAssemblyContext),b.m_eZyPlaneDrawTitlesMode=(0,i.convert3DPlaneModeForTitles)(this.sciChart3DSurface.zyAxisPlane.drawTitlesMode,this.webAssemblyContext),b.m_eXyPlaneVisibilityMode=(0,n.convertAxisPlaneVisibilityMode)(this.sciChart3DSurface.xyAxisPlane.visibilityMode,this.webAssemblyContext),b.m_eZxPlaneVisibilityMode=(0,n.convertAxisPlaneVisibilityMode)(this.sciChart3DSurface.zxAxisPlane.visibilityMode,this.webAssemblyContext),b.m_eZyPlaneVisibilityMode=(0,n.convertAxisPlaneVisibilityMode)(this.sciChart3DSurface.zyAxisPlane.visibilityMode,this.webAssemblyContext);var S=this.currentRenderPassData.sceneDescriptor.axisCubeDescriptor,_=S.xAxisDescriptor,C=S.yAxisDescriptor,P=S.zAxisDescriptor;(!(0,s.getDescriptorsEqual)(_,this.lastXDescriptor)||!(0,s.getDescriptorsEqual)(C,this.lastYDescriptor)||!(0,s.getDescriptorsEqual)(P,this.lastZDescriptor))&&m.DestroyMeshes(),this.lastXDescriptor=_,this.lastYDescriptor=C,this.lastZDescriptor=P;var x=b.GetXAxisDescPtr(),E=b.GetYAxisDescPtr(),A=b.GetZAxisDescPtr(),R=[[x,_],[E,C],[A,P]],M=!1;R.forEach(function(D){(0,t.updateScrtAxisDescriptor)(g.webAssemblyContext,D[0],D[1]),D[1].labelOrientationMode===g.webAssemblyContext.eSCRTTickLabelOrientationMode.TickLabelOrientationAuto&&(M=!0)}),M&&(b.m_bIsCameraChange=!1),f.prototype.Update.call(this,p),!((v=this.sciChart3DSurface)===null||v===void 0)&&v.isAxisCubeRendered||((y=this.sciChart3DSurface)===null||y===void 0||y.setIsAxisCubeRendered(),setTimeout(function(){var D;return(D=g.sciChart3DSurface)===null||D===void 0?void 0:D.invalidateElement()},0))}},h.prototype.delete=function(){f.prototype.delete.call(this),this.sciChart3DSurface=void 0,this.lastXDescriptor=void 0,this.lastYDescriptor=void 0,this.lastZDescriptor=void 0},h})(a.BaseSceneEntity3D);t.AxisCubeEntity=l;var u=function(f,h,p){var g;h.m_strTitle=(g=p.axisTitle)!==null&&g!==void 0?g:"",h.m_fRangeSize=p.axisSize,h.m_fTitleOffset=p.titleOffset,h.m_fLabelsOffset=p.tickLabelsOffset,h.m_bBandsEnabled=p.drawBands,h.m_bLabelsEnabled=p.drawLabels,h.m_bMajorLinesEnabled=p.drawMajorGridlines,h.m_bMajorTicksEnabled=p.drawMajorTicks,h.m_bMinorLinesEnabled=p.drawMinorGridlines,h.m_bMinorTicksEnabled=p.drawMinorTicks,h.m_fBorderThickness=p.borderThickness,h.m_eLabelsRotationMode=p.labelOrientationMode,h.m_eTitleRotationMode=p.titleOrientationMode,h.m_bBackgroundEnabled=!0,(0,o.updateTsrVector4)(p.borderColor,h.GetBorderColorPtr()),(0,o.updateTsrVector4)(p.backgroundColor,h.GetBackgroundColorPtr()),(0,o.updateTsrVector4)(p.bandColor,h.GetBandColorPtr()),(0,t.updateScrtLineStyle)(p.majorLineStyle,h.GetMajorLineStylePtr()),(0,t.updateScrtLineStyle)(p.minorLineStyle,h.GetMinorLineStylePtr());var v=new f.SCRTTextStyle;(0,t.updateScrtTextStyle)(p.labelStyle,v),h.SetLabelTextStyle(v),(0,t.updateScrtTextStyle)(p.titleStyle,v),h.SetTitleTextStyle(v),v.delete(),(0,t.updateScrtLineStyle)(p.majorTickStyle,h.GetMajorTickStylePtr()),(0,t.updateScrtLineStyle)(p.minorTickStyle,h.GetMinorTickStylePtr());var y=new f.FloatVector;p.majorCoordinates.forEach(function(S){return y.push_back(S)}),h.SetMajors(y),y.delete();var m=new f.FloatVector;p.minorCoordinates.forEach(function(S){return m.push_back(S)}),h.SetMinors(m),m.delete();var b=new f.WStringVector;p.tickLabels.forEach(function(S){return b.push_back(S)}),h.SetMajorLabels(b),b.delete()};t.updateScrtAxisDescriptor=u;var c=function(f,h){h.m_fStrokeThickness=f.strokeThickness,h.m_fStart=f.start,h.m_fEnd=f.end,(0,o.updateTsrVector4)(f.stroke,h.GetStrokeColorPtr())};t.updateScrtLineStyle=c;var d=function(f,h){return h.m_fSize=f.fontSize,h.m_strFont=f.fontFamily,h.m_uiARGBColor=f.foreground,h.m_fDpiScaling=f.dpiScaling,h.m_MultilineAlignment=f.multilineAlignment,h.m_fMultilineSpacing=f.multilineSpacing,h};t.updateScrtTextStyle=d})(EB)),EB}var qA={},p7={exports:{}},xCe;function yVe(){return xCe||(xCe=1,(function(t,e){var i=(()=>{var r;var n=typeof document<"u"?(r=document.currentScript)==null?void 0:r.src:void 0;return(function(o={}){var a,s=o,l,u,c=new Promise((O,j)=>{l=O,u=j}),d=Object.assign({},s),f=[],h="./this.program",p=(O,j)=>{throw j},g="";function v(O){return s.locateFile?s.locateFile(O,g):g+O}var y,m;typeof document<"u"&&document.currentScript&&(g=document.currentScript.src),n&&(g=n),g.startsWith("blob:")?g="":g=g.substr(0,g.replace(/[?#].*/,"").lastIndexOf("/")+1),y=async O=>{var j=await fetch(O,{credentials:"same-origin"});if(j.ok)return j.arrayBuffer();throw new Error(j.status+" : "+j.url)};var b=s.print||console.log.bind(console),S=s.printErr||console.error.bind(console);Object.assign(s,d),d=null,s.arguments&&(f=s.arguments),s.thisProgram&&(h=s.thisProgram);var _=s.wasmBinary,C,P=!1,x,E,A,R,M,D,F,I,V;function z(){var O=C.buffer;s.HEAP8=E=new Int8Array(O),s.HEAP16=R=new Int16Array(O),s.HEAPU8=A=new Uint8Array(O),s.HEAPU16=M=new Uint16Array(O),s.HEAP32=D=new Int32Array(O),s.HEAPU32=F=new Uint32Array(O),s.HEAPF32=I=new Float32Array(O),s.HEAPF64=V=new Float64Array(O)}var G=[],H=[],U=[],k=[];function X(){if(s.preRun)for(typeof s.preRun=="function"&&(s.preRun=[s.preRun]);s.preRun.length;)oe(s.preRun.shift());Mt(G)}function W(){!s.noFSInit&&!ce.initialized&&ce.init(),ce.ignorePermissions=!1,Mt(H)}function Y(){Mt(U)}function te(){if(s.postRun)for(typeof s.postRun=="function"&&(s.postRun=[s.postRun]);s.postRun.length;)ge(s.postRun.shift());Mt(k)}function oe(O){G.unshift(O)}function de(O){H.unshift(O)}function ge(O){k.unshift(O)}var Ee=0,Re=null;function Ae(O){var j;Ee++,(j=s.monitorRunDependencies)==null||j.call(s,Ee)}function Pe(O){var Q;if(Ee--,(Q=s.monitorRunDependencies)==null||Q.call(s,Ee),Ee==0&&Re){var j=Re;Re=null,j()}}function we(O){var Q;(Q=s.onAbort)==null||Q.call(s,O),O="Aborted("+O+")",S(O),P=!0,O+=". Build with -sASSERTIONS for more info.";var j=new WebAssembly.RuntimeError(O);throw u(j),j}var Te="data:application/octet-stream;base64,",ke=O=>O.startsWith(Te);function $e(){var O="scichart3d.wasm";return ke(O)?O:v(O)}var Ne;function ve(O){if(O==Ne&&_)return new Uint8Array(_);throw"both async and sync fetching of the wasm failed"}async function pe(O){if(!_)try{var j=await y(O);return new Uint8Array(j)}catch{}return ve(O)}async function fe(O,j){try{var Q=await pe(O),ie=await WebAssembly.instantiate(Q,j);return ie}catch(he){S(`failed to asynchronously prepare wasm: ${he}`),we(he)}}async function me(O,j,Q){if(!O&&typeof WebAssembly.instantiateStreaming=="function"&&!ke(j)&&typeof fetch=="function")try{var ie=fetch(j,{credentials:"same-origin"}),he=await WebAssembly.instantiateStreaming(ie,Q);return he}catch(Oe){S(`wasm streaming compile failed: ${Oe}`),S("falling back to ArrayBuffer instantiation")}return fe(j,Q)}function Ce(){return{a:xi}}async function Ue(){function O(he,Oe){return yi=he.exports,yi=Xp(yi),C=yi.nb,z(),Lt=yi.sb,de(yi.ob),Pe(),yi}Ae();function j(he){O(he.instance)}var Q=Ce();if(s.instantiateWasm)try{return s.instantiateWasm(Q,O)}catch(he){S(`Module.instantiateWasm callback failed with error: ${he}`),u(he)}Ne??(Ne=$e());try{var ie=await me(_,Ne,Q);return j(ie),ie}catch(he){u(he);return}}var Qe,it,xt={514030:()=>s.getRandomValue(),514066:()=>{if(s.getRandomValue===void 0)try{var O=typeof window=="object"?window:self,j=typeof O.crypto<"u"?O.crypto:O.msCrypto,Q=function(){var Oe=new Uint32Array(1);return j.getRandomValues(Oe),Oe[0]>>>0};Q(),s.getRandomValue=Q}catch{try{var ie=Math.pow(2,32),he=function(){var Fe=Math.floor(Math.random()*Math.floor(ie));return Fe>>>0};he(),s.getRandomValue=he}catch{throw"No secure random number generator found"}}},514110:()=>s.getRandomValue(),514146:()=>{if(s.getRandomValue===void 0)try{var O=typeof window=="object"?window:self,j=typeof O.crypto<"u"?O.crypto:O.msCrypto,Q=function(){var Oe=new Uint32Array(1);return j.getRandomValues(Oe),Oe[0]>>>0};Q(),s.getRandomValue=Q}catch{try{var ie=Math.pow(2,32),he=function(){var Fe=Math.floor(Math.random()*Math.floor(ie));return Fe>>>0};he(),s.getRandomValue=he}catch{throw"No secure random number generator found"}}}};function wt(){var O="";typeof window<"u"?O=window.location.hostname:typeof process<"u"&&(O="node");var j=nr(O)+1,Q=Ol(j);return Di(O,Q,j),Q}class $t{constructor(j){Go(this,"name","ExitStatus");this.message=`Program terminated with exit(${j})`,this.status=j}}var Mt=O=>{for(;O.length>0;)O.shift()(s)},rt=s.noExitRuntime||!0,qe=O=>cf(O),vt=()=>ry();class kt{constructor(j){this.excPtr=j,this.ptr=j-24}set_type(j){F[this.ptr+4>>>2>>>0]=j}get_type(){return F[this.ptr+4>>>2>>>0]}set_destructor(j){F[this.ptr+8>>>2>>>0]=j}get_destructor(){return F[this.ptr+8>>>2>>>0]}set_caught(j){j=j?1:0,E[this.ptr+12>>>0]=j}get_caught(){return E[this.ptr+12>>>0]!=0}set_rethrown(j){j=j?1:0,E[this.ptr+13>>>0]=j}get_rethrown(){return E[this.ptr+13>>>0]!=0}init(j,Q){this.set_adjusted_ptr(0),this.set_type(j),this.set_destructor(Q)}set_adjusted_ptr(j){F[this.ptr+16>>>2>>>0]=j}get_adjusted_ptr(){return F[this.ptr+16>>>2>>>0]}}var Xe=0,_t=(O,j)=>j+2097152>>>0<4194305-!!O?(O>>>0)+j*4294967296:NaN;function Ht(O,j,Q){O>>>=0,j>>>=0,Q>>>=0;var ie=new kt(O);throw ie.init(j,Q),Xe=O,Xe}var Pt=()=>{var O=D[+Yt.varargs>>>2>>>0];return Yt.varargs+=4,O},Jt=Pt,zt={isAbs:O=>O.charAt(0)==="/",splitPath:O=>{var j=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;return j.exec(O).slice(1)},normalizeArray:(O,j)=>{for(var Q=0,ie=O.length-1;ie>=0;ie--){var he=O[ie];he==="."?O.splice(ie,1):he===".."?(O.splice(ie,1),Q++):Q&&(O.splice(ie,1),Q--)}if(j)for(;Q;Q--)O.unshift("..");return O},normalize:O=>{var j=zt.isAbs(O),Q=O.substr(-1)==="/";return O=zt.normalizeArray(O.split("/").filter(ie=>!!ie),!j).join("/"),!O&&!j&&(O="."),O&&Q&&(O+="/"),(j?"/":"")+O},dirname:O=>{var j=zt.splitPath(O),Q=j[0],ie=j[1];return!Q&&!ie?".":(ie&&(ie=ie.substr(0,ie.length-1)),Q+ie)},basename:O=>{if(O==="/")return"/";O=zt.normalize(O),O=O.replace(/\/$/,"");var j=O.lastIndexOf("/");return j===-1?O:O.substr(j+1)},join:(...O)=>zt.normalize(O.join("/")),join2:(O,j)=>zt.normalize(O+"/"+j)},Bt=()=>{if(typeof crypto=="object"&&typeof crypto.getRandomValues=="function")return O=>crypto.getRandomValues(O);we("initRandomDevice")},Mr=O=>(Mr=Bt())(O),Be={resolve:(...O)=>{for(var j="",Q=!1,ie=O.length-1;ie>=-1&&!Q;ie--){var he=ie>=0?O[ie]:ce.cwd();if(typeof he!="string")throw new TypeError("Arguments to path.resolve must be strings");if(!he)return"";j=he+"/"+j,Q=zt.isAbs(he)}return j=zt.normalizeArray(j.split("/").filter(Oe=>!!Oe),!Q).join("/"),(Q?"/":"")+j||"."},relative:(O,j)=>{O=Be.resolve(O).substr(1),j=Be.resolve(j).substr(1);function Q(Ot){for(var St=0;St<Ot.length&&Ot[St]==="";St++);for(var jt=Ot.length-1;jt>=0&&Ot[jt]==="";jt--);return St>jt?[]:Ot.slice(St,jt-St+1)}for(var ie=Q(O.split("/")),he=Q(j.split("/")),Oe=Math.min(ie.length,he.length),Fe=Oe,Ge=0;Ge<Oe;Ge++)if(ie[Ge]!==he[Ge]){Fe=Ge;break}for(var lt=[],Ge=Fe;Ge<ie.length;Ge++)lt.push("..");return lt=lt.concat(he.slice(Fe)),lt.join("/")}},We=typeof TextDecoder<"u"?new TextDecoder:void 0,dt=(O,j=0,Q=NaN)=>{j>>>=0;for(var ie=j+Q,he=j;O[he]&&!(he>=ie);)++he;if(he-j>16&&O.buffer&&We)return We.decode(O.subarray(j,he));for(var Oe="";j<he;){var Fe=O[j++];if(!(Fe&128)){Oe+=String.fromCharCode(Fe);continue}var Ge=O[j++]&63;if((Fe&224)==192){Oe+=String.fromCharCode((Fe&31)<<6|Ge);continue}var lt=O[j++]&63;if((Fe&240)==224?Fe=(Fe&15)<<12|Ge<<6|lt:Fe=(Fe&7)<<18|Ge<<12|lt<<6|O[j++]&63,Fe<65536)Oe+=String.fromCharCode(Fe);else{var Ot=Fe-65536;Oe+=String.fromCharCode(55296|Ot>>10,56320|Ot&1023)}}return Oe},Tt=[],nr=O=>{for(var j=0,Q=0;Q<O.length;++Q){var ie=O.charCodeAt(Q);ie<=127?j++:ie<=2047?j+=2:ie>=55296&&ie<=57343?(j+=4,++Q):j+=3}return j},Ar=(O,j,Q,ie)=>{if(Q>>>=0,!(ie>0))return 0;for(var he=Q,Oe=Q+ie-1,Fe=0;Fe<O.length;++Fe){var Ge=O.charCodeAt(Fe);if(Ge>=55296&&Ge<=57343){var lt=O.charCodeAt(++Fe);Ge=65536+((Ge&1023)<<10)|lt&1023}if(Ge<=127){if(Q>=Oe)break;j[Q++>>>0]=Ge}else if(Ge<=2047){if(Q+1>=Oe)break;j[Q++>>>0]=192|Ge>>6,j[Q++>>>0]=128|Ge&63}else if(Ge<=65535){if(Q+2>=Oe)break;j[Q++>>>0]=224|Ge>>12,j[Q++>>>0]=128|Ge>>6&63,j[Q++>>>0]=128|Ge&63}else{if(Q+3>=Oe)break;j[Q++>>>0]=240|Ge>>18,j[Q++>>>0]=128|Ge>>12&63,j[Q++>>>0]=128|Ge>>6&63,j[Q++>>>0]=128|Ge&63}}return j[Q>>>0]=0,Q-he};function Qr(O,j,Q){var ie=nr(O)+1,he=new Array(ie),Oe=Ar(O,he,0,he.length);return he.length=Oe,he}var Si=()=>{if(!Tt.length){var O=null;if(typeof window<"u"&&typeof window.prompt=="function"&&(O=window.prompt("Input: "),O!==null&&(O+=`
`)),!O)return null;Tt=Qr(O)}return Tt.shift()},oi={ttys:[],init(){},shutdown(){},register(O,j){oi.ttys[O]={input:[],output:[],ops:j},ce.registerDevice(O,oi.stream_ops)},stream_ops:{open(O){var j=oi.ttys[O.node.rdev];if(!j)throw new ce.ErrnoError(43);O.tty=j,O.seekable=!1},close(O){O.tty.ops.fsync(O.tty)},fsync(O){O.tty.ops.fsync(O.tty)},read(O,j,Q,ie,he){if(!O.tty||!O.tty.ops.get_char)throw new ce.ErrnoError(60);for(var Oe=0,Fe=0;Fe<ie;Fe++){var Ge;try{Ge=O.tty.ops.get_char(O.tty)}catch{throw new ce.ErrnoError(29)}if(Ge===void 0&&Oe===0)throw new ce.ErrnoError(6);if(Ge==null)break;Oe++,j[Q+Fe]=Ge}return Oe&&(O.node.atime=Date.now()),Oe},write(O,j,Q,ie,he){if(!O.tty||!O.tty.ops.put_char)throw new ce.ErrnoError(60);try{for(var Oe=0;Oe<ie;Oe++)O.tty.ops.put_char(O.tty,j[Q+Oe])}catch{throw new ce.ErrnoError(29)}return ie&&(O.node.mtime=O.node.ctime=Date.now()),Oe}},default_tty_ops:{get_char(O){return Si()},put_char(O,j){j===null||j===10?(b(dt(O.output)),O.output=[]):j!=0&&O.output.push(j)},fsync(O){O.output&&O.output.length>0&&(b(dt(O.output)),O.output=[])},ioctl_tcgets(O){return{c_iflag:25856,c_oflag:5,c_cflag:191,c_lflag:35387,c_cc:[3,28,127,21,4,0,1,0,17,19,26,0,18,15,23,22,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]}},ioctl_tcsets(O,j,Q){return 0},ioctl_tiocgwinsz(O){return[24,80]}},default_tty1_ops:{put_char(O,j){j===null||j===10?(S(dt(O.output)),O.output=[]):j!=0&&O.output.push(j)},fsync(O){O.output&&O.output.length>0&&(S(dt(O.output)),O.output=[])}}},Yr=(O,j)=>Math.ceil(O/j)*j,vi=O=>{we()},rr={ops_table:null,mount(O){return rr.createNode(null,"/",16895,0)},createNode(O,j,Q,ie){if(ce.isBlkdev(Q)||ce.isFIFO(Q))throw new ce.ErrnoError(63);rr.ops_table||(rr.ops_table={dir:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr,lookup:rr.node_ops.lookup,mknod:rr.node_ops.mknod,rename:rr.node_ops.rename,unlink:rr.node_ops.unlink,rmdir:rr.node_ops.rmdir,readdir:rr.node_ops.readdir,symlink:rr.node_ops.symlink},stream:{llseek:rr.stream_ops.llseek}},file:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr},stream:{llseek:rr.stream_ops.llseek,read:rr.stream_ops.read,write:rr.stream_ops.write,allocate:rr.stream_ops.allocate,mmap:rr.stream_ops.mmap,msync:rr.stream_ops.msync}},link:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr,readlink:rr.node_ops.readlink},stream:{}},chrdev:{node:{getattr:rr.node_ops.getattr,setattr:rr.node_ops.setattr},stream:ce.chrdev_stream_ops}});var he=ce.createNode(O,j,Q,ie);return ce.isDir(he.mode)?(he.node_ops=rr.ops_table.dir.node,he.stream_ops=rr.ops_table.dir.stream,he.contents={}):ce.isFile(he.mode)?(he.node_ops=rr.ops_table.file.node,he.stream_ops=rr.ops_table.file.stream,he.usedBytes=0,he.contents=null):ce.isLink(he.mode)?(he.node_ops=rr.ops_table.link.node,he.stream_ops=rr.ops_table.link.stream):ce.isChrdev(he.mode)&&(he.node_ops=rr.ops_table.chrdev.node,he.stream_ops=rr.ops_table.chrdev.stream),he.atime=he.mtime=he.ctime=Date.now(),O&&(O.contents[j]=he,O.atime=O.mtime=O.ctime=he.atime),he},getFileDataAsTypedArray(O){return O.contents?O.contents.subarray?O.contents.subarray(0,O.usedBytes):new Uint8Array(O.contents):new Uint8Array(0)},expandFileStorage(O,j){var Q=O.contents?O.contents.length:0;if(!(Q>=j)){var ie=1024*1024;j=Math.max(j,Q*(Q<ie?2:1.125)>>>0),Q!=0&&(j=Math.max(j,256));var he=O.contents;O.contents=new Uint8Array(j),O.usedBytes>0&&O.contents.set(he.subarray(0,O.usedBytes),0)}},resizeFileStorage(O,j){if(O.usedBytes!=j)if(j==0)O.contents=null,O.usedBytes=0;else{var Q=O.contents;O.contents=new Uint8Array(j),Q&&O.contents.set(Q.subarray(0,Math.min(j,O.usedBytes))),O.usedBytes=j}},node_ops:{getattr(O){var j={};return j.dev=ce.isChrdev(O.mode)?O.id:1,j.ino=O.id,j.mode=O.mode,j.nlink=1,j.uid=0,j.gid=0,j.rdev=O.rdev,ce.isDir(O.mode)?j.size=4096:ce.isFile(O.mode)?j.size=O.usedBytes:ce.isLink(O.mode)?j.size=O.link.length:j.size=0,j.atime=new Date(O.atime),j.mtime=new Date(O.mtime),j.ctime=new Date(O.ctime),j.blksize=4096,j.blocks=Math.ceil(j.size/j.blksize),j},setattr(O,j){for(const Q of["mode","atime","mtime","ctime"])j[Q]&&(O[Q]=j[Q]);j.size!==void 0&&rr.resizeFileStorage(O,j.size)},lookup(O,j){throw rr.doesNotExistError},mknod(O,j,Q,ie){return rr.createNode(O,j,Q,ie)},rename(O,j,Q){var ie;try{ie=ce.lookupNode(j,Q)}catch{}if(ie){if(ce.isDir(O.mode))for(var he in ie.contents)throw new ce.ErrnoError(55);ce.hashRemoveNode(ie)}delete O.parent.contents[O.name],j.contents[Q]=O,O.name=Q,j.ctime=j.mtime=O.parent.ctime=O.parent.mtime=Date.now()},unlink(O,j){delete O.contents[j],O.ctime=O.mtime=Date.now()},rmdir(O,j){var Q=ce.lookupNode(O,j);for(var ie in Q.contents)throw new ce.ErrnoError(55);delete O.contents[j],O.ctime=O.mtime=Date.now()},readdir(O){return[".","..",...Object.keys(O.contents)]},symlink(O,j,Q){var ie=rr.createNode(O,j,41471,0);return ie.link=Q,ie},readlink(O){if(!ce.isLink(O.mode))throw new ce.ErrnoError(28);return O.link}},stream_ops:{read(O,j,Q,ie,he){var Oe=O.node.contents;if(he>=O.node.usedBytes)return 0;var Fe=Math.min(O.node.usedBytes-he,ie);if(Fe>8&&Oe.subarray)j.set(Oe.subarray(he,he+Fe),Q);else for(var Ge=0;Ge<Fe;Ge++)j[Q+Ge]=Oe[he+Ge];return Fe},write(O,j,Q,ie,he,Oe){if(j.buffer===E.buffer&&(Oe=!1),!ie)return 0;var Fe=O.node;if(Fe.mtime=Fe.ctime=Date.now(),j.subarray&&(!Fe.contents||Fe.contents.subarray)){if(Oe)return Fe.contents=j.subarray(Q,Q+ie),Fe.usedBytes=ie,ie;if(Fe.usedBytes===0&&he===0)return Fe.contents=j.slice(Q,Q+ie),Fe.usedBytes=ie,ie;if(he+ie<=Fe.usedBytes)return Fe.contents.set(j.subarray(Q,Q+ie),he),ie}if(rr.expandFileStorage(Fe,he+ie),Fe.contents.subarray&&j.subarray)Fe.contents.set(j.subarray(Q,Q+ie),he);else for(var Ge=0;Ge<ie;Ge++)Fe.contents[he+Ge]=j[Q+Ge];return Fe.usedBytes=Math.max(Fe.usedBytes,he+ie),ie},llseek(O,j,Q){var ie=j;if(Q===1?ie+=O.position:Q===2&&ce.isFile(O.node.mode)&&(ie+=O.node.usedBytes),ie<0)throw new ce.ErrnoError(28);return ie},allocate(O,j,Q){rr.expandFileStorage(O.node,j+Q),O.node.usedBytes=Math.max(O.node.usedBytes,j+Q)},mmap(O,j,Q,ie,he){if(!ce.isFile(O.node.mode))throw new ce.ErrnoError(43);var Oe,Fe,Ge=O.node.contents;if(!(he&2)&&Ge&&Ge.buffer===E.buffer)Fe=!1,Oe=Ge.byteOffset;else{if(Fe=!0,Oe=vi(),!Oe)throw new ce.ErrnoError(48);Ge&&((Q>0||Q+j<Ge.length)&&(Ge.subarray?Ge=Ge.subarray(Q,Q+j):Ge=Array.prototype.slice.call(Ge,Q,Q+j)),E.set(Ge,Oe>>>0))}return{ptr:Oe,allocated:Fe}},msync(O,j,Q,ie,he){return rr.stream_ops.write(O,j,0,ie,Q,!1),0}}},Ji=async O=>{var j=await y(O);return new Uint8Array(j)},qn=(O,j,Q,ie,he,Oe)=>{ce.createDataFile(O,j,Q,ie,he,Oe)},ri=s.preloadPlugins||[],eo=(O,j,Q,ie)=>{typeof Browser<"u"&&Browser.init();var he=!1;return ri.forEach(Oe=>{he||Oe.canHandle(j)&&(Oe.handle(O,j,Q,ie),he=!0)}),he},xn=(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot)=>{var St=j?Be.resolve(zt.join2(O,j)):O;function jt(cr){function or(mr){Ot==null||Ot(),Ge||qn(O,j,mr,ie,he,lt),Oe==null||Oe(),Pe()}eo(cr,St,or,()=>{Fe==null||Fe(),Pe()})||or(cr)}Ae(),typeof Q=="string"?Ji(Q).then(jt,Fe):jt(Q)},mt=O=>{var j={r:0,"r+":2,w:577,"w+":578,a:1089,"a+":1090},Q=j[O];if(typeof Q>"u")throw new Error(`Unknown file open mode: ${O}`);return Q},gr=(O,j)=>{var Q=0;return O&&(Q|=365),j&&(Q|=146),Q},ce={root:null,mounts:[],devices:{},streams:[],nextInode:1,nameTable:null,currentPath:"/",initialized:!1,ignorePermissions:!0,ErrnoError:class{constructor(O){Go(this,"name","ErrnoError");this.errno=O}},filesystems:null,syncFSRequests:0,readFiles:{},FSStream:class{constructor(){Go(this,"shared",{})}get object(){return this.node}set object(O){this.node=O}get isRead(){return(this.flags&2097155)!==1}get isWrite(){return(this.flags&2097155)!==0}get isAppend(){return this.flags&1024}get flags(){return this.shared.flags}set flags(O){this.shared.flags=O}get position(){return this.shared.position}set position(O){this.shared.position=O}},FSNode:class{constructor(O,j,Q,ie){Go(this,"node_ops",{});Go(this,"stream_ops",{});Go(this,"readMode",365);Go(this,"writeMode",146);Go(this,"mounted",null);O||(O=this),this.parent=O,this.mount=O.mount,this.id=ce.nextInode++,this.name=j,this.mode=Q,this.rdev=ie,this.atime=this.mtime=this.ctime=Date.now()}get read(){return(this.mode&this.readMode)===this.readMode}set read(O){O?this.mode|=this.readMode:this.mode&=~this.readMode}get write(){return(this.mode&this.writeMode)===this.writeMode}set write(O){O?this.mode|=this.writeMode:this.mode&=~this.writeMode}get isFolder(){return ce.isDir(this.mode)}get isDevice(){return ce.isChrdev(this.mode)}},lookupPath(O,j={}){if(!O)return{path:"",node:null};j.follow_mount??(j.follow_mount=!0),zt.isAbs(O)||(O=ce.cwd()+"/"+O);e:for(var Q=0;Q<40;Q++){for(var ie=O.split("/").filter(Ot=>!!Ot&&Ot!=="."),he=ce.root,Oe="/",Fe=0;Fe<ie.length;Fe++){var Ge=Fe===ie.length-1;if(Ge&&j.parent)break;if(ie[Fe]===".."){Oe=zt.dirname(Oe),he=he.parent;continue}Oe=zt.join2(Oe,ie[Fe]);try{he=ce.lookupNode(he,ie[Fe])}catch(Ot){if((Ot==null?void 0:Ot.errno)===44&&Ge&&j.noent_okay)return{path:Oe};throw Ot}if(ce.isMountpoint(he)&&(!Ge||j.follow_mount)&&(he=he.mounted.root),ce.isLink(he.mode)&&(!Ge||j.follow)){if(!he.node_ops.readlink)throw new ce.ErrnoError(52);var lt=he.node_ops.readlink(he);zt.isAbs(lt)||(lt=zt.dirname(Oe)+"/"+lt),O=lt+"/"+ie.slice(Fe+1).join("/");continue e}}return{path:Oe,node:he}}throw new ce.ErrnoError(32)},getPath(O){for(var j;;){if(ce.isRoot(O)){var Q=O.mount.mountpoint;return j?Q[Q.length-1]!=="/"?`${Q}/${j}`:Q+j:Q}j=j?`${O.name}/${j}`:O.name,O=O.parent}},hashName(O,j){for(var Q=0,ie=0;ie<j.length;ie++)Q=(Q<<5)-Q+j.charCodeAt(ie)|0;return(O+Q>>>0)%ce.nameTable.length},hashAddNode(O){var j=ce.hashName(O.parent.id,O.name);O.name_next=ce.nameTable[j],ce.nameTable[j]=O},hashRemoveNode(O){var j=ce.hashName(O.parent.id,O.name);if(ce.nameTable[j]===O)ce.nameTable[j]=O.name_next;else for(var Q=ce.nameTable[j];Q;){if(Q.name_next===O){Q.name_next=O.name_next;break}Q=Q.name_next}},lookupNode(O,j){var Q=ce.mayLookup(O);if(Q)throw new ce.ErrnoError(Q);for(var ie=ce.hashName(O.id,j),he=ce.nameTable[ie];he;he=he.name_next){var Oe=he.name;if(he.parent.id===O.id&&Oe===j)return he}return ce.lookup(O,j)},createNode(O,j,Q,ie){var he=new ce.FSNode(O,j,Q,ie);return ce.hashAddNode(he),he},destroyNode(O){ce.hashRemoveNode(O)},isRoot(O){return O===O.parent},isMountpoint(O){return!!O.mounted},isFile(O){return(O&61440)===32768},isDir(O){return(O&61440)===16384},isLink(O){return(O&61440)===40960},isChrdev(O){return(O&61440)===8192},isBlkdev(O){return(O&61440)===24576},isFIFO(O){return(O&61440)===4096},isSocket(O){return(O&49152)===49152},flagsToPermissionString(O){var j=["r","w","rw"][O&3];return O&512&&(j+="w"),j},nodePermissions(O,j){return ce.ignorePermissions?0:j.includes("r")&&!(O.mode&292)||j.includes("w")&&!(O.mode&146)||j.includes("x")&&!(O.mode&73)?2:0},mayLookup(O){if(!ce.isDir(O.mode))return 54;var j=ce.nodePermissions(O,"x");return j||(O.node_ops.lookup?0:2)},mayCreate(O,j){if(!ce.isDir(O.mode))return 54;try{var Q=ce.lookupNode(O,j);return 20}catch{}return ce.nodePermissions(O,"wx")},mayDelete(O,j,Q){var ie;try{ie=ce.lookupNode(O,j)}catch(Oe){return Oe.errno}var he=ce.nodePermissions(O,"wx");if(he)return he;if(Q){if(!ce.isDir(ie.mode))return 54;if(ce.isRoot(ie)||ce.getPath(ie)===ce.cwd())return 10}else if(ce.isDir(ie.mode))return 31;return 0},mayOpen(O,j){return O?ce.isLink(O.mode)?32:ce.isDir(O.mode)&&(ce.flagsToPermissionString(j)!=="r"||j&512)?31:ce.nodePermissions(O,ce.flagsToPermissionString(j)):44},MAX_OPEN_FDS:4096,nextfd(){for(var O=0;O<=ce.MAX_OPEN_FDS;O++)if(!ce.streams[O])return O;throw new ce.ErrnoError(33)},getStreamChecked(O){var j=ce.getStream(O);if(!j)throw new ce.ErrnoError(8);return j},getStream:O=>ce.streams[O],createStream(O,j=-1){return O=Object.assign(new ce.FSStream,O),j==-1&&(j=ce.nextfd()),O.fd=j,ce.streams[j]=O,O},closeStream(O){ce.streams[O]=null},dupStream(O,j=-1){var ie,he;var Q=ce.createStream(O,j);return(he=(ie=Q.stream_ops)==null?void 0:ie.dup)==null||he.call(ie,Q),Q},chrdev_stream_ops:{open(O){var Q,ie;var j=ce.getDevice(O.node.rdev);O.stream_ops=j.stream_ops,(ie=(Q=O.stream_ops).open)==null||ie.call(Q,O)},llseek(){throw new ce.ErrnoError(70)}},major:O=>O>>8,minor:O=>O&255,makedev:(O,j)=>O<<8|j,registerDevice(O,j){ce.devices[O]={stream_ops:j}},getDevice:O=>ce.devices[O],getMounts(O){for(var j=[],Q=[O];Q.length;){var ie=Q.pop();j.push(ie),Q.push(...ie.mounts)}return j},syncfs(O,j){typeof O=="function"&&(j=O,O=!1),ce.syncFSRequests++,ce.syncFSRequests>1&&S(`warning: ${ce.syncFSRequests} FS.syncfs operations in flight at once, probably just doing extra work`);var Q=ce.getMounts(ce.root.mount),ie=0;function he(Fe){return ce.syncFSRequests--,j(Fe)}function Oe(Fe){if(Fe)return Oe.errored?void 0:(Oe.errored=!0,he(Fe));++ie>=Q.length&&he(null)}Q.forEach(Fe=>{if(!Fe.type.syncfs)return Oe(null);Fe.type.syncfs(Fe,O,Oe)})},mount(O,j,Q){var ie=Q==="/",he=!Q,Oe;if(ie&&ce.root)throw new ce.ErrnoError(10);if(!ie&&!he){var Fe=ce.lookupPath(Q,{follow_mount:!1});if(Q=Fe.path,Oe=Fe.node,ce.isMountpoint(Oe))throw new ce.ErrnoError(10);if(!ce.isDir(Oe.mode))throw new ce.ErrnoError(54)}var Ge={type:O,opts:j,mountpoint:Q,mounts:[]},lt=O.mount(Ge);return lt.mount=Ge,Ge.root=lt,ie?ce.root=lt:Oe&&(Oe.mounted=Ge,Oe.mount&&Oe.mount.mounts.push(Ge)),lt},unmount(O){var j=ce.lookupPath(O,{follow_mount:!1});if(!ce.isMountpoint(j.node))throw new ce.ErrnoError(28);var Q=j.node,ie=Q.mounted,he=ce.getMounts(ie);Object.keys(ce.nameTable).forEach(Fe=>{for(var Ge=ce.nameTable[Fe];Ge;){var lt=Ge.name_next;he.includes(Ge.mount)&&ce.destroyNode(Ge),Ge=lt}}),Q.mounted=null;var Oe=Q.mount.mounts.indexOf(ie);Q.mount.mounts.splice(Oe,1)},lookup(O,j){return O.node_ops.lookup(O,j)},mknod(O,j,Q){var ie=ce.lookupPath(O,{parent:!0}),he=ie.node,Oe=zt.basename(O);if(!Oe||Oe==="."||Oe==="..")throw new ce.ErrnoError(28);var Fe=ce.mayCreate(he,Oe);if(Fe)throw new ce.ErrnoError(Fe);if(!he.node_ops.mknod)throw new ce.ErrnoError(63);return he.node_ops.mknod(he,Oe,j,Q)},statfs(O){var j={bsize:4096,frsize:4096,blocks:1e6,bfree:5e5,bavail:5e5,files:ce.nextInode,ffree:ce.nextInode-1,fsid:42,flags:2,namelen:255},Q=ce.lookupPath(O,{follow:!0}).node;return Q!=null&&Q.node_ops.statfs&&Object.assign(j,Q.node_ops.statfs(Q.mount.opts.root)),j},create(O,j=438){return j&=4095,j|=32768,ce.mknod(O,j,0)},mkdir(O,j=511){return j&=1023,j|=16384,ce.mknod(O,j,0)},mkdirTree(O,j){for(var Q=O.split("/"),ie="",he=0;he<Q.length;++he)if(Q[he]){ie+="/"+Q[he];try{ce.mkdir(ie,j)}catch(Oe){if(Oe.errno!=20)throw Oe}}},mkdev(O,j,Q){return typeof Q>"u"&&(Q=j,j=438),j|=8192,ce.mknod(O,j,Q)},symlink(O,j){if(!Be.resolve(O))throw new ce.ErrnoError(44);var Q=ce.lookupPath(j,{parent:!0}),ie=Q.node;if(!ie)throw new ce.ErrnoError(44);var he=zt.basename(j),Oe=ce.mayCreate(ie,he);if(Oe)throw new ce.ErrnoError(Oe);if(!ie.node_ops.symlink)throw new ce.ErrnoError(63);return ie.node_ops.symlink(ie,he,O)},rename(O,j){var Q=zt.dirname(O),ie=zt.dirname(j),he=zt.basename(O),Oe=zt.basename(j),Fe,Ge,lt;if(Fe=ce.lookupPath(O,{parent:!0}),Ge=Fe.node,Fe=ce.lookupPath(j,{parent:!0}),lt=Fe.node,!Ge||!lt)throw new ce.ErrnoError(44);if(Ge.mount!==lt.mount)throw new ce.ErrnoError(75);var Ot=ce.lookupNode(Ge,he),St=Be.relative(O,ie);if(St.charAt(0)!==".")throw new ce.ErrnoError(28);if(St=Be.relative(j,Q),St.charAt(0)!==".")throw new ce.ErrnoError(55);var jt;try{jt=ce.lookupNode(lt,Oe)}catch{}if(Ot!==jt){var cr=ce.isDir(Ot.mode),or=ce.mayDelete(Ge,he,cr);if(or)throw new ce.ErrnoError(or);if(or=jt?ce.mayDelete(lt,Oe,cr):ce.mayCreate(lt,Oe),or)throw new ce.ErrnoError(or);if(!Ge.node_ops.rename)throw new ce.ErrnoError(63);if(ce.isMountpoint(Ot)||jt&&ce.isMountpoint(jt))throw new ce.ErrnoError(10);if(lt!==Ge&&(or=ce.nodePermissions(Ge,"w"),or))throw new ce.ErrnoError(or);ce.hashRemoveNode(Ot);try{Ge.node_ops.rename(Ot,lt,Oe),Ot.parent=lt}catch(mr){throw mr}finally{ce.hashAddNode(Ot)}}},rmdir(O){var j=ce.lookupPath(O,{parent:!0}),Q=j.node,ie=zt.basename(O),he=ce.lookupNode(Q,ie),Oe=ce.mayDelete(Q,ie,!0);if(Oe)throw new ce.ErrnoError(Oe);if(!Q.node_ops.rmdir)throw new ce.ErrnoError(63);if(ce.isMountpoint(he))throw new ce.ErrnoError(10);Q.node_ops.rmdir(Q,ie),ce.destroyNode(he)},readdir(O){var j=ce.lookupPath(O,{follow:!0}),Q=j.node;if(!Q.node_ops.readdir)throw new ce.ErrnoError(54);return Q.node_ops.readdir(Q)},unlink(O){var j=ce.lookupPath(O,{parent:!0}),Q=j.node;if(!Q)throw new ce.ErrnoError(44);var ie=zt.basename(O),he=ce.lookupNode(Q,ie),Oe=ce.mayDelete(Q,ie,!1);if(Oe)throw new ce.ErrnoError(Oe);if(!Q.node_ops.unlink)throw new ce.ErrnoError(63);if(ce.isMountpoint(he))throw new ce.ErrnoError(10);Q.node_ops.unlink(Q,ie),ce.destroyNode(he)},readlink(O){var j=ce.lookupPath(O),Q=j.node;if(!Q)throw new ce.ErrnoError(44);if(!Q.node_ops.readlink)throw new ce.ErrnoError(28);return Q.node_ops.readlink(Q)},stat(O,j){var Q=ce.lookupPath(O,{follow:!j}),ie=Q.node;if(!ie)throw new ce.ErrnoError(44);if(!ie.node_ops.getattr)throw new ce.ErrnoError(63);return ie.node_ops.getattr(ie)},lstat(O){return ce.stat(O,!0)},chmod(O,j,Q){var ie;if(typeof O=="string"){var he=ce.lookupPath(O,{follow:!Q});ie=he.node}else ie=O;if(!ie.node_ops.setattr)throw new ce.ErrnoError(63);ie.node_ops.setattr(ie,{mode:j&4095|ie.mode&-4096,ctime:Date.now()})},lchmod(O,j){ce.chmod(O,j,!0)},fchmod(O,j){var Q=ce.getStreamChecked(O);ce.chmod(Q.node,j)},chown(O,j,Q,ie){var he;if(typeof O=="string"){var Oe=ce.lookupPath(O,{follow:!ie});he=Oe.node}else he=O;if(!he.node_ops.setattr)throw new ce.ErrnoError(63);he.node_ops.setattr(he,{timestamp:Date.now()})},lchown(O,j,Q){ce.chown(O,j,Q,!0)},fchown(O,j,Q){var ie=ce.getStreamChecked(O);ce.chown(ie.node,j,Q)},truncate(O,j){if(j<0)throw new ce.ErrnoError(28);var Q;if(typeof O=="string"){var ie=ce.lookupPath(O,{follow:!0});Q=ie.node}else Q=O;if(!Q.node_ops.setattr)throw new ce.ErrnoError(63);if(ce.isDir(Q.mode))throw new ce.ErrnoError(31);if(!ce.isFile(Q.mode))throw new ce.ErrnoError(28);var he=ce.nodePermissions(Q,"w");if(he)throw new ce.ErrnoError(he);Q.node_ops.setattr(Q,{size:j,timestamp:Date.now()})},ftruncate(O,j){var Q=ce.getStreamChecked(O);if((Q.flags&2097155)===0)throw new ce.ErrnoError(28);ce.truncate(Q.node,j)},utime(O,j,Q){var ie=ce.lookupPath(O,{follow:!0}),he=ie.node;he.node_ops.setattr(he,{atime:j,mtime:Q})},open(O,j,Q=438){if(O==="")throw new ce.ErrnoError(44);j=typeof j=="string"?mt(j):j,j&64?Q=Q&4095|32768:Q=0;var ie;if(typeof O=="object")ie=O;else{var he=ce.lookupPath(O,{follow:!(j&131072),noent_okay:!0});ie=he.node,O=he.path}var Oe=!1;if(j&64)if(ie){if(j&128)throw new ce.ErrnoError(20)}else ie=ce.mknod(O,Q,0),Oe=!0;if(!ie)throw new ce.ErrnoError(44);if(ce.isChrdev(ie.mode)&&(j&=-513),j&65536&&!ce.isDir(ie.mode))throw new ce.ErrnoError(54);if(!Oe){var Fe=ce.mayOpen(ie,j);if(Fe)throw new ce.ErrnoError(Fe)}j&512&&!Oe&&ce.truncate(ie,0),j&=-131713;var Ge=ce.createStream({node:ie,path:ce.getPath(ie),flags:j,seekable:!0,position:0,stream_ops:ie.stream_ops,ungotten:[],error:!1});return Ge.stream_ops.open&&Ge.stream_ops.open(Ge),s.logReadFiles&&!(j&1)&&(O in ce.readFiles||(ce.readFiles[O]=1)),Ge},close(O){if(ce.isClosed(O))throw new ce.ErrnoError(8);O.getdents&&(O.getdents=null);try{O.stream_ops.close&&O.stream_ops.close(O)}catch(j){throw j}finally{ce.closeStream(O.fd)}O.fd=null},isClosed(O){return O.fd===null},llseek(O,j,Q){if(ce.isClosed(O))throw new ce.ErrnoError(8);if(!O.seekable||!O.stream_ops.llseek)throw new ce.ErrnoError(70);if(Q!=0&&Q!=1&&Q!=2)throw new ce.ErrnoError(28);return O.position=O.stream_ops.llseek(O,j,Q),O.ungotten=[],O.position},read(O,j,Q,ie,he){if(ie<0||he<0)throw new ce.ErrnoError(28);if(ce.isClosed(O))throw new ce.ErrnoError(8);if((O.flags&2097155)===1)throw new ce.ErrnoError(8);if(ce.isDir(O.node.mode))throw new ce.ErrnoError(31);if(!O.stream_ops.read)throw new ce.ErrnoError(28);var Oe=typeof he<"u";if(!Oe)he=O.position;else if(!O.seekable)throw new ce.ErrnoError(70);var Fe=O.stream_ops.read(O,j,Q,ie,he);return Oe||(O.position+=Fe),Fe},write(O,j,Q,ie,he,Oe){if(ie<0||he<0)throw new ce.ErrnoError(28);if(ce.isClosed(O))throw new ce.ErrnoError(8);if((O.flags&2097155)===0)throw new ce.ErrnoError(8);if(ce.isDir(O.node.mode))throw new ce.ErrnoError(31);if(!O.stream_ops.write)throw new ce.ErrnoError(28);O.seekable&&O.flags&1024&&ce.llseek(O,0,2);var Fe=typeof he<"u";if(!Fe)he=O.position;else if(!O.seekable)throw new ce.ErrnoError(70);var Ge=O.stream_ops.write(O,j,Q,ie,he,Oe);return Fe||(O.position+=Ge),Ge},allocate(O,j,Q){if(ce.isClosed(O))throw new ce.ErrnoError(8);if(j<0||Q<=0)throw new ce.ErrnoError(28);if((O.flags&2097155)===0)throw new ce.ErrnoError(8);if(!ce.isFile(O.node.mode)&&!ce.isDir(O.node.mode))throw new ce.ErrnoError(43);if(!O.stream_ops.allocate)throw new ce.ErrnoError(138);O.stream_ops.allocate(O,j,Q)},mmap(O,j,Q,ie,he){if((ie&2)!==0&&(he&2)===0&&(O.flags&2097155)!==2)throw new ce.ErrnoError(2);if((O.flags&2097155)===1)throw new ce.ErrnoError(2);if(!O.stream_ops.mmap)throw new ce.ErrnoError(43);if(!j)throw new ce.ErrnoError(28);return O.stream_ops.mmap(O,j,Q,ie,he)},msync(O,j,Q,ie,he){return O.stream_ops.msync?O.stream_ops.msync(O,j,Q,ie,he):0},ioctl(O,j,Q){if(!O.stream_ops.ioctl)throw new ce.ErrnoError(59);return O.stream_ops.ioctl(O,j,Q)},readFile(O,j={}){if(j.flags=j.flags||0,j.encoding=j.encoding||"binary",j.encoding!=="utf8"&&j.encoding!=="binary")throw new Error(`Invalid encoding type "${j.encoding}"`);var Q,ie=ce.open(O,j.flags),he=ce.stat(O),Oe=he.size,Fe=new Uint8Array(Oe);return ce.read(ie,Fe,0,Oe,0),j.encoding==="utf8"?Q=dt(Fe):j.encoding==="binary"&&(Q=Fe),ce.close(ie),Q},writeFile(O,j,Q={}){Q.flags=Q.flags||577;var ie=ce.open(O,Q.flags,Q.mode);if(typeof j=="string"){var he=new Uint8Array(nr(j)+1),Oe=Ar(j,he,0,he.length);ce.write(ie,he,0,Oe,void 0,Q.canOwn)}else if(ArrayBuffer.isView(j))ce.write(ie,j,0,j.byteLength,void 0,Q.canOwn);else throw new Error("Unsupported data type");ce.close(ie)},cwd:()=>ce.currentPath,chdir(O){var j=ce.lookupPath(O,{follow:!0});if(j.node===null)throw new ce.ErrnoError(44);if(!ce.isDir(j.node.mode))throw new ce.ErrnoError(54);var Q=ce.nodePermissions(j.node,"x");if(Q)throw new ce.ErrnoError(Q);ce.currentPath=j.path},createDefaultDirectories(){ce.mkdir("/tmp"),ce.mkdir("/home"),ce.mkdir("/home/web_user")},createDefaultDevices(){ce.mkdir("/dev"),ce.registerDevice(ce.makedev(1,3),{read:()=>0,write:(ie,he,Oe,Fe,Ge)=>Fe,llseek:()=>0}),ce.mkdev("/dev/null",ce.makedev(1,3)),oi.register(ce.makedev(5,0),oi.default_tty_ops),oi.register(ce.makedev(6,0),oi.default_tty1_ops),ce.mkdev("/dev/tty",ce.makedev(5,0)),ce.mkdev("/dev/tty1",ce.makedev(6,0));var O=new Uint8Array(1024),j=0,Q=()=>(j===0&&(j=Mr(O).byteLength),O[--j]);ce.createDevice("/dev","random",Q),ce.createDevice("/dev","urandom",Q),ce.mkdir("/dev/shm"),ce.mkdir("/dev/shm/tmp")},createSpecialDirectories(){ce.mkdir("/proc");var O=ce.mkdir("/proc/self");ce.mkdir("/proc/self/fd"),ce.mount({mount(){var j=ce.createNode(O,"fd",16895,73);return j.stream_ops={llseek:rr.stream_ops.llseek},j.node_ops={lookup(Q,ie){var he=+ie,Oe=ce.getStreamChecked(he),Fe={parent:null,mount:{mountpoint:"fake"},node_ops:{readlink:()=>Oe.path},id:he+1};return Fe.parent=Fe,Fe},readdir(){return Array.from(ce.streams.entries()).filter(([Q,ie])=>ie).map(([Q,ie])=>Q.toString())}},j}},{},"/proc/self/fd")},createStandardStreams(O,j,Q){O?ce.createDevice("/dev","stdin",O):ce.symlink("/dev/tty","/dev/stdin"),j?ce.createDevice("/dev","stdout",null,j):ce.symlink("/dev/tty","/dev/stdout"),Q?ce.createDevice("/dev","stderr",null,Q):ce.symlink("/dev/tty1","/dev/stderr"),ce.open("/dev/stdin",0),ce.open("/dev/stdout",1),ce.open("/dev/stderr",1)},staticInit(){ce.nameTable=new Array(4096),ce.mount(rr,{},"/"),ce.createDefaultDirectories(),ce.createDefaultDevices(),ce.createSpecialDirectories(),ce.filesystems={MEMFS:rr}},init(O,j,Q){ce.initialized=!0,O??(O=s.stdin),j??(j=s.stdout),Q??(Q=s.stderr),ce.createStandardStreams(O,j,Q)},quit(){ce.initialized=!1;for(var O=0;O<ce.streams.length;O++){var j=ce.streams[O];j&&ce.close(j)}},findObject(O,j){var Q=ce.analyzePath(O,j);return Q.exists?Q.object:null},analyzePath(O,j){try{var Q=ce.lookupPath(O,{follow:!j});O=Q.path}catch{}var ie={isRoot:!1,exists:!1,error:0,name:null,path:null,object:null,parentExists:!1,parentPath:null,parentObject:null};try{var Q=ce.lookupPath(O,{parent:!0});ie.parentExists=!0,ie.parentPath=Q.path,ie.parentObject=Q.node,ie.name=zt.basename(O),Q=ce.lookupPath(O,{follow:!j}),ie.exists=!0,ie.path=Q.path,ie.object=Q.node,ie.name=Q.node.name,ie.isRoot=Q.path==="/"}catch(he){ie.error=he.errno}return ie},createPath(O,j,Q,ie){O=typeof O=="string"?O:ce.getPath(O);for(var he=j.split("/").reverse();he.length;){var Oe=he.pop();if(Oe){var Fe=zt.join2(O,Oe);try{ce.mkdir(Fe)}catch{}O=Fe}}return Fe},createFile(O,j,Q,ie,he){var Oe=zt.join2(typeof O=="string"?O:ce.getPath(O),j),Fe=gr(ie,he);return ce.create(Oe,Fe)},createDataFile(O,j,Q,ie,he,Oe){var Fe=j;O&&(O=typeof O=="string"?O:ce.getPath(O),Fe=j?zt.join2(O,j):O);var Ge=gr(ie,he),lt=ce.create(Fe,Ge);if(Q){if(typeof Q=="string"){for(var Ot=new Array(Q.length),St=0,jt=Q.length;St<jt;++St)Ot[St]=Q.charCodeAt(St);Q=Ot}ce.chmod(lt,Ge|146);var cr=ce.open(lt,577);ce.write(cr,Q,0,Q.length,0,Oe),ce.close(cr),ce.chmod(lt,Ge)}},createDevice(O,j,Q,ie){var Ge;var he=zt.join2(typeof O=="string"?O:ce.getPath(O),j),Oe=gr(!!Q,!!ie);(Ge=ce.createDevice).major??(Ge.major=64);var Fe=ce.makedev(ce.createDevice.major++,0);return ce.registerDevice(Fe,{open(lt){lt.seekable=!1},close(lt){var Ot;(Ot=ie==null?void 0:ie.buffer)!=null&&Ot.length&&ie(10)},read(lt,Ot,St,jt,cr){for(var or=0,mr=0;mr<jt;mr++){var Vr;try{Vr=Q()}catch{throw new ce.ErrnoError(29)}if(Vr===void 0&&or===0)throw new ce.ErrnoError(6);if(Vr==null)break;or++,Ot[St+mr]=Vr}return or&&(lt.node.atime=Date.now()),or},write(lt,Ot,St,jt,cr){for(var or=0;or<jt;or++)try{ie(Ot[St+or])}catch{throw new ce.ErrnoError(29)}return jt&&(lt.node.mtime=lt.node.ctime=Date.now()),or}}),ce.mkdev(he,Oe,Fe)},forceLoadFile(O){if(O.isDevice||O.isFolder||O.link||O.contents)return!0;if(typeof XMLHttpRequest<"u")throw new Error("Lazy loading should have been performed (contents set) in createLazyFile, but it was not. Lazy loading only works in web workers. Use --embed-file or --preload-file in emcc on the main thread.");try{O.contents=m(O.url),O.usedBytes=O.contents.length}catch{throw new ce.ErrnoError(29)}},createLazyFile(O,j,Q,ie,he){class Oe{constructor(){Go(this,"lengthKnown",!1);Go(this,"chunks",[])}get(or){if(!(or>this.length-1||or<0)){var mr=or%this.chunkSize,Vr=or/this.chunkSize|0;return this.getter(Vr)[mr]}}setDataGetter(or){this.getter=or}cacheLength(){var or=new XMLHttpRequest;if(or.open("HEAD",Q,!1),or.send(null),!(or.status>=200&&or.status<300||or.status===304))throw new Error("Couldn't load "+Q+". Status: "+or.status);var mr=Number(or.getResponseHeader("Content-length")),Vr,ei=(Vr=or.getResponseHeader("Accept-Ranges"))&&Vr==="bytes",ui=(Vr=or.getResponseHeader("Content-Encoding"))&&Vr==="gzip",Ei=1024*1024;ei||(Ei=mr);var jr=(ji,Kr)=>{if(ji>Kr)throw new Error("invalid range ("+ji+", "+Kr+") or no bytes requested!");if(Kr>mr-1)throw new Error("only "+mr+" bytes available! programmer error!");var Ai=new XMLHttpRequest;if(Ai.open("GET",Q,!1),mr!==Ei&&Ai.setRequestHeader("Range","bytes="+ji+"-"+Kr),Ai.responseType="arraybuffer",Ai.overrideMimeType&&Ai.overrideMimeType("text/plain; charset=x-user-defined"),Ai.send(null),!(Ai.status>=200&&Ai.status<300||Ai.status===304))throw new Error("Couldn't load "+Q+". Status: "+Ai.status);return Ai.response!==void 0?new Uint8Array(Ai.response||[]):Qr(Ai.responseText||"")},cn=this;cn.setDataGetter(ji=>{var Kr=ji*Ei,Ai=(ji+1)*Ei-1;if(Ai=Math.min(Ai,mr-1),typeof cn.chunks[ji]>"u"&&(cn.chunks[ji]=jr(Kr,Ai)),typeof cn.chunks[ji]>"u")throw new Error("doXHR failed!");return cn.chunks[ji]}),(ui||!mr)&&(Ei=mr=1,mr=this.getter(0).length,Ei=mr,b("LazyFiles on gzip forces download of the whole file when length is accessed")),this._length=mr,this._chunkSize=Ei,this.lengthKnown=!0}get length(){return this.lengthKnown||this.cacheLength(),this._length}get chunkSize(){return this.lengthKnown||this.cacheLength(),this._chunkSize}}if(typeof XMLHttpRequest<"u"){throw"Cannot do synchronous binary XHRs outside webworkers in modern browsers. Use --embed-file or --preload-file in emcc";var Fe,Ge}else var Ge={isDevice:!1,url:Q};var lt=ce.createFile(O,j,Ge,ie,he);Ge.contents?lt.contents=Ge.contents:Ge.url&&(lt.contents=null,lt.url=Ge.url),Object.defineProperties(lt,{usedBytes:{get:function(){return this.contents.length}}});var Ot={},St=Object.keys(lt.stream_ops);St.forEach(cr=>{var or=lt.stream_ops[cr];Ot[cr]=(...mr)=>(ce.forceLoadFile(lt),or(...mr))});function jt(cr,or,mr,Vr,ei){var ui=cr.node.contents;if(ei>=ui.length)return 0;var Ei=Math.min(ui.length-ei,Vr);if(ui.slice)for(var jr=0;jr<Ei;jr++)or[mr+jr]=ui[ei+jr];else for(var jr=0;jr<Ei;jr++)or[mr+jr]=ui.get(ei+jr);return Ei}return Ot.read=(cr,or,mr,Vr,ei)=>(ce.forceLoadFile(lt),jt(cr,or,mr,Vr,ei)),Ot.mmap=(cr,or,mr,Vr,ei)=>{ce.forceLoadFile(lt);var ui=vi();if(!ui)throw new ce.ErrnoError(48);return jt(cr,E,ui,or,mr),{ptr:ui,allocated:!0}},lt.stream_ops=Ot,lt}},fr=(O,j)=>(O>>>=0,O?dt(A,O,j):""),Yt={DEFAULT_POLLMASK:5,calculateAt(O,j,Q){if(zt.isAbs(j))return j;var ie;if(O===-100)ie=ce.cwd();else{var he=Yt.getStreamFromFD(O);ie=he.path}if(j.length==0){if(!Q)throw new ce.ErrnoError(44);return ie}return ie+"/"+j},doStat(O,j,Q){var ie=O(j);D[Q>>>2>>>0]=ie.dev,D[Q+4>>>2>>>0]=ie.mode,F[Q+8>>>2>>>0]=ie.nlink,D[Q+12>>>2>>>0]=ie.uid,D[Q+16>>>2>>>0]=ie.gid,D[Q+20>>>2>>>0]=ie.rdev,it=[ie.size>>>0,(Qe=ie.size,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[Q+24>>>2>>>0]=it[0],D[Q+28>>>2>>>0]=it[1],D[Q+32>>>2>>>0]=4096,D[Q+36>>>2>>>0]=ie.blocks;var he=ie.atime.getTime(),Oe=ie.mtime.getTime(),Fe=ie.ctime.getTime();return it=[Math.floor(he/1e3)>>>0,(Qe=Math.floor(he/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[Q+40>>>2>>>0]=it[0],D[Q+44>>>2>>>0]=it[1],F[Q+48>>>2>>>0]=he%1e3*1e3*1e3,it=[Math.floor(Oe/1e3)>>>0,(Qe=Math.floor(Oe/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[Q+56>>>2>>>0]=it[0],D[Q+60>>>2>>>0]=it[1],F[Q+64>>>2>>>0]=Oe%1e3*1e3*1e3,it=[Math.floor(Fe/1e3)>>>0,(Qe=Math.floor(Fe/1e3),+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[Q+72>>>2>>>0]=it[0],D[Q+76>>>2>>>0]=it[1],F[Q+80>>>2>>>0]=Fe%1e3*1e3*1e3,it=[ie.ino>>>0,(Qe=ie.ino,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[Q+88>>>2>>>0]=it[0],D[Q+92>>>2>>>0]=it[1],0},doMsync(O,j,Q,ie,he){if(!ce.isFile(j.node.mode))throw new ce.ErrnoError(43);if(ie&2)return 0;var Oe=A.slice(O,O+Q);ce.msync(j,Oe,he,Q,ie)},getStreamFromFD(O){var j=ce.getStreamChecked(O);return j},varargs:void 0,getStr(O){var j=fr(O);return j}};function Lr(O,j,Q){Q>>>=0,Yt.varargs=Q;try{var ie=Yt.getStreamFromFD(O);switch(j){case 0:{var he=Pt();if(he<0)return-28;for(;ce.streams[he];)he++;var Oe;return Oe=ce.dupStream(ie,he),Oe.fd}case 1:case 2:return 0;case 3:return ie.flags;case 4:{var he=Pt();return ie.flags|=he,0}case 12:{var he=Jt(),Fe=0;return R[he+Fe>>>1>>>0]=2,0}case 13:case 14:return 0}return-28}catch(Ge){if(typeof ce>"u"||Ge.name!=="ErrnoError")throw Ge;return-Ge.errno}}function Cr(O,j,Q){Q>>>=0,Yt.varargs=Q;try{var ie=Yt.getStreamFromFD(O);switch(j){case 21509:return ie.tty?0:-59;case 21505:{if(!ie.tty)return-59;if(ie.tty.ops.ioctl_tcgets){var he=ie.tty.ops.ioctl_tcgets(ie),Oe=Jt();D[Oe>>>2>>>0]=he.c_iflag||0,D[Oe+4>>>2>>>0]=he.c_oflag||0,D[Oe+8>>>2>>>0]=he.c_cflag||0,D[Oe+12>>>2>>>0]=he.c_lflag||0;for(var Fe=0;Fe<32;Fe++)E[Oe+Fe+17>>>0]=he.c_cc[Fe]||0;return 0}return 0}case 21510:case 21511:case 21512:return ie.tty?0:-59;case 21506:case 21507:case 21508:{if(!ie.tty)return-59;if(ie.tty.ops.ioctl_tcsets){for(var Oe=Jt(),Ge=D[Oe>>>2>>>0],lt=D[Oe+4>>>2>>>0],Ot=D[Oe+8>>>2>>>0],St=D[Oe+12>>>2>>>0],jt=[],Fe=0;Fe<32;Fe++)jt.push(E[Oe+Fe+17>>>0]);return ie.tty.ops.ioctl_tcsets(ie.tty,j,{c_iflag:Ge,c_oflag:lt,c_cflag:Ot,c_lflag:St,c_cc:jt})}return 0}case 21519:{if(!ie.tty)return-59;var Oe=Jt();return D[Oe>>>2>>>0]=0,0}case 21520:return ie.tty?-28:-59;case 21531:{var Oe=Jt();return ce.ioctl(ie,j,Oe)}case 21523:{if(!ie.tty)return-59;if(ie.tty.ops.ioctl_tiocgwinsz){var cr=ie.tty.ops.ioctl_tiocgwinsz(ie.tty),Oe=Jt();R[Oe>>>1>>>0]=cr[0],R[Oe+2>>>1>>>0]=cr[1]}return 0}case 21524:return ie.tty?0:-59;case 21515:return ie.tty?0:-59;default:return-28}}catch(or){if(typeof ce>"u"||or.name!=="ErrnoError")throw or;return-or.errno}}function zr(O,j,Q,ie){j>>>=0,ie>>>=0,Yt.varargs=ie;try{j=Yt.getStr(j),j=Yt.calculateAt(O,j);var he=ie?Pt():0;return ce.open(j,Q,he).fd}catch(Oe){if(typeof ce>"u"||Oe.name!=="ErrnoError")throw Oe;return-Oe.errno}}function fi(O,j){O>>>=0,j>>>=0;try{return O=Yt.getStr(O),Yt.doStat(ce.stat,O,j)}catch(Q){if(typeof ce>"u"||Q.name!=="ErrnoError")throw Q;return-Q.errno}}var to=()=>we(""),st=(O,j)=>Object.defineProperty(j,"name",{value:O}),zo=[],hi=[],si,sr=O=>{throw new si(O)},Ns=()=>hi.length/2-5-zo.length,ts=()=>{hi.push(0,1,void 0,1,null,1,!0,1,!1,1),s.count_emval_handles=Ns},Z={toValue:O=>(O||sr("Cannot use deleted val. handle = "+O),hi[O]),toHandle:O=>{switch(O){case void 0:return 2;case null:return 4;case!0:return 6;case!1:return 8;default:{const j=zo.pop()||hi.length;return hi[j]=O,hi[j+1]=1,j}}}},re=(O,j)=>{var Q=st(j,function(ie){this.name=j,this.message=ie;var he=new Error(ie).stack;he!==void 0&&(this.stack=this.toString()+`
`+he.replace(/^Error(:[^\n]*)?\n/,""))});return Q.prototype=Object.create(O.prototype),Q.prototype.constructor=Q,Q.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},Q},ye,Ye=()=>{for(var O=new Array(256),j=0;j<256;++j)O[j]=String.fromCharCode(j);gt=O},gt,Dt=O=>{for(var j="",Q=O;A[Q>>>0];)j+=gt[A[Q++>>>0]];return j},pr={},Gr=(O,j)=>{for(j===void 0&&sr("ptr should not be undefined");O.baseClass;)j=O.upcast(j),O=O.baseClass;return j},rn=(O,j,Q)=>{j=Gr(O,j),pr.hasOwnProperty(j)?sr(`Tried to register registered instance: ${j}`):pr[j]=Q},ro={},na=O=>{var j=Xo(O),Q=Dt(j);return Cs(j),Q},yl=(O,j)=>{var Q=ro[O];return Q===void 0&&sr(`${j} has unknown type ${na(O)}`),Q},Ga=(O,j)=>{j=Gr(O,j),pr.hasOwnProperty(j)?delete pr[j]:sr(`Tried to unregister unregistered instance: ${j}`)},ys=O=>{},tc=!1,rs=O=>{O.smartPtr?O.smartPtrType.rawDestructor(O.smartPtr):O.ptrType.registeredClass.rawDestructor(O.ptr)},rc=O=>{O.count.value-=1;var j=O.count.value===0;j&&rs(O)},Hl=(O,j,Q)=>{if(j===Q)return O;if(Q.baseClass===void 0)return null;var ie=Hl(O,j,Q.baseClass);return ie===null?null:Q.downcast(ie)},fu={},hu=(O,j)=>(j=Gr(O,j),pr[j]),ic,rl=O=>{throw new ic(O)},oa=(O,j)=>{(!j.ptrType||!j.ptr)&&rl("makeClassHandle requires ptr and ptrType");var Q=!!j.smartPtrType,ie=!!j.smartPtr;return Q!==ie&&rl("Both smartPtrType and smartPtr must be specified"),j.count={value:1},Ya(Object.create(O,{$$:{value:j,writable:!0}}))};function Wd(O){var j=this.getPointee(O);if(!j)return this.destructor(O),null;var Q=hu(this.registeredClass,j);if(Q!==void 0){if(Q.$$.count.value===0)return Q.$$.ptr=j,Q.$$.smartPtr=O,Q.clone();var ie=Q.clone();return this.destructor(O),ie}function he(){return this.isSmartPointer?oa(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:j,smartPtrType:this,smartPtr:O}):oa(this.registeredClass.instancePrototype,{ptrType:this,ptr:O})}var Oe=this.registeredClass.getActualType(j),Fe=fu[Oe];if(!Fe)return he.call(this);var Ge;this.isConst?Ge=Fe.constPointerType:Ge=Fe.pointerType;var lt=Hl(j,this.registeredClass,Ge.registeredClass);return lt===null?he.call(this):this.isSmartPointer?oa(Ge.registeredClass.instancePrototype,{ptrType:Ge,ptr:lt,smartPtrType:this,smartPtr:O}):oa(Ge.registeredClass.instancePrototype,{ptrType:Ge,ptr:lt})}var Ya=O=>typeof FinalizationRegistry>"u"?(Ya=j=>j,O):(tc=new FinalizationRegistry(j=>{rc(j.$$)}),Ya=j=>{var Q=j.$$,ie=!!Q.smartPtr;if(ie){var he={$$:Q};tc.register(j,he,j)}return j},ys=j=>tc.unregister(j),Ya(O));function cd(O,j,Q){O>>>=0,j>>>=0,Q>>>=0,O=Dt(O),j=yl(j,"wrapper"),Q=Z.toValue(Q);var ie=j.registeredClass,he=ie.instancePrototype,Oe=ie.baseClass,Fe=Oe.instancePrototype,Ge=ie.baseClass.constructor,lt=st(O,function(...Ot){ie.baseClass.pureVirtualFunctions.forEach((function(St){if(this[St]===Fe[St])throw new ye(`Pure virtual function ${St} must be implemented in JavaScript`)}).bind(this)),Object.defineProperty(this,"__parent",{value:he}),this.__construct(...Ot)});return he.__construct=function(...St){this===he&&sr("Pass correct 'this' to __construct");var jt=Ge.implement(this,...St);ys(jt);var cr=jt.$$;jt.notifyOnDestruction(),cr.preservePointerOnDelete=!0,Object.defineProperties(this,{$$:{value:cr}}),Ya(this),rn(ie,cr.ptr,this)},he.__destruct=function(){this===he&&sr("Pass correct 'this' to __destruct"),ys(this),Ga(ie,this.$$.ptr)},lt.prototype=Object.create(he),Object.assign(lt.prototype,Q),Z.toHandle(lt)}function ml(O,j,Q,ie,he){}var Fs={},Ul={},wo=(O,j,Q)=>{O.forEach(Ge=>Ul[Ge]=j);function ie(Ge){var lt=Q(Ge);lt.length!==O.length&&rl("Mismatched type converter count");for(var Ot=0;Ot<O.length;++Ot)Lo(O[Ot],lt[Ot])}var he=new Array(j.length),Oe=[],Fe=0;j.forEach((Ge,lt)=>{ro.hasOwnProperty(Ge)?he[lt]=ro[Ge]:(Oe.push(Ge),Fs.hasOwnProperty(Ge)||(Fs[Ge]=[]),Fs[Ge].push(()=>{he[lt]=ro[Ge],++Fe,Fe===Oe.length&&ie(he)}))}),Oe.length===0&&ie(he)};function Ta(O,j,Q={}){var ie=j.name;if(O||sr(`type "${ie}" must have a positive integer typeid pointer`),ro.hasOwnProperty(O)){if(Q.ignoreDuplicateRegistrations)return;sr(`Cannot register type '${ie}' twice`)}if(ro[O]=j,delete Ul[O],Fs.hasOwnProperty(O)){var he=Fs[O];delete Fs[O],he.forEach(Oe=>Oe())}}function Lo(O,j,Q={}){return Ta(O,j,Q)}var ao=8;function bl(O,j,Q,ie){O>>>=0,j>>>=0,j=Dt(j),Lo(O,{name:j,fromWireType:function(he){return!!he},toWireType:function(he,Oe){return Oe?Q:ie},argPackAdvance:ao,readValueFromPointer:function(he){return this.fromWireType(A[he>>>0])},destructorFunction:null})}var nc=O=>({count:O.count,deleteScheduled:O.deleteScheduled,preservePointerOnDelete:O.preservePointerOnDelete,ptr:O.ptr,ptrType:O.ptrType,smartPtr:O.smartPtr,smartPtrType:O.smartPtrType}),Vu=O=>{function j(Q){return Q.$$.ptrType.registeredClass.name}sr(j(O)+" instance already deleted")},dd=()=>{Object.assign(xa.prototype,{isAliasOf(O){if(!(this instanceof xa)||!(O instanceof xa))return!1;var j=this.$$.ptrType.registeredClass,Q=this.$$.ptr;O.$$=O.$$;for(var ie=O.$$.ptrType.registeredClass,he=O.$$.ptr;j.baseClass;)Q=j.upcast(Q),j=j.baseClass;for(;ie.baseClass;)he=ie.upcast(he),ie=ie.baseClass;return j===ie&&Q===he},clone(){if(this.$$.ptr||Vu(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var O=Ya(Object.create(Object.getPrototypeOf(this),{$$:{value:nc(this.$$)}}));return O.$$.count.value+=1,O.$$.deleteScheduled=!1,O},delete(){this.$$.ptr||Vu(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&sr("Object already scheduled for deletion"),ys(this),rc(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)},isDeleted(){return!this.$$.ptr},deleteLater(){return this.$$.ptr||Vu(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&sr("Object already scheduled for deletion"),this.$$.deleteScheduled=!0,this}})};function xa(){}var Fa=(O,j,Q)=>{if(O[j].overloadTable===void 0){var ie=O[j];O[j]=function(...he){return O[j].overloadTable.hasOwnProperty(he.length)||sr(`Function '${Q}' called with an invalid number of arguments (${he.length}) - expects one of (${O[j].overloadTable})!`),O[j].overloadTable[he.length].apply(this,he)},O[j].overloadTable=[],O[j].overloadTable[ie.argCount]=ie}},va=(O,j,Q)=>{s.hasOwnProperty(O)?((Q===void 0||s[O].overloadTable!==void 0&&s[O].overloadTable[Q]!==void 0)&&sr(`Cannot register public name '${O}' twice`),Fa(s,O,O),s[O].overloadTable.hasOwnProperty(Q)&&sr(`Cannot register multiple overloads of a function with the same number of arguments (${Q})!`),s[O].overloadTable[Q]=j):(s[O]=j,s[O].argCount=Q)},Gd=48,Oc=57,il=O=>{O=O.replace(/[^a-zA-Z0-9_]/g,"$");var j=O.charCodeAt(0);return j>=Gd&&j<=Oc?`_${O}`:O};function aa(O,j,Q,ie,he,Oe,Fe,Ge){this.name=O,this.constructor=j,this.instancePrototype=Q,this.rawDestructor=ie,this.baseClass=he,this.getActualType=Oe,this.upcast=Fe,this.downcast=Ge,this.pureVirtualFunctions=[]}var Qi=(O,j,Q)=>{for(;j!==Q;)j.upcast||sr(`Expected null or instance of ${Q.name}, got an instance of ${j.name}`),O=j.upcast(O),j=j.baseClass;return O};function mn(O,j){if(j===null)return this.isReference&&sr(`null is not a valid ${this.name}`),0;j.$$||sr(`Cannot pass "${pd(j)}" as a ${this.name}`),j.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`);var Q=j.$$.ptrType.registeredClass,ie=Qi(j.$$.ptr,Q,this.registeredClass);return ie}function oc(O,j){var Q;if(j===null)return this.isReference&&sr(`null is not a valid ${this.name}`),this.isSmartPointer?(Q=this.rawConstructor(),O!==null&&O.push(this.rawDestructor,Q),Q):0;(!j||!j.$$)&&sr(`Cannot pass "${pd(j)}" as a ${this.name}`),j.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`),!this.isConst&&j.$$.ptrType.isConst&&sr(`Cannot convert argument of type ${j.$$.smartPtrType?j.$$.smartPtrType.name:j.$$.ptrType.name} to parameter type ${this.name}`);var ie=j.$$.ptrType.registeredClass;if(Q=Qi(j.$$.ptr,ie,this.registeredClass),this.isSmartPointer)switch(j.$$.smartPtr===void 0&&sr("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:j.$$.smartPtrType===this?Q=j.$$.smartPtr:sr(`Cannot convert argument of type ${j.$$.smartPtrType?j.$$.smartPtrType.name:j.$$.ptrType.name} to parameter type ${this.name}`);break;case 1:Q=j.$$.smartPtr;break;case 2:if(j.$$.smartPtrType===this)Q=j.$$.smartPtr;else{var he=j.clone();Q=this.rawShare(Q,Z.toHandle(()=>he.delete())),O!==null&&O.push(this.rawDestructor,Q)}break;default:sr("Unsupporting sharing policy")}return Q}function _e(O,j){if(j===null)return this.isReference&&sr(`null is not a valid ${this.name}`),0;j.$$||sr(`Cannot pass "${pd(j)}" as a ${this.name}`),j.$$.ptr||sr(`Cannot pass deleted object as a pointer of type ${this.name}`),j.$$.ptrType.isConst&&sr(`Cannot convert argument of type ${j.$$.ptrType.name} to parameter type ${this.name}`);var Q=j.$$.ptrType.registeredClass,ie=Qi(j.$$.ptr,Q,this.registeredClass);return ie}function He(O){return this.fromWireType(F[O>>>2>>>0])}var et=()=>{Object.assign(ht.prototype,{getPointee(O){return this.rawGetPointee&&(O=this.rawGetPointee(O)),O},destructor(O){var j;(j=this.rawDestructor)==null||j.call(this,O)},argPackAdvance:ao,readValueFromPointer:He,fromWireType:Wd})};function ht(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot,St){this.name=O,this.registeredClass=j,this.isReference=Q,this.isConst=ie,this.isSmartPointer=he,this.pointeeType=Oe,this.sharingPolicy=Fe,this.rawGetPointee=Ge,this.rawConstructor=lt,this.rawShare=Ot,this.rawDestructor=St,!he&&j.baseClass===void 0?ie?(this.toWireType=mn,this.destructorFunction=null):(this.toWireType=_e,this.destructorFunction=null):this.toWireType=oc}var Ft=(O,j,Q)=>{s.hasOwnProperty(O)||rl("Replacing nonexistent public symbol"),s[O].overloadTable!==void 0&&Q!==void 0?s[O].overloadTable[Q]=j:(s[O]=j,s[O].argCount=Q)},ur=(O,j,Q)=>{O=O.replace(/p/g,"i");var ie=s["dynCall_"+O];return ie(j,...Q)},Lt,Kt=O=>Lt.get(O),Zr=(O,j,Q=[])=>{if(O.includes("j"))return ur(O,j,Q);var ie=Kt(j)(...Q);return O[0]=="p"?ie>>>0:ie},ni=(O,j)=>(...Q)=>Zr(O,j,Q),pi=(O,j)=>{O=Dt(O);function Q(){return O.includes("j")||O.includes("p")?ni(O,j):Kt(j)}var ie=Q();return typeof ie!="function"&&sr(`unknown function pointer with signature ${O}: ${j}`),ie},Oi,Bi=(O,j)=>{var Q=[],ie={};function he(Oe){if(!ie[Oe]&&!ro[Oe]){if(Ul[Oe]){Ul[Oe].forEach(he);return}Q.push(Oe),ie[Oe]=!0}}throw j.forEach(he),new Oi(`${O}: `+Q.map(na).join([", "]))};function ms(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot,St,jt,cr){O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0,Ge>>>=0,lt>>>=0,Ot>>>=0,St>>>=0,jt>>>=0,cr>>>=0,St=Dt(St),Oe=pi(he,Oe),Ge&&(Ge=pi(Fe,Ge)),Ot&&(Ot=pi(lt,Ot)),cr=pi(jt,cr);var or=il(St);va(or,function(){Bi(`Cannot construct ${St} due to unbound types`,[ie])}),wo([O,j,Q],ie?[ie]:[],mr=>{var Ai;mr=mr[0];var Vr,ei;ie?(Vr=mr.registeredClass,ei=Vr.instancePrototype):ei=xa.prototype;var ui=st(St,function(...qa){if(Object.getPrototypeOf(this)!==Ei)throw new si("Use 'new' to construct "+St);if(jr.constructor_body===void 0)throw new si(St+" has no accessible constructor");var sa=jr.constructor_body[qa.length];if(sa===void 0)throw new si(`Tried to invoke ctor of ${St} with invalid number of parameters (${qa.length}) - expected (${Object.keys(jr.constructor_body).toString()}) parameters instead!`);return sa.apply(this,qa)}),Ei=Object.create(ei,{constructor:{value:ui}});ui.prototype=Ei;var jr=new aa(St,ui,Ei,cr,Vr,Oe,Ge,Ot);jr.baseClass&&((Ai=jr.baseClass).__derivedClasses??(Ai.__derivedClasses=[]),jr.baseClass.__derivedClasses.push(jr));var cn=new ht(St,jr,!0,!1,!1),ji=new ht(St+"*",jr,!1,!1,!1),Kr=new ht(St+" const*",jr,!1,!0,!1);return fu[O]={pointerType:ji,constPointerType:Kr},Ft(or,ui),[cn,ji,Kr]})}var Ba=O=>{for(;O.length;){var j=O.pop(),Q=O.pop();Q(j)}};function Sl(O){for(var j=1;j<O.length;++j)if(O[j]!==null&&O[j].destructorFunction===void 0)return!0;return!1}function zl(O,j,Q,ie,he,Oe){var Fe=j.length;Fe<2&&sr("argTypes array size mismatch! Must at least get return value and 'this' types!");var Ge=j[1]!==null&&Q!==null,lt=Sl(j),Ot=j[0].name!=="void",St=Fe-2,jt=new Array(St),cr=[],or=[],mr=function(...Vr){or.length=0;var ei;cr.length=Ge?2:1,cr[0]=he,Ge&&(ei=j[1].toWireType(or,this),cr[1]=ei);for(var ui=0;ui<St;++ui)jt[ui]=j[ui+2].toWireType(or,Vr[ui]),cr.push(jt[ui]);var Ei=ie(...cr);function jr(cn){if(lt)Ba(or);else for(var ji=Ge?1:2;ji<j.length;ji++){var Kr=ji===1?ei:jt[ji-2];j[ji].destructorFunction!==null&&j[ji].destructorFunction(Kr)}if(Ot)return j[0].fromWireType(cn)}return jr(Ei)};return st(O,mr)}var Hu=(O,j)=>{for(var Q=[],ie=0;ie<O;ie++)Q.push(F[j+ie*4>>>2>>>0]);return Q},fd=O=>{O=O.trim();const j=O.indexOf("(");return j!==-1?O.substr(0,j):O},Bs=function(O,j,Q,ie,he,Oe,Fe,Ge,lt){O>>>=0,j>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0;var Ot=Hu(Q,ie);j=Dt(j),j=fd(j),Oe=pi(he,Oe),wo([],[O],St=>{St=St[0];var jt=`${St.name}.${j}`;function cr(){Bi(`Cannot call ${jt} due to unbound types`,Ot)}j.startsWith("@@")&&(j=Symbol[j.substring(2)]);var or=St.registeredClass.constructor;return or[j]===void 0?(cr.argCount=Q-1,or[j]=cr):(Fa(or,j,jt),or[j].overloadTable[Q-1]=cr),wo([],Ot,mr=>{var Vr=[mr[0],null].concat(mr.slice(1)),ei=zl(jt,Vr,null,Oe,Fe);if(or[j].overloadTable===void 0?(ei.argCount=Q-1,or[j]=ei):or[j].overloadTable[Q-1]=ei,St.registeredClass.__derivedClasses)for(const ui of St.registeredClass.__derivedClasses)ui.constructor.hasOwnProperty(j)||(ui.constructor[j]=ei);return[]}),[]})},jg=function(O,j,Q,ie,he,Oe){O>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0;var Fe=Hu(j,Q);he=pi(ie,he),wo([],[O],Ge=>{Ge=Ge[0];var lt=`constructor ${Ge.name}`;if(Ge.registeredClass.constructor_body===void 0&&(Ge.registeredClass.constructor_body=[]),Ge.registeredClass.constructor_body[j-1]!==void 0)throw new si(`Cannot register multiple constructors with identical number of parameters (${j-1}) for class '${Ge.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return Ge.registeredClass.constructor_body[j-1]=()=>{Bi(`Cannot construct ${Ge.name} due to unbound types`,Fe)},wo([],Fe,Ot=>(Ot.splice(1,0,null),Ge.registeredClass.constructor_body[j-1]=zl(lt,Ot,null,he,Oe),[])),[]})},js=function(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot){O>>>=0,j>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0;var St=Hu(Q,ie);j=Dt(j),j=fd(j),Oe=pi(he,Oe),wo([],[O],jt=>{jt=jt[0];var cr=`${jt.name}.${j}`;j.startsWith("@@")&&(j=Symbol[j.substring(2)]),Ge&&jt.registeredClass.pureVirtualFunctions.push(j);function or(){Bi(`Cannot call ${cr} due to unbound types`,St)}var mr=jt.registeredClass.instancePrototype,Vr=mr[j];return Vr===void 0||Vr.overloadTable===void 0&&Vr.className!==jt.name&&Vr.argCount===Q-2?(or.argCount=Q-2,or.className=jt.name,mr[j]=or):(Fa(mr,j,cr),mr[j].overloadTable[Q-2]=or),wo([],St,ei=>{var ui=zl(cr,ei,jt,Oe,Fe);return mr[j].overloadTable===void 0?(ui.argCount=Q-2,mr[j]=ui):mr[j].overloadTable[Q-2]=ui,[]}),[]})},qf=(O,j,Q)=>(O instanceof Object||sr(`${Q} with invalid "this": ${O}`),O instanceof j.registeredClass.constructor||sr(`${Q} incompatible with "this" of type ${O.constructor.name}`),O.$$.ptr||sr(`cannot call emscripten binding method ${Q} on deleted object`),Qi(O.$$.ptr,O.$$.ptrType.registeredClass,j.registeredClass)),hd=function(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot){O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0,Ge>>>=0,lt>>>=0,Ot>>>=0,j=Dt(j),he=pi(ie,he),wo([],[O],St=>{St=St[0];var jt=`${St.name}.${j}`,cr={get(){Bi(`Cannot access ${jt} due to unbound types`,[Q,Fe])},enumerable:!0,configurable:!0};return lt?cr.set=()=>Bi(`Cannot access ${jt} due to unbound types`,[Q,Fe]):cr.set=or=>sr(jt+" is a read-only property"),Object.defineProperty(St.registeredClass.instancePrototype,j,cr),wo([],lt?[Q,Fe]:[Q],or=>{var mr=or[0],Vr={get(){var ui=qf(this,St,jt+" getter");return mr.fromWireType(he(Oe,ui))},enumerable:!0};if(lt){lt=pi(Ge,lt);var ei=or[1];Vr.set=function(ui){var Ei=qf(this,St,jt+" setter"),jr=[];lt(Ot,Ei,ei.toWireType(jr,ui)),Ba(jr)}}return Object.defineProperty(St.registeredClass.instancePrototype,j,Vr),[]}),[]})};function is(O){O>>>=0,O>9&&--hi[O+1]===0&&(hi[O]=void 0,zo.push(O))}var Xf={name:"emscripten::val",fromWireType:O=>{var j=Z.toValue(O);return is(O),j},toWireType:(O,j)=>Z.toHandle(j),argPackAdvance:ao,readValueFromPointer:He,destructorFunction:null};function Yd(O){return O>>>=0,Lo(O,Xf)}var ko=(O,j,Q)=>{switch(j){case 1:return Q?function(ie){return this.fromWireType(E[ie>>>0])}:function(ie){return this.fromWireType(A[ie>>>0])};case 2:return Q?function(ie){return this.fromWireType(R[ie>>>1>>>0])}:function(ie){return this.fromWireType(M[ie>>>1>>>0])};case 4:return Q?function(ie){return this.fromWireType(D[ie>>>2>>>0])}:function(ie){return this.fromWireType(F[ie>>>2>>>0])};default:throw new TypeError(`invalid integer width (${j}): ${O}`)}};function ac(O,j,Q,ie){O>>>=0,j>>>=0,Q>>>=0,j=Dt(j);function he(){}he.values={},Lo(O,{name:j,constructor:he,fromWireType:function(Oe){return this.constructor.values[Oe]},toWireType:(Oe,Fe)=>Fe.value,argPackAdvance:ao,readValueFromPointer:ko(j,Q,ie),destructorFunction:null}),va(j,he)}function Nh(O,j,Q){O>>>=0,j>>>=0;var ie=yl(O,"enum");j=Dt(j);var he=ie.constructor,Oe=Object.create(ie.constructor.prototype,{value:{value:Q},constructor:{value:st(`${ie.name}_${j}`,function(){})}});he.values[Q]=Oe,he[j]=Oe}var pd=O=>{if(O===null)return"null";var j=typeof O;return j==="object"||j==="array"||j==="function"?O.toString():""+O},Fh=(O,j)=>{switch(j){case 4:return function(Q){return this.fromWireType(I[Q>>>2>>>0])};case 8:return function(Q){return this.fromWireType(V[Q>>>3>>>0])};default:throw new TypeError(`invalid float width (${j}): ${O}`)}},Vg=function(O,j,Q){O>>>=0,j>>>=0,Q>>>=0,j=Dt(j),Lo(O,{name:j,fromWireType:ie=>ie,toWireType:(ie,he)=>he,argPackAdvance:ao,readValueFromPointer:Fh(j,Q),destructorFunction:null})};function Hg(O,j,Q,ie,he,Oe,Fe,Ge){O>>>=0,Q>>>=0,ie>>>=0,he>>>=0,Oe>>>=0;var lt=Hu(j,Q);O=Dt(O),O=fd(O),he=pi(ie,he),va(O,function(){Bi(`Cannot call ${O} due to unbound types`,lt)},j-1),wo([],lt,Ot=>{var St=[Ot[0],null].concat(Ot.slice(1));return Ft(O,zl(O,St,null,he,Oe),j-1),[]})}var Kf=(O,j,Q)=>{switch(j){case 1:return Q?ie=>E[ie>>>0]:ie=>A[ie>>>0];case 2:return Q?ie=>R[ie>>>1>>>0]:ie=>M[ie>>>1>>>0];case 4:return Q?ie=>D[ie>>>2>>>0]:ie=>F[ie>>>2>>>0];default:throw new TypeError(`invalid integer width (${j}): ${O}`)}};function gd(O,j,Q,ie,he){O>>>=0,j>>>=0,Q>>>=0,j=Dt(j);var Oe=St=>St;if(ie===0){var Fe=32-8*Q;Oe=St=>St<<Fe>>>Fe}var Ge=j.includes("unsigned"),lt=(St,jt)=>{},Ot;Ge?Ot=function(St,jt){return lt(jt,this.name),jt>>>0}:Ot=function(St,jt){return lt(jt,this.name),jt},Lo(O,{name:j,fromWireType:Oe,toWireType:Ot,argPackAdvance:ao,readValueFromPointer:Kf(j,Q,ie!==0),destructorFunction:null})}function Zf(O,j,Q){O>>>=0,Q>>>=0;var ie=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],he=ie[j];function Oe(Fe){var Ge=F[Fe>>>2>>>0],lt=F[Fe+4>>>2>>>0];return new he(E.buffer,lt,Ge)}Q=Dt(Q),Lo(O,{name:Q,fromWireType:Oe,argPackAdvance:ao,readValueFromPointer:Oe},{ignoreDuplicateRegistrations:!0})}var Di=(O,j,Q)=>Ar(O,A,j,Q);function Ip(O,j){O>>>=0,j>>>=0,j=Dt(j),Lo(O,{name:j,fromWireType(Q){for(var ie=F[Q>>>2>>>0],he=Q+4,Oe,Fe,Ge=he,Fe=0;Fe<=ie;++Fe){var lt=he+Fe;if(Fe==ie||A[lt>>>0]==0){var Ot=lt-Ge,St=fr(Ge,Ot);Oe===void 0?Oe=St:(Oe+="\0",Oe+=St),Ge=lt+1}}return Cs(Q),Oe},toWireType(Q,ie){ie instanceof ArrayBuffer&&(ie=new Uint8Array(ie));var he,Oe=typeof ie=="string";Oe||ie instanceof Uint8Array||ie instanceof Uint8ClampedArray||ie instanceof Int8Array||sr("Cannot pass non-string to std::string"),Oe?he=nr(ie):he=ie.length;var Fe=Ol(4+he+1),Ge=Fe+4;if(F[Fe>>>2>>>0]=he,Oe)Di(ie,Ge,he+1);else if(Oe)for(var lt=0;lt<he;++lt){var Ot=ie.charCodeAt(lt);Ot>255&&(Cs(Ge),sr("String has UTF-16 code units that do not fit in 8 bits")),A[Ge+lt>>>0]=Ot}else for(var lt=0;lt<he;++lt)A[Ge+lt>>>0]=ie[lt];return Q!==null&&Q.push(Cs,Fe),Fe},argPackAdvance:ao,readValueFromPointer:He,destructorFunction(Q){Cs(Q)}})}var qd=typeof TextDecoder<"u"?new TextDecoder("utf-16le"):void 0,Xd=(O,j)=>{for(var Q=O,ie=Q>>1,he=ie+j/2;!(ie>=he)&&M[ie>>>0];)++ie;if(Q=ie<<1,Q-O>32&&qd)return qd.decode(A.subarray(O>>>0,Q>>>0));for(var Oe="",Fe=0;!(Fe>=j/2);++Fe){var Ge=R[O+Fe*2>>>1>>>0];if(Ge==0)break;Oe+=String.fromCharCode(Ge)}return Oe},sc=(O,j,Q)=>{if(Q??(Q=2147483647),Q<2)return 0;Q-=2;for(var ie=j,he=Q<O.length*2?Q/2:O.length,Oe=0;Oe<he;++Oe){var Fe=O.charCodeAt(Oe);R[j>>>1>>>0]=Fe,j+=2}return R[j>>>1>>>0]=0,j-ie},Kd=O=>O.length*2,Jf=(O,j)=>{for(var Q=0,ie="";!(Q>=j/4);){var he=D[O+Q*4>>>2>>>0];if(he==0)break;if(++Q,he>=65536){var Oe=he-65536;ie+=String.fromCharCode(55296|Oe>>10,56320|Oe&1023)}else ie+=String.fromCharCode(he)}return ie},Bh=(O,j,Q)=>{if(j>>>=0,Q??(Q=2147483647),Q<4)return 0;for(var ie=j,he=ie+Q-4,Oe=0;Oe<O.length;++Oe){var Fe=O.charCodeAt(Oe);if(Fe>=55296&&Fe<=57343){var Ge=O.charCodeAt(++Oe);Fe=65536+((Fe&1023)<<10)|Ge&1023}if(D[j>>>2>>>0]=Fe,j+=4,j+4>he)break}return D[j>>>2>>>0]=0,j-ie},Dc=O=>{for(var j=0,Q=0;Q<O.length;++Q){var ie=O.charCodeAt(Q);ie>=55296&&ie<=57343&&++Q,j+=4}return j},Rc=function(O,j,Q){O>>>=0,j>>>=0,Q>>>=0,Q=Dt(Q);var ie,he,Oe,Fe;j===2?(ie=Xd,he=sc,Fe=Kd,Oe=Ge=>M[Ge>>>1>>>0]):j===4&&(ie=Jf,he=Bh,Fe=Dc,Oe=Ge=>F[Ge>>>2>>>0]),Lo(O,{name:Q,fromWireType:Ge=>{for(var lt=F[Ge>>>2>>>0],Ot,St=Ge+4,jt=0;jt<=lt;++jt){var cr=Ge+4+jt*j;if(jt==lt||Oe(cr)==0){var or=cr-St,mr=ie(St,or);Ot===void 0?Ot=mr:(Ot+="\0",Ot+=mr),St=cr+j}}return Cs(Ge),Ot},toWireType:(Ge,lt)=>{typeof lt!="string"&&sr(`Cannot pass non-string to C++ string type ${Q}`);var Ot=Fe(lt),St=Ol(4+Ot+j);return F[St>>>2>>>0]=Ot/j,he(lt,St+4,Ot+j),Ge!==null&&Ge.push(Cs,St),St},argPackAdvance:ao,readValueFromPointer:He,destructorFunction(Ge){Cs(Ge)}})},Np=function(O,j){O>>>=0,j>>>=0,j=Dt(j),Lo(O,{isVoid:!0,name:j,argPackAdvance:0,fromWireType:()=>{},toWireType:(Q,ie)=>{}})};function Mc(O){if(so.xhrs.has(O)){var j=so.xhrs.get(O);so.xhrs.free(O),j.readyState>0&&j.readyState<4&&j.abort()}}var nl=()=>{throw 1/0},jh={},Zd=O=>{var j=jh[O];return j===void 0?Dt(O):j},Uu=[];function Vh(O,j,Q,ie,he){return O>>>=0,j>>>=0,Q>>>=0,ie>>>=0,he>>>=0,O=Uu[O],j=Z.toValue(j),Q=Zd(Q),O(j,j[Q],ie,he)}var Jd=O=>{var j=Uu.length;return Uu.push(O),j},pu=(O,j)=>{for(var Q=new Array(O),ie=0;ie<O;++ie)Q[ie]=yl(F[j+ie*4>>>2>>>0],"parameter "+ie);return Q},io=Reflect.construct,gu=(O,j,Q)=>{var ie=[],he=O.toWireType(ie,Q);return ie.length&&(F[j>>>2>>>0]=Z.toHandle(ie)),he},ns=function(O,j,Q){j>>>=0;var ie=pu(O,j),he=ie.shift();O--;var Oe=new Array(O),Fe=(lt,Ot,St,jt)=>{for(var cr=0,or=0;or<O;++or)Oe[or]=ie[or].readValueFromPointer(jt+cr),cr+=ie[or].argPackAdvance;var mr=Q===1?io(Ot,Oe):Ot.apply(lt,Oe);return gu(he,St,mr)},Ge=`methodCaller<(${ie.map(lt=>lt.name).join(", ")}) => ${he.name}>`;return Jd(st(Ge,Fe))};function os(O){O>>>=0;var j=Z.toValue(O);Ba(j),is(O)}function Hh(O,j){O>>>=0,j>>>=0,O=yl(O,"_emval_take_value");var Q=O.readValueFromPointer(j);return Z.toHandle(Q)}var Qf=O=>O%4===0&&(O%100!==0||O%400===0),eh=[0,31,60,91,121,152,182,213,244,274,305,335],Uh=[0,31,59,90,120,151,181,212,243,273,304,334],zu=O=>{var j=Qf(O.getFullYear()),Q=j?eh:Uh,ie=Q[O.getMonth()]+O.getDate()-1;return ie};function th(O,j,Q){var ie=_t(O,j);Q>>>=0;var he=new Date(ie*1e3);D[Q>>>2>>>0]=he.getSeconds(),D[Q+4>>>2>>>0]=he.getMinutes(),D[Q+8>>>2>>>0]=he.getHours(),D[Q+12>>>2>>>0]=he.getDate(),D[Q+16>>>2>>>0]=he.getMonth(),D[Q+20>>>2>>>0]=he.getFullYear()-1900,D[Q+24>>>2>>>0]=he.getDay();var Oe=zu(he)|0;D[Q+28>>>2>>>0]=Oe,D[Q+36>>>2>>>0]=-(he.getTimezoneOffset()*60);var Fe=new Date(he.getFullYear(),0,1),Ge=new Date(he.getFullYear(),6,1).getTimezoneOffset(),lt=Fe.getTimezoneOffset(),Ot=(Ge!=lt&&he.getTimezoneOffset()==Math.min(lt,Ge))|0;D[Q+32>>>2>>>0]=Ot}var Ug=function(O,j,Q,ie){O>>>=0,j>>>=0,Q>>>=0,ie>>>=0;var he=new Date().getFullYear(),Oe=new Date(he,0,1),Fe=new Date(he,6,1),Ge=Oe.getTimezoneOffset(),lt=Fe.getTimezoneOffset(),Ot=Math.max(Ge,lt);F[O>>>2>>>0]=Ot*60,D[j>>>2>>>0]=+(Ge!=lt);var St=or=>{var mr=or>=0?"-":"+",Vr=Math.abs(or),ei=String(Math.floor(Vr/60)).padStart(2,"0"),ui=String(Vr%60).padStart(2,"0");return`UTC${mr}${ei}${ui}`},jt=St(Ge),cr=St(lt);lt<Ge?(Di(jt,Q,17),Di(cr,ie,17)):(Di(jt,ie,17),Di(cr,Q,17))},Qd=()=>performance.now(),Fp=()=>Date.now(),Lc=O=>O>=0&&O<=3;function Ke(O,j,Q,ie){if(ie>>>=0,!Lc(O))return 28;var he;O===0?he=Fp():he=Qd();var Oe=Math.round(he*1e3*1e3);return it=[Oe>>>0,(Qe=Oe,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[ie>>>2>>>0]=it[0],D[ie+4>>>2>>>0]=it[1],0}var le=[],Se=(O,j)=>{le.length=0;for(var Q;Q=A[O++>>>0];){var ie=Q!=105;ie&=Q!=112,j+=ie&&j%8?4:0,le.push(Q==112?F[j>>>2>>>0]:Q==105?D[j>>>2>>>0]:V[j>>>3>>>0]),j+=ie?8:4}return le},be=(O,j,Q)=>{var ie=Se(j,Q);return xt[O](...ie)};function xe(O,j,Q){return O>>>=0,j>>>=0,Q>>>=0,be(O,j,Q)}var Le=O=>{if(O instanceof $t||O=="unwind")return x;p(1,O)},je=0,ct=()=>rt||je>0,ze=O=>{var j;x=O,ct()||((j=s.onExit)==null||j.call(s,O),P=!0),p(O,new $t(O))},at=(O,j)=>{x=O,ze(O)},tt=at,pt=()=>{if(!ct())try{tt(x)}catch(O){Le(O)}},Ut=O=>{if(!P)try{O(),pt()}catch(j){Le(j)}},vr=(O,j)=>setTimeout(()=>{Ut(O)},j),Ir=(O,j)=>{if(hr.timingMode=O,hr.timingValue=j,!hr.func)return 1;if(hr.running||(hr.running=!0),O==0)hr.scheduler=function(){var Fe=Math.max(0,hr.tickStartTime+j-Qd())|0;setTimeout(hr.runner,Fe)},hr.method="timeout";else if(O==1)hr.scheduler=function(){hr.requestAnimationFrame(hr.runner)},hr.method="rAF";else if(O==2){if(typeof hr.setImmediate>"u")if(typeof setImmediate>"u"){var Q=[],ie="setimmediate",he=Oe=>{(Oe.data===ie||Oe.data.target===ie)&&(Oe.stopPropagation(),Q.shift()())};addEventListener("message",he,!0),hr.setImmediate=Oe=>{Q.push(Oe),postMessage(ie,"*")}}else hr.setImmediate=setImmediate;hr.scheduler=function(){hr.setImmediate(hr.runner)},hr.method="immediate"}return 0},Nt=(O,j,Q,ie,he)=>{hr.func=O,hr.arg=ie;var Oe=hr.currentlyRunningMainloop;function Fe(){return Oe<hr.currentlyRunningMainloop?(pt(),!1):!0}if(hr.running=!1,hr.runner=function(){if(!P){if(hr.queue.length>0){var lt=hr.queue.shift();if(lt.func(lt.arg),hr.remainingBlockers){var Ot=hr.remainingBlockers,St=Ot%1==0?Ot-1:Math.floor(Ot);lt.counted?hr.remainingBlockers=St:(St=St+.5,hr.remainingBlockers=(8*Ot+St)/9)}if(hr.updateStatus(),!Fe())return;setTimeout(hr.runner,0);return}if(Fe()){if(hr.currentFrameNumber=hr.currentFrameNumber+1|0,hr.timingMode==1&&hr.timingValue>1&&hr.currentFrameNumber%hr.timingValue!=0){hr.scheduler();return}else hr.timingMode==0&&(hr.tickStartTime=Qd());hr.runIter(O),Fe()&&hr.scheduler()}}},he||(j&&j>0?Ir(0,1e3/j):Ir(1,1),hr.scheduler()),Q)throw"unwind"},hr={running:!1,scheduler:null,method:"",currentlyRunningMainloop:0,func:null,arg:0,timingMode:0,timingValue:0,currentFrameNumber:0,queue:[],preMainLoop:[],postMainLoop:[],pause(){hr.scheduler=null,hr.currentlyRunningMainloop++},resume(){hr.currentlyRunningMainloop++;var O=hr.timingMode,j=hr.timingValue,Q=hr.func;hr.func=null,Nt(Q,0,!1,hr.arg,!0),Ir(O,j),hr.scheduler()},updateStatus(){if(s.setStatus){var O=s.statusMessage||"Please wait...",j=hr.remainingBlockers??0,Q=hr.expectedBlockers??0;j?j<Q?s.setStatus("{message} ({expected - remaining}/{expected})"):s.setStatus(O):s.setStatus("")}},init(){s.preMainLoop&&hr.preMainLoop.push(s.preMainLoop),s.postMainLoop&&hr.postMainLoop.push(s.postMainLoop)},runIter(O){if(!P){for(var j of hr.preMainLoop)if(j()===!1)return;Ut(O);for(var Q of hr.postMainLoop)Q()}},nextRAF:0,fakeRequestAnimationFrame(O){var j=Date.now();if(hr.nextRAF===0)hr.nextRAF=j+1e3/60;else for(;j+2>=hr.nextRAF;)hr.nextRAF+=1e3/60;var Q=Math.max(hr.nextRAF-j,0);setTimeout(O,Q)},requestAnimationFrame(O){if(typeof requestAnimationFrame=="function"){requestAnimationFrame(O);return}var j=hr.fakeRequestAnimationFrame;j(O)}},Ao=O=>hr.requestAnimationFrame(()=>{Ut(O)}),ho=function(O,j,Q){O>>>=0,j>>>=0;var ie=()=>Kt(O)(j);Q>=0?vr(ie,Q):Ao(ie)},$l=()=>{hr.pause(),hr.func=null},rh=()=>{rt=!1,je=0},kc=O=>{rh(),tt(O)},ef=()=>!0,tf=()=>4294901760,Mn=O=>{var j=C.buffer,Q=(O-j.byteLength+65535)/65536|0;try{return C.grow(Q),z(),1}catch{}};function ya(O){O>>>=0;var j=A.length,Q=tf();if(O>Q)return!1;for(var ie=1;ie<=4;ie*=2){var he=j*(1+.2/ie);he=Math.min(he,O+100663296);var Oe=Math.min(Q,Yr(Math.max(O,he),65536)),Fe=Mn(Oe);if(Fe)return!0}return!1}function Po(O,j,Q){O>>>=0;var ie=Kt(O);Nt(ie,j,Q)}class po{constructor(){Go(this,"allocated",[void 0]);Go(this,"freelist",[])}get(j){return this.allocated[j]}has(j){return this.allocated[j]!==void 0}allocate(j){var Q=this.freelist.pop()||this.allocated.length;return this.allocated[Q]=j,Q}free(j){this.allocated[j]=void 0,this.freelist.push(j)}}var so={openDatabase(O,j,Q,ie){try{var he=indexedDB.open(O,j)}catch(Oe){return ie(Oe)}he.onupgradeneeded=Oe=>{var Fe=Oe.target.result;Fe.objectStoreNames.contains("FILES")&&Fe.deleteObjectStore("FILES"),Fe.createObjectStore("FILES")},he.onsuccess=Oe=>Q(Oe.target.result),he.onerror=ie},init(){so.xhrs=new po;var O=Q=>{so.dbInstance=Q,Pe()},j=()=>{so.dbInstance=!1,Pe()};Ae(),so.openDatabase("emscripten_filesystem",1,O,j)}};function _l(O,j,Q,ie,he){var Oe=F[O+8>>>2>>>0];if(!Oe){Q(O,0,"no url specified!");return}var Fe=fr(Oe),Ge=O+108,lt=fr(Ge+0);lt||(lt="GET");var Ot=F[Ge+56>>>2>>>0],St=F[Ge+68>>>2>>>0],jt=F[Ge+72>>>2>>>0],cr=F[Ge+76>>>2>>>0],or=F[Ge+80>>>2>>>0],mr=F[Ge+84>>>2>>>0],Vr=F[Ge+88>>>2>>>0],ei=F[Ge+52>>>2>>>0],ui=!!(ei&1),Ei=!!(ei&2),jr=!!(ei&64),cn=St?fr(St):void 0,ji=jt?fr(jt):void 0,Kr=new XMLHttpRequest;if(Kr.withCredentials=!!A[Ge+60>>>0],Kr.open(lt,Fe,!jr,cn,ji),jr||(Kr.timeout=Ot),Kr.url_=Fe,Kr.responseType="arraybuffer",or){var Ai=fr(or);Kr.overrideMimeType(Ai)}if(cr)for(;;){var qa=F[cr>>>2>>>0];if(!qa)break;var sa=F[cr+4>>>2>>>0];if(!sa)break;cr+=8;var No=fr(qa),al=fr(sa);Kr.setRequestHeader(No,al)}var pn=so.xhrs.allocate(Kr);F[O>>>2>>>0]=pn;var sl=mr&&Vr?A.slice(mr,mr+Vr):null;function Hs(){var In=0,dc=0;Kr.response&&ui&&F[O+12>>>2>>>0]===0&&(dc=Kr.response.byteLength),dc>0&&(In=Ol(dc),A.set(new Uint8Array(Kr.response),In>>>0)),F[O+12>>>2>>>0]=In,as(O+16,dc),as(O+24,0);var ss=Kr.response?Kr.response.byteLength:0;ss&&as(O+32,ss),R[O+40>>>1>>>0]=Kr.readyState,R[O+42>>>1>>>0]=Kr.status,Kr.statusText&&Di(Kr.statusText,O+44,64)}Kr.onload=In=>{so.xhrs.has(pn)&&(Hs(),Kr.status>=200&&Kr.status<300?j==null||j(O,Kr,In):Q==null||Q(O,Kr,In))},Kr.onerror=In=>{so.xhrs.has(pn)&&(Hs(),Q==null||Q(O,Kr,In))},Kr.ontimeout=In=>{so.xhrs.has(pn)&&(Q==null||Q(O,Kr,In))},Kr.onprogress=In=>{if(so.xhrs.has(pn)){var dc=ui&&Ei&&Kr.response?Kr.response.byteLength:0,ss=0;dc>0&&ui&&Ei&&(ss=Ol(dc),A.set(new Uint8Array(Kr.response),ss>>>0)),F[O+12>>>2>>>0]=ss,as(O+16,dc),as(O+24,In.loaded-dc),as(O+32,In.total),R[O+40>>>1>>>0]=Kr.readyState,Kr.readyState>=3&&Kr.status===0&&In.loaded>0&&(Kr.status=200),R[O+42>>>1>>>0]=Kr.status,Kr.statusText&&Di(Kr.statusText,O+44,64),ie==null||ie(O,Kr,In),ss&&Cs(ss)}},Kr.onreadystatechange=In=>{so.xhrs.has(pn)&&(R[O+40>>>1>>>0]=Kr.readyState,Kr.readyState>=2&&(R[O+42>>>1>>>0]=Kr.status),he==null||he(O,Kr,In))};try{Kr.send(sl)}catch(In){Q==null||Q(O,Kr,In)}}var as=(O,j)=>{F[O>>>2>>>0]=j;var Q=F[O>>>2>>>0];F[O+4>>>2>>>0]=(j-Q)/4294967296};function rf(O,j,Q,ie,he){if(!O){he(j,0,"IndexedDB not available!");return}var Oe=j+108,Fe=F[Oe+64>>>2>>>0];Fe||(Fe=F[j+8>>>2>>>0]);var Ge=fr(Fe);try{var lt=O.transaction(["FILES"],"readwrite"),Ot=lt.objectStore("FILES"),St=Ot.put(Q,Ge);St.onsuccess=jt=>{R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=200,Di("OK",j+44,64),ie(j,0,Ge)},St.onerror=jt=>{R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=413,Di("Payload Too Large",j+44,64),he(j,0,jt)}}catch(jt){he(j,0,jt)}}function Or(O,j,Q,ie){if(!O){ie(j,0,"IndexedDB not available!");return}var he=j+108,Oe=F[he+64>>>2>>>0];Oe||(Oe=F[j+8>>>2>>>0]);var Fe=fr(Oe);try{var Ge=O.transaction(["FILES"],"readonly"),lt=Ge.objectStore("FILES"),Ot=lt.get(Fe);Ot.onsuccess=St=>{if(St.target.result){var jt=St.target.result,cr=jt.byteLength||jt.length,or=Ol(cr);A.set(new Uint8Array(jt),or>>>0),F[j+12>>>2>>>0]=or,as(j+16,cr),as(j+24,0),as(j+32,cr),R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=200,Di("OK",j+44,64),Q(j,0,jt)}else R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=404,Di("Not Found",j+44,64),ie(j,0,"no data")},Ot.onerror=St=>{R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=404,Di("Not Found",j+44,64),ie(j,0,St)}}catch(St){ie(j,0,St)}}function nf(O,j,Q,ie){if(!O){ie(j,0,"IndexedDB not available!");return}var he=j+108,Oe=F[he+64>>>2>>>0];Oe||(Oe=F[j+8>>>2>>>0]);var Fe=fr(Oe);try{var Ge=O.transaction(["FILES"],"readwrite"),lt=Ge.objectStore("FILES"),Ot=lt.delete(Fe);Ot.onsuccess=St=>{var jt=St.target.result;F[j+12>>>2>>>0]=0,as(j+16,0),as(j+24,0),as(j+32,0),R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=200,Di("OK",j+44,64),Q(j,0,jt)},Ot.onerror=St=>{R[j+40>>>1>>>0]=4,R[j+42>>>1>>>0]=404,Di("Not Found",j+44,64),ie(j,0,St)}}catch(St){ie(j,0,St)}}function Bp(O,j,Q,ie,he){O>>>=0;var Oe=O+108,Fe=F[Oe+36>>>2>>>0],Ge=F[Oe+40>>>2>>>0],lt=F[Oe+44>>>2>>>0],Ot=F[Oe+48>>>2>>>0],St=F[Oe+52>>>2>>>0],jt=!!(St&64);function cr(No){jt?No():Ut(No)}var or=(No,al,pn)=>{cr(()=>{Fe?Kt(Fe)(No):j==null||j(No)})},mr=(No,al,pn)=>{cr(()=>{lt?Kt(lt)(No):ie==null||ie(No)})},Vr=(No,al,pn)=>{cr(()=>{Ge?Kt(Ge)(No):Q==null||Q(No)})},ei=(No,al,pn)=>{cr(()=>{Ot?Kt(Ot)(No):he==null||he(No)})},ui=(No,al,pn)=>{_l(No,or,Vr,mr,ei)},Ei=(No,al,pn)=>{var sl=(In,dc,ss)=>{cr(()=>{Fe?Kt(Fe)(In):j==null||j(In)})},Hs=(In,dc,ss)=>{cr(()=>{Fe?Kt(Fe)(In):j==null||j(In)})};rf(so.dbInstance,No,al.response,sl,Hs)},jr=(No,al,pn)=>{_l(No,Ei,Vr,mr,ei)},cn=fr(Oe+0),ji=!!(St&16),Kr=!!(St&4),Ai=!!(St&32);if(cn==="EM_IDB_STORE"){var qa=F[Oe+84>>>2>>>0],sa=F[Oe+88>>>2>>>0];rf(so.dbInstance,O,A.slice(qa,qa+sa),or,Vr)}else if(cn==="EM_IDB_DELETE")nf(so.dbInstance,O,or,Vr);else if(!ji)Or(so.dbInstance,O,or,Ai?Vr:Kr?jr:ui);else if(!Ai)_l(O,Kr?Ei:or,Vr,mr,ei);else return 0;return O}var Rr,zg=O=>{var j=O.getExtension("ANGLE_instanced_arrays");if(j)return O.vertexAttribDivisor=(Q,ie)=>j.vertexAttribDivisorANGLE(Q,ie),O.drawArraysInstanced=(Q,ie,he,Oe)=>j.drawArraysInstancedANGLE(Q,ie,he,Oe),O.drawElementsInstanced=(Q,ie,he,Oe,Fe)=>j.drawElementsInstancedANGLE(Q,ie,he,Oe,Fe),1},zh=O=>{var j=O.getExtension("OES_vertex_array_object");if(j)return O.createVertexArray=()=>j.createVertexArrayOES(),O.deleteVertexArray=Q=>j.deleteVertexArrayOES(Q),O.bindVertexArray=Q=>j.bindVertexArrayOES(Q),O.isVertexArray=Q=>j.isVertexArrayOES(Q),1},Ic=O=>{var j=O.getExtension("WEBGL_draw_buffers");if(j)return O.drawBuffers=(Q,ie)=>j.drawBuffersWEBGL(Q,ie),1},qv=O=>!!(O.dibvbi=O.getExtension("WEBGL_draw_instanced_base_vertex_base_instance")),bs=O=>!!(O.mdibvbi=O.getExtension("WEBGL_multi_draw_instanced_base_vertex_base_instance")),Nc=O=>!!(O.extPolygonOffsetClamp=O.getExtension("EXT_polygon_offset_clamp")),Wl=O=>!!(O.extClipControl=O.getExtension("EXT_clip_control")),Tr=O=>!!(O.webglPolygonMode=O.getExtension("WEBGL_polygon_mode")),Ln=O=>!!(O.multiDrawWebgl=O.getExtension("WEBGL_multi_draw")),vd=O=>{var j=["ANGLE_instanced_arrays","EXT_blend_minmax","EXT_disjoint_timer_query","EXT_frag_depth","EXT_shader_texture_lod","EXT_sRGB","OES_element_index_uint","OES_fbo_render_mipmap","OES_standard_derivatives","OES_texture_float","OES_texture_half_float","OES_texture_half_float_linear","OES_vertex_array_object","WEBGL_color_buffer_float","WEBGL_depth_texture","WEBGL_draw_buffers","EXT_color_buffer_float","EXT_conservative_depth","EXT_disjoint_timer_query_webgl2","EXT_texture_norm16","NV_shader_noperspective_interpolation","WEBGL_clip_cull_distance","EXT_clip_control","EXT_color_buffer_half_float","EXT_depth_clamp","EXT_float_blend","EXT_polygon_offset_clamp","EXT_texture_compression_bptc","EXT_texture_compression_rgtc","EXT_texture_filter_anisotropic","KHR_parallel_shader_compile","OES_texture_float_linear","WEBGL_blend_func_extended","WEBGL_compressed_texture_astc","WEBGL_compressed_texture_etc","WEBGL_compressed_texture_etc1","WEBGL_compressed_texture_s3tc","WEBGL_compressed_texture_s3tc_srgb","WEBGL_debug_renderer_info","WEBGL_debug_shaders","WEBGL_lose_context","WEBGL_multi_draw","WEBGL_polygon_mode"];return(O.getSupportedExtensions()||[]).filter(Q=>j.includes(Q))},_r={counter:1,buffers:[],programs:[],framebuffers:[],renderbuffers:[],textures:[],shaders:[],vaos:[],contexts:[],offscreenCanvases:{},queries:[],samplers:[],transformFeedbacks:[],syncs:[],stringCache:{},stringiCache:{},unpackAlignment:4,unpackRowLength:0,recordError:O=>{_r.lastError||(_r.lastError=O)},getNewId:O=>{for(var j=_r.counter++,Q=O.length;Q<j;Q++)O[Q]=null;return j},genObject:(O,j,Q,ie)=>{for(var he=0;he<O;he++){var Oe=Rr[Q](),Fe=Oe&&_r.getNewId(ie);Oe?(Oe.name=Fe,ie[Fe]=Oe):_r.recordError(1282),D[j+he*4>>>2>>>0]=Fe}},getSource:(O,j,Q,ie)=>{for(var he="",Oe=0;Oe<j;++Oe){var Fe=ie?F[ie+Oe*4>>>2>>>0]:void 0;he+=fr(F[Q+Oe*4>>>2>>>0],Fe)}return he},createContext:(O,j)=>{var Q=j.majorVersion>1?O.getContext("webgl2",j):O.getContext("webgl",j);if(!Q)return 0;var ie=_r.registerContext(Q,j);return ie},registerContext:(O,j)=>{var Q=_r.getNewId(_r.contexts),ie={handle:Q,attributes:j,version:j.majorVersion,GLctx:O};return O.canvas&&(O.canvas.GLctxObject=ie),_r.contexts[Q]=ie,(typeof j.enableExtensionsByDefault>"u"||j.enableExtensionsByDefault)&&_r.initExtensions(ie),Q},makeContextCurrent:O=>{var j;return _r.currentContext=_r.contexts[O],s.ctx=Rr=(j=_r.currentContext)==null?void 0:j.GLctx,!(O&&!Rr)},getContext:O=>_r.contexts[O],deleteContext:O=>{_r.currentContext===_r.contexts[O]&&(_r.currentContext=null),typeof _n=="object"&&_n.removeAllHandlersOnTarget(_r.contexts[O].GLctx.canvas),_r.contexts[O]&&_r.contexts[O].GLctx.canvas&&(_r.contexts[O].GLctx.canvas.GLctxObject=void 0),_r.contexts[O]=null},initExtensions:O=>{if(O||(O=_r.currentContext),!O.initExtensionsDone){O.initExtensionsDone=!0;var j=O.GLctx;Ln(j),Nc(j),Wl(j),Tr(j),zg(j),zh(j),Ic(j),qv(j),bs(j),O.version>=2&&(j.disjointTimerQueryExt=j.getExtension("EXT_disjoint_timer_query_webgl2")),(O.version<2||!j.disjointTimerQueryExt)&&(j.disjointTimerQueryExt=j.getExtension("EXT_disjoint_timer_query")),vd(j).forEach(Q=>{!Q.includes("lose_context")&&!Q.includes("debug")&&j.getExtension(Q)})}}},_n={memcpy(O,j,Q){E.set(E.subarray(j>>>0,j+Q>>>0),O>>>0)},removeAllEventListeners(){for(;_n.eventHandlers.length;)_n._removeHandler(_n.eventHandlers.length-1);_n.deferredCalls=[]},inEventHandler:0,deferredCalls:[],deferCall(O,j,Q){function ie(Oe,Fe){if(Oe.length!=Fe.length)return!1;for(var Ge in Oe)if(Oe[Ge]!=Fe[Ge])return!1;return!0}for(var he of _n.deferredCalls)if(he.targetFunction==O&&ie(he.argsList,Q))return;_n.deferredCalls.push({targetFunction:O,precedence:j,argsList:Q}),_n.deferredCalls.sort((Oe,Fe)=>Oe.precedence<Fe.precedence)},removeDeferredCalls(O){_n.deferredCalls=_n.deferredCalls.filter(j=>j.targetFunction!=O)},canPerformEventHandlerRequests(){return navigator.userActivation?navigator.userActivation.isActive:_n.inEventHandler&&_n.currentEventHandler.allowsDeferredCalls},runDeferredCalls(){if(_n.canPerformEventHandlerRequests()){var O=_n.deferredCalls;_n.deferredCalls=[];for(var j of O)j.targetFunction(...j.argsList)}},eventHandlers:[],removeAllHandlersOnTarget:(O,j)=>{for(var Q=0;Q<_n.eventHandlers.length;++Q)_n.eventHandlers[Q].target==O&&(!j||j==_n.eventHandlers[Q].eventTypeString)&&_n._removeHandler(Q--)},_removeHandler(O){var j=_n.eventHandlers[O];j.target.removeEventListener(j.eventTypeString,j.eventListenerFunc,j.useCapture),_n.eventHandlers.splice(O,1)},registerOrRemoveHandler(O){if(!O.target)return-4;if(O.callbackfunc)O.eventListenerFunc=function(Q){++_n.inEventHandler,_n.currentEventHandler=O,_n.runDeferredCalls(),O.handlerFunc(Q),_n.runDeferredCalls(),--_n.inEventHandler},O.target.addEventListener(O.eventTypeString,O.eventListenerFunc,O.useCapture),_n.eventHandlers.push(O);else for(var j=0;j<_n.eventHandlers.length;++j)_n.eventHandlers[j].target==O.target&&_n.eventHandlers[j].eventTypeString==O.eventTypeString&&_n._removeHandler(j--);return 0},getNodeNameForTarget(O){return O?O==window?"#window":O==screen?"#screen":(O==null?void 0:O.nodeName)||"":""},fullscreenEnabled(){return document.fullscreenEnabled||document.webkitFullscreenEnabled}},$h=["default","low-power","high-performance"],Xv=O=>O>2?fr(O):O,Pl=[0,document,window],ih=O=>{O=Xv(O);var j=Pl[O]||document.querySelector(O);return j},nh=ih;function ma(O,j){O>>>=0,j>>>=0;var Q=j>>>2,ie=D[Q+2>>>0],he={alpha:!!E[j+0>>>0],depth:!!E[j+1>>>0],stencil:!!E[j+2>>>0],antialias:!!E[j+3>>>0],premultipliedAlpha:!!E[j+4>>>0],preserveDrawingBuffer:!!E[j+5>>>0],powerPreference:$h[ie],failIfMajorPerformanceCaveat:!!E[j+12>>>0],majorVersion:D[Q+4>>>0],minorVersion:D[Q+5>>>0],enableExtensionsByDefault:E[j+24>>>0],explicitSwapControl:E[j+25>>>0],proxyContextToMainThread:D[Q+7>>>0],renderViaOffscreenBackBuffer:E[j+32>>>0]},Oe=nh(O);if(!Oe||he.explicitSwapControl)return 0;var Fe=_r.createContext(Oe,he);return Fe}var ja=ma;function Cl(){return _r.currentContext?_r.currentContext.handle:0}var vu=Cl;function Gl(O){O>>>=0;var j=_r.makeContextCurrent(O);return j?0:-5}var yu={},mu=()=>h||"./this.program",Ss=()=>{if(!Ss.strings){var O=(typeof navigator=="object"&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",j={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:O,_:mu()};for(var Q in yu)yu[Q]===void 0?delete j[Q]:j[Q]=yu[Q];var ie=[];for(var Q in j)ie.push(`${Q}=${j[Q]}`);Ss.strings=ie}return Ss.strings},jp=(O,j)=>{for(var Q=0;Q<O.length;++Q)E[j++>>>0]=O.charCodeAt(Q);E[j>>>0]=0},yd=function(O,j){O>>>=0,j>>>=0;var Q=0;return Ss().forEach((ie,he)=>{var Oe=j+Q;F[O+he*4>>>2>>>0]=Oe,jp(ie,Oe),Q+=ie.length+1}),0},of=function(O,j){O>>>=0,j>>>=0;var Q=Ss();F[O>>>2>>>0]=Q.length;var ie=0;return Q.forEach(he=>ie+=he.length+1),F[j>>>2>>>0]=ie,0};function oh(O){try{var j=Yt.getStreamFromFD(O);return ce.close(j),0}catch(Q){if(typeof ce>"u"||Q.name!=="ErrnoError")throw Q;return Q.errno}}var Va=(O,j,Q,ie)=>{for(var he=0,Oe=0;Oe<Q;Oe++){var Fe=F[j>>>2>>>0],Ge=F[j+4>>>2>>>0];j+=8;var lt=ce.read(O,E,Fe,Ge,ie);if(lt<0)return-1;if(he+=lt,lt<Ge)break}return he};function lo(O,j,Q,ie){j>>>=0,Q>>>=0,ie>>>=0;try{var he=Yt.getStreamFromFD(O),Oe=Va(he,j,Q);return F[ie>>>2>>>0]=Oe,0}catch(Fe){if(typeof ce>"u"||Fe.name!=="ErrnoError")throw Fe;return Fe.errno}}function kn(O,j,Q,ie,he){var Oe=_t(j,Q);he>>>=0;try{if(isNaN(Oe))return 61;var Fe=Yt.getStreamFromFD(O);return ce.llseek(Fe,Oe,ie),it=[Fe.position>>>0,(Qe=Fe.position,+Math.abs(Qe)>=1?Qe>0?+Math.floor(Qe/4294967296)>>>0:~~+Math.ceil((Qe-+(~~Qe>>>0))/4294967296)>>>0:0)],D[he>>>2>>>0]=it[0],D[he+4>>>2>>>0]=it[1],Fe.getdents&&Oe===0&&ie===0&&(Fe.getdents=null),0}catch(Ge){if(typeof ce>"u"||Ge.name!=="ErrnoError")throw Ge;return Ge.errno}}var md=(O,j,Q,ie)=>{for(var he=0,Oe=0;Oe<Q;Oe++){var Fe=F[j>>>2>>>0],Ge=F[j+4>>>2>>>0];j+=8;var lt=ce.write(O,E,Fe,Ge,ie);if(lt<0)return-1;if(he+=lt,lt<Ge)break}return he};function bu(O,j,Q,ie){j>>>=0,Q>>>=0,ie>>>=0;try{var he=Yt.getStreamFromFD(O),Oe=md(he,j,Q);return F[ie>>>2>>>0]=Oe,0}catch(Fe){if(typeof ce>"u"||Fe.name!=="ErrnoError")throw Fe;return Fe.errno}}var $g=O=>Rr.activeTexture(O),bd=(O,j)=>{Rr.attachShader(_r.programs[O],_r.shaders[j])};function Wh(O,j,Q){Q>>>=0,Rr.bindAttribLocation(_r.programs[O],j,fr(Q))}var ah=(O,j)=>{O==35051?Rr.currentPixelPackBufferBinding=j:O==35052&&(Rr.currentPixelUnpackBufferBinding=j),Rr.bindBuffer(O,_r.buffers[j])},af=(O,j,Q)=>{Rr.bindBufferBase(O,j,_r.buffers[Q])},nt=(O,j)=>{Rr.bindFramebuffer(O,_r.framebuffers[j])},Sd=(O,j)=>{Rr.bindTexture(O,_r.textures[j])},_d=(O,j,Q,ie)=>Rr.blendColor(O,j,Q,ie),Tl=O=>Rr.blendEquation(O),nn=(O,j,Q,ie)=>Rr.blendFuncSeparate(O,j,Q,ie);function Fc(O,j,Q,ie){j>>>=0,Q>>>=0,Rr.bufferData(O,Q?A.subarray(Q>>>0,Q+j>>>0):j,ie)}function Pd(O,j,Q,ie){j>>>=0,Q>>>=0,ie>>>=0,Rr.bufferSubData(O,j,A.subarray(ie>>>0,ie+Q>>>0))}var Bc=O=>Rr.checkFramebufferStatus(O),jc=O=>Rr.clear(O),Wg=(O,j,Q,ie)=>Rr.clearColor(O,j,Q,ie),sh=(O,j,Q,ie)=>{Rr.colorMask(!!O,!!j,!!Q,!!ie)},Vp=O=>{Rr.compileShader(_r.shaders[O])};function sf(O,j,Q,ie,he,Oe,Fe,Ge){if(Ge>>>=0,_r.currentContext.version>=2&&(Rr.currentPixelUnpackBufferBinding||!Fe)){Rr.compressedTexImage2D(O,j,Q,ie,he,Oe,Fe,Ge);return}Rr.compressedTexImage2D(O,j,Q,ie,he,Oe,A.subarray(Ge>>>0,Ge+Fe>>>0))}var _s=()=>{var O=_r.getNewId(_r.programs),j=Rr.createProgram();return j.name=O,j.maxUniformLength=j.maxAttributeLength=j.maxUniformBlockNameLength=0,j.uniformIdCounter=1,_r.programs[O]=j,O},Su=O=>{var j=_r.getNewId(_r.shaders);return _r.shaders[j]=Rr.createShader(O),j},Kv=O=>Rr.cullFace(O);function Fm(O,j){j>>>=0;for(var Q=0;Q<O;Q++){var ie=D[j+Q*4>>>2>>>0],he=_r.buffers[ie];he&&(Rr.deleteBuffer(he),he.name=0,_r.buffers[ie]=null,ie==Rr.currentPixelPackBufferBinding&&(Rr.currentPixelPackBufferBinding=0),ie==Rr.currentPixelUnpackBufferBinding&&(Rr.currentPixelUnpackBufferBinding=0))}}function Bm(O,j){j>>>=0;for(var Q=0;Q<O;++Q){var ie=D[j+Q*4>>>2>>>0],he=_r.framebuffers[ie];he&&(Rr.deleteFramebuffer(he),he.name=0,_r.framebuffers[ie]=null)}}var jm=O=>{if(O){var j=_r.programs[O];if(!j){_r.recordError(1281);return}Rr.deleteProgram(j),j.name=0,_r.programs[O]=null}};function Ha(O,j){j>>>=0;for(var Q=0;Q<O;Q++){var ie=D[j+Q*4>>>2>>>0],he=_r.renderbuffers[ie];he&&(Rr.deleteRenderbuffer(he),he.name=0,_r.renderbuffers[ie]=null)}}var $u=O=>{if(O){var j=_r.shaders[O];if(!j){_r.recordError(1281);return}Rr.deleteShader(j),_r.shaders[O]=null}};function Gh(O,j){j>>>=0;for(var Q=0;Q<O;Q++){var ie=D[j+Q*4>>>2>>>0],he=_r.textures[ie];he&&(Rr.deleteTexture(he),he.name=0,_r.textures[ie]=null)}}var Yh=O=>Rr.depthFunc(O),Gg=O=>{Rr.depthMask(!!O)},lh=(O,j)=>{Rr.detachShader(_r.programs[O],_r.shaders[j])},uh=O=>Rr.disable(O),lf=O=>{Rr.disableVertexAttribArray(O)},Zv=(O,j,Q)=>{Rr.drawArrays(O,j,Q)};function Vm(O,j,Q,ie){ie>>>=0,Rr.drawElements(O,j,Q,ie)}function _u(O,j,Q,ie,he){ie>>>=0,Rr.drawElementsInstanced(O,j,Q,ie,he)}var uf=O=>Rr.enable(O),Yg=O=>{Rr.enableVertexAttribArray(O)},Hp=(O,j,Q,ie,he)=>{Rr.framebufferTexture2D(O,j,Q,_r.textures[ie],he)},Jv=O=>Rr.frontFace(O);function ch(O,j){j>>>=0,_r.genObject(O,j,"createBuffer",_r.buffers)}function Up(O,j){j>>>=0,_r.genObject(O,j,"createFramebuffer",_r.framebuffers)}function qh(O,j){j>>>=0,_r.genObject(O,j,"createTexture",_r.textures)}var Xh=O=>Rr.generateMipmap(O),Qv=(O,j,Q,ie,he,Oe,Fe,Ge)=>{j=_r.programs[j];var lt=Rr[O](j,Q);if(lt){var Ot=Ge&&Di(lt.name,Ge,ie);he&&(D[he>>>2>>>0]=Ot),Oe&&(D[Oe>>>2>>>0]=lt.size),Fe&&(D[Fe>>>2>>>0]=lt.type)}};function zp(O,j,Q,ie,he,Oe,Fe){return ie>>>=0,he>>>=0,Oe>>>=0,Fe>>>=0,Qv("getActiveUniform",O,j,Q,ie,he,Oe,Fe)}var Pu=()=>{var O=vd(Rr);return O=O.concat(O.map(j=>"GL_"+j)),O},lc=(O,j,Q)=>{if(!j){_r.recordError(1281);return}var ie=void 0;switch(O){case 36346:ie=1;break;case 36344:return;case 34814:case 36345:ie=0;break;case 34466:var he=Rr.getParameter(34467);ie=he?he.length:0;break;case 33309:if(_r.currentContext.version<2){_r.recordError(1282);return}ie=Pu().length;break;case 33307:case 33308:if(_r.currentContext.version<2){_r.recordError(1280);return}ie=O==33307?3:0;break}if(ie===void 0){var Oe=Rr.getParameter(O);switch(typeof Oe){case"number":ie=Oe;break;case"boolean":ie=Oe?1:0;break;case"string":_r.recordError(1280);return;case"object":if(Oe===null)switch(O){case 34964:case 35725:case 34965:case 36006:case 36007:case 32873:case 34229:case 36662:case 36663:case 35053:case 35055:case 36010:case 35097:case 35869:case 32874:case 36389:case 35983:case 35368:case 34068:{ie=0;break}default:{_r.recordError(1280);return}}else if(Oe instanceof Float32Array||Oe instanceof Uint32Array||Oe instanceof Int32Array||Oe instanceof Array){for(var Fe=0;Fe<Oe.length;++Fe)switch(Q){case 0:D[j+Fe*4>>>2>>>0]=Oe[Fe];break;case 2:I[j+Fe*4>>>2>>>0]=Oe[Fe];break;case 4:E[j+Fe>>>0]=Oe[Fe]?1:0;break}return}else try{ie=Oe.name|0}catch(Ge){_r.recordError(1280),S(`GL_INVALID_ENUM in glGet${Q}v: Unknown object returned from WebGL getParameter(${O})! (error: ${Ge})`);return}break;default:_r.recordError(1280),S(`GL_INVALID_ENUM in glGet${Q}v: Native code calling glGet${Q}v(${O}) and it returns ${Oe} of type ${typeof Oe}!`);return}}switch(Q){case 1:as(j,ie);break;case 0:D[j>>>2>>>0]=ie;break;case 2:I[j>>>2>>>0]=ie;break;case 4:E[j>>>0]=ie?1:0;break}};function ey(O,j){return j>>>=0,lc(O,j,0)}function qg(O,j,Q,ie){Q>>>=0,ie>>>=0;var he=Rr.getProgramInfoLog(_r.programs[O]);he===null&&(he="(unknown error)");var Oe=j>0&&ie?Di(he,ie,j):0;Q&&(D[Q>>>2>>>0]=Oe)}function Vc(O,j,Q){if(Q>>>=0,!Q){_r.recordError(1281);return}if(O>=_r.counter){_r.recordError(1281);return}if(O=_r.programs[O],j==35716){var ie=Rr.getProgramInfoLog(O);ie===null&&(ie="(unknown error)"),D[Q>>>2>>>0]=ie.length+1}else if(j==35719){if(!O.maxUniformLength)for(var he=Rr.getProgramParameter(O,35718),Oe=0;Oe<he;++Oe)O.maxUniformLength=Math.max(O.maxUniformLength,Rr.getActiveUniform(O,Oe).name.length+1);D[Q>>>2>>>0]=O.maxUniformLength}else if(j==35722){if(!O.maxAttributeLength)for(var Fe=Rr.getProgramParameter(O,35721),Oe=0;Oe<Fe;++Oe)O.maxAttributeLength=Math.max(O.maxAttributeLength,Rr.getActiveAttrib(O,Oe).name.length+1);D[Q>>>2>>>0]=O.maxAttributeLength}else if(j==35381){if(!O.maxUniformBlockNameLength)for(var Ge=Rr.getProgramParameter(O,35382),Oe=0;Oe<Ge;++Oe)O.maxUniformBlockNameLength=Math.max(O.maxUniformBlockNameLength,Rr.getActiveUniformBlockName(O,Oe).length+1);D[Q>>>2>>>0]=O.maxUniformBlockNameLength}else D[Q>>>2>>>0]=Rr.getProgramParameter(O,j)}function Yl(O,j,Q,ie){Q>>>=0,ie>>>=0;var he=Rr.getShaderInfoLog(_r.shaders[O]);he===null&&(he="(unknown error)");var Oe=j>0&&ie?Di(he,ie,j):0;Q&&(D[Q>>>2>>>0]=Oe)}function dh(O,j,Q){if(Q>>>=0,!Q){_r.recordError(1281);return}if(j==35716){var ie=Rr.getShaderInfoLog(_r.shaders[O]);ie===null&&(ie="(unknown error)");var he=ie?ie.length+1:0;D[Q>>>2>>>0]=he}else if(j==35720){var Oe=Rr.getShaderSource(_r.shaders[O]),Fe=Oe?Oe.length+1:0;D[Q>>>2>>>0]=Fe}else D[Q>>>2>>>0]=Rr.getShaderParameter(_r.shaders[O],j)}var xl=O=>{var j=nr(O)+1,Q=Ol(j);return Q&&Di(O,Q,j),Q};function Vs(O){var j=_r.stringCache[O];if(!j){switch(O){case 7939:j=xl(Pu().join(" "));break;case 7936:case 7937:case 37445:case 37446:var Q=Rr.getParameter(O);Q||_r.recordError(1280),j=Q?xl(Q):0;break;case 7938:var ie=Rr.getParameter(7938),he=`OpenGL ES 2.0 (${ie})`;_r.currentContext.version>=2&&(he=`OpenGL ES 3.0 (${ie})`),j=xl(he);break;case 35724:var Oe=Rr.getParameter(35724),Fe=/^WebGL GLSL ES ([0-9]\.[0-9][0-9]?)(?:$| .*)/,Ge=Oe.match(Fe);Ge!==null&&(Ge[1].length==3&&(Ge[1]=Ge[1]+"0"),Oe=`OpenGL ES GLSL ES ${Ge[1]} (${Oe})`),j=xl(Oe);break;default:_r.recordError(1280)}_r.stringCache[O]=j}return j}function ty(O,j){return j>>>=0,Rr.getUniformBlockIndex(_r.programs[O],fr(j))}var Cd=O=>parseInt(O),$p=O=>O.slice(-1)=="]"&&O.lastIndexOf("["),Cu=O=>{var j=O.uniformLocsById,Q=O.uniformSizeAndIdsByName,ie,he;if(!j){O.uniformLocsById=j={},O.uniformArrayNamesById={};var Oe=Rr.getProgramParameter(O,35718);for(ie=0;ie<Oe;++ie){var Fe=Rr.getActiveUniform(O,ie),Ge=Fe.name,lt=Fe.size,Ot=$p(Ge),St=Ot>0?Ge.slice(0,Ot):Ge,jt=O.uniformIdCounter;for(O.uniformIdCounter+=lt,Q[St]=[lt,jt],he=0;he<lt;++he)j[jt]=he,O.uniformArrayNamesById[jt++]=St}}};function uc(O,j){if(j>>>=0,j=fr(j),O=_r.programs[O]){Cu(O);var Q=O.uniformLocsById,ie=0,he=j,Oe=$p(j);Oe>0&&(ie=Cd(j.slice(Oe+1))>>>0,he=j.slice(0,Oe));var Fe=O.uniformSizeAndIdsByName[he];if(Fe&&ie<Fe[0]&&(ie+=Fe[1],Q[ie]=Q[ie]||Rr.getUniformLocation(O,j)))return ie}else _r.recordError(1281);return-1}var Wp=O=>{O=_r.programs[O],Rr.linkProgram(O),O.uniformLocsById=0,O.uniformSizeAndIdsByName={}},Td=(O,j)=>{O==3317?_r.unpackAlignment=j:O==3314&&(_r.unpackRowLength=j),Rr.pixelStorei(O,j)},Tu=(O,j,Q)=>{function ie(Fe,Ge){return Fe+Ge-1&-Ge}var he=(_r.unpackRowLength||O)*Q,Oe=ie(he,_r.unpackAlignment);return j*Oe},fh=O=>{var j={5:3,6:4,8:2,29502:3,29504:4,26917:2,26918:2,29846:3,29847:4};return j[O-6402]||1},Gp=O=>(O-=5120,O==0?E:O==1?A:O==2?R:O==4?D:O==6?I:O==5||O==28922||O==28520||O==30779||O==30782?F:M),Ua=(O,j)=>O>>>31-Math.clz32(j.BYTES_PER_ELEMENT),xd=(O,j,Q,ie,he,Oe)=>{var Fe=Gp(O),Ge=fh(j)*Fe.BYTES_PER_ELEMENT,lt=Tu(Q,ie,Ge);return Fe.subarray(Ua(he,Fe)>>>0,Ua(he+lt,Fe)>>>0)};function hh(O,j,Q,ie,he,Oe,Fe){if(Fe>>>=0,_r.currentContext.version>=2&&Rr.currentPixelPackBufferBinding){Rr.readPixels(O,j,Q,ie,he,Oe,Fe);return}var Ge=xd(Oe,he,Q,ie,Fe);if(!Ge){_r.recordError(1280);return}Rr.readPixels(O,j,Q,ie,he,Oe,Ge)}var Wu=(O,j,Q,ie)=>Rr.scissor(O,j,Q,ie);function Yp(O,j,Q,ie){Q>>>=0,ie>>>=0;var he=_r.getSource(O,j,Q,ie);Rr.shaderSource(_r.shaders[O],he)}function Hc(O,j,Q,ie,he,Oe,Fe,Ge,lt){if(lt>>>=0,_r.currentContext.version>=2&&Rr.currentPixelUnpackBufferBinding){Rr.texImage2D(O,j,Q,ie,he,Oe,Fe,Ge,lt);return}var Ot=lt?xd(Ge,Fe,ie,he,lt):null;Rr.texImage2D(O,j,Q,ie,he,Oe,Fe,Ge,Ot)}var cc=(O,j,Q)=>Rr.texParameteri(O,j,Q),Xg=O=>{var j=Rr.currentProgram;if(j){var Q=j.uniformLocsById[O];return typeof Q=="number"&&(j.uniformLocsById[O]=Q=Rr.getUniformLocation(j,j.uniformArrayNamesById[O]+(Q>0?`[${Q}]`:""))),Q}else _r.recordError(1282)},Ps=(O,j)=>{Rr.uniform1i(Xg(O),j)},Kh=(O,j,Q)=>{O=_r.programs[O],Rr.uniformBlockBinding(O,j,Q)},ql=O=>{O=_r.programs[O],Rr.useProgram(O),Rr.currentProgram=O},El=(O,j)=>{Rr.vertexAttribDivisor(O,j)};function Uc(O,j,Q,ie,he,Oe){Oe>>>=0,Rr.vertexAttribPointer(O,j,Q,!!ie,he,Oe)}var ph=(O,j,Q,ie)=>Rr.viewport(O,j,Q,ie),qp=O=>$c(O),wl=O=>{var j=nr(O)+1,Q=qp(j);return Di(O,Q,j),Q},ol=O=>{var j=s["_"+O];return j},Ea=(O,j)=>{E.set(O,j>>>0)},Io=(O,j,Q,ie,he)=>{var Oe={string:mr=>{var Vr=0;return mr!=null&&mr!==0&&(Vr=wl(mr)),Vr},array:mr=>{var Vr=qp(mr.length);return Ea(mr,Vr),Vr}};function Fe(mr){return j==="string"?fr(mr):j==="boolean"?!!mr:mr}var Ge=ol(O),lt=[],Ot=0;if(ie)for(var St=0;St<ie.length;St++){var jt=Oe[Q[St]];jt?(Ot===0&&(Ot=vt()),lt[St]=jt(ie[St])):lt[St]=ie[St]}var cr=Ge(...lt);function or(mr){return Ot!==0&&qe(Ot),Fe(mr)}return cr=or(cr),cr},Al=(O,j,Q,ie)=>{var he=!Q||Q.every(Fe=>Fe==="number"||Fe==="boolean"),Oe=j!=="string";return Oe&&he&&!ie?ol(O):(...Fe)=>Io(O,j,Q,Fe)};ce.createPreloadedFile=xn,ce.staticInit(),rr.doesNotExistError=new ce.ErrnoError(44),rr.doesNotExistError.stack="<generic error, no stack>",si=s.BindingError=class extends Error{constructor(j){super(j),this.name="BindingError"}},ts(),ye=s.PureVirtualError=re(Error,"PureVirtualError"),Ye(),ic=s.InternalError=class extends Error{constructor(j){super(j),this.name="InternalError"}},dd(),et(),Oi=s.UnboundTypeError=re(Error,"UnboundTypeError"),s.requestAnimationFrame=hr.requestAnimationFrame,s.pauseMainLoop=hr.pause,s.resumeMainLoop=hr.resume,hr.init(),so.init();var xi={f:Ht,U:Lr,ib:Cr,jb:zr,gb:fi,lb:to,_:cd,Za:ml,Y:bl,d:ms,e:Bs,g:jg,a:js,c:hd,W:Yd,h:ac,b:Nh,H:Vg,j:Hg,o:gd,k:Zf,X:Ip,D:Rc,Z:Np,Ca:Mc,bb:nl,t:Vh,aa:is,s:ns,$:os,v:Hh,Wa:th,db:Ug,Ya:Ke,K:xe,ba:ho,wa:$l,kb:Fp,mb:kc,Sa:ef,cb:ya,na:Po,La:Bp,J:ja,ha:vu,I:Gl,eb:yd,fb:of,V:oh,hb:lo,Xa:kn,T:bu,ca:wt,ra:$g,P:bd,l:Wh,m:ah,ua:af,r:nt,q:Sd,Ka:_d,Ja:Tl,Ma:nn,w:Fc,da:Pd,L:Bc,Ta:jc,Ua:Wg,Ga:sh,oa:Vp,B:sf,Ba:_s,qa:Su,Qa:Kv,S:Fm,Ea:Bm,Q:jm,Da:Ha,O:$u,Fa:Gh,Na:Yh,Oa:Gg,R:lh,z:uh,Ra:lf,fa:Zv,ga:Vm,ea:_u,y:uf,ka:Yg,E:Hp,Pa:Jv,x:ch,M:Up,C:qh,Va:Xh,xa:zp,p:ey,za:qg,F:Vc,ma:Yl,N:dh,u:Vs,ya:ty,va:uc,Aa:Wp,la:Td,Ia:hh,Ha:Wu,pa:Yp,n:Hc,i:cc,sa:Ps,ta:Kh,G:ql,ia:El,ja:Uc,A:ph,$a:df,ab:Ko,_a:Zh},yi;Ue();var Xo=O=>(Xo=yi.pb)(O),Cs=s._free=O=>(Cs=s._free=yi.qb)(O),Ol=s._malloc=O=>(Ol=s._malloc=yi.rb)(O);s._SCRTFillActiveTextureCharArray=(O,j,Q)=>(s._SCRTFillActiveTextureCharArray=yi.tb)(O,j,Q);var zc=s._main=(O,j)=>(zc=s._main=yi.ub)(O,j),Ed=s._setThrew=(O,j)=>(Ed=s._setThrew=yi.vb)(O,j),cf=O=>(cf=yi.wb)(O),$c=O=>($c=yi.xb)(O),ry=()=>(ry=yi.yb)();s.dynCall_jiji=(O,j,Q,ie,he)=>(s.dynCall_jiji=yi.zb)(O,j,Q,ie,he),s.dynCall_viijii=(O,j,Q,ie,he,Oe,Fe)=>(s.dynCall_viijii=yi.Ab)(O,j,Q,ie,he,Oe,Fe),s.dynCall_iiiiij=(O,j,Q,ie,he,Oe,Fe)=>(s.dynCall_iiiiij=yi.Bb)(O,j,Q,ie,he,Oe,Fe),s.dynCall_iiiiijj=(O,j,Q,ie,he,Oe,Fe,Ge,lt)=>(s.dynCall_iiiiijj=yi.Cb)(O,j,Q,ie,he,Oe,Fe,Ge,lt),s.dynCall_iiiiiijj=(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot)=>(s.dynCall_iiiiiijj=yi.Db)(O,j,Q,ie,he,Oe,Fe,Ge,lt,Ot);function Ko(O,j,Q,ie){var he=vt();try{return Kt(O)(j,Q,ie)}catch(Oe){if(qe(he),Oe!==Oe+0)throw Oe;Ed(1,0)}}function df(O,j,Q){var ie=vt();try{return Kt(O)(j,Q)}catch(he){if(qe(ie),he!==he+0)throw he;Ed(1,0)}}function Zh(O,j,Q,ie,he){var Oe=vt();try{return Kt(O)(j,Q,ie,he)}catch(Fe){if(qe(Oe),Fe!==Fe+0)throw Fe;Ed(1,0)}}function Xp(O){O=Object.assign({},O);var j=ie=>he=>ie(he)>>>0,Q=ie=>()=>ie()>>>0;return O.pb=j(O.pb),O.rb=j(O.rb),O.xb=j(O.xb),O.yb=Q(O.yb),O}s.callMain=$,s.ccall=Io,s.cwrap=Al,s.UTF8ToString=fr,s.stringToUTF8=Di,s.lengthBytesUTF8=nr,s.specialHTMLTargets=Pl;var Wc;Re=function O(){Wc||ee(),Wc||(Re=O)};function $(O=[]){var j=zc;O.unshift(h);var Q=O.length,ie=qp((Q+1)*4),he=ie;O.forEach(Fe=>{F[he>>>2>>>0]=wl(Fe),he+=4}),F[he>>>2>>>0]=0;try{var Oe=j(Q,ie);return at(Oe,!0),Oe}catch(Fe){return Le(Fe)}}function ee(O=f){if(Ee>0||(X(),Ee>0))return;function j(){var Q;Wc||(Wc=!0,s.calledRun=!0,!P&&(W(),Y(),l(s),(Q=s.onRuntimeInitialized)==null||Q.call(s),ae&&$(O),te()))}s.setStatus?(s.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>s.setStatus(""),1),j()},1)):j()}if(s.preInit)for(typeof s.preInit=="function"&&(s.preInit=[s.preInit]);s.preInit.length>0;)s.preInit.pop()();var ae=!0;return s.noInitialRun&&(ae=!1),ee(),_r&&(_r.getNewId=function(O){_r.counter++;var j=O.length;if(j===0)return 1;for(var Q=1;Q<j;++Q)if(O[Q]===null)return Q;return j}),a=c,a})})();t.exports=i,t.exports.default=i})(p7)),p7.exports}var ECe;function mJ(){return ECe||(ECe=1,(function(t){var e=qA&&qA.__awaiter||function(M,D,F,I){function V(z){return z instanceof F?z:new F(function(G){G(z)})}return new(F||(F=Promise))(function(z,G){function H(X){try{k(I.next(X))}catch(W){G(W)}}function U(X){try{k(I.throw(X))}catch(W){G(W)}}function k(X){X.done?z(X.value):V(X.value).then(H,U)}k((I=I.apply(M,D||[])).next())})},i=qA&&qA.__generator||function(M,D){var F={label:0,sent:function(){if(z[0]&1)throw z[1];return z[1]},trys:[],ops:[]},I,V,z,G;return G={next:H(0),throw:H(1),return:H(2)},typeof Symbol=="function"&&(G[Symbol.iterator]=function(){return this}),G;function H(k){return function(X){return U([k,X])}}function U(k){if(I)throw new TypeError("Generator is already executing.");for(;F;)try{if(I=1,V&&(z=k[0]&2?V.return:k[0]?V.throw||((z=V.return)&&z.call(V),0):V.next)&&!(z=z.call(V,k[1])).done)return z;switch(V=0,z&&(k=[k[0]&2,z.value]),k[0]){case 0:case 1:z=k;break;case 4:return F.label++,{value:k[1],done:!1};case 5:F.label++,V=k[1],k=[0];continue;case 7:k=F.ops.pop(),F.trys.pop();continue;default:if(z=F.trys,!(z=z.length>0&&z[z.length-1])&&(k[0]===6||k[0]===2)){F=0;continue}if(k[0]===3&&(!z||k[1]>z[0]&&k[1]<z[3])){F.label=k[1];break}if(k[0]===6&&F.label<z[1]){F.label=z[1],z=k;break}if(z&&F.label<z[2]){F.label=z[2],F.ops.push(k);break}z[2]&&F.ops.pop(),F.trys.pop();continue}k=D.call(M,F)}catch(X){k=[6,X],V=0}finally{I=z=0}if(k[0]&5)throw k[1];return{value:k[0]?k[1]:void 0,done:!0}}};Object.defineProperty(t,"__esModule",{value:!0}),t.disposeMultiChart3d=t.initializeChartEngine3D=t.getSharedWasmContext3D=t.createMultichart3d=void 0;var n=yVe(),r=LFe(),o=AI(),a=Wf(),s=tC(),l=Sn(),u=vm(),c=fo(),d=$v(),f=hl(),h=kh(),p=gm(),g=La(),v=Z3(),y=TW(),m=LD(),b={id:void 0,wasmContext:void 0,getChildSurfaces:void 0,createChildSurface:void 0},S,_=function(M,D){return e(void 0,void 0,void 0,function(){var F,I,V,z,G,H,U,k,X,W,Y,te,oe,de,ge,Ee,Re;return i(this,function(Ae){switch(Ae.label){case 0:s.default.checkChartDivExists(M),F=s.default.initCanvas(M,(X=D==null?void 0:D.widthAspect)!==null&&X!==void 0?X:0,(W=D==null?void 0:D.heightAspect)!==null&&W!==void 0?W:0,s.default.ECanvasType.canvas2D,(Y=D==null?void 0:D.disableAspect)!==null&&Y!==void 0?Y:a.SciChartDefaults.disableAspect,D==null?void 0:D.touchAction),I=(te=D==null?void 0:D.loader)!==null&&te!==void 0?te:a.SciChartDefaults.defaultLoader,V=(oe=I.addChartLoader)===null||oe===void 0?void 0:oe.call(I,F.domDivContainer,(de=D==null?void 0:D.theme)!==null&&de!==void 0?de:l.SciChartSurfaceBase.DEFAULT_THEME),Ae.label=1;case 1:return Ae.trys.push([1,3,,4]),[4,(0,t.initializeChartEngine3D)({destinationCanvas:F.domCanvas2D})];case 2:return Ae.sent(),z=b.createChildSurface,G=b.wasmContext,G.TSRSetDrawRequestsEnabled((ge=!(D!=null&&D.disableEngineLoop))!==null&&ge!==void 0?ge:!0),H=F.domChartRoot.id,U=z(H,F,(Ee=D==null?void 0:D.theme)!==null&&Ee!==void 0?Ee:l.SciChartSurfaceBase.DEFAULT_THEME),[2,new Promise(function(Pe){setTimeout(function(){var we;(we=I.removeChartLoader)===null||we===void 0||we.call(I,F.domDivContainer,V),U.setIsInitialized(),Pe({wasmContext:G,sciChart3DSurface:U})},0)})];case 3:return k=Ae.sent(),console.error(k),(Re=I.removeChartLoader)===null||Re===void 0||Re.call(I,F.domDivContainer,V),[2,Promise.reject(k)];case 4:return[2]}})})};t.createMultichart3d=_;var C=function(){return e(void 0,void 0,void 0,function(){var M;return i(this,function(D){switch(D.label){case 0:return[4,(0,t.initializeChartEngine3D)()];case 1:return M=D.sent().wasmContext,[2,M]}})})};t.getSharedWasmContext3D=C;var P=function(M){return e(void 0,void 0,void 0,function(){var D,F,I,V,z;return i(this,function(G){switch(G.label){case 0:return D=(V=M==null?void 0:M.destinationCanvas)===null||V===void 0?void 0:V.id,F=g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.EngineInitStart,{parentContextId:D}),m.WebGlHelper.initialize(),!b.wasmContext||!b.createChildSurface||!b.getChildSurfaces?(S||(S=A()),[4,S]):[3,2];case 1:I=G.sent(),(0,u.checkBuildStamp)(I.wasmContext),b.id=I.id,b.wasmContext=I.wasmContext,b.createChildSurface=I.createChildSurface,b.getChildSurfaces=I.getChildSurfaces,G.label=2;case 2:return g.PerformanceDebugHelper.mark(g.EPerformanceMarkType.EngineInitEnd,{relatedId:(z=F==null?void 0:F.detail)===null||z===void 0?void 0:z.relatedId,contextId:b.id,parentContextId:D}),[2,S]}})})};t.initializeChartEngine3D=P;var x,E=function(){x&&x(),b.createChildSurface=void 0,b.getChildSurfaces=void 0,b.wasmContext=void 0,S=void 0,o.licenseManager.clear()};t.disposeMultiChart3d=E;var A=function(){var M=function(F,I,V,z){var G=new v.SciChart3DSurface(F,{canvases:V});G.applyTheme(z),G.setDestinations(d.sciChart3DDestinations);var H=s.default.subscribeToResize(V.domChartRoot,V.aspect,G);return G.addDeletable(H),G},D=function(F,I,V,z,G,H){var U=(0,l.createChartDestination)(V.domCanvas2D);if(!U){V.delete();return}var k=F.SCRTSurfaceDestination.implement(U);H.AddDestination(k),d.sciChart3DDestinations.push({canvasElementId:I,sciChartSurface:V,width:z,height:G})};return new Promise(function(F,I){var V=(0,l.getMasterCanvas)(),z=(0,l.getLocateFile)(v.sciChartConfig3D);new n({locateFile:z,noInitialRun:!0,canvas:V,preRun:y.preRun}).then(function(G){var H=(0,f.generateGuid)(),U=(0,c.createWasmContextRevocableProxy)(G,H),k=U.proxy;o.licenseManager.applyLicense(k,"3D master"),x=function(){k.TSRRequestExit(),oe.delete(),k.SCRTGetGlobalSampleChartInterface().SetFrameRenderer(null),k.SCRTGetGlobalSampleChartInterface().delete(),k.SCRTSetGlobalSampleChartInterface(null),de.delete(),k.SCRTSetGlobalCopyToDestinationInterface(null),U.revoke(),U=void 0,x=void 0};var X=function(){return d.sciChart3DDestinations.map(function(ge){return ge.sciChartSurface})},W=function(ge,Ee,Re){var Ae=s.default.getCanvas2dId(ge),Pe=d.sciChart3DDestinations.filter(function(ke){return ke.canvasElementId!==Ae});te.ClearDestinations();var we=d.sciChart3DDestinations.filter(function(ke){return ke.canvasElementId===Ae});for(we.forEach(function(ke){return ke.sciChartSurface.delete()});d.sciChart3DDestinations.length>0;)d.sciChart3DDestinations.pop();Pe.forEach(function(ke){return D(k,ke.canvasElementId,ke.sciChartSurface,ke.width,ke.height,te)});var Te=M(k,ge,Ee,Re);return Te.addDeletable({delete:function(){v.SciChart3DSurface.autoDisposeWasmContext&&(0,d.getOther3DMultiChartDestinations)(Te).length===0&&(v.SciChart3DSurface.wasmContextDisposeTimeout?setTimeout(function(){d.sciChart3DDestinations.length===0&&v.SciChart3DSurface.disposeSharedWasmContext()},v.SciChart3DSurface.wasmContextDisposeTimeout):v.SciChart3DSurface.disposeSharedWasmContext())}}),D(k,Ae,Te,Ee.domCanvas2D.width,Ee.domCanvas2D.height,te),o.licenseManager.updateLicenseDisplay(Te),Te},Y={InitializeChart:function(){F({id:H,getChildSurfaces:X,createChildSurface:W,wasmContext:k})},Draw:function(ge){h.Logger.debug("Draw",ge);var Ee=d.sciChart3DDestinations.find(function(Re){return Re.canvasElementId===ge});Ee&&Ee.sciChartSurface.doDrawingLoop()},Update:function(ge){},ShutDownChart:function(){}},te=k.SCRTSampleChartInterface.implement(Y),oe=new k.SCRTFrameRenderer3D;te.SetFrameRenderer(oe),te.SetFPSCounterEnabled(!1),te.SetWasmBufferSizesKb(a.SciChartDefaults.wasmBufferSizesKb),k.SCRTSetGlobalSampleChartInterface(te);var de=k.SCRTCopyToDestinationInterface.implement({CopyToDestination:(0,r.copyToCanvas)(l.SciChartSurfaceBase.domMasterCanvas,R)});k.SCRTSetGlobalCopyToDestinationInterface(de),k.TSRSetDrawRequestsEnabled(!0),l.SciChartSurfaceBase.domMasterCanvas&&k.SCRTSetMainWindowSize(l.SciChartSurfaceBase.domMasterCanvas.width,l.SciChartSurfaceBase.domMasterCanvas.height),k.callMain()}).catch(function(G){console.error(G),I(`Could not load SciChart WebAssembly module.
            Check your build process and ensure that your "scichart3d.wasm" and "scichart3d.js" files are from the same version`)})})},R=function(M){return d.sciChart3DDestinations.find(function(D){return D.canvasElementId===M})}})(qA)),qA}var wB={},wCe;function mVe(){if(wCe)return wB;wCe=1,Object.defineProperty(wB,"__esModule",{value:!0}),wB.createSingle3dInternal=void 0;var t=yVe(),e=AI(),i=Wf(),n=tC(),r=Sn(),o=vm(),a=fo(),s=kh(),l=La(),u=Z3(),c=TW(),d=$v(),f=function(p,g){return new Promise(function(v,y){var m,b,S,_,C,P,x=n.default.initCanvas(p,(m=g==null?void 0:g.widthAspect)!==null&&m!==void 0?m:0,(b=g==null?void 0:g.heightAspect)!==null&&b!==void 0?b:0,void 0,(S=g==null?void 0:g.disableAspect)!==null&&S!==void 0?S:i.SciChartDefaults.disableAspect,g==null?void 0:g.touchAction),E=(_=g==null?void 0:g.loader)!==null&&_!==void 0?_:i.SciChartDefaults.defaultLoader,A=(C=E.addChartLoader)===null||C===void 0?void 0:C.call(E,x.domDivContainer,(P=g==null?void 0:g.theme)!==null&&P!==void 0?P:r.SciChartSurfaceBase.DEFAULT_THEME),R=l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.EngineInitStart,{parentContextId:x.domCanvas2D.id}),M=(0,r.getLocateFile)(u.sciChartConfig3D);new t({locateFile:M,noInitialRun:!0,canvas:x.domCanvasWebGL,preRun:c.preRun}).then(function(D){var F,I,V;(F=E.removeChartLoader)===null||F===void 0||F.call(E,x.domDivContainer,A),D.doNotCaptureKeyboard=!0,e.licenseManager.applyLicense(D,"3D single");var z=(0,a.createWasmContextRevocableProxy)(D,x.domCanvas2D.id),G=function(H){H.sciChart3DSurface.addDeletable({delete:function(){z.revoke(),z=void 0}}),l.PerformanceDebugHelper.mark(l.EPerformanceMarkType.EngineInitEnd,{relatedId:R==null?void 0:R.detail.relatedId,contextId:H.sciChart3DSurface.id,parentContextId:x.domCanvas2D.id}),v(H)};h(z.proxy,x,G,(I=g==null?void 0:g.theme)!==null&&I!==void 0?I:r.SciChartSurfaceBase.DEFAULT_THEME),D.TSRSetDrawRequestsEnabled((V=!(g!=null&&g.disableEngineLoop))!==null&&V!==void 0?V:!0),(0,o.checkBuildStamp)(D)}).catch(function(D){var F;throw(F=E.removeChartLoader)===null||F===void 0||F.call(E,x.domDivContainer,A),y(`Could not load SciChart WebAssembly module.
                    Check your build process and ensure that your "scichart3d.wasm" and "scichart3d.js" files are from the same version`),D})})};wB.createSingle3dInternal=f;var h=function(p,g,v,y){var m=g.domCanvas2D.width,b=g.domCanvas2D.height,S;p.canvas=g.domCanvasWebGL;var _={InitializeChart:function(){S=new u.SciChart3DSurface(p,{canvases:g}),S.applyTheme(y),d.sciChart3DSingleDestinations.push({canvasElementId:g.domCanvasWebGL.id,sciChartSurface:S,width:m,height:b}),S.setDestinations(d.sciChart3DSingleDestinations),S.addDeletable({delete:function(){p.TSRRequestExit(),P.delete(),p.SCRTGetGlobalSampleChartInterface().SetFrameRenderer(null),p.SCRTGetGlobalSampleChartInterface().delete(),p.SCRTSetGlobalSampleChartInterface(null),e.licenseManager.clear()}}),setTimeout(function(){S.invalidateElement(),e.licenseManager.updateLicenseDisplay(S);var x=n.default.subscribeToResize(g.domChartRoot,g.aspect,S);S.addDeletable(x),S.setIsInitialized(),v({wasmContext:p,sciChart3DSurface:S})},0)},Draw:function(x){s.Logger.debug("Draw",x),S.isInitialized&&S.doDrawingLoop()},Update:function(x){},ShutDownChart:function(){}},C=p.SCRTSampleChartInterface.implement(_),P=new p.SCRTFrameRenderer3D;C.SetFrameRenderer(P),C.SetFPSCounterEnabled(!1),C.SetWasmBufferSizesKb(i.SciChartDefaults.wasmBufferSizesKb),p.SCRTSetGlobalSampleChartInterface(C),p.callMain()};return wB}var XA={},AB={},ACe;function bVe(){if(ACe)return AB;ACe=1,Object.defineProperty(AB,"__esModule",{value:!0}),AB.ViewportManager3DBase=void 0;var t=tR(),e=(function(){function i(n,r){this.width=n,this.height=r}return i.prototype.setSize=function(n,r){this.width=n,this.height=r},i.prototype.attachSciChartSurface=function(n){if(this.isAttached)throw Error("This ViewportManager instance is already attached to a SciChart3DSurface. Detach it before attaching to another");this.parentSurface=n,this.isAttached=!0},i.prototype.detachSciChartSurface=function(){this.isAttached=!1,this.parentSurface=void 0},i.prototype.calculateAutoRange=function(n){if(n.autoRange===t.EAutoRange.Always||n.autoRange===t.EAutoRange.Once){var r=n.getMaximumRange();if(r&&r.isDefined)return r}return n.visibleRange},i})();return AB.ViewportManager3DBase=e,AB}var OCe;function SVe(){if(OCe)return XA;OCe=1;var t=XA&&XA.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(XA,"__esModule",{value:!0}),XA.DefaultViewportManager3D=void 0;var e=bVe(),i=(function(n){t(r,n);function r(){return n!==null&&n.apply(this,arguments)||this}return r})(e.ViewportManager3DBase);return XA.DefaultViewportManager3D=i,XA}var KA={},DCe;function _Ve(){if(DCe)return KA;DCe=1;var t=KA&&KA.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(KA,"__esModule",{value:!0}),KA.GizmoEntity=void 0;var e=Im(),i=HI(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.type=e.ESceneEntityType.GizmoEntity,s.setNativeEntity(a.SCRTXyzGizmoEntity.implement(s)),s.nativeEntity.SetOverrideEnableGizmo(!1),s}return Object.defineProperty(o.prototype,"enableGizmo",{get:function(){return this.nativeEntity.GetOverrideEnableGizmo()},set:function(a){this.nativeEntity.SetOverrideEnableGizmo(a)},enumerable:!1,configurable:!0}),o})(i.BaseSceneEntity3D);return KA.GizmoEntity=n,KA}var ZA={},OB={},RCe;function PVe(){if(RCe)return OB;RCe=1,Object.defineProperty(OB,"__esModule",{value:!0}),OB.DefaultEntityIdProvider=void 0;var t=(function(){function e(){this.currentId=-1,this.maxId=4294967295}return e.prototype.getNextEntityId=function(){var i=++this.currentId;if(i>=this.maxId)throw new Error("The max Mesh ID has been exceeded.  Please see https://www.scichart.com/questions/wpf/maximum-mesh-id");return i},e.prototype.releaseEntityId=function(i){},e})();return OB.DefaultEntityIdProvider=t,OB}var MCe;function CVe(){if(MCe)return ZA;MCe=1;var t=ZA&&ZA.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(ZA,"__esModule",{value:!0}),ZA.RootSceneEntity=void 0;var e=Im(),i=HI(),n=PVe(),r=ci(),o=(function(a){t(s,a);function s(l,u){var c=a.call(this,l)||this;return c.type=e.ESceneEntityType.RootSceneEntity,r.Guard.notNull(u,"parentSurface"),c.parentSurface=u,c.entityIdProvider=new n.DefaultEntityIdProvider,c}return s.prototype.attachChild=function(l){var u=this;l!=null&&l.nativeEntity&&this.world.AddEntity(l.nativeEntity),l.entityIdProvider=this.entityIdProvider,l.parent=u,l.onAttached()},s.prototype.detachChild=function(l){l!=null&&l.nativeEntity&&this.world.RemoveEntity(l.nativeEntity),l.onDetached(),l.parent=void 0},s})(i.BaseSceneEntity3D);return ZA.RootSceneEntity=o,ZA}var JA={},DB={},LCe;function TVe(){if(LCe)return DB;LCe=1,Object.defineProperty(DB,"__esModule",{value:!0}),DB.AxisCubeDescriptor=void 0;var t=(function(){function e(){}return e})();return DB.AxisCubeDescriptor=t,DB}var RB={},kCe;function xVe(){if(kCe)return RB;kCe=1,Object.defineProperty(RB,"__esModule",{value:!0}),RB.RenderPassInfo3D=void 0;var t=(function(){function e(){}return e})();return RB.RenderPassInfo3D=t,RB}var MB={},ICe;function EVe(){if(ICe)return MB;ICe=1,Object.defineProperty(MB,"__esModule",{value:!0}),MB.SceneDescriptor=void 0;var t=(function(){function e(){}return e})();return MB.SceneDescriptor=t,MB}var NCe;function wVe(){if(NCe)return JA;NCe=1;var t=JA&&JA.__spreadArray||function(d,f,h){if(h||arguments.length===2)for(var p=0,g=f.length,v;p<g;p++)(v||!(p in f))&&(v||(v=Array.prototype.slice.call(f,0,p)),v[p]=f[p]);return d.concat(v||Array.prototype.slice.call(f))};Object.defineProperty(JA,"__esModule",{value:!0}),JA.SciChart3DRenderer=void 0;var e=Br(),i=ci(),n=Rn(),r=tR(),o=Bre(),a=La(),s=TVe(),l=xVe(),u=EVe(),c=(function(){function d(f,h){this.isInvalidated=!1,i.Guard.notNull(f,"scs"),this.scs=f,this.wasmContext=h}return d.getSceneDescriptor=function(f){var h,p,g,v=new u.SceneDescriptor;return v.axisCubeDescriptor=new s.AxisCubeDescriptor,v.axisCubeDescriptor.dimensions=f.worldDimensions,v.axisCubeDescriptor.isVisible=!0,v.axisCubeDescriptor.xAxisDescriptor=(h=f.xAxis)===null||h===void 0?void 0:h.toAxisDescriptor(),v.axisCubeDescriptor.yAxisDescriptor=(p=f.yAxis)===null||p===void 0?void 0:p.toAxisDescriptor(),v.axisCubeDescriptor.zAxisDescriptor=(g=f.zAxis)===null||g===void 0?void 0:g.toAxisDescriptor(),v},d.prepareRenderData=function(f){var h=new l.RenderPassInfo3D;return h.xCalc=f.xAxis.getCurrentCoordinateCalculator(),h.yCalc=f.yAxis.getCurrentCoordinateCalculator(),h.zCalc=f.zAxis.getCurrentCoordinateCalculator(),h.worldDimensions=f.worldDimensions,h.sceneDescriptor=d.getSceneDescriptor(f),h},d.tryPerformAutoRangeOn=function(f,h){var p=(!f.hasValidVisibleRange()||f.hasDefaultVisibleRange())&&f.autoRange===r.EAutoRange.Once||f.autoRange===r.EAutoRange.Always;if(p){var g=h.viewportManager.calculateAutoRange(f);g&&g!==f.visibleRange&&f.isValidRange(g)&&(f.visibleRange=g)}},d.prototype.render=function(){var f=this,h,p;if(!(this.scs.isDeleted||!this.scs.isInitialized)){this.isInvalidated=!1;var g=a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.RenderStart,{contextId:this.scs.id,level:a.EPerformanceDebugLevel.Verbose});this.isSurfaceValid(this.scs),this.scs.webAssemblyContext3D.SCRTSetIsSelectionBufferEnabled(this.scs.isHitTestEnabled);var v=this.scs.getSceneWorld();if(!v){console.warn("SciChart3DRenderer: Undefined scene world!");return}this.wasmContext.SCRTSetActiveWorld(v),this.updateWorldDimensions(v,this.scs.worldDimensions);var y=v.GetMainCamera(),m=this.scs.camera;m.updateEngineCamera(y);var b=this.scs.viewportManager,S=b.width,_=b.height,C=new n.Rect(0,0,S,_);this.scs.setSeriesViewRect(C);var P=this.previousTime?Date.now()-this.previousTime:void 0;this.previousTime=Date.now();var x=a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.GenericAnimationStart,{contextId:this.scs.id,level:a.EPerformanceDebugLevel.Verbose});this.scs.genericAnimationsRun.raiseEvent(),this.scs.onAnimate(P),a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.GenericAnimationEnd,{contextId:this.scs.id,relatedId:(h=x==null?void 0:x.detail)===null||h===void 0?void 0:h.relatedId,level:a.EPerformanceDebugLevel.Verbose}),this.scs.updateBackground(),this.prepareAxes(this.scs.xAxis,this.scs.yAxis,this.scs.zAxis);var E=d.prepareRenderData(this.scs);this.scs.rootEntity.visitEntities(function(F){return F.setRenderPassData(E)});var A=this.scs.annotations.asArray(),R=this.scs.modifierAnnotations.asArray(),M=t(t([],A,!0),R,!0),D=M.filter(function(F){return F.isDomAnnotation});D.forEach(function(F){var I,V=a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.DrawAnnotationStart,{contextId:F.id,parentContextId:f.scs.id,level:a.EPerformanceDebugLevel.Verbose});F.update(void 0,void 0,0,0),a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.DrawAnnotationEnd,{contextId:F.id,parentContextId:f.scs.id,relatedId:(I=V==null?void 0:V.detail)===null||I===void 0?void 0:I.relatedId,level:a.EPerformanceDebugLevel.Verbose})}),this.updateWatermark(),this.scs.onSciChartRendered(),this.scs.isRunningAnimation&&setTimeout(this.scs.invalidateElement,0),a.PerformanceDebugHelper.mark(a.EPerformanceMarkType.RenderEnd,{contextId:this.scs.id,relatedId:(p=g==null?void 0:g.detail)===null||p===void 0?void 0:p.relatedId,level:a.EPerformanceDebugLevel.Verbose})}},d.prototype.updateWatermark=function(){var f=this.scs.getMainCanvas().clientHeight,h=this.scs.getMainCanvas().clientWidth,p=o.watermarkHelpers.calcPosition(h,f,this.scs.watermarkPosition,!0),g=p.left,v=p.bottom;this.scs.updateWatermark(g,v)},d.prototype.isSurfaceValid=function(f,h){if(!f.xAxis)throw new Error("Unable to draw SciChart3DSurface as the xAxis is undefined");if(!f.yAxis)throw new Error("Unable to draw SciChart3DSurface as the yAxis is undefined");if(!f.zAxis)throw new Error("Unable to draw SciChart3DSurface as the zAxis is undefined");return!0},d.prototype.prepareAxes=function(){for(var f=this,h=[],p=0;p<arguments.length;p++)h[p]=arguments[p];h.forEach(function(g){g.validateAxis(),d.tryPerformAutoRangeOn(g,f.scs),g.isMeasured=!0})},d.prototype.updateWorldDimensions=function(f,h){i.Guard.notNull(h,"worldDimensions");var p;try{p=this.scs.worldDimensions.toTsrVector3(this.wasmContext),f.SetWorldDimensions(p)}finally{(0,e.deleteSafe)(p)}},d})();return JA.SciChart3DRenderer=c,JA}var g7={},FCe;function bJ(){return FCe||(FCe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.AxisPlane=t.EAxisPlaneType=void 0;var e=KP(),i=Nj(),n=a$();(function(o){o.XY="xyAxisPlane",o.ZX="zxAxisPlane",o.ZY="zyAxisPlane"})(t.EAxisPlaneType||(t.EAxisPlaneType={}));var r=(function(){function o(a,s,l){var u,c,d,f;this.drawLabelsModeProperty=i.EAxisPlaneDrawLabelsMode.Both,this.drawTitlesModeProperty=i.EAxisPlaneDrawLabelsMode.Both,this.visibilityModeProperty=n.EAxisPlaneVisibilityMode.Auto,this.isVisibleProperty=!0,this.parentSurface=a,this.planeType=s,this.drawLabelsModeProperty=(u=l==null?void 0:l.drawLabelsMode)!==null&&u!==void 0?u:this.drawLabelsModeProperty,this.drawTitlesModeProperty=(c=l==null?void 0:l.drawTitlesMode)!==null&&c!==void 0?c:this.drawTitlesModeProperty,this.visibilityModeProperty=(d=l==null?void 0:l.visibilityMode)!==null&&d!==void 0?d:this.visibilityModeProperty,this.isVisibleProperty=(f=l==null?void 0:l.isVisible)!==null&&f!==void 0?f:this.isVisibleProperty}return o.prototype.notifyPropertyChanged=function(a){var s;(s=this.parentSurface.propertyChanged)===null||s===void 0||s.raiseEvent(new e.PropertyChangedEventArgs("".concat(this.planeType,".").concat(a))),this.parentSurface.invalidateElement()},Object.defineProperty(o.prototype,"drawLabelsMode",{get:function(){return this.drawLabelsModeProperty},set:function(a){this.drawLabelsModeProperty!==a&&(this.drawLabelsModeProperty=a,this.notifyPropertyChanged("drawLabelsMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"drawTitlesMode",{get:function(){return this.drawTitlesModeProperty},set:function(a){this.drawTitlesModeProperty!==a&&(this.drawTitlesModeProperty=a,this.notifyPropertyChanged("drawTitlesMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"visibilityMode",{get:function(){return this.visibilityModeProperty},set:function(a){this.visibilityModeProperty!==a&&(this.visibilityModeProperty=a,this.notifyPropertyChanged("visibilityMode"))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"isVisible",{get:function(){return this.isVisibleProperty},set:function(a){this.isVisibleProperty!==a&&(this.isVisibleProperty=a,this.notifyPropertyChanged("isVisible"))},enumerable:!1,configurable:!0}),o.prototype.toJSON=function(){return{drawLabelsMode:this.drawLabelsMode,drawTitlesMode:this.drawTitlesMode,visibilityMode:this.visibilityMode,isVisible:this.isVisible}},o})();t.AxisPlane=r})(g7)),g7}var BCe;function Z3(){return BCe||(BCe=1,(function(t){var e=Hb&&Hb.__extends||(function(){var H=function(U,k){return H=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(X,W){X.__proto__=W}||function(X,W){for(var Y in W)Object.prototype.hasOwnProperty.call(W,Y)&&(X[Y]=W[Y])},H(U,k)};return function(U,k){if(typeof k!="function"&&k!==null)throw new TypeError("Class extends value "+String(k)+" is not a constructor or null");H(U,k);function X(){this.constructor=U}U.prototype=k===null?Object.create(k):(X.prototype=k.prototype,new X)}})(),i=Hb&&Hb.__awaiter||function(H,U,k,X){function W(Y){return Y instanceof k?Y:new k(function(te){te(Y)})}return new(k||(k=Promise))(function(Y,te){function oe(Ee){try{ge(X.next(Ee))}catch(Re){te(Re)}}function de(Ee){try{ge(X.throw(Ee))}catch(Re){te(Re)}}function ge(Ee){Ee.done?Y(Ee.value):W(Ee.value).then(oe,de)}ge((X=X.apply(H,U||[])).next())})},n=Hb&&Hb.__generator||function(H,U){var k={label:0,sent:function(){if(Y[0]&1)throw Y[1];return Y[1]},trys:[],ops:[]},X,W,Y,te;return te={next:oe(0),throw:oe(1),return:oe(2)},typeof Symbol=="function"&&(te[Symbol.iterator]=function(){return this}),te;function oe(ge){return function(Ee){return de([ge,Ee])}}function de(ge){if(X)throw new TypeError("Generator is already executing.");for(;k;)try{if(X=1,W&&(Y=ge[0]&2?W.return:ge[0]?W.throw||((Y=W.return)&&Y.call(W),0):W.next)&&!(Y=Y.call(W,ge[1])).done)return Y;switch(W=0,Y&&(ge=[ge[0]&2,Y.value]),ge[0]){case 0:case 1:Y=ge;break;case 4:return k.label++,{value:ge[1],done:!1};case 5:k.label++,W=ge[1],ge=[0];continue;case 7:ge=k.ops.pop(),k.trys.pop();continue;default:if(Y=k.trys,!(Y=Y.length>0&&Y[Y.length-1])&&(ge[0]===6||ge[0]===2)){k=0;continue}if(ge[0]===3&&(!Y||ge[1]>Y[0]&&ge[1]<Y[3])){k.label=ge[1];break}if(ge[0]===6&&k.label<Y[1]){k.label=Y[1],Y=ge;break}if(Y&&k.label<Y[2]){k.label=Y[2],k.ops.push(ge);break}Y[2]&&k.ops.pop(),k.trys.pop();continue}ge=U.call(H,k)}catch(Ee){ge=[6,Ee],W=0}finally{X=Y=0}if(ge[0]&5)throw ge[1];return{value:ge[0]?ge[1]:void 0,done:!0}}};Object.defineProperty(t,"__esModule",{value:!0}),t.SciChart3DSurface=t.sciChartConfig3D=void 0;var r=Sn(),o=Zi(),a=Uo(),s=Br(),l=DP(),u=$i(),c=rI(),d=cR(),f=vVe(),h=vje(),p=mJ(),g=mVe(),v=SVe(),y=_Ve(),m=CVe(),b=wVe(),S=vm(),_=Wf(),C=LD(),P=$v(),x=ps(),E=pa(),A=La(),R=Rn(),M=kh(),D=vs(),F=WS(),I=tC(),V=bJ(),z={wasmUrl:"scichart3d.wasm",wasmNoSimdUrl:void 0};t.sciChartConfig3D=z;var G=(function(H){e(U,H);function U(k,X){var W=this,Y,te,oe,de,ge,Ee;W=H.call(this,k,X==null?void 0:X.canvases)||this,W.watermarkPosition=_.SciChartDefaults.watermarkPosition,W.preRender=new x.EventHandler,W.showErrors=!0,W.animationList=[],W.isAxisCubeRenderedProperty=!1,W.isHitTestEnabledProperty=!1;var Re=(te=(Y=W.domCanvas2D)===null||Y===void 0?void 0:Y.width)!==null&&te!==void 0?te:a.DEFAULT_WIDTH,Ae=(de=(oe=W.domCanvas2D)===null||oe===void 0?void 0:oe.height)!==null&&de!==void 0?de:a.DEFAULT_HEIGHT;if(W.webAssemblyContext3D=k,W.visibleRangeClipMin=new k.TSRVector3(Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY),W.visibleRangeClipMax=new k.TSRVector3(Number.MAX_VALUE,Number.MAX_VALUE,Number.MAX_VALUE),!a.IS_TEST_ENV){var Pe=Re/o.DpiHelper.PIXEL_RATIO,we=Ae/o.DpiHelper.PIXEL_RATIO;W.isCopyCanvasSurface?W.changeMasterCanvasViewportSize(k,Pe,we):W.changeWebGLCanvasViewportSize(k,Pe,we)}return W.invalidateElement=W.invalidateElement.bind(W),W.sciChart3DRenderer=new b.SciChart3DRenderer(W,k),W.viewportManager=new v.DefaultViewportManager3D(Re,Ae),W.worldDimensionsProperty=(X==null?void 0:X.worldDimensions)||new d.Vector3(300,200,300),W.detachSeries=W.detachSeries.bind(W),W.attachSeries=W.attachSeries.bind(W),W.renderableSeries=new l.ObservableArray,W.renderableSeries.collectionChanged.subscribe(function(Te){var ke,$e;(ke=Te.getOldItems())===null||ke===void 0||ke.forEach(function(Ne){return W.detachSeries(Ne)}),($e=Te.getNewItems())===null||$e===void 0||$e.forEach(function(Ne){return W.attachSeries(Ne)})}),W.childPropertyChanged=W.childPropertyChanged.bind(W),W.sceneWorldProperty=new W.webAssemblyContext3D.SCRTSceneWorld,W.sceneWorldProperty.SetCanvasId((Ee=(ge=W.domCanvas2D)===null||ge===void 0?void 0:ge.id)!==null&&Ee!==void 0?Ee:"DefaultCanvasIdNeededForUnitTests"),W.sceneWorldProperty.Init(),W.rootEntity=new m.RootSceneEntity(k,W),W.axisCubeEntity=new f.AxisCubeEntity(k,W),W.rootEntity.children.add(W.axisCubeEntity),W.gizmoEntity=new y.GizmoEntity(k),W.rootEntity.children.add(W.gizmoEntity),a.IS_TEST_ENV||(W.watermarkProperties=new k.SCRTWaterMarkProperties,W.watermarkProperties.m_fCanvasWidth=Re,W.watermarkPropertyPosition=new k.TSRVector2(0,0),W.watermarkProperties.SetPosition(W.watermarkPropertyPosition),W.watermarkProperties.SetOpacity(.5),k.SCRT3DSetWaterMarkProperties(W.watermarkProperties)),W}return U.createSingle=function(k,X){var W=A.PerformanceDebugHelper.mark(A.EPerformanceMarkType.InitializationStart,{contextId:X==null?void 0:X.id});return(0,g.createSingle3dInternal)(k,X).then(function(Y){var te;return Y.sciChart3DSurface.applyOptions(X),A.PerformanceDebugHelper.mark(A.EPerformanceMarkType.InitializationEnd,{parentContextId:Y.sciChart3DSurface.domCanvas2D.id,contextId:Y.sciChart3DSurface.id,relatedId:(te=W==null?void 0:W.detail)===null||te===void 0?void 0:te.relatedId}),Y})},U.configure=function(k){var X,W;t.sciChartConfig3D.wasmUrl=(X=k==null?void 0:k.wasmUrl)!==null&&X!==void 0?X:z.wasmUrl,t.sciChartConfig3D.wasmNoSimdUrl=(W=k==null?void 0:k.wasmNoSimdUrl)!==null&&W!==void 0?W:z.wasmNoSimdUrl},U.useWasmFromCDN=function(){t.sciChartConfig3D.wasmUrl="https://cdn.jsdelivr.net/npm/scichart@".concat(S.libraryVersion,"/_wasm/scichart3d.wasm"),t.sciChartConfig3D.wasmNoSimdUrl="https://cdn.jsdelivr.net/npm/scichart@".concat(S.libraryVersion,"/_wasm/scichart3d-nosimd.wasm")},U.loadWasmFromCDN=function(){return U.useWasmFromCDN()},U.loadWasmLocal=function(){return U.configure(z)},U.create=function(k,X){var W=A.PerformanceDebugHelper.mark(A.EPerformanceMarkType.InitializationStart,{contextId:X==null?void 0:X.id});return a.IS_TEST_ENV?this.createTest(k,X):(0,p.createMultichart3d)(k,X).then(function(Y){var te,oe;return Y.sciChart3DSurface.applyOptions(X),A.PerformanceDebugHelper.mark(A.EPerformanceMarkType.InitializationEnd,{parentContextId:Y.sciChart3DSurface.domCanvas2D.id,contextId:(te=Y.sciChart3DSurface)===null||te===void 0?void 0:te.id,relatedId:(oe=W==null?void 0:W.detail)===null||oe===void 0?void 0:oe.relatedId}),Y})},U.disposeSharedWasmContext=function(){P.sciChart3DDestinations.length===0&&(0,p.disposeMultiChart3d)(),H.disposeSharedWasmContext.call(this)},U.createTest=function(k,X){var W,Y,te=I.default.initCanvas(k,(W=X==null?void 0:X.widthAspect)!==null&&W!==void 0?W:0,(Y=X==null?void 0:X.heightAspect)!==null&&Y!==void 0?Y:0,I.default.ECanvasType.canvas2D),oe=new U(t.sciChartConfig3D.testWasm,{canvases:te});return oe.applyTheme(X==null?void 0:X.theme),oe.applyOptions(X),new Promise(function(de){return de({wasmContext:oe.webAssemblyContext3D,sciChart3DSurface:oe})})},U.prototype.getSceneWorld=function(){return this.sceneWorldProperty},U.prototype.worldToScreenCoord=function(k){var X=this.getSceneWorld();if(X){var W=k.toTsrVector3(this.webAssemblyContext3D),Y=X.TransformWorldToScreenCoords(W),te=new u.Point(Y.x,Y.y);return Y.delete(),W.delete(),te}},U.prototype.delete=function(k){k===void 0&&(k=!0),this.renderableSeries.asArray().forEach(function(X){return X.delete()}),this.renderableSeries.clear(!1),this.xAxis=(0,s.deleteSafe)(this.xAxis),this.yAxis=(0,s.deleteSafe)(this.yAxis),this.zAxis=(0,s.deleteSafe)(this.zAxis),this.rootEntity=(0,s.deleteSafe)(this.rootEntity),this.watermarkProperties=(0,s.deleteSafe)(this.watermarkProperties),this.watermarkPropertyPosition=(0,s.deleteSafe)(this.watermarkPropertyPosition),this.sceneWorldProperty=(0,s.deleteSafe)(this.sceneWorldProperty),a.IS_TEST_ENV||this.webAssemblyContext3D.SCRTSetActiveWorld(null),this.clearRootElement(k),this.visibleRangeClipMin=(0,s.deleteSafe)(this.visibleRangeClipMin),this.visibleRangeClipMax=(0,s.deleteSafe)(this.visibleRangeClipMax),H.prototype.delete.call(this)},Object.defineProperty(U.prototype,"enableGizmo",{get:function(){return this.gizmoEntity.enableGizmo},set:function(k){this.gizmoEntity.enableGizmo=k},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"viewportManager",{get:function(){return this.viewportManagerProperty},set:function(k){var X,W;(X=this.viewportManagerProperty)===null||X===void 0||X.detachSciChartSurface(),this.viewportManagerProperty=k,(W=this.viewportManagerProperty)===null||W===void 0||W.attachSciChartSurface(this),this.notifyPropertyChanged(h.PROPERTY.SURFACE_VIEWPORT_MANAGER)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"worldDimensions",{get:function(){return this.worldDimensionsProperty},set:function(k){this.worldDimensionsProperty=k,this.notifyPropertyChanged(h.PROPERTY.SURFACE_WORLD_DIMENSIONS)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"isZXPlaneVisible",{get:function(){return this.zxAxisPlaneProperty.isVisible},set:function(k){this.zxAxisPlaneProperty.isVisible=k},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"isXYPlaneVisible",{get:function(){return this.xyAxisPlaneProperty.isVisible},set:function(k){this.xyAxisPlaneProperty.isVisible=k},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"isZYPlaneVisible",{get:function(){return this.zyAxisPlaneProperty.isVisible},set:function(k){this.zyAxisPlaneProperty.isVisible=k},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"xyAxisPlane",{get:function(){return this.xyAxisPlaneProperty},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"zyAxisPlane",{get:function(){return this.zyAxisPlaneProperty},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"zxAxisPlane",{get:function(){return this.zxAxisPlaneProperty},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"camera",{get:function(){return this.cameraProperty},set:function(k){var X,W;(X=this.cameraProperty)===null||X===void 0||X.propertyChanged.unsubscribe(this.childPropertyChanged),this.cameraProperty=k,(W=this.cameraProperty)===null||W===void 0||W.propertyChanged.subscribe(this.childPropertyChanged),this.notifyPropertyChanged(h.PROPERTY.SURFACE_CAMERA)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"xAxis",{get:function(){return this.xAxisProperty},set:function(k){this.detachAxis(this.xAxisProperty),this.xAxisProperty=k,this.attachAxis(this.xAxisProperty),this.notifyPropertyChanged(h.PROPERTY.SURFACE_XAXIS)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"yAxis",{get:function(){return this.yAxisProperty},set:function(k){this.detachAxis(this.yAxisProperty),this.yAxisProperty=k,this.attachAxis(this.yAxisProperty),this.notifyPropertyChanged(h.PROPERTY.SURFACE_YAXIS)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"zAxis",{get:function(){return this.zAxisProperty},set:function(k){this.detachAxis(this.zAxisProperty),this.zAxisProperty=k,this.attachAxis(this.zAxisProperty),this.notifyPropertyChanged(h.PROPERTY.SURFACE_ZAXIS)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"isHitTestEnabled",{get:function(){return this.isHitTestEnabledProperty},set:function(k){k!==this.isHitTestEnabledProperty&&(this.isHitTestEnabledProperty=k,this.invalidateElement())},enumerable:!1,configurable:!0}),U.prototype.setIsAxisCubeRendered=function(){this.isAxisCubeRenderedProperty=!0},Object.defineProperty(U.prototype,"isAxisCubeRendered",{get:function(){return this.isAxisCubeRenderedProperty},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"chartViewRect",{get:function(){return new R.Rect(0,0,this.viewportManager.width,this.viewportManager.height)},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"preRenderAll",{get:function(){return this.preRender},enumerable:!1,configurable:!0}),U.prototype.invalidateElement=function(k){var X,W,Y;if(M.Logger.debug("Invalidating ".concat((W=(X=this.domChartRoot)===null||X===void 0?void 0:X.id)!==null&&W!==void 0?W:this.id,": force=").concat(k==null?void 0:k.force," isSuspended=").concat(this.isSuspended," isInitialized=").concat(this.isInitialized,".")),!(!(k!=null&&k.force)&&(this.isSuspended||this.isDeleted||!this.isInitialized))&&(A.PerformanceDebugHelper.mark(this.sciChart3DRenderer.isInvalidated?A.EPerformanceMarkType.Invalidate:A.EPerformanceMarkType.LeadingInvalidate,{contextId:this.id}),!this.sciChart3DRenderer.isInvalidated)){if(!(!((Y=C.WebGlHelper.getContext(this.webAssemblyContext3D.canvas))===null||Y===void 0)&&Y.isContextLost())){this.sciChart3DRenderer.isInvalidated=!0;var te=this.domCanvas2D?this.domCanvas2D.id:"undefinedCanvasId";this.webAssemblyContext3D.TSRRequestCanvasDraw(te)}this.redrawRequested.raiseEvent(this.sciChart3DRenderer.isInvalidated)}},U.prototype.onDpiChanged=function(k){var X,W;this.renderableSeries.asArray().forEach(function(Y){return Y.onDpiChanged(k)}),this.changeViewportSize((X=this.getMainCanvas())===null||X===void 0?void 0:X.clientWidth,(W=this.getMainCanvas())===null||W===void 0?void 0:W.clientHeight),H.prototype.onDpiChanged.call(this,k)},Object.defineProperty(U.prototype,"surfaceType",{get:function(){return D.ESurfaceType.SciChart3DSurfaceType},enumerable:!1,configurable:!0}),Object.defineProperty(U.prototype,"isInvalidated",{get:function(){var k;return(k=this.sciChart3DRenderer)===null||k===void 0?void 0:k.isInvalidated},enumerable:!1,configurable:!0}),U.prototype.onSciChartRendered=function(){this.chartModifiers.asArray().forEach(function(k){k.onParentSurfaceRendered()})},U.prototype.doDrawingLoop=function(){var k=this;try{var X=this.suspender.lock();try{this.preRender.raiseEvent()}finally{X()}this.updateClipPlanes(),this.sciChart3DRenderer.render();var W=this.isInvalidated;A.PerformanceDebugHelper.mark(W?A.EPerformanceMarkType.Rendered:A.EPerformanceMarkType.FullStateRendered,{contextId:this.id}),this.rendered.raiseEvent(W),this.renderedToWebGl.raiseEvent(this.isInvalidated),this.isCopyCanvasSurface||this.renderedToDestination.raiseEvent(this.isInvalidated),(this.painted.handlers.length>0||A.PerformanceDebugHelper.enableDebug)&&(0,A.runAfterFramePaint)(function(){A.PerformanceDebugHelper.mark(A.EPerformanceMarkType.Painted,{contextId:k.id}),k.painted.raiseEvent()})}catch(Y){if(Y.name==="BindingError")console.error(Y),console.warn("Binding errors can occur if a previous chart using the same div id was not deleted correctly, or if you try to share data or series between charts that use different webassembly contexts.");else if(this.domChartRoot)this.showErrors&&console.error("Error from chart in div ".concat(this.domChartRoot.id,":"),Y);else throw Y}},U.prototype.applyTheme=function(k){var X,W,Y;H.prototype.applyTheme.call(this,k),this.renderableSeries.asArray().forEach(function(te){return te.applyTheme(k)}),(X=this.xAxis)===null||X===void 0||X.applyTheme(k),(W=this.yAxis)===null||W===void 0||W.applyTheme(k),(Y=this.zAxis)===null||Y===void 0||Y.applyTheme(k),this.invalidateElement()},U.prototype.changeViewportSize=function(k,X){if(!(!k||!X||this.isDeleted)){var W=k*o.DpiHelper.PIXEL_RATIO,Y=X*o.DpiHelper.PIXEL_RATIO;this.viewportManager.setSize(W,Y),this.isCopyCanvasSurface?(this.changeMasterCanvasViewportSize(this.webAssemblyContext3D,k,X),this.domCanvas2D&&o.DpiHelper.setSize(this.domCanvas2D,k,X)):this.changeWebGLCanvasViewportSize(this.webAssemblyContext3D,k,X),this.invalidateElement()}},U.prototype.getAnimations=function(){return this.animationList},U.prototype.addAnimation=function(){for(var k=this,X=[],W=0;W<arguments.length;W++)X[W]=arguments[W];X!==void 0&&(X.forEach(function(Y){return k.animationList.push(Y)}),this.invalidateElement())},Object.defineProperty(U.prototype,"isRunningAnimation",{get:function(){return this.animationList.some(function(k){return!k.isComplete})},enumerable:!1,configurable:!0}),U.prototype.onAnimate=function(k){if(k){for(var X=[],W=0;W<this.animationList.length;W++){var Y=this.animationList[W];Y.isComplete||(Y.update(k),Y.isComplete||(this.invalidateElement(),X.push(Y)))}this.animationList=X}},U.prototype.getXAxisById=function(k){return this.xAxis},U.prototype.getDefaultXAxis=function(){return this.xAxis},U.prototype.getYAxisById=function(k){return this.yAxis},U.prototype.getDefaultYAxis=function(){return this.yAxis},U.prototype.updateWatermark=function(k,X){var W,Y;if(!a.IS_TEST_ENV){this.watermarkPropertyPosition.x=k,this.watermarkPropertyPosition.y=X,this.watermarkProperties.m_fCanvasWidth=(W=this.getMainCanvas())===null||W===void 0?void 0:W.clientWidth,this.watermarkProperties.SetPosition(this.watermarkPropertyPosition);var te=(Y=this.themeProvider)===null||Y===void 0?void 0:Y.isLightBackground;this.watermarkProperties.m_bIsDarkBackground=te!==void 0?!te:!1,this.webAssemblyContext3D.SCRT3DSetWaterMarkProperties(this.watermarkProperties)}},U.prototype.getSeriesViewRectPadding=function(k){return E.Thickness.fromNumber(0)},U.prototype.updateBackground=function(){var k;this.applySciChartBackground((k=this.backgroundProperty)!==null&&k!==void 0?k:this.themeProvider.sciChartBackground)},U.prototype.registerFont=function(k,X){return i(this,void 0,void 0,function(){var W=this;return n(this,function(Y){return k.includes(".")||(k+=".ttf"),this.showErrors=!1,[2,new Promise(function(te,oe){var de=W.webAssemblyContext3D.SCRTFileLoadCallbackInterface.implement({OnLoadComplete:function(ge,Ee){ge?te(!0):(console.error("Failed to load ".concat(k," from ").concat(X,".  Error: ").concat(Ee)),te(!1))}});W.webAssemblyContext3D.SCRTRegisterFile(k,X,de)}).then(function(){return W.showErrors=!0})]})})},U.prototype.updateClipPlanes=function(){var k=this.getSceneWorld();k.SetVisibleRangeMin(this.visibleRangeClipMin),k.SetVisibleRangeMax(this.visibleRangeClipMax),k.SetUseClipPlanes(!1)},U.prototype.applyOptions=function(k){H.prototype.applyOptions.call(this,k),this.camera=new c.CameraController(this.webAssemblyContext3D,k==null?void 0:k.cameraOptions),k!=null&&k.worldDimensions&&(this.worldDimensions=d.Vector3.hydrate(k.worldDimensions)),k!=null&&k.background&&(this.background=k.background),this.xyAxisPlaneProperty=new V.AxisPlane(this,V.EAxisPlaneType.XY,k==null?void 0:k.xyAxisPlane),this.zyAxisPlaneProperty=new V.AxisPlane(this,V.EAxisPlaneType.ZY,k==null?void 0:k.zyAxisPlane),this.zxAxisPlaneProperty=new V.AxisPlane(this,V.EAxisPlaneType.ZX,k==null?void 0:k.zxAxisPlane)},U.prototype.attachChartModifier=function(k){H.prototype.attachChartModifier.call(this,k),k.setParentSurface(this),k.invalidateParentCallback=this.invalidateElement,k.onAttach(),this.invalidateElement()},U.prototype.applySciChartBackground=function(k){this.domChartRoot&&(this.domChartRoot.style.background=k),this.webAssemblyContext3D.SCRT3DSetClearColor(0,0,0,0)},U.prototype.detachSeries=function(k){this.rootEntity&&this.rootEntity.children.remove(k.sceneEntity),k.onDetach(),this.invalidateElement()},U.prototype.attachSeries=function(k){if(k.onAttach(this),!k.sceneEntity)throw new Error("IRenderableSeries3D.sceneEntity must be set before attaching to SciChart3DSurface");this.rootEntity&&this.rootEntity.children.add(k.sceneEntity),this.invalidateElement()},U.prototype.detachAxis=function(k){k&&(k.invalidateParentCallback=void 0,k.parentSurface=void 0)},U.prototype.attachAxis=function(k){if(k){if(k.invalidateParentCallback)throw new Error("Invalid operation in sciChart3DSurface.attachAxis, this axis has already been attached to a SciChart3DSurface. Please detach it from a SciChart3DSurface before attaching to another");k.onAttach(this,k===this.xAxis,k===this.yAxis,k===this.zAxis),this.themeProviderProperty&&k.applyTheme(this.themeProviderProperty),k.invalidateParentCallback=this.invalidateElement}},U.prototype.childPropertyChanged=function(k){this.invalidateElement()},U.prototype.getNextState=function(k){return k===void 0&&(k=!1),i(this,void 0,void 0,function(){return n(this,function(X){switch(X.label){case 0:return[4,this.nextStateRender({resumeBefore:!0,invalidateOnResume:!0,suspendAfter:!0})];case 1:return X.sent(),[2,this.toJSON(k)]}})})},U.prototype.getOptions=function(){var k;"toJSON"in this.themeProvider?k=this.themeProvider.toJSON():k=this.themeProvider;var X={id:this.id,cameraOptions:this.camera.toJSON(),worldDimensions:this.worldDimensions,heightAspect:this.heightAspect,widthAspect:this.widthAspect,theme:k,background:this.background,loader:this.loaderJson,disableAspect:this.disableAspect,touchAction:this.touchActionProperty,freezeWhenOutOfView:this.freezeWhenOutOfView,xyAxisPlane:this.xyAxisPlaneProperty.toJSON(),zyAxisPlane:this.zyAxisPlaneProperty.toJSON(),zxAxisPlane:this.zxAxisPlaneProperty.toJSON()};return X},U.prototype.toJSON=function(k){k===void 0&&(k=!1);var X=this.getOptions(),W={type:F.ESciChartSurfaceType.Default3D,surface:X,xAxis:this.xAxis.toJSON(),yAxis:this.yAxis.toJSON(),zAxis:this.zAxis.toJSON(),series:this.renderableSeries.asArray().map(function(Y){return Y.toJSON(k)}),modifiers:this.chartModifiers.asArray().map(function(Y){return Y.toJSON()}),onCreated:this.onCreatedName,createSingle:!this.isCopyCanvasSurface};return W},U})(r.SciChartSurfaceBase);t.SciChart3DSurface=G})(Hb)),Hb}var jCe;function U_(){if(jCe)return dl;jCe=1;var t=dl&&dl.__assign||function(){return t=Object.assign||function(ve){for(var pe,fe=1,me=arguments.length;fe<me;fe++){pe=arguments[fe];for(var Ce in pe)Object.prototype.hasOwnProperty.call(pe,Ce)&&(ve[Ce]=pe[Ce])}return ve},t.apply(this,arguments)},e=dl&&dl.__awaiter||function(ve,pe,fe,me){function Ce(Ue){return Ue instanceof fe?Ue:new fe(function(Qe){Qe(Ue)})}return new(fe||(fe=Promise))(function(Ue,Qe){function it($t){try{wt(me.next($t))}catch(Mt){Qe(Mt)}}function xt($t){try{wt(me.throw($t))}catch(Mt){Qe(Mt)}}function wt($t){$t.done?Ue($t.value):Ce($t.value).then(it,xt)}wt((me=me.apply(ve,pe||[])).next())})},i=dl&&dl.__generator||function(ve,pe){var fe={label:0,sent:function(){if(Ue[0]&1)throw Ue[1];return Ue[1]},trys:[],ops:[]},me,Ce,Ue,Qe;return Qe={next:it(0),throw:it(1),return:it(2)},typeof Symbol=="function"&&(Qe[Symbol.iterator]=function(){return this}),Qe;function it(wt){return function($t){return xt([wt,$t])}}function xt(wt){if(me)throw new TypeError("Generator is already executing.");for(;fe;)try{if(me=1,Ce&&(Ue=wt[0]&2?Ce.return:wt[0]?Ce.throw||((Ue=Ce.return)&&Ue.call(Ce),0):Ce.next)&&!(Ue=Ue.call(Ce,wt[1])).done)return Ue;switch(Ce=0,Ue&&(wt=[wt[0]&2,Ue.value]),wt[0]){case 0:case 1:Ue=wt;break;case 4:return fe.label++,{value:wt[1],done:!1};case 5:fe.label++,Ce=wt[1],wt=[0];continue;case 7:wt=fe.ops.pop(),fe.trys.pop();continue;default:if(Ue=fe.trys,!(Ue=Ue.length>0&&Ue[Ue.length-1])&&(wt[0]===6||wt[0]===2)){fe=0;continue}if(wt[0]===3&&(!Ue||wt[1]>Ue[0]&&wt[1]<Ue[3])){fe.label=wt[1];break}if(wt[0]===6&&fe.label<Ue[1]){fe.label=Ue[1],Ue=wt;break}if(Ue&&fe.label<Ue[2]){fe.label=Ue[2],fe.ops.push(wt);break}Ue[2]&&fe.ops.pop(),fe.trys.pop();continue}wt=pe.call(ve,fe)}catch($t){wt=[6,$t],Ce=0}finally{me=Ue=0}if(wt[0]&5)throw wt[1];return{value:wt[0]?wt[1]:void 0,done:!0}}};Object.defineProperty(dl,"__esModule",{value:!0}),dl.configure3DSurface=dl.configure2DSurface=dl.buildSubCharts=dl.build3DChart=dl.buildPieChart=dl.build2DPolarChart=dl.build2DChart=void 0;var n=pW(),r=gW(),o=lVe(),a=uVe(),s=JP(),l=vW(),u=yW(),c=cVe(),d=mW(),f=bW(),h=dVe(),p=SW(),g=_W(),v=fVe(),y=hVe(),m=uW(),b=cW(),S=pVe(),_=BI(),C=xre(),P=gVe(),x=GO(),E=Rg(),A=ga(),R=zS(),M=$d(),D=nne(),F=e$(),I=n$(),V=K3(),z=Tv(),G=mo(),H=OI(),U=La(),k=uie(),X=WS(),W=lie(),Y=aie(),te=oie(),oe=hie(),de=die(),ge=od(),Ee=Z3(),Re=pie();(0,G.registerType)(A.EBaseType.ThemeProvider,H.EThemeProviderType.Light,function(){return new S.SciChartJSLightTheme},!0),(0,G.registerType)(A.EBaseType.ThemeProvider,H.EThemeProviderType.DarkV2,function(){return new b.SciChartJSDarkv2Theme},!0),(0,G.registerType)(A.EBaseType.ThemeProvider,H.EThemeProviderType.Dark,function(){return new m.SciChartJSDarkTheme},!0),(0,G.registerType)(A.EBaseType.ThemeProvider,H.EThemeProviderType.Navy,function(){return new y.SciChartJsNavyTheme},!0),(0,G.registerType)(A.EBaseType.LayoutManager,R.ELayoutManagerType.Default,function(ve){return new s.LayoutManager(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutManager,R.ELayoutManagerType.Polar,function(ve){return new te.PolarLayoutManager(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutManager,R.ELayoutManagerType.CentralAxes,function(ve){return new a.CentralAxesLayoutManager(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.BottomInner,function(ve){return new n.BottomAlignedInnerAxisLayoutStrategy(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.BottomOuter,function(ve){return new r.BottomAlignedOuterAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.BottomStacked,function(ve){return new o.BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.LeftInner,function(ve){return new l.LeftAlignedInnerAxisLayoutStrategy(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.LeftOuter,function(ve){return new u.LeftAlignedOuterAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.LeftStacked,function(ve){return new c.LeftAlignedOuterVerticallyStackedAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.RightInner,function(ve){return new d.RightAlignedInnerAxisLayoutStrategy(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.RightOuter,function(ve){return new f.RightAlignedOuterAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.RightStacked,function(ve){return new h.RightAlignedOuterVerticallyStackedAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.TopInner,function(ve){return new p.TopAlignedInnerAxisLayoutStrategy(ve)},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.TopOuter,function(ve){return new g.TopAlignedOuterAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.LayoutStrategy,M.ELayoutStrategyType.TopStacked,function(ve){return new v.TopAlignedOuterHorizontallyStackedAxisLayoutStrategy},!0),(0,G.registerType)(A.EBaseType.Loader,"Default",function(){return new C.DefaultSciChartLoader},!0);var Ae=function(ve,pe){return e(void 0,void 0,void 0,function(){var fe,me,Ce,Ue,Qe;return i(this,function(it){switch(it.label){case 0:return typeof pe=="string"&&(pe=JSON.parse(pe,z.chartReviver)),pe!=null&&pe.createSingle?[4,E.SciChartSurface.createSingle(ve,pe==null?void 0:pe.surface)]:[3,2];case 1:return fe=it.sent(),[3,4];case 2:return[4,E.SciChartSurface.create(ve,pe==null?void 0:pe.surface)];case 3:fe=it.sent(),it.label=4;case 4:return me=fe.wasmContext,Ce=fe.sciChartSurface,Ue=U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupStart,{contextId:Ce.id}),$e(pe,Ce,me),pe.onCreated?(typeof pe.onCreated=="string"&&(Ce.onCreatedName=pe.onCreated,pe.onCreated=(0,G.getFunction)(A.EBaseType.OnCreateFunction,pe.onCreated)),[4,pe.onCreated(Ce)]):[3,6];case 5:it.sent(),it.label=6;case 6:return U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupEnd,{contextId:Ce.id,relatedId:(Qe=Ue==null?void 0:Ue.detail)===null||Qe===void 0?void 0:Qe.relatedId}),[2,{wasmContext:me,sciChartSurface:Ce}]}})})};dl.build2DChart=Ae;var Pe=function(ve,pe){return e(void 0,void 0,void 0,function(){var fe,me,Ce,Ue,Qe;return i(this,function(it){switch(it.label){case 0:return typeof pe=="string"&&(pe=JSON.parse(pe,z.chartReviver)),pe!=null&&pe.createSingle?[4,Y.SciChartPolarSurface.createSingle(ve,pe==null?void 0:pe.surface)]:[3,2];case 1:return fe=it.sent(),[3,4];case 2:return[4,Y.SciChartPolarSurface.create(ve,pe==null?void 0:pe.surface)];case 3:fe=it.sent(),it.label=4;case 4:return me=fe.wasmContext,Ce=fe.sciChartSurface,Ue=U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupStart,{contextId:Ce.id}),$e(pe,Ce,me),pe.onCreated?(typeof pe.onCreated=="string"&&(Ce.onCreatedName=pe.onCreated,pe.onCreated=(0,G.getFunction)(A.EBaseType.OnCreateFunction,pe.onCreated)),[4,pe.onCreated(Ce)]):[3,6];case 5:it.sent(),it.label=6;case 6:return U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupEnd,{contextId:Ce.id,relatedId:(Qe=Ue==null?void 0:Ue.detail)===null||Qe===void 0?void 0:Qe.relatedId}),[2,{wasmContext:me,sciChartSurface:Ce}]}})})};dl.build2DPolarChart=Pe;var we=function(ve,pe){return e(void 0,void 0,void 0,function(){var fe,me,Ce,Ue,Qe;return i(this,function(it){switch(it.label){case 0:return typeof pe=="string"&&(pe=JSON.parse(pe,z.chartReviver)),[4,x.SciChartPieSurface.create(ve,pe==null?void 0:pe.surface)];case 1:if(fe=it.sent(),pe!=null&&pe.segments)for(me=0,Ce=pe==null?void 0:pe.segments;me<Ce.length;me++)Ue=Ce[me],Qe=new P.PieSegment(Ue),fe.pieSegments.add(Qe);return pe.onCreated&&(typeof pe.onCreated=="string"&&(fe.onCreatedName=pe.onCreated,pe.onCreated=(0,G.getFunction)(A.EBaseType.OnCreateFunction,pe.onCreated)),pe.onCreated(fe)),[2,fe]}})})};dl.buildPieChart=we;var Te=function(ve,pe){return e(void 0,void 0,void 0,function(){var fe,me,Ce,Ue,Qe,it,xt;return i(this,function(wt){switch(wt.label){case 0:return typeof pe=="string"&&(pe=JSON.parse(pe,z.chartReviver)),pe!=null&&pe.createSingle?[4,Ee.SciChart3DSurface.createSingle(ve,t({},pe==null?void 0:pe.surface))]:[3,2];case 1:return fe=wt.sent(),[3,4];case 2:return[4,Ee.SciChart3DSurface.create(ve,t({},pe==null?void 0:pe.surface))];case 3:fe=wt.sent(),wt.label=4;case 4:return!((it=pe==null?void 0:pe.surface)===null||it===void 0)&&it.theme&&("type"in pe.surface.theme?(me=(0,G.getFunction)(A.EBaseType.ThemeProvider,pe.surface.theme.type).call(null),me&&fe.sciChart3DSurface.applyTheme(me)):fe.sciChart3DSurface.applyTheme(pe.surface.theme)),Ce=fe.wasmContext,Ue=fe.sciChart3DSurface,Qe=U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupStart,{contextId:Ue.id}),Ne(pe,Ue,Ce),pe.onCreated?(typeof pe.onCreated=="string"&&(Ue.onCreatedName=pe.onCreated,pe.onCreated=(0,G.getFunction)(A.EBaseType.OnCreateFunction,pe.onCreated)),[4,pe.onCreated(Ue)]):[3,6];case 5:wt.sent(),wt.label=6;case 6:return U.PerformanceDebugHelper.mark(U.EPerformanceMarkType.SetupEnd,{contextId:Ue.id,relatedId:(xt=Qe==null?void 0:Qe.detail)===null||xt===void 0?void 0:xt.relatedId}),[2,{wasmContext:Ce,sciChart3DSurface:Ue}]}})})};dl.build3DChart=Te;function ke(ve,pe){for(var fe,me=pe.webAssemblyContext2D,Ce=Array.isArray(ve)?ve:[ve],Ue=[],Qe=0,it=Ce;Qe<it.length;Qe++){var xt=it[Qe],wt=((fe=xt==null?void 0:xt.surface)===null||fe===void 0?void 0:fe.surfaceType)===X.ESciChartSurfaceType.Polar2D;if(wt){var $t=W.SciChartPolarSubSurface.createSubSurface(pe,xt.surface);$e(xt,$t,me),Ue.push($t)}else{var $t=k.SciChartSubSurface.createSubSurface(pe,xt.surface);$e(xt,$t,me),Ue.push($t)}}return Ue}dl.buildSubCharts=ke;function $e(ve,pe,fe){var me,Ce,Ue,Qe,it;ve.xAxes&&(me=pe.xAxes).add.apply(me,(0,F.buildAxes)(fe,ve.xAxes)),ve.yAxes&&(Ce=pe.yAxes).add.apply(Ce,(0,F.buildAxes)(fe,ve.yAxes)),pe.isPolar?(pe.xAxes.size()===0&&!ve.subCharts&&pe.xAxes.add(new oe.PolarNumericAxis(fe,{polarAxisMode:de.EPolarAxisMode.Angular,axisAlignment:ge.EAxisAlignment.Top})),pe.yAxes.size()===0&&!ve.subCharts&&pe.yAxes.add(new oe.PolarNumericAxis(fe,{polarAxisMode:de.EPolarAxisMode.Radial,axisAlignment:ge.EAxisAlignment.Right}))):(pe.xAxes.size()===0&&!ve.subCharts&&pe.xAxes.add(new _.NumericAxis(fe)),pe.yAxes.size()===0&&!ve.subCharts&&pe.yAxes.add(new _.NumericAxis(fe))),ve.series&&(Ue=pe.renderableSeries).add.apply(Ue,(0,V.buildSeries)(fe,ve.series,ve.sharedData)),ve.modifiers&&(Qe=pe.chartModifiers).add.apply(Qe,(0,I.buildModifiers)(ve.modifiers)),ve.annotations&&(it=pe.annotations).add.apply(it,(0,D.buildAnnotations)(ve.annotations)),ve.subCharts&&!pe.isSubSurface&&ke(ve.subCharts,pe)}dl.configure2DSurface=$e;function Ne(ve,pe,fe){var me,Ce;ve.xAxis?pe.xAxis=(0,F.buildAxis3D)(fe,ve.xAxis):pe.xAxis=new Re.NumericAxis3D(fe),ve.yAxis?pe.yAxis=(0,F.buildAxis3D)(fe,ve.yAxis):pe.yAxis=new Re.NumericAxis3D(fe),ve.zAxis?pe.zAxis=(0,F.buildAxis3D)(fe,ve.zAxis):pe.zAxis=new Re.NumericAxis3D(fe),ve.series&&(me=pe.renderableSeries).add.apply(me,(0,V.buildSeries3D)(fe,ve.series,ve.sharedData)),ve.modifiers&&(Ce=pe.chartModifiers).add.apply(Ce,(0,I.buildModifiers3D)(ve.modifiers))}return dl.configure3DSurface=Ne,dl}var VCe;function Tv(){return VCe||(VCe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.chartBuilder=t.ensureRegistrations=t.configureChart=t.buildChart=t.chartReviver=void 0;var e=di(),i=pa(),n=WS(),r=nne(),o=e$(),a=G3(),s=n$(),l=K3(),u=U_(),c=mo();function d(v,y){switch(v){case"visibleRange":case"visibleRangeLimit":case"visibleRangeSizeLimit":case"growBy":return new e.NumberRange(y.min,y.max);case"padding":var m=y;return new i.Thickness(m.top,m.right,m.bottom,m.left);default:return y===null?NaN:y}}t.chartReviver=d;var f=function(v){return"options"in v?v.options:v};function h(v,y){var m;typeof y=="string"&&(y=JSON.parse(y,d)),y||(y={});var b=(m=y==null?void 0:y.type)!==null&&m!==void 0?m:n.ESciChartSurfaceType.Default2D,S=f(y);if(b===n.ESciChartSurfaceType.Default2D)return(0,u.build2DChart)(v,S);if(b===n.ESciChartSurfaceType.Polar2D)return(0,u.build2DPolarChart)(v,S);if(b===n.ESciChartSurfaceType.Pie2D)return(0,u.buildPieChart)(v,S);if(b===n.ESciChartSurfaceType.Default3D)return(0,u.build3DChart)(v,S);throw new Error("Surface type: ".concat(b," does not exist. See ESciChartSurfaceType for all available types."))}t.buildChart=h;var p=function(v,y,m){var b;typeof m=="string"&&(m=JSON.parse(m,d)),m||(m={});var S=(b=m==null?void 0:m.type)!==null&&b!==void 0?b:n.ESciChartSurfaceType.Default2D,_=f(m);if(S===n.ESciChartSurfaceType.Default2D)(0,u.configure2DSurface)(_,v,y);else if(S!==n.ESciChartSurfaceType.Pie2D)throw new Error("Surface type: ".concat(S," is not yet supported by the builder api"))};t.configureChart=p;var g=function(){};t.ensureRegistrations=g,t.chartBuilder={buildChart:h,chartReviver:d,build2DChart:u.build2DChart,build2DPolarChart:u.build2DPolarChart,buildPieChart:u.buildPieChart,configureChart:t.configureChart,buildSeries:l.buildSeries,buildDataSeries:a.buildDataSeries,buildModifiers:s.buildModifiers,buildAxes:o.buildAxes,buildAnnotations:r.buildAnnotations,registerType:c.registerType,registerWasmType:c.registerWasmType,registerFunction:c.registerFunction,build3DChart:u.build3DChart,buildAxis3D:o.buildAxis3D,buildModifiers3D:s.buildModifiers3D,buildSeries3D:l.buildSeries3D,buildDataSeries3D:a.buildDataSeries3D}})(A9)),A9}var HCe;function nne(){if(HCe)return uN;HCe=1,Object.defineProperty(uN,"__esModule",{value:!0}),uN.buildAnnotations=void 0;var t=HFe(),e=EW(),i=UFe(),n=zFe(),r=Gre(),o=Yre(),a=$Fe(),s=WFe(),l=Qa(),u=rC(),c=dJ(),d=Jz(),f=qFe(),h=XFe(),p=KFe(),g=ga(),v=Tv(),y=mo(),m=FW();(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextAxisMarkerAnnotation,function(S){return new i.AxisMarkerAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextBoxAnnotation,function(S){return new n.BoxAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextHorizontalLineAnnotation,function(S){return new a.HorizontalLineAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextLineAnnotation,function(S){return new u.LineAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextVerticalLineAnnotation,function(S){return new p.VerticalLineAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.SVGTextAnnotation,function(S){return new h.TextAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.SVGCustomAnnotation,function(S){return new r.CustomAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.SVGPolarPointerAnnotation,function(S){return new f.PolarPointerAnnotation(S)}),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.HtmlTextAnnotation,function(S){return new s.HtmlTextAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextNativeTextAnnotation,function(S){return new d.NativeTextAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextArcAnnotation,function(S){return new t.ArcAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.HtmlCustomAnnotation,function(S){return new o.HtmlCustomAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextLineArrowAnnotation,function(S){return new c.LineArrowAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.RenderContextPolarArcAnnotation,function(S){return new e.PolarArcAnnotation(S)},!0),(0,y.registerType)(g.EBaseType.Annotation,l.EAnnotationType.SvgLineAnnotation,function(S){return new m.SvgLineAnnotation(S)},!0);var b=function(S){typeof S=="string"&&(S=JSON.parse(S,v.chartReviver));var _=[];if(Array.isArray(S))for(var C=0,P=S;C<P.length;C++){var x=P[C];_.push((0,y.createType)(g.EBaseType.Annotation,x.type,null,x.options))}else _.push((0,y.createType)(g.EBaseType.Annotation,S.type,null,S.options));return _};return uN.buildAnnotations=b,uN}var QA={},UCe;function nAt(){if(UCe)return QA;UCe=1;var t=QA&&QA.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(QA,"__esModule",{value:!0}),QA.CustomChartModifier2D=void 0;var e=Ho(),i=Qu(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.type=e.EChart2DModifierType.Custom,s}return o})(i.ChartModifierBase2D);return QA.CustomChartModifier2D=n,QA}var LB={},zCe;function oAt(){if(zCe)return LB;zCe=1,Object.defineProperty(LB,"__esModule",{value:!0}),LB.RenderContext2D=void 0;var t=(function(){function e(i){this.canvas2D=i,this.ctx2D=i.getContext("2d")}return e.prototype.drawRect=function(i,n,r,o,a){a===void 0&&(a="rgba(211,211,211,0.5)"),this.clear(),this.ctx2D.fillStyle=a,this.ctx2D.fillRect(i,n,r,o)},e.prototype.drawCircle=function(i,n,r,o){var a=0,s=o;this.clear(),this.ctx2D.beginPath(),this.ctx2D.arc(i,n,r,0,2*Math.PI,!1),this.ctx2D.fillStyle=o,this.ctx2D.fill(),this.ctx2D.lineWidth=a,this.ctx2D.strokeStyle=s,this.ctx2D.stroke()},e.prototype.clear=function(){this.ctx2D.clearRect(0,0,this.canvas2D.width,this.canvas2D.height)},e})();return LB.RenderContext2D=t,LB}var kB={},eO={},$Ce;function one(){if($Ce)return eO;$Ce=1;var t=eO&&eO.__extends||(function(){var a=function(s,l){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,c){u.__proto__=c}||function(u,c){for(var d in c)Object.prototype.hasOwnProperty.call(c,d)&&(u[d]=c[d])},a(s,l)};return function(s,l){if(typeof l!="function"&&l!==null)throw new TypeError("Class extends value "+String(l)+" is not a constructor or null");a(s,l);function u(){this.constructor=s}s.prototype=l===null?Object.create(l):(u.prototype=l.prototype,new u)}})();Object.defineProperty(eO,"__esModule",{value:!0}),eO.SynchronizedLayoutManager=void 0;var e=zS(),i=hl(),n=JP(),r=pa(),o=(function(a){t(s,a);function s(l,u,c){var d=a.call(this,c)||this;return d.type=e.ELayoutManagerType.Synchronised,d.id=(0,i.generateGuid)(),d.lastLeftOuterAreaSize=0,d.lastRightOuterAreaSize=0,d.lastTopOuterAreaSize=0,d.lastBottomOuterAreaSize=0,d.verticalGroup=l??void 0,d.horizontalGroup=u??void 0,d}return s.prototype.layoutChart=function(l,u){var c=this.sciChartSurface.chartTitleRenderer.titleOffset;if(this.verticalGroup&&this.horizontalGroup){var d=r.Thickness.mergeMax(this.verticalGroup.calculateMaxTitleSize(),this.horizontalGroup.calculateMaxTitleSize()),f=r.Thickness.mergeSubtract(d,c),h=r.Thickness.mergeAdd(u,f),p=a.prototype.layoutChart.call(this,l,h);return this.verticalGroup.synchronizeAxisSizes(),this.horizontalGroup.synchronizeAxisSizes(),p}else if(this.verticalGroup){var f=r.Thickness.mergeSubtract(this.verticalGroup.calculateMaxTitleSize(),c),p=a.prototype.layoutChart.call(this,l,r.Thickness.mergeAdd(u,f));return this.verticalGroup.synchronizeAxisSizes(),p}else if(this.horizontalGroup){var f=r.Thickness.mergeSubtract(this.horizontalGroup.calculateMaxTitleSize(),c),p=a.prototype.layoutChart.call(this,l,r.Thickness.mergeAdd(u,f));return this.horizontalGroup.synchronizeAxisSizes(),p}return a.prototype.layoutChart.call(this,l,u)},s.prototype.trySynchronizeLayouts=function(){this.verticalGroup&&(this.lastLeftOuterAreaSize!==this.verticalGroup.groupLeftSize||this.lastRightOuterAreaSize!==this.verticalGroup.groupRightSize)&&this.sciChartSurface.invalidateElement(),this.horizontalGroup&&(this.lastTopOuterAreaSize!==this.horizontalGroup.groupTopSize||this.lastBottomOuterAreaSize!==this.horizontalGroup.groupBottomSize)&&this.sciChartSurface.invalidateElement()},s.prototype.measureLeftOuterAxes=function(){if(a.prototype.measureLeftOuterAxes.call(this),!this.verticalGroup){a.prototype.measureLeftOuterAxes.call(this);return}this.verticalGroup.onLeftSizeChanged(this.id,this.chartLayoutState.leftOuterAreaSize);var l=this.chartLayoutState.leftOuterAreaSize,u=this.verticalGroup.groupLeftSize,c=Math.abs(l)>Math.abs(u)?l:u;if(this.axesGroupedByLayoutStrategy.leftOuterAxes.length>0){var d=this.axesGroupedByLayoutStrategy.leftOuterAxes[this.axesGroupedByLayoutStrategy.leftOuterAxes.length-1],f=this.chartLayoutState.leftOuterAreaSize-d.axisLayoutState.axisSize;d.axisLayoutState.axisSize=c-f}this.chartLayoutState.leftOuterAreaSize=c,this.lastLeftOuterAreaSize=c},s.prototype.measureRightOuterAxes=function(){if(a.prototype.measureRightOuterAxes.call(this),!this.verticalGroup){a.prototype.measureRightOuterAxes.call(this);return}this.verticalGroup.onRightSizeChanged(this.id,this.chartLayoutState.rightOuterAreaSize);var l=this.chartLayoutState.rightOuterAreaSize,u=this.verticalGroup.groupRightSize,c=Math.abs(l)>Math.abs(u)?l:u;if(this.axesGroupedByLayoutStrategy.rightOuterAxes.length>0){var d=this.axesGroupedByLayoutStrategy.rightOuterAxes[this.axesGroupedByLayoutStrategy.rightOuterAxes.length-1],f=this.chartLayoutState.rightOuterAreaSize-d.axisLayoutState.axisSize;d.axisLayoutState.axisSize=c-f}this.chartLayoutState.rightOuterAreaSize=c,this.lastRightOuterAreaSize=c},s.prototype.measureTopOuterAxes=function(){if(a.prototype.measureTopOuterAxes.call(this),!!this.horizontalGroup){this.horizontalGroup.onTopSizeChanged(this.id,this.chartLayoutState.topOuterAreaSize);var l=this.chartLayoutState.topOuterAreaSize,u=this.horizontalGroup.groupTopSize,c=Math.abs(l)>Math.abs(u)?l:u;if(this.axesGroupedByLayoutStrategy.topOuterAxes.length>0){var d=this.axesGroupedByLayoutStrategy.topOuterAxes[this.axesGroupedByLayoutStrategy.topOuterAxes.length-1],f=this.chartLayoutState.topOuterAreaSize-d.axisLayoutState.axisSize;d.axisLayoutState.axisSize=c-f}this.chartLayoutState.topOuterAreaSize=c,this.lastTopOuterAreaSize=c}},s.prototype.measureBottomOuterAxes=function(){if(a.prototype.measureBottomOuterAxes.call(this),!!this.horizontalGroup){this.horizontalGroup.onBottomSizeChanged(this.id,this.chartLayoutState.bottomOuterAreaSize);var l=this.chartLayoutState.bottomOuterAreaSize,u=this.horizontalGroup.groupBottomSize,c=Math.abs(l)>Math.abs(u)?l:u;if(this.axesGroupedByLayoutStrategy.bottomOuterAxes.length>0){var d=this.axesGroupedByLayoutStrategy.bottomOuterAxes[this.axesGroupedByLayoutStrategy.bottomOuterAxes.length-1],f=this.chartLayoutState.bottomOuterAreaSize-d.axisLayoutState.axisSize;d.axisLayoutState.axisSize=c-f}this.chartLayoutState.bottomOuterAreaSize=c,this.lastBottomOuterAreaSize=c}},s})(n.LayoutManager);return eO.SynchronizedLayoutManager=o,eO}var WCe;function aAt(){if(WCe)return kB;WCe=1,Object.defineProperty(kB,"__esModule",{value:!0}),kB.SciChartHorizontalGroup=void 0;var t=pa(),e=zS(),i=JP(),n=one(),r=(function(){function a(){this.groupTopSize=0,this.groupBottomSize=0,this.layoutManagers=[],this.topOuterLayoutSizes={},this.bottomOuterLayoutSizes={}}return a.prototype.addSurfaceToGroup=function(s){var l=s.layoutManager;l.type!==e.ELayoutManagerType.Synchronised?(l=new n.SynchronizedLayoutManager(void 0,this),l.bottomInnerAxesLayoutStrategy=s.layoutManager.bottomInnerAxesLayoutStrategy,l.bottomOuterAxesLayoutStrategy=s.layoutManager.bottomOuterAxesLayoutStrategy,l.leftInnerAxesLayoutStrategy=s.layoutManager.leftInnerAxesLayoutStrategy,l.leftOuterAxesLayoutStrategy=s.layoutManager.leftOuterAxesLayoutStrategy,l.rightInnerAxesLayoutStrategy=s.layoutManager.rightInnerAxesLayoutStrategy,l.rightOuterAxesLayoutStrategy=s.layoutManager.rightOuterAxesLayoutStrategy,l.topInnerAxesLayoutStrategy=s.layoutManager.topInnerAxesLayoutStrategy,l.topOuterAxesLayoutStrategy=s.layoutManager.topOuterAxesLayoutStrategy,s.layoutManager=l):l.horizontalGroup=this,this.layoutManagers.push(l)},a.prototype.removeSurface=function(s){var l=s.layoutManager,u=this.layoutManagers.findIndex(function(d){return d===l});if(u<0)throw new Error("Surface ".concat(s.id," not found in Horizontal Group!"));if(this.layoutManagers.splice(u,1),l.verticalGroup)l.horizontalGroup=void 0;else{var c=new i.LayoutManager;c.leftInnerAxesLayoutStrategy=l.leftInnerAxesLayoutStrategy,c.leftOuterAxesLayoutStrategy=l.leftOuterAxesLayoutStrategy,c.rightInnerAxesLayoutStrategy=l.rightInnerAxesLayoutStrategy,c.rightOuterAxesLayoutStrategy=l.rightOuterAxesLayoutStrategy,c.bottomInnerAxesLayoutStrategy=l.bottomInnerAxesLayoutStrategy,c.bottomOuterAxesLayoutStrategy=l.bottomOuterAxesLayoutStrategy,c.topInnerAxesLayoutStrategy=l.topInnerAxesLayoutStrategy,c.topOuterAxesLayoutStrategy=l.topOuterAxesLayoutStrategy,s.layoutManager=c}s.layoutManager.layoutChart(s.renderSurface.viewportSize,s.chartTitleRenderer.titleOffset),this.onTopSizeChanged(l.id,0),this.onBottomSizeChanged(l.id,0),delete this.topOuterLayoutSizes[l.id],delete this.bottomOuterLayoutSizes[l.id],this.synchronizeAxisSizes(),s.invalidateElement()},a.prototype.calculateMaxTitleSize=function(){var s=new t.Thickness(0,0,0,0);return this.layoutManagers.forEach(function(l){var u=l.sciChartSurface.chartTitleRenderer.titleOffset;s=t.Thickness.mergeMax(s,new t.Thickness(u.top,0,u.bottom,0))}),s},a.prototype.synchronizeAxisSizes=function(){this.layoutManagers.forEach(function(s){s.trySynchronizeLayouts()})},a.prototype.onTopSizeChanged=function(s,l){this.topOuterLayoutSizes[s]=l,this.groupTopSize=o(this.topOuterLayoutSizes)},a.prototype.onBottomSizeChanged=function(s,l){this.bottomOuterLayoutSizes[s]=l,this.groupBottomSize=o(this.bottomOuterLayoutSizes)},a})();kB.SciChartHorizontalGroup=r;var o=function(a){var s=0;return Object.keys(a).forEach(function(l){s=Math.max(s,a[l])}),s};return kB}var IB={},GCe;function sAt(){if(GCe)return IB;GCe=1,Object.defineProperty(IB,"__esModule",{value:!0}),IB.SciChartVerticalGroup=void 0;var t=pa(),e=zS(),i=JP(),n=one(),r=(function(){function a(){this.groupRightSize=0,this.groupLeftSize=0,this.layoutManagers=[],this.leftOuterLayoutSizes={},this.rightOuterLayoutSizes={}}return a.prototype.addSurfaceToGroup=function(s){var l=s.layoutManager;l.type!==e.ELayoutManagerType.Synchronised?(l=new n.SynchronizedLayoutManager(this),l.bottomInnerAxesLayoutStrategy=s.layoutManager.bottomInnerAxesLayoutStrategy,l.bottomOuterAxesLayoutStrategy=s.layoutManager.bottomOuterAxesLayoutStrategy,l.leftInnerAxesLayoutStrategy=s.layoutManager.leftInnerAxesLayoutStrategy,l.leftOuterAxesLayoutStrategy=s.layoutManager.leftOuterAxesLayoutStrategy,l.rightInnerAxesLayoutStrategy=s.layoutManager.rightInnerAxesLayoutStrategy,l.rightOuterAxesLayoutStrategy=s.layoutManager.rightOuterAxesLayoutStrategy,l.topInnerAxesLayoutStrategy=s.layoutManager.topInnerAxesLayoutStrategy,l.topOuterAxesLayoutStrategy=s.layoutManager.topOuterAxesLayoutStrategy,s.layoutManager=l):l.verticalGroup=this,this.layoutManagers.push(l)},a.prototype.removeSurface=function(s){var l=s.layoutManager,u=this.layoutManagers.findIndex(function(d){return d===l});if(u<0)throw new Error("Surface ".concat(s.id," not found in Vertical Group!"));if(this.layoutManagers.splice(u,1),l.horizontalGroup)l.verticalGroup=void 0;else{var c=new i.LayoutManager;c.bottomInnerAxesLayoutStrategy=l.bottomInnerAxesLayoutStrategy,c.bottomOuterAxesLayoutStrategy=l.bottomOuterAxesLayoutStrategy,c.topInnerAxesLayoutStrategy=l.topInnerAxesLayoutStrategy,c.topOuterAxesLayoutStrategy=l.topOuterAxesLayoutStrategy,c.leftInnerAxesLayoutStrategy=l.leftInnerAxesLayoutStrategy,c.leftOuterAxesLayoutStrategy=l.leftOuterAxesLayoutStrategy,c.rightInnerAxesLayoutStrategy=l.rightInnerAxesLayoutStrategy,c.rightOuterAxesLayoutStrategy=l.rightOuterAxesLayoutStrategy,s.layoutManager=c}s.layoutManager.layoutChart(s.renderSurface.viewportSize,s.chartTitleRenderer.titleOffset),this.onLeftSizeChanged(l.id,0),this.onRightSizeChanged(l.id,0),delete this.leftOuterLayoutSizes[l.id],delete this.rightOuterLayoutSizes[l.id],this.synchronizeAxisSizes()},a.prototype.calculateMaxTitleSize=function(){var s=new t.Thickness(0,0,0,0);return this.layoutManagers.forEach(function(l){var u=l.sciChartSurface.chartTitleRenderer.titleOffset;s=t.Thickness.mergeMax(s,new t.Thickness(0,u.right,0,u.left))}),s},a.prototype.synchronizeAxisSizes=function(){this.layoutManagers.forEach(function(s){s.trySynchronizeLayouts()})},a.prototype.onLeftSizeChanged=function(s,l){this.leftOuterLayoutSizes[s]=l,this.groupLeftSize=o(this.leftOuterLayoutSizes)},a.prototype.onRightSizeChanged=function(s,l){this.rightOuterLayoutSizes[s]=l,this.groupRightSize=o(this.rightOuterLayoutSizes)},a})();IB.SciChartVerticalGroup=r;var o=function(a){var s=0;return Object.keys(a).forEach(function(l){s=Math.max(s,a[l])}),s};return IB}var NB={},YCe;function lAt(){if(YCe)return NB;YCe=1,Object.defineProperty(NB,"__esModule",{value:!0}),NB.BasePaletteProvider=void 0;var t=(function(){function e(){}return e.prototype.onAttached=function(i){},e.prototype.onDetached=function(){},e})();return NB.BasePaletteProvider=t,NB}var FB={},qCe;function uAt(){if(qCe)return FB;qCe=1,Object.defineProperty(FB,"__esModule",{value:!0}),FB.MetadataPaletteProvider=void 0;var t=Ti(),e=vS(),i=(function(){function n(){this.strokePaletteMode=e.EStrokePaletteMode.SOLID,this.fillPaletteMode=e.EFillPaletteMode.SOLID}return n.prototype.onAttached=function(r){},n.prototype.onDetached=function(){},n.prototype.overrideFillArgb=function(r,o,a,s,l){if(!(!l||!l.fill))return typeof l.fill=="string"?(0,t.parseColorToUIntArgb)(l.fill):l.fill},n.prototype.overrideStrokeArgb=function(r,o,a,s,l){if(!(!l||!l.stroke))return typeof l.stroke=="string"?(0,t.parseColorToUIntArgb)(l.stroke):l.stroke},n.prototype.overridePointMarkerArgb=function(r,o,a,s,l){if(l){var u=void 0,c=void 0;return typeof l.stroke=="string"?u=(0,t.parseColorToUIntArgb)(l.stroke):u=l.stroke,typeof l.fill=="string"?c=(0,t.parseColorToUIntArgb)(l.fill):c=l.fill,{stroke:u,fill:c}}},n})();return FB.MetadataPaletteProvider=i,FB}var BB={},XCe;function cAt(){if(XCe)return BB;XCe=1,Object.defineProperty(BB,"__esModule",{value:!0}),BB.RenderPassDataCollection=void 0;var t=(function(){function e(){}return e})();return BB.RenderPassDataCollection=t,BB}var tO={},KCe;function ZCe(){if(KCe)return tO;KCe=1,Object.defineProperty(tO,"__esModule",{value:!0}),tO.getAxis3dById=tO.getAxisById=void 0;var t=ci();function e(r,o){return n(r,o)}tO.getAxisById=e;function i(r,o){return n(r,o)}tO.getAxis3dById=i;function n(r,o){t.Guard.notNull(r,"axes");for(var a=0;a<r.size();a++){var s=r.get(a);if(s.id===o)return s}console.warn("scichart getAxisGeneric(): Axis with Id '".concat(o,"' was not found"))}return tO}var rO={},JCe;function dAt(){if(JCe)return rO;JCe=1;var t=rO&&rO.__extends||(function(){var n=function(r,o){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,s){a.__proto__=s}||function(a,s){for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(a[l]=s[l])},n(r,o)};return function(r,o){if(typeof o!="function"&&o!==null)throw new TypeError("Class extends value "+String(o)+" is not a constructor or null");n(r,o);function a(){this.constructor=r}r.prototype=o===null?Object.create(o):(a.prototype=o.prototype,new a)}})();Object.defineProperty(rO,"__esModule",{value:!0}),rO.RadianLabelProvider=void 0;var e=Rm(),i=(function(n){t(r,n);function r(o){o===void 0&&(o={});var a=this,s,l;return a=n.call(this,o)||this,a.maxDenominatorProperty=12,a.errorToleranceProperty=1e-4,a.maxDenominatorProperty=(s=o.maxDenominator)!==null&&s!==void 0?s:a.maxDenominatorProperty,a.errorToleranceProperty=(l=o.errorTolerance)!==null&&l!==void 0?l:a.errorToleranceProperty,a}return Object.defineProperty(r.prototype,"maxDenominator",{get:function(){return this.maxDenominatorProperty},set:function(o){this.maxDenominatorProperty=o},enumerable:!1,configurable:!0}),Object.defineProperty(r.prototype,"errorTolerance",{get:function(){return this.errorToleranceProperty},set:function(o){this.errorToleranceProperty=o},enumerable:!1,configurable:!0}),r.prototype.getGCD=function(o,a){for(;a!==0;)a=o%(o=a);return Math.abs(o)},r.prototype.findFraction=function(o){for(var a=0,s=1,l=1/0,u=1;u<=this.maxDenominatorProperty;u++){var c=Math.round(o*u),d=Math.abs(o-c/u);d<l&&(l=d,a=c,s=u)}if(l<this.errorToleranceProperty){var f=this.getGCD(a,s);return{numerator:a/f,denominator:s/f}}return null},Object.defineProperty(r.prototype,"formatLabel",{get:function(){var o=this;return function(a){var s;if(a===0)return"0";var l=a/Math.PI,u=o.findFraction(l);if(u){if(!u)return a.toString();var c=u.numerator,d=u.denominator;return d===1?c===1?"π":"".concat(c,"π"):c===1?"π/".concat(d):"".concat(c,"π/").concat(d)}return a.toFixed((s=o==null?void 0:o.precision)!==null&&s!==void 0?s:1)}},enumerable:!1,configurable:!0}),r})(e.NumericLabelProvider);return rO.RadianLabelProvider=i,rO}var hp={},v7={},QCe;function AVe(){return QCe||(QCe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.zeroArray2D=void 0;var e=function(i){if(i){for(var n=[],r=0;r<i[0];++r)n.push(i.length===1?0:(0,t.zeroArray2D)(i.slice(1)));return n}};t.zeroArray2D=e})(v7)),v7}var eTe;function fAt(){if(eTe)return hp;eTe=1;var t=hp&&hp.__extends||(function(){var g=function(v,y){return g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(m,b){m.__proto__=b}||function(m,b){for(var S in b)Object.prototype.hasOwnProperty.call(b,S)&&(m[S]=b[S])},g(v,y)};return function(v,y){if(typeof y!="function"&&y!==null)throw new TypeError("Class extends value "+String(y)+" is not a constructor or null");g(v,y);function m(){this.constructor=v}v.prototype=y===null?Object.create(y):(m.prototype=y.prototype,new m)}})(),e=hp&&hp.__assign||function(){return e=Object.assign||function(g){for(var v,y=1,m=arguments.length;y<m;y++){v=arguments[y];for(var b in v)Object.prototype.hasOwnProperty.call(v,b)&&(g[b]=v[b])}return g},e.apply(this,arguments)},i=hp&&hp.__awaiter||function(g,v,y,m){function b(S){return S instanceof y?S:new y(function(_){_(S)})}return new(y||(y=Promise))(function(S,_){function C(E){try{x(m.next(E))}catch(A){_(A)}}function P(E){try{x(m.throw(E))}catch(A){_(A)}}function x(E){E.done?S(E.value):b(E.value).then(C,P)}x((m=m.apply(g,v||[])).next())})},n=hp&&hp.__generator||function(g,v){var y={label:0,sent:function(){if(S[0]&1)throw S[1];return S[1]},trys:[],ops:[]},m,b,S,_;return _={next:C(0),throw:C(1),return:C(2)},typeof Symbol=="function"&&(_[Symbol.iterator]=function(){return this}),_;function C(x){return function(E){return P([x,E])}}function P(x){if(m)throw new TypeError("Generator is already executing.");for(;y;)try{if(m=1,b&&(S=x[0]&2?b.return:x[0]?b.throw||((S=b.return)&&S.call(b),0):b.next)&&!(S=S.call(b,x[1])).done)return S;switch(b=0,S&&(x=[x[0]&2,S.value]),x[0]){case 0:case 1:S=x;break;case 4:return y.label++,{value:x[1],done:!1};case 5:y.label++,b=x[1],x=[0];continue;case 7:x=y.ops.pop(),y.trys.pop();continue;default:if(S=y.trys,!(S=S.length>0&&S[S.length-1])&&(x[0]===6||x[0]===2)){y=0;continue}if(x[0]===3&&(!S||x[1]>S[0]&&x[1]<S[3])){y.label=x[1];break}if(x[0]===6&&y.label<S[1]){y.label=S[1],S=x;break}if(S&&y.label<S[2]){y.label=S[2],y.ops.push(x);break}S[2]&&y.ops.pop(),y.trys.pop();continue}x=v.call(g,y)}catch(E){x=[6,E],b=0}finally{m=S=0}if(x[0]&5)throw x[1];return{value:x[0]?x[1]:void 0,done:!0}}};Object.defineProperty(hp,"__esModule",{value:!0}),hp.HeatmapLegend=void 0;var r=ci(),o=di(),a=AVe(),s=bie(),l=BI(),u=GW(),c=XW(),d=Rg(),f=Br(),h=fo(),p=(function(g){t(v,g);function v(y,m){var b=this,S,_,C,P,x,E,A;b=g.call(this)||this,b.SIZE=100,r.Guard.notNull(y,"sciChartSurface"),b.sciChartSurface=y,b.wasmContext=y.webAssemblyContext2D;var R=(_=(S=m==null?void 0:m.colorMap)===null||S===void 0?void 0:S.minimum)!==null&&_!==void 0?_:0,M=(P=(C=m==null?void 0:m.colorMap)===null||C===void 0?void 0:C.maximum)!==null&&P!==void 0?P:100,D=(E=(x=m==null?void 0:m.colorMap)===null||x===void 0?void 0:x.gradientStops)!==null&&E!==void 0?E:b.getDefaultGradientStops();y.xAxes.add(new l.NumericAxis(b.wasmContext,e({},b.getDefaultXAxisOptions()))),y.yAxes.add(new l.NumericAxis(b.wasmContext,e(e(e({},b.getDefaultYAxisOptions()),m==null?void 0:m.yAxisOptions),{visibleRange:new o.NumberRange(R,M)})));var F=b.getZValues(R,M);return y.renderableSeries.add(new c.UniformHeatmapRenderableSeries(b.wasmContext,{dataSeries:new s.UniformHeatmapDataSeries(b.wasmContext,{xStart:0,xStep:1,yStart:R,yStep:(M-R)/b.SIZE,zValues:F}),useLinearTextureFiltering:!0,colorMap:(A=m==null?void 0:m.colorMap)!==null&&A!==void 0?A:new u.HeatmapColorMap({minimum:R,maximum:M,gradientStops:D})})),b}return v.create=function(y,m){return i(this,void 0,void 0,function(){var b,S,_,C;return n(this,function(P){switch(P.label){case 0:return[4,d.SciChartSurface.create(y,{theme:m==null?void 0:m.theme})];case 1:return b=P.sent(),S=b.sciChartSurface,_=b.wasmContext,C=new v(S,m),[2,{wasmContext:_,heatmapLegend:C}]}})})},v.prototype.delete=function(){this.sciChartSurface=(0,f.deleteSafe)(this.sciChartSurface),this.wasmContext=void 0},Object.defineProperty(v.prototype,"innerSciChartSurface",{get:function(){return{sciChartSurface:this.sciChartSurface,wasmContext:this.wasmContext}},enumerable:!1,configurable:!0}),v.prototype.getDefaultGradientStops=function(){return[{offset:1,color:"Red"},{offset:0,color:"Blue"}]},v.prototype.getDefaultXAxisOptions=function(){return{drawMajorGridLines:!1,drawMinorGridLines:!1,drawMajorTickLines:!1,drawMinorTickLines:!1,drawLabels:!1}},v.prototype.getDefaultYAxisOptions=function(){return{maxAutoTicks:5,drawMajorGridLines:!1,drawMinorGridLines:!1,drawLabels:!0,drawMajorTickLines:!0,drawMinorTickLines:!0}},v.prototype.getZValues=function(y,m){for(var b=(0,a.zeroArray2D)([this.SIZE,1]),S=(m-y)/(this.SIZE-1),_=0,C=y;_<this.SIZE;_++,C+=S)b[_][0]=C;return b},v})(h.DeletableEntity);return hp.HeatmapLegend=p,hp}var iO={},tTe;function hAt(){if(tTe)return iO;tTe=1;var t=iO&&iO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(iO,"__esModule",{value:!0}),iO.ManualLegend=void 0;var e=pa(),i=zy(),n=(function(r){t(o,r);function o(a,s){var l=this,u,c,d;return l=r.call(this,a)||this,l.type=i.ELegendType.ManualLegend,l.itemsProperty=[],l.showCheckboxesProperty=!1,l.showSeriesMarkersProperty=!0,l.showCheckboxesProperty=(u=a==null?void 0:a.showCheckboxes)!==null&&u!==void 0?u:l.showCheckboxes,l.showSeriesMarkersProperty=(c=a==null?void 0:a.showSeriesMarkers)!==null&&c!==void 0?c:l.showSeriesMarkers,l.itemsProperty=(d=a==null?void 0:a.items)!==null&&d!==void 0?d:l.items,l.legendItemCheckedChangedCallback=a==null?void 0:a.isCheckedChangedCallback,s&&l.attachTo(s),l}return Object.defineProperty(o.prototype,"showCheckboxes",{get:function(){return this.showCheckboxesProperty},set:function(a){this.showCheckboxesProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"showSeriesMarkers",{get:function(){return this.showSeriesMarkersProperty},set:function(a){this.showSeriesMarkersProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"items",{get:function(){return this.itemsProperty},set:function(a){this.itemsProperty=a,this.notifyPropertyChanged()},enumerable:!1,configurable:!0}),o.prototype.attachTo=function(a){var s=this;r.prototype.attachTo.call(this,a),a.addDeletable({delete:function(){s.delete(),s.setRootDiv(void 0),s.setInvalidateParentSurface(void 0),s.setParentSurface(void 0)}})},o.prototype.applyTheme=function(){},o.prototype.getInnerHTML=function(){var a,s,l=(a=this.backgroundColor)!==null&&a!==void 0?a:this.parentSurfaceProperty.themeProvider.legendBackgroundBrush,u=(s=this.textColor)!==null&&s!==void 0?s:this.parentSurfaceProperty.themeProvider.labelForegroundBrush,c=this.parentSurfaceProperty.getSeriesViewRectPadding(!1),d=c.left,f=c.top,h=c.right,p=c.bottom,g=this.isExternal()?new e.Thickness(this.margin,this.margin,this.margin,this.margin):new e.Thickness(f+this.margin,h+this.margin,p+this.margin,d+this.margin);return this.getLegendHTML(this.placement,u,l,g,this.orientation,this.showCheckboxes,this.showSeriesMarkers,this.items)},o.prototype.addEventListeners=function(){var a=this;this.items.forEach(function(s){return a.addEventListenerToItem(s)})},o.prototype.addEventListenerToItem=function(a){var s=this,l=this.parentDiv.querySelector("[id='".concat(a.id,"']"));if(l){var u=function(f){a.checked=l.checked,s.legendItemCheckedChangedCallback&&s.legendItemCheckedChangedCallback(a,a.checked,s)};l.addEventListener("change",u);var c={element:l,eventType:"change",eventListener:u,delete:function(){return l.removeEventListener("change",u)}},d=this.eventListenersCollection.get(a.id);d?d.push(c):this.eventListenersCollection.set(a.id,[c])}},o.prototype.removeEventListeners=function(){var a=this;this.items.forEach(function(s){return a.removeEventListenerFromSeries(s.id)})},o})(i.SciChartLegendBase);return iO.ManualLegend=n,iO}var nO={},oO={},rTe;function OVe(){if(rTe)return oO;rTe=1;var t=oO&&oO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(oO,"__esModule",{value:!0}),oO.BandAnimationStyle=void 0;var e=Ti(),i=YS(),n=(function(r){t(o,r);function o(a){var s=this,l,u,c;return s=r.call(this,a)||this,s.strokeY1=(l=a==null?void 0:a.strokeY1)!==null&&l!==void 0?l:s.strokeY1Property,s.fill=(u=a==null?void 0:a.fill)!==null&&u!==void 0?u:s.fillProperty,s.fillY1=(c=a==null?void 0:a.fillY1)!==null&&c!==void 0?c:s.fillY1Property,s}return Object.defineProperty(o.prototype,"strokeY1",{get:function(){return this.strokeY1Property},set:function(a){this.strokeY1Property=a,a&&(this.strokeY1ARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeY1ARGB",{get:function(){return this.strokeY1ARGBProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fill",{get:function(){return this.fillProperty},set:function(a){this.fillProperty=a,a&&(this.fillARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillARGB",{get:function(){return this.fillARGBProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillY1",{get:function(){return this.fillY1Property},set:function(a){this.fillY1Property=a,a&&(this.fillY1ARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillY1ARGB",{get:function(){return this.fillY1ARGBProperty},enumerable:!1,configurable:!0}),o})(i.BaseAnimationStyle);return oO.BandAnimationStyle=n,oO}var iTe;function pAt(){if(iTe)return nO;iTe=1;var t=nO&&nO.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(nO,"__esModule",{value:!0}),nO.BandAnimation=void 0;var e=Gf(),i=Ti(),n=$S(),r=OVe(),o=Bg(),a=(function(s){t(l,s);function l(u){var c=this,d,f;return c=s.call(this,u)||this,c.type=e.EAnimationType.Style,c.duration=(d=u==null?void 0:u.duration)!==null&&d!==void 0?d:1e3,c.styles=u!=null&&u.styles?new r.BandAnimationStyle(u.styles):c.styles,c.dataSeries=(f=u==null?void 0:u.dataSeries)!==null&&f!==void 0?f:c.dataSeries,c}return l.prototype.getSeriesStyle=function(u){var c;if(!u.isStacked)return new r.BandAnimationStyle({stroke:u.stroke,strokeY1:u.strokeY1,fill:u.fill,fillY1:u.fillY1,strokeThickness:u.strokeThickness,opacity:u.opacity,pointMarker:(c=u.pointMarker)===null||c===void 0?void 0:c.getPointMarkerStyle()})},l.prototype.updateSeriesProperties=function(u,c,d){if(s.prototype.updateSeriesProperties.call(this,u,c,d),this.isStyleAnimation){var f=this.styles;if(f.strokeY1!==void 0){var h=n.animationHelpers.interpolateColor(c.strokeY1ARGB,f.strokeY1ARGB,d);u.strokeY1=(0,i.parseArgbToHtmlColor)(h)}if(f.fill!==void 0){var h=n.animationHelpers.interpolateColor(c.fillARGB,f.fillARGB,d);u.fill=(0,i.parseArgbToHtmlColor)(h)}if(f.fillY1!==void 0){var h=n.animationHelpers.interpolateColor(c.fillY1ARGB,f.fillY1ARGB,d);u.fillY1=(0,i.parseArgbToHtmlColor)(h)}}},l})(o.SeriesAnimation);return nO.BandAnimation=a,nO}var aO={},nTe;function gAt(){if(nTe)return aO;nTe=1;var t=aO&&aO.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(aO,"__esModule",{value:!0}),aO.BubbleAnimation=void 0;var e=Gf(),i=Bg(),n=YS(),r=(function(o){t(a,o);function a(s){var l=this,u,c;return l=o.call(this,s)||this,l.type=e.EAnimationType.Style,l.duration=(u=s==null?void 0:s.duration)!==null&&u!==void 0?u:1e3,l.styles=s!=null&&s.styles?new n.BaseAnimationStyle(s.styles):l.styles,l.dataSeries=(c=s==null?void 0:s.dataSeries)!==null&&c!==void 0?c:l.dataSeries,l}return a})(i.SeriesAnimation);return aO.BubbleAnimation=r,aO}var sO={},lO={},uO={},oTe;function ane(){if(oTe)return uO;oTe=1;var t=uO&&uO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(uO,"__esModule",{value:!0}),uO.OhlcAnimationStyle=void 0;var e=Ti(),i=YS(),n=(function(r){t(o,r);function o(a){var s=this,l,u,c;return s=r.call(this,a)||this,s.strokeUp=(l=a==null?void 0:a.strokeUp)!==null&&l!==void 0?l:s.strokeUpProperty,s.strokeDown=(u=a==null?void 0:a.strokeDown)!==null&&u!==void 0?u:s.strokeDownProperty,s.dataPointWidth=(c=a==null?void 0:a.dataPointWidth)!==null&&c!==void 0?c:s.dataPointWidth,s}return Object.defineProperty(o.prototype,"strokeUp",{get:function(){return this.strokeUpProperty},set:function(a){this.strokeUpProperty=a,a&&(this.strokeUpARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeUpARGB",{get:function(){return this.strokeUpARGBProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeDown",{get:function(){return this.strokeDownProperty},set:function(a){this.strokeDownProperty=a,a&&(this.strokeDownARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"strokeDownARGB",{get:function(){return this.strokeDownARGBProperty},enumerable:!1,configurable:!0}),o})(i.BaseAnimationStyle);return uO.OhlcAnimationStyle=n,uO}var aTe;function DVe(){if(aTe)return lO;aTe=1;var t=lO&&lO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(lO,"__esModule",{value:!0}),lO.CandlestickAnimationStyle=void 0;var e=Ti(),i=ane(),n=(function(r){t(o,r);function o(a){var s=this,l,u;return s=r.call(this,a)||this,s.brushUp=(l=a==null?void 0:a.brushUp)!==null&&l!==void 0?l:s.brushUpProperty,s.brushDown=(u=a==null?void 0:a.brushDown)!==null&&u!==void 0?u:s.brushDownProperty,s}return Object.defineProperty(o.prototype,"brushUp",{get:function(){return this.brushUpProperty},set:function(a){this.brushUpProperty=a,a&&(this.brushUpARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"brushUpARGB",{get:function(){return this.brushUpARGBProperty},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"brushDown",{get:function(){return this.brushDownProperty},set:function(a){this.brushDownProperty=a,a&&(this.brushDownARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"brushDownARGB",{get:function(){return this.brushDownARGBProperty},enumerable:!1,configurable:!0}),o})(i.OhlcAnimationStyle);return lO.CandlestickAnimationStyle=n,lO}var cO={},sTe;function RVe(){if(sTe)return cO;sTe=1;var t=cO&&cO.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(cO,"__esModule",{value:!0}),cO.OhlcAnimation=void 0;var e=Gf(),i=Ti(),n=$S(),r=Bg(),o=ane(),a=(function(s){t(l,s);function l(u){var c=this,d,f;return c=s.call(this,u)||this,c.type=e.EAnimationType.Style,c.duration=(d=u==null?void 0:u.duration)!==null&&d!==void 0?d:1e3,c.styles=u!=null&&u.styles?new o.OhlcAnimationStyle(u.styles):c.styles,c.dataSeries=(f=u==null?void 0:u.dataSeries)!==null&&f!==void 0?f:c.dataSeries,c}return l.prototype.getSeriesStyle=function(u){var c;if(!u.isStacked)return new o.OhlcAnimationStyle({stroke:u.stroke,strokeThickness:u.strokeThickness,opacity:u.opacity,strokeUp:u.strokeUp,strokeDown:u.strokeDown,dataPointWidth:u.dataPointWidth,pointMarker:(c=u.pointMarker)===null||c===void 0?void 0:c.getPointMarkerStyle()})},l.prototype.updateSeriesProperties=function(u,c,d){if(s.prototype.updateSeriesProperties.call(this,u,c,d),this.isStyleAnimation){var f=this.styles;if(f.strokeUp!==void 0){var h=n.animationHelpers.interpolateColor(c.strokeUpARGB,f.strokeUpARGB,d);u.strokeUp=(0,i.parseArgbToHtmlColor)(h)}if(f.strokeDown!==void 0){var h=n.animationHelpers.interpolateColor(c.strokeDownARGB,f.strokeDownARGB,d);u.strokeDown=(0,i.parseArgbToHtmlColor)(h)}f.dataPointWidth!==void 0&&(u.dataPointWidth=n.animationHelpers.interpolateNumber(c.dataPointWidth,f.dataPointWidth,d))}},l})(r.SeriesAnimation);return cO.OhlcAnimation=a,cO}var lTe;function vAt(){if(lTe)return sO;lTe=1;var t=sO&&sO.__extends||(function(){var s=function(l,u){return s=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(c,d){c.__proto__=d}||function(c,d){for(var f in d)Object.prototype.hasOwnProperty.call(d,f)&&(c[f]=d[f])},s(l,u)};return function(l,u){if(typeof u!="function"&&u!==null)throw new TypeError("Class extends value "+String(u)+" is not a constructor or null");s(l,u);function c(){this.constructor=l}l.prototype=u===null?Object.create(u):(c.prototype=u.prototype,new c)}})();Object.defineProperty(sO,"__esModule",{value:!0}),sO.CandlestickAnimation=void 0;var e=Gf(),i=Ti(),n=$S(),r=DVe(),o=RVe(),a=(function(s){t(l,s);function l(u){var c=this,d,f;return c=s.call(this,u)||this,c.type=e.EAnimationType.Style,c.duration=(d=u==null?void 0:u.duration)!==null&&d!==void 0?d:1e3,c.styles=u!=null&&u.styles?new r.CandlestickAnimationStyle(u.styles):c.styles,c.dataSeries=(f=u==null?void 0:u.dataSeries)!==null&&f!==void 0?f:c.dataSeries,c}return l.prototype.getSeriesStyle=function(u){var c;if(!u.isStacked)return new r.CandlestickAnimationStyle({stroke:u.stroke,strokeThickness:u.strokeThickness,opacity:u.opacity,strokeUp:u.strokeUp,strokeDown:u.strokeDown,brushUp:u.brushUp,brushDown:u.brushDown,pointMarker:(c=u.pointMarker)===null||c===void 0?void 0:c.getPointMarkerStyle()})},l.prototype.updateSeriesProperties=function(u,c,d){if(s.prototype.updateSeriesProperties.call(this,u,c,d),this.isStyleAnimation){var f=this.styles;if(f.brushUp!==void 0){var h=n.animationHelpers.interpolateColor(c.brushUpARGB,f.brushUpARGB,d);u.brushUp=(0,i.parseArgbToHtmlColor)(h)}if(f.brushDown!==void 0){var h=n.animationHelpers.interpolateColor(c.brushDownARGB,f.brushDownARGB,d);u.brushDown=(0,i.parseArgbToHtmlColor)(h)}}},l})(o.OhlcAnimation);return sO.CandlestickAnimation=a,sO}var dO={},fO={},uTe;function MVe(){if(uTe)return fO;uTe=1;var t=fO&&fO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(fO,"__esModule",{value:!0}),fO.ColumnAnimationStyle=void 0;var e=Ti(),i=YS(),n=(function(r){t(o,r);function o(a){var s=this,l,u,c;return s=r.call(this,a)||this,s.fill=(l=a==null?void 0:a.fill)!==null&&l!==void 0?l:s.fillProperty,s.zeroLineY=(u=a==null?void 0:a.zeroLineY)!==null&&u!==void 0?u:s.zeroLineY,s.dataPointWidth=(c=a==null?void 0:a.dataPointWidth)!==null&&c!==void 0?c:s.dataPointWidth,s}return Object.defineProperty(o.prototype,"fill",{get:function(){return this.fillProperty},set:function(a){this.fillProperty=a,a&&(this.fillARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillARGB",{get:function(){return this.fillARGBProperty},enumerable:!1,configurable:!0}),o})(i.BaseAnimationStyle);return fO.ColumnAnimationStyle=n,fO}var cTe;function yAt(){if(cTe)return dO;cTe=1;var t=dO&&dO.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(dO,"__esModule",{value:!0}),dO.ColumnAnimation=void 0;var e=Gf(),i=Ti(),n=$S(),r=Bg(),o=MVe(),a=RI(),s=(function(l){t(u,l);function u(c){var d=this,f,h;return d=l.call(this,c)||this,d.type=e.EAnimationType.Style,d.duration=(f=c==null?void 0:c.duration)!==null&&f!==void 0?f:1e3,d.styles=c!=null&&c.styles?new o.ColumnAnimationStyle(c.styles):d.styles,d.dataSeries=(h=c==null?void 0:c.dataSeries)!==null&&h!==void 0?h:d.dataSeries,d}return u.prototype.getSeriesStyle=function(c){var d,f;if(!c.isStacked)return new o.ColumnAnimationStyle({stroke:c.stroke,strokeThickness:c.strokeThickness,opacity:c.opacity,pointMarker:(f=(d=c.pointMarker)===null||d===void 0?void 0:d.getPointMarkerStyle())!==null&&f!==void 0?f:new a.PointMarkerStyle,fill:c.fill,zeroLineY:c.zeroLineY,dataPointWidth:c.dataPointWidth})},u.prototype.updateSeriesProperties=function(c,d,f){if(l.prototype.updateSeriesProperties.call(this,c,d,f),this.isStyleAnimation){var h=this.styles;if(h.fill!==void 0){var p=n.animationHelpers.interpolateColor(d.fillARGB,h.fillARGB,f);c.fill=(0,i.parseArgbToHtmlColor)(p)}h.zeroLineY!==void 0&&(c.zeroLineY=n.animationHelpers.interpolateNumber(d.zeroLineY,h.zeroLineY,f)),h.dataPointWidth!==void 0&&(c.dataPointWidth=n.animationHelpers.interpolateNumber(d.dataPointWidth,h.dataPointWidth,f))}},u})(r.SeriesAnimation);return dO.ColumnAnimation=s,dO}var hO={},dTe;function mAt(){if(dTe)return hO;dTe=1;var t=hO&&hO.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(hO,"__esModule",{value:!0}),hO.LineAnimation=void 0;var e=Gf(),i=Bg(),n=YS(),r=(function(o){t(a,o);function a(s){var l=this,u,c;return l=o.call(this,s)||this,l.type=e.EAnimationType.Style,l.duration=(u=s==null?void 0:s.duration)!==null&&u!==void 0?u:1e3,l.styles=s!=null&&s.styles?new n.BaseAnimationStyle(s.styles):l.styles,l.dataSeries=(c=s==null?void 0:s.dataSeries)!==null&&c!==void 0?c:l.dataSeries,l}return a})(i.SeriesAnimation);return hO.LineAnimation=r,hO}var pO={},gO={},fTe;function LVe(){if(fTe)return gO;fTe=1;var t=gO&&gO.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(gO,"__esModule",{value:!0}),gO.MountainAnimationStyle=void 0;var e=Ti(),i=YS(),n=(function(r){t(o,r);function o(a){var s=this,l,u;return s=r.call(this,a)||this,s.fill=(l=a==null?void 0:a.fill)!==null&&l!==void 0?l:s.fillProperty,s.zeroLineY=(u=a==null?void 0:a.zeroLineY)!==null&&u!==void 0?u:s.zeroLineY,s}return Object.defineProperty(o.prototype,"fill",{get:function(){return this.fillProperty},set:function(a){this.fillProperty=a,a&&(this.fillARGBProperty=(0,e.parseColorToUIntArgb)(a))},enumerable:!1,configurable:!0}),Object.defineProperty(o.prototype,"fillARGB",{get:function(){return this.fillARGBProperty},enumerable:!1,configurable:!0}),o})(i.BaseAnimationStyle);return gO.MountainAnimationStyle=n,gO}var hTe;function bAt(){if(hTe)return pO;hTe=1;var t=pO&&pO.__extends||(function(){var l=function(u,c){return l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,f){d.__proto__=f}||function(d,f){for(var h in f)Object.prototype.hasOwnProperty.call(f,h)&&(d[h]=f[h])},l(u,c)};return function(u,c){if(typeof c!="function"&&c!==null)throw new TypeError("Class extends value "+String(c)+" is not a constructor or null");l(u,c);function d(){this.constructor=u}u.prototype=c===null?Object.create(c):(d.prototype=c.prototype,new d)}})();Object.defineProperty(pO,"__esModule",{value:!0}),pO.MountainAnimation=void 0;var e=Gf(),i=Ti(),n=$S(),r=Bg(),o=LVe(),a=RI(),s=(function(l){t(u,l);function u(c){var d=this,f,h;return d=l.call(this,c)||this,d.type=e.EAnimationType.Style,d.duration=(f=c==null?void 0:c.duration)!==null&&f!==void 0?f:1e3,d.styles=c!=null&&c.styles?new o.MountainAnimationStyle(c.styles):d.styles,d.dataSeries=(h=c==null?void 0:c.dataSeries)!==null&&h!==void 0?h:d.dataSeries,d}return u.prototype.getSeriesStyle=function(c){var d,f;if(!c.isStacked)return new o.MountainAnimationStyle({stroke:c.stroke,strokeThickness:c.strokeThickness,opacity:c.opacity,pointMarker:(f=(d=c.pointMarker)===null||d===void 0?void 0:d.getPointMarkerStyle())!==null&&f!==void 0?f:new a.PointMarkerStyle,fill:c.fill,zeroLineY:c.zeroLineY})},u.prototype.updateSeriesProperties=function(c,d,f){if(l.prototype.updateSeriesProperties.call(this,c,d,f),this.isStyleAnimation){var h=this.styles;if(h.fill!==void 0){var p=n.animationHelpers.interpolateColor(d.fillARGB,h.fillARGB,f);c.fill=(0,i.parseArgbToHtmlColor)(p)}h.zeroLineY!==void 0&&(c.zeroLineY=n.animationHelpers.interpolateNumber(d.zeroLineY,h.zeroLineY,f))}},u})(r.SeriesAnimation);return pO.MountainAnimation=s,pO}var vO={},pTe;function SAt(){if(pTe)return vO;pTe=1;var t=vO&&vO.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(vO,"__esModule",{value:!0}),vO.ScatterAnimation=void 0;var e=Gf(),i=Bg(),n=YS(),r=(function(o){t(a,o);function a(s){var l=this,u,c;return l=o.call(this,s)||this,l.type=e.EAnimationType.Style,l.duration=(u=s==null?void 0:s.duration)!==null&&u!==void 0?u:1e3,l.styles=s!=null&&s.styles?new n.BaseAnimationStyle(s.styles):l.styles,l.dataSeries=(c=s==null?void 0:s.dataSeries)!==null&&c!==void 0?c:l.dataSeries,l}return a})(i.SeriesAnimation);return vO.ScatterAnimation=r,vO}var yO={},y7={},gTe;function sne(){return gTe||(gTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EColorPickMode=void 0,(function(e){e.Discrete="Discrete",e.Interpolated="Interpolated"})(t.EColorPickMode||(t.EColorPickMode={}))})(y7)),y7}var m7={},vTe;function s$(){return vTe||(vTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.validateColorStops=t.HEIGHT_SERIES_MAX_TEXTURE_SIZE=void 0,t.HEIGHT_SERIES_MAX_TEXTURE_SIZE=1024;function e(i){if(!i)return!0;if(i.colorStops.length<2)throw new Error("Must define at least 2 colorStops");for(var n=Number.MAX_VALUE,r=i.colorStops,o=r[0].dataValue,a=r[r.length-1].dataValue,s=0;s<r.length-1;s++){if(r[s].dataValue>=r[s+1].dataValue)throw new Error("colorStops must be unique and in ascending order");n=Math.min(n,r[s+1].dataValue-r[s].dataValue)}if((a-o)/n>t.HEIGHT_SERIES_MAX_TEXTURE_SIZE)throw new Error("Unsupported stop configuration. The range can be at most ".concat(t.HEIGHT_SERIES_MAX_TEXTURE_SIZE,` times the smallest difference between stops.
        If you need more resolution than this, use a Fill PaletteProvider`));return!0}t.validateColorStops=e})(m7)),m7}var b7={},yTe;function kVe(){return yTe||(yTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EHeightSeriesMode=void 0,(function(e){e.Perpendicular="Perpendicular",e.Vertical="Vertical",e.Horizontal="Horizontal"})(t.EHeightSeriesMode||(t.EHeightSeriesMode={}))})(b7)),b7}var mTe;function _At(){if(mTe)return yO;mTe=1;var t=yO&&yO.__extends||(function(){var h=function(p,g){return h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(v,y){v.__proto__=y}||function(v,y){for(var m in y)Object.prototype.hasOwnProperty.call(y,m)&&(v[m]=y[m])},h(p,g)};return function(p,g){if(typeof g!="function"&&g!==null)throw new TypeError("Class extends value "+String(g)+" is not a constructor or null");h(p,g);function v(){this.constructor=p}p.prototype=g===null?Object.create(g):(v.prototype=g.prototype,new v)}})();Object.defineProperty(yO,"__esModule",{value:!0}),yO.HeightSeriesDrawingProvider=void 0;var e=Br(),i=sne(),n=s$(),r=Ti(),o=tu(),a=Ls(),s=vS(),l=an(),u=un(),c=du(),d=kVe(),f=(function(h){t(p,h);function p(g,v,y,m){var b=h.call(this,g,v,y)||this;return b.args=new b.webAssemblyContext.SCRTHeightSeriesParams,b.colorSettings=new b.webAssemblyContext.SCRTHeightColorSettings,b.zSelector=m??(function(S){return S.zValues}),b.linesPenCache=new a.Pen2DCache(g),b.fillBrushCache=new o.BrushCache(g),b}return p.prototype.onAttachSeries=function(){h.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTHeightSeriesDrawingProvider;var g=this.parentSeries,v=g.stroke,y=g.strokeThickness,m=g.fill,b=g.opacity,S=g.strokeDashArray,_=g.customTextureOptions;(0,a.createPenInCache)(this.linesPenCache,v,y,b,S),this.fillBrushCache.create(m,b,1,1,void 0,_)},p.prototype.onDetachSeries=function(){h.prototype.onDetachSeries.call(this),this.delete()},p.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),this.linesPenCache=(0,e.deleteSafe)(this.linesPenCache),this.fillBrushCache=(0,e.deleteSafe)(this.fillBrushCache),h.prototype.delete.call(this)},p.prototype.draw=function(g,v){var y,m=v.pointSeries;this.args.Reset(),this.colorSettings.Reset();var b=(0,o.getScrtBrushFromCache)(this.fillBrushCache);b&&this.args.SetFillBrush(b);var S=this.parentSeries,_=S.zMultiplier,C=S.zLimits,P=S.paletteProvider,x=S.normalise,E=S.isInverseHeight,A=S.strokeThickness,R=S.heightMode,M=S.dataSeries;this.args.zMultiplier=_,this.args.isInverseHeight=E,this.args.normaliseHeights=x;var D=(0,a.getScrtPenFromCache)(this.linesPenCache);D&&A>0&&this.args.SetEdgePen(D);var F=v.xCoordinateCalculator.isCategoryCoordinateCalculator,I=m.xValues,V=F?m.indexes:I,z=this.ySelector(m),G=this.zSelector(m);if(x&&(!C||C.max===Number.MAX_VALUE)){var H=void 0;try{H=this.webAssemblyContext.NumberUtil.MinMax(G,M==null?void 0:M.dataDistributionCalculator.containsNaN),this.args.minHeight=H.minD,this.args.maxHeight=H.maxD}finally{(0,e.deleteSafe)(H)}}else this.args.minHeight=C.min,this.args.maxHeight=C.max;var U=this.getStartAndCount(v,V),k=U.startIndex,X=U.count;this.args.startIndex=Math.max(0,k-1),this.args.count=Math.min(V.size(),X+1),this.args.verticalChart=v.isVerticalChart,R===d.EHeightSeriesMode.Horizontal?this.args.SetNormalDirection(v.isVerticalChart?(0,l.getVector3)(this.webAssemblyContext,0,1,0):(0,l.getVector3)(this.webAssemblyContext,1,0,0)):R===d.EHeightSeriesMode.Vertical&&this.args.SetNormalDirection(v.isVerticalChart?(0,l.getVector3)(this.webAssemblyContext,1,0,0):(0,l.getVector3)(this.webAssemblyContext,0,1,0));var W=P.overrideFillArgb!==void 0;if(W&&(h.prototype.applyStrokeFillPaletting.call(this,this.parentSeries.stroke,D,this.parentSeries.fill,b,this.parentSeries.opacity,!1,!0,v),this.args.SetPalettedColors(this.palettingState.palettedColors),this.args.paletteStart=this.palettingState.paletteStartIndex,this.args.interpolate=this.palettingState.gradientPaletting),this.parentSeries.colorSettings){var Y=this.parentSeries.colorSettings.colorStops;(0,n.validateColorStops)(this.parentSeries.colorSettings);for(var te=0,oe=Y;te<oe.length;te++){var de=oe[te];this.colorSettings.AddColorStop(de.dataValue,(0,r.parseColorToUIntArgb)(de.color))}this.parentSeries.colorSettings.infraColor&&(this.colorSettings.m_uiInfra=(0,r.parseColorToUIntArgb)(this.parentSeries.colorSettings.infraColor)),this.parentSeries.colorSettings.ultraColor&&(this.colorSettings.m_uiUltra=(0,r.parseColorToUIntArgb)(this.parentSeries.colorSettings.ultraColor)),this.colorSettings.m_fMinHeight=Y[0].dataValue,this.colorSettings.m_fMaxHeight=Y[Y.length-1].dataValue,this.colorSettings.m_bIsGradient=this.parentSeries.colorSettings.colorPickMode===i.EColorPickMode.Interpolated,this.args.interpolate=this.parentSeries.colorSettings.fillMode===s.EFillPaletteMode.GRADIENT,this.colorSettings.m_fMaxTextureSize=(y=this.parentSeries.colorSettings.maxTextureSize)!==null&&y!==void 0?y:0,this.args.SetHeightColors(this.colorSettings)}this.parentSeries.heightsForColoringDataSeries&&this.args.SetHeightsForColoring(this.parentSeries.getHeightsForColoring(m.resampled)),this.args.SetXValues(V),this.args.SetYValues(z),this.args.SetZValues(G),this.args.SetXCoordinateCalculator(v.xCoordinateCalculator.nativeCalculator),this.args.SetYCoordinateCalculator(v.yCoordinateCalculator.nativeCalculator),this.args.SetNativeContext(g.getNativeContext()),this.nativeDrawingProvider.DrawPointsVec(this.args)},p.prototype.onDpiChanged=function(g){h.prototype.onDpiChanged.call(this,g),this.onSeriesPropertyChange(u.PROPERTY.STROKE)},p.prototype.onSeriesPropertyChange=function(g){h.prototype.onSeriesPropertyChange.call(this,g);var v=this.parentSeries,y=v.stroke,m=v.strokeThickness,b=v.fill,S=v.opacity,_=v.strokeDashArray,C=v.customTextureOptions;(g===u.PROPERTY.STROKE||g===u.PROPERTY.STROKE_THICKNESS||g===u.PROPERTY.OPACITY||g===u.PROPERTY.STROKE_DASH_ARRAY)&&(this.palettingState.requiresUpdate=!0,(0,a.createPenInCache)(this.linesPenCache,y,m,S,_)),(g===u.PROPERTY.FILL||g===u.PROPERTY.OPACITY||g===u.PROPERTY.CUSTOM_TEXTURE_OPTIONS)&&(this.palettingState.requiresUpdate=!0,this.fillBrushCache.create(b,S,1,1,void 0,C))},p})(c.BaseSeriesDrawingProvider);return yO.HeightSeriesDrawingProvider=f,yO}var mO={},bTe;function PAt(){if(bTe)return mO;bTe=1;var t=mO&&mO.__extends||(function(){var c=function(d,f){return c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,p){h.__proto__=p}||function(h,p){for(var g in p)Object.prototype.hasOwnProperty.call(p,g)&&(h[g]=p[g])},c(d,f)};return function(d,f){if(typeof f!="function"&&f!==null)throw new TypeError("Class extends value "+String(f)+" is not a constructor or null");c(d,f);function h(){this.constructor=d}d.prototype=f===null?Object.create(f):(h.prototype=f.prototype,new h)}})();Object.defineProperty(mO,"__esModule",{value:!0}),mO.SmearSeriesDrawingProvider=void 0;var e=Br(),i=sne(),n=Ju(),r=s$(),o=Ti(),a=du(),s=Bu(),l=di(),u=(function(c){t(d,c);function d(f,h,p,g,v){var y=c.call(this,f,h,p)||this;return y.valuesUpdateRequired=!0,y.args=new y.webAssemblyContext.SCRTSmearSeriesParams,y.colorSettings=new y.webAssemblyContext.SCRTHeightColorSettings,y.yColorSelector=v??(function(m){return m.getNativeXValues()}),y.zColorSelector=g??(function(m){return m.getNativeYValues()}),y}return d.prototype.onAttachSeries=function(){c.prototype.onAttachSeries.call(this),this.nativeDrawingProvider=new this.webAssemblyContext.SCRTSmearSeriesDrawingProvider;var f=this.parentSeries;f.stroke,f.strokeThickness,f.opacity},d.prototype.onDetachSeries=function(){c.prototype.onDetachSeries.call(this),this.delete()},d.prototype.delete=function(){this.nativeDrawingProvider=(0,e.deleteSafe)(this.nativeDrawingProvider),this.args=(0,e.deleteSafe)(this.args),c.prototype.delete.call(this)},d.prototype.draw=function(f,h){var p,g=h.pointSeries;this.colorSettings.Reset();var v=h.xCoordinateCalculator.isCategoryCoordinateCalculator,y=g.xValues,m=this.parentSeries.colorDataSeries,b=v?g.indexes:y,S=this.ySelector(g),_=this.yColorSelector(m),C=this.zColorSelector(m);this.args.SetX(b),this.args.SetY(S);var P=this.getStartAndCount(h,b),x=P.startIndex,E=P.count;if(this.args.m_iStartIndex=x,this.args.m_iCount=E,this.args.m_dYOffset=this.parentSeries.yOffset,this.args.smoothColors=this.parentSeries.smoothColors,!(E<2)){performance.now();var A=(0,s.getWindowedYRange)(this.webAssemblyContext,g.xValues,g.yValues,v?new l.NumberRange(0,g.count-1):new l.NumberRange(h.xCoordinateCalculator.visibleMin,h.xCoordinateCalculator.visibleMax),!0,v,this.parentSeries.dataSeries.dataDistributionCalculator.isSortedAscending,this.parentSeries.dataSeries.dataDistributionCalculator.containsNaN),R=_.size(),M=new l.NumberRange(h.yCoordinateCalculator.visibleMin-A.max,h.yCoordinateCalculator.visibleMax-A.min),D=(0,s.getIndicesRange)(this.webAssemblyContext,_,M,m.dataDistributionCalculator.isSortedAscending);if(this.args.m_iColorStartIndex=Math.min(R-2,D.min),this.args.m_iColorCount=Math.max(2,D.diff+1),this.parentSeries.colorSettings){var F=this.parentSeries.colorSettings.colorStops;(0,r.validateColorStops)(this.parentSeries.colorSettings);for(var I=0,V=F;I<V.length;I++){var z=V[I],G=(0,o.parseColorToUIntArgb)(z.color);this.colorSettings.AddColorStop(z.dataValue,G)}this.parentSeries.colorSettings.infraColor&&(this.colorSettings.m_uiInfra=(0,o.parseColorToUIntArgb)(this.parentSeries.colorSettings.infraColor)),this.parentSeries.colorSettings.ultraColor&&(this.colorSettings.m_uiUltra=(0,o.parseColorToUIntArgb)(this.parentSeries.colorSettings.ultraColor)),this.colorSettings.m_fMinHeight=F[0].dataValue,this.colorSettings.m_fMaxHeight=F[F.length-1].dataValue,this.colorSettings.m_bIsGradient=this.parentSeries.colorSettings.colorPickMode===i.EColorPickMode.Interpolated,this.colorSettings.m_fMaxTextureSize=(p=this.parentSeries.colorSettings.maxTextureSize)!==null&&p!==void 0?p:0,this.args.SetHeightColors(this.colorSettings),this.args.SetColorZvalues(C)}else if(this.parentSeries.paletteProvider){var H=this.parentSeries.paletteProvider,U=this.parentSeries.paletteProvider,k=(0,n.uintArgbColorMultiplyOpacity)((0,o.parseColorToUIntArgb)(this.parentSeries.stroke),this.parentSeries.opacity);this.palettingState.palettedColors||(this.palettingState.palettedColors=new this.webAssemblyContext.UIntVector);var X=_.size();if(H.applyPaletting){H.applyPaletting(this.palettingState,_,C,m.getNativeIndexes(),0,X);return}if(this.palettingState.palettedColors.clear(),this.palettingState.palettedColors.reserve(X),U.overrideStrokeArgb)for(var W=0;W<X;W++){var Y=_.get(W),te=C.get(W),oe=U.overrideStrokeArgb(Y,te,W,this.parentSeries.opacity,m.getMetadataAt(W));this.palettingState.palettedColors.push_back(oe||k)}else for(var W=0;W<X;W++)this.palettingState.palettedColors.push_back(C.get(W));this.palettingState.requiresUpdate=!1,this.args.SetColors(this.palettingState.palettedColors)}var de=f.getNativeContext();performance.now(),this.nativeDrawingProvider.CreateSmearSeriesColorsTexture(_,h.yCoordinateCalculator.nativeCalculator,this.args),performance.now(),this.nativeDrawingProvider.CreateSmearSeriesValuesTexture(h.xCoordinateCalculator.nativeCalculator,h.yCoordinateCalculator.nativeCalculator,this.args),this.valuesUpdateRequired=!1,performance.now(),this.nativeDrawingProvider.DrawSmearSeries(de,this.args)}},d.prototype.onDpiChanged=function(f){c.prototype.onDpiChanged.call(this,f)},d.prototype.onSeriesPropertyChange=function(f){c.prototype.onSeriesPropertyChange.call(this,f)},d.prototype.seriesHasDataChanges=function(){this.valuesUpdateRequired=!0},d.prototype.seriesHasColorChanges=function(){this.palettingState.requiresUpdate=!0},d})(a.BaseSeriesDrawingProvider);return mO.SmearSeriesDrawingProvider=u,mO}var bO={},STe;function CAt(){if(STe)return bO;STe=1;var t=bO&&bO.__extends||(function(){var d=function(f,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,g){p.__proto__=g}||function(p,g){for(var v in g)Object.prototype.hasOwnProperty.call(g,v)&&(p[v]=g[v])},d(f,h)};return function(f,h){if(typeof h!="function"&&h!==null)throw new TypeError("Class extends value "+String(h)+" is not a constructor or null");d(f,h);function p(){this.constructor=f}f.prototype=h===null?Object.create(h):(p.prototype=h.prototype,new p)}})();Object.defineProperty(bO,"__esModule",{value:!0}),bO.PolarLineSeriesHitTestProvider=void 0;var e=$i(),i=tl(),n=vl(),r=gl(),o=Ca(),a=Eo(),s=gR(),l=Zi(),u=10,c=(function(d){t(f,d);function f(){return d!==null&&d.apply(this,arguments)||this}return f.prototype.hitTest=function(h,p,g){var v=this;g===void 0&&(g=u);var y=this.getTranslatedHitTestPoint(h,p);if(!y)return i.HitTestInfo.empty();var m=this.currentRenderPassData,b=m.xCoordinateCalculator,S=m.yCoordinateCalculator,_=m.isVerticalChart,C=y.x,P=y.y,x=this.parentSeries.dataSeries;if(!x)return i.HitTestInfo.empty();var E=x.getNativeXValues(),A=x.getNativeYValues(),R=this.parentSeries.xAxis,M=function(oe){var de=E.get(oe),ge=A.get(oe),Ee=b.getCoordinate(de),Re=S.getCoordinate(ge),Ae=_?Re:Ee,Pe=_?Ee:Re,we=r.annotationHelpers.convertPolarToCartesian(R,!1,v.webAssemblyContext,o.ECoordinateMode.Pixel,Ae*l.DpiHelper.PIXEL_RATIO,Pe);return new e.Point(we.x,we.y)},D=Number.MAX_VALUE,F=-1,I=function(oe,de,ge){oe<D&&(D=oe,F=de)};if(x.count()>0){var V=M(0),z=(0,a.calcDistance)(C,P,V.x,V.y);I(z,0);for(var G=1;G<x.count();G++){var H=M(G),U=(0,a.calcDistance)(V.x,V.y,H.x,H.y),k=(0,a.calcDistance)(C,P,H.x,H.y);I(k,G);var X=z<U&&k<U;if(X){var W=(0,a.calcDistanceFromLine)(C,P,V.x,V.y,H.x,H.y);W<D&&(z<k?I(W,G-1):I(W,G))}V=H,z=k}}var Y=R.reverseTransform(y.x,y.y),te=n.hitTestHelpers.createHitTestInfo(this.parentSeries,b,S,_,x,E,A,Y.x,Y.y,F,g);return te.isHit=D<g,te},f})(s.PolarDataPointHitTestProvider);return bO.PolarLineSeriesHitTestProvider=c,bO}var SO={},_Te;function TAt(){if(_Te)return SO;_Te=1;var t=SO&&SO.__extends||(function(){var o=function(a,s){return o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(l,u){l.__proto__=u}||function(l,u){for(var c in u)Object.prototype.hasOwnProperty.call(u,c)&&(l[c]=u[c])},o(a,s)};return function(a,s){if(typeof s!="function"&&s!==null)throw new TypeError("Class extends value "+String(s)+" is not a constructor or null");o(a,s);function l(){this.constructor=a}a.prototype=s===null?Object.create(s):(l.prototype=s.prototype,new l)}})();Object.defineProperty(SO,"__esModule",{value:!0}),SO.BaseRenderDataTransformJS=void 0;var e=di(),i=jI(),n=Cv(),r=(function(o){t(a,o);function a(){return o!==null&&o.apply(this,arguments)||this}return a.prototype.createPointSeries=function(){return new i.BasePointSeriesResampled(this.wasmContext,new e.NumberRange(0,0))},a.prototype.runTransformInternal=function(s){throw new Error("runTransformInternal not implemented.")},a})(n.BaseRenderDataTransform);return SO.BaseRenderDataTransformJS=r,SO}var pp={},PTe;function xAt(){if(PTe)return pp;PTe=1;var t=pp&&pp.__extends||(function(){var m=function(b,S){return m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(_,C){_.__proto__=C}||function(_,C){for(var P in C)Object.prototype.hasOwnProperty.call(C,P)&&(_[P]=C[P])},m(b,S)};return function(b,S){if(typeof S!="function"&&S!==null)throw new TypeError("Class extends value "+String(S)+" is not a constructor or null");m(b,S);function _(){this.constructor=b}b.prototype=S===null?Object.create(S):(_.prototype=S.prototype,new _)}})(),e=pp&&pp.__assign||function(){return e=Object.assign||function(m){for(var b,S=1,_=arguments.length;S<_;S++){b=arguments[S];for(var C in b)Object.prototype.hasOwnProperty.call(b,C)&&(m[C]=b[C])}return m},e.apply(this,arguments)},i=pp&&pp.__awaiter||function(m,b,S,_){function C(P){return P instanceof S?P:new S(function(x){x(P)})}return new(S||(S=Promise))(function(P,x){function E(M){try{R(_.next(M))}catch(D){x(D)}}function A(M){try{R(_.throw(M))}catch(D){x(D)}}function R(M){M.done?P(M.value):C(M.value).then(E,A)}R((_=_.apply(m,b||[])).next())})},n=pp&&pp.__generator||function(m,b){var S={label:0,sent:function(){if(P[0]&1)throw P[1];return P[1]},trys:[],ops:[]},_,C,P,x;return x={next:E(0),throw:E(1),return:E(2)},typeof Symbol=="function"&&(x[Symbol.iterator]=function(){return this}),x;function E(R){return function(M){return A([R,M])}}function A(R){if(_)throw new TypeError("Generator is already executing.");for(;S;)try{if(_=1,C&&(P=R[0]&2?C.return:R[0]?C.throw||((P=C.return)&&P.call(C),0):C.next)&&!(P=P.call(C,R[1])).done)return P;switch(C=0,P&&(R=[R[0]&2,P.value]),R[0]){case 0:case 1:P=R;break;case 4:return S.label++,{value:R[1],done:!1};case 5:S.label++,C=R[1],R=[0];continue;case 7:R=S.ops.pop(),S.trys.pop();continue;default:if(P=S.trys,!(P=P.length>0&&P[P.length-1])&&(R[0]===6||R[0]===2)){S=0;continue}if(R[0]===3&&(!P||R[1]>P[0]&&R[1]<P[3])){S.label=R[1];break}if(R[0]===6&&S.label<P[1]){S.label=P[1],P=R;break}if(P&&S.label<P[2]){S.label=P[2],S.ops.push(R);break}P[2]&&S.ops.pop(),S.trys.pop();continue}R=b.call(m,S)}catch(M){R=[6,M],C=0}finally{_=P=0}if(R[0]&5)throw R[1];return{value:R[0]?R[1]:void 0,done:!0}}};Object.defineProperty(pp,"__esModule",{value:!0}),pp.SciChartOverview=void 0;var r=K3(),o=fo(),a=di(),s=tR(),l=ud(),u=wie(),c=NW(),d=RW(),f=_ie(),h=z3(),p=BI(),g=Rg(),v=(function(m){t(b,m);function b(S,_,C,P,x,E){var A=m.call(this)||this;return A.overviewXAxisProperty=x,A.overviewYAxisProperty=E,A.rangeSelectionModifierProperty=P,A.parentSciChartSurfaceProperty=S,A.overviewSciChartSurfaceProperty=_,A.overviewWasmContext=C,A}return b.create=function(S,_,C){return i(this,void 0,void 0,function(){var P,x,E,A,R,M;return n(this,function(D){switch(D.label){case 0:return[4,y(S,_,C)];case 1:return P=D.sent(),x=P.sciChartSurface,E=P.wasmContext,A=P.rangeSelectionModifier,R=P.xAxis,M=P.yAxis,[2,new b(S,x,E,A,R,M)]}})})},Object.defineProperty(b.prototype,"overviewSciChartSurface",{get:function(){return this.overviewSciChartSurfaceProperty},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"parentSciChartSurface",{get:function(){return this.parentSciChartSurfaceProperty},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"rangeSelectionModifier",{get:function(){return this.rangeSelectionModifierProperty},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"overviewXAxis",{get:function(){return this.overviewXAxisProperty},enumerable:!1,configurable:!0}),Object.defineProperty(b.prototype,"overviewYAxis",{get:function(){return this.overviewYAxisProperty},enumerable:!1,configurable:!0}),b.prototype.applyTheme=function(S){this.overviewSciChartSurface.applyTheme(S)},b.prototype.delete=function(){this.overviewSciChartSurface&&!this.overviewSciChartSurface.isDeleted&&this.overviewSciChartSurface.delete(),this.overviewWasmContext=void 0},b})(o.DeletableEntity);pp.SciChartOverview=v;var y=function(m,b,S){return i(void 0,void 0,void 0,function(){var _,C,P,x,E,A,R,M,D,F,I,V,z,G,H,U,k,X,W,Y,te;return n(this,function(oe){switch(oe.label){case 0:return[4,g.SciChartSurface.create(b,S)];case 1:if(_=oe.sent(),C=_.wasmContext,P=_.sciChartSurface,x=S==null?void 0:S.mainAxisId,E=S==null?void 0:S.secondaryAxisId,A=(W=m.getXAxisById(x))!==null&&W!==void 0?W:m.getDefaultXAxis(),R=(Y=m.getYAxisById(E))!==null&&Y!==void 0?Y:m.getDefaultYAxis(),!A)throw new Error("Could not find a main axis with id ".concat(x,".")+(S!=null&&S.mainAxisId?"":"Please specify mainAxisId in the options"));if(!A)throw new Error("Could not find a secondary axis with id ".concat(E,".")+(S!=null&&S.secondaryAxisId?"":"Please specify secondaryAxisId in the options"));return M=A.isXAxis?A:R,D=A.isXAxis?R:A,F=e({axisAlignment:M.axisAlignment,isVisible:!1,autoRange:s.EAutoRange.Always,visibleRange:M.visibleRange},S==null?void 0:S.overviewXAxisOptions),I=e({axisAlignment:D.axisAlignment,isVisible:!1,autoRange:s.EAutoRange.Always,visibleRange:D.visibleRange},S==null?void 0:S.overviewYAxisOptions),V=M.isCategoryAxis?new d.CategoryAxis(C,F):M.type===l.EAxisType.BaseValueAxis?new c.BaseValueAxis(C,F):M.type===l.EAxisType.DiscontinuousDateAxis?new f.DiscontinuousDateAxis(C,F):M.type===l.EAxisType.LogarithmicAxis?new h.LogarithmicAxis(C,F):new p.NumericAxis(C,F),z=D.isCategoryAxis?new d.CategoryAxis(C,I):D.type===l.EAxisType.BaseValueAxis?new c.BaseValueAxis(C,I):D.type===l.EAxisType.DiscontinuousDateAxis?new f.DiscontinuousDateAxis(C,I):D.type===l.EAxisType.LogarithmicAxis?new h.LogarithmicAxis(C,I):new p.NumericAxis(C,I),G=A.isXAxis?V:z,H=function(de){var ge,Ee;if(!(((ge=de.xAxis)===null||ge===void 0?void 0:ge.id)!==M.id||((Ee=de.yAxis)===null||Ee===void 0?void 0:Ee.id)!==D.id)){var Re=(0,r.buildSeries)(C,de.toJSON(!0))[0];return Re.dataSeries.delete(),Re.dataSeries=de.dataSeries,Re.xAxisId=V.id,Re.yAxisId=z.id,Re}},S!=null&&S.transformRenderableSeries&&(H=function(de){return S==null?void 0:S.transformRenderableSeries(de,P)}),P.xAxes.add(V),P.yAxes.add(z),U=m.renderableSeries.asArray().map(H).filter(function(de){return de}),(X=P.renderableSeries).add.apply(X,U),P.zoomExtents(),k=(te=S==null?void 0:S.customRangeSelectionModifier)!==null&&te!==void 0?te:new u.OverviewRangeSelectionModifier,k.xAxisId=V.id,k.yAxisId=z.id,k.onSelectedAreaChanged=function(de){de.equals(A.visibleRange)||A.setVisibleRangeWithLimits(de)},k.selectedArea=new a.NumberRange(Math.max(V.visibleRange.min,A.visibleRange.min),Math.min(V.visibleRange.max,A.visibleRange.max)),P.chartModifiers.add(k),(S==null?void 0:S.rangeSelectionAnnotationSvgString)!==void 0&&(k.rangeSelectionAnnotation.svgString=S.rangeSelectionAnnotationSvgString),V.visibleRangeChanged.subscribe(function(de){var ge=de.visibleRange,Ee=A.visibleRange.clip(ge);k.selectedArea=Ee}),A.visibleRangeChanged.subscribe(function(de){var ge=de.visibleRange,Ee=ge.clip(G.visibleRange),Re=!Ee.equals(k.selectedArea);Re&&(k.selectedArea=Ee)}),P.layoutMeasured.subscribe(function(){k.selectedArea=new a.NumberRange(Math.max(V.visibleRange.min,A.visibleRange.min),Math.min(V.visibleRange.max,A.visibleRange.max))}),[2,{sciChartSurface:P,xAxis:V,yAxis:z,rangeSelectionModifier:k,wasmContext:C}]}})})};return pp}var _O={},CTe;function EAt(){if(CTe)return _O;CTe=1;var t=_O&&_O.__extends||(function(){var r=function(o,a){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,l){s.__proto__=l}||function(s,l){for(var u in l)Object.prototype.hasOwnProperty.call(l,u)&&(s[u]=l[u])},r(o,a)};return function(o,a){if(typeof a!="function"&&a!==null)throw new TypeError("Class extends value "+String(a)+" is not a constructor or null");r(o,a);function s(){this.constructor=o}o.prototype=a===null?Object.create(a):(s.prototype=a.prototype,new s)}})();Object.defineProperty(_O,"__esModule",{value:!0}),_O.CustomChartModifier3D=void 0;var e=Ho(),i=dR(),n=(function(r){t(o,r);function o(a){var s=r.call(this,a)||this;return s.type=e.EChart3DModifierType.Custom,s}return o})(i.ChartModifierBase3D);return _O.CustomChartModifier3D=n,_O}var S7={},TTe;function wAt(){return TTe||(TTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.EAxisSideClipping=void 0,(function(e){e.Default="Default",e.None="None",e.VisibleRange="VisibleRange"})(t.EAxisSideClipping||(t.EAxisSideClipping={}))})(S7)),S7}var _7={},xTe;function AAt(){return xTe||(xTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ETextAlignment3D=void 0,(function(e){e.Default="Default",e.Camera="Camera",e.ScreenHorizontal="ScreenHorizontal",e.ScreenAutoRotated="ScreenAutoRotated"})(t.ETextAlignment3D||(t.ETextAlignment3D={}))})(_7)),_7}var jB={},ETe;function OAt(){if(ETe)return jB;ETe=1,Object.defineProperty(jB,"__esModule",{value:!0}),jB.GradientParams=void 0;var t=(function(){function e(i,n,r){if(this.gradientStops=[],r.length<2)throw Error("At least two gradient point should be provided");if(i.x<0||i.y<0||i.x>1||i.y>1)throw Error("startPoint values should be within [0,1]");if(n.x<0||n.y<0||n.x>1||n.y>1)throw Error("endPoint values should be within [0,1]");r.forEach(function(o){if(o.offset<0||o.offset>1)throw Error("gradientStops offset should be within [0,1]")}),this.startPoint=i,this.endPoint=n,this.gradientStops=r}return e})();return jB.GradientParams=t,jB}var VB={},wTe;function DAt(){if(wTe)return VB;wTe=1,Object.defineProperty(VB,"__esModule",{value:!0}),VB.List=void 0;var t=(function(){function e(){this.items=[]}return e.prototype.size=function(){return this.items.length},e.prototype.add=function(i){this.items.push(i)},e.prototype.get=function(i){return this.items[i]},e})();return VB.List=t,VB}var P7={},ATe;function RAt(){return ATe||(ATe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ERenderLayer=void 0,(function(e){e[e.First=0]="First",e[e.Second=1]="Second",e[e.Third=2]="Third"})(t.ERenderLayer||(t.ERenderLayer={}))})(P7)),P7}var PO={},OTe;function DTe(){if(OTe)return PO;OTe=1,Object.defineProperty(PO,"__esModule",{value:!0}),PO.calcAverageForArray=PO.calcAverageForDoubleVector=void 0;var t=function(i,n,r){var o=i.size(),a=r??o-1;if(a>=o||a<0)throw Error("index should be in range [0, length-1]");if(a+1<n)return NaN;for(var s=0,l=a+1-n;l<a+1;l++)s+=i.get(l);return s/=n,s};PO.calcAverageForDoubleVector=t;var e=function(i,n,r){var o=i.length,a=r??o-1;if(a>=o||a<0)throw Error("index should be in range [0, length-1]");if(a+1<n)return NaN;for(var s=0,l=a+1-n;l<a+1;l++)s+=i[l];return s/=n,s};return PO.calcAverageForArray=e,PO}var CO={},RTe;function MTe(){if(RTe)return CO;RTe=1,Object.defineProperty(CO,"__esModule",{value:!0}),CO.convertRgbToHexColor=CO.convertColor=void 0;var t=function(n,r){r===void 0&&(r=1);var o=i(r),a=n.toLowerCase();return a.length===0?"":a[0]==="#"?"0x".concat(o).concat(a.substr(1)):"0x".concat(o).concat(a)};CO.convertColor=t;var e=function(n,r,o){return"#"+i(n)+i(r)+i(o)};CO.convertRgbToHexColor=e;var i=function(n){if(n>=1)return"ff";if(n<=0)return"00";var r=Math.floor(n*256),o=r.toString(16);return o.length===1?"0"+o:o};return CO}var HB={},LTe;function MAt(){if(LTe)return HB;LTe=1,Object.defineProperty(HB,"__esModule",{value:!0}),HB.convertToPixel=void 0;var t=function(i,n,r,o){var a="0x"+e(o)+e(i)+e(n)+e(r);return parseInt(a,16)};HB.convertToPixel=t;var e=function(i){return i>=255?"ff":i<=0?"00":i.toString(16)};return HB}var UB={},kTe;function LAt(){if(kTe)return UB;kTe=1,Object.defineProperty(UB,"__esModule",{value:!0}),UB.logDoubleVector=void 0;var t=function(e,i,n,r){n===void 0&&(n=2);for(var o="",a=0;a<(r??e.size());a++)o+=e.get(a).toFixed(n)+",";i?console.log(i,o):console.log(o)};return UB.logDoubleVector=t,UB}var zB={},ITe;function kAt(){if(ITe)return zB;ITe=1,Object.defineProperty(zB,"__esModule",{value:!0}),zB.hasAllProperties=void 0;var t=function(e,i){for(var n=0;n<i.length;n++)if(!e.hasOwnProperty(i[n]))return!1;return!0};return zB.hasAllProperties=t,zB}var TO={},NTe;function FTe(){if(NTe)return TO;NTe=1,Object.defineProperty(TO,"__esModule",{value:!0}),TO.createImagesArrayAsync=TO.createImageAsync=void 0;function t(i){return new Promise(function(n,r){var o=new Image;o.crossOrigin="Anonymous",o.onload=function(){return n(o)},o.onerror=r,o.src=i})}TO.createImageAsync=t;function e(i){var n=i.map(function(r){return t(r)});return Promise.all(n)}return TO.createImagesArrayAsync=e,TO}var $B={},BTe;function IVe(){if(BTe)return $B;BTe=1,Object.defineProperty($B,"__esModule",{value:!0}),$B.getRandomInRange=void 0;var t=function(e,i,n){var r=Math.random(),o=e+r*(i-e);return parseInt((o*Math.pow(10,n)).toFixed(n),10)/Math.pow(10,n)};return $B.getRandomInRange=t,$B}var xO={},jTe;function VTe(){if(jTe)return xO;jTe=1,Object.defineProperty(xO,"__esModule",{value:!0}),xO.getNextRandomPriceBarFactory=xO.getStocksDataFactory=void 0;var t=IVe(),e=function(o,a,s){return function(l,u){var c=.7,d=l+o,f=u,h=(0,t.getRandomInRange)(a,s,3),p=Math.abs(f-h),g=Math.max(f,h),v=(0,t.getRandomInRange)(g,Math.min(s,g+p*c),3),y=Math.min(f,h),m=(0,t.getRandomInRange)(Math.max(a,y-p*c),y,3);return{xValue:d,openValue:f,highValue:v,lowValue:m,closeValue:h}}};xO.getStocksDataFactory=e;var i=(function(){function o(a,s,l,u,c,d){this.xValue=a,this.openValue=s,this.highValue=l,this.lowValue=u,this.closeValue=c,this.volume=d}return o})(),n=function(o,a,s,l){var u=o,c=new i(o,l,l,l,l,0);return function(d){d===void 0&&(d=!1);var f=function(){var p=c.closeValue,g=(Math.random()-.9)*l/30,v=Math.random(),y=.5*l+l/2*Math.sin(727220521664304e-20*u)+l/16*Math.cos(727220521664304e-19*u)+l/32*Math.sin(727220521664304e-19*(10+v)*u)+l/64*Math.cos(727220521664304e-19*(20+v)*u)+g,m=Math.max(p,y),b=Math.random()*l/100,S=m+b,_=Math.min(p,y),C=Math.random()*l/100,P=_-C,x=Math.random()*3e4+2e4,E=s?r(c.xValue):c.xValue,A=E+a*60;return c=new i(A,p,S,P,y,x),u+=a*60,c},h=function(){var p=c.closeValue+(Math.random()-.48)*(c.closeValue/100),g=p>c.highValue?p:c.highValue,v=p<c.lowValue?p:c.lowValue,y=(Math.random()*3e4+2e4)*.05;return c=new i(c.xValue,c.openValue,g,v,p,c.volume+y),c};return d?h():f()}};xO.getNextRandomPriceBarFactory=n;var r=function(o){return o};return xO}var WB={},HTe;function IAt(){if(HTe)return WB;HTe=1,Object.defineProperty(WB,"__esModule",{value:!0}),WB.getAttributeFromString=void 0;var t=function(e,i){var n=e.indexOf(i);if(n>=0){var r=e.indexOf('"',n),o=r>=0?e.indexOf('"',r+1):-1;if(o>=0){var a=e.substr(r+1,o-r-1),s=parseInt(a,10);if(!isNaN(s))return s}}};return WB.getAttributeFromString=t,WB}var UTe;function qS(){return UTe||(UTe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.PolarArcZoomModifier=t.PointerEventsMediatorModifier=t.PinchZoomModifier=t.OverviewRangeSelectionModifier=t.MouseWheelZoomModifier=t.EActionType=t.ModifierMouseArgs=t.ModifierArgsBase=t.LegendModifier=t.DataPointSelectionModifier=t.ESelectionMode=t.DataPointSelectionChangedArgs=t.DataPointInfo=t.CustomChartModifier2D=t.adjustTooltipPosition=t.calcTooltipSize=t.defaultCursorTooltipSvgTemplate=t.CursorModifier=t.getActiveAxes=t.testIsOverAxes=t.ChartModifierBase2D=t.ChartModifierBase=t.AnnotationHoverModifier=t.getSubTypes=t.createType=t.getFunction=t.registerFunction=t.registerWasmType=t.registerType=t.chartBuilder=t.ensureRegistrations=t.configureChart=t.buildChart=t.chartReviver=t.configure3DSurface=t.configure2DSurface=t.buildSubCharts=t.build3DChart=t.buildPieChart=t.build2DPolarChart=t.build2DChart=t.buildSeries3D=t.buildSeries=t.buildModifiers3D=t.buildModifiers=t.buildDataSeries3D=t.buildDataSeries=t.buildAxis3D=t.buildAxes=t.buildAnnotations=void 0,t.CentralAxesLayoutManager=t.BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy=t.BottomAlignedOuterAxisLayoutStrategy=t.BottomAlignedInnerAxisLayoutStrategy=t.BaseCenteredAxisLayoutStrategy=t.BaseAxisLayoutStrategy=t.testLayoutManager=t.getCoordinateWithCoordinateMode=t.getValueWithCoordinateMode=t.updateTopAndBottomChartLayoutState=t.updateLeftAndRightChartLayoutState=t.getVerticalAxisRequiredSize=t.getHorizontalAxisRequiredSize=t.layoutAxisPartsBottomStrategy=t.layoutAxisPartsTopStrategy=t.layoutAxisPartsRightStrategy=t.layoutAxisPartsLeftStrategy=t.layoutAxisParts=t.updateAxisLayoutState=t.WebGlRenderContext2D=t.ELineDrawMode=t.calculateAbsoluteRenderLayer=t.WebGlPen=t.WebGlBrush=t.RenderContext2D=t.createPenInCache=t.getScrtPenFromCache=t.getWebGlPenFromCache=t.createBrushInCache=t.getScrtBrushFromCache=t.getWebGlBrushFromCache=t.BatchRenderContext=t.ZoomPanModifier=t.ZoomExtentsModifier=t.YAxisDragModifier=t.XAxisDragModifier=t.VerticalSliceModifier=t.SeriesSelectionModifier=t.getRubberBandRect=t.RubberBandXyZoomModifier=t.splitIntoClusters=t.RolloverModifier=t.PolarZoomExtentsModifier=t.PolarSeriesSelectionModifier=t.PolarPanModifier=t.EPolarPanModifierPanMode=t.PolarMouseWheelZoomModifier=t.PolarLegendModifier=t.PolarDataPointSelectionModifier=t.PolarCursorModifier=void 0,t.XyMovingAverageFilter=t.XyLinearTrendFilter=t.switchData=t.XyFilterBase=t.EDataSeriesField=t.XyCustomFilter=t.OhlcScaleOffsetFilter=t.OhlcFilterBase=t.OhlcCustomFilter=t.HlcScaleOffsetFilter=t.HlcFilterBase=t.HlcCustomFilter=t.FIFOVectorProvider=t.DoubleVectorProvider=t.DataPointSelectionPaletteProvider=t.DataDistributionCalculator=t.XyzSeriesInfo=t.XyySeriesInfo=t.XySeriesInfo=t.TriangleSeriesInfo=t.StackedXySeriesInfo=t.SeriesInfo=t.OhlcSeriesInfo=t.HlcSeriesInfo=t.HeatmapSeriesInfo=t.BoxPlotSeriesInfo=t.BoxPlotDataSeries=t.BasePaletteProvider=t.BaseHeatmapDataSeries=t.getWindowedYRange=t.BaseDataSeries=t.TopAlignedOuterHorizontallyStackedAxisLayoutStrategy=t.TopAlignedOuterAxisLayoutStrategy=t.TopAlignedInnerAxisLayoutStrategy=t.SynchronizedLayoutManager=t.SciChartVerticalGroup=t.SciChartHorizontalGroup=t.RightAlignedOuterVerticallyStackedAxisLayoutStrategy=t.RightAlignedOuterAxisLayoutStrategy=t.RightAlignedInnerAxisLayoutStrategy=t.RadialAxisLayoutStrategy=t.PolarLayoutManager=t.BasePolarAxisLayoutStrategy=t.AngularAxisLayoutStrategy=t.LeftAlignedOuterVerticallyStackedAxisLayoutStrategy=t.LeftAlignedOuterAxisLayoutStrategy=t.LeftAlignedInnerAxisLayoutStrategy=t.LayoutManager=t.EInnerAxisPlacementCoordinateMode=t.ChartLayoutState=void 0,t.IndexCoordinateCalculator=t.FlippedNumericCoordinateCalculator=t.FlippedIndexCoordinateCalculator=t.FlippedCategoryCoordinateCalculator=t.CoordinateCalculatorBase=t.CategoryCoordinateCalculator=t.XyzDataSeries=t.getYyYRange=t.XyyDataSeries=t.XyxyDataSeries=t.XyxDataSeries=t.XyTextDataSeries=t.XyNDataSeries=t.XyDataSeries=t.XDataSeries=t.UniformHeatmapDataSeries=t.XyzPointSeriesWrapped=t.XyzPointSeriesResampled=t.XyyPointSeriesWrapped=t.XyyPointSeriesResampled=t.XyPointSeriesWrapped=t.XyPointSeriesResampled=t.XyNPointSeriesResampled=t.OhlcPointSeriesWrapped=t.OhlcPointSeriesResampled=t.HlcPointSeriesWrapped=t.BoxPlotPointSeriesWrapped=t.BasePointSeriesWrapped=t.BasePointSeriesResampled=t.PaletteFactory=t.getOHLCYRange=t.OhlcDataSeries=t.NonUniformHeatmapDataSeries=t.MetadataPaletteProvider=t.TemplateMetadataGenerator=t.DefaultPaletteProvider=t.EFillPaletteMode=t.EStrokePaletteMode=t.EDataSeriesValueType=t.EDataChangeType=t.EDataSeriesType=t.HlcDataSeries=t.XyzScaleOffsetFilter=t.XyzFilterBase=t.XyzCustomFilter=t.XyyScaleOffsetFilter=t.XyyFilterBase=t.XyyCustomFilter=t.XyScaleOffsetFilter=t.XyRatioFilter=void 0,t.LineAnnotation=t.EAnnotationType=t.EAnnotationLayer=t.HtmlTextAnnotation=t.HtmlCustomAnnotation=t.HorizontalLineAnnotation=t.DomAnnotationBase=t.CustomAnnotation=t.CursorTooltipSvgAnnotation=t.BoxAnnotation=t.AxisMarkerAnnotation=t.ArcAnnotationBase=t.ArcAnnotation=t.AnnotationHoverEventArgs=t.annotationHelpers=t.AnnotationDragDeltaEventArgs=t.AnnotationClickEventArgs=t.AnnotationBase=t.ECoordinateMode=t.EDraggingGripPoint=t.AdornerLayer=t.SciChartJsNavyTheme=t.SciChartJSLightTheme=t.SciChartJSDarkv2Theme=t.SciChartJSDarkTheme=t.stripAutoColor=t.ThemeProvider=t.AUTO_COLOR=t.getAdjustedRotation=t.TitleRendererBase=t.SciChartRenderer=t.RenderPassInfo=t.RenderPassDataCollection=t.RenderPassData=t.ChartTitleRenderer=t.TickProvider=t.NumericTickProvider=t.LogarithmicTickProvider=t.ELogarithmicMajorTickMode=t.ELogarithmicMinorTickMode=t.IndexTickProvider=t.TickCoordinatesProvider=t.StaticTickCoordinatesProvider=t.PolarTickCoordinatesProvider=t.DefaultTickCoordinatesProvider=t.ResamplingParams=t.EResamplingMode=t.ExtremeResamplerHelper=t.NumericCoordinateCalculator=t.LogarithmicCoordinateCalculator=void 0,t.TextLabelProvider=t.SmartDateLabelProvider=t.DEFAULT_LABEL_THRESHOLDS=t.EHighPrecisionLabelMode=t.EDatePrecision=t.ETradeChartLabelFormat=t.RadianLabelProvider=t.PieLabelProvider=t.NumericLabelProvider=t.LogarithmicLabelProvider=t.LabelProviderBase2D=t.LabelInfo=t.LabelProvider=t.labelCache=t.DateLabelProvider=t.getAxis3dById=t.getAxisById=t.DiscontinuousDateAxis=t.NumericDeltaCalculator=t.LogarithmicDeltaCalculator=t.IndexDeltaCalculator=t.DeltaCalculator=t.DateTimeDeltaCalculator=t.CategoryDeltaCalculator=t.DateTimeNumericAxis=t.CategoryAxisBase=t.CategoryAxis=t.BaseValueAxis=t.AxisTitleRenderer=t.AxisRenderer=t.PolarAxisLayoutState=t.AxisLayoutState=t.AxisCore=t.AxisBase2D=t.EClipMode=t.VerticalLineAnnotation=t.TextAnnotation=t.SvgLineAnnotation=t.SvgAnnotationBase=t.RolloverTooltipSvgAnnotation=t.RolloverMarkerSvgAnnotation=t.RolloverLegendSvgAnnotation=t.RenderContextAnnotationBase=t.PolarPointerAnnotation=t.PolarArcAnnotation=t.OverviewCustomResizableAnnotation=t.NativeTextAnnotation=t.EWrapTo=t.LineArrowAnnotation=t.EArrowHeadPosition=void 0,t.ELegendPlacement=t.ELegendOrientation=t.SciChartLegend=t.SciChart3DLegend=t.ManualLegend=t.polarChartHelper=t.getAllFontKeys=t.getFontKey=t.getVector3=t.getVector2=t.getVector4=t.getNativeRect=t.getTextBounds=t.getTextureVertex=t.getArcParams=t.getArcVertex=t.getVertex=t.getVectorArcVertex=t.getVectorColorTextureVertex=t.getVectorColorVertex=t.getVectorRectVertex=t.freeCache=t.deleteCache=t.FontKey=t.labelHelper=t.getLabelValue=t.getLineCoordinates=t.getLabelCoordinates=t.drawAxisMarkerAnnotation=t.drawLineAnnotation=t.drawModifiersAxisLabel=t.drawBorder=t.createSolidBrush=t.createSCRTPen=t.createNativeRect=t.HeatmapLegend=t.initializeChartEngine2D=t.getSharedWasmContext=t.VisibleRangeChangedArgs=t.EPolarLabelMode=t.EPolarGridlineMode=t.EPolarAxisMode=t.PolarNumericAxis=t.PolarCategoryAxis=t.PolarAxisRenderer=t.PolarAxisBase=t.NumericAxis=t.LogarithmicAxis=t.MIN_LOG_AXIS_VALUE=t.wrapText=void 0,t.BubbleSeriesDataLabelProvider=t.BaseDataLabelProvider=t.BandSeriesDataLabelProvider=t.BaseStackedRenderableSeries=t.BaseStackedMountainRenderableSeries=t.BaseStackedCollection=t.BaseRenderableSeries=t.BaseOhlcRenderableSeries=t.BaseMountainRenderableSeries=t.BaseLineRenderableSeries=t.ELineType=t.BaseHeatmapRenderableSeries=t.BaseBandRenderableSeries=t.WaveAnimation=t.SweepAnimation=t.SeriesAnimation=t.ScatterAnimation=t.ScaleAnimation=t.PointMarkerStyle=t.OhlcAnimationStyle=t.OhlcAnimation=t.MountainAnimationStyle=t.MountainAnimation=t.LineAnimation=t.FadeAnimation=t.CustomPointMarkerStyle=t.ColumnAnimationStyle=t.ColumnAnimation=t.CandlestickAnimationStyle=t.CandlestickAnimation=t.BubbleAnimation=t.BasePointMarkerStyle=t.BaseAnimationStyle=t.BandAnimationStyle=t.BandAnimation=t.animationHelpers=t.XPointMarker=t.TrianglePointMarker=t.SquarePointMarker=t.SpritePointMarker=t.EllipsePointMarker=t.CrossPointMarker=t.BasePointMarker=t.DefaultSciChartLoader=t.licenseManager2dState=t.SciChartPieLegend=t.getLegendContainerHtml=t.getLegendItemHtml=t.SciChartLegendBase=t.ELegendType=void 0,t.FastLineRenderableSeries=t.FastImpulseRenderableSeries=t.FastErrorBarsRenderableSeries=t.getXRange=t.FastColumnRenderableSeries=t.FastCandlestickRenderableSeries=t.FastBubbleRenderableSeries=t.FastBoxPlotRenderableSeries=t.FastBandRenderableSeries=t.UniformHeatmapDrawingProvider=t.UniformContoursDrawingProvider=t.TriangleSeriesDrawingProvider=t.StackedColumnSeriesDrawingProvider=t.StackedColumnRenderPassData=t.SmearSeriesDrawingProvider=t.RectangleSeriesDrawingProvider=t.PointMarkerDrawingProvider=t.OhlcSeriesDrawingProvider=t.EOhlcDrawingMode=t.NonUniformHeatmapDrawingProvider=t.MountainSeriesDrawingProvider=t.LineSeriesDrawingProvider=t.LineSegmentSeriesDrawingProvider=t.HeightSeriesDrawingProvider=t.calculateHeatmapTexture=t.calculateCellCoordinates=t.calculateOffsets=t.createColorMap=t.getColor=t.getColorDataForTexture=t.ErrorSeriesDrawingProvider=t.ColumnSeriesDrawingProvider=t.BubbleSeriesDrawingProvider=t.BoxPlotSeriesDrawingProvider=t.BaseSeriesDrawingProvider=t.BandSeriesDrawingProvider=t.TextDataLabelProvider=t.StackedColumnSeriesDataLabelProvider=t.StackedCollectionDataLabelProvider=t.RectangleSeriesDataLabelProvider=t.RectangleDataLabelState=t.NonUniformHeatMapDataLabelProvider=t.LineSeriesDataLabelProvider=t.HeatMapDataLabelProvider=t.DataLabelState=t.DataLabelProvider=t.dataLabelHelpers=t.ContoursDataLabelProvider=t.ColumnSeriesDataLabelProvider=t.EColumnDataLabelPosition=void 0,t.PolarColumnRenderableSeries=t.PolarBandRenderableSeries=t.PolarMountainSeriesHitTestProvider=t.PolarLineSeriesHitTestProvider=t.polarHitTestHelpers=t.PolarDataPointHitTestProvider=t.PolarTriangleSeriesDrawingProvider=t.PolarPointMarkerDrawingProvider=t.PolarLineSeriesDrawingProvider=t.PolarHeatmapDrawingProvider=t.PolarColumnSeriesDrawingProvider=t.PolarBandSeriesDrawingProvider=t.PolarTextDataLabelProvider=t.PolarHeatMapDataLabelProvider=t.PolarDataLabelState=t.PolarDataLabelProvider=t.PolarColumnSeriesDataLabelProvider=t.PolarColumnDataLabelState=t.NonUniformHeatmapRenderableSeries=t.HoveredChangedArgs=t.UniformHeatmapHitTestProvider=t.TriangleSeriesHitTestProvider=t.TextSeriesHitTestProvider=t.StackedMountainSeriesHitTestProvider=t.StackedColumnSeriesHitTestProvider=t.ScatterSeriesHitTestProvider=t.RectangleSeriesHitTestProvider=t.OhlcSeriesHitTestProvider=t.NonUniformHeatmapHitTestProvider=t.MountainSeriesHitTestProvider=t.LineSeriesHitTestProvider=t.LineSegmentSeriesHitTestProvider=t.ImpulseSeriesHitTestProvider=t.HitTestInfo=t.hitTestHelpersRectangleSeries=t.hitTestHelpers=t.ErrorSeriesHitTestProvider=t.ColumnSeriesHitTestProvider=t.BubbleSeriesHitTestProvider=t.BoxPlotSeriesHitTestProvider=t.BaseHitTestProvider=t.BandSeriesHitTestProvider=t.HeatmapColorMap=t.GlowEffect=t.FastTriangleRenderableSeries=t.FastTextRenderableSeries=t.FastRectangleRenderableSeries=t.FastOhlcRenderableSeries=t.FastMountainRenderableSeries=t.FastLineSegmentRenderableSeries=void 0,t.EPieType=t.ESizingMode=t.PieSegment=t.SciChartOverview=t.SciChartDefaults=t.RubberBandSvgRect=t.XyScatterRenderableSeries=t.UniformHeatmapRenderableSeries=t.UniformContoursRenderableSeries=t.EContourColorMapMode=t.StackedXyCollection=t.StackedMountainRenderableSeries=t.StackedMountainCollection=t.StackedColumnRenderableSeries=t.StackedColumnCollection=t.SplineMountainRenderableSeries=t.SplineLineRenderableSeries=t.SplineBandRenderableSeries=t.SmoothStackedMountainRenderableSeries=t.ShadowEffect=t.ShaderEffect=t.SeriesVisibleChangedArgs=t.SeriesSelectedArgs=t.SeriesHoveredArgs=t.SelectionChangedArgs=t.RolloverModifierRenderableSeriesProps=t.XyySplineRenderDataTransform=t.SplineRenderDataTransform=t.PolarInterpolateLineRenderDataTransform=t.PolarInterpolateBandRenderDataTransform=t.SmoothStackedRenderDataTransform=t.XyyBezierRenderDataTransform=t.BezierRenderDataTransform=t.bezierTransform=t.BaseRenderDataTransformJS=t.XyzBaseRenderDataTransform=t.OhlcBaseRenderDataTransform=t.XyyBaseRenderDataTransform=t.XyBaseRenderDataTransform=t.BaseRenderDataTransform=t.PolarXyScatterRenderableSeries=t.PolarUniformHeatmapRenderableSeries=t.PolarTriangleRenderableSeries=t.PolarTextRenderableSeries=t.PolarStackedMountainRenderableSeries=t.PolarStackedMountainCollection=t.PolarStackedColumnRenderableSeries=t.PolarStackedColumnCollection=t.PolarMountainRenderableSeries=t.PolarLineRenderableSeries=void 0,t.getSharedWasmContext3D=t.AxisPlane=t.EAxisPlaneType=t.NumericAxis3D=t.getArraysEqual=t.getTextStylesEqual=t.getTArgbEqual=t.getLineStylesEqual=t.getDescriptorsEqual=t.ETextAlignment3D=t.EAxisSideClipping=t.AxisCubeEntity=t.AxisBase3D=t.EWhichAxis=t.TooltipSvgAnnotation3D=t.Vector3=t.XyzDataSeries3D=t.UniformGridDataSeries3D=t.BaseGridDataSeries3D=t.BaseDataSeries3D=t.EDataSeriesType3D=t.adjustTooltipPosition3D=t.TooltipModifier3D=t.ResetCamera3DModifier=t.PinchZoomModifier3D=t.OrbitModifier3D=t.MouseWheelZoomModifier3D=t.LegendModifier3D=t.CustomChartModifier3D=t.ChartModifierBase3D=t.CameraController=t.ECameraProjectionMode=t.UpdateSuspender=t.measureTextWidth=t.measureTextHeight=t.TextureManager=t.DpiHelper=t.CanvasTexture=t.SciChartSurfaceCore=t.createChartDestination=t.SciChartSurfaceBase=t.DebugForDpi=t.SciChartSurface=t.sciChartConfig=t.sciChartSubSurfaceCommon=t.SciChartSubSurface=t.SciChartPolarSurface=t.SciChartPolarSubSurface=t.SciChartPieSurface=t.EPieValueMode=void 0,t.SciChart3DSurface=t.sciChartConfig3D=t.SciChart3DRenderer=t.RootSceneEntity=t.XyzSeriesInfo3D=t.SurfaceMeshSeriesInfo3D=t.SurfaceMeshRenderableSeries3D=t.EMeshResolution=t.EMeshPaletteMode=t.EDrawMeshAs=t.SolidColorBrushPalette=t.MeshColorPalette=t.GradientColorPalette=t.SeriesInfo3D=t.Series3DVisibleChangedArgs=t.ScatterRenderableSeries3D=t.PointLineRenderableSeries3D=t.HitTestInfo3D=t.ESeriesType3D=t.ColumnRenderableSeries3D=t.BaseRenderableSeries3D=t.SurfaceMeshSceneEntity=t.SurfaceMeshSceneEntityState=t.SceneDescriptor=t.ScatterPointsSceneEntity=t.RenderPassInfo3D=t.RenderableSeriesSceneEntityState=t.RenderableSeriesSceneEntity=t.PointLine3DSceneEntity=t.DefaultEntityIdProvider=t.CrosshairLinesSceneEntity=t.ColumnSceneEntity=t.BaseSceneEntity3D=t.AxisCubeDescriptor=t.TrianglePointMarker3D=t.EllipsePointMarker3D=t.QuadPointMarker=t.PixelPointMarker3D=t.CylinderPointMarker3D=t.PyramidPointMarker3D=t.CubePointMarker3D=t.SpherePointMarker3D=t.BaseTexturePointMarker3D=t.BasePointMarker3D=t.EMarkerType=t.BaseMeshPointMarker3D=t.GizmoEntity=t.DefaultViewportManager3D=t.createSingle3dInternal=t.initializeChartEngine3D=void 0,t.getIsHorizontal=t.EAxisAlignment=t.EAutoRange=t.EAutoColorMode=t.EAnnotationClippingMode=t.EAnimationType=t.EVerticalAnchorPoint=t.EHorizontalAnchorPoint=t.WebGlHelper=t.EWebGLSupport=t.Thickness=t.sendTelemetry=t.shouldSendTelemetry=t.getUserCookie=t.localStorageApi=t.SimdHelper=t.Rect=t.PropertyChangedEventArgs=t.Point=t.OneTimePerformanceWarning=t.ObservableArrayChangedArgs=t.EObservableArrayChangedAction=t.ObservableArray=t.ObservableArrayBase=t.NumberUtil=t.NumberRange=t.MouseManager=t.List=t.IncludedItems=t.Guard=t.GradientParams=t.receiveNextEvent=t.EventHandler=t.Dictionary=t.deleteSafe=t.DeletableEntity=t.checkBuildStamp=t.libraryVersion=t.AnimationToken=t.NumberRangeAnimator=t.GenericAnimation=t.autoReverseEasing=t.easing=t.DoubleAnimator=t.animateAny=t.SeriesAnimationFiniteStateMachine=t.AnimationFiniteStateMachine=t.EAnimationStateTransition=t.EAnimationState=t.ViewportManager3DBase=void 0,t.ELabelPlacement=t.ELabelAlignment=t.EHoverMode=t.EHeightSeriesMode=t.EColorPickMode=t.EUseWasmSimd=t.EErrorMode=t.EErrorDirection=t.EDragMode=t.EDefaultRenderLayer=t.EDataPointWidthMode=t.EDataLabelSkipMode=t.EDataLabelProviderType=t.EDataFilterType=t.ECursorStyle=t.convertCoordinateFromRelativeValue=t.convertCoordinateFromPixelValue=t.convertCoordinateFromDataValue=t.convertToRelativeCoordinate=t.convertToPixelCoordinate=t.convertToDataValue=t.convertCoordinateMode=t.convertFromAbsoluteCoordinate=t.convertAbsoluteCoordinateToRelativeValue=t.convertAbsoluteCoordinateToPixelValue=t.convertAbsoluteCoordinateToDataValue=t.convertToAbsoluteCoordinate=t.convertRelativeValueToAbsoluteCoordinate=t.convertPixelValueToAbsoluteCoordinate=t.convertDataValueToAbsoluteCoordinate=t.subtractCoord=t.addCoord=t.convertYColumnMode=t.EColumnYMode=t.convertColumnMode=t.EColumnMode=t.EColor=t.EChart3DModifierType=t.EChart2DModifierType=t.EModifierMouseArgKey=t.EExecuteOn=t.EBaseType=t.EAxisType=t.convertAxisPlaneVisibilityMode=t.EAxisPlaneVisibilityMode=t.convert3DPlaneModeForTitles=t.convert3DPlaneModeForLabels=t.EAxisPlaneDrawLabelsMode=t.handleInvalidAxisAlignment=t.getIsVertical=void 0,t.countUnique=t.getUniqueValues=t.EZoomState=t.EYRangeMode=t.EXyDirection=t.EWatermarkPosition=t.generateValueNamesForDataSeries=t.EValueName=t.ETriangleSeriesDrawMode=t.EColorMapMode=t.EThemeProviderType=t.convert3DTitleRotationMode=t.convert3DLabelOrientationMode=t.E3DTitleRotationMode=t.E3DLabelOrientationMode=t.ETitlePosition=t.ETextAlignment=t.convertMultiLineAlignment=t.EMultiLineAlignment=t.EVerticalTextPosition=t.EHorizontalTextPosition=t.ESurfaceType=t.ESubSurfacePositionCoordinateMode=t.ESubChartClippingMode=t.Size=t.EShaderEffectType=t.ESeriesType=t.convertSearchMode=t.ESearchMode=t.ESciChartSurfaceType=t.ESceneEntityType=t.ERenderLayer=t.EStrokeLineJoin=t.EPointMarkerType=t.EPointMarker3DType=t.EPaletteProviderType=t.OrderedRenderable=t.ENumericFormat=t.subArray=t.isNumberArray=t.isTypedArray=t.EMousePosition=t.EModifierType=t.ELayoutStrategyType=t.ELayoutManagerType=t.ELabelProviderType=t.ERadialAxisLabelPlacement=t.EAngularAxisLabelPlacement=t.EVerticalAlignment=t.EHorizontalAlignment=void 0,t.htmlToElement=t.validateColorStops=t.HEIGHT_SERIES_MAX_TEXTURE_SIZE=t.hashUtils=t.hasAllProperties=t.base64Id=t.generateGuid=t.geometryHelpers=t.getFontFamily=t.getDefaultFontName=t.getFontString=t.logDoubleVector=t.formatUnixDateToHumanStringSSns=t.formatUnixDateToHumanStringSSus=t.formatUnixDateToHumanStringYYYY=t.formatUnixDateToHumanStringDD=t.formatUnixDateToHumanStringMMM=t.formatUnixDateToHumanStringMMMDD=t.formatUnixDateToHumanStringHHMM=t.formatUnixDateToHumanStringSSms=t.formatUnixDateToHumanStringHHMMSS=t.formatUnixDateToHumanStringDDMM=t.formatUnixDateToHumanStringDDMMHHMM=t.formatUnixDateToHumanStringDDMMYY=t.formatUnixDateToHumanString=t.copyDoubleVector=t.convertToPixel=t.convertRgbToHexColor=t.convertColor=t.applyOpacityToHtmlColor=t.uintArgbColorIsTransparent=t.uintArgbColorOverrideOpacity=t.uintArgbColorMultiplyOpacity=t.uintArgbColorToAbgr=t.linearColorMapLerp=t.uintArgbColorLerp=t.uintArgbColorLerp24bit=t.appendDoubleVectorFromBuffer=t.appendDoubleVectorFromJsArray=t.memCopyFloat32=t.insertDoubleVectorFromJsArray=t.SIZEOF_FLOAT32=t.SIZEOF_NUMBER=t.calcAverageForArray=t.calcAverageForDoubleVector=t.appendRangeFifo=t.makeIncArray=t.isArraySorted=t.arrayRemove=t.areArraysEqual=void 0,t.getMultilineTextHeight=t.getTextHeightToBaseline=t.getFirstLineHeightToBaseline=t.getNativeTextSize=t.convertToNativeLineSpacing=t.wrapNativeText=t.getAttributeFromString=t.getNextRandomPriceBarFactory=t.getStocksDataFactory=t.getRandomInRange=t.testPointInTriangle=t.calcDistanceFromLineSegment=t.calcDotProduct=t.testIsInInterval=t.testIsInXBounds=t.calcAnnotationBordersForAxisMarker=t.testIsInBounds=t.calcDistance=t.calcCrossProduct=t.calcDistanceFromLine=t.runAfterFramePaint=t.PerformanceDebugHelper=t.EPerformanceDebugLevel=t.EPerformanceMarkType=t.parseTArgbToHtmlColor=t.parseArgbToHtmlColor=t.parseColorToTArgb=t.toHex=t.parseColorToUIntAbgr=t.parseColorToUIntArgb=t.parseColorToHexStringAbgr=t.parseColorToHexStringArgb=t.checkIsNaN=t.toEngineering=t.toScientific=t.toSuperScript=t.formatNumber=t.numericHashCode=t.formatNumber2Digits=t.MemoryUsageHelper=t.ObjectRegistry=t.memoize=t.logToBase=t.fillNoisySinewave=t.getNoisySinewave=t.Logger=t.isRealNumber=t.createImagesArrayAsync=t.createImageAsync=t.stringOccurrences=void 0,t.zeroArray2D=t.watermarkHelpers=t.vectorToArrayViewI32=t.vectorToArrayViewUi32=t.vectorToArrayViewF32=t.vectorToArrayViewF64=t.vectorToArray=t.fromTsrVector4=t.updateTsrVector4=t.translateDataValueRectToAbsolute=t.translateToNotScaledRect=t.translateToScaledRect=t.translateToNotScaled=t.translateToScaled=t.translateFromSeriesViewRectToCanvasY=t.translateFromSeriesViewRectToCanvasX=t.translateFromCanvasToSeriesViewRectY=t.translateFromCanvasToSeriesViewRectX=t.translateFromSeriesViewRectToCanvas=t.translateFromCanvasToSeriesViewRect=t.EShift=t.ECoord=t.ESize=t.getNativeTextPosition=void 0;var e=nne();Object.defineProperty(t,"buildAnnotations",{enumerable:!0,get:function(){return e.buildAnnotations}});var i=e$();Object.defineProperty(t,"buildAxes",{enumerable:!0,get:function(){return i.buildAxes}});var n=e$();Object.defineProperty(t,"buildAxis3D",{enumerable:!0,get:function(){return n.buildAxis3D}});var r=G3();Object.defineProperty(t,"buildDataSeries",{enumerable:!0,get:function(){return r.buildDataSeries}});var o=G3();Object.defineProperty(t,"buildDataSeries3D",{enumerable:!0,get:function(){return o.buildDataSeries3D}});var a=n$();Object.defineProperty(t,"buildModifiers",{enumerable:!0,get:function(){return a.buildModifiers}});var s=n$();Object.defineProperty(t,"buildModifiers3D",{enumerable:!0,get:function(){return s.buildModifiers3D}});var l=K3();Object.defineProperty(t,"buildSeries",{enumerable:!0,get:function(){return l.buildSeries}});var u=K3();Object.defineProperty(t,"buildSeries3D",{enumerable:!0,get:function(){return u.buildSeries3D}});var c=U_();Object.defineProperty(t,"build2DChart",{enumerable:!0,get:function(){return c.build2DChart}});var d=U_();Object.defineProperty(t,"build2DPolarChart",{enumerable:!0,get:function(){return d.build2DPolarChart}});var f=U_();Object.defineProperty(t,"buildPieChart",{enumerable:!0,get:function(){return f.buildPieChart}});var h=U_();Object.defineProperty(t,"build3DChart",{enumerable:!0,get:function(){return h.build3DChart}});var p=U_();Object.defineProperty(t,"buildSubCharts",{enumerable:!0,get:function(){return p.buildSubCharts}});var g=U_();Object.defineProperty(t,"configure2DSurface",{enumerable:!0,get:function(){return g.configure2DSurface}});var v=U_();Object.defineProperty(t,"configure3DSurface",{enumerable:!0,get:function(){return v.configure3DSurface}});var y=Tv();Object.defineProperty(t,"chartReviver",{enumerable:!0,get:function(){return y.chartReviver}});var m=Tv();Object.defineProperty(t,"buildChart",{enumerable:!0,get:function(){return m.buildChart}});var b=Tv();Object.defineProperty(t,"configureChart",{enumerable:!0,get:function(){return b.configureChart}});var S=Tv();Object.defineProperty(t,"ensureRegistrations",{enumerable:!0,get:function(){return S.ensureRegistrations}});var _=Tv();Object.defineProperty(t,"chartBuilder",{enumerable:!0,get:function(){return _.chartBuilder}});var C=mo();Object.defineProperty(t,"registerType",{enumerable:!0,get:function(){return C.registerType}});var P=mo();Object.defineProperty(t,"registerWasmType",{enumerable:!0,get:function(){return P.registerWasmType}});var x=mo();Object.defineProperty(t,"registerFunction",{enumerable:!0,get:function(){return x.registerFunction}});var E=mo();Object.defineProperty(t,"getFunction",{enumerable:!0,get:function(){return E.getFunction}});var A=mo();Object.defineProperty(t,"createType",{enumerable:!0,get:function(){return A.createType}});var R=mo();Object.defineProperty(t,"getSubTypes",{enumerable:!0,get:function(){return R.getSubTypes}});var M=aje();Object.defineProperty(t,"AnnotationHoverModifier",{enumerable:!0,get:function(){return M.AnnotationHoverModifier}});var D=Cie();Object.defineProperty(t,"ChartModifierBase",{enumerable:!0,get:function(){return D.ChartModifierBase}});var F=Qu();Object.defineProperty(t,"ChartModifierBase2D",{enumerable:!0,get:function(){return F.ChartModifierBase2D}});var I=Qu();Object.defineProperty(t,"testIsOverAxes",{enumerable:!0,get:function(){return I.testIsOverAxes}});var V=Qu();Object.defineProperty(t,"getActiveAxes",{enumerable:!0,get:function(){return V.getActiveAxes}});var z=YO();Object.defineProperty(t,"CursorModifier",{enumerable:!0,get:function(){return z.CursorModifier}});var G=YO();Object.defineProperty(t,"defaultCursorTooltipSvgTemplate",{enumerable:!0,get:function(){return G.defaultCursorTooltipSvgTemplate}});var H=YO();Object.defineProperty(t,"calcTooltipSize",{enumerable:!0,get:function(){return H.calcTooltipSize}});var U=YO();Object.defineProperty(t,"adjustTooltipPosition",{enumerable:!0,get:function(){return U.adjustTooltipPosition}});var k=nAt();Object.defineProperty(t,"CustomChartModifier2D",{enumerable:!0,get:function(){return k.CustomChartModifier2D}});var X=WBe();Object.defineProperty(t,"DataPointInfo",{enumerable:!0,get:function(){return X.DataPointInfo}});var W=GBe();Object.defineProperty(t,"DataPointSelectionChangedArgs",{enumerable:!0,get:function(){return W.DataPointSelectionChangedArgs}});var Y=t$();Object.defineProperty(t,"ESelectionMode",{enumerable:!0,get:function(){return Y.ESelectionMode}});var te=t$();Object.defineProperty(t,"DataPointSelectionModifier",{enumerable:!0,get:function(){return te.DataPointSelectionModifier}});var oe=Eie();Object.defineProperty(t,"LegendModifier",{enumerable:!0,get:function(){return oe.LegendModifier}});var de=rFe();Object.defineProperty(t,"ModifierArgsBase",{enumerable:!0,get:function(){return de.ModifierArgsBase}});var ge=iFe();Object.defineProperty(t,"ModifierMouseArgs",{enumerable:!0,get:function(){return ge.ModifierMouseArgs}});var Ee=r$();Object.defineProperty(t,"EActionType",{enumerable:!0,get:function(){return Ee.EActionType}});var Re=r$();Object.defineProperty(t,"MouseWheelZoomModifier",{enumerable:!0,get:function(){return Re.MouseWheelZoomModifier}});var Ae=wie();Object.defineProperty(t,"OverviewRangeSelectionModifier",{enumerable:!0,get:function(){return Ae.OverviewRangeSelectionModifier}});var Pe=BW();Object.defineProperty(t,"PinchZoomModifier",{enumerable:!0,get:function(){return Pe.PinchZoomModifier}});var we=oje();Object.defineProperty(t,"PointerEventsMediatorModifier",{enumerable:!0,get:function(){return we.PointerEventsMediatorModifier}});var Te=uje();Object.defineProperty(t,"PolarArcZoomModifier",{enumerable:!0,get:function(){return Te.PolarArcZoomModifier}});var ke=cje();Object.defineProperty(t,"PolarCursorModifier",{enumerable:!0,get:function(){return ke.PolarCursorModifier}});var $e=dje();Object.defineProperty(t,"PolarDataPointSelectionModifier",{enumerable:!0,get:function(){return $e.PolarDataPointSelectionModifier}});var Ne=hje();Object.defineProperty(t,"PolarLegendModifier",{enumerable:!0,get:function(){return Ne.PolarLegendModifier}});var ve=pje();Object.defineProperty(t,"PolarMouseWheelZoomModifier",{enumerable:!0,get:function(){return ve.PolarMouseWheelZoomModifier}});var pe=pJ();Object.defineProperty(t,"EPolarPanModifierPanMode",{enumerable:!0,get:function(){return pe.EPolarPanModifierPanMode}});var fe=pJ();Object.defineProperty(t,"PolarPanModifier",{enumerable:!0,get:function(){return fe.PolarPanModifier}});var me=fje();Object.defineProperty(t,"PolarSeriesSelectionModifier",{enumerable:!0,get:function(){return me.PolarSeriesSelectionModifier}});var Ce=gje();Object.defineProperty(t,"PolarZoomExtentsModifier",{enumerable:!0,get:function(){return Ce.PolarZoomExtentsModifier}});var Ue=i$();Object.defineProperty(t,"RolloverModifier",{enumerable:!0,get:function(){return Ue.RolloverModifier}});var Qe=i$();Object.defineProperty(t,"splitIntoClusters",{enumerable:!0,get:function(){return Qe.splitIntoClusters}});var it=Y3();Object.defineProperty(t,"RubberBandXyZoomModifier",{enumerable:!0,get:function(){return it.RubberBandXyZoomModifier}});var xt=Y3();Object.defineProperty(t,"getRubberBandRect",{enumerable:!0,get:function(){return xt.getRubberBandRect}});var wt=Aie();Object.defineProperty(t,"SeriesSelectionModifier",{enumerable:!0,get:function(){return wt.SeriesSelectionModifier}});var $t=JBe();Object.defineProperty(t,"VerticalSliceModifier",{enumerable:!0,get:function(){return $t.VerticalSliceModifier}});var Mt=tje();Object.defineProperty(t,"XAxisDragModifier",{enumerable:!0,get:function(){return Mt.XAxisDragModifier}});var rt=rje();Object.defineProperty(t,"YAxisDragModifier",{enumerable:!0,get:function(){return rt.YAxisDragModifier}});var qe=Rie();Object.defineProperty(t,"ZoomExtentsModifier",{enumerable:!0,get:function(){return qe.ZoomExtentsModifier}});var vt=ije();Object.defineProperty(t,"ZoomPanModifier",{enumerable:!0,get:function(){return vt.ZoomPanModifier}});var kt=dFe();Object.defineProperty(t,"BatchRenderContext",{enumerable:!0,get:function(){return kt.BatchRenderContext}});var Xe=tu();Object.defineProperty(t,"getWebGlBrushFromCache",{enumerable:!0,get:function(){return Xe.getWebGlBrushFromCache}});var _t=tu();Object.defineProperty(t,"getScrtBrushFromCache",{enumerable:!0,get:function(){return _t.getScrtBrushFromCache}});var Ht=tu();Object.defineProperty(t,"createBrushInCache",{enumerable:!0,get:function(){return Ht.createBrushInCache}});var Pt=Ls();Object.defineProperty(t,"getWebGlPenFromCache",{enumerable:!0,get:function(){return Pt.getWebGlPenFromCache}});var Jt=Ls();Object.defineProperty(t,"getScrtPenFromCache",{enumerable:!0,get:function(){return Jt.getScrtPenFromCache}});var zt=Ls();Object.defineProperty(t,"createPenInCache",{enumerable:!0,get:function(){return zt.createPenInCache}});var Bt=oAt();Object.defineProperty(t,"RenderContext2D",{enumerable:!0,get:function(){return Bt.RenderContext2D}});var Mr=NFe();Object.defineProperty(t,"WebGlBrush",{enumerable:!0,get:function(){return Mr.WebGlBrush}});var Be=uFe();Object.defineProperty(t,"WebGlPen",{enumerable:!0,get:function(){return Be.WebGlPen}});var We=Iu();Object.defineProperty(t,"calculateAbsoluteRenderLayer",{enumerable:!0,get:function(){return We.calculateAbsoluteRenderLayer}});var dt=Iu();Object.defineProperty(t,"ELineDrawMode",{enumerable:!0,get:function(){return dt.ELineDrawMode}});var Tt=Iu();Object.defineProperty(t,"WebGlRenderContext2D",{enumerable:!0,get:function(){return Tt.WebGlRenderContext2D}});var nr=fs();Object.defineProperty(t,"updateAxisLayoutState",{enumerable:!0,get:function(){return nr.updateAxisLayoutState}});var Ar=fs();Object.defineProperty(t,"layoutAxisParts",{enumerable:!0,get:function(){return Ar.layoutAxisParts}});var Qr=fs();Object.defineProperty(t,"layoutAxisPartsLeftStrategy",{enumerable:!0,get:function(){return Qr.layoutAxisPartsLeftStrategy}});var Si=fs();Object.defineProperty(t,"layoutAxisPartsRightStrategy",{enumerable:!0,get:function(){return Si.layoutAxisPartsRightStrategy}});var oi=fs();Object.defineProperty(t,"layoutAxisPartsTopStrategy",{enumerable:!0,get:function(){return oi.layoutAxisPartsTopStrategy}});var Yr=fs();Object.defineProperty(t,"layoutAxisPartsBottomStrategy",{enumerable:!0,get:function(){return Yr.layoutAxisPartsBottomStrategy}});var vi=fs();Object.defineProperty(t,"getHorizontalAxisRequiredSize",{enumerable:!0,get:function(){return vi.getHorizontalAxisRequiredSize}});var rr=fs();Object.defineProperty(t,"getVerticalAxisRequiredSize",{enumerable:!0,get:function(){return rr.getVerticalAxisRequiredSize}});var Ji=fs();Object.defineProperty(t,"updateLeftAndRightChartLayoutState",{enumerable:!0,get:function(){return Ji.updateLeftAndRightChartLayoutState}});var qn=fs();Object.defineProperty(t,"updateTopAndBottomChartLayoutState",{enumerable:!0,get:function(){return qn.updateTopAndBottomChartLayoutState}});var ri=fs();Object.defineProperty(t,"getValueWithCoordinateMode",{enumerable:!0,get:function(){return ri.getValueWithCoordinateMode}});var eo=fs();Object.defineProperty(t,"getCoordinateWithCoordinateMode",{enumerable:!0,get:function(){return eo.getCoordinateWithCoordinateMode}});var xn=fs();Object.defineProperty(t,"testLayoutManager",{enumerable:!0,get:function(){return xn.testLayoutManager}});var mt=eR();Object.defineProperty(t,"BaseAxisLayoutStrategy",{enumerable:!0,get:function(){return mt.BaseAxisLayoutStrategy}});var gr=YV();Object.defineProperty(t,"BaseCenteredAxisLayoutStrategy",{enumerable:!0,get:function(){return gr.BaseCenteredAxisLayoutStrategy}});var ce=pW();Object.defineProperty(t,"BottomAlignedInnerAxisLayoutStrategy",{enumerable:!0,get:function(){return ce.BottomAlignedInnerAxisLayoutStrategy}});var fr=gW();Object.defineProperty(t,"BottomAlignedOuterAxisLayoutStrategy",{enumerable:!0,get:function(){return fr.BottomAlignedOuterAxisLayoutStrategy}});var Yt=lVe();Object.defineProperty(t,"BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy",{enumerable:!0,get:function(){return Yt.BottomAlignedOuterHorizontallyStackedAxisLayoutStrategy}});var Lr=uVe();Object.defineProperty(t,"CentralAxesLayoutManager",{enumerable:!0,get:function(){return Lr.CentralAxesLayoutManager}});var Cr=pFe();Object.defineProperty(t,"ChartLayoutState",{enumerable:!0,get:function(){return Cr.ChartLayoutState}});var zr=hW();Object.defineProperty(t,"EInnerAxisPlacementCoordinateMode",{enumerable:!0,get:function(){return zr.EInnerAxisPlacementCoordinateMode}});var fi=JP();Object.defineProperty(t,"LayoutManager",{enumerable:!0,get:function(){return fi.LayoutManager}});var to=vW();Object.defineProperty(t,"LeftAlignedInnerAxisLayoutStrategy",{enumerable:!0,get:function(){return to.LeftAlignedInnerAxisLayoutStrategy}});var st=yW();Object.defineProperty(t,"LeftAlignedOuterAxisLayoutStrategy",{enumerable:!0,get:function(){return st.LeftAlignedOuterAxisLayoutStrategy}});var zo=cVe();Object.defineProperty(t,"LeftAlignedOuterVerticallyStackedAxisLayoutStrategy",{enumerable:!0,get:function(){return zo.LeftAlignedOuterVerticallyStackedAxisLayoutStrategy}});var hi=nBe();Object.defineProperty(t,"AngularAxisLayoutStrategy",{enumerable:!0,get:function(){return hi.AngularAxisLayoutStrategy}});var si=nie();Object.defineProperty(t,"BasePolarAxisLayoutStrategy",{enumerable:!0,get:function(){return si.BasePolarAxisLayoutStrategy}});var sr=oie();Object.defineProperty(t,"PolarLayoutManager",{enumerable:!0,get:function(){return sr.PolarLayoutManager}});var Ns=oBe();Object.defineProperty(t,"RadialAxisLayoutStrategy",{enumerable:!0,get:function(){return Ns.RadialAxisLayoutStrategy}});var ts=mW();Object.defineProperty(t,"RightAlignedInnerAxisLayoutStrategy",{enumerable:!0,get:function(){return ts.RightAlignedInnerAxisLayoutStrategy}});var Z=bW();Object.defineProperty(t,"RightAlignedOuterAxisLayoutStrategy",{enumerable:!0,get:function(){return Z.RightAlignedOuterAxisLayoutStrategy}});var re=dVe();Object.defineProperty(t,"RightAlignedOuterVerticallyStackedAxisLayoutStrategy",{enumerable:!0,get:function(){return re.RightAlignedOuterVerticallyStackedAxisLayoutStrategy}});var ye=aAt();Object.defineProperty(t,"SciChartHorizontalGroup",{enumerable:!0,get:function(){return ye.SciChartHorizontalGroup}});var Ye=sAt();Object.defineProperty(t,"SciChartVerticalGroup",{enumerable:!0,get:function(){return Ye.SciChartVerticalGroup}});var gt=one();Object.defineProperty(t,"SynchronizedLayoutManager",{enumerable:!0,get:function(){return gt.SynchronizedLayoutManager}});var Dt=SW();Object.defineProperty(t,"TopAlignedInnerAxisLayoutStrategy",{enumerable:!0,get:function(){return Dt.TopAlignedInnerAxisLayoutStrategy}});var pr=_W();Object.defineProperty(t,"TopAlignedOuterAxisLayoutStrategy",{enumerable:!0,get:function(){return pr.TopAlignedOuterAxisLayoutStrategy}});var Gr=fVe();Object.defineProperty(t,"TopAlignedOuterHorizontallyStackedAxisLayoutStrategy",{enumerable:!0,get:function(){return Gr.TopAlignedOuterHorizontallyStackedAxisLayoutStrategy}});var rn=Bu();Object.defineProperty(t,"BaseDataSeries",{enumerable:!0,get:function(){return rn.BaseDataSeries}});var ro=Bu();Object.defineProperty(t,"getWindowedYRange",{enumerable:!0,get:function(){return ro.getWindowedYRange}});var na=mie();Object.defineProperty(t,"BaseHeatmapDataSeries",{enumerable:!0,get:function(){return na.BaseHeatmapDataSeries}});var yl=lAt();Object.defineProperty(t,"BasePaletteProvider",{enumerable:!0,get:function(){return yl.BasePaletteProvider}});var Ga=pBe();Object.defineProperty(t,"BoxPlotDataSeries",{enumerable:!0,get:function(){return Ga.BoxPlotDataSeries}});var ys=vFe();Object.defineProperty(t,"BoxPlotSeriesInfo",{enumerable:!0,get:function(){return ys.BoxPlotSeriesInfo}});var tc=yFe();Object.defineProperty(t,"HeatmapSeriesInfo",{enumerable:!0,get:function(){return tc.HeatmapSeriesInfo}});var rs=mFe();Object.defineProperty(t,"HlcSeriesInfo",{enumerable:!0,get:function(){return rs.HlcSeriesInfo}});var rc=bFe();Object.defineProperty(t,"OhlcSeriesInfo",{enumerable:!0,get:function(){return rc.OhlcSeriesInfo}});var Hl=Am();Object.defineProperty(t,"SeriesInfo",{enumerable:!0,get:function(){return Hl.SeriesInfo}});var fu=u3e();Object.defineProperty(t,"StackedXySeriesInfo",{enumerable:!0,get:function(){return fu.StackedXySeriesInfo}});var hu=B3e();Object.defineProperty(t,"TriangleSeriesInfo",{enumerable:!0,get:function(){return hu.TriangleSeriesInfo}});var ic=SFe();Object.defineProperty(t,"XySeriesInfo",{enumerable:!0,get:function(){return ic.XySeriesInfo}});var rl=_Fe();Object.defineProperty(t,"XyySeriesInfo",{enumerable:!0,get:function(){return rl.XyySeriesInfo}});var oa=PFe();Object.defineProperty(t,"XyzSeriesInfo",{enumerable:!0,get:function(){return oa.XyzSeriesInfo}});var Wd=gFe();Object.defineProperty(t,"DataDistributionCalculator",{enumerable:!0,get:function(){return Wd.DataDistributionCalculator}});var Ya=Tje();Object.defineProperty(t,"DataPointSelectionPaletteProvider",{enumerable:!0,get:function(){return Ya.DataPointSelectionPaletteProvider}});var cd=cJ();Object.defineProperty(t,"DoubleVectorProvider",{enumerable:!0,get:function(){return cd.DoubleVectorProvider}});var ml=cJ();Object.defineProperty(t,"FIFOVectorProvider",{enumerable:!0,get:function(){return ml.FIFOVectorProvider}});var Fs=vBe();Object.defineProperty(t,"HlcCustomFilter",{enumerable:!0,get:function(){return Fs.HlcCustomFilter}});var Ul=gBe();Object.defineProperty(t,"HlcFilterBase",{enumerable:!0,get:function(){return Ul.HlcFilterBase}});var wo=yBe();Object.defineProperty(t,"HlcScaleOffsetFilter",{enumerable:!0,get:function(){return wo.HlcScaleOffsetFilter}});var Ta=bBe();Object.defineProperty(t,"OhlcCustomFilter",{enumerable:!0,get:function(){return Ta.OhlcCustomFilter}});var Lo=mBe();Object.defineProperty(t,"OhlcFilterBase",{enumerable:!0,get:function(){return Lo.OhlcFilterBase}});var ao=SBe();Object.defineProperty(t,"OhlcScaleOffsetFilter",{enumerable:!0,get:function(){return ao.OhlcScaleOffsetFilter}});var bl=TBe();Object.defineProperty(t,"XyCustomFilter",{enumerable:!0,get:function(){return bl.XyCustomFilter}});var nc=sm();Object.defineProperty(t,"EDataSeriesField",{enumerable:!0,get:function(){return nc.EDataSeriesField}});var Vu=sm();Object.defineProperty(t,"XyFilterBase",{enumerable:!0,get:function(){return Vu.XyFilterBase}});var dd=sm();Object.defineProperty(t,"switchData",{enumerable:!0,get:function(){return dd.switchData}});var xa=_Be();Object.defineProperty(t,"XyLinearTrendFilter",{enumerable:!0,get:function(){return xa.XyLinearTrendFilter}});var Fa=PBe();Object.defineProperty(t,"XyMovingAverageFilter",{enumerable:!0,get:function(){return Fa.XyMovingAverageFilter}});var va=CBe();Object.defineProperty(t,"XyRatioFilter",{enumerable:!0,get:function(){return va.XyRatioFilter}});var Gd=xBe();Object.defineProperty(t,"XyScaleOffsetFilter",{enumerable:!0,get:function(){return Gd.XyScaleOffsetFilter}});var Oc=wBe();Object.defineProperty(t,"XyyCustomFilter",{enumerable:!0,get:function(){return Oc.XyyCustomFilter}});var il=EBe();Object.defineProperty(t,"XyyFilterBase",{enumerable:!0,get:function(){return il.XyyFilterBase}});var aa=ABe();Object.defineProperty(t,"XyyScaleOffsetFilter",{enumerable:!0,get:function(){return aa.XyyScaleOffsetFilter}});var Qi=DBe();Object.defineProperty(t,"XyzCustomFilter",{enumerable:!0,get:function(){return Qi.XyzCustomFilter}});var mn=OBe();Object.defineProperty(t,"XyzFilterBase",{enumerable:!0,get:function(){return mn.XyzFilterBase}});var oc=RBe();Object.defineProperty(t,"XyzScaleOffsetFilter",{enumerable:!0,get:function(){return oc.XyzScaleOffsetFilter}});var _e=gie();Object.defineProperty(t,"HlcDataSeries",{enumerable:!0,get:function(){return _e.HlcDataSeries}});var He=zi();Object.defineProperty(t,"EDataSeriesType",{enumerable:!0,get:function(){return He.EDataSeriesType}});var et=zi();Object.defineProperty(t,"EDataChangeType",{enumerable:!0,get:function(){return et.EDataChangeType}});var ht=zi();Object.defineProperty(t,"EDataSeriesValueType",{enumerable:!0,get:function(){return ht.EDataSeriesValueType}});var Ft=vS();Object.defineProperty(t,"EStrokePaletteMode",{enumerable:!0,get:function(){return Ft.EStrokePaletteMode}});var ur=vS();Object.defineProperty(t,"EFillPaletteMode",{enumerable:!0,get:function(){return ur.EFillPaletteMode}});var Lt=vS();Object.defineProperty(t,"DefaultPaletteProvider",{enumerable:!0,get:function(){return Lt.DefaultPaletteProvider}});var Kt=XV();Object.defineProperty(t,"TemplateMetadataGenerator",{enumerable:!0,get:function(){return Kt.TemplateMetadataGenerator}});var Zr=uAt();Object.defineProperty(t,"MetadataPaletteProvider",{enumerable:!0,get:function(){return Zr.MetadataPaletteProvider}});var ni=MBe();Object.defineProperty(t,"NonUniformHeatmapDataSeries",{enumerable:!0,get:function(){return ni.NonUniformHeatmapDataSeries}});var pi=$3();Object.defineProperty(t,"OhlcDataSeries",{enumerable:!0,get:function(){return pi.OhlcDataSeries}});var Oi=$3();Object.defineProperty(t,"getOHLCYRange",{enumerable:!0,get:function(){return Oi.getOHLCYRange}});var Bi=Cre();Object.defineProperty(t,"PaletteFactory",{enumerable:!0,get:function(){return Bi.PaletteFactory}});var ms=jI();Object.defineProperty(t,"BasePointSeriesResampled",{enumerable:!0,get:function(){return ms.BasePointSeriesResampled}});var Ba=wm();Object.defineProperty(t,"BasePointSeriesWrapped",{enumerable:!0,get:function(){return Ba.BasePointSeriesWrapped}});var Sl=L3e();Object.defineProperty(t,"BoxPlotPointSeriesWrapped",{enumerable:!0,get:function(){return Sl.BoxPlotPointSeriesWrapped}});var zl=Vje();Object.defineProperty(t,"HlcPointSeriesWrapped",{enumerable:!0,get:function(){return zl.HlcPointSeriesWrapped}});var Hu=jie();Object.defineProperty(t,"OhlcPointSeriesResampled",{enumerable:!0,get:function(){return Hu.OhlcPointSeriesResampled}});var fd=Ije();Object.defineProperty(t,"OhlcPointSeriesWrapped",{enumerable:!0,get:function(){return fd.OhlcPointSeriesWrapped}});var Bs=LBe();Object.defineProperty(t,"XyNPointSeriesResampled",{enumerable:!0,get:function(){return Bs.XyNPointSeriesResampled}});var jg=lR();Object.defineProperty(t,"XyPointSeriesResampled",{enumerable:!0,get:function(){return jg.XyPointSeriesResampled}});var js=DI();Object.defineProperty(t,"XyPointSeriesWrapped",{enumerable:!0,get:function(){return js.XyPointSeriesWrapped}});var qf=hR();Object.defineProperty(t,"XyyPointSeriesResampled",{enumerable:!0,get:function(){return qf.XyyPointSeriesResampled}});var hd=KV();Object.defineProperty(t,"XyyPointSeriesWrapped",{enumerable:!0,get:function(){return hd.XyyPointSeriesWrapped}});var is=n3e();Object.defineProperty(t,"XyzPointSeriesResampled",{enumerable:!0,get:function(){return is.XyzPointSeriesResampled}});var Xf=Rje();Object.defineProperty(t,"XyzPointSeriesWrapped",{enumerable:!0,get:function(){return Xf.XyzPointSeriesWrapped}});var Yd=bie();Object.defineProperty(t,"UniformHeatmapDataSeries",{enumerable:!0,get:function(){return Yd.UniformHeatmapDataSeries}});var ko=Sie();Object.defineProperty(t,"XDataSeries",{enumerable:!0,get:function(){return ko.XDataSeries}});var ac=vie();Object.defineProperty(t,"XyDataSeries",{enumerable:!0,get:function(){return ac.XyDataSeries}});var Nh=kBe();Object.defineProperty(t,"XyNDataSeries",{enumerable:!0,get:function(){return Nh.XyNDataSeries}});var pd=IBe();Object.defineProperty(t,"XyTextDataSeries",{enumerable:!0,get:function(){return pd.XyTextDataSeries}});var Fh=NBe();Object.defineProperty(t,"XyxDataSeries",{enumerable:!0,get:function(){return Fh.XyxDataSeries}});var Vg=FBe();Object.defineProperty(t,"XyxyDataSeries",{enumerable:!0,get:function(){return Vg.XyxyDataSeries}});var Hg=W3();Object.defineProperty(t,"XyyDataSeries",{enumerable:!0,get:function(){return Hg.XyyDataSeries}});var Kf=W3();Object.defineProperty(t,"getYyYRange",{enumerable:!0,get:function(){return Kf.getYyYRange}});var gd=yie();Object.defineProperty(t,"XyzDataSeries",{enumerable:!0,get:function(){return gd.XyzDataSeries}});var Zf=ZFe();Object.defineProperty(t,"CategoryCoordinateCalculator",{enumerable:!0,get:function(){return Zf.CategoryCoordinateCalculator}});var Di=iC();Object.defineProperty(t,"CoordinateCalculatorBase",{enumerable:!0,get:function(){return Di.CoordinateCalculatorBase}});var Ip=JFe();Object.defineProperty(t,"FlippedCategoryCoordinateCalculator",{enumerable:!0,get:function(){return Ip.FlippedCategoryCoordinateCalculator}});var qd=HBe();Object.defineProperty(t,"FlippedIndexCoordinateCalculator",{enumerable:!0,get:function(){return qd.FlippedIndexCoordinateCalculator}});var Xd=MW();Object.defineProperty(t,"FlippedNumericCoordinateCalculator",{enumerable:!0,get:function(){return Xd.FlippedNumericCoordinateCalculator}});var sc=UBe();Object.defineProperty(t,"IndexCoordinateCalculator",{enumerable:!0,get:function(){return sc.IndexCoordinateCalculator}});var Kd=lBe();Object.defineProperty(t,"LogarithmicCoordinateCalculator",{enumerable:!0,get:function(){return Kd.LogarithmicCoordinateCalculator}});var Jf=LW();Object.defineProperty(t,"NumericCoordinateCalculator",{enumerable:!0,get:function(){return Jf.NumericCoordinateCalculator}});var Bh=Dre();Object.defineProperty(t,"ExtremeResamplerHelper",{enumerable:!0,get:function(){return Bh.ExtremeResamplerHelper}});var Dc=Om();Object.defineProperty(t,"EResamplingMode",{enumerable:!0,get:function(){return Dc.EResamplingMode}});var Rc=Ore();Object.defineProperty(t,"ResamplingParams",{enumerable:!0,get:function(){return Rc.ResamplingParams}});var Np=Xre();Object.defineProperty(t,"DefaultTickCoordinatesProvider",{enumerable:!0,get:function(){return Np.DefaultTickCoordinatesProvider}});var Mc=cie();Object.defineProperty(t,"PolarTickCoordinatesProvider",{enumerable:!0,get:function(){return Mc.PolarTickCoordinatesProvider}});var nl=QFe();Object.defineProperty(t,"StaticTickCoordinatesProvider",{enumerable:!0,get:function(){return nl.StaticTickCoordinatesProvider}});var jh=qre();Object.defineProperty(t,"TickCoordinatesProvider",{enumerable:!0,get:function(){return jh.TickCoordinatesProvider}});var Zd=zBe();Object.defineProperty(t,"IndexTickProvider",{enumerable:!0,get:function(){return Zd.IndexTickProvider}});var Uu=r5();Object.defineProperty(t,"ELogarithmicMinorTickMode",{enumerable:!0,get:function(){return Uu.ELogarithmicMinorTickMode}});var Vh=r5();Object.defineProperty(t,"ELogarithmicMajorTickMode",{enumerable:!0,get:function(){return Vh.ELogarithmicMajorTickMode}});var Jd=r5();Object.defineProperty(t,"LogarithmicTickProvider",{enumerable:!0,get:function(){return Jd.LogarithmicTickProvider}});var pu=oR();Object.defineProperty(t,"NumericTickProvider",{enumerable:!0,get:function(){return pu.NumericTickProvider}});var io=wW();Object.defineProperty(t,"TickProvider",{enumerable:!0,get:function(){return io.TickProvider}});var gu=FFe();Object.defineProperty(t,"ChartTitleRenderer",{enumerable:!0,get:function(){return gu.ChartTitleRenderer}});var ns=QP();Object.defineProperty(t,"RenderPassData",{enumerable:!0,get:function(){return ns.RenderPassData}});var os=cAt();Object.defineProperty(t,"RenderPassDataCollection",{enumerable:!0,get:function(){return os.RenderPassDataCollection}});var Hh=AFe();Object.defineProperty(t,"RenderPassInfo",{enumerable:!0,get:function(){return Hh.RenderPassInfo}});var Qf=DFe();Object.defineProperty(t,"SciChartRenderer",{enumerable:!0,get:function(){return Qf.SciChartRenderer}});var eh=Zz();Object.defineProperty(t,"TitleRendererBase",{enumerable:!0,get:function(){return eh.TitleRendererBase}});var Uh=Zz();Object.defineProperty(t,"getAdjustedRotation",{enumerable:!0,get:function(){return Uh.getAdjustedRotation}});var zu=Xs();Object.defineProperty(t,"AUTO_COLOR",{enumerable:!0,get:function(){return zu.AUTO_COLOR}});var th=Xs();Object.defineProperty(t,"ThemeProvider",{enumerable:!0,get:function(){return th.ThemeProvider}});var Ug=Xs();Object.defineProperty(t,"stripAutoColor",{enumerable:!0,get:function(){return Ug.stripAutoColor}});var Qd=uW();Object.defineProperty(t,"SciChartJSDarkTheme",{enumerable:!0,get:function(){return Qd.SciChartJSDarkTheme}});var Fp=cW();Object.defineProperty(t,"SciChartJSDarkv2Theme",{enumerable:!0,get:function(){return Fp.SciChartJSDarkv2Theme}});var Lc=pVe();Object.defineProperty(t,"SciChartJSLightTheme",{enumerable:!0,get:function(){return Lc.SciChartJSLightTheme}});var Ke=hVe();Object.defineProperty(t,"SciChartJsNavyTheme",{enumerable:!0,get:function(){return Ke.SciChartJsNavyTheme}});var le=RFe();Object.defineProperty(t,"AdornerLayer",{enumerable:!0,get:function(){return le.AdornerLayer}});var Se=Ca();Object.defineProperty(t,"EDraggingGripPoint",{enumerable:!0,get:function(){return Se.EDraggingGripPoint}});var be=Ca();Object.defineProperty(t,"ECoordinateMode",{enumerable:!0,get:function(){return be.ECoordinateMode}});var xe=Ca();Object.defineProperty(t,"AnnotationBase",{enumerable:!0,get:function(){return xe.AnnotationBase}});var Le=BFe();Object.defineProperty(t,"AnnotationClickEventArgs",{enumerable:!0,get:function(){return Le.AnnotationClickEventArgs}});var je=jFe();Object.defineProperty(t,"AnnotationDragDeltaEventArgs",{enumerable:!0,get:function(){return je.AnnotationDragDeltaEventArgs}});var ct=gl();Object.defineProperty(t,"annotationHelpers",{enumerable:!0,get:function(){return ct.annotationHelpers}});var ze=VFe();Object.defineProperty(t,"AnnotationHoverEventArgs",{enumerable:!0,get:function(){return ze.AnnotationHoverEventArgs}});var at=HFe();Object.defineProperty(t,"ArcAnnotation",{enumerable:!0,get:function(){return at.ArcAnnotation}});var tt=$re();Object.defineProperty(t,"ArcAnnotationBase",{enumerable:!0,get:function(){return tt.ArcAnnotationBase}});var pt=UFe();Object.defineProperty(t,"AxisMarkerAnnotation",{enumerable:!0,get:function(){return pt.AxisMarkerAnnotation}});var Ut=zFe();Object.defineProperty(t,"BoxAnnotation",{enumerable:!0,get:function(){return Ut.BoxAnnotation}});var vr=Pie();Object.defineProperty(t,"CursorTooltipSvgAnnotation",{enumerable:!0,get:function(){return vr.CursorTooltipSvgAnnotation}});var Ir=Gre();Object.defineProperty(t,"CustomAnnotation",{enumerable:!0,get:function(){return Ir.CustomAnnotation}});var Nt=Wre();Object.defineProperty(t,"DomAnnotationBase",{enumerable:!0,get:function(){return Nt.DomAnnotationBase}});var hr=$Fe();Object.defineProperty(t,"HorizontalLineAnnotation",{enumerable:!0,get:function(){return hr.HorizontalLineAnnotation}});var Ao=Yre();Object.defineProperty(t,"HtmlCustomAnnotation",{enumerable:!0,get:function(){return Ao.HtmlCustomAnnotation}});var ho=WFe();Object.defineProperty(t,"HtmlTextAnnotation",{enumerable:!0,get:function(){return ho.HtmlTextAnnotation}});var $l=Qa();Object.defineProperty(t,"EAnnotationLayer",{enumerable:!0,get:function(){return $l.EAnnotationLayer}});var rh=Qa();Object.defineProperty(t,"EAnnotationType",{enumerable:!0,get:function(){return rh.EAnnotationType}});var kc=rC();Object.defineProperty(t,"LineAnnotation",{enumerable:!0,get:function(){return kc.LineAnnotation}});var ef=dJ();Object.defineProperty(t,"EArrowHeadPosition",{enumerable:!0,get:function(){return ef.EArrowHeadPosition}});var tf=dJ();Object.defineProperty(t,"LineArrowAnnotation",{enumerable:!0,get:function(){return tf.LineArrowAnnotation}});var Mn=Jz();Object.defineProperty(t,"EWrapTo",{enumerable:!0,get:function(){return Mn.EWrapTo}});var ya=Jz();Object.defineProperty(t,"NativeTextAnnotation",{enumerable:!0,get:function(){return ya.NativeTextAnnotation}});var Po=qBe();Object.defineProperty(t,"OverviewCustomResizableAnnotation",{enumerable:!0,get:function(){return Po.OverviewCustomResizableAnnotation}});var po=EW();Object.defineProperty(t,"PolarArcAnnotation",{enumerable:!0,get:function(){return po.PolarArcAnnotation}});var so=qFe();Object.defineProperty(t,"PolarPointerAnnotation",{enumerable:!0,get:function(){return so.PolarPointerAnnotation}});var _l=FI();Object.defineProperty(t,"RenderContextAnnotationBase",{enumerable:!0,get:function(){return _l.RenderContextAnnotationBase}});var as=XBe();Object.defineProperty(t,"RolloverLegendSvgAnnotation",{enumerable:!0,get:function(){return as.RolloverLegendSvgAnnotation}});var rf=KBe();Object.defineProperty(t,"RolloverMarkerSvgAnnotation",{enumerable:!0,get:function(){return rf.RolloverMarkerSvgAnnotation}});var Or=ZBe();Object.defineProperty(t,"RolloverTooltipSvgAnnotation",{enumerable:!0,get:function(){return Or.RolloverTooltipSvgAnnotation}});var nf=Dm();Object.defineProperty(t,"SvgAnnotationBase",{enumerable:!0,get:function(){return nf.SvgAnnotationBase}});var Bp=FW();Object.defineProperty(t,"SvgLineAnnotation",{enumerable:!0,get:function(){return Bp.SvgLineAnnotation}});var Rr=XFe();Object.defineProperty(t,"TextAnnotation",{enumerable:!0,get:function(){return Rr.TextAnnotation}});var zg=KFe();Object.defineProperty(t,"VerticalLineAnnotation",{enumerable:!0,get:function(){return zg.VerticalLineAnnotation}});var zh=Vv();Object.defineProperty(t,"EClipMode",{enumerable:!0,get:function(){return zh.EClipMode}});var Ic=Vv();Object.defineProperty(t,"AxisBase2D",{enumerable:!0,get:function(){return Ic.AxisBase2D}});var qv=Kre();Object.defineProperty(t,"AxisCore",{enumerable:!0,get:function(){return qv.AxisCore}});var bs=Qz();Object.defineProperty(t,"AxisLayoutState",{enumerable:!0,get:function(){return bs.AxisLayoutState}});var Nc=Qz();Object.defineProperty(t,"PolarAxisLayoutState",{enumerable:!0,get:function(){return Nc.PolarAxisLayoutState}});var Wl=Zre();Object.defineProperty(t,"AxisRenderer",{enumerable:!0,get:function(){return Wl.AxisRenderer}});var Tr=tBe();Object.defineProperty(t,"AxisTitleRenderer",{enumerable:!0,get:function(){return Tr.AxisTitleRenderer}});var Ln=NW();Object.defineProperty(t,"BaseValueAxis",{enumerable:!0,get:function(){return Ln.BaseValueAxis}});var vd=RW();Object.defineProperty(t,"CategoryAxis",{enumerable:!0,get:function(){return vd.CategoryAxis}});var _r=rBe();Object.defineProperty(t,"CategoryAxisBase",{enumerable:!0,get:function(){return _r.CategoryAxisBase}});var _n=iBe();Object.defineProperty(t,"DateTimeNumericAxis",{enumerable:!0,get:function(){return _n.DateTimeNumericAxis}});var $h=Jre();Object.defineProperty(t,"CategoryDeltaCalculator",{enumerable:!0,get:function(){return $h.CategoryDeltaCalculator}});var Xv=eie();Object.defineProperty(t,"DateTimeDeltaCalculator",{enumerable:!0,get:function(){return Xv.DateTimeDeltaCalculator}});var Pl=OW();Object.defineProperty(t,"DeltaCalculator",{enumerable:!0,get:function(){return Pl.DeltaCalculator}});var ih=$Be();Object.defineProperty(t,"IndexDeltaCalculator",{enumerable:!0,get:function(){return ih.IndexDeltaCalculator}});var nh=uBe();Object.defineProperty(t,"LogarithmicDeltaCalculator",{enumerable:!0,get:function(){return nh.LogarithmicDeltaCalculator}});var ma=aR();Object.defineProperty(t,"NumericDeltaCalculator",{enumerable:!0,get:function(){return ma.NumericDeltaCalculator}});var ja=_ie();Object.defineProperty(t,"DiscontinuousDateAxis",{enumerable:!0,get:function(){return ja.DiscontinuousDateAxis}});var Cl=ZCe();Object.defineProperty(t,"getAxisById",{enumerable:!0,get:function(){return Cl.getAxisById}});var vu=ZCe();Object.defineProperty(t,"getAxis3dById",{enumerable:!0,get:function(){return vu.getAxis3dById}});var Gl=DW();Object.defineProperty(t,"DateLabelProvider",{enumerable:!0,get:function(){return Gl.DateLabelProvider}});var yu=ZD();Object.defineProperty(t,"labelCache",{enumerable:!0,get:function(){return yu.labelCache}});var mu=Qre();Object.defineProperty(t,"LabelProvider",{enumerable:!0,get:function(){return mu.LabelProvider}});var Ss=tI();Object.defineProperty(t,"LabelInfo",{enumerable:!0,get:function(){return Ss.LabelInfo}});var jp=tI();Object.defineProperty(t,"LabelProviderBase2D",{enumerable:!0,get:function(){return jp.LabelProviderBase2D}});var yd=tie();Object.defineProperty(t,"LogarithmicLabelProvider",{enumerable:!0,get:function(){return yd.LogarithmicLabelProvider}});var of=Rm();Object.defineProperty(t,"NumericLabelProvider",{enumerable:!0,get:function(){return of.NumericLabelProvider}});var oh=IW();Object.defineProperty(t,"PieLabelProvider",{enumerable:!0,get:function(){return oh.PieLabelProvider}});var Va=dAt();Object.defineProperty(t,"RadianLabelProvider",{enumerable:!0,get:function(){return Va.RadianLabelProvider}});var lo=lS();Object.defineProperty(t,"ETradeChartLabelFormat",{enumerable:!0,get:function(){return lo.ETradeChartLabelFormat}});var kn=lS();Object.defineProperty(t,"EDatePrecision",{enumerable:!0,get:function(){return kn.EDatePrecision}});var md=lS();Object.defineProperty(t,"EHighPrecisionLabelMode",{enumerable:!0,get:function(){return md.EHighPrecisionLabelMode}});var bu=lS();Object.defineProperty(t,"DEFAULT_LABEL_THRESHOLDS",{enumerable:!0,get:function(){return bu.DEFAULT_LABEL_THRESHOLDS}});var $g=lS();Object.defineProperty(t,"SmartDateLabelProvider",{enumerable:!0,get:function(){return $g.SmartDateLabelProvider}});var bd=U3();Object.defineProperty(t,"TextLabelProvider",{enumerable:!0,get:function(){return bd.TextLabelProvider}});var Wh=U3();Object.defineProperty(t,"wrapText",{enumerable:!0,get:function(){return Wh.wrapText}});var ah=z3();Object.defineProperty(t,"MIN_LOG_AXIS_VALUE",{enumerable:!0,get:function(){return ah.MIN_LOG_AXIS_VALUE}});var af=z3();Object.defineProperty(t,"LogarithmicAxis",{enumerable:!0,get:function(){return af.LogarithmicAxis}});var nt=BI();Object.defineProperty(t,"NumericAxis",{enumerable:!0,get:function(){return nt.NumericAxis}});var Sd=fie();Object.defineProperty(t,"PolarAxisBase",{enumerable:!0,get:function(){return Sd.PolarAxisBase}});var _d=dBe();Object.defineProperty(t,"PolarAxisRenderer",{enumerable:!0,get:function(){return _d.PolarAxisRenderer}});var Tl=hBe();Object.defineProperty(t,"PolarCategoryAxis",{enumerable:!0,get:function(){return Tl.PolarCategoryAxis}});var nn=hie();Object.defineProperty(t,"PolarNumericAxis",{enumerable:!0,get:function(){return nn.PolarNumericAxis}});var Fc=die();Object.defineProperty(t,"EPolarAxisMode",{enumerable:!0,get:function(){return Fc.EPolarAxisMode}});var Pd=fBe();Object.defineProperty(t,"EPolarGridlineMode",{enumerable:!0,get:function(){return Pd.EPolarGridlineMode}});var Bc=NI();Object.defineProperty(t,"EPolarLabelMode",{enumerable:!0,get:function(){return Bc.EPolarLabelMode}});var jc=eBe();Object.defineProperty(t,"VisibleRangeChangedArgs",{enumerable:!0,get:function(){return jc.VisibleRangeChangedArgs}});var Wg=H3();Object.defineProperty(t,"getSharedWasmContext",{enumerable:!0,get:function(){return Wg.getSharedWasmContext}});var sh=H3();Object.defineProperty(t,"initializeChartEngine2D",{enumerable:!0,get:function(){return sh.initializeChartEngine2D}});var Vp=fAt();Object.defineProperty(t,"HeatmapLegend",{enumerable:!0,get:function(){return Vp.HeatmapLegend}});var sf=ZP();Object.defineProperty(t,"createNativeRect",{enumerable:!0,get:function(){return sf.createNativeRect}});var _s=JNe();Object.defineProperty(t,"createSCRTPen",{enumerable:!0,get:function(){return _s.createSCRTPen}});var Su=Hre();Object.defineProperty(t,"createSolidBrush",{enumerable:!0,get:function(){return Su.createSolidBrush}});var Kv=jre();Object.defineProperty(t,"drawBorder",{enumerable:!0,get:function(){return Kv.drawBorder}});var Fm=_v();Object.defineProperty(t,"drawModifiersAxisLabel",{enumerable:!0,get:function(){return Fm.drawModifiersAxisLabel}});var Bm=_v();Object.defineProperty(t,"drawLineAnnotation",{enumerable:!0,get:function(){return Bm.drawLineAnnotation}});var jm=_v();Object.defineProperty(t,"drawAxisMarkerAnnotation",{enumerable:!0,get:function(){return jm.drawAxisMarkerAnnotation}});var Ha=_v();Object.defineProperty(t,"getLabelCoordinates",{enumerable:!0,get:function(){return Ha.getLabelCoordinates}});var $u=_v();Object.defineProperty(t,"getLineCoordinates",{enumerable:!0,get:function(){return $u.getLineCoordinates}});var Gh=_v();Object.defineProperty(t,"getLabelValue",{enumerable:!0,get:function(){return Gh.getLabelValue}});var Yh=nR();Object.defineProperty(t,"labelHelper",{enumerable:!0,get:function(){return Yh.labelHelper}});var Gg=an();Object.defineProperty(t,"FontKey",{enumerable:!0,get:function(){return Gg.FontKey}});var lh=an();Object.defineProperty(t,"deleteCache",{enumerable:!0,get:function(){return lh.deleteCache}});var uh=an();Object.defineProperty(t,"freeCache",{enumerable:!0,get:function(){return uh.freeCache}});var lf=an();Object.defineProperty(t,"getVectorRectVertex",{enumerable:!0,get:function(){return lf.getVectorRectVertex}});var Zv=an();Object.defineProperty(t,"getVectorColorVertex",{enumerable:!0,get:function(){return Zv.getVectorColorVertex}});var Vm=an();Object.defineProperty(t,"getVectorColorTextureVertex",{enumerable:!0,get:function(){return Vm.getVectorColorTextureVertex}});var _u=an();Object.defineProperty(t,"getVectorArcVertex",{enumerable:!0,get:function(){return _u.getVectorArcVertex}});var uf=an();Object.defineProperty(t,"getVertex",{enumerable:!0,get:function(){return uf.getVertex}});var Yg=an();Object.defineProperty(t,"getArcVertex",{enumerable:!0,get:function(){return Yg.getArcVertex}});var Hp=an();Object.defineProperty(t,"getArcParams",{enumerable:!0,get:function(){return Hp.getArcParams}});var Jv=an();Object.defineProperty(t,"getTextureVertex",{enumerable:!0,get:function(){return Jv.getTextureVertex}});var ch=an();Object.defineProperty(t,"getTextBounds",{enumerable:!0,get:function(){return ch.getTextBounds}});var Up=an();Object.defineProperty(t,"getNativeRect",{enumerable:!0,get:function(){return Up.getNativeRect}});var qh=an();Object.defineProperty(t,"getVector4",{enumerable:!0,get:function(){return qh.getVector4}});var Xh=an();Object.defineProperty(t,"getVector2",{enumerable:!0,get:function(){return Xh.getVector2}});var Qv=an();Object.defineProperty(t,"getVector3",{enumerable:!0,get:function(){return Qv.getVector3}});var zp=an();Object.defineProperty(t,"getFontKey",{enumerable:!0,get:function(){return zp.getFontKey}});var Pu=an();Object.defineProperty(t,"getAllFontKeys",{enumerable:!0,get:function(){return Pu.getAllFontKeys}});var lc=cBe();Object.defineProperty(t,"polarChartHelper",{enumerable:!0,get:function(){return lc.polarChartHelper}});var ey=hAt();Object.defineProperty(t,"ManualLegend",{enumerable:!0,get:function(){return ey.ManualLegend}});var qg=Pje();Object.defineProperty(t,"SciChart3DLegend",{enumerable:!0,get:function(){return qg.SciChart3DLegend}});var Vc=YBe();Object.defineProperty(t,"SciChartLegend",{enumerable:!0,get:function(){return Vc.SciChartLegend}});var Yl=zy();Object.defineProperty(t,"ELegendOrientation",{enumerable:!0,get:function(){return Yl.ELegendOrientation}});var dh=zy();Object.defineProperty(t,"ELegendPlacement",{enumerable:!0,get:function(){return dh.ELegendPlacement}});var xl=zy();Object.defineProperty(t,"ELegendType",{enumerable:!0,get:function(){return xl.ELegendType}});var Vs=zy();Object.defineProperty(t,"SciChartLegendBase",{enumerable:!0,get:function(){return Vs.SciChartLegendBase}});var ty=zy();Object.defineProperty(t,"getLegendItemHtml",{enumerable:!0,get:function(){return ty.getLegendItemHtml}});var Cd=zy();Object.defineProperty(t,"getLegendContainerHtml",{enumerable:!0,get:function(){return Cd.getLegendContainerHtml}});var $p=aBe();Object.defineProperty(t,"SciChartPieLegend",{enumerable:!0,get:function(){return $p.SciChartPieLegend}});var Cu=lW();Object.defineProperty(t,"licenseManager2dState",{enumerable:!0,get:function(){return Cu.licenseManager2dState}});var uc=xre();Object.defineProperty(t,"DefaultSciChartLoader",{enumerable:!0,get:function(){return uc.DefaultSciChartLoader}});var Wp=iR();Object.defineProperty(t,"BasePointMarker",{enumerable:!0,get:function(){return Wp.BasePointMarker}});var Td=Mre();Object.defineProperty(t,"CrossPointMarker",{enumerable:!0,get:function(){return Td.CrossPointMarker}});var Tu=MI();Object.defineProperty(t,"EllipsePointMarker",{enumerable:!0,get:function(){return Tu.EllipsePointMarker}});var fh=kre();Object.defineProperty(t,"SpritePointMarker",{enumerable:!0,get:function(){return fh.SpritePointMarker}});var Gp=Ire();Object.defineProperty(t,"SquarePointMarker",{enumerable:!0,get:function(){return Gp.SquarePointMarker}});var Ua=Nre();Object.defineProperty(t,"TrianglePointMarker",{enumerable:!0,get:function(){return Ua.TrianglePointMarker}});var xd=Fre();Object.defineProperty(t,"XPointMarker",{enumerable:!0,get:function(){return xd.XPointMarker}});var hh=$S();Object.defineProperty(t,"animationHelpers",{enumerable:!0,get:function(){return hh.animationHelpers}});var Wu=pAt();Object.defineProperty(t,"BandAnimation",{enumerable:!0,get:function(){return Wu.BandAnimation}});var Yp=OVe();Object.defineProperty(t,"BandAnimationStyle",{enumerable:!0,get:function(){return Yp.BandAnimationStyle}});var Hc=YS();Object.defineProperty(t,"BaseAnimationStyle",{enumerable:!0,get:function(){return Hc.BaseAnimationStyle}});var cc=Rre();Object.defineProperty(t,"BasePointMarkerStyle",{enumerable:!0,get:function(){return cc.BasePointMarkerStyle}});var Xg=gAt();Object.defineProperty(t,"BubbleAnimation",{enumerable:!0,get:function(){return Xg.BubbleAnimation}});var Ps=vAt();Object.defineProperty(t,"CandlestickAnimation",{enumerable:!0,get:function(){return Ps.CandlestickAnimation}});var Kh=DVe();Object.defineProperty(t,"CandlestickAnimationStyle",{enumerable:!0,get:function(){return Kh.CandlestickAnimationStyle}});var ql=yAt();Object.defineProperty(t,"ColumnAnimation",{enumerable:!0,get:function(){return ql.ColumnAnimation}});var El=MVe();Object.defineProperty(t,"ColumnAnimationStyle",{enumerable:!0,get:function(){return El.ColumnAnimationStyle}});var Uc=Lre();Object.defineProperty(t,"CustomPointMarkerStyle",{enumerable:!0,get:function(){return Uc.CustomPointMarkerStyle}});var ph=xje();Object.defineProperty(t,"FadeAnimation",{enumerable:!0,get:function(){return ph.FadeAnimation}});var qp=mAt();Object.defineProperty(t,"LineAnimation",{enumerable:!0,get:function(){return qp.LineAnimation}});var wl=bAt();Object.defineProperty(t,"MountainAnimation",{enumerable:!0,get:function(){return wl.MountainAnimation}});var ol=LVe();Object.defineProperty(t,"MountainAnimationStyle",{enumerable:!0,get:function(){return ol.MountainAnimationStyle}});var Ea=RVe();Object.defineProperty(t,"OhlcAnimation",{enumerable:!0,get:function(){return Ea.OhlcAnimation}});var Io=ane();Object.defineProperty(t,"OhlcAnimationStyle",{enumerable:!0,get:function(){return Io.OhlcAnimationStyle}});var Al=RI();Object.defineProperty(t,"PointMarkerStyle",{enumerable:!0,get:function(){return Al.PointMarkerStyle}});var xi=Eje();Object.defineProperty(t,"ScaleAnimation",{enumerable:!0,get:function(){return xi.ScaleAnimation}});var yi=SAt();Object.defineProperty(t,"ScatterAnimation",{enumerable:!0,get:function(){return yi.ScatterAnimation}});var Xo=Bg();Object.defineProperty(t,"SeriesAnimation",{enumerable:!0,get:function(){return Xo.SeriesAnimation}});var Cs=wje();Object.defineProperty(t,"SweepAnimation",{enumerable:!0,get:function(){return Cs.SweepAnimation}});var Ol=Aje();Object.defineProperty(t,"WaveAnimation",{enumerable:!0,get:function(){return Ol.WaveAnimation}});var zc=UW();Object.defineProperty(t,"BaseBandRenderableSeries",{enumerable:!0,get:function(){return zc.BaseBandRenderableSeries}});var Ed=zI();Object.defineProperty(t,"BaseHeatmapRenderableSeries",{enumerable:!0,get:function(){return Ed.BaseHeatmapRenderableSeries}});var cf=mm();Object.defineProperty(t,"ELineType",{enumerable:!0,get:function(){return cf.ELineType}});var $c=mm();Object.defineProperty(t,"BaseLineRenderableSeries",{enumerable:!0,get:function(){return $c.BaseLineRenderableSeries}});var ry=$W();Object.defineProperty(t,"BaseMountainRenderableSeries",{enumerable:!0,get:function(){return ry.BaseMountainRenderableSeries}});var Ko=Vie();Object.defineProperty(t,"BaseOhlcRenderableSeries",{enumerable:!0,get:function(){return Ko.BaseOhlcRenderableSeries}});var df=ju();Object.defineProperty(t,"BaseRenderableSeries",{enumerable:!0,get:function(){return df.BaseRenderableSeries}});var Zh=Vre();Object.defineProperty(t,"BaseStackedCollection",{enumerable:!0,get:function(){return Zh.BaseStackedCollection}});var Xp=d3e();Object.defineProperty(t,"BaseStackedMountainRenderableSeries",{enumerable:!0,get:function(){return Xp.BaseStackedMountainRenderableSeries}});var Wc=YW();Object.defineProperty(t,"BaseStackedRenderableSeries",{enumerable:!0,get:function(){return Wc.BaseStackedRenderableSeries}});var $=kie();Object.defineProperty(t,"BandSeriesDataLabelProvider",{enumerable:!0,get:function(){return $.BandSeriesDataLabelProvider}});var ee=LI();Object.defineProperty(t,"BaseDataLabelProvider",{enumerable:!0,get:function(){return ee.BaseDataLabelProvider}});var ae=Iie();Object.defineProperty(t,"BubbleSeriesDataLabelProvider",{enumerable:!0,get:function(){return ae.BubbleSeriesDataLabelProvider}});var O=iI();Object.defineProperty(t,"EColumnDataLabelPosition",{enumerable:!0,get:function(){return O.EColumnDataLabelPosition}});var j=iI();Object.defineProperty(t,"ColumnSeriesDataLabelProvider",{enumerable:!0,get:function(){return j.ColumnSeriesDataLabelProvider}});var Q=Nie();Object.defineProperty(t,"ContoursDataLabelProvider",{enumerable:!0,get:function(){return Q.ContoursDataLabelProvider}});var ie=C3e();Object.defineProperty(t,"dataLabelHelpers",{enumerable:!0,get:function(){return ie.dataLabelHelpers}});var he=Wv();Object.defineProperty(t,"DataLabelProvider",{enumerable:!0,get:function(){return he.DataLabelProvider}});var Oe=UI();Object.defineProperty(t,"DataLabelState",{enumerable:!0,get:function(){return Oe.DataLabelState}});var Fe=tH();Object.defineProperty(t,"HeatMapDataLabelProvider",{enumerable:!0,get:function(){return Fe.HeatMapDataLabelProvider}});var Ge=fR();Object.defineProperty(t,"LineSeriesDataLabelProvider",{enumerable:!0,get:function(){return Ge.LineSeriesDataLabelProvider}});var lt=Fie();Object.defineProperty(t,"NonUniformHeatMapDataLabelProvider",{enumerable:!0,get:function(){return lt.NonUniformHeatMapDataLabelProvider}});var Ot=T3e();Object.defineProperty(t,"RectangleDataLabelState",{enumerable:!0,get:function(){return Ot.RectangleDataLabelState}});var St=qie();Object.defineProperty(t,"RectangleSeriesDataLabelProvider",{enumerable:!0,get:function(){return St.RectangleSeriesDataLabelProvider}});var jt=IFe();Object.defineProperty(t,"StackedCollectionDataLabelProvider",{enumerable:!0,get:function(){return jt.StackedCollectionDataLabelProvider}});var cr=p3e();Object.defineProperty(t,"StackedColumnSeriesDataLabelProvider",{enumerable:!0,get:function(){return cr.StackedColumnSeriesDataLabelProvider}});var or=HW();Object.defineProperty(t,"TextDataLabelProvider",{enumerable:!0,get:function(){return or.TextDataLabelProvider}});var mr=Bie();Object.defineProperty(t,"BandSeriesDrawingProvider",{enumerable:!0,get:function(){return mr.BandSeriesDrawingProvider}});var Vr=du();Object.defineProperty(t,"BaseSeriesDrawingProvider",{enumerable:!0,get:function(){return Vr.BaseSeriesDrawingProvider}});var ei=k3e();Object.defineProperty(t,"BoxPlotSeriesDrawingProvider",{enumerable:!0,get:function(){return ei.BoxPlotSeriesDrawingProvider}});var ui=Mje();Object.defineProperty(t,"BubbleSeriesDrawingProvider",{enumerable:!0,get:function(){return ui.BubbleSeriesDrawingProvider}});var Ei=Bje();Object.defineProperty(t,"ColumnSeriesDrawingProvider",{enumerable:!0,get:function(){return Ei.ColumnSeriesDrawingProvider}});var jr=Hje();Object.defineProperty(t,"ErrorSeriesDrawingProvider",{enumerable:!0,get:function(){return jr.ErrorSeriesDrawingProvider}});var cn=NO();Object.defineProperty(t,"getColorDataForTexture",{enumerable:!0,get:function(){return cn.getColorDataForTexture}});var ji=NO();Object.defineProperty(t,"getColor",{enumerable:!0,get:function(){return ji.getColor}});var Kr=NO();Object.defineProperty(t,"createColorMap",{enumerable:!0,get:function(){return Kr.createColorMap}});var Ai=NO();Object.defineProperty(t,"calculateOffsets",{enumerable:!0,get:function(){return Ai.calculateOffsets}});var qa=NO();Object.defineProperty(t,"calculateCellCoordinates",{enumerable:!0,get:function(){return qa.calculateCellCoordinates}});var sa=NO();Object.defineProperty(t,"calculateHeatmapTexture",{enumerable:!0,get:function(){return sa.calculateHeatmapTexture}});var No=_At();Object.defineProperty(t,"HeightSeriesDrawingProvider",{enumerable:!0,get:function(){return No.HeightSeriesDrawingProvider}});var al=m3e();Object.defineProperty(t,"LineSegmentSeriesDrawingProvider",{enumerable:!0,get:function(){return al.LineSegmentSeriesDrawingProvider}});var pn=Hie();Object.defineProperty(t,"LineSeriesDrawingProvider",{enumerable:!0,get:function(){return pn.LineSeriesDrawingProvider}});var sl=qje();Object.defineProperty(t,"MountainSeriesDrawingProvider",{enumerable:!0,get:function(){return sl.MountainSeriesDrawingProvider}});var Hs=e3e();Object.defineProperty(t,"NonUniformHeatmapDrawingProvider",{enumerable:!0,get:function(){return Hs.NonUniformHeatmapDrawingProvider}});var In=o$();Object.defineProperty(t,"EOhlcDrawingMode",{enumerable:!0,get:function(){return In.EOhlcDrawingMode}});var dc=o$();Object.defineProperty(t,"OhlcSeriesDrawingProvider",{enumerable:!0,get:function(){return dc.OhlcSeriesDrawingProvider}});var ss=Yf();Object.defineProperty(t,"PointMarkerDrawingProvider",{enumerable:!0,get:function(){return ss.PointMarkerDrawingProvider}});var Hm=_3e();Object.defineProperty(t,"RectangleSeriesDrawingProvider",{enumerable:!0,get:function(){return Hm.RectangleSeriesDrawingProvider}});var sC=PAt();Object.defineProperty(t,"SmearSeriesDrawingProvider",{enumerable:!0,get:function(){return sC.SmearSeriesDrawingProvider}});var Um=Kz();Object.defineProperty(t,"StackedColumnRenderPassData",{enumerable:!0,get:function(){return Um.StackedColumnRenderPassData}});var t2=Kz();Object.defineProperty(t,"StackedColumnSeriesDrawingProvider",{enumerable:!0,get:function(){return t2.StackedColumnSeriesDrawingProvider}});var mR=Qie();Object.defineProperty(t,"TriangleSeriesDrawingProvider",{enumerable:!0,get:function(){return mR.TriangleSeriesDrawingProvider}});var bR=v3e();Object.defineProperty(t,"UniformContoursDrawingProvider",{enumerable:!0,get:function(){return bR.UniformContoursDrawingProvider}});var lC=Gie();Object.defineProperty(t,"UniformHeatmapDrawingProvider",{enumerable:!0,get:function(){return lC.UniformHeatmapDrawingProvider}});var uC=Dje();Object.defineProperty(t,"FastBandRenderableSeries",{enumerable:!0,get:function(){return uC.FastBandRenderableSeries}});var SR=N3e();Object.defineProperty(t,"FastBoxPlotRenderableSeries",{enumerable:!0,get:function(){return SR.FastBoxPlotRenderableSeries}});var XS=kje();Object.defineProperty(t,"FastBubbleRenderableSeries",{enumerable:!0,get:function(){return XS.FastBubbleRenderableSeries}});var cC=Fje();Object.defineProperty(t,"FastCandlestickRenderableSeries",{enumerable:!0,get:function(){return cC.FastCandlestickRenderableSeries}});var Gu=q3();Object.defineProperty(t,"FastColumnRenderableSeries",{enumerable:!0,get:function(){return Gu.FastColumnRenderableSeries}});var wd=q3();Object.defineProperty(t,"getXRange",{enumerable:!0,get:function(){return wd.getXRange}});var _R=zje();Object.defineProperty(t,"FastErrorBarsRenderableSeries",{enumerable:!0,get:function(){return _R.FastErrorBarsRenderableSeries}});var PR=Wje();Object.defineProperty(t,"FastImpulseRenderableSeries",{enumerable:!0,get:function(){return PR.FastImpulseRenderableSeries}});var KS=Yje();Object.defineProperty(t,"FastLineRenderableSeries",{enumerable:!0,get:function(){return KS.FastLineRenderableSeries}});var Kp=S3e();Object.defineProperty(t,"FastLineSegmentRenderableSeries",{enumerable:!0,get:function(){return Kp.FastLineSegmentRenderableSeries}});var dC=Kje();Object.defineProperty(t,"FastMountainRenderableSeries",{enumerable:!0,get:function(){return dC.FastMountainRenderableSeries}});var fC=Zje();Object.defineProperty(t,"FastOhlcRenderableSeries",{enumerable:!0,get:function(){return fC.FastOhlcRenderableSeries}});var hC=Xie();Object.defineProperty(t,"FastRectangleRenderableSeries",{enumerable:!0,get:function(){return hC.FastRectangleRenderableSeries}});var pC=Uie();Object.defineProperty(t,"FastTextRenderableSeries",{enumerable:!0,get:function(){return pC.FastTextRenderableSeries}});var Kg=ene();Object.defineProperty(t,"FastTriangleRenderableSeries",{enumerable:!0,get:function(){return Kg.FastTriangleRenderableSeries}});var zm=Qje();Object.defineProperty(t,"GlowEffect",{enumerable:!0,get:function(){return zm.GlowEffect}});var r2=GW();Object.defineProperty(t,"HeatmapColorMap",{enumerable:!0,get:function(){return r2.HeatmapColorMap}});var gC=Oje();Object.defineProperty(t,"BandSeriesHitTestProvider",{enumerable:!0,get:function(){return gC.BandSeriesHitTestProvider}});var iy=Vl();Object.defineProperty(t,"BaseHitTestProvider",{enumerable:!0,get:function(){return iy.BaseHitTestProvider}});var ny=I3e();Object.defineProperty(t,"BoxPlotSeriesHitTestProvider",{enumerable:!0,get:function(){return ny.BoxPlotSeriesHitTestProvider}});var $m=Lje();Object.defineProperty(t,"BubbleSeriesHitTestProvider",{enumerable:!0,get:function(){return $m.BubbleSeriesHitTestProvider}});var Wm=jje();Object.defineProperty(t,"ColumnSeriesHitTestProvider",{enumerable:!0,get:function(){return Wm.ColumnSeriesHitTestProvider}});var ZS=Uje();Object.defineProperty(t,"ErrorSeriesHitTestProvider",{enumerable:!0,get:function(){return ZS.ErrorSeriesHitTestProvider}});var Zp=vl();Object.defineProperty(t,"hitTestHelpers",{enumerable:!0,get:function(){return Zp.hitTestHelpers}});var CR=P3e();Object.defineProperty(t,"hitTestHelpersRectangleSeries",{enumerable:!0,get:function(){return CR.hitTestHelpersRectangleSeries}});var JS=tl();Object.defineProperty(t,"HitTestInfo",{enumerable:!0,get:function(){return JS.HitTestInfo}});var Gm=$je();Object.defineProperty(t,"ImpulseSeriesHitTestProvider",{enumerable:!0,get:function(){return Gm.ImpulseSeriesHitTestProvider}});var QS=b3e();Object.defineProperty(t,"LineSegmentSeriesHitTestProvider",{enumerable:!0,get:function(){return QS.LineSegmentSeriesHitTestProvider}});var Ym=Gje();Object.defineProperty(t,"LineSeriesHitTestProvider",{enumerable:!0,get:function(){return Ym.LineSeriesHitTestProvider}});var TR=Xje();Object.defineProperty(t,"MountainSeriesHitTestProvider",{enumerable:!0,get:function(){return TR.MountainSeriesHitTestProvider}});var vC=t3e();Object.defineProperty(t,"NonUniformHeatmapHitTestProvider",{enumerable:!0,get:function(){return vC.NonUniformHeatmapHitTestProvider}});var Yu=Nje();Object.defineProperty(t,"OhlcSeriesHitTestProvider",{enumerable:!0,get:function(){return Yu.OhlcSeriesHitTestProvider}});var yC=KW();Object.defineProperty(t,"RectangleSeriesHitTestProvider",{enumerable:!0,get:function(){return yC.RectangleSeriesHitTestProvider}});var mC=y3e();Object.defineProperty(t,"ScatterSeriesHitTestProvider",{enumerable:!0,get:function(){return mC.ScatterSeriesHitTestProvider}});var xR=h3e();Object.defineProperty(t,"StackedColumnSeriesHitTestProvider",{enumerable:!0,get:function(){return xR.StackedColumnSeriesHitTestProvider}});var qm=c3e();Object.defineProperty(t,"StackedMountainSeriesHitTestProvider",{enumerable:!0,get:function(){return qm.StackedMountainSeriesHitTestProvider}});var ER=Jje();Object.defineProperty(t,"TextSeriesHitTestProvider",{enumerable:!0,get:function(){return ER.TextSeriesHitTestProvider}});var bC=F3e();Object.defineProperty(t,"TriangleSeriesHitTestProvider",{enumerable:!0,get:function(){return bC.TriangleSeriesHitTestProvider}});var gh=Wie();Object.defineProperty(t,"UniformHeatmapHitTestProvider",{enumerable:!0,get:function(){return gh.UniformHeatmapHitTestProvider}});var e_=QBe();Object.defineProperty(t,"HoveredChangedArgs",{enumerable:!0,get:function(){return e_.HoveredChangedArgs}});var SC=r3e();Object.defineProperty(t,"NonUniformHeatmapRenderableSeries",{enumerable:!0,get:function(){return SC.NonUniformHeatmapRenderableSeries}});var Xm=A3e();Object.defineProperty(t,"PolarColumnDataLabelState",{enumerable:!0,get:function(){return Xm.PolarColumnDataLabelState}});var Xa=Jie();Object.defineProperty(t,"PolarColumnSeriesDataLabelProvider",{enumerable:!0,get:function(){return Xa.PolarColumnSeriesDataLabelProvider}});var ls=pR();Object.defineProperty(t,"PolarDataLabelProvider",{enumerable:!0,get:function(){return ls.PolarDataLabelProvider}});var Mi=ZW();Object.defineProperty(t,"PolarDataLabelState",{enumerable:!0,get:function(){return Mi.PolarDataLabelState}});var Km=z3e();Object.defineProperty(t,"PolarHeatMapDataLabelProvider",{enumerable:!0,get:function(){return Km.PolarHeatMapDataLabelProvider}});var t_=ine();Object.defineProperty(t,"PolarTextDataLabelProvider",{enumerable:!0,get:function(){return t_.PolarTextDataLabelProvider}});var Jp=QW();Object.defineProperty(t,"PolarBandSeriesDrawingProvider",{enumerable:!0,get:function(){return Jp.PolarBandSeriesDrawingProvider}});var Zm=Zie();Object.defineProperty(t,"PolarColumnSeriesDrawingProvider",{enumerable:!0,get:function(){return Zm.PolarColumnSeriesDrawingProvider}});var r_=$3e();Object.defineProperty(t,"PolarHeatmapDrawingProvider",{enumerable:!0,get:function(){return r_.PolarHeatmapDrawingProvider}});var Jm=rH();Object.defineProperty(t,"PolarLineSeriesDrawingProvider",{enumerable:!0,get:function(){return Jm.PolarLineSeriesDrawingProvider}});var Xl=nC();Object.defineProperty(t,"PolarPointMarkerDrawingProvider",{enumerable:!0,get:function(){return Xl.PolarPointMarkerDrawingProvider}});var i2=oVe();Object.defineProperty(t,"PolarTriangleSeriesDrawingProvider",{enumerable:!0,get:function(){return i2.PolarTriangleSeriesDrawingProvider}});var i_=gR();Object.defineProperty(t,"PolarDataPointHitTestProvider",{enumerable:!0,get:function(){return i_.PolarDataPointHitTestProvider}});var n_=Kie();Object.defineProperty(t,"polarHitTestHelpers",{enumerable:!0,get:function(){return n_.polarHitTestHelpers}});var wR=CAt();Object.defineProperty(t,"PolarLineSeriesHitTestProvider",{enumerable:!0,get:function(){return wR.PolarLineSeriesHitTestProvider}});var _C=D3e();Object.defineProperty(t,"PolarMountainSeriesHitTestProvider",{enumerable:!0,get:function(){return _C.PolarMountainSeriesHitTestProvider}});var AR=w3e();Object.defineProperty(t,"PolarBandRenderableSeries",{enumerable:!0,get:function(){return AR.PolarBandRenderableSeries}});var PC=O3e();Object.defineProperty(t,"PolarColumnRenderableSeries",{enumerable:!0,get:function(){return PC.PolarColumnRenderableSeries}});var CC=x3e();Object.defineProperty(t,"PolarLineRenderableSeries",{enumerable:!0,get:function(){return CC.PolarLineRenderableSeries}});var ff=R3e();Object.defineProperty(t,"PolarMountainRenderableSeries",{enumerable:!0,get:function(){return ff.PolarMountainRenderableSeries}});var xu=H3e();Object.defineProperty(t,"PolarStackedColumnCollection",{enumerable:!0,get:function(){return xu.PolarStackedColumnCollection}});var Qm=U3e();Object.defineProperty(t,"PolarStackedColumnRenderableSeries",{enumerable:!0,get:function(){return Qm.PolarStackedColumnRenderableSeries}});var o_=V3e();Object.defineProperty(t,"PolarStackedMountainCollection",{enumerable:!0,get:function(){return o_.PolarStackedMountainCollection}});var e0=M3e();Object.defineProperty(t,"PolarStackedMountainRenderableSeries",{enumerable:!0,get:function(){return e0.PolarStackedMountainRenderableSeries}});var OR=sVe();Object.defineProperty(t,"PolarTextRenderableSeries",{enumerable:!0,get:function(){return OR.PolarTextRenderableSeries}});var TC=aVe();Object.defineProperty(t,"PolarTriangleRenderableSeries",{enumerable:!0,get:function(){return TC.PolarTriangleRenderableSeries}});var oy=W3e();Object.defineProperty(t,"PolarUniformHeatmapRenderableSeries",{enumerable:!0,get:function(){return oy.PolarUniformHeatmapRenderableSeries}});var vh=j3e();Object.defineProperty(t,"PolarXyScatterRenderableSeries",{enumerable:!0,get:function(){return vh.PolarXyScatterRenderableSeries}});var a_=Cv();Object.defineProperty(t,"BaseRenderDataTransform",{enumerable:!0,get:function(){return a_.BaseRenderDataTransform}});var n2=Cv();Object.defineProperty(t,"XyBaseRenderDataTransform",{enumerable:!0,get:function(){return n2.XyBaseRenderDataTransform}});var DR=Cv();Object.defineProperty(t,"XyyBaseRenderDataTransform",{enumerable:!0,get:function(){return DR.XyyBaseRenderDataTransform}});var Jh=Cv();Object.defineProperty(t,"OhlcBaseRenderDataTransform",{enumerable:!0,get:function(){return Jh.OhlcBaseRenderDataTransform}});var xC=Cv();Object.defineProperty(t,"XyzBaseRenderDataTransform",{enumerable:!0,get:function(){return xC.XyzBaseRenderDataTransform}});var EC=TAt();Object.defineProperty(t,"BaseRenderDataTransformJS",{enumerable:!0,get:function(){return EC.BaseRenderDataTransformJS}});var t0=fj();Object.defineProperty(t,"bezierTransform",{enumerable:!0,get:function(){return t0.bezierTransform}});var r0=fj();Object.defineProperty(t,"BezierRenderDataTransform",{enumerable:!0,get:function(){return r0.BezierRenderDataTransform}});var la=fj();Object.defineProperty(t,"XyyBezierRenderDataTransform",{enumerable:!0,get:function(){return la.XyyBezierRenderDataTransform}});var RR=fj();Object.defineProperty(t,"SmoothStackedRenderDataTransform",{enumerable:!0,get:function(){return RR.SmoothStackedRenderDataTransform}});var i0=E3e();Object.defineProperty(t,"PolarInterpolateBandRenderDataTransform",{enumerable:!0,get:function(){return i0.PolarInterpolateBandRenderDataTransform}});var s_=JW();Object.defineProperty(t,"PolarInterpolateLineRenderDataTransform",{enumerable:!0,get:function(){return s_.PolarInterpolateLineRenderDataTransform}});var ay=$ie();Object.defineProperty(t,"SplineRenderDataTransform",{enumerable:!0,get:function(){return ay.SplineRenderDataTransform}});var Qh=o3e();Object.defineProperty(t,"XyySplineRenderDataTransform",{enumerable:!0,get:function(){return Qh.XyySplineRenderDataTransform}});var n0=CW();Object.defineProperty(t,"RolloverModifierRenderableSeriesProps",{enumerable:!0,get:function(){return n0.RolloverModifierRenderableSeriesProps}});var wC=eje();Object.defineProperty(t,"SelectionChangedArgs",{enumerable:!0,get:function(){return wC.SelectionChangedArgs}});var fc=xFe();Object.defineProperty(t,"SeriesHoveredArgs",{enumerable:!0,get:function(){return fc.SeriesHoveredArgs}});var Eu=EFe();Object.defineProperty(t,"SeriesSelectedArgs",{enumerable:!0,get:function(){return Eu.SeriesSelectedArgs}});var MR=wFe();Object.defineProperty(t,"SeriesVisibleChangedArgs",{enumerable:!0,get:function(){return MR.SeriesVisibleChangedArgs}});var l_=zie();Object.defineProperty(t,"ShaderEffect",{enumerable:!0,get:function(){return l_.ShaderEffect}});var LR=i3e();Object.defineProperty(t,"ShadowEffect",{enumerable:!0,get:function(){return LR.ShadowEffect}});var AC=f3e();Object.defineProperty(t,"SmoothStackedMountainRenderableSeries",{enumerable:!0,get:function(){return AC.SmoothStackedMountainRenderableSeries}});var OC=a3e();Object.defineProperty(t,"SplineBandRenderableSeries",{enumerable:!0,get:function(){return OC.SplineBandRenderableSeries}});var u_=s3e();Object.defineProperty(t,"SplineLineRenderableSeries",{enumerable:!0,get:function(){return u_.SplineLineRenderableSeries}});var kR=l3e();Object.defineProperty(t,"SplineMountainRenderableSeries",{enumerable:!0,get:function(){return kR.SplineMountainRenderableSeries}});var ep=Ure();Object.defineProperty(t,"StackedColumnCollection",{enumerable:!0,get:function(){return ep.StackedColumnCollection}});var Us=g3e();Object.defineProperty(t,"StackedColumnRenderableSeries",{enumerable:!0,get:function(){return Us.StackedColumnRenderableSeries}});var DC=xW();Object.defineProperty(t,"StackedMountainCollection",{enumerable:!0,get:function(){return DC.StackedMountainCollection}});var IR=qW();Object.defineProperty(t,"StackedMountainRenderableSeries",{enumerable:!0,get:function(){return IR.StackedMountainRenderableSeries}});var Dl=zre();Object.defineProperty(t,"StackedXyCollection",{enumerable:!0,get:function(){return Dl.StackedXyCollection}});var o2=vJ();Object.defineProperty(t,"EContourColorMapMode",{enumerable:!0,get:function(){return o2.EContourColorMapMode}});var RC=vJ();Object.defineProperty(t,"UniformContoursRenderableSeries",{enumerable:!0,get:function(){return RC.UniformContoursRenderableSeries}});var MC=XW();Object.defineProperty(t,"UniformHeatmapRenderableSeries",{enumerable:!0,get:function(){return MC.UniformHeatmapRenderableSeries}});var wa=Yie();Object.defineProperty(t,"XyScatterRenderableSeries",{enumerable:!0,get:function(){return wa.XyScatterRenderableSeries}});var hc=xie();Object.defineProperty(t,"RubberBandSvgRect",{enumerable:!0,get:function(){return hc.RubberBandSvgRect}});var tp=Wf();Object.defineProperty(t,"SciChartDefaults",{enumerable:!0,get:function(){return tp.SciChartDefaults}});var NR=xAt();Object.defineProperty(t,"SciChartOverview",{enumerable:!0,get:function(){return NR.SciChartOverview}});var LC=gVe();Object.defineProperty(t,"PieSegment",{enumerable:!0,get:function(){return LC.PieSegment}});var FR=GO();Object.defineProperty(t,"ESizingMode",{enumerable:!0,get:function(){return FR.ESizingMode}});var a2=GO();Object.defineProperty(t,"EPieType",{enumerable:!0,get:function(){return a2.EPieType}});var c_=GO();Object.defineProperty(t,"EPieValueMode",{enumerable:!0,get:function(){return c_.EPieValueMode}});var pc=GO();Object.defineProperty(t,"SciChartPieSurface",{enumerable:!0,get:function(){return pc.SciChartPieSurface}});var hf=lie();Object.defineProperty(t,"SciChartPolarSubSurface",{enumerable:!0,get:function(){return hf.SciChartPolarSubSurface}});var BR=aie();Object.defineProperty(t,"SciChartPolarSurface",{enumerable:!0,get:function(){return BR.SciChartPolarSurface}});var Aa=uie();Object.defineProperty(t,"SciChartSubSurface",{enumerable:!0,get:function(){return Aa.SciChartSubSurface}});var jR=sie();Object.defineProperty(t,"sciChartSubSurfaceCommon",{enumerable:!0,get:function(){return jR.sciChartSubSurfaceCommon}});var rp=Rg();Object.defineProperty(t,"sciChartConfig",{enumerable:!0,get:function(){return rp.sciChartConfig}});var Zg=Rg();Object.defineProperty(t,"SciChartSurface",{enumerable:!0,get:function(){return Zg.SciChartSurface}});var yh=Sn();Object.defineProperty(t,"DebugForDpi",{enumerable:!0,get:function(){return yh.DebugForDpi}});var kC=Sn();Object.defineProperty(t,"SciChartSurfaceBase",{enumerable:!0,get:function(){return kC.SciChartSurfaceBase}});var IC=Sn();Object.defineProperty(t,"createChartDestination",{enumerable:!0,get:function(){return IC.createChartDestination}});var pf=Ere();Object.defineProperty(t,"SciChartSurfaceCore",{enumerable:!0,get:function(){return pf.SciChartSurfaceCore}});var VR=rR();Object.defineProperty(t,"CanvasTexture",{enumerable:!0,get:function(){return VR.CanvasTexture}});var Qp=Zi();Object.defineProperty(t,"DpiHelper",{enumerable:!0,get:function(){return Qp.DpiHelper}});var o0=gD();Object.defineProperty(t,"TextureManager",{enumerable:!0,get:function(){return o0.TextureManager}});var a0=gD();Object.defineProperty(t,"measureTextHeight",{enumerable:!0,get:function(){return a0.measureTextHeight}});var sy=gD();Object.defineProperty(t,"measureTextWidth",{enumerable:!0,get:function(){return sy.measureTextWidth}});var HR=aFe();Object.defineProperty(t,"UpdateSuspender",{enumerable:!0,get:function(){return HR.UpdateSuspender}});var UR=rI();Object.defineProperty(t,"ECameraProjectionMode",{enumerable:!0,get:function(){return UR.ECameraProjectionMode}});var s0=rI();Object.defineProperty(t,"CameraController",{enumerable:!0,get:function(){return s0.CameraController}});var zR=dR();Object.defineProperty(t,"ChartModifierBase3D",{enumerable:!0,get:function(){return zR.ChartModifierBase3D}});var d_=EAt();Object.defineProperty(t,"CustomChartModifier3D",{enumerable:!0,get:function(){return d_.CustomChartModifier3D}});var $R=Cje();Object.defineProperty(t,"LegendModifier3D",{enumerable:!0,get:function(){return $R.LegendModifier3D}});var s2=yje();Object.defineProperty(t,"MouseWheelZoomModifier3D",{enumerable:!0,get:function(){return s2.MouseWheelZoomModifier3D}});var l2=mje();Object.defineProperty(t,"OrbitModifier3D",{enumerable:!0,get:function(){return l2.OrbitModifier3D}});var Oo=Mie();Object.defineProperty(t,"PinchZoomModifier3D",{enumerable:!0,get:function(){return Oo.PinchZoomModifier3D}});var ua=_je();Object.defineProperty(t,"ResetCamera3DModifier",{enumerable:!0,get:function(){return ua.ResetCamera3DModifier}});var Un=gJ();Object.defineProperty(t,"TooltipModifier3D",{enumerable:!0,get:function(){return Un.TooltipModifier3D}});var Xn=gJ();Object.defineProperty(t,"adjustTooltipPosition3D",{enumerable:!0,get:function(){return Xn.adjustTooltipPosition3D}});var $o=Uf();Object.defineProperty(t,"EDataSeriesType3D",{enumerable:!0,get:function(){return $o.EDataSeriesType3D}});var Gc=Uf();Object.defineProperty(t,"BaseDataSeries3D",{enumerable:!0,get:function(){return Gc.BaseDataSeries3D}});var eg=BBe();Object.defineProperty(t,"BaseGridDataSeries3D",{enumerable:!0,get:function(){return eg.BaseGridDataSeries3D}});var ly=jBe();Object.defineProperty(t,"UniformGridDataSeries3D",{enumerable:!0,get:function(){return ly.UniformGridDataSeries3D}});var NC=VBe();Object.defineProperty(t,"XyzDataSeries3D",{enumerable:!0,get:function(){return NC.XyzDataSeries3D}});var gf=cR();Object.defineProperty(t,"Vector3",{enumerable:!0,get:function(){return gf.Vector3}});var Ka=bje();Object.defineProperty(t,"TooltipSvgAnnotation3D",{enumerable:!0,get:function(){return Ka.TooltipSvgAnnotation3D}});var tg=hJ();Object.defineProperty(t,"EWhichAxis",{enumerable:!0,get:function(){return tg.EWhichAxis}});var Jg=hJ();Object.defineProperty(t,"AxisBase3D",{enumerable:!0,get:function(){return Jg.AxisBase3D}});var FC=vVe();Object.defineProperty(t,"AxisCubeEntity",{enumerable:!0,get:function(){return FC.AxisCubeEntity}});var Yc=wAt();Object.defineProperty(t,"EAxisSideClipping",{enumerable:!0,get:function(){return Yc.EAxisSideClipping}});var uy=AAt();Object.defineProperty(t,"ETextAlignment3D",{enumerable:!0,get:function(){return uy.ETextAlignment3D}});var l0=mL();Object.defineProperty(t,"getDescriptorsEqual",{enumerable:!0,get:function(){return l0.getDescriptorsEqual}});var gc=mL();Object.defineProperty(t,"getLineStylesEqual",{enumerable:!0,get:function(){return gc.getLineStylesEqual}});var BC=mL();Object.defineProperty(t,"getTArgbEqual",{enumerable:!0,get:function(){return BC.getTArgbEqual}});var u0=mL();Object.defineProperty(t,"getTextStylesEqual",{enumerable:!0,get:function(){return u0.getTextStylesEqual}});var WR=mL();Object.defineProperty(t,"getArraysEqual",{enumerable:!0,get:function(){return WR.getArraysEqual}});var Qg=pie();Object.defineProperty(t,"NumericAxis3D",{enumerable:!0,get:function(){return Qg.NumericAxis3D}});var f_=bJ();Object.defineProperty(t,"EAxisPlaneType",{enumerable:!0,get:function(){return f_.EAxisPlaneType}});var rg=bJ();Object.defineProperty(t,"AxisPlane",{enumerable:!0,get:function(){return rg.AxisPlane}});var ll=mJ();Object.defineProperty(t,"getSharedWasmContext3D",{enumerable:!0,get:function(){return ll.getSharedWasmContext3D}});var ig=mJ();Object.defineProperty(t,"initializeChartEngine3D",{enumerable:!0,get:function(){return ig.initializeChartEngine3D}});var cy=mVe();Object.defineProperty(t,"createSingle3dInternal",{enumerable:!0,get:function(){return cy.createSingle3dInternal}});var ip=SVe();Object.defineProperty(t,"DefaultViewportManager3D",{enumerable:!0,get:function(){return ip.DefaultViewportManager3D}});var jC=_Ve();Object.defineProperty(t,"GizmoEntity",{enumerable:!0,get:function(){return jC.GizmoEntity}});var VC=G3e();Object.defineProperty(t,"BaseMeshPointMarker3D",{enumerable:!0,get:function(){return VC.BaseMeshPointMarker3D}});var GR=kD();Object.defineProperty(t,"EMarkerType",{enumerable:!0,get:function(){return GR.EMarkerType}});var c0=kD();Object.defineProperty(t,"BasePointMarker3D",{enumerable:!0,get:function(){return c0.BasePointMarker3D}});var HC=Y3e();Object.defineProperty(t,"BaseTexturePointMarker3D",{enumerable:!0,get:function(){return HC.BaseTexturePointMarker3D}});var qc=Ry();Object.defineProperty(t,"SpherePointMarker3D",{enumerable:!0,get:function(){return qc.SpherePointMarker3D}});var YR=Ry();Object.defineProperty(t,"CubePointMarker3D",{enumerable:!0,get:function(){return YR.CubePointMarker3D}});var vc=Ry();Object.defineProperty(t,"PyramidPointMarker3D",{enumerable:!0,get:function(){return vc.PyramidPointMarker3D}});var qR=Ry();Object.defineProperty(t,"CylinderPointMarker3D",{enumerable:!0,get:function(){return qR.CylinderPointMarker3D}});var XR=Ry();Object.defineProperty(t,"PixelPointMarker3D",{enumerable:!0,get:function(){return XR.PixelPointMarker3D}});var KR=Ry();Object.defineProperty(t,"QuadPointMarker",{enumerable:!0,get:function(){return KR.QuadPointMarker}});var np=Ry();Object.defineProperty(t,"EllipsePointMarker3D",{enumerable:!0,get:function(){return np.EllipsePointMarker3D}});var h_=Ry();Object.defineProperty(t,"TrianglePointMarker3D",{enumerable:!0,get:function(){return h_.TrianglePointMarker3D}});var UC=TVe();Object.defineProperty(t,"AxisCubeDescriptor",{enumerable:!0,get:function(){return UC.AxisCubeDescriptor}});var dy=HI();Object.defineProperty(t,"BaseSceneEntity3D",{enumerable:!0,get:function(){return dy.BaseSceneEntity3D}});var ZR=q3e();Object.defineProperty(t,"ColumnSceneEntity",{enumerable:!0,get:function(){return ZR.ColumnSceneEntity}});var d0=Sje();Object.defineProperty(t,"CrosshairLinesSceneEntity",{enumerable:!0,get:function(){return d0.CrosshairLinesSceneEntity}});var JR=PVe();Object.defineProperty(t,"DefaultEntityIdProvider",{enumerable:!0,get:function(){return JR.DefaultEntityIdProvider}});var QR=Q3e();Object.defineProperty(t,"PointLine3DSceneEntity",{enumerable:!0,get:function(){return QR.PointLine3DSceneEntity}});var p_=iH();Object.defineProperty(t,"RenderableSeriesSceneEntity",{enumerable:!0,get:function(){return p_.RenderableSeriesSceneEntity}});var zC=nH();Object.defineProperty(t,"RenderableSeriesSceneEntityState",{enumerable:!0,get:function(){return zC.RenderableSeriesSceneEntityState}});var u2=xVe();Object.defineProperty(t,"RenderPassInfo3D",{enumerable:!0,get:function(){return u2.RenderPassInfo3D}});var c2=tVe();Object.defineProperty(t,"ScatterPointsSceneEntity",{enumerable:!0,get:function(){return c2.ScatterPointsSceneEntity}});var d2=EVe();Object.defineProperty(t,"SceneDescriptor",{enumerable:!0,get:function(){return d2.SceneDescriptor}});var eM=yJ();Object.defineProperty(t,"SurfaceMeshSceneEntityState",{enumerable:!0,get:function(){return eM.SurfaceMeshSceneEntityState}});var tM=yJ();Object.defineProperty(t,"SurfaceMeshSceneEntity",{enumerable:!0,get:function(){return tM.SurfaceMeshSceneEntity}});var fy=oH();Object.defineProperty(t,"BaseRenderableSeries3D",{enumerable:!0,get:function(){return fy.BaseRenderableSeries3D}});var g_=J3e();Object.defineProperty(t,"ColumnRenderableSeries3D",{enumerable:!0,get:function(){return g_.ColumnRenderableSeries3D}});var f0=vR();Object.defineProperty(t,"ESeriesType3D",{enumerable:!0,get:function(){return f0.ESeriesType3D}});var rM=VW();Object.defineProperty(t,"HitTestInfo3D",{enumerable:!0,get:function(){return rM.HitTestInfo3D}});var $C=eVe();Object.defineProperty(t,"PointLineRenderableSeries3D",{enumerable:!0,get:function(){return $C.PointLineRenderableSeries3D}});var WC=rVe();Object.defineProperty(t,"ScatterRenderableSeries3D",{enumerable:!0,get:function(){return WC.ScatterRenderableSeries3D}});var v_=X3e();Object.defineProperty(t,"Series3DVisibleChangedArgs",{enumerable:!0,get:function(){return v_.Series3DVisibleChangedArgs}});var GC=eH();Object.defineProperty(t,"SeriesInfo3D",{enumerable:!0,get:function(){return GC.SeriesInfo3D}});var h0=iVe();Object.defineProperty(t,"GradientColorPalette",{enumerable:!0,get:function(){return h0.GradientColorPalette}});var YC=rne();Object.defineProperty(t,"MeshColorPalette",{enumerable:!0,get:function(){return YC.MeshColorPalette}});var qC=nVe();Object.defineProperty(t,"SolidColorBrushPalette",{enumerable:!0,get:function(){return qC.SolidColorBrushPalette}});var Wo=kL();Object.defineProperty(t,"EDrawMeshAs",{enumerable:!0,get:function(){return Wo.EDrawMeshAs}});var XC=kL();Object.defineProperty(t,"EMeshPaletteMode",{enumerable:!0,get:function(){return XC.EMeshPaletteMode}});var f2=kL();Object.defineProperty(t,"EMeshResolution",{enumerable:!0,get:function(){return f2.EMeshResolution}});var p0=kL();Object.defineProperty(t,"SurfaceMeshRenderableSeries3D",{enumerable:!0,get:function(){return p0.SurfaceMeshRenderableSeries3D}});var y_=K3e();Object.defineProperty(t,"SurfaceMeshSeriesInfo3D",{enumerable:!0,get:function(){return y_.SurfaceMeshSeriesInfo3D}});var h2=Z3e();Object.defineProperty(t,"XyzSeriesInfo3D",{enumerable:!0,get:function(){return h2.XyzSeriesInfo3D}});var p2=CVe();Object.defineProperty(t,"RootSceneEntity",{enumerable:!0,get:function(){return p2.RootSceneEntity}});var hy=wVe();Object.defineProperty(t,"SciChart3DRenderer",{enumerable:!0,get:function(){return hy.SciChart3DRenderer}});var ev=Z3();Object.defineProperty(t,"sciChartConfig3D",{enumerable:!0,get:function(){return ev.sciChartConfig3D}});var KC=Z3();Object.defineProperty(t,"SciChart3DSurface",{enumerable:!0,get:function(){return KC.SciChart3DSurface}});var m_=bVe();Object.defineProperty(t,"ViewportManager3DBase",{enumerable:!0,get:function(){return m_.ViewportManager3DBase}});var ZC=cP();Object.defineProperty(t,"EAnimationState",{enumerable:!0,get:function(){return ZC.EAnimationState}});var ng=cP();Object.defineProperty(t,"EAnimationStateTransition",{enumerable:!0,get:function(){return ng.EAnimationStateTransition}});var mh=cP();Object.defineProperty(t,"AnimationFiniteStateMachine",{enumerable:!0,get:function(){return mh.AnimationFiniteStateMachine}});var g0=cP();Object.defineProperty(t,"SeriesAnimationFiniteStateMachine",{enumerable:!0,get:function(){return g0.SeriesAnimationFiniteStateMachine}});var g2=lje();Object.defineProperty(t,"animateAny",{enumerable:!0,get:function(){return g2.animateAny}});var iM=jW();Object.defineProperty(t,"DoubleAnimator",{enumerable:!0,get:function(){return iM.DoubleAnimator}});var nM=ad();Object.defineProperty(t,"easing",{enumerable:!0,get:function(){return nM.easing}});var oM=ad();Object.defineProperty(t,"autoReverseEasing",{enumerable:!0,get:function(){return oM.autoReverseEasing}});var aM=ZV();Object.defineProperty(t,"GenericAnimation",{enumerable:!0,get:function(){return aM.GenericAnimation}});var v2=JV();Object.defineProperty(t,"NumberRangeAnimator",{enumerable:!0,get:function(){return v2.NumberRangeAnimator}});var Xc=sje();Object.defineProperty(t,"AnimationToken",{enumerable:!0,get:function(){return Xc.AnimationToken}});var sM=vm();Object.defineProperty(t,"libraryVersion",{enumerable:!0,get:function(){return sM.libraryVersion}});var lM=vm();Object.defineProperty(t,"checkBuildStamp",{enumerable:!0,get:function(){return lM.checkBuildStamp}});var tv=fo();Object.defineProperty(t,"DeletableEntity",{enumerable:!0,get:function(){return tv.DeletableEntity}});var on=Br();Object.defineProperty(t,"deleteSafe",{enumerable:!0,get:function(){return on.deleteSafe}});var JC=Sre();Object.defineProperty(t,"Dictionary",{enumerable:!0,get:function(){return JC.Dictionary}});var yc=ps();Object.defineProperty(t,"EventHandler",{enumerable:!0,get:function(){return yc.EventHandler}});var Ts=ps();Object.defineProperty(t,"receiveNextEvent",{enumerable:!0,get:function(){return Ts.receiveNextEvent}});var v0=OAt();Object.defineProperty(t,"GradientParams",{enumerable:!0,get:function(){return v0.GradientParams}});var og=ci();Object.defineProperty(t,"Guard",{enumerable:!0,get:function(){return og.Guard}});var uM=Tie();Object.defineProperty(t,"IncludedItems",{enumerable:!0,get:function(){return uM.IncludedItems}});var zn=DAt();Object.defineProperty(t,"List",{enumerable:!0,get:function(){return zn.List}});var QC=nFe();Object.defineProperty(t,"MouseManager",{enumerable:!0,get:function(){return QC.MouseManager}});var b_=di();Object.defineProperty(t,"NumberRange",{enumerable:!0,get:function(){return b_.NumberRange}});var eT=wre();Object.defineProperty(t,"NumberUtil",{enumerable:!0,get:function(){return eT.NumberUtil}});var S_=DP();Object.defineProperty(t,"ObservableArrayBase",{enumerable:!0,get:function(){return S_.ObservableArrayBase}});var tT=DP();Object.defineProperty(t,"ObservableArray",{enumerable:!0,get:function(){return tT.ObservableArray}});var Kc=uJ();Object.defineProperty(t,"EObservableArrayChangedAction",{enumerable:!0,get:function(){return Kc.EObservableArrayChangedAction}});var y0=uJ();Object.defineProperty(t,"ObservableArrayChangedArgs",{enumerable:!0,get:function(){return y0.ObservableArrayChangedArgs}});var __=sFe();Object.defineProperty(t,"OneTimePerformanceWarning",{enumerable:!0,get:function(){return __.OneTimePerformanceWarning}});var za=$i();Object.defineProperty(t,"Point",{enumerable:!0,get:function(){return za.Point}});var us=KP();Object.defineProperty(t,"PropertyChangedEventArgs",{enumerable:!0,get:function(){return us.PropertyChangedEventArgs}});var cM=Rn();Object.defineProperty(t,"Rect",{enumerable:!0,get:function(){return cM.Rect}});var dM=oFe();Object.defineProperty(t,"SimdHelper",{enumerable:!0,get:function(){return dM.SimdHelper}});var fM=QNe();Object.defineProperty(t,"localStorageApi",{enumerable:!0,get:function(){return fM.localStorageApi}});var Zo=t5();Object.defineProperty(t,"getUserCookie",{enumerable:!0,get:function(){return Zo.getUserCookie}});var rT=t5();Object.defineProperty(t,"shouldSendTelemetry",{enumerable:!0,get:function(){return rT.shouldSendTelemetry}});var Kl=t5();Object.defineProperty(t,"sendTelemetry",{enumerable:!0,get:function(){return Kl.sendTelemetry}});var y2=pa();Object.defineProperty(t,"Thickness",{enumerable:!0,get:function(){return y2.Thickness}});var iT=LD();Object.defineProperty(t,"EWebGLSupport",{enumerable:!0,get:function(){return iT.EWebGLSupport}});var m0=LD();Object.defineProperty(t,"WebGlHelper",{enumerable:!0,get:function(){return m0.WebGlHelper}});var b0=jv();Object.defineProperty(t,"EHorizontalAnchorPoint",{enumerable:!0,get:function(){return b0.EHorizontalAnchorPoint}});var nT=jv();Object.defineProperty(t,"EVerticalAnchorPoint",{enumerable:!0,get:function(){return nT.EVerticalAnchorPoint}});var S0=Gf();Object.defineProperty(t,"EAnimationType",{enumerable:!0,get:function(){return S0.EAnimationType}});var _0=II();Object.defineProperty(t,"EAnnotationClippingMode",{enumerable:!0,get:function(){return _0.EAnnotationClippingMode}});var mc=cFe();Object.defineProperty(t,"EAutoColorMode",{enumerable:!0,get:function(){return mc.EAutoColorMode}});var ag=tR();Object.defineProperty(t,"EAutoRange",{enumerable:!0,get:function(){return ag.EAutoRange}});var oT=od();Object.defineProperty(t,"EAxisAlignment",{enumerable:!0,get:function(){return oT.EAxisAlignment}});var m2=od();Object.defineProperty(t,"getIsHorizontal",{enumerable:!0,get:function(){return m2.getIsHorizontal}});var hM=od();Object.defineProperty(t,"getIsVertical",{enumerable:!0,get:function(){return hM.getIsVertical}});var b2=od();Object.defineProperty(t,"handleInvalidAxisAlignment",{enumerable:!0,get:function(){return b2.handleInvalidAxisAlignment}});var pM=Nj();Object.defineProperty(t,"EAxisPlaneDrawLabelsMode",{enumerable:!0,get:function(){return pM.EAxisPlaneDrawLabelsMode}});var gM=Nj();Object.defineProperty(t,"convert3DPlaneModeForLabels",{enumerable:!0,get:function(){return gM.convert3DPlaneModeForLabels}});var op=Nj();Object.defineProperty(t,"convert3DPlaneModeForTitles",{enumerable:!0,get:function(){return op.convert3DPlaneModeForTitles}});var Wi=a$();Object.defineProperty(t,"EAxisPlaneVisibilityMode",{enumerable:!0,get:function(){return Wi.EAxisPlaneVisibilityMode}});var aT=a$();Object.defineProperty(t,"convertAxisPlaneVisibilityMode",{enumerable:!0,get:function(){return aT.convertAxisPlaneVisibilityMode}});var Zc=ud();Object.defineProperty(t,"EAxisType",{enumerable:!0,get:function(){return Zc.EAxisType}});var P_=ga();Object.defineProperty(t,"EBaseType",{enumerable:!0,get:function(){return P_.EBaseType}});var S2=Lm();Object.defineProperty(t,"EExecuteOn",{enumerable:!0,get:function(){return S2.EExecuteOn}});var Fo=uR();Object.defineProperty(t,"EModifierMouseArgKey",{enumerable:!0,get:function(){return Fo.EModifierMouseArgKey}});var vM=Ho();Object.defineProperty(t,"EChart2DModifierType",{enumerable:!0,get:function(){return vM.EChart2DModifierType}});var C_=Ho();Object.defineProperty(t,"EChart3DModifierType",{enumerable:!0,get:function(){return C_.EChart3DModifierType}});var py=tFe();Object.defineProperty(t,"EColor",{enumerable:!0,get:function(){return py.EColor}});var _2=Vd();Object.defineProperty(t,"EColumnMode",{enumerable:!0,get:function(){return _2.EColumnMode}});var Ad=Vd();Object.defineProperty(t,"convertColumnMode",{enumerable:!0,get:function(){return Ad.convertColumnMode}});var sT=Vd();Object.defineProperty(t,"EColumnYMode",{enumerable:!0,get:function(){return sT.EColumnYMode}});var yM=Vd();Object.defineProperty(t,"convertYColumnMode",{enumerable:!0,get:function(){return yM.convertYColumnMode}});var mM=Ku();Object.defineProperty(t,"addCoord",{enumerable:!0,get:function(){return mM.addCoord}});var bM=Ku();Object.defineProperty(t,"subtractCoord",{enumerable:!0,get:function(){return bM.subtractCoord}});var P0=Ku();Object.defineProperty(t,"convertDataValueToAbsoluteCoordinate",{enumerable:!0,get:function(){return P0.convertDataValueToAbsoluteCoordinate}});var Od=Ku();Object.defineProperty(t,"convertPixelValueToAbsoluteCoordinate",{enumerable:!0,get:function(){return Od.convertPixelValueToAbsoluteCoordinate}});var SM=Ku();Object.defineProperty(t,"convertRelativeValueToAbsoluteCoordinate",{enumerable:!0,get:function(){return SM.convertRelativeValueToAbsoluteCoordinate}});var T_=Ku();Object.defineProperty(t,"convertToAbsoluteCoordinate",{enumerable:!0,get:function(){return T_.convertToAbsoluteCoordinate}});var ap=Ku();Object.defineProperty(t,"convertAbsoluteCoordinateToDataValue",{enumerable:!0,get:function(){return ap.convertAbsoluteCoordinateToDataValue}});var P2=Ku();Object.defineProperty(t,"convertAbsoluteCoordinateToPixelValue",{enumerable:!0,get:function(){return P2.convertAbsoluteCoordinateToPixelValue}});var C2=Ku();Object.defineProperty(t,"convertAbsoluteCoordinateToRelativeValue",{enumerable:!0,get:function(){return C2.convertAbsoluteCoordinateToRelativeValue}});var sg=Ku();Object.defineProperty(t,"convertFromAbsoluteCoordinate",{enumerable:!0,get:function(){return sg.convertFromAbsoluteCoordinate}});var _M=Ku();Object.defineProperty(t,"convertCoordinateMode",{enumerable:!0,get:function(){return _M.convertCoordinateMode}});var lT=Ku();Object.defineProperty(t,"convertToDataValue",{enumerable:!0,get:function(){return lT.convertToDataValue}});var T2=Ku();Object.defineProperty(t,"convertToPixelCoordinate",{enumerable:!0,get:function(){return T2.convertToPixelCoordinate}});var x2=Ku();Object.defineProperty(t,"convertToRelativeCoordinate",{enumerable:!0,get:function(){return x2.convertToRelativeCoordinate}});var E2=Ku();Object.defineProperty(t,"convertCoordinateFromDataValue",{enumerable:!0,get:function(){return E2.convertCoordinateFromDataValue}});var Rl=Ku();Object.defineProperty(t,"convertCoordinateFromPixelValue",{enumerable:!0,get:function(){return Rl.convertCoordinateFromPixelValue}});var bc=Ku();Object.defineProperty(t,"convertCoordinateFromRelativeValue",{enumerable:!0,get:function(){return bc.convertCoordinateFromRelativeValue}});var w2=Oie();Object.defineProperty(t,"ECursorStyle",{enumerable:!0,get:function(){return w2.ECursorStyle}});var PM=Mm();Object.defineProperty(t,"EDataFilterType",{enumerable:!0,get:function(){return PM.EDataFilterType}});var gy=Ac();Object.defineProperty(t,"EDataLabelProviderType",{enumerable:!0,get:function(){return gy.EDataLabelProviderType}});var vy=Lie();Object.defineProperty(t,"EDataLabelSkipMode",{enumerable:!0,get:function(){return vy.EDataLabelSkipMode}});var CM=Em();Object.defineProperty(t,"EDataPointWidthMode",{enumerable:!0,get:function(){return CM.EDataPointWidthMode}});var A2=QD();Object.defineProperty(t,"EDefaultRenderLayer",{enumerable:!0,get:function(){return A2.EDefaultRenderLayer}});var yy=Die();Object.defineProperty(t,"EDragMode",{enumerable:!0,get:function(){return yy.EDragMode}});var my=QV();Object.defineProperty(t,"EErrorDirection",{enumerable:!0,get:function(){return my.EErrorDirection}});var TM=zW();Object.defineProperty(t,"EErrorMode",{enumerable:!0,get:function(){return TM.EErrorMode}});var x_=Pre();Object.defineProperty(t,"EUseWasmSimd",{enumerable:!0,get:function(){return x_.EUseWasmSimd}});var uT=sne();Object.defineProperty(t,"EColorPickMode",{enumerable:!0,get:function(){return uT.EColorPickMode}});var E_=kVe();Object.defineProperty(t,"EHeightSeriesMode",{enumerable:!0,get:function(){return E_.EHeightSeriesMode}});var C0=nje();Object.defineProperty(t,"EHoverMode",{enumerable:!0,get:function(){return C0.EHoverMode}});var xM=kI();Object.defineProperty(t,"ELabelAlignment",{enumerable:!0,get:function(){return xM.ELabelAlignment}});var EM=Gy();Object.defineProperty(t,"ELabelPlacement",{enumerable:!0,get:function(){return EM.ELabelPlacement}});var O2=Gy();Object.defineProperty(t,"EHorizontalAlignment",{enumerable:!0,get:function(){return O2.EHorizontalAlignment}});var wM=Gy();Object.defineProperty(t,"EVerticalAlignment",{enumerable:!0,get:function(){return wM.EVerticalAlignment}});var by=Gy();Object.defineProperty(t,"EAngularAxisLabelPlacement",{enumerable:!0,get:function(){return by.EAngularAxisLabelPlacement}});var cT=Gy();Object.defineProperty(t,"ERadialAxisLabelPlacement",{enumerable:!0,get:function(){return cT.ERadialAxisLabelPlacement}});var D2=sR();Object.defineProperty(t,"ELabelProviderType",{enumerable:!0,get:function(){return D2.ELabelProviderType}});var w_=zS();Object.defineProperty(t,"ELayoutManagerType",{enumerable:!0,get:function(){return w_.ELayoutManagerType}});var A_=$d();Object.defineProperty(t,"ELayoutStrategyType",{enumerable:!0,get:function(){return A_.ELayoutStrategyType}});var O_=$f();Object.defineProperty(t,"EModifierType",{enumerable:!0,get:function(){return O_.EModifierType}});var AM=GS();Object.defineProperty(t,"EMousePosition",{enumerable:!0,get:function(){return AM.EMousePosition}});var Sy=ZL();Object.defineProperty(t,"isTypedArray",{enumerable:!0,get:function(){return Sy.isTypedArray}});var R2=ZL();Object.defineProperty(t,"isNumberArray",{enumerable:!0,get:function(){return R2.isNumberArray}});var OM=ZL();Object.defineProperty(t,"subArray",{enumerable:!0,get:function(){return OM.subArray}});var DM=Fg();Object.defineProperty(t,"ENumericFormat",{enumerable:!0,get:function(){return DM.ENumericFormat}});var RM=OFe();Object.defineProperty(t,"OrderedRenderable",{enumerable:!0,get:function(){return RM.OrderedRenderable}});var MM=JD();Object.defineProperty(t,"EPaletteProviderType",{enumerable:!0,get:function(){return MM.EPaletteProviderType}});var dT=tne();Object.defineProperty(t,"EPointMarker3DType",{enumerable:!0,get:function(){return dT.EPointMarker3DType}});var LM=Ng();Object.defineProperty(t,"EPointMarkerType",{enumerable:!0,get:function(){return LM.EPointMarkerType}});var kM=YFe();Object.defineProperty(t,"EStrokeLineJoin",{enumerable:!0,get:function(){return kM.EStrokeLineJoin}});var D_=RAt();Object.defineProperty(t,"ERenderLayer",{enumerable:!0,get:function(){return D_.ERenderLayer}});var M2=Im();Object.defineProperty(t,"ESceneEntityType",{enumerable:!0,get:function(){return M2.ESceneEntityType}});var L2=WS();Object.defineProperty(t,"ESciChartSurfaceType",{enumerable:!0,get:function(){return L2.ESciChartSurfaceType}});var fT=ym();Object.defineProperty(t,"ESearchMode",{enumerable:!0,get:function(){return fT.ESearchMode}});var hT=ym();Object.defineProperty(t,"convertSearchMode",{enumerable:!0,get:function(){return hT.convertSearchMode}});var R_=hn();Object.defineProperty(t,"ESeriesType",{enumerable:!0,get:function(){return R_.ESeriesType}});var pT=WW();Object.defineProperty(t,"EShaderEffectType",{enumerable:!0,get:function(){return pT.EShaderEffectType}});var IM=Ig();Object.defineProperty(t,"Size",{enumerable:!0,get:function(){return IM.Size}});var gT=rie();Object.defineProperty(t,"ESubChartClippingMode",{enumerable:!0,get:function(){return gT.ESubChartClippingMode}});var lg=kW();Object.defineProperty(t,"ESubSurfacePositionCoordinateMode",{enumerable:!0,get:function(){return lg.ESubSurfacePositionCoordinateMode}});var ug=vs();Object.defineProperty(t,"ESurfaceType",{enumerable:!0,get:function(){return ug.ESurfaceType}});var cg=Tc();Object.defineProperty(t,"EHorizontalTextPosition",{enumerable:!0,get:function(){return cg.EHorizontalTextPosition}});var T0=Tc();Object.defineProperty(t,"EVerticalTextPosition",{enumerable:!0,get:function(){return T0.EVerticalTextPosition}});var x0=Tc();Object.defineProperty(t,"EMultiLineAlignment",{enumerable:!0,get:function(){return x0.EMultiLineAlignment}});var dg=Tc();Object.defineProperty(t,"convertMultiLineAlignment",{enumerable:!0,get:function(){return dg.convertMultiLineAlignment}});var k2=eI();Object.defineProperty(t,"ETextAlignment",{enumerable:!0,get:function(){return k2.ETextAlignment}});var NM=eI();Object.defineProperty(t,"ETitlePosition",{enumerable:!0,get:function(){return NM.ETitlePosition}});var rv=dj();Object.defineProperty(t,"E3DLabelOrientationMode",{enumerable:!0,get:function(){return rv.E3DLabelOrientationMode}});var FM=dj();Object.defineProperty(t,"E3DTitleRotationMode",{enumerable:!0,get:function(){return FM.E3DTitleRotationMode}});var vT=dj();Object.defineProperty(t,"convert3DLabelOrientationMode",{enumerable:!0,get:function(){return vT.convert3DLabelOrientationMode}});var M_=dj();Object.defineProperty(t,"convert3DTitleRotationMode",{enumerable:!0,get:function(){return M_.convert3DTitleRotationMode}});var BM=OI();Object.defineProperty(t,"EThemeProviderType",{enumerable:!0,get:function(){return BM.EThemeProviderType}});var I2=ZNe();Object.defineProperty(t,"EColorMapMode",{enumerable:!0,get:function(){return I2.EColorMapMode}});var _y=VI();Object.defineProperty(t,"ETriangleSeriesDrawMode",{enumerable:!0,get:function(){return _y.ETriangleSeriesDrawMode}});var L_=Yo();Object.defineProperty(t,"EValueName",{enumerable:!0,get:function(){return L_.EValueName}});var jM=Yo();Object.defineProperty(t,"generateValueNamesForDataSeries",{enumerable:!0,get:function(){return jM.generateValueNamesForDataSeries}});var Py=Tre();Object.defineProperty(t,"EWatermarkPosition",{enumerable:!0,get:function(){return Py.EWatermarkPosition}});var qu=pl();Object.defineProperty(t,"EXyDirection",{enumerable:!0,get:function(){return qu.EXyDirection}});var E0=eC();Object.defineProperty(t,"EYRangeMode",{enumerable:!0,get:function(){return E0.EYRangeMode}});var k_=xm();Object.defineProperty(t,"EZoomState",{enumerable:!0,get:function(){return k_.EZoomState}});var VM=Th();Object.defineProperty(t,"getUniqueValues",{enumerable:!0,get:function(){return VM.getUniqueValues}});var N2=Th();Object.defineProperty(t,"countUnique",{enumerable:!0,get:function(){return N2.countUnique}});var I_=Th();Object.defineProperty(t,"areArraysEqual",{enumerable:!0,get:function(){return I_.areArraysEqual}});var T=Th();Object.defineProperty(t,"arrayRemove",{enumerable:!0,get:function(){return T.arrayRemove}});var w=Th();Object.defineProperty(t,"isArraySorted",{enumerable:!0,get:function(){return w.isArraySorted}});var N=Th();Object.defineProperty(t,"makeIncArray",{enumerable:!0,get:function(){return N.makeIncArray}});var q=Th();Object.defineProperty(t,"appendRangeFifo",{enumerable:!0,get:function(){return q.appendRangeFifo}});var ne=DTe();Object.defineProperty(t,"calcAverageForDoubleVector",{enumerable:!0,get:function(){return ne.calcAverageForDoubleVector}});var ue=DTe();Object.defineProperty(t,"calcAverageForArray",{enumerable:!0,get:function(){return ue.calcAverageForArray}});var Ie=Rf();Object.defineProperty(t,"SIZEOF_NUMBER",{enumerable:!0,get:function(){return Ie.SIZEOF_NUMBER}});var ot=Rf();Object.defineProperty(t,"SIZEOF_FLOAT32",{enumerable:!0,get:function(){return ot.SIZEOF_FLOAT32}});var Et=Rf();Object.defineProperty(t,"insertDoubleVectorFromJsArray",{enumerable:!0,get:function(){return Et.insertDoubleVectorFromJsArray}});var tr=Rf();Object.defineProperty(t,"memCopyFloat32",{enumerable:!0,get:function(){return tr.memCopyFloat32}});var yr=Rf();Object.defineProperty(t,"appendDoubleVectorFromJsArray",{enumerable:!0,get:function(){return yr.appendDoubleVectorFromJsArray}});var Pr=Rf();Object.defineProperty(t,"appendDoubleVectorFromBuffer",{enumerable:!0,get:function(){return Pr.appendDoubleVectorFromBuffer}});var ir=Ju();Object.defineProperty(t,"uintArgbColorLerp24bit",{enumerable:!0,get:function(){return ir.uintArgbColorLerp24bit}});var ar=Ju();Object.defineProperty(t,"uintArgbColorLerp",{enumerable:!0,get:function(){return ar.uintArgbColorLerp}});var li=Ju();Object.defineProperty(t,"linearColorMapLerp",{enumerable:!0,get:function(){return li.linearColorMapLerp}});var Ii=Ju();Object.defineProperty(t,"uintArgbColorToAbgr",{enumerable:!0,get:function(){return Ii.uintArgbColorToAbgr}});var Jo=Ju();Object.defineProperty(t,"uintArgbColorMultiplyOpacity",{enumerable:!0,get:function(){return Jo.uintArgbColorMultiplyOpacity}});var Wt=Ju();Object.defineProperty(t,"uintArgbColorOverrideOpacity",{enumerable:!0,get:function(){return Wt.uintArgbColorOverrideOpacity}});var It=Ju();Object.defineProperty(t,"uintArgbColorIsTransparent",{enumerable:!0,get:function(){return It.uintArgbColorIsTransparent}});var Qt=Ju();Object.defineProperty(t,"applyOpacityToHtmlColor",{enumerable:!0,get:function(){return Qt.applyOpacityToHtmlColor}});var Sr=MTe();Object.defineProperty(t,"convertColor",{enumerable:!0,get:function(){return Sr.convertColor}});var wi=MTe();Object.defineProperty(t,"convertRgbToHexColor",{enumerable:!0,get:function(){return wi.convertRgbToHexColor}});var Co=MAt();Object.defineProperty(t,"convertToPixel",{enumerable:!0,get:function(){return Co.convertToPixel}});var gi=qV();Object.defineProperty(t,"copyDoubleVector",{enumerable:!0,get:function(){return gi.copyDoubleVector}});var Pn=Tf();Object.defineProperty(t,"formatUnixDateToHumanString",{enumerable:!0,get:function(){return Pn.formatUnixDateToHumanString}});var Kn=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringDDMMYY",{enumerable:!0,get:function(){return Kn.formatUnixDateToHumanStringDDMMYY}});var To=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringDDMMHHMM",{enumerable:!0,get:function(){return To.formatUnixDateToHumanStringDDMMHHMM}});var fg=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringDDMM",{enumerable:!0,get:function(){return fg.formatUnixDateToHumanStringDDMM}});var F2=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringHHMMSS",{enumerable:!0,get:function(){return F2.formatUnixDateToHumanStringHHMMSS}});var _G=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringSSms",{enumerable:!0,get:function(){return _G.formatUnixDateToHumanStringSSms}});var PG=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringHHMM",{enumerable:!0,get:function(){return PG.formatUnixDateToHumanStringHHMM}});var CG=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringMMMDD",{enumerable:!0,get:function(){return CG.formatUnixDateToHumanStringMMMDD}});var TG=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringMMM",{enumerable:!0,get:function(){return TG.formatUnixDateToHumanStringMMM}});var xG=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringDD",{enumerable:!0,get:function(){return xG.formatUnixDateToHumanStringDD}});var B=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringYYYY",{enumerable:!0,get:function(){return B.formatUnixDateToHumanStringYYYY}});var K=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringSSus",{enumerable:!0,get:function(){return K.formatUnixDateToHumanStringSSus}});var se=Tf();Object.defineProperty(t,"formatUnixDateToHumanStringSSns",{enumerable:!0,get:function(){return se.formatUnixDateToHumanStringSSns}});var De=LAt();Object.defineProperty(t,"logDoubleVector",{enumerable:!0,get:function(){return De.logDoubleVector}});var Je=Vf();Object.defineProperty(t,"getFontString",{enumerable:!0,get:function(){return Je.getFontString}});var ut=Vf();Object.defineProperty(t,"getDefaultFontName",{enumerable:!0,get:function(){return ut.getDefaultFontName}});var bt=Vf();Object.defineProperty(t,"getFontFamily",{enumerable:!0,get:function(){return bt.getFontFamily}});var Rt=GFe();Object.defineProperty(t,"geometryHelpers",{enumerable:!0,get:function(){return Rt.geometryHelpers}});var Xt=hl();Object.defineProperty(t,"generateGuid",{enumerable:!0,get:function(){return Xt.generateGuid}});var xr=hl();Object.defineProperty(t,"base64Id",{enumerable:!0,get:function(){return xr.base64Id}});var wr=kAt();Object.defineProperty(t,"hasAllProperties",{enumerable:!0,get:function(){return wr.hasAllProperties}});var Nr=CFe();Object.defineProperty(t,"hashUtils",{enumerable:!0,get:function(){return Nr.hashUtils}});var ti=s$();Object.defineProperty(t,"HEIGHT_SERIES_MAX_TEXTURE_SIZE",{enumerable:!0,get:function(){return ti.HEIGHT_SERIES_MAX_TEXTURE_SIZE}});var mi=s$();Object.defineProperty(t,"validateColorStops",{enumerable:!0,get:function(){return mi.validateColorStops}});var Gi=fJ();Object.defineProperty(t,"htmlToElement",{enumerable:!0,get:function(){return Gi.htmlToElement}});var Vn=fJ();Object.defineProperty(t,"stringOccurrences",{enumerable:!0,get:function(){return Vn.stringOccurrences}});var Yi=FTe();Object.defineProperty(t,"createImageAsync",{enumerable:!0,get:function(){return Yi.createImageAsync}});var no=FTe();Object.defineProperty(t,"createImagesArrayAsync",{enumerable:!0,get:function(){return no.createImagesArrayAsync}});var go=kp();Object.defineProperty(t,"isRealNumber",{enumerable:!0,get:function(){return go.isRealNumber}});var vf=kh();Object.defineProperty(t,"Logger",{enumerable:!0,get:function(){return vf.Logger}});var Jc=Ij();Object.defineProperty(t,"getNoisySinewave",{enumerable:!0,get:function(){return Jc.getNoisySinewave}});var yf=Ij();Object.defineProperty(t,"fillNoisySinewave",{enumerable:!0,get:function(){return yf.fillNoisySinewave}});var ul=Ij();Object.defineProperty(t,"logToBase",{enumerable:!0,get:function(){return ul.logToBase}});var sp=Are();Object.defineProperty(t,"memoize",{enumerable:!0,get:function(){return sp.memoize}});var iv=gm();Object.defineProperty(t,"ObjectRegistry",{enumerable:!0,get:function(){return iv.ObjectRegistry}});var cH=gm();Object.defineProperty(t,"MemoryUsageHelper",{enumerable:!0,get:function(){return cH.MemoryUsageHelper}});var O4e=Du();Object.defineProperty(t,"formatNumber2Digits",{enumerable:!0,get:function(){return O4e.formatNumber2Digits}});var D4e=Du();Object.defineProperty(t,"numericHashCode",{enumerable:!0,get:function(){return D4e.numericHashCode}});var R4e=Du();Object.defineProperty(t,"formatNumber",{enumerable:!0,get:function(){return R4e.formatNumber}});var M4e=Du();Object.defineProperty(t,"toSuperScript",{enumerable:!0,get:function(){return M4e.toSuperScript}});var L4e=Du();Object.defineProperty(t,"toScientific",{enumerable:!0,get:function(){return L4e.toScientific}});var k4e=Du();Object.defineProperty(t,"toEngineering",{enumerable:!0,get:function(){return k4e.toEngineering}});var I4e=Du();Object.defineProperty(t,"checkIsNaN",{enumerable:!0,get:function(){return I4e.checkIsNaN}});var N4e=Ti();Object.defineProperty(t,"parseColorToHexStringArgb",{enumerable:!0,get:function(){return N4e.parseColorToHexStringArgb}});var F4e=Ti();Object.defineProperty(t,"parseColorToHexStringAbgr",{enumerable:!0,get:function(){return F4e.parseColorToHexStringAbgr}});var B4e=Ti();Object.defineProperty(t,"parseColorToUIntArgb",{enumerable:!0,get:function(){return B4e.parseColorToUIntArgb}});var j4e=Ti();Object.defineProperty(t,"parseColorToUIntAbgr",{enumerable:!0,get:function(){return j4e.parseColorToUIntAbgr}});var V4e=Ti();Object.defineProperty(t,"toHex",{enumerable:!0,get:function(){return V4e.toHex}});var H4e=Ti();Object.defineProperty(t,"parseColorToTArgb",{enumerable:!0,get:function(){return H4e.parseColorToTArgb}});var U4e=Ti();Object.defineProperty(t,"parseArgbToHtmlColor",{enumerable:!0,get:function(){return U4e.parseArgbToHtmlColor}});var z4e=Ti();Object.defineProperty(t,"parseTArgbToHtmlColor",{enumerable:!0,get:function(){return z4e.parseTArgbToHtmlColor}});var $4e=La();Object.defineProperty(t,"EPerformanceMarkType",{enumerable:!0,get:function(){return $4e.EPerformanceMarkType}});var W4e=La();Object.defineProperty(t,"EPerformanceDebugLevel",{enumerable:!0,get:function(){return W4e.EPerformanceDebugLevel}});var G4e=La();Object.defineProperty(t,"PerformanceDebugHelper",{enumerable:!0,get:function(){return G4e.PerformanceDebugHelper}});var Y4e=La();Object.defineProperty(t,"runAfterFramePaint",{enumerable:!0,get:function(){return Y4e.runAfterFramePaint}});var q4e=Eo();Object.defineProperty(t,"calcDistanceFromLine",{enumerable:!0,get:function(){return q4e.calcDistanceFromLine}});var X4e=Eo();Object.defineProperty(t,"calcCrossProduct",{enumerable:!0,get:function(){return X4e.calcCrossProduct}});var K4e=Eo();Object.defineProperty(t,"calcDistance",{enumerable:!0,get:function(){return K4e.calcDistance}});var Z4e=Eo();Object.defineProperty(t,"testIsInBounds",{enumerable:!0,get:function(){return Z4e.testIsInBounds}});var J4e=Eo();Object.defineProperty(t,"calcAnnotationBordersForAxisMarker",{enumerable:!0,get:function(){return J4e.calcAnnotationBordersForAxisMarker}});var Q4e=Eo();Object.defineProperty(t,"testIsInXBounds",{enumerable:!0,get:function(){return Q4e.testIsInXBounds}});var eUe=Eo();Object.defineProperty(t,"testIsInInterval",{enumerable:!0,get:function(){return eUe.testIsInInterval}});var tUe=Eo();Object.defineProperty(t,"calcDotProduct",{enumerable:!0,get:function(){return tUe.calcDotProduct}});var rUe=Eo();Object.defineProperty(t,"calcDistanceFromLineSegment",{enumerable:!0,get:function(){return rUe.calcDistanceFromLineSegment}});var iUe=Eo();Object.defineProperty(t,"testPointInTriangle",{enumerable:!0,get:function(){return iUe.testPointInTriangle}});var nUe=IVe();Object.defineProperty(t,"getRandomInRange",{enumerable:!0,get:function(){return nUe.getRandomInRange}});var oUe=VTe();Object.defineProperty(t,"getStocksDataFactory",{enumerable:!0,get:function(){return oUe.getStocksDataFactory}});var aUe=VTe();Object.defineProperty(t,"getNextRandomPriceBarFactory",{enumerable:!0,get:function(){return aUe.getNextRandomPriceBarFactory}});var sUe=IAt();Object.defineProperty(t,"getAttributeFromString",{enumerable:!0,get:function(){return sUe.getAttributeFromString}});var lUe=id();Object.defineProperty(t,"wrapNativeText",{enumerable:!0,get:function(){return lUe.wrapNativeText}});var uUe=id();Object.defineProperty(t,"convertToNativeLineSpacing",{enumerable:!0,get:function(){return uUe.convertToNativeLineSpacing}});var cUe=id();Object.defineProperty(t,"getNativeTextSize",{enumerable:!0,get:function(){return cUe.getNativeTextSize}});var dUe=id();Object.defineProperty(t,"getFirstLineHeightToBaseline",{enumerable:!0,get:function(){return dUe.getFirstLineHeightToBaseline}});var fUe=id();Object.defineProperty(t,"getTextHeightToBaseline",{enumerable:!0,get:function(){return fUe.getTextHeightToBaseline}});var hUe=id();Object.defineProperty(t,"getMultilineTextHeight",{enumerable:!0,get:function(){return hUe.getMultilineTextHeight}});var pUe=id();Object.defineProperty(t,"getNativeTextPosition",{enumerable:!0,get:function(){return pUe.getNativeTextPosition}});var gUe=i5();Object.defineProperty(t,"ESize",{enumerable:!0,get:function(){return gUe.ESize}});var vUe=i5();Object.defineProperty(t,"ECoord",{enumerable:!0,get:function(){return vUe.ECoord}});var yUe=i5();Object.defineProperty(t,"EShift",{enumerable:!0,get:function(){return yUe.EShift}});var mUe=An();Object.defineProperty(t,"translateFromCanvasToSeriesViewRect",{enumerable:!0,get:function(){return mUe.translateFromCanvasToSeriesViewRect}});var bUe=An();Object.defineProperty(t,"translateFromSeriesViewRectToCanvas",{enumerable:!0,get:function(){return bUe.translateFromSeriesViewRectToCanvas}});var SUe=An();Object.defineProperty(t,"translateFromCanvasToSeriesViewRectX",{enumerable:!0,get:function(){return SUe.translateFromCanvasToSeriesViewRectX}});var _Ue=An();Object.defineProperty(t,"translateFromCanvasToSeriesViewRectY",{enumerable:!0,get:function(){return _Ue.translateFromCanvasToSeriesViewRectY}});var PUe=An();Object.defineProperty(t,"translateFromSeriesViewRectToCanvasX",{enumerable:!0,get:function(){return PUe.translateFromSeriesViewRectToCanvasX}});var CUe=An();Object.defineProperty(t,"translateFromSeriesViewRectToCanvasY",{enumerable:!0,get:function(){return CUe.translateFromSeriesViewRectToCanvasY}});var TUe=An();Object.defineProperty(t,"translateToScaled",{enumerable:!0,get:function(){return TUe.translateToScaled}});var xUe=An();Object.defineProperty(t,"translateToNotScaled",{enumerable:!0,get:function(){return xUe.translateToNotScaled}});var EUe=An();Object.defineProperty(t,"translateToScaledRect",{enumerable:!0,get:function(){return EUe.translateToScaledRect}});var wUe=An();Object.defineProperty(t,"translateToNotScaledRect",{enumerable:!0,get:function(){return wUe.translateToNotScaledRect}});var AUe=An();Object.defineProperty(t,"translateDataValueRectToAbsolute",{enumerable:!0,get:function(){return AUe.translateDataValueRectToAbsolute}});var OUe=X3();Object.defineProperty(t,"updateTsrVector4",{enumerable:!0,get:function(){return OUe.updateTsrVector4}});var DUe=X3();Object.defineProperty(t,"fromTsrVector4",{enumerable:!0,get:function(){return DUe.fromTsrVector4}});var RUe=bo();Object.defineProperty(t,"vectorToArray",{enumerable:!0,get:function(){return RUe.vectorToArray}});var MUe=bo();Object.defineProperty(t,"vectorToArrayViewF64",{enumerable:!0,get:function(){return MUe.vectorToArrayViewF64}});var LUe=bo();Object.defineProperty(t,"vectorToArrayViewF32",{enumerable:!0,get:function(){return LUe.vectorToArrayViewF32}});var kUe=bo();Object.defineProperty(t,"vectorToArrayViewUi32",{enumerable:!0,get:function(){return kUe.vectorToArrayViewUi32}});var IUe=bo();Object.defineProperty(t,"vectorToArrayViewI32",{enumerable:!0,get:function(){return IUe.vectorToArrayViewI32}});var NUe=Bre();Object.defineProperty(t,"watermarkHelpers",{enumerable:!0,get:function(){return NUe.watermarkHelpers}});var FUe=AVe();Object.defineProperty(t,"zeroArray2D",{enumerable:!0,get:function(){return FUe.zeroArray2D}})})(yq)),yq}var Gt=qS();class NAt{constructor(e){this.brokerUrl=e}setupFrontendLicense(e,i){console.log("Setup license"),Gt.SciChartSurface.setRuntimeLicenseKey(e),Gt.SciChartSurface.setLicenseCallback(n=>{const r=new URLSearchParams(n).get("challenge");return this.getFrontendLicense(r,i).then(o=>o.json()).then(o=>{const a=o.v1.data;return new Response(a,{status:200,headers:{"content-type":"text/plain"}})})})}async getFrontendLicense(e,i){return await fetch(`${this.brokerUrl}/v1/GetFrontendSettings`,{method:"POST",headers:{"content-type":"application/json","x-authorization":`Bearer ${i}`},body:JSON.stringify({v1:{data:e}})})}}function FAt(t){var we;const e=qt.c(89),[i,n]=J.useState("");let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=[],e[0]=r):r=e[0];const[o,a]=J.useState(r),[s,l]=J.useState(""),{getDirectoryContents:u}=B$(),{fileTree:c,isLoading:d,isFolderExpanded:f,isFolderLoading:h,toggleFolder:p}=CQ();let g;e[1]!==i?(g=i.trim(),e[1]=i,e[2]=g):g=e[2];const v=g,y=v?`${s}/${v}.dashboard.json`:"";let m;e[3]!==y||e[4]!==t||e[5]!==v?(m=()=>{v&&t.onCreate(y)},e[3]=y,e[4]=t,e[5]=v,e[6]=m):m=e[6];const b=m;let S;e[7]!==b||e[8]!==t||e[9]!==v?(S=Te=>{Te.key==="Enter"&&v?b():Te.key==="Escape"&&t.onClose()},e[7]=b,e[8]=t,e[9]=v,e[10]=S):S=e[10];const _=S;let C,P;e[11]!==u||e[12]!==s?(C=()=>void u(s).then(a),P=[u,s],e[11]=u,e[12]=s,e[13]=C,e[14]=P):(C=e[13],P=e[14]),J.useEffect(C,P);let x;if(e[15]!==y||e[16]!==o){let Te;e[18]!==y?(Te=ke=>ke.path===y,e[18]=y,e[19]=Te):Te=e[19],x=o.some(Te),e[15]=y,e[16]=o,e[17]=x}else x=e[17];const E=x;let A,R,M,D,F,I,V,z,G,H,U;if(e[20]!==y||e[21]!==c||e[22]!==_||e[23]!==f||e[24]!==h||e[25]!==d||e[26]!==i||e[27]!==t.onClose||e[28]!==t.title||e[29]!==s||e[30]!==p){const Te=(fe,me)=>{var it;if(fe.type==="file"&&fe.fileType!==Ef.DASHBOARD)return null;const Ce=fe.type==="folder",Ue=Ce&&f(fe.id),Qe=Ce?fe.path===s:fe.path===y;return L.jsxs("div",{className:"text-muted-foreground",children:[L.jsx(Zwe,{node:fe,depth:me,isExpanded:Ue,isActive:Qe,isLoading:h(fe.path),onToggle:()=>{p(fe.id),l(fe.path)},onSelect:()=>{fe.type==="file"&&(n(fe.name.replace(".dashboard.json","")),l(fe.path.split("/").slice(0,-1).join("/")))}}),Ue&&((it=fe.children)==null?void 0:it.map(xt=>Te(xt,me+1)))]},fe.id)};A=yI,I=!0,V=t.onClose,z="md",D="p-5";const ke=t.title??"New Dashboard";e[42]!==ke?(F=L.jsx("h3",{className:"text-sm font-medium mb-4",children:ke}),e[42]=ke,e[43]=F):F=e[43],R="space-y-4";let $e;e[44]===Symbol.for("react.memo_cache_sentinel")?($e=L.jsx("label",{className:"block text-xs text-muted-foreground mb-1",children:"Name"}),e[44]=$e):$e=e[44];let Ne;e[45]===Symbol.for("react.memo_cache_sentinel")?(Ne=fe=>n(fe.target.value),e[45]=Ne):Ne=e[45];let ve;e[46]!==_||e[47]!==i?(ve=L.jsx("input",{autoFocus:!0,type:"text",value:i,onChange:Ne,onKeyDown:_,placeholder:"My Dashboard",className:"flex-1 min-w-0 px-2 py-1.5 text-sm bg-transparent focus:outline-none disabled:opacity-50 disabled:cursor-not-allowed"}),e[46]=_,e[47]=i,e[48]=ve):ve=e[48];let pe;e[49]===Symbol.for("react.memo_cache_sentinel")?(pe=L.jsx("span",{className:"pr-2 text-sm text-muted-foreground select-none shrink-0",children:".dashboard.json"}),e[49]=pe):pe=e[49],e[50]!==ve?(M=L.jsxs("div",{children:[$e,L.jsxs("div",{className:"flex items-center rounded border border-border bg-background focus-within:ring-1 focus-within:ring-primary",children:[ve,pe]})]}),e[50]=ve,e[51]=M):M=e[51],e[52]===Symbol.for("react.memo_cache_sentinel")?(U=L.jsx("label",{className:"block text-xs text-muted-foreground mb-1",children:"Save location"}),e[52]=U):U=e[52],G="rounded border border-border bg-background overflow-y-auto max-h-48 [&_div]:!text-foreground",H=d||!c?L.jsx("div",{className:"p-3 text-xs text-muted-foreground",children:"Loading..."}):L.jsx("div",{className:"py-1",children:(we=c.children)==null?void 0:we.map(fe=>Te(fe,0))}),e[20]=y,e[21]=c,e[22]=_,e[23]=f,e[24]=h,e[25]=d,e[26]=i,e[27]=t.onClose,e[28]=t.title,e[29]=s,e[30]=p,e[31]=A,e[32]=R,e[33]=M,e[34]=D,e[35]=F,e[36]=I,e[37]=V,e[38]=z,e[39]=G,e[40]=H,e[41]=U}else A=e[31],R=e[32],M=e[33],D=e[34],F=e[35],I=e[36],V=e[37],z=e[38],G=e[39],H=e[40],U=e[41];let k;e[53]!==G||e[54]!==H?(k=L.jsx("div",{className:G,children:H}),e[53]=G,e[54]=H,e[55]=k):k=e[55];let X;e[56]!==k||e[57]!==U?(X=L.jsxs("div",{children:[U,k]}),e[56]=k,e[57]=U,e[58]=X):X=e[58];let W;e[59]!==R||e[60]!==M||e[61]!==X?(W=L.jsxs("div",{className:R,children:[M,X]}),e[59]=R,e[60]=M,e[61]=X,e[62]=W):W=e[62];let Y;e[63]!==E?(Y=E&&L.jsx("p",{className:"text-xs text-red-500 mt-2",children:"A dashboard with this name already exists."}),e[63]=E,e[64]=Y):Y=e[64];let te;e[65]!==t.onClose?(te=L.jsx(Za,{type:fn.PRIMARY,size:_a.SM,label:"Cancel",onClick:t.onClose}),e[65]=t.onClose,e[66]=te):te=e[66];const oe=E?fn.DESTRUCTIVE:fn.SUCCESS,de=t.isSaving?t.savingLabel:E?"Overwrite":t.confirmLabel;let ge;e[67]!==b||e[68]!==oe||e[69]!==de?(ge=L.jsx(Za,{type:oe,size:_a.SM,label:de,onClick:b}),e[67]=b,e[68]=oe,e[69]=de,e[70]=ge):ge=e[70];let Ee;e[71]!==te||e[72]!==ge?(Ee=L.jsxs("div",{className:"flex justify-end gap-2 mt-4",children:[te,ge]}),e[71]=te,e[72]=ge,e[73]=Ee):Ee=e[73];let Re;e[74]!==y?(Re=y&&L.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:y}),e[74]=y,e[75]=Re):Re=e[75];let Ae;e[76]!==D||e[77]!==F||e[78]!==W||e[79]!==Y||e[80]!==Ee||e[81]!==Re?(Ae=L.jsxs("div",{className:D,children:[F,W,Y,Ee,Re]}),e[76]=D,e[77]=F,e[78]=W,e[79]=Y,e[80]=Ee,e[81]=Re,e[82]=Ae):Ae=e[82];let Pe;return e[83]!==A||e[84]!==I||e[85]!==V||e[86]!==z||e[87]!==Ae?(Pe=L.jsx(A,{show:I,onClose:V,size:z,children:Ae}),e[83]=A,e[84]=I,e[85]=V,e[86]=z,e[87]=Ae,e[88]=Pe):Pe=e[88],Pe}var C7={},EO={},wO={},zTe;function lne(){if(zTe)return wO;zTe=1,Object.defineProperty(wO,"__esModule",{value:!0}),wO.fallbackWrapperStyle=wO.DefaultFallback=void 0;const t=MP(),e=ld(),i=qS(),n=()=>{const r=(0,e.useRef)(null);return(0,e.useEffect)(()=>{const o=r.current,a=new i.DefaultSciChartLoader,s=a.addChartLoader(o,i.SciChartSurfaceBase.DEFAULT_THEME);return()=>{o&&a.removeChartLoader(o,s)}},[]),(0,t.jsx)("div",{ref:r,style:{position:"absolute",height:"100%",width:"100%",top:0,left:0,textAlign:"center",background:i.SciChartSurfaceBase.DEFAULT_THEME.sciChartBackground}})};return wO.DefaultFallback=n,wO.fallbackWrapperStyle={position:"absolute",height:"100%",width:"100%",top:0,left:0,zIndex:12},wO}var GB={},YB={},$Te;function une(){if($Te)return YB;$Te=1,Object.defineProperty(YB,"__esModule",{value:!0}),YB.SciChartGroupContext=void 0;const t=ld();return YB.SciChartGroupContext=(0,t.createContext)(void 0),YB}var WTe;function NVe(){if(WTe)return GB;WTe=1,Object.defineProperty(GB,"__esModule",{value:!0}),GB.SciChartGroup=void 0;const t=MP(),e=ld(),i=une(),n=r=>{const{onInit:o,onDelete:a}=r,[s,l]=(0,e.useState)({groupInitialized:!1,charts:new Map}),u=(h,p,g)=>{s.charts.set(h,{isInitialized:p,initResult:g});const v=s.charts.size>0&&Array.from(s.charts.values()).every(({isInitialized:y})=>y);l({groupInitialized:v,charts:s.charts})},c=h=>{s.charts.delete(h);const p=s.charts.size>0&&Array.from(s.charts.values()).every(({isInitialized:g})=>g);l({groupInitialized:p,charts:s.charts})},d=h=>{var p;return(p=r==null?void 0:r.onInitError)===null||p===void 0?void 0:p.call(r,h)},f=Object.assign(Object.assign({},s),{addChartToGroup:u,removeChartFromGroup:c,notifyError:d});return(0,e.useEffect)(()=>{if(o&&s.groupInitialized){const h=Array.from(s.charts.values()).map(({initResult:p})=>p);o(h)}},[s.groupInitialized]),(0,e.useEffect)(()=>{if(a&&s.groupInitialized){const h=Array.from(s.charts.values()).map(({initResult:p})=>p);return()=>{a(h)}}},[s.groupInitialized]),(0,t.jsx)(i.SciChartGroupContext.Provider,{value:f,children:r.children})};return GB.SciChartGroup=n,GB}var GTe;function BAt(){if(GTe)return EO;GTe=1;var t=EO&&EO.__rest||function(a,s){var l={};for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&s.indexOf(u)<0&&(l[u]=a[u]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,u=Object.getOwnPropertySymbols(a);c<u.length;c++)s.indexOf(u[c])<0&&Object.prototype.propertyIsEnumerable.call(a,u[c])&&(l[u[c]]=a[u[c]]);return l};Object.defineProperty(EO,"__esModule",{value:!0}),EO.ChartGroupLoader=void 0;const e=MP(),i=ld(),n=lne(),r=NVe(),o=a=>{const{fallback:s,onInit:l,onInitError:u}=a,c=t(a,["fallback","onInit","onInitError"]),[d,f]=(0,i.useState)(!1);return(0,e.jsx)(r.SciChartGroup,{onInit:h=>{var p;(p=a.onInit)===null||p===void 0||p.call(a,h),f(!0)},onInitError:u,children:(0,e.jsxs)("div",Object.assign({},c,{children:[a.children,d?null:s?(0,e.jsx)("div",{style:n.fallbackWrapperStyle,children:s}):(0,e.jsx)(n.DefaultFallback,{})]}))})};return EO.ChartGroupLoader=o,EO}var Ub={},qB={},YTe;function eG(){if(YTe)return qB;YTe=1,Object.defineProperty(qB,"__esModule",{value:!0}),qB.SciChartSurfaceContext=void 0;const t=ld();return qB.SciChartSurfaceContext=(0,t.createContext)(null),qB}var lv={},qTe;function jAt(){if(qTe)return lv;qTe=1;var t=lv&&lv.__awaiter||function(a,s,l,u){function c(d){return d instanceof l?d:new l(function(f){f(d)})}return new(l||(l=Promise))(function(d,f){function h(v){try{g(u.next(v))}catch(y){f(y)}}function p(v){try{g(u.throw(v))}catch(y){f(y)}}function g(v){v.done?d(v.value):c(v.value).then(h,p)}g((u=u.apply(a,s||[])).next())})};Object.defineProperty(lv,"__esModule",{value:!0}),lv.createChartFromConfig=lv.createChartRoot=lv.useIsMountedRef=void 0;const e=ld(),i=qS(),n=()=>{const a=(0,e.useRef)(!1);return(0,e.useEffect)(()=>(a.current=!0,()=>{a.current=!1}),[]),a};lv.useIsMountedRef=n;const r=()=>{const a=document.createElement("div");return a.id=`chart-root-${(0,i.generateGuid)()}`,a.style.width="100%",a.style.height="100%",a};lv.createChartRoot=r;function o(a){return s=>t(this,void 0,void 0,function*(){const l=yield i.chartBuilder.buildChart(s,a);return"sciChartSurface"in l?{sciChartSurface:l.sciChartSurface}:"sciChart3DSurface"in l?{sciChartSurface:l.sciChart3DSurface}:{sciChartSurface:l}})}return lv.createChartFromConfig=o,lv}var AO={},XTe;function VAt(){return XTe||(XTe=1,Object.defineProperty(AO,"__esModule",{value:!0}),AO.conflictingConfigsMessage=AO.wrongInitResultMessage=void 0,AO.wrongInitResultMessage='"initChart" function should resolve to an object with "sciChartSurface" property ({ sciChartSurface })',AO.conflictingConfigsMessage='Only one of "initChart" or "config" props is required!'),AO}var KTe;function FVe(){if(KTe)return Ub;KTe=1;var t=Ub&&Ub.__awaiter||function(p,g,v,y){function m(b){return b instanceof v?b:new v(function(S){S(b)})}return new(v||(v=Promise))(function(b,S){function _(x){try{P(y.next(x))}catch(E){S(E)}}function C(x){try{P(y.throw(x))}catch(E){S(E)}}function P(x){x.done?b(x.value):m(x.value).then(_,C)}P((y=y.apply(p,g||[])).next())})},e=Ub&&Ub.__rest||function(p,g){var v={};for(var y in p)Object.prototype.hasOwnProperty.call(p,y)&&g.indexOf(y)<0&&(v[y]=p[y]);if(p!=null&&typeof Object.getOwnPropertySymbols=="function")for(var m=0,y=Object.getOwnPropertySymbols(p);m<y.length;m++)g.indexOf(y[m])<0&&Object.prototype.propertyIsEnumerable.call(p,y[m])&&(v[y[m]]=p[y[m]]);return v};Object.defineProperty(Ub,"__esModule",{value:!0}),Ub.SciChartReact=void 0;const i=MP(),n=ld(),r=qS(),o=eG(),a=jAt(),s=une(),l=lne(),u=VAt();r.SciChartSurface.configure({wasmUrl:"/scichart2d.wasm",dataUrl:"/scichart2d.data"}),r.SciChart3DSurface.configure({wasmUrl:"/scichart3d.wasm",dataUrl:"/scichart3d.data"}),r.SciChartDefaults.defaultLoader=!1,r.SciChartDefaults.disableAspect=!0;function c(p){const{initChart:g,config:v}=p;if(!g&&!v||g&&v)throw new Error(u.conflictingConfigsMessage)}function d(p){if(!p.sciChartSurface)throw new Error(u.wrongInitResultMessage);return p}function f(p){const{initChart:g,config:v}=p,y=g||(0,a.createChartFromConfig)(v);return m=>y(m).then(d)}function h(p){const{initChart:g,config:v,fallback:y,onInit:m,onDelete:b,onInitError:S,innerContainerProps:_}=p,C=e(p,["initChart","config","fallback","onInit","onDelete","onInitError","innerContainerProps"]);c(p);const P=(0,a.useIsMountedRef)(),x=(0,n.useRef)(null),E=(0,n.useRef)(),A=(0,n.useRef)(null),[R,M]=(0,n.useState)(!1);(0,n.useEffect)(()=>{const I=(0,r.generateGuid)();D==null||D.addChartToGroup(I,!1,null);const V=x.current,z=(0,a.createChartRoot)();V.appendChild(z);const G=f(p);let H=!1,U;const k=()=>t(this,void 0,void 0,function*(){try{const Y=yield G(z);return P.current?(D==null||D.addChartToGroup(I,!0,Y),A.current=Y,M(!0),m&&(U=m(Y))):H=!0,Y}catch(Y){throw S&&S(Y),D==null||D.notifyError(Y),Y}}),X=E.current?E.current.then(k):k();E.current=X;const W=Y=>{!H&&U&&(U(),U=void 0),H||b==null||b(Y),P.current&&(A.current=null,M(!1)),D==null||D.removeChartFromGroup(I),Y.sciChartSurface.delete()};return()=>{V.removeChild(z),X.then(W)}},[]);const D=(0,n.useContext)(s.SciChartGroupContext),F=Object.assign(Object.assign({},_),{style:Object.assign({height:"100%",width:"100%"},_==null?void 0:_.style)});return(0,i.jsx)(o.SciChartSurfaceContext.Provider,{value:A.current,children:(0,i.jsxs)("div",Object.assign({},C,{style:Object.assign({position:"relative"},C.style),children:[(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("div",Object.assign({},F,{ref:x})),R?p.children:null]}),R?null:y?(0,i.jsx)("div",{style:l.fallbackWrapperStyle,children:y}):(0,i.jsx)(l.DefaultFallback,{})]}))})}return Ub.SciChartReact=h,Ub}var OO={},ZTe;function HAt(){if(ZTe)return OO;ZTe=1;var t=OO&&OO.__rest||function(a,s){var l={};for(var u in a)Object.prototype.hasOwnProperty.call(a,u)&&s.indexOf(u)<0&&(l[u]=a[u]);if(a!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,u=Object.getOwnPropertySymbols(a);c<u.length;c++)s.indexOf(u[c])<0&&Object.prototype.propertyIsEnumerable.call(a,u[c])&&(l[u[c]]=a[u[c]]);return l};Object.defineProperty(OO,"__esModule",{value:!0}),OO.SciChartNestedLegend=void 0;const e=MP(),i=ld(),n=qS(),r=eG(),o=a=>{const{options:s}=a,l=t(a,["options"]),u=(0,i.useRef)(null),c=(0,i.useContext)(r.SciChartSurfaceContext),d=c==null?void 0:c.sciChartSurface;return(0,i.useEffect)(()=>{const f=new n.LegendModifier(Object.assign(Object.assign({},a==null?void 0:a.options),{placementDivId:u.current}));return d.chartModifiers.add(f),()=>{d.chartModifiers.remove(f,!0)}},[d]),(0,e.jsx)("div",Object.assign({},l,{ref:u}))};return OO.SciChartNestedLegend=o,OO}var XB={},JTe;function UAt(){if(JTe)return XB;JTe=1,Object.defineProperty(XB,"__esModule",{value:!0}),XB.SciChartMemoryDebugWrapper=void 0;const t=MP(),e=ld(),i=qS();function n(r){(0,e.useState)(()=>{i.MemoryUsageHelper.isMemoryUsageDebugEnabled=!0,i.SciChartSurface.autoDisposeWasmContext=!0,i.SciChartSurface.wasmContextDisposeTimeout=0});const[o,a]=(0,e.useState)(!1),s=u=>{a(u.target.checked)},l=()=>{window.gc&&window.gc();const u=i.MemoryUsageHelper.objectRegistry.getState();console.log("state",u)};return(0,t.jsx)(t.Fragment,{children:(0,t.jsxs)("div",{style:{position:"fixed",top:0,left:0},children:[(0,t.jsx)("input",{type:"checkbox",checked:o,onChange:s})," Render Child Components Tree",(0,t.jsx)("br",{}),(0,t.jsx)("input",{type:"button",onClick:l,value:"Log Object Registry State"}),(0,t.jsx)("br",{}),o?r.children:null]})})}return XB.SciChartMemoryDebugWrapper=n,XB}var zb={},QTe;function zAt(){if(QTe)return zb;QTe=1;var t=zb&&zb.__awaiter||function(l,u,c,d){function f(h){return h instanceof c?h:new c(function(p){p(h)})}return new(c||(c=Promise))(function(h,p){function g(m){try{y(d.next(m))}catch(b){p(b)}}function v(m){try{y(d.throw(m))}catch(b){p(b)}}function y(m){m.done?h(m.value):f(m.value).then(g,v)}y((d=d.apply(l,u||[])).next())})},e=zb&&zb.__rest||function(l,u){var c={};for(var d in l)Object.prototype.hasOwnProperty.call(l,d)&&u.indexOf(d)<0&&(c[d]=l[d]);if(l!=null&&typeof Object.getOwnPropertySymbols=="function")for(var f=0,d=Object.getOwnPropertySymbols(l);f<d.length;f++)u.indexOf(d[f])<0&&Object.prototype.propertyIsEnumerable.call(l,d[f])&&(c[d[f]]=l[d[f]]);return c};Object.defineProperty(zb,"__esModule",{value:!0}),zb.SciChartNestedOverview=void 0;const i=MP(),n=ld(),r=qS(),o=eG(),a=FVe(),s=l=>{const{options:u}=l,c=e(l,["options"]),d=(0,n.useContext)(o.SciChartSurfaceContext),f=d==null?void 0:d.sciChartSurface,h=(0,n.useRef)(null),p=(0,n.useRef)(null),g=v=>t(void 0,void 0,void 0,function*(){p.current=r.SciChartOverview.create(f,v,u);const y=yield p.current;return h.current=y,{sciChartSurface:y.overviewSciChartSurface}});return f?(0,i.jsx)(a.SciChartReact,Object.assign({},c,{initChart:g,onDelete:()=>{h.current.delete()}})):null};return zb.SciChartNestedOverview=s,zb}var e1e;function $At(){return e1e||(e1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SciChartSurfaceContext=t.SciChartNestedOverview=t.SciChartMemoryDebugWrapper=t.SciChartNestedLegend=t.SciChartGroupContext=t.SciChartGroup=t.SciChartReact=t.DefaultFallback=t.ChartGroupLoader=void 0;var e=BAt();Object.defineProperty(t,"ChartGroupLoader",{enumerable:!0,get:function(){return e.ChartGroupLoader}});var i=lne();Object.defineProperty(t,"DefaultFallback",{enumerable:!0,get:function(){return i.DefaultFallback}});var n=FVe();Object.defineProperty(t,"SciChartReact",{enumerable:!0,get:function(){return n.SciChartReact}});var r=NVe();Object.defineProperty(t,"SciChartGroup",{enumerable:!0,get:function(){return r.SciChartGroup}});var o=une();Object.defineProperty(t,"SciChartGroupContext",{enumerable:!0,get:function(){return o.SciChartGroupContext}});var a=HAt();Object.defineProperty(t,"SciChartNestedLegend",{enumerable:!0,get:function(){return a.SciChartNestedLegend}});var s=UAt();Object.defineProperty(t,"SciChartMemoryDebugWrapper",{enumerable:!0,get:function(){return s.SciChartMemoryDebugWrapper}});var l=zAt();Object.defineProperty(t,"SciChartNestedOverview",{enumerable:!0,get:function(){return l.SciChartNestedOverview}});var u=eG();Object.defineProperty(t,"SciChartSurfaceContext",{enumerable:!0,get:function(){return u.SciChartSurfaceContext}})})(C7)),C7}var $I=$At(),WAt=AI();const l$=function(t,e){if(t&&!t.isDeleted){const i=e?cne:dne;t.applyTheme(i.scichartTheme()),t.renderableSeries.asArray().forEach(a=>YAt(a,e)),t.chartModifiers.asArray().forEach((a,s)=>{switch(a.constructor.name){case"CursorModifier2":t.chartModifiers.removeAt(s);break;case"RolloverModifier2":GAt(a,e);break;case"DataPointSelectionModifier2":a.selectionFill=e?"#FFFFFF":"#000000",a.selectionStroke=e?"#ff0000":"#333333"}});const n=new Gt.CursorModifier({modifierGroup:"asd",showTooltip:!1,showAxisLabels:!0,showXLine:!0,showYLine:!0,axisLabelFill:i.tooltipBackground,axisLabelStroke:i.tooltipTextColor,crosshairStroke:i.tooltipTextColor,crosshairStrokeThickness:1,crosshairStrokeDashArray:[4,4]});t.chartModifiers.add(n);const r=t.annotations.asArray().filter(a=>a.id==="playahead");r.length>0&&(r[0].stroke=e?"#aaaaaa":"#111111");const o=t.annotations.asArray().filter(a=>a.id==="selectedPoint");o.length>0&&(o[0].stroke=e?"#ffdd00":"#101010"),t.invalidateElement()}},GAt=function(t,e){t.rolloverLineStroke=e?"#FFFFFF":"#555555",t.rolloverLineStrokeThickness=1},YAt=function(t,e){const i=e?cne:dne;t.rolloverModifierProps.tooltipTextColor=i.tooltipTextColor,t.rolloverModifierProps.tooltipColor=i.tooltipBackground,t.rolloverModifierProps.shadowColor=i.tooltipBackground},cne={scichartTheme:()=>({...new Gt.SciChartJSDarkv2Theme,sciChartBackground:"#212121",cursorLineBrush:"aaaaaa"}),tooltipBackground:"#212121",tooltipTextColor:"#999",buttonBackground:"#434343",buttonText:"#FFFFFF",buttonBorder:"#787878"},dne={scichartTheme:()=>({...new Gt.SciChartJSLightTheme,sciChartBackground:"#EDF4FA"}),tooltipBackground:"#EDF4FA",tooltipTextColor:"#000",buttonBackground:"#efefef",buttonText:"#343434",buttonBorder:"#000000"};function T7(t){return t?cne:dne}WAt.setIsDebugLicensing(!1);Gt.SciChartSurface.useWasmFromCDN();class qAt extends Gt.SmartDateLabelProvider{get formatLabel(){return e=>{const i=new Date(e),n=i.getHours().toString().padStart(2,"0"),r=i.getMinutes().toString().padStart(2,"0"),o=i.getSeconds().toString().padStart(2,"0");return`${n}:${r}:${o}`}}get formatCursorLabel(){return e=>{const i=new Date(e),n=i.getHours().toString().padStart(2,"0"),r=i.getMinutes().toString().padStart(2,"0"),o=i.getSeconds().toString().padStart(2,"0"),a=i.getMilliseconds().toString().padStart(3,"0");return`${n}:${r}:${o}.${a}`}}}const t1e=t=>({fill:t?"#4a90c2B3":"#05315aB3",stroke:t?"#6ab0e2":"#05315a"}),XAt=t=>{const e=t.frameIdFrequency.map(i=>Number(i.frequency));return{x:t.receivedTimestamp,y:e.length>0?e.reduce((i,n)=>i+n):0}},KAt=500,ZAt=8,x7=12;function JAt(t){var $t;const e=qt.c(123),{graphWidthMs:i,data:n,shouldPauseStreaming:r,chartKey:o,height:a,isDarkMode:s,clock:l,showBinDistribution:u,maxBinDistributionItems:c,frameIdToNameMapping:d,filter:f,onFilterChange:h,isBinDistributionEnabled:p}=t,g=u===void 0?!1:u,v=c===void 0?ZAt:c,y=p===void 0?!0:p,[m,b]=J.useState(void 0),S=f!==void 0?f:m,_=J.useRef(null),C=J.useRef(null),P=J.useRef(null),x=J.useRef(null),E=J.useRef(null),A=J.useRef(null),R=J.useRef(r),M=J.useRef(i);let D,F;e[0]!==r?(D=()=>{R.current=r},F=[r],e[0]=r,e[1]=D,e[2]=F):(D=e[1],F=e[2]),J.useEffect(D,F);let I,V;e[3]!==i?(I=()=>{M.current=i},V=[i],e[3]=i,e[4]=I,e[5]=V):(I=e[4],V=e[5]),J.useEffect(I,V);const z=a??"100%";let G;e[6]!==z?(G={width:"100%",height:z,position:"relative",overflow:"hidden"},e[6]=z,e[7]=G):G=e[7];const H=G;let U;e[8]===Symbol.for("react.memo_cache_sentinel")?(U={width:"100%",height:"100%"},e[8]=U):U=e[8];const k=U;let X,W;e[9]!==s?(X=()=>{const Mt=_.current;if(!(!Mt||Mt.isDeleted)&&(l$(Mt,s),E.current)){const rt=t1e(s);E.current.fill=rt.fill,E.current.stroke=rt.stroke}},W=[s],e[9]=s,e[10]=X,e[11]=W):(X=e[10],W=e[11]),J.useEffect(X,W);let Y,te;e[12]!==n?(Y=()=>{const Mt=P.current,rt=_.current;if(!Mt||n.length===0||rt!=null&&rt.isDeleted)return;Mt.clear();const qe=n.map(XAt);if(qe.length>0){const vt=new Float64Array(qe.map(iOt)),kt=new Float64Array(qe.map(rOt));Mt.appendRange(vt,kt)}},te=[n],e[12]=n,e[13]=Y,e[14]=te):(Y=e[13],te=e[14]),J.useEffect(Y,te);let oe;e[15]!==o||e[16]!==l||e[17]!==i||e[18]!==s?(oe=async Mt=>{const rt=typeof Mt=="string"?document.getElementById(Mt):Mt;if(!rt)throw new Error("SciChart root element not found");const{wasmContext:qe,sciChartSurface:vt}=await Gt.SciChartSurface.create(rt,{freezeWhenOutOfView:!0});_.current=vt,C.current=qe;const kt=new Gt.NumericAxis(qe,{labelProvider:new qAt,useNativeText:!0,drawMinorGridLines:!1,drawMajorGridLines:!0});kt.autoRange=Gt.EAutoRange.Never,kt.visibleRange=new Gt.NumberRange(Date.now()-i,Date.now()),kt.majorDelta=1e3,x.current=kt,vt.xAxes.add(kt);const Xe=new Gt.NumericAxis(qe,{drawMinorGridLines:!1,drawMajorGridLines:!0});Xe.axisAlignment=Gt.EAxisAlignment.Left,Xe.autoRange=Gt.EAutoRange.Always,Xe.growBy=new Gt.NumberRange(0,.1),Xe.isInnerAxis=!0,Xe.drawLabels=!0,vt.yAxes.add(Xe);const _t=new Gt.XyDataSeries(qe,{fifoCapacity:100,dataSeriesName:`frame-distribution-${o}`,dataIsSortedInX:!0,dataEvenlySpacedInX:!1,containsNaN:!1});P.current=_t;const Ht=t1e(s),Pt=new Gt.FastColumnRenderableSeries(qe,{dataSeries:_t,fill:Ht.fill,stroke:Ht.stroke,strokeThickness:1,dataPointWidth:.8});E.current=Pt,vt.renderableSeries.add(Pt),vt.chartModifiers.add(new Gt.RolloverModifier({showTooltip:!0,showRolloverLine:!0,rolloverLineStrokeThickness:1}),new Gt.CursorModifier({showTooltip:!1,showAxisLabels:!0,showXLine:!0,showYLine:!1,crosshairStrokeThickness:1,crosshairStrokeDashArray:[4,4]}),new Gt.ZoomExtentsModifier),l$(vt,s);const Jt=()=>{if(!vt.isDeleted){if(!R.current&&x.current){const zt=l.time(),Bt=zt+KAt,Mr=zt-M.current;x.current.visibleRange=new Gt.NumberRange(Mr,Bt)}A.current=requestAnimationFrame(Jt)}};return A.current=requestAnimationFrame(Jt),{sciChartSurface:vt}},e[15]=o,e[16]=l,e[17]=i,e[18]=s,e[19]=oe):oe=e[19];const de=oe;let ge,Ee;e[20]===Symbol.for("react.memo_cache_sentinel")?(ge=()=>()=>{A.current&&cancelAnimationFrame(A.current)},Ee=[],e[20]=ge,e[21]=Ee):(ge=e[20],Ee=e[21]),J.useEffect(ge,Ee);let Re;e[22]!==d?(Re=Mt=>{const rt=d==null?void 0:d.get(Mt.frameId);return rt!==void 0?`${rt} - ${Mt.frameId} (0x${Mt.frameId.toString(16).toUpperCase()})`:`${Mt.frameId}`},e[22]=d,e[23]=Re):Re=e[23];const Ae=Re;let Pe;e[24]!==h?(Pe=Mt=>{const rt=Mt.target.value.toLowerCase(),qe=rt.length>=1?rt:void 0;h?h(qe):b(qe)},e[24]=h,e[25]=Pe):Pe=e[25];const we=Pe;let Te;e:{if(!g||!y){Te=null;break e}const Mt=n[n.length-1];if(!Mt){Te=null;break e}let rt;if(e[26]!==Ae||e[27]!==Mt.frameIdFrequency){let Ar;e[29]!==Ae?(Ar=Qr=>Ae(Qr)!==`${Qr.frameId}`,e[29]=Ae,e[30]=Ar):Ar=e[30],rt=Mt.frameIdFrequency.filter(Ar),e[26]=Ae,e[27]=Mt.frameIdFrequency,e[28]=rt}else rt=e[28];const vt=rt.length/Mt.frameIdFrequency.length*100,kt=Math.round(vt*100)/100||0;let Xe;e[31]!==s||e[32]!==kt?(Xe=()=>kt<10?s?"#ef4444":"#dc2626":kt<33?s?"#f59e0b":"#d97706":kt<75?s?"#4a90c2":"#05315a":s?"#22c55e":"#16a34a",e[31]=s,e[32]=kt,e[33]=Xe):Xe=e[33];const _t=Xe;let Ht;e[34]===Symbol.for("react.memo_cache_sentinel")?(Ht={display:"flex",flexDirection:"column",padding:"4px",paddingBottom:0},e[34]=Ht):Ht=e[34];const Pt=s?"#9ca3af":"#6b7280";let Jt;e[35]!==Pt?(Jt={fontSize:"12px",padding:0,margin:0,color:Pt,textAlign:"left"},e[35]=Pt,e[36]=Jt):Jt=e[36];const zt=_t();let Bt;e[37]!==zt?(Bt={color:zt},e[37]=zt,e[38]=Bt):Bt=e[38];const Mr=`${kt}%`;let Be;e[39]!==Bt||e[40]!==Mr?(Be=L.jsx("span",{style:Bt,children:Mr}),e[39]=Bt,e[40]=Mr,e[41]=Be):Be=e[41];let We;e[42]!==Jt||e[43]!==Be?(We=L.jsxs("p",{style:Jt,children:["Signal database hit rate:"," ",Be]}),e[42]=Jt,e[43]=Be,e[44]=We):We=e[44];const dt=s?"#6b7280":"#9ca3af";let Tt;e[45]!==dt?(Tt=L.jsx("p",{style:{fontSize:"11px",padding:0,margin:0,color:dt},children:"The amount of received frames present in the signal database file"}),e[45]=dt,e[46]=Tt):Tt=e[46];let nr;e[47]!==We||e[48]!==Tt?(nr=L.jsxs("div",{style:Ht,children:[We,Tt]}),e[47]=We,e[48]=Tt,e[49]=nr):nr=e[49],Te=nr}const ke=Te;let $e;if(e[50]!==n||e[51]!==S||e[52]!==Ae||e[53]!==y||e[54]!==s||e[55]!==v||e[56]!==g){e:{if(!g){$e=null;break e}if(!y){let Ht;e[58]===Symbol.for("react.memo_cache_sentinel")?(Ht={height:"100%",display:"flex",justifyContent:"center",alignItems:"center"},e[58]=Ht):Ht=e[58];const Pt=s?"#9ca3af":"#6b7280";let Jt;e[59]!==Pt?(Jt=L.jsx("div",{style:Ht,children:L.jsx("p",{style:{fontSize:"12px",color:Pt},children:"This visualization is disabled for the current namespace type."})}),e[59]=Pt,e[60]=Jt):Jt=e[60],$e=Jt;break e}const Mt=n[n.length-1];if(!Mt){let Ht;e[61]===Symbol.for("react.memo_cache_sentinel")?(Ht={width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"},e[61]=Ht):Ht=e[61];const Pt=s?"#9ca3af":"#6b7280";let Jt;e[62]!==Pt?(Jt=L.jsx("div",{style:Ht,children:L.jsx("p",{style:{margin:0,fontSize:"12px",color:Pt},children:"No frames received"})}),e[62]=Pt,e[63]=Jt):Jt=e[63],$e=Jt;break e}let rt=Mt;if(S!==void 0){let Ht;e[64]!==S||e[65]!==Ae?(Ht=Pt=>Ae(Pt).toLowerCase().includes(S.toLowerCase()),e[64]=S,e[65]=Ae,e[66]=Ht):Ht=e[66],rt={receivedTimestamp:Mt.receivedTimestamp,frameIdFrequency:Mt.frameIdFrequency.filter(Ht)}}if((($t=rt==null?void 0:rt.frameIdFrequency)==null?void 0:$t.length)>0){let Ht;e[67]!==Mt.frameIdFrequency?(Ht=Mt.frameIdFrequency.map(tOt).reduce(eOt),e[67]=Mt.frameIdFrequency,e[68]=Ht):Ht=e[68];const Pt=Ht,Jt=s?"rgba(74, 144, 194, 0.1)":"rgba(5, 49, 90, 0.1)",zt=s?"rgba(74, 144, 194, 0.4)":"rgba(5, 49, 90, 0.3)",Bt=s?"rgba(74, 144, 194, 0.7)":"rgba(5, 49, 90, 0.6)",Mr=s?"#e5e7eb":"#1f2937";let Be;e[69]===Symbol.for("react.memo_cache_sentinel")?(Be={display:"flex",flexWrap:"wrap"},e[69]=Be):Be=e[69];let We;e[70]!==zt||e[71]!==Bt||e[72]!==Jt||e[73]!==Ae||e[74]!==Mr||e[75]!==Pt?(We=dt=>L.jsx("div",{style:{width:"50%"},children:L.jsxs("div",{style:{marginLeft:2,marginRight:2,marginBottom:4,borderRadius:4,backgroundColor:Jt,padding:4,display:"flex",flexDirection:"column"},children:[L.jsxs("div",{style:{display:"flex",flexDirection:"row",margin:0,alignItems:"center",justifyContent:"space-between"},children:[L.jsx("p",{style:{color:Mr,fontSize:"12px",paddingLeft:4,margin:0,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},children:Ae(dt)}),L.jsx("p",{style:{color:Mr,fontSize:"12px",paddingLeft:4,paddingRight:4,margin:0},children:dt.frequency})]}),L.jsxs("div",{style:{width:"100%",position:"relative"},children:[L.jsx("div",{style:{height:x7,borderRadius:4,backgroundColor:zt,marginLeft:4,marginTop:0,position:"absolute",width:"calc(100% - 8px)"}}),L.jsx("div",{style:{width:`${Number(dt.frequency)/Pt*100}%`,height:x7,borderRadius:4,backgroundColor:Bt,marginLeft:4,marginTop:0,position:"relative"}}),L.jsx("p",{style:{fontSize:"10px",color:"#ffffff",paddingLeft:4,paddingRight:4,margin:0,position:"absolute",top:0,left:0,lineHeight:`${x7}px`},children:`${dt.frequency}/${Pt}`})]})]})},dt.frameId),e[70]=zt,e[71]=Bt,e[72]=Jt,e[73]=Ae,e[74]=Mr,e[75]=Pt,e[76]=We):We=e[76],$e=L.jsx("div",{style:Be,children:rt.frameIdFrequency.sort(QAt).slice(0,v).map(We)});break e}let qe;e[77]===Symbol.for("react.memo_cache_sentinel")?(qe={width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"},e[77]=qe):qe=e[77];const vt=s?"#9ca3af":"#6b7280";let kt;e[78]!==vt?(kt={margin:0,fontSize:"12px",color:vt},e[78]=vt,e[79]=kt):kt=e[79];const Xe=S!==void 0&&S.trim()!==""?"No frames match the current filter":"No frames received";let _t;e[80]!==kt||e[81]!==Xe?(_t=L.jsx("div",{style:qe,children:L.jsx("p",{style:kt,children:Xe})}),e[80]=kt,e[81]=Xe,e[82]=_t):_t=e[82],$e=_t}e[50]=n,e[51]=S,e[52]=Ae,e[53]=y,e[54]=s,e[55]=v,e[56]=g,e[57]=$e}else $e=e[57];const Ne=$e;let ve;e:{if(!g||!y){ve=null;break e}const Mt=n[n.length-1];if(!Mt){ve=null;break e}const rt=Mt.frameIdFrequency.length;let qe;e[83]!==S||e[84]!==Ae||e[85]!==Mt.frameIdFrequency||e[86]!==rt?(qe=S!==void 0?Mt.frameIdFrequency.filter(Ht=>Ae(Ht).toLowerCase().includes(S.toLowerCase())).length:rt,e[83]=S,e[84]=Ae,e[85]=Mt.frameIdFrequency,e[86]=rt,e[87]=qe):qe=e[87];const vt=qe,kt=Math.min(rt,v),Xe=Math.min(vt,kt);let _t;e[88]!==kt||e[89]!==Xe?(_t={displayed:Xe,cap:kt},e[88]=kt,e[89]=Xe,e[90]=_t):_t=e[90],ve=_t}const pe=ve;let fe;e:{if(!g||!y){fe=null;break e}let Mt;e[91]===Symbol.for("react.memo_cache_sentinel")?(Mt={display:"flex",flexDirection:"column",width:"100%"},e[91]=Mt):Mt=e[91];const rt=`1px solid ${s?"#374151":"#d1d5db"}`,qe=s?"#1f2937":"#ffffff",vt=s?"#e5e7eb":"#1f2937";let kt;e[92]!==rt||e[93]!==qe||e[94]!==vt?(kt={width:"100%",fontSize:"11px",border:rt,backgroundColor:qe,color:vt,outline:"none"},e[92]=rt,e[93]=qe,e[94]=vt,e[95]=kt):kt=e[95];let Xe;e[96]!==we||e[97]!==kt?(Xe=L.jsx("input",{type:"text",placeholder:"Filter frames...",onChange:we,className:"rounded-sm py-0.5 px-2",style:kt}),e[96]=we,e[97]=kt,e[98]=Xe):Xe=e[98];let _t;e[99]!==pe||e[100]!==s?(_t=pe!==null&&L.jsxs("p",{className:"m-0 ms-0.5 mt-0.5 text-xxs",style:{color:s?"#6b7280":"#9ca3af"},children:["Showing ",pe.displayed," of ",pe.cap," results"]}),e[99]=pe,e[100]=s,e[101]=_t):_t=e[101];let Ht;e[102]!==Xe||e[103]!==_t?(Ht=L.jsxs("div",{style:Mt,children:[Xe,_t]}),e[102]=Xe,e[103]=_t,e[104]=Ht):Ht=e[104],fe=Ht}const me=fe;let Ce;e[105]===Symbol.for("react.memo_cache_sentinel")?(Ce={display:"flex",flexDirection:"column",flex:1,minHeight:0},e[105]=Ce):Ce=e[105];let Ue;e[106]!==H?(Ue={...H,flexShrink:0},e[106]=H,e[107]=Ue):Ue=e[107];let Qe;e[108]!==de?(Qe=L.jsx($I.SciChartReact,{style:k,initChart:de}),e[108]=de,e[109]=Qe):Qe=e[109];let it;e[110]!==Ue||e[111]!==Qe?(it=L.jsx("div",{style:Ue,children:Qe}),e[110]=Ue,e[111]=Qe,e[112]=it):it=e[112];let xt;e[113]!==me||e[114]!==Ne||e[115]!==ke||e[116]!==s||e[117]!==v||e[118]!==g?(xt=g&&L.jsxs("div",{style:{display:"flex",flexDirection:"column",flex:1,minHeight:0,marginTop:8,padding:"0 4px"},children:[L.jsxs("div",{style:{display:"flex",flexDirection:"row",marginBottom:8,width:"100%",alignItems:"center",gap:12,flexShrink:0},children:[L.jsxs("div",{style:{flex:1,textAlign:"left",minWidth:0},children:[L.jsx("p",{style:{margin:0,fontSize:"14px",fontWeight:500,color:s?"#e5e7eb":"#1f2937"},children:"Latest bin distribution"}),L.jsx("p",{style:{margin:0,fontSize:"11px",color:s?"#6b7280":"#9ca3af"},children:"Most frequent frames, ordered by count"})]}),L.jsx("div",{style:{flex:1,minWidth:0},children:me})]}),L.jsx("div",{style:{flex:1,minHeight:0,overflowY:"auto",overflowX:"hidden"},children:Ne},v),ke]}),e[113]=me,e[114]=Ne,e[115]=ke,e[116]=s,e[117]=v,e[118]=g,e[119]=xt):xt=e[119];let wt;return e[120]!==it||e[121]!==xt?(wt=L.jsxs("div",{style:Ce,children:[it,xt]}),e[120]=it,e[121]=xt,e[122]=wt):wt=e[122],wt}function QAt(t,e){return Number(e.frequency)-Number(t.frequency)||t.frameId-e.frameId}function eOt(t,e){return t+e}function tOt(t){return Number(t.frequency)}function rOt(t){return t.y}function iOt(t){return t.x}const WI=J.forwardRef(function(e,i){const n=qt.c(6),{children:r,fullHeight:o}=e,s=(o===void 0?!1:o)&&"h-full flex flex-col";let l;n[0]!==s?(l=Hr("w-full relative group/area rounded-sm overflow-hidden bg-[var(--primary-10)]",s),n[0]=s,n[1]=l):l=n[1];let u;return n[2]!==r||n[3]!==i||n[4]!==l?(u=L.jsx("div",{ref:i,className:l,children:r}),n[2]=r,n[3]=i,n[4]=l,n[5]=u):u=n[5],u});function GI(t){const e=qt.c(13),{icon:i,dropdown:n,children:r,helpTooltip:o}=t;let a;e[0]!==i?(a=L.jsx("div",{className:"w-5 h-5 bg-blue-200/60 dark:bg-accent rounded flex items-center justify-center",children:L.jsx(Wr,{type:i,className:"w-3 h-3 dark:text-foreground text-muted-foreground"})}),e[0]=i,e[1]=a):a=e[1];const s=a;let l;e[2]!==o||e[3]!==s?(l=o!=null?L.jsx(FD,{delay:200,content:o,className:"flex items-center",children:s}):s,e[2]=o,e[3]=s,e[4]=l):l=e[4];let u;e[5]!==r||e[6]!==l?(u=L.jsxs("div",{className:"flex items-center gap-2 w-full",children:[l,r]}),e[5]=r,e[6]=l,e[7]=u):u=e[7];let c;e[8]!==n?(c=L.jsx("div",{className:"flex justify-end z-20 mb-0",children:n}),e[8]=n,e[9]=c):c=e[9];let d;return e[10]!==u||e[11]!==c?(d=L.jsxs("div",{className:"flex flex-row justify-between px-1 py-1 grid-stack-item-drag-handle w-full",children:[u,c]}),e[10]=u,e[11]=c,e[12]=d):d=e[12],d}function YI(t){const e=qt.c(7),{children:i,fullHeight:n,padding:r}=t,o=n===void 0?!1:n,a=r??o,s=o&&"flex-1 min-h-0 flex flex-col",l=a&&"p-2",u=!o&&"bg-card";let c;e[0]!==s||e[1]!==l||e[2]!==u?(c=Hr(s,l,u),e[0]=s,e[1]=l,e[2]=u,e[3]=c):c=e[3];let d;return e[4]!==i||e[5]!==c?(d=L.jsx("div",{className:c,children:i}),e[4]=i,e[5]=c,e[6]=d):d=e[6],d}const nOt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Frame distribution"}),L.jsx("p",{className:"text-xs ms-2",children:"Each bucket represents all frames for one namespace during one second. The bin distribution shows the distribution of frames in the last received bucket."}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Namespace"}),": The namespace for which to receive frame buckets"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Distribution items"}),": Maximum number of items to show in the latest bin distribution list"]})]}),oOt={sm:{track:"w-8 h-4",knob:"h-3 w-3 left-0.5 top-0.5",translate:"1rem"},md:{track:"w-11 h-6",knob:"h-5 w-5 left-0.5 top-0.5",translate:"1.25rem"},lg:{track:"w-14 h-7",knob:"h-6 w-6 left-0.5 top-0.5",translate:"1.75rem"}};function BVe(t){const e=qt.c(16),[i,n]=J.useState(t.defaultChecked??!1),r=t.size??"md",o=oOt[r];let a;e[0]!==t?(a=v=>{var m;const y=v.target.checked;n(y),(m=t.onChange)==null||m.call(t,y)},e[0]=t,e[1]=a):a=e[1];const s=a;let l;e[2]!==i||e[3]!==s?(l=L.jsx("input",{type:"checkbox",checked:i,onChange:s,className:"sr-only"}),e[2]=i,e[3]=s,e[4]=l):l=e[4];const u=`rounded-full transition-colors ${o.track} ${i?"bg-emerald-500":"bg-muted border"}`;let c;e[5]!==u?(c=L.jsx("div",{className:u}),e[5]=u,e[6]=c):c=e[6];const d=`absolute rounded-full bg-white shadow transition-[transform] duration-200 ease-out ${o.knob}`,f=i?`translateX(${o.translate})`:"translateX(0)";let h;e[7]!==f?(h={transform:f},e[7]=f,e[8]=h):h=e[8];let p;e[9]!==d||e[10]!==h?(p=L.jsx("div",{className:d,style:h,"aria-hidden":!0}),e[9]=d,e[10]=h,e[11]=p):p=e[11];let g;return e[12]!==l||e[13]!==c||e[14]!==p?(g=L.jsxs("label",{className:"relative inline-flex items-center cursor-pointer",children:[l,c,p]}),e[12]=l,e[13]=c,e[14]=p,e[15]=g):g=e[15],g}const jVe=J.createContext(null);function tG(){const t=J.useContext(jVe);if(!t)throw new Error("PanelDropdownMenu sub-components must be used within a PanelDropdownMenu");return t}const aOt=Hr("z-[9999] w-[220px]","bg-popover border border-border","rounded-md shadow-xl p-1","animate-in fade-in-0 zoom-in-95"),sOt=Hr("flex items-center justify-between w-full px-2 py-1.5","text-xs text-popover-foreground outline-none","transition-colors rounded-sm");function Ri(t){const e=qt.c(5);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i={menuItemStyles:Hr(sOt)},e[0]=i):i=e[0];const n=i;let r;e[1]===Symbol.for("react.memo_cache_sentinel")?(r=Hr("p-0.5 rounded transition-all","text-muted-foreground hover:bg-accent hover:text-accent-foreground","data-[state=open]:opacity-100 data-[state=open]:bg-accent data-[state=open]:text-accent-foreground","focus:outline-none focus-visible:ring-2 focus-visible:ring-primary/40 focus-visible:ring-offset-2 focus-visible:ring-offset-background"),e[1]=r):r=e[1];let o;e[2]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx(Nk,{asChild:!0,children:L.jsx("button",{className:r,title:"Panel options",children:L.jsx(Wr,{type:dr.NAV_MORE_VERTICAL,className:"w-4 h-4"})})}),e[2]=o):o=e[2];let a;return e[3]!==t.children?(a=L.jsx(jVe.Provider,{value:n,children:L.jsxs(Ik,{children:[o,L.jsx(AD,{children:L.jsx(Fk,{align:"end",sideOffset:4,className:aOt,children:t.children})})]})}),e[3]=t.children,e[4]=a):a=e[4],a}function lOt(t){const e=qt.c(5);let i;e[0]!==t.title?(i=L.jsx(wMe,{className:"px-2 py-1 text-[10px] font-semibold text-muted-foreground uppercase tracking-wider bg-muted/50 rounded-sm",children:t.title}),e[0]=t.title,e[1]=i):i=e[1];let n;return e[2]!==t.children||e[3]!==i?(n=L.jsxs(EMe,{children:[i,t.children]}),e[2]=t.children,e[3]=i,e[4]=n):n=e[4],n}function uOt(){const t=qt.c(1);let e;return t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsx(Fat,{className:"my-1 bg-border"}),t[0]=e):e=t[0],e}function cOt(t){const e=qt.c(11),{menuItemStyles:i}=tG();let n;e[0]!==i?(n=Hr(i),e[0]=i,e[1]=n):n=e[1];let r;e[2]!==t.label?(r=L.jsx("span",{children:t.label}),e[2]=t.label,e[3]=r):r=e[3];let o;e[4]!==t.checked||e[5]!==t.onChange?(o=L.jsx(BVe,{size:"sm",defaultChecked:t.checked,onChange:t.onChange}),e[4]=t.checked,e[5]=t.onChange,e[6]=o):o=e[6];let a;return e[7]!==n||e[8]!==r||e[9]!==o?(a=L.jsxs(dm,{className:n,onSelect:dOt,children:[r,o]}),e[7]=n,e[8]=r,e[9]=o,e[10]=a):a=e[10],a}function dOt(t){return t.preventDefault()}function fOt(t){const e=qt.c(29),{menuItemStyles:i}=tG(),{value:n,onChange:r,min:o,max:a,step:s,formatValue:l}=t,u=o===void 0?-1/0:o,c=a===void 0?1/0:a,d=s===void 0?1:s;let f;e[0]!==u||e[1]!==r||e[2]!==d||e[3]!==n?(f=x=>{x.preventDefault(),r(Math.max(u,n-d))},e[0]=u,e[1]=r,e[2]=d,e[3]=n,e[4]=f):f=e[4];const h=f;let p;e[5]!==c||e[6]!==r||e[7]!==d||e[8]!==n?(p=x=>{x.preventDefault(),r(Math.min(c,n+d))},e[5]=c,e[6]=r,e[7]=d,e[8]=n,e[9]=p):p=e[9];const g=p;let v;e[10]!==l||e[11]!==n?(v=l?l(n):n.toString(),e[10]=l,e[11]=n,e[12]=v):v=e[12];const y=v;let m;e[13]!==t.label?(m=L.jsx("span",{children:t.label}),e[13]=t.label,e[14]=m):m=e[14];let b;e[15]!==h?(b=L.jsx("button",{type:"button",onClick:h,className:"w-5 h-5 flex items-center justify-center rounded hover:bg-accent text-muted-foreground hover:text-accent-foreground text-xs",children:"−"}),e[15]=h,e[16]=b):b=e[16];let S;e[17]!==y?(S=L.jsx("span",{className:"w-8 text-center text-foreground",children:y}),e[17]=y,e[18]=S):S=e[18];let _;e[19]!==g?(_=L.jsx("button",{type:"button",onClick:g,className:"w-5 h-5 flex items-center justify-center rounded hover:bg-accent text-muted-foreground hover:text-accent-foreground text-xs",children:"+"}),e[19]=g,e[20]=_):_=e[20];let C;e[21]!==b||e[22]!==S||e[23]!==_?(C=L.jsxs("div",{className:"flex items-center gap-1",onClick:hOt,children:[b,S,_]}),e[21]=b,e[22]=S,e[23]=_,e[24]=C):C=e[24];let P;return e[25]!==i||e[26]!==C||e[27]!==m?(P=L.jsxs(dm,{className:i,onSelect:pOt,children:[m,C]}),e[25]=i,e[26]=C,e[27]=m,e[28]=P):P=e[28],P}function hOt(t){return t.stopPropagation()}function pOt(t){return t.preventDefault()}function gOt(t){const e=qt.c(26),{menuItemStyles:i}=tG();let n,r,o;if(e[0]!==i||e[1]!==t.onClick||e[2]!==t.variant){const h={default:"cursor-pointer data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground",danger:"cursor-pointer text-red-400 data-[highlighted]:bg-red-900/30",primary:"cursor-pointer text-primary data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground"},p=t.variant??"default";n=dm,r=t.onClick,o=Hr(i,h[p]),e[0]=i,e[1]=t.onClick,e[2]=t.variant,e[3]=n,e[4]=r,e[5]=o}else n=e[3],r=e[4],o=e[5];let a;e[6]!==t.icon?(a=t.icon&&L.jsx(Wr,{type:t.icon,className:"w-3.5 h-3.5"}),e[6]=t.icon,e[7]=a):a=e[7];let s;e[8]!==t.label?(s=L.jsx("span",{children:t.label}),e[8]=t.label,e[9]=s):s=e[9];let l;e[10]!==a||e[11]!==s?(l=L.jsxs("div",{className:"flex items-center gap-1.5",children:[a,s]}),e[10]=a,e[11]=s,e[12]=l):l=e[12];let u;e[13]!==t.subtitle?(u=t.subtitle&&L.jsx("span",{className:"text-[10px] text-muted-foreground truncate max-w-[120px]",children:t.subtitle}),e[13]=t.subtitle,e[14]=u):u=e[14];let c;e[15]!==l||e[16]!==u?(c=L.jsxs("div",{className:"flex flex-col items-start",children:[l,u]}),e[15]=l,e[16]=u,e[17]=c):c=e[17];let d;e[18]!==t.subtitle?(d=t.subtitle&&L.jsx("span",{className:"text-[10px] text-primary",children:"Edit"}),e[18]=t.subtitle,e[19]=d):d=e[19];let f;return e[20]!==n||e[21]!==r||e[22]!==o||e[23]!==c||e[24]!==d?(f=L.jsxs(n,{onSelect:r,className:o,children:[c,d]}),e[20]=n,e[21]=r,e[22]=o,e[23]=c,e[24]=d,e[25]=f):f=e[25],f}function vOt(t){const e=qt.c(9),{menuItemStyles:i}=tG(),n=t.label??"Remove panel",r=t.onClick;let o;e[0]!==i?(o=Hr(i,"cursor-pointer text-red-400 data-[highlighted]:bg-red-900/30"),e[0]=i,e[1]=o):o=e[1];let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(Wr,{type:dr.ACTION_DELETE,className:"w-3.5 h-3.5"}),e[2]=a):a=e[2];let s;e[3]!==n?(s=L.jsxs("div",{className:"flex items-center gap-1.5",children:[a,L.jsx("span",{children:n})]}),e[3]=n,e[4]=s):s=e[4];let l;return e[5]!==t.onClick||e[6]!==o||e[7]!==s?(l=L.jsx(dm,{onSelect:r,className:o,children:s}),e[5]=t.onClick,e[6]=o,e[7]=s,e[8]=l):l=e[8],l}Ri.Section=lOt;Ri.Divider=uOt;Ri.Toggle=cOt;Ri.NumberStepper=fOt;Ri.Button=gOt;Ri.RemoveButton=vOt;function vD(t){const e=qt.c(16);let i;e[0]!==t.className?(i=Hr("mx-2 mb-2",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;e[2]===Symbol.for("react.memo_cache_sentinel")?(n=L.jsx(Wr,{type:dr.STATUS_WARNING,className:"text-amber-500 dark:text-amber-400 w-4 h-4 flex-shrink-0"}),e[2]=n):n=e[2];let r;e[3]!==t.title?(r=L.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[n,L.jsx("p",{className:"text-xs font-medium text-amber-800 dark:text-amber-200 m-0",children:t.title})]}),e[3]=t.title,e[4]=r):r=e[4];let o;e[5]!==t.message?(o=L.jsx("div",{className:"ml-6 text-xs text-amber-700 dark:text-amber-300",children:t.message}),e[5]=t.message,e[6]=o):o=e[6];let a;e[7]!==t.suggestion?(a=t.suggestion&&L.jsx("p",{className:"ml-6 mt-1 text-xs text-amber-600 dark:text-amber-400 m-0",children:t.suggestion}),e[7]=t.suggestion,e[8]=a):a=e[8];let s;e[9]!==r||e[10]!==o||e[11]!==a?(s=L.jsxs("div",{className:"bg-amber-50 dark:bg-amber-950/30 border border-amber-200 dark:border-amber-800/50 rounded-md px-3 py-2",children:[r,o,a]}),e[9]=r,e[10]=o,e[11]=a,e[12]=s):s=e[12];let l;return e[13]!==i||e[14]!==s?(l=L.jsx("div",{className:i,children:s}),e[13]=i,e[14]=s,e[15]=l):l=e[15],l}function yOt(t){return t.length===0?null:L.jsx("div",{className:"space-y-2 mt-1",children:t.map((e,i)=>L.jsxs("div",{className:"text-xs text-muted-foreground space-y-0.5",children:[L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Namespace: "}),L.jsx("span",{className:"font-medium",children:e.namespace})]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Frame: "}),L.jsx("span",{className:"font-medium",children:e.frame})]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Signal: "}),L.jsx("span",{className:"font-medium",children:e.signal})]})]},i))})}function mOt(t,e){switch(e.type){case"add":return{panels:[...t.panels,e.panel],isDirty:!0};case"remove":return{panels:t.panels.filter(i=>i.id!==e.id),isDirty:!0};case"update":return{panels:t.panels.map(i=>i.id===e.id?e.updater(i):i),isDirty:!0};case"replace-all":return{panels:e.panels,isDirty:!1};case"mark-clean":return{...t,isDirty:!1};default:return t}}function VVe(t){return{...t,type:"trace",frames:[],bufferSize:1e4,expandSignals:!1,sortOrder:"newest-first",groupByFrame:!1,unresolvedFrames:void 0}}function HVe(t){return{...t,type:"timeseries",signals:[],useSuggestedMinMax:!1,syncCharts:!0,chartWidthSeconds:30,maxFps:60,unresolvedSignals:void 0}}function UVe(t){return{...t,type:"map",signals:{},unresolvedSignals:void 0}}function zVe(t){return{...t,type:"video",videoFilePath:void 0,recordingSessionPath:void 0,soundMuted:!0}}function $Ve(t){return{...t,type:"gauge",signals:[],heightConfig:150,unresolvedSignals:void 0}}const SJ=8;function WVe(t){return{...t,type:"frame-distribution",selectedNamespace:void 0,maxBinDistributionItems:SJ}}const bOt={timeseries:{w:6,h:4},gauge:{w:6,h:4},"frame-distribution":{w:6,h:4},map:{w:6,h:4},video:{w:6,h:4},trace:{w:6,h:4}};function SOt(t,e){const{w:i,h:n}=bOt[t],r={id:crypto.randomUUID(),type:t,grid:{x:0,y:e,w:i,h:n}};switch(t){case"trace":return VVe(r);case"timeseries":return HVe(r);case"map":return UVe(r);case"video":return zVe(r);case"gauge":return $Ve(r);case"frame-distribution":return WVe(r)}}function _Ot(){const t=qt.c(17);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e={panels:[],isDirty:!1},t[0]=e):e=t[0];const[i,n]=J.useReducer(mOt,e);let r;t[1]!==i.panels?(r=()=>i.panels.length===0?0:Math.max(...i.panels.map(COt)),t[1]=i.panels,t[2]=r):r=t[2];const o=r;let a;t[3]!==i.panels?(a=i.panels.some(POt),t[3]=i.panels,t[4]=a):a=t[4];const s=a;let l;t[5]!==o||t[6]!==s?(l=b=>{if(b==="frame-distribution"&&s)return;const S=SOt(b,o());n({type:"add",panel:S})},t[5]=o,t[6]=s,t[7]=l):l=t[7];const u=l;let c;t[8]===Symbol.for("react.memo_cache_sentinel")?(c=(b,S,_)=>{n({type:"update",id:b,updater:C=>C.type!==S?C:_(C)})},t[8]=c):c=t[8];const d=c;let f;t[9]===Symbol.for("react.memo_cache_sentinel")?(f=b=>{n({type:"remove",id:b})},t[9]=f):f=t[9];const h=f;let p;t[10]===Symbol.for("react.memo_cache_sentinel")?(p=b=>{n({type:"replace-all",panels:b})},t[10]=p):p=t[10];const g=p;let v;t[11]===Symbol.for("react.memo_cache_sentinel")?(v=()=>{n({type:"mark-clean"})},t[11]=v):v=t[11];const y=v;let m;return t[12]!==u||t[13]!==s||t[14]!==i.isDirty||t[15]!==i.panels?(m={panels:i.panels,isDirty:i.isDirty,hasFrameDistributionPanel:s,addPanel:u,updatePanel:d,removePanel:h,replaceAll:g,markClean:y},t[12]=u,t[13]=s,t[14]=i.isDirty,t[15]=i.panels,t[16]=m):m=t[16],m}function POt(t){return t.type==="frame-distribution"}function COt(t){return t.grid.y+t.grid.h}const GVe=J.createContext(null);function TOt(t){const e=qt.c(3),i=_Ot();let n;return e[0]!==t.children||e[1]!==i?(n=L.jsx(GVe.Provider,{value:i,children:t.children}),e[0]=t.children,e[1]=i,e[2]=n):n=e[2],n}function oC(){const t=J.useContext(GVe);if(!t)throw new Error("useDashboardPanelsContext must be used inside DashboardPanelsProvider");return t}const r1e=1e4;function xOt(t){const e=qt.c(9);let i;e[0]!==t.maxBinDistributionItems||e[1]!==t.onMaxBinDistributionItemsChange?(i=L.jsx(Ri.Section,{title:"Settings",children:L.jsx(Ri.NumberStepper,{label:"Distribution items",value:t.maxBinDistributionItems,onChange:t.onMaxBinDistributionItemsChange,min:4,max:100,step:1})}),e[0]=t.maxBinDistributionItems,e[1]=t.onMaxBinDistributionItemsChange,e[2]=i):i=e[2];let n;e[3]===Symbol.for("react.memo_cache_sentinel")?(n=L.jsx(Ri.Divider,{}),e[3]=n):n=e[3];let r;e[4]!==t.onRemove?(r=L.jsx(Ri.Section,{title:"Actions",children:L.jsx(Ri.RemoveButton,{onClick:t.onRemove})}),e[4]=t.onRemove,e[5]=r):r=e[5];let o;return e[6]!==i||e[7]!==r?(o=L.jsxs(Ri,{children:[i,n,r]}),e[6]=i,e[7]=r,e[8]=o):o=e[8],o}const EOt=36;function wOt(t){const e=qt.c(100),{track:i}=el(),{updatePanel:n,removePanel:r}=oC(),o=t.panelConfig,{isDarkMode:a}=dI();let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=[],e[0]=s):s=e[0];const[l,u]=J.useState(s),[c,d]=J.useState(o==null?void 0:o.selectedNamespace);let f;e[1]===Symbol.for("react.memo_cache_sentinel")?(f=[],e[1]=f):f=e[1];const[h,p]=J.useState(f),[g,v]=J.useState(400),[y,m]=J.useState(!1),b=J.useRef(null);let S;e[2]===Symbol.for("react.memo_cache_sentinel")?(S=[],e[2]=S):S=e[2];const _=J.useRef(S),C=J.useRef(null),P=J.useRef(0),x=Z1t(),{broker:E}=CNe();let A;e:{if(!(E!=null&&E.liveSignalService)||!c){let rt;e[3]===Symbol.for("react.memo_cache_sentinel")?(rt=new Map,e[3]=rt):rt=e[3],A=rt;break e}let Mt;if(e[4]!==E.liveSignalService||e[5]!==c){const rt=E.liveSignalService.listFrames(c);Mt=new Map(rt.filter(ROt).map(DOt)),e[4]=E.liveSignalService,e[5]=c,e[6]=Mt}else Mt=e[6];A=Mt}const R=A;let M,D;e[7]===Symbol.for("react.memo_cache_sentinel")?(M=()=>{if(!b.current)return;const Mt=new ResizeObserver(rt=>{for(const qe of rt){const vt=qe.contentRect.height;vt>0&&v(vt)}});return Mt.observe(b.current),()=>Mt.disconnect()},D=[],e[7]=M,e[8]=D):(M=e[7],D=e[8]),J.useEffect(M,D);let F;e[9]!==x||e[10]!==o||e[11]!==c?(F=()=>{(async()=>{if(!x){m(!0);return}const rt=await x.getNamespaceNames();u(rt),m(!0),o!=null&&o.selectedNamespace?(rt.includes(o.selectedNamespace),d(o.selectedNamespace)):rt.length>0&&!c&&d(rt[0])})()},e[9]=x,e[10]=o,e[11]=c,e[12]=F):F=e[12];const I=o==null?void 0:o.selectedNamespace;let V;e[13]!==x||e[14]!==c||e[15]!==I?(V=[x,I,c],e[13]=x,e[14]=c,e[15]=I,e[16]=V):V=e[16],J.useEffect(F,V);let z,G;e[17]!==x||e[18]!==l||e[19]!==c?(G=()=>{if(!x||!c||!l.includes(c))return;const Mt=vt=>{_.current.push(vt)},rt=OOt;return x.subscribeToFrameDistribution(c,Mt,rt)},z=[x,c,l],e[17]=x,e[18]=l,e[19]=c,e[20]=z,e[21]=G):(z=e[20],G=e[21]),J.useEffect(G,z);let H,U;if(e[22]===Symbol.for("react.memo_cache_sentinel")?(H=()=>{const Mt=rt=>{if(rt-P.current>=1e3){P.current=rt;const qe=_.current;if(qe.length>0){const kt=qe[qe.length-1].receivedTimestamp-r1e;p(Xe=>Xe.concat(qe).filter(_t=>_t.receivedTimestamp>kt)),_.current=[]}}C.current=requestAnimationFrame(Mt)};return C.current=requestAnimationFrame(Mt),()=>{C.current!==null&&cancelAnimationFrame(C.current)}},U=[],e[22]=H,e[23]=U):(H=e[22],U=e[23]),J.useEffect(H,U),!o)return null;let k;e[24]!==o.id||e[25]!==r||e[26]!==i?(k=()=>{r(o.id),i(Fi.RemovePanelFromDashboard,{panelType:"frame-distribution"})},e[24]=o.id,e[25]=r,e[26]=i,e[27]=k):k=e[27];const X=k;let W,Y,te,oe,de,ge,Ee,Re,Ae,Pe;if(e[28]!==x||e[29]!==l||e[30]!==y||e[31]!==o.id||e[32]!==c||e[33]!==n){const Mt=Jt=>{d(Jt),p([]),_.current=[],n(o.id,"frame-distribution",zt=>({...zt,selectedNamespace:Jt}))},rt=y&&!x,qe=y&&x&&l.length===0;let vt;e[44]!==x||e[45]!==l||e[46]!==y||e[47]!==c?(vt=y&&x&&c&&l.length>0&&!l.includes(c),e[44]=x,e[45]=l,e[46]=y,e[47]=c,e[48]=vt):vt=e[48],de=vt;let kt;e[49]!==c||e[50]!==de||e[51]!==qe||e[52]!==rt?(kt=()=>rt?L.jsx(vD,{title:"Frame distribution unavailable",message:"The frame distribution service is not available.",suggestion:"Ensure the broker is connected and streaming data."}):qe?L.jsx(vD,{title:"No namespaces available",message:"No signal namespaces are currently available for frame distribution.",suggestion:"Open a recording session or start streaming data from the broker."}):de?L.jsx(vD,{title:"Namespace not found",message:L.jsxs(L.Fragment,{children:["The configured namespace"," ",L.jsx("code",{className:"px-1 py-0.5 bg-neutral-800 rounded text-xs",children:c})," ","is not available."]}),suggestion:"Select a different namespace from the dropdown or remove this panel."}):null,e[49]=c,e[50]=de,e[51]=qe,e[52]=rt,e[53]=kt):kt=e[53],oe=kt,te=Ik;let Xe;e[54]===Symbol.for("react.memo_cache_sentinel")?(Xe=Hr("flex items-center gap-1 px-2 py-0.5 text-xs rounded","bg-muted hover:bg-muted/80 transition-colors","border border-border focus:outline-none","[&[data-state=open]>svg]:rotate-180"),e[54]=Xe):Xe=e[54];const _t=c||"Select namespace";let Ht;e[55]!==_t?(Ht=L.jsx("span",{className:"truncate max-w-[120px] text-xxs",children:_t}),e[55]=_t,e[56]=Ht):Ht=e[56];let Pt;e[57]===Symbol.for("react.memo_cache_sentinel")?(Pt=L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"w-3 h-3 transition-transform"}),e[57]=Pt):Pt=e[57],e[58]!==Ht?(Pe=L.jsx(Nk,{asChild:!0,children:L.jsxs("button",{className:Xe,children:[Ht,Pt]})}),e[58]=Ht,e[59]=Pe):Pe=e[59],Y=AD,W=Fk,ge="start",Ee=4,e[60]===Symbol.for("react.memo_cache_sentinel")?(Re=Hr("z-50 min-w-[150px] max-h-[310px] overflow-y-auto bg-popover border border-border rounded-md shadow-lg p-1","animate-in fade-in-0 zoom-in-95"),e[60]=Re):Re=e[60],Ae=l.map(Jt=>L.jsx(dm,{onSelect:()=>Mt(Jt),className:Hr("px-3 py-2 text-sm rounded-sm cursor-pointer outline-none","data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground",c===Jt&&"bg-accent"),children:Jt},Jt)),e[28]=x,e[29]=l,e[30]=y,e[31]=o.id,e[32]=c,e[33]=n,e[34]=W,e[35]=Y,e[36]=te,e[37]=oe,e[38]=de,e[39]=ge,e[40]=Ee,e[41]=Re,e[42]=Ae,e[43]=Pe}else W=e[34],Y=e[35],te=e[36],oe=e[37],de=e[38],ge=e[39],Ee=e[40],Re=e[41],Ae=e[42],Pe=e[43];let we;e[61]!==W||e[62]!==ge||e[63]!==Ee||e[64]!==Re||e[65]!==Ae?(we=L.jsx(W,{align:ge,sideOffset:Ee,className:Re,children:Ae}),e[61]=W,e[62]=ge,e[63]=Ee,e[64]=Re,e[65]=Ae,e[66]=we):we=e[66];let Te;e[67]!==Y||e[68]!==we?(Te=L.jsx(Y,{children:we}),e[67]=Y,e[68]=we,e[69]=Te):Te=e[69];let ke;e[70]!==te||e[71]!==Pe||e[72]!==Te?(ke=L.jsxs(te,{children:[Pe,Te]}),e[70]=te,e[71]=Pe,e[72]=Te,e[73]=ke):ke=e[73];const $e=ke,Ne=g-EOt,ve=Math.max(60,Math.floor(Ne*.3));let pe;e[74]!==oe?(pe=oe(),e[74]=oe,e[75]=pe):pe=e[75];const fe=pe,me=o.maxBinDistributionItems??SJ;let Ce;e[76]!==o.id||e[77]!==i||e[78]!==n?(Ce=Mt=>{n(o.id,"frame-distribution",rt=>({...rt,maxBinDistributionItems:Mt})),i(Fi.ChangePanelSetting,{panelType:"frame-distribution",setting:"maxBinDistributionItems",value:Mt})},e[76]=o.id,e[77]=i,e[78]=n,e[79]=Ce):Ce=e[79];let Ue;e[80]!==X||e[81]!==me||e[82]!==Ce?(Ue=L.jsx(xOt,{maxBinDistributionItems:me,onMaxBinDistributionItemsChange:Ce,onRemove:X}),e[80]=X,e[81]=me,e[82]=Ce,e[83]=Ue):Ue=e[83];const Qe=(!fe||de)&&$e;let it;e[84]!==Ue||e[85]!==Qe?(it=L.jsx(GI,{icon:dr.CONTEXT_DASHBOARD,helpTooltip:nOt,dropdown:Ue,children:Qe}),e[84]=Ue,e[85]=Qe,e[86]=it):it=e[86];let xt;e[87]!==fe||e[88]!==h||e[89]!==R||e[90]!==a||e[91]!==o.maxBinDistributionItems||e[92]!==t.panelId||e[93]!==ve?(xt=fe||L.jsx(JAt,{frameIdToNameMapping:R,graphWidthMs:r1e,data:h,shouldPauseStreaming:!1,showBinDistribution:!0,chartKey:t.panelId,height:ve,maxBinDistributionItems:o.maxBinDistributionItems??SJ,isDarkMode:a,clock:{time:AOt}}),e[87]=fe,e[88]=h,e[89]=R,e[90]=a,e[91]=o.maxBinDistributionItems,e[92]=t.panelId,e[93]=ve,e[94]=xt):xt=e[94];let wt;e[95]!==xt?(wt=L.jsx(YI,{fullHeight:!0,children:xt}),e[95]=xt,e[96]=wt):wt=e[96];let $t;return e[97]!==it||e[98]!==wt?($t=L.jsxs(WI,{ref:b,fullHeight:!0,children:[it,wt]}),e[97]=it,e[98]=wt,e[99]=$t):$t=e[99],$t}function AOt(){return Date.now()}function OOt(){console.log("[FrameDistributionPanel] Subscription ended")}function DOt(t){return[t.frameId,t.name]}function ROt(t){return t.frameId!==void 0}const MOt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Gauge"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Signals"}),": Add or remove signals via the panel menu",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Panel height"}),": Adjust in Settings (panel menu)"]})]}),LOt={cyber:{background:"conic-gradient(from 225deg, #0f0f23 0deg, #1a1a2e 180deg, #16213e 270deg)",trackBorder:"rgba(100, 100, 140, 0.3)",needleColor:"#e0e0f0",needleShadow:"0 0 12px rgba(0, 217, 255, 0.6)",textColor:"#e8e8f4",textShadow:"0 0 10px rgba(0, 217, 255, 0.5)",tickColor:"rgba(200, 200, 240, 0.6)",centerGlow:"radial-gradient(circle, rgba(0, 217, 255, 0.15) 0%, transparent 70%)",gradientStops:["#00d9ff","#00ffaa","#ff3366"],arcGlow:"rgba(0, 217, 255, 0.4)",capGradient:"radial-gradient(circle at 30% 30%, #4a4a6a 0%, #1a1a2e 100%)"},warm:{background:"conic-gradient(from 225deg, #1a0a0a 0deg, #2a1515 180deg, #1f0f0f 270deg)",trackBorder:"rgba(180, 100, 60, 0.3)",needleColor:"#fff0e0",needleShadow:"0 0 12px rgba(255, 149, 0, 0.6)",textColor:"#fff5e8",textShadow:"0 0 10px rgba(255, 149, 0, 0.5)",tickColor:"rgba(255, 200, 150, 0.6)",centerGlow:"radial-gradient(circle, rgba(255, 149, 0, 0.15) 0%, transparent 70%)",gradientStops:["#ff9500","#ffcc00","#ff2d55"],arcGlow:"rgba(255, 149, 0, 0.4)",capGradient:"radial-gradient(circle at 30% 30%, #5a3a2a 0%, #1a0a0a 100%)"},cool:{background:"conic-gradient(from 225deg, #0a1520 0deg, #0f2538 180deg, #0d1f30 270deg)",trackBorder:"rgba(80, 140, 200, 0.3)",needleColor:"#e8f4ff",needleShadow:"0 0 12px rgba(90, 200, 250, 0.6)",textColor:"#e8f4ff",textShadow:"0 0 10px rgba(90, 200, 250, 0.5)",tickColor:"rgba(150, 200, 255, 0.6)",centerGlow:"radial-gradient(circle, rgba(90, 200, 250, 0.15) 0%, transparent 70%)",gradientStops:["#5ac8fa","#64d2ff","#007aff"],arcGlow:"rgba(90, 200, 250, 0.4)",capGradient:"radial-gradient(circle at 30% 30%, #2a4a6a 0%, #0a1520 100%)"},mono:{background:"conic-gradient(from 225deg, #111111 0deg, #1a1a1a 180deg, #141414 270deg)",trackBorder:"rgba(120, 120, 120, 0.3)",needleColor:"#ffffff",needleShadow:"0 0 12px rgba(255, 255, 255, 0.4)",textColor:"#f0f0f0",textShadow:"0 0 10px rgba(255, 255, 255, 0.3)",tickColor:"rgba(180, 180, 180, 0.6)",centerGlow:"radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%)",gradientStops:["#888888","#bbbbbb","#dddddd"],arcGlow:"rgba(255, 255, 255, 0.3)",capGradient:"radial-gradient(circle at 30% 30%, #444 0%, #111 100%)"},neon:{background:"conic-gradient(from 225deg, #0a0015 0deg, #150028 180deg, #0d001a 270deg)",trackBorder:"rgba(255, 0, 255, 0.2)",needleColor:"#ff00ff",needleShadow:"0 0 20px rgba(255, 0, 255, 0.8), 0 0 40px rgba(255, 0, 255, 0.4)",textColor:"#ff66ff",textShadow:"0 0 15px rgba(255, 0, 255, 0.8)",tickColor:"rgba(255, 100, 255, 0.5)",centerGlow:"radial-gradient(circle, rgba(255, 0, 255, 0.2) 0%, transparent 70%)",gradientStops:["#ff00ff","#00ffff","#ffff00"],arcGlow:"rgba(255, 0, 255, 0.6)",capGradient:"radial-gradient(circle at 30% 30%, #3a0050 0%, #0a0015 100%)"},racing:{background:"conic-gradient(from 225deg, #1a0000 0deg, #2d0000 180deg, #200000 270deg)",trackBorder:"rgba(255, 50, 50, 0.3)",needleColor:"#ff3333",needleShadow:"0 0 15px rgba(255, 50, 50, 0.7)",textColor:"#ffffff",textShadow:"0 0 8px rgba(255, 50, 50, 0.5)",tickColor:"rgba(255, 255, 255, 0.7)",centerGlow:"radial-gradient(circle, rgba(255, 50, 50, 0.15) 0%, transparent 70%)",gradientStops:["#00ff00","#ffff00","#ff0000"],arcGlow:"rgba(255, 200, 0, 0.5)",capGradient:"radial-gradient(circle at 30% 30%, #4a2020 0%, #1a0000 100%)"},retro:{background:"conic-gradient(from 225deg, #2a2318 0deg, #3d3425 180deg, #32291c 270deg)",trackBorder:"rgba(200, 170, 120, 0.4)",needleColor:"#f5e6c8",needleShadow:"0 0 8px rgba(245, 200, 120, 0.4)",textColor:"#f5e6c8",textShadow:"none",tickColor:"rgba(200, 170, 120, 0.7)",centerGlow:"radial-gradient(circle, rgba(245, 200, 120, 0.1) 0%, transparent 70%)",gradientStops:["#c89b3c","#f0c060","#8b6914"],arcGlow:"rgba(200, 155, 60, 0.4)",capGradient:"radial-gradient(circle at 30% 30%, #5a4a30 0%, #2a2318 100%)"},ocean:{background:"conic-gradient(from 225deg, #001a2c 0deg, #002d4a 180deg, #00233a 270deg)",trackBorder:"rgba(0, 200, 200, 0.3)",needleColor:"#00ffff",needleShadow:"0 0 15px rgba(0, 255, 255, 0.6)",textColor:"#b0ffff",textShadow:"0 0 10px rgba(0, 255, 255, 0.5)",tickColor:"rgba(100, 220, 220, 0.6)",centerGlow:"radial-gradient(circle, rgba(0, 200, 200, 0.15) 0%, transparent 70%)",gradientStops:["#006080","#00b0b0","#00ffff"],arcGlow:"rgba(0, 200, 200, 0.5)",capGradient:"radial-gradient(circle at 30% 30%, #004060 0%, #001a2c 100%)"},forest:{background:"conic-gradient(from 225deg, #0a1a0a 0deg, #152815 180deg, #0f1f0f 270deg)",trackBorder:"rgba(100, 180, 100, 0.3)",needleColor:"#90ee90",needleShadow:"0 0 12px rgba(100, 200, 100, 0.5)",textColor:"#c0ffc0",textShadow:"0 0 8px rgba(100, 200, 100, 0.4)",tickColor:"rgba(150, 200, 150, 0.6)",centerGlow:"radial-gradient(circle, rgba(100, 180, 100, 0.12) 0%, transparent 70%)",gradientStops:["#228b22","#32cd32","#90ee90"],arcGlow:"rgba(100, 180, 100, 0.4)",capGradient:"radial-gradient(circle at 30% 30%, #2a4a2a 0%, #0a1a0a 100%)"},sunset:{background:"conic-gradient(from 225deg, #1a0a1a 0deg, #2d1528 180deg, #20101f 270deg)",trackBorder:"rgba(255, 100, 100, 0.3)",needleColor:"#ffa07a",needleShadow:"0 0 15px rgba(255, 160, 122, 0.6)",textColor:"#ffd0b0",textShadow:"0 0 10px rgba(255, 140, 100, 0.5)",tickColor:"rgba(255, 180, 150, 0.6)",centerGlow:"radial-gradient(circle, rgba(255, 140, 100, 0.15) 0%, transparent 70%)",gradientStops:["#ff6b6b","#ffa500","#ffdd00"],arcGlow:"rgba(255, 140, 100, 0.5)",capGradient:"radial-gradient(circle at 30% 30%, #5a3040 0%, #1a0a1a 100%)"}},kOt=42,z_=2*Math.PI*kOt,DO=z_*.75,IOt=(t,e)=>{const i=[],a=e==="analog"?t*2:t;for(let s=0;s<=a;s++){const l=-135+s/a*270,u=s%2===0,c=e==="analog"&&s%2!==0;i.push({angle:l,isMajor:u,isMinor:c})}return i},YVe=J.forwardRef((t,e)=>{const i=qt.c(6),{label:n,initialValue:r,minValue:o,maxValue:a,size:s,theme:l,variant:u}=t,c=r===void 0?50:r,d=o===void 0?0:o,f=a===void 0?100:a,h=s===void 0?200:s,p=l===void 0?"cyber":l,g=u===void 0?"modern":u,v=J.useRef(null),y=J.useRef(null),m=J.useRef(null),b=J.useRef(null);let S;i[0]!==f||i[1]!==d?(S={min:d,max:f},i[0]=f,i[1]=d,i[2]=S):S=i[2];const _=J.useRef(S),C=J.useRef(void 0),P=LOt[p],x=IOt(10,g),E=NOt;let A;i[3]!==c||i[4]!==P?(A=()=>({updateValue:G=>{if(G===C.current)return;C.current=G;const{min:H,max:U}=_.current,k=U-H;if(G===void 0)v.current&&(v.current.style.transform=`translate(-50%, -100%) rotate(${E(c,H,U)}deg)`,v.current.style.opacity="0.4"),y.current&&(y.current.textContent="--"),m.current&&(m.current.style.opacity="0.3"),b.current&&(b.current.style.opacity="0.3");else{const X=Math.max(H,Math.min(U,G)),W=E(X,H,U),Y=k>0?(X-H)/k:0;if(v.current&&(v.current.style.transform=`translate(-50%, -100%) rotate(${W}deg)`,v.current.style.opacity="1"),y.current&&(y.current.textContent=G.toFixed(1)),m.current){m.current.style.opacity="1";const te=Y*DO;m.current.style.strokeDasharray=`${te} ${z_}`}if(b.current){b.current.style.opacity="1";const te=Y*270;b.current.style.background=`conic-gradient(from 135deg, ${P.gradientStops[0]} 0deg, ${P.gradientStops[1]} ${te*.5}deg, ${P.gradientStops[2]} ${te}deg, transparent ${te}deg)`}}},updateBounds:(G,H)=>{_.current={min:G,max:H}}}),i[3]=c,i[4]=P,i[5]=A):A=i[5],J.useImperativeHandle(e,A);const R=E(c,d,f),M=(c-d)/(f-d),D=()=>{switch(g){case"classic":return I();case"minimal":return V();case"analog":return z();case"modern":default:return F()}},F=()=>L.jsxs("div",{style:{width:h,height:h,position:"relative",borderRadius:"50%",background:P.background,boxShadow:`
            inset 0 0 ${h*.15}px rgba(0, 0, 0, 0.5),
            0 ${h*.02}px ${h*.08}px rgba(0, 0, 0, 0.4)
          `,overflow:"hidden"},children:[L.jsx("div",{style:{position:"absolute",inset:0,background:P.centerGlow,pointerEvents:"none"}}),L.jsx("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"10%",width:"80%",height:"80%",transform:"rotate(135deg)"},children:L.jsx("circle",{cx:"50",cy:"50",r:"42",fill:"none",stroke:P.trackBorder,strokeWidth:"6",strokeLinecap:"round",strokeDasharray:`${DO} ${z_}`,strokeDashoffset:"0",style:{filter:`drop-shadow(0 0 4px ${P.trackBorder})`}})}),L.jsxs("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"10%",width:"80%",height:"80%",transform:"rotate(135deg)"},children:[L.jsx("defs",{children:L.jsxs("linearGradient",{id:`gauge-gradient-${n}-modern`,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[L.jsx("stop",{offset:"0%",stopColor:P.gradientStops[0]}),L.jsx("stop",{offset:"50%",stopColor:P.gradientStops[1]}),L.jsx("stop",{offset:"100%",stopColor:P.gradientStops[2]})]})}),L.jsx("circle",{ref:m,cx:"50",cy:"50",r:"42",fill:"none",stroke:`url(#gauge-gradient-${n}-modern)`,strokeWidth:"6",strokeLinecap:"round",strokeDasharray:`${M*DO} ${z_}`,strokeDashoffset:"0",style:{transition:"stroke-dasharray 0.1s ease-out",filter:`drop-shadow(0 0 6px ${P.arcGlow})`}})]}),x.map((G,H)=>L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:G.isMajor?"2px":"1px",height:G.isMajor?`${h*.08}px`:`${h*.05}px`,background:P.tickColor,transformOrigin:"center top",transform:`translate(-50%, 0) rotate(${G.angle}deg) translateY(${-h*.38}px)`,borderRadius:"1px"}},H)),L.jsx("div",{ref:v,style:{position:"absolute",left:"50%",top:"50%",width:"4px",height:`${h*.35}px`,background:`linear-gradient(to top, ${P.needleColor} 0%, rgba(255,255,255,0.6) 100%)`,transformOrigin:"center bottom",transform:`translate(-50%, -100%) rotate(${R}deg)`,borderRadius:"2px 2px 0 0",boxShadow:P.needleShadow,transition:"transform 0.1s ease-out"}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${h*.12}px`,height:`${h*.12}px`,background:P.capGradient,borderRadius:"50%",transform:"translate(-50%, -50%)",boxShadow:"inset 0 -2px 4px rgba(0, 0, 0, 0.5), 0 2px 8px rgba(0, 0, 0, 0.4)"}}),L.jsx("div",{style:{position:"absolute",bottom:`${h*.18}px`,left:"50%",transform:"translateX(-50%)",textAlign:"center"},children:L.jsx("span",{ref:y,style:{fontFamily:"'JetBrains Mono', 'Fira Code', 'SF Mono', monospace",fontSize:`${h*.14}px`,fontWeight:600,color:P.textColor,textShadow:P.textShadow,letterSpacing:"-0.02em"},children:c.toFixed(1)})}),L.jsx("span",{style:{position:"absolute",bottom:`${h*.08}px`,left:`${h*.15}px`,fontFamily:"'JetBrains Mono', 'Fira Code', 'SF Mono', monospace",fontSize:`${h*.055}px`,color:"rgba(200, 200, 220, 0.5)"},children:d}),L.jsx("span",{style:{position:"absolute",bottom:`${h*.08}px`,right:`${h*.15}px`,fontFamily:"'JetBrains Mono', 'Fira Code', 'SF Mono', monospace",fontSize:`${h*.055}px`,color:"rgba(200, 200, 220, 0.5)"},children:f})]}),I=()=>L.jsxs("div",{style:{width:h,height:h,position:"relative",borderRadius:"50%",background:P.background,boxShadow:`
            inset 0 0 ${h*.2}px rgba(0, 0, 0, 0.6),
            0 ${h*.03}px ${h*.1}px rgba(0, 0, 0, 0.5),
            inset 0 ${h*.02}px ${h*.05}px rgba(255, 255, 255, 0.05)
          `,overflow:"hidden"},children:[L.jsx("div",{style:{position:"absolute",inset:0,background:P.centerGlow,pointerEvents:"none"}}),L.jsx("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"8%",width:"84%",height:"84%",transform:"rotate(135deg)"},children:L.jsx("circle",{cx:"50",cy:"50",r:"40",fill:"none",stroke:P.trackBorder,strokeWidth:"12",strokeLinecap:"butt",strokeDasharray:`${DO*.95} ${z_}`,strokeDashoffset:"0"})}),L.jsxs("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"8%",width:"84%",height:"84%",transform:"rotate(135deg)"},children:[L.jsx("defs",{children:L.jsxs("linearGradient",{id:`gauge-gradient-${n}-classic`,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[L.jsx("stop",{offset:"0%",stopColor:P.gradientStops[0]}),L.jsx("stop",{offset:"50%",stopColor:P.gradientStops[1]}),L.jsx("stop",{offset:"100%",stopColor:P.gradientStops[2]})]})}),L.jsx("circle",{ref:m,cx:"50",cy:"50",r:"40",fill:"none",stroke:`url(#gauge-gradient-${n}-classic)`,strokeWidth:"12",strokeLinecap:"butt",strokeDasharray:`${M*DO*.95} ${z_}`,strokeDashoffset:"0",style:{transition:"stroke-dasharray 0.1s ease-out",filter:`drop-shadow(0 0 8px ${P.arcGlow})`}})]}),x.filter(FOt).map((G,H)=>L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:"3px",height:`${h*.1}px`,background:P.tickColor,transformOrigin:"center top",transform:`translate(-50%, 0) rotate(${G.angle}deg) translateY(${-h*.42}px)`,borderRadius:"1px"}},H)),L.jsx("div",{ref:v,style:{position:"absolute",left:"50%",top:"50%",width:"0",height:"0",borderLeft:`${h*.02}px solid transparent`,borderRight:`${h*.02}px solid transparent`,borderBottom:`${h*.35}px solid ${P.needleColor}`,transformOrigin:"center bottom",transform:`translate(-50%, -100%) rotate(${R}deg)`,filter:`drop-shadow(${P.needleShadow})`,transition:"transform 0.1s ease-out"}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${h*.18}px`,height:`${h*.18}px`,background:P.capGradient,borderRadius:"50%",transform:"translate(-50%, -50%)",boxShadow:"inset 0 -3px 6px rgba(0, 0, 0, 0.5), 0 3px 10px rgba(0, 0, 0, 0.5)"}}),L.jsx("div",{style:{position:"absolute",bottom:`${h*.22}px`,left:"50%",transform:"translateX(-50%)",textAlign:"center"},children:L.jsx("span",{ref:y,style:{fontFamily:"'Georgia', serif",fontSize:`${h*.12}px`,fontWeight:700,color:P.textColor,textShadow:P.textShadow},children:c.toFixed(1)})})]}),V=()=>L.jsxs("div",{style:{width:h,height:h,position:"relative",borderRadius:"50%",background:"transparent"},children:[L.jsx("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"5%",width:"90%",height:"90%",transform:"rotate(135deg)"},children:L.jsx("circle",{cx:"50",cy:"50",r:"45",fill:"none",stroke:P.trackBorder,strokeWidth:"2",strokeLinecap:"round",strokeDasharray:`${DO*1.07} ${z_}`,strokeDashoffset:"0"})}),L.jsx("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"5%",width:"90%",height:"90%",transform:"rotate(135deg)"},children:L.jsx("circle",{ref:m,cx:"50",cy:"50",r:"45",fill:"none",stroke:P.gradientStops[1],strokeWidth:"3",strokeLinecap:"round",strokeDasharray:`${M*DO*1.07} ${z_}`,strokeDashoffset:"0",style:{transition:"stroke-dasharray 0.1s ease-out",filter:`drop-shadow(0 0 4px ${P.arcGlow})`}})}),L.jsx("div",{ref:v,style:{position:"absolute",left:"50%",top:"50%",width:"2px",height:`${h*.4}px`,background:P.needleColor,transformOrigin:"center bottom",transform:`translate(-50%, -100%) rotate(${R}deg)`,borderRadius:"1px",boxShadow:P.needleShadow,transition:"transform 0.1s ease-out"}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${h*.05}px`,height:`${h*.05}px`,background:P.needleColor,borderRadius:"50%",transform:"translate(-50%, -50%)",boxShadow:P.needleShadow}}),L.jsx("div",{style:{position:"absolute",bottom:`${h*.28}px`,left:"50%",transform:"translateX(-50%)",textAlign:"center"},children:L.jsx("span",{ref:y,style:{fontFamily:"'Helvetica Neue', sans-serif",fontSize:`${h*.16}px`,fontWeight:300,color:P.textColor,letterSpacing:"-0.03em"},children:c.toFixed(1)})})]}),z=()=>{const G=M*270;return L.jsxs("div",{style:{width:h,height:h,position:"relative",borderRadius:"50%",background:P.background,boxShadow:`
              inset 0 0 ${h*.15}px rgba(0, 0, 0, 0.6),
              0 ${h*.02}px ${h*.1}px rgba(0, 0, 0, 0.5),
              inset 0 0 ${h*.02}px rgba(255, 255, 255, 0.1)
            `,overflow:"hidden"},children:[L.jsx("div",{style:{position:"absolute",inset:0,background:P.centerGlow,pointerEvents:"none"}}),L.jsx("div",{ref:b,style:{position:"absolute",inset:"12%",width:"76%",height:"76%",borderRadius:"50%",background:`conic-gradient(from 135deg, ${P.gradientStops[0]} 0deg, ${P.gradientStops[1]} ${G*.5}deg, ${P.gradientStops[2]} ${G}deg, transparent ${G}deg)`,mask:"radial-gradient(circle at 50% 50%, transparent 70%, black 70%)",WebkitMask:"radial-gradient(circle at 50% 50%, transparent 70%, black 70%)",transition:"background 0.1s ease-out",filter:`drop-shadow(0 0 6px ${P.arcGlow})`}}),L.jsx("div",{style:{position:"absolute",inset:"12%",width:"76%",height:"76%",borderRadius:"50%",background:`conic-gradient(from 135deg, ${P.trackBorder} 0deg, ${P.trackBorder} 270deg, transparent 270deg)`,mask:"radial-gradient(circle at 50% 50%, transparent 70%, black 70%)",WebkitMask:"radial-gradient(circle at 50% 50%, transparent 70%, black 70%)",opacity:.5,zIndex:-1}}),x.map((H,U)=>L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:H.isMajor?"2.5px":"1px",height:H.isMajor?`${h*.1}px`:`${h*.05}px`,background:H.isMajor?P.tickColor:`${P.tickColor}80`,transformOrigin:"center top",transform:`translate(-50%, 0) rotate(${H.angle}deg) translateY(${-h*.4}px)`,borderRadius:"0.5px"}},U)),L.jsx("div",{ref:v,style:{position:"absolute",left:"50%",top:"50%",width:`${h*.06}px`,height:`${h*.38}px`,background:`linear-gradient(90deg, ${P.needleColor}dd 0%, ${P.needleColor} 50%, ${P.needleColor}aa 100%)`,clipPath:"polygon(40% 100%, 60% 100%, 55% 8%, 50% 0%, 45% 8%)",transformOrigin:"50% 100%",transform:`translate(-50%, -100%) rotate(${R}deg)`,boxShadow:P.needleShadow,transition:"transform 0.1s ease-out"}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${h*.14}px`,height:`${h*.14}px`,background:P.capGradient,borderRadius:"50%",transform:"translate(-50%, -50%)",boxShadow:"inset 0 -2px 6px rgba(0, 0, 0, 0.5), 0 2px 10px rgba(0, 0, 0, 0.4)"}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${h*.06}px`,height:`${h*.06}px`,background:"radial-gradient(circle at 30% 30%, #aaa 0%, #444 100%)",borderRadius:"50%",transform:"translate(-50%, -50%)"}}),L.jsx("div",{style:{position:"absolute",bottom:`${h*.2}px`,left:"50%",transform:"translateX(-50%)",textAlign:"center",background:"rgba(0,0,0,0.3)",padding:`${h*.02}px ${h*.05}px`,borderRadius:`${h*.02}px`},children:L.jsx("span",{ref:y,style:{fontFamily:"'Courier New', monospace",fontSize:`${h*.11}px`,fontWeight:700,color:P.textColor,textShadow:P.textShadow,letterSpacing:"0.05em"},children:c.toFixed(1)})}),L.jsx("span",{style:{position:"absolute",bottom:`${h*.1}px`,left:`${h*.12}px`,fontFamily:"'Courier New', monospace",fontSize:`${h*.05}px`,color:P.tickColor},children:d}),L.jsx("span",{style:{position:"absolute",bottom:`${h*.1}px`,right:`${h*.12}px`,fontFamily:"'Courier New', monospace",fontSize:`${h*.05}px`,color:P.tickColor},children:f})]})};return D()});YVe.displayName="CSSGauge";function NOt(t,e,i){const n=i-e;return-135+(n>0?(t-e)/n:0)*270}function FOt(t,e){return e%2===0}const BOt=t=>t>66?"#FF1133":t>33?"#FFBB00":"#44DD66",jOt=async(t,e,i,n,r)=>{const{wasmContext:o,sciChartSurface:a}=await Gt.SciChartPolarSurface.create(t,{padding:new Gt.Thickness(10,10,10,10)}),s=Math.PI*1.5,l=new Gt.NumberRange(i,n),u=["#44DD66","#FFBB00","#FF1133"],c=n-i,d=[i+c*.33,i+c*.66,n],f=new Gt.PolarNumericAxis(o,{polarAxisMode:Gt.EPolarAxisMode.Angular,visibleRange:l,flippedCoordinates:!0,totalAngle:s,startAngle:(Math.PI-s)/2,isVisible:!1});r.angularXAxis=f,a.xAxes.add(f);const h=new Gt.PolarNumericAxis(o,{polarAxisMode:Gt.EPolarAxisMode.Radial,isVisible:!1});a.yAxes.add(h);const p=new Gt.PolarArcAnnotation({y1:9.4,y2:7,x1:i,x2:n,fill:"#88888822",strokeThickness:0});r.backgroundArc=p,a.annotations.add(p);const g=new Gt.PolarArcAnnotation({y1:9.4,y2:7,x1:i,x2:e,fill:"#44DD66",strokeThickness:0});r.valueArc=g,a.annotations.add(g),d.forEach((b,S)=>{const _=new Gt.PolarArcAnnotation({y1:10,y2:9.7,x1:d[S-1]??i,x2:b,fill:u[S],strokeThickness:0});a.annotations.add(_)});const v=new Gt.PolarPointerAnnotation({x1:e,y1:7,pointerCenterStyle:{size:.15,stroke:"#666",strokeWidth:5,fill:"#333"},pointerStyle:{fill:"#666",stroke:"#666",strokeWidth:0,backExtensionSize:.2,baseSize:.1}});r.pointer=v,a.annotations.add(v);const y=(i+n)/2,m=new Gt.NativeTextAnnotation({text:`${e.toFixed(1)}`,fontSize:14,textColor:"#fff",x1:y,y1:-2,xCoordinateMode:Gt.ECoordinateMode.DataValue,yCoordinateMode:Gt.ECoordinateMode.DataValue,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Top});return r.text=m,a.annotations.add(m),{sciChartSurface:a,wasmContext:o}},qVe=J.forwardRef((t,e)=>{const i=qt.c(16),{initialValue:n,minValue:r,maxValue:o,size:a}=t,s=n===void 0?50:n,l=r===void 0?0:r,u=o===void 0?100:o,c=a===void 0?200:a;let d;i[0]===Symbol.for("react.memo_cache_sentinel")?(d={valueArc:null,pointer:null,text:null,backgroundArc:null,angularXAxis:null},i[0]=d):d=i[0];const f=J.useRef(d),h=J.useRef(void 0);let p;i[1]!==s||i[2]!==u||i[3]!==l?(p={initialValue:s,minValue:l,maxValue:u},i[1]=s,i[2]=u,i[3]=l,i[4]=p):p=i[4];const g=J.useRef(p);let v;i[5]!==u||i[6]!==l?(v={min:l,max:u},i[5]=u,i[6]=l,i[7]=v):v=i[7];const y=J.useRef(v),m=VOt;let b;i[8]!==s?(b=()=>({updateValue:E=>{const A=f.current;if(!A.valueArc||!A.pointer||!A.text||E===h.current)return;h.current=E;const{min:R,max:M}=y.current;if(E===void 0)A.valueArc.x2=s,A.valueArc.fill=m(s,R,M),A.pointer.x1=s,A.text.text="--";else{const D=Math.max(R,Math.min(M,E));A.valueArc.x2=D,A.valueArc.fill=m(D,R,M),A.pointer.x1=D,A.text.text=`${E.toFixed(1)}`}},updateBounds:(E,A)=>{const R=f.current;!R.angularXAxis||!R.backgroundArc||(y.current={min:E,max:A},R.angularXAxis.visibleRange=new Gt.NumberRange(E,A),R.backgroundArc.x1=E,R.backgroundArc.x2=A,R.text&&(R.text.x1=(E+A)/2),R.valueArc&&(R.valueArc.x1=E))}}),i[8]=s,i[9]=b):b=i[9],J.useImperativeHandle(e,b);let S;i[10]===Symbol.for("react.memo_cache_sentinel")?(S=E=>{const{initialValue:A,minValue:R,maxValue:M}=g.current;return jOt(E,A,R,M,f.current)},i[10]=S):S=i[10];const _=S;let C;i[11]!==c?(C={height:c,width:c},i[11]=c,i[12]=C):C=i[12];let P;i[13]===Symbol.for("react.memo_cache_sentinel")?(P=L.jsx($I.SciChartReact,{initChart:_,style:{width:"100%",height:"100%"}}),i[13]=P):P=i[13];let x;return i[14]!==C?(x=L.jsx("div",{style:C,children:P}),i[14]=C,i[15]=x):x=i[15],x});qVe.displayName="Gauge";function VOt(t,e,i){const n=i-e,r=n>0?(t-e)/n*100:50;return BOt(r)}const Og={background:"#1a1a2e",inactive:"#333344",active:"#44DD66",activeHighlight:"#66FF88",reverse:"#FF6644",neutral:"#FFBB00",textInactive:"#888899",border:"#444455"},HOt=["P","R","N","D"],fne=(t,e)=>t==="R"?Og.reverse:t==="N"?Og.neutral:Og.active;class XVe{constructor(){this.fillPaletteMode=Gt.EFillPaletteMode.SOLID,this.inactiveColor=Gt.parseColorToUIntArgb(Og.inactive)}onAttached(e){}onDetached(){}overrideFillArgb(){return this.inactiveColor}}const UOt=async(t,e,i,n)=>{const{sciChartSurface:r,wasmContext:o}=await Gt.SciChartSurface.create(t,{padding:new Gt.Thickness(5,10,15,10)}),a=e.length,s=1,l=.2,u=a*(s+l)-l,c=new Gt.NumericAxis(o,{isVisible:!1,visibleRange:new Gt.NumberRange(-.5,u+.5)});r.xAxes.add(c);const d=new Gt.NumericAxis(o,{isVisible:!1,visibleRange:new Gt.NumberRange(-.5,2)});r.yAxes.add(d);const f=[],h=[],p=[],g=[];e.forEach((P,x)=>{const E=x*(s+l);f.push(E),h.push(0),p.push(E+s),g.push(1)});const v=new Gt.XyxyDataSeries(o,{xValues:f,yValues:h,x1Values:p,y1Values:g}),y=new Gt.FastRectangleRenderableSeries(o,{dataSeries:v,columnXMode:Gt.EColumnMode.StartEnd,columnYMode:Gt.EColumnYMode.TopBottom,stroke:Og.border,strokeThickness:2,paletteProvider:new XVe});r.renderableSeries.add(y);const m=i*(s+l),b=new Gt.XyxyDataSeries(o,{xValues:[m],yValues:[0],x1Values:[m+s],y1Values:[1]}),S=fne(e[i]),_=new Gt.FastRectangleRenderableSeries(o,{dataSeries:b,columnXMode:Gt.EColumnMode.StartEnd,columnYMode:Gt.EColumnYMode.TopBottom,stroke:Og.activeHighlight,strokeThickness:3,fill:S});r.renderableSeries.add(_),n.activeRectSeries=_,n.activeDataSeries=b;const C=[];return e.forEach((P,x)=>{const E=x*(s+l)+s/2,A=x===i,R=new Gt.TextAnnotation({x1:E,y1:.5,text:P,fontSize:18,fontWeight:"bold",textColor:A?"#000000":Og.textInactive,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Center});r.annotations.add(R),C.push(R)}),n.gearLabels=C,{sciChartSurface:r,wasmContext:o}},zOt=async(t,e,i,n)=>{const{sciChartSurface:r,wasmContext:o}=await Gt.SciChartSurface.create(t,{theme:{type:"Dark",sciChartBackground:"transparent",loadingAnimationBackground:"transparent"},padding:new Gt.Thickness(10,5,10,5)}),a=e.length,s=1,l=.15,u=a*(s+l)-l,c=new Gt.NumericAxis(o,{isVisible:!1,visibleRange:new Gt.NumberRange(-.3,1.3)});r.xAxes.add(c);const d=new Gt.NumericAxis(o,{isVisible:!1,visibleRange:new Gt.NumberRange(-.5,u+.5),flippedCoordinates:!0});r.yAxes.add(d);const f=[],h=[],p=[],g=[];e.forEach((P,x)=>{const E=x*(s+l);f.push(0),h.push(E),p.push(1),g.push(E+s)});const v=new Gt.XyxyDataSeries(o,{xValues:f,yValues:h,x1Values:p,y1Values:g}),y=new Gt.FastRectangleRenderableSeries(o,{dataSeries:v,columnXMode:Gt.EColumnMode.StartEnd,columnYMode:Gt.EColumnYMode.TopBottom,stroke:Og.border,strokeThickness:2,paletteProvider:new XVe});r.renderableSeries.add(y);const m=i*(s+l),b=new Gt.XyxyDataSeries(o,{xValues:[0],yValues:[m],x1Values:[1],y1Values:[m+s]}),S=fne(e[i]),_=new Gt.FastRectangleRenderableSeries(o,{dataSeries:b,columnXMode:Gt.EColumnMode.StartEnd,columnYMode:Gt.EColumnYMode.TopBottom,stroke:Og.activeHighlight,strokeThickness:3,fill:S});r.renderableSeries.add(_),n.activeRectSeries=_,n.activeDataSeries=b;const C=[];return e.forEach((P,x)=>{const E=x*(s+l)+s/2,A=x===i,R=new Gt.TextAnnotation({x1:.5,y1:E,text:P,fontSize:16,fontWeight:"bold",textColor:A?"#000000":Og.textInactive,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Center});r.annotations.add(R),C.push(R)}),n.gearLabels=C,{sciChartSurface:r,wasmContext:o}},KVe=J.forwardRef((t,e)=>{const i=qt.c(16),{initialGear:n,gears:r,orientation:o,size:a}=t,s=n===void 0?0:n,l=r===void 0?HOt:r,u=o===void 0?"horizontal":o,c=a===void 0?200:a;let d;i[0]===Symbol.for("react.memo_cache_sentinel")?(d={activeRectSeries:null,activeDataSeries:null,gearLabels:[]},i[0]=d):d=i[0];const f=J.useRef(d),h=J.useRef(void 0),p=J.useRef(null);let g;i[1]!==l||i[2]!==s||i[3]!==u?(g={gears:l,initialGear:s,orientation:u},i[1]=l,i[2]=s,i[3]=u,i[4]=g):g=i[4];const v=J.useRef(g);let y;i[5]!==l||i[6]!==s||i[7]!==u?(y=()=>({updateValue:x=>{const E=f.current;if(!E.activeDataSeries||!E.activeRectSeries)return;const A=x!==void 0?Math.max(0,Math.min(l.length-1,Math.round(x))):s;if(A===h.current)return;h.current=A;const R=u==="horizontal"?.2:.15;if(u==="horizontal"){const D=A*(1+R);E.activeDataSeries.clear(),E.activeDataSeries.append(D,0,D+1,1)}else{const D=A*(1+R);E.activeDataSeries.clear(),E.activeDataSeries.append(0,D,1,D+1)}const M=fne(l[A]);E.activeRectSeries.fill=M,E.gearLabels.forEach((D,F)=>{D.textColor=F===A?"#000000":Og.textInactive}),p.current&&(p.current.textContent=`Current: ${x!==void 0?l[A]:"--"}`)},updateBounds:$Ot}),i[5]=l,i[6]=s,i[7]=u,i[8]=y):y=i[8],J.useImperativeHandle(e,y);let m;i[9]===Symbol.for("react.memo_cache_sentinel")?(m=x=>{const{gears:E,initialGear:A,orientation:R}=v.current;return(R==="horizontal"?UOt:zOt)(x,E,A,f.current)},i[9]=m):m=i[9];const b=m;let S;i[10]!==u||i[11]!==c?(S=u==="horizontal"?{width:c,height:c*.4}:{width:c*.3,height:c},i[10]=u,i[11]=c,i[12]=S):S=i[12];const _=S;let C;i[13]===Symbol.for("react.memo_cache_sentinel")?(C={display:"flex",flexDirection:"column",alignItems:"center"},i[13]=C):C=i[13];let P;return i[14]!==_?(P=L.jsx("div",{style:C,children:L.jsx($I.SciChartReact,{initChart:b,style:{..._,border:"1px solid #333",borderRadius:"8px",backgroundColor:Og.background}})}),i[14]=_,i[15]=P):P=i[15],P});KVe.displayName="GearGauge";function $Ot(t,e){}const WOt={default:{plateColor:"linear-gradient(180deg, #333 0%, #222 50%, #111 100%)",borderColor:"#444",borderWidth:4,needleColor:"#f00",needleShadow:"0 0 10px rgba(255, 0, 0, 0.5)",valueColor:"#fff",unitColor:"#aaa",majorTickColor:"#fff",minorTickColor:"#888",numberColor:"#fff",highlightStart:.8,highlightEnd:1,highlightColor:"rgba(255, 0, 0, 0.3)",innerShadow:!0,colorBarGradient:["#0f0","#ff0","#f00"]},"car-speedometer":{plateColor:"radial-gradient(circle at 30% 30%, #2a2a2a 0%, #0a0a0a 100%)",borderColor:"#555",borderWidth:6,needleColor:"#ff3300",needleShadow:"0 0 15px rgba(255, 51, 0, 0.7)",valueColor:"#fff",unitColor:"#888",majorTickColor:"#fff",minorTickColor:"#666",numberColor:"#fff",highlightStart:.75,highlightEnd:1,highlightColor:"rgba(255, 0, 0, 0.25)",innerShadow:!0,colorBarGradient:["#00ff00","#ffff00","#ff0000"]},industrial:{plateColor:"linear-gradient(180deg, #e8e8e8 0%, #c8c8c8 100%)",borderColor:"#333",borderWidth:5,needleColor:"#333",needleShadow:"2px 2px 4px rgba(0, 0, 0, 0.3)",valueColor:"#222",unitColor:"#555",majorTickColor:"#333",minorTickColor:"#999",numberColor:"#222",highlightStart:.7,highlightEnd:1,highlightColor:"rgba(255, 100, 0, 0.3)",innerShadow:!1,colorBarGradient:["#00aa00","#aaaa00","#ff5500"]},compass:{plateColor:"radial-gradient(circle, #1a1a2e 0%, #16213e 50%, #0f0f23 100%)",borderColor:"#4a4a6a",borderWidth:4,needleColor:"#e74c3c",needleShadow:"0 0 12px rgba(231, 76, 60, 0.6)",valueColor:"#ecf0f1",unitColor:"#95a5a6",majorTickColor:"#ecf0f1",minorTickColor:"#7f8c8d",numberColor:"#ecf0f1",highlightStart:0,highlightEnd:0,highlightColor:"transparent",innerShadow:!0,colorBarGradient:["#3498db","#3498db","#3498db"]},temperature:{plateColor:"radial-gradient(circle at 40% 40%, #1a0a0a 0%, #2d0000 100%)",borderColor:"#8b0000",borderWidth:4,needleColor:"#ff6347",needleShadow:"0 0 12px rgba(255, 99, 71, 0.6)",valueColor:"#ffd700",unitColor:"#ff8c00",majorTickColor:"#ff8c00",minorTickColor:"#8b4513",numberColor:"#ffa500",highlightStart:.65,highlightEnd:1,highlightColor:"rgba(255, 0, 0, 0.35)",innerShadow:!0,colorBarGradient:["#00bfff","#ffd700","#ff4500"]},fuel:{plateColor:"radial-gradient(circle at 30% 30%, #2a2a2a 0%, #1a1a1a 100%)",borderColor:"#4a4a4a",borderWidth:3,needleColor:"#f39c12",needleShadow:"0 0 8px rgba(243, 156, 18, 0.5)",valueColor:"#fff",unitColor:"#888",majorTickColor:"#fff",minorTickColor:"#555",numberColor:"#ddd",highlightStart:0,highlightEnd:.15,highlightColor:"rgba(255, 0, 0, 0.35)",innerShadow:!0,colorBarGradient:["#ff0000","#ffff00","#00ff00"]},rpm:{plateColor:"radial-gradient(circle at 30% 30%, #0a0a0a 0%, #000 100%)",borderColor:"#333",borderWidth:5,needleColor:"#ff0000",needleShadow:"0 0 20px rgba(255, 0, 0, 0.8)",valueColor:"#fff",unitColor:"#ff0000",majorTickColor:"#fff",minorTickColor:"#444",numberColor:"#fff",highlightStart:.75,highlightEnd:1,highlightColor:"rgba(255, 0, 0, 0.4)",innerShadow:!0,colorBarGradient:["#00ff00","#ffff00","#ff0000"]},voltage:{plateColor:"radial-gradient(circle at 30% 30%, #001a33 0%, #000d1a 100%)",borderColor:"#0066cc",borderWidth:4,needleColor:"#00ff88",needleShadow:"0 0 15px rgba(0, 255, 136, 0.7)",valueColor:"#00ff88",unitColor:"#0099ff",majorTickColor:"#0099ff",minorTickColor:"#004466",numberColor:"#00ccff",highlightStart:.85,highlightEnd:1,highlightColor:"rgba(255, 0, 0, 0.3)",innerShadow:!0,colorBarGradient:["#00ff00","#00ff88","#ff0000"]}},GOt=t=>{const e=[];for(let o=0;o<=t;o++){const a=-135+o/t*270,s=o/t;e.push({angle:a,percent:s})}return e},YOt=(t,e)=>{const i=[],a=t*e;for(let s=0;s<=a;s++){if(s%e===0)continue;const l=-135+s/a*270;i.push({angle:l})}return i},ZVe=J.forwardRef(({label:t,initialValue:e=50,minValue:i=0,maxValue:n=100,size:r=200,preset:o="default",unit:a=""},s)=>{const l=J.useRef(null),u=J.useRef(null),c=J.useRef(null),d=J.useRef({min:i,max:n}),f=J.useRef(void 0),h=WOt[o],p=GOt(10),g=YOt(10,5),v=J.useCallback((P,x,E)=>{const A=E-x;return-135+(A>0?(P-x)/A:0)*270},[]),y=P=>Math.abs(P)>=1e3?P.toFixed(0):(Math.abs(P)>=100,P.toFixed(1)),m=()=>{const P=[],{min:x,max:E}=d.current,A=E-x,R=10;for(let M=0;M<=R;M++){const D=x+M/R*A,F=-135+M/R*270,I=F*Math.PI/180,V=.68,z=50+V*50*Math.sin(I),G=50-V*50*Math.cos(I);P.push({value:Math.round(D*10)/10,x:z,y:G,angle:F})}return P};J.useImperativeHandle(s,()=>({updateValue:P=>{if(P===f.current)return;f.current=P;const{min:x,max:E}=d.current;if(P===void 0)l.current&&(l.current.style.transform=`translate(-50%, -100%) rotate(${v(e,x,E)}deg)`,l.current.style.opacity="0.4"),u.current&&(u.current.textContent="--");else{const A=Math.max(x,Math.min(E,P)),R=v(A,x,E);l.current&&(l.current.style.transform=`translate(-50%, -100%) rotate(${R}deg)`,l.current.style.opacity="1"),u.current&&(u.current.textContent=y(P))}},updateBounds:(P,x)=>{d.current={min:P,max:x}}}));const b=v(e,i,n),S=m(),_=-135+h.highlightStart*270,C=-135+h.highlightEnd*270;return L.jsxs("div",{style:{width:r,height:r,position:"relative",borderRadius:"50%",background:h.plateColor,border:`${h.borderWidth}px solid ${h.borderColor}`,boxShadow:h.innerShadow?`
              inset 0 0 ${r*.15}px rgba(0, 0, 0, 0.7),
              0 ${r*.02}px ${r*.08}px rgba(0, 0, 0, 0.5),
              inset 0 ${r*.01}px ${r*.02}px rgba(255, 255, 255, 0.05)
            `:`0 ${r*.02}px ${r*.08}px rgba(0, 0, 0, 0.3)`,overflow:"hidden"},children:[h.highlightStart!==h.highlightEnd&&L.jsxs("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"8%",width:"84%",height:"84%"},children:[L.jsx("defs",{children:L.jsx("linearGradient",{id:`highlight-gradient-${t}-${o}`,x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:h.colorBarGradient.map((P,x)=>L.jsx("stop",{offset:`${x/(h.colorBarGradient.length-1)*100}%`,stopColor:P},x))})}),L.jsx("path",{d:i1e(50,50,44,_,C),fill:"none",stroke:h.highlightColor,strokeWidth:"8",strokeLinecap:"butt"})]}),L.jsxs("svg",{viewBox:"0 0 100 100",style:{position:"absolute",inset:"5%",width:"90%",height:"90%"},children:[L.jsx("defs",{children:L.jsx("linearGradient",{id:`color-bar-${t}-${o}`,x1:"0%",y1:"100%",x2:"100%",y2:"0%",children:h.colorBarGradient.map((P,x)=>L.jsx("stop",{offset:`${x/(h.colorBarGradient.length-1)*100}%`,stopColor:P},x))})}),L.jsx("path",{d:i1e(50,50,46,-135,135),fill:"none",stroke:`url(#color-bar-${t}-${o})`,strokeWidth:"3",strokeLinecap:"round",style:{opacity:.6}})]}),p.map((P,x)=>L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${r*.015}px`,height:`${r*.1}px`,background:h.majorTickColor,transformOrigin:"center top",transform:`translate(-50%, 0) rotate(${P.angle}deg) translateY(${-r*.42}px)`,borderRadius:"1px"}},`major-${x}`)),g.map((P,x)=>L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${r*.008}px`,height:`${r*.05}px`,background:h.minorTickColor,transformOrigin:"center top",transform:`translate(-50%, 0) rotate(${P.angle}deg) translateY(${-r*.42}px)`,borderRadius:"1px"}},`minor-${x}`)),S.map((P,x)=>L.jsx("div",{style:{position:"absolute",left:`${P.x}%`,top:`${P.y}%`,transform:"translate(-50%, -50%)",fontFamily:"'JetBrains Mono', 'SF Mono', 'Consolas', monospace",fontSize:`${r*.065}px`,fontWeight:600,color:h.numberColor,textShadow:"0 1px 2px rgba(0, 0, 0, 0.5)"},children:P.value},`num-${x}`)),L.jsx("div",{ref:l,style:{position:"absolute",left:"50%",top:"50%",width:`${r*.04}px`,height:`${r*.38}px`,background:`linear-gradient(90deg, 
              ${h.needleColor}aa 0%, 
              ${h.needleColor} 40%, 
              ${h.needleColor} 60%, 
              ${h.needleColor}aa 100%)`,clipPath:"polygon(35% 100%, 65% 100%, 55% 5%, 50% 0%, 45% 5%)",transformOrigin:"50% 100%",transform:`translate(-50%, -100%) rotate(${b}deg)`,boxShadow:h.needleShadow,transition:"transform 0.1s ease-out",zIndex:10}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${r*.06}px`,height:`${r*.08}px`,background:h.needleColor,clipPath:"polygon(25% 0%, 75% 0%, 90% 100%, 10% 100%)",transformOrigin:"50% 0%",transform:`translate(-50%, 0) rotate(${b}deg)`,opacity:.8,zIndex:9}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${r*.15}px`,height:`${r*.15}px`,background:`radial-gradient(circle at 35% 35%, 
              #666 0%, 
              #333 40%, 
              #111 80%, 
              #000 100%)`,borderRadius:"50%",transform:"translate(-50%, -50%)",boxShadow:`
              inset 0 -2px 4px rgba(255, 255, 255, 0.1),
              0 2px 8px rgba(0, 0, 0, 0.5)
            `,zIndex:11}}),L.jsx("div",{style:{position:"absolute",left:"50%",top:"50%",width:`${r*.05}px`,height:`${r*.05}px`,background:"radial-gradient(circle at 40% 40%, #aaa 0%, #444 100%)",borderRadius:"50%",transform:"translate(-50%, -50%)",zIndex:12}}),L.jsxs("div",{style:{position:"absolute",bottom:`${r*.22}px`,left:"50%",transform:"translateX(-50%)",textAlign:"center",background:"rgba(0, 0, 0, 0.4)",padding:`${r*.02}px ${r*.06}px`,borderRadius:`${r*.02}px`,border:"1px solid rgba(255, 255, 255, 0.1)"},children:[L.jsx("span",{ref:u,style:{fontFamily:"'JetBrains Mono', 'SF Mono', 'Consolas', monospace",fontSize:`${r*.12}px`,fontWeight:700,color:h.valueColor,letterSpacing:"-0.02em"},children:y(e)}),a&&L.jsx("span",{ref:c,style:{display:"block",fontFamily:"'JetBrains Mono', 'SF Mono', 'Consolas', monospace",fontSize:`${r*.055}px`,color:h.unitColor,marginTop:`-${r*.01}px`},children:a})]}),L.jsx("div",{style:{position:"absolute",top:`${r*.15}px`,left:"50%",transform:"translateX(-50%)",fontFamily:"'JetBrains Mono', 'SF Mono', 'Consolas', monospace",fontSize:`${r*.05}px`,color:h.unitColor,textTransform:"uppercase",letterSpacing:"0.1em",opacity:.7},children:t})]})});function i1e(t,e,i,n,r){const o=n1e(t,e,i,r),a=n1e(t,e,i,n),s=r-n<=180?"0":"1";return["M",o.x,o.y,"A",i,i,0,s,0,a.x,a.y].join(" ")}function n1e(t,e,i,n){const r=(n-90)*Math.PI/180;return{x:t+i*Math.cos(r),y:e+i*Math.sin(r)}}ZVe.displayName="RadialGauge";const o1e="#1a1a2e",E7={VividPink:"#FF1133",VividRed:"#FF1133"},JVe=(t,e=7)=>{const i=t/e,n=Math.pow(10,Math.floor(Math.log10(i))),r=i/n;let o;return r<=1?o=1:r<=2?o=2:r<=2.5?o=2.5:r<=5?o=5:o=10,o*n},qOt=async(t,e,i,n,r)=>{const{sciChartSurface:o,wasmContext:a}=await Gt.SciChartPolarSurface.create(t,{padding:new Gt.Thickness(10,10,10,10)}),s=new Gt.PolarNumericAxis(a,{visibleRange:new Gt.NumberRange(0,10),labelStyle:{padding:new Gt.Thickness(0,0,0,0)},axisAlignment:Gt.EAxisAlignment.Right,polarAxisMode:Gt.EPolarAxisMode.Radial,useNativeText:!0,drawLabels:!1,autoTicks:!1,majorDelta:10,drawMajorGridLines:!1,drawMinorGridLines:!1,drawMajorTickLines:!1,drawMinorTickLines:!1,totalAngle:Math.PI*3/2});o.xAxes.add(s);const l=n-i,u=JVe(l),c=new Gt.PolarNumericAxis(a,{polarAxisMode:Gt.EPolarAxisMode.Angular,axisAlignment:Gt.EAxisAlignment.Top,polarLabelMode:Gt.EPolarLabelMode.Parallel,visibleRange:new Gt.NumberRange(i,n),flippedCoordinates:!0,useNativeText:!0,totalAngle:Math.PI*3/2,startAngle:Math.PI*2-Math.PI/4,autoTicks:!1,majorDelta:u,minorsPerMajor:4,drawMajorGridLines:!1,drawMinorGridLines:!1,drawMajorTickLines:!0,majorTickLineStyle:{color:"#FFFFFF",strokeThickness:2.5,tickSize:14},drawMinorTickLines:!0,minorTickLineStyle:{color:"#FFFFFF",strokeThickness:.5,tickSize:8},isInnerAxis:!0,labelPrecision:0,labelStyle:{color:"white",fontSize:14,padding:Gt.Thickness.fromNumber(2)}});r.angularYAxis=c,o.yAxes.add(c);const d=new Gt.PolarPointerAnnotation({x1:e,y1:10,xCoordinateMode:Gt.ECoordinateMode.DataValue,yCoordinateMode:Gt.ECoordinateMode.DataValue,pointerStyle:{baseSize:.02,fill:E7.VividPink,stroke:E7.VividPink,backExtensionSize:.2},pointerCenterStyle:{size:.25,fill:o1e,stroke:o1e},isStrokeAboveCenter:!0,strokeLineJoin:Gt.EStrokeLineJoin.Round});r.pointer=d;const f=new Gt.PolarArcAnnotation({y1:i+l*.71,y2:n,x1:10,x2:9.4,fill:E7.VividRed,strokeThickness:0,annotationLayer:Gt.EAnnotationLayer.Background});r.dangerArcSector=f;const h=new Gt.PolarArcAnnotation({y1:i,y2:n,x1:10,x2:9.7,stroke:"#FFFFFF",isLineMode:!0,strokeThickness:3,annotationLayer:Gt.EAnnotationLayer.Background});r.outlineArcLine=h;const p=new Gt.NativeTextAnnotation({text:`${e.toFixed(0)}`,fontSize:16,textColor:"#fff",x1:0,y1:(i+n)/2,xCoordinateMode:Gt.ECoordinateMode.DataValue,yCoordinateMode:Gt.ECoordinateMode.DataValue,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Center});return r.text=p,o.annotations.add(d,f,h,p),{sciChartSurface:o,wasmContext:a}},QVe=J.forwardRef((t,e)=>{const i=qt.c(16),{initialValue:n,minValue:r,maxValue:o,size:a}=t,s=n===void 0?50:n,l=r===void 0?0:r,u=o===void 0?140:o,c=a===void 0?200:a;let d;i[0]===Symbol.for("react.memo_cache_sentinel")?(d={pointer:null,text:null,angularYAxis:null,dangerArcSector:null,outlineArcLine:null},i[0]=d):d=i[0];const f=J.useRef(d),h=J.useRef(void 0);let p;i[1]!==s||i[2]!==u||i[3]!==l?(p={initialValue:s,minValue:l,maxValue:u},i[1]=s,i[2]=u,i[3]=l,i[4]=p):p=i[4];const g=J.useRef(p);let v;i[5]!==u||i[6]!==l?(v={min:l,max:u},i[5]=u,i[6]=l,i[7]=v):v=i[7];const y=J.useRef(v);let m;i[8]!==s?(m=()=>({updateValue:x=>{const E=f.current;if(!E.pointer||!E.text||x===h.current)return;h.current=x;const{min:A,max:R}=y.current;if(x===void 0)E.pointer.x1=s,E.text.text="--";else{const M=Math.max(A,Math.min(R,x));E.pointer.x1=M,E.text.text=`${x.toFixed(0)}`}},updateBounds:(x,E)=>{const A=f.current;if(!A.angularYAxis)return;y.current={min:x,max:E};const R=E-x,M=JVe(R);A.angularYAxis.visibleRange=new Gt.NumberRange(x,E),A.angularYAxis.majorDelta=M,A.dangerArcSector&&(A.dangerArcSector.y1=x+R*.71,A.dangerArcSector.y2=E),A.outlineArcLine&&(A.outlineArcLine.y1=x,A.outlineArcLine.y2=E),A.text&&(A.text.y1=(x+E)/2)}}),i[8]=s,i[9]=m):m=i[9],J.useImperativeHandle(e,m);let b;i[10]===Symbol.for("react.memo_cache_sentinel")?(b=x=>{const{initialValue:E,minValue:A,maxValue:R}=g.current;return qOt(x,E,A,R,f.current)},i[10]=b):b=i[10];const S=b;let _;i[11]!==c?(_={height:c,width:c},i[11]=c,i[12]=_):_=i[12];let C;i[13]===Symbol.for("react.memo_cache_sentinel")?(C=L.jsx($I.SciChartReact,{initChart:S,style:{width:"100%",height:"100%",border:"1px solid #333",borderRadius:"8px"}}),i[13]=C):C=i[13];let P;return i[14]!==_?(P=L.jsx("div",{style:_,children:C}),i[14]=_,i[15]=P):P=i[15],P});QVe.displayName="SpeedometerGauge";const Au={background:"#1a1a2e",wheelRim:"#5a5a6a",wheelRimHighlight:"#7a7a8a",spoke:"#4a4a5a",hub:"#3a3a4a",hubHighlight:"#5a5a6a",leftIndicator:"#FF6644",rightIndicator:"#44DD66",neutral:"#666677",text:"#FFFFFF"},Pg=8,XOt=async(t,e,i,n)=>{const{sciChartSurface:r,wasmContext:o}=await Gt.SciChartPolarSurface.create(t,{padding:new Gt.Thickness(15,15,25,15)}),a=Math.PI*2,s=new Gt.PolarNumericAxis(o,{polarAxisMode:Gt.EPolarAxisMode.Angular,visibleRange:new Gt.NumberRange(0,360),totalAngle:a,startAngle:-Math.PI/2,isVisible:!1});r.xAxes.add(s);const l=new Gt.PolarNumericAxis(o,{polarAxisMode:Gt.EPolarAxisMode.Radial,visibleRange:new Gt.NumberRange(0,10),isVisible:!1});r.yAxes.add(l);const u=-(e/i)*90,c=new Gt.PolarArcAnnotation({x1:0,x2:359.9,y1:10,y2:8,fill:Au.wheelRim,stroke:Au.wheelRimHighlight,strokeThickness:2});n.rimArc=c,r.annotations.add(c);const d=new Gt.PolarArcAnnotation({x1:0,x2:359.9,y1:8,y2:7.7,fill:Au.wheelRimHighlight,strokeThickness:0});r.annotations.add(d);const f=0+u,h=new Gt.PolarArcAnnotation({x1:f-Pg/2,x2:f+Pg/2,y1:8,y2:2.5,fill:Au.spoke,strokeThickness:0,annotationLayer:Gt.EAnnotationLayer.BelowChart});n.spoke1=h,r.annotations.add(h);const p=120+u,g=new Gt.PolarArcAnnotation({x1:p-Pg/2,x2:p+Pg/2,y1:8,y2:2.5,fill:Au.spoke,strokeThickness:0,annotationLayer:Gt.EAnnotationLayer.BelowChart});n.spoke2=g,r.annotations.add(g);const v=240+u,y=new Gt.PolarArcAnnotation({x1:v-Pg/2,x2:v+Pg/2,y1:8,y2:2.5,fill:Au.spoke,strokeThickness:0,annotationLayer:Gt.EAnnotationLayer.BelowChart});n.spoke3=y,r.annotations.add(y);const m=new Gt.PolarArcAnnotation({x1:0,x2:359.9,y1:2.5,y2:0,fill:Au.hub,stroke:Au.hubHighlight,strokeThickness:1});r.annotations.add(m);const b=new Gt.PolarArcAnnotation({x1:0,x2:359.9,y1:1.5,y2:0,fill:Au.background,strokeThickness:0});r.annotations.add(b);const S=new Gt.NativeTextAnnotation({text:`${e.toFixed(1)}°`,fontSize:16,textColor:Au.text,x1:180,y1:-4,xCoordinateMode:Gt.ECoordinateMode.DataValue,yCoordinateMode:Gt.ECoordinateMode.DataValue,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Center});n.valueText=S,r.annotations.add(S);const _=P=>P<-5?"← LEFT":P>5?"RIGHT →":"CENTER",C=new Gt.NativeTextAnnotation({text:_(e),fontSize:11,textColor:e<-5?Au.leftIndicator:e>5?Au.rightIndicator:Au.neutral,x1:180,y1:-6.5,xCoordinateMode:Gt.ECoordinateMode.DataValue,yCoordinateMode:Gt.ECoordinateMode.DataValue,horizontalAnchorPoint:Gt.EHorizontalAnchorPoint.Center,verticalAnchorPoint:Gt.EVerticalAnchorPoint.Center});return n.directionText=C,r.annotations.add(C),{sciChartSurface:r,wasmContext:o}},eHe=J.forwardRef((t,e)=>{const i=qt.c(16),{initialValue:n,minValue:r,maxValue:o,size:a}=t,s=n===void 0?0:n,l=r===void 0?-800:r,u=o===void 0?800:o,c=a===void 0?200:a;let d;i[0]===Symbol.for("react.memo_cache_sentinel")?(d={spoke1:null,spoke2:null,spoke3:null,valueText:null,directionText:null,rimArc:null},i[0]=d):d=i[0];const f=J.useRef(d),h=J.useRef(void 0);let p;i[1]!==s||i[2]!==u||i[3]!==l?(p={initialValue:s,minValue:l,maxValue:u},i[1]=s,i[2]=u,i[3]=l,i[4]=p):p=i[4];const g=J.useRef(p);let v;i[5]!==u||i[6]!==l?(v={min:l,max:u},i[5]=u,i[6]=l,i[7]=v):v=i[7];const y=J.useRef(v);let m;i[8]!==s?(m=()=>({updateValue:x=>{const E=f.current;if(!E.spoke1||!E.spoke2||!E.spoke3||!E.valueText||!E.directionText||!E.rimArc||x===h.current)return;h.current=x;const{min:A,max:R}=y.current,D=Math.max(A,Math.min(R,x??s)),F=-(D/R)*90,I=0+F;E.spoke1.x1=I-Pg/2,E.spoke1.x2=I+Pg/2;const V=120+F;E.spoke2.x1=V-Pg/2,E.spoke2.x2=V+Pg/2;const z=240+F;if(E.spoke3.x1=z-Pg/2,E.spoke3.x2=z+Pg/2,D<-5?E.rimArc.fill=Au.leftIndicator:D>5?E.rimArc.fill=Au.rightIndicator:E.rimArc.fill=Au.wheelRim,x===void 0)E.valueText.text="--",E.directionText.text="WAITING",E.directionText.textColor=Au.neutral;else{E.valueText.text=`${x.toFixed(1)}°`;const G=KOt;E.directionText.text=G(x),E.directionText.textColor=x<-5?Au.leftIndicator:x>5?Au.rightIndicator:Au.neutral}},updateBounds:(x,E)=>{y.current={min:x,max:E}}}),i[8]=s,i[9]=m):m=i[9],J.useImperativeHandle(e,m);let b;i[10]===Symbol.for("react.memo_cache_sentinel")?(b=x=>{const{initialValue:E,maxValue:A}=g.current;return XOt(x,E,A,f.current)},i[10]=b):b=i[10];const S=b;let _;i[11]!==c?(_={height:c,width:c},i[11]=c,i[12]=_):_=i[12];let C;i[13]===Symbol.for("react.memo_cache_sentinel")?(C=L.jsx($I.SciChartReact,{initChart:S,style:{width:"100%",height:"100%",border:"1px solid #333",borderRadius:"8px"}}),i[13]=C):C=i[13];let P;return i[14]!==_?(P=L.jsx("div",{style:_,children:C}),i[14]=_,i[15]=P):P=i[15],P});eHe.displayName="SteeringWheelGauge";function KOt(t){return t<-5?"← LEFT":t>5?"RIGHT →":"CENTER"}const ZOt=[{value:"gauge",label:"Gauge"},{value:"cssGauge",label:"CSS Gauge"},{value:"radialGauge",label:"Radial Gauge"},{value:"speedometer",label:"Speedometer"},{value:"steeringWheel",label:"Steering Wheel"},{value:"gear",label:"Gear"}],JOt=[{value:"cyber",label:"Cyber"},{value:"neon",label:"Neon"},{value:"racing",label:"Racing"},{value:"warm",label:"Warm"},{value:"cool",label:"Cool"},{value:"ocean",label:"Ocean"},{value:"forest",label:"Forest"},{value:"sunset",label:"Sunset"},{value:"retro",label:"Retro"},{value:"mono",label:"Mono"}],QOt=[{value:"modern",label:"Modern"},{value:"classic",label:"Classic"},{value:"minimal",label:"Minimal"},{value:"analog",label:"Analog"}],eDt=[{value:"default",label:"Default"},{value:"car-speedometer",label:"Car Speedometer"},{value:"industrial",label:"Industrial"},{value:"rpm",label:"RPM"},{value:"temperature",label:"Temperature"},{value:"fuel",label:"Fuel"},{value:"voltage",label:"Voltage"},{value:"compass",label:"Compass"}];function tDt(t){const e=qt.c(54),{type:i,signalMetadata:n,initialValue:r,onRemove:o,onSettings:a,height:s}=t,[l,u]=J.useState(i),[c,d]=J.useState("cyber"),[f,h]=J.useState("modern"),[p,g]=J.useState("default"),[v,y]=J.useState(!1),m=J.useRef(null),b=J.useRef(null),S=$V();let _;e[0]!==n.name?(_=n.name.split(".").pop()??n.name,e[0]=n.name,e[1]=_):_=e[1];const C=_,P=n.min,x=n.max,E=P!=null,A=x!=null,R=E?P:0,M=A?x:0,D=r??(R+M)/2,F=J.useRef(null),I=J.useRef(void 0);let V;e[2]!==A||e[3]!==E||e[4]!==M||e[5]!==R?(V={min:R,max:M,hasMetadataMin:E,hasMetadataMax:A},e[2]=A,e[3]=E,e[4]=M,e[5]=R,e[6]=V):V=e[6];const z=J.useRef(V);let G;e[7]===Symbol.for("react.memo_cache_sentinel")?(G=Ee=>{I.current=Ee.signals[0]},e[7]=G):G=e[7];const H=G;let U,k;e[8]!==S||e[9]!==n?(U=()=>{S.addPendingSubscription(new B3([n.id],H,()=>{console.log("Subscription closed for",n.longName())})),S.applyPendingSubscriptions()},k=[S,n],e[8]=S,e[9]=n,e[10]=U,e[11]=k):(U=e[10],k=e[11]),J.useEffect(U,k);let X,W;e[12]===Symbol.for("react.memo_cache_sentinel")?(X=()=>{let Ee,Re;const Ae=()=>{var Te,ke;const Pe=I.current,we=Pe==null?void 0:Pe.value;if(we!==Re){if(Re=we,we!==void 0){const $e=z.current;let Ne=!1;!$e.hasMetadataMin&&we<$e.min&&($e.min=we,Ne=!0),!$e.hasMetadataMax&&we>$e.max&&($e.max=we,Ne=!0),Ne&&((Te=F.current)==null||Te.updateBounds($e.min,$e.max))}(ke=F.current)==null||ke.updateValue(we)}Ee=requestAnimationFrame(Ae)};return Ee=requestAnimationFrame(Ae),()=>cancelAnimationFrame(Ee)},W=[],e[12]=X,e[13]=W):(X=e[12],W=e[13]),J.useEffect(X,W);let Y;e[14]!==a||e[15]!==v?(Y=()=>{y(!v),a==null||a()},e[14]=a,e[15]=v,e[16]=Y):Y=e[16];const te=Y;let oe,de;e[17]!==v?(de=()=>{const Ee=Re=>{v&&b.current&&!b.current.contains(Re.target)&&m.current&&!m.current.contains(Re.target)&&y(!1)};return document.addEventListener("mousedown",Ee),()=>document.removeEventListener("mousedown",Ee)},oe=[v],e[17]=v,e[18]=oe,e[19]=de):(oe=e[18],de=e[19]),J.useEffect(de,oe);let ge;if(e[20]!==c||e[21]!==f||e[22]!==D||e[23]!==l||e[24]!==te||e[25]!==s||e[26]!==M||e[27]!==R||e[28]!==r||e[29]!==C||e[30]!==o||e[31]!==p||e[32]!==v||e[33]!==n.name||e[34]!==n.namedValues||e[35]!==n.unit){const Ee=()=>{switch(l){case"speedometer":return L.jsx(QVe,{ref:F,label:C,initialValue:D,minValue:R,maxValue:M,size:s});case"steeringWheel":return L.jsx(eHe,{ref:F,label:C,initialValue:D,minValue:R,maxValue:M,size:s});case"gear":{const $e=n.namedValues?Object.entries(n.namedValues).sort(iDt).map(rDt):void 0;return L.jsx(KVe,{ref:F,label:C,initialGear:typeof r=="number"?r:0,gears:$e,size:s})}case"cssGauge":return L.jsx(YVe,{ref:F,label:C,initialValue:D,minValue:R,maxValue:M,size:s,theme:c,variant:f});case"radialGauge":return L.jsx(ZVe,{ref:F,label:C,initialValue:D,minValue:R,maxValue:M,size:s,preset:p,unit:n.unit??""});case"gauge":default:return L.jsx(qVe,{ref:F,label:C,initialValue:D,minValue:R,maxValue:M,size:s})}};let Re;e[37]===Symbol.for("react.memo_cache_sentinel")?(Re=L.jsx(Wr,{type:dr.NAV_MORE_HORIZONTAL,className:"w-4 h-4"}),e[37]=Re):Re=e[37];let Ae;e[38]!==te?(Ae=L.jsx("button",{ref:m,onClick:te,className:"p-1 rounded-md bg-neutral-200/80 dark:bg-neutral-800/80 hover:bg-neutral-300 dark:hover:bg-neutral-700 text-neutral-600 dark:text-neutral-400 transition-colors",title:"Settings",children:Re}),e[38]=te,e[39]=Ae):Ae=e[39];let Pe;e[40]!==o?(Pe=o&&L.jsx("button",{onClick:o,className:"p-1 rounded-md bg-neutral-200/80 dark:bg-neutral-800/80 hover:bg-red-600 text-neutral-600 dark:text-neutral-400 hover:text-white transition-colors",title:"Remove gauge",children:L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-4 h-4"})}),e[40]=o,e[41]=Pe):Pe=e[41];let we;e[42]!==Ae||e[43]!==Pe?(we=L.jsxs("div",{className:"absolute top-1 right-1 z-10 flex gap-1 opacity-0 group-hover/gauge:opacity-100 transition-opacity",children:[Ae,Pe]}),e[42]=Ae,e[43]=Pe,e[44]=we):we=e[44];let Te;e[45]!==c||e[46]!==f||e[47]!==l||e[48]!==p||e[49]!==v||e[50]!==n.name?(Te=v&&L.jsxs("div",{ref:b,className:"absolute top-8 right-1 z-20 bg-white dark:bg-neutral-800 border border-neutral-200 dark:border-neutral-700 rounded-lg shadow-lg p-3 min-w-[160px]",children:[L.jsx("div",{className:"text-xs text-neutral-500 dark:text-neutral-400 mb-2",children:"Gauge Settings"}),L.jsx("div",{className:"text-sm text-neutral-700 dark:text-neutral-300 mb-3 truncate",title:n.name,children:n.name.split(".").pop()}),L.jsx("div",{className:"text-xs text-neutral-500 dark:text-neutral-400 mb-1",children:"Type"}),L.jsx("div",{className:"flex flex-col gap-1",children:ZOt.map($e=>L.jsx("button",{onClick:()=>u($e.value),className:`
                  text-left px-2 py-1.5 rounded text-sm transition-colors
                  ${l===$e.value?"bg-primary text-primary-foreground":"text-neutral-700 dark:text-neutral-300 hover:bg-neutral-100 dark:hover:bg-neutral-700"}
                `,children:$e.label},$e.value))}),l==="cssGauge"&&L.jsxs(L.Fragment,{children:[L.jsx("div",{className:"text-xs text-neutral-500 dark:text-neutral-400 mb-1 mt-3",children:"Style"}),L.jsx("div",{className:"flex flex-wrap gap-1",children:QOt.map($e=>L.jsx("button",{onClick:()=>h($e.value),className:`
                      px-2 py-1 rounded text-xs transition-colors
                      ${f===$e.value?"bg-primary text-primary-foreground":"text-neutral-700 dark:text-neutral-300 hover:bg-neutral-100 dark:hover:bg-neutral-700 bg-neutral-50 dark:bg-neutral-700/50"}
                    `,children:$e.label},$e.value))}),L.jsx("div",{className:"text-xs text-neutral-500 dark:text-neutral-400 mb-1 mt-3",children:"Theme"}),L.jsx("div",{className:"flex flex-wrap gap-1 max-w-[200px]",children:JOt.map($e=>L.jsx("button",{onClick:()=>d($e.value),className:`
                      px-2 py-1 rounded text-xs transition-colors
                      ${c===$e.value?"bg-primary text-primary-foreground":"text-neutral-700 dark:text-neutral-300 hover:bg-neutral-100 dark:hover:bg-neutral-700 bg-neutral-50 dark:bg-neutral-700/50"}
                    `,children:$e.label},$e.value))})]}),l==="radialGauge"&&L.jsxs(L.Fragment,{children:[L.jsx("div",{className:"text-xs text-neutral-500 dark:text-neutral-400 mb-1 mt-3",children:"Preset"}),L.jsx("div",{className:"flex flex-wrap gap-1 max-w-[200px]",children:eDt.map($e=>L.jsx("button",{onClick:()=>g($e.value),className:`
                      px-2 py-1 rounded text-xs transition-colors
                      ${p===$e.value?"bg-primary text-primary-foreground":"text-neutral-700 dark:text-neutral-300 hover:bg-neutral-100 dark:hover:bg-neutral-700 bg-neutral-50 dark:bg-neutral-700/50"}
                    `,children:$e.label},$e.value))})]})]}),e[45]=c,e[46]=f,e[47]=l,e[48]=p,e[49]=v,e[50]=n.name,e[51]=Te):Te=e[51];let ke;e[52]!==C?(ke=L.jsx("p",{className:"absolute bottom-1 left-1 text-xs z-10 text-neutral-600 dark:text-neutral-300 pointer-events-none",children:C}),e[52]=C,e[53]=ke):ke=e[53],ge=L.jsxs("div",{className:"relative group/gauge",children:[we,Te,ke,Ee()]}),e[20]=c,e[21]=f,e[22]=D,e[23]=l,e[24]=te,e[25]=s,e[26]=M,e[27]=R,e[28]=r,e[29]=C,e[30]=o,e[31]=p,e[32]=v,e[33]=n.name,e[34]=n.namedValues,e[35]=n.unit,e[36]=ge}else ge=e[36];return ge}function rDt(t){const[,e]=t;return e}function iDt(t,e){const[i]=t,[n]=e;return Number(i)-Number(n)}function nDt(t){const e=qt.c(14);let i;e[0]!==t.chartHeight||e[1]!==t.onHeightChange?(i=L.jsx(Ri.Section,{title:"Settings",children:L.jsx(Ri.NumberStepper,{label:"Height (px)",value:t.chartHeight,onChange:t.onHeightChange,min:80,max:400,step:30})}),e[0]=t.chartHeight,e[1]=t.onHeightChange,e[2]=i):i=e[2];let n;e[3]===Symbol.for("react.memo_cache_sentinel")?(n=L.jsx(Ri.Divider,{}),e[3]=n):n=e[3];let r;e[4]!==t.onAddGauge?(r=t.onAddGauge&&L.jsx(Ri.Button,{icon:dr.ACTION_ADD,label:"Add gauge",onClick:t.onAddGauge}),e[4]=t.onAddGauge,e[5]=r):r=e[5];let o;e[6]!==t.onRemove?(o=L.jsx(Ri.RemoveButton,{onClick:t.onRemove}),e[6]=t.onRemove,e[7]=o):o=e[7];let a;e[8]!==r||e[9]!==o?(a=L.jsxs(Ri.Section,{title:"Actions",children:[r,o]}),e[8]=r,e[9]=o,e[10]=a):a=e[10];let s;return e[11]!==i||e[12]!==a?(s=L.jsxs(Ri,{children:[i,n,a]}),e[11]=i,e[12]=a,e[13]=s):s=e[13],s}function oDt(t){const e=qt.c(44),{track:i}=el(),{updatePanel:n,removePanel:r}=oC(),o=t.panelConfig,a=J.useRef(null),[s,l]=J.useState(o.heightConfig??150),[u,c]=J.useState(!1);let d,f;if(e[0]===Symbol.for("react.memo_cache_sentinel")?(d=()=>{if(!a.current)return;const G=new ResizeObserver(H=>{for(const U of H){const k=U.contentRect.height;k>0&&l(Math.max(50,k-36-16))}});return G.observe(a.current),()=>G.disconnect()},f=[],e[0]=d,e[1]=f):(d=e[0],f=e[1]),J.useEffect(d,f),!o)return null;let h;e[2]!==o.id||e[3]!==r||e[4]!==i?(h=()=>{r(o.id),i(Fi.RemovePanelFromDashboard,{panelType:"gauge"})},e[2]=o.id,e[3]=r,e[4]=i,e[5]=h):h=e[5];const p=h;let g;e[6]!==o.id||e[7]!==n?(g=G=>n(o.id,"gauge",H=>({...H,signals:H.signals.filter(U=>U.name!==G.name)})),e[6]=o.id,e[7]=n,e[8]=g):g=e[8];const v=g;let y;e[9]!==o.id||e[10]!==i||e[11]!==n?(y=G=>{n(o.id,"gauge",H=>({...H,heightConfig:G})),i(Fi.ChangePanelSetting,{panelType:"gauge",setting:"heightConfig",value:G})},e[9]=o.id,e[10]=i,e[11]=n,e[12]=y):y=e[12];const m=y,b=o.unresolvedSignals&&o.unresolvedSignals.length>0;let S;e[13]!==o.id||e[14]!==n?(S=G=>{n(o.id,"gauge",H=>{const U=new Set(H.signals.map(aDt)),k=G.filter(X=>!U.has(X.name));return{...H,signals:[...H.signals,...k]}}),c(!1)},e[13]=o.id,e[14]=n,e[15]=S):S=e[15];const _=S;let C;e[16]!==s||e[17]!==v||e[18]!==b||e[19]!==o.signals||e[20]!==o.unresolvedSignals?(C=()=>o.signals.length===0&&b?L.jsx(vD,{title:"Signals not available",message:L.jsxs(L.Fragment,{children:[L.jsx("span",{children:"The following signals could not be found:"}),yOt(o.unresolvedSignals)]}),suggestion:"This is likely because you are running against a platform that does not contains these signals."}):L.jsxs("div",{className:"flex flex-wrap gap-4 items-center h-full",children:[o.signals.map(G=>L.jsx(tDt,{type:"gauge",signalMetadata:G,initialValue:0,onRemove:()=>v(G),height:s},G.longName())),o.signals.length===0&&L.jsx("div",{className:"text-sm text-muted-foreground",children:"Click + to add a gauge"})]}),e[16]=s,e[17]=v,e[18]=b,e[19]=o.signals,e[20]=o.unresolvedSignals,e[21]=C):C=e[21];const P=C;let x;e[22]===Symbol.for("react.memo_cache_sentinel")?(x=()=>c(!0),e[22]=x):x=e[22];let E;e[23]!==m||e[24]!==p||e[25]!==o.heightConfig?(E=L.jsx(nDt,{chartHeight:o.heightConfig,onHeightChange:m,onAddGauge:x,onRemove:p}),e[23]=m,e[24]=p,e[25]=o.heightConfig,e[26]=E):E=e[26];let A;e[27]===Symbol.for("react.memo_cache_sentinel")?(A=L.jsx("span",{className:"text-xs font-sm",children:"Gauges"}),e[27]=A):A=e[27];let R;e[28]!==E?(R=L.jsx(GI,{icon:dr.DATA_CIRCLE_GAUGE,helpTooltip:MOt,dropdown:E,children:A}),e[28]=E,e[29]=R):R=e[29];let M;e[30]!==P?(M=L.jsx(YI,{fullHeight:!0,children:P()}),e[30]=P,e[31]=M):M=e[31];let D;e[32]!==R||e[33]!==M?(D=L.jsxs(WI,{ref:a,fullHeight:!0,children:[R,M]}),e[32]=R,e[33]=M,e[34]=D):D=e[34];let F,I;e[35]===Symbol.for("react.memo_cache_sentinel")?(F=[],I=()=>c(!1),e[35]=F,e[36]=I):(F=e[35],I=e[36]);let V;e[37]!==_||e[38]!==o.signals||e[39]!==u?(V=L.jsx(sW,{show:u,selectedSignals:o.signals,selectedFrames:F,handleCloseFunction:I,selectSignalsFunction:_,isFramesSelectable:!1,autoSelectParentFrame:!1,enforceFrameSelection:!1}),e[37]=_,e[38]=o.signals,e[39]=u,e[40]=V):V=e[40];let z;return e[41]!==D||e[42]!==V?(z=L.jsxs(L.Fragment,{children:[D,V]}),e[41]=D,e[42]=V,e[43]=z):z=e[43],z}function aDt(t){return t.name}const sDt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Map"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Latitude"}),": Set the signal for the latitude coordinate",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Longitude"}),": Set the signal for the longitude coordinate"]})]});function u$(t){var a,s,l,u;const e=qt.c(10);if(((a=t.signals)==null?void 0:a.length)===0&&((s=t.frames)==null?void 0:s.length)===0)return null;let i;e[0]!==t.className?(i=Hr("space-y-2 mx-2 mb-2",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;e[2]!==t?(n=(l=t==null?void 0:t.signals)==null?void 0:l.map((c,d)=>L.jsxs("div",{className:"bg-amber-50 dark:bg-amber-950/30 border border-amber-200 dark:border-amber-800/50 rounded-md px-3 py-2",children:[L.jsxs("div",{className:"flex items-center justify-between gap-2",children:[L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx(Wr,{type:dr.STATUS_WARNING,className:"text-amber-500 dark:text-amber-400 w-4 h-4 flex-shrink-0"}),L.jsx("p",{className:"text-xs font-medium text-amber-800 dark:text-amber-200 m-0",children:t.title??"Signal not available"})]}),t.onRemoveSignal&&L.jsxs("button",{onClick:()=>{var f;return(f=t.onRemoveSignal)==null?void 0:f.call(t,c)},className:"flex items-center gap-1 text-xs text-amber-600 dark:text-amber-400 hover:text-amber-800 dark:hover:text-amber-200 transition-colors",title:"Remove this signal from the panel",children:[L.jsx("span",{children:"Remove"}),L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-3 h-3"})]})]}),L.jsxs("div",{className:"mt-1 ml-6 space-y-0.5 text-xs text-amber-700 dark:text-amber-300",children:[L.jsxs("div",{children:[L.jsx("span",{className:"text-amber-600 dark:text-amber-400",children:"Namespace: "}),L.jsx("span",{className:"font-medium",children:c.namespace})]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-amber-600 dark:text-amber-400",children:"Signal: "}),L.jsx("span",{className:"font-medium",children:c.signal})]})]})]},`${c.namespace}-${c.frame}-${c.signal}-${d}`)),e[2]=t,e[3]=n):n=e[3];let r;e[4]!==t?(r=(u=t==null?void 0:t.frames)==null?void 0:u.map((c,d)=>L.jsxs("div",{className:"bg-amber-50 dark:bg-amber-950/30 border border-amber-200 dark:border-amber-800/50 rounded-md px-3 py-2",children:[L.jsxs("div",{className:"flex items-center justify-between gap-2",children:[L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx(Wr,{type:dr.STATUS_WARNING,className:"text-amber-500 dark:text-amber-400 w-4 h-4 flex-shrink-0"}),L.jsx("p",{className:"text-xs font-medium text-amber-800 dark:text-amber-200 m-0",children:t.title??"Frame not available"})]}),t.onRemoveFrame&&L.jsxs("button",{onClick:()=>{var f;return(f=t.onRemoveFrame)==null?void 0:f.call(t,c)},className:"flex items-center gap-1 text-xs text-amber-600 dark:text-amber-400 hover:text-amber-800 dark:hover:text-amber-200 transition-colors",title:"Remove this signal from the panel",children:[L.jsx("span",{children:"Remove"}),L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-3 h-3"})]})]}),L.jsxs("div",{className:"mt-1 ml-6 space-y-0.5 text-xs text-amber-700 dark:text-amber-300",children:[L.jsxs("div",{children:[L.jsx("span",{className:"text-amber-600 dark:text-amber-400",children:"Namespace: "}),L.jsx("span",{className:"font-medium",children:c.namespace})]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-amber-600 dark:text-amber-400",children:"Frame: "}),L.jsx("span",{className:"font-medium",children:c.frame})]})]})]},`${c.namespace}-${c.frame}-${d}`)),e[4]=t,e[5]=r):r=e[5];let o;return e[6]!==i||e[7]!==n||e[8]!==r?(o=L.jsxs("div",{className:i,children:[n,r]}),e[6]=i,e[7]=n,e[8]=r,e[9]=o):o=e[9],o}function rG(t){const e=qt.c(16),{icon:i,title:n,description:r,descriptionClassName:o,children:a}=t;let s;e[0]!==i?(s=L.jsx("div",{className:"w-8 h-8 bg-blue-200/60 dark:bg-accent rounded-sm flex items-center justify-center mb-2",children:L.jsx(Wr,{type:i,className:"w-5 h-5 dark:text-foreground text-muted-foreground"})}),e[0]=i,e[1]=s):s=e[1];let l;e[2]!==n?(l=L.jsx("p",{className:"text-sm font-medium text-foreground",children:n}),e[2]=n,e[3]=l):l=e[3];let u;e[4]!==o?(u=Hr("text-xs text-muted-foreground text-center",o),e[4]=o,e[5]=u):u=e[5];let c;e[6]!==r||e[7]!==u?(c=L.jsx("p",{className:u,children:r}),e[6]=r,e[7]=u,e[8]=c):c=e[8];let d;e[9]!==s||e[10]!==l||e[11]!==c?(d=L.jsxs("div",{className:"mb-4 flex flex-col items-center justify-center",children:[s,l,c]}),e[9]=s,e[10]=l,e[11]=c,e[12]=d):d=e[12];let f;return e[13]!==a||e[14]!==d?(f=L.jsxs("div",{className:"flex flex-col justify-center items-center h-full",children:[d,a]}),e[13]=a,e[14]=d,e[15]=f):f=e[15],f}function lDt(t){var c,d;const e=qt.c(15),i=((c=t.signals.latitude)==null?void 0:c.name)??"Not set";let n;e[0]!==t.onOpenLatitudeModal||e[1]!==i?(n=L.jsx(Ri.Button,{label:"Latitude",subtitle:i,onClick:t.onOpenLatitudeModal}),e[0]=t.onOpenLatitudeModal,e[1]=i,e[2]=n):n=e[2];const r=((d=t.signals.longitude)==null?void 0:d.name)??"Not set";let o;e[3]!==t.onOpenLongitudeModal||e[4]!==r?(o=L.jsx(Ri.Button,{label:"Longitude",subtitle:r,onClick:t.onOpenLongitudeModal}),e[3]=t.onOpenLongitudeModal,e[4]=r,e[5]=o):o=e[5];let a;e[6]!==n||e[7]!==o?(a=L.jsxs(Ri.Section,{title:"Settings",children:[n,o]}),e[6]=n,e[7]=o,e[8]=a):a=e[8];let s;e[9]===Symbol.for("react.memo_cache_sentinel")?(s=L.jsx(Ri.Divider,{}),e[9]=s):s=e[9];let l;e[10]!==t.onRemove?(l=L.jsx(Ri.Section,{title:"Actions",children:L.jsx(Ri.RemoveButton,{onClick:t.onRemove})}),e[10]=t.onRemove,e[11]=l):l=e[11];let u;return e[12]!==a||e[13]!==l?(u=L.jsxs(Ri,{children:[a,s,l]}),e[12]=a,e[13]=l,e[14]=u):u=e[14],u}function uDt(t){const e=qt.c(56),{track:i}=el(),{updatePanel:n,removePanel:r}=oC(),o=t.panelConfig,{settings:a}=Lp(),s=J.useRef(null),[l,u]=J.useState(!1),[c,d]=J.useState("latitude");let f;e[0]!==o.id||e[1]!==r||e[2]!==i?(f=()=>{r(o.id),i(Fi.RemovePanelFromDashboard,{panelType:"map"})},e[0]=o.id,e[1]=r,e[2]=i,e[3]=f):f=e[3];const h=f;let p;e[4]!==o.id||e[5]!==n?(p=X=>n(o.id,"map",W=>({...W,signals:{...W.signals,latitude:X}})),e[4]=o.id,e[5]=n,e[6]=p):p=e[6];const g=p;let v;e[7]!==o.id||e[8]!==n?(v=X=>n(o.id,"map",W=>({...W,signals:{...W.signals,longitude:X}})),e[7]=o.id,e[8]=n,e[9]=v):v=e[9];const y=v;let m;e[10]!==o.id||e[11]!==n?(m=()=>n(o.id,"map",dDt),e[10]=o.id,e[11]=n,e[12]=m):m=e[12];const b=m;let S;e[13]!==o.id||e[14]!==n?(S=()=>n(o.id,"map",cDt),e[13]=o.id,e[14]=n,e[15]=S):S=e[15];const _=S,C=o.signals.latitude!==void 0&&o.signals.longitude!==void 0;let P;e[16]!==o.signals.latitude||e[17]!==o.signals.longitude?(P=()=>L.jsx(rG,{icon:dr.TOPOLOGY_ENDPOINT,title:"Map panel",description:"Select latitude and longitude signals to plot movement on a map",children:L.jsxs("div",{className:"flex gap-2",children:[L.jsx(Za,{icon:o.signals.latitude?dr.STATUS_SUCCESS:dr.ACTION_EDIT,label:o.signals.latitude?"Latitude set":"Set latitude",type:o.signals.latitude?fn.SUCCESS:fn.PRIMARY,size:_a.SM,onClick:()=>{d("latitude"),u(!0)}}),L.jsx(Za,{icon:o.signals.longitude?dr.STATUS_SUCCESS:dr.ACTION_EDIT,label:o.signals.longitude?"Longitude set":"Set longitude",type:o.signals.longitude?fn.SUCCESS:fn.PRIMARY,size:_a.SM,onClick:()=>{d("longitude"),u(!0)}})]})}),e[16]=o.signals.latitude,e[17]=o.signals.longitude,e[18]=P):P=e[18];const x=P;let E;e[19]!==h||e[20]!==b||e[21]!==_||e[22]!==C||e[23]!==o.signals.latitude||e[24]!==o.signals.longitude||e[25]!==o.unresolvedSignals||e[26]!==x||e[27]!==a?(E=()=>{var X,W;return C?L.jsxs("div",{className:"flex flex-col h-full",children:[((X=o.unresolvedSignals)==null?void 0:X.latitude)&&L.jsx(u$,{signals:[o.unresolvedSignals.latitude],title:"Latitude signal not available",onRemoveSignal:b}),((W=o.unresolvedSignals)==null?void 0:W.longitude)&&L.jsx(u$,{signals:[o.unresolvedSignals.longitude],title:"Longitude signal not available",onRemoveSignal:_}),L.jsx("div",{className:"flex-1 min-h-0",children:L.jsx(ZEt,{googleMapsApiKey:a.googleMapsApiKey,latitudeSignal:o.signals.latitude,longitudeSignal:o.signals.longitude,showSelectSignalModal:Y=>{d(Y==="latitude"?"latitude":"longitude"),u(!0)},onRemove:h})})]}):x()},e[19]=h,e[20]=b,e[21]=_,e[22]=C,e[23]=o.signals.latitude,e[24]=o.signals.longitude,e[25]=o.unresolvedSignals,e[26]=x,e[27]=a,e[28]=E):E=e[28];const A=E;let R,M;e[29]===Symbol.for("react.memo_cache_sentinel")?(R=()=>{d("latitude"),u(!0)},M=()=>{d("longitude"),u(!0)},e[29]=R,e[30]=M):(R=e[29],M=e[30]);let D;e[31]!==h||e[32]!==o.signals?(D=L.jsx(GI,{icon:dr.TOPOLOGY_ENDPOINT,helpTooltip:sDt,dropdown:L.jsx(lDt,{signals:o.signals,onOpenLatitudeModal:R,onOpenLongitudeModal:M,onRemove:h})}),e[31]=h,e[32]=o.signals,e[33]=D):D=e[33];let F;e[34]!==A?(F=L.jsx(YI,{fullHeight:!0,padding:!1,children:A()}),e[34]=A,e[35]=F):F=e[35];let I;e[36]!==F||e[37]!==D?(I=L.jsxs(WI,{ref:s,fullHeight:!0,children:[D,F]}),e[36]=F,e[37]=D,e[38]=I):I=e[38];let V;e[39]!==o.signals.latitude||e[40]!==o.signals.longitude||e[41]!==c?(V=c==="latitude"?o.signals.latitude?[o.signals.latitude]:[]:o.signals.longitude?[o.signals.longitude]:[],e[39]=o.signals.latitude,e[40]=o.signals.longitude,e[41]=c,e[42]=V):V=e[42];let z,G;e[43]===Symbol.for("react.memo_cache_sentinel")?(z=[],G=()=>u(!1),e[43]=z,e[44]=G):(z=e[43],G=e[44]);let H;e[45]!==g||e[46]!==y||e[47]!==c?(H=(X,W)=>{X.length!==0&&(c==="latitude"?g(X[0]):y(X[0]))},e[45]=g,e[46]=y,e[47]=c,e[48]=H):H=e[48];let U;e[49]!==l||e[50]!==V||e[51]!==H?(U=L.jsx(sW,{show:l,selectedSignals:V,selectedFrames:z,handleCloseFunction:G,selectSignalsFunction:H,singleSignalSelectionOnly:!0,isFramesSelectable:!1,autoSelectParentFrame:!1,enforceFrameSelection:!1}),e[49]=l,e[50]=V,e[51]=H,e[52]=U):U=e[52];let k;return e[53]!==I||e[54]!==U?(k=L.jsxs(L.Fragment,{children:[I,U]}),e[53]=I,e[54]=U,e[55]=k):k=e[55],k}function cDt(t){return{...t,unresolvedSignals:t.unresolvedSignals?{...t.unresolvedSignals,longitude:void 0}:void 0}}function dDt(t){return{...t,unresolvedSignals:t.unresolvedSignals?{...t.unresolvedSignals,latitude:void 0}:void 0}}function fDt(t){let e=2166136261;for(let i=0;i<t.length;i++)e^=t.charCodeAt(i),e=e*16777619>>>0;return e>>>0}function hDt(t,e,i){i/=100;const n=e*Math.min(i,1-i)/100,r=o=>{const a=(o+t/30)%12,s=i-n*Math.max(Math.min(a-3,9-a,1),-1);return Math.round(255*s).toString(16).padStart(2,"0")};return`#${r(0)}${r(8)}${r(4)}`}function pDt(t,e){const i=fDt(t),n=(i&255^i>>8&255)&255,r=(i>>8&255^i>>16&255)&255,o=(i>>16&255^i>>24&255)&255,a=Math.floor(n/255*359),s=Math.floor(40+r/255*60),l=e?[50,80]:[40,70],u=Math.floor(l[0]+o/255*(l[1]-l[0]));return hDt(a,s,u)}class gDt extends Gt.SmartDateLabelProvider{get formatCursorLabel(){return e=>{const i=new Date(e),n=i.getHours().toString().padStart(2,"0"),r=i.getMinutes().toString().padStart(2,"0"),o=i.getSeconds().toString().padStart(2,"0"),a=i.getMilliseconds().toString().padStart(3,"0");return`${n}:${r}:${o}.${a}`}}get formatLabel(){return vDt}}const vDt=t=>{const e=new Date(t),i=(n,r=2)=>String(n).padStart(r,"0");return`${i(e.getHours())}:${i(e.getMinutes())}:${i(e.getSeconds())}`},D4=(t,e)=>{const i=e.namedValues;return i&&t in i?i[t]+` (${t})`:null},tHe=(t,e,i)=>{if(!t||Object.keys(t).length<=1)return!1;const n=Object.keys(t).map(Number).sort((s,l)=>s-l),r=Math.min(...n),a=Math.max(...n)-r;return e!==void 0&&i!==void 0&&n.some(l=>l<e||l>i)?!1:n.length>1&&a<=10&&n.length>=a*.5},yDt=(t,e,i)=>{if(t.id==="y-default"||!t||t.isDeleted)return;t.labelProvider||console.warn(`Axis ${t.id} missing label provider, skipping`),rHe(t,e);const n=tHe(e.namedValues,e.min,e.max);i&&!n?(t.visibleRangeLimit=void 0,t.autoRange=Gt.EAutoRange.Never,t.setVisibleRangeWithLimits(new Gt.NumberRange(e.min??0,e.max??100))):!i&&!n&&(t.visibleRangeLimit=void 0,t.autoRange=Gt.EAutoRange.Always,t.growBy=new Gt.NumberRange(.1,.1))},rHe=(t,e)=>{if(!t.labelProvider)return;const i=t.labelProvider.formatLabel.bind(t.labelProvider),n=e.namedValues;if(!n||Object.keys(n).length===0){t.labelProvider.formatLabel=c=>{const d=D4(c,e);return d!==null?d:i(c)};return}const r=Object.keys(n).map(Number).sort((c,d)=>c-d);if(r.length===0){t.labelProvider.formatLabel=c=>{const d=D4(c,e);return d!==null?d:i(c)};return}const o=Math.min(...r),a=Math.max(...r),s=a-o;let l=!1;e.min!==void 0&&e.max!==void 0&&(l=r.some(c=>c<e.min||c>e.max));const u=!l&&r.length>1&&s<=10&&r.length>=s*.5;if(t.drawMinorTickLines=!1,t.minorDelta=Number.MAX_VALUE,u){const c=s>0?s*.1:.5;if(t.autoRange=Gt.EAutoRange.Never,t.visibleRange=new Gt.NumberRange(o-c,a+c),t.growBy=new Gt.NumberRange(0,0),r.length>1){const d=[];for(let h=1;h<r.length;h++)d.push(r[h]-r[h-1]);const f=Math.min(...d);t.majorDelta=f}else t.majorDelta=1;t.labelProvider.formatLabel=d=>{const f=r.find(h=>Math.abs(h-d)<.001);if(f!==void 0){const h=D4(f,e);return h!==null?h:i(d)}return""}}else{if(t.autoRange=Gt.EAutoRange.Always,t.growBy=new Gt.NumberRange(.1,.1),r.length>1){const c=[];for(let f=1;f<r.length;f++)c.push(r[f]-r[f-1]);const d=Math.min(...c);t.majorDelta=Math.min(d,1)}else t.majorDelta=1;t.labelProvider.formatLabel=c=>{const d=r.find(f=>Math.abs(f-c)<.001);if(d!==void 0){const f=D4(d,e);return f!==null?f:i(c)}return i(c)}}},R4=(t,e,i=1e-9)=>Math.abs(t-e)<=i;class mDt{constructor(){this.groups=new Map,this.locks=new Set,this.groupWindowSizes=new Map,this.verticalGroup=new Gt.SciChartVerticalGroup,this.groupSelectedPoint=new Map}add(e,i,n,r){const o=this.ensureGroup(e),a={xAxis:i,onLiveChange:n,onWindowSizeChange:r},s=o.values().next().value;if(s&&s.xAxis.visibleRange){const u=s.xAxis.visibleRange;i.visibleRange=new Gt.NumberRange(u.min,u.max)}o.add(a);const l=u=>{if(!u||!u.visibleRange||this.locks.has(e))return;const c=u.visibleRange,d=this.groups.get(e);if(d){this.locks.add(e);try{d.forEach(f=>{if(f.xAxis===i)return;const h=f.xAxis.visibleRange;h&&R4(h.min,c.min)&&R4(h.max,c.max)||(f.xAxis.visibleRange=new Gt.NumberRange(c.min,c.max))})}finally{this.locks.delete(e)}}};return i.visibleRangeChanged.subscribe(l),()=>{try{i.visibleRangeChanged.unsubscribe(l)}catch{}const u=this.groups.get(e);u&&(u.delete(a),u.size===0&&this.groups.delete(e))}}setLive(e,i,n,r){const o=this.groups.get(e);if(!o)return;o.forEach(s=>{var l;(l=s.onLiveChange)==null||l.call(s,i)});let a=n;if(i&&!a&&r){const s=this.groupWindowSizes.get(e);if(s){const l=r(),u=500;a=new Gt.NumberRange(l-s,l+u)}}if(i&&a){this.locks.add(e);try{o.forEach(s=>{const l=s.xAxis.visibleRange;l&&R4(l.min,a.min)&&R4(l.max,a.max)||(s.xAxis.visibleRange=new Gt.NumberRange(a.min,a.max))})}finally{this.locks.delete(e)}}}setWindowSize(e,i){this.groupWindowSizes.set(e,i);const n=this.groups.get(e);n&&n.forEach(r=>{var o;(o=r.onWindowSizeChange)==null||o.call(r,i)})}getSelectedPoint(e){return this.groupSelectedPoint.get(e)}setSelectedPoint(e,i){this.groupSelectedPoint.set(e,i)}getWindowSize(e){return this.groupWindowSizes.get(e)}clearGroup(e){this.groups.delete(e),this.locks.delete(e),this.groupWindowSizes.delete(e)}ensureGroup(e){let i=this.groups.get(e);return i||(i=new Set,this.groups.set(e,i)),i}addSurface(e){this.verticalGroup.addSurfaceToGroup(e)}}const bDt=new mDt;function SDt(){return bDt}const _Dt=1.5;class PDt{constructor(){this.lastTimestampRef={},this.gapAnnotationsRef=[],this.clearGapAnnotations=e=>{this.gapAnnotationsRef.forEach(i=>{try{e.annotations.remove(i)}catch{}}),this.gapAnnotationsRef=[]}}detectAll(e,i,n){e.forEach(r=>this.detect(r,i,n))}detect(e,i,n){if(!Number.isFinite(e.value))return;const r=e.timestampeUs/1e3,o=this.lastTimestampRef[e.name];if(o!==void 0){const a=r-o,s=_Dt*1e3;a>s&&(console.log(`Gap detected for ${e.name}: ${a}ms > ${s}ms, inserting line break and gap annotation`),i.append(o+1,NaN),this.addGapAnnotation(o,r,e.name,n))}this.lastTimestampRef[e.name]=r}addGapAnnotation(e,i,n,r){console.log(`addGapAnnotation called: startTime=${e}, endTime=${i}, key=${n}`);const o=new Gt.VerticalLineAnnotation({id:`gap-start-${n}-${e}`,x1:e,strokeThickness:1,strokeDashArray:[1,2],annotationLayer:Gt.EAnnotationLayer.AboveChart}),a=new Gt.VerticalLineAnnotation({id:`gap-end-${n}-${i}`,x1:i,strokeThickness:1,strokeDashArray:[1,2],annotationLayer:Gt.EAnnotationLayer.AboveChart});console.log(`Adding gap annotations at start: ${e} and end: ${i}`),r.annotations.add(o),r.annotations.add(a),this.gapAnnotationsRef.push(o,a),console.log(`Gap annotations added, total annotations: ${this.gapAnnotationsRef.length}`)}}const CDt=new PDt;function TDt(){return CDt}const xDt=t=>{const e=new Date(t),i=(n,r=2)=>String(n).padStart(r,"0");return`${i(e.getHours())}:${i(e.getMinutes())}:${i(e.getSeconds())}.${String(e.getMilliseconds()).padStart(3,"0")}`};function EDt(t,e,i,n){function r(a){return Math.abs(a)<1e3?`${Math.round(a)}ms`:`${(a/1e3).toFixed(3)}s`}const o=new Gt.RolloverModifier({modifierGroup:"asd",showRolloverLine:!0,snapToDataPoint:!0,hitTestRadius:0,tooltipDataTemplate:a=>{const s=typeof a.xValue=="number"?xDt(a.xValue):a.formattedXValue;let l;if(typeof a.yValue=="number"){const c=n(a.yValue);l=c!==null?c:a.yValue.toFixed(3)}else l=a.formattedYValue;const u=[`${s}`,`${l}`];if(i&&e.getSelectedPoint(i)){const c=e.getSelectedPoint(i),d=a.xValue-e.getSelectedPoint(i).x;if(u.push("- - - - -"),c.id===a.seriesName){const f=n(c.y);l=f!==null?f:c.y.toFixed(3),u.push(`Value: ${l}`)}u.push(`Timediff: ${r(d)}`)}return u}});t.chartModifiers.add(o)}function wDt(t,e,i){const n=new Gt.ZoomPanModifier({enableZoom:!1,executeCondition:{button:Gt.EExecuteOn.MouseLeftButton,key:Gt.EModifierMouseArgKey.Ctrl},xyDirection:Gt.EXyDirection.XDirection}),r=new Gt.MouseWheelZoomModifier({executeCondition:{key:Gt.EModifierMouseArgKey.Alt},xyDirection:Gt.EXyDirection.XDirection,growFactor:.01}),o=new Gt.RubberBandXyZoomModifier({executeCondition:{button:Gt.EExecuteOn.MouseLeftButton,key:Gt.EModifierMouseArgKey.Alt},xyDirection:Gt.EXyDirection.XDirection}),a=new Gt.ZoomExtentsModifier;t.chartModifiers.add(n,r,a,o),t.chartModifiers.add(new Gt.DataPointSelectionModifier({onSelectionChanged:s=>{s.selectedDataPoints.length>0&&e.setSelectedPoint(i,{x:s.selectedDataPoints[0].xValue,y:s.selectedDataPoints[0].yValue,id:s.selectedDataPoints[0].seriesName})},allowDragSelect:!1,selectionFill:"#ffffff",selectionStroke:"#ff0000",selectionStrokeThickness:4}))}Gt.SciChartSurface.useWasmFromCDN();const ADt=200,a1e=1;function ODt({isPaused:t=!1,onPausedChange:e,chartHeight:i=150,windowSizeMs:n=1e4,getTime:r,signals:o,signalBuffersRef:a,isDarkMode:s=!0,groupId:l="subchart-group",useSuggestedMinMax:u=!1,animationMaxFps:c,onRemoveSignal:d}){const f=J.useRef(null),h=J.useRef(new Map),p=J.useRef(null),g=J.useRef(0),v=J.useRef(1e3/c);v.current=1e3/c;const y=J.useRef(n),m=J.useRef(!0),b=J.useRef(null),S=J.useRef(new Map),_=J.useRef(null),C=J.useRef(new Set),P=J.useRef(!1),[x,E]=J.useState(null),[A,R]=J.useState(null),M=J.useRef(new Map),D=J.useRef(r);D.current=r;const F=J.useRef(o);F.current=o;const I=SDt(),V=TDt(),z=J.useRef(new Map);J.useEffect(()=>{y.current=n,I.setWindowSize(l,n)},[n,I,l]),J.useEffect(()=>{t?H():U()},[t]);const G=J.useCallback((Pe,we)=>{const Te=we.namedValues;return Te&&Pe in Te?Te[Pe]+` (${Pe})`:null},[]),H=J.useCallback(()=>{I.setLive(l,!1),e(!0)},[I,l]),U=J.useCallback(()=>{I.setLive(l,!0,void 0,D.current)},[I,l]),k=J.useCallback(()=>{for(const[Pe,we]of h.current){const Te=a.current.get(Pe);if(!Te)continue;const ke=Te.current;if(ke.length===0)continue;Te.current=[];const $e=ke[0].timestampeUs/1e3,Ne=S.current.get(Pe)??0;$e<Ne&&we.dataSeries.clear(),S.current.set(Pe,ke[ke.length-1].timestampeUs/1e3),V.detectAll(ke,we.dataSeries,we.surface);const ve=new Float64Array(ke.map(fe=>fe.timestampeUs/1e3)),pe=new Float64Array(ke.map(fe=>fe.value));we.dataSeries.appendRange(ve,pe)}},[V]),X=J.useCallback((Pe,we,Te,ke,$e)=>{const Ne=a1e/$e,ve=ke*Ne,pe=.005,fe=Gt.SciChartSubSurface.createSubSurface(Pe,{position:{x:0,y:ve+pe/2,width:1,height:Ne-pe},isTransparent:!1});fe.suspendUpdates();const me=new Gt.DateTimeNumericAxis(we,{autoRange:Gt.EAutoRange.Never,drawLabels:ke===$e-1,drawMajorTickLines:!1,drawMinorTickLines:!1,drawMajorGridLines:!0,drawMinorGridLines:!1,labelProvider:new gDt,useNativeText:!0});fe.xAxes.add(me);const Ce=new Gt.NumericAxis(we,{axisAlignment:Gt.EAxisAlignment.Left,autoRange:Gt.EAutoRange.Always,growBy:new Gt.NumberRange(.1,.1),drawMajorTickLines:!1,drawMinorTickLines:!1,drawMajorGridLines:!0,drawMinorGridLines:!1,isInnerAxis:!0});Ce.growBy=new Gt.NumberRange(.1,.1),fe.yAxes.add(Ce),rHe(Ce,Te);const Ue=tHe(Te.namedValues,Te.min,Te.max);u&&!Ue&&(Ce.autoRange=Gt.EAutoRange.Never,Ce.visibleRange=new Gt.NumberRange(Te.min??0,Te.max??100));const Qe=new Gt.XyDataSeries(we,{fifoCapacity:1e5,dataSeriesName:Te.name,dataIsSortedInX:!0,containsNaN:!1}),it=pDt(Te.name,s),xt=new Gt.FastLineRenderableSeries(we,{dataSeries:Qe,stroke:it,strokeThickness:2,drawNaNAs:Gt.ELineDrawMode.DiscontinuousLine}),wt=new Gt.EllipsePointMarker(we,{width:4,height:4,strokeThickness:0,fill:it});xt.pointMarker=wt,fe.renderableSeries.add(xt);const $t=new Gt.VerticalLineAnnotation({id:"selectedPoint",x1:0,strokeThickness:2,strokeDashArray:[3,3],annotationLayer:Gt.EAnnotationLayer.AboveChart});fe.annotations.add($t),EDt(fe,I,l,qe=>G(qe,Te)),wDt(fe,I,l);const rt=I.add(l,me,qe=>{m.current=qe,b.current&&(b.current.style.display=qe?"none":"block")},qe=>{y.current=qe});return z.current.set(Te.longName(),rt),l$(fe,s),fe.resumeUpdates(),{surface:fe,dataSeries:Qe,xAxis:me,yAxis:Ce,signalMeta:Te}},[s,u,I,l,G]),W=J.useCallback(Pe=>{const we=h.current.get(Pe);if(!we)return;const Te=z.current.get(Pe);Te&&(Te(),z.current.delete(Pe)),f.current&&f.current.removeSubChart(we.surface),we.surface.delete(),h.current.delete(Pe),C.current.delete(Pe),S.current.delete(Pe)},[]),Y=J.useCallback((Pe,we)=>{const Te=F.current;if(Te.length===0)return;const ke=Te.length;Te.forEach(($e,Ne)=>{const ve=$e.longName();if(C.current.has(ve)){const pe=h.current.get(ve);if(pe){const fe=a1e/ke,me=Ne*fe,Ce=.005;pe.surface.subPosition={x:0,y:me+Ce/2,width:1,height:fe-Ce},pe.xAxis.drawLabels=Ne===ke-1}}else{const pe=X(Pe,we,$e,Ne,ke);h.current.set(ve,pe),C.current.add(ve)}})},[X]),te=J.useMemo(()=>async Pe=>{h.current.clear(),C.current.clear(),S.current.clear();for(const ke of z.current.values())ke();z.current.clear();const{wasmContext:we,sciChartSurface:Te}=await Gt.SciChartSurface.create(Pe);return f.current=Te,_.current=we,Te.applyTheme(T7(s).scichartTheme()),Te.domCanvas2D.addEventListener("wheel",ke=>{ke.altKey&&H()},{passive:!0}),Te.domCanvas2D.addEventListener("pointerdown",ke=>{(ke.ctrlKey||ke.altKey)&&H()}),Y(Te,we),P.current=!0,{sciChartSurface:Te}},[s,H,Y]);J.useEffect(()=>{let Pe=!0;const we=()=>{if(!P.current||!f.current){requestAnimationFrame(we);return}const Te=ke=>{if(Pe){if(ke-g.current>=v.current){g.current=ke,k();const $e=D.current();if(m.current){const ve=new Gt.NumberRange($e-y.current,$e+ADt);for(const pe of h.current.values())if(pe.surface.xAxes.size()>0){pe.xAxis.visibleRange=ve;const fe=pe.surface.annotations.getById("playhead");if(fe){const me=fe;me.x1=$e}}}const Ne=I.getSelectedPoint(l);if(Ne){for(const ve of h.current.values())if(ve.surface.xAxes.size()>0){const pe=ve.surface.annotations.getById("selectedPoint");if(pe){const fe=pe;fe.x1=Ne.x}}}}p.current=requestAnimationFrame(Te)}};p.current=requestAnimationFrame(Te)};return we(),()=>{Pe=!1,p.current&&cancelAnimationFrame(p.current);for(const Te of z.current.values())Te();z.current.clear(),h.current.clear(),C.current.clear(),S.current.clear(),P.current=!1}},[k,I,l]);const oe=J.useMemo(()=>o.map(Pe=>Pe.longName()).join(","),[o]);J.useEffect(()=>{const Pe=f.current,we=_.current;if(!Pe||!we||!P.current)return;const Te=new Set(F.current.map(ke=>ke.longName()));for(const ke of[...h.current.keys()])Te.has(ke)||W(ke);Y(Pe,we)},[oe,Y,W]),J.useEffect(()=>{if(f.current&&P.current){f.current.applyTheme(T7(s).scichartTheme());for(const Pe of h.current.values())l$(Pe.surface,s)}},[s]),J.useEffect(()=>{if(P.current)for(const Pe of h.current.values()){const{yAxis:we,signalMeta:Te,surface:ke}=Pe;if(!(!we||!ke))try{ke.suspendUpdates(),yDt(we,Te,u)}finally{ke.resumeUpdates()}}},[u,o]);const de=i*Math.max(o.length,1),ge=J.useCallback((Pe,we)=>{if(x===Pe)E(null),R(null);else{const Te=we.getBoundingClientRect();R({top:Te.bottom+4,left:Te.left}),E(Pe)}},[x]),Ee=J.useCallback(Pe=>{navigator.clipboard.writeText(Pe).catch(we=>{console.error("Failed to copy text:",we)})},[]),Re=J.useCallback(()=>{const Pe=o.find(Te=>Te.longName()===x);if(!Pe||!A)return L.jsx(L.Fragment,{children:" "});const we=({label:Te,value:ke,truncate:$e})=>L.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",gap:"8px",minWidth:0},children:[L.jsxs("div",{style:$e?{overflow:"hidden",minWidth:0}:void 0,children:[L.jsxs("span",{style:{opacity:.7},children:[Te,": "]}),L.jsx("span",{style:$e?{display:"inline-block",maxWidth:"350px",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap",verticalAlign:"bottom"}:void 0,title:$e?String(ke):void 0,children:ke})]}),L.jsx("button",{onClick:()=>Ee(String(ke)),style:{padding:"2px",background:"transparent",border:"none",cursor:"pointer",color:s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0},onMouseEnter:Ne=>{Ne.currentTarget.style.color=s?"rgba(255, 255, 255, 0.9)":"rgba(0, 0, 0, 0.9)"},onMouseLeave:Ne=>{Ne.currentTarget.style.color=s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)"},title:`Copy ${Te}`,children:L.jsx(uX,{size:12})})]});return zf.createPortal(L.jsxs("div",{style:{position:"fixed",top:A.top,left:A.left,backgroundColor:s?"#1f2937":"#ffffff",border:`1px solid ${s?"#374151":"#e5e7eb"}`,borderRadius:"6px",padding:"8px 12px",minWidth:"250px",maxWidth:"400px",boxShadow:"0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",zIndex:1e4,fontSize:"11px",lineHeight:"1.5",color:s?"#e5e7eb":"#1f2937",fontFamily:"monospace",whiteSpace:"pre-wrap",wordBreak:"break-word",pointerEvents:"auto"},children:[L.jsxs("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginBottom:"6px"},children:[L.jsx("span",{style:{fontWeight:"bold",fontSize:"12px"},children:"Signal Information"}),L.jsx("button",{onClick:()=>{E(null),R(null)},style:{padding:"2px",background:"transparent",border:"none",cursor:"pointer",color:s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)",display:"flex",alignItems:"center",justifyContent:"center"},onMouseEnter:Te=>{Te.currentTarget.style.color=s?"rgba(255, 255, 255, 0.9)":"rgba(0, 0, 0, 0.9)"},onMouseLeave:Te=>{Te.currentTarget.style.color=s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)"},title:"Close",children:L.jsx(zj,{size:14})})]}),L.jsxs("div",{style:{display:"flex",flexDirection:"column",gap:"4px"},children:[L.jsx(we,{label:"Name",value:Pe.name,truncate:!0}),L.jsx(we,{label:"Frame",value:Pe.frameName,truncate:!0}),L.jsx(we,{label:"Namespace",value:Pe.namespace}),L.jsx(we,{label:"ID",value:`${Pe.namespace}:${Pe.name}`,truncate:!0}),Pe.description&&L.jsx(we,{label:"Description",value:Pe.description}),Pe.unit&&L.jsx(we,{label:"Unit",value:Pe.unit}),Pe.min!==void 0&&L.jsx(we,{label:"Min",value:Pe.min}),Pe.max!==void 0&&L.jsx(we,{label:"Max",value:Pe.max}),Pe.namedValues&&Object.keys(Pe.namedValues).length>0&&L.jsxs("div",{children:[L.jsx("div",{style:{opacity:.7,marginBottom:"2px"},children:"Named Values:"}),L.jsx("div",{style:{paddingLeft:"8px",maxHeight:"150px",overflowY:"auto"},children:Object.entries(Pe.namedValues).map(([Te,ke])=>L.jsxs("div",{style:{fontSize:"10px",display:"flex",justifyContent:"space-between",alignItems:"center",gap:"4px"},children:[L.jsxs("div",{children:[L.jsxs("span",{style:{opacity:.6},children:[Te,": "]}),L.jsx("span",{children:ke})]}),L.jsx("button",{onClick:()=>Ee(String(ke)),style:{padding:"2px",background:"transparent",border:"none",cursor:"pointer",color:s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)",display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0},onMouseEnter:$e=>{$e.currentTarget.style.color=s?"rgba(255, 255, 255, 0.9)":"rgba(0, 0, 0, 0.9)"},onMouseLeave:$e=>{$e.currentTarget.style.color=s?"rgba(255, 255, 255, 0.5)":"rgba(0, 0, 0, 0.5)"},title:"Copy value",children:L.jsx(uX,{size:10})})]},Te))})]})]})]}),document.body)},[x,A,s,o,Ee]),Ae=J.useCallback(()=>{const Pe=o.find(we=>we.longName()===x);return L.jsxs(L.Fragment,{children:[L.jsx("div",{style:{position:"absolute",top:0,left:0,right:0,bottom:0,pointerEvents:"none",zIndex:1},children:o.map((we,Te)=>{const ke=Te*i,$e=we.longName();return L.jsxs("div",{style:{position:"absolute",top:ke-4,left:8,right:8,fontSize:10,color:T7(s).buttonText,fontFamily:"monospace",display:"flex",alignItems:"center",justifyContent:"space-between"},children:[L.jsxs("div",{style:{display:"flex",alignItems:"center",gap:"4px"},children:[L.jsx("span",{children:we.name}),L.jsx("button",{ref:Ne=>{Ne&&M.current.set($e,Ne)},onClick:Ne=>ge($e,Ne.currentTarget),className:"pointer-events-auto transition-all duration-200",style:{padding:"4px",borderRadius:"50%",background:"transparent",color:s?"rgba(255, 255, 255, 0.7)":"rgba(0, 0, 0, 0.7)",border:"0",cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",width:"24px",height:"24px"},onMouseEnter:Ne=>{Ne.currentTarget.style.color=s?"rgba(255, 255, 255, 1)":"rgba(0, 0, 0, 1)"},onMouseLeave:Ne=>{Ne.currentTarget.style.color=s?"rgba(255, 255, 255, 0.7)":"rgba(0, 0, 0, 0.7)"},title:"Signal information",children:L.jsx(cX,{size:14})})]}),d&&L.jsx("button",{onClick:()=>d(we),className:`pointer-events-auto opacity-0 group-hover/area:opacity-70 hover:!opacity-100 
                                                   transition-all duration-200 p-0.5 rounded bg-black/50 hover:bg-red-600 
                                                   text-white/60 hover:text-white border-0 cursor-pointer 
                                                   flex items-center justify-center w-4 h-4 text-[10px] leading-none`,title:"Remove signal",children:L.jsx(zj,{size:12})})]},$e)})}),Pe&&A&&Re()]})},[o,s,i,d,x,A,ge]);return L.jsxs("div",{style:{position:"relative"},children:[Ae(),L.jsx($I.SciChartReact,{initChart:te,style:{width:"100%",height:de,borderRadius:0,border:"none",overflow:"hidden"}})]})}function KB(t){const e=qt.c(8);let i,n;e[0]!==t?({className:i,...n}=t,e[0]=t,e[1]=i,e[2]=n):(i=e[1],n=e[2]);let r;e[3]!==i?(r=Hr("bg-muted text-muted-foreground border border-muted-foreground border-t-0 border-s-0 in-data-[slot=tooltip-content]:bg-background/20 in-data-[slot=tooltip-content]:text-background dark:in-data-[slot=tooltip-content]:bg-background/10 h-5 w-fit min-w-5 gap-1 rounded px-1 font-sans text-xs font-medium [&_svg:not([class*='size-'])]:size-3 pointer-events-none inline-flex items-center justify-center select-none",i),e[3]=i,e[4]=r):r=e[4];let o;return e[5]!==n||e[6]!==r?(o=L.jsx("kbd",{"data-slot":"kbd",className:r,...n}),e[5]=n,e[6]=r,e[7]=o):o=e[7],o}const DDt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Timeseries"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Chart width"}),": Set the width of the chart in seconds",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Min/max"}),": Set to use signal-defined min/max for Y-axis",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Max FPS"}),": Set the maximum update frequency for the chart"]}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Navigation"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Zoom in/out"}),": ",L.jsx(KB,{children:"Alt"})," or"," ",L.jsx(KB,{className:"font-[arial]",children:"⌥"})," + scroll/pinch",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Zoom in"}),": ",L.jsx(KB,{children:"Alt"})," or"," ",L.jsx(KB,{className:"font-[arial]",children:"⌥"})," + select area",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Pan"}),": ",L.jsx(KB,{children:"Ctrl"})," + drag",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Show all"}),": Double click",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Select signal value"}),": Click on point",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Measure time"}),": First select signal value, then hover any chart to see time-diff in tooltip"]})]});function RDt(t){const e=qt.c(18),{settings:i,onChartWidthChange:n,onUseSuggestedMinMaxChange:r,onToggleSyncCharts:o,onMaxFpsChange:a,onAddSignal:s,onRemove:l}=t,u=i.chartWidthSeconds!==void 0||r!==void 0||o!==void 0||a!==void 0;let c;e[0]!==u||e[1]!==n||e[2]!==a||e[3]!==r||e[4]!==i.chartWidthSeconds||e[5]!==i.maxFps||e[6]!==i.useSuggestedMinMax?(c=u&&L.jsxs(L.Fragment,{children:[L.jsxs(Ri.Section,{title:"Settings",children:[i.chartWidthSeconds!==void 0&&n&&L.jsx(Ri.NumberStepper,{label:"Chart width",value:i.chartWidthSeconds,onChange:n,min:5,max:300,step:5,formatValue:MDt}),r&&L.jsx(Ri.Toggle,{label:"Min/max",checked:i.useSuggestedMinMax,onChange:r}),a&&L.jsx(Ri.NumberStepper,{label:"Max FPS",value:i.maxFps,onChange:a,min:5,max:120,step:5})]}),L.jsx(Ri.Divider,{})]}),e[0]=u,e[1]=n,e[2]=a,e[3]=r,e[4]=i.chartWidthSeconds,e[5]=i.maxFps,e[6]=i.useSuggestedMinMax,e[7]=c):c=e[7];let d;e[8]!==s?(d=s&&L.jsx(Ri.Button,{icon:dr.ACTION_EDIT,label:"Select signals",onClick:s}),e[8]=s,e[9]=d):d=e[9];let f;e[10]!==l?(f=l&&L.jsx(Ri.RemoveButton,{onClick:l}),e[10]=l,e[11]=f):f=e[11];let h;e[12]!==d||e[13]!==f?(h=L.jsxs(Ri.Section,{title:"Actions",children:[d,f]}),e[12]=d,e[13]=f,e[14]=h):h=e[14];let p;return e[15]!==c||e[16]!==h?(p=L.jsxs(Ri,{children:[c,h]}),e[15]=c,e[16]=h,e[17]=p):p=e[17],p}function MDt(t){return`${t}s`}function LDt(t){const e=qt.c(74),{track:i}=el(),{updatePanel:n,removePanel:r}=oC(),o=J.useRef(null),[a,s]=J.useState(80),{isDarkMode:l}=dI(),u=$V();let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c=new Map,e[0]=c):c=e[0];const d=J.useRef(c),[f,h]=J.useState(!1),[p,g]=J.useState(!1);let v;e[1]===Symbol.for("react.memo_cache_sentinel")?(v=new Set,e[1]=v):v=e[1];const y=J.useRef(v),m=t.panelConfig,b=m.unresolvedSignals&&m.unresolvedSignals.length>0;let S;e[2]===Symbol.for("react.memo_cache_sentinel")?(S=Te=>(d.current.has(Te)||d.current.set(Te,{current:[]}),d.current.get(Te)),e[2]=S):S=e[2];const _=S;let C,P;e[3]!==u||e[4]!==m.signals?(C=()=>{(()=>{let ke=!1;m.signals.forEach($e=>{const Ne=$e.longName();if(y.current.has(Ne))return;_(Ne);const ve=fe=>{const me=d.current.get(Ne);if(me)for(const Ce of fe.signals)Ce.name===$e.name&&me.current.push(Ce)},pe=new B3([$e.id],ve,IDt);u.addPendingSubscription(pe),y.current.add(Ne),ke=!0}),ke&&u.applyPendingSubscriptions()})()},P=[u,m.signals],e[3]=u,e[4]=m.signals,e[5]=C,e[6]=P):(C=e[5],P=e[6]),J.useEffect(C,P);let x;e[7]!==b||e[8]!==m.signals.length||e[9]!==m.unresolvedSignals?(x=()=>{if(!o.current)return;const Te=new ResizeObserver(ke=>{for(const $e of ke){const Ne=$e.contentRect.height;if(Ne>0){let ve=Ne-36;if(b&&m.unresolvedSignals){const me=8+m.unresolvedSignals.length*100;ve=ve-me}const pe=Math.max(1,m.signals.length),fe=Math.floor(ve/pe);s(Math.max(50,fe))}}});return Te.observe(o.current),()=>Te.disconnect()},e[7]=b,e[8]=m.signals.length,e[9]=m.unresolvedSignals,e[10]=x):x=e[10];let E;e[11]!==b||e[12]!==m.signals||e[13]!==m.unresolvedSignals?(E=[m.signals,b,m.unresolvedSignals],e[11]=b,e[12]=m.signals,e[13]=m.unresolvedSignals,e[14]=E):E=e[14],J.useEffect(x,E);const A=kDt;let R;e[15]===Symbol.for("react.memo_cache_sentinel")?(R=()=>L.jsx(rG,{icon:dr.DATA_TIMESERIES,title:"Timeseries panel",description:"Select signals to plot values over time in a chart",children:L.jsx(Za,{icon:dr.ACTION_EDIT,label:"Select signals",type:fn.PRIMARY,size:_a.SM,onClick:()=>h(!0)})}),e[15]=R):R=e[15];const M=R;let D;e[16]!==p?(D=()=>L.jsx(Za,{icon:p?dr.MEDIA_PLAY:dr.MEDIA_PAUSE,label:p?"Resume":"Pause",type:p?fn.PANEL_BUTTON_ACTIVE:fn.PANEL_BUTTON,size:_a.XS,onClick:()=>g(!p)}),e[16]=p,e[17]=D):D=e[17];const F=D;let I;e[18]!==m||e[19]!==t.panelId||e[20]!==r||e[21]!==F||e[22]!==i||e[23]!==n?(I=()=>L.jsxs("div",{className:"flex items-center gap-2",children:[F(),L.jsx(RDt,{settings:m,onChartWidthChange:Te=>{n(t.panelId,"timeseries",ke=>({...ke,chartWidthSeconds:Te})),i(Fi.ChangePanelSetting,{panelType:"timeseries",setting:"chartWidthSeconds",value:Te})},onUseSuggestedMinMaxChange:Te=>{n(t.panelId,"timeseries",ke=>({...ke,useSuggestedMinMax:Te})),i(Fi.ChangePanelSetting,{panelType:"timeseries",setting:"useSuggestedMinMax",value:Te})},onToggleSyncCharts:Te=>{n(t.panelId,"timeseries",ke=>({...ke,syncCharts:Te})),i(Fi.ChangePanelSetting,{panelType:"timeseries",setting:"syncCharts",value:Te})},onMaxFpsChange:Te=>{n(t.panelId,"timeseries",ke=>({...ke,maxFps:Te})),i(Fi.ChangePanelSetting,{panelType:"timeseries",setting:"maxFps",value:Te})},onAddSignal:()=>h(!0),onRemove:()=>{r(t.panelId),i(Fi.RemovePanelFromDashboard,{panelType:"timeseries"})}})]}),e[18]=m,e[19]=t.panelId,e[20]=r,e[21]=F,e[22]=i,e[23]=n,e[24]=I):I=e[24];const V=I;let z;e[25]!==t.panelId||e[26]!==n?(z=Te=>{n(t.panelId,"timeseries",ke=>({...ke,signals:ke.signals.filter($e=>$e.name!==Te.name)}))},e[25]=t.panelId,e[26]=n,e[27]=z):z=e[27];const G=z;let H,U,k,X,W,Y,te,oe;if(e[28]!==a||e[29]!==b||e[30]!==l||e[31]!==p||e[32]!==m.chartWidthSeconds||e[33]!==m.maxFps||e[34]!==m.signals||e[35]!==m.unresolvedSignals||e[36]!==m.useSuggestedMinMax||e[37]!==t.panelId||e[38]!==G||e[39]!==V||e[40]!==n){const Te=ke=>m.signals.length===0&&!b?M():L.jsxs(L.Fragment,{children:[b&&L.jsx(u$,{signals:m.unresolvedSignals??[],onRemoveSignal:$e=>n(t.panelId,"timeseries",Ne=>{var ve;return{...Ne,unresolvedSignals:(ve=Ne.unresolvedSignals)==null?void 0:ve.filter(pe=>!(pe.namespace===$e.namespace&&pe.frame===$e.frame&&pe.signal===$e.signal))}})}),m.signals.length>0&&L.jsx(ODt,{onPausedChange:$e=>g($e),isPaused:p,signals:m.signals,signalBuffersRef:d,getTime:A,chartHeight:ke,windowSizeMs:m.chartWidthSeconds*1e3,isDarkMode:l,groupId:t.panelId,useSuggestedMinMax:m.useSuggestedMinMax,animationMaxFps:m.maxFps,onRemoveSignal:G})]});U=WI,Y=o,te=!0,e[49]!==V?(oe=L.jsx(GI,{icon:dr.DATA_TIMESERIES,dropdown:V(),helpTooltip:DDt}),e[49]=V,e[50]=oe):oe=e[50],H=YI,k=!0,X=!1,W=Te(a),e[28]=a,e[29]=b,e[30]=l,e[31]=p,e[32]=m.chartWidthSeconds,e[33]=m.maxFps,e[34]=m.signals,e[35]=m.unresolvedSignals,e[36]=m.useSuggestedMinMax,e[37]=t.panelId,e[38]=G,e[39]=V,e[40]=n,e[41]=H,e[42]=U,e[43]=k,e[44]=X,e[45]=W,e[46]=Y,e[47]=te,e[48]=oe}else H=e[41],U=e[42],k=e[43],X=e[44],W=e[45],Y=e[46],te=e[47],oe=e[48];let de;e[51]!==H||e[52]!==k||e[53]!==X||e[54]!==W?(de=L.jsx(H,{fullHeight:k,padding:X,children:W}),e[51]=H,e[52]=k,e[53]=X,e[54]=W,e[55]=de):de=e[55];let ge;e[56]!==U||e[57]!==Y||e[58]!==te||e[59]!==oe||e[60]!==de?(ge=L.jsxs(U,{ref:Y,fullHeight:te,children:[oe,de]}),e[56]=U,e[57]=Y,e[58]=te,e[59]=oe,e[60]=de,e[61]=ge):ge=e[61];let Ee,Re;e[62]===Symbol.for("react.memo_cache_sentinel")?(Ee=[],Re=()=>h(!1),e[62]=Ee,e[63]=Re):(Ee=e[62],Re=e[63]);let Ae;e[64]!==t.panelId||e[65]!==n?(Ae=(Te,ke)=>{n(t.panelId,"timeseries",$e=>({...$e,signals:[...Te]}))},e[64]=t.panelId,e[65]=n,e[66]=Ae):Ae=e[66];let Pe;e[67]!==m.signals||e[68]!==f||e[69]!==Ae?(Pe=L.jsx(sW,{show:f,selectedSignals:m.signals,selectedFrames:Ee,handleCloseFunction:Re,selectSignalsFunction:Ae,isFramesSelectable:!1,autoSelectParentFrame:!1,enforceFrameSelection:!1}),e[67]=m.signals,e[68]=f,e[69]=Ae,e[70]=Pe):Pe=e[70];let we;return e[71]!==ge||e[72]!==Pe?(we=L.jsxs(L.Fragment,{children:[ge,Pe]}),e[71]=ge,e[72]=Pe,e[73]=we):we=e[73],we}function kDt(){return Date.now()}function IDt(){}const NDt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Video"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Sound"}),": Mute/unmute video audio"]})]});function FDt(t){const e=qt.c(20),i=t.testOffset!==void 0?t.testOffset:t.videoOffsetSeconds,n=!t.soundMuted;let r;e[0]!==t?(r=f=>t.onSoundMutedChange(!f),e[0]=t,e[1]=r):r=e[1];let o;e[2]!==n||e[3]!==r?(o=L.jsx(Ri.Section,{title:"Settings",children:L.jsx(Ri.Toggle,{label:"Sound",checked:n,onChange:r})}),e[2]=n,e[3]=r,e[4]=o):o=e[4];let a;e[5]!==i||e[6]!==t?(a=jNe()&&L.jsxs(L.Fragment,{children:[L.jsx(Ri.Divider,{}),L.jsxs(Ri.Section,{title:"Debug",children:[L.jsx(Ri.Toggle,{label:"Debug panel",checked:t.showDebugPanel,onChange:t.onShowDebugPanelChange}),t.showDebugPanel&&L.jsxs(L.Fragment,{children:[L.jsx(Ri.NumberStepper,{label:"Test offset (s)",value:i,onChange:t.onTestOffsetChange,step:.5,formatValue:BDt}),t.testOffset!==void 0&&L.jsx(Ri.Button,{icon:dr.ACTION_REFRESH,label:"Reset offset",onClick:()=>t.onTestOffsetChange(void 0),variant:"primary"})]})]})]}),e[5]=i,e[6]=t,e[7]=a):a=e[7];let s;e[8]===Symbol.for("react.memo_cache_sentinel")?(s=L.jsx(Ri.Divider,{}),e[8]=s):s=e[8];let l;e[9]!==t.onSelectVideo?(l=L.jsx(Ri.Button,{icon:dr.FILE_VIDEO,label:"Select video",onClick:t.onSelectVideo}),e[9]=t.onSelectVideo,e[10]=l):l=e[10];let u;e[11]!==t.onRemove?(u=L.jsx(Ri.RemoveButton,{onClick:t.onRemove}),e[11]=t.onRemove,e[12]=u):u=e[12];let c;e[13]!==l||e[14]!==u?(c=L.jsxs(Ri.Section,{title:"Actions",children:[l,u]}),e[13]=l,e[14]=u,e[15]=c):c=e[15];let d;return e[16]!==o||e[17]!==a||e[18]!==c?(d=L.jsxs(Ri,{children:[o,a,s,c]}),e[16]=o,e[17]=a,e[18]=c,e[19]=d):d=e[19],d}function BDt(t){return t.toFixed(1)}function jDt(t){const e=qt.c(38),{track:i}=el(),{updatePanel:n,removePanel:r}=oC(),o=t.panelConfig,a=J.useRef(null),[s,l]=J.useState(400),[u,c]=J.useState(!0),[d,f]=J.useState(!1),[h,p]=J.useState(void 0),[g,v]=J.useState(null),[y,m]=J.useState(!1),b=o.videoFilePath,S=o.videoName,_=o.recordingSessionPath,C=b!=null&&b.length>0||S!=null&&S.length>0,P=Qke(_||""),x=pte();let E;e:{if(!C){E={resolvedVideoFile:void 0,resolvedSessionPath:void 0,ambiguous:!1};break e}const Ne=P==null?void 0:P.recordingSessionInfo.videos.find(ve=>ve.location===b);if(Ne){E={resolvedVideoFile:Ne,resolvedSessionPath:_,ambiguous:!1};break e}if(S){let ve;e[0]!==S?(ve=fe=>fe.recordingSessionInfo.videos.filter(me=>me.name===S).map(me=>({videoFile:me,sessionPath:fe.recordingSessionInfo.path})),e[0]=S,e[1]=ve):ve=e[1];const pe=x.flatMap(ve);if(pe.length===1){E={resolvedVideoFile:pe[0].videoFile,resolvedSessionPath:pe[0].sessionPath,ambiguous:!1};break e}if(pe.length>1){E={resolvedVideoFile:void 0,resolvedSessionPath:void 0,ambiguous:!0};break e}}E={resolvedVideoFile:void 0,resolvedSessionPath:void 0,ambiguous:!1}}const{resolvedVideoFile:A,resolvedSessionPath:R,ambiguous:M}=E;let D,F;e[2]===Symbol.for("react.memo_cache_sentinel")?(D=()=>{if(!a.current)return;const Ne=new ResizeObserver(ve=>{for(const pe of ve){const fe=pe.contentRect.height;fe>0&&l(Math.max(200,fe-36-16))}});return Ne.observe(a.current),()=>Ne.disconnect()},F=[],e[2]=D,e[3]=F):(D=e[2],F=e[3]),J.useEffect(D,F);let I;e[4]!==o.id||e[5]!==r||e[6]!==i?(I=()=>{r(o.id),i(Fi.RemovePanelFromDashboard,{panelType:"video"})},e[4]=o.id,e[5]=r,e[6]=i,e[7]=I):I=e[7];const V=I;let z;e[8]!==o.id||e[9]!==i||e[10]!==n?(z=Ne=>{n(o.id,"video",ve=>({...ve,videoFilePath:Ne.videoFilePath,recordingSessionPath:Ne.recordingSessionPath,videoName:Ne.videoName})),i(Fi.AddVideoToPanel)},e[8]=o.id,e[9]=i,e[10]=n,e[11]=z):z=e[11];const G=z;let H;e[12]!==b||e[13]!==g?(H=()=>{if(!g)return b;const Ne=g.hasEnded?"Video has ended":`Offset: ${g.offsetSeconds}s`,ve=`${Hk(g.currentTimeSeconds*1e3)} / ${Hk(g.lengthSeconds*1e3)}`;return`${Ne} · ${ve}`},e[12]=b,e[13]=g,e[14]=H):H=e[14];const U=H;let k;e[15]===Symbol.for("react.memo_cache_sentinel")?(k=()=>L.jsx(rG,{icon:dr.FILE_VIDEO,title:"Video panel",description:"Select video from a recording session for synchronized playback",descriptionClassName:"max-w-sm",children:L.jsx(Za,{icon:dr.ACTION_ADD,label:"Select video",type:fn.PRIMARY,size:_a.SM,onClick:()=>m(!0)})}),e[15]=k):k=e[15];const X=k,W=()=>C?x.length===0?L.jsx(vD,{title:"No recording session open",message:"No recording sessions are currently open.",suggestion:"Open a recording session to view this video."}):M?L.jsx(vD,{title:"Ambiguous video",message:`Multiple videos named "${S}" were found across open recording sessions.`,suggestion:"Re-select the video to specify which recording session to use."}):!A||!R?L.jsx(vD,{title:"Video file not found",message:`The video "${S||b}" was not found in any open recording session.`,suggestion:"The video may have been removed or renamed."}):L.jsx(twt,{panelKey:t.panelId,removePanelFunction:V,videoPanelSettings:{videoFilePath:A.location,recordingSessionPath:R},hideHeader:!0,height:s,soundMuted:u,onSoundMutedChange:c,showDebugPanel:d,onShowDebugPanelChange:f,testOffset:h,onTestOffsetChange:p,onVideoInfoChange:v}):X();let Y;e[16]!==i?(Y=Ne=>{c(Ne),i(Fi.ChangePanelSetting,{panelType:"video",setting:"soundMuted",value:Ne})},e[16]=i,e[17]=Y):Y=e[17];const te=(g==null?void 0:g.offsetSeconds)??0;let oe;e[18]===Symbol.for("react.memo_cache_sentinel")?(oe=()=>m(!0),e[18]=oe):oe=e[18];let de;e[19]!==V||e[20]!==d||e[21]!==u||e[22]!==Y||e[23]!==te||e[24]!==h?(de=L.jsx(FDt,{soundMuted:u,onSoundMutedChange:Y,showDebugPanel:d,onShowDebugPanelChange:f,testOffset:h,onTestOffsetChange:p,videoOffsetSeconds:te,onSelectVideo:oe,onRemove:V}),e[19]=V,e[20]=d,e[21]=u,e[22]=Y,e[23]=te,e[24]=h,e[25]=de):de=e[25];let ge;e[26]!==U||e[27]!==g?(ge=g&&L.jsx("span",{className:"text-[10px] text-muted-foreground block truncate",children:U()}),e[26]=U,e[27]=g,e[28]=ge):ge=e[28];const Ee=YI,Re=!0,Ae=!1,Pe=W();let we;e[29]!==Ee||e[30]!==Pe?(we=L.jsx(Ee,{fullHeight:Re,padding:Ae,children:Pe}),e[29]=Ee,e[30]=Pe,e[31]=we):we=e[31];let Te;e[32]===Symbol.for("react.memo_cache_sentinel")?(Te=()=>m(!1),e[32]=Te):Te=e[32];let ke;e[33]!==G?(ke=(Ne,ve)=>{G(ve),m(!1)},e[33]=G,e[34]=ke):ke=e[34];let $e;return e[35]!==y||e[36]!==ke?($e=L.jsx(mbt,{show:y,handleCloseFunction:Te,savePanelFunction:ke}),e[35]=y,e[36]=ke,e[37]=$e):$e=e[37],L.jsxs(L.Fragment,{children:[L.jsxs(WI,{ref:a,fullHeight:!0,children:[L.jsx(GI,{icon:dr.FILE_VIDEO,helpTooltip:NDt,dropdown:de,children:L.jsxs("div",{className:"min-w-0 flex-1",children:[L.jsxs("div",{className:"flex items-center gap-1",children:[L.jsx("span",{className:"text-xs font-sm truncate text-left",title:(A==null?void 0:A.location)||b,children:(A==null?void 0:A.name)||""}),A&&L.jsx(FD,{side:"bottom",content:L.jsxs("div",{className:"text-xs space-y-1",children:[L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Recording: "}),R]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Video name: "}),A.name]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Video path: "}),A.location]}),L.jsxs("div",{children:[L.jsx("span",{className:"text-neutral-400",children:"Offset: "}),A.offsetMs," ms"]})]}),children:L.jsx(Wr,{type:dr.STATUS_INFO,className:"w-3 h-3 text-muted-foreground shrink-0 cursor-help"})})]}),ge]})}),we]}),$e]})}class lr{static getElements(e,i=document){if(typeof e=="string"){const n="getElementById"in i?i:void 0;if(n&&!isNaN(+e[0])){const o=n.getElementById(e);return o?[o]:[]}let r=i.querySelectorAll(e);if(!r.length&&e[0]!=="."&&e[0]!=="#"&&(r=i.querySelectorAll("."+e),r.length||(r=i.querySelectorAll("#"+e)),!r.length)){const o=i.querySelector(`[gs-id="${e}"]`);return o?[o]:[]}return Array.from(r)}return[e]}static getElement(e,i=document){if(typeof e=="string"){const n="getElementById"in i?i:void 0;if(!e.length)return null;if(n&&e[0]==="#")return n.getElementById(e.substring(1));if(e[0]==="#"||e[0]==="."||e[0]==="[")return i.querySelector(e);if(n&&!isNaN(+e[0]))return n.getElementById(e);let r=i.querySelector(e);return n&&!r&&(r=n.getElementById(e)),r||(r=i.querySelector("."+e)),r}return e}static lazyLoad(e){var i,n;return e.lazyLoad||((n=(i=e.grid)==null?void 0:i.opts)==null?void 0:n.lazyLoad)&&e.lazyLoad!==!1}static createDiv(e,i){const n=document.createElement("div");return e.forEach(r=>{r&&n.classList.add(r)}),i==null||i.appendChild(n),n}static shouldSizeToContent(e,i=!1){return(e==null?void 0:e.grid)&&(i?e.sizeToContent===!0||e.grid.opts.sizeToContent===!0&&e.sizeToContent===void 0:!!e.sizeToContent||e.grid.opts.sizeToContent&&e.sizeToContent!==!1)}static isIntercepted(e,i){return!(e.y>=i.y+i.h||e.y+e.h<=i.y||e.x+e.w<=i.x||e.x>=i.x+i.w)}static isTouching(e,i){return lr.isIntercepted(e,{x:i.x-.5,y:i.y-.5,w:i.w+1,h:i.h+1})}static areaIntercept(e,i){const n=e.x>i.x?e.x:i.x,r=e.x+e.w<i.x+i.w?e.x+e.w:i.x+i.w;if(r<=n)return 0;const o=e.y>i.y?e.y:i.y,a=e.y+e.h<i.y+i.h?e.y+e.h:i.y+i.h;return a<=o?0:(r-n)*(a-o)}static area(e){return e.w*e.h}static sort(e,i=1){return e.sort((r,o)=>{const a=i*((r.y??1e4)-(o.y??1e4));return a===0?i*((r.x??1e4)-(o.x??1e4)):a})}static find(e,i){return i?e.find(n=>n.id===i):void 0}static toBool(e){return typeof e=="boolean"?e:typeof e=="string"?(e=e.toLowerCase(),!(e===""||e==="no"||e==="false"||e==="0")):!!e}static toNumber(e){return e===null||e.length===0?void 0:Number(e)}static parseHeight(e){let i,n="px";if(typeof e=="string")if(e==="auto"||e==="")i=0;else{const r=e.match(/^(-[0-9]+\.[0-9]+|[0-9]*\.[0-9]+|-[0-9]+|[0-9]+)(px|em|rem|vh|vw|%|cm|mm)?$/);if(!r)throw new Error(`Invalid height val = ${e}`);n=r[2]||"px",i=parseFloat(r[1])}else i=e;return{h:i,unit:n}}static defaults(e,...i){return i.forEach(n=>{for(const r in n){if(!n.hasOwnProperty(r))return;e[r]===null||e[r]===void 0?e[r]=n[r]:typeof n[r]=="object"&&typeof e[r]=="object"&&lr.defaults(e[r],n[r])}}),e}static same(e,i){if(typeof e!="object")return e==i;if(typeof e!=typeof i||Object.keys(e).length!==Object.keys(i).length)return!1;for(const n in e)if(e[n]!==i[n])return!1;return!0}static copyPos(e,i,n=!1){return i.x!==void 0&&(e.x=i.x),i.y!==void 0&&(e.y=i.y),i.w!==void 0&&(e.w=i.w),i.h!==void 0&&(e.h=i.h),n&&(i.minW&&(e.minW=i.minW),i.minH&&(e.minH=i.minH),i.maxW&&(e.maxW=i.maxW),i.maxH&&(e.maxH=i.maxH)),e}static samePos(e,i){return e&&i&&e.x===i.x&&e.y===i.y&&(e.w||1)===(i.w||1)&&(e.h||1)===(i.h||1)}static sanitizeMinMax(e){e.minW||delete e.minW,e.minH||delete e.minH,e.maxW||delete e.maxW,e.maxH||delete e.maxH}static removeInternalAndSame(e,i){if(!(typeof e!="object"||typeof i!="object")&&!(Array.isArray(e)||Array.isArray(i)))for(let n in e){const r=e[n],o=i[n];n[0]==="_"||r===o?delete e[n]:r&&typeof r=="object"&&o!==void 0&&(lr.removeInternalAndSame(r,o),Object.keys(r).length||delete e[n])}}static removeInternalForSave(e,i=!0){for(let n in e)(n[0]==="_"||e[n]===null||e[n]===void 0)&&delete e[n];delete e.grid,i&&delete e.el,e.autoPosition||delete e.autoPosition,e.noResize||delete e.noResize,e.noMove||delete e.noMove,e.locked||delete e.locked,(e.w===1||e.w===e.minW)&&delete e.w,(e.h===1||e.h===e.minH)&&delete e.h}static throttle(e,i){let n=!1;return(...r)=>{n||(n=!0,setTimeout(()=>{e(...r),n=!1},i))}}static removePositioningStyles(e){const i=e.style;i.position&&i.removeProperty("position"),i.left&&i.removeProperty("left"),i.top&&i.removeProperty("top"),i.width&&i.removeProperty("width"),i.height&&i.removeProperty("height")}static getScrollElement(e){if(!e)return document.scrollingElement||document.documentElement;const i=getComputedStyle(e);return/(auto|scroll)/.test(i.overflow+i.overflowY)?e:lr.getScrollElement(e.parentElement)}static updateScrollPosition(e,i,n){const r=lr.getScrollElement(e);if(!r)return;const o=e.getBoundingClientRect(),a=r.getBoundingClientRect(),s=window.innerHeight||document.documentElement.clientHeight,l=o.bottom-Math.min(a.bottom,s),u=o.top-Math.max(a.top,0),c=r.scrollTop;u<0&&n<0?e.offsetHeight>a.height?r.scrollTop+=n:r.scrollTop+=Math.abs(u)>Math.abs(n)?n:u:l>0&&n>0&&(e.offsetHeight>a.height?r.scrollTop+=n:r.scrollTop+=l>n?n:l),i.top+=r.scrollTop-c}static updateScrollResize(e,i,n){const r=lr.getScrollElement(i),o=r.clientHeight,a=r===lr.getScrollElement()?0:r.getBoundingClientRect().top,s=e.clientY-a,l=s<n,u=s>o-n;l?r.scrollBy({behavior:"smooth",top:s-n}):u&&r.scrollBy({behavior:"smooth",top:n-(o-s)})}static clone(e){return e==null||typeof e!="object"?e:e instanceof Array?[...e]:{...e}}static cloneDeep(e){const i=["parentGrid","el","grid","subGrid","engine"],n=lr.clone(e);for(const r in n)n.hasOwnProperty(r)&&typeof n[r]=="object"&&r.substring(0,2)!=="__"&&!i.find(o=>o===r)&&(n[r]=lr.cloneDeep(e[r]));return n}static cloneNode(e){const i=e.cloneNode(!0);return i.removeAttribute("id"),i}static appendTo(e,i){let n;typeof i=="string"?n=lr.getElement(i):n=i,n&&n.appendChild(e)}static addElStyles(e,i){if(i instanceof Object)for(const n in i)i.hasOwnProperty(n)&&(Array.isArray(i[n])?i[n].forEach(r=>{e.style[n]=r}):e.style[n]=i[n])}static initEvent(e,i){const n={type:i.type},r={button:0,which:0,buttons:1,bubbles:!0,cancelable:!0,target:i.target?i.target:e.target};return["altKey","ctrlKey","metaKey","shiftKey"].forEach(o=>n[o]=e[o]),["pageX","pageY","clientX","clientY","screenX","screenY"].forEach(o=>n[o]=e[o]),{...n,...r}}static simulateMouseEvent(e,i,n){const r=e,o=new MouseEvent(i,{bubbles:!0,composed:!0,cancelable:!0,view:window,detail:1,screenX:e.screenX,screenY:e.screenY,clientX:e.clientX,clientY:e.clientY,ctrlKey:r.ctrlKey??!1,altKey:r.altKey??!1,shiftKey:r.shiftKey??!1,metaKey:r.metaKey??!1,button:0,relatedTarget:e.target});(n||e.target).dispatchEvent(o)}static getValuesFromTransformedElement(e){const i=document.createElement("div");lr.addElStyles(i,{opacity:"0",position:"fixed",top:"0px",left:"0px",width:"1px",height:"1px",zIndex:"-999999"}),e.appendChild(i);const n=i.getBoundingClientRect();return e.removeChild(i),i.remove(),{xScale:1/n.width,yScale:1/n.height,xOffset:n.left,yOffset:n.top}}static swap(e,i,n){if(!e)return;const r=e[i];e[i]=e[n],e[n]=r}static canBeRotated(e){var i;return!(!e||e.w===e.h||e.locked||e.noResize||(i=e.grid)!=null&&i.opts.disableResize||e.minW&&e.minW===e.maxW||e.minH&&e.minH===e.maxH)}}class uS{constructor(e={}){this.addedNodes=[],this.removedNodes=[],this.defaultColumn=12,this.column=e.column||this.defaultColumn,this.column>this.defaultColumn&&(this.defaultColumn=this.column),this.maxRow=e.maxRow,this._float=e.float,this.nodes=e.nodes||[],this.onChange=e.onChange}batchUpdate(e=!0,i=!0){return!!this.batchMode===e?this:(this.batchMode=e,e?(this._prevFloat=this._float,this._float=!0,this.cleanNodes(),this.saveInitial()):(this._float=this._prevFloat,delete this._prevFloat,i&&this._packNodes(),this._notify()),this)}_useEntireRowArea(e,i){return(!this.float||this.batchMode&&!this._prevFloat)&&!this._hasLocked&&(!e._moving||e._skipDown||i.y<=e.y)}_fixCollisions(e,i=e,n,r={}){if(this.sortNodes(-1),n=n||this.collide(e,i),!n)return!1;if(e._moving&&!r.nested&&!this.float&&this.swap(e,n))return!0;let o=i;!this._loading&&this._useEntireRowArea(e,i)&&(o={x:0,w:this.column,y:i.y,h:i.h},n=this.collide(e,o,r.skip));let a=!1;const s={nested:!0,pack:!1};let l=0;for(;n=n||this.collide(e,o,r.skip);){if(l++>this.nodes.length*2)throw new Error("Infinite collide check");let u;if(n.locked||this._loading||e._moving&&!e._skipDown&&i.y>e.y&&!this.float&&(!this.collide(n,{...n,y:e.y},e)||!this.collide(n,{...n,y:i.y-n.h},e))){e._skipDown=e._skipDown||i.y>e.y;const c={...i,y:n.y+n.h,...s};u=this._loading&&lr.samePos(e,c)?!0:this.moveNode(e,c),(n.locked||this._loading)&&u?lr.copyPos(i,e):!n.locked&&u&&r.pack&&(this._packNodes(),i.y=n.y+n.h,lr.copyPos(e,i)),a=a||u}else u=this.moveNode(n,{...n,y:i.y+i.h,skip:e,...s});if(!u)return a;n=void 0}return a}collide(e,i=e,n){const r=e._id,o=n==null?void 0:n._id;return this.nodes.find(a=>a._id!==r&&a._id!==o&&lr.isIntercepted(a,i))}collideAll(e,i=e,n){const r=e._id,o=n==null?void 0:n._id;return this.nodes.filter(a=>a._id!==r&&a._id!==o&&lr.isIntercepted(a,i))}directionCollideCoverage(e,i,n){if(!i.rect||!e._rect)return;const r=e._rect,o={...i.rect};o.y>r.y?(o.h+=o.y-r.y,o.y=r.y):o.h+=r.y-o.y,o.x>r.x?(o.w+=o.x-r.x,o.x=r.x):o.w+=r.x-o.x;let a,s=.5;for(let l of n){if(l.locked||!l._rect)break;const u=l._rect;let c=Number.MAX_VALUE,d=Number.MAX_VALUE;r.y<u.y?c=(o.y+o.h-u.y)/u.h:r.y+r.h>u.y+u.h&&(c=(u.y+u.h-o.y)/u.h),r.x<u.x?d=(o.x+o.w-u.x)/u.w:r.x+r.w>u.x+u.w&&(d=(u.x+u.w-o.x)/u.w);const f=Math.min(d,c);f>s&&(s=f,a=l)}return i.collide=a,a}cacheRects(e,i,n,r,o,a){return this.nodes.forEach(s=>s._rect={y:s.y*i+n,x:s.x*e+a,w:s.w*e-a-r,h:s.h*i-n-o}),this}swap(e,i){if(!i||i.locked||!e||e.locked)return!1;function n(){const o=i.x,a=i.y;return i.x=e.x,i.y=e.y,e.h!=i.h?(e.x=o,e.y=i.y+i.h):e.w!=i.w?(e.x=i.x+i.w,e.y=a):(e.x=o,e.y=a),e._dirty=i._dirty=!0,!0}let r;if(e.w===i.w&&e.h===i.h&&(e.x===i.x||e.y===i.y)&&(r=lr.isTouching(e,i)))return n();if(r!==!1){if(e.w===i.w&&e.x===i.x&&(r||(r=lr.isTouching(e,i)))){if(i.y<e.y){const o=e;e=i,i=o}return n()}if(r!==!1){if(e.h===i.h&&e.y===i.y&&(r||(r=lr.isTouching(e,i)))){if(i.x<e.x){const o=e;e=i,i=o}return n()}return!1}}}isAreaEmpty(e,i,n,r){const o={x:e||0,y:i||0,w:n||1,h:r||1};return!this.collide(o)}compact(e="compact",i=!0){if(this.nodes.length===0)return this;i&&this.sortNodes();const n=this.batchMode;n||this.batchUpdate();const r=this._inColumnResize;r||(this._inColumnResize=!0);const o=this.nodes;return this.nodes=[],o.forEach((a,s,l)=>{let u;a.locked||(a.autoPosition=!0,e==="list"&&s&&(u=l[s-1])),this.addNode(a,!1,u)}),r||delete this._inColumnResize,n||this.batchUpdate(!1),this}set float(e){this._float!==e&&(this._float=e||!1,e||this._packNodes()._notify())}get float(){return this._float||!1}sortNodes(e=1){return this.nodes=lr.sort(this.nodes,e),this}_packNodes(){return this.batchMode?this:(this.sortNodes(),this.float?this.nodes.forEach(e=>{if(e._updating||e._orig===void 0||e.y===e._orig.y)return;let i=e.y;for(;i>e._orig.y;)--i,this.collide(e,{x:e.x,y:i,w:e.w,h:e.h})||(e._dirty=!0,e.y=i)}):this.nodes.forEach((e,i)=>{if(!e.locked)for(;e.y>0;){const n=i===0?0:e.y-1;if(!(i===0||!this.collide(e,{x:e.x,y:n,w:e.w,h:e.h})))break;e._dirty=e.y!==n,e.y=n}}),this)}prepareNode(e,i){e._id=e._id??uS._idSeq++;const n=e.id;if(n){let o=1;for(;this.nodes.find(a=>a.id===e.id&&a!==e);)e.id=n+"_"+o++}(e.x===void 0||e.y===void 0||e.x===null||e.y===null)&&(e.autoPosition=!0);const r={x:0,y:0,w:1,h:1};return lr.defaults(e,r),e.autoPosition||delete e.autoPosition,e.noResize||delete e.noResize,e.noMove||delete e.noMove,lr.sanitizeMinMax(e),typeof e.x=="string"&&(e.x=Number(e.x)),typeof e.y=="string"&&(e.y=Number(e.y)),typeof e.w=="string"&&(e.w=Number(e.w)),typeof e.h=="string"&&(e.h=Number(e.h)),isNaN(e.x)&&(e.x=r.x,e.autoPosition=!0),isNaN(e.y)&&(e.y=r.y,e.autoPosition=!0),isNaN(e.w)&&(e.w=r.w),isNaN(e.h)&&(e.h=r.h),this.nodeBoundFix(e,i),e}nodeBoundFix(e,i){const n=e._orig||lr.copyPos({},e);if(e.maxW&&(e.w=Math.min(e.w||1,e.maxW)),e.maxH&&(e.h=Math.min(e.h||1,e.maxH)),e.minW&&(e.w=Math.max(e.w||1,e.minW)),e.minH&&(e.h=Math.max(e.h||1,e.minH)),(e.x||0)+(e.w||1)>this.column&&this.column<this.defaultColumn&&!this._inColumnResize&&!this.skipCacheUpdate&&e._id!=null&&this.findCacheLayout(e,this.defaultColumn)===-1){const o={...e};o.autoPosition||o.x===void 0?(delete o.x,delete o.y):o.x=Math.min(this.defaultColumn-1,o.x),o.w=Math.min(this.defaultColumn,o.w||1),this.cacheOneLayout(o,this.defaultColumn)}return e.w>this.column?e.w=this.column:e.w<1&&(e.w=1),this.maxRow&&e.h>this.maxRow?e.h=this.maxRow:e.h<1&&(e.h=1),e.x<0&&(e.x=0),e.y<0&&(e.y=0),e.x+e.w>this.column&&(i?e.w=this.column-e.x:e.x=this.column-e.w),this.maxRow&&e.y+e.h>this.maxRow&&(i?e.h=this.maxRow-e.y:e.y=this.maxRow-e.h),lr.samePos(e,n)||(e._dirty=!0),this}getDirtyNodes(e){return e?this.nodes.filter(i=>i._dirty&&!lr.samePos(i,i._orig)):this.nodes.filter(i=>i._dirty)}_notify(e){if(this.batchMode||!this.onChange)return this;const i=(e||[]).concat(this.getDirtyNodes());return this.onChange(i),this}cleanNodes(){return this.batchMode?this:(this.nodes.forEach(e=>{delete e._dirty,delete e._lastTried}),this)}saveInitial(){return this.nodes.forEach(e=>{e._orig=lr.copyPos({},e),delete e._dirty}),this._hasLocked=this.nodes.some(e=>e.locked),this}restoreInitial(){return this.nodes.forEach(e=>{!e._orig||lr.samePos(e,e._orig)||(lr.copyPos(e,e._orig),e._dirty=!0)}),this._notify(),this}findEmptyPosition(e,i=this.nodes,n=this.column,r){const o=r?r.y*n+(r.x+r.w):0;let a=!1;for(let s=o;!a;++s){const l=s%n,u=Math.floor(s/n);if(l+e.w>n)continue;const c={x:l,y:u,w:e.w,h:e.h};i.find(d=>lr.isIntercepted(c,d))||((e.x!==l||e.y!==u)&&(e._dirty=!0),e.x=l,e.y=u,delete e.autoPosition,a=!0)}return a}addNode(e,i=!1,n){const r=this.nodes.find(a=>a._id===e._id);if(r)return r;this._inColumnResize?this.nodeBoundFix(e):this.prepareNode(e),delete e._temporaryRemoved,delete e._removeDOM;let o;return e.autoPosition&&this.findEmptyPosition(e,this.nodes,this.column,n)&&(delete e.autoPosition,o=!0),this.nodes.push(e),i&&this.addedNodes.push(e),o||this._fixCollisions(e),this.batchMode||this._packNodes()._notify(),e}removeNode(e,i=!0,n=!1){return this.nodes.find(r=>r._id===e._id)?(n&&this.removedNodes.push(e),i&&(e._removeDOM=!0),this.nodes=this.nodes.filter(r=>r._id!==e._id),e._isAboutToRemove||this._packNodes(),this._notify([e]),this):this}removeAll(e=!0,i=!0){if(delete this._layouts,!this.nodes.length)return this;e&&this.nodes.forEach(r=>r._removeDOM=!0);const n=this.nodes;return this.removedNodes=i?n:[],this.nodes=[],this._notify(n)}moveNodeCheck(e,i){if(!this.changedPosConstrain(e,i))return!1;if(i.pack=!0,!this.maxRow)return this.moveNode(e,i);let n;const r=new uS({column:this.column,float:this.float,nodes:this.nodes.map(a=>a._id===e._id?(n={...a},n):{...a})});if(!n)return!1;const o=r.moveNode(n,i)&&r.getRow()<=Math.max(this.getRow(),this.maxRow);if(!o&&!i.resizing&&i.collide){const a=i.collide.el.gridstackNode;if(this.swap(e,a))return this._notify(),!0}return o?(r.nodes.filter(a=>a._dirty).forEach(a=>{const s=this.nodes.find(l=>l._id===a._id);s&&(lr.copyPos(s,a),s._dirty=!0)}),this._notify(),!0):!1}willItFit(e){if(delete e._willFitPos,!this.maxRow)return!0;const i=new uS({column:this.column,float:this.float,nodes:this.nodes.map(r=>({...r}))}),n={...e};return this.cleanupNode(n),delete n.el,delete n._id,delete n.content,delete n.grid,i.addNode(n),i.getRow()<=this.maxRow?(e._willFitPos=lr.copyPos({},n),!0):!1}changedPosConstrain(e,i){return i.w=i.w||e.w,i.h=i.h||e.h,e.x!==i.x||e.y!==i.y?!0:(e.maxW&&(i.w=Math.min(i.w,e.maxW)),e.maxH&&(i.h=Math.min(i.h,e.maxH)),e.minW&&(i.w=Math.max(i.w,e.minW)),e.minH&&(i.h=Math.max(i.h,e.minH)),e.w!==i.w||e.h!==i.h)}moveNode(e,i){var u,c;if(!e||!i)return!1;let n;i.pack===void 0&&!this.batchMode&&(n=i.pack=!0),typeof i.x!="number"&&(i.x=e.x),typeof i.y!="number"&&(i.y=e.y),typeof i.w!="number"&&(i.w=e.w),typeof i.h!="number"&&(i.h=e.h);const r=e.w!==i.w||e.h!==i.h,o=lr.copyPos({},e,!0);if(lr.copyPos(o,i),this.nodeBoundFix(o,r),lr.copyPos(i,o),!i.forceCollide&&lr.samePos(e,i))return!1;const a=lr.copyPos({},e),s=this.collideAll(e,o,i.skip);let l=!0;if(s.length){const d=e._moving&&!i.nested;let f=d?this.directionCollideCoverage(e,i,s):s[0];if(d&&f&&((c=(u=e.grid)==null?void 0:u.opts)!=null&&c.subGridDynamic)&&!e.grid._isTemp){const h=lr.areaIntercept(i.rect,f._rect),p=lr.area(i.rect),g=lr.area(f._rect);h/(p<g?p:g)>.8&&(f.grid.makeSubGrid(f.el,void 0,e),f=void 0)}f?l=!this._fixCollisions(e,o,f,i):(l=!1,n&&delete i.pack)}return l&&!lr.samePos(e,o)&&(e._dirty=!0,lr.copyPos(e,o)),i.pack&&this._packNodes()._notify(),!lr.samePos(e,a)}getRow(){return this.nodes.reduce((e,i)=>Math.max(e,i.y+i.h),0)}beginUpdate(e){return e._updating||(e._updating=!0,delete e._skipDown,this.batchMode||this.saveInitial()),this}endUpdate(){const e=this.nodes.find(i=>i._updating);return e&&(delete e._updating,delete e._skipDown),this}save(e=!0,i,n){var s;const r=((s=this._layouts)==null?void 0:s.length)||0;let o;r&&(n?n!==this.column&&(o=this._layouts[n]):this.column!==r-1&&(o=this._layouts[r-1]));const a=[];return this.sortNodes(),this.nodes.forEach(l=>{const u=o==null?void 0:o.find(d=>d._id===l._id),c={...l,...u||{}};lr.removeInternalForSave(c,!e),i&&i(l,c),a.push(c)}),a}layoutsNodesChange(e){return!this._layouts||this._inColumnResize?this:(this._layouts.forEach((i,n)=>{if(!i||n===this.column)return this;if(n<this.column)this._layouts[n]=void 0;else{const r=n/this.column;e.forEach(o=>{if(!o._orig)return;const a=i.find(s=>s._id===o._id);a&&(a.y>=0&&o.y!==o._orig.y&&(a.y+=o.y-o._orig.y,a.y<0&&(a.y=0)),o.x!==o._orig.x&&(a.x=Math.round(o.x*r),a.x<0&&(a.x=0)),o.w!==o._orig.w&&(a.w=Math.round(o.w*r),a.w<1&&(a.w=1)))})}}),this)}columnChanged(e,i,n="moveScale"){var s;if(!this.nodes.length||!i||e===i)return this;const r=n==="compact"||n==="list";r&&this.sortNodes(1),i<e&&this.cacheLayout(this.nodes,e),this.batchUpdate();let o=[],a=r?this.nodes:lr.sort(this.nodes,-1);if(i>e&&this._layouts){const l=this._layouts[i]||[],u=this._layouts.length-1;!l.length&&e!==u&&((s=this._layouts[u])!=null&&s.length)&&(e=u,this._layouts[u].forEach(c=>{const d=a.find(f=>f._id===c._id);d&&(!r&&!c.autoPosition&&(d.x=c.x??d.x,d.y=c.y??d.y),d.w=c.w??d.w,(c.x==null||c.y===void 0)&&(d.autoPosition=!0))})),l.forEach(c=>{const d=a.findIndex(f=>f._id===c._id);if(d!==-1){const f=a[d];if(r){f.w=c.w;return}(c.autoPosition||isNaN(c.x)||isNaN(c.y))&&this.findEmptyPosition(c,o),c.autoPosition||(f.x=c.x??f.x,f.y=c.y??f.y,f.w=c.w??f.w,o.push(f)),a.splice(d,1)}})}if(r)this.compact(n,!1);else{if(a.length)if(typeof n=="function")n(i,e,o,a);else{const l=r||n==="none"?1:i/e,u=n==="move"||n==="moveScale",c=n==="scale"||n==="moveScale";a.forEach(d=>{d.x=i===1?0:u?Math.round(d.x*l):Math.min(d.x,i-1),d.w=i===1||e===1?1:c?Math.round(d.w*l)||1:Math.min(d.w,i),o.push(d)}),a=[]}o=lr.sort(o,-1),this._inColumnResize=!0,this.nodes=[],o.forEach(l=>{this.addNode(l,!1),delete l._orig})}return this.nodes.forEach(l=>delete l._orig),this.batchUpdate(!1,!r),delete this._inColumnResize,this}cacheLayout(e,i,n=!1){const r=[];return e.forEach((o,a)=>{if(o._id===void 0){const s=o.id?this.nodes.find(l=>l.id===o.id):void 0;o._id=(s==null?void 0:s._id)??uS._idSeq++}r[a]={x:o.x,y:o.y,w:o.w,_id:o._id}}),this._layouts=n?[]:this._layouts||[],this._layouts[i]=r,this}cacheOneLayout(e,i){e._id=e._id??uS._idSeq++;const n={x:e.x,y:e.y,w:e.w,_id:e._id};(e.autoPosition||e.x===void 0)&&(delete n.x,delete n.y,e.autoPosition&&(n.autoPosition=!0)),this._layouts=this._layouts||[],this._layouts[i]=this._layouts[i]||[];const r=this.findCacheLayout(e,i);return r===-1?this._layouts[i].push(n):this._layouts[i][r]=n,this}findCacheLayout(e,i){var n,r;return((r=(n=this._layouts)==null?void 0:n[i])==null?void 0:r.findIndex(o=>o._id===e._id))??-1}removeNodeFromLayoutCache(e){if(this._layouts)for(let i=0;i<this._layouts.length;i++){const n=this.findCacheLayout(e,i);n!==-1&&this._layouts[i].splice(n,1)}}cleanupNode(e){for(const i in e)i[0]==="_"&&i!=="_id"&&delete e[i];return this}}uS._idSeq=0;const gp={alwaysShowResizeHandle:"mobile",animate:!0,auto:!0,cellHeight:"auto",cellHeightThrottle:100,cellHeightUnit:"px",column:12,draggable:{handle:".grid-stack-item-content",appendTo:"body",scroll:!0},handle:".grid-stack-item-content",itemClass:"grid-stack-item",margin:10,marginUnit:"px",maxRow:0,minRow:0,placeholderClass:"grid-stack-placeholder",placeholderText:"",removableOptions:{accept:"grid-stack-item",decline:"grid-stack-non-removable"},resizable:{handles:"se"},rtl:"auto"};class sn{}const Ov=typeof window<"u"&&typeof document<"u"&&("ontouchstart"in document||"ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0);class Tp{}function c$(t,e){t.touches.length>1||(t.cancelable&&t.preventDefault(),lr.simulateMouseEvent(t.changedTouches[0],e))}function iHe(t,e){t.cancelable&&t.preventDefault(),lr.simulateMouseEvent(t,e)}function d$(t){Tp.touchHandled||(Tp.touchHandled=!0,c$(t,"mousedown"))}function f$(t){Tp.touchHandled&&c$(t,"mousemove")}function h$(t){if(!Tp.touchHandled)return;Tp.pointerLeaveTimeout&&(window.clearTimeout(Tp.pointerLeaveTimeout),delete Tp.pointerLeaveTimeout);const e=!!sn.dragElement;c$(t,"mouseup"),e||c$(t,"click"),Tp.touchHandled=!1}function p$(t){t.pointerType!=="mouse"&&t.target.releasePointerCapture(t.pointerId)}function s1e(t){sn.dragElement&&t.pointerType!=="mouse"&&iHe(t,"mouseenter")}function l1e(t){sn.dragElement&&t.pointerType!=="mouse"&&(Tp.pointerLeaveTimeout=window.setTimeout(()=>{delete Tp.pointerLeaveTimeout,iHe(t,"mouseleave")},10))}class iG{constructor(e,i,n){this.host=e,this.dir=i,this.option=n,this.moving=!1,this._mouseDown=this._mouseDown.bind(this),this._mouseMove=this._mouseMove.bind(this),this._mouseUp=this._mouseUp.bind(this),this._keyEvent=this._keyEvent.bind(this),this._init()}_init(){if(this.option.element)try{this.el=this.option.element instanceof HTMLElement?this.option.element:this.host.querySelector(this.option.element)}catch(e){this.option.element=void 0,console.error("Query for resizeable handle failed, falling back",e)}return this.el||(this.el=document.createElement("div"),this.host.appendChild(this.el)),this.el.classList.add("ui-resizable-handle"),this.el.classList.add(`${iG.prefix}${this.dir}`),this.el.style.zIndex="100",this.el.style.userSelect="none",this.el.addEventListener("mousedown",this._mouseDown),Ov&&(this.el.addEventListener("touchstart",d$),this.el.addEventListener("pointerdown",p$)),this}destroy(){return this.moving&&this._mouseUp(this.mouseDownEvent),this.el.removeEventListener("mousedown",this._mouseDown),Ov&&(this.el.removeEventListener("touchstart",d$),this.el.removeEventListener("pointerdown",p$)),this.option.element||this.host.removeChild(this.el),delete this.el,delete this.host,this}_mouseDown(e){this.mouseDownEvent=e,document.addEventListener("mousemove",this._mouseMove,{capture:!0,passive:!0}),document.addEventListener("mouseup",this._mouseUp,!0),Ov&&(this.el.addEventListener("touchmove",f$),this.el.addEventListener("touchend",h$)),e.stopPropagation(),e.preventDefault()}_mouseMove(e){const i=this.mouseDownEvent;this.moving?this._triggerEvent("move",e):Math.abs(e.x-i.x)+Math.abs(e.y-i.y)>2&&(this.moving=!0,this._triggerEvent("start",this.mouseDownEvent),this._triggerEvent("move",e),document.addEventListener("keydown",this._keyEvent)),e.stopPropagation()}_mouseUp(e){this.moving&&(this._triggerEvent("stop",e),document.removeEventListener("keydown",this._keyEvent)),document.removeEventListener("mousemove",this._mouseMove,!0),document.removeEventListener("mouseup",this._mouseUp,!0),Ov&&(this.el.removeEventListener("touchmove",f$),this.el.removeEventListener("touchend",h$)),delete this.moving,delete this.mouseDownEvent,e.stopPropagation(),e.preventDefault()}_keyEvent(e){var i,n;e.key==="Escape"&&((n=(i=this.host.gridstackNode)==null?void 0:i.grid)==null||n.engine.restoreInitial(),this._mouseUp(this.mouseDownEvent))}_triggerEvent(e,i){return this.option[e]&&this.option[e](i),this}}iG.prefix="ui-resizable-";class hne{constructor(){this._eventRegister={}}get disabled(){return this._disabled}on(e,i){this._eventRegister[e]=i}off(e){delete this._eventRegister[e]}enable(){this._disabled=!1}disable(){this._disabled=!0}destroy(){delete this._eventRegister}triggerEvent(e,i){if(!this.disabled&&this._eventRegister&&this._eventRegister[e])return this._eventRegister[e](i)}}class J3 extends hne{constructor(e,i={}){super(),this.el=e,this.option=i,this.rectScale={x:1,y:1},this._ui=()=>{const r=this.el.parentElement.getBoundingClientRect(),o={width:this.originalRect.width,height:this.originalRect.height+this.scrolled,left:this.originalRect.left,top:this.originalRect.top-this.scrolled},a=this.temporalRect||o;return{position:{left:(a.left-r.left)*this.rectScale.x,top:(a.top-r.top)*this.rectScale.y},size:{width:a.width*this.rectScale.x,height:a.height*this.rectScale.y}}},this._mouseOver=this._mouseOver.bind(this),this._mouseOut=this._mouseOut.bind(this),this.enable(),this._setupAutoHide(this.option.autoHide),this._setupHandlers()}on(e,i){super.on(e,i)}off(e){super.off(e)}enable(){super.enable(),this.el.classList.remove("ui-resizable-disabled"),this._setupAutoHide(this.option.autoHide)}disable(){super.disable(),this.el.classList.add("ui-resizable-disabled"),this._setupAutoHide(!1)}destroy(){this._removeHandlers(),this._setupAutoHide(!1),delete this.el,super.destroy()}updateOption(e){const i=e.handles&&e.handles!==this.option.handles,n=e.autoHide&&e.autoHide!==this.option.autoHide;return Object.keys(e).forEach(r=>this.option[r]=e[r]),i&&(this._removeHandlers(),this._setupHandlers()),n&&this._setupAutoHide(this.option.autoHide),this}_setupAutoHide(e){return e?(this.el.classList.add("ui-resizable-autohide"),this.el.addEventListener("mouseover",this._mouseOver),this.el.addEventListener("mouseout",this._mouseOut)):(this.el.classList.remove("ui-resizable-autohide"),this.el.removeEventListener("mouseover",this._mouseOver),this.el.removeEventListener("mouseout",this._mouseOut),sn.overResizeElement===this&&delete sn.overResizeElement),this}_mouseOver(e){sn.overResizeElement||sn.dragElement||(sn.overResizeElement=this,this.el.classList.remove("ui-resizable-autohide"))}_mouseOut(e){sn.overResizeElement===this&&(delete sn.overResizeElement,this.el.classList.add("ui-resizable-autohide"))}_setupHandlers(){return this.handlers=this.option.handles.split(",").map(e=>e.trim()).map(e=>new iG(this.el,e,{element:this.option.element,start:i=>this._resizeStart(i),stop:i=>this._resizeStop(i),move:i=>this._resizing(i,e)})),this}_resizeStart(e){this.sizeToContent=lr.shouldSizeToContent(this.el.gridstackNode,!0),this.originalRect=this.el.getBoundingClientRect(),this.scrollEl=lr.getScrollElement(this.el),this.scrollY=this.scrollEl.scrollTop,this.scrolled=0,this.startEvent=e,this._setupHelper(),this._applyChange();const i=lr.initEvent(e,{type:"resizestart",target:this.el});return this.option.start&&this.option.start(i,this._ui()),this.el.classList.add("ui-resizable-resizing"),this.triggerEvent("resizestart",i),this}_resizing(e,i){this.scrolled=this.scrollEl.scrollTop-this.scrollY,this.temporalRect=this._getChange(e,i),this._applyChange();const n=lr.initEvent(e,{type:"resize",target:this.el});return this.option.resize&&this.option.resize(n,this._ui()),this.triggerEvent("resize",n),this}_resizeStop(e){const i=lr.initEvent(e,{type:"resizestop",target:this.el});return this._cleanHelper(),this.option.stop&&this.option.stop(i),this.el.classList.remove("ui-resizable-resizing"),this.triggerEvent("resizestop",i),delete this.startEvent,delete this.originalRect,delete this.temporalRect,delete this.scrollY,delete this.scrolled,this}_setupHelper(){this.elOriginStyleVal=J3._originStyleProp.map(n=>this.el.style[n]),this.parentOriginStylePosition=this.el.parentElement.style.position;const e=this.el.parentElement,i=lr.getValuesFromTransformedElement(e);return this.rectScale={x:i.xScale,y:i.yScale},getComputedStyle(this.el.parentElement).position.match(/static/)&&(this.el.parentElement.style.position="relative"),this.el.style.position="absolute",this.el.style.opacity="0.8",this}_cleanHelper(){return J3._originStyleProp.forEach((e,i)=>{this.el.style[e]=this.elOriginStyleVal[i]||null}),this.el.parentElement.style.position=this.parentOriginStylePosition||null,this}_getChange(e,i){const n=this.startEvent,r={width:this.originalRect.width,height:this.originalRect.height+this.scrolled,left:this.originalRect.left,top:this.originalRect.top-this.scrolled},o=e.clientX-n.clientX,a=this.sizeToContent?0:e.clientY-n.clientY;let s,l;i.indexOf("e")>-1?r.width+=o:i.indexOf("w")>-1&&(r.width-=o,r.left+=o,s=!0),i.indexOf("s")>-1?r.height+=a:i.indexOf("n")>-1&&(r.height-=a,r.top+=a,l=!0);const u=this._constrainSize(r.width,r.height,s,l);return Math.round(r.width)!==Math.round(u.width)&&(i.indexOf("w")>-1&&(r.left+=r.width-u.width),r.width=u.width),Math.round(r.height)!==Math.round(u.height)&&(i.indexOf("n")>-1&&(r.top+=r.height-u.height),r.height=u.height),r}_constrainSize(e,i,n,r){const o=this.option,a=(n?o.maxWidthMoveLeft:o.maxWidth)||Number.MAX_SAFE_INTEGER,s=o.minWidth/this.rectScale.x||e,l=(r?o.maxHeightMoveUp:o.maxHeight)||Number.MAX_SAFE_INTEGER,u=o.minHeight/this.rectScale.y||i,c=Math.min(a,Math.max(s,e)),d=Math.min(l,Math.max(u,i));return{width:c,height:d}}_applyChange(){let e={left:0,top:0,width:0,height:0};if(this.el.style.position==="absolute"){const i=this.el.parentElement,{left:n,top:r}=i.getBoundingClientRect();e={left:n,top:r,width:0,height:0}}return this.temporalRect?(Object.keys(this.temporalRect).forEach(i=>{const n=this.temporalRect[i],r=i==="width"||i==="left"?this.rectScale.x:i==="height"||i==="top"?this.rectScale.y:1;this.el.style[i]=(n-e[i])*r+"px"}),this):this}_removeHandlers(){return this.handlers.forEach(e=>e.destroy()),delete this.handlers,this}}J3._originStyleProp=["width","height","position","left","top","opacity","zIndex"];const VDt='input,textarea,button,select,option,[contenteditable="true"],.ui-resizable-handle';class Q3 extends hne{constructor(e,i={}){var o;super(),this.el=e,this.option=i,this.dragTransform={xScale:1,yScale:1,xOffset:0,yOffset:0};const n=(o=i==null?void 0:i.handle)==null?void 0:o.substring(1),r=e.gridstackNode;this.dragEls=!n||e.classList.contains(n)?[e]:r!=null&&r.subGrid?[e.querySelector(i.handle)||e]:Array.from(e.querySelectorAll(i.handle)),this.dragEls.length===0&&(this.dragEls=[e]),this._mouseDown=this._mouseDown.bind(this),this._mouseMove=this._mouseMove.bind(this),this._mouseUp=this._mouseUp.bind(this),this._keyEvent=this._keyEvent.bind(this),this.enable()}on(e,i){super.on(e,i)}off(e){super.off(e)}enable(){this.disabled!==!1&&(super.enable(),this.dragEls.forEach(e=>{e.addEventListener("mousedown",this._mouseDown),Ov&&(e.addEventListener("touchstart",d$),e.addEventListener("pointerdown",p$))}),this.el.classList.remove("ui-draggable-disabled"))}disable(e=!1){this.disabled!==!0&&(super.disable(),this.dragEls.forEach(i=>{i.removeEventListener("mousedown",this._mouseDown),Ov&&(i.removeEventListener("touchstart",d$),i.removeEventListener("pointerdown",p$))}),e||this.el.classList.add("ui-draggable-disabled"))}destroy(){this.dragTimeout&&window.clearTimeout(this.dragTimeout),delete this.dragTimeout,this.mouseDownEvent&&this._mouseUp(this.mouseDownEvent),this.disable(!0),delete this.el,delete this.helper,delete this.option,super.destroy()}updateOption(e){return Object.keys(e).forEach(i=>this.option[i]=e[i]),this}_mouseDown(e){if(Tp.touchHandled&&e.isTrusted&&(Tp.touchHandled=!1),!sn.mouseHandled)return e.button!==0||!this.dragEls.find(i=>i===e.target)&&e.target.closest(VDt)||this.option.cancel&&e.target.closest(this.option.cancel)||(this.mouseDownEvent=e,delete this.dragging,delete sn.dragElement,delete sn.dropElement,document.addEventListener("mousemove",this._mouseMove,{capture:!0,passive:!0}),document.addEventListener("mouseup",this._mouseUp,!0),Ov&&(e.currentTarget.addEventListener("touchmove",f$),e.currentTarget.addEventListener("touchend",h$)),e.preventDefault(),document.activeElement&&document.activeElement.blur(),sn.mouseHandled=!0),!0}_callDrag(e){if(!this.dragging)return;const i=lr.initEvent(e,{target:this.el,type:"drag"});this.option.drag&&this.option.drag(i,this.ui()),this.triggerEvent("drag",i)}_mouseMove(e){var n;const i=this.mouseDownEvent;if(this.lastDrag=e,this.dragging)if(this._dragFollow(e),sn.pauseDrag){const r=Number.isInteger(sn.pauseDrag)?sn.pauseDrag:100;this.dragTimeout&&window.clearTimeout(this.dragTimeout),this.dragTimeout=window.setTimeout(()=>this._callDrag(e),r)}else this._callDrag(e);else if(Math.abs(e.x-i.x)+Math.abs(e.y-i.y)>3){this.dragging=!0,sn.dragElement=this;const r=(n=this.el.gridstackNode)==null?void 0:n.grid;r?sn.dropElement=r.el.ddElement.ddDroppable:delete sn.dropElement,this.helper=this._createHelper(),this._setupHelperContainmentStyle(),this.dragTransform=lr.getValuesFromTransformedElement(this.helperContainment),this.dragOffset=this._getDragOffset(e,this.el,this.helperContainment),this._setupHelperStyle(e);const o=lr.initEvent(e,{target:this.el,type:"dragstart"});this.option.start&&this.option.start(o,this.ui()),this.triggerEvent("dragstart",o),document.addEventListener("keydown",this._keyEvent)}return!0}_mouseUp(e){var i,n;if(document.removeEventListener("mousemove",this._mouseMove,!0),document.removeEventListener("mouseup",this._mouseUp,!0),Ov&&e.currentTarget&&(e.currentTarget.removeEventListener("touchmove",f$,!0),e.currentTarget.removeEventListener("touchend",h$,!0)),this.dragging){delete this.dragging,(i=this.el.gridstackNode)==null||delete i._origRotate,document.removeEventListener("keydown",this._keyEvent),((n=sn.dropElement)==null?void 0:n.el)===this.el.parentElement&&delete sn.dropElement,this.helperContainment.style.position=this.parentOriginStylePosition||null,this.helper!==this.el&&this.helper.remove(),this._removeHelperStyle();const r=lr.initEvent(e,{target:this.el,type:"dragstop"});this.option.stop&&this.option.stop(r),this.triggerEvent("dragstop",r),sn.dropElement&&sn.dropElement.drop(e)}delete this.helper,delete this.mouseDownEvent,delete sn.dragElement,delete sn.dropElement,delete sn.mouseHandled,e.preventDefault()}_keyEvent(e){var r,o;const i=this.el.gridstackNode,n=(i==null?void 0:i.grid)||((o=(r=sn.dropElement)==null?void 0:r.el)==null?void 0:o.gridstack);if(e.key==="Escape")i&&i._origRotate&&(i._orig=i._origRotate,delete i._origRotate),n==null||n.cancelDrag(),this._mouseUp(this.mouseDownEvent);else if(i&&n&&(e.key==="r"||e.key==="R")){if(!lr.canBeRotated(i))return;i._origRotate=i._origRotate||{...i._orig},delete i._moving,n.setAnimation(!1).rotate(i.el,{top:-this.dragOffset.offsetTop,left:-this.dragOffset.offsetLeft}).setAnimation(),i._moving=!0,this.dragOffset=this._getDragOffset(this.lastDrag,i.el,this.helperContainment),this.helper.style.width=this.dragOffset.width+"px",this.helper.style.height=this.dragOffset.height+"px",lr.swap(i._orig,"w","h"),delete i._rect,this._mouseMove(this.lastDrag)}}_createHelper(){let e=this.el;return typeof this.option.helper=="function"?e=this.option.helper(this.el):this.option.helper==="clone"&&(e=lr.cloneNode(this.el)),e.parentElement||lr.appendTo(e,this.option.appendTo==="parent"?this.el.parentElement:this.option.appendTo),this.dragElementOriginStyle=Q3.originStyleProp.map(i=>this.el.style[i]),e}_setupHelperStyle(e){var n,r;this.helper.classList.add("ui-draggable-dragging"),(r=(n=this.el.gridstackNode)==null?void 0:n.grid)==null||r.el.classList.add("grid-stack-dragging");const i=this.helper.style;return i.pointerEvents="none",i.width=this.dragOffset.width+"px",i.height=this.dragOffset.height+"px",i.willChange="left, top",i.position="fixed",this._dragFollow(e),i.transition="none",setTimeout(()=>{this.helper&&(i.transition=null)},0),this}_removeHelperStyle(){var i,n,r;this.helper.classList.remove("ui-draggable-dragging"),(n=(i=this.el.gridstackNode)==null?void 0:i.grid)==null||n.el.classList.remove("grid-stack-dragging");const e=(r=this.helper)==null?void 0:r.gridstackNode;if(!(e!=null&&e._isAboutToRemove)&&this.dragElementOriginStyle){const o=this.helper,a=this.dragElementOriginStyle.transition||null;o.style.transition=this.dragElementOriginStyle.transition="none",Q3.originStyleProp.forEach(s=>o.style[s]=this.dragElementOriginStyle[s]||null),setTimeout(()=>o.style.transition=a,50)}return delete this.dragElementOriginStyle,this}_dragFollow(e){const i={left:0,top:0},n=this.helper.style,r=this.dragOffset;n.left=(e.clientX+r.offsetLeft-i.left)*this.dragTransform.xScale+"px",n.top=(e.clientY+r.offsetTop-i.top)*this.dragTransform.yScale+"px"}_setupHelperContainmentStyle(){return this.helperContainment=this.helper.parentElement,this.helper.style.position!=="fixed"&&(this.parentOriginStylePosition=this.helperContainment.style.position,getComputedStyle(this.helperContainment).position.match(/static/)&&(this.helperContainment.style.position="relative")),this}_getDragOffset(e,i,n){let r=0,o=0;n&&(r=this.dragTransform.xOffset,o=this.dragTransform.yOffset);const a=i.getBoundingClientRect();return{left:a.left,top:a.top,offsetLeft:-e.clientX+a.left-r,offsetTop:-e.clientY+a.top-o,width:a.width*this.dragTransform.xScale,height:a.height*this.dragTransform.yScale}}ui(){const i=this.el.parentElement.getBoundingClientRect(),n=this.helper.getBoundingClientRect();return{position:{top:(n.top-i.top)*this.dragTransform.yScale,left:(n.left-i.left)*this.dragTransform.xScale}}}}Q3.originStyleProp=["width","height","transform","transform-origin","transition","pointerEvents","position","left","top","minWidth","willChange"];class HDt extends hne{constructor(e,i={}){super(),this.el=e,this.option=i,this._mouseEnter=this._mouseEnter.bind(this),this._mouseLeave=this._mouseLeave.bind(this),this.enable(),this._setupAccept()}on(e,i){super.on(e,i)}off(e){super.off(e)}enable(){this.disabled!==!1&&(super.enable(),this.el.classList.add("ui-droppable"),this.el.classList.remove("ui-droppable-disabled"),this.el.addEventListener("mouseenter",this._mouseEnter),this.el.addEventListener("mouseleave",this._mouseLeave),Ov&&(this.el.addEventListener("pointerenter",s1e),this.el.addEventListener("pointerleave",l1e)))}disable(e=!1){this.disabled!==!0&&(super.disable(),this.el.classList.remove("ui-droppable"),e||this.el.classList.add("ui-droppable-disabled"),this.el.removeEventListener("mouseenter",this._mouseEnter),this.el.removeEventListener("mouseleave",this._mouseLeave),Ov&&(this.el.removeEventListener("pointerenter",s1e),this.el.removeEventListener("pointerleave",l1e)))}destroy(){this.disable(!0),this.el.classList.remove("ui-droppable"),this.el.classList.remove("ui-droppable-disabled"),super.destroy()}updateOption(e){return Object.keys(e).forEach(i=>this.option[i]=e[i]),this._setupAccept(),this}_mouseEnter(e){if(!sn.dragElement||Tp.touchHandled&&e.isTrusted||!this._canDrop(sn.dragElement.el))return;e.preventDefault(),e.stopPropagation(),sn.dropElement&&sn.dropElement!==this&&sn.dropElement._mouseLeave(e,!0),sn.dropElement=this;const i=lr.initEvent(e,{target:this.el,type:"dropover"});this.option.over&&this.option.over(i,this._ui(sn.dragElement)),this.triggerEvent("dropover",i),this.el.classList.add("ui-droppable-over")}_mouseLeave(e,i=!1){var r;if(!sn.dragElement||sn.dropElement!==this)return;e.preventDefault(),e.stopPropagation();const n=lr.initEvent(e,{target:this.el,type:"dropout"});if(this.option.out&&this.option.out(n,this._ui(sn.dragElement)),this.triggerEvent("dropout",n),sn.dropElement===this&&(delete sn.dropElement,!i)){let o,a=this.el.parentElement;for(;!o&&a;)o=(r=a.ddElement)==null?void 0:r.ddDroppable,a=a.parentElement;o&&o._mouseEnter(e)}}drop(e){e.preventDefault();const i=lr.initEvent(e,{target:this.el,type:"drop"});this.option.drop&&this.option.drop(i,this._ui(sn.dragElement)),this.triggerEvent("drop",i)}_canDrop(e){return e&&(!this.accept||this.accept(e))}_setupAccept(){return this.option.accept?(typeof this.option.accept=="string"?this.accept=e=>e.classList.contains(this.option.accept)||e.matches(this.option.accept):this.accept=this.option.accept,this):this}_ui(e){return{draggable:e.el,...e.ui()}}}class pne{static init(e){return e.ddElement||(e.ddElement=new pne(e)),e.ddElement}constructor(e){this.el=e}on(e,i){return this.ddDraggable&&["drag","dragstart","dragstop"].indexOf(e)>-1?this.ddDraggable.on(e,i):this.ddDroppable&&["drop","dropover","dropout"].indexOf(e)>-1?this.ddDroppable.on(e,i):this.ddResizable&&["resizestart","resize","resizestop"].indexOf(e)>-1&&this.ddResizable.on(e,i),this}off(e){return this.ddDraggable&&["drag","dragstart","dragstop"].indexOf(e)>-1?this.ddDraggable.off(e):this.ddDroppable&&["drop","dropover","dropout"].indexOf(e)>-1?this.ddDroppable.off(e):this.ddResizable&&["resizestart","resize","resizestop"].indexOf(e)>-1&&this.ddResizable.off(e),this}setupDraggable(e){return this.ddDraggable?this.ddDraggable.updateOption(e):this.ddDraggable=new Q3(this.el,e),this}cleanDraggable(){return this.ddDraggable&&(this.ddDraggable.destroy(),delete this.ddDraggable),this}setupResizable(e){return this.ddResizable?this.ddResizable.updateOption(e):this.ddResizable=new J3(this.el,e),this}cleanResizable(){return this.ddResizable&&(this.ddResizable.destroy(),delete this.ddResizable),this}setupDroppable(e){return this.ddDroppable?this.ddDroppable.updateOption(e):this.ddDroppable=new HDt(this.el,e),this}cleanDroppable(){return this.ddDroppable&&(this.ddDroppable.destroy(),delete this.ddDroppable),this}}class UDt{resizable(e,i,n,r){return this._getDDElements(e,i).forEach(o=>{if(i==="disable"||i==="enable")o.ddResizable&&o.ddResizable[i]();else if(i==="destroy")o.ddResizable&&o.cleanResizable();else if(i==="option")o.setupResizable({[n]:r});else{const s=o.el.gridstackNode.grid;let l=o.el.getAttribute("gs-resize-handles")||s.opts.resizable.handles||"e,s,se";l==="all"&&(l="n,e,s,w,se,sw,ne,nw");const u=!s.opts.alwaysShowResizeHandle;o.setupResizable({...s.opts.resizable,handles:l,autoHide:u,start:i.start,stop:i.stop,resize:i.resize})}}),this}draggable(e,i,n,r){return this._getDDElements(e,i).forEach(o=>{if(i==="disable"||i==="enable")o.ddDraggable&&o.ddDraggable[i]();else if(i==="destroy")o.ddDraggable&&o.cleanDraggable();else if(i==="option")o.setupDraggable({[n]:r});else{const a=o.el.gridstackNode.grid;o.setupDraggable({...a.opts.draggable,start:i.start,stop:i.stop,drag:i.drag})}}),this}dragIn(e,i){return this._getDDElements(e).forEach(n=>n.setupDraggable(i)),this}droppable(e,i,n,r){return typeof i.accept=="function"&&!i._accept&&(i._accept=i.accept,i.accept=o=>i._accept(o)),this._getDDElements(e,i).forEach(o=>{i==="disable"||i==="enable"?o.ddDroppable&&o.ddDroppable[i]():i==="destroy"?o.ddDroppable&&o.cleanDroppable():i==="option"?o.setupDroppable({[n]:r}):o.setupDroppable(i)}),this}isDroppable(e){var i;return!!((i=e==null?void 0:e.ddElement)!=null&&i.ddDroppable&&!e.ddElement.ddDroppable.disabled)}isDraggable(e){var i;return!!((i=e==null?void 0:e.ddElement)!=null&&i.ddDraggable&&!e.ddElement.ddDraggable.disabled)}isResizable(e){var i;return!!((i=e==null?void 0:e.ddElement)!=null&&i.ddResizable&&!e.ddElement.ddResizable.disabled)}on(e,i,n){return this._getDDElements(e).forEach(r=>r.on(i,o=>{n(o,sn.dragElement?sn.dragElement.el:o.target,sn.dragElement?sn.dragElement.helper:null)})),this}off(e,i){return this._getDDElements(e).forEach(n=>n.off(i)),this}_getDDElements(e,i){const n=e.gridstack||i!=="destroy"&&i!=="disable",r=lr.getElements(e);return r.length?r.map(a=>a.ddElement||(n?pne.init(a):null)).filter(a=>a):[]}}/*!
 * GridStack 12.4.2
 * https://gridstackjs.com/
 *
 * Copyright (c) 2021-2025  Alain Dumesny
 * see root license https://github.com/gridstack/gridstack.js/tree/master/LICENSE
 */const Pf=new UDt;class Li{static init(e={},i=".grid-stack"){if(typeof document>"u")return null;const n=Li.getGridElement(i);return n?(n.gridstack||(n.gridstack=new Li(n,lr.cloneDeep(e))),n.gridstack):(console.error(typeof i=="string"?'GridStack.initAll() no grid was found with selector "'+i+`" - element missing or wrong selector ?
Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the default selector.`:"GridStack.init() no grid element was passed."),null)}static initAll(e={},i=".grid-stack"){const n=[];return typeof document>"u"||(Li.getGridElements(i).forEach(r=>{r.gridstack||(r.gridstack=new Li(r,lr.cloneDeep(e))),n.push(r.gridstack)}),n.length===0&&console.error('GridStack.initAll() no grid was found with selector "'+i+`" - element missing or wrong selector ?
Note: ".grid-stack" is required for proper CSS styling and drag/drop, and is the default selector.`)),n}static addGrid(e,i={}){if(!e)return null;let n=e;if(n.gridstack){const a=n.gridstack;return i&&(a.opts={...a.opts,...i}),i.children!==void 0&&a.load(i.children),a}return(!e.classList.contains("grid-stack")||Li.addRemoveCB)&&(Li.addRemoveCB?n=Li.addRemoveCB(e,i,!0,!0):n=lr.createDiv(["grid-stack",i.class],e)),Li.init(i,n)}static registerEngine(e){Li.engineClass=e}get placeholder(){if(!this._placeholder){this._placeholder=lr.createDiv([this.opts.placeholderClass,gp.itemClass,this.opts.itemClass]);const e=lr.createDiv(["placeholder-content"],this._placeholder);this.opts.placeholderText&&(e.textContent=this.opts.placeholderText)}return this._placeholder}constructor(e,i={}){var u;this.el=e,this.opts=i,this.animationDelay=310,this._gsEventHandler={},this._extraDragRow=0,this.dragTransform={xScale:1,yScale:1,xOffset:0,yOffset:0},e.gridstack=this,this.opts=i=i||{},e.classList.contains("grid-stack")||this.el.classList.add("grid-stack"),i.row&&(i.minRow=i.maxRow=i.row,delete i.row);const n=lr.toNumber(e.getAttribute("gs-row"));i.column==="auto"&&delete i.column,i.alwaysShowResizeHandle!==void 0&&(i._alwaysShowResizeHandle=i.alwaysShowResizeHandle);const r=i.columnOpts;if(r){const c=r.breakpoints;!r.columnWidth&&!(c!=null&&c.length)?delete i.columnOpts:(r.columnMax=r.columnMax||12,(c==null?void 0:c.length)>1&&c.sort((d,f)=>(f.w||0)-(d.w||0)))}const o={...lr.cloneDeep(gp),column:lr.toNumber(e.getAttribute("gs-column"))||gp.column,minRow:n||lr.toNumber(e.getAttribute("gs-min-row"))||gp.minRow,maxRow:n||lr.toNumber(e.getAttribute("gs-max-row"))||gp.maxRow,staticGrid:lr.toBool(e.getAttribute("gs-static"))||gp.staticGrid,sizeToContent:lr.toBool(e.getAttribute("gs-size-to-content"))||void 0,draggable:{handle:(i.handleClass?"."+i.handleClass:i.handle?i.handle:"")||gp.draggable.handle},removableOptions:{accept:i.itemClass||gp.removableOptions.accept,decline:gp.removableOptions.decline}};e.getAttribute("gs-animate")&&(o.animate=lr.toBool(e.getAttribute("gs-animate"))),i=lr.defaults(i,o),this._initMargin(),this.checkDynamicColumn(),this._updateColumnVar(i),i.rtl==="auto"&&(i.rtl=e.style.direction==="rtl"),i.rtl&&this.el.classList.add("grid-stack-rtl");const a=this.el.closest("."+gp.itemClass),s=a==null?void 0:a.gridstackNode;if(s&&(s.subGrid=this,this.parentGridNode=s,this.el.classList.add("grid-stack-nested"),s.el.classList.add("grid-stack-sub-grid")),this._isAutoCellHeight=i.cellHeight==="auto",this._isAutoCellHeight||i.cellHeight==="initial")this.cellHeight(void 0);else{typeof i.cellHeight=="number"&&i.cellHeightUnit&&i.cellHeightUnit!==gp.cellHeightUnit&&(i.cellHeight=i.cellHeight+i.cellHeightUnit,delete i.cellHeightUnit);const c=i.cellHeight;delete i.cellHeight,this.cellHeight(c)}i.alwaysShowResizeHandle==="mobile"&&(i.alwaysShowResizeHandle=Ov),this._setStaticClass();const l=i.engineClass||Li.engineClass||uS;if(this.engine=new l({column:this.getColumn(),float:i.float,maxRow:i.maxRow,onChange:c=>{c.forEach(d=>{const f=d.el;f&&(d._removeDOM?(f&&f.remove(),delete d._removeDOM):this._writePosAttr(f,d))}),this._updateContainerHeight()}}),i.auto&&(this.batchUpdate(),this.engine._loading=!0,this.getGridItems().forEach(c=>this._prepareElement(c)),delete this.engine._loading,this.batchUpdate(!1)),i.children){const c=i.children;delete i.children,c.length&&this.load(c)}this.setAnimation(),i.subGridDynamic&&!sn.pauseDrag&&(sn.pauseDrag=!0),((u=i.draggable)==null?void 0:u.pause)!==void 0&&(sn.pauseDrag=i.draggable.pause),this._setupRemoveDrop(),this._setupAcceptWidget(),this._updateResizeEvent()}_updateColumnVar(e=this.opts){this.el.classList.add("gs-"+e.column),typeof e.column=="number"&&this.el.style.setProperty("--gs-column-width",`${100/e.column}%`)}addWidget(e){if(!e)return;if(typeof e=="string"){console.error("V11: GridStack.addWidget() does not support string anymore. see #2736");return}if(e.ELEMENT_NODE)return console.error("V11: GridStack.addWidget() does not support HTMLElement anymore. use makeWidget()"),this.makeWidget(e);let i,n=e;if(n.grid=this,n.el?i=n.el:Li.addRemoveCB?i=Li.addRemoveCB(this.el,e,!0,!1):i=this.createWidgetDivs(n),!i)return;if(n=i.gridstackNode,n&&i.parentElement===this.el&&this.engine.nodes.find(o=>o._id===n._id))return i;const r=this._readAttr(i);return lr.defaults(e,r),this.engine.prepareNode(e),this.el.appendChild(i),this.makeWidget(i,e),i}createWidgetDivs(e){const i=lr.createDiv(["grid-stack-item",this.opts.itemClass]),n=lr.createDiv(["grid-stack-item-content"],i);return lr.lazyLoad(e)?e.visibleObservable||(e.visibleObservable=new IntersectionObserver(([r])=>{var o,a;r.isIntersecting&&((o=e.visibleObservable)==null||o.disconnect(),delete e.visibleObservable,Li.renderCB(n,e),(a=e.grid)==null||a.prepareDragDrop(e.el))}),window.setTimeout(()=>{var r;return(r=e.visibleObservable)==null?void 0:r.observe(i)})):Li.renderCB(n,e),i}makeSubGrid(e,i,n,r=!0){var h,p,g;let o=e.gridstackNode;if(o||(o=this.makeWidget(e).gridstackNode),(h=o.subGrid)!=null&&h.el)return o.subGrid;let a,s=this;for(;s&&!a;)a=(p=s.opts)==null?void 0:p.subGridOpts,s=(g=s.parentGridNode)==null?void 0:g.grid;i=lr.cloneDeep({...this.opts,id:void 0,children:void 0,column:"auto",columnOpts:void 0,layout:"list",subGridOpts:void 0,...a||{},...i||o.subGridOpts||{}}),o.subGridOpts=i;let l;i.column==="auto"&&(l=!0,i.column=Math.max(o.w||1,(n==null?void 0:n.w)||1),delete i.columnOpts);let u=o.el.querySelector(".grid-stack-item-content"),c,d;if(r&&(this._removeDD(o.el),d={...o,x:0,y:0},lr.removeInternalForSave(d),delete d.subGridOpts,o.content&&(d.content=o.content,delete o.content),Li.addRemoveCB?c=Li.addRemoveCB(this.el,d,!0,!1):(c=lr.createDiv(["grid-stack-item"]),c.appendChild(u),u=lr.createDiv(["grid-stack-item-content"],o.el)),this.prepareDragDrop(o.el)),n){const v=l?i.column:o.w,y=o.h+n.h,m=o.el.style;m.transition="none",this.update(o.el,{w:v,h:y}),setTimeout(()=>m.transition=null)}const f=o.subGrid=Li.addGrid(u,i);return n!=null&&n._moving&&(f._isTemp=!0),l&&(f._autoColumn=!0),r&&f.makeWidget(c,d),n&&(n._moving?window.setTimeout(()=>lr.simulateMouseEvent(n._event,"mouseenter",f.el),0):f.makeWidget(o.el,o)),this.resizeToContentCheck(!1,o),f}removeAsSubGrid(e){var n;const i=(n=this.parentGridNode)==null?void 0:n.grid;i&&(i.batchUpdate(),i.removeWidget(this.parentGridNode.el,!0,!0),this.engine.nodes.forEach(r=>{r.x+=this.parentGridNode.x,r.y+=this.parentGridNode.y,i.makeWidget(r.el,r)}),i.batchUpdate(!1),this.parentGridNode&&delete this.parentGridNode.subGrid,delete this.parentGridNode,e&&window.setTimeout(()=>lr.simulateMouseEvent(e._event,"mouseenter",i.el),0))}save(e=!0,i=!1,n=Li.saveCB,r){const o=this.engine.save(e,n,r);if(o.forEach(a=>{var s;if(e&&a.el&&!a.subGrid&&!n){const l=a.el.querySelector(".grid-stack-item-content");a.content=l==null?void 0:l.innerHTML,a.content||delete a.content}else if(!e&&!n&&delete a.content,(s=a.subGrid)!=null&&s.el){const l=a.w||a.subGrid.getColumn(),u=a.subGrid.save(e,i,n,l);a.subGridOpts=i?u:{children:u},delete a.subGrid}delete a.el}),i){const a=lr.cloneDeep(this.opts);a.marginBottom===a.marginTop&&a.marginRight===a.marginLeft&&a.marginTop===a.marginRight&&(a.margin=a.marginTop,delete a.marginTop,delete a.marginRight,delete a.marginBottom,delete a.marginLeft),a.rtl===(this.el.style.direction==="rtl")&&(a.rtl="auto"),this._isAutoCellHeight&&(a.cellHeight="auto"),this._autoColumn&&(a.column="auto");const s=a._alwaysShowResizeHandle;return delete a._alwaysShowResizeHandle,s!==void 0?a.alwaysShowResizeHandle=s:delete a.alwaysShowResizeHandle,lr.removeInternalAndSame(a,gp),a.children=o,a}return o}load(e,i=Li.addRemoveCB||!0){e=lr.cloneDeep(e);const n=this.getColumn();e.forEach(c=>{c.w=c.w||c.minW||1,c.h=c.h||c.minH||1}),e=lr.sort(e),this.engine.skipCacheUpdate=this._ignoreLayoutsNodeChange=!0;let r=0;e.forEach(c=>{r=Math.max(r,(c.x||0)+c.w)}),r>this.engine.defaultColumn&&(this.engine.defaultColumn=r),r>n&&(this.engine.nodes.length===0&&this.responseLayout?(this.engine.nodes=e,this.engine.columnChanged(r,n,this.responseLayout),e=this.engine.nodes,this.engine.nodes=[],delete this.responseLayout):this.engine.cacheLayout(e,r,!0));const o=Li.addRemoveCB;typeof i=="function"&&(Li.addRemoveCB=i);const a=[];this.batchUpdate();const s=!this.engine.nodes.length,l=s&&this.opts.animate;l&&this.setAnimation(!1),!s&&i&&[...this.engine.nodes].forEach(d=>{if(!d.id)return;lr.find(e,d.id)||(Li.addRemoveCB&&Li.addRemoveCB(this.el,d,!1,!1),a.push(d),this.removeWidget(d.el,!0,!1))}),this.engine._loading=!0;const u=[];return this.engine.nodes=this.engine.nodes.filter(c=>lr.find(e,c.id)?(u.push(c),!1):!0),e.forEach(c=>{var f;const d=lr.find(u,c.id);if(d){if(lr.shouldSizeToContent(d)&&(c.h=d.h),this.engine.nodeBoundFix(c),(c.autoPosition||c.x===void 0||c.y===void 0)&&(c.w=c.w||d.w,c.h=c.h||d.h,this.engine.findEmptyPosition(c)),this.engine.nodes.push(d),lr.samePos(d,c)&&this.engine.nodes.length>1&&(this.moveNode(d,{...c,forceCollide:!0}),lr.copyPos(c,d)),this.update(d.el,c),(f=c.subGridOpts)!=null&&f.children){const h=d.el.querySelector(".grid-stack");h&&h.gridstack&&h.gridstack.load(c.subGridOpts.children)}}else i&&this.addWidget(c)}),delete this.engine._loading,this.engine.removedNodes=a,this.batchUpdate(!1),delete this._ignoreLayoutsNodeChange,delete this.engine.skipCacheUpdate,o?Li.addRemoveCB=o:delete Li.addRemoveCB,l&&this.setAnimation(!0,!0),this}batchUpdate(e=!0){return this.engine.batchUpdate(e),e||(this._updateContainerHeight(),this._triggerRemoveEvent(),this._triggerAddEvent(),this._triggerChangeEvent()),this}getCellHeight(e=!1){if(this.opts.cellHeight&&this.opts.cellHeight!=="auto"&&(!e||!this.opts.cellHeightUnit||this.opts.cellHeightUnit==="px"))return this.opts.cellHeight;if(this.opts.cellHeightUnit==="rem")return this.opts.cellHeight*parseFloat(getComputedStyle(document.documentElement).fontSize);if(this.opts.cellHeightUnit==="em")return this.opts.cellHeight*parseFloat(getComputedStyle(this.el).fontSize);if(this.opts.cellHeightUnit==="cm")return this.opts.cellHeight*(96/2.54);if(this.opts.cellHeightUnit==="mm")return this.opts.cellHeight*(96/2.54)/10;const i=this.el.querySelector("."+this.opts.itemClass);if(i){const r=lr.toNumber(i.getAttribute("gs-h"))||1;return Math.round(i.offsetHeight/r)}const n=parseInt(this.el.getAttribute("gs-current-row"));return n?Math.round(this.el.getBoundingClientRect().height/n):this.opts.cellHeight}cellHeight(e){if(e!==void 0&&this._isAutoCellHeight!==(e==="auto")&&(this._isAutoCellHeight=e==="auto",this._updateResizeEvent()),(e==="initial"||e==="auto")&&(e=void 0),e===void 0){const n=-this.opts.marginRight-this.opts.marginLeft+this.opts.marginTop+this.opts.marginBottom;e=this.cellWidth()+n}const i=lr.parseHeight(e);return this.opts.cellHeightUnit===i.unit&&this.opts.cellHeight===i.h?this:(this.opts.cellHeightUnit=i.unit,this.opts.cellHeight=i.h,this.el.style.setProperty("--gs-cell-height",`${this.opts.cellHeight}${this.opts.cellHeightUnit}`),this._updateContainerHeight(),this.resizeToContentCheck(),this)}cellWidth(){return this._widthOrContainer()/this.getColumn()}_widthOrContainer(e=!1){var i;return e&&((i=this.opts.columnOpts)!=null&&i.breakpointForWindow)?window.innerWidth:this.el.clientWidth||this.el.parentElement.clientWidth||window.innerWidth}checkDynamicColumn(){var o,a;const e=this.opts.columnOpts;if(!e||!e.columnWidth&&!((o=e.breakpoints)!=null&&o.length))return!1;const i=this.getColumn();let n=i;const r=this._widthOrContainer(!0);if(e.columnWidth)n=Math.min(Math.round(r/e.columnWidth)||1,e.columnMax);else{n=e.columnMax;let s=0;for(;s<e.breakpoints.length&&r<=e.breakpoints[s].w;)n=e.breakpoints[s++].c||i}if(n!==i){const s=(a=e.breakpoints)==null?void 0:a.find(l=>l.c===n);return this.column(n,(s==null?void 0:s.layout)||e.layout),!0}return!1}compact(e="compact",i=!0){return this.engine.compact(e,i),this._triggerChangeEvent(),this}column(e,i="moveScale"){if(!e||e<1||this.opts.column===e)return this;const n=this.getColumn();return this.opts.column=e,this.engine?(this.engine.column=e,this.el.classList.remove("gs-"+n),this._updateColumnVar(),this.engine.columnChanged(n,e,i),this._isAutoCellHeight&&this.cellHeight(),this.resizeToContentCheck(!0),this._ignoreLayoutsNodeChange=!0,this._triggerChangeEvent(),delete this._ignoreLayoutsNodeChange,this):(this.responseLayout=i,this)}getColumn(){return this.opts.column}getGridItems(){return Array.from(this.el.children).filter(e=>e.matches("."+this.opts.itemClass)&&!e.matches("."+this.opts.placeholderClass))}isIgnoreChangeCB(){return this._ignoreLayoutsNodeChange}destroy(e=!0){var i;if(this.el)return this.offAll(),this._updateResizeEvent(!0),this.setStatic(!0,!1),this.setAnimation(!1),e?this.el.parentNode.removeChild(this.el):(this.removeAll(e),this.el.removeAttribute("gs-current-row")),this.parentGridNode&&delete this.parentGridNode.subGrid,delete this.parentGridNode,delete this.opts,(i=this._placeholder)==null||delete i.gridstackNode,delete this._placeholder,delete this.engine,delete this.el.gridstack,delete this.el,this}float(e){return this.opts.float!==e&&(this.opts.float=this.engine.float=e,this._triggerChangeEvent()),this}getFloat(){return this.engine.float}getCellFromPixel(e,i=!1){const n=this.el.getBoundingClientRect();let r;i?r={top:n.top+document.documentElement.scrollTop,left:n.left}:r={top:this.el.offsetTop,left:this.el.offsetLeft};const o=e.left-r.left,a=e.top-r.top,s=n.width/this.getColumn(),l=n.height/parseInt(this.el.getAttribute("gs-current-row"));return{x:Math.floor(o/s),y:Math.floor(a/l)}}getRow(){return Math.max(this.engine.getRow(),this.opts.minRow||0)}isAreaEmpty(e,i,n,r){return this.engine.isAreaEmpty(e,i,n,r)}makeWidget(e,i){const n=Li.getElement(e);if(!n||n.gridstackNode)return n;n.parentElement||this.el.appendChild(n),this._prepareElement(n,!0,i);const r=n.gridstackNode;this._updateContainerHeight(),r.subGridOpts&&this.makeSubGrid(n,r.subGridOpts,void 0,!1);let o;return this.opts.column===1&&!this._ignoreLayoutsNodeChange&&(o=this._ignoreLayoutsNodeChange=!0),this._triggerAddEvent(),this._triggerChangeEvent(),o&&delete this._ignoreLayoutsNodeChange,n}on(e,i){return e.indexOf(" ")!==-1?(e.split(" ").forEach(r=>this.on(r,i)),this):(e==="change"||e==="added"||e==="removed"||e==="enable"||e==="disable"?(e==="enable"||e==="disable"?this._gsEventHandler[e]=r=>i(r):this._gsEventHandler[e]=r=>{r.detail&&i(r,r.detail)},this.el.addEventListener(e,this._gsEventHandler[e])):e==="drag"||e==="dragstart"||e==="dragstop"||e==="resizestart"||e==="resize"||e==="resizestop"||e==="dropped"||e==="resizecontent"?this._gsEventHandler[e]=i:console.error("GridStack.on("+e+") event not supported"),this)}off(e){return e.indexOf(" ")!==-1?(e.split(" ").forEach(n=>this.off(n)),this):((e==="change"||e==="added"||e==="removed"||e==="enable"||e==="disable")&&this._gsEventHandler[e]&&this.el.removeEventListener(e,this._gsEventHandler[e]),delete this._gsEventHandler[e],this)}offAll(){return Object.keys(this._gsEventHandler).forEach(e=>this.off(e)),this}removeWidget(e,i=!0,n=!0){return e?(Li.getElements(e).forEach(r=>{if(r.parentElement&&r.parentElement!==this.el)return;let o=r.gridstackNode;o||(o=this.engine.nodes.find(a=>r===a.el)),o&&(i&&Li.addRemoveCB&&Li.addRemoveCB(this.el,o,!1,!1),delete r.gridstackNode,this._removeDD(r),this.engine.removeNode(o,i,n),i&&r.parentElement&&r.remove())}),n&&(this._triggerRemoveEvent(),this._triggerChangeEvent()),this):(console.error("Error: GridStack.removeWidget(undefined) called"),this)}removeAll(e=!0,i=!0){return this.engine.nodes.forEach(n=>{e&&Li.addRemoveCB&&Li.addRemoveCB(this.el,n,!1,!1),delete n.el.gridstackNode,this.opts.staticGrid||this._removeDD(n.el)}),this.engine.removeAll(e,i),i&&this._triggerRemoveEvent(),this}setAnimation(e=this.opts.animate,i){return i?setTimeout(()=>{this.opts&&this.setAnimation(e)}):e?this.el.classList.add("grid-stack-animate"):this.el.classList.remove("grid-stack-animate"),this.opts.animate=e,this}hasAnimationCSS(){return this.el.classList.contains("grid-stack-animate")}setStatic(e,i=!0,n=!0){return!!this.opts.staticGrid===e?this:(e?this.opts.staticGrid=!0:delete this.opts.staticGrid,this._setupRemoveDrop(),this._setupAcceptWidget(),this.engine.nodes.forEach(r=>{this.prepareDragDrop(r.el),r.subGrid&&n&&r.subGrid.setStatic(e,i,n)}),i&&this._setStaticClass(),this)}updateOptions(e){var n;const i=this.opts;return e===i?this:(e.acceptWidgets!==void 0&&(i.acceptWidgets=e.acceptWidgets,this._setupAcceptWidget()),e.animate!==void 0&&this.setAnimation(e.animate),e.cellHeight&&this.cellHeight(e.cellHeight),e.class!==void 0&&e.class!==i.class&&(i.class&&this.el.classList.remove(i.class),e.class&&this.el.classList.add(e.class)),e.columnOpts?(this.opts.columnOpts=e.columnOpts,this.checkDynamicColumn()):e.columnOpts===null&&this.opts.columnOpts?(delete this.opts.columnOpts,this._updateResizeEvent()):typeof e.column=="number"&&this.column(e.column),e.margin!==void 0&&this.margin(e.margin),e.staticGrid!==void 0&&this.setStatic(e.staticGrid),e.disableDrag!==void 0&&!e.staticGrid&&this.enableMove(!e.disableDrag),e.disableResize!==void 0&&!e.staticGrid&&this.enableResize(!e.disableResize),e.float!==void 0&&this.float(e.float),e.row!==void 0?(i.minRow=i.maxRow=i.row=e.row,this._updateContainerHeight()):(e.minRow!==void 0&&(i.minRow=e.minRow,this._updateContainerHeight()),e.maxRow!==void 0&&(i.maxRow=e.maxRow)),e.lazyLoad!==void 0&&(i.lazyLoad=e.lazyLoad),(n=e.children)!=null&&n.length&&this.load(e.children),this)}update(e,i){return Li.getElements(e).forEach(n=>{var c;const r=n==null?void 0:n.gridstackNode;if(!r)return;const o={...lr.copyPos({},r),...lr.cloneDeep(i)};this.engine.nodeBoundFix(o),delete o.autoPosition;const a=["x","y","w","h"];let s;if(a.some(d=>o[d]!==void 0&&o[d]!==r[d])&&(s={},a.forEach(d=>{s[d]=o[d]!==void 0?o[d]:r[d],delete o[d]})),!s&&(o.minW||o.minH||o.maxW||o.maxH)&&(s={}),o.content!==void 0){const d=n.querySelector(".grid-stack-item-content");d&&d.textContent!==o.content&&(r.content=o.content,Li.renderCB(d,o),(c=r.subGrid)!=null&&c.el&&(d.appendChild(r.subGrid.el),r.subGrid._updateContainerHeight())),delete o.content}let l=!1,u=!1;for(const d in o)d[0]!=="_"&&r[d]!==o[d]&&(r[d]=o[d],l=!0,u=u||!this.opts.staticGrid&&(d==="noResize"||d==="noMove"||d==="locked"));if(lr.sanitizeMinMax(r),s){const d=s.w!==void 0&&s.w!==r.w;this.moveNode(r,s),d&&r.subGrid?r.subGrid.onResize(this.hasAnimationCSS()?r.w:void 0):this.resizeToContentCheck(d,r),delete r._orig}(s||l)&&this._writeAttr(n,r),u&&this.prepareDragDrop(r.el),Li.updateCB&&Li.updateCB(r)}),this}moveNode(e,i){const n=e._updating;n||this.engine.cleanNodes().beginUpdate(e),this.engine.moveNode(e,i),this._updateContainerHeight(),n||(this._triggerChangeEvent(),this.engine.endUpdate())}resizeToContent(e){var f,h;if(!e||(e.classList.remove("size-to-content-max"),!e.clientHeight))return;const i=e.gridstackNode;if(!i)return;const n=i.grid;if(!n||e.parentElement!==n.el)return;const r=n.getCellHeight(!0);if(!r)return;let o=i.h?i.h*r:e.clientHeight,a;if(i.resizeToContentParent&&(a=e.querySelector(i.resizeToContentParent)),a||(a=e.querySelector(Li.resizeToContentParent)),!a)return;const s=e.clientHeight-a.clientHeight,l=i.h?i.h*r-s:a.clientHeight;let u;if(i.subGrid){u=i.subGrid.getRow()*i.subGrid.getCellHeight(!0);const p=i.subGrid.el.getBoundingClientRect(),g=e.getBoundingClientRect();u+=p.top-g.top}else{if((h=(f=i.subGridOpts)==null?void 0:f.children)!=null&&h.length)return;{const p=a.firstElementChild;if(!p){console.error(`Error: GridStack.resizeToContent() widget id:${i.id} '${Li.resizeToContentParent}'.firstElementChild is null, make sure to have a div like container. Skipping sizing.`);return}u=p.getBoundingClientRect().height||l}}if(l===u)return;o+=u-l;let c=Math.ceil(o/r);const d=Number.isInteger(i.sizeToContent)?i.sizeToContent:0;d&&c>d&&(c=d,e.classList.add("size-to-content-max")),i.minH&&c<i.minH?c=i.minH:i.maxH&&c>i.maxH&&(c=i.maxH),c!==i.h&&(n._ignoreLayoutsNodeChange=!0,n.moveNode(i,{h:c}),delete n._ignoreLayoutsNodeChange)}resizeToContentCBCheck(e){Li.resizeToContentCB?Li.resizeToContentCB(e):this.resizeToContent(e)}rotate(e,i){return Li.getElements(e).forEach(n=>{const r=n.gridstackNode;if(!lr.canBeRotated(r))return;const o={w:r.h,h:r.w,minH:r.minW,minW:r.minH,maxH:r.maxW,maxW:r.maxH};if(i){const s=i.left>0?Math.floor(i.left/this.cellWidth()):0,l=i.top>0?Math.floor(i.top/this.opts.cellHeight):0;o.x=r.x+s-(r.h-(l+1)),o.y=r.y+l-s}Object.keys(o).forEach(s=>{o[s]===void 0&&delete o[s]});const a=r._orig;this.update(n,o),r._orig=a}),this}margin(e){if(!(typeof e=="string"&&e.split(" ").length>1)){const n=lr.parseHeight(e);if(this.opts.marginUnit===n.unit&&this.opts.margin===n.h)return}return this.opts.margin=e,this.opts.marginTop=this.opts.marginBottom=this.opts.marginLeft=this.opts.marginRight=void 0,this._initMargin(),this}getMargin(){return this.opts.margin}willItFit(e){return this.engine.willItFit(e)}_triggerChangeEvent(){if(this.engine.batchMode)return this;const e=this.engine.getDirtyNodes(!0);return e&&e.length&&(this._ignoreLayoutsNodeChange||this.engine.layoutsNodesChange(e),this._triggerEvent("change",e)),this.engine.saveInitial(),this}_triggerAddEvent(){var e;if(this.engine.batchMode)return this;if((e=this.engine.addedNodes)!=null&&e.length){this._ignoreLayoutsNodeChange||this.engine.layoutsNodesChange(this.engine.addedNodes),this.engine.addedNodes.forEach(n=>{delete n._dirty});const i=[...this.engine.addedNodes];this.engine.addedNodes=[],this._triggerEvent("added",i)}return this}_triggerRemoveEvent(){var e;if(this.engine.batchMode)return this;if((e=this.engine.removedNodes)!=null&&e.length){const i=[...this.engine.removedNodes];this.engine.removedNodes=[],this._triggerEvent("removed",i)}return this}_triggerEvent(e,i){const n=i?new CustomEvent(e,{bubbles:!1,detail:i}):new Event(e);let r=this;for(;r.parentGridNode;)r=r.parentGridNode.grid;return r.el.dispatchEvent(n),this}_updateContainerHeight(){if(!this.engine||this.engine.batchMode)return this;const e=this.parentGridNode;let i=this.getRow()+this._extraDragRow;const n=this.opts.cellHeight,r=this.opts.cellHeightUnit;if(!n)return this;if(!e&&!this.opts.minRow){const o=lr.parseHeight(getComputedStyle(this.el).minHeight);if(o.h>0&&o.unit===r){const a=Math.floor(o.h/n);i<a&&(i=a)}}return this.el.setAttribute("gs-current-row",String(i)),this.el.style.removeProperty("min-height"),this.el.style.removeProperty("height"),i&&(this.el.style[e?"minHeight":"height"]=i*n+r),e&&lr.shouldSizeToContent(e)&&e.grid.resizeToContentCBCheck(e.el),this}_prepareElement(e,i=!1,n){n=n||this._readAttr(e),e.gridstackNode=n,n.el=e,n.grid=this,n=this.engine.addNode(n,i),this._writeAttr(e,n),e.classList.add(gp.itemClass,this.opts.itemClass);const r=lr.shouldSizeToContent(n);return r?e.classList.add("size-to-content"):e.classList.remove("size-to-content"),r&&this.resizeToContentCheck(!1,n),lr.lazyLoad(n)||this.prepareDragDrop(n.el),this}_writePosAttr(e,i){return(!i._moving&&!i._resizing||this._placeholder===e)&&(e.style.top=i.y?i.y===1?"var(--gs-cell-height)":`calc(${i.y} * var(--gs-cell-height))`:null,e.style.left=i.x?i.x===1?"var(--gs-column-width)":`calc(${i.x} * var(--gs-column-width))`:null,e.style.width=i.w>1?`calc(${i.w} * var(--gs-column-width))`:null,e.style.height=i.h>1?`calc(${i.h} * var(--gs-cell-height))`:null),e.setAttribute("gs-x",String(i.x)),e.setAttribute("gs-y",String(i.y)),i.w>1?e.setAttribute("gs-w",String(i.w)):e.removeAttribute("gs-w"),i.h>1?e.setAttribute("gs-h",String(i.h)):e.removeAttribute("gs-h"),this}_writeAttr(e,i){if(!i)return this;this._writePosAttr(e,i);const n={noResize:"gs-no-resize",noMove:"gs-no-move",locked:"gs-locked",id:"gs-id",sizeToContent:"gs-size-to-content"};for(const r in n)i[r]?e.setAttribute(n[r],String(i[r])):e.removeAttribute(n[r]);return this}_readAttr(e,i=!0){const n={};n.x=lr.toNumber(e.getAttribute("gs-x")),n.y=lr.toNumber(e.getAttribute("gs-y")),n.w=lr.toNumber(e.getAttribute("gs-w")),n.h=lr.toNumber(e.getAttribute("gs-h")),n.autoPosition=lr.toBool(e.getAttribute("gs-auto-position")),n.noResize=lr.toBool(e.getAttribute("gs-no-resize")),n.noMove=lr.toBool(e.getAttribute("gs-no-move")),n.locked=lr.toBool(e.getAttribute("gs-locked"));const r=e.getAttribute("gs-size-to-content");r&&(r==="true"||r==="false"?n.sizeToContent=lr.toBool(r):n.sizeToContent=parseInt(r,10)),n.id=e.getAttribute("gs-id"),n.maxW=lr.toNumber(e.getAttribute("gs-max-w")),n.minW=lr.toNumber(e.getAttribute("gs-min-w")),n.maxH=lr.toNumber(e.getAttribute("gs-max-h")),n.minH=lr.toNumber(e.getAttribute("gs-min-h")),i&&(n.w===1&&e.removeAttribute("gs-w"),n.h===1&&e.removeAttribute("gs-h"),n.maxW&&e.removeAttribute("gs-max-w"),n.minW&&e.removeAttribute("gs-min-w"),n.maxH&&e.removeAttribute("gs-max-h"),n.minH&&e.removeAttribute("gs-min-h"));for(const o in n){if(!n.hasOwnProperty(o))return;!n[o]&&n[o]!==0&&o!=="sizeToContent"&&delete n[o]}return n}_setStaticClass(){const e=["grid-stack-static"];return this.opts.staticGrid?(this.el.classList.add(...e),this.el.setAttribute("gs-static","true")):(this.el.classList.remove(...e),this.el.removeAttribute("gs-static")),this}onResize(e=(i=>(i=this.el)==null?void 0:i.clientWidth)()){if(!e||this.prevWidth===e)return;this.prevWidth=e,this.batchUpdate();let n=!1;return this._autoColumn&&this.parentGridNode?this.opts.column!==this.parentGridNode.w&&(this.column(this.parentGridNode.w,this.opts.layout||"list"),n=!0):n=this.checkDynamicColumn(),this._isAutoCellHeight&&this.cellHeight(),this.engine.nodes.forEach(r=>{r.subGrid&&r.subGrid.onResize()}),this._skipInitialResize||this.resizeToContentCheck(n),delete this._skipInitialResize,this.batchUpdate(!1),this}resizeToContentCheck(e=!1,i=void 0){if(this.engine){if(e&&this.hasAnimationCSS())return setTimeout(()=>this.resizeToContentCheck(!1,i),this.animationDelay);if(i)lr.shouldSizeToContent(i)&&this.resizeToContentCBCheck(i.el);else if(this.engine.nodes.some(n=>lr.shouldSizeToContent(n))){const n=[...this.engine.nodes];this.batchUpdate(),n.forEach(r=>{lr.shouldSizeToContent(r)&&this.resizeToContentCBCheck(r.el)}),this._ignoreLayoutsNodeChange=!0,this.batchUpdate(!1),this._ignoreLayoutsNodeChange=!1}this._gsEventHandler.resizecontent&&this._gsEventHandler.resizecontent(null,i?[i]:this.engine.nodes)}}_updateResizeEvent(e=!1){const i=!this.parentGridNode&&(this._isAutoCellHeight||this.opts.sizeToContent||this.opts.columnOpts||this.engine.nodes.find(n=>n.sizeToContent));return!e&&i&&!this.resizeObserver?(this._sizeThrottle=lr.throttle(()=>this.onResize(),this.opts.cellHeightThrottle),this.resizeObserver=new ResizeObserver(()=>this._sizeThrottle()),this.resizeObserver.observe(this.el),this._skipInitialResize=!0):(e||!i)&&this.resizeObserver&&(this.resizeObserver.disconnect(),delete this.resizeObserver,delete this._sizeThrottle),this}static getElement(e=".grid-stack-item"){return lr.getElement(e)}static getElements(e=".grid-stack-item"){return lr.getElements(e)}static getGridElement(e){return Li.getElement(e)}static getGridElements(e){return lr.getElements(e)}_initMargin(){let e,i=0,n=[];typeof this.opts.margin=="string"&&(n=this.opts.margin.split(" ")),n.length===2?(this.opts.marginTop=this.opts.marginBottom=n[0],this.opts.marginLeft=this.opts.marginRight=n[1]):n.length===4?(this.opts.marginTop=n[0],this.opts.marginRight=n[1],this.opts.marginBottom=n[2],this.opts.marginLeft=n[3]):(e=lr.parseHeight(this.opts.margin),this.opts.marginUnit=e.unit,i=this.opts.margin=e.h),["marginTop","marginRight","marginBottom","marginLeft"].forEach(a=>{this.opts[a]===void 0?this.opts[a]=i:(e=lr.parseHeight(this.opts[a]),this.opts[a]=e.h,delete this.opts.margin)}),this.opts.marginUnit=e.unit,this.opts.marginTop===this.opts.marginBottom&&this.opts.marginLeft===this.opts.marginRight&&this.opts.marginTop===this.opts.marginRight&&(this.opts.margin=this.opts.marginTop);const o=this.el.style;return o.setProperty("--gs-item-margin-top",`${this.opts.marginTop}${this.opts.marginUnit}`),o.setProperty("--gs-item-margin-bottom",`${this.opts.marginBottom}${this.opts.marginUnit}`),o.setProperty("--gs-item-margin-right",`${this.opts.marginRight}${this.opts.marginUnit}`),o.setProperty("--gs-item-margin-left",`${this.opts.marginLeft}${this.opts.marginUnit}`),this}static getDD(){return Pf}static setupDragIn(e,i,n,r=document){(i==null?void 0:i.pause)!==void 0&&(sn.pauseDrag=i.pause),i={appendTo:"body",helper:"clone",...i||{}},(typeof e=="string"?lr.getElements(e,r):e).forEach((a,s)=>{Pf.isDraggable(a)||Pf.dragIn(a,i),n!=null&&n[s]&&(a.gridstackNode=n[s])})}movable(e,i){return this.opts.staticGrid?this:(Li.getElements(e).forEach(n=>{const r=n.gridstackNode;r&&(i?delete r.noMove:r.noMove=!0,this.prepareDragDrop(r.el))}),this)}resizable(e,i){return this.opts.staticGrid?this:(Li.getElements(e).forEach(n=>{const r=n.gridstackNode;r&&(i?delete r.noResize:r.noResize=!0,this.prepareDragDrop(r.el))}),this)}disable(e=!0){if(!this.opts.staticGrid)return this.enableMove(!1,e),this.enableResize(!1,e),this._triggerEvent("disable"),this}enable(e=!0){if(!this.opts.staticGrid)return this.enableMove(!0,e),this.enableResize(!0,e),this._triggerEvent("enable"),this}enableMove(e,i=!0){return this.opts.staticGrid?this:(e?delete this.opts.disableDrag:this.opts.disableDrag=!0,this.engine.nodes.forEach(n=>{this.prepareDragDrop(n.el),n.subGrid&&i&&n.subGrid.enableMove(e,i)}),this)}enableResize(e,i=!0){return this.opts.staticGrid?this:(e?delete this.opts.disableResize:this.opts.disableResize=!0,this.engine.nodes.forEach(n=>{this.prepareDragDrop(n.el),n.subGrid&&i&&n.subGrid.enableResize(e,i)}),this)}cancelDrag(){var i;const e=(i=this._placeholder)==null?void 0:i.gridstackNode;e&&(e._isExternal?(e._isAboutToRemove=!0,this.engine.removeNode(e)):e._isAboutToRemove&&Li._itemRemoving(e.el,!1),this.engine.restoreInitial())}_removeDD(e){return Pf.draggable(e,"destroy").resizable(e,"destroy"),e.gridstackNode&&delete e.gridstackNode._initDD,delete e.ddElement,this}_setupAcceptWidget(){if(this.opts.staticGrid||!this.opts.acceptWidgets&&!this.opts.removable)return Pf.droppable(this.el,"destroy"),this;let e,i;const n=(r,o,a)=>{var f;a=a||o;const s=a.gridstackNode;if(!s)return;if(!((f=s.grid)!=null&&f.el)){a.style.transform=`scale(${1/this.dragTransform.xScale},${1/this.dragTransform.yScale})`;const h=a.getBoundingClientRect();a.style.left=h.x+(this.dragTransform.xScale-1)*(r.clientX-h.x)/this.dragTransform.xScale+"px",a.style.top=h.y+(this.dragTransform.yScale-1)*(r.clientY-h.y)/this.dragTransform.yScale+"px",a.style.transformOrigin="0px 0px"}let{top:l,left:u}=a.getBoundingClientRect();const c=this.el.getBoundingClientRect();u-=c.left,l-=c.top;const d={position:{top:l*this.dragTransform.xScale,left:u*this.dragTransform.yScale}};if(s._temporaryRemoved){if(s.x=Math.max(0,Math.round(u/i)),s.y=Math.max(0,Math.round(l/e)),delete s.autoPosition,this.engine.nodeBoundFix(s),!this.engine.willItFit(s)){if(s.autoPosition=!0,!this.engine.willItFit(s)){Pf.off(o,"drag");return}s._willFitPos&&(lr.copyPos(s,s._willFitPos),delete s._willFitPos)}this._onStartMoving(a,r,d,s,i,e)}else this._dragOrResize(a,r,d,s,i,e)};return Pf.droppable(this.el,{accept:r=>{const o=r.gridstackNode||this._readAttr(r,!1);if((o==null?void 0:o.grid)===this)return!0;if(!this.opts.acceptWidgets)return!1;let a=!0;if(typeof this.opts.acceptWidgets=="function")a=this.opts.acceptWidgets(r);else{const s=this.opts.acceptWidgets===!0?".grid-stack-item":this.opts.acceptWidgets;a=r.matches(s)}if(a&&o&&this.opts.maxRow){const s={w:o.w,h:o.h,minW:o.minW,minH:o.minH};a=this.engine.willItFit(s)}return a}}).on(this.el,"dropover",(r,o,a)=>{let s=(a==null?void 0:a.gridstackNode)||o.gridstackNode;if((s==null?void 0:s.grid)===this&&!s._temporaryRemoved)return!1;if(s!=null&&s._sidebarOrig&&(s.w=s._sidebarOrig.w,s.h=s._sidebarOrig.h),s!=null&&s.grid&&s.grid!==this&&!s._temporaryRemoved&&s.grid._leave(o,a),a=a||o,i=this.cellWidth(),e=this.getCellHeight(!0),!s){const c=a.getAttribute("data-gs-widget")||a.getAttribute("gridstacknode");if(c){try{s=JSON.parse(c)}catch{console.error("Gridstack dropover: Bad JSON format: ",c)}a.removeAttribute("data-gs-widget"),a.removeAttribute("gridstacknode")}s||(s=this._readAttr(a)),s._sidebarOrig={w:s.w,h:s.h}}s.grid||(s.el||(s={...s}),s._isExternal=!0,a.gridstackNode=s);const l=s.w||Math.round(a.offsetWidth/i)||1,u=s.h||Math.round(a.offsetHeight/e)||1;return s.grid&&s.grid!==this?(o._gridstackNodeOrig||(o._gridstackNodeOrig=s),o.gridstackNode=s={...s,w:l,h:u,grid:this},delete s.x,delete s.y,this.engine.cleanupNode(s).nodeBoundFix(s),s._initDD=s._isExternal=s._temporaryRemoved=!0):(s.w=l,s.h=u,s._temporaryRemoved=!0),Li._itemRemoving(s.el,!1),Pf.on(o,"drag",n),n(r,o,a),!1}).on(this.el,"dropout",(r,o,a)=>{const s=(a==null?void 0:a.gridstackNode)||o.gridstackNode;return s&&(!s.grid||s.grid===this)&&(this._leave(o,a),this._isTemp&&this.removeAsSubGrid(s)),!1}).on(this.el,"drop",(r,o,a)=>{var f,h,p;const s=(a==null?void 0:a.gridstackNode)||o.gridstackNode;if((s==null?void 0:s.grid)===this&&!s._isExternal)return!1;const l=!!this.placeholder.parentElement,u=o!==a;this.placeholder.remove(),delete this.placeholder.gridstackNode,l&&this.opts.animate&&(this.setAnimation(!1),this.setAnimation(!0,!0));const c=o._gridstackNodeOrig;if(delete o._gridstackNodeOrig,l&&(c!=null&&c.grid)&&c.grid!==this){const g=c.grid;g.engine.removeNodeFromLayoutCache(c),g.engine.removedNodes.push(c),g._triggerRemoveEvent()._triggerChangeEvent(),g.parentGridNode&&!g.engine.nodes.length&&g.opts.subGridDynamic&&g.removeAsSubGrid()}if(!s||(l&&(this.engine.cleanupNode(s),s.grid=this),(f=s.grid)==null||delete f._isTemp,Pf.off(o,"drag"),a!==o?(a.remove(),o=a):o.remove(),this._removeDD(o),!l))return!1;const d=(p=(h=s.subGrid)==null?void 0:h.el)==null?void 0:p.gridstack;return lr.copyPos(s,this._readAttr(this.placeholder)),lr.removePositioningStyles(o),u&&(s.content||s.subGridOpts||Li.addRemoveCB)?(delete s.el,o=this.addWidget(s)):(this._prepareElement(o,!0,s),this.el.appendChild(o),this.resizeToContentCheck(!1,s),d&&(d.parentGridNode=s),this._updateContainerHeight()),this.engine.addedNodes.push(s),this._triggerAddEvent(),this._triggerChangeEvent(),this.engine.endUpdate(),this._gsEventHandler.dropped&&this._gsEventHandler.dropped({...r,type:"dropped"},c&&c.grid?c:void 0,s),!1}),this}static _itemRemoving(e,i){if(!e)return;const n=e?e.gridstackNode:void 0;!(n!=null&&n.grid)||e.classList.contains(n.grid.opts.removableOptions.decline)||(i?n._isAboutToRemove=!0:delete n._isAboutToRemove,i?e.classList.add("grid-stack-item-removing"):e.classList.remove("grid-stack-item-removing"))}_setupRemoveDrop(){if(typeof this.opts.removable!="string")return this;const e=document.querySelector(this.opts.removable);return e?(!this.opts.staticGrid&&!Pf.isDroppable(e)&&Pf.droppable(e,this.opts.removableOptions).on(e,"dropover",(i,n)=>Li._itemRemoving(n,!0)).on(e,"dropout",(i,n)=>Li._itemRemoving(n,!1)),this):this}prepareDragDrop(e,i=!1){const n=e==null?void 0:e.gridstackNode;if(!n)return;const r=n.noMove||this.opts.disableDrag,o=n.noResize||this.opts.disableResize,a=this.opts.staticGrid||r&&o;if((i||a)&&(n._initDD&&(this._removeDD(e),delete n._initDD),a&&e.classList.add("ui-draggable-disabled","ui-resizable-disabled"),!i))return this;if(!n._initDD){let s,l;const u=(f,h)=>{this.triggerEvent(f,f.target),s=this.cellWidth(),l=this.getCellHeight(!0),this._onStartMoving(e,f,h,n,s,l)},c=(f,h)=>{this._dragOrResize(e,f,h,n,s,l)},d=f=>{this.placeholder.remove(),delete this.placeholder.gridstackNode,delete n._moving,delete n._resizing,delete n._event,delete n._lastTried;const h=n.w!==n._orig.w,p=f.target;if(!(!p.gridstackNode||p.gridstackNode.grid!==this)){if(n.el=p,n._isAboutToRemove){const g=e.gridstackNode.grid;g._gsEventHandler[f.type]&&g._gsEventHandler[f.type](f,p),g.engine.nodes.push(n),g.removeWidget(e,!0,!0)}else lr.removePositioningStyles(p),n._temporaryRemoved?(this._writePosAttr(p,n),this.engine.addNode(n)):this._writePosAttr(p,n),this.triggerEvent(f,p);this._extraDragRow=0,this._updateContainerHeight(),this._triggerChangeEvent(),this.engine.endUpdate(),f.type==="resizestop"&&(Number.isInteger(n.sizeToContent)&&(n.sizeToContent=n.h),this.resizeToContentCheck(h,n))}};Pf.draggable(e,{start:u,stop:d,drag:c}).resizable(e,{start:u,stop:d,resize:c}),n._initDD=!0}return Pf.draggable(e,r?"disable":"enable").resizable(e,o?"disable":"enable"),this}_onStartMoving(e,i,n,r,o,a){var s;if(this.engine.cleanNodes().beginUpdate(r),this._writePosAttr(this.placeholder,r),this.el.appendChild(this.placeholder),this.placeholder.gridstackNode=r,(s=r.grid)!=null&&s.el)this.dragTransform=lr.getValuesFromTransformedElement(e);else if(this.placeholder&&this.placeholder.closest(".grid-stack")){const l=this.placeholder.closest(".grid-stack");this.dragTransform=lr.getValuesFromTransformedElement(l)}else this.dragTransform={xScale:1,xOffset:0,yScale:1,yOffset:0};if(r.el=this.placeholder,r._lastUiPosition=n.position,r._prevYPix=n.position.top,r._moving=i.type==="dragstart",r._resizing=i.type==="resizestart",delete r._lastTried,i.type==="dropover"&&r._temporaryRemoved&&(this.engine.addNode(r),r._moving=!0),this.engine.cacheRects(o,a,this.opts.marginTop,this.opts.marginRight,this.opts.marginBottom,this.opts.marginLeft),i.type==="resizestart"){const l=this.getColumn()-r.x,u=(this.opts.maxRow||Number.MAX_SAFE_INTEGER)-r.y;Pf.resizable(e,"option","minWidth",o*Math.min(r.minW||1,l)).resizable(e,"option","minHeight",a*Math.min(r.minH||1,u)).resizable(e,"option","maxWidth",o*Math.min(r.maxW||Number.MAX_SAFE_INTEGER,l)).resizable(e,"option","maxWidthMoveLeft",o*Math.min(r.maxW||Number.MAX_SAFE_INTEGER,r.x+r.w)).resizable(e,"option","maxHeight",a*Math.min(r.maxH||Number.MAX_SAFE_INTEGER,u)).resizable(e,"option","maxHeightMoveUp",a*Math.min(r.maxH||Number.MAX_SAFE_INTEGER,r.y+r.h))}}_dragOrResize(e,i,n,r,o,a){const s={...r._orig};let l,u=this.opts.marginLeft,c=this.opts.marginRight,d=this.opts.marginTop,f=this.opts.marginBottom;const h=Math.round(a*.1),p=Math.round(o*.1);if(u=Math.min(u,p),c=Math.min(c,p),d=Math.min(d,h),f=Math.min(f,h),i.type==="drag"){if(r._temporaryRemoved)return;const v=n.position.top-r._prevYPix;r._prevYPix=n.position.top,this.opts.draggable.scroll!==!1&&lr.updateScrollPosition(e,n.position,v);const y=n.position.left+(n.position.left>r._lastUiPosition.left?-c:u),m=n.position.top+(n.position.top>r._lastUiPosition.top?-f:d);s.x=Math.round(y/o),s.y=Math.round(m/a);const b=this._extraDragRow;if(this.engine.collide(r,s)){const S=this.getRow();let _=Math.max(0,s.y+r.h-S);this.opts.maxRow&&S+_>this.opts.maxRow&&(_=Math.max(0,this.opts.maxRow-S)),this._extraDragRow=_}else this._extraDragRow=0;if(this._extraDragRow!==b&&this._updateContainerHeight(),r.x===s.x&&r.y===s.y)return}else if(i.type==="resize"){if(s.x<0||(lr.updateScrollResize(i,e,a),s.w=Math.round((n.size.width-u)/o),s.h=Math.round((n.size.height-d)/a),r.w===s.w&&r.h===s.h)||r._lastTried&&r._lastTried.w===s.w&&r._lastTried.h===s.h)return;const v=n.position.left+u,y=n.position.top+d;s.x=Math.round(v/o),s.y=Math.round(y/a),l=!0}r._event=i,r._lastTried=s;const g={x:n.position.left+u,y:n.position.top+d,w:(n.size?n.size.width:r.w*o)-u-c,h:(n.size?n.size.height:r.h*a)-d-f};if(this.engine.moveNodeCheck(r,{...s,cellWidth:o,cellHeight:a,rect:g,resizing:l})){r._lastUiPosition=n.position,this.engine.cacheRects(o,a,d,c,f,u),delete r._skipDown,l&&r.subGrid&&r.subGrid.onResize(),this._extraDragRow=0,this._updateContainerHeight();const v=i.target;r._sidebarOrig||this._writePosAttr(v,r),this.triggerEvent(i,v)}}triggerEvent(e,i){let n=this;for(;n.parentGridNode;)n=n.parentGridNode.grid;n._gsEventHandler[e.type]&&n._gsEventHandler[e.type](e,i)}_leave(e,i){i=i||e;const n=i.gridstackNode;if(!n||(i.style.transform=i.style.transformOrigin=null,Pf.off(e,"drag"),n._temporaryRemoved))return;n._temporaryRemoved=!0,this.engine.removeNode(n),n.el=n._isExternal&&i?i:e;const r=n._sidebarOrig;n._isExternal&&this.engine.cleanupNode(n),n._sidebarOrig=r,this.opts.removable===!0&&Li._itemRemoving(e,!0),e._gridstackNodeOrig?(e.gridstackNode=e._gridstackNodeOrig,delete e._gridstackNodeOrig):n._isExternal&&this.engine.restoreInitial()}}Li.renderCB=(t,e)=>{t&&(e!=null&&e.content)&&(t.textContent=e.content)};Li.resizeToContentParent=".grid-stack-item-content";Li.Utils=lr;Li.Engine=uS;Li.GDRev="12.4.2";const zDt=80,$Dt=12,WDt=4,GDt=J.forwardRef(function(e,i){const n=qt.c(22),{items:r,onLayoutChange:o,columns:a,margin:s,renderItem:l}=e,u=a===void 0?$Dt:a,c=s===void 0?WDt:s,{track:d}=el(),f=J.useRef(null),h=J.useRef(null);let p;n[0]===Symbol.for("react.memo_cache_sentinel")?(p=new Map,n[0]=p):p=n[0];const[g,v]=J.useState(p),y=J.useRef(!1);let m,b;n[1]!==u||n[2]!==c||n[3]!==o||n[4]!==d?(m=()=>{if(!(!f.current||y.current))return h.current=Li.init({handle:".grid-stack-item-drag-handle",column:u,cellHeight:zDt,margin:c,float:!0,animate:!0,resizable:{handles:"se"},draggable:{handle:".grid-stack-item-drag-handle"}},f.current),y.current=!0,h.current.on("change",()=>{if(o&&h.current){const R=h.current.getGridItems().map(YDt);o(R)}}),h.current.on("dragstop",(R,M)=>{const D=M.gridstackNode;D!=null&&D.id&&d(Fi.DashboardLayoutMove,{x:D.x??void 0,y:D.y??void 0})}),h.current.on("resizestop",(R,M)=>{const D=M.gridstackNode;D!=null&&D.id&&d(Fi.DashboardLayoutResize,{width:D.w??void 0,height:D.h??void 0})}),()=>{h.current&&(h.current.destroy(!1),h.current=null,y.current=!1)}},b=[u,c,o,d],n[1]=u,n[2]=c,n[3]=o,n[4]=d,n[5]=m,n[6]=b):(m=n[5],b=n[6]),J.useEffect(m,b);let S,_;n[7]===Symbol.for("react.memo_cache_sentinel")?(S=()=>({compact:()=>{h.current&&h.current.compact("list",!0)}}),_=[],n[7]=S,n[8]=_):(S=n[7],_=n[8]),J.useImperativeHandle(i,S,_);let C,P;n[9]!==r?(C=()=>{const R=h.current;if(!R||!y.current)return;R.batchUpdate();const M=R.getGridItems(),D=new Map;M.forEach(V=>{const z=V.getAttribute("gs-id");z&&D.set(z,V)});const F=new Map;r.forEach(V=>{if(D.has(V.id)){const G=D.get(V.id).querySelector(".grid-stack-item-content");G&&F.set(V.id,G)}else{console.log("Creating new widget",V);const G=R.addWidget({id:V.id,x:V.x??0,y:V.y,w:V.w??3,h:V.h??3,content:""}).querySelector(".grid-stack-item-content");G&&F.set(V.id,G)}});const I=new Set(r.map(qDt));D.forEach((V,z)=>{I.has(z)||R.removeWidget(V)}),R.batchUpdate(!1),queueMicrotask(()=>{v(F)})},P=[r],n[9]=r,n[10]=C,n[11]=P):(C=n[10],P=n[11]),J.useEffect(C,P);let x;n[12]===Symbol.for("react.memo_cache_sentinel")?(x=L.jsx("div",{ref:f,className:"grid-stack"}),n[12]=x):x=n[12];let E;if(n[13]!==g||n[14]!==r||n[15]!==l){let R;n[17]!==g||n[18]!==l?(R=M=>{const D=g.get(M.id);return D?L.jsx("div",{children:zf.createPortal(l(M,D),D)},M.id):null},n[17]=g,n[18]=l,n[19]=R):R=n[19],E=r.map(R),n[13]=g,n[14]=r,n[15]=l,n[16]=E}else E=n[16];let A;return n[20]!==E?(A=L.jsxs("div",{className:"gridstack-container w-full}",children:[x,E]}),n[20]=E,n[21]=A):A=n[21],A});function YDt(t){const e=t.gridstackNode;return{id:e==null?void 0:e.id,x:(e==null?void 0:e.x)??0,y:(e==null?void 0:e.y)??0,w:(e==null?void 0:e.w)??12,h:(e==null?void 0:e.h)??3}}function qDt(t){return t.id}const XDt=t=>{const e=qt.c(10),{signal:i}=t;let n;e[0]!==i.name?(n=L.jsx("span",{className:"text-xxs text-muted-foreground flex-1 truncate mr-4 ml-4",title:i.name,children:i.name}),e[0]=i.name,e[1]=n):n=e[1];const r=i.formattedValue?`${i.formattedValue} (${i.value})`:i.value;let o;e[2]!==r?(o=L.jsx("span",{className:"text-xxs text-green-600 dark:text-green-400 font-mono w-40 text-left truncate",children:r}),e[2]=r,e[3]=o):o=e[3];const a=i.unit||"";let s;e[4]!==a?(s=L.jsx("span",{className:"text-xxs text-muted-foreground w-32 ml-2",children:a}),e[4]=a,e[5]=s):s=e[5];let l;return e[6]!==n||e[7]!==o||e[8]!==s?(l=L.jsxs("div",{className:"flex items-center px-2 py-0.5 bg-muted/60 border-b border-border/20",children:[n,o,s]}),e[6]=n,e[7]=o,e[8]=s,e[9]=l):l=e[9],l},w7=[500,1e3,5e3,1e4,2e4,3e4,4e4,5e4];function KDt(t){const e=qt.c(35),{groupByFrame:i,bufferSize:n,onBufferSizeChange:r,sortOrder:o,onSortOrderChange:a,onGroupByFrameChange:s,onClear:l,onAddSignal:u,onRemove:c}=t,d=w7.indexOf(n);let f;e[0]!==d||e[1]!==r?(f=R=>{const M=Math.max(0,Math.min(w7.length-1,d+R));r(w7[M])},e[0]=d,e[1]=r,e[2]=f):f=e[2];const h=f;let p;e[3]!==n||e[4]!==h?(p=R=>h(R>n?1:-1),e[3]=n,e[4]=h,e[5]=p):p=e[5];let g;e[6]!==n||e[7]!==p?(g=L.jsx(Ri.NumberStepper,{label:"Buffer",value:n,onChange:p,formatValue:ZDt}),e[6]=n,e[7]=p,e[8]=g):g=e[8];const v=o==="newest-first";let y;e[9]!==a?(y=R=>a(R?"newest-first":"oldest-first"),e[9]=a,e[10]=y):y=e[10];let m;e[11]!==v||e[12]!==y?(m=L.jsx(Ri.Toggle,{label:"Newest first",checked:v,onChange:y}),e[11]=v,e[12]=y,e[13]=m):m=e[13];let b;e[14]!==i||e[15]!==s?(b=L.jsx(Ri.Toggle,{label:"Group by frame",checked:i,onChange:s}),e[14]=i,e[15]=s,e[16]=b):b=e[16];let S;e[17]!==g||e[18]!==m||e[19]!==b?(S=L.jsxs(Ri.Section,{title:"Settings",children:[g,m,b]}),e[17]=g,e[18]=m,e[19]=b,e[20]=S):S=e[20];let _;e[21]===Symbol.for("react.memo_cache_sentinel")?(_=L.jsx(Ri.Divider,{}),e[21]=_):_=e[21];let C;e[22]!==u?(C=u&&L.jsx(Ri.Button,{icon:dr.ACTION_EDIT,label:"Select signals",onClick:u}),e[22]=u,e[23]=C):C=e[23];let P;e[24]!==l?(P=L.jsx(Ri.Button,{icon:dr.ACTION_DELETE,label:"Clear trace",onClick:l}),e[24]=l,e[25]=P):P=e[25];let x;e[26]!==c?(x=c&&L.jsx(Ri.RemoveButton,{onClick:c}),e[26]=c,e[27]=x):x=e[27];let E;e[28]!==C||e[29]!==P||e[30]!==x?(E=L.jsxs(Ri.Section,{title:"Actions",children:[C,P,x]}),e[28]=C,e[29]=P,e[30]=x,e[31]=E):E=e[31];let A;return e[32]!==E||e[33]!==S?(A=L.jsxs(Ri,{children:[S,_,E]}),e[32]=E,e[33]=S,e[34]=A):A=e[34],A}function ZDt(t){return t>=1e3?`${t/1e3}k`:t.toString()}function u1e(t,e=8){if(!t||t.length===0)return"-";const n=Array.from(t.slice(0,e)).map(r=>r.toString(16).padStart(2,"0").toUpperCase()).join(" ");return t.length>e?`${n}...`:n}function JDt(t){const e=new Date(Math.floor(t/1e3)),i=e.getHours().toString().padStart(2,"0"),n=e.getMinutes().toString().padStart(2,"0"),r=e.getSeconds().toString().padStart(2,"0"),o=(t%1e6).toString().padStart(6,"0");return`${i}:${n}:${r}.${o}`}function QDt(t,e){return e===void 0?"-":`${((t-e)/1e6).toFixed(3)}s`}function eRt(t){return t===void 0?"-":`0x${t.toString(16).toUpperCase()}`}function c1e(t,e){if(e&&e[t]!==void 0)return e[t]}const tRt=J.memo(function(e){const i=qt.c(52),{entry:n,previousTimestampUs:r,isExpanded:o,onToggle:a,columnWidths:s,hideDelta:l}=e;let u;i[0]===Symbol.for("react.memo_cache_sentinel")?(u=Hr("flex items-center px-2 py-1 cursor-pointer hover:bg-accent border-b border-border/30"),i[0]=u):u=i[0];let c;i[1]!==n.id||i[2]!==a?(c=()=>a(n.id),i[1]=n.id,i[2]=a,i[3]=c):c=i[3];let d;i[4]!==s.chevron?(d={width:s.chevron},i[4]=s.chevron,i[5]=d):d=i[5];let f;i[6]!==n.signals.length||i[7]!==o?(f=n.signals.length>0?L.jsx(Wr,{type:o?dr.NAV_CHEVRON_DOWN:dr.NAV_CHEVRON_RIGHT,className:"w-3 h-3 text-muted-foreground"}):L.jsx("span",{className:"w-3 h-3 text-muted-foreground"}),i[6]=n.signals.length,i[7]=o,i[8]=f):f=i[8];let h;i[9]!==d||i[10]!==f?(h=L.jsx("div",{style:d,className:"flex-shrink-0",children:f}),i[9]=d,i[10]=f,i[11]=h):h=i[11];let p;i[12]!==s.timestamp?(p={width:s.timestamp},i[12]=s.timestamp,i[13]=p):p=i[13];let g;i[14]!==n.timestampUs?(g=JDt(n.timestampUs),i[14]=n.timestampUs,i[15]=g):g=i[15];let v;i[16]!==p||i[17]!==g?(v=L.jsx("span",{style:p,className:"text-xxs text-foreground font-mono flex-shrink-0 mr-2",children:g}),i[16]=p,i[17]=g,i[18]=v):v=i[18];let y;i[19]!==s.delta||i[20]!==n.timestampUs||i[21]!==l||i[22]!==r?(y=!l&&L.jsxs(L.Fragment,{children:[L.jsx("div",{className:"w-1 flex-shrink-0"}),L.jsx("span",{style:{width:s.delta},className:"text-xxs text-muted-foreground font-mono flex-shrink-0 ml-2 mr-2",children:QDt(n.timestampUs,r)}),L.jsx("div",{className:"w-1 flex-shrink-0"})]}),i[19]=s.delta,i[20]=n.timestampUs,i[21]=l,i[22]=r,i[23]=y):y=i[23];let m;i[24]!==s.frameId?(m={width:s.frameId},i[24]=s.frameId,i[25]=m):m=i[25];const b=n.frameId;let S;i[26]!==n.frameId?(S=eRt(n.frameId),i[26]=n.frameId,i[27]=S):S=i[27];let _;i[28]!==n.frameId||i[29]!==m||i[30]!==S?(_=L.jsxs("span",{style:m,className:"text-xxs text-primary font-mono flex-shrink-0 ml-2 mr-2",children:[b,"(",S,")"]}),i[28]=n.frameId,i[29]=m,i[30]=S,i[31]=_):_=i[31];let C;i[32]===Symbol.for("react.memo_cache_sentinel")?(C=L.jsx("div",{className:"w-1 flex-shrink-0"}),i[32]=C):C=i[32];let P;i[33]!==s.name?(P={width:s.name},i[33]=s.name,i[34]=P):P=i[34];let x;i[35]!==n.frameName||i[36]!==P?(x=L.jsx("span",{style:P,className:"text-xxs text-foreground truncate flex-shrink-0 ml-2 mr-2",title:n.frameName,children:n.frameName}),i[35]=n.frameName,i[36]=P,i[37]=x):x=i[37];let E;i[38]===Symbol.for("react.memo_cache_sentinel")?(E=L.jsx("div",{className:"w-1 flex-shrink-0"}),i[38]=E):E=i[38];let A;i[39]!==s.rawData?(A={width:s.rawData},i[39]=s.rawData,i[40]=A):A=i[40];let R;i[41]!==n.rawHex||i[42]!==A?(R=L.jsx("span",{style:A,className:"text-xxs text-muted-foreground font-mono truncate flex-shrink-0 ml-2",title:n.rawHex,children:n.rawHex}),i[41]=n.rawHex,i[42]=A,i[43]=R):R=i[43];let M;return i[44]!==_||i[45]!==x||i[46]!==R||i[47]!==c||i[48]!==h||i[49]!==v||i[50]!==y?(M=L.jsxs("div",{className:u,onClick:c,children:[h,v,y,_,C,x,E,R]}),i[44]=_,i[45]=x,i[46]=R,i[47]=c,i[48]=h,i[49]=v,i[50]=y,i[51]=M):M=i[51],M}),M4=t=>{const e=qt.c(7),{onResize:i}=t,[n,r]=J.useState(!1),o=J.useRef(0);let a;e[0]!==i?(a=d=>{d.preventDefault(),d.stopPropagation(),r(!0),o.current=d.clientX;const f=p=>{const g=p.clientX-o.current;o.current=p.clientX,i(g)},h=()=>{r(!1),document.removeEventListener("mousemove",f),document.removeEventListener("mouseup",h),document.body.style.cursor="",document.body.style.userSelect=""};document.addEventListener("mousemove",f),document.addEventListener("mouseup",h),document.body.style.cursor="col-resize",document.body.style.userSelect="none"},e[0]=i,e[1]=a):a=e[1];const s=a,l=n&&"bg-blue-500";let u;e[2]!==l?(u=Hr("w-1 h-5 cursor-col-resize hover:bg-blue-500/50 transition-colors flex-shrink-0",l),e[2]=l,e[3]=u):u=e[3];let c;return e[4]!==s||e[5]!==u?(c=L.jsx("div",{title:"Resize column",className:u,onMouseDown:s}),e[4]=s,e[5]=u,e[6]=c):c=e[6],c},rRt=J.memo(function(e){const i=qt.c(30),{columnWidths:n,groupByFrame:r,onResizeColumn:o}=e;let a;i[0]!==n.chevron?(a=L.jsx("span",{style:{width:n.chevron},className:"flex-shrink-0"}),i[0]=n.chevron,i[1]=a):a=i[1];let s;i[2]!==n.timestamp?(s=L.jsx("span",{style:{width:n.timestamp},className:"flex-shrink-0 mr-2",children:"Timestamp"}),i[2]=n.timestamp,i[3]=s):s=i[3];let l;i[4]!==o?(l=L.jsx(M4,{onResize:v=>o("timestamp",v)}),i[4]=o,i[5]=l):l=i[5];let u;i[6]!==n.delta||i[7]!==r||i[8]!==o?(u=!r&&L.jsxs(L.Fragment,{children:[L.jsx("span",{style:{width:n.delta},className:"flex-shrink-0 ml-2 mr-2",children:"Delta"}),L.jsx(M4,{onResize:v=>o("delta",v)})]}),i[6]=n.delta,i[7]=r,i[8]=o,i[9]=u):u=i[9];let c;i[10]!==n.frameId?(c=L.jsx("span",{style:{width:n.frameId},className:"flex-shrink-0 ml-2 mr-2",children:"Frame ID"}),i[10]=n.frameId,i[11]=c):c=i[11];let d;i[12]!==o?(d=L.jsx(M4,{onResize:v=>o("frameId",v)}),i[12]=o,i[13]=d):d=i[13];let f;i[14]!==n.name?(f=L.jsx("span",{style:{width:n.name},className:"flex-shrink-0 ml-2 mr-2",children:"Name"}),i[14]=n.name,i[15]=f):f=i[15];let h;i[16]!==o?(h=L.jsx(M4,{onResize:v=>o("name",v)}),i[16]=o,i[17]=h):h=i[17];let p;i[18]!==n.rawData?(p=L.jsx("span",{style:{width:n.rawData},className:"flex-shrink-0 ml-2",children:"Raw Data"}),i[18]=n.rawData,i[19]=p):p=i[19];let g;return i[20]!==a||i[21]!==s||i[22]!==l||i[23]!==u||i[24]!==c||i[25]!==d||i[26]!==f||i[27]!==h||i[28]!==p?(g=L.jsxs("div",{className:"flex sticky min-w-fit z-10 top-0 items-center px-2 py-1 bg-muted border-b border-border text-xxs text-muted-foreground uppercase tracking-wider",children:[a,s,l,u,c,d,f,h,p]}),i[20]=a,i[21]=s,i[22]=l,i[23]=u,i[24]=c,i[25]=d,i[26]=f,i[27]=h,i[28]=p,i[29]=g):g=i[29],g}),iRt=L.jsxs("div",{className:"max-w-md space-y-1",children:[L.jsx("p",{className:"text-sm font-semibold",children:"Trace"}),L.jsxs("p",{className:"text-xs",children:[L.jsx("span",{className:"font-bold",children:"Settings"}),":"]}),L.jsxs("p",{className:"text-xs ms-2",children:[L.jsx("span",{className:"font-semibold",children:"Buffer size"}),": Max number of entries (circular buffer)",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Sort order"}),": Newest-first or oldest-first",L.jsx("br",{}),L.jsx("span",{className:"font-semibold",children:"Group by frame"}),": Show one row per frame (latest entry)"]})]}),nRt=J.memo(function(e){const i=qt.c(23),{isPaused:n,onTogglePause:r,panelConfig:o,onToggleExpandAll:a,statusRef:s,dropdown:l}=e,u=o.expandSignals;let c;i[0]===Symbol.for("react.memo_cache_sentinel")?(c=L.jsx("span",{className:"text-xs font-sm",children:"Trace"}),i[0]=c):c=i[0];let d;i[1]!==s?(d=L.jsx("div",{children:L.jsxs("div",{className:"flex items-center gap-2",children:[c,L.jsx("span",{ref:s,className:"text-xxs text-muted-foreground bg-muted px-1.5 py-0.5 rounded whitespace-nowrap"})]})}),i[1]=s,i[2]=d):d=i[2];const f=n?dr.MEDIA_PLAY:dr.MEDIA_PAUSE,h=n?"Resume":"Pause",p=n?fn.PANEL_BUTTON_ACTIVE:fn.PANEL_BUTTON;let g;i[3]!==r||i[4]!==f||i[5]!==h||i[6]!==p?(g=L.jsx(Za,{icon:f,label:h,type:p,size:_a.XS,onClick:r}),i[3]=r,i[4]=f,i[5]=h,i[6]=p,i[7]=g):g=i[7];const v=u?dr.NAV_CHEVRON_DOWN:dr.NAV_CHEVRON_RIGHT,y=u?"Collapse All":"Expand All",m=u?"Collapse all signals":"Expand all signals",b=u?fn.PANEL_BUTTON_ACTIVE:fn.PANEL_BUTTON;let S;i[8]!==a||i[9]!==b||i[10]!==v||i[11]!==y||i[12]!==m?(S=L.jsx(Za,{icon:v,label:y,title:m,type:b,size:_a.XS,onClick:a}),i[8]=a,i[9]=b,i[10]=v,i[11]=y,i[12]=m,i[13]=S):S=i[13];let _;i[14]!==S||i[15]!==g?(_=L.jsxs("div",{className:"flex gap-2 mr-2",children:[g,S]}),i[14]=S,i[15]=g,i[16]=_):_=i[16];let C;i[17]!==_||i[18]!==d?(C=L.jsxs("div",{className:"flex w-full justify-between items-center",children:[d,_]}),i[17]=_,i[18]=d,i[19]=C):C=i[19];let P;return i[20]!==l||i[21]!==C?(P=L.jsx(GI,{icon:dr.DATA_TRACE,dropdown:l,helpTooltip:iRt,children:C}),i[20]=l,i[21]=C,i[22]=P):P=i[22],P}),oRt={chevron:12,timestamp:100,delta:64,frameId:56,name:140,rawData:200},aRt={chevron:12,timestamp:80,delta:50,frameId:50,name:80,rawData:100};function sRt(){const t=qt.c(3),[e,i]=J.useState(oRt);let n;t[0]===Symbol.for("react.memo_cache_sentinel")?(n=(a,s)=>{i(l=>{const u=Math.max(aRt[a],l[a]+s);return{...l,[a]:u}})},t[0]=n):n=t[0];const r=n;let o;return t[1]!==e?(o={columnWidths:e,handleResizeColumn:r},t[1]=e,t[2]=o):o=t[2],o}class lRt{constructor(e){Go(this,"buffer");Go(this,"head",0);Go(this,"tail",0);Go(this,"count",0);Go(this,"capacity");this.capacity=e,this.buffer=new Array(e)}push(e){this.buffer[this.tail]=e,this.tail=(this.tail+1)%this.capacity,this.count<this.capacity?this.count++:this.head=(this.head+1)%this.capacity}toArray(){const e=[];for(let i=0;i<this.count;i++)e.push(this.buffer[(this.head+i)%this.capacity]);return e}clear(){this.head=0,this.tail=0,this.count=0}get length(){return this.count}resize(e){const i=this.toArray();this.capacity=e,this.buffer=new Array(e),this.head=0,this.tail=0,this.count=0;const n=Math.max(0,i.length-e);for(let r=n;r<i.length;r++)this.push(i[r])}}const d1e=t=>`${t.namespace}:${t.name}`;function uRt(t){const e=qt.c(44),{bufferSize:i,isPaused:n,expandAllSignals:r,groupByFrame:o,sortOrder:a,signalMetaLookup:s,selectedFrames:l,setExpandedEntries:u}=t;let c;e[0]!==i?(c=new lRt(i),e[0]=i,e[1]=c):c=e[1];const d=J.useRef(c);let f;e[2]===Symbol.for("react.memo_cache_sentinel")?(f=[],e[2]=f):f=e[2];const h=J.useRef(f),p=J.useRef(0);let g;e[3]===Symbol.for("react.memo_cache_sentinel")?(g=new Map,e[3]=g):g=e[3];const v=J.useRef(g);let y;e[4]===Symbol.for("react.memo_cache_sentinel")?(y=[],e[4]=y):y=e[4];const[m,b]=J.useState(y);let S;e[5]!==s?(S=(W,Y)=>{const te=W.signals.map(oe=>{const de=s.get(d1e(oe));return{name:oe.name,value:oe.value,formattedValue:c1e(oe.value,de==null?void 0:de.namedValues),unit:(de==null?void 0:de.unit)||""}});return p.current=p.current+1,{id:p.current,frameName:W.name||Y.name,namespace:Y.namespace||"",frameId:Y.frameId,timestampUs:W.timestampUs,rawHex:u1e(W.value),cycleTime:Y.cycleTime,signals:te}},e[5]=s,e[6]=S):S=e[6];const _=J.useEffectEvent(S);let C;e[7]!==o||e[8]!==a?(C=()=>{const W=o?Array.from(v.current.values()):d.current.toArray(),Y=o?[...W].sort(dRt):a==="newest-first"?[...W].reverse():W;b(Y)},e[7]=o,e[8]=a,e[9]=C):C=e[9];const P=J.useEffectEvent(C);let x;e[10]!==i||e[11]!==P?(x=()=>{d.current.resize(i),P()},e[10]=i,e[11]=P,e[12]=x):x=e[12];let E;e[13]!==i?(E=[i],e[13]=i,e[14]=E):E=e[14],J.useEffect(x,E);let A,R;e[15]!==o||e[16]!==l?(R=()=>{if(!o)return;const W=new Set(l.map(cRt));v.current.forEach((Y,te)=>{W.has(te)||v.current.delete(te)})},A=[l,o],e[15]=o,e[16]=l,e[17]=A,e[18]=R):(A=e[17],R=e[18]),J.useEffect(R,A);let M;e[19]!==P||e[20]!==_||e[21]!==r||e[22]!==o||e[23]!==n||e[24]!==u||e[25]!==s?(M=()=>{const W=h.current;if(!(W.length===0||n))if(o){const Y=new Set,te=[];for(const{frame:oe,metadata:de}of W){const ge=`${oe.name}:${oe.timestampUs}`;if(!Y.has(ge)){Y.add(ge);const Ee=de.longName(),Re=v.current.get(Ee);if(Re){const Ae={...Re,timestampUs:oe.timestampUs,rawHex:u1e(oe.value),signals:oe.signals.map(Pe=>{const we=s.get(d1e(Pe));return{name:Pe.name,value:Pe.value,formattedValue:c1e(Pe.value,we==null?void 0:we.namedValues),unit:(we==null?void 0:we.unit)||""}})};v.current.set(Ee,Ae),d.current.push(_(oe,de))}else{const Ae=_(oe,de);v.current.set(Ee,Ae),d.current.push(Ae),te.push(Ae.id)}}}h.current=[],P(),r&&te.length>0&&u(oe=>{const de=new Set(oe);return te.forEach(ge=>de.add(ge)),de})}else{const Y=new Set,te=[];for(const{frame:oe,metadata:de}of W){const ge=`${oe.name}:${oe.timestampUs}`;if(!Y.has(ge)){Y.add(ge);const Ee=_(oe,de);d.current.push(Ee),te.push(Ee.id)}}h.current=[],P(),r&&te.length>0&&u(oe=>{const de=new Set(oe);return te.forEach(ge=>de.add(ge)),de})}},e[19]=P,e[20]=_,e[21]=r,e[22]=o,e[23]=n,e[24]=u,e[25]=s,e[26]=M):M=e[26];const D=J.useEffectEvent(M);let F;e[27]!==D?(F=()=>{const W=setInterval(D,100);return()=>clearInterval(W)},e[27]=D,e[28]=F):F=e[28];let I;e[29]===Symbol.for("react.memo_cache_sentinel")?(I=[],e[29]=I):I=e[29],J.useEffect(F,I);let V;e[30]!==P?(V=()=>{P()},e[30]=P,e[31]=V):V=e[31];let z;e[32]!==a?(z=[a],e[32]=a,e[33]=z):z=e[33],J.useEffect(V,z);let G;e[34]!==P||e[35]!==o?(G=()=>{if(o){const W=new Map;for(const Y of d.current.toArray()){const te=`${Y.namespace}:${Y.frameName}`,oe=W.get(te);(!oe||Y.timestampUs>oe.timestampUs)&&W.set(te,Y)}v.current=W}else v.current.clear();P()},e[34]=P,e[35]=o,e[36]=G):G=e[36];let H;e[37]!==o?(H=[o],e[37]=o,e[38]=H):H=e[38],J.useEffect(G,H);let U;e[39]!==u?(U=()=>{d.current.clear(),v.current.clear(),h.current=[],u(new Set),b([])},e[39]=u,e[40]=U):U=e[40];const k=U;let X;return e[41]!==k||e[42]!==m?(X={pendingFramesRef:h,sortedEntries:m,handleClear:k},e[41]=k,e[42]=m,e[43]=X):X=e[43],X}function cRt(t){return t.longName()}function dRt(t,e){return t.frameName.localeCompare(e.frameName)}function fRt(t,e,i){const n=qt.c(8),r=$V(),o=WV();let a;n[0]===Symbol.for("react.memo_cache_sentinel")?(a=new Map,n[0]=a):a=n[0];const s=J.useRef(a);let l,u;n[1]!==o||n[2]!==i||n[3]!==r||n[4]!==t||n[5]!==e?(l=()=>{if(!r)return;const c=s.current,d=new Set(e.map(vRt)),f=[];c.forEach((p,g)=>{d.has(g)||(f.push(p),c.delete(g))}),f.length>0&&r.removeSubscriptions(f);let h=!1;return e.forEach(p=>{var C,P;const g=p.longName();if(c.has(g))return;const v=((C=i.find(x=>`${x.namespace}:${x.frame}`===p.longName()))==null?void 0:C.signals.length)??0,y=v>0?new Set(p.signals.map(gRt)):null,m=v>0?p.signals:((P=o.find(x=>x.longName()===p.longName()))==null?void 0:P.signals)??[],b=[p.id,...m.map(pRt)],S=x=>{const E=y!==null?x.signals.filter(A=>y.has(A.name)):[];t.current.push({frame:{...x,signals:E},metadata:p})},_=new B3(b,S,hRt);r.addPendingSubscription(_),c.set(g,_.subscriptionId),h=!0}),h&&r.applyPendingSubscriptions(),()=>{const p=Array.from(c.values());p.length>0&&(r.removeSubscriptions(p),c.clear())}},u=[r,e,o,i,t],n[1]=o,n[2]=i,n[3]=r,n[4]=t,n[5]=e,n[6]=l,n[7]=u):(l=n[6],u=n[7]),J.useEffect(l,u)}function hRt(){}function pRt(t){return t.id}function gRt(t){return t.name}function vRt(t){return t.longName()}function yRt(t){const e=qt.c(8),{sortedEntries:i,isPaused:n,groupByFrame:r,pendingFramesRef:o}=t,a=J.useRef(null);let s,l;e[0]!==r||e[1]!==i?(s=()=>{a.current&&(r?a.current.innerText=`${i.length.toLocaleString()} unique frames`:a.current.innerText=`${i.length.toLocaleString()} entries`)},l=[i,r],e[0]=r,e[1]=i,e[2]=s,e[3]=l):(s=e[2],l=e[3]),J.useEffect(s,l);let u,c;return e[4]!==n||e[5]!==o?(u=()=>{if(!n)return;const d=()=>{a.current&&(a.current.innerText=`Paused (${o.current.length} pending)`)};d();const f=setInterval(d,100);return()=>clearInterval(f)},c=[n,o],e[4]=n,e[5]=o,e[6]=u,e[7]=c):(u=e[6],c=e[7]),J.useEffect(u,c),a}const A7=24,mRt=18,bRt=[],SRt=t=>`${t.namespace}:${t.signal}`,_Rt=t=>`${t.namespace}:${t.frame}`;function PRt(t){const{track:e}=el(),{updatePanel:i,removePanel:n}=oC(),r=t.panelConfig,o=r.bufferSize,a=r.sortOrder,s=r.groupByFrame,l=r.expandSignals,u=J.useMemo(()=>r.frames??[],[r.frames]),c=J.useRef(null),d=WV(),[f,h]=J.useState(new Set),[p,g]=J.useState(!1),[v,y]=J.useState(!1),m=J.useMemo(()=>{const Y=new Map(u.map(te=>[_Rt(te),new Set(te.signals.map(oe=>SRt(oe)))]));return d.filter(te=>Y.has(te.longName())).map(te=>{const oe=Y.get(te.longName());return oe.size===0?{...te,signals:[]}:{...te,signals:te.signals.filter(de=>oe.has(de.longName()))}})},[u,d]),b=J.useMemo(()=>{const Y=new Map;return m.flatMap(te=>te.signals).forEach(te=>{Y.set(te.longName(),te)}),Y},[m]),{columnWidths:S,handleResizeColumn:_}=sRt(),{pendingFramesRef:C,sortedEntries:P,handleClear:x}=uRt({bufferSize:o,isPaused:p,expandAllSignals:l,groupByFrame:s,sortOrder:a,signalMetaLookup:b,selectedFrames:m,setExpandedEntries:h});fRt(C,m,u);const E=J.useRef(P);E.current=P;const A=yRt({sortedEntries:P,isPaused:p,groupByFrame:s,pendingFramesRef:C}),R=J.useCallback(Y=>{h(te=>{const oe=new Set(te);return oe.has(Y)?oe.delete(Y):oe.add(Y),oe})},[]),M=J.useCallback(()=>{const Y=!l;i(t.panelId,"trace",te=>({...te,expandSignals:Y})),h(Y?new Set(E.current.map(te=>te.id)):new Set)},[l,t.panelId,i]),D=J.useCallback(Y=>{const te=Y.map(oe=>({namespace:oe.namespace,frame:oe.name,signals:oe.signals.map(de=>({namespace:de.namespace,frame:de.frameName,signal:de.name}))}));i(t.panelId,"trace",oe=>({...oe,frames:te}))},[t.panelId,i]),F=J.useCallback(()=>g(Y=>!Y),[]),I=J.useCallback(Y=>{const te=P[Y];return te&&f.has(te.id)?A7+te.signals.length*mRt:A7},[P,f]),V=J.useCallback(Y=>{i(t.panelId,"trace",te=>({...te,bufferSize:Y})),e(Fi.ChangePanelSetting,{panelType:"trace",setting:"bufferSize",value:Y})},[t.panelId,i,e]),z=J.useCallback(Y=>{i(t.panelId,"trace",te=>({...te,sortOrder:Y})),e(Fi.ChangePanelSetting,{panelType:"trace",setting:"sortOrder",value:Y})},[t.panelId,i,e]),G=J.useCallback(Y=>{i(t.panelId,"trace",te=>({...te,groupByFrame:Y})),e(Fi.ChangePanelSetting,{panelType:"trace",setting:"groupByFrame",value:Y})},[t.panelId,i,e]),H=J.useCallback(()=>y(!0),[]),U=J.useCallback(()=>{n(t.panelId),e(Fi.RemovePanelFromDashboard,{panelType:"trace"})},[t.panelId,n,e]),k=J.useMemo(()=>L.jsx(KDt,{bufferSize:o,onBufferSizeChange:V,sortOrder:a,onSortOrderChange:z,groupByFrame:s,onGroupByFrameChange:G,onClear:x,onAddSignal:H,onRemove:U}),[o,V,a,z,s,G,x,H,U]),X=pre({count:P.length,getScrollElement:()=>c.current,estimateSize:Y=>I(Y),getItemKey:Y=>{var te;return((te=P[Y])==null?void 0:te.id)??Y},measureElement:void 0}),W=m.length>0;return L.jsxs(L.Fragment,{children:[L.jsxs(WI,{fullHeight:!0,children:[L.jsx(nRt,{panelConfig:t.panelConfig,isPaused:p,statusRef:A,onTogglePause:F,onToggleExpandAll:M,dropdown:k}),L.jsxs(YI,{fullHeight:!0,padding:!1,children:[r.unresolvedFrames&&L.jsx(u$,{signals:[],frames:r.unresolvedFrames??[],onRemoveFrame:Y=>i(t.panelId,"trace",te=>{var oe;return{...te,unresolvedFrames:(oe=te.unresolvedFrames)==null?void 0:oe.filter(de=>!(de.namespace===Y.namespace&&de.frame===Y.frame))}})}),!W&&L.jsx(rG,{icon:dr.DATA_TRACE,title:"Trace panel",description:"Select signals to view values in a table",children:L.jsx(Za,{icon:dr.ACTION_EDIT,label:"Select signals",type:fn.PRIMARY,size:_a.SM,onClick:()=>y(!0)})}),W&&L.jsx("div",{className:"flex flex-col h-full ",children:L.jsxs("div",{ref:c,className:"flex-1 overflow-y-auto",children:[L.jsx(rRt,{columnWidths:S,groupByFrame:s,onResizeColumn:_}),L.jsx("div",{className:"relative w-full",style:{height:X.getTotalSize()},children:L.jsx("ul",{className:"flex w-full relative",children:X.getVirtualItems().map(Y=>{const te=P[Y.index];if(!te)return null;const oe=a==="newest-first"?Y.index+1:Y.index-1,de=P[oe],ge=f.has(te.id),Ee=I(Y.index);return L.jsxs("li",{style:{position:"absolute",top:0,left:0,width:"100%",minWidth:"fit-content",height:Ee,transform:`translateY(${Y.start}px)`},children:[L.jsx(tRt,{entry:te,previousTimestampUs:de==null?void 0:de.timestampUs,isExpanded:ge,onToggle:R,columnWidths:S,hideDelta:s}),ge&&te.signals.map(Re=>L.jsx(XDt,{signal:Re},`${te.id}-${Re.name}`))]},te.id)})})})]})})]})]}),L.jsx(sW,{show:v,selectedSignals:bRt,selectedFrames:m,handleCloseFunction:()=>y(!1),selectEnforcedFramesFunction:D,isFramesSelectable:!0,enforceFrameSelection:!0,autoSelectParentFrame:!0,selectedFramesAsOnlySourceOfSignals:!0})]})}const CRt=J.forwardRef(function(e,i){const n=qt.c(16),{panels:r,updatePanel:o}=oC(),a=J.useRef(null);let s,l;n[0]===Symbol.for("react.memo_cache_sentinel")?(s=()=>({compact:()=>{var b;(b=a.current)==null||b.compact()}}),l=[],n[0]=s,n[1]=l):(s=n[0],l=n[1]),J.useImperativeHandle(i,s,l);const u=J.useRef(0);let c,d;n[2]!==r.length?(c=()=>{if(r.length!==u.current&&a.current){const b=setTimeout(()=>{var S;(S=a.current)==null||S.compact()},50);return u.current=r.length,()=>clearTimeout(b)}},d=[r.length],n[2]=r.length,n[3]=c,n[4]=d):(c=n[3],d=n[4]),J.useEffect(c,d);let f;n[5]!==r?(f=r.map(TRt),n[5]=r,n[6]=f):f=n[6];const h=f;let p;n[7]!==r||n[8]!==o?(p=b=>{b.forEach(S=>{const{id:_,x:C,y:P,w:x,h:E}=S,A=r.find(R=>R.id===_);A&&o(_,A.type,R=>({...R,grid:{x:C,y:P,w:x,h:E}}))})},n[7]=r,n[8]=o,n[9]=p):p=n[9];const g=p;let v;n[10]!==r?(v=b=>{const S=r.find(_=>_.id===b.id);if(!S)return null;switch(S.type){case"timeseries":return L.jsx(LDt,{panelId:S.id,panelConfig:S});case"gauge":return L.jsx(oDt,{panelId:S.id,panelConfig:S});case"frame-distribution":return L.jsx(wOt,{panelId:S.id,panelConfig:S});case"map":return L.jsx(uDt,{panelId:S.id,panelConfig:S});case"video":return L.jsx(jDt,{panelId:S.id,panelConfig:S});case"trace":return L.jsx(PRt,{panelId:S.id,panelConfig:S});default:return null}},n[10]=r,n[11]=v):v=n[11];const y=v;let m;return n[12]!==h||n[13]!==g||n[14]!==y?(m=L.jsx(GDt,{ref:a,items:h,onLayoutChange:g,renderItem:y}),n[12]=h,n[13]=g,n[14]=y,n[15]=m):m=n[15],m});function TRt(t){return{id:t.id,x:t.grid.x,y:t.grid.y,w:t.grid.w,h:t.grid.h}}const nHe="remotive-dashboard:0.1",xRt={chartWidthSeconds:30},qI={timeseries:{x:0,y:0,w:12,h:4},gauge:{x:0,y:0,w:12,h:3},map:{x:0,y:0,w:12,h:5},frameDistribution:{x:0,y:0,w:12,h:4},video:{x:0,y:0,w:12,h:5},trace:{x:0,y:0,w:12,h:5}},oHe=[nHe],O7="0.1",D7="0.1";function ERt(t){const e=t.match(/^([^:]+):(.+)$/);return e?{name:e[1],version:e[2]}:null}function f1e(t){const e=t.match(/^(\d+)\.(\d+)$/);return e?{major:parseInt(e[1],10),minor:parseInt(e[2],10)}:null}function h1e(t,e){const i=f1e(t),n=f1e(e);return!i||!n?t.localeCompare(e):i.major!==n.major?i.major-n.major:i.minor-n.minor}function wRt(t){return oHe.includes(t)}function ARt(t){if(typeof t!="object"||t===null)throw new Error("Invalid configuration: expected an object");const e=t;if(typeof e.schema=="string"){const i=e.schema;if(!wRt(i)){const n=ERt(i);throw n&&n.name==="remotive-dashboard"?h1e(n.version,D7)>0?new Error(`This dashboard was created with a newer version (${n.version}) than your application supports (${D7}). Please update Remotive Studio to load this dashboard.`):h1e(n.version,O7)<0?new Error(`This dashboard was created with an old version (${n.version}) that is no longer supported. The minimum supported version is ${O7}. Please recreate the dashboard or contact support for assistance.`):new Error(`Dashboard schema version "${n.version}" is not supported. Supported versions: ${O7} to ${D7}.`):new Error(`Unknown schema "${i}". Expected one of: ${oHe.join(", ")}`)}return e}else throw new Error("Missing or invalid schema field")}function ORt(t){const e=[];return typeof t.schema!="string"&&e.push("Missing or invalid schema field"),Array.isArray(t.panels)?t.panels.forEach((i,n)=>{typeof i!="object"||i===null?e.push(`Panel at index ${n} is not an object`):typeof i.type!="string"&&e.push(`Panel at index ${n} is missing type field`)}):e.push("Missing or invalid panels array"),e}function DRt(){return["timeseries","gauge","map","frameDistribution","video","trace"]}var L4={exports:{}},R7={},$b={},RO={},M7={},L7={},k7={},p1e;function g$(){return p1e||(p1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class e{}t._CodeOrName=e,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class i extends e{constructor(m){if(super(),!t.IDENTIFIER.test(m))throw new Error("CodeGen: name must be a valid identifier");this.str=m}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=i;class n extends e{constructor(m){super(),this._items=typeof m=="string"?[m]:m}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const m=this._items[0];return m===""||m==='""'}get str(){var m;return(m=this._str)!==null&&m!==void 0?m:this._str=this._items.reduce((b,S)=>`${b}${S}`,"")}get names(){var m;return(m=this._names)!==null&&m!==void 0?m:this._names=this._items.reduce((b,S)=>(S instanceof i&&(b[S.str]=(b[S.str]||0)+1),b),{})}}t._Code=n,t.nil=new n("");function r(y,...m){const b=[y[0]];let S=0;for(;S<m.length;)s(b,m[S]),b.push(y[++S]);return new n(b)}t._=r;const o=new n("+");function a(y,...m){const b=[h(y[0])];let S=0;for(;S<m.length;)b.push(o),s(b,m[S]),b.push(o,h(y[++S]));return l(b),new n(b)}t.str=a;function s(y,m){m instanceof n?y.push(...m._items):m instanceof i?y.push(m):y.push(d(m))}t.addCodeArg=s;function l(y){let m=1;for(;m<y.length-1;){if(y[m]===o){const b=u(y[m-1],y[m+1]);if(b!==void 0){y.splice(m-1,3,b);continue}y[m++]="+"}m++}}function u(y,m){if(m==='""')return y;if(y==='""')return m;if(typeof y=="string")return m instanceof i||y[y.length-1]!=='"'?void 0:typeof m!="string"?`${y.slice(0,-1)}${m}"`:m[0]==='"'?y.slice(0,-1)+m.slice(1):void 0;if(typeof m=="string"&&m[0]==='"'&&!(y instanceof i))return`"${y}${m.slice(1)}`}function c(y,m){return m.emptyStr()?y:y.emptyStr()?m:a`${y}${m}`}t.strConcat=c;function d(y){return typeof y=="number"||typeof y=="boolean"||y===null?y:h(Array.isArray(y)?y.join(","):y)}function f(y){return new n(h(y))}t.stringify=f;function h(y){return JSON.stringify(y).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.safeStringify=h;function p(y){return typeof y=="string"&&t.IDENTIFIER.test(y)?new n(`.${y}`):r`[${y}]`}t.getProperty=p;function g(y){if(typeof y=="string"&&t.IDENTIFIER.test(y))return new n(`${y}`);throw new Error(`CodeGen: invalid export name: ${y}, use explicit $id name mapping`)}t.getEsmExportName=g;function v(y){return new n(y.toString())}t.regexpCode=v})(k7)),k7}var I7={},g1e;function v1e(){return g1e||(g1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;const e=g$();class i extends Error{constructor(u){super(`CodeGen: "code" for ${u} not defined`),this.value=u.value}}var n;(function(l){l[l.Started=0]="Started",l[l.Completed=1]="Completed"})(n||(t.UsedValueState=n={})),t.varKinds={const:new e.Name("const"),let:new e.Name("let"),var:new e.Name("var")};class r{constructor({prefixes:u,parent:c}={}){this._names={},this._prefixes=u,this._parent=c}toName(u){return u instanceof e.Name?u:this.name(u)}name(u){return new e.Name(this._newName(u))}_newName(u){const c=this._names[u]||this._nameGroup(u);return`${u}${c.index++}`}_nameGroup(u){var c,d;if(!((d=(c=this._parent)===null||c===void 0?void 0:c._prefixes)===null||d===void 0)&&d.has(u)||this._prefixes&&!this._prefixes.has(u))throw new Error(`CodeGen: prefix "${u}" is not allowed in this scope`);return this._names[u]={prefix:u,index:0}}}t.Scope=r;class o extends e.Name{constructor(u,c){super(c),this.prefix=u}setValue(u,{property:c,itemIndex:d}){this.value=u,this.scopePath=(0,e._)`.${new e.Name(c)}[${d}]`}}t.ValueScopeName=o;const a=(0,e._)`\n`;class s extends r{constructor(u){super(u),this._values={},this._scope=u.scope,this.opts={...u,_n:u.lines?a:e.nil}}get(){return this._scope}name(u){return new o(u,this._newName(u))}value(u,c){var d;if(c.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const f=this.toName(u),{prefix:h}=f,p=(d=c.key)!==null&&d!==void 0?d:c.ref;let g=this._values[h];if(g){const m=g.get(p);if(m)return m}else g=this._values[h]=new Map;g.set(p,f);const v=this._scope[h]||(this._scope[h]=[]),y=v.length;return v[y]=c.ref,f.setValue(c,{property:h,itemIndex:y}),f}getValue(u,c){const d=this._values[u];if(d)return d.get(c)}scopeRefs(u,c=this._values){return this._reduceValues(c,d=>{if(d.scopePath===void 0)throw new Error(`CodeGen: name "${d}" has no value`);return(0,e._)`${u}${d.scopePath}`})}scopeCode(u=this._values,c,d){return this._reduceValues(u,f=>{if(f.value===void 0)throw new Error(`CodeGen: name "${f}" has no value`);return f.value.code},c,d)}_reduceValues(u,c,d={},f){let h=e.nil;for(const p in u){const g=u[p];if(!g)continue;const v=d[p]=d[p]||new Map;g.forEach(y=>{if(v.has(y))return;v.set(y,n.Started);let m=c(y);if(m){const b=this.opts.es5?t.varKinds.var:t.varKinds.const;h=(0,e._)`${h}${b} ${y} = ${m};${this.opts._n}`}else if(m=f==null?void 0:f(y))h=(0,e._)`${h}${m}${this.opts._n}`;else throw new i(y);v.set(y,n.Completed)})}return h}}t.ValueScope=s})(I7)),I7}var y1e;function _o(){return y1e||(y1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;const e=g$(),i=v1e();var n=g$();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return n.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return n.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return n.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return n.Name}});var r=v1e();Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return r.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return r.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return r.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return r.varKinds}}),t.operators={GT:new e._Code(">"),GTE:new e._Code(">="),LT:new e._Code("<"),LTE:new e._Code("<="),EQ:new e._Code("==="),NEQ:new e._Code("!=="),NOT:new e._Code("!"),OR:new e._Code("||"),AND:new e._Code("&&"),ADD:new e._Code("+")};class o{optimizeNodes(){return this}optimizeNames(Y,te){return this}}class a extends o{constructor(Y,te,oe){super(),this.varKind=Y,this.name=te,this.rhs=oe}render({es5:Y,_n:te}){const oe=Y?i.varKinds.var:this.varKind,de=this.rhs===void 0?"":` = ${this.rhs}`;return`${oe} ${this.name}${de};`+te}optimizeNames(Y,te){if(Y[this.name.str])return this.rhs&&(this.rhs=F(this.rhs,Y,te)),this}get names(){return this.rhs instanceof e._CodeOrName?this.rhs.names:{}}}class s extends o{constructor(Y,te,oe){super(),this.lhs=Y,this.rhs=te,this.sideEffects=oe}render({_n:Y}){return`${this.lhs} = ${this.rhs};`+Y}optimizeNames(Y,te){if(!(this.lhs instanceof e.Name&&!Y[this.lhs.str]&&!this.sideEffects))return this.rhs=F(this.rhs,Y,te),this}get names(){const Y=this.lhs instanceof e.Name?{}:{...this.lhs.names};return D(Y,this.rhs)}}class l extends s{constructor(Y,te,oe,de){super(Y,oe,de),this.op=te}render({_n:Y}){return`${this.lhs} ${this.op}= ${this.rhs};`+Y}}class u extends o{constructor(Y){super(),this.label=Y,this.names={}}render({_n:Y}){return`${this.label}:`+Y}}class c extends o{constructor(Y){super(),this.label=Y,this.names={}}render({_n:Y}){return`break${this.label?` ${this.label}`:""};`+Y}}class d extends o{constructor(Y){super(),this.error=Y}render({_n:Y}){return`throw ${this.error};`+Y}get names(){return this.error.names}}class f extends o{constructor(Y){super(),this.code=Y}render({_n:Y}){return`${this.code};`+Y}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(Y,te){return this.code=F(this.code,Y,te),this}get names(){return this.code instanceof e._CodeOrName?this.code.names:{}}}class h extends o{constructor(Y=[]){super(),this.nodes=Y}render(Y){return this.nodes.reduce((te,oe)=>te+oe.render(Y),"")}optimizeNodes(){const{nodes:Y}=this;let te=Y.length;for(;te--;){const oe=Y[te].optimizeNodes();Array.isArray(oe)?Y.splice(te,1,...oe):oe?Y[te]=oe:Y.splice(te,1)}return Y.length>0?this:void 0}optimizeNames(Y,te){const{nodes:oe}=this;let de=oe.length;for(;de--;){const ge=oe[de];ge.optimizeNames(Y,te)||(I(Y,ge.names),oe.splice(de,1))}return oe.length>0?this:void 0}get names(){return this.nodes.reduce((Y,te)=>M(Y,te.names),{})}}class p extends h{render(Y){return"{"+Y._n+super.render(Y)+"}"+Y._n}}class g extends h{}class v extends p{}v.kind="else";class y extends p{constructor(Y,te){super(te),this.condition=Y}render(Y){let te=`if(${this.condition})`+super.render(Y);return this.else&&(te+="else "+this.else.render(Y)),te}optimizeNodes(){super.optimizeNodes();const Y=this.condition;if(Y===!0)return this.nodes;let te=this.else;if(te){const oe=te.optimizeNodes();te=this.else=Array.isArray(oe)?new v(oe):oe}if(te)return Y===!1?te instanceof y?te:te.nodes:this.nodes.length?this:new y(V(Y),te instanceof y?[te]:te.nodes);if(!(Y===!1||!this.nodes.length))return this}optimizeNames(Y,te){var oe;if(this.else=(oe=this.else)===null||oe===void 0?void 0:oe.optimizeNames(Y,te),!!(super.optimizeNames(Y,te)||this.else))return this.condition=F(this.condition,Y,te),this}get names(){const Y=super.names;return D(Y,this.condition),this.else&&M(Y,this.else.names),Y}}y.kind="if";class m extends p{}m.kind="for";class b extends m{constructor(Y){super(),this.iteration=Y}render(Y){return`for(${this.iteration})`+super.render(Y)}optimizeNames(Y,te){if(super.optimizeNames(Y,te))return this.iteration=F(this.iteration,Y,te),this}get names(){return M(super.names,this.iteration.names)}}class S extends m{constructor(Y,te,oe,de){super(),this.varKind=Y,this.name=te,this.from=oe,this.to=de}render(Y){const te=Y.es5?i.varKinds.var:this.varKind,{name:oe,from:de,to:ge}=this;return`for(${te} ${oe}=${de}; ${oe}<${ge}; ${oe}++)`+super.render(Y)}get names(){const Y=D(super.names,this.from);return D(Y,this.to)}}class _ extends m{constructor(Y,te,oe,de){super(),this.loop=Y,this.varKind=te,this.name=oe,this.iterable=de}render(Y){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(Y)}optimizeNames(Y,te){if(super.optimizeNames(Y,te))return this.iterable=F(this.iterable,Y,te),this}get names(){return M(super.names,this.iterable.names)}}class C extends p{constructor(Y,te,oe){super(),this.name=Y,this.args=te,this.async=oe}render(Y){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(Y)}}C.kind="func";class P extends h{render(Y){return"return "+super.render(Y)}}P.kind="return";class x extends p{render(Y){let te="try"+super.render(Y);return this.catch&&(te+=this.catch.render(Y)),this.finally&&(te+=this.finally.render(Y)),te}optimizeNodes(){var Y,te;return super.optimizeNodes(),(Y=this.catch)===null||Y===void 0||Y.optimizeNodes(),(te=this.finally)===null||te===void 0||te.optimizeNodes(),this}optimizeNames(Y,te){var oe,de;return super.optimizeNames(Y,te),(oe=this.catch)===null||oe===void 0||oe.optimizeNames(Y,te),(de=this.finally)===null||de===void 0||de.optimizeNames(Y,te),this}get names(){const Y=super.names;return this.catch&&M(Y,this.catch.names),this.finally&&M(Y,this.finally.names),Y}}class E extends p{constructor(Y){super(),this.error=Y}render(Y){return`catch(${this.error})`+super.render(Y)}}E.kind="catch";class A extends p{render(Y){return"finally"+super.render(Y)}}A.kind="finally";class R{constructor(Y,te={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...te,_n:te.lines?`
`:""},this._extScope=Y,this._scope=new i.Scope({parent:Y}),this._nodes=[new g]}toString(){return this._root.render(this.opts)}name(Y){return this._scope.name(Y)}scopeName(Y){return this._extScope.name(Y)}scopeValue(Y,te){const oe=this._extScope.value(Y,te);return(this._values[oe.prefix]||(this._values[oe.prefix]=new Set)).add(oe),oe}getScopeValue(Y,te){return this._extScope.getValue(Y,te)}scopeRefs(Y){return this._extScope.scopeRefs(Y,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(Y,te,oe,de){const ge=this._scope.toName(te);return oe!==void 0&&de&&(this._constants[ge.str]=oe),this._leafNode(new a(Y,ge,oe)),ge}const(Y,te,oe){return this._def(i.varKinds.const,Y,te,oe)}let(Y,te,oe){return this._def(i.varKinds.let,Y,te,oe)}var(Y,te,oe){return this._def(i.varKinds.var,Y,te,oe)}assign(Y,te,oe){return this._leafNode(new s(Y,te,oe))}add(Y,te){return this._leafNode(new l(Y,t.operators.ADD,te))}code(Y){return typeof Y=="function"?Y():Y!==e.nil&&this._leafNode(new f(Y)),this}object(...Y){const te=["{"];for(const[oe,de]of Y)te.length>1&&te.push(","),te.push(oe),(oe!==de||this.opts.es5)&&(te.push(":"),(0,e.addCodeArg)(te,de));return te.push("}"),new e._Code(te)}if(Y,te,oe){if(this._blockNode(new y(Y)),te&&oe)this.code(te).else().code(oe).endIf();else if(te)this.code(te).endIf();else if(oe)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(Y){return this._elseNode(new y(Y))}else(){return this._elseNode(new v)}endIf(){return this._endBlockNode(y,v)}_for(Y,te){return this._blockNode(Y),te&&this.code(te).endFor(),this}for(Y,te){return this._for(new b(Y),te)}forRange(Y,te,oe,de,ge=this.opts.es5?i.varKinds.var:i.varKinds.let){const Ee=this._scope.toName(Y);return this._for(new S(ge,Ee,te,oe),()=>de(Ee))}forOf(Y,te,oe,de=i.varKinds.const){const ge=this._scope.toName(Y);if(this.opts.es5){const Ee=te instanceof e.Name?te:this.var("_arr",te);return this.forRange("_i",0,(0,e._)`${Ee}.length`,Re=>{this.var(ge,(0,e._)`${Ee}[${Re}]`),oe(ge)})}return this._for(new _("of",de,ge,te),()=>oe(ge))}forIn(Y,te,oe,de=this.opts.es5?i.varKinds.var:i.varKinds.const){if(this.opts.ownProperties)return this.forOf(Y,(0,e._)`Object.keys(${te})`,oe);const ge=this._scope.toName(Y);return this._for(new _("in",de,ge,te),()=>oe(ge))}endFor(){return this._endBlockNode(m)}label(Y){return this._leafNode(new u(Y))}break(Y){return this._leafNode(new c(Y))}return(Y){const te=new P;if(this._blockNode(te),this.code(Y),te.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(P)}try(Y,te,oe){if(!te&&!oe)throw new Error('CodeGen: "try" without "catch" and "finally"');const de=new x;if(this._blockNode(de),this.code(Y),te){const ge=this.name("e");this._currNode=de.catch=new E(ge),te(ge)}return oe&&(this._currNode=de.finally=new A,this.code(oe)),this._endBlockNode(E,A)}throw(Y){return this._leafNode(new d(Y))}block(Y,te){return this._blockStarts.push(this._nodes.length),Y&&this.code(Y).endBlock(te),this}endBlock(Y){const te=this._blockStarts.pop();if(te===void 0)throw new Error("CodeGen: not in self-balancing block");const oe=this._nodes.length-te;if(oe<0||Y!==void 0&&oe!==Y)throw new Error(`CodeGen: wrong number of nodes: ${oe} vs ${Y} expected`);return this._nodes.length=te,this}func(Y,te=e.nil,oe,de){return this._blockNode(new C(Y,te,oe)),de&&this.code(de).endFunc(),this}endFunc(){return this._endBlockNode(C)}optimize(Y=1){for(;Y-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(Y){return this._currNode.nodes.push(Y),this}_blockNode(Y){this._currNode.nodes.push(Y),this._nodes.push(Y)}_endBlockNode(Y,te){const oe=this._currNode;if(oe instanceof Y||te&&oe instanceof te)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${te?`${Y.kind}/${te.kind}`:Y.kind}"`)}_elseNode(Y){const te=this._currNode;if(!(te instanceof y))throw new Error('CodeGen: "else" without "if"');return this._currNode=te.else=Y,this}get _root(){return this._nodes[0]}get _currNode(){const Y=this._nodes;return Y[Y.length-1]}set _currNode(Y){const te=this._nodes;te[te.length-1]=Y}}t.CodeGen=R;function M(W,Y){for(const te in Y)W[te]=(W[te]||0)+(Y[te]||0);return W}function D(W,Y){return Y instanceof e._CodeOrName?M(W,Y.names):W}function F(W,Y,te){if(W instanceof e.Name)return oe(W);if(!de(W))return W;return new e._Code(W._items.reduce((ge,Ee)=>(Ee instanceof e.Name&&(Ee=oe(Ee)),Ee instanceof e._Code?ge.push(...Ee._items):ge.push(Ee),ge),[]));function oe(ge){const Ee=te[ge.str];return Ee===void 0||Y[ge.str]!==1?ge:(delete Y[ge.str],Ee)}function de(ge){return ge instanceof e._Code&&ge._items.some(Ee=>Ee instanceof e.Name&&Y[Ee.str]===1&&te[Ee.str]!==void 0)}}function I(W,Y){for(const te in Y)W[te]=(W[te]||0)-(Y[te]||0)}function V(W){return typeof W=="boolean"||typeof W=="number"||W===null?!W:(0,e._)`!${X(W)}`}t.not=V;const z=k(t.operators.AND);function G(...W){return W.reduce(z)}t.and=G;const H=k(t.operators.OR);function U(...W){return W.reduce(H)}t.or=U;function k(W){return(Y,te)=>Y===e.nil?te:te===e.nil?Y:(0,e._)`${X(Y)} ${W} ${X(te)}`}function X(W){return W instanceof e.Name?W:(0,e._)`(${W})`}})(L7)),L7}var oo={},m1e;function qo(){if(m1e)return oo;m1e=1,Object.defineProperty(oo,"__esModule",{value:!0}),oo.checkStrictMode=oo.getErrorPath=oo.Type=oo.useFunc=oo.setEvaluated=oo.evaluatedPropsToName=oo.mergeEvaluated=oo.eachItem=oo.unescapeJsonPointer=oo.escapeJsonPointer=oo.escapeFragment=oo.unescapeFragment=oo.schemaRefOrVal=oo.schemaHasRulesButRef=oo.schemaHasRules=oo.checkUnknownRules=oo.alwaysValidSchema=oo.toHash=void 0;const t=_o(),e=g$();function i(_){const C={};for(const P of _)C[P]=!0;return C}oo.toHash=i;function n(_,C){return typeof C=="boolean"?C:Object.keys(C).length===0?!0:(r(_,C),!o(C,_.self.RULES.all))}oo.alwaysValidSchema=n;function r(_,C=_.schema){const{opts:P,self:x}=_;if(!P.strictSchema||typeof C=="boolean")return;const E=x.RULES.keywords;for(const A in C)E[A]||S(_,`unknown keyword: "${A}"`)}oo.checkUnknownRules=r;function o(_,C){if(typeof _=="boolean")return!_;for(const P in _)if(C[P])return!0;return!1}oo.schemaHasRules=o;function a(_,C){if(typeof _=="boolean")return!_;for(const P in _)if(P!=="$ref"&&C.all[P])return!0;return!1}oo.schemaHasRulesButRef=a;function s({topSchemaRef:_,schemaPath:C},P,x,E){if(!E){if(typeof P=="number"||typeof P=="boolean")return P;if(typeof P=="string")return(0,t._)`${P}`}return(0,t._)`${_}${C}${(0,t.getProperty)(x)}`}oo.schemaRefOrVal=s;function l(_){return d(decodeURIComponent(_))}oo.unescapeFragment=l;function u(_){return encodeURIComponent(c(_))}oo.escapeFragment=u;function c(_){return typeof _=="number"?`${_}`:_.replace(/~/g,"~0").replace(/\//g,"~1")}oo.escapeJsonPointer=c;function d(_){return _.replace(/~1/g,"/").replace(/~0/g,"~")}oo.unescapeJsonPointer=d;function f(_,C){if(Array.isArray(_))for(const P of _)C(P);else C(_)}oo.eachItem=f;function h({mergeNames:_,mergeToName:C,mergeValues:P,resultToName:x}){return(E,A,R,M)=>{const D=R===void 0?A:R instanceof t.Name?(A instanceof t.Name?_(E,A,R):C(E,A,R),R):A instanceof t.Name?(C(E,R,A),A):P(A,R);return M===t.Name&&!(D instanceof t.Name)?x(E,D):D}}oo.mergeEvaluated={props:h({mergeNames:(_,C,P)=>_.if((0,t._)`${P} !== true && ${C} !== undefined`,()=>{_.if((0,t._)`${C} === true`,()=>_.assign(P,!0),()=>_.assign(P,(0,t._)`${P} || {}`).code((0,t._)`Object.assign(${P}, ${C})`))}),mergeToName:(_,C,P)=>_.if((0,t._)`${P} !== true`,()=>{C===!0?_.assign(P,!0):(_.assign(P,(0,t._)`${P} || {}`),g(_,P,C))}),mergeValues:(_,C)=>_===!0?!0:{..._,...C},resultToName:p}),items:h({mergeNames:(_,C,P)=>_.if((0,t._)`${P} !== true && ${C} !== undefined`,()=>_.assign(P,(0,t._)`${C} === true ? true : ${P} > ${C} ? ${P} : ${C}`)),mergeToName:(_,C,P)=>_.if((0,t._)`${P} !== true`,()=>_.assign(P,C===!0?!0:(0,t._)`${P} > ${C} ? ${P} : ${C}`)),mergeValues:(_,C)=>_===!0?!0:Math.max(_,C),resultToName:(_,C)=>_.var("items",C)})};function p(_,C){if(C===!0)return _.var("props",!0);const P=_.var("props",(0,t._)`{}`);return C!==void 0&&g(_,P,C),P}oo.evaluatedPropsToName=p;function g(_,C,P){Object.keys(P).forEach(x=>_.assign((0,t._)`${C}${(0,t.getProperty)(x)}`,!0))}oo.setEvaluated=g;const v={};function y(_,C){return _.scopeValue("func",{ref:C,code:v[C.code]||(v[C.code]=new e._Code(C.code))})}oo.useFunc=y;var m;(function(_){_[_.Num=0]="Num",_[_.Str=1]="Str"})(m||(oo.Type=m={}));function b(_,C,P){if(_ instanceof t.Name){const x=C===m.Num;return P?x?(0,t._)`"[" + ${_} + "]"`:(0,t._)`"['" + ${_} + "']"`:x?(0,t._)`"/" + ${_}`:(0,t._)`"/" + ${_}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return P?(0,t.getProperty)(_).toString():"/"+c(_)}oo.getErrorPath=b;function S(_,C,P=_.opts.strictSchema){if(P){if(C=`strict mode: ${C}`,P===!0)throw new Error(C);_.self.logger.warn(C)}}return oo.checkStrictMode=S,oo}var k4={},b1e;function aC(){if(b1e)return k4;b1e=1,Object.defineProperty(k4,"__esModule",{value:!0});const t=_o(),e={data:new t.Name("data"),valCxt:new t.Name("valCxt"),instancePath:new t.Name("instancePath"),parentData:new t.Name("parentData"),parentDataProperty:new t.Name("parentDataProperty"),rootData:new t.Name("rootData"),dynamicAnchors:new t.Name("dynamicAnchors"),vErrors:new t.Name("vErrors"),errors:new t.Name("errors"),this:new t.Name("this"),self:new t.Name("self"),scope:new t.Name("scope"),json:new t.Name("json"),jsonPos:new t.Name("jsonPos"),jsonLen:new t.Name("jsonLen"),jsonPart:new t.Name("jsonPart")};return k4.default=e,k4}var S1e;function nG(){return S1e||(S1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;const e=_o(),i=qo(),n=aC();t.keywordError={message:({keyword:v})=>(0,e.str)`must pass "${v}" keyword validation`},t.keyword$DataError={message:({keyword:v,schemaType:y})=>y?(0,e.str)`"${v}" keyword must be ${y} ($data)`:(0,e.str)`"${v}" keyword is invalid ($data)`};function r(v,y=t.keywordError,m,b){const{it:S}=v,{gen:_,compositeRule:C,allErrors:P}=S,x=d(v,y,m);b??(C||P)?l(_,x):u(S,(0,e._)`[${x}]`)}t.reportError=r;function o(v,y=t.keywordError,m){const{it:b}=v,{gen:S,compositeRule:_,allErrors:C}=b,P=d(v,y,m);l(S,P),_||C||u(b,n.default.vErrors)}t.reportExtraError=o;function a(v,y){v.assign(n.default.errors,y),v.if((0,e._)`${n.default.vErrors} !== null`,()=>v.if(y,()=>v.assign((0,e._)`${n.default.vErrors}.length`,y),()=>v.assign(n.default.vErrors,null)))}t.resetErrorsCount=a;function s({gen:v,keyword:y,schemaValue:m,data:b,errsCount:S,it:_}){if(S===void 0)throw new Error("ajv implementation error");const C=v.name("err");v.forRange("i",S,n.default.errors,P=>{v.const(C,(0,e._)`${n.default.vErrors}[${P}]`),v.if((0,e._)`${C}.instancePath === undefined`,()=>v.assign((0,e._)`${C}.instancePath`,(0,e.strConcat)(n.default.instancePath,_.errorPath))),v.assign((0,e._)`${C}.schemaPath`,(0,e.str)`${_.errSchemaPath}/${y}`),_.opts.verbose&&(v.assign((0,e._)`${C}.schema`,m),v.assign((0,e._)`${C}.data`,b))})}t.extendErrors=s;function l(v,y){const m=v.const("err",y);v.if((0,e._)`${n.default.vErrors} === null`,()=>v.assign(n.default.vErrors,(0,e._)`[${m}]`),(0,e._)`${n.default.vErrors}.push(${m})`),v.code((0,e._)`${n.default.errors}++`)}function u(v,y){const{gen:m,validateName:b,schemaEnv:S}=v;S.$async?m.throw((0,e._)`new ${v.ValidationError}(${y})`):(m.assign((0,e._)`${b}.errors`,y),m.return(!1))}const c={keyword:new e.Name("keyword"),schemaPath:new e.Name("schemaPath"),params:new e.Name("params"),propertyName:new e.Name("propertyName"),message:new e.Name("message"),schema:new e.Name("schema"),parentSchema:new e.Name("parentSchema")};function d(v,y,m){const{createErrors:b}=v.it;return b===!1?(0,e._)`{}`:f(v,y,m)}function f(v,y,m={}){const{gen:b,it:S}=v,_=[h(S,m),p(v,m)];return g(v,y,_),b.object(..._)}function h({errorPath:v},{instancePath:y}){const m=y?(0,e.str)`${v}${(0,i.getErrorPath)(y,i.Type.Str)}`:v;return[n.default.instancePath,(0,e.strConcat)(n.default.instancePath,m)]}function p({keyword:v,it:{errSchemaPath:y}},{schemaPath:m,parentSchema:b}){let S=b?y:(0,e.str)`${y}/${v}`;return m&&(S=(0,e.str)`${S}${(0,i.getErrorPath)(m,i.Type.Str)}`),[c.schemaPath,S]}function g(v,{params:y,message:m},b){const{keyword:S,data:_,schemaValue:C,it:P}=v,{opts:x,propertyName:E,topSchemaRef:A,schemaPath:R}=P;b.push([c.keyword,S],[c.params,typeof y=="function"?y(v):y||(0,e._)`{}`]),x.messages&&b.push([c.message,typeof m=="function"?m(v):m]),x.verbose&&b.push([c.schema,C],[c.parentSchema,(0,e._)`${A}${R}`],[n.default.data,_]),E&&b.push([c.propertyName,E])}})(M7)),M7}var _1e;function RRt(){if(_1e)return RO;_1e=1,Object.defineProperty(RO,"__esModule",{value:!0}),RO.boolOrEmptySchema=RO.topBoolOrEmptySchema=void 0;const t=nG(),e=_o(),i=aC(),n={message:"boolean schema is false"};function r(s){const{gen:l,schema:u,validateName:c}=s;u===!1?a(s,!1):typeof u=="object"&&u.$async===!0?l.return(i.default.data):(l.assign((0,e._)`${c}.errors`,null),l.return(!0))}RO.topBoolOrEmptySchema=r;function o(s,l){const{gen:u,schema:c}=s;c===!1?(u.var(l,!1),a(s)):u.var(l,!0)}RO.boolOrEmptySchema=o;function a(s,l){const{gen:u,data:c}=s,d={gen:u,keyword:"false schema",data:c,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:s};(0,t.reportError)(d,n,void 0,l)}return RO}var ed={},MO={},P1e;function aHe(){if(P1e)return MO;P1e=1,Object.defineProperty(MO,"__esModule",{value:!0}),MO.getRules=MO.isJSONType=void 0;const t=["string","number","integer","boolean","null","object","array"],e=new Set(t);function i(r){return typeof r=="string"&&e.has(r)}MO.isJSONType=i;function n(){const r={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...r,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},r.number,r.string,r.array,r.object],post:{rules:[]},all:{},keywords:{}}}return MO.getRules=n,MO}var Wb={},C1e;function sHe(){if(C1e)return Wb;C1e=1,Object.defineProperty(Wb,"__esModule",{value:!0}),Wb.shouldUseRule=Wb.shouldUseGroup=Wb.schemaHasRulesForType=void 0;function t({schema:n,self:r},o){const a=r.RULES.types[o];return a&&a!==!0&&e(n,a)}Wb.schemaHasRulesForType=t;function e(n,r){return r.rules.some(o=>i(n,o))}Wb.shouldUseGroup=e;function i(n,r){var o;return n[r.keyword]!==void 0||((o=r.definition.implements)===null||o===void 0?void 0:o.some(a=>n[a]!==void 0))}return Wb.shouldUseRule=i,Wb}var T1e;function v$(){if(T1e)return ed;T1e=1,Object.defineProperty(ed,"__esModule",{value:!0}),ed.reportTypeError=ed.checkDataTypes=ed.checkDataType=ed.coerceAndCheckDataType=ed.getJSONTypes=ed.getSchemaTypes=ed.DataType=void 0;const t=aHe(),e=sHe(),i=nG(),n=_o(),r=qo();var o;(function(m){m[m.Correct=0]="Correct",m[m.Wrong=1]="Wrong"})(o||(ed.DataType=o={}));function a(m){const b=s(m.type);if(b.includes("null")){if(m.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!b.length&&m.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');m.nullable===!0&&b.push("null")}return b}ed.getSchemaTypes=a;function s(m){const b=Array.isArray(m)?m:m?[m]:[];if(b.every(t.isJSONType))return b;throw new Error("type must be JSONType or JSONType[]: "+b.join(","))}ed.getJSONTypes=s;function l(m,b){const{gen:S,data:_,opts:C}=m,P=c(b,C.coerceTypes),x=b.length>0&&!(P.length===0&&b.length===1&&(0,e.schemaHasRulesForType)(m,b[0]));if(x){const E=p(b,_,C.strictNumbers,o.Wrong);S.if(E,()=>{P.length?d(m,b,P):v(m)})}return x}ed.coerceAndCheckDataType=l;const u=new Set(["string","number","integer","boolean","null"]);function c(m,b){return b?m.filter(S=>u.has(S)||b==="array"&&S==="array"):[]}function d(m,b,S){const{gen:_,data:C,opts:P}=m,x=_.let("dataType",(0,n._)`typeof ${C}`),E=_.let("coerced",(0,n._)`undefined`);P.coerceTypes==="array"&&_.if((0,n._)`${x} == 'object' && Array.isArray(${C}) && ${C}.length == 1`,()=>_.assign(C,(0,n._)`${C}[0]`).assign(x,(0,n._)`typeof ${C}`).if(p(b,C,P.strictNumbers),()=>_.assign(E,C))),_.if((0,n._)`${E} !== undefined`);for(const R of S)(u.has(R)||R==="array"&&P.coerceTypes==="array")&&A(R);_.else(),v(m),_.endIf(),_.if((0,n._)`${E} !== undefined`,()=>{_.assign(C,E),f(m,E)});function A(R){switch(R){case"string":_.elseIf((0,n._)`${x} == "number" || ${x} == "boolean"`).assign(E,(0,n._)`"" + ${C}`).elseIf((0,n._)`${C} === null`).assign(E,(0,n._)`""`);return;case"number":_.elseIf((0,n._)`${x} == "boolean" || ${C} === null
              || (${x} == "string" && ${C} && ${C} == +${C})`).assign(E,(0,n._)`+${C}`);return;case"integer":_.elseIf((0,n._)`${x} === "boolean" || ${C} === null
              || (${x} === "string" && ${C} && ${C} == +${C} && !(${C} % 1))`).assign(E,(0,n._)`+${C}`);return;case"boolean":_.elseIf((0,n._)`${C} === "false" || ${C} === 0 || ${C} === null`).assign(E,!1).elseIf((0,n._)`${C} === "true" || ${C} === 1`).assign(E,!0);return;case"null":_.elseIf((0,n._)`${C} === "" || ${C} === 0 || ${C} === false`),_.assign(E,null);return;case"array":_.elseIf((0,n._)`${x} === "string" || ${x} === "number"
              || ${x} === "boolean" || ${C} === null`).assign(E,(0,n._)`[${C}]`)}}}function f({gen:m,parentData:b,parentDataProperty:S},_){m.if((0,n._)`${b} !== undefined`,()=>m.assign((0,n._)`${b}[${S}]`,_))}function h(m,b,S,_=o.Correct){const C=_===o.Correct?n.operators.EQ:n.operators.NEQ;let P;switch(m){case"null":return(0,n._)`${b} ${C} null`;case"array":P=(0,n._)`Array.isArray(${b})`;break;case"object":P=(0,n._)`${b} && typeof ${b} == "object" && !Array.isArray(${b})`;break;case"integer":P=x((0,n._)`!(${b} % 1) && !isNaN(${b})`);break;case"number":P=x();break;default:return(0,n._)`typeof ${b} ${C} ${m}`}return _===o.Correct?P:(0,n.not)(P);function x(E=n.nil){return(0,n.and)((0,n._)`typeof ${b} == "number"`,E,S?(0,n._)`isFinite(${b})`:n.nil)}}ed.checkDataType=h;function p(m,b,S,_){if(m.length===1)return h(m[0],b,S,_);let C;const P=(0,r.toHash)(m);if(P.array&&P.object){const x=(0,n._)`typeof ${b} != "object"`;C=P.null?x:(0,n._)`!${b} || ${x}`,delete P.null,delete P.array,delete P.object}else C=n.nil;P.number&&delete P.integer;for(const x in P)C=(0,n.and)(C,h(x,b,S,_));return C}ed.checkDataTypes=p;const g={message:({schema:m})=>`must be ${m}`,params:({schema:m,schemaValue:b})=>typeof m=="string"?(0,n._)`{type: ${m}}`:(0,n._)`{type: ${b}}`};function v(m){const b=y(m);(0,i.reportError)(b,g)}ed.reportTypeError=v;function y(m){const{gen:b,data:S,schema:_}=m,C=(0,r.schemaRefOrVal)(m,_,"type");return{gen:b,keyword:"type",data:S,schema:_.type,schemaCode:C,schemaValue:C,parentSchema:_,params:{},it:m}}return ed}var ZB={},x1e;function MRt(){if(x1e)return ZB;x1e=1,Object.defineProperty(ZB,"__esModule",{value:!0}),ZB.assignDefaults=void 0;const t=_o(),e=qo();function i(r,o){const{properties:a,items:s}=r.schema;if(o==="object"&&a)for(const l in a)n(r,l,a[l].default);else o==="array"&&Array.isArray(s)&&s.forEach((l,u)=>n(r,u,l.default))}ZB.assignDefaults=i;function n(r,o,a){const{gen:s,compositeRule:l,data:u,opts:c}=r;if(a===void 0)return;const d=(0,t._)`${u}${(0,t.getProperty)(o)}`;if(l){(0,e.checkStrictMode)(r,`default is ignored for: ${d}`);return}let f=(0,t._)`${d} === undefined`;c.useDefaults==="empty"&&(f=(0,t._)`${f} || ${d} === null || ${d} === ""`),s.if(f,(0,t._)`${d} = ${(0,t.stringify)(a)}`)}return ZB}var uv={},Da={},E1e;function Gv(){if(E1e)return Da;E1e=1,Object.defineProperty(Da,"__esModule",{value:!0}),Da.validateUnion=Da.validateArray=Da.usePattern=Da.callValidateCode=Da.schemaProperties=Da.allSchemaProperties=Da.noPropertyInData=Da.propertyInData=Da.isOwnProperty=Da.hasPropFunc=Da.reportMissingProp=Da.checkMissingProp=Da.checkReportMissingProp=void 0;const t=_o(),e=qo(),i=aC(),n=qo();function r(m,b){const{gen:S,data:_,it:C}=m;S.if(c(S,_,b,C.opts.ownProperties),()=>{m.setParams({missingProperty:(0,t._)`${b}`},!0),m.error()})}Da.checkReportMissingProp=r;function o({gen:m,data:b,it:{opts:S}},_,C){return(0,t.or)(..._.map(P=>(0,t.and)(c(m,b,P,S.ownProperties),(0,t._)`${C} = ${P}`)))}Da.checkMissingProp=o;function a(m,b){m.setParams({missingProperty:b},!0),m.error()}Da.reportMissingProp=a;function s(m){return m.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,t._)`Object.prototype.hasOwnProperty`})}Da.hasPropFunc=s;function l(m,b,S){return(0,t._)`${s(m)}.call(${b}, ${S})`}Da.isOwnProperty=l;function u(m,b,S,_){const C=(0,t._)`${b}${(0,t.getProperty)(S)} !== undefined`;return _?(0,t._)`${C} && ${l(m,b,S)}`:C}Da.propertyInData=u;function c(m,b,S,_){const C=(0,t._)`${b}${(0,t.getProperty)(S)} === undefined`;return _?(0,t.or)(C,(0,t.not)(l(m,b,S))):C}Da.noPropertyInData=c;function d(m){return m?Object.keys(m).filter(b=>b!=="__proto__"):[]}Da.allSchemaProperties=d;function f(m,b){return d(b).filter(S=>!(0,e.alwaysValidSchema)(m,b[S]))}Da.schemaProperties=f;function h({schemaCode:m,data:b,it:{gen:S,topSchemaRef:_,schemaPath:C,errorPath:P},it:x},E,A,R){const M=R?(0,t._)`${m}, ${b}, ${_}${C}`:b,D=[[i.default.instancePath,(0,t.strConcat)(i.default.instancePath,P)],[i.default.parentData,x.parentData],[i.default.parentDataProperty,x.parentDataProperty],[i.default.rootData,i.default.rootData]];x.opts.dynamicRef&&D.push([i.default.dynamicAnchors,i.default.dynamicAnchors]);const F=(0,t._)`${M}, ${S.object(...D)}`;return A!==t.nil?(0,t._)`${E}.call(${A}, ${F})`:(0,t._)`${E}(${F})`}Da.callValidateCode=h;const p=(0,t._)`new RegExp`;function g({gen:m,it:{opts:b}},S){const _=b.unicodeRegExp?"u":"",{regExp:C}=b.code,P=C(S,_);return m.scopeValue("pattern",{key:P.toString(),ref:P,code:(0,t._)`${C.code==="new RegExp"?p:(0,n.useFunc)(m,C)}(${S}, ${_})`})}Da.usePattern=g;function v(m){const{gen:b,data:S,keyword:_,it:C}=m,P=b.name("valid");if(C.allErrors){const E=b.let("valid",!0);return x(()=>b.assign(E,!1)),E}return b.var(P,!0),x(()=>b.break()),P;function x(E){const A=b.const("len",(0,t._)`${S}.length`);b.forRange("i",0,A,R=>{m.subschema({keyword:_,dataProp:R,dataPropType:e.Type.Num},P),b.if((0,t.not)(P),E)})}}Da.validateArray=v;function y(m){const{gen:b,schema:S,keyword:_,it:C}=m;if(!Array.isArray(S))throw new Error("ajv implementation error");if(S.some(A=>(0,e.alwaysValidSchema)(C,A))&&!C.opts.unevaluated)return;const x=b.let("valid",!1),E=b.name("_valid");b.block(()=>S.forEach((A,R)=>{const M=m.subschema({keyword:_,schemaProp:R,compositeRule:!0},E);b.assign(x,(0,t._)`${x} || ${E}`),m.mergeValidEvaluated(M,E)||b.if((0,t.not)(x))})),m.result(x,()=>m.reset(),()=>m.error(!0))}return Da.validateUnion=y,Da}var w1e;function LRt(){if(w1e)return uv;w1e=1,Object.defineProperty(uv,"__esModule",{value:!0}),uv.validateKeywordUsage=uv.validSchemaType=uv.funcKeywordCode=uv.macroKeywordCode=void 0;const t=_o(),e=aC(),i=Gv(),n=nG();function r(f,h){const{gen:p,keyword:g,schema:v,parentSchema:y,it:m}=f,b=h.macro.call(m.self,v,y,m),S=u(p,g,b);m.opts.validateSchema!==!1&&m.self.validateSchema(b,!0);const _=p.name("valid");f.subschema({schema:b,schemaPath:t.nil,errSchemaPath:`${m.errSchemaPath}/${g}`,topSchemaRef:S,compositeRule:!0},_),f.pass(_,()=>f.error(!0))}uv.macroKeywordCode=r;function o(f,h){var p;const{gen:g,keyword:v,schema:y,parentSchema:m,$data:b,it:S}=f;l(S,h);const _=!b&&h.compile?h.compile.call(S.self,y,m,S):h.validate,C=u(g,v,_),P=g.let("valid");f.block$data(P,x),f.ok((p=h.valid)!==null&&p!==void 0?p:P);function x(){if(h.errors===!1)R(),h.modifying&&a(f),M(()=>f.error());else{const D=h.async?E():A();h.modifying&&a(f),M(()=>s(f,D))}}function E(){const D=g.let("ruleErrs",null);return g.try(()=>R((0,t._)`await `),F=>g.assign(P,!1).if((0,t._)`${F} instanceof ${S.ValidationError}`,()=>g.assign(D,(0,t._)`${F}.errors`),()=>g.throw(F))),D}function A(){const D=(0,t._)`${C}.errors`;return g.assign(D,null),R(t.nil),D}function R(D=h.async?(0,t._)`await `:t.nil){const F=S.opts.passContext?e.default.this:e.default.self,I=!("compile"in h&&!b||h.schema===!1);g.assign(P,(0,t._)`${D}${(0,i.callValidateCode)(f,C,F,I)}`,h.modifying)}function M(D){var F;g.if((0,t.not)((F=h.valid)!==null&&F!==void 0?F:P),D)}}uv.funcKeywordCode=o;function a(f){const{gen:h,data:p,it:g}=f;h.if(g.parentData,()=>h.assign(p,(0,t._)`${g.parentData}[${g.parentDataProperty}]`))}function s(f,h){const{gen:p}=f;p.if((0,t._)`Array.isArray(${h})`,()=>{p.assign(e.default.vErrors,(0,t._)`${e.default.vErrors} === null ? ${h} : ${e.default.vErrors}.concat(${h})`).assign(e.default.errors,(0,t._)`${e.default.vErrors}.length`),(0,n.extendErrors)(f)},()=>f.error())}function l({schemaEnv:f},h){if(h.async&&!f.$async)throw new Error("async keyword in sync schema")}function u(f,h,p){if(p===void 0)throw new Error(`keyword "${h}" failed to compile`);return f.scopeValue("keyword",typeof p=="function"?{ref:p}:{ref:p,code:(0,t.stringify)(p)})}function c(f,h,p=!1){return!h.length||h.some(g=>g==="array"?Array.isArray(f):g==="object"?f&&typeof f=="object"&&!Array.isArray(f):typeof f==g||p&&typeof f>"u")}uv.validSchemaType=c;function d({schema:f,opts:h,self:p,errSchemaPath:g},v,y){if(Array.isArray(v.keyword)?!v.keyword.includes(y):v.keyword!==y)throw new Error("ajv implementation error");const m=v.dependencies;if(m!=null&&m.some(b=>!Object.prototype.hasOwnProperty.call(f,b)))throw new Error(`parent schema must have dependencies of ${y}: ${m.join(",")}`);if(v.validateSchema&&!v.validateSchema(f[y])){const S=`keyword "${y}" value is invalid at path "${g}": `+p.errorsText(v.validateSchema.errors);if(h.validateSchema==="log")p.logger.error(S);else throw new Error(S)}}return uv.validateKeywordUsage=d,uv}var Gb={},A1e;function kRt(){if(A1e)return Gb;A1e=1,Object.defineProperty(Gb,"__esModule",{value:!0}),Gb.extendSubschemaMode=Gb.extendSubschemaData=Gb.getSubschema=void 0;const t=_o(),e=qo();function i(o,{keyword:a,schemaProp:s,schema:l,schemaPath:u,errSchemaPath:c,topSchemaRef:d}){if(a!==void 0&&l!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(a!==void 0){const f=o.schema[a];return s===void 0?{schema:f,schemaPath:(0,t._)`${o.schemaPath}${(0,t.getProperty)(a)}`,errSchemaPath:`${o.errSchemaPath}/${a}`}:{schema:f[s],schemaPath:(0,t._)`${o.schemaPath}${(0,t.getProperty)(a)}${(0,t.getProperty)(s)}`,errSchemaPath:`${o.errSchemaPath}/${a}/${(0,e.escapeFragment)(s)}`}}if(l!==void 0){if(u===void 0||c===void 0||d===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:l,schemaPath:u,topSchemaRef:d,errSchemaPath:c}}throw new Error('either "keyword" or "schema" must be passed')}Gb.getSubschema=i;function n(o,a,{dataProp:s,dataPropType:l,data:u,dataTypes:c,propertyName:d}){if(u!==void 0&&s!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:f}=a;if(s!==void 0){const{errorPath:p,dataPathArr:g,opts:v}=a,y=f.let("data",(0,t._)`${a.data}${(0,t.getProperty)(s)}`,!0);h(y),o.errorPath=(0,t.str)`${p}${(0,e.getErrorPath)(s,l,v.jsPropertySyntax)}`,o.parentDataProperty=(0,t._)`${s}`,o.dataPathArr=[...g,o.parentDataProperty]}if(u!==void 0){const p=u instanceof t.Name?u:f.let("data",u,!0);h(p),d!==void 0&&(o.propertyName=d)}c&&(o.dataTypes=c);function h(p){o.data=p,o.dataLevel=a.dataLevel+1,o.dataTypes=[],a.definedProperties=new Set,o.parentData=a.data,o.dataNames=[...a.dataNames,p]}}Gb.extendSubschemaData=n;function r(o,{jtdDiscriminator:a,jtdMetadata:s,compositeRule:l,createErrors:u,allErrors:c}){l!==void 0&&(o.compositeRule=l),u!==void 0&&(o.createErrors=u),c!==void 0&&(o.allErrors=c),o.jtdDiscriminator=a,o.jtdMetadata=s}return Gb.extendSubschemaMode=r,Gb}var Cf={},N7,O1e;function lHe(){return O1e||(O1e=1,N7=function t(e,i){if(e===i)return!0;if(e&&i&&typeof e=="object"&&typeof i=="object"){if(e.constructor!==i.constructor)return!1;var n,r,o;if(Array.isArray(e)){if(n=e.length,n!=i.length)return!1;for(r=n;r--!==0;)if(!t(e[r],i[r]))return!1;return!0}if(e.constructor===RegExp)return e.source===i.source&&e.flags===i.flags;if(e.valueOf!==Object.prototype.valueOf)return e.valueOf()===i.valueOf();if(e.toString!==Object.prototype.toString)return e.toString()===i.toString();if(o=Object.keys(e),n=o.length,n!==Object.keys(i).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(i,o[r]))return!1;for(r=n;r--!==0;){var a=o[r];if(!t(e[a],i[a]))return!1}return!0}return e!==e&&i!==i}),N7}var F7={exports:{}},D1e;function IRt(){if(D1e)return F7.exports;D1e=1;var t=F7.exports=function(n,r,o){typeof r=="function"&&(o=r,r={}),o=r.cb||o;var a=typeof o=="function"?o:o.pre||function(){},s=o.post||function(){};e(r,a,s,n,"",n)};t.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},t.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},t.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},t.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function e(n,r,o,a,s,l,u,c,d,f){if(a&&typeof a=="object"&&!Array.isArray(a)){r(a,s,l,u,c,d,f);for(var h in a){var p=a[h];if(Array.isArray(p)){if(h in t.arrayKeywords)for(var g=0;g<p.length;g++)e(n,r,o,p[g],s+"/"+h+"/"+g,l,s,h,a,g)}else if(h in t.propsKeywords){if(p&&typeof p=="object")for(var v in p)e(n,r,o,p[v],s+"/"+h+"/"+i(v),l,s,h,a,v)}else(h in t.keywords||n.allKeys&&!(h in t.skipKeywords))&&e(n,r,o,p,s+"/"+h,l,s,h,a)}o(a,s,l,u,c,d,f)}}function i(n){return n.replace(/~/g,"~0").replace(/\//g,"~1")}return F7.exports}var R1e;function oG(){if(R1e)return Cf;R1e=1,Object.defineProperty(Cf,"__esModule",{value:!0}),Cf.getSchemaRefs=Cf.resolveUrl=Cf.normalizeId=Cf._getFullPath=Cf.getFullPath=Cf.inlineRef=void 0;const t=qo(),e=lHe(),i=IRt(),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function r(g,v=!0){return typeof g=="boolean"?!0:v===!0?!a(g):v?s(g)<=v:!1}Cf.inlineRef=r;const o=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function a(g){for(const v in g){if(o.has(v))return!0;const y=g[v];if(Array.isArray(y)&&y.some(a)||typeof y=="object"&&a(y))return!0}return!1}function s(g){let v=0;for(const y in g){if(y==="$ref")return 1/0;if(v++,!n.has(y)&&(typeof g[y]=="object"&&(0,t.eachItem)(g[y],m=>v+=s(m)),v===1/0))return 1/0}return v}function l(g,v="",y){y!==!1&&(v=d(v));const m=g.parse(v);return u(g,m)}Cf.getFullPath=l;function u(g,v){return g.serialize(v).split("#")[0]+"#"}Cf._getFullPath=u;const c=/#\/?$/;function d(g){return g?g.replace(c,""):""}Cf.normalizeId=d;function f(g,v,y){return y=d(y),g.resolve(v,y)}Cf.resolveUrl=f;const h=/^[a-z_][-a-z0-9._]*$/i;function p(g,v){if(typeof g=="boolean")return{};const{schemaId:y,uriResolver:m}=this.opts,b=d(g[y]||v),S={"":b},_=l(m,b,!1),C={},P=new Set;return i(g,{allKeys:!0},(A,R,M,D)=>{if(D===void 0)return;const F=_+R;let I=S[D];typeof A[y]=="string"&&(I=V.call(this,A[y])),z.call(this,A.$anchor),z.call(this,A.$dynamicAnchor),S[R]=I;function V(G){const H=this.opts.uriResolver.resolve;if(G=d(I?H(I,G):G),P.has(G))throw E(G);P.add(G);let U=this.refs[G];return typeof U=="string"&&(U=this.refs[U]),typeof U=="object"?x(A,U.schema,G):G!==d(F)&&(G[0]==="#"?(x(A,C[G],G),C[G]=A):this.refs[G]=F),G}function z(G){if(typeof G=="string"){if(!h.test(G))throw new Error(`invalid anchor "${G}"`);V.call(this,`#${G}`)}}}),C;function x(A,R,M){if(R!==void 0&&!e(A,R))throw E(M)}function E(A){return new Error(`reference "${A}" resolves to more than one schema`)}}return Cf.getSchemaRefs=p,Cf}var M1e;function aG(){if(M1e)return $b;M1e=1,Object.defineProperty($b,"__esModule",{value:!0}),$b.getData=$b.KeywordCxt=$b.validateFunctionCode=void 0;const t=RRt(),e=v$(),i=sHe(),n=v$(),r=MRt(),o=LRt(),a=kRt(),s=_o(),l=aC(),u=oG(),c=qo(),d=nG();function f(Ae){if(_(Ae)&&(P(Ae),S(Ae))){v(Ae);return}h(Ae,()=>(0,t.topBoolOrEmptySchema)(Ae))}$b.validateFunctionCode=f;function h({gen:Ae,validateName:Pe,schema:we,schemaEnv:Te,opts:ke},$e){ke.code.es5?Ae.func(Pe,(0,s._)`${l.default.data}, ${l.default.valCxt}`,Te.$async,()=>{Ae.code((0,s._)`"use strict"; ${m(we,ke)}`),g(Ae,ke),Ae.code($e)}):Ae.func(Pe,(0,s._)`${l.default.data}, ${p(ke)}`,Te.$async,()=>Ae.code(m(we,ke)).code($e))}function p(Ae){return(0,s._)`{${l.default.instancePath}="", ${l.default.parentData}, ${l.default.parentDataProperty}, ${l.default.rootData}=${l.default.data}${Ae.dynamicRef?(0,s._)`, ${l.default.dynamicAnchors}={}`:s.nil}}={}`}function g(Ae,Pe){Ae.if(l.default.valCxt,()=>{Ae.var(l.default.instancePath,(0,s._)`${l.default.valCxt}.${l.default.instancePath}`),Ae.var(l.default.parentData,(0,s._)`${l.default.valCxt}.${l.default.parentData}`),Ae.var(l.default.parentDataProperty,(0,s._)`${l.default.valCxt}.${l.default.parentDataProperty}`),Ae.var(l.default.rootData,(0,s._)`${l.default.valCxt}.${l.default.rootData}`),Pe.dynamicRef&&Ae.var(l.default.dynamicAnchors,(0,s._)`${l.default.valCxt}.${l.default.dynamicAnchors}`)},()=>{Ae.var(l.default.instancePath,(0,s._)`""`),Ae.var(l.default.parentData,(0,s._)`undefined`),Ae.var(l.default.parentDataProperty,(0,s._)`undefined`),Ae.var(l.default.rootData,l.default.data),Pe.dynamicRef&&Ae.var(l.default.dynamicAnchors,(0,s._)`{}`)})}function v(Ae){const{schema:Pe,opts:we,gen:Te}=Ae;h(Ae,()=>{we.$comment&&Pe.$comment&&D(Ae),A(Ae),Te.let(l.default.vErrors,null),Te.let(l.default.errors,0),we.unevaluated&&y(Ae),x(Ae),F(Ae)})}function y(Ae){const{gen:Pe,validateName:we}=Ae;Ae.evaluated=Pe.const("evaluated",(0,s._)`${we}.evaluated`),Pe.if((0,s._)`${Ae.evaluated}.dynamicProps`,()=>Pe.assign((0,s._)`${Ae.evaluated}.props`,(0,s._)`undefined`)),Pe.if((0,s._)`${Ae.evaluated}.dynamicItems`,()=>Pe.assign((0,s._)`${Ae.evaluated}.items`,(0,s._)`undefined`))}function m(Ae,Pe){const we=typeof Ae=="object"&&Ae[Pe.schemaId];return we&&(Pe.code.source||Pe.code.process)?(0,s._)`/*# sourceURL=${we} */`:s.nil}function b(Ae,Pe){if(_(Ae)&&(P(Ae),S(Ae))){C(Ae,Pe);return}(0,t.boolOrEmptySchema)(Ae,Pe)}function S({schema:Ae,self:Pe}){if(typeof Ae=="boolean")return!Ae;for(const we in Ae)if(Pe.RULES.all[we])return!0;return!1}function _(Ae){return typeof Ae.schema!="boolean"}function C(Ae,Pe){const{schema:we,gen:Te,opts:ke}=Ae;ke.$comment&&we.$comment&&D(Ae),R(Ae),M(Ae);const $e=Te.const("_errs",l.default.errors);x(Ae,$e),Te.var(Pe,(0,s._)`${$e} === ${l.default.errors}`)}function P(Ae){(0,c.checkUnknownRules)(Ae),E(Ae)}function x(Ae,Pe){if(Ae.opts.jtd)return V(Ae,[],!1,Pe);const we=(0,e.getSchemaTypes)(Ae.schema),Te=(0,e.coerceAndCheckDataType)(Ae,we);V(Ae,we,!Te,Pe)}function E(Ae){const{schema:Pe,errSchemaPath:we,opts:Te,self:ke}=Ae;Pe.$ref&&Te.ignoreKeywordsWithRef&&(0,c.schemaHasRulesButRef)(Pe,ke.RULES)&&ke.logger.warn(`$ref: keywords ignored in schema at path "${we}"`)}function A(Ae){const{schema:Pe,opts:we}=Ae;Pe.default!==void 0&&we.useDefaults&&we.strictSchema&&(0,c.checkStrictMode)(Ae,"default is ignored in the schema root")}function R(Ae){const Pe=Ae.schema[Ae.opts.schemaId];Pe&&(Ae.baseId=(0,u.resolveUrl)(Ae.opts.uriResolver,Ae.baseId,Pe))}function M(Ae){if(Ae.schema.$async&&!Ae.schemaEnv.$async)throw new Error("async schema in sync schema")}function D({gen:Ae,schemaEnv:Pe,schema:we,errSchemaPath:Te,opts:ke}){const $e=we.$comment;if(ke.$comment===!0)Ae.code((0,s._)`${l.default.self}.logger.log(${$e})`);else if(typeof ke.$comment=="function"){const Ne=(0,s.str)`${Te}/$comment`,ve=Ae.scopeValue("root",{ref:Pe.root});Ae.code((0,s._)`${l.default.self}.opts.$comment(${$e}, ${Ne}, ${ve}.schema)`)}}function F(Ae){const{gen:Pe,schemaEnv:we,validateName:Te,ValidationError:ke,opts:$e}=Ae;we.$async?Pe.if((0,s._)`${l.default.errors} === 0`,()=>Pe.return(l.default.data),()=>Pe.throw((0,s._)`new ${ke}(${l.default.vErrors})`)):(Pe.assign((0,s._)`${Te}.errors`,l.default.vErrors),$e.unevaluated&&I(Ae),Pe.return((0,s._)`${l.default.errors} === 0`))}function I({gen:Ae,evaluated:Pe,props:we,items:Te}){we instanceof s.Name&&Ae.assign((0,s._)`${Pe}.props`,we),Te instanceof s.Name&&Ae.assign((0,s._)`${Pe}.items`,Te)}function V(Ae,Pe,we,Te){const{gen:ke,schema:$e,data:Ne,allErrors:ve,opts:pe,self:fe}=Ae,{RULES:me}=fe;if($e.$ref&&(pe.ignoreKeywordsWithRef||!(0,c.schemaHasRulesButRef)($e,me))){ke.block(()=>de(Ae,"$ref",me.all.$ref.definition));return}pe.jtd||G(Ae,Pe),ke.block(()=>{for(const Ue of me.rules)Ce(Ue);Ce(me.post)});function Ce(Ue){(0,i.shouldUseGroup)($e,Ue)&&(Ue.type?(ke.if((0,n.checkDataType)(Ue.type,Ne,pe.strictNumbers)),z(Ae,Ue),Pe.length===1&&Pe[0]===Ue.type&&we&&(ke.else(),(0,n.reportTypeError)(Ae)),ke.endIf()):z(Ae,Ue),ve||ke.if((0,s._)`${l.default.errors} === ${Te||0}`))}}function z(Ae,Pe){const{gen:we,schema:Te,opts:{useDefaults:ke}}=Ae;ke&&(0,r.assignDefaults)(Ae,Pe.type),we.block(()=>{for(const $e of Pe.rules)(0,i.shouldUseRule)(Te,$e)&&de(Ae,$e.keyword,$e.definition,Pe.type)})}function G(Ae,Pe){Ae.schemaEnv.meta||!Ae.opts.strictTypes||(H(Ae,Pe),Ae.opts.allowUnionTypes||U(Ae,Pe),k(Ae,Ae.dataTypes))}function H(Ae,Pe){if(Pe.length){if(!Ae.dataTypes.length){Ae.dataTypes=Pe;return}Pe.forEach(we=>{W(Ae.dataTypes,we)||te(Ae,`type "${we}" not allowed by context "${Ae.dataTypes.join(",")}"`)}),Y(Ae,Pe)}}function U(Ae,Pe){Pe.length>1&&!(Pe.length===2&&Pe.includes("null"))&&te(Ae,"use allowUnionTypes to allow union type keyword")}function k(Ae,Pe){const we=Ae.self.RULES.all;for(const Te in we){const ke=we[Te];if(typeof ke=="object"&&(0,i.shouldUseRule)(Ae.schema,ke)){const{type:$e}=ke.definition;$e.length&&!$e.some(Ne=>X(Pe,Ne))&&te(Ae,`missing type "${$e.join(",")}" for keyword "${Te}"`)}}}function X(Ae,Pe){return Ae.includes(Pe)||Pe==="number"&&Ae.includes("integer")}function W(Ae,Pe){return Ae.includes(Pe)||Pe==="integer"&&Ae.includes("number")}function Y(Ae,Pe){const we=[];for(const Te of Ae.dataTypes)W(Pe,Te)?we.push(Te):Pe.includes("integer")&&Te==="number"&&we.push("integer");Ae.dataTypes=we}function te(Ae,Pe){const we=Ae.schemaEnv.baseId+Ae.errSchemaPath;Pe+=` at "${we}" (strictTypes)`,(0,c.checkStrictMode)(Ae,Pe,Ae.opts.strictTypes)}class oe{constructor(Pe,we,Te){if((0,o.validateKeywordUsage)(Pe,we,Te),this.gen=Pe.gen,this.allErrors=Pe.allErrors,this.keyword=Te,this.data=Pe.data,this.schema=Pe.schema[Te],this.$data=we.$data&&Pe.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,c.schemaRefOrVal)(Pe,this.schema,Te,this.$data),this.schemaType=we.schemaType,this.parentSchema=Pe.schema,this.params={},this.it=Pe,this.def=we,this.$data)this.schemaCode=Pe.gen.const("vSchema",Re(this.$data,Pe));else if(this.schemaCode=this.schemaValue,!(0,o.validSchemaType)(this.schema,we.schemaType,we.allowUndefined))throw new Error(`${Te} value must be ${JSON.stringify(we.schemaType)}`);("code"in we?we.trackErrors:we.errors!==!1)&&(this.errsCount=Pe.gen.const("_errs",l.default.errors))}result(Pe,we,Te){this.failResult((0,s.not)(Pe),we,Te)}failResult(Pe,we,Te){this.gen.if(Pe),Te?Te():this.error(),we?(this.gen.else(),we(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(Pe,we){this.failResult((0,s.not)(Pe),void 0,we)}fail(Pe){if(Pe===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(Pe),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(Pe){if(!this.$data)return this.fail(Pe);const{schemaCode:we}=this;this.fail((0,s._)`${we} !== undefined && (${(0,s.or)(this.invalid$data(),Pe)})`)}error(Pe,we,Te){if(we){this.setParams(we),this._error(Pe,Te),this.setParams({});return}this._error(Pe,Te)}_error(Pe,we){(Pe?d.reportExtraError:d.reportError)(this,this.def.error,we)}$dataError(){(0,d.reportError)(this,this.def.$dataError||d.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,d.resetErrorsCount)(this.gen,this.errsCount)}ok(Pe){this.allErrors||this.gen.if(Pe)}setParams(Pe,we){we?Object.assign(this.params,Pe):this.params=Pe}block$data(Pe,we,Te=s.nil){this.gen.block(()=>{this.check$data(Pe,Te),we()})}check$data(Pe=s.nil,we=s.nil){if(!this.$data)return;const{gen:Te,schemaCode:ke,schemaType:$e,def:Ne}=this;Te.if((0,s.or)((0,s._)`${ke} === undefined`,we)),Pe!==s.nil&&Te.assign(Pe,!0),($e.length||Ne.validateSchema)&&(Te.elseIf(this.invalid$data()),this.$dataError(),Pe!==s.nil&&Te.assign(Pe,!1)),Te.else()}invalid$data(){const{gen:Pe,schemaCode:we,schemaType:Te,def:ke,it:$e}=this;return(0,s.or)(Ne(),ve());function Ne(){if(Te.length){if(!(we instanceof s.Name))throw new Error("ajv implementation error");const pe=Array.isArray(Te)?Te:[Te];return(0,s._)`${(0,n.checkDataTypes)(pe,we,$e.opts.strictNumbers,n.DataType.Wrong)}`}return s.nil}function ve(){if(ke.validateSchema){const pe=Pe.scopeValue("validate$data",{ref:ke.validateSchema});return(0,s._)`!${pe}(${we})`}return s.nil}}subschema(Pe,we){const Te=(0,a.getSubschema)(this.it,Pe);(0,a.extendSubschemaData)(Te,this.it,Pe),(0,a.extendSubschemaMode)(Te,Pe);const ke={...this.it,...Te,items:void 0,props:void 0};return b(ke,we),ke}mergeEvaluated(Pe,we){const{it:Te,gen:ke}=this;Te.opts.unevaluated&&(Te.props!==!0&&Pe.props!==void 0&&(Te.props=c.mergeEvaluated.props(ke,Pe.props,Te.props,we)),Te.items!==!0&&Pe.items!==void 0&&(Te.items=c.mergeEvaluated.items(ke,Pe.items,Te.items,we)))}mergeValidEvaluated(Pe,we){const{it:Te,gen:ke}=this;if(Te.opts.unevaluated&&(Te.props!==!0||Te.items!==!0))return ke.if(we,()=>this.mergeEvaluated(Pe,s.Name)),!0}}$b.KeywordCxt=oe;function de(Ae,Pe,we,Te){const ke=new oe(Ae,we,Pe);"code"in we?we.code(ke,Te):ke.$data&&we.validate?(0,o.funcKeywordCode)(ke,we):"macro"in we?(0,o.macroKeywordCode)(ke,we):(we.compile||we.validate)&&(0,o.funcKeywordCode)(ke,we)}const ge=/^\/(?:[^~]|~0|~1)*$/,Ee=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Re(Ae,{dataLevel:Pe,dataNames:we,dataPathArr:Te}){let ke,$e;if(Ae==="")return l.default.rootData;if(Ae[0]==="/"){if(!ge.test(Ae))throw new Error(`Invalid JSON-pointer: ${Ae}`);ke=Ae,$e=l.default.rootData}else{const fe=Ee.exec(Ae);if(!fe)throw new Error(`Invalid JSON-pointer: ${Ae}`);const me=+fe[1];if(ke=fe[2],ke==="#"){if(me>=Pe)throw new Error(pe("property/index",me));return Te[Pe-me]}if(me>Pe)throw new Error(pe("data",me));if($e=we[Pe-me],!ke)return $e}let Ne=$e;const ve=ke.split("/");for(const fe of ve)fe&&($e=(0,s._)`${$e}${(0,s.getProperty)((0,c.unescapeJsonPointer)(fe))}`,Ne=(0,s._)`${Ne} && ${$e}`);return Ne;function pe(fe,me){return`Cannot access ${fe} ${me} levels up, current level is ${Pe}`}}return $b.getData=Re,$b}var I4={},L1e;function gne(){if(L1e)return I4;L1e=1,Object.defineProperty(I4,"__esModule",{value:!0});class t extends Error{constructor(i){super("validation failed"),this.errors=i,this.ajv=this.validation=!0}}return I4.default=t,I4}var N4={},k1e;function sG(){if(k1e)return N4;k1e=1,Object.defineProperty(N4,"__esModule",{value:!0});const t=oG();class e extends Error{constructor(n,r,o,a){super(a||`can't resolve reference ${o} from id ${r}`),this.missingRef=(0,t.resolveUrl)(n,r,o),this.missingSchema=(0,t.normalizeId)((0,t.getFullPath)(n,this.missingRef))}}return N4.default=e,N4}var vp={},I1e;function vne(){if(I1e)return vp;I1e=1,Object.defineProperty(vp,"__esModule",{value:!0}),vp.resolveSchema=vp.getCompilingSchema=vp.resolveRef=vp.compileSchema=vp.SchemaEnv=void 0;const t=_o(),e=gne(),i=aC(),n=oG(),r=qo(),o=aG();class a{constructor(y){var m;this.refs={},this.dynamicAnchors={};let b;typeof y.schema=="object"&&(b=y.schema),this.schema=y.schema,this.schemaId=y.schemaId,this.root=y.root||this,this.baseId=(m=y.baseId)!==null&&m!==void 0?m:(0,n.normalizeId)(b==null?void 0:b[y.schemaId||"$id"]),this.schemaPath=y.schemaPath,this.localRefs=y.localRefs,this.meta=y.meta,this.$async=b==null?void 0:b.$async,this.refs={}}}vp.SchemaEnv=a;function s(v){const y=c.call(this,v);if(y)return y;const m=(0,n.getFullPath)(this.opts.uriResolver,v.root.baseId),{es5:b,lines:S}=this.opts.code,{ownProperties:_}=this.opts,C=new t.CodeGen(this.scope,{es5:b,lines:S,ownProperties:_});let P;v.$async&&(P=C.scopeValue("Error",{ref:e.default,code:(0,t._)`require("ajv/dist/runtime/validation_error").default`}));const x=C.scopeName("validate");v.validateName=x;const E={gen:C,allErrors:this.opts.allErrors,data:i.default.data,parentData:i.default.parentData,parentDataProperty:i.default.parentDataProperty,dataNames:[i.default.data],dataPathArr:[t.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:C.scopeValue("schema",this.opts.code.source===!0?{ref:v.schema,code:(0,t.stringify)(v.schema)}:{ref:v.schema}),validateName:x,ValidationError:P,schema:v.schema,schemaEnv:v,rootId:m,baseId:v.baseId||m,schemaPath:t.nil,errSchemaPath:v.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,t._)`""`,opts:this.opts,self:this};let A;try{this._compilations.add(v),(0,o.validateFunctionCode)(E),C.optimize(this.opts.code.optimize);const R=C.toString();A=`${C.scopeRefs(i.default.scope)}return ${R}`,this.opts.code.process&&(A=this.opts.code.process(A,v));const D=new Function(`${i.default.self}`,`${i.default.scope}`,A)(this,this.scope.get());if(this.scope.value(x,{ref:D}),D.errors=null,D.schema=v.schema,D.schemaEnv=v,v.$async&&(D.$async=!0),this.opts.code.source===!0&&(D.source={validateName:x,validateCode:R,scopeValues:C._values}),this.opts.unevaluated){const{props:F,items:I}=E;D.evaluated={props:F instanceof t.Name?void 0:F,items:I instanceof t.Name?void 0:I,dynamicProps:F instanceof t.Name,dynamicItems:I instanceof t.Name},D.source&&(D.source.evaluated=(0,t.stringify)(D.evaluated))}return v.validate=D,v}catch(R){throw delete v.validate,delete v.validateName,A&&this.logger.error("Error compiling schema, function code:",A),R}finally{this._compilations.delete(v)}}vp.compileSchema=s;function l(v,y,m){var b;m=(0,n.resolveUrl)(this.opts.uriResolver,y,m);const S=v.refs[m];if(S)return S;let _=f.call(this,v,m);if(_===void 0){const C=(b=v.localRefs)===null||b===void 0?void 0:b[m],{schemaId:P}=this.opts;C&&(_=new a({schema:C,schemaId:P,root:v,baseId:y}))}if(_!==void 0)return v.refs[m]=u.call(this,_)}vp.resolveRef=l;function u(v){return(0,n.inlineRef)(v.schema,this.opts.inlineRefs)?v.schema:v.validate?v:s.call(this,v)}function c(v){for(const y of this._compilations)if(d(y,v))return y}vp.getCompilingSchema=c;function d(v,y){return v.schema===y.schema&&v.root===y.root&&v.baseId===y.baseId}function f(v,y){let m;for(;typeof(m=this.refs[y])=="string";)y=m;return m||this.schemas[y]||h.call(this,v,y)}function h(v,y){const m=this.opts.uriResolver.parse(y),b=(0,n._getFullPath)(this.opts.uriResolver,m);let S=(0,n.getFullPath)(this.opts.uriResolver,v.baseId,void 0);if(Object.keys(v.schema).length>0&&b===S)return g.call(this,m,v);const _=(0,n.normalizeId)(b),C=this.refs[_]||this.schemas[_];if(typeof C=="string"){const P=h.call(this,v,C);return typeof(P==null?void 0:P.schema)!="object"?void 0:g.call(this,m,P)}if(typeof(C==null?void 0:C.schema)=="object"){if(C.validate||s.call(this,C),_===(0,n.normalizeId)(y)){const{schema:P}=C,{schemaId:x}=this.opts,E=P[x];return E&&(S=(0,n.resolveUrl)(this.opts.uriResolver,S,E)),new a({schema:P,schemaId:x,root:v,baseId:S})}return g.call(this,m,C)}}vp.resolveSchema=h;const p=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function g(v,{baseId:y,schema:m,root:b}){var S;if(((S=v.fragment)===null||S===void 0?void 0:S[0])!=="/")return;for(const P of v.fragment.slice(1).split("/")){if(typeof m=="boolean")return;const x=m[(0,r.unescapeFragment)(P)];if(x===void 0)return;m=x;const E=typeof m=="object"&&m[this.opts.schemaId];!p.has(P)&&E&&(y=(0,n.resolveUrl)(this.opts.uriResolver,y,E))}let _;if(typeof m!="boolean"&&m.$ref&&!(0,r.schemaHasRulesButRef)(m,this.RULES)){const P=(0,n.resolveUrl)(this.opts.uriResolver,y,m.$ref);_=h.call(this,b,P)}const{schemaId:C}=this.opts;if(_=_||new a({schema:m,schemaId:C,root:b,baseId:y}),_.schema!==_.root.schema)return _}return vp}const NRt="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",FRt="Meta-schema for $data reference (JSON AnySchema extension proposal)",BRt="object",jRt=["$data"],VRt={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},HRt=!1,URt={$id:NRt,description:FRt,type:BRt,required:jRt,properties:VRt,additionalProperties:HRt};var F4={},JB={exports:{}},B7,N1e;function uHe(){if(N1e)return B7;N1e=1;const t=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),e=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);function i(f){let h="",p=0,g=0;for(g=0;g<f.length;g++)if(p=f[g].charCodeAt(0),p!==48){if(!(p>=48&&p<=57||p>=65&&p<=70||p>=97&&p<=102))return"";h+=f[g];break}for(g+=1;g<f.length;g++){if(p=f[g].charCodeAt(0),!(p>=48&&p<=57||p>=65&&p<=70||p>=97&&p<=102))return"";h+=f[g]}return h}const n=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function r(f){return f.length=0,!0}function o(f,h,p){if(f.length){const g=i(f);if(g!=="")h.push(g);else return p.error=!0,!1;f.length=0}return!0}function a(f){let h=0;const p={error:!1,address:"",zone:""},g=[],v=[];let y=!1,m=!1,b=o;for(let S=0;S<f.length;S++){const _=f[S];if(!(_==="["||_==="]"))if(_===":"){if(y===!0&&(m=!0),!b(v,g,p))break;if(++h>7){p.error=!0;break}S>0&&f[S-1]===":"&&(y=!0),g.push(":");continue}else if(_==="%"){if(!b(v,g,p))break;b=r}else{v.push(_);continue}}return v.length&&(b===r?p.zone=v.join(""):m?g.push(v.join("")):g.push(i(v))),p.address=g.join(""),p}function s(f){if(l(f,":")<2)return{host:f,isIPV6:!1};const h=a(f);if(h.error)return{host:f,isIPV6:!1};{let p=h.address,g=h.address;return h.zone&&(p+="%"+h.zone,g+="%25"+h.zone),{host:p,isIPV6:!0,escapedHost:g}}}function l(f,h){let p=0;for(let g=0;g<f.length;g++)f[g]===h&&p++;return p}function u(f){let h=f;const p=[];let g=-1,v=0;for(;v=h.length;){if(v===1){if(h===".")break;if(h==="/"){p.push("/");break}else{p.push(h);break}}else if(v===2){if(h[0]==="."){if(h[1]===".")break;if(h[1]==="/"){h=h.slice(2);continue}}else if(h[0]==="/"&&(h[1]==="."||h[1]==="/")){p.push("/");break}}else if(v===3&&h==="/.."){p.length!==0&&p.pop(),p.push("/");break}if(h[0]==="."){if(h[1]==="."){if(h[2]==="/"){h=h.slice(3);continue}}else if(h[1]==="/"){h=h.slice(2);continue}}else if(h[0]==="/"&&h[1]==="."){if(h[2]==="/"){h=h.slice(2);continue}else if(h[2]==="."&&h[3]==="/"){h=h.slice(3),p.length!==0&&p.pop();continue}}if((g=h.indexOf("/",1))===-1){p.push(h);break}else p.push(h.slice(0,g)),h=h.slice(g)}return p.join("")}function c(f,h){const p=h!==!0?escape:unescape;return f.scheme!==void 0&&(f.scheme=p(f.scheme)),f.userinfo!==void 0&&(f.userinfo=p(f.userinfo)),f.host!==void 0&&(f.host=p(f.host)),f.path!==void 0&&(f.path=p(f.path)),f.query!==void 0&&(f.query=p(f.query)),f.fragment!==void 0&&(f.fragment=p(f.fragment)),f}function d(f){const h=[];if(f.userinfo!==void 0&&(h.push(f.userinfo),h.push("@")),f.host!==void 0){let p=unescape(f.host);if(!e(p)){const g=s(p);g.isIPV6===!0?p=`[${g.escapedHost}]`:p=f.host}h.push(p)}return(typeof f.port=="number"||typeof f.port=="string")&&(h.push(":"),h.push(String(f.port))),h.length?h.join(""):void 0}return B7={nonSimpleDomain:n,recomposeAuthority:d,normalizeComponentEncoding:c,removeDotSegments:u,isIPv4:e,isUUID:t,normalizeIPv6:s,stringArrayToHexStripped:i},B7}var j7,F1e;function zRt(){if(F1e)return j7;F1e=1;const{isUUID:t}=uHe(),e=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,i=["http","https","ws","wss","urn","urn:uuid"];function n(_){return i.indexOf(_)!==-1}function r(_){return _.secure===!0?!0:_.secure===!1?!1:_.scheme?_.scheme.length===3&&(_.scheme[0]==="w"||_.scheme[0]==="W")&&(_.scheme[1]==="s"||_.scheme[1]==="S")&&(_.scheme[2]==="s"||_.scheme[2]==="S"):!1}function o(_){return _.host||(_.error=_.error||"HTTP URIs must have a host."),_}function a(_){const C=String(_.scheme).toLowerCase()==="https";return(_.port===(C?443:80)||_.port==="")&&(_.port=void 0),_.path||(_.path="/"),_}function s(_){return _.secure=r(_),_.resourceName=(_.path||"/")+(_.query?"?"+_.query:""),_.path=void 0,_.query=void 0,_}function l(_){if((_.port===(r(_)?443:80)||_.port==="")&&(_.port=void 0),typeof _.secure=="boolean"&&(_.scheme=_.secure?"wss":"ws",_.secure=void 0),_.resourceName){const[C,P]=_.resourceName.split("?");_.path=C&&C!=="/"?C:void 0,_.query=P,_.resourceName=void 0}return _.fragment=void 0,_}function u(_,C){if(!_.path)return _.error="URN can not be parsed",_;const P=_.path.match(e);if(P){const x=C.scheme||_.scheme||"urn";_.nid=P[1].toLowerCase(),_.nss=P[2];const E=`${x}:${C.nid||_.nid}`,A=S(E);_.path=void 0,A&&(_=A.parse(_,C))}else _.error=_.error||"URN can not be parsed.";return _}function c(_,C){if(_.nid===void 0)throw new Error("URN without nid cannot be serialized");const P=C.scheme||_.scheme||"urn",x=_.nid.toLowerCase(),E=`${P}:${C.nid||x}`,A=S(E);A&&(_=A.serialize(_,C));const R=_,M=_.nss;return R.path=`${x||C.nid}:${M}`,C.skipEscape=!0,R}function d(_,C){const P=_;return P.uuid=P.nss,P.nss=void 0,!C.tolerant&&(!P.uuid||!t(P.uuid))&&(P.error=P.error||"UUID is not valid."),P}function f(_){const C=_;return C.nss=(_.uuid||"").toLowerCase(),C}const h={scheme:"http",domainHost:!0,parse:o,serialize:a},p={scheme:"https",domainHost:h.domainHost,parse:o,serialize:a},g={scheme:"ws",domainHost:!0,parse:s,serialize:l},v={scheme:"wss",domainHost:g.domainHost,parse:g.parse,serialize:g.serialize},b={http:h,https:p,ws:g,wss:v,urn:{scheme:"urn",parse:u,serialize:c,skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:d,serialize:f,skipNormalize:!0}};Object.setPrototypeOf(b,null);function S(_){return _&&(b[_]||b[_.toLowerCase()])||void 0}return j7={wsIsSecure:r,SCHEMES:b,isValidSchemeName:n,getSchemeHandler:S},j7}var B1e;function $Rt(){if(B1e)return JB.exports;B1e=1;const{normalizeIPv6:t,removeDotSegments:e,recomposeAuthority:i,normalizeComponentEncoding:n,isIPv4:r,nonSimpleDomain:o}=uHe(),{SCHEMES:a,getSchemeHandler:s}=zRt();function l(v,y){return typeof v=="string"?v=f(p(v,y),y):typeof v=="object"&&(v=p(f(v,y),y)),v}function u(v,y,m){const b=m?Object.assign({scheme:"null"},m):{scheme:"null"},S=c(p(v,b),p(y,b),b,!0);return b.skipEscape=!0,f(S,b)}function c(v,y,m,b){const S={};return b||(v=p(f(v,m),m),y=p(f(y,m),m)),m=m||{},!m.tolerant&&y.scheme?(S.scheme=y.scheme,S.userinfo=y.userinfo,S.host=y.host,S.port=y.port,S.path=e(y.path||""),S.query=y.query):(y.userinfo!==void 0||y.host!==void 0||y.port!==void 0?(S.userinfo=y.userinfo,S.host=y.host,S.port=y.port,S.path=e(y.path||""),S.query=y.query):(y.path?(y.path[0]==="/"?S.path=e(y.path):((v.userinfo!==void 0||v.host!==void 0||v.port!==void 0)&&!v.path?S.path="/"+y.path:v.path?S.path=v.path.slice(0,v.path.lastIndexOf("/")+1)+y.path:S.path=y.path,S.path=e(S.path)),S.query=y.query):(S.path=v.path,y.query!==void 0?S.query=y.query:S.query=v.query),S.userinfo=v.userinfo,S.host=v.host,S.port=v.port),S.scheme=v.scheme),S.fragment=y.fragment,S}function d(v,y,m){return typeof v=="string"?(v=unescape(v),v=f(n(p(v,m),!0),{...m,skipEscape:!0})):typeof v=="object"&&(v=f(n(v,!0),{...m,skipEscape:!0})),typeof y=="string"?(y=unescape(y),y=f(n(p(y,m),!0),{...m,skipEscape:!0})):typeof y=="object"&&(y=f(n(y,!0),{...m,skipEscape:!0})),v.toLowerCase()===y.toLowerCase()}function f(v,y){const m={host:v.host,scheme:v.scheme,userinfo:v.userinfo,port:v.port,path:v.path,query:v.query,nid:v.nid,nss:v.nss,uuid:v.uuid,fragment:v.fragment,reference:v.reference,resourceName:v.resourceName,secure:v.secure,error:""},b=Object.assign({},y),S=[],_=s(b.scheme||m.scheme);_&&_.serialize&&_.serialize(m,b),m.path!==void 0&&(b.skipEscape?m.path=unescape(m.path):(m.path=escape(m.path),m.scheme!==void 0&&(m.path=m.path.split("%3A").join(":")))),b.reference!=="suffix"&&m.scheme&&S.push(m.scheme,":");const C=i(m);if(C!==void 0&&(b.reference!=="suffix"&&S.push("//"),S.push(C),m.path&&m.path[0]!=="/"&&S.push("/")),m.path!==void 0){let P=m.path;!b.absolutePath&&(!_||!_.absolutePath)&&(P=e(P)),C===void 0&&P[0]==="/"&&P[1]==="/"&&(P="/%2F"+P.slice(2)),S.push(P)}return m.query!==void 0&&S.push("?",m.query),m.fragment!==void 0&&S.push("#",m.fragment),S.join("")}const h=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function p(v,y){const m=Object.assign({},y),b={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let S=!1;m.reference==="suffix"&&(m.scheme?v=m.scheme+":"+v:v="//"+v);const _=v.match(h);if(_){if(b.scheme=_[1],b.userinfo=_[3],b.host=_[4],b.port=parseInt(_[5],10),b.path=_[6]||"",b.query=_[7],b.fragment=_[8],isNaN(b.port)&&(b.port=_[5]),b.host)if(r(b.host)===!1){const x=t(b.host);b.host=x.host.toLowerCase(),S=x.isIPV6}else S=!0;b.scheme===void 0&&b.userinfo===void 0&&b.host===void 0&&b.port===void 0&&b.query===void 0&&!b.path?b.reference="same-document":b.scheme===void 0?b.reference="relative":b.fragment===void 0?b.reference="absolute":b.reference="uri",m.reference&&m.reference!=="suffix"&&m.reference!==b.reference&&(b.error=b.error||"URI is not a "+m.reference+" reference.");const C=s(m.scheme||b.scheme);if(!m.unicodeSupport&&(!C||!C.unicodeSupport)&&b.host&&(m.domainHost||C&&C.domainHost)&&S===!1&&o(b.host))try{b.host=URL.domainToASCII(b.host.toLowerCase())}catch(P){b.error=b.error||"Host's domain name can not be converted to ASCII: "+P}(!C||C&&!C.skipNormalize)&&(v.indexOf("%")!==-1&&(b.scheme!==void 0&&(b.scheme=unescape(b.scheme)),b.host!==void 0&&(b.host=unescape(b.host))),b.path&&(b.path=escape(unescape(b.path))),b.fragment&&(b.fragment=encodeURI(decodeURIComponent(b.fragment)))),C&&C.parse&&C.parse(b,m)}else b.error=b.error||"URI can not be parsed.";return b}const g={SCHEMES:a,normalize:l,resolve:u,resolveComponent:c,equal:d,serialize:f,parse:p};return JB.exports=g,JB.exports.default=g,JB.exports.fastUri=g,JB.exports}var j1e;function WRt(){if(j1e)return F4;j1e=1,Object.defineProperty(F4,"__esModule",{value:!0});const t=$Rt();return t.code='require("ajv/dist/runtime/uri").default',F4.default=t,F4}var V1e;function GRt(){return V1e||(V1e=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var e=aG();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return e.KeywordCxt}});var i=_o();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return i._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return i.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return i.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return i.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return i.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return i.CodeGen}});const n=gne(),r=sG(),o=aHe(),a=vne(),s=_o(),l=oG(),u=v$(),c=qo(),d=URt,f=WRt(),h=(U,k)=>new RegExp(U,k);h.code="new RegExp";const p=["removeAdditional","useDefaults","coerceTypes"],g=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),v={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},y={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},m=200;function b(U){var k,X,W,Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e,Ne,ve,pe,fe,me,Ce,Ue,Qe,it;const xt=U.strict,wt=(k=U.code)===null||k===void 0?void 0:k.optimize,$t=wt===!0||wt===void 0?1:wt||0,Mt=(W=(X=U.code)===null||X===void 0?void 0:X.regExp)!==null&&W!==void 0?W:h,rt=(Y=U.uriResolver)!==null&&Y!==void 0?Y:f.default;return{strictSchema:(oe=(te=U.strictSchema)!==null&&te!==void 0?te:xt)!==null&&oe!==void 0?oe:!0,strictNumbers:(ge=(de=U.strictNumbers)!==null&&de!==void 0?de:xt)!==null&&ge!==void 0?ge:!0,strictTypes:(Re=(Ee=U.strictTypes)!==null&&Ee!==void 0?Ee:xt)!==null&&Re!==void 0?Re:"log",strictTuples:(Pe=(Ae=U.strictTuples)!==null&&Ae!==void 0?Ae:xt)!==null&&Pe!==void 0?Pe:"log",strictRequired:(Te=(we=U.strictRequired)!==null&&we!==void 0?we:xt)!==null&&Te!==void 0?Te:!1,code:U.code?{...U.code,optimize:$t,regExp:Mt}:{optimize:$t,regExp:Mt},loopRequired:(ke=U.loopRequired)!==null&&ke!==void 0?ke:m,loopEnum:($e=U.loopEnum)!==null&&$e!==void 0?$e:m,meta:(Ne=U.meta)!==null&&Ne!==void 0?Ne:!0,messages:(ve=U.messages)!==null&&ve!==void 0?ve:!0,inlineRefs:(pe=U.inlineRefs)!==null&&pe!==void 0?pe:!0,schemaId:(fe=U.schemaId)!==null&&fe!==void 0?fe:"$id",addUsedSchema:(me=U.addUsedSchema)!==null&&me!==void 0?me:!0,validateSchema:(Ce=U.validateSchema)!==null&&Ce!==void 0?Ce:!0,validateFormats:(Ue=U.validateFormats)!==null&&Ue!==void 0?Ue:!0,unicodeRegExp:(Qe=U.unicodeRegExp)!==null&&Qe!==void 0?Qe:!0,int32range:(it=U.int32range)!==null&&it!==void 0?it:!0,uriResolver:rt}}class S{constructor(k={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,k=this.opts={...k,...b(k)};const{es5:X,lines:W}=this.opts.code;this.scope=new s.ValueScope({scope:{},prefixes:g,es5:X,lines:W}),this.logger=M(k.logger);const Y=k.validateFormats;k.validateFormats=!1,this.RULES=(0,o.getRules)(),_.call(this,v,k,"NOT SUPPORTED"),_.call(this,y,k,"DEPRECATED","warn"),this._metaOpts=A.call(this),k.formats&&x.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),k.keywords&&E.call(this,k.keywords),typeof k.meta=="object"&&this.addMetaSchema(k.meta),P.call(this),k.validateFormats=Y}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:k,meta:X,schemaId:W}=this.opts;let Y=d;W==="id"&&(Y={...d},Y.id=Y.$id,delete Y.$id),X&&k&&this.addMetaSchema(Y,Y[W],!1)}defaultMeta(){const{meta:k,schemaId:X}=this.opts;return this.opts.defaultMeta=typeof k=="object"?k[X]||k:void 0}validate(k,X){let W;if(typeof k=="string"){if(W=this.getSchema(k),!W)throw new Error(`no schema with key or ref "${k}"`)}else W=this.compile(k);const Y=W(X);return"$async"in W||(this.errors=W.errors),Y}compile(k,X){const W=this._addSchema(k,X);return W.validate||this._compileSchemaEnv(W)}compileAsync(k,X){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:W}=this.opts;return Y.call(this,k,X);async function Y(Re,Ae){await te.call(this,Re.$schema);const Pe=this._addSchema(Re,Ae);return Pe.validate||oe.call(this,Pe)}async function te(Re){Re&&!this.getSchema(Re)&&await Y.call(this,{$ref:Re},!0)}async function oe(Re){try{return this._compileSchemaEnv(Re)}catch(Ae){if(!(Ae instanceof r.default))throw Ae;return de.call(this,Ae),await ge.call(this,Ae.missingSchema),oe.call(this,Re)}}function de({missingSchema:Re,missingRef:Ae}){if(this.refs[Re])throw new Error(`AnySchema ${Re} is loaded but ${Ae} cannot be resolved`)}async function ge(Re){const Ae=await Ee.call(this,Re);this.refs[Re]||await te.call(this,Ae.$schema),this.refs[Re]||this.addSchema(Ae,Re,X)}async function Ee(Re){const Ae=this._loading[Re];if(Ae)return Ae;try{return await(this._loading[Re]=W(Re))}finally{delete this._loading[Re]}}}addSchema(k,X,W,Y=this.opts.validateSchema){if(Array.isArray(k)){for(const oe of k)this.addSchema(oe,void 0,W,Y);return this}let te;if(typeof k=="object"){const{schemaId:oe}=this.opts;if(te=k[oe],te!==void 0&&typeof te!="string")throw new Error(`schema ${oe} must be string`)}return X=(0,l.normalizeId)(X||te),this._checkUnique(X),this.schemas[X]=this._addSchema(k,W,X,Y,!0),this}addMetaSchema(k,X,W=this.opts.validateSchema){return this.addSchema(k,X,!0,W),this}validateSchema(k,X){if(typeof k=="boolean")return!0;let W;if(W=k.$schema,W!==void 0&&typeof W!="string")throw new Error("$schema must be a string");if(W=W||this.opts.defaultMeta||this.defaultMeta(),!W)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const Y=this.validate(W,k);if(!Y&&X){const te="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(te);else throw new Error(te)}return Y}getSchema(k){let X;for(;typeof(X=C.call(this,k))=="string";)k=X;if(X===void 0){const{schemaId:W}=this.opts,Y=new a.SchemaEnv({schema:{},schemaId:W});if(X=a.resolveSchema.call(this,Y,k),!X)return;this.refs[k]=X}return X.validate||this._compileSchemaEnv(X)}removeSchema(k){if(k instanceof RegExp)return this._removeAllSchemas(this.schemas,k),this._removeAllSchemas(this.refs,k),this;switch(typeof k){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const X=C.call(this,k);return typeof X=="object"&&this._cache.delete(X.schema),delete this.schemas[k],delete this.refs[k],this}case"object":{const X=k;this._cache.delete(X);let W=k[this.opts.schemaId];return W&&(W=(0,l.normalizeId)(W),delete this.schemas[W],delete this.refs[W]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(k){for(const X of k)this.addKeyword(X);return this}addKeyword(k,X){let W;if(typeof k=="string")W=k,typeof X=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),X.keyword=W);else if(typeof k=="object"&&X===void 0){if(X=k,W=X.keyword,Array.isArray(W)&&!W.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(F.call(this,W,X),!X)return(0,c.eachItem)(W,te=>I.call(this,te)),this;z.call(this,X);const Y={...X,type:(0,u.getJSONTypes)(X.type),schemaType:(0,u.getJSONTypes)(X.schemaType)};return(0,c.eachItem)(W,Y.type.length===0?te=>I.call(this,te,Y):te=>Y.type.forEach(oe=>I.call(this,te,Y,oe))),this}getKeyword(k){const X=this.RULES.all[k];return typeof X=="object"?X.definition:!!X}removeKeyword(k){const{RULES:X}=this;delete X.keywords[k],delete X.all[k];for(const W of X.rules){const Y=W.rules.findIndex(te=>te.keyword===k);Y>=0&&W.rules.splice(Y,1)}return this}addFormat(k,X){return typeof X=="string"&&(X=new RegExp(X)),this.formats[k]=X,this}errorsText(k=this.errors,{separator:X=", ",dataVar:W="data"}={}){return!k||k.length===0?"No errors":k.map(Y=>`${W}${Y.instancePath} ${Y.message}`).reduce((Y,te)=>Y+X+te)}$dataMetaSchema(k,X){const W=this.RULES.all;k=JSON.parse(JSON.stringify(k));for(const Y of X){const te=Y.split("/").slice(1);let oe=k;for(const de of te)oe=oe[de];for(const de in W){const ge=W[de];if(typeof ge!="object")continue;const{$data:Ee}=ge.definition,Re=oe[de];Ee&&Re&&(oe[de]=H(Re))}}return k}_removeAllSchemas(k,X){for(const W in k){const Y=k[W];(!X||X.test(W))&&(typeof Y=="string"?delete k[W]:Y&&!Y.meta&&(this._cache.delete(Y.schema),delete k[W]))}}_addSchema(k,X,W,Y=this.opts.validateSchema,te=this.opts.addUsedSchema){let oe;const{schemaId:de}=this.opts;if(typeof k=="object")oe=k[de];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof k!="boolean")throw new Error("schema must be object or boolean")}let ge=this._cache.get(k);if(ge!==void 0)return ge;W=(0,l.normalizeId)(oe||W);const Ee=l.getSchemaRefs.call(this,k,W);return ge=new a.SchemaEnv({schema:k,schemaId:de,meta:X,baseId:W,localRefs:Ee}),this._cache.set(ge.schema,ge),te&&!W.startsWith("#")&&(W&&this._checkUnique(W),this.refs[W]=ge),Y&&this.validateSchema(k,!0),ge}_checkUnique(k){if(this.schemas[k]||this.refs[k])throw new Error(`schema with key or id "${k}" already exists`)}_compileSchemaEnv(k){if(k.meta?this._compileMetaSchema(k):a.compileSchema.call(this,k),!k.validate)throw new Error("ajv implementation error");return k.validate}_compileMetaSchema(k){const X=this.opts;this.opts=this._metaOpts;try{a.compileSchema.call(this,k)}finally{this.opts=X}}}S.ValidationError=n.default,S.MissingRefError=r.default,t.default=S;function _(U,k,X,W="error"){for(const Y in U){const te=Y;te in k&&this.logger[W](`${X}: option ${Y}. ${U[te]}`)}}function C(U){return U=(0,l.normalizeId)(U),this.schemas[U]||this.refs[U]}function P(){const U=this.opts.schemas;if(U)if(Array.isArray(U))this.addSchema(U);else for(const k in U)this.addSchema(U[k],k)}function x(){for(const U in this.opts.formats){const k=this.opts.formats[U];k&&this.addFormat(U,k)}}function E(U){if(Array.isArray(U)){this.addVocabulary(U);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const k in U){const X=U[k];X.keyword||(X.keyword=k),this.addKeyword(X)}}function A(){const U={...this.opts};for(const k of p)delete U[k];return U}const R={log(){},warn(){},error(){}};function M(U){if(U===!1)return R;if(U===void 0)return console;if(U.log&&U.warn&&U.error)return U;throw new Error("logger must implement log, warn and error methods")}const D=/^[a-z_$][a-z0-9_$:-]*$/i;function F(U,k){const{RULES:X}=this;if((0,c.eachItem)(U,W=>{if(X.keywords[W])throw new Error(`Keyword ${W} is already defined`);if(!D.test(W))throw new Error(`Keyword ${W} has invalid name`)}),!!k&&k.$data&&!("code"in k||"validate"in k))throw new Error('$data keyword must have "code" or "validate" function')}function I(U,k,X){var W;const Y=k==null?void 0:k.post;if(X&&Y)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:te}=this;let oe=Y?te.post:te.rules.find(({type:ge})=>ge===X);if(oe||(oe={type:X,rules:[]},te.rules.push(oe)),te.keywords[U]=!0,!k)return;const de={keyword:U,definition:{...k,type:(0,u.getJSONTypes)(k.type),schemaType:(0,u.getJSONTypes)(k.schemaType)}};k.before?V.call(this,oe,de,k.before):oe.rules.push(de),te.all[U]=de,(W=k.implements)===null||W===void 0||W.forEach(ge=>this.addKeyword(ge))}function V(U,k,X){const W=U.rules.findIndex(Y=>Y.keyword===X);W>=0?U.rules.splice(W,0,k):(U.rules.push(k),this.logger.warn(`rule ${X} is not defined`))}function z(U){let{metaSchema:k}=U;k!==void 0&&(U.$data&&this.opts.$data&&(k=H(k)),U.validateSchema=this.compile(k,!0))}const G={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function H(U){return{anyOf:[U,G]}}})(R7)),R7}var B4={},j4={},V4={},H1e;function YRt(){if(H1e)return V4;H1e=1,Object.defineProperty(V4,"__esModule",{value:!0});const t={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};return V4.default=t,V4}var B_={},U1e;function qRt(){if(U1e)return B_;U1e=1,Object.defineProperty(B_,"__esModule",{value:!0}),B_.callRef=B_.getValidate=void 0;const t=sG(),e=Gv(),i=_o(),n=aC(),r=vne(),o=qo(),a={keyword:"$ref",schemaType:"string",code(u){const{gen:c,schema:d,it:f}=u,{baseId:h,schemaEnv:p,validateName:g,opts:v,self:y}=f,{root:m}=p;if((d==="#"||d==="#/")&&h===m.baseId)return S();const b=r.resolveRef.call(y,m,h,d);if(b===void 0)throw new t.default(f.opts.uriResolver,h,d);if(b instanceof r.SchemaEnv)return _(b);return C(b);function S(){if(p===m)return l(u,g,p,p.$async);const P=c.scopeValue("root",{ref:m});return l(u,(0,i._)`${P}.validate`,m,m.$async)}function _(P){const x=s(u,P);l(u,x,P,P.$async)}function C(P){const x=c.scopeValue("schema",v.code.source===!0?{ref:P,code:(0,i.stringify)(P)}:{ref:P}),E=c.name("valid"),A=u.subschema({schema:P,dataTypes:[],schemaPath:i.nil,topSchemaRef:x,errSchemaPath:d},E);u.mergeEvaluated(A),u.ok(E)}}};function s(u,c){const{gen:d}=u;return c.validate?d.scopeValue("validate",{ref:c.validate}):(0,i._)`${d.scopeValue("wrapper",{ref:c})}.validate`}B_.getValidate=s;function l(u,c,d,f){const{gen:h,it:p}=u,{allErrors:g,schemaEnv:v,opts:y}=p,m=y.passContext?n.default.this:i.nil;f?b():S();function b(){if(!v.$async)throw new Error("async schema referenced by sync schema");const P=h.let("valid");h.try(()=>{h.code((0,i._)`await ${(0,e.callValidateCode)(u,c,m)}`),C(c),g||h.assign(P,!0)},x=>{h.if((0,i._)`!(${x} instanceof ${p.ValidationError})`,()=>h.throw(x)),_(x),g||h.assign(P,!1)}),u.ok(P)}function S(){u.result((0,e.callValidateCode)(u,c,m),()=>C(c),()=>_(c))}function _(P){const x=(0,i._)`${P}.errors`;h.assign(n.default.vErrors,(0,i._)`${n.default.vErrors} === null ? ${x} : ${n.default.vErrors}.concat(${x})`),h.assign(n.default.errors,(0,i._)`${n.default.vErrors}.length`)}function C(P){var x;if(!p.opts.unevaluated)return;const E=(x=d==null?void 0:d.validate)===null||x===void 0?void 0:x.evaluated;if(p.props!==!0)if(E&&!E.dynamicProps)E.props!==void 0&&(p.props=o.mergeEvaluated.props(h,E.props,p.props));else{const A=h.var("props",(0,i._)`${P}.evaluated.props`);p.props=o.mergeEvaluated.props(h,A,p.props,i.Name)}if(p.items!==!0)if(E&&!E.dynamicItems)E.items!==void 0&&(p.items=o.mergeEvaluated.items(h,E.items,p.items));else{const A=h.var("items",(0,i._)`${P}.evaluated.items`);p.items=o.mergeEvaluated.items(h,A,p.items,i.Name)}}}return B_.callRef=l,B_.default=a,B_}var z1e;function XRt(){if(z1e)return j4;z1e=1,Object.defineProperty(j4,"__esModule",{value:!0});const t=YRt(),e=qRt(),i=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",t.default,e.default];return j4.default=i,j4}var H4={},U4={},$1e;function KRt(){if($1e)return U4;$1e=1,Object.defineProperty(U4,"__esModule",{value:!0});const t=_o(),e=t.operators,i={maximum:{okStr:"<=",ok:e.LTE,fail:e.GT},minimum:{okStr:">=",ok:e.GTE,fail:e.LT},exclusiveMaximum:{okStr:"<",ok:e.LT,fail:e.GTE},exclusiveMinimum:{okStr:">",ok:e.GT,fail:e.LTE}},n={message:({keyword:o,schemaCode:a})=>(0,t.str)`must be ${i[o].okStr} ${a}`,params:({keyword:o,schemaCode:a})=>(0,t._)`{comparison: ${i[o].okStr}, limit: ${a}}`},r={keyword:Object.keys(i),type:"number",schemaType:"number",$data:!0,error:n,code(o){const{keyword:a,data:s,schemaCode:l}=o;o.fail$data((0,t._)`${s} ${i[a].fail} ${l} || isNaN(${s})`)}};return U4.default=r,U4}var z4={},W1e;function ZRt(){if(W1e)return z4;W1e=1,Object.defineProperty(z4,"__esModule",{value:!0});const t=_o(),i={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:n})=>(0,t.str)`must be multiple of ${n}`,params:({schemaCode:n})=>(0,t._)`{multipleOf: ${n}}`},code(n){const{gen:r,data:o,schemaCode:a,it:s}=n,l=s.opts.multipleOfPrecision,u=r.let("res"),c=l?(0,t._)`Math.abs(Math.round(${u}) - ${u}) > 1e-${l}`:(0,t._)`${u} !== parseInt(${u})`;n.fail$data((0,t._)`(${a} === 0 || (${u} = ${o}/${a}, ${c}))`)}};return z4.default=i,z4}var $4={},W4={},G1e;function JRt(){if(G1e)return W4;G1e=1,Object.defineProperty(W4,"__esModule",{value:!0});function t(e){const i=e.length;let n=0,r=0,o;for(;r<i;)n++,o=e.charCodeAt(r++),o>=55296&&o<=56319&&r<i&&(o=e.charCodeAt(r),(o&64512)===56320&&r++);return n}return W4.default=t,t.code='require("ajv/dist/runtime/ucs2length").default',W4}var Y1e;function QRt(){if(Y1e)return $4;Y1e=1,Object.defineProperty($4,"__esModule",{value:!0});const t=_o(),e=qo(),i=JRt(),r={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:o,schemaCode:a}){const s=o==="maxLength"?"more":"fewer";return(0,t.str)`must NOT have ${s} than ${a} characters`},params:({schemaCode:o})=>(0,t._)`{limit: ${o}}`},code(o){const{keyword:a,data:s,schemaCode:l,it:u}=o,c=a==="maxLength"?t.operators.GT:t.operators.LT,d=u.opts.unicode===!1?(0,t._)`${s}.length`:(0,t._)`${(0,e.useFunc)(o.gen,i.default)}(${s})`;o.fail$data((0,t._)`${d} ${c} ${l}`)}};return $4.default=r,$4}var G4={},q1e;function eMt(){if(q1e)return G4;q1e=1,Object.defineProperty(G4,"__esModule",{value:!0});const t=Gv(),e=qo(),i=_o(),r={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:o})=>(0,i.str)`must match pattern "${o}"`,params:({schemaCode:o})=>(0,i._)`{pattern: ${o}}`},code(o){const{gen:a,data:s,$data:l,schema:u,schemaCode:c,it:d}=o,f=d.opts.unicodeRegExp?"u":"";if(l){const{regExp:h}=d.opts.code,p=h.code==="new RegExp"?(0,i._)`new RegExp`:(0,e.useFunc)(a,h),g=a.let("valid");a.try(()=>a.assign(g,(0,i._)`${p}(${c}, ${f}).test(${s})`),()=>a.assign(g,!1)),o.fail$data((0,i._)`!${g}`)}else{const h=(0,t.usePattern)(o,u);o.fail$data((0,i._)`!${h}.test(${s})`)}}};return G4.default=r,G4}var Y4={},X1e;function tMt(){if(X1e)return Y4;X1e=1,Object.defineProperty(Y4,"__esModule",{value:!0});const t=_o(),i={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:n,schemaCode:r}){const o=n==="maxProperties"?"more":"fewer";return(0,t.str)`must NOT have ${o} than ${r} properties`},params:({schemaCode:n})=>(0,t._)`{limit: ${n}}`},code(n){const{keyword:r,data:o,schemaCode:a}=n,s=r==="maxProperties"?t.operators.GT:t.operators.LT;n.fail$data((0,t._)`Object.keys(${o}).length ${s} ${a}`)}};return Y4.default=i,Y4}var q4={},K1e;function rMt(){if(K1e)return q4;K1e=1,Object.defineProperty(q4,"__esModule",{value:!0});const t=Gv(),e=_o(),i=qo(),r={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:o}})=>(0,e.str)`must have required property '${o}'`,params:({params:{missingProperty:o}})=>(0,e._)`{missingProperty: ${o}}`},code(o){const{gen:a,schema:s,schemaCode:l,data:u,$data:c,it:d}=o,{opts:f}=d;if(!c&&s.length===0)return;const h=s.length>=f.loopRequired;if(d.allErrors?p():g(),f.strictRequired){const m=o.parentSchema.properties,{definedProperties:b}=o.it;for(const S of s)if((m==null?void 0:m[S])===void 0&&!b.has(S)){const _=d.schemaEnv.baseId+d.errSchemaPath,C=`required property "${S}" is not defined at "${_}" (strictRequired)`;(0,i.checkStrictMode)(d,C,d.opts.strictRequired)}}function p(){if(h||c)o.block$data(e.nil,v);else for(const m of s)(0,t.checkReportMissingProp)(o,m)}function g(){const m=a.let("missing");if(h||c){const b=a.let("valid",!0);o.block$data(b,()=>y(m,b)),o.ok(b)}else a.if((0,t.checkMissingProp)(o,s,m)),(0,t.reportMissingProp)(o,m),a.else()}function v(){a.forOf("prop",l,m=>{o.setParams({missingProperty:m}),a.if((0,t.noPropertyInData)(a,u,m,f.ownProperties),()=>o.error())})}function y(m,b){o.setParams({missingProperty:m}),a.forOf(m,l,()=>{a.assign(b,(0,t.propertyInData)(a,u,m,f.ownProperties)),a.if((0,e.not)(b),()=>{o.error(),a.break()})},e.nil)}}};return q4.default=r,q4}var X4={},Z1e;function iMt(){if(Z1e)return X4;Z1e=1,Object.defineProperty(X4,"__esModule",{value:!0});const t=_o(),i={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:n,schemaCode:r}){const o=n==="maxItems"?"more":"fewer";return(0,t.str)`must NOT have ${o} than ${r} items`},params:({schemaCode:n})=>(0,t._)`{limit: ${n}}`},code(n){const{keyword:r,data:o,schemaCode:a}=n,s=r==="maxItems"?t.operators.GT:t.operators.LT;n.fail$data((0,t._)`${o}.length ${s} ${a}`)}};return X4.default=i,X4}var K4={},Z4={},J1e;function yne(){if(J1e)return Z4;J1e=1,Object.defineProperty(Z4,"__esModule",{value:!0});const t=lHe();return t.code='require("ajv/dist/runtime/equal").default',Z4.default=t,Z4}var Q1e;function nMt(){if(Q1e)return K4;Q1e=1,Object.defineProperty(K4,"__esModule",{value:!0});const t=v$(),e=_o(),i=qo(),n=yne(),o={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:a,j:s}})=>(0,e.str)`must NOT have duplicate items (items ## ${s} and ${a} are identical)`,params:({params:{i:a,j:s}})=>(0,e._)`{i: ${a}, j: ${s}}`},code(a){const{gen:s,data:l,$data:u,schema:c,parentSchema:d,schemaCode:f,it:h}=a;if(!u&&!c)return;const p=s.let("valid"),g=d.items?(0,t.getSchemaTypes)(d.items):[];a.block$data(p,v,(0,e._)`${f} === false`),a.ok(p);function v(){const S=s.let("i",(0,e._)`${l}.length`),_=s.let("j");a.setParams({i:S,j:_}),s.assign(p,!0),s.if((0,e._)`${S} > 1`,()=>(y()?m:b)(S,_))}function y(){return g.length>0&&!g.some(S=>S==="object"||S==="array")}function m(S,_){const C=s.name("item"),P=(0,t.checkDataTypes)(g,C,h.opts.strictNumbers,t.DataType.Wrong),x=s.const("indices",(0,e._)`{}`);s.for((0,e._)`;${S}--;`,()=>{s.let(C,(0,e._)`${l}[${S}]`),s.if(P,(0,e._)`continue`),g.length>1&&s.if((0,e._)`typeof ${C} == "string"`,(0,e._)`${C} += "_"`),s.if((0,e._)`typeof ${x}[${C}] == "number"`,()=>{s.assign(_,(0,e._)`${x}[${C}]`),a.error(),s.assign(p,!1).break()}).code((0,e._)`${x}[${C}] = ${S}`)})}function b(S,_){const C=(0,i.useFunc)(s,n.default),P=s.name("outer");s.label(P).for((0,e._)`;${S}--;`,()=>s.for((0,e._)`${_} = ${S}; ${_}--;`,()=>s.if((0,e._)`${C}(${l}[${S}], ${l}[${_}])`,()=>{a.error(),s.assign(p,!1).break(P)})))}}};return K4.default=o,K4}var J4={},exe;function oMt(){if(exe)return J4;exe=1,Object.defineProperty(J4,"__esModule",{value:!0});const t=_o(),e=qo(),i=yne(),r={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:o})=>(0,t._)`{allowedValue: ${o}}`},code(o){const{gen:a,data:s,$data:l,schemaCode:u,schema:c}=o;l||c&&typeof c=="object"?o.fail$data((0,t._)`!${(0,e.useFunc)(a,i.default)}(${s}, ${u})`):o.fail((0,t._)`${c} !== ${s}`)}};return J4.default=r,J4}var Q4={},txe;function aMt(){if(txe)return Q4;txe=1,Object.defineProperty(Q4,"__esModule",{value:!0});const t=_o(),e=qo(),i=yne(),r={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:o})=>(0,t._)`{allowedValues: ${o}}`},code(o){const{gen:a,data:s,$data:l,schema:u,schemaCode:c,it:d}=o;if(!l&&u.length===0)throw new Error("enum must have non-empty array");const f=u.length>=d.opts.loopEnum;let h;const p=()=>h??(h=(0,e.useFunc)(a,i.default));let g;if(f||l)g=a.let("valid"),o.block$data(g,v);else{if(!Array.isArray(u))throw new Error("ajv implementation error");const m=a.const("vSchema",c);g=(0,t.or)(...u.map((b,S)=>y(m,S)))}o.pass(g);function v(){a.assign(g,!1),a.forOf("v",c,m=>a.if((0,t._)`${p()}(${s}, ${m})`,()=>a.assign(g,!0).break()))}function y(m,b){const S=u[b];return typeof S=="object"&&S!==null?(0,t._)`${p()}(${s}, ${m}[${b}])`:(0,t._)`${s} === ${S}`}}};return Q4.default=r,Q4}var rxe;function sMt(){if(rxe)return H4;rxe=1,Object.defineProperty(H4,"__esModule",{value:!0});const t=KRt(),e=ZRt(),i=QRt(),n=eMt(),r=tMt(),o=rMt(),a=iMt(),s=nMt(),l=oMt(),u=aMt(),c=[t.default,e.default,i.default,n.default,r.default,o.default,a.default,s.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},l.default,u.default];return H4.default=c,H4}var eU={},uL={},ixe;function cHe(){if(ixe)return uL;ixe=1,Object.defineProperty(uL,"__esModule",{value:!0}),uL.validateAdditionalItems=void 0;const t=_o(),e=qo(),n={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:o}})=>(0,t.str)`must NOT have more than ${o} items`,params:({params:{len:o}})=>(0,t._)`{limit: ${o}}`},code(o){const{parentSchema:a,it:s}=o,{items:l}=a;if(!Array.isArray(l)){(0,e.checkStrictMode)(s,'"additionalItems" is ignored when "items" is not an array of schemas');return}r(o,l)}};function r(o,a){const{gen:s,schema:l,data:u,keyword:c,it:d}=o;d.items=!0;const f=s.const("len",(0,t._)`${u}.length`);if(l===!1)o.setParams({len:a.length}),o.pass((0,t._)`${f} <= ${a.length}`);else if(typeof l=="object"&&!(0,e.alwaysValidSchema)(d,l)){const p=s.var("valid",(0,t._)`${f} <= ${a.length}`);s.if((0,t.not)(p),()=>h(p)),o.ok(p)}function h(p){s.forRange("i",a.length,f,g=>{o.subschema({keyword:c,dataProp:g,dataPropType:e.Type.Num},p),d.allErrors||s.if((0,t.not)(p),()=>s.break())})}}return uL.validateAdditionalItems=r,uL.default=n,uL}var tU={},cL={},nxe;function dHe(){if(nxe)return cL;nxe=1,Object.defineProperty(cL,"__esModule",{value:!0}),cL.validateTuple=void 0;const t=_o(),e=qo(),i=Gv(),n={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(o){const{schema:a,it:s}=o;if(Array.isArray(a))return r(o,"additionalItems",a);s.items=!0,!(0,e.alwaysValidSchema)(s,a)&&o.ok((0,i.validateArray)(o))}};function r(o,a,s=o.schema){const{gen:l,parentSchema:u,data:c,keyword:d,it:f}=o;g(u),f.opts.unevaluated&&s.length&&f.items!==!0&&(f.items=e.mergeEvaluated.items(l,s.length,f.items));const h=l.name("valid"),p=l.const("len",(0,t._)`${c}.length`);s.forEach((v,y)=>{(0,e.alwaysValidSchema)(f,v)||(l.if((0,t._)`${p} > ${y}`,()=>o.subschema({keyword:d,schemaProp:y,dataProp:y},h)),o.ok(h))});function g(v){const{opts:y,errSchemaPath:m}=f,b=s.length,S=b===v.minItems&&(b===v.maxItems||v[a]===!1);if(y.strictTuples&&!S){const _=`"${d}" is ${b}-tuple, but minItems or maxItems/${a} are not specified or different at path "${m}"`;(0,e.checkStrictMode)(f,_,y.strictTuples)}}}return cL.validateTuple=r,cL.default=n,cL}var oxe;function lMt(){if(oxe)return tU;oxe=1,Object.defineProperty(tU,"__esModule",{value:!0});const t=dHe(),e={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:i=>(0,t.validateTuple)(i,"items")};return tU.default=e,tU}var rU={},axe;function uMt(){if(axe)return rU;axe=1,Object.defineProperty(rU,"__esModule",{value:!0});const t=_o(),e=qo(),i=Gv(),n=cHe(),o={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:a}})=>(0,t.str)`must NOT have more than ${a} items`,params:({params:{len:a}})=>(0,t._)`{limit: ${a}}`},code(a){const{schema:s,parentSchema:l,it:u}=a,{prefixItems:c}=l;u.items=!0,!(0,e.alwaysValidSchema)(u,s)&&(c?(0,n.validateAdditionalItems)(a,c):a.ok((0,i.validateArray)(a)))}};return rU.default=o,rU}var iU={},sxe;function cMt(){if(sxe)return iU;sxe=1,Object.defineProperty(iU,"__esModule",{value:!0});const t=_o(),e=qo(),n={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:r,max:o}})=>o===void 0?(0,t.str)`must contain at least ${r} valid item(s)`:(0,t.str)`must contain at least ${r} and no more than ${o} valid item(s)`,params:({params:{min:r,max:o}})=>o===void 0?(0,t._)`{minContains: ${r}}`:(0,t._)`{minContains: ${r}, maxContains: ${o}}`},code(r){const{gen:o,schema:a,parentSchema:s,data:l,it:u}=r;let c,d;const{minContains:f,maxContains:h}=s;u.opts.next?(c=f===void 0?1:f,d=h):c=1;const p=o.const("len",(0,t._)`${l}.length`);if(r.setParams({min:c,max:d}),d===void 0&&c===0){(0,e.checkStrictMode)(u,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(d!==void 0&&c>d){(0,e.checkStrictMode)(u,'"minContains" > "maxContains" is always invalid'),r.fail();return}if((0,e.alwaysValidSchema)(u,a)){let b=(0,t._)`${p} >= ${c}`;d!==void 0&&(b=(0,t._)`${b} && ${p} <= ${d}`),r.pass(b);return}u.items=!0;const g=o.name("valid");d===void 0&&c===1?y(g,()=>o.if(g,()=>o.break())):c===0?(o.let(g,!0),d!==void 0&&o.if((0,t._)`${l}.length > 0`,v)):(o.let(g,!1),v()),r.result(g,()=>r.reset());function v(){const b=o.name("_valid"),S=o.let("count",0);y(b,()=>o.if(b,()=>m(S)))}function y(b,S){o.forRange("i",0,p,_=>{r.subschema({keyword:"contains",dataProp:_,dataPropType:e.Type.Num,compositeRule:!0},b),S()})}function m(b){o.code((0,t._)`${b}++`),d===void 0?o.if((0,t._)`${b} >= ${c}`,()=>o.assign(g,!0).break()):(o.if((0,t._)`${b} > ${d}`,()=>o.assign(g,!1).break()),c===1?o.assign(g,!0):o.if((0,t._)`${b} >= ${c}`,()=>o.assign(g,!0)))}}};return iU.default=n,iU}var V7={},lxe;function dMt(){return lxe||(lxe=1,(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;const e=_o(),i=qo(),n=Gv();t.error={message:({params:{property:l,depsCount:u,deps:c}})=>{const d=u===1?"property":"properties";return(0,e.str)`must have ${d} ${c} when property ${l} is present`},params:({params:{property:l,depsCount:u,deps:c,missingProperty:d}})=>(0,e._)`{property: ${l},
    missingProperty: ${d},
    depsCount: ${u},
    deps: ${c}}`};const r={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(l){const[u,c]=o(l);a(l,u),s(l,c)}};function o({schema:l}){const u={},c={};for(const d in l){if(d==="__proto__")continue;const f=Array.isArray(l[d])?u:c;f[d]=l[d]}return[u,c]}function a(l,u=l.schema){const{gen:c,data:d,it:f}=l;if(Object.keys(u).length===0)return;const h=c.let("missing");for(const p in u){const g=u[p];if(g.length===0)continue;const v=(0,n.propertyInData)(c,d,p,f.opts.ownProperties);l.setParams({property:p,depsCount:g.length,deps:g.join(", ")}),f.allErrors?c.if(v,()=>{for(const y of g)(0,n.checkReportMissingProp)(l,y)}):(c.if((0,e._)`${v} && (${(0,n.checkMissingProp)(l,g,h)})`),(0,n.reportMissingProp)(l,h),c.else())}}t.validatePropertyDeps=a;function s(l,u=l.schema){const{gen:c,data:d,keyword:f,it:h}=l,p=c.name("valid");for(const g in u)(0,i.alwaysValidSchema)(h,u[g])||(c.if((0,n.propertyInData)(c,d,g,h.opts.ownProperties),()=>{const v=l.subschema({keyword:f,schemaProp:g},p);l.mergeValidEvaluated(v,p)},()=>c.var(p,!0)),l.ok(p))}t.validateSchemaDeps=s,t.default=r})(V7)),V7}var nU={},uxe;function fMt(){if(uxe)return nU;uxe=1,Object.defineProperty(nU,"__esModule",{value:!0});const t=_o(),e=qo(),n={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:r})=>(0,t._)`{propertyName: ${r.propertyName}}`},code(r){const{gen:o,schema:a,data:s,it:l}=r;if((0,e.alwaysValidSchema)(l,a))return;const u=o.name("valid");o.forIn("key",s,c=>{r.setParams({propertyName:c}),r.subschema({keyword:"propertyNames",data:c,dataTypes:["string"],propertyName:c,compositeRule:!0},u),o.if((0,t.not)(u),()=>{r.error(!0),l.allErrors||o.break()})}),r.ok(u)}};return nU.default=n,nU}var oU={},cxe;function fHe(){if(cxe)return oU;cxe=1,Object.defineProperty(oU,"__esModule",{value:!0});const t=Gv(),e=_o(),i=aC(),n=qo(),o={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:a})=>(0,e._)`{additionalProperty: ${a.additionalProperty}}`},code(a){const{gen:s,schema:l,parentSchema:u,data:c,errsCount:d,it:f}=a;if(!d)throw new Error("ajv implementation error");const{allErrors:h,opts:p}=f;if(f.props=!0,p.removeAdditional!=="all"&&(0,n.alwaysValidSchema)(f,l))return;const g=(0,t.allSchemaProperties)(u.properties),v=(0,t.allSchemaProperties)(u.patternProperties);y(),a.ok((0,e._)`${d} === ${i.default.errors}`);function y(){s.forIn("key",c,C=>{!g.length&&!v.length?S(C):s.if(m(C),()=>S(C))})}function m(C){let P;if(g.length>8){const x=(0,n.schemaRefOrVal)(f,u.properties,"properties");P=(0,t.isOwnProperty)(s,x,C)}else g.length?P=(0,e.or)(...g.map(x=>(0,e._)`${C} === ${x}`)):P=e.nil;return v.length&&(P=(0,e.or)(P,...v.map(x=>(0,e._)`${(0,t.usePattern)(a,x)}.test(${C})`))),(0,e.not)(P)}function b(C){s.code((0,e._)`delete ${c}[${C}]`)}function S(C){if(p.removeAdditional==="all"||p.removeAdditional&&l===!1){b(C);return}if(l===!1){a.setParams({additionalProperty:C}),a.error(),h||s.break();return}if(typeof l=="object"&&!(0,n.alwaysValidSchema)(f,l)){const P=s.name("valid");p.removeAdditional==="failing"?(_(C,P,!1),s.if((0,e.not)(P),()=>{a.reset(),b(C)})):(_(C,P),h||s.if((0,e.not)(P),()=>s.break()))}}function _(C,P,x){const E={keyword:"additionalProperties",dataProp:C,dataPropType:n.Type.Str};x===!1&&Object.assign(E,{compositeRule:!0,createErrors:!1,allErrors:!1}),a.subschema(E,P)}}};return oU.default=o,oU}var aU={},dxe;function hMt(){if(dxe)return aU;dxe=1,Object.defineProperty(aU,"__esModule",{value:!0});const t=aG(),e=Gv(),i=qo(),n=fHe(),r={keyword:"properties",type:"object",schemaType:"object",code(o){const{gen:a,schema:s,parentSchema:l,data:u,it:c}=o;c.opts.removeAdditional==="all"&&l.additionalProperties===void 0&&n.default.code(new t.KeywordCxt(c,n.default,"additionalProperties"));const d=(0,e.allSchemaProperties)(s);for(const v of d)c.definedProperties.add(v);c.opts.unevaluated&&d.length&&c.props!==!0&&(c.props=i.mergeEvaluated.props(a,(0,i.toHash)(d),c.props));const f=d.filter(v=>!(0,i.alwaysValidSchema)(c,s[v]));if(f.length===0)return;const h=a.name("valid");for(const v of f)p(v)?g(v):(a.if((0,e.propertyInData)(a,u,v,c.opts.ownProperties)),g(v),c.allErrors||a.else().var(h,!0),a.endIf()),o.it.definedProperties.add(v),o.ok(h);function p(v){return c.opts.useDefaults&&!c.compositeRule&&s[v].default!==void 0}function g(v){o.subschema({keyword:"properties",schemaProp:v,dataProp:v},h)}}};return aU.default=r,aU}var sU={},fxe;function pMt(){if(fxe)return sU;fxe=1,Object.defineProperty(sU,"__esModule",{value:!0});const t=Gv(),e=_o(),i=qo(),n=qo(),r={keyword:"patternProperties",type:"object",schemaType:"object",code(o){const{gen:a,schema:s,data:l,parentSchema:u,it:c}=o,{opts:d}=c,f=(0,t.allSchemaProperties)(s),h=f.filter(S=>(0,i.alwaysValidSchema)(c,s[S]));if(f.length===0||h.length===f.length&&(!c.opts.unevaluated||c.props===!0))return;const p=d.strictSchema&&!d.allowMatchingProperties&&u.properties,g=a.name("valid");c.props!==!0&&!(c.props instanceof e.Name)&&(c.props=(0,n.evaluatedPropsToName)(a,c.props));const{props:v}=c;y();function y(){for(const S of f)p&&m(S),c.allErrors?b(S):(a.var(g,!0),b(S),a.if(g))}function m(S){for(const _ in p)new RegExp(S).test(_)&&(0,i.checkStrictMode)(c,`property ${_} matches pattern ${S} (use allowMatchingProperties)`)}function b(S){a.forIn("key",l,_=>{a.if((0,e._)`${(0,t.usePattern)(o,S)}.test(${_})`,()=>{const C=h.includes(S);C||o.subschema({keyword:"patternProperties",schemaProp:S,dataProp:_,dataPropType:n.Type.Str},g),c.opts.unevaluated&&v!==!0?a.assign((0,e._)`${v}[${_}]`,!0):!C&&!c.allErrors&&a.if((0,e.not)(g),()=>a.break())})})}}};return sU.default=r,sU}var lU={},hxe;function gMt(){if(hxe)return lU;hxe=1,Object.defineProperty(lU,"__esModule",{value:!0});const t=qo(),e={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(i){const{gen:n,schema:r,it:o}=i;if((0,t.alwaysValidSchema)(o,r)){i.fail();return}const a=n.name("valid");i.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},a),i.failResult(a,()=>i.reset(),()=>i.error())},error:{message:"must NOT be valid"}};return lU.default=e,lU}var uU={},pxe;function vMt(){if(pxe)return uU;pxe=1,Object.defineProperty(uU,"__esModule",{value:!0});const e={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:Gv().validateUnion,error:{message:"must match a schema in anyOf"}};return uU.default=e,uU}var cU={},gxe;function yMt(){if(gxe)return cU;gxe=1,Object.defineProperty(cU,"__esModule",{value:!0});const t=_o(),e=qo(),n={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:r})=>(0,t._)`{passingSchemas: ${r.passing}}`},code(r){const{gen:o,schema:a,parentSchema:s,it:l}=r;if(!Array.isArray(a))throw new Error("ajv implementation error");if(l.opts.discriminator&&s.discriminator)return;const u=a,c=o.let("valid",!1),d=o.let("passing",null),f=o.name("_valid");r.setParams({passing:d}),o.block(h),r.result(c,()=>r.reset(),()=>r.error(!0));function h(){u.forEach((p,g)=>{let v;(0,e.alwaysValidSchema)(l,p)?o.var(f,!0):v=r.subschema({keyword:"oneOf",schemaProp:g,compositeRule:!0},f),g>0&&o.if((0,t._)`${f} && ${c}`).assign(c,!1).assign(d,(0,t._)`[${d}, ${g}]`).else(),o.if(f,()=>{o.assign(c,!0),o.assign(d,g),v&&r.mergeEvaluated(v,t.Name)})})}}};return cU.default=n,cU}var dU={},vxe;function mMt(){if(vxe)return dU;vxe=1,Object.defineProperty(dU,"__esModule",{value:!0});const t=qo(),e={keyword:"allOf",schemaType:"array",code(i){const{gen:n,schema:r,it:o}=i;if(!Array.isArray(r))throw new Error("ajv implementation error");const a=n.name("valid");r.forEach((s,l)=>{if((0,t.alwaysValidSchema)(o,s))return;const u=i.subschema({keyword:"allOf",schemaProp:l},a);i.ok(a),i.mergeEvaluated(u)})}};return dU.default=e,dU}var fU={},yxe;function bMt(){if(yxe)return fU;yxe=1,Object.defineProperty(fU,"__esModule",{value:!0});const t=_o(),e=qo(),n={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:o})=>(0,t.str)`must match "${o.ifClause}" schema`,params:({params:o})=>(0,t._)`{failingKeyword: ${o.ifClause}}`},code(o){const{gen:a,parentSchema:s,it:l}=o;s.then===void 0&&s.else===void 0&&(0,e.checkStrictMode)(l,'"if" without "then" and "else" is ignored');const u=r(l,"then"),c=r(l,"else");if(!u&&!c)return;const d=a.let("valid",!0),f=a.name("_valid");if(h(),o.reset(),u&&c){const g=a.let("ifClause");o.setParams({ifClause:g}),a.if(f,p("then",g),p("else",g))}else u?a.if(f,p("then")):a.if((0,t.not)(f),p("else"));o.pass(d,()=>o.error(!0));function h(){const g=o.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},f);o.mergeEvaluated(g)}function p(g,v){return()=>{const y=o.subschema({keyword:g},f);a.assign(d,f),o.mergeValidEvaluated(y,d),v?a.assign(v,(0,t._)`${g}`):o.setParams({ifClause:g})}}}};function r(o,a){const s=o.schema[a];return s!==void 0&&!(0,e.alwaysValidSchema)(o,s)}return fU.default=n,fU}var hU={},mxe;function SMt(){if(mxe)return hU;mxe=1,Object.defineProperty(hU,"__esModule",{value:!0});const t=qo(),e={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:i,parentSchema:n,it:r}){n.if===void 0&&(0,t.checkStrictMode)(r,`"${i}" without "if" is ignored`)}};return hU.default=e,hU}var bxe;function _Mt(){if(bxe)return eU;bxe=1,Object.defineProperty(eU,"__esModule",{value:!0});const t=cHe(),e=lMt(),i=dHe(),n=uMt(),r=cMt(),o=dMt(),a=fMt(),s=fHe(),l=hMt(),u=pMt(),c=gMt(),d=vMt(),f=yMt(),h=mMt(),p=bMt(),g=SMt();function v(y=!1){const m=[c.default,d.default,f.default,h.default,p.default,g.default,a.default,s.default,o.default,l.default,u.default];return y?m.push(e.default,n.default):m.push(t.default,i.default),m.push(r.default),m}return eU.default=v,eU}var pU={},gU={},Sxe;function PMt(){if(Sxe)return gU;Sxe=1,Object.defineProperty(gU,"__esModule",{value:!0});const t=_o(),i={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:n})=>(0,t.str)`must match format "${n}"`,params:({schemaCode:n})=>(0,t._)`{format: ${n}}`},code(n,r){const{gen:o,data:a,$data:s,schema:l,schemaCode:u,it:c}=n,{opts:d,errSchemaPath:f,schemaEnv:h,self:p}=c;if(!d.validateFormats)return;s?g():v();function g(){const y=o.scopeValue("formats",{ref:p.formats,code:d.code.formats}),m=o.const("fDef",(0,t._)`${y}[${u}]`),b=o.let("fType"),S=o.let("format");o.if((0,t._)`typeof ${m} == "object" && !(${m} instanceof RegExp)`,()=>o.assign(b,(0,t._)`${m}.type || "string"`).assign(S,(0,t._)`${m}.validate`),()=>o.assign(b,(0,t._)`"string"`).assign(S,m)),n.fail$data((0,t.or)(_(),C()));function _(){return d.strictSchema===!1?t.nil:(0,t._)`${u} && !${S}`}function C(){const P=h.$async?(0,t._)`(${m}.async ? await ${S}(${a}) : ${S}(${a}))`:(0,t._)`${S}(${a})`,x=(0,t._)`(typeof ${S} == "function" ? ${P} : ${S}.test(${a}))`;return(0,t._)`${S} && ${S} !== true && ${b} === ${r} && !${x}`}}function v(){const y=p.formats[l];if(!y){_();return}if(y===!0)return;const[m,b,S]=C(y);m===r&&n.pass(P());function _(){if(d.strictSchema===!1){p.logger.warn(x());return}throw new Error(x());function x(){return`unknown format "${l}" ignored in schema at path "${f}"`}}function C(x){const E=x instanceof RegExp?(0,t.regexpCode)(x):d.code.formats?(0,t._)`${d.code.formats}${(0,t.getProperty)(l)}`:void 0,A=o.scopeValue("formats",{key:l,ref:x,code:E});return typeof x=="object"&&!(x instanceof RegExp)?[x.type||"string",x.validate,(0,t._)`${A}.validate`]:["string",x,A]}function P(){if(typeof y=="object"&&!(y instanceof RegExp)&&y.async){if(!h.$async)throw new Error("async format in sync schema");return(0,t._)`await ${S}(${a})`}return typeof b=="function"?(0,t._)`${S}(${a})`:(0,t._)`${S}.test(${a})`}}}};return gU.default=i,gU}var _xe;function CMt(){if(_xe)return pU;_xe=1,Object.defineProperty(pU,"__esModule",{value:!0});const e=[PMt().default];return pU.default=e,pU}var LO={},Pxe;function TMt(){return Pxe||(Pxe=1,Object.defineProperty(LO,"__esModule",{value:!0}),LO.contentVocabulary=LO.metadataVocabulary=void 0,LO.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],LO.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),LO}var Cxe;function xMt(){if(Cxe)return B4;Cxe=1,Object.defineProperty(B4,"__esModule",{value:!0});const t=XRt(),e=sMt(),i=_Mt(),n=CMt(),r=TMt(),o=[t.default,e.default,(0,i.default)(),n.default,r.metadataVocabulary,r.contentVocabulary];return B4.default=o,B4}var vU={},QB={},Txe;function EMt(){if(Txe)return QB;Txe=1,Object.defineProperty(QB,"__esModule",{value:!0}),QB.DiscrError=void 0;var t;return(function(e){e.Tag="tag",e.Mapping="mapping"})(t||(QB.DiscrError=t={})),QB}var xxe;function wMt(){if(xxe)return vU;xxe=1,Object.defineProperty(vU,"__esModule",{value:!0});const t=_o(),e=EMt(),i=vne(),n=sG(),r=qo(),a={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:s,tagName:l}})=>s===e.DiscrError.Tag?`tag "${l}" must be string`:`value of tag "${l}" must be in oneOf`,params:({params:{discrError:s,tag:l,tagName:u}})=>(0,t._)`{error: ${s}, tag: ${u}, tagValue: ${l}}`},code(s){const{gen:l,data:u,schema:c,parentSchema:d,it:f}=s,{oneOf:h}=d;if(!f.opts.discriminator)throw new Error("discriminator: requires discriminator option");const p=c.propertyName;if(typeof p!="string")throw new Error("discriminator: requires propertyName");if(c.mapping)throw new Error("discriminator: mapping is not supported");if(!h)throw new Error("discriminator: requires oneOf keyword");const g=l.let("valid",!1),v=l.const("tag",(0,t._)`${u}${(0,t.getProperty)(p)}`);l.if((0,t._)`typeof ${v} == "string"`,()=>y(),()=>s.error(!1,{discrError:e.DiscrError.Tag,tag:v,tagName:p})),s.ok(g);function y(){const S=b();l.if(!1);for(const _ in S)l.elseIf((0,t._)`${v} === ${_}`),l.assign(g,m(S[_]));l.else(),s.error(!1,{discrError:e.DiscrError.Mapping,tag:v,tagName:p}),l.endIf()}function m(S){const _=l.name("valid"),C=s.subschema({keyword:"oneOf",schemaProp:S},_);return s.mergeEvaluated(C,t.Name),_}function b(){var S;const _={},C=x(d);let P=!0;for(let R=0;R<h.length;R++){let M=h[R];if(M!=null&&M.$ref&&!(0,r.schemaHasRulesButRef)(M,f.self.RULES)){const F=M.$ref;if(M=i.resolveRef.call(f.self,f.schemaEnv.root,f.baseId,F),M instanceof i.SchemaEnv&&(M=M.schema),M===void 0)throw new n.default(f.opts.uriResolver,f.baseId,F)}const D=(S=M==null?void 0:M.properties)===null||S===void 0?void 0:S[p];if(typeof D!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${p}"`);P=P&&(C||x(M)),E(D,R)}if(!P)throw new Error(`discriminator: "${p}" must be required`);return _;function x({required:R}){return Array.isArray(R)&&R.includes(p)}function E(R,M){if(R.const)A(R.const,M);else if(R.enum)for(const D of R.enum)A(D,M);else throw new Error(`discriminator: "properties/${p}" must have "const" or "enum"`)}function A(R,M){if(typeof R!="string"||R in _)throw new Error(`discriminator: "${p}" values must be unique strings`);_[R]=M}}}};return vU.default=a,vU}const AMt="http://json-schema.org/draft-07/schema#",OMt="http://json-schema.org/draft-07/schema#",DMt="Core schema meta-schema",RMt={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},MMt=["object","boolean"],LMt={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},kMt={$schema:AMt,$id:OMt,title:DMt,definitions:RMt,type:MMt,properties:LMt,default:!0};var Exe;function IMt(){return Exe||(Exe=1,(function(t,e){Object.defineProperty(e,"__esModule",{value:!0}),e.MissingRefError=e.ValidationError=e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=e.Ajv=void 0;const i=GRt(),n=xMt(),r=wMt(),o=kMt,a=["/properties"],s="http://json-schema.org/draft-07/schema";class l extends i.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(p=>this.addVocabulary(p)),this.opts.discriminator&&this.addKeyword(r.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const p=this.opts.$data?this.$dataMetaSchema(o,a):o;this.addMetaSchema(p,s,!1),this.refs["http://json-schema.org/schema"]=s}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(s)?s:void 0)}}e.Ajv=l,t.exports=e=l,t.exports.Ajv=l,Object.defineProperty(e,"__esModule",{value:!0}),e.default=l;var u=aG();Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return u.KeywordCxt}});var c=_o();Object.defineProperty(e,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var d=gne();Object.defineProperty(e,"ValidationError",{enumerable:!0,get:function(){return d.default}});var f=sG();Object.defineProperty(e,"MissingRefError",{enumerable:!0,get:function(){return f.default}})})(L4,L4.exports)),L4.exports}var NMt=IMt();const FMt=wc(NMt),BMt="http://json-schema.org/draft-07/schema#",jMt="remotive-dashboard.schema.json",VMt="Remotive Dashboard Layout",HMt="Schema for Remotive Studio dashboard layout configuration. Compatible with JSON Schema Drafts 4, 6, and 7. To enable strict validation, change all 'additionalProperties: true' to 'additionalProperties: false' throughout this schema.",UMt=`STRICT MODE: This schema uses lenient validation by default (additionalProperties: true). To enable strict validation that rejects unknown properties, search and replace 'additionalProperties": true' with 'additionalProperties": false' in this file.`,zMt={Signal:{type:"object",description:"Reference to a signal by namespace, frame, and signal name",required:["namespace","frame","signal"],properties:{namespace:{type:"string",description:"Signal namespace identifier"},frame:{type:"string",description:"Frame name containing the signal"},signal:{type:"string",description:"Signal name within the frame"}},additionalProperties:!0},Frame:{type:"object",description:"Reference to a signal by namespace, frame, and signal name",required:["namespace","frame"],properties:{namespace:{type:"string",description:"Signal namespace identifier"},frame:{type:"string",description:"Frame name containing the signal"},signals:{type:"array",items:{$ref:"#/definitions/Signal"},description:"List of signals to display in the frame"}},additionalProperties:!0},GridConfig:{type:"object",description:"Grid position and size for panel layout",required:["x","y","w","h"],properties:{x:{type:"integer",minimum:0,description:"X position in grid units"},y:{type:"integer",minimum:0,description:"Y position in grid units"},w:{type:"integer",minimum:1,description:"Width in grid units"},h:{type:"integer",minimum:1,description:"Height in grid units"}},additionalProperties:!0},TimeseriesPanelContent:{type:"object",description:"Data content for a timeseries panel",required:["signals"],properties:{signals:{type:"array",items:{$ref:"#/definitions/Signal"},description:"List of signals to display in the chart"}},additionalProperties:!0},TimeseriesPanelSettings:{type:"object",description:"Display settings for a timeseries panel",properties:{syncChart:{type:"boolean",description:"Whether to sync chart width with global setting. Default: true"},chartWidthSeconds:{type:"number",minimum:1,description:"Per-panel chart width in seconds. Only used when syncChart is false"},useSuggestedMinMax:{type:"boolean",description:"Use signal-defined min/max for Y-axis. Default: false"},maxFps:{type:"number",minimum:5,maximum:120,description:"Max animation frame rate for the chart (increments of 5). Default: 60"}},additionalProperties:!0},GaugePanelContent:{type:"object",description:"Data content for a gauge panel",required:["signals"],properties:{signals:{type:"array",items:{$ref:"#/definitions/Signal"},description:"List of signals to display as gauges"}},additionalProperties:!0},GaugePanelSettings:{type:"object",description:"Display settings for a gauge panel",properties:{height:{type:"number",description:"Height of each gauge row in pixels"}},additionalProperties:!0},MapPanelContent:{type:"object",description:"Data content for a map panel",properties:{signals:{type:"object",description:"Latitude and longitude signal references",properties:{latitude:{$ref:"#/definitions/Signal"},longitude:{$ref:"#/definitions/Signal"}},additionalProperties:!0}},additionalProperties:!0},FrameDistributionPanelContent:{type:"object",description:"Data content for a frame distribution panel",properties:{namespace:{type:"string",description:"The namespace to subscribe to for frame distribution"}},additionalProperties:!0},VideoPanelContent:{type:"object",description:"Data content for a video panel",required:["videoName"],properties:{videoName:{type:"string",description:"A name like 'front-camera' is used to share one dashboard with multiple recordings/videos"},videoFilePath:{type:"string",description:"Path to the video file"},recordingSessionPath:{type:"string",description:"Path to the recording session"}},additionalProperties:!0},TracePanelContent:{type:"object",description:"Data content for a trace panel",required:["frames"],properties:{frames:{type:"array",items:{$ref:"#/definitions/Frame"},description:"List of frames to display in the trace panel"}},additionalProperties:!0},TracePanelSettings:{type:"object",description:"Display settings for a trace panel",properties:{sortOrder:{type:"string",enum:["newest-first","oldest-first"],description:"Sort order for the trace panel. Default: newest-first"},groupByFrame:{type:"boolean",description:"Whether to group frames by frame name. Default: false"},expandSignals:{type:"boolean",description:"Whether to expand or collapse signals. Default: false"},bufferSize:{type:"integer",minimum:100,description:"The number of entries to display in the trace panel. Default: 10000"}},additionalProperties:!0},TimeseriesPanelConfig:{type:"object",description:"Timeseries chart panel configuration",required:["type"],properties:{type:{type:"string",enum:["timeseries"],description:"Panel type identifier"},content:{$ref:"#/definitions/TimeseriesPanelContent"},settings:{$ref:"#/definitions/TimeseriesPanelSettings"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},GaugePanelConfig:{type:"object",description:"Gauge panel configuration for displaying signal values",required:["type"],properties:{type:{type:"string",enum:["gauge"],description:"Panel type identifier"},content:{$ref:"#/definitions/GaugePanelContent"},settings:{$ref:"#/definitions/GaugePanelSettings"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},MapPanelConfig:{type:"object",description:"Map panel configuration for displaying geographic data",required:["type"],properties:{type:{type:"string",enum:["map"],description:"Panel type identifier"},content:{$ref:"#/definitions/MapPanelContent"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},FrameDistributionPanelConfig:{type:"object",description:"Frame distribution panel for CAN frame visualization",required:["type"],properties:{type:{type:"string",enum:["frameDistribution"],description:"Panel type identifier"},content:{$ref:"#/definitions/FrameDistributionPanelContent"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},VideoPanelConfig:{type:"object",description:"Video panel configuration (recording-specific, not portable between recordings)",required:["type"],properties:{type:{type:"string",enum:["video"],description:"Panel type identifier"},content:{$ref:"#/definitions/VideoPanelContent"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},TracePanelConfig:{type:"object",description:"Trace panel configuration",required:["type"],properties:{type:{type:"string",enum:["trace"],description:"Panel type identifier"},content:{$ref:"#/definitions/TracePanelContent"},settings:{$ref:"#/definitions/TracePanelSettings"},grid:{$ref:"#/definitions/GridConfig"}},additionalProperties:!0},PanelConfig:{type:"object",description:"Union of all panel configuration types",discriminator:{propertyName:"type"},oneOf:[{$ref:"#/definitions/TimeseriesPanelConfig"},{$ref:"#/definitions/GaugePanelConfig"},{$ref:"#/definitions/MapPanelConfig"},{$ref:"#/definitions/FrameDistributionPanelConfig"},{$ref:"#/definitions/VideoPanelConfig"},{$ref:"#/definitions/TracePanelConfig"}]}},$Mt="object",WMt=["schema","panels"],GMt={schema:{type:"string",enum:["remotive-dashboard:0.1"],description:"Schema identifier and version (format: name:version)"},name:{type:"string",description:"Optional name for the dashboard layout"},chartWidthSeconds:{type:"number",minimum:1,description:"Global chart width in seconds for synced timeseries panels. Default: 30"},panels:{type:"array",items:{$ref:"#/definitions/PanelConfig"},description:"List of panel configurations"}},YMt=!0,hHe={$schema:BMt,$id:jMt,title:VMt,description:HMt,$comment:UMt,definitions:zMt,type:$Mt,required:WMt,properties:GMt,additionalProperties:YMt},pHe=new FMt({allErrors:!0,verbose:!0,strict:!0,discriminator:!0}),H7=pHe.compile(hHe),mne=JSON.parse(JSON.stringify(hHe));delete mne.$id;function gHe(t){typeof t=="object"&&t!==null&&(t.additionalProperties===!0&&(t.additionalProperties=!1),Object.values(t).forEach(gHe))}gHe(mne);const U7=pHe.compile(mne);function vHe(t){const e=t.instancePath||"(root)",i=t.message||"unknown error";switch(t.keyword){case"required":return`${e}: missing required property '${t.params.missingProperty}'`;case"enum":return`${e}: ${i}. Allowed values: ${JSON.stringify(t.params.allowedValues)}`;case"type":return`${e}: ${i}`;case"additionalProperties":return`${e}: unexpected property '${t.params.additionalProperty}'`;case"oneOf":return`${e}: must match exactly one panel type schema`;default:return`${e}: ${i}`}}function qMt(t){const e=new Set,i=[];for(const n of t){const r=vHe(n);e.has(r)||(e.add(r),i.push(n))}return i}function XMt(t){if(!H7(t)){const r=H7.errors?qMt(H7.errors):[];return{valid:!1,errors:r.length>0?r.map(vHe):["Unknown validation error"]}}const i=U7(t),n=[];if(!i&&U7.errors){for(const r of U7.errors)if(r.keyword==="additionalProperties"){const o=r.instancePath||"(root)";n.push(`${o}: unknown property '${r.params.additionalProperty}'`)}}return{valid:!0,warnings:n.length>0?n:void 0}}function y$(t){return{namespace:t.namespace,frame:t.frameName,signal:t.name}}function m$(t,e){return e.find(i=>i.namespace===t.namespace&&i.frameName===t.frame&&i.name===t.signal)}function KMt(t,e){return e.find(i=>i.namespace===t.namespace&&i.name===t.frame)}function b$(t){return`${t.namespace}:${t.frame}:${t.signal}`}function ZMt(t){return`${t.namespace}:${t.frame}`}function XI(t){return{x:t.x,y:t.y,w:t.w,h:t.h}}function JMt(t){switch(t.type){case"timeseries":return QMt(t);case"gauge":return eLt(t);case"map":return tLt(t);case"frame-distribution":return rLt(t);case"video":return iLt(t);case"trace":return nLt(t)}}function QMt(t){const e={useSuggestedMinMax:t.useSuggestedMinMax,syncChart:t.syncCharts,chartWidthSeconds:t.chartWidthSeconds,maxFps:t.maxFps},i=[...t.signals.map(y$),...t.unresolvedSignals||[]];return{type:"timeseries",...i.length>0?{content:{signals:i}}:{},settings:e,grid:XI(t.grid)}}function eLt(t){const e={};t.heightConfig!==void 0&&(e.height=t.heightConfig);const i=[...t.signals.map(y$),...t.unresolvedSignals||[]];return{type:"gauge",...i.length>0?{content:{signals:i}}:{},...Object.keys(e).length>0?{settings:e}:{},grid:XI(t.grid)}}function tLt(t){var r,o,a,s;const e={type:"map",grid:XI(t.grid)},i=t.signals.latitude||((r=t.unresolvedSignals)==null?void 0:r.latitude),n=t.signals.longitude||((o=t.unresolvedSignals)==null?void 0:o.longitude);return(i||n)&&(e.content={signals:{}},t.signals.latitude?e.content.signals.latitude=y$(t.signals.latitude):(a=t.unresolvedSignals)!=null&&a.latitude&&(e.content.signals.latitude=t.unresolvedSignals.latitude),t.signals.longitude?e.content.signals.longitude=y$(t.signals.longitude):(s=t.unresolvedSignals)!=null&&s.longitude&&(e.content.signals.longitude=t.unresolvedSignals.longitude)),e}function rLt(t){const e={type:"frameDistribution",grid:XI(t.grid)};return t.selectedNamespace&&(e.content={namespace:t.selectedNamespace}),e}function iLt(t){const e={type:"video",grid:XI(t.grid)};return t.videoName&&(e.content={videoName:t.videoName,...t.videoFilePath?{videoFilePath:t.videoFilePath}:{},...t.recordingSessionPath?{recordingSessionPath:t.recordingSessionPath}:{}}),e}function nLt(t){const e={groupByFrame:t.groupByFrame??!1,expandSignals:t.expandSignals??!1,bufferSize:t.bufferSize,sortOrder:t.sortOrder??"newest-first"};return{type:"trace",...t.frames.length>0?{content:{frames:t.frames}}:{},settings:e,grid:XI(t.grid)}}function oLt(t,e={},i){const{includeVideoPanels:n=!1,name:r}=e,o={schema:nHe,panels:[]};r&&r.trim()&&(o.name=r.trim()),i!==void 0&&i!==xRt.chartWidthSeconds&&(o.chartWidthSeconds=i);for(const a of t){if(a.type==="video"&&!n)continue;const s=JMt(a);s&&o.panels.push(s)}return o}function aLt(t,e){switch(t.type){case"timeseries":return sLt(t,e);case"gauge":return lLt(t,e);case"map":return uLt(t,e);case"frameDistribution":return cLt(t);case"video":return dLt(t);case"trace":return fLt(t,e);default:return null}}function sLt(t,e){var o,a,s,l,u;const i=[],n=[];for(const c of((o=t.content)==null?void 0:o.signals)??[]){const d=m$(c,e.availableSignals);d?i.push(d):(n.push(c),e.warnings.push(`Signal not found: ${b$(c)}`))}const r=HVe({id:crypto.randomUUID(),type:"timeseries",grid:t.grid??{...qI.timeseries}});return{...r,signals:i,useSuggestedMinMax:((a=t.settings)==null?void 0:a.useSuggestedMinMax)??r.useSuggestedMinMax,syncCharts:((s=t.settings)==null?void 0:s.syncChart)??r.syncCharts,chartWidthSeconds:((l=t.settings)==null?void 0:l.chartWidthSeconds)||r.chartWidthSeconds,maxFps:((u=t.settings)==null?void 0:u.maxFps)??r.maxFps,unresolvedSignals:n.length>0?n:void 0}}function lLt(t,e){var o,a;const i=[],n=[];for(const s of((o=t.content)==null?void 0:o.signals)??[]){const l=m$(s,e.availableSignals);l?i.push(l):(n.push(s),e.warnings.push(`Signal not found: ${b$(s)}`))}const r=$Ve({id:crypto.randomUUID(),type:"gauge",grid:t.grid??{...qI.gauge}});return{...r,signals:i,heightConfig:((a=t.settings)==null?void 0:a.height)??r.heightConfig,unresolvedSignals:n.length>0?n:void 0}}function uLt(t,e){var s,l,u,c;let i,n;const r={};(l=(s=t.content)==null?void 0:s.signals)!=null&&l.latitude&&(i=m$(t.content.signals.latitude,e.availableSignals),i||(r.latitude=t.content.signals.latitude,e.warnings.push(`Latitude signal not found: ${b$(t.content.signals.latitude)}`))),(c=(u=t.content)==null?void 0:u.signals)!=null&&c.longitude&&(n=m$(t.content.signals.longitude,e.availableSignals),n||(r.longitude=t.content.signals.longitude,e.warnings.push(`Longitude signal not found: ${b$(t.content.signals.longitude)}`)));const o=r.latitude||r.longitude;return{...UVe({id:crypto.randomUUID(),type:"map",grid:t.grid??{...qI.map}}),signals:{latitude:i,longitude:n},unresolvedSignals:o?r:void 0}}function cLt(t,e){var n;return{...WVe({id:crypto.randomUUID(),type:"frame-distribution",grid:t.grid??{...qI.frameDistribution}}),selectedNamespace:(n=t.content)==null?void 0:n.namespace}}function dLt(t,e){var n,r,o;return{...zVe({id:crypto.randomUUID(),type:"video",grid:t.grid??{...qI.video}}),videoFilePath:(n=t.content)==null?void 0:n.videoFilePath,recordingSessionPath:(r=t.content)==null?void 0:r.recordingSessionPath,videoName:(o=t.content)==null?void 0:o.videoName}}function fLt(t,e){var o,a,s,l,u;const i=[],n=[];for(const c of((o=t.content)==null?void 0:o.frames)??[])KMt(c,e.availableFrames)?i.push(c):(n.push(c),e.warnings.push(`Frame not found: ${ZMt(c)}`));const r=VVe({id:crypto.randomUUID(),type:"trace",grid:t.grid??{...qI.trace}});return{...r,frames:i,bufferSize:((a=t.settings)==null?void 0:a.bufferSize)??r.bufferSize,sortOrder:((s=t.settings)==null?void 0:s.sortOrder)??r.sortOrder,groupByFrame:((l=t.settings)==null?void 0:l.groupByFrame)??r.groupByFrame,expandSignals:((u=t.settings)==null?void 0:u.expandSignals)??r.expandSignals,unresolvedFrames:n.length>0?n:void 0}}function hLt(t,e,i){const n=[];let r;try{r=JSON.parse(t)}catch(f){return{success:!1,warnings:[],error:`Invalid JSON: ${f instanceof Error?f.message:"Parse error"}`}}let o;try{o=ARt(r)}catch(f){return{success:!1,warnings:[],error:f instanceof Error?f.message:"Migration failed"}}const a=XMt(o);if(!a.valid)return{success:!1,warnings:[],error:"Schema validation failed",errors:a.errors||[]};a.warnings&&n.push(...a.warnings);const s=ORt(o);if(s.length>0)return{success:!1,warnings:[],error:`Invalid layout: ${s.join(", ")}`};const l=DRt(),u={availableSignals:e,availableFrames:i,warnings:n},c=[];let d=!1;for(const f of o.panels){if(!l.includes(f.type)){n.push(`Unknown panel type: ${f.type} (skipped)`);continue}if(f.type==="frameDistribution"){if(d){n.push("Only one frame-distribution panel is allowed; duplicate skipped");continue}d=!0}const h=aLt(f,u);h&&c.push(h)}return{success:!0,config:o,panels:c,chartWidthSeconds:o.chartWidthSeconds,warnings:n}}function pLt(t){return JSON.stringify(t,null,2)}function gLt(t){return pLt(t)}function vLt(t){const e=qt.c(12),{theme:i,setTheme:n}=dI();let r;e[0]!==t||e[1]!==n?(r=d=>{const f=d.target.value;n(f),t.onChange(f)},e[0]=t,e[1]=n,e[2]=r):r=e[2];let o,a,s;e[3]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx("option",{value:VL.System,children:"System"}),a=L.jsx("option",{value:VL.Light,children:"Light"}),s=L.jsx("option",{value:VL.Dark,children:"Dark"}),e[3]=o,e[4]=a,e[5]=s):(o=e[3],a=e[4],s=e[5]);let l;e[6]!==r||e[7]!==i?(l=L.jsxs("select",{value:i,onChange:r,className:"appearance-none pl-3 pr-10 py-2 rounded-md border border-border bg-background text-foreground text-sm focus:outline-none focus:ring-2 focus:ring-ring cursor-pointer",children:[o,a,s]}),e[6]=r,e[7]=i,e[8]=l):l=e[8];let u;e[9]===Symbol.for("react.memo_cache_sentinel")?(u=L.jsx(A$,{className:"absolute right-3 top-1/2 -translate-y-1/2 h-4 w-4 text-muted-foreground pointer-events-none"}),e[9]=u):u=e[9];let c;return e[10]!==l?(c=L.jsx(L.Fragment,{children:L.jsxs("div",{className:"relative",children:[l,u]})}),e[10]=l,e[11]=c):c=e[11],c}function S$(t){const e=qt.c(10);let i;e[0]!==t.label?(i=L.jsx("p",{className:"font-medium text-card-foreground",children:t.label}),e[0]=t.label,e[1]=i):i=e[1];let n;e[2]!==t.description?(n=L.jsx("p",{className:"text-sm text-muted-foreground",children:t.description}),e[2]=t.description,e[3]=n):n=e[3];let r;e[4]!==i||e[5]!==n?(r=L.jsxs("div",{children:[i,n]}),e[4]=i,e[5]=n,e[6]=r):r=e[6];let o;return e[7]!==t.children||e[8]!==r?(o=L.jsxs("div",{className:"flex items-center justify-between p-4",children:[r,t.children]}),e[7]=t.children,e[8]=r,e[9]=o):o=e[9],o}function _J(t){const e=qt.c(17);let i;e[0]!==t.iconType?(i=L.jsx("div",{className:"p-2 rounded-lg bg-muted",children:L.jsx(Wr,{type:t.iconType,className:"w-5 h-5 text-muted-foreground"})}),e[0]=t.iconType,e[1]=i):i=e[1];let n;e[2]!==t.title?(n=L.jsx("h2",{className:"text-lg font-semibold text-foreground",children:t.title}),e[2]=t.title,e[3]=n):n=e[3];let r;e[4]!==t.description?(r=L.jsx("p",{className:"text-sm text-muted-foreground",children:t.description}),e[4]=t.description,e[5]=r):r=e[5];let o;e[6]!==n||e[7]!==r?(o=L.jsxs("div",{children:[n,r]}),e[6]=n,e[7]=r,e[8]=o):o=e[8];let a;e[9]!==i||e[10]!==o?(a=L.jsxs("div",{className:"flex items-center gap-3 mb-4",children:[i,o]}),e[9]=i,e[10]=o,e[11]=a):a=e[11];let s;e[12]!==t.children?(s=L.jsx("div",{className:"rounded-2xl border border-border bg-card divide-y divide-border",children:t.children}),e[12]=t.children,e[13]=s):s=e[13];let l;return e[14]!==a||e[15]!==s?(l=L.jsxs("section",{children:[a,s]}),e[14]=a,e[15]=s,e[16]=l):l=e[16],l}function yHe(t){const e=qt.c(7);let i;e[0]!==t?(i=r=>t.onChange(r.target.value),e[0]=t,e[1]=i):i=e[1];let n;return e[2]!==t.disabled||e[3]!==t.placeholder||e[4]!==t.value||e[5]!==i?(n=L.jsx("input",{type:"text",value:t.value,onChange:i,placeholder:t.placeholder,className:"w-64 px-3 py-1.5 text-sm rounded-sm border border-border bg-background text-foreground placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-primary disabled:opacity-50 disabled:cursor-not-allowed",disabled:t.disabled}),e[2]=t.disabled,e[3]=t.placeholder,e[4]=t.value,e[5]=i,e[6]=n):n=e[6],n}const yLt={route:Nu.SETTINGS,title:"Settings",contextId:qs.SETTINGS,icon:Xi.CONTEXT_SETTINGS,component:_Lt};function mLt(t){const e=qt.c(11),{track:i}=el();let n;e[0]!==t||e[1]!==i?(n=async()=>{var l;i(Fi.ChangeSetting,{setting:"studioBackendUrl"}),t.updateEnvironment(t.studioBackendUrl,(l=t.environment)==null?void 0:l.studioBackendUrl).catch(bLt)},e[0]=t,e[1]=i,e[2]=n):n=e[2];const r=n;let o;e[3]!==t.setStudioBackendUrl||e[4]!==t.studioBackendUrl?(o=L.jsx(yHe,{value:t.studioBackendUrl,onChange:t.setStudioBackendUrl,placeholder:"E.g. http://localhost:12345"}),e[3]=t.setStudioBackendUrl,e[4]=t.studioBackendUrl,e[5]=o):o=e[5];let a;e[6]!==r?(a=L.jsx(Za,{onClick:r,label:"Connect",type:fn.PRIMARY}),e[6]=r,e[7]=a):a=e[7];let s;return e[8]!==o||e[9]!==a?(s=L.jsxs(S$,{label:"RemotiveStudio URL",description:"The URL of the RemotiveStudio backend to connect to",children:[o,a]}),e[8]=o,e[9]=a,e[10]=s):s=e[10],s}async function bLt(t){console.warn("Failed to connect to studio",t),await SLt(100),Ki.error("Failed to connect",{toastId:"api.failed-connection"})}function SLt(t){return new Promise(e=>setTimeout(e,t))}function mHe(){const t=qt.c(8),{connectedBroker:e,disconnectBroker:i}=F6(),{environment:n}=Lp(),[r,o]=J.useState(n.brokerUrl);let a;t[0]!==r?(a=L.jsx(yHe,{value:r,onChange:o,placeholder:"E.g. http://localhost:12345",disabled:!0}),t[0]=r,t[1]=a):a=t[1];let s;t[2]!==e||t[3]!==i?(s=Swe,t[2]=e,t[3]=i,t[4]=s):s=t[4];let l;return t[5]!==a||t[6]!==s?(l=L.jsxs(S$,{label:"RemotiveBroker URL",description:"The URL of the RemotiveBroker to connect to",children:[a,s]}),t[5]=a,t[6]=s,t[7]=l):l=t[7],l}function _Lt(){const t=qt.c(17),{environment:e,updateEnvironment:i,updatePreferences:n,preferences:r}=Lp(),{track:o}=el(),[a,s]=J.useState(e.studioBackendUrl);let l;t[0]!==e||t[1]!==a||t[2]!==i?(l=()=>L.jsx(_J,{iconType:dr.SYSTEM_SERVER,title:"Development",description:"Only visible during development",children:L.jsx(mLt,{environment:e,updateEnvironment:i,studioBackendUrl:a,setStudioBackendUrl:s})}),t[0]=e,t[1]=a,t[2]=i,t[3]=l):l=t[3];const u=l,c=PLt;let d;t[4]!==r.showHiddenFiles||t[5]!==o||t[6]!==n?(d=()=>L.jsxs(_J,{iconType:dr.THEME_PALETTE,title:"Preferences",description:"Adjust how RemotiveStudio looks and behaves.",children:[L.jsx(S$,{label:"Theme",description:"Select a color theme",children:L.jsx(vLt,{onChange:m=>{o(Fi.ChangeSetting,{setting:"theme",value:m})}})}),L.jsx(S$,{label:"Hidden files",description:"Show hidden files in the file browser",children:L.jsx(BVe,{defaultChecked:r.showHiddenFiles,onChange:m=>{n({showHiddenFiles:m}),o(Fi.ChangeSetting,{setting:"showHiddenFiles",value:m})}})})]}),t[4]=r.showHiddenFiles,t[5]=o,t[6]=n,t[7]=d):d=t[7];const f=d;let h;t[8]===Symbol.for("react.memo_cache_sentinel")?(h=L.jsx(LP,{title:"Settings",description:"Customize your RemotiveStudio experience"}),t[8]=h):h=t[8];let p;t[9]===Symbol.for("react.memo_cache_sentinel")?(p=c(),t[9]=p):p=t[9];let g;t[10]!==f?(g=f(),t[10]=f,t[11]=g):g=t[11];let v;t[12]!==u?(v=Swe,t[12]=u,t[13]=v):v=t[13];let y;return t[14]!==g||t[15]!==v?(y=L.jsxs(MS,{children:[h,L.jsx(LS,{children:L.jsxs("div",{className:"space-y-8",children:[p,g,v]})})]}),t[14]=g,t[15]=v,t[16]=y):y=t[16],y}function PLt(){return L.jsx(_J,{iconType:dr.SYSTEM_SERVER,title:"Connections",description:"Configure server connections",children:L.jsx(mHe,{})})}function CLt(t){const e=qt.c(4);if(!CNe().broker){let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=L.jsx(mHe,{}),e[0]=r):r=e[0];let o;return e[1]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsxs(L.Fragment,{children:[r,L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center text-muted-foreground",children:[L.jsx(Wr,{type:dr.STATUS_LOADING,className:"w-8 h-8 animate-spin mb-3"}),L.jsx("p",{className:"text-sm",children:"Unable to connect to broker"}),L.jsx("p",{className:"text-xs text-muted-foreground",children:"Trying to connect..."})]})]}),e[1]=o):o=e[1],o}let n;return e[2]!==t.filePath?(n=L.jsx(TOt,{children:L.jsx(TLt,{filePath:t.filePath})}),e[2]=t.filePath,e[3]=n):n=e[3],n}const wxe=t=>{var e;return((e=t.split("/").pop())==null?void 0:e.replace(".dashboard.json",""))||"untitled"};function TLt(t){const{track:e}=el(),i=fte(),n=J.useRef(null),r=J.useCallback(()=>{var G;(G=n.current)==null||G.compact()},[]),o=oC(),a=X1t(),s=WV(),{refreshFileTree:l}=CQ(),u=B$(),[c,d]=J.useState(30),[f,h]=J.useState(!1),[p,g]=J.useState(!1),[v,y]=J.useState(!1),{files:m}=Jke(),b=t.filePath.startsWith("draft:"),[S,_]=J.useState(!1),C=J.useRef(null),P=J.useRef(crypto.randomUUID());J.useEffect(()=>{const G=new BroadcastChannel("remotive-studio");C.current=G;const H=P.current;return G.onmessage=U=>{const{type:k,id:X}=U.data;X!==H&&(k==="announce"&&(_(!0),G.postMessage({type:"announce-ack",id:H})),k==="announce-ack"&&_(!0),k==="ping"&&G.postMessage({type:"pong",id:H}))},G.postMessage({type:"announce",id:H}),()=>{C.current=null,G.close()}},[]),J.useEffect(()=>{if(!S)return;let G=!1;const H=C.current;if(!H)return;const U=H.onmessage;H.onmessage=X=>{U==null||U.call(H,X);const{type:W,id:Y}=X.data;W==="pong"&&Y!==P.current&&(G=!0)};const k=setInterval(()=>{G=!1,H.postMessage({type:"ping",id:P.current}),setTimeout(()=>{G||_(!1)},1e3)},3e3);return()=>{clearInterval(k),H.onmessage=U}},[S]);const{tabId:x}=jne(),{setPageUnsavedChanges:E,updatePage:A}=Ih();J.useEffect(()=>{E(x,b||o.isDirty)},[x,b,o.isDirty,E]);const R=o.panels.length>0;J.useEffect(()=>{(()=>{console.log("Setting up frontend license"),new NAt(i.grpcUrl).setupFrontendLicense("auZC0a9O/aNgCfBUyVEsyFHTD15184gp2I5cMZjSUT0e2JvEdUHZ2FvQIp8IzCyBK9cRFdViZ+at2eIpePirYQyDwwNQid1G5Kn+m9F/9ll2mRjXsky4EU8gAxgr9g4sF0HKbupsLeaEutxOIEF0gv0Y4h+OqHHl+m9KuYv0rQuxON7cYUznEuNfuZ62v/No4hBpzcSDAzjHgOGLKyfFJQzfL/rvz1lnbdyZ5+iiZCjbjgClpu6vxXdl2R764iiUXQA0UbIdDqzoxxJB/yH3lVdCrMqJii/MnEBiq6bD2nM0DYVb0Sfj3MbgruM7jCAaEPEvBrW+Ef5Le5Kr1ywjdulHtWefacP2hwuPcjrxerAr5yua3RWmL6NktiqvP6NACM3dcoYWR3+mhMA9wLYFqb7IUDceR4N/OfdN0zPTPOj+ixB5vmMTfHdZyutYetDaKJjZ6kSTzvwFo7+/e4P17f3+gr3PFw8/2W0MHAEucg9hmdLAfp6RUxSW/E7HzEWhrApnGfLWQRVOcXwJ7+I+AOiluFTRQcGs6ybAAwmZLQGJvWGihbbA3FMKGANsQqE1BnFpEocj/rl/h4r+eRhBaCqWM8L53D4nV4A41LM3wxKjlzIylsyTTSotvPIZYvKOaMyC+Iu+rityQ2H1kRcOLyYW6YabWxL/R0cj7/xWvdRQ2gvmamtRtrEB8U84dRkyWPYA2A/RcOazYAEJc5M=",void 0)})()},[i]);const M=J.useRef(!1),D=J.useRef(null);J.useEffect(()=>{var H;if((H=t.filePath)!=null&&H.startsWith("draft:")){D.current=t.filePath;return}if(!t.filePath||M.current||D.current===t.filePath)return;(async()=>{M.current=!0;try{const U=await u.getFileContent(t.filePath),k=hLt(U,a,s);if(k.success&&k.panels){if(o.replaceAll(k.panels),k.chartWidthSeconds!==void 0&&d(k.chartWidthSeconds),k.warnings.length>0){const X=L.jsx("div",{children:L.jsx("p",{className:"font-medium mb-1",children:"Dashboard loaded with warnings"})});Ki.warning(X,{autoClose:5e3}),console.log("warnings",k.warnings)}}else if(k.errors&&k.errors.length>0){const X=L.jsxs("div",{children:[L.jsxs("p",{className:"font-medium mb-1",children:[k.error||"Schema validation failed",":"]}),L.jsxs("ul",{className:"text-xs space-y-0.5 list-disc list-inside max-h-[300px] overflow-y-auto",children:[k.errors.slice(0,10).map((W,Y)=>L.jsx("li",{className:"break-words",children:W},Y)),k.errors.length>10&&L.jsxs("li",{children:["...and ",k.errors.length-10," more"]})]})]});Ki.error(X,{autoClose:!1})}else Ki.error(k.error||"Failed to load dashboard",{autoClose:!1});D.current=t.filePath,M.current=!1}catch(U){console.error("Error loading dashboard from file:",U),Ki.error(U instanceof Error?U.message:"Failed to load dashboard",{autoClose:!1}),D.current=t.filePath,M.current=!1}})()},[t.filePath,u,o,a,s]);const F=G=>{G==="gauge-row"?(o.addPanel("gauge"),e(Fi.AddPanelToDashboard,{panelType:"gauge"})):G==="signal-timeseries"?(o.addPanel("timeseries"),e(Fi.AddPanelToDashboard,{panelType:"timeseries"})):G==="trace"?(o.addPanel("trace"),e(Fi.AddPanelToDashboard,{panelType:"trace"})):G==="frame-distribution"?(o.addPanel("frame-distribution"),e(Fi.AddPanelToDashboard,{panelType:"frame-distribution"})):G==="map"?(o.addPanel("map"),e(Fi.AddPanelToDashboard,{panelType:"map"})):G==="video"?(o.addPanel("video"),e(Fi.AddPanelToDashboard,{panelType:"video"})):G==="recording"&&h(!0)},I=J.useCallback(G=>{const H=G.startsWith("/")?wxe(G):G,U=oLt(o.panels,{includeVideoPanels:!0,name:H},c),k=gLt(U);b&&y(!0);const X=b?G:t.filePath;u.uploadAsFile(X,k).then(()=>{o.markClean(),l(),b?(e(Fi.SaveDashboardAs,{name:H}),g(!1),A(x,{title:wxe(X),params:{path:X,fileType:"FILE_TYPE_DASHBOARD"}})):e(Fi.SaveDashboard,{name:H})}).catch(W=>{console.error("Error saving dashboard:",W.message),Ki.error("Error saving dashboard")}).finally(()=>{b&&y(!1)})},[u,o,c,l,x,b,A,t.filePath,e]),V=[{id:"panels",header:"Charts",defaultExpanded:!0,items:[{id:"signal-timeseries",label:"Timeseries",icon:L.jsx(Wr,{type:dr.DATA_TIMESERIES,className:"w-3.5 h-3.5"})},{id:"trace",label:"Trace",icon:L.jsx(Wr,{type:dr.DATA_TRACE,className:"w-3.5 h-3.5"})},{id:"map",label:"Map",icon:L.jsx(Wr,{type:dr.TOPOLOGY_ENDPOINT,className:"w-3.5 h-3.5"})},{id:"frame-distribution",label:"Frame distribution",disabled:o.hasFrameDistributionPanel,icon:L.jsx(Wr,{type:dr.CONTEXT_DASHBOARD,className:"w-3.5 h-3.5"})}]},{id:"recording",header:"Recordings",defaultExpanded:!0,items:[{id:"recording",disabled:m.length===0,label:"Open recording",icon:L.jsx(Wr,{type:dr.FOLDER_OPEN,className:"w-3.5 h-3.5"})},{id:"video",label:"Video",disabled:m.length===0,icon:L.jsx(Wr,{type:dr.FILE_VIDEO,className:"w-3.5 h-3.5"})}]}],z=()=>L.jsx(L.Fragment,{children:L.jsxs("div",{className:Hr("flex flex-col items-center justify-center text-center","flex-1"),children:[L.jsx("div",{className:"p-4 rounded-xl bg-muted mb-4",children:L.jsx(Wr,{type:dr.CONTEXT_DASHBOARD,className:"w-8 h-8 text-muted-foreground"})}),L.jsxs("div",{className:"flex flex-col items-center justify-center mb-4",children:[L.jsx("p",{className:"text-foreground text-sm m-0",children:"Ready to start visualizing data?"}),L.jsxs("p",{className:"text-muted-foreground text-xs m-0",children:["Click the ",L.jsx("span",{className:"font-bold",children:"+ Add Panel"})," button in the top right corner to get started."]})]})]})});return L.jsxs(L.Fragment,{children:[S&&L.jsx("div",{className:"flex items-center justify-between mb-1 mx-1 gap-2 px-3 py-2 text-warning-foreground text-xs bg-amber-50 dark:bg-amber-300/40  rounded-sm",children:L.jsxs("span",{className:"flex items-center gap-2",children:[L.jsx(Wr,{type:dr.STATUS_WARNING,className:"w-4 h-4 inline text-orange-500 dark:text-orange-400"}),"A dashboard is open in another tab. Running dashboards in multiple tabs simultaneously may cause unexpected behavior.",L.jsx("a",{className:"-ms-1 text-primary cursor-pointer dark:text-blue-300 underline",target:"_blank",rel:"noopener noreferrer",href:"https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Connection_management_in_HTTP_1.x",children:"Read more about this limitation here."})]})}),L.jsx("div",{className:"m-1",children:L.jsxs("div",{className:"flex flex-row w-full items-center justify-between",children:[L.jsxs("div",{className:"flex flex-row gap-1",children:[L.jsx(Za,{icon:dr.PANEL_SHRINK,label:"Compact",type:fn.PRIMARY,size:_a.SM,onClick:()=>{r(),e(Fi.CompactDashboard)}}),L.jsx(Za,{disabled:!o.isDirty&&!b,icon:dr.ACTION_SAVE,label:b?"Save As...":"Save",type:fn.PRIMARY,size:_a.SM,onClick:()=>{b?g(!0):I(t.filePath)}})]}),L.jsx("div",{className:"flex flex-row gap-1",children:L.jsxs(Ik,{children:[L.jsx(Nk,{asChild:!0,children:L.jsxs("button",{type:"button",className:Hr(XJ,VEe[_a.SM],KJ[fn.PRIMARY],"data-[state=open]:[&_.add-panel-chevron]:rotate-180"),children:[L.jsx(Wr,{type:dr.ACTION_ADD,className:"w-3 h-3"}),"Add Panel",L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"add-panel-chevron w-3 h-3 transition-transform"})]})}),L.jsx(AD,{children:L.jsx(Fk,{align:"end",sideOffset:4,className:Hr("z-[9999] min-w-[200px]","bg-popover border border-border","rounded-md shadow-xl p-1","animate-in fade-in-0 zoom-in-95"),children:V.map(G=>L.jsxs(EMe,{children:[L.jsx(wMe,{className:"px-2 py-1 text-[10px] font-semibold text-muted-foreground uppercase tracking-wider bg-muted/50 rounded-sm",children:G.header}),G.items.map(H=>L.jsxs(dm,{disabled:H.disabled,onSelect:()=>F(H.id),className:Hr("flex items-center gap-2 w-full px-2 py-1.5","text-xs text-popover-foreground outline-none","rounded-sm cursor-pointer transition-colors","data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground","data-[disabled]:opacity-50 data-[disabled]:pointer-events-none"),children:[H.icon,L.jsx("span",{children:H.label})]},H.id))]},G.id))})})]})})]})}),L.jsx("div",{className:"p-0 min-h-0 flex-1 flex flex-col",children:L.jsx(Z0t,{children:L.jsxs("div",{className:Hr("flex flex-col min-h-0 flex-1",!R&&"min-h-[calc(100vh-14rem)]"),children:[L.jsx(pbt,{showFileTreeModal:f,setShowFileTreeModal:h,onRecordingSessionOpened:G=>e(Fi.OpenRecordingSession,{path:G})}),L.jsx("div",{className:"flex-1 min-h-0 flex flex-col",children:R?L.jsx(CRt,{ref:n}):z()})]})})}),p&&L.jsx(FAt,{title:"Save Dashboard",confirmLabel:"Save",savingLabel:"Saving...",onClose:()=>g(!1),onCreate:I,isSaving:v})]})}function bHe(t){const e=qt.c(11),{pages:i,openPage:n}=Ih(),{track:r}=el();let o;e[0]!==n||e[1]!==i||e[2]!==r?(o=function(){const f=i.filter(xLt).length;r(Fi.CreateDashboard,{numberOfDrafts:f+1}),n(Nu.FILES,{id:`file:draft:${crypto.randomUUID()}`,title:f===0?"New Dashboard":`New Dashboard ${f+1}`,params:{path:f===0?"draft:new-dashboard":`draft:new-dashboard-${f+1}`,fileType:"FILE_TYPE_DASHBOARD"}})},e[0]=n,e[1]=i,e[2]=r,e[3]=o):o=e[3];const a=o;let s;e[4]!==t.className?(s=Hr("w-full flex items-center gap-2.5 px-3 py-2 text-sm text-left","transition-colors duration-150","hover:bg-white/5",t.className),e[4]=t.className,e[5]=s):s=e[5];let l,u;e[6]===Symbol.for("react.memo_cache_sentinel")?(l=L.jsx(Wr,{type:dr.ACTION_ADD,className:"w-4 h-4 opacity-70 text-blue-400"}),u=L.jsx("span",{children:"New Dashboard"}),e[6]=l,e[7]=u):(l=e[6],u=e[7]);let c;return e[8]!==a||e[9]!==s?(c=L.jsxs("button",{onClick:a,className:s,children:[l,u]}),e[8]=a,e[9]=s,e[10]=c):c=e[10],c}function xLt(t){return t.type===Nu.FILES&&t.params.path.startsWith("draft:")}const ELt={container:"Containers",behavioral_model:"Behavioral Models",ecu:"ECUs",channel:"Channels",endpoint:"Endpoints",socket:"Sockets",service_instance:"Service Instances",ecu_channel:"ECU Channels"},bne=Symbol.for("yaml.alias"),PJ=Symbol.for("yaml.document"),mP=Symbol.for("yaml.map"),SHe=Symbol.for("yaml.pair"),bm=Symbol.for("yaml.scalar"),KI=Symbol.for("yaml.seq"),Mg=Symbol.for("yaml.node.type"),yR=t=>!!t&&typeof t=="object"&&t[Mg]===bne,lG=t=>!!t&&typeof t=="object"&&t[Mg]===PJ,aH=t=>!!t&&typeof t=="object"&&t[Mg]===mP,nu=t=>!!t&&typeof t=="object"&&t[Mg]===SHe,gs=t=>!!t&&typeof t=="object"&&t[Mg]===bm,sH=t=>!!t&&typeof t=="object"&&t[Mg]===KI;function eu(t){if(t&&typeof t=="object")switch(t[Mg]){case mP:case KI:return!0}return!1}function ru(t){if(t&&typeof t=="object")switch(t[Mg]){case bne:case mP:case bm:case KI:return!0}return!1}const _He=t=>(gs(t)||eu(t))&&!!t.anchor,FO=Symbol("break visit"),wLt=Symbol("skip children"),Fj=Symbol("remove node");function ZI(t,e){const i=ALt(e);lG(t)?IL(null,t.contents,i,Object.freeze([t]))===Fj&&(t.contents=null):IL(null,t,i,Object.freeze([]))}ZI.BREAK=FO;ZI.SKIP=wLt;ZI.REMOVE=Fj;function IL(t,e,i,n){const r=OLt(t,e,i,n);if(ru(r)||nu(r))return DLt(t,n,r),IL(t,r,i,n);if(typeof r!="symbol"){if(eu(e)){n=Object.freeze(n.concat(e));for(let o=0;o<e.items.length;++o){const a=IL(o,e.items[o],i,n);if(typeof a=="number")o=a-1;else{if(a===FO)return FO;a===Fj&&(e.items.splice(o,1),o-=1)}}}else if(nu(e)){n=Object.freeze(n.concat(e));const o=IL("key",e.key,i,n);if(o===FO)return FO;o===Fj&&(e.key=null);const a=IL("value",e.value,i,n);if(a===FO)return FO;a===Fj&&(e.value=null)}}return r}function ALt(t){return typeof t=="object"&&(t.Collection||t.Node||t.Value)?Object.assign({Alias:t.Node,Map:t.Node,Scalar:t.Node,Seq:t.Node},t.Value&&{Map:t.Value,Scalar:t.Value,Seq:t.Value},t.Collection&&{Map:t.Collection,Seq:t.Collection},t):t}function OLt(t,e,i,n){var r,o,a,s,l;if(typeof i=="function")return i(t,e,n);if(aH(e))return(r=i.Map)==null?void 0:r.call(i,t,e,n);if(sH(e))return(o=i.Seq)==null?void 0:o.call(i,t,e,n);if(nu(e))return(a=i.Pair)==null?void 0:a.call(i,t,e,n);if(gs(e))return(s=i.Scalar)==null?void 0:s.call(i,t,e,n);if(yR(e))return(l=i.Alias)==null?void 0:l.call(i,t,e,n)}function DLt(t,e,i){const n=e[e.length-1];if(eu(n))n.items[t]=i;else if(nu(n))t==="key"?n.key=i:n.value=i;else if(lG(n))n.contents=i;else{const r=yR(n)?"alias":"scalar";throw new Error(`Cannot replace node with ${r} parent`)}}const RLt={"!":"%21",",":"%2C","[":"%5B","]":"%5D","{":"%7B","}":"%7D"},MLt=t=>t.replace(/[!,[\]{}]/g,e=>RLt[e]);class Af{constructor(e,i){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},Af.defaultYaml,e),this.tags=Object.assign({},Af.defaultTags,i)}clone(){const e=new Af(this.yaml,this.tags);return e.docStart=this.docStart,e}atDocument(){const e=new Af(this.yaml,this.tags);switch(this.yaml.version){case"1.1":this.atNextDocument=!0;break;case"1.2":this.atNextDocument=!1,this.yaml={explicit:Af.defaultYaml.explicit,version:"1.2"},this.tags=Object.assign({},Af.defaultTags);break}return e}add(e,i){this.atNextDocument&&(this.yaml={explicit:Af.defaultYaml.explicit,version:"1.1"},this.tags=Object.assign({},Af.defaultTags),this.atNextDocument=!1);const n=e.trim().split(/[ \t]+/),r=n.shift();switch(r){case"%TAG":{if(n.length!==2&&(i(0,"%TAG directive should contain exactly two parts"),n.length<2))return!1;const[o,a]=n;return this.tags[o]=a,!0}case"%YAML":{if(this.yaml.explicit=!0,n.length!==1)return i(0,"%YAML directive should contain exactly one part"),!1;const[o]=n;if(o==="1.1"||o==="1.2")return this.yaml.version=o,!0;{const a=/^\d+\.\d+$/.test(o);return i(6,`Unsupported YAML version ${o}`,a),!1}}default:return i(0,`Unknown directive ${r}`,!0),!1}}tagName(e,i){if(e==="!")return"!";if(e[0]!=="!")return i(`Not a valid tag: ${e}`),null;if(e[1]==="<"){const a=e.slice(2,-1);return a==="!"||a==="!!"?(i(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==">"&&i("Verbatim tags must end with a >"),a)}const[,n,r]=e.match(/^(.*!)([^!]*)$/s);r||i(`The ${e} tag has no suffix`);const o=this.tags[n];if(o)try{return o+decodeURIComponent(r)}catch(a){return i(String(a)),null}return n==="!"?e:(i(`Could not resolve tag: ${e}`),null)}tagString(e){for(const[i,n]of Object.entries(this.tags))if(e.startsWith(n))return i+MLt(e.substring(n.length));return e[0]==="!"?e:`!<${e}>`}toString(e){const i=this.yaml.explicit?[`%YAML ${this.yaml.version||"1.2"}`]:[],n=Object.entries(this.tags);let r;if(e&&n.length>0&&ru(e.contents)){const o={};ZI(e.contents,(a,s)=>{ru(s)&&s.tag&&(o[s.tag]=!0)}),r=Object.keys(o)}else r=[];for(const[o,a]of n)o==="!!"&&a==="tag:yaml.org,2002:"||(!e||r.some(s=>s.startsWith(a)))&&i.push(`%TAG ${o} ${a}`);return i.join(`
`)}}Af.defaultYaml={explicit:!1,version:"1.2"};Af.defaultTags={"!!":"tag:yaml.org,2002:"};function PHe(t){if(/[\x00-\x19\s,[\]{}]/.test(t)){const i=`Anchor must not contain whitespace or control characters: ${JSON.stringify(t)}`;throw new Error(i)}return!0}function CHe(t){const e=new Set;return ZI(t,{Value(i,n){n.anchor&&e.add(n.anchor)}}),e}function THe(t,e){for(let i=1;;++i){const n=`${t}${i}`;if(!e.has(n))return n}}function LLt(t,e){const i=[],n=new Map;let r=null;return{onAnchor:o=>{i.push(o),r??(r=CHe(t));const a=THe(e,r);return r.add(a),a},setAnchors:()=>{for(const o of i){const a=n.get(o);if(typeof a=="object"&&a.anchor&&(gs(a.node)||eu(a.node)))a.node.anchor=a.anchor;else{const s=new Error("Failed to resolve repeated object (this should not happen)");throw s.source=o,s}}},sourceObjects:n}}function NL(t,e,i,n){if(n&&typeof n=="object")if(Array.isArray(n))for(let r=0,o=n.length;r<o;++r){const a=n[r],s=NL(t,n,String(r),a);s===void 0?delete n[r]:s!==a&&(n[r]=s)}else if(n instanceof Map)for(const r of Array.from(n.keys())){const o=n.get(r),a=NL(t,n,r,o);a===void 0?n.delete(r):a!==o&&n.set(r,a)}else if(n instanceof Set)for(const r of Array.from(n)){const o=NL(t,n,r,r);o===void 0?n.delete(r):o!==r&&(n.delete(r),n.add(o))}else for(const[r,o]of Object.entries(n)){const a=NL(t,n,r,o);a===void 0?delete n[r]:a!==o&&(n[r]=a)}return t.call(e,i,n)}function Dg(t,e,i){if(Array.isArray(t))return t.map((n,r)=>Dg(n,String(r),i));if(t&&typeof t.toJSON=="function"){if(!i||!_He(t))return t.toJSON(e,i);const n={aliasCount:0,count:1,res:void 0};i.anchors.set(t,n),i.onCreate=o=>{n.res=o,delete i.onCreate};const r=t.toJSON(e,i);return i.onCreate&&i.onCreate(r),r}return typeof t=="bigint"&&!(i!=null&&i.keep)?Number(t):t}class Sne{constructor(e){Object.defineProperty(this,Mg,{value:e})}clone(){const e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:i,maxAliasCount:n,onAnchor:r,reviver:o}={}){if(!lG(e))throw new TypeError("A document argument is required");const a={anchors:new Map,doc:e,keep:!0,mapAsMap:i===!0,mapKeyWarned:!1,maxAliasCount:typeof n=="number"?n:100},s=Dg(this,"",a);if(typeof r=="function")for(const{count:l,res:u}of a.anchors.values())r(u,l);return typeof o=="function"?NL(o,{"":s},"",s):s}}class _ne extends Sne{constructor(e){super(bne),this.source=e,Object.defineProperty(this,"tag",{set(){throw new Error("Alias nodes cannot have tags")}})}resolve(e,i){let n;i!=null&&i.aliasResolveCache?n=i.aliasResolveCache:(n=[],ZI(e,{Node:(o,a)=>{(yR(a)||_He(a))&&n.push(a)}}),i&&(i.aliasResolveCache=n));let r;for(const o of n){if(o===this)break;o.anchor===this.source&&(r=o)}return r}toJSON(e,i){if(!i)return{source:this.source};const{anchors:n,doc:r,maxAliasCount:o}=i,a=this.resolve(r,i);if(!a){const l=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new ReferenceError(l)}let s=n.get(a);if(s||(Dg(a,null,i),s=n.get(a)),(s==null?void 0:s.res)===void 0){const l="This should not happen: Alias anchor was not resolved?";throw new ReferenceError(l)}if(o>=0&&(s.count+=1,s.aliasCount===0&&(s.aliasCount=n5(r,a,n)),s.count*s.aliasCount>o)){const l="Excessive alias count indicates a resource exhaustion attack";throw new ReferenceError(l)}return s.res}toString(e,i,n){const r=`*${this.source}`;if(e){if(PHe(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){const o=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw new Error(o)}if(e.implicitKey)return`${r} `}return r}}function n5(t,e,i){if(yR(e)){const n=e.resolve(t),r=i&&n&&i.get(n);return r?r.count*r.aliasCount:0}else if(eu(e)){let n=0;for(const r of e.items){const o=n5(t,r,i);o>n&&(n=o)}return n}else if(nu(e)){const n=n5(t,e.key,i),r=n5(t,e.value,i);return Math.max(n,r)}return 1}const xHe=t=>!t||typeof t!="function"&&typeof t!="object";class Fn extends Sne{constructor(e){super(bm),this.value=e}toJSON(e,i){return i!=null&&i.keep?this.value:Dg(this.value,e,i)}toString(){return String(this.value)}}Fn.BLOCK_FOLDED="BLOCK_FOLDED";Fn.BLOCK_LITERAL="BLOCK_LITERAL";Fn.PLAIN="PLAIN";Fn.QUOTE_DOUBLE="QUOTE_DOUBLE";Fn.QUOTE_SINGLE="QUOTE_SINGLE";const kLt="tag:yaml.org,2002:";function ILt(t,e,i){if(e){const n=i.filter(o=>o.tag===e),r=n.find(o=>!o.format)??n[0];if(!r)throw new Error(`Tag ${e} not found`);return r}return i.find(n=>{var r;return((r=n.identify)==null?void 0:r.call(n,t))&&!n.format})}function eV(t,e,i){var d,f,h;if(lG(t)&&(t=t.contents),ru(t))return t;if(nu(t)){const p=(f=(d=i.schema[mP]).createNode)==null?void 0:f.call(d,i.schema,null,i);return p.items.push(t),p}(t instanceof String||t instanceof Number||t instanceof Boolean||typeof BigInt<"u"&&t instanceof BigInt)&&(t=t.valueOf());const{aliasDuplicateObjects:n,onAnchor:r,onTagObj:o,schema:a,sourceObjects:s}=i;let l;if(n&&t&&typeof t=="object"){if(l=s.get(t),l)return l.anchor??(l.anchor=r(t)),new _ne(l.anchor);l={anchor:null,node:null},s.set(t,l)}e!=null&&e.startsWith("!!")&&(e=kLt+e.slice(2));let u=ILt(t,e,a.tags);if(!u){if(t&&typeof t.toJSON=="function"&&(t=t.toJSON()),!t||typeof t!="object"){const p=new Fn(t);return l&&(l.node=p),p}u=t instanceof Map?a[mP]:Symbol.iterator in Object(t)?a[KI]:a[mP]}o&&(o(u),delete i.onTagObj);const c=u!=null&&u.createNode?u.createNode(i.schema,t,i):typeof((h=u==null?void 0:u.nodeClass)==null?void 0:h.from)=="function"?u.nodeClass.from(i.schema,t,i):new Fn(t);return e?c.tag=e:u.default||(c.tag=u.tag),l&&(l.node=c),c}function _$(t,e,i){let n=i;for(let r=e.length-1;r>=0;--r){const o=e[r];if(typeof o=="number"&&Number.isInteger(o)&&o>=0){const a=[];a[o]=n,n=a}else n=new Map([[o,n]])}return eV(n,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw new Error("This should not happen, please report a bug.")},schema:t,sourceObjects:new Map})}const hj=t=>t==null||typeof t=="object"&&!!t[Symbol.iterator]().next().done;class EHe extends Sne{constructor(e,i){super(e),Object.defineProperty(this,"schema",{value:i,configurable:!0,enumerable:!1,writable:!0})}clone(e){const i=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(i.schema=e),i.items=i.items.map(n=>ru(n)||nu(n)?n.clone(e):n),this.range&&(i.range=this.range.slice()),i}addIn(e,i){if(hj(e))this.add(i);else{const[n,...r]=e,o=this.get(n,!0);if(eu(o))o.addIn(r,i);else if(o===void 0&&this.schema)this.set(n,_$(this.schema,r,i));else throw new Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){const[i,...n]=e;if(n.length===0)return this.delete(i);const r=this.get(i,!0);if(eu(r))return r.deleteIn(n);throw new Error(`Expected YAML collection at ${i}. Remaining path: ${n}`)}getIn(e,i){const[n,...r]=e,o=this.get(n,!0);return r.length===0?!i&&gs(o)?o.value:o:eu(o)?o.getIn(r,i):void 0}hasAllNullValues(e){return this.items.every(i=>{if(!nu(i))return!1;const n=i.value;return n==null||e&&gs(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){const[i,...n]=e;if(n.length===0)return this.has(i);const r=this.get(i,!0);return eu(r)?r.hasIn(n):!1}setIn(e,i){const[n,...r]=e;if(r.length===0)this.set(n,i);else{const o=this.get(n,!0);if(eu(o))o.setIn(r,i);else if(o===void 0&&this.schema)this.set(n,_$(this.schema,r,i));else throw new Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}}const NLt=t=>t.replace(/^(?!$)(?: $)?/gm,"#");function dS(t,e){return/^\n+$/.test(t)?t.substring(1):e?t.replace(/^(?! *$)/gm,e):t}const qO=(t,e,i)=>t.endsWith(`
`)?dS(i,e):i.includes(`
`)?`
`+dS(i,e):(t.endsWith(" ")?"":" ")+i,wHe="flow",CJ="block",o5="quoted";function uG(t,e,i="flow",{indentAtStart:n,lineWidth:r=80,minContentWidth:o=20,onFold:a,onOverflow:s}={}){if(!r||r<0)return t;r<o&&(o=0);const l=Math.max(1+o,1+r-e.length);if(t.length<=l)return t;const u=[],c={};let d=r-e.length;typeof n=="number"&&(n>r-Math.max(2,o)?u.push(0):d=r-n);let f,h,p=!1,g=-1,v=-1,y=-1;i===CJ&&(g=Axe(t,g,e.length),g!==-1&&(d=g+l));for(let b;b=t[g+=1];){if(i===o5&&b==="\\"){switch(v=g,t[g+1]){case"x":g+=3;break;case"u":g+=5;break;case"U":g+=9;break;default:g+=1}y=g}if(b===`
`)i===CJ&&(g=Axe(t,g,e.length)),d=g+e.length+l,f=void 0;else{if(b===" "&&h&&h!==" "&&h!==`
`&&h!=="	"){const S=t[g+1];S&&S!==" "&&S!==`
`&&S!=="	"&&(f=g)}if(g>=d)if(f)u.push(f),d=f+l,f=void 0;else if(i===o5){for(;h===" "||h==="	";)h=b,b=t[g+=1],p=!0;const S=g>y+1?g-2:v-1;if(c[S])return t;u.push(S),c[S]=!0,d=S+l,f=void 0}else p=!0}h=b}if(p&&s&&s(),u.length===0)return t;a&&a();let m=t.slice(0,u[0]);for(let b=0;b<u.length;++b){const S=u[b],_=u[b+1]||t.length;S===0?m=`
${e}${t.slice(0,_)}`:(i===o5&&c[S]&&(m+=`${t[S]}\\`),m+=`
${e}${t.slice(S+1,_)}`)}return m}function Axe(t,e,i){let n=e,r=e+1,o=t[r];for(;o===" "||o==="	";)if(e<r+i)o=t[++e];else{do o=t[++e];while(o&&o!==`
`);n=e,r=e+1,o=t[r]}return n}const cG=(t,e)=>({indentAtStart:e?t.indent.length:t.indentAtStart,lineWidth:t.options.lineWidth,minContentWidth:t.options.minContentWidth}),dG=t=>/^(%|---|\.\.\.)/m.test(t);function FLt(t,e,i){if(!e||e<0)return!1;const n=e-i,r=t.length;if(r<=n)return!1;for(let o=0,a=0;o<r;++o)if(t[o]===`
`){if(o-a>n)return!0;if(a=o+1,r-a<=n)return!1}return!0}function Bj(t,e){const i=JSON.stringify(t);if(e.options.doubleQuotedAsJSON)return i;const{implicitKey:n}=e,r=e.options.doubleQuotedMinMultiLineLength,o=e.indent||(dG(t)?"  ":"");let a="",s=0;for(let l=0,u=i[l];u;u=i[++l])if(u===" "&&i[l+1]==="\\"&&i[l+2]==="n"&&(a+=i.slice(s,l)+"\\ ",l+=1,s=l,u="\\"),u==="\\")switch(i[l+1]){case"u":{a+=i.slice(s,l);const c=i.substr(l+2,4);switch(c){case"0000":a+="\\0";break;case"0007":a+="\\a";break;case"000b":a+="\\v";break;case"001b":a+="\\e";break;case"0085":a+="\\N";break;case"00a0":a+="\\_";break;case"2028":a+="\\L";break;case"2029":a+="\\P";break;default:c.substr(0,2)==="00"?a+="\\x"+c.substr(2):a+=i.substr(l,6)}l+=5,s=l+1}break;case"n":if(n||i[l+2]==='"'||i.length<r)l+=1;else{for(a+=i.slice(s,l)+`

`;i[l+2]==="\\"&&i[l+3]==="n"&&i[l+4]!=='"';)a+=`
`,l+=2;a+=o,i[l+2]===" "&&(a+="\\"),l+=1,s=l+1}break;default:l+=1}return a=s?a+i.slice(s):i,n?a:uG(a,o,o5,cG(e,!1))}function TJ(t,e){if(e.options.singleQuote===!1||e.implicitKey&&t.includes(`
`)||/[ \t]\n|\n[ \t]/.test(t))return Bj(t,e);const i=e.indent||(dG(t)?"  ":""),n="'"+t.replace(/'/g,"''").replace(/\n+/g,`$&
${i}`)+"'";return e.implicitKey?n:uG(n,i,wHe,cG(e,!1))}function FL(t,e){const{singleQuote:i}=e.options;let n;if(i===!1)n=Bj;else{const r=t.includes('"'),o=t.includes("'");r&&!o?n=TJ:o&&!r?n=Bj:n=i?TJ:Bj}return n(t,e)}let xJ;try{xJ=new RegExp(`(^|(?<!
))
+(?!
|$)`,"g")}catch{xJ=/\n+(?!\n|$)/g}function a5({comment:t,type:e,value:i},n,r,o){const{blockQuote:a,commentString:s,lineWidth:l}=n.options;if(!a||/\n[\t ]+$/.test(i))return FL(i,n);const u=n.indent||(n.forceBlockIndent||dG(i)?"  ":""),c=a==="literal"?!0:a==="folded"||e===Fn.BLOCK_FOLDED?!1:e===Fn.BLOCK_LITERAL?!0:!FLt(i,l,u.length);if(!i)return c?`|
`:`>
`;let d,f;for(f=i.length;f>0;--f){const _=i[f-1];if(_!==`
`&&_!=="	"&&_!==" ")break}let h=i.substring(f);const p=h.indexOf(`
`);p===-1?d="-":i===h||p!==h.length-1?(d="+",o&&o()):d="",h&&(i=i.slice(0,-h.length),h[h.length-1]===`
`&&(h=h.slice(0,-1)),h=h.replace(xJ,`$&${u}`));let g=!1,v,y=-1;for(v=0;v<i.length;++v){const _=i[v];if(_===" ")g=!0;else if(_===`
`)y=v;else break}let m=i.substring(0,y<v?y+1:v);m&&(i=i.substring(m.length),m=m.replace(/\n+/g,`$&${u}`));let S=(g?u?"2":"1":"")+d;if(t&&(S+=" "+s(t.replace(/ ?[\r\n]+/g," ")),r&&r()),!c){const _=i.replace(/\n+/g,`
$&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,"$1$2").replace(/\n+/g,`$&${u}`);let C=!1;const P=cG(n,!0);a!=="folded"&&e!==Fn.BLOCK_FOLDED&&(P.onOverflow=()=>{C=!0});const x=uG(`${m}${_}${h}`,u,CJ,P);if(!C)return`>${S}
${u}${x}`}return i=i.replace(/\n+/g,`$&${u}`),`|${S}
${u}${m}${i}${h}`}function BLt(t,e,i,n){const{type:r,value:o}=t,{actualString:a,implicitKey:s,indent:l,indentStep:u,inFlow:c}=e;if(s&&o.includes(`
`)||c&&/[[\]{},]/.test(o))return FL(o,e);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(o))return s||c||!o.includes(`
`)?FL(o,e):a5(t,e,i,n);if(!s&&!c&&r!==Fn.PLAIN&&o.includes(`
`))return a5(t,e,i,n);if(dG(o)){if(l==="")return e.forceBlockIndent=!0,a5(t,e,i,n);if(s&&l===u)return FL(o,e)}const d=o.replace(/\n+/g,`$&
${l}`);if(a){const f=g=>{var v;return g.default&&g.tag!=="tag:yaml.org,2002:str"&&((v=g.test)==null?void 0:v.test(d))},{compat:h,tags:p}=e.doc.schema;if(p.some(f)||h!=null&&h.some(f))return FL(o,e)}return s?d:uG(d,l,wHe,cG(e,!1))}function Pne(t,e,i,n){const{implicitKey:r,inFlow:o}=e,a=typeof t.value=="string"?t:Object.assign({},t,{value:String(t.value)});let{type:s}=t;s!==Fn.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(a.value)&&(s=Fn.QUOTE_DOUBLE);const l=c=>{switch(c){case Fn.BLOCK_FOLDED:case Fn.BLOCK_LITERAL:return r||o?FL(a.value,e):a5(a,e,i,n);case Fn.QUOTE_DOUBLE:return Bj(a.value,e);case Fn.QUOTE_SINGLE:return TJ(a.value,e);case Fn.PLAIN:return BLt(a,e,i,n);default:return null}};let u=l(s);if(u===null){const{defaultKeyType:c,defaultStringType:d}=e.options,f=r&&c||d;if(u=l(f),u===null)throw new Error(`Unsupported default string type ${f}`)}return u}function AHe(t,e){const i=Object.assign({blockQuote:!0,commentString:NLt,defaultKeyType:null,defaultStringType:"PLAIN",directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:"false",flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:"null",simpleKeys:!1,singleQuote:null,trueStr:"true",verifyAliasOrder:!0},t.schema.toStringOptions,e);let n;switch(i.collectionStyle){case"block":n=!1;break;case"flow":n=!0;break;default:n=null}return{anchors:new Set,doc:t,flowCollectionPadding:i.flowCollectionPadding?" ":"",indent:"",indentStep:typeof i.indent=="number"?" ".repeat(i.indent):"  ",inFlow:n,options:i}}function jLt(t,e){var r;if(e.tag){const o=t.filter(a=>a.tag===e.tag);if(o.length>0)return o.find(a=>a.format===e.format)??o[0]}let i,n;if(gs(e)){n=e.value;let o=t.filter(a=>{var s;return(s=a.identify)==null?void 0:s.call(a,n)});if(o.length>1){const a=o.filter(s=>s.test);a.length>0&&(o=a)}i=o.find(a=>a.format===e.format)??o.find(a=>!a.format)}else n=e,i=t.find(o=>o.nodeClass&&n instanceof o.nodeClass);if(!i){const o=((r=n==null?void 0:n.constructor)==null?void 0:r.name)??(n===null?"null":typeof n);throw new Error(`Tag not resolved for ${o} value`)}return i}function VLt(t,e,{anchors:i,doc:n}){if(!n.directives)return"";const r=[],o=(gs(t)||eu(t))&&t.anchor;o&&PHe(o)&&(i.add(o),r.push(`&${o}`));const a=t.tag??(e.default?null:e.tag);return a&&r.push(n.directives.tagString(a)),r.join(" ")}function nI(t,e,i,n){var l;if(nu(t))return t.toString(e,i,n);if(yR(t)){if(e.doc.directives)return t.toString(e);if((l=e.resolvedAliases)!=null&&l.has(t))throw new TypeError("Cannot stringify circular structure without alias nodes");e.resolvedAliases?e.resolvedAliases.add(t):e.resolvedAliases=new Set([t]),t=t.resolve(e.doc)}let r;const o=ru(t)?t:e.doc.createNode(t,{onTagObj:u=>r=u});r??(r=jLt(e.doc.schema.tags,o));const a=VLt(o,r,e);a.length>0&&(e.indentAtStart=(e.indentAtStart??0)+a.length+1);const s=typeof r.stringify=="function"?r.stringify(o,e,i,n):gs(o)?Pne(o,e,i,n):o.toString(e,i,n);return a?gs(o)||s[0]==="{"||s[0]==="["?`${a} ${s}`:`${a}
${e.indent}${s}`:s}function HLt({key:t,value:e},i,n,r){const{allNullValues:o,doc:a,indent:s,indentStep:l,options:{commentString:u,indentSeq:c,simpleKeys:d}}=i;let f=ru(t)&&t.comment||null;if(d){if(f)throw new Error("With simple keys, key nodes cannot have comments");if(eu(t)||!ru(t)&&typeof t=="object"){const P="With simple keys, collection cannot be used as a key value";throw new Error(P)}}let h=!d&&(!t||f&&e==null&&!i.inFlow||eu(t)||(gs(t)?t.type===Fn.BLOCK_FOLDED||t.type===Fn.BLOCK_LITERAL:typeof t=="object"));i=Object.assign({},i,{allNullValues:!1,implicitKey:!h&&(d||!o),indent:s+l});let p=!1,g=!1,v=nI(t,i,()=>p=!0,()=>g=!0);if(!h&&!i.inFlow&&v.length>1024){if(d)throw new Error("With simple keys, single line scalar must not span more than 1024 characters");h=!0}if(i.inFlow){if(o||e==null)return p&&n&&n(),v===""?"?":h?`? ${v}`:v}else if(o&&!d||e==null&&h)return v=`? ${v}`,f&&!p?v+=qO(v,i.indent,u(f)):g&&r&&r(),v;p&&(f=null),h?(f&&(v+=qO(v,i.indent,u(f))),v=`? ${v}
${s}:`):(v=`${v}:`,f&&(v+=qO(v,i.indent,u(f))));let y,m,b;ru(e)?(y=!!e.spaceBefore,m=e.commentBefore,b=e.comment):(y=!1,m=null,b=null,e&&typeof e=="object"&&(e=a.createNode(e))),i.implicitKey=!1,!h&&!f&&gs(e)&&(i.indentAtStart=v.length+1),g=!1,!c&&l.length>=2&&!i.inFlow&&!h&&sH(e)&&!e.flow&&!e.tag&&!e.anchor&&(i.indent=i.indent.substring(2));let S=!1;const _=nI(e,i,()=>S=!0,()=>g=!0);let C=" ";if(f||y||m){if(C=y?`
`:"",m){const P=u(m);C+=`
${dS(P,i.indent)}`}_===""&&!i.inFlow?C===`
`&&b&&(C=`

`):C+=`
${i.indent}`}else if(!h&&eu(e)){const P=_[0],x=_.indexOf(`
`),E=x!==-1,A=i.inFlow??e.flow??e.items.length===0;if(E||!A){let R=!1;if(E&&(P==="&"||P==="!")){let M=_.indexOf(" ");P==="&"&&M!==-1&&M<x&&_[M+1]==="!"&&(M=_.indexOf(" ",M+1)),(M===-1||x<M)&&(R=!0)}R||(C=`
${i.indent}`)}}else(_===""||_[0]===`
`)&&(C="");return v+=C+_,i.inFlow?S&&n&&n():b&&!S?v+=qO(v,i.indent,u(b)):g&&r&&r(),v}function OHe(t,e){(t==="debug"||t==="warn")&&console.warn(e)}const yU="<<",yS={identify:t=>t===yU||typeof t=="symbol"&&t.description===yU,default:"key",tag:"tag:yaml.org,2002:merge",test:/^<<$/,resolve:()=>Object.assign(new Fn(Symbol(yU)),{addToJSMap:DHe}),stringify:()=>yU},ULt=(t,e)=>(yS.identify(e)||gs(e)&&(!e.type||e.type===Fn.PLAIN)&&yS.identify(e.value))&&(t==null?void 0:t.doc.schema.tags.some(i=>i.tag===yS.tag&&i.default));function DHe(t,e,i){if(i=t&&yR(i)?i.resolve(t.doc):i,sH(i))for(const n of i.items)z7(t,e,n);else if(Array.isArray(i))for(const n of i)z7(t,e,n);else z7(t,e,i)}function z7(t,e,i){const n=t&&yR(i)?i.resolve(t.doc):i;if(!aH(n))throw new Error("Merge sources must be maps or map aliases");const r=n.toJSON(null,t,Map);for(const[o,a]of r)e instanceof Map?e.has(o)||e.set(o,a):e instanceof Set?e.add(o):Object.prototype.hasOwnProperty.call(e,o)||Object.defineProperty(e,o,{value:a,writable:!0,enumerable:!0,configurable:!0});return e}function RHe(t,e,{key:i,value:n}){if(ru(i)&&i.addToJSMap)i.addToJSMap(t,e,n);else if(ULt(t,i))DHe(t,e,n);else{const r=Dg(i,"",t);if(e instanceof Map)e.set(r,Dg(n,r,t));else if(e instanceof Set)e.add(r);else{const o=zLt(i,r,t),a=Dg(n,o,t);o in e?Object.defineProperty(e,o,{value:a,writable:!0,enumerable:!0,configurable:!0}):e[o]=a}}return e}function zLt(t,e,i){if(e===null)return"";if(typeof e!="object")return String(e);if(ru(t)&&(i!=null&&i.doc)){const n=AHe(i.doc,{});n.anchors=new Set;for(const o of i.anchors.keys())n.anchors.add(o.anchor);n.inFlow=!0,n.inStringifyKey=!0;const r=t.toString(n);if(!i.mapKeyWarned){let o=JSON.stringify(r);o.length>40&&(o=o.substring(0,36)+'..."'),OHe(i.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${o}. Set mapAsMap: true to use object keys.`),i.mapKeyWarned=!0}return r}return JSON.stringify(e)}function Cne(t,e,i){const n=eV(t,void 0,i),r=eV(e,void 0,i);return new Hf(n,r)}class Hf{constructor(e,i=null){Object.defineProperty(this,Mg,{value:SHe}),this.key=e,this.value=i}clone(e){let{key:i,value:n}=this;return ru(i)&&(i=i.clone(e)),ru(n)&&(n=n.clone(e)),new Hf(i,n)}toJSON(e,i){const n=i!=null&&i.mapAsMap?new Map:{};return RHe(i,n,this)}toString(e,i,n){return e!=null&&e.doc?HLt(this,e,i,n):JSON.stringify(this)}}function MHe(t,e,i){return(e.inFlow??t.flow?WLt:$Lt)(t,e,i)}function $Lt({comment:t,items:e},i,{blockItemPrefix:n,flowChars:r,itemIndent:o,onChompKeep:a,onComment:s}){const{indent:l,options:{commentString:u}}=i,c=Object.assign({},i,{indent:o,type:null});let d=!1;const f=[];for(let p=0;p<e.length;++p){const g=e[p];let v=null;if(ru(g))!d&&g.spaceBefore&&f.push(""),P$(i,f,g.commentBefore,d),g.comment&&(v=g.comment);else if(nu(g)){const m=ru(g.key)?g.key:null;m&&(!d&&m.spaceBefore&&f.push(""),P$(i,f,m.commentBefore,d))}d=!1;let y=nI(g,c,()=>v=null,()=>d=!0);v&&(y+=qO(y,o,u(v))),d&&v&&(d=!1),f.push(n+y)}let h;if(f.length===0)h=r.start+r.end;else{h=f[0];for(let p=1;p<f.length;++p){const g=f[p];h+=g?`
${l}${g}`:`
`}}return t?(h+=`
`+dS(u(t),l),s&&s()):d&&a&&a(),h}function WLt({items:t},e,{flowChars:i,itemIndent:n}){const{indent:r,indentStep:o,flowCollectionPadding:a,options:{commentString:s}}=e;n+=o;const l=Object.assign({},e,{indent:n,inFlow:!0,type:null});let u=!1,c=0;const d=[];for(let p=0;p<t.length;++p){const g=t[p];let v=null;if(ru(g))g.spaceBefore&&d.push(""),P$(e,d,g.commentBefore,!1),g.comment&&(v=g.comment);else if(nu(g)){const m=ru(g.key)?g.key:null;m&&(m.spaceBefore&&d.push(""),P$(e,d,m.commentBefore,!1),m.comment&&(u=!0));const b=ru(g.value)?g.value:null;b?(b.comment&&(v=b.comment),b.commentBefore&&(u=!0)):g.value==null&&(m!=null&&m.comment)&&(v=m.comment)}v&&(u=!0);let y=nI(g,l,()=>v=null);p<t.length-1&&(y+=","),v&&(y+=qO(y,n,s(v))),!u&&(d.length>c||y.includes(`
`))&&(u=!0),d.push(y),c=d.length}const{start:f,end:h}=i;if(d.length===0)return f+h;if(!u){const p=d.reduce((g,v)=>g+v.length+2,2);u=e.options.lineWidth>0&&p>e.options.lineWidth}if(u){let p=f;for(const g of d)p+=g?`
${o}${r}${g}`:`
`;return`${p}
${r}${h}`}else return`${f}${a}${d.join(" ")}${a}${h}`}function P$({indent:t,options:{commentString:e}},i,n,r){if(n&&r&&(n=n.replace(/^\n+/,"")),n){const o=dS(e(n),t);i.push(o.trimStart())}}function XO(t,e){const i=gs(e)?e.value:e;for(const n of t)if(nu(n)&&(n.key===e||n.key===i||gs(n.key)&&n.key.value===i))return n}class Tg extends EHe{static get tagName(){return"tag:yaml.org,2002:map"}constructor(e){super(mP,e),this.items=[]}static from(e,i,n){const{keepUndefined:r,replacer:o}=n,a=new this(e),s=(l,u)=>{if(typeof o=="function")u=o.call(i,l,u);else if(Array.isArray(o)&&!o.includes(l))return;(u!==void 0||r)&&a.items.push(Cne(l,u,n))};if(i instanceof Map)for(const[l,u]of i)s(l,u);else if(i&&typeof i=="object")for(const l of Object.keys(i))s(l,i[l]);return typeof e.sortMapEntries=="function"&&a.items.sort(e.sortMapEntries),a}add(e,i){var a;let n;nu(e)?n=e:!e||typeof e!="object"||!("key"in e)?n=new Hf(e,e==null?void 0:e.value):n=new Hf(e.key,e.value);const r=XO(this.items,n.key),o=(a=this.schema)==null?void 0:a.sortMapEntries;if(r){if(!i)throw new Error(`Key ${n.key} already set`);gs(r.value)&&xHe(n.value)?r.value.value=n.value:r.value=n.value}else if(o){const s=this.items.findIndex(l=>o(n,l)<0);s===-1?this.items.push(n):this.items.splice(s,0,n)}else this.items.push(n)}delete(e){const i=XO(this.items,e);return i?this.items.splice(this.items.indexOf(i),1).length>0:!1}get(e,i){const n=XO(this.items,e),r=n==null?void 0:n.value;return(!i&&gs(r)?r.value:r)??void 0}has(e){return!!XO(this.items,e)}set(e,i){this.add(new Hf(e,i),!0)}toJSON(e,i,n){const r=n?new n:i!=null&&i.mapAsMap?new Map:{};i!=null&&i.onCreate&&i.onCreate(r);for(const o of this.items)RHe(i,r,o);return r}toString(e,i,n){if(!e)return JSON.stringify(this);for(const r of this.items)if(!nu(r))throw new Error(`Map items must all be pairs; found ${JSON.stringify(r)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),MHe(this,e,{blockItemPrefix:"",flowChars:{start:"{",end:"}"},itemIndent:e.indent||"",onChompKeep:n,onComment:i})}}const JI={collection:"map",default:!0,nodeClass:Tg,tag:"tag:yaml.org,2002:map",resolve(t,e){return aH(t)||e("Expected a mapping for this tag"),t},createNode:(t,e,i)=>Tg.from(t,e,i)};class ID extends EHe{static get tagName(){return"tag:yaml.org,2002:seq"}constructor(e){super(KI,e),this.items=[]}add(e){this.items.push(e)}delete(e){const i=mU(e);return typeof i!="number"?!1:this.items.splice(i,1).length>0}get(e,i){const n=mU(e);if(typeof n!="number")return;const r=this.items[n];return!i&&gs(r)?r.value:r}has(e){const i=mU(e);return typeof i=="number"&&i<this.items.length}set(e,i){const n=mU(e);if(typeof n!="number")throw new Error(`Expected a valid index, not ${e}.`);const r=this.items[n];gs(r)&&xHe(i)?r.value=i:this.items[n]=i}toJSON(e,i){const n=[];i!=null&&i.onCreate&&i.onCreate(n);let r=0;for(const o of this.items)n.push(Dg(o,String(r++),i));return n}toString(e,i,n){return e?MHe(this,e,{blockItemPrefix:"- ",flowChars:{start:"[",end:"]"},itemIndent:(e.indent||"")+"  ",onChompKeep:n,onComment:i}):JSON.stringify(this)}static from(e,i,n){const{replacer:r}=n,o=new this(e);if(i&&Symbol.iterator in Object(i)){let a=0;for(let s of i){if(typeof r=="function"){const l=i instanceof Set?s:String(a++);s=r.call(i,l,s)}o.items.push(eV(s,void 0,n))}}return o}}function mU(t){let e=gs(t)?t.value:t;return e&&typeof e=="string"&&(e=Number(e)),typeof e=="number"&&Number.isInteger(e)&&e>=0?e:null}const QI={collection:"seq",default:!0,nodeClass:ID,tag:"tag:yaml.org,2002:seq",resolve(t,e){return sH(t)||e("Expected a sequence for this tag"),t},createNode:(t,e,i)=>ID.from(t,e,i)},fG={identify:t=>typeof t=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:t=>t,stringify(t,e,i,n){return e=Object.assign({actualString:!0},e),Pne(t,e,i,n)}},hG={identify:t=>t==null,createNode:()=>new Fn(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new Fn(null),stringify:({source:t},e)=>typeof t=="string"&&hG.test.test(t)?t:e.options.nullStr},Tne={identify:t=>typeof t=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:t=>new Fn(t[0]==="t"||t[0]==="T"),stringify({source:t,value:e},i){if(t&&Tne.test.test(t)){const n=t[0]==="t"||t[0]==="T";if(e===n)return t}return e?i.options.trueStr:i.options.falseStr}};function Yv({format:t,minFractionDigits:e,tag:i,value:n}){if(typeof n=="bigint")return String(n);const r=typeof n=="number"?n:Number(n);if(!isFinite(r))return isNaN(r)?".nan":r<0?"-.inf":".inf";let o=Object.is(n,-0)?"-0":JSON.stringify(n);if(!t&&e&&(!i||i==="tag:yaml.org,2002:float")&&/^\d/.test(o)){let a=o.indexOf(".");a<0&&(a=o.length,o+=".");let s=e-(o.length-a-1);for(;s-- >0;)o+="0"}return o}const LHe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:t=>t.slice(-3).toLowerCase()==="nan"?NaN:t[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Yv},kHe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:t=>parseFloat(t),stringify(t){const e=Number(t.value);return isFinite(e)?e.toExponential():Yv(t)}},IHe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(t){const e=new Fn(parseFloat(t)),i=t.indexOf(".");return i!==-1&&t[t.length-1]==="0"&&(e.minFractionDigits=t.length-i-1),e},stringify:Yv},pG=t=>typeof t=="bigint"||Number.isInteger(t),xne=(t,e,i,{intAsBigInt:n})=>n?BigInt(t):parseInt(t.substring(e),i);function NHe(t,e,i){const{value:n}=t;return pG(n)&&n>=0?i+n.toString(e):Yv(t)}const FHe={identify:t=>pG(t)&&t>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^0o[0-7]+$/,resolve:(t,e,i)=>xne(t,2,8,i),stringify:t=>NHe(t,8,"0o")},BHe={identify:pG,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9]+$/,resolve:(t,e,i)=>xne(t,0,10,i),stringify:Yv},jHe={identify:t=>pG(t)&&t>=0,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^0x[0-9a-fA-F]+$/,resolve:(t,e,i)=>xne(t,2,16,i),stringify:t=>NHe(t,16,"0x")},GLt=[JI,QI,fG,hG,Tne,FHe,BHe,jHe,LHe,kHe,IHe];function Oxe(t){return typeof t=="bigint"||Number.isInteger(t)}const bU=({value:t})=>JSON.stringify(t),YLt=[{identify:t=>typeof t=="string",default:!0,tag:"tag:yaml.org,2002:str",resolve:t=>t,stringify:bU},{identify:t=>t==null,createNode:()=>new Fn(null),default:!0,tag:"tag:yaml.org,2002:null",test:/^null$/,resolve:()=>null,stringify:bU},{identify:t=>typeof t=="boolean",default:!0,tag:"tag:yaml.org,2002:bool",test:/^true$|^false$/,resolve:t=>t==="true",stringify:bU},{identify:Oxe,default:!0,tag:"tag:yaml.org,2002:int",test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(t,e,{intAsBigInt:i})=>i?BigInt(t):parseInt(t,10),stringify:({value:t})=>Oxe(t)?t.toString():JSON.stringify(t)},{identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:t=>parseFloat(t),stringify:bU}],qLt={default:!0,tag:"",test:/^/,resolve(t,e){return e(`Unresolved plain scalar ${JSON.stringify(t)}`),t}},XLt=[JI,QI].concat(YLt,qLt),Ene={identify:t=>t instanceof Uint8Array,default:!1,tag:"tag:yaml.org,2002:binary",resolve(t,e){if(typeof atob=="function"){const i=atob(t.replace(/[\n\r]/g,"")),n=new Uint8Array(i.length);for(let r=0;r<i.length;++r)n[r]=i.charCodeAt(r);return n}else return e("This environment does not support reading binary tags; either Buffer or atob is required"),t},stringify({comment:t,type:e,value:i},n,r,o){if(!i)return"";const a=i;let s;if(typeof btoa=="function"){let l="";for(let u=0;u<a.length;++u)l+=String.fromCharCode(a[u]);s=btoa(l)}else throw new Error("This environment does not support writing binary tags; either Buffer or btoa is required");if(e??(e=Fn.BLOCK_LITERAL),e!==Fn.QUOTE_DOUBLE){const l=Math.max(n.options.lineWidth-n.indent.length,n.options.minContentWidth),u=Math.ceil(s.length/l),c=new Array(u);for(let d=0,f=0;d<u;++d,f+=l)c[d]=s.substr(f,l);s=c.join(e===Fn.BLOCK_LITERAL?`
`:" ")}return Pne({comment:t,type:e,value:s},n,r,o)}};function VHe(t,e){if(sH(t))for(let i=0;i<t.items.length;++i){let n=t.items[i];if(!nu(n)){if(aH(n)){n.items.length>1&&e("Each pair must have its own sequence indicator");const r=n.items[0]||new Hf(new Fn(null));if(n.commentBefore&&(r.key.commentBefore=r.key.commentBefore?`${n.commentBefore}
${r.key.commentBefore}`:n.commentBefore),n.comment){const o=r.value??r.key;o.comment=o.comment?`${n.comment}
${o.comment}`:n.comment}n=r}t.items[i]=nu(n)?n:new Hf(n)}}else e("Expected a sequence for this tag");return t}function HHe(t,e,i){const{replacer:n}=i,r=new ID(t);r.tag="tag:yaml.org,2002:pairs";let o=0;if(e&&Symbol.iterator in Object(e))for(let a of e){typeof n=="function"&&(a=n.call(e,String(o++),a));let s,l;if(Array.isArray(a))if(a.length===2)s=a[0],l=a[1];else throw new TypeError(`Expected [key, value] tuple: ${a}`);else if(a&&a instanceof Object){const u=Object.keys(a);if(u.length===1)s=u[0],l=a[s];else throw new TypeError(`Expected tuple with one key, not ${u.length} keys`)}else s=a;r.items.push(Cne(s,l,i))}return r}const wne={collection:"seq",default:!1,tag:"tag:yaml.org,2002:pairs",resolve:VHe,createNode:HHe};class JL extends ID{constructor(){super(),this.add=Tg.prototype.add.bind(this),this.delete=Tg.prototype.delete.bind(this),this.get=Tg.prototype.get.bind(this),this.has=Tg.prototype.has.bind(this),this.set=Tg.prototype.set.bind(this),this.tag=JL.tag}toJSON(e,i){if(!i)return super.toJSON(e);const n=new Map;i!=null&&i.onCreate&&i.onCreate(n);for(const r of this.items){let o,a;if(nu(r)?(o=Dg(r.key,"",i),a=Dg(r.value,o,i)):o=Dg(r,"",i),n.has(o))throw new Error("Ordered maps must not include duplicate keys");n.set(o,a)}return n}static from(e,i,n){const r=HHe(e,i,n),o=new this;return o.items=r.items,o}}JL.tag="tag:yaml.org,2002:omap";const Ane={collection:"seq",identify:t=>t instanceof Map,nodeClass:JL,default:!1,tag:"tag:yaml.org,2002:omap",resolve(t,e){const i=VHe(t,e),n=[];for(const{key:r}of i.items)gs(r)&&(n.includes(r.value)?e(`Ordered maps must not include duplicate keys: ${r.value}`):n.push(r.value));return Object.assign(new JL,i)},createNode:(t,e,i)=>JL.from(t,e,i)};function UHe({value:t,source:e},i){return e&&(t?zHe:$He).test.test(e)?e:t?i.options.trueStr:i.options.falseStr}const zHe={identify:t=>t===!0,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new Fn(!0),stringify:UHe},$He={identify:t=>t===!1,default:!0,tag:"tag:yaml.org,2002:bool",test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new Fn(!1),stringify:UHe},KLt={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:t=>t.slice(-3).toLowerCase()==="nan"?NaN:t[0]==="-"?Number.NEGATIVE_INFINITY:Number.POSITIVE_INFINITY,stringify:Yv},ZLt={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"EXP",test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:t=>parseFloat(t.replace(/_/g,"")),stringify(t){const e=Number(t.value);return isFinite(e)?e.toExponential():Yv(t)}},JLt={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(t){const e=new Fn(parseFloat(t.replace(/_/g,""))),i=t.indexOf(".");if(i!==-1){const n=t.substring(i+1).replace(/_/g,"");n[n.length-1]==="0"&&(e.minFractionDigits=n.length)}return e},stringify:Yv},lH=t=>typeof t=="bigint"||Number.isInteger(t);function gG(t,e,i,{intAsBigInt:n}){const r=t[0];if((r==="-"||r==="+")&&(e+=1),t=t.substring(e).replace(/_/g,""),n){switch(i){case 2:t=`0b${t}`;break;case 8:t=`0o${t}`;break;case 16:t=`0x${t}`;break}const a=BigInt(t);return r==="-"?BigInt(-1)*a:a}const o=parseInt(t,i);return r==="-"?-1*o:o}function One(t,e,i){const{value:n}=t;if(lH(n)){const r=n.toString(e);return n<0?"-"+i+r.substr(1):i+r}return Yv(t)}const QLt={identify:lH,default:!0,tag:"tag:yaml.org,2002:int",format:"BIN",test:/^[-+]?0b[0-1_]+$/,resolve:(t,e,i)=>gG(t,2,2,i),stringify:t=>One(t,2,"0b")},ekt={identify:lH,default:!0,tag:"tag:yaml.org,2002:int",format:"OCT",test:/^[-+]?0[0-7_]+$/,resolve:(t,e,i)=>gG(t,1,8,i),stringify:t=>One(t,8,"0")},tkt={identify:lH,default:!0,tag:"tag:yaml.org,2002:int",test:/^[-+]?[0-9][0-9_]*$/,resolve:(t,e,i)=>gG(t,0,10,i),stringify:Yv},rkt={identify:lH,default:!0,tag:"tag:yaml.org,2002:int",format:"HEX",test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(t,e,i)=>gG(t,2,16,i),stringify:t=>One(t,16,"0x")};class QL extends Tg{constructor(e){super(e),this.tag=QL.tag}add(e){let i;nu(e)?i=e:e&&typeof e=="object"&&"key"in e&&"value"in e&&e.value===null?i=new Hf(e.key,null):i=new Hf(e,null),XO(this.items,i.key)||this.items.push(i)}get(e,i){const n=XO(this.items,e);return!i&&nu(n)?gs(n.key)?n.key.value:n.key:n}set(e,i){if(typeof i!="boolean")throw new Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof i}`);const n=XO(this.items,e);n&&!i?this.items.splice(this.items.indexOf(n),1):!n&&i&&this.items.push(new Hf(e))}toJSON(e,i){return super.toJSON(e,i,Set)}toString(e,i,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),i,n);throw new Error("Set items must all have null values")}static from(e,i,n){const{replacer:r}=n,o=new this(e);if(i&&Symbol.iterator in Object(i))for(let a of i)typeof r=="function"&&(a=r.call(i,a,a)),o.items.push(Cne(a,null,n));return o}}QL.tag="tag:yaml.org,2002:set";const Dne={collection:"map",identify:t=>t instanceof Set,nodeClass:QL,default:!1,tag:"tag:yaml.org,2002:set",createNode:(t,e,i)=>QL.from(t,e,i),resolve(t,e){if(aH(t)){if(t.hasAllNullValues(!0))return Object.assign(new QL,t);e("Set items must all have null values")}else e("Expected a mapping for this tag");return t}};function Rne(t,e){const i=t[0],n=i==="-"||i==="+"?t.substring(1):t,r=a=>e?BigInt(a):Number(a),o=n.replace(/_/g,"").split(":").reduce((a,s)=>a*r(60)+r(s),r(0));return i==="-"?r(-1)*o:o}function WHe(t){let{value:e}=t,i=a=>a;if(typeof e=="bigint")i=a=>BigInt(a);else if(isNaN(e)||!isFinite(e))return Yv(t);let n="";e<0&&(n="-",e*=i(-1));const r=i(60),o=[e%r];return e<60?o.unshift(0):(e=(e-o[0])/r,o.unshift(e%r),e>=60&&(e=(e-o[0])/r,o.unshift(e))),n+o.map(a=>String(a).padStart(2,"0")).join(":").replace(/000000\d*$/,"")}const GHe={identify:t=>typeof t=="bigint"||Number.isInteger(t),default:!0,tag:"tag:yaml.org,2002:int",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(t,e,{intAsBigInt:i})=>Rne(t,i),stringify:WHe},YHe={identify:t=>typeof t=="number",default:!0,tag:"tag:yaml.org,2002:float",format:"TIME",test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:t=>Rne(t,!1),stringify:WHe},vG={identify:t=>t instanceof Date,default:!0,tag:"tag:yaml.org,2002:timestamp",test:RegExp("^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$"),resolve(t){const e=t.match(vG.test);if(!e)throw new Error("!!timestamp expects a date, starting with yyyy-mm-dd");const[,i,n,r,o,a,s]=e.map(Number),l=e[7]?Number((e[7]+"00").substr(1,3)):0;let u=Date.UTC(i,n-1,r,o||0,a||0,s||0,l);const c=e[8];if(c&&c!=="Z"){let d=Rne(c,!1);Math.abs(d)<30&&(d*=60),u-=6e4*d}return new Date(u)},stringify:({value:t})=>(t==null?void 0:t.toISOString().replace(/(T00:00:00)?\.000Z$/,""))??""},Dxe=[JI,QI,fG,hG,zHe,$He,QLt,ekt,tkt,rkt,KLt,ZLt,JLt,Ene,yS,Ane,wne,Dne,GHe,YHe,vG],Rxe=new Map([["core",GLt],["failsafe",[JI,QI,fG]],["json",XLt],["yaml11",Dxe],["yaml-1.1",Dxe]]),Mxe={binary:Ene,bool:Tne,float:IHe,floatExp:kHe,floatNaN:LHe,floatTime:YHe,int:BHe,intHex:jHe,intOct:FHe,intTime:GHe,map:JI,merge:yS,null:hG,omap:Ane,pairs:wne,seq:QI,set:Dne,timestamp:vG},ikt={"tag:yaml.org,2002:binary":Ene,"tag:yaml.org,2002:merge":yS,"tag:yaml.org,2002:omap":Ane,"tag:yaml.org,2002:pairs":wne,"tag:yaml.org,2002:set":Dne,"tag:yaml.org,2002:timestamp":vG};function $7(t,e,i){const n=Rxe.get(e);if(n&&!t)return i&&!n.includes(yS)?n.concat(yS):n.slice();let r=n;if(!r)if(Array.isArray(t))r=[];else{const o=Array.from(Rxe.keys()).filter(a=>a!=="yaml11").map(a=>JSON.stringify(a)).join(", ");throw new Error(`Unknown schema "${e}"; use one of ${o} or define customTags array`)}if(Array.isArray(t))for(const o of t)r=r.concat(o);else typeof t=="function"&&(r=t(r.slice()));return i&&(r=r.concat(yS)),r.reduce((o,a)=>{const s=typeof a=="string"?Mxe[a]:a;if(!s){const l=JSON.stringify(a),u=Object.keys(Mxe).map(c=>JSON.stringify(c)).join(", ");throw new Error(`Unknown custom tag ${l}; use one of ${u}`)}return o.includes(s)||o.push(s),o},[])}const nkt=(t,e)=>t.key<e.key?-1:t.key>e.key?1:0;class Mne{constructor({compat:e,customTags:i,merge:n,resolveKnownTags:r,schema:o,sortMapEntries:a,toStringDefaults:s}){this.compat=Array.isArray(e)?$7(e,"compat"):e?$7(null,e):null,this.name=typeof o=="string"&&o||"core",this.knownTags=r?ikt:{},this.tags=$7(i,this.name,n),this.toStringOptions=s??null,Object.defineProperty(this,mP,{value:JI}),Object.defineProperty(this,bm,{value:fG}),Object.defineProperty(this,KI,{value:QI}),this.sortMapEntries=typeof a=="function"?a:a===!0?nkt:null}clone(){const e=Object.create(Mne.prototype,Object.getOwnPropertyDescriptors(this));return e.tags=this.tags.slice(),e}}function okt(t,e){var l;const i=[];let n=e.directives===!0;if(e.directives!==!1&&t.directives){const u=t.directives.toString(t);u?(i.push(u),n=!0):t.directives.docStart&&(n=!0)}n&&i.push("---");const r=AHe(t,e),{commentString:o}=r.options;if(t.commentBefore){i.length!==1&&i.unshift("");const u=o(t.commentBefore);i.unshift(dS(u,""))}let a=!1,s=null;if(t.contents){if(ru(t.contents)){if(t.contents.spaceBefore&&n&&i.push(""),t.contents.commentBefore){const d=o(t.contents.commentBefore);i.push(dS(d,""))}r.forceBlockIndent=!!t.comment,s=t.contents.comment}const u=s?void 0:()=>a=!0;let c=nI(t.contents,r,()=>s=null,u);s&&(c+=qO(c,"",o(s))),(c[0]==="|"||c[0]===">")&&i[i.length-1]==="---"?i[i.length-1]=`--- ${c}`:i.push(c)}else i.push(nI(t.contents,r));if((l=t.directives)!=null&&l.docEnd)if(t.comment){const u=o(t.comment);u.includes(`
`)?(i.push("..."),i.push(dS(u,""))):i.push(`... ${u}`)}else i.push("...");else{let u=t.comment;u&&a&&(u=u.replace(/^\n+/,"")),u&&((!a||s)&&i[i.length-1]!==""&&i.push(""),i.push(dS(o(u),"")))}return i.join(`
`)+`
`}let qHe=class XHe{constructor(e,i,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,Mg,{value:PJ});let r=null;typeof i=="function"||Array.isArray(i)?r=i:n===void 0&&i&&(n=i,i=void 0);const o=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:"warn",prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:"1.2"},n);this.options=o;let{version:a}=o;n!=null&&n._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(a=this.directives.yaml.version)):this.directives=new Af({version:a}),this.setSchema(a,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){const e=Object.create(XHe.prototype,{[Mg]:{value:PJ}});return e.commentBefore=this.commentBefore,e.comment=this.comment,e.errors=this.errors.slice(),e.warnings=this.warnings.slice(),e.options=Object.assign({},this.options),this.directives&&(e.directives=this.directives.clone()),e.schema=this.schema.clone(),e.contents=ru(this.contents)?this.contents.clone(e.schema):this.contents,this.range&&(e.range=this.range.slice()),e}add(e){dL(this.contents)&&this.contents.add(e)}addIn(e,i){dL(this.contents)&&this.contents.addIn(e,i)}createAlias(e,i){if(!e.anchor){const n=CHe(this);e.anchor=!i||n.has(i)?THe(i||"a",n):i}return new _ne(e.anchor)}createNode(e,i,n){let r;if(typeof i=="function")e=i.call({"":e},"",e),r=i;else if(Array.isArray(i)){const v=m=>typeof m=="number"||m instanceof String||m instanceof Number,y=i.filter(v).map(String);y.length>0&&(i=i.concat(y)),r=i}else n===void 0&&i&&(n=i,i=void 0);const{aliasDuplicateObjects:o,anchorPrefix:a,flow:s,keepUndefined:l,onTagObj:u,tag:c}=n??{},{onAnchor:d,setAnchors:f,sourceObjects:h}=LLt(this,a||"a"),p={aliasDuplicateObjects:o??!0,keepUndefined:l??!1,onAnchor:d,onTagObj:u,replacer:r,schema:this.schema,sourceObjects:h},g=eV(e,c,p);return s&&eu(g)&&(g.flow=!0),f(),g}createPair(e,i,n={}){const r=this.createNode(e,null,n),o=this.createNode(i,null,n);return new Hf(r,o)}delete(e){return dL(this.contents)?this.contents.delete(e):!1}deleteIn(e){return hj(e)?this.contents==null?!1:(this.contents=null,!0):dL(this.contents)?this.contents.deleteIn(e):!1}get(e,i){return eu(this.contents)?this.contents.get(e,i):void 0}getIn(e,i){return hj(e)?!i&&gs(this.contents)?this.contents.value:this.contents:eu(this.contents)?this.contents.getIn(e,i):void 0}has(e){return eu(this.contents)?this.contents.has(e):!1}hasIn(e){return hj(e)?this.contents!==void 0:eu(this.contents)?this.contents.hasIn(e):!1}set(e,i){this.contents==null?this.contents=_$(this.schema,[e],i):dL(this.contents)&&this.contents.set(e,i)}setIn(e,i){hj(e)?this.contents=i:this.contents==null?this.contents=_$(this.schema,Array.from(e),i):dL(this.contents)&&this.contents.setIn(e,i)}setSchema(e,i={}){typeof e=="number"&&(e=String(e));let n;switch(e){case"1.1":this.directives?this.directives.yaml.version="1.1":this.directives=new Af({version:"1.1"}),n={resolveKnownTags:!1,schema:"yaml-1.1"};break;case"1.2":case"next":this.directives?this.directives.yaml.version=e:this.directives=new Af({version:e}),n={resolveKnownTags:!0,schema:"core"};break;case null:this.directives&&delete this.directives,n=null;break;default:{const r=JSON.stringify(e);throw new Error(`Expected '1.1', '1.2' or null as first argument, but found: ${r}`)}}if(i.schema instanceof Object)this.schema=i.schema;else if(n)this.schema=new Mne(Object.assign(n,i));else throw new Error("With a null YAML version, the { schema: Schema } option is required")}toJS({json:e,jsonArg:i,mapAsMap:n,maxAliasCount:r,onAnchor:o,reviver:a}={}){const s={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r=="number"?r:100},l=Dg(this.contents,i??"",s);if(typeof o=="function")for(const{count:u,res:c}of s.anchors.values())o(c,u);return typeof a=="function"?NL(a,{"":l},"",l):l}toJSON(e,i){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:i})}toString(e={}){if(this.errors.length>0)throw new Error("Document with errors cannot be stringified");if("indent"in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){const i=JSON.stringify(e.indent);throw new Error(`"indent" option must be a positive integer, not ${i}`)}return okt(this,e)}};function dL(t){if(eu(t))return!0;throw new Error("Expected a YAML collection as document contents")}class KHe extends Error{constructor(e,i,n,r){super(),this.name=e,this.code=n,this.message=r,this.pos=i}}class pj extends KHe{constructor(e,i,n){super("YAMLParseError",e,i,n)}}class akt extends KHe{constructor(e,i,n){super("YAMLWarning",e,i,n)}}const Lxe=(t,e)=>i=>{if(i.pos[0]===-1)return;i.linePos=i.pos.map(s=>e.linePos(s));const{line:n,col:r}=i.linePos[0];i.message+=` at line ${n}, column ${r}`;let o=r-1,a=t.substring(e.lineStarts[n-1],e.lineStarts[n]).replace(/[\n\r]+$/,"");if(o>=60&&a.length>80){const s=Math.min(o-39,a.length-79);a="…"+a.substring(s),o-=s-1}if(a.length>80&&(a=a.substring(0,79)+"…"),n>1&&/^ *$/.test(a.substring(0,o))){let s=t.substring(e.lineStarts[n-2],e.lineStarts[n-1]);s.length>80&&(s=s.substring(0,79)+`…
`),a=s+a}if(/[^ ]/.test(a)){let s=1;const l=i.linePos[1];(l==null?void 0:l.line)===n&&l.col>r&&(s=Math.max(1,Math.min(l.col-r,80-o)));const u=" ".repeat(o)+"^".repeat(s);i.message+=`:

${a}
${u}
`}};function oI(t,{flow:e,indicator:i,next:n,offset:r,onError:o,parentIndent:a,startOnNewline:s}){let l=!1,u=s,c=s,d="",f="",h=!1,p=!1,g=null,v=null,y=null,m=null,b=null,S=null,_=null;for(const x of t)switch(p&&(x.type!=="space"&&x.type!=="newline"&&x.type!=="comma"&&o(x.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),p=!1),g&&(u&&x.type!=="comment"&&x.type!=="newline"&&o(g,"TAB_AS_INDENT","Tabs are not allowed as indentation"),g=null),x.type){case"space":!e&&(i!=="doc-start"||(n==null?void 0:n.type)!=="flow-collection")&&x.source.includes("	")&&(g=x),c=!0;break;case"comment":{c||o(x,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const E=x.source.substring(1)||" ";d?d+=f+E:d=E,f="",u=!1;break}case"newline":u?d?d+=x.source:(!S||i!=="seq-item-ind")&&(l=!0):f+=x.source,u=!0,h=!0,(v||y)&&(m=x),c=!0;break;case"anchor":v&&o(x,"MULTIPLE_ANCHORS","A node can have at most one anchor"),x.source.endsWith(":")&&o(x.offset+x.source.length-1,"BAD_ALIAS","Anchor ending in : is ambiguous",!0),v=x,_??(_=x.offset),u=!1,c=!1,p=!0;break;case"tag":{y&&o(x,"MULTIPLE_TAGS","A node can have at most one tag"),y=x,_??(_=x.offset),u=!1,c=!1,p=!0;break}case i:(v||y)&&o(x,"BAD_PROP_ORDER",`Anchors and tags must be after the ${x.source} indicator`),S&&o(x,"UNEXPECTED_TOKEN",`Unexpected ${x.source} in ${e??"collection"}`),S=x,u=i==="seq-item-ind"||i==="explicit-key-ind",c=!1;break;case"comma":if(e){b&&o(x,"UNEXPECTED_TOKEN",`Unexpected , in ${e}`),b=x,u=!1,c=!1;break}default:o(x,"UNEXPECTED_TOKEN",`Unexpected ${x.type} token`),u=!1,c=!1}const C=t[t.length-1],P=C?C.offset+C.source.length:r;return p&&n&&n.type!=="space"&&n.type!=="newline"&&n.type!=="comma"&&(n.type!=="scalar"||n.source!=="")&&o(n.offset,"MISSING_CHAR","Tags and anchors must be separated from the next token by white space"),g&&(u&&g.indent<=a||(n==null?void 0:n.type)==="block-map"||(n==null?void 0:n.type)==="block-seq")&&o(g,"TAB_AS_INDENT","Tabs are not allowed as indentation"),{comma:b,found:S,spaceBefore:l,comment:d,hasNewline:h,anchor:v,tag:y,newlineAfterProp:m,end:P,start:_??P}}function tV(t){if(!t)return null;switch(t.type){case"alias":case"scalar":case"double-quoted-scalar":case"single-quoted-scalar":if(t.source.includes(`
`))return!0;if(t.end){for(const e of t.end)if(e.type==="newline")return!0}return!1;case"flow-collection":for(const e of t.items){for(const i of e.start)if(i.type==="newline")return!0;if(e.sep){for(const i of e.sep)if(i.type==="newline")return!0}if(tV(e.key)||tV(e.value))return!0}return!1;default:return!0}}function EJ(t,e,i){if((e==null?void 0:e.type)==="flow-collection"){const n=e.end[0];n.indent===t&&(n.source==="]"||n.source==="}")&&tV(e)&&i(n,"BAD_INDENT","Flow end indicator should be more indented than parent",!0)}}function ZHe(t,e,i){const{uniqueKeys:n}=t.options;if(n===!1)return!1;const r=typeof n=="function"?n:(o,a)=>o===a||gs(o)&&gs(a)&&o.value===a.value;return e.some(o=>r(o.key,i))}const kxe="All mapping items must start at the same column";function skt({composeNode:t,composeEmptyNode:e},i,n,r,o){var c;const a=(o==null?void 0:o.nodeClass)??Tg,s=new a(i.schema);i.atRoot&&(i.atRoot=!1);let l=n.offset,u=null;for(const d of n.items){const{start:f,key:h,sep:p,value:g}=d,v=oI(f,{indicator:"explicit-key-ind",next:h??(p==null?void 0:p[0]),offset:l,onError:r,parentIndent:n.indent,startOnNewline:!0}),y=!v.found;if(y){if(h&&(h.type==="block-seq"?r(l,"BLOCK_AS_IMPLICIT_KEY","A block sequence may not be used as an implicit map key"):"indent"in h&&h.indent!==n.indent&&r(l,"BAD_INDENT",kxe)),!v.anchor&&!v.tag&&!p){u=v.end,v.comment&&(s.comment?s.comment+=`
`+v.comment:s.comment=v.comment);continue}(v.newlineAfterProp||tV(h))&&r(h??f[f.length-1],"MULTILINE_IMPLICIT_KEY","Implicit keys need to be on a single line")}else((c=v.found)==null?void 0:c.indent)!==n.indent&&r(l,"BAD_INDENT",kxe);i.atKey=!0;const m=v.end,b=h?t(i,h,v,r):e(i,m,f,null,v,r);i.schema.compat&&EJ(n.indent,h,r),i.atKey=!1,ZHe(i,s.items,b)&&r(m,"DUPLICATE_KEY","Map keys must be unique");const S=oI(p??[],{indicator:"map-value-ind",next:g,offset:b.range[2],onError:r,parentIndent:n.indent,startOnNewline:!h||h.type==="block-scalar"});if(l=S.end,S.found){y&&((g==null?void 0:g.type)==="block-map"&&!S.hasNewline&&r(l,"BLOCK_AS_IMPLICIT_KEY","Nested mappings are not allowed in compact mappings"),i.options.strict&&v.start<S.found.offset-1024&&r(b.range,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit block mapping key"));const _=g?t(i,g,S,r):e(i,l,p,null,S,r);i.schema.compat&&EJ(n.indent,g,r),l=_.range[2];const C=new Hf(b,_);i.options.keepSourceTokens&&(C.srcToken=d),s.items.push(C)}else{y&&r(b.range,"MISSING_CHAR","Implicit map keys need to be followed by map values"),S.comment&&(b.comment?b.comment+=`
`+S.comment:b.comment=S.comment);const _=new Hf(b);i.options.keepSourceTokens&&(_.srcToken=d),s.items.push(_)}}return u&&u<l&&r(u,"IMPOSSIBLE","Map comment with trailing content"),s.range=[n.offset,l,u??l],s}function lkt({composeNode:t,composeEmptyNode:e},i,n,r,o){const a=(o==null?void 0:o.nodeClass)??ID,s=new a(i.schema);i.atRoot&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let l=n.offset,u=null;for(const{start:c,value:d}of n.items){const f=oI(c,{indicator:"seq-item-ind",next:d,offset:l,onError:r,parentIndent:n.indent,startOnNewline:!0});if(!f.found)if(f.anchor||f.tag||d)(d==null?void 0:d.type)==="block-seq"?r(f.end,"BAD_INDENT","All sequence items must start at the same column"):r(l,"MISSING_CHAR","Sequence item without - indicator");else{u=f.end,f.comment&&(s.comment=f.comment);continue}const h=d?t(i,d,f,r):e(i,f.end,c,null,f,r);i.schema.compat&&EJ(n.indent,d,r),l=h.range[2],s.items.push(h)}return s.range=[n.offset,l,u??l],s}function uH(t,e,i,n){let r="";if(t){let o=!1,a="";for(const s of t){const{source:l,type:u}=s;switch(u){case"space":o=!0;break;case"comment":{i&&!o&&n(s,"MISSING_CHAR","Comments must be separated from other tokens by white space characters");const c=l.substring(1)||" ";r?r+=a+c:r=c,a="";break}case"newline":r&&(a+=l),o=!0;break;default:n(s,"UNEXPECTED_TOKEN",`Unexpected ${u} at node end`)}e+=l.length}}return{comment:r,offset:e}}const W7="Block collections are not allowed within flow collections",G7=t=>t&&(t.type==="block-map"||t.type==="block-seq");function ukt({composeNode:t,composeEmptyNode:e},i,n,r,o){var v;const a=n.start.source==="{",s=a?"flow map":"flow sequence",l=(o==null?void 0:o.nodeClass)??(a?Tg:ID),u=new l(i.schema);u.flow=!0;const c=i.atRoot;c&&(i.atRoot=!1),i.atKey&&(i.atKey=!1);let d=n.offset+n.start.source.length;for(let y=0;y<n.items.length;++y){const m=n.items[y],{start:b,key:S,sep:_,value:C}=m,P=oI(b,{flow:s,indicator:"explicit-key-ind",next:S??(_==null?void 0:_[0]),offset:d,onError:r,parentIndent:n.indent,startOnNewline:!1});if(!P.found){if(!P.anchor&&!P.tag&&!_&&!C){y===0&&P.comma?r(P.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${s}`):y<n.items.length-1&&r(P.start,"UNEXPECTED_TOKEN",`Unexpected empty item in ${s}`),P.comment&&(u.comment?u.comment+=`
`+P.comment:u.comment=P.comment),d=P.end;continue}!a&&i.options.strict&&tV(S)&&r(S,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line")}if(y===0)P.comma&&r(P.comma,"UNEXPECTED_TOKEN",`Unexpected , in ${s}`);else if(P.comma||r(P.start,"MISSING_CHAR",`Missing , between ${s} items`),P.comment){let x="";e:for(const E of b)switch(E.type){case"comma":case"space":break;case"comment":x=E.source.substring(1);break e;default:break e}if(x){let E=u.items[u.items.length-1];nu(E)&&(E=E.value??E.key),E.comment?E.comment+=`
`+x:E.comment=x,P.comment=P.comment.substring(x.length+1)}}if(!a&&!_&&!P.found){const x=C?t(i,C,P,r):e(i,P.end,_,null,P,r);u.items.push(x),d=x.range[2],G7(C)&&r(x.range,"BLOCK_IN_FLOW",W7)}else{i.atKey=!0;const x=P.end,E=S?t(i,S,P,r):e(i,x,b,null,P,r);G7(S)&&r(E.range,"BLOCK_IN_FLOW",W7),i.atKey=!1;const A=oI(_??[],{flow:s,indicator:"map-value-ind",next:C,offset:E.range[2],onError:r,parentIndent:n.indent,startOnNewline:!1});if(A.found){if(!a&&!P.found&&i.options.strict){if(_)for(const D of _){if(D===A.found)break;if(D.type==="newline"){r(D,"MULTILINE_IMPLICIT_KEY","Implicit keys of flow sequence pairs need to be on a single line");break}}P.start<A.found.offset-1024&&r(A.found,"KEY_OVER_1024_CHARS","The : indicator must be at most 1024 chars after the start of an implicit flow sequence key")}}else C&&("source"in C&&((v=C.source)==null?void 0:v[0])===":"?r(C,"MISSING_CHAR",`Missing space after : in ${s}`):r(A.start,"MISSING_CHAR",`Missing , or : between ${s} items`));const R=C?t(i,C,A,r):A.found?e(i,A.end,_,null,A,r):null;R?G7(C)&&r(R.range,"BLOCK_IN_FLOW",W7):A.comment&&(E.comment?E.comment+=`
`+A.comment:E.comment=A.comment);const M=new Hf(E,R);if(i.options.keepSourceTokens&&(M.srcToken=m),a){const D=u;ZHe(i,D.items,E)&&r(x,"DUPLICATE_KEY","Map keys must be unique"),D.items.push(M)}else{const D=new Tg(i.schema);D.flow=!0,D.items.push(M);const F=(R??E).range;D.range=[E.range[0],F[1],F[2]],u.items.push(D)}d=R?R.range[2]:A.end}}const f=a?"}":"]",[h,...p]=n.end;let g=d;if((h==null?void 0:h.source)===f)g=h.offset+h.source.length;else{const y=s[0].toUpperCase()+s.substring(1),m=c?`${y} must end with a ${f}`:`${y} in block collection must be sufficiently indented and end with a ${f}`;r(d,c?"MISSING_CHAR":"BAD_INDENT",m),h&&h.source.length!==1&&p.unshift(h)}if(p.length>0){const y=uH(p,g,i.options.strict,r);y.comment&&(u.comment?u.comment+=`
`+y.comment:u.comment=y.comment),u.range=[n.offset,g,y.offset]}else u.range=[n.offset,g,g];return u}function Y7(t,e,i,n,r,o){const a=i.type==="block-map"?skt(t,e,i,n,o):i.type==="block-seq"?lkt(t,e,i,n,o):ukt(t,e,i,n,o),s=a.constructor;return r==="!"||r===s.tagName?(a.tag=s.tagName,a):(r&&(a.tag=r),a)}function ckt(t,e,i,n,r){var f;const o=n.tag,a=o?e.directives.tagName(o.source,h=>r(o,"TAG_RESOLVE_FAILED",h)):null;if(i.type==="block-seq"){const{anchor:h,newlineAfterProp:p}=n,g=h&&o?h.offset>o.offset?h:o:h??o;g&&(!p||p.offset<g.offset)&&r(g,"MISSING_CHAR","Missing newline after block sequence props")}const s=i.type==="block-map"?"map":i.type==="block-seq"?"seq":i.start.source==="{"?"map":"seq";if(!o||!a||a==="!"||a===Tg.tagName&&s==="map"||a===ID.tagName&&s==="seq")return Y7(t,e,i,r,a);let l=e.schema.tags.find(h=>h.tag===a&&h.collection===s);if(!l){const h=e.schema.knownTags[a];if((h==null?void 0:h.collection)===s)e.schema.tags.push(Object.assign({},h,{default:!1})),l=h;else return h?r(o,"BAD_COLLECTION_TYPE",`${h.tag} used for ${s} collection, but expects ${h.collection??"scalar"}`,!0):r(o,"TAG_RESOLVE_FAILED",`Unresolved tag: ${a}`,!0),Y7(t,e,i,r,a)}const u=Y7(t,e,i,r,a,l),c=((f=l.resolve)==null?void 0:f.call(l,u,h=>r(o,"TAG_RESOLVE_FAILED",h),e.options))??u,d=ru(c)?c:new Fn(c);return d.range=u.range,d.tag=a,l!=null&&l.format&&(d.format=l.format),d}function dkt(t,e,i){const n=e.offset,r=fkt(e,t.options.strict,i);if(!r)return{value:"",type:null,comment:"",range:[n,n,n]};const o=r.mode===">"?Fn.BLOCK_FOLDED:Fn.BLOCK_LITERAL,a=e.source?hkt(e.source):[];let s=a.length;for(let g=a.length-1;g>=0;--g){const v=a[g][1];if(v===""||v==="\r")s=g;else break}if(s===0){const g=r.chomp==="+"&&a.length>0?`
`.repeat(Math.max(1,a.length-1)):"";let v=n+r.length;return e.source&&(v+=e.source.length),{value:g,type:o,comment:r.comment,range:[n,v,v]}}let l=e.indent+r.indent,u=e.offset+r.length,c=0;for(let g=0;g<s;++g){const[v,y]=a[g];if(y===""||y==="\r")r.indent===0&&v.length>l&&(l=v.length);else{v.length<l&&i(u+v.length,"MISSING_CHAR","Block scalars with more-indented leading empty lines must use an explicit indentation indicator"),r.indent===0&&(l=v.length),c=g,l===0&&!t.atRoot&&i(u,"BAD_INDENT","Block scalar values in collections must be indented");break}u+=v.length+y.length+1}for(let g=a.length-1;g>=s;--g)a[g][0].length>l&&(s=g+1);let d="",f="",h=!1;for(let g=0;g<c;++g)d+=a[g][0].slice(l)+`
`;for(let g=c;g<s;++g){let[v,y]=a[g];u+=v.length+y.length+1;const m=y[y.length-1]==="\r";if(m&&(y=y.slice(0,-1)),y&&v.length<l){const S=`Block scalar lines must not be less indented than their ${r.indent?"explicit indentation indicator":"first line"}`;i(u-y.length-(m?2:1),"BAD_INDENT",S),v=""}o===Fn.BLOCK_LITERAL?(d+=f+v.slice(l)+y,f=`
`):v.length>l||y[0]==="	"?(f===" "?f=`
`:!h&&f===`
`&&(f=`

`),d+=f+v.slice(l)+y,f=`
`,h=!0):y===""?f===`
`?d+=`
`:f=`
`:(d+=f+y,f=" ",h=!1)}switch(r.chomp){case"-":break;case"+":for(let g=s;g<a.length;++g)d+=`
`+a[g][0].slice(l);d[d.length-1]!==`
`&&(d+=`
`);break;default:d+=`
`}const p=n+r.length+e.source.length;return{value:d,type:o,comment:r.comment,range:[n,p,p]}}function fkt({offset:t,props:e},i,n){if(e[0].type!=="block-scalar-header")return n(e[0],"IMPOSSIBLE","Block scalar header not found"),null;const{source:r}=e[0],o=r[0];let a=0,s="",l=-1;for(let f=1;f<r.length;++f){const h=r[f];if(!s&&(h==="-"||h==="+"))s=h;else{const p=Number(h);!a&&p?a=p:l===-1&&(l=t+f)}}l!==-1&&n(l,"UNEXPECTED_TOKEN",`Block scalar header includes extra characters: ${r}`);let u=!1,c="",d=r.length;for(let f=1;f<e.length;++f){const h=e[f];switch(h.type){case"space":u=!0;case"newline":d+=h.source.length;break;case"comment":i&&!u&&n(h,"MISSING_CHAR","Comments must be separated from other tokens by white space characters"),d+=h.source.length,c=h.source.substring(1);break;case"error":n(h,"UNEXPECTED_TOKEN",h.message),d+=h.source.length;break;default:{const p=`Unexpected token in block scalar header: ${h.type}`;n(h,"UNEXPECTED_TOKEN",p);const g=h.source;g&&typeof g=="string"&&(d+=g.length)}}}return{mode:o,indent:a,chomp:s,comment:c,length:d}}function hkt(t){const e=t.split(/\n( *)/),i=e[0],n=i.match(/^( *)/),o=[n!=null&&n[1]?[n[1],i.slice(n[1].length)]:["",i]];for(let a=1;a<e.length;a+=2)o.push([e[a],e[a+1]]);return o}function pkt(t,e,i){const{offset:n,type:r,source:o,end:a}=t;let s,l;const u=(f,h,p)=>i(n+f,h,p);switch(r){case"scalar":s=Fn.PLAIN,l=gkt(o,u);break;case"single-quoted-scalar":s=Fn.QUOTE_SINGLE,l=vkt(o,u);break;case"double-quoted-scalar":s=Fn.QUOTE_DOUBLE,l=ykt(o,u);break;default:return i(t,"UNEXPECTED_TOKEN",`Expected a flow scalar value, but found: ${r}`),{value:"",type:null,comment:"",range:[n,n+o.length,n+o.length]}}const c=n+o.length,d=uH(a,c,e,i);return{value:l,type:s,comment:d.comment,range:[n,c,d.offset]}}function gkt(t,e){let i="";switch(t[0]){case"	":i="a tab character";break;case",":i="flow indicator character ,";break;case"%":i="directive indicator character %";break;case"|":case">":{i=`block scalar indicator ${t[0]}`;break}case"@":case"`":{i=`reserved character ${t[0]}`;break}}return i&&e(0,"BAD_SCALAR_START",`Plain value cannot start with ${i}`),JHe(t)}function vkt(t,e){return(t[t.length-1]!=="'"||t.length===1)&&e(t.length,"MISSING_CHAR","Missing closing 'quote"),JHe(t.slice(1,-1)).replace(/''/g,"'")}function JHe(t){let e,i;try{e=new RegExp(`(.*?)(?<![ 	])[ 	]*\r?
`,"sy"),i=new RegExp(`[ 	]*(.*?)(?:(?<![ 	])[ 	]*)?\r?
`,"sy")}catch{e=/(.*?)[ \t]*\r?\n/sy,i=/[ \t]*(.*?)[ \t]*\r?\n/sy}let n=e.exec(t);if(!n)return t;let r=n[1],o=" ",a=e.lastIndex;for(i.lastIndex=a;n=i.exec(t);)n[1]===""?o===`
`?r+=o:o=`
`:(r+=o+n[1],o=" "),a=i.lastIndex;const s=/[ \t]*(.*)/sy;return s.lastIndex=a,n=s.exec(t),r+o+((n==null?void 0:n[1])??"")}function ykt(t,e){let i="";for(let n=1;n<t.length-1;++n){const r=t[n];if(!(r==="\r"&&t[n+1]===`
`))if(r===`
`){const{fold:o,offset:a}=mkt(t,n);i+=o,n=a}else if(r==="\\"){let o=t[++n];const a=bkt[o];if(a)i+=a;else if(o===`
`)for(o=t[n+1];o===" "||o==="	";)o=t[++n+1];else if(o==="\r"&&t[n+1]===`
`)for(o=t[++n+1];o===" "||o==="	";)o=t[++n+1];else if(o==="x"||o==="u"||o==="U"){const s={x:2,u:4,U:8}[o];i+=Skt(t,n+1,s,e),n+=s}else{const s=t.substr(n-1,2);e(n-1,"BAD_DQ_ESCAPE",`Invalid escape sequence ${s}`),i+=s}}else if(r===" "||r==="	"){const o=n;let a=t[n+1];for(;a===" "||a==="	";)a=t[++n+1];a!==`
`&&!(a==="\r"&&t[n+2]===`
`)&&(i+=n>o?t.slice(o,n+1):r)}else i+=r}return(t[t.length-1]!=='"'||t.length===1)&&e(t.length,"MISSING_CHAR",'Missing closing "quote'),i}function mkt(t,e){let i="",n=t[e+1];for(;(n===" "||n==="	"||n===`
`||n==="\r")&&!(n==="\r"&&t[e+2]!==`
`);)n===`
`&&(i+=`
`),e+=1,n=t[e+1];return i||(i=" "),{fold:i,offset:e}}const bkt={0:"\0",a:"\x07",b:"\b",e:"\x1B",f:"\f",n:`
`,r:"\r",t:"	",v:"\v",N:"",_:" ",L:"\u2028",P:"\u2029"," ":" ",'"':'"',"/":"/","\\":"\\","	":"	"};function Skt(t,e,i,n){const r=t.substr(e,i),a=r.length===i&&/^[0-9a-fA-F]+$/.test(r)?parseInt(r,16):NaN;if(isNaN(a)){const s=t.substr(e-2,i+2);return n(e-2,"BAD_DQ_ESCAPE",`Invalid escape sequence ${s}`),s}return String.fromCodePoint(a)}function QHe(t,e,i,n){const{value:r,type:o,comment:a,range:s}=e.type==="block-scalar"?dkt(t,e,n):pkt(e,t.options.strict,n),l=i?t.directives.tagName(i.source,d=>n(i,"TAG_RESOLVE_FAILED",d)):null;let u;t.options.stringKeys&&t.atKey?u=t.schema[bm]:l?u=_kt(t.schema,r,l,i,n):e.type==="scalar"?u=Pkt(t,r,e,n):u=t.schema[bm];let c;try{const d=u.resolve(r,f=>n(i??e,"TAG_RESOLVE_FAILED",f),t.options);c=gs(d)?d:new Fn(d)}catch(d){const f=d instanceof Error?d.message:String(d);n(i??e,"TAG_RESOLVE_FAILED",f),c=new Fn(r)}return c.range=s,c.source=r,o&&(c.type=o),l&&(c.tag=l),u.format&&(c.format=u.format),a&&(c.comment=a),c}function _kt(t,e,i,n,r){var s;if(i==="!")return t[bm];const o=[];for(const l of t.tags)if(!l.collection&&l.tag===i)if(l.default&&l.test)o.push(l);else return l;for(const l of o)if((s=l.test)!=null&&s.test(e))return l;const a=t.knownTags[i];return a&&!a.collection?(t.tags.push(Object.assign({},a,{default:!1,test:void 0})),a):(r(n,"TAG_RESOLVE_FAILED",`Unresolved tag: ${i}`,i!=="tag:yaml.org,2002:str"),t[bm])}function Pkt({atKey:t,directives:e,schema:i},n,r,o){const a=i.tags.find(s=>{var l;return(s.default===!0||t&&s.default==="key")&&((l=s.test)==null?void 0:l.test(n))})||i[bm];if(i.compat){const s=i.compat.find(l=>{var u;return l.default&&((u=l.test)==null?void 0:u.test(n))})??i[bm];if(a.tag!==s.tag){const l=e.tagString(a.tag),u=e.tagString(s.tag),c=`Value may be parsed as either ${l} or ${u}`;o(r,"TAG_RESOLVE_FAILED",c,!0)}}return a}function Ckt(t,e,i){if(e){i??(i=e.length);for(let n=i-1;n>=0;--n){let r=e[n];switch(r.type){case"space":case"comment":case"newline":t-=r.source.length;continue}for(r=e[++n];(r==null?void 0:r.type)==="space";)t+=r.source.length,r=e[++n];break}}return t}const Tkt={composeNode:e4e,composeEmptyNode:Lne};function e4e(t,e,i,n){const r=t.atKey,{spaceBefore:o,comment:a,anchor:s,tag:l}=i;let u,c=!0;switch(e.type){case"alias":u=xkt(t,e,n),(s||l)&&n(e,"ALIAS_PROPS","An alias node must not specify any properties");break;case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"block-scalar":u=QHe(t,e,l,n),s&&(u.anchor=s.source.substring(1));break;case"block-map":case"block-seq":case"flow-collection":u=ckt(Tkt,t,e,i,n),s&&(u.anchor=s.source.substring(1));break;default:{const d=e.type==="error"?e.message:`Unsupported token (type: ${e.type})`;n(e,"UNEXPECTED_TOKEN",d),u=Lne(t,e.offset,void 0,null,i,n),c=!1}}return s&&u.anchor===""&&n(s,"BAD_ALIAS","Anchor cannot be an empty string"),r&&t.options.stringKeys&&(!gs(u)||typeof u.value!="string"||u.tag&&u.tag!=="tag:yaml.org,2002:str")&&n(l??e,"NON_STRING_KEY","With stringKeys, all keys must be strings"),o&&(u.spaceBefore=!0),a&&(e.type==="scalar"&&e.source===""?u.comment=a:u.commentBefore=a),t.options.keepSourceTokens&&c&&(u.srcToken=e),u}function Lne(t,e,i,n,{spaceBefore:r,comment:o,anchor:a,tag:s,end:l},u){const c={type:"scalar",offset:Ckt(e,i,n),indent:-1,source:""},d=QHe(t,c,s,u);return a&&(d.anchor=a.source.substring(1),d.anchor===""&&u(a,"BAD_ALIAS","Anchor cannot be an empty string")),r&&(d.spaceBefore=!0),o&&(d.comment=o,d.range[2]=l),d}function xkt({options:t},{offset:e,source:i,end:n},r){const o=new _ne(i.substring(1));o.source===""&&r(e,"BAD_ALIAS","Alias cannot be an empty string"),o.source.endsWith(":")&&r(e+i.length-1,"BAD_ALIAS","Alias ending in : is ambiguous",!0);const a=e+i.length,s=uH(n,a,t.strict,r);return o.range=[e,a,s.offset],s.comment&&(o.comment=s.comment),o}function Ekt(t,e,{offset:i,start:n,value:r,end:o},a){const s=Object.assign({_directives:e},t),l=new qHe(void 0,s),u={atKey:!1,atRoot:!0,directives:l.directives,options:l.options,schema:l.schema},c=oI(n,{indicator:"doc-start",next:r??(o==null?void 0:o[0]),offset:i,onError:a,parentIndent:0,startOnNewline:!0});c.found&&(l.directives.docStart=!0,r&&(r.type==="block-map"||r.type==="block-seq")&&!c.hasNewline&&a(c.end,"MISSING_CHAR","Block collection cannot start on same line with directives-end marker")),l.contents=r?e4e(u,r,c,a):Lne(u,c.end,n,null,c,a);const d=l.contents.range[2],f=uH(o,d,!1,a);return f.comment&&(l.comment=f.comment),l.range=[i,d,f.offset],l}function ej(t){if(typeof t=="number")return[t,t+1];if(Array.isArray(t))return t.length===2?t:[t[0],t[1]];const{offset:e,source:i}=t;return[e,e+(typeof i=="string"?i.length:1)]}function Ixe(t){var r;let e="",i=!1,n=!1;for(let o=0;o<t.length;++o){const a=t[o];switch(a[0]){case"#":e+=(e===""?"":n?`

`:`
`)+(a.substring(1)||" "),i=!0,n=!1;break;case"%":((r=t[o+1])==null?void 0:r[0])!=="#"&&(o+=1),i=!1;break;default:i||(n=!0),i=!1}}return{comment:e,afterEmptyLine:n}}class wkt{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(i,n,r,o)=>{const a=ej(i);o?this.warnings.push(new akt(a,n,r)):this.errors.push(new pj(a,n,r))},this.directives=new Af({version:e.version||"1.2"}),this.options=e}decorate(e,i){const{comment:n,afterEmptyLine:r}=Ixe(this.prelude);if(n){const o=e.contents;if(i)e.comment=e.comment?`${e.comment}
${n}`:n;else if(r||e.directives.docStart||!o)e.commentBefore=n;else if(eu(o)&&!o.flow&&o.items.length>0){let a=o.items[0];nu(a)&&(a=a.key);const s=a.commentBefore;a.commentBefore=s?`${n}
${s}`:n}else{const a=o.commentBefore;o.commentBefore=a?`${n}
${a}`:n}}i?(Array.prototype.push.apply(e.errors,this.errors),Array.prototype.push.apply(e.warnings,this.warnings)):(e.errors=this.errors,e.warnings=this.warnings),this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Ixe(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,i=!1,n=-1){for(const r of e)yield*this.next(r);yield*this.end(i,n)}*next(e){switch(e.type){case"directive":this.directives.add(e.source,(i,n,r)=>{const o=ej(e);o[0]+=i,this.onError(o,"BAD_DIRECTIVE",n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case"document":{const i=Ekt(this.options,this.directives,e,this.onError);this.atDirectives&&!i.directives.docStart&&this.onError(e,"MISSING_CHAR","Missing directives-end/doc-start indicator line"),this.decorate(i,!1),this.doc&&(yield this.doc),this.doc=i,this.atDirectives=!1;break}case"byte-order-mark":case"space":break;case"comment":case"newline":this.prelude.push(e.source);break;case"error":{const i=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new pj(ej(e),"UNEXPECTED_TOKEN",i);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case"doc-end":{if(!this.doc){const n="Unexpected doc-end without preceding document";this.errors.push(new pj(ej(e),"UNEXPECTED_TOKEN",n));break}this.doc.directives.docEnd=!0;const i=uH(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),i.comment){const n=this.doc.comment;this.doc.comment=n?`${n}
${i.comment}`:i.comment}this.doc.range[2]=i.offset;break}default:this.errors.push(new pj(ej(e),"UNEXPECTED_TOKEN",`Unsupported token ${e.type}`))}}*end(e=!1,i=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){const n=Object.assign({_directives:this.directives},this.options),r=new qHe(void 0,n);this.atDirectives&&this.onError(i,"MISSING_CHAR","Missing directives-end indicator line"),r.range=[0,i,i],this.decorate(r,!1),yield r}}}const t4e="\uFEFF",r4e="",i4e="",wJ="";function Akt(t){switch(t){case t4e:return"byte-order-mark";case r4e:return"doc-mode";case i4e:return"flow-error-end";case wJ:return"scalar";case"---":return"doc-start";case"...":return"doc-end";case"":case`
`:case`\r
`:return"newline";case"-":return"seq-item-ind";case"?":return"explicit-key-ind";case":":return"map-value-ind";case"{":return"flow-map-start";case"}":return"flow-map-end";case"[":return"flow-seq-start";case"]":return"flow-seq-end";case",":return"comma"}switch(t[0]){case" ":case"	":return"space";case"#":return"comment";case"%":return"directive-line";case"*":return"alias";case"&":return"anchor";case"!":return"tag";case"'":return"single-quoted-scalar";case'"':return"double-quoted-scalar";case"|":case">":return"block-scalar-header"}return null}function cv(t){switch(t){case void 0:case" ":case`
`:case"\r":case"	":return!0;default:return!1}}const Nxe=new Set("0123456789ABCDEFabcdef"),Okt=new Set("0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()"),SU=new Set(",[]{}"),Dkt=new Set(` ,[]{}
\r	`),q7=t=>!t||Dkt.has(t);class Rkt{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer="",this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,i=!1){if(e){if(typeof e!="string")throw TypeError("source is not a string");this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!i;let n=this.next??"stream";for(;n&&(i||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,i=this.buffer[e];for(;i===" "||i==="	";)i=this.buffer[++e];return!i||i==="#"||i===`
`?!0:i==="\r"?this.buffer[e+1]===`
`:!1}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let i=this.buffer[e];if(this.indentNext>0){let n=0;for(;i===" ";)i=this.buffer[++n+e];if(i==="\r"){const r=this.buffer[n+e+1];if(r===`
`||!r&&!this.atEnd)return e+n+1}return i===`
`||n>=this.indentNext||!i&&!this.atEnd?e+n:-1}if(i==="-"||i==="."){const n=this.buffer.substr(e,3);if((n==="---"||n==="...")&&cv(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!="number"||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(`
`,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]==="\r"&&(e-=1),this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case"stream":return yield*this.parseStream();case"line-start":return yield*this.parseLineStart();case"block-start":return yield*this.parseBlockStart();case"doc":return yield*this.parseDocument();case"flow":return yield*this.parseFlowCollection();case"quoted-scalar":return yield*this.parseQuotedScalar();case"block-scalar":return yield*this.parseBlockScalar();case"plain-scalar":return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext("stream");if(e[0]===t4e&&(yield*this.pushCount(1),e=e.substring(1)),e[0]==="%"){let i=e.length,n=e.indexOf("#");for(;n!==-1;){const o=e[n-1];if(o===" "||o==="	"){i=n-1;break}else n=e.indexOf("#",n+1)}for(;;){const o=e[i-1];if(o===" "||o==="	")i-=1;else break}const r=(yield*this.pushCount(i))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-r),this.pushNewline(),"stream"}if(this.atLineEnd()){const i=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-i),yield*this.pushNewline(),"stream"}return yield r4e,yield*this.parseLineStart()}*parseLineStart(){const e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext("line-start");if(e==="-"||e==="."){if(!this.atEnd&&!this.hasChars(4))return this.setNext("line-start");const i=this.peek(3);if((i==="---"||i==="...")&&cv(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,i==="---"?"doc":"stream"}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!cv(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){const[e,i]=this.peek(2);if(!i&&!this.atEnd)return this.setNext("block-start");if((e==="-"||e==="?"||e===":")&&cv(i)){const n=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=n,yield*this.parseBlockStart()}return"doc"}*parseDocument(){yield*this.pushSpaces(!0);const e=this.getLine();if(e===null)return this.setNext("doc");let i=yield*this.pushIndicators();switch(e[i]){case"#":yield*this.pushCount(e.length-i);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,"flow";case"}":case"]":return yield*this.pushCount(1),"doc";case"*":return yield*this.pushUntil(q7),"doc";case'"':case"'":return yield*this.parseQuotedScalar();case"|":case">":return i+=yield*this.parseBlockScalarHeader(),i+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-i),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,i,n=-1;do e=yield*this.pushNewline(),e>0?(i=yield*this.pushSpaces(!1),this.indentValue=n=i):i=0,i+=yield*this.pushSpaces(!0);while(e+i>0);const r=this.getLine();if(r===null)return this.setNext("flow");if((n!==-1&&n<this.indentNext&&r[0]!=="#"||n===0&&(r.startsWith("---")||r.startsWith("..."))&&cv(r[3]))&&!(n===this.indentNext-1&&this.flowLevel===1&&(r[0]==="]"||r[0]==="}")))return this.flowLevel=0,yield i4e,yield*this.parseLineStart();let o=0;for(;r[o]===",";)o+=yield*this.pushCount(1),o+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(o+=yield*this.pushIndicators(),r[o]){case void 0:return"flow";case"#":return yield*this.pushCount(r.length-o),"flow";case"{":case"[":return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,"flow";case"}":case"]":return yield*this.pushCount(1),this.flowKey=!0,this.flowLevel-=1,this.flowLevel?"flow":"doc";case"*":return yield*this.pushUntil(q7),"flow";case'"':case"'":return this.flowKey=!0,yield*this.parseQuotedScalar();case":":{const a=this.charAt(1);if(this.flowKey||cv(a)||a===",")return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),"flow"}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){const e=this.charAt(0);let i=this.buffer.indexOf(e,this.pos+1);if(e==="'")for(;i!==-1&&this.buffer[i+1]==="'";)i=this.buffer.indexOf("'",i+2);else for(;i!==-1;){let o=0;for(;this.buffer[i-1-o]==="\\";)o+=1;if(o%2===0)break;i=this.buffer.indexOf('"',i+1)}const n=this.buffer.substring(0,i);let r=n.indexOf(`
`,this.pos);if(r!==-1){for(;r!==-1;){const o=this.continueScalar(r+1);if(o===-1)break;r=n.indexOf(`
`,o)}r!==-1&&(i=r-(n[r-1]==="\r"?2:1))}if(i===-1){if(!this.atEnd)return this.setNext("quoted-scalar");i=this.buffer.length}return yield*this.pushToIndex(i+1,!1),this.flowLevel?"flow":"doc"}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){const i=this.buffer[++e];if(i==="+")this.blockScalarKeep=!0;else if(i>"0"&&i<="9")this.blockScalarIndent=Number(i)-1;else if(i!=="-")break}return yield*this.pushUntil(i=>cv(i)||i==="#")}*parseBlockScalar(){let e=this.pos-1,i=0,n;e:for(let o=this.pos;n=this.buffer[o];++o)switch(n){case" ":i+=1;break;case`
`:e=o,i=0;break;case"\r":{const a=this.buffer[o+1];if(!a&&!this.atEnd)return this.setNext("block-scalar");if(a===`
`)break}default:break e}if(!n&&!this.atEnd)return this.setNext("block-scalar");if(i>=this.indentNext){this.blockScalarIndent===-1?this.indentNext=i:this.indentNext=this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{const o=this.continueScalar(e+1);if(o===-1)break;e=this.buffer.indexOf(`
`,o)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext("block-scalar");e=this.buffer.length}}let r=e+1;for(n=this.buffer[r];n===" ";)n=this.buffer[++r];if(n==="	"){for(;n==="	"||n===" "||n==="\r"||n===`
`;)n=this.buffer[++r];e=r-1}else if(!this.blockScalarKeep)do{let o=e-1,a=this.buffer[o];a==="\r"&&(a=this.buffer[--o]);const s=o;for(;a===" ";)a=this.buffer[--o];if(a===`
`&&o>=this.pos&&o+1+i>s)e=o;else break}while(!0);return yield wJ,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){const e=this.flowLevel>0;let i=this.pos-1,n=this.pos-1,r;for(;r=this.buffer[++n];)if(r===":"){const o=this.buffer[n+1];if(cv(o)||e&&SU.has(o))break;i=n}else if(cv(r)){let o=this.buffer[n+1];if(r==="\r"&&(o===`
`?(n+=1,r=`
`,o=this.buffer[n+1]):i=n),o==="#"||e&&SU.has(o))break;if(r===`
`){const a=this.continueScalar(n+1);if(a===-1)break;n=Math.max(n,a-2)}}else{if(e&&SU.has(r))break;i=n}return!r&&!this.atEnd?this.setNext("plain-scalar"):(yield wJ,yield*this.pushToIndex(i+1,!0),e?"flow":"doc")}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,i){const n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(i&&(yield""),0)}*pushIndicators(){switch(this.charAt(0)){case"!":return(yield*this.pushTag())+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"&":return(yield*this.pushUntil(q7))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators());case"-":case"?":case":":{const e=this.flowLevel>0,i=this.charAt(1);if(cv(i)||e&&SU.has(i))return e?this.flowKey&&(this.flowKey=!1):this.indentNext=this.indentValue+1,(yield*this.pushCount(1))+(yield*this.pushSpaces(!0))+(yield*this.pushIndicators())}}return 0}*pushTag(){if(this.charAt(1)==="<"){let e=this.pos+2,i=this.buffer[e];for(;!cv(i)&&i!==">";)i=this.buffer[++e];return yield*this.pushToIndex(i===">"?e+1:e,!1)}else{let e=this.pos+1,i=this.buffer[e];for(;i;)if(Okt.has(i))i=this.buffer[++e];else if(i==="%"&&Nxe.has(this.buffer[e+1])&&Nxe.has(this.buffer[e+2]))i=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){const e=this.buffer[this.pos];return e===`
`?yield*this.pushCount(1):e==="\r"&&this.charAt(1)===`
`?yield*this.pushCount(2):0}*pushSpaces(e){let i=this.pos-1,n;do n=this.buffer[++i];while(n===" "||e&&n==="	");const r=i-this.pos;return r>0&&(yield this.buffer.substr(this.pos,r),this.pos=i),r}*pushUntil(e){let i=this.pos,n=this.buffer[i];for(;!e(n);)n=this.buffer[++i];return yield*this.pushToIndex(i,!1)}}class Mkt{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let i=0,n=this.lineStarts.length;for(;i<n;){const o=i+n>>1;this.lineStarts[o]<e?i=o+1:n=o}if(this.lineStarts[i]===e)return{line:i+1,col:1};if(i===0)return{line:0,col:e};const r=this.lineStarts[i-1];return{line:i,col:e-r+1}}}}function G_(t,e){for(let i=0;i<t.length;++i)if(t[i].type===e)return!0;return!1}function Fxe(t){for(let e=0;e<t.length;++e)switch(t[e].type){case"space":case"comment":case"newline":break;default:return e}return-1}function n4e(t){switch(t==null?void 0:t.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":case"flow-collection":return!0;default:return!1}}function _U(t){switch(t.type){case"document":return t.start;case"block-map":{const e=t.items[t.items.length-1];return e.sep??e.start}case"block-seq":return t.items[t.items.length-1].start;default:return[]}}function fL(t){var i;if(t.length===0)return[];let e=t.length;e:for(;--e>=0;)switch(t[e].type){case"doc-start":case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":case"newline":break e}for(;((i=t[++e])==null?void 0:i.type)==="space";);return t.splice(e,t.length)}function Bxe(t){if(t.start.type==="flow-seq-start")for(const e of t.items)e.sep&&!e.value&&!G_(e.start,"explicit-key-ind")&&!G_(e.sep,"map-value-ind")&&(e.key&&(e.value=e.key),delete e.key,n4e(e.value)?e.value.end?Array.prototype.push.apply(e.value.end,e.sep):e.value.end=e.sep:Array.prototype.push.apply(e.start,e.sep),delete e.sep)}class Lkt{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source="",this.type="",this.lexer=new Rkt,this.onNewLine=e}*parse(e,i=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(const n of this.lexer.lex(e,i))yield*this.next(n);i||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}const i=Akt(e);if(i)if(i==="scalar")this.atNewLine=!1,this.atScalar=!0,this.type="scalar";else{switch(this.type=i,yield*this.step(),i){case"newline":this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case"space":this.atNewLine&&e[0]===" "&&(this.indent+=e.length);break;case"explicit-key-ind":case"map-value-ind":case"seq-item-ind":this.atNewLine&&(this.indent+=e.length);break;case"doc-mode":case"flow-error-end":return;default:this.atNewLine=!1}this.offset+=e.length}else{const n=`Not a YAML token: ${e}`;yield*this.pop({type:"error",offset:this.offset,message:n,source:e}),this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){const e=this.peek(1);if(this.type==="doc-end"&&(e==null?void 0:e.type)!=="doc-end"){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:"doc-end",offset:this.offset,source:this.source});return}if(!e)return yield*this.stream();switch(e.type){case"document":return yield*this.document(e);case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return yield*this.scalar(e);case"block-scalar":return yield*this.blockScalar(e);case"block-map":return yield*this.blockMap(e);case"block-seq":return yield*this.blockSequence(e);case"flow-collection":return yield*this.flowCollection(e);case"doc-end":return yield*this.documentEnd(e)}yield*this.pop()}peek(e){return this.stack[this.stack.length-e]}*pop(e){const i=e??this.stack.pop();if(!i)yield{type:"error",offset:this.offset,source:"",message:"Tried to pop an empty stack"};else if(this.stack.length===0)yield i;else{const n=this.peek(1);switch(i.type==="block-scalar"?i.indent="indent"in n?n.indent:0:i.type==="flow-collection"&&n.type==="document"&&(i.indent=0),i.type==="flow-collection"&&Bxe(i),n.type){case"document":n.value=i;break;case"block-scalar":n.props.push(i);break;case"block-map":{const r=n.items[n.items.length-1];if(r.value){n.items.push({start:[],key:i,sep:[]}),this.onKeyLine=!0;return}else if(r.sep)r.value=i;else{Object.assign(r,{key:i,sep:[]}),this.onKeyLine=!r.explicitKey;return}break}case"block-seq":{const r=n.items[n.items.length-1];r.value?n.items.push({start:[],value:i}):r.value=i;break}case"flow-collection":{const r=n.items[n.items.length-1];!r||r.value?n.items.push({start:[],key:i,sep:[]}):r.sep?r.value=i:Object.assign(r,{key:i,sep:[]});return}default:yield*this.pop(),yield*this.pop(i)}if((n.type==="document"||n.type==="block-map"||n.type==="block-seq")&&(i.type==="block-map"||i.type==="block-seq")){const r=i.items[i.items.length-1];r&&!r.sep&&!r.value&&r.start.length>0&&Fxe(r.start)===-1&&(i.indent===0||r.start.every(o=>o.type!=="comment"||o.indent<i.indent))&&(n.type==="document"?n.end=r.start:n.items.push({start:r.start}),i.items.splice(-1,1))}}}*stream(){switch(this.type){case"directive-line":yield{type:"directive",offset:this.offset,source:this.source};return;case"byte-order-mark":case"space":case"comment":case"newline":yield this.sourceToken;return;case"doc-mode":case"doc-start":{const e={type:"document",offset:this.offset,start:[]};this.type==="doc-start"&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case"doc-start":{Fxe(e.start)!==-1?(yield*this.pop(),yield*this.step()):e.start.push(this.sourceToken);return}case"anchor":case"tag":case"space":case"comment":case"newline":e.start.push(this.sourceToken);return}const i=this.startBlockValue(e);i?this.stack.push(i):yield{type:"error",offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type==="map-value-ind"){const i=_U(this.peek(2)),n=fL(i);let r;e.end?(r=e.end,r.push(this.sourceToken),delete e.end):r=[this.sourceToken];const o={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=o}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case"space":case"comment":case"newline":e.props.push(this.sourceToken);return;case"scalar":if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let i=this.source.indexOf(`
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
`,i)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){var n;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(this.onKeyLine=!1,i.value){const r="end"in i.value?i.value.end:void 0,o=Array.isArray(r)?r[r.length-1]:void 0;(o==null?void 0:o.type)==="comment"?r==null||r.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else if(i.sep)i.sep.push(this.sourceToken);else{if(this.atIndentedComment(i.start,e.indent)){const r=e.items[e.items.length-2],o=(n=r==null?void 0:r.value)==null?void 0:n.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return}if(this.indent>=e.indent){const r=!this.onKeyLine&&this.indent===e.indent,o=r&&(i.sep||i.explicitKey)&&this.type!=="seq-item-ind";let a=[];if(o&&i.sep&&!i.value){const s=[];for(let l=0;l<i.sep.length;++l){const u=i.sep[l];switch(u.type){case"newline":s.push(l);break;case"space":break;case"comment":u.indent>e.indent&&(s.length=0);break;default:s.length=0}}s.length>=2&&(a=i.sep.splice(s[1]))}switch(this.type){case"anchor":case"tag":o||i.value?(a.push(this.sourceToken),e.items.push({start:a}),this.onKeyLine=!0):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"explicit-key-ind":!i.sep&&!i.explicitKey?(i.start.push(this.sourceToken),i.explicitKey=!0):o||i.value?(a.push(this.sourceToken),e.items.push({start:a,explicitKey:!0})):this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case"map-value-ind":if(i.explicitKey)if(i.sep)if(i.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(G_(i.sep,"map-value-ind"))this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:a,key:null,sep:[this.sourceToken]}]});else if(n4e(i.key)&&!G_(i.sep,"newline")){const s=fL(i.start),l=i.key,u=i.sep;u.push(this.sourceToken),delete i.key,delete i.sep,this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:l,sep:u}]})}else a.length>0?i.sep=i.sep.concat(a,this.sourceToken):i.sep.push(this.sourceToken);else if(G_(i.start,"newline"))Object.assign(i,{key:null,sep:[this.sourceToken]});else{const s=fL(i.start);this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:s,key:null,sep:[this.sourceToken]}]})}else i.sep?i.value||o?e.items.push({start:a,key:null,sep:[this.sourceToken]}):G_(i.sep,"map-value-ind")?this.stack.push({type:"block-map",offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const s=this.flowScalar(this.type);o||i.value?(e.items.push({start:a,key:s,sep:[]}),this.onKeyLine=!0):i.sep?this.stack.push(s):(Object.assign(i,{key:s,sep:[]}),this.onKeyLine=!0);return}default:{const s=this.startBlockValue(e);if(s){if(s.type==="block-seq"){if(!i.explicitKey&&i.sep&&!G_(i.sep,"newline")){yield*this.pop({type:"error",offset:this.offset,message:"Unexpected block-seq-ind on same line with key",source:this.source});return}}else r&&e.items.push({start:a});this.stack.push(s);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){var n;const i=e.items[e.items.length-1];switch(this.type){case"newline":if(i.value){const r="end"in i.value?i.value.end:void 0,o=Array.isArray(r)?r[r.length-1]:void 0;(o==null?void 0:o.type)==="comment"?r==null||r.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else i.start.push(this.sourceToken);return;case"space":case"comment":if(i.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(i.start,e.indent)){const r=e.items[e.items.length-2],o=(n=r==null?void 0:r.value)==null?void 0:n.end;if(Array.isArray(o)){Array.prototype.push.apply(o,i.start),o.push(this.sourceToken),e.items.pop();return}}i.start.push(this.sourceToken)}return;case"anchor":case"tag":if(i.value||this.indent<=e.indent)break;i.start.push(this.sourceToken);return;case"seq-item-ind":if(this.indent!==e.indent)break;i.value||G_(i.start,"seq-item-ind")?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return}if(this.indent>e.indent){const r=this.startBlockValue(e);if(r){this.stack.push(r);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){const i=e.items[e.items.length-1];if(this.type==="flow-error-end"){let n;do yield*this.pop(),n=this.peek(1);while((n==null?void 0:n.type)==="flow-collection")}else if(e.end.length===0){switch(this.type){case"comma":case"explicit-key-ind":!i||i.sep?e.items.push({start:[this.sourceToken]}):i.start.push(this.sourceToken);return;case"map-value-ind":!i||i.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):Object.assign(i,{key:null,sep:[this.sourceToken]});return;case"space":case"comment":case"newline":case"anchor":case"tag":!i||i.value?e.items.push({start:[this.sourceToken]}):i.sep?i.sep.push(this.sourceToken):i.start.push(this.sourceToken);return;case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":{const r=this.flowScalar(this.type);!i||i.value?e.items.push({start:[],key:r,sep:[]}):i.sep?this.stack.push(r):Object.assign(i,{key:r,sep:[]});return}case"flow-map-end":case"flow-seq-end":e.end.push(this.sourceToken);return}const n=this.startBlockValue(e);n?this.stack.push(n):(yield*this.pop(),yield*this.step())}else{const n=this.peek(2);if(n.type==="block-map"&&(this.type==="map-value-ind"&&n.indent===e.indent||this.type==="newline"&&!n.items[n.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type==="map-value-ind"&&n.type!=="flow-collection"){const r=_U(n),o=fL(r);Bxe(e);const a=e.end.splice(1,e.end.length);a.push(this.sourceToken);const s={type:"block-map",offset:e.offset,indent:e.indent,items:[{start:o,key:e,sep:a}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=s}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let i=this.source.indexOf(`
`)+1;for(;i!==0;)this.onNewLine(this.offset+i),i=this.source.indexOf(`
`,i)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case"alias":case"scalar":case"single-quoted-scalar":case"double-quoted-scalar":return this.flowScalar(this.type);case"block-scalar-header":return{type:"block-scalar",offset:this.offset,indent:this.indent,props:[this.sourceToken],source:""};case"flow-map-start":case"flow-seq-start":return{type:"flow-collection",offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case"seq-item-ind":return{type:"block-seq",offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case"explicit-key-ind":{this.onKeyLine=!0;const i=_U(e),n=fL(i);return n.push(this.sourceToken),{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,explicitKey:!0}]}}case"map-value-ind":{this.onKeyLine=!0;const i=_U(e),n=fL(i);return{type:"block-map",offset:this.offset,indent:this.indent,items:[{start:n,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,i){return this.type!=="comment"||this.indent<=i?!1:e.every(n=>n.type==="newline"||n.type==="space")}*documentEnd(e){this.type!=="doc-mode"&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case"comma":case"doc-start":case"doc-end":case"flow-seq-end":case"flow-map-end":case"map-value-ind":yield*this.pop(),yield*this.step();break;case"newline":this.onKeyLine=!1;case"space":case"comment":default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type==="newline"&&(yield*this.pop())}}}function kkt(t){const e=t.prettyErrors!==!1;return{lineCounter:t.lineCounter||e&&new Mkt||null,prettyErrors:e}}function Ikt(t,e={}){const{lineCounter:i,prettyErrors:n}=kkt(e),r=new Lkt(i==null?void 0:i.addNewLine),o=new wkt(e);let a=null;for(const s of o.compose(r.parse(t),!0,t.length))if(!a)a=s;else if(a.options.logLevel!=="silent"){a.errors.push(new pj(s.range.slice(0,2),"MULTIPLE_DOCS","Source contains multiple documents; please use YAML.parseAllDocuments()"));break}return n&&i&&(a.errors.forEach(Lxe(t,i)),a.warnings.forEach(Lxe(t,i))),a}function Nkt(t,e,i){let n;const r=Ikt(t,i);if(!r)return null;if(r.warnings.forEach(o=>OHe(r.options.logLevel,o)),r.errors.length>0){if(r.options.logLevel!=="silent")throw r.errors[0];r.errors=[]}return r.toJS(Object.assign({reviver:n},i))}function Fkt(t){const e=Nkt(t);if(e.schema&&e.schema.startsWith("remotive-topology-platform"))return o4e(e);if(e.schema&&e.schema.startsWith("remotive-topology-instance"))return Bkt(e);throw new Error(`Unknown schema: ${e.schema}`)}function o4e(t){var r,o;const e=new Map,i=new Map,n=t.channels||{};for(const[a,s]of Object.entries(n)){const l=(()=>{switch(s.type){case"flexray":return{entityType:"channel",name:a,type:"flexray",platform:s,ecus:[]};case"ethernet":return{entityType:"channel",name:a,type:"ethernet",platform:s,serviceInstances:[],endpoints:[],ecus:[]};case"can":return{entityType:"channel",name:a,type:"can",platform:s,ecus:[]};case"lin":return{entityType:"channel",name:a,type:"lin",platform:s,ecus:[]};default:{const u=s||{type:"?"};throw new Error(`Unknown channel type: ${u.type}`)}}})();i.set(a,l)}for(const a of i.values())if(a.type==="ethernet"){const s=new Map;for(const[u,c]of Object.entries(((r=a.platform.someip)==null?void 0:r.services)||{})){const d={entityType:"service_instance",name:u,channel:a,platform:c,providedBySocket:void 0,consumedBySockets:[]};s.set(u,d),a.serviceInstances.push(d)}const l=new Map;for(const[u,c]of Object.entries(a.platform.endpoints||{})){const d={entityType:"endpoint",name:u,channel:a,platform:c,sockets:[],providedByEcu:void 0};a.endpoints.push(d);for(const[f,h]of Object.entries(c.sockets||{})){const p={entityType:"socket",name:f,channel:a,endpoint:d,platform:h,providedServiceInstances:[],consumedServiceInstances:[],connections:[]};l.set(f,p),d.sockets.push(p);for(const g of h.provided_service_instances||[]){const v=s.get(g);v&&(v.providedBySocket=p,p.providedServiceInstances.push(v))}for(const g of h.consumed_service_instances||[]){const v=s.get(g);v&&(v.consumedBySockets.push(p),p.consumedServiceInstances.push(v))}}}for(const u of l.values())for(const c of u.platform.socket_connections||[]){const d=l.get(c);d&&u.connections.push(d)}}for(const[a,s]of Object.entries(t.ecus||{})){const l={entityType:"ecu",name:a,platform:s,channels:[]};e.set(a,l);for(const[u,c]of Object.entries(s.channels||{})){const d=i.get(u);if(!d){console.warn(`ECU ${a} references unknown channel ${u}`);continue}d.ecus.push(l);const f=(()=>{if(!c||!c.config)switch(d.type){case"ethernet":return{type:"ethernet",providedEndpoints:[]};case"can":return{type:"can"};case"lin":return{type:"lin"};case"flexray":return{type:"flexray"}}if(c.config.type==="ethernet"&&d.type==="ethernet")return{type:"ethernet",providedEndpoints:(c.config.provided_endpoints||[]).map(g=>{const v=d.endpoints.find(y=>y.name===g);if(!v)throw new Error(`ECU ${a} references unknown endpoint ${g} on channel ${u}`);return v.providedByEcu=l,v})};if(d.type==="can")return{type:"can"};if(d.type==="lin")return{type:"lin"};if(d.type==="flexray")return{type:"flexray"};throw new Error(`ECU ${a} channel ${u} has mismatched config type ${c.config.type}`)})(),h={entityType:"ecu_channel",name:u,platform:c||{},ecu:l,channel:d,config:f};l.channels.push(h)}}for(const a of i.values())if(a.type==="ethernet")for(const s of a.serviceInstances)s.providedByEcu=(o=s.providedBySocket)==null?void 0:o.endpoint.providedByEcu;return{ecus:e,channels:i,containers:new Map}}function Bkt(t){const e=o4e(t.platform||{});for(const[i,n]of Object.entries(t.channels||{})){const r=e.channels.get(i);if(!r)throw new Error(`Instance references unknown channel ${i}`);r.instance=n}for(const[i,n]of Object.entries(t.ecus||{})){const r=e.ecus.get(i);if(!r)throw new Error(`Instance references unknown ECU ${i}`);r.instance=n;for(const[o,a]of Object.entries(n.channels||{})){const s=r.channels.find(l=>l.name===o);if(!s)throw new Error(`ECU ${i} references unknown channel ${o}`);s.instance=a||{}}n.container&&(r.container={entityType:"container",name:i,instance:n.container,ecu:r}),n.models&&(r.models=Object.entries(n.models).map(([o,a])=>{const s=a.type==="container"&&a.container?{entityType:"container",name:o,instance:a.container,ecu:r}:void 0;return{entityType:"behavioral_model",name:o,instance:a,ecu:r,container:s}}))}for(const[i,n]of Object.entries(t.containers||{})){const r={entityType:"container",name:i,instance:n};e.containers.set(i,r)}return e}function ky(t){switch(t.entityType){case"ecu_channel":return`ecu_channel:${t.ecu.name}:${t.channel.name}`;case"endpoint":return`endpoint:${t.channel.name}:${t.name}`;case"socket":return`socket:${t.channel.name}:${t.name}`;case"service_instance":return`service_instance:${t.channel.name}:${t.name}`}return`${t.entityType}:${t.name}`}function kne(t){return`${t.platform.type||"???"}://${t.endpoint.platform.host||"???"}:${t.platform.port||"???"}`}function a4e(t){const e=t.models?Object.keys(t.models):[];return t.container!==void 0?"Container":e.length>0?"Behavioral Model":t.mock!==void 0?"Mock":"RemotiveBroker"}function Ty(t,e){if(!(!e||e.length===0))return{name:ELt[t],parent:null,children:e,childType:t,path:`/${t}s`,type:"folder"}}function jxe(t){const e=t.instance.build&&[...t.instance.build.args||[],t.instance.build.context,t.instance.build.dockerfile,t.instance.build.target]||[];return[...t.instance.profiles||[],t.instance.platform,t.instance.image,...t.instance.volumes||[],...t.instance.ports||[],...t.instance.environment||[],t.instance.working_dir,...t.instance.depends_on||[],t.instance.command,...t.instance.cap_add||[],...t.instance.devices||[],t.instance.control_network,...t.instance.extra_hosts||[],...e].filter(i=>i!==void 0).join(" ")}function jkt(t){var e,i,n,r,o,a,s,l;switch(t.entityType){case"ecu":{const u=t.channels.flatMap(c=>c.config.type==="ethernet"?c.config.providedEndpoints:[]);return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:t.name.toLowerCase(),channel:t.channels.map(c=>c.channel.name.toLowerCase()).join(" "),endpoint:u.map(c=>c.name.toLowerCase()).join(" "),socket:u.flatMap(c=>c.sockets.map(d=>d.name.toLowerCase())).join(" "),service_instance:u.flatMap(c=>c.sockets.map(d=>d.providedServiceInstances.map(f=>f.name.toLowerCase()).join(" "))).join(" "),extra:""}}case"channel":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:t.ecus.map(u=>u.name.toLowerCase()).join(" "),channel:t.name.toLowerCase(),endpoint:t.type==="ethernet"?t.endpoints.map(u=>u.name.toLowerCase()).join(" "):"",socket:t.type==="ethernet"?t.endpoints.flatMap(u=>u.sockets.map(c=>c.name.toLowerCase())).join(" "):"",service_instance:t.type==="ethernet"?t.serviceInstances.map(u=>u.name.toLowerCase()).join(" "):"",extra:""};case"container":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:t.ecu?t.ecu.name.toLowerCase():"",channel:"",endpoint:"",socket:"",service_instance:"",extra:jxe(t)};case"behavioral_model":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:t.ecu.name.toLowerCase(),channel:"",endpoint:"",socket:"",service_instance:"",extra:t.container?jxe(t.container):""};case"endpoint":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:t.providedByEcu?t.providedByEcu.name.toLowerCase():"",channel:t.channel.name.toLowerCase(),endpoint:t.name.toLowerCase(),socket:t.sockets.map(u=>u.name.toLowerCase()).join(" "),service_instance:t.sockets.flatMap(u=>u.providedServiceInstances.map(c=>c.name.toLowerCase())).join(" "),extra:t.platform.host??""};case"socket":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:((e=t.endpoint.providedByEcu)==null?void 0:e.name.toLowerCase())??"",channel:t.channel.name.toLowerCase(),endpoint:t.endpoint.name.toLowerCase(),socket:t.name.toLowerCase(),service_instance:t.providedServiceInstances.map(u=>u.name.toLowerCase()).join(" "),extra:((i=t.platform.port)==null?void 0:i.toString())??""};case"service_instance":return{_id:ky(t),name:t.name,entityType:t.entityType,ecu:((r=(n=t.providedBySocket)==null?void 0:n.endpoint.providedByEcu)==null?void 0:r.name.toLowerCase())||"",channel:t.channel.name.toLowerCase(),endpoint:((o=t.providedBySocket)==null?void 0:o.endpoint.name.toLowerCase())||"",socket:((a=t.providedBySocket)==null?void 0:a.name.toLowerCase())||"",service_instance:t.name.toLowerCase(),extra:[(s=t.platform.service_id)==null?void 0:s.toString(),(l=t.platform.instance_id)==null?void 0:l.toString()].filter(u=>u!==void 0).join(" ")}}throw new Error(`Unsupported entity type: ${t.entityType}`)}function Vkt(t){const e=Array.from(t.channels.values()),i=e.filter(p=>p.type==="ethernet").flatMap(p=>p.serviceInstances),n=e.filter(p=>p.type==="ethernet").flatMap(p=>p.endpoints),r=n.flatMap(p=>p.sockets),o=Array.from(t.ecus.values()),a=o.flatMap(p=>p.channels),s=o.flatMap(p=>p.container?[p.container]:[]),l=o.flatMap(p=>p.models?p.models:[]),u=Array.from(t.containers.values()),c=[...e,...o,...i,...n,...r,...u,...s,...l],d=[...c,...a],f=c.map(jkt),h=new Xz(["name","entityType","ecu","channel","endpoint","socket","service_instance","extra"],f,[]);return{graph:t,entities:$kt(d,p=>ky(p)),index:h}}async function Hkt(t,e){if(e.trim()==="")return Promise.resolve({nodes:[Ty("channel",Array.from(t.graph.channels.values())),Ty("ecu",Array.from(t.graph.ecus.values())),Ty("container",Array.from(t.graph.containers.values()))].filter(s=>s!==void 0),entitiesCount:Object.keys(t.entities).length,filteredEntitiesCount:Object.keys(t.entities).length});const[i,n]=Ukt(e),o=(await t.index.search(i,n)).map(s=>t.entities[s.id]),a=zkt(o,s=>s.entityType);return Promise.resolve({nodes:[Ty("channel",a.channel),Ty("ecu",a.ecu),Ty("endpoint",a.endpoint),Ty("socket",a.socket),Ty("service_instance",a.service_instance),Ty("container",a.container),Ty("behavioral_model",a.behavioral_model)].filter(s=>s!==void 0),filteredEntitiesCount:o.length,entitiesCount:Object.keys(t.entities).length})}function Ukt(t){const e=t.split(" ").map(r=>{if(r.indexOf(":")>0){const[o,...a]=r.split(":");if(o==="ecu"||o==="channel"||o==="endpoint"||o==="socket"||o==="service_instance"||o==="container"||o==="behavioral_model")return{type:"entityType",entityType:o,value:a.join(":")}}return{type:"string",value:r}}),i=e.filter(r=>r.type==="string").map(r=>r.value).join(" "),n=e.filter(r=>r.type==="entityType").map(r=>HNe(!0,r.value,[r.entityType]));return[ML(i,["name","extra"]),n]}function zkt(t,e){return t.reduce((i,n)=>{const r=e(n);return(i[r]??(i[r]=[])).push(n),i},{})}function $kt(t,e){return t.reduce((i,n)=>{const r=e(n);if(i[r])throw new Error(`Duplicate key found when grouping by unique: ${String(r)}`);return i[r]=n,i},{})}function Wkt(t){return t.name}function Gkt(t,e){let i=t;for(;i!==null;){if(i.type==="entity"&&i.entity===e)return!0;i=i.parent}return!1}function xy(t,e){const i=Gkt(t,e);return{type:"entity",parent:t,path:`${t.path}/${ky(e)}`,name:`${Wkt(e)}`,isAncestorRef:i,entity:e,expandable:!(i||e.entityType==="container"&&e.ecu===void 0)}}function Ykt(t){return qkt(t).sort((e,i)=>{if(e.type==="folder"&&i.type==="entity")return-1;if(e.type==="entity"&&i.type==="folder")return 1;if(e.type==="entity"&&i.type==="entity"){const n=e.entity.entityType.localeCompare(i.entity.entityType);if(n!==0)return n}return e.name.localeCompare(i.name)})}function qkt(t){switch(t.type){case"folder":return t.children.map(e=>xy(t,e));case"entity":switch(t.entity.entityType){case"channel":{const e=t.entity;if(e.type==="ethernet"){const i=e.endpoints.length>0?{type:"folder",parent:t,childType:"endpoint",children:e.endpoints,name:"Endpoints",path:`${t.path}/endpoints`}:void 0,n=e.serviceInstances.length>0?{type:"folder",parent:t,childType:"service_instance",children:e.serviceInstances,name:"Service Instances",path:`${t.path}/serviceInstances`}:void 0,r=e.ecus.length>0?{type:"folder",parent:t,childType:"ecu",children:e.ecus,name:"ECUs",path:`${t.path}/ecus`}:void 0;return[i,n,r].filter(o=>o!==void 0)}return[{type:"folder",parent:t,childType:"ecu",children:e.ecus,name:"ECUs",path:`${t.path}/ecus`}]}case"ecu":{const e=t.entity,i=e.models&&e.models.length>0?[{type:"folder",parent:t,childType:"behavioral_model",children:e.models,name:"Behavioral Models",path:`${t.path}/models`}]:[];return[...[...e.channels,e.container].filter(r=>r!==void 0).map(r=>xy(t,r)),...i]}case"container":return[t.entity.ecu].filter(i=>i!==void 0).map(i=>xy(t,i));case"behavioral_model":return[t.entity.ecu].filter(i=>i!==void 0).map(i=>xy(t,i));case"ecu_channel":{const e=t.entity,i=e.config.type==="ethernet"&&e.config.providedEndpoints.length>0?[{type:"folder",parent:t,childType:"endpoint",children:e.config.providedEndpoints,name:"Provided Endpoints",path:`${t.path}/providedEndpoints`}]:[];return[xy(t,e.channel),xy(t,e.ecu),...i]}case"endpoint":{const e=t.entity,i=e.providedByEcu?xy(t,e.providedByEcu):void 0;return[e.sockets.length>0?{type:"folder",parent:t,childType:"socket",children:e.sockets,name:"Sockets",path:`${t.path}/sockets`}:void 0,i,xy(t,e.channel)].filter(r=>r!==void 0)}case"socket":{const e=t.entity,i=e.consumedServiceInstances.length>0?{type:"folder",parent:t,childType:"service_instance",children:e.consumedServiceInstances,name:"Consumed Service Instances",path:`${t.path}/consumedServiceInstances`}:void 0,n=e.providedServiceInstances.length>0?{type:"folder",parent:t,childType:"service_instance",children:e.providedServiceInstances,name:"Provided Service Instances",path:`${t.path}/providedServiceInstances`}:void 0,r=e.connections.length>0?{type:"folder",parent:t,childType:"socket",children:e.connections,name:"Connections",path:`${t.path}/connections`}:void 0;return[xy(t,e.endpoint),n,i,r].filter(o=>o!==void 0)}case"service_instance":{const e=t.entity,i=e.consumedBySockets.length>0?{type:"folder",parent:t,childType:"socket",children:e.consumedBySockets,name:"Consumed By Sockets",path:`${t.path}/consumedBySockets`}:void 0;return[e.providedBySocket&&xy(t,e.providedBySocket),i].filter(n=>n!==void 0)}}}}function Xkt(t){const e=qt.c(7),{tabId:i,params:n}=jne(),{updatePage:r}=Ih(),o=n==null?void 0:n.entityId;let a;e:{if(!t||!o){a=null;break e}a=t.entities[o]??null}const s=a;let l;e[0]!==n||e[1]!==i||e[2]!==r?(l=d=>{r(i,{params:{...n,entityId:d?ky(d):void 0}})},e[0]=n,e[1]=i,e[2]=r,e[3]=l):l=e[3];const u=l;let c;return e[4]!==u||e[5]!==s?(c={selectedEntity:s,selectEntity:u},e[4]=u,e[5]=s,e[6]=c):c=e[6],c}function Kkt(t){const e=qt.c(54),{content:i}=t;let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n={},e[0]=n):n=e[0];const[r,o]=J.useState(n),[a,s]=J.useState(""),[l,u]=J.useState(!1),[c,d]=J.useState(!1);let f;e[1]===Symbol.for("react.memo_cache_sentinel")?(f={hovered:null,highlightedEntity:null},e[1]=f):f=e[1];const[h,p]=J.useState(f),{track:g}=el();let v;try{let ve;if(e[2]!==i){const fe=Fkt(i);ve=Vkt(fe),e[2]=i,e[3]=ve}else ve=e[3];let pe;e[4]!==ve?(pe={graphIndex:ve,parseError:null},e[4]=ve,e[5]=pe):pe=e[5],v=pe}catch(ve){const pe=ve;let fe;e[6]===Symbol.for("react.memo_cache_sentinel")?(fe={graphIndex:null,parseError:pe instanceof Error?pe.message:"Failed to parse topology file"},e[6]=fe):fe=e[6],v=fe}const{graphIndex:y,parseError:m}=v,{selectedEntity:b,selectEntity:S}=Xkt(y);let _;e[7]===Symbol.for("react.memo_cache_sentinel")?(_=ve=>{s(ve),o({}),p({hovered:null,highlightedEntity:null})},e[7]=_):_=e[7];const C=_;let P;e[8]===Symbol.for("react.memo_cache_sentinel")?(P=ve=>{o(pe=>{const fe={...pe};return pe[ve.path]?delete fe[ve.path]:fe[ve.path]=Ykt(ve),fe})},e[8]=P):P=e[8];const x=P;let E;e[9]!==r||e[10]!==c?(E=ve=>{const pe=r[ve.path];return pe?c?pe.filter(Qkt):pe:[]},e[9]=r,e[10]=c,e[11]=E):E=e[11];const A=E;let R;e[12]!==r?(R=ve=>{const pe=r[ve.path];return pe?pe.filter(Jkt):[]},e[12]=r,e[13]=R):R=e[13];const M=R;let D;e[14]===Symbol.for("react.memo_cache_sentinel")?(D=ve=>{p({hovered:ve,highlightedEntity:ve.type!=="folder"?ve.entity:null})},e[14]=D):D=e[14];const F=D;let I;e[15]===Symbol.for("react.memo_cache_sentinel")?(I=ve=>{p({hovered:null,highlightedEntity:ve})},e[15]=I):I=e[15];const V=I;let z;e[16]===Symbol.for("react.memo_cache_sentinel")?(z=ve=>{const pe="type"in ve&&ve.type==="folder",fe="type"in ve&&ve.type==="entity",me="entityType"in ve;pe||fe?F(ve):me&&V(ve)},e[16]=z):z=e[16];const G=z;let H;e[17]===Symbol.for("react.memo_cache_sentinel")?(H=()=>{p({hovered:null,highlightedEntity:null})},e[17]=H):H=e[17];const U=H;let k;e[18]===Symbol.for("react.memo_cache_sentinel")?(k={nodes:[],filteredEntitiesCount:0,entitiesCount:0},e[18]=k):k=e[18];const[X,W]=J.useState(k);let Y,te;e[19]!==y||e[20]!==a||e[21]!==c?(Y=()=>{let ve=!1;return(async()=>{if(ve)return;if(!y)return W({nodes:[],filteredEntitiesCount:0,entitiesCount:0});const fe=await Hkt(y,a),me=c?fe.nodes.filter(Zkt):fe.nodes;W({nodes:me,filteredEntitiesCount:fe.filteredEntitiesCount,entitiesCount:fe.entitiesCount})})(),()=>{ve=!0}},te=[y,a,c],e[19]=y,e[20]=a,e[21]=c,e[22]=Y,e[23]=te):(Y=e[22],te=e[23]),J.useEffect(Y,te);const oe=X.nodes;let de,ge;e[24]!==a||e[25]!==X.entitiesCount||e[26]!==X.filteredEntitiesCount||e[27]!==g?(de=()=>{a.trim()!==""&&g(Fi.TopologySearch,{filteredEntitiesCount:X.filteredEntitiesCount,entitiesCount:X.entitiesCount,searchQueryCharactersCount:a.length})},ge=[g,a,X.filteredEntitiesCount,X.entitiesCount],e[24]=a,e[25]=X.entitiesCount,e[26]=X.filteredEntitiesCount,e[27]=g,e[28]=de,e[29]=ge):(de=e[28],ge=e[29]),J.useEffect(de,ge);let Ee;e[30]!==r?(Ee=ve=>r[ve.path]!==void 0,e[30]=r,e[31]=Ee):Ee=e[31];const Re=Ee;let Ae;e[32]!==b?(Ae=ve=>ve.type!=="folder"&&b!==null&&ve.entity===b,e[32]=b,e[33]=Ae):Ae=e[33];const Pe=Ae;let we;e[34]!==h.hovered?(we=ve=>h.hovered===ve,e[34]=h.hovered,e[35]=we):we=e[35];const Te=we;let ke;e[36]!==h.highlightedEntity||e[37]!==h.hovered?(ke=ve=>ve.type!=="folder"&&h.highlightedEntity===ve.entity&&h.hovered!==ve,e[36]=h.highlightedEntity,e[37]=h.hovered,e[38]=ke):ke=e[38];const $e=ke;let Ne;return e[39]!==oe||e[40]!==A||e[41]!==M||e[42]!==h||e[43]!==Re||e[44]!==$e||e[45]!==Te||e[46]!==Pe||e[47]!==m||e[48]!==a||e[49]!==S||e[50]!==b||e[51]!==c||e[52]!==l?(Ne={parseError:m,filteredNodes:oe,searchQuery:a,setSearchQuery:C,showSearchOptions:l,setShowSearchOptions:u,showOnlyInstanced:c,setShowOnlyInstanced:d,toggleNode:x,getChildren:A,getUninstantiatedChildren:M,hoverState:h,handleMouseEnter:G,handleMouseLeave:U,selectedEntity:b,selectEntity:S,isNodeExpanded:Re,isNodeSelected:Pe,isNodeHovered:Te,isNodeHighlightedAncestor:$e},e[39]=oe,e[40]=A,e[41]=M,e[42]=h,e[43]=Re,e[44]=$e,e[45]=Te,e[46]=Pe,e[47]=m,e[48]=a,e[49]=S,e[50]=b,e[51]=c,e[52]=l,e[53]=Ne):Ne=e[53],Ne}function Zkt(t){return t.type==="folder"||t.entity.instance}function Jkt(t){return t.type==="entity"&&!t.entity.instance}function Qkt(t){return t.type==="folder"||!!t.entity.instance}function Vxe(t){const e=qt.c(11),{message:i,error:n,className:r}=t;let o;e[0]!==r?(o=Hr("h-full flex flex-col items-center justify-center",r),e[0]=r,e[1]=o):o=e[1];let a;e[2]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx("div",{className:"p-4 rounded-xl bg-destructive/10 mb-4",children:L.jsx(Wr,{type:dr.STATUS_ERROR,className:"w-8 h-8 text-destructive"})}),e[2]=a):a=e[2];let s;e[3]!==i?(s=L.jsx("p",{className:"text-foreground font-medium mb-1",children:i}),e[3]=i,e[4]=s):s=e[4];let l;e[5]!==n?(l=L.jsx("p",{className:"text-sm text-muted-foreground text-center max-w-md",children:n}),e[5]=n,e[6]=l):l=e[6];let u;return e[7]!==o||e[8]!==s||e[9]!==l?(u=L.jsxs("div",{className:o,children:[a,s,l]}),e[7]=o,e[8]=s,e[9]=l,e[10]=u):u=e[10],u}function Ine(t){const e=qt.c(8);let i;e[0]!==t.className?(i=Hr("text-xs font-medium text-foreground",t.className),e[0]=t.className,e[1]=i):i=e[1];let n;e[2]!==t.subtitle?(n=t.subtitle!=null&&t.subtitle!==""&&L.jsx("span",{className:"ms-2 font-normal text-muted-foreground",children:t.subtitle}),e[2]=t.subtitle,e[3]=n):n=e[3];let r;return e[4]!==t.title||e[5]!==i||e[6]!==n?(r=L.jsxs("div",{className:i,children:[t.title,n]}),e[4]=t.title,e[5]=i,e[6]=n,e[7]=r):r=e[7],r}function eIt(t){return t==null?"N/A":typeof t=="boolean"?t?"Yes":"No":String(t)}function tIt(t){const e=qt.c(10);let i;e[0]!==t.value?(i=eIt(t.value),e[0]=t.value,e[1]=i):i=e[1];const n=i;let r;e[2]!==t.label?(r=L.jsxs("span",{className:"text-muted-foreground min-w-[100px] shrink-0",children:[t.label,":"]}),e[2]=t.label,e[3]=r):r=e[3];let o;e[4]!==n||e[5]!==t.onClick?(o=t.onClick?L.jsx("button",{className:"text-primary hover:underline break-all text-left cursor-pointer",onClick:t.onClick,children:n}):L.jsx("span",{className:"text-foreground break-all",children:n}),e[4]=n,e[5]=t.onClick,e[6]=o):o=e[6];let a;return e[7]!==r||e[8]!==o?(a=L.jsxs("div",{className:"mx-4 flex items-start gap-2 text-xs",children:[r,o]}),e[7]=r,e[8]=o,e[9]=a):a=e[9],a}function Ys(t){const e=qt.c(8);let i;e[0]!==t.subtitle||e[1]!==t.title?(i=t.title!=null&&L.jsx(Ine,{className:"mb-2",title:t.title,subtitle:t.subtitle}),e[0]=t.subtitle,e[1]=t.title,e[2]=i):i=e[2];let n;e[3]!==t.rows?(n=t.rows.map(rIt),e[3]=t.rows,e[4]=n):n=e[4];let r;return e[5]!==i||e[6]!==n?(r=L.jsxs("div",{className:"space-y-0.5 my-3 mb-5",children:[i,n]}),e[5]=i,e[6]=n,e[7]=r):r=e[7],r}function rIt(t){const[e,i,n]=t;return L.jsx(tIt,{label:e,value:i,onClick:n},e)}function iIt(t,e){const i=t.split("/");i.pop();for(const n of e.replace(/^\.\//,"").split("/"))n===".."?i.pop():i.push(n);return i.join("/")}function nIt(t){const e=qt.c(54),{channel:i,filePath:n,entity:r}=t,o=Kwe();let a;e[0]!==r.platform.database||e[1]!==n||e[2]!==o?(a=()=>{const f=r.platform.database;f&&n&&o(iIt(n,f))},e[0]=r.platform.database,e[1]=n,e[2]=o,e[3]=a):a=e[3];const s=a,u=!!(r.platform.database&&n)?s:void 0;let c;e[4]!==r.platform.database||e[5]!==u?(c=[u?["Database",r.platform.database,u]:["Database",r.platform.database]],e[4]=r.platform.database,e[5]=u,e[6]=c):c=e[6];const d=c;switch(i.type){case"flexray":{let f;e[7]!==i.platform.flexray_physical_channel_name?(f=["Channel name",i.platform.flexray_physical_channel_name],e[7]=i.platform.flexray_physical_channel_name,e[8]=f):f=e[8];let h;e[9]!==i.platform.speed?(h=["Speed",i.platform.speed],e[9]=i.platform.speed,e[10]=h):h=e[10];let p;e[11]!==i.platform.is_high_low_byte_order?(p=["High/Low Byte Order",i.platform.is_high_low_byte_order],e[11]=i.platform.is_high_low_byte_order,e[12]=p):p=e[12];let g;e[13]!==i.platform.macrotick_microseconds?(g=["Macrotick (µs)",i.platform.macrotick_microseconds],e[13]=i.platform.macrotick_microseconds,e[14]=g):g=e[14];let v;e[15]!==i.platform.static_slot_macroticks?(v=["Static Slot Macroticks",i.platform.static_slot_macroticks],e[15]=i.platform.static_slot_macroticks,e[16]=v):v=e[16];let y;e[17]!==i.platform.cycle_microseconds?(y=["Cycle (µs)",i.platform.cycle_microseconds],e[17]=i.platform.cycle_microseconds,e[18]=y):y=e[18];let m;e[19]!==i.platform.number_of_static_slots?(m=["Number of Static Slots",i.platform.number_of_static_slots],e[19]=i.platform.number_of_static_slots,e[20]=m):m=e[20];let b;e[21]!==i.platform.number_of_minislots?(b=["Number of Minislots",i.platform.number_of_minislots],e[21]=i.platform.number_of_minislots,e[22]=b):b=e[22];let S;return e[23]!==d||e[24]!==f||e[25]!==h||e[26]!==p||e[27]!==g||e[28]!==v||e[29]!==y||e[30]!==m||e[31]!==b?(S=L.jsx(Ys,{title:"Platform",rows:[...d,f,h,p,g,v,y,m,b]}),e[23]=d,e[24]=f,e[25]=h,e[26]=p,e[27]=g,e[28]=v,e[29]=y,e[30]=m,e[31]=b,e[32]=S):S=e[32],S}case"ethernet":{let f;e[33]!==i.platform.subnet?(f=["Subnet",i.platform.subnet],e[33]=i.platform.subnet,e[34]=f):f=e[34];let h;e[35]!==i.platform.cluster_name?(h=["Cluster Name",i.platform.cluster_name],e[35]=i.platform.cluster_name,e[36]=h):h=e[36];let p;e[37]!==i.platform.vlan?(p=["VLAN",i.platform.vlan],e[37]=i.platform.vlan,e[38]=p):p=e[38];let g;return e[39]!==d||e[40]!==f||e[41]!==h||e[42]!==p?(g=L.jsx(Ys,{title:"Platform",rows:[...d,f,h,p]}),e[39]=d,e[40]=f,e[41]=h,e[42]=p,e[43]=g):g=e[43],g}case"lin":{let f;return e[44]!==d?(f=L.jsx(Ys,{title:"Platform",rows:[...d]}),e[44]=d,e[45]=f):f=e[45],f}case"can":{let f;e[46]!==i.platform.baudrate?(f=["Baudrate",i.platform.baudrate],e[46]=i.platform.baudrate,e[47]=f):f=e[47];let h;e[48]!==i.platform.can_physical_channel_name?(h=["CAN Physical Channel Name",i.platform.can_physical_channel_name],e[48]=i.platform.can_physical_channel_name,e[49]=h):h=e[49];let p;return e[50]!==d||e[51]!==f||e[52]!==h?(p=L.jsx(Ys,{title:"Platform",rows:[...d,f,h]}),e[50]=d,e[51]=f,e[52]=h,e[53]=p):p=e[53],p}}}function oIt(t){var i,n,r,o;const e=qt.c(55);switch((i=t.instance.driver)==null?void 0:i.type){case"virtual":{let a;e[0]!==t.instance.driver.subnet?(a=["Subnet",t.instance.driver.subnet],e[0]=t.instance.driver.subnet,e[1]=a):a=e[1];let s;e[2]!==t.instance.driver.target_host?(s=["Target host",t.instance.driver.target_host],e[2]=t.instance.driver.target_host,e[3]=s):s=e[3];let l;e[4]!==t.instance.driver.port?(l=["Port",t.instance.driver.port],e[4]=t.instance.driver.port,e[5]=l):l=e[5];let u;return e[6]!==a||e[7]!==s||e[8]!==l?(u=L.jsx(Ys,{title:"Instance",subtitle:"Virtual",rows:[a,s,l]}),e[6]=a,e[7]=s,e[8]=l,e[9]=u):u=e[9],u}case"bridge":{let a;return e[10]!==t.instance.driver.name?(a=L.jsx(Ys,{title:"Instance",subtitle:"Bridge",rows:[["Name",t.instance.driver.name]]}),e[10]=t.instance.driver.name,e[11]=a):a=e[11],a}case"udp":{let a;e[12]!==t.instance.driver.target_host?(a=["Target host",t.instance.driver.target_host],e[12]=t.instance.driver.target_host,e[13]=a):a=e[13];let s;e[14]!==t.instance.driver.port?(s=["Target port",t.instance.driver.port],e[14]=t.instance.driver.port,e[15]=s):s=e[15];let l;e[16]!==t.instance.driver.subnet?(l=["Subnet",t.instance.driver.subnet],e[16]=t.instance.driver.subnet,e[17]=l):l=e[17];let u;return e[18]!==a||e[19]!==s||e[20]!==l?(u=L.jsx(Ys,{title:"Instance",subtitle:"UDP",rows:[a,s,l]}),e[18]=a,e[19]=s,e[20]=l,e[21]=u):u=e[21],u}case"remotivebus":switch((n=t.instance.driver.config)==null?void 0:n.type){case"can":{let a;e[22]!==t.instance.driver.config.device?(a=["Device",t.instance.driver.config.device],e[22]=t.instance.driver.config.device,e[23]=a):a=e[23];let s;e[24]!==t.instance.driver.config.host_device?(s=["Host device",t.instance.driver.config.host_device],e[24]=t.instance.driver.config.host_device,e[25]=s):s=e[25];let l;e[26]!==t.instance.driver.config.txqueuelen?(l=["TX queue length",t.instance.driver.config.txqueuelen],e[26]=t.instance.driver.config.txqueuelen,e[27]=l):l=e[27];let u;return e[28]!==a||e[29]!==s||e[30]!==l?(u=L.jsx("div",{children:L.jsx(Ys,{title:"Instance",subtitle:"RemotiveBus CAN",rows:[a,s,l]})}),e[28]=a,e[29]=s,e[30]=l,e[31]=u):u=e[31],u}case"vcan":{let a;e[32]!==t.instance.driver.config.device?(a=["Device",t.instance.driver.config.device],e[32]=t.instance.driver.config.device,e[33]=a):a=e[33];let s;e[34]!==t.instance.driver.config.host_device?(s=["Host device",t.instance.driver.config.host_device],e[34]=t.instance.driver.config.host_device,e[35]=s):s=e[35];let l;e[36]!==a||e[37]!==s?(l=L.jsx(Ys,{title:"Instance",subtitle:"RemotiveBus VCAN",rows:[a,s]}),e[36]=a,e[37]=s,e[38]=l):l=e[38];let u;e[39]!==t.instance.driver.config.plugin?(u=t.instance.driver.config.plugin&&L.jsx(aIt,{plugin:t.instance.driver.config.plugin}),e[39]=t.instance.driver.config.plugin,e[40]=u):u=e[40];let c;return e[41]!==l||e[42]!==u?(c=L.jsxs("div",{children:[l,u]}),e[41]=l,e[42]=u,e[43]=c):c=e[43],c}default:{const a=(r=t.instance.driver)==null?void 0:r.type;let s;return e[44]!==a?(s=L.jsxs("div",{children:["Unknown driver type ",a]}),e[44]=a,e[45]=s):s=e[45],s}}case"dockercan":{let a;e[46]!==t.instance.driver.device_name?(a=["Device",t.instance.driver.device_name],e[46]=t.instance.driver.device_name,e[47]=a):a=e[47];let s;e[48]!==t.instance.driver.peer?(s=["Peer",t.instance.driver.peer],e[48]=t.instance.driver.peer,e[49]=s):s=e[49];let l;return e[50]!==a||e[51]!==s?(l=L.jsx(Ys,{title:"Instance",subtitle:"DockerCAN",rows:[a,s]}),e[50]=a,e[51]=s,e[52]=l):l=e[52],l}default:{const a=(o=t.instance.driver)==null?void 0:o.type;let s;return e[53]!==a?(s=L.jsxs("div",{children:["Unknown driver type ",a]}),e[53]=a,e[54]=s):s=e[54],s}}}function aIt(t){const e=qt.c(5),n=`Plugin${`${t.plugin.driver?` (${t.plugin.driver})`:""}`}`;let r;e[0]!==t.plugin?(r=Object.entries(t.plugin).filter(sIt),e[0]=t.plugin,e[1]=r):r=e[1];let o;return e[2]!==n||e[3]!==r?(o=L.jsx("div",{className:"mt-4",children:L.jsx(Ys,{title:"RemotiveBus",subtitle:n,rows:r})}),e[2]=n,e[3]=r,e[4]=o):o=e[4],o}function sIt(t){const[e]=t;return e!=="driver"}function lIt(t){const e=qt.c(9);let i;e[0]!==t.entity||e[1]!==t.filePath?(i=L.jsx(nIt,{channel:t.entity,filePath:t.filePath,entity:t.entity}),e[0]=t.entity,e[1]=t.filePath,e[2]=i):i=e[2];let n;e[3]!==t.entity||e[4]!==t.mode?(n=t.mode==="instance"&&t.entity.instance&&L.jsx("div",{className:"mt-4",children:L.jsx(oIt,{instance:t.entity.instance})}),e[3]=t.entity,e[4]=t.mode,e[5]=n):n=e[5];let r;return e[6]!==i||e[7]!==n?(r=L.jsxs(L.Fragment,{children:[i,n]}),e[6]=i,e[7]=n,e[8]=r):r=e[8],r}function uIt(t){const e=qt.c(18),{entity:i,mode:n}=t;if(n==="platform")return null;if(!i.instance){let v;return e[0]===Symbol.for("react.memo_cache_sentinel")?(v=L.jsx(Ys,{title:"Not instantiated",rows:[]}),e[0]=v):v=e[0],v}let r;e[1]!==i.instance.models?(r=i.instance.models?Object.keys(i.instance.models):[],e[1]=i.instance.models,e[2]=r):r=e[2];const o=r;let a;e[3]!==i.instance?(a=a4e(i.instance),e[3]=i.instance,e[4]=a):a=e[4];const s=a,l=i.instance.mock!==void 0;let u;e[5]!==l?(u=["Mock",l],e[5]=l,e[6]=u):u=e[6];const c=i.instance.container!==void 0;let d;e[7]!==c?(d=["Container",c],e[7]=c,e[8]=d):d=e[8];const f=o.length>0?o.join(", "):"-";let h;e[9]!==f?(h=["Models",f],e[9]=f,e[10]=h):h=e[10];let p;e[11]!==u||e[12]!==d||e[13]!==h?(p=[u,d,h],e[11]=u,e[12]=d,e[13]=h,e[14]=p):p=e[14];let g;return e[15]!==s||e[16]!==p?(g=L.jsx(Ys,{title:"Instance",subtitle:s,rows:p}),e[15]=s,e[16]=p,e[17]=g):g=e[17],g}const cIt={ecu_channel:{icon:dr.TOPOLOGY_SERVICE,color:"text-amber-500",hoverBg:"hover:bg-amber-500/10",badgeBg:"bg-amber-500"},service_instance:{icon:dr.TOPOLOGY_INSTANCE,color:"text-purple-500",hoverBg:"hover:bg-purple-500/10",badgeBg:"bg-purple-500"},socket:{icon:dr.TOPOLOGY_SOCKET,color:"text-cyan-500",hoverBg:"hover:bg-cyan-500/10",badgeBg:"bg-cyan-500"},endpoint:{icon:dr.TOPOLOGY_ENDPOINT,color:"text-rose-500",hoverBg:"hover:bg-rose-500/10",badgeBg:"bg-rose-500"},ecu:{icon:dr.TOPOLOGY_ECU,color:"text-blue-500",hoverBg:"hover:bg-blue-500/10",badgeBg:"bg-blue-500"},channel:{icon:dr.TOPOLOGY_CHANNEL,color:"text-emerald-500",hoverBg:"hover:bg-emerald-500/10",badgeBg:"bg-emerald-500"},container:{icon:dr.TOPOLOGY_CONTAINER,color:"text-green-500",hoverBg:"hover:bg-green-500/10",badgeBg:"bg-green-500"},behavioral_model:{icon:dr.TOPOLOGY_BEHAVIORAL_MODEL,color:"text-green-500",hoverBg:"hover:bg-green-500/10",badgeBg:"bg-green-500"}};function AJ(t){return cIt[t]}function s4e(t){const e=qt.c(33);let i,n,r,o;if(e[0]!==t.className||e[1]!==t.entity.entityType){const{icon:g,color:v}=AJ(t.entity.entityType);i=g,e[6]!==t.className?(o=Hr("flex items-center justify-between gap-2 px-2 overflow-hidden my-1",t.className),e[6]=t.className,e[7]=o):o=e[7],r="flex items-center gap-3 min-w-0 flex-1",n=Hr("p-1 rounded shrink-0",v),e[0]=t.className,e[1]=t.entity.entityType,e[2]=i,e[3]=n,e[4]=r,e[5]=o}else i=e[2],n=e[3],r=e[4],o=e[5];let a;e[8]!==i?(a=L.jsx(Wr,{type:i,className:"w-3.5 h-3.5"}),e[8]=i,e[9]=a):a=e[9];let s;e[10]!==n||e[11]!==a?(s=L.jsx("div",{className:n,children:a}),e[10]=n,e[11]=a,e[12]=s):s=e[12];let l;e[13]!==t.subtitle?(l=t.subtitle!=null&&t.subtitle!==""&&L.jsx("span",{className:"ms-2 text-xs text-muted-foreground font-normal truncate",title:t.subtitle,children:t.subtitle}),e[13]=t.subtitle,e[14]=l):l=e[14];let u;e[15]!==t.entity.name||e[16]!==l?(u=L.jsxs("p",{className:"w-full text-sm font-semibold truncate flex items-baseline gap-0",title:t.entity.name,children:[t.entity.name,l]}),e[15]=t.entity.name,e[16]=l,e[17]=u):u=e[17];let c;e[18]!==t.entity.entityType?(c=L.jsx("p",{className:"w-full text-xs text-muted-foreground truncate capitalize",title:t.entity.entityType,children:t.entity.entityType}),e[18]=t.entity.entityType,e[19]=c):c=e[19];let d;e[20]!==u||e[21]!==c?(d=L.jsxs("div",{className:"min-w-0 flex-1 flex flex-col items-baseline",children:[u,c]}),e[20]=u,e[21]=c,e[22]=d):d=e[22];let f;e[23]!==r||e[24]!==s||e[25]!==d?(f=L.jsxs("div",{className:r,children:[s,d]}),e[23]=r,e[24]=s,e[25]=d,e[26]=f):f=e[26];let h;e[27]!==t.onClose?(h=t.onClose!=null&&L.jsx("button",{onClick:t.onClose,className:"p-2 rounded-md hover:bg-muted transition-colors shrink-0","aria-label":"Close detail panel",children:L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-4 h-4 text-muted-foreground"})}),e[27]=t.onClose,e[28]=h):h=e[28];let p;return e[29]!==h||e[30]!==o||e[31]!==f?(p=L.jsxs("div",{className:o,children:[f,h]}),e[29]=h,e[30]=o,e[31]=f,e[32]=p):p=e[32],p}function yG(t){const e=qt.c(3);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx(Ine,{className:"mb-2 mt-3",title:"Related Entities"}),e[0]=i):i=e[0];let n;return e[1]!==t.children?(n=L.jsxs(L.Fragment,{children:[i,t.children]}),e[1]=t.children,e[2]=n):n=e[2],n}function Dv(t){const e=qt.c(9),{entity:i,subtitle:n,onSelectEntity:r,onEntityMouseEnter:o,onEntityMouseLeave:a}=t;let s;e[0]!==i||e[1]!==n?(s=L.jsx(s4e,{entity:i,subtitle:n}),e[0]=i,e[1]=n,e[2]=s):s=e[2];const l=s;let u;return e[3]!==i||e[4]!==l||e[5]!==o||e[6]!==a||e[7]!==r?(u=L.jsx("div",{className:"flex flex-col mb-1",children:r!=null?L.jsx("button",{type:"button",onClick:()=>r(i),onMouseEnter:()=>o==null?void 0:o(i),onMouseLeave:()=>a==null?void 0:a(),className:Hr("w-full text-left rounded-md transition-colors","hover:bg-muted active:opacity-90 cursor-pointer","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/40 focus-visible:ring-offset-2 focus-visible:ring-offset-background"),children:l}):l}),e[3]=i,e[4]=l,e[5]=o,e[6]=a,e[7]=r,e[8]=u):u=e[8],u}function dIt(t){const e=qt.c(22),{entity:i,mode:n,onSelectEntity:r,onEntityMouseEnter:o,onEntityMouseLeave:a}=t,s=fIt;let l;e[0]!==i.platform.database?(l=L.jsx(Ys,{title:"Platform",rows:[["Database",i.platform.database]]}),e[0]=i.platform.database,e[1]=l):l=e[1];let u;e[2]!==i.instance||e[3]!==n?(u=n==="instance"&&i.instance&&s(i.instance),e[2]=i.instance,e[3]=n,e[4]=u):u=e[4];let c;e[5]!==i.ecu||e[6]!==o||e[7]!==a||e[8]!==r?(c=L.jsx(Dv,{entity:i.ecu,onSelectEntity:r,onEntityMouseEnter:o,onEntityMouseLeave:a}),e[5]=i.ecu,e[6]=o,e[7]=a,e[8]=r,e[9]=c):c=e[9];let d;e[10]!==i.channel||e[11]!==o||e[12]!==a||e[13]!==r?(d=L.jsx(Dv,{entity:i.channel,onSelectEntity:r,onEntityMouseEnter:o,onEntityMouseLeave:a}),e[10]=i.channel,e[11]=o,e[12]=a,e[13]=r,e[14]=d):d=e[14];let f;e[15]!==c||e[16]!==d?(f=L.jsxs(yG,{children:[c,d]}),e[15]=c,e[16]=d,e[17]=f):f=e[17];let h;return e[18]!==l||e[19]!==u||e[20]!==f?(h=L.jsxs(L.Fragment,{children:[l,u,f]}),e[18]=l,e[19]=u,e[20]=f,e[21]=h):h=e[21],h}function fIt(t){var e;switch((e=t.config)==null?void 0:e.type){case void 0:return L.jsx(Ys,{title:"Instance",rows:[]});case"can":return L.jsx(Ys,{title:"Instance",subtitle:"CAN",rows:[]});case"ethernet":return L.jsx(Ys,{title:"Instance",subtitle:"Ethernet",rows:[]});case"lin":return L.jsx(Ys,{title:"Instance",subtitle:"LIN",rows:[["Schedule autostart",t.config.schedule_autostart],["Schedule table name",t.config.schedule_table_name]]})}}function hIt(t){const e=qt.c(6);if(t.description==null||t.description==="")return null;let i;if(e[0]!==t.description){let o;e[2]===Symbol.for("react.memo_cache_sentinel")?(o=/\.+$/,e[2]=o):o=e[2],i=t.description.trim().replace(o,""),e[0]=t.description,e[1]=i}else i=e[1];const n=i+".";let r;return e[3]!==t.description||e[4]!==n?(r=L.jsx("p",{className:"text-xs text-muted-foreground mb-2 break-words",title:t.description,children:n}),e[3]=t.description,e[4]=n,e[5]=r):r=e[5],r}function pIt(t){const e=qt.c(30),{entity:i,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}=t;let a;e[0]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(hIt,{}),e[0]=a):a=e[0];let s;e[1]!==i.platform.port?(s=["Port",i.platform.port],e[1]=i.platform.port,e[2]=s):s=e[2];let l;e[3]!==i.platform.type?(l=["Protocol",i.platform.type],e[3]=i.platform.type,e[4]=l):l=e[4];let u;e[5]!==s||e[6]!==l?(u=L.jsx(Ys,{title:"Platform",rows:[s,l]}),e[5]=s,e[6]=l,e[7]=u):u=e[7];let c;e[8]!==i.endpoint||e[9]!==r||e[10]!==o||e[11]!==n?(c=L.jsx(Dv,{entity:i.endpoint,subtitle:i.endpoint.platform.host,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[8]=i.endpoint,e[9]=r,e[10]=o,e[11]=n,e[12]=c):c=e[12];let d;e[13]!==i.endpoint.providedByEcu||e[14]!==r||e[15]!==o||e[16]!==n?(d=i.endpoint.providedByEcu&&L.jsx(Dv,{entity:i.endpoint.providedByEcu,subtitle:"Provided by",onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[13]=i.endpoint.providedByEcu,e[14]=r,e[15]=o,e[16]=n,e[17]=d):d=e[17];let f;e[18]!==i.channel||e[19]!==r||e[20]!==o||e[21]!==n?(f=L.jsx(Dv,{entity:i.channel,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[18]=i.channel,e[19]=r,e[20]=o,e[21]=n,e[22]=f):f=e[22];let h;e[23]!==c||e[24]!==d||e[25]!==f?(h=L.jsxs(yG,{children:[c,d,f]}),e[23]=c,e[24]=d,e[25]=f,e[26]=h):h=e[26];let p;return e[27]!==u||e[28]!==h?(p=L.jsxs(L.Fragment,{children:[a,u,h]}),e[27]=u,e[28]=h,e[29]=p):p=e[29],p}function gIt(t){const e=qt.c(18),{entity:i,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}=t;let a;e[0]!==i.platform.host?(a=L.jsx(Ys,{title:"Platform",rows:[["Host",i.platform.host]]}),e[0]=i.platform.host,e[1]=a):a=e[1];let s;e[2]!==i.providedByEcu||e[3]!==r||e[4]!==o||e[5]!==n?(s=i.providedByEcu&&L.jsx(Dv,{entity:i.providedByEcu,subtitle:"Provided by",onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[2]=i.providedByEcu,e[3]=r,e[4]=o,e[5]=n,e[6]=s):s=e[6];let l;e[7]!==i.channel||e[8]!==r||e[9]!==o||e[10]!==n?(l=L.jsx(Dv,{entity:i.channel,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[7]=i.channel,e[8]=r,e[9]=o,e[10]=n,e[11]=l):l=e[11];let u;e[12]!==s||e[13]!==l?(u=L.jsxs(yG,{children:[s,l]}),e[12]=s,e[13]=l,e[14]=u):u=e[14];let c;return e[15]!==a||e[16]!==u?(c=L.jsxs(L.Fragment,{children:[a,u]}),e[15]=a,e[16]=u,e[17]=c):c=e[17],c}function vIt(t){const e=qt.c(41),{entity:i,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}=t;let a;e[0]!==i.platform.service_id?(a=["Service ID",i.platform.service_id],e[0]=i.platform.service_id,e[1]=a):a=e[1];let s;e[2]!==i.platform.instance_id?(s=["Instance ID",i.platform.instance_id],e[2]=i.platform.instance_id,e[3]=s):s=e[3];let l;e[4]!==i.platform.version_major?(l=["Version Major",i.platform.version_major],e[4]=i.platform.version_major,e[5]=l):l=e[5];let u;e[6]!==i.platform.version_minor?(u=["Version Minor",i.platform.version_minor],e[6]=i.platform.version_minor,e[7]=u):u=e[7];let c;e[8]!==a||e[9]!==s||e[10]!==l||e[11]!==u?(c=L.jsx(Ys,{title:"Platform",rows:[a,s,l,u]}),e[8]=a,e[9]=s,e[10]=l,e[11]=u,e[12]=c):c=e[12];let d;e[13]!==i.providedBySocket||e[14]!==r||e[15]!==o||e[16]!==n?(d=i.providedBySocket&&L.jsx(Dv,{entity:i.providedBySocket,subtitle:`Provided by | ${kne(i.providedBySocket)}`,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[13]=i.providedBySocket,e[14]=r,e[15]=o,e[16]=n,e[17]=d):d=e[17];let f;e[18]!==i.providedBySocket||e[19]!==r||e[20]!==o||e[21]!==n?(f=i.providedBySocket&&L.jsx(Dv,{entity:i.providedBySocket.endpoint,subtitle:"Provided by",onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[18]=i.providedBySocket,e[19]=r,e[20]=o,e[21]=n,e[22]=f):f=e[22];let h;e[23]!==i.channel||e[24]!==r||e[25]!==o||e[26]!==n?(h=L.jsx(Dv,{entity:i.channel,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[23]=i.channel,e[24]=r,e[25]=o,e[26]=n,e[27]=h):h=e[27];let p;e[28]!==i.providedByEcu||e[29]!==r||e[30]!==o||e[31]!==n?(p=i.providedByEcu&&L.jsx(Dv,{entity:i.providedByEcu,subtitle:"Provided by",onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[28]=i.providedByEcu,e[29]=r,e[30]=o,e[31]=n,e[32]=p):p=e[32];let g;e[33]!==d||e[34]!==f||e[35]!==h||e[36]!==p?(g=L.jsxs(yG,{children:[d,f,h,p]}),e[33]=d,e[34]=f,e[35]=h,e[36]=p,e[37]=g):g=e[37];let v;return e[38]!==c||e[39]!==g?(v=L.jsxs(L.Fragment,{children:[c,g]}),e[38]=c,e[39]=g,e[40]=v):v=e[40],v}function l4e(t){var Y,te,oe,de,ge,Ee,Re,Ae,Pe,we,Te,ke,$e,Ne,ve,pe,fe,me,Ce,Ue,Qe,it,xt,wt,$t,Mt,rt,qe,vt,kt,Xe,_t,Ht,Pt,Jt,zt,Bt,Mr,Be,We;const e=qt.c(77),{entity:i}=t;let n;e[0]!==((Y=i.instance)==null?void 0:Y.profiles)?(n=((te=i.instance)==null?void 0:te.profiles)||[],e[0]=(oe=i.instance)==null?void 0:oe.profiles,e[1]=n):n=e[1];let r;e[2]!==n?(r=n.join(", "),e[2]=n,e[3]=r):r=e[3];let o;e[4]!==r?(o=["profiles",r],e[4]=r,e[5]=o):o=e[5];const a=((de=i.instance)==null?void 0:de.platform)||"";let s;e[6]!==a?(s=["platform",a],e[6]=a,e[7]=s):s=e[7];const l=((ge=i.instance)==null?void 0:ge.image)||"";let u;e[8]!==l?(u=["image",l],e[8]=l,e[9]=u):u=e[9];let c;e[10]!==((Ee=i.instance)==null?void 0:Ee.volumes)?(c=((Re=i.instance)==null?void 0:Re.volumes)||[],e[10]=(Ae=i.instance)==null?void 0:Ae.volumes,e[11]=c):c=e[11];let d;e[12]!==c?(d=c.join(", "),e[12]=c,e[13]=d):d=e[13];let f;e[14]!==d?(f=["volumes",d],e[14]=d,e[15]=f):f=e[15];let h;e[16]!==((Pe=i.instance)==null?void 0:Pe.ports)?(h=((we=i.instance)==null?void 0:we.ports)||[],e[16]=(Te=i.instance)==null?void 0:Te.ports,e[17]=h):h=e[17];let p;e[18]!==h?(p=h.join(", "),e[18]=h,e[19]=p):p=e[19];let g;e[20]!==p?(g=["ports",p],e[20]=p,e[21]=g):g=e[21];let v;e[22]!==((ke=i.instance)==null?void 0:ke.environment)?(v=(($e=i.instance)==null?void 0:$e.environment)||[],e[22]=(Ne=i.instance)==null?void 0:Ne.environment,e[23]=v):v=e[23];let y;e[24]!==v?(y=v.join(", "),e[24]=v,e[25]=y):y=e[25];let m;e[26]!==y?(m=["environment",y],e[26]=y,e[27]=m):m=e[27];const b=((ve=i.instance)==null?void 0:ve.working_dir)||"";let S;e[28]!==b?(S=["working_dir",b],e[28]=b,e[29]=S):S=e[29];let _;e[30]!==((pe=i.instance)==null?void 0:pe.depends_on)?(_=((fe=i.instance)==null?void 0:fe.depends_on)||[],e[30]=(me=i.instance)==null?void 0:me.depends_on,e[31]=_):_=e[31];let C;e[32]!==_?(C=_.join(", "),e[32]=_,e[33]=C):C=e[33];let P;e[34]!==C?(P=["depends_on",C],e[34]=C,e[35]=P):P=e[35];const x=((Ce=i.instance)==null?void 0:Ce.command)||"";let E;e[36]!==x?(E=["command",x],e[36]=x,e[37]=E):E=e[37];let A;e[38]!==((Ue=i.instance)==null?void 0:Ue.cap_add)?(A=((Qe=i.instance)==null?void 0:Qe.cap_add)||[],e[38]=(it=i.instance)==null?void 0:it.cap_add,e[39]=A):A=e[39];let R;e[40]!==A?(R=A.join(", "),e[40]=A,e[41]=R):R=e[41];let M;e[42]!==R?(M=["cap_add",R],e[42]=R,e[43]=M):M=e[43];let D;e[44]!==((xt=i.instance)==null?void 0:xt.devices)?(D=((wt=i.instance)==null?void 0:wt.devices)||[],e[44]=($t=i.instance)==null?void 0:$t.devices,e[45]=D):D=e[45];let F;e[46]!==D?(F=D.join(", "),e[46]=D,e[47]=F):F=e[47];let I;e[48]!==F?(I=["devices",F],e[48]=F,e[49]=I):I=e[49];const V=((Mt=i.instance)==null?void 0:Mt.control_network)||"";let z;e[50]!==V?(z=["control_network",V],e[50]=V,e[51]=z):z=e[51];let G;e[52]!==((rt=i.instance)==null?void 0:rt.extra_hosts)?(G=((qe=i.instance)==null?void 0:qe.extra_hosts)||[],e[52]=(vt=i.instance)==null?void 0:vt.extra_hosts,e[53]=G):G=e[53];let H;e[54]!==G?(H=G.join(", "),e[54]=G,e[55]=H):H=e[55];let U;e[56]!==H?(U=["extra_hosts",H],e[56]=H,e[57]=U):U=e[57];let k;e[58]!==g||e[59]!==m||e[60]!==S||e[61]!==o||e[62]!==P||e[63]!==E||e[64]!==M||e[65]!==I||e[66]!==z||e[67]!==U||e[68]!==s||e[69]!==u||e[70]!==f?(k=L.jsx(Ys,{title:"Container",rows:[o,s,u,f,g,m,S,P,E,M,I,z,U]}),e[58]=g,e[59]=m,e[60]=S,e[61]=o,e[62]=P,e[63]=E,e[64]=M,e[65]=I,e[66]=z,e[67]=U,e[68]=s,e[69]=u,e[70]=f,e[71]=k):k=e[71];let X;e[72]!==((kt=i.instance)==null?void 0:kt.build)?(X=((Xe=i.instance)==null?void 0:Xe.build)&&L.jsx(Ys,{title:"Build",rows:[["args",(((Ht=(_t=i.instance)==null?void 0:_t.build)==null?void 0:Ht.args)||[]).join(", ")],["context",((Jt=(Pt=i.instance)==null?void 0:Pt.build)==null?void 0:Jt.context)||""],["dockerfile",((Bt=(zt=i.instance)==null?void 0:zt.build)==null?void 0:Bt.dockerfile)||""],["target",((Be=(Mr=i.instance)==null?void 0:Mr.build)==null?void 0:Be.target)||""]]}),e[72]=(We=i.instance)==null?void 0:We.build,e[73]=X):X=e[73];let W;return e[74]!==k||e[75]!==X?(W=L.jsxs(L.Fragment,{children:[k,X]}),e[74]=k,e[75]=X,e[76]=W):W=e[76],W}function yIt(t){const e=qt.c(10),{entity:i,onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}=t;let a;e[0]!==i.instance.type?(a=L.jsx(Ys,{title:"Behavioral Model",rows:[["Type",i.instance.type]]}),e[0]=i.instance.type,e[1]=a):a=e[1];let s;e[2]!==i.container||e[3]!==r||e[4]!==o||e[5]!==n?(s=i.container&&L.jsx(l4e,{entity:i.container,mode:"instance",onSelectEntity:n,onEntityMouseEnter:r,onEntityMouseLeave:o}),e[2]=i.container,e[3]=r,e[4]=o,e[5]=n,e[6]=s):s=e[6];let l;return e[7]!==a||e[8]!==s?(l=L.jsxs(L.Fragment,{children:[a,s]}),e[7]=a,e[8]=s,e[9]=l):l=e[9],l}function Yb(t){const e=qt.c(2);let i;return e[0]!==t.children?(i=L.jsx("div",{className:"px-4 pt-1",children:t.children}),e[0]=t.children,e[1]=i):i=e[1],i}function mIt(t){const e=qt.c(50);switch(t.entity.entityType){case"channel":{let i;return e[0]!==t.entity||e[1]!==t.filePath||e[2]!==t.mode||e[3]!==t.onEntityMouseEnter||e[4]!==t.onEntityMouseLeave||e[5]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(lIt,{entity:t.entity,mode:t.mode,filePath:t.filePath,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[0]=t.entity,e[1]=t.filePath,e[2]=t.mode,e[3]=t.onEntityMouseEnter,e[4]=t.onEntityMouseLeave,e[5]=t.onSelectEntity,e[6]=i):i=e[6],i}case"ecu":{let i;return e[7]!==t.entity||e[8]!==t.mode||e[9]!==t.onEntityMouseEnter||e[10]!==t.onEntityMouseLeave||e[11]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(uIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[7]=t.entity,e[8]=t.mode,e[9]=t.onEntityMouseEnter,e[10]=t.onEntityMouseLeave,e[11]=t.onSelectEntity,e[12]=i):i=e[12],i}case"ecu_channel":{let i;return e[13]!==t.entity||e[14]!==t.mode||e[15]!==t.onEntityMouseEnter||e[16]!==t.onEntityMouseLeave||e[17]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(dIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[13]=t.entity,e[14]=t.mode,e[15]=t.onEntityMouseEnter,e[16]=t.onEntityMouseLeave,e[17]=t.onSelectEntity,e[18]=i):i=e[18],i}case"socket":{let i;return e[19]!==t.entity||e[20]!==t.mode||e[21]!==t.onEntityMouseEnter||e[22]!==t.onEntityMouseLeave||e[23]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(pIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[19]=t.entity,e[20]=t.mode,e[21]=t.onEntityMouseEnter,e[22]=t.onEntityMouseLeave,e[23]=t.onSelectEntity,e[24]=i):i=e[24],i}case"endpoint":{let i;return e[25]!==t.entity||e[26]!==t.mode||e[27]!==t.onEntityMouseEnter||e[28]!==t.onEntityMouseLeave||e[29]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(gIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[25]=t.entity,e[26]=t.mode,e[27]=t.onEntityMouseEnter,e[28]=t.onEntityMouseLeave,e[29]=t.onSelectEntity,e[30]=i):i=e[30],i}case"service_instance":{let i;return e[31]!==t.entity||e[32]!==t.mode||e[33]!==t.onEntityMouseEnter||e[34]!==t.onEntityMouseLeave||e[35]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(vIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[31]=t.entity,e[32]=t.mode,e[33]=t.onEntityMouseEnter,e[34]=t.onEntityMouseLeave,e[35]=t.onSelectEntity,e[36]=i):i=e[36],i}case"container":{let i;return e[37]!==t.entity||e[38]!==t.mode||e[39]!==t.onEntityMouseEnter||e[40]!==t.onEntityMouseLeave||e[41]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(l4e,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[37]=t.entity,e[38]=t.mode,e[39]=t.onEntityMouseEnter,e[40]=t.onEntityMouseLeave,e[41]=t.onSelectEntity,e[42]=i):i=e[42],i}case"behavioral_model":{let i;return e[43]!==t.entity||e[44]!==t.mode||e[45]!==t.onEntityMouseEnter||e[46]!==t.onEntityMouseLeave||e[47]!==t.onSelectEntity?(i=L.jsx(Yb,{children:L.jsx(yIt,{entity:t.entity,mode:t.mode,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[43]=t.entity,e[44]=t.mode,e[45]=t.onEntityMouseEnter,e[46]=t.onEntityMouseLeave,e[47]=t.onSelectEntity,e[48]=i):i=e[48],i}default:{let i;return e[49]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx(Yb,{children:L.jsx(Ine,{title:"Not supported"})}),e[49]=i):i=e[49],i}}}const bIt=400,SIt=200,_It=800;function PIt(t){const e=qt.c(29),i=mre(),[n,r]=J.useState(i?200:bIt),[o,a]=J.useState(!1),s=J.useRef(null);let l;e[0]===Symbol.for("react.memo_cache_sentinel")?(l=_=>{_.preventDefault(),a(!0)},e[0]=l):l=e[0];const u=l;let c,d;if(e[1]!==o?(c=()=>{if(!o)return;const _=P=>{if(!s.current)return;const E=s.current.getBoundingClientRect().right-P.clientX;r(Math.max(SIt,Math.min(_It,E)))},C=()=>{a(!1)};return document.addEventListener("mousemove",_),document.addEventListener("mouseup",C),()=>{document.removeEventListener("mousemove",_),document.removeEventListener("mouseup",C)}},d=[o],e[1]=o,e[2]=c,e[3]=d):(c=e[2],d=e[3]),J.useEffect(c,d),!t.entity){let _;return e[4]===Symbol.for("react.memo_cache_sentinel")?(_=L.jsx(L.Fragment,{}),e[4]=_):_=e[4],_}let f;e[5]===Symbol.for("react.memo_cache_sentinel")?(f=()=>L.jsx("div",{onMouseDown:u,className:Hr("absolute top-0 left-0 w-2 h-full cursor-ew-resize","hover:bg-primary/20 active:bg-primary/20 transition-colors")}),e[5]=f):f=e[5];const h=f;let p;e[6]!==t.className?(p=Hr("relative flex flex-col shrink-0","h-full overflow-hidden","border-s border-muted",t.className),e[6]=t.className,e[7]=p):p=e[7];let g;e[8]!==n?(g={width:n},e[8]=n,e[9]=g):g=e[9];let v;e[10]===Symbol.for("react.memo_cache_sentinel")?(v=h(),e[10]=v):v=e[10];let y;e[11]!==t.entity?(y=t.entity.entityType==="socket"?kne(t.entity):void 0,e[11]=t.entity,e[12]=y):y=e[12];let m;e[13]!==t.entity||e[14]!==t.onClose||e[15]!==y?(m=L.jsx(s4e,{subtitle:y,entity:t.entity,onClose:t.onClose,border:!0}),e[13]=t.entity,e[14]=t.onClose,e[15]=y,e[16]=m):m=e[16];let b;e[17]!==t.entity||e[18]!==t.filePath||e[19]!==t.mode||e[20]!==t.onEntityMouseEnter||e[21]!==t.onEntityMouseLeave||e[22]!==t.onSelectEntity?(b=L.jsx("div",{className:"flex-1 overflow-auto overscroll-contain",children:L.jsx(mIt,{entity:t.entity,mode:t.mode,filePath:t.filePath,onSelectEntity:t.onSelectEntity,onEntityMouseEnter:t.onEntityMouseEnter,onEntityMouseLeave:t.onEntityMouseLeave})}),e[17]=t.entity,e[18]=t.filePath,e[19]=t.mode,e[20]=t.onEntityMouseEnter,e[21]=t.onEntityMouseLeave,e[22]=t.onSelectEntity,e[23]=b):b=e[23];let S;return e[24]!==p||e[25]!==g||e[26]!==m||e[27]!==b?(S=L.jsxs("div",{ref:s,className:p,style:g,children:[v,m,b]}),e[24]=p,e[25]=g,e[26]=m,e[27]=b,e[28]=S):S=e[28],S}function CIt(t){const e=qt.c(18),i=t.disabled&&"opacity-50";let n;e[0]!==t.className||e[1]!==i?(n=Hr("relative",i,t.className),e[0]=t.className,e[1]=i,e[2]=n):n=e[2];let r;e[3]===Symbol.for("react.memo_cache_sentinel")?(r=L.jsx(Wr,{type:dr.ACTION_SEARCH,className:"absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground"}),e[3]=r):r=e[3];const o=t.searchQuery;let a;e[4]!==t?(a=p=>t.onSearchChange(p.target.value),e[4]=t,e[5]=a):a=e[5];const s=t.disabled,l=t.disabled&&"cursor-not-allowed";let u;e[6]!==l?(u=Hr("w-full pl-9 pr-10 py-2 text-sm rounded-full","bg-background dark:bg-muted/30 border border-border","text-foreground placeholder:text-muted-foreground","focus:outline-none focus:ring-2 focus:ring-primary/30 focus:border-primary/50","transition-colors",l),e[6]=l,e[7]=u):u=e[7];let c;e[8]!==t.disabled||e[9]!==t.searchQuery||e[10]!==a||e[11]!==u?(c=L.jsx("input",{type:"text",value:o,onChange:a,placeholder:"Search, e.g. bodycan or ecu:BCM",disabled:s,className:u}),e[8]=t.disabled,e[9]=t.searchQuery,e[10]=a,e[11]=u,e[12]=c):c=e[12];let d;e[13]===Symbol.for("react.memo_cache_sentinel")?(d=L.jsxs("div",{className:"max-w-xs space-y-2",children:[L.jsx("p",{className:"text-sm font-medium",children:"Search tips"}),L.jsx("p",{className:"text-xs text-neutral-400",children:'Start filtering in all categories by typing any text. Prepend the category name with a colon to filter in only that category, e.g. "ecu:CCZM" or "channel:BCM".'})]}),e[13]=d):d=e[13];let f;e[14]===Symbol.for("react.memo_cache_sentinel")?(f=L.jsx(FD,{side:"left",className:"absolute right-3 top-1/2 -translate-y-1/2",content:d,children:L.jsx("div",{className:"text-muted-foreground",children:L.jsx(Wr,{type:dr.STATUS_HELP,className:"w-4 h-4"})})}),e[14]=f):f=e[14];let h;return e[15]!==n||e[16]!==c?(h=L.jsxs("div",{className:n,children:[r,c,f]}),e[15]=n,e[16]=c,e[17]=h):h=e[17],h}const Hxe="text-muted-foreground text-xs m-0";function u4e(t){const e=qt.c(13);if(!(t.icon??t.title??t.subtitle??t.subtitleElement))return null;const n=t.subtitleElement??t.subtitle;let r;e[0]!==t.className?(r=Hr("flex flex-col items-center justify-center h-full text-center",t.className),e[0]=t.className,e[1]=r):r=e[1];let o;e[2]!==t.icon?(o=t.icon&&L.jsx("div",{className:"p-4 rounded-xl bg-muted mb-4",children:L.jsx("div",{className:"w-8 h-8 flex items-center justify-center [&>svg]:w-8 [&>svg]:h-8 text-muted-foreground",children:t.icon})}),e[2]=t.icon,e[3]=o):o=e[3];let a;e[4]!==n||e[5]!==t.subtitle||e[6]!==t.subtitleElement||e[7]!==t.title?(a=(t.title??n)&&L.jsxs("div",{className:"flex flex-col items-center justify-center mb-4",children:[t.title&&L.jsx("p",{className:"text-foreground text-sm mb-1",children:t.title}),t.subtitleElement!==void 0?L.jsx("div",{className:Hxe,children:t.subtitleElement}):t.subtitle!==void 0&&L.jsx("p",{className:Hxe,children:t.subtitle})]}),e[4]=n,e[5]=t.subtitle,e[6]=t.subtitleElement,e[7]=t.title,e[8]=a):a=e[8];let s;return e[9]!==r||e[10]!==o||e[11]!==a?(s=L.jsxs("div",{className:r,children:[o,a]}),e[9]=r,e[10]=o,e[11]=a,e[12]=s):s=e[12],s}function TIt(t){const e=qt.c(65),i=t.isSelected??!1,n=t.isHovered??!1,r=t.isHighlightedAsAncestor??!1,o=t.node.type!=="folder";let a,s,l,u,c,d,f,h,p,g,v;if(e[0]!==o||e[1]!==r||e[2]!==n||e[3]!==i||e[4]!==t){const{icon:b,color:S,hoverBg:_,badgeBg:C}=t.node.type==="folder"?AJ(t.node.childType):AJ(t.node.entity.entityType),P=t.node.type!=="folder"&&!t.node.expandable,x=t.node.type!=="folder"&&t.node.isAncestorRef,E=t.node.type==="entity"&&!!t.node.entity.instance,A=t.mode==="instance";let R;e[16]!==o||e[17]!==P||e[18]!==t?(R=()=>{var ge;!P&&!t.isExpanded&&t.onToggle(),o&&((ge=t.onInfoClick)==null||ge.call(t))},e[16]=o,e[17]=P,e[18]=t,e[19]=R):R=e[19];const M=R;let D;e[20]!==t?(D=ge=>{var Ee;ge.stopPropagation(),(Ee=t.onInfoClick)==null||Ee.call(t)},e[20]=t,e[21]=D):D=e[21];const F=D;let I;e[22]!==x||e[23]!==r||e[24]!==n?(I=()=>r?"bg-primary/20 ring-1 ring-primary/40":n&&x?"bg-muted/80":n?"bg-muted/60":"",e[22]=x,e[23]=r,e[24]=n,e[25]=I):I=e[25];const V=I;let z;e[26]!==P||e[27]!==t?(z=ge=>{ge.stopPropagation(),P||t.onToggle()},e[26]=P,e[27]=t,e[28]=z):z=e[28];const G=z;let H;e[29]!==G||e[30]!==P||e[31]!==t.isExpanded?(H=()=>P?L.jsx("span",{className:"w-4 h-4"}):L.jsx("span",{className:"w-4 h-4 flex items-center justify-center shrink-0 cursor-pointer",onClick:G,children:t.isExpanded?L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"w-3.5 h-3.5 text-muted-foreground"}):L.jsx(Wr,{type:dr.NAV_CHEVRON_RIGHT,className:"w-3.5 h-3.5 text-muted-foreground"})}),e[29]=G,e[30]=P,e[31]=t.isExpanded,e[32]=H):H=e[32];const U=H,k=()=>L.jsxs("div",{className:"relative shrink-0",children:[L.jsx(Wr,{type:b,className:Hr("w-4 h-4",x?"opacity-40":S,r&&"opacity-100")}),t.mode==="instance"&&E&&L.jsx("span",{className:Hr("absolute -top-0.5 -right-0.5 w-1.5 h-1.5 rounded-full ring-1 ring-background",x?"bg-current opacity-40":C)})]});let X;e[33]!==t.node.entity||e[34]!==t.node.type?(X=()=>{if(t.node.type!=="folder")switch(t.node.entity.entityType){case"endpoint":return t.node.entity.platform.host;case"socket":return kne(t.node.entity);case"ecu":return t.node.entity.instance&&a4e(t.node.entity.instance)}},e[33]=t.node.entity,e[34]=t.node.type,e[35]=X):X=e[35];const W=X;let Y;e[36]!==r||e[37]!==P||e[38]!==W||e[39]!==t.node.entity||e[40]!==t.node.name||e[41]!==t.node.type?(Y=()=>{const ge=t.node.type==="entity"&&t.node.entity.instance?"instance":void 0,Ee=[W(),ge].filter(Boolean).join(" | ");return L.jsx(L.Fragment,{children:L.jsxs("span",{className:Hr("truncate font-normal",P&&"italic",r&&"text-primary font-semibold"),children:[t.node.name,L.jsx("span",{className:"ms-1 text-xs text-muted-foreground",children:Ee})]})})},e[36]=r,e[37]=P,e[38]=W,e[39]=t.node.entity,e[40]=t.node.name,e[41]=t.node.type,e[42]=Y):Y=e[42];const te=Y;let oe;e[43]!==F||e[44]!==i?(oe=()=>L.jsx(L.Fragment,{children:L.jsx("button",{onClick:F,title:i?"This is currently selected":"View details",className:Hr("p-0.5 rounded transition-opacity",i?"opacity-100 text-foreground":"opacity-0 group-hover:opacity-100 hover:bg-muted/80 text-muted-foreground hover:text-foreground"),"aria-label":"View details",children:L.jsx(Wr,{type:dr.STATUS_INFO,className:"w-3.5 h-3.5"})})}),e[43]=F,e[44]=i,e[45]=oe):oe=e[45],a=oe,s=Hr("flex items-center gap-1.5 py-1.5 px-2 cursor-pointer rounded-md mx-1 group","text-sm transition-all duration-150",P?"text-muted-foreground/50 hover:text-muted-foreground/70 hover:bg-muted/40":Hr("text-foreground",_),V(),A&&!E&&t.node.type!=="folder"&&"opacity-70");const de=`${t.depth*20+8}px`;e[46]!==de?(l={paddingLeft:de},e[46]=de,e[47]=l):l=e[47],u=M,c=t.onMouseEnter,d=t.onMouseLeave,f=`topology-node-${t.node.path}`,h=t.node.path,e[48]!==U?(p=U(),e[48]=U,e[49]=p):p=e[49],g=k(),v=te(),e[0]=o,e[1]=r,e[2]=n,e[3]=i,e[4]=t,e[5]=a,e[6]=s,e[7]=l,e[8]=u,e[9]=c,e[10]=d,e[11]=f,e[12]=h,e[13]=p,e[14]=g,e[15]=v}else a=e[5],s=e[6],l=e[7],u=e[8],c=e[9],d=e[10],f=e[11],h=e[12],p=e[13],g=e[14],v=e[15];let y;e[50]!==o||e[51]!==a?(y=o&&a(),e[50]=o,e[51]=a,e[52]=y):y=e[52];let m;return e[53]!==s||e[54]!==l||e[55]!==y||e[56]!==u||e[57]!==c||e[58]!==d||e[59]!==f||e[60]!==h||e[61]!==p||e[62]!==g||e[63]!==v?(m=L.jsxs("div",{className:s,style:l,onClick:u,onMouseEnter:c,onMouseLeave:d,"data-testid":f,"data-node-id":h,children:[p,g,v,y]}),e[53]=s,e[54]=l,e[55]=y,e[56]=u,e[57]=c,e[58]=d,e[59]=f,e[60]=h,e[61]=p,e[62]=g,e[63]=v,e[64]=m):m=e[64],m}function xIt(t){const e=qt.c(10),i=EIt;let n,r,o;if(e[0]!==t){o=Symbol.for("react.early_return_sentinel");e:{const s=(l,u)=>{const c=t.isNodeExpanded(l),d=t.getChildren(l),f=t.getUninstantiatedChildren(l);return L.jsxs("div",{children:[L.jsx(TIt,{node:l,depth:u,mode:t.mode,isExpanded:c,onToggle:()=>t.onToggleNode(l,u),isSelected:t.isNodeSelected(l),isHovered:t.isNodeHovered(l),isHighlightedAsAncestor:t.isNodeHighlightedAncestor(l),onMouseEnter:()=>t.onNodeMouseEnter(l),onMouseLeave:t.onNodeMouseLeave,onInfoClick:()=>{var h;return(h=t.onNodeInfoClick)==null?void 0:h.call(t,l)}}),c&&L.jsxs(L.Fragment,{children:[d.map(h=>s(h,u+1)),t.showOnlyInstanced&&f.length>0&&L.jsx("span",{className:"text-xs italic text-muted-foreground block mt-1",style:{paddingLeft:`${(u+1)*20+8}px`},children:f.length===1?"Filtering out 1 uninstantiated child.":`Filtering out ${f.length} uninstantiated children.`})]})]},l.path)};if(t.searchQuery.trim()!==""&&t.nodes.length===0){let l;e[4]===Symbol.for("react.memo_cache_sentinel")?(l=L.jsx("div",{className:"flex-1 overflow-auto overscroll-contain py-2",children:L.jsx(u4e,{title:"No results match your search.",subtitle:"Try a different search term or clear the search to see the full tree."})}),e[4]=l):l=e[4],o=l;break e}if(t.nodes.length===0){let l;e[5]!==t.mode?(l=L.jsx("div",{className:"flex-1 overflow-auto overscroll-contain py-2",children:i(t.mode)}),e[5]=t.mode,e[6]=l):l=e[6],o=l;break e}n="flex-1 overflow-auto overscroll-contain py-2",r=t.nodes.map(l=>s(l,0))}e[0]=t,e[1]=n,e[2]=r,e[3]=o}else n=e[1],r=e[2],o=e[3];if(o!==Symbol.for("react.early_return_sentinel"))return o;let a;return e[7]!==n||e[8]!==r?(a=L.jsx("div",{className:n,children:r}),e[7]=n,e[8]=r,e[9]=a):a=e[9],a}function EIt(t){return L.jsx(u4e,{icon:L.jsx(Wr,{type:dr.SYSTEM_NETWORK,className:"w-8 h-8 text-muted-foreground"}),title:`There is nothing to visualize in this ${t}`,subtitleElement:L.jsxs("span",{className:"inline-flex",children:["You can still view the text content of the resolved ",t," by switching to the"," ",L.jsx(Wr,{type:dr.VIEW_TEXT,className:"w-4 h-4 text-muted-foreground mx-1"})," ","view."]})})}/**
   * table-core
   *
   * Copyright (c) TanStack
   *
   * This source code is licensed under the MIT license found in the
   * LICENSE.md file in the root directory of this source tree.
   *
   * @license MIT
   */function dP(t,e){return typeof t=="function"?t(e):t}function Dp(t,e){return i=>{e.setState(n=>({...n,[t]:dP(i,n[t])}))}}function mG(t){return t instanceof Function}function wIt(t){return Array.isArray(t)&&t.every(e=>typeof e=="number")}function AIt(t,e){const i=[],n=r=>{r.forEach(o=>{i.push(o);const a=e(o);a!=null&&a.length&&n(a)})};return n(t),i}function gn(t,e,i){let n=[],r;return o=>{let a;i.key&&i.debug&&(a=Date.now());const s=t(o);if(!(s.length!==n.length||s.some((c,d)=>n[d]!==c)))return r;n=s;let u;if(i.key&&i.debug&&(u=Date.now()),r=e(...s),i==null||i.onChange==null||i.onChange(r),i.key&&i.debug&&i!=null&&i.debug()){const c=Math.round((Date.now()-a)*100)/100,d=Math.round((Date.now()-u)*100)/100,f=d/16,h=(p,g)=>{for(p=String(p);p.length<g;)p=" "+p;return p};console.info(`%c⏱ ${h(d,5)} /${h(c,5)} ms`,`
            font-size: .6rem;
            font-weight: bold;
            color: hsl(${Math.max(0,Math.min(120-120*f,120))}deg 100% 31%);`,i==null?void 0:i.key)}return r}}function vn(t,e,i,n){return{debug:()=>{var r;return(r=t==null?void 0:t.debugAll)!=null?r:t[e]},key:!1,onChange:n}}function OIt(t,e,i,n){const r=()=>{var a;return(a=o.getValue())!=null?a:t.options.renderFallbackValue},o={id:`${e.id}_${i.id}`,row:e,column:i,getValue:()=>e.getValue(n),renderValue:r,getContext:gn(()=>[t,i,e,o],(a,s,l,u)=>({table:a,column:s,row:l,cell:u,getValue:u.getValue,renderValue:u.renderValue}),vn(t.options,"debugCells"))};return t._features.forEach(a=>{a.createCell==null||a.createCell(o,i,e,t)},{}),o}function DIt(t,e,i,n){var r,o;const s={...t._getDefaultColumnDef(),...e},l=s.accessorKey;let u=(r=(o=s.id)!=null?o:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof s.header=="string"?s.header:void 0,c;if(s.accessorFn?c=s.accessorFn:l&&(l.includes(".")?c=f=>{let h=f;for(const g of l.split(".")){var p;h=(p=h)==null?void 0:p[g]}return h}:c=f=>f[s.accessorKey]),!u)throw new Error;let d={id:`${String(u)}`,accessorFn:c,parent:n,depth:i,columnDef:s,columns:[],getFlatColumns:gn(()=>[!0],()=>{var f;return[d,...(f=d.columns)==null?void 0:f.flatMap(h=>h.getFlatColumns())]},vn(t.options,"debugColumns")),getLeafColumns:gn(()=>[t._getOrderColumnsFn()],f=>{var h;if((h=d.columns)!=null&&h.length){let p=d.columns.flatMap(g=>g.getLeafColumns());return f(p)}return[d]},vn(t.options,"debugColumns"))};for(const f of t._features)f.createColumn==null||f.createColumn(d,t);return d}const Md="debugHeaders";function Uxe(t,e,i){var n;let o={id:(n=i.id)!=null?n:e.id,column:e,index:i.index,isPlaceholder:!!i.isPlaceholder,placeholderId:i.placeholderId,depth:i.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const a=[],s=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(s),a.push(l)};return s(o),a},getContext:()=>({table:t,header:o,column:e})};return t._features.forEach(a=>{a.createHeader==null||a.createHeader(o,t)}),o}const RIt={createTable:t=>{t.getHeaderGroups=gn(()=>[t.getAllColumns(),t.getVisibleLeafColumns(),t.getState().columnPinning.left,t.getState().columnPinning.right],(e,i,n,r)=>{var o,a;const s=(o=n==null?void 0:n.map(d=>i.find(f=>f.id===d)).filter(Boolean))!=null?o:[],l=(a=r==null?void 0:r.map(d=>i.find(f=>f.id===d)).filter(Boolean))!=null?a:[],u=i.filter(d=>!(n!=null&&n.includes(d.id))&&!(r!=null&&r.includes(d.id)));return PU(e,[...s,...u,...l],t)},vn(t.options,Md)),t.getCenterHeaderGroups=gn(()=>[t.getAllColumns(),t.getVisibleLeafColumns(),t.getState().columnPinning.left,t.getState().columnPinning.right],(e,i,n,r)=>(i=i.filter(o=>!(n!=null&&n.includes(o.id))&&!(r!=null&&r.includes(o.id))),PU(e,i,t,"center")),vn(t.options,Md)),t.getLeftHeaderGroups=gn(()=>[t.getAllColumns(),t.getVisibleLeafColumns(),t.getState().columnPinning.left],(e,i,n)=>{var r;const o=(r=n==null?void 0:n.map(a=>i.find(s=>s.id===a)).filter(Boolean))!=null?r:[];return PU(e,o,t,"left")},vn(t.options,Md)),t.getRightHeaderGroups=gn(()=>[t.getAllColumns(),t.getVisibleLeafColumns(),t.getState().columnPinning.right],(e,i,n)=>{var r;const o=(r=n==null?void 0:n.map(a=>i.find(s=>s.id===a)).filter(Boolean))!=null?r:[];return PU(e,o,t,"right")},vn(t.options,Md)),t.getFooterGroups=gn(()=>[t.getHeaderGroups()],e=>[...e].reverse(),vn(t.options,Md)),t.getLeftFooterGroups=gn(()=>[t.getLeftHeaderGroups()],e=>[...e].reverse(),vn(t.options,Md)),t.getCenterFooterGroups=gn(()=>[t.getCenterHeaderGroups()],e=>[...e].reverse(),vn(t.options,Md)),t.getRightFooterGroups=gn(()=>[t.getRightHeaderGroups()],e=>[...e].reverse(),vn(t.options,Md)),t.getFlatHeaders=gn(()=>[t.getHeaderGroups()],e=>e.map(i=>i.headers).flat(),vn(t.options,Md)),t.getLeftFlatHeaders=gn(()=>[t.getLeftHeaderGroups()],e=>e.map(i=>i.headers).flat(),vn(t.options,Md)),t.getCenterFlatHeaders=gn(()=>[t.getCenterHeaderGroups()],e=>e.map(i=>i.headers).flat(),vn(t.options,Md)),t.getRightFlatHeaders=gn(()=>[t.getRightHeaderGroups()],e=>e.map(i=>i.headers).flat(),vn(t.options,Md)),t.getCenterLeafHeaders=gn(()=>[t.getCenterFlatHeaders()],e=>e.filter(i=>{var n;return!((n=i.subHeaders)!=null&&n.length)}),vn(t.options,Md)),t.getLeftLeafHeaders=gn(()=>[t.getLeftFlatHeaders()],e=>e.filter(i=>{var n;return!((n=i.subHeaders)!=null&&n.length)}),vn(t.options,Md)),t.getRightLeafHeaders=gn(()=>[t.getRightFlatHeaders()],e=>e.filter(i=>{var n;return!((n=i.subHeaders)!=null&&n.length)}),vn(t.options,Md)),t.getLeafHeaders=gn(()=>[t.getLeftHeaderGroups(),t.getCenterHeaderGroups(),t.getRightHeaderGroups()],(e,i,n)=>{var r,o,a,s,l,u;return[...(r=(o=e[0])==null?void 0:o.headers)!=null?r:[],...(a=(s=i[0])==null?void 0:s.headers)!=null?a:[],...(l=(u=n[0])==null?void 0:u.headers)!=null?l:[]].map(c=>c.getLeafHeaders()).flat()},vn(t.options,Md))}};function PU(t,e,i,n){var r,o;let a=0;const s=function(f,h){h===void 0&&(h=1),a=Math.max(a,h),f.filter(p=>p.getIsVisible()).forEach(p=>{var g;(g=p.columns)!=null&&g.length&&s(p.columns,h+1)},0)};s(t);let l=[];const u=(f,h)=>{const p={depth:h,id:[n,`${h}`].filter(Boolean).join("_"),headers:[]},g=[];f.forEach(v=>{const y=[...g].reverse()[0],m=v.column.depth===p.depth;let b,S=!1;if(m&&v.column.parent?b=v.column.parent:(b=v.column,S=!0),y&&(y==null?void 0:y.column)===b)y.subHeaders.push(v);else{const _=Uxe(i,b,{id:[n,h,b.id,v==null?void 0:v.id].filter(Boolean).join("_"),isPlaceholder:S,placeholderId:S?`${g.filter(C=>C.column===b).length}`:void 0,depth:h,index:g.length});_.subHeaders.push(v),g.push(_)}p.headers.push(v),v.headerGroup=p}),l.push(p),h>0&&u(g,h-1)},c=e.map((f,h)=>Uxe(i,f,{depth:a,index:h}));u(c,a-1),l.reverse();const d=f=>f.filter(p=>p.column.getIsVisible()).map(p=>{let g=0,v=0,y=[0];p.subHeaders&&p.subHeaders.length?(y=[],d(p.subHeaders).forEach(b=>{let{colSpan:S,rowSpan:_}=b;g+=S,y.push(_)})):g=1;const m=Math.min(...y);return v=v+m,p.colSpan=g,p.rowSpan=v,{colSpan:g,rowSpan:v}});return d((r=(o=l[0])==null?void 0:o.headers)!=null?r:[]),l}const MIt=(t,e,i,n,r,o,a)=>{let s={id:e,index:n,original:i,depth:r,parentId:a,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(s._valuesCache.hasOwnProperty(l))return s._valuesCache[l];const u=t.getColumn(l);if(u!=null&&u.accessorFn)return s._valuesCache[l]=u.accessorFn(s.original,n),s._valuesCache[l]},getUniqueValues:l=>{if(s._uniqueValuesCache.hasOwnProperty(l))return s._uniqueValuesCache[l];const u=t.getColumn(l);if(u!=null&&u.accessorFn)return u.columnDef.getUniqueValues?(s._uniqueValuesCache[l]=u.columnDef.getUniqueValues(s.original,n),s._uniqueValuesCache[l]):(s._uniqueValuesCache[l]=[s.getValue(l)],s._uniqueValuesCache[l])},renderValue:l=>{var u;return(u=s.getValue(l))!=null?u:t.options.renderFallbackValue},subRows:[],getLeafRows:()=>AIt(s.subRows,l=>l.subRows),getParentRow:()=>s.parentId?t.getRow(s.parentId,!0):void 0,getParentRows:()=>{let l=[],u=s;for(;;){const c=u.getParentRow();if(!c)break;l.push(c),u=c}return l.reverse()},getAllCells:gn(()=>[t.getAllLeafColumns()],l=>l.map(u=>OIt(t,s,u,u.id)),vn(t.options,"debugRows")),_getAllCellsByColumnId:gn(()=>[s.getAllCells()],l=>l.reduce((u,c)=>(u[c.column.id]=c,u),{}),vn(t.options,"debugRows"))};for(let l=0;l<t._features.length;l++){const u=t._features[l];u==null||u.createRow==null||u.createRow(s,t)}return s},LIt={createColumn:(t,e)=>{t._getFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,t.id),t.getFacetedRowModel=()=>t._getFacetedRowModel?t._getFacetedRowModel():e.getPreFilteredRowModel(),t._getFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,t.id),t.getFacetedUniqueValues=()=>t._getFacetedUniqueValues?t._getFacetedUniqueValues():new Map,t._getFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,t.id),t.getFacetedMinMaxValues=()=>{if(t._getFacetedMinMaxValues)return t._getFacetedMinMaxValues()}}},c4e=(t,e,i)=>{var n,r;const o=i==null||(n=i.toString())==null?void 0:n.toLowerCase();return!!(!((r=t.getValue(e))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(o))};c4e.autoRemove=t=>Iv(t);const d4e=(t,e,i)=>{var n;return!!(!((n=t.getValue(e))==null||(n=n.toString())==null)&&n.includes(i))};d4e.autoRemove=t=>Iv(t);const f4e=(t,e,i)=>{var n;return((n=t.getValue(e))==null||(n=n.toString())==null?void 0:n.toLowerCase())===(i==null?void 0:i.toLowerCase())};f4e.autoRemove=t=>Iv(t);const h4e=(t,e,i)=>{var n;return(n=t.getValue(e))==null?void 0:n.includes(i)};h4e.autoRemove=t=>Iv(t);const p4e=(t,e,i)=>!i.some(n=>{var r;return!((r=t.getValue(e))!=null&&r.includes(n))});p4e.autoRemove=t=>Iv(t)||!(t!=null&&t.length);const g4e=(t,e,i)=>i.some(n=>{var r;return(r=t.getValue(e))==null?void 0:r.includes(n)});g4e.autoRemove=t=>Iv(t)||!(t!=null&&t.length);const v4e=(t,e,i)=>t.getValue(e)===i;v4e.autoRemove=t=>Iv(t);const y4e=(t,e,i)=>t.getValue(e)==i;y4e.autoRemove=t=>Iv(t);const Nne=(t,e,i)=>{let[n,r]=i;const o=t.getValue(e);return o>=n&&o<=r};Nne.resolveFilterValue=t=>{let[e,i]=t,n=typeof e!="number"?parseFloat(e):e,r=typeof i!="number"?parseFloat(i):i,o=e===null||Number.isNaN(n)?-1/0:n,a=i===null||Number.isNaN(r)?1/0:r;if(o>a){const s=o;o=a,a=s}return[o,a]};Nne.autoRemove=t=>Iv(t)||Iv(t[0])&&Iv(t[1]);const Jb={includesString:c4e,includesStringSensitive:d4e,equalsString:f4e,arrIncludes:h4e,arrIncludesAll:p4e,arrIncludesSome:g4e,equals:v4e,weakEquals:y4e,inNumberRange:Nne};function Iv(t){return t==null||t===""}const kIt={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:t=>({columnFilters:[],...t}),getDefaultOptions:t=>({onColumnFiltersChange:Dp("columnFilters",t),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(t,e)=>{t.getAutoFilterFn=()=>{const i=e.getCoreRowModel().flatRows[0],n=i==null?void 0:i.getValue(t.id);return typeof n=="string"?Jb.includesString:typeof n=="number"?Jb.inNumberRange:typeof n=="boolean"||n!==null&&typeof n=="object"?Jb.equals:Array.isArray(n)?Jb.arrIncludes:Jb.weakEquals},t.getFilterFn=()=>{var i,n;return mG(t.columnDef.filterFn)?t.columnDef.filterFn:t.columnDef.filterFn==="auto"?t.getAutoFilterFn():(i=(n=e.options.filterFns)==null?void 0:n[t.columnDef.filterFn])!=null?i:Jb[t.columnDef.filterFn]},t.getCanFilter=()=>{var i,n,r;return((i=t.columnDef.enableColumnFilter)!=null?i:!0)&&((n=e.options.enableColumnFilters)!=null?n:!0)&&((r=e.options.enableFilters)!=null?r:!0)&&!!t.accessorFn},t.getIsFiltered=()=>t.getFilterIndex()>-1,t.getFilterValue=()=>{var i;return(i=e.getState().columnFilters)==null||(i=i.find(n=>n.id===t.id))==null?void 0:i.value},t.getFilterIndex=()=>{var i,n;return(i=(n=e.getState().columnFilters)==null?void 0:n.findIndex(r=>r.id===t.id))!=null?i:-1},t.setFilterValue=i=>{e.setColumnFilters(n=>{const r=t.getFilterFn(),o=n==null?void 0:n.find(c=>c.id===t.id),a=dP(i,o?o.value:void 0);if(zxe(r,a,t)){var s;return(s=n==null?void 0:n.filter(c=>c.id!==t.id))!=null?s:[]}const l={id:t.id,value:a};if(o){var u;return(u=n==null?void 0:n.map(c=>c.id===t.id?l:c))!=null?u:[]}return n!=null&&n.length?[...n,l]:[l]})}},createRow:(t,e)=>{t.columnFilters={},t.columnFiltersMeta={}},createTable:t=>{t.setColumnFilters=e=>{const i=t.getAllLeafColumns(),n=r=>{var o;return(o=dP(e,r))==null?void 0:o.filter(a=>{const s=i.find(l=>l.id===a.id);if(s){const l=s.getFilterFn();if(zxe(l,a.value,s))return!1}return!0})};t.options.onColumnFiltersChange==null||t.options.onColumnFiltersChange(n)},t.resetColumnFilters=e=>{var i,n;t.setColumnFilters(e?[]:(i=(n=t.initialState)==null?void 0:n.columnFilters)!=null?i:[])},t.getPreFilteredRowModel=()=>t.getCoreRowModel(),t.getFilteredRowModel=()=>(!t._getFilteredRowModel&&t.options.getFilteredRowModel&&(t._getFilteredRowModel=t.options.getFilteredRowModel(t)),t.options.manualFiltering||!t._getFilteredRowModel?t.getPreFilteredRowModel():t._getFilteredRowModel())}};function zxe(t,e,i){return(t&&t.autoRemove?t.autoRemove(e,i):!1)||typeof e>"u"||typeof e=="string"&&!e}const IIt=(t,e,i)=>i.reduce((n,r)=>{const o=r.getValue(t);return n+(typeof o=="number"?o:0)},0),NIt=(t,e,i)=>{let n;return i.forEach(r=>{const o=r.getValue(t);o!=null&&(n>o||n===void 0&&o>=o)&&(n=o)}),n},FIt=(t,e,i)=>{let n;return i.forEach(r=>{const o=r.getValue(t);o!=null&&(n<o||n===void 0&&o>=o)&&(n=o)}),n},BIt=(t,e,i)=>{let n,r;return i.forEach(o=>{const a=o.getValue(t);a!=null&&(n===void 0?a>=a&&(n=r=a):(n>a&&(n=a),r<a&&(r=a)))}),[n,r]},jIt=(t,e)=>{let i=0,n=0;if(e.forEach(r=>{let o=r.getValue(t);o!=null&&(o=+o)>=o&&(++i,n+=o)}),i)return n/i},VIt=(t,e)=>{if(!e.length)return;const i=e.map(o=>o.getValue(t));if(!wIt(i))return;if(i.length===1)return i[0];const n=Math.floor(i.length/2),r=i.sort((o,a)=>o-a);return i.length%2!==0?r[n]:(r[n-1]+r[n])/2},HIt=(t,e)=>Array.from(new Set(e.map(i=>i.getValue(t))).values()),UIt=(t,e)=>new Set(e.map(i=>i.getValue(t))).size,zIt=(t,e)=>e.length,X7={sum:IIt,min:NIt,max:FIt,extent:BIt,mean:jIt,median:VIt,unique:HIt,uniqueCount:UIt,count:zIt},$It={getDefaultColumnDef:()=>({aggregatedCell:t=>{var e,i;return(e=(i=t.getValue())==null||i.toString==null?void 0:i.toString())!=null?e:null},aggregationFn:"auto"}),getInitialState:t=>({grouping:[],...t}),getDefaultOptions:t=>({onGroupingChange:Dp("grouping",t),groupedColumnMode:"reorder"}),createColumn:(t,e)=>{t.toggleGrouping=()=>{e.setGrouping(i=>i!=null&&i.includes(t.id)?i.filter(n=>n!==t.id):[...i??[],t.id])},t.getCanGroup=()=>{var i,n;return((i=t.columnDef.enableGrouping)!=null?i:!0)&&((n=e.options.enableGrouping)!=null?n:!0)&&(!!t.accessorFn||!!t.columnDef.getGroupingValue)},t.getIsGrouped=()=>{var i;return(i=e.getState().grouping)==null?void 0:i.includes(t.id)},t.getGroupedIndex=()=>{var i;return(i=e.getState().grouping)==null?void 0:i.indexOf(t.id)},t.getToggleGroupingHandler=()=>{const i=t.getCanGroup();return()=>{i&&t.toggleGrouping()}},t.getAutoAggregationFn=()=>{const i=e.getCoreRowModel().flatRows[0],n=i==null?void 0:i.getValue(t.id);if(typeof n=="number")return X7.sum;if(Object.prototype.toString.call(n)==="[object Date]")return X7.extent},t.getAggregationFn=()=>{var i,n;if(!t)throw new Error;return mG(t.columnDef.aggregationFn)?t.columnDef.aggregationFn:t.columnDef.aggregationFn==="auto"?t.getAutoAggregationFn():(i=(n=e.options.aggregationFns)==null?void 0:n[t.columnDef.aggregationFn])!=null?i:X7[t.columnDef.aggregationFn]}},createTable:t=>{t.setGrouping=e=>t.options.onGroupingChange==null?void 0:t.options.onGroupingChange(e),t.resetGrouping=e=>{var i,n;t.setGrouping(e?[]:(i=(n=t.initialState)==null?void 0:n.grouping)!=null?i:[])},t.getPreGroupedRowModel=()=>t.getFilteredRowModel(),t.getGroupedRowModel=()=>(!t._getGroupedRowModel&&t.options.getGroupedRowModel&&(t._getGroupedRowModel=t.options.getGroupedRowModel(t)),t.options.manualGrouping||!t._getGroupedRowModel?t.getPreGroupedRowModel():t._getGroupedRowModel())},createRow:(t,e)=>{t.getIsGrouped=()=>!!t.groupingColumnId,t.getGroupingValue=i=>{if(t._groupingValuesCache.hasOwnProperty(i))return t._groupingValuesCache[i];const n=e.getColumn(i);return n!=null&&n.columnDef.getGroupingValue?(t._groupingValuesCache[i]=n.columnDef.getGroupingValue(t.original),t._groupingValuesCache[i]):t.getValue(i)},t._groupingValuesCache={}},createCell:(t,e,i,n)=>{t.getIsGrouped=()=>e.getIsGrouped()&&e.id===i.groupingColumnId,t.getIsPlaceholder=()=>!t.getIsGrouped()&&e.getIsGrouped(),t.getIsAggregated=()=>{var r;return!t.getIsGrouped()&&!t.getIsPlaceholder()&&!!((r=i.subRows)!=null&&r.length)}}};function WIt(t,e,i){if(!(e!=null&&e.length)||!i)return t;const n=t.filter(o=>!e.includes(o.id));return i==="remove"?n:[...e.map(o=>t.find(a=>a.id===o)).filter(Boolean),...n]}const GIt={getInitialState:t=>({columnOrder:[],...t}),getDefaultOptions:t=>({onColumnOrderChange:Dp("columnOrder",t)}),createColumn:(t,e)=>{t.getIndex=gn(i=>[jj(e,i)],i=>i.findIndex(n=>n.id===t.id),vn(e.options,"debugColumns")),t.getIsFirstColumn=i=>{var n;return((n=jj(e,i)[0])==null?void 0:n.id)===t.id},t.getIsLastColumn=i=>{var n;const r=jj(e,i);return((n=r[r.length-1])==null?void 0:n.id)===t.id}},createTable:t=>{t.setColumnOrder=e=>t.options.onColumnOrderChange==null?void 0:t.options.onColumnOrderChange(e),t.resetColumnOrder=e=>{var i;t.setColumnOrder(e?[]:(i=t.initialState.columnOrder)!=null?i:[])},t._getOrderColumnsFn=gn(()=>[t.getState().columnOrder,t.getState().grouping,t.options.groupedColumnMode],(e,i,n)=>r=>{let o=[];if(!(e!=null&&e.length))o=r;else{const a=[...e],s=[...r];for(;s.length&&a.length;){const l=a.shift(),u=s.findIndex(c=>c.id===l);u>-1&&o.push(s.splice(u,1)[0])}o=[...o,...s]}return WIt(o,i,n)},vn(t.options,"debugTable"))}},K7=()=>({left:[],right:[]}),YIt={getInitialState:t=>({columnPinning:K7(),...t}),getDefaultOptions:t=>({onColumnPinningChange:Dp("columnPinning",t)}),createColumn:(t,e)=>{t.pin=i=>{const n=t.getLeafColumns().map(r=>r.id).filter(Boolean);e.setColumnPinning(r=>{var o,a;if(i==="right"){var s,l;return{left:((s=r==null?void 0:r.left)!=null?s:[]).filter(d=>!(n!=null&&n.includes(d))),right:[...((l=r==null?void 0:r.right)!=null?l:[]).filter(d=>!(n!=null&&n.includes(d))),...n]}}if(i==="left"){var u,c;return{left:[...((u=r==null?void 0:r.left)!=null?u:[]).filter(d=>!(n!=null&&n.includes(d))),...n],right:((c=r==null?void 0:r.right)!=null?c:[]).filter(d=>!(n!=null&&n.includes(d)))}}return{left:((o=r==null?void 0:r.left)!=null?o:[]).filter(d=>!(n!=null&&n.includes(d))),right:((a=r==null?void 0:r.right)!=null?a:[]).filter(d=>!(n!=null&&n.includes(d)))}})},t.getCanPin=()=>t.getLeafColumns().some(n=>{var r,o,a;return((r=n.columnDef.enablePinning)!=null?r:!0)&&((o=(a=e.options.enableColumnPinning)!=null?a:e.options.enablePinning)!=null?o:!0)}),t.getIsPinned=()=>{const i=t.getLeafColumns().map(s=>s.id),{left:n,right:r}=e.getState().columnPinning,o=i.some(s=>n==null?void 0:n.includes(s)),a=i.some(s=>r==null?void 0:r.includes(s));return o?"left":a?"right":!1},t.getPinnedIndex=()=>{var i,n;const r=t.getIsPinned();return r?(i=(n=e.getState().columnPinning)==null||(n=n[r])==null?void 0:n.indexOf(t.id))!=null?i:-1:0}},createRow:(t,e)=>{t.getCenterVisibleCells=gn(()=>[t._getAllVisibleCells(),e.getState().columnPinning.left,e.getState().columnPinning.right],(i,n,r)=>{const o=[...n??[],...r??[]];return i.filter(a=>!o.includes(a.column.id))},vn(e.options,"debugRows")),t.getLeftVisibleCells=gn(()=>[t._getAllVisibleCells(),e.getState().columnPinning.left],(i,n)=>(n??[]).map(o=>i.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"left"})),vn(e.options,"debugRows")),t.getRightVisibleCells=gn(()=>[t._getAllVisibleCells(),e.getState().columnPinning.right],(i,n)=>(n??[]).map(o=>i.find(a=>a.column.id===o)).filter(Boolean).map(o=>({...o,position:"right"})),vn(e.options,"debugRows"))},createTable:t=>{t.setColumnPinning=e=>t.options.onColumnPinningChange==null?void 0:t.options.onColumnPinningChange(e),t.resetColumnPinning=e=>{var i,n;return t.setColumnPinning(e?K7():(i=(n=t.initialState)==null?void 0:n.columnPinning)!=null?i:K7())},t.getIsSomeColumnsPinned=e=>{var i;const n=t.getState().columnPinning;if(!e){var r,o;return!!((r=n.left)!=null&&r.length||(o=n.right)!=null&&o.length)}return!!((i=n[e])!=null&&i.length)},t.getLeftLeafColumns=gn(()=>[t.getAllLeafColumns(),t.getState().columnPinning.left],(e,i)=>(i??[]).map(n=>e.find(r=>r.id===n)).filter(Boolean),vn(t.options,"debugColumns")),t.getRightLeafColumns=gn(()=>[t.getAllLeafColumns(),t.getState().columnPinning.right],(e,i)=>(i??[]).map(n=>e.find(r=>r.id===n)).filter(Boolean),vn(t.options,"debugColumns")),t.getCenterLeafColumns=gn(()=>[t.getAllLeafColumns(),t.getState().columnPinning.left,t.getState().columnPinning.right],(e,i,n)=>{const r=[...i??[],...n??[]];return e.filter(o=>!r.includes(o.id))},vn(t.options,"debugColumns"))}};function qIt(t){return t||(typeof document<"u"?document:null)}const CU={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},Z7=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),XIt={getDefaultColumnDef:()=>CU,getInitialState:t=>({columnSizing:{},columnSizingInfo:Z7(),...t}),getDefaultOptions:t=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:Dp("columnSizing",t),onColumnSizingInfoChange:Dp("columnSizingInfo",t)}),createColumn:(t,e)=>{t.getSize=()=>{var i,n,r;const o=e.getState().columnSizing[t.id];return Math.min(Math.max((i=t.columnDef.minSize)!=null?i:CU.minSize,(n=o??t.columnDef.size)!=null?n:CU.size),(r=t.columnDef.maxSize)!=null?r:CU.maxSize)},t.getStart=gn(i=>[i,jj(e,i),e.getState().columnSizing],(i,n)=>n.slice(0,t.getIndex(i)).reduce((r,o)=>r+o.getSize(),0),vn(e.options,"debugColumns")),t.getAfter=gn(i=>[i,jj(e,i),e.getState().columnSizing],(i,n)=>n.slice(t.getIndex(i)+1).reduce((r,o)=>r+o.getSize(),0),vn(e.options,"debugColumns")),t.resetSize=()=>{e.setColumnSizing(i=>{let{[t.id]:n,...r}=i;return r})},t.getCanResize=()=>{var i,n;return((i=t.columnDef.enableResizing)!=null?i:!0)&&((n=e.options.enableColumnResizing)!=null?n:!0)},t.getIsResizing=()=>e.getState().columnSizingInfo.isResizingColumn===t.id},createHeader:(t,e)=>{t.getSize=()=>{let i=0;const n=r=>{if(r.subHeaders.length)r.subHeaders.forEach(n);else{var o;i+=(o=r.column.getSize())!=null?o:0}};return n(t),i},t.getStart=()=>{if(t.index>0){const i=t.headerGroup.headers[t.index-1];return i.getStart()+i.getSize()}return 0},t.getResizeHandler=i=>{const n=e.getColumn(t.column.id),r=n==null?void 0:n.getCanResize();return o=>{if(!n||!r||(o.persist==null||o.persist(),J7(o)&&o.touches&&o.touches.length>1))return;const a=t.getSize(),s=t?t.getLeafHeaders().map(y=>[y.column.id,y.column.getSize()]):[[n.id,n.getSize()]],l=J7(o)?Math.round(o.touches[0].clientX):o.clientX,u={},c=(y,m)=>{typeof m=="number"&&(e.setColumnSizingInfo(b=>{var S,_;const C=e.options.columnResizeDirection==="rtl"?-1:1,P=(m-((S=b==null?void 0:b.startOffset)!=null?S:0))*C,x=Math.max(P/((_=b==null?void 0:b.startSize)!=null?_:0),-.999999);return b.columnSizingStart.forEach(E=>{let[A,R]=E;u[A]=Math.round(Math.max(R+R*x,0)*100)/100}),{...b,deltaOffset:P,deltaPercentage:x}}),(e.options.columnResizeMode==="onChange"||y==="end")&&e.setColumnSizing(b=>({...b,...u})))},d=y=>c("move",y),f=y=>{c("end",y),e.setColumnSizingInfo(m=>({...m,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},h=qIt(i),p={moveHandler:y=>d(y.clientX),upHandler:y=>{h==null||h.removeEventListener("mousemove",p.moveHandler),h==null||h.removeEventListener("mouseup",p.upHandler),f(y.clientX)}},g={moveHandler:y=>(y.cancelable&&(y.preventDefault(),y.stopPropagation()),d(y.touches[0].clientX),!1),upHandler:y=>{var m;h==null||h.removeEventListener("touchmove",g.moveHandler),h==null||h.removeEventListener("touchend",g.upHandler),y.cancelable&&(y.preventDefault(),y.stopPropagation()),f((m=y.touches[0])==null?void 0:m.clientX)}},v=KIt()?{passive:!1}:!1;J7(o)?(h==null||h.addEventListener("touchmove",g.moveHandler,v),h==null||h.addEventListener("touchend",g.upHandler,v)):(h==null||h.addEventListener("mousemove",p.moveHandler,v),h==null||h.addEventListener("mouseup",p.upHandler,v)),e.setColumnSizingInfo(y=>({...y,startOffset:l,startSize:a,deltaOffset:0,deltaPercentage:0,columnSizingStart:s,isResizingColumn:n.id}))}}},createTable:t=>{t.setColumnSizing=e=>t.options.onColumnSizingChange==null?void 0:t.options.onColumnSizingChange(e),t.setColumnSizingInfo=e=>t.options.onColumnSizingInfoChange==null?void 0:t.options.onColumnSizingInfoChange(e),t.resetColumnSizing=e=>{var i;t.setColumnSizing(e?{}:(i=t.initialState.columnSizing)!=null?i:{})},t.resetHeaderSizeInfo=e=>{var i;t.setColumnSizingInfo(e?Z7():(i=t.initialState.columnSizingInfo)!=null?i:Z7())},t.getTotalSize=()=>{var e,i;return(e=(i=t.getHeaderGroups()[0])==null?void 0:i.headers.reduce((n,r)=>n+r.getSize(),0))!=null?e:0},t.getLeftTotalSize=()=>{var e,i;return(e=(i=t.getLeftHeaderGroups()[0])==null?void 0:i.headers.reduce((n,r)=>n+r.getSize(),0))!=null?e:0},t.getCenterTotalSize=()=>{var e,i;return(e=(i=t.getCenterHeaderGroups()[0])==null?void 0:i.headers.reduce((n,r)=>n+r.getSize(),0))!=null?e:0},t.getRightTotalSize=()=>{var e,i;return(e=(i=t.getRightHeaderGroups()[0])==null?void 0:i.headers.reduce((n,r)=>n+r.getSize(),0))!=null?e:0}}};let TU=null;function KIt(){if(typeof TU=="boolean")return TU;let t=!1;try{const e={get passive(){return t=!0,!1}},i=()=>{};window.addEventListener("test",i,e),window.removeEventListener("test",i)}catch{t=!1}return TU=t,TU}function J7(t){return t.type==="touchstart"}const ZIt={getInitialState:t=>({columnVisibility:{},...t}),getDefaultOptions:t=>({onColumnVisibilityChange:Dp("columnVisibility",t)}),createColumn:(t,e)=>{t.toggleVisibility=i=>{t.getCanHide()&&e.setColumnVisibility(n=>({...n,[t.id]:i??!t.getIsVisible()}))},t.getIsVisible=()=>{var i,n;const r=t.columns;return(i=r.length?r.some(o=>o.getIsVisible()):(n=e.getState().columnVisibility)==null?void 0:n[t.id])!=null?i:!0},t.getCanHide=()=>{var i,n;return((i=t.columnDef.enableHiding)!=null?i:!0)&&((n=e.options.enableHiding)!=null?n:!0)},t.getToggleVisibilityHandler=()=>i=>{t.toggleVisibility==null||t.toggleVisibility(i.target.checked)}},createRow:(t,e)=>{t._getAllVisibleCells=gn(()=>[t.getAllCells(),e.getState().columnVisibility],i=>i.filter(n=>n.column.getIsVisible()),vn(e.options,"debugRows")),t.getVisibleCells=gn(()=>[t.getLeftVisibleCells(),t.getCenterVisibleCells(),t.getRightVisibleCells()],(i,n,r)=>[...i,...n,...r],vn(e.options,"debugRows"))},createTable:t=>{const e=(i,n)=>gn(()=>[n(),n().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(o=>o.getIsVisible==null?void 0:o.getIsVisible()),vn(t.options,"debugColumns"));t.getVisibleFlatColumns=e("getVisibleFlatColumns",()=>t.getAllFlatColumns()),t.getVisibleLeafColumns=e("getVisibleLeafColumns",()=>t.getAllLeafColumns()),t.getLeftVisibleLeafColumns=e("getLeftVisibleLeafColumns",()=>t.getLeftLeafColumns()),t.getRightVisibleLeafColumns=e("getRightVisibleLeafColumns",()=>t.getRightLeafColumns()),t.getCenterVisibleLeafColumns=e("getCenterVisibleLeafColumns",()=>t.getCenterLeafColumns()),t.setColumnVisibility=i=>t.options.onColumnVisibilityChange==null?void 0:t.options.onColumnVisibilityChange(i),t.resetColumnVisibility=i=>{var n;t.setColumnVisibility(i?{}:(n=t.initialState.columnVisibility)!=null?n:{})},t.toggleAllColumnsVisible=i=>{var n;i=(n=i)!=null?n:!t.getIsAllColumnsVisible(),t.setColumnVisibility(t.getAllLeafColumns().reduce((r,o)=>({...r,[o.id]:i||!(o.getCanHide!=null&&o.getCanHide())}),{}))},t.getIsAllColumnsVisible=()=>!t.getAllLeafColumns().some(i=>!(i.getIsVisible!=null&&i.getIsVisible())),t.getIsSomeColumnsVisible=()=>t.getAllLeafColumns().some(i=>i.getIsVisible==null?void 0:i.getIsVisible()),t.getToggleAllColumnsVisibilityHandler=()=>i=>{var n;t.toggleAllColumnsVisible((n=i.target)==null?void 0:n.checked)}}};function jj(t,e){return e?e==="center"?t.getCenterVisibleLeafColumns():e==="left"?t.getLeftVisibleLeafColumns():t.getRightVisibleLeafColumns():t.getVisibleLeafColumns()}const JIt={createTable:t=>{t._getGlobalFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,"__global__"),t.getGlobalFacetedRowModel=()=>t.options.manualFiltering||!t._getGlobalFacetedRowModel?t.getPreFilteredRowModel():t._getGlobalFacetedRowModel(),t._getGlobalFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,"__global__"),t.getGlobalFacetedUniqueValues=()=>t._getGlobalFacetedUniqueValues?t._getGlobalFacetedUniqueValues():new Map,t._getGlobalFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,"__global__"),t.getGlobalFacetedMinMaxValues=()=>{if(t._getGlobalFacetedMinMaxValues)return t._getGlobalFacetedMinMaxValues()}}},QIt={getInitialState:t=>({globalFilter:void 0,...t}),getDefaultOptions:t=>({onGlobalFilterChange:Dp("globalFilter",t),globalFilterFn:"auto",getColumnCanGlobalFilter:e=>{var i;const n=(i=t.getCoreRowModel().flatRows[0])==null||(i=i._getAllCellsByColumnId()[e.id])==null?void 0:i.getValue();return typeof n=="string"||typeof n=="number"}}),createColumn:(t,e)=>{t.getCanGlobalFilter=()=>{var i,n,r,o;return((i=t.columnDef.enableGlobalFilter)!=null?i:!0)&&((n=e.options.enableGlobalFilter)!=null?n:!0)&&((r=e.options.enableFilters)!=null?r:!0)&&((o=e.options.getColumnCanGlobalFilter==null?void 0:e.options.getColumnCanGlobalFilter(t))!=null?o:!0)&&!!t.accessorFn}},createTable:t=>{t.getGlobalAutoFilterFn=()=>Jb.includesString,t.getGlobalFilterFn=()=>{var e,i;const{globalFilterFn:n}=t.options;return mG(n)?n:n==="auto"?t.getGlobalAutoFilterFn():(e=(i=t.options.filterFns)==null?void 0:i[n])!=null?e:Jb[n]},t.setGlobalFilter=e=>{t.options.onGlobalFilterChange==null||t.options.onGlobalFilterChange(e)},t.resetGlobalFilter=e=>{t.setGlobalFilter(e?void 0:t.initialState.globalFilter)}}},e2t={getInitialState:t=>({expanded:{},...t}),getDefaultOptions:t=>({onExpandedChange:Dp("expanded",t),paginateExpandedRows:!0}),createTable:t=>{let e=!1,i=!1;t._autoResetExpanded=()=>{var n,r;if(!e){t._queue(()=>{e=!0});return}if((n=(r=t.options.autoResetAll)!=null?r:t.options.autoResetExpanded)!=null?n:!t.options.manualExpanding){if(i)return;i=!0,t._queue(()=>{t.resetExpanded(),i=!1})}},t.setExpanded=n=>t.options.onExpandedChange==null?void 0:t.options.onExpandedChange(n),t.toggleAllRowsExpanded=n=>{n??!t.getIsAllRowsExpanded()?t.setExpanded(!0):t.setExpanded({})},t.resetExpanded=n=>{var r,o;t.setExpanded(n?{}:(r=(o=t.initialState)==null?void 0:o.expanded)!=null?r:{})},t.getCanSomeRowsExpand=()=>t.getPrePaginationRowModel().flatRows.some(n=>n.getCanExpand()),t.getToggleAllRowsExpandedHandler=()=>n=>{n.persist==null||n.persist(),t.toggleAllRowsExpanded()},t.getIsSomeRowsExpanded=()=>{const n=t.getState().expanded;return n===!0||Object.values(n).some(Boolean)},t.getIsAllRowsExpanded=()=>{const n=t.getState().expanded;return typeof n=="boolean"?n===!0:!(!Object.keys(n).length||t.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},t.getExpandedDepth=()=>{let n=0;return(t.getState().expanded===!0?Object.keys(t.getRowModel().rowsById):Object.keys(t.getState().expanded)).forEach(o=>{const a=o.split(".");n=Math.max(n,a.length)}),n},t.getPreExpandedRowModel=()=>t.getSortedRowModel(),t.getExpandedRowModel=()=>(!t._getExpandedRowModel&&t.options.getExpandedRowModel&&(t._getExpandedRowModel=t.options.getExpandedRowModel(t)),t.options.manualExpanding||!t._getExpandedRowModel?t.getPreExpandedRowModel():t._getExpandedRowModel())},createRow:(t,e)=>{t.toggleExpanded=i=>{e.setExpanded(n=>{var r;const o=n===!0?!0:!!(n!=null&&n[t.id]);let a={};if(n===!0?Object.keys(e.getRowModel().rowsById).forEach(s=>{a[s]=!0}):a=n,i=(r=i)!=null?r:!o,!o&&i)return{...a,[t.id]:!0};if(o&&!i){const{[t.id]:s,...l}=a;return l}return n})},t.getIsExpanded=()=>{var i;const n=e.getState().expanded;return!!((i=e.options.getIsRowExpanded==null?void 0:e.options.getIsRowExpanded(t))!=null?i:n===!0||n!=null&&n[t.id])},t.getCanExpand=()=>{var i,n,r;return(i=e.options.getRowCanExpand==null?void 0:e.options.getRowCanExpand(t))!=null?i:((n=e.options.enableExpanding)!=null?n:!0)&&!!((r=t.subRows)!=null&&r.length)},t.getIsAllParentsExpanded=()=>{let i=!0,n=t;for(;i&&n.parentId;)n=e.getRow(n.parentId,!0),i=n.getIsExpanded();return i},t.getToggleExpandedHandler=()=>{const i=t.getCanExpand();return()=>{i&&t.toggleExpanded()}}}},OJ=0,DJ=10,Q7=()=>({pageIndex:OJ,pageSize:DJ}),t2t={getInitialState:t=>({...t,pagination:{...Q7(),...t==null?void 0:t.pagination}}),getDefaultOptions:t=>({onPaginationChange:Dp("pagination",t)}),createTable:t=>{let e=!1,i=!1;t._autoResetPageIndex=()=>{var n,r;if(!e){t._queue(()=>{e=!0});return}if((n=(r=t.options.autoResetAll)!=null?r:t.options.autoResetPageIndex)!=null?n:!t.options.manualPagination){if(i)return;i=!0,t._queue(()=>{t.resetPageIndex(),i=!1})}},t.setPagination=n=>{const r=o=>dP(n,o);return t.options.onPaginationChange==null?void 0:t.options.onPaginationChange(r)},t.resetPagination=n=>{var r;t.setPagination(n?Q7():(r=t.initialState.pagination)!=null?r:Q7())},t.setPageIndex=n=>{t.setPagination(r=>{let o=dP(n,r.pageIndex);const a=typeof t.options.pageCount>"u"||t.options.pageCount===-1?Number.MAX_SAFE_INTEGER:t.options.pageCount-1;return o=Math.max(0,Math.min(o,a)),{...r,pageIndex:o}})},t.resetPageIndex=n=>{var r,o;t.setPageIndex(n?OJ:(r=(o=t.initialState)==null||(o=o.pagination)==null?void 0:o.pageIndex)!=null?r:OJ)},t.resetPageSize=n=>{var r,o;t.setPageSize(n?DJ:(r=(o=t.initialState)==null||(o=o.pagination)==null?void 0:o.pageSize)!=null?r:DJ)},t.setPageSize=n=>{t.setPagination(r=>{const o=Math.max(1,dP(n,r.pageSize)),a=r.pageSize*r.pageIndex,s=Math.floor(a/o);return{...r,pageIndex:s,pageSize:o}})},t.setPageCount=n=>t.setPagination(r=>{var o;let a=dP(n,(o=t.options.pageCount)!=null?o:-1);return typeof a=="number"&&(a=Math.max(-1,a)),{...r,pageCount:a}}),t.getPageOptions=gn(()=>[t.getPageCount()],n=>{let r=[];return n&&n>0&&(r=[...new Array(n)].fill(null).map((o,a)=>a)),r},vn(t.options,"debugTable")),t.getCanPreviousPage=()=>t.getState().pagination.pageIndex>0,t.getCanNextPage=()=>{const{pageIndex:n}=t.getState().pagination,r=t.getPageCount();return r===-1?!0:r===0?!1:n<r-1},t.previousPage=()=>t.setPageIndex(n=>n-1),t.nextPage=()=>t.setPageIndex(n=>n+1),t.firstPage=()=>t.setPageIndex(0),t.lastPage=()=>t.setPageIndex(t.getPageCount()-1),t.getPrePaginationRowModel=()=>t.getExpandedRowModel(),t.getPaginationRowModel=()=>(!t._getPaginationRowModel&&t.options.getPaginationRowModel&&(t._getPaginationRowModel=t.options.getPaginationRowModel(t)),t.options.manualPagination||!t._getPaginationRowModel?t.getPrePaginationRowModel():t._getPaginationRowModel()),t.getPageCount=()=>{var n;return(n=t.options.pageCount)!=null?n:Math.ceil(t.getRowCount()/t.getState().pagination.pageSize)},t.getRowCount=()=>{var n;return(n=t.options.rowCount)!=null?n:t.getPrePaginationRowModel().rows.length}}},eX=()=>({top:[],bottom:[]}),r2t={getInitialState:t=>({rowPinning:eX(),...t}),getDefaultOptions:t=>({onRowPinningChange:Dp("rowPinning",t)}),createRow:(t,e)=>{t.pin=(i,n,r)=>{const o=n?t.getLeafRows().map(l=>{let{id:u}=l;return u}):[],a=r?t.getParentRows().map(l=>{let{id:u}=l;return u}):[],s=new Set([...a,t.id,...o]);e.setRowPinning(l=>{var u,c;if(i==="bottom"){var d,f;return{top:((d=l==null?void 0:l.top)!=null?d:[]).filter(g=>!(s!=null&&s.has(g))),bottom:[...((f=l==null?void 0:l.bottom)!=null?f:[]).filter(g=>!(s!=null&&s.has(g))),...Array.from(s)]}}if(i==="top"){var h,p;return{top:[...((h=l==null?void 0:l.top)!=null?h:[]).filter(g=>!(s!=null&&s.has(g))),...Array.from(s)],bottom:((p=l==null?void 0:l.bottom)!=null?p:[]).filter(g=>!(s!=null&&s.has(g)))}}return{top:((u=l==null?void 0:l.top)!=null?u:[]).filter(g=>!(s!=null&&s.has(g))),bottom:((c=l==null?void 0:l.bottom)!=null?c:[]).filter(g=>!(s!=null&&s.has(g)))}})},t.getCanPin=()=>{var i;const{enableRowPinning:n,enablePinning:r}=e.options;return typeof n=="function"?n(t):(i=n??r)!=null?i:!0},t.getIsPinned=()=>{const i=[t.id],{top:n,bottom:r}=e.getState().rowPinning,o=i.some(s=>n==null?void 0:n.includes(s)),a=i.some(s=>r==null?void 0:r.includes(s));return o?"top":a?"bottom":!1},t.getPinnedIndex=()=>{var i,n;const r=t.getIsPinned();if(!r)return-1;const o=(i=r==="top"?e.getTopRows():e.getBottomRows())==null?void 0:i.map(a=>{let{id:s}=a;return s});return(n=o==null?void 0:o.indexOf(t.id))!=null?n:-1}},createTable:t=>{t.setRowPinning=e=>t.options.onRowPinningChange==null?void 0:t.options.onRowPinningChange(e),t.resetRowPinning=e=>{var i,n;return t.setRowPinning(e?eX():(i=(n=t.initialState)==null?void 0:n.rowPinning)!=null?i:eX())},t.getIsSomeRowsPinned=e=>{var i;const n=t.getState().rowPinning;if(!e){var r,o;return!!((r=n.top)!=null&&r.length||(o=n.bottom)!=null&&o.length)}return!!((i=n[e])!=null&&i.length)},t._getPinnedRows=(e,i,n)=>{var r;return((r=t.options.keepPinnedRows)==null||r?(i??[]).map(a=>{const s=t.getRow(a,!0);return s.getIsAllParentsExpanded()?s:null}):(i??[]).map(a=>e.find(s=>s.id===a))).filter(Boolean).map(a=>({...a,position:n}))},t.getTopRows=gn(()=>[t.getRowModel().rows,t.getState().rowPinning.top],(e,i)=>t._getPinnedRows(e,i,"top"),vn(t.options,"debugRows")),t.getBottomRows=gn(()=>[t.getRowModel().rows,t.getState().rowPinning.bottom],(e,i)=>t._getPinnedRows(e,i,"bottom"),vn(t.options,"debugRows")),t.getCenterRows=gn(()=>[t.getRowModel().rows,t.getState().rowPinning.top,t.getState().rowPinning.bottom],(e,i,n)=>{const r=new Set([...i??[],...n??[]]);return e.filter(o=>!r.has(o.id))},vn(t.options,"debugRows"))}},i2t={getInitialState:t=>({rowSelection:{},...t}),getDefaultOptions:t=>({onRowSelectionChange:Dp("rowSelection",t),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:t=>{t.setRowSelection=e=>t.options.onRowSelectionChange==null?void 0:t.options.onRowSelectionChange(e),t.resetRowSelection=e=>{var i;return t.setRowSelection(e?{}:(i=t.initialState.rowSelection)!=null?i:{})},t.toggleAllRowsSelected=e=>{t.setRowSelection(i=>{e=typeof e<"u"?e:!t.getIsAllRowsSelected();const n={...i},r=t.getPreGroupedRowModel().flatRows;return e?r.forEach(o=>{o.getCanSelect()&&(n[o.id]=!0)}):r.forEach(o=>{delete n[o.id]}),n})},t.toggleAllPageRowsSelected=e=>t.setRowSelection(i=>{const n=typeof e<"u"?e:!t.getIsAllPageRowsSelected(),r={...i};return t.getRowModel().rows.forEach(o=>{RJ(r,o.id,n,!0,t)}),r}),t.getPreSelectedRowModel=()=>t.getCoreRowModel(),t.getSelectedRowModel=gn(()=>[t.getState().rowSelection,t.getCoreRowModel()],(e,i)=>Object.keys(e).length?tX(t,i):{rows:[],flatRows:[],rowsById:{}},vn(t.options,"debugTable")),t.getFilteredSelectedRowModel=gn(()=>[t.getState().rowSelection,t.getFilteredRowModel()],(e,i)=>Object.keys(e).length?tX(t,i):{rows:[],flatRows:[],rowsById:{}},vn(t.options,"debugTable")),t.getGroupedSelectedRowModel=gn(()=>[t.getState().rowSelection,t.getSortedRowModel()],(e,i)=>Object.keys(e).length?tX(t,i):{rows:[],flatRows:[],rowsById:{}},vn(t.options,"debugTable")),t.getIsAllRowsSelected=()=>{const e=t.getFilteredRowModel().flatRows,{rowSelection:i}=t.getState();let n=!!(e.length&&Object.keys(i).length);return n&&e.some(r=>r.getCanSelect()&&!i[r.id])&&(n=!1),n},t.getIsAllPageRowsSelected=()=>{const e=t.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:i}=t.getState();let n=!!e.length;return n&&e.some(r=>!i[r.id])&&(n=!1),n},t.getIsSomeRowsSelected=()=>{var e;const i=Object.keys((e=t.getState().rowSelection)!=null?e:{}).length;return i>0&&i<t.getFilteredRowModel().flatRows.length},t.getIsSomePageRowsSelected=()=>{const e=t.getPaginationRowModel().flatRows;return t.getIsAllPageRowsSelected()?!1:e.filter(i=>i.getCanSelect()).some(i=>i.getIsSelected()||i.getIsSomeSelected())},t.getToggleAllRowsSelectedHandler=()=>e=>{t.toggleAllRowsSelected(e.target.checked)},t.getToggleAllPageRowsSelectedHandler=()=>e=>{t.toggleAllPageRowsSelected(e.target.checked)}},createRow:(t,e)=>{t.toggleSelected=(i,n)=>{const r=t.getIsSelected();e.setRowSelection(o=>{var a;if(i=typeof i<"u"?i:!r,t.getCanSelect()&&r===i)return o;const s={...o};return RJ(s,t.id,i,(a=n==null?void 0:n.selectChildren)!=null?a:!0,e),s})},t.getIsSelected=()=>{const{rowSelection:i}=e.getState();return Fne(t,i)},t.getIsSomeSelected=()=>{const{rowSelection:i}=e.getState();return MJ(t,i)==="some"},t.getIsAllSubRowsSelected=()=>{const{rowSelection:i}=e.getState();return MJ(t,i)==="all"},t.getCanSelect=()=>{var i;return typeof e.options.enableRowSelection=="function"?e.options.enableRowSelection(t):(i=e.options.enableRowSelection)!=null?i:!0},t.getCanSelectSubRows=()=>{var i;return typeof e.options.enableSubRowSelection=="function"?e.options.enableSubRowSelection(t):(i=e.options.enableSubRowSelection)!=null?i:!0},t.getCanMultiSelect=()=>{var i;return typeof e.options.enableMultiRowSelection=="function"?e.options.enableMultiRowSelection(t):(i=e.options.enableMultiRowSelection)!=null?i:!0},t.getToggleSelectedHandler=()=>{const i=t.getCanSelect();return n=>{var r;i&&t.toggleSelected((r=n.target)==null?void 0:r.checked)}}}},RJ=(t,e,i,n,r)=>{var o;const a=r.getRow(e,!0);i?(a.getCanMultiSelect()||Object.keys(t).forEach(s=>delete t[s]),a.getCanSelect()&&(t[e]=!0)):delete t[e],n&&(o=a.subRows)!=null&&o.length&&a.getCanSelectSubRows()&&a.subRows.forEach(s=>RJ(t,s.id,i,n,r))};function tX(t,e){const i=t.getState().rowSelection,n=[],r={},o=function(a,s){return a.map(l=>{var u;const c=Fne(l,i);if(c&&(n.push(l),r[l.id]=l),(u=l.subRows)!=null&&u.length&&(l={...l,subRows:o(l.subRows)}),c)return l}).filter(Boolean)};return{rows:o(e.rows),flatRows:n,rowsById:r}}function Fne(t,e){var i;return(i=e[t.id])!=null?i:!1}function MJ(t,e,i){var n;if(!((n=t.subRows)!=null&&n.length))return!1;let r=!0,o=!1;return t.subRows.forEach(a=>{if(!(o&&!r)&&(a.getCanSelect()&&(Fne(a,e)?o=!0:r=!1),a.subRows&&a.subRows.length)){const s=MJ(a,e);s==="all"?o=!0:(s==="some"&&(o=!0),r=!1)}}),r?"all":o?"some":!1}const LJ=/([0-9]+)/gm,n2t=(t,e,i)=>m4e(RP(t.getValue(i)).toLowerCase(),RP(e.getValue(i)).toLowerCase()),o2t=(t,e,i)=>m4e(RP(t.getValue(i)),RP(e.getValue(i))),a2t=(t,e,i)=>Bne(RP(t.getValue(i)).toLowerCase(),RP(e.getValue(i)).toLowerCase()),s2t=(t,e,i)=>Bne(RP(t.getValue(i)),RP(e.getValue(i))),l2t=(t,e,i)=>{const n=t.getValue(i),r=e.getValue(i);return n>r?1:n<r?-1:0},u2t=(t,e,i)=>Bne(t.getValue(i),e.getValue(i));function Bne(t,e){return t===e?0:t>e?1:-1}function RP(t){return typeof t=="number"?isNaN(t)||t===1/0||t===-1/0?"":String(t):typeof t=="string"?t:""}function m4e(t,e){const i=t.split(LJ).filter(Boolean),n=e.split(LJ).filter(Boolean);for(;i.length&&n.length;){const r=i.shift(),o=n.shift(),a=parseInt(r,10),s=parseInt(o,10),l=[a,s].sort();if(isNaN(l[0])){if(r>o)return 1;if(o>r)return-1;continue}if(isNaN(l[1]))return isNaN(a)?-1:1;if(a>s)return 1;if(s>a)return-1}return i.length-n.length}const tj={alphanumeric:n2t,alphanumericCaseSensitive:o2t,text:a2t,textCaseSensitive:s2t,datetime:l2t,basic:u2t},c2t={getInitialState:t=>({sorting:[],...t}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:t=>({onSortingChange:Dp("sorting",t),isMultiSortEvent:e=>e.shiftKey}),createColumn:(t,e)=>{t.getAutoSortingFn=()=>{const i=e.getFilteredRowModel().flatRows.slice(10);let n=!1;for(const r of i){const o=r==null?void 0:r.getValue(t.id);if(Object.prototype.toString.call(o)==="[object Date]")return tj.datetime;if(typeof o=="string"&&(n=!0,o.split(LJ).length>1))return tj.alphanumeric}return n?tj.text:tj.basic},t.getAutoSortDir=()=>{const i=e.getFilteredRowModel().flatRows[0];return typeof(i==null?void 0:i.getValue(t.id))=="string"?"asc":"desc"},t.getSortingFn=()=>{var i,n;if(!t)throw new Error;return mG(t.columnDef.sortingFn)?t.columnDef.sortingFn:t.columnDef.sortingFn==="auto"?t.getAutoSortingFn():(i=(n=e.options.sortingFns)==null?void 0:n[t.columnDef.sortingFn])!=null?i:tj[t.columnDef.sortingFn]},t.toggleSorting=(i,n)=>{const r=t.getNextSortingOrder(),o=typeof i<"u"&&i!==null;e.setSorting(a=>{const s=a==null?void 0:a.find(h=>h.id===t.id),l=a==null?void 0:a.findIndex(h=>h.id===t.id);let u=[],c,d=o?i:r==="desc";if(a!=null&&a.length&&t.getCanMultiSort()&&n?s?c="toggle":c="add":a!=null&&a.length&&l!==a.length-1?c="replace":s?c="toggle":c="replace",c==="toggle"&&(o||r||(c="remove")),c==="add"){var f;u=[...a,{id:t.id,desc:d}],u.splice(0,u.length-((f=e.options.maxMultiSortColCount)!=null?f:Number.MAX_SAFE_INTEGER))}else c==="toggle"?u=a.map(h=>h.id===t.id?{...h,desc:d}:h):c==="remove"?u=a.filter(h=>h.id!==t.id):u=[{id:t.id,desc:d}];return u})},t.getFirstSortDir=()=>{var i,n;return((i=(n=t.columnDef.sortDescFirst)!=null?n:e.options.sortDescFirst)!=null?i:t.getAutoSortDir()==="desc")?"desc":"asc"},t.getNextSortingOrder=i=>{var n,r;const o=t.getFirstSortDir(),a=t.getIsSorted();return a?a!==o&&((n=e.options.enableSortingRemoval)==null||n)&&(!(i&&(r=e.options.enableMultiRemove)!=null)||r)?!1:a==="desc"?"asc":"desc":o},t.getCanSort=()=>{var i,n;return((i=t.columnDef.enableSorting)!=null?i:!0)&&((n=e.options.enableSorting)!=null?n:!0)&&!!t.accessorFn},t.getCanMultiSort=()=>{var i,n;return(i=(n=t.columnDef.enableMultiSort)!=null?n:e.options.enableMultiSort)!=null?i:!!t.accessorFn},t.getIsSorted=()=>{var i;const n=(i=e.getState().sorting)==null?void 0:i.find(r=>r.id===t.id);return n?n.desc?"desc":"asc":!1},t.getSortIndex=()=>{var i,n;return(i=(n=e.getState().sorting)==null?void 0:n.findIndex(r=>r.id===t.id))!=null?i:-1},t.clearSorting=()=>{e.setSorting(i=>i!=null&&i.length?i.filter(n=>n.id!==t.id):[])},t.getToggleSortingHandler=()=>{const i=t.getCanSort();return n=>{i&&(n.persist==null||n.persist(),t.toggleSorting==null||t.toggleSorting(void 0,t.getCanMultiSort()?e.options.isMultiSortEvent==null?void 0:e.options.isMultiSortEvent(n):!1))}}},createTable:t=>{t.setSorting=e=>t.options.onSortingChange==null?void 0:t.options.onSortingChange(e),t.resetSorting=e=>{var i,n;t.setSorting(e?[]:(i=(n=t.initialState)==null?void 0:n.sorting)!=null?i:[])},t.getPreSortedRowModel=()=>t.getGroupedRowModel(),t.getSortedRowModel=()=>(!t._getSortedRowModel&&t.options.getSortedRowModel&&(t._getSortedRowModel=t.options.getSortedRowModel(t)),t.options.manualSorting||!t._getSortedRowModel?t.getPreSortedRowModel():t._getSortedRowModel())}},d2t=[RIt,ZIt,GIt,YIt,LIt,kIt,JIt,QIt,c2t,$It,e2t,t2t,r2t,i2t,XIt];function f2t(t){var e,i;const n=[...d2t,...(e=t._features)!=null?e:[]];let r={_features:n};const o=r._features.reduce((f,h)=>Object.assign(f,h.getDefaultOptions==null?void 0:h.getDefaultOptions(r)),{}),a=f=>r.options.mergeOptions?r.options.mergeOptions(o,f):{...o,...f};let l={...{},...(i=t.initialState)!=null?i:{}};r._features.forEach(f=>{var h;l=(h=f.getInitialState==null?void 0:f.getInitialState(l))!=null?h:l});const u=[];let c=!1;const d={_features:n,options:{...o,...t},initialState:l,_queue:f=>{u.push(f),c||(c=!0,Promise.resolve().then(()=>{for(;u.length;)u.shift()();c=!1}).catch(h=>setTimeout(()=>{throw h})))},reset:()=>{r.setState(r.initialState)},setOptions:f=>{const h=dP(f,r.options);r.options=a(h)},getState:()=>r.options.state,setState:f=>{r.options.onStateChange==null||r.options.onStateChange(f)},_getRowId:(f,h,p)=>{var g;return(g=r.options.getRowId==null?void 0:r.options.getRowId(f,h,p))!=null?g:`${p?[p.id,h].join("."):h}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(f,h)=>{let p=(h?r.getPrePaginationRowModel():r.getRowModel()).rowsById[f];if(!p&&(p=r.getCoreRowModel().rowsById[f],!p))throw new Error;return p},_getDefaultColumnDef:gn(()=>[r.options.defaultColumn],f=>{var h;return f=(h=f)!=null?h:{},{header:p=>{const g=p.header.column.columnDef;return g.accessorKey?g.accessorKey:g.accessorFn?g.id:null},cell:p=>{var g,v;return(g=(v=p.renderValue())==null||v.toString==null?void 0:v.toString())!=null?g:null},...r._features.reduce((p,g)=>Object.assign(p,g.getDefaultColumnDef==null?void 0:g.getDefaultColumnDef()),{}),...f}},vn(t,"debugColumns")),_getColumnDefs:()=>r.options.columns,getAllColumns:gn(()=>[r._getColumnDefs()],f=>{const h=function(p,g,v){return v===void 0&&(v=0),p.map(y=>{const m=DIt(r,y,v,g),b=y;return m.columns=b.columns?h(b.columns,m,v+1):[],m})};return h(f)},vn(t,"debugColumns")),getAllFlatColumns:gn(()=>[r.getAllColumns()],f=>f.flatMap(h=>h.getFlatColumns()),vn(t,"debugColumns")),_getAllFlatColumnsById:gn(()=>[r.getAllFlatColumns()],f=>f.reduce((h,p)=>(h[p.id]=p,h),{}),vn(t,"debugColumns")),getAllLeafColumns:gn(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(f,h)=>{let p=f.flatMap(g=>g.getLeafColumns());return h(p)},vn(t,"debugColumns")),getColumn:f=>r._getAllFlatColumnsById()[f]};Object.assign(r,d);for(let f=0;f<r._features.length;f++){const h=r._features[f];h==null||h.createTable==null||h.createTable(r)}return r}function h2t(){return t=>gn(()=>[t.options.data],e=>{const i={rows:[],flatRows:[],rowsById:{}},n=function(r,o,a){o===void 0&&(o=0);const s=[];for(let u=0;u<r.length;u++){const c=MIt(t,t._getRowId(r[u],u,a),r[u],u,o,void 0,a==null?void 0:a.id);if(i.flatRows.push(c),i.rowsById[c.id]=c,s.push(c),t.options.getSubRows){var l;c.originalSubRows=t.options.getSubRows(r[u],u),(l=c.originalSubRows)!=null&&l.length&&(c.subRows=n(c.originalSubRows,o+1,c))}}return s};return i.rows=n(e),i},vn(t.options,"debugTable","getRowModel",()=>t._autoResetPageIndex()))}/**
   * react-table
   *
   * Copyright (c) TanStack
   *
   * This source code is licensed under the MIT license found in the
   * LICENSE.md file in the root directory of this source tree.
   *
   * @license MIT
   */function $xe(t,e){return t?p2t(t)?J.createElement(t,e):t:null}function p2t(t){return g2t(t)||typeof t=="function"||v2t(t)}function g2t(t){return typeof t=="function"&&(()=>{const e=Object.getPrototypeOf(t);return e.prototype&&e.prototype.isReactComponent})()}function v2t(t){return typeof t=="object"&&typeof t.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(t.$$typeof.description)}function y2t(t){const e={state:{},onStateChange:()=>{},renderFallbackValue:null,...t},[i]=J.useState(()=>({current:f2t(e)})),[n,r]=J.useState(()=>i.current.initialState);return i.current.setOptions(o=>({...o,...t,state:{...n,...t.state},onStateChange:a=>{r(a),t.onStateChange==null||t.onStateChange(a)}})),i.current}const b4e=28,rX=8,iX=30,S4e="absolute top-0 right-0 z-10 flex h-full w-2 cursor-col-resize items-center justify-center touch-none select-none hover:bg-muted/40 dark:hover:bg-muted/25";function kJ(t,e){const i=t.frame;switch(e){case"name":return t.name;case"channel":return t.channel;case"frameName":return"";case"frameId":return i.id??"";case"unit":return"";case"cycleTime":return"cycle_time"in i?i.cycle_time??"":"";case"min":return"";case"max":return"";case"size":return i.payload_size??"";case"factor":return"";case"offset":return"";case"isRaw":return"";case"senders":return(i.senders??[]).join(", ");case"receivers":return"";case"namedValues":return"";case"description":return i.description??"";default:return}}function m2t(t,e,i,n){const r=kJ(t,i),o=kJ(e,i),a=r==null||r==="",s=o==null||o==="";if(a&&s)return 0;if(a)return n?-1:1;if(s)return n?1:-1;let l=0;return typeof r=="number"&&typeof o=="number"?l=r-o:l=String(r).localeCompare(String(o),void 0,{numeric:!0}),n?-l:l}const b2t=[{id:"name",label:"Name",width:200,minSize:80,maxSize:400},{id:"channel",label:"Channel",width:130,minSize:60,maxSize:300},{id:"frameId",label:"Frame ID",width:80,minSize:50,maxSize:120},{id:"cycleTime",label:"Cycle Time",width:95,minSize:60,maxSize:140},{id:"size",label:"Size",width:60,minSize:40,maxSize:100},{id:"senders",label:"Senders",width:130,minSize:80,maxSize:300},{id:"description",label:"Description",width:220,minSize:80,maxSize:500}],Vj=[{id:"name",label:"Name",width:180,minSize:80,maxSize:400},{id:"unit",label:"Unit",width:80,minSize:40,maxSize:200},{id:"min",label:"Min",width:70,minSize:40,maxSize:120},{id:"max",label:"Max",width:70,minSize:40,maxSize:120},{id:"factor",label:"Factor",width:80,minSize:40,maxSize:160},{id:"offset",label:"Offset",width:80,minSize:40,maxSize:160},{id:"isRaw",label:"Raw",width:60,minSize:40,maxSize:100},{id:"receivers",label:"Receivers",width:150,minSize:80,maxSize:400},{id:"namedValues",label:"Named Values",width:150,minSize:80,maxSize:400},{id:"description",label:"Description",width:250,minSize:80,maxSize:500}];function IJ(t,e){const i=t,n=i.signal;switch(e){case"name":return i.name;case"channel":return i.channel;case"frameName":return i.frameName;case"frameId":return"";case"unit":return n.unit??"";case"cycleTime":return"";case"min":return n.min??"";case"max":return n.max??"";case"size":return"";case"factor":return n.factor??"";case"offset":return n.offset??"";case"isRaw":return n.is_raw??"";case"senders":return"";case"receivers":return(n.receivers??[]).join(", ");case"namedValues":return n.named_values?Object.entries(n.named_values).map(([r,o])=>`${r}: ${o}`).join(`
`):"";case"description":return n.description??"";default:return}}function S2t(t,e,i,n){const r=IJ(t,i),o=IJ(e,i),a=r==null||r==="",s=o==null||o==="";if(a&&s)return 0;if(a)return n?-1:1;if(s)return n?1:-1;let l=0;return typeof r=="number"&&typeof o=="number"?l=r-o:l=String(r).localeCompare(String(o),void 0,{numeric:!0}),n?-l:l}function _2t(t,e){return b2t.map(i=>({id:i.id,accessorFn:n=>kJ(n,i.id),header:()=>L.jsxs("button",{type:"button",className:"flex items-center gap-1 w-full pr-3 text-left hover:text-foreground",onClick:()=>e(i.id),children:[i.label,(t==null?void 0:t.columnId)===i.id&&L.jsx("span",{className:"text-muted-foreground",children:t.desc?" ↓":" ↑"})]}),cell:n=>{const r=n.getValue(),o=r!=null&&r!==""?String(r):"";return L.jsx("div",{className:`flex-shrink-0 px-2 truncate text-foreground/80 ${i.id==="name"?"font-medium":""}`,title:o,children:o})},size:i.width,minSize:i.minSize,maxSize:i.maxSize,enableSorting:!0}))}function P2t(t){const e=qt.c(24);let i;e:{if(!t.sortState){i=t.frame.signals;break e}let h;if(e[0]!==t.frame.signals||e[1]!==t.sortState){let p;e[3]!==t.sortState?(p=(g,v)=>S2t(g,v,t.sortState.columnId,t.sortState.desc),e[3]=t.sortState,e[4]=p):p=e[4],h=[...t.frame.signals].sort(p),e[0]=t.frame.signals,e[1]=t.sortState,e[2]=h}else h=e[2];i=h}const n=i;let r;e[5]!==t.columnWidths?(r=Vj.reduce((h,p)=>h+t.columnWidths[p.id],0),e[5]=t.columnWidths,e[6]=r):r=e[6];const o=r;let a;e[7]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx("p",{className:"text-xs font-medium mb-1",children:"Signals"}),e[7]=a):a=e[7];let s;e[8]!==o?(s={minWidth:o},e[8]=o,e[9]=s):s=e[9];let l;e[10]===Symbol.for("react.memo_cache_sentinel")?(l={height:b4e},e[10]=l):l=e[10];let u;e[11]!==t?(u=Vj.map(h=>{var p;return L.jsxs("div",{className:"flex-shrink-0 relative flex items-center px-2",style:{width:t.columnWidths[h.id]},children:[L.jsxs("button",{type:"button",className:"flex min-w-0 flex-1 items-center gap-1 truncate pr-3 text-left hover:text-foreground",onClick:()=>t.onSort(h.id),children:[h.label,((p=t.sortState)==null?void 0:p.columnId)===h.id&&L.jsx("span",{className:"text-muted-foreground shrink-0",children:t.sortState.desc?" ↓":" ↑"})]}),L.jsx("div",{role:"separator","aria-orientation":"vertical","aria-label":`Resize ${h.label} column`,title:"Drag to resize column",onMouseDown:g=>t.onColumnResizeStart(h.id,g),className:S4e,style:{touchAction:"none"},children:L.jsx("span",{className:"pointer-events-none h-[55%] w-px rounded-full bg-border dark:bg-white/20","aria-hidden":!0})})]},h.id)}),e[11]=t,e[12]=u):u=e[12];let c;e[13]!==u?(c=L.jsx("div",{className:"flex items-center border-b border-border bg-muted/30 text-xs font-medium text-muted-foreground",style:l,children:u}),e[13]=u,e[14]=c):c=e[14];let d;if(e[15]!==t.columnWidths||e[16]!==n){let h;e[18]!==t.columnWidths?(h=p=>{const g=`${p.channel}:${p.name}`;return L.jsx("div",{className:"flex items-start border-b border-border/30 last:border-b-0 hover:bg-muted/20",children:Vj.map(v=>{const y=IJ(p,v.id),m=y!=null&&y!==""?String(y):"",b=p.signal.named_values;return v.id==="namedValues"&&b&&Object.keys(b).length>0?L.jsx("div",{className:"flex-shrink-0 px-2 py-1 text-foreground/80 whitespace-normal",style:{width:t.columnWidths[v.id]},title:m,children:L.jsx("div",{className:"flex flex-col gap-0.5",children:Object.entries(b).map(C2t)})},`${g}:${v.id}`):L.jsx("div",{className:`flex-shrink-0 truncate px-2 py-1 text-foreground/80 ${v.id==="name"?"font-medium":""}`,style:{width:t.columnWidths[v.id]},title:m,children:m},`${g}:${v.id}`)})},g)},e[18]=t.columnWidths,e[19]=h):h=e[19],d=n.map(h),e[15]=t.columnWidths,e[16]=n,e[17]=d}else d=e[17];let f;return e[20]!==s||e[21]!==c||e[22]!==d?(f=L.jsx("div",{className:"border-b border-border/50 bg-muted/10",children:L.jsxs("div",{className:"p-3",children:[a,L.jsx("div",{className:"overflow-x-auto rounded border border-border/60 bg-background/70",children:L.jsxs("div",{className:"min-w-max",style:s,children:[c,d]})})]})}),e[20]=s,e[21]=c,e[22]=d,e[23]=f):f=e[23],f}function C2t(t){const[e,i]=t;return L.jsxs("div",{children:[e,": ",i]},e)}function T2t(){"use no memo";var U,k;const{activePage:t}=Ih(),{environment:e}=Lp(),[i,n]=J.useState([]),[r,o]=J.useState([]),[a,s]=J.useState(new Set),[l,u]=J.useState(null),[c,d]=J.useState(null),[f,h]=J.useState(()=>Object.fromEntries(Vj.map(X=>[X.id,X.width]))),p=J.useRef(f);p.current=f;const[g,v]=J.useState(!1),y=J.useRef(null),m=(U=t==null?void 0:t.params)==null?void 0:U.path,b=J.useMemo(()=>e.studioBackendUrl&&m?Fwt(e.studioBackendUrl,m):void 0,[e.studioBackendUrl,m]);J.useEffect(()=>{if(!b)return;let X=!1;return(async()=>{if(await b.refreshDocumentCount(),!b.hasIndexedFiles()){v(!0);try{await b.reindex()}finally{X||v(!1)}}const Y=await b.fetchParsedFrames();X||(n(Y),o(Y))})(),()=>{X=!0}},[b,m,n,o]);const S=i.reduce((X,W)=>X+W.signals.length,0),_=r.reduce((X,W)=>X+W.signals.length,0),C=J.useMemo(()=>l?[...r].sort((W,Y)=>m2t(W,Y,l.columnId,l.desc)):r,[r,l]),P=X=>`${X.channel}:${X.name}`,x=X=>`${X.channel}:${X.name}`,E=J.useCallback((X,W)=>{const Y=[];for(const te of X){const oe=P(te);if(W.has(oe))Y.push(te);else{const de=te.signals.filter(ge=>W.has(x(ge)));de.length>0&&Y.push({...te,signals:de})}}return Y},[]),A=X=>{u(W=>(W==null?void 0:W.columnId)!==X?{columnId:X,desc:!1}:W.desc?null:{columnId:X,desc:!0})},R=X=>{d(W=>(W==null?void 0:W.columnId)!==X?{columnId:X,desc:!1}:W.desc?null:{columnId:X,desc:!0})},M=J.useCallback((X,W)=>{W.preventDefault(),W.stopPropagation();const Y=Vj.find(Ae=>Ae.id===X);if(!Y)return;const te=Y.minSize??40,oe=Y.maxSize??600,de=W.clientX,ge=p.current[X],Ee=Ae=>{const Pe=Ae.clientX-de,we=Math.min(oe,Math.max(te,ge+Pe));h(Te=>({...Te,[X]:we}))},Re=()=>{window.removeEventListener("mousemove",Ee),window.removeEventListener("mouseup",Re)};window.addEventListener("mousemove",Ee),window.addEventListener("mouseup",Re)},[]),D=J.useMemo(()=>_2t(l,A),[l]),F=y2t({data:C,columns:D,getCoreRowModel:h2t(),enableColumnResizing:!0,columnResizeMode:"onChange"}),I=pre({count:C.length,getScrollElement:()=>y.current,estimateSize:X=>a.has(P(C[X]))?260:iX,getItemKey:X=>P(C[X]),overscan:8}),V=X=>{s(W=>{const Y=new Set(W);return Y.has(X)?Y.delete(X):Y.add(X),Y})},z=`Showing ${_} of ${S} signals`,H=(((k=F.getHeaderGroups()[0])==null?void 0:k.headers.reduce((X,W)=>X+W.getSize(),0))??0)+rX;return L.jsxs("div",{className:"flex-1 flex flex-col min-h-0 overflow-hidden",children:[L.jsx("div",{className:"flex-shrink-0 px-2 pb-2",children:L.jsx(GNe,{frameEntries:i,setFoundSignals:o,filterEntries:E,placeholderHint:"Speed",showChannelField:!0,searchApi:b,clear:()=>o(i),status:z})}),g?L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center text-muted-foreground gap-2",children:[L.jsx("div",{className:"h-5 w-5 animate-spin rounded-full border-2 border-muted-foreground border-t-transparent"}),L.jsx("p",{className:"text-sm",children:"Indexing signals…"})]}):r.length===0?L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center gap-2",children:[L.jsx(Wr,{type:dr.SYSTEM_SEARCH_X,className:"w-8 h-8 opacity-40"}),L.jsx("p",{className:"text-sm",children:"No matches found"}),L.jsx("div",{className:"flex items-center gap-1 max-w-lg",children:L.jsxs("p",{className:"text-xs text-muted-foreground inline",children:["Try adjusting your search query or filters. Make sure you are using the correct search options. If you need help, hover over the",L.jsx(Wr,{type:dr.STATUS_HELP,className:"w-3.5 h-3.5 text-muted-foreground mx-1 inline align-middle"}),"icon in the search bar for more information."]})})]}):L.jsxs("div",{ref:y,className:"flex-1 overflow-auto min-h-0 text-xs",children:[L.jsxs("div",{className:"sticky top-0 z-10 flex items-center font-medium text-muted-foreground border-b border-border bg-background",style:{height:b4e,minWidth:H},children:[L.jsx("div",{style:{width:rX},className:"flex-shrink-0"}),F.getHeaderGroups().map(X=>X.headers.map(W=>L.jsxs("div",{className:"flex-shrink-0 relative flex items-center px-2 truncate",style:{width:W.getSize()},children:[W.isPlaceholder?null:$xe(W.column.columnDef.header,W.getContext()),W.column.getCanResize()&&L.jsx("div",{role:"separator","aria-orientation":"vertical","aria-label":`Resize ${W.column.id} column`,title:"Drag to resize column",onMouseDown:W.getResizeHandler(),onTouchStart:W.getResizeHandler(),className:`${S4e} ${W.column.getIsResizing()?"bg-muted/50 dark:bg-muted/35":""}`,style:{touchAction:"none"},children:L.jsx("span",{className:`pointer-events-none h-[55%] w-px rounded-full ${W.column.getIsResizing()?"bg-primary":"bg-border dark:bg-white/20"}`,"aria-hidden":!0})})]},W.id)))]}),L.jsx("div",{style:{height:I.getTotalSize(),minWidth:H,position:"relative"},children:I.getVirtualItems().map(X=>{const W=F.getRowModel().rows[X.index];if(!W)return null;const Y=W.original,te=P(Y),oe=a.has(te);return L.jsxs("div",{"data-index":X.index,ref:I.measureElement,style:{left:0,position:"absolute",top:0,transform:`translateY(${X.start}px)`,width:"100%"},children:[L.jsxs("div",{className:"flex items-center bg-muted/20 hover:bg-muted/40 border-b border-border/50 cursor-pointer select-none",onClick:()=>V(te),children:[L.jsx("div",{style:{width:rX,height:iX},className:"flex-shrink-0 flex items-center justify-center text-muted-foreground",children:oe?"▾":"▸"}),W.getVisibleCells().map(de=>L.jsx("div",{className:"flex items-center flex-shrink-0 overflow-hidden",style:{height:iX,width:de.column.getSize()},children:$xe(de.column.columnDef.cell,de.getContext())},de.id))]}),oe&&L.jsx(P2t,{frame:Y,sortState:c,onSort:R,columnWidths:f,onColumnResizeStart:M})]},X.key)})})]})]})}const x2t=[{value:"tree",icon:dr.VIEW_TREE,tooltip:"Tree view"},{value:"text",icon:dr.VIEW_TEXT,tooltip:"YAML"},{value:"signals",icon:dr.SYSTEM_SIGNAL,tooltip:"Signals"}];function Wxe(t){const{getResolvedPlatform:e,getResolvedInstance:i}=B$(),{track:n}=el(),[r,o]=J.useState("tree"),[a,s]=J.useState(null),[l,u]=J.useState(!0),[c,d]=J.useState(null),f=Kkt({content:a??""}),h=J.useCallback((_,C)=>{const P=f.isNodeExpanded(_),x=_.type==="folder"?_.childType:_.entity.entityType,E=_.type;P?n(Fi.TopologyCollapseNode,{entityType:x,nodeType:E}):n(Fi.TopologyExpandNode,{entityType:x,nodeType:E,treeDepth:C}),f.toggleNode(_)},[n,f]),p=J.useCallback(_=>{_!==null?n(Fi.TopologyEntityDetailsOpen,{entityType:_.entityType}):n(Fi.TopologyEntityDetailsClose),f.selectEntity(_)},[n,f]),g=J.useCallback(_=>{n(Fi.TopologyChangeMode,{mode:_==="text"?"yaml":_}),o(_)},[n]);J.useEffect(()=>{let _=!1;return(async()=>{try{const P=t.mode==="platform"?await e(t.filePath):await i(t.filePath);_||s(P)}catch(P){if(!_){const x=P instanceof Error?P.message:`Failed to load ${t.mode}`;d(x),Ki.error(x)}}finally{_||u(!1)}})(),()=>{_=!0}},[t.filePath,e,i,t.mode]);const v=_=>{f.setSearchQuery(_)};if(c)return L.jsx(Vxe,{message:`Failed to load ${t.mode}`,error:c});if(l)return L.jsxs("div",{className:Hr("h-full flex flex-col items-center justify-center text-muted-foreground"),children:[L.jsx(Wr,{type:dr.STATUS_LOADING,className:"w-8 h-8 animate-spin mb-3"}),L.jsxs("p",{className:"text-sm",children:["Resolving ",t.mode,"..."]})]});if(a===null)return null;if(f.parseError)return L.jsx(Vxe,{message:`Failed to parse ${t.mode}`,error:f.parseError});const y=f.selectedEntity!==null,m=()=>L.jsx(L.Fragment,{children:L.jsxs("div",{className:"flex items-center gap-2",children:[L.jsx(kqe,{options:x2t,value:r,onChange:g}),r==="tree"&&L.jsx(CIt,{searchQuery:f.searchQuery,onSearchChange:v,disabled:r!=="tree",className:"flex-1"}),t.mode==="instance"&&L.jsx(FD,{content:L.jsx("p",{className:"text-xs",children:f.showOnlyInstanced?"Show all entities":"Show only instantiated entities"}),side:"bottom",delay:400,children:L.jsx("button",{onClick:()=>{const _=!f.showOnlyInstanced;n(Fi.TopologyShowAllEntities,{showAll:!_}),f.setShowOnlyInstanced(_)},className:Hr("p-2 rounded-md transition-colors",f.showOnlyInstanced?"bg-primary/20 text-primary":"text-muted-foreground hover:bg-muted hover:text-foreground"),children:L.jsx(Wr,{type:dr.ACTION_FILTER,className:"w-4 h-4"})})})]})}),b=()=>L.jsxs(L.Fragment,{children:[r==="tree"&&L.jsx(xIt,{nodes:f.filteredNodes,searchQuery:f.searchQuery,mode:t.mode,showOnlyInstanced:f.showOnlyInstanced,isNodeSelected:f.isNodeSelected,isNodeExpanded:f.isNodeExpanded,isNodeHovered:f.isNodeHovered,isNodeHighlightedAncestor:f.isNodeHighlightedAncestor,onToggleNode:h,getChildren:f.getChildren,getUninstantiatedChildren:f.getUninstantiatedChildren,onNodeMouseEnter:f.handleMouseEnter,onNodeMouseLeave:f.handleMouseLeave,onNodeInfoClick:_=>p(_.type==="entity"?_.entity:null)}),r==="text"&&L.jsx(tAe,{text:a,language:"yaml",className:"flex-1 mt-1"}),r==="signals"&&L.jsx(T2t,{})]}),S=()=>L.jsx(L.Fragment,{children:y&&L.jsx(PIt,{entity:f.selectedEntity,onClose:()=>p(null),onSelectEntity:p,onEntityMouseEnter:f.handleMouseEnter,onEntityMouseLeave:f.handleMouseLeave,mode:t.mode,filePath:t.filePath})});return L.jsxs("div",{className:Hr("flex overflow-hidden relative h-full min-h-0",t.className),children:[L.jsxs("div",{className:"flex-1 flex flex-col min-w-0 min-h-0 overflow-hidden",children:[L.jsx("div",{className:"flex-shrink-0 space-y-2 px-2",children:m()}),L.jsx("div",{className:"flex-1 min-h-0 flex flex-col",children:b()})]}),S()]})}function E2t(t){return{path:typeof t.path=="string"?t.path:void 0,fileType:typeof t.fileType=="string"?t.fileType:void 0}}const w2t={route:Nu.FILES,title:"File",contextId:qs.FILES,icon:Xi.CONTEXT_FILES,component:R2t,validateSearch:E2t};function A2t(t){const e=qt.c(3);let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx(Wr,{type:dr.STATUS_LOADING,className:"w-8 h-8 animate-spin mb-3"}),e[0]=i):i=e[0];let n;return e[1]!==t.message?(n=L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center text-muted-foreground",children:[i,L.jsx("p",{className:"text-sm",children:t.message})]}),e[1]=t.message,e[2]=n):n=e[2],n}function O2t(t){const e=qt.c(4);let i,n;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx("div",{className:"p-4 rounded-xl bg-destructive/10 mb-4",children:L.jsx(Wr,{type:dr.STATUS_ERROR,className:"w-8 h-8 text-destructive"})}),n=L.jsx("p",{className:"text-foreground font-medium mb-1",children:"Failed to load file"}),e[0]=i,e[1]=n):(i=e[0],n=e[1]);let r;return e[2]!==t.message?(r=L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center",children:[i,n,L.jsx("p",{className:"text-sm text-muted-foreground",children:t.message})]}),e[2]=t.message,e[3]=r):r=e[3],r}function D2t(t){const e=qt.c(5);let i,n,r;e[0]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsx("div",{className:"p-4 rounded-xl bg-muted mb-4",children:L.jsx(Wr,{type:dr.FILE_UNKNOWN,className:"w-8 h-8 text-muted-foreground"})}),n=L.jsx("p",{className:"text-foreground font-medium mb-1",children:"Unsupported file type"}),r=L.jsx("p",{className:"text-xs text-muted-foreground text-center max-w-md mb-4",children:"This file type will not be automatically previewed. You can preview it as text, but the content might not be readable."}),e[0]=i,e[1]=n,e[2]=r):(i=e[0],n=e[1],r=e[2]);let o;return e[3]!==t.onViewAsText?(o=L.jsxs("div",{className:"flex-1 flex flex-col items-center justify-center",children:[i,n,r,L.jsx(Za,{type:fn.PRIMARY,onClick:t.onViewAsText,label:"View as text",icon:dr.CONTENT_CODE})]}),e[3]=t.onViewAsText,e[4]=o):o=e[4],o}function R2t(){const t=qt.c(66),{getFileContent:e,getFileUrl:i}=B$(),{pages:n,activePage:r,closeOtherPages:o}=Ih(),{tabId:a,params:s}=jne(),l=(s==null?void 0:s.path)||"",u=s==null?void 0:s.fileType;let c;t[0]!==u?(c=Jqe(u),t[0]=u,t[1]=c):c=t[1];const d=c;let f;t[2]!==d||t[3]!==(s==null?void 0:s.viewMode)?(f=()=>Zqe(s==null?void 0:s.viewMode,d),t[2]=d,t[3]=s==null?void 0:s.viewMode,t[4]=f):f=t[4];const[h,p]=J.useState(f),g=l.split("/").pop()||l,v=Xqe(g),y=Uat(v);let m;t[5]!==l||t[6]!==i?(m=i(l),t[5]=l,t[6]=i,t[7]=m):m=t[7];const b=m;let S;t[8]!==d?(S=qat(d),t[8]=d,t[9]=S):S=t[9];const _=S;let C;t[10]!==l?(C=l.startsWith("draft:"),t[10]=l,t[11]=C):C=t[11];const x=!_&&h!=="unsupported"&&!C,[E,A]=J.useState(null),[R,M]=J.useState(x),[D,F]=J.useState(null);let I;t[12]!==l||t[13]!==e||t[14]!==F||t[15]!==x?(I=()=>{x&&e(l).then(me=>{me===null?F("Failed to load file"):A(me)}).catch(me=>F(me.message||"Unknown error")).finally(()=>M(!1))},t[12]=l,t[13]=e,t[14]=F,t[15]=x,t[16]=I):I=t[16];let V;t[17]!==l||t[18]!==e||t[19]!==x?(V=[l,e,x],t[17]=l,t[18]=e,t[19]=x,t[20]=V):V=t[20],J.useEffect(I,V);const z=Gat(d,v);let G;t[21]!==d?(G=d?Yat(d):[],t[21]=d,t[22]=G):G=t[22];const H=G;let U;t[23]===Symbol.for("react.memo_cache_sentinel")?(U=me=>{p(me)},t[23]=U):U=t[23];const k=U;let X;if(t[24]!==H){X=[];for(const me of H){const Ce=Xat[me];Ce&&X.push({value:me,icon:dV(Ce.iconName),label:Ce.label,isLoading:!1})}t[24]=H,t[25]=X}else X=t[25];const W=X;let Y;t[26]!==H||t[27]!==E||t[28]!==D||t[29]!==g||t[30]!==l||t[31]!==R||t[32]!==y||t[33]!==b||t[34]!==F||t[35]!==h?(Y=()=>R?L.jsx(A2t,{message:"Loading file..."}):D?L.jsx(O2t,{message:D}):h==="unsupported"?L.jsx(D2t,{onViewAsText:()=>k("text")}):L.jsxs(L.Fragment,{children:[H.includes("image")&&L.jsx("div",{className:h==="image"?"h-full":"hidden",children:L.jsx(A7e,{url:b,fileName:g,onError:()=>F("Failed to load image")})},"image"),H.includes("video")&&L.jsx("div",{className:h==="video"?"h-full":"hidden",children:L.jsx(O7e,{url:b,onError:()=>F("Failed to load video")})},"video"),H.includes("audio")&&L.jsx("div",{className:h==="audio"?"h-full":"hidden",children:L.jsx(D7e,{url:b,onError:()=>F("Failed to load audio")})},"audio"),(H.includes("text")||h==="text")&&E!==null&&L.jsx("div",{className:h==="text"?"h-full min-h-0 flex flex-col":"hidden",children:L.jsx(tAe,{text:E,language:y,className:"flex-1 min-h-0"})},"text"),H.includes("platform")&&L.jsx("div",{className:h==="platform"?"h-full min-h-0 flex flex-col":"hidden",children:L.jsx(Wxe,{filePath:l,mode:"platform",className:"flex-1 min-h-0"})},"platform"),H.includes("instance")&&L.jsx("div",{className:h==="instance"?"h-full min-h-0 flex flex-col":"hidden",children:L.jsx(Wxe,{filePath:l,mode:"instance",className:"flex-1 min-h-0"})},"instance"),H.includes("signal-database")&&E!==null&&L.jsx("div",{className:h==="signal-database"?"h-full":"hidden",children:L.jsx("div",{children:"Signal Database Viewer"})},"signal-database"),H.includes("dashboard")&&L.jsx("div",{className:h==="dashboard"?"flex flex-col":"hidden",children:L.jsx(CLt,{filePath:l})},"dashboard")]}),t[26]=H,t[27]=E,t[28]=D,t[29]=g,t[30]=l,t[31]=R,t[32]=y,t[33]=b,t[34]=F,t[35]=h,t[36]=Y):Y=t[36];const te=Y,oe=h==="dashboard",de=oe?"overflow-auto":"overflow-hidden",ge=u??"";let Ee;t[37]!==r||t[38]!==o?(Ee=()=>(r==null?void 0:r.id)&&o(r.id),t[37]=r,t[38]=o,t[39]=Ee):Ee=t[39];const Re=n.length>1;let Ae;t[40]!==z||t[41]!==g||t[42]!==l||t[43]!==ge||t[44]!==Ee||t[45]!==Re||t[46]!==h||t[47]!==W?(Ae=L.jsx(LP,{className:"p-0",children:L.jsx(Hat,{fileName:g,filePath:l,fileType:ge,fileIcon:z,viewModeOptions:W,currentViewMode:h,onViewModeChange:k,onCloseOtherTabs:Ee,hasOtherTabs:Re})}),t[40]=z,t[41]=g,t[42]=l,t[43]=ge,t[44]=Ee,t[45]=Re,t[46]=h,t[47]=W,t[48]=Ae):Ae=t[48];const Pe=!oe&&"min-h-0";let we;t[49]!==Pe?(we=Hr("p-0",Pe),t[49]=Pe,t[50]=we):we=t[50];const Te=`fileviewer-${a}`,ke=!oe&&"flex-1 min-h-0 overflow-hidden";let $e;t[51]!==ke?($e=Hr("flex flex-col",ke),t[51]=ke,t[52]=$e):$e=t[52];let Ne;t[53]!==te?(Ne=te(),t[53]=te,t[54]=Ne):Ne=t[54];let ve;t[55]!==Te||t[56]!==$e||t[57]!==Ne?(ve=L.jsx("div",{className:$e,children:Ne},Te),t[55]=Te,t[56]=$e,t[57]=Ne,t[58]=ve):ve=t[58];let pe;t[59]!==we||t[60]!==ve?(pe=L.jsx(LS,{className:we,children:ve}),t[59]=we,t[60]=ve,t[61]=pe):pe=t[61];let fe;return t[62]!==de||t[63]!==Ae||t[64]!==pe?(fe=L.jsxs(MS,{maxWidth:"full",className:de,children:[Ae,pe]}),t[62]=de,t[63]=Ae,t[64]=pe,t[65]=fe):fe=t[65],fe}function M2t(t){const e=qt.c(12);let i;e[0]!==t.label?(i=L.jsx("span",{className:"text-md text-card-foreground",children:t.label}),e[0]=t.label,e[1]=i):i=e[1];let n;e[2]!==t.description?(n=L.jsx("span",{className:"text-sm text-muted-foreground text-card-foreground",children:t.description}),e[2]=t.description,e[3]=n):n=e[3];let r;e[4]!==i||e[5]!==n?(r=L.jsxs("div",{className:"flex flex-col gap-0",children:[i,n]}),e[4]=i,e[5]=n,e[6]=r):r=e[6];let o;e[7]!==t.value?(o=L.jsx("span",{className:"text-md text-muted-foreground",children:t.value}),e[7]=t.value,e[8]=o):o=e[8];let a;return e[9]!==r||e[10]!==o?(a=L.jsxs("div",{className:"flex rounded-md border border-border px-4 py-2 bg-card justify-between items-center",children:[r,o]}),e[9]=r,e[10]=o,e[11]=a):a=e[11],a}function Y_(t){const e=qt.c(13);let i;e[0]!==t.iconType?(i=L.jsx("div",{className:"p-2 rounded-lg bg-muted group-hover:bg-background transition-colors",children:L.jsx(Wr,{type:t.iconType,className:"w-5 h-5 text-muted-foreground group-hover:text-foreground transition-colors"})}),e[0]=t.iconType,e[1]=i):i=e[1];let n;e[2]!==t.title?(n=L.jsx("p",{className:"font-medium text-card-foreground group-hover:text-foreground transition-colors",children:t.title}),e[2]=t.title,e[3]=n):n=e[3];let r;e[4]!==t.description?(r=L.jsx("p",{className:"text-sm text-muted-foreground",children:t.description}),e[4]=t.description,e[5]=r):r=e[5];let o;e[6]!==n||e[7]!==r?(o=L.jsxs("div",{children:[n,r]}),e[6]=n,e[7]=r,e[8]=o):o=e[8];let a;return e[9]!==t.href||e[10]!==i||e[11]!==o?(a=L.jsxs("a",{href:t.href,target:"_blank",rel:"noopener noreferrer",className:"rounded-xl border border-border bg-card p-4 hover:bg-muted/50 transition-colors group flex items-start gap-4",children:[i,o]}),e[9]=t.href,e[10]=i,e[11]=o,e[12]=a):a=e[12],a}const L2t={route:Nu.ABOUT,title:"About",contextId:qs.ABOUT,icon:Xi.CONTEXT_ABOUT,component:k2t};function k2t(){const t=qt.c(9),{environment:e}=Lp(),i=F2t,n=N2t;let r;t[0]!==e.versions?(r=()=>L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-foreground mb-5",children:"Version Information"}),L.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 gap-2 sm:gap-3 ",children:e.versions.map(I2t)})]}),t[0]=e.versions,t[1]=r):r=t[1];const o=r;let a;t[2]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(LP,{title:"About",description:"Information about RemotiveStudio and RemotiveLabs"}),t[2]=a):a=t[2];let s;t[3]!==o?(s=L.jsx("section",{className:"mb-10",children:o()}),t[3]=o,t[4]=s):s=t[4];let l;t[5]===Symbol.for("react.memo_cache_sentinel")?(l=L.jsx("section",{className:"mb-10",children:n()}),t[5]=l):l=t[5];let u;t[6]===Symbol.for("react.memo_cache_sentinel")?(u=L.jsx("section",{className:"mb-10",children:i()}),t[6]=u):u=t[6];let c;return t[7]!==s?(c=L.jsxs(MS,{children:[a,L.jsxs(LS,{children:[s,l,u]})]}),t[7]=s,t[8]=c):c=t[8],c}function I2t(t){return L.jsx(M2t,{label:t.name,value:t.version},t.name)}function N2t(){return L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-foreground mb-5",children:"Legal"}),L.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2 sm:gap-3 ",children:[L.jsx(Y_,{iconType:dr.FILE_GENERIC,title:"Privacy Policy",description:"How we handle your data",href:"https://www.remotivelabs.com/privacy-policy"}),L.jsx(Y_,{iconType:dr.FILE_GENERIC,title:"EULA",description:"Terms and license information",href:"https://www.remotivelabs.com/license"})]})]})}function F2t(){return L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-foreground mb-5",children:"RemotiveLabs resources"}),L.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2 sm:gap-3 ",children:[L.jsx(Y_,{iconType:dr.CONTENT_BOOK_TEXT,title:"Documentation",description:"Read the official documentation",href:"https://docs.remotivelabs.com"}),L.jsx(Y_,{iconType:dr.BRAND_GITHUB,title:"GitHub",description:"View source code and contribute",href:"https://github.com/remotivelabs"}),L.jsx(Y_,{iconType:dr.PANEL_TOP,title:"Website",description:"Read more about RemotiveLabs",href:"https://remotivelabs.com"}),L.jsx(Y_,{iconType:dr.CONTENT_NEWS,title:"Blog",description:"Read news, guides & articles",href:"https://www.remotivelabs.com/blog"}),L.jsx(Y_,{iconType:dr.BRAND_YOUTUBE,title:"Youtube",description:"Watch video guides & demos",href:"https://www.youtube.com/channel/UClSPiaP1zWIZEMgsDF7AODQ"}),L.jsx(Y_,{iconType:dr.BRAND_LINKEDIN,title:"LinkedIn",description:"Follow for company updates",href:"https://www.linkedin.com/company/remotivelabs"})]})]})}const B2t={route:Nu.TOPOLOGY_PLATFORM,title:"Platform",contextId:qs.TOPOLOGY,icon:Xi.SYSTEM_SERVER,component:j2t};function j2t(){const t=qt.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsx(LP,{title:"Platform",description:"View the platform that the running topology is using"}),t[0]=e):e=t[0];let i;return t[1]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsxs(MS,{children:[e,L.jsx(LS,{children:L.jsxs("div",{className:"rounded-2xl border-2 border-dashed border-border bg-muted/20 p-16 flex flex-col items-center justify-center text-center",children:[L.jsx("div",{className:"p-5 rounded-2xl bg-muted mb-6",children:L.jsx(Wr,{type:dr.SYSTEM_SERVER,className:"w-10 h-10 text-muted-foreground"})}),L.jsx("h2",{className:"text-xl font-semibold text-foreground mb-3",children:"Coming soon..."}),L.jsx("p",{className:"text-muted-foreground max-w-lg",children:"This is where you'll be able to visualize the platform that the running topology is using"})]})})]}),t[1]=i):i=t[1],i}const V2t={route:Nu.TOPOLOGY_INSTANCE,title:"Instance",contextId:qs.TOPOLOGY,icon:Xi.OBJECT_BOX,component:H2t};function H2t(){const t=qt.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsx(LP,{title:"Instance",description:"View the instance of the running topology"}),t[0]=e):e=t[0];let i;return t[1]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsxs(MS,{children:[e,L.jsx(LS,{children:L.jsxs("div",{className:"rounded-2xl border-2 border-dashed border-border bg-muted/20 p-16 flex flex-col items-center justify-center text-center",children:[L.jsx("div",{className:"p-5 rounded-2xl bg-muted mb-6",children:L.jsx(Wr,{type:dr.OBJECT_BOX,className:"w-10 h-10 text-muted-foreground"})}),L.jsx("h2",{className:"text-xl font-semibold text-foreground mb-3",children:"Coming soon..."}),L.jsx("p",{className:"text-muted-foreground max-w-lg",children:"This is where you'll be able to visualize the instance of the running topology"})]})})]}),t[1]=i):i=t[1],i}const U2t={route:Nu.TOPOLOGY_RESTBUS,title:"Restbus",contextId:qs.TOPOLOGY,icon:Xi.OBJECT_BUS,component:z2t};function z2t(){const t=qt.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsx(LP,{title:"Restbus",description:"Configure the restbus simulation for the running topology"}),t[0]=e):e=t[0];let i;return t[1]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsxs(MS,{children:[e,L.jsx(LS,{children:L.jsxs("div",{className:"rounded-2xl border-2 border-dashed border-border bg-muted/20 p-16 flex flex-col items-center justify-center text-center",children:[L.jsx("div",{className:"p-5 rounded-2xl bg-muted mb-6",children:L.jsx(Wr,{type:dr.OBJECT_BUS,className:"w-10 h-10 text-muted-foreground"})}),L.jsx("h2",{className:"text-xl font-semibold text-foreground mb-3",children:"Coming soon..."}),L.jsx("p",{className:"text-muted-foreground max-w-lg",children:"This is where you'll be able to configure restbus simulation"})]})})]}),t[1]=i):i=t[1],i}const $2t={route:Nu.TOPOLOGY_API_PLAYGROUND,title:"API Playground",contextId:qs.TOPOLOGY,icon:Xi.CONTENT_CODE,component:W2t};function W2t(){const t=qt.c(2);let e;t[0]===Symbol.for("react.memo_cache_sentinel")?(e=L.jsx(LP,{title:"API Playground",description:"Explore and test the API of the running topology interactively"}),t[0]=e):e=t[0];let i;return t[1]===Symbol.for("react.memo_cache_sentinel")?(i=L.jsxs(MS,{children:[e,L.jsx(LS,{children:L.jsxs("div",{className:"rounded-2xl border-2 border-dashed border-border bg-muted/20 p-16 flex flex-col items-center justify-center text-center",children:[L.jsx("div",{className:"p-5 rounded-2xl bg-muted mb-6",children:L.jsx(Wr,{type:dr.FILE_CODE,className:"w-10 h-10 text-muted-foreground"})}),L.jsx("h2",{className:"text-xl font-semibold text-foreground mb-3",children:"Coming soon..."}),L.jsx("p",{className:"text-muted-foreground max-w-lg",children:"This is where you'll be able to interact with the running topology, e.g. send CAN messages or call SOME/IP services."})]})})]}),t[1]=i):i=t[1],i}function G2t(){const t=qt.c(4),{track:e}=el();let i,n;t[0]!==e?(i=()=>{e(Fi.NotFoundPageViewed,{path:window.location.pathname})},n=[e],t[0]=e,t[1]=i,t[2]=n):(i=t[1],n=t[2]),J.useEffect(i,n);let r;return t[3]===Symbol.for("react.memo_cache_sentinel")?(r=L.jsx(MS,{children:L.jsx(LS,{className:"flex items-center justify-center min-h-[60vh]",children:L.jsx(bNt,{title:"Page not found",description:"The page you're looking for doesn't exist or has been moved."})})}),t[3]=r):r=t[3],r}function Y2t(t){var f,h;const e=qt.c(15),{track:i}=el();let n;e[0]!==((f=t.error)==null?void 0:f.stack)||e[1]!==i?(n=()=>{var p;i(Fi.AppCrashed,{stacktrace:(p=t.error)==null?void 0:p.stack})},e[0]=(h=t.error)==null?void 0:h.stack,e[1]=i,e[2]=n):n=e[2];let r;e[3]!==t.error||e[4]!==i?(r=[i,t.error],e[3]=t.error,e[4]=i,e[5]=r):r=e[5],J.useEffect(n,r);let o;e[6]!==t.error?(o=t.error?[t.error.message,t.error.stack].filter(Boolean).join(`

`):null,e[6]=t.error,e[7]=o):o=e[7];const a=o;let s;e[8]===Symbol.for("react.memo_cache_sentinel")?(s=L.jsx("p",{className:"text-lg text-foreground",children:"Something went wrong..."}),e[8]=s):s=e[8];let l;e[9]===Symbol.for("react.memo_cache_sentinel")?(l=L.jsxs("p",{className:"text-muted-foreground text-sm",children:["If this keeps happening, please contact"," ",L.jsx("a",{href:"mailto:support@remotivelabs.com",children:"support@remotivelabs.com"}),"."]}),e[9]=l):l=e[9];let u;e[10]===Symbol.for("react.memo_cache_sentinel")?(u=L.jsx("div",{className:"flex flex-col items-center justify-center text-center gap-6 w-full",children:L.jsxs("div",{className:"py-14 px-6",children:[s,l,L.jsx("div",{className:"mt-6",children:L.jsx("button",{type:"button",className:Hr(XJ,KJ[fn.PRIMARY],"gap-2 px-5 py-2 text-sm rounded-full"),onClick:q2t,children:"Reload application"})})]})}),e[10]=u):u=e[10];let c;e[11]!==a?(c=a&&L.jsxs("div",{className:"w-full",children:[L.jsx("label",{className:"text-sm font-medium text-muted-foreground mb-1 block",children:"Error details"}),L.jsx("textarea",{readOnly:!0,className:Hr("w-full min-h-[200px] p-2 rounded-md border border-border bg-muted","font-mono text-xs text-foreground resize-y"),value:a,"aria-label":"Error details"})]}),e[11]=a,e[12]=c):c=e[12];let d;return e[13]!==c?(d=L.jsx("div",{className:"min-h-screen flex flex-col items-center justify-center w-full p-5",children:L.jsxs("div",{className:"w-full max-w-3xl bg-background rounded-md border border-border/70 p-5",children:[u,c]})}),e[13]=c,e[14]=d):d=e[14],d}function q2t(){sessionStorage.clear(),window.location.href="/"}const bG=[Nqe,Wqe,w2t,B2t,V2t,U2t,$2t,yLt,L2t],X2t=new Map(bG.map(t=>[t.route,t]));function SG(t){return X2t.get(t)}function K2t(t){return bG.filter(e=>e.contextId===t)}const Z2t=new Set([qs.TOPOLOGY,qs.FILES]);function C$(t){return Z2t.has(t.id)}function J2t(t){if(t.type!==Nu.FILES)return!1;const e=t.params;return(e==null?void 0:e.fileType)==="FILE_TYPE_DASHBOARD"}function Q2t(t,e){if(t==="/")return null;const i=new URLSearchParams(e);if(t===Nu.FILES){const r=i.get("path")||"",o=r.split("/").pop()||"File",a=i.get("fileType")??void 0,s=i.get("viewMode")??void 0,l=i.get("entityId")??void 0,u=`file:${r}`;return{id:u,open:c=>c(Nu.FILES,{id:u,title:o,params:{path:r,fileType:a,viewMode:s,entityId:l}})}}const n=bG.find(r=>r.route===t);return n?{id:n.route,open:r=>r(n.route)}:null}function eNt(t){const e=t.type;if(!t.params)return e;const i=new URLSearchParams;for(const[r,o]of Object.entries(t.params))o!==void 0&&i.set(r,o);const n=i.toString();return n?`${e}?${n}`:e}function Gxe(t){return t==="/"||t===Nu.FILES?!0:bG.some(e=>e.route===t)}const _4e=J.createContext(null);function tNt(t){const e=qt.c(14),i=J.useRef(null),[n,r]=J.useState(!1);let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=y=>{i.current=y,r(!0)},e[0]=o):o=e[0];const a=o;let s;e[1]===Symbol.for("react.memo_cache_sentinel")?(s=()=>{const y=i.current;i.current=null,r(!1),y==null||y()},e[1]=s):s=e[1];const l=s;let u;e[2]===Symbol.for("react.memo_cache_sentinel")?(u=()=>{i.current=null,r(!1)},e[2]=u):u=e[2];const c=u;let d;e[3]!==n?(d={requestConfirmation:a,hasPendingConfirmation:n,confirmPendingAction:l,cancelPendingAction:c},e[3]=n,e[4]=d):d=e[4];let f,h;e[5]===Symbol.for("react.memo_cache_sentinel")?(f=L.jsx("h3",{className:"text-sm font-medium mb-2",children:"Unsaved Changes"}),h=L.jsx("p",{className:"text-xs text-muted-foreground mb-4",children:"You have unsaved changes. If you close this tab, your changes will be lost."}),e[5]=f,e[6]=h):(f=e[5],h=e[6]);let p;e[7]===Symbol.for("react.memo_cache_sentinel")?(p=L.jsxs("div",{className:"p-4",children:[f,h,L.jsxs("div",{className:"flex justify-end gap-2",children:[L.jsx(Za,{type:fn.NEUTRAL,size:_a.SM,label:"Cancel",onClick:c}),L.jsx(Za,{type:fn.DESTRUCTIVE,size:_a.SM,label:"Leave Without Saving",onClick:l})]})]}),e[7]=p):p=e[7];let g;e[8]!==n?(g=L.jsx(yI,{show:n,onClose:c,className:"max-w-sm",size:"sm",children:p}),e[8]=n,e[9]=g):g=e[9];let v;return e[10]!==t.children||e[11]!==d||e[12]!==g?(v=L.jsxs(_4e.Provider,{value:d,children:[t.children,g]}),e[10]=t.children,e[11]=d,e[12]=g,e[13]=v):v=e[13],v}function rNt(){const t=J.useContext(_4e);if(!t)throw new Error("useNavigationGuard must be used within a NavigationGuardProvider");return t}const iNt="studio-tabs";function P4e(t){return`${iNt}:${t}`}function Yxe(t){try{const e=sessionStorage.getItem(P4e(t));if(!e)return null;const i=JSON.parse(e);return Array.isArray(i.tabs)?i:null}catch{return null}}function nNt(t,e){try{const i=e.tabs.map(n=>{const{hasUnsavedChanges:r,...o}=n;return o});sessionStorage.setItem(P4e(t),JSON.stringify({tabs:i,activeTabId:e.activeTabId}))}catch{}}function qxe(t,e){const i=e,n={route:t};return(i==null?void 0:i.fileType)!==void 0&&(n.fileType=i.fileType),(i==null?void 0:i.viewMode)!==void 0&&(n.viewMode=i.viewMode),n}const nX=100;function oNt(t,e){const i=(e==null?void 0:e.params)!==void 0?e.params:t.params,n=(e==null?void 0:e.title)!==void 0?e.title:t.title;return i===t.params&&n===t.title?null:{...t,params:i,title:n}}function aNt(t,e){return t.find(i=>{var n;return((n=i.params)==null?void 0:n.path)===e})}function sNt(){return typeof window>"u"?"/":window.location.pathname}const C4e=J.createContext(null);function lNt(t){const e=qt.c(37),{environment:i}=Lp(),n=i.workspace,{requestConfirmation:r}=rNt(),{track:o}=el();let a;e[0]!==n?(a=()=>{const W=Yxe(n);return(W==null?void 0:W.tabs)??[]},e[0]=n,e[1]=a):a=e[1];const[s,l]=J.useState(a),u=J.useRef(s);let c,d;e[2]!==s?(c=()=>{u.current=s},d=[s],e[2]=s,e[3]=c,e[4]=d):(c=e[3],d=e[4]),J.useEffect(c,d);let f;e[5]!==n?(f=()=>{if(typeof window<"u"&&!Gxe(window.location.pathname))return null;const W=Yxe(n);return(W==null?void 0:W.activeTabId)??null},e[5]=n,e[6]=f):f=e[6];const[h,p]=J.useState(f),[g,v]=J.useState(sNt);let y;e[7]!==g?(y=Gxe(g),e[7]=g,e[8]=y):y=e[8];const m=!y;let b;e[9]!==h||e[10]!==s?(b=s.find(W=>W.id===h)??null,e[9]=h,e[10]=s,e[11]=b):b=e[11];const S=b;let _;e[12]===Symbol.for("react.memo_cache_sentinel")?(_=(W,Y)=>{l(te=>{const oe=te.find(de=>de.id===W);return!oe||oe.hasUnsavedChanges===Y?te:te.map(de=>de.id===W?{...de,hasUnsavedChanges:Y}:de)})},e[12]=_):_=e[12];const C=_,P=J.useRef(null);let x,E;e[13]!==h||e[14]!==s||e[15]!==n?(x=()=>(P.current&&clearTimeout(P.current),P.current=setTimeout(()=>{nNt(n,{tabs:s,activeTabId:h})},300),()=>{P.current&&clearTimeout(P.current)}),E=[s,h,n],e[13]=h,e[14]=s,e[15]=n,e[16]=x,e[17]=E):(x=e[16],E=e[17]),J.useEffect(x,E);let A;e[18]===Symbol.for("react.memo_cache_sentinel")?(A=(W,Y)=>{l(te=>te.map(oe=>oe.id===W?{...oe,...Y}:oe)),Y.id&&p(Y.id)},e[18]=A):A=e[18];const R=A;let M;e[19]!==o?(M=(W,Y)=>{var we;const te=SG(W),oe=(Y==null?void 0:Y.id)??W,de=te==null?void 0:te.contextId,ge=u.current,Ee=ge.find(Te=>Te.id===oe),Re=(we=Y==null?void 0:Y.params)==null?void 0:we.path,Ae=!Ee&&Re?aNt(ge,Re):void 0,Pe=Ee?oNt(Ee,Y):null;return l(Te=>Ee?(p(oe),Te):Ae?(p(Ae.id),Te):Te.length>=nX?(console.warn(`Tab limit (${nX}) reached`),Te):(p(oe),[...Te,{id:oe,type:W,params:Y==null?void 0:Y.params,title:Y==null?void 0:Y.title,contextId:de}])),Ee&&Pe?R(oe,{title:Pe.title,params:Pe.params}):!Ee&&!Ae&&ge.length<nX&&o(Fi.OpenTab,qxe(W,Y==null?void 0:Y.params)),oe},e[19]=o,e[20]=M):M=e[20];const D=M;let F;e[21]!==r||e[22]!==s||e[23]!==o?(F=W=>{const Y=s.find(oe=>oe.id===W);if(!Y)return!1;const te=()=>{l(oe=>{const de=oe.findIndex(Ee=>Ee.id===W);if(de===-1)return oe;const ge=oe.filter(Ee=>Ee.id!==W);return p(Ee=>{if(Ee===W){if(ge.length===0)return null;const Re=Math.max(0,de-1),Ae=ge[Re];return(Ae==null?void 0:Ae.id)??null}return Ee}),ge}),o(Fi.CloseTab,qxe(Y.type,Y.params))};return Y.hasUnsavedChanges?(r(te),!0):(te(),!0)},e[21]=r,e[22]=s,e[23]=o,e[24]=F):F=e[24];const I=F;let V;e[25]===Symbol.for("react.memo_cache_sentinel")?(V=W=>{l(Y=>{const te=Y.find(oe=>oe.id===W);return!te||Y.length<=1?Y:(p(W),[te])})},e[25]=V):V=e[25];const z=V;let G;e[26]===Symbol.for("react.memo_cache_sentinel")?(G=W=>{l(Y=>(Y.find(oe=>oe.id===W)&&p(W),Y))},e[26]=G):G=e[26];const H=G;let U;e[27]!==S||e[28]!==I||e[29]!==g||e[30]!==m||e[31]!==D||e[32]!==s?(U={pages:s,activePage:S,effectivePathname:g,isNotFoundRoute:m,setEffectivePathname:v,setPageUnsavedChanges:C,openPage:D,updatePage:R,closePage:I,closeOtherPages:z,setActivePage:H},e[27]=S,e[28]=I,e[29]=g,e[30]=m,e[31]=D,e[32]=s,e[33]=U):U=e[33];const k=U;let X;return e[34]!==t.children||e[35]!==k?(X=L.jsx(C4e.Provider,{value:k,children:t.children}),e[34]=t.children,e[35]=k,e[36]=X):X=e[36],X}function Ih(){var o,a,s;const t=qt.c(15),e=J.useContext(C4e);if(!e)throw new Error("usePageTabs must be used within a PageTabsProvider");let i;t[0]!==((o=e.activePage)==null?void 0:o.id)?(i=l=>{var u;return((u=e.activePage)==null?void 0:u.id)===l},t[0]=(a=e.activePage)==null?void 0:a.id,t[1]=i):i=t[1],(s=e.activePage)==null||s.id;const n=i;let r;return t[2]!==e.activePage||t[3]!==e.closeOtherPages||t[4]!==e.closePage||t[5]!==e.effectivePathname||t[6]!==e.isNotFoundRoute||t[7]!==e.openPage||t[8]!==e.pages||t[9]!==e.setActivePage||t[10]!==e.setEffectivePathname||t[11]!==e.setPageUnsavedChanges||t[12]!==e.updatePage||t[13]!==n?(r={pages:e.pages,activePage:e.activePage,effectivePathname:e.effectivePathname,isNotFoundRoute:e.isNotFoundRoute,setEffectivePathname:e.setEffectivePathname,isPageActive:n,setActivePage:e.setActivePage,closePage:e.closePage,closeOtherPages:e.closeOtherPages,setPageUnsavedChanges:e.setPageUnsavedChanges,updatePage:e.updatePage,openPage:e.openPage},t[2]=e.activePage,t[3]=e.closeOtherPages,t[4]=e.closePage,t[5]=e.effectivePathname,t[6]=e.isNotFoundRoute,t[7]=e.openPage,t[8]=e.pages,t[9]=e.setActivePage,t[10]=e.setEffectivePathname,t[11]=e.setPageUnsavedChanges,t[12]=e.updatePage,t[13]=n,t[14]=r):r=t[14],r}const T4e=J.createContext(null);function Xxe(t){const e=qt.c(6);let i;e[0]!==t.params||e[1]!==t.tabId?(i={tabId:t.tabId,params:t.params},e[0]=t.params,e[1]=t.tabId,e[2]=i):i=e[2];const n=i;let r;return e[3]!==t.children||e[4]!==n?(r=L.jsx(T4e.Provider,{value:n,children:t.children}),e[3]=t.children,e[4]=n,e[5]=r):r=e[5],r}function jne(){const t=qt.c(3),e=J.useContext(T4e);if(!e)throw new Error("usePageParams must be used within a PageParamsProvider");const i=e.params;let n;return t[0]!==i||t[1]!==e.tabId?(n={tabId:e.tabId,params:i},t[0]=i,t[1]=e.tabId,t[2]=n):n=t[2],n}const x4e=J.createContext(null);function uNt(t){const e=qt.c(11),{children:i}=t,[n,r]=J.useState(bH[0]),[o,a]=J.useState(!1);let s;e[0]===Symbol.for("react.memo_cache_sentinel")?(s=b=>{const S=bH.find(_=>_.id===b);S&&(C$(S)&&a(!1),r(_=>_.id===b?_:S))},e[0]=s):s=e[0];const l=s;let u;e[1]===Symbol.for("react.memo_cache_sentinel")?(u=b=>{const S=bH.find(_=>_.id===b);S&&r(_=>_.id!==b?S:_)},e[1]=u):u=e[1];const c=u;let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=()=>{a(dNt)},e[2]=d):d=e[2];const f=d;let h;e[3]===Symbol.for("react.memo_cache_sentinel")?(h=b=>{a(b)},e[3]=h):h=e[3];const p=h;let g;e[4]===Symbol.for("react.memo_cache_sentinel")?(g=b=>{a(!b)},e[4]=g):g=e[4];const v=g;let y;e[5]!==n||e[6]!==o?(y={contexts:bH,activeContext:n,panelCollapsed:o,setActiveContext:l,setContextActive:l,setActiveContextHighlight:c,togglePanelCollapsed:f,setPanelCollapsed:p,setContextPanelExpanded:v,isContextActive:cNt},e[5]=n,e[6]=o,e[7]=y):y=e[7];let m;return e[8]!==i||e[9]!==y?(m=L.jsx(x4e.Provider,{value:y,children:i}),e[8]=i,e[9]=y,e[10]=m):m=e[10],m}function cNt(){return!1}function dNt(t){return!t}function e2(t){const e=qt.c(32);let i;e[0]!==t?(i=t===void 0?{}:t,e[0]=t,e[1]=i):i=e[1];const n=i,{onPanelContextSelect:r,onNavigate:o}=n,a=J.useContext(x4e);if(!a)throw new Error("useContextTabs must be used within a ContextTabsProvider");const{activePage:s,pages:l,openPage:u,setActivePage:c}=Ih();let d;e[2]!==s||e[3]!==a.activeContext||e[4]!==a.panelCollapsed?(d=x=>{if(!a.panelCollapsed&&C$(a.activeContext))return a.activeContext.id===x;if(!s)return!1;const E=SG(s.type);return(E==null?void 0:E.contextId)===x},e[2]=s,e[3]=a.activeContext,e[4]=a.panelCollapsed,e[5]=d):d=e[5];const f=d;let h;e[6]!==a.contexts?(h=a.contexts.filter(hNt),e[6]=a.contexts,e[7]=h):h=e[7];const p=h;let g;e[8]!==a.contexts?(g=a.contexts.filter(fNt),e[8]=a.contexts,e[9]=g):g=e[9];const v=g;let y;e[10]!==v||e[11]!==p?(y=[...p,...v],e[10]=v,e[11]=p,e[12]=y):y=e[12];const m=y;let b;e[13]!==a||e[14]!==o||e[15]!==r||e[16]!==u||e[17]!==l||e[18]!==c?(b=x=>{var E;if(!C$(x)){const R=(E=K2t(x.id)[0])==null?void 0:E.route;if(!R)return;const M=l.find(D=>D.type===R);M?c(M.id):u(R),a.setPanelCollapsed(!0),o==null||o();return}r==null||r(x.id)},e[13]=a,e[14]=o,e[15]=r,e[16]=u,e[17]=l,e[18]=c,e[19]=b):b=e[19];const S=b;let _;e[20]!==o||e[21]!==u?(_=x=>{u(x),o==null||o()},e[20]=o,e[21]=u,e[22]=_):_=e[22];const C=_;let P;return e[23]!==s||e[24]!==m||e[25]!==v||e[26]!==a||e[27]!==S||e[28]!==C||e[29]!==f||e[30]!==p?(P={...a,isContextActive:f,mainContexts:p,bottomContexts:v,allContexts:m,handleContextClick:S,handleSubPageSelect:C,activePage:s,getIcon:dV},e[23]=s,e[24]=m,e[25]=v,e[26]=a,e[27]=S,e[28]=C,e[29]=f,e[30]=p,e[31]=P):P=e[31],P}function fNt(t){return t.position===rS.BOTTOM}function hNt(t){return t.position===rS.MAIN}function pNt(){const t=qt.c(8),{activePage:e,isNotFoundRoute:i}=Ih(),{setActiveContextHighlight:n}=e2();let r;t[0]!==e||t[1]!==i||t[2]!==n?(r=()=>{!i&&(e!=null&&e.contextId)&&n(e.contextId)},t[0]=e,t[1]=i,t[2]=n,t[3]=r):r=t[3];const o=e==null?void 0:e.contextId;let a;t[4]!==i||t[5]!==n||t[6]!==o?(a=[o,i,n],t[4]=i,t[5]=n,t[6]=o,t[7]=a):a=t[7],J.useEffect(r,a)}const gNt=History.prototype.pushState;function vNt(){const t=qt.c(14),{activePage:e,openPage:i,isNotFoundRoute:n,setEffectivePathname:r}=Ih(),o=J.useRef(!1);let a;t[0]!==i?(a=(g,v)=>{const y=Q2t(g,v);y&&y.open(i)},t[0]=i,t[1]=a):a=t[1];const s=a,l=J.useRef(!1);let u,c;t[2]!==s?(u=()=>{l.current||(l.current=!0,s(window.location.pathname,window.location.search))},c=[s],t[2]=s,t[3]=u,t[4]=c):(u=t[3],c=t[4]),J.useEffect(u,c);let d,f;t[5]!==s||t[6]!==r?(d=()=>{const g=function(){o.current||(r(window.location.pathname),s(window.location.pathname,window.location.search))};return window.addEventListener("popstate",g),()=>window.removeEventListener("popstate",g)},f=[s,r],t[5]=s,t[6]=r,t[7]=d,t[8]=f):(d=t[7],f=t[8]),J.useEffect(d,f);let h,p;t[9]!==e||t[10]!==n||t[11]!==r?(h=()=>{if(n&&e===null)return;const g=e?eNt(e):"/";if(!g)return;const v=window.location.pathname+window.location.search;if(g===v)return;o.current=!0,gNt.call(window.history,null,"",g);const y=g.split("?")[0];r(y),requestAnimationFrame(()=>{o.current=!1})},p=[e,n,r],t[9]=e,t[10]=n,t[11]=r,t[12]=h,t[13]=p):(h=t[12],p=t[13]),J.useEffect(h,p)}function yNt(t){const e=qt.c(2);vNt(),pNt();let i;return e[0]!==t.children?(i=L.jsx(L.Fragment,{children:t.children}),e[0]=t.children,e[1]=i):i=e[1],i}function mNt(t){const e=qt.c(2),{children:i}=t;let n;return e[0]!==i?(n=L.jsx(uNt,{children:L.jsx(tNt,{children:L.jsx(lNt,{children:L.jsx(yNt,{children:i})})})}),e[0]=i,e[1]=n):n=e[1],n}function bNt(t){const e=qt.c(13),{openPage:i}=Ih();let n;e[0]===Symbol.for("react.memo_cache_sentinel")?(n=L.jsx("p",{className:"text-8xl font-bold text-muted-foreground/20",children:"404"}),e[0]=n):n=e[0];let r;e[1]!==t.title?(r=L.jsx("h1",{className:"text-2xl font-bold text-foreground",children:t.title}),e[1]=t.title,e[2]=r):r=e[2];let o;e[3]!==t.description?(o=L.jsx("p",{className:"text-muted-foreground max-w-md",children:t.description}),e[3]=t.description,e[4]=o):o=e[4];let a;e[5]!==r||e[6]!==o?(a=L.jsxs("div",{className:"space-y-2",children:[r,o]}),e[5]=r,e[6]=o,e[7]=a):a=e[7];let s;e[8]!==i?(s=L.jsx(Za,{onClick:()=>{i(Nu.OVERVIEW)},label:"Back to overview",type:fn.PRIMARY}),e[8]=i,e[9]=s):s=e[9];let l;return e[10]!==a||e[11]!==s?(l=L.jsxs("div",{className:"flex flex-col items-center justify-center text-center gap-6 min-h-[60vh]",children:[n,a,s]}),e[10]=a,e[11]=s,e[12]=l):l=e[12],l}class SNt extends J.Component{constructor(e){super(e),this.state={error:null}}static getDerivedStateFromError(e){return{error:e}}render(){return this.state.error?this.props.fallback(this.state.error):this.props.children}}function _Nt(t){const e=qt.c(13);let i;e[0]!==t.onContextSelect?(i={onPanelContextSelect:t.onContextSelect},e[0]=t.onContextSelect,e[1]=i):i=e[1];const{handleContextClick:n,isContextActive:r,getIcon:o}=e2(i);let a;if(e[2]!==o||e[3]!==n||e[4]!==r||e[5]!==t.contexts){const s=t.contexts.filter(CNt),l=t.contexts.filter(PNt);let u;e[7]!==o||e[8]!==n||e[9]!==r?(u=v=>{const y=o(v.icon),m=r(v.id);return L.jsx(hke,{label:v.label,side:"right",children:L.jsx("button",{onClick:()=>n(v),className:Hr("w-10 h-10 rounded-md flex items-center justify-center transition-all duration-200","hover:bg-white/10 hover:shadow-sm",m?"bg-white/15 text-white shadow-sm":"text-green-400"),"data-testid":`context-tab-${v.id}`,"data-context":v.id,"data-active":m,children:L.jsx(Wr,{type:y,className:"w-5 h-5"})})},v.id)},e[7]=o,e[8]=n,e[9]=r,e[10]=u):u=e[10];const c=u,d=()=>L.jsx("div",{className:"flex flex-col gap-1",children:s.map(c)}),f=()=>L.jsx("div",{className:"flex flex-col gap-1 items-center",children:l.map(c)});let h;e[11]===Symbol.for("react.memo_cache_sentinel")?(h=L.jsx("div",{className:"p-2 mb-4",children:L.jsx("div",{className:"w-8 h-8 rounded-md flex items-center justify-center",children:L.jsx("img",{src:"/images/remotivelabs-logo_icon-neg_low.png",alt:"RemotiveStudio",className:"w-full h-full"})})}),e[11]=h):h=e[11];const p=h;let g;e[12]===Symbol.for("react.memo_cache_sentinel")?(g=L.jsx("div",{className:"flex-1"}),e[12]=g):g=e[12],a=L.jsxs("div",{className:"flex flex-col items-center gap-1 py-2 w-14 text-white/80",children:[p,d(),g,f()]}),e[2]=o,e[3]=n,e[4]=r,e[5]=t.contexts,e[6]=a}else a=e[6];return a}function PNt(t){return t.position===rS.BOTTOM}function CNt(t){return t.position===rS.MAIN}const TNt=224,xNt=140,ENt=800;function wNt(t){var I,V,z;const e=qt.c(34),{togglePanelCollapsed:i}=e2(),[n,r]=J.useState(TNt),[o,a]=J.useState(!1),s=J.useRef(null),l=(I=t.activeContext)==null?void 0:I.id;let u;e[0]===Symbol.for("react.memo_cache_sentinel")?(u=G=>{G.preventDefault(),a(!0)},e[0]=u):u=e[0];const c=u;let d,f;e[1]!==o?(d=()=>{if(!o)return;const G=U=>{if(!s.current)return;const k=s.current.getBoundingClientRect(),X=U.clientX-k.left;r(Math.max(xNt,Math.min(ENt,X)))},H=()=>{a(!1)};return document.addEventListener("mousemove",G),document.addEventListener("mouseup",H),()=>{document.removeEventListener("mousemove",G),document.removeEventListener("mouseup",H)}},f=[o],e[1]=o,e[2]=d,e[3]=f):(d=e[2],f=e[3]),J.useEffect(d,f);let h;e[4]!==t.collapsed?(h=()=>!t.collapsed&&L.jsx("div",{onMouseDown:c,className:`absolute top-0 right-0 w-2 h-full cursor-ew-resize 
            hover:bg-white/20 active:bg-white/20 transition-colors`}),e[4]=t.collapsed,e[5]=h):h=e[5];const p=h;let g;e[6]!==i?(g=()=>L.jsx(hke,{label:"Collapse panel",side:"right",children:L.jsx("button",{onClick:i,className:"p-1 rounded-sm hover:bg-white/10 transition-colors",children:L.jsx(Wr,{type:dr.PANEL_LEFT_CLOSE,className:"w-5 h-5 text-white/90"})})}),e[6]=i,e[7]=g):g=e[7];const v=g;let y;e[8]!==v||e[9]!==l||e[10]!==((V=t.activeContext)==null?void 0:V.label)?(y=()=>{var G;switch(l){case qs.TOPOLOGY:case qs.FILES:return L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-sm font-semibold text-white capitalize",children:((G=t.activeContext)==null?void 0:G.label)||l}),v()]});default:return L.jsx(L.Fragment,{})}},e[8]=v,e[9]=l,e[10]=(z=t.activeContext)==null?void 0:z.label,e[11]=y):y=e[11];const m=y;let b;e[12]!==l?(b=()=>{switch(l){case qs.TOPOLOGY:return L.jsx(bHe,{});case qs.FILES:return L.jsx(Jwe,{});default:return L.jsx(L.Fragment,{})}},e[12]=l,e[13]=b):b=e[13];const S=b,_=`relative transition-[width] overflow-hidden
        ${t.collapsed?"w-0":""}
        ${o?"duration-0":"duration-300 ease-in-out"}`,C=t.collapsed?0:n;let P;e[14]!==C?(P={width:C},e[14]=C,e[15]=P):P=e[15];const x=t.collapsed;let E;e[16]!==n?(E={width:n},e[16]=n,e[17]=E):E=e[17];let A;e[18]!==m?(A=L.jsx("div",{className:"ps-3 pe-3 pt-3 pb-2 flex items-center justify-between",children:m()}),e[18]=m,e[19]=A):A=e[19];let R;e[20]!==S?(R=L.jsx("div",{className:"flex-1 overflow-auto",children:L.jsx("div",{className:"min-w-max",children:S()})}),e[20]=S,e[21]=R):R=e[21];let M;e[22]!==E||e[23]!==A||e[24]!==R?(M=L.jsxs("div",{className:"h-full border-s border-white/10 flex flex-col text-white/80",style:E,children:[A,R]}),e[22]=E,e[23]=A,e[24]=R,e[25]=M):M=e[25];let D;e[26]!==p?(D=p(),e[26]=p,e[27]=D):D=e[27];let F;return e[28]!==t.collapsed||e[29]!==M||e[30]!==D||e[31]!==_||e[32]!==P?(F=L.jsxs("div",{ref:s,className:_,style:P,"data-testid":"context-panel","data-collapsed":x,children:[M,D]}),e[28]=t.collapsed,e[29]=M,e[30]=D,e[31]=_,e[32]=P,e[33]=F):F=e[33],F}function ANt(){const t=qt.c(14),{contexts:e,activeContext:i,panelCollapsed:n,setActiveContext:r}=e2();let o;t[0]!==i||t[1]!==n?(o=C$(i)&&!n,t[0]=i,t[1]=n,t[2]=o):o=t[2];const a=o;let s,l;t[3]===Symbol.for("react.memo_cache_sentinel")?(s=Hr("flex h-full rounded-md overflow-hidden shrink-0","bg-[radial-gradient(183.91%_56.41%_at_13.33%_6.53%,#05345a_13.13%,#001324_93.52%)]","dark:bg-[radial-gradient(183.91%_56.41%_at_13.33%_6.53%,#222222_13.13%,#10121c_93.52%)]","border border-border/70"),l={boxShadow:"var(--shadow-sidebar)"},t[3]=s,t[4]=l):(s=t[3],l=t[4]);let u;t[5]!==e||t[6]!==r?(u=L.jsx(_Nt,{contexts:e,onContextSelect:r}),t[5]=e,t[6]=r,t[7]=u):u=t[7];const c=!a;let d;t[8]!==i||t[9]!==c?(d=L.jsx(wNt,{activeContext:i,collapsed:c}),t[8]=i,t[9]=c,t[10]=d):d=t[10];let f;return t[11]!==u||t[12]!==d?(f=L.jsxs("div",{className:s,style:l,"data-testid":"sidebar",children:[u,d]}),t[11]=u,t[12]=d,t[13]=f):f=t[13],f}const E4e=50,ONt=50,w4e=80,DNt=`calc(100vh - ${w4e}px)`,RNt=`calc(100vh - ${w4e+ONt}px)`;function MNt(t){const e=qt.c(21),[i,n]=J.useState(null);let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=()=>n(null),e[0]=r):r=e[0];const{contexts:o,allContexts:a,setActiveContext:s,handleContextClick:l,isContextActive:u,getIcon:c}=e2({onPanelContextSelect:m=>{i===m?n(null):(n(m),d(m))},onNavigate:r}),d=s;let f;if(e[1]!==o||e[2]!==i){let m;e[4]!==i?(m=b=>b.id===i,e[4]=i,e[5]=m):m=e[5],f=o.find(m),e[1]=o,e[2]=i,e[3]=f}else f=e[3];const h=f,p=h&&(h.id===qs.FILES||h.id===qs.TOPOLOGY);let g;e[6]!==(h==null?void 0:h.label)||e[7]!==i||e[8]!==p||e[9]!==t.gap?(g=()=>L.jsxs(L.Fragment,{children:[p&&L.jsx("div",{className:"fixed inset-0 bg-black/50 backdrop-blur-sm z-40 transition-opacity duration-300",onClick:()=>n(null)}),L.jsx("div",{className:Hr("fixed z-50","transition-all duration-300 ease-out",p?"opacity-100 translate-y-0":"opacity-0 translate-y-full pointer-events-none"),style:{left:t.gap,right:t.gap,bottom:E4e+t.gap},children:L.jsxs("div",{className:Hr("rounded-t-md overflow-hidden","bg-black/80","border border-white/40","shadow-2xl"),style:{maxHeight:DNt},children:[L.jsxs("div",{className:"flex items-center justify-between px-4 py-3 border-b border-white/10",children:[L.jsx("h2",{className:"text-sm font-semibold text-white capitalize",children:h==null?void 0:h.label}),L.jsx("button",{onClick:()=>n(null),className:"w-8 h-8 flex items-center justify-center text-white/60 hover:bg-white/10 hover:text-white transition-colors",children:L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:"w-5 h-5"})})]}),L.jsxs("div",{className:"overflow-auto text-white/80",style:{maxHeight:RNt},children:[i===qs.TOPOLOGY&&L.jsx(bHe,{className:"px-4 py-3 gap-3"}),i===qs.FILES&&L.jsx("div",{className:"px-2 py-2",children:L.jsx(Jwe,{})})]})]})})]}),e[6]=h==null?void 0:h.label,e[7]=i,e[8]=p,e[9]=t.gap,e[10]=g):g=e[10];const v=g;let y;if(e[11]!==a||e[12]!==v||e[13]!==c||e[14]!==l||e[15]!==p||e[16]!==u||e[17]!==t.gap){const m=()=>L.jsx(L.Fragment,{children:L.jsx("div",{className:Hr("fixed bottom-0 z-50","bg-[radial-gradient(183.91%_56.41%_at_50%_0%,#05345a_13.13%,#001324_93.52%)]","dark:bg-[radial-gradient(183.91%_56.41%_at_50%_0%,#222222_13.13%,#10121c_93.52%)]",p?"rounded-b-md":"rounded-md","safe-area-inset-bottom","border border-white/20 "),style:{left:t.gap,right:t.gap,bottom:t.gap,boxShadow:"0 -4px 20px rgba(0, 0, 0, 0.3)",paddingBottom:"env(safe-area-inset-bottom, 0px)"},"data-testid":"mobile-sidebar",children:L.jsx("div",{className:"flex items-center justify-center px-1",children:a.map(b)})})}),b=_=>{const C=c(_.icon),P=u(_.id);return L.jsxs("button",{onClick:()=>l(_),className:Hr("flex flex-col items-center justify-center gap-0.5 min-w-[64px]","transition-all duration-200","active:scale-95"," m-0 p-1",P?"text-white":"text-green-400",P?"bg-white/15 shadow-sm":"hover:bg-white/10"),"data-testid":`mobile-context-tab-${_.id}`,"data-context":_.id,"data-active":P,children:[L.jsx("div",{className:Hr("w-6 h-6 flex items-center justify-center transition-all duration-200"),children:L.jsx(Wr,{type:C,className:"w-4 h-4"})}),L.jsx("span",{className:"text-[10px] text-white font-medium",children:_.label})]},_.id)};let S;e[19]!==v?(S=v(),e[19]=v,e[20]=S):S=e[20],y=L.jsxs(L.Fragment,{children:[S,m()]}),e[11]=a,e[12]=v,e[13]=c,e[14]=l,e[15]=p,e[16]=u,e[17]=t.gap,e[18]=y}else y=e[18];return y}const LNt={"not-found":"SECURITY_LOCK",overview:"CONTEXT_HOME",files:"CONTEXT_FILES",dashboard:"CONTEXT_DASHBOARD",topology:"CONTEXT_TOPOLOGY",settings:"CONTEXT_SETTINGS",about:"CONTEXT_ABOUT"};function kNt(t){return t.includes(":")?t:t.replace(/^\//,"").replace(/\//g,"-")}function INt(t){const e=qt.c(41),i=J.useRef(null);let n,r;e[0]!==t.isActive?(n=()=>{t.isActive&&i.current&&i.current.scrollIntoView({behavior:"smooth",block:"nearest",inline:"nearest"})},r=[t.isActive],e[0]=t.isActive,e[1]=n,e[2]=r):(n=e[1],r=e[2]),J.useEffect(n,r);let o;e[3]!==t?(o=z=>{z.preventDefault(),z.stopPropagation(),t.onClose()},e[3]=t,e[4]=o):o=e[4];const a=o;let s;e[5]!==t.tab.type?(s=SG(t.tab.type),e[5]=t.tab.type,e[6]=s):s=e[6];const l=s;let u;e[7]!==l?(u=l!=null&&l.contextId?dV(LNt[l.contextId]):null,e[7]=l,e[8]=u):u=e[8];const c=u,d=t.tab.title??(l==null?void 0:l.title)??"Page";let f;e[9]!==t.tab.id?(f=kNt(t.tab.id),e[9]=t.tab.id,e[10]=f):f=e[10];const h=f,p=t.tab.hasUnsavedChanges??!1,g=t.onSelect,v=t.isActive?"bg-topbar-tab-active text-topbar-tab-active-foreground shadow-sm":"bg-topbar-tab text-topbar-tab-foreground hover:bg-topbar-tab-hover hover:text-topbar-foreground";let y;e[11]!==v?(y=Hr("group flex items-center gap-1.5 px-2 h-7 cursor-pointer transition-all duration-200 rounded-sm min-w-30 relative select-none no-underline",v),e[11]=v,e[12]=y):y=e[12];const m=`page-tab-${h}`,b=t.isActive;let S;e[13]!==c?(S=c&&L.jsx(Wr,{type:c,className:"w-3.5 h-3.5 flex-shrink-0 opacity-70"}),e[13]=c,e[14]=S):S=e[14];const _=p&&"italic pe-0.5";let C;e[15]!==_?(C=Hr("text-xs font-medium truncate",_),e[15]=_,e[16]=C):C=e[16];let P;e[17]!==C||e[18]!==d?(P=L.jsx("span",{className:C,children:d}),e[17]=C,e[18]=d,e[19]=P):P=e[19];let x;e[20]!==p?(x=p&&L.jsx("span",{className:"absolute w-2 h-2 rounded-full bg-white pointer-events-none group-hover:opacity-0 transition-opacity duration-150"}),e[20]=p,e[21]=x):x=e[21];const E=t.isActive&&"hover:bg-white/20",A=(p||!t.isActive)&&"opacity-0 group-hover:opacity-100";let R;e[22]!==E||e[23]!==A?(R=Hr("p-0.5 rounded transition-all duration-150","hover:bg-white/60 dark:hover:bg-white/20",E,A),e[22]=E,e[23]=A,e[24]=R):R=e[24];const M=`page-tab-close-${h}`;let D;e[25]===Symbol.for("react.memo_cache_sentinel")?(D=L.jsx(Wr,{type:dr.ACTION_CLOSE,className:"w-3 h-3"}),e[25]=D):D=e[25];let F;e[26]!==a||e[27]!==R||e[28]!==M?(F=L.jsx("button",{type:"button",onClick:a,onMouseDown:NNt,className:R,"data-testid":M,children:D}),e[26]=a,e[27]=R,e[28]=M,e[29]=F):F=e[29];let I;e[30]!==x||e[31]!==F?(I=L.jsxs("div",{className:"flex-shrink-0 relative w-4 h-4 flex items-center justify-center",children:[x,F]}),e[30]=x,e[31]=F,e[32]=I):I=e[32];let V;return e[33]!==t.isActive||e[34]!==t.onSelect||e[35]!==S||e[36]!==P||e[37]!==I||e[38]!==y||e[39]!==m?(V=L.jsxs("div",{ref:i,onClick:g,className:y,"data-testid":m,"data-active":b,children:[S,P,I]}),e[33]=t.isActive,e[34]=t.onSelect,e[35]=S,e[36]=P,e[37]=I,e[38]=y,e[39]=m,e[40]=V):V=e[40],V}function NNt(t){return t.stopPropagation()}function FNt(){const t=qt.c(11),{pages:e,activePage:i,setActivePage:n,closePage:r}=Ih();let o;if(t[0]!==(i==null?void 0:i.id)||t[1]!==r||t[2]!==e||t[3]!==n){let s;t[5]!==(i==null?void 0:i.id)||t[6]!==r||t[7]!==n?(s=l=>L.jsx(INt,{tab:l,isActive:l.id===(i==null?void 0:i.id),onSelect:()=>n(l.id),onClose:()=>r(l.id)},l.id),t[5]=i==null?void 0:i.id,t[6]=r,t[7]=n,t[8]=s):s=t[8],o=e.map(s),t[0]=i==null?void 0:i.id,t[1]=r,t[2]=e,t[3]=n,t[4]=o}else o=t[4];let a;return t[9]!==o?(a=L.jsx("div",{className:"flex items-center gap-1 h-full px-1 pr-3 flex-nowrap w-full","data-testid":"page-tabs",children:o}),t[9]=o,t[10]=a):a=t[10],a}const A4e=J.createContext(null);class BNt{constructor(e){Go(this,"studioBackendUrl");this.studioBackendUrl=e.endsWith("/")?e.slice(0,-1):e}async getCurrentUser(){try{const e=await fetch(`${this.studioBackendUrl}/auth/whoami`);return e.ok?await e.json():(console.error(`Failed to fetch user info: ${e.status}`),null)}catch(e){return console.error("Error fetching current user:",e),null}}}function jNt(t){const e=qt.c(2);let i;return e[0]!==t?(i=new BNt(t),e[0]=t,e[1]=i):i=e[1],i}function VNt(t){const e=qt.c(14),{environment:i}=Lp(),{identify:n}=el(),r=jNt(i.studioBackendUrl),[o,a]=J.useState(null),[s,l]=J.useState(!0);let u;e[0]!==i.authMode||e[1]!==n||e[2]!==r?(u=()=>{let p=!0;return async function(){if(i.authMode){const y=await r.getCurrentUser();p&&(y&&n(y.uid,y.email),a(y),l(!1))}else a(null),l(!1)}(),()=>{p=!1}},e[0]=i.authMode,e[1]=n,e[2]=r,e[3]=u):u=e[3];let c;e[4]!==i||e[5]!==n||e[6]!==r?(c=[r,i,n],e[4]=i,e[5]=n,e[6]=r,e[7]=c):c=e[7],J.useEffect(u,c);let d;e[8]!==s||e[9]!==o?(d={user:o,isLoading:s},e[8]=s,e[9]=o,e[10]=d):d=e[10];const f=d;let h;return e[11]!==t.children||e[12]!==f?(h=L.jsx(A4e.Provider,{value:f,children:t.children}),e[11]=t.children,e[12]=f,e[13]=h):h=e[13],h}function HNt(){const t=J.useContext(A4e);if(!t)throw new Error("useUser must be used within a UserProvider");return t}function UNt(t){const e=qt.c(20),{user:i,onClose:n,show:r}=t;let o;e[0]!==i.familyName||e[1]!==i.givenName?(o=[i.givenName,i.familyName],e[0]=i.familyName,e[1]=i.givenName,e[2]=o):o=e[2];const a=o.join(" ");let s;e[3]!==a||e[4]!==i.email?(s=()=>L.jsxs(L.Fragment,{children:[L.jsx("h2",{className:"text-lg font-semibold text-neutral-900 dark:text-white",children:a}),L.jsx("p",{className:"text-sm text-neutral-500 dark:text-neutral-400 mt-1",children:i.email})]}),e[3]=a,e[4]=i.email,e[5]=s):s=e[5];const l=s;let u;e[6]!==a||e[7]!==i.picture?(u=()=>L.jsx(L.Fragment,{children:i.picture?L.jsx("img",{src:i.picture,alt:a,className:"w-20 h-20 rounded-full mb-4 object-cover shadow-lg"}):L.jsx("div",{className:Hr("w-20 h-20 rounded-full mb-4","bg-gradient-to-br from-green-400 to-emerald-600","flex items-center justify-center","shadow-lg"),children:L.jsx(Wr,{type:dr.USER_PROFILE,className:"w-10 h-10 text-white"})})}),e[6]=a,e[7]=i.picture,e[8]=u):u=e[8];const c=u;let d;e[9]!==c?(d=c(),e[9]=c,e[10]=d):d=e[10];let f;e[11]!==l?(f=l(),e[11]=l,e[12]=f):f=e[12];let h;e[13]!==d||e[14]!==f?(h=L.jsx("div",{className:"p-6 pb-5",children:L.jsxs("div",{className:"flex flex-col items-center text-center",children:[d,f]})}),e[13]=d,e[14]=f,e[15]=h):h=e[15];let p;return e[16]!==n||e[17]!==r||e[18]!==h?(p=L.jsx(yI,{show:r,onClose:n,size:"sm",children:h}),e[16]=n,e[17]=r,e[18]=h,e[19]=p):p=e[19],p}const Kxe=200,Zxe=Hr("flex items-center gap-2 px-3 py-2","text-xs text-neutral-700 dark:text-neutral-200","hover:bg-neutral-100 dark:hover:bg-neutral-700","transition-colors");function zNt(t){const e=qt.c(8),{dropdownRef:i,position:n,children:r}=t;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o=Hr("fixed z-[9999]","min-w-[200px] py-1","bg-white dark:bg-neutral-800","border border-neutral-200 dark:border-neutral-700","rounded-md shadow-lg","animate-fade-in"),e[0]=o):o=e[0];let a;e[1]!==n.left||e[2]!==n.top?(a={top:n.top,left:n.left},e[1]=n.left,e[2]=n.top,e[3]=a):a=e[3];let s;return e[4]!==r||e[5]!==i||e[6]!==a?(s=zf.createPortal(L.jsx("div",{ref:i,className:o,style:a,children:r}),document.body),e[4]=r,e[5]=i,e[6]=a,e[7]=s):s=e[7],s}function $Nt(t){const e=qt.c(50),i=t.compact??!1,{user:n,isLoading:r}=HNt(),[o,a]=J.useState(!1),[s,l]=J.useState(!1),[u,c]=J.useState(null),d=J.useRef(null),f=J.useRef(null),h=!!n;let p;e[0]!==(n==null?void 0:n.email)||e[1]!==(n==null?void 0:n.givenName)?(p=(n==null?void 0:n.givenName)||(n==null?void 0:n.email.split("@")[0]),e[0]=n==null?void 0:n.email,e[1]=n==null?void 0:n.givenName,e[2]=p):p=e[2];const g=p;let v,y;e[3]!==o?(v=()=>{if(o&&d.current){const G=d.current.getBoundingClientRect();let H=G.right-Kxe;H<8&&(H=8),c({top:G.bottom+4,left:H})}},y=[o],e[3]=o,e[4]=v,e[5]=y):(v=e[4],y=e[5]),J.useEffect(v,y);let m,b;e[6]!==o?(m=()=>{const G=function(U){const k=U.target;d.current&&!d.current.contains(k)&&f.current&&!f.current.contains(k)&&a(!1)};if(o)return document.addEventListener("mousedown",G),()=>document.removeEventListener("mousedown",G)},b=[o],e[6]=o,e[7]=m,e[8]=b):(m=e[7],b=e[8]),J.useEffect(m,b);let S;e[9]===Symbol.for("react.memo_cache_sentinel")?(S=()=>{a(!1),l(!0)},e[9]=S):S=e[9];const _=S;if(r){const G=i?"w-12":"w-24";let H;e[10]!==G?(H=Hr("flex items-center gap-1.5 h-7 my-auto rounded-sm","bg-neutral-200/80 dark:bg-neutral-800/40","border border-neutral-300/50 dark:border-neutral-700/50","animate-pulse","px-1",G),e[10]=G,e[11]=H):H=e[11];let U;e[12]===Symbol.for("react.memo_cache_sentinel")?(U=L.jsx("div",{className:"w-5 h-5 rounded-md bg-neutral-300 dark:bg-neutral-700"}),e[12]=U):U=e[12];let k;return e[13]!==H?(k=L.jsx("div",{className:H,children:U}),e[13]=H,e[14]=k):k=e[14],k}let C;e[15]!==o?(C=()=>a(!o),e[15]=o,e[16]=C):C=e[16];let P;e[17]!==i||e[18]!==h?(P=Hr("flex items-center gap-1.5 h-7 my-auto rounded-sm","transition-colors cursor-pointer",h?["bg-green-200/80 dark:bg-green-900/40","border border-green-300/50 dark:border-green-700/50","hover:bg-green-300/80 dark:hover:bg-green-800/50","px-1"]:["bg-neutral-200/80 dark:bg-neutral-800/40","border border-neutral-300/50 dark:border-neutral-700/50","hover:bg-neutral-300/80 dark:hover:bg-neutral-700/50",i?"px-2":"px-3"]),e[17]=i,e[18]=h,e[19]=P):P=e[19];let x;e[20]!==g||e[21]!==h||e[22]!==n?(x=n!=null&&n.picture?L.jsx("img",{src:n.picture,alt:g,className:"w-5 h-5 rounded-md object-cover"}):L.jsx("div",{className:Hr("flex items-center justify-center w-5 h-5 rounded-md",h?"bg-green-300 dark:bg-green-700":"bg-neutral-300 dark:bg-neutral-700"),children:L.jsx(Wr,{type:dr.USER_PROFILE,className:Hr("w-3 h-3",h?"text-green-700 dark:text-green-200":"text-neutral-500 dark:text-neutral-400")})}),e[20]=g,e[21]=h,e[22]=n,e[23]=x):x=e[23];let E;e[24]!==i||e[25]!==g||e[26]!==h?(E=!i&&L.jsx("span",{className:Hr(`text-xs truncate max-w-[${Kxe}px]`,h?"text-green-800 dark:text-green-200":"text-neutral-600 dark:text-neutral-400"),children:g??"Not signed in"}),e[24]=i,e[25]=g,e[26]=h,e[27]=E):E=e[27];const A=h?"text-green-700 dark:text-green-300":"text-neutral-500 dark:text-neutral-400",R=o&&"rotate-180";let M;e[28]!==A||e[29]!==R?(M=Hr("w-3 h-3 transition-transform",A,R),e[28]=A,e[29]=R,e[30]=M):M=e[30];let D;e[31]!==M?(D=L.jsx(Wr,{type:dr.NAV_CHEVRON_DOWN,className:M}),e[31]=M,e[32]=D):D=e[32];let F;e[33]!==D||e[34]!==C||e[35]!==P||e[36]!==x||e[37]!==E?(F=L.jsxs("button",{ref:d,onClick:C,className:P,children:[x,E,D]}),e[33]=D,e[34]=C,e[35]=P,e[36]=x,e[37]=E,e[38]=F):F=e[38];let I;e[39]!==o||e[40]!==h||e[41]!==u?(I=o&&u&&L.jsxs(zNt,{dropdownRef:f,position:u,children:[h&&L.jsxs("button",{onClick:_,className:Hr(Zxe,"w-full text-left"),children:[L.jsx(Wr,{type:dr.USER_PROFILE_CIRCLE,className:"w-4 h-4 text-neutral-500 dark:text-neutral-400"}),"Profile information"]}),L.jsxs("a",{href:"https://cloud.remotivelabs.com",target:"_blank",rel:"noopener noreferrer",onClick:()=>a(!1),className:Zxe,children:[L.jsx(Wr,{type:dr.ACTION_EXTERNAL_LINK,className:"w-4 h-4 text-neutral-500 dark:text-neutral-400"}),"Go to RemotiveCloud"]})]}),e[39]=o,e[40]=h,e[41]=u,e[42]=I):I=e[42];let V;e[43]!==s||e[44]!==n?(V=n&&L.jsx(UNt,{show:s,user:n,onClose:()=>l(!1)}),e[43]=s,e[44]=n,e[45]=V):V=e[45];let z;return e[46]!==F||e[47]!==I||e[48]!==V?(z=L.jsxs(L.Fragment,{children:[F,I,V]}),e[46]=F,e[47]=I,e[48]=V,e[49]=z):z=e[49],z}const WNt="flex items-center justify-center h-7 w-7 my-auto rounded-sm border px-1",GNt=()=>{const t=qt.c(14),{connectedBroker:e}=F6(),{environment:i}=Lp();let n;t[0]!==(e==null?void 0:e.grpcUrl)||t[1]!==i?(n=v=>L.jsxs("div",{className:"text-xs p-1 flex flex-col gap-0.5",children:[L.jsx("div",{className:"font-semibold",children:"RemotiveBroker"}),L.jsx("span",{className:"font-mono text-[11px]",children:v?(e==null?void 0:e.grpcUrl)||"":i.brokerUrl||"—"}),L.jsx("div",{className:"text-muted-foreground flex items-center gap-1.5 mt-0.5",children:v?L.jsxs(L.Fragment,{children:[L.jsx(Wr,{type:dr.SYSTEM_WIFI,className:"w-3.5 h-3.5 text-green-500"}),L.jsx("span",{children:"Connected"})]}):L.jsxs(L.Fragment,{children:[L.jsx(Wr,{type:dr.SYSTEM_WIFI_OFF,className:"w-3.5 h-3.5 text-red-500"}),L.jsx("span",{children:"Disconnected"})]})})]}),t[0]=e==null?void 0:e.grpcUrl,t[1]=i,t[2]=n):n=t[2];const r=n,o=e!==void 0;let a;t[3]!==o||t[4]!==r?(a=r(o),t[3]=o,t[4]=r,t[5]=a):a=t[5];const s=a,l=e?dr.SYSTEM_WIFI:dr.SYSTEM_WIFI_OFF,f=`${WNt} ${e?"dark:bg-green-500/20 bg-green-500/30 border-green-300/50 dark:border-green-700/50":"dark:bg-red-600/20 bg-red-500/30 border-red-300/50 dark:border-red-700/50"} ${e?"border-green-300/50 dark:border-green-700/50":"border-red-300/50 dark:border-red-700/50"} ${e?"text-green-600 dark:text-green-500":"text-red-700 dark:text-red-600"}`;let h;t[6]!==l?(h=L.jsx(Wr,{type:l,className:"w-4 h-4"}),t[6]=l,t[7]=h):h=t[7];let p;t[8]!==f||t[9]!==h?(p=L.jsx("div",{className:f,children:h}),t[8]=f,t[9]=h,t[10]=p):p=t[10];let g;return t[11]!==s||t[12]!==p?(g=L.jsx("div",{className:"flex items-center",children:L.jsx(FD,{content:s,children:p})}),t[11]=s,t[12]=p,t[13]=g):g=t[13],g};function YNt(){const t=qt.c(5),e=qNe();let i;t[0]===Symbol.for("react.memo_cache_sentinel")?(i={boxShadow:"var(--shadow-topbar)"},t[0]=i):i=t[0];let n;t[1]===Symbol.for("react.memo_cache_sentinel")?(n=L.jsx("div",{className:"flex-1 min-w-0 h-full overflow-x-auto overflow-y-hidden scrollbar-thin",children:L.jsx(FNt,{})}),t[1]=n):n=t[1];let r;t[2]===Symbol.for("react.memo_cache_sentinel")?(r=L.jsx(GNt,{}),t[2]=r):r=t[2];let o;return t[3]!==e?(o=L.jsxs("div",{className:"flex items-center h-10 w-full max-w-full bg-topbar text-topbar-foreground rounded-md rounded-b-none overflow-hidden border border-b-0",style:i,"data-testid":"top-bar",children:[n,L.jsx("div",{className:"flex-shrink-0 px-1 border-s",children:L.jsxs("div",{className:"flex items-center gap-1",children:[r,L.jsx($Nt,{compact:e})]})})]}),t[3]=e,t[4]=o):o=t[4],o}function qNt(){const t=qt.c(9),{pages:e,activePage:i,isNotFoundRoute:n}=Ih();if(n){let a;return t[0]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(G2t,{}),t[0]=a):a=t[0],a}if(e.length===0){let a;return t[1]===Symbol.for("react.memo_cache_sentinel")?(a=L.jsx(ywe,{}),t[1]=a):a=t[1],a}let r;if(t[2]!==(i==null?void 0:i.id)||t[3]!==e){let a;t[5]!==(i==null?void 0:i.id)?(a=s=>{const l=SG(s.type);if(!l)return null;const u=l.component,c=s.id===(i==null?void 0:i.id);return J2t(s)?L.jsx("div",{className:"flex-1 min-h-0 flex flex-col",style:{display:c?"block":"none"},children:L.jsx(Xxe,{tabId:s.id,params:s.params,children:L.jsx(u,{})})},s.id):L.jsx(J.Activity,{mode:c?"visible":"hidden",children:L.jsx(Xxe,{tabId:s.id,params:s.params,children:L.jsx(u,{})})},s.id)},t[5]=i==null?void 0:i.id,t[6]=a):a=t[6],r=e.map(a),t[2]=i==null?void 0:i.id,t[3]=e,t[4]=r}else r=t[4];let o;return t[7]!==r?(o=L.jsx(L.Fragment,{children:r}),t[7]=r,t[8]=o):o=t[8],o}const Kb=6,XNt=E4e+Kb+7;function KNt(){const t=qt.c(28),e=qNe();let i;t[0]!==e?(i=e?{paddingTop:Kb,paddingLeft:Kb,paddingRight:Kb,paddingBottom:0}:{padding:Kb,gap:Kb},t[0]=e,t[1]=i):i=t[1];const n=i,r=e?"h-screen flex-col min-h-0":"h-screen flex-row";let o;t[2]!==r?(o=Hr("w-screen flex",r),t[2]=r,t[3]=o):o=t[3];let a;t[4]!==e?(a=!e&&L.jsx("div",{className:Hr(`shrink-0 sticky top-[${Kb}px] h-[calc(100vh-${Kb*2}px)]`),children:L.jsx(ANt,{})}),t[4]=e,t[5]=a):a=t[5];const s=e&&"min-h-0";let l;t[6]!==s?(l=Hr("flex-1 min-w-0 flex flex-col",s),t[6]=s,t[7]=l):l=t[7];let u,c,d;t[8]===Symbol.for("react.memo_cache_sentinel")?(u={boxShadow:"var(--shadow-page)"},c=L.jsx("div",{className:Hr("shrink-0 z-10 w-full max-w-full"),children:L.jsx(YNt,{})}),d=Hr("flex-1 min-h-0 flex flex-col bg-background rounded-md rounded-t-none border border-border/100 overflow-auto"),t[8]=u,t[9]=c,t[10]=d):(u=t[8],c=t[9],d=t[10]);const f=e?XNt:void 0,h=e?"env(safe-area-inset-bottom, 0px)":void 0;let p;t[11]!==h||t[12]!==f?(p={marginBottom:f,paddingBottom:h},t[11]=h,t[12]=f,t[13]=p):p=t[13];let g;t[14]===Symbol.for("react.memo_cache_sentinel")?(g=L.jsx("div",{className:"flex-1 min-h-0 flex flex-col",children:L.jsx(qNt,{})}),t[14]=g):g=t[14];let v;t[15]!==p?(v=L.jsx("main",{className:d,style:p,"data-testid":"page-view",children:g}),t[15]=p,t[16]=v):v=t[16];let y;t[17]!==v||t[18]!==l?(y=L.jsxs("div",{className:l,style:u,children:[c,v]}),t[17]=v,t[18]=l,t[19]=y):y=t[19];let m;t[20]!==e?(m=e&&L.jsx(MNt,{gap:Kb}),t[20]=e,t[21]=m):m=t[21];let b;return t[22]!==n||t[23]!==y||t[24]!==m||t[25]!==o||t[26]!==a?(b=L.jsxs("div",{className:o,style:n,children:[a,y,m]}),t[22]=n,t[23]=y,t[24]=m,t[25]=o,t[26]=a,t[27]=b):b=t[27],b}function ZNt(){const t=qt.c(6),{environment:e}=Lp(),{track:i}=el();let n,r;t[0]!==i?(n=()=>{i(Fi.AppMounted)},r=[i],t[0]=i,t[1]=n,t[2]=r):(n=t[1],r=t[2]),J.useEffect(n,r);let o;t[3]===Symbol.for("react.memo_cache_sentinel")?(o=L.jsx(q1t,{children:L.jsx(S7e,{children:L.jsx(mNt,{children:L.jsx(VNt,{children:L.jsx(KNt,{})})})})}),t[3]=o):o=t[3];let a;return t[4]!==e.brokerUrl?(a=L.jsx(X0t,{brokerUrl:e.brokerUrl,children:o}),t[4]=e.brokerUrl,t[5]=a):a=t[5],a}const JNt=Dze({routeTree:Sze({component:()=>L.jsx(pwe,{delayDuration:0,children:L.jsx(F7e,{children:L.jsxs($qe,{children:[L.jsx(ZNt,{}),L.jsx(Zgt,{})]})})})}),disableGlobalCatchBoundary:!0});XUe.createRoot(document.getElementById("root")).render(L.jsx(Wn.StrictMode,{children:L.jsx(SNt,{fallback:t=>L.jsx(Y2t,{error:t}),children:L.jsx(Lze,{router:JNt})})}));export{iae as _,L as j,J as r};
