var vY=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var Mke=vY((aBe,sx)=>{(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))i(s);new MutationObserver(s=>{for(const o of s)if(o.type==="childList")for(const c of o.addedNodes)c.tagName==="LINK"&&c.rel==="modulepreload"&&i(c)}).observe(document,{childList:!0,subtree:!0});function n(s){const o={};return s.integrity&&(o.integrity=s.integrity),s.referrerPolicy&&(o.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?o.credentials="include":s.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function i(s){if(s.ep)return;s.ep=!0;const o=n(s);fetch(s.href,o)}})();function Yn(){}function oN(e){return e()}function Ok(){return Object.create(null)}function Xo(e){e.forEach(oN)}function lN(e){return typeof e=="function"}function $i(e,t){return e!=e?t==t:e!==t||e&&typeof e=="object"||typeof e=="function"}let kg;function EY(e,t){return kg||(kg=document.createElement("a")),kg.href=t,e===kg.href}function SY(e){return Object.keys(e).length===0}function Ve(e,t){e.appendChild(t)}function $t(e,t,n){e.insertBefore(t,n||null)}function Pt(e){e.parentNode&&e.parentNode.removeChild(e)}function h2(e,t){for(let n=0;ne.removeEventListener(t,n,i)}function Ee(e,t,n){n==null?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function kY(e){return Array.from(e.childNodes)}function Lh(e,t){t=""+t,e.wholeText!==t&&(e.data=t)}function Mk(e,t,n,i){n===null?e.style.removeProperty(t):e.style.setProperty(t,n,i?"important":"")}function BY(e,t,{bubbles:n=!1,cancelable:i=!1}={}){const s=document.createEvent("CustomEvent");return s.initCustomEvent(e,n,i,t),s}let g2;function X1(e){g2=e}function h9(){if(!g2)throw new Error("Function called outside component initialization");return g2}function FY(e){h9().$$.on_mount.push(e)}function cN(e){h9().$$.on_destroy.push(e)}function sf(){const e=h9();return(t,n,{cancelable:i=!1}={})=>{const s=e.$$.callbacks[t];if(s){const o=BY(t,n,{cancelable:i});return s.slice().forEach(c=>{c.call(e,o)}),!o.defaultPrevented}return!0}}function rn(e,t){const n=e.$$.callbacks[t.type];n&&n.slice().forEach(i=>i.call(this,t))}const $f=[],Wl=[],E_=[],k5=[],IY=Promise.resolve();let B5=!1;function OY(){B5||(B5=!0,IY.then(dN))}function F5(e){E_.push(e)}function g9(e){k5.push(e)}const j6=new Set;let xf=0;function dN(){if(xf!==0)return;const e=g2;do{try{for(;xf<$f.length;){const t=$f[xf];xf++,X1(t),MY(t.$$)}}catch(t){throw $f.length=0,xf=0,t}for(X1(null),$f.length=0,xf=0;Wl.length;)Wl.pop()();for(let t=0;t{S_.delete(e),i&&(n&&e.d(1),i())}),e.o(t)}else i&&i()}function _9(e,t,n){const i=e.$$.props[t];i!==void 0&&(e.$$.bound[i]=n,n(e.$$.ctx[i]))}function Nn(e){e&&e.c()}function bn(e,t,n,i){const{fragment:s,after_update:o}=e.$$;s&&s.m(t,n),i||F5(()=>{const c=e.$$.on_mount.map(oN).filter(lN);e.$$.on_destroy?e.$$.on_destroy.push(...c):Xo(c),e.$$.on_mount=[]}),o.forEach(F5)}function Tn(e,t){const n=e.$$;n.fragment!==null&&(Xo(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function AY(e,t){e.$$.dirty[0]===-1&&($f.push(e),OY(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<{const l=p.length?p[0]:y;return u.ctx&&s(u.ctx[m],u.ctx[m]=l)&&(!u.skip_bound&&u.bound[m]&&u.bound[m](l),a&&AY(e,m)),y}):[],u.update(),a=!0,Xo(u.before_update),u.fragment=i?i(u.ctx):!1,t.target){if(t.hydrate){const m=kY(t.target);u.fragment&&u.fragment.l(m),m.forEach(Pt)}else u.fragment&&u.fragment.c();t.intro&&wt(e.$$.fragment),bn(e,t.target,t.anchor,t.customElement),dN()}X1(f)}class Vi{$destroy(){Tn(this,1),this.$destroy=Yn}$on(t,n){if(!lN(n))return Yn;const i=this.$$.callbacks[t]||(this.$$.callbacks[t]=[]);return i.push(n),()=>{const s=i.indexOf(n);s!==-1&&i.splice(s,1)}}$set(t){this.$$set&&!SY(t)&&(this.$$.skip_bound=!0,this.$$set(t),this.$$.skip_bound=!1)}}function NY(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Qe(e){return this instanceof Qe?(this.v=e,this):new Qe(e)}function Ir(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var i=n.apply(e,t||[]),s,o=[];return s={},c("next"),c("throw"),c("return"),s[Symbol.asyncIterator]=function(){return this},s;function c(y){i[y]&&(s[y]=function(p){return new Promise(function(l,b){o.push([y,p,l,b])>1||d(y,p)})})}function d(y,p){try{f(i[y](p))}catch(l){m(o[0][3],l)}}function f(y){y.value instanceof Qe?Promise.resolve(y.value.v).then(u,a):m(o[0][2],y)}function u(y){d("next",y)}function a(y){d("throw",y)}function m(y,p){y(p),o.shift(),o.length&&d(o[0][0],o[0][1])}}function x_(e){var t,n;return t={},i("next"),i("throw",function(s){throw s}),i("return"),t[Symbol.iterator]=function(){return this},t;function i(s,o){t[s]=e[s]?function(c){return(n=!n)?{value:Qe(e[s](c)),done:!1}:o?o(c):c}:o}}function Pl(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=e[Symbol.asyncIterator],n;return t?t.call(e):(e=typeof Ak=="function"?Ak(e):e[Symbol.iterator](),n={},i("next"),i("throw"),i("return"),n[Symbol.asyncIterator]=function(){return this},n);function i(o){n[o]=e[o]&&function(c){return new Promise(function(d,f){c=e[o](c),s(d,f,c.done,c.value)})}}function s(o,c,d,f){Promise.resolve(f).then(function(u){o({value:u,done:d})},c)}}const CY=new TextDecoder("utf-8"),I5=e=>CY.decode(e),RY=new TextEncoder,c4=e=>RY.encode(e),[Pke,fN]=(()=>{const e=()=>{throw new Error("BigInt is not available in this environment")};function t(){throw e()}return t.asIntN=()=>{throw e()},t.asUintN=()=>{throw e()},typeof BigInt<"u"?[BigInt,!0]:[t,!1]})(),[Ko,Dke]=(()=>{const e=()=>{throw new Error("BigInt64Array is not available in this environment")};class t{static get BYTES_PER_ELEMENT(){return 8}static of(){throw e()}static from(){throw e()}constructor(){throw e()}}return typeof BigInt64Array<"u"?[BigInt64Array,!0]:[t,!1]})(),[Zo,jke]=(()=>{const e=()=>{throw new Error("BigUint64Array is not available in this environment")};class t{static get BYTES_PER_ELEMENT(){return 8}static of(){throw e()}static from(){throw e()}constructor(){throw e()}}return typeof BigUint64Array<"u"?[BigUint64Array,!0]:[t,!1]})(),PY=e=>typeof e=="number",uN=e=>typeof e=="boolean",Bn=e=>typeof e=="function",cs=e=>e!=null&&Object(e)===e,Yl=e=>cs(e)&&Bn(e.then),bh=e=>cs(e)&&Bn(e[Symbol.iterator]),rf=e=>cs(e)&&Bn(e[Symbol.asyncIterator]),O5=e=>cs(e)&&cs(e.schema),hN=e=>cs(e)&&"done"in e&&"value"in e,gN=e=>cs(e)&&Bn(e.stat)&&PY(e.fd),_N=e=>cs(e)&&p9(e.body),d4=e=>"_getDOMStream"in e&&"_getNodeStream"in e,DY=e=>cs(e)&&Bn(e.abort)&&Bn(e.getWriter)&&!d4(e),p9=e=>cs(e)&&Bn(e.cancel)&&Bn(e.getReader)&&!d4(e),jY=e=>cs(e)&&Bn(e.end)&&Bn(e.write)&&uN(e.writable)&&!d4(e),pN=e=>cs(e)&&Bn(e.read)&&Bn(e.pipe)&&uN(e.readable)&&!d4(e),UY=e=>cs(e)&&Bn(e.clear)&&Bn(e.bytes)&&Bn(e.position)&&Bn(e.setPosition)&&Bn(e.capacity)&&Bn(e.getBufferIdentifier)&&Bn(e.createLong),y9=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:ArrayBuffer;function HY(e){const t=e[0]?[e[0]]:[];let n,i,s,o;for(let c,d,f=0,u=0,a=e.length;++fa+m.byteLength,0);let s,o,c,d=0,f=-1;const u=Math.min(t||Number.POSITIVE_INFINITY,i);for(const a=n.length;++fbt(Int8Array,e),$Y=e=>bt(Int16Array,e),Gf=e=>bt(Int32Array,e),qY=e=>bt(Ko,e),St=e=>bt(Uint8Array,e),VY=e=>bt(Uint16Array,e),GY=e=>bt(Uint32Array,e),WY=e=>bt(Zo,e),YY=e=>bt(Float32Array,e),XY=e=>bt(Float64Array,e),KY=e=>bt(Uint8ClampedArray,e),M5=e=>(e.next(),e);function*Wa(e,t){const n=function*(s){yield s},i=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof y9?n(t):bh(t)?t:n(t);return yield*M5(function*(s){let o=null;do o=s.next(yield bt(e,o));while(!o.done)}(i[Symbol.iterator]())),new e}const ZY=e=>Wa(Int8Array,e),JY=e=>Wa(Int16Array,e),QY=e=>Wa(Int32Array,e),yN=e=>Wa(Uint8Array,e),eX=e=>Wa(Uint16Array,e),tX=e=>Wa(Uint32Array,e),nX=e=>Wa(Float32Array,e),iX=e=>Wa(Float64Array,e),sX=e=>Wa(Uint8ClampedArray,e);function Gr(e,t){return Ir(this,arguments,function*(){if(Yl(t))return yield Qe(yield Qe(yield*x_(Pl(Gr(e,yield Qe(t))))));const i=function(c){return Ir(this,arguments,function*(){yield yield Qe(yield Qe(c))})},s=function(c){return Ir(this,arguments,function*(){yield Qe(yield*x_(Pl(M5(function*(d){let f=null;do f=d.next(yield f==null?void 0:f.value);while(!f.done)}(c[Symbol.iterator]())))))})},o=typeof t=="string"||ArrayBuffer.isView(t)||t instanceof ArrayBuffer||t instanceof y9?i(t):bh(t)?s(t):rf(t)?t:i(t);return yield Qe(yield*x_(Pl(M5(function(c){return Ir(this,arguments,function*(){let d=null;do d=yield Qe(c.next(yield yield Qe(bt(e,d))));while(!d.done)})}(o[Symbol.asyncIterator]()))))),yield Qe(new e)})}const rX=e=>Gr(Int8Array,e),aX=e=>Gr(Int16Array,e),oX=e=>Gr(Int32Array,e),mN=e=>Gr(Uint8Array,e),lX=e=>Gr(Uint16Array,e),cX=e=>Gr(Uint32Array,e),dX=e=>Gr(Float32Array,e),fX=e=>Gr(Float64Array,e),uX=e=>Gr(Uint8ClampedArray,e);function f4(e,t,n){if(e!==0){n=n.slice(0,t+1);for(let i=-1;++i<=t;)n[i]+=e}return n}function wN(e,t){let n=0;const i=e.length;if(i!==t.length)return!1;if(i>0)do if(e[n]!==t[n])return!1;while(++n(e.next(),e);function*gX(e){let t,n=!1,i=[],s,o,c,d=0;function f(){return o==="peek"?Hr(i,c)[0]:([s,i,d]=Hr(i,c),s)}({cmd:o,size:c}=yield null);const u=yN(e)[Symbol.iterator]();try{do if({done:t,value:s}=Number.isNaN(c-d)?u.next():u.next(c-d),!t&&s.byteLength>0&&(i.push(s),d+=s.byteLength),t||c<=d)do({cmd:o,size:c}=yield f());while(c0&&(s.push(o),f+=o.byteLength),n||d<=f)do({cmd:c,size:d}=yield yield Qe(u()));while(d0&&(s.push(St(o)),f+=o.byteLength),n||d<=f)do({cmd:c,size:d}=yield yield Qe(u()));while(d{})}get closed(){return this.reader?this.reader.closed.catch(()=>{}):Promise.resolve()}releaseLock(){this.reader&&this.reader.releaseLock(),this.reader=null}cancel(t){return Ae(this,void 0,void 0,function*(){const{reader:n,source:i}=this;n&&(yield n.cancel(t).catch(()=>{})),i&&i.locked&&this.releaseLock()})}read(t){return Ae(this,void 0,void 0,function*(){if(t===0)return{done:this.reader==null,value:new Uint8Array(0)};const n=yield this.reader.read();return!n.done&&(n.value=St(n)),n})}}const U6=(e,t)=>{const n=s=>i([t,s]);let i;return[t,n,new Promise(s=>(i=s)&&e.once(t,n))]};function mX(e){return Ir(this,arguments,function*(){const n=[];let i="error",s=!1,o=null,c,d,f=0,u=[],a;function m(){return c==="peek"?Hr(u,d)[0]:([a,u,f]=Hr(u,d),a)}if({cmd:c,size:d}=yield yield Qe(null),e.isTTY)return yield yield Qe(new Uint8Array(0)),yield Qe(null);try{n[0]=U6(e,"end"),n[1]=U6(e,"error");do{if(n[2]=U6(e,"readable"),[i,o]=yield Qe(Promise.race(n.map(p=>p[2]))),i==="error")break;if((s=i==="end")||(Number.isFinite(d-f)?(a=St(e.read(d-f)),a.byteLength0&&(u.push(a),f+=a.byteLength)),s||d<=f)do({cmd:c,size:d}=yield yield Qe(m()));while(d{for(const[E,S]of p)e.off(E,S);try{const E=e.destroy;E&&E.call(e,l),l=void 0}catch(E){l=E||l}finally{l!=null?L(l):b()}})}})}var ts;(function(e){e[e.V1=0]="V1",e[e.V2=1]="V2",e[e.V3=2]="V3",e[e.V4=3]="V4",e[e.V5=4]="V5"})(ts||(ts={}));var Xn;(function(e){e[e.Sparse=0]="Sparse",e[e.Dense=1]="Dense"})(Xn||(Xn={}));var Cn;(function(e){e[e.HALF=0]="HALF",e[e.SINGLE=1]="SINGLE",e[e.DOUBLE=2]="DOUBLE"})(Cn||(Cn={}));var ds;(function(e){e[e.DAY=0]="DAY",e[e.MILLISECOND=1]="MILLISECOND"})(ds||(ds={}));var rt;(function(e){e[e.SECOND=0]="SECOND",e[e.MILLISECOND=1]="MILLISECOND",e[e.MICROSECOND=2]="MICROSECOND",e[e.NANOSECOND=3]="NANOSECOND"})(rt||(rt={}));var er;(function(e){e[e.YEAR_MONTH=0]="YEAR_MONTH",e[e.DAY_TIME=1]="DAY_TIME",e[e.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"})(er||(er={}));var zt;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(zt||(zt={}));var te;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth"})(te||(te={}));var wr;(function(e){e[e.OFFSET=0]="OFFSET",e[e.DATA=1]="DATA",e[e.VALIDITY=2]="VALIDITY",e[e.TYPE=3]="TYPE"})(wr||(wr={}));const wX=void 0;function Dl(e){if(e===null)return"null";if(e===wX)return"undefined";switch(typeof e){case"number":return`${e}`;case"bigint":return`${e}`;case"string":return`"${e}"`}return typeof e[Symbol.toPrimitive]=="function"?e[Symbol.toPrimitive]("string"):ArrayBuffer.isView(e)?e instanceof Ko||e instanceof Zo?`[${[...e].map(t=>Dl(t))}]`:`[${e}]`:ArrayBuffer.isView(e)?`[${e}]`:JSON.stringify(e,(t,n)=>typeof n=="bigint"?`${n}`:n)}const LN=Symbol.for("isArrowBigNum");function Wr(e,...t){return t.length===0?Object.setPrototypeOf(bt(this.TypedArray,e),this.constructor.prototype):Object.setPrototypeOf(new this.TypedArray(e,...t),this.constructor.prototype)}Wr.prototype[LN]=!0;Wr.prototype.toJSON=function(){return`"${jl(this)}"`};Wr.prototype.valueOf=function(){return bN(this)};Wr.prototype.toString=function(){return jl(this)};Wr.prototype[Symbol.toPrimitive]=function(e="default"){switch(e){case"number":return bN(this);case"string":return jl(this);case"default":return lp(this)}return jl(this)};function du(...e){return Wr.apply(this,e)}function fu(...e){return Wr.apply(this,e)}function p2(...e){return Wr.apply(this,e)}Object.setPrototypeOf(du.prototype,Object.create(Int32Array.prototype));Object.setPrototypeOf(fu.prototype,Object.create(Uint32Array.prototype));Object.setPrototypeOf(p2.prototype,Object.create(Uint32Array.prototype));Object.assign(du.prototype,Wr.prototype,{constructor:du,signed:!0,TypedArray:Int32Array,BigIntArray:Ko});Object.assign(fu.prototype,Wr.prototype,{constructor:fu,signed:!1,TypedArray:Uint32Array,BigIntArray:Zo});Object.assign(p2.prototype,Wr.prototype,{constructor:p2,signed:!0,TypedArray:Uint32Array,BigIntArray:Zo});function bN(e){const{buffer:t,byteOffset:n,length:i,signed:s}=e,o=new Zo(t,n,i),c=s&&o[o.length-1]&BigInt(1)<e.byteLength===8?new e.BigIntArray(e.buffer,e.byteOffset,1)[0]:H6(e),jl=e=>e.byteLength===8?`${new e.BigIntArray(e.buffer,e.byteOffset,1)[0]}`:H6(e)):(jl=H6,lp=jl);function H6(e){let t="";const n=new Uint32Array(2);let i=new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2);const s=new Uint32Array((i=new Uint16Array(i).reverse()).buffer);let o=-1;const c=i.length-1;do{for(n[0]=i[o=0];o(e.children=null,e.ArrayType=Array,e[Symbol.toStringTag]="DataType"))(We.prototype);let Oa=class extends We{toString(){return"Null"}get typeId(){return te.Null}};vN=Symbol.toStringTag;Oa[vN]=(e=>e[Symbol.toStringTag]="Null")(Oa.prototype);class vi extends We{constructor(t,n){super(),this.isSigned=t,this.bitWidth=n}get typeId(){return te.Int}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array;case 16:return this.isSigned?Int16Array:Uint16Array;case 32:return this.isSigned?Int32Array:Uint32Array;case 64:return this.isSigned?Ko:Zo}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}EN=Symbol.toStringTag;vi[EN]=(e=>(e.isSigned=null,e.bitWidth=null,e[Symbol.toStringTag]="Int"))(vi.prototype);class m9 extends vi{constructor(){super(!0,8)}get ArrayType(){return Int8Array}}class w9 extends vi{constructor(){super(!0,16)}get ArrayType(){return Int16Array}}class Xl extends vi{constructor(){super(!0,32)}get ArrayType(){return Int32Array}}let u4=class extends vi{constructor(){super(!0,64)}get ArrayType(){return Ko}};class L9 extends vi{constructor(){super(!1,8)}get ArrayType(){return Uint8Array}}class b9 extends vi{constructor(){super(!1,16)}get ArrayType(){return Uint16Array}}class T9 extends vi{constructor(){super(!1,32)}get ArrayType(){return Uint32Array}}let v9=class extends vi{constructor(){super(!1,64)}get ArrayType(){return Zo}};Object.defineProperty(m9.prototype,"ArrayType",{value:Int8Array});Object.defineProperty(w9.prototype,"ArrayType",{value:Int16Array});Object.defineProperty(Xl.prototype,"ArrayType",{value:Int32Array});Object.defineProperty(u4.prototype,"ArrayType",{value:Ko});Object.defineProperty(L9.prototype,"ArrayType",{value:Uint8Array});Object.defineProperty(b9.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(T9.prototype,"ArrayType",{value:Uint32Array});Object.defineProperty(v9.prototype,"ArrayType",{value:Zo});class Ho extends We{constructor(t){super(),this.precision=t}get typeId(){return te.Float}get ArrayType(){switch(this.precision){case Cn.HALF:return Uint16Array;case Cn.SINGLE:return Float32Array;case Cn.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}SN=Symbol.toStringTag;Ho[SN]=(e=>(e.precision=null,e[Symbol.toStringTag]="Float"))(Ho.prototype);class HN extends Ho{constructor(){super(Cn.HALF)}}class E9 extends Ho{constructor(){super(Cn.SINGLE)}}class h4 extends Ho{constructor(){super(Cn.DOUBLE)}}Object.defineProperty(HN.prototype,"ArrayType",{value:Uint16Array});Object.defineProperty(E9.prototype,"ArrayType",{value:Float32Array});Object.defineProperty(h4.prototype,"ArrayType",{value:Float64Array});let y2=class extends We{constructor(){super()}get typeId(){return te.Binary}toString(){return"Binary"}};xN=Symbol.toStringTag;y2[xN]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Binary"))(y2.prototype);let ku=class extends We{constructor(){super()}get typeId(){return te.Utf8}toString(){return"Utf8"}};kN=Symbol.toStringTag;ku[kN]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Utf8"))(ku.prototype);let Bu=class extends We{constructor(){super()}get typeId(){return te.Bool}toString(){return"Bool"}};BN=Symbol.toStringTag;Bu[BN]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Bool"))(Bu.prototype);let m2=class extends We{constructor(t,n,i=128){super(),this.scale=t,this.precision=n,this.bitWidth=i}get typeId(){return te.Decimal}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}};FN=Symbol.toStringTag;m2[FN]=(e=>(e.scale=null,e.precision=null,e.ArrayType=Uint32Array,e[Symbol.toStringTag]="Decimal"))(m2.prototype);class Id extends We{constructor(t){super(),this.unit=t}get typeId(){return te.Date}toString(){return`Date${(this.unit+1)*32}<${ds[this.unit]}>`}}IN=Symbol.toStringTag;Id[IN]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Date"))(Id.prototype);class bX extends Id{constructor(){super(ds.DAY)}}class zN extends Id{constructor(){super(ds.MILLISECOND)}}class Ma extends We{constructor(t,n){super(),this.unit=t,this.bitWidth=n}get typeId(){return te.Time}toString(){return`Time${this.bitWidth}<${rt[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array;case 64:return Ko}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}ON=Symbol.toStringTag;Ma[ON]=(e=>(e.unit=null,e.bitWidth=null,e[Symbol.toStringTag]="Time"))(Ma.prototype);class TX extends Ma{constructor(){super(rt.SECOND,32)}}class vX extends Ma{constructor(){super(rt.MILLISECOND,32)}}class EX extends Ma{constructor(){super(rt.MICROSECOND,64)}}class SX extends Ma{constructor(){super(rt.NANOSECOND,64)}}class zo extends We{constructor(t,n){super(),this.unit=t,this.timezone=n}get typeId(){return te.Timestamp}toString(){return`Timestamp<${rt[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}MN=Symbol.toStringTag;zo[MN]=(e=>(e.unit=null,e.timezone=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Timestamp"))(zo.prototype);class xX extends zo{constructor(t){super(rt.SECOND,t)}}class kX extends zo{constructor(t){super(rt.MILLISECOND,t)}}class BX extends zo{constructor(t){super(rt.MICROSECOND,t)}}class FX extends zo{constructor(t){super(rt.NANOSECOND,t)}}class Od extends We{constructor(t){super(),this.unit=t}get typeId(){return te.Interval}toString(){return`Interval<${er[this.unit]}>`}}AN=Symbol.toStringTag;Od[AN]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Interval"))(Od.prototype);class IX extends Od{constructor(){super(er.DAY_TIME)}}class OX extends Od{constructor(){super(er.YEAR_MONTH)}}let Md=class extends We{constructor(t){super(),this.children=[t]}get typeId(){return te.List}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}};NN=Symbol.toStringTag;Md[NN]=(e=>(e.children=null,e[Symbol.toStringTag]="List"))(Md.prototype);class Hn extends We{constructor(t){super(),this.children=t}get typeId(){return te.Struct}toString(){return`Struct<{${this.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}CN=Symbol.toStringTag;Hn[CN]=(e=>(e.children=null,e[Symbol.toStringTag]="Struct"))(Hn.prototype);class Kl extends We{constructor(t,n,i){super(),this.mode=t,this.children=i,this.typeIds=n=Int32Array.from(n),this.typeIdToChildIndex=n.reduce((s,o,c)=>(s[o]=c)&&s||s,Object.create(null))}get typeId(){return te.Union}toString(){return`${this[Symbol.toStringTag]}<${this.children.map(t=>`${t.type}`).join(" | ")}>`}}RN=Symbol.toStringTag;Kl[RN]=(e=>(e.mode=null,e.typeIds=null,e.children=null,e.typeIdToChildIndex=null,e.ArrayType=Int8Array,e[Symbol.toStringTag]="Union"))(Kl.prototype);class MX extends Kl{constructor(t,n){super(Xn.Dense,t,n)}}class AX extends Kl{constructor(t,n){super(Xn.Sparse,t,n)}}let w2=class extends We{constructor(t){super(),this.byteWidth=t}get typeId(){return te.FixedSizeBinary}toString(){return`FixedSizeBinary[${this.byteWidth}]`}};PN=Symbol.toStringTag;w2[PN]=(e=>(e.byteWidth=null,e.ArrayType=Uint8Array,e[Symbol.toStringTag]="FixedSizeBinary"))(w2.prototype);let Fu=class extends We{constructor(t,n){super(),this.listSize=t,this.children=[n]}get typeId(){return te.FixedSizeList}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}};DN=Symbol.toStringTag;Fu[DN]=(e=>(e.children=null,e.listSize=null,e[Symbol.toStringTag]="FixedSizeList"))(Fu.prototype);class Iu extends We{constructor(t,n=!1){super(),this.children=[t],this.keysSorted=n}get typeId(){return te.Map}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map(t=>`${t.name}:${t.type}`).join(", ")}}>`}}jN=Symbol.toStringTag;Iu[jN]=(e=>(e.children=null,e.keysSorted=null,e[Symbol.toStringTag]="Map_"))(Iu.prototype);const NX=(e=>()=>++e)(-1);class $o extends We{constructor(t,n,i,s){super(),this.indices=n,this.dictionary=t,this.isOrdered=s||!1,this.id=i==null?NX():typeof i=="number"?i:i.low}get typeId(){return te.Dictionary}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}UN=Symbol.toStringTag;$o[UN]=(e=>(e.id=null,e.indices=null,e.isOrdered=null,e.dictionary=null,e[Symbol.toStringTag]="Dictionary"))($o.prototype);function aa(e){const t=e;switch(e.typeId){case te.Decimal:return e.bitWidth/32;case te.Timestamp:return 2;case te.Date:return 1+t.unit;case te.Interval:return 1+t.unit;case te.FixedSizeList:return t.listSize;case te.FixedSizeBinary:return t.byteWidth;default:return 1}}class mt{visitMany(t,...n){return t.map((i,s)=>this.visit(i,...n.map(o=>o[s])))}visit(...t){return this.getVisitFn(t[0],!1).apply(this,t)}getVisitFn(t,n=!0){return CX(this,t,n)}getVisitFnByTypeId(t,n=!0){return Wf(this,t,n)}visitNull(t,...n){return null}visitBool(t,...n){return null}visitInt(t,...n){return null}visitFloat(t,...n){return null}visitUtf8(t,...n){return null}visitBinary(t,...n){return null}visitFixedSizeBinary(t,...n){return null}visitDate(t,...n){return null}visitTimestamp(t,...n){return null}visitTime(t,...n){return null}visitDecimal(t,...n){return null}visitList(t,...n){return null}visitStruct(t,...n){return null}visitUnion(t,...n){return null}visitDictionary(t,...n){return null}visitInterval(t,...n){return null}visitFixedSizeList(t,...n){return null}visitMap(t,...n){return null}}function CX(e,t,n=!0){return typeof t=="number"?Wf(e,t,n):typeof t=="string"&&t in te?Wf(e,te[t],n):t&&t instanceof We?Wf(e,Nk(t),n):t!=null&&t.type&&t.type instanceof We?Wf(e,Nk(t.type),n):Wf(e,te.NONE,n)}function Wf(e,t,n=!0){let i=null;switch(t){case te.Null:i=e.visitNull;break;case te.Bool:i=e.visitBool;break;case te.Int:i=e.visitInt;break;case te.Int8:i=e.visitInt8||e.visitInt;break;case te.Int16:i=e.visitInt16||e.visitInt;break;case te.Int32:i=e.visitInt32||e.visitInt;break;case te.Int64:i=e.visitInt64||e.visitInt;break;case te.Uint8:i=e.visitUint8||e.visitInt;break;case te.Uint16:i=e.visitUint16||e.visitInt;break;case te.Uint32:i=e.visitUint32||e.visitInt;break;case te.Uint64:i=e.visitUint64||e.visitInt;break;case te.Float:i=e.visitFloat;break;case te.Float16:i=e.visitFloat16||e.visitFloat;break;case te.Float32:i=e.visitFloat32||e.visitFloat;break;case te.Float64:i=e.visitFloat64||e.visitFloat;break;case te.Utf8:i=e.visitUtf8;break;case te.Binary:i=e.visitBinary;break;case te.FixedSizeBinary:i=e.visitFixedSizeBinary;break;case te.Date:i=e.visitDate;break;case te.DateDay:i=e.visitDateDay||e.visitDate;break;case te.DateMillisecond:i=e.visitDateMillisecond||e.visitDate;break;case te.Timestamp:i=e.visitTimestamp;break;case te.TimestampSecond:i=e.visitTimestampSecond||e.visitTimestamp;break;case te.TimestampMillisecond:i=e.visitTimestampMillisecond||e.visitTimestamp;break;case te.TimestampMicrosecond:i=e.visitTimestampMicrosecond||e.visitTimestamp;break;case te.TimestampNanosecond:i=e.visitTimestampNanosecond||e.visitTimestamp;break;case te.Time:i=e.visitTime;break;case te.TimeSecond:i=e.visitTimeSecond||e.visitTime;break;case te.TimeMillisecond:i=e.visitTimeMillisecond||e.visitTime;break;case te.TimeMicrosecond:i=e.visitTimeMicrosecond||e.visitTime;break;case te.TimeNanosecond:i=e.visitTimeNanosecond||e.visitTime;break;case te.Decimal:i=e.visitDecimal;break;case te.List:i=e.visitList;break;case te.Struct:i=e.visitStruct;break;case te.Union:i=e.visitUnion;break;case te.DenseUnion:i=e.visitDenseUnion||e.visitUnion;break;case te.SparseUnion:i=e.visitSparseUnion||e.visitUnion;break;case te.Dictionary:i=e.visitDictionary;break;case te.Interval:i=e.visitInterval;break;case te.IntervalDayTime:i=e.visitIntervalDayTime||e.visitInterval;break;case te.IntervalYearMonth:i=e.visitIntervalYearMonth||e.visitInterval;break;case te.FixedSizeList:i=e.visitFixedSizeList;break;case te.Map:i=e.visitMap;break}if(typeof i=="function")return i;if(!n)return()=>null;throw new Error(`Unrecognized type '${te[t]}'`)}function Nk(e){switch(e.typeId){case te.Null:return te.Null;case te.Int:{const{bitWidth:t,isSigned:n}=e;switch(t){case 8:return n?te.Int8:te.Uint8;case 16:return n?te.Int16:te.Uint16;case 32:return n?te.Int32:te.Uint32;case 64:return n?te.Int64:te.Uint64}return te.Int}case te.Float:switch(e.precision){case Cn.HALF:return te.Float16;case Cn.SINGLE:return te.Float32;case Cn.DOUBLE:return te.Float64}return te.Float;case te.Binary:return te.Binary;case te.Utf8:return te.Utf8;case te.Bool:return te.Bool;case te.Decimal:return te.Decimal;case te.Time:switch(e.unit){case rt.SECOND:return te.TimeSecond;case rt.MILLISECOND:return te.TimeMillisecond;case rt.MICROSECOND:return te.TimeMicrosecond;case rt.NANOSECOND:return te.TimeNanosecond}return te.Time;case te.Timestamp:switch(e.unit){case rt.SECOND:return te.TimestampSecond;case rt.MILLISECOND:return te.TimestampMillisecond;case rt.MICROSECOND:return te.TimestampMicrosecond;case rt.NANOSECOND:return te.TimestampNanosecond}return te.Timestamp;case te.Date:switch(e.unit){case ds.DAY:return te.DateDay;case ds.MILLISECOND:return te.DateMillisecond}return te.Date;case te.Interval:switch(e.unit){case er.DAY_TIME:return te.IntervalDayTime;case er.YEAR_MONTH:return te.IntervalYearMonth}return te.Interval;case te.Map:return te.Map;case te.List:return te.List;case te.Struct:return te.Struct;case te.Union:switch(e.mode){case Xn.Dense:return te.DenseUnion;case Xn.Sparse:return te.SparseUnion}return te.Union;case te.FixedSizeBinary:return te.FixedSizeBinary;case te.FixedSizeList:return te.FixedSizeList;case te.Dictionary:return te.Dictionary}throw new Error(`Unrecognized type '${te[e.typeId]}'`)}mt.prototype.visitInt8=null;mt.prototype.visitInt16=null;mt.prototype.visitInt32=null;mt.prototype.visitInt64=null;mt.prototype.visitUint8=null;mt.prototype.visitUint16=null;mt.prototype.visitUint32=null;mt.prototype.visitUint64=null;mt.prototype.visitFloat16=null;mt.prototype.visitFloat32=null;mt.prototype.visitFloat64=null;mt.prototype.visitDateDay=null;mt.prototype.visitDateMillisecond=null;mt.prototype.visitTimestampSecond=null;mt.prototype.visitTimestampMillisecond=null;mt.prototype.visitTimestampMicrosecond=null;mt.prototype.visitTimestampNanosecond=null;mt.prototype.visitTimeSecond=null;mt.prototype.visitTimeMillisecond=null;mt.prototype.visitTimeMicrosecond=null;mt.prototype.visitTimeNanosecond=null;mt.prototype.visitDenseUnion=null;mt.prototype.visitSparseUnion=null;mt.prototype.visitIntervalDayTime=null;mt.prototype.visitIntervalYearMonth=null;const $N=new Float64Array(1),kf=new Uint32Array($N.buffer);function S9(e){const t=(e&31744)>>10,n=(e&1023)/1024,i=Math.pow(-1,(e&32768)>>15);switch(t){case 31:return i*(n?Number.NaN:1/0);case 0:return i*(n?6103515625e-14*n:0)}return i*Math.pow(2,t-15)*(1+n)}function x9(e){if(e!==e)return 32256;$N[0]=e;const t=(kf[1]&2147483648)>>16&65535;let n=kf[1]&2146435072,i=0;return n>=1089470464?kf[0]>0?n=31744:(n=(n&2080374784)>>16,i=(kf[1]&1048575)>>10):n<=1056964608?(i=1048576+(kf[1]&1048575),i=1048576+(i<<(n>>20)-998)>>21,n=0):(n=n-1056964608>>10,i=(kf[1]&1048575)+512>>10),t|n|i&65535}const RX=Object.freeze(Object.defineProperty({__proto__:null,float64ToUint16:x9,uint16ToFloat64:S9},Symbol.toStringTag,{value:"Module"}));class ot extends mt{}function ut(e){return(t,n,i)=>{if(t.setValid(n,i!=null))return e(t,n,i)}}const PX=(e,t,n)=>{e[t]=Math.trunc(n/864e5)},k9=(e,t,n)=>{e[t]=Math.trunc(n%4294967296),e[t+1]=Math.trunc(n/4294967296)},DX=(e,t,n)=>{e[t]=Math.trunc(n*1e3%4294967296),e[t+1]=Math.trunc(n*1e3/4294967296)},jX=(e,t,n)=>{e[t]=Math.trunc(n*1e6%4294967296),e[t+1]=Math.trunc(n*1e6/4294967296)},qN=(e,t,n,i)=>{if(n+1{const s=e+n;i?t[s>>3]|=1<>3]&=~(1<{e[t]=n},B9=({values:e},t,n)=>{e[t]=n},VN=({values:e},t,n)=>{e[t]=x9(n)},HX=(e,t,n)=>{switch(e.type.precision){case Cn.HALF:return VN(e,t,n);case Cn.SINGLE:case Cn.DOUBLE:return B9(e,t,n)}},F9=({values:e},t,n)=>{PX(e,t,n.valueOf())},I9=({values:e},t,n)=>{k9(e,t*2,n.valueOf())},GN=({stride:e,values:t},n,i)=>{t.set(i.subarray(0,e),e*n)},zX=({values:e,valueOffsets:t},n,i)=>qN(e,t,n,i),$X=({values:e,valueOffsets:t},n,i)=>{qN(e,t,n,c4(i))},WN=(e,t,n)=>{e.type.unit===ds.DAY?F9(e,t,n):I9(e,t,n)},O9=({values:e},t,n)=>k9(e,t*2,n/1e3),M9=({values:e},t,n)=>k9(e,t*2,n),A9=({values:e},t,n)=>DX(e,t*2,n),N9=({values:e},t,n)=>jX(e,t*2,n),YN=(e,t,n)=>{switch(e.type.unit){case rt.SECOND:return O9(e,t,n);case rt.MILLISECOND:return M9(e,t,n);case rt.MICROSECOND:return A9(e,t,n);case rt.NANOSECOND:return N9(e,t,n)}},C9=({values:e},t,n)=>{e[t]=n},R9=({values:e},t,n)=>{e[t]=n},P9=({values:e},t,n)=>{e[t]=n},D9=({values:e},t,n)=>{e[t]=n},XN=(e,t,n)=>{switch(e.type.unit){case rt.SECOND:return C9(e,t,n);case rt.MILLISECOND:return R9(e,t,n);case rt.MICROSECOND:return P9(e,t,n);case rt.NANOSECOND:return D9(e,t,n)}},KN=({values:e,stride:t},n,i)=>{e.set(i.subarray(0,t),t*n)},qX=(e,t,n)=>{const i=e.children[0],s=e.valueOffsets,o=tr.getVisitFn(i);if(Array.isArray(n))for(let c=-1,d=s[t],f=s[t+1];d{const i=e.children[0],{valueOffsets:s}=e,o=tr.getVisitFn(i);let{[t]:c,[t+1]:d}=s;const f=n instanceof Map?n.entries():Object.entries(n);for(const u of f)if(o(i,c,u),++c>=d)break},GX=(e,t)=>(n,i,s,o)=>i&&n(i,e,t[o]),WX=(e,t)=>(n,i,s,o)=>i&&n(i,e,t.get(o)),YX=(e,t)=>(n,i,s,o)=>i&&n(i,e,t.get(s.name)),XX=(e,t)=>(n,i,s,o)=>i&&n(i,e,t[s.name]),KX=(e,t,n)=>{const i=e.type.children.map(o=>tr.getVisitFn(o.type)),s=n instanceof Map?YX(t,n):n instanceof qe?WX(t,n):Array.isArray(n)?GX(t,n):XX(t,n);e.type.children.forEach((o,c)=>s(i[c],e.children[c],o,c))},ZX=(e,t,n)=>{e.type.mode===Xn.Dense?ZN(e,t,n):JN(e,t,n)},ZN=(e,t,n)=>{const i=e.type.typeIdToChildIndex[e.typeIds[t]],s=e.children[i];tr.visit(s,e.valueOffsets[t],n)},JN=(e,t,n)=>{const i=e.type.typeIdToChildIndex[e.typeIds[t]],s=e.children[i];tr.visit(s,t,n)},JX=(e,t,n)=>{var i;(i=e.dictionary)===null||i===void 0||i.set(e.values[t],n)},QN=(e,t,n)=>{e.type.unit===er.DAY_TIME?j9(e,t,n):U9(e,t,n)},j9=({values:e},t,n)=>{e.set(n.subarray(0,2),2*t)},U9=({values:e},t,n)=>{e[t]=n[0]*12+n[1]%12},QX=(e,t,n)=>{const{stride:i}=e,s=e.children[0],o=tr.getVisitFn(s);if(Array.isArray(n))for(let c=-1,d=t*i;++c`${Dl(t)}: ${Dl(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}[Symbol.iterator](){return new eK(this[Lr],this[uu])}}class eK{constructor(t,n){this.childIndex=0,this.children=t.children,this.rowIndex=n,this.childFields=t.type.children,this.numChildren=this.childFields.length}[Symbol.iterator](){return this}next(){const t=this.childIndex;return tn.name)}has(t,n){return t[Lr].type.children.findIndex(i=>i.name===n)!==-1}getOwnPropertyDescriptor(t,n){if(t[Lr].type.children.findIndex(i=>i.name===n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const i=t[Lr].type.children.findIndex(s=>s.name===n);if(i!==-1){const s=fs.visit(t[Lr].children[i],t[uu]);return Reflect.set(t,n,s),s}}set(t,n,i){const s=t[Lr].type.children.findIndex(o=>o.name===n);return s!==-1?(tr.visit(t[Lr].children[s],t[uu],i),Reflect.set(t,n,i)):Reflect.has(t,n)||typeof n=="symbol"?Reflect.set(t,n,i):!1}}class tt extends mt{}function lt(e){return(t,n)=>t.getValid(n)?e(t,n):null}const nK=(e,t)=>864e5*e[t],H9=(e,t)=>4294967296*e[t+1]+(e[t]>>>0),iK=(e,t)=>4294967296*(e[t+1]/1e3)+(e[t]>>>0)/1e3,sK=(e,t)=>4294967296*(e[t+1]/1e6)+(e[t]>>>0)/1e6,eC=e=>new Date(e),rK=(e,t)=>eC(nK(e,t)),aK=(e,t)=>eC(H9(e,t)),oK=(e,t)=>null,tC=(e,t,n)=>{if(n+1>=t.length)return null;const i=t[n],s=t[n+1];return e.subarray(i,s)},lK=({offset:e,values:t},n)=>{const i=e+n;return(t[i>>3]&1<rK(e,t),iC=({values:e},t)=>aK(e,t*2),pc=({stride:e,values:t},n)=>t[e*n],cK=({stride:e,values:t},n)=>S9(t[e*n]),sC=({values:e},t)=>e[t],dK=({stride:e,values:t},n)=>t.subarray(e*n,e*(n+1)),fK=({values:e,valueOffsets:t},n)=>tC(e,t,n),uK=({values:e,valueOffsets:t},n)=>{const i=tC(e,t,n);return i!==null?I5(i):null},hK=({values:e},t)=>e[t],gK=({type:e,values:t},n)=>e.precision!==Cn.HALF?t[n]:S9(t[n]),_K=(e,t)=>e.type.unit===ds.DAY?nC(e,t):iC(e,t),rC=({values:e},t)=>1e3*H9(e,t*2),aC=({values:e},t)=>H9(e,t*2),oC=({values:e},t)=>iK(e,t*2),lC=({values:e},t)=>sK(e,t*2),pK=(e,t)=>{switch(e.type.unit){case rt.SECOND:return rC(e,t);case rt.MILLISECOND:return aC(e,t);case rt.MICROSECOND:return oC(e,t);case rt.NANOSECOND:return lC(e,t)}},cC=({values:e},t)=>e[t],dC=({values:e},t)=>e[t],fC=({values:e},t)=>e[t],uC=({values:e},t)=>e[t],yK=(e,t)=>{switch(e.type.unit){case rt.SECOND:return cC(e,t);case rt.MILLISECOND:return dC(e,t);case rt.MICROSECOND:return fC(e,t);case rt.NANOSECOND:return uC(e,t)}},mK=({values:e,stride:t},n)=>a0.decimal(e.subarray(t*n,t*(n+1))),wK=(e,t)=>{const{valueOffsets:n,stride:i,children:s}=e,{[t*i]:o,[t*i+1]:c}=n,f=s[0].slice(o,c-o);return new qe([f])},LK=(e,t)=>{const{valueOffsets:n,children:i}=e,{[t]:s,[t+1]:o}=n,c=i[0];return new o0(c.slice(s,o-s))},bK=(e,t)=>new g4(e,t),TK=(e,t)=>e.type.mode===Xn.Dense?hC(e,t):gC(e,t),hC=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[n];return fs.visit(i,e.valueOffsets[t])},gC=(e,t)=>{const n=e.type.typeIdToChildIndex[e.typeIds[t]],i=e.children[n];return fs.visit(i,t)},vK=(e,t)=>{var n;return(n=e.dictionary)===null||n===void 0?void 0:n.get(e.values[t])},EK=(e,t)=>e.type.unit===er.DAY_TIME?_C(e,t):pC(e,t),_C=({values:e},t)=>e.subarray(2*t,2*(t+1)),pC=({values:e},t)=>{const n=e[t],i=new Int32Array(2);return i[0]=Math.trunc(n/12),i[1]=Math.trunc(n%12),i},SK=(e,t)=>{const{stride:n,children:i}=e,o=i[0].slice(t*n,n);return new qe([o])};tt.prototype.visitNull=lt(oK);tt.prototype.visitBool=lt(lK);tt.prototype.visitInt=lt(hK);tt.prototype.visitInt8=lt(pc);tt.prototype.visitInt16=lt(pc);tt.prototype.visitInt32=lt(pc);tt.prototype.visitInt64=lt(sC);tt.prototype.visitUint8=lt(pc);tt.prototype.visitUint16=lt(pc);tt.prototype.visitUint32=lt(pc);tt.prototype.visitUint64=lt(sC);tt.prototype.visitFloat=lt(gK);tt.prototype.visitFloat16=lt(cK);tt.prototype.visitFloat32=lt(pc);tt.prototype.visitFloat64=lt(pc);tt.prototype.visitUtf8=lt(uK);tt.prototype.visitBinary=lt(fK);tt.prototype.visitFixedSizeBinary=lt(dK);tt.prototype.visitDate=lt(_K);tt.prototype.visitDateDay=lt(nC);tt.prototype.visitDateMillisecond=lt(iC);tt.prototype.visitTimestamp=lt(pK);tt.prototype.visitTimestampSecond=lt(rC);tt.prototype.visitTimestampMillisecond=lt(aC);tt.prototype.visitTimestampMicrosecond=lt(oC);tt.prototype.visitTimestampNanosecond=lt(lC);tt.prototype.visitTime=lt(yK);tt.prototype.visitTimeSecond=lt(cC);tt.prototype.visitTimeMillisecond=lt(dC);tt.prototype.visitTimeMicrosecond=lt(fC);tt.prototype.visitTimeNanosecond=lt(uC);tt.prototype.visitDecimal=lt(mK);tt.prototype.visitList=lt(wK);tt.prototype.visitStruct=lt(bK);tt.prototype.visitUnion=lt(TK);tt.prototype.visitDenseUnion=lt(hC);tt.prototype.visitSparseUnion=lt(gC);tt.prototype.visitDictionary=lt(vK);tt.prototype.visitInterval=lt(EK);tt.prototype.visitIntervalDayTime=lt(_C);tt.prototype.visitIntervalYearMonth=lt(pC);tt.prototype.visitFixedSizeList=lt(SK);tt.prototype.visitMap=lt(LK);const fs=new tt,vr=Symbol.for("keys"),hu=Symbol.for("vals");class o0{constructor(t){return this[vr]=new qe([t.children[0]]).memoize(),this[hu]=t.children[1],new Proxy(this,new kK)}[Symbol.iterator](){return new xK(this[vr],this[hu])}get size(){return this[vr].length}toArray(){return Object.values(this.toJSON())}toJSON(){const t=this[vr],n=this[hu],i={};for(let s=-1,o=t.length;++s`${Dl(t)}: ${Dl(n)}`).join(", ")}}`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}class xK{constructor(t,n){this.keys=t,this.vals=n,this.keyIndex=0,this.numKeys=t.length}[Symbol.iterator](){return this}next(){const t=this.keyIndex;return t===this.numKeys?{done:!0,value:null}:(this.keyIndex++,{done:!1,value:[this.keys.get(t),fs.visit(this.vals,t)]})}}class kK{isExtensible(){return!1}deleteProperty(){return!1}preventExtensions(){return!0}ownKeys(t){return t[vr].toArray().map(String)}has(t,n){return t[vr].includes(n)}getOwnPropertyDescriptor(t,n){if(t[vr].indexOf(n)!==-1)return{writable:!0,enumerable:!0,configurable:!0}}get(t,n){if(Reflect.has(t,n))return t[n];const i=t[vr].indexOf(n);if(i!==-1){const s=fs.visit(Reflect.get(t,hu),i);return Reflect.set(t,n,s),s}}set(t,n,i){const s=t[vr].indexOf(n);return s!==-1?(tr.visit(Reflect.get(t,hu),s,i),Reflect.set(t,n,i)):Reflect.has(t,n)?Reflect.set(t,n,i):!1}}Object.defineProperties(o0.prototype,{[Symbol.toStringTag]:{enumerable:!1,configurable:!1,value:"Row"},[vr]:{writable:!0,enumerable:!1,configurable:!1,value:null},[hu]:{writable:!0,enumerable:!1,configurable:!1,value:null}});function BK(e,t,n){const i=e.length,s=t>-1?t:i+t%i;return n?n(e,s):s}let Ck;function z9(e,t,n,i){const{length:s=0}=e;let o=typeof t!="number"?0:t,c=typeof n!="number"?s:n;return o<0&&(o=(o%s+s)%s),c<0&&(c=(c%s+s)%s),cs&&(c=s),i?i(e,o,c):[o,c]}const Rk=e=>e!==e;function af(e){if(typeof e!=="object"||e===null)return Rk(e)?Rk:n=>n===e;if(e instanceof Date){const n=e.valueOf();return i=>i instanceof Date?i.valueOf()===n:!1}return ArrayBuffer.isView(e)?n=>n?wN(e,n):!1:e instanceof Map?IK(e):Array.isArray(e)?FK(e):e instanceof qe?OK(e):MK(e,!0)}function FK(e){const t=[];for(let n=-1,i=e.length;++n!1;const i=[];for(let s=-1,o=n.length;++s{if(!n||typeof n!="object")return!1;switch(n.constructor){case Array:return AK(e,n);case Map:return Pk(e,n,n.keys());case o0:case g4:case Object:case void 0:return Pk(e,n,t||Object.keys(n))}return n instanceof qe?NK(e,n):!1}}function AK(e,t){const n=e.length;if(t.length!==n)return!1;for(let i=-1;++i>i}function RK(e,t,n){return n?!!(e[t>>3]|=1<>3]&=~(1<0||n.byteLength>3):L2(new Ou(n,e,t,null,p4)).subarray(0,i)),s}return n}function L2(e){const t=[];let n=0,i=0,s=0;for(const c of e)c&&(s|=1<0)&&(t[n++]=s);const o=new Uint8Array(t.length+7&-8);return o.set(t),o}class Ou{constructor(t,n,i,s,o){this.bytes=t,this.length=i,this.context=s,this.get=o,this.bit=n%8,this.byteIndex=n>>3,this.byte=t[this.byteIndex++],this.index=0}next(){return this.index>3<<3,s=t+(t%8===0?0:8-t%8);return cp(e,t,s)+cp(e,i,n)+yC(e,s>>3,i-s>>3)}function yC(e,t,n){let i=0,s=Math.trunc(t);const o=new DataView(e.buffer,e.byteOffset,e.byteLength),c=n===void 0?e.byteLength:s+n;for(;c-s>=4;)i+=k_(o.getUint32(s)),s+=4;for(;c-s>=2;)i+=k_(o.getUint16(s)),s+=2;for(;c-s>=1;)i+=k_(o.getUint8(s)),s+=1;return i}function k_(e){let t=Math.trunc(e);return t=t-(t>>>1&1431655765),t=(t&858993459)+(t>>>2&858993459),(t+(t>>>4)&252645135)*16843009>>>24}const PK=Object.freeze(Object.defineProperty({__proto__:null,BitIterator:Ou,getBit:$9,getBool:p4,packBools:L2,popcnt_array:yC,popcnt_bit_range:cp,popcnt_uint32:k_,setBool:RK,truncateBitmap:y4},Symbol.toStringTag,{value:"Module"})),DK=-1;class Ut{constructor(t,n,i,s,o,c=[],d){this.type=t,this.children=c,this.dictionary=d,this.offset=Math.floor(Math.max(n||0,0)),this.length=Math.floor(Math.max(i||0,0)),this._nullCount=Math.floor(Math.max(s||0,-1));let f;o instanceof Ut?(this.stride=o.stride,this.values=o.values,this.typeIds=o.typeIds,this.nullBitmap=o.nullBitmap,this.valueOffsets=o.valueOffsets):(this.stride=aa(t),o&&((f=o[0])&&(this.valueOffsets=f),(f=o[1])&&(this.values=f),(f=o[2])&&(this.nullBitmap=f),(f=o[3])&&(this.typeIds=f))),this.nullable=this._nullCount!==0&&this.nullBitmap&&this.nullBitmap.byteLength>0}get typeId(){return this.type.typeId}get ArrayType(){return this.type.ArrayType}get buffers(){return[this.valueOffsets,this.values,this.nullBitmap,this.typeIds]}get byteLength(){let t=0;const{valueOffsets:n,values:i,nullBitmap:s,typeIds:o}=this;return n&&(t+=n.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),o&&(t+=o.byteLength),this.children.reduce((c,d)=>c+d.byteLength,t)}get nullCount(){let t=this._nullCount,n;return t<=DK&&(n=this.nullBitmap)&&(this._nullCount=t=this.length-cp(n,this.offset,this.offset+this.length)),t}getValid(t){if(this.nullable&&this.nullCount>0){const n=this.offset+t;return(this.nullBitmap[n>>3]&1<>3){const{nullBitmap:f}=this._changeLengthAndBackfillNullBitmap(this.length);Object.assign(this,{nullBitmap:f,_nullCount:0})}const{nullBitmap:i,offset:s}=this,o=s+t>>3,c=(s+t)%8,d=i[o]>>c&1;return n?d===0&&(i[o]|=1<>3).fill(255,0,n>>3);s[n>>3]=(1<0&&s.set(y4(this.offset,n,this.nullBitmap),0);const o=this.buffers;return o[wr.VALIDITY]=s,this.clone(this.type,0,t,i+(t-n),o)}_sliceBuffers(t,n,i,s){let o;const{buffers:c}=this;return(o=c[wr.TYPE])&&(c[wr.TYPE]=o.subarray(t,t+n)),(o=c[wr.OFFSET])&&(c[wr.OFFSET]=o.subarray(t,t+n+1))||(o=c[wr.DATA])&&(c[wr.DATA]=s===6?o:o.subarray(i*t,i*(t+n))),c}_sliceChildren(t,n,i){return t.map(s=>s.slice(n,i))}}Ut.prototype.children=Object.freeze([]);class K1 extends mt{visit(t){return this.getVisitFn(t.type).call(this,t)}visitNull(t){const{["type"]:n,["offset"]:i=0,["length"]:s=0}=t;return new Ut(n,i,s,0)}visitBool(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length>>3,["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitInt(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length,["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitFloat(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length,["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitUtf8(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.data),o=St(t.nullBitmap),c=Gf(t.valueOffsets),{["length"]:d=c.length-1,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new Ut(n,i,d,f,[c,s,o])}visitBinary(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.data),o=St(t.nullBitmap),c=Gf(t.valueOffsets),{["length"]:d=c.length-1,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new Ut(n,i,d,f,[c,s,o])}visitFixedSizeBinary(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitDate(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitTimestamp(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitTime(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitDecimal(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitList(t){const{["type"]:n,["offset"]:i=0,["child"]:s}=t,o=St(t.nullBitmap),c=Gf(t.valueOffsets),{["length"]:d=c.length-1,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new Ut(n,i,d,f,[c,void 0,o],[s])}visitStruct(t){const{["type"]:n,["offset"]:i=0,["children"]:s=[]}=t,o=St(t.nullBitmap),{length:c=s.reduce((f,{length:u})=>Math.max(f,u),0),nullCount:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,void 0,o],s)}visitUnion(t){const{["type"]:n,["offset"]:i=0,["children"]:s=[]}=t,o=St(t.nullBitmap),c=bt(n.ArrayType,t.typeIds),{["length"]:d=c.length,["nullCount"]:f=t.nullBitmap?-1:0}=t;if(We.isSparseUnion(n))return new Ut(n,i,d,f,[void 0,void 0,o,c],s);const u=Gf(t.valueOffsets);return new Ut(n,i,d,f,[u,void 0,o,c],s)}visitDictionary(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.indices.ArrayType,t.data),{["dictionary"]:c=new qe([new K1().visit({type:n.dictionary})])}=t,{["length"]:d=o.length,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new Ut(n,i,d,f,[void 0,o,s],[],c)}visitInterval(t){const{["type"]:n,["offset"]:i=0}=t,s=St(t.nullBitmap),o=bt(n.ArrayType,t.data),{["length"]:c=o.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,o,s])}visitFixedSizeList(t){const{["type"]:n,["offset"]:i=0,["child"]:s=new K1().visit({type:n.valueType})}=t,o=St(t.nullBitmap),{["length"]:c=s.length/aa(n),["nullCount"]:d=t.nullBitmap?-1:0}=t;return new Ut(n,i,c,d,[void 0,void 0,o],[s])}visitMap(t){const{["type"]:n,["offset"]:i=0,["child"]:s=new K1().visit({type:n.childType})}=t,o=St(t.nullBitmap),c=Gf(t.valueOffsets),{["length"]:d=c.length-1,["nullCount"]:f=t.nullBitmap?-1:0}=t;return new Ut(n,i,d,f,[c,void 0,o],[s])}}function Ze(e){return new K1().visit(e)}class Dk{constructor(t=0,n){this.numChunks=t,this.getChunkIterator=n,this.chunkIndex=0,this.chunkIterator=this.getChunkIterator(0)}next(){for(;this.chunkIndext+n.nullCount,0)}function wC(e){return e.reduce((t,n,i)=>(t[i+1]=t[i]+n.length,t),new Uint32Array(e.length+1))}function LC(e,t,n,i){const s=[];for(let o=-1,c=e.length;++o=i)break;if(n>=f+u)continue;if(f>=n&&f+u<=i){s.push(d);continue}const a=Math.max(0,n-f),m=Math.min(i-f,u);s.push(d.slice(a,m-a))}return s.length===0&&s.push(e[0].slice(0,0)),s}function q9(e,t,n,i){let s=0,o=0,c=t.length-1;do{if(s>=c-1)return n0?0:-1}function UK(e,t){const{nullBitmap:n}=e;if(!n||e.nullCount<=0)return-1;let i=0;for(const s of new Ou(n,e.offset+(t||0),e.length,n,p4)){if(!s)return i;++i}return-1}function _t(e,t,n){if(t===void 0)return-1;if(t===null)return UK(e,n);const i=fs.getVisitFn(e),s=af(t);for(let o=(n||0)-1,c=e.length;++o{const s=e.data[i];return s.values.subarray(0,s.length)[Symbol.iterator]()});let n=0;return new Dk(e.data.length,i=>{const o=e.data[i].length,c=e.slice(n,n+o);return n+=o,new HK(c)})}class HK{constructor(t){this.vector=t,this.index=0}next(){return this.indexe+t;class yc extends mt{visitNull(t,n){return 0}visitInt(t,n){return t.type.bitWidth/8}visitFloat(t,n){return t.type.ArrayType.BYTES_PER_ELEMENT}visitBool(t,n){return 1/8}visitDecimal(t,n){return t.type.bitWidth/8}visitDate(t,n){return(t.type.unit+1)*4}visitTime(t,n){return t.type.bitWidth/8}visitTimestamp(t,n){return t.type.unit===rt.SECOND?4:8}visitInterval(t,n){return(t.type.unit+1)*4}visitStruct(t,n){return t.children.reduce((i,s)=>i+Aa.visit(s,n),0)}visitFixedSizeBinary(t,n){return t.type.byteWidth}visitMap(t,n){return 8+t.children.reduce((i,s)=>i+Aa.visit(s,n),0)}visitDictionary(t,n){var i;return t.type.indices.bitWidth/8+(((i=t.dictionary)===null||i===void 0?void 0:i.getByteLength(t.values[n]))||0)}}const $K=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),qK=({valueOffsets:e},t)=>8+(e[t+1]-e[t]),VK=({valueOffsets:e,stride:t,children:n},i)=>{const s=n[0],{[i*t]:o}=e,{[i*t+1]:c}=e,d=Aa.getVisitFn(s.type),f=s.slice(o,c-o);let u=8;for(let a=-1,m=c-o;++a{const i=t[0],s=i.slice(n*e,e),o=Aa.getVisitFn(i.type);let c=0;for(let d=-1,f=s.length;++de.type.mode===Xn.Dense?EC(e,t):SC(e,t),EC=({type:e,children:t,typeIds:n,valueOffsets:i},s)=>{const o=e.typeIdToChildIndex[n[s]];return 8+Aa.visit(t[o],i[s])},SC=({children:e},t)=>4+Aa.visitMany(e,e.map(()=>t)).reduce(zK,0);yc.prototype.visitUtf8=$K;yc.prototype.visitBinary=qK;yc.prototype.visitList=VK;yc.prototype.visitFixedSizeList=GK;yc.prototype.visitUnion=WK;yc.prototype.visitDenseUnion=EC;yc.prototype.visitSparseUnion=SC;const Aa=new yc;var xC;const kC={},BC={};class qe{constructor(t){var n,i,s;const o=t[0]instanceof qe?t.flatMap(d=>d.data):t;if(o.length===0||o.some(d=>!(d instanceof Ut)))throw new TypeError("Vector constructor expects an Array of Data instances.");const c=(n=o[0])===null||n===void 0?void 0:n.type;switch(o.length){case 0:this._offsets=[0];break;case 1:{const{get:d,set:f,indexOf:u,byteLength:a}=kC[c.typeId],m=o[0];this.isValid=y=>V9(m,y),this.get=y=>d(m,y),this.set=(y,p)=>f(m,y,p),this.indexOf=y=>u(m,y),this.getByteLength=y=>a(m,y),this._offsets=[0,m.length];break}default:Object.setPrototypeOf(this,BC[c.typeId]),this._offsets=wC(o);break}this.data=o,this.type=c,this.stride=aa(c),this.numChildren=(s=(i=c.children)===null||i===void 0?void 0:i.length)!==null&&s!==void 0?s:0,this.length=this._offsets[this._offsets.length-1]}get byteLength(){return this._byteLength===-1&&(this._byteLength=this.data.reduce((t,n)=>t+n.byteLength,0)),this._byteLength}get nullCount(){return this._nullCount===-1&&(this._nullCount=mC(this.data)),this._nullCount}get ArrayType(){return this.type.ArrayType}get[Symbol.toStringTag](){return`${this.VectorName}<${this.type[Symbol.toStringTag]}>`}get VectorName(){return`${te[this.type.typeId]}Vector`}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}includes(t,n){return this.indexOf(t,n)>0}getByteLength(t){return 0}[Symbol.iterator](){return G9.visit(this)}concat(...t){return new qe(this.data.concat(t.flatMap(n=>n.data).flat(Number.POSITIVE_INFINITY)))}slice(t,n){return new qe(z9(this,t,n,({data:i,_offsets:s},o,c)=>LC(i,s,o,c)))}toJSON(){return[...this]}toArray(){const{type:t,data:n,length:i,stride:s,ArrayType:o}=this;switch(t.typeId){case te.Int:case te.Float:case te.Decimal:case te.Time:case te.Timestamp:switch(n.length){case 0:return new o;case 1:return n[0].values.subarray(0,i*s);default:return n.reduce((c,{values:d,length:f})=>(c.array.set(d.subarray(0,f*s),c.offset),c.offset+=f*s,c),{array:new o(i*s),offset:0}).array}}return[...this]}toString(){return`[${[...this].join(",")}]`}getChild(t){var n;return this.getChildAt((n=this.type.children)===null||n===void 0?void 0:n.findIndex(i=>i.name===t))}getChildAt(t){return t>-1&&tn[t])):null}get isMemoized(){return We.isDictionary(this.type)?this.data[0].dictionary.isMemoized:!1}memoize(){if(We.isDictionary(this.type)){const t=new fp(this.data[0].dictionary),n=this.data.map(i=>{const s=i.clone();return s.dictionary=t,s});return new qe(n)}return new fp(this)}unmemoize(){if(We.isDictionary(this.type)&&this.isMemoized){const t=this.data[0].dictionary.unmemoize(),n=this.data.map(i=>{const s=i.clone();return s.dictionary=t,s});return new qe(n)}return this}}xC=Symbol.toStringTag;qe[xC]=(e=>{e.type=We.prototype,e.data=[],e.length=0,e.stride=1,e.numChildren=0,e._nullCount=-1,e._byteLength=-1,e._offsets=new Uint32Array([0]),e[Symbol.isConcatSpreadable]=!0;const t=Object.keys(te).map(n=>te[n]).filter(n=>typeof n=="number"&&n!==te.NONE);for(const n of t){const i=fs.getVisitFnByTypeId(n),s=tr.getVisitFnByTypeId(n),o=dp.getVisitFnByTypeId(n),c=Aa.getVisitFnByTypeId(n);kC[n]={get:i,set:s,indexOf:o,byteLength:c},BC[n]=Object.create(e,{isValid:{value:gu(V9)},get:{value:gu(fs.getVisitFnByTypeId(n))},set:{value:bC(tr.getVisitFnByTypeId(n))},indexOf:{value:TC(dp.getVisitFnByTypeId(n))},getByteLength:{value:gu(Aa.getVisitFnByTypeId(n))}})}return"Vector"})(qe.prototype);class fp extends qe{constructor(t){super(t.data);const n=this.get,i=this.set,s=this.slice,o=new Array(this.length);Object.defineProperty(this,"get",{value(c){const d=o[c];if(d!==void 0)return d;const f=n.call(this,c);return o[c]=f,f}}),Object.defineProperty(this,"set",{value(c,d){i.call(this,c,d),o[c]=d}}),Object.defineProperty(this,"slice",{value:(c,d)=>new fp(s.call(this,c,d))}),Object.defineProperty(this,"isMemoized",{value:!0}),Object.defineProperty(this,"unmemoize",{value:()=>new qe(this.data)}),Object.defineProperty(this,"memoize",{value:()=>this})}}function m4(e){if(e){if(e instanceof Ut)return new qe([e]);if(e instanceof qe)return new qe(e.data);if(e.type instanceof We)return new qe([Ze(e)]);if(Array.isArray(e))return new qe(e.flatMap(t=>YK(t)));if(ArrayBuffer.isView(e)){e instanceof DataView&&(e=new Uint8Array(e.buffer));const t={offset:0,length:e.length,nullCount:0,data:e};if(e instanceof Int8Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new m9}))]);if(e instanceof Int16Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new w9}))]);if(e instanceof Int32Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new Xl}))]);if(e instanceof Ko)return new qe([Ze(Object.assign(Object.assign({},t),{type:new u4}))]);if(e instanceof Uint8Array||e instanceof Uint8ClampedArray)return new qe([Ze(Object.assign(Object.assign({},t),{type:new L9}))]);if(e instanceof Uint16Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new b9}))]);if(e instanceof Uint32Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new T9}))]);if(e instanceof Zo)return new qe([Ze(Object.assign(Object.assign({},t),{type:new v9}))]);if(e instanceof Float32Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new E9}))]);if(e instanceof Float64Array)return new qe([Ze(Object.assign(Object.assign({},t),{type:new h4}))]);throw new Error("Unrecognized input")}}throw new Error("Unrecognized input")}function YK(e){return e instanceof Ut?[e]:e instanceof qe?e.data:m4(e).data}function XK(e){if(!e||e.length<=0)return function(s){return!0};let t="";const n=e.filter(i=>i===i);return n.length>0&&(t=` switch (x) {${n.map(i=>` case ${KK(i)}:`).join("")} return false; }`),e.length!==n.length&&(t=`if (x !== x) return false; ${t}`),new Function("x",`${t} return true;`)}function KK(e){return typeof e!="bigint"?Dl(e):fN?`${Dl(e)}n`:`"${Dl(e)}"`}const z6=(e,t)=>(Math.ceil(e)*t+63&-64||64)/t,ZK=(e,t=0)=>e.length>=t?e.subarray(0,t):_2(new e.constructor(t),e,0);class w4{constructor(t,n=1){this.buffer=t,this.stride=n,this.BYTES_PER_ELEMENT=t.BYTES_PER_ELEMENT,this.ArrayType=t.constructor,this._resize(this.length=Math.ceil(t.length/n))}get byteLength(){return Math.ceil(this.length*this.stride)*this.BYTES_PER_ELEMENT}get reservedLength(){return this.buffer.length/this.stride}get reservedByteLength(){return this.buffer.byteLength}set(t,n){return this}append(t){return this.set(this.length,t)}reserve(t){if(t>0){this.length+=t;const n=this.stride,i=this.length*n,s=this.buffer.length;i>=s&&this._resize(s===0?z6(i*1,this.BYTES_PER_ELEMENT):z6(i*2,this.BYTES_PER_ELEMENT))}return this}flush(t=this.length){t=z6(t*this.stride,this.BYTES_PER_ELEMENT);const n=ZK(this.buffer,t);return this.clear(),n}clear(){return this.length=0,this._resize(0),this}_resize(t){return this.buffer=_2(new this.ArrayType(t),this.buffer)}}w4.prototype.offset=0;class l0 extends w4{last(){return this.get(this.length-1)}get(t){return this.buffer[t]}set(t,n){return this.reserve(t-this.length+1),this.buffer[t*this.stride]=n,this}}class FC extends l0{constructor(t=new Uint8Array(0)){super(t,1/8),this.numValid=0}get numInvalid(){return this.length-this.numValid}get(t){return this.buffer[t>>3]>>t%8&1}set(t,n){const{buffer:i}=this.reserve(t-this.length+1),s=t>>3,o=t%8,c=i[s]>>o&1;return n?c===0&&(i[s]|=1<this.length&&this.set(t-1,0),super.flush(t+1)}}let ki=class{constructor({type:t,nullValues:n}){this.length=0,this.finished=!1,this.type=t,this.children=[],this.nullValues=n,this.stride=aa(t),this._nulls=new FC,n&&n.length>0&&(this._isValid=XK(n))}static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t){throw new Error('"throughDOM" not available in this environment')}toVector(){return new qe([this.flush()])}get ArrayType(){return this.type.ArrayType}get nullCount(){return this._nulls.numInvalid}get numChildren(){return this.children.length}get byteLength(){let t=0;const{_offsets:n,_values:i,_nulls:s,_typeIds:o,children:c}=this;return n&&(t+=n.byteLength),i&&(t+=i.byteLength),s&&(t+=s.byteLength),o&&(t+=o.byteLength),c.reduce((d,f)=>d+f.byteLength,t)}get reservedLength(){return this._nulls.reservedLength}get reservedByteLength(){let t=0;return this._offsets&&(t+=this._offsets.reservedByteLength),this._values&&(t+=this._values.reservedByteLength),this._nulls&&(t+=this._nulls.reservedByteLength),this._typeIds&&(t+=this._typeIds.reservedByteLength),this.children.reduce((n,i)=>n+i.reservedByteLength,t)}get valueOffsets(){return this._offsets?this._offsets.buffer:null}get values(){return this._values?this._values.buffer:null}get nullBitmap(){return this._nulls?this._nulls.buffer:null}get typeIds(){return this._typeIds?this._typeIds.buffer:null}append(t){return this.set(this.length,t)}isValid(t){return this._isValid(t)}set(t,n){return this.setValid(t,this.isValid(n))&&this.setValue(t,n),this}setValue(t,n){this._setValue(this,t,n)}setValid(t,n){return this.length=this._nulls.set(t,+n).length,n}addChild(t,n=`${this.numChildren}`){throw new Error(`Cannot append children to non-nested type "${this.type}"`)}getChildAt(t){return this.children[t]||null}flush(){let t,n,i,s;const{type:o,length:c,nullCount:d,_typeIds:f,_offsets:u,_values:a,_nulls:m}=this;(n=f==null?void 0:f.flush(c))?s=u==null?void 0:u.flush(c):(s=u==null?void 0:u.flush(c))?t=a==null?void 0:a.flush(u.last()):t=a==null?void 0:a.flush(c),d>0&&(i=m==null?void 0:m.flush(c));const y=this.children.map(p=>p.flush());return this.clear(),Ze({type:o,length:c,nullCount:d,children:y,child:y[0],data:t,typeIds:n,nullBitmap:i,valueOffsets:s})}finish(){this.finished=!0;for(const t of this.children)t.finish();return this}clear(){var t,n,i,s;this.length=0,(t=this._nulls)===null||t===void 0||t.clear(),(n=this._values)===null||n===void 0||n.clear(),(i=this._offsets)===null||i===void 0||i.clear(),(s=this._typeIds)===null||s===void 0||s.clear();for(const o of this.children)o.clear();return this}};ki.prototype.length=1;ki.prototype.stride=1;ki.prototype.children=null;ki.prototype.finished=!1;ki.prototype.nullValues=null;ki.prototype._isValid=()=>!0;class mc extends ki{constructor(t){super(t),this._values=new l0(new this.ArrayType(0),this.stride)}setValue(t,n){const i=this._values;return i.reserve(t-i.length+1),super.setValue(t,n)}}class L4 extends ki{constructor(t){super(t),this._pendingLength=0,this._offsets=new IC}setValue(t,n){const i=this._pending||(this._pending=new Map),s=i.get(t);s&&(this._pendingLength-=s.length),this._pendingLength+=n instanceof o0?n[vr].length:n.length,i.set(t,n)}setValid(t,n){return super.setValid(t,n)?!0:((this._pending||(this._pending=new Map)).set(t,void 0),!1)}clear(){return this._pendingLength=0,this._pending=void 0,super.clear()}flush(){return this._flush(),super.flush()}finish(){return this._flush(),super.finish()}_flush(){const t=this._pending,n=this._pendingLength;return this._pendingLength=0,this._pending=void 0,t&&t.size>0&&this._flushPending(t,n),this}}class A5{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}metaDataLength(){return this.bb.readInt32(this.bb_pos+8)}bodyLength(){return this.bb.readInt64(this.bb_pos+16)}static sizeOf(){return 24}static createBlock(t,n,i,s){return t.prep(8,24),t.writeInt64(s),t.pad(4),t.writeInt32(i),t.writeInt64(n),t.offset()}}const $6=2,fa=4,Eo=4,Qt=4,wl=new Int32Array(2),jk=new Float32Array(wl.buffer),Uk=new Float64Array(wl.buffer),Fg=new Uint16Array(new Uint8Array([1,0]).buffer)[0]===1;let Ao=class N5{constructor(t,n){this.low=t|0,this.high=n|0}static create(t,n){return t==0&&n==0?N5.ZERO:new N5(t,n)}toFloat64(){return(this.low>>>0)+this.high*4294967296}equals(t){return this.low==t.low&&this.high==t.high}};Ao.ZERO=new Ao(0,0);var C5;(function(e){e[e.UTF8_BYTES=1]="UTF8_BYTES",e[e.UTF16_STRING=2]="UTF16_STRING"})(C5||(C5={}));let Mu=class OC{constructor(t){this.bytes_=t,this.position_=0}static allocate(t){return new OC(new Uint8Array(t))}clear(){this.position_=0}bytes(){return this.bytes_}position(){return this.position_}setPosition(t){this.position_=t}capacity(){return this.bytes_.length}readInt8(t){return this.readUint8(t)<<24>>24}readUint8(t){return this.bytes_[t]}readInt16(t){return this.readUint16(t)<<16>>16}readUint16(t){return this.bytes_[t]|this.bytes_[t+1]<<8}readInt32(t){return this.bytes_[t]|this.bytes_[t+1]<<8|this.bytes_[t+2]<<16|this.bytes_[t+3]<<24}readUint32(t){return this.readInt32(t)>>>0}readInt64(t){return new Ao(this.readInt32(t),this.readInt32(t+4))}readUint64(t){return new Ao(this.readUint32(t),this.readUint32(t+4))}readFloat32(t){return wl[0]=this.readInt32(t),jk[0]}readFloat64(t){return wl[Fg?0:1]=this.readInt32(t),wl[Fg?1:0]=this.readInt32(t+4),Uk[0]}writeInt8(t,n){this.bytes_[t]=n}writeUint8(t,n){this.bytes_[t]=n}writeInt16(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8}writeUint16(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8}writeInt32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeUint32(t,n){this.bytes_[t]=n,this.bytes_[t+1]=n>>8,this.bytes_[t+2]=n>>16,this.bytes_[t+3]=n>>24}writeInt64(t,n){this.writeInt32(t,n.low),this.writeInt32(t+4,n.high)}writeUint64(t,n){this.writeUint32(t,n.low),this.writeUint32(t+4,n.high)}writeFloat32(t,n){jk[0]=n,this.writeInt32(t,wl[0])}writeFloat64(t,n){Uk[0]=n,this.writeInt32(t,wl[Fg?0:1]),this.writeInt32(t+4,wl[Fg?1:0])}getBufferIdentifier(){if(this.bytes_.length>10)+55296,(c&(1<<10)-1)+56320))}return s}__union_with_string(t,n){return typeof t=="string"?this.__string(n):this.__union(t,n)}__indirect(t){return t+this.readInt32(t)}__vector(t){return t+this.readInt32(t)+fa}__vector_len(t){return this.readInt32(t+this.readInt32(t))}__has_identifier(t){if(t.length!=Eo)throw new Error("FlatBuffers: file identifier must be length "+Eo);for(let n=0;nthis.minalign&&(this.minalign=t);const i=~(this.bb.capacity()-this.space+n)+1&t-1;for(;this.space=0&&this.vtable[n]==0;n--);const i=n+1;for(;n>=0;n--)this.addInt16(this.vtable[n]!=0?t-this.vtable[n]:0);const s=2;this.addInt16(t-this.object_start);const o=(i+s)*$6;this.addInt16(o);let c=0;const d=this.space;e:for(n=0;n=0;c--)this.writeInt8(o.charCodeAt(c))}this.prep(this.minalign,fa+s),this.addOffset(t),s&&this.addInt32(this.bb.capacity()-this.space),this.bb.setPosition(this.space)}finishSizePrefixed(t,n){this.finish(t,n,!0)}requiredField(t,n){const i=this.bb.capacity()-t,s=i-this.bb.readInt32(i);if(!(this.bb.readInt16(s+n)!=0))throw new Error("FlatBuffers: field "+n+" must be set")}startVector(t,n,i){this.notNested(),this.vector_num_elems=n,this.prep(fa,t*n),this.prep(i,t*n)}endVector(){return this.writeInt32(this.vector_num_elems),this.offset()}createSharedString(t){if(!t)return 0;if(this.string_maps||(this.string_maps=new Map),this.string_maps.has(t))return this.string_maps.get(t);const n=this.createString(t);return this.string_maps.set(t,n),n}createString(t){if(!t)return 0;let n;if(t instanceof Uint8Array)n=t;else{n=[];let i=0;for(;i=56320)s=o;else{const c=t.charCodeAt(i++);s=(o<<10)+c+(65536-(55296<<10)-56320)}s<128?n.push(s):(s<2048?n.push(s>>6&31|192):(s<65536?n.push(s>>12&15|224):n.push(s>>18&7|240,s>>12&63|128),n.push(s>>6&63|128)),n.push(s&63|128))}}this.addInt8(0),this.startVector(1,n.length,1),this.bb.setPosition(this.space-=n.length);for(let i=0,s=this.space,o=this.bb.bytes();i=0;i--)t.addInt32(n[i]);return t.endVector()}static startTypeIdsVector(t,n){t.startVector(4,n,4)}static endUnion(t){return t.endObject()}static createUnion(t,n,i){return Kc.startUnion(t),Kc.addMode(t,n),Kc.addTypeIds(t,i),Kc.endUnion(t)}};class gd{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsUtf8(t,n){return(n||new gd).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsUtf8(t,n){return t.setPosition(t.position()+Qt),(n||new gd).__init(t.readInt32(t.position())+t.position(),t)}static startUtf8(t){t.startObject(0)}static endUtf8(t){return t.endObject()}static createUtf8(t){return gd.startUtf8(t),gd.endUtf8(t)}}var gt;(function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.FloatingPoint=3]="FloatingPoint",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct_=13]="Struct_",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.LargeBinary=19]="LargeBinary",e[e.LargeUtf8=20]="LargeUtf8",e[e.LargeList=21]="LargeList"})(gt||(gt={}));let $s=class I_{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsField(t,n){return(n||new I_).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsField(t,n){return t.setPosition(t.position()+Qt),(n||new I_).__init(t.readInt32(t.position())+t.position(),t)}name(t){const n=this.bb.__offset(this.bb_pos,4);return n?this.bb.__string(this.bb_pos+n,t):null}nullable(){const t=this.bb.__offset(this.bb_pos,6);return t?!!this.bb.readInt8(this.bb_pos+t):!1}typeType(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.readUint8(this.bb_pos+t):gt.NONE}type(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.__union(t,this.bb_pos+n):null}dictionary(t){const n=this.bb.__offset(this.bb_pos,12);return n?(t||new So).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}children(t,n){const i=this.bb.__offset(this.bb_pos,14);return i?(n||new I_).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}childrenLength(){const t=this.bb.__offset(this.bb_pos,14);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const i=this.bb.__offset(this.bb_pos,16);return i?(n||new Fn).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,16);return t?this.bb.__vector_len(this.bb_pos+t):0}static startField(t){t.startObject(7)}static addName(t,n){t.addFieldOffset(0,n,0)}static addNullable(t,n){t.addFieldInt8(1,+n,0)}static addTypeType(t,n){t.addFieldInt8(2,n,gt.NONE)}static addType(t,n){t.addFieldOffset(3,n,0)}static addDictionary(t,n){t.addFieldOffset(4,n,0)}static addChildren(t,n){t.addFieldOffset(5,n,0)}static createChildrenVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startChildrenVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(6,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endField(t){return t.endObject()}},ra=class yo{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsSchema(t,n){return(n||new yo).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsSchema(t,n){return t.setPosition(t.position()+Qt),(n||new yo).__init(t.readInt32(t.position())+t.position(),t)}endianness(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Nu.Little}fields(t,n){const i=this.bb.__offset(this.bb_pos,6);return i?(n||new $s).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}fieldsLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const i=this.bb.__offset(this.bb_pos,8);return i?(n||new Fn).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}features(t){const n=this.bb.__offset(this.bb_pos,10);return n?this.bb.readInt64(this.bb.__vector(this.bb_pos+n)+t*8):this.bb.createLong(0,0)}featuresLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}static startSchema(t){t.startObject(4)}static addEndianness(t,n){t.addFieldInt16(0,n,Nu.Little)}static addFields(t,n){t.addFieldOffset(1,n,0)}static createFieldsVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startFieldsVector(t,n){t.startVector(4,n,4)}static addCustomMetadata(t,n){t.addFieldOffset(2,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static addFeatures(t,n){t.addFieldOffset(3,n,0)}static createFeaturesVector(t,n){t.startVector(8,n.length,8);for(let i=n.length-1;i>=0;i--)t.addInt64(n[i]);return t.endVector()}static startFeaturesVector(t,n){t.startVector(8,n,8)}static endSchema(t){return t.endObject()}static finishSchemaBuffer(t,n){t.finish(n)}static finishSizePrefixedSchemaBuffer(t,n){t.finish(n,void 0,!0)}static createSchema(t,n,i,s,o){return yo.startSchema(t),yo.addEndianness(t,n),yo.addFields(t,i),yo.addCustomMetadata(t,s),yo.addFeatures(t,o),yo.endSchema(t)}};class Es{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsFooter(t,n){return(n||new Es).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsFooter(t,n){return t.setPosition(t.position()+Qt),(n||new Es).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Au.V1}schema(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new ra).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}dictionaries(t,n){const i=this.bb.__offset(this.bb_pos,8);return i?(n||new A5).__init(this.bb.__vector(this.bb_pos+i)+t*24,this.bb):null}dictionariesLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}recordBatches(t,n){const i=this.bb.__offset(this.bb_pos,10);return i?(n||new A5).__init(this.bb.__vector(this.bb_pos+i)+t*24,this.bb):null}recordBatchesLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.__vector_len(this.bb_pos+t):0}customMetadata(t,n){const i=this.bb.__offset(this.bb_pos,12);return i?(n||new Fn).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startFooter(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,Au.V1)}static addSchema(t,n){t.addFieldOffset(1,n,0)}static addDictionaries(t,n){t.addFieldOffset(2,n,0)}static startDictionariesVector(t,n){t.startVector(24,n,8)}static addRecordBatches(t,n){t.addFieldOffset(3,n,0)}static startRecordBatchesVector(t,n){t.startVector(24,n,8)}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endFooter(t){return t.endObject()}static finishFooterBuffer(t,n){t.finish(n)}static finishSizePrefixedFooterBuffer(t,n){t.finish(n,void 0,!0)}}class Ot{constructor(t=[],n,i){this.fields=t||[],this.metadata=n||new Map,i||(i=P5(t)),this.dictionaries=i}get[Symbol.toStringTag](){return"Schema"}get names(){return this.fields.map(t=>t.name)}toString(){return`Schema<{ ${this.fields.map((t,n)=>`${n}: ${t}`).join(", ")} }>`}select(t){const n=new Set(t),i=this.fields.filter(s=>n.has(s.name));return new Ot(i,this.metadata)}selectAt(t){const n=t.map(i=>this.fields[i]).filter(Boolean);return new Ot(n,this.metadata)}assign(...t){const n=t[0]instanceof Ot?t[0]:Array.isArray(t[0])?new Ot(t[0]):new Ot(t),i=[...this.fields],s=Ig(Ig(new Map,this.metadata),n.metadata),o=n.fields.filter(d=>{const f=i.findIndex(u=>u.name===d.name);return~f?(i[f]=d.clone({metadata:Ig(Ig(new Map,i[f].metadata),d.metadata)}))&&!1:!0}),c=P5(o,new Map);return new Ot([...i,...o],s,new Map([...this.dictionaries,...c]))}}Ot.prototype.fields=null;Ot.prototype.metadata=null;Ot.prototype.dictionaries=null;let Vt=class R5{constructor(t,n,i=!1,s){this.name=t,this.type=n,this.nullable=i,this.metadata=s||new Map}static new(...t){let[n,i,s,o]=t;return t[0]&&typeof t[0]=="object"&&({name:n}=t[0],i===void 0&&(i=t[0].type),s===void 0&&(s=t[0].nullable),o===void 0&&(o=t[0].metadata)),new R5(`${n}`,i,s,o)}get typeId(){return this.type.typeId}get[Symbol.toStringTag](){return"Field"}toString(){return`${this.name}: ${this.type}`}clone(...t){let[n,i,s,o]=t;return!t[0]||typeof t[0]!="object"?[n=this.name,i=this.type,s=this.nullable,o=this.metadata]=t:{name:n=this.name,type:i=this.type,nullable:s=this.nullable,metadata:o=this.metadata}=t[0],R5.new(n,i,s,o)}};Vt.prototype.type=null;Vt.prototype.name=null;Vt.prototype.nullable=null;Vt.prototype.metadata=null;function Ig(e,t){return new Map([...e||new Map,...t||new Map])}function P5(e,t=new Map){for(let n=-1,i=e.length;++n0&&P5(o.children,t)}return t}var Hk=Ao,JK=MC,QK=Mu;class b2{constructor(t,n=ts.V4,i,s){this.schema=t,this.version=n,i&&(this._recordBatches=i),s&&(this._dictionaryBatches=s)}static decode(t){t=new QK(St(t));const n=Es.getRootAsFooter(t),i=Ot.decode(n.schema());return new eZ(i,n)}static encode(t){const n=new JK,i=Ot.encode(n,t.schema);Es.startRecordBatchesVector(n,t.numRecordBatches);for(const c of[...t.recordBatches()].slice().reverse())Na.encode(n,c);const s=n.endVector();Es.startDictionariesVector(n,t.numDictionaries);for(const c of[...t.dictionaryBatches()].slice().reverse())Na.encode(n,c);const o=n.endVector();return Es.startFooter(n),Es.addSchema(n,i),Es.addVersion(n,ts.V4),Es.addRecordBatches(n,s),Es.addDictionaries(n,o),Es.finishFooterBuffer(n,Es.endFooter(n)),n.asUint8Array()}get numRecordBatches(){return this._recordBatches.length}get numDictionaries(){return this._dictionaryBatches.length}*recordBatches(){for(let t,n=-1,i=this.numRecordBatches;++n=0&&t=0&&t=0&&t=0&&tthis._closedPromiseResolve=t)}get closed(){return this._closedPromise}cancel(t){return Ae(this,void 0,void 0,function*(){yield this.return(t)})}write(t){this._ensureOpen()&&(this.resolvers.length<=0?this._values.push(t):this.resolvers.shift().resolve({done:!1,value:t}))}abort(t){this._closedPromiseResolve&&(this.resolvers.length<=0?this._error={error:t}:this.resolvers.shift().reject({done:!0,value:t}))}close(){if(this._closedPromiseResolve){const{resolvers:t}=this;for(;t.length>0;)t.shift().resolve(un);this._closedPromiseResolve(),this._closedPromiseResolve=void 0}}[Symbol.asyncIterator](){return this}toDOMStream(t){return ks.toDOMStream(this._closedPromiseResolve||this._error?this:this._values,t)}toNodeStream(t){return ks.toNodeStream(this._closedPromiseResolve||this._error?this:this._values,t)}throw(t){return Ae(this,void 0,void 0,function*(){return yield this.abort(t),un})}return(t){return Ae(this,void 0,void 0,function*(){return yield this.close(),un})}read(t){return Ae(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return Ae(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(...t){return this._values.length>0?Promise.resolve({done:!1,value:this._values.shift()}):this._error?Promise.reject({done:!0,value:this._error.error}):this._closedPromiseResolve?new Promise((n,i)=>{this.resolvers.push({resolve:n,reject:i})}):Promise.resolve(un)}_ensureOpen(){if(this._closedPromiseResolve)return!0;throw new Error("AsyncQueue is closed")}}class _u extends tZ{write(t){if((t=St(t)).byteLength>0)return super.write(t)}toString(t=!1){return t?I5(this.toUint8Array(!0)):this.toUint8Array(!1).then(I5)}toUint8Array(t=!1){return t?Hr(this._values)[0]:(()=>Ae(this,void 0,void 0,function*(){var n,i;const s=[];let o=0;try{for(var c=Pl(this),d;d=yield c.next(),!d.done;){const f=d.value;s.push(f),o+=f.byteLength}}catch(f){n={error:f}}finally{try{d&&!d.done&&(i=c.return)&&(yield i.call(c))}finally{if(n)throw n.error}}return Hr(s,o)[0]}))()}}class T2{constructor(t){t&&(this.source=new nZ(ks.fromIterable(t)))}[Symbol.iterator](){return this}next(t){return this.source.next(t)}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}peek(t){return this.source.peek(t)}read(t){return this.source.read(t)}}class Zl{constructor(t){t instanceof Zl?this.source=t.source:t instanceof _u?this.source=new Rc(ks.fromAsyncIterable(t)):pN(t)?this.source=new Rc(ks.fromNodeStream(t)):p9(t)?this.source=new Rc(ks.fromDOMStream(t)):_N(t)?this.source=new Rc(ks.fromDOMStream(t.body)):bh(t)?this.source=new Rc(ks.fromIterable(t)):Yl(t)?this.source=new Rc(ks.fromAsyncIterable(t)):rf(t)&&(this.source=new Rc(ks.fromAsyncIterable(t)))}[Symbol.asyncIterator](){return this}next(t){return this.source.next(t)}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}get closed(){return this.source.closed}cancel(t){return this.source.cancel(t)}peek(t){return this.source.peek(t)}read(t){return this.source.read(t)}}class nZ{constructor(t){this.source=t}cancel(t){this.return(t)}peek(t){return this.next(t,"peek").value}read(t){return this.next(t,"read").value}next(t,n="read"){return this.source.next({cmd:n,size:t})}throw(t){return Object.create(this.source.throw&&this.source.throw(t)||un)}return(t){return Object.create(this.source.return&&this.source.return(t)||un)}}class Rc{constructor(t){this.source=t,this._closedPromise=new Promise(n=>this._closedPromiseResolve=n)}cancel(t){return Ae(this,void 0,void 0,function*(){yield this.return(t)})}get closed(){return this._closedPromise}read(t){return Ae(this,void 0,void 0,function*(){return(yield this.next(t,"read")).value})}peek(t){return Ae(this,void 0,void 0,function*(){return(yield this.next(t,"peek")).value})}next(t,n="read"){return Ae(this,void 0,void 0,function*(){return yield this.source.next({cmd:n,size:t})})}throw(t){return Ae(this,void 0,void 0,function*(){const n=this.source.throw&&(yield this.source.throw(t))||un;return this._closedPromiseResolve&&this._closedPromiseResolve(),this._closedPromiseResolve=void 0,Object.create(n)})}return(t){return Ae(this,void 0,void 0,function*(){const n=this.source.return&&(yield this.source.return(t))||un;return this._closedPromiseResolve&&this._closedPromiseResolve(),this._closedPromiseResolve=void 0,Object.create(n)})}}class $k extends T2{constructor(t,n){super(),this.position=0,this.buffer=St(t),this.size=typeof n>"u"?this.buffer.byteLength:n}readInt32(t){const{buffer:n,byteOffset:i}=this.readAt(t,4);return new DataView(n,i).getInt32(0,!0)}seek(t){return this.position=Math.min(t,this.size),tAe(this,void 0,void 0,function*(){this.size=(yield t.stat()).size,delete this._pending}))()}readInt32(t){return Ae(this,void 0,void 0,function*(){const{buffer:n,byteOffset:i}=yield this.readAt(t,4);return new DataView(n,i).getInt32(0,!0)})}seek(t){return Ae(this,void 0,void 0,function*(){return this._pending&&(yield this._pending),this.position=Math.min(t,this.size),t>>16,this.buffer[1]&65535,this.buffer[0]>>>16,this.buffer[0]&65535]),i=new Uint32Array([t.buffer[1]>>>16,t.buffer[1]&65535,t.buffer[0]>>>16,t.buffer[0]&65535]);let s=n[3]*i[3];this.buffer[0]=s&65535;let o=s>>>16;return s=n[2]*i[3],o+=s,s=n[3]*i[2]>>>0,o+=s,this.buffer[0]+=o<<16,this.buffer[1]=o>>>0>>16,this.buffer[1]+=n[1]*i[3]+n[2]*i[2]+n[3]*i[1],this.buffer[1]+=n[0]*i[3]+n[1]*i[2]+n[2]*i[1]+n[3]*i[0]<<16,this}_plus(t){const n=this.buffer[0]+t.buffer[0]>>>0;this.buffer[1]+=t.buffer[1],n>>0&&++this.buffer[1],this.buffer[0]=n}lessThan(t){return this.buffer[1]>>0,n[2]=this.buffer[2]+t.buffer[2]>>>0,n[1]=this.buffer[1]+t.buffer[1]>>>0,n[0]=this.buffer[0]+t.buffer[0]>>>0,n[0]>>0&&++n[1],n[1]>>0&&++n[2],n[2]>>0&&++n[3],this.buffer[3]=n[3],this.buffer[2]=n[2],this.buffer[1]=n[1],this.buffer[0]=n[0],this}hex(){return`${tu(this.buffer[3])} ${tu(this.buffer[2])} ${tu(this.buffer[1])} ${tu(this.buffer[0])}`}static multiply(t,n){return new mr(new Uint32Array(t.buffer)).times(n)}static add(t,n){return new mr(new Uint32Array(t.buffer)).plus(n)}static from(t,n=new Uint32Array(4)){return mr.fromString(typeof t=="string"?t:t.toString(),n)}static fromNumber(t,n=new Uint32Array(4)){return mr.fromString(t.toString(),n)}static fromString(t,n=new Uint32Array(4)){const i=t.startsWith("-"),s=t.length,o=new mr(n);for(let c=i?1:0;c0&&this.readData(t,i)||new Uint8Array(0)}readOffsets(t,n){return this.readData(t,n)}readTypeIds(t,n){return this.readData(t,n)}readData(t,{length:n,offset:i}=this.nextBufferRange()){return this.bytes.subarray(i,i+n)}readDictionary(t){return this.dictionaries.get(t.id)}}class rZ extends NC{constructor(t,n,i,s){super(new Uint8Array(0),n,i,s),this.sources=t}readNullBitmap(t,n,{offset:i}=this.nextBufferRange()){return n<=0?new Uint8Array(0):L2(this.sources[i])}readOffsets(t,{offset:n}=this.nextBufferRange()){return bt(Uint8Array,bt(Int32Array,this.sources[n]))}readTypeIds(t,{offset:n}=this.nextBufferRange()){return bt(Uint8Array,bt(t.ArrayType,this.sources[n]))}readData(t,{offset:n}=this.nextBufferRange()){const{sources:i}=this;return We.isTimestamp(t)||(We.isInt(t)||We.isTime(t))&&t.bitWidth===64||We.isDate(t)&&t.unit===ds.MILLISECOND?bt(Uint8Array,Oi.convertArray(i[n])):We.isDecimal(t)?bt(Uint8Array,mr.convertArray(i[n])):We.isBinary(t)||We.isFixedSizeBinary(t)?aZ(i[n]):We.isBool(t)?L2(i[n]):We.isUtf8(t)?c4(i[n].join("")):bt(Uint8Array,bt(t.ArrayType,i[n].map(s=>+s)))}}function aZ(e){const t=e.join(""),n=new Uint8Array(t.length/2);for(let i=0;i>1]=Number.parseInt(t.slice(i,i+2),16);return n}class K9 extends L4{constructor(t){super(t),this._values=new w4(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,St(n))}_flushPending(t,n){const i=this._offsets,s=this._values.reserve(n).buffer;let o=0;for(const[c,d]of t)if(d===void 0)i.set(c,0);else{const f=d.length;s.set(d,o),i.set(c,f),o+=f}}}class CC extends ki{constructor(t){super(t),this._values=new FC}setValue(t,n){this._values.set(t,+n)}}class c0 extends mc{}c0.prototype._setValue=WN;class Z9 extends c0{}Z9.prototype._setValue=F9;class J9 extends c0{}J9.prototype._setValue=I9;class Q9 extends mc{}Q9.prototype._setValue=KN;class RC extends ki{constructor({type:t,nullValues:n,dictionaryHashFunction:i}){super({type:new $o(t.dictionary,t.indices,t.id,t.isOrdered)}),this._nulls=null,this._dictionaryOffset=0,this._keysToIndices=Object.create(null),this.indices=Ad({type:this.type.indices,nullValues:n}),this.dictionary=Ad({type:this.type.dictionary,nullValues:null}),typeof i=="function"&&(this.valueToKey=i)}get values(){return this.indices.values}get nullCount(){return this.indices.nullCount}get nullBitmap(){return this.indices.nullBitmap}get byteLength(){return this.indices.byteLength+this.dictionary.byteLength}get reservedLength(){return this.indices.reservedLength+this.dictionary.reservedLength}get reservedByteLength(){return this.indices.reservedByteLength+this.dictionary.reservedByteLength}isValid(t){return this.indices.isValid(t)}setValid(t,n){const i=this.indices;return n=i.setValid(t,n),this.length=i.length,n}setValue(t,n){const i=this._keysToIndices,s=this.valueToKey(n);let o=i[s];return o===void 0&&(i[s]=o=this._dictionaryOffset+this.dictionary.append(n).length-1),this.indices.setValue(t,o)}flush(){const t=this.type,n=this._dictionary,i=this.dictionary.toVector(),s=this.indices.flush().clone(t);return s.dictionary=n?n.concat(i):i,this.finished||(this._dictionaryOffset+=i.length),this._dictionary=s.dictionary,this.clear(),s}finish(){return this.indices.finish(),this.dictionary.finish(),this._dictionaryOffset=0,this._keysToIndices=Object.create(null),super.finish()}clear(){return this.indices.clear(),this.dictionary.clear(),super.clear()}valueToKey(t){return typeof t=="string"?t:`${t}`}}class e7 extends mc{}e7.prototype._setValue=GN;class PC extends ki{setValue(t,n){const[i]=this.children,s=t*this.stride;for(let o=-1,c=n.length;++o0)throw new Error("FixedSizeListBuilder can only have one child.");const i=this.children.push(t);return this.type=new Fu(this.type.listSize,new Vt(n,t.type,!0)),i}}class d0 extends mc{setValue(t,n){this._values.set(t,n)}}class DC extends d0{setValue(t,n){super.setValue(t,x9(n))}}class jC extends d0{}class UC extends d0{}class f0 extends mc{}f0.prototype._setValue=QN;class t7 extends f0{}t7.prototype._setValue=j9;class n7 extends f0{}n7.prototype._setValue=U9;class Ya extends mc{setValue(t,n){this._values.set(t,n)}}class HC extends Ya{}class zC extends Ya{}class $C extends Ya{}class qC extends Ya{}class VC extends Ya{}class GC extends Ya{}class WC extends Ya{}class YC extends Ya{}class XC extends L4{constructor(t){super(t),this._offsets=new IC}addChild(t,n="0"){if(this.numChildren>0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Md(new Vt(n,t.type,!0)),this.numChildren-1}_flushPending(t){const n=this._offsets,[i]=this.children;for(const[s,o]of t)if(typeof o>"u")n.set(s,0);else{const c=o.length,d=n.set(s,c).buffer[s];for(let f=-1;++f0)throw new Error("ListBuilder can only have one child.");return this.children[this.numChildren]=t,this.type=new Iu(new Vt(n,t.type,!0),this.type.keysSorted),this.numChildren-1}_flushPending(t){const n=this._offsets,[i]=this.children;for(const[s,o]of t)if(o===void 0)n.set(s,0);else{let{[s]:c,[s+1]:d}=n.set(s,o.size).buffer;for(const f of o.entries())if(i.set(c,f),++c>=d)break}}}class ZC extends ki{setValue(t,n){}setValid(t,n){return this.length=Math.max(t+1,this.length),n}}class JC extends ki{setValue(t,n){const{children:i,type:s}=this;switch(Array.isArray(n)||n.constructor){case!0:return s.children.forEach((o,c)=>i[c].set(t,n[c]));case Map:return s.children.forEach((o,c)=>i[c].set(t,n.get(o.name)));default:return s.children.forEach((o,c)=>i[c].set(t,n[o.name]))}}setValid(t,n){return super.setValid(t,n)||this.children.forEach(i=>i.setValid(t,n)),n}addChild(t,n=`${this.numChildren}`){const i=this.children.push(t);return this.type=new Hn([...this.type.children,new Vt(n,t.type,!0)]),i}}class of extends mc{}of.prototype._setValue=YN;class i7 extends of{}i7.prototype._setValue=O9;class s7 extends of{}s7.prototype._setValue=M9;class r7 extends of{}r7.prototype._setValue=A9;class a7 extends of{}a7.prototype._setValue=N9;class lf extends mc{}lf.prototype._setValue=XN;class o7 extends lf{}o7.prototype._setValue=C9;class l7 extends lf{}l7.prototype._setValue=R9;class c7 extends lf{}c7.prototype._setValue=P9;class d7 extends lf{}d7.prototype._setValue=D9;class b4 extends ki{constructor(t){super(t),this._typeIds=new l0(new Int8Array(0),1),typeof t.valueToChildTypeId=="function"&&(this._valueToChildTypeId=t.valueToChildTypeId)}get typeIdToChildIndex(){return this.type.typeIdToChildIndex}append(t,n){return this.set(this.length,t,n)}set(t,n,i){return i===void 0&&(i=this._valueToChildTypeId(this,n,t)),this.setValid(t,this.isValid(n))&&this.setValue(t,n,i),this}setValue(t,n,i){this._typeIds.set(t,i);const s=this.type.typeIdToChildIndex[i],o=this.children[s];o==null||o.set(t,n)}addChild(t,n=`${this.children.length}`){const i=this.children.push(t),{type:{children:s,mode:o,typeIds:c}}=this,d=[...s,new Vt(n,t.type)];return this.type=new Kl(o,[...c,i],d),i}_valueToChildTypeId(t,n,i){throw new Error("Cannot map UnionBuilder value to child typeId. Pass the `childTypeId` as the second argument to unionBuilder.append(), or supply a `valueToChildTypeId` function as part of the UnionBuilder constructor options.")}}class QC extends b4{}class eR extends b4{constructor(t){super(t),this._offsets=new l0(new Int32Array(0))}setValue(t,n,i){const s=this._typeIds.set(t,i).buffer[t],o=this.getChildAt(this.type.typeIdToChildIndex[s]),c=this._offsets.set(t,o.length).buffer[t];o==null||o.set(c,n)}}class f7 extends L4{constructor(t){super(t),this._values=new w4(new Uint8Array(0))}get byteLength(){let t=this._pendingLength+this.length*4;return this._offsets&&(t+=this._offsets.byteLength),this._values&&(t+=this._values.byteLength),this._nulls&&(t+=this._nulls.byteLength),t}setValue(t,n){return super.setValue(t,c4(n))}_flushPending(t,n){}}f7.prototype._flushPending=K9.prototype._flushPending;class oZ extends mt{visitNull(){return ZC}visitBool(){return CC}visitInt(){return Ya}visitInt8(){return HC}visitInt16(){return zC}visitInt32(){return $C}visitInt64(){return qC}visitUint8(){return VC}visitUint16(){return GC}visitUint32(){return WC}visitUint64(){return YC}visitFloat(){return d0}visitFloat16(){return DC}visitFloat32(){return jC}visitFloat64(){return UC}visitUtf8(){return f7}visitBinary(){return K9}visitFixedSizeBinary(){return e7}visitDate(){return c0}visitDateDay(){return Z9}visitDateMillisecond(){return J9}visitTimestamp(){return of}visitTimestampSecond(){return i7}visitTimestampMillisecond(){return s7}visitTimestampMicrosecond(){return r7}visitTimestampNanosecond(){return a7}visitTime(){return lf}visitTimeSecond(){return o7}visitTimeMillisecond(){return l7}visitTimeMicrosecond(){return c7}visitTimeNanosecond(){return d7}visitDecimal(){return Q9}visitList(){return XC}visitStruct(){return JC}visitUnion(){return b4}visitDenseUnion(){return eR}visitSparseUnion(){return QC}visitDictionary(){return RC}visitInterval(){return f0}visitIntervalDayTime(){return t7}visitIntervalYearMonth(){return n7}visitFixedSizeList(){return PC}visitMap(){return KC}}const lZ=new oZ;class st extends mt{compareSchemas(t,n){return t===n||n instanceof t.constructor&&this.compareManyFields(t.fields,n.fields)}compareManyFields(t,n){return t===n||Array.isArray(t)&&Array.isArray(n)&&t.length===n.length&&t.every((i,s)=>this.compareFields(i,n[s]))}compareFields(t,n){return t===n||n instanceof t.constructor&&t.name===n.name&&t.nullable===n.nullable&&this.visit(t.type,n.type)}}function ws(e,t){return t instanceof e.constructor}function u0(e,t){return e===t||ws(e,t)}function Qo(e,t){return e===t||ws(e,t)&&e.bitWidth===t.bitWidth&&e.isSigned===t.isSigned}function T4(e,t){return e===t||ws(e,t)&&e.precision===t.precision}function cZ(e,t){return e===t||ws(e,t)&&e.byteWidth===t.byteWidth}function u7(e,t){return e===t||ws(e,t)&&e.unit===t.unit}function h0(e,t){return e===t||ws(e,t)&&e.unit===t.unit&&e.timezone===t.timezone}function g0(e,t){return e===t||ws(e,t)&&e.unit===t.unit&&e.bitWidth===t.bitWidth}function dZ(e,t){return e===t||ws(e,t)&&e.children.length===t.children.length&&Ca.compareManyFields(e.children,t.children)}function fZ(e,t){return e===t||ws(e,t)&&e.children.length===t.children.length&&Ca.compareManyFields(e.children,t.children)}function h7(e,t){return e===t||ws(e,t)&&e.mode===t.mode&&e.typeIds.every((n,i)=>n===t.typeIds[i])&&Ca.compareManyFields(e.children,t.children)}function uZ(e,t){return e===t||ws(e,t)&&e.id===t.id&&e.isOrdered===t.isOrdered&&Ca.visit(e.indices,t.indices)&&Ca.visit(e.dictionary,t.dictionary)}function g7(e,t){return e===t||ws(e,t)&&e.unit===t.unit}function hZ(e,t){return e===t||ws(e,t)&&e.listSize===t.listSize&&e.children.length===t.children.length&&Ca.compareManyFields(e.children,t.children)}function gZ(e,t){return e===t||ws(e,t)&&e.keysSorted===t.keysSorted&&e.children.length===t.children.length&&Ca.compareManyFields(e.children,t.children)}st.prototype.visitNull=u0;st.prototype.visitBool=u0;st.prototype.visitInt=Qo;st.prototype.visitInt8=Qo;st.prototype.visitInt16=Qo;st.prototype.visitInt32=Qo;st.prototype.visitInt64=Qo;st.prototype.visitUint8=Qo;st.prototype.visitUint16=Qo;st.prototype.visitUint32=Qo;st.prototype.visitUint64=Qo;st.prototype.visitFloat=T4;st.prototype.visitFloat16=T4;st.prototype.visitFloat32=T4;st.prototype.visitFloat64=T4;st.prototype.visitUtf8=u0;st.prototype.visitBinary=u0;st.prototype.visitFixedSizeBinary=cZ;st.prototype.visitDate=u7;st.prototype.visitDateDay=u7;st.prototype.visitDateMillisecond=u7;st.prototype.visitTimestamp=h0;st.prototype.visitTimestampSecond=h0;st.prototype.visitTimestampMillisecond=h0;st.prototype.visitTimestampMicrosecond=h0;st.prototype.visitTimestampNanosecond=h0;st.prototype.visitTime=g0;st.prototype.visitTimeSecond=g0;st.prototype.visitTimeMillisecond=g0;st.prototype.visitTimeMicrosecond=g0;st.prototype.visitTimeNanosecond=g0;st.prototype.visitDecimal=u0;st.prototype.visitList=dZ;st.prototype.visitStruct=fZ;st.prototype.visitUnion=h7;st.prototype.visitDenseUnion=h7;st.prototype.visitSparseUnion=h7;st.prototype.visitDictionary=uZ;st.prototype.visitInterval=g7;st.prototype.visitIntervalDayTime=g7;st.prototype.visitIntervalYearMonth=g7;st.prototype.visitFixedSizeList=hZ;st.prototype.visitMap=gZ;const Ca=new st;function mp(e,t){return Ca.compareSchemas(e,t)}function _Z(e,t){return Ca.compareFields(e,t)}function tR(e,t){return Ca.visit(e,t)}function Ad(e){const t=e.type,n=new(lZ.getVisitFn(t)())(e);if(t.children&&t.children.length>0){const i=e.children||[],s={nullValues:e.nullValues},o=Array.isArray(i)?(c,d)=>i[d]||s:({name:c})=>i[c]||s;for(const[c,d]of t.children.entries()){const{type:f}=d,u=o(d,c);n.children.push(Ad(Object.assign(Object.assign({},u),{type:f})))}}return n}function _7(e,t){if(e instanceof Ut||e instanceof qe||e.type instanceof We||ArrayBuffer.isView(e))return m4(e);const n={type:t??O_(e),nullValues:[null]},i=[...nR(n)(e)],s=i.length===1?i[0]:i.reduce((o,c)=>o.concat(c));return We.isDictionary(s.type)?s.memoize():s}function pZ(e){const t=_7(e),n=new ti(new Ot(t.type.children),t.data[0]);return new In(n)}function O_(e){if(e.length===0)return new Oa;let t=0,n=0,i=0,s=0,o=0,c=0,d=0,f=0;for(const u of e){if(u==null){++t;continue}switch(typeof u){case"bigint":++c;continue;case"boolean":++d;continue;case"number":++s;continue;case"string":++o;continue;case"object":Array.isArray(u)?++n:Object.prototype.toString.call(u)==="[object Date]"?++f:++i;continue}throw new TypeError("Unable to infer Vector type from input values, explicit type declaration expected")}if(s+t===e.length)return new h4;if(o+t===e.length)return new $o(new ku,new Xl);if(c+t===e.length)return new u4;if(d+t===e.length)return new Bu;if(f+t===e.length)return new zN;if(n+t===e.length){const u=e,a=O_(u[u.findIndex(m=>m!=null)]);if(u.every(m=>m==null||tR(a,O_(m))))return new Md(new Vt("",a,!0))}else if(i+t===e.length){const u=new Map;for(const a of e)for(const m of Object.keys(a))!u.has(m)&&a[m]!=null&&u.set(m,new Vt(m,O_([a[m]]),!0));return new Hn([...u.values()])}throw new TypeError("Unable to infer Vector type from input values, explicit type declaration expected")}function nR(e){const{["queueingStrategy"]:t="count"}=e,{["highWaterMark"]:n=t!=="bytes"?Number.POSITIVE_INFINITY:Math.pow(2,14)}=e,i=t!=="bytes"?"length":"byteLength";return function*(s){let o=0;const c=Ad(e);for(const d of s)c.append(d)[i]>=n&&++o&&(yield c.toVector());(c.finish().length>0||o===0)&&(yield c.toVector())}}function yZ(e){const{["queueingStrategy"]:t="count"}=e,{["highWaterMark"]:n=t!=="bytes"?Number.POSITIVE_INFINITY:Math.pow(2,14)}=e,i=t!=="bytes"?"length":"byteLength";return function(s){return Ir(this,arguments,function*(){var o,c;let d=0;const f=Ad(e);try{for(var u=Pl(s),a;a=yield Qe(u.next()),!a.done;){const m=a.value;f.append(m)[i]>=n&&++d&&(yield yield Qe(f.toVector()))}}catch(m){o={error:m}}finally{try{a&&!a.done&&(c=u.return)&&(yield Qe(c.call(u)))}finally{if(o)throw o.error}}(f.finish().length>0||d===0)&&(yield yield Qe(f.toVector()))})}}function q6(e,t){return mZ(e,t.map(n=>n.data.concat()))}function mZ(e,t){const n=[...e.fields],i=[],s={numBatches:t.reduce((m,y)=>Math.max(m,y.length),0)};let o=0,c=0,d=-1;const f=t.length;let u,a=[];for(;s.numBatches-- >0;){for(c=Number.POSITIVE_INFINITY,d=-1;++d0&&(i[o++]=Ze({type:new Hn(n),length:c,nullCount:0,children:a.slice()})))}return[e=e.assign(n),i.map(m=>new ti(e,m))]}function wZ(e,t,n,i,s){var o;const c=(t+63&-64)>>3;for(let d=-1,f=i.length;++d=t)a===t?n[d]=u:(n[d]=u.slice(0,t),s.numBatches=Math.max(s.numBatches,i[d].unshift(u.slice(t,a-t))));else{const m=e[d];e[d]=m.clone({nullable:!0}),n[d]=(o=u==null?void 0:u._changeLengthAndBackfillNullBitmap(t))!==null&&o!==void 0?o:Ze({type:m.type,length:t,nullCount:t,nullBitmap:new Uint8Array(c)})}}return n}var iR;class In{constructor(...t){var n,i;if(t.length===0)return this.batches=[],this.schema=new Ot([]),this._offsets=[0],this;let s,o;t[0]instanceof Ot&&(s=t.shift()),t[t.length-1]instanceof Uint32Array&&(o=t.pop());const c=f=>{if(f){if(f instanceof ti)return[f];if(f instanceof In)return f.batches;if(f instanceof Ut){if(f.type instanceof Hn)return[new ti(new Ot(f.type.children),f)]}else{if(Array.isArray(f))return f.flatMap(u=>c(u));if(typeof f[Symbol.iterator]=="function")return[...f].flatMap(u=>c(u));if(typeof f=="object"){const u=Object.keys(f),a=u.map(p=>new qe([f[p]])),m=new Ot(u.map((p,l)=>new Vt(String(p),a[l].type))),[,y]=q6(m,a);return y.length===0?[new ti(f)]:y}}}return[]},d=t.flatMap(f=>c(f));if(s=(i=s??((n=d[0])===null||n===void 0?void 0:n.schema))!==null&&i!==void 0?i:new Ot([]),!(s instanceof Ot))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");for(const f of d){if(!(f instanceof ti))throw new TypeError("Table constructor expects a [Schema, RecordBatch[]] pair.");if(!mp(s,f.schema))throw new TypeError("Table and inner RecordBatch schemas must be equivalent.")}this.schema=s,this.batches=d,this._offsets=o??wC(this.data)}get data(){return this.batches.map(({data:t})=>t)}get numCols(){return this.schema.fields.length}get numRows(){return this.data.reduce((t,n)=>t+n.length,0)}get nullCount(){return this._nullCount===-1&&(this._nullCount=mC(this.data)),this._nullCount}isValid(t){return!1}get(t){return null}set(t,n){}indexOf(t,n){return-1}getByteLength(t){return 0}[Symbol.iterator](){return this.batches.length>0?G9.visit(new qe(this.data)):new Array(0)[Symbol.iterator]()}toArray(){return[...this]}toString(){return`[ ${this.toArray().join(`, `)} ]`}concat(...t){const n=this.schema,i=this.data.concat(t.flatMap(({data:s})=>s));return new In(n,i.map(s=>new ti(n,s)))}slice(t,n){const i=this.schema;[t,n]=z9({length:this.numRows},t,n);const s=LC(this.data,this._offsets,t,n);return new In(i,s.map(o=>new ti(i,o)))}getChild(t){return this.getChildAt(this.schema.fields.findIndex(n=>n.name===t))}getChildAt(t){if(t>-1&&ti.children[t]);if(n.length===0){const{type:i}=this.schema.fields[t],s=Ze({type:i,length:0,nullCount:0});n.push(s._changeLengthAndBackfillNullBitmap(this.numRows))}return new qe(n)}return null}setChild(t,n){var i;return this.setChildAt((i=this.schema.fields)===null||i===void 0?void 0:i.findIndex(s=>s.name===t),n)}setChildAt(t,n){let i=this.schema,s=[...this.batches];if(t>-1&&tthis.getChildAt(u));[o[t],d[t]]=[c,n],[i,s]=q6(i,d)}return new In(i,s)}select(t){const n=this.schema.fields.reduce((i,s,o)=>i.set(s.name,o),new Map);return this.selectAt(t.map(i=>n.get(i)).filter(i=>i>-1))}selectAt(t){const n=this.schema.selectAt(t),i=this.batches.map(s=>s.selectAt(t));return new In(n,i)}assign(t){const n=this.schema.fields,[i,s]=t.schema.fields.reduce((d,f,u)=>{const[a,m]=d,y=n.findIndex(p=>p.name===f.name);return~y?m[y]=u:a.push(u),d},[[],[]]),o=this.schema.assign(t.schema),c=[...n.map((d,f)=>[f,s[f]]).map(([d,f])=>f===void 0?this.getChildAt(d):t.getChildAt(f)),...i.map(d=>t.getChildAt(d))].filter(Boolean);return new In(...q6(o,c))}}iR=Symbol.toStringTag;In[iR]=(e=>(e.schema=null,e.batches=[],e._offsets=new Uint32Array([0]),e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,e.isValid=gu(V9),e.get=gu(fs.getVisitFn(te.Struct)),e.set=bC(tr.getVisitFn(te.Struct)),e.indexOf=TC(dp.getVisitFn(te.Struct)),e.getByteLength=gu(Aa.getVisitFn(te.Struct)),"Table"))(In.prototype);function LZ(e){const t={},n=Object.entries(e);for(const[i,s]of n)t[i]=m4(s);return new In(t)}function bZ(e){const t={},n=Object.entries(e);for(const[i,s]of n)t[i]=_7(s);return new In(t)}var sR;let ti=class T1{constructor(...t){switch(t.length){case 2:{if([this.schema]=t,!(this.schema instanceof Ot))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");if([,this.data=Ze({nullCount:0,type:new Hn(this.schema.fields),children:this.schema.fields.map(n=>Ze({type:n.type,nullCount:0}))})]=t,!(this.data instanceof Ut))throw new TypeError("RecordBatch constructor expects a [Schema, Data] pair.");[this.schema,this.data]=qk(this.schema,this.data.children);break}case 1:{const[n]=t,{fields:i,children:s,length:o}=Object.keys(n).reduce((f,u,a)=>(f.children[a]=n[u],f.length=Math.max(f.length,n[u].length),f.fields[a]=Vt.new({name:u,type:n[u].type,nullable:!0}),f),{length:0,fields:new Array,children:new Array}),c=new Ot(i),d=Ze({type:new Hn(i),length:o,children:s,nullCount:0});[this.schema,this.data]=qk(c,d.children,o);break}default:throw new TypeError("RecordBatch constructor expects an Object mapping names to child Data, or a [Schema, Data] pair.")}}get dictionaries(){return this._dictionaries||(this._dictionaries=rR(this.schema.fields,this.data.children))}get numCols(){return this.schema.fields.length}get numRows(){return this.data.length}get nullCount(){return this.data.nullCount}isValid(t){return this.data.getValid(t)}get(t){return fs.visit(this.data,t)}set(t,n){return tr.visit(this.data,t,n)}indexOf(t,n){return dp.visit(this.data,t,n)}getByteLength(t){return Aa.visit(this.data,t)}[Symbol.iterator](){return G9.visit(new qe([this.data]))}toArray(){return[...this]}concat(...t){return new In(this.schema,[this,...t])}slice(t,n){const[i]=new qe([this.data]).slice(t,n).data;return new T1(this.schema,i)}getChild(t){var n;return this.getChildAt((n=this.schema.fields)===null||n===void 0?void 0:n.findIndex(i=>i.name===t))}getChildAt(t){return t>-1&&ts.name===t),n)}setChildAt(t,n){let i=this.schema,s=this.data;if(t>-1&&td.name===o);~c&&(s[c]=this.data.children[c])}return new T1(n,Ze({type:i,length:this.numRows,children:s}))}selectAt(t){const n=this.schema.selectAt(t),i=t.map(o=>this.data.children[o]).filter(Boolean),s=Ze({type:new Hn(n.fields),length:this.numRows,children:i});return new T1(n,s)}};sR=Symbol.toStringTag;ti[sR]=(e=>(e._nullCount=-1,e[Symbol.isConcatSpreadable]=!0,"RecordBatch"))(ti.prototype);function qk(e,t,n=t.reduce((i,s)=>Math.max(i,s.length),0)){var i;const s=[...e.fields],o=[...t],c=(n+63&-64)>>3;for(const[d,f]of e.fields.entries()){const u=t[d];(!u||u.length!==n)&&(s[d]=f.clone({nullable:!0}),o[d]=(i=u==null?void 0:u._changeLengthAndBackfillNullBitmap(n))!==null&&i!==void 0?i:Ze({type:f.type,length:n,nullCount:n,nullBitmap:new Uint8Array(c)}))}return[e.assign(s),Ze({type:new Hn(s),length:n,children:o})]}function rR(e,t,n=new Map){for(let i=-1,s=e.length;++i0&&rR(c.children,d.children,n)}return n}class p7 extends ti{constructor(t){const n=t.fields.map(s=>Ze({type:s.type})),i=Ze({type:new Hn(t.fields),nullCount:0,children:n});super(t,i)}}var wp;(function(e){e[e.BUFFER=0]="BUFFER"})(wp||(wp={}));var Lp;(function(e){e[e.LZ4_FRAME=0]="LZ4_FRAME",e[e.ZSTD=1]="ZSTD"})(Lp||(Lp={}));class Ll{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsBodyCompression(t,n){return(n||new Ll).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsBodyCompression(t,n){return t.setPosition(t.position()+Qt),(n||new Ll).__init(t.readInt32(t.position())+t.position(),t)}codec(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt8(this.bb_pos+t):Lp.LZ4_FRAME}method(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readInt8(this.bb_pos+t):wp.BUFFER}static startBodyCompression(t){t.startObject(2)}static addCodec(t,n){t.addFieldInt8(0,n,Lp.LZ4_FRAME)}static addMethod(t,n){t.addFieldInt8(1,n,wp.BUFFER)}static endBodyCompression(t){return t.endObject()}static createBodyCompression(t,n,i){return Ll.startBodyCompression(t),Ll.addCodec(t,n),Ll.addMethod(t,i),Ll.endBodyCompression(t)}}let aR=class{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}offset(){return this.bb.readInt64(this.bb_pos)}length(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createBuffer(t,n,i){return t.prep(8,16),t.writeInt64(i),t.writeInt64(n),t.offset()}},oR=class{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}length(){return this.bb.readInt64(this.bb_pos)}nullCount(){return this.bb.readInt64(this.bb_pos+8)}static sizeOf(){return 16}static createFieldNode(t,n,i){return t.prep(8,16),t.writeInt64(i),t.writeInt64(n),t.offset()}},mo=class D5{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsRecordBatch(t,n){return(n||new D5).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsRecordBatch(t,n){return t.setPosition(t.position()+Qt),(n||new D5).__init(t.readInt32(t.position())+t.position(),t)}length(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}nodes(t,n){const i=this.bb.__offset(this.bb_pos,6);return i?(n||new oR).__init(this.bb.__vector(this.bb_pos+i)+t*16,this.bb):null}nodesLength(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.__vector_len(this.bb_pos+t):0}buffers(t,n){const i=this.bb.__offset(this.bb_pos,8);return i?(n||new aR).__init(this.bb.__vector(this.bb_pos+i)+t*16,this.bb):null}buffersLength(){const t=this.bb.__offset(this.bb_pos,8);return t?this.bb.__vector_len(this.bb_pos+t):0}compression(t){const n=this.bb.__offset(this.bb_pos,10);return n?(t||new Ll).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}static startRecordBatch(t){t.startObject(4)}static addLength(t,n){t.addFieldInt64(0,n,t.createLong(0,0))}static addNodes(t,n){t.addFieldOffset(1,n,0)}static startNodesVector(t,n){t.startVector(16,n,8)}static addBuffers(t,n){t.addFieldOffset(2,n,0)}static startBuffersVector(t,n){t.startVector(16,n,8)}static addCompression(t,n){t.addFieldOffset(3,n,0)}static endRecordBatch(t){return t.endObject()}},Kf=class j5{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsDictionaryBatch(t,n){return(n||new j5).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsDictionaryBatch(t,n){return t.setPosition(t.position()+Qt),(n||new j5).__init(t.readInt32(t.position())+t.position(),t)}id(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}data(t){const n=this.bb.__offset(this.bb_pos,6);return n?(t||new mo).__init(this.bb.__indirect(this.bb_pos+n),this.bb):null}isDelta(){const t=this.bb.__offset(this.bb_pos,8);return t?!!this.bb.readInt8(this.bb_pos+t):!1}static startDictionaryBatch(t){t.startObject(3)}static addId(t,n){t.addFieldInt64(0,n,t.createLong(0,0))}static addData(t,n){t.addFieldOffset(1,n,0)}static addIsDelta(t,n){t.addFieldInt8(2,+n,0)}static endDictionaryBatch(t){return t.endObject()}};var v2;(function(e){e[e.NONE=0]="NONE",e[e.Schema=1]="Schema",e[e.DictionaryBatch=2]="DictionaryBatch",e[e.RecordBatch=3]="RecordBatch",e[e.Tensor=4]="Tensor",e[e.SparseTensor=5]="SparseTensor"})(v2||(v2={}));let hl=class ia{constructor(){this.bb=null,this.bb_pos=0}__init(t,n){return this.bb_pos=t,this.bb=n,this}static getRootAsMessage(t,n){return(n||new ia).__init(t.readInt32(t.position())+t.position(),t)}static getSizePrefixedRootAsMessage(t,n){return t.setPosition(t.position()+Qt),(n||new ia).__init(t.readInt32(t.position())+t.position(),t)}version(){const t=this.bb.__offset(this.bb_pos,4);return t?this.bb.readInt16(this.bb_pos+t):Au.V1}headerType(){const t=this.bb.__offset(this.bb_pos,6);return t?this.bb.readUint8(this.bb_pos+t):v2.NONE}header(t){const n=this.bb.__offset(this.bb_pos,8);return n?this.bb.__union(t,this.bb_pos+n):null}bodyLength(){const t=this.bb.__offset(this.bb_pos,10);return t?this.bb.readInt64(this.bb_pos+t):this.bb.createLong(0,0)}customMetadata(t,n){const i=this.bb.__offset(this.bb_pos,12);return i?(n||new Fn).__init(this.bb.__indirect(this.bb.__vector(this.bb_pos+i)+t*4),this.bb):null}customMetadataLength(){const t=this.bb.__offset(this.bb_pos,12);return t?this.bb.__vector_len(this.bb_pos+t):0}static startMessage(t){t.startObject(5)}static addVersion(t,n){t.addFieldInt16(0,n,Au.V1)}static addHeaderType(t,n){t.addFieldInt8(1,n,v2.NONE)}static addHeader(t,n){t.addFieldOffset(2,n,0)}static addBodyLength(t,n){t.addFieldInt64(3,n,t.createLong(0,0))}static addCustomMetadata(t,n){t.addFieldOffset(4,n,0)}static createCustomMetadataVector(t,n){t.startVector(4,n.length,4);for(let i=n.length-1;i>=0;i--)t.addOffset(n[i]);return t.endVector()}static startCustomMetadataVector(t,n){t.startVector(4,n,4)}static endMessage(t){return t.endObject()}static finishMessageBuffer(t,n){t.finish(n)}static finishSizePrefixedMessageBuffer(t,n){t.finish(n,void 0,!0)}static createMessage(t,n,i,s,o,c){return ia.startMessage(t),ia.addVersion(t,n),ia.addHeaderType(t,i),ia.addHeader(t,s),ia.addBodyLength(t,o),ia.addCustomMetadata(t,c),ia.endMessage(t)}};var TZ=Ao;class vZ extends mt{visit(t,n){return t==null||n==null?void 0:super.visit(t,n)}visitNull(t,n){return ud.startNull(n),ud.endNull(n)}visitInt(t,n){return Bs.startInt(n),Bs.addBitWidth(n,t.bitWidth),Bs.addIsSigned(n,t.isSigned),Bs.endInt(n)}visitFloat(t,n){return ga.startFloatingPoint(n),ga.addPrecision(n,t.precision),ga.endFloatingPoint(n)}visitBinary(t,n){return cd.startBinary(n),cd.endBinary(n)}visitBool(t,n){return dd.startBool(n),dd.endBool(n)}visitUtf8(t,n){return gd.startUtf8(n),gd.endUtf8(n)}visitDecimal(t,n){return Ki.startDecimal(n),Ki.addScale(n,t.scale),Ki.addPrecision(n,t.precision),Ki.addBitWidth(n,t.bitWidth),Ki.endDecimal(n)}visitDate(t,n){return B_.startDate(n),B_.addUnit(n,t.unit),B_.endDate(n)}visitTime(t,n){return b1.startTime(n),b1.addUnit(n,t.unit),b1.addBitWidth(n,t.bitWidth),b1.endTime(n)}visitTimestamp(t,n){const i=t.timezone&&n.createString(t.timezone)||void 0;return Vs.startTimestamp(n),Vs.addUnit(n,t.unit),i!==void 0&&Vs.addTimezone(n,i),Vs.endTimestamp(n)}visitInterval(t,n){return _a.startInterval(n),_a.addUnit(n,t.unit),_a.endInterval(n)}visitList(t,n){return fd.startList(n),fd.endList(n)}visitStruct(t,n){return hd.startStruct_(n),hd.endStruct_(n)}visitUnion(t,n){Xc.startTypeIdsVector(n,t.typeIds.length);const i=Xc.createTypeIdsVector(n,t.typeIds);return Xc.startUnion(n),Xc.addMode(n,t.mode),Xc.addTypeIds(n,i),Xc.endUnion(n)}visitDictionary(t,n){const i=this.visit(t.indices,n);return So.startDictionaryEncoding(n),So.addId(n,new TZ(t.id,0)),So.addIsOrdered(n,t.isOrdered),i!==void 0&&So.addIndexType(n,i),So.endDictionaryEncoding(n)}visitFixedSizeBinary(t,n){return ua.startFixedSizeBinary(n),ua.addByteWidth(n,t.byteWidth),ua.endFixedSizeBinary(n)}visitFixedSizeList(t,n){return ha.startFixedSizeList(n),ha.addListSize(n,t.listSize),ha.endFixedSizeList(n)}visitMap(t,n){return F_.startMap(n),F_.addKeysSorted(n,t.keysSorted),F_.endMap(n)}}const V6=new vZ;function EZ(e,t=new Map){return new Ot(xZ(e,t),M_(e.customMetadata),t)}function lR(e){return new Ns(e.count,cR(e.columns),dR(e.columns))}function SZ(e){return new Ra(lR(e.data),e.id,e.isDelta)}function xZ(e,t){return(e.fields||[]).filter(Boolean).map(n=>Vt.fromJSON(n,t))}function Vk(e,t){return(e.children||[]).filter(Boolean).map(n=>Vt.fromJSON(n,t))}function cR(e){return(e||[]).reduce((t,n)=>[...t,new cf(n.count,kZ(n.VALIDITY)),...cR(n.children)],[])}function dR(e,t=[]){for(let n=-1,i=(e||[]).length;++nt+ +(n===0),0)}function BZ(e,t){let n,i,s,o,c,d;return!t||!(o=e.dictionary)?(c=Wk(e,Vk(e,t)),s=new Vt(e.name,c,e.nullable,M_(e.customMetadata))):t.has(n=o.id)?(i=(i=o.indexType)?Gk(i):new Xl,d=new $o(t.get(n),i,n,o.isOrdered),s=new Vt(e.name,d,e.nullable,M_(e.customMetadata))):(i=(i=o.indexType)?Gk(i):new Xl,t.set(n,c=Wk(e,Vk(e,t))),d=new $o(c,i,n,o.isOrdered),s=new Vt(e.name,d,e.nullable,M_(e.customMetadata))),s||null}function M_(e){return new Map(Object.entries(e||{}))}function Gk(e){return new vi(e.isSigned,e.bitWidth)}function Wk(e,t){const n=e.type.name;switch(n){case"NONE":return new Oa;case"null":return new Oa;case"binary":return new y2;case"utf8":return new ku;case"bool":return new Bu;case"list":return new Md((t||[])[0]);case"struct":return new Hn(t||[]);case"struct_":return new Hn(t||[])}switch(n){case"int":{const i=e.type;return new vi(i.isSigned,i.bitWidth)}case"floatingpoint":{const i=e.type;return new Ho(Cn[i.precision])}case"decimal":{const i=e.type;return new m2(i.scale,i.precision,i.bitWidth)}case"date":{const i=e.type;return new Id(ds[i.unit])}case"time":{const i=e.type;return new Ma(rt[i.unit],i.bitWidth)}case"timestamp":{const i=e.type;return new zo(rt[i.unit],i.timezone)}case"interval":{const i=e.type;return new Od(er[i.unit])}case"union":{const i=e.type;return new Kl(Xn[i.mode],i.typeIds||[],t||[])}case"fixedsizebinary":{const i=e.type;return new w2(i.byteWidth)}case"fixedsizelist":{const i=e.type;return new Fu(i.listSize,(t||[])[0])}case"map":{const i=e.type;return new Iu((t||[])[0],i.keysSorted)}}throw new Error(`Unrecognized type: "${n}"`)}var Nd=Ao,FZ=MC,IZ=Mu;class hi{constructor(t,n,i,s){this._version=n,this._headerType=i,this.body=new Uint8Array(0),s&&(this._createHeader=()=>s),this._bodyLength=typeof t=="number"?t:t.low}static fromJSON(t,n){const i=new hi(0,ts.V4,n);return i._createHeader=OZ(t,n),i}static decode(t){t=new IZ(St(t));const n=hl.getRootAsMessage(t),i=n.bodyLength(),s=n.version(),o=n.headerType(),c=new hi(i,s,o);return c._createHeader=MZ(n,o),c}static encode(t){const n=new FZ;let i=-1;return t.isSchema()?i=Ot.encode(n,t.header()):t.isRecordBatch()?i=Ns.encode(n,t.header()):t.isDictionaryBatch()&&(i=Ra.encode(n,t.header())),hl.startMessage(n),hl.addVersion(n,ts.V4),hl.addHeader(n,i),hl.addHeaderType(n,t.headerType),hl.addBodyLength(n,new Nd(t.bodyLength,0)),hl.finishMessageBuffer(n,hl.endMessage(n)),n.asUint8Array()}static from(t,n=0){if(t instanceof Ot)return new hi(0,ts.V4,zt.Schema,t);if(t instanceof Ns)return new hi(n,ts.V4,zt.RecordBatch,t);if(t instanceof Ra)return new hi(n,ts.V4,zt.DictionaryBatch,t);throw new Error(`Unrecognized Message header: ${t}`)}get type(){return this.headerType}get version(){return this._version}get headerType(){return this._headerType}get bodyLength(){return this._bodyLength}header(){return this._createHeader()}isSchema(){return this.headerType===zt.Schema}isRecordBatch(){return this.headerType===zt.RecordBatch}isDictionaryBatch(){return this.headerType===zt.DictionaryBatch}}class Ns{constructor(t,n,i){this._nodes=n,this._buffers=i,this._length=typeof t=="number"?t:t.low}get nodes(){return this._nodes}get length(){return this._length}get buffers(){return this._buffers}}class Ra{constructor(t,n,i=!1){this._data=t,this._isDelta=i,this._id=typeof n=="number"?n:n.low}get id(){return this._id}get data(){return this._data}get isDelta(){return this._isDelta}get length(){return this.data.length}get nodes(){return this.data.nodes}get buffers(){return this.data.buffers}}class La{constructor(t,n){this.offset=typeof t=="number"?t:t.low,this.length=typeof n=="number"?n:n.low}}class cf{constructor(t,n){this.length=typeof t=="number"?t:t.low,this.nullCount=typeof n=="number"?n:n.low}}function OZ(e,t){return()=>{switch(t){case zt.Schema:return Ot.fromJSON(e);case zt.RecordBatch:return Ns.fromJSON(e);case zt.DictionaryBatch:return Ra.fromJSON(e)}throw new Error(`Unrecognized Message type: { name: ${zt[t]}, type: ${t} }`)}}function MZ(e,t){return()=>{switch(t){case zt.Schema:return Ot.decode(e.header(new ra));case zt.RecordBatch:return Ns.decode(e.header(new mo),e.version());case zt.DictionaryBatch:return Ra.decode(e.header(new Kf),e.version())}throw new Error(`Unrecognized Message type: { name: ${zt[t]}, type: ${t} }`)}}Vt.encode=$Z;Vt.decode=HZ;Vt.fromJSON=BZ;Ot.encode=zZ;Ot.decode=AZ;Ot.fromJSON=EZ;Ns.encode=qZ;Ns.decode=NZ;Ns.fromJSON=lR;Ra.encode=VZ;Ra.decode=CZ;Ra.fromJSON=SZ;cf.encode=GZ;cf.decode=PZ;La.encode=WZ;La.decode=RZ;function AZ(e,t=new Map){const n=UZ(e,t);return new Ot(n,A_(e),t)}function NZ(e,t=ts.V4){if(e.compression()!==null)throw new Error("Record batch compression not implemented");return new Ns(e.length(),DZ(e),jZ(e,t))}function CZ(e,t=ts.V4){return new Ra(Ns.decode(e.data(),t),e.id(),e.isDelta())}function RZ(e){return new La(e.offset(),e.length())}function PZ(e){return new cf(e.length(),e.nullCount())}function DZ(e){const t=[];for(let n,i=-1,s=-1,o=e.nodesLength();++iVt.encode(e,o));ra.startFieldsVector(e,n.length);const i=ra.createFieldsVector(e,n),s=t.metadata&&t.metadata.size>0?ra.createCustomMetadataVector(e,[...t.metadata].map(([o,c])=>{const d=e.createString(`${o}`),f=e.createString(`${c}`);return Fn.startKeyValue(e),Fn.addKey(e,d),Fn.addValue(e,f),Fn.endKeyValue(e)})):-1;return ra.startSchema(e),ra.addFields(e,i),ra.addEndianness(e,YZ?Nu.Little:Nu.Big),s!==-1&&ra.addCustomMetadata(e,s),ra.endSchema(e)}function $Z(e,t){let n=-1,i=-1,s=-1;const o=t.type;let c=t.typeId;We.isDictionary(o)?(c=o.dictionary.typeId,s=V6.visit(o,e),i=V6.visit(o.dictionary,e)):i=V6.visit(o,e);const d=(o.children||[]).map(a=>Vt.encode(e,a)),f=$s.createChildrenVector(e,d),u=t.metadata&&t.metadata.size>0?$s.createCustomMetadataVector(e,[...t.metadata].map(([a,m])=>{const y=e.createString(`${a}`),p=e.createString(`${m}`);return Fn.startKeyValue(e),Fn.addKey(e,y),Fn.addValue(e,p),Fn.endKeyValue(e)})):-1;return t.name&&(n=e.createString(t.name)),$s.startField(e),$s.addType(e,i),$s.addTypeType(e,c),$s.addChildren(e,f),$s.addNullable(e,!!t.nullable),n!==-1&&$s.addName(e,n),s!==-1&&$s.addDictionary(e,s),u!==-1&&$s.addCustomMetadata(e,u),$s.endField(e)}function qZ(e,t){const n=t.nodes||[],i=t.buffers||[];mo.startNodesVector(e,n.length);for(const c of n.slice().reverse())cf.encode(e,c);const s=e.endVector();mo.startBuffersVector(e,i.length);for(const c of i.slice().reverse())La.encode(e,c);const o=e.endVector();return mo.startRecordBatch(e),mo.addLength(e,new Nd(t.length,0)),mo.addNodes(e,s),mo.addBuffers(e,o),mo.endRecordBatch(e)}function VZ(e,t){const n=Ns.encode(e,t.data);return Kf.startDictionaryBatch(e),Kf.addId(e,new Nd(t.id,0)),Kf.addIsDelta(e,t.isDelta),Kf.addData(e,n),Kf.endDictionaryBatch(e)}function GZ(e,t){return oR.createFieldNode(e,new Nd(t.length,0),new Nd(t.nullCount,0))}function WZ(e,t){return aR.createBuffer(e,new Nd(t.offset,0),new Nd(t.length,0))}const YZ=(()=>{const e=new ArrayBuffer(2);return new DataView(e).setInt16(0,256,!0),new Int16Array(e)[0]===256})(),y7=e=>`Expected ${zt[e]} Message in stream, but was null or length 0.`,m7=e=>`Header pointer of flatbuffer-encoded ${zt[e]} Message is null or length 0.`,fR=(e,t)=>`Expected to read ${e} metadata bytes, but only read ${t}.`,uR=(e,t)=>`Expected to read ${e} bytes for message body, but only read ${t}.`;class w7{constructor(t){this.source=t instanceof T2?t:new T2(t)}[Symbol.iterator](){return this}next(){let t;return(t=this.readMetadataLength()).done||t.value===-1&&(t=this.readMetadataLength()).done||(t=this.readMetadata(t.value)).done?un:t}throw(t){return this.source.throw(t)}return(t){return this.source.return(t)}readMessage(t){let n;if((n=this.next()).done)return null;if(t!=null&&n.value.headerType!==t)throw new Error(y7(t));return n.value}readMessageBody(t){if(t<=0)return new Uint8Array(0);const n=St(this.source.read(t));if(n.byteLength[...s,...o.VALIDITY&&[o.VALIDITY]||[],...o.TYPE&&[o.TYPE]||[],...o.OFFSET&&[o.OFFSET]||[],...o.DATA&&[o.DATA]||[],...n(o.children)],[])}}readMessage(t){let n;if((n=this.next()).done)return null;if(t!=null&&n.value.headerType!==t)throw new Error(y7(t));return n.value}readSchema(){const t=zt.Schema,n=this.readMessage(t),i=n==null?void 0:n.header();if(!n||!i)throw new Error(m7(t));return i}}const v4=4,U5="ARROW1",E2=new Uint8Array(U5.length);for(let e=0;ethis):this}readRecordBatch(t){return this._impl.isFile()?this._impl.readRecordBatch(t):null}[Symbol.iterator](){return this._impl[Symbol.iterator]()}[Symbol.asyncIterator](){return this._impl[Symbol.asyncIterator]()}toDOMStream(){return ks.toDOMStream(this.isSync()?{[Symbol.iterator]:()=>this}:{[Symbol.asyncIterator]:()=>this})}toNodeStream(){return ks.toNodeStream(this.isSync()?{[Symbol.iterator]:()=>this}:{[Symbol.asyncIterator]:()=>this},{objectMode:!0})}static throughNode(t){throw new Error('"throughNode" not available in this environment')}static throughDOM(t,n){throw new Error('"throughDOM" not available in this environment')}static from(t){return t instanceof Zs?t:O5(t)?JZ(t):gN(t)?tJ(t):Yl(t)?(()=>Ae(this,void 0,void 0,function*(){return yield Zs.from(yield t)}))():_N(t)||p9(t)||pN(t)||rf(t)?eJ(new Zl(t)):QZ(new T2(t))}static readAll(t){return t instanceof Zs?t.isSync()?Zk(t):Jk(t):O5(t)||ArrayBuffer.isView(t)||bh(t)||hN(t)?Zk(t):Jk(t)}}class Pu extends Zs{constructor(t){super(t),this._impl=t}readAll(){return[...this]}[Symbol.iterator](){return this._impl[Symbol.iterator]()}[Symbol.asyncIterator](){return Ir(this,arguments,function*(){yield Qe(yield*x_(Pl(this[Symbol.iterator]())))})}}class S2 extends Zs{constructor(t){super(t),this._impl=t}readAll(){var t,n;return Ae(this,void 0,void 0,function*(){const i=new Array;try{for(var s=Pl(this),o;o=yield s.next(),!o.done;){const c=o.value;i.push(c)}}catch(c){t={error:c}}finally{try{o&&!o.done&&(n=s.return)&&(yield n.call(s))}finally{if(t)throw t.error}}return i})}[Symbol.iterator](){throw new Error("AsyncRecordBatchStreamReader is not Iterable")}[Symbol.asyncIterator](){return this._impl[Symbol.asyncIterator]()}}class E4 extends Pu{constructor(t){super(t),this._impl=t}}class pR extends S2{constructor(t){super(t),this._impl=t}}class yR{constructor(t=new Map){this.closed=!1,this.autoDestroy=!0,this._dictionaryIndex=0,this._recordBatchIndex=0,this.dictionaries=t}get numDictionaries(){return this._dictionaryIndex}get numRecordBatches(){return this._recordBatchIndex}isSync(){return!1}isAsync(){return!1}isFile(){return!1}isStream(){return!1}reset(t){return this._dictionaryIndex=0,this._recordBatchIndex=0,this.schema=t,this.dictionaries=new Map,this}_loadRecordBatch(t,n){const i=this._loadVectors(t,n,this.schema.fields),s=Ze({type:new Hn(this.schema.fields),length:t.length,children:i});return new ti(this.schema,s)}_loadDictionaryBatch(t,n){const{id:i,isDelta:s}=t,{dictionaries:o,schema:c}=this,d=o.get(i);if(s||!d){const f=c.dictionaries.get(i),u=this._loadVectors(t.data,n,[f]);return(d&&s?d.concat(new qe(u)):new qe(u)).memoize()}return d.memoize()}_loadVectors(t,n,i){return new NC(n,t.nodes,t.buffers,this.dictionaries).visitMany(i)}}class bp extends yR{constructor(t,n){super(n),this._reader=O5(t)?new gR(this._handle=t):new w7(this._handle=t)}isSync(){return!0}isStream(){return!0}[Symbol.iterator](){return this}cancel(){!this.closed&&(this.closed=!0)&&(this.reset()._reader.return(),this._reader=null,this.dictionaries=null)}open(t){return this.closed||(this.autoDestroy=wR(this,t),this.schema||(this.schema=this._reader.readSchema())||this.cancel()),this}throw(t){return!this.closed&&this.autoDestroy&&(this.closed=!0)?this.reset()._reader.throw(t):un}return(t){return!this.closed&&this.autoDestroy&&(this.closed=!0)?this.reset()._reader.return(t):un}next(){if(this.closed)return un;let t;const{_reader:n}=this;for(;t=this._readNextMessageAndValidate();)if(t.isSchema())this.reset(t.header());else if(t.isRecordBatch()){this._recordBatchIndex++;const i=t.header(),s=n.readMessageBody(t.bodyLength);return{done:!1,value:this._loadRecordBatch(i,s)}}else if(t.isDictionaryBatch()){this._dictionaryIndex++;const i=t.header(),s=n.readMessageBody(t.bodyLength),o=this._loadDictionaryBatch(i,s);this.dictionaries.set(i.id,o)}return this.schema&&this._recordBatchIndex===0?(this._recordBatchIndex++,{done:!1,value:new p7(this.schema)}):this.return()}_readNextMessageAndValidate(t){return this._reader.readMessage(t)}}class Tp extends yR{constructor(t,n){super(n),this._reader=new hR(this._handle=t)}isAsync(){return!0}isStream(){return!0}[Symbol.asyncIterator](){return this}cancel(){return Ae(this,void 0,void 0,function*(){!this.closed&&(this.closed=!0)&&(yield this.reset()._reader.return(),this._reader=null,this.dictionaries=null)})}open(t){return Ae(this,void 0,void 0,function*(){return this.closed||(this.autoDestroy=wR(this,t),this.schema||(this.schema=yield this._reader.readSchema())||(yield this.cancel())),this})}throw(t){return Ae(this,void 0,void 0,function*(){return!this.closed&&this.autoDestroy&&(this.closed=!0)?yield this.reset()._reader.throw(t):un})}return(t){return Ae(this,void 0,void 0,function*(){return!this.closed&&this.autoDestroy&&(this.closed=!0)?yield this.reset()._reader.return(t):un})}next(){return Ae(this,void 0,void 0,function*(){if(this.closed)return un;let t;const{_reader:n}=this;for(;t=yield this._readNextMessageAndValidate();)if(t.isSchema())yield this.reset(t.header());else if(t.isRecordBatch()){this._recordBatchIndex++;const i=t.header(),s=yield n.readMessageBody(t.bodyLength);return{done:!1,value:this._loadRecordBatch(i,s)}}else if(t.isDictionaryBatch()){this._dictionaryIndex++;const i=t.header(),s=yield n.readMessageBody(t.bodyLength),o=this._loadDictionaryBatch(i,s);this.dictionaries.set(i.id,o)}return this.schema&&this._recordBatchIndex===0?(this._recordBatchIndex++,{done:!1,value:new p7(this.schema)}):yield this.return()})}_readNextMessageAndValidate(t){return Ae(this,void 0,void 0,function*(){return yield this._reader.readMessage(t)})}}class mR extends bp{constructor(t,n){super(t instanceof $k?t:new $k(t),n)}get footer(){return this._footer}get numDictionaries(){return this._footer?this._footer.numDictionaries:0}get numRecordBatches(){return this._footer?this._footer.numRecordBatches:0}isSync(){return!0}isFile(){return!0}open(t){if(!this.closed&&!this._footer){this.schema=(this._footer=this._readFooter()).schema;for(const n of this._footer.dictionaryBatches())n&&this._readDictionaryBatch(this._dictionaryIndex++)}return super.open(t)}readRecordBatch(t){var n;if(this.closed)return null;this._footer||this.open();const i=(n=this._footer)===null||n===void 0?void 0:n.getRecordBatch(t);if(i&&this._handle.seek(i.offset)){const s=this._reader.readMessage(zt.RecordBatch);if(s!=null&&s.isRecordBatch()){const o=s.header(),c=this._reader.readMessageBody(s.bodyLength);return this._loadRecordBatch(o,c)}}return null}_readDictionaryBatch(t){var n;const i=(n=this._footer)===null||n===void 0?void 0:n.getDictionaryBatch(t);if(i&&this._handle.seek(i.offset)){const s=this._reader.readMessage(zt.DictionaryBatch);if(s!=null&&s.isDictionaryBatch()){const o=s.header(),c=this._reader.readMessageBody(s.bodyLength),d=this._loadDictionaryBatch(o,c);this.dictionaries.set(o.id,d)}}}_readFooter(){const{_handle:t}=this,n=t.size-_R,i=t.readInt32(n),s=t.readAt(n-i,i);return b2.decode(s)}_readNextMessageAndValidate(t){var n;if(this._footer||this.open(),this._footer&&this._recordBatchIndexsuper.open}});return Ae(this,void 0,void 0,function*(){if(!this.closed&&!this._footer){this.schema=(this._footer=yield this._readFooter()).schema;for(const i of this._footer.dictionaryBatches())i&&(yield this._readDictionaryBatch(this._dictionaryIndex++))}return yield n.open.call(this,t)})}readRecordBatch(t){var n;return Ae(this,void 0,void 0,function*(){if(this.closed)return null;this._footer||(yield this.open());const i=(n=this._footer)===null||n===void 0?void 0:n.getRecordBatch(t);if(i&&(yield this._handle.seek(i.offset))){const s=yield this._reader.readMessage(zt.RecordBatch);if(s!=null&&s.isRecordBatch()){const o=s.header(),c=yield this._reader.readMessageBody(s.bodyLength);return this._loadRecordBatch(o,c)}}return null})}_readDictionaryBatch(t){var n;return Ae(this,void 0,void 0,function*(){const i=(n=this._footer)===null||n===void 0?void 0:n.getDictionaryBatch(t);if(i&&(yield this._handle.seek(i.offset))){const s=yield this._reader.readMessage(zt.DictionaryBatch);if(s!=null&&s.isDictionaryBatch()){const o=s.header(),c=yield this._reader.readMessageBody(s.bodyLength),d=this._loadDictionaryBatch(o,c);this.dictionaries.set(o.id,d)}}})}_readFooter(){return Ae(this,void 0,void 0,function*(){const{_handle:t}=this;t._pending&&(yield t._pending);const n=t.size-_R,i=yield t.readInt32(n),s=yield t.readAt(n-i,i);return b2.decode(s)})}_readNextMessageAndValidate(t){return Ae(this,void 0,void 0,function*(){if(this._footer||(yield this.open()),this._footer&&this._recordBatchIndex=4?L7(t)?new E4(new mR(e.read())):new Pu(new bp(e)):new Pu(new bp(function*(){}()))}function eJ(e){return Ae(this,void 0,void 0,function*(){const t=yield e.peek(_0+7&-8);return t&&t.byteLength>=4?L7(t)?new E4(new mR(yield e.read())):new S2(new Tp(e)):new S2(new Tp(function(){return Ir(this,arguments,function*(){})}()))})}function tJ(e){return Ae(this,void 0,void 0,function*(){const{size:t}=yield e.stat(),n=new yp(e,t);return t>=XZ&&L7(yield n.readAt(0,_0+7&-8))?new pR(new KZ(n)):new S2(new Tp(n))})}class vn extends mt{constructor(){super(),this._byteLength=0,this._nodes=[],this._buffers=[],this._bufferRegions=[]}static assemble(...t){const n=s=>s.flatMap(o=>Array.isArray(o)?n(o):o instanceof ti?o.data.children:o.data),i=new vn;return i.visitMany(n(t)),i}visit(t){if(t instanceof qe)return this.visitMany(t.data),this;const{type:n}=t;if(!We.isDictionary(n)){const{length:i,nullCount:s}=t;if(i>2147483647)throw new RangeError("Cannot write arrays larger than 2^31 - 1 in length");We.isNull(n)||Rr.call(this,s<=0?new Uint8Array(0):y4(t.offset,i,t.nullBitmap)),this.nodes.push(new cf(i,s))}return super.visit(t)}visitNull(t){return this}visitDictionary(t){return this.visit(t.clone(t.type.indices))}get nodes(){return this._nodes}get buffers(){return this._buffers}get byteLength(){return this._byteLength}get bufferRegions(){return this._bufferRegions}}function Rr(e){const t=e.byteLength+7&-8;return this.buffers.push(e),this.bufferRegions.push(new La(this._byteLength,t)),this._byteLength+=t,this}function nJ(e){const{type:t,length:n,typeIds:i,valueOffsets:s}=e;if(Rr.call(this,i),t.mode===Xn.Sparse)return H5.call(this,e);if(t.mode===Xn.Dense){if(e.offset<=0)return Rr.call(this,s),H5.call(this,e);{const o=i.reduce((a,m)=>Math.max(a,m),i[0]),c=new Int32Array(o+1),d=new Int32Array(o+1).fill(-1),f=new Int32Array(n),u=f4(-s[0],n,s);for(let a,m,y=-1;++y=e.length?Rr.call(this,new Uint8Array(0)):(t=e.values)instanceof Uint8Array?Rr.call(this,y4(e.offset,e.length,t)):Rr.call(this,L2(e.values))}function wc(e){return Rr.call(this,e.values.subarray(0,e.length*e.stride))}function LR(e){const{length:t,values:n,valueOffsets:i}=e,s=i[0],o=i[t],c=Math.min(o-s,n.byteLength-s);return Rr.call(this,f4(-i[0],t,i)),Rr.call(this,n.subarray(s,s+c)),this}function b7(e){const{length:t,valueOffsets:n}=e;return n&&Rr.call(this,f4(n[0],t,n)),this.visit(e.children[0])}function H5(e){return this.visitMany(e.type.children.map((t,n)=>e.children[n]).filter(Boolean))[0]}vn.prototype.visitBool=iJ;vn.prototype.visitInt=wc;vn.prototype.visitFloat=wc;vn.prototype.visitUtf8=LR;vn.prototype.visitBinary=LR;vn.prototype.visitFixedSizeBinary=wc;vn.prototype.visitDate=wc;vn.prototype.visitTimestamp=wc;vn.prototype.visitTime=wc;vn.prototype.visitDecimal=wc;vn.prototype.visitList=b7;vn.prototype.visitStruct=H5;vn.prototype.visitUnion=nJ;vn.prototype.visitInterval=wc;vn.prototype.visitFixedSizeList=b7;vn.prototype.visitMap=b7;class sJ extends mt{visit(t){return t==null?void 0:super.visit(t)}visitNull({typeId:t}){return{name:gt[t].toLowerCase()}}visitInt({typeId:t,bitWidth:n,isSigned:i}){return{name:gt[t].toLowerCase(),bitWidth:n,isSigned:i}}visitFloat({typeId:t,precision:n}){return{name:gt[t].toLowerCase(),precision:Cn[n]}}visitBinary({typeId:t}){return{name:gt[t].toLowerCase()}}visitBool({typeId:t}){return{name:gt[t].toLowerCase()}}visitUtf8({typeId:t}){return{name:gt[t].toLowerCase()}}visitDecimal({typeId:t,scale:n,precision:i,bitWidth:s}){return{name:gt[t].toLowerCase(),scale:n,precision:i,bitWidth:s}}visitDate({typeId:t,unit:n}){return{name:gt[t].toLowerCase(),unit:ds[n]}}visitTime({typeId:t,unit:n,bitWidth:i}){return{name:gt[t].toLowerCase(),unit:rt[n],bitWidth:i}}visitTimestamp({typeId:t,timezone:n,unit:i}){return{name:gt[t].toLowerCase(),unit:rt[i],timezone:n}}visitInterval({typeId:t,unit:n}){return{name:gt[t].toLowerCase(),unit:er[n]}}visitList({typeId:t}){return{name:gt[t].toLowerCase()}}visitStruct({typeId:t}){return{name:gt[t].toLowerCase()}}visitUnion({typeId:t,mode:n,typeIds:i}){return{name:gt[t].toLowerCase(),mode:Xn[n],typeIds:[...i]}}visitDictionary(t){return this.visit(t.dictionary)}visitFixedSizeBinary({typeId:t,byteWidth:n}){return{name:gt[t].toLowerCase(),byteWidth:n}}visitFixedSizeList({typeId:t,listSize:n}){return{name:gt[t].toLowerCase(),listSize:n}}visitMap({typeId:t,keysSorted:n}){return{name:gt[t].toLowerCase(),keysSorted:n}}}class S4 extends mt{static assemble(...t){const n=new S4;return t.map(({schema:i,data:s})=>n.visitMany(i.fields,s.children))}visit({name:t},n){const{length:i}=n,{offset:s,nullCount:o,nullBitmap:c}=n,d=We.isDictionary(n.type)?n.type.indices:n.type,f=Object.assign([],n.buffers,{[wr.VALIDITY]:void 0});return Object.assign({name:t,count:i,VALIDITY:We.isNull(d)?void 0:o<=0?Array.from({length:i},()=>1):[...new Ou(c,s,i,null,$9)]},super.visit(n.clone(d,s,i,0,f)))}visitNull(){return{}}visitBool({values:t,offset:n,length:i}){return{DATA:[...new Ou(t,n,i,null,p4)]}}visitInt(t){return{DATA:t.type.bitWidth<64?[...t.values]:[...Yh(t.values,2)]}}visitFloat(t){return{DATA:[...t.values]}}visitUtf8(t){return{DATA:[...new qe([t])],OFFSET:[...t.valueOffsets]}}visitBinary(t){return{DATA:[...Qk(new qe([t]))],OFFSET:[...t.valueOffsets]}}visitFixedSizeBinary(t){return{DATA:[...Qk(new qe([t]))]}}visitDate(t){return{DATA:t.type.unit===ds.DAY?[...t.values]:[...Yh(t.values,2)]}}visitTimestamp(t){return{DATA:[...Yh(t.values,2)]}}visitTime(t){return{DATA:t.type.unit`${n}${("0"+(i&255).toString(16)).slice(-2)}`,"").toUpperCase()}function*Yh(e,t){const n=new Uint32Array(e.buffer);for(let i=-1,s=n.length/t;++ithis.writeAll(n)):rf(t)?E7(this,t):v7(this,t)}get closed(){return this._sink.closed}[Symbol.asyncIterator](){return this._sink[Symbol.asyncIterator]()}toDOMStream(t){return this._sink.toDOMStream(t)}toNodeStream(t){return this._sink.toNodeStream(t)}close(){return this.reset()._sink.close()}abort(t){return this.reset()._sink.abort(t)}finish(){return this._autoDestroy?this.close():this.reset(this._sink,this._schema),this}reset(t=this._sink,n=null){return t===this._sink||t instanceof _u?this._sink=t:(this._sink=new _u,t&&DY(t)?this.toDOMStream({type:"bytes"}).pipeTo(t):t&&jY(t)&&this.toNodeStream({objectMode:!1}).pipe(t)),this._started&&this._schema&&this._writeFooter(this._schema),this._started=!1,this._dictionaryBlocks=[],this._recordBatchBlocks=[],this._dictionaryDeltaOffsets=new Map,(!n||!mp(n,this._schema))&&(n==null?(this._position=0,this._schema=null):(this._started=!0,this._schema=n,this._writeSchema(n))),this}write(t){let n=null;if(this._sink){if(t==null)return this.finish()&&void 0;if(t instanceof In&&!(n=t.schema))return this.finish()&&void 0;if(t instanceof ti&&!(n=t.schema))return this.finish()&&void 0}else throw new Error("RecordBatchWriter is closed");if(n&&!mp(n,this._schema)){if(this._started&&this._autoDestroy)return this.close();this.reset(this._sink,n)}t instanceof ti?t instanceof p7||this._writeRecordBatch(t):t instanceof In?this.writeAll(t.batches):bh(t)&&this.writeAll(t)}_writeMessage(t,n=8){const i=n-1,s=hi.encode(t),o=s.byteLength,c=this._writeLegacyIpcFormat?4:8,d=o+c+i&~i,f=d-o-c;return t.headerType===zt.RecordBatch?this._recordBatchBlocks.push(new Na(d,t.bodyLength,this._position)):t.headerType===zt.DictionaryBatch&&this._dictionaryBlocks.push(new Na(d,t.bodyLength,this._position)),this._writeLegacyIpcFormat||this._write(Int32Array.of(-1)),this._write(Int32Array.of(d-c)),o>0&&this._write(s),this._writePadding(f)}_write(t){if(this._started){const n=St(t);n&&n.byteLength>0&&(this._sink.write(n),this._position+=n.byteLength)}return this}_writeSchema(t){return this._writeMessage(hi.from(t))}_writeFooter(t){return this._writeLegacyIpcFormat?this._write(Int32Array.of(0)):this._write(Int32Array.of(-1,0))}_writeMagic(){return this._write(E2)}_writePadding(t){return t>0?this._write(new Uint8Array(t)):this}_writeRecordBatch(t){const{byteLength:n,nodes:i,bufferRegions:s,buffers:o}=vn.assemble(t),c=new Ns(t.numRows,i,s),d=hi.from(c,n);return this._writeDictionaries(t)._writeMessage(d)._writeBodyBuffers(o)}_writeDictionaryBatch(t,n,i=!1){this._dictionaryDeltaOffsets.set(n,t.length+(this._dictionaryDeltaOffsets.get(n)||0));const{byteLength:s,nodes:o,bufferRegions:c,buffers:d}=vn.assemble(new qe([t])),f=new Ns(t.length,o,c),u=new Ra(f,n,i),a=hi.from(u,s);return this._writeMessage(a)._writeBodyBuffers(d)}_writeBodyBuffers(t){let n,i,s;for(let o=-1,c=t.length;++o0&&(this._write(n),(s=(i+7&-8)-i)>0&&this._writePadding(s));return this}_writeDictionaries(t){for(let[n,i]of t.dictionaries){let s=this._dictionaryDeltaOffsets.get(n)||0;if(s===0||(i=i==null?void 0:i.slice(s)).length>0)for(const o of i.data)this._writeDictionaryBatch(o,n,s>0),s+=o.length}return this}}class y0 extends p0{static writeAll(t,n){const i=new y0(n);return Yl(t)?t.then(s=>i.writeAll(s)):rf(t)?E7(i,t):v7(i,t)}}class m0 extends p0{static writeAll(t){const n=new m0;return Yl(t)?t.then(i=>n.writeAll(i)):rf(t)?E7(n,t):v7(n,t)}constructor(){super(),this._autoDestroy=!0}_writeSchema(t){return this._writeMagic()._writePadding(2)}_writeFooter(t){const n=b2.encode(new b2(t,ts.V4,this._recordBatchBlocks,this._dictionaryBlocks));return super._writeFooter(t)._write(n)._write(Int32Array.of(n.byteLength))._writeMagic()}}class T7 extends p0{constructor(){super(),this._autoDestroy=!0,this._recordBatches=[],this._dictionaries=[]}static writeAll(t){return new T7().writeAll(t)}_writeMessage(){return this}_writeFooter(t){return this}_writeSchema(t){return this._write(`{ "schema": ${JSON.stringify({fields:t.fields.map(n=>bR(n))},null,2)}`)}_writeDictionaries(t){return t.dictionaries.size>0&&this._dictionaries.push(t),this}_writeDictionaryBatch(t,n,i=!1){return this._dictionaryDeltaOffsets.set(n,t.length+(this._dictionaryDeltaOffsets.get(n)||0)),this._write(this._dictionaryBlocks.length===0?" ":`, `),this._write(`${rJ(t,n,i)}`),this._dictionaryBlocks.push(new Na(0,0,0)),this}_writeRecordBatch(t){return this._writeDictionaries(t),this._recordBatches.push(t),this}close(){if(this._dictionaries.length>0){this._write(`, "dictionaries": [ `);for(const t of this._dictionaries)super._writeDictionaries(t);this._write(` ]`)}if(this._recordBatches.length>0){for(let t=-1,n=this._recordBatches.length;++tbR(s)),dictionary:We.isDictionary(t)?{id:t.id,isOrdered:t.isOrdered,indexType:i.visit(t.indices)}:void 0}}function rJ(e,t,n=!1){const[i]=S4.assemble(new ti({[t]:e}));return JSON.stringify({id:t,isDelta:n,data:{count:e.length,columns:i}},null,2)}function aJ(e){const[t]=S4.assemble(e);return JSON.stringify({count:e.numRows,columns:t},null,2)}function oJ(e,t){if(rf(e))return cJ(e,t);if(bh(e))return lJ(e,t);throw new Error("toDOMStream() must be called with an Iterable or AsyncIterable")}function lJ(e,t){let n=null;const i=(t==null?void 0:t.type)==="bytes"||!1,s=(t==null?void 0:t.highWaterMark)||Math.pow(2,24);return new ReadableStream(Object.assign(Object.assign({},t),{start(c){o(c,n||(n=e[Symbol.iterator]()))},pull(c){n?o(c,n):c.close()},cancel(){(n!=null&&n.return&&n.return()||!0)&&(n=null)}}),Object.assign({highWaterMark:i?s:void 0},t));function o(c,d){let f,u=null,a=c.desiredSize||null;for(;!(u=d.next(i?a:null)).done;)if(ArrayBuffer.isView(u.value)&&(f=St(u.value))&&(a!=null&&i&&(a=a-f.byteLength+1),u.value=f),c.enqueue(u.value),a!=null&&--a<=0)return;c.close()}}function cJ(e,t){let n=null;const i=(t==null?void 0:t.type)==="bytes"||!1,s=(t==null?void 0:t.highWaterMark)||Math.pow(2,24);return new ReadableStream(Object.assign(Object.assign({},t),{start(c){return Ae(this,void 0,void 0,function*(){yield o(c,n||(n=e[Symbol.asyncIterator]()))})},pull(c){return Ae(this,void 0,void 0,function*(){n?yield o(c,n):c.close()})},cancel(){return Ae(this,void 0,void 0,function*(){(n!=null&&n.return&&(yield n.return())||!0)&&(n=null)})}}),Object.assign({highWaterMark:i?s:void 0},t));function o(c,d){return Ae(this,void 0,void 0,function*(){let f,u=null,a=c.desiredSize||null;for(;!(u=yield d.next(i?a:null)).done;)if(ArrayBuffer.isView(u.value)&&(f=St(u.value))&&(a!=null&&i&&(a=a-f.byteLength+1),u.value=f),c.enqueue(u.value),a!=null&&--a<=0)return;c.close()})}}function dJ(e){return new fJ(e)}class fJ{constructor(t){this._numChunks=0,this._finished=!1,this._bufferedSize=0;const{["readableStrategy"]:n,["writableStrategy"]:i,["queueingStrategy"]:s="count"}=t,o=NY(t,["readableStrategy","writableStrategy","queueingStrategy"]);this._controller=null,this._builder=Ad(o),this._getSize=s!=="bytes"?eB:tB;const{["highWaterMark"]:c=s==="bytes"?Math.pow(2,14):1e3}=Object.assign({},n),{["highWaterMark"]:d=s==="bytes"?Math.pow(2,14):1e3}=Object.assign({},i);this.readable=new ReadableStream({cancel:()=>{this._builder.clear()},pull:f=>{this._maybeFlush(this._builder,this._controller=f)},start:f=>{this._maybeFlush(this._builder,this._controller=f)}},{highWaterMark:c,size:s!=="bytes"?eB:tB}),this.writable=new WritableStream({abort:()=>{this._builder.clear()},write:()=>{this._maybeFlush(this._builder,this._controller)},close:()=>{this._maybeFlush(this._builder.finish(),this._controller)}},{highWaterMark:d,size:f=>this._writeValueAndReturnChunkSize(f)})}_writeValueAndReturnChunkSize(t){const n=this._bufferedSize;return this._bufferedSize=this._getSize(this._builder.append(t)),this._bufferedSize-n}_maybeFlush(t,n){n!=null&&(this._bufferedSize>=n.desiredSize&&++this._numChunks&&this._enqueue(n,t.toVector()),t.finished&&((t.length>0||this._numChunks===0)&&++this._numChunks&&this._enqueue(n,t.toVector()),!this._finished&&(this._finished=!0)&&this._enqueue(n,null)))}_enqueue(t,n){this._bufferedSize=0,this._controller=null,n==null?t.close():t.enqueue(n)}}const eB=e=>{var t;return(t=e==null?void 0:e.length)!==null&&t!==void 0?t:0},tB=e=>{var t;return(t=e==null?void 0:e.byteLength)!==null&&t!==void 0?t:0};function S7(e,t){const n=new _u;let i=null;const s=new ReadableStream({cancel(){return Ae(this,void 0,void 0,function*(){yield n.close()})},start(d){return Ae(this,void 0,void 0,function*(){yield c(d,i||(i=yield o()))})},pull(d){return Ae(this,void 0,void 0,function*(){i?yield c(d,i):d.close()})}});return{writable:new WritableStream(n,Object.assign({highWaterMark:Math.pow(2,14)},e)),readable:s};function o(){return Ae(this,void 0,void 0,function*(){return yield(yield Zs.from(n)).open(t)})}function c(d,f){return Ae(this,void 0,void 0,function*(){let u=d.desiredSize,a=null;for(;!(a=yield f.next()).done;)if(d.enqueue(a.value),u!=null&&--u<=0)return;d.close()})}}function x7(e,t){const n=new this(e),i=new Zl(n),s=new ReadableStream({cancel(){return Ae(this,void 0,void 0,function*(){yield i.cancel()})},pull(c){return Ae(this,void 0,void 0,function*(){yield o(c)})},start(c){return Ae(this,void 0,void 0,function*(){yield o(c)})}},Object.assign({highWaterMark:Math.pow(2,14)},t));return{writable:new WritableStream(n,e),readable:s};function o(c){return Ae(this,void 0,void 0,function*(){let d=null,f=c.desiredSize;for(;d=yield i.read(f||null);)if(c.enqueue(d),f!=null&&(f-=d.byteLength)<=0)return;c.close()})}}function k7(e){const t=Zs.from(e);return Yl(t)?t.then(n=>k7(n)):t.isAsync()?t.readAll().then(n=>new In(n)):new In(t.readAll())}function uJ(e,t="stream"){return(t==="stream"?y0:m0).writeAll(e).toUint8Array(!0)}const hJ=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},LX),sZ),PK),RX),hX),CK),{compareSchemas:mp,compareFields:_Z,compareTypes:tR});ks.toDOMStream=oJ;ki.throughDOM=dJ;Zs.throughDOM=S7;E4.throughDOM=S7;Pu.throughDOM=S7;p0.throughDOM=x7;m0.throughDOM=x7;y0.throughDOM=x7;const gJ=Object.freeze(Object.defineProperty({__proto__:null,AsyncByteQueue:_u,AsyncByteStream:Zl,AsyncMessageReader:hR,AsyncRecordBatchFileReader:pR,AsyncRecordBatchStreamReader:S2,Binary:y2,BinaryBuilder:K9,Bool:Bu,BoolBuilder:CC,get BufferType(){return wr},Builder:ki,ByteStream:T2,Data:Ut,DataType:We,DateBuilder:c0,DateDay:bX,DateDayBuilder:Z9,DateMillisecond:zN,DateMillisecondBuilder:J9,get DateUnit(){return ds},Date_:Id,Decimal:m2,DecimalBuilder:Q9,DenseUnion:MX,DenseUnionBuilder:eR,Dictionary:$o,DictionaryBuilder:RC,Field:Vt,FixedSizeBinary:w2,FixedSizeBinaryBuilder:e7,FixedSizeList:Fu,FixedSizeListBuilder:PC,Float:Ho,Float16:HN,Float16Builder:DC,Float32:E9,Float32Builder:jC,Float64:h4,Float64Builder:UC,FloatBuilder:d0,Int:vi,Int16:w9,Int16Builder:zC,Int32:Xl,Int32Builder:$C,Int64:u4,Int64Builder:qC,Int8:m9,Int8Builder:HC,IntBuilder:Ya,Interval:Od,IntervalBuilder:f0,IntervalDayTime:IX,IntervalDayTimeBuilder:t7,get IntervalUnit(){return er},IntervalYearMonth:OX,IntervalYearMonthBuilder:n7,JSONMessageReader:gR,List:Md,ListBuilder:XC,MapBuilder:KC,MapRow:o0,Map_:Iu,Message:hi,get MessageHeader(){return v2},MessageReader:w7,get MetadataVersion(){return ts},Null:Oa,NullBuilder:ZC,get Precision(){return Cn},RecordBatch:ti,RecordBatchFileReader:E4,RecordBatchFileWriter:m0,RecordBatchJSONWriter:T7,RecordBatchReader:Zs,RecordBatchStreamReader:Pu,RecordBatchStreamWriter:y0,RecordBatchWriter:p0,Schema:Ot,SparseUnion:AX,SparseUnionBuilder:QC,Struct:Hn,StructBuilder:JC,StructRow:g4,Table:In,Time:Ma,TimeBuilder:lf,TimeMicrosecond:EX,TimeMicrosecondBuilder:c7,TimeMillisecond:vX,TimeMillisecondBuilder:l7,TimeNanosecond:SX,TimeNanosecondBuilder:d7,TimeSecond:TX,TimeSecondBuilder:o7,get TimeUnit(){return rt},Timestamp:zo,TimestampBuilder:of,TimestampMicrosecond:BX,TimestampMicrosecondBuilder:r7,TimestampMillisecond:kX,TimestampMillisecondBuilder:s7,TimestampNanosecond:FX,TimestampNanosecondBuilder:a7,TimestampSecond:xX,TimestampSecondBuilder:i7,get Type(){return te},Uint16:b9,Uint16Builder:GC,Uint32:T9,Uint32Builder:WC,Uint64:v9,Uint64Builder:YC,Uint8:L9,Uint8Builder:VC,Union:Kl,UnionBuilder:b4,get UnionMode(){return Xn},Utf8:ku,Utf8Builder:f7,Vector:qe,Visitor:mt,builderThroughAsyncIterable:yZ,builderThroughIterable:nR,makeBuilder:Ad,makeData:Ze,makeTable:LZ,makeVector:m4,tableFromArrays:bZ,tableFromIPC:k7,tableFromJSON:pZ,tableToIPC:uJ,util:hJ,vectorFromArray:_7},Symbol.toStringTag,{value:"Module"}));function _J(e,t,n){return Math.ceil((t-e)/(3.49*n))}const pJ=Uint32Array,G6=Uint32Array;var yJ=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function mJ(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function wJ(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function i(){if(this instanceof i){var s=[null];s.push.apply(s,arguments);var o=Function.bind.apply(t,s);return new o}return t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(i){var s=Object.getOwnPropertyDescriptor(e,i);Object.defineProperty(n,i,s.get?s:{enumerable:!0,get:function(){return e[i]}})}),n}function LJ(e){for(var t=new Array(e),n=0;n * @license MIT */var TJ=function(e){return e!=null&&(TR(e)||vJ(e)||!!e._isBuffer)};function TR(e){return!!e.constructor&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e)}function vJ(e){return typeof e.readFloatLE=="function"&&typeof e.slice=="function"&&TR(e.slice(0,0))}var EJ=bJ,SJ=TJ,xJ=typeof Float64Array<"u";function kJ(e,t){return e[0]-t[0]}function BJ(){var e=this.stride,t=new Array(e.length),n;for(n=0;nMath.abs(this.stride[1]))?[1,0]:[0,1]}})"):t===3&&s.push("var s0=Math.abs(this.stride[0]),s1=Math.abs(this.stride[1]),s2=Math.abs(this.stride[2]);if(s0>s1){if(s1>s2){return [2,1,0];}else if(s0>s2){return [1,2,0];}else{return [1,0,2];}}else if(s0>s2){return [2,0,1];}else if(s2>s1){return [0,1,2];}else{return [0,2,1];}}})")):s.push("ORDER})")),s.push("proto.set=function "+n+"_set("+c.join(",")+",v){"),i?s.push("return this.data.set("+d+",v)}"):s.push("return this.data["+d+"]=v}"),s.push("proto.get=function "+n+"_get("+c.join(",")+"){"),i?s.push("return this.data.get("+d+")}"):s.push("return this.data["+d+"]}"),s.push("proto.index=function "+n+"_index(",c.join(),"){return "+d+"}"),s.push("proto.hi=function "+n+"_hi("+c.join(",")+"){return new "+n+"(this.data,"+o.map(function(L){return["(typeof i",L,"!=='number'||i",L,"<0)?this.shape[",L,"]:i",L,"|0"].join("")}).join(",")+","+o.map(function(L){return"this.stride["+L+"]"}).join(",")+",this.offset)}");var a=o.map(function(L){return"a"+L+"=this.shape["+L+"]"}),m=o.map(function(L){return"c"+L+"=this.stride["+L+"]"});s.push("proto.lo=function "+n+"_lo("+c.join(",")+"){var b=this.offset,d=0,"+a.join(",")+","+m.join(","));for(var y=0;y=0){d=i"+y+"|0;b+=c"+y+"*d;a"+y+"-=d}");s.push("return new "+n+"(this.data,"+o.map(function(L){return"a"+L}).join(",")+","+o.map(function(L){return"c"+L}).join(",")+",b)}"),s.push("proto.step=function "+n+"_step("+c.join(",")+"){var "+o.map(function(L){return"a"+L+"=this.shape["+L+"]"}).join(",")+","+o.map(function(L){return"b"+L+"=this.stride["+L+"]"}).join(",")+",c=this.offset,d=0,ceil=Math.ceil");for(var y=0;y=0){c=(c+this.stride["+y+"]*i"+y+")|0}else{a.push(this.shape["+y+"]);b.push(this.stride["+y+"])}");s.push("var ctor=CTOR_LIST[a.length+1];return ctor(this.data,a,b,c)}"),s.push("return function construct_"+n+"(data,shape,stride,offset){return new "+n+"(data,"+o.map(function(L){return"shape["+L+"]"}).join(",")+","+o.map(function(L){return"stride["+L+"]"}).join(",")+",offset)}");var b=new Function("CTOR_LIST","ORDER",s.join(` `));return b(vp[e],BJ)}function IJ(e){if(SJ(e))return"buffer";if(xJ)switch(Object.prototype.toString.call(e)){case"[object Float64Array]":return"float64";case"[object Float32Array]":return"float32";case"[object Int8Array]":return"int8";case"[object Int16Array]":return"int16";case"[object Int32Array]":return"int32";case"[object Uint8Array]":return"uint8";case"[object Uint16Array]":return"uint16";case"[object Uint32Array]":return"uint32";case"[object Uint8ClampedArray]":return"uint8_clamped";case"[object BigInt64Array]":return"bigint64";case"[object BigUint64Array]":return"biguint64"}return Array.isArray(e)?"array":"generic"}var vp={float32:[],float64:[],int8:[],int16:[],int32:[],uint8:[],uint16:[],uint32:[],array:[],uint8_clamped:[],bigint64:[],biguint64:[],buffer:[],generic:[]};function OJ(e,t,n,i){if(e===void 0){var u=vp.array[0];return u([])}else typeof e=="number"&&(e=[e]);t===void 0&&(t=[e.length]);var s=t.length;if(n===void 0){n=new Array(s);for(var o=s-1,c=1;o>=0;--o)n[o]=c,c*=t[o]}if(i===void 0){i=0;for(var o=0;o1&&!u?f.push("+"):u&&f.push("-"),e==="generic"?f.push(Zf,".get("):f.push(Zf,"["),f.push(Jc,"-",d.join("-")),e==="generic"?f.push(")"):f.push("]")}return e==="generic"?f.push(");"):f.push(";"),f.join("")}t[n-1]=!0;var a=[z5(e,t,n-1),Jc,"+=",Ep,n-1,";for(",N_,n-1,"=1;",N_,n-1,"<",v1,n-1,";++",N_,n-1,"){"];return t[n-1]=!1,a.push(z5(e,t,n-1),Jc,"+=",Ep,n-1,";}"),a.join("")}function NJ(e,t){for(var n=["prefixSum",t.length,"d",e,"s",t.join("s")].join(""),i=["function ",n,"(arr){var ",Zf,"=arr.data,",v1,"=arr.shape,",Zc,"=arr.stride,",Jc,"=arr.offset,"],s=t.length,o=0;o0;--o)i.push(Ep,o,"=",Zc,o,"-",v1,o-1,"*",Zc,o-1,",");i.push(Ep,"0=",Zc,0,";");for(var c=new Array(s),o=0;o0,c=[],d=[],f=0,u=0,a,m;for(a=0;a0&&c.push("var "+d.join(",")),a=i-1;a>=0;--a)f=e[a],c.push(["for(i",a,"=0;i",a,"0&&c.push(["index[",u,"]-=s",u].join("")),c.push(["++index[",f,"]"].join(""))),c.push("}")}return c.join(` `)}function HJ(e,t,n,i){for(var s=t.length,o=n.arrayArgs.length,c=n.blockSize,d=n.indexArgs.length>0,f=[],u=0;u0;){"].join("")),f.push(["if(j",u,"<",c,"){"].join("")),f.push(["s",t[u],"=j",u].join("")),f.push(["j",u,"=0"].join("")),f.push(["}else{s",t[u],"=",c].join("")),f.push(["j",u,"-=",c,"}"].join("")),d&&f.push(["index[",t[u],"]=j",u].join(""));for(var u=0;u0&&(n=n&&t[i]===t[i-1])}return n?t[0]:t.join("")}function qJ(e,t){for(var n=t[1].length-Math.abs(e.arrayBlockIndices[0])|0,i=new Array(e.arrayArgs.length),s=new Array(e.arrayArgs.length),o=0;o0&&b.push("shape=SS.slice(0)"),e.indexArgs.length>0){for(var L=new Array(n),o=0;o0&&l.push("var "+b.join(","));for(var o=0;o3&&l.push(W6(e.pre,e,s));var F=W6(e.body,e,s),k=zJ(a);k3&&l.push(W6(e.post,e,s)),e.debug&&console.log("-----Generated cwise routine for ",t,`: `+l.join(` `)+` ----------`);var M=[e.funcName||"unnamed","_cwise_loop_",i[0].join("s"),"m",k,$J(s)].join(""),O=new Function(["function ",M,"(",p.join(","),"){",l.join(` `),"} return ",M].join(""));return O()}var VJ=qJ,GJ=VJ;function WJ(e){var t=["'use strict'","var CACHED={}"],n=[],i=e.funcName+"_cwise_thunk";t.push(["return function ",i,"(",e.shimArgs.join(","),"){"].join(""));for(var s=[],o=[],c=[["array",e.arrayArgs[0],".shape.slice(",Math.max(0,e.arrayBlockIndices[0]),e.arrayBlockIndices[0]<0?","+e.arrayBlockIndices[0]+")":")"].join("")],d=[],f=[],u=0;u0&&(d.push("array"+e.arrayArgs[0]+".shape.length===array"+a+".shape.length+"+(Math.abs(e.arrayBlockIndices[0])-Math.abs(e.arrayBlockIndices[u]))),f.push("array"+e.arrayArgs[0]+".shape[shapeIndex+"+Math.max(0,e.arrayBlockIndices[0])+"]===array"+a+".shape[shapeIndex+"+Math.max(0,e.arrayBlockIndices[u])+"]"))}e.arrayArgs.length>1&&(t.push("if (!("+d.join(" && ")+")) throw new Error('cwise: Arrays do not all have the same dimensionality!')"),t.push("for(var shapeIndex=array"+e.arrayArgs[0]+".shape.length-"+Math.abs(e.arrayBlockIndices[0])+"; shapeIndex-->0;) {"),t.push("if (!("+f.join(" && ")+")) throw new Error('cwise: Arrays do not all have the same shape!')"),t.push("}"));for(var u=0;u0)throw new Error("cwise: pre() block may not reference array args");if(i0)throw new Error("cwise: post() block may not reference array args")}else if(s==="scalar")t.scalarArgs.push(i),t.shimArgs.push("scalar"+i);else if(s==="index"){if(t.indexArgs.push(i),i0)throw new Error("cwise: pre() block may not reference array index");if(i0)throw new Error("cwise: post() block may not reference array index")}else if(s==="shape"){if(t.shapeArgs.push(i),in.length)throw new Error("cwise: Too many arguments in pre() block");if(t.body.args.length>n.length)throw new Error("cwise: Too many arguments in body() block");if(t.post.args.length>n.length)throw new Error("cwise: Too many arguments in post() block");return t.debug=!!e.printCode||!!e.debug,t.funcName=e.funcName||"cwise",t.blockSize=e.blockSize||64,XJ(t)}var JJ=ZJ;(function(e){var t=JJ,n={body:"",args:[],thisVars:[],localVars:[]};function i(y){if(!y)return n;for(var p=0;p>",rrshift:">>>"};(function(){for(var y in c){var p=c[y];e[y]=o({args:["array","array","array"],body:{args:["a","b","c"],body:"a=b"+p+"c"},funcName:y}),e[y+"eq"]=o({args:["array","array"],body:{args:["a","b"],body:"a"+p+"=b"},rvalue:!0,funcName:y+"eq"}),e[y+"s"]=o({args:["array","array","scalar"],body:{args:["a","b","s"],body:"a=b"+p+"s"},funcName:y+"s"}),e[y+"seq"]=o({args:["array","scalar"],body:{args:["a","s"],body:"a"+p+"=s"},rvalue:!0,funcName:y+"seq"})}})();var d={not:"!",bnot:"~",neg:"-",recip:"1.0/"};(function(){for(var y in d){var p=d[y];e[y]=o({args:["array","array"],body:{args:["a","b"],body:"a="+p+"b"},funcName:y}),e[y+"eq"]=o({args:["array"],body:{args:["a"],body:"a="+p+"a"},rvalue:!0,count:2,funcName:y+"eq"})}})();var f={and:"&&",or:"||",eq:"===",neq:"!==",lt:"<",gt:">",leq:"<=",geq:">="};(function(){for(var y in f){var p=f[y];e[y]=o({args:["array","array","array"],body:{args:["a","b","c"],body:"a=b"+p+"c"},funcName:y}),e[y+"s"]=o({args:["array","array","scalar"],body:{args:["a","b","s"],body:"a=b"+p+"s"},funcName:y+"s"}),e[y+"eq"]=o({args:["array","array"],body:{args:["a","b"],body:"a=a"+p+"b"},rvalue:!0,count:2,funcName:y+"eq"}),e[y+"seq"]=o({args:["array","scalar"],body:{args:["a","s"],body:"a=a"+p+"s"},rvalue:!0,count:2,funcName:y+"seq"})}})();var u=["abs","acos","asin","atan","ceil","cos","exp","floor","log","round","sin","sqrt","tan"];(function(){for(var y=0;ythis_s){this_s=-a}else if(a>this_s){this_s=a}",localVars:[],thisVars:["this_s"]},post:{args:[],localVars:[],thisVars:["this_s"],body:"return this_s"},funcName:"norminf"}),e.norm1=t({args:["array"],pre:{args:[],localVars:[],thisVars:["this_s"],body:"this_s=0"},body:{args:[{name:"a",lvalue:!1,rvalue:!0,count:3}],body:"this_s+=a<0?-a:a",localVars:[],thisVars:["this_s"]},post:{args:[],localVars:[],thisVars:["this_s"],body:"return this_s"},funcName:"norm1"}),e.sup=t({args:["array"],pre:{body:"this_h=-Infinity",args:[],thisVars:["this_h"],localVars:[]},body:{body:"if(_inline_1_arg0_>this_h)this_h=_inline_1_arg0_",args:[{name:"_inline_1_arg0_",lvalue:!1,rvalue:!0,count:2}],thisVars:["this_h"],localVars:[]},post:{body:"return this_h",args:[],thisVars:["this_h"],localVars:[]}}),e.inf=t({args:["array"],pre:{body:"this_h=Infinity",args:[],thisVars:["this_h"],localVars:[]},body:{body:"if(_inline_1_arg0_this_v){this_v=_inline_1_arg1_;for(var _inline_1_k=0;_inline_1_k<_inline_1_arg0_.length;++_inline_1_k){this_i[_inline_1_k]=_inline_1_arg0_[_inline_1_k]}}}",args:[{name:"_inline_1_arg0_",lvalue:!1,rvalue:!0,count:2},{name:"_inline_1_arg1_",lvalue:!1,rvalue:!0,count:2}],thisVars:["this_i","this_v"],localVars:["_inline_1_k"]},post:{body:"{return this_i}",args:[],thisVars:["this_i"],localVars:[]}}),e.random=o({args:["array"],pre:{args:[],body:"this_f=Math.random",thisVars:["this_f"]},body:{args:["a"],body:"a=this_f()",thisVars:["this_f"]},funcName:"random"}),e.assign=o({args:["array","array"],body:{args:["a","b"],body:"a=b"},funcName:"assign"}),e.assigns=o({args:["array","scalar"],body:{args:["a","b"],body:"a=b"},funcName:"assigns"}),e.equals=t({args:["array","array"],pre:n,body:{args:[{name:"x",lvalue:!1,rvalue:!0,count:1},{name:"y",lvalue:!1,rvalue:!0,count:1}],body:"if(x!==y){return false}",localVars:[],thisVars:[]},post:{args:[],localVars:[],thisVars:[],body:"return true"},funcName:"equals"})})(E1);const Jf=class{constructor(e,t,n,i){this.data=e,this.ndarray=MJ(e,t,n,i)}get shape(){return this.ndarray.shape}get offset(){return this.ndarray.offset}get strides(){return this.ndarray.stride}get length(){return this.ndarray.size}set shape(e){this.ndarray.shape=e}set offset(e){this.ndarray.offset=e}set strides(e){this.ndarray.stride=e}get(...e){return this.ndarray.get(...e)}set(...e){return this.ndarray.set(...e)}fill(e){this.data.fill(e)}increment(e,t=1){const n=this.ndarray.index(...e);this.data[n]+=t}addToItself(e){return E1.addeq(this.ndarray,e.ndarray),this}subToItself(e){return E1.subeq(this.ndarray,e.ndarray),this}add(e,t=G6){const n=new Jf(new t(this.length),this.shape);return E1.add(n.ndarray,this.ndarray,e.ndarray),n}sub(e,t=G6){const n=new Jf(new t(this.length),this.shape);return E1.sub(n.ndarray,this.ndarray,e.ndarray),n}slice(...e){const t=this.ndarray.pick(...e);return new Jf(this.data,t.shape,t.stride,t.offset)}cumulativeSum(){return AJ(this.ndarray),this}static typedArray(e,t,n,i,s){const o=new e(t);return new Jf(o,n,i,s)}static allocCumulative(e,t,n,i){return this.typedArray(pJ,e,t,n,i)}static allocCounts(e,t,n,i){return this.typedArray(G6,e,t,n,i)}toString2D(){let e="";for(let t=0;tt?1:e>=t?0:NaN}function QJ(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function w0(e){let t,n,i;e.length!==2?(t=No,n=(d,f)=>No(e(d),f),i=(d,f)=>e(d)-f):(t=e===No||e===QJ?e:eQ,n=e,i=e);function s(d,f,u=0,a=d.length){if(u>>1;n(d[m],f)<0?u=m+1:a=m}while(u>>1;n(d[m],f)<=0?u=m+1:a=m}while(uu&&i(d[m-1],f)>-i(d[m],f)?m-1:m}return{left:s,center:c,right:o}}function eQ(){return 0}function ER(e){return e===null?NaN:+e}function*tQ(e,t){if(t===void 0)for(let n of e)n!=null&&(n=+n)>=n&&(yield n);else{let n=-1;for(let i of e)(i=t(i,++n,e))!=null&&(i=+i)>=i&&(yield i)}}const SR=w0(No),Sp=SR.right,nQ=SR.left;w0(ER).center;const L0=Sp;function iQ(e,t){let n=0,i,s=0,o=0;if(t===void 0)for(let c of e)c!=null&&(c=+c)>=c&&(i=c-s,s+=i/++n,o+=i*(c-s));else{let c=-1;for(let d of e)(d=t(d,++c,e))!=null&&(d=+d)>=d&&(i=d-s,s+=i/++n,o+=i*(d-s))}if(n>1)return o/(n-1)}function sQ(e,t){const n=iQ(e,t);return n&&Math.sqrt(n)}function xR(e,t){let n,i;if(t===void 0)for(const s of e)s!=null&&(n===void 0?s>=s&&(n=i=s):(n>s&&(n=s),i=o&&(n=i=o):(n>o&&(n=o),i0){for(c=t[--n];n>0&&(i=c,s=t[--n],c=i+s,o=s-(c-i),!o););n>0&&(o<0&&t[n-1]<0||o>0&&t[n-1]>0)&&(s=o*2,i=c+s,s==i-c&&(c=i))}return c}}class iB extends Map{constructor(t,n=FR){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[i,s]of t)this.set(i,s)}get(t){return super.get($5(this,t))}has(t){return super.has($5(this,t))}set(t,n){return super.set(kR(this,t),n)}delete(t){return super.delete(BR(this,t))}}class xp extends Set{constructor(t,n=FR){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const i of t)this.add(i)}has(t){return super.has($5(this,t))}add(t){return super.add(kR(this,t))}delete(t){return super.delete(BR(this,t))}}function $5({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):n}function kR({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):(e.set(i,n),n)}function BR({_intern:e,_key:t},n){const i=t(n);return e.has(i)&&(n=e.get(i),e.delete(i)),n}function FR(e){return e!==null&&typeof e=="object"?e.valueOf():e}function rQ(e,t){return Array.from(t,n=>e[n])}function aQ(e=No){if(e===No)return IR;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,n)=>{const i=e(t,n);return i||i===0?i:(e(n,n)===0)-(e(t,t)===0)}}function IR(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(et?1:0)}const oQ=Math.sqrt(50),lQ=Math.sqrt(10),cQ=Math.sqrt(2);function kp(e,t,n){const i=(t-e)/Math.max(0,n),s=Math.floor(Math.log10(i)),o=i/Math.pow(10,s),c=o>=oQ?10:o>=lQ?5:o>=cQ?2:1;let d,f,u;return s<0?(u=Math.pow(10,-s)/c,d=Math.round(e*u),f=Math.round(t*u),d/ut&&--f,u=-u):(u=Math.pow(10,s)*c,d=Math.round(e/u),f=Math.round(t/u),d*ut&&--f),f0))return[];if(e===t)return[e];const i=t=s))return[];const d=o-s+1,f=new Array(d);if(i)if(c<0)for(let u=0;u=i)&&(n=i);else{let i=-1;for(let s of e)(s=t(s,++i,e))!=null&&(n=s)&&(n=s)}return n}function G5(e,t){let n;if(t===void 0)for(const i of e)i!=null&&(n>i||n===void 0&&i>=i)&&(n=i);else{let i=-1;for(let s of e)(s=t(s,++i,e))!=null&&(n>s||n===void 0&&s>=s)&&(n=s)}return n}function OR(e,t,n=0,i=1/0,s){if(t=Math.floor(t),n=Math.floor(Math.max(0,n)),i=Math.floor(Math.min(e.length-1,i)),!(n<=t&&t<=i))return e;for(s=s===void 0?IR:aQ(s);i>n;){if(i-n>600){const f=i-n+1,u=t-n+1,a=Math.log(f),m=.5*Math.exp(2*a/3),y=.5*Math.sqrt(a*m*(f-m)/f)*(u-f/2<0?-1:1),p=Math.max(n,Math.floor(t-u*m/f+y)),l=Math.min(i,Math.floor(t+(f-u)*m/f+y));OR(e,t,p,l,s)}const o=e[t];let c=n,d=i;for(Xh(e,n,t),s(e[i],o)>0&&Xh(e,n,i);c0;)--d}s(e[n],o)===0?Xh(e,n,d):(++d,Xh(e,d,i)),d<=t&&(n=d+1),t<=d&&(i=d-1)}return e}function Xh(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function W5(e,t,n){if(e=Float64Array.from(tQ(e,n)),!(!(i=e.length)||isNaN(t=+t))){if(t<=0||i<2)return G5(e);if(t>=1)return bd(e);var i,s=(i-1)*t,o=Math.floor(s),c=bd(OR(e,o).subarray(0,o+1)),d=G5(e.subarray(o+1));return c+(d-c)*(s-o)}}function MR(e,t,n=ER){if(!(!(i=e.length)||isNaN(t=+t))){if(t<=0||i<2)return+n(e[0],0,e);if(t>=1)return+n(e[i-1],i-1,e);var i,s=(i-1)*t,o=Math.floor(s),c=+n(e[o],o,e),d=+n(e[o+1],o+1,e);return c+(d-c)*(s-o)}}function dQ(e,t){let n=0,i=0;if(t===void 0)for(let s of e)s!=null&&(s=+s)>=s&&(++n,i+=s);else{let s=-1;for(let o of e)(o=t(o,++s,e))!=null&&(o=+o)>=o&&(++n,i+=o)}if(n)return i/n}function AR(e,t){return W5(e,.5,t)}function*fQ(e){for(const t of e)yield*t}function NR(e){return Array.from(fQ(e))}function Os(e,t,n){e=+e,t=+t,n=(s=arguments.length)<2?(t=e,e=0,1):s<3?1:+n;for(var i=-1,s=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(s);++i+e(t)}function pQ(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function yQ(){return!this.__axis}function mQ(e,t){var n=[],i=null,s=null,o=6,c=6,d=3,f=typeof window<"u"&&window.devicePixelRatio>1?0:.5,u=e===Y6||e===Og?-1:1,a=e===Og||e===X6?"x":"y",m=e===Y6||e===Y5?hQ:gQ;function y(p){var l=i??(t.ticks?t.ticks.apply(t,n):t.domain()),b=s??(t.tickFormat?t.tickFormat.apply(t,n):uQ),L=Math.max(o,0)+d,E=t.range(),S=+E[0]+f,x=+E[E.length-1]+f,F=(t.bandwidth?pQ:_Q)(t.copy(),f),k=p.selection?p.selection():p,M=k.selectAll(".domain").data([null]),O=k.selectAll(".tick").data(l,t).order(),C=O.exit(),P=O.enter().append("g").attr("class","tick"),j=O.select("line"),R=O.select("text");M=M.merge(M.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),O=O.merge(P),j=j.merge(P.append("line").attr("stroke","currentColor").attr(a+"2",u*o)),R=R.merge(P.append("text").attr("fill","currentColor").attr(a,u*L).attr("dy",e===Y6?"0em":e===Y5?"0.71em":"0.32em")),p!==k&&(M=M.transition(p),O=O.transition(p),j=j.transition(p),R=R.transition(p),C=C.transition(p).attr("opacity",sB).attr("transform",function(H){return isFinite(H=F(H))?m(H+f):this.getAttribute("transform")}),P.attr("opacity",sB).attr("transform",function(H){var z=this.parentNode.__axis;return m((z&&isFinite(z=z(H))?z:F(H))+f)})),C.remove(),M.attr("d",e===Og||e===X6?c?"M"+u*c+","+S+"H"+f+"V"+x+"H"+u*c:"M"+f+","+S+"V"+x:c?"M"+S+","+u*c+"V"+f+"H"+x+"V"+u*c:"M"+S+","+f+"H"+x),O.attr("opacity",1).attr("transform",function(H){return m(F(H)+f)}),j.attr(a+"2",u*o),R.attr(a,u*L).text(b),k.filter(yQ).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===X6?"start":e===Og?"end":"middle"),k.each(function(){this.__axis=F})}return y.scale=function(p){return arguments.length?(t=p,y):t},y.ticks=function(){return n=Array.from(arguments),y},y.tickArguments=function(p){return arguments.length?(n=p==null?[]:Array.from(p),y):n.slice()},y.tickValues=function(p){return arguments.length?(i=p==null?null:Array.from(p),y):i&&i.slice()},y.tickFormat=function(p){return arguments.length?(s=p,y):s},y.tickSize=function(p){return arguments.length?(o=c=+p,y):o},y.tickSizeInner=function(p){return arguments.length?(o=+p,y):o},y.tickSizeOuter=function(p){return arguments.length?(c=+p,y):c},y.tickPadding=function(p){return arguments.length?(d=+p,y):d},y.offset=function(p){return arguments.length?(f=+p,y):f},y}function wQ(e){return mQ(Y5,e)}var LQ={value:()=>{}};function B7(){for(var e=0,t=arguments.length,n={},i;e=0&&(i=n.slice(s+1),n=n.slice(0,s)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:i}})}C_.prototype=B7.prototype={constructor:C_,on:function(e,t){var n=this._,i=bQ(e+"",n),s,o=-1,c=i.length;if(arguments.length<2){for(;++o0)for(var n=new Array(s),i=0,s,o;i=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),aB.hasOwnProperty(t)?{space:aB[t],local:e}:e}function vQ(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===X5&&t.documentElement.namespaceURI===X5?t.createElement(e):t.createElementNS(n,e)}}function EQ(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function RR(e){var t=x4(e);return(t.local?EQ:vQ)(t)}function SQ(){}function F7(e){return e==null?SQ:function(){return this.querySelector(e)}}function xQ(e){typeof e!="function"&&(e=F7(e));for(var t=this._groups,n=t.length,i=new Array(n),s=0;s=x&&(x=S+1);!(k=L[x])&&++x=0;)(c=i[s])&&(o&&c.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(c,o),o=c);return this}function ZQ(e){e||(e=JQ);function t(m,y){return m&&y?e(m.__data__,y.__data__):!m-!y}for(var n=this._groups,i=n.length,s=new Array(i),o=0;ot?1:e>=t?0:NaN}function QQ(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function eee(){return Array.from(this)}function tee(){for(var e=this._groups,t=0,n=e.length;t1?this.each((t==null?uee:typeof t=="function"?gee:hee)(e,t,n??"")):Du(this.node(),e)}function Du(e,t){return e.style.getPropertyValue(t)||HR(e).getComputedStyle(e,null).getPropertyValue(t)}function pee(e){return function(){delete this[e]}}function yee(e,t){return function(){this[e]=t}}function mee(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function wee(e,t){return arguments.length>1?this.each((t==null?pee:typeof t=="function"?mee:yee)(e,t)):this.node()[e]}function zR(e){return e.trim().split(/^|\s+/)}function I7(e){return e.classList||new $R(e)}function $R(e){this._node=e,this._names=zR(e.getAttribute("class")||"")}$R.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function qR(e,t){for(var n=I7(e),i=-1,s=t.length;++i=0&&(n=t.slice(i+1),t=t.slice(0,i)),{type:t,name:n}})}function Wee(e){return function(){var t=this.__on;if(t){for(var n=0,i=-1,s=t.length,o;n>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Mg(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Mg(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=ite.exec(e))?new $n(t[1],t[2],t[3],1):(t=ste.exec(e))?new $n(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=rte.exec(e))?Mg(t[1],t[2],t[3],t[4]):(t=ate.exec(e))?Mg(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=ote.exec(e))?hB(t[1],t[2]/100,t[3]/100,1):(t=lte.exec(e))?hB(t[1],t[2]/100,t[3]/100,t[4]):oB.hasOwnProperty(e)?dB(oB[e]):e==="transparent"?new $n(NaN,NaN,NaN,0):null}function dB(e){return new $n(e>>16&255,e>>8&255,e&255,1)}function Mg(e,t,n,i){return i<=0&&(e=t=n=NaN),new $n(e,t,n,i)}function O7(e){return e instanceof Lc||(e=Ql(e)),e?(e=e.rgb(),new $n(e.r,e.g,e.b,e.opacity)):new $n}function ec(e,t,n,i){return arguments.length===1?O7(e):new $n(e,t,n,i??1)}function $n(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}Th($n,ec,T0(Lc,{brighter(e){return e=e==null?ju:Math.pow(ju,e),new $n(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Cd:Math.pow(Cd,e),new $n(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new $n(Td(this.r),Td(this.g),Td(this.b),Fp(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:fB,formatHex:fB,formatHex8:fte,formatRgb:uB,toString:uB}));function fB(){return`#${_d(this.r)}${_d(this.g)}${_d(this.b)}`}function fte(){return`#${_d(this.r)}${_d(this.g)}${_d(this.b)}${_d((isNaN(this.opacity)?1:this.opacity)*255)}`}function uB(){const e=Fp(this.opacity);return`${e===1?"rgb(":"rgba("}${Td(this.r)}, ${Td(this.g)}, ${Td(this.b)}${e===1?")":`, ${e})`}`}function Fp(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Td(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function _d(e){return e=Td(e),(e<16?"0":"")+e.toString(16)}function hB(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Er(e,t,n,i)}function YR(e){if(e instanceof Er)return new Er(e.h,e.s,e.l,e.opacity);if(e instanceof Lc||(e=Ql(e)),!e)return new Er;if(e instanceof Er)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,s=Math.min(t,n,i),o=Math.max(t,n,i),c=NaN,d=o-s,f=(o+s)/2;return d?(t===o?c=(n-i)/d+(n0&&f<1?0:c,new Er(c,d,f,e.opacity)}function Ip(e,t,n,i){return arguments.length===1?YR(e):new Er(e,t,n,i??1)}function Er(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}Th(Er,Ip,T0(Lc,{brighter(e){return e=e==null?ju:Math.pow(ju,e),new Er(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Cd:Math.pow(Cd,e),new Er(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*t,s=2*n-i;return new $n(K6(e>=240?e-240:e+120,s,i),K6(e,s,i),K6(e<120?e+240:e-120,s,i),this.opacity)},clamp(){return new Er(gB(this.h),Ag(this.s),Ag(this.l),Fp(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Fp(this.opacity);return`${e===1?"hsl(":"hsla("}${gB(this.h)}, ${Ag(this.s)*100}%, ${Ag(this.l)*100}%${e===1?")":`, ${e})`}`}}));function gB(e){return e=(e||0)%360,e<0?e+360:e}function Ag(e){return Math.max(0,Math.min(1,e||0))}function K6(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const XR=Math.PI/180,KR=180/Math.PI,Op=18,ZR=.96422,JR=1,QR=.82521,eP=4/29,yu=6/29,tP=3*yu*yu,ute=yu*yu*yu;function nP(e){if(e instanceof xa)return new xa(e.l,e.a,e.b,e.opacity);if(e instanceof ko)return iP(e);e instanceof $n||(e=O7(e));var t=ew(e.r),n=ew(e.g),i=ew(e.b),s=Z6((.2225045*t+.7168786*n+.0606169*i)/JR),o,c;return t===n&&n===i?o=c=s:(o=Z6((.4360747*t+.3850649*n+.1430804*i)/ZR),c=Z6((.0139322*t+.0971045*n+.7141733*i)/QR)),new xa(116*s-16,500*(o-s),200*(s-c),e.opacity)}function Mp(e,t,n,i){return arguments.length===1?nP(e):new xa(e,t,n,i??1)}function xa(e,t,n,i){this.l=+e,this.a=+t,this.b=+n,this.opacity=+i}Th(xa,Mp,T0(Lc,{brighter(e){return new xa(this.l+Op*(e??1),this.a,this.b,this.opacity)},darker(e){return new xa(this.l-Op*(e??1),this.a,this.b,this.opacity)},rgb(){var e=(this.l+16)/116,t=isNaN(this.a)?e:e+this.a/500,n=isNaN(this.b)?e:e-this.b/200;return t=ZR*J6(t),e=JR*J6(e),n=QR*J6(n),new $n(Q6(3.1338561*t-1.6168667*e-.4906146*n),Q6(-.9787684*t+1.9161415*e+.033454*n),Q6(.0719453*t-.2289914*e+1.4052427*n),this.opacity)}}));function Z6(e){return e>ute?Math.pow(e,1/3):e/tP+eP}function J6(e){return e>yu?e*e*e:tP*(e-eP)}function Q6(e){return 255*(e<=.0031308?12.92*e:1.055*Math.pow(e,1/2.4)-.055)}function ew(e){return(e/=255)<=.04045?e/12.92:Math.pow((e+.055)/1.055,2.4)}function hte(e){if(e instanceof ko)return new ko(e.h,e.c,e.l,e.opacity);if(e instanceof xa||(e=nP(e)),e.a===0&&e.b===0)return new ko(NaN,0=1?(n=1,t-1):Math.floor(n*t),s=e[i],o=e[i+1],c=i>0?e[i-1]:2*s-o,d=i()=>e;function lP(e,t){return function(n){return e+n*t}}function _te(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}function F4(e,t){var n=t-e;return n?lP(e,n>180||n<-180?n-360*Math.round(n/360):n):B4(isNaN(e)?t:e)}function pte(e){return(e=+e)==1?qn:function(t,n){return n-t?_te(t,n,e):B4(isNaN(t)?n:t)}}function qn(e,t){var n=t-e;return n?lP(e,n):B4(isNaN(e)?t:e)}const B2=function e(t){var n=pte(t);function i(s,o){var c=n((s=ec(s)).r,(o=ec(o)).r),d=n(s.g,o.g),f=n(s.b,o.b),u=qn(s.opacity,o.opacity);return function(a){return s.r=c(a),s.g=d(a),s.b=f(a),s.opacity=u(a),s+""}}return i.gamma=e,i}(1);function cP(e){return function(t){var n=t.length,i=new Array(n),s=new Array(n),o=new Array(n),c,d;for(c=0;cn&&(o=t.slice(n,o),d[c]?d[c]+=o:d[++c]=o),(i=i[0])===(s=s[0])?d[c]?d[c]+=s:d[++c]=s:(d[++c]=null,f.push({i:c,x:Gs(i,s)})),n=tw.lastIndex;return n180?a+=360:a-u>180&&(u+=360),y.push({i:m.push(s(m)+"rotate(",null,i)-2,x:Gs(u,a)})):a&&m.push(s(m)+"rotate("+a+i)}function d(u,a,m,y){u!==a?y.push({i:m.push(s(m)+"skewX(",null,i)-2,x:Gs(u,a)}):a&&m.push(s(m)+"skewX("+a+i)}function f(u,a,m,y,p,l){if(u!==m||a!==y){var b=p.push(s(p)+"scale(",null,",",null,")");l.push({i:b-4,x:Gs(u,m)},{i:b-2,x:Gs(a,y)})}else(m!==1||y!==1)&&p.push(s(p)+"scale("+m+","+y+")")}return function(u,a){var m=[],y=[];return u=e(u),a=e(a),o(u.translateX,u.translateY,a.translateX,a.translateY,m,y),c(u.rotate,a.rotate,m,y),d(u.skewX,a.skewX,m,y),f(u.scaleX,u.scaleY,a.scaleX,a.scaleY,m,y),u=a=null,function(p){for(var l=-1,b=y.length,L;++l=0&&e._call.call(void 0,t),e=e._next;--Uu}function LB(){Rd=(Cp=F2.now())+I4,Uu=S1=0;try{jte()}finally{Uu=0,Hte(),Rd=0}}function Ute(){var e=F2.now(),t=e-Cp;t>TP&&(I4-=t,Cp=e)}function Hte(){for(var e,t=Np,n,i=1/0;t;)t._call?(i>t._time&&(i=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Np=n);x1=e,Q5(i)}function Q5(e){if(!Uu){S1&&(S1=clearTimeout(S1));var t=e-Rd;t>24?(e<1/0&&(S1=setTimeout(LB,e-F2.now()-I4)),Kh&&(Kh=clearInterval(Kh))):(Kh||(Cp=F2.now(),Kh=setInterval(Ute,TP)),Uu=1,vP(LB))}}function bB(e,t,n){var i=new I2;return t=t==null?0:+t,i.restart(s=>{i.stop(),e(s+t)},t,n),i}function zte(e,t,n){var i=new I2,s=t;return t==null?(i.restart(e,t,n),i):(i._restart=i.restart,i.restart=function(o,c,d){c=+c,d=d==null?O4():+d,i._restart(function f(u){u+=s,i._restart(f,s+=c,d),o(u)},c,d)},i.restart(e,t,n),i)}var $te=B7("start","end","cancel","interrupt"),qte=[],EP=0,TB=1,eL=2,R_=3,vB=4,tL=5,P_=6;function M4(e,t,n,i,s,o){var c=e.__transition;if(!c)e.__transition={};else if(n in c)return;Vte(e,n,{name:t,index:i,group:s,on:$te,tween:qte,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:EP})}function D7(e,t){var n=Yr(e,t);if(n.state>EP)throw new Error("too late; already scheduled");return n}function Xa(e,t){var n=Yr(e,t);if(n.state>R_)throw new Error("too late; already running");return n}function Yr(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function Vte(e,t,n){var i=e.__transition,s;i[t]=n,n.timer=P7(o,0,n.time);function o(u){n.state=TB,n.timer.restart(c,n.delay,n.time),n.delay<=u&&c(u-n.delay)}function c(u){var a,m,y,p;if(n.state!==TB)return f();for(a in i)if(p=i[a],p.name===n.name){if(p.state===R_)return bB(c);p.state===vB?(p.state=P_,p.timer.stop(),p.on.call("interrupt",e,e.__data__,p.index,p.group),delete i[a]):+aeL&&i.state=0&&(t=t.slice(0,n)),!t||t==="start"})}function Tne(e,t,n){var i,s,o=bne(t)?D7:Xa;return function(){var c=o(this,e),d=c.on;d!==i&&(s=(i=d).copy()).on(t,n),c.on=s}}function vne(e,t){var n=this._id;return arguments.length<2?Yr(this.node(),n).on.on(e):this.each(Tne(n,e,t))}function Ene(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function Sne(){return this.on("end.remove",Ene(this._id))}function xne(e){var t=this._name,n=this._id;typeof e!="function"&&(e=F7(e));for(var i=this._groups,s=i.length,o=new Array(s),c=0;c=0))throw new Error(`invalid digits: ${e}`);if(t>15)return BP;const n=10**t;return function(i){this._+=i[0];for(let s=1,o=i.length;sQc)if(!(Math.abs(m*f-u*a)>Qc)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let p=i-c,l=s-d,b=f*f+u*u,L=p*p+l*l,E=Math.sqrt(b),S=Math.sqrt(y),x=o*Math.tan((nL-Math.acos((b+y-L)/(2*E*S)))/2),F=x/S,k=x/E;Math.abs(F-1)>Qc&&this._append`L${t+F*a},${n+F*m}`,this._append`A${o},${o},0,0,${+(m*p>a*l)},${this._x1=t+k*f},${this._y1=n+k*u}`}}arc(t,n,i,s,o,c){if(t=+t,n=+n,i=+i,c=!!c,i<0)throw new Error(`negative radius: ${i}`);let d=i*Math.cos(s),f=i*Math.sin(s),u=t+d,a=n+f,m=1^c,y=c?s-o:o-s;this._x1===null?this._append`M${u},${a}`:(Math.abs(this._x1-u)>Qc||Math.abs(this._y1-a)>Qc)&&this._append`L${u},${a}`,i&&(y<0&&(y=y%iL+iL),y>Zne?this._append`A${i},${i},0,1,${m},${t-d},${n-f}A${i},${i},0,1,${m},${this._x1=u},${this._y1=a}`:y>Qc&&this._append`A${i},${i},0,${+(y>=nL)},${m},${this._x1=t+i*Math.cos(o)},${this._y1=n+i*Math.sin(o)}`)}rect(t,n,i,s){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${i=+i}v${+s}h${-i}Z`}toString(){return this._}};function A4(){return new U7}A4.prototype=U7.prototype;const Co=11102230246251565e-32,li=134217729,Qne=(3+8*Co)*Co;function nw(e,t,n,i,s){let o,c,d,f,u=t[0],a=i[0],m=0,y=0;a>u==a>-u?(o=u,u=t[++m]):(o=a,a=i[++y]);let p=0;if(mu==a>-u?(c=u+o,d=o-(c-u),u=t[++m]):(c=a+o,d=o-(c-a),a=i[++y]),o=c,d!==0&&(s[p++]=d);mu==a>-u?(c=o+u,f=c-o,d=o-(c-f)+(u-f),u=t[++m]):(c=o+a,f=c-o,d=o-(c-f)+(a-f),a=i[++y]),o=c,d!==0&&(s[p++]=d);for(;m=Y||-z>=Y||(m=e-P,d=e-(P+m)+(m-s),m=n-j,u=n-(j+m)+(m-s),m=t-R,f=t-(R+m)+(m-o),m=i-H,a=i-(H+m)+(m-o),d===0&&f===0&&u===0&&a===0)||(Y=iie*c+Qne*Math.abs(z),z+=P*a+H*d-(R*u+j*f),z>=Y||-z>=Y))return z;F=d*H,y=li*d,p=y-(y-d),l=d-p,y=li*H,b=y-(y-H),L=H-b,k=l*L-(F-p*b-l*b-p*L),M=f*j,y=li*f,p=y-(y-f),l=f-p,y=li*j,b=y-(y-j),L=j-b,O=l*L-(M-p*b-l*b-p*L),E=k-O,m=k-E,Bi[0]=k-(E+m)+(m-O),S=F+E,m=S-F,x=F-(S-m)+(E-m),E=x-M,m=x-E,Bi[1]=x-(E+m)+(m-M),C=S+E,m=C-S,Bi[2]=S-(C-m)+(E-m),Bi[3]=C;const $=nw(4,Bf,4,Bi,EB);F=P*a,y=li*P,p=y-(y-P),l=P-p,y=li*a,b=y-(y-a),L=a-b,k=l*L-(F-p*b-l*b-p*L),M=R*u,y=li*R,p=y-(y-R),l=R-p,y=li*u,b=y-(y-u),L=u-b,O=l*L-(M-p*b-l*b-p*L),E=k-O,m=k-E,Bi[0]=k-(E+m)+(m-O),S=F+E,m=S-F,x=F-(S-m)+(E-m),E=x-M,m=x-E,Bi[1]=x-(E+m)+(m-M),C=S+E,m=C-S,Bi[2]=S-(C-m)+(E-m),Bi[3]=C;const W=nw($,EB,4,Bi,SB);F=d*a,y=li*d,p=y-(y-d),l=d-p,y=li*a,b=y-(y-a),L=a-b,k=l*L-(F-p*b-l*b-p*L),M=f*u,y=li*f,p=y-(y-f),l=f-p,y=li*u,b=y-(y-u),L=u-b,O=l*L-(M-p*b-l*b-p*L),E=k-O,m=k-E,Bi[0]=k-(E+m)+(m-O),S=F+E,m=S-F,x=F-(S-m)+(E-m),E=x-M,m=x-E,Bi[1]=x-(E+m)+(m-M),C=S+E,m=C-S,Bi[2]=S-(C-m)+(E-m),Bi[3]=C;const X=nw(W,SB,4,Bi,xB);return xB[X-1]}function Cg(e,t,n,i,s,o){const c=(t-o)*(n-s),d=(e-s)*(i-o),f=c-d;if(c===0||d===0||c>0!=d>0)return f;const u=Math.abs(c+d);return Math.abs(f)>=tie*u?f:-sie(e,t,n,i,s,o,u)}const kB=Math.pow(2,-52),Rg=new Uint32Array(512);class Rp{static from(t,n=cie,i=die){const s=t.length,o=new Float64Array(s*2);for(let c=0;c>1;if(n>0&&typeof t[0]!="number")throw new Error("Expected coords to contain numbers.");this.coords=t;const i=Math.max(2*n-5,0);this._triangles=new Uint32Array(i*3),this._halfedges=new Int32Array(i*3),this._hashSize=Math.ceil(Math.sqrt(n)),this._hullPrev=new Uint32Array(n),this._hullNext=new Uint32Array(n),this._hullTri=new Uint32Array(n),this._hullHash=new Int32Array(this._hashSize).fill(-1),this._ids=new Uint32Array(n),this._dists=new Float64Array(n),this.update()}update(){const{coords:t,_hullPrev:n,_hullNext:i,_hullTri:s,_hullHash:o}=this,c=t.length>>1;let d=1/0,f=1/0,u=-1/0,a=-1/0;for(let j=0;ju&&(u=R),H>a&&(a=H),this._ids[j]=j}const m=(d+u)/2,y=(f+a)/2;let p=1/0,l,b,L;for(let j=0;j0&&(b=j,p=R)}let x=t[2*b],F=t[2*b+1],k=1/0;for(let j=0;jz&&(j[R++]=Y,z=this._dists[Y])}this.hull=j.subarray(0,R),this.triangles=new Uint32Array(0),this.halfedges=new Uint32Array(0);return}if(Cg(E,S,x,F,M,O)<0){const j=b,R=x,H=F;b=L,x=M,F=O,L=j,M=R,O=H}const C=lie(E,S,x,F,M,O);this._cx=C.x,this._cy=C.y;for(let j=0;j0&&Math.abs(Y-R)<=kB&&Math.abs($-H)<=kB||(R=Y,H=$,z===l||z===b||z===L))continue;let W=0;for(let ie=0,Oe=this._hashKey(Y,$);ie=0;)if(X=G,X===W){X=-1;break}if(X===-1)continue;let oe=this._addTriangle(X,z,i[X],-1,-1,s[X]);s[z]=this._legalize(oe+2),s[X]=oe,P++;let he=i[X];for(;G=i[he],Cg(Y,$,t[2*he],t[2*he+1],t[2*G],t[2*G+1])<0;)oe=this._addTriangle(he,z,G,s[z],-1,s[he]),s[z]=this._legalize(oe+2),i[he]=he,P--,he=G;if(X===W)for(;G=n[X],Cg(Y,$,t[2*G],t[2*G+1],t[2*X],t[2*X+1])<0;)oe=this._addTriangle(G,z,X,-1,s[X],s[G]),this._legalize(oe+2),s[G]=oe,i[X]=X,P--,X=G;this._hullStart=n[z]=X,i[X]=n[he]=z,i[z]=he,o[this._hashKey(Y,$)]=z,o[this._hashKey(t[2*X],t[2*X+1])]=X}this.hull=new Uint32Array(P);for(let j=0,R=this._hullStart;j0?3-n:1+n)/4}function iw(e,t,n,i){const s=e-n,o=t-i;return s*s+o*o}function aie(e,t,n,i,s,o,c,d){const f=e-c,u=t-d,a=n-c,m=i-d,y=s-c,p=o-d,l=f*f+u*u,b=a*a+m*m,L=y*y+p*p;return f*(m*L-b*p)-u*(a*L-b*y)+l*(a*p-m*y)<0}function oie(e,t,n,i,s,o){const c=n-e,d=i-t,f=s-e,u=o-t,a=c*c+d*d,m=f*f+u*u,y=.5/(c*u-d*f),p=(u*a-d*m)*y,l=(c*m-f*a)*y;return p*p+l*l}function lie(e,t,n,i,s,o){const c=n-e,d=i-t,f=s-e,u=o-t,a=c*c+d*d,m=f*f+u*u,y=.5/(c*u-d*f),p=e+(u*a-d*m)*y,l=t+(c*m-f*a)*y;return{x:p,y:l}}function nu(e,t,n,i){if(i-n<=20)for(let s=n+1;s<=i;s++){const o=e[s],c=t[o];let d=s-1;for(;d>=n&&t[e[d]]>c;)e[d+1]=e[d--];e[d+1]=o}else{const s=n+i>>1;let o=n+1,c=i;Zh(e,s,o),t[e[n]]>t[e[i]]&&Zh(e,n,i),t[e[o]]>t[e[i]]&&Zh(e,o,i),t[e[n]]>t[e[o]]&&Zh(e,n,o);const d=e[o],f=t[d];for(;;){do o++;while(t[e[o]]f);if(c=c-n?(nu(e,t,o,i),nu(e,t,n,c-1)):(nu(e,t,n,c-1),nu(e,t,o,i))}}function Zh(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function cie(e){return e[0]}function die(e){return e[1]}const BB=1e-6;class pd{constructor(){this._x0=this._y0=this._x1=this._y1=null,this._=""}moveTo(t,n){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")}lineTo(t,n){this._+=`L${this._x1=+t},${this._y1=+n}`}arc(t,n,i){t=+t,n=+n,i=+i;const s=t+i,o=n;if(i<0)throw new Error("negative radius");this._x1===null?this._+=`M${s},${o}`:(Math.abs(this._x1-s)>BB||Math.abs(this._y1-o)>BB)&&(this._+="L"+s+","+o),i&&(this._+=`A${i},${i},0,1,1,${t-i},${n}A${i},${i},0,1,1,${this._x1=s},${this._y1=o}`)}rect(t,n,i,s){this._+=`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${+i}v${+s}h${-i}Z`}value(){return this._||null}}class sL{constructor(){this._=[]}moveTo(t,n){this._.push([t,n])}closePath(){this._.push(this._[0].slice())}lineTo(t,n){this._.push([t,n])}value(){return this._.length?this._:null}}let fie=class{constructor(t,[n,i,s,o]=[0,0,960,500]){if(!((s=+s)>=(n=+n))||!((o=+o)>=(i=+i)))throw new Error("invalid bounds");this.delaunay=t,this._circumcenters=new Float64Array(t.points.length*2),this.vectors=new Float64Array(t.points.length*2),this.xmax=s,this.xmin=n,this.ymax=o,this.ymin=i,this._init()}update(){return this.delaunay.update(),this._init(),this}_init(){const{delaunay:{points:t,hull:n,triangles:i},vectors:s}=this,o=this.circumcenters=this._circumcenters.subarray(0,i.length/3*2);for(let p=0,l=0,b=i.length,L,E;p1;)o-=2;for(let c=2;c4)for(let c=0;c0){if(n>=this.ymax)return null;(c=(this.ymax-n)/s)0){if(t>=this.xmax)return null;(c=(this.xmax-t)/i)this.xmax?2:0)|(nthis.ymax?8:0)}};const uie=2*Math.PI,Ff=Math.pow;function hie(e){return e[0]}function gie(e){return e[1]}function _ie(e){const{triangles:t,coords:n}=e;for(let i=0;i1e-10)return!1}return!0}function pie(e,t,n){return[e+Math.sin(e+t)*n,t+Math.cos(e-t)*n]}class H7{static from(t,n=hie,i=gie,s){return new H7("length"in t?yie(t,n,i,s):Float64Array.from(mie(t,n,i,s)))}constructor(t){this._delaunator=new Rp(t),this.inedges=new Int32Array(t.length/2),this._hullIndex=new Int32Array(t.length/2),this.points=this._delaunator.coords,this._init()}update(){return this._delaunator.update(),this._init(),this}_init(){const t=this._delaunator,n=this.points;if(t.hull&&t.hull.length>2&&_ie(t)){this.collinear=Int32Array.from({length:n.length/2},(y,p)=>p).sort((y,p)=>n[2*y]-n[2*p]||n[2*y+1]-n[2*p+1]);const f=this.collinear[0],u=this.collinear[this.collinear.length-1],a=[n[2*f],n[2*f+1],n[2*u],n[2*u+1]],m=1e-8*Math.hypot(a[3]-a[1],a[2]-a[0]);for(let y=0,p=n.length/2;y0&&(this.triangles=new Int32Array(3).fill(-1),this.halfedges=new Int32Array(3).fill(-1),this.triangles[0]=s[0],c[s[0]]=1,s.length===2&&(c[s[1]]=0,this.triangles[1]=s[1],this.triangles[2]=s[1]))}voronoi(t){return new fie(this,t)}*neighbors(t){const{inedges:n,hull:i,_hullIndex:s,halfedges:o,triangles:c,collinear:d}=this;if(d){const m=d.indexOf(t);m>0&&(yield d[m-1]),m=0&&o!==i&&o!==s;)i=o;return o}_step(t,n,i){const{inedges:s,hull:o,_hullIndex:c,halfedges:d,triangles:f,points:u}=this;if(s[t]===-1||!u.length)return(t+1)%(u.length>>1);let a=t,m=Ff(n-u[t*2],2)+Ff(i-u[t*2+1],2);const y=s[t];let p=y;do{let l=f[p];const b=Ff(n-u[l*2],2)+Ff(i-u[l*2+1],2);if(b9999?"+"+Xi(e,6):Xi(e,4)}function bie(e){var t=e.getUTCHours(),n=e.getUTCMinutes(),i=e.getUTCSeconds(),s=e.getUTCMilliseconds();return isNaN(e)?"Invalid Date":Lie(e.getUTCFullYear())+"-"+Xi(e.getUTCMonth()+1,2)+"-"+Xi(e.getUTCDate(),2)+(s?"T"+Xi(t,2)+":"+Xi(n,2)+":"+Xi(i,2)+"."+Xi(s,3)+"Z":i?"T"+Xi(t,2)+":"+Xi(n,2)+":"+Xi(i,2)+"Z":n||t?"T"+Xi(t,2)+":"+Xi(n,2)+"Z":"")}function Tie(e){var t=new RegExp('["'+e+` \r]`),n=e.charCodeAt(0);function i(m,y){var p,l,b=s(m,function(L,E){if(p)return p(L,E-1);l=L,p=y?wie(L,y):FP(L)});return b.columns=l||[],b}function s(m,y){var p=[],l=m.length,b=0,L=0,E,S=l<=0,x=!1;m.charCodeAt(l-1)===Jh&&--l,m.charCodeAt(l-1)===aw&&--l;function F(){if(S)return sw;if(x)return x=!1,FB;var M,O=b,C;if(m.charCodeAt(O)===rw){for(;b++=l?S=!0:(C=m.charCodeAt(b++))===Jh?x=!0:C===aw&&(x=!0,m.charCodeAt(b)===Jh&&++b),m.slice(O+1,M-1).replace(/""/g,'"')}for(;b=(m=(d+u)/2))?d=m:u=m,(L=n>=(y=(f+a)/2))?f=y:a=y,s=o,!(o=o[E=L<<1|b]))return s[E]=c,e;if(p=+e._x.call(null,o.data),l=+e._y.call(null,o.data),t===p&&n===l)return c.next=o,s?s[E]=c:e._root=c,e;do s=s?s[E]=new Array(4):e._root=new Array(4),(b=t>=(m=(d+u)/2))?d=m:u=m,(L=n>=(y=(f+a)/2))?f=y:a=y;while((E=L<<1|b)===(S=(l>=y)<<1|p>=m));return s[S]=o,s[E]=c,e}function Sie(e){var t,n,i=e.length,s,o,c=new Array(i),d=new Array(i),f=1/0,u=1/0,a=-1/0,m=-1/0;for(n=0;na&&(a=s),om&&(m=o));if(f>a||u>m)return this;for(this.cover(f,u).cover(a,m),n=0;ne||e>=s||i>t||t>=o;)switch(u=(ta||(d=l.y0)>m||(f=l.x1)=E)<<1|e>=L)&&(l=y[y.length-1],y[y.length-1]=y[y.length-1-b],y[y.length-1-b]=l)}else{var S=e-+this._x.call(null,p.data),x=t-+this._y.call(null,p.data),F=S*S+x*x;if(F=(y=(c+f)/2))?c=y:f=y,(b=m>=(p=(d+u)/2))?d=p:u=p,t=n,!(n=n[L=b<<1|l]))return this;if(!n.length)break;(t[L+1&3]||t[L+2&3]||t[L+3&3])&&(i=t,E=L)}for(;n.data!==e;)if(s=n,!(n=n.next))return this;return(o=n.next)&&delete n.next,s?(o?s.next=o:delete s.next,this):t?(o?t[L]=o:delete t[L],(n=t[0]||t[1]||t[2]||t[3])&&n===(t[3]||t[2]||t[1]||t[0])&&!n.length&&(i?i[E]=n:this._root=n),this):(this._root=o,this)}function Oie(e){for(var t=0,n=e.length;ty.index){var R=p-C.x-C.vx,H=l-C.y-C.vy,z=R*R+H*H;zp+j||Ml+j||Ou.r&&(u.r=u[a].r)}function f(){if(t){var u,a=t.length,m;for(n=new Array(a),u=0;u[t(k,M,c),k])),F;for(L=0,d=new Array(E);L(e=(Vie*e+Gie)%AB)/AB}function Yie(e){return e.x}function Xie(e){return e.y}var Kie=10,Zie=Math.PI*(3-Math.sqrt(5));function Jie(e){var t,n=1,i=.001,s=1-Math.pow(i,1/300),o=0,c=.6,d=new Map,f=P7(m),u=B7("tick","end"),a=Wie();e==null&&(e=[]);function m(){y(),u.call("tick",t),n1?(L==null?d.delete(b):d.set(b,l(L)),t):d.get(b)},find:function(b,L,E){var S=0,x=e.length,F,k,M,O,C;for(E==null?E=1/0:E*=E,S=0;S1?(u.on(b,L),t):u.on(b)}}}function Qie(){var e,t,n,i,s=Di(-30),o,c=1,d=1/0,f=.81;function u(p){var l,b=e.length,L=z7(e,Yie,Xie).visitAfter(m);for(i=p,l=0;l=d)return;(p.data!==t||p.next)&&(E===0&&(E=Fl(n),F+=E*E),S===0&&(S=Fl(n),F+=S*S),F=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function Pp(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var n,i=e.slice(0,n);return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function Hu(e){return e=Pp(Math.abs(e)),e?e[1]:NaN}function ise(e,t){return function(n,i){for(var s=n.length,o=[],c=0,d=e[0],f=0;s>0&&d>0&&(f+d+1>i&&(d=Math.max(1,i-f)),o.push(n.substring(s-=d,s+d)),!((f+=d+1)>i));)d=e[c=(c+1)%e.length];return o.reverse().join(t)}}function sse(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var rse=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Pd(e){if(!(t=rse.exec(e)))throw new Error("invalid format: "+e);var t;return new q7({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Pd.prototype=q7.prototype;function q7(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}q7.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function ase(e){e:for(var t=e.length,n=1,i=-1,s;n0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(s+1):e}var OP;function ose(e,t){var n=Pp(e,t);if(!n)return e+"";var i=n[0],s=n[1],o=s-(OP=Math.max(-8,Math.min(8,Math.floor(s/3)))*3)+1,c=i.length;return o===c?i:o>c?i+new Array(o-c+1).join("0"):o>0?i.slice(0,o)+"."+i.slice(o):"0."+new Array(1-o).join("0")+Pp(e,Math.max(0,t+o-1))[0]}function NB(e,t){var n=Pp(e,t);if(!n)return e+"";var i=n[0],s=n[1];return s<0?"0."+new Array(-s).join("0")+i:i.length>s+1?i.slice(0,s+1)+"."+i.slice(s+1):i+new Array(s-i.length+2).join("0")}const CB={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:nse,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>NB(e*100,t),r:NB,s:ose,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function RB(e){return e}var PB=Array.prototype.map,DB=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function MP(e){var t=e.grouping===void 0||e.thousands===void 0?RB:ise(PB.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",s=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?RB:sse(PB.call(e.numerals,String)),c=e.percent===void 0?"%":e.percent+"",d=e.minus===void 0?"−":e.minus+"",f=e.nan===void 0?"NaN":e.nan+"";function u(m){m=Pd(m);var y=m.fill,p=m.align,l=m.sign,b=m.symbol,L=m.zero,E=m.width,S=m.comma,x=m.precision,F=m.trim,k=m.type;k==="n"?(S=!0,k="g"):CB[k]||(x===void 0&&(x=12),F=!0,k="g"),(L||y==="0"&&p==="=")&&(L=!0,y="0",p="=");var M=b==="$"?n:b==="#"&&/[boxX]/.test(k)?"0"+k.toLowerCase():"",O=b==="$"?i:/[%p]/.test(k)?c:"",C=CB[k],P=/[defgprs%]/.test(k);x=x===void 0?6:/[gprs]/.test(k)?Math.max(1,Math.min(21,x)):Math.max(0,Math.min(20,x));function j(R){var H=M,z=O,Y,$,W;if(k==="c")z=C(R)+z,R="";else{R=+R;var X=R<0||1/R<0;if(R=isNaN(R)?f:C(Math.abs(R),x),F&&(R=ase(R)),X&&+R==0&&l!=="+"&&(X=!1),H=(X?l==="("?l:d:l==="-"||l==="("?"":l)+H,z=(k==="s"?DB[8+OP/3]:"")+z+(X&&l==="("?")":""),P){for(Y=-1,$=R.length;++Y<$;)if(W=R.charCodeAt(Y),48>W||W>57){z=(W===46?s+R.slice(Y+1):R.slice(Y))+z,R=R.slice(0,Y);break}}}S&&!L&&(R=t(R,1/0));var G=H.length+R.length+z.length,oe=G>1)+H+R+z+oe.slice(G);break;default:R=oe+H+R+z;break}return o(R)}return j.toString=function(){return m+""},j}function a(m,y){var p=u((m=Pd(m),m.type="f",m)),l=Math.max(-8,Math.min(8,Math.floor(Hu(y)/3)))*3,b=Math.pow(10,-l),L=DB[8+l/3];return function(E){return p(b*E)+L}}return{format:u,formatPrefix:a}}var Pg,N4,V7;lse({thousands:",",grouping:[3],currency:["$",""]});function lse(e){return Pg=MP(e),N4=Pg.format,V7=Pg.formatPrefix,Pg}function AP(e){return Math.max(0,-Hu(Math.abs(e)))}function NP(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Hu(t)/3)))*3-Hu(Math.abs(e)))}function CP(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Hu(t)-Hu(e))+1}var He=1e-6,Dp=1e-12,Lt=Math.PI,yn=Lt/2,jp=Lt/4,Hi=Lt*2,wn=180/Lt,yt=Lt/180,xt=Math.abs,vh=Math.atan,nr=Math.atan2,ze=Math.cos,Dg=Math.ceil,RP=Math.exp,rL=Math.hypot,Up=Math.log,ow=Math.pow,Pe=Math.sin,Ws=Math.sign||function(e){return e>0?1:e<0?-1:0},zi=Math.sqrt,G7=Math.tan;function PP(e){return e>1?0:e<-1?Lt:Math.acos(e)}function us(e){return e>1?yn:e<-1?-yn:Math.asin(e)}function ni(){}function Hp(e,t){e&&UB.hasOwnProperty(e.type)&&UB[e.type](e,t)}var jB={Feature:function(e,t){Hp(e.geometry,t)},FeatureCollection:function(e,t){for(var n=e.features,i=-1,s=n.length;++i=0?1:-1,s=i*n,o=ze(t),c=Pe(t),d=cL*c,f=lL*o+d*ze(s),u=d*i*Pe(s);zp.add(nr(u,f)),oL=e,lL=o,cL=c}function use(e){return $p=new ji,xo(e,Pa),$p*2}function qp(e){return[nr(e[1],e[0]),us(e[2])]}function Dd(e){var t=e[0],n=e[1],i=ze(n);return[i*ze(t),i*Pe(t),Pe(n)]}function jg(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function zu(e,t){return[e[1]*t[2]-e[2]*t[1],e[2]*t[0]-e[0]*t[2],e[0]*t[1]-e[1]*t[0]]}function lw(e,t){e[0]+=t[0],e[1]+=t[1],e[2]+=t[2]}function Ug(e,t){return[e[0]*t,e[1]*t,e[2]*t]}function Vp(e){var t=zi(e[0]*e[0]+e[1]*e[1]+e[2]*e[2]);e[0]/=t,e[1]/=t,e[2]/=t}var fn,Qi,gn,Fs,ed,HP,zP,mu,Z1,bl,Vo,bo={point:dL,lineStart:zB,lineEnd:$B,polygonStart:function(){bo.point=qP,bo.lineStart=hse,bo.lineEnd=gse,Z1=new ji,Pa.polygonStart()},polygonEnd:function(){Pa.polygonEnd(),bo.point=dL,bo.lineStart=zB,bo.lineEnd=$B,zp<0?(fn=-(gn=180),Qi=-(Fs=90)):Z1>He?Fs=90:Z1<-He&&(Qi=-90),Vo[0]=fn,Vo[1]=gn},sphere:function(){fn=-(gn=180),Qi=-(Fs=90)}};function dL(e,t){bl.push(Vo=[fn=e,gn=e]),tFs&&(Fs=t)}function $P(e,t){var n=Dd([e*yt,t*yt]);if(mu){var i=zu(mu,n),s=[i[1],-i[0],0],o=zu(s,i);Vp(o),o=qp(o);var c=e-ed,d=c>0?1:-1,f=o[0]*wn*d,u,a=xt(c)>180;a^(d*edFs&&(Fs=u)):(f=(f+360)%360-180,a^(d*edFs&&(Fs=t))),a?exs(fn,gn)&&(gn=e):xs(e,gn)>xs(fn,gn)&&(fn=e):gn>=fn?(egn&&(gn=e)):e>ed?xs(fn,e)>xs(fn,gn)&&(gn=e):xs(e,gn)>xs(fn,gn)&&(fn=e)}else bl.push(Vo=[fn=e,gn=e]);tFs&&(Fs=t),mu=n,ed=e}function zB(){bo.point=$P}function $B(){Vo[0]=fn,Vo[1]=gn,bo.point=dL,mu=null}function qP(e,t){if(mu){var n=e-ed;Z1.add(xt(n)>180?n+(n>0?360:-360):n)}else HP=e,zP=t;Pa.point(e,t),$P(e,t)}function hse(){Pa.lineStart()}function gse(){qP(HP,zP),Pa.lineEnd(),xt(Z1)>He&&(fn=-(gn=180)),Vo[0]=fn,Vo[1]=gn,mu=null}function xs(e,t){return(t-=e)<0?t+360:t}function _se(e,t){return e[0]-t[0]}function qB(e,t){return e[0]<=e[1]?e[0]<=t&&t<=e[1]:txs(i[0],i[1])&&(i[1]=s[1]),xs(s[0],i[1])>xs(i[0],i[1])&&(i[0]=s[0])):o.push(i=s);for(c=-1/0,n=o.length-1,t=0,i=o[n];t<=n;i=s,++t)s=o[t],(d=xs(i[1],s[0]))>c&&(c=d,fn=s[0],gn=i[1])}return bl=Vo=null,fn===1/0||Qi===1/0?[[NaN,NaN],[NaN,NaN]]:[[fn,Qi],[gn,Fs]]}var k1,Gp,Wp,Yp,Xp,Kp,Zp,Jp,fL,uL,hL,VP,GP,Ai,Ni,Ci,Or={sphere:ni,point:W7,lineStart:VB,lineEnd:GB,polygonStart:function(){Or.lineStart=wse,Or.lineEnd=Lse},polygonEnd:function(){Or.lineStart=VB,Or.lineEnd=GB}};function W7(e,t){e*=yt,t*=yt;var n=ze(t);S0(n*ze(e),n*Pe(e),Pe(t))}function S0(e,t,n){++k1,Wp+=(e-Wp)/k1,Yp+=(t-Yp)/k1,Xp+=(n-Xp)/k1}function VB(){Or.point=yse}function yse(e,t){e*=yt,t*=yt;var n=ze(t);Ai=n*ze(e),Ni=n*Pe(e),Ci=Pe(t),Or.point=mse,S0(Ai,Ni,Ci)}function mse(e,t){e*=yt,t*=yt;var n=ze(t),i=n*ze(e),s=n*Pe(e),o=Pe(t),c=nr(zi((c=Ni*o-Ci*s)*c+(c=Ci*i-Ai*o)*c+(c=Ai*s-Ni*i)*c),Ai*i+Ni*s+Ci*o);Gp+=c,Kp+=c*(Ai+(Ai=i)),Zp+=c*(Ni+(Ni=s)),Jp+=c*(Ci+(Ci=o)),S0(Ai,Ni,Ci)}function GB(){Or.point=W7}function wse(){Or.point=bse}function Lse(){WP(VP,GP),Or.point=W7}function bse(e,t){VP=e,GP=t,e*=yt,t*=yt,Or.point=WP;var n=ze(t);Ai=n*ze(e),Ni=n*Pe(e),Ci=Pe(t),S0(Ai,Ni,Ci)}function WP(e,t){e*=yt,t*=yt;var n=ze(t),i=n*ze(e),s=n*Pe(e),o=Pe(t),c=Ni*o-Ci*s,d=Ci*i-Ai*o,f=Ai*s-Ni*i,u=rL(c,d,f),a=us(u),m=u&&-a/u;fL.add(m*c),uL.add(m*d),hL.add(m*f),Gp+=a,Kp+=a*(Ai+(Ai=i)),Zp+=a*(Ni+(Ni=s)),Jp+=a*(Ci+(Ci=o)),S0(Ai,Ni,Ci)}function Tse(e){k1=Gp=Wp=Yp=Xp=Kp=Zp=Jp=0,fL=new ji,uL=new ji,hL=new ji,xo(e,Or);var t=+fL,n=+uL,i=+hL,s=rL(t,n,i);return sLt&&(e-=Math.round(e/Hi)*Hi),[e,t]}_L.invert=_L;function YP(e,t,n){return(e%=Hi)?t||n?gL(YB(e),XB(t,n)):YB(e):t||n?XB(t,n):_L}function WB(e){return function(t,n){return t+=e,xt(t)>Lt&&(t-=Math.round(t/Hi)*Hi),[t,n]}}function YB(e){var t=WB(e);return t.invert=WB(-e),t}function XB(e,t){var n=ze(e),i=Pe(e),s=ze(t),o=Pe(t);function c(d,f){var u=ze(f),a=ze(d)*u,m=Pe(d)*u,y=Pe(f),p=y*n+a*i;return[nr(m*s-p*o,a*n-y*i),us(p*s+m*o)]}return c.invert=function(d,f){var u=ze(f),a=ze(d)*u,m=Pe(d)*u,y=Pe(f),p=y*s-m*o;return[nr(m*s+y*o,a*n+p*i),us(p*n-a*i)]},c}function vse(e){e=YP(e[0]*yt,e[1]*yt,e.length>2?e[2]*yt:0);function t(n){return n=e(n[0]*yt,n[1]*yt),n[0]*=wn,n[1]*=wn,n}return t.invert=function(n){return n=e.invert(n[0]*yt,n[1]*yt),n[0]*=wn,n[1]*=wn,n},t}function Ese(e,t,n,i,s,o){if(n){var c=ze(t),d=Pe(t),f=i*n;s==null?(s=t+i*Hi,o=t-f/2):(s=KB(c,s),o=KB(c,o),(i>0?so)&&(s+=i*Hi));for(var u,a=s;i>0?a>o:a1&&e.push(e.pop().concat(e.shift()))},result:function(){var n=e;return e=[],t=null,n}}}function D_(e,t){return xt(e[0]-t[0])=0;--d)s.point((m=a[d])[0],m[1]);else i(y.x,y.p.x,-1,s);y=y.p}y=y.o,a=y.z,p=!p}while(!y.v);s.lineEnd()}}}function ZB(e){if(t=e.length){for(var t,n=0,i=e[0],s;++n=0?1:-1,j=P*C,R=j>Lt,H=L*M;if(f.add(nr(H*P*Pe(j),E*O+H*ze(j))),c+=R?C+P*Hi:C,R^l>=n^F>=n){var z=zu(Dd(p),Dd(x));Vp(z);var Y=zu(o,z);Vp(Y);var $=(R^C>=0?-1:1)*us(Y[2]);(i>$||i===$&&(z[0]||z[1]))&&(d+=R^C>=0?1:-1)}}return(c<-He||c0){for(f||(s.polygonStart(),f=!0),s.lineStart(),M=0;M1&&F&2&&k.push(k.pop().concat(k.shift())),a.push(k.filter(xse))}}return y}}function xse(e){return e.length>1}function kse(e,t){return((e=e.x)[0]<0?e[1]-yn-He:yn-e[1])-((t=t.x)[0]<0?t[1]-yn-He:yn-t[1])}const JB=ZP(function(){return!0},Bse,Ise,[-Lt,-yn]);function Bse(e){var t=NaN,n=NaN,i=NaN,s;return{lineStart:function(){e.lineStart(),s=1},point:function(o,c){var d=o>0?Lt:-Lt,f=xt(o-t);xt(f-Lt)0?yn:-yn),e.point(i,n),e.lineEnd(),e.lineStart(),e.point(d,n),e.point(o,n),s=0):i!==d&&f>=Lt&&(xt(t-i)He?vh((Pe(t)*(o=ze(i))*Pe(n)-Pe(i)*(s=ze(t))*Pe(e))/(s*o*c)):(t+i)/2}function Ise(e,t,n,i){var s;if(e==null)s=n*yn,i.point(-Lt,s),i.point(0,s),i.point(Lt,s),i.point(Lt,0),i.point(Lt,-s),i.point(0,-s),i.point(-Lt,-s),i.point(-Lt,0),i.point(-Lt,s);else if(xt(e[0]-t[0])>He){var o=e[0]0,s=xt(t)>He;function o(a,m,y,p){Ese(p,e,n,y,a,m)}function c(a,m){return ze(a)*ze(m)>t}function d(a){var m,y,p,l,b;return{lineStart:function(){l=p=!1,b=1},point:function(L,E){var S=[L,E],x,F=c(L,E),k=i?F?0:u(L,E):F?u(L+(L<0?Lt:-Lt),E):0;if(!m&&(l=p=F)&&a.lineStart(),F!==p&&(x=f(m,S),(!x||D_(m,x)||D_(S,x))&&(S[2]=1)),F!==p)b=0,F?(a.lineStart(),x=f(S,m),a.point(x[0],x[1])):(x=f(m,S),a.point(x[0],x[1],2),a.lineEnd()),m=x;else if(s&&m&&i^F){var M;!(k&y)&&(M=f(S,m,!0))&&(b=0,i?(a.lineStart(),a.point(M[0][0],M[0][1]),a.point(M[1][0],M[1][1]),a.lineEnd()):(a.point(M[1][0],M[1][1]),a.lineEnd(),a.lineStart(),a.point(M[0][0],M[0][1],3)))}F&&(!m||!D_(m,S))&&a.point(S[0],S[1]),m=S,p=F,y=k},lineEnd:function(){p&&a.lineEnd(),m=null},clean:function(){return b|(l&&p)<<1}}}function f(a,m,y){var p=Dd(a),l=Dd(m),b=[1,0,0],L=zu(p,l),E=jg(L,L),S=L[0],x=E-S*S;if(!x)return!y&&a;var F=t*E/x,k=-t*S/x,M=zu(b,L),O=Ug(b,F),C=Ug(L,k);lw(O,C);var P=M,j=jg(O,P),R=jg(P,P),H=j*j-R*(jg(O,O)-1);if(!(H<0)){var z=zi(H),Y=Ug(P,(-j-z)/R);if(lw(Y,O),Y=qp(Y),!y)return Y;var $=a[0],W=m[0],X=a[1],G=m[1],oe;W<$&&(oe=$,$=W,W=oe);var he=W-$,ie=xt(he-Lt)0^Y[1]<(xt(Y[0]-$)Lt^($<=Y[0]&&Y[0]<=W)){var de=Ug(P,(-j+z)/R);return lw(de,O),[Y,qp(de)]}}}function u(a,m){var y=i?e:Lt-e,p=0;return a<-y?p|=1:a>y&&(p|=2),m<-y?p|=4:m>y&&(p|=8),p}return ZP(c,d,o,i?[0,-e]:[-Lt,e-Lt])}function Mse(e,t,n,i,s,o){var c=e[0],d=e[1],f=t[0],u=t[1],a=0,m=1,y=f-c,p=u-d,l;if(l=n-c,!(!y&&l>0)){if(l/=y,y<0){if(l0){if(l>m)return;l>a&&(a=l)}if(l=s-c,!(!y&&l<0)){if(l/=y,y<0){if(l>m)return;l>a&&(a=l)}else if(y>0){if(l0)){if(l/=p,p<0){if(l0){if(l>m)return;l>a&&(a=l)}if(l=o-d,!(!p&&l<0)){if(l/=p,p<0){if(l>m)return;l>a&&(a=l)}else if(p>0){if(l0&&(e[0]=c+a*y,e[1]=d+a*p),m<1&&(t[0]=c+m*y,t[1]=d+m*p),!0}}}}}var B1=1e9,zg=-B1;function JP(e,t,n,i){function s(u,a){return e<=u&&u<=n&&t<=a&&a<=i}function o(u,a,m,y){var p=0,l=0;if(u==null||(p=c(u,m))!==(l=c(a,m))||f(u,a)<0^m>0)do y.point(p===0||p===3?e:n,p>1?i:t);while((p=(p+m+4)%4)!==l);else y.point(a[0],a[1])}function c(u,a){return xt(u[0]-e)0?0:3:xt(u[0]-n)0?2:1:xt(u[1]-t)0?1:0:a>0?3:2}function d(u,a){return f(u.x,a.x)}function f(u,a){var m=c(u,1),y=c(a,1);return m!==y?m-y:m===0?a[1]-u[1]:m===1?u[0]-a[0]:m===2?u[1]-a[1]:a[0]-u[0]}return function(u){var a=u,m=XP(),y,p,l,b,L,E,S,x,F,k,M,O={point:C,lineStart:H,lineEnd:z,polygonStart:j,polygonEnd:R};function C($,W){s($,W)&&a.point($,W)}function P(){for(var $=0,W=0,X=p.length;Wi&&(Me-Oe)*(i-de)>(Fe-de)*(e-Oe)&&++$:Fe<=i&&(Me-Oe)*(i-de)<(Fe-de)*(e-Oe)&&--$;return $}function j(){a=m,y=[],p=[],M=!0}function R(){var $=P(),W=M&&$,X=(y=NR(y)).length;(W||X)&&(u.polygonStart(),W&&(u.lineStart(),o(null,null,1,u),u.lineEnd()),X&&KP(y,d,$,o,u),u.polygonEnd()),a=u,y=p=l=null}function H(){O.point=Y,p&&p.push(l=[]),k=!0,F=!1,S=x=NaN}function z(){y&&(Y(b,L),E&&F&&m.rejoin(),y.push(m.result())),O.point=C,F&&a.lineEnd()}function Y($,W){var X=s($,W);if(p&&l.push([$,W]),k)b=$,L=W,E=X,k=!1,X&&(a.lineStart(),a.point($,W));else if(X&&F)a.point($,W);else{var G=[S=Math.max(zg,Math.min(B1,S)),x=Math.max(zg,Math.min(B1,x))],oe=[$=Math.max(zg,Math.min(B1,$)),W=Math.max(zg,Math.min(B1,W))];Mse(G,oe,e,t,n,i)?(F||(a.lineStart(),a.point(G[0],G[1])),a.point(oe[0],oe[1]),X||a.lineEnd(),M=!1):X&&(a.lineStart(),a.point($,W),M=!1)}S=$,x=W,F=X}return O}}function QB(e,t,n){var i=Os(e,t-He,n).concat(t);return function(s){return i.map(function(o){return[s,o]})}}function eF(e,t,n){var i=Os(e,t-He,n).concat(t);return function(s){return i.map(function(o){return[o,s]})}}function Ase(){var e,t,n,i,s,o,c,d,f=10,u=f,a=90,m=360,y,p,l,b,L=2.5;function E(){return{type:"MultiLineString",coordinates:S()}}function S(){return Os(Dg(i/a)*a,n,a).map(l).concat(Os(Dg(d/m)*m,c,m).map(b)).concat(Os(Dg(t/f)*f,e,f).filter(function(x){return xt(x%a)>He}).map(y)).concat(Os(Dg(o/u)*u,s,u).filter(function(x){return xt(x%m)>He}).map(p))}return E.lines=function(){return S().map(function(x){return{type:"LineString",coordinates:x}})},E.outline=function(){return{type:"Polygon",coordinates:[l(i).concat(b(c).slice(1),l(n).reverse().slice(1),b(d).reverse().slice(1))]}},E.extent=function(x){return arguments.length?E.extentMajor(x).extentMinor(x):E.extentMinor()},E.extentMajor=function(x){return arguments.length?(i=+x[0][0],n=+x[1][0],d=+x[0][1],c=+x[1][1],i>n&&(x=i,i=n,n=x),d>c&&(x=d,d=c,c=x),E.precision(L)):[[i,d],[n,c]]},E.extentMinor=function(x){return arguments.length?(t=+x[0][0],e=+x[1][0],o=+x[0][1],s=+x[1][1],t>e&&(x=t,t=e,e=x),o>s&&(x=o,o=s,s=x),E.precision(L)):[[t,o],[e,s]]},E.step=function(x){return arguments.length?E.stepMajor(x).stepMinor(x):E.stepMinor()},E.stepMajor=function(x){return arguments.length?(a=+x[0],m=+x[1],E):[a,m]},E.stepMinor=function(x){return arguments.length?(f=+x[0],u=+x[1],E):[f,u]},E.precision=function(x){return arguments.length?(L=+x,y=QB(o,s,90),p=eF(t,e,L),l=QB(d,c,90),b=eF(i,n,L),E):L},E.extentMajor([[-180,-90+He],[180,90-He]]).extentMinor([[-180,-80-He],[180,80+He]])}const O2=e=>e;var dw=new ji,pL=new ji,QP,eD,yL,mL,kl={point:ni,lineStart:ni,lineEnd:ni,polygonStart:function(){kl.lineStart=Nse,kl.lineEnd=Rse},polygonEnd:function(){kl.lineStart=kl.lineEnd=kl.point=ni,dw.add(xt(pL)),pL=new ji},result:function(){var e=dw/2;return dw=new ji,e}};function Nse(){kl.point=Cse}function Cse(e,t){kl.point=tD,QP=yL=e,eD=mL=t}function tD(e,t){pL.add(mL*e-yL*t),yL=e,mL=t}function Rse(){tD(QP,eD)}const tF=kl;var $u=1/0,Qp=$u,M2=-$u,ey=M2,Pse={point:Dse,lineStart:ni,lineEnd:ni,polygonStart:ni,polygonEnd:ni,result:function(){var e=[[$u,Qp],[M2,ey]];return M2=ey=-(Qp=$u=1/0),e}};function Dse(e,t){e<$u&&($u=e),e>M2&&(M2=e),tey&&(ey=t)}const ty=Pse;var wL=0,LL=0,F1=0,ny=0,iy=0,iu=0,bL=0,TL=0,I1=0,nD,iD,pa,ya,Sr={point:jd,lineStart:nF,lineEnd:iF,polygonStart:function(){Sr.lineStart=Hse,Sr.lineEnd=zse},polygonEnd:function(){Sr.point=jd,Sr.lineStart=nF,Sr.lineEnd=iF},result:function(){var e=I1?[bL/I1,TL/I1]:iu?[ny/iu,iy/iu]:F1?[wL/F1,LL/F1]:[NaN,NaN];return wL=LL=F1=ny=iy=iu=bL=TL=I1=0,e}};function jd(e,t){wL+=e,LL+=t,++F1}function nF(){Sr.point=jse}function jse(e,t){Sr.point=Use,jd(pa=e,ya=t)}function Use(e,t){var n=e-pa,i=t-ya,s=zi(n*n+i*i);ny+=s*(pa+e)/2,iy+=s*(ya+t)/2,iu+=s,jd(pa=e,ya=t)}function iF(){Sr.point=jd}function Hse(){Sr.point=$se}function zse(){sD(nD,iD)}function $se(e,t){Sr.point=sD,jd(nD=pa=e,iD=ya=t)}function sD(e,t){var n=e-pa,i=t-ya,s=zi(n*n+i*i);ny+=s*(pa+e)/2,iy+=s*(ya+t)/2,iu+=s,s=ya*e-pa*t,bL+=s*(pa+e),TL+=s*(ya+t),I1+=s*3,jd(pa=e,ya=t)}const sF=Sr;function rD(e){this._context=e}rD.prototype={_radius:4.5,pointRadius:function(e){return this._radius=e,this},polygonStart:function(){this._line=0},polygonEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){this._line===0&&this._context.closePath(),this._point=NaN},point:function(e,t){switch(this._point){case 0:{this._context.moveTo(e,t),this._point=1;break}case 1:{this._context.lineTo(e,t);break}default:{this._context.moveTo(e+this._radius,t),this._context.arc(e,t,this._radius,0,Hi);break}}},result:ni};var vL=new ji,fw,aD,oD,O1,M1,sy={point:ni,lineStart:function(){sy.point=qse},lineEnd:function(){fw&&lD(aD,oD),sy.point=ni},polygonStart:function(){fw=!0},polygonEnd:function(){fw=null},result:function(){var e=+vL;return vL=new ji,e}};function qse(e,t){sy.point=lD,aD=O1=e,oD=M1=t}function lD(e,t){O1-=e,M1-=t,vL.add(zi(O1*O1+M1*M1)),O1=e,M1=t}const rF=sy;let aF,ry,oF,lF;class cF{constructor(t){this._append=t==null?cD:Vse(t),this._radius=4.5,this._=""}pointRadius(t){return this._radius=+t,this}polygonStart(){this._line=0}polygonEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){this._line===0&&(this._+="Z"),this._point=NaN}point(t,n){switch(this._point){case 0:{this._append`M${t},${n}`,this._point=1;break}case 1:{this._append`L${t},${n}`;break}default:{if(this._append`M${t},${n}`,this._radius!==oF||this._append!==ry){const i=this._radius,s=this._;this._="",this._append`m0,${i}a${i},${i} 0 1,1 0,${-2*i}a${i},${i} 0 1,1 0,${2*i}z`,oF=i,ry=this._append,lF=this._,this._=s}this._+=lF;break}}}result(){const t=this._;return this._="",t.length?t:null}}function cD(e){let t=1;this._+=e[0];for(const n=e.length;t=0))throw new RangeError(`invalid digits: ${e}`);if(t>15)return cD;if(t!==aF){const n=10**t;aF=t,ry=function(s){let o=1;this._+=s[0];for(const c=s.length;o=0))throw new RangeError(`invalid digits: ${d}`);n=f}return t===null&&(o=new cF(n)),c},c.projection(e).digits(n).context(t)}function C4(e){return function(t){var n=new EL;for(var i in e)n[i]=e[i];return n.stream=t,n}}function EL(){}EL.prototype={constructor:EL,point:function(e,t){this.stream.point(e,t)},sphere:function(){this.stream.sphere()},lineStart:function(){this.stream.lineStart()},lineEnd:function(){this.stream.lineEnd()},polygonStart:function(){this.stream.polygonStart()},polygonEnd:function(){this.stream.polygonEnd()}};function Y7(e,t,n){var i=e.clipExtent&&e.clipExtent();return e.scale(150).translate([0,0]),i!=null&&e.clipExtent(null),xo(n,e.stream(ty)),t(ty.result()),i!=null&&e.clipExtent(i),e}function R4(e,t,n){return Y7(e,function(i){var s=t[1][0]-t[0][0],o=t[1][1]-t[0][1],c=Math.min(s/(i[1][0]-i[0][0]),o/(i[1][1]-i[0][1])),d=+t[0][0]+(s-c*(i[1][0]+i[0][0]))/2,f=+t[0][1]+(o-c*(i[1][1]+i[0][1]))/2;e.scale(150*c).translate([d,f])},n)}function X7(e,t,n){return R4(e,[[0,0],t],n)}function K7(e,t,n){return Y7(e,function(i){var s=+t,o=s/(i[1][0]-i[0][0]),c=(s-o*(i[1][0]+i[0][0]))/2,d=-o*i[0][1];e.scale(150*o).translate([c,d])},n)}function Z7(e,t,n){return Y7(e,function(i){var s=+t,o=s/(i[1][1]-i[0][1]),c=-o*i[0][0],d=(s-o*(i[1][1]+i[0][1]))/2;e.scale(150*o).translate([c,d])},n)}var dF=16,Gse=ze(30*yt);function fF(e,t){return+t?Yse(e,t):Wse(e)}function Wse(e){return C4({point:function(t,n){t=e(t,n),this.stream.point(t[0],t[1])}})}function Yse(e,t){function n(i,s,o,c,d,f,u,a,m,y,p,l,b,L){var E=u-i,S=a-s,x=E*E+S*S;if(x>4*t&&b--){var F=c+y,k=d+p,M=f+l,O=zi(F*F+k*k+M*M),C=us(M/=O),P=xt(xt(M)-1)t||xt((E*z+S*Y)/x-.5)>.3||c*y+d*p+f*l2?$[2]%360*yt:0,z()):[d*wn,f*wn,u*wn]},R.angle=function($){return arguments.length?(m=$%360*yt,z()):m*wn},R.reflectX=function($){return arguments.length?(y=$?-1:1,z()):y<0},R.reflectY=function($){return arguments.length?(p=$?-1:1,z()):p<0},R.precision=function($){return arguments.length?(M=fF(O,k=$*$),Y()):zi(k)},R.fitExtent=function($,W){return R4(R,$,W)},R.fitSize=function($,W){return X7(R,$,W)},R.fitWidth=function($,W){return K7(R,$,W)},R.fitHeight=function($,W){return Z7(R,$,W)};function z(){var $=uF(n,0,0,y,p,m).apply(null,t(o,c)),W=uF(n,i-$[0],s-$[1],y,p,m);return a=YP(d,f,u),O=gL(t,W),C=gL(a,O),M=fF(O,k),Y()}function Y(){return P=j=null,R}return function(){return t=e.apply(this,arguments),R.invert=t.invert&&H,z()}}function J7(e){var t=0,n=Lt/3,i=fD(e),s=i(t,n);return s.parallels=function(o){return arguments.length?i(t=o[0]*yt,n=o[1]*yt):[t*wn,n*wn]},s}function Jse(e){var t=ze(e);function n(i,s){return[i*t,Pe(s)/t]}return n.invert=function(i,s){return[i/t,us(s*t)]},n}function Qse(e,t){var n=Pe(e),i=(n+Pe(t))/2;if(xt(i)=.12&&L<.234&&b>=-.425&&b<-.214?s:L>=.166&&L<.234&&b>=-.214&&b<-.115?c:n).invert(y)},a.stream=function(y){return e&&t===y?e:e=ere([n.stream(t=y),s.stream(y),c.stream(y)])},a.precision=function(y){return arguments.length?(n.precision(y),s.precision(y),c.precision(y),m()):n.precision()},a.scale=function(y){return arguments.length?(n.scale(y),s.scale(y*.35),c.scale(y),a.translate(n.translate())):n.scale()},a.translate=function(y){if(!arguments.length)return n.translate();var p=n.scale(),l=+y[0],b=+y[1];return i=n.translate(y).clipExtent([[l-.455*p,b-.238*p],[l+.455*p,b+.238*p]]).stream(u),o=s.translate([l-.307*p,b+.201*p]).clipExtent([[l-.425*p+He,b+.12*p+He],[l-.214*p-He,b+.234*p-He]]).stream(u),d=c.translate([l-.205*p,b+.212*p]).clipExtent([[l-.214*p+He,b+.166*p+He],[l-.115*p-He,b+.234*p-He]]).stream(u),m()},a.fitExtent=function(y,p){return R4(a,y,p)},a.fitSize=function(y,p){return X7(a,y,p)},a.fitWidth=function(y,p){return K7(a,y,p)},a.fitHeight=function(y,p){return Z7(a,y,p)};function m(){return e=t=null,a}return a.scale(1070)}function hD(e){return function(t,n){var i=ze(t),s=ze(n),o=e(i*s);return o===1/0?[2,0]:[o*s*Pe(t),o*Pe(n)]}}function x0(e){return function(t,n){var i=zi(t*t+n*n),s=e(i),o=Pe(s),c=ze(s);return[nr(t*o,i*c),us(i&&n*o/i)]}}var gD=hD(function(e){return zi(2/(1+e))});gD.invert=x0(function(e){return 2*us(e/2)});function nre(){return Ka(gD).scale(124.75).clipAngle(180-.001)}var _D=hD(function(e){return(e=PP(e))&&e/Pe(e)});_D.invert=x0(function(e){return e});function ire(){return Ka(_D).scale(79.4188).clipAngle(180-.001)}function P4(e,t){return[e,Up(G7((yn+t)/2))]}P4.invert=function(e,t){return[e,2*vh(RP(t))-yn]};function sre(){return pD(P4).scale(961/Hi)}function pD(e){var t=Ka(e),n=t.center,i=t.scale,s=t.translate,o=t.clipExtent,c=null,d,f,u;t.scale=function(m){return arguments.length?(i(m),a()):i()},t.translate=function(m){return arguments.length?(s(m),a()):s()},t.center=function(m){return arguments.length?(n(m),a()):n()},t.clipExtent=function(m){return arguments.length?(m==null?c=d=f=u=null:(c=+m[0][0],d=+m[0][1],f=+m[1][0],u=+m[1][1]),a()):c==null?null:[[c,d],[f,u]]};function a(){var m=Lt*i(),y=t(vse(t.rotate()).invert([0,0]));return o(c==null?[[y[0]-m,y[1]-m],[y[0]+m,y[1]+m]]:e===P4?[[Math.max(y[0]-m,c),d],[Math.min(y[0]+m,f),u]]:[[c,Math.max(y[1]-m,d)],[f,Math.min(y[1]+m,u)]])}return a()}function $g(e){return G7((yn+e)/2)}function rre(e,t){var n=ze(e),i=e===t?Pe(e):Up(n/ze(t))/Up($g(t)/$g(e)),s=n*ow($g(e),i)/i;if(!i)return P4;function o(c,d){s>0?d<-yn+He&&(d=-yn+He):d>yn-He&&(d=yn-He);var f=s/ow($g(d),i);return[f*Pe(i*c),s-f*ze(i*c)]}return o.invert=function(c,d){var f=s-d,u=Ws(i)*zi(c*c+f*f),a=nr(c,xt(f))*Ws(f);return f*i<0&&(a-=Lt*Ws(c)*Ws(f)),[a/i,2*vh(ow(s/u,1/i))-yn]},o}function are(){return J7(rre).scale(109.5).parallels([30,30])}function oy(e,t){return[e,t]}oy.invert=oy;function ore(){return Ka(oy).scale(152.63)}function lre(e,t){var n=ze(e),i=e===t?Pe(e):(n-ze(t))/(t-e),s=n/i+e;if(xt(i)He&&--i>0);return[e/(.8707+(o=n*n)*(-.131979+o*(-.013791+o*o*o*(.003971-.001529*o)))),n]};function gre(){return Ka(wD).scale(175.295)}function LD(e,t){return[ze(t)*Pe(e),Pe(t)]}LD.invert=x0(us);function _re(){return Ka(LD).scale(249.5).clipAngle(90+He)}function bD(e,t){var n=ze(t),i=1+ze(e)*n;return[n*Pe(e)/i,Pe(t)/i]}bD.invert=x0(function(e){return 2*vh(e)});function pre(){return Ka(bD).scale(250).clipAngle(142)}function TD(e,t){return[Up(G7((yn+t)/2)),-e]}TD.invert=function(e,t){return[-t,2*vh(RP(e))-yn]};function yre(){var e=pD(TD),t=e.center,n=e.rotate;return e.center=function(i){return arguments.length?t([-i[1],i[0]]):(i=t(),[i[1],-i[0]])},e.rotate=function(i){return arguments.length?n([i[0],i[1],i.length>2?i[2]+90:90]):(i=n(),[i[0],i[1],i[2]-90])},n([0,0,90]).scale(159.155)}function mre(e,t){return e.parent===t.parent?1:2}function wre(e){return e.reduce(Lre,0)/e.length}function Lre(e,t){return e+t.x}function bre(e){return 1+e.reduce(Tre,0)}function Tre(e,t){return Math.max(e,t.y)}function vre(e){for(var t;t=e.children;)e=t[0];return e}function Ere(e){for(var t;t=e.children;)e=t[t.length-1];return e}function Sre(){var e=mre,t=1,n=1,i=!1;function s(o){var c,d=0;o.eachAfter(function(y){var p=y.children;p?(y.x=wre(p),y.y=bre(p)):(y.x=c?d+=e(y,c):0,y.y=0,c=y)});var f=vre(o),u=Ere(o),a=f.x-e(f,u)/2,m=u.x+e(u,f)/2;return o.eachAfter(i?function(y){y.x=(y.x-o.x)*t,y.y=(o.y-y.y)*n}:function(y){y.x=(y.x-a)/(m-a)*t,y.y=(1-(o.y?y.y/o.y:1))*n})}return s.separation=function(o){return arguments.length?(e=o,s):e},s.size=function(o){return arguments.length?(i=!1,t=+o[0],n=+o[1],s):i?null:[t,n]},s.nodeSize=function(o){return arguments.length?(i=!0,t=+o[0],n=+o[1],s):i?[t,n]:null},s}function xre(e){var t=0,n=e.children,i=n&&n.length;if(!i)t=1;else for(;--i>=0;)t+=n[i].value;e.value=t}function kre(){return this.eachAfter(xre)}function Bre(e,t){let n=-1;for(const i of this)e.call(t,i,++n,this);return this}function Fre(e,t){for(var n=this,i=[n],s,o,c=-1;n=i.pop();)if(e.call(t,n,++c,this),s=n.children)for(o=s.length-1;o>=0;--o)i.push(s[o]);return this}function Ire(e,t){for(var n=this,i=[n],s=[],o,c,d,f=-1;n=i.pop();)if(s.push(n),o=n.children)for(c=0,d=o.length;c=0;)n+=i[s].value;t.value=n})}function Are(e){return this.eachBefore(function(t){t.children&&t.children.sort(e)})}function Nre(e){for(var t=this,n=Cre(t,e),i=[t];t!==n;)t=t.parent,i.push(t);for(var s=i.length;e!==n;)i.splice(s,0,e),e=e.parent;return i}function Cre(e,t){if(e===t)return e;var n=e.ancestors(),i=t.ancestors(),s=null;for(e=n.pop(),t=i.pop();e===t;)s=e,e=n.pop(),t=i.pop();return s}function Rre(){for(var e=this,t=[e];e=e.parent;)t.push(e);return t}function Pre(){return Array.from(this)}function Dre(){var e=[];return this.eachBefore(function(t){t.children||e.push(t)}),e}function jre(){var e=this,t=[];return e.each(function(n){n!==e&&t.push({source:n.parent,target:n})}),t}function*Ure(){var e=this,t,n=[e],i,s,o;do for(t=n.reverse(),n=[];e=t.pop();)if(yield e,i=e.children)for(s=0,o=i.length;s=0;--d)s.push(o=c[d]=new qu(c[d])),o.parent=i,o.depth=i.depth+1;return n.eachBefore(vD)}function Hre(){return Q7(this).eachBefore(qre)}function zre(e){return e.children}function $re(e){return Array.isArray(e)?e[1]:null}function qre(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function vD(e){var t=0;do e.height=t;while((e=e.parent)&&e.height<++t)}function qu(e){this.data=e,this.depth=this.height=0,this.parent=null}qu.prototype=Q7.prototype={constructor:qu,count:kre,each:Bre,eachAfter:Ire,eachBefore:Fre,find:Ore,sum:Mre,sort:Are,path:Nre,ancestors:Rre,descendants:Pre,leaves:Dre,links:jre,copy:Hre,[Symbol.iterator]:Ure};function j_(e){return e==null?null:ED(e)}function ED(e){if(typeof e!="function")throw new Error;return e}function nd(){return 0}function Qf(e){return function(){return e}}const Vre=1664525,Gre=1013904223,hF=4294967296;function Wre(){let e=1;return()=>(e=(Vre*e+Gre)%hF)/hF}function Yre(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Xre(e,t){let n=e.length,i,s;for(;n;)s=t()*n--|0,i=e[n],e[n]=e[s],e[s]=i;return e}function Kre(e,t){for(var n=0,i=(e=Xre(Array.from(e),t)).length,s=[],o,c;n0&&n*n>i*i+s*s}function uw(e,t){for(var n=0;n1e-6?(R+Math.sqrt(R*R-4*j*H))/(2*j):H/R);return{x:i+M+O*z,y:s+C+P*z,r:z}}function gF(e,t,n){var i=e.x-t.x,s,o,c=e.y-t.y,d,f,u=i*i+c*c;u?(o=t.r+n.r,o*=o,f=e.r+n.r,f*=f,o>f?(s=(u+f-o)/(2*u),d=Math.sqrt(Math.max(0,f/u-s*s)),n.x=e.x-s*i-d*c,n.y=e.y-s*c+d*i):(s=(u+o-f)/(2*u),d=Math.sqrt(Math.max(0,o/u-s*s)),n.x=t.x+s*i-d*c,n.y=t.y+s*c+d*i)):(n.x=t.x+n.r,n.y=t.y)}function _F(e,t){var n=e.r+t.r-1e-6,i=t.x-e.x,s=t.y-e.y;return n>0&&n*n>i*i+s*s}function pF(e){var t=e._,n=e.next._,i=t.r+n.r,s=(t.x*n.r+n.x*t.r)/i,o=(t.y*n.r+n.y*t.r)/i;return s*s+o*o}function Vg(e){this._=e,this.next=null,this.previous=null}function eae(e,t){if(!(o=(e=Yre(e)).length))return 0;var n,i,s,o,c,d,f,u,a,m,y;if(n=e[0],n.x=0,n.y=0,!(o>1))return n.r;if(i=e[1],n.x=-i.r,i.x=n.r,i.y=0,!(o>2))return n.r+i.r;gF(i,n,s=e[2]),n=new Vg(n),i=new Vg(i),s=new Vg(s),n.next=s.previous=i,i.next=n.previous=s,s.next=i.previous=n;e:for(f=3;foae(n(F,k,s))),S=E.map(bF),x=new Set(E).add("");for(const F of S)x.has(F)||(x.add(F),E.push(F),S.push(bF(F)),o.push(gw));c=(F,k)=>E[k],d=(F,k)=>S[k]}for(a=0,f=o.length;a=0&&(p=o[E],p.data===gw);--E)p.data=null}if(m.parent=sae,m.eachBefore(function(E){E.depth=E.parent.depth+1,--f}).eachBefore(vD),m.parent=null,f>0)throw new Error("cycle");return m}return i.id=function(s){return arguments.length?(e=j_(s),i):e},i.parentId=function(s){return arguments.length?(t=j_(s),i):t},i.path=function(s){return arguments.length?(n=j_(s),i):n},i}function oae(e){e=`${e}`;let t=e.length;return SL(e,t-1)&&!SL(e,t-2)&&(e=e.slice(0,-1)),e[0]==="/"?e:`/${e}`}function bF(e){let t=e.length;if(t<2)return"";for(;--t>1&&!SL(e,t););return e.slice(0,t)}function SL(e,t){if(e[t]==="/"){let n=0;for(;t>0&&e[--t]==="\\";)++n;if(!(n&1))return!0}return!1}function lae(e,t){return e.parent===t.parent?1:2}function _w(e){var t=e.children;return t?t[0]:e.t}function pw(e){var t=e.children;return t?t[t.length-1]:e.t}function cae(e,t,n){var i=n/(t.i-e.i);t.c-=i,t.s+=n,e.c+=i,t.z+=n,t.m+=n}function dae(e){for(var t=0,n=0,i=e.children,s=i.length,o;--s>=0;)o=i[s],o.z+=t,o.m+=t,t+=o.s+(n+=o.c)}function fae(e,t,n){return e.a.parent===t.parent?e.a:n}function U_(e,t){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=t}U_.prototype=Object.create(qu.prototype);function uae(e){for(var t=new U_(e,0),n,i=[t],s,o,c,d;n=i.pop();)if(o=n._.children)for(n.children=new Array(d=o.length),c=d-1;c>=0;--c)i.push(s=n.children[c]=new U_(o[c],c)),s.parent=n;return(t.parent=new U_(null,0)).children=[t],t}function hae(){var e=lae,t=1,n=1,i=null;function s(u){var a=uae(u);if(a.eachAfter(o),a.parent.m=-a.z,a.eachBefore(c),i)u.eachBefore(f);else{var m=u,y=u,p=u;u.eachBefore(function(S){S.xy.x&&(y=S),S.depth>p.depth&&(p=S)});var l=m===y?1:e(m,y)/2,b=l-m.x,L=t/(y.x+l+b),E=n/(p.depth||1);u.eachBefore(function(S){S.x=(S.x+b)*L,S.y=S.depth*E})}return u}function o(u){var a=u.children,m=u.parent.children,y=u.i?m[u.i-1]:null;if(a){dae(u);var p=(a[0].z+a[a.length-1].z)/2;y?(u.z=y.z+e(u._,y._),u.m=u.z-p):u.z=p}else y&&(u.z=y.z+e(u._,y._));u.parent.A=d(u,y,u.parent.A||m[0])}function c(u){u._.x=u.z+u.parent.m,u.m+=u.parent.m}function d(u,a,m){if(a){for(var y=u,p=u,l=a,b=y.parent.children[0],L=y.m,E=p.m,S=l.m,x=b.m,F;l=pw(l),y=_w(y),l&&y;)b=_w(b),p=pw(p),p.a=u,F=l.z+S-y.z-L+e(l._,y._),F>0&&(cae(fae(l,u,m),u,F),L+=F,E+=F),S+=l.m,L+=y.m,x+=b.m,E+=p.m;l&&!pw(p)&&(p.t=l,p.m+=S-E),y&&!_w(b)&&(b.t=y,b.m+=L-x,m=u)}return m}function f(u){u.x*=t,u.y=u.depth*n}return s.separation=function(u){return arguments.length?(e=u,s):e},s.size=function(u){return arguments.length?(i=!1,t=+u[0],n=+u[1],s):i?null:[t,n]},s.nodeSize=function(u){return arguments.length?(i=!0,t=+u[0],n=+u[1],s):i?[t,n]:null},s}function D4(e,t,n,i,s){for(var o=e.children,c,d=-1,f=o.length,u=e.value&&(s-n)/e.value;++dS&&(S=u),M=L*L*k,x=Math.max(S/M,M/E),x>F){L-=u;break}F=x}c.push(f={value:L,dice:p1?i:1)},n}(BD);function gae(){var e=ID,t=!1,n=1,i=1,s=[0],o=nd,c=nd,d=nd,f=nd,u=nd;function a(y){return y.x0=y.y0=0,y.x1=n,y.y1=i,y.eachBefore(m),s=[0],t&&y.eachBefore(kD),y}function m(y){var p=s[y.depth],l=y.x0+p,b=y.y0+p,L=y.x1-p,E=y.y1-p;L=y-1){var S=o[m];S.x0=l,S.y0=b,S.x1=L,S.y1=E;return}for(var x=u[m],F=p/2+x,k=m+1,M=y-1;k>>1;u[O]E-b){var j=p?(l*P+L*C)/p:L;a(m,k,C,l,b,j,E),a(k,y,P,j,b,L,E)}else{var R=p?(b*P+E*C)/p:E;a(m,k,C,l,b,L,R),a(k,y,P,l,R,L,E)}}}function pae(e,t,n,i,s){(e.depth&1?D4:k0)(e,t,n,i,s)}const yae=function e(t){function n(i,s,o,c,d){if((f=i._squarify)&&f.ratio===t)for(var f,u,a,m,y=-1,p,l=f.length,b=i.value;++y1?i:1)},n}(BD);function Za(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Tc(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}const xL=Symbol("implicit");function eb(){var e=new iB,t=[],n=[],i=xL;function s(o){let c=e.get(o);if(c===void 0){if(i!==xL)return i;e.set(o,c=t.push(o)-1)}return n[c%n.length]}return s.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new iB;for(const c of o)e.has(c)||e.set(c,t.push(c)-1);return s},s.range=function(o){return arguments.length?(n=Array.from(o),s):n.slice()},s.unknown=function(o){return arguments.length?(i=o,s):i},s.copy=function(){return eb(t,n).unknown(i)},Za.apply(s,arguments),s}function mae(e){return function(){return e}}function kL(e){return+e}var TF=[0,1];function ss(e){return e}function BL(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:mae(isNaN(t)?NaN:.5)}function wae(e,t){var n;return e>t&&(n=e,e=t,t=n),function(i){return Math.max(e,Math.min(t,i))}}function Lae(e,t,n){var i=e[0],s=e[1],o=t[0],c=t[1];return s2?bae:Lae,f=u=null,m}function m(y){return y==null||isNaN(y=+y)?o:(f||(f=d(e.map(i),t,n)))(i(c(y)))}return m.invert=function(y){return c(s((u||(u=d(t,e.map(i),Gs)))(y)))},m.domain=function(y){return arguments.length?(e=Array.from(y,kL),a()):e.slice()},m.range=function(y){return arguments.length?(t=Array.from(y),a()):t.slice()},m.rangeRound=function(y){return t=Array.from(y),n=v0,a()},m.clamp=function(y){return arguments.length?(c=y?!0:ss,a()):c!==ss},m.interpolate=function(y){return arguments.length?(n=y,a()):n},m.unknown=function(y){return arguments.length?(o=y,m):o},function(y,p){return i=y,s=p,a()}}function OD(){return j4()(ss,ss)}function MD(e,t,n,i){var s=Jl(e,t,n),o;switch(i=Pd(i??",f"),i.type){case"s":{var c=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(o=NP(s,c))&&(i.precision=o),V7(i,c)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(o=CP(s,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=o-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(o=AP(s))&&(i.precision=o-(i.type==="%")*2);break}}return N4(i)}function df(e){var t=e.domain;return e.ticks=function(n){var i=t();return q5(i[0],i[i.length-1],n??10)},e.tickFormat=function(n,i){var s=t();return MD(s[0],s[s.length-1],n??10,i)},e.nice=function(n){n==null&&(n=10);var i=t(),s=0,o=i.length-1,c=i[s],d=i[o],f,u,a=10;for(d0;){if(u=V5(c,d,n),u===f)return i[s]=c,i[o]=d,t(i);if(u>0)c=Math.floor(c/u)*u,d=Math.ceil(d/u)*u;else if(u<0)c=Math.ceil(c*u)/u,d=Math.floor(d*u)/u;else break;f=u}return e},e}function U4(){var e=OD();return e.copy=function(){return B0(e,U4())},Za.apply(e,arguments),df(e)}function AD(e){var t;function n(i){return i==null||isNaN(i=+i)?t:i}return n.invert=n,n.domain=n.range=function(i){return arguments.length?(e=Array.from(i,kL),n):e.slice()},n.unknown=function(i){return arguments.length?(t=i,n):t},n.copy=function(){return AD(e).unknown(t)},e=arguments.length?Array.from(e,kL):[0,1],df(n)}function ND(e,t){e=e.slice();var n=0,i=e.length-1,s=e[n],o=e[i],c;return oMath.pow(e,t)}function xae(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function SF(e){return(t,n)=>-e(-t,n)}function tb(e){const t=e(vF,EF),n=t.domain;let i=10,s,o;function c(){return s=xae(i),o=Sae(i),n()[0]<0?(s=SF(s),o=SF(o),e(Tae,vae)):e(vF,EF),t}return t.base=function(d){return arguments.length?(i=+d,c()):i},t.domain=function(d){return arguments.length?(n(d),c()):n()},t.ticks=d=>{const f=n();let u=f[0],a=f[f.length-1];const m=a0){for(;y<=p;++y)for(l=1;la)break;E.push(b)}}else for(;y<=p;++y)for(l=i-1;l>=1;--l)if(b=y>0?l/o(-y):l*o(y),!(ba)break;E.push(b)}E.length*2{if(d==null&&(d=10),f==null&&(f=i===10?"s":","),typeof f!="function"&&(!(i%1)&&(f=Pd(f)).precision==null&&(f.trim=!0),f=N4(f)),d===1/0)return f;const u=Math.max(1,i*d/t.ticks().length);return a=>{let m=a/o(Math.round(s(a)));return m*in(ND(n(),{floor:d=>o(Math.floor(s(d))),ceil:d=>o(Math.ceil(s(d)))})),t}function CD(){const e=tb(j4()).domain([1,10]);return e.copy=()=>B0(e,CD()).base(e.base()),Za.apply(e,arguments),e}function xF(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function kF(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function nb(e){var t=1,n=e(xF(t),kF(t));return n.constant=function(i){return arguments.length?e(xF(t=+i),kF(t)):t},df(n)}function RD(){var e=nb(j4());return e.copy=function(){return B0(e,RD()).constant(e.constant())},Za.apply(e,arguments)}function BF(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function kae(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function Bae(e){return e<0?-e*e:e*e}function ib(e){var t=e(ss,ss),n=1;function i(){return n===1?e(ss,ss):n===.5?e(kae,Bae):e(BF(n),BF(1/n))}return t.exponent=function(s){return arguments.length?(n=+s,i()):n},df(t)}function sb(){var e=ib(j4());return e.copy=function(){return B0(e,sb()).exponent(e.exponent())},Za.apply(e,arguments),e}function Fae(){return sb.apply(null,arguments).exponent(.5)}function PD(){var e=[],t=[],n=[],i;function s(){var c=0,d=Math.max(1,t.length);for(n=new Array(d-1);++c0?n[d-1]:e[0],d=n?[i[n-1],t]:[i[u-1],i[u]]},c.unknown=function(f){return arguments.length&&(o=f),c},c.thresholds=function(){return i.slice()},c.copy=function(){return DD().domain([e,t]).range(s).unknown(o)},Za.apply(df(c),arguments)}function jD(){var e=[.5],t=[0,1],n,i=1;function s(o){return o!=null&&o<=o?t[L0(e,o,0,i)]:n}return s.domain=function(o){return arguments.length?(e=Array.from(o),i=Math.min(e.length,t.length-1),s):e.slice()},s.range=function(o){return arguments.length?(t=Array.from(o),i=Math.min(e.length,t.length-1),s):t.slice()},s.invertExtent=function(o){var c=t.indexOf(o);return[e[c-1],e[c]]},s.unknown=function(o){return arguments.length?(n=o,s):n},s.copy=function(){return jD().domain(e).range(t).unknown(n)},Za.apply(s,arguments)}const yw=new Date,mw=new Date;function Pn(e,t,n,i){function s(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return s.floor=o=>(e(o=new Date(+o)),o),s.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),s.round=o=>{const c=s(o),d=s.ceil(o);return o-c(t(o=new Date(+o),c==null?1:Math.floor(c)),o),s.range=(o,c,d)=>{const f=[];if(o=s.ceil(o),d=d==null?1:Math.floor(d),!(o0))return f;let u;do f.push(u=new Date(+o)),t(o,d),e(o);while(uPn(c=>{if(c>=c)for(;e(c),!o(c);)c.setTime(c-1)},(c,d)=>{if(c>=c)if(d<0)for(;++d<=0;)for(;t(c,-1),!o(c););else for(;--d>=0;)for(;t(c,1),!o(c););}),n&&(s.count=(o,c)=>(yw.setTime(+o),mw.setTime(+c),e(yw),e(mw),Math.floor(n(yw,mw))),s.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?s.filter(i?c=>i(c)%o===0:c=>s.count(0,c)%o===0):s)),s}const Vu=Pn(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Vu.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?Pn(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Vu);Vu.range;const Bo=1e3,Ys=Bo*60,Fo=Ys*60,Go=Fo*24,rb=Go*7,FF=Go*30,ww=Go*365,Io=Pn(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Bo)},(e,t)=>(t-e)/Bo,e=>e.getUTCSeconds());Io.range;const H4=Pn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Bo)},(e,t)=>{e.setTime(+e+t*Ys)},(e,t)=>(t-e)/Ys,e=>e.getMinutes());H4.range;const z4=Pn(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Ys)},(e,t)=>(t-e)/Ys,e=>e.getUTCMinutes());z4.range;const $4=Pn(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Bo-e.getMinutes()*Ys)},(e,t)=>{e.setTime(+e+t*Fo)},(e,t)=>(t-e)/Fo,e=>e.getHours());$4.range;const q4=Pn(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Fo)},(e,t)=>(t-e)/Fo,e=>e.getUTCHours());q4.range;const Ro=Pn(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Ys)/Go,e=>e.getDate()-1);Ro.range;const Ul=Pn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Go,e=>e.getUTCDate()-1);Ul.range;const UD=Pn(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Go,e=>Math.floor(e/Go));UD.range;function ff(e){return Pn(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,n)=>{t.setDate(t.getDate()+n*7)},(t,n)=>(n-t-(n.getTimezoneOffset()-t.getTimezoneOffset())*Ys)/rb)}const Eh=ff(0),cy=ff(1),Iae=ff(2),Oae=ff(3),Gu=ff(4),Mae=ff(5),Aae=ff(6);Eh.range;cy.range;Iae.range;Oae.range;Gu.range;Mae.range;Aae.range;function uf(e){return Pn(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCDate(t.getUTCDate()+n*7)},(t,n)=>(n-t)/rb)}const Sh=uf(0),dy=uf(1),Nae=uf(2),Cae=uf(3),Wu=uf(4),Rae=uf(5),Pae=uf(6);Sh.range;dy.range;Nae.range;Cae.range;Wu.range;Rae.range;Pae.range;const A2=Pn(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());A2.range;const N2=Pn(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());N2.range;const Da=Pn(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());Da.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Pn(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,n)=>{t.setFullYear(t.getFullYear()+n*e)});Da.range;const ja=Pn(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());ja.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:Pn(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,n)=>{t.setUTCFullYear(t.getUTCFullYear()+n*e)});ja.range;function HD(e,t,n,i,s,o){const c=[[Io,1,Bo],[Io,5,5*Bo],[Io,15,15*Bo],[Io,30,30*Bo],[o,1,Ys],[o,5,5*Ys],[o,15,15*Ys],[o,30,30*Ys],[s,1,Fo],[s,3,3*Fo],[s,6,6*Fo],[s,12,12*Fo],[i,1,Go],[i,2,2*Go],[n,1,rb],[t,1,FF],[t,3,3*FF],[e,1,ww]];function d(u,a,m){const y=aL).right(c,y);if(p===c.length)return e.every(Jl(u/ww,a/ww,m));if(p===0)return Vu.every(Math.max(Jl(u,a,m),1));const[l,b]=c[y/c[p-1][2]53)return null;"w"in D||(D.w=1),"Z"in D?(J=bw(Qh(D.y,0,1)),re=J.getUTCDay(),J=re>4||re===0?dy.ceil(J):dy(J),J=Ul.offset(J,(D.V-1)*7),D.y=J.getUTCFullYear(),D.m=J.getUTCMonth(),D.d=J.getUTCDate()+(D.w+6)%7):(J=Lw(Qh(D.y,0,1)),re=J.getDay(),J=re>4||re===0?cy.ceil(J):cy(J),J=Ro.offset(J,(D.V-1)*7),D.y=J.getFullYear(),D.m=J.getMonth(),D.d=J.getDate()+(D.w+6)%7)}else("W"in D||"U"in D)&&("w"in D||(D.w="u"in D?D.u%7:"W"in D?1:0),re="Z"in D?bw(Qh(D.y,0,1)).getUTCDay():Lw(Qh(D.y,0,1)).getDay(),D.m=0,D.d="W"in D?(D.w+6)%7+D.W*7-(re+5)%7:D.w+D.U*7-(re+6)%7);return"Z"in D?(D.H+=D.Z/100|0,D.M+=D.Z%100,bw(D)):Lw(D)}}function C(ge,V,q,D){for(var K=0,J=V.length,re=q.length,se,_e;K=re)return-1;if(se=V.charCodeAt(K++),se===37){if(se=V.charAt(K++),_e=k[se in IF?V.charAt(K++):se],!_e||(D=_e(ge,q,D))<0)return-1}else if(se!=q.charCodeAt(D++))return-1}return D}function P(ge,V,q){var D=u.exec(V.slice(q));return D?(ge.p=a.get(D[0].toLowerCase()),q+D[0].length):-1}function j(ge,V,q){var D=p.exec(V.slice(q));return D?(ge.w=l.get(D[0].toLowerCase()),q+D[0].length):-1}function R(ge,V,q){var D=m.exec(V.slice(q));return D?(ge.w=y.get(D[0].toLowerCase()),q+D[0].length):-1}function H(ge,V,q){var D=E.exec(V.slice(q));return D?(ge.m=S.get(D[0].toLowerCase()),q+D[0].length):-1}function z(ge,V,q){var D=b.exec(V.slice(q));return D?(ge.m=L.get(D[0].toLowerCase()),q+D[0].length):-1}function Y(ge,V,q){return C(ge,t,V,q)}function $(ge,V,q){return C(ge,n,V,q)}function W(ge,V,q){return C(ge,i,V,q)}function X(ge){return c[ge.getDay()]}function G(ge){return o[ge.getDay()]}function oe(ge){return f[ge.getMonth()]}function he(ge){return d[ge.getMonth()]}function ie(ge){return s[+(ge.getHours()>=12)]}function Oe(ge){return 1+~~(ge.getMonth()/3)}function de(ge){return c[ge.getUTCDay()]}function Me(ge){return o[ge.getUTCDay()]}function Fe(ge){return f[ge.getUTCMonth()]}function Ge(ge){return d[ge.getUTCMonth()]}function pt(ge){return s[+(ge.getUTCHours()>=12)]}function ht(ge){return 1+~~(ge.getUTCMonth()/3)}return{format:function(ge){var V=M(ge+="",x);return V.toString=function(){return ge},V},parse:function(ge){var V=O(ge+="",!1);return V.toString=function(){return ge},V},utcFormat:function(ge){var V=M(ge+="",F);return V.toString=function(){return ge},V},utcParse:function(ge){var V=O(ge+="",!0);return V.toString=function(){return ge},V}}}var IF={"-":"",_:" ",0:"0"},Qn=/^\s*\d+/,zae=/^%/,$ae=/[\\^$*+?|[\]().{}]/g;function At(e,t,n){var i=e<0?"-":"",s=(i?-e:e)+"",o=s.length;return i+(o[t.toLowerCase(),n]))}function Vae(e,t,n){var i=Qn.exec(t.slice(n,n+1));return i?(e.w=+i[0],n+i[0].length):-1}function Gae(e,t,n){var i=Qn.exec(t.slice(n,n+1));return i?(e.u=+i[0],n+i[0].length):-1}function Wae(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.U=+i[0],n+i[0].length):-1}function Yae(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.V=+i[0],n+i[0].length):-1}function Xae(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.W=+i[0],n+i[0].length):-1}function OF(e,t,n){var i=Qn.exec(t.slice(n,n+4));return i?(e.y=+i[0],n+i[0].length):-1}function MF(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function Kae(e,t,n){var i=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(n,n+6));return i?(e.Z=i[1]?0:-(i[2]+(i[3]||"00")),n+i[0].length):-1}function Zae(e,t,n){var i=Qn.exec(t.slice(n,n+1));return i?(e.q=i[0]*3-3,n+i[0].length):-1}function Jae(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.m=i[0]-1,n+i[0].length):-1}function AF(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.d=+i[0],n+i[0].length):-1}function Qae(e,t,n){var i=Qn.exec(t.slice(n,n+3));return i?(e.m=0,e.d=+i[0],n+i[0].length):-1}function NF(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.H=+i[0],n+i[0].length):-1}function eoe(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.M=+i[0],n+i[0].length):-1}function toe(e,t,n){var i=Qn.exec(t.slice(n,n+2));return i?(e.S=+i[0],n+i[0].length):-1}function noe(e,t,n){var i=Qn.exec(t.slice(n,n+3));return i?(e.L=+i[0],n+i[0].length):-1}function ioe(e,t,n){var i=Qn.exec(t.slice(n,n+6));return i?(e.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function soe(e,t,n){var i=zae.exec(t.slice(n,n+1));return i?n+i[0].length:-1}function roe(e,t,n){var i=Qn.exec(t.slice(n));return i?(e.Q=+i[0],n+i[0].length):-1}function aoe(e,t,n){var i=Qn.exec(t.slice(n));return i?(e.s=+i[0],n+i[0].length):-1}function CF(e,t){return At(e.getDate(),t,2)}function ooe(e,t){return At(e.getHours(),t,2)}function loe(e,t){return At(e.getHours()%12||12,t,2)}function coe(e,t){return At(1+Ro.count(Da(e),e),t,3)}function $D(e,t){return At(e.getMilliseconds(),t,3)}function doe(e,t){return $D(e,t)+"000"}function foe(e,t){return At(e.getMonth()+1,t,2)}function uoe(e,t){return At(e.getMinutes(),t,2)}function hoe(e,t){return At(e.getSeconds(),t,2)}function goe(e){var t=e.getDay();return t===0?7:t}function _oe(e,t){return At(Eh.count(Da(e)-1,e),t,2)}function qD(e){var t=e.getDay();return t>=4||t===0?Gu(e):Gu.ceil(e)}function poe(e,t){return e=qD(e),At(Gu.count(Da(e),e)+(Da(e).getDay()===4),t,2)}function yoe(e){return e.getDay()}function moe(e,t){return At(cy.count(Da(e)-1,e),t,2)}function woe(e,t){return At(e.getFullYear()%100,t,2)}function Loe(e,t){return e=qD(e),At(e.getFullYear()%100,t,2)}function boe(e,t){return At(e.getFullYear()%1e4,t,4)}function Toe(e,t){var n=e.getDay();return e=n>=4||n===0?Gu(e):Gu.ceil(e),At(e.getFullYear()%1e4,t,4)}function voe(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+At(t/60|0,"0",2)+At(t%60,"0",2)}function RF(e,t){return At(e.getUTCDate(),t,2)}function Eoe(e,t){return At(e.getUTCHours(),t,2)}function Soe(e,t){return At(e.getUTCHours()%12||12,t,2)}function xoe(e,t){return At(1+Ul.count(ja(e),e),t,3)}function VD(e,t){return At(e.getUTCMilliseconds(),t,3)}function koe(e,t){return VD(e,t)+"000"}function Boe(e,t){return At(e.getUTCMonth()+1,t,2)}function Foe(e,t){return At(e.getUTCMinutes(),t,2)}function Ioe(e,t){return At(e.getUTCSeconds(),t,2)}function Ooe(e){var t=e.getUTCDay();return t===0?7:t}function Moe(e,t){return At(Sh.count(ja(e)-1,e),t,2)}function GD(e){var t=e.getUTCDay();return t>=4||t===0?Wu(e):Wu.ceil(e)}function Aoe(e,t){return e=GD(e),At(Wu.count(ja(e),e)+(ja(e).getUTCDay()===4),t,2)}function Noe(e){return e.getUTCDay()}function Coe(e,t){return At(dy.count(ja(e)-1,e),t,2)}function Roe(e,t){return At(e.getUTCFullYear()%100,t,2)}function Poe(e,t){return e=GD(e),At(e.getUTCFullYear()%100,t,2)}function Doe(e,t){return At(e.getUTCFullYear()%1e4,t,4)}function joe(e,t){var n=e.getUTCDay();return e=n>=4||n===0?Wu(e):Wu.ceil(e),At(e.getUTCFullYear()%1e4,t,4)}function Uoe(){return"+0000"}function PF(){return"%"}function DF(e){return+e}function jF(e){return Math.floor(+e/1e3)}var If,ab,WD,ob,YD;Hoe({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Hoe(e){return If=zD(e),ab=If.format,WD=If.parse,ob=If.utcFormat,YD=If.utcParse,If}function zoe(e){return new Date(e)}function $oe(e){return e instanceof Date?+e:+new Date(+e)}function lb(e,t,n,i,s,o,c,d,f,u){var a=OD(),m=a.invert,y=a.domain,p=u(".%L"),l=u(":%S"),b=u("%I:%M"),L=u("%I %p"),E=u("%a %d"),S=u("%b %d"),x=u("%B"),F=u("%Y");function k(M){return(f(M)1?0:e<-1?Yu:Math.acos(e)}function HF(e){return e>=1?fy:e<=-1?-fy:Math.asin(e)}function W4(e){let t=3;return e.digits=function(n){if(!arguments.length)return t;if(n==null)t=null;else{const i=Math.floor(n);if(!(i>=0))throw new RangeError(`invalid digits: ${n}`);t=i}return e},()=>new U7(t)}function Xoe(e){return e.innerRadius}function Koe(e){return e.outerRadius}function Zoe(e){return e.startAngle}function Joe(e){return e.endAngle}function Qoe(e){return e&&e.padAngle}function ele(e,t,n,i,s,o,c,d){var f=n-e,u=i-t,a=c-s,m=d-o,y=m*f-a*u;if(!(y*yY*Y+$*$&&(C=j,P=R),{cx:C,cy:P,x01:-a,y01:-m,x11:C*(s/k-1),y11:P*(s/k-1)}}function tle(){var e=Xoe,t=Koe,n=Ht(0),i=null,s=Zoe,o=Joe,c=Qoe,d=null,f=W4(u);function u(){var a,m,y=+e.apply(this,arguments),p=+t.apply(this,arguments),l=s.apply(this,arguments)-fy,b=o.apply(this,arguments)-fy,L=UF(b-l),E=b>l;if(d||(d=a=f()),pdi))d.moveTo(0,0);else if(L>tj-di)d.moveTo(p*Pc(l),p*ta(l)),d.arc(0,0,p,l,b,!E),y>di&&(d.moveTo(y*Pc(b),y*ta(b)),d.arc(0,0,y,b,l,E));else{var S=l,x=b,F=l,k=b,M=L,O=L,C=c.apply(this,arguments)/2,P=C>di&&(i?+i.apply(this,arguments):yd(y*y+p*p)),j=Tw(UF(p-y)/2,+n.apply(this,arguments)),R=j,H=j,z,Y;if(P>di){var $=HF(P/y*ta(C)),W=HF(P/p*ta(C));(M-=$*2)>di?($*=E?1:-1,F+=$,k-=$):(M=0,F=k=(l+b)/2),(O-=W*2)>di?(W*=E?1:-1,S+=W,x-=W):(O=0,S=x=(l+b)/2)}var X=p*Pc(S),G=p*ta(S),oe=y*Pc(k),he=y*ta(k);if(j>di){var ie=p*Pc(x),Oe=p*ta(x),de=y*Pc(F),Me=y*ta(F),Fe;if(Ldi?H>di?(z=Gg(de,Me,X,G,p,H,E),Y=Gg(ie,Oe,oe,he,p,H,E),d.moveTo(z.cx+z.x01,z.cy+z.y01),Hdi)||!(M>di)?d.lineTo(oe,he):R>di?(z=Gg(oe,he,ie,Oe,y,-R,E),Y=Gg(X,G,de,Me,y,-R,E),d.lineTo(z.cx+z.x01,z.cy+z.y01),R=p;--l)d.point(x[l],F[l]);d.lineEnd(),d.areaEnd()}E&&(x[y]=+e(L,y,m),F[y]=+t(L,y,m),d.point(i?+i(L,y,m):x[y],n?+n(L,y,m):F[y]))}if(S)return d=null,S+""||null}function a(){return aj().defined(s).curve(c).context(o)}return u.x=function(m){return arguments.length?(e=typeof m=="function"?m:Ht(+m),i=null,u):e},u.x0=function(m){return arguments.length?(e=typeof m=="function"?m:Ht(+m),u):e},u.x1=function(m){return arguments.length?(i=m==null?null:typeof m=="function"?m:Ht(+m),u):i},u.y=function(m){return arguments.length?(t=typeof m=="function"?m:Ht(+m),n=null,u):t},u.y0=function(m){return arguments.length?(t=typeof m=="function"?m:Ht(+m),u):t},u.y1=function(m){return arguments.length?(n=m==null?null:typeof m=="function"?m:Ht(+m),u):n},u.lineX0=u.lineY0=function(){return a().x(e).y(t)},u.lineY1=function(){return a().x(e).y(n)},u.lineX1=function(){return a().x(i).y(t)},u.defined=function(m){return arguments.length?(s=typeof m=="function"?m:Ht(!!m),u):s},u.curve=function(m){return arguments.length?(c=m,o!=null&&(d=c(o)),u):c},u.context=function(m){return arguments.length?(m==null?o=d=null:d=c(o=m),u):o},u}const nle={draw(e,t){const n=yd(t/Yu);e.moveTo(n,0),e.arc(0,0,n,0,tj)}};function ile(e,t){let n=null,i=W4(s);e=typeof e=="function"?e:Ht(e||nle),t=typeof t=="function"?t:Ht(t===void 0?64:+t);function s(){let o;if(n||(n=o=i()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return s.type=function(o){return arguments.length?(e=typeof o=="function"?o:Ht(o),s):e},s.size=function(o){return arguments.length?(t=typeof o=="function"?o:Ht(+o),s):t},s.context=function(o){return arguments.length?(n=o??null,s):n},s}function tc(){}function uy(e,t,n){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+n)/6)}function Y4(e){this._context=e}Y4.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:uy(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:uy(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function sle(e){return new Y4(e)}function lj(e){this._context=e}lj.prototype={areaStart:tc,areaEnd:tc,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:uy(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function rle(e){return new lj(e)}function cj(e){this._context=e}cj.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var n=(this._x0+4*this._x1+e)/6,i=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(n,i):this._context.moveTo(n,i);break;case 3:this._point=4;default:uy(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function ale(e){return new cj(e)}function dj(e,t){this._basis=new Y4(e),this._beta=t}dj.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var e=this._x,t=this._y,n=e.length-1;if(n>0)for(var i=e[0],s=t[0],o=e[n]-i,c=t[n]-s,d=-1,f;++d<=n;)f=d/n,this._basis.point(this._beta*e[d]+(1-this._beta)*(i+f*o),this._beta*t[d]+(1-this._beta)*(s+f*c));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const ole=function e(t){function n(i){return t===1?new Y4(i):new dj(i,t)}return n.beta=function(i){return e(+i)},n}(.85);function hy(e,t,n){e._context.bezierCurveTo(e._x1+e._k*(e._x2-e._x0),e._y1+e._k*(e._y2-e._y0),e._x2+e._k*(e._x1-t),e._y2+e._k*(e._y1-n),e._x2,e._y2)}function hb(e,t){this._context=e,this._k=(1-t)/6}hb.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:hy(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2,this._x1=e,this._y1=t;break;case 2:this._point=3;default:hy(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const lle=function e(t){function n(i){return new hb(i,t)}return n.tension=function(i){return e(+i)},n}(0);function gb(e,t){this._context=e,this._k=(1-t)/6}gb.prototype={areaStart:tc,areaEnd:tc,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:hy(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const cle=function e(t){function n(i){return new gb(i,t)}return n.tension=function(i){return e(+i)},n}(0);function _b(e,t){this._context=e,this._k=(1-t)/6}_b.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:hy(this,e,t);break}this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const dle=function e(t){function n(i){return new _b(i,t)}return n.tension=function(i){return e(+i)},n}(0);function pb(e,t,n){var i=e._x1,s=e._y1,o=e._x2,c=e._y2;if(e._l01_a>di){var d=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,f=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*d-e._x0*e._l12_2a+e._x2*e._l01_2a)/f,s=(s*d-e._y0*e._l12_2a+e._y2*e._l01_2a)/f}if(e._l23_a>di){var u=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,a=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*u+e._x1*e._l23_2a-t*e._l12_2a)/a,c=(c*u+e._y1*e._l23_2a-n*e._l12_2a)/a}e._context.bezierCurveTo(i,s,o,c,e._x2,e._y2)}function fj(e,t){this._context=e,this._alpha=t}fj.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3;default:pb(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const fle=function e(t){function n(i){return t?new fj(i,t):new hb(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function uj(e,t){this._context=e,this._alpha=t}uj.prototype={areaStart:tc,areaEnd:tc,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=e,this._y3=t;break;case 1:this._point=2,this._context.moveTo(this._x4=e,this._y4=t);break;case 2:this._point=3,this._x5=e,this._y5=t;break;default:pb(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const ule=function e(t){function n(i){return t?new uj(i,t):new gb(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function hj(e,t){this._context=e,this._alpha=t}hj.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){if(e=+e,t=+t,this._point){var n=this._x2-e,i=this._y2-t;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(n*n+i*i,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:pb(this,e,t);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=e,this._y0=this._y1,this._y1=this._y2,this._y2=t}};const hle=function e(t){function n(i){return t?new hj(i,t):new _b(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function gj(e){this._context=e}gj.prototype={areaStart:tc,areaEnd:tc,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function gle(e){return new gj(e)}function zF(e){return e<0?-1:1}function $F(e,t,n){var i=e._x1-e._x0,s=t-e._x1,o=(e._y1-e._y0)/(i||s<0&&-0),c=(n-e._y1)/(s||i<0&&-0),d=(o*s+c*i)/(i+s);return(zF(o)+zF(c))*Math.min(Math.abs(o),Math.abs(c),.5*Math.abs(d))||0}function qF(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function vw(e,t,n){var i=e._x0,s=e._y0,o=e._x1,c=e._y1,d=(o-i)/3;e._context.bezierCurveTo(i+d,s+d*t,o-d,c-d*n,o,c)}function gy(e){this._context=e}gy.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:vw(this,this._t0,qF(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var n=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,vw(this,qF(this,n=$F(this,e,t)),n);break;default:vw(this,this._t0,n=$F(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function _j(e){this._context=new pj(e)}(_j.prototype=Object.create(gy.prototype)).point=function(e,t){gy.prototype.point.call(this,t,e)};function pj(e){this._context=e}pj.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,n,i,s,o){this._context.bezierCurveTo(t,e,i,n,o,s)}};function _le(e){return new gy(e)}function ple(e){return new _j(e)}function yj(e){this._context=e}yj.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,n=e.length;if(n)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),n===2)this._context.lineTo(e[1],t[1]);else for(var i=VF(e),s=VF(t),o=0,c=1;c=0;--t)s[t]=(c[t]-s[t+1])/o[t];for(o[n-1]=(e[n]+s[n-1])/2,t=0;t=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var n=this._x*(1-this._t)+e*this._t;this._context.lineTo(n,this._y),this._context.lineTo(n,t)}break}}this._x=e,this._y=t}};function mle(e){return new X4(e,.5)}function wle(e){return new X4(e,0)}function Lle(e){return new X4(e,1)}function N1(e,t,n){this.k=e,this.x=t,this.y=n}N1.prototype={constructor:N1,scale:function(e){return e===1?this:new N1(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new N1(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};N1.prototype;function*mj(e,t){if(t==null)for(let n of e)n!=null&&n!==""&&(n=+n)>=n&&(yield n);else{let n=-1;for(let i of e)i=t(i,++n,e),i!=null&&i!==""&&(i=+i)>=i&&(yield i)}}function yb(e,t,n){const i=Float64Array.from(mj(e,n));return i.sort(No),t.map(s=>MR(i,s))}function mb(e,t){return yb(e,[.25,.5,.75],t)}function wb(e,t){const n=e.length,i=sQ(e,t),s=mb(e,t),o=(s[2]-s[0])/1.34;return 1.06*(Math.min(i,o)||i||Math.abs(s[0])||1)*Math.pow(n,-.2)}function Lb(e){const t=e.maxbins||20,n=e.base||10,i=Math.log(n),s=e.divide||[5,2];let o=e.extent[0],c=e.extent[1],d,f,u,a,m,y;const p=e.span||c-o||Math.abs(o)||1;if(e.step)d=e.step;else if(e.steps){for(a=p/t,m=0,y=e.steps.length;mt;)d*=n;for(m=0,y=s.length;m=u&&p/a<=t&&(d=a)}a=Math.log(d);const l=a>=0?0:~~(-a/i)+1,b=Math.pow(n,-l-1);return(e.nice||e.nice===void 0)&&(a=Math.floor(o/d+b)*d,o=oy);const s=e.length,o=new Float64Array(s);let c=0,d=1,f=i(e[0]),u=f,a=f+t,m;for(;d=a){for(u=(f+u)/2;c>1);cs;)e[c--]=e[i]}i=s,s=o}return e}function vle(e){return function(){return e=(1103515245*e+12345)%2147483647,e/2147483647}}function Ele(e,t){t==null&&(t=e,e=0);let n,i,s;const o={min(c){return arguments.length?(n=c||0,s=i-n,o):n},max(c){return arguments.length?(i=c||0,s=i-n,o):i},sample(){return n+Math.floor(s*ir())},pdf(c){return c===Math.floor(c)&&c>=n&&c=i?1:(d-n+1)/s},icdf(c){return c>=0&&c<=1?n-1+Math.floor(c*s):NaN}};return o.min(e).max(t)}const bj=Math.sqrt(2*Math.PI),Sle=Math.SQRT2;let n1=NaN;function K4(e,t){e=e||0,t=t??1;let n=0,i=0,s,o;if(n1===n1)n=n1,n1=NaN;else{do n=ir()*2-1,i=ir()*2-1,s=n*n+i*i;while(s===0||s>1);o=Math.sqrt(-2*Math.log(s)/s),n*=o,n1=i*o}return e+n*t}function bb(e,t,n){n=n??1;const i=(e-(t||0))/n;return Math.exp(-.5*i*i)/(n*bj)}function Z4(e,t,n){t=t||0,n=n??1;const i=(e-t)/n,s=Math.abs(i);let o;if(s>37)o=0;else{const c=Math.exp(-s*s/2);let d;s<7.07106781186547?(d=.0352624965998911*s+.700383064443688,d=d*s+6.37396220353165,d=d*s+33.912866078383,d=d*s+112.079291497871,d=d*s+221.213596169931,d=d*s+220.206867912376,o=c*d,d=.0883883476483184*s+1.75566716318264,d=d*s+16.064177579207,d=d*s+86.7807322029461,d=d*s+296.564248779674,d=d*s+637.333633378831,d=d*s+793.826512519948,d=d*s+440.413735824752,o=o/d):(d=s+.65,d=s+4/d,d=s+3/d,d=s+2/d,d=s+1/d,o=c/d/2.506628274631)}return i>0?1-o:o}function J4(e,t,n){return e<0||e>1?NaN:(t||0)+(n??1)*Sle*xle(2*e-1)}function xle(e){let t=-Math.log((1-e)*(1+e)),n;return t<6.25?(t-=3.125,n=-364441206401782e-35,n=-16850591381820166e-35+n*t,n=128584807152564e-32+n*t,n=11157877678025181e-33+n*t,n=-1333171662854621e-31+n*t,n=20972767875968562e-33+n*t,n=6637638134358324e-30+n*t,n=-4054566272975207e-29+n*t,n=-8151934197605472e-29+n*t,n=26335093153082323e-28+n*t,n=-12975133253453532e-27+n*t,n=-5415412054294628e-26+n*t,n=10512122733215323e-25+n*t,n=-4112633980346984e-24+n*t,n=-29070369957882005e-24+n*t,n=42347877827932404e-23+n*t,n=-13654692000834679e-22+n*t,n=-13882523362786469e-21+n*t,n=.00018673420803405714+n*t,n=-.000740702534166267+n*t,n=-.006033670871430149+n*t,n=.24015818242558962+n*t,n=1.6536545626831027+n*t):t<16?(t=Math.sqrt(t)-3.25,n=22137376921775787e-25,n=9075656193888539e-23+n*t,n=-27517406297064545e-23+n*t,n=18239629214389228e-24+n*t,n=15027403968909828e-22+n*t,n=-4013867526981546e-21+n*t,n=29234449089955446e-22+n*t,n=12475304481671779e-21+n*t,n=-47318229009055734e-21+n*t,n=6828485145957318e-20+n*t,n=24031110387097894e-21+n*t,n=-.0003550375203628475+n*t,n=.0009532893797373805+n*t,n=-.0016882755560235047+n*t,n=.002491442096107851+n*t,n=-.003751208507569241+n*t,n=.005370914553590064+n*t,n=1.0052589676941592+n*t,n=3.0838856104922208+n*t):Number.isFinite(t)?(t=Math.sqrt(t)-5,n=-27109920616438573e-27,n=-2555641816996525e-25+n*t,n=15076572693500548e-25+n*t,n=-3789465440126737e-24+n*t,n=761570120807834e-23+n*t,n=-1496002662714924e-23+n*t,n=2914795345090108e-23+n*t,n=-6771199775845234e-23+n*t,n=22900482228026655e-23+n*t,n=-99298272942317e-20+n*t,n=4526062597223154e-21+n*t,n=-1968177810553167e-20+n*t,n=7599527703001776e-20+n*t,n=-.00021503011930044477+n*t,n=-.00013871931833623122+n*t,n=1.0103004648645344+n*t,n=4.849906401408584+n*t):n=1/0,n*e}function Tb(e,t){let n,i;const s={mean(o){return arguments.length?(n=o||0,s):n},stdev(o){return arguments.length?(i=o??1,s):i},sample:()=>K4(n,i),pdf:o=>bb(o,n,i),cdf:o=>Z4(o,n,i),icdf:o=>J4(o,n,i)};return s.mean(e).stdev(t)}function vb(e,t){const n=Tb();let i=0;const s={data(o){return arguments.length?(e=o,i=o?o.length:0,s.bandwidth(t)):e},bandwidth(o){return arguments.length?(t=o,!t&&e&&(t=wb(e)),s):t},sample(){return e[~~(ir()*i)]+t*n.sample()},pdf(o){let c=0,d=0;for(;dEb(n,i),pdf:o=>Sb(o,n,i),cdf:o=>xb(o,n,i),icdf:o=>kb(o,n,i)};return s.mean(e).stdev(t)}function vj(e,t){let n=0,i;function s(c){const d=[];let f=0,u;for(u=0;u=t&&e<=n?1/(n-t):0}function Ib(e,t,n){return n==null&&(n=t??1,t=0),en?1:(e-t)/(n-t)}function Ob(e,t,n){return n==null&&(n=t??1,t=0),e>=0&&e<=1?t+e*(n-t):NaN}function Ej(e,t){let n,i;const s={min(o){return arguments.length?(n=o||0,s):n},max(o){return arguments.length?(i=o??1,s):i},sample:()=>Bb(n,i),pdf:o=>Fb(o,n,i),cdf:o=>Ib(o,n,i),icdf:o=>Ob(o,n,i)};return t==null&&(t=e??1,e=0),s.min(e).max(t)}function F0(e,t,n,i){const s=i-e*e,o=Math.abs(s)<1e-24?0:(n-e*t)/s;return[t-o*e,o]}function Q4(e,t,n,i){e=e.filter(p=>{let l=t(p),b=n(p);return l!=null&&(l=+l)>=l&&b!=null&&(b=+b)>=b}),i&&e.sort((p,l)=>t(p)-t(l));const s=e.length,o=new Float64Array(s),c=new Float64Array(s);let d=0,f=0,u=0,a,m,y;for(y of e)o[d]=a=+t(y),c[d]=m=+n(y),++d,f+=(a-f)/d,u+=(m-u)/d;for(d=0;d=o&&c!=null&&(c=+c)>=c&&i(o,c,++s)}function xh(e,t,n,i,s){let o=0,c=0;return I0(e,t,n,(d,f)=>{const u=f-s(d),a=f-i;o+=u*u,c+=a*a}),1-o/c}function Mb(e,t,n){let i=0,s=0,o=0,c=0,d=0;I0(e,t,n,(a,m)=>{++d,i+=(a-i)/d,s+=(m-s)/d,o+=(a*m-o)/d,c+=(a*a-c)/d});const f=F0(i,s,o,c),u=a=>f[0]+f[1]*a;return{coef:f,predict:u,rSquared:xh(e,t,n,s,u)}}function Sj(e,t,n){let i=0,s=0,o=0,c=0,d=0;I0(e,t,n,(a,m)=>{++d,a=Math.log(a),i+=(a-i)/d,s+=(m-s)/d,o+=(a*m-o)/d,c+=(a*a-c)/d});const f=F0(i,s,o,c),u=a=>f[0]+f[1]*Math.log(a);return{coef:f,predict:u,rSquared:xh(e,t,n,s,u)}}function xj(e,t,n){const[i,s,o,c]=Q4(e,t,n);let d=0,f=0,u=0,a=0,m=0,y,p,l;I0(e,t,n,(S,x)=>{y=i[m++],p=Math.log(x),l=y*x,d+=(x*p-d)/m,f+=(l-f)/m,u+=(l*p-u)/m,a+=(y*l-a)/m});const[b,L]=F0(f/c,d/c,u/c,a/c),E=S=>Math.exp(b+L*(S-o));return{coef:[Math.exp(b-L*o),L],predict:E,rSquared:xh(e,t,n,c,E)}}function kj(e,t,n){let i=0,s=0,o=0,c=0,d=0,f=0;I0(e,t,n,(m,y)=>{const p=Math.log(m),l=Math.log(y);++f,i+=(p-i)/f,s+=(l-s)/f,o+=(p*l-o)/f,c+=(p*p-c)/f,d+=(y-d)/f});const u=F0(i,s,o,c),a=m=>u[0]*Math.pow(m,u[1]);return u[0]=Math.exp(u[0]),{coef:u,predict:a,rSquared:xh(e,t,n,d,a)}}function Ab(e,t,n){const[i,s,o,c]=Q4(e,t,n),d=i.length;let f=0,u=0,a=0,m=0,y=0,p,l,b,L;for(p=0;p(O=O-o,x*O*O+F*O+k+c);return{coef:[k-F*o+x*o*o+c,F-2*x*o,x],predict:M,rSquared:xh(e,t,n,c,M)}}function Bj(e,t,n,i){if(i===1)return Mb(e,t,n);if(i===2)return Ab(e,t,n);const[s,o,c,d]=Q4(e,t,n),f=s.length,u=[],a=[],m=i+1;let y,p,l,b,L;for(y=0;y{x-=c;let F=d+E[0]+E[1]*x+E[2]*x*x;for(y=3;y=0;--o)for(d=t[o],f=1,s[o]+=d,c=1;c<=o;++c)f*=(o+1-c)/c,s[o-c]+=d*Math.pow(n,c)*f;return s[0]+=i,s}function Ble(e){const t=e.length-1,n=[];let i,s,o,c,d;for(i=0;iMath.abs(e[i][c])&&(c=s);for(o=i;o=i;o--)e[o][s]-=e[o][i]*e[i][s]/e[i][i]}for(s=t-1;s>=0;--s){for(d=0,o=s+1;os[x]-E?S:x;let k=0,M=0,O=0,C=0,P=0;const j=1/Math.abs(s[F]-E||1);for(let z=S;z<=x;++z){const Y=s[z],$=o[z],W=Fle(Math.abs(E-Y)*j)*y[z],X=Y*W;k+=W,M+=X,O+=$*W,C+=$*X,P+=Y*X}const[R,H]=F0(M/k,O/k,C/k,P/k);a[L]=R+H*E,m[L]=Math.abs(o[L]-a[L]),Ile(s,L+1,l)}if(p===GF)break;const b=AR(m);if(Math.abs(b)=1?WF:(S=1-E*E)*S}return Ole(s,a,c,d)}function Fle(e){return(e=1-e*e*e)*e*e}function Ile(e,t,n){const i=e[t];let s=n[0],o=n[1]+1;if(!(o>=e.length))for(;t>s&&e[o]-i<=i-e[s];)n[0]=++s,n[1]=o,++o}function Ole(e,t,n,i){const s=e.length,o=[];let c=0,d=0,f=[],u;for(;c[b,e(b)],o=t[0],c=t[1],d=c-o,f=d/i,u=[s(o)],a=[];if(n===i){for(let b=1;b0;)a.push(s(o+b/n*d))}let m=u[0],y=a[a.length-1];const p=1/d,l=Ale(m[1],a);for(;y;){const b=s((m[0]+y[0])/2);b[0]-m[0]>=f&&Nle(m,b,y,p,l)>Mle?a.push(b):(m=y,u.push(y),a.pop()),y=a[a.length-1]}return u}function Ale(e,t){let n=e,i=e;const s=t.length;for(let o=0;oi&&(i=c)}return 1/(i-n)}function Nle(e,t,n,i,s){const o=Math.atan2(s*(n[1]-e[1]),i*(n[0]-e[0])),c=Math.atan2(s*(t[1]-e[1]),i*(t[0]-e[0]));return Math.abs(o-c)}function Wg(e){return e.length}function su(e){const t=new Map(e.map((n,i)=>[n,i]));return n=>t.get(n)}function n2({start:e,step:t,stop:n}){return(n-e)/t}function Cle(e,t){return Lb({maxbins:e,extent:t})}function Rle(e,t){const i=XD().domain(t).ticks(e),s=i[0].getTime(),o=i[i.length-1].getTime(),c=(o-s)/i.length;return{start:s,stop:o,step:c}}function Ple(e,t){return(e.time?Rle:Cle)(e.bins,t)}function Dle(e){let t=[],n=e.start,i=n+e.step;for(;i<=e.stop;)t.push({binStart:n,binEnd:i}),n=i,i+=e.step;return t}function jle(e,t){const n=Ule(e,t);return i=>[n(i[0]),n(i[1])]}function Ule(e,t,n=Math.floor){const i=[1,t],s=e,o=U4().domain(s).range(i);return o.clamp(!0),c=>{const d=o(c);return n(d)}}function YF(e,...t){return new Map(Array.from(e.entries()).filter(([n,i])=>!t.includes(n)))}function Hle(e,{start:t,step:n,stop:i},s=o=>`${o}`){const o=n2({start:t,step:n,stop:i}),c=`FLOOR((${e} - ${s(t)}) / ${s(n)})::INT`;return`LEAST(${s(o-1)}, ${c})::INT`}function zle({start:e,stop:t},n){return(t-e)/n}function $le(e){return e.replace(/\s+/g," ").trim()}class qle{constructor(){this.views=[]}remove(t){const n=this.views.findIndex(i=>i==t);n!==-1&&this.views.splice(n,1)}add(t){this.views.findIndex(i=>i==t)===-1&&this.views.push(t)}get passive(){return this.views.filter(t=>!t.isActive)}get active(){const t=this.views.find(n=>n.isActive);if(t)return t}get size(){return this.views.length}forEach(t){this.views.forEach(t)}[Symbol.iterator](){return this.views[Symbol.iterator]()}}class Ij{constructor(t){this.isActive=!1,this.linkTogetherWithOtherViews(t),this.onChangeListeners=new Set}linkTogetherWithOtherViews(t){this.falcon=t}onChange(t){return this.onChangeListeners.add(t),()=>this.onChangeListeners.delete(t)}addOnChangeListener(t){return this.onChange(t)}signalOnChange(t){this.onChangeListeners.forEach(n=>{n(t)})}markThisViewActive(){this.falcon.views.forEach(t=>{t.isActive=!1}),this.isActive=!0}}class Tl extends Ij{constructor(t){super(t),this.state={total:null,filter:null}}async all(){const t=await this.falcon.db.length(this.falcon.filters.size>0?this.falcon.filters:void 0);return this.state.total=t,this.state.filter=t,this.signalOnChange(this.state),this}async countFromActiveContinuous1D(t){const n=await this.falcon.index.get(this);if(n===void 0)throw Error("Cannot count for undefined index in 0D");if(!t)this.state.filter=n.noFilter.get(0);else{const i=n.filter.get(t[0]),s=n.filter.get(t[1]);this.state.filter=s-i}this.signalOnChange(this.state)}async countFromActiveCategorical1D(t,n){const i=await this.falcon.index.get(this);if(i===void 0)throw Error("Cannot count for undefined index in 0D");if(t===void 0)this.state.filter=i.noFilter.get(0);else{const s=su(n);let o=0;for(const c of t){const d=s(c);d&&(o+=i.filter.get(d))}this.state.filter=o}this.signalOnChange(this.state)}async attach(){this.falcon.views.add(this),await this.falcon.link()}async detach(){this.falcon.views.remove(this),this.falcon.index.delete(this)}}class ca extends Ij{constructor(t,n){super(t),this.dimension=n,this.state={total:null,filter:null,bin:null},this.toPixels=()=>[0,0]}async update(t){this.dimension=t,await this.falcon.link()}async createBins(){var t;if(((t=this.dimension)==null?void 0:t.range)===void 0&&(this.dimension.range=await this.falcon.db.range(this.dimension)),this.dimension.type==="continuous"){this.dimension.bins=this.dimension.bins??await this.falcon.db.estimateNumBins(this.dimension,200,15),this.dimension.binConfig=Ple(this.dimension,this.dimension.range);const{start:n,stop:i}=this.dimension.binConfig;this.toPixels=jle([n,i],this.dimension.resolution)}this.dimension.type==="continuous"?this.state.bin=Dle(this.dimension.binConfig):this.state.bin=this.dimension.range}async all(){await this.createBins();const t=await this.falcon.db.histogramView1D(this,this.falcon.filters.size>0?this.falcon.otherFilters(this):void 0);return this.state.total=t.noFilter.data,this.state.filter=t.filter.data,this.signalOnChange(this.state),this}async computeIndex(t=!1){(!this.isActive||t)&&(await this.falcon.views.forEach(async n=>{n instanceof ca&&(!("range"in n.dimension)||n.dimension.type==="continuous"&&!("binConfig"in n.dimension))&&await n.all()}),this.markThisViewActive(),this.falcon.index=this.falcon.db.falconIndexView1D(this,this.falcon.views.passive,this.falcon.passiveFilters))}async activate(){await this.computeIndex()}async select(t,n=!1){if(t)if(this.dimension.type==="continuous"){if(this.lastFilter&&this.lastFilter[0]===t[0]&&this.lastFilter[1]===t[1]&&n===!1)return;this.falcon.filters.set(this.dimension,t);let s=this.toPixels(t);this.isActive&&this.falcon.views.passive.forEach(async o=>{await o.countFromActiveContinuous1D(s)}),this.lastFilter=t}else this.falcon.filters.set(this.dimension,t),this.isActive&&this.falcon.views.passive.forEach(async i=>{await i.countFromActiveCategorical1D(t,this.dimension.range)}),this.lastFilter=t;else if(this.isActive)if(this.dimension.type==="continuous"){if(this.lastFilter===t)return;this.falcon.filters.delete(this.dimension),this.falcon.views.passive.forEach(async s=>{await s.countFromActiveContinuous1D()}),this.lastFilter=t}else this.falcon.filters.delete(this.dimension),this.falcon.views.passive.forEach(async i=>{await i.countFromActiveCategorical1D()}),this.lastFilter=t}async countFromActiveContinuous1D(t){const n=await this.falcon.index.get(this);if(n===void 0)throw Error("Index not defined for 1D passive view");if(!t)this.state.filter=n.noFilter.data;else{const i=n.filter.slice(t[0],null),o=n.filter.slice(t[1],null).sub(i);this.state.filter=o.data}this.signalOnChange(this.state)}async countFromActiveCategorical1D(t,n){const i=await this.falcon.index.get(this);if(i===void 0)throw Error("Index not defined for 1D passive view");if(!t)this.state.filter=i.noFilter.data;else{let s;this.dimension.type==="continuous"?s=Ss.allocCounts(n2(this.dimension.binConfig)):s=Ss.allocCounts(this.dimension.range.length),s.data.fill(0);const o=su(n);for(const c of t){const d=o(c);if(d){const f=i.filter.slice(d,null);s.addToItself(f)}}this.state.filter=s.data}this.signalOnChange(this.state)}async attach(){this.falcon.views.add(this),await this.falcon.link()}async detach(){this.falcon.views.remove(this),this.falcon.index.delete(this),this.isActive&&await this.falcon.link()}}class Vle{constructor(t,n){this.table=t,this.nameMap=n}castBins(t){return`${t}`}castTime(t){return t}getName(t){var i;let n=((i=this.nameMap)==null?void 0:i.get(t.name))??t.name;return t.type==="continuous"&&t.time&&(n=this.castTime(n)),n}async dimensionExists(t){const n=await this.query(`SELECT EXISTS (SELECT 0 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '${this.table}' AND COLUMN_NAME = '${t.name}') as _exists`),{_exists:i}=this.getASValues(n);return i}async tableExists(){const t=await this.query(`SELECT EXISTS (SELECT 0 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME = '${this.table}') as _exists`),{_exists:n}=this.getASValues(t);return n}async entries(t=0,n=1/0,i){const s=i?[...this.filtersToSQLWhereClauses(i).values()].join(" AND "):void 0;return await this.query(`SELECT * FROM ${this.table} ${s?`WHERE ${s}`:""} ${n>=0&&n<1/0?`LIMIT ${n}`:""} OFFSET ${t}`)}async estimateNumBins(t,n=200,i=15){if(await this.length()<=1)return 1;if(t.range){const o=await this.query(`SELECT STDDEV(${this.getName(t)}) AS standardDeviation FROM ${this.table}`),{standardDeviation:c}=this.getASValues(o),[d,f]=t.range,u=_J(d,f,c);return Math.min(u,n)}return i}async length(t){let n="";t&&(n=[...this.filtersToSQLWhereClauses(t).values()].join(" AND "));const i=await this.query(`SELECT count(*) AS _count FROM ${this.table} ${n?`WHERE ${n}`:""}`),{_count:s}=this.getASValues(i);return s}async range(t){const n=this.getName(t);if(t.type==="continuous"){const i=await this.query(`SELECT MIN(${n}) AS _min, MAX(${n}) AS _max FROM ${this.table}`),{_min:s,_max:o}=this.getASValues(i);return[Number(s),Number(o)]}else{const i=await this.query(`SELECT DISTINCT "${n}" AS _unique FROM ${this.table}`);let s=[];for(const{_unique:o}of i)s.push(o);return s.filter(o=>o!==null)}}async histogramView1D(t,n){let i,s,o=a=>a;if(t.dimension.type==="continuous"){const a=t.dimension.binConfig;i=n2(a),s=this.binSQL(t.dimension,a)}else i=Wg(t.dimension.range),s=this.binSQLCategorical(t.dimension,t.dimension.range),o=su(t.dimension.range);const c=Ss.allocCounts(i),d=n&&n.size>0,f=d?Ss.allocCounts(i):c,u=await this.query(`SELECT ${s.select} AS binIndex, count(*) AS binCount FROM ${this.table} WHERE ${s.where} GROUP BY binIndex`);for(const{binIndex:a,binCount:m}of u)c.set(o(a),m);if(d){const a=[...this.filtersToSQLWhereClauses(n).values()].join(" AND "),m=`SELECT ${s.select} AS binIndex, count(*) AS binCount FROM ${this.table} WHERE ${s.where} AND ${a} GROUP BY binIndex`,y=await this.query(m);console.log(t.dimension.name,m);for(const{binIndex:p,binCount:l}of y)f.set(p,l)}return{filter:f,noFilter:c}}falconIndexView1D(t,n,i){const s=performance.now(),o=this.filtersToSQLWhereClauses(i),c=new Map;if(t.dimension.type==="continuous"){const d=t.dimension.resolution,f=this.binSQLPixel(t.dimension,t.dimension.binConfig,d),u=d+1,a=[];n.forEach(m=>{const y=this.cubeSlice1DContinuous(m,o,f,u);a.push(y),c.set(m,y)}),Promise.all(a).then(()=>{console.info(`Build index: ${performance.now()-s}ms`)})}else{const d=this.binSQLCategorical(t.dimension,t.dimension.range),f=Wg(t.dimension.range),u=su(t.dimension.range),a=[];n.forEach(m=>{const y=this.cubeSlice1DCategorical(m,o,d,u,f);a.push(y),c.set(m,y)}),Promise.all(a).then(()=>{console.info(`Build index: ${performance.now()-s}ms`)})}return c}async cubeSlice1DCategorical(t,n,i,s,o){let c,d;const f=new Map(n);t instanceof Tl||t instanceof ca&&f.delete(t.dimension);const u=[...f.values()].join(" AND ");let a="",m=l=>l;const y=`CASE WHEN ${i.where} THEN ${i.select} ELSE -1 END AS "keyActive", count(*) AS cnt`;if(t instanceof Tl)d=Ss.allocCounts(o),c=Ss.allocCounts(1,[1]),a=`SELECT ${y} FROM ${this.table} ${u?`WHERE ${u}`:""} GROUP BY "keyActive"`;else if(t instanceof ca){let l,b;if(t.dimension.type==="continuous"){const L=t.dimension.binConfig;b=n2(L),l=this.binSQL(t.dimension,t.dimension.binConfig)}else m=su(t.dimension.range),b=Wg(t.dimension.range),l=this.binSQLCategorical(t.dimension,t.dimension.range);d=Ss.allocCounts(o*b,[o,b]),c=Ss.allocCounts(b,[b]),a=`SELECT ${y}, ${l.select} AS key FROM ${this.table} WHERE ${l.where} ${u?`AND ${u}`:""} GROUP BY "keyActive", key`}else throw Error("no 2d view here");const p=await this.query(a);if(t instanceof Tl)for(const{keyActive:l,cnt:b}of p){const L=s(l);L>=0&&d.set(L,b),c.increment([0],b)}else if(t instanceof ca)for(const{keyActive:l,key:b,cnt:L}of p){const E=s(l),S=m(b);E>=0&&d.set(E,S,L),c.increment([S],L)}else throw Error();return{noFilter:c,filter:d}}async cubeSlice1DContinuous(t,n,i,s){let o,c;const d=new Map(n);t instanceof Tl||t instanceof ca&&d.delete(t.dimension);const f=[...d.values()].join(" AND ");let u,a=p=>p;const m=`CASE WHEN ${i.where} THEN ${i.select} ELSE -1 END AS "keyActive", count(*) AS cnt`;if(t instanceof Tl)c=Ss.allocCumulative(s),o=Ss.allocCounts(1,[1]),u=`SELECT ${m} FROM ${this.table} ${f?`WHERE ${f}`:""} GROUP BY "keyActive"`;else if(t instanceof ca){let p,l;if(t.dimension.type==="continuous"){const b=t.dimension.binConfig;p=this.binSQL(t.dimension,b),l=n2(b)}else p=this.binSQLCategorical(t.dimension,t.dimension.range),l=Wg(t.dimension.range),a=su(t.dimension.range);c=Ss.allocCumulative(s*l,[s,l]),o=Ss.allocCounts(l,[l]),u=`SELECT ${m}, ${p.select} AS key FROM ${this.table} WHERE ${p.where} ${f?`AND ${f}`:""} GROUP BY "keyActive", key`}else throw Error("only 0D and 1D views");const y=await this.query(u);if(t instanceof Tl){for(const{keyActive:p,cnt:l}of y)p>=0&&c.set(p+1,l),o.increment([0],l);c.cumulativeSum()}else if(t instanceof ca){for(const{keyActive:p,key:l,cnt:b}of y){const L=a(l);p>=0&&c.set(p+1,L,b),o.increment([L],b)}for(let p=0;p{s!==null&&(n+=`'${s}', `)}),n+=")",t.findIndex(s=>s===null)!==-1&&(n+=` OR "${e}" IS NULL`),n}class Gle extends Vle{constructor(t,n,i,s=encodeURIComponent){super(n,i),this.url=t,this.escapeQuery=s,this.blocking=!1}async query(t){const n=performance.now(),i=this.escapeQuery(t),s=await fetch(`${this.url}${i}`);if(!s.ok)throw new Error(`HTTP ${s.status}: ${s.statusText}`);const o=await s.arrayBuffer(),c=k7(o);return console.info(`%c${$le(t)}`,"color: #bbb",` Rows:`,c.numRows,"Query time:",performance.now()-n,"ms."),c}}var FL={},Wle={get exports(){return FL},set exports(e){FL=e}};const Yle=wJ(gJ);(function(e,t){(function(i,s){e.exports=s(Yle)})(yJ,function(n){return(()=>{var i={2190:c=>{c.exports=function(f,u,a){if(f.filter)return f.filter(u,a);if(f==null)throw new TypeError;if(typeof u!="function")throw new TypeError;for(var m=[],y=0;y{var u=f(2190);c.exports=function(){return u(["BigInt64Array","BigUint64Array","Float32Array","Float64Array","Int16Array","Int32Array","Int8Array","Uint16Array","Uint32Array","Uint8Array","Uint8ClampedArray"],function(m){return typeof f.g[m]=="function"})}},7123:(c,d,f)=>{f.r(d),f.d(d,{DbCon:()=>ht,default:()=>ge,Client:()=>L.Client,Processor:()=>L.Processor});var u=f(6729),a=f.n(u),m=f(2003),y=f(9539),p=f.n(y),l=f(2818),b=f(2607),L=f(4221),E=f(9262),S=f(5141),x=f(2033),O={};for(const V in l)["default","DbCon","Client","Processor"].indexOf(V)<0&&(O[V]=()=>l[V]);f.d(d,O);var F=f(4494),O={};for(const V in F)["default","DbCon","Client","Processor"].indexOf(V)<0&&(O[V]=()=>F[V]);f.d(d,O);var k=f(1396),O={};for(const V in k)["default","DbCon","Client","Processor"].indexOf(V)<0&&(O[V]=()=>k[V]);f.d(d,O);var O={};for(const V in b)["default","DbCon","Client","Processor"].indexOf(V)<0&&(O[V]=()=>b[V]);f.d(d,O);var M=f(3962),O={};for(const V in M)["default","DbCon","Client","Processor"].indexOf(V)<0&&(O[V]=()=>M[V]);f.d(d,O);var C=f(8764).Buffer;function P(V,q){var D=Object.keys(V);if(Object.getOwnPropertySymbols){var K=Object.getOwnPropertySymbols(V);q&&(K=K.filter(function(J){return Object.getOwnPropertyDescriptor(V,J).enumerable})),D.push.apply(D,K)}return D}function j(V){for(var q=1;qV.length)&&(q=V.length);for(var D=0,K=new Array(q);D"u"||!(Symbol.iterator in Object(V)))){var D=[],K=!0,J=!1,re=void 0;try{for(var se=V[Symbol.iterator](),_e;!(K=(_e=se.next()).done)&&(D.push(_e.value),!(q&&D.length===q));K=!0);}catch(be){J=!0,re=be}finally{try{!K&&se.return!=null&&se.return()}finally{if(J)throw re}}return D}}function X(V){if(Array.isArray(V))return V}function G(V,q){if(!(V instanceof q))throw new TypeError("Cannot call a class as a function")}function oe(V,q){for(var D=0;D3&&arguments[3]!==void 0?arguments[3]:2;K instanceof b.TPixel||(K=new b.TPixel(K));var se=!0,_e=(q._nonce++).toString();return q._client[q._lastRenderCon].get_result_row_for_pixel(q._sessionId[q._lastRenderCon],D,K,J,se,re,_e).then(function(be){be=Array.isArray(be)?be.pixel_rows:[be];for(var Ke={isImage:!1,eliminateNullRows:!1,query:"pixel request",queryId:-2},It=(0,S.Z)(q._logging,q.updateQueryTimes),Et=be.length,et=0;et0&&arguments[0]!==void 0?arguments[0]:{},K=arguments.length>1?arguments[1]:void 0;return K.catch(function(J){throw q._logging&&D.query&&console.error(D.query,` `,J),J}).then(function(J){var re=(0,S.Z)(q._logging,q.updateQueryTimes),se=re(D,q._datumEnum,J);return se})},this}return he(V,[{key:"removeConnection",value:function(D){if(D<0||D>=this.numConnections){var K={msg:"Remove connection id invalid"};throw K}this._client.splice(D,1),this._sessionId.splice(D,1),this._numConnections--}},{key:"xhrWithCredentials",value:function(D){Me.withCredentials=Boolean(D)}},{key:"initClients",value:function(){var D=Array.isArray(this._host)&&Array.isArray(this._port)&&Array.isArray(this._dbName);if(!D)throw new Error("Host, port, and dbName must be arrays.");if(this._client=[],this._sessionId=[],this._host[0]){if(!this._port[0])throw new Error("Please enter a port.")}else throw new Error("Please enter a host name.");var K=this._host.length;if(K<1)throw new Error("Must have at least one server to connect to.");if(K!==this._port.length)throw new Error("Array connection parameters must be of equal length.");this._protocol||(this._protocol=this._host.map(function(){return window.location.protocol.replace(":","")}));for(var J=this.getEndpoints(),re=[],se=0;se"u")return this._logging;if(typeof D!="boolean")return"logging can only be set with boolean values";this._logging=D;var K=D?"enabled":"disabled";return"SQL logging is now ".concat(K)}},{key:"platform",value:function(D){return arguments.length?(this._platform=D,this):this._platform}},{key:"numConnections",value:function(){return this._numConnections}},{key:"protocol",value:function(D){return arguments.length?(this._protocol=de(D),this):this._protocol}},{key:"disableAutoReconnect",value:function(D){return arguments.length?(this._disableAutoReconnect=D,this):this._disableAutoReconnect}},{key:"getEndpoints",value:function(){var D=this;return this._host.map(function(K,J){return"".concat(D._protocol[J],"://").concat(K,":").concat(D._port[J])})}},{key:"setLicenseKey",value:function(D,K){var J=K.protocol,re=K.host,se=K.port,_e=Array.isArray(this._client)&&this._client[0],be=this._sessionId&&this._sessionId[0];if(!_e){var Ke="".concat(J,"://").concat(re,":").concat(se);_e=pt(Ke,this._useBinaryProtocol),be=""}return _e.set_license_key(be,D,this._nonce++)}},{key:"getLicenseClaims",value:function(D){var K=D.protocol,J=D.host,re=D.port,se=Array.isArray(this._client)&&this._client[0],_e=this._sessionId&&this._sessionId[0];if(!se){var be="".concat(K,"://").concat(J,":").concat(re);se=pt(be,this._useBinaryProtocol),_e=""}return se.get_license_claims(_e,this._nonce++)}},{key:"isTimeoutError",value:function(D){return D instanceof b.TDBException&&(String(D.error_msg).indexOf("Session not valid.")!==-1||String(D.error_msg).indexOf("User should re-authenticate.")!==-1)}}]),V}();const ge=ht},2033:(c,d,f)=>{f.d(d,{Dq:()=>a,HP:()=>m,RK:()=>y,kS:()=>p});var u=f(2607),a=function(b){return new u.TCopyParams(b)},m=function(b,L){return b.forEach(function(E,S){L[S].col_name=E.clean_col_name,L[S].col_type.encoding=E.col_type.encoding,L[S].col_type.precision=E.col_type.precision,L[S].col_type.comp_param=E.col_type.comp_param,L[S].col_type.scale=E.col_type.scale,L[S].col_type.type=E.col_type.type}),L};function y(l,b){var L=Math.pow(10,b-3),E=l/L;return E}function p(l){return l.toNumber?Boolean(l.toNumber(!0)):Boolean(l)}},5141:(c,d,f)=>{f.d(d,{Z:()=>y});var u=f(2033);function a(p,l,b){var L={fields:[],results:[]},E=p.row_desc.length,S=typeof p.columns[0]>"u"?0:p.columns[0].nulls.length;L.fields=p.row_desc.map(function(X){return{name:X.col_name,type:b[X.col_type.type],is_array:X.col_type.is_array}});for(var x=0;x"u"?null:b.conId,O=typeof b.estimatedQueryTime>"u"?null:b.estimatedQueryTime),E.execution_time_ms&&M!==null&&O!==null&&l(M,k,O,E.execution_time_ms),p&&E.execution_time_ms&&console.log(F,"on Server",M,"- Execution Time:",E.execution_time_ms,"ms, Total Time:",E.total_time_ms,"ms, Real Time:",b.startTime?Date.now()-b.startTime:void 0,"ms"),S)return E;var C=null;if(!E.row_set)throw new Error("No result to process");return E.row_set.is_columnar?C=a(E.row_set,x,L):C=m(E.row_set,x,L),C.timing={execution_time_ms:E.execution_time_ms,total_time_ms:E.total_time_ms},b.returnTiming?C:C.results}}},9742:(c,d)=>{d.byteLength=b,d.toByteArray=E,d.fromByteArray=F;for(var f=[],u=[],a=typeof Uint8Array<"u"?Uint8Array:Array,m="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",y=0,p=m.length;y0)throw new Error("Invalid string. Length must be a multiple of 4");var O=k.indexOf("=");O===-1&&(O=M);var C=O===M?0:4-O%4;return[O,C]}function b(k){var M=l(k),O=M[0],C=M[1];return(O+C)*3/4-C}function L(k,M,O){return(M+O)*3/4-O}function E(k){var M,O=l(k),C=O[0],P=O[1],j=new a(L(k,C,P)),R=0,H=P>0?C-4:C,z;for(z=0;z>16&255,j[R++]=M>>8&255,j[R++]=M&255;return P===2&&(M=u[k.charCodeAt(z)]<<2|u[k.charCodeAt(z+1)]>>4,j[R++]=M&255),P===1&&(M=u[k.charCodeAt(z)]<<10|u[k.charCodeAt(z+1)]<<4|u[k.charCodeAt(z+2)]>>2,j[R++]=M>>8&255,j[R++]=M&255),j}function S(k){return f[k>>18&63]+f[k>>12&63]+f[k>>6&63]+f[k&63]}function x(k,M,O){for(var C,P=[],j=M;jH?H:R+j));return C===1?(M=k[O-1],P.push(f[M>>2]+f[M<<4&63]+"==")):C===2&&(M=(k[O-2]<<8)+k[O-1],P.push(f[M>>10]+f[M>>4&63]+f[M<<2&63]+"=")),P.join("")}},3818:(c,d)=>{Object.defineProperty(d,"__esModule",{value:!0});var f=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(p){return typeof p}:function(p){return p&&typeof Symbol=="function"&&p.constructor===Symbol&&p!==Symbol.prototype?"symbol":typeof p},u=typeof window<"u"&&typeof window.document<"u",a=(typeof self>"u"?"undefined":f(self))==="object"&&self.constructor&&self.constructor.name==="DedicatedWorkerGlobalScope",m=typeof process<"u"&&process.versions!=null&&process.versions.node!=null,y=function(){return typeof window<"u"&&window.name==="nodejs"||navigator.userAgent.includes("Node.js")||navigator.userAgent.includes("jsdom")};d.isBrowser=u,d.isWebWorker=a,d.isNode=m,d.isJsDom=y},8764:(c,d,f)=>{/*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT */const u=f(9742),a=f(645),m=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;d.Buffer=b,d.SlowBuffer=j,d.INSPECT_MAX_BYTES=50;const y=2147483647;d.kMaxLength=y,b.TYPED_ARRAY_SUPPORT=p(),!b.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function p(){try{const N=new Uint8Array(1),I={foo:function(){return 42}};return Object.setPrototypeOf(I,Uint8Array.prototype),Object.setPrototypeOf(N,I),N.foo()===42}catch{return!1}}Object.defineProperty(b.prototype,"parent",{enumerable:!0,get:function(){if(b.isBuffer(this))return this.buffer}}),Object.defineProperty(b.prototype,"offset",{enumerable:!0,get:function(){if(b.isBuffer(this))return this.byteOffset}});function l(N){if(N>y)throw new RangeError('The value "'+N+'" is invalid for option "size"');const I=new Uint8Array(N);return Object.setPrototypeOf(I,b.prototype),I}function b(N,I,A){if(typeof N=="number"){if(typeof I=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return x(N)}return L(N,I,A)}b.poolSize=8192;function L(N,I,A){if(typeof N=="string")return F(N,I);if(ArrayBuffer.isView(N))return M(N);if(N==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof N);if(ln(N,ArrayBuffer)||N&&ln(N.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ln(N,SharedArrayBuffer)||N&&ln(N.buffer,SharedArrayBuffer)))return O(N,I,A);if(typeof N=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const U=N.valueOf&&N.valueOf();if(U!=null&&U!==N)return b.from(U,I,A);const Z=C(N);if(Z)return Z;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof N[Symbol.toPrimitive]=="function")return b.from(N[Symbol.toPrimitive]("string"),I,A);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof N)}b.from=function(N,I,A){return L(N,I,A)},Object.setPrototypeOf(b.prototype,Uint8Array.prototype),Object.setPrototypeOf(b,Uint8Array);function E(N){if(typeof N!="number")throw new TypeError('"size" argument must be of type number');if(N<0)throw new RangeError('The value "'+N+'" is invalid for option "size"')}function S(N,I,A){return E(N),N<=0?l(N):I!==void 0?typeof A=="string"?l(N).fill(I,A):l(N).fill(I):l(N)}b.alloc=function(N,I,A){return S(N,I,A)};function x(N){return E(N),l(N<0?0:P(N)|0)}b.allocUnsafe=function(N){return x(N)},b.allocUnsafeSlow=function(N){return x(N)};function F(N,I){if((typeof I!="string"||I==="")&&(I="utf8"),!b.isEncoding(I))throw new TypeError("Unknown encoding: "+I);const A=R(N,I)|0;let U=l(A);const Z=U.write(N,I);return Z!==A&&(U=U.slice(0,Z)),U}function k(N){const I=N.length<0?0:P(N.length)|0,A=l(I);for(let U=0;U=y)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+y.toString(16)+" bytes");return N|0}function j(N){return+N!=N&&(N=0),b.alloc(+N)}b.isBuffer=function(I){return I!=null&&I._isBuffer===!0&&I!==b.prototype},b.compare=function(I,A){if(ln(I,Uint8Array)&&(I=b.from(I,I.offset,I.byteLength)),ln(A,Uint8Array)&&(A=b.from(A,A.offset,A.byteLength)),!b.isBuffer(I)||!b.isBuffer(A))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(I===A)return 0;let U=I.length,Z=A.length;for(let ee=0,ne=Math.min(U,Z);eeZ.length?(b.isBuffer(ne)||(ne=b.from(ne)),ne.copy(Z,ee)):Uint8Array.prototype.set.call(Z,ne,ee);else if(b.isBuffer(ne))ne.copy(Z,ee);else throw new TypeError('"list" argument must be an Array of Buffers');ee+=ne.length}return Z};function R(N,I){if(b.isBuffer(N))return N.length;if(ArrayBuffer.isView(N)||ln(N,ArrayBuffer))return N.byteLength;if(typeof N!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof N);const A=N.length,U=arguments.length>2&&arguments[2]===!0;if(!U&&A===0)return 0;let Z=!1;for(;;)switch(I){case"ascii":case"latin1":case"binary":return A;case"utf8":case"utf-8":return Yi(N).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A*2;case"hex":return A>>>1;case"base64":return jn(N).length;default:if(Z)return U?-1:Yi(N).length;I=(""+I).toLowerCase(),Z=!0}}b.byteLength=R;function H(N,I,A){let U=!1;if((I===void 0||I<0)&&(I=0),I>this.length||((A===void 0||A>this.length)&&(A=this.length),A<=0)||(A>>>=0,I>>>=0,A<=I))return"";for(N||(N="utf8");;)switch(N){case"hex":return pt(this,I,A);case"utf8":case"utf-8":return Oe(this,I,A);case"ascii":return Fe(this,I,A);case"latin1":case"binary":return Ge(this,I,A);case"base64":return ie(this,I,A);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ht(this,I,A);default:if(U)throw new TypeError("Unknown encoding: "+N);N=(N+"").toLowerCase(),U=!0}}b.prototype._isBuffer=!0;function z(N,I,A){const U=N[I];N[I]=N[A],N[A]=U}b.prototype.swap16=function(){const I=this.length;if(I%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let A=0;AA&&(I+=" ... "),""},m&&(b.prototype[m]=b.prototype.inspect),b.prototype.compare=function(I,A,U,Z,ee){if(ln(I,Uint8Array)&&(I=b.from(I,I.offset,I.byteLength)),!b.isBuffer(I))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof I);if(A===void 0&&(A=0),U===void 0&&(U=I?I.length:0),Z===void 0&&(Z=0),ee===void 0&&(ee=this.length),A<0||U>I.length||Z<0||ee>this.length)throw new RangeError("out of range index");if(Z>=ee&&A>=U)return 0;if(Z>=ee)return-1;if(A>=U)return 1;if(A>>>=0,U>>>=0,Z>>>=0,ee>>>=0,this===I)return 0;let ne=ee-Z,Be=U-A;const je=Math.min(ne,Be),Ue=this.slice(Z,ee),Ye=I.slice(A,U);for(let Xe=0;Xe2147483647?A=2147483647:A<-2147483648&&(A=-2147483648),A=+A,cl(A)&&(A=Z?0:N.length-1),A<0&&(A=N.length+A),A>=N.length){if(Z)return-1;A=N.length-1}else if(A<0)if(Z)A=0;else return-1;if(typeof I=="string"&&(I=b.from(I,U)),b.isBuffer(I))return I.length===0?-1:$(N,I,A,U,Z);if(typeof I=="number")return I=I&255,typeof Uint8Array.prototype.indexOf=="function"?Z?Uint8Array.prototype.indexOf.call(N,I,A):Uint8Array.prototype.lastIndexOf.call(N,I,A):$(N,[I],A,U,Z);throw new TypeError("val must be string, number or Buffer")}function $(N,I,A,U,Z){let ee=1,ne=N.length,Be=I.length;if(U!==void 0&&(U=String(U).toLowerCase(),U==="ucs2"||U==="ucs-2"||U==="utf16le"||U==="utf-16le")){if(N.length<2||I.length<2)return-1;ee=2,ne/=2,Be/=2,A/=2}function je(Ye,Xe){return ee===1?Ye[Xe]:Ye.readUInt16BE(Xe*ee)}let Ue;if(Z){let Ye=-1;for(Ue=A;Uene&&(A=ne-Be),Ue=A;Ue>=0;Ue--){let Ye=!0;for(let Xe=0;XeZ&&(U=Z)):U=Z;const ee=I.length;U>ee/2&&(U=ee/2);let ne;for(ne=0;ne>>0,isFinite(U)?(U=U>>>0,Z===void 0&&(Z="utf8")):(Z=U,U=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const ee=this.length-A;if((U===void 0||U>ee)&&(U=ee),I.length>0&&(U<0||A<0)||A>this.length)throw new RangeError("Attempt to write outside buffer bounds");Z||(Z="utf8");let ne=!1;for(;;)switch(Z){case"hex":return W(this,I,A,U);case"utf8":case"utf-8":return X(this,I,A,U);case"ascii":case"latin1":case"binary":return G(this,I,A,U);case"base64":return oe(this,I,A,U);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return he(this,I,A,U);default:if(ne)throw new TypeError("Unknown encoding: "+Z);Z=(""+Z).toLowerCase(),ne=!0}},b.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function ie(N,I,A){return I===0&&A===N.length?u.fromByteArray(N):u.fromByteArray(N.slice(I,A))}function Oe(N,I,A){A=Math.min(N.length,A);const U=[];let Z=I;for(;Z239?4:ee>223?3:ee>191?2:1;if(Z+Be<=A){let je,Ue,Ye,Xe;switch(Be){case 1:ee<128&&(ne=ee);break;case 2:je=N[Z+1],(je&192)===128&&(Xe=(ee&31)<<6|je&63,Xe>127&&(ne=Xe));break;case 3:je=N[Z+1],Ue=N[Z+2],(je&192)===128&&(Ue&192)===128&&(Xe=(ee&15)<<12|(je&63)<<6|Ue&63,Xe>2047&&(Xe<55296||Xe>57343)&&(ne=Xe));break;case 4:je=N[Z+1],Ue=N[Z+2],Ye=N[Z+3],(je&192)===128&&(Ue&192)===128&&(Ye&192)===128&&(Xe=(ee&15)<<18|(je&63)<<12|(Ue&63)<<6|Ye&63,Xe>65535&&Xe<1114112&&(ne=Xe))}}ne===null?(ne=65533,Be=1):ne>65535&&(ne-=65536,U.push(ne>>>10&1023|55296),ne=56320|ne&1023),U.push(ne),Z+=Be}return Me(U)}const de=4096;function Me(N){const I=N.length;if(I<=de)return String.fromCharCode.apply(String,N);let A="",U=0;for(;UU)&&(A=U);let Z="";for(let ee=I;eeU&&(I=U),A<0?(A+=U,A<0&&(A=0)):A>U&&(A=U),AA)throw new RangeError("Trying to access beyond buffer length")}b.prototype.readUintLE=b.prototype.readUIntLE=function(I,A,U){I=I>>>0,A=A>>>0,U||ge(I,A,this.length);let Z=this[I],ee=1,ne=0;for(;++ne>>0,A=A>>>0,U||ge(I,A,this.length);let Z=this[I+--A],ee=1;for(;A>0&&(ee*=256);)Z+=this[I+--A]*ee;return Z},b.prototype.readUint8=b.prototype.readUInt8=function(I,A){return I=I>>>0,A||ge(I,1,this.length),this[I]},b.prototype.readUint16LE=b.prototype.readUInt16LE=function(I,A){return I=I>>>0,A||ge(I,2,this.length),this[I]|this[I+1]<<8},b.prototype.readUint16BE=b.prototype.readUInt16BE=function(I,A){return I=I>>>0,A||ge(I,2,this.length),this[I]<<8|this[I+1]},b.prototype.readUint32LE=b.prototype.readUInt32LE=function(I,A){return I=I>>>0,A||ge(I,4,this.length),(this[I]|this[I+1]<<8|this[I+2]<<16)+this[I+3]*16777216},b.prototype.readUint32BE=b.prototype.readUInt32BE=function(I,A){return I=I>>>0,A||ge(I,4,this.length),this[I]*16777216+(this[I+1]<<16|this[I+2]<<8|this[I+3])},b.prototype.readBigUInt64LE=Ts(function(I){I=I>>>0,Et(I,"offset");const A=this[I],U=this[I+7];(A===void 0||U===void 0)&&et(I,this.length-8);const Z=A+this[++I]*2**8+this[++I]*2**16+this[++I]*2**24,ee=this[++I]+this[++I]*2**8+this[++I]*2**16+U*2**24;return BigInt(Z)+(BigInt(ee)<>>0,Et(I,"offset");const A=this[I],U=this[I+7];(A===void 0||U===void 0)&&et(I,this.length-8);const Z=A*2**24+this[++I]*2**16+this[++I]*2**8+this[++I],ee=this[++I]*2**24+this[++I]*2**16+this[++I]*2**8+U;return(BigInt(Z)<>>0,A=A>>>0,U||ge(I,A,this.length);let Z=this[I],ee=1,ne=0;for(;++ne=ee&&(Z-=Math.pow(2,8*A)),Z},b.prototype.readIntBE=function(I,A,U){I=I>>>0,A=A>>>0,U||ge(I,A,this.length);let Z=A,ee=1,ne=this[I+--Z];for(;Z>0&&(ee*=256);)ne+=this[I+--Z]*ee;return ee*=128,ne>=ee&&(ne-=Math.pow(2,8*A)),ne},b.prototype.readInt8=function(I,A){return I=I>>>0,A||ge(I,1,this.length),this[I]&128?(255-this[I]+1)*-1:this[I]},b.prototype.readInt16LE=function(I,A){I=I>>>0,A||ge(I,2,this.length);const U=this[I]|this[I+1]<<8;return U&32768?U|4294901760:U},b.prototype.readInt16BE=function(I,A){I=I>>>0,A||ge(I,2,this.length);const U=this[I+1]|this[I]<<8;return U&32768?U|4294901760:U},b.prototype.readInt32LE=function(I,A){return I=I>>>0,A||ge(I,4,this.length),this[I]|this[I+1]<<8|this[I+2]<<16|this[I+3]<<24},b.prototype.readInt32BE=function(I,A){return I=I>>>0,A||ge(I,4,this.length),this[I]<<24|this[I+1]<<16|this[I+2]<<8|this[I+3]},b.prototype.readBigInt64LE=Ts(function(I){I=I>>>0,Et(I,"offset");const A=this[I],U=this[I+7];(A===void 0||U===void 0)&&et(I,this.length-8);const Z=this[I+4]+this[I+5]*2**8+this[I+6]*2**16+(U<<24);return(BigInt(Z)<>>0,Et(I,"offset");const A=this[I],U=this[I+7];(A===void 0||U===void 0)&&et(I,this.length-8);const Z=(A<<24)+this[++I]*2**16+this[++I]*2**8+this[++I];return(BigInt(Z)<>>0,A||ge(I,4,this.length),a.read(this,I,!0,23,4)},b.prototype.readFloatBE=function(I,A){return I=I>>>0,A||ge(I,4,this.length),a.read(this,I,!1,23,4)},b.prototype.readDoubleLE=function(I,A){return I=I>>>0,A||ge(I,8,this.length),a.read(this,I,!0,52,8)},b.prototype.readDoubleBE=function(I,A){return I=I>>>0,A||ge(I,8,this.length),a.read(this,I,!1,52,8)};function V(N,I,A,U,Z,ee){if(!b.isBuffer(N))throw new TypeError('"buffer" argument must be a Buffer instance');if(I>Z||IN.length)throw new RangeError("Index out of range")}b.prototype.writeUintLE=b.prototype.writeUIntLE=function(I,A,U,Z){if(I=+I,A=A>>>0,U=U>>>0,!Z){const Be=Math.pow(2,8*U)-1;V(this,I,A,U,Be,0)}let ee=1,ne=0;for(this[A]=I&255;++ne>>0,U=U>>>0,!Z){const Be=Math.pow(2,8*U)-1;V(this,I,A,U,Be,0)}let ee=U-1,ne=1;for(this[A+ee]=I&255;--ee>=0&&(ne*=256);)this[A+ee]=I/ne&255;return A+U},b.prototype.writeUint8=b.prototype.writeUInt8=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,1,255,0),this[A]=I&255,A+1},b.prototype.writeUint16LE=b.prototype.writeUInt16LE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,2,65535,0),this[A]=I&255,this[A+1]=I>>>8,A+2},b.prototype.writeUint16BE=b.prototype.writeUInt16BE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,2,65535,0),this[A]=I>>>8,this[A+1]=I&255,A+2},b.prototype.writeUint32LE=b.prototype.writeUInt32LE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,4,4294967295,0),this[A+3]=I>>>24,this[A+2]=I>>>16,this[A+1]=I>>>8,this[A]=I&255,A+4},b.prototype.writeUint32BE=b.prototype.writeUInt32BE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,4,4294967295,0),this[A]=I>>>24,this[A+1]=I>>>16,this[A+2]=I>>>8,this[A+3]=I&255,A+4};function q(N,I,A,U,Z){It(I,U,Z,N,A,7);let ee=Number(I&BigInt(4294967295));N[A++]=ee,ee=ee>>8,N[A++]=ee,ee=ee>>8,N[A++]=ee,ee=ee>>8,N[A++]=ee;let ne=Number(I>>BigInt(32)&BigInt(4294967295));return N[A++]=ne,ne=ne>>8,N[A++]=ne,ne=ne>>8,N[A++]=ne,ne=ne>>8,N[A++]=ne,A}function D(N,I,A,U,Z){It(I,U,Z,N,A,7);let ee=Number(I&BigInt(4294967295));N[A+7]=ee,ee=ee>>8,N[A+6]=ee,ee=ee>>8,N[A+5]=ee,ee=ee>>8,N[A+4]=ee;let ne=Number(I>>BigInt(32)&BigInt(4294967295));return N[A+3]=ne,ne=ne>>8,N[A+2]=ne,ne=ne>>8,N[A+1]=ne,ne=ne>>8,N[A]=ne,A+8}b.prototype.writeBigUInt64LE=Ts(function(I,A=0){return q(this,I,A,BigInt(0),BigInt("0xffffffffffffffff"))}),b.prototype.writeBigUInt64BE=Ts(function(I,A=0){return D(this,I,A,BigInt(0),BigInt("0xffffffffffffffff"))}),b.prototype.writeIntLE=function(I,A,U,Z){if(I=+I,A=A>>>0,!Z){const je=Math.pow(2,8*U-1);V(this,I,A,U,je-1,-je)}let ee=0,ne=1,Be=0;for(this[A]=I&255;++ee>0)-Be&255;return A+U},b.prototype.writeIntBE=function(I,A,U,Z){if(I=+I,A=A>>>0,!Z){const je=Math.pow(2,8*U-1);V(this,I,A,U,je-1,-je)}let ee=U-1,ne=1,Be=0;for(this[A+ee]=I&255;--ee>=0&&(ne*=256);)I<0&&Be===0&&this[A+ee+1]!==0&&(Be=1),this[A+ee]=(I/ne>>0)-Be&255;return A+U},b.prototype.writeInt8=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,1,127,-128),I<0&&(I=255+I+1),this[A]=I&255,A+1},b.prototype.writeInt16LE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,2,32767,-32768),this[A]=I&255,this[A+1]=I>>>8,A+2},b.prototype.writeInt16BE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,2,32767,-32768),this[A]=I>>>8,this[A+1]=I&255,A+2},b.prototype.writeInt32LE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,4,2147483647,-2147483648),this[A]=I&255,this[A+1]=I>>>8,this[A+2]=I>>>16,this[A+3]=I>>>24,A+4},b.prototype.writeInt32BE=function(I,A,U){return I=+I,A=A>>>0,U||V(this,I,A,4,2147483647,-2147483648),I<0&&(I=4294967295+I+1),this[A]=I>>>24,this[A+1]=I>>>16,this[A+2]=I>>>8,this[A+3]=I&255,A+4},b.prototype.writeBigInt64LE=Ts(function(I,A=0){return q(this,I,A,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),b.prototype.writeBigInt64BE=Ts(function(I,A=0){return D(this,I,A,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function K(N,I,A,U,Z,ee){if(A+U>N.length)throw new RangeError("Index out of range");if(A<0)throw new RangeError("Index out of range")}function J(N,I,A,U,Z){return I=+I,A=A>>>0,Z||K(N,I,A,4),a.write(N,I,A,U,23,4),A+4}b.prototype.writeFloatLE=function(I,A,U){return J(this,I,A,!0,U)},b.prototype.writeFloatBE=function(I,A,U){return J(this,I,A,!1,U)};function re(N,I,A,U,Z){return I=+I,A=A>>>0,Z||K(N,I,A,8),a.write(N,I,A,U,52,8),A+8}b.prototype.writeDoubleLE=function(I,A,U){return re(this,I,A,!0,U)},b.prototype.writeDoubleBE=function(I,A,U){return re(this,I,A,!1,U)},b.prototype.copy=function(I,A,U,Z){if(!b.isBuffer(I))throw new TypeError("argument should be a Buffer");if(U||(U=0),!Z&&Z!==0&&(Z=this.length),A>=I.length&&(A=I.length),A||(A=0),Z>0&&Z=this.length)throw new RangeError("Index out of range");if(Z<0)throw new RangeError("sourceEnd out of bounds");Z>this.length&&(Z=this.length),I.length-A>>0,U=U===void 0?this.length:U>>>0,I||(I=0);let ee;if(typeof I=="number")for(ee=A;ee4294967296?Z=be(String(A)):typeof A=="bigint"&&(Z=String(A),(A>BigInt(2)**BigInt(32)||A<-(BigInt(2)**BigInt(32)))&&(Z=be(Z)),Z+="n"),U+=` It must be ${I}. Received ${Z}`,U},RangeError);function be(N){let I="",A=N.length;const U=N[0]==="-"?1:0;for(;A>=U+4;A-=3)I=`_${N.slice(A-3,A)}${I}`;return`${N.slice(0,A)}${I}`}function Ke(N,I,A){Et(I,"offset"),(N[I]===void 0||N[I+A]===void 0)&&et(I,N.length-(A+1))}function It(N,I,A,U,Z,ee){if(N>A||N3?I===0||I===BigInt(0)?Be=`>= 0${ne} and < 2${ne} ** ${(ee+1)*8}${ne}`:Be=`>= -(2${ne} ** ${(ee+1)*8-1}${ne}) and < 2 ** ${(ee+1)*8-1}${ne}`:Be=`>= ${I}${ne} and <= ${A}${ne}`,new se.ERR_OUT_OF_RANGE("value",Be,N)}Ke(U,Z,ee)}function Et(N,I){if(typeof N!="number")throw new se.ERR_INVALID_ARG_TYPE(I,"number",N)}function et(N,I,A){throw Math.floor(N)!==N?(Et(N,A),new se.ERR_OUT_OF_RANGE(A||"offset","an integer",N)):I<0?new se.ERR_BUFFER_OUT_OF_BOUNDS:new se.ERR_OUT_OF_RANGE(A||"offset",`>= ${A?1:0} and <= ${I}`,N)}const Zt=/[^+/0-9A-Za-z-_]/g;function kn(N){if(N=N.split("=")[0],N=N.trim().replace(Zt,""),N.length<2)return"";for(;N.length%4!==0;)N=N+"=";return N}function Yi(N,I){I=I||1/0;let A;const U=N.length;let Z=null;const ee=[];for(let ne=0;ne55295&&A<57344){if(!Z){if(A>56319){(I-=3)>-1&&ee.push(239,191,189);continue}else if(ne+1===U){(I-=3)>-1&&ee.push(239,191,189);continue}Z=A;continue}if(A<56320){(I-=3)>-1&&ee.push(239,191,189),Z=A;continue}A=(Z-55296<<10|A-56320)+65536}else Z&&(I-=3)>-1&&ee.push(239,191,189);if(Z=null,A<128){if((I-=1)<0)break;ee.push(A)}else if(A<2048){if((I-=2)<0)break;ee.push(A>>6|192,A&63|128)}else if(A<65536){if((I-=3)<0)break;ee.push(A>>12|224,A>>6&63|128,A&63|128)}else if(A<1114112){if((I-=4)<0)break;ee.push(A>>18|240,A>>12&63|128,A>>6&63|128,A&63|128)}else throw new Error("Invalid code point")}return ee}function fe(N){const I=[];for(let A=0;A>8,Z=A%256,ee.push(Z),ee.push(U);return ee}function jn(N){return u.toByteArray(kn(N))}function ur(N,I,A,U){let Z;for(Z=0;Z=I.length||Z>=N.length);++Z)I[Z+A]=N[Z];return Z}function ln(N,I){return N instanceof I||N!=null&&N.constructor!=null&&N.constructor.name!=null&&N.constructor.name===I.name}function cl(N){return N!==N}const dl=function(){const N="0123456789abcdef",I=new Array(256);for(let A=0;A<16;++A){const U=A*16;for(let Z=0;Z<16;++Z)I[U+Z]=N[A]+N[Z]}return I}();function Ts(N){return typeof BigInt>"u"?fl:N}function fl(){throw new Error("BigInt not supported")}},8769:(c,d,f)=>{var u,a=TypeError,m=Object.getOwnPropertyDescriptor;if(m)try{m({},"")}catch{m=null}var y=function(){throw new a},p=m?function(){try{return arguments.callee,y}catch{try{return m(arguments,"callee").get}catch{return y}}}():y,l=f(1405)(),b=Object.getPrototypeOf||function(R){return R.__proto__},L=u,E=u,S=u,x=typeof Uint8Array>"u"?u:b(Uint8Array),F={"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?u:ArrayBuffer,"%ArrayBufferPrototype%":typeof ArrayBuffer>"u"?u:ArrayBuffer.prototype,"%ArrayIteratorPrototype%":l?b([][Symbol.iterator]()):u,"%ArrayPrototype%":Array.prototype,"%ArrayProto_entries%":Array.prototype.entries,"%ArrayProto_forEach%":Array.prototype.forEach,"%ArrayProto_keys%":Array.prototype.keys,"%ArrayProto_values%":Array.prototype.values,"%AsyncFromSyncIteratorPrototype%":u,"%AsyncFunction%":E,"%AsyncFunctionPrototype%":u,"%AsyncGenerator%":u,"%AsyncGeneratorFunction%":S,"%AsyncGeneratorPrototype%":u,"%AsyncIteratorPrototype%":u,"%Atomics%":typeof Atomics>"u"?u:Atomics,"%Boolean%":Boolean,"%BooleanPrototype%":Boolean.prototype,"%DataView%":typeof DataView>"u"?u:DataView,"%DataViewPrototype%":typeof DataView>"u"?u:DataView.prototype,"%Date%":Date,"%DatePrototype%":Date.prototype,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%ErrorPrototype%":Error.prototype,"%eval%":eval,"%EvalError%":EvalError,"%EvalErrorPrototype%":EvalError.prototype,"%Float32Array%":typeof Float32Array>"u"?u:Float32Array,"%Float32ArrayPrototype%":typeof Float32Array>"u"?u:Float32Array.prototype,"%Float64Array%":typeof Float64Array>"u"?u:Float64Array,"%Float64ArrayPrototype%":typeof Float64Array>"u"?u:Float64Array.prototype,"%Function%":Function,"%FunctionPrototype%":Function.prototype,"%Generator%":u,"%GeneratorFunction%":L,"%GeneratorPrototype%":u,"%Int8Array%":typeof Int8Array>"u"?u:Int8Array,"%Int8ArrayPrototype%":typeof Int8Array>"u"?u:Int8Array.prototype,"%Int16Array%":typeof Int16Array>"u"?u:Int16Array,"%Int16ArrayPrototype%":typeof Int16Array>"u"?u:Int8Array.prototype,"%Int32Array%":typeof Int32Array>"u"?u:Int32Array,"%Int32ArrayPrototype%":typeof Int32Array>"u"?u:Int32Array.prototype,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":l?b(b([][Symbol.iterator]())):u,"%JSON%":typeof JSON=="object"?JSON:u,"%JSONParse%":typeof JSON=="object"?JSON.parse:u,"%Map%":typeof Map>"u"?u:Map,"%MapIteratorPrototype%":typeof Map>"u"||!l?u:b(new Map()[Symbol.iterator]()),"%MapPrototype%":typeof Map>"u"?u:Map.prototype,"%Math%":Math,"%Number%":Number,"%NumberPrototype%":Number.prototype,"%Object%":Object,"%ObjectPrototype%":Object.prototype,"%ObjProto_toString%":Object.prototype.toString,"%ObjProto_valueOf%":Object.prototype.valueOf,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?u:Promise,"%PromisePrototype%":typeof Promise>"u"?u:Promise.prototype,"%PromiseProto_then%":typeof Promise>"u"?u:Promise.prototype.then,"%Promise_all%":typeof Promise>"u"?u:Promise.all,"%Promise_reject%":typeof Promise>"u"?u:Promise.reject,"%Promise_resolve%":typeof Promise>"u"?u:Promise.resolve,"%Proxy%":typeof Proxy>"u"?u:Proxy,"%RangeError%":RangeError,"%RangeErrorPrototype%":RangeError.prototype,"%ReferenceError%":ReferenceError,"%ReferenceErrorPrototype%":ReferenceError.prototype,"%Reflect%":typeof Reflect>"u"?u:Reflect,"%RegExp%":RegExp,"%RegExpPrototype%":RegExp.prototype,"%Set%":typeof Set>"u"?u:Set,"%SetIteratorPrototype%":typeof Set>"u"||!l?u:b(new Set()[Symbol.iterator]()),"%SetPrototype%":typeof Set>"u"?u:Set.prototype,"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?u:SharedArrayBuffer,"%SharedArrayBufferPrototype%":typeof SharedArrayBuffer>"u"?u:SharedArrayBuffer.prototype,"%String%":String,"%StringIteratorPrototype%":l?b(""[Symbol.iterator]()):u,"%StringPrototype%":String.prototype,"%Symbol%":l?Symbol:u,"%SymbolPrototype%":l?Symbol.prototype:u,"%SyntaxError%":SyntaxError,"%SyntaxErrorPrototype%":SyntaxError.prototype,"%ThrowTypeError%":p,"%TypedArray%":x,"%TypedArrayPrototype%":x?x.prototype:u,"%TypeError%":a,"%TypeErrorPrototype%":a.prototype,"%Uint8Array%":typeof Uint8Array>"u"?u:Uint8Array,"%Uint8ArrayPrototype%":typeof Uint8Array>"u"?u:Uint8Array.prototype,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?u:Uint8ClampedArray,"%Uint8ClampedArrayPrototype%":typeof Uint8ClampedArray>"u"?u:Uint8ClampedArray.prototype,"%Uint16Array%":typeof Uint16Array>"u"?u:Uint16Array,"%Uint16ArrayPrototype%":typeof Uint16Array>"u"?u:Uint16Array.prototype,"%Uint32Array%":typeof Uint32Array>"u"?u:Uint32Array,"%Uint32ArrayPrototype%":typeof Uint32Array>"u"?u:Uint32Array.prototype,"%URIError%":URIError,"%URIErrorPrototype%":URIError.prototype,"%WeakMap%":typeof WeakMap>"u"?u:WeakMap,"%WeakMapPrototype%":typeof WeakMap>"u"?u:WeakMap.prototype,"%WeakSet%":typeof WeakSet>"u"?u:WeakSet,"%WeakSetPrototype%":typeof WeakSet>"u"?u:WeakSet.prototype},k=f(8612),M=k.call(Function.call,String.prototype.replace),O=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,C=/\\(\\)?/g,P=function(H){var z=[];return M(H,O,function(Y,$,W,X){z[z.length]=W?M(X,C,"$1"):$||Y}),z},j=function(H,z){if(!(H in F))throw new SyntaxError("intrinsic "+H+" does not exist!");if(typeof F[H]>"u"&&!z)throw new a("intrinsic "+H+" exists, but is not available. Please file an issue!");return F[H]};c.exports=function(H,z){if(typeof H!="string"||H.length===0)throw new TypeError("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof z!="boolean")throw new TypeError('"allowMissing" argument must be a boolean');for(var Y=P(H),$=j("%"+(Y.length>0?Y[0]:"")+"%",z),W=1;W=Y.length){var X=m($,Y[W]);if(!z&&!(Y[W]in $))throw new a("base intrinsic for "+H+" exists, but the property is not available.");$=X&&"get"in X&&!("originalValue"in X.get)?X.get:$[Y[W]]}else $=$[Y[W]];return $}},4147:(c,d,f)=>{var u=f(8612),a=f(8769),m=a("%Function.prototype.apply%"),y=a("%Function.prototype.call%"),p=a("%Reflect.apply%",!0)||u.call(y,m),l=a("%Object.defineProperty%",!0);if(l)try{l({},"a",{value:1})}catch{l=null}c.exports=function(){return p(u,y,arguments)};var b=function(){return p(u,m,arguments)};l?l(c.exports,"apply",{value:b}):c.exports.apply=b},8914:(c,d,f)=>{var u=f(8769),a=f(4147),m=a(u("String.prototype.indexOf"));c.exports=function(p,l){var b=u(p,!!l);return typeof b=="function"&&m(p,".prototype.")?a(b):b}},4079:(c,d,f)=>{var u=f(8769),a=u("%Object.getOwnPropertyDescriptor%");if(a)try{a([],"length")}catch{a=null}c.exports=a},6729:c=>{var d=Object.prototype.hasOwnProperty,f="~";function u(){}Object.create&&(u.prototype=Object.create(null),new u().__proto__||(f=!1));function a(l,b,L){this.fn=l,this.context=b,this.once=L||!1}function m(l,b,L,E,S){if(typeof L!="function")throw new TypeError("The listener must be a function");var x=new a(L,E||l,S),F=f?f+b:b;return l._events[F]?l._events[F].fn?l._events[F]=[l._events[F],x]:l._events[F].push(x):(l._events[F]=x,l._eventsCount++),l}function y(l,b){--l._eventsCount===0?l._events=new u:delete l._events[b]}function p(){this._events=new u,this._eventsCount=0}p.prototype.eventNames=function(){var b=[],L,E;if(this._eventsCount===0)return b;for(E in L=this._events)d.call(L,E)&&b.push(f?E.slice(1):E);return Object.getOwnPropertySymbols?b.concat(Object.getOwnPropertySymbols(L)):b},p.prototype.listeners=function(b){var L=f?f+b:b,E=this._events[L];if(!E)return[];if(E.fn)return[E.fn];for(var S=0,x=E.length,F=new Array(x);S{var d=typeof Reflect=="object"?Reflect:null,f=d&&typeof d.apply=="function"?d.apply:function(j,R,H){return Function.prototype.apply.call(j,R,H)},u;d&&typeof d.ownKeys=="function"?u=d.ownKeys:Object.getOwnPropertySymbols?u=function(j){return Object.getOwnPropertyNames(j).concat(Object.getOwnPropertySymbols(j))}:u=function(j){return Object.getOwnPropertyNames(j)};function a(P){console&&console.warn&&console.warn(P)}var m=Number.isNaN||function(j){return j!==j};function y(){y.init.call(this)}c.exports=y,c.exports.once=C,y.EventEmitter=y,y.prototype._events=void 0,y.prototype._eventsCount=0,y.prototype._maxListeners=void 0;var p=10;function l(P){if(typeof P!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof P)}Object.defineProperty(y,"defaultMaxListeners",{enumerable:!0,get:function(){return p},set:function(P){if(typeof P!="number"||P<0||m(P))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+P+".");p=P}}),y.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},y.prototype.setMaxListeners=function(j){if(typeof j!="number"||j<0||m(j))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+j+".");return this._maxListeners=j,this};function b(P){return P._maxListeners===void 0?y.defaultMaxListeners:P._maxListeners}y.prototype.getMaxListeners=function(){return b(this)},y.prototype.emit=function(j){for(var R=[],H=1;H0&&($=R[0]),$ instanceof Error)throw $;var W=new Error("Unhandled error."+($?" ("+$.message+")":""));throw W.context=$,W}var X=Y[j];if(X===void 0)return!1;if(typeof X=="function")f(X,this,R);else for(var G=X.length,oe=k(X,G),H=0;H0&&$.length>z&&!$.warned){$.warned=!0;var W=new Error("Possible EventEmitter memory leak detected. "+$.length+" "+String(j)+" listeners added. Use emitter.setMaxListeners() to increase limit");W.name="MaxListenersExceededWarning",W.emitter=P,W.type=j,W.count=$.length,a(W)}return P}y.prototype.addListener=function(j,R){return L(this,j,R,!1)},y.prototype.on=y.prototype.addListener,y.prototype.prependListener=function(j,R){return L(this,j,R,!0)};function E(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function S(P,j,R){var H={fired:!1,wrapFn:void 0,target:P,type:j,listener:R},z=E.bind(H);return z.listener=R,H.wrapFn=z,z}y.prototype.once=function(j,R){return l(R),this.on(j,S(this,j,R)),this},y.prototype.prependOnceListener=function(j,R){return l(R),this.prependListener(j,S(this,j,R)),this},y.prototype.removeListener=function(j,R){var H,z,Y,$,W;if(l(R),z=this._events,z===void 0)return this;if(H=z[j],H===void 0)return this;if(H===R||H.listener===R)--this._eventsCount===0?this._events=Object.create(null):(delete z[j],z.removeListener&&this.emit("removeListener",j,H.listener||R));else if(typeof H!="function"){for(Y=-1,$=H.length-1;$>=0;$--)if(H[$]===R||H[$].listener===R){W=H[$].listener,Y=$;break}if(Y<0)return this;Y===0?H.shift():M(H,Y),H.length===1&&(z[j]=H[0]),z.removeListener!==void 0&&this.emit("removeListener",j,W||R)}return this},y.prototype.off=y.prototype.removeListener,y.prototype.removeAllListeners=function(j){var R,H,z;if(H=this._events,H===void 0)return this;if(H.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):H[j]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete H[j]),this;if(arguments.length===0){var Y=Object.keys(H),$;for(z=0;z=0;z--)this.removeListener(j,R[z]);return this};function x(P,j,R){var H=P._events;if(H===void 0)return[];var z=H[j];return z===void 0?[]:typeof z=="function"?R?[z.listener||z]:[z]:R?O(z):k(z,z.length)}y.prototype.listeners=function(j){return x(this,j,!0)},y.prototype.rawListeners=function(j){return x(this,j,!1)},y.listenerCount=function(P,j){return typeof P.listenerCount=="function"?P.listenerCount(j):F.call(P,j)},y.prototype.listenerCount=F;function F(P){var j=this._events;if(j!==void 0){var R=j[P];if(typeof R=="function")return 1;if(R!==void 0)return R.length}return 0}y.prototype.eventNames=function(){return this._eventsCount>0?u(this._events):[]};function k(P,j){for(var R=new Array(j),H=0;H{var d=Object.prototype.hasOwnProperty,f=Object.prototype.toString;c.exports=function(a,m,y){if(f.call(m)!=="[object Function]")throw new TypeError("iterator must be a function");var p=a.length;if(p===+p)for(var l=0;l{var d="Function.prototype.bind called on incompatible ",f=Array.prototype.slice,u=Object.prototype.toString,a="[object Function]";c.exports=function(y){var p=this;if(typeof p!="function"||u.call(p)!==a)throw new TypeError(d+p);for(var l=f.call(arguments,1),b,L=function(){if(this instanceof b){var k=p.apply(this,l.concat(f.call(arguments)));return Object(k)===k?k:this}else return p.apply(y,l.concat(f.call(arguments)))},E=Math.max(0,p.length-l.length),S=[],x=0;x{var u=f(7648);c.exports=Function.prototype.bind||u},1405:(c,d,f)=>{var u=f.g.Symbol,a=f(5419);c.exports=function(){return typeof u!="function"||typeof Symbol!="function"||typeof u("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:a()}},5419:c=>{c.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var f={},u=Symbol("test"),a=Object(u);if(typeof u=="string"||Object.prototype.toString.call(u)!=="[object Symbol]"||Object.prototype.toString.call(a)!=="[object Symbol]")return!1;var m=42;f[u]=m;for(u in f)return!1;if(typeof Object.keys=="function"&&Object.keys(f).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(f).length!==0)return!1;var y=Object.getOwnPropertySymbols(f);if(y.length!==1||y[0]!==u||!Object.prototype.propertyIsEnumerable.call(f,u))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var p=Object.getOwnPropertyDescriptor(f,u);if(p.value!==m||p.enumerable!==!0)return!1}return!0}},645:(c,d)=>{/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */d.read=function(f,u,a,m,y){var p,l,b=y*8-m-1,L=(1<>1,S=-7,x=a?y-1:0,F=a?-1:1,k=f[u+x];for(x+=F,p=k&(1<<-S)-1,k>>=-S,S+=b;S>0;p=p*256+f[u+x],x+=F,S-=8);for(l=p&(1<<-S)-1,p>>=-S,S+=m;S>0;l=l*256+f[u+x],x+=F,S-=8);if(p===0)p=1-E;else{if(p===L)return l?NaN:(k?-1:1)*(1/0);l=l+Math.pow(2,m),p=p-E}return(k?-1:1)*l*Math.pow(2,p-m)},d.write=function(f,u,a,m,y,p){var l,b,L,E=p*8-y-1,S=(1<>1,F=y===23?Math.pow(2,-24)-Math.pow(2,-77):0,k=m?0:p-1,M=m?1:-1,O=u<0||u===0&&1/u<0?1:0;for(u=Math.abs(u),isNaN(u)||u===1/0?(b=isNaN(u)?1:0,l=S):(l=Math.floor(Math.log(u)/Math.LN2),u*(L=Math.pow(2,-l))<1&&(l--,L*=2),l+x>=1?u+=F/L:u+=F*Math.pow(2,1-x),u*L>=2&&(l++,L/=2),l+x>=S?(b=0,l=S):l+x>=1?(b=(u*L-1)*Math.pow(2,y),l=l+x):(b=u*Math.pow(2,x-1)*Math.pow(2,y),l=0));y>=8;f[a+k]=b&255,k+=M,b/=256,y-=8);for(l=l<0;f[a+k]=l&255,k+=M,l/=256,E-=8);f[a+k-M]|=O*128}},5717:c=>{typeof Object.create=="function"?c.exports=function(f,u){u&&(f.super_=u,f.prototype=Object.create(u.prototype,{constructor:{value:f,enumerable:!1,writable:!0,configurable:!0}}))}:c.exports=function(f,u){if(u){f.super_=u;var a=function(){};a.prototype=u.prototype,f.prototype=new a,f.prototype.constructor=f}}},2584:c=>{var d=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",f=Object.prototype.toString,u=function(p){return d&&p&&typeof p=="object"&&Symbol.toStringTag in p?!1:f.call(p)==="[object Arguments]"},a=function(p){return u(p)?!0:p!==null&&typeof p=="object"&&typeof p.length=="number"&&p.length>=0&&f.call(p)!=="[object Array]"&&f.call(p.callee)==="[object Function]"},m=function(){return u(arguments)}();u.isLegacyArguments=a,c.exports=m?u:a},8662:c=>{var d=Object.prototype.toString,f=Function.prototype.toString,u=/^\s*(?:function)?\*/,a=typeof Symbol=="function"&&typeof Symbol.toStringTag=="symbol",m=Object.getPrototypeOf,y=function(){if(!a)return!1;try{return Function("return function*() {}")()}catch{}},p=y(),l=p?m(p):{};c.exports=function(L){if(typeof L!="function")return!1;if(u.test(f.call(L)))return!0;if(!a){var E=d.call(L);return E==="[object GeneratorFunction]"}return m(L)===l}},5692:(c,d,f)=>{var u=f(9804),a=f(6314),m=f(8914),y=m("Object.prototype.toString"),p=f(1405)(),l=p&&typeof Symbol.toStringTag=="symbol",b=a(),L=m("Array.prototype.indexOf",!0)||function(O,C){for(var P=0;P-1}return x?k(O):!1}},6792:(c,d,f)=>{var u=null;typeof WebSocket<"u"?u=WebSocket:typeof MozWebSocket<"u"?u=MozWebSocket:typeof f.g<"u"?u=f.g.WebSocket||f.g.MozWebSocket:typeof window<"u"?u=window.WebSocket||window.MozWebSocket:typeof self<"u"&&(u=self.WebSocket||self.MozWebSocket),c.exports=u},135:(c,d,f)=>{for(var u=f(8764).Buffer,a=4294967296,m=[],y=0;y<256;y++)m[y]=(y>15?"":"0")+y.toString(16);var p=c.exports=function(l,b){l instanceof u?(this.buffer=l,this.offset=b||0):Object.prototype.toString.call(l)=="[object Uint8Array]"?(this.buffer=new u(l),this.offset=b||0):(this.buffer=this.buffer||new u(8),this.offset=0,this.setValue.apply(this,arguments))};p.MAX_INT=Math.pow(2,53),p.MIN_INT=-Math.pow(2,53),p.prototype={constructor:p,_2scomp:function(){for(var l=this.buffer,b=this.offset,L=1,E=b+7;E>=b;E--){var S=(l[E]^255)+L;l[E]=S&255,L=S>>8}},setValue:function(l,b){var L=!1;if(arguments.length==1)if(typeof l=="number"){if(L=l<0,l=Math.abs(l),b=l%a,l=l/a,l>a)throw new RangeError(l+" is outside Int64 range");l=l|0}else if(typeof l=="string")l=(l+"").replace(/^0x/,""),b=l.substr(-8),l=l.length>8?l.substr(0,l.length-8):"",l=parseInt(l,16),b=parseInt(b,16);else throw new Error(l+" must be a Number or String");for(var E=this.buffer,S=this.offset,x=7;x>=0;x--)E[S+x]=b&255,b=x==4?l:b>>>8;L&&this._2scomp()},toNumber:function(l){for(var b=this.buffer,L=this.offset,E=b[L]&128,S=0,x=1,F=7,k=1;F>=0;F--,k*=256){var M=b[L+F];E&&(M=(M^255)+x,x=M>>8,M=M&255),S+=M*k}return!l&&S>=p.MAX_INT?E?-1/0:1/0:E?-S:S},valueOf:function(){return this.toNumber(!1)},toString:function(l){return this.valueOf().toString(l||10)},toOctetString:function(l){for(var b=new Array(8),L=this.buffer,E=this.offset,S=0;S<8;S++)b[S]=m[L[E+S]];return b.join(l||"")},toBuffer:function(l){if(l&&this.offset===0)return this.buffer;var b=new u(8);return this.buffer.copy(b,0,this.offset,this.offset+8),b},copy:function(l,b){this.buffer.copy(l,b||0,this.offset,this.offset+8)},compare:function(l){if((this.buffer[this.offset]&128)!=(l.buffer[l.offset]&128))return l.buffer[l.offset]-this.buffer[this.offset];for(var b=0;b<8;b++)if(this.buffer[this.offset+b]!==l.buffer[l.offset+b])return this.buffer[this.offset+b]-l.buffer[l.offset+b];return 0},equals:function(l){return this.compare(l)===0},inspect:function(){return"[Int64 value:"+this+" octets:"+this.toOctetString(" ")+"]"}}},8486:c=>{/*! * * Copyright 2009-2017 Kris Kowal under the terms of the MIT * license found at https://github.com/kriskowal/q/blob/v1/LICENSE * * With parts by Tyler Close * Copyright 2007-2009 Tyler Close under the terms of the MIT X license found * at http://www.opensource.org/licenses/mit-license.html * Forked at ref_send.js version: 2009-05-11 * * With parts by Mark Miller * Copyright (C) 2011 Google Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. * */(function(d){typeof bootstrap=="function"?bootstrap("promise",d):c.exports=d()})(function(){var d=!1;try{throw new Error}catch(N){d=!!N.stack}var f=W(),u,a=function(){},m=function(){var N={task:void 0,next:null},I=N,A=!1,U=void 0,Z=!1,ee=[];function ne(){for(var Ye,Xe;N.next;)N=N.next,Ye=N.task,N.task=void 0,Xe=N.domain,Xe&&(N.domain=void 0,Xe.enter()),Be(Ye,Xe);for(;ee.length;)Ye=ee.pop(),Be(Ye);A=!1}function Be(Ye,Xe){try{Ye()}catch(ul){if(Z)throw Xe&&Xe.exit(),setTimeout(ne,0),Xe&&Xe.enter(),ul;setTimeout(function(){throw ul},0)}Xe&&Xe.exit()}if(m=function(Ye){I=I.next={task:Ye,domain:Z&&process.domain,next:null},A||(A=!0,U())},typeof process=="object"&&process.toString()==="[object process]"&&process.nextTick)Z=!0,U=function(){process.nextTick(ne)};else if(typeof setImmediate=="function")typeof window<"u"?U=setImmediate.bind(window,ne):U=function(){setImmediate(ne)};else if(typeof MessageChannel<"u"){var je=new MessageChannel;je.port1.onmessage=function(){U=Ue,je.port1.onmessage=ne,ne()};var Ue=function(){je.port2.postMessage(0)};U=function(){setTimeout(ne,0),Ue()}}else U=function(){setTimeout(ne,0)};return m.runAfter=function(Ye){ee.push(Ye),A||(A=!0,U())},m}(),y=Function.call;function p(N){return function(){return y.apply(N,arguments)}}var l=p(Array.prototype.slice),b=p(Array.prototype.reduce||function(N,I){var A=0,U=this.length;if(arguments.length===1)do{if(A in this){I=this[A++];break}if(++A>=U)throw new TypeError}while(1);for(;AU.stackCounter)&&(x(N,"__minimumStackCounter__",{value:U.stackCounter,configurable:!0}),A.unshift(U.stack));A.unshift(N.stack);var Z=A.join(` `+j+` `),ee=H(Z);x(N,"stack",{value:ee,configurable:!0})}}function H(N){for(var I=N.split(` `),A=[],U=0;U=f&&U<=fl}function W(){if(d)try{throw new Error}catch(U){var N=U.stack.split(` `),I=N[0].indexOf("@")>0?N[1]:N[2],A=Y(I);return A?(u=A[0],A[1]):void 0}}function X(N,I,A){return function(){return typeof console<"u"&&typeof console.warn=="function"&&console.warn(I+" is deprecated, use "+A+" instead.",new Error("").stack),N.apply(N,arguments)}}function G(N){return N instanceof de?N:pt(N)?It(N):Ke(N)}G.resolve=G,G.nextTick=m,G.longStackSupport=!1;var oe=1;typeof process=="object"&&process&&{BROWSER:!0}&&{BROWSER:!0}.Q_DEBUG&&(G.longStackSupport=!0),G.defer=he;function he(){var N=[],I=[],A,U=S(he.prototype),Z=S(de.prototype);if(Z.promiseDispatch=function(ne,Be,je){var Ue=l(arguments);N?(N.push(Ue),Be==="when"&&je[1]&&I.push(je[1])):G.nextTick(function(){A.promiseDispatch.apply(A,Ue)})},Z.valueOf=function(){if(N)return Z;var ne=Fe(A);return Ge(ne)&&(A=ne),ne},Z.inspect=function(){return A?A.inspect():{state:"pending"}},G.longStackSupport&&d)try{throw new Error}catch(ne){Z.stack=ne.stack.substring(ne.stack.indexOf(` `)+1),Z.stackCounter=oe++}function ee(ne){A=ne,G.longStackSupport&&d&&(Z.source=ne),b(N,function(Be,je){G.nextTick(function(){ne.promiseDispatch.apply(ne,je)})},void 0),N=void 0,I=void 0}return U.promise=Z,U.resolve=function(ne){A||ee(G(ne))},U.fulfill=function(ne){A||ee(Ke(ne))},U.reject=function(ne){A||ee(be(ne))},U.notify=function(ne){A||b(I,function(Be,je){G.nextTick(function(){je(ne)})},void 0)},U}he.prototype.makeNodeResolver=function(){var N=this;return function(I,A){I?N.reject(I):arguments.length>2?N.resolve(l(arguments,1)):N.resolve(A)}},G.Promise=ie,G.promise=ie;function ie(N){if(typeof N!="function")throw new TypeError("resolver must be a function.");var I=he();try{N(I.resolve,I.reject,I.notify)}catch(A){I.reject(A)}return I.promise}ie.race=Oe,ie.all=jn,ie.reject=be,ie.resolve=G,G.passByCopy=function(N){return N},de.prototype.passByCopy=function(){return this},G.join=function(N,I){return G(N).join(I)},de.prototype.join=function(N){return G([this,N]).spread(function(I,A){if(I===A)return I;throw new Error("Q can't join: not the same: "+I+" "+A)})},G.race=Oe;function Oe(N){return ie(function(I,A){for(var U=0,Z=N.length;U"u"){try{Be=A[ee](ne)}catch(je){return be(je)}return Be.done?G(Be.value):Me(Be.value,U,Z)}else{try{Be=A[ee](ne)}catch(je){return C(je)?G(je.value):be(je)}return Me(Be,U,Z)}}var A=N.apply(this,arguments),U=I.bind(I,"next"),Z=I.bind(I,"throw");return U()}}G.spawn=kn;function kn(N){G.done(G.async(N)())}G.return=Yi;function Yi(N){throw new P(N)}G.promised=fe;function fe(N){return function(){return et([this,jn(arguments)],function(I,A){return N.apply(I,A)})}}G.dispatch=oi;function oi(N,I,A){return G(N).dispatch(I,A)}de.prototype.dispatch=function(N,I){var A=this,U=he();return G.nextTick(function(){A.promiseDispatch(U.resolve,N,I)}),U.promise},G.get=function(N,I){return G(N).dispatch("get",[I])},de.prototype.get=function(N){return this.dispatch("get",[N])},G.set=function(N,I,A){return G(N).dispatch("set",[I,A])},de.prototype.set=function(N,I){return this.dispatch("set",[N,I])},G.del=G.delete=function(N,I){return G(N).dispatch("delete",[I])},de.prototype.del=de.prototype.delete=function(N){return this.dispatch("delete",[N])},G.mapply=G.post=function(N,I,A){return G(N).dispatch("post",[I,A])},de.prototype.mapply=de.prototype.post=function(N,I){return this.dispatch("post",[N,I])},G.send=G.mcall=G.invoke=function(N,I){return G(N).dispatch("post",[I,l(arguments,2)])},de.prototype.send=de.prototype.mcall=de.prototype.invoke=function(N){return this.dispatch("post",[N,l(arguments,1)])},G.fapply=function(N,I){return G(N).dispatch("apply",[void 0,I])},de.prototype.fapply=function(N){return this.dispatch("apply",[void 0,N])},G.try=G.fcall=function(N){return G(N).dispatch("apply",[void 0,l(arguments,1)])},de.prototype.fcall=function(){return this.dispatch("apply",[void 0,l(arguments)])},G.fbind=function(N){var I=G(N),A=l(arguments,1);return function(){return I.dispatch("apply",[this,A.concat(l(arguments))])}},de.prototype.fbind=function(){var N=this,I=l(arguments);return function(){return N.dispatch("apply",[this,I.concat(l(arguments))])}},G.keys=function(N){return G(N).dispatch("keys",[])},de.prototype.keys=function(){return this.dispatch("keys",[])},G.all=jn;function jn(N){return Me(N,function(I){var A=0,U=he();return b(I,function(Z,ee,ne){var Be;Ge(ee)&&(Be=ee.inspect()).state==="fulfilled"?I[ne]=Be.value:(++A,Me(ee,function(je){I[ne]=je,--A===0&&U.resolve(I)},U.reject,function(je){U.notify({index:ne,value:je})}))},void 0),A===0&&U.resolve(I),U.promise})}de.prototype.all=function(){return jn(this)},G.any=ur;function ur(N){if(N.length===0)return G.resolve();var I=G.defer(),A=0;return b(N,function(U,Z,ee){var ne=N[ee];A++,Me(ne,Be,je,Ue);function Be(Ye){I.resolve(Ye)}function je(Ye){if(A--,A===0){var Xe=Ye||new Error(""+Ye);Xe.message="Q can't get fulfillment value from any promise, all promises were rejected. Last error message: "+Xe.message,I.reject(Xe)}}function Ue(Ye){I.notify({index:ee,value:Ye})}},void 0),I.promise}de.prototype.any=function(){return ur(this)},G.allResolved=X(ln,"allResolved","allSettled");function ln(N){return Me(N,function(I){return I=E(I,G),Me(jn(E(I,function(A){return Me(A,a,a)})),function(){return I})})}de.prototype.allResolved=function(){return ln(this)},G.allSettled=cl;function cl(N){return G(N).allSettled()}de.prototype.allSettled=function(){return this.then(function(N){return jn(E(N,function(I){I=G(I);function A(){return I.inspect()}return I.then(A,A)}))})},G.fail=G.catch=function(N,I){return G(N).then(void 0,I)},de.prototype.fail=de.prototype.catch=function(N){return this.then(void 0,N)},G.progress=dl;function dl(N,I){return G(N).then(void 0,void 0,I)}de.prototype.progress=function(N){return this.then(void 0,void 0,N)},G.fin=G.finally=function(N,I){return G(N).finally(I)},de.prototype.fin=de.prototype.finally=function(N){if(!N||typeof N.apply!="function")throw new Error("Q can't apply finally callback");return N=G(N),this.then(function(I){return N.fcall().then(function(){return I})},function(I){return N.fcall().then(function(){throw I})})},G.done=function(N,I,A,U){return G(N).done(I,A,U)},de.prototype.done=function(N,I,A){var U=function(ee){G.nextTick(function(){if(R(ee,Z),G.onerror)G.onerror(ee);else throw ee})},Z=N||I||A?this.then(N,I,A):this;typeof process=="object"&&process&&process.domain&&(U=process.domain.bind(U)),Z.then(void 0,U)},G.timeout=function(N,I,A){return G(N).timeout(I,A)},de.prototype.timeout=function(N,I){var A=he(),U=setTimeout(function(){(!I||typeof I=="string")&&(I=new Error(I||"Timed out after "+N+" ms"),I.code="ETIMEDOUT"),A.reject(I)},N);return this.then(function(Z){clearTimeout(U),A.resolve(Z)},function(Z){clearTimeout(U),A.reject(Z)},A.notify),A.promise},G.delay=function(N,I){return I===void 0&&(I=N,N=void 0),G(N).delay(I)},de.prototype.delay=function(N){return this.then(function(I){var A=he();return setTimeout(function(){A.resolve(I)},N),A.promise})},G.nfapply=function(N,I){return G(N).nfapply(I)},de.prototype.nfapply=function(N){var I=he(),A=l(N);return A.push(I.makeNodeResolver()),this.fapply(A).fail(I.reject),I.promise},G.nfcall=function(N){var I=l(arguments,1);return G(N).nfapply(I)},de.prototype.nfcall=function(){var N=l(arguments),I=he();return N.push(I.makeNodeResolver()),this.fapply(N).fail(I.reject),I.promise},G.nfbind=G.denodeify=function(N){if(N===void 0)throw new Error("Q can't wrap an undefined function");var I=l(arguments,1);return function(){var A=I.concat(l(arguments)),U=he();return A.push(U.makeNodeResolver()),G(N).fapply(A).fail(U.reject),U.promise}},de.prototype.nfbind=de.prototype.denodeify=function(){var N=l(arguments);return N.unshift(this),G.denodeify.apply(void 0,N)},G.nbind=function(N,I){var A=l(arguments,2);return function(){var U=A.concat(l(arguments)),Z=he();U.push(Z.makeNodeResolver());function ee(){return N.apply(I,arguments)}return G(ee).fapply(U).fail(Z.reject),Z.promise}},de.prototype.nbind=function(){var N=l(arguments,0);return N.unshift(this),G.nbind.apply(void 0,N)},G.nmapply=G.npost=function(N,I,A){return G(N).npost(I,A)},de.prototype.nmapply=de.prototype.npost=function(N,I){var A=l(I||[]),U=he();return A.push(U.makeNodeResolver()),this.dispatch("post",[N,A]).fail(U.reject),U.promise},G.nsend=G.nmcall=G.ninvoke=function(N,I){var A=l(arguments,2),U=he();return A.push(U.makeNodeResolver()),G(N).dispatch("post",[I,A]).fail(U.reject),U.promise},de.prototype.nsend=de.prototype.nmcall=de.prototype.ninvoke=function(N){var I=l(arguments,1),A=he();return I.push(A.makeNodeResolver()),this.dispatch("post",[N,I]).fail(A.reject),A.promise},G.nodeify=Ts;function Ts(N,I){return G(N).nodeify(I)}de.prototype.nodeify=function(N){if(N)this.then(function(I){G.nextTick(function(){N(null,I)})},function(I){G.nextTick(function(){N(I)})});else return this},G.noConflict=function(){throw new Error("Q.noConflict only works when Q is used as a global")};var fl=W();return G})},7533:(c,d)=>{var f=Math.pow(2,8),u=Math.pow(2,16),a=Math.pow(2,24),m=Math.pow(2,32),y=Math.pow(2,40),p=Math.pow(2,48),l=Math.pow(2,52),b=Math.pow(2,1022);d.readByte=function(L){return L>127?L-256:L},d.readI16=function(L,E){E=E||0;var S=L[E+1];return S+=L[E]<<8,L[E]&128&&(S-=u),S},d.readI32=function(L,E){E=E||0;var S=L[E+3];return S+=L[E+2]<<8,S+=L[E+1]<<16,S+=L[E]*a,L[E]&128&&(S-=m),S},d.writeI16=function(L,E){return L[1]=E&255,E>>=8,L[0]=E&255,L},d.writeI32=function(L,E){return L[3]=E&255,E>>=8,L[2]=E&255,E>>=8,L[1]=E&255,E>>=8,L[0]=E&255,L},d.readDouble=function(L,E){E=E||0;var S=L[E]&128,x=(L[E+1]&240)>>4;x+=(L[E]&127)<<4;var F=L[E+7];switch(F+=L[E+6]<<8,F+=L[E+5]<<16,F+=L[E+4]*a,F+=L[E+3]*m,F+=L[E+2]*y,F+=(L[E+1]&15)*p,x){case 0:x=-1022;break;case 2047:return F?NaN:S?-1/0:1/0;default:F+=l,x-=1023}return S&&(F*=-1),F*Math.pow(2,x-52)},d.writeDouble=function(L,E){var S,x,F;return L[0]=E<0?128:0,E=Math.abs(E),E!==E?(S=0x8000000000000,x=2047):E===1/0?(S=0,x=2047):(x=Math.floor(Math.log(E)/Math.LN2),F=Math.pow(2,-x),E*F<1&&(x--,F*=2),x+1023>=2047?(S=0,x=2047):x+1023>=1?(S=(E*F-1)*l,x+=1023):(S=E*b*l,x=0)),L[1]=x<<4&240,L[0]|=x>>4&127,L[7]=S&255,S=Math.floor(S/f),L[6]=S&255,S=Math.floor(S/f),L[5]=S&255,S=Math.floor(S/f),L[4]=S&255,S>>=8,L[3]=S&255,S>>=8,L[2]=S&255,S>>=8,L[1]|=S&15,L}},4711:(c,d,f)=>{var u=f(8764).Buffer,a=f(1291),m=f(7533),y=f(135),p=f(5406),l=p.Type;c.exports=S;var b=-65536,L=-2147418112,E=255;S.VERSION_MASK=b,S.VERSION_1=L,S.TYPE_MASK=E;function S(x,F,k){this.trans=x,this.strictRead=F!==void 0?F:!1,this.strictWrite=k!==void 0?k:!0,this._seqid=null}S.prototype.flush=function(){return this.trans.flush()},S.prototype.writeMessageBegin=function(x,F,k){this.strictWrite?(this.writeI32(L|F),this.writeString(x),this.writeI32(k)):(this.writeString(x),this.writeByte(F),this.writeI32(k)),this._seqid!==null?a.warning("SeqId already set",{name:x}):(this._seqid=k,this.trans.setCurrSeqId(k))},S.prototype.writeMessageEnd=function(){this._seqid!==null?this._seqid=null:a.warning("No seqid to unset")},S.prototype.writeStructBegin=function(x){},S.prototype.writeStructEnd=function(){},S.prototype.writeFieldBegin=function(x,F,k){this.writeByte(F),this.writeI16(k)},S.prototype.writeFieldEnd=function(){},S.prototype.writeFieldStop=function(){this.writeByte(l.STOP)},S.prototype.writeMapBegin=function(x,F,k){this.writeByte(x),this.writeByte(F),this.writeI32(k)},S.prototype.writeMapEnd=function(){},S.prototype.writeListBegin=function(x,F){this.writeByte(x),this.writeI32(F)},S.prototype.writeListEnd=function(){},S.prototype.writeSetBegin=function(x,F){this.writeByte(x),this.writeI32(F)},S.prototype.writeSetEnd=function(){},S.prototype.writeBool=function(x){x?this.writeByte(1):this.writeByte(0)},S.prototype.writeByte=function(x){this.trans.write(new u([x]))},S.prototype.writeI16=function(x){this.trans.write(m.writeI16(new u(2),x))},S.prototype.writeI32=function(x){this.trans.write(m.writeI32(new u(4),x))},S.prototype.writeI64=function(x){x.buffer?this.trans.write(x.buffer):this.trans.write(new y(x).buffer)},S.prototype.writeDouble=function(x){this.trans.write(m.writeDouble(new u(8),x))},S.prototype.writeStringOrBinary=function(x,F,k){if(typeof k=="string")this.writeI32(u.byteLength(k,F)),this.trans.write(new u(k,F));else if(k instanceof u||Object.prototype.toString.call(k)=="[object Uint8Array]")this.writeI32(k.length),this.trans.write(k);else throw new Error(x+" called without a string/Buffer argument: "+k)},S.prototype.writeString=function(x){this.writeStringOrBinary("writeString","utf8",x)},S.prototype.writeBinary=function(x){this.writeStringOrBinary("writeBinary","binary",x)},S.prototype.readMessageBegin=function(){var x=this.readI32(),F,k,M;if(x<0){var O=x&b;if(O!=L)throw new p.TProtocolException(p.TProtocolExceptionType.BAD_VERSION,"Bad version in readMessageBegin: "+x);F=x&E,k=this.readString(),M=this.readI32()}else{if(this.strictRead)throw new p.TProtocolException(p.TProtocolExceptionType.BAD_VERSION,"No protocol version header");k=this.trans.read(x),F=this.readByte(),M=this.readI32()}return{fname:k,mtype:F,rseqid:M}},S.prototype.readMessageEnd=function(){},S.prototype.readStructBegin=function(){return{fname:""}},S.prototype.readStructEnd=function(){},S.prototype.readFieldBegin=function(){var x=this.readByte();if(x==l.STOP)return{fname:null,ftype:x,fid:0};var F=this.readI16();return{fname:null,ftype:x,fid:F}},S.prototype.readFieldEnd=function(){},S.prototype.readMapBegin=function(){var x=this.readByte(),F=this.readByte(),k=this.readI32();return{ktype:x,vtype:F,size:k}},S.prototype.readMapEnd=function(){},S.prototype.readListBegin=function(){var x=this.readByte(),F=this.readI32();return{etype:x,size:F}},S.prototype.readListEnd=function(){},S.prototype.readSetBegin=function(){var x=this.readByte(),F=this.readI32();return{etype:x,size:F}},S.prototype.readSetEnd=function(){},S.prototype.readBool=function(){var x=this.readByte();return x!==0},S.prototype.readByte=function(){return this.trans.readByte()},S.prototype.readI16=function(){return this.trans.readI16()},S.prototype.readI32=function(){return this.trans.readI32()},S.prototype.readI64=function(){var x=this.trans.read(8);return new y(x)},S.prototype.readDouble=function(){return this.trans.readDouble()},S.prototype.readBinary=function(){var x=this.readI32();if(x===0)return new u(0);if(x<0)throw new p.TProtocolException(p.TProtocolExceptionType.NEGATIVE_SIZE,"Negative binary size");return this.trans.read(x)},S.prototype.readString=function(){var x=this.readI32();if(x===0)return"";if(x<0)throw new p.TProtocolException(p.TProtocolExceptionType.NEGATIVE_SIZE,"Negative string size");return this.trans.readString(x)},S.prototype.getTransport=function(){return this.trans},S.prototype.skip=function(x){switch(x){case l.BOOL:this.readBool();break;case l.BYTE:this.readByte();break;case l.I16:this.readI16();break;case l.I32:this.readI32();break;case l.I64:this.readI64();break;case l.DOUBLE:this.readDouble();break;case l.STRING:this.readString();break;case l.STRUCT:for(this.readStructBegin();;){var F=this.readFieldBegin();if(F.ftype===l.STOP)break;this.skip(F.ftype),this.readFieldEnd()}this.readStructEnd();break;case l.MAP:for(var k=this.readMapBegin(),M=0;M{d.Thrift=f(5406);var u=f(5455);d.WSConnection=u.WSConnection,d.createWSConnection=u.createWSConnection,d.createWSClient=u.createWSClient;var a=f(4050);d.XHRConnection=a.XHRConnection,d.createXHRConnection=a.createXHRConnection,d.createXHRClient=a.createXHRClient,d.Int64=f(135),d.Q=f(8486);var m=f(4184);d.Multiplexer=m.Multiplexer,d.TBufferedTransport=f(8869),d.TFramedTransport=f(7584),d.TWebSocketTransport=f(5764),d.Protocol=f(5086),d.TJSONProtocol=f(5086),d.TBinaryProtocol=f(4711),d.TCompactProtocol=f(9277)},8869:(c,d,f)=>{var u=f(8764).Buffer,a=f(7533),m=f(3590),y=f(5190);c.exports=p;function p(l,b){this.defaultReadBufferSize=1024,this.writeBufferSize=512,this.inBuf=new u(this.defaultReadBufferSize),this.readCursor=0,this.writeCursor=0,this.outBuffers=[],this.outCount=0,this.onFlush=b}p.prototype=new y,p.prototype.reset=function(){this.inBuf=new u(this.defaultReadBufferSize),this.readCursor=0,this.writeCursor=0,this.outBuffers=[],this.outCount=0},p.receiver=function(l,b){var L=new p;return function(E){if(L.writeCursor+E.length>L.inBuf.length){var S=new u(L.writeCursor+E.length);L.inBuf.copy(S,0,0,L.writeCursor),L.inBuf=S}E.copy(L.inBuf,L.writeCursor,0),L.writeCursor+=E.length,l(L,b)}},p.prototype.commitPosition=function(){var l=this.writeCursor-this.readCursor,b=l*2>this.defaultReadBufferSize?l*2:this.defaultReadBufferSize,L=new u(b);l>0&&this.inBuf.copy(L,0,this.readCursor,this.writeCursor),this.readCursor=0,this.writeCursor=l,this.inBuf=L},p.prototype.rollbackPosition=function(){this.readCursor=0},p.prototype.isOpen=function(){return!0},p.prototype.open=function(){},p.prototype.close=function(){},p.prototype.setCurrSeqId=function(l){this._seqid=l},p.prototype.ensureAvailable=function(l){if(this.readCursor+l>this.writeCursor)throw new m},p.prototype.read=function(l){this.ensureAvailable(l);var b=new u(l);return this.inBuf.copy(b,0,this.readCursor,this.readCursor+l),this.readCursor+=l,b},p.prototype.readByte=function(){return this.ensureAvailable(1),a.readByte(this.inBuf[this.readCursor++])},p.prototype.readI16=function(){this.ensureAvailable(2);var l=a.readI16(this.inBuf,this.readCursor);return this.readCursor+=2,l},p.prototype.readI32=function(){this.ensureAvailable(4);var l=a.readI32(this.inBuf,this.readCursor);return this.readCursor+=4,l},p.prototype.readDouble=function(){this.ensureAvailable(8);var l=a.readDouble(this.inBuf,this.readCursor);return this.readCursor+=8,l},p.prototype.readString=function(l){this.ensureAvailable(l);var b=this.inBuf.toString("utf8",this.readCursor,this.readCursor+l);return this.readCursor+=l,b},p.prototype.borrow=function(){var l={buf:this.inBuf,readIndex:this.readCursor,writeIndex:this.writeCursor};return l},p.prototype.consume=function(l){this.readCursor+=l},p.prototype.write=function(l){typeof l=="string"&&(l=new u(l,"utf8")),this.outBuffers.push(l),this.outCount+=l.length},p.prototype.flush=function(){var l=this._seqid;if(this._seqid=null,!(this.outCount<1)){var b=new u(this.outCount),L=0;this.outBuffers.forEach(function(E){E.copy(b,L,0),L+=E.length}),this.onFlush&&this.onFlush(b,l),this.outBuffers=[],this.outCount=0}}},9277:(c,d,f)=>{var u=f(8764).Buffer,a=f(1291),m=f(135),y=f(5406),p=y.Type;c.exports=k;var l=Math.pow(2,8),b=Math.pow(2,24),L=Math.pow(2,32),E=Math.pow(2,40),S=Math.pow(2,48),x=Math.pow(2,52),F=Math.pow(2,1022);function k(M){this.trans=M,this.lastField_=[],this.lastFieldId_=0,this.string_limit_=0,this.string_buf_=null,this.string_buf_size_=0,this.container_limit_=0,this.booleanField_={name:null,hasBoolValue:!1},this.boolValue_={hasBoolValue:!1,boolValue:!1}}k.PROTOCOL_ID=-126,k.VERSION_N=1,k.VERSION_MASK=31,k.TYPE_MASK=-32,k.TYPE_BITS=7,k.TYPE_SHIFT_AMOUNT=5,k.Types={CT_STOP:0,CT_BOOLEAN_TRUE:1,CT_BOOLEAN_FALSE:2,CT_BYTE:3,CT_I16:4,CT_I32:5,CT_I64:6,CT_DOUBLE:7,CT_BINARY:8,CT_LIST:9,CT_SET:10,CT_MAP:11,CT_STRUCT:12},k.TTypeToCType=[k.Types.CT_STOP,0,k.Types.CT_BOOLEAN_TRUE,k.Types.CT_BYTE,k.Types.CT_DOUBLE,0,k.Types.CT_I16,0,k.Types.CT_I32,0,k.Types.CT_I64,k.Types.CT_BINARY,k.Types.CT_STRUCT,k.Types.CT_MAP,k.Types.CT_SET,k.Types.CT_LIST],k.prototype.getTransport=function(){return this.trans},k.prototype.getCompactType=function(M){return k.TTypeToCType[M]},k.prototype.getTType=function(M){switch(M){case p.STOP:return p.STOP;case k.Types.CT_BOOLEAN_FALSE:case k.Types.CT_BOOLEAN_TRUE:return p.BOOL;case k.Types.CT_BYTE:return p.BYTE;case k.Types.CT_I16:return p.I16;case k.Types.CT_I32:return p.I32;case k.Types.CT_I64:return p.I64;case k.Types.CT_DOUBLE:return p.DOUBLE;case k.Types.CT_BINARY:return p.STRING;case k.Types.CT_LIST:return p.LIST;case k.Types.CT_SET:return p.SET;case k.Types.CT_MAP:return p.MAP;case k.Types.CT_STRUCT:return p.STRUCT;default:throw new y.TProtocolException(y.TProtocolExceptionType.INVALID_DATA,"Unknown type: "+M)}return p.STOP},k.prototype.flush=function(){return this.trans.flush()},k.prototype.writeMessageBegin=function(M,O,C){this.writeByte(k.PROTOCOL_ID),this.writeByte(k.VERSION_N&k.VERSION_MASK|O<=2047?(C=0,P=2047):P+1023>=1?(C=(M*j-1)*x,P+=1023):(C=M*F*x,P=0)),O[6]=P<<4&240,O[7]|=P>>4&127,O[0]=C&255,C=Math.floor(C/l),O[1]=C&255,C=Math.floor(C/l),O[2]=C&255,C=Math.floor(C/l),O[3]=C&255,C>>=8,O[4]=C&255,C>>=8,O[5]=C&255,C>>=8,O[6]|=C&15,this.trans.write(O)},k.prototype.writeStringOrBinary=function(M,O,C){if(typeof C=="string")this.writeVarint32(u.byteLength(C,O)),this.trans.write(new u(C,O));else if(C instanceof u||Object.prototype.toString.call(C)=="[object Uint8Array]")this.writeVarint32(C.length),this.trans.write(C);else throw new Error(M+" called without a string/Buffer argument: "+C)},k.prototype.writeString=function(M){this.writeStringOrBinary("writeString","utf8",M)},k.prototype.writeBinary=function(M){this.writeStringOrBinary("writeBinary","binary",M)},k.prototype.writeFieldBeginInternal=function(M,O,C,P){var j=P==-1?this.getCompactType(O):P;C>this.lastFieldId_&&C-this.lastFieldId_<=15?this.writeByte(C-this.lastFieldId_<<4|j):(this.writeByte(j),this.writeI16(C)),this.lastFieldId_=C},k.prototype.writeCollectionBegin=function(M,O){O<=14?this.writeByte(O<<4|this.getCompactType(M)):(this.writeByte(240|this.getCompactType(M)),this.writeVarint32(O))},k.prototype.writeVarint32=function(M){for(var O=new u(5),C=0;;)if(M&-128)O[C++]=M&127|128,M=M>>>7;else{O[C++]=M;break}var P=new u(C);O.copy(P,0,0,C),this.trans.write(P)},k.prototype.writeVarint64=function(M){if(typeof M=="number"&&(M=new m(M)),!(M instanceof m))throw new y.TProtocolException(y.TProtocolExceptionType.INVALID_DATA,"Expected Int64 or Number, found: "+M);for(var O=new u(10),C=0,P=M.buffer.readUInt32BE(0,!0),j=M.buffer.readUInt32BE(4,!0),R=0;;)if(!(j&-128)&&P===0){O[C++]=j;break}else O[C++]=j&127|128,R=P<<25,j=j>>>7,P=P>>>7,j=j|R;var H=new u(C);O.copy(H,0,0,C),this.trans.write(H)},k.prototype.i64ToZigzag=function(M){if(typeof M=="string"?M=new m(parseInt(M,10)):typeof M=="number"&&(M=new m(M)),!(M instanceof m))throw new y.TProtocolException(y.TProtocolExceptionType.INVALID_DATA,"Expected Int64 or Number, found: "+M);var O=M.buffer.readUInt32BE(0,!0),C=M.buffer.readUInt32BE(4,!0),P=O>>>31;return O=(O<<1|C>>>31)^(P?4294967295:0),C=C<<1^(P?4294967295:0),new m(O,C)},k.prototype.i32ToZigzag=function(M){return M<<1^(M&2147483648?4294967295:0)},k.prototype.readMessageBegin=function(){var M=this.trans.readByte();if(M!=k.PROTOCOL_ID)throw new y.TProtocolException(y.TProtocolExceptionType.BAD_VERSION,"Bad protocol identifier "+M);var O=this.trans.readByte(),C=O&k.VERSION_MASK;if(C!=k.VERSION_N)throw new y.TProtocolException(y.TProtocolExceptionType.BAD_VERSION,"Bad protocol version "+C);var P=O>>k.TYPE_SHIFT_AMOUNT&k.TYPE_BITS,j=this.readVarint32(),R=this.readString();return{fname:R,mtype:P,rseqid:j}},k.prototype.readMessageEnd=function(){},k.prototype.readStructBegin=function(){return this.lastField_.push(this.lastFieldId_),this.lastFieldId_=0,{fname:""}},k.prototype.readStructEnd=function(){this.lastFieldId_=this.lastField_.pop()},k.prototype.readFieldBegin=function(){var M=0,O=this.trans.readByte(O),C=O&15;if(C==k.Types.CT_STOP)return{fname:null,ftype:y.Type.STOP,fid:0};var P=(O&240)>>>4;P===0?M=this.readI16():M=this.lastFieldId_+P;var j=this.getTType(C);return(C==k.Types.CT_BOOLEAN_TRUE||C==k.Types.CT_BOOLEAN_FALSE)&&(this.boolValue_.hasBoolValue=!0,this.boolValue_.boolValue=C==k.Types.CT_BOOLEAN_TRUE),this.lastFieldId_=M,{fname:null,ftype:j,fid:M}},k.prototype.readFieldEnd=function(){},k.prototype.readMapBegin=function(){var M=this.readVarint32();if(M<0)throw new y.TProtocolException(y.TProtocolExceptionType.NEGATIVE_SIZE,"Negative map size");var O=0;M!==0&&(O=this.trans.readByte());var C=this.getTType((O&240)>>>4),P=this.getTType(O&15);return{ktype:C,vtype:P,size:M}},k.prototype.readMapEnd=function(){},k.prototype.readListBegin=function(){var M=this.trans.readByte(),O=M>>>4&15;if(O==15&&(O=this.readVarint32()),O<0)throw new y.TProtocolException(y.TProtocolExceptionType.NEGATIVE_SIZE,"Negative list size");var C=this.getTType(M&15);return{etype:C,size:O}},k.prototype.readListEnd=function(){},k.prototype.readSetBegin=function(){return this.readListBegin()},k.prototype.readSetEnd=function(){},k.prototype.readBool=function(){var M=!1;if(this.boolValue_.hasBoolValue===!0)M=this.boolValue_.boolValue,this.boolValue_.hasBoolValue=!1;else{var O=this.trans.readByte();O.rsize,M=O.value==k.Types.CT_BOOLEAN_TRUE}return M},k.prototype.readByte=function(){return this.trans.readByte()},k.prototype.readI16=function(){return this.readI32()},k.prototype.readI32=function(){return this.zigzagToI32(this.readVarint32())},k.prototype.readI64=function(){return this.zigzagToI64(this.readVarint64())},k.prototype.readDouble=function(){var M=this.trans.read(8),O=0,C=M[O+7]&128,P=(M[O+6]&240)>>4;P+=(M[O+7]&127)<<4;var j=M[O];switch(j+=M[O+1]<<8,j+=M[O+2]<<16,j+=M[O+3]*b,j+=M[O+4]*L,j+=M[O+5]*E,j+=(M[O+6]&15)*S,P){case 0:P=-1022;break;case 2047:return j?NaN:C?-1/0:1/0;default:j+=x,P-=1023}return C&&(j*=-1),j*Math.pow(2,P-52)},k.prototype.readBinary=function(){var M=this.readVarint32();if(M===0)return new u(0);if(M<0)throw new y.TProtocolException(y.TProtocolExceptionType.NEGATIVE_SIZE,"Negative binary size");return this.trans.read(M)},k.prototype.readString=function(){var M=this.readVarint32();if(M===0)return"";if(M<0)throw new y.TProtocolException(y.TProtocolExceptionType.NEGATIVE_SIZE,"Negative string size");return this.trans.readString(M)},k.prototype.readVarint32=function(){return this.readVarint64().toNumber()},k.prototype.readVarint64=function(){for(var M=0,O=0,C=0,P=0;;){var j=this.trans.readByte();if(M++,P<=25?O=O|(j&127)<>>32-P):C=C|(j&127)<=10)throw new y.TProtocolException(y.TProtocolExceptionType.INVALID_DATA,"Variable-length int over 10 bytes.")}return new m(C,O)},k.prototype.zigzagToI32=function(M){return M>>>1^-1*(M&1)},k.prototype.zigzagToI64=function(M){var O=M.buffer.readUInt32BE(0,!0),C=M.buffer.readUInt32BE(4,!0),P=new m(O&0,C&1);P._2scomp();var j=P.buffer.readUInt32BE(0,!0),R=P.buffer.readUInt32BE(4,!0),H=O<<31;return O=O>>>1^j,C=(C>>>1|H)^R,new m(O,C)},k.prototype.skip=function(M){switch(M){case p.BOOL:this.readBool();break;case p.BYTE:this.readByte();break;case p.I16:this.readI16();break;case p.I32:this.readI32();break;case p.I64:this.readI64();break;case p.DOUBLE:this.readDouble();break;case p.STRING:this.readString();break;case p.STRUCT:for(this.readStructBegin();;){var O=this.readFieldBegin();if(O.ftype===p.STOP)break;this.skip(O.ftype),this.readFieldEnd()}this.readStructEnd();break;case p.MAP:for(var C=this.readMapBegin(),P=0;P{c.exports=d;function d(f,u){f.Client&&(f=f.Client);var a=function(p,l){u.write(p,l)},m=new u.transport(void 0,a),y=new f(m,u.protocol);return m.client=y,u.client=y,y}},7584:(c,d,f)=>{var u=f(8764).Buffer,a=f(7533),m=f(3590),y=f(5190);c.exports=p;function p(l,b){this.inBuf=l||new u(0),this.outBuffers=[],this.outCount=0,this.readPos=0,this.onFlush=b}p.prototype=new y,p.receiver=function(l,b){var L=null;return function(E){for(L&&(E=u.concat([L,E]),L=null);E.length;){if(E.length<4){L=E;return}var S=a.readI32(E,0);if(E.length<4+S){L=E;return}var x=E.slice(4,4+S);L=E.slice(4+S),l(new p(x),b),E=L,L=null}}},p.prototype.commitPosition=function(){},p.prototype.rollbackPosition=function(){},p.prototype.isOpen=function(){return!0},p.prototype.open=function(){},p.prototype.close=function(){},p.prototype.setCurrSeqId=function(l){this._seqid=l},p.prototype.ensureAvailable=function(l){if(this.readPos+l>this.inBuf.length)throw new m},p.prototype.read=function(l){this.ensureAvailable(l);var b=this.readPos+l;if(this.inBuf.length{var u=f(8764).Buffer,a=f(9539),m=f(9277),y=f(4711),p=f(3590);function l(W){Error.call(this),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.message=W}a.inherits(l,Error),c.exports=R;var b=0,L=1,E=0,S=32/8,x=48/8,F=64/8,k=96/8,M=112/8,O=4095,C=1,P=1073741823;function j(W){var X=f(8869);this.outputBuffer=null;var G=this;this.transport=new X(null,function(oe){G.outputBuffer=oe}),this.transport.inBuf=W||u.alloc(0),this.transport.writeCursor=this.transport.inBuf.length,this.protocol=new m(this.transport)}j.prototype.readVarint32=function(){return this.protocol.readVarint32()},j.prototype.writeVarint32=function(W){this.protocol.writeVarint32(W)},j.prototype.readString=function(){return this.protocol.readString()},j.prototype.writeString=function(W){this.protocol.writeString(W)},j.prototype.getOutCount=function(){return this.transport.outCount},j.prototype.write=function(W){this.transport.write(W)},j.prototype.toBuffer=function(){return this.transport.flush(),this.outputBuffer},R.SubprotocolId={BINARY:0,JSON:1,COMPACT:2};function R(){this.maxFrameSize=P,this.protocolId=R.SubprotocolId.BINARY,this.rheaders={},this.wheaders={},this.inBuf=u.alloc(0),this.outCount=0,this.flags=null,this.seqid=0,this.shouldWriteHeaders=!0}var H=function(W,X){if(typeof W!="string"||typeof X!="string")throw new l("Header key and values must be strings")},z=function(W){for(var X=Object.keys(R.SubprotocolId),G=0;Gthis.maxFrameSize)throw new l("Frame exceeds maximum frame size");var oe=W.readInt16BE(S);if(this.shouldWriteHeaders=oe===O,!!this.shouldWriteHeaders){this.setFlags(W.readInt16BE(x)),this.setSeqId(W.readInt32BE(F));var he=W.readInt16BE(k)*4,ie=M+he;if(ie>W.length)throw new l("Header size is greater than frame size");var Oe=u.alloc(he);W.copy(Oe,0,M,ie);var de=new j(Oe);this.setProtocolId(de.readVarint32());var Me=de.readVarint32();if(Me>0)throw new l("Transforms are not yet supported");for(;;)try{var Fe=de.readVarint32();if(Fe!==C)break;for(var Ge=de.readVarint32(),pt=0;pt0){X.writeVarint32(C),X.writeVarint32(G.length);for(var oe=0;oe{var u=f(9539);c.exports=a;function a(m){Error.call(this),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.message=m}u.inherits(a,Error)},5197:(c,d,f)=>{var u=f(8764).Buffer,a=f(135),m=c.exports={},y=Math.pow(2,24),p=Math.pow(2,31),l=Math.pow(2,32),b=Math.pow(10,11);m.toDecimalString=function(L){var E=L.buffer,S=L.offset;if(!E[S]&&!(E[S+1]&224)||!~E[S]&&!~(E[S+1]&224))return L.toString();var x=E[S]&128;if(x){for(var F=!1,k=new u(8),M=7;M>=0;--M)k[M]=~E[S+M]+(F?0:1)&255,F|=E[S+M];E=k}var O=E[S+1]+(E[S]<<8),C=E[S+7]+(E[S+6]<<8)+(E[S+5]<<16)+E[S+4]*y+(E[S+3]+(E[S+2]<<8))*l+O*74976710656,P=Math.floor(C/b)+O*2814;return C=("00000000000"+String(C%b)).slice(-11),(x?"-":"")+String(P)+C},m.fromDecimalString=function(L){var E=L.charAt(0)==="-";if(L.length<(E?17:16))return new a(+L);if(L.length>(E?20:19))throw new RangeError("Too many digits for Int64: "+L);var S=+L.slice(E?1:0,-15),x=+L.slice(-15)+S*2764472320,F=Math.floor(x/l)+S*232830;if(x=x%l,F>=p&&!(E&&F==p&&x==0))throw new RangeError("The magnitude is too large for Int64.");return E&&(F=~F,x===0?F=F+1&4294967295:x=~x+1,F=2147483648|F),new a(F,x)}},6502:(c,d,f)=>{var u=f(135);f(5197),c.exports=function(){var a,m,y={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:` `,r:"\r",t:" "},p,l=function(O){throw new SyntaxError(O)},b=function(O){return O&&O!==m&&l("Expected '"+O+"' instead of '"+m+"'"),m=p.charAt(a),a+=1,m},L=function(){var O,C="";for(m==="-"&&(C="-",b("-"));m>="0"&&m<="9";)C+=m,b();if(m===".")for(C+=".";b()&&m>="0"&&m<="9";)C+=m;if(m==="e"||m==="E")for(C+=m,b(),(m==="-"||m==="+")&&(C+=m,b());m>="0"&&m<="9";)C+=m,b();if(O=+C,!isFinite(O))l("Bad number");else return O>=u.MAX_INT||O<=u.MIN_INT?C:O},E=function(){var O,C,P="",j;if(m==='"')for(;b();){if(m==='"')return b(),P;if(m==="\\")if(b(),m==="u"){for(j=0,C=0;C<4&&(O=parseInt(b(),16),!!isFinite(O));C+=1)j=j*16+O;P+=String.fromCharCode(j)}else if(typeof y[m]=="string")P+=y[m];else break;else P+=m}l("Bad string")},S=function(){for(;m&&m<=" ";)b()},x=function(){switch(m){case"t":return b("t"),b("r"),b("u"),b("e"),!0;case"f":return b("f"),b("a"),b("l"),b("s"),b("e"),!1;case"n":return b("n"),b("u"),b("l"),b("l"),null}l("Unexpected '"+m+"'")},F,k=function(){var O=[];if(m==="["){if(b("["),S(),m==="]")return b("]"),O;for(;m;){if(O.push(F()),S(),m==="]")return b("]"),O;b(","),S()}}l("Bad array")},M=function(){var O,C={};if(m==="{"){if(b("{"),S(),m==="}")return b("}"),C;for(;m;){if(O=E(),S(),b(":"),Object.hasOwnProperty.call(C,O)&&l('Duplicate key "'+O+'"'),C[O]=F(),S(),m==="}")return b("}"),C;b(","),S()}}l("Bad object")};return F=function(){switch(S(),m){case"{":return M();case"[":return k();case'"':return E();case"-":return L();default:return m>="0"&&m<="9"?L():x()}},function(O){var C;return p=O,a=0,m=" ",C=F(),S(),m&&l("Syntax error"),C}}()},5086:(c,d,f)=>{var u=f(8764).Buffer,a=f(135),m=f(5406),y=m.Type;f(9539);var p=f(5197),l=f(6502),b=f(3590);c.exports=L;function L(E){this.tstack=[],this.tpos=[],this.trans=E}L.Type={},L.Type[y.BOOL]='"tf"',L.Type[y.BYTE]='"i8"',L.Type[y.I16]='"i16"',L.Type[y.I32]='"i32"',L.Type[y.I64]='"i64"',L.Type[y.DOUBLE]='"dbl"',L.Type[y.STRUCT]='"rec"',L.Type[y.STRING]='"str"',L.Type[y.MAP]='"map"',L.Type[y.LIST]='"lst"',L.Type[y.SET]='"set"',L.RType={},L.RType.tf=y.BOOL,L.RType.i8=y.BYTE,L.RType.i16=y.I16,L.RType.i32=y.I32,L.RType.i64=y.I64,L.RType.dbl=y.DOUBLE,L.RType.rec=y.STRUCT,L.RType.str=y.STRING,L.RType.map=y.MAP,L.RType.lst=y.LIST,L.RType.set=y.SET,L.Version=1,L.prototype.flush=function(){return this.writeToTransportIfStackIsFlushable(),this.trans.flush()},L.prototype.writeToTransportIfStackIsFlushable=function(){this.tstack.length===1&&this.trans.write(this.tstack.pop())},L.prototype.writeMessageBegin=function(E,S,x){this.tstack.push([L.Version,'"'+E+'"',S,x])},L.prototype.writeMessageEnd=function(){var E=this.tstack.pop();this.wobj=this.tstack.pop(),this.wobj.push(E),this.wbuf="["+this.wobj.join(",")+"]",this.trans.write(this.wbuf)},L.prototype.writeStructBegin=function(E){this.tpos.push(this.tstack.length),this.tstack.push({})},L.prototype.writeStructEnd=function(){var E=this.tpos.pop(),S=this.tstack[E],x="{",F=!0;for(var k in S)F?F=!1:x+=",",x+=k+":"+S[k];x+="}",this.tstack[E]=x,this.writeToTransportIfStackIsFlushable()},L.prototype.writeFieldBegin=function(E,S,x){this.tpos.push(this.tstack.length),this.tstack.push({fieldId:'"'+x+'"',fieldType:L.Type[S]})},L.prototype.writeFieldEnd=function(){var E=this.tstack.pop(),S=this.tstack.pop();":"+E==":[object Object]"?this.tstack[this.tstack.length-1][S.fieldId]="{"+S.fieldType+":"+JSON.stringify(E)+"}":this.tstack[this.tstack.length-1][S.fieldId]="{"+S.fieldType+":"+E+"}",this.tpos.pop(),this.writeToTransportIfStackIsFlushable()},L.prototype.writeFieldStop=function(){},L.prototype.writeMapBegin=function(E,S,x){this.tpos.push(this.tstack.length),this.tstack.push([L.Type[E],L.Type[S],0])},L.prototype.writeMapEnd=function(){var E=this.tpos.pop();if(E!=this.tstack.length){(this.tstack.length-E-1)%2!==0&&this.tstack.push("");var S=(this.tstack.length-E-1)/2;this.tstack[E][this.tstack[E].length-1]=S;for(var x="}",F=!0;this.tstack.length>E+1;){var k=this.tstack.pop(),M=this.tstack.pop();F?F=!1:x=","+x,isNaN(M)||(M='"'+M+'"'),x=M+":"+k+x}x="{"+x,this.tstack[E].push(x),this.tstack[E]="["+this.tstack[E].join(",")+"]",this.writeToTransportIfStackIsFlushable()}},L.prototype.writeListBegin=function(E,S){this.tpos.push(this.tstack.length),this.tstack.push([L.Type[E],S])},L.prototype.writeListEnd=function(){for(var E=this.tpos.pop();this.tstack.length>E+1;){var S=this.tstack[E+1];this.tstack.splice(E+1,1),this.tstack[E].push(S)}this.tstack[E]="["+this.tstack[E].join(",")+"]",this.writeToTransportIfStackIsFlushable()},L.prototype.writeSetBegin=function(E,S){this.tpos.push(this.tstack.length),this.tstack.push([L.Type[E],S])},L.prototype.writeSetEnd=function(){for(var E=this.tpos.pop();this.tstack.length>E+1;){var S=this.tstack[E+1];this.tstack.splice(E+1,1),this.tstack[E].push(S)}this.tstack[E]="["+this.tstack[E].join(",")+"]",this.writeToTransportIfStackIsFlushable()},L.prototype.writeBool=function(E){this.tstack.push(E?1:0)},L.prototype.writeByte=function(E){this.tstack.push(E)},L.prototype.writeI16=function(E){this.tstack.push(E)},L.prototype.writeI32=function(E){this.tstack.push(E)},L.prototype.writeI64=function(E){E instanceof a?this.tstack.push(p.toDecimalString(E)):this.tstack.push(E)},L.prototype.writeDouble=function(E){this.tstack.push(E)},L.prototype.writeString=function(E){if(E===null)this.tstack.push(null);else{if(typeof E=="string")var S=E;else if(E instanceof u)var S=E.toString("utf8");else throw new Error("writeString called without a string/Buffer argument: "+E);for(var x="",F=0;F=E.writeIndex)throw new b;var S=E.readIndex;if(E.buf[S]!==91)throw new Error("Malformed JSON input, no opening bracket");S++;for(var x=1,F=!1;SE;)this.rstack.pop()},L.prototype.readMapBegin=function(){var E=this.rstack.pop(),S=E.shift();S instanceof Array&&(this.rstack.push(E),E=S,S=E.shift());var x={};return x.ktype=L.RType[S],x.vtype=L.RType[E.shift()],x.size=E.shift(),this.rpos.push(this.rstack.length),this.rstack.push(E.shift()),x},L.prototype.readMapEnd=function(){this.readFieldEnd()},L.prototype.readListBegin=function(){var E=this.rstack[this.rstack.length-1],S={};return S.etype=L.RType[E.shift()],S.size=E.shift(),this.rpos.push(this.rstack.length),this.rstack.push(E.shift()),S},L.prototype.readListEnd=function(){var E=this.rpos.pop()-2,S=this.rstack;S.pop(),S instanceof Array&&S.length>E&&S[E].length>0&&S.push(S[E].shift())},L.prototype.readSetBegin=function(){return this.readListBegin()},L.prototype.readSetEnd=function(){return this.readListEnd()},L.prototype.readBool=function(){return this.readValue()=="1"},L.prototype.readByte=function(){return this.readI32()},L.prototype.readI16=function(){return this.readI32()},L.prototype.readI32=function(E){return+this.readValue()},L.prototype.readValue=function(E){E===void 0&&(E=this.rstack[this.rstack.length-1]);var S={};if(E instanceof Array)E.length===0?S.value=void 0:S.value=E.shift();else if(!(E instanceof a)&&E instanceof Object){for(var x in E)if(x!==null){this.rstack.push(E[x]),delete E[x],S.value=x;break}}else S.value=E,this.rstack.pop();return S.value},L.prototype.readI64=function(){var E=this.readValue();return typeof E=="string"?p.fromDecimalString(E):new a(E)},L.prototype.readDouble=function(){return this.readI32()},L.prototype.readBinary=function(){return new u(this.readValue(),"base64")},L.prototype.readString=function(){return this.readValue()},L.prototype.getTransport=function(){return this.trans},L.prototype.skip=function(E){switch(E){case y.BOOL:this.readBool();break;case y.BYTE:this.readByte();break;case y.I16:this.readI16();break;case y.I32:this.readI32();break;case y.I64:this.readI64();break;case y.DOUBLE:this.readDouble();break;case y.STRING:this.readString();break;case y.STRUCT:for(this.readStructBegin();;){var S=this.readFieldBegin();if(S.ftype===y.STOP)break;this.skip(S.ftype),this.readFieldEnd()}this.readStructEnd();break;case y.MAP:for(var x=this.readMapBegin(),F=0;F{var u=f(9539),a=function(){},m=console.log,y="error";function p(F){return function(){var k=["thrift: ["+F+"] "].concat(Array.from(arguments));return m(u.format.apply(null,k))}}var l=a,b=a,L=a,E=a,S=a;d.setLogFunc=function(F){m=F};var x=d.setLogLevel=function(F){switch(l=b=L=E=S=a,y=F,y){case"trace":l=p("TRACE");case"debug":b=p("DEBUG");case"error":L=p("ERROR");case"warning":E=p("WARN");case"info":S=p("INFO")}};x(y),d.getLogLevel=function(){return y},d.trace=function(){return l.apply(null,arguments)},d.debug=function(){return b.apply(null,arguments)},d.error=function(){return L.apply(null,arguments)},d.warning=function(){return E.apply(null,arguments)},d.info=function(){return S.apply(null,arguments)}},4184:(c,d,f)=>{var u=f(9539),a=f(5406);d.Multiplexer=y;function m(p,l,b){function L(E,S,x){l.call(this,E,S,x)}return u.inherits(L,l),L.prototype.writeMessageBegin=function(E,S,x){S==a.MessageType.CALL||S==a.MessageType.ONEWAY?(b.seqId2Service[x]=p,L.super_.prototype.writeMessageBegin.call(this,p+":"+E,S,x)):L.super_.prototype.writeMessageBegin.call(this,E,S,x)},L}function y(){this.seqid=0}y.prototype.createClient=function(p,l,b){l.Client&&(l=l.Client);var L=function(k,M){b.write(k,M)},E=new b.transport(void 0,L),S=new m(p,b.protocol,b),x=new l(E,S),F=this;return x.new_seqid=function(){return F.seqid+=1,F.seqid},typeof b.client!="object"&&(b.client={}),b.client[p]=x,x}},5406:(c,d,f)=>{var u=f(9539),a=d.Type={STOP:0,VOID:1,BOOL:2,BYTE:3,I08:3,DOUBLE:4,I16:6,I32:8,I64:10,STRING:11,UTF7:11,STRUCT:12,MAP:13,SET:14,LIST:15,UTF8:16,UTF16:17};d.MessageType={CALL:1,REPLY:2,EXCEPTION:3,ONEWAY:4},d.TException=m;function m(E){Error.call(this),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.message=E}u.inherits(m,Error);var y=d.TApplicationExceptionType={UNKNOWN:0,UNKNOWN_METHOD:1,INVALID_MESSAGE_TYPE:2,WRONG_METHOD_NAME:3,BAD_SEQUENCE_ID:4,MISSING_RESULT:5,INTERNAL_ERROR:6,PROTOCOL_ERROR:7,INVALID_TRANSFORM:8,INVALID_PROTOCOL:9,UNSUPPORTED_CLIENT_TYPE:10};d.TApplicationException=p;function p(E,S){m.call(this),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,this.constructor),this.type=E||y.UNKNOWN,this.name=this.constructor.name,this.message=S}u.inherits(p,m),p.prototype.read=function(E){for(var S=E.readStructBegin("TApplicationException");S=E.readFieldBegin(),S.ftype!=a.STOP;){switch(S.fid){case 1:S.ftype==a.STRING?(S=E.readString(),this.message=S):S=E.skip(S.ftype);break;case 2:S.ftype==a.I32?(S=E.readI32(),this.type=S):S=E.skip(S.ftype);break;default:S=E.skip(S.ftype);break}E.readFieldEnd()}E.readStructEnd()},p.prototype.write=function(E){E.writeStructBegin("TApplicationException"),this.message&&(E.writeFieldBegin("message",a.STRING,1),E.writeString(this.message),E.writeFieldEnd()),this.code&&(E.writeFieldBegin("type",a.I32,2),E.writeI32(this.code),E.writeFieldEnd()),E.writeFieldStop(),E.writeStructEnd()},d.TProtocolExceptionType={UNKNOWN:0,INVALID_DATA:1,NEGATIVE_SIZE:2,SIZE_LIMIT:3,BAD_VERSION:4,NOT_IMPLEMENTED:5,DEPTH_LIMIT:6},d.TProtocolException=l;function l(E,S){Error.call(this),Error.captureStackTrace!==void 0&&Error.captureStackTrace(this,this.constructor),this.name=this.constructor.name,this.type=E,this.message=S}u.inherits(l,Error),d.objectLength=function(E){return Object.keys(E).length},d.inherits=function(E,S){u.inherits(E,S)};var b,L;b=function(E,S){if(!E)return E;var x;S.shift===void 0?x=S:x=S[0];var F=x,k=E.length,M=[],O,C;for(O=0;O{var u=f(8764).Buffer,a=f(9539),m=f(6792),y=f(7187).EventEmitter,p=f(5406),l=f(8869),b=f(5086),L=f(3590),E=f(6243),S=f(3818);d.WSConnection=x;function x(F,k,M){y.call(this),this.options=M||{},this.host=F,this.port=k,this.secure=this.options.secure||!1,this.transport=this.options.transport||l,this.protocol=this.options.protocol||b,this.path=this.options.path,this.send_pending=[],this.seqId2Service={},this.wsOptions={host:this.host,port:this.port||80,path:this.options.path||"/",headers:this.options.headers||{}};for(var O in this.options.wsOptions)this.wsOptions[O]=this.options.wsOptions[O]}a.inherits(x,y),x.prototype.__reset=function(){this.socket=null,this.send_pending=[]},x.prototype.__onOpen=function(){this.emit("open"),this.send_pending.length>0&&(this.send_pending.forEach(function(F){this.socket.send(F)},this),this.send_pending=[])},x.prototype.__onClose=function(F){this.emit("close"),this.__reset()},x.prototype.__decodeCallback=function(F){var k=new this.protocol(F);try{for(;;){var M=k.readMessageBegin(),O=M.rseqid*-1,C=this.client,P=this.seqId2Service[M.rseqid];P&&(C=this.client[P],delete this.seqId2Service[M.rseqid]),C._reqs[O]=function(j,R){F.commitPosition();var H=C._reqs[M.rseqid];delete C._reqs[M.rseqid],H&&H(j,R)},C["recv_"+M.fname]?C["recv_"+M.fname](k,M.mtype,O):(delete C._reqs[O],this.emit("error",new p.TApplicationException(p.TApplicationExceptionType.WRONG_METHOD_NAME,"Received a response to an unknown RPC function")))}}catch(j){if(j instanceof L)F.rollbackPosition();else throw j}},x.prototype.__onData=function(F){Object.prototype.toString.call(F)==="[object ArrayBuffer]"&&(F=new Uint8Array(F));var k=new u(F);this.transport.receiver(this.__decodeCallback.bind(this))(k)},x.prototype.__onMessage=function(F){this.__onData(F.data)},x.prototype.__onError=function(F){this.emit("error",F),this.socket.close()},x.prototype.isOpen=function(){return this.socket&&this.socket.readyState===this.socket.OPEN},x.prototype.open=function(){this.socket&&this.socket.readyState!==this.socket.CLOSED||(S.isBrowser?this.socket=new m(this.uri()):this.socket=new m(this.uri(),"",this.wsOptions),this.socket.binaryType="arraybuffer",this.socket.onopen=this.__onOpen.bind(this),this.socket.onmessage=this.__onMessage.bind(this),this.socket.onerror=this.__onError.bind(this),this.socket.onclose=this.__onClose.bind(this))},x.prototype.close=function(){this.socket.close()},x.prototype.uri=function(){var F=this.secure?"wss":"ws",k="",M=this.path||"/",O=this.host;return this.port&&(F==="wss"&&this.port!==443||F==="ws"&&this.port!==80)&&(k=":"+this.port),F+"://"+O+k+M},x.prototype.write=function(F){this.isOpen()?this.socket.send(F):this.send_pending.push(F)},d.createWSConnection=function(F,k,M){return new x(F,k,M)},d.createWSClient=E},5764:(c,d,f)=>{var u=f(1291);c.exports=a;function a(m){this.__reset(m)}a.prototype.__reset=function(m){this.url=m,this.socket=null,this.callbacks=[],this.send_pending=[],this.send_buf="",this.recv_buf="",this.rb_wpos=0,this.rb_rpos=0},a.prototype.flush=function(m,y){var p=this;this.isOpen()?(this.socket.send(this.send_buf),this.callbacks.push(function(){var l=y;return function(b){p.setRecvBuffer(b),l()}}())):this.send_pending.push({buf:this.send_buf,cb:y})},a.prototype.__onOpen=function(){var m=this;this.send_pending.length>0&&(this.send_pending.forEach(function(y){m.socket.send(y.buf),m.callbacks.push(function(){var p=y.cb;return function(l){m.setRecvBuffer(l),p()}}())}),this.send_pending=[])},a.prototype.__onClose=function(m){this.__reset(this.url)},a.prototype.__onMessage=function(m){this.callbacks.length&&this.callbacks.shift()(m.data)},a.prototype.__onError=function(m){u.error("websocket: "+m.toString()),this.socket.close()},a.prototype.setRecvBuffer=function(m){this.recv_buf=m,this.recv_buf_sz=this.recv_buf.length,this.wpos=this.recv_buf.length,this.rpos=0},a.prototype.isOpen=function(){return this.socket&&this.socket.readyState==this.socket.OPEN},a.prototype.open=function(){this.socket&&this.socket.readyState!=this.socket.CLOSED||(this.socket=new WebSocket(this.url),this.socket.onopen=this.__onOpen.bind(this),this.socket.onmessage=this.__onMessage.bind(this),this.socket.onerror=this.__onError.bind(this),this.socket.onclose=this.__onClose.bind(this))},a.prototype.close=function(){this.socket.close()},a.prototype.read=function(m){var y=this.wpos-this.rpos;if(y===0)return"";var p=m;y{var u=f(8764).Buffer,a=f(9539),m=f(7187).EventEmitter,y=f(5406),p=f(8869),l=f(5086),b=f(3590),L=f(6243);d.XHRConnection=E;function E(S,x,F){this.options=F||{},this.wpos=0,this.rpos=0,this.useCORS=F&&F.useCORS,this.send_buf="",this.recv_buf="",this.transport=F.transport||p,this.protocol=F.protocol||l,this.headers=F.headers||{},S=S||window.location.host,x=x||window.location.port;var k=F.https?"https://":"http://",M=F.path||"/";x===""&&(x=void 0),!x||x===80||x==="80"?this.url=k+S+M:this.url=k+S+":"+x+M,this.seqId2Service={}}a.inherits(E,m),E.prototype.getXmlHttpRequestObject=function(){try{return new XMLHttpRequest}catch{}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch{}try{return new ActiveXObject("Microsoft.XMLHTTP")}catch{}throw"Your browser doesn't support XHR."},E.prototype.flush=function(){var S=this;if(this.url===void 0||this.url==="")return this.send_buf;var x=this.getXmlHttpRequestObject();x.overrideMimeType&&x.overrideMimeType("application/json"),x.onreadystatechange=function(){this.readyState==4&&this.status==200&&S.setRecvBuffer(this.responseText)},x.open("POST",this.url,!0),Object.keys(this.headers).forEach(function(F){x.setRequestHeader(F,S.headers[F])}),x.send(this.send_buf)},E.prototype.setRecvBuffer=function(S){if(this.recv_buf=S,this.recv_buf_sz=this.recv_buf.length,this.wpos=this.recv_buf.length,this.rpos=0,Object.prototype.toString.call(S)=="[object ArrayBuffer]")var x=new Uint8Array(S);var F=new u(x||S);this.transport.receiver(this.__decodeCallback.bind(this))(F)},E.prototype.__decodeCallback=function(S){var x=new this.protocol(S);try{for(;;){var F=x.readMessageBegin(),k=F.rseqid*-1,M=this.client,O=this.seqId2Service[F.rseqid];O&&(M=this.client[O],delete this.seqId2Service[F.rseqid]),M._reqs[k]=function(C,P){S.commitPosition();var j=M._reqs[F.rseqid];delete M._reqs[F.rseqid],j&&j(C,P)},M["recv_"+F.fname]?M["recv_"+F.fname](x,F.mtype,k):(delete M._reqs[k],this.emit("error",new y.TApplicationException(y.TApplicationExceptionType.WRONG_METHOD_NAME,"Received a response to an unknown RPC function")))}}catch(C){if(C instanceof b)S.rollbackPosition();else throw C}},E.prototype.isOpen=function(){return!0},E.prototype.open=function(){},E.prototype.close=function(){},E.prototype.read=function(S){var x=this.wpos-this.rpos;if(x===0)return"";var F=S;x{c.exports=function(f){return f&&typeof f=="object"&&typeof f.copy=="function"&&typeof f.fill=="function"&&typeof f.readUInt8=="function"}},5955:(c,d,f)=>{var u=f(2584),a=f(8662),m=f(6430),y=f(5692);function p(fe){return fe.call.bind(fe)}var l=typeof BigInt<"u",b=typeof Symbol<"u",L=p(Object.prototype.toString),E=p(Number.prototype.valueOf),S=p(String.prototype.valueOf),x=p(Boolean.prototype.valueOf);if(l)var F=p(BigInt.prototype.valueOf);if(b)var k=p(Symbol.prototype.valueOf);function M(fe,oi){if(typeof fe!="object")return!1;try{return oi(fe),!0}catch{return!1}}d.isArgumentsObject=u,d.isGeneratorFunction=a,d.isTypedArray=y;function O(fe){return typeof Promise<"u"&&fe instanceof Promise||fe!==null&&typeof fe=="object"&&typeof fe.then=="function"&&typeof fe.catch=="function"}d.isPromise=O;function C(fe){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(fe):y(fe)||q(fe)}d.isArrayBufferView=C;function P(fe){return m(fe)==="Uint8Array"}d.isUint8Array=P;function j(fe){return m(fe)==="Uint8ClampedArray"}d.isUint8ClampedArray=j;function R(fe){return m(fe)==="Uint16Array"}d.isUint16Array=R;function H(fe){return m(fe)==="Uint32Array"}d.isUint32Array=H;function z(fe){return m(fe)==="Int8Array"}d.isInt8Array=z;function Y(fe){return m(fe)==="Int16Array"}d.isInt16Array=Y;function $(fe){return m(fe)==="Int32Array"}d.isInt32Array=$;function W(fe){return m(fe)==="Float32Array"}d.isFloat32Array=W;function X(fe){return m(fe)==="Float64Array"}d.isFloat64Array=X;function G(fe){return m(fe)==="BigInt64Array"}d.isBigInt64Array=G;function oe(fe){return m(fe)==="BigUint64Array"}d.isBigUint64Array=oe;function he(fe){return L(fe)==="[object Map]"}he.working=typeof Map<"u"&&he(new Map);function ie(fe){return typeof Map>"u"?!1:he.working?he(fe):fe instanceof Map}d.isMap=ie;function Oe(fe){return L(fe)==="[object Set]"}Oe.working=typeof Set<"u"&&Oe(new Set);function de(fe){return typeof Set>"u"?!1:Oe.working?Oe(fe):fe instanceof Set}d.isSet=de;function Me(fe){return L(fe)==="[object WeakMap]"}Me.working=typeof WeakMap<"u"&&Me(new WeakMap);function Fe(fe){return typeof WeakMap>"u"?!1:Me.working?Me(fe):fe instanceof WeakMap}d.isWeakMap=Fe;function Ge(fe){return L(fe)==="[object WeakSet]"}Ge.working=typeof WeakSet<"u"&&Ge(new WeakSet);function pt(fe){return Ge(fe)}d.isWeakSet=pt;function ht(fe){return L(fe)==="[object ArrayBuffer]"}ht.working=typeof ArrayBuffer<"u"&&ht(new ArrayBuffer);function ge(fe){return typeof ArrayBuffer>"u"?!1:ht.working?ht(fe):fe instanceof ArrayBuffer}d.isArrayBuffer=ge;function V(fe){return L(fe)==="[object DataView]"}V.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&V(new DataView(new ArrayBuffer(1),0,1));function q(fe){return typeof DataView>"u"?!1:V.working?V(fe):fe instanceof DataView}d.isDataView=q;function D(fe){return L(fe)==="[object SharedArrayBuffer]"}D.working=typeof SharedArrayBuffer<"u"&&D(new SharedArrayBuffer);function K(fe){return typeof SharedArrayBuffer>"u"?!1:D.working?D(fe):fe instanceof SharedArrayBuffer}d.isSharedArrayBuffer=K;function J(fe){return L(fe)==="[object AsyncFunction]"}d.isAsyncFunction=J;function re(fe){return L(fe)==="[object Map Iterator]"}d.isMapIterator=re;function se(fe){return L(fe)==="[object Set Iterator]"}d.isSetIterator=se;function _e(fe){return L(fe)==="[object Generator]"}d.isGeneratorObject=_e;function be(fe){return L(fe)==="[object WebAssembly.Module]"}d.isWebAssemblyCompiledModule=be;function Ke(fe){return M(fe,E)}d.isNumberObject=Ke;function It(fe){return M(fe,S)}d.isStringObject=It;function Et(fe){return M(fe,x)}d.isBooleanObject=Et;function et(fe){return l&&M(fe,F)}d.isBigIntObject=et;function Zt(fe){return b&&M(fe,k)}d.isSymbolObject=Zt;function kn(fe){return Ke(fe)||It(fe)||Et(fe)||et(fe)||Zt(fe)}d.isBoxedPrimitive=kn;function Yi(fe){return typeof Uint8Array<"u"&&(ge(fe)||K(fe))}d.isAnyArrayBuffer=Yi,["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(fe){Object.defineProperty(d,fe,{enumerable:!1,value:function(){throw new Error(fe+" is not supported in userland")}})})},9539:(c,d,f)=>{var u=Object.getOwnPropertyDescriptors||function(q){for(var D=Object.keys(q),K={},J=0;J=J)return _e;switch(_e){case"%s":return String(K[D++]);case"%d":return Number(K[D++]);case"%j":try{return JSON.stringify(K[D++])}catch{return"[Circular]"}default:return _e}}),se=K[D];D"u")return function(){return d.deprecate(V,q).apply(this,arguments)};var D=!1;function K(){if(!D){if(process.throwDeprecation)throw new Error(q);process.traceDeprecation?console.trace(q):console.error(q),D=!0}return V.apply(this,arguments)}return K};var m={},y=/^$/;if({BROWSER:!0}.NODE_DEBUG){var p={BROWSER:!0}.NODE_DEBUG;p=p.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),y=new RegExp("^"+p+"$","i")}d.debuglog=function(V){if(V=V.toUpperCase(),!m[V])if(y.test(V)){var q=process.pid;m[V]=function(){var D=d.format.apply(d,arguments);console.error("%s %d: %s",V,q,D)}}else m[V]=function(){};return m[V]};function l(V,q){var D={seen:[],stylize:L};return arguments.length>=3&&(D.depth=arguments[2]),arguments.length>=4&&(D.colors=arguments[3]),P(q)?D.showHidden=q:q&&d._extend(D,q),$(D.showHidden)&&(D.showHidden=!1),$(D.depth)&&(D.depth=2),$(D.colors)&&(D.colors=!1),$(D.customInspect)&&(D.customInspect=!0),D.colors&&(D.stylize=b),S(D,V,D.depth)}d.inspect=l,l.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},l.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function b(V,q){var D=l.styles[q];return D?"\x1B["+l.colors[D][0]+"m"+V+"\x1B["+l.colors[D][1]+"m":V}function L(V,q){return V}function E(V){var q={};return V.forEach(function(D,K){q[D]=!0}),q}function S(V,q,D){if(V.customInspect&&q&&he(q.inspect)&&q.inspect!==d.inspect&&!(q.constructor&&q.constructor.prototype===q)){var K=q.inspect(D,V);return z(K)||(K=S(V,K,D)),K}var J=x(V,q);if(J)return J;var re=Object.keys(q),se=E(re);if(V.showHidden&&(re=Object.getOwnPropertyNames(q)),oe(q)&&(re.indexOf("message")>=0||re.indexOf("description")>=0))return F(q);if(re.length===0){if(he(q)){var _e=q.name?": "+q.name:"";return V.stylize("[Function"+_e+"]","special")}if(W(q))return V.stylize(RegExp.prototype.toString.call(q),"regexp");if(G(q))return V.stylize(Date.prototype.toString.call(q),"date");if(oe(q))return F(q)}var be="",Ke=!1,It=["{","}"];if(C(q)&&(Ke=!0,It=["[","]"]),he(q)){var Et=q.name?": "+q.name:"";be=" [Function"+Et+"]"}if(W(q)&&(be=" "+RegExp.prototype.toString.call(q)),G(q)&&(be=" "+Date.prototype.toUTCString.call(q)),oe(q)&&(be=" "+F(q)),re.length===0&&(!Ke||q.length==0))return It[0]+be+It[1];if(D<0)return W(q)?V.stylize(RegExp.prototype.toString.call(q),"regexp"):V.stylize("[Object]","special");V.seen.push(q);var et;return Ke?et=k(V,q,D,se,re):et=re.map(function(Zt){return M(V,q,D,se,Zt,Ke)}),V.seen.pop(),O(et,be,It)}function x(V,q){if($(q))return V.stylize("undefined","undefined");if(z(q)){var D="'"+JSON.stringify(q).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return V.stylize(D,"string")}if(H(q))return V.stylize(""+q,"number");if(P(q))return V.stylize(""+q,"boolean");if(j(q))return V.stylize("null","null")}function F(V){return"["+Error.prototype.toString.call(V)+"]"}function k(V,q,D,K,J){for(var re=[],se=0,_e=q.length;se<_e;++se)Ge(q,String(se))?re.push(M(V,q,D,K,String(se),!0)):re.push("");return J.forEach(function(be){be.match(/^\d+$/)||re.push(M(V,q,D,K,be,!0))}),re}function M(V,q,D,K,J,re){var se,_e,be;if(be=Object.getOwnPropertyDescriptor(q,J)||{value:q[J]},be.get?be.set?_e=V.stylize("[Getter/Setter]","special"):_e=V.stylize("[Getter]","special"):be.set&&(_e=V.stylize("[Setter]","special")),Ge(K,J)||(se="["+J+"]"),_e||(V.seen.indexOf(be.value)<0?(j(D)?_e=S(V,be.value,null):_e=S(V,be.value,D-1),_e.indexOf(` `)>-1&&(re?_e=_e.split(` `).map(function(Ke){return" "+Ke}).join(` `).substr(2):_e=` `+_e.split(` `).map(function(Ke){return" "+Ke}).join(` `))):_e=V.stylize("[Circular]","special")),$(se)){if(re&&J.match(/^\d+$/))return _e;se=JSON.stringify(""+J),se.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(se=se.substr(1,se.length-2),se=V.stylize(se,"name")):(se=se.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),se=V.stylize(se,"string"))}return se+": "+_e}function O(V,q,D){var K=V.reduce(function(J,re){return re.indexOf(` `)>=0,J+re.replace(/\u001b\[\d\d?m/g,"").length+1},0);return K>60?D[0]+(q===""?"":q+` `)+" "+V.join(`, `)+" "+D[1]:D[0]+q+" "+V.join(", ")+" "+D[1]}d.types=f(5955);function C(V){return Array.isArray(V)}d.isArray=C;function P(V){return typeof V=="boolean"}d.isBoolean=P;function j(V){return V===null}d.isNull=j;function R(V){return V==null}d.isNullOrUndefined=R;function H(V){return typeof V=="number"}d.isNumber=H;function z(V){return typeof V=="string"}d.isString=z;function Y(V){return typeof V=="symbol"}d.isSymbol=Y;function $(V){return V===void 0}d.isUndefined=$;function W(V){return X(V)&&Oe(V)==="[object RegExp]"}d.isRegExp=W,d.types.isRegExp=W;function X(V){return typeof V=="object"&&V!==null}d.isObject=X;function G(V){return X(V)&&Oe(V)==="[object Date]"}d.isDate=G,d.types.isDate=G;function oe(V){return X(V)&&(Oe(V)==="[object Error]"||V instanceof Error)}d.isError=oe,d.types.isNativeError=oe;function he(V){return typeof V=="function"}d.isFunction=he;function ie(V){return V===null||typeof V=="boolean"||typeof V=="number"||typeof V=="string"||typeof V=="symbol"||typeof V>"u"}d.isPrimitive=ie,d.isBuffer=f(384);function Oe(V){return Object.prototype.toString.call(V)}function de(V){return V<10?"0"+V.toString(10):V.toString(10)}var Me=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function Fe(){var V=new Date,q=[de(V.getHours()),de(V.getMinutes()),de(V.getSeconds())].join(":");return[V.getDate(),Me[V.getMonth()],q].join(" ")}d.log=function(){console.log("%s - %s",Fe(),d.format.apply(d,arguments))},d.inherits=f(5717),d._extend=function(V,q){if(!q||!X(q))return V;for(var D=Object.keys(q),K=D.length;K--;)V[D[K]]=q[D[K]];return V};function Ge(V,q){return Object.prototype.hasOwnProperty.call(V,q)}var pt=typeof Symbol<"u"?Symbol("util.promisify.custom"):void 0;d.promisify=function(q){if(typeof q!="function")throw new TypeError('The "original" argument must be of type Function');if(pt&&q[pt]){var D=q[pt];if(typeof D!="function")throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(D,pt,{value:D,enumerable:!1,writable:!1,configurable:!0}),D}function D(){for(var K,J,re=new Promise(function(be,Ke){K=be,J=Ke}),se=[],_e=0;_e{var u=f(9804),a=f(6314),m=f(8914),y=m("Object.prototype.toString"),p=f(1405)(),l=p&&typeof Symbol.toStringTag=="symbol",b=a(),L=m("String.prototype.slice"),E={},S=f(4079),x=Object.getPrototypeOf;l&&S&&x&&u(b,function(M){if(typeof f.g[M]=="function"){var O=new f.g[M];if(!(Symbol.toStringTag in O))throw new EvalError("this engine has support for Symbol.toStringTag, but "+M+" does not have the property! Please report this.");var C=x(O),P=S(C,Symbol.toStringTag);if(!P){var j=x(C);P=S(j,Symbol.toStringTag)}E[M]=P.get}});var F=function(O){var C=!1;return u(E,function(P,j){if(!C)try{var R=P.call(O);R===j&&(C=R)}catch{}}),C},k=f(5692);c.exports=function(O){return k(O)?l?F(O):L(y(O),8,-1):!1}},4221:(c,d,f)=>{const a=f(9262).Thrift;f(135),f(2818);const m=f(4494),y=f(3962),p=f(1396),l=f(2607),b=class{constructor(r){this.user=null,this.passwd=null,this.dbname=null,r&&(r.user!==void 0&&r.user!==null&&(this.user=r.user),r.passwd!==void 0&&r.passwd!==null&&(this.passwd=r.passwd),r.dbname!==void 0&&r.dbname!==null&&(this.dbname=r.dbname))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.user=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.passwd=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.dbname=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_connect_args"),this.user!==null&&this.user!==void 0&&(r.writeFieldBegin("user",a.Type.STRING,1),r.writeString(this.user),r.writeFieldEnd()),this.passwd!==null&&this.passwd!==void 0&&(r.writeFieldBegin("passwd",a.Type.STRING,2),r.writeString(this.passwd),r.writeFieldEnd()),this.dbname!==null&&this.dbname!==void 0&&(r.writeFieldBegin("dbname",a.Type.STRING,3),r.writeString(this.dbname),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},L=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_connect_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},E=class{constructor(r){this.inputToken=null,this.dbname=null,r&&(r.inputToken!==void 0&&r.inputToken!==null&&(this.inputToken=r.inputToken),r.dbname!==void 0&&r.dbname!==null&&(this.dbname=r.dbname))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.inputToken=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.dbname=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_krb5_connect_args"),this.inputToken!==null&&this.inputToken!==void 0&&(r.writeFieldBegin("inputToken",a.Type.STRING,1),r.writeString(this.inputToken),r.writeFieldEnd()),this.dbname!==null&&this.dbname!==void 0&&(r.writeFieldBegin("dbname",a.Type.STRING,2),r.writeString(this.dbname),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},S=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TKrb5Session(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TKrb5Session,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_krb5_connect_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},x=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_disconnect_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},F=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_disconnect_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},k=class{constructor(r){this.session=null,this.dbname=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dbname!==void 0&&r.dbname!==null&&(this.dbname=r.dbname))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.dbname=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_switch_database_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dbname!==null&&this.dbname!==void 0&&(r.writeFieldBegin("dbname",a.Type.STRING,2),r.writeString(this.dbname),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},M=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_switch_database_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},O=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clone_session_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},C=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clone_session_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},P=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_server_status_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},j=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TServerStatus(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TServerStatus,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_server_status_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},R=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_status_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},H=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TServerStatus])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TServerStatus,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_status_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},z=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_hardware_info_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Y=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TClusterHardwareInfo(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TClusterHardwareInfo,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_hardware_info_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},$=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_tables_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},W=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_tables_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},X=class{constructor(r){this.session=null,this.database_name=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.database_name!==void 0&&r.database_name!==null&&(this.database_name=r.database_name))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.database_name=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_tables_for_database_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.database_name!==null&&this.database_name!==void 0&&(r.writeFieldBegin("database_name",a.Type.STRING,2),r.writeString(this.database_name),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},G=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_tables_for_database_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},oe=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_physical_tables_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},he=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_physical_tables_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ie=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_views_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Oe=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_views_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},de=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_tables_meta_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Me=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TTableMeta])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TTableMeta,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_tables_meta_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Fe=class{constructor(r){this.session=null,this.table_name=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_details_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ge=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TTableDetails(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TTableDetails,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_details_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},pt=class{constructor(r){this.session=null,this.table_name=null,this.database_name=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.database_name!==void 0&&r.database_name!==null&&(this.database_name=r.database_name))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.database_name=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_details_for_database_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.database_name!==null&&this.database_name!==void 0&&(r.writeFieldBegin("database_name",a.Type.STRING,3),r.writeString(this.database_name),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ht=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TTableDetails(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TTableDetails,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_details_for_database_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ge=class{constructor(r){this.session=null,this.table_name=null,this.include_system_columns=!0,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.include_system_columns!==void 0&&r.include_system_columns!==null&&(this.include_system_columns=r.include_system_columns))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.BOOL?this.include_system_columns=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_internal_table_details_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.include_system_columns!==null&&this.include_system_columns!==void 0&&(r.writeFieldBegin("include_system_columns",a.Type.BOOL,3),r.writeBool(this.include_system_columns),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},V=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TTableDetails(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TTableDetails,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_internal_table_details_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},q=class{constructor(r){this.session=null,this.table_name=null,this.database_name=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.database_name!==void 0&&r.database_name!==null&&(this.database_name=r.database_name))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.database_name=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_internal_table_details_for_database_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.database_name!==null&&this.database_name!==void 0&&(r.writeFieldBegin("database_name",a.Type.STRING,3),r.writeString(this.database_name),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},D=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TTableDetails(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TTableDetails,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_internal_table_details_for_database_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},K=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_users_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},J=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_users_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},re=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_databases_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},se=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TDBInfo])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TDBInfo,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_databases_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},_e=class{constructor(r){}read(r){for(r.readStructBegin();;){const g=r.readFieldBegin().ftype;if(g==a.Type.STOP)break;r.skip(g),r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_version_args"),r.writeFieldStop(),r.writeStructEnd()}},be=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_version_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ke=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_start_heap_profile_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},It=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_start_heap_profile_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Et=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_stop_heap_profile_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},et=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_stop_heap_profile_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Zt=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_heap_profile_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},kn=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_heap_profile_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Yi=class{constructor(r){this.session=null,this.memory_level=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.memory_level!==void 0&&r.memory_level!==null&&(this.memory_level=r.memory_level))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.memory_level=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_memory_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.memory_level!==null&&this.memory_level!==void 0&&(r.writeFieldBegin("memory_level",a.Type.STRING,2),r.writeString(this.memory_level),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},fe=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TNodeMemoryInfo])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TNodeMemoryInfo,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_memory_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},oi=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clear_cpu_memory_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},jn=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clear_cpu_memory_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ur=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clear_gpu_memory_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ln=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_clear_gpu_memory_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},cl=class{constructor(r){this.parent_session=null,this.leaf_session=null,this.start_time_str=null,this.label=null,this.for_running_query_kernel=null,r&&(r.parent_session!==void 0&&r.parent_session!==null&&(this.parent_session=r.parent_session),r.leaf_session!==void 0&&r.leaf_session!==null&&(this.leaf_session=r.leaf_session),r.start_time_str!==void 0&&r.start_time_str!==null&&(this.start_time_str=r.start_time_str),r.label!==void 0&&r.label!==null&&(this.label=r.label),r.for_running_query_kernel!==void 0&&r.for_running_query_kernel!==null&&(this.for_running_query_kernel=r.for_running_query_kernel))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.parent_session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.leaf_session=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.start_time_str=r.readString():r.skip(g);break;case 4:g==a.Type.STRING?this.label=r.readString():r.skip(g);break;case 5:g==a.Type.BOOL?this.for_running_query_kernel=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_cur_session_args"),this.parent_session!==null&&this.parent_session!==void 0&&(r.writeFieldBegin("parent_session",a.Type.STRING,1),r.writeString(this.parent_session),r.writeFieldEnd()),this.leaf_session!==null&&this.leaf_session!==void 0&&(r.writeFieldBegin("leaf_session",a.Type.STRING,2),r.writeString(this.leaf_session),r.writeFieldEnd()),this.start_time_str!==null&&this.start_time_str!==void 0&&(r.writeFieldBegin("start_time_str",a.Type.STRING,3),r.writeString(this.start_time_str),r.writeFieldEnd()),this.label!==null&&this.label!==void 0&&(r.writeFieldBegin("label",a.Type.STRING,4),r.writeString(this.label),r.writeFieldEnd()),this.for_running_query_kernel!==null&&this.for_running_query_kernel!==void 0&&(r.writeFieldBegin("for_running_query_kernel",a.Type.BOOL,5),r.writeBool(this.for_running_query_kernel),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},dl=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_cur_session_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ts=class{constructor(r){this.parent_session=null,this.leaf_session=null,this.start_time_str=null,this.label=null,this.for_running_query_kernel=null,r&&(r.parent_session!==void 0&&r.parent_session!==null&&(this.parent_session=r.parent_session),r.leaf_session!==void 0&&r.leaf_session!==null&&(this.leaf_session=r.leaf_session),r.start_time_str!==void 0&&r.start_time_str!==null&&(this.start_time_str=r.start_time_str),r.label!==void 0&&r.label!==null&&(this.label=r.label),r.for_running_query_kernel!==void 0&&r.for_running_query_kernel!==null&&(this.for_running_query_kernel=r.for_running_query_kernel))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.parent_session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.leaf_session=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.start_time_str=r.readString():r.skip(g);break;case 4:g==a.Type.STRING?this.label=r.readString():r.skip(g);break;case 5:g==a.Type.BOOL?this.for_running_query_kernel=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_invalidate_cur_session_args"),this.parent_session!==null&&this.parent_session!==void 0&&(r.writeFieldBegin("parent_session",a.Type.STRING,1),r.writeString(this.parent_session),r.writeFieldEnd()),this.leaf_session!==null&&this.leaf_session!==void 0&&(r.writeFieldBegin("leaf_session",a.Type.STRING,2),r.writeString(this.leaf_session),r.writeFieldEnd()),this.start_time_str!==null&&this.start_time_str!==void 0&&(r.writeFieldBegin("start_time_str",a.Type.STRING,3),r.writeString(this.start_time_str),r.writeFieldEnd()),this.label!==null&&this.label!==void 0&&(r.writeFieldBegin("label",a.Type.STRING,4),r.writeString(this.label),r.writeFieldEnd()),this.for_running_query_kernel!==null&&this.for_running_query_kernel!==void 0&&(r.writeFieldBegin("for_running_query_kernel",a.Type.BOOL,5),r.writeBool(this.for_running_query_kernel),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},fl=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_invalidate_cur_session_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},N=class{constructor(r){this.session=null,this.db_id=null,this.table_id=null,this.new_epoch=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.db_id!==void 0&&r.db_id!==null&&(this.db_id=r.db_id),r.table_id!==void 0&&r.table_id!==null&&(this.table_id=r.table_id),r.new_epoch!==void 0&&r.new_epoch!==null&&(this.new_epoch=r.new_epoch))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.db_id=r.readI32():r.skip(g);break;case 3:g==a.Type.I32?this.table_id=r.readI32():r.skip(g);break;case 4:g==a.Type.I32?this.new_epoch=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_table_epoch_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.db_id!==null&&this.db_id!==void 0&&(r.writeFieldBegin("db_id",a.Type.I32,2),r.writeI32(this.db_id),r.writeFieldEnd()),this.table_id!==null&&this.table_id!==void 0&&(r.writeFieldBegin("table_id",a.Type.I32,3),r.writeI32(this.table_id),r.writeFieldEnd()),this.new_epoch!==null&&this.new_epoch!==void 0&&(r.writeFieldBegin("new_epoch",a.Type.I32,4),r.writeI32(this.new_epoch),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},I=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_table_epoch_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},A=class{constructor(r){this.session=null,this.table_name=null,this.new_epoch=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.new_epoch!==void 0&&r.new_epoch!==null&&(this.new_epoch=r.new_epoch))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.I32?this.new_epoch=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_table_epoch_by_name_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.new_epoch!==null&&this.new_epoch!==void 0&&(r.writeFieldBegin("new_epoch",a.Type.I32,3),r.writeI32(this.new_epoch),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},U=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_table_epoch_by_name_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Z=class{constructor(r){this.session=null,this.db_id=null,this.table_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.db_id!==void 0&&r.db_id!==null&&(this.db_id=r.db_id),r.table_id!==void 0&&r.table_id!==null&&(this.table_id=r.table_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.db_id=r.readI32():r.skip(g);break;case 3:g==a.Type.I32?this.table_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_epoch_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.db_id!==null&&this.db_id!==void 0&&(r.writeFieldBegin("db_id",a.Type.I32,2),r.writeI32(this.db_id),r.writeFieldEnd()),this.table_id!==null&&this.table_id!==void 0&&(r.writeFieldBegin("table_id",a.Type.I32,3),r.writeI32(this.table_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ee=class{constructor(r){this.success=null,r&&r.success!==void 0&&r.success!==null&&(this.success=r.success)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.I32?this.success=r.readI32():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_epoch_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.I32,0),r.writeI32(this.success),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ne=class{constructor(r){this.session=null,this.table_name=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_epoch_by_name_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Be=class{constructor(r){this.success=null,r&&r.success!==void 0&&r.success!==null&&(this.success=r.success)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.I32?this.success=r.readI32():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_epoch_by_name_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.I32,0),r.writeI32(this.success),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},je=class{constructor(r){this.session=null,this.db_id=null,this.table_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.db_id!==void 0&&r.db_id!==null&&(this.db_id=r.db_id),r.table_id!==void 0&&r.table_id!==null&&(this.table_id=r.table_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.db_id=r.readI32():r.skip(g);break;case 3:g==a.Type.I32?this.table_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_table_epochs_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.db_id!==null&&this.db_id!==void 0&&(r.writeFieldBegin("db_id",a.Type.I32,2),r.writeI32(this.db_id),r.writeFieldEnd()),this.table_id!==null&&this.table_id!==void 0&&(r.writeFieldBegin("table_id",a.Type.I32,3),r.writeI32(this.table_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ue=class{constructor(r){this.success=null,r&&r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TTableEpochInfo]))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TTableEpochInfo,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_table_epochs_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},Ye=class{constructor(r){this.session=null,this.db_id=null,this.table_epochs=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.db_id!==void 0&&r.db_id!==null&&(this.db_id=r.db_id),r.table_epochs!==void 0&&r.table_epochs!==null&&(this.table_epochs=a.copyList(r.table_epochs,[l.TTableEpochInfo])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.db_id=r.readI32():r.skip(g);break;case 3:if(g==a.Type.LIST){this.table_epochs=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TTableEpochInfo,B.read(r),this.table_epochs.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_set_table_epochs_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.db_id!==null&&this.db_id!==void 0&&(r.writeFieldBegin("db_id",a.Type.I32,2),r.writeI32(this.db_id),r.writeFieldEnd()),this.table_epochs!==null&&this.table_epochs!==void 0){r.writeFieldBegin("table_epochs",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.table_epochs.length);for(let w in this.table_epochs)this.table_epochs.hasOwnProperty(w)&&(w=this.table_epochs[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},Xe=class{constructor(r){}read(r){for(r.readStructBegin();;){const g=r.readFieldBegin().ftype;if(g==a.Type.STOP)break;r.skip(g),r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_table_epochs_result"),r.writeFieldStop(),r.writeStructEnd()}},ul=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_session_info_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},g3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TSessionInfo(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TSessionInfo,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_session_info_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},gx=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_queries_info_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},_3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TQueryInfo])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TQueryInfo,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_queries_info_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},_x=class{constructor(r){this.session=null,this.leaf_info=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.leaf_info!==void 0&&r.leaf_info!==null&&(this.leaf_info=new l.TLeafInfo(r.leaf_info)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRUCT?(this.leaf_info=new l.TLeafInfo,this.leaf_info.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_leaf_info_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.leaf_info!==null&&this.leaf_info!==void 0&&(r.writeFieldBegin("leaf_info",a.Type.STRUCT,2),this.leaf_info.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},p3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_leaf_info_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},px=class{constructor(r){this.session=null,this.query=null,this.column_format=null,this.nonce=null,this.first_n=-1,this.at_most_n=-1,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.query!==void 0&&r.query!==null&&(this.query=r.query),r.column_format!==void 0&&r.column_format!==null&&(this.column_format=r.column_format),r.nonce!==void 0&&r.nonce!==null&&(this.nonce=r.nonce),r.first_n!==void 0&&r.first_n!==null&&(this.first_n=r.first_n),r.at_most_n!==void 0&&r.at_most_n!==null&&(this.at_most_n=r.at_most_n))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.query=r.readString():r.skip(g);break;case 3:g==a.Type.BOOL?this.column_format=r.readBool():r.skip(g);break;case 4:g==a.Type.STRING?this.nonce=r.readString():r.skip(g);break;case 5:g==a.Type.I32?this.first_n=r.readI32():r.skip(g);break;case 6:g==a.Type.I32?this.at_most_n=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.query!==null&&this.query!==void 0&&(r.writeFieldBegin("query",a.Type.STRING,2),r.writeString(this.query),r.writeFieldEnd()),this.column_format!==null&&this.column_format!==void 0&&(r.writeFieldBegin("column_format",a.Type.BOOL,3),r.writeBool(this.column_format),r.writeFieldEnd()),this.nonce!==null&&this.nonce!==void 0&&(r.writeFieldBegin("nonce",a.Type.STRING,4),r.writeString(this.nonce),r.writeFieldEnd()),this.first_n!==null&&this.first_n!==void 0&&(r.writeFieldBegin("first_n",a.Type.I32,5),r.writeI32(this.first_n),r.writeFieldEnd()),this.at_most_n!==null&&this.at_most_n!==void 0&&(r.writeFieldBegin("at_most_n",a.Type.I32,6),r.writeI32(this.at_most_n),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},y3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TQueryResult(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TQueryResult,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},yx=class{constructor(r){this.session=null,this.query=null,this.device_type=null,this.device_id=0,this.first_n=-1,this.transport_method=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.query!==void 0&&r.query!==null&&(this.query=r.query),r.device_type!==void 0&&r.device_type!==null&&(this.device_type=r.device_type),r.device_id!==void 0&&r.device_id!==null&&(this.device_id=r.device_id),r.first_n!==void 0&&r.first_n!==null&&(this.first_n=r.first_n),r.transport_method!==void 0&&r.transport_method!==null&&(this.transport_method=r.transport_method))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.query=r.readString():r.skip(g);break;case 3:g==a.Type.I32?this.device_type=r.readI32():r.skip(g);break;case 4:g==a.Type.I32?this.device_id=r.readI32():r.skip(g);break;case 5:g==a.Type.I32?this.first_n=r.readI32():r.skip(g);break;case 6:g==a.Type.I32?this.transport_method=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_df_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.query!==null&&this.query!==void 0&&(r.writeFieldBegin("query",a.Type.STRING,2),r.writeString(this.query),r.writeFieldEnd()),this.device_type!==null&&this.device_type!==void 0&&(r.writeFieldBegin("device_type",a.Type.I32,3),r.writeI32(this.device_type),r.writeFieldEnd()),this.device_id!==null&&this.device_id!==void 0&&(r.writeFieldBegin("device_id",a.Type.I32,4),r.writeI32(this.device_id),r.writeFieldEnd()),this.first_n!==null&&this.first_n!==void 0&&(r.writeFieldBegin("first_n",a.Type.I32,5),r.writeI32(this.first_n),r.writeFieldEnd()),this.transport_method!==null&&this.transport_method!==void 0&&(r.writeFieldBegin("transport_method",a.Type.I32,6),r.writeI32(this.transport_method),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},m3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TDataFrame(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TDataFrame,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_df_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},mx=class{constructor(r){this.session=null,this.query=null,this.device_id=0,this.first_n=-1,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.query!==void 0&&r.query!==null&&(this.query=r.query),r.device_id!==void 0&&r.device_id!==null&&(this.device_id=r.device_id),r.first_n!==void 0&&r.first_n!==null&&(this.first_n=r.first_n))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.query=r.readString():r.skip(g);break;case 3:g==a.Type.I32?this.device_id=r.readI32():r.skip(g);break;case 4:g==a.Type.I32?this.first_n=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_gdf_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.query!==null&&this.query!==void 0&&(r.writeFieldBegin("query",a.Type.STRING,2),r.writeString(this.query),r.writeFieldEnd()),this.device_id!==null&&this.device_id!==void 0&&(r.writeFieldBegin("device_id",a.Type.I32,3),r.writeI32(this.device_id),r.writeFieldEnd()),this.first_n!==null&&this.first_n!==void 0&&(r.writeFieldBegin("first_n",a.Type.I32,4),r.writeI32(this.first_n),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},w3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TDataFrame(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TDataFrame,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_execute_gdf_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},wx=class{constructor(r){this.session=null,this.df=null,this.device_type=null,this.device_id=0,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.df!==void 0&&r.df!==null&&(this.df=new l.TDataFrame(r.df)),r.device_type!==void 0&&r.device_type!==null&&(this.device_type=r.device_type),r.device_id!==void 0&&r.device_id!==null&&(this.device_id=r.device_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRUCT?(this.df=new l.TDataFrame,this.df.read(r)):r.skip(g);break;case 3:g==a.Type.I32?this.device_type=r.readI32():r.skip(g);break;case 4:g==a.Type.I32?this.device_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_deallocate_df_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.df!==null&&this.df!==void 0&&(r.writeFieldBegin("df",a.Type.STRUCT,2),this.df.write(r),r.writeFieldEnd()),this.device_type!==null&&this.device_type!==void 0&&(r.writeFieldBegin("device_type",a.Type.I32,3),r.writeI32(this.device_type),r.writeFieldEnd()),this.device_id!==null&&this.device_id!==void 0&&(r.writeFieldBegin("device_id",a.Type.I32,4),r.writeI32(this.device_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},L3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_deallocate_df_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Lx=class{constructor(r){this.query_session=null,this.interrupt_session=null,r&&(r.query_session!==void 0&&r.query_session!==null&&(this.query_session=r.query_session),r.interrupt_session!==void 0&&r.interrupt_session!==null&&(this.interrupt_session=r.interrupt_session))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.query_session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.interrupt_session=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_interrupt_args"),this.query_session!==null&&this.query_session!==void 0&&(r.writeFieldBegin("query_session",a.Type.STRING,1),r.writeString(this.query_session),r.writeFieldEnd()),this.interrupt_session!==null&&this.interrupt_session!==void 0&&(r.writeFieldBegin("interrupt_session",a.Type.STRING,2),r.writeString(this.interrupt_session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},b3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_interrupt_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},bx=class{constructor(r){this.session=null,this.query=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.query!==void 0&&r.query!==null&&(this.query=r.query))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.query=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_sql_validate_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.query!==null&&this.query!==void 0&&(r.writeFieldBegin("query",a.Type.STRING,2),r.writeString(this.query),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},T3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TColumnType])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumnType,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_sql_validate_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Tx=class{constructor(r){this.session=null,this.sql=null,this.cursor=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.sql!==void 0&&r.sql!==null&&(this.sql=r.sql),r.cursor!==void 0&&r.cursor!==null&&(this.cursor=r.cursor))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.sql=r.readString():r.skip(g);break;case 3:g==a.Type.I32?this.cursor=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_completion_hints_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.sql!==null&&this.sql!==void 0&&(r.writeFieldBegin("sql",a.Type.STRING,2),r.writeString(this.sql),r.writeFieldEnd()),this.cursor!==null&&this.cursor!==void 0&&(r.writeFieldBegin("cursor",a.Type.I32,3),r.writeI32(this.cursor),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},v3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[m.TCompletionHint])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new m.TCompletionHint,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_completion_hints_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},vx=class{constructor(r){this.session=null,this.mode=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.mode!==void 0&&r.mode!==null&&(this.mode=r.mode))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.mode=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_execution_mode_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.mode!==null&&this.mode!==void 0&&(r.writeFieldBegin("mode",a.Type.I32,2),r.writeI32(this.mode),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},E3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_set_execution_mode_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ex=class{constructor(r){this.session=null,this.widget_id=null,this.vega_json=null,this.compression_level=null,this.nonce=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.widget_id!==void 0&&r.widget_id!==null&&(this.widget_id=r.widget_id),r.vega_json!==void 0&&r.vega_json!==null&&(this.vega_json=r.vega_json),r.compression_level!==void 0&&r.compression_level!==null&&(this.compression_level=r.compression_level),r.nonce!==void 0&&r.nonce!==null&&(this.nonce=r.nonce))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I64?this.widget_id=r.readI64():r.skip(g);break;case 3:g==a.Type.STRING?this.vega_json=r.readString():r.skip(g);break;case 4:g==a.Type.I32?this.compression_level=r.readI32():r.skip(g);break;case 5:g==a.Type.STRING?this.nonce=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_render_vega_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.widget_id!==null&&this.widget_id!==void 0&&(r.writeFieldBegin("widget_id",a.Type.I64,2),r.writeI64(this.widget_id),r.writeFieldEnd()),this.vega_json!==null&&this.vega_json!==void 0&&(r.writeFieldBegin("vega_json",a.Type.STRING,3),r.writeString(this.vega_json),r.writeFieldEnd()),this.compression_level!==null&&this.compression_level!==void 0&&(r.writeFieldBegin("compression_level",a.Type.I32,4),r.writeI32(this.compression_level),r.writeFieldEnd()),this.nonce!==null&&this.nonce!==void 0&&(r.writeFieldBegin("nonce",a.Type.STRING,5),r.writeString(this.nonce),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},S3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TRenderResult(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TRenderResult,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_render_vega_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Sx=class{constructor(r){this.session=null,this.widget_id=null,this.pixel=null,this.table_col_names=null,this.column_format=null,this.pixelRadius=null,this.nonce=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.widget_id!==void 0&&r.widget_id!==null&&(this.widget_id=r.widget_id),r.pixel!==void 0&&r.pixel!==null&&(this.pixel=new l.TPixel(r.pixel)),r.table_col_names!==void 0&&r.table_col_names!==null&&(this.table_col_names=a.copyMap(r.table_col_names,[a.copyList,null])),r.column_format!==void 0&&r.column_format!==null&&(this.column_format=r.column_format),r.pixelRadius!==void 0&&r.pixelRadius!==null&&(this.pixelRadius=r.pixelRadius),r.nonce!==void 0&&r.nonce!==null&&(this.nonce=r.nonce))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I64?this.widget_id=r.readI64():r.skip(g);break;case 3:g==a.Type.STRUCT?(this.pixel=new l.TPixel,this.pixel.read(r)):r.skip(g);break;case 4:if(g==a.Type.MAP){this.table_col_names={};const _=r.readMapBegin().size||0;for(let v=0;v<_;++v){let B=null,Q=null;B=r.readString(),Q=[];const $e=r.readListBegin().size||0;for(let sn=0;sn<$e;++sn){let fo=null;fo=r.readString(),Q.push(fo)}r.readListEnd(),this.table_col_names[B]=Q}r.readMapEnd()}else r.skip(g);break;case 5:g==a.Type.BOOL?this.column_format=r.readBool():r.skip(g);break;case 6:g==a.Type.I32?this.pixelRadius=r.readI32():r.skip(g);break;case 7:g==a.Type.STRING?this.nonce=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_result_row_for_pixel_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.widget_id!==null&&this.widget_id!==void 0&&(r.writeFieldBegin("widget_id",a.Type.I64,2),r.writeI64(this.widget_id),r.writeFieldEnd()),this.pixel!==null&&this.pixel!==void 0&&(r.writeFieldBegin("pixel",a.Type.STRUCT,3),this.pixel.write(r),r.writeFieldEnd()),this.table_col_names!==null&&this.table_col_names!==void 0){r.writeFieldBegin("table_col_names",a.Type.MAP,4),r.writeMapBegin(a.Type.STRING,a.Type.LIST,a.objectLength(this.table_col_names));for(let w in this.table_col_names)if(this.table_col_names.hasOwnProperty(w)){let g=this.table_col_names[w];r.writeString(w),r.writeListBegin(a.Type.STRING,g.length);for(let h in g)g.hasOwnProperty(h)&&(h=g[h],r.writeString(h));r.writeListEnd()}r.writeMapEnd(),r.writeFieldEnd()}this.column_format!==null&&this.column_format!==void 0&&(r.writeFieldBegin("column_format",a.Type.BOOL,5),r.writeBool(this.column_format),r.writeFieldEnd()),this.pixelRadius!==null&&this.pixelRadius!==void 0&&(r.writeFieldBegin("pixelRadius",a.Type.I32,6),r.writeI32(this.pixelRadius),r.writeFieldEnd()),this.nonce!==null&&this.nonce!==void 0&&(r.writeFieldBegin("nonce",a.Type.STRING,7),r.writeString(this.nonce),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},x3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TPixelTableRowResult(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TPixelTableRowResult,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_result_row_for_pixel_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},xx=class{constructor(r){this.session=null,this.custom_expression=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.custom_expression!==void 0&&r.custom_expression!==null&&(this.custom_expression=new l.TCustomExpression(r.custom_expression)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRUCT?(this.custom_expression=new l.TCustomExpression,this.custom_expression.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_custom_expression_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.custom_expression!==null&&this.custom_expression!==void 0&&(r.writeFieldBegin("custom_expression",a.Type.STRUCT,2),this.custom_expression.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},k3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.I32?this.success=r.readI32():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_custom_expression_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.I32,0),r.writeI32(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},kx=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_custom_expressions_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},B3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TCustomExpression])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TCustomExpression,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_custom_expressions_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Bx=class{constructor(r){this.session=null,this.id=null,this.expression_json=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.id!==void 0&&r.id!==null&&(this.id=r.id),r.expression_json!==void 0&&r.expression_json!==null&&(this.expression_json=r.expression_json))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.id=r.readI32():r.skip(g);break;case 3:g==a.Type.STRING?this.expression_json=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_update_custom_expression_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.id!==null&&this.id!==void 0&&(r.writeFieldBegin("id",a.Type.I32,2),r.writeI32(this.id),r.writeFieldEnd()),this.expression_json!==null&&this.expression_json!==void 0&&(r.writeFieldBegin("expression_json",a.Type.STRING,3),r.writeString(this.expression_json),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},F3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_update_custom_expression_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Fx=class{constructor(r){this.session=null,this.custom_expression_ids=null,this.do_soft_delete=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.custom_expression_ids!==void 0&&r.custom_expression_ids!==null&&(this.custom_expression_ids=a.copyList(r.custom_expression_ids,[null])),r.do_soft_delete!==void 0&&r.do_soft_delete!==null&&(this.do_soft_delete=r.do_soft_delete))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:if(g==a.Type.LIST){this.custom_expression_ids=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readI32(),this.custom_expression_ids.push(B)}r.readListEnd()}else r.skip(g);break;case 3:g==a.Type.BOOL?this.do_soft_delete=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_delete_custom_expressions_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.custom_expression_ids!==null&&this.custom_expression_ids!==void 0){r.writeFieldBegin("custom_expression_ids",a.Type.LIST,2),r.writeListBegin(a.Type.I32,this.custom_expression_ids.length);for(let w in this.custom_expression_ids)this.custom_expression_ids.hasOwnProperty(w)&&(w=this.custom_expression_ids[w],r.writeI32(w));r.writeListEnd(),r.writeFieldEnd()}this.do_soft_delete!==null&&this.do_soft_delete!==void 0&&(r.writeFieldBegin("do_soft_delete",a.Type.BOOL,3),r.writeBool(this.do_soft_delete),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},I3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_delete_custom_expressions_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ix=class{constructor(r){this.session=null,this.dashboard_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},O3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TDashboard(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TDashboard,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_dashboard_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ox=class{constructor(r){this.session=null,r&&r.session!==void 0&&r.session!==null&&(this.session=r.session)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_dashboards_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},M3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TDashboard])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TDashboard,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_dashboards_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Mx=class{constructor(r){this.session=null,this.dashboard_name=null,this.dashboard_state=null,this.image_hash=null,this.dashboard_metadata=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_name!==void 0&&r.dashboard_name!==null&&(this.dashboard_name=r.dashboard_name),r.dashboard_state!==void 0&&r.dashboard_state!==null&&(this.dashboard_state=r.dashboard_state),r.image_hash!==void 0&&r.image_hash!==null&&(this.image_hash=r.image_hash),r.dashboard_metadata!==void 0&&r.dashboard_metadata!==null&&(this.dashboard_metadata=r.dashboard_metadata))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.dashboard_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.dashboard_state=r.readString():r.skip(g);break;case 4:g==a.Type.STRING?this.image_hash=r.readString():r.skip(g);break;case 5:g==a.Type.STRING?this.dashboard_metadata=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_name!==null&&this.dashboard_name!==void 0&&(r.writeFieldBegin("dashboard_name",a.Type.STRING,2),r.writeString(this.dashboard_name),r.writeFieldEnd()),this.dashboard_state!==null&&this.dashboard_state!==void 0&&(r.writeFieldBegin("dashboard_state",a.Type.STRING,3),r.writeString(this.dashboard_state),r.writeFieldEnd()),this.image_hash!==null&&this.image_hash!==void 0&&(r.writeFieldBegin("image_hash",a.Type.STRING,4),r.writeString(this.image_hash),r.writeFieldEnd()),this.dashboard_metadata!==null&&this.dashboard_metadata!==void 0&&(r.writeFieldBegin("dashboard_metadata",a.Type.STRING,5),r.writeString(this.dashboard_metadata),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},A3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.I32?this.success=r.readI32():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_dashboard_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.I32,0),r.writeI32(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ax=class{constructor(r){this.session=null,this.dashboard_id=null,this.dashboard_name=null,this.dashboard_owner=null,this.dashboard_state=null,this.image_hash=null,this.dashboard_metadata=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id),r.dashboard_name!==void 0&&r.dashboard_name!==null&&(this.dashboard_name=r.dashboard_name),r.dashboard_owner!==void 0&&r.dashboard_owner!==null&&(this.dashboard_owner=r.dashboard_owner),r.dashboard_state!==void 0&&r.dashboard_state!==null&&(this.dashboard_state=r.dashboard_state),r.image_hash!==void 0&&r.image_hash!==null&&(this.image_hash=r.image_hash),r.dashboard_metadata!==void 0&&r.dashboard_metadata!==null&&(this.dashboard_metadata=r.dashboard_metadata))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;case 3:g==a.Type.STRING?this.dashboard_name=r.readString():r.skip(g);break;case 4:g==a.Type.STRING?this.dashboard_owner=r.readString():r.skip(g);break;case 5:g==a.Type.STRING?this.dashboard_state=r.readString():r.skip(g);break;case 6:g==a.Type.STRING?this.image_hash=r.readString():r.skip(g);break;case 7:g==a.Type.STRING?this.dashboard_metadata=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_replace_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),this.dashboard_name!==null&&this.dashboard_name!==void 0&&(r.writeFieldBegin("dashboard_name",a.Type.STRING,3),r.writeString(this.dashboard_name),r.writeFieldEnd()),this.dashboard_owner!==null&&this.dashboard_owner!==void 0&&(r.writeFieldBegin("dashboard_owner",a.Type.STRING,4),r.writeString(this.dashboard_owner),r.writeFieldEnd()),this.dashboard_state!==null&&this.dashboard_state!==void 0&&(r.writeFieldBegin("dashboard_state",a.Type.STRING,5),r.writeString(this.dashboard_state),r.writeFieldEnd()),this.image_hash!==null&&this.image_hash!==void 0&&(r.writeFieldBegin("image_hash",a.Type.STRING,6),r.writeString(this.image_hash),r.writeFieldEnd()),this.dashboard_metadata!==null&&this.dashboard_metadata!==void 0&&(r.writeFieldBegin("dashboard_metadata",a.Type.STRING,7),r.writeString(this.dashboard_metadata),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},N3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_replace_dashboard_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Nx=class{constructor(r){this.session=null,this.dashboard_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_delete_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},C3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_delete_dashboard_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Cx=class{constructor(r){this.session=null,this.dashboard_ids=null,this.groups=null,this.permissions=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_ids!==void 0&&r.dashboard_ids!==null&&(this.dashboard_ids=a.copyList(r.dashboard_ids,[null])),r.groups!==void 0&&r.groups!==null&&(this.groups=a.copyList(r.groups,[null])),r.permissions!==void 0&&r.permissions!==null&&(this.permissions=new l.TDashboardPermissions(r.permissions)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:if(g==a.Type.LIST){this.dashboard_ids=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readI32(),this.dashboard_ids.push(B)}r.readListEnd()}else r.skip(g);break;case 3:if(g==a.Type.LIST){this.groups=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.groups.push(B)}r.readListEnd()}else r.skip(g);break;case 4:g==a.Type.STRUCT?(this.permissions=new l.TDashboardPermissions,this.permissions.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_share_dashboards_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_ids!==null&&this.dashboard_ids!==void 0){r.writeFieldBegin("dashboard_ids",a.Type.LIST,2),r.writeListBegin(a.Type.I32,this.dashboard_ids.length);for(let w in this.dashboard_ids)this.dashboard_ids.hasOwnProperty(w)&&(w=this.dashboard_ids[w],r.writeI32(w));r.writeListEnd(),r.writeFieldEnd()}if(this.groups!==null&&this.groups!==void 0){r.writeFieldBegin("groups",a.Type.LIST,3),r.writeListBegin(a.Type.STRING,this.groups.length);for(let w in this.groups)this.groups.hasOwnProperty(w)&&(w=this.groups[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.permissions!==null&&this.permissions!==void 0&&(r.writeFieldBegin("permissions",a.Type.STRUCT,4),this.permissions.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},R3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_share_dashboards_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Rx=class{constructor(r){this.session=null,this.dashboard_ids=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_ids!==void 0&&r.dashboard_ids!==null&&(this.dashboard_ids=a.copyList(r.dashboard_ids,[null])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:if(g==a.Type.LIST){this.dashboard_ids=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readI32(),this.dashboard_ids.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_delete_dashboards_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_ids!==null&&this.dashboard_ids!==void 0){r.writeFieldBegin("dashboard_ids",a.Type.LIST,2),r.writeListBegin(a.Type.I32,this.dashboard_ids.length);for(let w in this.dashboard_ids)this.dashboard_ids.hasOwnProperty(w)&&(w=this.dashboard_ids[w],r.writeI32(w));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},P3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_delete_dashboards_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Px=class{constructor(r){this.session=null,this.dashboard_id=null,this.groups=null,this.objects=null,this.permissions=null,this.grant_role=!1,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id),r.groups!==void 0&&r.groups!==null&&(this.groups=a.copyList(r.groups,[null])),r.objects!==void 0&&r.objects!==null&&(this.objects=a.copyList(r.objects,[null])),r.permissions!==void 0&&r.permissions!==null&&(this.permissions=new l.TDashboardPermissions(r.permissions)),r.grant_role!==void 0&&r.grant_role!==null&&(this.grant_role=r.grant_role))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;case 3:if(g==a.Type.LIST){this.groups=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.groups.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.objects=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.objects.push(B)}r.readListEnd()}else r.skip(g);break;case 5:g==a.Type.STRUCT?(this.permissions=new l.TDashboardPermissions,this.permissions.read(r)):r.skip(g);break;case 6:g==a.Type.BOOL?this.grant_role=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_share_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),this.groups!==null&&this.groups!==void 0){r.writeFieldBegin("groups",a.Type.LIST,3),r.writeListBegin(a.Type.STRING,this.groups.length);for(let w in this.groups)this.groups.hasOwnProperty(w)&&(w=this.groups[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}if(this.objects!==null&&this.objects!==void 0){r.writeFieldBegin("objects",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.objects.length);for(let w in this.objects)this.objects.hasOwnProperty(w)&&(w=this.objects[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.permissions!==null&&this.permissions!==void 0&&(r.writeFieldBegin("permissions",a.Type.STRUCT,5),this.permissions.write(r),r.writeFieldEnd()),this.grant_role!==null&&this.grant_role!==void 0&&(r.writeFieldBegin("grant_role",a.Type.BOOL,6),r.writeBool(this.grant_role),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},D3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_share_dashboard_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Dx=class{constructor(r){this.session=null,this.dashboard_id=null,this.groups=null,this.objects=null,this.permissions=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id),r.groups!==void 0&&r.groups!==null&&(this.groups=a.copyList(r.groups,[null])),r.objects!==void 0&&r.objects!==null&&(this.objects=a.copyList(r.objects,[null])),r.permissions!==void 0&&r.permissions!==null&&(this.permissions=new l.TDashboardPermissions(r.permissions)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;case 3:if(g==a.Type.LIST){this.groups=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.groups.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.objects=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.objects.push(B)}r.readListEnd()}else r.skip(g);break;case 5:g==a.Type.STRUCT?(this.permissions=new l.TDashboardPermissions,this.permissions.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_unshare_dashboard_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),this.groups!==null&&this.groups!==void 0){r.writeFieldBegin("groups",a.Type.LIST,3),r.writeListBegin(a.Type.STRING,this.groups.length);for(let w in this.groups)this.groups.hasOwnProperty(w)&&(w=this.groups[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}if(this.objects!==null&&this.objects!==void 0){r.writeFieldBegin("objects",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.objects.length);for(let w in this.objects)this.objects.hasOwnProperty(w)&&(w=this.objects[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.permissions!==null&&this.permissions!==void 0&&(r.writeFieldBegin("permissions",a.Type.STRUCT,5),this.permissions.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},j3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_unshare_dashboard_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},jx=class{constructor(r){this.session=null,this.dashboard_ids=null,this.groups=null,this.permissions=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_ids!==void 0&&r.dashboard_ids!==null&&(this.dashboard_ids=a.copyList(r.dashboard_ids,[null])),r.groups!==void 0&&r.groups!==null&&(this.groups=a.copyList(r.groups,[null])),r.permissions!==void 0&&r.permissions!==null&&(this.permissions=new l.TDashboardPermissions(r.permissions)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:if(g==a.Type.LIST){this.dashboard_ids=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readI32(),this.dashboard_ids.push(B)}r.readListEnd()}else r.skip(g);break;case 3:if(g==a.Type.LIST){this.groups=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.groups.push(B)}r.readListEnd()}else r.skip(g);break;case 4:g==a.Type.STRUCT?(this.permissions=new l.TDashboardPermissions,this.permissions.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_unshare_dashboards_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_ids!==null&&this.dashboard_ids!==void 0){r.writeFieldBegin("dashboard_ids",a.Type.LIST,2),r.writeListBegin(a.Type.I32,this.dashboard_ids.length);for(let w in this.dashboard_ids)this.dashboard_ids.hasOwnProperty(w)&&(w=this.dashboard_ids[w],r.writeI32(w));r.writeListEnd(),r.writeFieldEnd()}if(this.groups!==null&&this.groups!==void 0){r.writeFieldBegin("groups",a.Type.LIST,3),r.writeListBegin(a.Type.STRING,this.groups.length);for(let w in this.groups)this.groups.hasOwnProperty(w)&&(w=this.groups[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.permissions!==null&&this.permissions!==void 0&&(r.writeFieldBegin("permissions",a.Type.STRUCT,4),this.permissions.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},U3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_unshare_dashboards_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Ux=class{constructor(r){this.session=null,this.dashboard_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.dashboard_id!==void 0&&r.dashboard_id!==null&&(this.dashboard_id=r.dashboard_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.dashboard_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_dashboard_grantees_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.dashboard_id!==null&&this.dashboard_id!==void 0&&(r.writeFieldBegin("dashboard_id",a.Type.I32,2),r.writeI32(this.dashboard_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},H3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TDashboardGrantees])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TDashboardGrantees,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_dashboard_grantees_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Hx=class{constructor(r){this.session=null,this.link=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.link!==void 0&&r.link!==null&&(this.link=r.link))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.link=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_link_view_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.link!==null&&this.link!==void 0&&(r.writeFieldBegin("link",a.Type.STRING,2),r.writeString(this.link),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},z3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TFrontendView(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TFrontendView,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_link_view_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},zx=class{constructor(r){this.session=null,this.view_state=null,this.view_metadata=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.view_state!==void 0&&r.view_state!==null&&(this.view_state=r.view_state),r.view_metadata!==void 0&&r.view_metadata!==null&&(this.view_metadata=r.view_metadata))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.view_state=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.view_metadata=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_link_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.view_state!==null&&this.view_state!==void 0&&(r.writeFieldBegin("view_state",a.Type.STRING,2),r.writeString(this.view_state),r.writeFieldEnd()),this.view_metadata!==null&&this.view_metadata!==void 0&&(r.writeFieldBegin("view_metadata",a.Type.STRING,3),r.writeString(this.view_metadata),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},$3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_link_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},$x=class{constructor(r){this.session=null,this.table_name=null,this.rows=null,this.column_names=[],r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.rows!==void 0&&r.rows!==null&&(this.rows=a.copyList(r.rows,[l.TRow])),r.column_names!==void 0&&r.column_names!==null&&(this.column_names=a.copyList(r.column_names,[null])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:if(g==a.Type.LIST){this.rows=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TRow,B.read(r),this.rows.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.column_names=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.column_names.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_load_table_binary_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.rows!==null&&this.rows!==void 0){r.writeFieldBegin("rows",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.rows.length);for(let w in this.rows)this.rows.hasOwnProperty(w)&&(w=this.rows[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}if(this.column_names!==null&&this.column_names!==void 0){r.writeFieldBegin("column_names",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.column_names.length);for(let w in this.column_names)this.column_names.hasOwnProperty(w)&&(w=this.column_names[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},q3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_binary_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},qx=class{constructor(r){this.session=null,this.table_name=null,this.cols=null,this.column_names=[],r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.cols!==void 0&&r.cols!==null&&(this.cols=a.copyList(r.cols,[l.TColumn])),r.column_names!==void 0&&r.column_names!==null&&(this.column_names=a.copyList(r.column_names,[null])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:if(g==a.Type.LIST){this.cols=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumn,B.read(r),this.cols.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.column_names=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.column_names.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_load_table_binary_columnar_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.cols!==null&&this.cols!==void 0){r.writeFieldBegin("cols",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.cols.length);for(let w in this.cols)this.cols.hasOwnProperty(w)&&(w=this.cols[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}if(this.column_names!==null&&this.column_names!==void 0){r.writeFieldBegin("column_names",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.column_names.length);for(let w in this.column_names)this.column_names.hasOwnProperty(w)&&(w=this.column_names[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},V3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_binary_columnar_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Vx=class{constructor(r){this.session=null,this.table_name=null,this.cols=null,this.column_names=[],this.assign_render_groups=!0,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.cols!==void 0&&r.cols!==null&&(this.cols=a.copyList(r.cols,[l.TColumn])),r.column_names!==void 0&&r.column_names!==null&&(this.column_names=a.copyList(r.column_names,[null])),r.assign_render_groups!==void 0&&r.assign_render_groups!==null&&(this.assign_render_groups=r.assign_render_groups))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:if(g==a.Type.LIST){this.cols=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumn,B.read(r),this.cols.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.column_names=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.column_names.push(B)}r.readListEnd()}else r.skip(g);break;case 5:g==a.Type.BOOL?this.assign_render_groups=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_load_table_binary_columnar_polys_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.cols!==null&&this.cols!==void 0){r.writeFieldBegin("cols",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.cols.length);for(let w in this.cols)this.cols.hasOwnProperty(w)&&(w=this.cols[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}if(this.column_names!==null&&this.column_names!==void 0){r.writeFieldBegin("column_names",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.column_names.length);for(let w in this.column_names)this.column_names.hasOwnProperty(w)&&(w=this.column_names[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.assign_render_groups!==null&&this.assign_render_groups!==void 0&&(r.writeFieldBegin("assign_render_groups",a.Type.BOOL,5),r.writeBool(this.assign_render_groups),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},G3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_binary_columnar_polys_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Gx=class{constructor(r){this.session=null,this.table_name=null,this.arrow_stream=null,this.use_column_names=!1,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.arrow_stream!==void 0&&r.arrow_stream!==null&&(this.arrow_stream=r.arrow_stream),r.use_column_names!==void 0&&r.use_column_names!==null&&(this.use_column_names=r.use_column_names))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.arrow_stream=r.readBinary():r.skip(g);break;case 4:g==a.Type.BOOL?this.use_column_names=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_binary_arrow_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.arrow_stream!==null&&this.arrow_stream!==void 0&&(r.writeFieldBegin("arrow_stream",a.Type.STRING,3),r.writeBinary(this.arrow_stream),r.writeFieldEnd()),this.use_column_names!==null&&this.use_column_names!==void 0&&(r.writeFieldBegin("use_column_names",a.Type.BOOL,4),r.writeBool(this.use_column_names),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},W3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_binary_arrow_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Wx=class{constructor(r){this.session=null,this.table_name=null,this.rows=null,this.column_names=[],r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.rows!==void 0&&r.rows!==null&&(this.rows=a.copyList(r.rows,[l.TStringRow])),r.column_names!==void 0&&r.column_names!==null&&(this.column_names=a.copyList(r.column_names,[null])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:if(g==a.Type.LIST){this.rows=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TStringRow,B.read(r),this.rows.push(B)}r.readListEnd()}else r.skip(g);break;case 4:if(g==a.Type.LIST){this.column_names=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.column_names.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_load_table_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.rows!==null&&this.rows!==void 0){r.writeFieldBegin("rows",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.rows.length);for(let w in this.rows)this.rows.hasOwnProperty(w)&&(w=this.rows[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}if(this.column_names!==null&&this.column_names!==void 0){r.writeFieldBegin("column_names",a.Type.LIST,4),r.writeListBegin(a.Type.STRING,this.column_names.length);for(let w in this.column_names)this.column_names.hasOwnProperty(w)&&(w=this.column_names[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},Y3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_load_table_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Yx=class{constructor(r){this.session=null,this.file_name=null,this.copy_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.file_name!==void 0&&r.file_name!==null&&(this.file_name=r.file_name),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.file_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_detect_column_types_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.file_name!==null&&this.file_name!==void 0&&(r.writeFieldBegin("file_name",a.Type.STRING,2),r.writeString(this.file_name),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,3),this.copy_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},X3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TDetectResult(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TDetectResult,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_detect_column_types_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Xx=class{constructor(r){this.session=null,this.table_name=null,this.row_desc=null,this.create_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.row_desc!==void 0&&r.row_desc!==null&&(this.row_desc=a.copyList(r.row_desc,[l.TColumnType])),r.create_params!==void 0&&r.create_params!==null&&(this.create_params=new l.TCreateParams(r.create_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:if(g==a.Type.LIST){this.row_desc=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumnType,B.read(r),this.row_desc.push(B)}r.readListEnd()}else r.skip(g);break;case 4:g==a.Type.STRUCT?(this.create_params=new l.TCreateParams,this.create_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_create_table_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.row_desc!==null&&this.row_desc!==void 0){r.writeFieldBegin("row_desc",a.Type.LIST,3),r.writeListBegin(a.Type.STRUCT,this.row_desc.length);for(let w in this.row_desc)this.row_desc.hasOwnProperty(w)&&(w=this.row_desc[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.create_params!==null&&this.create_params!==void 0&&(r.writeFieldBegin("create_params",a.Type.STRUCT,4),this.create_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},K3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_create_table_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Kx=class{constructor(r){this.session=null,this.table_name=null,this.file_name=null,this.copy_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.file_name!==void 0&&r.file_name!==null&&(this.file_name=r.file_name),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.file_name=r.readString():r.skip(g);break;case 4:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_import_table_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.file_name!==null&&this.file_name!==void 0&&(r.writeFieldBegin("file_name",a.Type.STRING,3),r.writeString(this.file_name),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,4),this.copy_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Z3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_import_table_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Zx=class{constructor(r){this.session=null,this.table_name=null,this.file_name=null,this.copy_params=null,this.row_desc=null,this.create_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_name!==void 0&&r.table_name!==null&&(this.table_name=r.table_name),r.file_name!==void 0&&r.file_name!==null&&(this.file_name=r.file_name),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)),r.row_desc!==void 0&&r.row_desc!==null&&(this.row_desc=a.copyList(r.row_desc,[l.TColumnType])),r.create_params!==void 0&&r.create_params!==null&&(this.create_params=new l.TCreateParams(r.create_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.table_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.file_name=r.readString():r.skip(g);break;case 4:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;case 5:if(g==a.Type.LIST){this.row_desc=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumnType,B.read(r),this.row_desc.push(B)}r.readListEnd()}else r.skip(g);break;case 6:g==a.Type.STRUCT?(this.create_params=new l.TCreateParams,this.create_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_import_geo_table_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_name!==null&&this.table_name!==void 0&&(r.writeFieldBegin("table_name",a.Type.STRING,2),r.writeString(this.table_name),r.writeFieldEnd()),this.file_name!==null&&this.file_name!==void 0&&(r.writeFieldBegin("file_name",a.Type.STRING,3),r.writeString(this.file_name),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,4),this.copy_params.write(r),r.writeFieldEnd()),this.row_desc!==null&&this.row_desc!==void 0){r.writeFieldBegin("row_desc",a.Type.LIST,5),r.writeListBegin(a.Type.STRUCT,this.row_desc.length);for(let w in this.row_desc)this.row_desc.hasOwnProperty(w)&&(w=this.row_desc[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.create_params!==null&&this.create_params!==void 0&&(r.writeFieldBegin("create_params",a.Type.STRUCT,6),this.create_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},J3=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_import_geo_table_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Jx=class{constructor(r){this.session=null,this.import_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.import_id!==void 0&&r.import_id!==null&&(this.import_id=r.import_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.import_id=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_import_table_status_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.import_id!==null&&this.import_id!==void 0&&(r.writeFieldBegin("import_id",a.Type.STRING,2),r.writeString(this.import_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Q3=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TImportStatus(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TImportStatus,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_import_table_status_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},Qx=class{constructor(r){this.session=null,this.archive_path=null,this.copy_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.archive_path!==void 0&&r.archive_path!==null&&(this.archive_path=r.archive_path),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.archive_path=r.readString():r.skip(g);break;case 3:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_first_geo_file_in_archive_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.archive_path!==null&&this.archive_path!==void 0&&(r.writeFieldBegin("archive_path",a.Type.STRING,2),r.writeString(this.archive_path),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,3),this.copy_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},eg=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRING?this.success=r.readString():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_first_geo_file_in_archive_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRING,0),r.writeString(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ek=class{constructor(r){this.session=null,this.archive_path=null,this.copy_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.archive_path!==void 0&&r.archive_path!==null&&(this.archive_path=r.archive_path),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.archive_path=r.readString():r.skip(g);break;case 3:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_all_files_in_archive_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.archive_path!==null&&this.archive_path!==void 0&&(r.writeFieldBegin("archive_path",a.Type.STRING,2),r.writeString(this.archive_path),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,3),this.copy_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},tg=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[null])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readString(),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_all_files_in_archive_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRING,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],r.writeString(w));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},tk=class{constructor(r){this.session=null,this.file_name=null,this.copy_params=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.file_name!==void 0&&r.file_name!==null&&(this.file_name=r.file_name),r.copy_params!==void 0&&r.copy_params!==null&&(this.copy_params=new l.TCopyParams(r.copy_params)))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.file_name=r.readString():r.skip(g);break;case 3:g==a.Type.STRUCT?(this.copy_params=new l.TCopyParams,this.copy_params.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_get_layers_in_geo_file_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.file_name!==null&&this.file_name!==void 0&&(r.writeFieldBegin("file_name",a.Type.STRING,2),r.writeString(this.file_name),r.writeFieldEnd()),this.copy_params!==null&&this.copy_params!==void 0&&(r.writeFieldBegin("copy_params",a.Type.STRUCT,3),this.copy_params.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ng=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=a.copyList(r.success,[l.TGeoFileLayerInfo])),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:if(g==a.Type.LIST){this.success=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TGeoFileLayerInfo,B.read(r),this.success.push(B)}r.readListEnd()}else r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_get_layers_in_geo_file_result"),this.success!==null&&this.success!==void 0){r.writeFieldBegin("success",a.Type.LIST,0),r.writeListBegin(a.Type.STRUCT,this.success.length);for(let w in this.success)this.success.hasOwnProperty(w)&&(w=this.success[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},nk=class{constructor(r){this.session=null,this.query=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.query!==void 0&&r.query!==null&&(this.query=r.query))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.query=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_query_get_outer_fragment_count_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.query!==null&&this.query!==void 0&&(r.writeFieldBegin("query",a.Type.STRING,2),r.writeString(this.query),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ig=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=r.success),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.I64?this.success=r.readI64():r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_query_get_outer_fragment_count_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.I64,0),r.writeI64(this.success),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ik=class{constructor(r){this.session=null,this.table_id=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.table_id!==void 0&&r.table_id!==null&&(this.table_id=r.table_id))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I32?this.table_id=r.readI32():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_check_table_consistency_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.table_id!==null&&this.table_id!==void 0&&(r.writeFieldBegin("table_id",a.Type.I32,2),r.writeI32(this.table_id),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},sg=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TTableMeta(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TTableMeta,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_check_table_consistency_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},sk=class{constructor(r){this.leaf_session=null,this.parent_session=null,this.query_ra=null,this.start_time_str=null,this.just_explain=null,this.outer_fragment_indices=null,r&&(r.leaf_session!==void 0&&r.leaf_session!==null&&(this.leaf_session=r.leaf_session),r.parent_session!==void 0&&r.parent_session!==null&&(this.parent_session=r.parent_session),r.query_ra!==void 0&&r.query_ra!==null&&(this.query_ra=r.query_ra),r.start_time_str!==void 0&&r.start_time_str!==null&&(this.start_time_str=r.start_time_str),r.just_explain!==void 0&&r.just_explain!==null&&(this.just_explain=r.just_explain),r.outer_fragment_indices!==void 0&&r.outer_fragment_indices!==null&&(this.outer_fragment_indices=a.copyList(r.outer_fragment_indices,[null])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.leaf_session=r.readString():r.skip(g);break;case 2:g==a.Type.STRING?this.parent_session=r.readString():r.skip(g);break;case 3:g==a.Type.STRING?this.query_ra=r.readString():r.skip(g);break;case 4:g==a.Type.STRING?this.start_time_str=r.readString():r.skip(g);break;case 5:g==a.Type.BOOL?this.just_explain=r.readBool():r.skip(g);break;case 6:if(g==a.Type.LIST){this.outer_fragment_indices=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=r.readI64(),this.outer_fragment_indices.push(B)}r.readListEnd()}else r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_start_query_args"),this.leaf_session!==null&&this.leaf_session!==void 0&&(r.writeFieldBegin("leaf_session",a.Type.STRING,1),r.writeString(this.leaf_session),r.writeFieldEnd()),this.parent_session!==null&&this.parent_session!==void 0&&(r.writeFieldBegin("parent_session",a.Type.STRING,2),r.writeString(this.parent_session),r.writeFieldEnd()),this.query_ra!==null&&this.query_ra!==void 0&&(r.writeFieldBegin("query_ra",a.Type.STRING,3),r.writeString(this.query_ra),r.writeFieldEnd()),this.start_time_str!==null&&this.start_time_str!==void 0&&(r.writeFieldBegin("start_time_str",a.Type.STRING,4),r.writeString(this.start_time_str),r.writeFieldEnd()),this.just_explain!==null&&this.just_explain!==void 0&&(r.writeFieldBegin("just_explain",a.Type.BOOL,5),r.writeBool(this.just_explain),r.writeFieldEnd()),this.outer_fragment_indices!==null&&this.outer_fragment_indices!==void 0){r.writeFieldBegin("outer_fragment_indices",a.Type.LIST,6),r.writeListBegin(a.Type.I64,this.outer_fragment_indices.length);for(let w in this.outer_fragment_indices)this.outer_fragment_indices.hasOwnProperty(w)&&(w=this.outer_fragment_indices[w],r.writeI64(w));r.writeListEnd(),r.writeFieldEnd()}r.writeFieldStop(),r.writeStructEnd()}},rg=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TPendingQuery(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TPendingQuery,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_start_query_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},rk=class{constructor(r){this.pending_query=null,this.subquery_id=null,this.start_time_str=null,r&&(r.pending_query!==void 0&&r.pending_query!==null&&(this.pending_query=new l.TPendingQuery(r.pending_query)),r.subquery_id!==void 0&&r.subquery_id!==null&&(this.subquery_id=r.subquery_id),r.start_time_str!==void 0&&r.start_time_str!==null&&(this.start_time_str=r.start_time_str))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.pending_query=new l.TPendingQuery,this.pending_query.read(r)):r.skip(g);break;case 2:g==a.Type.I64?this.subquery_id=r.readI64():r.skip(g);break;case 3:g==a.Type.STRING?this.start_time_str=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_execute_query_step_args"),this.pending_query!==null&&this.pending_query!==void 0&&(r.writeFieldBegin("pending_query",a.Type.STRUCT,1),this.pending_query.write(r),r.writeFieldEnd()),this.subquery_id!==null&&this.subquery_id!==void 0&&(r.writeFieldBegin("subquery_id",a.Type.I64,2),r.writeI64(this.subquery_id),r.writeFieldEnd()),this.start_time_str!==null&&this.start_time_str!==void 0&&(r.writeFieldBegin("start_time_str",a.Type.STRING,3),r.writeString(this.start_time_str),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ag=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TStepResult(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TStepResult,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_execute_query_step_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ak=class{constructor(r){this.serialized_rows=null,this.row_desc=null,this.query_id=null,this.subquery_id=null,this.is_final_subquery_result=null,r&&(r.serialized_rows!==void 0&&r.serialized_rows!==null&&(this.serialized_rows=new y.TSerializedRows(r.serialized_rows)),r.row_desc!==void 0&&r.row_desc!==null&&(this.row_desc=a.copyList(r.row_desc,[l.TColumnType])),r.query_id!==void 0&&r.query_id!==null&&(this.query_id=r.query_id),r.subquery_id!==void 0&&r.subquery_id!==null&&(this.subquery_id=r.subquery_id),r.is_final_subquery_result!==void 0&&r.is_final_subquery_result!==null&&(this.is_final_subquery_result=r.is_final_subquery_result))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.serialized_rows=new y.TSerializedRows,this.serialized_rows.read(r)):r.skip(g);break;case 2:if(g==a.Type.LIST){this.row_desc=[];const _=r.readListBegin().size||0;for(let v=0;v<_;++v){let B=null;B=new l.TColumnType,B.read(r),this.row_desc.push(B)}r.readListEnd()}else r.skip(g);break;case 3:g==a.Type.I64?this.query_id=r.readI64():r.skip(g);break;case 4:g==a.Type.I64?this.subquery_id=r.readI64():r.skip(g);break;case 5:g==a.Type.BOOL?this.is_final_subquery_result=r.readBool():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){if(r.writeStructBegin("Heavy_broadcast_serialized_rows_args"),this.serialized_rows!==null&&this.serialized_rows!==void 0&&(r.writeFieldBegin("serialized_rows",a.Type.STRUCT,1),this.serialized_rows.write(r),r.writeFieldEnd()),this.row_desc!==null&&this.row_desc!==void 0){r.writeFieldBegin("row_desc",a.Type.LIST,2),r.writeListBegin(a.Type.STRUCT,this.row_desc.length);for(let w in this.row_desc)this.row_desc.hasOwnProperty(w)&&(w=this.row_desc[w],w.write(r));r.writeListEnd(),r.writeFieldEnd()}this.query_id!==null&&this.query_id!==void 0&&(r.writeFieldBegin("query_id",a.Type.I64,3),r.writeI64(this.query_id),r.writeFieldEnd()),this.subquery_id!==null&&this.subquery_id!==void 0&&(r.writeFieldBegin("subquery_id",a.Type.I64,4),r.writeI64(this.subquery_id),r.writeFieldEnd()),this.is_final_subquery_result!==null&&this.is_final_subquery_result!==void 0&&(r.writeFieldBegin("is_final_subquery_result",a.Type.BOOL,5),r.writeBool(this.is_final_subquery_result),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},og=class{constructor(r){if(this.e=null,r instanceof l.TDBException){this.e=r;return}r&&r.e!==void 0&&r.e!==null&&(this.e=r.e)}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;case 0:r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_broadcast_serialized_rows_result"),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},ok=class{constructor(r){this.session=null,this.widget_id=null,this.node_idx=null,this.vega_json=null,r&&(r.session!==void 0&&r.session!==null&&(this.session=r.session),r.widget_id!==void 0&&r.widget_id!==null&&(this.widget_id=r.widget_id),r.node_idx!==void 0&&r.node_idx!==null&&(this.node_idx=r.node_idx),r.vega_json!==void 0&&r.vega_json!==null&&(this.vega_json=r.vega_json))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRING?this.session=r.readString():r.skip(g);break;case 2:g==a.Type.I64?this.widget_id=r.readI64():r.skip(g);break;case 3:g==a.Type.I16?this.node_idx=r.readI16():r.skip(g);break;case 4:g==a.Type.STRING?this.vega_json=r.readString():r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_start_render_query_args"),this.session!==null&&this.session!==void 0&&(r.writeFieldBegin("session",a.Type.STRING,1),r.writeString(this.session),r.writeFieldEnd()),this.widget_id!==null&&this.widget_id!==void 0&&(r.writeFieldBegin("widget_id",a.Type.I64,2),r.writeI64(this.widget_id),r.writeFieldEnd()),this.node_idx!==null&&this.node_idx!==void 0&&(r.writeFieldBegin("node_idx",a.Type.I16,3),r.writeI16(this.node_idx),r.writeFieldEnd()),this.vega_json!==null&&this.vega_json!==void 0&&(r.writeFieldBegin("vega_json",a.Type.STRING,4),r.writeString(this.vega_json),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},lg=class{constructor(r){if(this.success=null,this.e=null,r instanceof l.TDBException){this.e=r;return}r&&(r.success!==void 0&&r.success!==null&&(this.success=new l.TPendingRenderQuery(r.success)),r.e!==void 0&&r.e!==null&&(this.e=r.e))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 0:g==a.Type.STRUCT?(this.success=new l.TPendingRenderQuery,this.success.read(r)):r.skip(g);break;case 1:g==a.Type.STRUCT?(this.e=new l.TDBException,this.e.read(r)):r.skip(g);break;default:r.skip(g)}r.readFieldEnd()}r.readStructEnd()}write(r){r.writeStructBegin("Heavy_start_render_query_result"),this.success!==null&&this.success!==void 0&&(r.writeFieldBegin("success",a.Type.STRUCT,0),this.success.write(r),r.writeFieldEnd()),this.e!==null&&this.e!==void 0&&(r.writeFieldBegin("e",a.Type.STRUCT,1),this.e.write(r),r.writeFieldEnd()),r.writeFieldStop(),r.writeStructEnd()}},lk=class{constructor(r){this.pending_render=null,this.merged_data=null,r&&(r.pending_render!==void 0&&r.pending_render!==null&&(this.pending_render=new l.TPendingRenderQuery(r.pending_render)),r.merged_data!==void 0&&r.merged_data!==null&&(this.merged_data=a.copyMap(r.merged_data,[a.copyMap,a.copyMap,a.copyMap,a.copyList,l.TRenderDatum])))}read(r){for(r.readStructBegin();;){const w=r.readFieldBegin(),g=w.ftype,h=w.fid;if(g==a.Type.STOP)break;switch(h){case 1:g==a.Type.STRUCT?(this.pending_render=new l.TPendingRenderQuery,this.pending_render.read(r)):r.skip(g);break;case 2:if(g==a.Type.MAP){this.merged_data={};const _=r.readMapBegin().size||0;for(let v=0;v<_;++v){let B=null,Q=null;B=r.readString(),Q={};const $e=r.readMapBegin().size||0;for(let sn=0;sn<$e;++sn){let fo=null,C6=null;fo=r.readString(),C6={};const LY=r.readMapBegin().size||0;for(let xk=0;xk{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_connect(w,g,h)})}send_connect(w,g,h){const T=new this.pClass(this.output),_={user:w,passwd:g,dbname:h},v=new b(_);try{return T.writeMessageBegin("connect",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_connect(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new L;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("connect failed: unknown result")}krb5_connect(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_krb5_connect(w,g)})}send_krb5_connect(w,g){const h=new this.pClass(this.output),T={inputToken:w,dbname:g},_=new E(T);try{return h.writeMessageBegin("krb5_connect",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_krb5_connect(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new S;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("krb5_connect failed: unknown result")}disconnect(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_disconnect(w)})}send_disconnect(w){const g=new this.pClass(this.output),h={session:w},T=new x(h);try{return g.writeMessageBegin("disconnect",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_disconnect(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new F;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}switch_database(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_switch_database(w,g)})}send_switch_database(w,g){const h=new this.pClass(this.output),T={session:w,dbname:g},_=new k(T);try{return h.writeMessageBegin("switch_database",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_switch_database(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new M;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}clone_session(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_clone_session(w)})}send_clone_session(w){const g=new this.pClass(this.output),h={session:w},T=new O(h);try{return g.writeMessageBegin("clone_session",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_clone_session(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new C;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("clone_session failed: unknown result")}get_server_status(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_server_status(w)})}send_get_server_status(w){const g=new this.pClass(this.output),h={session:w},T=new P(h);try{return g.writeMessageBegin("get_server_status",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_server_status(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new j;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_server_status failed: unknown result")}get_status(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_status(w)})}send_get_status(w){const g=new this.pClass(this.output),h={session:w},T=new R(h);try{return g.writeMessageBegin("get_status",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_status(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new H;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_status failed: unknown result")}get_hardware_info(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_hardware_info(w)})}send_get_hardware_info(w){const g=new this.pClass(this.output),h={session:w},T=new z(h);try{return g.writeMessageBegin("get_hardware_info",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_hardware_info(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Y;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_hardware_info failed: unknown result")}get_tables(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_tables(w)})}send_get_tables(w){const g=new this.pClass(this.output),h={session:w},T=new $(h);try{return g.writeMessageBegin("get_tables",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_tables(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new W;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_tables failed: unknown result")}get_tables_for_database(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_tables_for_database(w,g)})}send_get_tables_for_database(w,g){const h=new this.pClass(this.output),T={session:w,database_name:g},_=new X(T);try{return h.writeMessageBegin("get_tables_for_database",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_tables_for_database(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new G;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_tables_for_database failed: unknown result")}get_physical_tables(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_physical_tables(w)})}send_get_physical_tables(w){const g=new this.pClass(this.output),h={session:w},T=new oe(h);try{return g.writeMessageBegin("get_physical_tables",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_physical_tables(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new he;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_physical_tables failed: unknown result")}get_views(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_views(w)})}send_get_views(w){const g=new this.pClass(this.output),h={session:w},T=new ie(h);try{return g.writeMessageBegin("get_views",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_views(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Oe;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_views failed: unknown result")}get_tables_meta(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_tables_meta(w)})}send_get_tables_meta(w){const g=new this.pClass(this.output),h={session:w},T=new de(h);try{return g.writeMessageBegin("get_tables_meta",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_tables_meta(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Me;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_tables_meta failed: unknown result")}get_table_details(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_table_details(w,g)})}send_get_table_details(w,g){const h=new this.pClass(this.output),T={session:w,table_name:g},_=new Fe(T);try{return h.writeMessageBegin("get_table_details",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_table_details(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Ge;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_table_details failed: unknown result")}get_table_details_for_database(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_table_details_for_database(w,g,h)})}send_get_table_details_for_database(w,g,h){const T=new this.pClass(this.output),_={session:w,table_name:g,database_name:h},v=new pt(_);try{return T.writeMessageBegin("get_table_details_for_database",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_table_details_for_database(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ht;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_table_details_for_database failed: unknown result")}get_internal_table_details(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_internal_table_details(w,g,h)})}send_get_internal_table_details(w,g,h){const T=new this.pClass(this.output),_={session:w,table_name:g,include_system_columns:h},v=new ge(_);try{return T.writeMessageBegin("get_internal_table_details",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_internal_table_details(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new V;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_internal_table_details failed: unknown result")}get_internal_table_details_for_database(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_internal_table_details_for_database(w,g,h)})}send_get_internal_table_details_for_database(w,g,h){const T=new this.pClass(this.output),_={session:w,table_name:g,database_name:h},v=new q(_);try{return T.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_internal_table_details_for_database(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new D;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_internal_table_details_for_database failed: unknown result")}get_users(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_users(w)})}send_get_users(w){const g=new this.pClass(this.output),h={session:w},T=new K(h);try{return g.writeMessageBegin("get_users",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_users(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new J;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_users failed: unknown result")}get_databases(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_databases(w)})}send_get_databases(w){const g=new this.pClass(this.output),h={session:w},T=new re(h);try{return g.writeMessageBegin("get_databases",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_databases(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new se;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_databases failed: unknown result")}get_version(){this._seqid=this.new_seqid();const w=this;return new Promise((g,h)=>{w._reqs[w.seqid()]=(T,_)=>T?h(T):g(_),w.send_get_version()})}send_get_version(){const w=new this.pClass(this.output),g=new _e;try{return w.writeMessageBegin("get_version",a.MessageType.CALL,this.seqid()),g.write(w),w.writeMessageEnd(),this.output.flush()}catch(h){throw delete this._reqs[this.seqid()],typeof w.reset=="function"&&w.reset(),h}}recv_get_version(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new be;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_version failed: unknown result")}start_heap_profile(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_start_heap_profile(w)})}send_start_heap_profile(w){const g=new this.pClass(this.output),h={session:w},T=new Ke(h);try{return g.writeMessageBegin("start_heap_profile",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_start_heap_profile(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new It;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}stop_heap_profile(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_stop_heap_profile(w)})}send_stop_heap_profile(w){const g=new this.pClass(this.output),h={session:w},T=new Et(h);try{return g.writeMessageBegin("stop_heap_profile",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_stop_heap_profile(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new et;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_heap_profile(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_heap_profile(w)})}send_get_heap_profile(w){const g=new this.pClass(this.output),h={session:w},T=new Zt(h);try{return g.writeMessageBegin("get_heap_profile",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_heap_profile(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new kn;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_heap_profile failed: unknown result")}get_memory(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_memory(w,g)})}send_get_memory(w,g){const h=new this.pClass(this.output),T={session:w,memory_level:g},_=new Yi(T);try{return h.writeMessageBegin("get_memory",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_memory(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new fe;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_memory failed: unknown result")}clear_cpu_memory(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_clear_cpu_memory(w)})}send_clear_cpu_memory(w){const g=new this.pClass(this.output),h={session:w},T=new oi(h);try{return g.writeMessageBegin("clear_cpu_memory",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_clear_cpu_memory(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new jn;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}clear_gpu_memory(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_clear_gpu_memory(w)})}send_clear_gpu_memory(w){const g=new this.pClass(this.output),h={session:w},T=new ur(h);try{return g.writeMessageBegin("clear_gpu_memory",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_clear_gpu_memory(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ln;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}set_cur_session(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_set_cur_session(w,g,h,T,_)})}send_set_cur_session(w,g,h,T,_){const v=new this.pClass(this.output),B={parent_session:w,leaf_session:g,start_time_str:h,label:T,for_running_query_kernel:_},Q=new cl(B);try{return v.writeMessageBegin("set_cur_session",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_set_cur_session(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new dl;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}invalidate_cur_session(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_invalidate_cur_session(w,g,h,T,_)})}send_invalidate_cur_session(w,g,h,T,_){const v=new this.pClass(this.output),B={parent_session:w,leaf_session:g,start_time_str:h,label:T,for_running_query_kernel:_},Q=new Ts(B);try{return v.writeMessageBegin("invalidate_cur_session",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_invalidate_cur_session(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new fl;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}set_table_epoch(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_set_table_epoch(w,g,h,T)})}send_set_table_epoch(w,g,h,T){const _=new this.pClass(this.output),v={session:w,db_id:g,table_id:h,new_epoch:T},B=new N(v);try{return _.writeMessageBegin("set_table_epoch",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_set_table_epoch(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new I;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}set_table_epoch_by_name(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_set_table_epoch_by_name(w,g,h)})}send_set_table_epoch_by_name(w,g,h){const T=new this.pClass(this.output),_={session:w,table_name:g,new_epoch:h},v=new A(_);try{return T.writeMessageBegin("set_table_epoch_by_name",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_set_table_epoch_by_name(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new U;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_table_epoch(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_table_epoch(w,g,h)})}send_get_table_epoch(w,g,h){const T=new this.pClass(this.output),_={session:w,db_id:g,table_id:h},v=new Z(_);try{return T.writeMessageBegin("get_table_epoch",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_table_epoch(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ee;return _.read(w),w.readMessageEnd(),_.success!==null?T(null,_.success):T("get_table_epoch failed: unknown result")}get_table_epoch_by_name(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_table_epoch_by_name(w,g)})}send_get_table_epoch_by_name(w,g){const h=new this.pClass(this.output),T={session:w,table_name:g},_=new ne(T);try{return h.writeMessageBegin("get_table_epoch_by_name",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_table_epoch_by_name(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Be;return _.read(w),w.readMessageEnd(),_.success!==null?T(null,_.success):T("get_table_epoch_by_name failed: unknown result")}get_table_epochs(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_table_epochs(w,g,h)})}send_get_table_epochs(w,g,h){const T=new this.pClass(this.output),_={session:w,db_id:g,table_id:h},v=new je(_);try{return T.writeMessageBegin("get_table_epochs",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_table_epochs(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Ue;return _.read(w),w.readMessageEnd(),_.success!==null?T(null,_.success):T("get_table_epochs failed: unknown result")}set_table_epochs(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_set_table_epochs(w,g,h)})}send_set_table_epochs(w,g,h){const T=new this.pClass(this.output),_={session:w,db_id:g,table_epochs:h},v=new Ye(_);try{return T.writeMessageBegin("set_table_epochs",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_set_table_epochs(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}new Xe().read(w),w.readMessageEnd(),T(null)}get_session_info(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_session_info(w)})}send_get_session_info(w){const g=new this.pClass(this.output),h={session:w},T=new ul(h);try{return g.writeMessageBegin("get_session_info",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_session_info(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new g3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_session_info failed: unknown result")}get_queries_info(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_queries_info(w)})}send_get_queries_info(w){const g=new this.pClass(this.output),h={session:w},T=new gx(h);try{return g.writeMessageBegin("get_queries_info",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_queries_info(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new _3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_queries_info failed: unknown result")}set_leaf_info(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_set_leaf_info(w,g)})}send_set_leaf_info(w,g){const h=new this.pClass(this.output),T={session:w,leaf_info:g},_=new _x(T);try{return h.writeMessageBegin("set_leaf_info",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_set_leaf_info(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new p3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}sql_execute(w,g,h,T,_,v){this._seqid=this.new_seqid();const B=this;return new Promise((Q,pe)=>{B._reqs[B.seqid()]=($e,sn)=>$e?pe($e):Q(sn),B.send_sql_execute(w,g,h,T,_,v)})}send_sql_execute(w,g,h,T,_,v){const B=new this.pClass(this.output),Q={session:w,query:g,column_format:h,nonce:T,first_n:_,at_most_n:v},pe=new px(Q);try{return B.writeMessageBegin("sql_execute",a.MessageType.CALL,this.seqid()),pe.write(B),B.writeMessageEnd(),this.output.flush()}catch($e){throw delete this._reqs[this.seqid()],typeof B.reset=="function"&&B.reset(),$e}}recv_sql_execute(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new y3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("sql_execute failed: unknown result")}sql_execute_df(w,g,h,T,_,v){this._seqid=this.new_seqid();const B=this;return new Promise((Q,pe)=>{B._reqs[B.seqid()]=($e,sn)=>$e?pe($e):Q(sn),B.send_sql_execute_df(w,g,h,T,_,v)})}send_sql_execute_df(w,g,h,T,_,v){const B=new this.pClass(this.output),Q={session:w,query:g,device_type:h,device_id:T,first_n:_,transport_method:v},pe=new yx(Q);try{return B.writeMessageBegin("sql_execute_df",a.MessageType.CALL,this.seqid()),pe.write(B),B.writeMessageEnd(),this.output.flush()}catch($e){throw delete this._reqs[this.seqid()],typeof B.reset=="function"&&B.reset(),$e}}recv_sql_execute_df(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new m3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("sql_execute_df failed: unknown result")}sql_execute_gdf(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_sql_execute_gdf(w,g,h,T)})}send_sql_execute_gdf(w,g,h,T){const _=new this.pClass(this.output),v={session:w,query:g,device_id:h,first_n:T},B=new mx(v);try{return _.writeMessageBegin("sql_execute_gdf",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_sql_execute_gdf(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new w3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("sql_execute_gdf failed: unknown result")}deallocate_df(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_deallocate_df(w,g,h,T)})}send_deallocate_df(w,g,h,T){const _=new this.pClass(this.output),v={session:w,df:g,device_type:h,device_id:T},B=new wx(v);try{return _.writeMessageBegin("deallocate_df",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_deallocate_df(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new L3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}interrupt(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_interrupt(w,g)})}send_interrupt(w,g){const h=new this.pClass(this.output),T={query_session:w,interrupt_session:g},_=new Lx(T);try{return h.writeMessageBegin("interrupt",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_interrupt(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new b3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}sql_validate(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_sql_validate(w,g)})}send_sql_validate(w,g){const h=new this.pClass(this.output),T={session:w,query:g},_=new bx(T);try{return h.writeMessageBegin("sql_validate",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_sql_validate(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new T3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("sql_validate failed: unknown result")}get_completion_hints(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_completion_hints(w,g,h)})}send_get_completion_hints(w,g,h){const T=new this.pClass(this.output),_={session:w,sql:g,cursor:h},v=new Tx(_);try{return T.writeMessageBegin("get_completion_hints",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_completion_hints(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new v3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_completion_hints failed: unknown result")}set_execution_mode(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_set_execution_mode(w,g)})}send_set_execution_mode(w,g){const h=new this.pClass(this.output),T={session:w,mode:g},_=new vx(T);try{return h.writeMessageBegin("set_execution_mode",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_set_execution_mode(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new E3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}render_vega(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_render_vega(w,g,h,T,_)})}send_render_vega(w,g,h,T,_){const v=new this.pClass(this.output),B={session:w,widget_id:g,vega_json:h,compression_level:T,nonce:_},Q=new Ex(B);try{return v.writeMessageBegin("render_vega",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_render_vega(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new S3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("render_vega failed: unknown result")}get_result_row_for_pixel(w,g,h,T,_,v,B){this._seqid=this.new_seqid();const Q=this;return new Promise((pe,$e)=>{Q._reqs[Q.seqid()]=(sn,fo)=>sn?$e(sn):pe(fo),Q.send_get_result_row_for_pixel(w,g,h,T,_,v,B)})}send_get_result_row_for_pixel(w,g,h,T,_,v,B){const Q=new this.pClass(this.output),pe={session:w,widget_id:g,pixel:h,table_col_names:T,column_format:_,pixelRadius:v,nonce:B},$e=new Sx(pe);try{return Q.writeMessageBegin("get_result_row_for_pixel",a.MessageType.CALL,this.seqid()),$e.write(Q),Q.writeMessageEnd(),this.output.flush()}catch(sn){throw delete this._reqs[this.seqid()],typeof Q.reset=="function"&&Q.reset(),sn}}recv_get_result_row_for_pixel(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new x3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_result_row_for_pixel failed: unknown result")}create_custom_expression(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_create_custom_expression(w,g)})}send_create_custom_expression(w,g){const h=new this.pClass(this.output),T={session:w,custom_expression:g},_=new xx(T);try{return h.writeMessageBegin("create_custom_expression",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_create_custom_expression(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new k3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("create_custom_expression failed: unknown result")}get_custom_expressions(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_custom_expressions(w)})}send_get_custom_expressions(w){const g=new this.pClass(this.output),h={session:w},T=new kx(h);try{return g.writeMessageBegin("get_custom_expressions",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_custom_expressions(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new B3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_custom_expressions failed: unknown result")}update_custom_expression(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_update_custom_expression(w,g,h)})}send_update_custom_expression(w,g,h){const T=new this.pClass(this.output),_={session:w,id:g,expression_json:h},v=new Bx(_);try{return T.writeMessageBegin("update_custom_expression",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_update_custom_expression(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new F3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}delete_custom_expressions(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_delete_custom_expressions(w,g,h)})}send_delete_custom_expressions(w,g,h){const T=new this.pClass(this.output),_={session:w,custom_expression_ids:g,do_soft_delete:h},v=new Fx(_);try{return T.writeMessageBegin("delete_custom_expressions",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_delete_custom_expressions(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new I3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_dashboard(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_dashboard(w,g)})}send_get_dashboard(w,g){const h=new this.pClass(this.output),T={session:w,dashboard_id:g},_=new Ix(T);try{return h.writeMessageBegin("get_dashboard",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new O3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_dashboard failed: unknown result")}get_dashboards(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_dashboards(w)})}send_get_dashboards(w){const g=new this.pClass(this.output),h={session:w},T=new Ox(h);try{return g.writeMessageBegin("get_dashboards",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_dashboards(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new M3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_dashboards failed: unknown result")}create_dashboard(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_create_dashboard(w,g,h,T,_)})}send_create_dashboard(w,g,h,T,_){const v=new this.pClass(this.output),B={session:w,dashboard_name:g,dashboard_state:h,image_hash:T,dashboard_metadata:_},Q=new Mx(B);try{return v.writeMessageBegin("create_dashboard",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_create_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new A3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("create_dashboard failed: unknown result")}replace_dashboard(w,g,h,T,_,v,B){this._seqid=this.new_seqid();const Q=this;return new Promise((pe,$e)=>{Q._reqs[Q.seqid()]=(sn,fo)=>sn?$e(sn):pe(fo),Q.send_replace_dashboard(w,g,h,T,_,v,B)})}send_replace_dashboard(w,g,h,T,_,v,B){const Q=new this.pClass(this.output),pe={session:w,dashboard_id:g,dashboard_name:h,dashboard_owner:T,dashboard_state:_,image_hash:v,dashboard_metadata:B},$e=new Ax(pe);try{return Q.writeMessageBegin("replace_dashboard",a.MessageType.CALL,this.seqid()),$e.write(Q),Q.writeMessageEnd(),this.output.flush()}catch(sn){throw delete this._reqs[this.seqid()],typeof Q.reset=="function"&&Q.reset(),sn}}recv_replace_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new N3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}delete_dashboard(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_delete_dashboard(w,g)})}send_delete_dashboard(w,g){const h=new this.pClass(this.output),T={session:w,dashboard_id:g},_=new Nx(T);try{return h.writeMessageBegin("delete_dashboard",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_delete_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new C3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}share_dashboards(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_share_dashboards(w,g,h,T)})}send_share_dashboards(w,g,h,T){const _=new this.pClass(this.output),v={session:w,dashboard_ids:g,groups:h,permissions:T},B=new Cx(v);try{return _.writeMessageBegin("share_dashboards",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_share_dashboards(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new R3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}delete_dashboards(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_delete_dashboards(w,g)})}send_delete_dashboards(w,g){const h=new this.pClass(this.output),T={session:w,dashboard_ids:g},_=new Rx(T);try{return h.writeMessageBegin("delete_dashboards",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_delete_dashboards(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new P3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}share_dashboard(w,g,h,T,_,v){this._seqid=this.new_seqid();const B=this;return new Promise((Q,pe)=>{B._reqs[B.seqid()]=($e,sn)=>$e?pe($e):Q(sn),B.send_share_dashboard(w,g,h,T,_,v)})}send_share_dashboard(w,g,h,T,_,v){const B=new this.pClass(this.output),Q={session:w,dashboard_id:g,groups:h,objects:T,permissions:_,grant_role:v},pe=new Px(Q);try{return B.writeMessageBegin("share_dashboard",a.MessageType.CALL,this.seqid()),pe.write(B),B.writeMessageEnd(),this.output.flush()}catch($e){throw delete this._reqs[this.seqid()],typeof B.reset=="function"&&B.reset(),$e}}recv_share_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new D3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}unshare_dashboard(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_unshare_dashboard(w,g,h,T,_)})}send_unshare_dashboard(w,g,h,T,_){const v=new this.pClass(this.output),B={session:w,dashboard_id:g,groups:h,objects:T,permissions:_},Q=new Dx(B);try{return v.writeMessageBegin("unshare_dashboard",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_unshare_dashboard(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new j3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}unshare_dashboards(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_unshare_dashboards(w,g,h,T)})}send_unshare_dashboards(w,g,h,T){const _=new this.pClass(this.output),v={session:w,dashboard_ids:g,groups:h,permissions:T},B=new jx(v);try{return _.writeMessageBegin("unshare_dashboards",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_unshare_dashboards(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new U3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_dashboard_grantees(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_dashboard_grantees(w,g)})}send_get_dashboard_grantees(w,g){const h=new this.pClass(this.output),T={session:w,dashboard_id:g},_=new Ux(T);try{return h.writeMessageBegin("get_dashboard_grantees",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_dashboard_grantees(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new H3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_dashboard_grantees failed: unknown result")}get_link_view(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_link_view(w,g)})}send_get_link_view(w,g){const h=new this.pClass(this.output),T={session:w,link:g},_=new Hx(T);try{return h.writeMessageBegin("get_link_view",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_link_view(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new z3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_link_view failed: unknown result")}create_link(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_create_link(w,g,h)})}send_create_link(w,g,h){const T=new this.pClass(this.output),_={session:w,view_state:g,view_metadata:h},v=new zx(_);try{return T.writeMessageBegin("create_link",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_create_link(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new $3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("create_link failed: unknown result")}load_table_binary(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_load_table_binary(w,g,h,T)})}send_load_table_binary(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,rows:h,column_names:T},B=new $x(v);try{return _.writeMessageBegin("load_table_binary",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_load_table_binary(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new q3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}load_table_binary_columnar(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_load_table_binary_columnar(w,g,h,T)})}send_load_table_binary_columnar(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,cols:h,column_names:T},B=new qx(v);try{return _.writeMessageBegin("load_table_binary_columnar",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_load_table_binary_columnar(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new V3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}load_table_binary_columnar_polys(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_load_table_binary_columnar_polys(w,g,h,T,_)})}send_load_table_binary_columnar_polys(w,g,h,T,_){const v=new this.pClass(this.output),B={session:w,table_name:g,cols:h,column_names:T,assign_render_groups:_},Q=new Vx(B);try{return v.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_load_table_binary_columnar_polys(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new G3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}load_table_binary_arrow(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_load_table_binary_arrow(w,g,h,T)})}send_load_table_binary_arrow(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,arrow_stream:h,use_column_names:T},B=new Gx(v);try{return _.writeMessageBegin("load_table_binary_arrow",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_load_table_binary_arrow(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new W3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}load_table(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_load_table(w,g,h,T)})}send_load_table(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,rows:h,column_names:T},B=new Wx(v);try{return _.writeMessageBegin("load_table",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_load_table(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Y3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}detect_column_types(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_detect_column_types(w,g,h)})}send_detect_column_types(w,g,h){const T=new this.pClass(this.output),_={session:w,file_name:g,copy_params:h},v=new Yx(_);try{return T.writeMessageBegin("detect_column_types",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_detect_column_types(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new X3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("detect_column_types failed: unknown result")}create_table(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_create_table(w,g,h,T)})}send_create_table(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,row_desc:h,create_params:T},B=new Xx(v);try{return _.writeMessageBegin("create_table",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_create_table(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new K3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}import_table(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_import_table(w,g,h,T)})}send_import_table(w,g,h,T){const _=new this.pClass(this.output),v={session:w,table_name:g,file_name:h,copy_params:T},B=new Kx(v);try{return _.writeMessageBegin("import_table",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_import_table(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Z3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}import_geo_table(w,g,h,T,_,v){this._seqid=this.new_seqid();const B=this;return new Promise((Q,pe)=>{B._reqs[B.seqid()]=($e,sn)=>$e?pe($e):Q(sn),B.send_import_geo_table(w,g,h,T,_,v)})}send_import_geo_table(w,g,h,T,_,v){const B=new this.pClass(this.output),Q={session:w,table_name:g,file_name:h,copy_params:T,row_desc:_,create_params:v},pe=new Zx(Q);try{return B.writeMessageBegin("import_geo_table",a.MessageType.CALL,this.seqid()),pe.write(B),B.writeMessageEnd(),this.output.flush()}catch($e){throw delete this._reqs[this.seqid()],typeof B.reset=="function"&&B.reset(),$e}}recv_import_geo_table(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new J3;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}import_table_status(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_import_table_status(w,g)})}send_import_table_status(w,g){const h=new this.pClass(this.output),T={session:w,import_id:g},_=new Jx(T);try{return h.writeMessageBegin("import_table_status",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_import_table_status(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Q3;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("import_table_status failed: unknown result")}get_first_geo_file_in_archive(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_first_geo_file_in_archive(w,g,h)})}send_get_first_geo_file_in_archive(w,g,h){const T=new this.pClass(this.output),_={session:w,archive_path:g,copy_params:h},v=new Qx(_);try{return T.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_first_geo_file_in_archive(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new eg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_first_geo_file_in_archive failed: unknown result")}get_all_files_in_archive(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_all_files_in_archive(w,g,h)})}send_get_all_files_in_archive(w,g,h){const T=new this.pClass(this.output),_={session:w,archive_path:g,copy_params:h},v=new ek(_);try{return T.writeMessageBegin("get_all_files_in_archive",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_all_files_in_archive(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new tg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_all_files_in_archive failed: unknown result")}get_layers_in_geo_file(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_layers_in_geo_file(w,g,h)})}send_get_layers_in_geo_file(w,g,h){const T=new this.pClass(this.output),_={session:w,file_name:g,copy_params:h},v=new tk(_);try{return T.writeMessageBegin("get_layers_in_geo_file",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_layers_in_geo_file(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ng;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_layers_in_geo_file failed: unknown result")}query_get_outer_fragment_count(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_query_get_outer_fragment_count(w,g)})}send_query_get_outer_fragment_count(w,g){const h=new this.pClass(this.output),T={session:w,query:g},_=new nk(T);try{return h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_query_get_outer_fragment_count(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ig;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("query_get_outer_fragment_count failed: unknown result")}check_table_consistency(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_check_table_consistency(w,g)})}send_check_table_consistency(w,g){const h=new this.pClass(this.output),T={session:w,table_id:g},_=new ik(T);try{return h.writeMessageBegin("check_table_consistency",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_check_table_consistency(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new sg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("check_table_consistency failed: unknown result")}start_query(w,g,h,T,_,v){this._seqid=this.new_seqid();const B=this;return new Promise((Q,pe)=>{B._reqs[B.seqid()]=($e,sn)=>$e?pe($e):Q(sn),B.send_start_query(w,g,h,T,_,v)})}send_start_query(w,g,h,T,_,v){const B=new this.pClass(this.output),Q={leaf_session:w,parent_session:g,query_ra:h,start_time_str:T,just_explain:_,outer_fragment_indices:v},pe=new sk(Q);try{return B.writeMessageBegin("start_query",a.MessageType.CALL,this.seqid()),pe.write(B),B.writeMessageEnd(),this.output.flush()}catch($e){throw delete this._reqs[this.seqid()],typeof B.reset=="function"&&B.reset(),$e}}recv_start_query(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new rg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("start_query failed: unknown result")}execute_query_step(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_execute_query_step(w,g,h)})}send_execute_query_step(w,g,h){const T=new this.pClass(this.output),_={pending_query:w,subquery_id:g,start_time_str:h},v=new rk(_);try{return T.writeMessageBegin("execute_query_step",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_execute_query_step(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ag;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("execute_query_step failed: unknown result")}broadcast_serialized_rows(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_broadcast_serialized_rows(w,g,h,T,_)})}send_broadcast_serialized_rows(w,g,h,T,_){const v=new this.pClass(this.output),B={serialized_rows:w,row_desc:g,query_id:h,subquery_id:T,is_final_subquery_result:_},Q=new ak(B);try{return v.writeMessageBegin("broadcast_serialized_rows",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_broadcast_serialized_rows(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new og;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}start_render_query(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_start_render_query(w,g,h,T)})}send_start_render_query(w,g,h,T){const _=new this.pClass(this.output),v={session:w,widget_id:g,node_idx:h,vega_json:T},B=new ok(v);try{return _.writeMessageBegin("start_render_query",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_start_render_query(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new lg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("start_render_query failed: unknown result")}execute_next_render_step(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_execute_next_render_step(w,g)})}send_execute_next_render_step(w,g){const h=new this.pClass(this.output),T={pending_render:w,merged_data:g},_=new lk(T);try{return h.writeMessageBegin("execute_next_render_step",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_execute_next_render_step(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new cg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("execute_next_render_step failed: unknown result")}insert_data(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_insert_data(w,g)})}send_insert_data(w,g){const h=new this.pClass(this.output),T={session:w,insert_data:g},_=new ck(T);try{return h.writeMessageBegin("insert_data",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_insert_data(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new dg;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}insert_chunks(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_insert_chunks(w,g)})}send_insert_chunks(w,g){const h=new this.pClass(this.output),T={session:w,insert_chunks:g},_=new dk(T);try{return h.writeMessageBegin("insert_chunks",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_insert_chunks(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new fg;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}checkpoint(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_checkpoint(w,g)})}send_checkpoint(w,g){const h=new this.pClass(this.output),T={session:w,table_id:g},_=new fk(T);try{return h.writeMessageBegin("checkpoint",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_checkpoint(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new ug;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_roles(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_roles(w)})}send_get_roles(w){const g=new this.pClass(this.output),h={session:w},T=new uk(h);try{return g.writeMessageBegin("get_roles",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_roles(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new hg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_roles failed: unknown result")}get_db_objects_for_grantee(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_db_objects_for_grantee(w,g)})}send_get_db_objects_for_grantee(w,g){const h=new this.pClass(this.output),T={session:w,roleName:g},_=new hk(T);try{return h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_db_objects_for_grantee(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new gg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_db_objects_for_grantee failed: unknown result")}get_db_object_privs(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_get_db_object_privs(w,g,h)})}send_get_db_object_privs(w,g,h){const T=new this.pClass(this.output),_={session:w,objectName:g,type:h},v=new gk(_);try{return T.writeMessageBegin("get_db_object_privs",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_get_db_object_privs(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new _g;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_db_object_privs failed: unknown result")}get_all_roles_for_user(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_all_roles_for_user(w,g)})}send_get_all_roles_for_user(w,g){const h=new this.pClass(this.output),T={session:w,userName:g},_=new _k(T);try{return h.writeMessageBegin("get_all_roles_for_user",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_all_roles_for_user(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new pg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_all_roles_for_user failed: unknown result")}get_all_effective_roles_for_user(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_all_effective_roles_for_user(w,g)})}send_get_all_effective_roles_for_user(w,g){const h=new this.pClass(this.output),T={session:w,userName:g},_=new pk(T);try{return h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_all_effective_roles_for_user(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new yg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_all_effective_roles_for_user failed: unknown result")}has_role(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_has_role(w,g,h)})}send_has_role(w,g,h){const T=new this.pClass(this.output),_={session:w,granteeName:g,roleName:h},v=new yk(_);try{return T.writeMessageBegin("has_role",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_has_role(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new mg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("has_role failed: unknown result")}has_object_privilege(w,g,h,T,_){this._seqid=this.new_seqid();const v=this;return new Promise((B,Q)=>{v._reqs[v.seqid()]=(pe,$e)=>pe?Q(pe):B($e),v.send_has_object_privilege(w,g,h,T,_)})}send_has_object_privilege(w,g,h,T,_){const v=new this.pClass(this.output),B={session:w,granteeName:g,ObjectName:h,objectType:T,permissions:_},Q=new mk(B);try{return v.writeMessageBegin("has_object_privilege",a.MessageType.CALL,this.seqid()),Q.write(v),v.writeMessageEnd(),this.output.flush()}catch(pe){throw delete this._reqs[this.seqid()],typeof v.reset=="function"&&v.reset(),pe}}recv_has_object_privilege(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new wg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("has_object_privilege failed: unknown result")}set_license_key(w,g,h){this._seqid=this.new_seqid();const T=this;return new Promise((_,v)=>{T._reqs[T.seqid()]=(B,Q)=>B?v(B):_(Q),T.send_set_license_key(w,g,h)})}send_set_license_key(w,g,h){const T=new this.pClass(this.output),_={session:w,key:g,nonce:h},v=new wk(_);try{return T.writeMessageBegin("set_license_key",a.MessageType.CALL,this.seqid()),v.write(T),T.writeMessageEnd(),this.output.flush()}catch(B){throw delete this._reqs[this.seqid()],typeof T.reset=="function"&&T.reset(),B}}recv_set_license_key(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Lg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("set_license_key failed: unknown result")}get_license_claims(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_license_claims(w,g)})}send_get_license_claims(w,g){const h=new this.pClass(this.output),T={session:w,nonce:g},_=new Lk(T);try{return h.writeMessageBegin("get_license_claims",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_license_claims(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new bg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_license_claims failed: unknown result")}get_device_parameters(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_device_parameters(w)})}send_get_device_parameters(w){const g=new this.pClass(this.output),h={session:w},T=new bk(h);try{return g.writeMessageBegin("get_device_parameters",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_device_parameters(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Tg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_device_parameters failed: unknown result")}register_runtime_extension_functions(w,g,h,T){this._seqid=this.new_seqid();const _=this;return new Promise((v,B)=>{_._reqs[_.seqid()]=(Q,pe)=>Q?B(Q):v(pe),_.send_register_runtime_extension_functions(w,g,h,T)})}send_register_runtime_extension_functions(w,g,h,T){const _=new this.pClass(this.output),v={session:w,udfs:g,udtfs:h,device_ir_map:T},B=new Tk(v);try{return _.writeMessageBegin("register_runtime_extension_functions",a.MessageType.CALL,this.seqid()),B.write(_),_.writeMessageEnd(),this.output.flush()}catch(Q){throw delete this._reqs[this.seqid()],typeof _.reset=="function"&&_.reset(),Q}}recv_register_runtime_extension_functions(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new vg;if(_.read(w),w.readMessageEnd(),_.e!==null)return T(_.e);T(null)}get_table_function_names(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_table_function_names(w)})}send_get_table_function_names(w){const g=new this.pClass(this.output),h={session:w},T=new vk(h);try{return g.writeMessageBegin("get_table_function_names",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_table_function_names(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Eg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_table_function_names failed: unknown result")}get_runtime_table_function_names(w){this._seqid=this.new_seqid();const g=this;return new Promise((h,T)=>{g._reqs[g.seqid()]=(_,v)=>_?T(_):h(v),g.send_get_runtime_table_function_names(w)})}send_get_runtime_table_function_names(w){const g=new this.pClass(this.output),h={session:w},T=new Ek(h);try{return g.writeMessageBegin("get_runtime_table_function_names",a.MessageType.CALL,this.seqid()),T.write(g),g.writeMessageEnd(),this.output.flush()}catch(_){throw delete this._reqs[this.seqid()],typeof g.reset=="function"&&g.reset(),_}}recv_get_runtime_table_function_names(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new Sg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_runtime_table_function_names failed: unknown result")}get_table_function_details(w,g){this._seqid=this.new_seqid();const h=this;return new Promise((T,_)=>{h._reqs[h.seqid()]=(v,B)=>v?_(v):T(B),h.send_get_table_function_details(w,g)})}send_get_table_function_details(w,g){const h=new this.pClass(this.output),T={session:w,udtf_names:g},_=new Sk(T);try{return h.writeMessageBegin("get_table_function_details",a.MessageType.CALL,this.seqid()),_.write(h),h.writeMessageEnd(),this.output.flush()}catch(v){throw delete this._reqs[this.seqid()],typeof h.reset=="function"&&h.reset(),v}}recv_get_table_function_details(w,g,h){const T=this._reqs[h]||function(){};if(delete this._reqs[h],g==a.MessageType.EXCEPTION){const v=new a.TApplicationException;return v.read(w),w.readMessageEnd(),T(v)}const _=new xg;return _.read(w),w.readMessageEnd(),_.e!==null?T(_.e):_.success!==null?T(null,_.success):T("get_table_function_details failed: unknown result")}},d.Processor=class{constructor(w){this._handler=w}process(w,g){const h=w.readMessageBegin();if(this["process_"+h.fname])return this["process_"+h.fname].call(this,h.rseqid,w,g);{w.skip(a.Type.STRUCT),w.readMessageEnd();const T=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN_METHOD,"Unknown function "+h.fname);g.writeMessageBegin(h.fname,a.MessageType.EXCEPTION,h.rseqid),T.write(g),g.writeMessageEnd(),g.flush()}}process_connect(w,g,h){const T=new b;T.read(g),g.readMessageEnd(),this._handler.connect.length===3?Promise.resolve(this._handler.connect.bind(this._handler)(T.user,T.passwd,T.dbname)).then(_=>{const v=new L({success:_});h.writeMessageBegin("connect",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new L(_),h.writeMessageBegin("connect",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("connect",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.connect(T.user,T.passwd,T.dbname,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new L(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("connect",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("connect",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_krb5_connect(w,g,h){const T=new E;T.read(g),g.readMessageEnd(),this._handler.krb5_connect.length===2?Promise.resolve(this._handler.krb5_connect.bind(this._handler)(T.inputToken,T.dbname)).then(_=>{const v=new S({success:_});h.writeMessageBegin("krb5_connect",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new S(_),h.writeMessageBegin("krb5_connect",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("krb5_connect",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.krb5_connect(T.inputToken,T.dbname,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new S(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("krb5_connect",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("krb5_connect",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_disconnect(w,g,h){const T=new x;T.read(g),g.readMessageEnd(),this._handler.disconnect.length===1?Promise.resolve(this._handler.disconnect.bind(this._handler)(T.session)).then(_=>{const v=new F({success:_});h.writeMessageBegin("disconnect",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new F(_),h.writeMessageBegin("disconnect",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("disconnect",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.disconnect(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new F(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("disconnect",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("disconnect",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_switch_database(w,g,h){const T=new k;T.read(g),g.readMessageEnd(),this._handler.switch_database.length===2?Promise.resolve(this._handler.switch_database.bind(this._handler)(T.session,T.dbname)).then(_=>{const v=new M({success:_});h.writeMessageBegin("switch_database",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new M(_),h.writeMessageBegin("switch_database",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("switch_database",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.switch_database(T.session,T.dbname,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new M(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("switch_database",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("switch_database",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_clone_session(w,g,h){const T=new O;T.read(g),g.readMessageEnd(),this._handler.clone_session.length===1?Promise.resolve(this._handler.clone_session.bind(this._handler)(T.session)).then(_=>{const v=new C({success:_});h.writeMessageBegin("clone_session",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new C(_),h.writeMessageBegin("clone_session",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clone_session",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.clone_session(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new C(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("clone_session",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clone_session",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_server_status(w,g,h){const T=new P;T.read(g),g.readMessageEnd(),this._handler.get_server_status.length===1?Promise.resolve(this._handler.get_server_status.bind(this._handler)(T.session)).then(_=>{const v=new j({success:_});h.writeMessageBegin("get_server_status",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new j(_),h.writeMessageBegin("get_server_status",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_server_status",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_server_status(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new j(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_server_status",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_server_status",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_status(w,g,h){const T=new R;T.read(g),g.readMessageEnd(),this._handler.get_status.length===1?Promise.resolve(this._handler.get_status.bind(this._handler)(T.session)).then(_=>{const v=new H({success:_});h.writeMessageBegin("get_status",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new H(_),h.writeMessageBegin("get_status",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_status",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_status(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new H(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_status",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_status",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_hardware_info(w,g,h){const T=new z;T.read(g),g.readMessageEnd(),this._handler.get_hardware_info.length===1?Promise.resolve(this._handler.get_hardware_info.bind(this._handler)(T.session)).then(_=>{const v=new Y({success:_});h.writeMessageBegin("get_hardware_info",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Y(_),h.writeMessageBegin("get_hardware_info",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_hardware_info",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_hardware_info(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Y(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_hardware_info",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_hardware_info",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_tables(w,g,h){const T=new $;T.read(g),g.readMessageEnd(),this._handler.get_tables.length===1?Promise.resolve(this._handler.get_tables.bind(this._handler)(T.session)).then(_=>{const v=new W({success:_});h.writeMessageBegin("get_tables",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new W(_),h.writeMessageBegin("get_tables",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_tables(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new W(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_tables",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_tables_for_database(w,g,h){const T=new X;T.read(g),g.readMessageEnd(),this._handler.get_tables_for_database.length===2?Promise.resolve(this._handler.get_tables_for_database.bind(this._handler)(T.session,T.database_name)).then(_=>{const v=new G({success:_});h.writeMessageBegin("get_tables_for_database",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new G(_),h.writeMessageBegin("get_tables_for_database",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables_for_database",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_tables_for_database(T.session,T.database_name,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new G(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_tables_for_database",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables_for_database",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_physical_tables(w,g,h){const T=new oe;T.read(g),g.readMessageEnd(),this._handler.get_physical_tables.length===1?Promise.resolve(this._handler.get_physical_tables.bind(this._handler)(T.session)).then(_=>{const v=new he({success:_});h.writeMessageBegin("get_physical_tables",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new he(_),h.writeMessageBegin("get_physical_tables",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_physical_tables",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_physical_tables(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new he(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_physical_tables",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_physical_tables",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_views(w,g,h){const T=new ie;T.read(g),g.readMessageEnd(),this._handler.get_views.length===1?Promise.resolve(this._handler.get_views.bind(this._handler)(T.session)).then(_=>{const v=new Oe({success:_});h.writeMessageBegin("get_views",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Oe(_),h.writeMessageBegin("get_views",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_views",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_views(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Oe(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_views",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_views",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_tables_meta(w,g,h){const T=new de;T.read(g),g.readMessageEnd(),this._handler.get_tables_meta.length===1?Promise.resolve(this._handler.get_tables_meta.bind(this._handler)(T.session)).then(_=>{const v=new Me({success:_});h.writeMessageBegin("get_tables_meta",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Me(_),h.writeMessageBegin("get_tables_meta",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables_meta",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_tables_meta(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Me(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_tables_meta",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_tables_meta",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_details(w,g,h){const T=new Fe;T.read(g),g.readMessageEnd(),this._handler.get_table_details.length===2?Promise.resolve(this._handler.get_table_details.bind(this._handler)(T.session,T.table_name)).then(_=>{const v=new Ge({success:_});h.writeMessageBegin("get_table_details",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Ge(_),h.writeMessageBegin("get_table_details",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_details",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_details(T.session,T.table_name,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Ge(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_details",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_details",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_details_for_database(w,g,h){const T=new pt;T.read(g),g.readMessageEnd(),this._handler.get_table_details_for_database.length===3?Promise.resolve(this._handler.get_table_details_for_database.bind(this._handler)(T.session,T.table_name,T.database_name)).then(_=>{const v=new ht({success:_});h.writeMessageBegin("get_table_details_for_database",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ht(_),h.writeMessageBegin("get_table_details_for_database",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_details_for_database",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_details_for_database(T.session,T.table_name,T.database_name,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ht(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_details_for_database",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_details_for_database",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_internal_table_details(w,g,h){const T=new ge;T.read(g),g.readMessageEnd(),this._handler.get_internal_table_details.length===3?Promise.resolve(this._handler.get_internal_table_details.bind(this._handler)(T.session,T.table_name,T.include_system_columns)).then(_=>{const v=new V({success:_});h.writeMessageBegin("get_internal_table_details",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new V(_),h.writeMessageBegin("get_internal_table_details",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_internal_table_details",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_internal_table_details(T.session,T.table_name,T.include_system_columns,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new V(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_internal_table_details",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_internal_table_details",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_internal_table_details_for_database(w,g,h){const T=new q;T.read(g),g.readMessageEnd(),this._handler.get_internal_table_details_for_database.length===3?Promise.resolve(this._handler.get_internal_table_details_for_database.bind(this._handler)(T.session,T.table_name,T.database_name)).then(_=>{const v=new D({success:_});h.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new D(_),h.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_internal_table_details_for_database(T.session,T.table_name,T.database_name,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new D(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_internal_table_details_for_database",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_users(w,g,h){const T=new K;T.read(g),g.readMessageEnd(),this._handler.get_users.length===1?Promise.resolve(this._handler.get_users.bind(this._handler)(T.session)).then(_=>{const v=new J({success:_});h.writeMessageBegin("get_users",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new J(_),h.writeMessageBegin("get_users",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_users",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_users(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new J(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_users",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_users",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_databases(w,g,h){const T=new re;T.read(g),g.readMessageEnd(),this._handler.get_databases.length===1?Promise.resolve(this._handler.get_databases.bind(this._handler)(T.session)).then(_=>{const v=new se({success:_});h.writeMessageBegin("get_databases",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new se(_),h.writeMessageBegin("get_databases",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_databases",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_databases(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new se(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_databases",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_databases",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_version(w,g,h){new _e().read(g),g.readMessageEnd(),this._handler.get_version.length===0?Promise.resolve(this._handler.get_version.bind(this._handler)()).then(_=>{const v=new be({success:_});h.writeMessageBegin("get_version",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new be(_),h.writeMessageBegin("get_version",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_version",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_version((_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new be(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_version",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_version",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_start_heap_profile(w,g,h){const T=new Ke;T.read(g),g.readMessageEnd(),this._handler.start_heap_profile.length===1?Promise.resolve(this._handler.start_heap_profile.bind(this._handler)(T.session)).then(_=>{const v=new It({success:_});h.writeMessageBegin("start_heap_profile",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new It(_),h.writeMessageBegin("start_heap_profile",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_heap_profile",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.start_heap_profile(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new It(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("start_heap_profile",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_heap_profile",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_stop_heap_profile(w,g,h){const T=new Et;T.read(g),g.readMessageEnd(),this._handler.stop_heap_profile.length===1?Promise.resolve(this._handler.stop_heap_profile.bind(this._handler)(T.session)).then(_=>{const v=new et({success:_});h.writeMessageBegin("stop_heap_profile",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new et(_),h.writeMessageBegin("stop_heap_profile",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("stop_heap_profile",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.stop_heap_profile(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new et(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("stop_heap_profile",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("stop_heap_profile",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_heap_profile(w,g,h){const T=new Zt;T.read(g),g.readMessageEnd(),this._handler.get_heap_profile.length===1?Promise.resolve(this._handler.get_heap_profile.bind(this._handler)(T.session)).then(_=>{const v=new kn({success:_});h.writeMessageBegin("get_heap_profile",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new kn(_),h.writeMessageBegin("get_heap_profile",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_heap_profile",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_heap_profile(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new kn(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_heap_profile",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_heap_profile",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_memory(w,g,h){const T=new Yi;T.read(g),g.readMessageEnd(),this._handler.get_memory.length===2?Promise.resolve(this._handler.get_memory.bind(this._handler)(T.session,T.memory_level)).then(_=>{const v=new fe({success:_});h.writeMessageBegin("get_memory",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new fe(_),h.writeMessageBegin("get_memory",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_memory",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_memory(T.session,T.memory_level,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new fe(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_memory",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_memory",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_clear_cpu_memory(w,g,h){const T=new oi;T.read(g),g.readMessageEnd(),this._handler.clear_cpu_memory.length===1?Promise.resolve(this._handler.clear_cpu_memory.bind(this._handler)(T.session)).then(_=>{const v=new jn({success:_});h.writeMessageBegin("clear_cpu_memory",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new jn(_),h.writeMessageBegin("clear_cpu_memory",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clear_cpu_memory",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.clear_cpu_memory(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new jn(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("clear_cpu_memory",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clear_cpu_memory",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_clear_gpu_memory(w,g,h){const T=new ur;T.read(g),g.readMessageEnd(),this._handler.clear_gpu_memory.length===1?Promise.resolve(this._handler.clear_gpu_memory.bind(this._handler)(T.session)).then(_=>{const v=new ln({success:_});h.writeMessageBegin("clear_gpu_memory",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ln(_),h.writeMessageBegin("clear_gpu_memory",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clear_gpu_memory",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.clear_gpu_memory(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ln(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("clear_gpu_memory",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("clear_gpu_memory",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_cur_session(w,g,h){const T=new cl;T.read(g),g.readMessageEnd(),this._handler.set_cur_session.length===5?Promise.resolve(this._handler.set_cur_session.bind(this._handler)(T.parent_session,T.leaf_session,T.start_time_str,T.label,T.for_running_query_kernel)).then(_=>{const v=new dl({success:_});h.writeMessageBegin("set_cur_session",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new dl(_),h.writeMessageBegin("set_cur_session",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_cur_session",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_cur_session(T.parent_session,T.leaf_session,T.start_time_str,T.label,T.for_running_query_kernel,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new dl(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_cur_session",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_cur_session",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_invalidate_cur_session(w,g,h){const T=new Ts;T.read(g),g.readMessageEnd(),this._handler.invalidate_cur_session.length===5?Promise.resolve(this._handler.invalidate_cur_session.bind(this._handler)(T.parent_session,T.leaf_session,T.start_time_str,T.label,T.for_running_query_kernel)).then(_=>{const v=new fl({success:_});h.writeMessageBegin("invalidate_cur_session",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new fl(_),h.writeMessageBegin("invalidate_cur_session",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("invalidate_cur_session",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.invalidate_cur_session(T.parent_session,T.leaf_session,T.start_time_str,T.label,T.for_running_query_kernel,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new fl(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("invalidate_cur_session",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("invalidate_cur_session",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_table_epoch(w,g,h){const T=new N;T.read(g),g.readMessageEnd(),this._handler.set_table_epoch.length===4?Promise.resolve(this._handler.set_table_epoch.bind(this._handler)(T.session,T.db_id,T.table_id,T.new_epoch)).then(_=>{const v=new I({success:_});h.writeMessageBegin("set_table_epoch",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new I(_),h.writeMessageBegin("set_table_epoch",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epoch",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_table_epoch(T.session,T.db_id,T.table_id,T.new_epoch,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new I(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_table_epoch",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epoch",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_table_epoch_by_name(w,g,h){const T=new A;T.read(g),g.readMessageEnd(),this._handler.set_table_epoch_by_name.length===3?Promise.resolve(this._handler.set_table_epoch_by_name.bind(this._handler)(T.session,T.table_name,T.new_epoch)).then(_=>{const v=new U({success:_});h.writeMessageBegin("set_table_epoch_by_name",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new U(_),h.writeMessageBegin("set_table_epoch_by_name",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epoch_by_name",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_table_epoch_by_name(T.session,T.table_name,T.new_epoch,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new U(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_table_epoch_by_name",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epoch_by_name",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_epoch(w,g,h){const T=new Z;T.read(g),g.readMessageEnd(),this._handler.get_table_epoch.length===3?Promise.resolve(this._handler.get_table_epoch.bind(this._handler)(T.session,T.db_id,T.table_id)).then(_=>{const v=new ee({success:_});h.writeMessageBegin("get_table_epoch",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epoch",a.MessageType.EXCEPTION,w),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_epoch(T.session,T.db_id,T.table_id,(_,v)=>{let B;_===null||typeof _>"u"?(B=new ee(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_epoch",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epoch",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_epoch_by_name(w,g,h){const T=new ne;T.read(g),g.readMessageEnd(),this._handler.get_table_epoch_by_name.length===2?Promise.resolve(this._handler.get_table_epoch_by_name.bind(this._handler)(T.session,T.table_name)).then(_=>{const v=new Be({success:_});h.writeMessageBegin("get_table_epoch_by_name",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epoch_by_name",a.MessageType.EXCEPTION,w),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_epoch_by_name(T.session,T.table_name,(_,v)=>{let B;_===null||typeof _>"u"?(B=new Be(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_epoch_by_name",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epoch_by_name",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_epochs(w,g,h){const T=new je;T.read(g),g.readMessageEnd(),this._handler.get_table_epochs.length===3?Promise.resolve(this._handler.get_table_epochs.bind(this._handler)(T.session,T.db_id,T.table_id)).then(_=>{const v=new Ue({success:_});h.writeMessageBegin("get_table_epochs",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epochs",a.MessageType.EXCEPTION,w),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_epochs(T.session,T.db_id,T.table_id,(_,v)=>{let B;_===null||typeof _>"u"?(B=new Ue(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_epochs",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_epochs",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_table_epochs(w,g,h){const T=new Ye;T.read(g),g.readMessageEnd(),this._handler.set_table_epochs.length===3?Promise.resolve(this._handler.set_table_epochs.bind(this._handler)(T.session,T.db_id,T.table_epochs)).then(_=>{const v=new Xe({success:_});h.writeMessageBegin("set_table_epochs",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epochs",a.MessageType.EXCEPTION,w),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_table_epochs(T.session,T.db_id,T.table_epochs,(_,v)=>{let B;_===null||typeof _>"u"?(B=new Xe(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_table_epochs",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_table_epochs",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_session_info(w,g,h){const T=new ul;T.read(g),g.readMessageEnd(),this._handler.get_session_info.length===1?Promise.resolve(this._handler.get_session_info.bind(this._handler)(T.session)).then(_=>{const v=new g3({success:_});h.writeMessageBegin("get_session_info",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new g3(_),h.writeMessageBegin("get_session_info",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_session_info",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_session_info(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new g3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_session_info",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_session_info",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_queries_info(w,g,h){const T=new gx;T.read(g),g.readMessageEnd(),this._handler.get_queries_info.length===1?Promise.resolve(this._handler.get_queries_info.bind(this._handler)(T.session)).then(_=>{const v=new _3({success:_});h.writeMessageBegin("get_queries_info",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new _3(_),h.writeMessageBegin("get_queries_info",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_queries_info",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_queries_info(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new _3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_queries_info",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_queries_info",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_leaf_info(w,g,h){const T=new _x;T.read(g),g.readMessageEnd(),this._handler.set_leaf_info.length===2?Promise.resolve(this._handler.set_leaf_info.bind(this._handler)(T.session,T.leaf_info)).then(_=>{const v=new p3({success:_});h.writeMessageBegin("set_leaf_info",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new p3(_),h.writeMessageBegin("set_leaf_info",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_leaf_info",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_leaf_info(T.session,T.leaf_info,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new p3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_leaf_info",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_leaf_info",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_sql_execute(w,g,h){const T=new px;T.read(g),g.readMessageEnd(),this._handler.sql_execute.length===6?Promise.resolve(this._handler.sql_execute.bind(this._handler)(T.session,T.query,T.column_format,T.nonce,T.first_n,T.at_most_n)).then(_=>{const v=new y3({success:_});h.writeMessageBegin("sql_execute",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new y3(_),h.writeMessageBegin("sql_execute",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.sql_execute(T.session,T.query,T.column_format,T.nonce,T.first_n,T.at_most_n,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new y3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("sql_execute",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_sql_execute_df(w,g,h){const T=new yx;T.read(g),g.readMessageEnd(),this._handler.sql_execute_df.length===6?Promise.resolve(this._handler.sql_execute_df.bind(this._handler)(T.session,T.query,T.device_type,T.device_id,T.first_n,T.transport_method)).then(_=>{const v=new m3({success:_});h.writeMessageBegin("sql_execute_df",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new m3(_),h.writeMessageBegin("sql_execute_df",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute_df",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.sql_execute_df(T.session,T.query,T.device_type,T.device_id,T.first_n,T.transport_method,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new m3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("sql_execute_df",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute_df",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_sql_execute_gdf(w,g,h){const T=new mx;T.read(g),g.readMessageEnd(),this._handler.sql_execute_gdf.length===4?Promise.resolve(this._handler.sql_execute_gdf.bind(this._handler)(T.session,T.query,T.device_id,T.first_n)).then(_=>{const v=new w3({success:_});h.writeMessageBegin("sql_execute_gdf",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new w3(_),h.writeMessageBegin("sql_execute_gdf",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute_gdf",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.sql_execute_gdf(T.session,T.query,T.device_id,T.first_n,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new w3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("sql_execute_gdf",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_execute_gdf",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_deallocate_df(w,g,h){const T=new wx;T.read(g),g.readMessageEnd(),this._handler.deallocate_df.length===4?Promise.resolve(this._handler.deallocate_df.bind(this._handler)(T.session,T.df,T.device_type,T.device_id)).then(_=>{const v=new L3({success:_});h.writeMessageBegin("deallocate_df",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new L3(_),h.writeMessageBegin("deallocate_df",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("deallocate_df",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.deallocate_df(T.session,T.df,T.device_type,T.device_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new L3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("deallocate_df",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("deallocate_df",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_interrupt(w,g,h){const T=new Lx;T.read(g),g.readMessageEnd(),this._handler.interrupt.length===2?Promise.resolve(this._handler.interrupt.bind(this._handler)(T.query_session,T.interrupt_session)).then(_=>{const v=new b3({success:_});h.writeMessageBegin("interrupt",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new b3(_),h.writeMessageBegin("interrupt",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("interrupt",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.interrupt(T.query_session,T.interrupt_session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new b3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("interrupt",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("interrupt",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_sql_validate(w,g,h){const T=new bx;T.read(g),g.readMessageEnd(),this._handler.sql_validate.length===2?Promise.resolve(this._handler.sql_validate.bind(this._handler)(T.session,T.query)).then(_=>{const v=new T3({success:_});h.writeMessageBegin("sql_validate",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new T3(_),h.writeMessageBegin("sql_validate",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_validate",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.sql_validate(T.session,T.query,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new T3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("sql_validate",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("sql_validate",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_completion_hints(w,g,h){const T=new Tx;T.read(g),g.readMessageEnd(),this._handler.get_completion_hints.length===3?Promise.resolve(this._handler.get_completion_hints.bind(this._handler)(T.session,T.sql,T.cursor)).then(_=>{const v=new v3({success:_});h.writeMessageBegin("get_completion_hints",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new v3(_),h.writeMessageBegin("get_completion_hints",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_completion_hints",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_completion_hints(T.session,T.sql,T.cursor,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new v3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_completion_hints",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_completion_hints",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_execution_mode(w,g,h){const T=new vx;T.read(g),g.readMessageEnd(),this._handler.set_execution_mode.length===2?Promise.resolve(this._handler.set_execution_mode.bind(this._handler)(T.session,T.mode)).then(_=>{const v=new E3({success:_});h.writeMessageBegin("set_execution_mode",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new E3(_),h.writeMessageBegin("set_execution_mode",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_execution_mode",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_execution_mode(T.session,T.mode,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new E3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_execution_mode",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_execution_mode",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_render_vega(w,g,h){const T=new Ex;T.read(g),g.readMessageEnd(),this._handler.render_vega.length===5?Promise.resolve(this._handler.render_vega.bind(this._handler)(T.session,T.widget_id,T.vega_json,T.compression_level,T.nonce)).then(_=>{const v=new S3({success:_});h.writeMessageBegin("render_vega",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new S3(_),h.writeMessageBegin("render_vega",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("render_vega",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.render_vega(T.session,T.widget_id,T.vega_json,T.compression_level,T.nonce,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new S3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("render_vega",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("render_vega",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_result_row_for_pixel(w,g,h){const T=new Sx;T.read(g),g.readMessageEnd(),this._handler.get_result_row_for_pixel.length===7?Promise.resolve(this._handler.get_result_row_for_pixel.bind(this._handler)(T.session,T.widget_id,T.pixel,T.table_col_names,T.column_format,T.pixelRadius,T.nonce)).then(_=>{const v=new x3({success:_});h.writeMessageBegin("get_result_row_for_pixel",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new x3(_),h.writeMessageBegin("get_result_row_for_pixel",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_result_row_for_pixel",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_result_row_for_pixel(T.session,T.widget_id,T.pixel,T.table_col_names,T.column_format,T.pixelRadius,T.nonce,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new x3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_result_row_for_pixel",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_result_row_for_pixel",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_create_custom_expression(w,g,h){const T=new xx;T.read(g),g.readMessageEnd(),this._handler.create_custom_expression.length===2?Promise.resolve(this._handler.create_custom_expression.bind(this._handler)(T.session,T.custom_expression)).then(_=>{const v=new k3({success:_});h.writeMessageBegin("create_custom_expression",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new k3(_),h.writeMessageBegin("create_custom_expression",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_custom_expression",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.create_custom_expression(T.session,T.custom_expression,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new k3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("create_custom_expression",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_custom_expression",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_custom_expressions(w,g,h){const T=new kx;T.read(g),g.readMessageEnd(),this._handler.get_custom_expressions.length===1?Promise.resolve(this._handler.get_custom_expressions.bind(this._handler)(T.session)).then(_=>{const v=new B3({success:_});h.writeMessageBegin("get_custom_expressions",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new B3(_),h.writeMessageBegin("get_custom_expressions",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_custom_expressions",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_custom_expressions(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new B3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_custom_expressions",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_custom_expressions",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_update_custom_expression(w,g,h){const T=new Bx;T.read(g),g.readMessageEnd(),this._handler.update_custom_expression.length===3?Promise.resolve(this._handler.update_custom_expression.bind(this._handler)(T.session,T.id,T.expression_json)).then(_=>{const v=new F3({success:_});h.writeMessageBegin("update_custom_expression",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new F3(_),h.writeMessageBegin("update_custom_expression",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("update_custom_expression",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.update_custom_expression(T.session,T.id,T.expression_json,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new F3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("update_custom_expression",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("update_custom_expression",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_delete_custom_expressions(w,g,h){const T=new Fx;T.read(g),g.readMessageEnd(),this._handler.delete_custom_expressions.length===3?Promise.resolve(this._handler.delete_custom_expressions.bind(this._handler)(T.session,T.custom_expression_ids,T.do_soft_delete)).then(_=>{const v=new I3({success:_});h.writeMessageBegin("delete_custom_expressions",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new I3(_),h.writeMessageBegin("delete_custom_expressions",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_custom_expressions",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.delete_custom_expressions(T.session,T.custom_expression_ids,T.do_soft_delete,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new I3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("delete_custom_expressions",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_custom_expressions",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_dashboard(w,g,h){const T=new Ix;T.read(g),g.readMessageEnd(),this._handler.get_dashboard.length===2?Promise.resolve(this._handler.get_dashboard.bind(this._handler)(T.session,T.dashboard_id)).then(_=>{const v=new O3({success:_});h.writeMessageBegin("get_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new O3(_),h.writeMessageBegin("get_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_dashboard(T.session,T.dashboard_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new O3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_dashboards(w,g,h){const T=new Ox;T.read(g),g.readMessageEnd(),this._handler.get_dashboards.length===1?Promise.resolve(this._handler.get_dashboards.bind(this._handler)(T.session)).then(_=>{const v=new M3({success:_});h.writeMessageBegin("get_dashboards",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new M3(_),h.writeMessageBegin("get_dashboards",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboards",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_dashboards(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new M3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_dashboards",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboards",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_create_dashboard(w,g,h){const T=new Mx;T.read(g),g.readMessageEnd(),this._handler.create_dashboard.length===5?Promise.resolve(this._handler.create_dashboard.bind(this._handler)(T.session,T.dashboard_name,T.dashboard_state,T.image_hash,T.dashboard_metadata)).then(_=>{const v=new A3({success:_});h.writeMessageBegin("create_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new A3(_),h.writeMessageBegin("create_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.create_dashboard(T.session,T.dashboard_name,T.dashboard_state,T.image_hash,T.dashboard_metadata,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new A3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("create_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_replace_dashboard(w,g,h){const T=new Ax;T.read(g),g.readMessageEnd(),this._handler.replace_dashboard.length===7?Promise.resolve(this._handler.replace_dashboard.bind(this._handler)(T.session,T.dashboard_id,T.dashboard_name,T.dashboard_owner,T.dashboard_state,T.image_hash,T.dashboard_metadata)).then(_=>{const v=new N3({success:_});h.writeMessageBegin("replace_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new N3(_),h.writeMessageBegin("replace_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("replace_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.replace_dashboard(T.session,T.dashboard_id,T.dashboard_name,T.dashboard_owner,T.dashboard_state,T.image_hash,T.dashboard_metadata,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new N3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("replace_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("replace_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_delete_dashboard(w,g,h){const T=new Nx;T.read(g),g.readMessageEnd(),this._handler.delete_dashboard.length===2?Promise.resolve(this._handler.delete_dashboard.bind(this._handler)(T.session,T.dashboard_id)).then(_=>{const v=new C3({success:_});h.writeMessageBegin("delete_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new C3(_),h.writeMessageBegin("delete_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.delete_dashboard(T.session,T.dashboard_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new C3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("delete_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_share_dashboards(w,g,h){const T=new Cx;T.read(g),g.readMessageEnd(),this._handler.share_dashboards.length===4?Promise.resolve(this._handler.share_dashboards.bind(this._handler)(T.session,T.dashboard_ids,T.groups,T.permissions)).then(_=>{const v=new R3({success:_});h.writeMessageBegin("share_dashboards",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new R3(_),h.writeMessageBegin("share_dashboards",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("share_dashboards",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.share_dashboards(T.session,T.dashboard_ids,T.groups,T.permissions,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new R3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("share_dashboards",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("share_dashboards",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_delete_dashboards(w,g,h){const T=new Rx;T.read(g),g.readMessageEnd(),this._handler.delete_dashboards.length===2?Promise.resolve(this._handler.delete_dashboards.bind(this._handler)(T.session,T.dashboard_ids)).then(_=>{const v=new P3({success:_});h.writeMessageBegin("delete_dashboards",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new P3(_),h.writeMessageBegin("delete_dashboards",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_dashboards",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.delete_dashboards(T.session,T.dashboard_ids,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new P3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("delete_dashboards",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("delete_dashboards",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_share_dashboard(w,g,h){const T=new Px;T.read(g),g.readMessageEnd(),this._handler.share_dashboard.length===6?Promise.resolve(this._handler.share_dashboard.bind(this._handler)(T.session,T.dashboard_id,T.groups,T.objects,T.permissions,T.grant_role)).then(_=>{const v=new D3({success:_});h.writeMessageBegin("share_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new D3(_),h.writeMessageBegin("share_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("share_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.share_dashboard(T.session,T.dashboard_id,T.groups,T.objects,T.permissions,T.grant_role,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new D3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("share_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("share_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_unshare_dashboard(w,g,h){const T=new Dx;T.read(g),g.readMessageEnd(),this._handler.unshare_dashboard.length===5?Promise.resolve(this._handler.unshare_dashboard.bind(this._handler)(T.session,T.dashboard_id,T.groups,T.objects,T.permissions)).then(_=>{const v=new j3({success:_});h.writeMessageBegin("unshare_dashboard",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new j3(_),h.writeMessageBegin("unshare_dashboard",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("unshare_dashboard",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.unshare_dashboard(T.session,T.dashboard_id,T.groups,T.objects,T.permissions,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new j3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("unshare_dashboard",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("unshare_dashboard",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_unshare_dashboards(w,g,h){const T=new jx;T.read(g),g.readMessageEnd(),this._handler.unshare_dashboards.length===4?Promise.resolve(this._handler.unshare_dashboards.bind(this._handler)(T.session,T.dashboard_ids,T.groups,T.permissions)).then(_=>{const v=new U3({success:_});h.writeMessageBegin("unshare_dashboards",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new U3(_),h.writeMessageBegin("unshare_dashboards",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("unshare_dashboards",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.unshare_dashboards(T.session,T.dashboard_ids,T.groups,T.permissions,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new U3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("unshare_dashboards",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("unshare_dashboards",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_dashboard_grantees(w,g,h){const T=new Ux;T.read(g),g.readMessageEnd(),this._handler.get_dashboard_grantees.length===2?Promise.resolve(this._handler.get_dashboard_grantees.bind(this._handler)(T.session,T.dashboard_id)).then(_=>{const v=new H3({success:_});h.writeMessageBegin("get_dashboard_grantees",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new H3(_),h.writeMessageBegin("get_dashboard_grantees",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboard_grantees",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_dashboard_grantees(T.session,T.dashboard_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new H3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_dashboard_grantees",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_dashboard_grantees",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_link_view(w,g,h){const T=new Hx;T.read(g),g.readMessageEnd(),this._handler.get_link_view.length===2?Promise.resolve(this._handler.get_link_view.bind(this._handler)(T.session,T.link)).then(_=>{const v=new z3({success:_});h.writeMessageBegin("get_link_view",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new z3(_),h.writeMessageBegin("get_link_view",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_link_view",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_link_view(T.session,T.link,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new z3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_link_view",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_link_view",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_create_link(w,g,h){const T=new zx;T.read(g),g.readMessageEnd(),this._handler.create_link.length===3?Promise.resolve(this._handler.create_link.bind(this._handler)(T.session,T.view_state,T.view_metadata)).then(_=>{const v=new $3({success:_});h.writeMessageBegin("create_link",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new $3(_),h.writeMessageBegin("create_link",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_link",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.create_link(T.session,T.view_state,T.view_metadata,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new $3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("create_link",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_link",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_load_table_binary(w,g,h){const T=new $x;T.read(g),g.readMessageEnd(),this._handler.load_table_binary.length===4?Promise.resolve(this._handler.load_table_binary.bind(this._handler)(T.session,T.table_name,T.rows,T.column_names)).then(_=>{const v=new q3({success:_});h.writeMessageBegin("load_table_binary",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new q3(_),h.writeMessageBegin("load_table_binary",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.load_table_binary(T.session,T.table_name,T.rows,T.column_names,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new q3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("load_table_binary",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_load_table_binary_columnar(w,g,h){const T=new qx;T.read(g),g.readMessageEnd(),this._handler.load_table_binary_columnar.length===4?Promise.resolve(this._handler.load_table_binary_columnar.bind(this._handler)(T.session,T.table_name,T.cols,T.column_names)).then(_=>{const v=new V3({success:_});h.writeMessageBegin("load_table_binary_columnar",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new V3(_),h.writeMessageBegin("load_table_binary_columnar",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_columnar",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.load_table_binary_columnar(T.session,T.table_name,T.cols,T.column_names,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new V3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("load_table_binary_columnar",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_columnar",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_load_table_binary_columnar_polys(w,g,h){const T=new Vx;T.read(g),g.readMessageEnd(),this._handler.load_table_binary_columnar_polys.length===5?Promise.resolve(this._handler.load_table_binary_columnar_polys.bind(this._handler)(T.session,T.table_name,T.cols,T.column_names,T.assign_render_groups)).then(_=>{const v=new G3({success:_});h.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new G3(_),h.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.load_table_binary_columnar_polys(T.session,T.table_name,T.cols,T.column_names,T.assign_render_groups,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new G3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_columnar_polys",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_load_table_binary_arrow(w,g,h){const T=new Gx;T.read(g),g.readMessageEnd(),this._handler.load_table_binary_arrow.length===4?Promise.resolve(this._handler.load_table_binary_arrow.bind(this._handler)(T.session,T.table_name,T.arrow_stream,T.use_column_names)).then(_=>{const v=new W3({success:_});h.writeMessageBegin("load_table_binary_arrow",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new W3(_),h.writeMessageBegin("load_table_binary_arrow",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_arrow",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.load_table_binary_arrow(T.session,T.table_name,T.arrow_stream,T.use_column_names,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new W3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("load_table_binary_arrow",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table_binary_arrow",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_load_table(w,g,h){const T=new Wx;T.read(g),g.readMessageEnd(),this._handler.load_table.length===4?Promise.resolve(this._handler.load_table.bind(this._handler)(T.session,T.table_name,T.rows,T.column_names)).then(_=>{const v=new Y3({success:_});h.writeMessageBegin("load_table",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Y3(_),h.writeMessageBegin("load_table",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.load_table(T.session,T.table_name,T.rows,T.column_names,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Y3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("load_table",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("load_table",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_detect_column_types(w,g,h){const T=new Yx;T.read(g),g.readMessageEnd(),this._handler.detect_column_types.length===3?Promise.resolve(this._handler.detect_column_types.bind(this._handler)(T.session,T.file_name,T.copy_params)).then(_=>{const v=new X3({success:_});h.writeMessageBegin("detect_column_types",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new X3(_),h.writeMessageBegin("detect_column_types",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("detect_column_types",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.detect_column_types(T.session,T.file_name,T.copy_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new X3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("detect_column_types",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("detect_column_types",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_create_table(w,g,h){const T=new Xx;T.read(g),g.readMessageEnd(),this._handler.create_table.length===4?Promise.resolve(this._handler.create_table.bind(this._handler)(T.session,T.table_name,T.row_desc,T.create_params)).then(_=>{const v=new K3({success:_});h.writeMessageBegin("create_table",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new K3(_),h.writeMessageBegin("create_table",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_table",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.create_table(T.session,T.table_name,T.row_desc,T.create_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new K3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("create_table",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("create_table",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_import_table(w,g,h){const T=new Kx;T.read(g),g.readMessageEnd(),this._handler.import_table.length===4?Promise.resolve(this._handler.import_table.bind(this._handler)(T.session,T.table_name,T.file_name,T.copy_params)).then(_=>{const v=new Z3({success:_});h.writeMessageBegin("import_table",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Z3(_),h.writeMessageBegin("import_table",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_table",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.import_table(T.session,T.table_name,T.file_name,T.copy_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Z3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("import_table",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_table",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_import_geo_table(w,g,h){const T=new Zx;T.read(g),g.readMessageEnd(),this._handler.import_geo_table.length===6?Promise.resolve(this._handler.import_geo_table.bind(this._handler)(T.session,T.table_name,T.file_name,T.copy_params,T.row_desc,T.create_params)).then(_=>{const v=new J3({success:_});h.writeMessageBegin("import_geo_table",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new J3(_),h.writeMessageBegin("import_geo_table",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_geo_table",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.import_geo_table(T.session,T.table_name,T.file_name,T.copy_params,T.row_desc,T.create_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new J3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("import_geo_table",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_geo_table",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_import_table_status(w,g,h){const T=new Jx;T.read(g),g.readMessageEnd(),this._handler.import_table_status.length===2?Promise.resolve(this._handler.import_table_status.bind(this._handler)(T.session,T.import_id)).then(_=>{const v=new Q3({success:_});h.writeMessageBegin("import_table_status",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Q3(_),h.writeMessageBegin("import_table_status",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_table_status",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.import_table_status(T.session,T.import_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Q3(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("import_table_status",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("import_table_status",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_first_geo_file_in_archive(w,g,h){const T=new Qx;T.read(g),g.readMessageEnd(),this._handler.get_first_geo_file_in_archive.length===3?Promise.resolve(this._handler.get_first_geo_file_in_archive.bind(this._handler)(T.session,T.archive_path,T.copy_params)).then(_=>{const v=new eg({success:_});h.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new eg(_),h.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_first_geo_file_in_archive(T.session,T.archive_path,T.copy_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new eg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_first_geo_file_in_archive",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_all_files_in_archive(w,g,h){const T=new ek;T.read(g),g.readMessageEnd(),this._handler.get_all_files_in_archive.length===3?Promise.resolve(this._handler.get_all_files_in_archive.bind(this._handler)(T.session,T.archive_path,T.copy_params)).then(_=>{const v=new tg({success:_});h.writeMessageBegin("get_all_files_in_archive",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new tg(_),h.writeMessageBegin("get_all_files_in_archive",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_files_in_archive",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_all_files_in_archive(T.session,T.archive_path,T.copy_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new tg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_all_files_in_archive",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_files_in_archive",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_layers_in_geo_file(w,g,h){const T=new tk;T.read(g),g.readMessageEnd(),this._handler.get_layers_in_geo_file.length===3?Promise.resolve(this._handler.get_layers_in_geo_file.bind(this._handler)(T.session,T.file_name,T.copy_params)).then(_=>{const v=new ng({success:_});h.writeMessageBegin("get_layers_in_geo_file",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ng(_),h.writeMessageBegin("get_layers_in_geo_file",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_layers_in_geo_file",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_layers_in_geo_file(T.session,T.file_name,T.copy_params,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ng(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_layers_in_geo_file",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_layers_in_geo_file",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_query_get_outer_fragment_count(w,g,h){const T=new nk;T.read(g),g.readMessageEnd(),this._handler.query_get_outer_fragment_count.length===2?Promise.resolve(this._handler.query_get_outer_fragment_count.bind(this._handler)(T.session,T.query)).then(_=>{const v=new ig({success:_});h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ig(_),h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.query_get_outer_fragment_count(T.session,T.query,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ig(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("query_get_outer_fragment_count",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_check_table_consistency(w,g,h){const T=new ik;T.read(g),g.readMessageEnd(),this._handler.check_table_consistency.length===2?Promise.resolve(this._handler.check_table_consistency.bind(this._handler)(T.session,T.table_id)).then(_=>{const v=new sg({success:_});h.writeMessageBegin("check_table_consistency",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new sg(_),h.writeMessageBegin("check_table_consistency",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("check_table_consistency",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.check_table_consistency(T.session,T.table_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new sg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("check_table_consistency",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("check_table_consistency",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_start_query(w,g,h){const T=new sk;T.read(g),g.readMessageEnd(),this._handler.start_query.length===6?Promise.resolve(this._handler.start_query.bind(this._handler)(T.leaf_session,T.parent_session,T.query_ra,T.start_time_str,T.just_explain,T.outer_fragment_indices)).then(_=>{const v=new rg({success:_});h.writeMessageBegin("start_query",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new rg(_),h.writeMessageBegin("start_query",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_query",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.start_query(T.leaf_session,T.parent_session,T.query_ra,T.start_time_str,T.just_explain,T.outer_fragment_indices,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new rg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("start_query",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_query",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_execute_query_step(w,g,h){const T=new rk;T.read(g),g.readMessageEnd(),this._handler.execute_query_step.length===3?Promise.resolve(this._handler.execute_query_step.bind(this._handler)(T.pending_query,T.subquery_id,T.start_time_str)).then(_=>{const v=new ag({success:_});h.writeMessageBegin("execute_query_step",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ag(_),h.writeMessageBegin("execute_query_step",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("execute_query_step",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.execute_query_step(T.pending_query,T.subquery_id,T.start_time_str,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ag(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("execute_query_step",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("execute_query_step",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_broadcast_serialized_rows(w,g,h){const T=new ak;T.read(g),g.readMessageEnd(),this._handler.broadcast_serialized_rows.length===5?Promise.resolve(this._handler.broadcast_serialized_rows.bind(this._handler)(T.serialized_rows,T.row_desc,T.query_id,T.subquery_id,T.is_final_subquery_result)).then(_=>{const v=new og({success:_});h.writeMessageBegin("broadcast_serialized_rows",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new og(_),h.writeMessageBegin("broadcast_serialized_rows",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("broadcast_serialized_rows",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.broadcast_serialized_rows(T.serialized_rows,T.row_desc,T.query_id,T.subquery_id,T.is_final_subquery_result,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new og(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("broadcast_serialized_rows",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("broadcast_serialized_rows",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_start_render_query(w,g,h){const T=new ok;T.read(g),g.readMessageEnd(),this._handler.start_render_query.length===4?Promise.resolve(this._handler.start_render_query.bind(this._handler)(T.session,T.widget_id,T.node_idx,T.vega_json)).then(_=>{const v=new lg({success:_});h.writeMessageBegin("start_render_query",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new lg(_),h.writeMessageBegin("start_render_query",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_render_query",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.start_render_query(T.session,T.widget_id,T.node_idx,T.vega_json,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new lg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("start_render_query",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("start_render_query",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_execute_next_render_step(w,g,h){const T=new lk;T.read(g),g.readMessageEnd(),this._handler.execute_next_render_step.length===2?Promise.resolve(this._handler.execute_next_render_step.bind(this._handler)(T.pending_render,T.merged_data)).then(_=>{const v=new cg({success:_});h.writeMessageBegin("execute_next_render_step",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new cg(_),h.writeMessageBegin("execute_next_render_step",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("execute_next_render_step",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.execute_next_render_step(T.pending_render,T.merged_data,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new cg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("execute_next_render_step",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("execute_next_render_step",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_insert_data(w,g,h){const T=new ck;T.read(g),g.readMessageEnd(),this._handler.insert_data.length===2?Promise.resolve(this._handler.insert_data.bind(this._handler)(T.session,T.insert_data)).then(_=>{const v=new dg({success:_});h.writeMessageBegin("insert_data",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new dg(_),h.writeMessageBegin("insert_data",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("insert_data",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.insert_data(T.session,T.insert_data,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new dg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("insert_data",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("insert_data",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_insert_chunks(w,g,h){const T=new dk;T.read(g),g.readMessageEnd(),this._handler.insert_chunks.length===2?Promise.resolve(this._handler.insert_chunks.bind(this._handler)(T.session,T.insert_chunks)).then(_=>{const v=new fg({success:_});h.writeMessageBegin("insert_chunks",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new fg(_),h.writeMessageBegin("insert_chunks",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("insert_chunks",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.insert_chunks(T.session,T.insert_chunks,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new fg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("insert_chunks",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("insert_chunks",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_checkpoint(w,g,h){const T=new fk;T.read(g),g.readMessageEnd(),this._handler.checkpoint.length===2?Promise.resolve(this._handler.checkpoint.bind(this._handler)(T.session,T.table_id)).then(_=>{const v=new ug({success:_});h.writeMessageBegin("checkpoint",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new ug(_),h.writeMessageBegin("checkpoint",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("checkpoint",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.checkpoint(T.session,T.table_id,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new ug(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("checkpoint",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("checkpoint",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_roles(w,g,h){const T=new uk;T.read(g),g.readMessageEnd(),this._handler.get_roles.length===1?Promise.resolve(this._handler.get_roles.bind(this._handler)(T.session)).then(_=>{const v=new hg({success:_});h.writeMessageBegin("get_roles",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new hg(_),h.writeMessageBegin("get_roles",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_roles",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_roles(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new hg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_roles",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_roles",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_db_objects_for_grantee(w,g,h){const T=new hk;T.read(g),g.readMessageEnd(),this._handler.get_db_objects_for_grantee.length===2?Promise.resolve(this._handler.get_db_objects_for_grantee.bind(this._handler)(T.session,T.roleName)).then(_=>{const v=new gg({success:_});h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new gg(_),h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_db_objects_for_grantee(T.session,T.roleName,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new gg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_db_objects_for_grantee",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_db_object_privs(w,g,h){const T=new gk;T.read(g),g.readMessageEnd(),this._handler.get_db_object_privs.length===3?Promise.resolve(this._handler.get_db_object_privs.bind(this._handler)(T.session,T.objectName,T.type)).then(_=>{const v=new _g({success:_});h.writeMessageBegin("get_db_object_privs",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new _g(_),h.writeMessageBegin("get_db_object_privs",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_db_object_privs",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_db_object_privs(T.session,T.objectName,T.type,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new _g(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_db_object_privs",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_db_object_privs",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_all_roles_for_user(w,g,h){const T=new _k;T.read(g),g.readMessageEnd(),this._handler.get_all_roles_for_user.length===2?Promise.resolve(this._handler.get_all_roles_for_user.bind(this._handler)(T.session,T.userName)).then(_=>{const v=new pg({success:_});h.writeMessageBegin("get_all_roles_for_user",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new pg(_),h.writeMessageBegin("get_all_roles_for_user",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_roles_for_user",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_all_roles_for_user(T.session,T.userName,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new pg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_all_roles_for_user",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_roles_for_user",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_all_effective_roles_for_user(w,g,h){const T=new pk;T.read(g),g.readMessageEnd(),this._handler.get_all_effective_roles_for_user.length===2?Promise.resolve(this._handler.get_all_effective_roles_for_user.bind(this._handler)(T.session,T.userName)).then(_=>{const v=new yg({success:_});h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new yg(_),h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_all_effective_roles_for_user(T.session,T.userName,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new yg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_all_effective_roles_for_user",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_has_role(w,g,h){const T=new yk;T.read(g),g.readMessageEnd(),this._handler.has_role.length===3?Promise.resolve(this._handler.has_role.bind(this._handler)(T.session,T.granteeName,T.roleName)).then(_=>{const v=new mg({success:_});h.writeMessageBegin("has_role",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new mg(_),h.writeMessageBegin("has_role",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("has_role",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.has_role(T.session,T.granteeName,T.roleName,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new mg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("has_role",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("has_role",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_has_object_privilege(w,g,h){const T=new mk;T.read(g),g.readMessageEnd(),this._handler.has_object_privilege.length===5?Promise.resolve(this._handler.has_object_privilege.bind(this._handler)(T.session,T.granteeName,T.ObjectName,T.objectType,T.permissions)).then(_=>{const v=new wg({success:_});h.writeMessageBegin("has_object_privilege",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new wg(_),h.writeMessageBegin("has_object_privilege",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("has_object_privilege",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.has_object_privilege(T.session,T.granteeName,T.ObjectName,T.objectType,T.permissions,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new wg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("has_object_privilege",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("has_object_privilege",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_set_license_key(w,g,h){const T=new wk;T.read(g),g.readMessageEnd(),this._handler.set_license_key.length===3?Promise.resolve(this._handler.set_license_key.bind(this._handler)(T.session,T.key,T.nonce)).then(_=>{const v=new Lg({success:_});h.writeMessageBegin("set_license_key",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Lg(_),h.writeMessageBegin("set_license_key",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_license_key",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.set_license_key(T.session,T.key,T.nonce,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Lg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("set_license_key",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("set_license_key",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_license_claims(w,g,h){const T=new Lk;T.read(g),g.readMessageEnd(),this._handler.get_license_claims.length===2?Promise.resolve(this._handler.get_license_claims.bind(this._handler)(T.session,T.nonce)).then(_=>{const v=new bg({success:_});h.writeMessageBegin("get_license_claims",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new bg(_),h.writeMessageBegin("get_license_claims",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_license_claims",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_license_claims(T.session,T.nonce,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new bg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_license_claims",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_license_claims",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_device_parameters(w,g,h){const T=new bk;T.read(g),g.readMessageEnd(),this._handler.get_device_parameters.length===1?Promise.resolve(this._handler.get_device_parameters.bind(this._handler)(T.session)).then(_=>{const v=new Tg({success:_});h.writeMessageBegin("get_device_parameters",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Tg(_),h.writeMessageBegin("get_device_parameters",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_device_parameters",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_device_parameters(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Tg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_device_parameters",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_device_parameters",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_register_runtime_extension_functions(w,g,h){const T=new Tk;T.read(g),g.readMessageEnd(),this._handler.register_runtime_extension_functions.length===4?Promise.resolve(this._handler.register_runtime_extension_functions.bind(this._handler)(T.session,T.udfs,T.udtfs,T.device_ir_map)).then(_=>{const v=new vg({success:_});h.writeMessageBegin("register_runtime_extension_functions",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new vg(_),h.writeMessageBegin("register_runtime_extension_functions",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("register_runtime_extension_functions",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.register_runtime_extension_functions(T.session,T.udfs,T.udtfs,T.device_ir_map,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new vg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("register_runtime_extension_functions",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("register_runtime_extension_functions",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_function_names(w,g,h){const T=new vk;T.read(g),g.readMessageEnd(),this._handler.get_table_function_names.length===1?Promise.resolve(this._handler.get_table_function_names.bind(this._handler)(T.session)).then(_=>{const v=new Eg({success:_});h.writeMessageBegin("get_table_function_names",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Eg(_),h.writeMessageBegin("get_table_function_names",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_function_names",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_function_names(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Eg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_function_names",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_function_names",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_runtime_table_function_names(w,g,h){const T=new Ek;T.read(g),g.readMessageEnd(),this._handler.get_runtime_table_function_names.length===1?Promise.resolve(this._handler.get_runtime_table_function_names.bind(this._handler)(T.session)).then(_=>{const v=new Sg({success:_});h.writeMessageBegin("get_runtime_table_function_names",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new Sg(_),h.writeMessageBegin("get_runtime_table_function_names",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_runtime_table_function_names",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_runtime_table_function_names(T.session,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new Sg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_runtime_table_function_names",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_runtime_table_function_names",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}process_get_table_function_details(w,g,h){const T=new Sk;T.read(g),g.readMessageEnd(),this._handler.get_table_function_details.length===2?Promise.resolve(this._handler.get_table_function_details.bind(this._handler)(T.session,T.udtf_names)).then(_=>{const v=new xg({success:_});h.writeMessageBegin("get_table_function_details",a.MessageType.REPLY,w),v.write(h),h.writeMessageEnd(),h.flush()}).catch(_=>{let v;_ instanceof l.TDBException?(v=new xg(_),h.writeMessageBegin("get_table_function_details",a.MessageType.REPLY,w)):(v=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_function_details",a.MessageType.EXCEPTION,w)),v.write(h),h.writeMessageEnd(),h.flush()}):this._handler.get_table_function_details(T.session,T.udtf_names,(_,v)=>{let B;_===null||typeof _>"u"||_ instanceof l.TDBException?(B=new xg(_!==null||typeof _>"u"?_:{success:v}),h.writeMessageBegin("get_table_function_details",a.MessageType.REPLY,w)):(B=new a.TApplicationException(a.TApplicationExceptionType.UNKNOWN,_.message),h.writeMessageBegin("get_table_function_details",a.MessageType.EXCEPTION,w)),B.write(h),h.writeMessageEnd(),h.flush()})}}},2818:(c,d,f)=>{const a=f(9262).Thrift;f(135);const m=c.exports={};m.TDeviceType={CPU:0,GPU:1},m.TDatumType={SMALLINT:0,INT:1,BIGINT:2,FLOAT:3,DECIMAL:4,DOUBLE:5,STR:6,TIME:7,TIMESTAMP:8,DATE:9,BOOL:10,INTERVAL_DAY_TIME:11,INTERVAL_YEAR_MONTH:12,POINT:13,LINESTRING:14,POLYGON:15,MULTIPOLYGON:16,TINYINT:17,GEOMETRY:18,GEOGRAPHY:19},m.TEncodingType={NONE:0,FIXED:1,RL:2,DIFF:3,DICT:4,SPARSE:5,GEOINT:6,DATE_IN_DAYS:7},c.exports.TTypeInfo=class{constructor(y){this.type=null,this.encoding=null,this.nullable=null,this.is_array=null,this.precision=null,this.scale=null,this.comp_param=null,this.size=-1,y&&(y.type!==void 0&&y.type!==null&&(this.type=y.type),y.encoding!==void 0&&y.encoding!==null&&(this.encoding=y.encoding),y.nullable!==void 0&&y.nullable!==null&&(this.nullable=y.nullable),y.is_array!==void 0&&y.is_array!==null&&(this.is_array=y.is_array),y.precision!==void 0&&y.precision!==null&&(this.precision=y.precision),y.scale!==void 0&&y.scale!==null&&(this.scale=y.scale),y.comp_param!==void 0&&y.comp_param!==null&&(this.comp_param=y.comp_param),y.size!==void 0&&y.size!==null&&(this.size=y.size))}read(y){for(y.readStructBegin();;){const p=y.readFieldBegin(),l=p.ftype,b=p.fid;if(l==a.Type.STOP)break;switch(b){case 1:l==a.Type.I32?this.type=y.readI32():y.skip(l);break;case 4:l==a.Type.I32?this.encoding=y.readI32():y.skip(l);break;case 2:l==a.Type.BOOL?this.nullable=y.readBool():y.skip(l);break;case 3:l==a.Type.BOOL?this.is_array=y.readBool():y.skip(l);break;case 5:l==a.Type.I32?this.precision=y.readI32():y.skip(l);break;case 6:l==a.Type.I32?this.scale=y.readI32():y.skip(l);break;case 7:l==a.Type.I32?this.comp_param=y.readI32():y.skip(l);break;case 8:l==a.Type.I32?this.size=y.readI32():y.skip(l);break;default:y.skip(l)}y.readFieldEnd()}y.readStructEnd()}write(y){y.writeStructBegin("TTypeInfo"),this.type!==null&&this.type!==void 0&&(y.writeFieldBegin("type",a.Type.I32,1),y.writeI32(this.type),y.writeFieldEnd()),this.encoding!==null&&this.encoding!==void 0&&(y.writeFieldBegin("encoding",a.Type.I32,4),y.writeI32(this.encoding),y.writeFieldEnd()),this.nullable!==null&&this.nullable!==void 0&&(y.writeFieldBegin("nullable",a.Type.BOOL,2),y.writeBool(this.nullable),y.writeFieldEnd()),this.is_array!==null&&this.is_array!==void 0&&(y.writeFieldBegin("is_array",a.Type.BOOL,3),y.writeBool(this.is_array),y.writeFieldEnd()),this.precision!==null&&this.precision!==void 0&&(y.writeFieldBegin("precision",a.Type.I32,5),y.writeI32(this.precision),y.writeFieldEnd()),this.scale!==null&&this.scale!==void 0&&(y.writeFieldBegin("scale",a.Type.I32,6),y.writeI32(this.scale),y.writeFieldEnd()),this.comp_param!==null&&this.comp_param!==void 0&&(y.writeFieldBegin("comp_param",a.Type.I32,7),y.writeI32(this.comp_param),y.writeFieldEnd()),this.size!==null&&this.size!==void 0&&(y.writeFieldBegin("size",a.Type.I32,8),y.writeI32(this.size),y.writeFieldEnd()),y.writeFieldStop(),y.writeStructEnd()}}},4494:(c,d,f)=>{const a=f(9262).Thrift;f(135);const m=c.exports={};m.TCompletionHintType={COLUMN:0,TABLE:1,VIEW:2,SCHEMA:3,CATALOG:4,REPOSITORY:5,FUNCTION:6,KEYWORD:7},c.exports.TCompletionHint=class{constructor(y){this.type=null,this.hints=null,this.replaced=null,y&&(y.type!==void 0&&y.type!==null&&(this.type=y.type),y.hints!==void 0&&y.hints!==null&&(this.hints=a.copyList(y.hints,[null])),y.replaced!==void 0&&y.replaced!==null&&(this.replaced=y.replaced))}read(y){for(y.readStructBegin();;){const p=y.readFieldBegin(),l=p.ftype,b=p.fid;if(l==a.Type.STOP)break;switch(b){case 1:l==a.Type.I32?this.type=y.readI32():y.skip(l);break;case 2:if(l==a.Type.LIST){this.hints=[];const E=y.readListBegin().size||0;for(let S=0;S{const a=f(9262).Thrift;f(135);const m=c.exports={};m.TExtArgumentType={Int8:0,Int16:1,Int32:2,Int64:3,Float:4,Double:5,Void:6,PInt8:7,PInt16:8,PInt32:9,PInt64:10,PFloat:11,PDouble:12,PBool:13,Bool:14,ArrayInt8:15,ArrayInt16:16,ArrayInt32:17,ArrayInt64:18,ArrayFloat:19,ArrayDouble:20,ArrayBool:21,GeoPoint:22,GeoLineString:23,Cursor:24,GeoPolygon:25,GeoMultiPolygon:26,ColumnInt8:27,ColumnInt16:28,ColumnInt32:29,ColumnInt64:30,ColumnFloat:31,ColumnDouble:32,ColumnBool:33,TextEncodingNone:34,TextEncodingDict:35,ColumnListInt8:36,ColumnListInt16:37,ColumnListInt32:38,ColumnListInt64:39,ColumnListFloat:40,ColumnListDouble:41,ColumnListBool:42,ColumnTextEncodingDict:43,ColumnListTextEncodingDict:44,ColumnTimestamp:45,Timestamp:46},m.TOutputBufferSizeType={kConstant:0,kUserSpecifiedConstantParameter:1,kUserSpecifiedRowMultiplier:2,kTableFunctionSpecifiedParameter:3,kPreFlightParameter:4},c.exports.TUserDefinedFunction=class{constructor(y){this.name=null,this.argTypes=null,this.retType=null,y&&(y.name!==void 0&&y.name!==null&&(this.name=y.name),y.argTypes!==void 0&&y.argTypes!==null&&(this.argTypes=a.copyList(y.argTypes,[null])),y.retType!==void 0&&y.retType!==null&&(this.retType=y.retType))}read(y){for(y.readStructBegin();;){const p=y.readFieldBegin(),l=p.ftype,b=p.fid;if(l==a.Type.STOP)break;switch(b){case 1:l==a.Type.STRING?this.name=y.readString():y.skip(l);break;case 2:if(l==a.Type.LIST){this.argTypes=[];const E=y.readListBegin().size||0;for(let S=0;S{const a=f(9262).Thrift;f(135);const m=f(2818);f(4494);const y=f(3962);f(1396);const p=c.exports={};p.TExecuteMode={GPU:1,CPU:2},p.TSourceType={DELIMITED_FILE:0,GEO_FILE:1,PARQUET_FILE:2,RASTER_FILE:3,ODBC:4},p.TPartitionDetail={DEFAULT:0,REPLICATED:1,SHARDED:2,OTHER:3},p.TGeoFileLayerContents={EMPTY:0,GEO:1,NON_GEO:2,UNSUPPORTED_GEO:3},p.TImportHeaderRow={AUTODETECT:0,NO_HEADER:1,HAS_HEADER:2},p.TRole={SERVER:0,AGGREGATOR:1,LEAF:2,STRING_DICTIONARY:3},p.TTableType={DEFAULT:0,TEMPORARY:1,FOREIGN:2,VIEW:3},p.TTableRefreshUpdateType={ALL:0,APPEND:1},p.TTableRefreshTimingType={MANUAL:0,SCHEDULED:1},p.TTableRefreshIntervalType={NONE:0,HOUR:1,DAY:2},p.TMergeType={UNION:0,REDUCE:1},p.TRasterPointType={NONE:0,AUTO:1,SMALLINT:2,INT:3,FLOAT:4,DOUBLE:5,POINT:6},p.TRasterPointTransform={NONE:0,AUTO:1,FILE:2,WORLD:3},p.TQueryType={UNKNOWN:0,READ:1,WRITE:2,SCHEMA_READ:3,SCHEMA_WRITE:4},p.TArrowTransport={SHARED_MEMORY:0,WIRE:1},p.TExpressionRangeType={INVALID:0,INTEGER:1,FLOAT:2,DOUBLE:3},p.TDBObjectType={AbstractDBObjectType:0,DatabaseDBObjectType:1,TableDBObjectType:2,DashboardDBObjectType:3,ViewDBObjectType:4,ServerDBObjectType:5},p.TDataSourceType={TABLE:0},c.exports.TDatumVal=class{constructor(l){this.int_val=null,this.real_val=null,this.str_val=null,this.arr_val=null,l&&(l.int_val!==void 0&&l.int_val!==null&&(this.int_val=l.int_val),l.real_val!==void 0&&l.real_val!==null&&(this.real_val=l.real_val),l.str_val!==void 0&&l.str_val!==null&&(this.str_val=l.str_val),l.arr_val!==void 0&&l.arr_val!==null&&(this.arr_val=a.copyList(l.arr_val,[null])))}read(l){for(l.readStructBegin();;){const b=l.readFieldBegin(),L=b.ftype,E=b.fid;if(L==a.Type.STOP)break;switch(E){case 1:L==a.Type.I64?this.int_val=l.readI64():l.skip(L);break;case 2:L==a.Type.DOUBLE?this.real_val=l.readDouble():l.skip(L);break;case 3:L==a.Type.STRING?this.str_val=l.readString():l.skip(L);break;case 4:if(L==a.Type.LIST){this.arr_val=[];const x=l.readListBegin().size||0;for(let F=0;F{const a=f(9262).Thrift;f(135);const m=f(2818),y=c.exports={};y.TResultSetLayout={GroupByPerfectHash:0,GroupByBaselineHash:1,Projection:2,NonGroupedAggregate:3},y.TCountDistinctImplType={Invalid:0,Bitmap:1,UnorderedSet:2},y.TAggKind={AVG:0,MIN:1,MAX:2,SUM:3,COUNT:4,APPROX_COUNT_DISTINCT:5,SAMPLE:6,SINGLE_VALUE:7},c.exports.TSlotSize=class{constructor(p){this.padded=null,this.logical=null,p&&(p.padded!==void 0&&p.padded!==null&&(this.padded=p.padded),p.logical!==void 0&&p.logical!==null&&(this.logical=p.logical))}read(p){for(p.readStructBegin();;){const l=p.readFieldBegin(),b=l.ftype,L=l.fid;if(b==a.Type.STOP)break;switch(L){case 1:b==a.Type.I16?this.padded=p.readI16():p.skip(b);break;case 2:b==a.Type.I16?this.logical=p.readI16():p.skip(b);break;default:p.skip(b)}p.readFieldEnd()}p.readStructEnd()}write(p){p.writeStructBegin("TSlotSize"),this.padded!==null&&this.padded!==void 0&&(p.writeFieldBegin("padded",a.Type.I16,1),p.writeI16(this.padded),p.writeFieldEnd()),this.logical!==null&&this.logical!==void 0&&(p.writeFieldBegin("logical",a.Type.I16,2),p.writeI16(this.logical),p.writeFieldEnd()),p.writeFieldStop(),p.writeStructEnd()}},c.exports.TColSlotContext=class{constructor(p){this.slot_sizes=null,this.col_to_slot_map=null,p&&(p.slot_sizes!==void 0&&p.slot_sizes!==null&&(this.slot_sizes=a.copyList(p.slot_sizes,[y.TSlotSize])),p.col_to_slot_map!==void 0&&p.col_to_slot_map!==null&&(this.col_to_slot_map=a.copyList(p.col_to_slot_map,[a.copyList,null])))}read(p){for(p.readStructBegin();;){const l=p.readFieldBegin(),b=l.ftype,L=l.fid;if(b==a.Type.STOP)break;switch(L){case 1:if(b==a.Type.LIST){this.slot_sizes=[];const S=p.readListBegin().size||0;for(let x=0;x{c.exports=n}},s={};function o(c){if(s[c])return s[c].exports;var d=s[c]={exports:{}};return i[c](d,d.exports,o),d.exports}return o.n=c=>{var d=c&&c.__esModule?()=>c.default:()=>c;return o.d(d,{a:d}),d},o.d=(c,d)=>{for(var f in d)o.o(d,f)&&!o.o(c,f)&&Object.defineProperty(c,f,{enumerable:!0,get:d[f]})},o.g=function(){if(typeof globalThis=="object")return globalThis;try{return this||new Function("return this")()}catch{if(typeof window=="object")return window}}(),o.o=(c,d)=>Object.prototype.hasOwnProperty.call(c,d),o.r=c=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(c,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(c,"__esModule",{value:!0})},o(7123)})()})})(Wle);const Xle=mJ(FL);new Xle;class Kle{constructor(t){this.db=t,this.views=new qle,this.filters=new Map,this.index=new Map}async view0D(t){await this.assertDataExists();const n=new Tl(this);return this.views.add(n),t&&n.addOnChangeListener(t),n}async view1D(t,n){await this.assertDataExists(t);const i=new ca(this,t);return this.views.add(i),n&&i.addOnChangeListener(n),i}async entries({offset:t=0,length:n=1/0}={}){return this.db.entries(t,n,this.filters)}async all(){for(const t of this.views)await t.all()}async link(){const t=this.views.active;t?(await t.computeIndex(!0),await t.select(t.lastFilter,!0)):await this.all()}get passiveFilters(){const t=this.views.active;if(t instanceof Tl)throw Error("No filter for 0D view / count");if(t instanceof ca)return YF(this.filters,t.dimension);throw Error("2D view not implemented yet")}otherFilters(t){return YF(this.filters,t.dimension)}async assertDataExists(...t){if(!await this.db.tableExists())throw new Error("Table does not exists in the database");t==null||t.forEach(async i=>{if(i&&!await this.db.dimensionExists(i))throw new Error(`Dimension '${i.name}' does not exist in the data table`)})}}const Zle="/assets/github-mark-7a0dd11e.svg";function Jle(e){let t,n,i;return{c(){t=Tt("a"),n=Tt("img"),EY(n.src,i=Zle)||Ee(n,"src",i),Ee(n,"alt","github logo"),Ee(n,"width",e[1]),Ee(t,"href",e[0]),Ee(t,"target","_blank")},m(s,o){$t(s,t,o),Ve(t,n)},p(s,[o]){o&2&&Ee(n,"width",s[1]),o&1&&Ee(t,"href",s[0])},i:Yn,o:Yn,d(s){s&&Pt(t)}}}function Qle(e,t,n){let{href:i=""}=t,{width:s=25}=t;return e.$$set=o=>{"href"in o&&n(0,i=o.href),"width"in o&&n(1,s=o.width)},[i,s]}class ece extends Vi{constructor(t){super(),qi(this,t,Qle,Jle,$i,{href:0,width:1})}}function KF(e){let t,n,i,s,o,c,d,f,u,a;return{c(){t=Tt("div"),n=Tt("span"),i=Cr("["),s=Cr(e[1]),o=Cr("]"),c=Tt("span"),d=pn(),f=Tt("button"),f.textContent="Reset",Ee(f,"class","reset svelte-g3nrlw"),Ee(n,"class","selection svelte-g3nrlw")},m(m,y){$t(m,t,y),Ve(t,n),Ve(n,i),Ve(n,s),Ve(n,o),Ve(n,c),Ve(n,d),Ve(n,f),u||(a=Ri(f,"click",e[3]),u=!0)},p(m,y){y&2&&Lh(s,m[1])},d(m){m&&Pt(t),u=!1,a()}}}function tce(e){let t,n,i,s,o=e[1]&&KF(e);return{c(){t=Tt("div"),n=Tt("div"),i=Cr(e[0]),s=pn(),o&&o.c(),Ee(n,"class","title svelte-g3nrlw"),Ee(t,"class","top svelte-g3nrlw")},m(c,d){$t(c,t,d),Ve(t,n),Ve(n,i),Ve(t,s),o&&o.m(t,null)},p(c,[d]){d&1&&Lh(i,c[0]),c[1]?o?o.p(c,d):(o=KF(c),o.c(),o.m(t,null)):o&&(o.d(1),o=null)},i:Yn,o:Yn,d(c){c&&Pt(t),o&&o.d()}}}function nce(e,t,n){const i=sf();let{title:s=""}=t,{selection:o=null}=t;const c=async()=>{i("reset")};return e.$$set=d=>{"title"in d&&n(0,s=d.title),"selection"in d&&n(1,o=d.selection)},[s,o,i,c]}class Nb extends Vi{constructor(t){super(),qi(this,t,nce,tce,$i,{title:0,selection:1})}}/*! * https://github.com/Starcounter-Jack/JSON-Patch * (c) 2017-2022 Joachim Wester * MIT licensed */var ice=globalThis&&globalThis.__extends||function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,s){i.__proto__=s}||function(i,s){for(var o in s)s.hasOwnProperty(o)&&(i[o]=s[o])},e(t,n)};return function(t,n){e(t,n);function i(){this.constructor=t}t.prototype=n===null?Object.create(n):(i.prototype=n.prototype,new i)}}(),sce=Object.prototype.hasOwnProperty;function IL(e,t){return sce.call(e,t)}function OL(e){if(Array.isArray(e)){for(var t=new Array(e.length),n=0;n=48&&i<=57){t++;continue}return!1}return!0}function td(e){return e.indexOf("/")===-1&&e.indexOf("~")===-1?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}function Oj(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function AL(e){if(e===void 0)return!0;if(e){if(Array.isArray(e)){for(var t=0,n=e.length;t0&&f[a-1]=="constructor"))throw new TypeError("JSON-Patch: modifying `__proto__` or `constructor/prototype` prop is banned for security reasons, if this was on purpose, please set `banPrototypeModifications` flag false and pass it to this function. More info in fast-json-patch README");if(n&&y===void 0&&(u[p]===void 0?y=f.slice(0,a).join("/"):a==m-1&&(y=t.path),y!==void 0&&l(t,0,e,y)),a++,Array.isArray(u)){if(p==="-")p=u.length;else{if(n&&!ML(p))throw new _n("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",o,t,e);ML(p)&&(p=~~p)}if(a>=m){if(n&&t.op==="add"&&p>u.length)throw new _n("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",o,t,e);var c=ace[t.op].call(t,u,p,e);if(c.test===!1)throw new _n("Test operation failed","TEST_OPERATION_FAILED",o,t,e);return c}}else if(a>=m){var c=ru[t.op].call(t,u,p,e);if(c.test===!1)throw new _n("Test operation failed","TEST_OPERATION_FAILED",o,t,e);return c}if(u=u[p],n&&a0)throw new _n('Operation `path` property must start with "/"',"OPERATION_PATH_INVALID",t,e,n);if((e.op==="move"||e.op==="copy")&&typeof e.from!="string")throw new _n("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&e.value===void 0)throw new _n("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",t,e,n);if((e.op==="add"||e.op==="replace"||e.op==="test")&&AL(e.value))throw new _n("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",t,e,n);if(n){if(e.op=="add"){var s=e.path.split("/").length,o=i.split("/").length;if(s!==o+1&&s!==o)throw new _n("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",t,e,n)}else if(e.op==="replace"||e.op==="remove"||e.op==="_get"){if(e.path!==i)throw new _n("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",t,e,n)}else if(e.op==="move"||e.op==="copy"){var c={op:"_get",path:e.from,value:void 0},d=Aj([c],n);if(d&&d.name==="OPERATION_PATH_UNRESOLVABLE")throw new _n("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",t,e,n)}}}else throw new _n("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",t,e,n)}function Aj(e,t,n){try{if(!Array.isArray(e))throw new _n("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)tm(Ms(t),Ms(e),n||!0);else{n=n||py;for(var i=0;i0&&(e.patches=[],e.callback&&e.callback(i)),i}function Rb(e,t,n,i,s){if(t!==e){typeof t.toJSON=="function"&&(t=t.toJSON());for(var o=OL(t),c=OL(e),d=!1,f=c.length-1;f>=0;f--){var u=c[f],a=e[u];if(IL(t,u)&&!(t[u]===void 0&&a!==void 0&&Array.isArray(t)===!1)){var m=t[u];typeof a=="object"&&a!=null&&typeof m=="object"&&m!=null&&Array.isArray(a)===Array.isArray(m)?Rb(a,m,n,i+"/"+td(u),s):a!==m&&(s&&n.push({op:"test",path:i+"/"+td(u),value:Ms(a)}),n.push({op:"replace",path:i+"/"+td(u),value:Ms(m)}))}else Array.isArray(e)===Array.isArray(t)?(s&&n.push({op:"test",path:i+"/"+td(u),value:Ms(a)}),n.push({op:"remove",path:i+"/"+td(u)}),d=!0):(s&&n.push({op:"test",path:i,value:e}),n.push({op:"replace",path:i,value:t}))}if(!(!d&&o.length==c.length))for(var f=0;f0)return[x,i+y.join(`, `+E),a].join(` `+f)}return F}(t,"",0)};function Ls(e,t,n){return e.fields=t||[],e.fname=n,e}function mn(e){return e==null?null:e.fname}function mi(e){return e==null?null:e.fields}function Nj(e){return e.length===1?wce(e[0]):Lce(e)}const wce=e=>function(t){return t[e]},Lce=e=>{const t=e.length;return function(n){for(let i=0;ic?u():c=d+1:f==="["?(d>c&&u(),s=c=d+1):f==="]"&&(s||ce("Access path missing open bracket: "+e),s>0&&u(),s=0,c=d+1)}return s&&ce("Access path missing closing bracket: "+e),i&&ce("Access path missing closing quote: "+e),d>c&&(d++,u()),t}function hs(e,t,n){const i=Ja(e);return e=i.length===1?i[0]:e,Ls((n&&n.get||Nj)(i),[e],t||e)}const O0=hs("id"),Ei=Ls(e=>e,[],"identity"),Bl=Ls(()=>0,[],"zero"),kh=Ls(()=>1,[],"one"),sr=Ls(()=>!0,[],"true"),pl=Ls(()=>!1,[],"false");function bce(e,t,n){const i=[t].concat([].slice.call(n));console[e].apply(console,i)}const Cj=0,Pb=1,Db=2,Rj=3,Pj=4;function jb(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:bce,i=e||Cj;return{level(s){return arguments.length?(i=+s,this):i},error(){return i>=Pb&&n(t||"error","ERROR",arguments),this},warn(){return i>=Db&&n(t||"warn","WARN",arguments),this},info(){return i>=Rj&&n(t||"log","INFO",arguments),this},debug(){return i>=Pj&&n(t||"log","DEBUG",arguments),this}}}var ue=Array.isArray;function ke(e){return e===Object(e)}const JF=e=>e!=="__proto__";function Bh(){for(var e=arguments.length,t=new Array(e),n=0;n{for(const o in s)if(o==="signals")i.signals=Tce(i.signals,s.signals);else{const c=o==="legend"?{layout:1}:o==="style"?!0:null;Fh(i,o,s[o],c)}return i},{})}function Fh(e,t,n,i){if(!JF(t))return;let s,o;if(ke(n)&&!ue(n)){o=ke(e[t])?e[t]:e[t]={};for(s in n)i&&(i===!0||i[s])?Fh(o,s,n[s]):JF(s)&&(o[s]=n[s])}else e[t]=n}function Tce(e,t){if(e==null)return t;const n={},i=[];function s(o){n[o.name]||(n[o.name]=1,i.push(o))}return t.forEach(s),e.forEach(s),i}function kt(e){return e[e.length-1]}function _i(e){return e==null||e===""?null:+e}const Dj=e=>t=>e*Math.exp(t),jj=e=>t=>Math.log(e*t),Uj=e=>t=>Math.sign(t)*Math.log1p(Math.abs(t/e)),Hj=e=>t=>Math.sign(t)*Math.expm1(Math.abs(t))*e,yy=e=>t=>t<0?-Math.pow(-t,e):Math.pow(t,e);function nm(e,t,n,i){const s=n(e[0]),o=n(kt(e)),c=(o-s)*t;return[i(s-c),i(o-c)]}function zj(e,t){return nm(e,t,_i,Ei)}function $j(e,t){var n=Math.sign(e[0]);return nm(e,t,jj(n),Dj(n))}function qj(e,t,n){return nm(e,t,yy(n),yy(1/n))}function Vj(e,t,n){return nm(e,t,Uj(n),Hj(n))}function im(e,t,n,i,s){const o=i(e[0]),c=i(kt(e)),d=t!=null?i(t):(o+c)/2;return[s(d+(o-d)*n),s(d+(c-d)*n)]}function Ub(e,t,n){return im(e,t,n,_i,Ei)}function Hb(e,t,n){const i=Math.sign(e[0]);return im(e,t,n,jj(i),Dj(i))}function my(e,t,n,i){return im(e,t,n,yy(i),yy(1/i))}function zb(e,t,n,i){return im(e,t,n,Uj(i),Hj(i))}function Gj(e){return 1+~~(new Date(e).getMonth()/3)}function Wj(e){return 1+~~(new Date(e).getUTCMonth()/3)}function Se(e){return e!=null?ue(e)?e:[e]:[]}function Yj(e,t,n){let i=e[0],s=e[1],o;return s=n-t?[t,n]:[i=Math.min(Math.max(i,t),n-o),i+o]}function ft(e){return typeof e=="function"}const vce="descending";function $b(e,t,n){n=n||{},t=Se(t)||[];const i=[],s=[],o={},c=n.comparator||Ece;return Se(e).forEach((d,f)=>{d!=null&&(i.push(t[f]===vce?-1:1),s.push(d=ft(d)?d:hs(d,null,n)),(mi(d)||[]).forEach(u=>o[u]=1))}),s.length===0?null:Ls(c(s,i),Object.keys(o))}const sm=(e,t)=>(et||t==null)&&e!=null?1:(t=t instanceof Date?+t:t,(e=e instanceof Date?+e:e)!==e&&t===t?-1:t!==t&&e===e?1:0),Ece=(e,t)=>e.length===1?Sce(e[0],t[0]):xce(e,t,e.length),Sce=(e,t)=>function(n,i){return sm(e(n),e(i))*t},xce=(e,t,n)=>(t.push(0),function(i,s){let o,c=0,d=-1;for(;c===0&&++de}function qb(e,t){let n;return i=>{n&&clearTimeout(n),n=setTimeout(()=>(t(i),n=null),e)}}function dt(e){for(let t,n,i=1,s=arguments.length;ic&&(c=s))}else{for(s=t(e[n]);nc&&(c=s))}return[o,c]}function Xj(e,t){const n=e.length;let i=-1,s,o,c,d,f;if(t==null){for(;++i=o){s=c=o;break}if(i===n)return[-1,-1];for(d=f=i;++io&&(s=o,d=i),c=o){s=c=o;break}if(i===n)return[-1,-1];for(d=f=i;++io&&(s=o,d=i),c{s.set(o,e[o])}),s}function Kj(e,t,n,i,s,o){if(!n&&n!==0)return o;const c=+n;let d=e[0],f=kt(e),u;fo&&(c=s,s=o,o=c),n=n===void 0||n,i=i===void 0||i,(n?s<=e:sd.replace(/\\(.)/g,"$1")):Se(e));const i=e&&e.length,s=n&&n.get||Nj,o=d=>s(t?[d]:Ja(d));let c;if(!i)c=function(){return""};else if(i===1){const d=o(e[0]);c=function(f){return""+d(f)}}else{const d=e.map(o);c=function(f){let u=""+d[0](f),a=0;for(;++a{t={},n={},i=0},o=(c,d)=>(++i>e&&(n=t,t={},i=1),t[c]=d);return s(),{clear:s,has:c=>De(t,c)||De(n,c),get:c=>De(t,c)?t[c]:De(n,c)?o(c,n[c]):void 0,set:(c,d)=>De(t,c)?t[c]=d:o(c,d)}}function tU(e,t,n,i){const s=t.length,o=n.length;if(!o)return t;if(!s)return n;const c=i||new t.constructor(s+o);let d=0,f=0,u=0;for(;d0?n[f++]:t[d++];for(;d=0;)n+=e;return n}function nU(e,t,n,i){const s=n||" ",o=e+"",c=t-o.length;return c<=0?o:i==="left"?C1(s,c)+o:i==="center"?C1(s,~~(c/2))+o+C1(s,Math.ceil(c/2)):o+C1(s,c)}function M0(e){return e&&kt(e)-e[0]||0}function Te(e){return ue(e)?"["+e.map(Te)+"]":ke(e)||xe(e)?JSON.stringify(e).replace("\u2028","\\u2028").replace("\u2029","\\u2029"):e}function Gb(e){return e==null||e===""?null:!e||e==="false"||e==="0"?!1:!!e}const Fce=e=>Yt(e)||Hl(e)?e:Date.parse(e);function Wb(e,t){return t=t||Fce,e==null||e===""?null:t(e)}function Yb(e){return e==null||e===""?null:e+""}function zr(e){const t={},n=e.length;for(let i=0;i1)i=Pce(e,t,n);else for(s=0,i=new Array(o=e.arcs.length);s(e[t]=1+n,e),{});function Kb(e){const t=Se(e).slice(),n={};return t.length||ce("Missing time unit."),t.forEach(s=>{De(Sw,s)?n[s]=1:ce(`Invalid time unit: ${s}.`)}),(n[Mn]||n[gi]?1:0)+(n[gs]||n[wi]||n[_s]?1:0)+(n[Ha]?1:0)>1&&ce(`Incompatible time units: ${e}`),t.sort((s,o)=>Sw[s]-Sw[o]),t}const Dce={[si]:"%Y ",[gs]:"Q%q ",[wi]:"%b ",[_s]:"%d ",[Mn]:"W%U ",[gi]:"%a ",[Ha]:"%j ",[Rs]:"%H:00",[Ps]:"00:%M",[rr]:":%S",[$r]:".%L",[`${si}-${wi}`]:"%Y-%m ",[`${si}-${wi}-${_s}`]:"%Y-%m-%d ",[`${Rs}-${Ps}`]:"%H:%M"};function rU(e,t){const n=dt({},Dce,t),i=Kb(e),s=i.length;let o="",c=0,d,f;for(c=0;cc;--d)if(f=i.slice(c,d).join("-"),n[f]!=null){o+=n[f],c=d;break}return o.trim()}const id=new Date;function Zb(e){return id.setFullYear(e),id.setMonth(0),id.setDate(1),id.setHours(0,0,0,0),id}function aU(e){return lU(new Date(e))}function oU(e){return CL(new Date(e))}function lU(e){return Ro.count(Zb(e.getFullYear())-1,e)}function CL(e){return Eh.count(Zb(e.getFullYear())-1,e)}function RL(e){return Zb(e).getDay()}function jce(e,t,n,i,s,o,c){if(0<=e&&e<100){const d=new Date(-1,t,n,i,s,o,c);return d.setFullYear(e),d}return new Date(e,t,n,i,s,o,c)}function cU(e){return fU(new Date(e))}function dU(e){return PL(new Date(e))}function fU(e){const t=Date.UTC(e.getUTCFullYear(),0,1);return Ul.count(t-1,e)}function PL(e){const t=Date.UTC(e.getUTCFullYear(),0,1);return Sh.count(t-1,e)}function DL(e){return id.setTime(Date.UTC(e,0,1)),id.getUTCDay()}function Uce(e,t,n,i,s,o,c){if(0<=e&&e<100){const d=new Date(Date.UTC(-1,t,n,i,s,o,c));return d.setUTCFullYear(n.y),d}return new Date(Date.UTC(e,t,n,i,s,o,c))}function uU(e,t,n,i,s){const o=t||1,c=kt(e),d=(E,S,x)=>(x=x||E,Hce(n[x],i[x],E===c&&o,S)),f=new Date,u=zr(e),a=u[si]?d(si):Si(2012),m=u[wi]?d(wi):u[gs]?d(gs):Bl,y=u[Mn]&&u[gi]?d(gi,1,Mn+gi):u[Mn]?d(Mn,1):u[gi]?d(gi,1):u[_s]?d(_s,1):u[Ha]?d(Ha,1):kh,p=u[Rs]?d(Rs):Bl,l=u[Ps]?d(Ps):Bl,b=u[rr]?d(rr):Bl,L=u[$r]?d($r):Bl;return function(E){f.setTime(+E);const S=a(f);return s(S,m(f),y(f,S),p(f),l(f),b(f),L(f))}}function Hce(e,t,n,i){const s=n<=1?e:i?(o,c)=>i+n*Math.floor((e(o,c)-i)/n):(o,c)=>n*Math.floor(e(o,c)/n);return t?(o,c)=>t(s(o,c),c):s}function Xu(e,t,n){return t+e*7-(n+6)%7}const zce={[si]:e=>e.getFullYear(),[gs]:e=>Math.floor(e.getMonth()/3),[wi]:e=>e.getMonth(),[_s]:e=>e.getDate(),[Rs]:e=>e.getHours(),[Ps]:e=>e.getMinutes(),[rr]:e=>e.getSeconds(),[$r]:e=>e.getMilliseconds(),[Ha]:e=>lU(e),[Mn]:e=>CL(e),[Mn+gi]:(e,t)=>Xu(CL(e),e.getDay(),RL(t)),[gi]:(e,t)=>Xu(1,e.getDay(),RL(t))},$ce={[gs]:e=>3*e,[Mn]:(e,t)=>Xu(e,0,RL(t))};function hU(e,t){return uU(e,t||1,zce,$ce,jce)}const qce={[si]:e=>e.getUTCFullYear(),[gs]:e=>Math.floor(e.getUTCMonth()/3),[wi]:e=>e.getUTCMonth(),[_s]:e=>e.getUTCDate(),[Rs]:e=>e.getUTCHours(),[Ps]:e=>e.getUTCMinutes(),[rr]:e=>e.getUTCSeconds(),[$r]:e=>e.getUTCMilliseconds(),[Ha]:e=>fU(e),[Mn]:e=>PL(e),[gi]:(e,t)=>Xu(1,e.getUTCDay(),DL(t)),[Mn+gi]:(e,t)=>Xu(PL(e),e.getUTCDay(),DL(t))},Vce={[gs]:e=>3*e,[Mn]:(e,t)=>Xu(e,0,DL(t))};function gU(e,t){return uU(e,t||1,qce,Vce,Uce)}const Gce={[si]:Da,[gs]:A2.every(3),[wi]:A2,[Mn]:Eh,[_s]:Ro,[gi]:Ro,[Ha]:Ro,[Rs]:$4,[Ps]:H4,[rr]:Io,[$r]:Vu},Wce={[si]:ja,[gs]:N2.every(3),[wi]:N2,[Mn]:Sh,[_s]:Ul,[gi]:Ul,[Ha]:Ul,[Rs]:q4,[Ps]:z4,[rr]:Io,[$r]:Vu};function Oh(e){return Gce[e]}function Mh(e){return Wce[e]}function _U(e,t,n){return e?e.offset(t,n):void 0}function pU(e,t,n){return _U(Oh(e),t,n)}function yU(e,t,n){return _U(Mh(e),t,n)}function mU(e,t,n,i){return e?e.range(t,n,i):void 0}function wU(e,t,n,i){return mU(Oh(e),t,n,i)}function LU(e,t,n,i){return mU(Mh(e),t,n,i)}const R1=1e3,P1=R1*60,D1=P1*60,rm=D1*24,Yce=rm*7,eI=rm*30,jL=rm*365,bU=[si,wi,_s,Rs,Ps,rr,$r],j1=bU.slice(0,-1),U1=j1.slice(0,-1),H1=U1.slice(0,-1),Xce=H1.slice(0,-1),Kce=[si,Mn],tI=[si,wi],TU=[si],i1=[[j1,1,R1],[j1,5,5*R1],[j1,15,15*R1],[j1,30,30*R1],[U1,1,P1],[U1,5,5*P1],[U1,15,15*P1],[U1,30,30*P1],[H1,1,D1],[H1,3,3*D1],[H1,6,6*D1],[H1,12,12*D1],[Xce,1,rm],[Kce,1,Yce],[tI,1,eI],[tI,3,3*eI],[TU,1,jL]];function vU(e){const t=e.extent,n=e.maxbins||40,i=Math.abs(M0(t))/n;let s=w0(d=>d[2]).right(i1,i),o,c;return s===i1.length?(o=TU,c=Jl(t[0]/jL,t[1]/jL,n)):s?(s=i1[i/i1[s-1][2]t[n]||(t[n]=e(n))}function Zce(e,t){return n=>{const i=e(n),s=i.indexOf(t);if(s<0)return i;let o=Jce(i,s);const c=os;)if(i[o]!=="0"){++o;break}return i.slice(0,o)+c}}function Jce(e,t){let n=e.lastIndexOf("e"),i;if(n>0)return n;for(n=e.length;--n>t;)if(i=e.charCodeAt(n),i>=48&&i<=57)return n+1}function EU(e){const t=z1(e.format),n=e.formatPrefix;return{format:t,formatPrefix:n,formatFloat(i){const s=Pd(i||",");if(s.precision==null){switch(s.precision=12,s.type){case"%":s.precision-=2;break;case"e":s.precision-=1;break}return Zce(t(s),t(".1f")(1)[1])}else return t(s)},formatSpan(i,s,o,c){c=Pd(c??",f");const d=Jl(i,s,o),f=Math.max(Math.abs(i),Math.abs(s));let u;if(c.precision==null)switch(c.type){case"s":return isNaN(u=NP(d,f))||(c.precision=u),n(c,f);case"":case"e":case"g":case"p":case"r":{isNaN(u=CP(d,f))||(c.precision=u-(c.type==="e"));break}case"f":case"%":{isNaN(u=AP(d))||(c.precision=u-(c.type==="%")*2);break}}return t(c)}}}let UL;SU();function SU(){return UL=EU({format:N4,formatPrefix:V7})}function xU(e){return EU(MP(e))}function wy(e){return arguments.length?UL=xU(e):UL}function nI(e,t,n){n=n||{},ke(n)||ce(`Invalid time multi-format specifier: ${n}`);const i=t(rr),s=t(Ps),o=t(Rs),c=t(_s),d=t(Mn),f=t(wi),u=t(gs),a=t(si),m=e(n[$r]||".%L"),y=e(n[rr]||":%S"),p=e(n[Ps]||"%I:%M"),l=e(n[Rs]||"%I %p"),b=e(n[_s]||n[gi]||"%a %d"),L=e(n[Mn]||"%b %d"),E=e(n[wi]||"%B"),S=e(n[gs]||"%B"),x=e(n[si]||"%Y");return F=>(i(F)xe(i)?t(i):nI(t,Oh,i),utcFormat:i=>xe(i)?n(i):nI(n,Mh,i),timeParse:z1(e.parse),utcParse:z1(e.utcParse)}}let HL;BU();function BU(){return HL=kU({format:ab,parse:WD,utcFormat:ob,utcParse:YD})}function FU(e){return kU(zD(e))}function R2(e){return arguments.length?HL=FU(e):HL}const zL=(e,t)=>dt({},e,t);function IU(e,t){const n=e?xU(e):wy(),i=t?FU(t):R2();return zL(n,i)}function Jb(e,t){const n=arguments.length;return n&&n!==2&&ce("defaultLocale expects either zero or two arguments."),n?zL(wy(e),R2(t)):zL(wy(),R2())}function Qce(){return SU(),BU(),Jb()}const ede=/^(data:|([A-Za-z]+:)?\/\/)/,tde=/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp|file|data):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i,nde=/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205f\u3000]/g,iI="file://";function ide(e,t){return n=>({options:n||{},sanitize:rde,load:sde,fileAccess:!!t,file:ade(t),http:lde(e)})}async function sde(e,t){const n=await this.sanitize(e,t),i=n.href;return n.localFile?this.file(i):this.http(i,t)}async function rde(e,t){t=dt({},this.options,t);const n=this.fileAccess,i={href:null};let s,o,c;const d=tde.test(e.replace(nde,""));(e==null||typeof e!="string"||!d)&&ce("Sanitize failure, invalid URI: "+Te(e));const f=ede.test(e);return(c=t.baseURL)&&!f&&(!e.startsWith("/")&&!c.endsWith("/")&&(e="/"+e),e=c+e),o=(s=e.startsWith(iI))||t.mode==="file"||t.mode!=="http"&&!f&&n,s?e=e.slice(iI.length):e.startsWith("//")&&(t.defaultProtocol==="file"?(e=e.slice(2),o=!0):e=(t.defaultProtocol||"http")+":"+e),Object.defineProperty(i,"localFile",{value:!!o}),i.href=e,t.target&&(i.target=t.target+""),t.rel&&(i.rel=t.rel+""),t.context==="image"&&t.crossOrigin&&(i.crossOrigin=t.crossOrigin+""),i}function ade(e){return e?t=>new Promise((n,i)=>{e.readFile(t,(s,o)=>{s?i(s):n(o)})}):ode}async function ode(){ce("No file system access.")}function lde(e){return e?async function(t,n){const i=dt({},this.options.http,n),s=n&&n.response,o=await e(t,i);return o.ok?ft(o[s])?o[s]():o.text():ce(o.status+""+o.statusText)}:cde}async function cde(){ce("No HTTP fetch method available.")}const dde=e=>e!=null&&e===e,fde=e=>e==="true"||e==="false"||e===!0||e===!1,ude=e=>!Number.isNaN(Date.parse(e)),OU=e=>!Number.isNaN(+e)&&!(e instanceof Date),hde=e=>OU(e)&&Number.isInteger(+e),$L={boolean:Gb,integer:_i,number:_i,date:Wb,string:Yb,unknown:Ei},Xg=[fde,hde,OU,ude],gde=["boolean","integer","number","date"];function MU(e,t){if(!e||!e.length)return"unknown";const n=e.length,i=Xg.length,s=Xg.map((o,c)=>c+1);for(let o=0,c=0,d,f;oo===0?c:o,0)-1]}function AU(e,t){return t.reduce((n,i)=>(n[i]=MU(e,i),n),{})}function sI(e){const t=function(n,i){const s={delimiter:e};return Qb(n,i?dt(i,s):s)};return t.responseType="text",t}function Qb(e,t){return t.header&&(e=t.header.map(Te).join(t.delimiter)+` `+e),Tie(t.delimiter).parse(e+"")}Qb.responseType="text";function _de(e){return typeof Buffer=="function"&&ft(Buffer.isBuffer)?Buffer.isBuffer(e):!1}function eT(e,t){const n=t&&t.property?hs(t.property):Ei;return ke(e)&&!_de(e)?pde(n(e),t):n(JSON.parse(e))}eT.responseType="json";function pde(e,t){return!ue(e)&&Zj(e)&&(e=[...e]),t&&t.copy?JSON.parse(JSON.stringify(e)):e}const yde={interior:(e,t)=>e!==t,exterior:(e,t)=>e===t};function NU(e,t){let n,i,s,o;return e=eT(e,t),t&&t.feature?(n=Ace,s=t.feature):t&&t.mesh?(n=Cce,s=t.mesh,o=yde[t.filter]):ce("Missing TopoJSON feature or mesh parameter."),i=(i=e.objects[s])?n(e,i,o):ce("Invalid TopoJSON object: "+s),i&&i.features||[i]}NU.responseType="json";const H_={dsv:Qb,csv:sI(","),tsv:sI(" "),json:eT,topojson:NU};function tT(e,t){return arguments.length>1?(H_[e]=t,this):De(H_,e)?H_[e]:null}function CU(e){const t=tT(e);return t&&t.responseType||"text"}function RU(e,t,n,i){t=t||{};const s=tT(t.type||"json");return s||ce("Unknown data format type: "+t.type),e=s(e,t),t.parse&&mde(e,t.parse,n,i),De(e,"columns")&&delete e.columns,e}function mde(e,t,n,i){if(!e.length)return;const s=R2();n=n||s.timeParse,i=i||s.utcParse;let o=e.columns||Object.keys(e[0]),c,d,f,u,a,m;t==="auto"&&(t=AU(e,o)),o=Object.keys(t);const y=o.map(p=>{const l=t[p];let b,L;if(l&&(l.startsWith("date:")||l.startsWith("utc:")))return b=l.split(/:(.+)?/,2),L=b[1],(L[0]==="'"&&L[L.length-1]==="'"||L[0]==='"'&&L[L.length-1]==='"')&&(L=L.slice(1,-1)),(b[0]==="utc"?i:n)(L);if(!$L[l])throw Error("Illegal format pattern: "+p+":"+l);return $L[l]});for(f=0,a=e.length,m=o.length;f{const o=t(s);return i[o]||(i[o]=1,n.push(s)),n},n.remove=s=>{const o=t(s);if(i[o]){i[o]=0;const c=n.indexOf(s);c>=0&&n.splice(c,1)}return n},n}async function z_(e,t){try{await t(e)}catch(n){e.error(n)}}const PU=Symbol("vega_id");let wde=1;function lm(e){return!!(e&&Re(e))}function Re(e){return e[PU]}function DU(e,t){return e[PU]=t,e}function Dt(e){const t=e===Object(e)?e:{data:e};return Re(t)?t:DU(t,wde++)}function nT(e){return cm(e,Dt({}))}function cm(e,t){for(const n in e)t[n]=e[n];return t}function jU(e,t){return DU(t,Re(e))}function hf(e,t){return e?t?(n,i)=>e(n,i)||Re(t(n))-Re(t(i)):(n,i)=>e(n,i)||Re(n)-Re(i):null}function UU(e){return e&&e.constructor===gf}function gf(){const e=[],t=[],n=[],i=[],s=[];let o=null,c=!1;return{constructor:gf,insert(d){const f=Se(d),u=f.length;for(let a=0;a{l(S)&&(u[Re(S)]=-1)});for(m=0,y=e.length;m0&&(E(b,l,p.value),d.modifies(l));for(m=0,y=s.length;m{l(S)&&u[Re(S)]>0&&E(S,p.field,p.value)}),d.modifies(p.field);if(c)d.mod=t.length||i.length?f.filter(S=>u[Re(S)]>0):f.slice();else for(L in a)d.mod.push(a[L]);return(o||o==null&&(t.length||i.length))&&d.clean(!0),d}}}const $_="_:mod:_";function dm(){Object.defineProperty(this,$_,{writable:!0,value:{}})}dm.prototype={set(e,t,n,i){const s=this,o=s[e],c=s[$_];return t!=null&&t>=0?(o[t]!==n||i)&&(o[t]=n,c[t+":"+e]=-1,c[e]=-1):(o!==n||i)&&(s[e]=n,c[e]=ue(n)?1+n.length:-1),s},modified(e,t){const n=this[$_];if(arguments.length){if(ue(e)){for(let i=0;i=0?t+1{p instanceof Jt?(p!==this&&(t&&p.targets().add(this),o.push(p)),s.push({op:p,name:m,index:y})):i.set(m,y,p)};for(c in e)if(d=e[c],c===bde)Se(d).forEach(m=>{m instanceof Jt?m!==this&&(m.targets().add(this),o.push(m)):ce("Pulse parameters must be operator instances.")}),this.source=d;else if(ue(d))for(i.set(c,-1,Array(f=d.length)),u=0;u{const n=Date.now();return n-t>e?(t=n,1):0})},debounce(e){const t=yl();return this.targets().add(yl(null,null,qb(e,n=>{const i=n.dataflow;t.receive(n),i&&i.run&&i.run()}))),t},between(e,t){let n=!1;return e.targets().add(yl(null,null,()=>n=!0)),t.targets().add(yl(null,null,()=>n=!1)),this.filter(()=>n)},detach(){this._filter=sr,this._targets=null}};function Bde(e,t,n,i){const s=this,o=yl(n,i),c=function(u){u.dataflow=s;try{o.receive(u)}catch(a){s.error(a)}finally{s.run()}};let d;typeof e=="string"&&typeof document<"u"?d=document.querySelectorAll(e):d=Se(e);const f=d.length;for(let u=0;ut=i);return n.requests=0,n.done=()=>{--n.requests===0&&(e._pending=null,t(e))},e._pending=n}const Nde={skip:!0};function Cde(e,t,n,i,s){return(e instanceof Jt?Pde:Rde)(this,e,t,n,i,s),this}function Rde(e,t,n,i,s,o){const c=dt({},o,Nde);let d,f;ft(n)||(n=Si(n)),i===void 0?d=u=>e.touch(n(u)):ft(i)?(f=new Jt(null,i,s,!1),d=u=>{f.evaluate(u);const a=n(u),m=f.value;UU(m)?e.pulse(a,m,o):e.update(a,m,c)}):d=u=>e.update(n(u),i,c),t.apply(d)}function Pde(e,t,n,i,s,o){if(i===void 0)t.targets().add(n);else{const c=o||{},d=new Jt(null,Dde(n,i),s,!1);d.modified(c.force),d.rank=t.rank,t.targets().add(d),n&&(d.skip(!0),d.value=n.value,d.targets().add(n),e.connect(n,[d]))}}function Dde(e,t){return t=ft(t)?t:Si(t),e?function(n,i){const s=t(n,i);return e.skip()||(e.skip(s!==this.value).value=s),s}:t}function jde(e){e.rank=++this._rank}function Ude(e){const t=[e];let n,i,s;for(;t.length;)if(this.rank(n=t.pop()),i=n._targets)for(s=i.length;--s>=0;)t.push(n=i[s]),n===e&&ce("Cycle detected in dataflow graph.")}const Ly={},oa=1<<0,El=1<<1,wo=1<<2,Hde=oa|El,aI=oa|wo,Of=oa|El|wo,oI=1<<3,s1=1<<4,lI=1<<5,cI=1<<6;function zl(e,t,n){this.dataflow=e,this.stamp=t??-1,this.add=[],this.rem=[],this.mod=[],this.fields=null,this.encode=n||null}function xw(e,t){const n=[];return vl(e,t,i=>n.push(i)),n}function dI(e,t){const n={};return e.visit(t,i=>{n[Re(i)]=1}),i=>n[Re(i)]?null:i}function Kg(e,t){return e?(n,i)=>e(n,i)&&t(n,i):t}zl.prototype={StopPropagation:Ly,ADD:oa,REM:El,MOD:wo,ADD_REM:Hde,ADD_MOD:aI,ALL:Of,REFLOW:oI,SOURCE:s1,NO_SOURCE:lI,NO_FIELDS:cI,fork(e){return new zl(this.dataflow).init(this,e)},clone(){const e=this.fork(Of);return e.add=e.add.slice(),e.rem=e.rem.slice(),e.mod=e.mod.slice(),e.source&&(e.source=e.source.slice()),e.materialize(Of|s1)},addAll(){let e=this;return!e.source||e.add===e.rem||!e.rem.length&&e.source.length===e.add.length||(e=new zl(this.dataflow).init(this),e.add=e.source,e.rem=[]),e},init(e,t){const n=this;return n.stamp=e.stamp,n.encode=e.encode,e.fields&&!(t&cI)&&(n.fields=e.fields),t&oa?(n.addF=e.addF,n.add=e.add):(n.addF=null,n.add=[]),t&El?(n.remF=e.remF,n.rem=e.rem):(n.remF=null,n.rem=[]),t&wo?(n.modF=e.modF,n.mod=e.mod):(n.modF=null,n.mod=[]),t&lI?(n.srcF=null,n.source=null):(n.srcF=e.srcF,n.source=e.source,e.cleans&&(n.cleans=e.cleans)),n},runAfter(e){this.dataflow.runAfter(e)},changed(e){const t=e||Of;return t&oa&&this.add.length||t&El&&this.rem.length||t&wo&&this.mod.length},reflow(e){if(e)return this.fork(Of).reflow();const t=this.add.length,n=this.source&&this.source.length;return n&&n!==t&&(this.mod=this.source,t&&this.filter(wo,dI(this,oa))),this},clean(e){return arguments.length?(this.cleans=!!e,this):this.cleans},modifies(e){const t=this.fields||(this.fields={});return ue(e)?e.forEach(n=>t[n]=!0):t[e]=!0,this},modified(e,t){const n=this.fields;return(t||this.mod.length)&&n?arguments.length?ue(e)?e.some(i=>n[i]):n[e]:!!n:!1},filter(e,t){const n=this;return e&oa&&(n.addF=Kg(n.addF,t)),e&El&&(n.remF=Kg(n.remF,t)),e&wo&&(n.modF=Kg(n.modF,t)),e&s1&&(n.srcF=Kg(n.srcF,t)),n},materialize(e){e=e||Of;const t=this;return e&oa&&t.addF&&(t.add=xw(t.add,t.addF),t.addF=null),e&El&&t.remF&&(t.rem=xw(t.rem,t.remF),t.remF=null),e&wo&&t.modF&&(t.mod=xw(t.mod,t.modF),t.modF=null),e&s1&&t.srcF&&(t.source=t.source.filter(t.srcF),t.srcF=null),t},visit(e,t){const n=this,i=t;if(e&s1)return vl(n.source,n.srcF,i),n;e&oa&&vl(n.add,n.addF,i),e&El&&vl(n.rem,n.remF,i),e&wo&&vl(n.mod,n.modF,i);const s=n.source;if(e&oI&&s){const o=n.add.length+n.mod.length;o===s.length||(o?vl(s,dI(n,aI),i):vl(s,n.srcF,i))}return n}};function iT(e,t,n,i){const s=this;let o=0;this.dataflow=e,this.stamp=t,this.fields=null,this.encode=i||null,this.pulses=n;for(const c of n)if(c.stamp===t){if(c.fields){const d=s.fields||(s.fields={});for(const f in c.fields)d[f]=1}c.changed(s.ADD)&&(o|=s.ADD),c.changed(s.REM)&&(o|=s.REM),c.changed(s.MOD)&&(o|=s.MOD)}this.changes=o}Le(iT,zl,{fork(e){const t=new zl(this.dataflow).init(this,e&this.NO_FIELDS);return e!==void 0&&(e&t.ADD&&this.visit(t.ADD,n=>t.add.push(n)),e&t.REM&&this.visit(t.REM,n=>t.rem.push(n)),e&t.MOD&&this.visit(t.MOD,n=>t.mod.push(n))),t},changed(e){return this.changes&e},modified(e){const t=this,n=t.fields;return n&&t.changes&t.MOD?ue(e)?e.some(i=>n[i]):n[e]:0},filter(){ce("MultiPulse does not support filtering.")},materialize(){ce("MultiPulse does not support materialization.")},visit(e,t){const n=this,i=n.pulses,s=i.length;let o=0;if(e&n.SOURCE)for(;oi._enqueue(a,!0)),i._touched=om(O0);let c=0,d,f,u;try{for(;i._heap.size()>0;){if(d=i._heap.pop(),d.rank!==d.qrank){i._enqueue(d,!0);continue}f=d.run(i._getPulse(d,e)),f.then?f=await f:f.async&&(s.push(f.async),f=Ly),f!==Ly&&d._targets&&d._targets.forEach(a=>i._enqueue(a)),++c}}catch(a){i._heap.clear(),u=a}if(i._input={},i._pulse=null,i.debug(`Pulse ${o}: ${c} operators`),u&&(i._postrun=[],i.error(u)),i._postrun.length){const a=i._postrun.sort((m,y)=>y.priority-m.priority);i._postrun=[];for(let m=0;mi.runAsync(null,()=>{a.forEach(m=>{try{m(i)}catch(y){i.error(y)}})})),i}async function $de(e,t,n){for(;this._running;)await this._running;const i=()=>this._running=null;return(this._running=this.evaluate(e,t,n)).then(i,i),this._running}function qde(e,t,n){return this._pulse?HU(this):(this.evaluate(e,t,n),this)}function Vde(e,t,n){if(this._pulse||t)this._postrun.push({priority:n||0,callback:e});else try{e(this)}catch(i){this.error(i)}}function HU(e){return e.error("Dataflow already running. Use runAsync() to chain invocations."),e}function Gde(e,t){const n=e.stamps.pulse),t):this._input[e.id]||Yde(this._pulse,n&&n.pulse)}function Yde(e,t){return t&&t.stamp===e.stamp?t:(e=e.fork(),t&&t!==Ly&&(e.source=t.source),e)}const sT={skip:!1,force:!1};function Xde(e,t){const n=t||sT;return this._pulse?this._enqueue(e):this._touched.add(e),n.skip&&e.skip(!0),this}function Kde(e,t,n){const i=n||sT;return(e.set(t)||i.force)&&this.touch(e,i),this}function Zde(e,t,n){this.touch(e,n||sT);const i=new zl(this,this._clock+(this._pulse?0:1)),s=e.pulse&&e.pulse.source||[];return i.target=e,this._input[e.id]=t.pulse(i,s),this}function Jde(e){let t=[];return{clear:()=>t=[],size:()=>t.length,peek:()=>t[0],push:n=>(t.push(n),zU(t,0,t.length-1,e)),pop:()=>{const n=t.pop();let i;return t.length?(i=t[0],t[0]=n,Qde(t,0,e)):i=n,i}}}function zU(e,t,n,i){let s,o;const c=e[n];for(;n>t;){if(o=n-1>>1,s=e[o],i(c,s)<0){e[n]=s,n=o;continue}break}return e[n]=c}function Qde(e,t,n){const i=t,s=e.length,o=e[t];let c=(t<<1)+1,d;for(;c=0&&(c=d),e[t]=e[c],t=c,c=(t<<1)+1;return e[t]=o,zU(e,i,t,n)}function wu(){this.logger(jb()),this.logLevel(Pb),this._clock=0,this._rank=0,this._locale=Jb();try{this._loader=am()}catch{}this._touched=om(O0),this._input={},this._pulse=null,this._heap=Jde((e,t)=>e.qrank-t.qrank),this._postrun=[]}function r1(e){return function(){return this._log[e].apply(this,arguments)}}wu.prototype={stamp(){return this._clock},loader(e){return arguments.length?(this._loader=e,this):this._loader},locale(e){return arguments.length?(this._locale=e,this):this._locale},logger(e){return arguments.length?(this._log=e,this):this._log},error:r1("error"),warn:r1("warn"),info:r1("info"),debug:r1("debug"),logLevel:r1("level"),cleanThreshold:1e4,add:Sde,connect:xde,rank:jde,rerank:Ude,pulse:Zde,touch:Xde,update:Kde,changeset:gf,ingest:Ide,parse:Fde,preload:Mde,request:Ode,events:Bde,on:Cde,evaluate:zde,run:qde,runAsync:$de,runAfter:Vde,_enqueue:Gde,_getPulse:Wde};function ae(e,t){Jt.call(this,e,null,t)}Le(ae,Jt,{run(e){if(e.stampthis.pulse=n):t!==e.StopPropagation&&(this.pulse=t),t},evaluate(e){const t=this.marshall(e.stamp),n=this.transform(t,e);return t.clear(),n},transform(){}});const Ku={};function $U(e){const t=qU(e);return t&&t.Definition||null}function qU(e){return e=e&&e.toLowerCase(),De(Ku,e)?Ku[e]:null}function efe(e){return t=>{const n=e.length;let i=1,s=String(e[0](t));for(;i{},tfe={init:kw,add:kw,rem:kw,idx:0},P2={values:{init:e=>e.cell.store=!0,value:e=>e.cell.data.values(),idx:-1},count:{value:e=>e.cell.num},__count__:{value:e=>e.missing+e.valid},missing:{value:e=>e.missing},valid:{value:e=>e.valid},sum:{init:e=>e.sum=0,value:e=>e.sum,add:(e,t)=>e.sum+=+t,rem:(e,t)=>e.sum-=t},product:{init:e=>e.product=1,value:e=>e.valid?e.product:void 0,add:(e,t)=>e.product*=t,rem:(e,t)=>e.product/=t},mean:{init:e=>e.mean=0,value:e=>e.valid?e.mean:void 0,add:(e,t)=>(e.mean_d=t-e.mean,e.mean+=e.mean_d/e.valid),rem:(e,t)=>(e.mean_d=t-e.mean,e.mean-=e.valid?e.mean_d/e.valid:e.mean)},average:{value:e=>e.valid?e.mean:void 0,req:["mean"],idx:1},variance:{init:e=>e.dev=0,value:e=>e.valid>1?e.dev/(e.valid-1):void 0,add:(e,t)=>e.dev+=e.mean_d*(t-e.mean),rem:(e,t)=>e.dev-=e.mean_d*(t-e.mean),req:["mean"],idx:1},variancep:{value:e=>e.valid>1?e.dev/e.valid:void 0,req:["variance"],idx:2},stdev:{value:e=>e.valid>1?Math.sqrt(e.dev/(e.valid-1)):void 0,req:["variance"],idx:2},stdevp:{value:e=>e.valid>1?Math.sqrt(e.dev/e.valid):void 0,req:["variance"],idx:2},stderr:{value:e=>e.valid>1?Math.sqrt(e.dev/(e.valid*(e.valid-1))):void 0,req:["variance"],idx:2},distinct:{value:e=>e.cell.data.distinct(e.get),req:["values"],idx:3},ci0:{value:e=>e.cell.data.ci0(e.get),req:["values"],idx:3},ci1:{value:e=>e.cell.data.ci1(e.get),req:["values"],idx:3},median:{value:e=>e.cell.data.q2(e.get),req:["values"],idx:3},q1:{value:e=>e.cell.data.q1(e.get),req:["values"],idx:3},q3:{value:e=>e.cell.data.q3(e.get),req:["values"],idx:3},min:{init:e=>e.min=void 0,value:e=>e.min=Number.isNaN(e.min)?e.cell.data.min(e.get):e.min,add:(e,t)=>{(t{t<=e.min&&(e.min=NaN)},req:["values"],idx:4},max:{init:e=>e.max=void 0,value:e=>e.max=Number.isNaN(e.max)?e.cell.data.max(e.get):e.max,add:(e,t)=>{(t>e.max||e.max===void 0)&&(e.max=t)},rem:(e,t)=>{t>=e.max&&(e.max=NaN)},req:["values"],idx:4},argmin:{init:e=>e.argmin=void 0,value:e=>e.argmin||e.cell.data.argmin(e.get),add:(e,t,n)=>{t{t<=e.min&&(e.argmin=void 0)},req:["min","values"],idx:3},argmax:{init:e=>e.argmax=void 0,value:e=>e.argmax||e.cell.data.argmax(e.get),add:(e,t,n)=>{t>e.max&&(e.argmax=n)},rem:(e,t)=>{t>=e.max&&(e.argmax=void 0)},req:["max","values"],idx:3}},A0=Object.keys(P2).filter(e=>e!=="__count__");function nfe(e,t){return n=>dt({name:e,out:n||e},tfe,t)}[...A0,"__count__"].forEach(e=>{P2[e]=nfe(e,P2[e])});function GU(e,t){return P2[e](t)}function WU(e,t){return e.idx-t.idx}function ife(e){const t={};e.forEach(i=>t[i.name]=i);const n=i=>{i.req&&i.req.forEach(s=>{t[s]||n(t[s]=P2[s]())})};return e.forEach(n),Object.values(t).sort(WU)}function sfe(){this.valid=0,this.missing=0,this._ops.forEach(e=>e.init(this))}function rfe(e,t){if(e==null||e===""){++this.missing;return}e===e&&(++this.valid,this._ops.forEach(n=>n.add(this,e,t)))}function afe(e,t){if(e==null||e===""){--this.missing;return}e===e&&(--this.valid,this._ops.forEach(n=>n.rem(this,e,t)))}function ofe(e){return this._out.forEach(t=>e[t.out]=t.value(this)),e}function YU(e,t){const n=t||Ei,i=ife(e),s=e.slice().sort(WU);function o(c){this._ops=i,this._out=s,this.cell=c,this.init()}return o.prototype.init=sfe,o.prototype.add=rfe,o.prototype.rem=afe,o.prototype.set=ofe,o.prototype.get=n,o.fields=e.map(c=>c.out),o}function rT(e){this._key=e?hs(e):Re,this.reset()}const ai=rT.prototype;ai.reset=function(){this._add=[],this._rem=[],this._ext=null,this._get=null,this._q=null};ai.add=function(e){this._add.push(e)};ai.rem=function(e){this._rem.push(e)};ai.values=function(){if(this._get=null,this._rem.length===0)return this._add;const e=this._add,t=this._rem,n=this._key,i=e.length,s=t.length,o=Array(i-s),c={};let d,f,u;for(d=0;d=0;)o=e(t[i])+"",De(n,o)||(n[o]=1,++s);return s};ai.extent=function(e){if(this._get!==e||!this._ext){const t=this.values(),n=Xj(t,e);this._ext=[t[n[0]],t[n[1]]],this._get=e}return this._ext};ai.argmin=function(e){return this.extent(e)[0]||{}};ai.argmax=function(e){return this.extent(e)[1]||{}};ai.min=function(e){const t=this.extent(e)[0];return t!=null?e(t):void 0};ai.max=function(e){const t=this.extent(e)[1];return t!=null?e(t):void 0};ai.quartile=function(e){return(this._get!==e||!this._q)&&(this._q=mb(this.values(),e),this._get=e),this._q};ai.q1=function(e){return this.quartile(e)[0]};ai.q2=function(e){return this.quartile(e)[1]};ai.q3=function(e){return this.quartile(e)[2]};ai.ci=function(e){return(this._get!==e||!this._ci)&&(this._ci=wj(this.values(),1e3,.05,e),this._get=e),this._ci};ai.ci0=function(e){return this.ci(e)[0]};ai.ci1=function(e){return this.ci(e)[1]};function nc(e){ae.call(this,null,e),this._adds=[],this._mods=[],this._alen=0,this._mlen=0,this._drop=!0,this._cross=!1,this._dims=[],this._dnames=[],this._measures=[],this._countOnly=!1,this._counts=null,this._prev=null,this._inputs=null,this._outputs=null}nc.Definition={type:"Aggregate",metadata:{generates:!0,changes:!0},params:[{name:"groupby",type:"field",array:!0},{name:"ops",type:"enum",array:!0,values:A0},{name:"fields",type:"field",null:!0,array:!0},{name:"as",type:"string",null:!0,array:!0},{name:"drop",type:"boolean",default:!0},{name:"cross",type:"boolean",default:!1},{name:"key",type:"field"}]};Le(nc,ae,{transform(e,t){const n=this,i=t.fork(t.NO_SOURCE|t.NO_FIELDS),s=e.modified();return n.stamp=i.stamp,n.value&&(s||t.modified(n._inputs,!0))?(n._prev=n.value,n.value=s?n.init(e):{},t.visit(t.SOURCE,o=>n.add(o))):(n.value=n.value||n.init(e),t.visit(t.REM,o=>n.rem(o)),t.visit(t.ADD,o=>n.add(o))),i.modifies(n._outputs),n._drop=e.drop!==!1,e.cross&&n._dims.length>1&&(n._drop=!1,n.cross()),t.clean()&&n._drop&&i.clean(!0).runAfter(()=>this.clean()),n.changes(i)},cross(){const e=this,t=e.value,n=e._dnames,i=n.map(()=>({})),s=n.length;function o(d){let f,u,a,m;for(f in d)for(a=d[f].tuple,u=0;u{const E=mn(L);return s(L),n.push(E),E}),this.cellkey=e.key?e.key:qL(this._dims),this._countOnly=!0,this._counts=[],this._measures=[];const o=e.fields||[null],c=e.ops||["count"],d=e.as||[],f=o.length,u={};let a,m,y,p,l,b;for(f!==c.length&&ce("Unmatched number of fields and aggregate ops."),b=0;bYU(L,L.field)),{}},cellkey:qL(),cell(e,t){let n=this.value[e];return n?n.num===0&&this._drop&&n.stamp{const m=i(a);a[d]=m,a[f]=m==null?null:s+o*(1+(m-s)/o)}:a=>a[d]=i(a)),t.modifies(n?c:d)},_bins(e){if(this.value&&!e.modified())return this.value;const t=e.field,n=Lb(e),i=n.step;let s=n.start,o=s+Math.ceil((n.stop-s)/i)*i,c,d;(c=e.anchor)!=null&&(d=c-(s+i*Math.floor((c-s)/i)),s+=d,o+=d);const f=function(u){let a=_i(t(u));return a==null?null:ao?1/0:(a=Math.max(s,Math.min(a,o-i)),s+i*Math.floor(lfe+(a-s)/i))};return f.start=s,f.stop=n.stop,f.step=i,this.value=Ls(f,mi(t),e.name||"bin_"+mn(t))}});function XU(e,t,n){const i=e;let s=t||[],o=n||[],c={},d=0;return{add:f=>o.push(f),remove:f=>c[i(f)]=++d,size:()=>s.length,data:(f,u)=>(d&&(s=s.filter(a=>!c[i(a)]),c={},d=0),u&&f&&s.sort(f),o.length&&(s=f?tU(f,s,o.sort(f)):s.concat(o),o=[]),s)}}function oT(e){ae.call(this,[],e)}oT.Definition={type:"Collect",metadata:{source:!0},params:[{name:"sort",type:"compare"}]};Le(oT,ae,{transform(e,t){const n=t.fork(t.ALL),i=XU(Re,this.value,n.materialize(n.ADD).add),s=e.sort,o=t.changed()||s&&(e.modified("sort")||t.modified(s.fields));return n.visit(n.REM,i.remove),this.modified(o),this.value=n.source=i.data(hf(s),o),t.source&&t.source.root&&(this.value.root=t.source.root),n}});function KU(e){Jt.call(this,null,cfe,e)}Le(KU,Jt);function cfe(e){return this.value&&!e.modified()?this.value:$b(e.fields,e.orders)}function lT(e){ae.call(this,null,e)}lT.Definition={type:"CountPattern",metadata:{generates:!0,changes:!0},params:[{name:"field",type:"field",required:!0},{name:"case",type:"enum",values:["upper","lower","mixed"],default:"mixed"},{name:"pattern",type:"string",default:'[\\w"]+'},{name:"stopwords",type:"string",default:""},{name:"as",type:"string",array:!0,length:2,default:["text","count"]}]};function dfe(e,t,n){switch(t){case"upper":e=e.toUpperCase();break;case"lower":e=e.toLowerCase();break}return e.match(n)}Le(lT,ae,{transform(e,t){const n=m=>y=>{for(var p=dfe(d(y),e.case,o)||[],l,b=0,L=p.length;bs[m]=1+(s[m]||0)),a=n(m=>s[m]-=1);return i?t.visit(t.SOURCE,u):(t.visit(t.ADD,u),t.visit(t.REM,a)),this._finish(t,f)},_parameterCheck(e,t){let n=!1;return(e.modified("stopwords")||!this._stop)&&(this._stop=new RegExp("^"+(e.stopwords||"")+"$","i"),n=!0),(e.modified("pattern")||!this._match)&&(this._match=new RegExp(e.pattern||"[\\w']+","g"),n=!0),(e.modified("field")||t.modified(e.field.fields))&&(n=!0),n&&(this._counts={}),n},_finish(e,t){const n=this._counts,i=this._tuples||(this._tuples={}),s=t[0],o=t[1],c=e.fork(e.NO_SOURCE|e.NO_FIELDS);let d,f,u;for(d in n)f=i[d],u=n[d]||0,!f&&u?(i[d]=f=Dt({}),f[s]=d,f[o]=u,c.add.push(f)):u===0?(f&&c.rem.push(f),n[d]=null,i[d]=null):f[o]!==u&&(f[o]=u,c.mod.push(f));return c.modifies(t)}});function cT(e){ae.call(this,null,e)}cT.Definition={type:"Cross",metadata:{generates:!0},params:[{name:"filter",type:"expr"},{name:"as",type:"string",array:!0,length:2,default:["a","b"]}]};Le(cT,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE),i=e.as||["a","b"],s=i[0],o=i[1],c=!this.value||t.changed(t.ADD_REM)||e.modified("as")||e.modified("filter");let d=this.value;return c?(d&&(n.rem=d),d=t.materialize(t.SOURCE).source,n.add=this.value=ffe(d,s,o,e.filter||sr)):n.mod=d,n.source=this.value,n.modifies(i)}});function ffe(e,t,n,i){for(var s=[],o={},c=e.length,d=0,f,u;dZU(o,t))):typeof i[s]===uI&&i[s](e[s]);return i}function dT(e){ae.call(this,null,e)}const JU=[{key:{function:"normal"},params:[{name:"mean",type:"number",default:0},{name:"stdev",type:"number",default:1}]},{key:{function:"lognormal"},params:[{name:"mean",type:"number",default:0},{name:"stdev",type:"number",default:1}]},{key:{function:"uniform"},params:[{name:"min",type:"number",default:0},{name:"max",type:"number",default:1}]},{key:{function:"kde"},params:[{name:"field",type:"field",required:!0},{name:"from",type:"data"},{name:"bandwidth",type:"number",default:0}]}],gfe={key:{function:"mixture"},params:[{name:"distributions",type:"param",array:!0,params:JU},{name:"weights",type:"number",array:!0}]};dT.Definition={type:"Density",metadata:{generates:!0},params:[{name:"extent",type:"number",array:!0,length:2},{name:"steps",type:"number"},{name:"minsteps",type:"number",default:25},{name:"maxsteps",type:"number",default:200},{name:"method",type:"string",default:"pdf",values:["pdf","cdf"]},{name:"distribution",type:"param",params:JU.concat(gfe)},{name:"as",type:"string",array:!0,default:["value","density"]}]};Le(dT,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE|t.NO_FIELDS);if(!this.value||t.changed()||e.modified()){const i=ZU(e.distribution,_fe(t)),s=e.steps||e.minsteps||25,o=e.steps||e.maxsteps||200;let c=e.method||"pdf";c!=="pdf"&&c!=="cdf"&&ce("Invalid density method: "+c),!e.extent&&!i.data&&ce("Missing density extent parameter."),c=i[c];const d=e.as||["value","density"],f=e.extent||Ua(i.data()),u=em(c,f,s,o).map(a=>{const m={};return m[d[0]]=a[0],m[d[1]]=a[1],Dt(m)});this.value&&(n.rem=this.value),this.value=n.add=n.source=u}return n}});function _fe(e){return()=>e.materialize(e.SOURCE).source}function QU(e,t){return e?e.map((n,i)=>t[i]||mn(n)):null}function fT(e,t,n){const i=[],s=m=>m(f);let o,c,d,f,u,a;if(t==null)i.push(e.map(n));else for(o={},c=0,d=e.length;cM0(Ua(e,t))/30;Le(uT,ae,{transform(e,t){if(this.value&&!(e.modified()||t.changed()))return t;const n=t.materialize(t.SOURCE).source,i=fT(t.source,e.groupby,Ei),s=e.smooth||!1,o=e.field,c=e.step||pfe(n,o),d=hf((l,b)=>o(l)-o(b)),f=e.as||eH,u=i.length;let a=1/0,m=-1/0,y=0,p;for(;ym&&(m=b),l[++p][f]=b}return this.value={start:a,stop:m,step:c},t.reflow(!0).modifies(f)}});function tH(e){Jt.call(this,null,yfe,e),this.modified(!0)}Le(tH,Jt);function yfe(e){const t=e.expr;return this.value&&!e.modified("expr")?this.value:Ls(n=>t(n,e),mi(t),mn(t))}function hT(e){ae.call(this,[void 0,void 0],e)}hT.Definition={type:"Extent",metadata:{},params:[{name:"field",type:"field",required:!0}]};Le(hT,ae,{transform(e,t){const n=this.value,i=e.field,s=t.changed()||t.modified(i.fields)||e.modified("field");let o=n[0],c=n[1];if((s||o==null)&&(o=1/0,c=-1/0),t.visit(s?t.SOURCE:t.ADD,d=>{const f=_i(i(d));f!=null&&(fc&&(c=f))}),!Number.isFinite(o)||!Number.isFinite(c)){let d=mn(i);d&&(d=` for field "${d}"`),t.dataflow.warn(`Infinite extent${d}: [${o}, ${c}]`),o=c=void 0}this.value=[o,c]}});function gT(e,t){Jt.call(this,e),this.parent=t,this.count=0}Le(gT,Jt,{connect(e){return this.detachSubflow=e.detachSubflow,this.targets().add(e),e.source=this},add(e){this.count+=1,this.value.add.push(e)},rem(e){this.count-=1,this.value.rem.push(e)},mod(e){this.value.mod.push(e)},init(e){this.value.init(e,e.NO_SOURCE)},evaluate(){return this.value}});function um(e){ae.call(this,{},e),this._keys=Ih();const t=this._targets=[];t.active=0,t.forEach=n=>{for(let i=0,s=t.active;ii&&i.count>0);this.initTargets(n)}},initTargets(e){const t=this._targets,n=t.length,i=e?e.length:0;let s=0;for(;sthis.subflow(f,s,t);return this._group=e.group||{},this.initTargets(),t.visit(t.REM,f=>{const u=Re(f),a=o.get(u);a!==void 0&&(o.delete(u),d(a).rem(f))}),t.visit(t.ADD,f=>{const u=i(f);o.set(Re(f),u),d(u).add(f)}),c||t.modified(i.fields)?t.visit(t.MOD,f=>{const u=Re(f),a=o.get(u),m=i(f);a===m?d(m).mod(f):(o.set(u,m),d(a).rem(f),d(m).add(f))}):t.changed(t.MOD)&&t.visit(t.MOD,f=>{d(o.get(Re(f))).mod(f)}),c&&t.visit(t.REFLOW,f=>{const u=Re(f),a=o.get(u),m=i(f);a!==m&&(o.set(u,m),d(a).rem(f),d(m).add(f))}),t.clean()?n.runAfter(()=>{this.clean(),o.clean()}):o.empty>n.cleanThreshold&&n.runAfter(o.clean),t}});function nH(e){Jt.call(this,null,mfe,e)}Le(nH,Jt);function mfe(e){return this.value&&!e.modified()?this.value:ue(e.name)?Se(e.name).map(t=>hs(t)):hs(e.name,e.as)}function _T(e){ae.call(this,Ih(),e)}_T.Definition={type:"Filter",metadata:{changes:!0},params:[{name:"expr",type:"expr",required:!0}]};Le(_T,ae,{transform(e,t){const n=t.dataflow,i=this.value,s=t.fork(),o=s.add,c=s.rem,d=s.mod,f=e.expr;let u=!0;t.visit(t.REM,m=>{const y=Re(m);i.has(y)?i.delete(y):c.push(m)}),t.visit(t.ADD,m=>{f(m,e)?o.push(m):i.set(Re(m),1)});function a(m){const y=Re(m),p=f(m,e),l=i.get(y);p&&l?(i.delete(y),o.push(m)):!p&&!l?(i.set(y,1),c.push(m)):u&&p&&!l&&d.push(m)}return t.visit(t.MOD,a),e.modified()&&(u=!1,t.visit(t.REFLOW,a)),i.empty>n.cleanThreshold&&n.runAfter(i.clean),s}});function pT(e){ae.call(this,[],e)}pT.Definition={type:"Flatten",metadata:{generates:!0},params:[{name:"fields",type:"field",array:!0,required:!0},{name:"index",type:"string"},{name:"as",type:"string",array:!0}]};Le(pT,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE),i=e.fields,s=QU(i,e.as||[]),o=e.index||null,c=s.length;return n.rem=this.value,t.visit(t.SOURCE,d=>{const f=i.map(l=>l(d)),u=f.reduce((l,b)=>Math.max(l,b.length),0);let a=0,m,y,p;for(;a{for(let a=0,m;ac[i]=n(c,e))}});function iH(e){ae.call(this,[],e)}Le(iH,ae,{transform(e,t){const n=t.fork(t.ALL),i=e.generator;let s=this.value,o=e.size-s.length,c,d,f;if(o>0){for(c=[];--o>=0;)c.push(f=Dt(i(e))),s.push(f);n.add=n.add.length?n.materialize(n.ADD).add.concat(c):c}else d=s.slice(0,-o),n.rem=n.rem.length?n.materialize(n.REM).rem.concat(d):d,s=s.slice(-o);return n.source=this.value=s,n}});const Zg={value:"value",median:AR,mean:dQ,min:G5,max:bd},wfe=[];function wT(e){ae.call(this,[],e)}wT.Definition={type:"Impute",metadata:{changes:!0},params:[{name:"field",type:"field",required:!0},{name:"key",type:"field",required:!0},{name:"keyvals",array:!0},{name:"groupby",type:"field",array:!0},{name:"method",type:"enum",default:"value",values:["value","mean","median","max","min"]},{name:"value",default:0}]};function Lfe(e){var t=e.method||Zg.value,n;if(Zg[t]==null)ce("Unrecognized imputation method: "+t);else return t===Zg.value?(n=e.value!==void 0?e.value:0,()=>n):Zg[t]}function bfe(e){const t=e.field;return n=>n?t(n):NaN}Le(wT,ae,{transform(e,t){var n=t.fork(t.ALL),i=Lfe(e),s=bfe(e),o=mn(e.field),c=mn(e.key),d=(e.groupby||[]).map(mn),f=Tfe(t.source,e.groupby,e.key,e.keyvals),u=[],a=this.value,m=f.domain.length,y,p,l,b,L,E,S,x,F,k;for(L=0,x=f.length;LE(L),o=[],c=i?i.slice():[],d={},f={},u,a,m,y,p,l,b,L;for(c.forEach((E,S)=>d[E]=S+1),y=0,b=e.length;yn.add(o))):(s=n.value=n.value||this.init(e),t.visit(t.REM,o=>n.rem(o)),t.visit(t.ADD,o=>n.add(o))),n.changes(),t.visit(t.SOURCE,o=>{dt(o,s[n.cellkey(o)].tuple)}),t.reflow(i).modifies(this._outputs)},changes(){const e=this._adds,t=this._mods;let n,i;for(n=0,i=this._alen;n{const l=vb(p,c)[d],b=e.counts?p.length:1,L=a||Ua(p);em(l,L,m,y).forEach(E=>{const S={};for(let x=0;x(this._pending=Se(s.data),o=>o.touch(this)))}:n.request(e.url,e.format).then(i=>Bw(this,t,Se(i.data)))}});function Efe(e){return e.modified("async")&&!(e.modified("values")||e.modified("url")||e.modified("format"))}function Bw(e,t,n){n.forEach(Dt);const i=t.fork(t.NO_FIELDS&t.NO_SOURCE);return i.rem=e.value,e.value=i.source=i.add=n,e._pending=null,i.rem.length&&i.clean(!0),i}function TT(e){ae.call(this,{},e)}TT.Definition={type:"Lookup",metadata:{modifies:!0},params:[{name:"index",type:"index",params:[{name:"from",type:"data",required:!0},{name:"key",type:"field",required:!0}]},{name:"values",type:"field",array:!0},{name:"fields",type:"field",array:!0,required:!0},{name:"as",type:"string",array:!0},{name:"default",default:null}]};Le(TT,ae,{transform(e,t){const n=e.fields,i=e.index,s=e.values,o=e.default==null?null:e.default,c=e.modified(),d=n.length;let f=c?t.SOURCE:t.ADD,u=t,a=e.as,m,y,p;return s?(y=s.length,d>1&&!a&&ce('Multi-field lookup requires explicit "as" parameter.'),a&&a.length!==d*y&&ce('The "as" parameter has too few output field names.'),a=a||s.map(mn),m=function(l){for(var b=0,L=0,E,S;bt.modified(l.fields)),f|=p?t.MOD:0),t.visit(f,m),u.modifies(a)}});function aH(e){Jt.call(this,null,Sfe,e)}Le(aH,Jt);function Sfe(e){if(this.value&&!e.modified())return this.value;const t=e.extents,n=t.length;let i=1/0,s=-1/0,o,c;for(o=0;os&&(s=c[1]);return[i,s]}function oH(e){Jt.call(this,null,xfe,e)}Le(oH,Jt);function xfe(e){return this.value&&!e.modified()?this.value:e.values.reduce((t,n)=>t.concat(n),[])}function lH(e){ae.call(this,null,e)}Le(lH,ae,{transform(e,t){return this.modified(e.modified()),this.value=e,t.fork(t.NO_SOURCE|t.NO_FIELDS)}});function vT(e){nc.call(this,e)}vT.Definition={type:"Pivot",metadata:{generates:!0,changes:!0},params:[{name:"groupby",type:"field",array:!0},{name:"field",type:"field",required:!0},{name:"value",type:"field",required:!0},{name:"op",type:"enum",values:A0,default:"sum"},{name:"limit",type:"number",default:0},{name:"key",type:"field"}]};Le(vT,nc,{_transform:nc.prototype.transform,transform(e,t){return this._transform(kfe(e,t),t)}});function kfe(e,t){const n=e.field,i=e.value,s=(e.op==="count"?"__count__":e.op)||"sum",o=mi(n).concat(mi(i)),c=Ffe(n,e.limit||0,t);return t.changed()&&e.set("__pivot__",null,null,!0),{key:e.key,groupby:e.groupby,ops:c.map(()=>s),fields:c.map(d=>Bfe(d,n,i,o)),as:c.map(d=>d+""),modified:e.modified.bind(e)}}function Bfe(e,t,n,i){return Ls(s=>t(s)===e?n(s):NaN,i,e+"")}function Ffe(e,t,n){const i={},s=[];return n.visit(n.SOURCE,o=>{const c=e(o);i[c]||(i[c]=1,s.push(c))}),s.sort(sm),t?s.slice(0,t):s}function cH(e){um.call(this,e)}Le(cH,um,{transform(e,t){const n=e.subflow,i=e.field,s=o=>this.subflow(Re(o),n,t,o);return(e.modified("field")||i&&t.modified(mi(i)))&&ce("PreFacet does not support field modification."),this.initTargets(),i?(t.visit(t.MOD,o=>{const c=s(o);i(o).forEach(d=>c.mod(d))}),t.visit(t.ADD,o=>{const c=s(o);i(o).forEach(d=>c.add(Dt(d)))}),t.visit(t.REM,o=>{const c=s(o);i(o).forEach(d=>c.rem(d))})):(t.visit(t.MOD,o=>s(o).mod(o)),t.visit(t.ADD,o=>s(o).add(o)),t.visit(t.REM,o=>s(o).rem(o))),t.clean()&&t.runAfter(()=>this.clean()),t}});function ET(e){ae.call(this,null,e)}ET.Definition={type:"Project",metadata:{generates:!0,changes:!0},params:[{name:"fields",type:"field",array:!0},{name:"as",type:"string",null:!0,array:!0}]};Le(ET,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE),i=e.fields,s=QU(e.fields,e.as||[]),o=i?(d,f)=>Ife(d,f,i,s):cm;let c;return this.value?c=this.value:(t=t.addAll(),c=this.value={}),t.visit(t.REM,d=>{const f=Re(d);n.rem.push(c[f]),c[f]=null}),t.visit(t.ADD,d=>{const f=o(d,Dt({}));c[Re(d)]=f,n.add.push(f)}),t.visit(t.MOD,d=>{n.mod.push(o(d,c[Re(d)]))}),n}});function Ife(e,t,n,i){for(let s=0,o=n.length;s{const y=yb(m,u);for(let p=0;p{const o=Re(s);n.rem.push(i[o]),i[o]=null}),t.visit(t.ADD,s=>{const o=nT(s);i[Re(s)]=o,n.add.push(o)}),t.visit(t.MOD,s=>{const o=i[Re(s)];for(const c in s)o[c]=s[c],n.modifies(c);n.mod.push(o)})),n}});function xT(e){ae.call(this,[],e),this.count=0}xT.Definition={type:"Sample",metadata:{},params:[{name:"size",type:"number",default:1e3}]};Le(xT,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE),i=e.modified("size"),s=e.size,o=this.value.reduce((a,m)=>(a[Re(m)]=1,a),{});let c=this.value,d=this.count,f=0;function u(a){let m,y;c.length=f&&(m=c[y],o[Re(m)]&&n.rem.push(m),c[y]=a)),++d}if(t.rem.length&&(t.visit(t.REM,a=>{const m=Re(a);o[m]&&(o[m]=-1,n.rem.push(a)),--d}),c=c.filter(a=>o[Re(a)]!==-1)),(t.rem.length||i)&&c.length{o[Re(a)]||u(a)}),f=-1),i&&c.length>s){const a=c.length-s;for(let m=0;m{o[Re(a)]&&n.mod.push(a)}),t.add.length&&t.visit(t.ADD,u),(t.add.length||f<0)&&(n.add=c.filter(a=>!o[Re(a)])),this.count=d,this.value=n.source=c,n}});function kT(e){ae.call(this,null,e)}kT.Definition={type:"Sequence",metadata:{generates:!0,changes:!0},params:[{name:"start",type:"number",required:!0},{name:"stop",type:"number",required:!0},{name:"step",type:"number",default:1},{name:"as",type:"string",default:"data"}]};Le(kT,ae,{transform(e,t){if(this.value&&!e.modified())return;const n=t.materialize().fork(t.MOD),i=e.as||"data";return n.rem=this.value?t.rem.concat(this.value):t.rem,this.value=Os(e.start,e.stop,e.step||1).map(s=>{const o={};return o[i]=s,Dt(o)}),n.add=t.add.concat(this.value),n}});function uH(e){ae.call(this,null,e),this.modified(!0)}Le(uH,ae,{transform(e,t){return this.value=t.source,t.changed()?t.fork(t.NO_SOURCE|t.NO_FIELDS):t.StopPropagation}});function BT(e){ae.call(this,null,e)}const hH=["unit0","unit1"];BT.Definition={type:"TimeUnit",metadata:{modifies:!0},params:[{name:"field",type:"field",required:!0},{name:"interval",type:"boolean",default:!0},{name:"units",type:"enum",values:Xb,array:!0},{name:"step",type:"number",default:1},{name:"maxbins",type:"number",default:40},{name:"extent",type:"date",array:!0},{name:"timezone",type:"enum",default:"local",values:["local","utc"]},{name:"as",type:"string",array:!0,length:2,default:hH}]};Le(BT,ae,{transform(e,t){const n=e.field,i=e.interval!==!1,s=e.timezone==="utc",o=this._floor(e,t),c=(s?Mh:Oh)(o.unit).offset,d=e.as||hH,f=d[0],u=d[1],a=o.step;let m=o.start||1/0,y=o.stop||-1/0,p=t.ADD;return(e.modified()||t.changed(t.REM)||t.modified(mi(n)))&&(t=t.reflow(!0),p=t.SOURCE,m=1/0,y=-1/0),t.visit(p,l=>{const b=n(l);let L,E;b==null?(l[f]=null,i&&(l[u]=null)):(l[f]=L=E=o(b),i&&(l[u]=E=c(L,a)),Ly&&(y=E))}),o.start=m,o.stop=y,t.modifies(i?d:f)},_floor(e,t){const n=e.timezone==="utc",{units:i,step:s}=e.units?{units:e.units,step:e.step||1}:vU({extent:e.extent||Ua(t.materialize(t.SOURCE).source,e.field),maxbins:e.maxbins}),o=Kb(i),c=this.value||{},d=(n?gU:hU)(o,s);return d.unit=kt(o),d.units=o,d.step=s,d.start=c.start,d.stop=c.stop,this.value=d}});function gH(e){ae.call(this,Ih(),e)}Le(gH,ae,{transform(e,t){const n=t.dataflow,i=e.field,s=this.value,o=d=>s.set(i(d),d);let c=!0;return e.modified("field")||t.modified(i.fields)?(s.clear(),t.visit(t.SOURCE,o)):t.changed()?(t.visit(t.REM,d=>s.delete(i(d))),t.visit(t.ADD,o)):c=!1,this.modified(c),s.empty>n.cleanThreshold&&n.runAfter(s.clean),t.fork()}});function _H(e){ae.call(this,null,e)}Le(_H,ae,{transform(e,t){(!this.value||e.modified("field")||e.modified("sort")||t.changed()||e.sort&&t.modified(e.sort.fields))&&(this.value=(e.sort?t.source.slice().sort(hf(e.sort)):t.source).map(e.field))}});function Mfe(e,t,n,i){const s=D2[e](t,n);return{init:s.init||Bl,update:function(o,c){c[i]=s.next(o)}}}const D2={row_number:function(){return{next:e=>e.index+1}},rank:function(){let e;return{init:()=>e=1,next:t=>{const n=t.index,i=t.data;return n&&t.compare(i[n-1],i[n])?e=n+1:e}}},dense_rank:function(){let e;return{init:()=>e=1,next:t=>{const n=t.index,i=t.data;return n&&t.compare(i[n-1],i[n])?++e:e}}},percent_rank:function(){const e=D2.rank(),t=e.next;return{init:e.init,next:n=>(t(n)-1)/(n.data.length-1)}},cume_dist:function(){let e;return{init:()=>e=0,next:t=>{const n=t.data,i=t.compare;let s=t.index;if(e0||ce("ntile num must be greater than zero.");const n=D2.cume_dist(),i=n.next;return{init:n.init,next:s=>Math.ceil(t*i(s))}},lag:function(e,t){return t=+t||1,{next:n=>{const i=n.index-t;return i>=0?e(n.data[i]):null}}},lead:function(e,t){return t=+t||1,{next:n=>{const i=n.index+t,s=n.data;return ie(t.data[t.i0])}},last_value:function(e){return{next:t=>e(t.data[t.i1-1])}},nth_value:function(e,t){return t=+t,t>0||ce("nth_value nth must be greater than zero."),{next:n=>{const i=n.i0+(t-1);return it=null,next:n=>{const i=e(n.data[n.index]);return i!=null?t=i:t}}},next_value:function(e){let t,n;return{init:()=>(t=null,n=-1),next:i=>{const s=i.data;return i.index<=n?t:(n=Afe(e,s,i.index))<0?(n=s.length,t=null):t=e(s[n])}}}};function Afe(e,t,n){for(let i=t.length;nd[l]=1)}y(e.sort),t.forEach((p,l)=>{const b=n[l],L=mn(b),E=VU(p,L,s[l]);if(y(b),o.push(E),De(D2,p))c.push(Mfe(p,n[l],i[l],E));else{if(b==null&&p!=="count"&&ce("Null aggregate field specified."),p==="count"){u.push(E);return}m=!1;let S=f[L];S||(S=f[L]=[],S.field=b,a.push(S)),S.push(GU(p,E))}}),(u.length||a.length)&&(this.cell=Cfe(a,u,m)),this.inputs=Object.keys(d)}const yH=pH.prototype;yH.init=function(){this.windows.forEach(e=>e.init()),this.cell&&this.cell.init()};yH.update=function(e,t){const n=this.cell,i=this.windows,s=e.data,o=i&&i.length;let c;if(n){for(c=e.p0;cYU(f,f.field));const i={num:0,agg:null,store:!1,count:t};if(!n)for(var s=e.length,o=i.agg=Array(s),c=0;cthis.group(s(d));let c=this.state;(!c||n)&&(c=this.state=new pH(e)),n||t.modified(c.inputs)?(this.value={},t.visit(t.SOURCE,d=>o(d).add(d))):(t.visit(t.REM,d=>o(d).remove(d)),t.visit(t.ADD,d=>o(d).add(d)));for(let d=0,f=this._mlen;d0&&!s(o[n],o[n-1])&&(e.i0=t.left(o,o[n])),itypeof Image<"u"?Image:null;function IT(e,t,n){const i=e-t+n*2;return e?i>0?i:1:0}const Hfe="identity",Zu="linear",Wo="log",C0="pow",R0="sqrt",hm="symlog",Ud="time",Hd="utc",ka="sequential",Ah="diverging",Ju="quantile",gm="quantize",_m="threshold",OT="ordinal",VL="point",mH="band",MT="bin-ordinal",Dn="continuous",P0="discrete",D0="discretizing",cr="interpolating",AT="temporal";function zfe(e){return function(t){let n=t[0],i=t[1],s;return i=i&&n[f]<=s&&(o<0&&(o=f),c=f);if(!(o<0))return i=e.invertExtent(n[o]),s=e.invertExtent(n[c]),[i[0]===void 0?i[1]:i[0],s[1]===void 0?s[0]:s[1]]}}function NT(){const e=eb().unknown(void 0),t=e.domain,n=e.range;let i=[0,1],s,o,c=!1,d=0,f=0,u=.5;delete e.unknown;function a(){const m=t().length,y=i[1]b+s*E);return n(y?L.reverse():L)}return e.domain=function(m){return arguments.length?(t(m),a()):t()},e.range=function(m){return arguments.length?(i=[+m[0],+m[1]],a()):i.slice()},e.rangeRound=function(m){return i=[+m[0],+m[1]],c=!0,a()},e.bandwidth=function(){return o},e.step=function(){return s},e.round=function(m){return arguments.length?(c=!!m,a()):c},e.padding=function(m){return arguments.length?(f=Math.max(0,Math.min(1,m)),d=f,a()):d},e.paddingInner=function(m){return arguments.length?(d=Math.max(0,Math.min(1,m)),a()):d},e.paddingOuter=function(m){return arguments.length?(f=Math.max(0,Math.min(1,m)),a()):f},e.align=function(m){return arguments.length?(u=Math.max(0,Math.min(1,m)),a()):u},e.invertRange=function(m){if(m[0]==null||m[1]==null)return;const y=i[1]i[1-y])))return E=Math.max(0,Sp(p,b)-1),S=b===L?E:Sp(p,L)-1,b-p[E]>o+1e-10&&++E,y&&(x=E,E=l-S,S=l-x),E>S?void 0:t().slice(E,S+1)},e.invert=function(m){const y=e.invertRange([m,m]);return y&&y[0]},e.copy=function(){return NT().domain(t()).range(i).round(c).paddingInner(d).paddingOuter(f).align(u)},a()}function wH(e){const t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,e.copy=function(){return wH(t())},e}function qfe(){return wH(NT().paddingInner(1))}var Vfe=Array.prototype.map;function Gfe(e){return Vfe.call(e,_i)}const Wfe=Array.prototype.slice;function LH(){let e=[],t=[];function n(i){return i==null||i!==i?void 0:t[(L0(e,i)-1)%t.length]}return n.domain=function(i){return arguments.length?(e=Gfe(i),n):e.slice()},n.range=function(i){return arguments.length?(t=Wfe.call(i),n):t.slice()},n.tickFormat=function(i,s){return MD(e[0],kt(e),i??10,s)},n.copy=function(){return LH().domain(n.domain()).range(n.range())},n}const by=new Map,bH=Symbol("vega_scale");function TH(e){return e[bH]=!0,e}function Yfe(e){return e&&e[bH]===!0}function Xfe(e,t,n){const i=function(){const o=t();return o.invertRange||(o.invertRange=o.invert?zfe(o):o.invertExtent?$fe(o):void 0),o.type=e,TH(o)};return i.metadata=zr(Se(n)),i}function Nt(e,t,n){return arguments.length>1?(by.set(e,Xfe(e,t,n)),this):vH(e)?by.get(e):void 0}Nt(Hfe,AD);Nt(Zu,U4,Dn);Nt(Wo,CD,[Dn,Wo]);Nt(C0,sb,Dn);Nt(R0,Fae,Dn);Nt(hm,RD,Dn);Nt(Ud,XD,[Dn,AT]);Nt(Hd,qoe,[Dn,AT]);Nt(ka,cb,[Dn,cr]);Nt(`${ka}-${Zu}`,cb,[Dn,cr]);Nt(`${ka}-${Wo}`,KD,[Dn,cr,Wo]);Nt(`${ka}-${C0}`,db,[Dn,cr]);Nt(`${ka}-${R0}`,Voe,[Dn,cr]);Nt(`${ka}-${hm}`,ZD,[Dn,cr]);Nt(`${Ah}-${Zu}`,JD,[Dn,cr]);Nt(`${Ah}-${Wo}`,QD,[Dn,cr,Wo]);Nt(`${Ah}-${C0}`,fb,[Dn,cr]);Nt(`${Ah}-${R0}`,Goe,[Dn,cr]);Nt(`${Ah}-${hm}`,ej,[Dn,cr]);Nt(Ju,PD,[D0,Ju]);Nt(gm,DD,D0);Nt(_m,jD,D0);Nt(MT,LH,[P0,D0]);Nt(OT,eb,P0);Nt(mH,NT,P0);Nt(VL,qfe,P0);function vH(e){return by.has(e)}function _f(e,t){const n=by.get(e);return n&&n.metadata[t]}function CT(e){return _f(e,Dn)}function Qu(e){return _f(e,P0)}function GL(e){return _f(e,D0)}function EH(e){return _f(e,Wo)}function Kfe(e){return _f(e,AT)}function SH(e){return _f(e,cr)}function xH(e){return _f(e,Ju)}const Zfe=["clamp","base","constant","exponent"];function kH(e,t){const n=t[0],i=kt(t)-n;return function(s){return e(n+s*i)}}function pm(e,t,n){return R7(RT(t||"rgb",n),e)}function BH(e,t){const n=new Array(t),i=t+1;for(let s=0;se[d]?c[d](e[d]()):0),c)}function RT(e,t){const n=Pte[Jfe(e)];return t!=null&&n&&n.gamma?n.gamma(t):n}function Jfe(e){return"interpolate"+e.toLowerCase().split("-").map(t=>t[0].toUpperCase()+t.slice(1)).join("")}const Qfe={blues:"cfe1f2bed8eca8cee58fc1de74b2d75ba3cf4592c63181bd206fb2125ca40a4a90",greens:"d3eecdc0e6baabdda594d3917bc77d60ba6c46ab5e329a512089430e7735036429",greys:"e2e2e2d4d4d4c4c4c4b1b1b19d9d9d8888887575756262624d4d4d3535351e1e1e",oranges:"fdd8b3fdc998fdb87bfda55efc9244f87f2cf06b18e4580bd14904b93d029f3303",purples:"e2e1efd4d4e8c4c5e0b4b3d6a3a0cc928ec3827cb97566ae684ea25c3696501f8c",reds:"fdc9b4fcb49afc9e80fc8767fa7051f6573fec3f2fdc2a25c81b1db21218970b13",blueGreen:"d5efedc1e8e0a7ddd18bd2be70c6a958ba9144ad77319c5d2089460e7736036429",bluePurple:"ccddecbad0e4a8c2dd9ab0d4919cc98d85be8b6db28a55a6873c99822287730f71",greenBlue:"d3eecec5e8c3b1e1bb9bd8bb82cec269c2ca51b2cd3c9fc7288abd1675b10b60a1",orangeRed:"fddcaffdcf9bfdc18afdad77fb9562f67d53ee6545e24932d32d1ebf130da70403",purpleBlue:"dbdaebc8cee4b1c3de97b7d87bacd15b9fc93a90c01e7fb70b70ab056199045281",purpleBlueGreen:"dbd8eac8cee4b0c3de93b7d872acd1549fc83892bb1c88a3097f8702736b016353",purpleRed:"dcc9e2d3b3d7ce9eccd186c0da6bb2e14da0e23189d91e6fc61159ab07498f023a",redPurple:"fccfccfcbec0faa9b8f98faff571a5ec539ddb3695c41b8aa908808d0179700174",yellowGreen:"e4f4acd1eca0b9e2949ed68880c97c62bb6e47aa5e3297502083440e723b036034",yellowOrangeBrown:"feeaa1fedd84fecc63feb746fca031f68921eb7215db5e0bc54c05ab3d038f3204",yellowOrangeRed:"fee087fed16ffebd59fea849fd903efc7335f9522bee3423de1b20ca0b22af0225",blueOrange:"134b852f78b35da2cb9dcae1d2e5eff2f0ebfce0bafbbf74e8932fc5690d994a07",brownBlueGreen:"704108a0651ac79548e3c78af3e6c6eef1eac9e9e48ed1c74da79e187a72025147",purpleGreen:"5b1667834792a67fb6c9aed3e6d6e8eff0efd9efd5aedda971bb75368e490e5e29",purpleOrange:"4114696647968f83b7b9b4d6dadbebf3eeeafce0bafbbf74e8932fc5690d994a07",redBlue:"8c0d25bf363adf745ef4ae91fbdbc9f2efeed2e5ef9dcae15da2cb2f78b3134b85",redGrey:"8c0d25bf363adf745ef4ae91fcdccbfaf4f1e2e2e2c0c0c0969696646464343434",yellowGreenBlue:"eff9bddbf1b4bde5b594d5b969c5be45b4c22c9ec02182b82163aa23479c1c3185",redYellowBlue:"a50026d4322cf16e43fcac64fedd90faf8c1dcf1ecabd6e875abd04a74b4313695",redYellowGreen:"a50026d4322cf16e43fcac63fedd8df9f7aed7ee8ea4d86e64bc6122964f006837",pinkYellowGreen:"8e0152c0267edd72adf0b3d6faddedf5f3efe1f2cab6de8780bb474f9125276419",spectral:"9e0142d13c4bf0704afcac63fedd8dfbf8b0e0f3a1a9dda269bda94288b55e4fa2",viridis:"440154470e61481a6c482575472f7d443a834144873d4e8a39568c35608d31688e2d708e2a788e27818e23888e21918d1f988b1fa08822a8842ab07f35b77943bf7154c56866cc5d7ad1518fd744a5db36bcdf27d2e21be9e51afde725",magma:"0000040404130b0924150e3720114b2c11603b0f704a107957157e651a80721f817f24828c29819a2e80a8327db6377ac43c75d1426fde4968e95462f1605df76f5cfa7f5efc8f65fe9f6dfeaf78febf84fece91fddea0fcedaffcfdbf",inferno:"0000040403130c0826170c3b240c4f330a5f420a68500d6c5d126e6b176e781c6d86216b932667a12b62ae305cbb3755c73e4cd24644dd513ae65c30ed6925f3771af8850ffb9506fca50afcb519fac62df6d645f2e661f3f484fcffa4",plasma:"0d088723069033059742039d5002a25d01a66a00a87801a88405a7900da49c179ea72198b12a90ba3488c33d80cb4779d35171da5a69e16462e76e5bed7953f2834cf68f44fa9a3dfca636fdb32ffec029fcce25f9dc24f5ea27f0f921",cividis:"00205100235800265d002961012b65042e670831690d346b11366c16396d1c3c6e213f6e26426e2c456e31476e374a6e3c4d6e42506e47536d4c566d51586e555b6e5a5e6e5e616e62646f66676f6a6a706e6d717270717573727976737c79747f7c75827f758682768985778c8877908b78938e789691789a94789e9778a19b78a59e77a9a177aea575b2a874b6ab73bbaf71c0b26fc5b66dc9b96acebd68d3c065d8c462ddc85fe2cb5ce7cf58ebd355f0d652f3da4ff7de4cfae249fce647",rainbow:"6e40aa883eb1a43db3bf3cafd83fa4ee4395fe4b83ff576eff6659ff7847ff8c38f3a130e2b72fcfcc36bee044aff05b8ff4576ff65b52f6673af27828ea8d1ddfa319d0b81cbecb23abd82f96e03d82e14c6edb5a5dd0664dbf6e40aa",sinebow:"ff4040fc582af47218e78d0bd5a703bfbf00a7d5038de70b72f41858fc2a40ff402afc5818f4720be78d03d5a700bfbf03a7d50b8de71872f42a58fc4040ff582afc7218f48d0be7a703d5bf00bfd503a7e70b8df41872fc2a58ff4040",turbo:"23171b32204a3e2a71453493493eae4b49c54a53d7485ee44569ee4074f53c7ff8378af93295f72e9ff42ba9ef28b3e926bce125c5d925cdcf27d5c629dcbc2de3b232e9a738ee9d3ff39347f68950f9805afc7765fd6e70fe667cfd5e88fc5795fb51a1f84badf545b9f140c5ec3cd0e637dae034e4d931ecd12ef4c92bfac029ffb626ffad24ffa223ff9821ff8d1fff821dff771cfd6c1af76118f05616e84b14df4111d5380fcb2f0dc0260ab61f07ac1805a313029b0f00950c00910b00",browns:"eedbbdecca96e9b97ae4a865dc9856d18954c7784cc0673fb85536ad44339f3632",tealBlues:"bce4d89dd3d181c3cb65b3c245a2b9368fae347da0306a932c5985",teals:"bbdfdfa2d4d58ac9c975bcbb61b0af4da5a43799982b8b8c1e7f7f127273006667",warmGreys:"dcd4d0cec5c1c0b8b4b3aaa7a59c9998908c8b827f7e7673726866665c5a59504e",goldGreen:"f4d166d5ca60b6c35c98bb597cb25760a6564b9c533f8f4f33834a257740146c36",goldOrange:"f4d166f8be5cf8aa4cf5983bf3852aef701be2621fd65322c54923b142239e3a26",goldRed:"f4d166f6be59f9aa51fc964ef6834bee734ae56249db5247cf4244c43141b71d3e",lightGreyRed:"efe9e6e1dad7d5cbc8c8bdb9bbaea9cd967ddc7b43e15f19df4011dc000b",lightGreyTeal:"e4eaead6dcddc8ced2b7c2c7a6b4bc64b0bf22a6c32295c11f85be1876bc",lightMulti:"e0f1f2c4e9d0b0de9fd0e181f6e072f6c053f3993ef77440ef4a3c",lightOrange:"f2e7daf7d5baf9c499fab184fa9c73f68967ef7860e8645bde515bd43d5b",lightTealBlue:"e3e9e0c0dccf9aceca7abfc859afc0389fb9328dad2f7ca0276b95255988",darkBlue:"3232322d46681a5c930074af008cbf05a7ce25c0dd38daed50f3faffffff",darkGold:"3c3c3c584b37725e348c7631ae8b2bcfa424ecc31ef9de30fff184ffffff",darkGreen:"3a3a3a215748006f4d048942489e4276b340a6c63dd2d836ffeb2cffffaa",darkMulti:"3737371f5287197d8c29a86995ce3fffe800ffffff",darkRed:"3434347036339e3c38cc4037e75d1eec8620eeab29f0ce32ffeb2c"},eue={category10:"1f77b4ff7f0e2ca02cd627289467bd8c564be377c27f7f7fbcbd2217becf",category20:"1f77b4aec7e8ff7f0effbb782ca02c98df8ad62728ff98969467bdc5b0d58c564bc49c94e377c2f7b6d27f7f7fc7c7c7bcbd22dbdb8d17becf9edae5",category20b:"393b795254a36b6ecf9c9ede6379398ca252b5cf6bcedb9c8c6d31bd9e39e7ba52e7cb94843c39ad494ad6616be7969c7b4173a55194ce6dbdde9ed6",category20c:"3182bd6baed69ecae1c6dbefe6550dfd8d3cfdae6bfdd0a231a35474c476a1d99bc7e9c0756bb19e9ac8bcbddcdadaeb636363969696bdbdbdd9d9d9",tableau10:"4c78a8f58518e4575672b7b254a24beeca3bb279a2ff9da69d755dbab0ac",tableau20:"4c78a89ecae9f58518ffbf7954a24b88d27ab79a20f2cf5b43989483bcb6e45756ff9d9879706ebab0acd67195fcbfd2b279a2d6a5c99e765fd8b5a5",accent:"7fc97fbeaed4fdc086ffff99386cb0f0027fbf5b17666666",dark2:"1b9e77d95f027570b3e7298a66a61ee6ab02a6761d666666",paired:"a6cee31f78b4b2df8a33a02cfb9a99e31a1cfdbf6fff7f00cab2d66a3d9affff99b15928",pastel1:"fbb4aeb3cde3ccebc5decbe4fed9a6ffffcce5d8bdfddaecf2f2f2",pastel2:"b3e2cdfdcdaccbd5e8f4cae4e6f5c9fff2aef1e2cccccccc",set1:"e41a1c377eb84daf4a984ea3ff7f00ffff33a65628f781bf999999",set2:"66c2a5fc8d628da0cbe78ac3a6d854ffd92fe5c494b3b3b3",set3:"8dd3c7ffffb3bebadafb807280b1d3fdb462b3de69fccde5d9d9d9bc80bdccebc5ffed6f"};function IH(e){const t=e.length/6|0,n=new Array(t);for(let i=0;ipm(IH(e)));function PT(e,t){return e=e&&e.toLowerCase(),arguments.length>1?(hI[e]=t,this):hI[e]}const q_="symbol",tue="discrete",nue="gradient",iue=e=>ue(e)?e.map(t=>String(t)):String(e),sue=(e,t)=>e[1]-t[1],rue=(e,t)=>t[1]-e[1];function DT(e,t,n){let i;return Yt(t)&&(e.bins&&(t=Math.max(t,e.bins.length)),n!=null&&(t=Math.min(t,Math.floor(M0(e.domain())/n||1)))),ke(t)&&(i=t.step,t=t.interval),xe(t)&&(t=e.type===Ud?Oh(t):e.type==Hd?Mh(t):ce("Only time and utc scales accept interval strings."),i&&(t=t.every(i))),t}function MH(e,t,n){let i=e.range(),s=i[0],o=kt(i),c=sue;if(s>o&&(i=o,o=s,s=i,c=rue),s=Math.floor(s),o=Math.ceil(o),t=t.map(d=>[d,e(d)]).filter(d=>s<=d[1]&&d[1]<=o).sort(c).map(d=>d[0]),n>0&&t.length>1){const d=[t[0],kt(t)];for(;t.length>n&&t.length>=3;)t=t.filter((f,u)=>!(u%2));t.length<3&&(t=d)}return t}function jT(e,t){return e.bins?MH(e,e.bins):e.ticks?e.ticks(t):e.domain()}function AH(e,t,n,i,s,o){const c=t.type;let d=iue;if(c===Ud||s===Ud)d=e.timeFormat(i);else if(c===Hd||s===Hd)d=e.utcFormat(i);else if(EH(c)){const f=e.formatFloat(i);if(o||t.bins)d=f;else{const u=NH(t,n,!1);d=a=>u(a)?f(a):""}}else if(t.tickFormat){const f=t.domain();d=e.formatSpan(f[0],f[f.length-1],n,i)}else i&&(d=e.format(i));return d}function NH(e,t,n){const i=jT(e,t),s=e.base(),o=Math.log(s),c=Math.max(1,s*t/i.length),d=f=>{let u=f/Math.pow(s,Math.round(Math.log(f)/o));return u*s1?i[1]-i[0]:i[0],c;for(c=1;cWL[e.type]||e.bins;function PH(e,t,n,i,s,o,c){const d=CH[t.type]&&o!==Ud&&o!==Hd?aue(e,t,s):AH(e,t,n,s,o,c);return i===q_&&cue(t)?due(d):i===tue?fue(d):uue(d)}const due=e=>(t,n,i)=>{const s=gI(i[n+1],gI(i.max,1/0)),o=_I(t,e),c=_I(s,e);return o&&c?o+" – "+c:c?"< "+c:"≥ "+o},gI=(e,t)=>e??t,fue=e=>(t,n)=>n?e(t):null,uue=e=>t=>e(t),_I=(e,t)=>Number.isFinite(e)?t(e):null;function hue(e){const t=e.domain(),n=t.length-1;let i=+t[0],s=+kt(t),o=s-i;if(e.type===_m){const c=n?o/n:.1;i-=c,s+=c,o=s-i}return c=>(c-i)/o}function gue(e,t,n,i){const s=i||t.type;return xe(n)&&Kfe(s)&&(n=n.replace(/%a/g,"%A").replace(/%b/g,"%B")),!n&&s===Ud?e.timeFormat("%A, %d %B %Y, %X"):!n&&s===Hd?e.utcFormat("%A, %d %B %Y, %X UTC"):PH(e,t,5,null,n,i,!0)}function DH(e,t,n){n=n||{};const i=Math.max(3,n.maxlen||7),s=gue(e,t,n.format,n.formatType);if(GL(t.type)){const o=RH(t).slice(1).map(s),c=o.length;return`${c} boundar${c===1?"y":"ies"}: ${o.join(", ")}`}else if(Qu(t.type)){const o=t.domain(),c=o.length,d=c>i?o.slice(0,i-2).map(s).join(", ")+", ending with "+o.slice(-1).map(s):o.map(s).join(", ");return`${c} value${c===1?"":"s"}: ${d}`}else{const o=t.domain();return`values from ${s(o[0])} to ${s(kt(o))}`}}let jH=0;function _ue(){jH=0}const Ty="p_";function UT(e){return e&&e.gradient}function UH(e,t,n){const i=e.gradient;let s=e.id,o=i==="radial"?Ty:"";return s||(s=e.id="gradient_"+jH++,i==="radial"?(e.x1=na(e.x1,.5),e.y1=na(e.y1,.5),e.r1=na(e.r1,0),e.x2=na(e.x2,.5),e.y2=na(e.y2,.5),e.r2=na(e.r2,.5),o=Ty):(e.x1=na(e.x1,0),e.y1=na(e.y1,0),e.x2=na(e.x2,1),e.y2=na(e.y2,0))),t[s]=e,"url("+(n||"")+"#"+o+s+")"}function na(e,t){return e??t}function HH(e,t){var n=[],i;return i={gradient:"linear",x1:e?e[0]:0,y1:e?e[1]:0,x2:t?t[0]:1,y2:t?t[1]:0,stops:n,stop:function(s,o){return n.push({offset:s,color:o}),i}}}const pI={basis:{curve:sle},"basis-closed":{curve:rle},"basis-open":{curve:ale},bundle:{curve:ole,tension:"beta",value:.85},cardinal:{curve:lle,tension:"tension",value:0},"cardinal-open":{curve:dle,tension:"tension",value:0},"cardinal-closed":{curve:cle,tension:"tension",value:0},"catmull-rom":{curve:fle,tension:"alpha",value:.5},"catmull-rom-closed":{curve:ule,tension:"alpha",value:.5},"catmull-rom-open":{curve:hle,tension:"alpha",value:.5},linear:{curve:ub},"linear-closed":{curve:gle},monotone:{horizontal:ple,vertical:_le},natural:{curve:yle},step:{curve:mle},"step-after":{curve:Lle},"step-before":{curve:wle}};function HT(e,t,n){var i=De(pI,e)&&pI[e],s=null;return i&&(s=i.curve||i[t||"vertical"],i.tension&&n!=null&&(s=s[i.tension](n))),s}const pue={m:2,l:2,h:1,v:1,z:0,c:6,s:4,q:4,t:2,a:7},yue=/[mlhvzcsqta]([^mlhvzcsqta]+|$)/gi,mue=/^[+-]?(([0-9]*\.[0-9]+)|([0-9]+\.)|([0-9]+))([eE][+-]?[0-9]+)?/,wue=/^((\s+,?\s*)|(,\s*))/,Lue=/^[01]/;function eh(e){const t=[];return(e.match(yue)||[]).forEach(i=>{let s=i[0];const o=s.toLowerCase(),c=pue[o],d=bue(o,c,i.slice(1).trim()),f=d.length;if(f1&&(b=Math.sqrt(b),n*=b,i*=b);const L=y/n,E=m/n,S=-m/i,x=y/i,F=L*d+E*f,k=S*d+x*f,M=L*e+E*t,O=S*e+x*t;let P=1/((M-F)*(M-F)+(O-k)*(O-k))-.25;P<0&&(P=0);let j=Math.sqrt(P);o==s&&(j=-j);const R=.5*(F+M)-j*(O-k),H=.5*(k+O)+j*(M-F),z=Math.atan2(k-H,F-R);let $=Math.atan2(O-H,M-R)-z;$<0&&o===1?$+=ma:$>0&&o===0&&($-=ma);const W=Math.ceil(Math.abs($/(sd+.001))),X=[];for(let G=0;G+e}function Jg(e,t,n){return Math.max(t,Math.min(e,n))}function qH(){var e=kue,t=Bue,n=Fue,i=Iue,s=ho(0),o=s,c=s,d=s,f=null;function u(a,m,y){var p,l=m??+e.call(this,a),b=y??+t.call(this,a),L=+n.call(this,a),E=+i.call(this,a),S=Math.min(L,E)/2,x=Jg(+s.call(this,a),0,S),F=Jg(+o.call(this,a),0,S),k=Jg(+c.call(this,a),0,S),M=Jg(+d.call(this,a),0,S);if(f||(f=p=A4()),x<=0&&F<=0&&k<=0&&M<=0)f.rect(l,b,L,E);else{var O=l+L,C=b+E;f.moveTo(l+x,b),f.lineTo(O-F,b),f.bezierCurveTo(O-gl*F,b,O,b+gl*F,O,b+F),f.lineTo(O,C-M),f.bezierCurveTo(O,C-gl*M,O-gl*M,C,O-M,C),f.lineTo(l+k,C),f.bezierCurveTo(l+gl*k,C,l,C-gl*k,l,C-k),f.lineTo(l,b+x),f.bezierCurveTo(l,b+gl*x,l+gl*x,b,l+x,b),f.closePath()}if(p)return f=null,p+""||null}return u.x=function(a){return arguments.length?(e=ho(a),u):e},u.y=function(a){return arguments.length?(t=ho(a),u):t},u.width=function(a){return arguments.length?(n=ho(a),u):n},u.height=function(a){return arguments.length?(i=ho(a),u):i},u.cornerRadius=function(a,m,y,p){return arguments.length?(s=ho(a),o=m!=null?ho(m):s,d=y!=null?ho(y):s,c=p!=null?ho(p):o,u):s},u.context=function(a){return arguments.length?(f=a??null,u):f},u}function VH(){var e,t,n,i,s=null,o,c,d,f;function u(m,y,p){const l=p/2;if(o){var b=d-y,L=m-c;if(b||L){var E=Math.sqrt(b*b+L*L),S=(b/=E)*f,x=(L/=E)*f,F=Math.atan2(L,b);s.moveTo(c-S,d-x),s.lineTo(m-b*l,y-L*l),s.arc(m,y,l,F-Math.PI,F),s.lineTo(c+S,d+x),s.arc(c,d,f,F,F+Math.PI)}else s.arc(m,y,l,0,ma);s.closePath()}else o=1;c=m,d=y,f=l}function a(m){var y,p=m.length,l,b=!1,L;for(s==null&&(s=L=A4()),y=0;y<=p;++y)!(ye.x||0,H0=e=>e.y||0,Oue=e=>e.width||0,Mue=e=>e.height||0,Aue=e=>(e.x||0)+(e.width||0),Nue=e=>(e.y||0)+(e.height||0),Cue=e=>e.startAngle||0,Rue=e=>e.endAngle||0,Pue=e=>e.padAngle||0,Due=e=>e.innerRadius||0,jue=e=>e.outerRadius||0,Uue=e=>e.cornerRadius||0,Hue=e=>j0(e.cornerRadiusTopLeft,e.cornerRadius)||0,zue=e=>j0(e.cornerRadiusTopRight,e.cornerRadius)||0,$ue=e=>j0(e.cornerRadiusBottomRight,e.cornerRadius)||0,que=e=>j0(e.cornerRadiusBottomLeft,e.cornerRadius)||0,Vue=e=>j0(e.size,64),Gue=e=>e.size||1,ym=e=>e.defined!==!1,Wue=e=>$H(e.shape||"circle"),Yue=tle().startAngle(Cue).endAngle(Rue).padAngle(Pue).innerRadius(Due).outerRadius(jue).cornerRadius(Uue),Xue=oj().x(U0).y1(H0).y0(Nue).defined(ym),Kue=oj().y(H0).x1(U0).x0(Aue).defined(ym),Zue=aj().x(U0).y(H0).defined(ym),Jue=qH().x(U0).y(H0).width(Oue).height(Mue).cornerRadius(Hue,zue,$ue,que),Que=ile().type(Wue).size(Vue),ehe=VH().x(U0).y(H0).defined(ym).size(Gue);function zT(e){return e.cornerRadius||e.cornerRadiusTopLeft||e.cornerRadiusTopRight||e.cornerRadiusBottomRight||e.cornerRadiusBottomLeft}function the(e,t){return Yue.context(e)(t)}function nhe(e,t){const n=t[0],i=n.interpolate||"linear";return(n.orient==="horizontal"?Kue:Xue).curve(HT(i,n.orient,n.tension)).context(e)(t)}function ihe(e,t){const n=t[0],i=n.interpolate||"linear";return Zue.curve(HT(i,n.orient,n.tension)).context(e)(t)}function Nh(e,t,n,i){return Jue.context(e)(t,n,i)}function she(e,t){return(t.mark.shape||t.shape).context(e)(t)}function rhe(e,t){return Que.context(e)(t)}function ahe(e,t){return ehe.context(e)(t)}var GH=1;function WH(){GH=1}function $T(e,t,n){var i=t.clip,s=e._defs,o=t.clip_id||(t.clip_id="clip"+GH++),c=s.clipping[o]||(s.clipping[o]={id:o});return ft(i)?c.path=i(null):zT(n)?c.path=Nh(null,n,0,0):(c.width=n.width||0,c.height=n.height||0),"url(#"+o+")"}function En(e){this.clear(),e&&this.union(e)}En.prototype={clone(){return new En(this)},clear(){return this.x1=+Number.MAX_VALUE,this.y1=+Number.MAX_VALUE,this.x2=-Number.MAX_VALUE,this.y2=-Number.MAX_VALUE,this},empty(){return this.x1===+Number.MAX_VALUE&&this.y1===+Number.MAX_VALUE&&this.x2===-Number.MAX_VALUE&&this.y2===-Number.MAX_VALUE},equals(e){return this.x1===e.x1&&this.y1===e.y1&&this.x2===e.x2&&this.y2===e.y2},set(e,t,n,i){return nthis.x2&&(this.x2=e),t>this.y2&&(this.y2=t),this},expand(e){return this.x1-=e,this.y1-=e,this.x2+=e,this.y2+=e,this},round(){return this.x1=Math.floor(this.x1),this.y1=Math.floor(this.y1),this.x2=Math.ceil(this.x2),this.y2=Math.ceil(this.y2),this},scale(e){return this.x1*=e,this.y1*=e,this.x2*=e,this.y2*=e,this},translate(e,t){return this.x1+=e,this.x2+=e,this.y1+=t,this.y2+=t,this},rotate(e,t,n){const i=this.rotatedPoints(e,t,n);return this.clear().add(i[0],i[1]).add(i[2],i[3]).add(i[4],i[5]).add(i[6],i[7])},rotatedPoints(e,t,n){var{x1:i,y1:s,x2:o,y2:c}=this,d=Math.cos(e),f=Math.sin(e),u=t-t*d+n*f,a=n-t*f-n*d;return[d*i-f*s+u,f*i+d*s+a,d*i-f*c+u,f*i+d*c+a,d*o-f*s+u,f*o+d*s+a,d*o-f*c+u,f*o+d*c+a]},union(e){return e.x1this.x2&&(this.x2=e.x2),e.y2>this.y2&&(this.y2=e.y2),this},intersect(e){return e.x1>this.x1&&(this.x1=e.x1),e.y1>this.y1&&(this.y1=e.y1),e.x2=e.x2&&this.y1<=e.y1&&this.y2>=e.y2},alignsWith(e){return e&&(this.x1==e.x1||this.x2==e.x2||this.y1==e.y1||this.y2==e.y2)},intersects(e){return e&&!(this.x2e.x2||this.y2e.y2)},contains(e,t){return!(ethis.x2||tthis.y2)},width(){return this.x2-this.x1},height(){return this.y2-this.y1}};function mm(e){this.mark=e,this.bounds=this.bounds||new En}function wm(e){mm.call(this,e),this.items=this.items||[]}Le(wm,mm);function qT(e){this._pending=0,this._loader=e||am()}function LI(e){e._pending+=1}function a1(e){e._pending-=1}qT.prototype={pending(){return this._pending},sanitizeURL(e){const t=this;return LI(t),t._loader.sanitize(e,{context:"href"}).then(n=>(a1(t),n)).catch(()=>(a1(t),null))},loadImage(e){const t=this,n=Ufe();return LI(t),t._loader.sanitize(e,{context:"image"}).then(i=>{const s=i.href;if(!s||!n)throw{url:s};const o=new n,c=De(i,"crossOrigin")?i.crossOrigin:"anonymous";return c!=null&&(o.crossOrigin=c),o.onload=()=>a1(t),o.onerror=()=>a1(t),o.src=s,o}).catch(i=>(a1(t),{complete:!1,width:0,height:0,src:i&&i.url||""}))},ready(){const e=this;return new Promise(t=>{function n(i){e.pending()?setTimeout(()=>{n(!0)},10):t(i)}n(!1)})}};function el(e,t,n){if(t.stroke&&t.opacity!==0&&t.strokeOpacity!==0){const i=t.strokeWidth!=null?+t.strokeWidth:1;e.expand(i+(n?ohe(t,i):0))}return e}function ohe(e,t){return e.strokeJoin&&e.strokeJoin!=="miter"?0:t}const lhe=ma-1e-8;let Lm,V_,G_,md,YL,W_,XL,KL;const Il=(e,t)=>Lm.add(e,t),Y_=(e,t)=>Il(V_=e,G_=t),bI=e=>Il(e,Lm.y1),TI=e=>Il(Lm.x1,e),rd=(e,t)=>YL*e+XL*t,ad=(e,t)=>W_*e+KL*t,Mw=(e,t)=>Il(rd(e,t),ad(e,t)),Aw=(e,t)=>Y_(rd(e,t),ad(e,t));function z0(e,t){return Lm=e,t?(md=t*ic,YL=KL=Math.cos(md),W_=Math.sin(md),XL=-W_):(YL=KL=1,md=W_=XL=0),che}const che={beginPath(){},closePath(){},moveTo:Aw,lineTo:Aw,rect(e,t,n,i){md?(Mw(e+n,t),Mw(e+n,t+i),Mw(e,t+i),Aw(e,t)):(Il(e+n,t+i),Y_(e,t))},quadraticCurveTo(e,t,n,i){const s=rd(e,t),o=ad(e,t),c=rd(n,i),d=ad(n,i);vI(V_,s,c,bI),vI(G_,o,d,TI),Y_(c,d)},bezierCurveTo(e,t,n,i,s,o){const c=rd(e,t),d=ad(e,t),f=rd(n,i),u=ad(n,i),a=rd(s,o),m=ad(s,o);EI(V_,c,f,a,bI),EI(G_,d,u,m,TI),Y_(a,m)},arc(e,t,n,i,s,o){if(i+=md,s+=md,V_=n*Math.cos(s)+e,G_=n*Math.sin(s)+t,Math.abs(s-i)>lhe)Il(e-n,t-n),Il(e+n,t+n);else{const c=u=>Il(n*Math.cos(u)+e,n*Math.sin(u)+t);let d,f;if(c(i),c(s),s!==i)if(i=i%ma,i<0&&(i+=ma),s=s%ma,s<0&&(s+=ma),ss;++f,d-=sd)c(d);else for(d=i-i%sd+sd,f=0;f<4&&dTue?(a=c*c+d*o,a>=0&&(a=Math.sqrt(a),f=(-c+a)/o,u=(-c-a)/o)):f=.5*d/c,0y)return!1;b>m&&(m=b)}else if(p>0){if(b0?(e.globalAlpha=n,e.fillStyle=KH(e,t,t.fill),!0):!1}var fhe=[];function nh(e,t,n){var i=(i=t.strokeWidth)!=null?i:1;return i<=0?!1:(n*=t.strokeOpacity==null?1:t.strokeOpacity,n>0?(e.globalAlpha=n,e.strokeStyle=KH(e,t,t.stroke),e.lineWidth=i,e.lineCap=t.strokeCap||"butt",e.lineJoin=t.strokeJoin||"miter",e.miterLimit=t.strokeMiterLimit||10,e.setLineDash&&(e.setLineDash(t.strokeDash||fhe),e.lineDashOffset=t.strokeDashOffset||0),!0):!1)}function uhe(e,t){return e.zindex-t.zindex||e.index-t.index}function WT(e){if(!e.zdirty)return e.zitems;var t=e.items,n=[],i,s,o;for(s=0,o=t.length;s=0;)if(i=t(n[s]))return i;if(n===o){for(n=e.items,s=n.length;--s>=0;)if(!n[s].zindex&&(i=t(n[s])))return i}return null}function YT(e){return function(t,n,i){qr(n,s=>{(!i||i.intersects(s.bounds))&&ZH(e,t,s,s)})}}function hhe(e){return function(t,n,i){n.items.length&&(!i||i.intersects(n.bounds))&&ZH(e,t,n.items[0],n.items)}}function ZH(e,t,n,i){var s=n.opacity==null?1:n.opacity;s!==0&&(e(t,i)||(th(t,n),n.fill&&vy(t,n,s)&&t.fill(),n.stroke&&nh(t,n,s)&&t.stroke()))}function bm(e){return e=e||sr,function(t,n,i,s,o,c){return i*=t.pixelRatio,s*=t.pixelRatio,Ey(n,d=>{const f=d.bounds;if(!(f&&!f.contains(o,c)||!f)&&e(t,d,i,s,o,c))return d})}}function $0(e,t){return function(n,i,s,o){var c=Array.isArray(i)?i[0]:i,d=t??c.fill,f=c.stroke&&n.isPointInStroke,u,a;return f&&(u=c.strokeWidth,a=c.strokeCap,n.lineWidth=u??1,n.lineCap=a??"butt"),e(n,i)?!1:d&&n.isPointInPath(s,o)||f&&n.isPointInStroke(s,o)}}function XT(e){return bm($0(e))}function Sd(e,t){return"translate("+e+","+t+")"}function KT(e){return"rotate("+e+")"}function ghe(e,t){return"scale("+e+","+t+")"}function JH(e){return Sd(e.x||0,e.y||0)}function _he(e){return Sd(e.x||0,e.y||0)+(e.angle?" "+KT(e.angle):"")}function phe(e){return Sd(e.x||0,e.y||0)+(e.angle?" "+KT(e.angle):"")+(e.scaleX||e.scaleY?" "+ghe(e.scaleX||1,e.scaleY||1):"")}function ZT(e,t,n){function i(c,d){c("transform",_he(d)),c("d",t(null,d))}function s(c,d){return t(z0(c,d.angle),d),el(c,d).translate(d.x||0,d.y||0)}function o(c,d){var f=d.x||0,u=d.y||0,a=d.angle||0;c.translate(f,u),a&&c.rotate(a*=ic),c.beginPath(),t(c,d),a&&c.rotate(-a),c.translate(-f,-u)}return{type:e,tag:"path",nested:!1,attr:i,bound:s,draw:YT(o),pick:XT(o),isect:n||VT(o)}}var yhe=ZT("arc",the);function mhe(e,t){for(var n=e[0].orient==="horizontal"?t[1]:t[0],i=e[0].orient==="horizontal"?"y":"x",s=e.length,o=1/0,c,d;--s>=0;)e[s].defined!==!1&&(d=Math.abs(e[s][i]-n),d=0;)if(e[i].defined!==!1&&(s=e[i].x-t[0],o=e[i].y-t[1],c=s*s+o*o,c=0;)if(e[n].defined!==!1&&(i=e[n].x-t[0],s=e[n].y-t[1],o=i*i+s*s,i=e[n].size||1,o.5&&t<1.5?.5-Math.abs(t-1):0}function vhe(e,t){e("transform",JH(t))}function tz(e,t){const n=ez(t);e("d",Nh(null,t,n,n))}function Ehe(e,t){e("class","background"),e("aria-hidden",!0),tz(e,t)}function She(e,t){e("class","foreground"),e("aria-hidden",!0),t.strokeForeground?tz(e,t):e("d","")}function xhe(e,t,n){const i=t.clip?$T(n,t,t):null;e("clip-path",i)}function khe(e,t){if(!t.clip&&t.items){const n=t.items,i=n.length;for(let s=0;s{const s=i.x||0,o=i.y||0,c=i.strokeForeground,d=i.opacity==null?1:i.opacity;(i.stroke||i.fill)&&d&&(U2(e,i,s,o),th(e,i),i.fill&&vy(e,i,d)&&e.fill(),i.stroke&&!c&&nh(e,i,d)&&e.stroke()),e.save(),e.translate(s,o),i.clip&&QH(e,i),n&&n.translate(-s,-o),qr(i,f=>{this.draw(e,f,n)}),n&&n.translate(s,o),e.restore(),c&&i.stroke&&d&&(U2(e,i,s,o),th(e,i),nh(e,i,d)&&e.stroke())})}function Mhe(e,t,n,i,s,o){if(t.bounds&&!t.bounds.contains(s,o)||!t.items)return null;const c=n*e.pixelRatio,d=i*e.pixelRatio;return Ey(t,f=>{let u,a,m;const y=f.bounds;if(y&&!y.contains(s,o))return;a=f.x||0,m=f.y||0;const p=a+(f.width||0),l=m+(f.height||0),b=f.clip;if(b&&(sp||ol))return;if(e.save(),e.translate(a,m),a=s-a,m=o-m,b&&zT(f)&&!Ihe(e,f,c,d))return e.restore(),null;const L=f.strokeForeground,E=t.interactive!==!1;return E&&L&&f.stroke&&Fhe(e,f,c,d)?(e.restore(),f):(u=Ey(f,S=>Ahe(S,a,m)?this.pick(S,n,i,a,m):null),!u&&E&&(f.fill||!L&&f.stroke)&&Bhe(e,f,c,d)&&(u=f),e.restore(),u||null)})}function Ahe(e,t,n){return(e.interactive!==!1||e.marktype==="group")&&e.bounds&&e.bounds.contains(t,n)}var Nhe={type:"group",tag:"g",nested:!1,attr:vhe,bound:khe,draw:Ohe,pick:Mhe,isect:YH,content:xhe,background:Ehe,foreground:She},H2={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",version:"1.1"};function QT(e,t){var n=e.image;return(!n||e.url&&e.url!==n.url)&&(n={complete:!1,width:0,height:0},t.loadImage(e.url).then(i=>{e.image=i,e.image.url=e.url})),n}function ev(e,t){return e.width!=null?e.width:!t||!t.width?0:e.aspect!==!1&&e.height?e.height*t.width/t.height:t.width}function tv(e,t){return e.height!=null?e.height:!t||!t.height?0:e.aspect!==!1&&e.width?e.width*t.height/t.width:t.height}function Tm(e,t){return e==="center"?t/2:e==="right"?t:0}function vm(e,t){return e==="middle"?t/2:e==="bottom"?t:0}function Che(e,t,n){const i=QT(t,n),s=ev(t,i),o=tv(t,i),c=(t.x||0)-Tm(t.align,s),d=(t.y||0)-vm(t.baseline,o),f=!i.src&&i.toDataURL?i.toDataURL():i.src||"";e("href",f,H2["xmlns:xlink"],"xlink:href"),e("transform",Sd(c,d)),e("width",s),e("height",o),e("preserveAspectRatio",t.aspect===!1?"none":"xMidYMid")}function Rhe(e,t){const n=t.image,i=ev(t,n),s=tv(t,n),o=(t.x||0)-Tm(t.align,i),c=(t.y||0)-vm(t.baseline,s);return e.set(o,c,o+i,c+s)}function Phe(e,t,n){qr(t,i=>{if(n&&!n.intersects(i.bounds))return;const s=QT(i,this);let o=ev(i,s),c=tv(i,s);if(o===0||c===0)return;let d=(i.x||0)-Tm(i.align,o),f=(i.y||0)-vm(i.baseline,c),u,a,m,y;i.aspect!==!1&&(a=s.width/s.height,m=i.width/i.height,a===a&&m===m&&a!==m&&(m{if(!(n&&!n.intersects(i.bounds))){var s=i.opacity==null?1:i.opacity;s&&nz(e,i,s)&&(th(e,i),e.stroke())}})}function Xhe(e,t,n,i){return e.isPointInStroke?nz(e,t,1)&&e.isPointInStroke(n,i):!1}var Khe={type:"rule",tag:"line",nested:!1,attr:Ghe,bound:Whe,draw:Yhe,pick:bm(Xhe),isect:XH},Zhe=ZT("shape",she),Jhe=ZT("symbol",rhe,GT);const BI=eU();var Pr={height:Qa,measureWidth:nv,estimateWidth:JL,width:JL,canvas:iz};iz(!0);function iz(e){Pr.width=e&&$l?nv:JL}function JL(e,t){return sz(rc(e,t),Qa(e))}function sz(e,t){return~~(.8*e.length*t)}function nv(e,t){return Qa(e)<=0||!(t=rc(e,t))?0:rz(t,Em(e))}function rz(e,t){const n=`(${t}) ${e}`;let i=BI.get(n);return i===void 0&&($l.font=t,i=$l.measureText(e).width,BI.set(n,i)),i}function Qa(e){return e.fontSize!=null?+e.fontSize||0:11}function sc(e){return e.lineHeight!=null?e.lineHeight:Qa(e)+2}function Qhe(e){return ue(e)?e.length>1?e:e[0]:e}function q0(e){return Qhe(e.lineBreak&&e.text&&!ue(e.text)?e.text.split(e.lineBreak):e.text)}function iv(e){const t=q0(e);return(ue(t)?t.length-1:0)*sc(e)}function rc(e,t){const n=t==null?"":(t+"").trim();return e.limit>0&&n.length?t1e(e,n):n}function e1e(e){if(Pr.width===nv){const t=Em(e);return n=>rz(n,t)}else{const t=Qa(e);return n=>sz(n,t)}}function t1e(e,t){var n=+e.limit,i=e1e(e);if(i(t)>>1,i(t.slice(f))>n?c=f+1:d=f;return s+t.slice(c)}else{for(;c>>1),i(t.slice(0,f))Math.max(y,Pr.width(t,p)),0)):m=Pr.width(t,a),s==="center"?f-=m/2:s==="right"&&(f-=m),e.set(f+=c,u+=d,f+m,u+i),t.angle&&!n)e.rotate(t.angle*ic,c,d);else if(n===2)return e.rotatedPoints(t.angle*ic,c,d);return e}function s1e(e,t,n){qr(t,i=>{var s=i.opacity==null?1:i.opacity,o,c,d,f,u,a,m;if(!(n&&!n.intersects(i.bounds)||s===0||i.fontSize<=0||i.text==null||i.text.length===0)){if(e.font=Em(i),e.textAlign=i.align||"left",o=Sm(i),c=o.x1,d=o.y1,i.angle&&(e.save(),e.translate(c,d),e.rotate(i.angle*ic),c=d=0),c+=i.dx||0,d+=(i.dy||0)+sv(i),a=q0(i),th(e,i),ue(a))for(u=sc(i),f=0;ft;)e.removeChild(n[--i]);return e}function fz(e){return"mark-"+e.marktype+(e.role?" role-"+e.role:"")+(e.name?" "+e.name:"")}function xm(e,t){const n=t.getBoundingClientRect();return[e.clientX-n.left-(t.clientLeft||0),e.clientY-n.top-(t.clientTop||0)]}function d1e(e,t,n,i){var s=e&&e.mark,o,c;if(s&&(o=Ds[s.marktype]).tip){for(c=xm(t,n),c[0]-=i[0],c[1]-=i[1];e=e.mark.group;)c[0]-=e.x||0,c[1]-=e.y||0;e=o.tip(s.items,c)}return e}function ac(e,t){this._active=null,this._handlers={},this._loader=e||am(),this._tooltip=t||f1e}function f1e(e,t,n,i){e.element().setAttribute("title",i||"")}ac.prototype={initialize(e,t,n){return this._el=e,this._obj=n||null,this.origin(t)},element(){return this._el},canvas(){return this._el&&this._el.firstChild},origin(e){return arguments.length?(this._origin=e||[0,0],this):this._origin.slice()},scene(e){return arguments.length?(this._scene=e,this):this._scene},on(){},off(){},_handlerIndex(e,t,n){for(let i=e?e.length:0;--i>=0;)if(e[i].type===t&&(!n||e[i].handler===n))return i;return-1},handlers(e){const t=this._handlers,n=[];if(e)n.push(...t[this.eventName(e)]);else for(const i in t)n.push(...t[i]);return n},eventName(e){const t=e.indexOf(".");return t<0?e:e.slice(0,t)},handleHref(e,t,n){this._loader.sanitize(n,{context:"href"}).then(i=>{const s=new MouseEvent(e.type,e),o=Ol(null,"a");for(const c in i)o.setAttribute(c,i[c]);o.dispatchEvent(s)}).catch(()=>{})},handleTooltip(e,t,n){if(t&&t.tooltip!=null){t=d1e(t,e,this.canvas(),this._origin);const i=n&&t&&t.tooltip||null;this._tooltip.call(this._obj,this,e,t,i)}},getItemBoundingClientRect(e){const t=this.canvas();if(!t)return;const n=t.getBoundingClientRect(),i=this._origin,s=e.bounds,o=s.width(),c=s.height();let d=s.x1+i[0]+n.left,f=s.y1+i[1]+n.top;for(;e.mark&&(e=e.mark.group);)d+=e.x||0,f+=e.y||0;return{x:d,y:f,width:o,height:c,left:d,top:f,right:d+o,bottom:f+c}}};function eo(e){this._el=null,this._bgcolor=null,this._loader=new qT(e)}eo.prototype={initialize(e,t,n,i,s){return this._el=e,this.resize(t,n,i,s)},element(){return this._el},canvas(){return this._el&&this._el.firstChild},background(e){return arguments.length===0?this._bgcolor:(this._bgcolor=e,this)},resize(e,t,n,i){return this._width=e,this._height=t,this._origin=n||[0,0],this._scale=i||1,this},dirty(){},render(e){const t=this;return t._call=function(){t._render(e)},t._call(),t._call=null,t},_render(){},renderAsync(e){const t=this.render(e);return this._ready?this._ready.then(()=>t):Promise.resolve(t)},_load(e,t){var n=this,i=n._loader[e](t);if(!n._ready){const s=n._call;n._ready=n._loader.ready().then(o=>{o&&s(),n._ready=null})}return i},sanitizeURL(e){return this._load("sanitizeURL",e)},loadImage(e){return this._load("loadImage",e)}};const u1e="keydown",h1e="keypress",g1e="keyup",uz="dragenter",K_="dragleave",hz="dragover",e8="mousedown",_1e="mouseup",Sy="mousemove",s2="mouseout",gz="mouseover",xy="click",p1e="dblclick",y1e="wheel",_z="mousewheel",ky="touchstart",By="touchmove",Fy="touchend",m1e=[u1e,h1e,g1e,uz,K_,hz,e8,_1e,Sy,s2,gz,xy,p1e,y1e,_z,ky,By,Fy],t8=Sy,z2=s2,n8=xy;function G0(e,t){ac.call(this,e,t),this._down=null,this._touch=null,this._first=!0,this._events={}}const w1e=e=>e===ky||e===By||e===Fy?[ky,By,Fy]:[e];function II(e,t){w1e(t).forEach(n=>L1e(e,n))}function L1e(e,t){const n=e.canvas();n&&!e._events[t]&&(e._events[t]=1,n.addEventListener(t,e[t]?i=>e[t](i):i=>e.fire(t,i)))}function OI(e,t,n){return function(i){const s=this._active,o=this.pickEvent(i);o===s?this.fire(e,i):((!s||!s.exit)&&this.fire(n,i),this._active=o,this.fire(t,i),this.fire(e,i))}}function MI(e){return function(t){this.fire(e,t),this._active=null}}Le(G0,ac,{initialize(e,t,n){return this._canvas=e&&ov(e,"canvas"),[xy,e8,Sy,s2,K_].forEach(i=>II(this,i)),ac.prototype.initialize.call(this,e,t,n)},canvas(){return this._canvas},context(){return this._canvas.getContext("2d")},events:m1e,DOMMouseScroll(e){this.fire(_z,e)},mousemove:OI(Sy,gz,s2),dragover:OI(hz,uz,K_),mouseout:MI(s2),dragleave:MI(K_),mousedown(e){this._down=this._active,this.fire(e8,e)},click(e){this._down===this._active&&(this.fire(xy,e),this._down=null)},touchstart(e){this._touch=this.pickEvent(e.changedTouches[0]),this._first&&(this._active=this._touch,this._first=!1),this.fire(ky,e,!0)},touchmove(e){this.fire(By,e,!0)},touchend(e){this.fire(Fy,e,!0),this._touch=null},fire(e,t,n){const i=n?this._touch:this._active,s=this._handlers[e];if(t.vegaType=e,e===n8&&i&&i.href?this.handleHref(t,i,i.href):(e===t8||e===z2)&&this.handleTooltip(t,i,e!==z2),s)for(let o=0,c=s.length;o=0&&i.splice(s,1),this},pickEvent(e){const t=xm(e,this._canvas),n=this._origin;return this.pick(this._scene,t[0],t[1],t[0]-n[0],t[1]-n[1])},pick(e,t,n,i,s){const o=this.context();return Ds[e.marktype].pick.call(this,o,e,t,n,i,s)}});function b1e(){return typeof window<"u"&&window.devicePixelRatio||1}var T1e=b1e();function v1e(e,t,n,i,s,o){const c=typeof HTMLElement<"u"&&e instanceof HTMLElement&&e.parentNode!=null,d=e.getContext("2d"),f=c?T1e:s;e.width=t*f,e.height=n*f;for(const u in o)d[u]=o[u];return c&&f!==1&&(e.style.width=t+"px",e.style.height=n+"px"),d.pixelRatio=f,d.setTransform(f,0,0,f,f*i[0],f*i[1]),e}function Iy(e){eo.call(this,e),this._options={},this._redraw=!1,this._dirty=new En,this._tempb=new En}const AI=eo.prototype,E1e=(e,t,n)=>new En().set(0,0,t,n).translate(-e[0],-e[1]);function S1e(e,t,n){return t.expand(1).round(),e.pixelRatio%1&&t.scale(e.pixelRatio).round().scale(1/e.pixelRatio),t.translate(-(n[0]%1),-(n[1]%1)),e.beginPath(),e.rect(t.x1,t.y1,t.width(),t.height()),e.clip(),t}Le(Iy,eo,{initialize(e,t,n,i,s,o){return this._options=o||{},this._canvas=this._options.externalContext?null:N0(1,1,this._options.type),e&&this._canvas&&(xr(e,0).appendChild(this._canvas),this._canvas.setAttribute("class","marks")),AI.initialize.call(this,e,t,n,i,s)},resize(e,t,n,i){if(AI.resize.call(this,e,t,n,i),this._canvas)v1e(this._canvas,this._width,this._height,this._origin,this._scale,this._options.context);else{const s=this._options.externalContext;s||ce("CanvasRenderer is missing a valid canvas or context"),s.scale(this._scale,this._scale),s.translate(this._origin[0],this._origin[1])}return this._redraw=!0,this},canvas(){return this._canvas},context(){return this._options.externalContext||(this._canvas?this._canvas.getContext("2d"):null)},dirty(e){const t=this._tempb.clear().union(e.bounds);let n=e.mark.group;for(;n;)t.translate(n.x||0,n.y||0),n=n.mark.group;this._dirty.union(t)},_render(e){const t=this.context(),n=this._origin,i=this._width,s=this._height,o=this._dirty,c=E1e(n,i,s);t.save();const d=this._redraw||o.empty()?(this._redraw=!1,c.expand(1)):S1e(t,c.intersect(o),n);return this.clear(-n[0],-n[1],i,s),this.draw(t,e,d),t.restore(),o.clear(),this},draw(e,t,n){const i=Ds[t.marktype];t.clip&&The(e,t),i.draw.call(this,e,t,n),t.clip&&e.restore()},clear(e,t,n,i){const s=this._options,o=this.context();s.type!=="pdf"&&!s.externalContext&&o.clearRect(e,t,n,i),this._bgcolor!=null&&(o.fillStyle=this._bgcolor,o.fillRect(e,t,n,i))}});function lv(e,t){ac.call(this,e,t);const n=this;n._hrefHandler=i8(n,(i,s)=>{s&&s.href&&n.handleHref(i,s,s.href)}),n._tooltipHandler=i8(n,(i,s)=>{n.handleTooltip(i,s,i.type!==z2)})}const i8=(e,t)=>n=>{let i=n.target.__data__;i=Array.isArray(i)?i[0]:i,n.vegaType=n.type,t.call(e._obj,n,i)};Le(lv,ac,{initialize(e,t,n){let i=this._svg;return i&&(i.removeEventListener(n8,this._hrefHandler),i.removeEventListener(t8,this._tooltipHandler),i.removeEventListener(z2,this._tooltipHandler)),this._svg=i=e&&ov(e,"svg"),i&&(i.addEventListener(n8,this._hrefHandler),i.addEventListener(t8,this._tooltipHandler),i.addEventListener(z2,this._tooltipHandler)),ac.prototype.initialize.call(this,e,t,n)},canvas(){return this._svg},on(e,t){const n=this.eventName(e),i=this._handlers;if(this._handlerIndex(i[n],e,t)<0){const o={type:e,handler:t,listener:i8(this,t)};(i[n]||(i[n]=[])).push(o),this._svg&&this._svg.addEventListener(n,o.listener)}return this},off(e,t){const n=this.eventName(e),i=this._handlers[n],s=this._handlerIndex(i,e,t);return s>=0&&(this._svg&&this._svg.removeEventListener(n,i[s].listener),i.splice(s,1)),this}});const pz="aria-hidden",cv="aria-label",dv="role",fv="aria-roledescription",yz="graphics-object",uv="graphics-symbol",mz=(e,t,n)=>({[dv]:e,[fv]:t,[cv]:n||void 0}),x1e=zr(["axis-domain","axis-grid","axis-label","axis-tick","axis-title","legend-band","legend-entry","legend-gradient","legend-label","legend-title","legend-symbol","title"]),NI={axis:{desc:"axis",caption:F1e},legend:{desc:"legend",caption:I1e},"title-text":{desc:"title",caption:e=>`Title text '${RI(e)}'`},"title-subtitle":{desc:"subtitle",caption:e=>`Subtitle text '${RI(e)}'`}},CI={ariaRole:dv,ariaRoleDescription:fv,description:cv};function wz(e,t){const n=t.aria===!1;if(e(pz,n||void 0),n||t.description==null)for(const i in CI)e(CI[i],void 0);else{const i=t.mark.marktype;e(cv,t.description),e(dv,t.ariaRole||(i==="group"?yz:uv)),e(fv,t.ariaRoleDescription||`${i} mark`)}}function Lz(e){return e.aria===!1?{[pz]:!0}:x1e[e.role]?null:NI[e.role]?B1e(e,NI[e.role]):k1e(e)}function k1e(e){const t=e.marktype,n=t==="group"||t==="text"||e.items.some(i=>i.description!=null&&i.aria!==!1);return mz(n?yz:uv,`${t} mark container`,e.description)}function B1e(e,t){try{const n=e.items[0],i=t.caption||(()=>"");return mz(t.role||uv,t.desc,n.description||i(n))}catch{return null}}function RI(e){return Se(e.text).join(" ")}function F1e(e){const t=e.datum,n=e.orient,i=t.title?bz(e):null,s=e.context,o=s.scales[t.scale].value,c=s.dataflow.locale(),d=o.type;return`${n==="left"||n==="right"?"Y":"X"}-axis`+(i?` titled '${i}'`:"")+` for a ${Qu(d)?"discrete":d} scale with ${DH(c,o,e)}`}function I1e(e){const t=e.datum,n=t.title?bz(e):null,i=`${t.type||""} legend`.trim(),s=t.scales,o=Object.keys(s),c=e.context,d=c.scales[s[o[0]]].value,f=c.dataflow.locale();return M1e(i)+(n?` titled '${n}'`:"")+` for ${O1e(o)} with ${DH(f,d,e)}`}function bz(e){try{return Se(kt(e.items).items[0].text).join(" ")}catch{return null}}function O1e(e){return e=e.map(t=>t+(t==="fill"||t==="stroke"?" color":"")),e.length<2?e[0]:e.slice(0,-1).join(", ")+" and "+kt(e)}function M1e(e){return e.length?e[0].toUpperCase()+e.slice(1):e}const Tz=e=>(e+"").replace(/&/g,"&").replace(//g,">"),A1e=e=>Tz(e).replace(/"/g,""").replace(/\t/g," ").replace(/\n/g," ").replace(/\r/g," ");function hv(){let e="",t="",n="";const i=[],s=()=>t=n="",o=f=>{t&&(e+=`${t}>${n}`,s()),i.push(f)},c=(f,u)=>(u!=null&&(t+=` ${f}="${A1e(u)}"`),d),d={open(f){o(f),t="<"+f;for(var u=arguments.length,a=new Array(u>1?u-1:0),m=1;m${n}`:"/>"):e+=``,s(),d},attr:c,text:f=>(n+=Tz(f),d),toString:()=>e};return d}const vz=e=>Ez(hv(),e)+"";function Ez(e,t){if(e.open(t.tagName),t.hasAttributes()){const n=t.attributes,i=n.length;for(let s=0;s{u.dirty=t})),!i.zdirty){if(n.exit){o.nested&&i.items.length?(f=i.items[0],f._svg&&this._update(o,f._svg,f)):n._svg&&(f=n._svg.parentNode,f&&f.removeChild(n._svg)),n._svg=null;continue}n=o.nested?i.items[0]:n,n._update!==t&&(!n._svg||!n._svg.ownerSVGElement?(this._dirtyAll=!1,DI(n,t)):this._update(o,n._svg,n),n._update=t)}return!this._dirtyAll},mark(e,t,n){if(!this.isDirty(t))return t._svg;const i=this._svg,s=Ds[t.marktype],o=t.interactive===!1?"none":null,c=s.tag==="g",d=jI(t,e,n,"g",i);d.setAttribute("class",fz(t));const f=Lz(t);for(const y in f)Ii(d,y,f[y]);c||Ii(d,"pointer-events",o),Ii(d,"clip-path",t.clip?$T(this,t,t.group):null);let u=null,a=0;const m=y=>{const p=this.isDirty(y),l=jI(y,d,u,s.tag,i);p&&(this._update(s,l,y),c&&R1e(this,l,y)),u=l,++a};return s.nested?t.items.length&&m(t.items[0]):qr(t,m),xr(d,a),d},_update(e,t,n){Oo=t,ui=t.__values__,wz(r2,n),e.attr(r2,n,this);const i=D1e[e.type];i&&i.call(this,e,t,n),Oo&&this.style(Oo,n)},style(e,t){if(t!=null){for(const n in Oy){let i=n==="font"?V0(t):t[n];if(i===ui[n])continue;const s=Oy[n];i==null?e.removeAttribute(s):(UT(i)&&(i=UH(i,this._defs.gradient,xz())),e.setAttribute(s,i+"")),ui[n]=i}for(const n in My)Z_(e,My[n],t[n])}},defs(){const e=this._svg,t=this._defs;let n=t.el,i=0;for(const s in t.gradient)n||(t.el=n=ns(e,o1+1,"defs",On)),i=N1e(n,t.gradient[s],i);for(const s in t.clipping)n||(t.el=n=ns(e,o1+1,"defs",On)),i=C1e(n,t.clipping[s],i);n&&(i===0?(e.removeChild(n),t.el=null):xr(n,i))},_clearDefs(){const e=this._defs;e.gradient={},e.clipping={}}});function DI(e,t){for(;e&&e.dirty!==t;e=e.mark.group)if(e.dirty=t,e.mark&&e.mark.dirty!==t)e.mark.dirty=t;else return}function N1e(e,t,n){let i,s,o;if(t.gradient==="radial"){let c=ns(e,n++,"pattern",On);Ml(c,{id:Ty+t.id,viewBox:"0,0,1,1",width:"100%",height:"100%",preserveAspectRatio:"xMidYMid slice"}),c=ns(c,0,"rect",On),Ml(c,{width:1,height:1,fill:`url(${xz()}#${t.id})`}),e=ns(e,n++,"radialGradient",On),Ml(e,{id:t.id,fx:t.x1,fy:t.y1,fr:t.r1,cx:t.x2,cy:t.y2,r:t.r2})}else e=ns(e,n++,"linearGradient",On),Ml(e,{id:t.id,x1:t.x1,x2:t.x2,y1:t.y1,y2:t.y2});for(i=0,s=t.stops.length;i{i=e.mark(t,o,i),++s}),xr(t,1+s)}function jI(e,t,n,i,s){let o=e._svg,c;if(!o&&(c=t.ownerDocument,o=Ol(c,i,On),e._svg=o,e.mark&&(o.__data__=e,o.__values__={fill:"default"},i==="g"))){const d=Ol(c,"path",On);o.appendChild(d),d.__data__=e;const f=Ol(c,"g",On);o.appendChild(f),f.__data__=e;const u=Ol(c,"path",On);o.appendChild(u),u.__data__=e,u.__values__={fill:"default"}}return(o.ownerSVGElement!==s||P1e(o,n))&&t.insertBefore(o,n?n.nextSibling:t.firstChild),o}function P1e(e,t){return e.parentNode&&e.parentNode.childNodes.length>1&&e.previousSibling!=t}let Oo=null,ui=null;const D1e={group(e,t,n){const i=Oo=t.childNodes[2];ui=i.__values__,e.foreground(r2,n,this),ui=t.__values__,Oo=t.childNodes[1],e.content(r2,n,this);const s=Oo=t.childNodes[0];e.background(r2,n,this);const o=n.mark.interactive===!1?"none":null;if(o!==ui.events&&(Ii(i,"pointer-events",o),Ii(s,"pointer-events",o),ui.events=o),n.strokeForeground&&n.stroke){const c=n.fill;Ii(i,"display",null),this.style(s,n),Ii(s,"stroke",null),c&&(n.fill=null),ui=i.__values__,this.style(i,n),c&&(n.fill=c),Oo=null}else Ii(i,"display","none")},image(e,t,n){n.smooth===!1?(Z_(t,"image-rendering","optimizeSpeed"),Z_(t,"image-rendering","pixelated")):Z_(t,"image-rendering",null)},text(e,t,n){const i=q0(n);let s,o,c,d;ue(i)?(o=i.map(f=>rc(n,f)),s=o.join(` `),s!==ui.text&&(xr(t,0),c=t.ownerDocument,d=sc(n),o.forEach((f,u)=>{const a=Ol(c,"tspan",On);a.__data__=n,a.textContent=f,u&&(a.setAttribute("x",0),a.setAttribute("dy",d)),t.appendChild(a)}),ui.text=s)):(o=rc(n,i),o!==ui.text&&(t.textContent=o,ui.text=o)),Ii(t,"font-family",V0(n)),Ii(t,"font-size",Qa(n)+"px"),Ii(t,"font-style",n.fontStyle),Ii(t,"font-variant",n.fontVariant),Ii(t,"font-weight",n.fontWeight)}};function r2(e,t,n){t!==ui[e]&&(n?j1e(Oo,e,t,n):Ii(Oo,e,t),ui[e]=t)}function Z_(e,t,n){n!==ui[t]&&(n==null?e.style.removeProperty(t):e.style.setProperty(t,n+""),ui[t]=n)}function Ml(e,t){for(const n in t)Ii(e,n,t[n])}function Ii(e,t,n){n!=null?e.setAttribute(t,n):e.removeAttribute(t)}function j1e(e,t,n,i){n!=null?e.setAttributeNS(i,t,n):e.removeAttributeNS(i,t)}function xz(){let e;return typeof window>"u"?"":(e=window.location).hash?e.href.slice(0,-e.hash.length):e.href}function _v(e){eo.call(this,e),this._text=null,this._defs={gradient:{},clipping:{}}}Le(_v,eo,{svg(){return this._text},_render(e){const t=hv();t.open("svg",dt({},H2,{class:"marks",width:this._width*this._scale,height:this._height*this._scale,viewBox:`0 0 ${this._width} ${this._height}`}));const n=this._bgcolor;return n&&n!=="transparent"&&n!=="none"&&t.open("rect",{width:this._width,height:this._height,fill:n}).close(),t.open("g",Sz,{transform:"translate("+this._origin+")"}),this.mark(t,e),t.close(),this.defs(t),this._text=t.close()+"",this},mark(e,t){const n=Ds[t.marktype],i=n.tag,s=[wz,n.attr];e.open("g",{class:fz(t),"clip-path":t.clip?$T(this,t,t.group):null},Lz(t),{"pointer-events":i!=="g"&&t.interactive===!1?"none":null});const o=c=>{const d=this.href(c);if(d&&e.open("a",d),e.open(i,this.attr(t,c,s,i!=="g"?i:null)),i==="text"){const f=q0(c);if(ue(f)){const u={x:0,dy:sc(c)};for(let a=0;athis.mark(e,m)),e.close(),f&&a?(u&&(c.fill=null),c.stroke=a,e.open("path",this.attr(t,c,n.foreground,"bgrect")).close(),u&&(c.fill=u)):e.open("path",this.attr(t,c,n.foreground,"bgfore")).close()}e.close(),d&&e.close()};return n.nested?t.items&&t.items.length&&o(t.items[0]):qr(t,o),e.close()},href(e){const t=e.href;let n;if(t){if(n=this._hrefs&&this._hrefs[t])return n;this.sanitizeURL(t).then(i=>{i["xlink:href"]=i.href,i.href=null,(this._hrefs||(this._hrefs={}))[t]=i})}return null},attr(e,t,n,i){const s={},o=(c,d,f,u)=>{s[u||c]=d};return Array.isArray(n)?n.forEach(c=>c(o,t,this)):n(o,t,this),i&&U1e(s,t,e,i,this._defs),s},defs(e){const t=this._defs.gradient,n=this._defs.clipping;if(Object.keys(t).length+Object.keys(n).length!==0){e.open("defs");for(const s in t){const o=t[s],c=o.stops;o.gradient==="radial"?(e.open("pattern",{id:Ty+s,viewBox:"0,0,1,1",width:"100%",height:"100%",preserveAspectRatio:"xMidYMid slice"}),e.open("rect",{width:"1",height:"1",fill:"url(#"+s+")"}).close(),e.close(),e.open("radialGradient",{id:s,fx:o.x1,fy:o.y1,fr:o.r1,cx:o.x2,cy:o.y2,r:o.r2})):e.open("linearGradient",{id:s,x1:o.x1,x2:o.x2,y1:o.y1,y2:o.y2});for(let d=0;d1?(ih[e]=t,this):ih[e]}function Oz(e,t,n){const i=[],s=new En().union(t),o=e.marktype;return o?Mz(e,s,n,i):o==="group"?Az(e,s,n,i):ce("Intersect scene must be mark node or group item.")}function Mz(e,t,n,i){if(H1e(e,t,n)){const s=e.items,o=e.marktype,c=s.length;let d=0;if(o==="group")for(;d=0;o--)if(n[o]!=i[o])return!1;for(o=n.length-1;o>=0;o--)if(s=n[o],!pv(e[s],t[s],s))return!1;return typeof e==typeof t}function q1e(){WH(),_ue()}const sh="top",kr="left",Mr="right",oc="bottom",V1e="top-left",G1e="top-right",W1e="bottom-left",Y1e="bottom-right",yv="start",s8="middle",Mi="end",X1e="x",K1e="y",Bm="group",mv="axis",wv="title",Z1e="frame",J1e="scope",Lv="legend",Pz="row-header",Dz="row-footer",jz="row-title",Uz="column-header",Hz="column-footer",zz="column-title",Q1e="padding",e2e="symbol",$z="fit",qz="fit-x",Vz="fit-y",t2e="pad",bv="none",Qg="all",r8="each",Tv="flush",Nl="column",Cl="row";function Gz(e){ae.call(this,null,e)}Le(Gz,ae,{transform(e,t){const n=t.dataflow,i=e.mark,s=i.marktype,o=Ds[s],c=o.bound;let d=i.bounds,f;if(o.nested)i.items.length&&n.dirty(i.items[0]),d=e_(i,c),i.items.forEach(u=>{u.bounds.clear().union(d)});else if(s===Bm||e.modified())switch(t.visit(t.MOD,u=>n.dirty(u)),d.clear(),i.items.forEach(u=>d.union(e_(u,c))),i.role){case mv:case Lv:case wv:t.reflow()}else f=t.changed(t.REM),t.visit(t.ADD,u=>{d.union(e_(u,c))}),t.visit(t.MOD,u=>{f=f||d.alignsWith(u.bounds),n.dirty(u),d.union(e_(u,c))}),f&&(d.clear(),i.items.forEach(u=>d.union(u.bounds)));return Cz(i),t.modifies("bounds")}});function e_(e,t,n){return t(e.bounds.clear(),e,n)}const UI=":vega_identifier:";function vv(e){ae.call(this,0,e)}vv.Definition={type:"Identifier",metadata:{modifies:!0},params:[{name:"as",type:"string",required:!0}]};Le(vv,ae,{transform(e,t){const n=n2e(t.dataflow),i=e.as;let s=n.value;return t.visit(t.ADD,o=>o[i]=o[i]||++s),n.set(this.value=s),t}});function n2e(e){return e._signals[UI]||(e._signals[UI]=e.add(0))}function Wz(e){ae.call(this,null,e)}Le(Wz,ae,{transform(e,t){let n=this.value;n||(n=t.dataflow.scenegraph().mark(e.markdef,i2e(e),e.index),n.group.context=e.context,e.context.group||(e.context.group=n.group),n.source=this.source,n.clip=e.clip,n.interactive=e.interactive,this.value=n);const i=n.marktype===Bm?wm:mm;return t.visit(t.ADD,s=>i.call(s,n)),(e.modified("clip")||e.modified("interactive"))&&(n.clip=e.clip,n.interactive=!!e.interactive,n.zdirty=!0,t.reflow()),n.items=t.source,t}});function i2e(e){const t=e.groups,n=e.parent;return t&&t.size===1?t.get(Object.keys(t.object)[0]):t&&n?t.lookup(n):null}function Yz(e){ae.call(this,null,e)}const HI={parity:e=>e.filter((t,n)=>n%2?t.opacity=0:1),greedy:(e,t)=>{let n;return e.filter((i,s)=>!s||!Xz(n.bounds,i.bounds,t)?(n=i,1):i.opacity=0)}},Xz=(e,t,n)=>n>Math.max(t.x1-e.x2,e.x1-t.x2,t.y1-e.y2,e.y1-t.y2),zI=(e,t)=>{for(var n=1,i=e.length,s=e[0].bounds,o;n{const t=e.bounds;return t.width()>1&&t.height()>1},r2e=(e,t,n)=>{var i=e.range(),s=new En;return t===sh||t===oc?s.set(i[0],-1/0,i[1],1/0):s.set(-1/0,i[0],1/0,i[1]),s.expand(n||1),o=>s.encloses(o.bounds)},$I=e=>(e.forEach(t=>t.opacity=1),e),qI=(e,t)=>e.reflow(t.modified()).modifies("opacity");Le(Yz,ae,{transform(e,t){const n=HI[e.method]||HI.parity,i=e.separation||0;let s=t.materialize(t.SOURCE).source,o,c;if(!s||!s.length)return;if(!e.method)return e.modified("method")&&($I(s),t=qI(t,e)),t;if(s=s.filter(s2e),!s.length)return;if(e.sort&&(s=s.slice().sort(e.sort)),o=$I(s),t=qI(t,e),o.length>=3&&zI(o,i)){do o=n(o,i);while(o.length>=3&&zI(o,i));o.length<3&&!kt(s).opacity&&(o.length>1&&(kt(o).opacity=0),kt(s).opacity=1)}e.boundScale&&e.boundTolerance>=0&&(c=r2e(e.boundScale,e.boundOrient,+e.boundTolerance),s.forEach(f=>{c(f)||(f.opacity=0)}));const d=o[0].mark.bounds.clear();return s.forEach(f=>{f.opacity&&d.union(f.bounds)}),t}});function Kz(e){ae.call(this,null,e)}Le(Kz,ae,{transform(e,t){const n=t.dataflow;if(t.visit(t.ALL,i=>n.dirty(i)),t.fields&&t.fields.zindex){const i=t.source&&t.source[0];i&&(i.mark.zdirty=!0)}}});const fi=new En;function lu(e,t,n){return e[t]===n?0:(e[t]=n,1)}function a2e(e){var t=e.items[0].orient;return t===kr||t===Mr}function o2e(e){let t=+e.grid;return[e.ticks?t++:-1,e.labels?t++:-1,t+ +e.domain]}function l2e(e,t,n,i){var s=t.items[0],o=s.datum,c=s.translate!=null?s.translate:.5,d=s.orient,f=o2e(o),u=s.range,a=s.offset,m=s.position,y=s.minExtent,p=s.maxExtent,l=o.title&&s.items[f[2]].items[0],b=s.titlePadding,L=s.bounds,E=l&&iv(l),S=0,x=0,F,k;switch(fi.clear().union(L),L.clear(),(F=f[0])>-1&&L.union(s.items[F].bounds),(F=f[1])>-1&&L.union(s.items[F].bounds),d){case sh:S=m||0,x=-a,k=Math.max(y,Math.min(p,-L.y1)),L.add(0,-k).add(u,0),l&&t_(e,l,k,b,E,0,-1,L);break;case kr:S=-a,x=m||0,k=Math.max(y,Math.min(p,-L.x1)),L.add(-k,0).add(0,u),l&&t_(e,l,k,b,E,1,-1,L);break;case Mr:S=n+a,x=m||0,k=Math.max(y,Math.min(p,L.x2)),L.add(0,0).add(k,u),l&&t_(e,l,k,b,E,1,1,L);break;case oc:S=m||0,x=i+a,k=Math.max(y,Math.min(p,L.y2)),L.add(0,0).add(u,k),l&&t_(e,l,k,b,0,0,1,L);break;default:S=s.x,x=s.y}return el(L.translate(S,x),s),lu(s,"x",S+c)|lu(s,"y",x+c)&&(s.bounds=fi,e.dirty(s),s.bounds=L,e.dirty(s)),s.mark.bounds.clear().union(L)}function t_(e,t,n,i,s,o,c,d){const f=t.bounds;if(t.auto){const u=c*(n+s+i);let a=0,m=0;e.dirty(t),o?a=(t.x||0)-(t.x=u):m=(t.y||0)-(t.y=u),t.mark.bounds.clear().union(f.translate(-a,-m)),e.dirty(t)}d.union(f)}const VI=(e,t)=>Math.floor(Math.min(e,t)),GI=(e,t)=>Math.ceil(Math.max(e,t));function c2e(e){var t=e.items,n=t.length,i=0,s,o;const c={marks:[],rowheaders:[],rowfooters:[],colheaders:[],colfooters:[],rowtitle:null,coltitle:null};for(;i1)for(O=0;O0&&(x[O]+=Y/2);if(d&&cn(n.center,Cl)&&a!==1)for(O=0;O0&&(F[O]+=$/2);for(O=0;Os&&(e.warn("Grid headers exceed limit: "+s),t=t.slice(0,s)),b+=o,S=0,F=t.length;S=0&&(O=n[x])==null;x-=y);d?(C=p==null?O.x:Math.round(O.bounds.x1+p*O.bounds.width()),P=b):(C=b,P=p==null?O.y:Math.round(O.bounds.y1+p*O.bounds.height())),k.union(M.bounds.translate(C-(M.x||0),P-(M.y||0))),M.x=C,M.y=P,e.dirty(M),L=c(L,k[u])}return L}function YI(e,t,n,i,s,o){if(t){e.dirty(t);var c=n,d=n;i?c=Math.round(s.x1+o*s.width()):d=Math.round(s.y1+o*s.height()),t.bounds.translate(c-(t.x||0),d-(t.y||0)),t.mark.bounds.clear().union(t.bounds),t.x=c,t.y=d,e.dirty(t)}}function _2e(e,t){const n=e[t]||{};return(i,s)=>n[i]!=null?n[i]:e[i]!=null?e[i]:s}function p2e(e,t){let n=-1/0;return e.forEach(i=>{i.offset!=null&&(n=Math.max(n,i.offset))}),n>-1/0?n:t}function y2e(e,t,n,i,s,o,c){const d=_2e(n,t),f=p2e(e,d("offset",0)),u=d("anchor",yv),a=u===Mi?1:u===s8?.5:0,m={align:r8,bounds:d("bounds",Tv),columns:d("direction")==="vertical"?1:e.length,padding:d("margin",8),center:d("center"),nodirty:!0};switch(t){case kr:m.anchor={x:Math.floor(i.x1)-f,column:Mi,y:a*(c||i.height()+2*i.y1),row:u};break;case Mr:m.anchor={x:Math.ceil(i.x2)+f,y:a*(c||i.height()+2*i.y1),row:u};break;case sh:m.anchor={y:Math.floor(s.y1)-f,row:Mi,x:a*(o||s.width()+2*s.x1),column:u};break;case oc:m.anchor={y:Math.ceil(s.y2)+f,x:a*(o||s.width()+2*s.x1),column:u};break;case V1e:m.anchor={x:f,y:f};break;case G1e:m.anchor={x:o-f,y:f,column:Mi};break;case W1e:m.anchor={x:f,y:c-f,row:Mi};break;case Y1e:m.anchor={x:o-f,y:c-f,column:Mi,row:Mi};break}return m}function m2e(e,t){var n=t.items[0],i=n.datum,s=n.orient,o=n.bounds,c=n.x,d=n.y,f,u;return n._bounds?n._bounds.clear().union(o):n._bounds=o.clone(),o.clear(),L2e(e,n,n.items[0].items[0]),o=w2e(n,o),f=2*n.padding,u=2*n.padding,o.empty()||(f=Math.ceil(o.width()+f),u=Math.ceil(o.height()+u)),i.type===e2e&&b2e(n.items[0].items[0].items[0].items),s!==bv&&(n.x=c=0,n.y=d=0),n.width=f,n.height=u,el(o.set(c,d,c+f,d+u),n),n.mark.bounds.clear().union(o),n}function w2e(e,t){return e.items.forEach(n=>t.union(n.bounds)),t.x1=e.padding,t.y1=e.padding,t}function L2e(e,t,n){var i=t.padding,s=i-n.x,o=i-n.y;if(!t.datum.title)(s||o)&&l1(e,n,s,o);else{var c=t.items[1].items[0],d=c.anchor,f=t.titlePadding||0,u=i-c.x,a=i-c.y;switch(c.orient){case kr:s+=Math.ceil(c.bounds.width())+f;break;case Mr:case oc:break;default:o+=c.bounds.height()+f}switch((s||o)&&l1(e,n,s,o),c.orient){case kr:a+=Af(t,n,c,d,1,1);break;case Mr:u+=Af(t,n,c,Mi,0,0)+f,a+=Af(t,n,c,d,1,1);break;case oc:u+=Af(t,n,c,d,0,0),a+=Af(t,n,c,Mi,-1,0,1)+f;break;default:u+=Af(t,n,c,d,0,0)}(u||a)&&l1(e,c,u,a),(u=Math.round(c.bounds.x1-i))<0&&(l1(e,n,-u,0),l1(e,c,-u,0))}}function Af(e,t,n,i,s,o,c){const d=e.datum.type!=="symbol",f=n.datum.vgrad,u=d&&(o||!f)&&!c?t.items[0]:t,a=u.bounds[s?"y2":"x2"]-e.padding,m=f&&o?a:0,y=f&&o?0:a,p=s<=0?0:iv(n);return Math.round(i===yv?m:i===Mi?y-p:.5*(a-p))}function l1(e,t,n,i){t.x+=n,t.y+=i,t.bounds.translate(n,i),t.mark.bounds.translate(n,i),e.dirty(t)}function b2e(e){const t=e.reduce((n,i)=>(n[i.column]=Math.max(i.bounds.x2-i.x,n[i.column]||0),n),{});e.forEach(n=>{n.width=t[n.column],n.height=n.bounds.y2-n.y})}function T2e(e,t,n,i,s){var o=t.items[0],c=o.frame,d=o.orient,f=o.anchor,u=o.offset,a=o.padding,m=o.items[0].items[0],y=o.items[1]&&o.items[1].items[0],p=d===kr||d===Mr?i:n,l=0,b=0,L=0,E=0,S=0,x;if(c!==Bm?d===kr?(l=s.y2,p=s.y1):d===Mr?(l=s.y1,p=s.y2):(l=s.x1,p=s.x2):d===kr&&(l=i,p=0),x=f===yv?l:f===Mi?p:(l+p)/2,y&&y.text){switch(d){case sh:case oc:S=m.bounds.height()+a;break;case kr:E=m.bounds.width()+a;break;case Mr:E=-m.bounds.width()-a;break}fi.clear().union(y.bounds),fi.translate(E-(y.x||0),S-(y.y||0)),lu(y,"x",E)|lu(y,"y",S)&&(e.dirty(y),y.bounds.clear().union(fi),y.mark.bounds.clear().union(fi),e.dirty(y)),fi.clear().union(y.bounds)}else fi.clear();switch(fi.union(m.bounds),d){case sh:b=x,L=s.y1-fi.height()-u;break;case kr:b=s.x1-fi.width()-u,L=x;break;case Mr:b=s.x2+fi.width()+u,L=x;break;case oc:b=x,L=s.y2+u;break;default:b=o.x,L=o.y}return lu(o,"x",b)|lu(o,"y",L)&&(fi.translate(b,L),e.dirty(o),o.bounds.clear().union(fi),t.bounds.clear().union(fi),e.dirty(o)),o.bounds}function Jz(e){ae.call(this,null,e)}Le(Jz,ae,{transform(e,t){const n=t.dataflow;return e.mark.items.forEach(i=>{e.layout&&u2e(n,i,e.layout),E2e(n,i,e)}),v2e(e.mark.group)?t.reflow():t}});function v2e(e){return e&&e.mark.role!=="legend-entry"}function E2e(e,t,n){var i=t.items,s=Math.max(0,t.width||0),o=Math.max(0,t.height||0),c=new En().set(0,0,s,o),d=c.clone(),f=c.clone(),u=[],a,m,y,p,l,b;for(l=0,b=i.length;l{y=E.orient||Mr,y!==bv&&(L[y]||(L[y]=[])).push(E)});for(const E in L){const S=L[E];Zz(e,S,y2e(S,E,n.legends,d,f,s,o))}u.forEach(E=>{const S=E.bounds;if(S.equals(E._bounds)||(E.bounds=E._bounds,e.dirty(E),E.bounds=S,e.dirty(E)),n.autosize&&(n.autosize.type===$z||n.autosize.type===qz||n.autosize.type===Vz))switch(E.orient){case kr:case Mr:c.add(S.x1,0).add(S.x2,0);break;case sh:case oc:c.add(0,S.y1).add(0,S.y2)}else c.union(S)})}c.union(d).union(f),a&&c.union(T2e(e,a,s,o,c)),t.clip&&c.set(0,0,t.width||0,t.height||0),S2e(e,t,c,n)}function S2e(e,t,n,i){const s=i.autosize||{},o=s.type;if(e._autosize<1||!o)return;let c=e._width,d=e._height,f=Math.max(0,t.width||0),u=Math.max(0,Math.ceil(-n.x1)),a=Math.max(0,t.height||0),m=Math.max(0,Math.ceil(-n.y1));const y=Math.max(0,Math.ceil(n.x2-f)),p=Math.max(0,Math.ceil(n.y2-a));if(s.contains===Q1e){const l=e.padding();c-=l.left+l.right,d-=l.top+l.bottom}o===bv?(u=0,m=0,f=c,a=d):o===$z?(f=Math.max(0,c-u-y),a=Math.max(0,d-m-p)):o===qz?(f=Math.max(0,c-u-y),d=a+m+p):o===Vz?(c=f+u+y,a=Math.max(0,d-m-p)):o===t2e&&(c=f+u+y,d=a+m+p),e._resizeView(c,d,f,a,[u,m],s.resize)}const x2e=Object.freeze(Object.defineProperty({__proto__:null,bound:Gz,identifier:vv,mark:Wz,overlap:Yz,render:Kz,viewlayout:Jz},Symbol.toStringTag,{value:"Module"}));function Qz(e){ae.call(this,null,e)}Le(Qz,ae,{transform(e,t){if(this.value&&!e.modified())return t.StopPropagation;var n=t.dataflow.locale(),i=t.fork(t.NO_SOURCE|t.NO_FIELDS),s=this.value,o=e.scale,c=e.count==null?e.values?e.values.length:10:e.count,d=DT(o,c,e.minstep),f=e.format||AH(n,o,d,e.formatSpecifier,e.formatType,!!e.values),u=e.values?MH(o,e.values,d):jT(o,d);return s&&(i.rem=s),s=u.map((a,m)=>Dt({index:m/(u.length-1||1),value:a,label:f(a)})),e.extra&&s.length&&s.push(Dt({index:-1,extra:{value:s[0].value},label:""})),i.source=s,i.add=s,this.value=s,i}});function e$(e){ae.call(this,null,e)}function k2e(){return Dt({})}function B2e(e){const t=Ih().test(n=>n.exit);return t.lookup=n=>t.get(e(n)),t}Le(e$,ae,{transform(e,t){var n=t.dataflow,i=t.fork(t.NO_SOURCE|t.NO_FIELDS),s=e.item||k2e,o=e.key||Re,c=this.value;return ue(i.encode)&&(i.encode=null),c&&(e.modified("key")||t.modified(o))&&ce("DataJoin does not support modified key function or fields."),c||(t=t.addAll(),this.value=c=B2e(o)),t.visit(t.ADD,d=>{const f=o(d);let u=c.get(f);u?u.exit?(c.empty--,i.add.push(u)):i.mod.push(u):(u=s(d),c.set(f,u),i.add.push(u)),u.datum=d,u.exit=!1}),t.visit(t.MOD,d=>{const f=o(d),u=c.get(f);u&&(u.datum=d,i.mod.push(u))}),t.visit(t.REM,d=>{const f=o(d),u=c.get(f);d===u.datum&&!u.exit&&(i.rem.push(u),u.exit=!0,++c.empty)}),t.changed(t.ADD_MOD)&&i.modifies("datum"),(t.clean()||e.clean&&c.empty>n.cleanThreshold)&&n.runAfter(c.clean),i}});function t$(e){ae.call(this,null,e)}Le(t$,ae,{transform(e,t){var n=t.fork(t.ADD_REM),i=e.mod||!1,s=e.encoders,o=t.encode;if(ue(o))if(n.changed()||o.every(m=>s[m]))o=o[0],n.encode=null;else return t.StopPropagation;var c=o==="enter",d=s.update||pl,f=s.enter||pl,u=s.exit||pl,a=(o&&!c?s[o]:d)||pl;if(t.changed(t.ADD)&&(t.visit(t.ADD,m=>{f(m,e),d(m,e)}),n.modifies(f.output),n.modifies(d.output),a!==pl&&a!==d&&(t.visit(t.ADD,m=>{a(m,e)}),n.modifies(a.output))),t.changed(t.REM)&&u!==pl&&(t.visit(t.REM,m=>{u(m,e)}),n.modifies(u.output)),c||a!==pl){const m=t.MOD|(e.modified()?t.REFLOW:0);c?(t.visit(m,y=>{const p=f(y,e)||i;(a(y,e)||p)&&n.mod.push(y)}),n.mod.length&&n.modifies(f.output)):t.visit(m,y=>{(a(y,e)||i)&&n.mod.push(y)}),n.mod.length&&n.modifies(a.output)}return n.changed()?n:t.StopPropagation}});function n$(e){ae.call(this,[],e)}Le(n$,ae,{transform(e,t){if(this.value!=null&&!e.modified())return t.StopPropagation;var n=t.dataflow.locale(),i=t.fork(t.NO_SOURCE|t.NO_FIELDS),s=this.value,o=e.type||q_,c=e.scale,d=+e.limit,f=DT(c,e.count==null?5:e.count,e.minstep),u=!!e.values||o===q_,a=e.format||PH(n,c,f,o,e.formatSpecifier,e.formatType,u),m=e.values||RH(c,f),y,p,l,b,L;return s&&(i.rem=s),o===q_?(d&&m.length>d?(t.dataflow.warn("Symbol legend count exceeds limit, filtering items."),s=m.slice(0,d-1),L=!0):s=m,ft(l=e.size)?(!e.values&&c(s[0])===0&&(s=s.slice(1)),b=s.reduce((E,S)=>Math.max(E,l(S,e)),0)):l=Si(b=l||8),s=s.map((E,S)=>Dt({index:S,label:a(E,S,s),value:E,offset:b,size:l(E,e)})),L&&(L=m[s.length],s.push(Dt({index:s.length,label:`…${m.length-s.length} entries`,value:L,offset:b,size:l(L,e)})))):o===nue?(y=c.domain(),p=FH(c,y[0],kt(y)),m.length<3&&!e.values&&y[0]!==kt(y)&&(m=[y[0],kt(y)]),s=m.map((E,S)=>Dt({index:S,label:a(E,S,m),value:E,perc:p(E)}))):(l=m.length-1,p=hue(c),s=m.map((E,S)=>Dt({index:S,label:a(E,S,m),value:E,perc:S?p(E):0,perc2:S===l?1:p(m[S+1])}))),i.source=s,i.add=s,this.value=s,i}});const F2e=e=>e.source.x,I2e=e=>e.source.y,O2e=e=>e.target.x,M2e=e=>e.target.y;function Ev(e){ae.call(this,{},e)}Ev.Definition={type:"LinkPath",metadata:{modifies:!0},params:[{name:"sourceX",type:"field",default:"source.x"},{name:"sourceY",type:"field",default:"source.y"},{name:"targetX",type:"field",default:"target.x"},{name:"targetY",type:"field",default:"target.y"},{name:"orient",type:"enum",default:"vertical",values:["horizontal","vertical","radial"]},{name:"shape",type:"enum",default:"line",values:["line","arc","curve","diagonal","orthogonal"]},{name:"require",type:"signal"},{name:"as",type:"string",default:"path"}]};Le(Ev,ae,{transform(e,t){var n=e.sourceX||F2e,i=e.sourceY||I2e,s=e.targetX||O2e,o=e.targetY||M2e,c=e.as||"path",d=e.orient||"vertical",f=e.shape||"line",u=XI.get(f+"-"+d)||XI.get(f);return u||ce("LinkPath unsupported type: "+e.shape+(e.orient?"-"+e.orient:"")),t.visit(t.SOURCE,a=>{a[c]=u(n(a),i(a),s(a),o(a))}),t.reflow(e.modified()).modifies(c)}});const i$=(e,t,n,i)=>"M"+e+","+t+"L"+n+","+i,A2e=(e,t,n,i)=>i$(t*Math.cos(e),t*Math.sin(e),i*Math.cos(n),i*Math.sin(n)),s$=(e,t,n,i)=>{var s=n-e,o=i-t,c=Math.sqrt(s*s+o*o)/2,d=180*Math.atan2(o,s)/Math.PI;return"M"+e+","+t+"A"+c+","+c+" "+d+" 0 1 "+n+","+i},N2e=(e,t,n,i)=>s$(t*Math.cos(e),t*Math.sin(e),i*Math.cos(n),i*Math.sin(n)),r$=(e,t,n,i)=>{const s=n-e,o=i-t,c=.2*(s+o),d=.2*(o-s);return"M"+e+","+t+"C"+(e+c)+","+(t+d)+" "+(n+d)+","+(i-c)+" "+n+","+i},C2e=(e,t,n,i)=>r$(t*Math.cos(e),t*Math.sin(e),i*Math.cos(n),i*Math.sin(n)),R2e=(e,t,n,i)=>"M"+e+","+t+"V"+i+"H"+n,P2e=(e,t,n,i)=>"M"+e+","+t+"H"+n+"V"+i,D2e=(e,t,n,i)=>{const s=Math.cos(e),o=Math.sin(e),c=Math.cos(n),d=Math.sin(n),f=Math.abs(n-e)>Math.PI?n<=e:n>e;return"M"+t*s+","+t*o+"A"+t+","+t+" 0 0,"+(f?1:0)+" "+t*c+","+t*d+"L"+i*c+","+i*d},j2e=(e,t,n,i)=>{const s=(e+n)/2;return"M"+e+","+t+"C"+s+","+t+" "+s+","+i+" "+n+","+i},U2e=(e,t,n,i)=>{const s=(t+i)/2;return"M"+e+","+t+"C"+e+","+s+" "+n+","+s+" "+n+","+i},H2e=(e,t,n,i)=>{const s=Math.cos(e),o=Math.sin(e),c=Math.cos(n),d=Math.sin(n),f=(t+i)/2;return"M"+t*s+","+t*o+"C"+f*s+","+f*o+" "+f*c+","+f*d+" "+i*c+","+i*d},XI=Ih({line:i$,"line-radial":A2e,arc:s$,"arc-radial":N2e,curve:r$,"curve-radial":C2e,"orthogonal-horizontal":R2e,"orthogonal-vertical":P2e,"orthogonal-radial":D2e,"diagonal-horizontal":j2e,"diagonal-vertical":U2e,"diagonal-radial":H2e});function Sv(e){ae.call(this,null,e)}Sv.Definition={type:"Pie",metadata:{modifies:!0},params:[{name:"field",type:"field"},{name:"startAngle",type:"number",default:0},{name:"endAngle",type:"number",default:6.283185307179586},{name:"sort",type:"boolean",default:!1},{name:"as",type:"string",array:!0,length:2,default:["startAngle","endAngle"]}]};Le(Sv,ae,{transform(e,t){var n=e.as||["startAngle","endAngle"],i=n[0],s=n[1],o=e.field||kh,c=e.startAngle||0,d=e.endAngle!=null?e.endAngle:2*Math.PI,f=t.source,u=f.map(o),a=u.length,m=c,y=(d-c)/CR(u),p=Os(a),l,b,L;for(e.sort&&p.sort((E,S)=>u[E]-u[S]),l=0;l-1)return i;var s=t.domain,o=e.type,c=t.zero||t.zero===void 0&&$2e(e),d,f;if(!s)return 0;if(a$(o)&&t.padding&&s[0]!==kt(s)&&(s=X2e(o,s,t.range,t.padding,t.exponent,t.constant)),(c||t.domainMin!=null||t.domainMax!=null||t.domainMid!=null)&&(d=(s=s.slice()).length-1||1,c&&(s[0]>0&&(s[0]=0),s[d]<0&&(s[d]=0)),t.domainMin!=null&&(s[0]=t.domainMin),t.domainMax!=null&&(s[d]=t.domainMax),t.domainMid!=null)){f=t.domainMid;const u=f>s[d]?d+1:fs+(o<0?-1:o>0?1:0),0));i!==t.length&&n.warn("Log scale domain includes zero: "+Te(t))}return t}function K2e(e,t,n){let i=t.bins;if(i&&!ue(i)){const s=e.domain(),o=s[0],c=kt(s),d=i.step;let f=i.start==null?o:i.start,u=i.stop==null?c:i.stop;d||ce("Scale bins parameter missing step property."),fc&&(u=d*Math.floor(c/d)),i=Os(f,u+d/2,d)}return i?e.bins=i:e.bins&&delete e.bins,e.type===MT&&(i?!t.domain&&!t.domainRaw&&(e.domain(i),n=i.length):e.bins=e.domain()),n}function Z2e(e,t,n){var i=e.type,s=t.round||!1,o=t.range;if(t.rangeStep!=null)o=J2e(i,t,n);else if(t.scheme&&(o=Q2e(i,t,n),ft(o))){if(e.interpolator)return e.interpolator(o);ce(`Scale type ${i} does not support interpolating color schemes.`)}if(o&&SH(i))return e.interpolator(pm(a8(o,t.reverse),t.interpolate,t.interpolateGamma));o&&t.interpolate&&e.interpolate?e.interpolate(RT(t.interpolate,t.interpolateGamma)):ft(e.round)?e.round(s):ft(e.rangeRound)&&e.interpolate(s?v0:bc),o&&e.range(a8(o,t.reverse))}function J2e(e,t,n){e!==mH&&e!==VL&&ce("Only band and point scales support rangeStep.");var i=(t.paddingOuter!=null?t.paddingOuter:t.padding)||0,s=e===VL?1:(t.paddingInner!=null?t.paddingInner:t.padding)||0;return[0,t.rangeStep*IT(n,s,i)]}function Q2e(e,t,n){var i=t.schemeExtent,s,o;return ue(t.scheme)?o=pm(t.scheme,t.interpolate,t.interpolateGamma):(s=t.scheme.toLowerCase(),o=PT(s),o||ce(`Unrecognized scheme name: ${t.scheme}`)),n=e===_m?n+1:e===MT?n-1:e===Ju||e===gm?+t.schemeCount||z2e:n,SH(e)?KI(o,i,t.reverse):ft(o)?BH(KI(o,i),n):e===OT?o:o.slice(0,n)}function KI(e,t,n){return ft(e)&&(t||n)?kH(e,a8(t||[0,1],n)):e}function a8(e,t){return t?e.slice().reverse():e}function c$(e){ae.call(this,null,e)}Le(c$,ae,{transform(e,t){const n=e.modified("sort")||t.changed(t.ADD)||t.modified(e.sort.fields)||t.modified("datum");return n&&t.source.sort(hf(e.sort)),this.modified(n),t}});const ZI="zero",d$="center",f$="normalize",u$=["y0","y1"];function xv(e){ae.call(this,null,e)}xv.Definition={type:"Stack",metadata:{modifies:!0},params:[{name:"field",type:"field"},{name:"groupby",type:"field",array:!0},{name:"sort",type:"compare"},{name:"offset",type:"enum",default:ZI,values:[ZI,d$,f$]},{name:"as",type:"string",array:!0,length:2,default:u$}]};Le(xv,ae,{transform(e,t){var n=e.as||u$,i=n[0],s=n[1],o=hf(e.sort),c=e.field||kh,d=e.offset===d$?e0e:e.offset===f$?t0e:n0e,f,u,a,m;for(f=i0e(t.source,e.groupby,o,c),u=0,a=f.length,m=f.max;ub(a),c,d,f,u,a,m,y,p,l;if(t==null)s.push(e.slice());else for(c={},d=0,f=e.length;dl&&(l=p),n&&y.sort(n)}return s.max=l,s}const s0e=Object.freeze(Object.defineProperty({__proto__:null,axisticks:Qz,datajoin:e$,encode:t$,legendentries:n$,linkpath:Ev,pie:Sv,scale:o$,sortitems:c$,stack:xv},Symbol.toStringTag,{value:"Module"}));var r0e=Math.abs,o8=Math.cos,Ay=Math.sin,a0e=1e-6,h$=Math.PI,l8=h$/2,JI=o0e(2);function QI(e){return e>1?l8:e<-1?-l8:Math.asin(e)}function o0e(e){return e>0?Math.sqrt(e):0}function l0e(e,t){var n=e*Ay(t),i=30,s;do t-=s=(t+Ay(t)-n)/(1+o8(t));while(r0e(s)>a0e&&--i>0);return t/2}function c0e(e,t,n){function i(s,o){return[e*s*o8(o=l0e(n,o)),t*Ay(o)]}return i.invert=function(s,o){return o=QI(o/t),[s/(e*o8(o)),QI((2*o+Ay(2*o))/n)]},i}var d0e=c0e(JI/l8,JI,h$);function f0e(){return Ka(d0e).scale(169.529)}const u0e=dD(),c8=["clipAngle","clipExtent","scale","translate","center","rotate","parallels","precision","reflectX","reflectY","coefficient","distance","fraction","lobes","parallel","radius","ratio","spacing","tilt"];function h0e(e,t){return function n(){const i=t();return i.type=e,i.path=dD().projection(i),i.copy=i.copy||function(){const s=n();return c8.forEach(o=>{i[o]&&s[o](i[o]())}),s.path.pointRadius(i.path.pointRadius()),s},TH(i)}}function kv(e,t){if(!e||typeof e!="string")throw new Error("Projection type must be a name string.");return e=e.toLowerCase(),arguments.length>1?(Ny[e]=h0e(e,t),this):Ny[e]||null}function g$(e){return e&&e.path||u0e}const Ny={albers:uD,albersusa:tre,azimuthalequalarea:nre,azimuthalequidistant:ire,conicconformal:are,conicequalarea:ay,conicequidistant:cre,equalEarth:fre,equirectangular:ore,gnomonic:ure,identity:hre,mercator:sre,mollweide:f0e,naturalEarth1:gre,orthographic:_re,stereographic:pre,transversemercator:yre};for(const e in Ny)kv(e,Ny[e]);function g0e(){}const go=[[],[[[1,1.5],[.5,1]]],[[[1.5,1],[1,1.5]]],[[[1.5,1],[.5,1]]],[[[1,.5],[1.5,1]]],[[[1,1.5],[.5,1]],[[1,.5],[1.5,1]]],[[[1,.5],[1,1.5]]],[[[1,.5],[.5,1]]],[[[.5,1],[1,.5]]],[[[1,1.5],[1,.5]]],[[[.5,1],[1,.5]],[[1.5,1],[1,1.5]]],[[[1.5,1],[1,.5]]],[[[.5,1],[1.5,1]]],[[[1,1.5],[1.5,1]]],[[[.5,1],[1,1.5]]],[]];function _$(){var e=1,t=1,n=d;function i(f,u){return u.map(a=>s(f,a))}function s(f,u){var a=[],m=[];return o(f,u,y=>{n(y,f,u),_0e(y)>0?a.push([y]):m.push(y)}),m.forEach(y=>{for(var p=0,l=a.length,b;p=u,go[L<<1].forEach(x);++p=u,go[b|L<<1].forEach(x);for(go[L<<0].forEach(x);++l=u,E=f[l*e]>=u,go[L<<1|E<<2].forEach(x);++p=u,S=E,E=f[l*e+p+1]>=u,go[b|L<<1|E<<2|S<<3].forEach(x);go[L|E<<3].forEach(x)}for(p=-1,E=f[l*e]>=u,go[E<<2].forEach(x);++p=u,go[E<<2|S<<3].forEach(x);go[E<<3].forEach(x);function x(F){var k=[F[0][0]+p,F[0][1]+l],M=[F[1][0]+p,F[1][1]+l],O=c(k),C=c(M),P,j;(P=y[O])?(j=m[C])?(delete y[P.end],delete m[j.start],P===j?(P.ring.push(M),a(P.ring)):m[P.start]=y[j.end]={start:P.start,end:j.end,ring:P.ring.concat(j.ring)}):(delete y[P.end],P.ring.push(M),y[P.end=C]=P):(P=m[C])?(j=y[O])?(delete m[P.start],delete y[j.end],P===j?(P.ring.push(M),a(P.ring)):m[j.start]=y[P.end]={start:j.start,end:P.end,ring:j.ring.concat(P.ring)}):(delete m[P.start],P.ring.unshift(k),m[P.start=O]=P):m[O]=y[C]={start:O,end:C,ring:[k,M]}}}function c(f){return f[0]*2+f[1]*(e+1)*4}function d(f,u,a){f.forEach(m=>{var y=m[0],p=m[1],l=y|0,b=p|0,L,E=u[b*e+l];y>0&&y0&&p=0&&a>=0||ce("invalid size"),e=u,t=a,i},i.smooth=function(f){return arguments.length?(n=f?d:g0e,i):n===d},i}function _0e(e){for(var t=0,n=e.length,i=e[n-1][1]*e[0][0]-e[n-1][0]*e[0][1];++ti!=p>i&&n<(y-u)*(i-a)/(p-a)+u&&(s=-s)}return s}function m0e(e,t,n){var i;return w0e(e,t,n)&&L0e(e[i=+(e[0]===t[0])],n[i],t[i])}function w0e(e,t,n){return(t[0]-e[0])*(n[1]-e[1])===(n[0]-e[0])*(t[1]-e[1])}function L0e(e,t,n){return e<=t&&t<=n||n<=t&&t<=e}function p$(e,t,n){return function(i){var s=Ua(i),o=n?Math.min(s[0],0):s[0],c=s[1],d=c-o,f=t?Jl(o,c,e):d/(e+1);return Os(o+f,c,f)}}function Bv(e){ae.call(this,null,e)}Bv.Definition={type:"Isocontour",metadata:{generates:!0},params:[{name:"field",type:"field"},{name:"thresholds",type:"number",array:!0},{name:"levels",type:"number"},{name:"nice",type:"boolean",default:!1},{name:"resolve",type:"enum",values:["shared","independent"],default:"independent"},{name:"zero",type:"boolean",default:!0},{name:"smooth",type:"boolean",default:!0},{name:"scale",type:"number",expr:!0},{name:"translate",type:"number",array:!0,expr:!0},{name:"as",type:"string",null:!0,default:"contour"}]};Le(Bv,ae,{transform(e,t){if(this.value&&!t.changed()&&!e.modified())return t.StopPropagation;var n=t.fork(t.NO_SOURCE|t.NO_FIELDS),i=t.materialize(t.SOURCE).source,s=e.field||Ei,o=_$().smooth(e.smooth!==!1),c=e.thresholds||b0e(i,s,e),d=e.as===null?null:e.as||"contour",f=[];return i.forEach(u=>{const a=s(u),m=o.size([a.width,a.height])(a.values,ue(c)?c:c(a.values));T0e(m,a,u,e),m.forEach(y=>{f.push(cm(u,Dt(d!=null?{[d]:y}:y)))})}),this.value&&(n.rem=this.value),this.value=n.source=n.add=f,n}});function b0e(e,t,n){const i=p$(n.levels||10,n.nice,n.zero!==!1);return n.resolve!=="shared"?i:i(e.map(s=>bd(t(s).values)))}function T0e(e,t,n,i){let s=i.scale||t.scale,o=i.translate||t.translate;if(ft(s)&&(s=s(n,i)),ft(o)&&(o=o(n,i)),(s===1||s==null)&&!o)return;const c=(Yt(s)?s:s[0])||1,d=(Yt(s)?s:s[1])||1,f=o&&o[0]||0,u=o&&o[1]||0;e.forEach(y$(t,c,d,f,u))}function y$(e,t,n,i,s){const o=e.x1||0,c=e.y1||0,d=t*n<0;function f(m){m.forEach(u)}function u(m){d&&m.reverse(),m.forEach(a)}function a(m){m[0]=(m[0]-o)*t+i,m[1]=(m[1]-c)*n+s}return function(m){return m.coordinates.forEach(f),m}}function eO(e,t,n){const i=e>=0?e:wb(t,n);return Math.round((Math.sqrt(4*i*i+1)-1)/2)}function Rw(e){return ft(e)?e:Si(+e)}function m$(){var e=f=>f[0],t=f=>f[1],n=kh,i=[-1,-1],s=960,o=500,c=2;function d(f,u){const a=eO(i[0],f,e)>>c,m=eO(i[1],f,t)>>c,y=a?a+2:0,p=m?m+2:0,l=2*y+(s>>c),b=2*p+(o>>c),L=new Float32Array(l*b),E=new Float32Array(l*b);let S=L;f.forEach(F=>{const k=y+(+e(F)>>c),M=p+(+t(F)>>c);k>=0&&k=0&&M0&&m>0?(Nf(l,b,L,E,a),Cf(l,b,E,L,m),Nf(l,b,L,E,a),Cf(l,b,E,L,m),Nf(l,b,L,E,a),Cf(l,b,E,L,m)):a>0?(Nf(l,b,L,E,a),Nf(l,b,E,L,a),Nf(l,b,L,E,a),S=E):m>0&&(Cf(l,b,L,E,m),Cf(l,b,E,L,m),Cf(l,b,L,E,m),S=E);const x=u?Math.pow(2,-2*c):1/CR(S);for(let F=0,k=l*b;F>c),y2:p+(o>>c)}}return d.x=function(f){return arguments.length?(e=Rw(f),d):e},d.y=function(f){return arguments.length?(t=Rw(f),d):t},d.weight=function(f){return arguments.length?(n=Rw(f),d):n},d.size=function(f){if(!arguments.length)return[s,o];var u=+f[0],a=+f[1];return u>=0&&a>=0||ce("invalid size"),s=u,o=a,d},d.cellSize=function(f){return arguments.length?((f=+f)>=1||ce("invalid cell size"),c=Math.floor(Math.log(f)/Math.LN2),d):1<=s&&(d>=o&&(f-=n[d-o+c*e]),i[d-s+c*e]=f/Math.min(d+1,e-1+o-d,o))}function Cf(e,t,n,i,s){const o=(s<<1)+1;for(let c=0;c=s&&(d>=o&&(f-=n[c+(d-o)*e]),i[c+(d-s)*e]=f/Math.min(d+1,t-1+o-d,o))}function Fv(e){ae.call(this,null,e)}Fv.Definition={type:"KDE2D",metadata:{generates:!0},params:[{name:"size",type:"number",array:!0,length:2,required:!0},{name:"x",type:"field",required:!0},{name:"y",type:"field",required:!0},{name:"weight",type:"field"},{name:"groupby",type:"field",array:!0},{name:"cellSize",type:"number"},{name:"bandwidth",type:"number",array:!0,length:2},{name:"counts",type:"boolean",default:!1},{name:"as",type:"string",default:"grid"}]};const v0e=["x","y","weight","size","cellSize","bandwidth"];function w$(e,t){return v0e.forEach(n=>t[n]!=null?e[n](t[n]):0),e}Le(Fv,ae,{transform(e,t){if(this.value&&!t.changed()&&!e.modified())return t.StopPropagation;var n=t.fork(t.NO_SOURCE|t.NO_FIELDS),i=t.materialize(t.SOURCE).source,s=E0e(i,e.groupby),o=(e.groupby||[]).map(mn),c=w$(m$(),e),d=e.as||"grid",f=[];function u(a,m){for(let y=0;yDt(u({[d]:c(a,e.counts)},a.dims))),this.value&&(n.rem=this.value),this.value=n.source=n.add=f,n}});function E0e(e,t){var n=[],i=a=>a(d),s,o,c,d,f,u;if(t==null)n.push(e);else for(s={},o=0,c=e.length;on.push(d(a))),o&&c&&(t.visit(f,a=>{var m=o(a),y=c(a);m!=null&&y!=null&&(m=+m)===m&&(y=+y)===y&&i.push([m,y])}),n=n.concat({type:d8,geometry:{type:S0e,coordinates:i}})),this.value={type:Ov,features:n}}});function Av(e){ae.call(this,null,e)}Av.Definition={type:"GeoPath",metadata:{modifies:!0},params:[{name:"projection",type:"projection"},{name:"field",type:"field"},{name:"pointRadius",type:"number",expr:!0},{name:"as",type:"string",default:"path"}]};Le(Av,ae,{transform(e,t){var n=t.fork(t.ALL),i=this.value,s=e.field||Ei,o=e.as||"path",c=n.SOURCE;!i||e.modified()?(this.value=i=g$(e.projection),n.materialize().reflow()):c=s===Ei||t.modified(s.fields)?n.ADD_MOD:n.ADD;const d=x0e(i,e.pointRadius);return n.visit(c,f=>f[o]=i(s(f))),i.pointRadius(d),n.modifies(o)}});function x0e(e,t){const n=e.pointRadius();return e.context(null),t!=null&&e.pointRadius(t),n}function Nv(e){ae.call(this,null,e)}Nv.Definition={type:"GeoPoint",metadata:{modifies:!0},params:[{name:"projection",type:"projection",required:!0},{name:"fields",type:"field",array:!0,required:!0,length:2},{name:"as",type:"string",array:!0,length:2,default:["x","y"]}]};Le(Nv,ae,{transform(e,t){var n=e.projection,i=e.fields[0],s=e.fields[1],o=e.as||["x","y"],c=o[0],d=o[1],f;function u(a){const m=n([i(a),s(a)]);m?(a[c]=m[0],a[d]=m[1]):(a[c]=void 0,a[d]=void 0)}return e.modified()?t=t.materialize().reflow(!0).visit(t.SOURCE,u):(f=t.modified(i.fields)||t.modified(s.fields),t.visit(f?t.ADD_MOD:t.ADD,u)),t.modifies(o)}});function Cv(e){ae.call(this,null,e)}Cv.Definition={type:"GeoShape",metadata:{modifies:!0,nomod:!0},params:[{name:"projection",type:"projection"},{name:"field",type:"field",default:"datum"},{name:"pointRadius",type:"number",expr:!0},{name:"as",type:"string",default:"shape"}]};Le(Cv,ae,{transform(e,t){var n=t.fork(t.ALL),i=this.value,s=e.as||"shape",o=n.ADD;return(!i||e.modified())&&(this.value=i=k0e(g$(e.projection),e.field||hs("datum"),e.pointRadius),n.materialize().reflow(),o=n.SOURCE),n.visit(o,c=>c[s]=i),n.modifies(s)}});function k0e(e,t,n){const i=n==null?s=>e(t(s)):s=>{var o=e.pointRadius(),c=e.pointRadius(n)(t(s));return e.pointRadius(o),c};return i.context=s=>(e.context(s),i),i}function Rv(e){ae.call(this,[],e),this.generator=Ase()}Rv.Definition={type:"Graticule",metadata:{changes:!0,generates:!0},params:[{name:"extent",type:"array",array:!0,length:2,content:{type:"number",array:!0,length:2}},{name:"extentMajor",type:"array",array:!0,length:2,content:{type:"number",array:!0,length:2}},{name:"extentMinor",type:"array",array:!0,length:2,content:{type:"number",array:!0,length:2}},{name:"step",type:"number",array:!0,length:2},{name:"stepMajor",type:"number",array:!0,length:2,default:[90,360]},{name:"stepMinor",type:"number",array:!0,length:2,default:[10,10]},{name:"precision",type:"number",default:2.5}]};Le(Rv,ae,{transform(e,t){var n=this.value,i=this.generator,s;if(!n.length||e.modified())for(const o in e)ft(i[o])&&i[o](e[o]);return s=i(),n.length?t.mod.push(jU(n[0],s)):t.add.push(Dt(s)),n[0]=s,t}});function Pv(e){ae.call(this,null,e)}Pv.Definition={type:"heatmap",metadata:{modifies:!0},params:[{name:"field",type:"field"},{name:"color",type:"string",expr:!0},{name:"opacity",type:"number",expr:!0},{name:"resolve",type:"enum",values:["shared","independent"],default:"independent"},{name:"as",type:"string",default:"image"}]};Le(Pv,ae,{transform(e,t){if(!t.changed()&&!e.modified())return t.StopPropagation;var n=t.materialize(t.SOURCE).source,i=e.resolve==="shared",s=e.field||Ei,o=F0e(e.opacity,e),c=B0e(e.color,e),d=e.as||"image",f={$x:0,$y:0,$value:0,$max:i?bd(n.map(u=>bd(s(u).values))):0};return n.forEach(u=>{const a=s(u),m=dt({},u,f);i||(m.$max=bd(a.values||[])),u[d]=I0e(a,m,c.dep?c:Si(c(m)),o.dep?o:Si(o(m)))}),t.reflow(!0).modifies(d)}});function B0e(e,t){let n;return ft(e)?(n=i=>ec(e(i,t)),n.dep=L$(e)):n=Si(ec(e||"#888")),n}function F0e(e,t){let n;return ft(e)?(n=i=>e(i,t),n.dep=L$(e)):e?n=Si(e):(n=i=>i.$value/i.$max||0,n.dep=!0),n}function L$(e){if(!ft(e))return!1;const t=zr(mi(e));return t.$x||t.$y||t.$value||t.$max}function I0e(e,t,n,i){const s=e.width,o=e.height,c=e.x1||0,d=e.y1||0,f=e.x2||s,u=e.y2||o,a=e.values,m=a?L=>a[L]:Bl,y=N0(f-c,u-d),p=y.getContext("2d"),l=p.getImageData(0,0,f-c,u-d),b=l.data;for(let L=d,E=0;L{e[i]!=null&&tO(n,i,e[i])})):c8.forEach(i=>{e.modified(i)&&tO(n,i,e[i])}),e.pointRadius!=null&&n.path.pointRadius(e.pointRadius),e.fit&&O0e(n,e),t.fork(t.NO_SOURCE|t.NO_FIELDS)}});function O0e(e,t){const n=A0e(t.fit);t.extent?e.fitExtent(t.extent,n):t.size&&e.fitSize(t.size,n)}function M0e(e){const t=kv((e||"mercator").toLowerCase());return t||ce("Unrecognized projection type: "+e),t()}function tO(e,t,n){ft(e[t])&&e[t](n)}function A0e(e){return e=Se(e),e.length===1?e[0]:{type:Ov,features:e.reduce((t,n)=>t.concat(N0e(n)),[])}}function N0e(e){return e.type===Ov?e.features:Se(e).filter(t=>t!=null).map(t=>t.type===d8?t:{type:d8,geometry:t})}const C0e=Object.freeze(Object.defineProperty({__proto__:null,contour:Iv,geojson:Mv,geopath:Av,geopoint:Nv,geoshape:Cv,graticule:Rv,heatmap:Pv,isocontour:Bv,kde2d:Fv,projection:b$},Symbol.toStringTag,{value:"Module"})),nO={center:vie,collide:zie,nbody:Qie,link:qie,x:ese,y:tse},$1="forces",f8=["alpha","alphaMin","alphaTarget","velocityDecay","forces"],R0e=["static","iterations"],T$=["x","y","vx","vy"];function Dv(e){ae.call(this,null,e)}Dv.Definition={type:"Force",metadata:{modifies:!0},params:[{name:"static",type:"boolean",default:!1},{name:"restart",type:"boolean",default:!1},{name:"iterations",type:"number",default:300},{name:"alpha",type:"number",default:1},{name:"alphaMin",type:"number",default:.001},{name:"alphaTarget",type:"number",default:0},{name:"velocityDecay",type:"number",default:.4},{name:"forces",type:"param",array:!0,params:[{key:{force:"center"},params:[{name:"x",type:"number",default:0},{name:"y",type:"number",default:0}]},{key:{force:"collide"},params:[{name:"radius",type:"number",expr:!0},{name:"strength",type:"number",default:.7},{name:"iterations",type:"number",default:1}]},{key:{force:"nbody"},params:[{name:"strength",type:"number",default:-30,expr:!0},{name:"theta",type:"number",default:.9},{name:"distanceMin",type:"number",default:1},{name:"distanceMax",type:"number"}]},{key:{force:"link"},params:[{name:"links",type:"data"},{name:"id",type:"field"},{name:"distance",type:"number",default:30,expr:!0},{name:"strength",type:"number",expr:!0},{name:"iterations",type:"number",default:1}]},{key:{force:"x"},params:[{name:"strength",type:"number",default:.1},{name:"x",type:"field"}]},{key:{force:"y"},params:[{name:"strength",type:"number",default:.1},{name:"y",type:"field"}]}]},{name:"as",type:"string",array:!0,modify:!1,default:T$}]};Le(Dv,ae,{transform(e,t){var n=this.value,i=t.changed(t.ADD_REM),s=e.modified(f8),o=e.iterations||300;if(n?(i&&(t.modifies("index"),n.nodes(t.source)),(s||t.changed(t.MOD))&&v$(n,e,0,t)):(this.value=n=D0e(t.source,e),n.on("tick",P0e(t.dataflow,this)),e.static||(i=!0,n.tick()),t.modifies("index")),s||i||e.modified(R0e)||t.changed()&&e.restart){if(n.alpha(Math.max(n.alpha(),e.alpha||1)).alphaDecay(1-Math.pow(n.alphaMin(),1/o)),e.static)for(n.stop();--o>=0;)n.tick();else if(n.stopped()&&n.restart(),!i)return t.StopPropagation}return this.finish(e,t)},finish(e,t){const n=t.dataflow;for(let d=this._argops,f=0,u=d.length,a;fe.touch(t).run()}function D0e(e,t){const n=Jie(e),i=n.stop,s=n.restart;let o=!1;return n.stopped=()=>o,n.restart=()=>(o=!1,s()),n.stop=()=>(o=!0,i()),v$(n,t,!0).on("end",()=>o=!0)}function v$(e,t,n,i){var s=Se(t.forces),o,c,d,f;for(o=0,c=f8.length;ot(i,n):t)}const z0e=Object.freeze(Object.defineProperty({__proto__:null,force:Dv},Symbol.toStringTag,{value:"Module"}));function u8(e,t,n){const i={};return e.each(s=>{const o=s.data;n(o)&&(i[t(o)]=s)}),e.lookup=i,e}function jv(e){ae.call(this,null,e)}jv.Definition={type:"Nest",metadata:{treesource:!0,changes:!0},params:[{name:"keys",type:"field",array:!0},{name:"generate",type:"boolean"}]};const $0e=e=>e.values;Le(jv,ae,{transform(e,t){t.source||ce("Nest transform requires an upstream data source.");var n=e.generate,i=e.modified(),s=t.clone(),o=this.value;return(!o||i||t.changed())&&(o&&o.each(c=>{c.children&&lm(c.data)&&s.rem.push(c.data)}),this.value=o=Q7({values:Se(e.keys).reduce((c,d)=>(c.key(d),c),q0e()).entries(s.source)},$0e),n&&o.each(c=>{c.children&&(c=Dt(c.data),s.add.push(c),s.source.push(c))}),u8(o,Re,Re)),s.source.root=o,s}});function q0e(){const e=[],t={entries:s=>i(n(s,0),0),key:s=>(e.push(s),t)};function n(s,o){if(o>=e.length)return s;const c=s.length,d=e[o++],f={},u={};let a=-1,m,y,p;for(;++ae.length)return s;const c=[];for(const d in s)c.push({key:d,values:i(s[d],o)});return c}return t}function tl(e){ae.call(this,null,e)}const V0e=(e,t)=>e.parent===t.parent?1:2;Le(tl,ae,{transform(e,t){(!t.source||!t.source.root)&&ce(this.constructor.name+" transform requires a backing tree data source.");const n=this.layout(e.method),i=this.fields,s=t.source.root,o=e.as||i;e.field?s.sum(e.field):s.count(),e.sort&&s.sort(hf(e.sort,c=>c.data)),G0e(n,this.params,e),n.separation&&n.separation(e.separation!==!1?V0e:kh);try{this.value=n(s)}catch(c){ce(c)}return s.each(c=>W0e(c,i,o)),t.reflow(e.modified()).modifies(o).modifies("leaf")}});function G0e(e,t,n){for(let i,s=0,o=t.length;so[Re(c)]=1),i.each(c=>{const d=c.data,f=c.parent&&c.parent.data;f&&o[Re(d)]&&o[Re(f)]&&s.add.push(Dt({source:f,target:d}))}),this.value=s.add):t.changed(t.MOD)&&(t.visit(t.MOD,c=>o[Re(c)]=1),n.forEach(c=>{(o[Re(c.source)]||o[Re(c.target)])&&s.mod.push(c)})),s}});const sO={binary:_ae,dice:k0,slice:D4,slicedice:pae,squarify:ID,resquarify:yae},p8=["x0","y0","x1","y1","depth","children"];function Vv(e){tl.call(this,e)}Vv.Definition={type:"Treemap",metadata:{tree:!0,modifies:!0},params:[{name:"field",type:"field"},{name:"sort",type:"compare"},{name:"method",type:"enum",default:"squarify",values:["squarify","resquarify","binary","dice","slice","slicedice"]},{name:"padding",type:"number",default:0},{name:"paddingInner",type:"number",default:0},{name:"paddingOuter",type:"number",default:0},{name:"paddingTop",type:"number",default:0},{name:"paddingRight",type:"number",default:0},{name:"paddingBottom",type:"number",default:0},{name:"paddingLeft",type:"number",default:0},{name:"ratio",type:"number",default:1.618033988749895},{name:"round",type:"boolean",default:!1},{name:"size",type:"number",array:!0,length:2},{name:"as",type:"string",array:!0,length:p8.length,default:p8}]};Le(Vv,tl,{layout(){const e=gae();return e.ratio=t=>{const n=e.tile();n.ratio&&e.tile(n.ratio(t))},e.method=t=>{De(sO,t)?e.tile(sO[t]):ce("Unrecognized Treemap layout method: "+t)},e},params:["method","ratio","size","round","padding","paddingInner","paddingOuter","paddingTop","paddingRight","paddingBottom","paddingLeft"],fields:p8});const Y0e=Object.freeze(Object.defineProperty({__proto__:null,nest:jv,pack:Uv,partition:Hv,stratify:zv,tree:$v,treelinks:qv,treemap:Vv},Symbol.toStringTag,{value:"Module"}));function Pw(e,t){if(typeof document<"u"&&document.createElement){const n=document.createElement("canvas");if(n&&n.getContext)return n.width=e,n.height=t,n}return null}const Dw=4278190080;function X0e(e,t){const n=e.bitmap();return(t||[]).forEach(i=>n.set(e(i.boundary[0]),e(i.boundary[3]))),[n,void 0]}function K0e(e,t,n,i,s){const o=e.width,c=e.height,d=i||s,f=Pw(o,c).getContext("2d"),u=Pw(o,c).getContext("2d"),a=d&&Pw(o,c).getContext("2d");n.forEach(C=>J_(f,C,!1)),J_(u,t,!1),d&&J_(a,t,!0);const m=jw(f,o,c),y=jw(u,o,c),p=d&&jw(a,o,c),l=e.bitmap(),b=d&&e.bitmap();let L,E,S,x,F,k,M,O;for(E=0;E{s.items.forEach(o=>J_(e,o.items,n))}):Ds[i].draw(e,{items:n?t.map(Z0e):t})}function Z0e(e){const t=cm(e,{});return t.stroke&&t.strokeOpacity!==0||t.fill&&t.fillOpacity!==0?{...t,strokeOpacity:1,stroke:"#000",fillOpacity:0}:t}const _o=5,Fi=31,$2=32,Sl=new Uint32Array($2+1),Tr=new Uint32Array($2+1);Tr[0]=0;Sl[0]=~Tr[0];for(let e=1;e<=$2;++e)Tr[e]=Tr[e-1]<<1|1,Sl[e]=~Tr[e];function J0e(e,t){const n=new Uint32Array(~~((e*t+$2)/$2));function i(o,c){n[o]|=c}function s(o,c){n[o]&=c}return{array:n,get:(o,c)=>{const d=c*e+o;return n[d>>>_o]&1<<(d&Fi)},set:(o,c)=>{const d=c*e+o;i(d>>>_o,1<<(d&Fi))},clear:(o,c)=>{const d=c*e+o;s(d>>>_o,~(1<<(d&Fi)))},getRange:(o,c,d,f)=>{let u=f,a,m,y,p;for(;u>=c;--u)if(a=u*e+o,m=u*e+d,y=a>>>_o,p=m>>>_o,y===p){if(n[y]&Sl[a&Fi]&Tr[(m&Fi)+1])return!0}else{if(n[y]&Sl[a&Fi]||n[p]&Tr[(m&Fi)+1])return!0;for(let l=y+1;l{let u,a,m,y,p;for(;c<=f;++c)if(u=c*e+o,a=c*e+d,m=u>>>_o,y=a>>>_o,m===y)i(m,Sl[u&Fi]&Tr[(a&Fi)+1]);else for(i(m,Sl[u&Fi]),i(y,Tr[(a&Fi)+1]),p=m+1;p{let u,a,m,y,p;for(;c<=f;++c)if(u=c*e+o,a=c*e+d,m=u>>>_o,y=a>>>_o,m===y)s(m,Tr[u&Fi]|Sl[(a&Fi)+1]);else for(s(m,Tr[u&Fi]),s(y,Sl[(a&Fi)+1]),p=m+1;po<0||c<0||f>=t||d>=e}}function Q0e(e,t,n){const i=Math.max(1,Math.sqrt(e*t/1e6)),s=~~((e+2*n+i)/i),o=~~((t+2*n+i)/i),c=d=>~~((d+n)/i);return c.invert=d=>d*i-n,c.bitmap=()=>J0e(s,o),c.ratio=i,c.padding=n,c.width=e,c.height=t,c}function e3e(e,t,n,i){const s=e.width,o=e.height;return function(c){const d=c.datum.datum.items[i].items,f=d.length,u=c.datum.fontSize,a=Pr.width(c.datum,c.datum.text);let m=0,y,p,l,b,L,E,S;for(let x=0;x=m&&(m=S,c.x=L,c.y=E);return L=a/2,E=u/2,y=c.x-L,p=c.x+L,l=c.y-E,b=c.y+E,c.align="center",y<0&&p<=s?c.align="left":0<=y&&ss||t-(c=i/2)<0||t+c>o}function Rl(e,t,n,i,s,o,c,d){const f=s*o/(i*2),u=e(t-f),a=e(t+f),m=e(n-(o=o/2)),y=e(n+o);return c.outOfBounds(u,m,a,y)||c.getRange(u,m,a,y)||d&&d.getRange(u,m,a,y)}function t3e(e,t,n,i){const s=e.width,o=e.height,c=t[0],d=t[1];function f(u,a,m,y,p){const l=e.invert(u),b=e.invert(a);let L=m,E=o,S;if(!Cy(l,b,y,p,s,o)&&!Rl(e,l,b,p,y,L,c,d)&&!Rl(e,l,b,p,y,p,c,null)){for(;E-L>=1;)S=(L+E)/2,Rl(e,l,b,p,y,S,c,d)?E=S:L=S;if(L>m)return[l,b,L,!0]}}return function(u){const a=u.datum.datum.items[i].items,m=a.length,y=u.datum.fontSize,p=Pr.width(u.datum,u.datum.text);let l=n?y:0,b=!1,L=!1,E=0,S,x,F,k,M,O,C,P,j,R,H,z,Y,$,W,X,G;for(let oe=0;oex&&(G=S,S=x,x=G),F>k&&(G=F,F=k,k=G),j=e(S),H=e(x),R=~~((j+H)/2),z=e(F),$=e(k),Y=~~((z+$)/2),C=R;C>=j;--C)for(P=Y;P>=z;--P)X=f(C,P,l,p,y),X&&([u.x,u.y,l,b]=X);for(C=R;C<=H;++C)for(P=Y;P<=$;++P)X=f(C,P,l,p,y),X&&([u.x,u.y,l,b]=X);!b&&!n&&(W=Math.abs(x-S+k-F),M=(S+x)/2,O=(F+k)/2,W>=E&&!Cy(M,O,p,y,s,o)&&!Rl(e,M,O,y,p,y,c,null)&&(E=W,u.x=M,u.y=O,L=!0))}return b||L?(M=p/2,O=y/2,c.setRange(e(u.x-M),e(u.y-O),e(u.x+M),e(u.y+O)),u.align="center",u.baseline="middle",!0):!1}}const n3e=[-1,-1,1,1],i3e=[-1,1,-1,1];function s3e(e,t,n,i){const s=e.width,o=e.height,c=t[0],d=t[1],f=e.bitmap();return function(u){const a=u.datum.datum.items[i].items,m=a.length,y=u.datum.fontSize,p=Pr.width(u.datum,u.datum.text),l=[];let b=n?y:0,L=!1,E=!1,S=0,x,F,k,M,O,C,P,j,R,H,z,Y;for(let $=0;$=1;)z=(R+H)/2,Rl(e,O,C,y,p,z,c,d)?H=z:R=z;R>b&&(u.x=O,u.y=C,b=R,L=!0)}}!L&&!n&&(Y=Math.abs(F-x+M-k),O=(x+F)/2,C=(k+M)/2,Y>=S&&!Cy(O,C,p,y,s,o)&&!Rl(e,O,C,y,p,y,c,null)&&(S=Y,u.x=O,u.y=C,E=!0))}return L||E?(O=p/2,C=y/2,c.setRange(e(u.x-O),e(u.y-C),e(u.x+O),e(u.y+C)),u.align="center",u.baseline="middle",!0):!1}}const r3e=["right","center","left"],a3e=["bottom","middle","top"];function o3e(e,t,n,i){const s=e.width,o=e.height,c=t[0],d=t[1],f=i.length;return function(u){const a=u.boundary,m=u.datum.fontSize;if(a[2]<0||a[5]<0||a[0]>s||a[3]>o)return!1;let y=u.textWidth??0,p,l,b,L,E,S,x,F,k,M,O,C,P,j,R;for(let H=0;H>>2&3)-1,b=p===0&&l===0||i[H]<0,L=p&&l?Math.SQRT1_2:1,E=i[H]<0?-1:1,S=a[1+p]+i[H]*p*L,O=a[4+l]+E*m*l/2+i[H]*l*L,F=O-m/2,k=O+m/2,C=e(S),j=e(F),R=e(k),!y)if(rO(C,C,j,R,c,d,S,S,F,k,a,b))y=Pr.width(u.datum,u.datum.text);else continue;if(M=S+E*y*p/2,S=M-y/2,x=M+y/2,C=e(S),P=e(x),rO(C,P,j,R,c,d,S,x,F,k,a,b))return u.x=p?p*E<0?x:S:M,u.y=l?l*E<0?k:F:O,u.align=r3e[p*E+1],u.baseline=a3e[l*E+1],c.setRange(C,j,P,R),!0}return!1}}function rO(e,t,n,i,s,o,c,d,f,u,a,m){return!(s.outOfBounds(e,n,t,i)||(m&&o||s).getRange(e,n,t,i))}const Uw=0,Hw=4,zw=8,$w=0,qw=1,Vw=2,l3e={"top-left":Uw+$w,top:Uw+qw,"top-right":Uw+Vw,left:Hw+$w,middle:Hw+qw,right:Hw+Vw,"bottom-left":zw+$w,bottom:zw+qw,"bottom-right":zw+Vw},c3e={naive:e3e,"reduced-search":t3e,floodfill:s3e};function d3e(e,t,n,i,s,o,c,d,f,u,a){if(!e.length)return e;const m=Math.max(i.length,s.length),y=f3e(i,m),p=u3e(s,m),l=h3e(e[0].datum),b=l==="group"&&e[0].datum.items[f].marktype,L=b==="area",E=g3e(l,b,d,f),S=u===null||u===1/0,x=L&&a==="naive";let F=-1,k=-1;const M=e.map(j=>{const R=S?Pr.width(j,j.text):void 0;return F=Math.max(F,R),k=Math.max(k,j.fontSize),{datum:j,opacity:0,x:void 0,y:void 0,align:void 0,baseline:void 0,boundary:E(j),textWidth:R}});u=u===null||u===1/0?Math.max(F,k)+Math.max(...i):u;const O=Q0e(t[0],t[1],u);let C;if(!x){n&&M.sort((H,z)=>n(H.datum,z.datum));let j=!1;for(let H=0;HH.datum);C=o.length||R?K0e(O,R||[],o,j,L):X0e(O,c&&M)}const P=L?c3e[a](O,C,c,f):o3e(O,C,p,y);return M.forEach(j=>j.opacity=+P(j)),M}function f3e(e,t){const n=new Float64Array(t),i=e.length;for(let s=0;s[o.x,o.x,o.x,o.y,o.y,o.y];return e?e==="line"||e==="area"?o=>s(o.datum):t==="line"?o=>{const c=o.datum.items[i].items;return s(c.length?c[n==="start"?0:c.length-1]:{x:NaN,y:NaN})}:o=>{const c=o.datum.bounds;return[c.x1,(c.x1+c.x2)/2,c.x2,c.y1,(c.y1+c.y2)/2,c.y2]}:s}const y8=["x","y","opacity","align","baseline"],E$=["top-left","left","bottom-left","top","bottom","top-right","right","bottom-right"];function Gv(e){ae.call(this,null,e)}Gv.Definition={type:"Label",metadata:{modifies:!0},params:[{name:"size",type:"number",array:!0,length:2,required:!0},{name:"sort",type:"compare"},{name:"anchor",type:"string",array:!0,default:E$},{name:"offset",type:"number",array:!0,default:[1]},{name:"padding",type:"number",default:0,null:!0},{name:"lineAnchor",type:"string",values:["start","end"],default:"end"},{name:"markIndex",type:"number",default:0},{name:"avoidBaseMark",type:"boolean",default:!0},{name:"avoidMarks",type:"data",array:!0},{name:"method",type:"string",default:"naive"},{name:"as",type:"string",array:!0,length:y8.length,default:y8}]};Le(Gv,ae,{transform(e,t){function n(o){const c=e[o];return ft(c)&&t.modified(c.fields)}const i=e.modified();if(!(i||t.changed(t.ADD_REM)||n("sort")))return;(!e.size||e.size.length!==2)&&ce("Size parameter should be specified as a [width, height] array.");const s=e.as||y8;return d3e(t.materialize(t.SOURCE).source||[],e.size,e.sort,Se(e.offset==null?1:e.offset),Se(e.anchor||E$),e.avoidMarks||[],e.avoidBaseMark!==!1,e.lineAnchor||"end",e.markIndex||0,e.padding===void 0?0:e.padding,e.method||"naive").forEach(o=>{const c=o.datum;c[s[0]]=o.x,c[s[1]]=o.y,c[s[2]]=o.opacity,c[s[3]]=o.align,c[s[4]]=o.baseline}),t.reflow(i).modifies(s)}});const _3e=Object.freeze(Object.defineProperty({__proto__:null,label:Gv},Symbol.toStringTag,{value:"Module"}));function S$(e,t){var n=[],i=function(a){return a(d)},s,o,c,d,f,u;if(t==null)n.push(e);else for(s={},o=0,c=e.length;o{Fj(u,e.x,e.y,e.bandwidth||.3).forEach(a=>{const m={};for(let y=0;ye==="poly"?t:e==="quad"?2:1;function Yv(e){ae.call(this,null,e)}Yv.Definition={type:"Regression",metadata:{generates:!0},params:[{name:"x",type:"field",required:!0},{name:"y",type:"field",required:!0},{name:"groupby",type:"field",array:!0},{name:"method",type:"string",default:"linear",values:Object.keys(m8)},{name:"order",type:"number",default:3},{name:"extent",type:"number",array:!0,length:2},{name:"params",type:"boolean",default:!1},{name:"as",type:"string",array:!0}]};Le(Yv,ae,{transform(e,t){const n=t.fork(t.NO_SOURCE|t.NO_FIELDS);if(!this.value||t.changed()||e.modified()){const i=t.materialize(t.SOURCE).source,s=S$(i,e.groupby),o=(e.groupby||[]).map(mn),c=e.method||"linear",d=e.order||3,f=p3e(c,d),u=e.as||[mn(e.x),mn(e.y)],a=m8[c],m=[];let y=e.extent;De(m8,c)||ce("Invalid regression method: "+c),y!=null&&c==="log"&&y[0]<=0&&(t.dataflow.warn("Ignoring extent with values <= 0 for log regression."),y=null),s.forEach(p=>{if(p.length<=f){t.dataflow.warn("Skipping regression with more parameters than data points.");return}const b=a(p,e.x,e.y,d);if(e.params){m.push(Dt({keys:p.dims,coef:b.coef,rSquared:b.rSquared}));return}const L=y||Ua(p,e.x),E=S=>{const x={};for(let F=0;FE([S,b.predict(S)])):em(b.predict,L,25,200).forEach(E)}),this.value&&(n.rem=this.value),this.value=n.add=n.source=m}return n}});const y3e=Object.freeze(Object.defineProperty({__proto__:null,loess:Wv,regression:Yv},Symbol.toStringTag,{value:"Module"}));function Xv(e){ae.call(this,null,e)}Xv.Definition={type:"Voronoi",metadata:{modifies:!0},params:[{name:"x",type:"field",required:!0},{name:"y",type:"field",required:!0},{name:"size",type:"number",array:!0,length:2},{name:"extent",type:"array",array:!0,length:2,default:[[-1e5,-1e5],[1e5,1e5]],content:{type:"number",array:!0,length:2}},{name:"as",type:"string",default:"path"}]};const m3e=[-1e5,-1e5,1e5,1e5];Le(Xv,ae,{transform(e,t){const n=e.as||"path",i=t.source;if(!i||!i.length)return t;let s=e.size;s=s?[0,0,s[0],s[1]]:(s=e.extent)?[s[0][0],s[0][1],s[1][0],s[1][1]]:m3e;const o=this.value=H7.from(i,e.x,e.y).voronoi(s);for(let c=0,d=i.length;c>5,Q_=1<<11;function b3e(){var e=[256,256],t,n,i,s,o,c,d,f=x$,u=[],a=Math.random,m={};m.layout=function(){for(var l=y(N0()),b=k3e((e[0]>>5)*e[1]),L=null,E=u.length,S=-1,x=[],F=u.map(M=>({text:t(M),font:n(M),style:s(M),weight:o(M),rotate:c(M),size:~~(i(M)+1e-14),padding:d(M),xoff:0,yoff:0,x1:0,y1:0,x0:0,y0:0,hasText:!1,sprite:null,datum:M})).sort((M,O)=>O.size-M.size);++S>1,k.y=e[1]*(a()+.5)>>1,T3e(l,k,F,S),k.hasText&&p(b,k,L)&&(x.push(k),L?E3e(L,k):L=[{x:k.x+k.x0,y:k.y+k.y0},{x:k.x+k.x1,y:k.y+k.y1}],k.x-=e[0]>>1,k.y-=e[1]>>1)}return x};function y(l){l.width=l.height=1;var b=Math.sqrt(l.getContext("2d").getImageData(0,0,1,1).data.length>>2);l.width=(q1<<5)/b,l.height=Q_/b;var L=l.getContext("2d");return L.fillStyle=L.strokeStyle="red",L.textAlign="center",{context:L,ratio:b}}function p(l,b,L){for(var E=b.x,S=b.y,x=Math.sqrt(e[0]*e[0]+e[1]*e[1]),F=f(e),k=a()<.5?1:-1,M=-k,O,C,P;(O=F(M+=k))&&(C=~~O[0],P=~~O[1],!(Math.min(Math.abs(C),Math.abs(P))>=x));)if(b.x=E+C,b.y=S+P,!(b.x+b.x0<0||b.y+b.y0<0||b.x+b.x1>e[0]||b.y+b.y1>e[1])&&(!L||!v3e(b,l,e[0]))&&(!L||S3e(b,L))){for(var j=b.sprite,R=b.width>>5,H=e[0]>>5,z=b.x-(R<<4),Y=z&127,$=32-Y,W=b.y1-b.y0,X=(b.y+b.y0)*H+(z>>5),G,oe=0;oe>>Y:0);X+=H}return b.sprite=null,!0}return!1}return m.words=function(l){return arguments.length?(u=l,m):u},m.size=function(l){return arguments.length?(e=[+l[0],+l[1]],m):e},m.font=function(l){return arguments.length?(n=Dc(l),m):n},m.fontStyle=function(l){return arguments.length?(s=Dc(l),m):s},m.fontWeight=function(l){return arguments.length?(o=Dc(l),m):o},m.rotate=function(l){return arguments.length?(c=Dc(l),m):c},m.text=function(l){return arguments.length?(t=Dc(l),m):t},m.spiral=function(l){return arguments.length?(f=B3e[l]||l,m):f},m.fontSize=function(l){return arguments.length?(i=Dc(l),m):i},m.padding=function(l){return arguments.length?(d=Dc(l),m):d},m.random=function(l){return arguments.length?(a=l,m):a},m}function T3e(e,t,n,i){if(!t.sprite){var s=e.context,o=e.ratio;s.clearRect(0,0,(q1<<5)/o,Q_/o);var c=0,d=0,f=0,u=n.length,a,m,y,p,l;for(--i;++i>5<<5,y=~~Math.max(Math.abs(S+x),Math.abs(S-x))}else a=a+31>>5<<5;if(y>f&&(f=y),c+a>=q1<<5&&(c=0,d+=f,f=0),d+y>=Q_)break;s.translate((c+(a>>1))/o,(d+(y>>1))/o),t.rotate&&s.rotate(t.rotate*Gw),s.fillText(t.text,0,0),t.padding&&(s.lineWidth=2*t.padding,s.strokeText(t.text,0,0)),s.restore(),t.width=a,t.height=y,t.xoff=c,t.yoff=d,t.x1=a>>1,t.y1=y>>1,t.x0=-t.x1,t.y0=-t.y1,t.hasText=!0,c+=a}for(var k=s.getImageData(0,0,(q1<<5)/o,Q_/o).data,M=[];--i>=0;)if(t=n[i],!!t.hasText){for(a=t.width,m=a>>5,y=t.y1-t.y0,p=0;p>5),j=k[(d+l)*(q1<<5)+(c+p)<<2]?1<<31-p%32:0;M[P]|=j,O|=j}O?C=l:(t.y0++,y--,l--,d++)}t.y1=t.y0+C,t.sprite=M.slice(0,(t.y1-t.y0)*m)}}}function v3e(e,t,n){n>>=5;for(var i=e.sprite,s=e.width>>5,o=e.x-(s<<4),c=o&127,d=32-c,f=e.y1-e.y0,u=(e.y+e.y0)*n+(o>>5),a,m=0;m>>c:0))&t[u+y])return!0;u+=n}return!1}function E3e(e,t){var n=e[0],i=e[1];t.x+t.x0i.x&&(i.x=t.x+t.x1),t.y+t.y1>i.y&&(i.y=t.y+t.y1)}function S3e(e,t){return e.x+e.x1>t[0].x&&e.x+e.x0t[0].y&&e.y+e.y0b(l(L))}s.forEach(l=>{l[c[0]]=NaN,l[c[1]]=NaN,l[c[3]]=0});const u=o.words(s).text(e.text).size(e.size||[500,500]).padding(e.padding||1).spiral(e.spiral||"archimedean").rotate(e.rotate||0).font(e.font||"sans-serif").fontStyle(e.fontStyle||"normal").fontWeight(e.fontWeight||"normal").fontSize(d).random(ir).layout(),a=o.size(),m=a[0]>>1,y=a[1]>>1,p=u.length;for(let l=0,b,L;lnew Uint8Array(e),M3e=e=>new Uint16Array(e),a2=e=>new Uint32Array(e);function A3e(){let e=8,t=[],n=a2(0),i=i_(0,e),s=i_(0,e);return{data:()=>t,seen:()=>n=N3e(n,t.length),add(o){for(let c=0,d=t.length,f=o.length,u;ct.length,curr:()=>i,prev:()=>s,reset:o=>s[o]=i[o],all:()=>e<257?255:e<65537?65535:4294967295,set(o,c){i[o]|=c},clear(o,c){i[o]&=~c},resize(o,c){const d=i.length;(o>d||c>e)&&(e=Math.max(c,e),i=i_(o,e,i),s=i_(o,e))}}}function N3e(e,t,n){return e.length>=t?e:(n=n||new e.constructor(t),n.set(e),n)}function i_(e,t,n){const i=(t<257?O3e:t<65537?M3e:a2)(e);return n&&i.set(n),i}function aO(e,t,n){const i=1<0)for(L=0;Le,size:()=>n}}function C3e(e,t){return e.sort.call(t,(n,i)=>{const s=e[n],o=e[i];return so?1:0}),rQ(e,t)}function R3e(e,t,n,i,s,o,c,d,f){let u=0,a=0,m;for(m=0;ut.modified(i.fields));return n?this.reinit(e,t):this.eval(e,t)}else return this.init(e,t)},init(e,t){const n=e.fields,i=e.query,s=this._indices={},o=this._dims=[],c=i.length;let d=0,f,u;for(;d{const o=s.remove(t,n);for(const c in i)i[c].reindex(o)})},update(e,t,n){const i=this._dims,s=e.query,o=t.stamp,c=i.length;let d=0,f,u;for(n.filters=0,u=0;up)for(L=p,E=Math.min(m,l);Ll)for(L=Math.max(m,l),E=y;Lm)for(l=m,b=Math.min(u,y);ly)for(l=Math.max(u,y),b=a;ld[a]&n?null:c[a];return o.filter(o.MOD,u),s&s-1?(o.filter(o.ADD,a=>{const m=d[a]&n;return!m&&m^f[a]&n?c[a]:null}),o.filter(o.REM,a=>{const m=d[a]&n;return m&&!(m^(m^f[a]&n))?c[a]:null})):(o.filter(o.ADD,u),o.filter(o.REM,a=>(d[a]&n)===s?c[a]:null)),o.filter(o.SOURCE,a=>u(a._index))}});const P3e=Object.freeze(Object.defineProperty({__proto__:null,crossfilter:Zv,resolvefilter:Jv},Symbol.toStringTag,{value:"Module"})),D3e="RawCode",zd="Literal",j3e="Property",U3e="Identifier",H3e="ArrayExpression",z3e="BinaryExpression",B$="CallExpression",$3e="ConditionalExpression",q3e="LogicalExpression",V3e="MemberExpression",G3e="ObjectExpression",W3e="UnaryExpression";function Xr(e){this.type=e}Xr.prototype.visit=function(e){let t,n,i;if(e(this))return 1;for(t=Y3e(this),n=0,i=t.length;n";to[$d]="Identifier";to[Sc]="Keyword";to[Im]="Null";to[pf]="Numeric";to[Zi]="Punctuator";to[Y0]="String";to[X3e]="RegularExpression";var K3e="ArrayExpression",Z3e="BinaryExpression",J3e="CallExpression",Q3e="ConditionalExpression",F$="Identifier",ege="Literal",tge="LogicalExpression",nge="MemberExpression",ige="ObjectExpression",sge="Property",rge="UnaryExpression",Vn="Unexpected token %0",age="Unexpected number",oge="Unexpected string",lge="Unexpected identifier",cge="Unexpected reserved word",dge="Unexpected end of input",w8="Invalid regular expression",Ww="Invalid regular expression: missing /",I$="Octal literals are not allowed in strict mode.",fge="Duplicate data property in object literal not allowed in strict mode",ii="ILLEGAL",q2="Disabled.",uge=new RegExp("[\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0370-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0620-\\u064A\\u066E\\u066F\\u0671-\\u06D3\\u06D5\\u06E5\\u06E6\\u06EE\\u06EF\\u06FA-\\u06FC\\u06FF\\u0710\\u0712-\\u072F\\u074D-\\u07A5\\u07B1\\u07CA-\\u07EA\\u07F4\\u07F5\\u07FA\\u0800-\\u0815\\u081A\\u0824\\u0828\\u0840-\\u0858\\u08A0-\\u08B2\\u0904-\\u0939\\u093D\\u0950\\u0958-\\u0961\\u0971-\\u0980\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BD\\u09CE\\u09DC\\u09DD\\u09DF-\\u09E1\\u09F0\\u09F1\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A59-\\u0A5C\\u0A5E\\u0A72-\\u0A74\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABD\\u0AD0\\u0AE0\\u0AE1\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3D\\u0B5C\\u0B5D\\u0B5F-\\u0B61\\u0B71\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BD0\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3D\\u0C58\\u0C59\\u0C60\\u0C61\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBD\\u0CDE\\u0CE0\\u0CE1\\u0CF1\\u0CF2\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D3A\\u0D3D\\u0D4E\\u0D60\\u0D61\\u0D7A-\\u0D7F\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0E01-\\u0E30\\u0E32\\u0E33\\u0E40-\\u0E46\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB0\\u0EB2\\u0EB3\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EDC-\\u0EDF\\u0F00\\u0F40-\\u0F47\\u0F49-\\u0F6C\\u0F88-\\u0F8C\\u1000-\\u102A\\u103F\\u1050-\\u1055\\u105A-\\u105D\\u1061\\u1065\\u1066\\u106E-\\u1070\\u1075-\\u1081\\u108E\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176C\\u176E-\\u1770\\u1780-\\u17B3\\u17D7\\u17DC\\u1820-\\u1877\\u1880-\\u18A8\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1950-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19C1-\\u19C7\\u1A00-\\u1A16\\u1A20-\\u1A54\\u1AA7\\u1B05-\\u1B33\\u1B45-\\u1B4B\\u1B83-\\u1BA0\\u1BAE\\u1BAF\\u1BBA-\\u1BE5\\u1C00-\\u1C23\\u1C4D-\\u1C4F\\u1C5A-\\u1C7D\\u1CE9-\\u1CEC\\u1CEE-\\u1CF1\\u1CF5\\u1CF6\\u1D00-\\u1DBF\\u1E00-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u2071\\u207F\\u2090-\\u209C\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CEE\\u2CF2\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D80-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2E2F\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA61F\\uA62A\\uA62B\\uA640-\\uA66E\\uA67F-\\uA69D\\uA6A0-\\uA6EF\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA78E\\uA790-\\uA7AD\\uA7B0\\uA7B1\\uA7F7-\\uA801\\uA803-\\uA805\\uA807-\\uA80A\\uA80C-\\uA822\\uA840-\\uA873\\uA882-\\uA8B3\\uA8F2-\\uA8F7\\uA8FB\\uA90A-\\uA925\\uA930-\\uA946\\uA960-\\uA97C\\uA984-\\uA9B2\\uA9CF\\uA9E0-\\uA9E4\\uA9E6-\\uA9EF\\uA9FA-\\uA9FE\\uAA00-\\uAA28\\uAA40-\\uAA42\\uAA44-\\uAA4B\\uAA60-\\uAA76\\uAA7A\\uAA7E-\\uAAAF\\uAAB1\\uAAB5\\uAAB6\\uAAB9-\\uAABD\\uAAC0\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEA\\uAAF2-\\uAAF4\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB5F\\uAB64\\uAB65\\uABC0-\\uABE2\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D\\uFB1F-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF21-\\uFF3A\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]"),hge=new RegExp("[\\xAA\\xB5\\xBA\\xC0-\\xD6\\xD8-\\xF6\\xF8-\\u02C1\\u02C6-\\u02D1\\u02E0-\\u02E4\\u02EC\\u02EE\\u0300-\\u0374\\u0376\\u0377\\u037A-\\u037D\\u037F\\u0386\\u0388-\\u038A\\u038C\\u038E-\\u03A1\\u03A3-\\u03F5\\u03F7-\\u0481\\u0483-\\u0487\\u048A-\\u052F\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u0591-\\u05BD\\u05BF\\u05C1\\u05C2\\u05C4\\u05C5\\u05C7\\u05D0-\\u05EA\\u05F0-\\u05F2\\u0610-\\u061A\\u0620-\\u0669\\u066E-\\u06D3\\u06D5-\\u06DC\\u06DF-\\u06E8\\u06EA-\\u06FC\\u06FF\\u0710-\\u074A\\u074D-\\u07B1\\u07C0-\\u07F5\\u07FA\\u0800-\\u082D\\u0840-\\u085B\\u08A0-\\u08B2\\u08E4-\\u0963\\u0966-\\u096F\\u0971-\\u0983\\u0985-\\u098C\\u098F\\u0990\\u0993-\\u09A8\\u09AA-\\u09B0\\u09B2\\u09B6-\\u09B9\\u09BC-\\u09C4\\u09C7\\u09C8\\u09CB-\\u09CE\\u09D7\\u09DC\\u09DD\\u09DF-\\u09E3\\u09E6-\\u09F1\\u0A01-\\u0A03\\u0A05-\\u0A0A\\u0A0F\\u0A10\\u0A13-\\u0A28\\u0A2A-\\u0A30\\u0A32\\u0A33\\u0A35\\u0A36\\u0A38\\u0A39\\u0A3C\\u0A3E-\\u0A42\\u0A47\\u0A48\\u0A4B-\\u0A4D\\u0A51\\u0A59-\\u0A5C\\u0A5E\\u0A66-\\u0A75\\u0A81-\\u0A83\\u0A85-\\u0A8D\\u0A8F-\\u0A91\\u0A93-\\u0AA8\\u0AAA-\\u0AB0\\u0AB2\\u0AB3\\u0AB5-\\u0AB9\\u0ABC-\\u0AC5\\u0AC7-\\u0AC9\\u0ACB-\\u0ACD\\u0AD0\\u0AE0-\\u0AE3\\u0AE6-\\u0AEF\\u0B01-\\u0B03\\u0B05-\\u0B0C\\u0B0F\\u0B10\\u0B13-\\u0B28\\u0B2A-\\u0B30\\u0B32\\u0B33\\u0B35-\\u0B39\\u0B3C-\\u0B44\\u0B47\\u0B48\\u0B4B-\\u0B4D\\u0B56\\u0B57\\u0B5C\\u0B5D\\u0B5F-\\u0B63\\u0B66-\\u0B6F\\u0B71\\u0B82\\u0B83\\u0B85-\\u0B8A\\u0B8E-\\u0B90\\u0B92-\\u0B95\\u0B99\\u0B9A\\u0B9C\\u0B9E\\u0B9F\\u0BA3\\u0BA4\\u0BA8-\\u0BAA\\u0BAE-\\u0BB9\\u0BBE-\\u0BC2\\u0BC6-\\u0BC8\\u0BCA-\\u0BCD\\u0BD0\\u0BD7\\u0BE6-\\u0BEF\\u0C00-\\u0C03\\u0C05-\\u0C0C\\u0C0E-\\u0C10\\u0C12-\\u0C28\\u0C2A-\\u0C39\\u0C3D-\\u0C44\\u0C46-\\u0C48\\u0C4A-\\u0C4D\\u0C55\\u0C56\\u0C58\\u0C59\\u0C60-\\u0C63\\u0C66-\\u0C6F\\u0C81-\\u0C83\\u0C85-\\u0C8C\\u0C8E-\\u0C90\\u0C92-\\u0CA8\\u0CAA-\\u0CB3\\u0CB5-\\u0CB9\\u0CBC-\\u0CC4\\u0CC6-\\u0CC8\\u0CCA-\\u0CCD\\u0CD5\\u0CD6\\u0CDE\\u0CE0-\\u0CE3\\u0CE6-\\u0CEF\\u0CF1\\u0CF2\\u0D01-\\u0D03\\u0D05-\\u0D0C\\u0D0E-\\u0D10\\u0D12-\\u0D3A\\u0D3D-\\u0D44\\u0D46-\\u0D48\\u0D4A-\\u0D4E\\u0D57\\u0D60-\\u0D63\\u0D66-\\u0D6F\\u0D7A-\\u0D7F\\u0D82\\u0D83\\u0D85-\\u0D96\\u0D9A-\\u0DB1\\u0DB3-\\u0DBB\\u0DBD\\u0DC0-\\u0DC6\\u0DCA\\u0DCF-\\u0DD4\\u0DD6\\u0DD8-\\u0DDF\\u0DE6-\\u0DEF\\u0DF2\\u0DF3\\u0E01-\\u0E3A\\u0E40-\\u0E4E\\u0E50-\\u0E59\\u0E81\\u0E82\\u0E84\\u0E87\\u0E88\\u0E8A\\u0E8D\\u0E94-\\u0E97\\u0E99-\\u0E9F\\u0EA1-\\u0EA3\\u0EA5\\u0EA7\\u0EAA\\u0EAB\\u0EAD-\\u0EB9\\u0EBB-\\u0EBD\\u0EC0-\\u0EC4\\u0EC6\\u0EC8-\\u0ECD\\u0ED0-\\u0ED9\\u0EDC-\\u0EDF\\u0F00\\u0F18\\u0F19\\u0F20-\\u0F29\\u0F35\\u0F37\\u0F39\\u0F3E-\\u0F47\\u0F49-\\u0F6C\\u0F71-\\u0F84\\u0F86-\\u0F97\\u0F99-\\u0FBC\\u0FC6\\u1000-\\u1049\\u1050-\\u109D\\u10A0-\\u10C5\\u10C7\\u10CD\\u10D0-\\u10FA\\u10FC-\\u1248\\u124A-\\u124D\\u1250-\\u1256\\u1258\\u125A-\\u125D\\u1260-\\u1288\\u128A-\\u128D\\u1290-\\u12B0\\u12B2-\\u12B5\\u12B8-\\u12BE\\u12C0\\u12C2-\\u12C5\\u12C8-\\u12D6\\u12D8-\\u1310\\u1312-\\u1315\\u1318-\\u135A\\u135D-\\u135F\\u1380-\\u138F\\u13A0-\\u13F4\\u1401-\\u166C\\u166F-\\u167F\\u1681-\\u169A\\u16A0-\\u16EA\\u16EE-\\u16F8\\u1700-\\u170C\\u170E-\\u1714\\u1720-\\u1734\\u1740-\\u1753\\u1760-\\u176C\\u176E-\\u1770\\u1772\\u1773\\u1780-\\u17D3\\u17D7\\u17DC\\u17DD\\u17E0-\\u17E9\\u180B-\\u180D\\u1810-\\u1819\\u1820-\\u1877\\u1880-\\u18AA\\u18B0-\\u18F5\\u1900-\\u191E\\u1920-\\u192B\\u1930-\\u193B\\u1946-\\u196D\\u1970-\\u1974\\u1980-\\u19AB\\u19B0-\\u19C9\\u19D0-\\u19D9\\u1A00-\\u1A1B\\u1A20-\\u1A5E\\u1A60-\\u1A7C\\u1A7F-\\u1A89\\u1A90-\\u1A99\\u1AA7\\u1AB0-\\u1ABD\\u1B00-\\u1B4B\\u1B50-\\u1B59\\u1B6B-\\u1B73\\u1B80-\\u1BF3\\u1C00-\\u1C37\\u1C40-\\u1C49\\u1C4D-\\u1C7D\\u1CD0-\\u1CD2\\u1CD4-\\u1CF6\\u1CF8\\u1CF9\\u1D00-\\u1DF5\\u1DFC-\\u1F15\\u1F18-\\u1F1D\\u1F20-\\u1F45\\u1F48-\\u1F4D\\u1F50-\\u1F57\\u1F59\\u1F5B\\u1F5D\\u1F5F-\\u1F7D\\u1F80-\\u1FB4\\u1FB6-\\u1FBC\\u1FBE\\u1FC2-\\u1FC4\\u1FC6-\\u1FCC\\u1FD0-\\u1FD3\\u1FD6-\\u1FDB\\u1FE0-\\u1FEC\\u1FF2-\\u1FF4\\u1FF6-\\u1FFC\\u200C\\u200D\\u203F\\u2040\\u2054\\u2071\\u207F\\u2090-\\u209C\\u20D0-\\u20DC\\u20E1\\u20E5-\\u20F0\\u2102\\u2107\\u210A-\\u2113\\u2115\\u2119-\\u211D\\u2124\\u2126\\u2128\\u212A-\\u212D\\u212F-\\u2139\\u213C-\\u213F\\u2145-\\u2149\\u214E\\u2160-\\u2188\\u2C00-\\u2C2E\\u2C30-\\u2C5E\\u2C60-\\u2CE4\\u2CEB-\\u2CF3\\u2D00-\\u2D25\\u2D27\\u2D2D\\u2D30-\\u2D67\\u2D6F\\u2D7F-\\u2D96\\u2DA0-\\u2DA6\\u2DA8-\\u2DAE\\u2DB0-\\u2DB6\\u2DB8-\\u2DBE\\u2DC0-\\u2DC6\\u2DC8-\\u2DCE\\u2DD0-\\u2DD6\\u2DD8-\\u2DDE\\u2DE0-\\u2DFF\\u2E2F\\u3005-\\u3007\\u3021-\\u302F\\u3031-\\u3035\\u3038-\\u303C\\u3041-\\u3096\\u3099\\u309A\\u309D-\\u309F\\u30A1-\\u30FA\\u30FC-\\u30FF\\u3105-\\u312D\\u3131-\\u318E\\u31A0-\\u31BA\\u31F0-\\u31FF\\u3400-\\u4DB5\\u4E00-\\u9FCC\\uA000-\\uA48C\\uA4D0-\\uA4FD\\uA500-\\uA60C\\uA610-\\uA62B\\uA640-\\uA66F\\uA674-\\uA67D\\uA67F-\\uA69D\\uA69F-\\uA6F1\\uA717-\\uA71F\\uA722-\\uA788\\uA78B-\\uA78E\\uA790-\\uA7AD\\uA7B0\\uA7B1\\uA7F7-\\uA827\\uA840-\\uA873\\uA880-\\uA8C4\\uA8D0-\\uA8D9\\uA8E0-\\uA8F7\\uA8FB\\uA900-\\uA92D\\uA930-\\uA953\\uA960-\\uA97C\\uA980-\\uA9C0\\uA9CF-\\uA9D9\\uA9E0-\\uA9FE\\uAA00-\\uAA36\\uAA40-\\uAA4D\\uAA50-\\uAA59\\uAA60-\\uAA76\\uAA7A-\\uAAC2\\uAADB-\\uAADD\\uAAE0-\\uAAEF\\uAAF2-\\uAAF6\\uAB01-\\uAB06\\uAB09-\\uAB0E\\uAB11-\\uAB16\\uAB20-\\uAB26\\uAB28-\\uAB2E\\uAB30-\\uAB5A\\uAB5C-\\uAB5F\\uAB64\\uAB65\\uABC0-\\uABEA\\uABEC\\uABED\\uABF0-\\uABF9\\uAC00-\\uD7A3\\uD7B0-\\uD7C6\\uD7CB-\\uD7FB\\uF900-\\uFA6D\\uFA70-\\uFAD9\\uFB00-\\uFB06\\uFB13-\\uFB17\\uFB1D-\\uFB28\\uFB2A-\\uFB36\\uFB38-\\uFB3C\\uFB3E\\uFB40\\uFB41\\uFB43\\uFB44\\uFB46-\\uFBB1\\uFBD3-\\uFD3D\\uFD50-\\uFD8F\\uFD92-\\uFDC7\\uFDF0-\\uFDFB\\uFE00-\\uFE0F\\uFE20-\\uFE2D\\uFE33\\uFE34\\uFE4D-\\uFE4F\\uFE70-\\uFE74\\uFE76-\\uFEFC\\uFF10-\\uFF19\\uFF21-\\uFF3A\\uFF3F\\uFF41-\\uFF5A\\uFF66-\\uFFBE\\uFFC2-\\uFFC7\\uFFCA-\\uFFCF\\uFFD2-\\uFFD7\\uFFDA-\\uFFDC]");function Om(e,t){if(!e)throw new Error("ASSERT: "+t)}function To(e){return e>=48&&e<=57}function Qv(e){return"0123456789abcdefABCDEF".indexOf(e)>=0}function o2(e){return"01234567".indexOf(e)>=0}function gge(e){return e===32||e===9||e===11||e===12||e===160||e>=5760&&[5760,6158,8192,8193,8194,8195,8196,8197,8198,8199,8200,8201,8202,8239,8287,12288,65279].indexOf(e)>=0}function V2(e){return e===10||e===13||e===8232||e===8233}function X0(e){return e===36||e===95||e>=65&&e<=90||e>=97&&e<=122||e===92||e>=128&&uge.test(String.fromCharCode(e))}function Ry(e){return e===36||e===95||e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57||e===92||e>=128&&hge.test(String.fromCharCode(e))}const _ge={if:1,in:1,do:1,var:1,for:1,new:1,try:1,let:1,this:1,else:1,case:1,void:1,with:1,enum:1,while:1,break:1,catch:1,throw:1,const:1,yield:1,class:1,super:1,return:1,typeof:1,delete:1,switch:1,export:1,import:1,public:1,static:1,default:1,finally:1,extends:1,package:1,private:1,function:1,continue:1,debugger:1,interface:1,protected:1,instanceof:1,implements:1};function O$(){for(;le1114111||e!=="}")&&Mt({},Vn,ii),t<=65535?String.fromCharCode(t):(n=(t-65536>>10)+55296,i=(t-65536&1023)+56320,String.fromCharCode(n,i))}function M$(){var e,t;for(e=Ie.charCodeAt(le++),t=String.fromCharCode(e),e===92&&(Ie.charCodeAt(le)!==117&&Mt({},Vn,ii),++le,e=L8("u"),(!e||e==="\\"||!X0(e.charCodeAt(0)))&&Mt({},Vn,ii),t=e);le>>=")return le+=4,{type:Zi,value:c,start:e,end:le};if(o=c.substr(0,3),o===">>>"||o==="<<="||o===">>=")return le+=3,{type:Zi,value:o,start:e,end:le};if(s=o.substr(0,2),i===s[1]&&"+-<>&|".indexOf(i)>=0||s==="=>")return le+=2,{type:Zi,value:s,start:e,end:le};if(s==="//"&&Mt({},Vn,ii),"<>=!+-*%&|^/".indexOf(i)>=0)return++le,{type:Zi,value:i,start:e,end:le};Mt({},Vn,ii)}function wge(e){let t="";for(;le=0&&le=0&&(n=n.replace(/\\u\{([0-9a-fA-F]+)\}/g,(i,s)=>{if(parseInt(s,16)<=1114111)return"x";Mt({},w8)}).replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"x"));try{new RegExp(n)}catch{Mt({},w8)}try{return new RegExp(e,t)}catch{return null}}function vge(){var e,t,n,i,s;for(e=Ie[le],Om(e==="/","Regular expression literal must start with a slash"),t=Ie[le++],n=!1,i=!1;le=0&&Mt({},w8,n),{value:n,literal:t}}function Sge(){var e,t,n,i;return Gt=null,O$(),e=le,t=vge(),n=Ege(),i=Tge(t.value,n.value),{literal:t.literal+n.literal,value:i,regex:{pattern:t.value,flags:n.value},start:e,end:le}}function xge(e){return e.type===$d||e.type===Sc||e.type===Fm||e.type===Im}function A$(){if(O$(),le>=Li)return{type:W0,start:le,end:le};const e=Ie.charCodeAt(le);return X0(e)?mge():e===40||e===41||e===59?Yw():e===39||e===34?bge():e===46?To(Ie.charCodeAt(le+1))?lO():Yw():To(e)?lO():Yw()}function is(){const e=Gt;return le=e.end,Gt=A$(),le=e.end,e}function N$(){const e=le;Gt=A$(),le=e}function kge(e){const t=new Xr(K3e);return t.elements=e,t}function cO(e,t,n){const i=new Xr(e==="||"||e==="&&"?tge:Z3e);return i.operator=e,i.left=t,i.right=n,i}function Bge(e,t){const n=new Xr(J3e);return n.callee=e,n.arguments=t,n}function Fge(e,t,n){const i=new Xr(Q3e);return i.test=e,i.consequent=t,i.alternate=n,i}function eE(e){const t=new Xr(F$);return t.name=e,t}function V1(e){const t=new Xr(ege);return t.value=e.value,t.raw=Ie.slice(e.start,e.end),e.regex&&(t.raw==="//"&&(t.raw="/(?:)/"),t.regex=e.regex),t}function dO(e,t,n){const i=new Xr(nge);return i.computed=e==="[",i.object=t,i.property=n,i.computed||(n.member=!0),i}function Ige(e){const t=new Xr(ige);return t.properties=e,t}function fO(e,t,n){const i=new Xr(sge);return i.key=t,i.value=n,i.kind=e,i}function Oge(e,t){const n=new Xr(rge);return n.operator=e,n.argument=t,n.prefix=!0,n}function Mt(e,t){var n,i=Array.prototype.slice.call(arguments,2),s=t.replace(/%(\d)/g,(o,c)=>(Om(c":case"<=":case">=":case"instanceof":case"in":t=7;break;case"<<":case">>":case">>>":t=8;break;case"+":case"-":t=9;break;case"*":case"/":case"%":t=11;break}return t}function $ge(){var e,t,n,i,s,o,c,d,f,u;if(e=Gt,f=ep(),i=Gt,s=gO(i),s===0)return f;for(i.prec=s,is(),t=[e,Gt],c=ep(),o=[f,i,c];(s=gO(Gt))>0;){for(;o.length>2&&s<=o[o.length-2].prec;)c=o.pop(),d=o.pop().value,f=o.pop(),t.pop(),n=cO(d,f,c),o.push(n);i=is(),i.prec=s,o.push(i),t.push(Gt),n=ep(),o.push(n)}for(u=o.length-1,n=o[u],t.pop();u>1;)t.pop(),n=cO(o[u-1].value,o[u-2],n),u-=2;return n}function qd(){var e,t,n;return e=$ge(),an("?")&&(is(),t=qd(),bi(":"),n=qd(),e=Fge(e,t,n)),e}function tE(){const e=qd();if(an(","))throw new Error(q2);return e}function nE(e){Ie=e,le=0,Li=Ie.length,Gt=null,N$();const t=tE();if(Gt.type!==W0)throw new Error("Unexpect token after expression.");return t}var C$={NaN:"NaN",E:"Math.E",LN2:"Math.LN2",LN10:"Math.LN10",LOG2E:"Math.LOG2E",LOG10E:"Math.LOG10E",PI:"Math.PI",SQRT1_2:"Math.SQRT1_2",SQRT2:"Math.SQRT2",MIN_VALUE:"Number.MIN_VALUE",MAX_VALUE:"Number.MAX_VALUE"};function R$(e){function t(c,d,f,u){let a=e(d[0]);return f&&(a=f+"("+a+")",f.lastIndexOf("new ",0)===0&&(a="("+a+")")),a+"."+c+(u<0?"":u===0?"()":"("+d.slice(1).map(e).join(",")+")")}function n(c,d,f){return u=>t(c,u,d,f)}const i="new Date",s="String",o="RegExp";return{isNaN:"Number.isNaN",isFinite:"Number.isFinite",abs:"Math.abs",acos:"Math.acos",asin:"Math.asin",atan:"Math.atan",atan2:"Math.atan2",ceil:"Math.ceil",cos:"Math.cos",exp:"Math.exp",floor:"Math.floor",log:"Math.log",max:"Math.max",min:"Math.min",pow:"Math.pow",random:"Math.random",round:"Math.round",sin:"Math.sin",sqrt:"Math.sqrt",tan:"Math.tan",clamp:function(c){c.length<3&&ce("Missing arguments to clamp function."),c.length>3&&ce("Too many arguments to clamp function.");const d=c.map(e);return"Math.max("+d[1]+", Math.min("+d[2]+","+d[0]+"))"},now:"Date.now",utc:"Date.UTC",datetime:i,date:n("getDate",i,0),day:n("getDay",i,0),year:n("getFullYear",i,0),month:n("getMonth",i,0),hours:n("getHours",i,0),minutes:n("getMinutes",i,0),seconds:n("getSeconds",i,0),milliseconds:n("getMilliseconds",i,0),time:n("getTime",i,0),timezoneoffset:n("getTimezoneOffset",i,0),utcdate:n("getUTCDate",i,0),utcday:n("getUTCDay",i,0),utcyear:n("getUTCFullYear",i,0),utcmonth:n("getUTCMonth",i,0),utchours:n("getUTCHours",i,0),utcminutes:n("getUTCMinutes",i,0),utcseconds:n("getUTCSeconds",i,0),utcmilliseconds:n("getUTCMilliseconds",i,0),length:n("length",null,-1),parseFloat:"parseFloat",parseInt:"parseInt",upper:n("toUpperCase",s,0),lower:n("toLowerCase",s,0),substring:n("substring",s),split:n("split",s),trim:n("trim",s,0),regexp:o,test:n("test",o),if:function(c){c.length<3&&ce("Missing arguments to if function."),c.length>3&&ce("Too many arguments to if function.");const d=c.map(e);return"("+d[0]+"?"+d[1]+":"+d[2]+")"}}}function qge(e){const t=e&&e.length-1;return t&&(e[0]==='"'&&e[t]==='"'||e[0]==="'"&&e[t]==="'")?e.slice(1,-1):e}function P$(e){e=e||{};const t=e.allowed?zr(e.allowed):{},n=e.forbidden?zr(e.forbidden):{},i=e.constants||C$,s=(e.functions||R$)(m),o=e.globalvar,c=e.fieldvar,d=ft(o)?o:l=>`${o}["${l}"]`;let f={},u={},a=0;function m(l){if(xe(l))return l;const b=y[l.type];return b==null&&ce("Unsupported type: "+l.type),b(l)}const y={Literal:l=>l.raw,Identifier:l=>{const b=l.name;return a>0?b:De(n,b)?ce("Illegal identifier: "+b):De(i,b)?i[b]:De(t,b)?b:(f[b]=1,d(b))},MemberExpression:l=>{const b=!l.computed,L=m(l.object);b&&(a+=1);const E=m(l.property);return L===c&&(u[qge(E)]=1),b&&(a-=1),L+(b?"."+E:"["+E+"]")},CallExpression:l=>{l.callee.type!=="Identifier"&&ce("Illegal callee type: "+l.callee.type);const b=l.callee.name,L=l.arguments,E=De(s,b)&&s[b];return E||ce("Unrecognized function: "+b),ft(E)?E(L):E+"("+L.map(m).join(",")+")"},ArrayExpression:l=>"["+l.elements.map(m).join(",")+"]",BinaryExpression:l=>"("+m(l.left)+" "+l.operator+" "+m(l.right)+")",UnaryExpression:l=>"("+l.operator+m(l.argument)+")",ConditionalExpression:l=>"("+m(l.test)+"?"+m(l.consequent)+":"+m(l.alternate)+")",LogicalExpression:l=>"("+m(l.left)+l.operator+m(l.right)+")",ObjectExpression:l=>"{"+l.properties.map(m).join(",")+"}",Property:l=>{a+=1;const b=m(l.key);return a-=1,b+":"+m(l.value)}};function p(l){const b={code:m(l),globals:Object.keys(f),fields:Object.keys(u)};return f={},u={},b}return p.functions=s,p.constants=i,p}function Kw(e,t){return e==null||t==null?NaN:et?1:e>=t?0:NaN}function Vge(e,t){return e==null||t==null?NaN:te?1:t>=e?0:NaN}function Gge(e){let t,n,i;e.length!==2?(t=Kw,n=(d,f)=>Kw(e(d),f),i=(d,f)=>e(d)-f):(t=e===Kw||e===Vge?e:Wge,n=e,i=e);function s(d,f,u=0,a=d.length){if(u>>1;n(d[m],f)<0?u=m+1:a=m}while(u>>1;n(d[m],f)<=0?u=m+1:a=m}while(uu&&i(d[m-1],f)>-i(d[m],f)?m-1:m}return{left:s,center:c,right:o}}function Wge(){return 0}function Yge(e,...t){e=new xp(e),t=t.map(Xge);e:for(const n of e)for(const i of t)if(!i.has(n)){e.delete(n);continue e}return e}function Xge(e){return e instanceof xp?e:new xp(e)}function Kge(...e){const t=new xp;for(const n of e)for(const i of n)t.add(i);return t}const iE="intersect",_O="union",Zge="vlMulti",Jge="vlPoint",pO="or",Qge="and",da="_vgsid_",G2=hs(da),e_e="E",t_e="R",n_e="R-E",i_e="R-LE",s_e="R-RE",Py="index:unit";function yO(e,t){for(var n=t.fields,i=t.values,s=n.length,o=0,c,d;odt(t.fields?{values:t.fields.map(i=>(i.getter||(i.getter=hs(i.field)))(n.datum))}:{[da]:G2(n.datum)},t))}function d_e(e,t,n,i){for(var s=this.context.data[e],o=s?s.values.value:[],c={},d={},f={},u,a,m,y,p,l,b,L,E,S,x=o.length,F=0,k,M;F(O[a[P].field]=C,O),{})))}else p=da,l=G2(u),b=c[p]||(c[p]={}),L=b[y]||(b[y]=[]),L.push(l),n&&(L=d[y]||(d[y]=[]),L.push({[da]:l}));if(t=t||_O,c[da]?c[da]=Zw[`${da}_${t}`](...Object.values(c[da])):Object.keys(c).forEach(O=>{c[O]=Object.keys(c[O]).map(C=>c[O][C]).reduce((C,P)=>C===void 0?P:Zw[`${f[O]}_${t}`](C,P))}),o=Object.keys(d),n&&o.length){const O=i?Jge:Zge;c[O]=t===_O?{[pO]:o.reduce((C,P)=>(C.push(...d[P]),C),[])}:{[Qge]:o.map(C=>({[pO]:d[C]}))}}return c}var Zw={[`${da}_union`]:Kge,[`${da}_intersect`]:Yge,E_union:function(e,t){if(!e.length)return t;for(var n=0,i=t.length;nt.indexOf(n)>=0):t},R_union:function(e,t){var n=_i(t[0]),i=_i(t[1]);return n>i&&(n=t[1],i=t[0]),e.length?(e[0]>n&&(e[0]=n),e[1]i&&(n=t[1],i=t[0]),e.length?ii&&(e[1]=i),e):[n,i]}};const f_e=":",u_e="@";function sE(e,t,n,i){t[0].type!==zd&&ce("First argument to selection functions must be a string literal.");const s=t[0].value,o=t.length>=2&&kt(t).value,c="unit",d=u_e+c,f=f_e+s;o===iE&&!De(i,d)&&(i[d]=n.getData(s).indataRef(n,c)),De(i,f)||(i[f]=n.getData(s).tuplesRef())}function j$(e){const t=this.context.data[e];return t?t.values.value:[]}function h_e(e,t,n){const i=this.context.data[e]["index:"+t],s=i?i.value.get(n):void 0;return s&&s.count}function g_e(e,t){const n=this.context.dataflow,i=this.context.data[e],s=i.input;return n.pulse(s,n.changeset().remove(sr).insert(t)),1}function __e(e,t,n){if(e){const i=this.context.dataflow,s=e.mark.source;i.pulse(s,i.changeset().encode(e,t))}return n!==void 0?n:e}const K0=e=>function(t,n){return this.context.dataflow.locale()[e](n)(t)},p_e=K0("format"),U$=K0("timeFormat"),y_e=K0("utcFormat"),m_e=K0("timeParse"),w_e=K0("utcParse"),s_=new Date(2e3,0,1);function Am(e,t,n){return!Number.isInteger(e)||!Number.isInteger(t)?"":(s_.setYear(2e3),s_.setMonth(e),s_.setDate(t),U$.call(this,s_,n))}function L_e(e){return Am.call(this,e,1,"%B")}function b_e(e){return Am.call(this,e,1,"%b")}function T_e(e){return Am.call(this,0,2+e,"%A")}function v_e(e){return Am.call(this,0,2+e,"%a")}const E_e=":",S_e="@",b8="%",H$="$";function rE(e,t,n,i){t[0].type!==zd&&ce("First argument to data functions must be a string literal.");const s=t[0].value,o=E_e+s;if(!De(o,i))try{i[o]=n.getData(s).tuplesRef()}catch{}}function x_e(e,t,n,i){t[0].type!==zd&&ce("First argument to indata must be a string literal."),t[1].type!==zd&&ce("Second argument to indata must be a string literal.");const s=t[0].value,o=t[1].value,c=S_e+o;De(c,i)||(i[c]=n.getData(s).indataRef(n,o))}function rs(e,t,n,i){if(t[0].type===zd)mO(n,i,t[0].value);else for(e in n.scales)mO(n,i,e)}function mO(e,t,n){const i=b8+n;if(!De(t,i))try{t[i]=e.scaleRef(n)}catch{}}function nl(e,t){if(ft(e))return e;if(xe(e)){const n=t.scales[e];return n&&Yfe(n.value)?n.value:void 0}}function k_e(e,t,n){t.__bandwidth=s=>s&&s.bandwidth?s.bandwidth():0,n._bandwidth=rs,n._range=rs,n._scale=rs;const i=s=>"_["+(s.type===zd?Te(b8+s.value):Te(b8)+"+"+e(s))+"]";return{_bandwidth:s=>`this.__bandwidth(${i(s[0])})`,_range:s=>`${i(s[0])}.range()`,_scale:s=>`${i(s[0])}(${e(s[1])})`}}function aE(e,t){return function(n,i,s){if(n){const o=nl(n,(s||this).context);return o&&o.path[e](i)}else return t(i)}}const B_e=aE("area",use),F_e=aE("bounds",pse),I_e=aE("centroid",Tse);function O_e(e){const t=this.context.group;let n=!1;if(t)for(;e;){if(e===t){n=!0;break}e=e.mark.group}return n}function oE(e,t,n){try{e[t].apply(e,["EXPRESSION"].concat([].slice.call(n)))}catch(i){e.warn(i)}return n[n.length-1]}function M_e(){return oE(this.context.dataflow,"warn",arguments)}function A_e(){return oE(this.context.dataflow,"info",arguments)}function N_e(){return oE(this.context.dataflow,"debug",arguments)}function Jw(e){const t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}function T8(e){const t=ec(e),n=Jw(t.r),i=Jw(t.g),s=Jw(t.b);return .2126*n+.7152*i+.0722*s}function C_e(e,t){const n=T8(e),i=T8(t),s=Math.max(n,i),o=Math.min(n,i);return(s+.05)/(o+.05)}function R_e(){const e=[].slice.call(arguments);return e.unshift({}),dt(...e)}function z$(e,t){return e===t||e!==e&&t!==t?!0:ue(e)?ue(t)&&e.length===t.length?P_e(e,t):!1:ke(e)&&ke(t)?$$(e,t):!1}function P_e(e,t){for(let n=0,i=e.length;n$$(e,t)}function D_e(e,t,n,i,s,o){const c=this.context.dataflow,d=this.context.data[e],f=d.input,u=c.stamp();let a=d.changes,m,y;if(c._trigger===!1||!(f.value.length||t||i))return 0;if((!a||a.stamp{d.modified=!0,c.pulse(f,a).run()},!0,1)),n&&(m=n===!0?sr:ue(n)||lm(n)?n:wO(n),a.remove(m)),t&&a.insert(t),i&&(m=wO(i),f.value.some(m)?a.remove(m):a.insert(i)),s)for(y in o)a.modify(s,y,o[y]);return 1}function j_e(e){const t=e.touches,n=t[0].clientX-t[1].clientX,i=t[0].clientY-t[1].clientY;return Math.sqrt(n*n+i*i)}function U_e(e){const t=e.touches;return Math.atan2(t[0].clientY-t[1].clientY,t[0].clientX-t[1].clientX)}const LO={};function H_e(e,t){const n=LO[t]||(LO[t]=hs(t));return ue(e)?e.map(n):n(e)}function lE(e){return ue(e)||ArrayBuffer.isView(e)?e:null}function cE(e){return lE(e)||(xe(e)?e:null)}function z_e(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i1?t-1:0),i=1;i1?t-1:0),i=1;i1?t-1:0),i=1;io.stop(u(a),e(a))),o}function npe(e,t,n){const i=nl(e,(n||this).context);return function(s){return i?i.path.context(s)(t):""}}function ipe(e){let t=null;return function(n){return n?j2(n,t=t||eh(e)):e}}const q$=e=>e.data;function V$(e,t){const n=j$.call(t,e);return n.root&&n.root.lookup||{}}function spe(e,t,n){const i=V$(e,this),s=i[t],o=i[n];return s&&o?s.path(o).map(q$):void 0}function rpe(e,t){const n=V$(e,this)[t];return n?n.ancestors().map(q$):void 0}const G$=()=>typeof window<"u"&&window||null;function ape(){const e=G$();return e?e.screen:{}}function ope(){const e=G$();return e?[e.innerWidth,e.innerHeight]:[void 0,void 0]}function lpe(){const e=this.context.dataflow,t=e.container&&e.container();return t?[t.clientWidth,t.clientHeight]:[void 0,void 0]}function W$(e,t,n){if(!e)return[];const[i,s]=e,o=new En().set(i[0],i[1],s[0],s[1]),c=n||this.context.dataflow.scenegraph().root;return Oz(c,o,cpe(t))}function cpe(e){let t=null;if(e){const n=Se(e.marktype),i=Se(e.markname);t=s=>(!n.length||n.some(o=>s.marktype===o))&&(!i.length||i.some(o=>s.name===o))}return t}function dpe(e,t,n){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:5;e=Se(e);const s=e[e.length-1];return s===void 0||Math.sqrt((s[0]-t)**2+(s[1]-n)**2)>i?[...e,[t,n]]:e}function fpe(e){return Se(e).reduce((t,n,i)=>{let[s,o]=n;return t+=i==0?`M ${s},${o} `:i===e.length-1?" Z":`L ${s},${o} `},"")}function upe(e,t,n){const{x:i,y:s,mark:o}=n,c=new En().set(Number.MAX_SAFE_INTEGER,Number.MAX_SAFE_INTEGER,Number.MIN_SAFE_INTEGER,Number.MIN_SAFE_INTEGER);for(const[f,u]of t)fc.x2&&(c.x2=f),uc.y2&&(c.y2=u);return c.translate(i,s),W$([[c.x1,c.y1],[c.x2,c.y2]],e,o).filter(f=>hpe(f.x,f.y,t))}function hpe(e,t,n){let i=0;for(let s=0,o=n.length-1;st!=d>t&&e<(c-f)*(t-u)/(d-u)+f&&i++}return i&1}const W2={random(){return ir()},cumulativeNormal:Z4,cumulativeLogNormal:xb,cumulativeUniform:Ib,densityNormal:bb,densityLogNormal:Sb,densityUniform:Fb,quantileNormal:J4,quantileLogNormal:kb,quantileUniform:Ob,sampleNormal:K4,sampleLogNormal:Eb,sampleUniform:Bb,isArray:ue,isBoolean:Ec,isDate:Hl,isDefined(e){return e!==void 0},isNumber:Yt,isObject:ke,isRegExp:Jj,isString:xe,isTuple:lm,isValid(e){return e!=null&&e===e},toBoolean:Gb,toDate(e){return Wb(e)},toNumber:_i,toString:Yb,indexof:$_e,join:z_e,lastindexof:q_e,replace:G_e,reverse:W_e,slice:V_e,flush:Kj,lerp:Qj,merge:R_e,pad:nU,peek:kt,pluck:H_e,span:M0,inrange:au,truncate:iU,rgb:ec,lab:Mp,hcl:Ap,hsl:Ip,luminance:T8,contrast:C_e,sequence:Os,format:p_e,utcFormat:y_e,utcParse:w_e,utcOffset:yU,utcSequence:LU,timeFormat:U$,timeParse:m_e,timeOffset:pU,timeSequence:wU,timeUnitSpecifier:rU,monthFormat:L_e,monthAbbrevFormat:b_e,dayFormat:T_e,dayAbbrevFormat:v_e,quarter:Gj,utcquarter:Wj,week:oU,utcweek:dU,dayofyear:aU,utcdayofyear:cU,warn:M_e,info:A_e,debug:N_e,extent(e){return Ua(e)},inScope:O_e,intersect:W$,clampRange:Yj,pinchDistance:j_e,pinchAngle:U_e,screen:ape,containerSize:lpe,windowSize:ope,bandspace:Y_e,setdata:g_e,pathShape:ipe,panLinear:zj,panLog:$j,panPow:qj,panSymlog:Vj,zoomLinear:Ub,zoomLog:Hb,zoomPow:my,zoomSymlog:zb,encode:__e,modify:D_e,lassoAppend:dpe,lassoPath:fpe,intersectLasso:upe},gpe=["view","item","group","xy","x","y"],_pe="event.vega.",Y$="this.",dE={},X$={forbidden:["_"],allowed:["datum","event","item"],fieldvar:"datum",globalvar:e=>`_[${Te(H$+e)}]`,functions:ppe,constants:C$,visitors:dE},v8=P$(X$);function ppe(e){const t=R$(e);gpe.forEach(n=>t[n]=_pe+n);for(const n in W2)t[n]=Y$+n;return dt(t,k_e(e,W2,dE)),t}function xn(e,t,n){return arguments.length===1?W2[e]:(W2[e]=t,n&&(dE[e]=n),v8&&(v8.functions[e]=Y$+e),this)}xn("bandwidth",X_e,rs);xn("copy",K_e,rs);xn("domain",Z_e,rs);xn("range",Q_e,rs);xn("invert",J_e,rs);xn("scale",epe,rs);xn("gradient",tpe,rs);xn("geoArea",B_e,rs);xn("geoBounds",F_e,rs);xn("geoCentroid",I_e,rs);xn("geoShape",npe,rs);xn("indata",h_e,x_e);xn("data",j$,rE);xn("treePath",spe,rE);xn("treeAncestors",rpe,rE);xn("vlSelectionTest",r_e,sE);xn("vlSelectionIdTest",l_e,sE);xn("vlSelectionResolve",d_e,sE);xn("vlSelectionTuples",c_e);function za(e,t){const n={};let i;try{e=xe(e)?e:Te(e)+"",i=nE(e)}catch{ce("Expression parse error: "+e)}i.visit(o=>{if(o.type!==B$)return;const c=o.callee.name,d=X$.visitors[c];d&&d(c,o.arguments,t,n)});const s=v8(i);return s.globals.forEach(o=>{const c=H$+o;!De(n,c)&&t.getSignal(o)&&(n[c]=t.signalRef(o))}),{$expr:dt({code:s.code},t.options.ast?{ast:i}:null),$fields:s.fields,$params:n}}function ype(e){const t=this,n=e.operators||[];return e.background&&(t.background=e.background),e.eventConfig&&(t.eventConfig=e.eventConfig),e.locale&&(t.locale=e.locale),n.forEach(i=>t.parseOperator(i)),n.forEach(i=>t.parseOperatorParameters(i)),(e.streams||[]).forEach(i=>t.parseStream(i)),(e.updates||[]).forEach(i=>t.parseUpdate(i)),t.resolve()}const mpe=zr(["rule"]),bO=zr(["group","image","rect"]);function wpe(e,t){let n="";return mpe[t]||(e.x2&&(e.x?(bO[t]&&(n+="if(o.x>o.x2)$=o.x,o.x=o.x2,o.x2=$;"),n+="o.width=o.x2-o.x;"):n+="o.x=o.x2-(o.width||0);"),e.xc&&(n+="o.x=o.xc-(o.width||0)/2;"),e.y2&&(e.y?(bO[t]&&(n+="if(o.y>o.y2)$=o.y,o.y=o.y2,o.y2=$;"),n+="o.height=o.y2-o.y;"):n+="o.y=o.y2-(o.height||0);"),e.yc&&(n+="o.y=o.yc-(o.height||0)/2;")),n}function fE(e){return(e+"").toLowerCase()}function Lpe(e){return fE(e)==="operator"}function bpe(e){return fE(e)==="collect"}function c1(e,t,n){n.endsWith(";")||(n="return("+n+");");const i=Function(...t.concat(n));return e&&e.functions?i.bind(e.functions):i}function Tpe(e,t,n,i){return`((u = ${e}) < (v = ${t}) || u == null) && v != null ? ${n} : (u > v || v == null) && u != null ? ${i} : ((v = v instanceof Date ? +v : v), (u = u instanceof Date ? +u : u)) !== u && v === v ? ${n} : v !== v && u === u ? ${i} : `}var vpe={operator:(e,t)=>c1(e,["_"],t.code),parameter:(e,t)=>c1(e,["datum","_"],t.code),event:(e,t)=>c1(e,["event"],t.code),handler:(e,t)=>{const n=`var datum=event.item&&event.item.datum;return ${t.code};`;return c1(e,["_","event"],n)},encode:(e,t)=>{const{marktype:n,channels:i}=t;let s="var o=item,datum=o.datum,m=0,$;";for(const o in i){const c="o["+Te(o)+"]";s+=`$=${i[o].code};if(${c}!==$)${c}=$,m=1;`}return s+=wpe(i,n),s+="return m;",c1(e,["item","_"],s)},codegen:{get(e){const t=`[${e.map(Te).join("][")}]`,n=Function("_",`return _${t};`);return n.path=t,n},comparator(e,t){let n;const i=(o,c)=>{const d=t[c];let f,u;return o.path?(f=`a${o.path}`,u=`b${o.path}`):((n=n||{})["f"+c]=o,f=`this.f${c}(a)`,u=`this.f${c}(b)`),Tpe(f,u,-d,d)},s=Function("a","b","var u, v; return "+e.map(i).join("")+"0;");return n?s.bind(n):s}}};function Epe(e){const t=this;Lpe(e.type)||!e.type?t.operator(e,e.update?t.operatorExpression(e.update):null):t.transform(e,e.type)}function Spe(e){const t=this;if(e.params){const n=t.get(e.id);n||ce("Invalid operator id: "+e.id),t.dataflow.connect(n,n.parameters(t.parseParameters(e.params),e.react,e.initonly))}}function xpe(e,t){t=t||{};const n=this;for(const i in e){const s=e[i];t[i]=ue(s)?s.map(o=>TO(o,n,t)):TO(s,n,t)}return t}function TO(e,t,n){if(!e||!ke(e))return e;for(let i=0,s=vO.length,o;is&&s.$tupleid?Re:s);return t.fn[n]||(t.fn[n]=$b(i,e.$order,t.expr.codegen))}function Mpe(e,t){const n=e.$encode,i={};for(const s in n){const o=n[s];i[s]=Ls(t.encodeExpression(o.$expr),o.$fields),i[s].output=o.$output}return i}function Ape(e,t){return t}function Npe(e,t){const n=e.$subflow;return function(i,s,o){const c=t.fork().parse(n),d=c.get(n.operators[0].id),f=c.signals.parent;return f&&f.set(o),d.detachSubflow=()=>t.detach(c),d}}function Cpe(){return Re}function Rpe(e){var t=this,n=e.filter!=null?t.eventExpression(e.filter):void 0,i=e.stream!=null?t.get(e.stream):void 0,s;e.source?i=t.events(e.source,e.type,n):e.merge&&(s=e.merge.map(o=>t.get(o)),i=s[0].merge.apply(s[0],s.slice(1))),e.between&&(s=e.between.map(o=>t.get(o)),i=i.between(s[0],s[1])),e.filter&&(i=i.filter(n)),e.throttle!=null&&(i=i.throttle(+e.throttle)),e.debounce!=null&&(i=i.debounce(+e.debounce)),i==null&&ce("Invalid stream definition: "+JSON.stringify(e)),e.consume&&i.consume(!0),t.stream(e,i)}function Ppe(e){var t=this,n=ke(n=e.source)?n.$ref:n,i=t.get(n),s=null,o=e.update,c=void 0;i||ce("Source not defined: "+e.source),s=e.target&&e.target.$expr?t.eventExpression(e.target.$expr):t.get(e.target),o&&o.$expr&&(o.$params&&(c=t.parseParameters(o.$params)),o=t.handlerExpression(o.$expr)),t.update(e,i,s,o,c)}const Dpe={skip:!0};function jpe(e){var t=this,n={};if(e.signals){var i=n.signals={};Object.keys(t.signals).forEach(o=>{const c=t.signals[o];e.signals(o,c)&&(i[o]=c.value)})}if(e.data){var s=n.data={};Object.keys(t.data).forEach(o=>{const c=t.data[o];e.data(o,c)&&(s[o]=c.input.value)})}return t.subcontext&&e.recurse!==!1&&(n.subcontext=t.subcontext.map(o=>o.getState(e))),n}function Upe(e){var t=this,n=t.dataflow,i=e.data,s=e.signals;Object.keys(s||{}).forEach(o=>{n.update(t.signals[o],s[o],Dpe)}),Object.keys(i||{}).forEach(o=>{n.pulse(t.data[o].input,n.changeset().remove(sr).insert(i[o]))}),(e.subcontext||[]).forEach((o,c)=>{const d=t.subcontext[c];d&&d.setState(o)})}function K$(e,t,n,i){return new Z$(e,t,n,i)}function Z$(e,t,n,i){this.dataflow=e,this.transforms=t,this.events=e.events.bind(e),this.expr=i||vpe,this.signals={},this.scales={},this.nodes={},this.data={},this.fn={},n&&(this.functions=Object.create(n),this.functions.context=this)}function EO(e){this.dataflow=e.dataflow,this.transforms=e.transforms,this.events=e.events,this.expr=e.expr,this.signals=Object.create(e.signals),this.scales=Object.create(e.scales),this.nodes=Object.create(e.nodes),this.data=Object.create(e.data),this.fn=Object.create(e.fn),e.functions&&(this.functions=Object.create(e.functions),this.functions.context=this)}Z$.prototype=EO.prototype={fork(){const e=new EO(this);return(this.subcontext||(this.subcontext=[])).push(e),e},detach(e){this.subcontext=this.subcontext.filter(n=>n!==e);const t=Object.keys(e.nodes);for(const n of t)e.nodes[n]._targets=null;for(const n of t)e.nodes[n].detach();e.nodes=null},get(e){return this.nodes[e]},set(e,t){return this.nodes[e]=t},add(e,t){const n=this,i=n.dataflow,s=e.value;if(n.set(e.id,t),bpe(e.type)&&s&&(s.$ingest?i.ingest(t,s.$ingest,s.$format):s.$request?i.preload(t,s.$request,s.$format):i.pulse(t,i.changeset().insert(s))),e.root&&(n.root=t),e.parent){let o=n.get(e.parent.$ref);o?(i.connect(o,[t]),t.targets().add(o)):(n.unresolved=n.unresolved||[]).push(()=>{o=n.get(e.parent.$ref),i.connect(o,[t]),t.targets().add(o)})}if(e.signal&&(n.signals[e.signal]=t),e.scale&&(n.scales[e.scale]=t),e.data)for(const o in e.data){const c=n.data[o]||(n.data[o]={});e.data[o].forEach(d=>c[d]=t)}},resolve(){return(this.unresolved||[]).forEach(e=>e()),delete this.unresolved,this},operator(e,t){this.add(e,this.dataflow.add(e.value,t))},transform(e,t){this.add(e,this.dataflow.add(this.transforms[fE(t)]))},stream(e,t){this.set(e.id,t)},update(e,t,n,i,s){this.dataflow.on(t,n,i,s,e.options)},operatorExpression(e){return this.expr.operator(this,e)},parameterExpression(e){return this.expr.parameter(this,e)},eventExpression(e){return this.expr.event(this,e)},handlerExpression(e){return this.expr.handler(this,e)},encodeExpression(e){return this.expr.encode(this,e)},parse:ype,parseOperator:Epe,parseOperatorParameters:Spe,parseParameters:xpe,parseStream:Rpe,parseUpdate:Ppe,getState:jpe,setState:Upe};function Hpe(e){const t=e.container();t&&(t.setAttribute("role","graphics-document"),t.setAttribute("aria-roleDescription","visualization"),J$(t,e.description()))}function J$(e,t){e&&(t==null?e.removeAttribute("aria-label"):e.setAttribute("aria-label",t))}function zpe(e){e.add(null,t=>(e._background=t.bg,e._resize=1,t.bg),{bg:e._signals.background})}const Qw="default";function $pe(e){const t=e._signals.cursor||(e._signals.cursor=e.add({user:Qw,item:null}));e.on(e.events("view","mousemove"),t,(n,i)=>{const s=t.value,o=s?xe(s)?s:s.user:Qw,c=i.item&&i.item.cursor||null;return s&&o===s.user&&c==s.item?s:{user:o,item:c}}),e.add(null,function(n){let i=n.cursor,s=this.value;return xe(i)||(s=i.item,i=i.user),E8(e,i&&i!==Qw?i:s||i),s},{cursor:t})}function E8(e,t){const n=e.globalCursor()?typeof document<"u"&&document.body:e.container();if(n)return t==null?n.style.removeProperty("cursor"):n.style.cursor=t}function Dy(e,t){var n=e._runtime.data;return De(n,t)||ce("Unrecognized data set: "+t),n[t]}function qpe(e,t){return arguments.length<2?Dy(this,e).values.value:Nm.call(this,e,gf().remove(sr).insert(t))}function Nm(e,t){UU(t)||ce("Second argument to changes must be a changeset.");const n=Dy(this,e);return n.modified=!0,this.pulse(n.input,t)}function Vpe(e,t){return Nm.call(this,e,gf().insert(t))}function Gpe(e,t){return Nm.call(this,e,gf().remove(t))}function Q$(e){var t=e.padding();return Math.max(0,e._viewWidth+t.left+t.right)}function eq(e){var t=e.padding();return Math.max(0,e._viewHeight+t.top+t.bottom)}function Cm(e){var t=e.padding(),n=e._origin;return[t.left+n[0],t.top+n[1]]}function Wpe(e){var t=Cm(e),n=Q$(e),i=eq(e);e._renderer.background(e.background()),e._renderer.resize(n,i,t),e._handler.origin(t),e._resizeListeners.forEach(s=>{try{s(n,i)}catch(o){e.error(o)}})}function Ype(e,t,n){var i=e._renderer,s=i&&i.canvas(),o,c,d;return s&&(d=Cm(e),c=t.changedTouches?t.changedTouches[0]:t,o=xm(c,s),o[0]-=d[0],o[1]-=d[1]),t.dataflow=e,t.item=n,t.vega=Xpe(e,n,o),t}function Xpe(e,t,n){const i=t?t.mark.marktype==="group"?t:t.mark.group:null;function s(c){var d=i,f;if(c){for(f=t;f;f=f.mark.group)if(f.mark.name===c){d=f;break}}return d&&d.mark&&d.mark.interactive?d:{}}function o(c){if(!c)return n;xe(c)&&(c=s(c));const d=n.slice();for(;c;)d[0]-=c.x||0,d[1]-=c.y||0,c=c.mark&&c.mark.group;return d}return{view:Si(e),item:Si(t||{}),group:s,xy:o,x:c=>o(c)[0],y:c=>o(c)[1]}}const SO="view",Kpe="timer",Zpe="window",Jpe={trap:!1};function Qpe(e){const t=dt({defaults:{}},e),n=(i,s)=>{s.forEach(o=>{ue(i[o])&&(i[o]=zr(i[o]))})};return n(t.defaults,["prevent","allow"]),n(t,["view","window","selector"]),t}function tq(e,t,n,i){e._eventListeners.push({type:n,sources:Se(t),handler:i})}function eye(e,t){var n=e._eventConfig.defaults,i=n.prevent,s=n.allow;return i===!1||s===!0?!1:i===!0||s===!1?!0:i?i[t]:s?!s[t]:e.preventDefault()}function r_(e,t,n){const i=e._eventConfig&&e._eventConfig[t];return i===!1||ke(i)&&!i[n]?(e.warn(`Blocked ${t} ${n} event listener.`),!1):!0}function tye(e,t,n){var i=this,s=new fm(n),o=function(u,a){i.runAsync(null,()=>{e===SO&&eye(i,t)&&u.preventDefault(),s.receive(Ype(i,u,a))})},c;if(e===Kpe)r_(i,"timer",t)&&i.timer(o,t);else if(e===SO)r_(i,"view",t)&&i.addEventListener(t,o,Jpe);else if(e===Zpe?r_(i,"window",t)&&typeof window<"u"&&(c=[window]):typeof document<"u"&&r_(i,"selector",t)&&(c=Array.from(document.querySelectorAll(e))),!c)i.warn("Can not resolve event source: "+e);else{for(var d=0,f=c.length;d=0;)t[i].stop();for(i=n.length;--i>=0;)for(o=n[i],s=o.sources.length;--s>=0;)o.sources[s].removeEventListener(o.type,o.handler);return e&&e.call(this,this._handler,null,null,null),this}function As(e,t,n){const i=document.createElement(e);for(const s in t)i.setAttribute(s,t[s]);return n!=null&&(i.textContent=n),i}const sye="vega-bind",rye="vega-bind-name",aye="vega-bind-radio";function oye(e,t,n){if(!t)return;const i=n.param;let s=n.state;return s||(s=n.state={elements:null,active:!1,set:null,update:c=>{c!=e.signal(i.signal)&&e.runAsync(null,()=>{s.source=!0,e.signal(i.signal,c)})}},i.debounce&&(s.update=qb(i.debounce,s.update))),(i.input==null&&i.element?lye:dye)(s,t,i,e),s.active||(e.on(e._signals[i.signal],null,()=>{s.source?s.source=!1:s.set(e.signal(i.signal))}),s.active=!0),s}function lye(e,t,n,i){const s=n.event||"input",o=()=>e.update(t.value);i.signal(n.signal,t.value),t.addEventListener(s,o),tq(i,t,s,o),e.set=c=>{t.value=c,t.dispatchEvent(cye(s))}}function cye(e){return typeof Event<"u"?new Event(e):{type:e}}function dye(e,t,n,i){const s=i.signal(n.signal),o=As("div",{class:sye}),c=n.input==="radio"?o:o.appendChild(As("label"));c.appendChild(As("span",{class:rye},n.name||n.signal)),t.appendChild(o);let d=fye;switch(n.input){case"checkbox":d=uye;break;case"select":d=hye;break;case"radio":d=gye;break;case"range":d=_ye;break}d(e,c,n,s)}function fye(e,t,n,i){const s=As("input");for(const o in n)o!=="signal"&&o!=="element"&&s.setAttribute(o==="input"?"type":o,n[o]);s.setAttribute("name",n.signal),s.value=i,t.appendChild(s),s.addEventListener("input",()=>e.update(s.value)),e.elements=[s],e.set=o=>s.value=o}function uye(e,t,n,i){const s={type:"checkbox",name:n.signal};i&&(s.checked=!0);const o=As("input",s);t.appendChild(o),o.addEventListener("change",()=>e.update(o.checked)),e.elements=[o],e.set=c=>o.checked=!!c||null}function hye(e,t,n,i){const s=As("select",{name:n.signal}),o=n.labels||[];n.options.forEach((c,d)=>{const f={value:c};jy(c,i)&&(f.selected=!0),s.appendChild(As("option",f,(o[d]||c)+""))}),t.appendChild(s),s.addEventListener("change",()=>{e.update(n.options[s.selectedIndex])}),e.elements=[s],e.set=c=>{for(let d=0,f=n.options.length;d{const f={type:"radio",name:n.signal,value:c};jy(c,i)&&(f.checked=!0);const u=As("input",f);u.addEventListener("change",()=>e.update(c));const a=As("label",{},(o[d]||c)+"");return a.prepend(u),s.appendChild(a),u}),e.set=c=>{const d=e.elements,f=d.length;for(let u=0;u{f.textContent=d.value,e.update(+d.value)};d.addEventListener("input",u),d.addEventListener("change",u),e.elements=[d],e.set=a=>{d.value=a,f.textContent=a}}function jy(e,t){return e===t||e+""==t+""}function nq(e,t,n,i,s,o){return t=t||new i(e.loader()),t.initialize(n,Q$(e),eq(e),Cm(e),s,o).background(e.background())}function uE(e,t){return t?function(){try{t.apply(this,arguments)}catch(n){e.error(n)}}:null}function pye(e,t,n,i){const s=new i(e.loader(),uE(e,e.tooltip())).scene(e.scenegraph().root).initialize(n,Cm(e),e);return t&&t.handlers().forEach(o=>{s.on(o.type,o.handler)}),s}function yye(e,t){const n=this,i=n._renderType,s=n._eventConfig.bind,o=km(i);e=n._el=e?e5(n,e,!0):null,Hpe(n),o||n.error("Unrecognized renderer type: "+i);const c=o.handler||G0,d=e?o.renderer:o.headless;return n._renderer=d?nq(n,n._renderer,e,d):null,n._handler=pye(n,n._handler,e,c),n._redraw=!0,e&&s!=="none"&&(t=t?n._elBind=e5(n,t,!0):e.appendChild(As("form",{class:"vega-bindings"})),n._bind.forEach(f=>{f.param.element&&s!=="container"&&(f.element=e5(n,f.param.element,!!f.param.input))}),n._bind.forEach(f=>{oye(n,f.element||t,f)})),n}function e5(e,t,n){if(typeof t=="string")if(typeof document<"u"){if(t=document.querySelector(t),!t)return e.error("Signal bind element not found: "+t),null}else return e.error("DOM document instance not found."),null;if(t&&n)try{t.textContent=""}catch(i){t=null,e.error(i)}return t}const d1=e=>+e||0,mye=e=>({top:e,bottom:e,left:e,right:e});function FO(e){return ke(e)?{top:d1(e.top),bottom:d1(e.bottom),left:d1(e.left),right:d1(e.right)}:mye(d1(e))}async function hE(e,t,n,i){const s=km(t),o=s&&s.headless;return o||ce("Unrecognized renderer type: "+t),await e.runAsync(),nq(e,null,null,o,n,i).renderAsync(e._scenegraph.root)}async function wye(e,t){e!==Al.Canvas&&e!==Al.SVG&&e!==Al.PNG&&ce("Unrecognized image type: "+e);const n=await hE(this,e,t);return e===Al.SVG?Lye(n.svg(),"image/svg+xml"):n.canvas().toDataURL("image/png")}function Lye(e,t){const n=new Blob([e],{type:t});return window.URL.createObjectURL(n)}async function bye(e,t){return(await hE(this,Al.Canvas,e,t)).canvas()}async function Tye(e){return(await hE(this,Al.SVG,e)).svg()}function vye(e,t,n){return K$(e,Ku,W2,n).parse(t)}function Eye(e){var t=this._runtime.scales;return De(t,e)||ce("Unrecognized scale or projection: "+e),t[e].value}var iq="width",sq="height",gE="padding",IO={skip:!0};function rq(e,t){var n=e.autosize(),i=e.padding();return t-(n&&n.contains===gE?i.left+i.right:0)}function aq(e,t){var n=e.autosize(),i=e.padding();return t-(n&&n.contains===gE?i.top+i.bottom:0)}function Sye(e){var t=e._signals,n=t[iq],i=t[sq],s=t[gE];function o(){e._autosize=e._resize=1}e._resizeWidth=e.add(null,d=>{e._width=d.size,e._viewWidth=rq(e,d.size),o()},{size:n}),e._resizeHeight=e.add(null,d=>{e._height=d.size,e._viewHeight=aq(e,d.size),o()},{size:i});const c=e.add(null,o,{pad:s});e._resizeWidth.rank=n.rank+1,e._resizeHeight.rank=i.rank+1,c.rank=s.rank+1}function xye(e,t,n,i,s,o){this.runAfter(c=>{let d=0;c._autosize=0,c.width()!==n&&(d=1,c.signal(iq,n,IO),c._resizeWidth.skip(!0)),c.height()!==i&&(d=1,c.signal(sq,i,IO),c._resizeHeight.skip(!0)),c._viewWidth!==e&&(c._resize=1,c._viewWidth=e),c._viewHeight!==t&&(c._resize=1,c._viewHeight=t),(c._origin[0]!==s[0]||c._origin[1]!==s[1])&&(c._resize=1,c._origin=s),d&&c.run("enter"),o&&c.runAfter(f=>f.resize())},!1,1)}function kye(e){return this._runtime.getState(e||{data:Bye,signals:Fye,recurse:!0})}function Bye(e,t){return t.modified&&ue(t.input.value)&&e.indexOf("_:vega:_")}function Fye(e,t){return!(e==="parent"||t instanceof Ku.proxy)}function Iye(e){return this.runAsync(null,t=>{t._trigger=!1,t._runtime.setState(e)},t=>{t._trigger=!0}),this}function Oye(e,t){function n(i){e({timestamp:Date.now(),elapsed:i})}this._timers.push(zte(n,t))}function Mye(e,t,n,i){const s=e.element();s&&s.setAttribute("title",Aye(i))}function Aye(e){return e==null?"":ue(e)?oq(e):ke(e)&&!Hl(e)?Nye(e):e+""}function Nye(e){return Object.keys(e).map(t=>{const n=e[t];return t+": "+(ue(n)?oq(n):lq(n))}).join(` `)}function oq(e){return"["+e.map(lq).join(", ")+"]"}function lq(e){return ue(e)?"[…]":ke(e)&&!Hl(e)?"{…}":e}function cq(e,t){const n=this;if(t=t||{},wu.call(n),t.loader&&n.loader(t.loader),t.logger&&n.logger(t.logger),t.logLevel!=null&&n.logLevel(t.logLevel),t.locale||e.locale){const o=dt({},e.locale,t.locale);n.locale(IU(o.number,o.time))}n._el=null,n._elBind=null,n._renderType=t.renderer||Al.Canvas,n._scenegraph=new av;const i=n._scenegraph.root;n._renderer=null,n._tooltip=t.tooltip||Mye,n._redraw=!0,n._handler=new G0().scene(i),n._globalCursor=!1,n._preventDefault=!1,n._timers=[],n._eventListeners=[],n._resizeListeners=[],n._eventConfig=Qpe(e.eventConfig),n.globalCursor(n._eventConfig.globalCursor);const s=vye(n,e,t.expr);n._runtime=s,n._signals=s.signals,n._bind=(e.bindings||[]).map(o=>({state:null,param:dt({},o)})),s.root&&s.root.set(i),i.source=s.data.root.input,n.pulse(s.data.root.input,n.changeset().insert(i.items)),n._width=n.width(),n._height=n.height(),n._viewWidth=rq(n,n._width),n._viewHeight=aq(n,n._height),n._origin=[0,0],n._resize=0,n._autosize=1,Sye(n),zpe(n),$pe(n),n.description(e.description),t.hover&&n.hover(),t.container&&n.initialize(t.container,t.bind)}function a_(e,t){return De(e._signals,t)?e._signals[t]:ce("Unrecognized signal name: "+Te(t))}function dq(e,t){const n=(e._targets||[]).filter(i=>i._update&&i._update.handler===t);return n.length?n[0]:null}function OO(e,t,n,i){let s=dq(n,i);return s||(s=uE(e,()=>i(t,n.value)),s.handler=i,e.on(n,null,s)),e}function MO(e,t,n){const i=dq(t,n);return i&&t._targets.remove(i),e}Le(cq,wu,{async evaluate(e,t,n){if(await wu.prototype.evaluate.call(this,e,t),this._redraw||this._resize)try{this._renderer&&(this._resize&&(this._resize=0,Wpe(this)),await this._renderer.renderAsync(this._scenegraph.root)),this._redraw=!1}catch(i){this.error(i)}return n&&z_(this,n),this},dirty(e){this._redraw=!0,this._renderer&&this._renderer.dirty(e)},description(e){if(arguments.length){const t=e!=null?e+"":null;return t!==this._desc&&J$(this._el,this._desc=t),this}return this._desc},container(){return this._el},scenegraph(){return this._scenegraph},origin(){return this._origin.slice()},signal(e,t,n){const i=a_(this,e);return arguments.length===1?i.value:this.update(i,t,n)},width(e){return arguments.length?this.signal("width",e):this.signal("width")},height(e){return arguments.length?this.signal("height",e):this.signal("height")},padding(e){return arguments.length?this.signal("padding",FO(e)):FO(this.signal("padding"))},autosize(e){return arguments.length?this.signal("autosize",e):this.signal("autosize")},background(e){return arguments.length?this.signal("background",e):this.signal("background")},renderer(e){return arguments.length?(km(e)||ce("Unrecognized renderer type: "+e),e!==this._renderType&&(this._renderType=e,this._resetRenderer()),this):this._renderType},tooltip(e){return arguments.length?(e!==this._tooltip&&(this._tooltip=e,this._resetRenderer()),this):this._tooltip},loader(e){return arguments.length?(e!==this._loader&&(wu.prototype.loader.call(this,e),this._resetRenderer()),this):this._loader},resize(){return this._autosize=1,this.touch(a_(this,"autosize"))},_resetRenderer(){this._renderer&&(this._renderer=null,this.initialize(this._el,this._elBind))},_resizeView:xye,addEventListener(e,t,n){let i=t;return n&&n.trap===!1||(i=uE(this,t),i.raw=t),this._handler.on(e,i),this},removeEventListener(e,t){for(var n=this._handler.handlers(e),i=n.length,s,o;--i>=0;)if(o=n[i].type,s=n[i].handler,e===o&&(t===s||t===s.raw)){this._handler.off(o,s);break}return this},addResizeListener(e){const t=this._resizeListeners;return t.indexOf(e)<0&&t.push(e),this},removeResizeListener(e){var t=this._resizeListeners,n=t.indexOf(e);return n>=0&&t.splice(n,1),this},addSignalListener(e,t){return OO(this,e,a_(this,e),t)},removeSignalListener(e,t){return MO(this,a_(this,e),t)},addDataListener(e,t){return OO(this,e,Dy(this,e).values,t)},removeDataListener(e,t){return MO(this,Dy(this,e).values,t)},globalCursor(e){if(arguments.length){if(this._globalCursor!==!!e){const t=E8(this,null);this._globalCursor=!!e,t&&E8(this,t)}return this}else return this._globalCursor},preventDefault(e){return arguments.length?(this._preventDefault=e,this):this._preventDefault},timer:Oye,events:tye,finalize:iye,hover:nye,data:qpe,change:Nm,insert:Vpe,remove:Gpe,scale:Eye,initialize:yye,toImageURL:wye,toCanvas:bye,toSVG:Tye,getState:kye,setState:Iye});const Cye="view",Uy="[",Hy="]",fq="{",uq="}",Rye=":",hq=",",Pye="@",Dye=">",jye=/[[\]{}]/,Uye={"*":1,arc:1,area:1,group:1,image:1,line:1,path:1,rect:1,rule:1,shape:1,symbol:1,text:1,trail:1};let gq,_q;function xc(e,t,n){return gq=t||Cye,_q=n||Uye,pq(e.trim()).map(S8)}function Hye(e){return _q[e]}function l2(e,t,n,i,s){const o=e.length;let c=0,d;for(;t=0?--c:i&&i.indexOf(d)>=0&&++c}return t}function pq(e){const t=[],n=e.length;let i=0,s=0;for(;s' after between selector: "+e;i=i.map(S8);const s=S8(e.slice(1).trim());return s.between?{between:i,stream:s}:(s.between=i,s)}function $ye(e){const t={source:gq},n=[];let i=[0,0],s=0,o=0,c=e.length,d=0,f,u;if(e[c-1]===uq){if(d=e.lastIndexOf(fq),d>=0){try{i=qye(e.substring(d+1,c-1))}catch{throw"Invalid throttle specification: "+e}e=e.slice(0,d).trim(),c=e.length}else throw"Unmatched right brace: "+e;d=0}if(!c)throw e;if(e[0]===Pye&&(s=++d),f=l2(e,d,Rye),f1?(t.type=n[1],s?t.markname=n[0].slice(1):Hye(n[0])?t.marktype=n[0]:t.source=n[0]):t.type=n[0],t.type.slice(-1)==="!"&&(t.consume=!0,t.type=t.type.slice(0,-1)),u!=null&&(t.filter=u),i[0]&&(t.throttle=i[0]),i[1]&&(t.debounce=i[1]),t}function qye(e){const t=e.split(hq);if(!e.length||t.length>2)throw e;return t.map(n=>{const i=+n;if(i!==i)throw e;return i})}function Vye(e){return ke(e)?e:{type:e||"pad"}}const f1=e=>+e||0,Gye=e=>({top:e,bottom:e,left:e,right:e});function Wye(e){return ke(e)?e.signal?e:{top:f1(e.top),bottom:f1(e.bottom),left:f1(e.left),right:f1(e.right)}:Gye(f1(e))}const Gn=e=>ke(e)&&!ue(e)?dt({},e):{value:e};function AO(e,t,n,i){return n!=null?(ke(n)&&!ue(n)||ue(n)&&n.length&&ke(n[0])?e.update[t]=n:e[i||"enter"][t]={value:n},1):0}function ri(e,t,n){for(const i in t)AO(e,i,t[i]);for(const i in n)AO(e,i,n[i],"update")}function Ch(e,t,n){for(const i in t)n&&De(n,i)||(e[i]=dt(e[i]||{},t[i]));return e}function eu(e,t){return t&&(t.enter&&t.enter[e]||t.update&&t.update[e])}const _E="mark",pE="frame",yE="scope",Yye="axis",Xye="axis-domain",Kye="axis-grid",Zye="axis-label",Jye="axis-tick",Qye="axis-title",e4e="legend",t4e="legend-band",n4e="legend-entry",i4e="legend-gradient",yq="legend-label",s4e="legend-symbol",r4e="legend-title",a4e="title",o4e="title-text",l4e="title-subtitle";function c4e(e,t,n,i,s){const o={},c={};let d,f,u,a;f="lineBreak",t==="text"&&s[f]!=null&&!eu(f,e)&&t5(o,f,s[f]),(n=="legend"||String(n).startsWith("axis"))&&(n=null),a=n===pE?s.group:n===_E?dt({},s.mark,s[t]):null;for(f in a)u=eu(f,e)||(f==="fill"||f==="stroke")&&(eu("fill",e)||eu("stroke",e)),u||t5(o,f,a[f]);Se(i).forEach(m=>{const y=s.style&&s.style[m];for(const p in y)eu(p,e)||t5(o,p,y[p])}),e=dt({},e);for(f in o)a=o[f],a.signal?(d=d||{})[f]=a:c[f]=a;return e.enter=dt(c,e.enter),d&&(e.update=dt(d,e.update)),e}function t5(e,t,n){e[t]=n&&n.signal?{signal:n.signal}:{value:n}}const mq=e=>xe(e)?Te(e):e.signal?`(${e.signal})`:wq(e);function Rm(e){if(e.gradient!=null)return f4e(e);let t=e.signal?`(${e.signal})`:e.color?d4e(e.color):e.field!=null?wq(e.field):e.value!==void 0?Te(e.value):void 0;return e.scale!=null&&(t=u4e(e,t)),t===void 0&&(t=null),e.exponent!=null&&(t=`pow(${t},${tp(e.exponent)})`),e.mult!=null&&(t+=`*${tp(e.mult)}`),e.offset!=null&&(t+=`+${tp(e.offset)}`),e.round&&(t=`round(${t})`),t}const o_=(e,t,n,i)=>`(${e}(${[t,n,i].map(Rm).join(",")})+'')`;function d4e(e){return e.c?o_("hcl",e.h,e.c,e.l):e.h||e.s?o_("hsl",e.h,e.s,e.l):e.l||e.a?o_("lab",e.l,e.a,e.b):e.r||e.g||e.b?o_("rgb",e.r,e.g,e.b):null}function f4e(e){const t=[e.start,e.stop,e.count].map(n=>n==null?null:Te(n));for(;t.length&&kt(t)==null;)t.pop();return t.unshift(mq(e.gradient)),`gradient(${t.join(",")})`}function tp(e){return ke(e)?"("+Rm(e)+")":e}function wq(e){return Lq(ke(e)?e:{datum:e})}function Lq(e){let t,n,i;if(e.signal)t="datum",i=e.signal;else if(e.group||e.parent){for(n=Math.max(1,e.level||1),t="item";n-- >0;)t+=".mark.group";e.parent?(i=e.parent,t+=".datum"):i=e.group}else e.datum?(t="datum",i=e.datum):ce("Invalid field reference: "+Te(e));return e.signal||(i=xe(i)?Ja(i).map(Te).join("]["):Lq(i)),t+"["+i+"]"}function u4e(e,t){const n=mq(e.scale);return e.range!=null?t=`lerp(_range(${n}), ${+e.range})`:(t!==void 0&&(t=`_scale(${n}, ${t})`),e.band&&(t=(t?t+"+":"")+`_bandwidth(${n})`+(+e.band==1?"":"*"+tp(e.band)),e.extra&&(t=`(datum.extra ? _scale(${n}, datum.extra.value) : ${t})`)),t==null&&(t="0")),t}function h4e(e){let t="";return e.forEach(n=>{const i=Rm(n);t+=n.test?`(${n.test})?${i}:`:i}),kt(t)===":"&&(t+="null"),t}function bq(e,t,n,i,s,o){const c={};o=o||{},o.encoders={$encode:c},e=c4e(e,t,n,i,s.config);for(const d in e)c[d]=g4e(e[d],t,o,s);return o}function g4e(e,t,n,i){const s={},o={};for(const c in e)e[c]!=null&&(s[c]=p4e(_4e(e[c]),i,n,o));return{$expr:{marktype:t,channels:s},$fields:Object.keys(o),$output:Object.keys(e)}}function _4e(e){return ue(e)?h4e(e):Rm(e)}function p4e(e,t,n,i){const s=za(e,t);return s.$fields.forEach(o=>i[o]=1),dt(n,s.$params),s.$expr}const y4e="outer",m4e=["value","update","init","react","bind"];function NO(e,t){ce(e+' for "outer" push: '+Te(t))}function Tq(e,t){const n=e.name;if(e.push===y4e)t.signals[n]||NO("No prior signal definition",n),m4e.forEach(i=>{e[i]!==void 0&&NO("Invalid property ",i)});else{const i=t.addSignal(n,e.value);e.react===!1&&(i.react=!1),e.bind&&t.addBinding(n,e.bind)}}function x8(e,t,n,i){this.id=-1,this.type=e,this.value=t,this.params=n,i&&(this.parent=i)}function Pm(e,t,n,i){return new x8(e,t,n,i)}function zy(e,t){return Pm("operator",e,t)}function Ce(e){const t={$ref:e.id};return e.id<0&&(e.refs=e.refs||[]).push(t),t}function Y2(e,t){return t?{$field:e,$name:t}:{$field:e}}const k8=Y2("key");function CO(e,t){return{$compare:e,$order:t}}function w4e(e,t){const n={$key:e};return t&&(n.$flat=!0),n}const L4e="ascending",b4e="descending";function T4e(e){return ke(e)?(e.order===b4e?"-":"+")+Dm(e.op,e.field):""}function Dm(e,t){return(e&&e.signal?"$"+e.signal:e||"")+(e&&t?"_":"")+(t&&t.signal?"$"+t.signal:t||"")}const mE="scope",B8="view";function Rn(e){return e&&e.signal}function v4e(e){return e&&e.expr}function np(e){if(Rn(e))return!0;if(ke(e)){for(const t in e)if(np(e[t]))return!0}return!1}function br(e,t){return e??t}function xd(e){return e&&e.signal||e}const RO="timer";function X2(e,t){return(e.merge?S4e:e.stream?x4e:e.type?k4e:ce("Invalid stream specification: "+Te(e)))(e,t)}function E4e(e){return e===mE?B8:e||B8}function S4e(e,t){const n=e.merge.map(s=>X2(s,t)),i=wE({merge:n},e,t);return t.addStream(i).id}function x4e(e,t){const n=X2(e.stream,t),i=wE({stream:n},e,t);return t.addStream(i).id}function k4e(e,t){let n;e.type===RO?(n=t.event(RO,e.throttle),e={between:e.between,filter:e.filter}):n=t.event(E4e(e.source),e.type);const i=wE({stream:n},e,t);return Object.keys(i).length===1?n:t.addStream(i).id}function wE(e,t,n){let i=t.between;return i&&(i.length!==2&&ce('Stream "between" parameter must have 2 entries: '+Te(t)),e.between=[X2(i[0],n),X2(i[1],n)]),i=t.filter?[].concat(t.filter):[],(t.marktype||t.markname||t.markrole)&&i.push(B4e(t.marktype,t.markname,t.markrole)),t.source===mE&&i.push("inScope(event.item)"),i.length&&(e.filter=za("("+i.join(")&&(")+")",n).$expr),(i=t.throttle)!=null&&(e.throttle=+i),(i=t.debounce)!=null&&(e.debounce=+i),t.consume&&(e.consume=!0),e}function B4e(e,t,n){const i="event.item";return i+(e&&e!=="*"?"&&"+i+".mark.marktype==='"+e+"'":"")+(n?"&&"+i+".mark.role==='"+n+"'":"")+(t?"&&"+i+".mark.name==='"+t+"'":"")}const F4e={code:"_.$value",ast:{type:"Identifier",value:"value"}};function I4e(e,t,n){const i=e.encode,s={target:n};let o=e.events,c=e.update,d=[];o||ce("Signal update missing events specification."),xe(o)&&(o=xc(o,t.isSubscope()?mE:B8)),o=Se(o).filter(f=>f.signal||f.scale?(d.push(f),0):1),d.length>1&&(d=[M4e(d)]),o.length&&d.push(o.length>1?{merge:o}:o[0]),i!=null&&(c&&ce("Signal encode and update are mutually exclusive."),c="encode(item(),"+Te(i)+")"),s.update=xe(c)?za(c,t):c.expr!=null?za(c.expr,t):c.value!=null?c.value:c.signal!=null?{$expr:F4e,$params:{$value:t.signalRef(c.signal)}}:ce("Invalid signal update specification."),e.force&&(s.options={force:!0}),d.forEach(f=>t.addUpdate(dt(O4e(f,t),s)))}function O4e(e,t){return{source:e.signal?t.signalRef(e.signal):e.scale?t.scaleRef(e.scale):X2(e,t)}}function M4e(e){return{signal:"["+e.map(t=>t.scale?'scale("'+t.scale+'")':t.signal)+"]"}}function A4e(e,t){const n=t.getSignal(e.name);let i=e.update;e.init&&(i?ce("Signals can not include both init and update expressions."):(i=e.init,n.initonly=!0)),i&&(i=za(i,t),n.update=i.$expr,n.params=i.$params),e.on&&e.on.forEach(s=>I4e(s,t,n.id))}const Xt=e=>(t,n,i)=>Pm(e,n,t||void 0,i),vq=Xt("aggregate"),N4e=Xt("axisticks"),Eq=Xt("bound"),Kr=Xt("collect"),PO=Xt("compare"),C4e=Xt("datajoin"),Sq=Xt("encode"),R4e=Xt("expression"),P4e=Xt("facet"),D4e=Xt("field"),j4e=Xt("key"),U4e=Xt("legendentries"),H4e=Xt("load"),z4e=Xt("mark"),$4e=Xt("multiextent"),q4e=Xt("multivalues"),V4e=Xt("overlap"),G4e=Xt("params"),xq=Xt("prefacet"),W4e=Xt("projection"),Y4e=Xt("proxy"),X4e=Xt("relay"),kq=Xt("render"),K4e=Xt("scale"),yf=Xt("sieve"),Z4e=Xt("sortitems"),Bq=Xt("viewlayout"),J4e=Xt("values");let Q4e=0;const Fq={min:"min",max:"max",count:"sum"};function eme(e,t){const n=e.type||"linear";vH(n)||ce("Unrecognized scale type: "+Te(n)),t.addScale(e.name,{type:n,domain:void 0})}function tme(e,t){const n=t.getScale(e.name).params;let i;n.domain=Iq(e.domain,e,t),e.range!=null&&(n.range=Mq(e,t,n)),e.interpolate!=null&&fme(e.interpolate,n),e.nice!=null&&(n.nice=dme(e.nice)),e.bins!=null&&(n.bins=cme(e.bins,t));for(i in e)De(n,i)||i==="name"||(n[i]=Xs(e[i],t))}function Xs(e,t){return ke(e)?e.signal?t.signalRef(e.signal):ce("Unsupported object: "+Te(e)):e}function ip(e,t){return e.signal?t.signalRef(e.signal):e.map(n=>Xs(n,t))}function jm(e){ce("Can not find data set: "+Te(e))}function Iq(e,t,n){if(!e){(t.domainMin!=null||t.domainMax!=null)&&ce("No scale domain defined for domainMin/domainMax to override.");return}return e.signal?n.signalRef(e.signal):(ue(e)?nme:e.fields?sme:ime)(e,t,n)}function nme(e,t,n){return e.map(i=>Xs(i,n))}function ime(e,t,n){const i=n.getData(e.data);return i||jm(e.data),Qu(t.type)?i.valuesRef(n,e.field,Oq(e.sort,!1)):xH(t.type)?i.domainRef(n,e.field):i.extentRef(n,e.field)}function sme(e,t,n){const i=e.data,s=e.fields.reduce((o,c)=>(c=xe(c)?{data:i,field:c}:ue(c)||c.signal?rme(c,n):c,o.push(c),o),[]);return(Qu(t.type)?ame:xH(t.type)?ome:lme)(e,n,s)}function rme(e,t){const n="_:vega:_"+Q4e++,i=Kr({});if(ue(e))i.value={$ingest:e};else if(e.signal){const s="setdata("+Te(n)+","+e.signal+")";i.params.input=t.signalRef(s)}return t.addDataPipeline(n,[i,yf({})]),{data:n,field:"data"}}function ame(e,t,n){const i=Oq(e.sort,!0);let s,o;const c=n.map(u=>{const a=t.getData(u.data);return a||jm(u.data),a.countsRef(t,u.field,i)}),d={groupby:k8,pulse:c};i&&(s=i.op||"count",o=i.field?Dm(s,i.field):"count",d.ops=[Fq[s]],d.fields=[t.fieldRef(o)],d.as=[o]),s=t.add(vq(d));const f=t.add(Kr({pulse:Ce(s)}));return o=t.add(J4e({field:k8,sort:t.sortRef(i),pulse:Ce(f)})),Ce(o)}function Oq(e,t){return e&&(!e.field&&!e.op?ke(e)?e.field="key":e={field:"key"}:!e.field&&e.op!=="count"?ce("No field provided for sort aggregate op: "+e.op):t&&e.field&&e.op&&!Fq[e.op]&&ce("Multiple domain scales can not be sorted using "+e.op)),e}function ome(e,t,n){const i=n.map(s=>{const o=t.getData(s.data);return o||jm(s.data),o.domainRef(t,s.field)});return Ce(t.add(q4e({values:i})))}function lme(e,t,n){const i=n.map(s=>{const o=t.getData(s.data);return o||jm(s.data),o.extentRef(t,s.field)});return Ce(t.add($4e({extents:i})))}function cme(e,t){return e.signal||ue(e)?ip(e,t):t.objectProperty(e)}function dme(e){return ke(e)?{interval:Xs(e.interval),step:Xs(e.step)}:Xs(e)}function fme(e,t){t.interpolate=Xs(e.type||e),e.gamma!=null&&(t.interpolateGamma=Xs(e.gamma))}function Mq(e,t,n){const i=t.config.range;let s=e.range;if(s.signal)return t.signalRef(s.signal);if(xe(s)){if(i&&De(i,s))return e=dt({},e,{range:i[s]}),Mq(e,t,n);s==="width"?s=[0,{signal:"width"}]:s==="height"?s=Qu(e.type)?[0,{signal:"height"}]:[{signal:"height"},0]:ce("Unrecognized scale range value: "+Te(s))}else if(s.scheme){n.scheme=ue(s.scheme)?ip(s.scheme,t):Xs(s.scheme,t),s.extent&&(n.schemeExtent=ip(s.extent,t)),s.count&&(n.schemeCount=Xs(s.count,t));return}else if(s.step){n.rangeStep=Xs(s.step,t);return}else{if(Qu(e.type)&&!ue(s))return Iq(s,e,t);ue(s)||ce("Unsupported range type: "+Te(s))}return s.map(o=>(ue(o)?ip:Xs)(o,t))}function ume(e,t){const n=t.config.projection||{},i={};for(const s in e)s!=="name"&&(i[s]=F8(e[s],s,t));for(const s in n)i[s]==null&&(i[s]=F8(n[s],s,t));t.addProjection(e.name,i)}function F8(e,t,n){return ue(e)?e.map(i=>F8(i,t,n)):ke(e)?e.signal?n.signalRef(e.signal):t==="fit"?e:ce("Unsupported parameter object: "+Te(e)):e}const Zr="top",Rh="left",Ph="right",lc="bottom",Aq="center",hme="vertical",gme="start",_me="middle",pme="end",I8="index",LE="label",yme="offset",rh="perc",mme="perc2",Js="value",Z0="guide-label",bE="guide-title",wme="group-title",Lme="group-subtitle",DO="symbol",sp="gradient",O8="discrete",M8="size",bme="shape",Tme="fill",vme="stroke",Eme="strokeWidth",Sme="strokeDash",xme="opacity",TE=[M8,bme,Tme,vme,Eme,Sme,xme],J0={name:1,style:1,interactive:1},Ft={value:0},Qs={value:1},Um="group",Nq="rect",vE="rule",kme="symbol",mf="text";function K2(e){return e.type=Um,e.interactive=e.interactive||!1,e}function bs(e,t){const n=(i,s)=>br(e[i],br(t[i],s));return n.isVertical=i=>hme===br(e.direction,t.direction||(i?t.symbolDirection:t.gradientDirection)),n.gradientLength=()=>br(e.gradientLength,t.gradientLength||t.gradientWidth),n.gradientThickness=()=>br(e.gradientThickness,t.gradientThickness||t.gradientHeight),n.entryColumns=()=>br(e.columns,br(t.columns,+n.isVertical(!0))),n}function Cq(e,t){const n=t&&(t.update&&t.update[e]||t.enter&&t.enter[e]);return n&&n.signal?n:n?n.value:null}function Bme(e,t,n){const i=t.config.style[n];return i&&i[e]}function Hm(e,t,n){return`item.anchor === '${gme}' ? ${e} : item.anchor === '${pme}' ? ${t} : ${n}`}const EE=Hm(Te(Rh),Te(Ph),Te(Aq));function Fme(e){const t=e("tickBand");let n=e("tickOffset"),i,s;return t?t.signal?(i={signal:`(${t.signal}) === 'extent' ? 1 : 0.5`},s={signal:`(${t.signal}) === 'extent'`},ke(n)||(n={signal:`(${t.signal}) === 'extent' ? 0 : ${n}`})):t==="extent"?(i=1,s=!0,n=0):(i=.5,s=!1):(i=e("bandPosition"),s=e("tickExtra")),{extra:s,band:i,offset:n}}function Rq(e,t){return t?e?ke(e)?Object.assign({},e,{offset:Rq(e.offset,t)}):{value:e,offset:t}:t:e}function js(e,t){return t?(e.name=t.name,e.style=t.style||e.style,e.interactive=!!t.interactive,e.encode=Ch(e.encode,t,J0)):e.interactive=!1,e}function Ime(e,t,n,i){const s=bs(e,n),o=s.isVertical(),c=s.gradientThickness(),d=s.gradientLength();let f,u,a,m,y;o?(u=[0,1],a=[0,0],m=c,y=d):(u=[0,0],a=[1,0],m=d,y=c);const p={enter:f={opacity:Ft,x:Ft,y:Ft,width:Gn(m),height:Gn(y)},update:dt({},f,{opacity:Qs,fill:{gradient:t,start:u,stop:a}}),exit:{opacity:Ft}};return ri(p,{stroke:s("gradientStrokeColor"),strokeWidth:s("gradientStrokeWidth")},{opacity:s("gradientOpacity")}),js({type:Nq,role:i4e,encode:p},i)}function Ome(e,t,n,i,s){const o=bs(e,n),c=o.isVertical(),d=o.gradientThickness(),f=o.gradientLength();let u,a,m,y,p="";c?(u="y",m="y2",a="x",y="width",p="1-"):(u="x",m="x2",a="y",y="height");const l={opacity:Ft,fill:{scale:t,field:Js}};l[u]={signal:p+"datum."+rh,mult:f},l[a]=Ft,l[m]={signal:p+"datum."+mme,mult:f},l[y]=Gn(d);const b={enter:l,update:dt({},l,{opacity:Qs}),exit:{opacity:Ft}};return ri(b,{stroke:o("gradientStrokeColor"),strokeWidth:o("gradientStrokeWidth")},{opacity:o("gradientOpacity")}),js({type:Nq,role:t4e,key:Js,from:s,encode:b},i)}const Mme=`datum.${rh}<=0?"${Rh}":datum.${rh}>=1?"${Ph}":"${Aq}"`,Ame=`datum.${rh}<=0?"${lc}":datum.${rh}>=1?"${Zr}":"${_me}"`;function jO(e,t,n,i){const s=bs(e,t),o=s.isVertical(),c=Gn(s.gradientThickness()),d=s.gradientLength();let f=s("labelOverlap"),u,a,m,y,p="";const l={enter:u={opacity:Ft},update:a={opacity:Qs,text:{field:LE}},exit:{opacity:Ft}};return ri(l,{fill:s("labelColor"),fillOpacity:s("labelOpacity"),font:s("labelFont"),fontSize:s("labelFontSize"),fontStyle:s("labelFontStyle"),fontWeight:s("labelFontWeight"),limit:br(e.labelLimit,t.gradientLabelLimit)}),o?(u.align={value:"left"},u.baseline=a.baseline={signal:Ame},m="y",y="x",p="1-"):(u.align=a.align={signal:Mme},u.baseline={value:"top"},m="x",y="y"),u[m]=a[m]={signal:p+"datum."+rh,mult:d},u[y]=a[y]=c,c.offset=br(e.labelOffset,t.gradientLabelOffset)||0,f=f?{separation:s("labelSeparation"),method:f,order:"datum."+I8}:void 0,js({type:mf,role:yq,style:Z0,key:Js,from:i,encode:l,overlap:f},n)}function Nme(e,t,n,i,s){const o=bs(e,t),c=n.entries,d=!!(c&&c.interactive),f=c?c.name:void 0,u=o("clipHeight"),a=o("symbolOffset"),m={data:"value"},y=`(${s}) ? datum.${yme} : datum.${M8}`,p=u?Gn(u):{field:M8},l=`datum.${I8}`,b=`max(1, ${s})`;let L,E,S,x,F;p.mult=.5,L={enter:E={opacity:Ft,x:{signal:y,mult:.5,offset:a},y:p},update:S={opacity:Qs,x:E.x,y:E.y},exit:{opacity:Ft}};let k=null,M=null;e.fill||(k=t.symbolBaseFillColor,M=t.symbolBaseStrokeColor),ri(L,{fill:o("symbolFillColor",k),shape:o("symbolType"),size:o("symbolSize"),stroke:o("symbolStrokeColor",M),strokeDash:o("symbolDash"),strokeDashOffset:o("symbolDashOffset"),strokeWidth:o("symbolStrokeWidth")},{opacity:o("symbolOpacity")}),TE.forEach(j=>{e[j]&&(S[j]=E[j]={scale:e[j],field:Js})});const O=js({type:kme,role:s4e,key:Js,from:m,clip:u?!0:void 0,encode:L},n.symbols),C=Gn(a);C.offset=o("labelOffset"),L={enter:E={opacity:Ft,x:{signal:y,offset:C},y:p},update:S={opacity:Qs,text:{field:LE},x:E.x,y:E.y},exit:{opacity:Ft}},ri(L,{align:o("labelAlign"),baseline:o("labelBaseline"),fill:o("labelColor"),fillOpacity:o("labelOpacity"),font:o("labelFont"),fontSize:o("labelFontSize"),fontStyle:o("labelFontStyle"),fontWeight:o("labelFontWeight"),limit:o("labelLimit")});const P=js({type:mf,role:yq,style:Z0,key:Js,from:m,encode:L},n.labels);return L={enter:{noBound:{value:!u},width:Ft,height:u?Gn(u):Ft,opacity:Ft},exit:{opacity:Ft},update:S={opacity:Qs,row:{signal:null},column:{signal:null}}},o.isVertical(!0)?(x=`ceil(item.mark.items.length / ${b})`,S.row.signal=`${l}%${x}`,S.column.signal=`floor(${l} / ${x})`,F={field:["row",l]}):(S.row.signal=`floor(${l} / ${b})`,S.column.signal=`${l} % ${b}`,F={field:l}),S.column.signal=`(${s})?${S.column.signal}:${l}`,i={facet:{data:i,name:"value",groupby:I8}},K2({role:yE,from:i,encode:Ch(L,c,J0),marks:[O,P],name:f,interactive:d,sort:F})}function Cme(e,t){const n=bs(e,t);return{align:n("gridAlign"),columns:n.entryColumns(),center:{row:!0,column:!1},padding:{row:n("rowPadding"),column:n("columnPadding")}}}const SE='item.orient === "left"',xE='item.orient === "right"',zm=`(${SE} || ${xE})`,Rme=`datum.vgrad && ${zm}`,Pme=Hm('"top"','"bottom"','"middle"'),Dme=Hm('"right"','"left"','"center"'),jme=`datum.vgrad && ${xE} ? (${Dme}) : (${zm} && !(datum.vgrad && ${SE})) ? "left" : ${EE}`,Ume=`item._anchor || (${zm} ? "middle" : "start")`,Hme=`${Rme} ? (${SE} ? -90 : 90) : 0`,zme=`${zm} ? (datum.vgrad ? (${xE} ? "bottom" : "top") : ${Pme}) : "top"`;function $me(e,t,n,i){const s=bs(e,t),o={enter:{opacity:Ft},update:{opacity:Qs,x:{field:{group:"padding"}},y:{field:{group:"padding"}}},exit:{opacity:Ft}};return ri(o,{orient:s("titleOrient"),_anchor:s("titleAnchor"),anchor:{signal:Ume},angle:{signal:Hme},align:{signal:jme},baseline:{signal:zme},text:e.title,fill:s("titleColor"),fillOpacity:s("titleOpacity"),font:s("titleFont"),fontSize:s("titleFontSize"),fontStyle:s("titleFontStyle"),fontWeight:s("titleFontWeight"),limit:s("titleLimit"),lineHeight:s("titleLineHeight")},{align:s("titleAlign"),baseline:s("titleBaseline")}),js({type:mf,role:r4e,style:bE,from:i,encode:o},n)}function qme(e,t){let n;return ke(e)&&(e.signal?n=e.signal:e.path?n="pathShape("+UO(e.path)+")":e.sphere&&(n="geoShape("+UO(e.sphere)+', {type: "Sphere"})')),n?t.signalRef(n):!!e}function UO(e){return ke(e)&&e.signal?e.signal:Te(e)}function Pq(e){const t=e.role||"";return!t.indexOf("axis")||!t.indexOf("legend")||!t.indexOf("title")?t:e.type===Um?yE:t||_E}function Vme(e){return{marktype:e.type,name:e.name||void 0,role:e.role||Pq(e),zindex:+e.zindex||void 0,aria:e.aria,description:e.description}}function Gme(e,t){return e&&e.signal?t.signalRef(e.signal):e!==!1}function kE(e,t){const n=$U(e.type);n||ce("Unrecognized transform type: "+Te(e.type));const i=Pm(n.type.toLowerCase(),null,Dq(n,e,t));return e.signal&&t.addSignal(e.signal,t.proxy(i)),i.metadata=n.metadata||{},i}function Dq(e,t,n){const i={},s=e.params.length;for(let o=0;oHO(e,o,n)):HO(e,s,n)}function HO(e,t,n){const i=e.type;if(Rn(t))return $O(i)?ce("Expression references can not be signals."):n5(i)?n.fieldRef(t):qO(i)?n.compareRef(t):n.signalRef(t.signal);{const s=e.expr||n5(i);return s&&Kme(t)?n.exprRef(t.expr,t.as):s&&Zme(t)?Y2(t.field,t.as):$O(i)?za(t,n):Jme(i)?Ce(n.getData(t).values):n5(i)?Y2(t):qO(i)?n.compareRef(t):t}}function Yme(e,t,n){return xe(t.from)||ce('Lookup "from" parameter must be a string literal.'),n.getData(t.from).lookupRef(n,t.key)}function Xme(e,t,n){const i=t[e.name];return e.array?(ue(i)||ce("Expected an array of sub-parameters. Instead: "+Te(i)),i.map(s=>zO(e,s,n))):zO(e,i,n)}function zO(e,t,n){const i=e.params.length;let s;for(let c=0;ce&&e.expr,Zme=e=>e&&e.field,Jme=e=>e==="data",$O=e=>e==="expr",n5=e=>e==="field",qO=e=>e==="compare";function Qme(e,t,n){let i,s,o,c,d;return e?(i=e.facet)&&(t||ce("Only group marks can be faceted."),i.field!=null?c=d=rp(i,n):(e.data?d=Ce(n.getData(e.data).aggregate):(o=kE(dt({type:"aggregate",groupby:Se(i.groupby)},i.aggregate),n),o.params.key=n.keyRef(i.groupby),o.params.pulse=rp(i,n),c=d=Ce(n.add(o))),s=n.keyRef(i.groupby,!0))):c=Ce(n.add(Kr(null,[{}]))),c||(c=rp(e,n)),{key:s,pulse:c,parent:d}}function rp(e,t){return e.$ref?e:e.data&&e.data.$ref?e.data:Ce(t.getData(e.data).output)}function Vd(e,t,n,i,s){this.scope=e,this.input=t,this.output=n,this.values=i,this.aggregate=s,this.index={}}Vd.fromEntries=function(e,t){const n=t.length,i=t[n-1],s=t[n-2];let o=t[0],c=null,d=1;for(o&&o.type==="load"&&(o=t[1]),e.add(t[0]);dm??"null").join(",")+"),0)",a=za(u,t);f.update=a.$expr,f.params=a.$params}function $m(e,t){const n=Pq(e),i=e.type===Um,s=e.from&&e.from.facet,o=e.overlap;let c=e.layout||n===yE||n===pE,d,f,u,a,m,y,p;const l=n===_E||c||s,b=Qme(e.from,i,t);f=t.add(C4e({key:b.key||(e.key?Y2(e.key):void 0),pulse:b.pulse,clean:!i}));const L=Ce(f);f=u=t.add(Kr({pulse:L})),f=t.add(z4e({markdef:Vme(e),interactive:Gme(e.interactive,t),clip:qme(e.clip,t),context:{$context:!0},groups:t.lookup(),parent:t.signals.parent?t.signalRef("parent"):null,index:t.markpath(),pulse:Ce(f)}));const E=Ce(f);f=a=t.add(Sq(bq(e.encode,e.type,n,e.style,t,{mod:!1,pulse:E}))),f.params.parent=t.encode(),e.transform&&e.transform.forEach(M=>{const O=kE(M,t),C=O.metadata;(C.generates||C.changes)&&ce("Mark transforms should not generate new data."),C.nomod||(a.params.mod=!0),O.params.pulse=Ce(f),t.add(f=O)}),e.sort&&(f=t.add(Z4e({sort:t.compareRef(e.sort),pulse:Ce(f)})));const S=Ce(f);(s||c)&&(c=t.add(Bq({layout:t.objectProperty(e.layout),legends:t.legends,mark:E,pulse:S})),y=Ce(c));const x=t.add(Eq({mark:E,pulse:y||S}));p=Ce(x),i&&(l&&(d=t.operators,d.pop(),c&&d.pop()),t.pushState(S,y||p,L),s?e6e(e,t,b):l?t6e(e,t,b):t.parse(e),t.popState(),l&&(c&&d.push(c),d.push(x))),o&&(p=n6e(o,p,t));const F=t.add(kq({pulse:p})),k=t.add(yf({pulse:Ce(F)},void 0,t.parent()));e.name!=null&&(m=e.name,t.addData(m,new Vd(t,u,F,k)),e.on&&e.on.forEach(M=>{(M.insert||M.remove||M.toggle)&&ce("Marks only support modify triggers."),Uq(M,t,m)}))}function n6e(e,t,n){const i=e.method,s=e.bound,o=e.separation,c={separation:Rn(o)?n.signalRef(o.signal):o,method:Rn(i)?n.signalRef(i.signal):i,pulse:t};if(e.order&&(c.sort=n.compareRef({field:e.order})),s){const d=s.tolerance;c.boundTolerance=Rn(d)?n.signalRef(d.signal):+d,c.boundScale=n.scaleRef(s.scale),c.boundOrient=s.orient}return Ce(n.add(V4e(c)))}function i6e(e,t){const n=t.config.legend,i=e.encode||{},s=bs(e,n),o=i.legend||{},c=o.name||void 0,d=o.interactive,f=o.style,u={};let a=0,m,y,p;TE.forEach(x=>e[x]?(u[x]=e[x],a=a||e[x]):0),a||ce("Missing valid scale for legend.");const l=s6e(e,t.scaleType(a)),b={title:e.title!=null,scales:u,type:l,vgrad:l!=="symbol"&&s.isVertical()},L=Ce(t.add(Kr(null,[b]))),E={enter:{x:{value:0},y:{value:0}}},S=Ce(t.add(U4e(y={type:l,scale:t.scaleRef(a),count:t.objectProperty(s("tickCount")),limit:t.property(s("symbolLimit")),values:t.objectProperty(e.values),minstep:t.property(e.tickMinStep),formatType:t.property(e.formatType),formatSpecifier:t.property(e.format)})));return l===sp?(p=[Ime(e,a,n,i.gradient),jO(e,n,i.labels,S)],y.count=y.count||t.signalRef(`max(2,2*floor((${xd(s.gradientLength())})/100))`)):l===O8?p=[Ome(e,a,n,i.gradient,S),jO(e,n,i.labels,S)]:(m=Cme(e,n),p=[Nme(e,n,i,S,xd(m.columns))],y.size=o6e(e,t,p[0].marks)),p=[K2({role:n4e,from:L,encode:E,marks:p,layout:m,interactive:d})],b.title&&p.push($me(e,n,i.title,L)),$m(K2({role:e4e,from:L,encode:Ch(a6e(s,e,n),o,J0),marks:p,aria:s("aria"),description:s("description"),zindex:s("zindex"),name:c,interactive:d,style:f}),t)}function s6e(e,t){let n=e.type||DO;return!e.type&&r6e(e)===1&&(e.fill||e.stroke)&&(n=CT(t)?sp:GL(t)?O8:DO),n!==sp?n:GL(t)?O8:sp}function r6e(e){return TE.reduce((t,n)=>t+(e[n]?1:0),0)}function a6e(e,t,n){const i={enter:{},update:{}};return ri(i,{orient:e("orient"),offset:e("offset"),padding:e("padding"),titlePadding:e("titlePadding"),cornerRadius:e("cornerRadius"),fill:e("fillColor"),stroke:e("strokeColor"),strokeWidth:n.strokeWidth,strokeDash:n.strokeDash,x:e("legendX"),y:e("legendY"),format:t.format,formatType:t.formatType}),i}function o6e(e,t,n){const i=xd(GO("size",e,n)),s=xd(GO("strokeWidth",e,n)),o=xd(l6e(n[1].encode,t,Z0));return za(`max(ceil(sqrt(${i})+${s}),${o})`,t)}function GO(e,t,n){return t[e]?`scale("${t[e]}",datum)`:Cq(e,n[0].encode)}function l6e(e,t,n){return Cq("fontSize",e)||Bme("fontSize",t,n)}const c6e=`item.orient==="${Rh}"?-90:item.orient==="${Ph}"?90:0`;function d6e(e,t){e=xe(e)?{text:e}:e;const n=bs(e,t.config.title),i=e.encode||{},s=i.group||{},o=s.name||void 0,c=s.interactive,d=s.style,f=[],u={},a=Ce(t.add(Kr(null,[u])));return f.push(h6e(e,n,f6e(e),a)),e.subtitle&&f.push(g6e(e,n,i.subtitle,a)),$m(K2({role:a4e,from:a,encode:u6e(n,s),marks:f,aria:n("aria"),description:n("description"),zindex:n("zindex"),name:o,interactive:c,style:d}),t)}function f6e(e){const t=e.encode;return t&&t.title||dt({name:e.name,interactive:e.interactive,style:e.style},t)}function u6e(e,t){const n={enter:{},update:{}};return ri(n,{orient:e("orient"),anchor:e("anchor"),align:{signal:EE},angle:{signal:c6e},limit:e("limit"),frame:e("frame"),offset:e("offset")||0,padding:e("subtitlePadding")}),Ch(n,t,J0)}function h6e(e,t,n,i){const s={value:0},o=e.text,c={enter:{opacity:s},update:{opacity:{value:1}},exit:{opacity:s}};return ri(c,{text:o,align:{signal:"item.mark.group.align"},angle:{signal:"item.mark.group.angle"},limit:{signal:"item.mark.group.limit"},baseline:"top",dx:t("dx"),dy:t("dy"),fill:t("color"),font:t("font"),fontSize:t("fontSize"),fontStyle:t("fontStyle"),fontWeight:t("fontWeight"),lineHeight:t("lineHeight")},{align:t("align"),angle:t("angle"),baseline:t("baseline")}),js({type:mf,role:o4e,style:wme,from:i,encode:c},n)}function g6e(e,t,n,i){const s={value:0},o=e.subtitle,c={enter:{opacity:s},update:{opacity:{value:1}},exit:{opacity:s}};return ri(c,{text:o,align:{signal:"item.mark.group.align"},angle:{signal:"item.mark.group.angle"},limit:{signal:"item.mark.group.limit"},baseline:"top",dx:t("dx"),dy:t("dy"),fill:t("subtitleColor"),font:t("subtitleFont"),fontSize:t("subtitleFontSize"),fontStyle:t("subtitleFontStyle"),fontWeight:t("subtitleFontWeight"),lineHeight:t("subtitleLineHeight")},{align:t("align"),angle:t("angle"),baseline:t("baseline")}),js({type:mf,role:l4e,style:Lme,from:i,encode:c},n)}function _6e(e,t){const n=[];e.transform&&e.transform.forEach(i=>{n.push(kE(i,t))}),e.on&&e.on.forEach(i=>{Uq(i,t,e.name)}),t.addDataPipeline(e.name,p6e(e,t,n))}function p6e(e,t,n){const i=[];let s=null,o=!1,c=!1,d,f,u,a,m;for(e.values?Rn(e.values)||np(e.format)?(i.push(WO(t,e)),i.push(s=jc())):i.push(s=jc({$ingest:e.values,$format:e.format})):e.url?np(e.url)||np(e.format)?(i.push(WO(t,e)),i.push(s=jc())):i.push(s=jc({$request:e.url,$format:e.format})):e.source&&(s=d=Se(e.source).map(y=>Ce(t.getData(y).output)),i.push(null)),f=0,u=n.length;fe===lc||e===Zr,qm=(e,t,n)=>Rn(e)?L6e(e.signal,t,n):e===Rh||e===Zr?t:n,Wn=(e,t,n)=>Rn(e)?m6e(e.signal,t,n):Hq(e)?t:n,Dr=(e,t,n)=>Rn(e)?w6e(e.signal,t,n):Hq(e)?n:t,zq=(e,t,n)=>Rn(e)?b6e(e.signal,t,n):e===Zr?{value:t}:{value:n},y6e=(e,t,n)=>Rn(e)?T6e(e.signal,t,n):e===Ph?{value:t}:{value:n},m6e=(e,t,n)=>$q(`${e} === '${Zr}' || ${e} === '${lc}'`,t,n),w6e=(e,t,n)=>$q(`${e} !== '${Zr}' && ${e} !== '${lc}'`,t,n),L6e=(e,t,n)=>BE(`${e} === '${Rh}' || ${e} === '${Zr}'`,t,n),b6e=(e,t,n)=>BE(`${e} === '${Zr}'`,t,n),T6e=(e,t,n)=>BE(`${e} === '${Ph}'`,t,n),$q=(e,t,n)=>(t=t!=null?Gn(t):t,n=n!=null?Gn(n):n,YO(t)&&YO(n)?(t=t?t.signal||Te(t.value):null,n=n?n.signal||Te(n.value):null,{signal:`${e} ? (${t}) : (${n})`}):[dt({test:e},t)].concat(n||[])),YO=e=>e==null||Object.keys(e).length===1,BE=(e,t,n)=>({signal:`${e} ? (${cu(t)}) : (${cu(n)})`}),v6e=(e,t,n,i,s)=>({signal:(i!=null?`${e} === '${Rh}' ? (${cu(i)}) : `:"")+(n!=null?`${e} === '${lc}' ? (${cu(n)}) : `:"")+(s!=null?`${e} === '${Ph}' ? (${cu(s)}) : `:"")+(t!=null?`${e} === '${Zr}' ? (${cu(t)}) : `:"")+"(null)"}),cu=e=>Rn(e)?e.signal:e==null?null:Te(e),E6e=(e,t)=>t===0?0:Rn(e)?{signal:`(${e.signal}) * ${t}`}:{value:e*t},Lu=(e,t)=>{const n=e.signal;return n&&n.endsWith("(null)")?{signal:n.slice(0,-6)+t.signal}:e};function Rf(e,t,n,i){let s;if(t&&De(t,e))return t[e];if(De(n,e))return n[e];if(e.startsWith("title")){switch(e){case"titleColor":s="fill";break;case"titleFont":case"titleFontSize":case"titleFontWeight":s=e[5].toLowerCase()+e.slice(6)}return i[bE][s]}else if(e.startsWith("label")){switch(e){case"labelColor":s="fill";break;case"labelFont":case"labelFontSize":s=e[5].toLowerCase()+e.slice(6)}return i[Z0][s]}return null}function XO(e){const t={};for(const n of e)if(n)for(const i in n)t[i]=1;return Object.keys(t)}function S6e(e,t){var n=t.config,i=n.style,s=n.axis,o=t.scaleType(e.scale)==="band"&&n.axisBand,c=e.orient,d,f,u;if(Rn(c)){const m=XO([n.axisX,n.axisY]),y=XO([n.axisTop,n.axisBottom,n.axisLeft,n.axisRight]);d={};for(u of m)d[u]=Wn(c,Rf(u,n.axisX,s,i),Rf(u,n.axisY,s,i));f={};for(u of y)f[u]=v6e(c.signal,Rf(u,n.axisTop,s,i),Rf(u,n.axisBottom,s,i),Rf(u,n.axisLeft,s,i),Rf(u,n.axisRight,s,i))}else d=c===Zr||c===lc?n.axisX:n.axisY,f=n["axis"+c[0].toUpperCase()+c.slice(1)];return d||f||o?dt({},s,d,f,o):s}function x6e(e,t,n,i){const s=bs(e,t),o=e.orient;let c,d;const f={enter:c={opacity:Ft},update:d={opacity:Qs},exit:{opacity:Ft}};ri(f,{stroke:s("domainColor"),strokeCap:s("domainCap"),strokeDash:s("domainDash"),strokeDashOffset:s("domainDashOffset"),strokeWidth:s("domainWidth"),strokeOpacity:s("domainOpacity")});const u=KO(e,0),a=KO(e,1);return c.x=d.x=Wn(o,u,Ft),c.x2=d.x2=Wn(o,a),c.y=d.y=Dr(o,u,Ft),c.y2=d.y2=Dr(o,a),js({type:vE,role:Xye,from:i,encode:f},n)}function KO(e,t){return{scale:e.scale,range:t}}function k6e(e,t,n,i,s){const o=bs(e,t),c=e.orient,d=e.gridScale,f=qm(c,1,-1),u=B6e(e.offset,f);let a,m,y;const p={enter:a={opacity:Ft},update:y={opacity:Qs},exit:m={opacity:Ft}};ri(p,{stroke:o("gridColor"),strokeCap:o("gridCap"),strokeDash:o("gridDash"),strokeDashOffset:o("gridDashOffset"),strokeOpacity:o("gridOpacity"),strokeWidth:o("gridWidth")});const l={scale:e.scale,field:Js,band:s.band,extra:s.extra,offset:s.offset,round:o("tickRound")},b=Wn(c,{signal:"height"},{signal:"width"}),L=d?{scale:d,range:0,mult:f,offset:u}:{value:0,offset:u},E=d?{scale:d,range:1,mult:f,offset:u}:dt(b,{mult:f,offset:u});return a.x=y.x=Wn(c,l,L),a.y=y.y=Dr(c,l,L),a.x2=y.x2=Dr(c,E),a.y2=y.y2=Wn(c,E),m.x=Wn(c,l),m.y=Dr(c,l),js({type:vE,role:Kye,key:Js,from:i,encode:p},n)}function B6e(e,t){if(t!==1)if(!ke(e))e=Rn(t)?{signal:`(${t.signal}) * (${e||0})`}:t*(e||0);else{let n=e=dt({},e);for(;n.mult!=null;)if(ke(n.mult))n=n.mult=dt({},n.mult);else return n.mult=Rn(t)?{signal:`(${n.mult}) * (${t.signal})`}:n.mult*t,e;n.mult=t}return e}function F6e(e,t,n,i,s,o){const c=bs(e,t),d=e.orient,f=qm(d,-1,1);let u,a,m;const y={enter:u={opacity:Ft},update:m={opacity:Qs},exit:a={opacity:Ft}};ri(y,{stroke:c("tickColor"),strokeCap:c("tickCap"),strokeDash:c("tickDash"),strokeDashOffset:c("tickDashOffset"),strokeOpacity:c("tickOpacity"),strokeWidth:c("tickWidth")});const p=Gn(s);p.mult=f;const l={scale:e.scale,field:Js,band:o.band,extra:o.extra,offset:o.offset,round:c("tickRound")};return m.y=u.y=Wn(d,Ft,l),m.y2=u.y2=Wn(d,p),a.x=Wn(d,l),m.x=u.x=Dr(d,Ft,l),m.x2=u.x2=Dr(d,p),a.y=Dr(d,l),js({type:vE,role:Jye,key:Js,from:i,encode:y},n)}function i5(e,t,n,i,s){return{signal:'flush(range("'+e+'"), scale("'+e+'", datum.value), '+t+","+n+","+i+","+s+")"}}function I6e(e,t,n,i,s,o){const c=bs(e,t),d=e.orient,f=e.scale,u=qm(d,-1,1),a=xd(c("labelFlush")),m=xd(c("labelFlushOffset")),y=c("labelAlign"),p=c("labelBaseline");let l=a===0||!!a,b;const L=Gn(s);L.mult=u,L.offset=Gn(c("labelPadding")||0),L.offset.mult=u;const E={scale:f,field:Js,band:.5,offset:Rq(o.offset,c("labelOffset"))},S=Wn(d,l?i5(f,a,'"left"','"right"','"center"'):{value:"center"},y6e(d,"left","right")),x=Wn(d,zq(d,"bottom","top"),l?i5(f,a,'"top"','"bottom"','"middle"'):{value:"middle"}),F=i5(f,a,`-(${m})`,m,0);l=l&&m;const k={opacity:Ft,x:Wn(d,E,L),y:Dr(d,E,L)},M={enter:k,update:b={opacity:Qs,text:{field:LE},x:k.x,y:k.y,align:S,baseline:x},exit:{opacity:Ft,x:k.x,y:k.y}};ri(M,{dx:!y&&l?Wn(d,F):null,dy:!p&&l?Dr(d,F):null}),ri(M,{angle:c("labelAngle"),fill:c("labelColor"),fillOpacity:c("labelOpacity"),font:c("labelFont"),fontSize:c("labelFontSize"),fontWeight:c("labelFontWeight"),fontStyle:c("labelFontStyle"),limit:c("labelLimit"),lineHeight:c("labelLineHeight")},{align:y,baseline:p});const O=c("labelBound");let C=c("labelOverlap");return C=C||O?{separation:c("labelSeparation"),method:C,order:"datum.index",bound:O?{scale:f,orient:d,tolerance:O}:null}:void 0,b.align!==S&&(b.align=Lu(b.align,S)),b.baseline!==x&&(b.baseline=Lu(b.baseline,x)),js({type:mf,role:Zye,style:Z0,key:Js,from:i,encode:M,overlap:C},n)}function O6e(e,t,n,i){const s=bs(e,t),o=e.orient,c=qm(o,-1,1);let d,f;const u={enter:d={opacity:Ft,anchor:Gn(s("titleAnchor",null)),align:{signal:EE}},update:f=dt({},d,{opacity:Qs,text:Gn(e.title)}),exit:{opacity:Ft}},a={signal:`lerp(range("${e.scale}"), ${Hm(0,1,.5)})`};return f.x=Wn(o,a),f.y=Dr(o,a),d.angle=Wn(o,Ft,E6e(c,90)),d.baseline=Wn(o,zq(o,lc,Zr),{value:lc}),f.angle=d.angle,f.baseline=d.baseline,ri(u,{fill:s("titleColor"),fillOpacity:s("titleOpacity"),font:s("titleFont"),fontSize:s("titleFontSize"),fontStyle:s("titleFontStyle"),fontWeight:s("titleFontWeight"),limit:s("titleLimit"),lineHeight:s("titleLineHeight")},{align:s("titleAlign"),angle:s("titleAngle"),baseline:s("titleBaseline")}),M6e(s,o,u,n),u.update.align=Lu(u.update.align,d.align),u.update.angle=Lu(u.update.angle,d.angle),u.update.baseline=Lu(u.update.baseline,d.baseline),js({type:mf,role:Qye,style:bE,from:i,encode:u},n)}function M6e(e,t,n,i){const s=(d,f)=>d!=null?(n.update[f]=Lu(Gn(d),n.update[f]),!1):!eu(f,i),o=s(e("titleX"),"x"),c=s(e("titleY"),"y");n.enter.auto=c===o?Gn(c):Wn(t,Gn(c),Gn(o))}function A6e(e,t){const n=S6e(e,t),i=e.encode||{},s=i.axis||{},o=s.name||void 0,c=s.interactive,d=s.style,f=bs(e,n),u=Fme(f),a={scale:e.scale,ticks:!!f("ticks"),labels:!!f("labels"),grid:!!f("grid"),domain:!!f("domain"),title:e.title!=null},m=Ce(t.add(Kr({},[a]))),y=Ce(t.add(N4e({scale:t.scaleRef(e.scale),extra:t.property(u.extra),count:t.objectProperty(e.tickCount),values:t.objectProperty(e.values),minstep:t.property(e.tickMinStep),formatType:t.property(e.formatType),formatSpecifier:t.property(e.format)}))),p=[];let l;return a.grid&&p.push(k6e(e,n,i.grid,y,u)),a.ticks&&(l=f("tickSize"),p.push(F6e(e,n,i.ticks,y,l,u))),a.labels&&(l=a.ticks?l:0,p.push(I6e(e,n,i.labels,y,l,u))),a.domain&&p.push(x6e(e,n,i.domain,m)),a.title&&p.push(O6e(e,n,i.title,m)),$m(K2({role:Yye,from:m,encode:Ch(N6e(f,e),s,J0),marks:p,aria:f("aria"),description:f("description"),zindex:f("zindex"),name:o,interactive:c,style:d}),t)}function N6e(e,t){const n={enter:{},update:{}};return ri(n,{orient:e("orient"),offset:e("offset")||0,position:br(t.position,0),titlePadding:e("titlePadding"),minExtent:e("minExtent"),maxExtent:e("maxExtent"),range:{signal:`abs(span(range("${t.scale}")))`},translate:e("translate"),format:t.format,formatType:t.formatType}),n}function qq(e,t,n){const i=Se(e.signals),s=Se(e.scales);return n||i.forEach(o=>Tq(o,t)),Se(e.projections).forEach(o=>ume(o,t)),s.forEach(o=>eme(o,t)),Se(e.data).forEach(o=>_6e(o,t)),s.forEach(o=>tme(o,t)),(n||i).forEach(o=>A4e(o,t)),Se(e.axes).forEach(o=>A6e(o,t)),Se(e.marks).forEach(o=>$m(o,t)),Se(e.legends).forEach(o=>i6e(o,t)),e.title&&d6e(e.title,t),t.parseLambdas(),t}const C6e=e=>Ch({enter:{x:{value:0},y:{value:0}},update:{width:{signal:"width"},height:{signal:"height"}}},e);function R6e(e,t){const n=t.config,i=Ce(t.root=t.add(zy())),s=P6e(e,n);s.forEach(u=>Tq(u,t)),t.description=e.description||n.description,t.eventConfig=n.events,t.legends=t.objectProperty(n.legend&&n.legend.layout),t.locale=n.locale;const o=t.add(Kr()),c=t.add(Sq(bq(C6e(e.encode),Um,pE,e.style,t,{pulse:Ce(o)}))),d=t.add(Bq({layout:t.objectProperty(e.layout),legends:t.legends,autosize:t.signalRef("autosize"),mark:i,pulse:Ce(c)}));t.operators.pop(),t.pushState(Ce(c),Ce(d),null),qq(e,t,s),t.operators.push(d);let f=t.add(Eq({mark:i,pulse:Ce(d)}));return f=t.add(kq({pulse:Ce(f)})),f=t.add(yf({pulse:Ce(f)})),t.addData("root",new Vd(t,o,o,f)),t}function h1(e,t){return t&&t.signal?{name:e,update:t.signal}:{name:e,value:t}}function P6e(e,t){const n=c=>br(e[c],t[c]),i=[h1("background",n("background")),h1("autosize",Vye(n("autosize"))),h1("padding",Wye(n("padding"))),h1("width",n("width")||0),h1("height",n("height")||0)],s=i.reduce((c,d)=>(c[d.name]=d,c),{}),o={};return Se(e.signals).forEach(c=>{De(s,c.name)?c=dt(s[c.name],c):i.push(c),o[c.name]=c}),Se(t.signals).forEach(c=>{!De(o,c.name)&&!De(s,c.name)&&i.push(c)}),i}function Vq(e,t){this.config=e||{},this.options=t||{},this.bindings=[],this.field={},this.signals={},this.lambdas={},this.scales={},this.events={},this.data={},this.streams=[],this.updates=[],this.operators=[],this.eventConfig=null,this.locale=null,this._id=0,this._subid=0,this._nextsub=[0],this._parent=[],this._encode=[],this._lookup=[],this._markpath=[]}function ZO(e){this.config=e.config,this.options=e.options,this.legends=e.legends,this.field=Object.create(e.field),this.signals=Object.create(e.signals),this.lambdas=Object.create(e.lambdas),this.scales=Object.create(e.scales),this.events=Object.create(e.events),this.data=Object.create(e.data),this.streams=[],this.updates=[],this.operators=[],this._id=0,this._subid=++e._nextsub[0],this._nextsub=e._nextsub,this._parent=e._parent.slice(),this._encode=e._encode.slice(),this._lookup=e._lookup.slice(),this._markpath=e._markpath}Vq.prototype=ZO.prototype={parse(e){return qq(e,this)},fork(){return new ZO(this)},isSubscope(){return this._subid>0},toRuntime(){return this.finish(),{description:this.description,operators:this.operators,streams:this.streams,updates:this.updates,bindings:this.bindings,eventConfig:this.eventConfig,locale:this.locale}},id(){return(this._subid?this._subid+":":0)+this._id++},add(e){return this.operators.push(e),e.id=this.id(),e.refs&&(e.refs.forEach(t=>{t.$ref=e.id}),e.refs=null),e},proxy(e){const t=e instanceof x8?Ce(e):e;return this.add(Y4e({value:t}))},addStream(e){return this.streams.push(e),e.id=this.id(),e},addUpdate(e){return this.updates.push(e),e},finish(){let e,t;this.root&&(this.root.root=!0);for(e in this.signals)this.signals[e].signal=e;for(e in this.scales)this.scales[e].scale=e;function n(i,s,o){let c,d;i&&(c=i.data||(i.data={}),d=c[s]||(c[s]=[]),d.push(o))}for(e in this.data){t=this.data[e],n(t.input,e,"input"),n(t.output,e,"output"),n(t.values,e,"values");for(const i in t.index)n(t.index[i],e,"index:"+i)}return this},pushState(e,t,n){this._encode.push(Ce(this.add(yf({pulse:e})))),this._parent.push(t),this._lookup.push(n?Ce(this.proxy(n)):null),this._markpath.push(-1)},popState(){this._encode.pop(),this._parent.pop(),this._lookup.pop(),this._markpath.pop()},parent(){return kt(this._parent)},encode(){return kt(this._encode)},lookup(){return kt(this._lookup)},markpath(){const e=this._markpath;return++e[e.length-1]},fieldRef(e,t){if(xe(e))return Y2(e,t);e.signal||ce("Unsupported field reference: "+Te(e));const n=e.signal;let i=this.field[n];if(!i){const s={name:this.signalRef(n)};t&&(s.as=t),this.field[n]=i=Ce(this.add(D4e(s)))}return i},compareRef(e){let t=!1;const n=o=>Rn(o)?(t=!0,this.signalRef(o.signal)):v4e(o)?(t=!0,this.exprRef(o.expr)):o,i=Se(e.field).map(n),s=Se(e.order).map(n);return t?Ce(this.add(PO({fields:i,orders:s}))):CO(i,s)},keyRef(e,t){let n=!1;const i=o=>Rn(o)?(n=!0,Ce(s[o.signal])):o,s=this.signals;return e=Se(e).map(i),n?Ce(this.add(j4e({fields:e,flat:t}))):w4e(e,t)},sortRef(e){if(!e)return e;const t=Dm(e.op,e.field),n=e.order||L4e;return n.signal?Ce(this.add(PO({fields:t,orders:this.signalRef(n.signal)}))):CO(t,n)},event(e,t){const n=e+":"+t;if(!this.events[n]){const i=this.id();this.streams.push({id:i,source:e,type:t}),this.events[n]=i}return this.events[n]},hasOwnSignal(e){return De(this.signals,e)},addSignal(e,t){this.hasOwnSignal(e)&&ce("Duplicate signal name: "+Te(e));const n=t instanceof x8?t:this.add(zy(t));return this.signals[e]=n},getSignal(e){return this.signals[e]||ce("Unrecognized signal name: "+Te(e)),this.signals[e]},signalRef(e){return this.signals[e]?Ce(this.signals[e]):(De(this.lambdas,e)||(this.lambdas[e]=this.add(zy(null))),Ce(this.lambdas[e]))},parseLambdas(){const e=Object.keys(this.lambdas);for(let t=0,n=e.length;t0?",":"")+(ke(s)?s.signal||FE(s):Te(s))}return n+"]"}function j6e(e){let t="{",n=0,i,s;for(i in e)s=e[i],t+=(++n>1?",":"")+Te(i)+":"+(ke(s)?s.signal||FE(s):Te(s));return t+"}"}function U6e(){const e="sans-serif",i="#4c78a8",s="#000",o="#888",c="#ddd";return{description:"Vega visualization",padding:0,autosize:"pad",background:null,events:{defaults:{allow:["wheel"]}},group:null,mark:null,arc:{fill:i},area:{fill:i},image:null,line:{stroke:i,strokeWidth:2},path:{stroke:i},rect:{fill:i},rule:{stroke:s},shape:{stroke:i},symbol:{fill:i,size:64},text:{fill:s,font:e,fontSize:11},trail:{fill:i,size:2},style:{"guide-label":{fill:s,font:e,fontSize:10},"guide-title":{fill:s,font:e,fontSize:11,fontWeight:"bold"},"group-title":{fill:s,font:e,fontSize:13,fontWeight:"bold"},"group-subtitle":{fill:s,font:e,fontSize:12},point:{size:30,strokeWidth:2,shape:"circle"},circle:{size:30,strokeWidth:2},square:{size:30,strokeWidth:2,shape:"square"},cell:{fill:"transparent",stroke:c},view:{fill:"transparent"}},title:{orient:"top",anchor:"middle",offset:4,subtitlePadding:3},axis:{minExtent:0,maxExtent:200,bandPosition:.5,domain:!0,domainWidth:1,domainColor:o,grid:!1,gridWidth:1,gridColor:c,labels:!0,labelAngle:0,labelLimit:180,labelOffset:0,labelPadding:2,ticks:!0,tickColor:o,tickOffset:0,tickRound:!0,tickSize:5,tickWidth:1,titlePadding:4},axisBand:{tickOffset:-.5},projection:{type:"mercator"},legend:{orient:"right",padding:0,gridAlign:"each",columnPadding:10,rowPadding:2,symbolDirection:"vertical",gradientDirection:"vertical",gradientLength:200,gradientThickness:16,gradientStrokeColor:c,gradientStrokeWidth:0,gradientLabelOffset:2,labelAlign:"left",labelBaseline:"middle",labelLimit:160,labelOffset:4,labelOverlap:!0,symbolLimit:30,symbolType:"circle",symbolSize:100,symbolOffset:0,symbolStrokeWidth:1.5,symbolBaseFillColor:"transparent",symbolBaseStrokeColor:o,titleLimit:180,titleOrient:"top",titlePadding:5,layout:{offset:18,direction:"horizontal",left:{direction:"vertical"},right:{direction:"vertical"}}},range:{category:{scheme:"tableau10"},ordinal:{scheme:"blues"},heatmap:{scheme:"yellowgreenblue"},ramp:{scheme:"blues"},diverging:{scheme:"blueorange",extent:[1,0]},symbol:["circle","square","triangle-up","cross","diamond","triangle-right","triangle-down","triangle-left"]}}}function H6e(e,t,n){return ke(e)||ce("Input Vega specification must be an object."),t=Bh(U6e(),t,e.config),R6e(e,new Vq(t,n)).toRuntime()}var z6e="5.24.0";dt(Ku,jfe,x2e,s0e,C0e,z0e,_3e,Y0e,y3e,L3e,I3e,P3e);const $6e=Object.freeze(Object.defineProperty({__proto__:null,Bounds:En,CanvasHandler:G0,CanvasRenderer:Iy,DATE:_s,DAY:gi,DAYOFYEAR:Ha,Dataflow:wu,Debug:Pj,Error:Pb,EventStream:fm,Gradient:HH,GroupItem:wm,HOURS:Rs,Handler:ac,Info:Rj,Item:mm,MILLISECONDS:$r,MINUTES:Ps,MONTH:wi,Marks:Ds,MultiPulse:iT,None:Cj,Operator:Jt,Parameters:dm,Pulse:zl,QUARTER:gs,RenderType:Al,Renderer:eo,ResourceLoader:qT,SECONDS:rr,SVGHandler:lv,SVGRenderer:gv,SVGStringRenderer:_v,Scenegraph:av,TIME_UNITS:Xb,Transform:ae,View:cq,WEEK:Mn,Warn:Db,YEAR:si,accessor:Ls,accessorFields:mi,accessorName:mn,array:Se,ascending:sm,bandwidthNRD:wb,bin:Lb,bootstrapCI:wj,boundClip:Cz,boundContext:z0,boundItem:QL,boundMark:az,boundStroke:el,changeset:gf,clampRange:Yj,codegenExpression:P$,compare:$b,constant:Si,cumulativeLogNormal:xb,cumulativeNormal:Z4,cumulativeUniform:Ib,dayofyear:aU,debounce:qb,defaultLocale:Jb,definition:$U,densityLogNormal:Sb,densityNormal:bb,densityUniform:Fb,domChild:ns,domClear:xr,domCreate:Ol,domFind:ov,dotbin:Lj,error:ce,expressionFunction:xn,extend:dt,extent:Ua,extentIndex:Xj,falsy:pl,fastmap:Ih,field:hs,flush:Kj,font:Em,fontFamily:V0,fontSize:Qa,format:H_,formatLocale:wy,formats:tT,hasOwnProperty:De,id:O0,identity:Ei,inferType:MU,inferTypes:AU,ingest:Dt,inherits:Le,inrange:au,interpolate:RT,interpolateColors:pm,interpolateRange:kH,intersect:Oz,intersectBoxLine:ou,intersectPath:VT,intersectPoint:GT,intersectRule:XH,isArray:ue,isBoolean:Ec,isDate:Hl,isFunction:ft,isIterable:Zj,isNumber:Yt,isObject:ke,isRegExp:Jj,isString:xe,isTuple:lm,key:Vb,lerp:Qj,lineHeight:sc,loader:am,locale:IU,logger:jb,lruCache:eU,markup:hv,merge:tU,mergeConfig:Bh,multiLineOffset:iv,one:kh,pad:nU,panLinear:zj,panLog:$j,panPow:qj,panSymlog:Vj,parse:H6e,parseExpression:nE,parseSelector:xc,path:A4,pathCurves:HT,pathEqual:Rz,pathParse:eh,pathRectangle:qH,pathRender:j2,pathSymbols:$H,pathTrail:VH,peek:kt,point:xm,projection:kv,quantileLogNormal:kb,quantileNormal:J4,quantileUniform:Ob,quantiles:yb,quantizeInterpolator:BH,quarter:Gj,quartiles:mb,get random(){return ir},randomInteger:Ele,randomKDE:vb,randomLCG:vle,randomLogNormal:Tj,randomMixture:vj,randomNormal:Tb,randomUniform:Ej,read:RU,regressionExp:xj,regressionLinear:Mb,regressionLoess:Fj,regressionLog:Sj,regressionPoly:Bj,regressionPow:kj,regressionQuad:Ab,renderModule:km,repeat:C1,resetDefaultLocale:Qce,resetSVGClipId:WH,resetSVGDefIds:q1e,responseType:CU,runtimeContext:K$,sampleCurve:em,sampleLogNormal:Eb,sampleNormal:K4,sampleUniform:Bb,scale:Nt,sceneEqual:pv,sceneFromJSON:lz,scenePickVisit:Ey,sceneToJSON:oz,sceneVisit:qr,sceneZOrder:WT,scheme:PT,serializeXML:vz,setRandom:ble,span:M0,splitAccessPath:Ja,stringValue:Te,textMetrics:Pr,timeBin:vU,timeFloor:hU,timeFormatLocale:R2,timeInterval:Oh,timeOffset:pU,timeSequence:wU,timeUnitSpecifier:rU,timeUnits:Kb,toBoolean:Gb,toDate:Wb,toNumber:_i,toSet:zr,toString:Yb,transform:qU,transforms:Ku,truncate:iU,truthy:sr,tupleid:Re,typeParsers:$L,utcFloor:gU,utcInterval:Mh,utcOffset:yU,utcSequence:LU,utcdayofyear:cU,utcquarter:Wj,utcweek:dU,version:z6e,visitArray:vl,week:oU,writeConfig:Fh,zero:Bl,zoomLinear:Ub,zoomLog:Hb,zoomPow:my,zoomSymlog:zb},Symbol.toStringTag,{value:"Module"}));function q6e(e,t,n){let i;t.x2&&(t.x?(n&&e.x>e.x2&&(i=e.x,e.x=e.x2,e.x2=i),e.width=e.x2-e.x):e.x=e.x2-(e.width||0)),t.xc&&(e.x=e.xc-(e.width||0)/2),t.y2&&(t.y?(n&&e.y>e.y2&&(i=e.y,e.y=e.y2,e.y2=i),e.height=e.y2-e.y):e.y=e.y2-(e.height||0)),t.yc&&(e.y=e.yc-(e.height||0)/2)}var V6e={NaN:NaN,E:Math.E,LN2:Math.LN2,LN10:Math.LN10,LOG2E:Math.LOG2E,LOG10E:Math.LOG10E,PI:Math.PI,SQRT1_2:Math.SQRT1_2,SQRT2:Math.SQRT2,MIN_VALUE:Number.MIN_VALUE,MAX_VALUE:Number.MAX_VALUE},G6e={"*":(e,t)=>e*t,"+":(e,t)=>e+t,"-":(e,t)=>e-t,"/":(e,t)=>e/t,"%":(e,t)=>e%t,">":(e,t)=>e>t,"<":(e,t)=>ee<=t,">=":(e,t)=>e>=t,"==":(e,t)=>e==t,"!=":(e,t)=>e!=t,"===":(e,t)=>e===t,"!==":(e,t)=>e!==t,"&":(e,t)=>e&t,"|":(e,t)=>e|t,"^":(e,t)=>e^t,"<<":(e,t)=>e<>":(e,t)=>e>>t,">>>":(e,t)=>e>>>t},W6e={"+":e=>+e,"-":e=>-e,"~":e=>~e,"!":e=>!e};const Y6e=Array.prototype.slice,Uc=(e,t,n)=>{const i=n?n(t[0]):t[0];return i[e].apply(i,Y6e.call(t,1))},X6e=(e,t,n,i,s,o,c)=>new Date(e,t||0,n??1,i||0,s||0,o||0,c||0);var K6e={isNaN:Number.isNaN,isFinite:Number.isFinite,abs:Math.abs,acos:Math.acos,asin:Math.asin,atan:Math.atan,atan2:Math.atan2,ceil:Math.ceil,cos:Math.cos,exp:Math.exp,floor:Math.floor,log:Math.log,max:Math.max,min:Math.min,pow:Math.pow,random:Math.random,round:Math.round,sin:Math.sin,sqrt:Math.sqrt,tan:Math.tan,clamp:(e,t,n)=>Math.max(t,Math.min(n,e)),now:Date.now,utc:Date.UTC,datetime:X6e,date:e=>new Date(e).getDate(),day:e=>new Date(e).getDay(),year:e=>new Date(e).getFullYear(),month:e=>new Date(e).getMonth(),hours:e=>new Date(e).getHours(),minutes:e=>new Date(e).getMinutes(),seconds:e=>new Date(e).getSeconds(),milliseconds:e=>new Date(e).getMilliseconds(),time:e=>new Date(e).getTime(),timezoneoffset:e=>new Date(e).getTimezoneOffset(),utcdate:e=>new Date(e).getUTCDate(),utcday:e=>new Date(e).getUTCDay(),utcyear:e=>new Date(e).getUTCFullYear(),utcmonth:e=>new Date(e).getUTCMonth(),utchours:e=>new Date(e).getUTCHours(),utcminutes:e=>new Date(e).getUTCMinutes(),utcseconds:e=>new Date(e).getUTCSeconds(),utcmilliseconds:e=>new Date(e).getUTCMilliseconds(),length:e=>e.length,join:function(){return Uc("join",arguments)},indexof:function(){return Uc("indexOf",arguments)},lastindexof:function(){return Uc("lastIndexOf",arguments)},slice:function(){return Uc("slice",arguments)},reverse:e=>e.slice().reverse(),parseFloat,parseInt,upper:e=>String(e).toUpperCase(),lower:e=>String(e).toLowerCase(),substring:function(){return Uc("substring",arguments,String)},split:function(){return Uc("split",arguments,String)},replace:function(){return Uc("replace",arguments,String)},trim:e=>String(e).trim(),regexp:RegExp,test:(e,t)=>RegExp(e).test(t)};const Z6e=["view","item","group","xy","x","y"],J6e={Literal:(e,t)=>t.value,Identifier:(e,t)=>{const n=t.name;return e.memberDepth>0?n:n==="datum"?e.datum:n==="event"?e.event:n==="item"?e.item:V6e[n]||e.params["$"+n]},MemberExpression:(e,t)=>{const n=!t.computed,i=e(t.object);n&&(e.memberDepth+=1);const s=e(t.property);return n&&(e.memberDepth-=1),i[s]},CallExpression:(e,t)=>{const n=t.arguments;let i=t.callee.name;return i.startsWith("_")&&(i=i.slice(1)),i==="if"?e(n[0])?e(n[1]):e(n[2]):(e.fn[i]||K6e[i]).apply(e.fn,n.map(e))},ArrayExpression:(e,t)=>t.elements.map(e),BinaryExpression:(e,t)=>G6e[t.operator](e(t.left),e(t.right)),UnaryExpression:(e,t)=>W6e[t.operator](e(t.argument)),ConditionalExpression:(e,t)=>e(t.test)?e(t.consequent):e(t.alternate),LogicalExpression:(e,t)=>t.operator==="&&"?e(t.left)&&e(t.right):e(t.left)||e(t.right),ObjectExpression:(e,t)=>t.properties.reduce((n,i)=>{e.memberDepth+=1;const s=e(i.key);return e.memberDepth-=1,n[s]=e(i.value),n},{})};function g1(e,t,n,i,s,o){const c=d=>J6e[d.type](c,d);return c.memberDepth=0,c.fn=Object.create(t),c.params=n,c.datum=i,c.event=s,c.item=o,Z6e.forEach(d=>c.fn[d]=(...f)=>s.vega[d](...f)),c(e)}var Q6e={operator(e,t){const n=t.ast,i=e.functions;return s=>g1(n,i,s)},parameter(e,t){const n=t.ast,i=e.functions;return(s,o)=>g1(n,i,o,s)},event(e,t){const n=t.ast,i=e.functions;return s=>g1(n,i,void 0,void 0,s)},handler(e,t){const n=t.ast,i=e.functions;return(s,o)=>{const c=o.item&&o.item.datum;return g1(n,i,s,c,o)}},encode(e,t){const{marktype:n,channels:i}=t,s=e.functions,o=n==="group"||n==="image"||n==="rect";return(c,d)=>{const f=c.datum;let u=0,a;for(const m in i)a=g1(i[m].ast,s,d,f,void 0,c),c[m]!==a&&(c[m]=a,u=1);return n!=="rule"&&q6e(c,i,o),u}}};const ewe="vega-lite",twe='Dominik Moritz, Kanit "Ham" Wongsuphasawat, Arvind Satyanarayan, Jeffrey Heer',nwe="5.6.1",iwe=["Kanit Wongsuphasawat (http://kanitw.yellowpigz.com)","Dominik Moritz (https://www.domoritz.de)","Arvind Satyanarayan (https://arvindsatya.com)","Jeffrey Heer (https://jheer.org)"],swe="https://vega.github.io/vega-lite/",rwe="Vega-Lite is a concise high-level language for interactive visualization.",awe=["vega","chart","visualization"],owe="build/vega-lite.js",lwe="build/vega-lite.min.js",cwe="build/vega-lite.min.js",dwe="build/src/index",fwe="build/src/index.d.ts",uwe={vl2pdf:"./bin/vl2pdf",vl2png:"./bin/vl2png",vl2svg:"./bin/vl2svg",vl2vg:"./bin/vl2vg"},hwe=["bin","build","src","vega-lite*","tsconfig.json"],gwe={changelog:"conventional-changelog -p angular -r 2",prebuild:"yarn clean:build",build:"yarn build:only","build:only":"tsc -p tsconfig.build.json && rollup -c","prebuild:examples":"yarn build:only","build:examples":"yarn data && TZ=America/Los_Angeles scripts/build-examples.sh","prebuild:examples-full":"yarn build:only","build:examples-full":"TZ=America/Los_Angeles scripts/build-examples.sh 1","build:example":"TZ=America/Los_Angeles scripts/build-example.sh","build:toc":"yarn build:jekyll && scripts/generate-toc","build:site":"rollup -c site/rollup.config.mjs","build:jekyll":"pushd site && bundle exec jekyll build -q && popd","build:versions":"scripts/update-version.sh",clean:"yarn clean:build && del-cli 'site/data/*' 'examples/compiled/*.png' && find site/examples ! -name 'index.md' ! -name 'data' -type f -delete","clean:build":"del-cli 'build/*' !build/vega-lite-schema.json","predeploy:site":"yarn presite","deploy:site":"gh-pages -d site",data:"rsync -r node_modules/vega-datasets/data/* site/data",schema:"mkdir -p build && ts-json-schema-generator -f tsconfig.json -p src/index.ts -t TopLevelSpec --no-type-check --no-ref-encode > build/vega-lite-schema.json && yarn renameschema && cp build/vega-lite-schema.json site/_data/",renameschema:"scripts/rename-schema.sh",presite:"yarn data && yarn schema && yarn build:site && yarn build:versions && scripts/create-example-pages.sh",site:"yarn site:only","site:only":"pushd site && bundle exec jekyll serve -I -l && popd",prettierbase:"prettier '**/*.{md,css,yml}'",eslintbase:"eslint .",format:"yarn eslintbase --fix && yarn prettierbase --write",lint:"yarn eslintbase && yarn prettierbase --check",jest:"NODE_OPTIONS=--experimental-vm-modules npx jest",test:"yarn jest test/ && yarn lint && yarn schema && yarn jest examples/ && yarn test:runtime","test:cover":"yarn jest --collectCoverage test/","test:inspect":"node --inspect-brk --experimental-vm-modules ./node_modules/.bin/jest --runInBand test","test:runtime":"NODE_OPTIONS=--experimental-vm-modules TZ=America/Los_Angeles npx jest test-runtime/ --config test-runtime/jest-config.json","test:runtime:generate":"yarn build:only && del-cli test-runtime/resources && VL_GENERATE_TESTS=true yarn test:runtime",watch:"tsc -p tsconfig.build.json -w","watch:site":"yarn build:site -w","watch:test":"yarn jest --watch test/","watch:test:runtime":"NODE_OPTIONS=--experimental-vm-modules TZ=America/Los_Angeles npx jest --watch test-runtime/ --config test-runtime/jest-config.json",release:"yarn release-it"},_we={type:"git",url:"https://github.com/vega/vega-lite.git"},pwe="BSD-3-Clause",ywe={url:"https://github.com/vega/vega-lite/issues"},mwe={"@babel/core":"^7.20.12","@babel/preset-env":"^7.20.2","@babel/preset-typescript":"^7.18.6","@release-it/conventional-changelog":"^5.1.1","@rollup/plugin-alias":"^4.0.3","@rollup/plugin-babel":"^6.0.3","@rollup/plugin-commonjs":"^24.0.1","@rollup/plugin-json":"^6.0.0","@rollup/plugin-node-resolve":"^15.0.1","@rollup/plugin-terser":"^0.4.0","@types/chai":"^4.3.4","@types/d3":"^7.4.0","@types/jest":"^27.4.1","@types/mkdirp":"^1.0.2","@types/pako":"^2.0.0","@typescript-eslint/eslint-plugin":"^5.52.0","@typescript-eslint/parser":"^5.52.0","ajv-formats":"^2.1.1",ajv:"^8.12.0",chai:"^4.3.7",cheerio:"^1.0.0-rc.12","conventional-changelog-cli":"^2.2.2",d3:"^7.8.2","del-cli":"^5.0.0","eslint-config-prettier":"^8.6.0","eslint-plugin-jest":"^27.2.1","eslint-plugin-prettier":"^4.2.1",eslint:"^8.34.0","gh-pages":"^5.0.0","highlight.js":"^11.7.0","jest-dev-server":"^6.1.1",jest:"^27.5.1",mkdirp:"^2.1.3",pako:"^2.1.0",prettier:"^2.8.4",puppeteer:"^15.0.0","release-it":"^15.6.0","rollup-plugin-bundle-size":"^1.0.3","rollup-plugin-sourcemaps":"^0.6.3",rollup:"^3.15.0",serve:"^14.2.0",terser:"^5.16.3","ts-jest":"^29.0.5","ts-json-schema-generator":"^1.2.0",typescript:"~4.9.5","vega-cli":"^5.22.1","vega-datasets":"~2.5.4","vega-embed":"^6.21.2","vega-tooltip":"^0.30.1","yaml-front-matter":"^4.1.1"},wwe={"@types/clone":"~2.1.1",clone:"~2.1.2","fast-deep-equal":"~3.1.3","fast-json-stable-stringify":"~2.1.0","json-stringify-pretty-compact":"~3.0.0",tslib:"~2.5.0","vega-event-selector":"~3.0.0","vega-expression":"~5.0.0","vega-util":"~1.17.0",yargs:"~17.6.2"},Lwe={vega:"^5.22.0"},bwe={node:">=12"},Twe={name:ewe,author:twe,version:nwe,collaborators:iwe,homepage:swe,description:rwe,keywords:awe,main:owe,unpkg:lwe,jsdelivr:cwe,module:dwe,types:fwe,bin:uwe,files:hwe,scripts:gwe,repository:_we,license:pwe,bugs:ywe,devDependencies:mwe,dependencies:wwe,peerDependencies:Lwe,engines:bwe};var A8={},vwe={get exports(){return A8},set exports(e){A8=e}};(function(e){var t=function(){function n(y,p){return p!=null&&y instanceof p}var i;try{i=Map}catch{i=function(){}}var s;try{s=Set}catch{s=function(){}}var o;try{o=Promise}catch{o=function(){}}function c(y,p,l,b,L){typeof p=="object"&&(l=p.depth,b=p.prototype,L=p.includeNonEnumerable,p=p.circular);var E=[],S=[],x=typeof Buffer<"u";typeof p>"u"&&(p=!0),typeof l>"u"&&(l=1/0);function F(k,M){if(k===null)return null;if(M===0)return k;var O,C;if(typeof k!="object")return k;if(n(k,i))O=new i;else if(n(k,s))O=new s;else if(n(k,o))O=new o(function(X,G){k.then(function(oe){X(F(oe,M-1))},function(oe){G(F(oe,M-1))})});else if(c.__isArray(k))O=[];else if(c.__isRegExp(k))O=new RegExp(k.source,m(k)),k.lastIndex&&(O.lastIndex=k.lastIndex);else if(c.__isDate(k))O=new Date(k.getTime());else{if(x&&Buffer.isBuffer(k))return Buffer.allocUnsafe?O=Buffer.allocUnsafe(k.length):O=new Buffer(k.length),k.copy(O),O;n(k,Error)?O=Object.create(k):typeof b>"u"?(C=Object.getPrototypeOf(k),O=Object.create(C)):(O=Object.create(b),C=b)}if(p){var P=E.indexOf(k);if(P!=-1)return S[P];E.push(k),S.push(O)}n(k,i)&&k.forEach(function(X,G){var oe=F(G,M-1),he=F(X,M-1);O.set(oe,he)}),n(k,s)&&k.forEach(function(X){var G=F(X,M-1);O.add(G)});for(var j in k){var R;C&&(R=Object.getOwnPropertyDescriptor(C,j)),!(R&&R.set==null)&&(O[j]=F(k[j],M-1))}if(Object.getOwnPropertySymbols)for(var H=Object.getOwnPropertySymbols(k),j=0;jbu(n,t))}:ME(e)?{or:e.or.map(n=>bu(n,t))}:t(e)}const ba=IE,at=Ewe;function Gq(e){throw new Error(e)}function ah(e,t){const n={};for(const i of t)De(e,i)&&(n[i]=e[i]);return n}function as(e,t){const n=Object.assign({},e);for(const i of t)delete n[i];return n}Set.prototype.toJSON=function(){return`Set(${[...this].map(e=>OE(e)).join(",")})`};const tn=OE;function Bt(e){if(Yt(e))return e;const t=xe(e)?e:OE(e);if(t.length<250)return t;let n=0;for(let i=0;id===0?c:`[${c}]`),o=s.map((c,d)=>s.slice(0,d+1).join(""));for(const c of o)t.add(c)}return t}function PE(e,t){return e===void 0||t===void 0?!0:RE(C8(e),C8(t))}function Wt(e){return ye(e).length===0}const ye=Object.keys,Ti=Object.values,cc=Object.entries;function Z2(e){return e===!0||e===!1}function dn(e){const t=e.replace(/\W/g,"_");return(e.match(/^\d+/)?"_":"")+t}function c2(e,t){return NE(e)?`!(${c2(e.not,t)})`:AE(e)?`(${e.and.map(n=>c2(n,t)).join(") && (")})`:ME(e)?`(${e.or.map(n=>c2(n,t)).join(") || (")})`:t(e)}function $y(e,t){if(t.length===0)return!0;const n=t.shift();return n in e&&$y(e[n],t)&&delete e[n],Wt(e)}function Q0(e){return e.charAt(0).toUpperCase()+e.substr(1)}function DE(e,t="datum"){const n=Ja(e),i=[];for(let s=1;s<=n.length;s++){const o=`[${n.slice(0,s).map(Te).join("][")}]`;i.push(`${t}${o}`)}return i.join(" && ")}function Xq(e,t="datum"){return`${t}[${Te(Ja(e).join("."))}]`}function kwe(e){return e.replace(/(\[|\]|\.|'|")/g,"\\$1")}function ar(e){return`${Ja(e).map(kwe).join("\\.")}`}function Wd(e,t,n){return e.replace(new RegExp(t.replace(/[-/\\^$*+?.()|[\]{}]/g,"\\$&"),"g"),n)}function jE(e){return`${Ja(e).join(".")}`}function oh(e){return e?Ja(e).length:0}function Sn(...e){for(const t of e)if(t!==void 0)return t}let Kq=42;function Zq(e){const t=++Kq;return e?String(e)+t:t}function Bwe(){Kq=42}function Jq(e){return Qq(e)?e:`__${e}`}function Qq(e){return e.startsWith("__")}function J2(e){if(e!==void 0)return(e%360+360)%360}function Vm(e){return Yt(e)?!0:!isNaN(e)&&!isNaN(parseFloat(e))}var e3=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sQm(e[t])?dn(`_${t}_${cc(e[t])}`):dn(`_${t}_${e[t]}`)).join("")}function nn(e){return e===!0||bf(e)&&!e.binned}function ei(e){return e==="binned"||bf(e)&&e.binned===!0}function bf(e){return ke(e)}function Qm(e){return e==null?void 0:e.param}function JO(e){switch(e){case Po:case Do:case rl:case ps:case ro:case ao:case Ic:case al:case Bc:case Fc:case ys:return 6;case Oc:return 4;default:return 10}}function s3(e){return!!(e!=null&&e.expr)}function es(e){const t=ye(e||{}),n={};for(const i of t)n[i]=Is(e[i]);return n}var e5e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{var s;return n.field.push(ve(i,t)),n.order.push((s=i.sort)!==null&&s!==void 0?s:"ascending"),n},{field:[],order:[]})}function mV(e,t){const n=[...e];return t.forEach(i=>{for(const s of n)if(ba(s,i))return;n.push(i)}),n}function wV(e,t){return ba(e,t)||!t?e:e?[...Se(e),...Se(t)].join(", "):t}function LV(e,t){const n=e.value,i=t.value;if(n==null||i===null)return{explicit:e.explicit,value:null};if((xl(n)||Ne(n))&&(xl(i)||Ne(i)))return{explicit:e.explicit,value:wV(n,i)};if(xl(n)||Ne(n))return{explicit:e.explicit,value:n};if(xl(i)||Ne(i))return{explicit:e.explicit,value:i};if(!xl(n)&&!Ne(n)&&!xl(i)&&!Ne(i))return{explicit:e.explicit,value:mV(n,i)};throw new Error("It should never reach here")}function YE(e){return`Invalid specification ${tn(e)}. Make sure the specification includes at least one of the following properties: "mark", "layer", "facet", "hconcat", "vconcat", "concat", or "repeat".`}const l5e='Autosize "fit" only works for single views and layered views.';function tM(e){return`${e=="width"?"Width":"Height"} "container" only works for single views and layered views.`}function nM(e){const t=e=="width"?"Width":"Height",n=e=="width"?"x":"y";return`${t} "container" only works well with autosize "fit" or "fit-${n}".`}function iM(e){return e?`Dropping "fit-${e}" because spec has discrete ${ms(e)}.`:'Dropping "fit" because spec has discrete size.'}function XE(e){return`Unknown field for ${e}. Cannot calculate view size.`}function sM(e){return`Cannot project a selection on encoding channel "${e}", which has no field.`}function c5e(e,t){return`Cannot project a selection on encoding channel "${e}" as it uses an aggregate function ("${t}").`}function d5e(e){return`The "nearest" transform is not supported for ${e} marks.`}function bV(e){return`Selection not supported for ${e} yet.`}function f5e(e){return`Cannot find a selection named "${e}".`}const u5e="Scale bindings are currently only supported for scales with unbinned, continuous domains.",h5e="Legend bindings are only supported for selections over an individual field or encoding channel.";function g5e(e){return`Lookups can only be performed on selection parameters. "${e}" is a variable parameter.`}function _5e(e){return`Cannot define and lookup the "${e}" selection in the same view. Try moving the lookup into a second, layered view?`}const p5e="The same selection must be used to override scale domains in a layered view.",y5e='Interval selections should be initialized using "x" and/or "y" keys.';function m5e(e){return`Unknown repeated value "${e}".`}function rM(e){return`The "columns" property cannot be used when "${e}" has nested row/column.`}const w5e="Axes cannot be shared in concatenated or repeated views yet (https://github.com/vega/vega-lite/issues/2415).";function L5e(e){return`Unrecognized parse "${e}".`}function aM(e,t,n){return`An ancestor parsed field "${e}" as ${n} but a child wants to parse the field as ${t}.`}const b5e="Attempt to add the same child twice.";function T5e(e){return`Ignoring an invalid transform: ${tn(e)}.`}const v5e='If "from.fields" is not specified, "as" has to be a string that specifies the key to be used for the data from the secondary source.';function oM(e){return`Config.customFormatTypes is not true, thus custom format type and format for channel ${e} are dropped.`}function E5e(e){const{parentProjection:t,projection:n}=e;return`Layer's shared projection ${tn(t)} is overridden by a child projection ${tn(n)}.`}const S5e="Arc marks uses theta channel rather than angle, replacing angle with theta.";function x5e(e){return`${e}Offset dropped because ${e} is continuous`}function k5e(e){return`There is no ${e} encoding. Replacing ${e}Offset encoding as ${e}.`}function B5e(e,t,n){return`Channel ${e} is a ${t}. Converted to {value: ${tn(n)}}.`}function TV(e){return`Invalid field type "${e}".`}function F5e(e,t){return`Invalid field type "${e}" for aggregate: "${t}", using "quantitative" instead.`}function I5e(e){return`Invalid aggregation operator "${e}".`}function vV(e,t){const{fill:n,stroke:i}=t;return`Dropping color ${e} as the plot also has ${n&&i?"fill and stroke":n?"fill":"stroke"}.`}function O5e(e){return`Position range does not support relative band size for ${e}.`}function P8(e,t){return`Dropping ${tn(e)} from channel "${t}" since it does not contain any data field, datum, value, or signal.`}const M5e="Line marks cannot encode size with a non-groupby field. You may want to use trail marks instead.";function e6(e,t,n){return`${e} dropped as it is incompatible with "${t}"${n?` when ${n}`:""}.`}function A5e(e){return`${e} encoding has no scale, so specified scale is ignored.`}function N5e(e){return`${e}-encoding is dropped as ${e} is not a valid encoding channel.`}function C5e(e){return`${e} encoding should be discrete (ordinal / nominal / binned).`}function R5e(e){return`${e} encoding should be discrete (ordinal / nominal / binned) or use a discretizing scale (e.g. threshold).`}function P5e(e){return`Facet encoding dropped as ${e.join(" and ")} ${e.length>1?"are":"is"} also specified.`}function r5(e,t){return`Using discrete channel "${e}" to encode "${t}" field can be misleading as it does not encode ${t==="ordinal"?"order":"magnitude"}.`}function D5e(e){return`The ${e} for range marks cannot be an expression`}function j5e(e,t){return`Line mark is for continuous lines and thus cannot be used with ${e&&t?"x2 and y2":e?"x2":"y2"}. We will use the rule mark (line segments) instead.`}function U5e(e,t){return`Specified orient "${e}" overridden with "${t}".`}function H5e(e){return`Cannot use the scale property "${e}" with non-color channel.`}function z5e(e){return`Cannot use the relative band size with ${e} scale.`}function $5e(e){return`Using unaggregated domain with raw field has no effect (${tn(e)}).`}function q5e(e){return`Unaggregated domain not applicable for "${e}" since it produces values outside the origin domain of the source data.`}function V5e(e){return`Unaggregated domain is currently unsupported for log scale (${tn(e)}).`}function G5e(e){return`Cannot apply size to non-oriented mark "${e}".`}function W5e(e,t,n){return`Channel "${e}" does not work with "${t}" scale. We are using "${n}" scale instead.`}function Y5e(e,t){return`FieldDef does not work with "${e}" scale. We are using "${t}" scale instead.`}function EV(e,t,n){return`${n}-scale's "${t}" is dropped as it does not work with ${e} scale.`}function SV(e){return`The step for "${e}" is dropped because the ${e==="width"?"x":"y"} is continuous.`}function X5e(e,t,n,i){return`Conflicting ${t.toString()} property "${e.toString()}" (${tn(n)} and ${tn(i)}). Using ${tn(n)}.`}function K5e(e,t,n,i){return`Conflicting ${t.toString()} property "${e.toString()}" (${tn(n)} and ${tn(i)}). Using the union of the two domains.`}function Z5e(e){return`Setting the scale to be independent for "${e}" means we also have to set the guide (axis or legend) to be independent.`}function J5e(e){return`Dropping sort property ${tn(e)} as unioned domains only support boolean or op "count", "min", and "max".`}const lM="Domains that should be unioned has conflicting sort properties. Sort will be set to true.",Q5e="Detected faceted independent scales that union domain of multiple fields from different data sources. We will use the first field. The result view size may be incorrect.",eLe="Detected faceted independent scales that union domain of the same fields from different source. We will assume that this is the same field from a different fork of the same data source. However, if this is not the case, the result view size may be incorrect.",tLe="Detected faceted independent scales that union domain of multiple fields from the same data source. We will use the first field. The result view size may be incorrect.";function nLe(e){return`Cannot stack "${e}" if there is already "${e}2".`}function iLe(e){return`Cannot stack non-linear scale (${e}).`}function sLe(e){return`Stacking is applied even though the aggregate function is non-summative ("${e}").`}function Vy(e,t){return`Invalid ${e}: ${tn(t)}.`}function rLe(e){return`Dropping day from datetime ${tn(e)} as day cannot be combined with other units.`}function aLe(e,t){return`${t?"extent ":""}${t&&e?"and ":""}${e?"center ":""}${t&&e?"are ":"is "}not needed when data are aggregated.`}function oLe(e,t,n){return`${e} is not usually used with ${t} for ${n}.`}function lLe(e,t){return`Continuous axis should not have customized aggregation function ${e}; ${t} already agregates the axis.`}function cM(e){return`1D error band does not support ${e}.`}function xV(e){return`Channel ${e} is required for "binned" bin.`}function cLe(e){return`Channel ${e} should not be used with "binned" bin.`}function dLe(e){return`Domain for ${e} is required for threshold scale.`}globalThis&&globalThis.__classPrivateFieldSet;globalThis&&globalThis.__classPrivateFieldGet;const kV=jb(Db);let lh=kV;function fLe(e){return lh=e,lh}function uLe(){return lh=kV,lh}function me(...e){lh.warn(...e)}function hLe(...e){lh.debug(...e)}function Tf(e){if(e&&ke(e)){for(const t of ZE)if(t in e)return!0}return!1}const BV=["january","february","march","april","may","june","july","august","september","october","november","december"],gLe=BV.map(e=>e.substr(0,3)),FV=["sunday","monday","tuesday","wednesday","thursday","friday","saturday"],_Le=FV.map(e=>e.substr(0,3));function pLe(e){if(Vm(e)&&(e=+e),Yt(e))return e>4&&me(Vy("quarter",e)),e-1;throw new Error(Vy("quarter",e))}function yLe(e){if(Vm(e)&&(e=+e),Yt(e))return e-1;{const t=e.toLowerCase(),n=BV.indexOf(t);if(n!==-1)return n;const i=t.substr(0,3),s=gLe.indexOf(i);if(s!==-1)return s;throw new Error(Vy("month",e))}}function mLe(e){if(Vm(e)&&(e=+e),Yt(e))return e%7;{const t=e.toLowerCase(),n=FV.indexOf(t);if(n!==-1)return n;const i=t.substr(0,3),s=_Le.indexOf(i);if(s!==-1)return s;throw new Error(Vy("day",e))}}function KE(e,t){const n=[];if(t&&e.day!==void 0&&ye(e).length>1&&(me(rLe(e)),e=at(e),delete e.day),e.year!==void 0?n.push(e.year):n.push(2012),e.month!==void 0){const i=t?yLe(e.month):e.month;n.push(i)}else if(e.quarter!==void 0){const i=t?pLe(e.quarter):e.quarter;n.push(Yt(i)?i*3:`${i}*3`)}else n.push(0);if(e.date!==void 0)n.push(e.date);else if(e.day!==void 0){const i=t?mLe(e.day):e.day;n.push(Yt(i)?i+1:`${i}+1`)}else n.push(1);for(const i of["hours","minutes","seconds","milliseconds"]){const s=e[i];n.push(typeof s>"u"?0:s)}return n}function Q2(e){const n=KE(e,!0).join(", ");return e.utc?`utc(${n})`:`datetime(${n})`}function wLe(e){const n=KE(e,!1).join(", ");return e.utc?`utc(${n})`:`datetime(${n})`}function LLe(e){const t=KE(e,!0);return e.utc?+new Date(Date.UTC(...t)):+new Date(...t)}var bLe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sOV(e,t))}function OV(e,t){const n=e.indexOf(t);return!(n<0||n>0&&t==="seconds"&&e.charAt(n-1)==="i"||e.length>n+3&&t==="day"&&e.charAt(n+3)==="o"||n>0&&t==="year"&&e.charAt(n-1)==="f")}function SLe(e,t,{end:n}={end:!1}){const i=DE(t),s=JE(e)?"utc":"";function o(f){return f==="quarter"?`(${s}quarter(${i})-1)`:`${s}${f}(${i})`}let c;const d={};for(const f of ZE)OV(e,f)&&(d[f]=o(f),c=f);return n&&(d[c]+="+1"),wLe(d)}function MV(e){if(!e)return;const t=QE(e);return`timeUnitSpecifier(${tn(t)}, ${tn(ELe)})`}function xLe(e,t,n){if(!e)return;const i=MV(e);return`${n||JE(e)?"utc":"time"}Format(${t}, ${i})`}function xi(e){if(!e)return;let t;return xe(e)?t={unit:e}:ke(e)&&(t=Object.assign(Object.assign({},e),e.unit?{unit:e.unit}:{})),JE(t.unit)&&(t.utc=!0,t.unit=vLe(t.unit)),t}function kLe(e){const t=xi(e),{utc:n}=t,i=bLe(t,["utc"]);return i.unit?(n?"utc":"")+ye(i).map(s=>dn(`${s==="unit"?"":`_${s}_`}${i[s]}`)).join(""):(n?"utc":"")+"timeunit"+ye(i).map(s=>dn(`_${s}_${i[s]}`)).join("")}function BLe(e){return e==null?void 0:e.param}function eS(e){return!!(e!=null&&e.field)&&e.equal!==void 0}function tS(e){return!!(e!=null&&e.field)&&e.lt!==void 0}function nS(e){return!!(e!=null&&e.field)&&e.lte!==void 0}function iS(e){return!!(e!=null&&e.field)&&e.gt!==void 0}function sS(e){return!!(e!=null&&e.field)&&e.gte!==void 0}function rS(e){if(e!=null&&e.field){if(ue(e.range)&&e.range.length===2)return!0;if(Ne(e.range))return!0}return!1}function aS(e){return!!(e!=null&&e.field)&&(ue(e.oneOf)||ue(e.in))}function FLe(e){return!!(e!=null&&e.field)&&e.valid!==void 0}function AV(e){return aS(e)||eS(e)||rS(e)||tS(e)||iS(e)||nS(e)||sS(e)}function sa(e,t){return d6(e,{timeUnit:t,wrapTime:!0})}function ILe(e,t){return e.map(n=>sa(n,t))}function NV(e,t=!0){var n;const{field:i}=e,s=(n=xi(e.timeUnit))===null||n===void 0?void 0:n.unit,o=s?`time(${SLe(s,i)})`:ve(e,{expr:"datum"});if(eS(e))return`${o}===${sa(e.equal,s)}`;if(tS(e)){const c=e.lt;return`${o}<${sa(c,s)}`}else if(iS(e)){const c=e.gt;return`${o}>${sa(c,s)}`}else if(nS(e)){const c=e.lte;return`${o}<=${sa(c,s)}`}else if(sS(e)){const c=e.gte;return`${o}>=${sa(c,s)}`}else{if(aS(e))return`indexof([${ILe(e.oneOf,s).join(",")}], ${o}) !== -1`;if(FLe(e))return oS(o,e.valid);if(rS(e)){const{range:c}=e,d=Ne(c)?{signal:`${c.signal}[0]`}:c[0],f=Ne(c)?{signal:`${c.signal}[1]`}:c[1];if(d!==null&&f!==null&&t)return"inrange("+o+", ["+sa(d,s)+", "+sa(f,s)+"])";const u=[];return d!==null&&u.push(`${o} >= ${sa(d,s)}`),f!==null&&u.push(`${o} <= ${sa(f,s)}`),u.length>0?u.join(" && "):"true"}}throw new Error(`Invalid field predicate: ${tn(e)}`)}function oS(e,t=!0){return t?`isValid(${e}) && isFinite(+${e})`:`!isValid(${e}) || !isFinite(+${e})`}function OLe(e){var t;return AV(e)&&e.timeUnit?Object.assign(Object.assign({},e),{timeUnit:(t=xi(e.timeUnit))===null||t===void 0?void 0:t.unit}):e}const r3={quantitative:"quantitative",ordinal:"ordinal",temporal:"temporal",nominal:"nominal",geojson:"geojson"};function MLe(e){return e==="quantitative"||e==="temporal"}function CV(e){return e==="ordinal"||e==="nominal"}const Kd=r3.quantitative,lS=r3.ordinal,ch=r3.temporal,cS=r3.nominal,Uh=r3.geojson;function ALe(e){if(e)switch(e=e.toLowerCase(),e){case"q":case Kd:return"quantitative";case"t":case ch:return"temporal";case"o":case lS:return"ordinal";case"n":case cS:return"nominal";case Uh:return"geojson"}}var NLe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{switch(t.fieldTitle){case"plain":return e.field;case"functional":return S8e(e);default:return E8e(e,t)}};let oG=aG;function lG(e){oG=e}function x8e(){lG(aG)}function vu(e,t,{allowDisabling:n,includeDefault:i=!0}){var s,o;const c=(s=wS(e))===null||s===void 0?void 0:s.title;if(!we(e))return c??e.title;const d=e,f=i?LS(d,t):void 0;return n?Sn(c,d.title,f):(o=c??d.title)!==null&&o!==void 0?o:f}function wS(e){if(uh(e)&&e.axis)return e.axis;if(sG(e)&&e.legend)return e.legend;if(yS(e)&&e.header)return e.header}function LS(e,t){return oG(e,t)}function Xy(e){var t;if(rG(e)){const{format:n,formatType:i}=e;return{format:n,formatType:i}}else{const n=(t=wS(e))!==null&&t!==void 0?t:{},{format:i,formatType:s}=n;return{format:i,formatType:s}}}function k8e(e,t){var n;switch(t){case"latitude":case"longitude":return"quantitative";case"row":case"column":case"facet":case"shape":case"strokeDash":return"nominal";case"order":return"ordinal"}if(mS(e)&&ue(e.sort))return"ordinal";const{aggregate:i,bin:s,timeUnit:o}=e;if(o)return"temporal";if(s||i&&!Ac(i)&&!Yo(i))return"quantitative";if(vf(e)&&(!((n=e.scale)===null||n===void 0)&&n.type))switch(D8[e.scale.type]){case"numeric":case"discretizing":return"quantitative";case"time":return"temporal"}return"nominal"}function qa(e){if(we(e))return e;if(l6(e))return e.condition}function An(e){if(Je(e))return e;if(l3(e))return e.condition}function cG(e,t,n,i={}){if(xe(e)||Yt(e)||Ec(e)){const s=xe(e)?"string":Yt(e)?"number":"boolean";return me(B5e(t,s,e)),{value:e}}return Je(e)?Ky(e,t,n,i):l3(e)?Object.assign(Object.assign({},e),{condition:Ky(e.condition,t,n,i)}):e}function Ky(e,t,n,i){if(rG(e)){const{format:s,formatType:o}=e,c=H8(e,["format","formatType"]);if(Jd(o)&&!n.customFormatTypes)return me(oM(t)),Ky(c,t,n,i)}else{const s=uh(e)?"axis":sG(e)?"legend":yS(e)?"header":null;if(s&&e[s]){const o=e[s],{format:c,formatType:d}=o,f=H8(o,["format","formatType"]);if(Jd(d)&&!n.customFormatTypes)return me(oM(t)),Ky(Object.assign(Object.assign({},e),{[s]:f}),t,n,i)}}return we(e)?bS(e,t,i):B8e(e)}function B8e(e){let t=e.type;if(t)return e;const{datum:n}=e;return t=Yt(n)?"quantitative":xe(n)?"nominal":Tf(n)?"temporal":void 0,Object.assign(Object.assign({},e),{type:t})}function bS(e,t,{compositeMark:n=!1}={}){const{aggregate:i,timeUnit:s,bin:o,field:c}=e,d=Object.assign({},e);if(!n&&i&&!GE(i)&&!Ac(i)&&!Yo(i)&&(me(I5e(i)),delete d.aggregate),s&&(d.timeUnit=xi(s)),c&&(d.field=`${c}`),nn(o)&&(d.bin=c6(o,t)),ei(o)&&!Zn(t)&&me(cLe(t)),lr(d)){const{type:f}=d,u=ALe(f);f!==u&&(d.type=u),f!=="quantitative"&&fV(i)&&(me(F5e(f,i)),d.type="quantitative")}else if(!sV(t)){const f=k8e(d,t);d.type=f}if(lr(d)){const{compatible:f,warning:u}=F8e(d,t)||{};f===!1&&me(u)}if(mS(d)&&xe(d.sort)){const{sort:f}=d;if(hM(f))return Object.assign(Object.assign({},d),{sort:{encoding:f}});const u=f.substr(1);if(f.charAt(0)==="-"&&hM(u))return Object.assign(Object.assign({},d),{sort:{encoding:u,order:"descending"}})}if(yS(d)){const{header:f}=d;if(f){const{orient:u}=f,a=H8(f,["orient"]);if(u)return Object.assign(Object.assign({},d),{header:Object.assign(Object.assign({},a),{labelOrient:f.labelOrient||u,titleOrient:f.titleOrient||u})})}}return d}function c6(e,t){return Ec(e)?{maxbins:JO(t)}:e==="binned"?{binned:!0}:!e.maxbins&&!e.step?Object.assign(Object.assign({},e),{maxbins:JO(t)}):e}const Pf={compatible:!0};function F8e(e,t){const n=e.type;if(n==="geojson"&&t!=="shape")return{compatible:!1,warning:`Channel ${t} should not be used with a geojson data.`};switch(t){case Po:case Do:case Gm:return Yy(e)?Pf:{compatible:!1,warning:C5e(t)};case hn:case Kn:case kc:case Dh:case ps:case ro:case ao:case t3:case i3:case Wm:case Yd:case Ym:case Xm:case wf:case dr:case Qr:case Km:return Pf;case so:case or:case io:case ea:return n!==Kd?{compatible:!1,warning:`Channel ${t} should be used with a quantitative field only, not ${e.type} field.`}:Pf;case al:case Bc:case Fc:case Ic:case rl:case sl:case il:case Jr:case no:return n==="nominal"&&!e.sort?{compatible:!1,warning:`Channel ${t} should not be used with an unsorted discrete field.`}:Pf;case ys:case Oc:return!Yy(e)&&!T8e(e)?{compatible:!1,warning:R5e(t)}:Pf;case n3:return e.type==="nominal"&&!("sort"in e)?{compatible:!1,warning:"Channel order is inappropriate for nominal field, which has no inherent order."}:Pf}}function hh(e){const{formatType:t}=Xy(e);return t==="time"||!t&&I8e(e)}function I8e(e){return e&&(e.type==="temporal"||we(e)&&!!e.timeUnit)}function d6(e,{timeUnit:t,type:n,wrapTime:i,undefinedIfExprNotRequired:s}){var o;const c=t&&((o=xi(t))===null||o===void 0?void 0:o.unit);let d=c||n==="temporal",f;return s3(e)?f=e.expr:Ne(e)?f=e.signal:Tf(e)?(d=!0,f=Q2(e)):(xe(e)||Yt(e))&&d&&(f=`datetime(${tn(e)})`,TLe(c)&&(Yt(e)&&e<1e4||xe(e)&&isNaN(Date.parse(e)))&&(f=Q2({[c]:e}))),f?i&&d?`time(${f})`:f:s?void 0:tn(e)}function dG(e,t){const{type:n}=e;return t.map(i=>{const s=d6(i,{timeUnit:we(e)?e.timeUnit:void 0,type:n,undefinedIfExprNotRequired:!0});return s!==void 0?{signal:s}:i})}function c3(e,t){return nn(e.bin)?Mc(t)&&["ordinal","nominal"].includes(e.type):(console.warn("Only call this method for binned field defs."),!1)}const _M={labelAlign:{part:"labels",vgProp:"align"},labelBaseline:{part:"labels",vgProp:"baseline"},labelColor:{part:"labels",vgProp:"fill"},labelFont:{part:"labels",vgProp:"font"},labelFontSize:{part:"labels",vgProp:"fontSize"},labelFontStyle:{part:"labels",vgProp:"fontStyle"},labelFontWeight:{part:"labels",vgProp:"fontWeight"},labelOpacity:{part:"labels",vgProp:"opacity"},labelOffset:null,labelPadding:null,gridColor:{part:"grid",vgProp:"stroke"},gridDash:{part:"grid",vgProp:"strokeDash"},gridDashOffset:{part:"grid",vgProp:"strokeDashOffset"},gridOpacity:{part:"grid",vgProp:"opacity"},gridWidth:{part:"grid",vgProp:"strokeWidth"},tickColor:{part:"ticks",vgProp:"stroke"},tickDash:{part:"ticks",vgProp:"strokeDash"},tickDashOffset:{part:"ticks",vgProp:"strokeDashOffset"},tickOpacity:{part:"ticks",vgProp:"opacity"},tickSize:null,tickWidth:{part:"ticks",vgProp:"strokeWidth"}};function d3(e){return e==null?void 0:e.condition}const fG=["domain","grid","labels","ticks","title"],O8e={grid:"grid",gridCap:"grid",gridColor:"grid",gridDash:"grid",gridDashOffset:"grid",gridOpacity:"grid",gridScale:"grid",gridWidth:"grid",orient:"main",bandPosition:"both",aria:"main",description:"main",domain:"main",domainCap:"main",domainColor:"main",domainDash:"main",domainDashOffset:"main",domainOpacity:"main",domainWidth:"main",format:"main",formatType:"main",labelAlign:"main",labelAngle:"main",labelBaseline:"main",labelBound:"main",labelColor:"main",labelFlush:"main",labelFlushOffset:"main",labelFont:"main",labelFontSize:"main",labelFontStyle:"main",labelFontWeight:"main",labelLimit:"main",labelLineHeight:"main",labelOffset:"main",labelOpacity:"main",labelOverlap:"main",labelPadding:"main",labels:"main",labelSeparation:"main",maxExtent:"main",minExtent:"main",offset:"both",position:"main",tickCap:"main",tickColor:"main",tickDash:"main",tickDashOffset:"main",tickMinStep:"both",tickOffset:"both",tickOpacity:"main",tickRound:"both",ticks:"main",tickSize:"main",tickWidth:"both",title:"main",titleAlign:"main",titleAnchor:"main",titleAngle:"main",titleBaseline:"main",titleColor:"main",titleFont:"main",titleFontSize:"main",titleFontStyle:"main",titleFontWeight:"main",titleLimit:"main",titleLineHeight:"main",titleOpacity:"main",titlePadding:"main",titleX:"main",titleY:"main",encode:"both",scale:"both",tickBand:"both",tickCount:"both",tickExtra:"both",translate:"both",values:"both",zindex:"both"},uG={orient:1,aria:1,bandPosition:1,description:1,domain:1,domainCap:1,domainColor:1,domainDash:1,domainDashOffset:1,domainOpacity:1,domainWidth:1,format:1,formatType:1,grid:1,gridCap:1,gridColor:1,gridDash:1,gridDashOffset:1,gridOpacity:1,gridWidth:1,labelAlign:1,labelAngle:1,labelBaseline:1,labelBound:1,labelColor:1,labelFlush:1,labelFlushOffset:1,labelFont:1,labelFontSize:1,labelFontStyle:1,labelFontWeight:1,labelLimit:1,labelLineHeight:1,labelOffset:1,labelOpacity:1,labelOverlap:1,labelPadding:1,labels:1,labelSeparation:1,maxExtent:1,minExtent:1,offset:1,position:1,tickBand:1,tickCap:1,tickColor:1,tickCount:1,tickDash:1,tickDashOffset:1,tickExtra:1,tickMinStep:1,tickOffset:1,tickOpacity:1,tickRound:1,ticks:1,tickSize:1,tickWidth:1,title:1,titleAlign:1,titleAnchor:1,titleAngle:1,titleBaseline:1,titleColor:1,titleFont:1,titleFontSize:1,titleFontStyle:1,titleFontWeight:1,titleLimit:1,titleLineHeight:1,titleOpacity:1,titlePadding:1,titleX:1,titleY:1,translate:1,values:1,zindex:1},M8e=Object.assign(Object.assign({},uG),{style:1,labelExpr:1,encoding:1});function pM(e){return!!M8e[e]}const A8e={axis:1,axisBand:1,axisBottom:1,axisDiscrete:1,axisLeft:1,axisPoint:1,axisQuantitative:1,axisRight:1,axisTemporal:1,axisTop:1,axisX:1,axisXBand:1,axisXDiscrete:1,axisXPoint:1,axisXQuantitative:1,axisXTemporal:1,axisY:1,axisYBand:1,axisYDiscrete:1,axisYPoint:1,axisYQuantitative:1,axisYTemporal:1},hG=ye(A8e);function ol(e){return"mark"in e}class f6{constructor(t,n){this.name=t,this.run=n}hasMatchingType(t){return ol(t)?c8e(t.mark)===this.name:!1}}var N8e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s!!i.field):we(n)||l6(n):!1}function gG(e,t){const n=e&&e[t];return n?ue(n)?Gd(n,i=>!!i.field):we(n)||co(n)||l3(n):!1}function $8(e,t){if(Zn(t)){const n=e[t];if((we(n)||co(n))&&CV(n.type)){const i=rV(t);return gG(e,i)}}return!1}function TS(e){return Gd(Awe,t=>{if(Bd(e,t)){const n=e[t];if(ue(n))return Gd(n,i=>!!i.aggregate);{const i=qa(n);return i&&!!i.aggregate}}return!1})}function _G(e,t){const n=[],i=[],s=[],o=[],c={};return vS(e,(d,f)=>{if(we(d)){const{field:u,aggregate:a,bin:m,timeUnit:y}=d,p=N8e(d,["field","aggregate","bin","timeUnit"]);if(a||y||m){const l=wS(d),b=l==null?void 0:l.title;let L=ve(d,{forAs:!0});const E=Object.assign(Object.assign(Object.assign({},b?[]:{title:vu(d,t,{allowDisabling:!0})}),p),{field:L});if(a){let S;if(Ac(a)?(S="argmax",L=ve({op:"argmax",field:a.argmax},{forAs:!0}),E.field=`${L}.${u}`):Yo(a)?(S="argmin",L=ve({op:"argmin",field:a.argmin},{forAs:!0}),E.field=`${L}.${u}`):a!=="boxplot"&&a!=="errorbar"&&a!=="errorband"&&(S=a),S){const x={op:S,as:L};u&&(x.field=u),o.push(x)}}else if(n.push(L),lr(d)&&nn(m)){if(i.push({bin:m,field:u,as:L}),n.push(ve(d,{binSuffix:"end"})),c3(d,f)&&n.push(ve(d,{binSuffix:"range"})),Zn(f)){const S={field:`${L}_end`};c[`${f}2`]=S}E.bin="binned",sV(f)||(E.type=Kd)}else if(y){s.push({timeUnit:y,field:u,as:L});const S=lr(d)&&d.type!==ch&&"time";S&&(f===t3||f===Yd?E.formatType=S:$we(f)?E.legend=Object.assign({formatType:S},E.legend):Zn(f)&&(E.axis=Object.assign({formatType:S},E.axis)))}c[f]=E}else n.push(u),c[f]=e[f]}else c[f]=e[f]}),{bins:i,timeUnits:s,aggregate:o,groupby:n,encoding:c}}function C8e(e,t,n){const i=Vwe(t,n);if(i){if(i==="binned"){const s=e[t===Jr?hn:Kn];return!!(we(s)&&we(e[t])&&ei(s.bin))}}else return!1;return!0}function R8e(e,t,n,i){const s={};for(const o of ye(e))iV(o)||me(N5e(o));for(let o of jwe){if(!e[o])continue;const c=e[o];if(jh(o)){const d=aV(o),f=s[d];if(we(f)){if(MLe(f.type)&&we(c)){me(x5e(d));continue}}else o=d,me(k5e(d))}if(o==="angle"&&t==="arc"&&!e.theta&&(me(S5e),o=dr),!C8e(e,o,t)){me(e6(o,t));continue}if(o===rl&&t==="line"){const d=qa(e[o]);if(d!=null&&d.aggregate){me(M5e);continue}}if(o===ps&&(n?"fill"in e:"stroke"in e)){me(vV("encoding",{fill:"fill"in e,stroke:"stroke"in e}));continue}if(o===i3||o===n3&&!ue(c)&&!Vr(c)||o===Yd&&ue(c))c&&(s[o]=Se(c).reduce((d,f)=>(we(f)?d.push(bS(f,o)):me(P8(f,o)),d),[]));else{if(o===Yd&&c===null)s[o]=null;else if(!we(c)&&!co(c)&&!Vr(c)&&!o6(c)&&!Ne(c)){me(P8(c,o));continue}s[o]=cG(c,o,i)}}return s}function u6(e,t){const n={};for(const i of ye(e)){const s=cG(e[i],i,t,{compositeMark:!0});n[i]=s}return n}function P8e(e){const t=[];for(const n of ye(e))if(Bd(e,n)){const i=e[n],s=Se(i);for(const o of s)we(o)?t.push(o):l6(o)&&t.push(o.condition)}return t}function vS(e,t,n){if(e)for(const i of ye(e)){const s=e[i];if(ue(s))for(const o of s)t.call(n,o,i);else t.call(n,s,i)}}function D8e(e,t,n,i){return e?ye(e).reduce((s,o)=>{const c=e[o];return ue(c)?c.reduce((d,f)=>t.call(i,d,f,o),s):t.call(i,s,c,o)},n):n}function pG(e,t){return ye(t).reduce((n,i)=>{switch(i){case hn:case Kn:case Ym:case Km:case Xm:case Jr:case no:case kc:case Dh:case dr:case sl:case Qr:case il:case io:case so:case ea:case or:case t3:case ys:case wf:case Yd:return n;case n3:if(e==="line"||e==="trail")return n;case i3:case Wm:{const s=t[i];if(ue(s)||we(s))for(const o of Se(s))o.aggregate||n.push(ve(o,{}));return n}case rl:if(e==="trail")return n;case ps:case ro:case ao:case al:case Bc:case Fc:case Oc:case Ic:{const s=qa(t[i]);return s&&!s.aggregate&&n.push(ve(s,{})),n}}},[])}var yG=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{const f=i?` of ${ES(t)}`:"";return{field:c+t.field,type:t.type,title:Ne(d)?{signal:`${d}"${escape(f)}"`}:d+f}}),o=P8e(n).map(L8e);return{tooltip:[...s,...Ta(o,Bt)]}}function ES(e){const{title:t,field:n}=e;return Sn(t,n)}function SS(e,t,n,i,s){const{scale:o,axis:c}=n;return({partName:d,mark:f,positionPrefix:u,endPositionPrefix:a=void 0,extraEncoding:m={}})=>{const y=ES(n);return mG(e,d,s,{mark:f,encoding:Object.assign(Object.assign(Object.assign({[t]:Object.assign(Object.assign(Object.assign({field:`${u}_${n.field}`,type:n.type},y!==void 0?{title:y}:{}),o!==void 0?{scale:o}:{}),c!==void 0?{axis:c}:{})},xe(a)?{[`${t}2`]:{field:`${a}_${n.field}`}}:{}),i),m)})}}function mG(e,t,n,i){const{clip:s,color:o,opacity:c}=e,d=e.type;return e[t]||e[t]===void 0&&n[t]?[Object.assign(Object.assign({},i),{mark:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},n[t]),s?{clip:s}:{}),o?{color:o}:{}),c?{opacity:c}:{}),$a(i.mark)?i.mark:{type:i.mark}),{style:`${d}-${String(t)}`}),Ec(e[t])?{}:e[t])})]:[]}function wG(e,t,n){const{encoding:i}=e,s=t==="vertical"?"y":"x",o=i[s],c=i[`${s}2`],d=i[`${s}Error`],f=i[`${s}Error2`];return{continuousAxisChannelDef:l_(o,n),continuousAxisChannelDef2:l_(c,n),continuousAxisChannelDefError:l_(d,n),continuousAxisChannelDefError2:l_(f,n),continuousAxis:s}}function l_(e,t){if(e!=null&&e.aggregate){const{aggregate:n}=e,i=yG(e,["aggregate"]);return n!==t&&me(lLe(n,t)),i}else return e}function LG(e,t){const{mark:n,encoding:i}=e,{x:s,y:o}=i;if($a(n)&&n.orient)return n.orient;if(va(s)){if(va(o)){const c=we(s)&&s.aggregate,d=we(o)&&o.aggregate;if(!c&&d===t)return"vertical";if(!d&&c===t)return"horizontal";if(c===t&&d===t)throw new Error("Both x and y cannot have aggregate");return hh(o)&&!hh(s)?"horizontal":"vertical"}return"horizontal"}else{if(va(o))return"vertical";throw new Error(`Need a valid continuous axis for ${t}s`)}}var op=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sSS(u,S,E,_e,t.boxplot),z=H(R),Y=H(k),$=H(Object.assign(Object.assign({},R),j?{size:j}:{})),W=q8([{fieldPrefix:p==="min-max"?"upper_whisker_":"max_",titlePrefix:"Max"},{fieldPrefix:"upper_box_",titlePrefix:"Q3"},{fieldPrefix:"mid_box_",titlePrefix:"Median"},{fieldPrefix:"lower_box_",titlePrefix:"Q1"},{fieldPrefix:p==="min-max"?"lower_whisker_":"min_",titlePrefix:"Min"}],E,k),X={type:"tick",color:"black",opacity:1,orient:M,invalid:y,aria:!1},G=p==="min-max"?W:q8([{fieldPrefix:"upper_whisker_",titlePrefix:"Upper Whisker"},{fieldPrefix:"lower_whisker_",titlePrefix:"Lower Whisker"}],E,k),oe=[...z({partName:"rule",mark:{type:"rule",invalid:y,aria:!1},positionPrefix:"lower_whisker",endPositionPrefix:"lower_box",extraEncoding:G}),...z({partName:"rule",mark:{type:"rule",invalid:y,aria:!1},positionPrefix:"upper_box",endPositionPrefix:"upper_whisker",extraEncoding:G}),...z({partName:"ticks",mark:X,positionPrefix:"lower_whisker",extraEncoding:G}),...z({partName:"ticks",mark:X,positionPrefix:"upper_whisker",extraEncoding:G})],he=[...p!=="tukey"?oe:[],...Y({partName:"box",mark:Object.assign(Object.assign({type:"bar"},m?{size:m}:{}),{orient:O,invalid:y,ariaRoleDescription:"box"}),positionPrefix:"lower_box",endPositionPrefix:"upper_box",extraEncoding:W}),...$({partName:"median",mark:Object.assign(Object.assign(Object.assign({type:"tick",invalid:y},ke(t.boxplot.median)&&t.boxplot.median.color?{color:t.boxplot.median.color}:{}),m?{size:m}:{}),{orient:M,aria:!1}),positionPrefix:"mid_box",extraEncoding:W})];if(p==="min-max")return Object.assign(Object.assign({},f),{transform:((i=f.transform)!==null&&i!==void 0?i:[]).concat(L),layer:he});const ie=`datum["lower_box_${E.field}"]`,Oe=`datum["upper_box_${E.field}"]`,de=`(${Oe} - ${ie})`,Me=`${ie} - ${a} * ${de}`,Fe=`${Oe} + ${a} * ${de}`,Ge=`datum["${E.field}"]`,pt={joinaggregate:vG(E.field),groupby:x},ht={transform:[{filter:`(${Me} <= ${Ge}) && (${Ge} <= ${Fe})`},{aggregate:[{op:"min",field:E.field,as:`lower_whisker_${E.field}`},{op:"max",field:E.field,as:`upper_whisker_${E.field}`},{op:"min",field:`lower_box_${E.field}`,as:`lower_box_${E.field}`},{op:"max",field:`upper_box_${E.field}`,as:`upper_box_${E.field}`},...F],groupby:x}],layer:oe},ge=op(R,["tooltip"]),{scale:V,axis:q}=E,D=ES(E),K=as(q,["title"]),J=mG(u,"outliers",t.boxplot,{transform:[{filter:`(${Ge} < ${Me}) || (${Ge} > ${Fe})`}],mark:"point",encoding:Object.assign(Object.assign(Object.assign({[S]:Object.assign(Object.assign(Object.assign({field:E.field,type:E.type},D!==void 0?{title:D}:{}),V!==void 0?{scale:V}:{}),Wt(K)?{}:{axis:K})},ge),P?{color:P}:{}),C?{tooltip:C}:{})})[0];let re;const se=[...l,...b,pt];return J?re={transform:se,layer:[J,ht]}:(re=ht,re.transform.unshift(...se)),Object.assign(Object.assign({},f),{layer:[re,{transform:L,layer:he}]})}function vG(e){return[{op:"q1",field:e,as:`lower_box_${e}`},{op:"q3",field:e,as:`upper_box_${e}`}]}function z8e(e,t,n){const i=LG(e,Zy),{continuousAxisChannelDef:s,continuousAxis:o}=wG(e,i,Zy),c=s.field,d=bG(t),f=[...vG(c),{op:"median",field:c,as:`mid_box_${c}`},{op:"min",field:c,as:(d==="min-max"?"lower_whisker_":"min_")+c},{op:"max",field:c,as:(d==="min-max"?"upper_whisker_":"max_")+c}],u=d==="min-max"||d==="tukey"?[]:[{calculate:`datum["upper_box_${c}"] - datum["lower_box_${c}"]`,as:`iqr_${c}`},{calculate:`min(datum["upper_box_${c}"] + datum["iqr_${c}"] * ${t}, datum["max_${c}"])`,as:`upper_whisker_${c}`},{calculate:`max(datum["lower_box_${c}"] - datum["iqr_${c}"] * ${t}, datum["min_${c}"])`,as:`lower_whisker_${c}`}],a=e.encoding,m=o;a[m];const y=op(a,[typeof m=="symbol"?m:m+""]),{customTooltipWithoutAggregatedField:p,filteredEncoding:l}=j8e(y),{bins:b,timeUnits:L,aggregate:E,groupby:S,encoding:x}=_G(l,n),F=i==="vertical"?"horizontal":"vertical",k=i,M=[...b,...L,{aggregate:[...E,...f],groupby:S},...u];return{bins:b,timeUnits:L,transform:M,groupby:S,aggregate:E,continuousAxisChannelDef:s,continuousAxis:o,encodingWithoutContinuousAxis:x,ticksOrient:F,boxOrient:k,customTooltipWithoutAggregatedField:p}}var yM=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s1?{layer:l}:Object.assign({},l[0]))}function V8e(e,t){const{encoding:n}=e;if(G8e(n))return{orient:LG(e,t),inputType:"raw"};const i=W8e(n),s=Y8e(n),o=n.x,c=n.y;if(i){if(s)throw new Error(`${t} cannot be both type aggregated-upper-lower and aggregated-error`);const d=n.x2,f=n.y2;if(Je(d)&&Je(f))throw new Error(`${t} cannot have both x2 and y2`);if(Je(d)){if(va(o))return{orient:"horizontal",inputType:"aggregated-upper-lower"};throw new Error(`Both x and x2 have to be quantitative in ${t}`)}else if(Je(f)){if(va(c))return{orient:"vertical",inputType:"aggregated-upper-lower"};throw new Error(`Both y and y2 have to be quantitative in ${t}`)}throw new Error("No ranged axis")}else{const d=n.xError,f=n.xError2,u=n.yError,a=n.yError2;if(Je(f)&&!Je(d))throw new Error(`${t} cannot have xError2 without xError`);if(Je(a)&&!Je(u))throw new Error(`${t} cannot have yError2 without yError`);if(Je(d)&&Je(u))throw new Error(`${t} cannot have both xError and yError with both are quantiative`);if(Je(d)){if(va(o))return{orient:"horizontal",inputType:"aggregated-error"};throw new Error("All x, xError, and xError2 (if exist) have to be quantitative")}else if(Je(u)){if(va(c))return{orient:"vertical",inputType:"aggregated-error"};throw new Error("All y, yError, and yError2 (if exist) have to be quantitative")}throw new Error("No ranged axis")}}function G8e(e){return(Je(e.x)||Je(e.y))&&!Je(e.x2)&&!Je(e.y2)&&!Je(e.xError)&&!Je(e.xError2)&&!Je(e.yError)&&!Je(e.yError2)}function W8e(e){return Je(e.x2)||Je(e.y2)}function Y8e(e){return Je(e.xError)||Je(e.xError2)||Je(e.yError)||Je(e.yError2)}function SG(e,t,n){var i;const{mark:s,encoding:o,params:c,projection:d}=e,f=yM(e,["mark","encoding","params","projection"]),u=$a(s)?s:{type:s};c&&me(bV(t));const{orient:a,inputType:m}=V8e(e,t),{continuousAxisChannelDef:y,continuousAxisChannelDef2:p,continuousAxisChannelDefError:l,continuousAxisChannelDefError2:b,continuousAxis:L}=wG(e,a,t),{errorBarSpecificAggregate:E,postAggregateCalculates:S,tooltipSummary:x,tooltipTitleWithFieldName:F}=X8e(u,y,p,l,b,m,t,n),k=o,M=L;k[M];const O=L==="x"?"x2":"y2";k[O];const C=L==="x"?"xError":"yError";k[C];const P=L==="x"?"xError2":"yError2";k[P];const j=yM(k,[typeof M=="symbol"?M:M+"",typeof O=="symbol"?O:O+"",typeof C=="symbol"?C:C+"",typeof P=="symbol"?P:P+""]),{bins:R,timeUnits:H,aggregate:z,groupby:Y,encoding:$}=_G(j,n),W=[...z,...E],X=m!=="raw"?[]:Y,G=q8(x,y,$,F);return{transform:[...(i=f.transform)!==null&&i!==void 0?i:[],...R,...H,...W.length===0?[]:[{aggregate:W,groupby:X}],...S],groupby:X,continuousAxisChannelDef:y,continuousAxis:L,encodingWithoutContinuousAxis:$,ticksOrient:a==="vertical"?"horizontal":"vertical",markDef:u,outerSpec:f,tooltipEncoding:G}}function X8e(e,t,n,i,s,o,c,d){let f=[],u=[];const a=t.field;let m,y=!1;if(o==="raw"){const p=e.center?e.center:e.extent?e.extent==="iqr"?"median":"mean":d.errorbar.center,l=e.extent?e.extent:p==="mean"?"stderr":"iqr";if(p==="median"!=(l==="iqr")&&me(oLe(p,l,c)),l==="stderr"||l==="stdev")f=[{op:l,field:a,as:`extent_${a}`},{op:p,field:a,as:`center_${a}`}],u=[{calculate:`datum["center_${a}"] + datum["extent_${a}"]`,as:`upper_${a}`},{calculate:`datum["center_${a}"] - datum["extent_${a}"]`,as:`lower_${a}`}],m=[{fieldPrefix:"center_",titlePrefix:Q0(p)},{fieldPrefix:"upper_",titlePrefix:mM(p,l,"+")},{fieldPrefix:"lower_",titlePrefix:mM(p,l,"-")}],y=!0;else{let b,L,E;l==="ci"?(b="mean",L="ci0",E="ci1"):(b="median",L="q1",E="q3"),f=[{op:L,field:a,as:`lower_${a}`},{op:E,field:a,as:`upper_${a}`},{op:b,field:a,as:`center_${a}`}],m=[{fieldPrefix:"upper_",titlePrefix:vu({field:a,aggregate:E,type:"quantitative"},d,{allowDisabling:!1})},{fieldPrefix:"lower_",titlePrefix:vu({field:a,aggregate:L,type:"quantitative"},d,{allowDisabling:!1})},{fieldPrefix:"center_",titlePrefix:vu({field:a,aggregate:b,type:"quantitative"},d,{allowDisabling:!1})}]}}else{(e.center||e.extent)&&me(aLe(e.center,e.extent)),o==="aggregated-upper-lower"?(m=[],u=[{calculate:`datum["${n.field}"]`,as:`upper_${a}`},{calculate:`datum["${a}"]`,as:`lower_${a}`}]):o==="aggregated-error"&&(m=[{fieldPrefix:"",titlePrefix:a}],u=[{calculate:`datum["${a}"] + datum["${i.field}"]`,as:`upper_${a}`}],s?u.push({calculate:`datum["${a}"] + datum["${s.field}"]`,as:`lower_${a}`}):u.push({calculate:`datum["${a}"] - datum["${i.field}"]`,as:`lower_${a}`}));for(const p of u)m.push({fieldPrefix:p.as.substring(0,6),titlePrefix:Wd(Wd(p.calculate,'datum["',""),'"]',"")})}return{postAggregateCalculates:u,errorBarSpecificAggregate:f,tooltipSummary:m,tooltipTitleWithFieldName:y}}function mM(e,t,n){return`${Q0(e)} ${n} ${t}`}const kS="errorband",K8e=["band","borders"],Z8e=new f6(kS,xG);function xG(e,{config:t}){e=Object.assign(Object.assign({},e),{encoding:u6(e.encoding,t)});const{transform:n,continuousAxisChannelDef:i,continuousAxis:s,encodingWithoutContinuousAxis:o,markDef:c,outerSpec:d,tooltipEncoding:f}=SG(e,kS,t),u=c,a=SS(u,s,i,o,t.errorband),m=e.encoding.x!==void 0&&e.encoding.y!==void 0;let y={type:m?"area":"rect"},p={type:m?"line":"rule"};const l=Object.assign(Object.assign({},u.interpolate?{interpolate:u.interpolate}:{}),u.tension&&u.interpolate?{tension:u.tension}:{});return m?(y=Object.assign(Object.assign(Object.assign({},y),l),{ariaRoleDescription:"errorband"}),p=Object.assign(Object.assign(Object.assign({},p),l),{aria:!1})):u.interpolate?me(cM("interpolate")):u.tension&&me(cM("tension")),Object.assign(Object.assign({},d),{transform:n,layer:[...a({partName:"band",mark:y,positionPrefix:"lower",endPositionPrefix:"upper",extraEncoding:f}),...a({partName:"borders",mark:p,positionPrefix:"lower",extraEncoding:f}),...a({partName:"borders",mark:p,positionPrefix:"upper",extraEncoding:f})]})}const kG={};function BS(e,t,n){const i=new f6(e,t);kG[e]={normalizer:i,parts:n}}function J8e(){return ye(kG)}BS(Zy,TG,U8e);BS(xS,EG,$8e);BS(kS,xG,K8e);const Q8e=["gradientHorizontalMaxLength","gradientHorizontalMinLength","gradientVerticalMaxLength","gradientVerticalMinLength","unselectedOpacity"],BG={titleAlign:"align",titleAnchor:"anchor",titleAngle:"angle",titleBaseline:"baseline",titleColor:"color",titleFont:"font",titleFontSize:"fontSize",titleFontStyle:"fontStyle",titleFontWeight:"fontWeight",titleLimit:"limit",titleLineHeight:"lineHeight",titleOrient:"orient",titlePadding:"offset"},FG={labelAlign:"align",labelAnchor:"anchor",labelAngle:"angle",labelBaseline:"baseline",labelColor:"color",labelFont:"font",labelFontSize:"fontSize",labelFontStyle:"fontStyle",labelFontWeight:"fontWeight",labelLimit:"limit",labelLineHeight:"lineHeight",labelOrient:"orient",labelPadding:"offset"},e9e=ye(BG),t9e=ye(FG),n9e={header:1,headerRow:1,headerColumn:1,headerFacet:1},IG=ye(n9e),OG=["size","shape","fill","stroke","strokeDash","strokeWidth","opacity"],i9e={gradientHorizontalMaxLength:200,gradientHorizontalMinLength:100,gradientVerticalMaxLength:200,gradientVerticalMinLength:64,unselectedOpacity:.35},s9e={aria:1,clipHeight:1,columnPadding:1,columns:1,cornerRadius:1,description:1,direction:1,fillColor:1,format:1,formatType:1,gradientLength:1,gradientOpacity:1,gradientStrokeColor:1,gradientStrokeWidth:1,gradientThickness:1,gridAlign:1,labelAlign:1,labelBaseline:1,labelColor:1,labelFont:1,labelFontSize:1,labelFontStyle:1,labelFontWeight:1,labelLimit:1,labelOffset:1,labelOpacity:1,labelOverlap:1,labelPadding:1,labelSeparation:1,legendX:1,legendY:1,offset:1,orient:1,padding:1,rowPadding:1,strokeColor:1,symbolDash:1,symbolDashOffset:1,symbolFillColor:1,symbolLimit:1,symbolOffset:1,symbolOpacity:1,symbolSize:1,symbolStrokeColor:1,symbolStrokeWidth:1,symbolType:1,tickCount:1,tickMinStep:1,title:1,titleAlign:1,titleAnchor:1,titleBaseline:1,titleColor:1,titleFont:1,titleFontSize:1,titleFontStyle:1,titleFontWeight:1,titleLimit:1,titleLineHeight:1,titleOpacity:1,titleOrient:1,titlePadding:1,type:1,values:1,zindex:1},Va="_vgsid_",r9e={point:{on:"click",fields:[Va],toggle:"event.shiftKey",resolve:"global",clear:"dblclick"},interval:{on:"[mousedown, window:mouseup] > window:mousemove!",encodings:["x","y"],translate:"[mousedown, window:mouseup] > window:mousemove!",zoom:"wheel!",mark:{fill:"#333",fillOpacity:.125,stroke:"white"},resolve:"global",clear:"dblclick"}};function FS(e){return e==="legend"||!!(e!=null&&e.legend)}function a5(e){return FS(e)&&ke(e)}function IS(e){return!!(e!=null&&e.select)}var a9e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sthis.mapLayerOrUnit(i,n))})}mapHConcat(t,n){return Object.assign(Object.assign({},t),{hconcat:t.hconcat.map(i=>this.map(i,n))})}mapVConcat(t,n){return Object.assign(Object.assign({},t),{vconcat:t.vconcat.map(i=>this.map(i,n))})}mapConcat(t,n){const{concat:i}=t,s=k9e(t,["concat"]);return Object.assign(Object.assign({},s),{concat:i.map(o=>this.map(o,n))})}mapFacet(t,n){return Object.assign(Object.assign({},t),{spec:this.map(t.spec,n)})}mapRepeat(t,n){return Object.assign(Object.assign({},t),{spec:this.map(t.spec,n)})}}const B9e={zero:1,center:1,normalize:1};function F9e(e){return e in B9e}const I9e=new Set([zV,n6,t6,Gy,s6,fS,uS,i6,$V,dS]),O9e=new Set([n6,t6,zV]);function Df(e){return we(e)&&fh(e)==="quantitative"&&!e.bin}function vM(e,t){var n,i;const s=t==="x"?"y":"radius",o=e[t],c=e[s];if(we(o)&&we(c))if(Df(o)&&Df(c)){if(o.stack)return t;if(c.stack)return s;const d=we(o)&&!!o.aggregate,f=we(c)&&!!c.aggregate;if(d!==f)return d?t:s;{const u=(n=o.scale)===null||n===void 0?void 0:n.type,a=(i=c.scale)===null||i===void 0?void 0:i.type;if(u&&u!=="linear")return s;if(a&&a!=="linear")return t}}else{if(Df(o))return t;if(Df(c))return s}else{if(Df(o))return t;if(Df(c))return s}}function M9e(e){switch(e){case"x":return"y";case"y":return"x";case"theta":return"radius";case"radius":return"theta"}}function PG(e,t){var n,i;const s=$a(e)?e.type:e;if(!I9e.has(s))return null;const o=vM(t,"x")||vM(t,"theta");if(!o)return null;const c=t[o],d=we(c)?ve(c,{}):void 0,f=M9e(o),u=[],a=new Set;if(t[f]){const p=t[f],l=we(p)?ve(p,{}):void 0;l&&l!==d&&(u.push(f),a.add(l));const b=f==="x"?"xOffset":"yOffset",L=t[b],E=we(L)?ve(L,{}):void 0;E&&E!==d&&(u.push(b),a.add(E))}const m=Uwe.reduce((p,l)=>{if(l!=="tooltip"&&Bd(t,l)){const b=t[l];for(const L of Se(b)){const E=qa(L);if(E.aggregate)continue;const S=ve(E,{});(!S||!a.has(S))&&p.push({channel:l,fieldDef:E})}}return p},[]);let y;return c.stack!==void 0?Ec(c.stack)?y=c.stack?"zero":null:y=c.stack:O9e.has(s)&&(y="zero"),!y||!F9e(y)||TS(t)&&m.length===0?null:!((n=c==null?void 0:c.scale)===null||n===void 0)&&n.type&&((i=c==null?void 0:c.scale)===null||i===void 0?void 0:i.type)!==os.LINEAR?(me(iLe(c.scale.type)),null):Je(t[oo(o)])?(c.stack!==void 0&&me(nLe(o)),null):(we(c)&&c.aggregate&&!Jwe.has(c.aggregate)&&me(sLe(c.aggregate)),{groupbyChannels:u,groupbyFields:a,fieldChannel:o,impute:c.impute===null?!1:Cc(s),stackBy:m,offset:y})}var DG=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s1?t:t.type}function N9e(e){for(const t of["line","area","rule","trail"])e[t]&&(e=Object.assign(Object.assign({},e),{[t]:as(e[t],["point","line"])}));return e}function o5(e,t={},n){return e.point==="transparent"?{opacity:0}:e.point?ke(e.point)?e.point:{}:e.point!==void 0?null:t.point||n.shape?ke(t.point)?t.point:{}:void 0}function EM(e,t={}){return e.line?e.line===!0?{}:e.line:e.line!==void 0?null:t.line?t.line===!0?{}:t.line:void 0}class C9e{constructor(){this.name="path-overlay"}hasMatchingType(t,n){if(ol(t)){const{mark:i,encoding:s}=t,o=$a(i)?i:{type:i};switch(o.type){case"line":case"rule":case"trail":return!!o5(o,n[o.type],s);case"area":return!!o5(o,n[o.type],s)||!!EM(o,n[o.type])}}return!1}run(t,n,i){const{config:s}=n,{params:o,projection:c,mark:d,encoding:f}=t,u=DG(t,["params","projection","mark","encoding"]),a=u6(f,s),m=$a(d)?d:{type:d},y=o5(m,s[m.type],a),p=m.type==="area"&&EM(m,s[m.type]),l=[Object.assign(Object.assign({},o?{params:o}:{}),{mark:A9e(Object.assign(Object.assign({},m.type==="area"&&m.opacity===void 0&&m.fillOpacity===void 0?{opacity:.7}:{}),m)),encoding:as(a,["shape"])})],b=PG(m,a);let L=a;if(b){const{fieldChannel:E,offset:S}=b;L=Object.assign(Object.assign({},a),{[E]:Object.assign(Object.assign({},a[E]),S?{stack:S}:{})})}return L=as(L,["y2","x2"]),p&&l.push(Object.assign(Object.assign({},c?{projection:c}:{}),{mark:Object.assign(Object.assign({type:"line"},ah(m,["clip","interpolate","tension","tooltip"])),p),encoding:L})),y&&l.push(Object.assign(Object.assign({},c?{projection:c}:{}),{mark:Object.assign(Object.assign({type:"point",opacity:1,filled:!0},ah(m,["clip","tooltip"])),y),encoding:L})),i(Object.assign(Object.assign({},u),{layer:l}),Object.assign(Object.assign({},n),{config:N9e(s)}))}}var R9e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sxM(o,t)).filter(o=>o);else{const o=xM(s,t);o!==void 0&&(n[i]=o)}}return n}class D9e{constructor(){this.name="RuleForRangedLine"}hasMatchingType(t){if(ol(t)){const{encoding:n,mark:i}=t;if(i==="line"||$a(i)&&i.type==="line")for(const s of Pwe){const o=Lf(s),c=n[o];if(n[s]&&(we(c)&&!ei(c.bin)||co(c)))return!0}}return!1}run(t,n,i){const{encoding:s,mark:o}=t;return me(j5e(!!s.x2,!!s.y2)),i(Object.assign(Object.assign({},t),{mark:ke(o)?Object.assign(Object.assign({},o),{type:"rule"}):"rule"}),n)}}var _l=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{const y=Object.assign(Object.assign({},u),{layer:m}),p=`${(s.name||"")+a}child__layer_${dn(m)}`,l=this.mapLayerOrUnit(s,Object.assign(Object.assign({},n),{repeater:y,repeaterPrefix:p}));return l.name=p,l})})}mapNonLayerRepeat(t,n){var i;const{repeat:s,spec:o,data:c}=t,d=_l(t,["repeat","spec","data"]);!ue(s)&&t.columns&&(t=as(t,["columns"]),me(rM("repeat")));const f=[],{repeater:u={},repeaterPrefix:a=""}=n,m=!ue(s)&&s.row||[u?u.row:null],y=!ue(s)&&s.column||[u?u.column:null],p=ue(s)&&s||[u?u.repeat:null];for(const b of p)for(const L of m)for(const E of y){const S={repeat:b,row:L,column:E,layer:u.layer},x=(o.name||"")+a+"child__"+(ue(s)?`${dn(b)}`:(s.row?`row_${dn(L)}`:"")+(s.column?`column_${dn(E)}`:"")),F=this.map(o,Object.assign(Object.assign({},n),{repeater:S,repeaterPrefix:x}));F.name=x,f.push(as(F,["data"]))}const l=ue(s)?t.columns:s.column?s.column.length:1;return Object.assign(Object.assign({data:(i=o.data)!==null&&i!==void 0?i:c,align:"all"},d),{columns:l,concat:f})}mapFacet(t,n){const{facet:i}=t;return o3(i)&&t.columns&&(t=as(t,["columns"]),me(rM("facet"))),super.mapFacet(t,n)}mapUnitWithParentEncodingOrProjection(t,n){const{encoding:i,projection:s}=t,{parentEncoding:o,parentProjection:c,config:d}=n,f=BM({parentProjection:c,projection:s}),u=kM({parentEncoding:o,encoding:l5(i,n.repeater)});return this.mapUnit(Object.assign(Object.assign(Object.assign({},t),f?{projection:f}:{}),u?{encoding:u}:{}),{config:d})}mapFacetedUnit(t,n){const i=t.encoding,{row:s,column:o,facet:c}=i,d=_l(i,["row","column","facet"]),{mark:f,width:u,projection:a,height:m,view:y,params:p,encoding:l}=t,b=_l(t,["mark","width","projection","height","view","params","encoding"]),{facetMapping:L,layout:E}=this.getFacetMappingAndLayout({row:s,column:o,facet:c},n),S=l5(d,n.repeater);return this.mapFacet(Object.assign(Object.assign(Object.assign({},b),E),{facet:L,spec:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},u?{width:u}:{}),m?{height:m}:{}),y?{view:y}:{}),a?{projection:a}:{}),{mark:f,encoding:S}),p?{params:p}:{})}),n)}getFacetMappingAndLayout(t,n){var i;const{row:s,column:o,facet:c}=t;if(s||o){c&&me(P5e([...s?[Po]:[],...o?[Do]:[]]));const d={},f={};for(const u of[Po,Do]){const a=t[u];if(a){const m=_l(a,["align","center","spacing","columns"]);d[u]=m;for(const y of["align","center","spacing"])a[y]!==void 0&&((i=f[y])!==null&&i!==void 0||(f[y]={}),f[y][u]=a[y])}}return{facetMapping:d,layout:f}}else{const{align:d,center:f,spacing:u,columns:a}=c,m=_l(c,["align","center","spacing","columns"]);return{facetMapping:P9e(m,n.repeater),layout:Object.assign(Object.assign(Object.assign(Object.assign({},d?{align:d}:{}),f?{center:f}:{}),u?{spacing:u}:{}),a?{columns:a}:{})}}}mapLayer(t,n){var{parentEncoding:i,parentProjection:s}=n,o=_l(n,["parentEncoding","parentProjection"]);const{encoding:c,projection:d}=t,f=_l(t,["encoding","projection"]),u=Object.assign(Object.assign({},o),{parentEncoding:kM({parentEncoding:i,encoding:c,layer:!0}),parentProjection:BM({parentProjection:s,projection:d})});return super.mapLayer(f,u)}}function kM({parentEncoding:e,encoding:t={},layer:n}){let i={};if(e){const s=new Set([...ye(e),...ye(t)]);for(const o of s){const c=t[o],d=e[o];if(Je(c)){const f=Object.assign(Object.assign({},d),c);i[o]=f}else l3(c)?i[o]=Object.assign(Object.assign({},c),{condition:Object.assign(Object.assign({},d),c.condition)}):c||c===null?i[o]=c:(n||Vr(d)||Ne(d)||Je(d)||ue(d))&&(i[o]=d)}}else i=t;return!i||Wt(i)?void 0:i}function BM(e){const{parentProjection:t,projection:n}=e;return t&&n&&me(E5e({parentProjection:t,projection:n})),n??t}function NS(e){return"filter"in e}function U9e(e){return(e==null?void 0:e.stop)!==void 0}function HG(e){return"lookup"in e}function H9e(e){return"data"in e}function z9e(e){return"param"in e}function $9e(e){return"pivot"in e}function q9e(e){return"density"in e}function V9e(e){return"quantile"in e}function G9e(e){return"regression"in e}function W9e(e){return"loess"in e}function Y9e(e){return"sample"in e}function X9e(e){return"window"in e}function K9e(e){return"joinaggregate"in e}function Z9e(e){return"flatten"in e}function J9e(e){return"calculate"in e}function zG(e){return"bin"in e}function Q9e(e){return"impute"in e}function e7e(e){return"timeUnit"in e}function t7e(e){return"aggregate"in e}function n7e(e){return"stack"in e}function i7e(e){return"fold"in e}function s7e(e){return e.map(t=>NS(t)?{filter:bu(t.filter,OLe)}:t)}var ql=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{var f;const u=d,{init:a,bind:m,empty:y}=u,p=ql(u,["init","bind","empty"]);p.type==="single"?(p.type="point",p.toggle=!1):p.type==="multi"&&(p.type="point"),n.emptySelections[c]=y!=="none";for(const l of Ti((f=n.selectionPredicates[c])!==null&&f!==void 0?f:{}))l.empty=y!=="none";return{name:c,value:a,select:p,bind:m}})}):t}}function FM(e,t){const{transform:n}=e,i=ql(e,["transform"]);if(n){const s=n.map(o=>{if(NS(o))return{filter:W8(o,t)};if(zG(o)&&bf(o.bin))return Object.assign(Object.assign({},o),{bin:qG(o.bin)});if(HG(o)){const c=o.from,{selection:d}=c,f=ql(c,["selection"]);return d?Object.assign(Object.assign({},o),{from:Object.assign({param:d},f)}):o}return o});return Object.assign(Object.assign({},i),{transform:s})}return e}function $G(e,t){var n,i;const s=at(e);if(we(s)&&bf(s.bin)&&(s.bin=qG(s.bin)),vf(s)&&(!((i=(n=s.scale)===null||n===void 0?void 0:n.domain)===null||i===void 0)&&i.selection)){const o=s.scale.domain,{selection:c}=o,d=ql(o,["selection"]);s.scale.domain=Object.assign(Object.assign({},d),c?{param:c}:{})}if(o6(s))if(ue(s.condition))s.condition=s.condition.map(o=>{const{selection:c,param:d,test:f}=o,u=ql(o,["selection","param","test"]);return d?o:Object.assign(Object.assign({},u),{test:W8(o,t)})});else{const o=$G(s.condition,t),{selection:c,param:d,test:f}=o,u=ql(o,["selection","param","test"]);s.condition=d?s.condition:Object.assign(Object.assign({},u),{test:W8(s.condition,t)})}return s}function qG(e){const t=e.extent;if(t!=null&&t.selection){const{selection:n}=t,i=ql(t,["selection"]);return Object.assign(Object.assign({},e),{extent:Object.assign(Object.assign({},i),{param:n})})}return e}function W8(e,t){const n=i=>bu(i,s=>{var o,c,d;const f=(o=t.emptySelections[s])!==null&&o!==void 0?o:!0,u={param:s,empty:f};return(c=(d=t.selectionPredicates)[s])!==null&&c!==void 0||(d[s]=[]),t.selectionPredicates[s].push(u),u});return e.selection?n(e.selection):bu(e.test||e.filter,i=>i.selection?n(i.selection):i)}class Y8 extends AS{map(t,n){var i;const s=(i=n.selections)!==null&&i!==void 0?i:[];if(t.params&&!ol(t)){const o=[];for(const c of t.params)IS(c)?s.push(c):o.push(c);t.params=o}return n.selections=s,super.map(t,VG(t,n))}mapUnit(t,n){var i;const s=n.selections;if(!s||!s.length)return t;const o=((i=n.path)!==null&&i!==void 0?i:[]).concat(t.name),c=[];for(const d of s)if(!d.views||!d.views.length)c.push(d);else for(const f of d.views)(xe(f)&&(f===t.name||o.indexOf(f)>=0)||ue(f)&&f.map(u=>o.indexOf(u)).every((u,a,m)=>u!==-1&&(a===0||u>m[a-1])))&&c.push(d);return c.length&&(t.params=c),t}}for(const e of["mapFacet","mapRepeat","mapHConcat","mapVConcat","mapLayer"]){const t=Y8.prototype[e];Y8.prototype[e]=function(n,i){return t.call(this,n,VG(n,i))}}function VG(e,t){var n;return e.name?Object.assign(Object.assign({},t),{path:((n=t.path)!==null&&n!==void 0?n:[]).concat(e.name)}):t}function GG(e,t){t===void 0&&(t=RG(e.config));const n=c7e(e,t),{width:i,height:s}=e,o=d7e(n,{width:i,height:s,autosize:e.autosize},t);return Object.assign(Object.assign({},n),o?{autosize:o}:{})}const a7e=new j9e,o7e=new r7e,l7e=new Y8;function c7e(e,t={}){const n={config:t};return l7e.map(a7e.map(o7e.map(e,n),n),n)}function IM(e){return xe(e)?{type:e}:e??{}}function d7e(e,t,n){let{width:i,height:s}=t;const o=ol(e)||g6(e),c={};o?i=="container"&&s=="container"?(c.type="fit",c.contains="padding"):i=="container"?(c.type="fit-x",c.contains="padding"):s=="container"&&(c.type="fit-y",c.contains="padding"):(i=="container"&&(me(tM("width")),i=void 0),s=="container"&&(me(tM("height")),s=void 0));const d=Object.assign(Object.assign(Object.assign({type:"pad"},c),n?IM(n.autosize):{}),IM(e.autosize));if(d.type==="fit"&&!o&&(me(l5e),d.type="pad"),i=="container"&&!(d.type=="fit"||d.type=="fit-x")&&me(nM("width")),s=="container"&&!(d.type=="fit"||d.type=="fit-y")&&me(nM("height")),!ba(d,{type:"pad"}))return d}function f7e(e){return e==="fit"||e==="fit-x"||e==="fit-y"}function u7e(e){return e?`fit-${Zm(e)}`:"fit"}const h7e=["background","padding"];function OM(e,t){const n={};for(const i of h7e)e&&e[i]!==void 0&&(n[i]=Is(e[i]));return t&&(n.params=e.params),n}class ll{constructor(t={},n={}){this.explicit=t,this.implicit=n}clone(){return new ll(at(this.explicit),at(this.implicit))}combine(){return Object.assign(Object.assign({},this.explicit),this.implicit)}get(t){return Sn(this.explicit[t],this.implicit[t])}getWithExplicit(t){return this.explicit[t]!==void 0?{explicit:!0,value:this.explicit[t]}:this.implicit[t]!==void 0?{explicit:!1,value:this.implicit[t]}:{explicit:!1,value:void 0}}setWithExplicit(t,{value:n,explicit:i}){n!==void 0&&this.set(t,n,i)}set(t,n,i){return delete this[i?"implicit":"explicit"][t],this[i?"explicit":"implicit"][t]=n,this}copyKeyFromSplit(t,{explicit:n,implicit:i}){n[t]!==void 0?this.set(t,n[t],!0):i[t]!==void 0&&this.set(t,i[t],!1)}copyKeyFromObject(t,n){n[t]!==void 0&&this.set(t,n[t],!0)}copyAll(t){for(const n of ye(t.combine())){const i=t.getWithExplicit(n);this.setWithExplicit(n,i)}}}function la(e){return{explicit:!0,value:e}}function vs(e){return{explicit:!1,value:e}}function WG(e){return(t,n,i,s)=>{const o=e(t.value,n.value);return o>0?t:o<0?n:_6(t,n,i,s)}}function _6(e,t,n,i){return e.explicit&&t.explicit&&me(X5e(n,i,e.value,t.value)),e}function fc(e,t,n,i,s=_6){return e===void 0||e.value===void 0?t:e.explicit&&!t.explicit?e:t.explicit&&!e.explicit?t:ba(e.value,t.value)?e:s(e,t,n,i)}class g7e extends ll{constructor(t={},n={},i=!1){super(t,n),this.explicit=t,this.implicit=n,this.parseNothing=i}clone(){const t=super.clone();return t.parseNothing=this.parseNothing,t}}function gh(e){return"url"in e}function e0(e){return"values"in e}function YG(e){return"name"in e&&!gh(e)&&!e0(e)&&!Vl(e)}function Vl(e){return e&&(XG(e)||KG(e)||CS(e))}function XG(e){return"sequence"in e}function KG(e){return"sphere"in e}function CS(e){return"graticule"in e}var en;(function(e){e[e.Raw=0]="Raw",e[e.Main=1]="Main",e[e.Row=2]="Row",e[e.Column=3]="Column",e[e.Lookup=4]="Lookup"})(en||(en={}));var _7e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sQd(s,t,n));return t?`[${i.join(", ")}]`:i}else if(Tf(e))return n(t?Q2(e):LLe(e));return t?n(tn(e)):e}function p7e(e,t){var n;for(const i of Ti((n=e.component.selection)!==null&&n!==void 0?n:{})){const s=i.name;let o=`${s}${gc}, ${i.resolve==="global"?"true":`{unit: ${_h(e)}}`}`;for(const c of y6)c.defined(i)&&(c.signals&&(t=c.signals(e,i,t)),c.modifyExpr&&(o=c.modifyExpr(e,i,o)));t.push({name:s+X7e,on:[{events:{signal:i.name+gc},update:`modify(${Te(i.name+ef)}, ${o})`}]})}return RS(t)}function y7e(e,t){if(e.component.selection&&ye(e.component.selection).length){const n=Te(e.getName("cell"));t.unshift({name:"facet",value:{},on:[{events:xc("mousemove","scope"),update:`isTuple(facet) ? facet : group(${n}).datum`}]})}return RS(t)}function m7e(e,t){var n;let i=!1;for(const s of Ti((n=e.component.selection)!==null&&n!==void 0?n:{})){const o=s.name,c=Te(o+ef);if(t.filter(f=>f.name===o).length===0){const f=s.resolve==="global"?"union":s.resolve,u=s.type==="point"?", true, true)":")";t.push({name:s.name,update:`${uW}(${c}, ${Te(f)}${u}`})}i=!0;for(const f of y6)f.defined(s)&&f.topLevelSignals&&(t=f.topLevelSignals(e,s,t))}return i&&t.filter(o=>o.name==="unit").length===0&&t.unshift({name:"unit",value:{},on:[{events:"mousemove",update:"isTuple(group()) ? group() : unit"}]}),RS(t)}function w7e(e,t){var n;const i=[...t],s=_h(e,{escape:!1});for(const o of Ti((n=e.component.selection)!==null&&n!==void 0?n:{})){const c={name:o.name+ef};if(o.project.hasSelectionId&&(c.transform=[{type:"collect",sort:{field:Va}}]),o.init){const f=o.project.items.map(u=>_7e(u,["signals"]));c.values=o.project.hasSelectionId?o.init.map(u=>({unit:s,[Va]:Qd(u,!1)[0]})):o.init.map(u=>({unit:s,fields:f,values:Qd(u,!1)}))}i.filter(f=>f.name===o.name+ef).length||i.push(c)}return i}function ZG(e,t){var n;for(const i of Ti((n=e.component.selection)!==null&&n!==void 0?n:{}))for(const s of y6)s.defined(i)&&s.marks&&(t=s.marks(e,i,t));return t}function L7e(e,t){for(const n of e.children)Ln(n)&&(t=ZG(n,t));return t}function b7e(e,t,n,i){const s=yW(e,t.param,t);return{signal:Us(n.get("type"))&&ue(i)&&i[0]>i[1]?`isValid(${s}) && reverse(${s})`:s}}function RS(e){return e.map(t=>(t.on&&!t.on.length&&delete t.on,t))}class Kt{constructor(t,n){this.debugName=n,this._children=[],this._parent=null,t&&(this.parent=t)}clone(){throw new Error("Cannot clone node")}get parent(){return this._parent}set parent(t){this._parent=t,t&&t.addChild(this)}get children(){return this._children}numChildren(){return this._children.length}addChild(t,n){if(this._children.includes(t)){me(b5e);return}n!==void 0?this._children.splice(n,0,t):this._children.push(t)}removeChild(t){const n=this._children.indexOf(t);return this._children.splice(n,1),n}remove(){let t=this._parent.removeChild(this);for(const n of this._children)n._parent=this._parent,this._parent.addChild(n,t++)}insertAsParentOf(t){const n=t.parent;n.removeChild(this),this.parent=n,t.parent=this}swapWithParent(){const t=this._parent,n=t.parent;for(const s of this._children)s.parent=t;this._children=[],t.removeChild(this);const i=t.parent.removeChild(t);this._parent=n,n.addChild(this,i),t.parent=this}}class Ui extends Kt{clone(){const t=new this.constructor;return t.debugName=`clone_${this.debugName}`,t._source=this._source,t._name=`clone_${this._name}`,t.type=this.type,t.refCounts=this.refCounts,t.refCounts[t._name]=0,t}constructor(t,n,i,s){super(t,n),this.type=i,this.refCounts=s,this._source=this._name=n,this.refCounts&&!(this._name in this.refCounts)&&(this.refCounts[this._name]=0)}dependentFields(){return new Set}producedFields(){return new Set}hash(){return this._hash===void 0&&(this._hash=`Output ${Zq()}`),this._hash}getSource(){return this.refCounts[this._name]++,this._source}isRequired(){return!!this.refCounts[this._name]}setSource(t){this._source=t}}var MM=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{const{field:c,timeUnit:d}=o;if(d){const f=ve(o,{forAs:!0});s[Bt({as:f,field:c,timeUnit:d})]={as:f,field:c,timeUnit:d}}return s},{});return Wt(i)?null:new Fa(t,i)}static makeFromTransform(t,n){const i=Object.assign({},n),{timeUnit:s}=i,o=MM(i,["timeUnit"]),c=xi(s),d=Object.assign(Object.assign({},o),{timeUnit:c});return new Fa(t,{[Bt(d)]:d})}merge(t){this.formula=Object.assign({},this.formula);for(const n in t.formula)this.formula[n]||(this.formula[n]=t.formula[n]);for(const n of t.children)t.removeChild(n),n.parent=this;t.remove()}removeFormulas(t){const n={};for(const[i,s]of cc(this.formula))t.has(s.as)||(n[i]=s);this.formula=n}producedFields(){return new Set(Ti(this.formula).map(t=>t.as))}dependentFields(){return new Set(Ti(this.formula).map(t=>t.field))}hash(){return`TimeUnit ${Bt(this.formula)}`}assemble(){const t=[];for(const n of Ti(this.formula)){const{field:i,as:s,timeUnit:o}=n,c=xi(o),{unit:d,utc:f}=c,u=MM(c,["unit","utc"]);t.push(Object.assign(Object.assign(Object.assign(Object.assign({field:ar(i),type:"timeunit"},d?{units:QE(d)}:{}),f?{timezone:"utc"}:{}),u),{as:[s,`${s}_end`]}))}return t}}var T7e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s!0,parse:(e,t,n)=>{var i;const s=t.name,o=(i=t.project)!==null&&i!==void 0?i:t.project=new v7e,c={},d={},f=new Set,u=(b,L)=>{const E=L==="visual"?b.channel:b.field;let S=dn(`${s}_${E}`);for(let x=1;f.has(S);x++)S=dn(`${s}_${E}_${x}`);return f.add(S),{[L]:S}},a=t.type,m=e.config.selection[a],y=n.value!==void 0?Se(n.value):null;let{fields:p,encodings:l}=ke(n.select)?n.select:{};if(!p&&!l&&y){for(const b of y)if(ke(b))for(const L of ye(b))Rwe(L)?(l||(l=[])).push(L):a==="interval"?(me(y5e),l=m.encodings):(p||(p=[])).push(L)}!p&&!l&&(l=m.encodings,"fields"in m&&(p=m.fields));for(const b of l??[]){const L=e.fieldDef(b);if(L){let E=L.field;if(L.aggregate){me(c5e(b,L.aggregate));continue}else if(!E){me(sM(b));continue}if(L.timeUnit){E=e.vgField(b);const S={timeUnit:L.timeUnit,as:E,field:L.field};d[Bt(S)]=S}if(!c[E]){let S="E";if(a==="interval"){const F=e.getScaleComponent(b).get("type");Us(F)&&(S="R")}else L.bin&&(S="R-RE");const x={field:E,channel:b,type:S};x.signals=Object.assign(Object.assign({},u(x,"data")),u(x,"visual")),o.items.push(c[E]=x),o.hasField[E]=o.hasChannel[b]=c[E],o.hasSelectionId=o.hasSelectionId||E===Va}}else me(sM(b))}for(const b of p??[]){if(o.hasField[b])continue;const L={type:"E",field:b};L.signals=Object.assign({},u(L,"data")),o.items.push(L),o.hasField[b]=L,o.hasSelectionId=o.hasSelectionId||b===Va}y&&(t.init=y.map(b=>o.items.map(L=>ke(b)?b[L.channel]!==void 0?b[L.channel]:b[L.field]:b))),Wt(d)||(o.timeUnit=new Fa(null,d))},signals:(e,t,n)=>{const i=t.name+f3;return n.filter(o=>o.name===i).length>0||t.project.hasSelectionId?n:n.concat({name:i,value:t.project.items.map(o=>{const c=T7e(o,["signals","hasLegend"]);return c.field=ar(c.field),c})})}},uc={defined:e=>e.type==="interval"&&e.resolve==="global"&&e.bind&&e.bind==="scales",parse:(e,t)=>{const n=t.scales=[];for(const i of t.project.items){const s=i.channel;if(!Mc(s))continue;const o=e.getScaleComponent(s),c=o?o.get("type"):void 0;if(!o||!Us(c)){me(u5e);continue}o.set("selectionExtent",{param:t.name,field:i.field},!0),n.push(i)}},topLevelSignals:(e,t,n)=>{const i=t.scales.filter(c=>n.filter(d=>d.name===c.signals.data).length===0);if(!e.parent||K8(e)||i.length===0)return n;const s=n.filter(c=>c.name===t.name)[0];let o=s.update;if(o.indexOf(uW)>=0)s.update=`{${i.map(c=>`${Te(ar(c.field))}: ${c.signals.data}`).join(", ")}}`;else{for(const c of i){const d=`${Te(ar(c.field))}: ${c.signals.data}`;o.includes(d)||(o=`${o.substring(0,o.length-1)}, ${d}}`)}s.update=o}return n.concat(i.map(c=>({name:c.signals.data})))},signals:(e,t,n)=>{if(e.parent&&!K8(e))for(const i of t.scales){const s=n.filter(o=>o.name===i.signals.data)[0];s.push="outer",delete s.value,delete s.update}return n}};function X8(e,t){return`domain(${Te(e.scaleName(t))})`}function K8(e){var t;return e.parent&&Vh(e.parent)&&((t=!e.parent.parent)!==null&&t!==void 0?t:K8(e.parent.parent))}var S7e=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);se.type==="interval",signals:(e,t,n)=>{const i=t.name,s=i+f3,o=uc.defined(t),c=t.init?t.init[0]:null,d=[],f=[];if(t.translate&&!o){const a=`!event.item || event.item.mark.name !== ${Te(i+Eu)}`;JG(t,(m,y)=>{var p,l;const b=Se((p=(l=y.between[0]).filter)!==null&&p!==void 0?p:l.filter=[]);return b.includes(a)||b.push(a),m})}t.project.items.forEach((a,m)=>{const y=a.channel;if(y!==hn&&y!==Kn){me("Interval selections only support x and y encoding channels.");return}const p=c?c[m]:null,l=k7e(e,t,a,p),b=a.signals.data,L=a.signals.visual,E=Te(e.scaleName(y)),S=e.getScaleComponent(y).get("type"),x=Us(S)?"+":"";n.push(...l),d.push(b),f.push({scaleName:e.scaleName(y),expr:`(!isArray(${b}) || (${x}invert(${E}, ${L})[0] === ${x}${b}[0] && ${x}invert(${E}, ${L})[1] === ${x}${b}[1]))`})}),!o&&f.length&&n.push({name:i+Z8,value:{},on:[{events:f.map(a=>({scale:a.scaleName})),update:`${f.map(a=>a.expr).join(" && ")} ? ${i+Z8} : {}`}]});const u=`unit: ${_h(e)}, fields: ${s}, values`;return n.concat(Object.assign(Object.assign({name:i+gc},c?{init:`{${u}: ${Qd(c)}}`}:{}),d.length?{on:[{events:[{signal:d.join(" || ")}],update:`${d.join(" && ")} ? {${u}: [${d}]} : null`}]}:{}))},marks:(e,t,n)=>{const i=t.name,{x:s,y:o}=t.project.hasChannel,c=s==null?void 0:s.signals.visual,d=o==null?void 0:o.signals.visual,f=`data(${Te(t.name+ef)})`;if(uc.defined(t)||!s&&!o)return n;const u={x:s!==void 0?{signal:`${c}[0]`}:{value:0},y:o!==void 0?{signal:`${d}[0]`}:{value:0},x2:s!==void 0?{signal:`${c}[1]`}:{field:{group:"width"}},y2:o!==void 0?{signal:`${d}[1]`}:{field:{group:"height"}}};if(t.resolve==="global")for(const L of ye(u))u[L]=[Object.assign({test:`${f}.length && ${f}[0].unit === ${_h(e)}`},u[L]),{value:0}];const a=t.mark,{fill:m,fillOpacity:y,cursor:p}=a,l=S7e(a,["fill","fillOpacity","cursor"]),b=ye(l).reduce((L,E)=>(L[E]=[{test:[s!==void 0&&`${c}[0] !== ${c}[1]`,o!==void 0&&`${d}[0] !== ${d}[1]`].filter(S=>S).join(" && "),value:l[E]},{value:null}],L),{});return[{name:`${i+Eu}_bg`,type:"rect",clip:!0,encode:{enter:{fill:{value:m},fillOpacity:{value:y}},update:u}},...n,{name:i+Eu,type:"rect",clip:!0,encode:{enter:Object.assign(Object.assign({},p?{cursor:{value:p}}:{}),{fill:{value:"transparent"}}),update:Object.assign(Object.assign({},u),b)}}]}};function k7e(e,t,n,i){const s=n.channel,o=n.signals.visual,c=n.signals.data,d=uc.defined(t),f=Te(e.scaleName(s)),u=e.getScaleComponent(s),a=u?u.get("type"):void 0,m=b=>`scale(${f}, ${b})`,y=e.getSizeSignalRef(s===hn?"width":"height").signal,p=`${s}(unit)`,l=JG(t,(b,L)=>[...b,{events:L.between[0],update:`[${p}, ${p}]`},{events:L,update:`[${o}[0], clamp(${p}, 0, ${y})]`}]);return l.push({events:{signal:t.name+Z8},update:Us(a)?`[${m(`${c}[0]`)}, ${m(`${c}[1]`)}]`:"[0, 0]"}),d?[{name:c,on:[]}]:[Object.assign(Object.assign({name:o},i?{init:Qd(i,!0,m)}:{value:[]}),{on:l}),Object.assign(Object.assign({name:c},i?{init:Qd(i)}:{}),{on:[{events:{signal:o},update:`${o}[0] === ${o}[1] ? null : invert(${f}, ${o})`}]})]}function JG(e,t){return e.events.reduce((n,i)=>i.between?t(n,i):(me(`${i} is not an ordered event stream for interval selections.`),n),[])}const B7e={defined:e=>e.type==="point",signals:(e,t,n)=>{var i;const s=t.name,o=s+f3,c=t.project,d="(item().isVoronoi ? datum.datum : datum)",f=Ti((i=e.component.selection)!==null&&i!==void 0?i:{}).reduce((y,p)=>p.type==="interval"?y.concat(p.name+Eu):y,[]).map(y=>`indexof(item().mark.name, '${y}') < 0`).join(" && "),u=`datum && item().mark.marktype !== 'group' && indexof(item().mark.role, 'legend') < 0${f?` && ${f}`:""}`;let a=`unit: ${_h(e)}, `;if(t.project.hasSelectionId)a+=`${Va}: ${d}[${Te(Va)}]`;else{const y=c.items.map(p=>{const l=e.fieldDef(p.channel);return l!=null&&l.bin?`[${d}[${Te(e.vgField(p.channel,{}))}], ${d}[${Te(e.vgField(p.channel,{binSuffix:"end"}))}]]`:`${d}[${Te(p.field)}]`}).join(", ");a+=`fields: ${o}, values: [${y}]`}const m=t.events;return n.concat([{name:s+gc,on:m?[{events:m,update:`${u} ? {${a}} : null`,force:!0}]:[]}])}};function Hh(e,t,n,i){const s=o6(t)&&t.condition,o=i(t);if(s){const d=Se(s).map(f=>{const u=i(f);if(y8e(f)){const{param:a,empty:m}=f,y=pW(e,{param:a,empty:m});return Object.assign({test:y},u)}else{const a=n4(e,f.test);return Object.assign({test:a},u)}});return{[n]:[...d,...o!==void 0?[o]:[]]}}else return o!==void 0?{[n]:o}:{}}function PS(e,t="text"){const n=e.encoding[t];return Hh(e,n,t,i=>p6(i,e.config))}function p6(e,t,n="datum"){if(e){if(Vr(e))return on(e.value);if(Je(e)){const{format:i,formatType:s}=Xy(e);return pS({fieldOrDatumDef:e,format:i,formatType:s,expr:n,config:t})}}}function QG(e,t={}){const{encoding:n,markDef:i,config:s,stack:o}=e,c=n.tooltip;if(ue(c))return{tooltip:AM({tooltip:c},o,s,t)};{const d=t.reactiveGeom?"datum.datum":"datum";return Hh(e,c,"tooltip",f=>{const u=p6(f,s,d);if(u)return u;if(f===null)return;let a=qt("tooltip",i,s);if(a===!0&&(a={content:"encoding"}),xe(a))return{value:a};if(ke(a))return Ne(a)?a:a.content==="encoding"?AM(n,o,s,t):{signal:d}})}}function eW(e,t,n,{reactiveGeom:i}={}){const s={},o=i?"datum.datum":"datum",c=[];function d(u,a){const m=Lf(a),y=lr(u)?u:Object.assign(Object.assign({},u),{type:e[m].type}),p=y.title||LS(y,n),l=Se(p).join(", ");let b;if(Zn(a)){const L=a==="x"?"x2":"y2",E=qa(e[L]);if(ei(y.bin)&&E){const S=ve(y,{expr:o}),x=ve(E,{expr:o}),{format:F,formatType:k}=Xy(y);b=a3(S,x,F,k,n),s[L]=!0}}if((Zn(a)||a===dr||a===Qr)&&t&&t.fieldChannel===a&&t.offset==="normalize"){const{format:L,formatType:E}=Xy(y);b=pS({fieldOrDatumDef:y,format:L,formatType:E,expr:o,config:n,normalizeStack:!0}).signal}b??(b=p6(y,n,o).signal),c.push({channel:a,key:l,value:b})}vS(e,(u,a)=>{we(u)?d(u,a):l6(u)&&d(u.condition,a)});const f={};for(const{channel:u,key:a,value:m}of c)!s[u]&&!f[a]&&(f[a]=m);return f}function AM(e,t,n,{reactiveGeom:i}={}){const s=eW(e,t,n,{reactiveGeom:i}),o=cc(s).map(([c,d])=>`"${c}": ${d}`);return o.length>0?{signal:`{${o.join(", ")}}`}:void 0}function F7e(e){const{markDef:t,config:n}=e,i=qt("aria",t,n);return i===!1?{}:Object.assign(Object.assign(Object.assign({},i?{aria:i}:{}),I7e(e)),O7e(e))}function I7e(e){const{mark:t,markDef:n,config:i}=e;if(i.aria===!1)return{};const s=qt("ariaRoleDescription",n,i);return s!=null?{ariaRoleDescription:{value:s}}:t in r5e?{}:{ariaRoleDescription:{value:t}}}function O7e(e){const{encoding:t,markDef:n,config:i,stack:s}=e,o=t.description;if(o)return Hh(e,o,"description",f=>p6(f,e.config));const c=qt("description",n,i);if(c!=null)return{description:on(c)};if(i.aria===!1)return{};const d=eW(t,s,i);if(!Wt(d))return{description:{signal:cc(d).map(([f,u],a)=>`"${a>0?"; ":""}${f}: " + (${u})`).join(" + ")}}}function zn(e,t,n={}){const{markDef:i,encoding:s,config:o}=t,{vgChannel:c}=n;let{defaultRef:d,defaultValue:f}=n;d===void 0&&(f??(f=qt(e,i,o,{vgChannel:c,ignoreVgConfig:!0})),f!==void 0&&(d=on(f)));const u=s[e];return Hh(t,u,c??e,a=>_S({channel:e,channelDef:a,markDef:i,config:o,scaleName:t.scaleName(e),scale:t.getScaleComponent(e),stack:null,defaultRef:d}))}function tW(e,t={filled:void 0}){var n,i,s,o;const{markDef:c,encoding:d,config:f}=e,{type:u}=c,a=(n=t.filled)!==null&&n!==void 0?n:qt("filled",c,f),m=vt(["bar","point","circle","square","geoshape"],u)?"transparent":void 0,y=(s=(i=qt(a===!0?"color":void 0,c,f,{vgChannel:"fill"}))!==null&&i!==void 0?i:f.mark[a===!0&&"color"])!==null&&s!==void 0?s:m,p=(o=qt(a===!1?"color":void 0,c,f,{vgChannel:"stroke"}))!==null&&o!==void 0?o:f.mark[a===!1&&"color"],l=a?"fill":"stroke",b=Object.assign(Object.assign({},y?{fill:on(y)}:{}),p?{stroke:on(p)}:{});return c.color&&(a?c.fill:c.stroke)&&me(vV("property",{fill:"fill"in c,stroke:"stroke"in c})),Object.assign(Object.assign(Object.assign(Object.assign({},b),zn("color",e,{vgChannel:l,defaultValue:a?y:p})),zn("fill",e,{defaultValue:d.fill?y:void 0})),zn("stroke",e,{defaultValue:d.stroke?p:void 0}))}function M7e(e){const{encoding:t,mark:n}=e,i=t.order;return!Cc(n)&&Vr(i)?Hh(e,i,"zindex",s=>on(s.value)):{}}function t0({channel:e,markDef:t,encoding:n={},model:i,bandPosition:s}){const o=`${e}Offset`,c=t[o],d=n[o];if((o==="xOffset"||o==="yOffset")&&d)return{offsetType:"encoding",offset:_S({channel:o,channelDef:d,markDef:t,config:i==null?void 0:i.config,scaleName:i.scaleName(o),scale:i.getScaleComponent(o),stack:null,defaultRef:on(c),bandPosition:s})};const f=t[o];return f?{offsetType:"visual",offset:f}:{}}function pi(e,t,{defaultPos:n,vgChannel:i}){const{encoding:s,markDef:o,config:c,stack:d}=t,f=s[e],u=s[oo(e)],a=t.scaleName(e),m=t.getScaleComponent(e),{offset:y,offsetType:p}=t0({channel:e,markDef:o,encoding:s,model:t,bandPosition:.5}),l=DS({model:t,defaultPos:n,channel:e,scaleName:a,scale:m}),b=!f&&Zn(e)&&(s.latitude||s.longitude)?{field:t.getName(e)}:A7e({channel:e,channelDef:f,channel2Def:u,markDef:o,config:c,scaleName:a,scale:m,stack:d,offset:y,defaultRef:l,bandPosition:p==="encoding"?0:void 0});return b?{[i||e]:b}:void 0}function A7e(e){const{channel:t,channelDef:n,scaleName:i,stack:s,offset:o,markDef:c}=e;if(Je(n)&&s&&t===s.fieldChannel){if(we(n)){let d=n.bandPosition;if(d===void 0&&c.type==="text"&&(t==="radius"||t==="theta")&&(d=.5),d!==void 0)return Wy({scaleName:i,fieldOrDatumDef:n,startSuffix:"start",bandPosition:d,offset:o})}return kd(n,i,{suffix:"end"},{offset:o})}return hS(e)}function DS({model:e,defaultPos:t,channel:n,scaleName:i,scale:s}){const{markDef:o,config:c}=e;return()=>{const d=Lf(n),f=dc(n),u=qt(n,o,c,{vgChannel:f});if(u!==void 0)return d2(n,u);switch(t){case"zeroOrMin":case"zeroOrMax":if(i){const a=s.get("type");if(!vt([os.LOG,os.TIME,os.UTC],a)){if(s.domainDefinitelyIncludesZero())return{scale:i,value:0}}}if(t==="zeroOrMin")return d==="y"?{field:{group:"height"}}:{value:0};switch(d){case"radius":return{signal:`min(${e.width.signal},${e.height.signal})/2`};case"theta":return{signal:"2*PI"};case"x":return{field:{group:"width"}};case"y":return{value:0}}break;case"mid":{const a=e[ms(n)];return Object.assign(Object.assign({},a),{mult:.5})}}}}const N7e={left:"x",center:"xc",right:"x2"},C7e={top:"y",middle:"yc",bottom:"y2"};function nW(e,t,n,i="middle"){if(e==="radius"||e==="theta")return dc(e);const s=e==="x"?"align":"baseline",o=qt(s,t,n);let c;return Ne(o)?(me(D5e(s)),c=void 0):c=o,e==="x"?N7e[c||(i==="top"?"left":"center")]:C7e[c||i]}function e4(e,t,{defaultPos:n,defaultPos2:i,range:s}){return s?iW(e,t,{defaultPos:n,defaultPos2:i}):pi(e,t,{defaultPos:n})}function iW(e,t,{defaultPos:n,defaultPos2:i}){const{markDef:s,config:o}=t,c=oo(e),d=ms(e),f=R7e(t,i,c),u=f[d]?nW(e,s,o):dc(e);return Object.assign(Object.assign({},pi(e,t,{defaultPos:n,vgChannel:u})),f)}function R7e(e,t,n){const{encoding:i,mark:s,markDef:o,stack:c,config:d}=e,f=Lf(n),u=ms(n),a=dc(n),m=i[f],y=e.scaleName(f),p=e.getScaleComponent(f),{offset:l}=n in i||n in o?t0({channel:n,markDef:o,encoding:i,model:e}):t0({channel:f,markDef:o,encoding:i,model:e});if(!m&&(n==="x2"||n==="y2")&&(i.latitude||i.longitude)){const L=ms(n),E=e.markDef[L];return E!=null?{[L]:{value:E}}:{[a]:{field:e.getName(n)}}}const b=P7e({channel:n,channelDef:m,channel2Def:i[n],markDef:o,config:d,scaleName:y,scale:p,stack:c,offset:l,defaultRef:void 0});return b!==void 0?{[a]:b}:c_(n,o)||c_(n,{[n]:qy(n,o,d.style),[u]:qy(u,o,d.style)})||c_(n,d[s])||c_(n,d.mark)||{[a]:DS({model:e,defaultPos:t,channel:n,scaleName:y,scale:p})()}}function P7e({channel:e,channelDef:t,channel2Def:n,markDef:i,config:s,scaleName:o,scale:c,stack:d,offset:f,defaultRef:u}){return Je(t)&&d&&e.charAt(0)===d.fieldChannel.charAt(0)?kd(t,o,{suffix:"start"},{offset:f}):hS({channel:e,channelDef:n,scaleName:o,scale:c,stack:d,markDef:i,config:s,offset:f,defaultRef:u})}function c_(e,t){const n=ms(e),i=dc(e);if(t[i]!==void 0)return{[i]:d2(e,t[i])};if(t[e]!==void 0)return{[i]:d2(e,t[e])};if(t[n]){const s=t[n];if(Zd(s))me(O5e(n));else return{[n]:d2(e,s)}}}function hc(e,t){var n,i;const{config:s,encoding:o,markDef:c}=e,d=c.type,f=oo(t),u=ms(t),a=o[t],m=o[f],y=e.getScaleComponent(t),p=y?y.get("type"):void 0,l=c.orient,b=(i=(n=o[u])!==null&&n!==void 0?n:o.size)!==null&&i!==void 0?i:qt("size",c,s,{vgChannel:u}),L=d==="bar"&&(t==="x"?l==="vertical":l==="horizontal");return we(a)&&(nn(a.bin)||ei(a.bin)||a.timeUnit&&!m)&&!(b&&!Zd(b))&&!Jn(p)?U7e({fieldDef:a,fieldDef2:m,channel:t,model:e}):(Je(a)&&Jn(p)||L)&&!m?j7e(a,t,e):iW(t,e,{defaultPos:"zeroOrMax",defaultPos2:"zeroOrMin"})}function D7e(e,t,n,i,s){if(Zd(s))if(n){const c=n.get("type");if(c==="band"){let d=`bandwidth('${t}')`;return s.band!==1&&(d=`${s.band} * ${d}`),{signal:`max(0.25, ${d})`}}else s.band!==1&&(me(z5e(c)),s=void 0)}else return{mult:s.band,field:{group:e}};else{if(Ne(s))return s;if(s)return{value:s}}if(n){const c=n.get("range");if(Nc(c)&&Yt(c.step))return{value:c.step-2}}return{value:Jy(i.view,e)-2}}function j7e(e,t,n){const{markDef:i,encoding:s,config:o,stack:c}=n,d=i.orient,f=n.scaleName(t),u=n.getScaleComponent(t),a=ms(t),m=oo(t),y=Dwe(t),p=n.scaleName(y),l=d==="horizontal"&&t==="y"||d==="vertical"&&t==="x";let b;(s.size||i.size)&&(l?b=zn("size",n,{vgChannel:a,defaultRef:on(i.size)}):me(G5e(i.type)));const L=!!b,E=nG({channel:t,fieldDef:e,markDef:i,config:o,scaleType:u==null?void 0:u.get("type"),useVlSizeChannel:l});b=b||{[a]:D7e(a,p||f,u,o,E)};const S=(u==null?void 0:u.get("type"))==="band"&&Zd(E)&&!L?"top":"middle",x=nW(t,i,o,S),F=x==="xc"||x==="yc",{offset:k,offsetType:M}=t0({channel:t,markDef:i,encoding:s,model:n,bandPosition:F?.5:0}),O=hS({channel:t,channelDef:e,markDef:i,config:o,scaleName:f,scale:u,stack:c,offset:k,defaultRef:DS({model:n,defaultPos:"mid",channel:t,scaleName:f,scale:u}),bandPosition:F?M==="encoding"?0:.5:Ne(E)?{signal:`(1-${E})/2`}:Zd(E)?(1-E.band)/2:0});if(a)return Object.assign({[x]:O},b);{const C=dc(m),P=b[a],j=k?Object.assign(Object.assign({},P),{offset:k}):P;return{[x]:O,[C]:ue(O)?[O[0],Object.assign(Object.assign({},O[1]),{offset:j})]:Object.assign(Object.assign({},O),{offset:j})}}}function _1(e,t,n,i,s){if(tV(e))return 0;const o=e==="x"||e==="y2"?-t/2:t/2;if(Ne(n)||Ne(s)||Ne(i)){const c=jo(n),d=jo(s),f=jo(i),u=f?`${f} + `:"",a=c?`(${c} ? -1 : 1) * `:"",m=d?`(${d} + ${o})`:o;return{signal:u+a+m}}else return s=s||0,i+(n?-s-o:+s+o)}function U7e({fieldDef:e,fieldDef2:t,channel:n,model:i}){var s,o,c;const{config:d,markDef:f,encoding:u}=i,a=i.getScaleComponent(n),m=i.scaleName(n),y=a?a.get("type"):void 0,p=a.get("reverse"),l=nG({channel:n,fieldDef:e,markDef:f,config:d,scaleType:y}),b=(s=i.component.axes[n])===null||s===void 0?void 0:s[0],L=(o=b==null?void 0:b.get("translate"))!==null&&o!==void 0?o:.5,E=Zn(n)&&(c=qt("binSpacing",f,d))!==null&&c!==void 0?c:0,S=oo(n),x=dc(n),F=dc(S),{offset:k}=t0({channel:n,markDef:f,encoding:u,model:i,bandPosition:0}),M=Ne(l)?{signal:`(1-${l.signal})/2`}:Zd(l)?(1-l.band)/2:.5;if(nn(e.bin)||e.timeUnit)return{[F]:NM({fieldDef:e,scaleName:m,bandPosition:M,offset:_1(S,E,p,L,k)}),[x]:NM({fieldDef:e,scaleName:m,bandPosition:Ne(M)?{signal:`1-${M.signal}`}:1-M,offset:_1(n,E,p,L,k)})};if(ei(e.bin)){const O=kd(e,m,{},{offset:_1(S,E,p,L,k)});if(we(t))return{[F]:O,[x]:kd(t,m,{},{offset:_1(n,E,p,L,k)})};if(bf(e.bin)&&e.bin.step)return{[F]:O,[x]:{signal:`scale("${m}", ${ve(e,{expr:"datum"})} + ${e.bin.step})`,offset:_1(n,E,p,L,k)}}}me(xV(S))}function NM({fieldDef:e,scaleName:t,bandPosition:n,offset:i}){return Wy({scaleName:t,fieldOrDatumDef:e,bandPosition:n,offset:i})}const H7e=new Set(["aria","width","height"]);function fr(e,t){const{fill:n=void 0,stroke:i=void 0}=t.color==="include"?tW(e):{};return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},z7e(e.markDef,t)),CM(e,"fill",n)),CM(e,"stroke",i)),zn("opacity",e)),zn("fillOpacity",e)),zn("strokeOpacity",e)),zn("strokeWidth",e)),zn("strokeDash",e)),M7e(e)),QG(e)),PS(e,"href")),F7e(e))}function CM(e,t,n){const{config:i,mark:s,markDef:o}=e;if(qt("invalid",o,i)==="hide"&&n&&!Cc(s)){const d=$7e(e,{invalid:!0,channels:Jm});if(d)return{[t]:[{test:d,value:null},...Se(n)]}}return n?{[t]:n}:{}}function z7e(e,t){return s5e.reduce((n,i)=>(!H7e.has(i)&&e[i]!==void 0&&t[i]!=="ignore"&&(n[i]=on(e[i])),n),{})}function $7e(e,{invalid:t=!1,channels:n}){const i=n.reduce((o,c)=>{const d=e.getScaleComponent(c);if(d){const f=d.get("type"),u=e.vgField(c,{expr:"datum"});u&&Us(f)&&(o[u]=!0)}return o},{}),s=ye(i);if(s.length>0){const o=t?"||":"&&";return s.map(c=>gS(c,t)).join(` ${o} `)}}function jS(e){const{config:t,markDef:n}=e;if(qt("invalid",n,t)){const s=q7e(e,{channels:lo});if(s)return{defined:{signal:s}}}return{}}function q7e(e,{invalid:t=!1,channels:n}){const i=n.reduce((o,c)=>{var d;const f=e.getScaleComponent(c);if(f){const u=f.get("type"),a=e.vgField(c,{expr:"datum",binSuffix:!((d=e.stack)===null||d===void 0)&&d.impute?"mid":void 0});a&&Us(u)&&(o[a]=!0)}return o},{}),s=ye(i);if(s.length>0){const o=t?"||":"&&";return s.map(c=>gS(c,t)).join(` ${o} `)}}function RM(e,t){if(t!==void 0)return{[e]:on(t)}}const c5="voronoi",sW={defined:e=>e.type==="point"&&e.nearest,parse:(e,t)=>{if(t.events)for(const n of t.events)n.markname=e.getName(c5)},marks:(e,t,n)=>{const{x:i,y:s}=t.project.hasChannel,o=e.mark;if(Cc(o))return me(d5e(o)),n;const c={name:e.getName(c5),type:"path",interactive:!0,from:{data:e.getName("marks")},encode:{update:Object.assign({fill:{value:"transparent"},strokeWidth:{value:.35},stroke:{value:"transparent"},isVoronoi:{value:!0}},QG(e,{reactiveGeom:!0}))},transform:[{type:"voronoi",x:{expr:i||!s?"datum.datum.x || 0":"0"},y:{expr:s||!i?"datum.datum.y || 0":"0"},size:[e.getSizeSignalRef("width"),e.getSizeSignalRef("height")]}]};let d=0,f=!1;return n.forEach((u,a)=>{var m;const y=(m=u.name)!==null&&m!==void 0?m:"";y===e.component.mark[0].name?d=a:y.indexOf(c5)>=0&&(f=!0)}),f||n.splice(d+1,0,c),n}},rW={defined:e=>e.type==="point"&&e.resolve==="global"&&e.bind&&e.bind!=="scales"&&!FS(e.bind),parse:(e,t,n)=>hW(t,n),topLevelSignals:(e,t,n)=>{const i=t.name,s=t.project,o=t.bind,c=t.init&&t.init[0],d=sW.defined(t)?"(item().isVoronoi ? datum.datum : datum)":"datum";return s.items.forEach((f,u)=>{var a,m;const y=dn(`${i}_${f.field}`);n.filter(l=>l.name===y).length||n.unshift(Object.assign(Object.assign({name:y},c?{init:Qd(c[u])}:{value:null}),{on:t.events?[{events:t.events,update:`datum && item().mark.marktype !== 'group' ? ${d}[${Te(f.field)}] : null`}]:[],bind:(m=(a=o[f.field])!==null&&a!==void 0?a:o[f.channel])!==null&&m!==void 0?m:o}))}),n},signals:(e,t,n)=>{const i=t.name,s=t.project,o=n.filter(u=>u.name===i+gc)[0],c=i+f3,d=s.items.map(u=>dn(`${i}_${u.field}`)),f=d.map(u=>`${u} !== null`).join(" && ");return d.length&&(o.update=`${f} ? {fields: ${c}, values: [${d.join(", ")}]} : null`),delete o.value,delete o.on,n}},t4="_toggle",aW={defined:e=>e.type==="point"&&!!e.toggle,signals:(e,t,n)=>n.concat({name:t.name+t4,value:!1,on:[{events:t.events,update:t.toggle}]}),modifyExpr:(e,t)=>{const n=t.name+gc,i=t.name+t4;return`${i} ? null : ${n}, `+(t.resolve==="global"?`${i} ? null : true, `:`${i} ? null : {unit: ${_h(e)}}, `)+`${i} ? ${n} : null`}},V7e={defined:e=>e.clear!==void 0&&e.clear!==!1,parse:(e,t)=>{t.clear&&(t.clear=xe(t.clear)?xc(t.clear,"view"):t.clear)},topLevelSignals:(e,t,n)=>{if(rW.defined(t))for(const i of t.project.items){const s=n.findIndex(o=>o.name===dn(`${t.name}_${i.field}`));s!==-1&&n[s].on.push({events:t.clear,update:"null"})}return n},signals:(e,t,n)=>{function i(s,o){s!==-1&&n[s].on&&n[s].on.push({events:t.clear,update:o})}if(t.type==="interval")for(const s of t.project.items){const o=n.findIndex(c=>c.name===s.signals.visual);if(i(o,"[0, 0]"),o===-1){const c=n.findIndex(d=>d.name===s.signals.data);i(c,"null")}}else{let s=n.findIndex(o=>o.name===t.name+gc);i(s,"null"),aW.defined(t)&&(s=n.findIndex(o=>o.name===t.name+t4),i(s,"false"))}return n}},oW={defined:e=>{const t=e.resolve==="global"&&e.bind&&FS(e.bind),n=e.project.items.length===1&&e.project.items[0].field!==Va;return t&&!n&&me(h5e),t&&n},parse:(e,t,n)=>{var i;const s=at(n);if(s.select=xe(s.select)?{type:s.select,toggle:t.toggle}:Object.assign(Object.assign({},s.select),{toggle:t.toggle}),hW(t,s),ke(n.select)&&(n.select.on||n.select.clear)){const d='event.item && indexof(event.item.mark.role, "legend") < 0';for(const f of t.events)f.filter=Se((i=f.filter)!==null&&i!==void 0?i:[]),f.filter.includes(d)||f.filter.push(d)}const o=a5(t.bind)?t.bind.legend:"click",c=xe(o)?xc(o,"view"):Se(o);t.bind={legend:{merge:c}}},topLevelSignals:(e,t,n)=>{const i=t.name,s=a5(t.bind)&&t.bind.legend,o=c=>d=>{const f=at(d);return f.markname=c,f};for(const c of t.project.items){if(!c.hasLegend)continue;const d=`${dn(c.field)}_legend`,f=`${i}_${d}`;if(n.filter(a=>a.name===f).length===0){const a=s.merge.map(o(`${d}_symbols`)).concat(s.merge.map(o(`${d}_labels`))).concat(s.merge.map(o(`${d}_entries`)));n.unshift(Object.assign(Object.assign({name:f},t.init?{}:{value:null}),{on:[{events:a,update:"datum.value || item().items[0].items[0].datum.value",force:!0},{events:s.merge,update:`!event.item || !datum ? null : ${f}`,force:!0}]}))}}return n},signals:(e,t,n)=>{const i=t.name,s=t.project,o=n.find(y=>y.name===i+gc),c=i+f3,d=s.items.filter(y=>y.hasLegend).map(y=>dn(`${i}_${dn(y.field)}_legend`)),u=`${d.map(y=>`${y} !== null`).join(" && ")} ? {fields: ${c}, values: [${d.join(", ")}]} : null`;t.events&&d.length>0?o.on.push({events:d.map(y=>({signal:y})),update:u}):d.length>0&&(o.update=u,delete o.value,delete o.on);const a=n.find(y=>y.name===i+t4),m=a5(t.bind)&&t.bind.legend;return a&&(t.events?a.on.push(Object.assign(Object.assign({},a.on[0]),{events:m})):a.on[0].events=m),n}};function G7e(e,t,n){var i,s,o,c;const d=(i=e.fieldDef(t))===null||i===void 0?void 0:i.field;for(const f of Ti((s=e.component.selection)!==null&&s!==void 0?s:{})){const u=(o=f.project.hasField[d])!==null&&o!==void 0?o:f.project.hasChannel[t];if(u&&oW.defined(f)){const a=(c=n.get("selections"))!==null&&c!==void 0?c:[];a.push(f.name),n.set("selections",a,!1),u.hasLegend=!0}}}const lW="_translate_anchor",cW="_translate_delta",W7e={defined:e=>e.type==="interval"&&e.translate,signals:(e,t,n)=>{const i=t.name,s=uc.defined(t),o=i+lW,{x:c,y:d}=t.project.hasChannel;let f=xc(t.translate,"scope");return s||(f=f.map(u=>(u.between[0].markname=i+Eu,u))),n.push({name:o,value:{},on:[{events:f.map(u=>u.between[0]),update:"{x: x(unit), y: y(unit)"+(c!==void 0?`, extent_x: ${s?X8(e,hn):`slice(${c.signals.visual})`}`:"")+(d!==void 0?`, extent_y: ${s?X8(e,Kn):`slice(${d.signals.visual})`}`:"")+"}"}]},{name:i+cW,value:{},on:[{events:f,update:`{x: ${o}.x - x(unit), y: ${o}.y - y(unit)}`}]}),c!==void 0&&PM(e,t,c,"width",n),d!==void 0&&PM(e,t,d,"height",n),n}};function PM(e,t,n,i,s){var o,c;const d=t.name,f=d+lW,u=d+cW,a=n.channel,m=uc.defined(t),y=s.filter(O=>O.name===n.signals[m?"data":"visual"])[0],p=e.getSizeSignalRef(i).signal,l=e.getScaleComponent(a),b=l.get("type"),L=l.get("reverse"),E=m?a===hn?L?"":"-":L?"-":"":"",S=`${f}.extent_${a}`,x=`${E}${u}.${a} / ${m?`${p}`:`span(${S})`}`,F=m?b==="log"?"panLog":b==="symlog"?"panSymlog":b==="pow"?"panPow":"panLinear":"panLinear",k=m?b==="pow"?`, ${(o=l.get("exponent"))!==null&&o!==void 0?o:1}`:b==="symlog"?`, ${(c=l.get("constant"))!==null&&c!==void 0?c:1}`:"":"",M=`${F}(${S}, ${x}${k})`;y.on.push({events:{signal:u},update:m?M:`clampRange(${M}, 0, ${p})`})}const dW="_zoom_anchor",fW="_zoom_delta",Y7e={defined:e=>e.type==="interval"&&e.zoom,signals:(e,t,n)=>{const i=t.name,s=uc.defined(t),o=i+fW,{x:c,y:d}=t.project.hasChannel,f=Te(e.scaleName(hn)),u=Te(e.scaleName(Kn));let a=xc(t.zoom,"scope");return s||(a=a.map(m=>(m.markname=i+Eu,m))),n.push({name:i+dW,on:[{events:a,update:s?"{"+[f?`x: invert(${f}, x(unit))`:"",u?`y: invert(${u}, y(unit))`:""].filter(m=>!!m).join(", ")+"}":"{x: x(unit), y: y(unit)}"}]},{name:o,on:[{events:a,force:!0,update:"pow(1.001, event.deltaY * pow(16, event.deltaMode))"}]}),c!==void 0&&DM(e,t,c,"width",n),d!==void 0&&DM(e,t,d,"height",n),n}};function DM(e,t,n,i,s){var o,c;const d=t.name,f=n.channel,u=uc.defined(t),a=s.filter(F=>F.name===n.signals[u?"data":"visual"])[0],m=e.getSizeSignalRef(i).signal,y=e.getScaleComponent(f),p=y.get("type"),l=u?X8(e,f):a.name,b=d+fW,L=`${d}${dW}.${f}`,E=u?p==="log"?"zoomLog":p==="symlog"?"zoomSymlog":p==="pow"?"zoomPow":"zoomLinear":"zoomLinear",S=u?p==="pow"?`, ${(o=y.get("exponent"))!==null&&o!==void 0?o:1}`:p==="symlog"?`, ${(c=y.get("constant"))!==null&&c!==void 0?c:1}`:"":"",x=`${E}(${l}, ${L}, ${b}${S})`;a.on.push({events:{signal:b},update:u?x:`clampRange(${x}, 0, ${m})`})}const ef="_store",gc="_tuple",X7e="_modify",uW="vlSelectionResolve",y6=[B7e,x7e,E7e,aW,rW,uc,oW,V7e,W7e,Y7e,sW];function K7e(e){let t=e.parent;for(;t&&!Ur(t);)t=t.parent;return t}function _h(e,{escape:t}={escape:!0}){let n=t?Te(e.name):e.name;const i=K7e(e);if(i){const{facet:s}=i;for(const o of Ks)s[o]&&(n+=` + '__facet_${o}_' + (facet[${Te(i.vgField(o))}])`)}return n}function US(e){var t;return Ti((t=e.component.selection)!==null&&t!==void 0?t:{}).reduce((n,i)=>n||i.project.hasSelectionId,!1)}function hW(e,t){(xe(t.select)||!t.select.on)&&delete e.events,(xe(t.select)||!t.select.clear)&&delete e.clear,(xe(t.select)||!t.select.toggle)&&delete e.toggle}function J8(e){const t=[];return e.type==="Identifier"?[e.name]:e.type==="Literal"?[e.value]:(e.type==="MemberExpression"&&(t.push(...J8(e.object)),t.push(...J8(e.property))),t)}function gW(e){return e.object.type==="MemberExpression"?gW(e.object):e.object.name==="datum"}function _W(e){const t=nE(e),n=new Set;return t.visit(i=>{i.type==="MemberExpression"&&gW(i)&&n.add(J8(i).slice(1).join("."))}),n}class zh extends Kt{clone(){return new zh(null,this.model,at(this.filter))}constructor(t,n,i){super(t),this.model=n,this.filter=i,this.expr=n4(this.model,this.filter,this),this._dependentFields=_W(this.expr)}dependentFields(){return this._dependentFields}producedFields(){return new Set}assemble(){return{type:"filter",expr:this.expr}}hash(){return`Filter ${this.expr}`}}function Z7e(e,t){var n;const i={},s=e.config.selection;if(!t||!t.length)return i;for(const o of t){const c=dn(o.name),d=o.select,f=xe(d)?d:d.type,u=ke(d)?at(d):{type:f},a=s[f];for(const y in a)y==="fields"||y==="encodings"||(y==="mark"&&(u[y]=Object.assign(Object.assign({},a[y]),u[y])),(u[y]===void 0||u[y]===!0)&&(u[y]=(n=a[y])!==null&&n!==void 0?n:u[y]));const m=i[c]=Object.assign(Object.assign({},u),{name:c,type:f,init:o.value,bind:o.bind,events:xe(u.on)?xc(u.on,"scope"):Se(at(u.on))});for(const y of y6)y.defined(m)&&y.parse&&y.parse(e,m,o)}return i}function pW(e,t,n,i="datum"){const s=xe(t)?t:t.param,o=dn(s),c=Te(o+ef);let d;try{d=e.getSelectionComponent(o,s)}catch{return`!!${o}`}if(d.project.timeUnit){const y=n??e.component.data.raw,p=d.project.timeUnit.clone();y.parent?p.insertAsParentOf(y):y.parent=p}const f=d.project.hasSelectionId?"vlSelectionIdTest(":"vlSelectionTest(",u=d.resolve==="global"?")":`, ${Te(d.resolve)})`,a=`${f}${c}, ${i}${u}`,m=`length(data(${c}))`;return t.empty===!1?`${m} && ${a}`:`!${m} || ${a}`}function yW(e,t,n){const i=dn(t),s=n.encoding;let o=n.field,c;try{c=e.getSelectionComponent(i,t)}catch{return i}if(!s&&!o)o=c.project.items[0].field,c.project.items.length>1&&me(`A "field" or "encoding" must be specified when using a selection as a scale domain. Using "field": ${Te(o)}.`);else if(s&&!o){const d=c.project.items.filter(f=>f.channel===s);!d.length||d.length>1?(o=c.project.items[0].field,me((d.length?"Multiple ":"No ")+`matching ${Te(s)} encoding found for selection ${Te(n.param)}. Using "field": ${Te(o)}.`)):o=d[0].field}return`${c.name}[${Te(ar(o))}]`}function J7e(e,t){var n;for(const[i,s]of cc((n=e.component.selection)!==null&&n!==void 0?n:{})){const o=e.getName(`lookup_${i}`);e.component.data.outputNodes[o]=s.materialized=new Ui(new zh(t,e,{param:i}),o,en.Lookup,e.component.data.outputNodeRefCounts)}}function n4(e,t,n){return c2(t,i=>xe(i)?i:BLe(i)?pW(e,i,n):NV(i))}var d_=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sLS(n,t)).join(", "):e}function d5(e,t,n,i){var s,o,c,d,f;(s=e.encode)!==null&&s!==void 0||(e.encode={}),(o=(d=e.encode)[t])!==null&&o!==void 0||(d[t]={}),(c=(f=e.encode[t]).update)!==null&&c!==void 0||(f.update={}),e.encode[t].update[n]=i}function G1(e,t,n,i={header:!1}){var s,o;const c=e.combine(),{disable:d,orient:f,scale:u,labelExpr:a,title:m,zindex:y}=c,p=d_(c,["disable","orient","scale","labelExpr","title","zindex"]);if(!d){for(const l in p){const b=O8e[l],L=p[l];if(b&&b!==t&&b!=="both")delete p[l];else if(d3(L)){const{condition:E}=L,S=d_(L,["condition"]),x=Se(E),F=_M[l];if(F){const{vgProp:k,part:M}=F,O=[...x.map(C=>{const{test:P}=C,j=d_(C,["test"]);return Object.assign({test:n4(null,P)},j)}),S];d5(p,M,k,O),delete p[l]}else if(F===null){const k={signal:x.map(M=>{const{test:O}=M,C=d_(M,["test"]);return`${n4(null,O)} ? ${eM(C)} : `}).join("")+eM(S)};p[l]=k}}else if(Ne(L)){const E=_M[l];if(E){const{vgProp:S,part:x}=E;d5(p,x,S,L),delete p[l]}}vt(["labelAlign","labelBaseline"],l)&&p[l]===null&&delete p[l]}if(t==="grid"){if(!p.grid)return;if(p.encode){const{grid:l}=p.encode;p.encode=Object.assign({},l?{grid:l}:{}),Wt(p.encode)&&delete p.encode}return Object.assign(Object.assign({scale:u,orient:f},p),{domain:!1,labels:!1,aria:!1,maxExtent:0,minExtent:0,ticks:!1,zindex:Sn(y,0)})}else{if(!i.header&&e.mainExtracted)return;if(a!==void 0){let b=a;!((o=(s=p.encode)===null||s===void 0?void 0:s.labels)===null||o===void 0)&&o.update&&Ne(p.encode.labels.update.text)&&(b=Wd(a,"datum.label",p.encode.labels.update.text.signal)),d5(p,"labels","text",{signal:b})}if(p.labelAlign===null&&delete p.labelAlign,p.encode){for(const b of fG)e.hasAxisPart(b)||delete p.encode[b];Wt(p.encode)&&delete p.encode}const l=Q7e(m,n);return Object.assign(Object.assign(Object.assign(Object.assign({scale:u,orient:f,grid:!1},l?{title:l}:{}),p),n.aria===!1?{aria:!1}:{}),{zindex:Sn(y,0)})}}}function mW(e){const{axes:t}=e.component,n=[];for(const i of lo)if(t[i]){for(const s of t[i])if(!s.get("disable")&&!s.get("gridScale")){const o=i==="x"?"height":"width",c=e.getSizeSignalRef(o).signal;o!==c&&n.push({name:o,update:c})}}return n}function ebe(e,t){const{x:n=[],y:i=[]}=e;return[...n.map(s=>G1(s,"grid",t)),...i.map(s=>G1(s,"grid",t)),...n.map(s=>G1(s,"main",t)),...i.map(s=>G1(s,"main",t))].filter(s=>s)}function jM(e,t,n,i){return Object.assign.apply(null,[{},...e.map(s=>{if(s==="axisOrient"){const o=n==="x"?"bottom":"left",c=t[n==="x"?"axisBottom":"axisLeft"]||{},d=t[n==="x"?"axisTop":"axisRight"]||{},f=new Set([...ye(c),...ye(d)]),u={};for(const a of f.values())u[a]={signal:`${i.signal} === "${o}" ? ${jo(c[a])} : ${jo(d[a])}`};return u}return t[s]})])}function tbe(e,t,n,i){const s=t==="band"?["axisDiscrete","axisBand"]:t==="point"?["axisDiscrete","axisPoint"]:DV(t)?["axisQuantitative"]:t==="time"||t==="utc"?["axisTemporal"]:[],o=e==="x"?"axisX":"axisY",c=Ne(n)?"axisOrient":`axis${Q0(n)}`,d=[...s,...s.map(u=>o+u.substr(4))],f=["axis",c,o];return{vlOnlyAxisConfig:jM(d,i,e,n),vgAxisConfig:jM(f,i,e,n),axisConfigStyle:nbe([...f,...d],i)}}function nbe(e,t){var n;const i=[{}];for(const s of e){let o=(n=t[s])===null||n===void 0?void 0:n.style;if(o){o=Se(o);for(const c of o)i.push(t.style[c])}}return Object.assign.apply(null,i)}function Q8(e,t,n,i={}){var s;const o=pV(e,n,t);if(o!==void 0)return{configFrom:"style",configValue:o};for(const c of["vlOnlyAxisConfig","vgAxisConfig","axisConfigStyle"])if(((s=i[c])===null||s===void 0?void 0:s[e])!==void 0)return{configFrom:c,configValue:i[c][e]};return{}}const UM={scale:({model:e,channel:t})=>e.scaleName(t),format:({fieldOrDatumDef:e,config:t,axis:n})=>{const{format:i,formatType:s}=n;return KV(e,e.type,i,s,t,!0)},formatType:({axis:e,fieldOrDatumDef:t,scaleType:n})=>{const{formatType:i}=e;return ZV(i,t,n)},grid:({fieldOrDatumDef:e,axis:t,scaleType:n})=>{var i;return(i=t.grid)!==null&&i!==void 0?i:ibe(n,e)},gridScale:({model:e,channel:t})=>sbe(e,t),labelAlign:({axis:e,labelAngle:t,orient:n,channel:i})=>e.labelAlign||LW(t,n,i),labelAngle:({labelAngle:e})=>e,labelBaseline:({axis:e,labelAngle:t,orient:n,channel:i})=>e.labelBaseline||wW(t,n,i),labelFlush:({axis:e,fieldOrDatumDef:t,channel:n})=>{var i;return(i=e.labelFlush)!==null&&i!==void 0?i:abe(t.type,n)},labelOverlap:({axis:e,fieldOrDatumDef:t,scaleType:n})=>{var i;return(i=e.labelOverlap)!==null&&i!==void 0?i:obe(t.type,n,we(t)&&!!t.timeUnit,we(t)?t.sort:void 0)},orient:({orient:e})=>e,tickCount:({channel:e,model:t,axis:n,fieldOrDatumDef:i,scaleType:s})=>{var o;const c=e==="x"?"width":e==="y"?"height":void 0,d=c?t.getSizeSignalRef(c):void 0;return(o=n.tickCount)!==null&&o!==void 0?o:cbe({fieldOrDatumDef:i,scaleType:s,size:d,values:n.values})},title:({axis:e,model:t,channel:n})=>{if(e.title!==void 0)return e.title;const i=bW(t,n);if(i!==void 0)return i;const s=t.typedFieldDef(n),o=n==="x"?"x2":"y2",c=t.fieldDef(o);return mV(s?[gM(s)]:[],we(c)?[gM(c)]:[])},values:({axis:e,fieldOrDatumDef:t})=>dbe(e,t),zindex:({axis:e,fieldOrDatumDef:t,mark:n})=>{var i;return(i=e.zindex)!==null&&i!==void 0?i:fbe(n,t)}};function ibe(e,t){return!Jn(e)&&we(t)&&!nn(t==null?void 0:t.bin)&&!ei(t==null?void 0:t.bin)}function sbe(e,t){const n=t==="x"?"y":"x";if(e.getScaleComponent(n))return e.scaleName(n)}function rbe(e,t,n,i,s){const o=t==null?void 0:t.labelAngle;if(o!==void 0)return Ne(o)?o:J2(o);{const{configValue:c}=Q8("labelAngle",i,t==null?void 0:t.style,s);return c!==void 0?J2(c):n===hn&&vt([cS,lS],e.type)&&!(we(e)&&e.timeUnit)?270:void 0}}function e9(e){return`(((${e.signal} % 360) + 360) % 360)`}function wW(e,t,n,i){if(e!==void 0)if(n==="x"){if(Ne(e)){const s=e9(e),o=Ne(t)?`(${t.signal} === "top")`:t==="top";return{signal:`(45 < ${s} && ${s} < 135) || (225 < ${s} && ${s} < 315) ? "middle" :(${s} <= 45 || 315 <= ${s}) === ${o} ? "bottom" : "top"`}}if(45{if(vf(i)&&eG(i.sort)){const{field:o,timeUnit:c}=i,d=i.sort,f=d.map((u,a)=>`${NV({field:o,timeUnit:c,equal:u})} ? ${a} : `).join("")+d.length;t=new ph(t,{calculate:f,as:yh(i,s,{forAs:!0})})}}),t}producedFields(){return new Set([this.transform.as])}dependentFields(){return this._dependentFields}assemble(){return{type:"formula",expr:this.transform.calculate,as:this.transform.as}}hash(){return`Calculate ${Bt(this.transform)}`}}function yh(e,t,n){return ve(e,Object.assign({prefix:t,suffix:"sort_index"},n??{}))}function m6(e,t){return vt(["top","bottom"],t)?"column":vt(["left","right"],t)||e==="row"?"row":"column"}function mh(e,t,n,i){const s=i==="row"?n.headerRow:i==="column"?n.headerColumn:n.headerFacet;return Sn((t||{})[e],s[e],n.header[e])}function w6(e,t,n,i){const s={};for(const o of e){const c=mh(o,t||{},n,i);c!==void 0&&(s[o]=c)}return s}const HS=["row","column"],zS=["header","footer"];function ube(e,t){const n=e.component.layoutHeaders[t].title,i=e.config?e.config:void 0,s=e.component.layoutHeaders[t].facetFieldDef?e.component.layoutHeaders[t].facetFieldDef:void 0,{titleAnchor:o,titleAngle:c,titleOrient:d}=w6(["titleAnchor","titleAngle","titleOrient"],s.header,i,t),f=m6(t,d),u=J2(c);return{name:`${t}-title`,type:"group",role:`${f}-title`,title:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({text:n},t==="row"?{orient:"left"}:{}),{style:"guide-title"}),vW(u,f)),TW(f,u,o)),EW(i,s,t,e9e,BG))}}function TW(e,t,n="middle"){switch(n){case"start":return{align:"left"};case"end":return{align:"right"}}const i=LW(t,e==="row"?"left":"top",e==="row"?"y":"x");return i?{align:i}:{}}function vW(e,t){const n=wW(e,t==="row"?"left":"top",t==="row"?"y":"x",!0);return n?{baseline:n}:{}}function hbe(e,t){const n=e.component.layoutHeaders[t],i=[];for(const s of zS)if(n[s])for(const o of n[s]){const c=_be(e,t,s,n,o);c!=null&&i.push(c)}return i}function gbe(e,t){var n;const{sort:i}=e;return Ba(i)?{field:ve(i,{expr:"datum"}),order:(n=i.order)!==null&&n!==void 0?n:"ascending"}:ue(i)?{field:yh(e,t,{expr:"datum"}),order:"ascending"}:{field:ve(e,{expr:"datum"}),order:i??"ascending"}}function t9(e,t,n){const{format:i,formatType:s,labelAngle:o,labelAnchor:c,labelOrient:d,labelExpr:f}=w6(["format","formatType","labelAngle","labelAnchor","labelOrient","labelExpr"],e.header,n,t),u=pS({fieldOrDatumDef:e,format:i,formatType:s,expr:"parent",config:n}).signal,a=m6(t,d);return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({text:{signal:f?Wd(Wd(f,"datum.label",u),"datum.value",ve(e,{expr:"parent"})):u}},t==="row"?{orient:"left"}:{}),{style:"guide-label",frame:"group"}),vW(o,a)),TW(a,o,c)),EW(n,e,t,t9e,FG))}function _be(e,t,n,i,s){if(s){let o=null;const{facetFieldDef:c}=i,d=e.config?e.config:void 0;if(c&&s.labels){const{labelOrient:m}=w6(["labelOrient"],c.header,d,t);(t==="row"&&!vt(["top","bottom"],m)||t==="column"&&!vt(["left","right"],m))&&(o=t9(c,t,d))}const f=Ur(e)&&!o3(e.facet),u=s.axes,a=(u==null?void 0:u.length)>0;if(o||a){const m=t==="row"?"height":"width";return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({name:e.getName(`${t}_${n}`),type:"group",role:`${t}-${n}`},i.facetFieldDef?{from:{data:e.getName(`${t}_domain`)},sort:gbe(c,t)}:{}),a&&f?{from:{data:e.getName(`facet_domain_${t}`)}}:{}),o?{title:o}:{}),s.sizeSignal?{encode:{update:{[m]:s.sizeSignal}}}:{}),a?{axes:u}:{})}}return null}const pbe={column:{start:0,end:1},row:{start:1,end:0}};function ybe(e,t){return pbe[t][e]}function mbe(e,t){const n={};for(const i of Ks){const s=e[i];if(s!=null&&s.facetFieldDef){const{titleAnchor:o,titleOrient:c}=w6(["titleAnchor","titleOrient"],s.facetFieldDef.header,t,i),d=m6(i,c),f=ybe(o,d);f!==void 0&&(n[d]=f)}}return Wt(n)?void 0:n}function EW(e,t,n,i,s){const o={};for(const c of i){if(!s[c])continue;const d=mh(c,t==null?void 0:t.header,e,n);d!==void 0&&(o[s[c]]=d)}return o}function $S(e){return[...f_(e,"width"),...f_(e,"height"),...f_(e,"childWidth"),...f_(e,"childHeight")]}function f_(e,t){const n=t==="width"?"x":"y",i=e.component.layoutSize.get(t);if(!i||i==="merged")return[];const s=e.getSizeSignalRef(t).signal;if(i==="step"){const o=e.getScaleComponent(n);if(o){const c=o.get("type"),d=o.get("range");if(Jn(c)&&Nc(d)){const f=e.scaleName(n);return Ur(e.parent)&&e.parent.component.resolve.scale[n]==="independent"?[HM(f,d)]:[HM(f,d),{name:s,update:SW(f,o,`domain('${f}').length`)}]}}throw new Error("layout size is step although width/height is not step.")}else if(i=="container"){const o=s.endsWith("width"),c=o?"containerSize()[0]":"containerSize()[1]",d=V8(e.config.view,o?"width":"height"),f=`isFinite(${c}) ? ${c} : ${d}`;return[{name:s,init:f,on:[{update:f,events:"window:resize"}]}]}else return[{name:s,value:i}]}function HM(e,t){const n=`${e}_step`;return Ne(t.step)?{name:n,update:t.step.signal}:{name:n,value:t.step}}function SW(e,t,n){const i=t.get("type"),s=t.get("padding"),o=Sn(t.get("paddingOuter"),s);let c=t.get("paddingInner");return c=i==="band"?c!==void 0?c:s:1,`bandspace(${n}, ${jo(c)}, ${jo(o)}) * ${e}_step`}function xW(e){return e==="childWidth"?"width":e==="childHeight"?"height":e}function kW(e,t){return ye(e).reduce((n,i)=>{const s=e[i];return Object.assign(Object.assign({},n),Hh(t,s,i,o=>on(o.value)))},{})}function BW(e,t){if(Ur(t))return e==="theta"?"independent":"shared";if(Vh(t))return"shared";if(KS(t))return Zn(e)||e==="theta"||e==="radius"?"independent":"shared";throw new Error("invalid model type for resolve")}function qS(e,t){const n=e.scale[t],i=Zn(t)?"axis":"legend";return n==="independent"?(e[i][t]==="shared"&&me(Z5e(t)),"independent"):e[i][t]||"shared"}const wbe=Object.assign(Object.assign({},s9e),{disable:1,labelExpr:1,selections:1,opacity:1,shape:1,stroke:1,fill:1,size:1,strokeWidth:1,strokeDash:1,encode:1}),FW=ye(wbe);class Lbe extends ll{}const zM={symbols:bbe,gradient:Tbe,labels:vbe,entries:Ebe};function bbe(e,{fieldOrDatumDef:t,model:n,channel:i,legendCmpt:s,legendType:o}){var c,d,f,u,a,m,y,p;if(o!=="symbol")return;const{markDef:l,encoding:b,config:L,mark:E}=n,S=l.filled&&E!=="trail";let x=Object.assign(Object.assign({},o5e({},n,e8e)),tW(n,{filled:S}));const F=(c=s.get("symbolOpacity"))!==null&&c!==void 0?c:L.legend.symbolOpacity,k=(d=s.get("symbolFillColor"))!==null&&d!==void 0?d:L.legend.symbolFillColor,M=(f=s.get("symbolStrokeColor"))!==null&&f!==void 0?f:L.legend.symbolStrokeColor,O=F===void 0?(u=IW(b.opacity))!==null&&u!==void 0?u:l.opacity:void 0;if(x.fill){if(i==="fill"||S&&i===ps)delete x.fill;else if(x.fill.field)k?delete x.fill:(x.fill=on((a=L.legend.symbolBaseFillColor)!==null&&a!==void 0?a:"black"),x.fillOpacity=on(O??1));else if(ue(x.fill)){const C=(p=(y=n9((m=b.fill)!==null&&m!==void 0?m:b.color))!==null&&y!==void 0?y:l.fill)!==null&&p!==void 0?p:S&&l.color;C&&(x.fill=on(C))}}if(x.stroke){if(i==="stroke"||!S&&i===ps)delete x.stroke;else if(x.stroke.field||M)delete x.stroke;else if(ue(x.stroke)){const C=Sn(n9(b.stroke||b.color),l.stroke,S?l.color:void 0);C&&(x.stroke={value:C})}}if(i!==al){const C=we(t)&&MW(n,s,t);C?x.opacity=[Object.assign({test:C},on(O??1)),on(L.legend.unselectedOpacity)]:O&&(x.opacity=on(O))}return x=Object.assign(Object.assign({},x),e),Wt(x)?void 0:x}function Tbe(e,{model:t,legendType:n,legendCmpt:i}){var s;if(n!=="gradient")return;const{config:o,markDef:c,encoding:d}=t;let f={};const a=((s=i.get("gradientOpacity"))!==null&&s!==void 0?s:o.legend.gradientOpacity)===void 0?IW(d.opacity)||c.opacity:void 0;return a&&(f.opacity=on(a)),f=Object.assign(Object.assign({},f),e),Wt(f)?void 0:f}function vbe(e,{fieldOrDatumDef:t,model:n,channel:i,legendCmpt:s}){const o=n.legend(i)||{},c=n.config,d=we(t)?MW(n,s,t):void 0,f=d?[{test:d,value:1},{value:c.legend.unselectedOpacity}]:void 0,{format:u,formatType:a}=o;let m;Jd(a)?m=Nr({fieldOrDatumDef:t,field:"datum.value",format:u,formatType:a,config:c}):u===void 0&&a===void 0&&c.customFormatTypes&&(t.type==="quantitative"&&c.numberFormatType?m=Nr({fieldOrDatumDef:t,field:"datum.value",format:c.numberFormat,formatType:c.numberFormatType,config:c}):t.type==="temporal"&&c.timeFormatType&&we(t)&&t.timeUnit===void 0&&(m=Nr({fieldOrDatumDef:t,field:"datum.value",format:c.timeFormat,formatType:c.timeFormatType,config:c})));const y=Object.assign(Object.assign(Object.assign({},f?{opacity:f}:{}),m?{text:m}:{}),e);return Wt(y)?void 0:y}function Ebe(e,{legendCmpt:t}){const n=t.get("selections");return n!=null&&n.length?Object.assign(Object.assign({},e),{fill:{value:"transparent"}}):e}function IW(e){return OW(e,(t,n)=>Math.max(t,n.value))}function n9(e){return OW(e,(t,n)=>Sn(t,n.value))}function OW(e,t){if(w8e(e))return Se(e.condition).reduce(t,e.value);if(Vr(e))return e.value}function MW(e,t,n){const i=t.get("selections");if(!(i!=null&&i.length))return;const s=Te(n.field);return i.map(o=>`(!length(data(${Te(dn(o)+ef)})) || (${o}[${s}] && indexof(${o}[${s}], datum.value) >= 0))`).join(" || ")}const $M={direction:({direction:e})=>e,format:({fieldOrDatumDef:e,legend:t,config:n})=>{const{format:i,formatType:s}=t;return KV(e,e.type,i,s,n,!1)},formatType:({legend:e,fieldOrDatumDef:t,scaleType:n})=>{const{formatType:i}=e;return ZV(i,t,n)},gradientLength:e=>{var t,n;const{legend:i,legendConfig:s}=e;return(n=(t=i.gradientLength)!==null&&t!==void 0?t:s.gradientLength)!==null&&n!==void 0?n:Obe(e)},labelOverlap:({legend:e,legendConfig:t,scaleType:n})=>{var i,s;return(s=(i=e.labelOverlap)!==null&&i!==void 0?i:t.labelOverlap)!==null&&s!==void 0?s:Mbe(n)},symbolType:({legend:e,markDef:t,channel:n,encoding:i})=>{var s;return(s=e.symbolType)!==null&&s!==void 0?s:xbe(t.type,n,i.shape,t.shape)},title:({fieldOrDatumDef:e,config:t})=>vu(e,t,{allowDisabling:!0}),type:({legendType:e,scaleType:t,channel:n})=>{if(Tu(n)&&Ar(t)){if(e==="gradient")return}else if(e==="symbol")return;return e},values:({fieldOrDatumDef:e,legend:t})=>Sbe(t,e)};function Sbe(e,t){const n=e.values;if(ue(n))return dG(t,n);if(Ne(n))return n}function xbe(e,t,n,i){var s;if(t!=="shape"){const o=(s=n9(n))!==null&&s!==void 0?s:i;if(o)return o}switch(e){case"bar":case"rect":case"image":case"square":return"square";case"line":case"trail":case"rule":return"stroke";case"arc":case"point":case"circle":case"tick":case"geoshape":case"area":case"text":return"circle"}}function kbe(e){const{legend:t}=e;return Sn(t.type,Bbe(e))}function Bbe({channel:e,timeUnit:t,scaleType:n}){if(Tu(e)){if(vt(["quarter","month","day"],t))return"symbol";if(Ar(n))return"gradient"}return"symbol"}function Fbe({legendConfig:e,legendType:t,orient:n,legend:i}){var s,o;return(o=(s=i.direction)!==null&&s!==void 0?s:e[t?"gradientDirection":"symbolDirection"])!==null&&o!==void 0?o:Ibe(n,t)}function Ibe(e,t){switch(e){case"top":case"bottom":return"horizontal";case"left":case"right":case"none":case void 0:return;default:return t==="gradient"?"horizontal":void 0}}function Obe({legendConfig:e,model:t,direction:n,orient:i,scaleType:s}){const{gradientHorizontalMaxLength:o,gradientHorizontalMinLength:c,gradientVerticalMaxLength:d,gradientVerticalMinLength:f}=e;if(Ar(s))return n==="horizontal"?i==="top"||i==="bottom"?qM(t,"width",c,o):c:qM(t,"height",f,d)}function qM(e,t,n,i){return{signal:`clamp(${e.getSizeSignalRef(t).signal}, ${n}, ${i})`}}function Mbe(e){if(vt(["quantile","threshold","log","symlog"],e))return"greedy"}function AW(e){const t=Ln(e)?Abe(e):Pbe(e);return e.component.legends=t,t}function Abe(e){const{encoding:t}=e,n={};for(const i of[ps,...OG]){const s=An(t[i]);!s||!e.getScaleComponent(i)||i===ys&&we(s)&&s.type===Uh||(n[i]=Rbe(e,i))}return n}function Nbe(e,t){const n=e.scaleName(t);if(e.mark==="trail"){if(t==="color")return{stroke:n};if(t==="size")return{strokeWidth:n}}return t==="color"?e.markDef.filled?{fill:n}:{stroke:n}:{[t]:n}}function Cbe(e,t,n,i){switch(t){case"disable":return n!==void 0;case"values":return!!(n!=null&&n.values);case"title":if(t==="title"&&e===(i==null?void 0:i.title))return!0}return e===(n||{})[t]}function Rbe(e,t){var n,i,s;let o=e.legend(t);const{markDef:c,encoding:d,config:f}=e,u=f.legend,a=new Lbe({},Nbe(e,t));G7e(e,t,a);const m=o!==void 0?!o:u.disable;if(a.set("disable",m,o!==void 0),m)return a;o=o||{};const y=e.getScaleComponent(t).get("type"),p=An(d[t]),l=we(p)?(n=xi(p.timeUnit))===null||n===void 0?void 0:n.unit:void 0,b=o.orient||f.legend.orient||"right",L=kbe({legend:o,channel:t,timeUnit:l,scaleType:y}),E=Fbe({legend:o,legendType:L,orient:b,legendConfig:u}),S={legend:o,channel:t,model:e,markDef:c,encoding:d,fieldOrDatumDef:p,legendConfig:u,config:f,scaleType:y,orient:b,legendType:L,direction:E};for(const O of FW){if(L==="gradient"&&O.startsWith("symbol")||L==="symbol"&&O.startsWith("gradient"))continue;const C=O in $M?$M[O](S):o[O];if(C!==void 0){const P=Cbe(C,O,o,e.fieldDef(t));(P||f.legend[O]===void 0)&&a.set(O,C,P)}}const x=(i=o==null?void 0:o.encoding)!==null&&i!==void 0?i:{},F=a.get("selections"),k={},M={fieldOrDatumDef:p,model:e,channel:t,legendCmpt:a,legendType:L};for(const O of["labels","legend","title","symbols","gradient","entries"]){const C=kW((s=x[O])!==null&&s!==void 0?s:{},e),P=O in zM?zM[O](C,M):C;P!==void 0&&!Wt(P)&&(k[O]=Object.assign(Object.assign(Object.assign({},F!=null&&F.length&&we(p)?{name:`${dn(p.field)}_legend_${O}`}:{}),F!=null&&F.length?{interactive:!!F}:{}),{update:P}))}return Wt(k)||a.set("encode",k,!!(o!=null&&o.encoding)),a}function Pbe(e){const{legends:t,resolve:n}=e.component;for(const i of e.children){AW(i);for(const s of ye(i.component.legends))n.legend[s]=qS(e.component.resolve,s),n.legend[s]==="shared"&&(t[s]=NW(t[s],i.component.legends[s]),t[s]||(n.legend[s]="independent",delete t[s]))}for(const i of ye(t))for(const s of e.children)s.component.legends[i]&&n.legend[i]==="shared"&&delete s.component.legends[i];return t}function NW(e,t){var n,i,s,o;if(!e)return t.clone();const c=e.getWithExplicit("orient"),d=t.getWithExplicit("orient");if(c.explicit&&d.explicit&&c.value!==d.value)return;let f=!1;for(const u of FW){const a=fc(e.getWithExplicit(u),t.getWithExplicit(u),u,"legend",(m,y)=>{switch(u){case"symbolType":return Dbe(m,y);case"title":return LV(m,y);case"type":return f=!0,vs("symbol")}return _6(m,y,u,"legend")});e.setWithExplicit(u,a)}return f&&(!((i=(n=e.implicit)===null||n===void 0?void 0:n.encode)===null||i===void 0)&&i.gradient&&$y(e.implicit,["encode","gradient"]),!((o=(s=e.explicit)===null||s===void 0?void 0:s.encode)===null||o===void 0)&&o.gradient&&$y(e.explicit,["encode","gradient"])),e}function Dbe(e,t){return t.value==="circle"?t:e}var jbe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);sHbe(s,e.config)).filter(s=>s!==void 0)}function Hbe(e,t){var n,i,s;const o=e.combine(),{disable:c,labelExpr:d,selections:f}=o,u=jbe(o,["disable","labelExpr","selections"]);if(!c){if(t.aria===!1&&u.aria==null&&(u.aria=!1),!((n=u.encode)===null||n===void 0)&&n.symbols){const a=u.encode.symbols.update;a.fill&&a.fill.value!=="transparent"&&!a.stroke&&!u.stroke&&(a.stroke={value:"transparent"});for(const m of OG)u[m]&&delete a[m]}if(u.title||delete u.title,d!==void 0){let a=d;!((s=(i=u.encode)===null||i===void 0?void 0:i.labels)===null||s===void 0)&&s.update&&Ne(u.encode.labels.update.text)&&(a=Wd(d,"datum.label",u.encode.labels.update.text.signal)),Ube(u,"labels","text",{signal:a})}return u}}function zbe(e){return Vh(e)||KS(e)?$be(e):RW(e)}function $be(e){return e.children.reduce((t,n)=>t.concat(n.assembleProjections()),RW(e))}function RW(e){const t=e.component.projection;if(!t||t.merged)return[];const n=t.combine(),{name:i}=n;if(t.data){const s={signal:`[${t.size.map(c=>c.signal).join(", ")}]`},o=t.data.reduce((c,d)=>{const f=Ne(d)?d.signal:`data('${e.lookupDataSource(d)}')`;return vt(c,f)||c.push(f),c},[]);if(o.length<=0)throw new Error("Projection's fit didn't find any data sources");return[Object.assign({name:i,size:s,fit:{signal:o.length>1?`[${o.join(", ")}]`:o[0]}},n)]}else return[Object.assign(Object.assign({name:i},{translate:{signal:"[width / 2, height / 2]"}}),n)]}const qbe=["type","clipAngle","clipExtent","center","rotate","precision","reflectX","reflectY","coefficient","distance","fraction","lobes","parallel","radius","ratio","spacing","tilt"];class PW extends ll{constructor(t,n,i,s){super(Object.assign({},n),{name:t}),this.specifiedProjection=n,this.size=i,this.data=s,this.merged=!1}get isFit(){return!!this.data}}function DW(e){e.component.projection=Ln(e)?Vbe(e):Ybe(e)}function Vbe(e){var t;if(e.hasProjection){const n=es(e.specifiedProjection),i=!(n&&(n.scale!=null||n.translate!=null)),s=i?[e.getSizeSignalRef("width"),e.getSizeSignalRef("height")]:void 0,o=i?Gbe(e):void 0,c=new PW(e.projectionName(!0),Object.assign(Object.assign({},(t=es(e.config.projection))!==null&&t!==void 0?t:{}),n??{}),s,o);return c.get("type")||c.set("type","equalEarth",!1),c}}function Gbe(e){const t=[],{encoding:n}=e;for(const i of[[so,io],[or,ea]])(An(n[i[0]])||An(n[i[1]]))&&t.push({signal:e.getName(`geojson_${t.length}`)});return e.channelHasField(ys)&&e.typedFieldDef(ys).type===Uh&&t.push({signal:e.getName(`geojson_${t.length}`)}),t.length===0&&t.push(e.requestDataName(en.Main)),t}function Wbe(e,t){const n=CE(qbe,s=>!!(!De(e.explicit,s)&&!De(t.explicit,s)||De(e.explicit,s)&&De(t.explicit,s)&&ba(e.get(s),t.get(s))));if(ba(e.size,t.size)){if(n)return e;if(ba(e.explicit,{}))return t;if(ba(t.explicit,{}))return e}return null}function Ybe(e){if(e.children.length===0)return;let t;for(const i of e.children)DW(i);const n=CE(e.children,i=>{const s=i.component.projection;if(s)if(t){const o=Wbe(t,s);return o&&(t=o),!!o}else return t=s,!0;else return!0});if(t&&n){const i=e.projectionName(!0),s=new PW(i,t.specifiedProjection,t.size,at(t.data));for(const o of e.children){const c=o.component.projection;c&&(c.isFit&&s.data.push(...o.component.projection.data),o.renameProjection(c.get("name"),i),c.merged=!0)}return s}}var Xbe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{if(lr(o)&&nn(o.bin)){const{key:d,binComponent:f}=VM(o,o.bin,n);s[d]=Object.assign(Object.assign(Object.assign({},f),s[d]),Kbe(n,o,c,n.config))}return s},{});return Wt(i)?null:new Ia(t,i)}static makeFromTransform(t,n,i){const{key:s,binComponent:o}=VM(n,n.bin,i);return new Ia(t,{[s]:o})}merge(t,n){for(const i of ye(t.bins))i in this.bins?(n(t.bins[i].signal,this.bins[i].signal),this.bins[i].as=Ta([...this.bins[i].as,...t.bins[i].as],Bt)):this.bins[i]=t.bins[i];for(const i of t.children)t.removeChild(i),i.parent=this;t.remove()}producedFields(){return new Set(Ti(this.bins).map(t=>t.as).flat(2))}dependentFields(){return new Set(Ti(this.bins).map(t=>t.field))}hash(){return`Bin ${Bt(this.bins)}`}assemble(){return Ti(this.bins).flatMap(t=>{const n=[],[i,...s]=t.as,o=t.bin,{extent:c}=o,d=Xbe(o,["extent"]),f=Object.assign(Object.assign(Object.assign({type:"bin",field:ar(t.field),as:i,signal:t.signal},Qm(c)?{extent:null}:{extent:c}),t.span?{span:{signal:`span(${t.span})`}}:{}),d);!c&&t.extentSignal&&(n.push({type:"extent",field:ar(t.field),signal:t.extentSignal}),f.extent={signal:t.extentSignal}),n.push(f);for(const u of s)for(let a=0;a<2;a++)n.push({type:"formula",expr:ve({field:i[a]},{expr:"datum"}),as:u[a]});return t.formula&&n.push({type:"formula",expr:t.formula,as:t.formulaAs}),n})}}function Qbe(e,t,n,i){var s;const o=Ln(i)?i.encoding[oo(t)]:void 0;if(lr(n)&&Ln(i)&&iG(n,o,i.markDef,i.config))e.add(ve(n,{})),e.add(ve(n,{suffix:"end"})),n.bin&&c3(n,t)&&e.add(ve(n,{binSuffix:"range"}));else if(Owe(t)){const c=Iwe(t);e.add(i.getName(c))}else e.add(ve(n));return vf(n)&&zLe((s=n.scale)===null||s===void 0?void 0:s.range)&&e.add(n.scale.range.field),e}function eTe(e,t){var n;for(const i of ye(t)){const s=t[i];for(const o of ye(s))i in e?e[i][o]=new Set([...(n=e[i][o])!==null&&n!==void 0?n:[],...s[o]]):e[i]={[o]:s[o]}}}class jr extends Kt{clone(){return new jr(null,new Set(this.dimensions),at(this.measures))}constructor(t,n,i){super(t),this.dimensions=n,this.measures=i}get groupBy(){return this.dimensions}static makeFromEncoding(t,n){let i=!1;n.forEachFieldDef(c=>{c.aggregate&&(i=!0)});const s={},o=new Set;return!i||(n.forEachFieldDef((c,d)=>{var f,u,a,m;const{aggregate:y,field:p}=c;if(y)if(y==="count")(f=s["*"])!==null&&f!==void 0||(s["*"]={}),s["*"].count=new Set([ve(c,{forAs:!0})]);else{if(Yo(y)||Ac(y)){const l=Yo(y)?"argmin":"argmax",b=y[l];(u=s[b])!==null&&u!==void 0||(s[b]={}),s[b][l]=new Set([ve({op:l,field:b},{forAs:!0})])}else(a=s[p])!==null&&a!==void 0||(s[p]={}),s[p][y]=new Set([ve(c,{forAs:!0})]);Mc(d)&&n.scaleDomain(d)==="unaggregated"&&((m=s[p])!==null&&m!==void 0||(s[p]={}),s[p].min=new Set([ve({field:p,aggregate:"min"},{forAs:!0})]),s[p].max=new Set([ve({field:p,aggregate:"max"},{forAs:!0})]))}else Qbe(o,d,c,n)}),o.size+ye(s).length===0)?null:new jr(t,o,s)}static makeFromTransform(t,n){var i,s,o;const c=new Set,d={};for(const f of n.aggregate){const{op:u,field:a,as:m}=f;u&&(u==="count"?((i=d["*"])!==null&&i!==void 0||(d["*"]={}),d["*"].count=new Set([m||ve(f,{forAs:!0})])):((s=d[a])!==null&&s!==void 0||(d[a]={}),d[a][u]=new Set([m||ve(f,{forAs:!0})])))}for(const f of(o=n.groupby)!==null&&o!==void 0?o:[])c.add(f);return c.size+ye(d).length===0?null:new jr(t,c,d)}merge(t){return Yq(this.dimensions,t.dimensions)?(eTe(this.measures,t.measures),!0):(hLe("different dimensions, cannot merge"),!1)}addDimensions(t){t.forEach(this.dimensions.add,this.dimensions)}dependentFields(){return new Set([...this.dimensions,...ye(this.measures)])}producedFields(){const t=new Set;for(const n of ye(this.measures))for(const i of ye(this.measures[n])){const s=this.measures[n][i];s.size===0?t.add(`${i}_${n}`):s.forEach(t.add,t)}return t}hash(){return`Aggregate ${Bt({dimensions:this.dimensions,measures:this.measures})}`}assemble(){const t=[],n=[],i=[];for(const o of ye(this.measures))for(const c of ye(this.measures[o]))for(const d of this.measures[o][c])i.push(d),t.push(c),n.push(o==="*"?null:ar(o));return{type:"aggregate",groupby:[...this.dimensions].map(ar),ops:t,fields:n,as:i}}}class $h extends Kt{constructor(t,n,i,s){super(t),this.model=n,this.name=i,this.data=s;for(const o of Ks){const c=n.facet[o];if(c){const{bin:d,sort:f}=c;this[o]=Object.assign({name:n.getName(`${o}_domain`),fields:[ve(c),...nn(d)?[ve(c,{binSuffix:"end"})]:[]]},Ba(f)?{sortField:f}:ue(f)?{sortIndexField:yh(c,o)}:{})}}this.childModel=n.child}hash(){let t="Facet";for(const n of Ks)this[n]&&(t+=` ${n.charAt(0)}:${Bt(this[n])}`);return t}get fields(){var t;const n=[];for(const i of Ks)!((t=this[i])===null||t===void 0)&&t.fields&&n.push(...this[i].fields);return n}dependentFields(){const t=new Set(this.fields);for(const n of Ks)this[n]&&(this[n].sortField&&t.add(this[n].sortField.field),this[n].sortIndexField&&t.add(this[n].sortIndexField));return t}producedFields(){return new Set}getSource(){return this.name}getChildIndependentFieldsWithStep(){const t={};for(const n of lo){const i=this.childModel.component.scales[n];if(i&&!i.merged){const s=i.get("type"),o=i.get("range");if(Jn(s)&&Nc(o)){const c=L6(this.childModel,n),d=XS(c);d?t[n]=d:me(XE(n))}}}return t}assembleRowColumnHeaderData(t,n,i){const s={row:"y",column:"x",facet:void 0}[t],o=[],c=[],d=[];s&&i&&i[s]&&(n?(o.push(`distinct_${i[s]}`),c.push("max")):(o.push(i[s]),c.push("distinct")),d.push(`distinct_${i[s]}`));const{sortField:f,sortIndexField:u}=this[t];if(f){const{op:a=r6,field:m}=f;o.push(m),c.push(a),d.push(ve(f,{forAs:!0}))}else u&&(o.push(u),c.push("max"),d.push(u));return{name:this[t].name,source:n??this.data,transform:[Object.assign({type:"aggregate",groupby:this[t].fields},o.length?{fields:o,ops:c,as:d}:{})]}}assembleFacetHeaderData(t){var n,i;const{columns:s}=this.model.layout,{layoutHeaders:o}=this.model.component,c=[],d={};for(const a of HS){for(const m of zS){const y=(n=o[a]&&o[a][m])!==null&&n!==void 0?n:[];for(const p of y)if(((i=p.axes)===null||i===void 0?void 0:i.length)>0){d[a]=!0;break}}if(d[a]){const m=`length(data("${this.facet.name}"))`,y=a==="row"?s?{signal:`ceil(${m} / ${s})`}:1:s?{signal:`min(${m}, ${s})`}:{signal:m};c.push({name:`${this.facet.name}_${a}`,transform:[{type:"sequence",start:0,stop:y}]})}}const{row:f,column:u}=d;return(f||u)&&c.unshift(this.assembleRowColumnHeaderData("facet",null,t)),c}assemble(){var t,n;const i=[];let s=null;const o=this.getChildIndependentFieldsWithStep(),{column:c,row:d,facet:f}=this;if(c&&d&&(o.x||o.y)){s=`cross_${this.column.name}_${this.row.name}`;const u=[].concat((t=o.x)!==null&&t!==void 0?t:[],(n=o.y)!==null&&n!==void 0?n:[]),a=u.map(()=>"distinct");i.push({name:s,source:this.data,transform:[{type:"aggregate",groupby:this.fields,fields:u,ops:a}]})}for(const u of[Do,Po])this[u]&&i.push(this.assembleRowColumnHeaderData(u,s,o));if(f){const u=this.assembleFacetHeaderData(o);u&&i.push(...u)}return i}}function GM(e){return e.startsWith("'")&&e.endsWith("'")||e.startsWith('"')&&e.endsWith('"')?e.slice(1,-1):e}function tTe(e,t){const n=DE(e);if(t==="number")return`toNumber(${n})`;if(t==="boolean")return`toBoolean(${n})`;if(t==="string")return`toString(${n})`;if(t==="date")return`toDate(${n})`;if(t==="flatten")return n;if(t.startsWith("date:")){const i=GM(t.slice(5,t.length));return`timeParse(${n},'${i}')`}else if(t.startsWith("utc:")){const i=GM(t.slice(4,t.length));return`utcParse(${n},'${i}')`}else return me(L5e(t)),null}function nTe(e){const t={};return ap(e.filter,n=>{var i;if(AV(n)){let s=null;eS(n)?s=Is(n.equal):nS(n)?s=Is(n.lte):tS(n)?s=Is(n.lt):iS(n)?s=Is(n.gt):sS(n)?s=Is(n.gte):rS(n)?s=n.range[0]:aS(n)&&(s=((i=n.oneOf)!==null&&i!==void 0?i:n.in)[0]),s&&(Tf(s)?t[n.field]="date":Yt(s)?t[n.field]="number":xe(s)&&(t[n.field]="string")),n.timeUnit&&(t[n.field]="date")}}),t}function iTe(e){const t={};function n(i){hh(i)?t[i.field]="date":i.type==="quantitative"&&Zwe(i.aggregate)?t[i.field]="number":oh(i.field)>1?i.field in t||(t[i.field]="flatten"):vf(i)&&Ba(i.sort)&&oh(i.sort.field)>1&&(i.sort.field in t||(t[i.sort.field]="flatten"))}if((Ln(e)||Ur(e))&&e.forEachFieldDef((i,s)=>{if(lr(i))n(i);else{const o=Lf(s),c=e.fieldDef(o);n(Object.assign(Object.assign({},i),{type:c.type}))}}),Ln(e)){const{mark:i,markDef:s,encoding:o}=e;if(Cc(i)&&!e.encoding.order){const c=s.orient==="horizontal"?"y":"x",d=o[c];we(d)&&d.type==="quantitative"&&!(d.field in t)&&(t[d.field]="number")}}return t}function sTe(e){const t={};if(Ln(e)&&e.component.selection)for(const n of ye(e.component.selection)){const i=e.component.selection[n];for(const s of i.project.items)!s.channel&&oh(s.field)>1&&(t[s.field]="flatten")}return t}class yi extends Kt{clone(){return new yi(null,at(this._parse))}constructor(t,n){super(t),this._parse=n}hash(){return`Parse ${Bt(this._parse)}`}static makeExplicit(t,n,i){var s;let o={};const c=n.data;return!Vl(c)&&(!((s=c==null?void 0:c.format)===null||s===void 0)&&s.parse)&&(o=c.format.parse),this.makeWithAncestors(t,o,{},i)}static makeWithAncestors(t,n,i,s){for(const d of ye(i)){const f=s.getWithExplicit(d);f.value!==void 0&&(f.explicit||f.value===i[d]||f.value==="derived"||i[d]==="flatten"?delete i[d]:me(aM(d,i[d],f.value)))}for(const d of ye(n)){const f=s.get(d);f!==void 0&&(f===n[d]?delete n[d]:me(aM(d,n[d],f)))}const o=new ll(n,i);s.copyAll(o);const c={};for(const d of ye(o.combine())){const f=o.get(d);f!==null&&(c[d]=f)}return ye(c).length===0||s.parseNothing?null:new yi(t,c)}get parse(){return this._parse}merge(t){this._parse=Object.assign(Object.assign({},this._parse),t.parse),t.remove()}assembleFormatParse(){const t={};for(const n of ye(this._parse)){const i=this._parse[n];oh(n)===1&&(t[n]=i)}return t}producedFields(){return new Set(ye(this._parse))}dependentFields(){return new Set(ye(this._parse))}assembleTransforms(t=!1){return ye(this._parse).filter(n=>t?oh(n)>1:!0).map(n=>{const i=tTe(n,this._parse[n]);return i?{type:"formula",expr:i,as:jE(n)}:null}).filter(n=>n!==null)}}class _c extends Kt{clone(){return new _c(null)}constructor(t){super(t)}dependentFields(){return new Set}producedFields(){return new Set([Va])}hash(){return"Identifier"}assemble(){return{type:"identifier",as:Va}}}class u3 extends Kt{clone(){return new u3(null,this.params)}constructor(t,n){super(t),this.params=n}dependentFields(){return new Set}producedFields(){}hash(){return`Graticule ${Bt(this.params)}`}assemble(){return Object.assign({type:"graticule"},this.params===!0?{}:this.params)}}class h3 extends Kt{clone(){return new h3(null,this.params)}constructor(t,n){super(t),this.params=n}dependentFields(){return new Set}producedFields(){var t;return new Set([(t=this.params.as)!==null&&t!==void 0?t:"data"])}hash(){return`Hash ${Bt(this.params)}`}assemble(){return Object.assign({type:"sequence"},this.params)}}class tf extends Kt{constructor(t){super(null),t??(t={name:"source"});let n;if(Vl(t)||(n=t.format?Object.assign({},as(t.format,["parse"])):{}),e0(t))this._data={values:t.values};else if(gh(t)){if(this._data={url:t.url},!n.type){let i=/(?:\.([^.]+))?$/.exec(t.url)[1];vt(["json","csv","tsv","dsv","topojson"],i)||(i="json"),n.type=i}}else KG(t)?this._data={values:[{type:"Sphere"}]}:(YG(t)||Vl(t))&&(this._data={});this._generator=Vl(t),t.name&&(this._name=t.name),n&&!Wt(n)&&(this._data.format=n)}dependentFields(){return new Set}producedFields(){}get data(){return this._data}hasName(){return!!this._name}get isGenerator(){return this._generator}get dataName(){return this._name}set dataName(t){this._name=t}set parent(t){throw new Error("Source nodes have to be roots.")}remove(){throw new Error("Source nodes are roots and cannot be removed.")}hash(){throw new Error("Cannot hash sources")}assemble(){return Object.assign(Object.assign({name:this._name},this._data),{transform:[]})}}var WM=globalThis&&globalThis.__classPrivateFieldSet||function(e,t,n,i,s){if(i==="m")throw new TypeError("Private method is not writable");if(i==="a"&&!s)throw new TypeError("Private accessor was defined without a setter");if(typeof t=="function"?e!==t||!s:!t.has(e))throw new TypeError("Cannot write private member to an object whose class did not declare it");return i==="a"?s.call(e,n):s?s.value=n:t.set(e,n),n},rTe=globalThis&&globalThis.__classPrivateFieldGet||function(e,t,n,i){if(n==="a"&&!i)throw new TypeError("Private accessor was defined without a getter");if(typeof t=="function"?e!==t||!i:!t.has(e))throw new TypeError("Cannot read private member from an object whose class did not declare it");return n==="m"?i:n==="a"?i.call(e):i?i.value:t.get(e)},W1;function GS(e){return e instanceof tf||e instanceof u3||e instanceof h3}class WS{constructor(){W1.set(this,void 0),WM(this,W1,!1,"f")}setModified(){WM(this,W1,!0,"f")}get modifiedFlag(){return rTe(this,W1,"f")}}W1=new WeakMap;class Ef extends WS{getNodeDepths(t,n,i){i.set(t,n);for(const s of t.children)this.getNodeDepths(s,n+1,i);return i}optimize(t){const i=[...this.getNodeDepths(t,0,new Map).entries()].sort((s,o)=>o[1]-s[1]);for(const s of i)this.run(s[0]);return this.modifiedFlag}}class YS extends WS{optimize(t){this.run(t);for(const n of t.children)this.optimize(n);return this.modifiedFlag}}class aTe extends YS{mergeNodes(t,n){const i=n.shift();for(const s of n)t.removeChild(s),s.parent=i,s.remove()}run(t){const n=t.children.map(s=>s.hash()),i={};for(let s=0;s1&&(this.setModified(),this.mergeNodes(t,i[s]))}}class oTe extends YS{constructor(t){super(),this.requiresSelectionId=t&&US(t)}run(t){t instanceof _c&&(this.requiresSelectionId&&(GS(t.parent)||t.parent instanceof jr||t.parent instanceof yi)||(this.setModified(),t.remove()))}}class lTe extends WS{optimize(t){return this.run(t,new Set),this.modifiedFlag}run(t,n){let i=new Set;t instanceof Fa&&(i=t.producedFields(),RE(i,n)&&(this.setModified(),t.removeFormulas(n),t.producedFields.length===0&&t.remove()));for(const s of t.children)this.run(s,new Set([...n,...i]))}}class cTe extends YS{constructor(){super()}run(t){t instanceof Ui&&!t.isRequired()&&(this.setModified(),t.remove())}}class dTe extends Ef{run(t){if(!GS(t)&&!(t.numChildren()>1)){for(const n of t.children)if(n instanceof yi)if(t instanceof yi)this.setModified(),t.merge(n);else{if(PE(t.producedFields(),n.dependentFields()))continue;this.setModified(),n.swapWithParent()}}}}class fTe extends Ef{run(t){const n=[...t.children],i=t.children.filter(s=>s instanceof yi);if(t.numChildren()>1&&i.length>=1){const s={},o=new Set;for(const c of i){const d=c.parse;for(const f of ye(d))f in s?s[f]!==d[f]&&o.add(f):s[f]=d[f]}for(const c of o)delete s[c];if(!Wt(s)){this.setModified();const c=new yi(t,s);for(const d of n){if(d instanceof yi)for(const f of ye(s))delete d.parse[f];t.removeChild(d),d.parent=c,d instanceof yi&&ye(d.parse).length===0&&d.remove()}}}}}class uTe extends Ef{run(t){t instanceof Ui||t.numChildren()>0||t instanceof $h||t instanceof tf||(this.setModified(),t.remove())}}class hTe extends Ef{run(t){const n=t.children.filter(s=>s instanceof Fa),i=n.pop();for(const s of n)this.setModified(),i.merge(s)}}class gTe extends Ef{run(t){const n=t.children.filter(s=>s instanceof jr),i={};for(const s of n){const o=Bt(s.groupBy);o in i||(i[o]=[]),i[o].push(s)}for(const s of ye(i)){const o=i[s];if(o.length>1){const c=o.pop();for(const d of o)c.merge(d)&&(t.removeChild(d),d.parent=c,d.remove(),this.setModified())}}}}class _Te extends Ef{constructor(t){super(),this.model=t}run(t){const n=!(GS(t)||t instanceof zh||t instanceof yi||t instanceof _c),i=[],s=[];for(const o of t.children)o instanceof Ia&&(n&&!PE(t.producedFields(),o.dependentFields())?i.push(o):s.push(o));if(i.length>0){const o=i.pop();for(const c of i)o.merge(c,this.model.renameSignal.bind(this.model));this.setModified(),t instanceof Ia?t.merge(o,this.model.renameSignal.bind(this.model)):o.swapWithParent()}if(s.length>1){const o=s.pop();for(const c of s)o.merge(c,this.model.renameSignal.bind(this.model));this.setModified()}}}class pTe extends Ef{run(t){const n=[...t.children];if(!Gd(n,c=>c instanceof Ui)||t.numChildren()<=1)return;const s=[];let o;for(const c of n)if(c instanceof Ui){let d=c;for(;d.numChildren()===1;){const[f]=d.children;if(f instanceof Ui)d=f;else break}s.push(...d.children),o?(t.removeChild(c),c.parent=o.parent,o.parent.removeChild(o),o.parent=d,this.setModified()):o=d}else s.push(c);if(s.length){this.setModified();for(const c of s)c.parent.removeChild(c),c.parent=o}}}class Sf extends Kt{clone(){return new Sf(null,at(this.transform))}constructor(t,n){super(t),this.transform=n}addDimensions(t){this.transform.groupby=Ta(this.transform.groupby.concat(t),n=>n)}dependentFields(){const t=new Set;return this.transform.groupby&&this.transform.groupby.forEach(t.add,t),this.transform.joinaggregate.map(n=>n.field).filter(n=>n!==void 0).forEach(t.add,t),t}producedFields(){return new Set(this.transform.joinaggregate.map(this.getDefaultName))}getDefaultName(t){var n;return(n=t.as)!==null&&n!==void 0?n:ve(t)}hash(){return`JoinAggregateTransform ${Bt(this.transform)}`}assemble(){const t=[],n=[],i=[];for(const o of this.transform.joinaggregate)n.push(o.op),i.push(this.getDefaultName(o)),t.push(o.field===void 0?null:o.field);const s=this.transform.groupby;return Object.assign({type:"joinaggregate",as:i,ops:n,fields:t},s!==void 0?{groupby:s}:{})}}function yTe(e){return e.stack.stackBy.reduce((t,n)=>{const i=n.fieldDef,s=ve(i);return s&&t.push(s),t},[])}function mTe(e){return ue(e)&&e.every(t=>xe(t))&&e.length>1}class Uo extends Kt{clone(){return new Uo(null,at(this._stack))}constructor(t,n){super(t),this._stack=n}static makeFromTransform(t,n){const{stack:i,groupby:s,as:o,offset:c="zero"}=n,d=[],f=[];if(n.sort!==void 0)for(const m of n.sort)d.push(m.field),f.push(Sn(m.order,"ascending"));const u={field:d,order:f};let a;return mTe(o)?a=o:xe(o)?a=[o,`${o}_end`]:a=[`${n.stack}_start`,`${n.stack}_end`],new Uo(t,{dimensionFieldDefs:[],stackField:i,groupby:s,offset:c,sort:u,facetby:[],as:a})}static makeFromEncoding(t,n){const i=n.stack,{encoding:s}=n;if(!i)return null;const{groupbyChannels:o,fieldChannel:c,offset:d,impute:f}=i,u=o.map(p=>{const l=s[p];return qa(l)}).filter(p=>!!p),a=yTe(n),m=n.encoding.order;let y;return ue(m)||we(m)?y=yV(m):y=a.reduce((p,l)=>(p.field.push(l),p.order.push(c==="y"?"descending":"ascending"),p),{field:[],order:[]}),new Uo(t,{dimensionFieldDefs:u,stackField:n.vgField(c),facetby:[],stackby:a,sort:y,offset:d,impute:f,as:[n.vgField(c,{suffix:"start",forAs:!0}),n.vgField(c,{suffix:"end",forAs:!0})]})}get stack(){return this._stack}addDimensions(t){this._stack.facetby.push(...t)}dependentFields(){const t=new Set;return t.add(this._stack.stackField),this.getGroupbyFields().forEach(t.add,t),this._stack.facetby.forEach(t.add,t),this._stack.sort.field.forEach(t.add,t),t}producedFields(){return new Set(this._stack.as)}hash(){return`Stack ${Bt(this._stack)}`}getGroupbyFields(){const{dimensionFieldDefs:t,impute:n,groupby:i}=this._stack;return t.length>0?t.map(s=>s.bin?n?[ve(s,{binSuffix:"mid"})]:[ve(s,{}),ve(s,{binSuffix:"end"})]:[ve(s)]).flat():i??[]}assemble(){const t=[],{facetby:n,dimensionFieldDefs:i,stackField:s,stackby:o,sort:c,offset:d,impute:f,as:u}=this._stack;if(f)for(const a of i){const{bandPosition:m=.5,bin:y}=a;if(y){const p=ve(a,{expr:"datum"}),l=ve(a,{expr:"datum",binSuffix:"end"});t.push({type:"formula",expr:`${m}*${p}+${1-m}*${l}`,as:ve(a,{binSuffix:"mid",forAs:!0})})}t.push({type:"impute",field:s,groupby:[...o,...n],key:ve(a,{binSuffix:"mid"}),method:"value",value:0})}return t.push({type:"stack",groupby:[...this.getGroupbyFields(),...n],field:s,sort:c,as:u,offset:d}),t}}class qh extends Kt{clone(){return new qh(null,at(this.transform))}constructor(t,n){super(t),this.transform=n}addDimensions(t){this.transform.groupby=Ta(this.transform.groupby.concat(t),n=>n)}dependentFields(){var t,n;const i=new Set;return((t=this.transform.groupby)!==null&&t!==void 0?t:[]).forEach(i.add,i),((n=this.transform.sort)!==null&&n!==void 0?n:[]).forEach(s=>i.add(s.field)),this.transform.window.map(s=>s.field).filter(s=>s!==void 0).forEach(i.add,i),i}producedFields(){return new Set(this.transform.window.map(this.getDefaultName))}getDefaultName(t){var n;return(n=t.as)!==null&&n!==void 0?n:ve(t)}hash(){return`WindowTransform ${Bt(this.transform)}`}assemble(){var t;const n=[],i=[],s=[],o=[];for(const y of this.transform.window)i.push(y.op),s.push(this.getDefaultName(y)),o.push(y.param===void 0?null:y.param),n.push(y.field===void 0?null:y.field);const c=this.transform.frame,d=this.transform.groupby;if(c&&c[0]===null&&c[1]===null&&i.every(y=>GE(y)))return Object.assign({type:"joinaggregate",as:s,ops:i,fields:n},d!==void 0?{groupby:d}:{});const f=[],u=[];if(this.transform.sort!==void 0)for(const y of this.transform.sort)f.push(y.field),u.push((t=y.order)!==null&&t!==void 0?t:"ascending");const a={field:f,order:u},m=this.transform.ignorePeers;return Object.assign(Object.assign(Object.assign({type:"window",params:o,as:s,ops:i,fields:n,sort:a},m!==void 0?{ignorePeers:m}:{}),d!==void 0?{groupby:d}:{}),c!==void 0?{frame:c}:{})}}function wTe(e){function t(n){if(!(n instanceof $h)){const i=n.clone();if(i instanceof Ui){const s=s9+i.getSource();i.setSource(s),e.model.component.data.outputNodes[s]=i}else(i instanceof jr||i instanceof Uo||i instanceof qh||i instanceof Sf)&&i.addDimensions(e.fields);for(const s of n.children.flatMap(t))s.parent=i;return[i]}return n.children.flatMap(t)}return t}function i9(e){if(e instanceof $h)if(e.numChildren()===1&&!(e.children[0]instanceof Ui)){const t=e.children[0];(t instanceof jr||t instanceof Uo||t instanceof qh||t instanceof Sf)&&t.addDimensions(e.fields),t.swapWithParent(),i9(e)}else{const t=e.model.component.data.main;UW(t);const n=wTe(e),i=e.children.map(n).flat();for(const s of i)s.parent=t}else e.children.map(i9)}function UW(e){if(e instanceof Ui&&e.type===en.Main&&e.numChildren()===1){const t=e.children[0];t instanceof $h||(t.swapWithParent(),UW(e))}}const s9="scale_",u_=5;function r9(e){for(const t of e){for(const n of t.children)if(n.parent!==t)return!1;if(!r9(t.children))return!1}return!0}function hr(e,t){let n=!1;for(const i of t)n=e.optimize(i)||n;return n}function YM(e,t,n){let i=e.sources,s=!1;return s=hr(new cTe,i)||s,s=hr(new oTe(t),i)||s,i=i.filter(o=>o.numChildren()>0),s=hr(new uTe,i)||s,i=i.filter(o=>o.numChildren()>0),n||(s=hr(new dTe,i)||s,s=hr(new _Te(t),i)||s,s=hr(new lTe,i)||s,s=hr(new fTe,i)||s,s=hr(new gTe,i)||s,s=hr(new hTe,i)||s,s=hr(new aTe,i)||s,s=hr(new pTe,i)||s),e.sources=i,s}function LTe(e,t){r9(e.sources);let n=0,i=0;for(let s=0;st(n))}}var bTe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s({signal:`{data: ${d6(i,{timeUnit:n,type:t})}}`}))}function f5(e,t,n){var i;const s=(i=xi(n))===null||i===void 0?void 0:i.unit;return t==="temporal"||s?xTe(e,t,s):[e]}function ml(e,t,n,i){const{encoding:s}=n,o=An(s[i]),{type:c}=o,d=o.timeUnit;if(HLe(t)){const m=ml(e,void 0,n,i),y=f5(t.unionWith,c,d);return la([...y,...m.value])}else{if(Ne(t))return la([t]);if(t&&t!=="unaggregated"&&!UV(t))return la(f5(t,c,d))}const f=n.stack;if(f&&i===f.fieldChannel){if(f.offset==="normalize")return vs([[0,1]]);const m=n.requestDataName(en.Main);return vs([{data:m,field:n.vgField(i,{suffix:"start"})},{data:m,field:n.vgField(i,{suffix:"end"})}])}const u=Mc(i)&&we(o)?BTe(n,i,e):void 0;if(co(o)){const m=f5([o.datum],c,d);return vs(m)}const a=o;if(t==="unaggregated"){const m=n.requestDataName(en.Main),{field:y}=o;return vs([{data:m,field:ve({field:y,aggregate:"min"})},{data:m,field:ve({field:y,aggregate:"max"})}])}else if(nn(a.bin)){if(Jn(e))return vs(e==="bin-ordinal"?[]:[{data:Z2(u)?n.requestDataName(en.Main):n.requestDataName(en.Raw),field:n.vgField(i,c3(a,i)?{binSuffix:"range"}:{}),sort:u===!0||!ke(u)?{field:n.vgField(i,{}),op:"min"}:u}]);{const{bin:m}=a;if(nn(m)){const y=VS(n,a.field,m);return vs([new ls(()=>{const p=n.getSignalName(y);return`[${p}.start, ${p}.stop]`})])}else return vs([{data:n.requestDataName(en.Main),field:n.vgField(i,{})}])}}else if(a.timeUnit&&vt(["time","utc"],e)&&iG(a,Ln(n)?n.encoding[oo(i)]:void 0,n.markDef,n.config)){const m=n.requestDataName(en.Main);return vs([{data:m,field:n.vgField(i)},{data:m,field:n.vgField(i,{suffix:"end"})}])}else return vs(u?[{data:Z2(u)?n.requestDataName(en.Main):n.requestDataName(en.Raw),field:n.vgField(i),sort:u}]:[{data:n.requestDataName(en.Main),field:n.vgField(i)}])}function u5(e,t){const{op:n,field:i,order:s}=e;return Object.assign(Object.assign({op:n??(t?"sum":r6)},i?{field:ar(i)}:{}),s?{order:s}:{})}function kTe(e,t){var n;const i=e.component.scales[t],s=e.specifiedScales[t].domain,o=(n=e.fieldDef(t))===null||n===void 0?void 0:n.bin,c=UV(s)&&s,d=bf(o)&&Qm(o.extent)&&o.extent;(c||d)&&i.set("selectionExtent",c??d,!0)}function BTe(e,t,n){if(!Jn(n))return;const i=e.fieldDef(t),s=i.sort;if(eG(s))return{op:"min",field:yh(i,t),order:"ascending"};const{stack:o}=e,c=o?new Set([...o.groupbyFields,...o.stackBy.map(d=>d.fieldDef.field)]):void 0;if(Ba(s)){const d=o&&!c.has(s.field);return u5(s,d)}else if(QV(s)){const{encoding:d,order:f}=s,u=e.fieldDef(d),{aggregate:a,field:m}=u,y=o&&!c.has(m);if(Yo(a)||Ac(a))return u5({field:ve(u),order:f},y);if(GE(a)||!a)return u5({op:a,field:m,order:f},y)}else{if(s==="descending")return{op:"min",field:e.vgField(t),order:"descending"};if(vt(["ascending",void 0],s))return!0}}function XM(e,t){const{aggregate:n,type:i}=e;return n?xe(n)&&!Qwe.has(n)?{valid:!1,reason:q5e(n)}:i==="quantitative"&&t==="log"?{valid:!1,reason:V5e(e)}:{valid:!0}:{valid:!1,reason:$5e(e)}}function a9(e,t,n,i){return e.explicit&&t.explicit&&me(K5e(n,i,e.value,t.value)),{explicit:e.explicit,value:[...e.value,...t.value]}}function FTe(e){const t=Ta(e.map(c=>Mo(c)?bTe(c,["sort"]):c),Bt),n=Ta(e.map(c=>{if(Mo(c)){const d=c.sort;return d!==void 0&&!Z2(d)&&("op"in d&&d.op==="count"&&delete d.field,d.order==="ascending"&&delete d.order),d}}).filter(c=>c!==void 0),Bt);if(t.length===0)return;if(t.length===1){const c=e[0];if(Mo(c)&&n.length>0){let d=n[0];if(n.length>1)me(lM),d=!0;else if(ke(d)&&"field"in d){const f=d.field;c.field===f&&(d=d.order?{order:d.order}:!0)}return Object.assign(Object.assign({},c),{sort:d})}return c}const i=Ta(n.map(c=>Z2(c)||!("op"in c)||xe(c.op)&&c.op in Xwe?c:(me(J5e(c)),!0)),Bt);let s;i.length===1?s=i[0]:i.length>1&&(me(lM),s=!0);const o=Ta(e.map(c=>Mo(c)?c.data:null),c=>c);return o.length===1&&o[0]!==null?Object.assign({data:o[0],fields:t.map(d=>d.field)},s?{sort:s}:{}):Object.assign({fields:t},s?{sort:s}:{})}function XS(e){if(Mo(e)&&xe(e.field))return e.field;if(t5e(e)){let t;for(const n of e.fields)if(Mo(n)&&xe(n.field)){if(!t)t=n.field;else if(t!==n.field)return me(Q5e),t}return me(eLe),t}else if(n5e(e)){me(tLe);const t=e.fields[0];return xe(t)?t:void 0}}function L6(e,t){const i=e.component.scales[t].get("domains").map(s=>(Mo(s)&&(s.data=e.lookupDataSource(s.data)),s));return FTe(i)}var ITe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);st.concat(zW(n)),KM(e)):KM(e)}function KM(e){return ye(e.component.scales).reduce((t,n)=>{const i=e.component.scales[n];if(i.merged)return t;const s=i.combine(),{name:o,type:c,selectionExtent:d,domains:f,range:u,reverse:a}=s,m=ITe(s,["name","type","selectionExtent","domains","range","reverse"]),y=OTe(s.range,o,n,e),p=L6(e,n),l=d?b7e(e,d,i,p):null;return t.push(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({name:o,type:c},p?{domain:p}:{}),l?{domainRaw:l}:{}),{range:y}),a!==void 0?{reverse:a}:{}),m)),t},[])}function OTe(e,t,n,i){if(Zn(n)){if(Nc(e))return{step:{signal:`${t}_step`}}}else if(ke(e)&&Mo(e))return Object.assign(Object.assign({},e),{data:i.lookupDataSource(e.data)});return e}class $W extends ll{constructor(t,n){super({},{name:t}),this.merged=!1,this.setWithExplicit("type",n)}domainDefinitelyIncludesZero(){return this.get("zero")!==!1?!0:Gd(this.get("domains"),t=>ue(t)&&t.length===2&&t[0]<=0&&t[1]>=0)}}const MTe=["range","scheme"];function ATe(e){const t=e.component.scales;for(const n of Jm){const i=t[n];if(!i)continue;const s=NTe(n,e);i.setWithExplicit("range",s)}}function ZM(e,t){const n=e.fieldDef(t);if(n!=null&&n.bin){const{bin:i,field:s}=n,o=ms(t),c=e.getName(o);if(ke(i)&&i.binned&&i.step!==void 0)return new ls(()=>{const d=e.scaleName(t),f=`(domain("${d}")[1] - domain("${d}")[0]) / ${i.step}`;return`${e.getSignalName(c)} / (${f})`});if(nn(i)){const d=VS(e,s,i);return new ls(()=>{const f=e.getSignalName(d),u=`(${f}.stop - ${f}.start) / ${f}.step`;return`${e.getSignalName(c)} / (${u})`})}}}function NTe(e,t){const n=t.specifiedScales[e],{size:i}=t,o=t.getScaleComponent(e).get("type");for(const m of MTe)if(n[m]!==void 0){const y=j8(o,m),p=HV(e,m);if(!y)me(EV(o,m,e));else if(p)me(p);else switch(m){case"range":{const l=n.range;if(ue(l)){if(Zn(e))return la(l.map(b=>{if(b==="width"||b==="height"){const L=t.getName(b),E=t.getSignalName.bind(t);return ls.fromName(E,L)}return b}))}else if(ke(l))return la({data:t.requestDataName(en.Main),field:l.field,sort:{op:"min",field:t.vgField(e)}});return la(l)}case"scheme":return la(CTe(n[m]))}}const c=e===hn||e==="xOffset"?"width":"height",d=i[c];if(Ga(d)){if(Zn(e))if(Jn(o)){const m=qW(d,t,e);if(m)return la({step:m})}else me(SV(c));else if(jh(e)){const m=e===kc?"x":"y";if(t.getScaleComponent(m).get("type")==="band"){const l=VW(d,o);if(l)return la(l)}}}const{rangeMin:f,rangeMax:u}=n,a=RTe(e,t);return(f!==void 0||u!==void 0)&&j8(o,"rangeMin")&&ue(a)&&a.length===2?la([f??a[0],u??a[1]]):vs(a)}function CTe(e){return ULe(e)?Object.assign({scheme:e.name},as(e,["name"])):{scheme:e}}function RTe(e,t){const{size:n,config:i,mark:s,encoding:o}=t,c=t.getSignalName.bind(t),{type:d}=An(o[e]),u=t.getScaleComponent(e).get("type"),{domain:a,domainMid:m}=t.specifiedScales[e];switch(e){case hn:case Kn:{if(vt(["point","band"],u)){const l=GW(e,n,i.view);if(Ga(l))return{step:qW(l,t,e)}}const y=ms(e),p=t.getName(y);return e===Kn&&Us(u)?[ls.fromName(c,p),0]:[0,ls.fromName(c,p)]}case kc:case Dh:return PTe(e,t,u);case rl:{const y=t.component.scales[e].get("zero"),p=WW(s,y,i),l=UTe(s,n,t,i);return dh(u)?jTe(p,l,DTe(u,i,a,e)):[p,l]}case dr:return[0,Math.PI*2];case wf:return[0,360];case Qr:return[0,new ls(()=>{const y=t.getSignalName("width"),p=t.getSignalName("height");return`min(${y},${p})/2`})];case Ic:return[i.scale.minStrokeWidth,i.scale.maxStrokeWidth];case Oc:return[[1,0],[4,2],[2,1],[1,1],[1,2,4,2]];case ys:return"symbol";case ps:case ro:case ao:return u==="ordinal"?d==="nominal"?"category":"ordinal":m!==void 0?"diverging":s==="rect"||s==="geoshape"?"heatmap":"ramp";case al:case Bc:case Fc:return[i.scale.minOpacity,i.scale.maxOpacity]}}function qW(e,t,n){var i,s,o,c,d;const{encoding:f}=t,u=t.getScaleComponent(n),a=rV(n),m=f[a];if(AG({step:e,offsetIsDiscrete:Je(m)&&CV(m.type)})==="offset"&&gG(f,a)){const p=t.getScaleComponent(a);let b=`domain('${t.scaleName(a)}').length`;if(p.get("type")==="band"){const E=(s=(i=p.get("paddingInner"))!==null&&i!==void 0?i:p.get("padding"))!==null&&s!==void 0?s:0,S=(c=(o=p.get("paddingOuter"))!==null&&o!==void 0?o:p.get("padding"))!==null&&c!==void 0?c:0;b=`bandspace(${b}, ${E}, ${S})`}const L=(d=u.get("paddingInner"))!==null&&d!==void 0?d:u.get("padding");return{signal:`${e.step} * ${b} / (1-${a5e(L)})`}}else return e.step}function VW(e,t){if(AG({step:e,offsetIsDiscrete:Jn(t)})==="offset")return{step:e.step}}function PTe(e,t,n){const i=e===kc?"x":"y",o=t.getScaleComponent(i).get("type"),c=t.scaleName(i);if(o==="band"){const d=GW(i,t.size,t.config.view);if(Ga(d)){const f=VW(d,n);if(f)return f}return[0,{signal:`bandwidth('${c}')`}]}else return Gq(`Cannot use ${e} scale if ${i} scale is not discrete.`)}function GW(e,t,n){const i=e===hn?"width":"height",s=t[i];return s||Qy(n,i)}function DTe(e,t,n,i){switch(e){case"quantile":return t.scale.quantileCount;case"quantize":return t.scale.quantizeCount;case"threshold":return n!==void 0&&ue(n)?n.length+1:(me(dLe(i)),3)}}function jTe(e,t,n){const i=()=>{const s=jo(t),o=jo(e),c=`(${s} - ${o}) / (${n} - 1)`;return`sequence(${o}, ${s} + ${c}, ${c})`};return Ne(t)?new ls(i):{signal:i()}}function WW(e,t,n){if(t)return Ne(t)?{signal:`${t.signal} ? 0 : ${WW(e,!1,n)}`}:0;switch(e){case"bar":case"tick":return n.scale.minBandSize;case"line":case"trail":case"rule":return n.scale.minStrokeWidth;case"text":return n.scale.minFontSize;case"point":case"square":case"circle":return n.scale.minSize}throw new Error(e6("size",e))}const JM=.95;function UTe(e,t,n,i){const s={x:ZM(n,"x"),y:ZM(n,"y")};switch(e){case"bar":case"tick":{if(i.scale.maxBandSize!==void 0)return i.scale.maxBandSize;const o=QM(t,s,i.view);return Yt(o)?o-1:new ls(()=>`${o.signal} - 1`)}case"line":case"trail":case"rule":return i.scale.maxStrokeWidth;case"text":return i.scale.maxFontSize;case"point":case"square":case"circle":{if(i.scale.maxSize)return i.scale.maxSize;const o=QM(t,s,i.view);return Yt(o)?Math.pow(JM*o,2):new ls(()=>`pow(${JM} * ${o.signal}, 2)`)}}throw new Error(e6("size",e))}function QM(e,t,n){const i=Ga(e.width)?e.width.step:Jy(n,"width"),s=Ga(e.height)?e.height.step:Jy(n,"height");return t.x||t.y?new ls(()=>`min(${[t.x?t.x.signal:i,t.y?t.y.signal:s].join(", ")})`):Math.min(i,s)}function YW(e,t){Ln(e)?HTe(e,t):KW(e,t)}function HTe(e,t){const n=e.component.scales,{config:i,encoding:s,markDef:o,specifiedScales:c}=e;for(const d of ye(n)){const f=c[d],u=n[d],a=e.getScaleComponent(d),m=An(s[d]),y=f[t],p=a.get("type"),l=a.get("padding"),b=a.get("paddingInner"),L=j8(p,t),E=HV(d,t);if(y!==void 0&&(L?E&&me(E):me(EV(p,t,d))),L&&E===void 0)if(y!==void 0){const S=m.timeUnit,x=m.type;switch(t){case"domainMax":case"domainMin":Tf(f[t])||x==="temporal"||S?u.set(t,{signal:d6(f[t],{type:x,timeUnit:S})},!0):u.set(t,f[t],!0);break;default:u.copyKeyFromObject(t,f)}}else{const S=t in eA?eA[t]({model:e,channel:d,fieldOrDatumDef:m,scaleType:p,scalePadding:l,scalePaddingInner:b,domain:f.domain,domainMin:f.domainMin,domainMax:f.domainMax,markDef:o,config:i,hasNestedOffsetScale:$8(s,d),hasSecondaryRangeChannel:!!s[oo(d)]}):i.scale[t];S!==void 0&&u.set(t,S,!1)}}}const eA={bins:({model:e,fieldOrDatumDef:t})=>we(t)?zTe(e,t):void 0,interpolate:({channel:e,fieldOrDatumDef:t})=>$Te(e,t.type),nice:({scaleType:e,channel:t,domain:n,domainMin:i,domainMax:s,fieldOrDatumDef:o})=>qTe(e,t,n,i,s,o),padding:({channel:e,scaleType:t,fieldOrDatumDef:n,markDef:i,config:s})=>VTe(e,t,s.scale,n,i,s.bar),paddingInner:({scalePadding:e,channel:t,markDef:n,scaleType:i,config:s,hasNestedOffsetScale:o})=>GTe(e,t,n.type,i,s.scale,o),paddingOuter:({scalePadding:e,channel:t,scaleType:n,scalePaddingInner:i,config:s,hasNestedOffsetScale:o})=>WTe(e,t,n,i,s.scale,o),reverse:({fieldOrDatumDef:e,scaleType:t,channel:n,config:i})=>{const s=we(e)?e.sort:void 0;return YTe(t,s,n,i.scale)},zero:({channel:e,fieldOrDatumDef:t,domain:n,markDef:i,scaleType:s,config:o,hasSecondaryRangeChannel:c})=>XTe(e,t,n,i,s,o.scale,c)};function XW(e){Ln(e)?ATe(e):KW(e,"range")}function KW(e,t){const n=e.component.scales;for(const i of e.children)t==="range"?XW(i):YW(i,t);for(const i of ye(n)){let s;for(const o of e.children){const c=o.component.scales[i];if(c){const d=c.getWithExplicit(t);s=fc(s,d,t,"scale",WG((f,u)=>{switch(t){case"range":return f.step&&u.step?f.step-u.step:0}return 0}))}}n[i].setWithExplicit(t,s)}}function zTe(e,t){const n=t.bin;if(nn(n)){const i=VS(e,t.field,n);return new ls(()=>e.getSignalName(i))}else if(ei(n)&&bf(n)&&n.step!==void 0)return{step:n.step}}function $Te(e,t){if(vt([ps,ro,ao],e)&&t!=="nominal")return"hcl"}function qTe(e,t,n,i,s,o){var c;if(!(!((c=qa(o))===null||c===void 0)&&c.bin||ue(n)||s!=null||i!=null||vt([os.TIME,os.UTC],e)))return Zn(t)?!0:void 0}function VTe(e,t,n,i,s,o){if(Zn(e)){if(Ar(t)){if(n.continuousPadding!==void 0)return n.continuousPadding;const{type:c,orient:d}=s;if(c==="bar"&&!(we(i)&&(i.bin||i.timeUnit))&&(d==="vertical"&&e==="x"||d==="horizontal"&&e==="y"))return o.continuousBandSize}if(t===os.POINT)return n.pointPadding}}function GTe(e,t,n,i,s,o=!1){if(e===void 0){if(Zn(t)){const{bandPaddingInner:c,barBandPaddingInner:d,rectBandPaddingInner:f,bandWithNestedOffsetPaddingInner:u}=s;return o?u:Sn(c,n==="bar"?d:f)}else if(jh(t)&&i===os.BAND)return s.offsetBandPaddingInner}}function WTe(e,t,n,i,s,o=!1){if(e===void 0){if(Zn(t)){const{bandPaddingOuter:c,bandWithNestedOffsetPaddingOuter:d}=s;if(o)return d;if(n===os.BAND)return Sn(c,Ne(i)?{signal:`${i.signal}/2`}:i/2)}else if(jh(t)){if(n===os.POINT)return .5;if(n===os.BAND)return s.offsetBandPaddingOuter}}}function YTe(e,t,n,i){if(n==="x"&&i.xReverse!==void 0)return Us(e)&&t==="descending"?Ne(i.xReverse)?{signal:`!${i.xReverse.signal}`}:!i.xReverse:i.xReverse;if(Us(e)&&t==="descending")return!0}function XTe(e,t,n,i,s,o,c){if(!!n&&n!=="unaggregated"&&Us(s)){if(ue(n)){const f=n[0],u=n[n.length-1];if(f<=0&&u>=0)return!0}return!1}if(e==="size"&&t.type==="quantitative"&&!dh(s))return!0;if(!(we(t)&&t.bin)&&vt([...lo,...Hwe],e)){const{orient:f,type:u}=i;return vt(["bar","area","line","trail"],u)&&(f==="horizontal"&&e==="y"||f==="vertical"&&e==="x")?!1:vt(["bar","area"],u)&&!c?!0:o==null?void 0:o.zero}return!1}function KTe(e,t,n,i,s=!1){const o=ZTe(t,n,i,s),{type:c}=e;return Mc(t)?c!==void 0?WLe(t,c)?we(n)&&!GLe(c,n.type)?(me(Y5e(c,o)),o):c:(me(W5e(t,c,o)),o):o:null}function ZTe(e,t,n,i){var s;switch(t.type){case"nominal":case"ordinal":{if(Tu(e)||s5(e)==="discrete")return e==="shape"&&t.type==="ordinal"&&me(r5(e,"ordinal")),"ordinal";if(Zn(e)||jh(e)){if(vt(["rect","bar","image","rule"],n.type)||i)return"band"}else if(n.type==="arc"&&e in VE)return"band";const o=n[ms(e)];return Zd(o)||uh(t)&&(!((s=t.axis)===null||s===void 0)&&s.tickBand)?"band":"point"}case"temporal":return Tu(e)?"time":s5(e)==="discrete"?(me(r5(e,"temporal")),"ordinal"):we(t)&&t.timeUnit&&xi(t.timeUnit).utc?"utc":"time";case"quantitative":return Tu(e)?we(t)&&nn(t.bin)?"bin-ordinal":"linear":s5(e)==="discrete"?(me(r5(e,"quantitative")),"ordinal"):"linear";case"geojson":return}throw new Error(TV(t.type))}function JTe(e,{ignoreRange:t}={}){ZW(e),HW(e);for(const n of VLe)YW(e,n);t||XW(e)}function ZW(e){Ln(e)?e.component.scales=QTe(e):e.component.scales=tve(e)}function QTe(e){const{encoding:t,mark:n,markDef:i}=e,s={};for(const o of Jm){const c=An(t[o]);if(c&&n===qV&&o===ys&&c.type===Uh)continue;let d=c&&c.scale;if(jh(o)){const f=aV(o);if(!$8(t,f)){d&&me(A5e(o));continue}}if(c&&d!==null&&d!==!1){d??(d={});const f=$8(t,o),u=KTe(d,o,c,i,f);s[o]=new $W(e.scaleName(`${o}`,!0),{value:u,explicit:d.type===u})}}return s}const eve=WG((e,t)=>dM(e)-dM(t));function tve(e){var t,n;const i=e.component.scales={},s={},o=e.component.resolve;for(const c of e.children){ZW(c);for(const d of ye(c.component.scales))if((t=(n=o.scale)[d])!==null&&t!==void 0||(n[d]=BW(d,e)),o.scale[d]==="shared"){const f=s[d],u=c.component.scales[d].getWithExplicit("type");f?CLe(f.value,u.value)?s[d]=fc(f,u,"type","scale",eve):(o.scale[d]="independent",delete s[d]):s[d]=u}}for(const c of ye(s)){const d=e.scaleName(c,!0),f=s[c];i[c]=new $W(d,f);for(const u of e.children){const a=u.component.scales[c];a&&(u.renameScale(a.get("name"),d),a.merged=!0)}}return i}var h5=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{var m,y,p;return!((m=a.from)===null||m===void 0)&&m.data&&(a.from.data=this.lookupDataSource(a.from.data)),!((p=(y=a.from)===null||y===void 0?void 0:y.facet)===null||p===void 0)&&p.data&&(a.from.facet.data=this.lookupDataSource(a.from.facet.data)),a},this.parent=i,this.config=o,this.view=es(d),this.name=(f=t.name)!==null&&f!==void 0?f:s,this.title=xl(t.title)?{text:t.title}:t.title?es(t.title):void 0,this.scaleNameMap=i?i.scaleNameMap:new g5,this.projectionNameMap=i?i.projectionNameMap:new g5,this.signalNameMap=i?i.signalNameMap:new g5,this.data=t.data,this.description=t.description,this.transforms=s7e((u=t.transform)!==null&&u!==void 0?u:[]),this.layout=n==="layer"||n==="unit"?{}:d9e(t,n,o),this.component={data:{sources:i?i.component.data.sources:[],outputNodes:i?i.component.data.outputNodes:{},outputNodeRefCounts:i?i.component.data.outputNodeRefCounts:{},isFaceted:a6(t)||(i==null?void 0:i.component.data.isFaceted)&&t.data===void 0},layoutSize:new ll,layoutHeaders:{row:{},column:{},facet:{}},mark:null,resolve:Object.assign({scale:{},axis:{},legend:{}},c?at(c):{}),selection:null,scales:null,projection:null,axes:{},legends:{}}}get width(){return this.getSizeSignalRef("width")}get height(){return this.getSizeSignalRef("height")}parse(){this.parseScale(),this.parseLayoutSize(),this.renameTopLevelLayoutSizeSignal(),this.parseSelections(),this.parseProjection(),this.parseData(),this.parseAxesAndHeaders(),this.parseLegends(),this.parseMarkGroup()}parseScale(){JTe(this)}parseProjection(){DW(this)}renameTopLevelLayoutSizeSignal(){this.getName("width")!=="width"&&this.renameSignal(this.getName("width"),"width"),this.getName("height")!=="height"&&this.renameSignal(this.getName("height"),"height")}parseLegends(){AW(this)}assembleEncodeFromView(t){const n=h5(t,["style"]),i={};for(const s of ye(n)){const o=n[s];o!==void 0&&(i[s]=on(o))}return i}assembleGroupEncodeEntry(t){let n={};return this.view&&(n=this.assembleEncodeFromView(this.view)),!t&&(this.description&&(n.description=on(this.description)),this.type==="unit"||this.type==="layer")?Object.assign({width:this.getSizeSignalRef("width"),height:this.getSizeSignalRef("height")},n??{}):Wt(n)?void 0:n}assembleLayout(){if(!this.layout)return;const t=this.layout,{spacing:n}=t,i=h5(t,["spacing"]),{component:s,config:o}=this,c=mbe(s.layoutHeaders,o);return Object.assign(Object.assign(Object.assign({padding:n},this.assembleDefaultLayout()),i),c?{titleBand:c}:{})}assembleDefaultLayout(){return{}}assembleHeaderMarks(){const{layoutHeaders:t}=this.component;let n=[];for(const i of Ks)t[i].title&&n.push(ube(this,i));for(const i of HS)n=n.concat(hbe(this,i));return n}assembleAxes(){return ebe(this.component.axes,this.config)}assembleLegends(){return CW(this)}assembleProjections(){return zbe(this)}assembleTitle(){var t,n,i;const s=(t=this.title)!==null&&t!==void 0?t:{},{encoding:o}=s,c=h5(s,["encoding"]),d=Object.assign(Object.assign(Object.assign({},hV(this.config.title).nonMarkTitleProperties),c),o?{encode:{update:o}}:{});if(d.text)return vt(["unit","layer"],this.type)?vt(["middle",void 0],d.anchor)&&((n=d.frame)!==null&&n!==void 0||(d.frame="group")):(i=d.anchor)!==null&&i!==void 0||(d.anchor="start"),Wt(d)?void 0:d}assembleGroup(t=[]){const n={};t=t.concat(this.assembleSignals()),t.length>0&&(n.signals=t);const i=this.assembleLayout();i&&(n.layout=i),n.marks=[].concat(this.assembleHeaderMarks(),this.assembleMarks());const s=!this.parent||Ur(this.parent)?zW(this):[];s.length>0&&(n.scales=s);const o=this.assembleAxes();o.length>0&&(n.axes=o);const c=this.assembleLegends();return c.length>0&&(n.legends=c),n}getName(t){return dn((this.name?`${this.name}_`:"")+t)}getDataName(t){return this.getName(en[t].toLowerCase())}requestDataName(t){const n=this.getDataName(t),i=this.component.data.outputNodeRefCounts;return i[n]=(i[n]||0)+1,n}getSizeSignalRef(t){if(Ur(this.parent)){const n=xW(t),i=Zm(n),s=this.component.scales[i];if(s&&!s.merged){const o=s.get("type"),c=s.get("range");if(Jn(o)&&Nc(c)){const d=s.get("name"),f=L6(this,i),u=XS(f);if(u){const a=ve({aggregate:"distinct",field:u},{expr:"datum"});return{signal:SW(d,s,a)}}else return me(XE(i)),null}}}return{signal:this.signalNameMap.get(this.getName(t))}}lookupDataSource(t){const n=this.component.data.outputNodes[t];return n?n.getSource():t}getSignalName(t){return this.signalNameMap.get(t)}renameSignal(t,n){this.signalNameMap.rename(t,n)}renameScale(t,n){this.scaleNameMap.rename(t,n)}renameProjection(t,n){this.projectionNameMap.rename(t,n)}scaleName(t,n){if(n)return this.getName(t);if(iV(t)&&Mc(t)&&this.component.scales[t]||this.scaleNameMap.has(this.getName(t)))return this.scaleNameMap.get(this.getName(t))}projectionName(t){if(t)return this.getName("projection");if(this.component.projection&&!this.component.projection.merged||this.projectionNameMap.has(this.getName("projection")))return this.projectionNameMap.get(this.getName("projection"))}getScaleComponent(t){if(!this.component.scales)throw new Error("getScaleComponent cannot be called before parseScale(). Make sure you have called parseScale or use parseUnitModelWithScale().");const n=this.component.scales[t];return n&&!n.merged?n:this.parent?this.parent.getScaleComponent(t):void 0}getSelectionComponent(t,n){let i=this.component.selection[t];if(!i&&this.parent&&(i=this.parent.getSelectionComponent(t,n)),!i)throw new Error(f5e(n));return i}hasAxisOrientSignalRef(){var t,n;return((t=this.component.axes.x)===null||t===void 0?void 0:t.some(i=>i.hasOrientSignalRef()))||((n=this.component.axes.y)===null||n===void 0?void 0:n.some(i=>i.hasOrientSignalRef()))}}class JW extends ZS{vgField(t,n={}){const i=this.fieldDef(t);if(i)return ve(i,n)}reduceFieldDef(t,n){return D8e(this.getMapping(),(i,s,o)=>{const c=qa(s);return c?t(i,c,o):i},n)}forEachFieldDef(t,n){vS(this.getMapping(),(i,s)=>{const o=qa(i);o&&t(o,s)},n)}}var nve=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s{const m=Mc(a)&&n.getScaleComponent(a);if(m){const y=m.get("type");Us(y)&&u.aggregate!=="count"&&!Cc(s)&&(f[u.field]=u)}return f},{});return ye(d).length?new n0(t,d):null}dependentFields(){return new Set(ye(this.filter))}producedFields(){return new Set}hash(){return`FilterInvalid ${Bt(this.filter)}`}assemble(){const t=ye(this.filter).reduce((n,i)=>{const s=this.filter[i],o=ve(s,{expr:"datum"});return s!==null&&(s.type==="temporal"?n.push(`(isDate(${o}) || (isValid(${o}) && isFinite(+${o})))`):s.type==="quantitative"&&(n.push(`isValid(${o})`),n.push(`isFinite(+${o})`))),n},[]);return t.length>0?{type:"filter",expr:t.join(" && ")}:null}}class T6 extends Kt{clone(){return new T6(this.parent,at(this.transform))}constructor(t,n){super(t),this.transform=n,this.transform=at(n);const{flatten:i,as:s=[]}=this.transform;this.transform.as=i.map((o,c)=>{var d;return(d=s[c])!==null&&d!==void 0?d:o})}dependentFields(){return new Set(this.transform.flatten)}producedFields(){return new Set(this.transform.as)}hash(){return`FlattenTransform ${Bt(this.transform)}`}assemble(){const{flatten:t,as:n}=this.transform;return{type:"flatten",fields:t,as:n}}}class v6 extends Kt{clone(){return new v6(null,at(this.transform))}constructor(t,n){var i,s,o;super(t),this.transform=n,this.transform=at(n);const c=(i=this.transform.as)!==null&&i!==void 0?i:[void 0,void 0];this.transform.as=[(s=c[0])!==null&&s!==void 0?s:"key",(o=c[1])!==null&&o!==void 0?o:"value"]}dependentFields(){return new Set(this.transform.fold)}producedFields(){return new Set(this.transform.as)}hash(){return`FoldTransform ${Bt(this.transform)}`}assemble(){const{fold:t,as:n}=this.transform;return{type:"fold",fields:t,as:n}}}class Su extends Kt{clone(){return new Su(null,at(this.fields),this.geojson,this.signal)}static parseAll(t,n){if(n.component.projection&&!n.component.projection.isFit)return t;let i=0;for(const s of[[so,io],[or,ea]]){const o=s.map(c=>{const d=An(n.encoding[c]);return we(d)?d.field:co(d)?{expr:`${d.datum}`}:Vr(d)?{expr:`${d.value}`}:void 0});(o[0]||o[1])&&(t=new Su(t,o,null,n.getName(`geojson_${i++}`)))}if(n.channelHasField(ys)){const s=n.typedFieldDef(ys);s.type===Uh&&(t=new Su(t,null,s.field,n.getName(`geojson_${i++}`)))}return t}constructor(t,n,i,s){super(t),this.fields=n,this.geojson=i,this.signal=s}dependentFields(){var t;const n=((t=this.fields)!==null&&t!==void 0?t:[]).filter(xe);return new Set([...this.geojson?[this.geojson]:[],...n])}producedFields(){return new Set}hash(){return`GeoJSON ${this.geojson} ${this.signal} ${Bt(this.fields)}`}assemble(){return[...this.geojson?[{type:"filter",expr:`isValid(datum["${this.geojson}"])`}]:[],Object.assign(Object.assign(Object.assign({type:"geojson"},this.fields?{fields:this.fields}:{}),this.geojson?{geojson:this.geojson}:{}),{signal:this.signal})]}}class i0 extends Kt{clone(){return new i0(null,this.projection,at(this.fields),at(this.as))}constructor(t,n,i,s){super(t),this.projection=n,this.fields=i,this.as=s}static parseAll(t,n){if(!n.projectionName())return t;for(const i of[[so,io],[or,ea]]){const s=i.map(c=>{const d=An(n.encoding[c]);return we(d)?d.field:co(d)?{expr:`${d.datum}`}:Vr(d)?{expr:`${d.value}`}:void 0}),o=i[0]===or?"2":"";(s[0]||s[1])&&(t=new i0(t,n.projectionName(),s,[n.getName(`x${o}`),n.getName(`y${o}`)]))}return t}dependentFields(){return new Set(this.fields.filter(xe))}producedFields(){return new Set(this.as)}hash(){return`Geopoint ${this.projection} ${Bt(this.fields)} ${Bt(this.as)}`}assemble(){return{type:"geopoint",projection:this.projection,fields:this.fields,as:this.as}}}class Fd extends Kt{clone(){return new Fd(null,at(this.transform))}constructor(t,n){super(t),this.transform=n}dependentFields(){var t;return new Set([this.transform.impute,this.transform.key,...(t=this.transform.groupby)!==null&&t!==void 0?t:[]])}producedFields(){return new Set([this.transform.impute])}processSequence(t){const{start:n=0,stop:i,step:s}=t;return{signal:`sequence(${[n,i,...s?[s]:[]].join(",")})`}}static makeFromTransform(t,n){return new Fd(t,n)}static makeFromEncoding(t,n){const i=n.encoding,s=i.x,o=i.y;if(we(s)&&we(o)){const c=s.impute?s:o.impute?o:void 0;if(c===void 0)return;const d=s.impute?o:o.impute?s:void 0,{method:f,value:u,frame:a,keyvals:m}=c.impute,y=pG(n.mark,i);return new Fd(t,Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({impute:c.field,key:d.field},f?{method:f}:{}),u!==void 0?{value:u}:{}),a?{frame:a}:{}),m!==void 0?{keyvals:m}:{}),y.length?{groupby:y}:{}))}return null}hash(){return`Impute ${Bt(this.transform)}`}assemble(){const{impute:t,key:n,keyvals:i,method:s,groupby:o,value:c,frame:d=[null,null]}=this.transform,f=Object.assign(Object.assign(Object.assign(Object.assign({type:"impute",field:t,key:n},i?{keyvals:U9e(i)?this.processSequence(i):i}:{}),{method:"value"}),o?{groupby:o}:{}),{value:!s||s==="value"?c:null});if(s&&s!=="value"){const u=Object.assign({type:"window",as:[`imputed_${t}_value`],ops:[s],fields:[t],frame:d,ignorePeers:!1},o?{groupby:o}:{}),a={type:"formula",expr:`datum.${t} === null ? datum.imputed_${t}_value : datum.${t}`,as:t};return[f,u,a]}else return[f]}}var ive=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);si)}producedFields(){}dependentFields(){var t;return new Set([this.transform.pivot,this.transform.value,...(t=this.transform.groupby)!==null&&t!==void 0?t:[]])}hash(){return`PivotTransform ${Bt(this.transform)}`}assemble(){const{pivot:t,value:n,groupby:i,limit:s,op:o}=this.transform;return Object.assign(Object.assign(Object.assign({type:"pivot",field:t,value:n},s!==void 0?{limit:s}:{}),o!==void 0?{op:o}:{}),i!==void 0?{groupby:i}:{})}}class B6 extends Kt{clone(){return new B6(null,at(this.transform))}constructor(t,n){super(t),this.transform=n}dependentFields(){return new Set}producedFields(){return new Set}hash(){return`SampleTransform ${Bt(this.transform)}`}assemble(){return{type:"sample",size:this.transform.sample}}}function QW(e){let t=0;function n(i,s){var o;if(i instanceof tf&&!i.isGenerator&&!gh(i.data)&&(e.push(s),s={name:null,source:s.name,transform:[]}),i instanceof yi&&(i.parent instanceof tf&&!s.source?(s.format=Object.assign(Object.assign({},(o=s.format)!==null&&o!==void 0?o:{}),{parse:i.assembleFormatParse()}),s.transform.push(...i.assembleTransforms(!0))):s.transform.push(...i.assembleTransforms())),i instanceof $h){s.name||(s.name=`data_${t++}`),!s.source||s.transform.length>0?(e.push(s),i.data=s.name):i.data=s.source,e.push(...i.assemble());return}switch((i instanceof u3||i instanceof h3||i instanceof n0||i instanceof zh||i instanceof ph||i instanceof i0||i instanceof jr||i instanceof s0||i instanceof qh||i instanceof Sf||i instanceof v6||i instanceof T6||i instanceof b6||i instanceof E6||i instanceof S6||i instanceof x6||i instanceof _c||i instanceof B6||i instanceof k6)&&s.transform.push(i.assemble()),(i instanceof Ia||i instanceof Fa||i instanceof Fd||i instanceof Uo||i instanceof Su)&&s.transform.push(...i.assemble()),i instanceof Ui&&(s.source&&s.transform.length===0?i.setSource(s.source):i.parent instanceof Ui?i.setSource(s.name):(s.name||(s.name=`data_${t++}`),i.setSource(s.name),i.numChildren()===1&&(e.push(s),s={name:null,source:s.name,transform:[]}))),i.numChildren()){case 0:i instanceof Ui&&(!s.source||s.transform.length>0)&&e.push(s);break;case 1:n(i.children[0],s);break;default:{s.name||(s.name=`data_${t++}`);let c=s.name;!s.source||s.transform.length>0?e.push(s):c=s.source;for(const d of i.children)n(d,{name:null,source:c,transform:[]});break}}}return n}function ave(e){const t=[],n=QW(t);for(const i of e.children)n(i,{source:e.name,name:null,transform:[]});return t}function ove(e,t){var n,i;const s=[],o=QW(s);let c=0;for(const f of e.sources){f.hasName()||(f.dataName=`source_${c++}`);const u=f.assemble();o(f,u)}for(const f of s)f.transform.length===0&&delete f.transform;let d=0;for(const[f,u]of s.entries())((n=u.transform)!==null&&n!==void 0?n:[]).length===0&&!u.source&&s.splice(d++,0,s.splice(f,1)[0]);for(const f of s)for(const u of(i=f.transform)!==null&&i!==void 0?i:[])u.type==="lookup"&&(u.from=e.outputNodes[u.from].getSource());for(const f of s)f.name in t&&(f.values=t[f.name]);return s}function lve(e){return e==="top"||e==="left"||Ne(e)?"header":"footer"}function cve(e){for(const t of Ks)dve(e,t);tA(e,"x"),tA(e,"y")}function dve(e,t){var n;const{facet:i,config:s,child:o,component:c}=e;if(e.channelHasField(t)){const d=i[t],f=mh("title",null,s,t);let u=vu(d,s,{allowDisabling:!0,includeDefault:f===void 0||!!f});o.component.layoutHeaders[t].title&&(u=ue(u)?u.join(", "):u,u+=` / ${o.component.layoutHeaders[t].title}`,o.component.layoutHeaders[t].title=null);const a=mh("labelOrient",d.header,s,t),m=d.header!==null?Sn((n=d.header)===null||n===void 0?void 0:n.labels,s.header.labels,!0):!1,y=vt(["bottom","right"],a)?"footer":"header";c.layoutHeaders[t]={title:d.header!==null?u:null,facetFieldDef:d,[y]:t==="facet"?[]:[eY(e,t,m)]}}}function eY(e,t,n){const i=t==="row"?"height":"width";return{labels:n,sizeSignal:e.child.component.layoutSize.get(i)?e.child.getSizeSignalRef(i):void 0,axes:[]}}function tA(e,t){var n;const{child:i}=e;if(i.component.axes[t]){const{layoutHeaders:s,resolve:o}=e.component;if(o.axis[t]=qS(o,t),o.axis[t]==="shared"){const c=t==="x"?"column":"row",d=s[c];for(const f of i.component.axes[t]){const u=lve(f.get("orient"));(n=d[u])!==null&&n!==void 0||(d[u]=[eY(e,c,!1)]);const a=G1(f,"main",e.config,{header:!0});a&&d[u][0].axes.push(a),f.mainExtracted=!0}}}}function fve(e){JS(e),i4(e,"width"),i4(e,"height")}function uve(e){JS(e);const t=e.layout.columns===1?"width":"childWidth",n=e.layout.columns===void 0?"height":"childHeight";i4(e,t),i4(e,n)}function JS(e){for(const t of e.children)t.parseLayoutSize()}function i4(e,t){var n;const i=xW(t),s=Zm(i),o=e.component.resolve,c=e.component.layoutSize;let d;for(const f of e.children){const u=f.component.layoutSize.getWithExplicit(i),a=(n=o.scale[s])!==null&&n!==void 0?n:BW(s,e);if(a==="independent"&&u.value==="step"){d=void 0;break}if(d){if(a==="independent"&&d.value!==u.value){d=void 0;break}d=fc(d,u,i,"")}else d=u}if(d){for(const f of e.children)e.renameSignal(f.getName(i),e.getName(t)),f.component.layoutSize.set(i,"merged",!1);c.setWithExplicit(t,d)}else c.setWithExplicit(t,{explicit:!1,value:void 0})}function hve(e){const{size:t,component:n}=e;for(const i of lo){const s=ms(i);if(t[s]){const o=t[s];n.layoutSize.set(s,Ga(o)?"step":o,!0)}else{const o=gve(e,s);n.layoutSize.set(s,o,!1)}}}function gve(e,t){const n=t==="width"?"x":"y",i=e.config,s=e.getScaleComponent(n);if(s){const o=s.get("type"),c=s.get("range");if(Jn(o)){const d=Qy(i.view,t);return Nc(c)||Ga(d)?"step":d}else return V8(i.view,t)}else{if(e.hasProjection||e.mark==="arc")return V8(i.view,t);{const o=Qy(i.view,t);return Ga(o)?o.step:o}}}function o9(e,t,n){return ve(t,Object.assign({suffix:`by_${ve(e)}`},n??{}))}class f2 extends JW{constructor(t,n,i,s){super(t,"facet",n,i,s,t.resolve),this.child=ix(t.spec,this,this.getName("child"),void 0,s),this.children=[this.child],this.facet=this.initFacet(t.facet)}initFacet(t){if(!o3(t))return{facet:this.initFacetFieldDef(t,"facet")};const n=ye(t),i={};for(const s of n){if(![Po,Do].includes(s)){me(e6(s,"facet"));break}const o=t[s];if(o.field===void 0){me(P8(o,s));break}i[s]=this.initFacetFieldDef(o,s)}return i}initFacetFieldDef(t,n){const i=bS(t,n);return i.header?i.header=es(i.header):i.header===null&&(i.header=null),i}channelHasField(t){return!!this.facet[t]}fieldDef(t){return this.facet[t]}parseData(){this.component.data=F6(this),this.child.parseData()}parseLayoutSize(){JS(this)}parseSelections(){this.child.parseSelections(),this.component.selection=this.child.component.selection}parseMarkGroup(){this.child.parseMarkGroup()}parseAxesAndHeaders(){this.child.parseAxesAndHeaders(),cve(this)}assembleSelectionTopLevelSignals(t){return this.child.assembleSelectionTopLevelSignals(t)}assembleSignals(){return this.child.assembleSignals(),[]}assembleSelectionData(t){return this.child.assembleSelectionData(t)}getHeaderLayoutMixins(){var t,n,i;const s={};for(const o of Ks)for(const c of zS){const d=this.component.layoutHeaders[o],f=d[c],{facetFieldDef:u}=d;if(u){const a=mh("titleOrient",u.header,this.config,o);if(["right","bottom"].includes(a)){const m=m6(o,a);(t=s.titleAnchor)!==null&&t!==void 0||(s.titleAnchor={}),s.titleAnchor[m]="end"}}if(f!=null&&f[0]){const a=o==="row"?"height":"width",m=c==="header"?"headerBand":"footerBand";o!=="facet"&&!this.child.component.layoutSize.get(a)&&((n=s[m])!==null&&n!==void 0||(s[m]={}),s[m][o]=.5),d.title&&((i=s.offset)!==null&&i!==void 0||(s.offset={}),s.offset[o==="row"?"rowTitle":"columnTitle"]=10)}}return s}assembleDefaultLayout(){const{column:t,row:n}=this.facet,i=t?this.columnDistinctSignal():n?1:void 0;let s="all";return(!n&&this.component.resolve.scale.x==="independent"||!t&&this.component.resolve.scale.y==="independent")&&(s="none"),Object.assign(Object.assign(Object.assign({},this.getHeaderLayoutMixins()),i?{columns:i}:{}),{bounds:"full",align:s})}assembleLayoutSignals(){return this.child.assembleLayoutSignals()}columnDistinctSignal(){if(!(this.parent&&this.parent instanceof f2))return{signal:`length(data('${this.getName("column_domain")}'))`}}assembleGroupStyle(){}assembleGroup(t){return this.parent&&this.parent instanceof f2?Object.assign(Object.assign({},this.channelHasField("column")?{encode:{update:{columns:{field:ve(this.facet.column,{prefix:"distinct"})}}}}:{}),super.assembleGroup(t)):super.assembleGroup(t)}getCardinalityAggregateForChild(){const t=[],n=[],i=[];if(this.child instanceof f2){if(this.child.channelHasField("column")){const s=ve(this.child.facet.column);t.push(s),n.push("distinct"),i.push(`distinct_${s}`)}}else for(const s of lo){const o=this.child.component.scales[s];if(o&&!o.merged){const c=o.get("type"),d=o.get("range");if(Jn(c)&&Nc(d)){const f=L6(this.child,s),u=XS(f);u?(t.push(u),n.push("distinct"),i.push(`distinct_${u}`)):me(XE(s))}}}return{fields:t,ops:n,as:i}}assembleFacet(){const{name:t,data:n}=this.component.data.facetRoot,{row:i,column:s}=this.facet,{fields:o,ops:c,as:d}=this.getCardinalityAggregateForChild(),f=[];for(const a of Ks){const m=this.facet[a];if(m){f.push(ve(m));const{bin:y,sort:p}=m;if(nn(y)&&f.push(ve(m,{binSuffix:"end"})),Ba(p)){const{field:l,op:b=r6}=p,L=o9(m,p);i&&s?(o.push(L),c.push("max"),d.push(L)):(o.push(l),c.push(b),d.push(L))}else if(ue(p)){const l=yh(m,a);o.push(l),c.push("max"),d.push(l)}}}const u=!!i&&!!s;return Object.assign({name:t,data:n,groupby:f},u||o.length>0?{aggregate:Object.assign(Object.assign({},u?{cross:u}:{}),o.length?{fields:o,ops:c,as:d}:{})}:{})}facetSortFields(t){const{facet:n}=this,i=n[t];return i?Ba(i.sort)?[o9(i,i.sort,{expr:"datum"})]:ue(i.sort)?[yh(i,t,{expr:"datum"})]:[ve(i,{expr:"datum"})]:[]}facetSortOrder(t){const{facet:n}=this,i=n[t];if(i){const{sort:s}=i;return[(Ba(s)?s.order:!ue(s)&&s)||"ascending"]}return[]}assembleLabelTitle(){var t;const{facet:n,config:i}=this;if(n.facet)return t9(n.facet,"facet",i);const s={row:["top","bottom"],column:["left","right"]};for(const o of HS)if(n[o]){const c=mh("labelOrient",(t=n[o])===null||t===void 0?void 0:t.header,i,o);if(s[o].includes(c))return t9(n[o],o,i)}}assembleMarks(){const{child:t}=this,n=this.component.data.facetRoot,i=ave(n),s=t.assembleGroupEncodeEntry(!1),o=this.assembleLabelTitle()||t.assembleTitle(),c=t.assembleGroupStyle();return[Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({name:this.getName("cell"),type:"group"},o?{title:o}:{}),c?{style:c}:{}),{from:{facet:this.assembleFacet()},sort:{field:Ks.map(f=>this.facetSortFields(f)).flat(),order:Ks.map(f=>this.facetSortOrder(f)).flat()}}),i.length>0?{data:i}:{}),s?{encode:{update:s}}:{}),t.assembleGroup(y7e(this,[])))]}getMapping(){return this.facet}}function _ve(e,t){const{row:n,column:i}=t;if(n&&i){let s=null;for(const o of[n,i])if(Ba(o.sort)){const{field:c,op:d=r6}=o.sort;e=s=new Sf(e,{joinaggregate:[{op:d,field:c,as:o9(o,o.sort,{forAs:!0})}],groupby:[ve(o)]})}return s}return null}function tY(e,t){var n,i,s,o;for(const c of t){const d=c.data;if(e.name&&c.hasName()&&e.name!==c.dataName)continue;const f=(n=e.format)===null||n===void 0?void 0:n.mesh,u=(i=d.format)===null||i===void 0?void 0:i.feature;if(f&&u)continue;const a=(s=e.format)===null||s===void 0?void 0:s.feature;if((a||u)&&a!==u)continue;const m=(o=d.format)===null||o===void 0?void 0:o.mesh;if(!((f||m)&&f!==m)){if(e0(e)&&e0(d)){if(ba(e.values,d.values))return c}else if(gh(e)&&gh(d)){if(e.url===d.url)return c}else if(YG(e)&&e.name===c.dataName)return c}}return null}function pve(e,t){if(e.data||!e.parent){if(e.data===null){const i=new tf({values:[]});return t.push(i),i}const n=tY(e.data,t);if(n)return Vl(e.data)||(n.data.format=Wq({},e.data.format,n.data.format)),!n.hasName()&&e.data.name&&(n.dataName=e.data.name),n;{const i=new tf(e.data);return t.push(i),i}}else return e.parent.component.data.facetRoot?e.parent.component.data.facetRoot:e.parent.component.data.main}function yve(e,t,n){var i,s;let o=0;for(const c of t.transforms){let d,f;if(J9e(c))f=e=new ph(e,c),d="derived";else if(NS(c)){const u=nTe(c);f=e=(i=yi.makeWithAncestors(e,{},u,n))!==null&&i!==void 0?i:e,e=new zh(e,t,c.filter)}else if(zG(c))f=e=Ia.makeFromTransform(e,c,t),d="number";else if(e7e(c))d="date",n.getWithExplicit(c.field).value===void 0&&(e=new yi(e,{[c.field]:d}),n.set(c.field,d,!1)),f=e=Fa.makeFromTransform(e,c);else if(t7e(c))f=e=jr.makeFromTransform(e,c),d="number",US(t)&&(e=new _c(e));else if(HG(c))f=e=s0.make(e,t,c,o++),d="derived";else if(X9e(c))f=e=new qh(e,c),d="number";else if(K9e(c))f=e=new Sf(e,c),d="number";else if(n7e(c))f=e=Uo.makeFromTransform(e,c),d="derived";else if(i7e(c))f=e=new v6(e,c),d="derived";else if(Z9e(c))f=e=new T6(e,c),d="derived";else if($9e(c))f=e=new k6(e,c),d="derived";else if(Y9e(c))e=new B6(e,c);else if(Q9e(c))f=e=Fd.makeFromTransform(e,c),d="derived";else if(q9e(c))f=e=new b6(e,c),d="derived";else if(V9e(c))f=e=new S6(e,c),d="derived";else if(G9e(c))f=e=new x6(e,c),d="derived";else if(W9e(c))f=e=new E6(e,c),d="derived";else{me(T5e(c));continue}if(f&&d!==void 0)for(const u of(s=f.producedFields())!==null&&s!==void 0?s:[])n.set(u,d,!1)}return e}function F6(e){var t,n,i,s,o,c,d,f,u,a;let m=pve(e,e.component.data.sources);const{outputNodes:y,outputNodeRefCounts:p}=e.component.data,l=e.data,L=!(l&&(Vl(l)||gh(l)||e0(l)))&&e.parent?e.parent.component.data.ancestorParse.clone():new g7e;Vl(l)?(XG(l)?m=new h3(m,l.sequence):CS(l)&&(m=new u3(m,l.graticule)),L.parseNothing=!0):((t=l==null?void 0:l.format)===null||t===void 0?void 0:t.parse)===null&&(L.parseNothing=!0),m=(n=yi.makeExplicit(m,e,L))!==null&&n!==void 0?n:m,m=new _c(m);const E=e.parent&&Vh(e.parent);(Ln(e)||Ur(e))&&E&&(m=(i=Ia.makeFromEncoding(m,e))!==null&&i!==void 0?i:m),e.transforms.length>0&&(m=yve(m,e,L));const S=sTe(e),x=iTe(e);m=(s=yi.makeWithAncestors(m,{},Object.assign(Object.assign({},S),x),L))!==null&&s!==void 0?s:m,Ln(e)&&(m=Su.parseAll(m,e),m=i0.parseAll(m,e)),(Ln(e)||Ur(e))&&(E||(m=(o=Ia.makeFromEncoding(m,e))!==null&&o!==void 0?o:m),m=(c=Fa.makeFromEncoding(m,e))!==null&&c!==void 0?c:m,m=ph.parseAllForSortIndex(m,e));const F=e.getDataName(en.Raw),k=new Ui(m,F,en.Raw,p);if(y[F]=k,m=k,Ln(e)){const P=jr.makeFromEncoding(m,e);P&&(m=P,US(e)&&(m=new _c(m))),m=(d=Fd.makeFromEncoding(m,e))!==null&&d!==void 0?d:m,m=(f=Uo.makeFromEncoding(m,e))!==null&&f!==void 0?f:m}Ln(e)&&(m=(u=n0.make(m,e))!==null&&u!==void 0?u:m);const M=e.getDataName(en.Main),O=new Ui(m,M,en.Main,p);y[M]=O,m=O,Ln(e)&&J7e(e,O);let C=null;if(Ur(e)){const P=e.getName("facet");m=(a=_ve(m,e.facet))!==null&&a!==void 0?a:m,C=new $h(m,e,P,O.getSource()),y[P]=C}return Object.assign(Object.assign({},e.component.data),{outputNodes:y,outputNodeRefCounts:p,raw:k,main:O,facetRoot:C,ancestorParse:L})}class mve extends ZS{constructor(t,n,i,s){var o,c,d,f;super(t,"concat",n,i,s,t.resolve),(((c=(o=t.resolve)===null||o===void 0?void 0:o.axis)===null||c===void 0?void 0:c.x)==="shared"||((f=(d=t.resolve)===null||d===void 0?void 0:d.axis)===null||f===void 0?void 0:f.y)==="shared")&&me(w5e),this.children=this.getChildren(t).map((u,a)=>ix(u,this,this.getName(`concat_${a}`),void 0,s))}parseData(){this.component.data=F6(this);for(const t of this.children)t.parseData()}parseSelections(){this.component.selection={};for(const t of this.children){t.parseSelections();for(const n of ye(t.component.selection))this.component.selection[n]=t.component.selection[n]}}parseMarkGroup(){for(const t of this.children)t.parseMarkGroup()}parseAxesAndHeaders(){for(const t of this.children)t.parseAxesAndHeaders()}getChildren(t){return h6(t)?t.vconcat:MS(t)?t.hconcat:t.concat}parseLayoutSize(){uve(this)}parseAxisGroup(){return null}assembleSelectionTopLevelSignals(t){return this.children.reduce((n,i)=>i.assembleSelectionTopLevelSignals(n),t)}assembleSignals(){return this.children.forEach(t=>t.assembleSignals()),[]}assembleLayoutSignals(){const t=$S(this);for(const n of this.children)t.push(...n.assembleLayoutSignals());return t}assembleSelectionData(t){return this.children.reduce((n,i)=>i.assembleSelectionData(n),t)}assembleMarks(){return this.children.map(t=>{const n=t.assembleTitle(),i=t.assembleGroupStyle(),s=t.assembleGroupEncodeEntry(!1);return Object.assign(Object.assign(Object.assign(Object.assign({type:"group",name:t.getName("group")},n?{title:n}:{}),i?{style:i}:{}),s?{encode:{update:s}}:{}),t.assembleGroup())})}assembleGroupStyle(){}assembleDefaultLayout(){const t=this.layout.columns;return Object.assign(Object.assign({},t!=null?{columns:t}:{}),{bounds:"full",align:"each"})}}function wve(e){return e===!1||e===null}const Lve=Object.assign(Object.assign({disable:1,gridScale:1,scale:1},uG),{labelExpr:1,encode:1}),nY=ye(Lve);class QS extends ll{constructor(t={},n={},i=!1){super(),this.explicit=t,this.implicit=n,this.mainExtracted=i}clone(){return new QS(at(this.explicit),at(this.implicit),this.mainExtracted)}hasAxisPart(t){return t==="axis"?!0:t==="grid"||t==="title"?!!this.get(t):!wve(this.get(t))}hasOrientSignalRef(){return Ne(this.explicit.orient)}}function bve(e,t,n){var i;const{encoding:s,config:o}=e,c=(i=An(s[t]))!==null&&i!==void 0?i:An(s[oo(t)]),d=e.axis(t)||{},{format:f,formatType:u}=d;if(Jd(u))return Object.assign({text:Nr({fieldOrDatumDef:c,field:"datum.value",format:f,formatType:u,config:o})},n);if(f===void 0&&u===void 0&&o.customFormatTypes){if(fh(c)==="quantitative"){if(uh(c)&&c.stack==="normalize"&&o.normalizedNumberFormatType)return Object.assign({text:Nr({fieldOrDatumDef:c,field:"datum.value",format:o.normalizedNumberFormat,formatType:o.normalizedNumberFormatType,config:o})},n);if(o.numberFormatType)return Object.assign({text:Nr({fieldOrDatumDef:c,field:"datum.value",format:o.numberFormat,formatType:o.numberFormatType,config:o})},n)}if(fh(c)==="temporal"&&o.timeFormatType&&we(c)&&!c.timeUnit)return Object.assign({text:Nr({fieldOrDatumDef:c,field:"datum.value",format:o.timeFormat,formatType:o.timeFormatType,config:o})},n)}return n}function Tve(e){return lo.reduce((t,n)=>(e.component.scales[n]&&(t[n]=[Fve(n,e)]),t),{})}const vve={bottom:"top",top:"bottom",left:"right",right:"left"};function Eve(e){var t;const{axes:n,resolve:i}=e.component,s={top:0,bottom:0,right:0,left:0};for(const o of e.children){o.parseAxesAndHeaders();for(const c of ye(o.component.axes))i.axis[c]=qS(e.component.resolve,c),i.axis[c]==="shared"&&(n[c]=Sve(n[c],o.component.axes[c]),n[c]||(i.axis[c]="independent",delete n[c]))}for(const o of lo){for(const c of e.children)if(c.component.axes[o]){if(i.axis[o]==="independent"){n[o]=((t=n[o])!==null&&t!==void 0?t:[]).concat(c.component.axes[o]);for(const d of c.component.axes[o]){const{value:f,explicit:u}=d.getWithExplicit("orient");if(!Ne(f)){if(s[f]>0&&!u){const a=vve[f];s[f]>s[a]&&d.set("orient",a,!1)}s[f]++}}}delete c.component.axes[o]}if(i.axis[o]==="independent"&&n[o]&&n[o].length>1)for(const c of n[o])c.get("grid")&&!c.explicit.grid&&(c.implicit.grid=!1)}}function Sve(e,t){if(e){if(e.length!==t.length)return;const n=e.length;for(let i=0;in.clone());return e}function xve(e,t){for(const n of nY){const i=fc(e.getWithExplicit(n),t.getWithExplicit(n),n,"axis",(s,o)=>{switch(n){case"title":return LV(s,o);case"gridScale":return{explicit:s.explicit,value:Sn(s.value,o.value)}}return _6(s,o,n,"axis")});e.setWithExplicit(n,i)}return e}function kve(e,t,n,i,s){if(t==="disable")return n!==void 0;switch(n=n||{},t){case"titleAngle":case"labelAngle":return e===(Ne(n.labelAngle)?n.labelAngle:J2(n.labelAngle));case"values":return!!n.values;case"encode":return!!n.encoding||!!n.labelAngle;case"title":if(e===bW(i,s))return!0}return e===n[t]}const Bve=new Set(["grid","translate","format","formatType","orient","labelExpr","tickCount","position","tickMinStep"]);function Fve(e,t){var n,i,s;let o=t.axis(e);const c=new QS,d=An(t.encoding[e]),{mark:f,config:u}=t,a=(o==null?void 0:o.orient)||((n=u[e==="x"?"axisX":"axisY"])===null||n===void 0?void 0:n.orient)||((i=u.axis)===null||i===void 0?void 0:i.orient)||lbe(e),m=t.getScaleComponent(e).get("type"),y=tbe(e,m,a,t.config),p=o!==void 0?!o:Q8("disable",u.style,o==null?void 0:o.style,y).configValue;if(c.set("disable",p,o!==void 0),p)return c;o=o||{};const l=rbe(d,o,e,u.style,y),b={fieldOrDatumDef:d,axis:o,channel:e,model:t,scaleType:m,orient:a,labelAngle:l,mark:f,config:u};for(const S of nY){const x=S in UM?UM[S](b):pM(S)?o[S]:void 0,F=x!==void 0,k=kve(x,S,o,t,e);if(F&&k)c.set(S,x,k);else{const{configValue:M=void 0,configFrom:O=void 0}=pM(S)&&S!=="values"?Q8(S,u.style,o.style,y):{},C=M!==void 0;F&&!C?c.set(S,x,k):(O!=="vgAxisConfig"||Bve.has(S)&&C||d3(M)||Ne(M))&&c.set(S,M,!1)}}const L=(s=o.encoding)!==null&&s!==void 0?s:{},E=fG.reduce((S,x)=>{var F;if(!c.hasAxisPart(x))return S;const k=kW((F=L[x])!==null&&F!==void 0?F:{},t),M=x==="labels"?bve(t,e,k):k;return M!==void 0&&!Wt(M)&&(S[x]={update:M}),S},{});return Wt(E)||c.set("encode",E,!!o.encoding||o.labelAngle!==void 0),c}function Ive({encoding:e,size:t}){for(const n of lo){const i=ms(n);Ga(t[i])&&va(e[n])&&(delete t[i],me(SV(i)))}return t}function Ove(e,t,n){const i=es(e),s=qt("orient",i,n);if(i.orient=Cve(i.type,t,s),s!==void 0&&s!==i.orient&&me(U5e(i.orient,s)),i.type==="bar"&&i.orient){const d=qt("cornerRadiusEnd",i,n);if(d!==void 0){const f=i.orient==="horizontal"&&t.x2||i.orient==="vertical"&&t.y2?["cornerRadius"]:r8e[i.orient];for(const u of f)i[u]=d;i.cornerRadiusEnd!==void 0&&delete i.cornerRadiusEnd}}return qt("opacity",i,n)===void 0&&(i.opacity=Ave(i.type,t)),qt("cursor",i,n)===void 0&&(i.cursor=Mve(i,t,n)),i}function Mve(e,t,n){return t.href||e.href||qt("href",e,n)?"pointer":e.cursor}function Ave(e,t){if(vt([s6,dS,fS,uS],e)&&!TS(t))return .7}function Nve(e,t,{graticule:n}){if(n)return!1;const i=Xd("filled",e,t),s=e.type;return Sn(i,s!==s6&&s!==i6&&s!==Gy)}function Cve(e,t,n){switch(e){case s6:case fS:case uS:case $V:case XLe:case YLe:return}const{x:i,y:s,x2:o,y2:c}=t;switch(e){case n6:if(we(i)&&(ei(i.bin)||we(s)&&s.aggregate&&!i.aggregate))return"vertical";if(we(s)&&(ei(s.bin)||we(i)&&i.aggregate&&!s.aggregate))return"horizontal";if(c||o){if(n)return n;if(!o)return(we(i)&&i.type===Kd&&!nn(i.bin)||z8(i))&&we(s)&&ei(s.bin)?"horizontal":"vertical";if(!c)return(we(s)&&s.type===Kd&&!nn(s.bin)||z8(s))&&we(i)&&ei(i.bin)?"vertical":"horizontal"}case Gy:if(o&&!(we(i)&&ei(i.bin))&&c&&!(we(s)&&ei(s.bin)))return;case t6:if(c)return we(s)&&ei(s.bin)?"horizontal":"vertical";if(o)return we(i)&&ei(i.bin)?"vertical":"horizontal";if(e===Gy){if(i&&!s)return"vertical";if(s&&!i)return"horizontal"}case i6:case dS:{const d=va(i),f=va(s);if(n)return n;if(d&&!f)return e!=="tick"?"horizontal":"vertical";if(!d&&f)return e!=="tick"?"vertical":"horizontal";if(d&&f){const u=i,a=s,m=u.type===ch,y=a.type===ch;return m&&!y?e!=="tick"?"vertical":"horizontal":!m&&y?e!=="tick"?"horizontal":"vertical":!u.aggregate&&a.aggregate?e!=="tick"?"vertical":"horizontal":u.aggregate&&!a.aggregate&&e!=="tick"?"horizontal":"vertical"}else return}}return"vertical"}const Rve={vgMark:"arc",encodeEntry:e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",size:"ignore",orient:"ignore",theta:"ignore"})),pi("x",e,{defaultPos:"mid"})),pi("y",e,{defaultPos:"mid"})),hc(e,"radius")),hc(e,"theta"))},Pve={vgMark:"area",encodeEntry:e=>Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",orient:"include",size:"ignore",theta:"ignore"})),e4("x",e,{defaultPos:"zeroOrMin",defaultPos2:"zeroOrMin",range:e.markDef.orient==="horizontal"})),e4("y",e,{defaultPos:"zeroOrMin",defaultPos2:"zeroOrMin",range:e.markDef.orient==="vertical"})),jS(e))},Dve={vgMark:"rect",encodeEntry:e=>Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",orient:"ignore",size:"ignore",theta:"ignore"})),hc(e,"x")),hc(e,"y"))},jve={vgMark:"shape",encodeEntry:e=>Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",size:"ignore",orient:"ignore",theta:"ignore"})),postEncodingTransform:e=>{const{encoding:t}=e,n=t.shape;return[Object.assign({type:"geoshape",projection:e.projectionName()},n&&we(n)&&n.type===Uh?{field:ve(n,{expr:"datum"})}:{})]}},Uve={vgMark:"image",encodeEntry:e=>Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"ignore",orient:"ignore",size:"ignore",theta:"ignore"})),hc(e,"x")),hc(e,"y")),PS(e,"url"))},Hve={vgMark:"line",encodeEntry:e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",size:"ignore",orient:"ignore",theta:"ignore"})),pi("x",e,{defaultPos:"mid"})),pi("y",e,{defaultPos:"mid"})),zn("size",e,{vgChannel:"strokeWidth"})),jS(e))},zve={vgMark:"trail",encodeEntry:e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",size:"include",orient:"ignore",theta:"ignore"})),pi("x",e,{defaultPos:"mid"})),pi("y",e,{defaultPos:"mid"})),zn("size",e)),jS(e))};function ex(e,t){const{config:n}=e;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",size:"include",orient:"ignore",theta:"ignore"})),pi("x",e,{defaultPos:"mid"})),pi("y",e,{defaultPos:"mid"})),zn("size",e)),zn("angle",e)),$ve(e,n,t))}function $ve(e,t,n){return n?{shape:{value:n}}:zn("shape",e)}const qve={vgMark:"symbol",encodeEntry:e=>ex(e)},Vve={vgMark:"symbol",encodeEntry:e=>ex(e,"circle")},Gve={vgMark:"symbol",encodeEntry:e=>ex(e,"square")},Wve={vgMark:"rect",encodeEntry:e=>Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",orient:"ignore",size:"ignore",theta:"ignore"})),hc(e,"x")),hc(e,"y"))},Yve={vgMark:"rule",encodeEntry:e=>{const{markDef:t}=e,n=t.orient;return!e.encoding.x&&!e.encoding.y&&!e.encoding.latitude&&!e.encoding.longitude?{}:Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",orient:"ignore",size:"ignore",theta:"ignore"})),e4("x",e,{defaultPos:n==="horizontal"?"zeroOrMax":"mid",defaultPos2:"zeroOrMin",range:n!=="vertical"})),e4("y",e,{defaultPos:n==="vertical"?"zeroOrMax":"mid",defaultPos2:"zeroOrMin",range:n!=="horizontal"})),zn("size",e,{vgChannel:"strokeWidth"}))}},Xve={vgMark:"text",encodeEntry:e=>{const{config:t,encoding:n}=e;return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"include",baseline:"include",color:"include",size:"ignore",orient:"ignore",theta:"include"})),pi("x",e,{defaultPos:"mid"})),pi("y",e,{defaultPos:"mid"})),PS(e)),zn("size",e,{vgChannel:"fontSize"})),zn("angle",e)),RM("align",Kve(e.markDef,n,t))),RM("baseline",Zve(e.markDef,n,t))),pi("radius",e,{defaultPos:null})),pi("theta",e,{defaultPos:null}))}};function Kve(e,t,n){if(qt("align",e,n)===void 0)return"center"}function Zve(e,t,n){if(qt("baseline",e,n)===void 0)return"middle"}const Jve={vgMark:"rect",encodeEntry:e=>{const{config:t,markDef:n}=e,i=n.orient,s=i==="horizontal"?"width":"height",o=i==="horizontal"?"height":"width";return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},fr(e,{align:"ignore",baseline:"ignore",color:"include",orient:"ignore",size:"ignore",theta:"ignore"})),pi("x",e,{defaultPos:"mid",vgChannel:"xc"})),pi("y",e,{defaultPos:"mid",vgChannel:"yc"})),zn("size",e,{defaultValue:Qve(e),vgChannel:s})),{[o]:on(qt("thickness",n,t))})}};function Qve(e){var t;const{config:n,markDef:i}=e,{orient:s}=i,o=s==="horizontal"?"width":"height",c=e.getScaleComponent(s==="horizontal"?"x":"y"),d=(t=qt("size",i,n,{vgChannel:o}))!==null&&t!==void 0?t:n.tick.bandSize;if(d!==void 0)return d;{const f=c?c.get("range"):void 0;return f&&Nc(f)&&Yt(f.step)?f.step*3/4:Jy(n.view,o)*3/4}}const h_={arc:Rve,area:Pve,bar:Dve,circle:Vve,geoshape:jve,image:Uve,line:Hve,point:qve,rect:Wve,rule:Yve,square:Gve,text:Xve,tick:Jve,trail:zve};function eEe(e){if(vt([i6,t6,KLe],e.mark)){const t=pG(e.mark,e.encoding);if(t.length>0)return tEe(e,t)}else if(e.mark===n6){const t=R8.some(n=>qt(n,e.markDef,e.config));if(e.stack&&!e.fieldDef("size")&&t)return nEe(e)}return tx(e)}const nA="faceted_path_";function tEe(e,t){return[{name:e.getName("pathgroup"),type:"group",from:{facet:{name:nA+e.requestDataName(en.Main),data:e.requestDataName(en.Main),groupby:t}},encode:{update:{width:{field:{group:"width"}},height:{field:{group:"height"}}}},marks:tx(e,{fromPrefix:nA})}]}const iA="stack_group_";function nEe(e){var t;const[n]=tx(e,{fromPrefix:iA}),i=e.scaleName(e.stack.fieldChannel),s=(a={})=>e.vgField(e.stack.fieldChannel,a),o=(a,m)=>{const y=[s({prefix:"min",suffix:"start",expr:m}),s({prefix:"max",suffix:"start",expr:m}),s({prefix:"min",suffix:"end",expr:m}),s({prefix:"max",suffix:"end",expr:m})];return`${a}(${y.map(p=>`scale('${i}',${p})`).join(",")})`};let c,d;e.stack.fieldChannel==="x"?(c=Object.assign(Object.assign({},ah(n.encode.update,["y","yc","y2","height",...R8])),{x:{signal:o("min","datum")},x2:{signal:o("max","datum")},clip:{value:!0}}),d={x:{field:{group:"x"},mult:-1},height:{field:{group:"height"}}},n.encode.update=Object.assign(Object.assign({},as(n.encode.update,["y","yc","y2"])),{height:{field:{group:"height"}}})):(c=Object.assign(Object.assign({},ah(n.encode.update,["x","xc","x2","width"])),{y:{signal:o("min","datum")},y2:{signal:o("max","datum")},clip:{value:!0}}),d={y:{field:{group:"y"},mult:-1},width:{field:{group:"width"}}},n.encode.update=Object.assign(Object.assign({},as(n.encode.update,["x","xc","x2"])),{width:{field:{group:"width"}}}));for(const a of R8){const m=Xd(a,e.markDef,e.config);n.encode.update[a]?(c[a]=n.encode.update[a],delete n.encode.update[a]):m&&(c[a]=on(m)),m&&(n.encode.update[a]={value:0})}const f=[];if(((t=e.stack.groupbyChannels)===null||t===void 0?void 0:t.length)>0)for(const a of e.stack.groupbyChannels){const m=e.fieldDef(a),y=ve(m);y&&f.push(y),(m!=null&&m.bin||m!=null&&m.timeUnit)&&f.push(ve(m,{binSuffix:"end"}))}return c=["stroke","strokeWidth","strokeJoin","strokeCap","strokeDash","strokeDashOffset","strokeMiterLimit","strokeOpacity"].reduce((a,m)=>{if(n.encode.update[m])return Object.assign(Object.assign({},a),{[m]:n.encode.update[m]});{const y=Xd(m,e.markDef,e.config);return y!==void 0?Object.assign(Object.assign({},a),{[m]:on(y)}):a}},c),c.stroke&&(c.strokeForeground={value:!0},c.strokeOffset={value:0}),[{type:"group",from:{facet:{data:e.requestDataName(en.Main),name:iA+e.requestDataName(en.Main),groupby:f,aggregate:{fields:[s({suffix:"start"}),s({suffix:"start"}),s({suffix:"end"}),s({suffix:"end"})],ops:["min","max","min","max"]}}},encode:{update:c},marks:[{type:"group",encode:{update:d},marks:[n]}]}]}function iEe(e){var t;const{encoding:n,stack:i,mark:s,markDef:o,config:c}=e,d=n.order;if(!(!ue(d)&&Vr(d)&&N8(d.value)||!d&&N8(qt("order",o,c)))){if((ue(d)||we(d))&&!i)return yV(d,{expr:"datum"});if(Cc(s)){const f=o.orient==="horizontal"?"y":"x",u=n[f];if(we(u)){const a=u.sort;if(ue(a))return{field:ve(u,{prefix:f,suffix:"sort_index",expr:"datum"})};if(Ba(a))return{field:ve({aggregate:TS(e.encoding)?a.op:void 0,field:a.field},{expr:"datum"})};if(QV(a)){const m=e.fieldDef(a.encoding);return{field:ve(m,{expr:"datum"}),order:a.order}}else return a===null?void 0:{field:ve(u,{binSuffix:!((t=e.stack)===null||t===void 0)&&t.impute?"mid":void 0,expr:"datum"})}}return}}}function tx(e,t={fromPrefix:""}){const{mark:n,markDef:i,encoding:s,config:o}=e,c=Sn(i.clip,sEe(e),rEe(e)),d=_V(i),f=s.key,u=iEe(e),a=aEe(e),m=qt("aria",i,o),y=h_[n].postEncodingTransform?h_[n].postEncodingTransform(e):null;return[Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({name:e.getName("marks"),type:h_[n].vgMark},c?{clip:!0}:{}),d?{style:d}:{}),f?{key:f.field}:{}),u?{sort:u}:{}),a||{}),m===!1?{aria:m}:{}),{from:{data:t.fromPrefix+e.requestDataName(en.Main)},encode:{update:h_[n].encodeEntry(e)}}),y?{transform:y}:{})]}function sEe(e){const t=e.getScaleComponent("x"),n=e.getScaleComponent("y");return t!=null&&t.get("selectionExtent")||n!=null&&n.get("selectionExtent")?!0:void 0}function rEe(e){const t=e.component.projection;return t&&!t.isFit?!0:void 0}function aEe(e){if(!e.component.selection)return null;const t=ye(e.component.selection).length;let n=t,i=e.parent;for(;i&&n===0;)n=ye(i.component.selection).length,i=i.parent;return n?{interactive:t>0||!!e.encoding.tooltip}:null}class iY extends JW{constructor(t,n,i,s={},o){var c;super(t,"unit",n,i,o,void 0,wM(t)?t.view:void 0),this.specifiedScales={},this.specifiedAxes={},this.specifiedLegends={},this.specifiedProjection={},this.selection=[],this.children=[];const d=$a(t.mark)?Object.assign({},t.mark):{type:t.mark},f=d.type;d.filled===void 0&&(d.filled=Nve(d,o,{graticule:t.data&&CS(t.data)}));const u=this.encoding=R8e(t.encoding||{},f,d.filled,o);this.markDef=Ove(d,u,o),this.size=Ive({encoding:u,size:wM(t)?Object.assign(Object.assign(Object.assign({},s),t.width?{width:t.width}:{}),t.height?{height:t.height}:{}):s}),this.stack=PG(f,u),this.specifiedScales=this.initScales(f,u),this.specifiedAxes=this.initAxes(u),this.specifiedLegends=this.initLegends(u),this.specifiedProjection=t.projection,this.selection=((c=t.params)!==null&&c!==void 0?c:[]).filter(a=>IS(a))}get hasProjection(){const{encoding:t}=this,n=this.mark===qV,i=t&&Mwe.some(s=>Je(t[s]));return n||i}scaleDomain(t){const n=this.specifiedScales[t];return n?n.domain:void 0}axis(t){return this.specifiedAxes[t]}legend(t){return this.specifiedLegends[t]}initScales(t,n){return Jm.reduce((i,s)=>{var o;const c=An(n[s]);return c&&(i[s]=this.initScale((o=c.scale)!==null&&o!==void 0?o:{})),i},{})}initScale(t){const{domain:n,range:i}=t,s=es(t);return ue(n)&&(s.domain=n.map(Is)),ue(i)&&(s.range=i.map(Is)),s}initAxes(t){return lo.reduce((n,i)=>{const s=t[i];if(Je(s)||i===hn&&Je(t.x2)||i===Kn&&Je(t.y2)){const o=Je(s)?s.axis:void 0;n[i]=o&&this.initAxis(Object.assign({},o))}return n},{})}initAxis(t){const n=ye(t),i={};for(const s of n){const o=t[s];i[s]=d3(o)?gV(o):Is(o)}return i}initLegends(t){return zwe.reduce((n,i)=>{const s=An(t[i]);if(s&&qwe(i)){const o=s.legend;n[i]=o&&es(o)}return n},{})}parseData(){this.component.data=F6(this)}parseLayoutSize(){hve(this)}parseSelections(){this.component.selection=Z7e(this,this.selection)}parseMarkGroup(){this.component.mark=eEe(this)}parseAxesAndHeaders(){this.component.axes=Tve(this)}assembleSelectionTopLevelSignals(t){return m7e(this,t)}assembleSignals(){return[...mW(this),...p7e(this,[])]}assembleSelectionData(t){return w7e(this,t)}assembleLayout(){return null}assembleLayoutSignals(){return $S(this)}assembleMarks(){var t;let n=(t=this.component.mark)!==null&&t!==void 0?t:[];return(!this.parent||!Vh(this.parent))&&(n=ZG(this,n)),n.map(this.correctDataNames)}assembleGroupStyle(){const{style:t}=this.view||{};if(t!==void 0)return t;if(this.encoding.x||this.encoding.y)return"cell"}getMapping(){return this.encoding}get mark(){return this.markDef.type}channelHasField(t){return Bd(this.encoding,t)}fieldDef(t){const n=this.encoding[t];return qa(n)}typedFieldDef(t){const n=this.fieldDef(t);return lr(n)?n:null}}class nx extends ZS{constructor(t,n,i,s,o){super(t,"layer",n,i,o,t.resolve,t.view);const c=Object.assign(Object.assign(Object.assign({},s),t.width?{width:t.width}:{}),t.height?{height:t.height}:{});this.children=t.layer.map((d,f)=>{if(g6(d))return new nx(d,this,this.getName(`layer_${f}`),c,o);if(ol(d))return new iY(d,this,this.getName(`layer_${f}`),c,o);throw new Error(YE(d))})}parseData(){this.component.data=F6(this);for(const t of this.children)t.parseData()}parseLayoutSize(){fve(this)}parseSelections(){this.component.selection={};for(const t of this.children){t.parseSelections();for(const n of ye(t.component.selection))this.component.selection[n]=t.component.selection[n]}}parseMarkGroup(){for(const t of this.children)t.parseMarkGroup()}parseAxesAndHeaders(){Eve(this)}assembleSelectionTopLevelSignals(t){return this.children.reduce((n,i)=>i.assembleSelectionTopLevelSignals(n),t)}assembleSignals(){return this.children.reduce((t,n)=>t.concat(n.assembleSignals()),mW(this))}assembleLayoutSignals(){return this.children.reduce((t,n)=>t.concat(n.assembleLayoutSignals()),$S(this))}assembleSelectionData(t){return this.children.reduce((n,i)=>i.assembleSelectionData(n),t)}assembleGroupStyle(){const t=new Set;for(const i of this.children)for(const s of Se(i.assembleGroupStyle()))t.add(s);const n=Array.from(t);return n.length>1?n:n.length===1?n[0]:void 0}assembleTitle(){let t=super.assembleTitle();if(t)return t;for(const n of this.children)if(t=n.assembleTitle(),t)return t}assembleLayout(){return null}assembleMarks(){return L7e(this,this.children.flatMap(t=>t.assembleMarks()))}assembleLegends(){return this.children.reduce((t,n)=>t.concat(n.assembleLegends()),CW(this))}}function ix(e,t,n,i,s){if(a6(e))return new f2(e,t,n,s);if(g6(e))return new nx(e,t,n,i,s);if(ol(e))return new iY(e,t,n,i,s);if(o9e(e))return new mve(e,t,n,s);throw new Error(YE(e))}var oEe=globalThis&&globalThis.__rest||function(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);s(p.name==="width"||p.name==="height")&&p.value!==void 0?(t[p.name]=+p.value,!1):!0);const{params:m}=t,y=oEe(t,["params"]);return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({$schema:"https://vega.github.io/schema/vega/v5.json"},e.description?{description:e.description}:{}),y),d?{title:d}:{}),f?{style:f}:{}),u?{encode:{update:u}}:{}),{data:o}),c.length>0?{projections:c}:{}),e.assembleGroup([...a,...e.assembleSelectionTopLevelSignals([]),...MG(m)])),s?{config:s}:{}),i?{usermeta:i}:{})}const fEe=Twe.version,uEe=Object.freeze(Object.defineProperty({__proto__:null,accessPathDepth:oh,accessPathWithDatum:DE,compile:lEe,contains:vt,deepEqual:ba,deleteNestedProperty:$y,duplicate:at,entries:cc,every:CE,fieldIntersection:PE,flatAccessWithDatum:Xq,getFirstDefined:Sn,hasIntersection:RE,hash:Bt,internalField:Jq,isBoolean:Z2,isEmpty:Wt,isEqual:xwe,isInternalField:Qq,isNullOrFalse:N8,isNumeric:Vm,keys:ye,logicalExpr:c2,mergeDeep:Wq,never:Gq,normalize:GG,normalizeAngle:J2,omit:as,pick:ah,prefixGenerator:C8,removePathFromField:jE,replaceAll:Wd,replacePathInField:ar,resetIdCounter:Bwe,setEqual:Yq,some:Gd,stringify:tn,titleCase:Q0,unique:Ta,uniqueId:Zq,vals:Ti,varName:dn,version:fEe},Symbol.toStringTag,{value:"Module"}));function sY(e){const[t,n]=/schema\/([\w-]+)\/([\w\.\-]+)\.json$/g.exec(e).slice(1,3);return{library:t,version:n}}var hEe="vega-themes",gEe="2.10.0",_Ee="Themes for stylized Vega and Vega-Lite visualizations.",pEe=["vega","vega-lite","themes","style"],yEe="BSD-3-Clause",mEe={name:"UW Interactive Data Lab",url:"https://idl.cs.washington.edu"},wEe=[{name:"Emily Gu",url:"https://github.com/emilygu"},{name:"Arvind Satyanarayan",url:"http://arvindsatya.com"},{name:"Jeffrey Heer",url:"https://idl.cs.washington.edu"},{name:"Dominik Moritz",url:"https://www.domoritz.de"}],LEe="build/vega-themes.js",sx="build/vega-themes.module.js",bEe="build/vega-themes.min.js",TEe="build/vega-themes.min.js",vEe="build/vega-themes.module.d.ts",EEe={type:"git",url:"https://github.com/vega/vega-themes.git"},SEe=["src","build"],xEe={prebuild:"yarn clean",build:"rollup -c",clean:"rimraf build && rimraf examples/build","copy:data":"rsync -r node_modules/vega-datasets/data/* examples/data","copy:build":"rsync -r build/* examples/build","deploy:gh":"yarn build && mkdir -p examples/build && rsync -r build/* examples/build && gh-pages -d examples",preversion:"yarn lint",serve:"browser-sync start -s -f build examples --serveStatic examples",start:"yarn build && concurrently --kill-others -n Server,Rollup 'yarn serve' 'rollup -c -w'",prepare:"beemo create-config",eslintbase:"beemo eslint .",format:"yarn eslintbase --fix",lint:"yarn eslintbase",release:"auto shipit"},kEe={"@auto-it/conventional-commits":"^10.32.2","@auto-it/first-time-contributor":"^10.32.2","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^13.0.6","rollup-plugin-ts":"^1.4.7",auto:"^10.32.2","browser-sync":"^2.27.7",concurrently:"^6.4.0","gh-pages":"^3.2.3",rollup:"^2.60.0","rollup-plugin-bundle-size":"^1.0.3","rollup-plugin-terser":"^7.0.2",typescript:"^4.4.4",vega:"^5.19.1","vega-lite":"^5.0.0","vega-lite-dev-config":"^0.20.0"},BEe={vega:"*","vega-lite":"*"},FEe={name:hEe,version:gEe,description:_Ee,keywords:pEe,license:yEe,author:mEe,contributors:wEe,main:LEe,module:sx,unpkg:bEe,jsdelivr:TEe,types:vEe,repository:EEe,files:SEe,scripts:xEe,devDependencies:kEe,peerDependencies:BEe};const jf="#fff",IEe="#888",OEe={background:"#333",title:{color:jf,subtitleColor:jf},style:{"guide-label":{fill:jf},"guide-title":{fill:jf}},axis:{domainColor:jf,gridColor:IEe,tickColor:jf}},Hc="#4572a7",MEe={background:"#fff",arc:{fill:Hc},area:{fill:Hc},line:{stroke:Hc,strokeWidth:2},path:{stroke:Hc},rect:{fill:Hc},shape:{stroke:Hc},symbol:{fill:Hc,strokeWidth:1.5,size:50},axis:{bandPosition:.5,grid:!0,gridColor:"#000000",gridOpacity:1,gridWidth:.5,labelPadding:10,tickSize:5,tickWidth:.5},axisBand:{grid:!1,tickExtra:!0},legend:{labelBaseline:"middle",labelFontSize:11,symbolSize:50,symbolType:"square"},range:{category:["#4572a7","#aa4643","#8aa453","#71598e","#4598ae","#d98445","#94aace","#d09393","#b9cc98","#a99cbc"]}},zc="#30a2da",_5="#cbcbcb",AEe="#999",NEe="#333",sA="#f0f0f0",rA="#333",CEe={arc:{fill:zc},area:{fill:zc},axis:{domainColor:_5,grid:!0,gridColor:_5,gridWidth:1,labelColor:AEe,labelFontSize:10,titleColor:NEe,tickColor:_5,tickSize:10,titleFontSize:14,titlePadding:10,labelPadding:4},axisBand:{grid:!1},background:sA,group:{fill:sA},legend:{labelColor:rA,labelFontSize:11,padding:1,symbolSize:30,symbolType:"square",titleColor:rA,titleFontSize:14,titlePadding:10},line:{stroke:zc,strokeWidth:2},path:{stroke:zc,strokeWidth:.5},rect:{fill:zc},range:{category:["#30a2da","#fc4f30","#e5ae38","#6d904f","#8b8b8b","#b96db8","#ff9e27","#56cc60","#52d2ca","#52689e","#545454","#9fe4f8"],diverging:["#cc0020","#e77866","#f6e7e1","#d6e8ed","#91bfd9","#1d78b5"],heatmap:["#d6e8ed","#cee0e5","#91bfd9","#549cc6","#1d78b5"]},point:{filled:!0,shape:"circle"},shape:{stroke:zc},bar:{binSpacing:2,fill:zc,stroke:null},title:{anchor:"start",fontSize:24,fontWeight:600,offset:20}},$c="#000",REe={group:{fill:"#e5e5e5"},arc:{fill:$c},area:{fill:$c},line:{stroke:$c},path:{stroke:$c},rect:{fill:$c},shape:{stroke:$c},symbol:{fill:$c,size:40},axis:{domain:!1,grid:!0,gridColor:"#FFFFFF",gridOpacity:1,labelColor:"#7F7F7F",labelPadding:4,tickColor:"#7F7F7F",tickSize:5.67,titleFontSize:16,titleFontWeight:"normal"},legend:{labelBaseline:"middle",labelFontSize:11,symbolSize:40},range:{category:["#000000","#7F7F7F","#1A1A1A","#999999","#333333","#B0B0B0","#4D4D4D","#C9C9C9","#666666","#DCDCDC"]}},PEe=22,DEe="normal",aA="Benton Gothic, sans-serif",oA=11.5,jEe="normal",qc="#82c6df",p5="Benton Gothic Bold, sans-serif",lA="normal",cA=13,p1={"category-6":["#ec8431","#829eb1","#c89d29","#3580b1","#adc839","#ab7fb4"],"fire-7":["#fbf2c7","#f9e39c","#f8d36e","#f4bb6a","#e68a4f","#d15a40","#ab4232"],"fireandice-6":["#e68a4f","#f4bb6a","#f9e39c","#dadfe2","#a6b7c6","#849eae"],"ice-7":["#edefee","#dadfe2","#c4ccd2","#a6b7c6","#849eae","#607785","#47525d"]},UEe={background:"#ffffff",title:{anchor:"start",color:"#000000",font:p5,fontSize:PEe,fontWeight:DEe},arc:{fill:qc},area:{fill:qc},line:{stroke:qc,strokeWidth:2},path:{stroke:qc},rect:{fill:qc},shape:{stroke:qc},symbol:{fill:qc,size:30},axis:{labelFont:aA,labelFontSize:oA,labelFontWeight:jEe,titleFont:p5,titleFontSize:cA,titleFontWeight:lA},axisX:{labelAngle:0,labelPadding:4,tickSize:3},axisY:{labelBaseline:"middle",maxExtent:45,minExtent:45,tickSize:2,titleAlign:"left",titleAngle:0,titleX:-45,titleY:-11},legend:{labelFont:aA,labelFontSize:oA,symbolType:"square",titleFont:p5,titleFontSize:cA,titleFontWeight:lA},range:{category:p1["category-6"],diverging:p1["fireandice-6"],heatmap:p1["fire-7"],ordinal:p1["fire-7"],ramp:p1["fire-7"]}},Vc="#ab5787",g_="#979797",HEe={background:"#f9f9f9",arc:{fill:Vc},area:{fill:Vc},line:{stroke:Vc},path:{stroke:Vc},rect:{fill:Vc},shape:{stroke:Vc},symbol:{fill:Vc,size:30},axis:{domainColor:g_,domainWidth:.5,gridWidth:.2,labelColor:g_,tickColor:g_,tickWidth:.2,titleColor:g_},axisBand:{grid:!1},axisX:{grid:!0,tickSize:10},axisY:{domain:!1,grid:!0,tickSize:0},legend:{labelFontSize:11,padding:1,symbolSize:30,symbolType:"square"},range:{category:["#ab5787","#51b2e5","#703c5c","#168dd9","#d190b6","#00609f","#d365ba","#154866","#666666","#c4c4c4"]}},Gc="#3e5c69",zEe={background:"#fff",arc:{fill:Gc},area:{fill:Gc},line:{stroke:Gc},path:{stroke:Gc},rect:{fill:Gc},shape:{stroke:Gc},symbol:{fill:Gc},axis:{domainWidth:.5,grid:!0,labelPadding:2,tickSize:5,tickWidth:.5,titleFontWeight:"normal"},axisBand:{grid:!1},axisX:{gridWidth:.2},axisY:{gridDash:[3],gridWidth:.4},legend:{labelFontSize:11,padding:1,symbolType:"square"},range:{category:["#3e5c69","#6793a6","#182429","#0570b0","#3690c0","#74a9cf","#a6bddb","#e2ddf2"]}},zs="#1696d2",dA="#000000",$Ee="#FFFFFF",__="Lato",y5="Lato",qEe="Lato",VEe="#DEDDDD",GEe=18,y1={"main-colors":["#1696d2","#d2d2d2","#000000","#fdbf11","#ec008b","#55b748","#5c5859","#db2b27"],"shades-blue":["#CFE8F3","#A2D4EC","#73BFE2","#46ABDB","#1696D2","#12719E","#0A4C6A","#062635"],"shades-gray":["#F5F5F5","#ECECEC","#E3E3E3","#DCDBDB","#D2D2D2","#9D9D9D","#696969","#353535"],"shades-yellow":["#FFF2CF","#FCE39E","#FDD870","#FCCB41","#FDBF11","#E88E2D","#CA5800","#843215"],"shades-magenta":["#F5CBDF","#EB99C2","#E46AA7","#E54096","#EC008B","#AF1F6B","#761548","#351123"],"shades-green":["#DCEDD9","#BCDEB4","#98CF90","#78C26D","#55B748","#408941","#2C5C2D","#1A2E19"],"shades-black":["#D5D5D4","#ADABAC","#848081","#5C5859","#332D2F","#262223","#1A1717","#0E0C0D"],"shades-red":["#F8D5D4","#F1AAA9","#E9807D","#E25552","#DB2B27","#A4201D","#6E1614","#370B0A"],"one-group":["#1696d2","#000000"],"two-groups-cat-1":["#1696d2","#000000"],"two-groups-cat-2":["#1696d2","#fdbf11"],"two-groups-cat-3":["#1696d2","#db2b27"],"two-groups-seq":["#a2d4ec","#1696d2"],"three-groups-cat":["#1696d2","#fdbf11","#000000"],"three-groups-seq":["#a2d4ec","#1696d2","#0a4c6a"],"four-groups-cat-1":["#000000","#d2d2d2","#fdbf11","#1696d2"],"four-groups-cat-2":["#1696d2","#ec0008b","#fdbf11","#5c5859"],"four-groups-seq":["#cfe8f3","#73bf42","#1696d2","#0a4c6a"],"five-groups-cat-1":["#1696d2","#fdbf11","#d2d2d2","#ec008b","#000000"],"five-groups-cat-2":["#1696d2","#0a4c6a","#d2d2d2","#fdbf11","#332d2f"],"five-groups-seq":["#cfe8f3","#73bf42","#1696d2","#0a4c6a","#000000"],"six-groups-cat-1":["#1696d2","#ec008b","#fdbf11","#000000","#d2d2d2","#55b748"],"six-groups-cat-2":["#1696d2","#d2d2d2","#ec008b","#fdbf11","#332d2f","#0a4c6a"],"six-groups-seq":["#cfe8f3","#a2d4ec","#73bfe2","#46abdb","#1696d2","#12719e"],"diverging-colors":["#ca5800","#fdbf11","#fdd870","#fff2cf","#cfe8f3","#73bfe2","#1696d2","#0a4c6a"]},WEe={background:$Ee,title:{anchor:"start",fontSize:GEe,font:__},axisX:{domain:!0,domainColor:dA,domainWidth:1,grid:!1,labelFontSize:12,labelFont:y5,labelAngle:0,tickColor:dA,tickSize:5,titleFontSize:12,titlePadding:10,titleFont:__},axisY:{domain:!1,domainWidth:1,grid:!0,gridColor:VEe,gridWidth:1,labelFontSize:12,labelFont:y5,labelPadding:8,ticks:!1,titleFontSize:12,titlePadding:10,titleFont:__,titleAngle:0,titleY:-10,titleX:18},legend:{labelFontSize:12,labelFont:y5,symbolSize:100,titleFontSize:12,titlePadding:10,titleFont:__,orient:"right",offset:10},view:{stroke:"transparent"},range:{category:y1["six-groups-cat-1"],diverging:y1["diverging-colors"],heatmap:y1["diverging-colors"],ordinal:y1["six-groups-seq"],ramp:y1["shades-blue"]},area:{fill:zs},rect:{fill:zs},line:{color:zs,stroke:zs,strokeWidth:5},trail:{color:zs,stroke:zs,strokeWidth:0,size:1},path:{stroke:zs,strokeWidth:.5},point:{filled:!0},text:{font:qEe,color:zs,fontSize:11,align:"center",fontWeight:400,size:11},style:{bar:{fill:zs,stroke:null}},arc:{fill:zs},shape:{stroke:zs},symbol:{fill:zs,size:30}},Wc="#3366CC",fA="#ccc",p_="Arial, sans-serif",YEe={arc:{fill:Wc},area:{fill:Wc},path:{stroke:Wc},rect:{fill:Wc},shape:{stroke:Wc},symbol:{stroke:Wc},circle:{fill:Wc},background:"#fff",padding:{top:10,right:10,bottom:10,left:10},style:{"guide-label":{font:p_,fontSize:12},"guide-title":{font:p_,fontSize:12},"group-title":{font:p_,fontSize:12}},title:{font:p_,fontSize:14,fontWeight:"bold",dy:-3,anchor:"start"},axis:{gridColor:fA,tickColor:fA,domain:!1,grid:!0},range:{category:["#4285F4","#DB4437","#F4B400","#0F9D58","#AB47BC","#00ACC1","#FF7043","#9E9D24","#5C6BC0","#F06292","#00796B","#C2185B"],heatmap:["#c6dafc","#5e97f6","#2a56c6"]}},rx=e=>e*(1/3+1),uA=rx(9),hA=rx(10),gA=rx(12),m1="Segoe UI",_A="wf_standard-font, helvetica, arial, sans-serif",pA="#252423",w1="#605E5C",yA="transparent",XEe="#C8C6C4",_r="#118DFF",KEe="#12239E",ZEe="#E66C37",JEe="#6B007B",QEe="#E044A7",eSe="#744EC2",tSe="#D9B300",nSe="#D64550",rY=_r,aY="#DEEFFF",mA=[aY,rY],iSe=[aY,"#c7e4ff","#b0d9ff","#9aceff","#83c3ff","#6cb9ff","#55aeff","#3fa3ff","#2898ff",rY],sSe={view:{stroke:yA},background:yA,font:m1,header:{titleFont:_A,titleFontSize:gA,titleColor:pA,labelFont:m1,labelFontSize:hA,labelColor:w1},axis:{ticks:!1,grid:!1,domain:!1,labelColor:w1,labelFontSize:uA,titleFont:_A,titleColor:pA,titleFontSize:gA,titleFontWeight:"normal"},axisQuantitative:{tickCount:3,grid:!0,gridColor:XEe,gridDash:[1,5],labelFlush:!1},axisBand:{tickExtra:!0},axisX:{labelPadding:5},axisY:{labelPadding:10},bar:{fill:_r},line:{stroke:_r,strokeWidth:3,strokeCap:"round",strokeJoin:"round"},text:{font:m1,fontSize:uA,fill:w1},arc:{fill:_r},area:{fill:_r,line:!0,opacity:.6},path:{stroke:_r},rect:{fill:_r},point:{fill:_r,filled:!0,size:75},shape:{stroke:_r},symbol:{fill:_r,strokeWidth:1.5,size:50},legend:{titleFont:m1,titleFontWeight:"bold",titleColor:w1,labelFont:m1,labelFontSize:hA,labelColor:w1,symbolType:"circle",symbolSize:75},range:{category:[_r,KEe,ZEe,JEe,QEe,eSe,tSe,nSe],diverging:mA,heatmap:mA,ordinal:iSe}},rSe=FEe.version,aSe=Object.freeze(Object.defineProperty({__proto__:null,dark:OEe,excel:MEe,fivethirtyeight:CEe,ggplot2:REe,googlecharts:YEe,latimes:UEe,powerbi:sSe,quartz:HEe,urbaninstitute:WEe,version:rSe,vox:zEe},Symbol.toStringTag,{value:"Module"}));/*! ***************************************************************************** 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 oSe(e,t){var n={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&t.indexOf(i)<0&&(n[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,i=Object.getOwnPropertySymbols(e);st(xe(i)?i:wA(i,n))).join(", ")}]`;if(ke(e)){let i="";const s=e,{title:o,image:c}=s,d=oSe(s,["title","image"]);o&&(i+=`

${t(o)}

`),c&&(i+=``);const f=Object.keys(d);if(f.length>0){i+="";for(const u of f){let a=d[u];a!==void 0&&(ke(a)&&(a=wA(a,n)),i+=``)}i+="
${t(u)}:${t(a)}
"}return i||"{}"}return t(e)}function cSe(e){const t=[];return function(n,i){if(typeof i!="object"||i===null)return i;const s=t.indexOf(this)+1;return t.length=s,t.length>e?"[Object]":t.indexOf(i)>=0?"[Circular]":(t.push(i),i)}}function wA(e,t){return JSON.stringify(e,cSe(t))}var dSe=`#vg-tooltip-element { visibility: hidden; padding: 8px; position: fixed; z-index: 1000; font-family: sans-serif; font-size: 11px; border-radius: 3px; box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1); /* The default theme is the light theme. */ background-color: rgba(255, 255, 255, 0.95); border: 1px solid #d9d9d9; color: black; } #vg-tooltip-element.visible { visibility: visible; } #vg-tooltip-element h2 { margin-top: 0; margin-bottom: 10px; font-size: 13px; } #vg-tooltip-element img { max-width: 200px; max-height: 200px; } #vg-tooltip-element table { border-spacing: 0; } #vg-tooltip-element table tr { border: none; } #vg-tooltip-element table tr td { overflow: hidden; text-overflow: ellipsis; padding-top: 2px; padding-bottom: 2px; } #vg-tooltip-element table tr td.key { color: #808080; max-width: 150px; text-align: right; padding-right: 4px; } #vg-tooltip-element table tr td.value { display: block; max-width: 300px; max-height: 7em; text-align: left; } #vg-tooltip-element.dark-theme { background-color: rgba(32, 32, 32, 0.9); border: 1px solid #f5f5f5; color: white; } #vg-tooltip-element.dark-theme td.key { color: #bfbfbf; } `;const oY="vg-tooltip-element",fSe={offsetX:10,offsetY:10,id:oY,styleId:"vega-tooltip-style",theme:"light",disableDefaultStyle:!1,sanitize:uSe,maxDepth:2,formatTooltip:lSe};function uSe(e){return String(e).replace(/&/g,"&").replace(/window.innerWidth&&(s=+e.clientX-n-t.width);let o=e.clientY+i;return o+t.height>window.innerHeight&&(o=+e.clientY-i-t.height),{x:s,y:o}}class _Se{constructor(t){this.options=Object.assign(Object.assign({},fSe),t);const n=this.options.id;if(this.el=null,this.call=this.tooltipHandler.bind(this),!this.options.disableDefaultStyle&&!document.getElementById(this.options.styleId)){const i=document.createElement("style");i.setAttribute("id",this.options.styleId),i.innerHTML=hSe(n);const s=document.head;s.childNodes.length>0?s.insertBefore(i,s.childNodes[0]):s.appendChild(i)}}tooltipHandler(t,n,i,s){var o;if(this.el=document.getElementById(this.options.id),this.el||(this.el=document.createElement("div"),this.el.setAttribute("id",this.options.id),this.el.classList.add("vg-tooltip"),((o=document.fullscreenElement)!==null&&o!==void 0?o:document.body).appendChild(this.el)),s==null||s===""){this.el.classList.remove("visible",`${this.options.theme}-theme`);return}this.el.innerHTML=this.options.formatTooltip(s,this.options.sanitize,this.options.maxDepth),this.el.classList.add("visible",`${this.options.theme}-theme`);const{x:c,y:d}=gSe(n,this.el.getBoundingClientRect(),this.options.offsetX,this.options.offsetY);this.el.setAttribute("style",`top: ${d}px; left: ${c}px`)}}function pSe(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function LA(e,t,n,i,s,o,c){try{var d=e[o](c),f=d.value}catch(u){n(u);return}d.done?t(f):Promise.resolve(f).then(i,s)}function s4(e){return function(){var t=this,n=arguments;return new Promise(function(i,s){var o=e.apply(t,n);function c(f){LA(o,i,s,c,d,"next",f)}function d(f){LA(o,i,s,c,d,"throw",f)}c(void 0)})}}var lY=Object.prototype,wd=lY.hasOwnProperty,wa,ax=typeof Symbol=="function"?Symbol:{},I6=ax.iterator||"@@iterator",ySe=ax.asyncIterator||"@@asyncIterator",r4=ax.toStringTag||"@@toStringTag";function cY(e,t,n,i){var s=t&&t.prototype instanceof l9?t:l9,o=Object.create(s.prototype),c=new c9(i||[]);return o._invoke=TSe(e,n,c),o}function ox(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(i){return{type:"throw",arg:i}}}var bA="suspendedStart",mSe="suspendedYield",TA="executing",y_="completed",Br={};function l9(){}function O6(){}function wh(){}var lx={};lx[I6]=function(){return this};var m5=Object.getPrototypeOf,m_=m5&&m5(m5(cx([])));m_&&m_!==lY&&wd.call(m_,I6)&&(lx=m_);var Gh=wh.prototype=l9.prototype=Object.create(lx);O6.prototype=Gh.constructor=wh;wh.constructor=O6;wh[r4]=O6.displayName="GeneratorFunction";function dY(e){["next","throw","return"].forEach(function(t){e[t]=function(n){return this._invoke(t,n)}})}function fY(e){var t=typeof e=="function"&&e.constructor;return t?t===O6||(t.displayName||t.name)==="GeneratorFunction":!1}function wSe(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,wh):(e.__proto__=wh,r4 in e||(e[r4]="GeneratorFunction")),e.prototype=Object.create(Gh),e}function LSe(e){return{__await:e}}function M6(e,t){function n(o,c,d,f){var u=ox(e[o],e,c);if(u.type==="throw")f(u.arg);else{var a=u.arg,m=a.value;return m&&typeof m=="object"&&wd.call(m,"__await")?t.resolve(m.__await).then(function(y){n("next",y,d,f)},function(y){n("throw",y,d,f)}):t.resolve(m).then(function(y){a.value=y,d(a)},function(y){return n("throw",y,d,f)})}}var i;function s(o,c){function d(){return new t(function(f,u){n(o,c,f,u)})}return i=i?i.then(d,d):d()}this._invoke=s}dY(M6.prototype);M6.prototype[ySe]=function(){return this};function bSe(e,t,n,i,s){s===void 0&&(s=Promise);var o=new M6(cY(e,t,n,i),s);return fY(t)?o:o.next().then(function(c){return c.done?c.value:o.next()})}function TSe(e,t,n){var i=bA;return function(o,c){if(i===TA)throw new Error("Generator is already running");if(i===y_){if(o==="throw")throw c;return hY()}for(n.method=o,n.arg=c;;){var d=n.delegate;if(d){var f=uY(d,n);if(f){if(f===Br)continue;return f}}if(n.method==="next")n.sent=n._sent=n.arg;else if(n.method==="throw"){if(i===bA)throw i=y_,n.arg;n.dispatchException(n.arg)}else n.method==="return"&&n.abrupt("return",n.arg);i=TA;var u=ox(e,t,n);if(u.type==="normal"){if(i=n.done?y_:mSe,u.arg===Br)continue;return{value:u.arg,done:n.done}}else u.type==="throw"&&(i=y_,n.method="throw",n.arg=u.arg)}}}function uY(e,t){var n=e.iterator[t.method];if(n===wa){if(t.delegate=null,t.method==="throw"){if(e.iterator.return&&(t.method="return",t.arg=wa,uY(e,t),t.method==="throw"))return Br;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return Br}var i=ox(n,e.iterator,t.arg);if(i.type==="throw")return t.method="throw",t.arg=i.arg,t.delegate=null,Br;var s=i.arg;if(!s)return t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,Br;if(s.done)t[e.resultName]=s.value,t.next=e.nextLoc,t.method!=="return"&&(t.method="next",t.arg=wa);else return s;return t.delegate=null,Br}dY(Gh);Gh[r4]="Generator";Gh[I6]=function(){return this};Gh.toString=function(){return"[object Generator]"};function vSe(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function w5(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function c9(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(vSe,this),this.reset(!0)}function ESe(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function i(){for(;t.length;){var s=t.pop();if(s in e)return i.value=s,i.done=!1,i}return i.done=!0,i}}function cx(e){if(e){var t=e[I6];if(t)return t.call(e);if(typeof e.next=="function")return e;if(!isNaN(e.length)){var n=-1,i=function s(){for(;++n=0;--s){var o=this.tryEntries[s],c=o.completion;if(o.tryLoc==="root")return i("end");if(o.tryLoc<=this.prev){var d=wd.call(o,"catchLoc"),f=wd.call(o,"finallyLoc");if(d&&f){if(this.prev=0;--i){var s=this.tryEntries[i];if(s.tryLoc<=this.prev&&wd.call(s,"finallyLoc")&&this.prev=0;--n){var i=this.tryEntries[n];if(i.finallyLoc===t)return this.complete(i.completion,i.afterLoc),w5(i),Br}},catch:function(t){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc===t){var s=i.completion;if(s.type==="throw"){var o=s.arg;w5(i)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,i){return this.delegate={iterator:cx(t),resultName:n,nextLoc:i},this.method==="next"&&(this.arg=wa),Br}};var Ea={wrap:cY,isGeneratorFunction:fY,AsyncIterator:M6,mark:wSe,awrap:LSe,async:bSe,keys:ESe,values:cx},SSe=Ct;Ct.Node=nf;Ct.create=Ct;function Ct(e){var t=this;if(t instanceof Ct||(t=new Ct),t.tail=null,t.head=null,t.length=0,e&&typeof e.forEach=="function")e.forEach(function(s){t.push(s)});else if(arguments.length>0)for(var n=0,i=arguments.length;n1)n=t;else if(this.head)i=this.head.next,n=this.head.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=0;i!==null;s++)n=e(n,i.value,s),i=i.next;return n};Ct.prototype.reduceReverse=function(e,t){var n,i=this.tail;if(arguments.length>1)n=t;else if(this.tail)i=this.tail.prev,n=this.tail.value;else throw new TypeError("Reduce of empty list with no initial value");for(var s=this.length-1;i!==null;s--)n=e(n,i.value,s),i=i.prev;return n};Ct.prototype.toArray=function(){for(var e=new Array(this.length),t=0,n=this.head;n!==null;t++)e[t]=n.value,n=n.next;return e};Ct.prototype.toArrayReverse=function(){for(var e=new Array(this.length),t=0,n=this.tail;n!==null;t++)e[t]=n.value,n=n.prev;return e};Ct.prototype.slice=function(e,t){t=t||this.length,t<0&&(t+=this.length),e=e||0,e<0&&(e+=this.length);var n=new Ct;if(tthis.length&&(t=this.length);for(var i=0,s=this.head;s!==null&&ithis.length&&(t=this.length);for(var i=this.length,s=this.tail;s!==null&&i>t;i--)s=s.prev;for(;s!==null&&i>e;i--,s=s.prev)n.push(s.value);return n};Ct.prototype.splice=function(e,t){e>this.length&&(e=this.length-1),e<0&&(e=this.length+e);for(var n=0,i=this.head;i!==null&&n1;class ISe{constructor(t){if(typeof t=="number"&&(t={max:t}),t||(t={}),t.max&&(typeof t.max!="number"||t.max<0))throw new TypeError("max must be a non-negative number");this[od]=t.max||1/0;var n=t.length||L5;if(this[Uf]=typeof n!="function"?L5:n,this[u2]=t.stale||!1,t.maxAge&&typeof t.maxAge!="number")throw new TypeError("maxAge must be a number");this[Ld]=t.maxAge||0,this[Lo]=t.dispose,this[vA]=t.noDisposeOnSet||!1,this[gY]=t.updateAgeOnGet||!1,this.reset()}set max(t){if(typeof t!="number"||t<0)throw new TypeError("max must be a non-negative number");this[od]=t||1/0,L1(this)}get max(){return this[od]}set allowStale(t){this[u2]=!!t}get allowStale(){return this[u2]}set maxAge(t){if(typeof t!="number")throw new TypeError("maxAge must be a non-negative number");this[Ld]=t,L1(this)}get maxAge(){return this[Ld]}set lengthCalculator(t){typeof t!="function"&&(t=L5),t!==this[Uf]&&(this[Uf]=t,this[vo]=0,this[Un].forEach(n=>{n.length=this[Uf](n.value,n.key),this[vo]+=n.length})),L1(this)}get lengthCalculator(){return this[Uf]}get length(){return this[vo]}get itemCount(){return this[Un].length}rforEach(t,n){n=n||this;for(var i=this[Un].tail;i!==null;){var s=i.prev;EA(this,t,i,n),i=s}}forEach(t,n){n=n||this;for(var i=this[Un].head;i!==null;){var s=i.next;EA(this,t,i,n),i=s}}keys(){return this[Un].toArray().map(t=>t.key)}values(){return this[Un].toArray().map(t=>t.value)}reset(){this[Lo]&&this[Un]&&this[Un].length&&this[Un].forEach(t=>this[Lo](t.key,t.value)),this[pr]=new Map,this[Un]=new FSe,this[vo]=0}dump(){return this[Un].map(t=>a4(this,t)?!1:{k:t.key,v:t.value,e:t.now+(t.maxAge||0)}).toArray().filter(t=>t)}dumpLru(){return this[Un]}set(t,n,i){if(i=i||this[Ld],i&&typeof i!="number")throw new TypeError("maxAge must be a number");var s=i?Date.now():0,o=this[Uf](n,t);if(this[pr].has(t)){if(o>this[od])return xu(this,this[pr].get(t)),!1;var c=this[pr].get(t),d=c.value;return this[Lo]&&(this[vA]||this[Lo](t,d.value)),d.now=s,d.maxAge=i,d.value=n,this[vo]+=o-d.length,d.length=o,this.get(t),L1(this),!0}var f=new OSe(t,n,o,s,i);return f.length>this[od]?(this[Lo]&&this[Lo](t,n),!1):(this[vo]+=f.length,this[Un].unshift(f),this[pr].set(t,this[Un].head),L1(this),!0)}has(t){if(!this[pr].has(t))return!1;var n=this[pr].get(t).value;return!a4(this,n)}get(t){return b5(this,t,!0)}peek(t){return b5(this,t,!1)}pop(){var t=this[Un].tail;return t?(xu(this,t),t.value):null}del(t){xu(this,this[pr].get(t))}load(t){this.reset();for(var n=Date.now(),i=t.length-1;i>=0;i--){var s=t[i],o=s.e||0;if(o===0)this.set(s.k,s.v);else{var c=o-n;c>0&&this.set(s.k,s.v,c)}}}prune(){this[pr].forEach((t,n)=>b5(this,n,!1))}}var b5=(e,t,n)=>{var i=e[pr].get(t);if(i){var s=i.value;if(a4(e,s)){if(xu(e,i),!e[u2])return}else n&&(e[gY]&&(i.value.now=Date.now()),e[Un].unshiftNode(i));return s.value}},a4=(e,t)=>{if(!t||!t.maxAge&&!e[Ld])return!1;var n=Date.now()-t.now;return t.maxAge?n>t.maxAge:e[Ld]&&n>e[Ld]},L1=e=>{if(e[vo]>e[od])for(var t=e[Un].tail;e[vo]>e[od]&&t!==null;){var n=t.prev;xu(e,t),t=n}},xu=(e,t)=>{if(t){var n=t.value;e[Lo]&&e[Lo](n.key,n.value),e[vo]-=n.length,e[pr].delete(n.key),e[Un].removeNode(t)}};class OSe{constructor(t,n,i,s,o){this.key=t,this.value=n,this.length=i,this.now=s,this.maxAge=o||0}}var EA=(e,t,n,i)=>{var s=n.value;a4(e,s)&&(xu(e,n),e[u2]||(s=void 0)),s&&t.call(i,s.value,s.key,e)},MSe=ISe,ASe=["includePrerelease","loose","rtl"],NSe=e=>e?typeof e!="object"?{loose:!0}:ASe.filter(t=>e[t]).reduce((t,n)=>(t[n]=!0,t),{}):{},dx=NSe,Fr={exports:{}},CSe="2.0.0",RSe=256,PSe=Number.MAX_SAFE_INTEGER||9007199254740991,DSe=16,fx={SEMVER_SPEC_VERSION:CSe,MAX_LENGTH:RSe,MAX_SAFE_INTEGER:PSe,MAX_SAFE_COMPONENT_LENGTH:DSe},jSe=typeof process=="object"&&process.env&&{}.NODE_DEBUG&&/\bsemver\b/i.test({}.NODE_DEBUG)?function(){for(var e=arguments.length,t=new Array(e),n=0;n{},A6=jSe;(function(e,t){var n=fx.MAX_SAFE_COMPONENT_LENGTH,i=A6;t=e.exports={};var s=t.re=[],o=t.src=[],c=t.t={},d=0,f=(u,a,m)=>{var y=d++;i(u,y,a),c[u]=y,o[y]=a,s[y]=new RegExp(a,m?"g":void 0)};f("NUMERICIDENTIFIER","0|[1-9]\\d*"),f("NUMERICIDENTIFIERLOOSE","[0-9]+"),f("NONNUMERICIDENTIFIER","\\d*[a-zA-Z-][a-zA-Z0-9-]*"),f("MAINVERSION","(".concat(o[c.NUMERICIDENTIFIER],")\\.")+"(".concat(o[c.NUMERICIDENTIFIER],")\\.")+"(".concat(o[c.NUMERICIDENTIFIER],")")),f("MAINVERSIONLOOSE","(".concat(o[c.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(o[c.NUMERICIDENTIFIERLOOSE],")\\.")+"(".concat(o[c.NUMERICIDENTIFIERLOOSE],")")),f("PRERELEASEIDENTIFIER","(?:".concat(o[c.NUMERICIDENTIFIER],"|").concat(o[c.NONNUMERICIDENTIFIER],")")),f("PRERELEASEIDENTIFIERLOOSE","(?:".concat(o[c.NUMERICIDENTIFIERLOOSE],"|").concat(o[c.NONNUMERICIDENTIFIER],")")),f("PRERELEASE","(?:-(".concat(o[c.PRERELEASEIDENTIFIER],"(?:\\.").concat(o[c.PRERELEASEIDENTIFIER],")*))")),f("PRERELEASELOOSE","(?:-?(".concat(o[c.PRERELEASEIDENTIFIERLOOSE],"(?:\\.").concat(o[c.PRERELEASEIDENTIFIERLOOSE],")*))")),f("BUILDIDENTIFIER","[0-9A-Za-z-]+"),f("BUILD","(?:\\+(".concat(o[c.BUILDIDENTIFIER],"(?:\\.").concat(o[c.BUILDIDENTIFIER],")*))")),f("FULLPLAIN","v?".concat(o[c.MAINVERSION]).concat(o[c.PRERELEASE],"?").concat(o[c.BUILD],"?")),f("FULL","^".concat(o[c.FULLPLAIN],"$")),f("LOOSEPLAIN","[v=\\s]*".concat(o[c.MAINVERSIONLOOSE]).concat(o[c.PRERELEASELOOSE],"?").concat(o[c.BUILD],"?")),f("LOOSE","^".concat(o[c.LOOSEPLAIN],"$")),f("GTLT","((?:<|>)?=?)"),f("XRANGEIDENTIFIERLOOSE","".concat(o[c.NUMERICIDENTIFIERLOOSE],"|x|X|\\*")),f("XRANGEIDENTIFIER","".concat(o[c.NUMERICIDENTIFIER],"|x|X|\\*")),f("XRANGEPLAIN","[v=\\s]*(".concat(o[c.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(o[c.XRANGEIDENTIFIER],")")+"(?:\\.(".concat(o[c.XRANGEIDENTIFIER],")")+"(?:".concat(o[c.PRERELEASE],")?").concat(o[c.BUILD],"?")+")?)?"),f("XRANGEPLAINLOOSE","[v=\\s]*(".concat(o[c.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(o[c.XRANGEIDENTIFIERLOOSE],")")+"(?:\\.(".concat(o[c.XRANGEIDENTIFIERLOOSE],")")+"(?:".concat(o[c.PRERELEASELOOSE],")?").concat(o[c.BUILD],"?")+")?)?"),f("XRANGE","^".concat(o[c.GTLT],"\\s*").concat(o[c.XRANGEPLAIN],"$")),f("XRANGELOOSE","^".concat(o[c.GTLT],"\\s*").concat(o[c.XRANGEPLAINLOOSE],"$")),f("COERCE","".concat("(^|[^\\d])(\\d{1,").concat(n,"})")+"(?:\\.(\\d{1,".concat(n,"}))?")+"(?:\\.(\\d{1,".concat(n,"}))?")+"(?:$|[^\\d])"),f("COERCERTL",o[c.COERCE],!0),f("LONETILDE","(?:~>?)"),f("TILDETRIM","(\\s*)".concat(o[c.LONETILDE],"\\s+"),!0),t.tildeTrimReplace="$1~",f("TILDE","^".concat(o[c.LONETILDE]).concat(o[c.XRANGEPLAIN],"$")),f("TILDELOOSE","^".concat(o[c.LONETILDE]).concat(o[c.XRANGEPLAINLOOSE],"$")),f("LONECARET","(?:\\^)"),f("CARETTRIM","(\\s*)".concat(o[c.LONECARET],"\\s+"),!0),t.caretTrimReplace="$1^",f("CARET","^".concat(o[c.LONECARET]).concat(o[c.XRANGEPLAIN],"$")),f("CARETLOOSE","^".concat(o[c.LONECARET]).concat(o[c.XRANGEPLAINLOOSE],"$")),f("COMPARATORLOOSE","^".concat(o[c.GTLT],"\\s*(").concat(o[c.LOOSEPLAIN],")$|^$")),f("COMPARATOR","^".concat(o[c.GTLT],"\\s*(").concat(o[c.FULLPLAIN],")$|^$")),f("COMPARATORTRIM","(\\s*)".concat(o[c.GTLT],"\\s*(").concat(o[c.LOOSEPLAIN],"|").concat(o[c.XRANGEPLAIN],")"),!0),t.comparatorTrimReplace="$1$2$3",f("HYPHENRANGE","^\\s*(".concat(o[c.XRANGEPLAIN],")")+"\\s+-\\s+"+"(".concat(o[c.XRANGEPLAIN],")")+"\\s*$"),f("HYPHENRANGELOOSE","^\\s*(".concat(o[c.XRANGEPLAINLOOSE],")")+"\\s+-\\s+"+"(".concat(o[c.XRANGEPLAINLOOSE],")")+"\\s*$"),f("STAR","(<|>)?=?\\s*\\*"),f("GTE0","^\\s*>=\\s*0\\.0\\.0\\s*$"),f("GTE0PRE","^\\s*>=\\s*0\\.0\\.0-0\\s*$")})(Fr,Fr.exports);var SA=/^[0-9]+$/,_Y=(e,t)=>{var n=SA.test(e),i=SA.test(t);return n&&i&&(e=+e,t=+t),e===t?0:n&&!i?-1:i&&!n?1:e_Y(t,e),HSe={compareIdentifiers:_Y,rcompareIdentifiers:USe},w_=A6,xA=fx.MAX_LENGTH,L_=fx.MAX_SAFE_INTEGER,kA=Fr.exports.re,BA=Fr.exports.t,zSe=dx,Hf=HSe.compareIdentifiers;class yr{constructor(t,n){if(n=zSe(n),t instanceof yr){if(t.loose===!!n.loose&&t.includePrerelease===!!n.includePrerelease)return t;t=t.version}else if(typeof t!="string")throw new TypeError("Invalid Version: ".concat(t));if(t.length>xA)throw new TypeError("version is longer than ".concat(xA," characters"));w_("SemVer",t,n),this.options=n,this.loose=!!n.loose,this.includePrerelease=!!n.includePrerelease;var i=t.trim().match(n.loose?kA[BA.LOOSE]:kA[BA.FULL]);if(!i)throw new TypeError("Invalid Version: ".concat(t));if(this.raw=t,this.major=+i[1],this.minor=+i[2],this.patch=+i[3],this.major>L_||this.major<0)throw new TypeError("Invalid major version");if(this.minor>L_||this.minor<0)throw new TypeError("Invalid minor version");if(this.patch>L_||this.patch<0)throw new TypeError("Invalid patch version");i[4]?this.prerelease=i[4].split(".").map(s=>{if(/^[0-9]+$/.test(s)){var o=+s;if(o>=0&&o=0;)typeof this.prerelease[i]=="number"&&(this.prerelease[i]++,i=-2);i===-1&&this.prerelease.push(0)}n&&(Hf(this.prerelease[0],n)===0?isNaN(this.prerelease[1])&&(this.prerelease=[n,0]):this.prerelease=[n,0]);break;default:throw new Error("invalid increment argument: ".concat(t))}return this.format(),this.raw=this.version,this}}var ux=yr,FA=ux,$Se=(e,t,n)=>new FA(e,n).compare(new FA(t,n)),Wh=$Se,qSe=Wh,VSe=(e,t,n)=>qSe(e,t,n)===0,GSe=VSe,WSe=Wh,YSe=(e,t,n)=>WSe(e,t,n)!==0,XSe=YSe,KSe=Wh,ZSe=(e,t,n)=>KSe(e,t,n)>0,JSe=ZSe,QSe=Wh,exe=(e,t,n)=>QSe(e,t,n)>=0,txe=exe,nxe=Wh,ixe=(e,t,n)=>nxe(e,t,n)<0,sxe=ixe,rxe=Wh,axe=(e,t,n)=>rxe(e,t,n)<=0,oxe=axe,lxe=GSe,cxe=XSe,dxe=JSe,fxe=txe,uxe=sxe,hxe=oxe,gxe=(e,t,n,i)=>{switch(t){case"===":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e===n;case"!==":return typeof e=="object"&&(e=e.version),typeof n=="object"&&(n=n.version),e!==n;case"":case"=":case"==":return lxe(e,n,i);case"!=":return cxe(e,n,i);case">":return dxe(e,n,i);case">=":return fxe(e,n,i);case"<":return uxe(e,n,i);case"<=":return hxe(e,n,i);default:throw new TypeError("Invalid operator: ".concat(t))}},_xe=gxe,T5,IA;function pxe(){if(IA)return T5;IA=1;var e=Symbol("SemVer ANY");class t{static get ANY(){return e}constructor(a,m){if(m=n(m),a instanceof t){if(a.loose===!!m.loose)return a;a=a.value}c("comparator",a,m),this.options=m,this.loose=!!m.loose,this.parse(a),this.semver===e?this.value="":this.value=this.operator+this.semver.version,c("comp",this)}parse(a){var m=this.options.loose?i[s.COMPARATORLOOSE]:i[s.COMPARATOR],y=a.match(m);if(!y)throw new TypeError("Invalid comparator: ".concat(a));this.operator=y[1]!==void 0?y[1]:"",this.operator==="="&&(this.operator=""),y[2]?this.semver=new d(y[2],this.options.loose):this.semver=e}toString(){return this.value}test(a){if(c("Comparator.test",a,this.options.loose),this.semver===e||a===e)return!0;if(typeof a=="string")try{a=new d(a,this.options)}catch{return!1}return o(a,this.operator,this.semver,this.options)}intersects(a,m){if(!(a instanceof t))throw new TypeError("a Comparator is required");if((!m||typeof m!="object")&&(m={loose:!!m,includePrerelease:!1}),this.operator==="")return this.value===""?!0:new f(a.value,m).test(this.value);if(a.operator==="")return a.value===""?!0:new f(this.value,m).test(a.semver);var y=(this.operator===">="||this.operator===">")&&(a.operator===">="||a.operator===">"),p=(this.operator==="<="||this.operator==="<")&&(a.operator==="<="||a.operator==="<"),l=this.semver.version===a.semver.version,b=(this.operator===">="||this.operator==="<=")&&(a.operator===">="||a.operator==="<="),L=o(this.semver,"<",a.semver,m)&&(this.operator===">="||this.operator===">")&&(a.operator==="<="||a.operator==="<"),E=o(this.semver,">",a.semver,m)&&(this.operator==="<="||this.operator==="<")&&(a.operator===">="||a.operator===">");return y||p||l&&b||L||E}}T5=t;var n=dx,i=Fr.exports.re,s=Fr.exports.t,o=_xe,c=A6,d=ux,f=pY();return T5}function OA(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=yxe(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var i=0,s=function(){};return{s,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(u){throw u},f:s}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o=!0,c=!1,d;return{s:function(){n=n.call(e)},n:function(){var u=n.next();return o=u.done,u},e:function(u){c=!0,d=u},f:function(){try{!o&&n.return!=null&&n.return()}finally{if(c)throw d}}}}function yxe(e,t){if(e){if(typeof e=="string")return MA(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return MA(e,t)}}function MA(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);nthis.parseRange(G.trim())).filter(G=>G.length),!this.set.length)throw new TypeError("Invalid SemVer Range: ".concat(H));if(this.set.length>1){var Y=this.set[0];if(this.set=this.set.filter(G=>!y(G[0])),this.set.length===0)this.set=[Y];else if(this.set.length>1){var $=OA(this.set),W;try{for($.s();!(W=$.n()).done;){var X=W.value;if(X.length===1&&p(X[0])){this.set=[X];break}}}catch(G){$.e(G)}finally{$.f()}}}this.format()}format(){return this.range=this.set.map(H=>H.join(" ").trim()).join("||").trim(),this.range}toString(){return this.range}parseRange(H){H=H.trim();var z=Object.keys(this.options).join(","),Y="parseRange:".concat(z,":").concat(H),$=n.get(Y);if($)return $;var W=this.options.loose,X=W?d[f.HYPHENRANGELOOSE]:d[f.HYPHENRANGE];H=H.replace(X,P(this.options.includePrerelease)),o("hyphen replace",H),H=H.replace(d[f.COMPARATORTRIM],u),o("comparator trim",H),H=H.replace(d[f.TILDETRIM],a),H=H.replace(d[f.CARETTRIM],m),H=H.split(/\s+/).join(" ");var G=H.split(" ").map(Fe=>b(Fe,this.options)).join(" ").split(/\s+/).map(Fe=>C(Fe,this.options));W&&(G=G.filter(Fe=>(o("loose invalid filter",Fe,this.options),!!Fe.match(d[f.COMPARATORLOOSE])))),o("range list",G);var oe=new Map,he=G.map(Fe=>new s(Fe,this.options)),ie=OA(he),Oe;try{for(ie.s();!(Oe=ie.n()).done;){var de=Oe.value;if(y(de))return[de];oe.set(de.value,de)}}catch(Fe){ie.e(Fe)}finally{ie.f()}oe.size>1&&oe.has("")&&oe.delete("");var Me=[...oe.values()];return n.set(Y,Me),Me}intersects(H,z){if(!(H instanceof e))throw new TypeError("a Range is required");return this.set.some(Y=>l(Y,z)&&H.set.some($=>l($,z)&&Y.every(W=>$.every(X=>W.intersects(X,z)))))}test(H){if(!H)return!1;if(typeof H=="string")try{H=new c(H,this.options)}catch{return!1}for(var z=0;zR.value==="<0.0.0-0",p=R=>R.value==="",l=(R,H)=>{for(var z=!0,Y=R.slice(),$=Y.pop();z&&Y.length;)z=Y.every(W=>$.intersects(W,H)),$=Y.pop();return z},b=(R,H)=>(o("comp",R,H),R=x(R,H),o("caret",R),R=E(R,H),o("tildes",R),R=k(R,H),o("xrange",R),R=O(R,H),o("stars",R),R),L=R=>!R||R.toLowerCase()==="x"||R==="*",E=(R,H)=>R.trim().split(/\s+/).map(z=>S(z,H)).join(" "),S=(R,H)=>{var z=H.loose?d[f.TILDELOOSE]:d[f.TILDE];return R.replace(z,(Y,$,W,X,G)=>{o("tilde",R,Y,$,W,X,G);var oe;return L($)?oe="":L(W)?oe=">=".concat($,".0.0 <").concat(+$+1,".0.0-0"):L(X)?oe=">=".concat($,".").concat(W,".0 <").concat($,".").concat(+W+1,".0-0"):G?(o("replaceTilde pr",G),oe=">=".concat($,".").concat(W,".").concat(X,"-").concat(G," <").concat($,".").concat(+W+1,".0-0")):oe=">=".concat($,".").concat(W,".").concat(X," <").concat($,".").concat(+W+1,".0-0"),o("tilde return",oe),oe})},x=(R,H)=>R.trim().split(/\s+/).map(z=>F(z,H)).join(" "),F=(R,H)=>{o("caret",R,H);var z=H.loose?d[f.CARETLOOSE]:d[f.CARET],Y=H.includePrerelease?"-0":"";return R.replace(z,($,W,X,G,oe)=>{o("caret",R,$,W,X,G,oe);var he;return L(W)?he="":L(X)?he=">=".concat(W,".0.0").concat(Y," <").concat(+W+1,".0.0-0"):L(G)?W==="0"?he=">=".concat(W,".").concat(X,".0").concat(Y," <").concat(W,".").concat(+X+1,".0-0"):he=">=".concat(W,".").concat(X,".0").concat(Y," <").concat(+W+1,".0.0-0"):oe?(o("replaceCaret pr",oe),W==="0"?X==="0"?he=">=".concat(W,".").concat(X,".").concat(G,"-").concat(oe," <").concat(W,".").concat(X,".").concat(+G+1,"-0"):he=">=".concat(W,".").concat(X,".").concat(G,"-").concat(oe," <").concat(W,".").concat(+X+1,".0-0"):he=">=".concat(W,".").concat(X,".").concat(G,"-").concat(oe," <").concat(+W+1,".0.0-0")):(o("no pr"),W==="0"?X==="0"?he=">=".concat(W,".").concat(X,".").concat(G).concat(Y," <").concat(W,".").concat(X,".").concat(+G+1,"-0"):he=">=".concat(W,".").concat(X,".").concat(G).concat(Y," <").concat(W,".").concat(+X+1,".0-0"):he=">=".concat(W,".").concat(X,".").concat(G," <").concat(+W+1,".0.0-0")),o("caret return",he),he})},k=(R,H)=>(o("replaceXRanges",R,H),R.split(/\s+/).map(z=>M(z,H)).join(" ")),M=(R,H)=>{R=R.trim();var z=H.loose?d[f.XRANGELOOSE]:d[f.XRANGE];return R.replace(z,(Y,$,W,X,G,oe)=>{o("xRange",R,Y,$,W,X,G,oe);var he=L(W),ie=he||L(X),Oe=ie||L(G),de=Oe;return $==="="&&de&&($=""),oe=H.includePrerelease?"-0":"",he?$===">"||$==="<"?Y="<0.0.0-0":Y="*":$&&de?(ie&&(X=0),G=0,$===">"?($=">=",ie?(W=+W+1,X=0,G=0):(X=+X+1,G=0)):$==="<="&&($="<",ie?W=+W+1:X=+X+1),$==="<"&&(oe="-0"),Y="".concat($+W,".").concat(X,".").concat(G).concat(oe)):ie?Y=">=".concat(W,".0.0").concat(oe," <").concat(+W+1,".0.0-0"):Oe&&(Y=">=".concat(W,".").concat(X,".0").concat(oe," <").concat(W,".").concat(+X+1,".0-0")),o("xRange return",Y),Y})},O=(R,H)=>(o("replaceStars",R,H),R.trim().replace(d[f.STAR],"")),C=(R,H)=>(o("replaceGTE0",R,H),R.trim().replace(d[H.includePrerelease?f.GTE0PRE:f.GTE0],"")),P=R=>(H,z,Y,$,W,X,G,oe,he,ie,Oe,de,Me)=>(L(Y)?z="":L($)?z=">=".concat(Y,".0.0").concat(R?"-0":""):L(W)?z=">=".concat(Y,".").concat($,".0").concat(R?"-0":""):X?z=">=".concat(z):z=">=".concat(z).concat(R?"-0":""),L(he)?oe="":L(ie)?oe="<".concat(+he+1,".0.0-0"):L(Oe)?oe="<".concat(he,".").concat(+ie+1,".0-0"):de?oe="<=".concat(he,".").concat(ie,".").concat(Oe,"-").concat(de):R?oe="<".concat(he,".").concat(ie,".").concat(+Oe+1,"-0"):oe="<=".concat(oe),"".concat(z," ").concat(oe).trim()),j=(R,H,z)=>{for(var Y=0;Y0){var W=R[$].semver;if(W.major===H.major&&W.minor===H.minor&&W.patch===H.patch)return!0}return!1}return!0};return v5}var mxe=pY(),wxe=(e,t,n)=>{try{t=new mxe(t,n)}catch{return!1}return t.test(e)},yY=wxe;function Lxe(e,t,n){var i=e.open(t),s=1e4,o=250,c=new URL(t),d=c.origin,f=~~(s/o);function u(m){m.source===i&&(f=0,e.removeEventListener("message",u,!1))}e.addEventListener("message",u,!1);function a(){f<=0||(i.postMessage(n,d),setTimeout(a,o),f-=1)}setTimeout(a,o)}var bxe=`.vega-embed { position: relative; display: inline-block; box-sizing: border-box; } .vega-embed.has-actions { padding-right: 38px; } .vega-embed details:not([open]) > :not(summary) { display: none !important; } .vega-embed summary { list-style: none; position: absolute; top: 0; right: 0; padding: 6px; z-index: 1000; background: white; box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.1); color: #1b1e23; border: 1px solid #aaa; border-radius: 999px; opacity: 0.2; transition: opacity 0.4s ease-in; cursor: pointer; line-height: 0px; } .vega-embed summary::-webkit-details-marker { display: none; } .vega-embed summary:active { box-shadow: #aaa 0px 0px 0px 1px inset; } .vega-embed summary svg { width: 14px; height: 14px; } .vega-embed details[open] summary { opacity: 0.7; } .vega-embed:hover summary, .vega-embed:focus-within summary { opacity: 1 !important; transition: opacity 0.2s ease; } .vega-embed .vega-actions { position: absolute; z-index: 1001; top: 35px; right: -9px; display: flex; flex-direction: column; padding-bottom: 8px; padding-top: 8px; border-radius: 4px; box-shadow: 0 2px 8px 0 rgba(0, 0, 0, 0.2); border: 1px solid #d9d9d9; background: white; animation-duration: 0.15s; animation-name: scale-in; animation-timing-function: cubic-bezier(0.2, 0, 0.13, 1.5); text-align: left; } .vega-embed .vega-actions a { padding: 8px 16px; font-family: sans-serif; font-size: 14px; font-weight: 600; white-space: nowrap; color: #434a56; text-decoration: none; } .vega-embed .vega-actions a:hover, .vega-embed .vega-actions a:focus { background-color: #f7f7f9; color: black; } .vega-embed .vega-actions::before, .vega-embed .vega-actions::after { content: ""; display: inline-block; position: absolute; } .vega-embed .vega-actions::before { left: auto; right: 14px; top: -16px; border: 8px solid rgba(0, 0, 0, 0); border-bottom-color: #d9d9d9; } .vega-embed .vega-actions::after { left: auto; right: 15px; top: -14px; border: 7px solid rgba(0, 0, 0, 0); border-bottom-color: #fff; } .vega-embed .chart-wrapper.fit-x { width: 100%; } .vega-embed .chart-wrapper.fit-y { height: 100%; } .vega-embed-wrapper { max-width: 100%; overflow: auto; padding-right: 14px; } @keyframes scale-in { from { opacity: 0; transform: scale(0.6); } to { opacity: 1; transform: scale(1); } } `;String.prototype.startsWith||(String.prototype.startsWith=function(e,t){return this.substr(!t||t<0?0:+t,e.length)===e});function mY(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),i=1;i=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(u){throw u},f:s}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o=!0,c=!1,d;return{s:function(){n=n.call(e)},n:function(){var u=n.next();return o=u.done,u},e:function(u){c=!0,d=u},f:function(){try{!o&&n.return!=null&&n.return()}finally{if(c)throw d}}}}function Exe(e,t){if(e){if(typeof e=="string")return NA(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return NA(e,t)}}function NA(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);ne,"vega-lite":(e,t)=>r0.compile(e,{config:t}).spec},Bxe=` `,Fxe="chart-wrapper";function Ixe(e){return typeof e=="function"}function RA(e,t,n,i){var s="".concat(t,'
'),o="
".concat(n,""),c=window.open("");c.document.write(s+e+o),c.document.title="".concat(Y1[i]," JSON Source")}function Oxe(e,t){if(e.$schema){var n=sY(e.$schema);if(t&&t!==n.library){var i;console.warn("The given visualization spec is written in ".concat(Y1[n.library],", but mode argument sets ").concat((i=Y1[t])!==null&&i!==void 0?i:t,"."))}var s=n.library;return yY(o4[s],"^".concat(n.version.slice(1)))||console.warn("The input spec uses ".concat(Y1[s]," ").concat(n.version,", but the current version of ").concat(Y1[s]," is v").concat(o4[s],".")),s}return"mark"in e||"encoding"in e||"layer"in e||"hconcat"in e||"vconcat"in e||"facet"in e||"repeat"in e?"vega-lite":"marks"in e||"signals"in e||"scales"in e||"axes"in e?"vega":t??"vega"}function Mxe(e){return!!(e&&"load"in e)}function PA(e){return Mxe(e)?e:qs.loader(e)}function Axe(e){var t,n,i=(t=(n=e.usermeta)===null||n===void 0?void 0:n.embedOptions)!==null&&t!==void 0?t:{};return xe(i.defaultStyle)&&(i.defaultStyle=!1),i}function wY(e,t){return d9.apply(this,arguments)}function d9(){return d9=s4(Ea.mark(function e(t,n){var i,s,o,c,d,f,u,a,m,y,p,l=arguments;return Ea.wrap(function(L){for(;;)switch(L.prev=L.next){case 0:if(o=l.length>2&&l[2]!==void 0?l[2]:{},!xe(n)){L.next=10;break}return d=PA(o.loader),L.t0=JSON,L.next=6,d.load(n);case 6:L.t1=L.sent,c=L.t0.parse.call(L.t0,L.t1),L.next=11;break;case 10:c=n;case 11:return f=Axe(c),u=f.loader,(!d||u)&&(d=PA((a=o.loader)!==null&&a!==void 0?a:u)),L.next=16,DA(f,d);case 16:return m=L.sent,L.next=19,DA(o,d);case 19:return y=L.sent,p=Gl(Gl({},mY(y,m)),{},{config:Bh((i=y.config)!==null&&i!==void 0?i:{},(s=m.config)!==null&&s!==void 0?s:{})}),L.next=23,Cxe(t,c,p,d);case 23:return L.abrupt("return",L.sent);case 24:case"end":return L.stop()}},e)})),d9.apply(this,arguments)}function DA(e,t){return f9.apply(this,arguments)}function f9(){return f9=s4(Ea.mark(function e(t,n){var i,s,o;return Ea.wrap(function(d){for(;;)switch(d.prev=d.next){case 0:if(!xe(t.config)){d.next=8;break}return d.t1=JSON,d.next=4,n.load(t.config);case 4:d.t2=d.sent,d.t0=d.t1.parse.call(d.t1,d.t2),d.next=9;break;case 8:d.t0=(i=t.config)!==null&&i!==void 0?i:{};case 9:if(s=d.t0,!xe(t.patch)){d.next=18;break}return d.t4=JSON,d.next=14,n.load(t.patch);case 14:d.t5=d.sent,d.t3=d.t4.parse.call(d.t4,d.t5),d.next=19;break;case 18:d.t3=t.patch;case 19:return o=d.t3,d.abrupt("return",Gl(Gl(Gl({},t),o?{patch:o}:{}),s?{config:s}:{}));case 21:case"end":return d.stop()}},e)})),f9.apply(this,arguments)}function Nxe(e){var t,n=e.getRootNode?e.getRootNode():document;return n instanceof ShadowRoot?{root:n,rootContainer:n}:{root:document,rootContainer:(t=document.head)!==null&&t!==void 0?t:document.body}}function Cxe(e,t){return u9.apply(this,arguments)}function u9(){return u9=s4(Ea.mark(function e(t,n){var i,s,o,c,d,f,u,a,m,y,p,l,b,L,E,S,x,F,k,M,O,C,P,j,R,H,z,Y,$,W,X,G,oe,he,ie,Oe,de,Me,Fe,Ge,pt,ht,ge,V,q,D,K,J,re,se,_e,be=arguments;return Ea.wrap(function(It){for(;;)switch(It.prev=It.next){case 0:if(_e=function(){Me&&document.removeEventListener("click",Me),G.finalize()},a=be.length>2&&be[2]!==void 0?be[2]:{},m=be.length>3?be[3]:void 0,y=a.theme?Bh(aSe[a.theme],(i=a.config)!==null&&i!==void 0?i:{}):a.config,p=Ec(a.actions)?a.actions:mY({},Sxe,(s=a.actions)!==null&&s!==void 0?s:{}),l=Gl(Gl({},xxe),a.i18n),b=(o=a.renderer)!==null&&o!==void 0?o:"canvas",L=(c=a.logLevel)!==null&&c!==void 0?c:qs.Warn,E=(d=a.downloadFileName)!==null&&d!==void 0?d:"visualization",S=typeof t=="string"?document.querySelector(t):t,S){It.next=12;break}throw new Error("".concat(t," does not exist"));case 12:if(a.defaultStyle!==!1&&(x="vega-embed-style",F=Nxe(S),k=F.root,M=F.rootContainer,k.getElementById(x)||(O=document.createElement("style"),O.id=x,O.innerHTML=a.defaultStyle===void 0||a.defaultStyle===!0?bxe.toString():a.defaultStyle,M.appendChild(O))),C=Oxe(n,a.mode),P=kxe[C](n,y),C==="vega-lite"&&P.$schema&&(j=sY(P.$schema),yY(o4.vega,"^".concat(j.version.slice(1)))||console.warn("The compiled spec uses Vega ".concat(j.version,", but current version is v").concat(o4.vega,"."))),S.classList.add("vega-embed"),p&&S.classList.add("has-actions"),S.innerHTML="",R=S,p&&(H=document.createElement("div"),H.classList.add(Fxe),S.appendChild(H),R=H),z=a.patch,z&&(P=z instanceof Function?z(P):tm(P,z,!0,!1).newDocument),a.formatLocale&&qs.formatLocale(a.formatLocale),a.timeFormatLocale&&qs.timeFormatLocale(a.timeFormatLocale),a.expressionFunctions)for(Y in a.expressionFunctions)$=a.expressionFunctions[Y],"fn"in $?qs.expressionFunction(Y,$.fn,$.visitor):$ instanceof Function&&qs.expressionFunction(Y,$);return W=a.ast,X=qs.parse(P,C==="vega-lite"?{}:y,{ast:W}),G=new(a.viewClass||qs.View)(X,Gl({loader:m,logLevel:L,renderer:b},W?{expr:(f=(u=qs.expressionInterpreter)!==null&&u!==void 0?u:a.expr)!==null&&f!==void 0?f:Q6e}:{})),G.addSignalListener("autosize",(Et,et)=>{var Zt=et.type;Zt=="fit-x"?(R.classList.add("fit-x"),R.classList.remove("fit-y")):Zt=="fit-y"?(R.classList.remove("fit-x"),R.classList.add("fit-y")):Zt=="fit"?R.classList.add("fit-x","fit-y"):R.classList.remove("fit-x","fit-y")}),a.tooltip!==!1&&(oe=Ixe(a.tooltip)?a.tooltip:new _Se(a.tooltip===!0?{}:a.tooltip).call,G.tooltip(oe)),he=a.hover,he===void 0&&(he=C==="vega"),he&&(ie=typeof he=="boolean"?{}:he,Oe=ie.hoverSet,de=ie.updateSet,G.hover(Oe,de)),a&&(a.width!=null&&G.width(a.width),a.height!=null&&G.height(a.height),a.padding!=null&&G.padding(a.padding)),It.next=37,G.initialize(R,a.bind).runAsync();case 37:if(p!==!1){if(Fe=S,a.defaultStyle!==!1&&(Ge=document.createElement("details"),Ge.title=l.CLICK_TO_VIEW_ACTIONS,S.append(Ge),Fe=Ge,pt=document.createElement("summary"),pt.innerHTML=Bxe,Ge.append(pt),Me=Et=>{Ge.contains(Et.target)||Ge.removeAttribute("open")},document.addEventListener("click",Me)),ht=document.createElement("div"),Fe.append(ht),ht.classList.add("vega-actions"),p===!0||p.export!==!1){ge=vxe(["svg","png"]);try{for(q=function(){var et=V.value;if(p===!0||p.export===!0||p.export[et]){var Zt=l["".concat(et.toUpperCase(),"_ACTION")],kn=document.createElement("a");kn.text=Zt,kn.href="#",kn.target="_blank",kn.download="".concat(E,".").concat(et),kn.addEventListener("mousedown",function(){var Yi=s4(Ea.mark(function fe(oi){var jn;return Ea.wrap(function(ln){for(;;)switch(ln.prev=ln.next){case 0:return oi.preventDefault(),ln.next=3,G.toImageURL(et,a.scaleFactor);case 3:jn=ln.sent,this.href=jn;case 5:case"end":return ln.stop()}},fe,this)}));return function(fe){return Yi.apply(this,arguments)}}()),ht.append(kn)}},ge.s();!(V=ge.n()).done;)q()}catch(Et){ge.e(Et)}finally{ge.f()}}(p===!0||p.source!==!1)&&(D=document.createElement("a"),D.text=l.SOURCE_ACTION,D.href="#",D.addEventListener("click",function(Et){var et,Zt;RA(Ew(n),(et=a.sourceHeader)!==null&&et!==void 0?et:"",(Zt=a.sourceFooter)!==null&&Zt!==void 0?Zt:"",C),Et.preventDefault()}),ht.append(D)),C==="vega-lite"&&(p===!0||p.compiled!==!1)&&(K=document.createElement("a"),K.text=l.COMPILED_ACTION,K.href="#",K.addEventListener("click",function(Et){var et,Zt;RA(Ew(P),(et=a.sourceHeader)!==null&&et!==void 0?et:"",(Zt=a.sourceFooter)!==null&&Zt!==void 0?Zt:"","vega"),Et.preventDefault()}),ht.append(K)),(p===!0||p.editor!==!1)&&(re=(J=a.editorUrl)!==null&&J!==void 0?J:"https://vega.github.io/editor/",se=document.createElement("a"),se.text=l.EDITOR_ACTION,se.href="#",se.addEventListener("click",function(Et){Lxe(window,re,{config:y,mode:C,renderer:b,spec:Ew(n)}),Et.preventDefault()}),ht.append(se))}return It.abrupt("return",{view:G,spec:n,vgSpec:P,finalize:_e,embedOptions:a});case 39:case"end":return It.stop()}},e)})),u9.apply(this,arguments)}const Rxe=new Set(["width","height"]);function Pxe(e,t){for(const[n,i]of Object.entries(t))i&&(i&&{}.toString.call(i)==="[object Function]"?i(e.data(n)):e.change(n,qs.changeset().remove(()=>!0).insert(i)))}function T_(e={},t={},n=new Set){const i=Object.keys(e),s=Object.keys(t);return e===t||i.length===s.length&&i.filter(o=>!n.has(o)).every(o=>e[o]===t[o])}function jA(e,t){const n=Object.keys(t);for(const i of n)try{e.removeSignalListener(i,t[i])}catch(s){console.warn("Cannot remove invalid signal listener.",s)}return n.length>0}function S5(e,t){const n=Object.keys(t);for(const i of n)try{e.addSignalListener(i,t[i])}catch(s){console.warn("Cannot add invalid signal listener.",s)}return n.length>0}function Dxe(e){return new Set(e.flatMap(t=>Object.keys(t)))}function jxe(e,t){if(e===t)return!1;const n={width:!1,height:!1,isExpensive:!1},i="width"in e||"width"in t,s="height"in e||"height"in t;return i&&(!("width"in e)||!("width"in t)||e.width!==t.width)&&("width"in e&&typeof e.width=="number"?n.width=e.width:n.isExpensive=!0),s&&(!("height"in e)||!("height"in t)||e.height!==t.height)&&("height"in e&&typeof e.height=="number"?n.height=e.height:n.isExpensive=!0),[...Dxe([e,t])].filter(c=>c!=="width"&&c!=="height").some(c=>!(c in e)||!(c in t)||!IE(e[c],t[c]))&&(n.isExpensive=!0),n.width!==!1||n.height!==!1||n.isExpensive?n:!1}function UA(e,t){const{width:n,height:i}=t;return typeof n<"u"&&typeof i<"u"?{...e,width:n,height:i}:typeof n<"u"?{...e,width:n}:typeof i<"u"?{...e,height:i}:e}function Uxe(e){let t;return{c(){t=Tt("div")},m(n,i){$t(n,t,i),e[11](t)},p:Yn,i:Yn,o:Yn,d(n){n&&Pt(t),e[11](null)}}}function Hxe(e,t,n){let{options:i}=t,{spec:s}=t,{view:o}=t,{signalListeners:c={}}=t,{data:d={}}=t;const f=sf();let u,a={},m={},y={},p={},l;cN(()=>{L()});async function b(){L();try{n(6,u=await wY(l,s,i)),n(1,o=u.view),S5(o,c)&&o.runAsync(),S(o)}catch(k){E(k)}}function L(){u&&(u.finalize(),n(6,u=void 0),n(1,o=void 0))}function E(k){f("onError",{error:k}),console.warn(k)}function S(k){x(),f("onNewView",{view:k})}async function x(){d&&Object.keys(d).length>0&&u!==void 0&&(n(1,o=u.view),Pxe(o,d),await o.resize().runAsync())}function F(k){Wl[k?"unshift":"push"](()=>{l=k,n(0,l)})}return e.$$set=k=>{"options"in k&&n(2,i=k.options),"spec"in k&&n(3,s=k.spec),"view"in k&&n(1,o=k.view),"signalListeners"in k&&n(4,c=k.signalListeners),"data"in k&&n(5,d=k.data)},e.$$.update=()=>{if(e.$$.dirty&1056&&(T_(d,p)||x(),n(10,p=d)),e.$$.dirty&991&&l!==void 0){if(!T_(i,a,Rxe))b();else{const k=jxe(UA(s,i),UA(y,a)),M=c,O=m;if(k){if(k.isExpensive)b();else if(u!==void 0){const C=!T_(M,O);n(1,o=u.view),k.width!==!1&&o.width(k.width),k.height!==!1&&o.height(k.height),C&&(O&&jA(o,O),M&&S5(o,M)),o.runAsync()}}else!T_(M,O)&&u!==void 0&&(n(1,o=u.view),O&&jA(o,O),M&&S5(o,M),o.runAsync())}n(7,a=i),n(8,m=c),n(9,y=s)}},[l,o,i,s,c,d,u,a,m,y,p,F]}let zxe=class extends Vi{constructor(t){super(),qi(this,t,Hxe,Uxe,$i,{options:2,spec:3,view:1,signalListeners:4,data:5})}};function $xe(e){let t,n,i;function s(c){e[6](c)}let o={spec:e[1],data:e[2],signalListeners:e[3],options:e[4]};return e[0]!==void 0&&(o.view=e[0]),t=new zxe({props:o}),Wl.push(()=>_9(t,"view",s)),t.$on("onNewView",e[7]),t.$on("onError",e[8]),{c(){Nn(t.$$.fragment)},m(c,d){bn(t,c,d),i=!0},p(c,[d]){const f={};d&2&&(f.spec=c[1]),d&4&&(f.data=c[2]),d&8&&(f.signalListeners=c[3]),d&16&&(f.options=c[4]),!n&&d&1&&(n=!0,f.view=c[0],g9(()=>n=!1)),t.$set(f)},i(c){i||(wt(t.$$.fragment,c),i=!0)},o(c){Rt(t.$$.fragment,c),i=!1},d(c){Tn(t,c)}}}const qxe="vega-lite";function Vxe(e,t,n){let i,{spec:s}=t,{options:o={}}=t,{data:c={}}=t,{signalListeners:d={}}=t,{view:f=void 0}=t;function u(y){f=y,n(0,f)}function a(y){rn.call(this,e,y)}function m(y){rn.call(this,e,y)}return e.$$set=y=>{"spec"in y&&n(1,s=y.spec),"options"in y&&n(5,o=y.options),"data"in y&&n(2,c=y.data),"signalListeners"in y&&n(3,d=y.signalListeners),"view"in y&&n(0,f=y.view)},e.$$.update=()=>{e.$$.dirty&32&&n(4,i={...o,mode:qxe})},[f,s,c,d,i,o,u,a,m]}let Gxe=class extends Vi{constructor(t){super(),qi(this,t,Vxe,$xe,$i,{spec:1,options:5,data:2,signalListeners:3,view:0})}};const hx="hsl(171,69%,47%)";function Wxe(e){let t,n,i,s,o,c;function d(u){e[22](u)}let f={data:e[2],spec:e[1],options:{tooltip:!0,actions:!1,theme:"vox"}};return e[0]!==void 0&&(f.view=e[0]),n=new Gxe({props:f}),Wl.push(()=>_9(n,"view",d)),{c(){t=Tt("div"),Nn(n.$$.fragment),Ee(t,"class","container svelte-mufgje")},m(u,a){$t(u,t,a),bn(n,t,null),s=!0,o||(c=[Ri(t,"click",e[17]),Ri(t,"mousedown",e[18]),Ri(t,"mouseup",e[19]),Ri(t,"mouseenter",e[20]),Ri(t,"mouseleave",e[21])],o=!0)},p(u,[a]){const m={};a&4&&(m.data=u[2]),a&2&&(m.spec=u[1]),!i&&a&1&&(i=!0,m.view=u[0],g9(()=>i=!1)),n.$set(m)},i(u){s||(wt(n.$$.fragment,u),s=!0)},o(u){Rt(n.$$.fragment,u),s=!1},d(u){u&&Pt(t),Tn(n),o=!1,Xo(c)}}}function Yxe(e,t,n){let i,s;const o=sf();let{bins:c=[{bin:[0,10],count:200,filteredCount:150},{bin:[10,20],count:300,filteredCount:25},{bin:[20,30],count:72,filteredCount:12}]}=t,{title:d=""}=t,{width:f=400}=t,{height:u=125}=t,{countLabel:a="Count"}=t,{dimLabel:m=""}=t,{labelColor:y="black"}=t,{backgroundBarColor:p="hsla(0, 0%, 0%, 0.07)"}=t,{foregroundBarColor:l=hx}=t,{backgroundColor:b="white"}=t,{onlyFiltered:L=!1}=t,{type:E="quantitative"}=t,{timeUnit:S=""}=t,x,F=!1;function k(R){rn.call(this,e,R)}function M(R){rn.call(this,e,R)}function O(R){rn.call(this,e,R)}function C(R){rn.call(this,e,R)}function P(R){rn.call(this,e,R)}function j(R){x=R,n(0,x)}return e.$$set=R=>{"bins"in R&&n(3,c=R.bins),"title"in R&&n(4,d=R.title),"width"in R&&n(5,f=R.width),"height"in R&&n(6,u=R.height),"countLabel"in R&&n(7,a=R.countLabel),"dimLabel"in R&&n(8,m=R.dimLabel),"labelColor"in R&&n(9,y=R.labelColor),"backgroundBarColor"in R&&n(10,p=R.backgroundBarColor),"foregroundBarColor"in R&&n(11,l=R.foregroundBarColor),"backgroundColor"in R&&n(12,b=R.backgroundColor),"onlyFiltered"in R&&n(13,L=R.onlyFiltered),"type"in R&&n(14,E=R.type),"timeUnit"in R&&n(15,S=R.timeUnit)},e.$$.update=()=>{e.$$.dirty&8&&n(2,i={table:c}),e.$$.dirty&61296&&n(1,s={$schema:"https://vega.github.io/schema/vega-lite/v5.json",description:"A simple bar chart with embedded data.",data:{name:"table"},background:"transparent",width:f,height:u,title:{text:d,anchor:"start"},layer:[{params:[{name:"select",select:{type:"interval",encodings:["x"]}}],mark:{type:"bar",cursor:"col-resize"},encoding:{x:{...S?{timeUnit:S}:{},field:"bin[0]",type:E,bin:{binned:!0},axis:{title:m,titleColor:y,labelColor:y}},x2:{field:"bin[1]"},y:{field:L?"filteredCount":"count",type:"quantitative",axis:{title:"Count",titleColor:y,tickCount:3,labelColor:y}},color:{value:p}}},{mark:{type:"bar"},encoding:{size:{legend:null},x:{...S?{timeUnit:S}:{},field:"bin[0]",type:E,bin:{binned:!0},title:""},x2:{field:"bin[1]"},y:{field:"filteredCount",type:"quantitative"},color:{value:l}}}]}),e.$$.dirty&65537&&x&&!F&&(x.addSignalListener("select",(...R)=>{o("select",R[1]["bin\\.0"]??null)}),n(16,F=!0))},[x,s,i,c,d,f,u,a,m,y,p,l,b,L,E,S,F,k,M,O,C,P,j]}class Xxe extends Vi{constructor(t){super(),qi(this,t,Yxe,Wxe,$i,{bins:3,title:4,width:5,height:6,countLabel:7,dimLabel:8,labelColor:9,backgroundBarColor:10,foregroundBarColor:11,backgroundColor:12,onlyFiltered:13,type:14,timeUnit:15})}}function Kxe(e){let t,n;return t=new Xxe({props:{bins:e[8],timeUnit:e[7],type:e[6],title:e[0],width:e[1],height:e[2],countLabel:e[3],dimLabel:e[4],onlyFiltered:e[5]}}),t.$on("select",e[10]),t.$on("mouseenter",e[11]),t.$on("mouseleave",e[12]),t.$on("mouseup",e[13]),t.$on("mousedown",e[14]),t.$on("click",e[15]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,[s]){const o={};s&256&&(o.bins=i[8]),s&128&&(o.timeUnit=i[7]),s&64&&(o.type=i[6]),s&1&&(o.title=i[0]),s&2&&(o.width=i[1]),s&4&&(o.height=i[2]),s&8&&(o.countLabel=i[3]),s&16&&(o.dimLabel=i[4]),s&32&&(o.onlyFiltered=i[5]),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function Zxe(e){let t=[];if(e)for(let n=0;n{"state"in x&&n(9,s=x.state),"title"in x&&n(0,o=x.title),"width"in x&&n(1,c=x.width),"height"in x&&n(2,d=x.height),"countLabel"in x&&n(3,f=x.countLabel),"dimLabel"in x&&n(4,u=x.dimLabel),"onlyFiltered"in x&&n(5,a=x.onlyFiltered),"type"in x&&n(6,m=x.type),"timeUnit"in x&&n(7,y=x.timeUnit)},e.$$.update=()=>{e.$$.dirty&512&&n(8,i=Zxe(s))},[o,c,d,f,u,a,m,y,i,s,p,l,b,L,E,S]}class Qxe extends Vi{constructor(t){super(),qi(this,t,Jxe,Kxe,$i,{state:9,title:0,width:1,height:2,countLabel:3,dimLabel:4,onlyFiltered:5,type:6,timeUnit:7})}}function eke(e){let t,n,i,s,o,c;return i=new Nb({props:{title:e[1],selection:tke}}),o=new Qxe({props:{dimLabel:e[0],state:{bin:e[4],filter:e[3],total:e[2]},type:e[5],timeUnit:e[6],width:e[7],height:e[8]}}),o.$on("mouseenter",e[9]),o.$on("mouseleave",e[10]),o.$on("mousedown",e[11]),o.$on("mouseup",e[12]),o.$on("select",e[13]),{c(){t=Tt("div"),n=Tt("div"),Nn(i.$$.fragment),s=pn(),Nn(o.$$.fragment),Ee(n,"class","hist svelte-1velrzw"),Ee(t,"id","hist-container"),Ee(t,"class","svelte-1velrzw")},m(d,f){$t(d,t,f),Ve(t,n),bn(i,n,null),Ve(n,s),bn(o,n,null),c=!0},p(d,[f]){const u={};f&2&&(u.title=d[1]),i.$set(u);const a={};f&1&&(a.dimLabel=d[0]),f&28&&(a.state={bin:d[4],filter:d[3],total:d[2]}),f&32&&(a.type=d[5]),f&64&&(a.timeUnit=d[6]),f&128&&(a.width=d[7]),f&256&&(a.height=d[8]),o.$set(a)},i(d){c||(wt(i.$$.fragment,d),wt(o.$$.fragment,d),c=!0)},o(d){Rt(i.$$.fragment,d),Rt(o.$$.fragment,d),c=!1},d(d){d&&Pt(t),Tn(i),Tn(o)}}}let tke=null;function nke(e,t,n){let{dimLabel:i=""}=t,{title:s=""}=t,{totalCounts:o}=t,{filteredCounts:c}=t,{bins:d}=t,{type:f="quantitative"}=t,{timeUnit:u=""}=t,{width:a=400}=t,{height:m=150}=t;function y(E){rn.call(this,e,E)}function p(E){rn.call(this,e,E)}function l(E){rn.call(this,e,E)}function b(E){rn.call(this,e,E)}function L(E){rn.call(this,e,E)}return e.$$set=E=>{"dimLabel"in E&&n(0,i=E.dimLabel),"title"in E&&n(1,s=E.title),"totalCounts"in E&&n(2,o=E.totalCounts),"filteredCounts"in E&&n(3,c=E.filteredCounts),"bins"in E&&n(4,d=E.bins),"type"in E&&n(5,f=E.type),"timeUnit"in E&&n(6,u=E.timeUnit),"width"in E&&n(7,a=E.width),"height"in E&&n(8,m=E.height)},[i,s,o,c,d,f,u,a,m,y,p,l,b,L]}class N6 extends Vi{constructor(t){super(),qi(this,t,nke,eke,$i,{dimLabel:0,title:1,totalCounts:2,filteredCounts:3,bins:4,type:5,timeUnit:6,width:7,height:8})}}const ike=new Set(["width","height"]);function ske(e,t){for(const[n,i]of Object.entries(t))i&&(i&&{}.toString.call(i)==="[object Function]"?i(e.data(n)):e.change(n,qs.changeset().remove(()=>!0).insert(i)))}function v_(e={},t={},n=new Set){const i=Object.keys(e),s=Object.keys(t);return e===t||i.length===s.length&&i.filter(o=>!n.has(o)).every(o=>e[o]===t[o])}function HA(e,t){const n=Object.keys(t);for(const i of n)try{e.removeSignalListener(i,t[i])}catch(s){console.warn("Cannot remove invalid signal listener.",s)}return n.length>0}function x5(e,t){const n=Object.keys(t);for(const i of n)try{e.addSignalListener(i,t[i])}catch(s){console.warn("Cannot add invalid signal listener.",s)}return n.length>0}function rke(e){return new Set(e.flatMap(t=>Object.keys(t)))}function ake(e,t){if(e===t)return!1;const n={width:!1,height:!1,isExpensive:!1},i="width"in e||"width"in t,s="height"in e||"height"in t;return i&&(!("width"in e)||!("width"in t)||e.width!==t.width)&&("width"in e&&typeof e.width=="number"?n.width=e.width:n.isExpensive=!0),s&&(!("height"in e)||!("height"in t)||e.height!==t.height)&&("height"in e&&typeof e.height=="number"?n.height=e.height:n.isExpensive=!0),[...rke([e,t])].filter(c=>c!=="width"&&c!=="height").some(c=>!(c in e)||!(c in t)||!IE(e[c],t[c]))&&(n.isExpensive=!0),n.width!==!1||n.height!==!1||n.isExpensive?n:!1}function zA(e,t){const{width:n,height:i}=t;return typeof n<"u"&&typeof i<"u"?{...e,width:n,height:i}:typeof n<"u"?{...e,width:n}:typeof i<"u"?{...e,height:i}:e}function oke(e){let t;return{c(){t=Tt("div")},m(n,i){$t(n,t,i),e[11](t)},p:Yn,i:Yn,o:Yn,d(n){n&&Pt(t),e[11](null)}}}function lke(e,t,n){let{options:i}=t,{spec:s}=t,{view:o}=t,{signalListeners:c={}}=t,{data:d={}}=t;const f=sf();let u,a={},m={},y={},p={},l;cN(()=>{L()});async function b(){L();try{n(6,u=await wY(l,s,i)),n(1,o=u.view),x5(o,c)&&o.runAsync(),S(o)}catch(k){E(k)}}function L(){u&&(u.finalize(),n(6,u=void 0),n(1,o=void 0))}function E(k){f("onError",{error:k}),console.warn(k)}function S(k){x(),f("onNewView",{view:k})}async function x(){d&&Object.keys(d).length>0&&u!==void 0&&(n(1,o=u.view),ske(o,d),await o.resize().runAsync())}function F(k){Wl[k?"unshift":"push"](()=>{l=k,n(0,l)})}return e.$$set=k=>{"options"in k&&n(2,i=k.options),"spec"in k&&n(3,s=k.spec),"view"in k&&n(1,o=k.view),"signalListeners"in k&&n(4,c=k.signalListeners),"data"in k&&n(5,d=k.data)},e.$$.update=()=>{if(e.$$.dirty&1056&&(v_(d,p)||x(),n(10,p=d)),e.$$.dirty&991&&l!==void 0){if(!v_(i,a,ike))b();else{const k=ake(zA(s,i),zA(y,a)),M=c,O=m;if(k){if(k.isExpensive)b();else if(u!==void 0){const C=!v_(M,O);n(1,o=u.view),k.width!==!1&&o.width(k.width),k.height!==!1&&o.height(k.height),C&&(O&&HA(o,O),M&&x5(o,M)),o.runAsync()}}else!v_(M,O)&&u!==void 0&&(n(1,o=u.view),O&&HA(o,O),M&&x5(o,M),o.runAsync())}n(7,a=i),n(8,m=c),n(9,y=s)}},[l,o,i,s,c,d,u,a,m,y,p,F]}class cke extends Vi{constructor(t){super(),qi(this,t,lke,oke,$i,{options:2,spec:3,view:1,signalListeners:4,data:5})}}function dke(e){let t,n,i;function s(c){e[6](c)}let o={spec:e[1],data:e[2],signalListeners:e[3],options:e[4]};return e[0]!==void 0&&(o.view=e[0]),t=new cke({props:o}),Wl.push(()=>_9(t,"view",s)),t.$on("onNewView",e[7]),t.$on("onError",e[8]),{c(){Nn(t.$$.fragment)},m(c,d){bn(t,c,d),i=!0},p(c,[d]){const f={};d&2&&(f.spec=c[1]),d&4&&(f.data=c[2]),d&8&&(f.signalListeners=c[3]),d&16&&(f.options=c[4]),!n&&d&1&&(n=!0,f.view=c[0],g9(()=>n=!1)),t.$set(f)},i(c){i||(wt(t.$$.fragment,c),i=!0)},o(c){Rt(t.$$.fragment,c),i=!1},d(c){Tn(t,c)}}}const fke="vega-lite";function uke(e,t,n){let i,{spec:s}=t,{options:o={}}=t,{data:c={}}=t,{signalListeners:d={}}=t,{view:f=void 0}=t;function u(y){f=y,n(0,f)}function a(y){rn.call(this,e,y)}function m(y){rn.call(this,e,y)}return e.$$set=y=>{"spec"in y&&n(1,s=y.spec),"options"in y&&n(5,o=y.options),"data"in y&&n(2,c=y.data),"signalListeners"in y&&n(3,d=y.signalListeners),"view"in y&&n(0,f=y.view)},e.$$.update=()=>{e.$$.dirty&32&&n(4,i={...o,mode:fke})},[f,s,c,d,i,o,u,a,m]}class hke extends Vi{constructor(t){super(),qi(this,t,uke,dke,$i,{spec:1,options:5,data:2,signalListeners:3,view:0})}}function gke(e){let t,n,i,s;return t=new Nb({props:{title:e[2]}}),i=new hke({props:{data:{table:{filteredCount:e[0],totalCount:e[1]}},spec:e[3],options:{tooltip:!0,actions:!1,theme:"vox"}}}),{c(){Nn(t.$$.fragment),n=pn(),Nn(i.$$.fragment)},m(o,c){bn(t,o,c),$t(o,n,c),bn(i,o,c),s=!0},p(o,[c]){const d={};c&4&&(d.title=o[2]),t.$set(d);const f={};c&3&&(f.data={table:{filteredCount:o[0],totalCount:o[1]}}),c&8&&(f.spec=o[3]),i.$set(f)},i(o){s||(wt(t.$$.fragment,o),wt(i.$$.fragment,o),s=!0)},o(o){Rt(t.$$.fragment,o),Rt(i.$$.fragment,o),s=!1},d(o){Tn(t,o),o&&Pt(n),Tn(i,o)}}}function _ke(e,t,n){let i,{filteredCount:s}=t,{totalCount:o}=t,{width:c=500}=t,{height:d=50}=t,{barColor:f=hx}=t,{title:u="Table Rows Selected"}=t;return e.$$set=a=>{"filteredCount"in a&&n(0,s=a.filteredCount),"totalCount"in a&&n(1,o=a.totalCount),"width"in a&&n(4,c=a.width),"height"in a&&n(5,d=a.height),"barColor"in a&&n(6,f=a.barColor),"title"in a&&n(2,u=a.title)},e.$$.update=()=>{e.$$.dirty&114&&n(3,i={$schema:"https://vega.github.io/schema/vega-lite/v5.json",data:{name:"table"},width:c,height:d,title:null,mark:{type:"bar"},encoding:{x:{scale:{domain:[0,o]},type:"quantitative",title:null,field:"filteredCount",axis:{tickCount:5}},color:{value:f}}})},[s,o,u,i,c,d,f]}class pke extends Vi{constructor(t){super(),qi(this,t,_ke,gke,$i,{filteredCount:0,totalCount:1,width:4,height:5,barColor:6,title:2})}}let l4=[{d:"M102.263 199.566V200.763V201.944V203.109V204.259V205.394V206.515V207.622V208.716V209.795V210.863V211.917V212.958V213.988V215.007V216.013V217.012V217.998V218.972V219.936V220.891V221.835V222.77V223.695V224.612V225.52V226.418V227.307V228.189V229.061V229.926V230.783V231.632L102.606 231.751L102.945 231.869L103.048 231.634L103.415 231.814L103.734 231.971L103.938 231.77L104.159 231.551L104.457 231.536L104.792 231.519L105.014 231.507V231.693L104.932 232.001L104.863 232.258L105.047 232.492L105.066 232.517L105.315 232.653L105.549 232.779L105.654 233.13L105.91 233.4L106.105 233.604L106.292 233.8L106.558 234.079L106.745 234.274L106.995 234.533L107.142 234.687L107.214 234.986L107.299 235.343L107.246 235.553L107.363 235.587L107.594 235.351L107.81 235.204L108.078 235.023L108.259 234.901L108.595 234.895L108.755 234.538V234.034L108.925 234.044L109.026 233.975L109.07 233.827L108.963 233.624L109.286 233.53L109.519 233.461L109.85 233.273L110.174 233.09L110.329 233.232L110.483 233.369L110.783 233.699L110.804 233.778L110.784 233.932L110.755 234.086L110.938 234.516L110.99 234.564L111.14 234.623L111.32 234.765L111.399 234.888L111.659 235.084L111.703 235.165L111.728 235.296L111.77 235.409L111.819 235.489L111.866 235.604L111.979 235.738L112.193 235.889L112.341 235.993L112.549 236.139L112.759 236.436L112.942 236.694L113.15 236.947L113.12 237.149L113.331 237.46L113.553 237.853L113.724 238.201L113.845 238.395L113.99 238.675L114.168 239.017L114.37 239.404L114.525 239.653L114.728 239.999L114.826 240.205L114.76 240.345L114.676 240.519L114.935 240.602L115.114 240.658L115.068 240.85L115.009 241.103L115.211 241.203L115.35 241.27L115.321 241.402L115.397 241.552L115.409 241.799L115.657 241.784L115.767 241.776L115.914 241.886L116.109 242.031L116.304 242.165L116.471 242.279L116.69 242.348L116.959 242.446L117.092 242.645L117.338 242.731L117.429 243.008L117.714 243.11L117.881 243.042L117.941 243.155L117.988 243.284L118 243.448L117.985 243.606L117.913 243.739L117.86 243.882L117.824 244.036L117.81 244.201L117.819 244.378L117.848 244.532L117.935 244.816L117.963 244.989L117.968 245.104L117.775 245.508L117.708 245.7L117.714 245.786L117.573 245.985L117.314 246.264L117.197 246.425L117.139 246.371L116.804 246.33L116.683 245.975L116.619 245.699L116.521 245.458L116.524 245.403L116.613 245.241L116.947 245.108L116.95 245.055L116.826 245.02L116.795 244.962L116.762 244.698L116.771 244.466L116.762 244.312L116.705 243.997L116.622 243.803L116.406 243.425L116.387 243.329L116.482 243.208L116.541 243.095L116.176 243.29L115.678 243.495L115.465 243.637L115.421 243.693L115.406 243.742L115.446 243.876L115.44 243.919L115.395 243.998L115.344 244.221L115.236 244.457L115.181 244.506L114.986 244.418L114.935 244.343L114.837 244.035L114.86 243.952L114.931 243.882L115.027 243.733L115.149 243.501L115.38 242.911L115.532 242.908L115.8 242.79L115.38 242.731L115.318 242.7L115.262 242.619L115.211 242.488L115.126 242.342L114.966 242.29L114.896 242.237L114.792 242.06L114.722 241.98L114.683 241.881L114.677 241.764L114.647 241.704L114.537 241.683L114.478 241.642L114.461 241.337L114.244 241.257L114.154 241.19L114.011 241L113.972 240.907L113.959 240.829L113.994 240.617L113.979 240.577L113.851 240.599L113.06 240.269L113.101 239.833L112.955 239.255L112.799 239.02L112.831 238.929L112.864 238.88L112.934 238.878L113.237 239.049L113.523 239.252L113.559 239.223L113.103 238.793L112.989 238.663L112.96 238.508L112.958 238.424L112.995 238.38L113.424 238.418L113.45 238.386L113.016 238.259H112.928L112.832 238.441L112.786 238.483L112.694 238.474L112.662 238.447L112.551 238.225L112.446 238.071L112.249 237.858L112.213 237.705L112.204 237.481L112.23 237.268L112.389 236.78L112.453 236.694L112.47 236.641L112.421 236.648L112.374 236.696L112.242 236.923L112.105 237.295L111.994 237.422L111.924 237.391L111.819 237.24L111.598 237.056L111.343 237.008L111.181 236.819L110.943 236.29L110.911 236.026L110.88 235.962L110.751 235.877L110.672 235.749L110.549 235.099L110.387 234.644L110.346 234.403L110.36 234.164L110.339 234.138L110.282 234.324L110.267 234.422L110.165 234.449L110.261 234.638L110.285 234.733L110.237 234.725L110.138 234.748L110.304 235.068L110.378 235.564L110.489 235.929L110.561 236.223L110.593 236.446L110.64 236.659L110.769 237.127L110.787 237.22L110.772 237.297L110.73 237.387L110.657 237.42L110.425 237.359L110.339 237.243L110.214 237.031L110.039 236.934L109.607 236.982L109.572 236.966L109.573 236.792L109.624 236.481L109.584 236.356L109.36 235.897L109.363 235.807L109.674 235.595L109.523 235.578L109.401 235.66L109.354 235.607L109.281 235.311L109.234 235.201L109.211 235.177L109.198 235.459L109.249 235.607L109.257 235.692L109.249 235.811L109.217 235.897L109.161 235.948L109.105 235.962L109 235.903L108.884 235.791L108.782 235.738L108.744 235.694L108.696 235.57L108.616 235.476L108.238 235.357L108.011 235.216L107.993 235.253L108.063 235.404L108.069 235.492L108.011 235.52L107.909 235.663L107.938 235.683L108.046 235.636L108.166 235.642L108.365 235.729L108.546 235.842L108.612 235.906L108.639 236L108.662 236.034L108.839 236.144L108.848 236.202L108.734 236.372L108.968 236.354L109.105 236.415L109.28 236.679L109.339 236.825L109.347 237.013L109.31 237.068L109.24 237.106L108.764 237.167L108.592 237.393L108.557 237.396L108.426 237.335L108.189 237.155L107.892 236.984L107.217 236.475L107.199 236.45L107.188 236.351L107.141 236.301L107.049 236.258L106.922 236.128L106.759 235.912L106.658 235.743L106.62 235.621L106.526 235.48L106.22 235.187L106.061 235.075L105.919 235.01L105.796 234.997L105.762 234.957L105.819 234.893L105.826 234.855L105.556 234.794L105.297 234.655L104.643 234.266L104.305 234.022L104.107 233.905L104.024 233.839L103.987 233.786L104.034 233.729L104.167 233.671L104.256 233.604L104.398 233.356L104.408 233.275L104.332 233.093L104.299 232.927L104.3 232.836L104.317 232.744L104.338 232.685L104.398 232.627L104.44 232.598L104.492 232.618L104.658 232.846L104.681 232.929L104.673 233.24L104.72 233.603L104.736 233.577L104.751 233.456L104.76 233.228L104.778 233.118L104.813 233.009L104.874 232.953L105.061 232.987L105.148 232.967L104.783 232.802L104.553 232.492L104.512 232.46L104.387 232.447L104.255 232.572L103.912 232.979L103.817 233.051L103.388 233.276L103.097 233.322L102.77 233.287L102.492 233.214L101.792 232.859L101.682 232.776L101.845 232.555L101.851 232.486L101.795 232.261L101.748 232.197L101.681 232.162L101.662 232.187V232.255L101.681 232.378L101.627 232.444L101.509 232.514L101.308 232.586L100.687 232.404L100.051 232.253L99.4823 232.221L98.6791 232.341L98.2516 232.462L98.0021 232.474L97.7617 232.453L97.7419 232.369L97.8515 232.32L97.8454 232.259L97.707 232.068L97.4955 231.953L97.2125 231.911L97.0513 231.855L97.0102 231.783L96.9098 231.716L96.7516 231.652L96.6816 231.536L96.7379 231.176L96.7926 230.96L96.8474 230.81L96.9843 230.563L96.9372 230.581L96.7379 230.763L96.5644 230.949L96.4047 231.192L96.3089 231.303L96.1856 231.405L95.9939 231.381L95.7338 231.23L95.5117 231.152L95.3261 231.147L95.253 231.121L95.3793 230.986L95.4523 230.877L95.5528 230.702L95.574 230.617L94.8955 230.589L94.8712 230.496L94.8697 230.427L94.8484 230.371L94.7495 230.328L94.611 230.36L94.3874 230.47L94.29 230.386L94.325 230.339L94.3981 230.305L94.5471 230.147L94.3463 230.064L94.2444 229.97L94.1942 229.892L94.1972 229.611L94.2505 229.432L94.7008 229.256L94.5578 229.187L94.2733 229.212L94.0831 229.361L93.8565 229.576L93.7043 229.657L93.6267 229.602L93.5248 229.584L93.397 229.601L93.3118 229.656L93.2677 229.749L93.2175 229.811L93.1597 229.843L93.1186 229.833L93.0578 229.738L92.9285 229.679L92.8661 229.605L92.8296 229.651L92.7854 229.788L92.7398 229.859L92.5223 229.93L92.4021 229.917L92.2591 229.744L92.2378 229.685L92.2865 229.535L92.5998 228.942L92.5679 228.945L92.466 229.038L92.2636 229.276L92.1739 229.346L92.0187 229.355L91.9457 229.329L91.8574 229.349L91.754 229.413L91.687 229.483L91.6551 229.558L91.6764 229.57L91.8316 229.485L91.9198 229.462L91.9442 229.503L91.8224 229.77L91.7494 230.023L91.6794 230.087L91.5684 230.077L91.4467 230.101L91.4452 230.171L91.6718 230.374L91.754 230.403L91.859 230.475L91.8742 230.546L91.8346 230.74L91.8042 230.816L91.757 230.856L91.5714 230.85L91.5121 230.87L91.3873 230.99L91.325 231.091L91.3478 231.1L91.4558 231.018L91.6125 230.973L91.8179 230.967L91.9715 230.923L92.0719 230.841L92.1693 230.864L92.2651 230.992L92.2941 231.103L92.256 231.199L92.1769 231.268L92.0583 231.309L91.9837 231.37L91.9518 231.452L91.9335 231.573L91.9289 231.733L91.9594 232.021L91.9365 232.061L91.8924 232.082L91.8255 232.087L91.7662 232.154L91.6262 232.535L91.5775 232.576L91.5182 232.535L91.4665 232.54L91.4208 232.59L91.3219 232.628L91.1683 232.654L91.0374 232.645L90.8062 232.563L90.7119 232.505L90.6388 232.409L90.4304 232.509L90.3757 232.465L90.2463 232.201L90.219 232.216L90.1946 232.502L90.1551 232.601L90.0273 232.807L89.9573 233.16L89.936 233.171L89.9116 233.121L89.8325 232.805L89.7915 232.735L89.6758 232.916L89.6637 232.982L89.6941 233.217L89.6667 233.252L89.4324 233.125L89.3746 233.119L89.3594 233.141L89.44 233.322L89.4309 233.388L89.0993 233.739L89.0125 233.726L88.9578 233.691L88.8984 233.697L88.687 233.827L88.6292 233.821L88.5501 233.743L88.5135 233.746L88.4938 233.827L88.4907 233.984L88.4131 234.132L88.1621 234.371L88.0952 234.481L88.045 234.632L88.0069 234.646L87.8594 234.55L87.689 234.487L87.6646 234.518L87.7164 234.609L87.7057 234.666L87.6312 234.687L87.5384 234.68L87.4258 234.643L87.2676 234.686L87.0637 234.806L86.8933 234.803L86.656 234.603L86.5906 234.588L86.5693 234.532L86.6149 234.37L86.6819 234.248L86.7321 234.191L86.9572 234.034L87.2143 233.976L87.3756 233.882L87.5718 233.687L87.6753 233.539L87.8807 233.157L87.8655 233.128L87.8198 233.107L87.3695 233.469L87.3026 233.502L87.2128 233.499L86.8523 233.36L86.7762 233.301L86.7245 233.127L86.8249 232.73L86.8949 232.538L87.0698 232.241L87.2995 231.922L87.3786 231.715L87.4973 231.158L87.4897 230.905L87.4364 230.594L87.4349 230.409L87.4851 230.351L88.0115 230.063L88.261 229.846L88.7448 229.525L88.8771 229.528L88.9745 229.639L89.0871 229.727L89.2149 229.793L89.3807 229.787L89.583 229.706L89.904 229.737L90.5628 229.947L90.7027 229.959L90.7088 229.932L90.6069 229.784L90.1535 229.698L89.9619 229.613L89.4248 229.235L89.3016 229.088L89.3518 229.02L89.4826 228.963L89.5283 228.908L89.5481 228.812L89.6241 228.681L89.7565 228.515L89.9588 228.353L90.3407 228.112L90.1916 228.102L89.9162 228.146L89.8158 228.192L89.6317 228.364L89.5602 228.484L89.4583 228.719L89.4142 228.764L89.224 228.797L88.7037 228.82L88.6155 228.699L88.5668 228.68L88.5029 228.696L88.0252 229.003L87.8533 229.159L87.7316 229.337L87.5429 229.467L87.2874 229.549L87.0957 229.651L86.8949 229.854L86.8264 230.01L86.8218 230.083L86.8705 230.313L86.8203 230.356L86.7047 230.374L86.5191 230.527L86.1266 230.976L86.0749 231.14L86.0764 231.196L86.1403 231.323L86.0962 231.405L85.9851 231.535L85.7386 231.741L85.5774 231.818L85.4724 231.823L85.372 231.794L85.1925 231.661L85.0464 231.654L85.0373 231.672L85.2351 231.814L85.4359 231.995L85.5606 232.146L85.6108 232.265L85.6124 232.387L85.5667 232.514L85.4237 232.732L85.2838 232.798L84.9262 232.863L84.8106 232.915L84.7756 232.955L85.0206 233.046L85.0434 233.093L85.0099 233.275L84.9445 233.334L84.7406 233.443L84.5581 233.475L84.5307 233.453L84.5642 233.31L84.555 233.275L84.4866 233.246L84.3892 233.301L84.1458 233.511L84.1199 233.546L84.2082 233.603L84.1899 233.65L84.0576 233.801L84.0028 233.902L83.9146 234.004L83.5221 234.315L83.5525 234.391L83.4506 234.661L83.3943 234.898L83.4642 234.997L83.7944 235.114L83.9541 235.143L84.1428 235.224L84.4835 235.444L84.5976 235.587L84.6144 235.654L84.6037 235.727L84.5627 235.826L84.4562 236.012L84.1991 236.289L84.0834 236.366L83.907 236.427L83.8491 236.472L83.6225 236.732L83.5616 236.873L83.5707 236.995L83.5281 237.08L83.2376 237.248L83.2482 237.278L83.3532 237.291L83.3152 237.439L83.2984 237.643L83.2482 237.678L83.0672 237.676L82.8359 237.756L82.8192 237.779L82.8146 237.925L82.2107 238.032L82.0783 238.309L82.0099 238.395L81.7725 238.596L81.628 238.677L81.4622 238.726L81.3755 238.794L81.3679 238.881L81.3207 238.956L81.1777 239.081L81.1077 239.237L81.056 239.261L80.7882 239.299L80.735 239.348L80.7091 239.558L80.6589 239.565L80.5646 239.516L80.4414 239.554L80.1645 239.792L80.1036 239.877L80.1097 239.923L80.1523 239.969L80.2177 240.109L80.2132 240.204L80.1067 240.467L80.0686 240.509L79.9393 240.574L79.8861 240.719L79.7659 240.704L79.67 240.731L79.6077 240.827L79.5392 240.884L79.4647 240.899L79.3719 240.975L79.2593 241.114L79.1558 241.203L79.06 241.241L78.9672 241.25L78.8774 241.23L78.7968 241.245L78.7253 241.296L78.6553 241.375L78.599 241.601L78.5275 241.701L78.4819 241.72L78.3906 241.704L78.2522 241.657L78.1107 241.674L77.884 241.813L77.8125 241.916L77.9555 241.939L78.027 241.97L78.0255 241.999L77.9509 242.028L77.8232 242.026L77.7471 242.051L77.6543 242.11L77.42 242.174L77.3318 242.22L77.1553 242.479L77.134 242.537L77.1568 242.551L77.2557 242.523L77.3713 242.566L77.4322 242.621L77.4702 242.688L77.5067 242.818L77.5295 242.838L77.3059 243.056L77.242 243.149L77.2009 243.184L77.1735 243.158L77.1462 242.915L77.1294 242.874L77.0762 242.87L77.026 242.946L76.9134 243.233L76.7917 243.376L75.8758 243.745L75.742 243.829L75.7161 243.986L75.6781 244.122L75.6172 244.23L75.5457 244.299L75.5305 244.25L75.5381 243.868L75.5199 243.792L75.4271 243.743L75.386 243.75L75.3297 243.771L75.2384 243.853L75.1821 243.875L75.1121 243.868L74.9935 243.949L74.709 244.21L74.5234 244.274L74.4747 244.328L74.3956 244.469L74.3423 244.521L74.2648 244.526L74.1613 244.483L74.0792 244.514L74.0168 244.617L73.9529 244.659L73.7718 244.582L73.6927 244.634L73.5893 244.767L73.4813 244.854L73.3687 244.896L73.0766 244.941L72.9595 244.912L72.9351 244.874L72.9412 244.704L72.9884 244.582L73.0325 244.524L73.0903 244.474L73.1755 244.468L73.3352 244.506L73.317 244.465L73.2592 244.416L73.1131 244.332L72.9686 244.289L72.8849 244.317L72.7678 244.382L72.6887 244.457L72.6461 244.541L72.5928 244.817L72.5624 244.892L72.2201 245.377L72.0862 245.526L71.9539 245.516L71.89 245.572L71.8002 245.693L71.7165 245.751L71.6405 245.746L71.5811 245.723L71.5385 245.682L71.5461 245.644L71.6039 245.609L71.5842 245.513L71.4868 245.354L71.4199 245.269L71.2936 245.259L71.2738 245.331L71.3164 245.699L71.3103 245.781L71.2312 245.886L71.0228 246.002L70.9574 245.991L70.7703 245.761L70.5938 245.715L70.5816 245.79L70.6212 245.943L70.577 246.085L70.4493 246.217L70.3519 246.281L70.285 246.277L70.2819 246.184L70.3412 246.002L70.3565 245.851L70.3275 245.729L70.3306 245.636L70.3656 245.571L70.6014 245.389L70.7003 245.362L70.7535 245.406L70.8205 245.413L70.8996 245.384L70.9498 245.327L70.9711 245.24L71.073 245.128L71.2556 244.993L71.464 244.742L71.6983 244.376L71.9736 244.059L72.2901 243.792L72.6324 243.58L73.3215 243.287L73.3748 243.306L73.3124 243.4L73.355 243.46L73.4235 243.467L73.676 243.42L73.7764 243.359L73.8068 243.419L73.7718 243.493L73.6197 243.57L73.6243 243.632L73.8449 243.926L73.9149 243.971L73.9727 243.965L73.997 243.926L73.9787 243.714L74.0533 243.675L74.2054 243.666L74.3043 243.693L74.35 243.759L74.4367 243.812L74.5645 243.855L74.6436 243.841L74.674 243.772L74.6192 243.69L74.3743 243.509L74.3058 243.432L74.2891 243.327L74.3241 243.191L74.4017 242.99L74.5203 242.722L74.6284 242.534L74.8474 242.322L74.995 242.217L75.3692 241.893L76.0888 241.562L76.2668 241.349L76.5087 241.114L76.6122 241.056V241.148L76.6456 241.228L76.8069 241.282L76.9119 241.3L76.9606 241.283L76.9742 241.196L76.9529 241.039L76.9469 240.891L76.9575 240.751L76.9803 240.64L77.0883 240.443L77.2481 240.219L77.4672 239.957L77.6056 239.838L77.7364 239.775L77.8627 239.661L78.0787 239.389L78.1487 239.345L78.3039 239.292L78.3602 239.316L78.3937 239.385L78.4347 239.427L78.5929 239.465L78.6979 239.404L78.6812 239.372L78.596 239.353L78.5412 239.313L78.4895 239.151L78.3845 239.054L78.3602 238.942L78.3784 238.77L78.4682 238.363L78.4834 237.942L78.564 237.701L78.7253 237.614L79.0813 237.554L78.8729 237.445L78.7953 237.443L78.6599 237.391L78.6082 237.126L78.6097 236.932L78.6994 236.708L79.0311 236.33L79.3947 236.066L79.346 236.045L79.3004 235.967L79.4677 235.438L79.632 234.962L79.4114 235.367L79.1558 235.675L78.4058 236.032L77.8962 236.331L77.6543 236.403L77.4945 236.327L77.3698 236.04L77.2983 235.938L77.207 235.75L77.245 235.506L77.3181 235.337L77.4778 235.309L77.6573 235.392L77.8125 235.399L77.6117 235.232L77.3226 235.085L77.1918 235.132L77.0914 235.369L76.9575 235.531L76.8404 235.473L76.7704 235.407L76.8191 235.605L76.7293 235.906L76.6958 236.113L76.8236 236.659L76.7993 236.877L76.5665 236.976L76.3779 236.798L75.9839 236.106L75.8469 235.907L75.5381 235.579L75.4362 235.627L75.3069 235.788L75.1806 235.833L74.8474 235.595L74.6923 235.412L74.5462 235.19L74.321 235.312L74.1248 235.457L73.8951 235.689L73.7414 235.688L73.3231 235.886L73.2789 235.89L73.2196 235.997L73.1618 236.045L73.1146 236.249L72.5502 236.408L71.9919 236.319L72.1866 236.206L72.4042 236.118L72.5928 235.904L72.5122 235.619L72.4985 235.473L72.5015 235.288L72.7084 235.027H72.4939L72.3555 235.12L72.2262 234.925L72.1653 234.539L72.3129 234.31L72.3813 234.134L72.4392 233.89L72.4437 233.681L72.3296 233.325L72.001 232.567L71.8519 231.997L71.5963 231.692L71.788 231.19L72.001 230.731L72.2764 230.525L72.2551 230.495L72.1029 230.496L72.0025 230.524L71.9143 230.673L71.8215 230.787L71.5294 231.371L71.3423 231.655L71.2206 231.736L71.4168 231.846L71.4472 231.937L71.4853 232.146L71.4351 232.399L71.3849 232.54L71.1536 232.529L70.9452 232.732L70.4553 232.953L69.7951 233.078L69.471 233.063L69.1333 232.807L69.1363 232.657L69.15 232.528L68.6647 232.082L68.3894 231.637L68.1916 231.628L68.0197 231.509L67.8174 231.323L67.8356 231.173L67.8676 231.068L67.7428 230.993L67.5831 231.001L67.3975 230.949L67.8812 230.368L68.0471 229.978L68.1825 229.921L68.3589 229.982L68.6008 230.136L68.8062 230.205L68.8792 230.276L68.9553 230.414L68.8762 230.642L68.8032 230.803L68.8929 230.76L69.147 230.511L69.3372 230.293L69.4284 230.316L69.4878 230.354L69.5927 230.58L69.7236 230.809L70.0126 230.591L70.1663 230.319L70.0355 230.2L69.8757 230.13L69.4695 230.037L69.5684 229.959L69.8286 229.968L69.9274 229.894L69.824 229.79L69.6947 229.697L69.3432 230.006L68.7028 229.991L68.2555 229.81L67.8097 229.842L67.7398 229.807L67.653 229.709L67.9041 229.479L68.0821 229.351L68.0912 229.276L67.9877 229.267L67.793 229.328L67.7063 229.221L67.72 229.037L67.688 229.053L67.6105 229.154L67.5009 229.104L67.4081 229.02L67.4568 228.931L67.5526 228.809L67.51 228.791L67.4248 228.817L67.3412 228.977L67.3594 229.107L67.3579 229.293L67.2149 229.326L67.0932 229.303L67.005 229.117L66.9137 228.716L66.6672 228.609L66.6064 228.405L66.7631 228.143L66.6946 228.007L66.5288 227.963L66.3386 228.095L66.2549 227.978L66.2397 227.848L66.2336 227.662L66.2869 227.643L66.331 227.679L66.7113 227.575L66.7479 227.525L66.4451 227.366L66.3614 227.2L66.4862 227.106L66.7113 227.098L67.0278 226.999L66.8939 226.822L66.8665 226.724L66.8391 226.564L66.8924 226.293L67.2636 225.667L67.6257 225.143L67.7382 225.021L67.9041 224.955L68.0592 225.006L68.2205 225.118L68.2509 225.07L68.1962 225.024L68.1277 224.807L68.3513 224.722L68.4822 224.478L68.4913 224.408L68.3483 224.51L68.1992 224.678L68.1627 224.51L68.1247 224.123L68.1901 223.755L68.2403 223.589L68.3635 223.432L68.721 223.369L68.7834 223.401L68.7971 223.326L68.5826 223.093L68.6708 222.91L68.7484 222.815L69.1805 222.668L69.4163 222.713L69.7114 222.886L69.8833 223.101L69.859 223.21L69.8164 223.275L69.7281 223.346L69.6947 223.401L69.7099 223.445L69.8362 223.317L70.0446 223.162L70.1602 223.229L70.253 223.351L70.3549 223.349L70.6775 223.244L70.8418 223.133L71.0426 222.841L71.3088 222.652L71.6831 222.054L71.7941 221.809L71.9219 221.771L72.0375 221.792L72.1182 221.993L72.2353 222.053L72.9062 222.004L73.2485 221.911L73.4874 221.714L73.7353 221.383L73.8783 221.161L73.9468 220.869L73.8586 220.491L73.7673 220.177L73.6471 219.454L73.3139 218.974L73.0766 218.83L72.926 218.85L73.0355 218.542L73.3535 218.576L73.5604 218.516L73.7277 218.367L73.7825 218.254L73.8646 218.022L73.8357 217.775L73.7916 217.641L73.676 217.493L73.5391 217.275L73.4432 217.201L73.3626 217.206L72.9625 217.642L72.7221 217.65L72.5426 217.57L72.3859 217.818L71.9508 218.034L71.718 218.252L71.2875 218.792L71.1795 219.036L71.0426 219.047L70.9437 218.574L70.4751 218.121L70.3336 218.275L70.4112 218.417L70.5177 218.518L70.6927 218.562L70.6166 218.699L70.5588 218.881L70.3823 218.71L70.0689 218.461L69.7434 218.333L68.8975 218.347L68.3422 218.601L68.2905 218.548L68.2372 218.527L68.1444 218.588L68.1049 218.691L68.044 218.757L67.9299 218.78L67.7017 218.742L67.2605 218.583L66.2626 218.35L66.0009 218.206L65.7772 217.863L65.7818 217.63L65.8807 217.531L65.8716 217.194L65.6768 217.104L65.2813 216.617L65.1352 216.41L65.1672 216.387L65.2387 216.443L65.3741 216.486L65.7057 216.419L65.8198 216.102L66.0663 216.012L66.293 216.056L66.2428 215.971L66.185 215.904L65.5947 215.742L65.5141 215.792L64.4567 215.504L63.6215 215.001L63.5531 214.905L63.477 214.688L63.5896 214.474L63.7021 214.374L63.7067 214.491L63.725 214.607L64.2042 214.339L64.4537 213.985L64.9283 213.922L65.0394 213.825L65.187 213.634L65.3969 213.308L65.6936 213.135L65.8959 212.98L66.1591 212.888L66.3843 213.041L66.4542 213.062L66.8635 213.093L66.9974 213.027L67.0552 212.978L67.0978 212.901L66.6961 212.623L66.7372 212.469L66.7889 212.359L67.2575 212.034L67.6165 211.926L67.8082 211.934L68.3666 211.513L68.6723 211.392L69.2489 211.311L69.7221 211.291L69.8499 211.442L69.5958 211.41L69.4832 211.438L69.5623 211.49L69.6521 211.6L69.6262 211.738L69.4695 212.149L69.4817 212.475L69.3798 212.58L69.2809 212.728L69.7662 213.195L70.5162 213.224L70.9239 213.14L71.1597 213.279L71.3529 213.311L71.8869 213.239L72.2885 213.338L72.4559 213.3L72.8271 212.602L72.9731 212.492L73.1314 212.614L73.3383 212.713L73.4691 212.641L73.5771 212.821L73.5269 212.445L73.4539 212.303L72.8469 212.042L72.4407 212.172L72.3129 212.025L72.3555 211.734L71.9204 211.011L71.7393 210.864L71.5248 210.857L71.4153 210.604L71.324 210.277L71.5096 210.145L71.677 210.084L71.8321 210.189L72.0071 210.617L72.1699 210.68L72.1227 211.104L72.3251 211.493L72.7815 211.853L73.1466 211.72L73.4052 211.725L73.5589 211.801L73.9361 212.123L74.1278 212.162L74.7272 211.993L74.7333 211.676L74.6831 211.446L74.5416 211.301L74.137 211.328L73.822 211.09L73.5543 211.156L73.0583 211.52L72.8088 211.377L72.6521 211.182L72.4011 210.983L72.3692 210.607L72.5806 210.174L72.7373 209.966L72.5974 209.815L72.2459 209.708L71.6359 209.817L71.607 209.669L71.61 209.509L71.3605 209.823L71.105 209.757L70.7611 209.791L70.002 209.513L69.7312 209.17L69.6171 208.891L69.4117 208.121L69.15 207.636L67.3442 205.967L66.5227 205.543L66.1272 205.072L65.8792 204.956L65.6418 204.909L65.3391 204.756L65.543 204.567L65.6829 204.503L65.5369 204.7L65.6479 204.749L65.8244 204.636L65.9203 204.5L66.0602 203.92L66.2047 203.036L66.1667 202.685L67.1693 202.755L67.8356 202.696L68.0562 202.617L68.8975 202.481L69.115 202.382L69.5197 202.08L69.9959 201.543L70.4036 200.834L70.469 200.641L70.4949 200.69L70.5314 200.66L70.5755 200.388L70.6288 199.746L70.8311 199.138L71.6922 197.733L72.0923 197.17L72.2262 196.914L72.3646 196.726L72.462 196.905L72.5091 196.958L72.5365 197.042L72.4544 197.082L72.3205 197.263L72.1334 197.385L72.0877 197.448L72.1973 197.434L72.5259 197.301L72.7115 197.14L73.6319 196.842L74.1309 196.347L74.1507 196.235L74.8915 195.613L74.9935 195.637L75.1121 195.712L74.9068 196.124L75.0513 196.231L74.9235 196.719L75.1928 196.726L75.2521 196.951L75.2673 196.757L75.2643 196.479L75.2856 196.206L75.3251 196.017L75.5138 196.103L75.9382 195.9L75.424 195.874L75.1152 195.427L74.9433 195.424L75.5168 194.764L76.0417 194.362L76.1603 194.37L76.2181 194.445L76.2303 194.565L76.1177 194.645L76.0067 194.786L76.0584 194.911L76.1345 194.93L76.387 194.828L76.4996 194.699L77.0366 194.71L77.1948 194.619L77.2329 194.527L77.9281 194.509L78.0559 194.443L78.491 194.088L78.8926 193.655L79.0782 193.417L79.3962 192.81L79.6685 192.412L80.1112 192L80.2192 192.049L80.0747 192.128L79.9743 192.296L80.1143 192.52L81.0575 192.981L81.2948 193.005L81.3892 193.28L81.31 193.543L81.0666 193.835L80.5768 194.132L80.7274 194.245L80.8247 194.509L80.9693 194.541L81.2051 194.442L81.3892 194.28L81.7695 193.749L81.8897 193.452L81.9794 193.377L82.2989 193.449L82.4799 193.601L82.6853 193.873L82.6093 194.134L82.5256 194.28L82.7933 194.483L83.0885 194.526L83.3699 194.689L83.767 194.356L84.0773 194.285L84.3694 194.295L84.7483 194.114L85.3903 194.362L85.553 194.298L85.8101 194.341L86.084 194.491L86.1813 194.649L85.8893 194.985L85.8421 195.331L85.944 195.474L86.1296 195.499L86.1524 195.7L86.2681 195.75L86.8462 195.735L86.8021 195.83L86.7731 195.944L86.5936 196.199L87.6251 196.342L87.7635 196.202L87.9765 196.145L88.4299 195.952L88.6003 196.037L88.8011 196.235L88.9867 196.276L89.1601 196.237L89.5648 195.953L90.0318 195.939L90.2235 196.032L90.4259 195.993L91.0344 196.318L91.258 196.356L91.5577 196.775L91.7129 196.787L91.8879 196.609L92.04 196.615L92.1891 196.786L92.4325 196.838L92.5451 197.106L92.6668 197.204L93.5872 197.402L94.0421 197.312L94.7054 197.335L95.0248 197.462L95.3611 197.445L95.9103 197.905L96.2008 197.977L96.2571 198.082L97.0847 198.194L97.3738 197.954L97.8789 197.89L98.3337 197.689L98.5908 197.69L98.8905 197.741L99.0062 197.716L99.0898 197.628L99.8216 197.974L100.231 198.369L100.41 198.66L101.267 199.074L101.515 199.304L101.685 199.557L101.784 199.585L101.854 199.511L102.154 199.533L102.263 199.566ZM66.3067 212.666L66.2519 212.685L66.2549 212.631L66.4177 212.486L66.7189 212.306L66.7083 212.345L66.547 212.484L66.3067 212.666ZM58.6407 221.431L58.662 221.51L58.8111 221.498L59.021 221.531L59.2538 221.608L59.4835 221.58L59.7725 221.339L59.946 221.275L60.1194 221.242L60.3065 221.301L60.4906 221.429L60.5621 221.505L60.6184 221.637L60.6564 221.795L60.7127 221.91L61.0566 222.05L61.2756 222.106L61.3289 222.183L61.376 222.288L61.5571 222.369L61.7472 222.34L61.8537 222.369L62.1763 222.373L62.5779 222.491L62.5125 222.799L62.3816 222.934L62.0135 222.89L61.6468 222.934L61.4947 223.093L61.3684 223.293L61.3517 223.487L61.2771 223.575L61.2011 223.615L61.1387 223.508L61.055 223.18L60.9972 223.09L60.9333 223.032L60.7538 222.928L60.5728 222.863L60.4663 222.855L60.3902 222.741L60.3476 222.574L60.2746 222.489L60.1301 222.367L59.9825 222.271L59.5231 222.062L59.3724 222.035L59.2188 222.057L59.0545 222.152L58.8947 222.292L58.732 222.398L58.5631 222.42L58.4018 222.359L58.2497 222.222L58.1736 222.125L58.1326 221.955L58.1341 221.786L58.1554 221.623L58.2375 221.226L58.3805 221.148L58.6407 221.431ZM92.3412 230.096L92.1602 230.121L92.0765 230.084L92.0643 230.043L92.0993 229.895L92.0963 229.833L92.1876 229.81L92.2925 229.88L92.323 229.953L92.3412 230.096ZM56.809 231.175L57.1178 231.365L57.3156 231.346L57.4738 231.504L57.5392 231.634L57.3034 231.541L56.9611 231.547L56.4986 231.158L56.3328 231.07L56.3709 230.851L56.5488 230.739L56.6401 231.033L56.809 231.175ZM86.4841 231.452L86.4156 231.463L86.5084 231.32L86.5723 231.039L86.659 231.079L86.6758 231.131L86.5328 231.417L86.4841 231.452ZM92.7307 231.195V231.271L92.685 231.344L92.7276 231.478L92.6531 231.709L92.6242 231.855L92.5846 231.946L92.5451 231.982L92.5055 231.96L92.4979 231.91L92.5207 231.829L92.4264 231.832L92.3975 231.631L92.4492 231.567L92.4675 231.48L92.4736 231.422L92.5359 231.164L92.5588 231.146L92.5664 231.207L92.5862 231.225L92.6196 231.201L92.6683 231.086L92.6896 231.073L92.7307 231.195ZM94.5426 231.198L94.5745 231.277L94.8499 231.257L94.929 231.271L94.961 231.307L94.9229 231.361L94.8164 231.433L94.5061 231.558L94.2535 231.721L94.2201 231.705L94.1744 231.526L94.1273 231.452L94.0984 231.352V231.314L94.144 231.243L94.2368 231.141L94.3022 231.105L94.5426 231.198ZM96.3682 231.524L96.3225 231.594L96.1978 231.568L96.1309 231.524L96.3545 231.338L96.391 231.375L96.3682 231.524ZM66.2702 231.39L66.401 231.533L66.471 231.541L66.6916 231.497L66.7722 231.527L66.8513 231.59L66.9 231.684L66.9091 231.85L66.8726 231.998L66.8833 232.206L66.8756 232.296L66.9928 232.413L67.0293 232.572L67.0476 232.743L66.7935 232.799L66.5394 232.808L66.3204 232.924L66.2747 233.009L66.3097 233.136L66.2489 233.168L66.1926 233.141L66.0861 233.023L65.9689 232.967L65.5612 232.88L65.05 232.538L64.8295 232.468L64.6058 232.218L64.4035 231.899L64.5358 231.847L64.6682 231.821L65.263 231.869L65.3376 231.64L65.4136 231.582L65.6023 231.516L65.7788 231.388L65.8579 231.391L65.9385 231.44L66.1059 231.364L66.1941 231.347L66.2702 231.39ZM92.6196 233.029L92.4614 233.071L92.4234 232.987L92.507 232.776L92.574 232.657L92.6227 232.628L92.8052 232.39L93.0076 232.216L93.1932 231.962L93.3818 231.599L93.4168 231.463L93.5035 231.449L93.6465 231.539L93.7348 231.664L93.6937 231.763L93.219 232.279L93.1795 232.346L93.1369 232.52L93.0973 232.581L93.0349 232.608L92.9893 232.685L92.9604 232.81L92.9011 232.874L92.8128 232.88L92.752 232.913L92.7185 232.976L92.6196 233.029ZM92.2104 232.308L92.1358 232.396L91.8529 232.343L91.9122 232.169L92.1282 232.059L92.3656 232.23L92.2104 232.308ZM97.1608 233.014L97.0923 233.031L97.1958 232.843L97.3342 232.636L97.4651 232.506L97.6339 232.451L97.6157 232.546L97.3936 232.721L97.1608 233.014ZM73.7399 236.488L73.6349 236.533L73.5239 236.51L73.4356 236.237L73.5026 236.228L73.6441 236.048L73.9559 235.901L74.032 235.884L73.7399 236.488ZM85.8177 236.742L85.7752 236.76L85.6702 236.676L85.6017 236.587L85.6474 236.52L85.8497 236.377L85.9471 236.374L85.9866 236.397L86.0018 236.441L85.9942 236.508L85.9501 236.591L85.8177 236.742ZM85.9166 237.083L85.9684 237.106L86.0231 236.943L86.0612 236.938L86.23 237.076L86.3335 237.045L86.4004 237.214L86.4597 237.23L86.516 237.21L86.5495 237.222L86.5373 237.4L86.4141 237.58L86.3563 237.626L86.2757 237.58L86.2452 237.564L86.192 237.484L86.1524 237.384L86.1281 237.382L86.0338 237.501L86.0368 237.559L86.0764 237.647L86.0703 237.702L85.9668 237.728L85.8664 237.715L85.7432 237.791L85.7143 237.744L85.696 237.609L85.658 237.625L85.6002 237.789L85.5363 237.893L85.4207 237.98L85.3948 238.021L85.3096 238.027L85.1834 238.082L85.1058 238.073L84.6433 237.895L84.5353 237.829L84.9156 237.417L85.1149 237.259L85.2305 237.268L85.3461 237.318L85.407 237.31L85.4116 237.127L85.3035 236.99L85.3081 236.934L85.547 236.841L85.6367 236.854L85.7356 236.902L85.8284 236.979L85.9166 237.083ZM111.317 237.625L111.68 237.687L111.947 237.673L112.19 238.078L112.341 238.404L112.429 238.631L112.479 238.851L112.546 239.061L112.54 239.09L112.4 238.948L112.3 238.659L112.248 238.546L112.198 238.494L112.144 238.387L112.039 238.11L112.035 238.032L111.989 237.959L111.936 237.928L111.875 237.94L111.854 237.968L111.863 238.16L111.91 238.373L112.173 238.837L112.348 239.099L112.383 239.186L112.406 239.426L112.33 239.534L112.423 239.754L112.42 239.796L112.4 239.838L112.149 239.935L111.919 240.341L111.668 240.577L111.553 240.615L111.498 240.576L111.445 240.484L111.414 240.362L111.405 240.21L111.467 240.114L111.592 239.613L111.595 239.449L111.44 239.22L111.347 239.032L111.297 238.77L111.213 238.071L111.174 237.847L111.119 237.66L111.048 237.51L110.994 237.345L110.958 237.166L110.971 237.095L111.095 237.19L111.244 237.449L111.317 237.625ZM111.843 237.442L111.833 237.509L111.638 237.503L111.44 237.403L111.343 237.274L111.362 237.216L111.547 237.161L111.72 237.284L111.843 237.442ZM109.814 237.399L110.019 237.664L110.021 237.725L109.98 237.907L109.868 237.959L109.9 238.03L109.983 238.085L110.042 238.039L110.258 237.785L110.325 237.731L110.364 237.725L110.628 237.801L110.857 237.922L110.926 238.018L110.964 238.187L110.903 238.553L110.714 238.617L110.625 238.611L110.529 238.558L110.375 238.685L110.503 238.782L110.891 238.804L111.008 239.008L111.041 239.165L110.958 239.453L110.739 239.374L110.545 239.206L110.148 238.968L110.053 238.958L109.989 239L109.972 239.144L109.976 239.455L109.87 239.616L109.557 239.545L109.433 239.31L109.319 238.936L108.887 238.492L108.77 238.404L108.615 238.137L108.677 237.925L108.696 237.801L108.778 237.769L108.899 237.675L108.968 237.469L109.077 237.635L109.223 237.795L109.225 237.644L109.293 237.524L109.436 237.528L109.503 237.503L109.598 237.39L109.733 237.332L109.814 237.399ZM85.2275 238.537L85.2381 238.685L85.2959 238.666L85.5165 238.514L85.6321 238.469L85.7812 238.462L85.8999 238.532L85.9242 238.585L85.9136 238.649L85.8193 238.778L85.8238 238.861L85.9258 239.014L86.1768 239.098L86.2072 239.144L86.2057 239.199L86.0338 239.452L85.9699 239.511L85.9258 239.525L85.6124 239.479L85.3264 239.397L85.2107 239.383L85.1697 239.411L85.089 239.488L85.1468 239.511L85.3979 239.529L85.4861 239.642L85.5241 239.725L85.5439 239.816L85.4937 239.854L85.3857 239.882H85.2564L85.0966 239.985L85.0084 240.103L84.6889 240.133L84.447 240.291L84.3618 240.368L84.3314 240.46L84.2401 240.527L84.0332 240.594L84.1565 240.653L84.1762 240.704L84.1793 240.774L84.1625 240.835L83.9998 241.103L83.6909 241.323L83.6133 241.314L83.5799 241.286L83.5525 241.244L83.551 241.201L83.948 240.759L83.9328 240.737L83.8248 240.722L83.6529 240.6L83.5327 240.679L83.5053 240.676L83.5373 240.571L83.6164 240.446L83.6027 240.411L83.5586 240.38L83.4597 240.362L83.3045 240.356L83.1889 240.385L83.1143 240.451L83.1083 240.478L83.268 240.47L83.3121 240.504L83.3547 240.567L83.3806 240.638L83.3897 240.719L83.3562 240.829L83.2802 240.966L83.1691 240.942L82.9409 240.638L82.8405 240.191L82.6443 239.848L82.6351 239.766L82.6914 239.554L82.8892 239.252L83.1022 239.17L83.2528 239.041L83.3988 239.003L83.4886 239.006L83.6118 239.061L83.662 239.177L83.6316 239.232L83.6438 239.261L83.7305 239.331L83.8248 239.574L83.9343 239.789L84.0074 239.876L84.1032 239.929L84.0043 239.766L83.945 239.563L83.9161 239.156L83.8872 239.048L83.9419 239.019L84.0986 239.034L84.0941 238.973L83.9283 238.836L83.8263 238.721L83.7883 238.631L83.7913 238.553L83.8811 238.437L83.9328 238.404L83.9861 238.39L84.091 238.415L84.1382 238.451L84.2736 238.712L84.3375 238.793H84.3892L84.4379 238.75L84.482 238.663L84.5277 238.611L84.5748 238.595L84.7254 238.633L84.7756 238.619L84.8 238.553L84.7985 238.437L84.835 238.396L84.8441 238.311L84.7619 238.184L84.8563 238.146L85.1666 238.244L85.299 238.349L85.2275 238.537ZM84.7361 238.466L84.6965 238.541L84.6585 238.521L84.5779 238.434L84.4151 238.306L84.3405 238.218L84.336 238.18L84.3923 238.139L84.5839 238.242L84.6661 238.337L84.7361 238.466ZM110.903 239.801L111.025 240.092L111.113 240.318L111.191 240.588L111.321 241.145L111.382 241.355L111.402 241.469L111.417 241.768L111.397 241.832L111.358 241.892L111.35 241.977L111.387 242.205L111.39 242.549L111.355 242.743L111.315 242.772L111.218 242.708L111.137 242.603L111.078 242.494L110.932 242.15L110.888 241.988L110.885 241.872L110.908 241.788L110.955 241.736L111.038 241.596L111.026 241.573L110.962 241.605L110.833 241.623L110.719 241.512L110.631 241.453L110.649 241.251L110.625 241.195L110.45 241.257L110.384 241.201L110.371 241.125L110.374 241.012L110.407 240.913L110.573 240.661L110.556 240.615L110.475 240.605L110.369 240.518L110.32 240.236L110.206 240.074L110.139 240.089L109.986 240.545L109.91 240.644L109.694 240.708L109.738 240.582L109.757 240.469L109.681 240.126L109.678 239.993L109.73 239.896L109.882 239.854L109.963 239.796L110.025 239.702L110.04 239.61L110.159 239.366L110.214 239.319L110.36 239.322L110.669 239.592L110.763 239.632L110.903 239.801ZM60.5058 240.245L60.3583 240.37L60.2244 240.324L60.1848 240.234L60.1818 240.194L60.5697 240.092L60.5058 240.245ZM85.0708 240.4L84.8882 240.486L84.8563 240.483L84.7437 240.655L84.6585 240.73L84.5444 240.594L84.5733 240.384L84.6722 240.243L85.1727 240.291L85.2107 240.33L85.2123 240.364L85.1757 240.391L85.0708 240.4ZM113.199 240.721L113.295 240.803L113.346 240.716L113.444 240.721L113.623 240.797L113.73 240.913L113.79 241.044L113.795 241.122L113.777 241.3L113.79 241.482L113.783 241.576L113.759 241.654L113.717 241.715L113.673 241.723L113.533 241.559L113.374 241.265L113.252 241.175L113.247 241.206L113.281 241.289L113.38 241.448L113.398 241.543L113.468 241.659L113.5 241.747L113.518 241.861V241.962L113.498 242.047L113.466 242.102L113.421 242.127L113.177 242.102L113.031 242.16L112.861 242.128L112.82 242.076L112.794 241.991L112.782 241.785L112.739 241.489L112.75 241.261L112.64 241.053L112.546 240.928L112.411 240.815L112.322 240.704L112.347 240.615L112.485 240.548L112.712 240.564L113.199 240.721ZM112.306 241.137L112.398 241.318L112.532 241.303L112.608 241.44L112.665 241.645L112.624 241.776L112.564 241.747L112.497 241.823L112.456 242.075L112.475 242.327L112.455 242.577L112.377 242.83L112.36 242.999L112.33 243.049L112.297 243.066L112.254 243.021L112.192 242.984L112.112 243.127L112.017 243.129L111.937 242.804L112.009 242.261L112.169 242.15L112.074 242.002L111.874 241.829L111.89 241.733L111.738 241.454L111.729 241.387L111.753 241.154L111.895 240.945L112.082 240.908L112.213 240.998L112.286 241.074L112.306 241.137ZM114.086 241.97L114.07 242.008L113.888 242.005L113.822 241.974L113.798 241.863L113.815 241.759L113.857 241.68L113.909 241.526L113.949 241.268L114.216 241.556L114.299 241.684L114.343 241.84L114.248 241.898L114.133 241.927L114.086 241.97ZM61.0855 241.684L61.2741 241.736L61.3791 241.703L61.4719 241.73L61.4886 241.791L61.3274 241.925L61.2619 241.916L61.0702 241.755L61.0855 241.684ZM83.3501 241.997L83.2802 242.003L83.1737 241.935L83.1874 241.852L83.338 241.753L83.4901 241.768L83.5023 241.823L83.4947 241.886L83.4825 241.922L83.4338 241.959L83.3501 241.997ZM82.6716 242.203L82.5743 242.264L82.5423 242.243L82.5378 242.192L82.5606 242.112L82.6062 242.031L82.7568 241.877L82.909 241.774L82.9866 241.781L83.0124 241.846L82.9181 241.98L82.6716 242.203ZM114.995 243.045L114.966 243.47L114.91 243.446L114.857 243.445L114.746 243.506L114.63 243.48L114.575 243.432L114.556 243.377L114.577 243.251L114.513 243.181L114.296 243.155L114.213 243.124L114.168 242.992L114.157 242.816L114.191 242.751L114.3 242.705L114.385 242.491L114.432 242.462L114.614 242.038L114.705 242.067L114.863 242.325L115.062 242.696L114.995 243.045ZM114.038 242.69L113.965 242.697L113.879 242.658L113.673 242.447L113.67 242.385L113.699 242.314L113.816 242.185L113.863 242.154L114.143 242.168L114.233 242.203L114.253 242.264L114.248 242.325L114.219 242.388L114.213 242.452L114.229 242.519L114.197 242.586L114.038 242.69ZM112.913 242.453L113.183 242.508L113.431 242.502L113.517 242.609L113.573 242.722L113.605 242.827L113.614 242.926L113.608 242.996L113.577 243.071L113.584 243.095L114.069 243.339L114.299 243.595L114.39 243.73L114.443 243.843L114.539 244.125L114.741 244.451L114.848 244.55L114.909 244.646L114.875 244.649L114.732 244.578L114.423 244.358L114.397 244.367L114.37 244.486L114.323 244.59L114.251 244.665L114.308 244.687L114.557 244.64L114.766 244.854L114.846 244.892L114.925 245.044L114.928 245.102L114.883 245.215L114.848 245.261L114.86 245.291L114.918 245.308L115.148 245.276L115.189 245.331L115.154 245.769L115.186 245.929V246.002L115.158 246.098L115.157 246.181L115.178 246.264L115.181 246.339L115.123 246.534L115.061 246.566L114.962 246.568L114.883 246.513L114.772 246.345L114.664 246.085L114.623 246.048L114.481 246.008L114.455 245.978L114.366 245.972L114.302 245.863L114.309 245.722L114.254 245.577L114.262 245.511L114.2 245.484L114.148 245.525L114.175 245.667L114.145 245.776L114.032 245.731L113.845 245.38L113.634 245.098L113.55 245.031L113.573 244.948L113.678 244.904L113.763 244.907L113.78 244.858L113.603 244.584L113.609 244.506L113.673 244.367L113.596 244.312L113.375 244.357L113.298 244.328L113.234 244.216L113.196 244.119L113.004 244.1L112.931 244.113L112.806 243.966L112.75 243.873L112.773 243.826L112.888 243.742L112.955 243.754L113.085 243.843L113.135 243.84L113.263 243.722L113.282 243.615L113.378 243.527L113.363 243.434L113.31 243.275L113.193 243.231L112.952 243.326L112.744 243.47L112.66 243.414L112.642 243.326L112.866 243.085L112.963 242.95L112.945 242.871L112.873 242.769L112.867 242.511L112.913 242.453ZM116.617 244.625L116.567 244.903L116.468 245.186L116.317 245.339L116.211 245.305L116.133 245.183L116.06 245.189L115.983 245.163L115.94 245.061L115.981 244.93L115.945 244.828L115.907 244.916L115.838 244.999L115.668 245.105L115.549 245.308L115.493 245.439L115.423 245.296L115.379 244.954L115.373 244.81L115.497 244.59L115.657 244.381L115.689 243.756L116.199 243.44L116.246 243.457L116.412 243.693L116.588 244.023L116.634 244.17L116.635 244.428L116.617 244.625ZM81.4059 243.783L81.3496 243.864L81.2416 243.858L81.1807 243.832L81.161 243.762L81.3283 243.55L81.3663 243.521L81.3968 243.528L81.4105 243.617L81.4059 243.783ZM113.287 244.488L113.319 244.559L113.32 244.604L113.113 244.771L113.11 244.806L113.062 244.91L113.018 244.948L112.94 245.06L112.792 245.18L112.814 244.817L112.668 244.607L112.815 244.5L112.913 244.53L113.072 244.543L113.229 244.45L113.287 244.488ZM74.0761 245.066L74.0974 245.067L74.1415 245.047L74.2343 244.906L74.2648 244.899V244.944L74.2206 245.084L74.2952 245.272L74.3652 245.362L74.3576 245.394L74.1841 245.459L74.0518 245.412L73.9818 245.429L73.9179 245.494L73.8738 245.423L73.8433 245.078L73.8525 245.017L73.9255 244.896L74.0183 244.842L74.0594 244.857L74.0928 244.904L74.1005 244.954L74.0761 245.066ZM74.5858 245.008L74.566 245.206L74.3697 245.079L74.3165 245.017L74.3515 244.97L74.5386 244.957L74.5858 245.008ZM113.921 246.118L113.956 246.152L113.991 246.127L114.049 246.039L114.151 246.056L114.226 246.086L114.271 246.123L114.247 246.252L114.229 246.461L114.186 246.536L114.145 246.64L113.999 246.577L113.882 246.444L113.711 246.216L113.616 246.049L113.608 245.979L113.547 245.929L113.43 245.642L113.363 245.415L113.258 245.389L113.124 245.327L113.072 245.201L113.107 245.092L113.298 245.037L113.584 245.319L113.628 245.438L113.73 245.577L113.749 245.77L113.801 245.847L113.921 246.118ZM75.2384 245.532L75.1517 245.587L75.1243 245.657L75.0574 245.686L75.0011 245.743L74.814 245.999L74.7318 246.046L74.8231 245.827L74.8368 245.757L74.8383 245.711L74.8094 245.545L74.8642 245.552L74.9098 245.517L75.0011 245.371L75.0832 245.357L75.1715 245.182L75.2186 245.168L75.2415 245.192L75.2019 245.299L75.2856 245.397L75.2643 245.491L75.2384 245.532ZM116.101 245.656L116.247 245.981L116.255 246.095L116.115 246.135L116.006 246.118L115.949 246.08L115.934 246.027L115.969 245.862L115.898 245.764L115.814 245.731L115.739 245.787L115.735 245.624L115.791 245.506L115.759 245.348L115.758 245.227L115.776 245.189L115.852 245.192L116.007 245.316L116.101 245.656ZM75.7511 245.474L75.7435 245.674L75.7222 245.706L75.6842 245.653L75.6035 245.712L75.5594 245.67L75.5777 245.6L75.5716 245.545L75.6309 245.54L75.6446 245.441L75.634 245.4L75.6629 245.31L75.7055 245.288L75.7511 245.474ZM75.9702 245.924L75.923 245.937L75.885 245.909L75.8317 245.767L75.8272 245.708L75.9291 245.752L75.9686 245.856L75.9702 245.924ZM70.0781 245.903L70.2165 246.315L70.2773 246.396L70.3671 246.44L70.4919 246.484L70.5664 246.545L70.6318 246.637L70.6409 246.679L70.2469 246.515L69.9989 246.756L69.9244 246.788L69.2215 246.8L69.0816 246.844L68.9903 246.922L68.829 247.141L68.7484 247.227L68.6632 247.277L68.4807 247.334L68.2616 247.326L68.1475 247.297L68.0866 247.193L68.0319 246.987V246.929L68.0547 246.83L68.2494 246.695L68.3148 246.623L68.5674 246.153L68.6404 246.089L68.718 246.074L68.934 246.106L69.1181 245.969L69.5152 245.758L69.6019 245.734L69.8879 245.729L69.9655 245.761L70.0263 245.821L70.0781 245.903ZM71.7652 246.236L71.7317 246.248L71.6329 246.171L71.5963 246.115L71.5705 246.027L71.7713 245.898L71.8124 245.897L71.8504 245.969L71.8565 246.025L71.8002 246.187L71.7652 246.236ZM71.3986 247.338L71.2738 247.392L71.1415 247.335L71.0289 247.231L71.0167 247.108L71.2677 247.189L71.321 247.227L71.3986 247.338ZM67.0917 247.988L67.0293 248.006L67.0141 247.98L67.0065 247.872L66.9578 247.701L67.0491 247.639L67.1054 247.625L67.1297 247.651L67.1951 247.779L67.2605 247.813L67.3092 247.84L67.224 247.88L67.0917 247.988ZM66.6916 248.15L66.6368 248.192L66.5927 248.201L66.5592 248.177L66.4116 248.206L66.3827 248.189L66.3173 248.044L66.3128 247.97L66.3386 247.91L66.4056 247.857L66.5136 247.808L66.6185 247.817L66.8026 247.951L66.8893 248.031L66.9061 248.079L66.8422 248.125L66.6916 248.15ZM65.5825 248.563L65.6449 248.679L65.7514 248.606L65.8305 248.505L65.8913 248.375L65.9309 248.325L65.9841 248.394L66.1348 248.487L66.0085 248.63L65.7651 248.844L65.6829 248.987L65.6784 249.048L65.9142 249.001L65.9796 249.008L66.0222 249.057L65.9583 249.115L65.8305 249.167L65.7194 249.269L65.4608 249.444L65.3634 249.591L65.2478 249.647L65.0911 249.661L64.8142 249.756L64.6469 249.846L64.6043 249.894L64.5511 249.917L64.4887 249.914L64.4202 249.954L64.3472 250.035L64.2863 250.073L64.1859 250.082L64.1342 250.114L64.0764 250.112L63.9167 250.016L63.8771 249.96L64.0186 249.847L64.1205 249.809L64.2757 249.792L64.4278 249.687L64.7427 249.548L64.8401 249.472L64.9025 249.208L64.974 249.162L65.012 249.057L65.1854 249.06L65.2661 249.179L65.2935 249.196L65.3072 249.184L65.3148 249.089L65.4045 249.022L65.3528 248.973L65.1915 248.912L65.0729 248.883L64.9953 248.886L64.9314 248.851L64.8827 248.778L64.8599 248.706L64.8644 248.635L64.904 248.554L64.9785 248.465L65.0637 248.415L65.2493 248.378L65.4136 248.319L65.5004 248.31L65.5658 248.334L65.5825 248.563ZM66.1637 248.994L66.1439 249.002L66.1074 248.943L66.1059 248.888L66.1287 248.848L66.1956 248.755L66.2428 248.721L66.3006 248.705L66.3158 248.729L66.2641 248.839L66.2002 248.912L66.1637 248.994ZM63.6504 249.905L63.2123 250.161L63.0693 250.349L62.9613 250.529L62.8761 250.626L62.8137 250.643L62.7437 250.69L62.5992 250.816L62.5383 250.831L62.0728 251.122L62.0393 251.127L62.0622 251.05L62.2036 250.942L62.2964 250.843L62.4014 250.68L62.4592 250.62L62.4775 250.538L62.4851 250.372L62.5109 250.309L62.6114 250.184L62.6844 250.115L62.7802 250.093L62.975 250.114L63.0556 250.05L63.0799 250.001L63.0312 249.957L63.0191 249.881L63.0312 249.748L63.0875 249.63L63.1864 249.528L63.3218 249.449L63.4937 249.393L63.6185 249.389L63.8436 249.51L63.8771 249.565L63.8223 249.685L63.7904 249.798L63.6504 249.905ZM61.1767 251.093L61.1539 251.189L61.1326 251.224L60.912 251.174L60.7645 251.192L60.7477 251.136L60.7614 251.085L60.9927 251.009H61.087L61.1494 251.049L61.1767 251.093ZM59.6858 251.721L59.5946 251.796L59.5672 251.769L59.552 251.676L59.6037 251.604L59.7604 251.447L59.8669 251.476L59.9003 251.517L59.8973 251.577L59.8577 251.654L59.8075 251.692H59.7467L59.6858 251.721ZM54.0371 253.001L53.2689 253.097L53.1517 253.032L53.2689 252.993L53.4073 252.972L53.6964 252.862L54.0523 252.768L54.3292 252.653L54.5696 252.579L54.6381 252.455L54.4266 252.392L54.3855 252.342L54.4859 252.284L54.5696 252.2L54.7674 252.101L54.9438 252.225L54.9834 252.307L54.9667 252.406L54.9317 252.508L54.7765 252.562L54.7537 252.615L54.8374 252.768L54.5179 252.902L54.0371 253.001ZM57.2061 252.447L57.0996 252.482L56.9839 252.446L57.0372 252.322L57.092 252.257L57.1969 252.176L57.3217 252.211L57.4206 252.313L57.2061 252.447ZM55.6467 252.765L55.9281 252.859L56.2781 252.849L56.4058 252.871L56.4074 252.897L56.1837 252.935L56.1077 252.923L55.9129 252.975L55.7806 252.984L55.4778 252.935L55.2435 252.969L55.1812 252.957L55.1081 252.914L55.023 252.841L55.0184 252.795L55.0945 252.777L55.3014 252.839L55.3227 252.807L55.4976 252.748L55.6467 252.765ZM52.1126 253.077L52.0792 253.146L51.9392 253.073L51.889 253.013L51.8784 252.952L51.9194 252.852L52.032 252.85L52.0974 252.891L52.1598 252.967L52.1781 253.015L52.1126 253.077ZM51.2926 253.391L51.3003 253.469L51.4646 253.46L51.5163 253.5V253.652L51.495 253.695L51.4706 253.706L51.4113 253.672L51.3444 253.75L51.0386 253.939L50.9443 253.834L50.7663 254L50.891 253.568L51.0355 253.503L51.0888 253.454L51.0766 253.327L51.1436 253.115L51.2896 253.125L51.3565 253.213L51.3535 253.269L51.2926 253.391ZM50.4985 253.739L50.4574 253.77L50.3814 253.793L50.1623 253.767L50.0299 253.774L49.8824 253.791L49.7713 253.832L49.75 253.776L49.7531 253.73L50.2292 253.603L50.3403 253.536L50.4088 253.452L50.4711 253.294L50.5213 253.247L50.5518 253.25L50.6187 253.312L50.5944 253.395L50.5365 253.463L50.5168 253.53L50.4985 253.739ZM49.4518 253.895L49.4199 253.971L49.3849 253.969L49.1932 253.841L49.1658 253.799L49.2784 253.738L49.3104 253.69L49.2967 253.629L49.213 253.544L49.0578 253.434L49 253.356L49.038 253.308L49.1126 253.277L49.3453 253.271L49.4716 253.405L49.5659 253.452L49.788 253.485L49.6724 253.541L49.607 253.596L49.5264 253.808L49.4518 253.895ZM52.1294 253.518L52.0092 253.568L51.8495 253.466L51.8647 253.347L52.0396 253.446L52.1294 253.518ZM51.7323 253.565L51.6426 253.701L51.5756 253.64L51.5498 253.452L51.6 253.405L51.7414 253.539L51.7323 253.565Z",id:"AK"},{d:"M321.368 154.225L321.553 155.303L321.739 156.381L321.925 157.458L322.111 158.529L322.297 159.6L322.482 160.67L322.668 161.741L322.854 162.811L323.04 163.875L323.226 164.938L323.411 166.001L323.597 167.064L323.783 168.12L323.969 169.176L324.155 170.232L324.34 171.287L324.511 171.767L324.653 172.543L325.641 174.824L325.931 175.784L325.849 176.182L325.975 176.522L326.302 176.803L326.243 177.128L325.797 177.497L325.507 177.94L325.299 178.73L324.883 180.118L324.876 180.959L325.277 182.111L325.359 182.621L325.091 184.865L325.269 186.305L325.693 187.243L323.434 187.25H321.174H318.915H316.656H314.396H312.137H309.878H307.618L307.522 187.826L307.566 188.38L307.812 188.904L308.822 189.901L308.919 190.144L308.741 190.912L308.77 191.458L308.659 191.739L308.414 191.99L308.347 192.263L308.183 192.337L307.418 193.164L304.735 193.437L304.883 193.253L305.448 193.216L306.243 192.95L306.08 192.507L305.775 192.02L305.493 191.968L305.307 191.68L305.314 190.779L305.136 190.255L304.698 189.716L304.549 189.819L304.229 190.742L303.962 191.953L303.828 192.344L303.033 192.374L302.327 192.293L301.977 192.315L301.888 190.661L301.814 189.155L301.74 187.641L301.665 186.128L301.591 184.607L301.517 183.086L301.442 181.558L301.368 180.029L301.539 178.523L301.71 177.017L301.881 175.503L302.052 173.99L302.223 172.469L302.394 170.948L302.565 169.419L302.736 167.891L302.906 166.363L303.077 164.827L303.248 163.291L303.419 161.748L303.59 160.205L303.761 158.655L303.932 157.104L304.103 155.546L304.148 155.148L304.155 155.015L304.177 154.815L303.56 154.262L303.442 154.151L303.352 154.047L303.442 154.04L304.564 154.055L305.686 154.07L306.808 154.084L307.93 154.099L309.053 154.114L310.175 154.129L311.297 154.143L312.419 154.158L313.542 154.173L314.664 154.188L315.786 154.202L316.908 154.217L318.031 154.232L319.153 154.247L320.275 154.262L321.368 154.225ZM304.244 193.245L303.627 193.415L302.713 193.4L302.527 193.341L302.892 193.223L303.977 193.068L304.244 193.245Z",id:"AL"},{d:"M292.814 145.719L292.784 145.874L292.925 146.214V146.406L292.821 146.524L292.583 146.598L292.405 146.679L292.368 146.827L292.36 146.893L292.375 147.055L292.405 147.196L292.294 147.388L291.483 147.86L291.142 148.466L291.26 149.211L290.978 149.965L290.287 150.725L289.997 151.567L290.101 152.504L289.752 153.265L288.957 153.841L288.696 154.195V154.217V154.483L288.778 154.69L288.511 155.081L287.842 155.48L287.478 155.871L287.426 156.255L287.269 156.44L286.98 156.521L286.809 157.082L286.66 158.411L286.303 159.164L285.724 159.349L285.419 159.644L285.374 160.05L285.032 160.515L284.386 161.047L284.17 161.549L284.393 162.029L284.349 162.221L284.148 162.376L283.449 162.605L283.331 162.715L283.264 162.841L283.405 163.085L283.487 163.446L283.383 164.059L283.212 164.318L283.048 164.561L282.468 164.997L282.305 165.329L282.565 165.558L282.543 165.816L282.253 166.09L282.335 166.392L282.402 166.599L282.676 166.784L282.766 167.293L282.572 167.95L282.61 168.489L282.937 168.932L283.004 169.124L282.684 170.586L282.706 170.793H281.331L280.075 170.8H278.819H277.563H276.3L275.044 170.807H273.788H272.532H271.276L270.02 170.815H268.764H267.5H266.244L264.988 170.822H263.732H262.476L262.469 169.7L262.454 168.578L262.447 167.455L262.432 166.333L262.075 166.141L261.428 166.045L261.094 166.112L260.7 166.06L260.44 166.245L260.262 166.282L260.12 166.237L260.039 166.075L259.741 165.957L259.377 165.551L259.399 164.65L259.414 163.742L259.437 162.841L259.459 161.933L259.474 161.025L259.496 160.117L259.518 159.201L259.533 158.293L259.555 157.377L259.578 156.462L259.593 155.546L259.615 154.631L259.637 153.715L259.652 152.792L259.674 151.869L259.689 150.954L259.533 149.765L259.377 148.584L259.221 147.395L259.065 146.206L258.909 145.018L258.753 143.822L258.597 142.633L258.441 141.429H260.388H262.335H264.282H266.229H268.184H270.131H272.078H274.026H275.973H277.92H279.875H281.822H283.769H285.716H287.663H289.618L289.923 142.109L290.227 142.544L290.279 142.862L290.22 143.187L289.707 143.881L289.239 144.206L288.979 144.553L288.63 144.877L288.08 145.793L289.232 145.771L290.384 145.756L291.535 145.734L292.814 145.719Z",id:"AR"},{d:"M157.499 137.11V140.182L157.491 143.231V146.265V149.285V152.298V155.295V158.278V161.246V164.207V167.153V170.084V173.008V175.917V178.818V181.705V184.585H155.901L153.426 184.592L150.951 184.599L148.484 184.607H146.009L143.534 184.614L140.219 183.418L136.897 182.215L133.583 181.011L130.268 179.808L126.946 178.597L123.631 177.386L120.309 176.175L116.994 174.964L117.329 174.499L117.767 173.266L117.797 173.192L118.771 173.104L119.231 172.794L119.499 172.225L119.558 171.642L119.41 171.058L118.986 170.615L118.31 170.328L117.916 169.523L117.812 168.186L117.931 167.463L118.288 167.359L118.629 167.035L118.949 166.488L119.194 165.89L119.35 165.24L119.38 164.421L119.283 163.424L119.915 162.199L120.539 161.438L121.699 160.508L121.966 160.227V159.998V159.976L121.729 159.651L120.688 159.002L120.242 158.536L120.205 158.108L120.19 158.101L120.056 157.687L118.942 155.96L118.57 155.015V154.306V154.247L118.704 151.242L118.302 150.201L118.206 149.61L118.325 148.887L118.295 148.429L118.102 148.037L118.057 147.321L118.035 146.435L117.715 145.867L117.656 145.616L117.834 145.003L118.161 144.685L118.696 144.464L119.306 144.39L119.997 144.457L120.525 144.737L120.874 145.217L121.216 145.461L121.558 145.468L122.004 145.077L122.405 144.228L122.539 144.176L122.554 140.47L122.561 137.088H124.746H126.924H129.109L131.294 137.095H133.479H135.664H137.841L140.026 137.103H142.211H144.396H146.581H148.759L150.944 137.11H153.129H155.314H157.499Z",id:"AZ"},{d:"M80.8599 92.2273V93.9697V95.7122V97.4473V99.1749V100.903V102.623V104.336V106.049V107.754V109.452V111.151V112.841V114.525V116.208V117.884V119.56L82.5023 121.015L84.1448 122.469L85.7799 123.916L87.4224 125.363L89.0574 126.803L90.6999 128.243L92.3424 129.675L93.9774 131.108L95.2632 132.311L96.5489 133.515L97.8346 134.718L99.1204 135.914L100.406 137.11L101.692 138.306L102.978 139.495L104.263 140.684L106.04 142.389L107.816 144.087L109.592 145.786L111.368 147.476L113.145 149.167L114.921 150.85L116.697 152.534L118.6 154.321V155.029L118.971 155.982L120.086 157.702L120.22 158.116L120.235 158.123L120.279 158.551L120.718 159.016L121.758 159.666L121.996 159.984V160.013L121.989 160.242L121.721 160.523L120.562 161.453L119.937 162.213L119.306 163.439L119.402 164.436L119.373 165.255L119.217 165.905L118.979 166.503L118.652 167.049L118.31 167.374L117.953 167.478L117.827 168.201L117.931 169.53L118.325 170.342L119.008 170.63L119.425 171.066L119.581 171.657L119.521 172.232L119.246 172.801L118.785 173.111L117.812 173.192L117.782 173.266L116.98 173.355L114.98 173.532L112.981 173.709L110.982 173.886L108.983 174.063L106.983 174.241L104.984 174.418L102.985 174.595L100.986 174.772L100.971 174.721L100.926 173.82L100.599 173.502L100.183 173.702L99.9899 172.535L100.094 171.981L100.042 171.442L99.648 170.113L98.6076 168.496L96.3631 166.481L95.2186 165.809L94.3193 164.953L93.747 164.716L93.0336 164.65L92.8254 165.034L92.0154 164.768L92.1343 163.815L91.339 162.486L90.6925 162.339L89.0648 162.427L86.8873 161.696L86.2407 161.261L86.0177 160.478L84.9921 159.799L83.6469 159.135L82.8963 159.29L81.9152 159.186L80.518 158.706L79.7005 158.647L78.11 158.787L77.5155 158.684L76.9655 158.079L76.3709 157.776L76.4973 157.03L76.423 156.351L76.5121 155.827L76.2446 154.668L76.4527 153.59L76.2744 153.198L75.9399 152.903L74.8845 152.46L74.6913 151.906L74.8622 151.138L74.5873 150.629L73.7251 150.156L72.9225 149.078L71.9043 148.488L71.4881 147.498L70.8564 146.886L70.6409 146.339L69.2436 144.397L67.7498 142.877L67.5194 141.998L67.4599 140.794L68.0471 140.063L68.3592 139.414L68.3295 138.823L68.2403 138.387L67.7275 137.627L65.7431 137.177L64.1304 135.301L64.0338 133.862L63.4021 132.385L63.3946 131.425L63.298 130.384L63.7811 130.155L64.2121 130.236L64.1676 130.65L64.3088 131.396L64.8141 131.957L65.2972 132.2L65.7357 132.747L66.0627 132.909L66.4046 132.946L66.2188 132.599L66.0256 132.378L65.7877 131.654L65.3418 130.731L64.829 130.222L64.5689 129.291L64.3459 129.077L64.2047 128.73L64.7027 128.317L65.3864 128.021L66.3005 127.94L68.8869 128.073L69.4369 127.837L69.8902 127.918L70.2247 127.888L69.5261 127.645L69.1321 127.726L68.6639 127.674L67.7424 127.726L67.3708 127.623L66.9546 127.327L66.687 127.298L65.8323 127.807L65.4533 127.748L64.554 127.194L64.1601 127.113L63.5284 127.431L63.4541 128.797L63.6473 129.808L63.2683 129.911L62.8298 129.491L62.1535 129.24L61.5961 128.863L60.8083 128.154L60.3921 127.896L59.9239 128.487L59.909 128.213L60.1394 127.534L60.0725 126.39L60.7786 127.305L60.563 126.663L60.0131 125.954L59.5969 125.71L59.0692 124.441L57.8875 123.673L56.9436 122.432L55.0113 120.372L54.885 118.556L54.1789 116.252L54.4762 114.938L54.4391 114.008L54.0897 112.598L53.7256 111.83L52.1574 109.718L50.6487 108.293L50.4183 107.215L50.3143 106.123L50.6413 105.148L50.9237 104.122L51.1318 103.849L51.2135 103.959L51.1541 104.181L51.3696 104.247L51.4514 103.797L51.5777 103.561L51.3547 103.531L51.377 103.391L51.5108 103.103L51.979 101.752L51.9344 100.046L52.4324 97.9419L52.4101 97.2479L52.0905 95.7491L51.7709 94.8483L51.1987 94.206L51.4514 93.2683L51.4291 92.375L51.3102 92.2273H53.2202H55.0633H56.9065H58.7496H60.5928H62.4359H64.2791H66.1222H67.9653H69.8085H71.6516H73.4947H75.3379H77.181H79.0242H80.8599ZM81.6848 161.962L83.1118 162.391L83.8773 162.184L84.0185 162.391L83.9293 162.568L82.1977 162.893L81.67 162.664L81.6254 162.354L81.447 162.058L81.6848 161.962ZM78.7195 162.42L78.3479 162.442L77.7756 162.354L77.9763 162.162L78.2958 162.021L78.3999 162.125L78.7195 162.42ZM80.5626 163.299L80.0721 163.417L79.7005 163.306L79.106 162.509L80.3694 162.405L80.9119 162.752L80.9862 162.848L80.5626 163.299ZM92.4241 167.729L92.7808 168.341L92.2755 168.268L91.7404 168.305L91.5769 167.972L91.4208 167.507L91.3168 167.389L90.9526 167.345L90.9228 167.3L90.8783 167.079L90.9823 166.968L92.1268 167.485L92.4241 167.729ZM84.7989 169.124L84.4867 169.139L84.0557 169.065L83.8327 168.622L84.182 168.592L84.509 168.652L84.7692 168.999L84.7989 169.124ZM92.4018 172.343L91.9931 172.417L91.5397 172.247L91.1532 171.45L90.7222 170.83L90.9526 170.652L91.3019 171.25L92.1714 172.159L92.4018 172.343Z",id:"CA"},{d:"M206.625 110.567L206.632 112.266V113.949L206.639 115.632L206.647 117.316V118.984L206.654 120.653L206.662 122.322V123.983L206.669 125.637L206.677 127.291L206.684 128.937V130.583L206.691 132.223L206.699 133.854V135.486L206.706 137.11H204.975H203.25H201.519H199.795H197.149H194.503H191.865H189.219H186.573H183.935H181.289H178.643H176.005H173.359H170.713H168.067H165.429H162.783H160.137H157.499V134.947V132.769V130.583V128.391V126.19V123.983V121.768V119.545V117.316V115.079V112.827V110.575V108.308V106.034V103.76V101.471H159.691H161.891H164.091H166.284H168.483H170.683H172.876H175.076H177.276H179.468H181.668H183.86H186.06H188.26H190.452H192.652H194.399H196.145H197.892H199.638H201.385H203.132H204.871H206.617L206.625 102.616V103.76V104.897V106.034V107.171V108.308V109.438V110.567Z",id:"CO"},{d:"M418.073 92.1165L418.081 92.6186V93.32L418.088 93.8294L418.095 94.5235V95.3209L418.103 96.0518L418.11 96.6868L418.088 97.0633L418.051 97.6392L417.872 97.8607L417.783 98.3923L417.174 98.3406L416.163 98.4735L414.825 98.791L414.082 98.6064L413.324 98.9387L410.753 99.0346L410.21 98.8575L409.519 99.485L408.412 99.8616L405.602 101.272L405.275 101.552L404.911 100.976L404.629 100.519L405.193 100.157L405.625 99.8837L406.033 99.6327L406.301 99.4629L406.085 99.1085L405.877 98.7541L405.929 97.8755L405.989 97.0042L406.041 96.1256L406.1 95.247L406.152 94.3611L406.212 93.4825L406.264 92.5965L406.323 91.7104L406.91 91.74L407.497 91.7621L408.085 91.7843L408.679 91.8138L409.266 91.836L409.853 91.8655L410.44 91.8876L411.028 91.9098L411.035 92.1534L411.34 92.1239L411.377 91.9098L412.217 91.9245L413.049 91.9393L413.889 91.9541L414.721 91.9688L415.561 91.9762L416.394 91.991L417.233 92.0058L418.066 92.0205L418.073 92.1165Z",id:"CT"},{d:"M381.485 120.535L381.329 120.306L380.987 120.121L380.846 120.055L381.404 119.449L381.775 119.974L382.184 120.55L381.56 121.273L381.485 120.535Z",id:"DC"},{d:"M392.745 112.243L392.44 112.561L392.18 113.129L391.578 113.816L391.623 114.281L391.727 114.606L391.675 115.293L392.054 115.957L392.804 117.042L392.946 118.726L393.518 119.848L394.395 121.162L395.071 121.532L395.101 122.019L394.796 122.816L394.38 123.185L394.915 123.112L395.183 123.296L395.443 123.961L395.428 124.381L394.677 124.389H393.131H391.578H390.872H390.857H390.842H390.827H390.813H390.79H390.775H390.761H390.746L390.679 122.986L390.612 121.583L390.545 120.173L390.471 118.763L390.404 117.345L390.337 115.928L390.27 114.51L390.203 113.085L390.731 112.361L390.954 112.14L391.251 112.029L392.121 111.992L392.745 112.243Z",id:"DE"},{d:"M350.189 189.399L350.516 190.13L351.014 193.105L351.356 194.139L351.973 196.915L352.983 199.595L354.418 202.821L356.766 206.712L357.049 207.266L356.744 207.731L356.647 208.219L356.618 208.949L356.699 209.658L356.974 210.529L357.51 211.858L357.212 211.593L356.439 209.688L356.35 208.566L356.462 206.971L356.283 207.008L356.135 207.524L356.053 208.13L355.86 208.366L355.592 207.436L355.614 207.015L355.897 206.528L355.815 206.351L355.354 206.1L355.258 205.701L355.317 205.31L355.057 205.103L354.849 205.11L354.99 206.07L355.206 206.661L355.473 208.071L355.912 208.927L356.164 209.643L359.13 217.248L359.828 218.216L360.088 218.909L360.356 220.357L360.415 222.21L359.932 225.584L359.821 227.873L359.754 227.806L359.709 227.563L359.598 227.533L359.174 228.582L358.602 229.527L358.416 230.996L358.141 231.727L357.316 232.502L356.803 232.48L355.555 233.063L354.678 232.908L353.63 233.233L352.939 233.196L352.537 232.502L352.597 232.192L352.753 231.882L353.021 231.808L353.95 232.532L354.12 232.229L353.838 231.867L353.303 231.668L352.909 231.446L352.114 229.792L351.289 228.655L351.148 227.895L349.728 227.43L348.695 226.728L348.026 225.473L347.64 223.244L347.186 222.992L346.993 222.815L347.439 221.988L347.907 221.294L347.536 221.464L347.261 221.723L346.911 222.335L346.659 222.431L346.428 222.335L346.161 221.161L346.235 219.714L346.614 219.168L346.034 219.153L345.44 219.36L345.529 219.847L345.447 220.113L345.009 220.047L344.682 219.877L344.236 219.375L343.626 218.415L342.37 215.764L342.125 215.388L341.709 214.996L341.902 214.871L342.259 214.797L343.062 213.601L343.693 212.877L343.901 212.375L343.864 212.161L343.582 211.851L343.218 212.124L343.062 212.043L342.645 211.415L342.252 211.238L341.977 211.379L342.266 211.895L342.527 212.087L342.423 212.84L342.318 213.084L342.073 213.298L341.694 213.18L341.501 213.365L341.271 213.173L341.048 212.84L340.795 212.294L341.456 209.23L342.073 207.273L342.14 205.036L342.185 204.704L342.133 204.106L341.308 202.807L337.659 199.632L334.834 195.859L332.389 194.441L330.531 194.751L330.212 195.039L330.07 195.416L330.189 195.837L330.018 196.014L329.521 195.992L328.852 196.088L327.098 197.085L326.481 197.048L325.916 197.306L325.492 197.498L324.392 197.601L323.463 197.823L323.062 197.705L322.802 197.129V196.531L323.017 196.989L323.345 197.343L323.493 197.203L323.553 196.885L323.226 196.265L322.17 195.468L320.974 194.301L321.338 194.338L321.427 194.087L321.055 193.762L321.211 193.386L321.472 192.987L320.966 193.046L320.513 193.326L320.498 193.673L320.409 193.947L320.164 193.91L319.71 193.57L317.473 192.625L315.519 192.093L317.02 191.85L317.83 192.034L317.733 191.746L317.54 191.562L316.901 191.333L316.083 191.422L315.571 191.311L315.043 191.54L314.463 191.879L313.95 192.057L311.936 192.3L310.301 192.566L310.561 192.285L310.844 192.108L311.81 191.835L311.951 191.267L311.721 190.72L311.468 190.853L311.201 191.281L310.874 190.971H310.509L310.413 191.658L309.945 192.116L309.736 192.573L308.376 192.935L308.198 192.817L308.599 192.381L308.57 192.138L308.28 192.271L308.347 191.997L308.592 191.746L308.703 191.466L308.674 190.92L308.852 190.152L308.755 189.908L307.745 188.911L307.499 188.387L307.455 187.833L307.551 187.257H309.811H312.07H314.329H316.589H318.848H321.107H323.367L325.626 187.25L325.916 187.885L326.473 189.199L326.496 189.509L327.15 189.554L328.265 189.627L329.379 189.701L330.494 189.775L331.609 189.849L332.724 189.923L333.839 189.997L334.953 190.07L336.068 190.144L337.183 190.218L338.298 190.292L339.413 190.366L340.527 190.44L341.642 190.513L342.757 190.587L343.872 190.661L344.987 190.735L344.994 191.001L345.18 191.414L345.224 191.887L345.306 192.116L345.529 192.256L345.878 192.293L346.235 192.027L346.458 191.444L346.518 190.787L346.384 190.034L346.406 189.399L346.584 189.029L346.793 188.941L346.971 188.741L347.12 188.697L347.506 188.801L348.955 189.332L350.189 189.399ZM326.377 198.111L325.671 198.399L324.913 198.192L325.381 198.155L325.723 198.236L326.585 197.823L327.038 197.513L327.566 197.395L326.377 198.111ZM359.405 216.702L359.516 217.278L358.87 215.949L358.074 213.859L357.651 212.242L357.941 212.678L358.223 213.586L359.405 216.702ZM346.131 222.335L346.124 222.786L345.774 222.025L345.537 221.184L345.871 221.457L346.131 222.335ZM346.458 223.096L346.205 223.295L345.7 223.148L345.425 222.882L345.306 222.365L345.745 222.911L345.901 223.037L346.458 223.096ZM358.037 233.167L356.647 234.599L356.803 234.237L357.346 233.469L357.524 233.108L357.889 232.879L358.23 232.465L358.253 231.978L358.751 231.638L358.914 231.587L358.037 233.167ZM356.246 234.99L356.06 235.027L356.335 234.702L356.41 234.724L356.246 234.99ZM354.908 235.751H354.775L354.841 235.64L355.116 235.426L355.213 235.507L355.198 235.618L354.908 235.751ZM353.407 236.408L353.087 236.585L352.753 236.452L353.117 236.275L354.202 236.083L353.793 236.327L353.407 236.408ZM351.371 236.91L351.163 237.065L351.066 237.013V236.784L350.769 236.282L350.776 236.149L351.46 236.644L351.475 236.777L351.371 236.91ZM349.75 237.301L349.297 237.375L349.661 237.072L349.78 236.615L349.996 236.969L349.988 237.183L349.75 237.301ZM348.234 237.722L348.056 237.737L348.041 237.619L348.346 237.478L348.546 237.486L348.539 237.641L348.234 237.722Z",id:"FL"},{d:"M354.611 178.885L354.254 179.571L353.4 180L353.14 179.985L352.924 180.11L353.05 180.421L353.266 180.642L353.259 180.849L353.036 181.129L352.59 181.211L352.337 181.535L352.419 181.838L352.567 182.008L352.538 182.296L352.032 182.591L351.913 182.879L352.166 182.96L352.359 182.879L352.5 182.938L352.196 183.418L351.921 183.713L351.661 184.238L351.059 184.385L351.081 184.555L351.423 184.703L351.705 185.109L351.17 185.855L350.836 185.796L350.635 185.633L350.509 186.224L350.561 186.534L350.434 187.176L350.226 187.944L350.085 188.262L350.115 188.845L350.204 189.413L349.022 189.34L347.573 188.808L347.187 188.705L347.038 188.749L346.86 188.948L346.651 189.037L346.473 189.406L346.451 190.041L346.585 190.794L346.525 191.451L346.302 192.034L345.945 192.3L345.596 192.263L345.373 192.123L345.291 191.894L345.247 191.422L345.061 191.008L345.054 190.742L343.939 190.668L342.824 190.595L341.709 190.521L340.594 190.447L339.48 190.373L338.365 190.299L337.25 190.226L336.135 190.152L335.02 190.078L333.905 190.004L332.791 189.93L331.676 189.856L330.561 189.783L329.446 189.709L328.331 189.635L327.217 189.561L326.563 189.517L326.54 189.207L325.983 187.892L325.693 187.257L325.269 186.32L325.091 184.88L325.359 182.636L325.277 182.126L324.876 180.974L324.883 180.133L325.299 178.745L325.507 177.955L325.797 177.512L326.243 177.142L326.303 176.818L325.976 176.537L325.849 176.197L325.931 175.799L325.641 174.839L324.653 172.557L324.511 171.782L324.34 171.302L324.155 170.246L323.969 169.191L323.783 168.135L323.597 167.079L323.411 166.016L323.226 164.953L323.04 163.889L322.854 162.826L322.668 161.756L322.482 160.685L322.297 159.614L322.111 158.544L321.925 157.473L321.739 156.395L321.553 155.317L321.368 154.239L323.642 154.269L325.916 154.299L328.19 154.328L330.464 154.358L332.583 154.328L334.701 154.299L336.819 154.269L338.937 154.239L338.892 154.247L338.551 154.815L337.525 155.886L337.25 156.705L338.573 157.621L338.58 157.628L339.368 158.367L339.911 158.655L340.461 158.743L340.802 158.987L341.003 159.578L342.608 162.494L344.273 163.993L344.942 164.731L345.276 165.44L346.696 166.606L347.179 167.234L347.201 167.707L347.372 168.046L347.684 168.245L347.982 168.674L348.272 169.323L348.836 169.892L349.684 170.372L350.301 171.472L350.694 173.178L351.096 174.167L351.705 174.58L352.538 176.035L352.805 176.899L352.79 177.659L353.214 178.25L354.611 178.885ZM350.784 187.464L350.472 189.428L350.338 188.734L350.323 188.062L350.561 187.664L350.784 187.464Z",id:"GA"},{d:"M-39.8044 161.237L-40 161.28L-39.9783 161.14L-39.7935 161L-39.6197 161.043L-39.6958 161.162L-39.8044 161.237ZM144.298 231.064L143.396 231.678L142.875 231.42L141.886 231.323L141.505 230.86L140.462 230.45L140.039 229.88L140.68 228.813L142.19 227.909L144.515 227.952L145.004 228.663L145.048 229.19L144.743 229.783L144.602 230.623L144.298 231.064ZM136.04 232.055L135.833 232.54L135.486 232.465L135.399 232.034L135.627 231.441L136.214 230.935L136.866 230.16L137.398 230.278L137.116 230.784L137.083 231.334L136.333 231.646L136.04 232.055ZM160.391 236.224L160.738 236.288L161.195 236.213L161.347 237.075L161.868 237.548L162.064 237.829L161.499 238.13L160.391 238.249L159.869 238.012L159.337 237.473L158.761 237.624L158.663 237.193L158.554 237.064L158.152 237.182L158.522 237.742L157.522 237.785L157.207 237.721L156.924 237.085L155.892 235.868V235.394L155.544 234.834L157.076 234.673L158.13 233.682L158.717 233.574L159.847 235.179L159.815 235.631L160.065 236.073L160.391 236.224ZM166.378 238.83L168.54 239.132L169.051 239.003L169.409 239.239L171.202 239.39L171.506 239.476L171.137 240.037L169.996 240.543L168.344 240.09L165.584 239.929L165.693 239.498L165.954 239.196L165.997 238.669L166.378 238.83ZM173.821 241.889L174.082 242.083L175.168 241.792L175.951 241.684L177.276 242.395L177.733 242.88L178.602 243.397L178.895 243.774L178.656 244.226L177.7 244.98L176.396 245.153L175.625 245.476L174.614 245.411L174.31 245.271L174.201 244.323L173.886 243.3L173.234 243.419L172.506 243.074L171.745 242.212L171.659 241.695L172.082 240.877L172.81 240.769L173.354 241.221L173.821 241.889ZM170.105 243.612L169.496 243.914L168.833 243.774L168.681 243.042L168.051 242.105L169.159 241.911L169.79 242.18L170.116 242.471L170.518 242.977L170.105 243.612ZM183.079 262.483L182.622 263L182.057 262.957L180.004 261.858L179.754 261.266L179.906 258.53L179.134 256.3L178.287 254.599L178.906 253.726L179.721 253.048L180.623 251.766L179.884 250.118L180.069 249.127L180.503 248.955L182.644 250.161L186.969 251.971L188.121 253.242L188.327 254.609L189.109 254.782L189.479 255.719L190.62 256.537L191 257.001L190.533 257.755L188.457 259.198L185.839 259.823L183.535 261.438L183.079 262.483Z",id:"HI"},{d:"M286.199 87.4282L286.623 88.0706L287.359 88.6464L287.775 89.1854L287.879 89.6875L288.325 90.2265L289.12 90.795L289.581 91.297L289.707 91.7326L289.685 92.4045L289.514 93.3127L289.224 93.9698L288.815 94.3685L288.518 94.9296L288.317 95.6532L287.693 96.3103L286.645 96.9231L285.471 97.3366L284.185 97.558L283.42 98.0823L283.182 98.9018L283.286 99.5811L283.747 100.135L284.007 100.718L284.074 101.331L283.754 102.35L283.041 103.767L282.245 104.683L281.383 105.096L280.997 105.709L281.094 106.521L281.019 106.979L280.662 107.142L280.046 106.662L279.934 106.322L279.436 105.982L279.362 105.768L278.983 105.576L278.634 104.912L276.872 104.927L275.103 104.934L273.342 104.949L271.573 104.963L269.812 104.978L268.043 104.986L266.281 105L264.52 105.015L262.751 105.03L260.99 105.045L259.221 105.052L257.46 105.067L255.691 105.082L253.929 105.096L252.161 105.111L250.414 105.119L249.99 104.439L249.76 103.812L249.901 103.509L249.931 102.49L249.849 100.74L249.678 99.7509L249.426 99.5294L249.396 99.2193L249.589 98.8354L249.53 98.5695L249.218 98.4293L249.121 98.0971L249.24 97.558L249.166 97.2332L248.898 97.1151L248.794 96.9305L248.839 96.6794L248.69 96.5244L248.363 96.4506L248.229 95.8451L248.289 94.7007L248.17 93.896L247.858 93.416L247.694 92.9731V92.5522L247.367 91.8951L246.706 90.9943L246.282 89.7982L246.089 88.3216L245.62 87.4946L245.405 87.4503L245.227 86.6751L245.041 86.3281L245.004 86.0623L244.424 85.3904L244.387 85.132L244.461 84.8072L244.84 84.1722L245.182 83.1311L245.256 82.4297L245.539 81.8981L245.546 81.6102L245.494 81.2262L245.345 80.8866L244.885 80.643L244.833 80.5322L244.788 80.1483L244.974 79.9047L245.033 79.6315L244.981 79.2918L244.706 78.7086L244.587 78.1105L245.598 78.0736H247.872H250.147H252.428H254.702L256.977 78.0662H259.251H261.525H263.799H266.073H268.348H270.629H272.903H275.178H277.452H279.726L282.037 78.0588L282.089 78.6569L282.223 79.0851L282.506 79.4321L282.937 79.6905L283.004 80.2L282.721 80.9457L282.624 81.8686L282.714 82.9687L282.929 83.9581L283.264 84.8367L284.037 85.479L285.233 85.8925L285.939 86.5127L286.147 87.3617L286.199 87.4282Z",id:"IA"},{d:"M143.467 68.4679V69.9815L143.475 71.4877V72.9939V74.5001V75.9988V77.4903V78.9817V80.4657V81.9497V83.4264V84.9031V86.3724V87.8416V89.3035V90.7654V92.2199H142.167H140.859H139.551H138.243H136.935H135.626H134.318H133.01H131.702H130.394H129.086H127.778H126.47H125.162H123.854H122.546H119.945H117.344H114.742H112.141H109.54L106.939 92.2273H104.338H101.736V90.1452L101.729 88.0483V85.9515L101.722 83.8473V81.7356V79.6093L101.714 77.4829V75.135L101.707 75.0833L102.153 73.6362L102.242 72.9274L102.13 72.5287L102.205 72.1448L102.472 71.7756L102.465 71.3622L102.182 70.9265L101.647 70.6312L100.874 70.4909L100.473 69.9667L100.443 69.0733L101.023 67.6927L102.212 65.8247L102.859 64.5031L102.978 63.7205L103.691 61.9189L105.007 59.0838L105.512 57.2601L105.207 56.4627L104.531 55.6949L103.498 54.9639L102.769 54.1075L102.576 53.6718L102.338 53.1329L102.22 52.4536L102.398 52.0623L102.249 51.3756L101.781 50.3937L101.58 49.7292L101.625 49.4929L101.677 49.3969L101.67 47.7874V46.163L101.662 44.5387L101.655 42.9144L101.647 41.2827L101.64 39.6436V37.9971L101.632 36.3507L101.625 34.6968L101.618 33.043V31.3743L101.61 29.7057L101.603 28.0297L101.595 26.3537V24.6703L101.58 22.9869H103.832H106.812H108.507V25.5859V28.1774V30.7542V33.3235L109.258 34.3646L109.815 34.9995L110.172 35.6862L110.714 36.4024L110.818 36.6608L111.012 37.4286L110.87 37.9824L111.16 38.5509L111.108 38.8241L110.893 38.9717L110.848 39.016L110.856 39.0751L110.93 39.1637L111.695 39.7027L112.446 40.4558L113.397 40.9726L113.702 41.2753L114.958 42.7667L115.612 43.7192L116.296 44.4132L116.638 45.2032L117.344 45.8899L117.522 46.2442L117.567 46.3181L117.663 46.3255L118.102 46.163L118.213 46.2073L118.429 46.4805L118.473 46.894L118.629 47.0712L118.904 47.1672L119.217 47.1967L120.175 46.9974H120.383L120.487 47.0786L120.532 47.3001L120.517 47.6618L120.421 48.1787L120.131 48.6881L120.183 49.1607L119.952 50.2534L119.737 50.9917L119.714 51.7005L119.447 52.114L119.596 52.6013L119.492 53.3396L119.588 53.5316L119.93 53.8712L120.064 54.7793L120.004 54.9491L119.395 55.3035L119.187 55.5324L119.105 55.8647L119.373 56.8171L119.112 57.3413L119.083 57.7917L119.142 57.9098L119.707 58.1535L120.391 58.6851L120.606 58.8032L120.762 58.7811L121.052 58.6039L121.372 58.2421L122.026 57.8729L122.799 57.0903L122.836 56.8688L122.895 56.7507H122.999L123.245 56.8614L123.728 57.3339L124.151 57.5997L124.226 57.6588L124.263 57.7917L124.241 58.2642L124.478 58.6334L124.545 59.2388L124.791 59.8516L124.961 60.5826L125.593 61.5276L125.935 62.1995L126.314 62.5096L126.545 62.864L126.708 63.2922L126.775 63.6393L126.552 64.2668L126.611 64.5252L126.812 64.8058L127.466 65.4555L127.592 65.5072L128.202 65.4408L128.529 65.5441L128.856 65.869L129.183 66.3563L129.398 66.851L129.458 67.4343L129.792 68.0766L129.837 68.6451L130.045 68.8961L130.461 69.2358L130.863 69.4425L131.019 69.4573L131.13 69.3687L131.167 69.0512L131.323 68.8149L131.821 68.4753L132.297 68.4827L134.088 68.7632L134.207 68.7485L134.289 68.6525L134.593 68.1357L134.839 67.9289L135.218 67.8625L136.318 67.9954L137.589 67.9216L138.25 68.0692L139.216 67.8773L140.331 68.0175L140.48 67.9363L140.509 67.8256L140.413 67.6336L140.398 67.2497L140.621 66.7919L140.695 66.4006L140.925 66.1791L141.223 66.061L141.468 66.0757L141.706 66.2825L141.973 66.6295L142.449 67.5745L142.702 67.9142L143.006 68.2095L143.467 68.4679Z",id:"ID"},{d:"M306.058 87.5832L306.05 89.0452L306.162 90.256L306.37 90.795L306.615 91.1937L306.875 91.4447L307.18 92.2273L307.522 93.5415L307.841 94.4054L308.094 94.7598L308.079 97.2332L308.072 99.9945L308.064 102.749L308.049 105.48L308.042 108.212L308.035 110.922L308.02 113.624L308.012 116.164V116.208L307.685 116.481L307.462 116.954L307.522 117.463L307.433 117.825L307.21 118.047L307.321 118.6L307.76 119.486L308.027 120.365L308.116 121.229L308.035 121.842L307.656 122.403L307.291 123.614L306.979 124.094L306.593 124.256L306.251 124.706L305.954 125.445L305.634 125.799L305.292 125.777L305.039 125.917L304.876 126.205L304.898 126.508L305.099 126.833L305.032 127.128L304.698 127.401L304.705 127.534L304.809 127.615L304.772 127.741L304.556 127.874L304.43 128.28L304.445 128.952L304.326 129.291L304.103 129.306L304.073 129.491L304.445 130.251L304.229 130.406L303.843 131.034L303.761 131.72L303.992 132.474L303.412 133.086L302.015 133.544L301.279 133.958L301.197 134.312L301.294 134.851L301.569 135.575L301.621 136.077L301.442 136.357L300.446 136.165L298.633 135.508L297.422 135.53L296.805 136.232L296.589 136.763L296.664 137.191L296.173 136.667L295.839 136.431L295.779 136.446L295.705 136.512L295.675 136.675L295.697 136.793L295.742 136.926L295.72 137.007L295.638 137.014L295.281 136.815L294.85 136.232L294.337 135.272L294.226 134.511L294.516 133.943V133.352L294.226 132.725L294.085 132.112V131.514L293.386 130.613L291.989 129.417L290.963 128.671L290.302 128.391L289.536 127.793L288.659 126.87L288.191 126.161L288.132 125.674L288.533 124.367L289.692 121.502L289.826 121.17L289.863 121.044L289.811 120.919L289.7 120.801L289.209 120.461L288.273 120.173L287.403 120.018L286.712 120.358L286.11 119.664L285.59 117.929L284.319 116.097L282.283 114.163L281.101 112.841L280.774 112.147L280.484 111.099L280.246 109.696L280.254 108.537L280.662 107.142L281.019 106.979L281.093 106.521L280.997 105.709L281.383 105.096L282.245 104.683L283.041 103.767L283.754 102.35L284.074 101.331L284.007 100.718L283.747 100.135L283.286 99.5811L283.182 98.9018L283.42 98.0823L284.185 97.5581L285.471 97.3366L286.645 96.9231L287.693 96.3103L288.317 95.6532L288.518 94.9296L288.815 94.3685L289.224 93.9698L289.514 93.3127L289.685 92.4045L289.707 91.7326L289.581 91.2971L289.12 90.795L288.325 90.2265L287.879 89.6875L287.775 89.1854L287.359 88.6464L286.623 88.0706L286.199 87.4282L289.41 87.4577L292.561 87.4799L295.712 87.502L298.863 87.5242L302.015 87.5537L305.166 87.5759L306.058 87.5832Z",id:"IL"},{d:"M327.157 95.0034L327.135 98.0158L327.105 101.013L327.083 103.989L327.061 106.957L327.038 109.91L327.016 112.841L326.986 115.765L326.979 118.733L326.867 118.814L326.704 119.198L326.882 119.59L326.875 119.907L326.681 120.151L326.748 120.328L327.075 120.446L327.202 120.727L327.127 121.162L326.421 121.598L325.076 122.1L324.779 122.24L324.541 122.307L324.43 122.277L324.251 122.181L324.006 121.982L323.582 121.886L322.891 121.952L322.616 122.366L322.757 123.134L322.52 123.724L321.91 124.13L321.472 124.669L321.211 125.341L320.788 125.747L320.216 125.888L319.747 126.508L319.391 127.601L319.004 128.272L318.588 128.538L318.008 128.472L317.28 128.073L316.864 127.674L316.752 127.254L316.537 126.958L316.336 126.825H316.202L316.195 126.884L316.254 127.003L316.18 127.128L315.727 127.172L315.533 127.342L315.6 127.645L315.496 127.852L315.236 127.977L315.095 128.265L315.08 128.715L314.894 129.129L314.545 129.498L314.025 129.373L313.348 128.752L312.657 128.605L311.951 128.944L311.431 129.395L311.082 129.963L310.755 130.103L310.272 129.668L309.134 129.07L308.54 128.944L308.109 129.085L307.812 129.018L307.708 128.856L307.626 128.789L307.544 128.87L307.537 129.395L307.433 129.72L307.239 129.86L307.091 129.749L306.987 129.395L306.741 129.277L306.355 129.402L305.961 129.35L305.619 129.136L305.493 129.158L305.396 129.262L305.426 129.668L305.352 129.993L305.173 130.207L304.921 130.259L304.586 130.148L304.445 130.251L304.073 129.491L304.103 129.306L304.326 129.291L304.445 128.952L304.43 128.28L304.556 127.874L304.772 127.741L304.809 127.615L304.705 127.534L304.698 127.401L305.032 127.128L305.099 126.833L304.898 126.508L304.876 126.205L305.039 125.917L305.292 125.777L305.634 125.799L305.954 125.445L306.251 124.706L306.593 124.256L306.979 124.093L307.291 123.614L307.655 122.403L308.035 121.842L308.116 121.229L308.027 120.365L307.76 119.486L307.321 118.6L307.21 118.047L307.433 117.825L307.522 117.463L307.462 116.954L307.685 116.481L308.012 116.208V116.164L308.02 113.624L308.035 110.922L308.042 108.212L308.049 105.48L308.064 102.748L308.072 99.9945L308.079 97.2331L308.094 94.7598L308.139 94.8262L308.399 95.0625L308.607 95.1954L308.763 95.2175L308.852 95.4242L309.246 95.5424L309.967 95.5941L310.628 95.5129L311.23 95.2987L312.702 94.457H314.433H316.552L318.67 94.4644H320.795H322.913H325.032H327.157V95.0034Z",id:"IN"},{d:"M258.441 137.11H256.82H255.208H253.587H251.975H250.355H248.742H247.122H245.509H243.889H242.276H240.656H239.043H237.423H235.81H234.19H232.577H230.957H229.337H227.724H226.104H224.491H222.871H221.258H219.638H218.025H216.405H214.792H213.172H211.559H209.939H208.319H206.706L206.699 135.486V133.854L206.691 132.223L206.684 130.583V128.937L206.677 127.291L206.669 125.637L206.662 123.983V122.322L206.654 120.653L206.647 118.984V117.316L206.639 115.632L206.632 113.949V112.266L206.625 110.567H208.089H209.56H211.024H212.488H213.953H215.424H216.888H218.352H219.824H221.288H222.752H224.224H225.688H227.152H228.623H230.087H231.552H233.016H234.487H235.951H237.415H238.887H240.351H241.815H243.287H244.751H246.215H247.686H249.151H250.615H252.079H253.342L254.955 111.734L255.379 111.749L255.877 111.564L256.256 111.83L256.516 112.553L256.479 112.915L256.152 112.93L255.735 113.366L255.245 114.207L255.364 115.005L256.1 115.743L256.59 116.489L256.835 117.242L257.326 117.825L258.411 118.445L258.396 118.785V119.944L258.403 121.103V122.263V123.414L258.411 124.573V125.718L258.418 126.87V128.014V129.158L258.426 130.303V131.44L258.433 132.577V133.714V134.851L258.441 135.981V137.11Z",id:"KS"},{d:"M342.43 124.448L342.593 124.692L342.668 125.998L342.616 126.257L342.378 126.788L342.393 127.069L342.593 127.512L343.337 128.531L343.411 128.93L343.701 129.321L343.953 129.897L344.749 131.13L345.982 132.149L346.949 132.422L344.303 134.541L343.091 135.309L341.939 135.922L341.843 136.025L341.583 136.704L340.884 137.302L340.446 137.93L339.398 138.454L338.654 139.17L336.789 139.872L335.741 140.115L335.035 140.529L334.983 140.551L334.931 140.573L334.879 140.595L334.827 140.617L334.775 140.639L334.723 140.662L334.671 140.684L334.619 140.706L332.189 140.625L329.758 140.543L327.328 140.462L324.898 140.381L322.467 140.3L320.037 140.219L317.607 140.137L315.177 140.056L312.85 140.1L310.524 140.145L308.198 140.189L305.872 140.233L305.664 139.968L305.054 139.908L304.11 139.813H304.073L304.348 140.699L304.356 141.466L304.333 141.474H303.241H302.029H300.818H299.607H298.395H297.184H295.972H294.583L294.954 140.721L295.274 140.521L295.422 140.484L295.772 140.625L295.943 140.676L296.314 140.411L296.641 139.635L296.827 138.808L296.879 137.937L296.656 137.243L296.582 136.815L296.797 136.283L297.414 135.582L298.626 135.56L300.439 136.217L301.435 136.409L301.613 136.128L301.561 135.626L301.286 134.903L301.19 134.364L301.271 134.009L302.007 133.603L303.397 133.138L303.977 132.533L303.746 131.78L303.828 131.093L304.214 130.465L304.43 130.31L304.571 130.207L304.898 130.318L305.151 130.266L305.329 130.059L305.404 129.734L305.374 129.321L305.47 129.225L305.597 129.203L305.939 129.417L306.325 129.469L306.712 129.343L306.957 129.461L307.061 129.823L307.21 129.934L307.403 129.793L307.507 129.461L307.514 128.937L307.596 128.856L307.678 128.922L307.782 129.085L308.079 129.151L308.51 129.003L309.105 129.129L310.249 129.734L310.725 130.17L311.059 130.03L311.401 129.461L311.929 129.011L312.627 128.679L313.319 128.819L314.002 129.439L314.523 129.565L314.879 129.195L315.065 128.789L315.08 128.339L315.221 128.051L315.481 127.925L315.578 127.711L315.519 127.409L315.712 127.239L316.165 127.195L316.239 127.069L316.187 126.951L316.195 126.892H316.329L316.522 127.025L316.737 127.32L316.849 127.733L317.272 128.14L318.001 128.531L318.573 128.597L318.997 128.339L319.383 127.66L319.74 126.567L320.208 125.947L320.78 125.806L321.197 125.4L321.457 124.728L321.895 124.19L322.512 123.783L322.75 123.193L322.609 122.425L322.884 122.011L323.575 121.945L323.998 122.034L324.244 122.24L324.422 122.336L324.534 122.366L324.771 122.307L325.061 122.159L326.406 121.664L327.112 121.221L327.187 120.786L327.061 120.505L326.733 120.387L326.667 120.203L326.86 119.959L326.867 119.641L326.689 119.25L326.852 118.866L326.964 118.785L327.358 118.49L327.767 118.453L328.094 118.763L328.554 118.837L329.156 118.682L329.706 118.785L330.212 119.154L330.687 119.826L331.126 120.801L331.921 121.391L333.073 121.605L333.913 121.989L334.441 122.536L334.879 122.713L335.392 122.418L335.934 122.262L336.477 122.447L337.205 122.912L338.283 122.809L339.702 122.144L340.542 122.174L340.795 122.905L341.397 123.673L342.356 124.47L342.43 124.448ZM294.337 141.415L293.847 141.429L293.824 141.326L293.854 141.09L293.891 140.986L293.988 140.964H294.099L294.256 141.186L294.337 141.415Z",id:"KY"},{d:"M294.1 193.718L293.624 193.932L291.067 193.112L290.428 192.448L289.863 192.308L289.172 192.226L288.429 193.039L287.864 194.139L288.763 194.737L289.529 195.025L290.8 194.781L291.498 194.249L292.071 194.264L292.346 194.153L292.598 193.873L293.089 194.094L293.104 194.316L292.754 194.626L292.316 194.884L292.048 195.194L292.546 195.815L293.334 196.021L293.631 195.933L293.817 195.239L294.3 194.788L294.954 194.884L294.858 195.165L294.947 195.431L295.252 195.881L295.214 196.531L295.274 196.686L294.568 196.974L294.04 197.07L293.617 197.446L293.839 197.66L293.408 197.852L293.119 197.779L292.97 197.852L292.925 198.081L292.702 198.295L293.022 198.938L293.683 199.359L294.152 199.883L296.024 200.569L296.478 200.547L296.924 201.241L297.28 201.478L297.63 201.596L297.593 202.076L296.976 202.423L296.812 202.836L296.656 203.072L296.381 202.777L296.099 202.563L295.437 203.213L295.118 203.353L295.274 202.652L295.021 202.378L294.642 201.67L294.092 201.234L293.706 201.086L293.401 200.806L293.037 200.695L292.725 200.725L292.197 200.562L292.16 200.186L292.011 199.905L291.602 199.573L289.633 198.945L289.618 199.204L289.752 199.395L290.034 199.528L290.376 199.779V200.533L290.227 200.85L290.168 201.3L290.042 201.758L289.796 202.12L289.261 202.364L289.023 202.157L288.637 201.167L288.094 200.857L287.232 200.82L286.645 201.042L286.006 202.002L285.493 202.157L283.732 201.662L281.718 200.909L281.77 200.658L282.089 200.577L282.699 200.68L282.669 200.422L282.052 199.573L281.941 199.189L282.023 198.724L281.822 198.731L281.45 199.122L280.172 198.79L279.815 198.391L279.065 197.269L278.002 197.232L277.504 196.568L276.634 196.856L276.196 197.173L275.809 197.66L275.958 197.911L276.344 198.31L276.166 198.502L274.932 198.79L272.064 198.473L271.224 198.17L270.094 197.535L268.533 197.018L267.783 196.937L267.047 197.04L264.907 197.092L264.409 197.232L263.985 197.454L263.71 197.21L263.584 196.774L263.829 196.701L264.104 196.45L264.357 195.948L264.386 195.645L264.215 195.445L264.684 194.648L264.795 194.36L264.721 193.002L264.513 192.507L264.542 192.219L264.765 191.473L264.728 190.794L265.115 189.967L265.397 189.539L265.717 188.66L265.791 188.092L265.925 187.664L265.828 187.198L266.051 186.866L265.902 186.401L265.858 185.788L265.583 185.552L265.1 184.636L265.115 184.238L264.609 183.381L264.602 183.086L264.119 182.643L264.022 182.355L263.978 181.166L263.844 180.819L263.428 180.133L262.461 179.136V178.102V177.068V176.035V174.994V173.953V172.912V171.871V170.83H263.717H264.973H266.229H267.485H268.741H269.998H271.254H272.51H273.766H275.022H276.278H277.534H278.79H280.046H281.302L282.677 170.822L282.714 171.228L283.048 171.472L283.07 171.908L282.773 172.535V172.971L283.078 173.214L283.063 173.473L282.729 173.746L282.677 174.041L282.914 174.359L283.018 174.728L282.996 175.149L283.308 175.695L283.791 176.042L284.111 176.456L284.141 176.685L284.163 176.899L284.096 177.201L283.695 177.644L283.39 177.969L283.204 178.087L283.108 178.309L283.078 178.781L282.632 179.394L281.725 180.103L281.123 181.004L280.826 182.089L280.514 182.776L280.187 183.071L280.023 183.64V184.481L279.815 184.946L279.399 185.035L279.31 185.515L279.548 186.386L279.444 186.748L279.154 187.036L279.124 187.257L280.796 187.265H282.476H284.156H285.835H287.515H289.194H290.874H292.554L292.346 188.195L291.855 189.443L291.833 189.768L291.959 190.174V190.403L292.145 190.742L292.546 191.082L292.903 191.591L293.215 192.507L293.297 192.928L293.557 193.511L293.691 193.622L293.884 193.688L294.1 193.718ZM296.181 194.589L296.203 194.958L295.861 194.774L295.356 194.759L295.579 194.633L295.735 194.508L295.816 194.375L296.456 193.91L296.27 194.249L296.181 194.589ZM298.953 196.797L298.759 197.048L298.953 195.829L298.678 194.803L298.968 195.253L299.064 195.785L298.953 196.797ZM298.522 197.55L298.143 197.963L298.157 197.808L298.44 197.387L298.641 197.225L298.522 197.55ZM278.202 199.24L277.942 199.351L276.783 198.665L276.709 198.369L277.281 198.103L277.63 198.126L278.18 198.473L278.381 198.569L278.477 198.709L278.425 198.93L278.202 199.24Z",id:"LA"},{d:"M425.029 84.0024L424.866 84.4896L425.067 84.977L425.2 85.4716L425.52 85.959L425.795 86.0033L426.092 85.9147L426.308 85.9368L426.449 86.1435L426.389 86.3945L426.048 86.4536L425.416 86.8892L424.858 87.0591L424.583 87.5832L424.167 88.1887L423.357 89.1338L423.706 89.4217L424.955 89.7466L425.512 90.0862L426.36 91.8434L426.166 92.0206L426.092 92.3455L426.843 92.7958L427.081 94.051L427.697 94.4792L428.619 94.745L429.741 94.3685L430.678 93.8443L430.648 93.416L430.061 92.4193L429.92 91.9468L429.481 91.644L429.318 91.9025L429.035 91.5702L429.006 91.3783L429.266 91.2897L429.57 91.3266L429.927 91.5038L430.841 92.5965L431.094 94.0215L431.146 94.9296L431.042 95.2397L430.774 95.1733L430.262 95.2323L427.846 95.6975L427.311 96.111L426.085 96.5539L426.01 96.3324L426.1 95.8673L426.025 94.9222L425.78 94.8779L423.87 96.421L423.134 96.517L422.517 96.9674L422.376 96.7163L422.265 95.5646L422.651 94.5973L422.443 94.6121L422.057 94.9592L421.819 94.5457L421.559 94.3242L421.306 94.1101L421.313 93.763L421.328 93.2389L421.038 93.1355L421.009 92.4931L420.986 92.0723L420.459 92.0797L420.028 92.0871L419.336 92.1018L418.616 92.1092L418.088 92.1166L418.08 92.0132L417.241 91.9985L416.401 91.9837L415.561 91.9689L414.721 91.9542L413.881 91.9394L413.049 91.9246L412.209 91.9099L411.369 91.8951L411.332 92.1092L411.027 92.1388L411.02 91.8951L410.433 91.8729L409.846 91.8508L409.259 91.8286L408.672 91.8065L408.084 91.7843L407.497 91.7622L406.91 91.74L406.323 91.7179L406.137 91.489L406.36 90.7064L406.583 89.9238L406.806 89.1338L407.029 88.3437L407.252 87.5537L407.475 86.7637L407.698 85.9737L407.921 85.1837L408.605 85.2132L409.296 85.2428L409.987 85.2723L410.671 85.3018L411.362 85.3314L412.046 85.3535L412.737 85.383L413.428 85.4126L414.424 85.4421L415.42 85.4716L416.416 85.5012L417.412 85.5307L418.407 85.5602L419.403 85.5898L420.399 85.6193L421.395 85.6488L422.005 85.3904L422.725 84.6521L423.164 84.4896L423.877 84.0467L424.234 83.9507L425.029 84.0024ZM427.103 98.0158L425.178 98.4662L424.873 98.1783L425.356 98.0454L425.966 97.3513L426.367 97.2701L426.999 97.6614L427.103 98.0158ZM430.826 99.0347L430.284 99.1824L429.035 98.8427L430.061 98.5548L430.232 98.4514L430.366 98.0306L430.38 97.8165L430.767 98.7246L430.826 99.0347Z",id:"MA"},{d:"M390.203 113.085L390.27 114.51L390.337 115.928L390.404 117.345L390.471 118.763L390.538 120.173L390.604 121.583L390.671 122.986L390.738 124.389H390.753H390.768H390.783H390.798H390.813H390.827H390.842H390.857H391.563H393.116H394.67L395.42 124.381L395.413 124.64L395.324 125.024L395.16 125.179L395.168 124.788L395.056 124.655L394.87 124.824L394.751 125.016L394.699 125.777L394.573 126.153L394.112 126.264L393.644 127.261L393.213 127.822L393.057 128.176L392.403 128.265L391.348 128.405L391.073 128.804L390.545 128.634L389.735 128.656L389.891 128.117L390.129 127.645L389.705 127.172L389.452 127.113L389.192 126.921L389.497 126.53L389.646 126.117L389.556 125.607L389.683 125.223L389.475 125.282L389.133 125.688L388.925 125.851L388.798 125.489L388.65 125.57L388.553 125.814L388.338 125.947L387.884 125.607L387.215 125.223L386.844 124.559L386.636 124.042L386.851 123.112L387.312 122.949L387.907 123.104H388.687L388.575 122.897L388.293 122.934L387.468 122.174L387.201 121.716L386.74 121.591L386.532 122.034L386.301 122.152L386.584 121.185L386.955 121.148L387.505 120.882L387.342 120.321L386.992 120.077L386.361 120.387L386.368 119.996L386.487 119.494H386.963L387.379 119.656L387.736 118.844L387.751 118.482L387.163 119.014L387.03 117.869L387.609 116.769L388.159 116.289L388.85 116.304L389.549 116.223L389.111 116.024L388.657 115.913L388.999 115.477L389.289 115.396L389.571 115.012L388.888 115.071L388.969 114.348L388.635 114.495L388.241 114.562L388.085 114.872L388.115 115.381L387.996 115.714L387.684 115.979L387.163 116.186L387.111 115.824L386.94 115.662L386.874 116.437L386.74 116.703L386.361 115.979L386.249 116.127L386.264 116.334L386.167 116.688L385.84 116.873L385.863 117.33L385.736 117.581L384.689 117.183L384.666 117.316L385.261 118.172L385.692 118.46L385.744 118.925L385.372 119.309L384.859 118.977L384.77 118.999L385.045 119.568L385.224 120.062L385.045 120.483L385.075 120.993L385.038 121.458L384.926 121.864L385.172 123.732L385.469 124.234L385.766 124.721L385.922 125.171L385.61 125.238L385.112 124.869L384.674 124.588L384.153 123.68L384.064 123.318L383.938 123.03L383.997 123.687L384.183 124.426L385.818 126.065L386.123 126.692L386.353 127.187L386.294 127.66L385.87 127.327L385.506 126.899L384.532 126.419L383.306 126.117L382.615 124.994V125.467L382.459 125.866L382.035 125.378L381.768 124.965L381.679 124.514L381.151 124.544L380.593 124.935L380.058 124.839L379.999 124.071L380.14 123.665L380.742 122.698L381.307 122.203L381.56 121.568L381.478 120.579L381.552 121.317L382.169 120.594L381.768 120.025L381.396 119.494L380.839 120.099L380.363 119.87L379.59 119.117L378.334 118.586L378.156 118.32L378.178 118.024L378.349 117.618L377.963 117.22L377.019 116.828L376.617 116.496L376.528 116.422L376.491 116.016L376.365 115.758L376.157 115.647L376.119 115.47L376.246 115.226L376.119 114.968L375.733 114.687L375.599 114.444L375.718 114.229L375.525 114.133L375.019 114.148L374.522 113.949L374.031 113.528L373.444 113.454L372.433 113.875L371.861 113.978L371.608 114.215L371.482 114.621L371.237 114.828L370.679 114.835L370.59 114.82L369.958 114.687L369.512 114.436L369.431 114.333L369.483 114.119L369.401 114.023L369.267 114.008L369.141 114.133L369.007 114.517L367.914 115.566L367.387 115.359L367.186 115.366L365.663 116.843L365.202 117.079L364.302 117.744L364.317 116.6L364.332 115.455L364.355 114.303L364.369 113.152H365.982H367.595H369.208H370.82H372.433H374.046H375.659H377.271H378.884H380.512H382.124H383.737H385.35H386.963H388.575H390.203V113.085ZM394.112 128.044L393.927 128.066L394.112 127.756L394.729 126.279L395.004 125.77L394.737 126.803L394.268 127.756L394.112 128.044Z",id:"MD"},{d:"M437.292 40.6256L437.329 40.8398L437.649 41.2163L438.11 41.4747L438.459 41.5633L438.868 41.5559L439.99 41.0465L441.306 40.7142L442.026 40.4041L442.16 40.1162L442.487 40.0128L443.015 40.1014L443.988 40.825L445.118 41.9177L446.017 42.7816L446.047 44.273L446.062 45.853L446.084 47.5142L446.099 48.6955L446.121 50.3125L446.136 51.5972L446.159 53.2658L446.174 54.1592L446.3 54.4176L446.226 54.7646L446.196 54.9418L446.203 55.0821L446.255 55.2593L446.248 55.5029L446.136 55.7244L446.077 55.9828L446.062 56.4037L446.188 56.6621L446.396 56.8171H446.567L446.79 56.9722L447.08 57.238L447.519 57.4669L447.972 57.5481L448.284 57.489L448.663 57.6441L448.797 58.0132L448.723 58.3602L448.507 58.5227L448.277 58.6482L448.24 58.914L448.351 59.1946L448.515 59.4382L448.693 59.8664L448.619 60.2356L448.455 60.5457L448.381 60.8706L448.522 61.1511L448.894 61.5203L449.124 61.8747L449.488 62.074L449.659 61.9337L449.8 61.7492L449.949 61.6089L450.202 61.6901L450.499 61.7935L450.819 61.919L450.781 62.2217L450.975 62.7238L451.131 63.691L450.893 64.1266L450.945 64.7099L451.591 64.8797L451.748 65.0569L451.777 65.271L450.35 66.755L449.139 66.5483L448.485 66.9396L447.801 67.0577L447.496 67.7223L447.117 67.8625L446.605 67.8256L446.159 67.641L445.817 67.7296L445.341 68.9183L444.955 68.815L444.799 69.2432L444.598 69.4278L444.301 69.5902L444.041 69.0586L443.877 68.5565L443.632 68.4458L443.312 68.3203L442.978 68.3277L442.755 68.4015L442.48 68.7264L442.079 69.0069L441.774 68.7781L441.536 68.4015L441.335 68.9995L441.045 69.6345L441.097 70.3728L440.971 70.8085L440.689 70.6903L440.414 70.3064L439.633 69.9963L439.017 70.0258L439.143 69.6124L439.73 69.0217L439.552 68.9036L439.262 68.9848L439.135 68.9036L439.343 68.3646L439.366 67.7739L439.106 67.9806L438.779 68.6082L437.983 69.1029L438.021 69.9372L437.27 71.6354L437.233 72.3589L436.75 72.9348L436.125 73.4295L435.293 73.2892L434.661 73.7175L434.342 74.2121L434.059 74.286L433.911 73.6584L433.807 73.4664L433.576 74.3893L433.338 74.4484L433.249 73.7913L433.138 73.3557L432.811 73.7322L432.595 74.7216L432.372 74.6404L432.298 74.2712L432.134 74.1604L432.082 74.5813L432.164 75.1719L432.045 75.4894L431.822 75.3196L431.599 75.0391L431.228 75.2532L430.886 75.3418V75.0538L430.953 74.6995L430.276 74.8988L429.459 75.5559L428.827 76.464L429.043 76.6117L429.288 76.8997L428.188 78.2951L427.058 79.5502L426.204 81.588L425.862 81.8243L425.565 82.1934L425.007 81.3074L424.896 80.5913L424.264 79.7422L424.011 79.1589L423.929 78.5018L423.967 77.793L423.915 76.7299L423.863 75.6667L423.811 74.6035L423.759 73.5403L423.707 72.4697L423.654 71.3991L423.602 70.3285L423.55 69.258L423.498 68.18L423.446 67.102L423.394 66.0241L423.342 64.9387L423.29 63.8534L423.238 62.7681L423.186 61.6827L423.134 60.7081L423.305 60.5605L423.729 60.2799L424.004 60.3168L424.242 60.7377L424.442 61.0182L424.673 60.937L424.873 60.5457L424.866 59.9993L425.133 59.6154L425.453 59.5564L425.75 59.5711L425.899 59.3865L425.884 59.1207L425.78 58.6925L425.817 58.1757L426.56 57.2601L427.467 56.64L427.787 56.3298L427.876 55.6949L428.396 55.0378L428.656 54.6612L428.723 54.329L428.589 53.9229L428.604 53.1477L428.783 52.2247L428.998 51.2132L429.481 50.3051L430.269 49.3084L430.47 47.9941L430.685 46.6061L431.636 45.2476L432.714 43.7045L433.331 42.8259L434.438 41.2237L435.226 40.0793L435.62 39.5551L436.036 38.9275L436.713 39.1121L437.381 39.2967L437.285 40.2048L437.292 40.6256ZM443.357 70.0775L442.948 70.2695L442.502 70.1883L442.51 70.6977L442.458 70.8823L441.96 70.6165L441.781 70.4467L441.796 69.7674L442.235 69.1251L442.569 68.874L443 69.0512L443.327 69.7674L443.357 70.0775ZM440.302 71.3991L440.035 71.5911L439.752 71.532L439.745 71.0521L439.834 70.8897L439.931 70.8158L440.079 70.9487L440.302 71.3991Z",id:"ME"},{d:"M298.061 34.1357L298.024 34.3055L298.276 34.3572L298.232 34.4458L297.957 34.6009L297.176 34.9183L296.649 35.0217L296.381 34.911L296.351 34.6968L296.567 34.3867V34.2317H296.351L296.404 34.1062L296.723 33.8625L299.458 32.2973L300.625 31.7288L301.249 31.5442L301.353 31.6328L300.677 32.2234L300.565 32.4671L300.595 32.6295L300.372 32.9396L298.373 34.0323L298.061 34.1357ZM303.189 41.4821L303.063 41.8143L303.085 42.0137L302.238 42.8849L301.926 43.4386L301.665 43.5272L301.457 43.1507V42.848L301.665 42.6191L301.873 42.2942L301.903 41.8438L301.821 41.6814L301.561 42.0875L301.703 42.1761L301.747 42.2425L301.695 42.3902L300.722 42.1761L300.424 41.8586L300.469 41.423L300.796 40.8619L301.97 39.6732L302.49 39.3409L303.962 38.8167L304.772 38.6986H305.589L306.177 38.8684L306.541 39.2154L306.191 39.4443L304.579 39.6362L304.534 39.6953L304.839 39.8799L304.898 40.0128L304.616 40.3598L303.189 41.4821ZM330.219 48.6365L330.435 48.7694L330.583 48.9908L330.948 49.6111L331.126 50.0319L331.237 50.6521L331.312 50.8588L331.304 51.2206L331.059 51.4642L330.992 51.6562L331.141 51.8482L331.966 51.8999L332.345 52.0918L332.486 52.3059L332.389 52.5422L332.441 52.7932L332.642 53.059L333.303 53.4651L333.467 53.6571L333.422 53.8638L333.222 53.9967L332.872 54.0558L330.338 53.6719L329.595 53.6128L329.483 53.7531L329.409 53.7752L329.29 53.7383L329.075 53.7309L328.963 53.6423L328.874 53.3913L328.651 53.2289L328.302 53.155L327.997 53.347L327.648 54.1001L327.7 54.2404L327.64 54.7277L327.729 54.8606L327.722 54.9713L327.625 55.0599L327.417 55.0451L327.105 54.927L325.916 53.7826L325.017 53.2141L323.902 52.7932L323.018 52.5865L322.371 52.5939L321.836 52.8892L321.42 53.4651L320.766 53.79L319.881 53.8712L319.398 54.0262L319.324 54.2551L319.004 54.2625L318.439 54.041L317.86 53.9819L317.258 54.0779L316.819 54.3068L316.351 55.0156L316.262 55.3626L315.927 55.6653L315.036 56.1379L314.991 56.3151L314.523 56.854L314.374 57.1494V57.4373L314.218 57.4226L313.898 57.0977L313.884 56.6621L314.173 56.1083L314.434 55.8425L314.664 55.8573L314.805 55.6136L314.857 55.1116L314.775 54.8606L314.33 54.9565L314.099 55.1559L313.802 55.2002L313.445 55.082L313.133 55.3552L312.858 56.0197L312.531 56.4553L312.152 56.6621L311.899 56.4332L311.773 55.7761V55.2593L311.929 54.6317L311.847 54.5061L311.691 54.7055L311.453 55.2297L311.134 56.3667L310.926 56.7359L310.651 56.891L310.212 57.5776L309.61 58.7958L308.934 59.9772L308.183 61.1142L307.73 61.727L307.581 61.8156L307.514 62.0223L307.492 62.4949L307.158 62.362L306.875 61.978L306.704 61.5793L306.689 61.1732L307.098 60.1617L307.135 59.9993L307.091 59.9033L306.868 59.7926L306.362 59.9772L305.85 60.0141L305.686 59.9476L305.619 59.7704L305.627 59.4972L305.731 59.1724L306.035 58.5743V58.0058L306.177 57.681L306.043 57.0755L306.08 56.7876L305.864 56.4701L305.285 56.0566L303.932 55.5029L304.073 54.8827L304.014 54.6169L303.679 54.2182L302.26 53.7531L301.294 53.5389L300.335 53.5316L299.651 53.3618L298.878 53.3101L298.388 53.0295L297.897 52.7489L297.407 52.4684L296.916 52.1878L296.039 51.9442L295.162 51.7005L294.285 51.4569L293.408 51.2132L292.531 50.9696L291.654 50.7259L290.777 50.4823L289.9 50.2386L289.707 49.8178L289.514 49.3969L289.321 48.9761L289.128 48.5552L288.726 48.378L288.511 48.2821L288.355 48.0606L287.998 48.1566L287.857 47.7874L287.894 47.7062L288.355 47.6102L289.67 47.086L290.792 46.4436L291.721 45.6832L292.881 45.218L294.27 45.0482L295.259 44.7824L295.861 44.4132L296.664 43.697L297.117 43.4903L297.682 43.4239L298.105 43.1433L298.395 42.656L298.938 42.1023L299.733 41.4747L300.186 41.2236L300.298 41.3418L300.342 41.5633L300.313 41.8881L300.513 42.1466L300.944 42.3459L301.138 42.6117L301.101 42.944L301.219 43.2245L301.487 43.4534L301.561 43.9555L301.435 44.7307L301.42 45.2328L301.517 45.4616L301.613 45.5872L301.769 45.4616L301.963 45.1885L302.03 45.0187L302.082 44.8488L303.248 44.0662L303.479 44.0293L303.858 44.2286L305.619 44.5092L306.318 44.7086L307.054 45.1589L307.299 45.3287L308.198 46.7759L308.607 47.3444L308.86 47.4994L309.001 47.7209L309.12 48.2304L309.261 48.3854L310.569 48.4962L311.164 48.4002L311.528 48.1935L311.929 48.3264L312.367 48.7989L312.799 48.9318L313.23 48.7251L313.631 48.7324L314.01 48.9539L314.188 49.1164L314.3 49.109L315.043 48.3928L315.942 47.7578L317.139 47.0638L317.83 46.7537L318.023 46.8276L319.131 46.5987L320.127 46.5765L321.442 46.7168L322.661 46.5544L323.783 46.0892L324.779 45.8308L325.649 45.7717L325.976 45.9046L325.76 46.2147L325.649 46.7537L325.634 47.5142L325.559 47.9941L325.426 48.1935L325.411 48.3854L325.507 48.57L326.347 48.6881L326.786 48.9318L327.291 48.9392L327.863 48.7177L328.302 48.7989L328.606 49.1902L329.045 49.264L329.476 48.9835L329.781 48.7177L330.041 48.5995L330.219 48.6365ZM331.795 50.0688V50.2829L331.579 50.2313L331.401 50.0836L331.26 49.8399L331.081 49.2345L330.806 48.8063L331.215 48.319L331.46 48.2599L331.728 48.3707L331.765 48.6586L331.572 49.1164L331.579 49.5889L331.795 50.0688ZM331.884 51.2354L331.787 51.2944L331.438 50.9031L331.364 50.6595L331.416 50.4601L331.55 50.4527L331.773 50.6373L331.899 50.8514L331.929 51.0951L331.884 51.2354ZM336.202 53.5611L336.269 53.7826L336.098 54.1075L335.607 54.2773L334.612 54.2625L333.965 54.137L333.668 53.9007L333.601 53.7826L333.631 53.5242L333.772 53.5094L333.987 53.6497L334.307 53.5906L334.73 53.3248L334.953 53.1255L334.976 52.9926L334.842 52.7416L334.953 52.6382L335.481 52.7342L335.674 52.8966L336.031 53.4577L336.202 53.5611ZM328.829 55.4807L329.729 55.621L329.818 55.5472L330.071 55.813L330.108 56.0345L330.004 56.2191L329.848 56.3225L329.647 56.3372L329.327 56.1452L328.8 55.6432L328.829 55.4807ZM327.395 55.7613L327.893 55.9459L328.792 56.5587L329.64 56.9131L330.442 57.0165L331.029 57.2306L331.401 57.5628L331.668 57.932L331.832 58.3381L332.218 58.5669L332.82 58.6186L333.296 58.7885L333.645 59.0838L335.57 59.8443L336.373 60.243L336.819 60.6343L336.945 60.8853L336.908 61.1363L336.953 61.4021L337.28 61.919L337.406 61.9633L337.48 62.2143L337.51 62.6647L337.607 62.9674L337.77 63.1224L337.674 63.1815L337.079 62.9231L336.745 63.0043L336.588 63.3439L336.566 63.6614L336.678 63.9641L337.436 64.8649L337.636 65.6844L337.674 66.6738L337.577 67.0577L337.495 67.9068L337.436 69.221L337.421 69.6714L337.168 70.107L336.492 70.7346L336.484 70.6165L336.321 70.5869L336.143 70.6829L335.897 71.2219L335.689 72.2039L335.436 72.7355L335.139 72.8167L334.961 72.9569L334.901 73.1563L334.582 73.2892L333.995 73.3557L333.593 73.651L333.296 74.4853L333.311 74.884L333.17 75.3787L333.177 75.8069L333.333 76.1613L333.809 76.5157L334.597 76.8701L335.065 76.9218L335.392 76.7741L335.734 76.1908L336.061 75.9619L336.462 75.866L336.611 75.6002L337.272 74.441V74.1826L337.034 74.0866L337.072 74.0127L337.384 73.9684L337.651 73.8134L337.882 73.5476L338.283 73.3483L339.264 73.0455L339.792 72.6985L340.126 72.6395L340.609 72.824L341.241 73.2523L341.739 73.8725L342.11 74.6846L342.579 76.7889L343.143 80.1704L343.53 82.0531L343.738 82.4519L343.842 82.6512L343.344 85.2796L342.943 86.3576L342.244 86.9852L341.553 87.5906L340.691 88.6095L339.74 89.1115L339.257 89.4069L339.152 89.5989L339.034 89.5398L338.773 90.0935L338.543 90.854L338.454 91.4373L338.536 91.7622L338.335 91.9689L337.978 92.3528L337.911 92.4931L337.934 92.722L337.859 92.8327L337.688 92.8254L337.555 92.9361L337.235 93.3422L336.678 94.398L336.588 94.59L336.522 94.649L334.195 94.7376L331.869 94.8262L329.543 94.9148L327.217 95.0034V94.4644H325.099H322.98H320.862H318.744H316.626H314.508H312.776L313.23 94.206L313.973 93.6006L314.389 93.0616L314.79 92.3528L315.177 91.4742L315.965 90.1526L316.351 89.3552L316.723 88.3363L317.005 87.2731L317.191 86.1582L317.28 84.9991L317.273 83.7956L317.087 82.5848L316.723 81.3591L316.522 80.7315L316.448 80.5617L315.786 78.9891L315.036 76.7889L315.043 76.6043L315.742 75.2901L315.756 75.1129L315.682 74.0423L315.534 73.5033L315.177 72.7797L315.192 72.5952L315.92 71.6723L316.358 70.9709L316.752 70.1144L317.013 69.1177L317.131 67.9733V67.2128L317.005 66.8288L317.02 66.5335L317.176 66.3268L317.956 66.061L318.216 65.6106L318.276 64.8132L318.432 64.4145L318.692 64.4219L318.937 64.2595L319.16 63.9272L319.458 63.8312L319.829 63.9789L320.342 63.4842L321.004 62.3472L321.509 61.7122L321.866 61.5793L321.933 61.6827L321.71 62.0223L321.643 62.3989L321.732 62.805L321.658 63.1963L321.494 63.7352L321.598 63.9051L321.316 64.7689L321.301 65.1971L321.472 65.522L321.68 65.4113L321.918 64.8575L321.992 64.5622L321.895 64.5253L321.933 64.289L322.096 63.8534L322.245 63.6466L322.371 63.6688L322.408 63.9051L322.349 64.3555L321.97 65.426L321.895 65.7509L321.977 65.8395L322.43 65.175L322.809 64.1118L323.099 63.2923L323.151 62.8493L323.062 61.6975L323.077 61.2249L323.189 60.9001L323.582 60.5309L324.259 60.1174L324.928 59.896L325.589 59.8664L326.05 59.7557L326.31 59.5563L326.221 59.4013L325.775 59.2831L325.44 59.0247L325.21 58.626L325.136 58.1683L325.21 57.6514L325.492 57.142L325.983 56.6473L326.139 56.2782L325.961 56.0419L326.169 55.9607L326.771 56.0271L327.187 55.9607L327.425 55.7613H327.395ZM321.873 57.644L321.635 57.6957L321.449 57.5776L321.479 57.1124L321.724 56.3003L321.962 55.9311L322.282 56.0788L322.215 56.1748L322.282 57.0386L322.163 57.4226L321.873 57.644ZM318.9 62.5761L318.818 62.7164L318.625 62.7016L318.469 62.5687L318.321 62.1405L318.373 62.0445L318.752 62.1035L318.885 62.2881L318.9 62.5761Z",id:"MI"},{d:"M267.114 26.9518L267.954 26.8263L268.675 26.8632L269.395 26.9223L269.782 27.0109L270.897 27.4686L271.625 27.8452L272.673 28.5466L273.253 28.8567L273.528 29.5802L273.855 30.5105H274.315L274.665 29.9642L275.549 29.8682L276.716 30.2521L277.742 31.3375L279.221 32.3047L280.12 32.7846H281.034L282.201 32.3047L283.442 31.3818L284.334 31.2193L284.861 31.3079L285.159 32.0315L285.53 32.3047L286.489 32.2234L288.496 32.3637L290.094 32.1644L290.458 32.5778L290.785 33.2276L291.431 33.4343L292.308 33.2276L293.691 33.3679L293.497 33.4712L293.297 33.4491L293.029 33.6041L292.695 33.9364L291.929 34.4089L290.733 35.0291L289.35 35.5902L286.549 36.6091L284.802 37.6649L284.029 38.2999L281.027 41.4599L279.213 43.1359L276.278 45.4838L276.003 45.7791L275.98 46.0523L275.854 46.0449L275.371 46.6134L275.163 46.9752L274.687 47.0786V48.5331V49.9802V51.4273V52.8671L274.457 53.0147L274.167 53.3544L273.765 53.4356L271.878 54.6169L271.566 54.9565L271.224 55.7466L270.607 56.6325L270.451 57.1051L270.481 57.74L271.424 58.2495L271.774 58.7368L271.945 59.3348L271.922 59.8517L271.447 60.8632L271.365 61.2692L271.417 62.5022L271.179 62.8862L271.372 63.8829L271.387 64.2299L271.239 65.3227L271.135 65.6401L271.32 66.2086L271.343 66.2677L272.227 67.0503L272.97 67.486L273.639 67.6262L274.159 67.9585L274.538 68.4901L275.044 68.8371L275.683 68.9995L276.337 69.4425L277.333 70.5205L277.831 71.436L278.7 72.0857L280.112 72.7798L281.034 73.3926L281.472 73.9168L281.762 75.2532L281.993 78.0735L279.681 78.0809H277.407H275.133H272.859H270.585H268.31H266.036H263.762H261.488H259.214H256.939H254.665H252.391H250.117H247.843H245.568V75.9324V73.7765V71.6132V69.4425V67.2644V65.079V62.8788V60.6712L245.033 59.9403L243.866 59.3496L243.577 58.9952L243.034 58.1092L242.819 57.7327L242.781 57.4373L243.041 57.1051L244.097 56.1452L244.431 55.7023L244.595 55.274L244.84 54.2847L244.743 53.5242L244.81 52.3355L244.595 51.4421L244.55 50.9991L244.416 50.4454L243.621 48.9835L243.428 47.8022L243.227 47.2189L243.16 45.7127L243.183 45.2845L243.339 44.4649L243.004 43.9112L242.952 43.4534L242.796 39.8356L242.692 39.3188L242.722 37.6354L242.112 35.856L241.823 35.2506L241.674 34.5123L241.689 34.1579L241.191 32.9396L240.856 31.5885L240.886 30.4146L240.782 29.5286L240.819 28.8345L240.73 27.7935L240.834 27.2028L240.842 26.2799L240.158 22.9944H241.013H243.993H246.973H249.953H252.933L254.583 23.0091L254.613 20.772L254.635 19L256.144 19.2141L256.597 19.539L256.739 19.694L256.694 20.1813L256.82 21.658L257.095 22.891L257.727 24.3603V24.3677L257.779 24.9435L257.987 25.3053L258.366 25.6376L259.816 26.0436L262.328 26.5162L263.755 27.0552L264.089 27.668L264.758 27.9116L265.761 27.7935L266.467 27.5351L267.114 26.9518Z",id:"MN"},{d:"M280.662 107.142L280.254 108.537L280.246 109.696L280.484 111.099L280.774 112.147L281.101 112.841L282.283 114.163L284.319 116.097L285.59 117.928L286.11 119.664L286.712 120.358L287.403 120.018L288.273 120.173L289.209 120.461L289.7 120.801L289.811 120.919L289.863 121.044L289.826 121.17L289.692 121.502L288.533 124.367L288.132 125.674L288.191 126.161L288.659 126.87L289.536 127.792L290.302 128.391L290.963 128.671L291.989 129.417L293.386 130.613L294.085 131.514V132.112L294.226 132.725L294.516 133.352V133.943L294.226 134.511L294.337 135.272L294.85 136.232L295.281 136.815L295.638 137.014L295.72 137.007L295.742 136.926L295.697 136.793L295.675 136.675L295.705 136.512L295.779 136.446L295.839 136.431L296.173 136.667L296.664 137.191L296.886 137.885L296.842 138.757L296.649 139.584L296.322 140.359L295.95 140.625L295.787 140.58L295.43 140.44L295.289 140.484L294.962 140.684L294.597 141.437L294.583 141.459L294.449 141.533L294.352 141.459L294.337 141.415L294.27 141.193L294.114 140.964H293.995L293.899 140.979L293.862 141.09L293.824 141.326L293.847 141.429L293.966 142.072L293.862 142.53L293.52 142.714L293.468 142.973L293.661 143.268V143.401L293.587 143.504L293.349 143.541L293.17 143.607L293.029 143.844L293.312 144.294L293.252 144.833L292.866 145.468L292.814 145.719L291.535 145.734L290.383 145.756L289.232 145.771L288.08 145.793L288.63 144.877L288.979 144.553L289.239 144.206L289.707 143.881L290.22 143.187L290.279 142.862L290.227 142.544L289.923 142.109L289.618 141.429H287.663H285.716H283.769H281.822H279.875H277.92H275.973H274.026H272.078H270.131H268.184H266.229H264.282H262.335H260.388H258.441V140.359V139.273V138.196V137.11V135.981L258.433 134.851V133.714V132.577L258.426 131.44V130.303L258.418 129.158V128.014V126.87L258.411 125.718V124.573L258.403 123.414V122.262V121.103L258.396 119.944V118.785L258.411 118.445L257.326 117.825L256.835 117.242L256.59 116.489L256.1 115.743L255.364 115.005L255.245 114.207L255.735 113.366L256.152 112.93L256.479 112.915L256.516 112.553L256.256 111.83L255.877 111.564L255.379 111.749L254.955 111.734L253.342 110.567L253.231 110.486L252.733 109.711L252.525 108.788L252.123 108.183L251.521 107.902L251.142 107.297L250.979 106.351L250.592 105.399L250.414 105.118L252.161 105.111L253.929 105.096L255.691 105.082L257.46 105.067L259.221 105.052L260.99 105.045L262.751 105.03L264.52 105.015L266.281 105L268.043 104.986L269.812 104.978L271.573 104.963L273.342 104.949L275.103 104.934L276.872 104.927L278.633 104.912L278.983 105.576L279.362 105.768L279.436 105.982L279.934 106.322L280.046 106.662L280.662 107.142Z",id:"MO"},{d:"M303.531 154.239L304.148 154.793L304.125 154.993L304.118 155.125L304.073 155.524L303.902 157.082L303.731 158.633L303.56 160.183L303.39 161.726L303.219 163.269L303.048 164.805L302.877 166.341L302.706 167.869L302.535 169.397L302.364 170.926L302.193 172.447L302.022 173.968L301.851 175.481L301.68 176.995L301.509 178.501L301.338 180.007L301.413 181.535L301.487 183.064L301.561 184.585L301.636 186.106L301.71 187.619L301.784 189.133L301.859 190.639L301.948 192.293L299.904 192.418L299.012 192.012L298.64 191.931L298.417 191.938L297.377 192.315L296.188 192.603L295.905 192.514L295.504 192.5L294.642 193.482L294.099 193.725L293.929 193.659L293.735 193.592L293.602 193.482L293.341 192.898L293.26 192.477L292.948 191.562L292.591 191.052L292.189 190.713L292.004 190.373V190.144L291.877 189.738L291.9 189.413L292.39 188.166L292.598 187.235H290.919H289.239H287.559H285.88H284.2H282.52H280.841L279.169 187.228L279.198 187.006L279.488 186.718L279.592 186.357L279.354 185.485L279.444 185.006L279.86 184.917L280.068 184.452V183.61L280.231 183.042L280.558 182.746L280.87 182.06L281.168 180.974L281.77 180.074L282.676 179.365L283.122 178.752L283.152 178.279L283.249 178.058L283.435 177.94L283.739 177.615L284.141 177.172L284.207 176.869L284.185 176.655L284.155 176.426L283.836 176.013L283.353 175.666L283.041 175.119L283.063 174.699L282.959 174.329L282.721 174.012L282.773 173.717L283.108 173.443L283.122 173.185L282.818 172.941V172.506L283.115 171.878L283.093 171.442L282.758 171.199L282.721 170.793L282.699 170.586L283.018 169.124L282.944 168.932L282.624 168.489L282.587 167.95L282.781 167.293L282.684 166.784L282.416 166.599L282.349 166.392L282.268 166.09L282.558 165.809L282.572 165.551L282.312 165.314L282.476 164.982L283.063 164.554L283.226 164.31L283.397 164.052L283.501 163.439L283.42 163.07L283.278 162.826L283.345 162.701L283.464 162.59L284.163 162.368L284.364 162.213L284.408 162.021L284.185 161.549L284.401 161.047L285.047 160.515L285.389 160.05L285.426 159.644L285.738 159.349L286.318 159.164L286.675 158.411L286.816 157.089L286.987 156.528L287.284 156.447L287.44 156.262L287.492 155.879L287.857 155.487L288.525 155.089L288.793 154.697L288.711 154.49V154.225H290.495H292.353H294.211H296.069H297.927H299.785H301.643L303.531 154.239ZM300.84 193.533L300.751 193.622L300.134 193.452L299.755 193.297L299.688 193.142L300.729 193.422L300.84 193.533Z",id:"MS"},{d:"M192.727 54.2625L192.734 56.5735L192.749 58.8696L192.756 61.1659L192.771 63.4473V63.4768L192.764 63.5063V63.5359V63.5654H192.712H192.652H192.6H192.541H191.01H189.479H187.941H186.41H184.879H183.34H181.809H180.278H178.74H177.209H175.678H174.139H172.608H171.077H169.539H168.008H166.477H164.938H163.407H161.876H160.338H158.807H157.276H155.745H154.207H152.676H151.145H149.606H148.075H146.544H145.006H143.475V64.7984V66.024V67.2423L143.467 68.4679L143.007 68.2095L142.702 67.9142L142.449 67.5745L141.973 66.6295L141.706 66.2825L141.468 66.0757L141.223 66.061L140.926 66.1791L140.695 66.4006L140.621 66.7919L140.398 67.2497L140.413 67.6336L140.509 67.8256L140.48 67.9363L140.331 68.0175L139.216 67.8772L138.25 68.0692L137.589 67.9215L136.318 67.9954L135.218 67.8625L134.839 67.9289L134.593 68.1357L134.289 68.6525L134.207 68.7485L134.088 68.7632L132.297 68.4827L131.821 68.4753L131.323 68.8149L131.167 69.0512L131.13 69.3687L131.019 69.4573L130.863 69.4425L130.461 69.2358L130.045 68.8961L129.837 68.6451L129.792 68.0766L129.458 67.4342L129.398 66.851L129.183 66.3563L128.856 65.869L128.529 65.5441L128.202 65.4408L127.593 65.5072L127.466 65.4555L126.812 64.8058L126.611 64.5252L126.552 64.2668L126.775 63.6393L126.708 63.2922L126.545 62.864L126.314 62.5096L125.935 62.1995L125.593 61.5276L124.962 60.5826L124.791 59.8516L124.545 59.2388L124.478 58.6334L124.241 58.2642L124.263 57.7917L124.226 57.6588L124.151 57.5997L123.728 57.3339L123.245 56.8614L123 56.7507H122.895L122.836 56.8688L122.799 57.0903L122.026 57.8729L121.372 58.2421L121.052 58.6039L120.762 58.7811L120.606 58.8032L120.391 58.6851L119.707 58.1535L119.142 57.9098L119.083 57.7917L119.113 57.3413L119.373 56.8171L119.105 55.8647L119.187 55.5324L119.395 55.3035L120.004 54.9491L120.064 54.7793L119.93 53.8712L119.588 53.5316L119.492 53.3396L119.596 52.6013L119.447 52.114L119.715 51.7005L119.737 50.9917L119.952 50.2534L120.183 49.1606L120.131 48.6881L120.421 48.1787L120.517 47.6618L120.532 47.3001L120.487 47.0786L120.383 46.9974H120.175L119.217 47.1967L118.904 47.1672L118.629 47.0712L118.473 46.894L118.429 46.4805L118.213 46.2073L118.102 46.163L117.663 46.3255L117.567 46.3181L117.522 46.2442L117.344 45.8899L116.638 45.2032L116.296 44.4132L115.612 43.7192L114.958 42.7667L113.702 41.2753L113.397 40.9726L112.446 40.4558L111.695 39.7027L110.93 39.1637L110.856 39.0751L110.848 39.016L110.893 38.9717L111.108 38.8241L111.16 38.5509L110.87 37.9824L111.012 37.4286L110.818 36.6608L110.714 36.4024L110.172 35.6862L109.815 34.9995L109.258 34.3646L108.507 33.3235V30.7542V28.1774V25.5859V22.9869H109.8H112.78H115.768H118.748H121.729H122.405H124.716H127.697H130.677H133.664H136.645H139.632H142.613H145.593H148.581H150.832H151.561H154.548H157.529H160.509H163.497H166.477H169.457H172.445H175.425H178.405H181.393H184.373H187.361H190.341H192.563L192.578 24.9878L192.593 26.9887L192.6 28.9822L192.608 30.9756L192.615 32.9544L192.63 34.9257L192.638 36.8897L192.645 38.8462L192.66 40.8028L192.667 42.7446L192.675 44.679L192.69 46.6134L192.697 48.5331L192.704 50.4527L192.719 52.3576L192.727 54.2625Z",id:"MT"},{d:"M388.932 140.994L388.746 141.666L388.843 142.05L389.215 142.448L389.623 143.438L389.95 144.767L389.512 144.228L389.044 143.94L388.315 143.718L387.661 143.334L387.706 143.888L387.646 144.486L387.148 144.302L386.807 144.102L387.111 144.737L386.457 144.545L386.019 144.582L385.736 145.143L385.357 145.483L384.792 145.594L383.953 145.077L383.685 144.457L383.574 143.763L383.529 144.582L383.678 145.439L383.626 146.088L384.428 146.206L385.179 146.103L386.197 146.133L386.859 146.007L387.26 145.8L388.219 145.978L388.286 146.76L388.174 147.535L388.122 148.362L388.39 148.355L388.702 148.089L388.858 146.605L389.735 146.059L390.025 146.096L390.307 146.576L390.404 147.063L390.5 147.727L390.292 148.739L388.947 149.92L387.988 151.006L387.498 151.227L386.792 151.102L385.989 150.828L385.595 150.777L385.298 150.865L385.112 150.533L384.993 149.92L384.681 149.713L384.443 149.736L384.28 150.385L383.529 150.57L382.511 150.304L381.441 149.758L381.901 150.341L384.555 151.434L384.852 151.641L385.134 151.936L384.763 152.401L384.473 152.925L384.428 153.339L384.324 153.597L383.269 154.299L382.697 154.173L381.233 152.91L381.901 154.003L382.437 154.468L383.514 154.712L385.528 154.306L386.19 154.749L385.647 155.539L385.105 156.093L384.399 156.152L383.774 156.299L383.589 156.676L383.143 156.698L382.451 156.72L381.374 156.757L380.787 156.669L379.962 157.444L379.649 157.547L379.218 157.399L379.033 156.779L378.839 156.469L378.832 157.636L378.906 157.946L379.062 158.182L378.096 158.817L377.175 159.607L376.84 159.821L376.461 160.212L375.688 161.35L375.495 162.176L375.22 163.099L375.183 162.686L375.227 161.984L375.034 161.187L374.915 162.656L374.618 163.336L371.868 163.291L370.761 163.631L369.75 162.619L368.806 161.667L367.862 160.715L366.918 159.762L365.975 158.802L365.031 157.842L364.087 156.883L363.143 155.923L362.155 155.886L361.166 155.856L360.178 155.819L359.189 155.79L358.201 155.753L357.212 155.723L356.224 155.687L355.235 155.657L355.198 154.993L355.168 154.52L354.552 153.715L354.187 153.243L353.407 153.649L353.362 153.449L353.392 153.095L353.325 152.969L353.11 152.881L352.002 152.829L350.895 152.778L349.788 152.726L348.68 152.674L347.573 152.623L346.466 152.571L345.358 152.519L344.251 152.467L343.998 152.386L343.5 152.667L342.185 153.088L341.538 153.457L341.3 153.435L340.185 153.796L339.071 154.158H338.944L336.826 154.188L334.708 154.217L332.59 154.247L330.472 154.276L330.732 152.475L330.91 152.061L331.111 151.965L331.839 151.958L332.3 151.751L332.709 150.666L333.638 149.809L334.054 149.595L334.678 149.426L336.157 149.219L337.748 148.385L338.892 147.594L339.799 147.373L340.081 147.085L340.29 146.708L340.416 146.192L340.512 146.081L341.04 146.118L341.441 145.667L341.828 145.409L342.214 145.261L342.452 145.254L342.541 145.387L342.608 145.771L342.69 145.896L342.854 145.904L343.077 145.815L343.374 145.571L344.147 144.804L344.66 144.508L345.447 144.338L346.02 144.745L346.361 144.604L347.365 143.032L347.766 142.744L348.063 142.633L348.584 142.611L348.591 142.175L348.769 141.518L348.792 141.068L349.111 140.411L349.23 140.543L351.765 140.566L354.299 140.588L356.833 140.61L359.368 140.632L361.902 140.654L364.436 140.676L366.97 140.698L369.505 140.721L372.039 140.743L374.573 140.765L377.108 140.787L379.642 140.809L382.176 140.831L384.711 140.854L387.245 140.876L388.932 140.994ZM389.475 141.009H389.698L390.396 143.77L391.793 146.768L391.964 147.284L391.637 146.834L390.604 144.855L390.025 143.408L389.475 141.009ZM391.243 146.96L391.139 147.137L390.671 146.192L391.147 146.494L391.229 146.745L391.243 146.96ZM391.883 152.202L390.946 152.431L390.864 152.357L391.942 151.877L392.284 150.171L392.329 149.381L392.165 147.993L392.172 147.705L392.351 148.156L392.507 149.455L392.447 150.437L392.135 151.862L391.883 152.202ZM390.218 152.623L388.947 153.228L388.806 153.191L389.638 152.755L390.218 152.623ZM385.171 157.237L385.001 157.333L385.64 156.285L386.903 154.948L387.245 154.741L386.19 155.879L385.171 157.237ZM384.874 157.141L384.718 157.163L384.443 157.067L384.064 156.89L383.982 156.757L384.347 156.801L384.874 157.141Z",id:"NC"},{d:"M244.877 54.2625H243.25H241.622H239.987H238.359H236.732H235.104H233.469H231.841H230.214H228.579H226.951H225.324H223.696H222.061H220.433H218.806H217.171H215.543H213.915H212.28H210.653H209.025H207.398H205.763H204.135H202.507H200.872H199.245H197.617H195.982H194.354H192.727L192.719 52.3576L192.704 50.4527L192.697 48.5331L192.69 46.6134L192.675 44.679L192.667 42.7446L192.66 40.8028L192.645 38.8462L192.638 36.8897L192.63 34.9257L192.615 32.9544L192.608 30.9756L192.6 28.9822L192.593 26.9887L192.578 24.9878L192.563 22.9869H193.321H196.309H199.289H202.269H205.257H208.237H211.225H214.205H217.186H220.173H223.153H226.141H229.121H232.102H235.089H238.07H240.195L240.879 26.2725L240.871 27.1954L240.767 27.7861L240.857 28.8197L240.819 29.5138L240.923 30.3998L240.894 31.5737L241.228 32.9248L241.726 34.1431L241.711 34.4975L241.86 35.2284L242.15 35.8339L242.767 37.6206L242.737 39.304L242.841 39.8208L242.997 43.4386L243.049 43.889L243.383 44.4427L243.227 45.2623L243.205 45.6831L243.272 47.1893L243.465 47.7726L243.658 48.9613L244.454 50.4232L244.587 50.9769L244.632 51.4199L244.848 52.3133L244.781 53.502L244.877 54.2625Z",id:"ND"},{d:"M245.405 87.4503L245.62 87.4946L246.089 88.3215L246.282 89.7982L246.705 90.9943L247.367 91.895L247.694 92.5522V92.973L247.857 93.416L248.17 93.8959L248.289 94.7007L248.229 95.8451L248.363 96.4505L248.69 96.5244L248.839 96.6794L248.794 96.9304L248.898 97.115L249.165 97.2331L249.24 97.558L249.121 98.097L249.218 98.4292L249.53 98.5695L249.589 98.8353L249.396 99.2192L249.426 99.5294L249.678 99.7509L249.849 100.74L249.931 102.49L249.901 103.509L249.76 103.812L249.99 104.439L250.414 105.118L250.592 105.399L250.979 106.352L251.142 107.297L251.521 107.902L252.123 108.183L252.525 108.788L252.733 109.711L253.231 110.486L253.342 110.567H252.079H250.615H249.151H247.687H246.215H244.751H243.287H241.815H240.351H238.887H237.415H235.951H234.487H233.016H231.552H230.087H228.623H227.152H225.688H224.224H222.752H221.288H219.824H218.352H216.888H215.424H213.953H212.488H211.024H209.56H208.089H206.625V109.438V108.308V107.171V106.034V104.897V103.76V102.616L206.617 101.471H204.871H203.132H201.385H199.638H197.892H196.145H194.399H192.652L192.645 99.1676L192.637 96.864L192.63 94.5457V92.2199L192.623 89.8868L192.615 87.5389L192.608 85.191L192.6 82.8284H195.023H197.446H199.869H202.284H204.707H207.13H209.553H211.976H214.391H216.814H219.237H221.66H224.082H226.505H228.921H231.693L233.781 84.2386L235.022 84.6742L235.617 84.2607L236.895 84.0245L238.865 83.9654L240.106 84.1574L240.626 84.6004L241.637 85.1024L243.146 85.6562L244.045 86.2616L244.342 86.9113L244.87 87.3174L245.405 87.4503Z",id:"NE"},{d:"M425.542 82.1713L425.23 83.3969L425.03 84.0024L424.212 83.9581L423.855 84.054L423.142 84.4896L422.703 84.6521L421.982 85.3904L421.373 85.6488L420.377 85.6119L419.381 85.5824L418.385 85.5528L417.389 85.5159L416.401 85.4864L415.405 85.4495L414.409 85.4199L413.413 85.383L413.294 85.0508L412.908 84.4453L412.811 84.1943L412.834 83.9138L413.049 83.1533L413.205 82.917L413.369 82.474L413.614 80.7094L413.83 79.6832L413.986 77.8078L414.142 77.254L414.32 76.9144L414.602 76.0284L415.123 75.2975L415.465 74.4041L415.873 73.6215L415.94 73.1637L416.245 72.167L416.46 70.3876L416.669 70.107L417.605 69.8634L417.902 69.6788L418.898 68.9405L419.21 68.6304L419.411 68.3203L419.567 67.8182L419.678 67.6853L419.701 67.4121L419.351 66.2382L419.337 65.81L420.11 64.4736L419.946 63.6984L420.058 63.5064L420.741 61.6089L421.388 60.7303L422.265 61.0256L422.733 60.9961L423.082 60.6934L423.134 61.668L423.186 62.7533L423.246 63.8386L423.298 64.924L423.35 66.0093L423.402 67.0873L423.454 68.1652L423.513 69.2432L423.565 70.3138L423.617 71.3843L423.669 72.4549L423.721 73.5255L423.781 74.5887L423.833 75.6519L423.885 76.7151L423.937 77.7783L423.9 78.4797L423.989 79.1368L424.242 79.7201L424.873 80.5691L424.985 81.2853L425.542 82.1713Z",id:"NH"},{d:"M403.321 101.545L403.202 102.261L402.51 103.708L402.221 104.041L401.879 104.336L401.619 104.461L401.381 104.69L401.106 105.052L400.846 105.776L401.002 106.433L402.34 106.676L402.696 106.47L402.882 106.942L402.986 107.599L402.882 108.308L402.659 109.024L402.488 109.918L402.347 111.269L402.131 112.487L402.102 112.118L402.236 110.641L402.02 110.796L401.871 111.136L401.463 113.041L400.898 114.052L400.378 114.754L399.842 114.636L399.961 115.189L399.813 115.477L399.686 116.083L399.367 116.481L399.069 116.444L398.638 116.718L398.467 116.932L398.453 117.33L398.163 117.685L397.122 119.523L396.223 120.062L396.007 119.981L396.245 119.117L396.409 118.239L395.859 117.855L395.331 117.655L394.729 117.685L394.068 117.006L393.213 116.511L392.016 115.167L392.054 114.791L392.024 114.163L392.388 113.166L392.737 112.472L393.22 112.11L394.618 111.741L394.967 111.188L395.175 110.722L395.532 110.412L396.334 109.851L397.553 109.172L395.866 106.89L395.465 106.758L395.019 105.643L394.506 105.333L394.38 105.155L394.358 104.299L394.402 103.804L394.476 103.516L394.915 103.273L395.168 102.778L395.175 102.52L394.841 101.722V101.471L395.48 100.984L396.312 100.031L396.81 98.9904L397.011 98.6877L397.256 98.4735L397.806 98.1782L398.497 98.5991L399.188 99.0199L399.88 99.4407L400.571 99.8616L401.262 100.282L401.953 100.703L402.644 101.124L403.321 101.545ZM401.752 113.462L400.935 114.82L400.92 114.562L401.946 112.871L401.752 113.462Z",id:"NJ"},{d:"M199.795 141.429L199.505 141.437L199.497 143.851L199.482 146.258L199.475 148.658L199.46 151.042L199.453 153.427L199.445 155.797L199.43 158.167L199.423 160.523L199.416 162.87L199.401 165.211L199.393 167.544L199.378 169.87L199.371 172.188L199.364 174.499L199.349 176.803L199.341 179.099H197.766H196.197H194.622L193.046 179.106H191.478H189.903H188.334H186.759H185.183H183.615H182.039H180.471L178.896 179.114H177.32H175.752H174.176H174.139L174.853 180.59H174.845L175.692 181.011L175.64 180.996L174.102 180.982L172.564 180.974L171.025 180.967L169.487 180.96L167.948 180.945L166.41 180.937L164.871 180.93L163.333 180.923V181.838L163.326 182.746V183.662L163.318 184.57L160.843 184.577L158.376 184.585H157.491V181.705V178.818V175.917V173.008V170.084V167.153V164.207V161.246V158.278V155.295V152.298V149.285V146.266V143.231L157.499 140.182V137.11H160.137H162.783H165.429H168.067H170.713H173.359H176.005H178.643H181.289H183.935H186.573H189.219H191.865H194.503H197.149H199.795V138.196V139.274V140.351V141.429Z",id:"NM"},{d:"M122.561 137.088L122.554 140.47L122.539 144.176L122.405 144.228L122.004 145.077L121.558 145.468L121.216 145.461L120.874 145.217L120.525 144.737L119.997 144.457L119.306 144.39L118.696 144.464L118.161 144.686L117.834 145.003L117.656 145.616L117.715 145.867L118.035 146.435L118.057 147.321L118.102 148.037L118.295 148.429L118.325 148.887L118.206 149.61L118.302 150.201L118.704 151.242L118.57 154.247V154.306L116.667 152.512L114.891 150.836L113.115 149.152L111.339 147.462L109.562 145.771L107.786 144.073L106.01 142.367L104.234 140.662L102.955 139.473L101.67 138.284L100.384 137.095L99.1055 135.899L97.8198 134.703L96.5414 133.5L95.2557 132.296L93.97 131.093L92.3349 129.661L90.6924 128.228L89.0574 126.788L87.4224 125.349L85.7799 123.902L84.1448 122.454L82.5023 121.007L80.8673 119.553V117.877L80.8599 116.201V114.517V112.834V111.143V109.445V107.747V106.041V104.329V102.616V100.895V99.175V97.4473V95.7122V93.9698V92.2274H83.4685H86.0772H88.6858H91.2944H93.9105H96.5191H99.1278H101.736H104.338H106.939L109.54 92.22H112.141H114.742H117.344H119.945H122.546V93.6745V95.1216V96.5687V98.0084V99.4482V100.888V102.32V103.745V105.17V106.595V108.013V109.43L122.554 110.841V112.251V113.661V115.056V116.459V117.855V119.25V120.638V122.026V123.407V124.788V126.168V127.542V128.915L122.561 130.281V131.647V133.013V134.371V135.73V137.088Z",id:"NV"},{d:"M407.914 85.1763L407.691 85.9663L407.468 86.7563L407.245 87.5463L407.022 88.3363L406.799 89.1264L406.576 89.9164L406.353 90.699L406.13 91.4816L406.316 91.7105L406.256 92.5965L406.197 93.4825L406.137 94.3685L406.078 95.2471L406.018 96.1257L405.959 97.0043L405.899 97.8829L405.84 98.7615L406.056 99.1159L406.271 99.4703L406.011 99.6327L405.602 99.8912L405.171 100.164L404.606 100.519L404.889 100.977L405.253 101.552L404.963 101.789L404.212 102.586L403.707 103.014L403.291 103.155L403.038 103.516L402.756 103.753L403.023 102.955L403.313 102.283L403.558 100.977L403.484 99.9133L403.179 99.4777L402.867 99.1824L403.231 100.231L403.291 101.515L403.283 101.552L402.615 101.139L401.923 100.718L401.232 100.297L400.541 99.8764L399.85 99.4556L399.159 99.0347L398.467 98.6139L397.776 98.193L397.628 97.846L397.375 97.5802L396.126 97.1151L395.807 96.805L395.517 96.3841L395.316 95.8673L395.212 95.3283L395.205 94.9001L395.294 94.4202L395.004 94.1027L394.997 93.8L394.811 93.6006L393.993 93.2389L393.748 92.7294L393.206 92.2495H392.239H391.273H390.307H389.341H388.375H387.409H386.442H385.476H384.51H383.544H382.578H381.612H380.645H379.679H378.713H377.747H376.781H375.815H374.848H373.882H372.916H371.95H370.984H370.018H369.052H368.085H367.119H366.153H365.187H364.221H363.254H362.288V90.9943V89.7392V89.6875L362.697 89.4586L364.042 88.6095L364.711 87.9894L365.417 87.4725L366.16 87.0664L366.748 86.5422L367.186 85.8999L367.669 85.4199L368.197 85.1025L368.479 84.7702L368.516 84.4232L368.42 83.9507L368.189 83.36L368.16 82.8949L368.331 82.5552L368.368 82.3264L368.271 82.2082L367.164 81.8686L367.208 80.2369L367.193 80.1926L367.253 80.1705L369.795 79.4469L371.415 79.1959L373.392 79.1294L375.748 79.4838L376.662 79.8087L377.242 80.2221L377.91 80.3329L378.668 80.1409L379.716 80.0745L381.062 80.1409L381.783 80.2369L381.879 80.3698L381.968 80.3329L382.058 80.1262L382.414 79.8973L383.418 79.5502L383.551 79.6241L383.759 79.4469L384.042 79.0261L384.555 78.5609L385.305 78.0515L385.982 77.7857L386.584 77.7635L386.985 77.638L387.186 77.4091L387.245 77.2024L387.163 77.0252L387.2 76.8332L387.23 76.7372L387.2 76.656L387.126 76.4936L387.067 75.6519L386.948 75.2606L386.784 74.9726L386.68 74.7438L386.703 74.5444L387.067 74.3007L387.037 74.5296L387.134 74.5961L387.305 74.4927L387.691 73.9907L387.736 73.7987L388.003 73.5993L388.196 73.2966L387.981 73.2523L387.468 73.3409L387.349 73.2523L387.617 72.8463L387.565 72.6174L387.483 72.5214L387.312 72.4845L386.732 72.8389L386.554 72.8684L386.532 72.6838L386.234 72.263L387.037 71.5173L389.876 69.4426L390.166 69.1251L390.27 68.8445L390.196 68.6009L390.114 68.5418L390.158 68.4827L392.893 65.8026L394.447 64.5622L395.732 63.8682L396.706 63.5359L397.367 63.5802L397.739 63.5359H398.059H399.686L402.6 63.5285L405.513 63.5212H407.237L407.289 64.1709L407.141 64.9388L407.26 65.7731L407.096 67.5081L407.535 68.8445L407.43 69.7379L407.46 70.6977L407.386 70.934L407.044 71.4877L406.843 72.0267L406.732 72.5731L406.739 72.9275L407.037 74.4927L407.096 75.1794L407.089 75.5781L406.828 76.8628L406.814 77.2245L406.888 77.3279H406.985L407.282 76.9292L407.416 76.8701L407.587 76.9661L408.003 77.5715L407.98 78.6569L407.966 79.4395L407.951 80.3107L407.921 81.6176L407.899 82.57L407.884 83.4412L407.869 84.1057L407.772 84.593L407.914 85.1763ZM387.914 70.6165L387.691 70.6977L387.639 70.587L387.676 70.4762L387.862 70.3433H388.167L388.129 70.4467L387.914 70.6165ZM386.866 73.3852L386.762 73.4147L386.769 73.208L386.873 73.0751L387.082 73.0161L387.074 73.1194L386.866 73.3852ZM368.197 82.6217L367.981 82.9466L367.773 82.9171L367.625 82.8137L367.572 82.6069L367.61 82.3485L367.795 82.2378L368.293 82.3337L368.308 82.4371L368.197 82.6217ZM413.116 101.604L412.618 102.195L413.064 102.254L413.45 102.077L413.815 101.722L414.662 101.242L415.39 101.036L415.621 100.991L415.962 101.324L416.646 101.058L417.352 100.91L414.305 102.438L413.681 102.608L412.789 103.059L411.949 103.383L411.34 103.502L408.322 104.631L408.084 104.653L407.824 104.543L405.335 105.126L404.316 105.192L403.387 105.392L404.071 104.927L404.086 104.749L403.923 104.609L403.558 104.646L403.179 105.126L402.577 105.288L402.458 104.764L402.659 104.358L402.934 103.974L403.529 103.369L404.383 102.985L404.814 102.653L405.112 102.948L405.179 102.549L405.409 102.32L405.662 102.195H406.264L406.591 102.136L406.828 102.003L407.074 101.981L407.735 102.158L408.382 102.106L408.902 101.855L409.445 101.774L410.879 101.715L412.306 101.53L412.878 101.205L414.075 100.297L414.766 100.046L413.696 101.095L413.116 101.604ZM401.373 105.835L401.039 105.872L401.373 105L401.99 104.602L402.213 104.683L402.221 104.993L402.131 105.259L401.723 105.665L401.373 105.835Z",id:"NY"},{d:"M357.078 104.705L356.254 105.104L356.097 105.473L356.35 105.938L356.484 106.543L356.499 107.282L356.038 108.906L355.087 111.402L354.611 112.967L354.596 113.609L353.972 114.444L352.738 115.477L351.876 116.097L351.386 116.312L350.969 116.297L350.642 116.046L350.271 116.216L349.855 116.806L349.476 117.109L349.119 117.124L348.814 117.508L348.561 118.246L348.324 118.674L348.101 118.785L348.086 119.161L348.272 119.796L348.257 120.025L348.153 120.033L348.056 119.996L347.811 120.136L347.543 120.49L347.439 120.498L347.365 120.439L347.29 119.974L347.068 119.649L346.711 119.457L346.213 119.885L345.574 120.933L345.299 121.613L345.403 122.085L345.462 122.772L345.299 123.052L344.957 123.156L344.682 123.532L344.496 124.167L344.013 124.573L343.24 124.743L342.43 124.448L342.371 124.426L341.412 123.628L340.81 122.861L340.557 122.13L339.725 122.093L338.298 122.765L337.228 122.861L336.499 122.403L335.957 122.218L335.414 122.373L334.894 122.669L334.463 122.491L333.928 121.945L333.088 121.561L331.936 121.347L331.133 120.749L330.695 119.782L330.219 119.11L329.721 118.741L329.164 118.637L328.569 118.785L328.108 118.711L327.781 118.401L327.365 118.438L326.979 118.733L326.986 115.765L327.016 112.841L327.038 109.91L327.061 106.957L327.083 103.989L327.105 101.013L327.135 98.0158L327.157 95.0034L329.483 94.9148L331.817 94.8336L334.143 94.7376L336.477 94.6564L336.544 94.5973L336.529 94.6269L336.626 94.7893L337.257 94.8927L337.688 95.0846L338.023 95.3726L339.242 95.9411L339.613 96.2881L339.977 96.4801L340.349 96.517L340.594 96.4062L340.735 96.1552L340.906 96.133L341.114 96.3545L341.798 96.5982L341.821 96.672L339.925 97.0929L339.531 97.2922L340.007 97.4251L340.483 97.3956L340.966 97.1962L341.523 97.2036L342.006 97.2996L342.162 97.2184L342.222 97.1741L343.047 97.7279L343.359 97.8165L343.679 97.75L344.013 97.5433L344.741 97.2701L345.871 96.9378L346.956 96.7976L347.997 96.864L348.658 96.768L349.26 96.421L350.59 95.284L352.114 94.3684L354.633 93.224L357.071 92.3307V93.1059V94.0805V95.0551V96.0223V96.9969V97.9641V98.9313V99.8985V100.858V101.818V102.785V103.738L357.078 104.705Z",id:"OH"},{d:"M258.441 141.429L258.597 142.633L258.753 143.822L258.909 145.018L259.065 146.206L259.221 147.395L259.377 148.584L259.533 149.765L259.689 150.954L259.674 151.869L259.652 152.792L259.637 153.715L259.615 154.631L259.593 155.546L259.578 156.462L259.555 157.377L259.533 158.293L259.518 159.201L259.496 160.117L259.474 161.025L259.459 161.933L259.437 162.841L259.414 163.742L259.399 164.65L259.377 165.551L257.802 165.13L257.408 164.864L256.679 164.554L256.033 163.934L254.747 163.151L254.256 162.966L254.1 162.989L253.84 163.373L253.149 163.675L252.777 163.683L252.109 163.572L251.975 163.476L251.878 163.24L251.611 163.085L251.41 163.21L250.429 163.528L250.288 163.756L249.73 163.764L249.18 163.601L247.798 164.111L247.322 164.51L246.824 164.642L246.572 165.034L246.416 164.975L245.895 164.495L245.368 164.355L244.632 163.882L244.61 163.461L244.528 163.409L244.402 163.365L244.238 163.402L243.918 163.764L243.733 163.852L243.554 163.838L242.841 163.601L242.544 163.173L242.402 163.04L242.239 163.011L241.934 163.144L241.763 163.609L241.622 163.742L241.332 163.816L241.347 164.052L241.087 164.702L240.946 164.834L240.76 164.812L240.574 164.65L240.433 164.421L240.373 164.222L240.477 163.712L240.411 163.535L240.269 163.483L239.927 163.727L239.623 163.712L239.229 163.956L238.991 164.03L238.768 163.971L238.404 163.579L237.78 163.328L237.534 162.863L237.423 162.73L237.289 162.693L237.155 162.708L236.932 162.856L236.211 163.469L235.884 163.66L235.602 163.697L235.327 163.638L235.156 163.483L235.126 162.863L234.963 162.679L234.294 162.287L234.153 161.925L234.093 161.416L233.283 161.497L232.287 161.446L231.841 161.888L231.604 161.97L231.329 161.881L230.526 161.276L229.671 161.401L229.188 161.335L227.999 160.884L227.07 160.84L226.684 160.759L226.476 160.655L226.386 159.961L226.015 159.378L225.896 159.216L225.264 158.81L225.16 158.795L225.093 158.883L224.952 159.349L224.759 159.371L224.03 159.238L223.362 159.378L222.99 159.149L221.719 158.079L221.206 157.798L220.79 157.71V156.705V155.701V154.69V153.678L220.783 152.667V151.655V150.636V149.617V148.606V147.58L220.775 146.561V145.542V144.516V143.489V142.463L220.768 141.429H219.46H218.152H216.836H215.528H214.22H212.905H211.597H210.281H208.973H207.665H206.35H205.042H203.726H202.418H201.11H199.795V140.351V139.274V138.196V137.11H201.519H203.25H204.975H206.706H208.319H209.939H211.559H213.172H214.792H216.405H218.025H219.638H221.258H222.871H224.491H226.104H227.724H229.337H230.957H232.577H234.19H235.81H237.423H239.043H240.656H242.276H243.889H245.509H247.122H248.742H250.355H251.975H253.588H255.208H256.821H258.441V138.196V139.274V140.359V141.429Z",id:"OK"},{d:"M58.3334 52.1583L59.032 51.9073L59.582 52.0993L60.2806 52.5496L60.9718 53.9155L61.6481 56.1822L61.7967 56.9353L62.3244 57.4004L62.9487 57.4226L65.4533 57.7548L65.8249 57.7327L66.2783 57.6441L67.6978 56.7803L69.2362 56.4997L71.0571 56.5587L72.1719 56.8098L72.5806 57.238L73.5542 57.2823L75.8582 56.7803L78.4073 56.4258L79.7748 56.0641L81.3281 55.311L84.8583 54.3511L86.6197 54.2404L87.5116 53.8786L87.7196 53.6941L87.846 53.6867H89.704H91.5546L93.4126 53.6793H95.2706H97.1286L98.9866 53.6719H100.845H102.576L102.769 54.1075L103.498 54.964L104.531 55.6949L105.207 56.4628L105.512 57.2602L105.007 59.0838L103.691 61.919L102.978 63.7205L102.859 64.5031L102.212 65.8248L101.023 67.6927L100.443 69.0734L100.473 69.9668L100.874 70.491L101.647 70.6313L102.182 70.9266L102.465 71.3622L102.472 71.7757L102.205 72.1448L102.13 72.5288L102.242 72.9275L102.153 73.6363L101.707 75.0834L101.714 75.1351V77.4829L101.722 79.6093V81.7357V83.8473L101.729 85.9516V88.0484L101.736 90.1453V92.2273H99.1278H96.5192H93.9105H91.2944H88.6858H86.0772H83.4685H80.8599H79.0168H77.1662H75.323H73.4799H71.6367H69.7936H67.9505H66.0999H64.2567H62.4136H60.5705H58.7273H56.8767H55.0336H53.1905L51.2804 92.22L50.396 91.083L50.0096 89.3848L49.9352 88.6686L50.0393 86.7637L49.7717 85.9516L49.1028 84.6078L49.3927 83.4338L49.6974 82.7177L50.4555 79.5946L50.6338 79.3435L50.9534 79.3509L51.5034 78.8119L51.2507 78.6938L50.8642 78.9448L51.2061 77.7044L51.5926 76.6339L51.8378 76.2499L51.9642 72.7503L52.1871 70.0701L52.5513 69.1768L52.425 68.2612L52.5662 67.0135L52.4621 65.7509L53.2425 59.6376L53.1384 58.8919L53.3763 57.8951L53.1533 55.2593L53.2499 52.2912L53.0567 51.9147L52.9526 51.5012L53.1384 51.4421L53.4952 51.8777L55.1599 51.8704L56.2302 51.4717L56.6166 51.6046L57.0625 52.1436L57.6274 52.2543L58.3334 52.1583Z",id:"OR"},{d:"M397.799 98.1856L397.249 98.4883L397.003 98.7024L396.803 99.0051L396.305 100.054L395.472 100.999L394.833 101.486V101.737L395.168 102.534L395.16 102.793L394.908 103.287L394.469 103.531L394.395 103.819L394.35 104.314L394.372 105.17L394.499 105.347L395.012 105.65L395.45 106.772L395.859 106.905L397.546 109.187L396.327 109.859L395.524 110.427L395.175 110.73L394.484 111.535L393.451 111.8L392.886 112.103L392.745 112.243L392.121 111.992L391.251 112.029L390.954 112.14L390.731 112.361L390.203 113.085H388.59H386.97H385.357H383.745H382.132H380.512H378.899H377.286H375.673H374.053H372.441H370.828H369.208H367.595L365.982 113.078H364.369L363.455 113.085H362.541H361.634H360.72H359.813H358.899H357.985H357.078V112.044V110.996L357.071 109.955V108.906V107.858V106.802V105.753L357.078 104.705L357.071 103.738V102.785V101.818V100.858V99.8985V98.9313V97.9641V96.9969V96.0223V95.0551V94.0805V93.1059V92.3307L358.372 91.8508L358.951 91.5259L359.531 91.2158L359.836 91.0312L360.178 90.8688L362.37 89.6579V89.7096V90.9648V92.2199H363.336L364.295 92.2273H365.261H366.227H367.194H368.16H369.118H370.085H371.051H372.017H372.983L373.942 92.2347H374.908H375.874H376.84H377.799H378.765H379.731H380.697H381.656H382.622L383.589 92.242H384.555H385.521H386.48H387.446H388.412H389.378H390.337H391.303H392.269L393.235 92.2494L393.778 92.7294L394.023 93.2314L394.841 93.5932L395.026 93.7999V94.0953L395.316 94.4127L395.227 94.9V95.3283L395.331 95.8673L395.532 96.3841L395.822 96.7976L396.141 97.1076L397.397 97.5728L397.65 97.846L397.799 98.1856Z",id:"PA"},{d:"M422.042 94.9592L421.782 95.1954L421.507 94.8336L421.365 94.4423L421.165 94.2208L420.949 94.1396L421.135 94.9961L420.697 95.6384L420.578 97.2996L420.02 97.9863L418.296 98.4293L417.783 98.385L417.872 97.8534L418.051 97.6319L418.088 97.056L418.11 96.6794L418.103 96.0445L418.095 95.3135L418.088 94.5161L418.08 93.8147L418.073 93.3053L418.066 92.6039V92.1018L418.593 92.0944L419.314 92.0871L420.005 92.0723L420.436 92.0649L420.964 92.0575L420.986 92.4783L421.016 93.1207L421.306 93.2241L421.291 93.7483L421.284 94.0953L421.536 94.3094L421.796 94.5309L422.042 94.9592ZM421.99 96.9453L421.64 97.1963L421.254 97.152L421.447 96.8123L421.521 96.3103L421.715 95.7565L421.826 95.5867L422.057 95.439L421.99 96.9453ZM421.12 97.0043L420.927 97.1741L420.853 96.7237L420.986 96.2069L421.128 96.1922L421.194 96.4653L421.12 97.0043Z",id:"RI"},{d:"M370.753 163.653L370.664 163.683L368.814 164.923L368.264 165.469L366.74 167.566L366.354 168.903L366.042 168.341L366.116 167.921L366.123 167.574L365.737 168.312L366.101 169.39L365.774 169.803L364.771 170.571L364.221 170.697L363.596 170.911L363.403 171.671L362.563 172.365L362.073 172.675L361.181 172.484L361.456 173.155L361.129 173.657L360.557 174.049L359.851 174.3L359.449 174.27L359.107 174.403L358.832 174.728L358.171 175.031L357.487 174.861L356.707 174.758L356.276 174.935L357.004 175.237L357.391 175.666L357.316 176.249L357.116 176.47L356.655 176.773L356.454 176.729L356.335 176.456L356.187 175.887L355.971 176.005L355.934 176.271L355.748 176.367L355.094 175.459L355.131 176.153L355.354 176.685L355.577 176.958L355.8 177.113L355.852 177.364L355.406 177.962L355.176 178.095L354.767 178.191L354.537 178.56L354.611 178.885L353.192 178.228L352.768 177.637L352.783 176.877L352.515 176.013L351.683 174.566L351.081 174.152L350.68 173.163L350.286 171.45L349.669 170.357L348.822 169.877L348.257 169.309L347.967 168.659L347.67 168.231L347.357 168.031L347.186 167.699L347.164 167.219L346.681 166.592L345.262 165.425L344.927 164.716L344.258 163.978L342.593 162.479L340.996 159.563H340.988L340.788 158.972L340.446 158.728L339.896 158.64L339.353 158.352L338.565 157.614L338.558 157.606L337.235 156.691L337.51 155.871L338.528 154.793L338.87 154.225L338.922 154.217H339.048L340.163 153.855L341.278 153.501L341.516 153.516L342.162 153.147L343.47 152.726L343.976 152.445L344.229 152.527L345.336 152.571L346.451 152.623L347.558 152.667L348.665 152.718L349.773 152.77L350.888 152.814L351.995 152.866L353.102 152.91L353.318 152.999L353.385 153.125L353.355 153.479L353.4 153.678L354.18 153.272L354.544 153.737L355.161 154.542L355.191 155.015L355.228 155.679L356.216 155.709L357.205 155.746L358.193 155.775L359.182 155.812L360.17 155.842L361.159 155.879L362.147 155.908L363.136 155.945L364.08 156.905L365.023 157.865L365.967 158.824L366.911 159.777L367.855 160.737L368.806 161.689L369.75 162.642L370.753 163.653Z",id:"SC"},{d:"M244.877 54.2625L244.639 55.2519L244.476 55.6875L244.134 56.1231L243.079 57.0829L242.819 57.4152L242.856 57.7105L243.071 58.087L243.614 58.973L243.904 59.3348L245.063 59.9255L245.598 60.6564V62.864V65.0642V67.2497V69.4351V71.6058V73.7691V75.925V78.0735L244.587 78.1105L244.706 78.7085L244.981 79.2918L245.033 79.6314L244.974 79.9046L244.788 80.1483L244.833 80.5322L244.885 80.643L245.345 80.8866L245.494 81.2262L245.546 81.6102L245.539 81.8981L245.256 82.4297L245.182 83.1311L244.84 84.1721L244.461 84.8071L244.387 85.132L244.424 85.3904L245.004 86.0622L245.041 86.3281L245.226 86.6751L245.405 87.4503L244.87 87.3174L244.342 86.9113L244.045 86.2616L243.146 85.6562L241.637 85.1024L240.626 84.6004L240.106 84.1574L238.865 83.9654L236.895 84.0245L235.617 84.2607L235.022 84.6742L233.781 84.2386L231.693 82.8284H228.921H226.505H224.082H221.66H219.237H216.814H214.391H211.976H209.553H207.13H204.707H202.284H199.869H197.446H195.023H192.6L192.593 80.451L192.585 78.0735L192.578 75.6814L192.571 73.2744L192.563 70.8675L192.556 68.4458L192.548 66.0093L192.541 63.5654H192.6H192.652H192.712H192.764V63.5359V63.5064L192.771 63.4768V63.4473L192.756 61.1659L192.749 58.8697L192.734 56.5735L192.727 54.2625H194.354H195.982H197.617H199.245H200.872H202.507H204.135H205.762H207.398H209.025H210.653H212.28H213.915H215.543H217.171H218.806H220.433H222.061H223.696H225.324H226.951H228.579H230.214H231.841H233.469H235.104H236.732H238.359H239.987H241.622H243.25H244.877Z",id:"SD"},{d:"M335.05 140.536L336.64 140.543L340.029 140.558L342.437 140.573L344.414 140.58L345.581 140.588L347.053 140.595L347.38 140.418L348.115 140.447L349.104 140.484L348.784 141.149L348.762 141.592L348.584 142.249L348.576 142.685L348.063 142.707L347.759 142.817L347.357 143.105L346.362 144.678L346.012 144.818L345.44 144.412L344.652 144.582L344.139 144.877L343.374 145.645L343.077 145.889L342.846 145.978L342.683 145.97L342.601 145.845L342.534 145.461L342.445 145.328H342.207L341.821 145.475L341.434 145.734L341.033 146.177L340.505 146.14L340.408 146.251L340.282 146.768L340.074 147.144L339.792 147.432L338.877 147.654L337.733 148.444L336.15 149.278L334.664 149.485L334.047 149.654L333.63 149.869L332.701 150.725L332.293 151.81L331.824 152.017L331.104 152.024L330.903 152.12L330.717 152.534L330.457 154.328L328.183 154.306L325.909 154.276L323.642 154.247L321.368 154.225L320.245 154.21L319.123 154.195L318.001 154.18L316.879 154.173L315.756 154.158L314.634 154.143L313.512 154.136L312.39 154.121L311.268 154.107L310.145 154.092L309.023 154.084L307.901 154.07L306.779 154.055L305.656 154.047L304.534 154.033L303.412 154.018L303.323 154.025L303.404 154.129L303.531 154.239H301.628L299.77 154.232H297.912H296.054L294.196 154.225H292.338H290.48L288.696 154.217V154.195L288.957 153.841L289.752 153.265L290.101 152.504L289.997 151.567L290.287 150.725L290.978 149.965L291.26 149.211L291.142 148.466L291.483 147.86L292.294 147.388L292.405 147.196L292.375 147.056L292.36 146.893L292.368 146.827L292.405 146.679L292.583 146.598L292.821 146.524L292.925 146.406V146.214L292.784 145.874L292.814 145.719L292.866 145.468L293.252 144.833L293.312 144.294L293.029 143.844L293.171 143.607L293.349 143.541L293.587 143.504L293.661 143.401V143.268L293.468 142.973L293.52 142.714L293.862 142.53L293.966 142.072L293.847 141.429L294.337 141.415L294.352 141.459L294.449 141.533L294.583 141.459L294.597 141.437H295.987H297.191H298.403L299.607 141.444H300.818H302.022H303.233H304.326L304.348 141.429V140.662L304.066 139.776H304.103L305.047 139.872L305.664 139.931L305.864 140.196L308.198 140.152L310.524 140.108L312.85 140.064L315.184 140.019L317.614 140.1L320.037 140.189L322.468 140.27L324.898 140.359L327.328 140.44L329.758 140.521L332.181 140.61L334.611 140.691L334.671 140.669L334.723 140.654L334.775 140.632L334.834 140.61L334.886 140.595L334.946 140.573L334.998 140.558L335.05 140.536Z",id:"TN"},{d:"M259.377 165.551L259.741 165.957L260.031 166.075L260.12 166.237L260.262 166.282L260.44 166.245L260.707 166.06L261.101 166.112L261.428 166.045L262.075 166.141L262.432 166.333L262.439 167.456L262.447 168.578L262.454 169.7L262.461 170.822V171.863V172.904V173.945V174.986V176.027V177.061V178.095V179.128L263.428 180.125L263.844 180.812L263.978 181.159L264.022 182.348L264.119 182.636L264.602 183.078L264.609 183.374L265.115 184.23L265.1 184.629L265.583 185.545L265.858 185.781L265.902 186.394L266.051 186.859L265.828 187.191L265.925 187.656L265.791 188.084L265.717 188.653L265.397 189.531L265.115 189.96L264.728 190.787L264.765 191.466L264.542 192.212L264.513 192.5L264.721 192.994L264.795 194.353L264.684 194.641L264.215 195.438L263.881 195.416L263.145 196.73L263.561 197.468L263.532 197.734L262.067 197.882L258.745 199.359L257.452 200.156L257.519 199.89L259.087 198.857L258.537 198.701L257.645 198.96L257.326 198.864L257.705 198.007L257.579 197.254L256.947 197.232L256.546 197.838L256.263 197.808L255.899 197.55L255.617 197.631L255.825 198.997L256.226 199.558L256.56 200.274L255.654 201.153L254.806 201.876L254.717 202.578L253.87 203.493L253.075 204.01L251.194 205.221L250.659 205.479L249.812 206.04L248.645 206.461L247.523 207.133L247.144 207.237L247.857 206.668L248.705 206.107L247.976 206.181L246.854 205.922L246.17 205.908L246.163 206.114L245.643 206.402L245.1 205.981L244.862 205.693L244.751 205.45L244.52 205.391L244.298 205.509L245.108 207.244L245.449 207.318L245.828 207.488L245.353 207.894L244.84 208.196L244.037 208.403L243.354 207.768L243.205 208.558L243.116 209.348L242.885 209.548L242.521 209.835L242.321 209.621L242.224 209.319L241.994 209.592L241.652 209.799L241.087 209.835L240.663 209.946L240.671 210.271L240.79 210.596L241.54 210.338L241.265 211.179L240.574 212.014L240.017 212.213L239.162 212.087L238.946 212.169L238.761 212.338L239.757 213.638L239.117 215.594L238.709 216.303L238.426 216.392L238.114 216.414L237.007 215.786L236.405 215.299L236.94 216.628L238.389 217.012L238.463 217.514L238.456 217.942L238.174 218.444L237.906 219.109L238.107 219.574L238.337 220.718L238.53 221.243L238.746 222.837L238.976 223.524L240.292 226.057L240.738 226.079L240.812 226.352L240.767 226.876L239.816 227.031L239.415 227.267L239.34 227.467L239.281 227.577L239.162 227.57L238.709 227.422L237.683 226.706L236.182 226.263L234.212 226.093L232.867 225.732L232.146 225.185L231.396 224.86L230.608 224.757L229.954 224.462L229.441 223.967L228.683 223.65L227.687 223.509L227.04 223.14L226.587 222.232V222.217L226.186 220.704L225.68 219.751L224.692 218.57L224.603 218.415L224.595 218.223L224.722 217.536L224.618 217.042L224.305 216.635L224.231 216.207L224.402 215.757L224.417 215.218L224.268 214.59L223.636 213.911L222.522 213.173L221.578 212.102L220.797 210.685L220.025 209.703L219.259 209.156L218.739 208.492L218.456 207.702L218.375 207.244L218.486 207.118L218.018 206.24L216.963 204.608L216.353 203.412L216.197 202.652L215.528 201.751L214.339 200.702L213.692 200.023L213.536 199.551L211.686 198.17L211.151 197.306L210.727 197.033L210.244 197.062L209.999 196.981L209.984 196.789L209.828 196.782L209.531 196.959L208.549 196.996L206.877 196.893L205.673 196.656L204.93 196.287L204.41 196.339L204.113 196.804L203.481 197.107L202.507 197.24L201.675 198.103L200.976 199.691L200.672 200.71L200.761 201.168L200.575 201.5L200.122 201.706L199.661 202.164L199.193 202.88L198.643 203.227L198.018 203.205L196.859 202.652L195.172 201.574L193.849 200.909L192.89 200.658L192.043 200.156L191.307 199.41L190.631 198.916L190.014 198.665L189.293 197.838L188.468 196.427L188.052 195.342V194.19L186.967 191.68L186.395 190.587L185.971 190.085L185.139 189.487L183.897 188.786L182.233 187.39L180.144 185.286L178.665 184.016L177.796 183.588L177.045 182.827L176.406 181.735L175.782 181.041L175.715 181.011L174.868 180.598L174.154 179.121H174.199H175.774H177.35H178.925H180.501H182.077H183.652H185.228H186.803H188.379H189.955H191.53H193.106H194.681H196.257H197.833H199.408L199.416 176.825L199.423 174.521L199.43 172.21L199.438 169.892L199.445 167.566L199.453 165.233L199.46 162.893L199.468 160.545L199.475 158.189L199.482 155.827L199.49 153.457L199.497 151.072L199.505 148.68L199.512 146.28L199.52 143.873L199.527 141.459L199.817 141.452H201.125H202.433H203.741H205.049H206.357H207.665H208.973H210.281H211.589H212.897H214.205H215.513H216.821H218.129H219.437H220.745V142.478V143.504V144.53V145.557V146.583V147.602V148.621V149.64V150.659V151.677V152.689V153.7V154.712V155.723V156.728V157.732L221.154 157.82L221.667 158.101L222.938 159.171L223.309 159.4L223.978 159.267L224.707 159.4L224.9 159.378L225.041 158.92L225.108 158.824L225.212 158.839L225.844 159.245L225.963 159.408L226.334 159.991L226.431 160.685L226.632 160.788L227.018 160.87L227.954 160.914L229.144 161.364L229.627 161.431L230.481 161.305L231.284 161.911L231.566 161.999L231.797 161.918L232.25 161.475L233.239 161.527L234.049 161.446L234.108 161.955L234.249 162.324L234.918 162.715L235.082 162.9L235.112 163.52L235.282 163.675L235.55 163.734L235.832 163.697L236.159 163.505L236.88 162.893L237.103 162.745L237.237 162.73L237.371 162.76L237.482 162.893L237.728 163.358L238.352 163.609L238.709 164L238.932 164.059L239.177 163.985L239.563 163.742L239.868 163.756L240.217 163.513L240.359 163.565L240.418 163.734L240.314 164.251L240.373 164.443L240.515 164.672L240.708 164.834L240.894 164.857L241.035 164.724L241.295 164.074L241.28 163.838L241.577 163.756L241.711 163.631L241.882 163.158L242.187 163.033L242.35 163.055L242.499 163.188L242.796 163.616L243.502 163.86L243.688 163.875L243.874 163.786L244.193 163.432L244.357 163.387L244.491 163.439L244.565 163.491L244.595 163.912L245.323 164.384L245.858 164.524L246.378 165.004L246.527 165.056L246.78 164.672L247.278 164.532L247.753 164.133L249.136 163.624L249.686 163.786L250.243 163.779L250.392 163.557L251.373 163.232L251.573 163.107L251.848 163.269L251.945 163.505L252.071 163.601L252.748 163.72L253.119 163.705L253.803 163.402L254.071 163.018L254.227 162.996L254.717 163.181L256.003 163.956L256.657 164.583L257.385 164.886L257.779 165.152L259.377 165.551ZM255.49 202.054L255.141 202.127L256.664 200.909L256.984 200.503L257.393 200.518L256.709 201.204L255.49 202.054ZM243.428 209.88L243.168 209.909L243.487 209.488L244.008 209.274L245.145 208.462L245.606 208.403L245.851 208.123L245.955 208.078L245.888 208.425L244.974 208.913L243.428 209.88ZM241.674 211.844L241.525 211.866L241.867 211.224L241.927 210.965L242.484 210.153L242.774 210.035L242.9 210.382L242.328 210.95L241.674 211.844ZM239.303 216.539L239.088 216.99L239.147 216.325L239.712 214.804L240.864 212.804L241.347 212.471L240.017 214.664L239.303 216.539ZM240.581 225.37L240.485 225.724L239.905 224.056L238.961 220.261L238.924 218.09L239.073 217.344L239.318 220.408L240.359 224.285L240.581 225.37Z",id:"TX"},{d:"M143.475 92.22L143.482 93.3865V94.5457V95.7049V96.864V98.0158V99.1676V100.319V101.471H145.229H146.983H148.737H150.491H152.245H153.991H155.745H157.499V103.76V106.034V108.308V110.575V112.827V115.079V117.316V119.545V121.768V123.983V126.19V128.391V130.583V132.769V134.947V137.11H155.314H153.129H150.944L148.759 137.103H146.581H144.396H142.211H140.026L137.841 137.095H135.664H133.479H131.294L129.109 137.088H126.924H124.746H122.561V135.73V134.371V133.013V131.647V130.281L122.554 128.915V127.542V126.168V124.788V123.407V122.026V120.638V119.25V117.855V116.459V115.056V113.661V112.251V110.841L122.546 109.43V108.013V106.595V105.17V103.745V102.32V100.888V99.4482V98.0084V96.5687V95.1216V93.6745V92.22H123.854H125.162H126.47H127.778H129.086H130.394H131.702H133.01H134.318H135.627H136.935H138.243H139.551H140.859H142.167H143.475Z",id:"UT"},{d:"M376.617 116.459L377.019 116.791L377.962 117.183L378.349 117.581L378.178 117.988L378.156 118.283L378.334 118.549L379.59 119.08L380.363 119.833L380.839 120.062L380.98 120.129L381.322 120.313L381.478 120.542L381.374 121.554L381.047 122.056L380.534 122.44L379.865 123.119L379.702 123.747L379.493 124.92L379.776 125.319L380.066 125.422L380.92 125.157L381.359 125.275L382.34 126.685L384.168 127.239L384.837 127.586L385.38 128.317L386.197 128.738L386.829 129.35L386.844 129.749L386.621 130.222L386.532 130.857L386.264 131.255L385.617 131.3L385.224 131.196L383.12 128.952L382.868 128.745L382.087 127.571L381.173 126.936L380.891 126.951L382.191 128.117L382.719 128.93L383.655 130.067L384.324 130.546L384.815 131.3L385.276 131.654L386.524 132.156L386.093 132.518L386.784 132.828L386.881 133.389L386.814 134.031L385.855 133.78L385.825 134.253L385.915 134.533L385.491 134.762L384.904 134.452L383.373 132.747L383.388 132.976L383.514 133.241L384.406 134.341L385.201 134.999L385.878 135.294L386.398 135.848L386.584 136.18L386.703 136.682L386.316 137.022L385.878 137.214L385.446 136.874L385.134 136.512L384.465 135.899L384.265 135.213L383.759 135.25L381.634 134.378L379.924 134.275L380.088 134.452L380.304 134.57L381.664 134.785L382.199 135.183L383.313 135.538L383.967 135.634L384.235 136.719L385.142 137.465L385.261 138.018L385.878 138.077L386.963 137.531L387.661 137.723L388.672 137.878L388.902 138.314L389.073 139.148L389.43 140.086L389.66 141.001H389.437L388.895 140.994L387.156 140.979L384.622 140.957L382.087 140.935L379.553 140.913L377.019 140.89L374.484 140.868L371.95 140.846L369.416 140.824L366.881 140.802L364.347 140.78L361.813 140.758L359.278 140.735L356.744 140.713L354.21 140.691L351.675 140.669L349.141 140.647L349.022 140.514L348.026 140.477L347.298 140.447L346.971 140.625L345.507 140.617L344.34 140.61L342.363 140.602L339.955 140.588L336.559 140.573L334.976 140.566L335.682 140.152L336.73 139.908L338.595 139.207L339.338 138.491L340.386 137.967L340.825 137.339L341.523 136.741L341.783 136.062L341.88 135.958L343.032 135.346L344.243 134.578L346.889 132.459L346.941 132.739L346.845 133.042L347.068 133.396L347.253 133.95L347.513 134.29L347.84 134.563L348.383 134.807L349.022 135.235L349.528 135.353L349.698 135.338L350.256 134.925L350.717 134.703L351.2 134.253L352.062 134.866H352.404L353.251 134.6L354.046 134.526L354.247 134.445L354.544 134.194L354.552 133.684L354.618 133.551L354.752 133.492L354.908 133.478L355.265 133.662L355.614 133.67L357.101 133.079L357.212 133.123L357.398 133.396L358.052 133.049L358.438 132.725L358.609 132.237L358.929 131.757L358.862 131.543L358.654 131.263L358.929 130.613L359.33 129.971L360.846 128.021L361.33 126.84L361.961 126.08L362.169 125.474L362.645 124.876L362.972 123.636L363.173 123.385L363.463 123.34L363.76 123.495L363.975 123.724L364.117 124.094L364.882 124.418L365.521 124.455L365.967 124.219L366.227 123.783L366.577 122.964L366.911 122.477L367.127 121.864L367.349 121.443L367.691 121.177L368.553 121.192L368.999 120.815L369.341 120.387L369.549 120.247L369.795 120.269L370.575 119.582L371.601 118.143L371.824 117.234L372.091 116.577L372.195 115.905L372.396 115.536L373.303 116.267L373.823 116.688L375.012 117.648L375.8 118.283L376.112 117.552L376.617 116.459ZM393.926 128.066L394.112 128.044L393.362 129.38L393.042 129.52L393.926 128.066ZM391.08 128.804L391.355 128.405L392.41 128.265L393.064 128.176L391.518 131.624L391.585 132.259L391.273 132.466L390.805 132.629L390.329 133.005L390.017 133.419L389.727 134.541L389.163 135.796L388.813 135.272L388.724 134.821L388.88 133.647L389.49 131.72L390.158 130.517L390.671 129.948L391.08 128.804Z",id:"VA"},{d:"M413.413 85.383L412.73 85.3609L412.038 85.3313L411.355 85.3092L410.663 85.2796L409.972 85.2575L409.288 85.2279L408.597 85.2058L407.914 85.1763L407.728 84.6078L407.817 84.1204L407.832 83.4486L407.854 82.5847L407.869 81.6249L407.899 80.3181L407.914 79.4469L407.936 78.6568L407.958 77.5789L407.542 76.9734L407.371 76.8701L407.237 76.9365L406.947 77.3352L406.851 77.3279L406.776 77.2245L406.791 76.8627L407.051 75.578L407.059 75.1719L407.007 74.4853L406.71 72.92L406.702 72.5656L406.821 72.0267L407.022 71.4803L407.364 70.9266L407.438 70.6977L407.416 69.7378L407.52 68.8445L407.081 67.5081L407.245 65.773L407.126 64.9461L407.267 64.1782L407.222 63.5285L408.412 63.5211H411.325L414.231 63.5137L417.144 63.5063H420.057L419.946 63.6983L420.11 64.4736L419.337 65.8099L419.351 66.2382L419.701 67.4121L419.678 67.6853L419.567 67.8182L419.411 68.3203L419.21 68.6303L418.898 68.9404L417.902 69.6788L417.605 69.8634L416.668 70.107L416.46 70.3876L416.245 72.1669L415.94 73.1637L415.873 73.6214L415.464 74.4041L415.123 75.2975L414.602 76.0284L414.32 76.9144L414.142 77.254L413.986 77.8077L413.829 79.6831L413.614 80.7094L413.369 82.474L413.205 82.917L413.049 83.1532L412.834 83.9137L412.811 84.1943L412.908 84.4453L413.294 85.0507L413.413 85.383Z",id:"VT"},{d:"M102.576 53.6718H100.845H98.9866H97.1286H95.2706H93.4126H91.5546H89.6966H87.8386H87.7196L87.5116 53.8564L86.6197 54.2182L84.8583 54.3289L81.3207 55.2888L79.7674 56.0419L78.3999 56.411L75.8507 56.7654L73.5468 57.2675L72.5732 57.2232L72.1644 56.7949L71.0496 56.5513L69.2287 56.4922L67.6903 56.7802L66.2708 57.644L65.8175 57.7326L65.4459 57.7622L62.9413 57.4225L62.317 57.4004L61.7819 56.9426L61.6407 56.1895L60.9643 53.9155L60.2732 52.5496L59.5746 52.0992L59.0246 51.9146L58.326 52.1656L58.1105 52.0254L57.776 51.9885L57.0328 51.4864L56.6092 50.9843L55.3086 51.0212L55.041 50.6964L53.5918 51.0212L53.1459 50.689L52.3581 50.9031L52.5513 49.9654L52.5141 48.7841L52.5513 47.6323L52.7445 48.474L53.235 49.3674L53.4729 48.3559L53.6364 47.0786L53.1533 46.5839L52.3581 46.2221L52.0756 45.026L53.9634 44.0071L52.9601 43.793L52.5662 43.3353L52.0831 43.2762L52.0459 43.6306L51.8898 44.0957L51.7189 43.4829L51.6669 42.7594L51.4662 41.519L50.6933 39.5181L50.2251 36.9118L49.6379 35.6197L48.5083 34.3793L48.211 33.6558L47.9434 31.8173L48.0921 30.4219L47.884 29.4399L48.4265 29.499L49.8535 30.2742L51.6297 30.8797L52.1648 31.3227L53.0269 31.6475L57.7909 32.157L58.103 32.1053L58.7199 31.7878L58.98 31.8247L59.6786 32.5409L60.0279 32.6295L60.4813 32.5926L60.8157 32.4523L61.388 31.9576L61.4623 32.1422L61.4549 32.6L61.663 33.2497L62.0866 34.0914L62.2427 34.6156L61.388 36.0849L61.2245 36.1144L61.2022 35.6197L61.0907 35.5237L59.4854 38.0045L58.9205 39.1785L58.8611 39.7101L58.8834 40.0202L59.1063 40.094L59.6191 39.9759L60.3772 39.4886L60.4144 39.3852L59.7083 39.555L59.3665 39.5698L59.4111 39.016L59.4928 38.7502L59.9536 37.9307L60.4367 37.436L61.1279 36.9118L61.5292 36.4762L61.8042 35.8412L62.5697 35.0807L62.7109 34.8666L62.6811 34.2391L62.7332 34.1209L63.1048 34.2021L63.2609 35.2727L63.1717 35.7526L62.5102 36.3359L62.4285 36.5426L62.5474 37.34L62.4433 37.4139L62.1906 37.3179L62.1089 37.3696L62.7332 38.2334L62.9338 38.9053L62.9636 39.5033L62.7926 40.6477L62.6068 40.8397L62.2947 40.7733L61.8785 40.4189L61.7893 40.537L61.4623 41.423L61.3508 41.3418L61.1427 40.2933L61.0312 40.2121L60.3921 40.692L60.1394 41.1498L59.9164 41.8808L59.634 42.2204L60.4293 42.2942L61.1427 42.1465L61.715 42.4936L61.9082 42.5009L62.4359 42.1613L62.5994 41.9324L63.0305 40.8249L63.246 40.6256L63.573 40.6182L63.8851 40.4484L64.3459 39.843L64.3608 39.5993L64.1899 38.2334L64.2419 37.4582L64.1527 37.2145L63.9446 36.9561L63.9743 36.7051L64.1378 36.299L64.1527 35.9298L64.0115 35.5976L64.0709 35.221L64.5094 34.4163L64.5912 34.0618L65.1263 33.2571L64.9925 32.9322L64.5986 32.5335L64.3533 32.1865L64.1007 31.6401L63.9074 31.4556L63.848 31.5368L64.1155 32.4301L64.0561 32.4892L63.3649 32.0093L63.2014 31.7066L63.1196 31.2931L63.1791 30.983L63.5507 30.6803L63.9966 30.5696L63.9595 30.3112L63.4021 29.4768L63.0305 29.0929L62.7406 28.9083L62.3541 28.8566L62.1832 28.7164L62.1386 28.517L62.2204 28.2586L62.4285 28.1774L63.023 28.2808L63.3426 28.0962L63.3129 27.7639L63.2163 27.5793L63.2311 26.3832L63.0007 25.4087L62.8818 25.2462L62.7555 25.2315L62.6217 25.3644L62.2501 25.4013L62.0197 25.0838L61.767 24.4636L61.3062 22.9869H62.0197H64.9999H67.9802H70.9604H73.9407H76.9209H79.9011H82.8814H85.8616H88.8419H91.8221H94.8024H97.7826H100.763H101.491L101.506 24.6703L101.513 26.3537L101.521 28.0371L101.528 29.7131L101.536 31.3817L101.543 33.043L101.551 34.7042L101.558 36.3581L101.565 38.0045L101.573 39.651L101.58 41.2901L101.588 42.9218L101.595 44.5535L101.603 46.1778L101.61 47.7947L101.618 49.4117L101.565 49.5077L101.521 49.7439L101.722 50.4158L102.19 51.3904L102.338 52.077L102.16 52.4684L102.286 53.1476L102.576 53.6718ZM61.4029 26.3611L61.4995 26.59L61.217 26.8115L61.0164 26.8484L60.6968 26.494L60.5556 26.4497L60.6671 26.9961L60.6299 27.1807L59.9759 26.841L59.857 26.5752L60.0428 26.2947L60.4515 25.9993L60.5927 25.9624L61.4029 26.3611ZM59.7827 28.1626L59.9685 28.5022L59.2178 28.2808L58.8983 28.0814L58.8016 27.8894L58.6901 27.2545L58.7422 27.0477L59.0766 26.9739L59.7083 27.7565L59.7827 28.1626ZM61.1279 28.8862L61.0164 28.9895L60.6448 28.8493L60.4218 28.613L60.3475 28.3251L60.4887 27.7713L60.6745 27.631L60.7934 27.6606L60.8454 28.1479L61.1799 28.6647L61.1279 28.8862ZM62.8669 31.7509L63.2088 33.1094L63.3575 32.5409L64.3088 33.5229V34.0028L64.1899 34.1652L63.9892 34.2243L63.8034 34.084L63.6325 33.7444L63.4169 33.5672L62.9636 33.449L62.7257 33.0651L62.644 32.7993L62.6217 32.0388L62.5102 31.8026L62.2649 31.7509L62.0346 31.5663L61.6778 31.0347L61.6258 30.8944L61.7967 30.4588L62.1832 29.7279L62.4656 29.3809L62.644 29.4178L62.8595 29.6393L63.1196 30.038L63.0751 30.3185L62.0271 30.8723L61.99 30.9978L62.4953 31.1529L62.6811 31.2931L62.8669 31.7509ZM63.3946 37.5541L63.3575 37.7535L62.971 37.5172L62.8447 37.3031L62.8595 36.8158L62.9561 36.4983L63.0305 36.4319L63.2609 36.5722L63.3277 36.6534L63.3946 37.5541ZM64.1155 39.5993L64.0858 39.8356L63.8183 40.0202L63.677 39.9759L63.6696 39.7027L63.5953 39.6584L63.3054 39.9906L63.3277 39.3409L63.4689 38.6542L63.5953 38.6395L63.7811 39.0899L64.1155 39.5993ZM60.9049 41.5485L60.838 41.7478L60.7414 41.7405L60.5259 41.3344L60.4961 41.0464L60.6819 40.8397L60.9346 41.4378L60.9049 41.5485Z",id:"WA"},{d:"M287.767 43.3648L287.537 43.5272L287.448 43.4534L287.5 43.1433L287.619 42.9587L287.797 42.907L287.886 42.9809V43.1802L287.767 43.3648ZM285.798 44.3689L285.694 44.4428L285.426 44.273L285.389 44.1327L285.463 43.9924L285.59 44.0219L285.768 44.2287L285.798 44.3689ZM287.894 47.7505L287.857 47.8317L287.998 48.2009L288.355 48.1049L288.511 48.3264L288.726 48.4223L289.127 48.5995L289.321 49.0204L289.514 49.4412L289.707 49.8621L289.9 50.2829L290.777 50.5266L291.654 50.7702L292.531 51.0139L293.408 51.2575L294.285 51.5012L295.162 51.7448L296.039 51.9885L296.916 52.2321L297.407 52.5127L297.897 52.7933L298.388 53.0738L298.878 53.3544L299.651 53.4061L300.335 53.5759L301.294 53.5832L302.26 53.7974L303.679 54.2625L304.014 54.6612L304.073 54.927L303.932 55.5472L305.285 56.1009L305.864 56.5144L306.08 56.8319L306.043 57.1198L306.177 57.7253L306.035 58.0501V58.6186L305.731 59.2167L305.627 59.5416L305.619 59.8147L305.686 59.9919L305.85 60.0584L306.362 60.0215L306.868 59.8369L307.091 59.9476L307.135 60.0436L307.098 60.206L306.689 61.2176L306.704 61.6236L306.875 62.0223L307.158 62.4063L307.492 62.5392L307.477 62.7902L307.343 63.2849L306.949 63.6762L305.924 64.1709L305.76 64.5031L305.738 64.7763L305.077 65.9133L304.75 66.6074L304.534 67.3309L304.601 67.7887L304.95 67.9733L305.233 67.8994L305.448 67.5672L305.775 67.2718L306.221 67.0061L306.548 66.6147L307.001 65.6549L307.507 65.1012L307.774 65.0716L307.849 65.0864L308.376 64.8354L308.8 64.9166L309.053 65.2931L309.313 65.5516L309.372 65.7952L309.239 66.3342L309.001 66.9027L308.651 67.5007L308.332 68.3941L308.049 69.5902L307.99 70.491L308.153 71.0964L307.997 71.6354L307.522 72.1079L307.135 72.7429L306.845 73.5403L306.682 74.2047L306.645 74.7437L306.689 75.1498L306.868 75.6962L306.853 75.9693L306.333 77.1654L306.147 77.7487L306.117 78.2065L305.991 78.6569L305.597 79.5724L305.47 80.0818L305.448 80.547L305.537 81.3074L305.485 81.5659L305.508 81.7578L305.604 81.8907V82.127L305.5 82.474L305.537 82.7472L305.716 82.9391L305.835 83.3083L305.887 83.8547L306.02 84.305L306.243 84.6669L306.281 85.191L306.139 85.8777L306.065 87.1697V87.598L305.173 87.5906L302.022 87.5685L298.871 87.5463L295.72 87.5242L292.568 87.502L289.417 87.4799L286.199 87.4577L286.155 87.3839L285.939 86.5422L285.233 85.9146L284.037 85.5085L283.271 84.8662L282.937 83.9876L282.721 82.9982L282.632 81.8981L282.728 80.9752L283.011 80.2295L282.937 79.7274L282.506 79.4616L282.223 79.1146L282.089 78.6864L282.037 78.0957L281.807 75.2753L281.517 73.9389L281.079 73.4147L280.157 72.8019L278.745 72.1079L277.875 71.4582L277.377 70.5426L276.382 69.4647L275.728 69.0217L275.088 68.8592L274.583 68.5122L274.204 67.9806L273.684 67.6484L273.015 67.5081L272.272 67.0725L271.387 66.2899L271.365 66.2308L271.179 65.6623L271.283 65.3448L271.432 64.2521L271.417 63.9051L271.224 62.9083L271.462 62.5244L271.41 61.2914L271.491 60.8853L271.967 59.8738L271.989 59.357L271.818 58.7589L271.469 58.2716L270.525 57.7622L270.495 57.1272L270.651 56.6547L271.268 55.7687L271.61 54.9787L271.922 54.6391L273.81 53.4577L274.211 53.3765L274.501 53.0369L274.732 52.8892V51.4495V50.0024V48.5552V47.1007L275.207 46.9974L275.415 46.6356L275.898 46.0671L276.025 46.0745V46.0819L276.263 46.3403L276.857 46.7168L277.325 46.7611L277.92 46.6799L280.276 46.0302L281.272 45.5798L282.245 44.8193L282.342 44.7972L282.751 44.9374L282.877 45.0039L284.148 44.1327L284.564 44.0219L284.891 44.0441L285.3 44.3837L285.397 44.5904L285.263 44.9891L284.899 45.5798L284.72 46.0745L284.728 46.4805L284.572 46.9162L284.17 47.5068L284.312 47.6693L285.382 47.241L285.538 47.0786L285.553 46.9826L285.486 46.8645L285.612 46.8128L286.452 47.3961L287.017 47.7209L287.485 47.876L287.894 47.7505ZM286.928 44.4501L286.697 44.5092L286.192 44.4206L286.199 44.273L286.719 44.0662L286.95 44.0071L287.002 44.0958L286.928 44.4501ZM285.776 45.8234L285.374 45.9637L285.211 45.9342L285.278 45.7422L285.486 45.5133L286.415 44.9448L286.578 44.9522L286.63 45.0851L286.177 45.3657L286.006 45.5133L285.984 45.6684L285.776 45.8234ZM312.702 60.1175L312.494 60.2134L312.107 60.1765L311.966 59.955L312.167 59.3865L312.248 59.4899L312.583 59.4973L312.702 59.5563L312.739 59.6966L312.702 60.1175ZM311.795 61.2102L311.669 61.3357L311.453 61.2545L311.371 61.4391L311.416 61.8894L311.342 62.0962L311.149 62.0593L311.141 62.1405L311.312 62.3398L311.327 62.5613L311.193 62.7976L311.067 62.9083L310.94 62.8936L310.747 63.1667L310.487 63.7279L310.398 64.0527L310.48 64.1413L310.42 64.3259L309.774 65.175L309.528 65.2562L309.253 65.1381L309.06 64.887L308.949 64.5105L308.919 64.2152L308.964 64.0084L309.528 63.2553L309.781 62.7607L309.922 62.2069L310.182 61.8525L310.569 61.6975L310.881 61.3505L311.119 60.8115L311.394 60.5752L311.706 60.6417L311.84 60.8484L311.795 61.2102Z",id:"WI"},{d:"M364.369 113.078L364.347 114.23L364.332 115.381L364.31 116.526L364.295 117.67L365.187 117.006L365.655 116.769L367.179 115.3L367.379 115.293L367.907 115.499L368.999 114.451L369.133 114.074L369.26 113.949L369.401 113.964L369.483 114.06L369.43 114.281L369.512 114.385L369.966 114.636L370.59 114.776L370.679 114.791L371.236 114.783L371.482 114.577L371.608 114.17L371.861 113.934L372.426 113.831L373.436 113.417L374.016 113.484L374.514 113.905L375.012 114.104L375.517 114.089L375.718 114.185L375.599 114.399L375.733 114.65L376.112 114.931L376.246 115.189L376.119 115.426L376.164 115.603L376.365 115.721L376.491 115.979L376.528 116.385L376.617 116.459L376.164 117.53L375.852 118.261L375.064 117.626L373.875 116.666L373.355 116.245L372.448 115.514L372.247 115.883L372.143 116.555L371.876 117.212L371.66 118.121L370.634 119.56L369.854 120.247L369.616 120.232L369.408 120.372L369.066 120.801L368.628 121.17L367.766 121.155L367.416 121.421L367.193 121.849L366.978 122.462L366.643 122.942L366.287 123.761L366.027 124.197L365.581 124.433L364.934 124.396L364.176 124.064L364.035 123.695L363.819 123.466L363.522 123.311L363.232 123.348L363.032 123.599L362.705 124.839L362.229 125.437L362.021 126.05L361.389 126.811L360.906 127.992L359.397 129.941L358.988 130.583L358.714 131.226L358.922 131.506L358.988 131.72L358.669 132.2L358.498 132.688L358.112 133.013L357.465 133.36L357.272 133.086L357.16 133.042L355.674 133.64L355.325 133.633L354.968 133.441L354.812 133.456L354.678 133.522L354.611 133.648L354.604 134.164L354.306 134.415L354.106 134.497L353.31 134.57L352.471 134.836H352.129L351.267 134.223L350.784 134.674L350.315 134.888L349.765 135.301L349.594 135.316L349.089 135.198L348.45 134.77L347.915 134.526L347.588 134.26L347.328 133.913L347.142 133.36L346.919 133.013L347.016 132.71L346.963 132.429L345.997 132.156L344.756 131.137L343.961 129.904L343.708 129.328L343.418 128.937L343.344 128.546L342.601 127.519L342.4 127.076L342.385 126.796L342.623 126.264L342.675 126.006L342.593 124.692L342.43 124.448L343.24 124.743L344.013 124.573L344.496 124.167L344.682 123.532L344.957 123.156L345.299 123.053L345.462 122.772L345.403 122.085L345.299 121.613L345.574 120.934L346.213 119.885L346.711 119.457L347.068 119.649L347.29 119.974L347.365 120.439L347.439 120.498L347.543 120.491L347.811 120.136L348.056 119.996L348.153 120.033L348.257 120.025L348.272 119.796L348.086 119.162L348.101 118.785L348.324 118.674L348.561 118.246L348.814 117.508L349.119 117.124L349.476 117.109L349.855 116.806L350.271 116.216L350.642 116.046L350.969 116.297L351.386 116.312L351.876 116.097L352.738 115.477L353.972 114.444L354.596 113.609L354.611 112.967L355.087 111.402L356.038 108.906L356.499 107.282L356.484 106.544L356.35 105.938L356.097 105.473L356.254 105.104L357.078 104.705L357.071 105.754V106.802V107.858V108.906V109.955L357.078 110.996V112.044V113.085H357.985H358.899H359.813H360.72H361.634H362.541H363.455L364.369 113.078Z",id:"WV"},{d:"M192.6 82.8284L192.608 85.191L192.615 87.5389L192.623 89.8868L192.63 92.2199V94.5457L192.638 96.864L192.645 99.1675L192.652 101.471H190.453H188.26H186.06H183.86H181.668H179.468H177.276H175.076H172.876H170.683H168.483H166.284H164.091H161.891H159.691H157.499H155.745H153.991H152.245H150.491H148.737H146.983H145.229H143.482V100.319V99.1675V98.0158V96.864V95.7048V94.5457V93.3865L143.475 92.2199V90.7654V89.3035V87.8416V86.3724V84.9031V83.4264V81.9498V80.4658V78.9817V77.4903V75.9988V74.5001V72.9939V71.4877L143.467 69.9815V68.4679L143.475 67.2423V66.024V64.7984V63.5654H145.006H146.544H148.075H149.606H151.145H152.676H154.207H155.745H157.276H158.807H160.338H161.876H163.407H164.938H166.477H168.008H169.539H171.077H172.608H174.139H175.678H177.209H178.74H180.278H181.809H183.34H184.879H186.41H187.941H189.479H191.01H192.541L192.548 66.0093L192.556 68.4458L192.563 70.8675L192.571 73.2744L192.578 75.6814L192.586 78.0735L192.593 80.451L192.6 82.8284Z",id:"WY"}];function $A(e){let t,n;return{c(){t=Ji("title"),n=Cr(e[2])},m(i,s){$t(i,t,s),Ve(t,n)},p(i,s){s&4&&Lh(n,i[2])},d(i){i&&Pt(t)}}}function yke(e){let t,n,i,s,o,c=e[2]&&$A(e);return{c(){t=Ji("path"),c&&c.c(),Ee(t,"d",e[0]),Ee(t,"stroke",n=e[7]?e[5]:e[3]),Ee(t,"fill",e[1]),Ee(t,"stroke-width",i=e[7]?e[6]:e[4])},m(d,f){$t(d,t,f),c&&c.m(t,null),s||(o=[Ri(t,"click",e[9]),Ri(t,"mouseenter",e[10]),Ri(t,"mouseleave",e[11])],s=!0)},p(d,[f]){d[2]?c?c.p(d,f):(c=$A(d),c.c(),c.m(t,null)):c&&(c.d(1),c=null),f&1&&Ee(t,"d",d[0]),f&168&&n!==(n=d[7]?d[5]:d[3])&&Ee(t,"stroke",n),f&2&&Ee(t,"fill",d[1]),f&208&&i!==(i=d[7]?d[6]:d[4])&&Ee(t,"stroke-width",i)},i:Yn,o:Yn,d(d){d&&Pt(t),c&&c.d(),s=!1,Xo(o)}}}function mke(e,t,n){let{d:i}=t,{fill:s}=t,{title:o=""}=t,{stroke:c="hsla(0, 0%, 0%, 0.075)"}=t,{strokeWidth:d=.75}=t,{hoveringStroke:f="black"}=t,{hoveringStrokeWidth:u=1}=t;const a=sf();let m=!1;function y(b){rn.call(this,e,b)}const p=()=>{n(7,m=!0),a("mouseenter")},l=()=>{n(7,m=!1),a("mouseleave")};return e.$$set=b=>{"d"in b&&n(0,i=b.d),"fill"in b&&n(1,s=b.fill),"title"in b&&n(2,o=b.title),"stroke"in b&&n(3,c=b.stroke),"strokeWidth"in b&&n(4,d=b.strokeWidth),"hoveringStroke"in b&&n(5,f=b.hoveringStroke),"hoveringStrokeWidth"in b&&n(6,u=b.hoveringStrokeWidth)},[i,s,o,c,d,f,u,m,a,y,p,l]}class wke extends Vi{constructor(t){super(),qi(this,t,mke,yke,$i,{d:0,fill:1,title:2,stroke:3,strokeWidth:4,hoveringStroke:5,hoveringStrokeWidth:6})}}function qA(e,t,n){const i=e.slice();i[12]=t[n];const s=i[1].get(i[12].id)??i[3];return i[13]=s,i}function VA(e){let t,n;function i(){return e[11](e[12])}return t=new wke({props:{title:e[12].id,d:e[12].d,fill:e[13].fill??e[3].fill,stroke:e[13].stroke??e[3].stroke}}),t.$on("click",i),{c(){Nn(t.$$.fragment)},m(s,o){bn(t,s,o),n=!0},p(s,o){e=s;const c={};o&10&&(c.fill=e[13].fill??e[3].fill),o&10&&(c.stroke=e[13].stroke??e[3].stroke),t.$set(c)},i(s){n||(wt(t.$$.fragment,s),n=!0)},o(s){Rt(t.$$.fragment,s),n=!1},d(s){Tn(t,s)}}}function Lke(e){let t,n,i,s,o,c,d,f,u=l4,a=[];for(let y=0;yRt(a[y],1,1,()=>{a[y]=null});return{c(){t=Ji("svg"),n=Ji("g");for(let y=0;y{b.key==="Shift"&&n(4,u=!1)},p=b=>{b.key==="Shift"&&n(4,u=!0)},l=b=>{const L=f.includes(b.id);u?L?n(0,f=f.filter(E=>E!==b.id)):(f.push(b.id),n(0,f)):L&&f.length===1?n(0,f=[]):n(0,f=[b.id]),i("select",f)};return e.$$set=b=>{"stateToStyle"in b&&n(1,s=b.stateToStyle),"width"in b&&n(2,o=b.width),"defaultFill"in b&&n(6,c=b.defaultFill),"defaultStyle"in b&&n(3,d=b.defaultStyle),"selected"in b&&n(0,f=b.selected)},[f,s,o,d,u,i,c,a,m,y,p,l]}class Tke extends Vi{constructor(t){super(),qi(this,t,bke,Lke,$i,{stateToStyle:1,width:2,defaultFill:6,defaultStyle:3,selected:0})}}function GA(e,t,n){const i=e.slice();i[13]=t[n],i[17]=n;const s=i[0]/i[4].length;i[14]=s;const o=1/i[4].length*i[0];return i[15]=o,i}function WA(e){let t,n,i;return{c(){t=Ji("rect"),Ee(t,"x",n=e[17]*e[14]),Ee(t,"y",0),Ee(t,"height",e[1]),Ee(t,"width",i=e[15]),Ee(t,"fill",e[13])},m(s,o){$t(s,t,o)},p(s,o){o&1&&n!==(n=s[17]*s[14])&&Ee(t,"x",n),o&2&&Ee(t,"height",s[1]),o&1&&i!==(i=s[15])&&Ee(t,"width",i)},d(s){s&&Pt(t)}}}function vke(e){let t,n,i,s,o,c,d,f,u,a,m,y,p,l,b=e[4],L=[];for(let E=0;E1?M=1:M<0&&(M=0);const C=L(M);F[O]=Ql(C).hex(),M+=k}return F}function b(L){Wl[L?"unshift":"push"](()=>{y=L,n(3,y)})}return e.$$set=L=>{"data"in L&&n(5,o=L.data),"numberToColor"in L&&n(6,c=L.numberToColor),"width"in L&&n(0,d=L.width),"height"in L&&n(1,f=L.height),"title"in L&&n(2,u=L.title)},e.$$.update=()=>{e.$$.dirty&32&&n(7,[a,m]=xR(o),m),e.$$.dirty&129&&n(9,i=U4().domain([0,m]).range([0,d]).nice()),e.$$.dirty&512&&n(8,s=wQ(i).ticks(3)),e.$$.dirty&264&&y&&tte(y).transition().call(s)},[d,f,u,y,p,o,c,m,s,i,b]}class Ske extends Vi{constructor(t){super(),qi(this,t,Eke,vke,$i,{data:5,numberToColor:6,width:0,height:1,title:2})}}function xke(e){let t,n,i,s,o,c;return t=new Nb({props:{title:e[1],selection:e[6].length>0?e[6]:null}}),t.$on("reset",e[9]),i=new Tke({props:{width:e[3],stateToStyle:e[4]}}),i.$on("mouseenter",e[10]),i.$on("mouseleave",e[11]),i.$on("select",e[12]),o=new Ske({props:{title:e[1]+" Density",data:e[0].filter,numberToColor:e[2],width:200,height:10}}),{c(){Nn(t.$$.fragment),n=pn(),Nn(i.$$.fragment),s=pn(),Nn(o.$$.fragment)},m(d,f){bn(t,d,f),$t(d,n,f),bn(i,d,f),$t(d,s,f),bn(o,d,f),c=!0},p(d,[f]){const u={};f&2&&(u.title=d[1]),f&64&&(u.selection=d[6].length>0?d[6]:null),t.$set(u);const a={};f&8&&(a.width=d[3]),f&16&&(a.stateToStyle=d[4]),i.$set(a);const m={};f&2&&(m.title=d[1]+" Density"),f&1&&(m.data=d[0].filter),f&4&&(m.numberToColor=d[2]),o.$set(m)},i(d){c||(wt(t.$$.fragment,d),wt(i.$$.fragment,d),wt(o.$$.fragment,d),c=!0)},o(d){Rt(t.$$.fragment,d),Rt(i.$$.fragment,d),Rt(o.$$.fragment,d),c=!1},d(d){Tn(t,d),d&&Pt(n),Tn(i,d),d&&Pt(s),Tn(o,d)}}}function kke(e,t,n){const i=sf(),s=dP(["rgb(255,255,255)",hx]);let{state:o}=t,{title:c=""}=t,{numberToColor:d=x=>s(x)}=t,{width:f=600}=t,u=new Map(l4.map(x=>[x.id,{fill:"white"}])),a=structuredClone(u);function m(x){n(4,u=y(x)),n(5,a=structuredClone(u))}function y(x){const F=x.bin,k=x.filter;let[M,O]=xR(k);O<=0&&(O=1);for(let C=0;C0?(n(4,u=structuredClone(a)),x.forEach(F=>{u.set(F,{...u.get(F),stroke:"hsla(0, 0%, 0%, 0.5)"})}),n(4,u)):(l4.forEach(F=>{u.set(F.id,{fill:u.get(F.id).fill})}),n(4,u))}const b=()=>{n(6,p=[]),l(p),i("select",null)};function L(x){rn.call(this,e,x)}function E(x){rn.call(this,e,x)}const S=async x=>{n(6,p=x.detail),x.detail.length>0?(l(p),i("select",p)):(n(4,u=structuredClone(a)),i("select",null))};return e.$$set=x=>{"state"in x&&n(0,o=x.state),"title"in x&&n(1,c=x.title),"numberToColor"in x&&n(2,d=x.numberToColor),"width"in x&&n(3,f=x.width)},e.$$.update=()=>{e.$$.dirty&1&&o&&m(o)},[o,c,d,f,u,a,p,i,l,b,L,E,S]}class Bke extends Vi{constructor(t){super(),qi(this,t,kke,xke,$i,{state:0,title:1,numberToColor:2,width:3})}}function YA(e,t,n){const i=e.slice();return i[30]=t[n],i}function XA(e,t,n){const i=e.slice();return i[33]=t[n],i}function KA(e,t,n){const i=e.slice();return i[33]=t[n],i}function ZA(e){let t,n;return t=new N6({props:{title:"Distance Flown",dimLabel:"Distance in miles",bins:e[0].bin,filteredCounts:e[0].filter,totalCounts:e[0].total}}),t.$on("mouseenter",e[15]),t.$on("select",e[16]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,s){const o={};s[0]&1&&(o.bins=i[0].bin),s[0]&1&&(o.filteredCounts=i[0].filter),s[0]&1&&(o.totalCounts=i[0].total),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function JA(e){let t,n;return t=new N6({props:{title:"Arrival Flight Delay",dimLabel:"Delay in + minutes",bins:e[1].bin,filteredCounts:e[1].filter,totalCounts:e[1].total}}),t.$on("mouseenter",e[17]),t.$on("select",e[18]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,s){const o={};s[0]&2&&(o.bins=i[1].bin),s[0]&2&&(o.filteredCounts=i[1].filter),s[0]&2&&(o.totalCounts=i[1].total),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function QA(e){let t,n;return t=new N6({props:{title:"Departure Flight Delay",dimLabel:"Delay in + minutes",bins:e[2].bin,filteredCounts:e[2].filter,totalCounts:e[2].total}}),t.$on("mouseenter",e[19]),t.$on("select",e[20]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,s){const o={};s[0]&4&&(o.bins=i[2].bin),s[0]&4&&(o.filteredCounts=i[2].filter),s[0]&4&&(o.totalCounts=i[2].total),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function eN(e){let t,n;return t=new N6({props:{timeUnit:"",type:"temporal",title:"Flight Date",dimLabel:"Time of flight",bins:e[3].bin,filteredCounts:e[3].filter,totalCounts:e[3].total}}),t.$on("mouseenter",e[21]),t.$on("select",e[22]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,s){const o={};s[0]&8&&(o.bins=i[3].bin),s[0]&8&&(o.filteredCounts=i[3].filter),s[0]&8&&(o.totalCounts=i[3].total),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function tN(e){let t,n;return t=new Bke({props:{width:700,title:"Origin Airport Location by State",state:e[4]}}),t.$on("mouseenter",e[23]),t.$on("select",e[24]),{c(){Nn(t.$$.fragment)},m(i,s){bn(t,i,s),n=!0},p(i,s){const o={};s[0]&16&&(o.state=i[4]),t.$set(o)},i(i){n||(wt(t.$$.fragment,i),n=!0)},o(i){Rt(t.$$.fragment,i),n=!1},d(i){Tn(t,i)}}}function nN(e){let t,n,i,s,o,c,d,f,u,a=e[13]&&e[11]&&iN(e);return{c(){t=Tt("div"),n=Tt("button"),n.textContent="back",i=pn(),s=Tt("button"),s.textContent="next",o=pn(),c=Tt("div"),d=Tt("table"),a&&a.c(),Ee(d,"id","table"),Ee(d,"class","svelte-1q815rq"),Ee(c,"id","images")},m(m,y){$t(m,t,y),Ve(t,n),Ve(t,i),Ve(t,s),$t(m,o,y),$t(m,c,y),Ve(c,d),a&&a.m(d,null),f||(u=[Ri(n,"click",e[25]),Ri(s,"click",e[26])],f=!0)},p(m,y){m[13]&&m[11]?a?a.p(m,y):(a=iN(m),a.c(),a.m(d,null)):a&&(a.d(1),a=null)},d(m){m&&Pt(t),m&&Pt(o),m&&Pt(c),a&&a.d(),f=!1,Xo(u)}}}function iN(e){let t,n,i,s=e[14],o=[];for(let f=0;fFalconVis Logo',s=pn(),Nn(o.$$.fragment),c=pn(),d=Tt("main"),f=Tt("div"),u=Tt("div"),a=Tt("div"),M&&M.c(),m=pn(),O&&O.c(),y=pn(),C&&C.c(),p=pn(),P&&P.c(),l=pn(),b=Tt("div"),j&&j.c(),L=pn(),E=Tt("div"),S=Tt("div"),Nn(x.$$.fragment),F=pn(),R&&R.c(),document.title="FalconVis | 30 million",Ee(n,"class","svelte-1q815rq"),Ee(a,"id","hists"),Ee(a,"class","svelte-1q815rq"),Ee(b,"id","maps"),Ee(b,"class","svelte-1q815rq"),Ee(u,"id","charts"),Ee(u,"class","svelte-1q815rq"),Ee(E,"id","table"),Ee(E,"class","svelte-1q815rq"),Ee(f,"id","vis"),Ee(f,"class","svelte-1q815rq"),Ee(d,"class","svelte-1q815rq")},m(Y,$){$t(Y,t,$),$t(Y,n,$),Ve(n,i),Ve(n,s),bn(o,n,null),$t(Y,c,$),$t(Y,d,$),Ve(d,f),Ve(f,u),Ve(u,a),M&&M.m(a,null),Ve(a,m),O&&O.m(a,null),Ve(a,y),C&&C.m(a,null),Ve(a,p),P&&P.m(a,null),Ve(u,l),Ve(u,b),j&&j.m(b,null),Ve(f,L),Ve(f,E),Ve(E,S),bn(x,S,null),Ve(E,F),R&&R.m(E,null),k=!0},p(Y,$){var X,G;Y[5]&&Y[0]?M?(M.p(Y,$),$[0]&33&&wt(M,1)):(M=ZA(Y),M.c(),wt(M,1),M.m(a,m)):M&&(qf(),Rt(M,1,1,()=>{M=null}),Vf()),Y[5]&&Y[1]?O?(O.p(Y,$),$[0]&34&&wt(O,1)):(O=JA(Y),O.c(),wt(O,1),O.m(a,y)):O&&(qf(),Rt(O,1,1,()=>{O=null}),Vf()),Y[5]&&Y[2]?C?(C.p(Y,$),$[0]&36&&wt(C,1)):(C=QA(Y),C.c(),wt(C,1),C.m(a,p)):C&&(qf(),Rt(C,1,1,()=>{C=null}),Vf()),Y[5]&&Y[3]?P?(P.p(Y,$),$[0]&40&&wt(P,1)):(P=eN(Y),P.c(),wt(P,1),P.m(a,null)):P&&(qf(),Rt(P,1,1,()=>{P=null}),Vf()),Y[5]&&Y[4]?j?(j.p(Y,$),$[0]&48&&wt(j,1)):(j=tN(Y),j.c(),wt(j,1),j.m(b,null)):j&&(qf(),Rt(j,1,1,()=>{j=null}),Vf());const W={};$[0]&2048&&(W.filteredCount=((X=Y[11])==null?void 0:X.filter)??0),$[0]&2048&&(W.totalCount=((G=Y[11])==null?void 0:G.total)??0),x.$set(W),Y[13]?R?R.p(Y,$):(R=nN(Y),R.c(),R.m(E,null)):R&&(R.d(1),R=null)},i(Y){k||(wt(o.$$.fragment,Y),wt(M),wt(O),wt(C),wt(P),wt(j),wt(x.$$.fragment,Y),k=!0)},o(Y){Rt(o.$$.fragment,Y),Rt(M),Rt(O),Rt(C),Rt(P),Rt(j),Rt(x.$$.fragment,Y),k=!1},d(Y){Y&&Pt(t),Y&&Pt(n),Tn(o),Y&&Pt(c),Y&&Pt(d),M&&M.d(),O&&O.d(),C&&C.d(),P&&P.d(),j&&j.d(),Tn(x),R&&R.d()}}}let zf=25;function Ike(e,t,n){let i,s,o,c,d,f,u,a,m,y,p,l;FY(async()=>{const W=new Gle("query/","flights",new Map([["FlightDate","epoch(FlightDate)*1000"]]),X=>X);n(5,i=new Kle(W)),await i.view0D(X=>{n(11,u=X)}),n(6,s=await i.view1D({type:"continuous",name:"Distance",resolution:400,bins:5})),s.onChange(X=>{n(0,a=X)}),n(7,o=await i.view1D({type:"continuous",name:"ArrDelay",resolution:400,range:[-20,60],bins:5})),o.onChange(X=>{n(1,m=X)}),n(8,c=await i.view1D({type:"continuous",name:"DepDelay",resolution:400,range:[-20,60],bins:5})),c.onChange(X=>{n(2,y=X)}),n(9,d=await i.view1D({type:"continuous",name:"FlightDate",resolution:400,bins:25,time:!0})),d.onChange(X=>{n(3,p=X)}),n(10,f=await i.view1D({type:"categorical",name:"OriginState"})),f.onChange(X=>{n(4,l=X)}),await i.link(),n(13,L=await i.entries({length:zf,offset:b}))});let b=0,L,E=!0;async function S(W,X=0){i&&E&&(E=!1,n(13,L=await i.entries({length:zf,offset:b})),await new Promise(G=>setTimeout(G,X)),E=!0)}let x=["FlightDate","OriginState","DestState","DepDelay","ArrDelay","Distance"];const F=async()=>{await s.activate()},k=async W=>{const X=W.detail;X!==null?await s.select(X):await s.select()},M=async()=>{await o.activate()},O=async W=>{const X=W.detail;X!==null?await o.select(X):await o.select()},C=async()=>{await c.activate()},P=async W=>{const X=W.detail;X!==null?await c.select(X):await c.select()},j=async()=>{await d.activate()},R=async W=>{const X=W.detail;X!==null?await d.select(X):await d.select()},H=async()=>{await f.activate()},z=async W=>{const X=W.detail;X!==null?await f.select(X):await f.select()},Y=async()=>{n(12,b=Math.max(b-zf,0)),n(13,L=await i.entries({length:zf,offset:b}))},$=async()=>{n(12,b+=zf),n(13,L=await i.entries({length:zf,offset:b}))};return e.$$.update=()=>{e.$$.dirty[0]&31&&S()},[a,m,y,p,l,i,s,o,c,d,f,u,b,L,x,F,k,M,O,C,P,j,R,H,z,Y,$]}class Oke extends Vi{constructor(t){super(),qi(this,t,Ike,Fke,$i,{},null,[-1,-1])}}new Oke({target:document.getElementById("app")})});export default Mke();