|
import{s as Ge,c as hi,e as z,b as j,d as V,g as b,h as S,i as p,u as di,m as mi,n as yi,aa as Xt,a as R,f as Y,R as M,j as B,l as Ae,q as yt,ac as ui,w as ue,x as ce,ad as Ui,y as ge,ae as al,C as Kt,af as xl,r as be,p as Rt,z as re,v as ht,t as et,F as $l,ag as en,E as Hl,ah as Vi,U as Xi,A as gt,B as bt,X as ul,a9 as tn,V as Yt,Y as Ri,M as li,N as ni,L as ln,ai as nn,D as Yi,aj as rn,ak as sn}from"../chunks/scheduler.CTFCZgrd.js";import{S as Ne,i as Pe,t as G,a as H,b as se,d as oe,m as fe,j as Zi,f as it,e as ae,g as ze,c as je,k as on}from"../chunks/index.BoSueqLU.js";import{e as tt,K as fn,L as an,M as cl,N as Ji,O as xi,Q as un,R as cn,S as hn,U as Qi,V as Je,m as dn,J as mn,W as yn,X as gn,Y as hl,Z as dl}from"../chunks/VennDiagram.svelte_svelte_type_style_lang.CpWb66iP.js";import{w as vi}from"../chunks/entry.BZ_GMUeP.js";import{h as ml,p as bn}from"../chunks/setTrackProxy.LUR8PBUg.js";import{f as Oe,t as dt,m as Wi,s as _n,g as xe,a as ri,I as kn,C as wn}from"../chunks/CopyIcon.CThMk6Du.js";import{p as Ul}from"../chunks/stores.Bh9jB_M6.js";import{a as $i,g as ci,c as Ut,u as We,C as Cn,s as Tn,n as Sn,b as Ki,d as yl,f as ct,e as An,p as Vl,h as Xl,E as Rl,i as Yl,Q as Ln,j as On,D as Mn}from"../chunks/DataTable.D9ctlqFs.js";import{b as Ql,s as lt,f as En}from"../chunks/index.DyFnrb7c.js";import{C as vl,P as Kl}from"../chunks/Prismjs.CDZlKjZ2.js";function gl(l){return t=>t.map(i=>{var n;const r={},s=Object.keys(i);for(const o of s){const f=(n=l[o])!=null?n:o;r[f]=i[o]}return r})}function pn(l,e){if(l.length===0||e.length===0)return{};const t=Object.keys(l[0]),i=Object.keys(e[0]),n={};for(const r of t)i.includes(r)&&(n[r]=r);return n}function Dn(l,e,t){for(const i in t){const n=t[i];if(l[n]!==e[i])return!1}return!0}function In(l,e){return i=>{if(!l.length)return i;const n=pn(i,l),r=Object.keys(l[0]);return i.flatMap(o=>{const f=l.filter(c=>Dn(o,c,n));if(f.length)return f.map(c=>({...o,...c}));const u=Object.fromEntries(r.filter(c=>o[c]==null).map(c=>[c,void 0]));return{...o,...u}})}}function bl(l){return t=>{const i=t.map(n=>({...n}));for(const n in l){const r=l[n],s=typeof r=="function"?r(i):r,o=s!=null&&s[Symbol.iterator]&&typeof s!="string"?s:t.map(()=>s);let f=-1;for(const u of i)u[n]=o[++f]}return i}}function Fn(l){return t=>{const i=Bn(l),n=[];for(const r in i){const s=i[r];let o;typeof s=="function"?o=s(t):Array.isArray(s)?o=s:o=Array.from(new Set(t.map(f=>f[r]))),n.push(o.map(f=>({[r]:f})))}return qn(n)}}function qn(l){function e(i,n,r){if(!r.length&&n!=null){i.push(n);return}const s=r[0],o=r.slice(1);for(const f of s)e(i,{...n,...f},o)}const t=[];return e(t,null,l),t}function Bn(l){if(Array.isArray(l)){const e={};for(const t of l)e[t]=t;return e}else if(typeof l=="object")return l;return{[l]:l}}function zn(l){return t=>{const i=[];for(const n of t){const r={...n};for(const s in l)r[s]==null&&(r[s]=l[s]);i.push(r)}return i}}function _l(l,e){return i=>{const n=Fn(l)(i),r=In(i)(n);return e?zn(e)(r):r}}function kl(l,e,t){return l==null||e==null?void 0:e===0&&l===0?0:!t&&e===0?void 0:l/e}function wl(l,e,t){const i=typeof l=="function"?l:o=>o[l],n=o=>o[e],{predicate:r,allowDivideByZero:s}={};return r==null?(o,f,u)=>{const c=n(o),a=i(o,f,u);return kl(a,c,s)}:(o,f,u)=>{if(!r(o,f,u))return;const c=n(o),a=i(o,f,u);return kl(a,c,s)}}function jn(l){let e,t,i;const n=l[5].default,r=hi(n,l,l[4],null);return{c(){e=z("div"),r&&r.c(),this.h()},l(s){e=j(s,"DIV",{class:!0});var o=V(e);r&&r.l(o),o.forEach(b),this.h()},h(){S(e,"class",t="grid "+l[2][l[0]]+" "+l[3][l[1]])},m(s,o){p(s,e,o),r&&r.m(e,null),i=!0},p(s,[o]){r&&r.p&&(!i||o&16)&&di(r,n,s,s[4],i?yi(n,s[4],o,null):mi(s[4]),null),(!i||o&3&&t!==(t="grid "+s[2][s[0]]+" "+s[3][s[1]]))&&S(e,"class",t)},i(s){i||(G(r,s),i=!0)},o(s){H(r,s),i=!1},d(s){s&&b(e),r&&r.d(s)}}}function Gn(l,e,t){let{$$slots:i={},$$scope:n}=e,{cols:r=2}=e,{gapSize:s="md"}=e;const o=Object.freeze({1:"grid-cols-1",2:"grid-cols-1 sm:grid-cols-2",3:"grid-cols-1 sm:grid-cols-2 md:grid-cols-3",4:"grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4",5:"grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-5",6:"grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-6"}),f=Object.freeze({none:"gap-0",sm:"gap-2",md:"gap-4",lg:"gap-8"}),u=Object.freeze({none:0,sm:8,md:16,lg:32});let c=`grid-${Date.now()}-${Math.round(Math.random()*1e3)}`,a=u[s];return Xt("gridConfig",{gridId:c,cols:r,gapWidth:a}),l.$$set=d=>{"cols"in d&&t(0,r=d.cols),"gapSize"in d&&t(1,s=d.gapSize),"$$scope"in d&&t(4,n=d.$$scope)},[r,s,o,f,n,i]}class Nn extends Ne{constructor(e){super(),Pe(this,e,Gn,jn,Ge,{cols:0,gapSize:1})}}function Cl(l,e,t){const i=l.slice();return i[12]=e[t],i[14]=t,i}function Tl(l,e,t){const i=l.slice();return i[15]=e[t],i[17]=t,i}function Sl(l,e,t){const i=l.slice();return i[15]=e[t],i}function Al(l,e,t){const i=l.slice();return i[15]=e[t],i}function Ll(l){let e,t=l[15].id+"",i,n,r,s;return{c(){e=z("th"),i=ue(t),this.h()},l(o){e=j(o,"TH",{class:!0,style:!0,evidencetype:!0,evidencetypefidelity:!0});var f=V(e);i=ce(f,t),f.forEach(b),this.h()},h(){var o,f;S(e,"class",n=Ui(l[15].type)+" svelte-iw7vqx"),M(e,"width",l[6]+"%"),S(e,"evidencetype",r=((o=l[15].evidenceColumnType)==null?void 0:o.evidenceType)||"unavailable"),S(e,"evidencetypefidelity",s=((f=l[15].evidenceColumnType)==null?void 0:f.typeFidelity)||"unavailable")},m(o,f){p(o,e,f),B(e,i)},p(o,f){var u,c;f&8&&t!==(t=o[15].id+"")&&ge(i,t),f&8&&n!==(n=Ui(o[15].type)+" svelte-iw7vqx")&&S(e,"class",n),f&64&&M(e,"width",o[6]+"%"),f&8&&r!==(r=((u=o[15].evidenceColumnType)==null?void 0:u.evidenceType)||"unavailable")&&S(e,"evidencetype",r),f&8&&s!==(s=((c=o[15].evidenceColumnType)==null?void 0:c.typeFidelity)||"unavailable")&&S(e,"evidencetypefidelity",s)},d(o){o&&b(e)}}}function Ol(l){let e,t=l[15].type+"",i,n,r,s;return{c(){e=z("th"),i=ue(t),this.h()},l(o){e=j(o,"TH",{class:!0,style:!0,evidencetype:!0,evidencetypefidelity:!0});var f=V(e);i=ce(f,t),f.forEach(b),this.h()},h(){var o,f;S(e,"class",n=l[15].type+" type-indicator svelte-iw7vqx"),M(e,"width",l[6]+"%"),S(e,"evidencetype",r=((o=l[15].evidenceColumnType)==null?void 0:o.evidenceType)||"unavailable"),S(e,"evidencetypefidelity",s=((f=l[15].evidenceColumnType)==null?void 0:f.typeFidelity)||"unavailable")},m(o,f){p(o,e,f),B(e,i)},p(o,f){var u,c;f&8&&t!==(t=o[15].type+"")&&ge(i,t),f&8&&n!==(n=o[15].type+" type-indicator svelte-iw7vqx")&&S(e,"class",n),f&64&&M(e,"width",o[6]+"%"),f&8&&r!==(r=((u=o[15].evidenceColumnType)==null?void 0:u.evidenceType)||"unavailable")&&S(e,"evidencetype",r),f&8&&s!==(s=((c=o[15].evidenceColumnType)==null?void 0:c.typeFidelity)||"unavailable")&&S(e,"evidencetypefidelity",s)},d(o){o&&b(e)}}}function Pn(l){let e=(l[2]+l[14]+1).toLocaleString()+"",t;return{c(){t=ue(e)},l(i){t=ce(i,e)},m(i,n){p(i,t,n)},p(i,n){n&4&&e!==(e=(i[2]+i[14]+1).toLocaleString()+"")&&ge(t,e)},d(i){i&&b(t)}}}function Wn(l){let e=(l[2]+l[14]+1).toLocaleString()+"",t;return{c(){t=ue(e)},l(i){t=ce(i,e)},m(i,n){p(i,t,n)},p(i,n){n&4&&e!==(e=(i[2]+i[14]+1).toLocaleString()+"")&&ge(t,e)},d(i){i&&b(t)}}}function Hn(l){let e,t=(l[12][l[15].id]||"Ø")+"",i;return{c(){e=z("td"),i=ue(t),this.h()},l(n){e=j(n,"TD",{class:!0,style:!0});var r=V(e);i=ce(r,t),r.forEach(b),this.h()},h(){S(e,"class","other svelte-iw7vqx"),M(e,"width",l[6]+"%")},m(n,r){p(n,e,r),B(e,i)},p(n,r){r&40&&t!==(t=(n[12][n[15].id]||"Ø")+"")&&ge(i,t),r&64&&M(e,"width",n[6]+"%")},d(n){n&&b(e)}}}function Un(l){let e,t,i=(l[12][l[15].id]??"Ø")+"",n,r;return{c(){e=z("td"),t=z("div"),n=ue(i),this.h()},l(s){e=j(s,"TD",{class:!0,style:!0,title:!0});var o=V(e);t=j(o,"DIV",{class:!0});var f=V(t);n=ce(f,i),f.forEach(b),o.forEach(b),this.h()},h(){S(t,"class","svelte-iw7vqx"),S(e,"class","boolean svelte-iw7vqx"),M(e,"width",l[6]+"%"),S(e,"title",r=l[12][l[15].id])},m(s,o){p(s,e,o),B(e,t),B(t,n)},p(s,o){o&40&&i!==(i=(s[12][s[15].id]??"Ø")+"")&&ge(n,i),o&64&&M(e,"width",s[6]+"%"),o&40&&r!==(r=s[12][s[15].id])&&S(e,"title",r)},d(s){s&&b(e)}}}function Vn(l){let e,t,i=(l[12][l[15].id]||"Ø")+"",n,r;return{c(){e=z("td"),t=z("div"),n=ue(i),this.h()},l(s){e=j(s,"TD",{class:!0,style:!0,title:!0});var o=V(e);t=j(o,"DIV",{class:!0});var f=V(t);n=ce(f,i),f.forEach(b),o.forEach(b),this.h()},h(){S(t,"class","svelte-iw7vqx"),S(e,"class","string svelte-iw7vqx"),M(e,"width",l[6]+"%"),S(e,"title",r=l[12][l[15].id])},m(s,o){p(s,e,o),B(e,t),B(t,n)},p(s,o){o&40&&i!==(i=(s[12][s[15].id]||"Ø")+"")&&ge(n,i),o&64&&M(e,"width",s[6]+"%"),o&40&&r!==(r=s[12][s[15].id])&&S(e,"title",r)},d(s){s&&b(e)}}}function Xn(l){let e,t,i=Oe(l[12][l[15].id],l[3][l[17]].format,l[3][l[17]].columnUnitSummary)+"",n,r;return{c(){e=z("td"),t=z("div"),n=ue(i),this.h()},l(s){e=j(s,"TD",{class:!0,style:!0,title:!0});var o=V(e);t=j(o,"DIV",{class:!0});var f=V(t);n=ce(f,i),f.forEach(b),o.forEach(b),this.h()},h(){S(t,"class","svelte-iw7vqx"),S(e,"class","string svelte-iw7vqx"),M(e,"width",l[6]+"%"),S(e,"title",r=Oe(l[12][l[15].id],l[3][l[17]].format,l[3][l[17]].columnUnitSummary))},m(s,o){p(s,e,o),B(e,t),B(t,n)},p(s,o){o&40&&i!==(i=Oe(s[12][s[15].id],s[3][s[17]].format,s[3][s[17]].columnUnitSummary)+"")&&ge(n,i),o&64&&M(e,"width",s[6]+"%"),o&40&&r!==(r=Oe(s[12][s[15].id],s[3][s[17]].format,s[3][s[17]].columnUnitSummary))&&S(e,"title",r)},d(s){s&&b(e)}}}function Rn(l){let e,t=Oe(l[12][l[15].id],l[3][l[17]].format,l[3][l[17]].columnUnitSummary)+"",i;return{c(){e=z("td"),i=ue(t),this.h()},l(n){e=j(n,"TD",{class:!0,style:!0});var r=V(e);i=ce(r,t),r.forEach(b),this.h()},h(){S(e,"class","number svelte-iw7vqx"),M(e,"width",l[6]+"%")},m(n,r){p(n,e,r),B(e,i)},p(n,r){r&40&&t!==(t=Oe(n[12][n[15].id],n[3][n[17]].format,n[3][n[17]].columnUnitSummary)+"")&&ge(i,t),r&64&&M(e,"width",n[6]+"%")},d(n){n&&b(e)}}}function Yn(l){let e,t="Ø",i,n;return{c(){e=z("td"),i=ue(t),this.h()},l(r){e=j(r,"TD",{class:!0,style:!0});var s=V(e);i=ce(s,t),s.forEach(b),this.h()},h(){S(e,"class",n="null "+l[3][l[17]].type+" svelte-iw7vqx"),M(e,"width",l[6]+"%")},m(r,s){p(r,e,s),B(e,i)},p(r,s){s&8&&n!==(n="null "+r[3][r[17]].type+" svelte-iw7vqx")&&S(e,"class",n),s&64&&M(e,"width",r[6]+"%")},d(r){r&&b(e)}}}function Ml(l){let e;function t(r,s){return r[12][r[15].id]==null?Yn:r[3][r[17]].type==="number"?Rn:r[3][r[17]].type==="date"?Xn:r[3][r[17]].type==="string"?Vn:r[3][r[17]].type==="boolean"?Un:Hn}let i=t(l),n=i(l);return{c(){n.c(),e=be()},l(r){n.l(r),e=be()},m(r,s){n.m(r,s),p(r,e,s)},p(r,s){i===(i=t(r))&&n?n.p(r,s):(n.d(1),n=i(r),n&&(n.c(),n.m(e.parentNode,e)))},d(r){r&&b(e),n.d(r)}}}function El(l){let e,t,i,n;function r(c,a){return c[14]===0?Wn:Pn}let o=r(l)(l),f=tt(l[3]),u=[];for(let c=0;c<f.length;c+=1)u[c]=Ml(Tl(l,f,c));return{c(){e=z("tr"),t=z("td"),o.c(),i=R();for(let c=0;c<u.length;c+=1)u[c].c();n=R(),this.h()},l(c){e=j(c,"TR",{});var a=V(e);t=j(a,"TD",{class:!0,style:!0});var d=V(t);o.l(d),d.forEach(b),i=Y(a);for(let T=0;T<u.length;T+=1)u[T].l(a);n=Y(a),a.forEach(b),this.h()},h(){S(t,"class","index svelte-iw7vqx"),M(t,"width","10%")},m(c,a){p(c,e,a),B(e,t),o.m(t,null),B(e,i);for(let d=0;d<u.length;d+=1)u[d]&&u[d].m(e,null);B(e,n)},p(c,a){if(o.p(c,a),a&104){f=tt(c[3]);let d;for(d=0;d<f.length;d+=1){const T=Tl(c,f,d);u[d]?u[d].p(T,a):(u[d]=Ml(T),u[d].c(),u[d].m(e,n))}for(;d<u.length;d+=1)u[d].d(1);u.length=f.length}},d(c){c&&b(e),o.d(),ui(u,c)}}}function pl(l){let e,t,i,n,r=(l[2]+mt).toLocaleString()+"",s,o,f=(l[4]+mt).toLocaleString()+"",u,c,a;return{c(){e=z("div"),t=z("input"),i=R(),n=z("span"),s=ue(r),o=ue(" of "),u=ue(f),this.h()},l(d){e=j(d,"DIV",{class:!0});var T=V(e);t=j(T,"INPUT",{type:!0,max:!0,step:!0,class:!0}),i=Y(T),n=j(T,"SPAN",{class:!0});var m=V(n);s=ce(m,r),o=ce(m," of "),u=ce(m,f),m.forEach(b),T.forEach(b),this.h()},h(){S(t,"type","range"),S(t,"max",l[4]),S(t,"step","1"),S(t,"class","slider svelte-iw7vqx"),S(n,"class","svelte-iw7vqx"),S(e,"class","pagination svelte-iw7vqx")},m(d,T){p(d,e,T),B(e,t),al(t,l[2]),B(e,i),B(e,n),B(n,s),B(n,o),B(n,u),c||(a=[Ae(t,"change",l[9]),Ae(t,"input",l[9]),Ae(t,"input",l[7])],c=!0)},p(d,T){T&16&&S(t,"max",d[4]),T&4&&al(t,d[2]),T&4&&r!==(r=(d[2]+mt).toLocaleString()+"")&&ge(s,r),T&16&&f!==(f=(d[4]+mt).toLocaleString()+"")&&ge(u,f)},d(d){d&&b(e),c=!1,Kt(a)}}}function Qn(l){let e,t,i,n,r,s,o,f,u,c,a,d,T,m,h,w,A,k,C,L,D,X,q,g,E,P,v=tt(l[3]),U=[];for(let I=0;I<v.length;I+=1)U[I]=Ll(Al(l,v,I));let K=tt(l[3]),F=[];for(let I=0;I<K.length;I+=1)F[I]=Ol(Sl(l,K,I));let le=tt(l[5]),x=[];for(let I=0;I<le.length;I+=1)x[I]=El(Cl(l,le,I));let $=l[4]>0&&pl(l);return X=new $i({props:{class:"download-button",data:l[1],queryID:l[0],display:!0}}),{c(){e=z("div"),t=z("div"),i=z("table"),n=z("thead"),r=z("tr"),s=z("th"),o=R();for(let I=0;I<U.length;I+=1)U[I].c();f=R(),u=z("tr"),c=R(),a=z("tr"),d=z("th"),T=R();for(let I=0;I<F.length;I+=1)F[I].c();m=R(),h=z("tr"),w=R(),A=z("tbody");for(let I=0;I<x.length;I+=1)x[I].c();C=R(),$&&$.c(),L=R(),D=z("div"),se(X.$$.fragment),this.h()},l(I){e=j(I,"DIV",{class:!0});var ie=V(e);t=j(ie,"DIV",{class:!0});var Q=V(t);i=j(Q,"TABLE",{class:!0});var N=V(i);n=j(N,"THEAD",{});var J=V(n);r=j(J,"TR",{});var de=V(r);s=j(de,"TH",{class:!0,style:!0}),V(s).forEach(b),o=Y(de);for(let Z=0;Z<U.length;Z+=1)U[Z].l(de);f=Y(de),de.forEach(b),u=j(J,"TR",{}),V(u).forEach(b),c=Y(J),a=j(J,"TR",{class:!0});var _e=V(a);d=j(_e,"TH",{class:!0,style:!0}),V(d).forEach(b),T=Y(_e);for(let Z=0;Z<F.length;Z+=1)F[Z].l(_e);m=Y(_e),_e.forEach(b),h=j(J,"TR",{}),V(h).forEach(b),J.forEach(b),w=Y(N),A=j(N,"TBODY",{});var ne=V(A);for(let Z=0;Z<x.length;Z+=1)x[Z].l(ne);ne.forEach(b),N.forEach(b),Q.forEach(b),C=Y(ie),$&&$.l(ie),L=Y(ie),D=j(ie,"DIV",{class:!0});var me=V(D);oe(X.$$.fragment,me),me.forEach(b),ie.forEach(b),this.h()},h(){S(s,"class","index svelte-iw7vqx"),M(s,"width","10%"),S(d,"class","index type-indicator svelte-iw7vqx"),M(d,"width","10%"),S(a,"class","type-indicator svelte-iw7vqx"),S(i,"class","svelte-iw7vqx"),S(t,"class","scrollbox svelte-iw7vqx"),S(D,"class","footer svelte-iw7vqx"),S(e,"class","results-pane py-1 svelte-iw7vqx")},m(I,ie){p(I,e,ie),B(e,t),B(t,i),B(i,n),B(n,r),B(r,s),B(r,o);for(let Q=0;Q<U.length;Q+=1)U[Q]&&U[Q].m(r,null);B(r,f),B(n,u),B(n,c),B(n,a),B(a,d),B(a,T);for(let Q=0;Q<F.length;Q+=1)F[Q]&&F[Q].m(a,null);B(a,m),B(n,h),B(i,w),B(i,A);for(let Q=0;Q<x.length;Q+=1)x[Q]&&x[Q].m(A,null);B(e,C),$&&$.m(e,null),B(e,L),B(e,D),fe(X,D,null),g=!0,E||(P=Ae(A,"wheel",l[8]),E=!0)},p(I,[ie]){if(ie&72){v=tt(I[3]);let N;for(N=0;N<v.length;N+=1){const J=Al(I,v,N);U[N]?U[N].p(J,ie):(U[N]=Ll(J),U[N].c(),U[N].m(r,f))}for(;N<U.length;N+=1)U[N].d(1);U.length=v.length}if(ie&72){K=tt(I[3]);let N;for(N=0;N<K.length;N+=1){const J=Sl(I,K,N);F[N]?F[N].p(J,ie):(F[N]=Ol(J),F[N].c(),F[N].m(a,m))}for(;N<F.length;N+=1)F[N].d(1);F.length=K.length}if(ie&108){le=tt(I[5]);let N;for(N=0;N<le.length;N+=1){const J=Cl(I,le,N);x[N]?x[N].p(J,ie):(x[N]=El(J),x[N].c(),x[N].m(A,null))}for(;N<x.length;N+=1)x[N].d(1);x.length=le.length}I[4]>0?$?$.p(I,ie):($=pl(I),$.c(),$.m(e,L)):$&&($.d(1),$=null);const Q={};ie&2&&(Q.data=I[1]),ie&1&&(Q.queryID=I[0]),X.$set(Q)},i(I){g||(I&&(k||yt(()=>{k=Zi(i,Ql,{}),k.start()})),G(X.$$.fragment,I),I&&yt(()=>{g&&(q||(q=it(e,lt,{},!0)),q.run(1))}),g=!0)},o(I){H(X.$$.fragment,I),I&&(q||(q=it(e,lt,{},!1)),q.run(0)),g=!1},d(I){I&&b(e),ui(U,I),ui(F,I),ui(x,I),$&&$.d(),ae(X),I&&q&&q.end(),E=!1,P()}}}let mt=5;function vn(l,e,t){let i,n,r,s,{queryID:o}=e,{data:f}=e,u=0,c;function a(){c=f.slice(u,u+mt),t(5,s=c)}const d=fn(h=>{t(2,u=Math.min(Math.max(0,u+Math.floor(h.deltaY/Math.abs(h.deltaY))),r)),a()},60);function T(h){if(Math.abs(h.deltaX)>=Math.abs(h.deltaY))return;const w=h.deltaY<0&&u===0,A=h.deltaY>0&&u===r;w||A||(h.preventDefault(),d(h))}function m(){u=xl(this.value),t(2,u)}return l.$$set=h=>{"queryID"in h&&t(0,o=h.queryID),"data"in h&&t(1,f=h.data)},l.$$.update=()=>{l.$$.dirty&2&&t(3,i=ci(f,"array")),l.$$.dirty&8&&t(6,n=90/(i.length+1)),l.$$.dirty&2&&t(4,r=Math.max(f.length-mt,0)),l.$$.dirty&6&&t(5,s=f.slice(u,u+mt))},[o,f,u,i,r,s,n,a,T,m]}class Kn extends Ne{constructor(e){super(),Pe(this,e,vn,Qn,Ge,{queryID:0,data:1})}}function Zn(l){let e,t="Compiled",i,n,r="Written",s,o;return{c(){e=z("button"),e.textContent=t,i=R(),n=z("button"),n.textContent=r,this.h()},l(f){e=j(f,"BUTTON",{class:!0,"data-svelte-h":!0}),Rt(e)!=="svelte-1vzm9jy"&&(e.textContent=t),i=Y(f),n=j(f,"BUTTON",{class:!0,"data-svelte-h":!0}),Rt(n)!=="svelte-5roa31"&&(n.textContent=r),this.h()},h(){S(e,"class","off svelte-1b8idd8"),S(n,"class","on svelte-1b8idd8")},m(f,u){p(f,e,u),p(f,i,u),p(f,n,u),s||(o=Ae(e,"click",l[1]),s=!0)},p:re,d(f){f&&(b(e),b(i),b(n)),s=!1,o()}}}function Jn(l){let e,t="Compiled",i,n,r="Written",s,o;return{c(){e=z("button"),e.textContent=t,i=R(),n=z("button"),n.textContent=r,this.h()},l(f){e=j(f,"BUTTON",{class:!0,"data-svelte-h":!0}),Rt(e)!=="svelte-1ofx42v"&&(e.textContent=t),i=Y(f),n=j(f,"BUTTON",{class:!0,"data-svelte-h":!0}),Rt(n)!=="svelte-v36xno"&&(n.textContent=r),this.h()},h(){S(e,"class","on svelte-1b8idd8"),S(n,"class","off svelte-1b8idd8")},m(f,u){p(f,e,u),p(f,i,u),p(f,n,u),s||(o=Ae(n,"click",l[1]),s=!0)},p:re,d(f){f&&(b(e),b(i),b(n)),s=!1,o()}}}function xn(l){let e,t,i;function n(o,f){return o[0]?Jn:Zn}let r=n(l),s=r(l);return{c(){e=z("div"),s.c(),this.h()},l(o){e=j(o,"DIV",{class:!0});var f=V(e);s.l(f),f.forEach(b),this.h()},h(){S(e,"class","toggle svelte-1b8idd8")},m(o,f){p(o,e,f),s.m(e,null),i=!0},p(o,[f]){r===(r=n(o))&&s?s.p(o,f):(s.d(1),s=r(o),s&&(s.c(),s.m(e,null)))},i(o){i||(o&&yt(()=>{i&&(t||(t=it(e,lt,{},!0)),t.run(1))}),i=!0)},o(o){o&&(t||(t=it(e,lt,{},!1)),t.run(0)),i=!1},d(o){o&&b(e),s.d(),o&&t&&t.end()}}}function $n(l,e,t){let{showCompiled:i}=e;const n=function(){t(0,i=!i)};return l.$$set=r=>{"showCompiled"in r&&t(0,i=r.showCompiled)},[i,n]}class er extends Ne{constructor(e){super(),Pe(this,e,$n,xn,Ge,{showCompiled:0})}}function Dl(l){let e,t,i,n,r,s,o,f,u,c,a,d,T,m,h,w,A;n=new vl({props:{toggled:l[10]}});let k=l[10]&&l[4]&&Il(l),C=l[10]&&Fl(l);const L=[sr,rr,nr,lr],D=[];function X(g,E){return g[6]?0:g[8]?1:g[2].loading?2:3}a=X(l),d=D[a]=L[a](l);let q=l[8]>0&&!l[6]&&l[9]&&ql(l);return{c(){e=z("div"),t=z("div"),i=z("button"),se(n.$$.fragment),r=R(),s=ue(l[0]),o=R(),k&&k.c(),f=R(),C&&C.c(),u=R(),c=z("button"),d.c(),T=R(),q&&q.c(),this.h()},l(g){e=j(g,"DIV",{class:!0});var E=V(e);t=j(E,"DIV",{class:!0});var P=V(t);i=j(P,"BUTTON",{type:!0,"aria-label":!0,class:!0});var v=V(i);oe(n.$$.fragment,v),r=Y(v),s=ce(v,l[0]),v.forEach(b),o=Y(P),k&&k.l(P),f=Y(P),C&&C.l(P),P.forEach(b),u=Y(E),c=j(E,"BUTTON",{type:!0,"aria-label":!0,class:!0});var U=V(c);d.l(U),U.forEach(b),T=Y(E),q&&q.l(E),E.forEach(b),this.h()},h(){S(i,"type","button"),S(i,"aria-label","show-sql"),S(i,"class","title svelte-1plm20d"),S(t,"class","container-a svelte-1plm20d"),S(c,"type","button"),S(c,"aria-label","view-query"),S(c,"class",Ui("status-bar")+" svelte-1plm20d"),et(c,"error",l[6]),et(c,"success",!l[6]),et(c,"open",l[9]),et(c,"closed",!l[9]),S(e,"class","scrollbox svelte-1plm20d")},m(g,E){p(g,e,E),B(e,t),B(t,i),fe(n,i,null),B(i,r),B(i,s),B(t,o),k&&k.m(t,null),B(t,f),C&&C.m(t,null),B(e,u),B(e,c),D[a].m(c,null),B(e,T),q&&q.m(e,null),h=!0,w||(A=[Ae(i,"click",l[14]),Ae(c,"click",l[15])],w=!0)},p(g,E){const P={};E&1024&&(P.toggled=g[10]),n.$set(P),(!h||E&1)&&ge(s,g[0]),g[10]&&g[4]?k?(k.p(g,E),E&1040&&G(k,1)):(k=Il(g),k.c(),G(k,1),k.m(t,f)):k&&(ze(),H(k,1,1,()=>{k=null}),je()),g[10]?C?(C.p(g,E),E&1024&&G(C,1)):(C=Fl(g),C.c(),G(C,1),C.m(t,null)):C&&(ze(),H(C,1,1,()=>{C=null}),je());let v=a;a=X(g),a===v?D[a].p(g,E):(ze(),H(D[v],1,1,()=>{D[v]=null}),je(),d=D[a],d?d.p(g,E):(d=D[a]=L[a](g),d.c()),G(d,1),d.m(c,null)),(!h||E&64)&&et(c,"error",g[6]),(!h||E&64)&&et(c,"success",!g[6]),(!h||E&512)&&et(c,"open",g[9]),(!h||E&512)&&et(c,"closed",!g[9]),g[8]>0&&!g[6]&&g[9]?q?(q.p(g,E),E&832&&G(q,1)):(q=ql(g),q.c(),G(q,1),q.m(e,null)):q&&(ze(),H(q,1,1,()=>{q=null}),je())},i(g){h||(G(n.$$.fragment,g),G(k),G(C),G(d),G(q),g&&yt(()=>{h&&(m||(m=it(e,lt,{},!0)),m.run(1))}),h=!0)},o(g){H(n.$$.fragment,g),H(k),H(C),H(d),H(q),g&&(m||(m=it(e,lt,{},!1)),m.run(0)),h=!1},d(g){g&&b(e),ae(n),k&&k.d(),C&&C.d(),D[a].d(),q&&q.d(),g&&m&&m.end(),w=!1,Kt(A)}}}function Il(l){let e,t,i;function n(s){l[18](s)}let r={};return l[5]!==void 0&&(r.showCompiled=l[5]),e=new er({props:r}),$l.push(()=>on(e,"showCompiled",n)),{c(){se(e.$$.fragment)},l(s){oe(e.$$.fragment,s)},m(s,o){fe(e,s,o),i=!0},p(s,o){const f={};!t&&o&32&&(t=!0,f.showCompiled=s[5],en(()=>t=!1)),e.$set(f)},i(s){i||(G(e.$$.fragment,s),i=!0)},o(s){H(e.$$.fragment,s),i=!1},d(s){ae(e,s)}}}function Fl(l){let e,t,i,n,r;const s=[ir,tr],o=[];function f(u,c){return u[5]?0:1}return t=f(l),i=o[t]=s[t](l),{c(){e=z("div"),i.c(),this.h()},l(u){e=j(u,"DIV",{class:!0});var c=V(e);i.l(c),c.forEach(b),this.h()},h(){S(e,"class","code-container svelte-1plm20d")},m(u,c){p(u,e,c),o[t].m(e,null),r=!0},p(u,c){let a=t;t=f(u),t===a?o[t].p(u,c):(ze(),H(o[a],1,1,()=>{o[a]=null}),je(),i=o[t],i?i.p(u,c):(i=o[t]=s[t](u),i.c()),G(i,1),i.m(e,null))},i(u){r||(G(i),u&&yt(()=>{r&&(n||(n=it(e,lt,{},!0)),n.run(1))}),r=!0)},o(u){H(i),u&&(n||(n=it(e,lt,{},!1)),n.run(0)),r=!1},d(u){u&&b(e),o[t].d(),u&&n&&n.end()}}}function tr(l){let e,t;return e=new Kl({props:{code:l[3]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&8&&(r.code=i[3]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function ir(l){let e,t;return e=new Kl({props:{code:l[1].originalText}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&2&&(r.code=i[1].originalText),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function lr(l){let e;return{c(){e=ue("ran successfully but no data was returned")},l(t){e=ce(t,"ran successfully but no data was returned")},m(t,i){p(t,e,i)},p:re,i:re,o:re,d(t){t&&b(e)}}}function nr(l){let e;return{c(){e=ue("loading...")},l(t){e=ce(t,"loading...")},m(t,i){p(t,e,i)},p:re,i:re,o:re,d(t){t&&b(e)}}}function rr(l){let e,t,i=l[8].toLocaleString()+"",n,r,s=l[8]>1?"records":"record",o,f,u=l[7].toLocaleString()+"",c,a,d=l[7]>1?"properties":"property",T,m;return e=new vl({props:{toggled:l[9],color:"#3488e9"}}),{c(){se(e.$$.fragment),t=R(),n=ue(i),r=R(),o=ue(s),f=ue(" with "),c=ue(u),a=R(),T=ue(d)},l(h){oe(e.$$.fragment,h),t=Y(h),n=ce(h,i),r=Y(h),o=ce(h,s),f=ce(h," with "),c=ce(h,u),a=Y(h),T=ce(h,d)},m(h,w){fe(e,h,w),p(h,t,w),p(h,n,w),p(h,r,w),p(h,o,w),p(h,f,w),p(h,c,w),p(h,a,w),p(h,T,w),m=!0},p(h,w){const A={};w&512&&(A.toggled=h[9]),e.$set(A),(!m||w&256)&&i!==(i=h[8].toLocaleString()+"")&&ge(n,i),(!m||w&256)&&s!==(s=h[8]>1?"records":"record")&&ge(o,s),(!m||w&128)&&u!==(u=h[7].toLocaleString()+"")&&ge(c,u),(!m||w&128)&&d!==(d=h[7]>1?"properties":"property")&&ge(T,d)},i(h){m||(G(e.$$.fragment,h),m=!0)},o(h){H(e.$$.fragment,h),m=!1},d(h){h&&(b(t),b(n),b(r),b(o),b(f),b(c),b(a),b(T)),ae(e,h)}}}function sr(l){let e=l[6].message+"",t;return{c(){t=ue(e)},l(i){t=ce(i,e)},m(i,n){p(i,t,n)},p(i,n){n&64&&e!==(e=i[6].message+"")&&ge(t,e)},i:re,o:re,d(i){i&&b(t)}}}function ql(l){let e,t;return e=new Kn({props:{data:l[1],queryID:l[0]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&2&&(r.data=i[1]),n&1&&(r.queryID=i[0]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function or(l){let e,t,i,n=l[11]&&Dl(l);return{c(){e=z("div"),n&&n.c(),this.h()},l(r){e=j(r,"DIV",{class:!0});var s=V(e);n&&n.l(s),s.forEach(b),this.h()},h(){S(e,"class","over-container svelte-1plm20d")},m(r,s){p(r,e,s),n&&n.m(e,null),i=!0},p(r,[s]){r[11]?n?(n.p(r,s),s&2048&&G(n,1)):(n=Dl(r),n.c(),G(n,1),n.m(e,null)):n&&(ze(),H(n,1,1,()=>{n=null}),je())},i(r){i||(G(n),r&&(t||yt(()=>{t=Zi(e,Ql,{}),t.start()})),i=!0)},o(r){H(n),i=!1},d(r){r&&b(e),n&&n.d()}}}function fr(l,e,t){let i,n,r,s,o=re,f=()=>(o(),o=Hl(m,g=>t(2,s=g)),m),u,c,a,d;ht(l,Ul,g=>t(17,a=g)),ht(l,an,g=>t(11,d=g)),l.$$.on_destroy.push(()=>o());let{queryID:T}=e,{queryResult:m}=e;f();let h=cl("showSQL_".concat(T),!1);ht(l,h,g=>t(10,c=g));let w=cl(`showResults_${T}`);ht(l,w,g=>t(9,u=g));const A=function(){Vi(h,c=!c,c)},k=function(){!X&&s.length>0&&Vi(w,u=!u,u)};let C,L,D=!0,X;function q(g){D=g,t(5,D)}return l.$$set=g=>{"queryID"in g&&t(0,T=g.queryID),"queryResult"in g&&f(t(1,m=g.queryResult))},l.$$.update=()=>{if(l.$$.dirty&131072&&t(16,i=a.data.evidencemeta.queries),l.$$.dirty&4&&(s?t(6,X=s.error):t(6,X=new Error("queryResult is undefined"))),l.$$.dirty&4&&t(8,n=(s==null?void 0:s.length)??0),l.$$.dirty&4&&t(7,r=s.columns.length??(s==null?void 0:s._evidenceColumnTypes.length)??0),l.$$.dirty&65537){let g=i==null?void 0:i.find(E=>E.id===T);g&&(t(3,C=g.inputQueryString),t(4,L=g.compiled&&g.compileError===void 0))}},[T,m,s,C,L,D,X,r,n,u,c,d,h,w,A,k,i,a,q]}class ar extends Ne{constructor(e){super(),Pe(this,e,fr,or,Ge,{queryID:0,queryResult:1})}}const si=We.grey500,oi=We.grey500,fi=We.grey500,ai=We.grey200,Bl="white",ur=We.grey500,cr=We.grey600,hr=We.grey500,dr=We.grey400,mr="white",yr=We.grey900,gr=We.grey800,br=We.grey700,el={darkMode:!1,textStyle:{fontFamily:"sans-serif"},grid:{left:"0%",right:"4%",bottom:"0%",top:"15%",containLabel:!0},color:Ut,backgroundColor:"rgba(255, 255, 255, 0)",title:{padding:0,itemGap:7,textStyle:{fontSize:14,color:gr},subtextStyle:{fontSize:13,color:br,overflow:"break"},top:"0%"},line:{itemStyle:{borderWidth:0},lineStyle:{width:2,join:"round"},symbolSize:0,symbol:"circle",smooth:!1},radar:{itemStyle:{borderWidth:0},lineStyle:{width:2},symbolSize:0,symbol:"circle",smooth:!1},pie:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},scatter:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},boxplot:{itemStyle:{borderWidth:1.5}},parallel:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},sankey:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},funnel:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},gauge:{itemStyle:{borderWidth:0,borderColor:"#cccccc"}},candlestick:{itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderWidth:1}},graph:{itemStyle:{borderWidth:0,borderColor:"#cccccc"},lineStyle:{width:1,color:"#aaaaaa"},symbolSize:0,symbol:"circle",smooth:!1,color:["#923d59","#488f96","#518eca","#b3a9a0","#ffc857","#495867","#bfdbf7","#bc4749","#eeebd0"],label:{color:"#f2f2f2"}},map:{itemStyle:{areaColor:"#eee",borderColor:"#444",borderWidth:.5},label:{color:"#000"},emphasis:{itemStyle:{areaColor:"rgba(255,215,0,0.8)",borderColor:"#444",borderWidth:1},label:{color:"rgb(100,0,0)"}}},geo:{itemStyle:{areaColor:"#eee",borderColor:"#444",borderWidth:.5},label:{color:"#000"},emphasis:{itemStyle:{areaColor:"rgba(255,215,0,0.8)",borderColor:"#444",borderWidth:1},label:{color:"rgb(100,0,0)"}}},categoryAxis:{axisLine:{show:!0,lineStyle:{color:si}},axisTick:{show:!1,lineStyle:{color:oi},length:3,alignWithLabel:!0},axisLabel:{show:!0,color:fi},splitLine:{show:!1,lineStyle:{color:[ai]}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},valueAxis:{axisLine:{show:!1,lineStyle:{color:si}},axisTick:{show:!1,lineStyle:{color:oi},length:2},axisLabel:{show:!0,color:fi},splitLine:{show:!0,lineStyle:{color:[ai],width:1}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}},nameTextStyle:{backgroundColor:Bl}},logAxis:{axisLine:{show:!1,lineStyle:{color:si}},axisTick:{show:!1,lineStyle:{color:oi},length:2},axisLabel:{show:!0,color:fi},splitLine:{show:!0,lineStyle:{color:[ai]}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}},nameTextStyle:{backgroundColor:Bl}},timeAxis:{axisLine:{show:!0,lineStyle:{color:si}},axisTick:{show:!0,lineStyle:{color:oi},length:3},axisLabel:{show:!0,color:fi},splitLine:{show:!1,lineStyle:{color:[ai]}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},toolbox:{iconStyle:{borderColor:"#999999"},emphasis:{iconStyle:{borderColor:"#459cde"}}},legend:{textStyle:{padding:[0,0,0,-7],color:ur},icon:"circle",pageIcons:{horizontal:["M 17 3 h 2 c 0.386 0 0.738 0.223 0.904 0.572 s 0.115 0.762 -0.13 1.062 L 11.292 15 l 8.482 10.367 c 0.245 0.299 0.295 0.712 0.13 1.062 S 19.386 27 19 27 h -2 c -0.3 0 -0.584 -0.135 -0.774 -0.367 l -9 -11 c -0.301 -0.369 -0.301 -0.898 0 -1.267 l 9 -11 C 16.416 3.135 16.7 3 17 3 Z","M 12 27 h -2 c -0.386 0 -0.738 -0.223 -0.904 -0.572 s -0.115 -0.762 0.13 -1.062 L 17.708 15 L 9.226 4.633 c -0.245 -0.299 -0.295 -0.712 -0.13 -1.062 S 9.614 3 10 3 h 2 c 0.3 0 0.584 0.135 0.774 0.367 l 9 11 c 0.301 0.369 0.301 0.898 0 1.267 l -9 11 C 12.584 26.865 12.3 27 12 27 Z"]},pageIconColor:cr,pageIconSize:12,pageTextStyle:{color:hr},pageButtonItemGap:-2,animationDurationUpdate:300},tooltip:{axisPointer:{lineStyle:{color:"#cccccc",width:1},crossStyle:{color:"#cccccc",width:1}},borderRadius:4,borderWidth:1,borderColor:dr,backgroundColor:mr,textStyle:{color:yr,fontSize:12,fontWeight:400},padding:6},timeline:{lineStyle:{color:"#e3e3e3",width:2},itemStyle:{color:"#d6d6d6",borderWidth:1},controlStyle:{color:"#bfbfbf",borderColor:"#bfbfbf",borderWidth:1},checkpointStyle:{color:"#8f8f8f",borderColor:"#ffffff"},label:{color:"#c9c9c9"},emphasis:{itemStyle:{color:"#9c9c9c"},controlStyle:{color:"#bfbfbf",borderColor:"#bfbfbf",borderWidth:1},label:{color:"#c9c9c9"}}},visualMap:{color:["#c41621","#e39588","#f5ed98"]},dataZoom:{handleSize:"undefined%",textStyle:{}},markPoint:{label:{color:"#f2f2f2"},emphasis:{label:{color:"#f2f2f2"}}}},Dt=500,_r=(l,e)=>{const t=["iPad Simulator","iPhone Simulator","iPod Simulator","iPad","iPhone","iPod"].includes(navigator.platform)&&l.clientWidth*3*l.clientHeight*3>16777215;Ji("evidence-light",el);const i=xi(l,"evidence-light",{renderer:t?"svg":e.renderer??"canvas"});e.connectGroup&&(i.group=e.connectGroup,un(e.connectGroup));const n=()=>{if(e.seriesColors){const m=i.getOption();if(!m)return;const h={...m};for(const w of Object.keys(e.seriesColors)){const A=m.series.findIndex(k=>k.name===w);A!==-1&&(h.series[A]={...h.series[A],itemStyle:{...h.series[A].itemStyle,color:e.seriesColors[w]}})}i.setOption(h)}},r=()=>{e.echartsOptions&&i.setOption({...e.echartsOptions})},s=()=>{let m=[];if(e.seriesOptions){const h=e.config.series.reduce((w,{evidenceSeriesType:A},k)=>((A==="reference_line"||A==="reference_area"||A==="reference_point")&&w.push(k),w),[]);for(let w=0;w<e.config.series.length;w++)h.includes(w)?m.push({}):m.push({...e.seriesOptions});i.setOption({series:m})}};i.setOption({...e.config,animationDuration:Dt,animationDurationUpdate:Dt}),n(),r(),s();const o=e.dispatch;i.on("click",function(m){o("click",m)});const f=document.getElementById("evidence-main-article"),u=l.parentElement,c=cn(()=>{i.resize({animation:{duration:Dt}}),d()},100);let a;window.ResizeObserver&&f?(a=new ResizeObserver(c),a.observe(f),a.observe(u)):window.addEventListener("resize",c);const d=()=>{if(e.showAllXAxisLabels){const m=i.getOption();if(!m)return;const h=new Set(m.series.flatMap(k=>{var C;return(C=k.data)==null?void 0:C.map(L=>L[0])})),w=4/5,A=(l==null?void 0:l.clientWidth)??0;if(!e.swapXY){const k={xAxis:{axisLabel:{interval:0,overflow:"truncate",width:A*w/h.size}}};i.setOption(k)}}},T=m=>{e=m,i.setOption({...e.config,animationDuration:Dt,animationDurationUpdate:Dt},!0),n(),r(),s(),i.resize({animation:{duration:Dt}}),d()};return c(),{update(m){T(m)},destroy(){a?(a.unobserve(f),a.unobserve(u)):window.removeEventListener("resize",c),i.dispose()}}},kr=(l,e)=>{Ji("evidence-light",el);const t=xi(l,"evidence-light",{renderer:"canvas"});e.config.animation=!1,t.setOption(e.config);const i=()=>{if(e.seriesColors){const u=t.getOption();if(!u)return;const c={...u};for(const a of Object.keys(e.seriesColors)){const d=u.series.findIndex(T=>T.name===a);d!==-1&&(c.series[d]={...c.series[d],itemStyle:{...c.series[d].itemStyle,color:e.seriesColors[a]}})}t.setOption(c)}},n=()=>{e.echartsOptions&&t.setOption({...e.echartsOptions})},r=()=>{let u=[];if(e.seriesOptions){const c=e.config.series.reduce((a,{evidenceSeriesType:d},T)=>((d==="reference_line"||d==="reference_area"||d==="reference_point")&&a.push(T),a),[]);for(let a=0;a<e.config.series.length;a++)c.includes(a)?u.push({}):u.push({...e.seriesOptions});t.setOption({series:u})}};n(),i(),r();let s=t.getConnectedDataURL({type:"png",pixelRatio:3,backgroundColor:"white",excludeComponents:["toolbox"]});const o=new Date,f=new Date(o.getTime()-o.getTimezoneOffset()*6e4).toISOString().slice(0,19).replaceAll(":","-");return hn(s,(e.evidenceChartTitle??e.queryID??"evidence-chart")+`_${f}.png`),t.dispose(),{destroy(){t.dispose()}}},Qt=(l,e)=>{Ji("evidence-light",el);const{config:t,ratio:i,echartsOptions:n,seriesOptions:r,seriesColors:s,isMap:o,extraHeight:f,width:u}=e;let c={renderer:"canvas"};o&&(c.height=u*.5+f,l&&l.parentNode&&(l.style.height=c.height+"px",l.parentNode.style.height=c.height+"px"));const a=xi(l,"evidence-light",c);t.animation=!1,a.setOption(t),n&&a.setOption(n);const d=()=>{if(s){const w=a.getOption();if(!w)return;const A={...w};for(const k of Object.keys(s)){const C=w.series.findIndex(L=>L.name===k);C!==-1&&(A.series[C]={...A.series[C],itemStyle:{...A.series[C].itemStyle,color:s[k]}})}a.setOption(A)}},T=()=>{n&&a.setOption({...n})},m=()=>{let w=[];if(r){const A=t.series.reduce((k,{evidenceSeriesType:C},L)=>((C==="reference_line"||C==="reference_area"||C==="reference_point")&&k.push(L),k),[]);for(let k=0;k<t.series.length;k++)A.includes(k)?w.push({}):w.push({...r});a.setOption({series:w})}};T(),d(),m();let h=a.getConnectedDataURL({type:"jpeg",pixelRatio:i,backgroundColor:"#fff",excludeComponents:["toolbox"]});l.innerHTML=`<img src=${h} width="100%" style=" |
|
" />`,e.config.animation=!0};function wr(l){let e;function t(r,s){return r[10]?Sr:Tr}let i=t(l),n=i(l);return{c(){n.c(),e=be()},l(r){n.l(r),e=be()},m(r,s){n.m(r,s),p(r,e,s)},p(r,s){i===(i=t(r))&&n?n.p(r,s):(n.d(1),n=i(r),n&&(n.c(),n.m(e.parentNode,e)))},d(r){r&&b(e),n.d(r)}}}function Cr(l){let e,t,i,n;return{c(){e=z("div"),this.h()},l(r){e=j(r,"DIV",{class:!0,style:!0}),V(e).forEach(b),this.h()},h(){S(e,"class","chart"),M(e,"height",l[1]),M(e,"width",l[2]),M(e,"margin-left","0"),M(e,"margin-top","15px"),M(e,"margin-bottom","10px"),M(e,"overflow","visible"),M(e,"break-inside","avoid")},m(r,s){p(r,e,s),i||(n=gt(t=Qt.call(null,e,{config:l[0],ratio:2,echartsOptions:l[5],seriesOptions:l[6],seriesColors:l[7]})),i=!0)},p(r,s){s&2&&M(e,"height",r[1]),s&4&&M(e,"width",r[2]),t&&bt(t.update)&&s&225&&t.update.call(null,{config:r[0],ratio:2,echartsOptions:r[5],seriesOptions:r[6],seriesColors:r[7]})},d(r){r&&b(e),i=!1,n()}}}function Tr(l){let e,t,i,n,r,s,o;return{c(){e=z("div"),i=R(),n=z("div"),this.h()},l(f){e=j(f,"DIV",{class:!0,style:!0}),V(e).forEach(b),i=Y(f),n=j(f,"DIV",{class:!0,style:!0}),V(n).forEach(b),this.h()},h(){S(e,"class","chart md:hidden"),M(e,"height",l[1]),M(e,"width","650px"),M(e,"margin-left","0"),M(e,"margin-top","15px"),M(e,"margin-bottom","10px"),M(e,"overflow","visible"),M(e,"break-inside","avoid"),S(n,"class","chart hidden md:block"),M(n,"height",l[1]),M(n,"width","841px"),M(n,"margin-left","0"),M(n,"margin-top","15px"),M(n,"margin-bottom","10px"),M(n,"overflow","visible"),M(n,"break-inside","avoid")},m(f,u){p(f,e,u),p(f,i,u),p(f,n,u),s||(o=[gt(t=Qt.call(null,e,{config:l[0],ratio:4,echartsOptions:l[5],seriesOptions:l[6],seriesColors:l[7],isMap:l[8],extraHeight:l[9],width:650})),gt(r=Qt.call(null,n,{config:l[0],ratio:4,echartsOptions:l[5],seriesOptions:l[6],seriesColors:l[7],isMap:l[8],extraHeight:l[9],width:841}))],s=!0)},p(f,u){u&2&&M(e,"height",f[1]),t&&bt(t.update)&&u&993&&t.update.call(null,{config:f[0],ratio:4,echartsOptions:f[5],seriesOptions:f[6],seriesColors:f[7],isMap:f[8],extraHeight:f[9],width:650}),u&2&&M(n,"height",f[1]),r&&bt(r.update)&&u&993&&r.update.call(null,{config:f[0],ratio:4,echartsOptions:f[5],seriesOptions:f[6],seriesColors:f[7],isMap:f[8],extraHeight:f[9],width:841})},d(f){f&&(b(e),b(i),b(n)),s=!1,Kt(o)}}}function Sr(l){let e,t,i,n,r,s,o;return{c(){e=z("div"),i=R(),n=z("div"),this.h()},l(f){e=j(f,"DIV",{class:!0,style:!0}),V(e).forEach(b),i=Y(f),n=j(f,"DIV",{class:!0,style:!0}),V(n).forEach(b),this.h()},h(){S(e,"class","chart md:hidden"),M(e,"height",l[1]),M(e,"width",l[12]+"px"),M(e,"margin-left","0"),M(e,"margin-top","15px"),M(e,"margin-bottom","10px"),M(e,"overflow","visible"),M(e,"break-inside","avoid"),S(n,"class","chart hidden md:block"),M(n,"height",l[1]),M(n,"width",l[11]+"px"),M(n,"margin-left","0"),M(n,"margin-top","15px"),M(n,"margin-bottom","10px"),M(n,"overflow","visible"),M(n,"break-inside","avoid")},m(f,u){p(f,e,u),p(f,i,u),p(f,n,u),s||(o=[gt(t=Qt.call(null,e,{config:l[0],ratio:4,echartsOptions:l[5],seriesOptions:l[6],seriesColors:l[7],isMap:l[8],extraHeight:l[9],width:l[12]})),gt(r=Qt.call(null,n,{config:l[0],ratio:4,echartsOptions:l[5],seriesOptions:l[6],seriesColors:l[7],isMap:l[8],extraHeight:l[9],width:l[11]}))],s=!0)},p(f,u){u&2&&M(e,"height",f[1]),u&4096&&M(e,"width",f[12]+"px"),t&&bt(t.update)&&u&5089&&t.update.call(null,{config:f[0],ratio:4,echartsOptions:f[5],seriesOptions:f[6],seriesColors:f[7],isMap:f[8],extraHeight:f[9],width:f[12]}),u&2&&M(n,"height",f[1]),u&2048&&M(n,"width",f[11]+"px"),r&&bt(r.update)&&u&3041&&r.update.call(null,{config:f[0],ratio:4,echartsOptions:f[5],seriesOptions:f[6],seriesColors:f[7],isMap:f[8],extraHeight:f[9],width:f[11]})},d(f){f&&(b(e),b(i),b(n)),s=!1,Kt(o)}}}function Ar(l){let e;function t(r,s){if(r[3])return Cr;if(r[4])return wr}let i=t(l),n=i&&i(l);return{c(){n&&n.c(),e=be()},l(r){n&&n.l(r),e=be()},m(r,s){n&&n.m(r,s),p(r,e,s)},p(r,[s]){i===(i=t(r))&&n?n.p(r,s):(n&&n.d(1),n=i&&i(r),n&&(n.c(),n.m(e.parentNode,e)))},i:re,o:re,d(r){r&&b(e),n&&n.d(r)}}}function Lr(l,e,t){let i,n,r,s,{config:o=void 0}=e,{height:f="291px"}=e,{width:u="100%"}=e,{copying:c=!1}=e,{printing:a=!1}=e,{echartsOptions:d=void 0}=e,{seriesOptions:T=void 0}=e,{seriesColors:m=void 0}=e,{isMap:h=!1}=e,{extraHeight:w=void 0}=e,A=!1,k,C;const L=Xi("gridConfig");return L&&(A=!0,{cols:k,gapWidth:C}=L),l.$$set=D=>{"config"in D&&t(0,o=D.config),"height"in D&&t(1,f=D.height),"width"in D&&t(2,u=D.width),"copying"in D&&t(3,c=D.copying),"printing"in D&&t(4,a=D.printing),"echartsOptions"in D&&t(5,d=D.echartsOptions),"seriesOptions"in D&&t(6,T=D.seriesOptions),"seriesColors"in D&&t(7,m=D.seriesColors),"isMap"in D&&t(8,h=D.isMap),"extraHeight"in D&&t(9,w=D.extraHeight)},l.$$.update=()=>{l.$$.dirty&8192&&t(16,i=Math.min(Number(k),2)),l.$$.dirty&81920&&t(12,n=(650-Number(C)*(i-1))/i),l.$$.dirty&8192&&t(15,r=Math.min(Number(k),3)),l.$$.dirty&49152&&t(11,s=(841-Number(C)*(r-1))/r)},[o,f,u,c,a,d,T,m,h,w,A,s,n,k,C,r,i]}class Or extends Ne{constructor(e){super(),Pe(this,e,Lr,Ar,Ge,{config:0,height:1,width:2,copying:3,printing:4,echartsOptions:5,seriesOptions:6,seriesColors:7,isMap:8,extraHeight:9})}}function Mr(l){let e,t,i="Loading...",n,r,s;return{c(){e=z("div"),t=z("span"),t.textContent=i,n=R(),r=z("div"),this.h()},l(o){e=j(o,"DIV",{role:!0,class:!0});var f=V(e);t=j(f,"SPAN",{class:!0,"data-svelte-h":!0}),Rt(t)!=="svelte-1wtojot"&&(t.textContent=i),n=Y(f),r=j(f,"DIV",{class:!0,style:!0}),V(r).forEach(b),f.forEach(b),this.h()},h(){S(t,"class","sr-only"),S(r,"class","bg-gray-200 rounded-md dark:bg-gray-400 max-w-[100%]"),M(r,"height",l[0]),M(r,"margin-top","15px"),M(r,"margin-bottom","31px"),S(e,"role","status"),S(e,"class","animate-pulse")},m(o,f){p(o,e,f),B(e,t),B(e,n),B(e,r)},p(o,[f]){f&1&&M(r,"height",o[0])},i(o){o&&(s||yt(()=>{s=Zi(e,En,{}),s.start()}))},o:re,d(o){o&&b(e)}}}function Er(l,e,t){let{height:i="231px"}=e;return l.$$set=n=>{"height"in n&&t(0,i=n.height)},[i]}class pr extends Ne{constructor(e){super(),Pe(this,e,Er,Mr,Ge,{height:0})}}function zl(l){let e,t,i,n;const r=[Ir,Dr],s=[];function o(f,u){return 1}return e=o(),t=s[e]=r[e](l),{c(){t.c(),i=be()},l(f){t.l(f),i=be()},m(f,u){s[e].m(f,u),p(f,i,u),n=!0},p(f,u){t.p(f,u)},i(f){n||(G(t),n=!0)},o(f){H(t),n=!1},d(f){f&&b(i),s[e].d(f)}}}function Dr(l){let e,t,i,n;return{c(){e=z("div"),this.h()},l(r){e=j(r,"DIV",{class:!0,style:!0}),V(e).forEach(b),this.h()},h(){S(e,"class","chart svelte-19r8f8"),M(e,"height",l[3]),M(e,"width",l[4]),M(e,"margin-left","0"),M(e,"margin-top","15px"),M(e,"margin-bottom","10px"),M(e,"overflow","visible"),M(e,"display",l[13]?"none":"inherit")},m(r,s){p(r,e,s),i||(n=gt(t=_r.call(null,e,{config:l[0],...l[17],echartsOptions:l[7],seriesOptions:l[8],dispatch:l[16],renderer:l[6],connectGroup:l[11],seriesColors:l[10]})),i=!0)},p(r,s){s&8&&M(e,"height",r[3]),s&16&&M(e,"width",r[4]),s&8192&&M(e,"display",r[13]?"none":"inherit"),t&&bt(t.update)&&s&134593&&t.update.call(null,{config:r[0],...r[17],echartsOptions:r[7],seriesOptions:r[8],dispatch:r[16],renderer:r[6],connectGroup:r[11],seriesColors:r[10]})},i:re,o:re,d(r){r&&b(e),i=!1,n()}}}function Ir(l){let e,t;return e=new pr({props:{height:l[3]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&8&&(r.height=i[3]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Fr(l){let e,t,i,n;return{c(){e=li("svg"),t=li("rect"),i=li("circle"),n=li("path"),this.h()},l(r){e=ni(r,"svg",{xmlns:!0,width:!0,height:!0,viewBox:!0,fill:!0,stroke:!0,"stroke-width":!0,"stroke-linecap":!0,"stroke-linejoin":!0});var s=V(e);t=ni(s,"rect",{x:!0,y:!0,width:!0,height:!0,rx:!0}),V(t).forEach(b),i=ni(s,"circle",{cx:!0,cy:!0,r:!0}),V(i).forEach(b),n=ni(s,"path",{d:!0}),V(n).forEach(b),s.forEach(b),this.h()},h(){S(t,"x","3"),S(t,"y","3"),S(t,"width","18"),S(t,"height","18"),S(t,"rx","2"),S(i,"cx","8.5"),S(i,"cy","8.5"),S(i,"r","1.5"),S(n,"d","M20.4 14.5L16 10 4 20"),S(e,"xmlns","http://www.w3.org/2000/svg"),S(e,"width","12"),S(e,"height","12"),S(e,"viewBox","0 0 24 24"),S(e,"fill","none"),S(e,"stroke","#000"),S(e,"stroke-width","2"),S(e,"stroke-linecap","round"),S(e,"stroke-linejoin","round")},m(r,s){p(r,e,s),B(e,t),B(e,i),B(e,n)},p:re,d(r){r&&b(e)}}}function jl(l){let e,t;return e=new $i({props:{text:"Download data",data:l[5],queryID:l[1],class:"download-button",display:l[15]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&32&&(r.data=i[5]),n&2&&(r.queryID=i[1]),n&32768&&(r.display=i[15]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Gl(l){let e,t;return e=new Cn({props:{source:JSON.stringify(l[0],void 0,3),copyToClipboard:!0,$$slots:{default:[qr]},$$scope:{ctx:l}}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&1&&(r.source=JSON.stringify(i[0],void 0,3)),n&67108865&&(r.$$scope={dirty:n,ctx:i}),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function qr(l){let e=JSON.stringify(l[0],void 0,3)+"",t;return{c(){t=ue(e)},l(i){t=ce(i,e)},m(i,n){p(i,t,n)},p(i,n){n&1&&e!==(e=JSON.stringify(i[0],void 0,3)+"")&&ge(t,e)},d(i){i&&b(t)}}}function Nl(l){let e,t,i,n;return{c(){e=z("div"),this.h()},l(r){e=j(r,"DIV",{class:!0,style:!0}),V(e).forEach(b),this.h()},h(){S(e,"class","chart svelte-19r8f8"),M(e,"display","none"),M(e,"visibility","visible"),M(e,"height",l[3]),M(e,"width","666px"),M(e,"margin-left","0"),M(e,"margin-top","15px"),M(e,"margin-bottom","15px"),M(e,"overflow","visible")},m(r,s){p(r,e,s),i||(n=gt(t=kr.call(null,e,{config:l[0],...l[17],echartsOptions:l[7],seriesOptions:l[8],seriesColors:l[10],queryID:l[1],evidenceChartTitle:l[2]})),i=!0)},p(r,s){s&8&&M(e,"height",r[3]),t&&bt(t.update)&&s&132487&&t.update.call(null,{config:r[0],...r[17],echartsOptions:r[7],seriesOptions:r[8],seriesColors:r[10],queryID:r[1],evidenceChartTitle:r[2]})},d(r){r&&b(e),i=!1,n()}}}function Br(l){let e,t,i,n,r,s,o,f,u,c,a,d,T,m=!l[14]&&zl(l);i=new Or({props:{config:l[0],height:l[3],width:l[4],copying:l[13],printing:l[14],echartsOptions:l[7],seriesOptions:l[8],seriesColors:l[10]}}),s=new $i({props:{text:"Save image",class:"download-button",downloadData:l[23],display:l[15],queryID:l[1],$$slots:{default:[Fr]},$$scope:{ctx:l}}});let h=l[5]&&jl(l),w=l[9]&&!l[14]&&Gl(l),A=l[12]&&Nl(l);return{c(){e=z("div"),m&&m.c(),t=R(),se(i.$$.fragment),n=R(),r=z("div"),se(s.$$.fragment),o=R(),h&&h.c(),f=R(),w&&w.c(),u=R(),A&&A.c(),c=be(),this.h()},l(k){e=j(k,"DIV",{role:!0,class:!0});var C=V(e);m&&m.l(C),t=Y(C),oe(i.$$.fragment,C),n=Y(C),r=j(C,"DIV",{class:!0});var L=V(r);oe(s.$$.fragment,L),o=Y(L),h&&h.l(L),L.forEach(b),f=Y(C),w&&w.l(C),C.forEach(b),u=Y(k),A&&A.l(k),c=be(),this.h()},h(){S(r,"class","chart-footer svelte-19r8f8"),S(e,"role","none"),S(e,"class","chart-container svelte-19r8f8")},m(k,C){p(k,e,C),m&&m.m(e,null),B(e,t),fe(i,e,null),B(e,n),B(e,r),fe(s,r,null),B(r,o),h&&h.m(r,null),B(e,f),w&&w.m(e,null),p(k,u,C),A&&A.m(k,C),p(k,c,C),a=!0,d||(T=[Ae(window,"copy",l[18]),Ae(window,"beforeprint",l[19]),Ae(window,"afterprint",l[20]),Ae(window,"export-beforeprint",l[21]),Ae(window,"export-afterprint",l[22]),Ae(e,"mouseenter",l[24]),Ae(e,"mouseleave",l[25])],d=!0)},p(k,[C]){k[14]?m&&(ze(),H(m,1,1,()=>{m=null}),je()):m?(m.p(k,C),C&16384&&G(m,1)):(m=zl(k),m.c(),G(m,1),m.m(e,t));const L={};C&1&&(L.config=k[0]),C&8&&(L.height=k[3]),C&16&&(L.width=k[4]),C&8192&&(L.copying=k[13]),C&16384&&(L.printing=k[14]),C&128&&(L.echartsOptions=k[7]),C&256&&(L.seriesOptions=k[8]),C&1024&&(L.seriesColors=k[10]),i.$set(L);const D={};C&4096&&(D.downloadData=k[23]),C&32768&&(D.display=k[15]),C&2&&(D.queryID=k[1]),C&67108864&&(D.$$scope={dirty:C,ctx:k}),s.$set(D),k[5]?h?(h.p(k,C),C&32&&G(h,1)):(h=jl(k),h.c(),G(h,1),h.m(r,null)):h&&(ze(),H(h,1,1,()=>{h=null}),je()),k[9]&&!k[14]?w?(w.p(k,C),C&16896&&G(w,1)):(w=Gl(k),w.c(),G(w,1),w.m(e,null)):w&&(ze(),H(w,1,1,()=>{w=null}),je()),k[12]?A?A.p(k,C):(A=Nl(k),A.c(),A.m(c.parentNode,c)):A&&(A.d(1),A=null)},i(k){a||(G(m),G(i.$$.fragment,k),G(s.$$.fragment,k),G(h),G(w),a=!0)},o(k){H(m),H(i.$$.fragment,k),H(s.$$.fragment,k),H(h),H(w),a=!1},d(k){k&&(b(e),b(u),b(c)),m&&m.d(),ae(i),ae(s),h&&h.d(),w&&w.d(),A&&A.d(k),d=!1,Kt(T)}}}function zr(l,e,t){const i=["config","queryID","evidenceChartTitle","height","width","data","renderer","echartsOptions","seriesOptions","printEchartsConfig","seriesColors","connectGroup"];let n=ul(e,i),{config:r=void 0}=e,{queryID:s=void 0}=e,{evidenceChartTitle:o=void 0}=e,{height:f="291px"}=e,{width:u="100%"}=e,{data:c}=e,{renderer:a=void 0}=e,{echartsOptions:d=void 0}=e,{seriesOptions:T=void 0}=e,{printEchartsConfig:m}=e,{seriesColors:h=void 0}=e,{connectGroup:w=void 0}=e;const A=tn();let k=!1,C=!1,L=!1,D=!1;const X=()=>{t(13,C=!0),ln(),setTimeout(()=>{t(13,C=!1)},0)},q=()=>t(14,L=!0),g=()=>t(14,L=!1),E=()=>t(14,L=!0),P=()=>t(14,L=!1),v=()=>{t(12,k=!0),setTimeout(()=>{t(12,k=!1)},0)},U=()=>t(15,D=!0),K=()=>t(15,D=!1);return l.$$set=F=>{e=Yt(Yt({},e),Ri(F)),t(17,n=ul(e,i)),"config"in F&&t(0,r=F.config),"queryID"in F&&t(1,s=F.queryID),"evidenceChartTitle"in F&&t(2,o=F.evidenceChartTitle),"height"in F&&t(3,f=F.height),"width"in F&&t(4,u=F.width),"data"in F&&t(5,c=F.data),"renderer"in F&&t(6,a=F.renderer),"echartsOptions"in F&&t(7,d=F.echartsOptions),"seriesOptions"in F&&t(8,T=F.seriesOptions),"printEchartsConfig"in F&&t(9,m=F.printEchartsConfig),"seriesColors"in F&&t(10,h=F.seriesColors),"connectGroup"in F&&t(11,w=F.connectGroup)},[r,s,o,f,u,c,a,d,T,m,h,w,k,C,L,D,A,n,X,q,g,E,P,v,U,K]}class jr extends Ne{constructor(e){super(),Pe(this,e,zr,Br,Ge,{config:0,queryID:1,evidenceChartTitle:2,height:3,width:4,data:5,renderer:6,echartsOptions:7,seriesOptions:8,printEchartsConfig:9,seriesColors:10,connectGroup:11})}}function vt(l,e){const t=new Set(l.map(i=>i[e]));return Array.from(t)}function Gr(l,e){return dt(l,Tn({count:Sn(e)}))[0].count}function Nr(l,e,t){let i;if(typeof t!="object")i=dt(l,Qi(e,bl({xTotal:Ki(t)})),Wi({percentOfX:wl(t,"xTotal")}),gl({[t]:t+"_raw",percentOfX:t+"_pct"}));else{i=dt(l,Wi({valueSum:0}));for(let n=0;n<i.length;n++){i[n].valueSum=0;for(let r=0;r<t.length;r++)i[n].valueSum=i[n].valueSum+i[n][t[r]]}i=dt(i,Qi(e,bl({xTotal:Ki("valueSum")})));for(let n=0;n<t.length;n++)i=dt(i,Wi({percentOfX:wl(t[n],"xTotal")}),gl({[t[n]]:t[n]+"_raw",percentOfX:t[n]+"_pct"}))}return i}function Vt(l,e,t){return[...l].sort((i,n)=>(i[e]<n[e]?-1:1)*(t?1:-1))}function Zl(l,e,t){const i=e+t;return l%i<e?0:1}function Pr(l){let e,t;return e=new Rl({props:{error:l[13],chartType:l[6]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n[0]&8192&&(r.error=i[13]),n[0]&64&&(r.chartType=i[6]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Wr(l){let e,t,i,n,r;const s=l[119].default,o=hi(s,l,l[118],null),f=[Ur,Hr],u=[];function c(a,d){return a[15].series.length?1:0}return t=c(l),i=u[t]=f[t](l),{c(){o&&o.c(),e=R(),i.c(),n=be()},l(a){o&&o.l(a),e=Y(a),i.l(a),n=be()},m(a,d){o&&o.m(a,d),p(a,e,d),u[t].m(a,d),p(a,n,d),r=!0},p(a,d){o&&o.p&&(!r||d[3]&33554432)&&di(o,s,a,a[118],r?yi(s,a[118],d,null):mi(a[118]),null);let T=t;t=c(a),t===T?u[t].p(a,d):(ze(),H(u[T],1,1,()=>{u[T]=null}),je(),i=u[t],i?i.p(a,d):(i=u[t]=f[t](a),i.c()),G(i,1),i.m(n.parentNode,n))},i(a){r||(G(o,a),G(i),r=!0)},o(a){H(o,a),H(i),r=!1},d(a){a&&(b(e),b(n)),o&&o.d(a),u[t].d(a)}}}function Hr(l){let e,t;return e=new jr({props:{config:l[15],height:l[14],width:l[12],data:l[0],queryID:l[3],evidenceChartTitle:l[5],showAllXAxisLabels:l[4],swapXY:l[2],echartsOptions:l[7],seriesOptions:l[8],printEchartsConfig:l[1],renderer:l[10],connectGroup:l[11],seriesColors:l[9]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n[0]&32768&&(r.config=i[15]),n[0]&16384&&(r.height=i[14]),n[0]&4096&&(r.width=i[12]),n[0]&1&&(r.data=i[0]),n[0]&8&&(r.queryID=i[3]),n[0]&32&&(r.evidenceChartTitle=i[5]),n[0]&16&&(r.showAllXAxisLabels=i[4]),n[0]&4&&(r.swapXY=i[2]),n[0]&128&&(r.echartsOptions=i[7]),n[0]&256&&(r.seriesOptions=i[8]),n[0]&2&&(r.printEchartsConfig=i[1]),n[0]&1024&&(r.renderer=i[10]),n[0]&2048&&(r.connectGroup=i[11]),n[0]&512&&(r.seriesColors=i[9]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Ur(l){let e,t;return e=new Yl({props:{emptySet:"pass"}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p:re,i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Vr(l){let e,t,i,n;const r=[Wr,Pr],s=[];function o(f,u){return f[13]?1:0}return e=o(l),t=s[e]=r[e](l),{c(){t.c(),i=be()},l(f){t.l(f),i=be()},m(f,u){s[e].m(f,u),p(f,i,u),n=!0},p(f,u){let c=e;e=o(f),e===c?s[e].p(f,u):(ze(),H(s[c],1,1,()=>{s[c]=null}),je(),t=s[e],t?t.p(f,u):(t=s[e]=r[e](f),t.c()),G(t,1),t.m(i.parentNode,i))},i(f){n||(G(t),n=!0)},o(f){H(t),n=!1},d(f){f&&b(i),s[e].d(f)}}}function Xr(l,e,t){let i,{$$slots:n={},$$scope:r}=e,s=vi({}),o=vi({});ht(l,o,_=>t(15,i=_));let{data:f=void 0}=e,{queryID:u=void 0}=e,{x:c=void 0}=e,{y:a=void 0}=e,{y2:d=void 0}=e,{series:T=void 0}=e,{size:m=void 0}=e,{tooltipTitle:h=void 0}=e,{showAllXAxisLabels:w=!1}=e,{printEchartsConfig:A=!1}=e;const k=!!a,C=!!c;let{swapXY:L=!1}=e,{title:D=void 0}=e,{subtitle:X=void 0}=e,{chartType:q="Chart"}=e,{bubble:g=!1}=e,{hist:E=!1}=e,{boxplot:P=!1}=e,v,{xType:U=void 0}=e,{xAxisTitle:K="false"}=e,{xBaseline:F=!0}=e,{xTickMarks:le=!1}=e,{xGridlines:x=!1}=e,{xAxisLabels:$=!0}=e,{sort:I=!0}=e,{xFmt:ie=void 0}=e,{xMin:Q=void 0}=e,{xMax:N=void 0}=e,{yLog:J=!1}=e,{yType:de=J===!0?"log":"value"}=e,{yLogBase:_e=10}=e,{yAxisTitle:ne="false"}=e,{yBaseline:me=!1}=e,{yTickMarks:Z=!1}=e,{yGridlines:Me=!0}=e,{yAxisLabels:we=!0}=e,{yMin:He=void 0}=e,{yMax:qe=void 0}=e,{yScale:ke=!1}=e,{yFmt:Be=void 0}=e,{yAxisColor:ye="true"}=e,{y2AxisTitle:Ce="false"}=e,{y2Baseline:Te=!1}=e,{y2TickMarks:Ee=!1}=e,{y2Gridlines:Ue=!0}=e,{y2AxisLabels:Ve=!0}=e,{y2Min:O=void 0}=e,{y2Max:he=void 0}=e,{y2Scale:pe=!1}=e,{y2Fmt:Ye=void 0}=e,{y2AxisColor:Xe="true"}=e,{sizeFmt:nt=void 0}=e,{colorPalette:Le=void 0}=e,{legend:De=void 0}=e,{echartsOptions:It=void 0}=e,{seriesOptions:Ft=void 0}=e,{seriesColors:qt=void 0}=e,{stackType:_t=void 0}=e,{stacked100:$e=!1}=e,{chartAreaHeight:Ie}=e,{renderer:Bt=void 0}=e,{connectGroup:zt=void 0}=e,ee,rt,y=[],ve=[],kt,st,Fe,gi,Qe,Se,Ke,Zt,bi,jt,Jt,_i,xt,wt,ki,wi,Gt,Ct,Ci,Ti,Si,Ai,Li,Oi,Mi,Ei,pi,Di,Ii,Tt,Nt,Pt,$t,ei,Fi,qi,St,Bi,zi,ti,tl,ji,ot=[],At=!0,Ze=[],Wt=[],Re,Ht,Gi,ft;return l.$$set=_=>{"data"in _&&t(0,f=_.data),"queryID"in _&&t(3,u=_.queryID),"x"in _&&t(17,c=_.x),"y"in _&&t(18,a=_.y),"y2"in _&&t(41,d=_.y2),"series"in _&&t(42,T=_.series),"size"in _&&t(43,m=_.size),"tooltipTitle"in _&&t(44,h=_.tooltipTitle),"showAllXAxisLabels"in _&&t(4,w=_.showAllXAxisLabels),"printEchartsConfig"in _&&t(1,A=_.printEchartsConfig),"swapXY"in _&&t(2,L=_.swapXY),"title"in _&&t(5,D=_.title),"subtitle"in _&&t(45,X=_.subtitle),"chartType"in _&&t(6,q=_.chartType),"bubble"in _&&t(46,g=_.bubble),"hist"in _&&t(47,E=_.hist),"boxplot"in _&&t(48,P=_.boxplot),"xType"in _&&t(19,U=_.xType),"xAxisTitle"in _&&t(20,K=_.xAxisTitle),"xBaseline"in _&&t(21,F=_.xBaseline),"xTickMarks"in _&&t(22,le=_.xTickMarks),"xGridlines"in _&&t(23,x=_.xGridlines),"xAxisLabels"in _&&t(24,$=_.xAxisLabels),"sort"in _&&t(25,I=_.sort),"xFmt"in _&&t(49,ie=_.xFmt),"xMin"in _&&t(50,Q=_.xMin),"xMax"in _&&t(51,N=_.xMax),"yLog"in _&&t(26,J=_.yLog),"yType"in _&&t(52,de=_.yType),"yLogBase"in _&&t(53,_e=_.yLogBase),"yAxisTitle"in _&&t(27,ne=_.yAxisTitle),"yBaseline"in _&&t(28,me=_.yBaseline),"yTickMarks"in _&&t(29,Z=_.yTickMarks),"yGridlines"in _&&t(30,Me=_.yGridlines),"yAxisLabels"in _&&t(31,we=_.yAxisLabels),"yMin"in _&&t(54,He=_.yMin),"yMax"in _&&t(55,qe=_.yMax),"yScale"in _&&t(32,ke=_.yScale),"yFmt"in _&&t(56,Be=_.yFmt),"yAxisColor"in _&&t(57,ye=_.yAxisColor),"y2AxisTitle"in _&&t(33,Ce=_.y2AxisTitle),"y2Baseline"in _&&t(34,Te=_.y2Baseline),"y2TickMarks"in _&&t(35,Ee=_.y2TickMarks),"y2Gridlines"in _&&t(36,Ue=_.y2Gridlines),"y2AxisLabels"in _&&t(37,Ve=_.y2AxisLabels),"y2Min"in _&&t(58,O=_.y2Min),"y2Max"in _&&t(59,he=_.y2Max),"y2Scale"in _&&t(38,pe=_.y2Scale),"y2Fmt"in _&&t(60,Ye=_.y2Fmt),"y2AxisColor"in _&&t(61,Xe=_.y2AxisColor),"sizeFmt"in _&&t(62,nt=_.sizeFmt),"colorPalette"in _&&t(63,Le=_.colorPalette),"legend"in _&&t(39,De=_.legend),"echartsOptions"in _&&t(7,It=_.echartsOptions),"seriesOptions"in _&&t(8,Ft=_.seriesOptions),"seriesColors"in _&&t(9,qt=_.seriesColors),"stackType"in _&&t(64,_t=_.stackType),"stacked100"in _&&t(65,$e=_.stacked100),"chartAreaHeight"in _&&t(40,Ie=_.chartAreaHeight),"renderer"in _&&t(10,Bt=_.renderer),"connectGroup"in _&&t(11,zt=_.connectGroup),"$$scope"in _&&t(118,r=_.$$scope)},l.$$.update=()=>{var _,il,ll,nl,rl,sl;if(l.$$.dirty[0]&2&&t(1,A=A==="true"||A===!0),l.$$.dirty[0]&4&&(L==="true"||L===!0?t(2,L=!0):t(2,L=!1)),l.$$.dirty[0]&2097152&&t(21,F=F==="true"||F===!0),l.$$.dirty[0]&4194304&&t(22,le=le==="true"||le===!0),l.$$.dirty[0]&8388608&&t(23,x=x==="true"||x===!0),l.$$.dirty[0]&16777216&&t(24,$=$==="true"||$===!0),l.$$.dirty[0]&33554432&&t(25,I=I==="true"||I===!0),l.$$.dirty[0]&67108864&&t(26,J=J==="true"||J===!0),l.$$.dirty[0]&268435456&&t(28,me=me==="true"||me===!0),l.$$.dirty[0]&536870912&&t(29,Z=Z==="true"||Z===!0),l.$$.dirty[0]&1073741824&&t(30,Me=Me==="true"||Me===!0),l.$$.dirty[1]&1&&t(31,we=we==="true"||we===!0),l.$$.dirty[1]&2&&t(32,ke=ke==="true"||ke===!0),l.$$.dirty[1]&8&&t(34,Te=Te==="true"||Te===!0),l.$$.dirty[1]&16&&t(35,Ee=Ee==="true"||Ee===!0),l.$$.dirty[1]&32&&t(36,Ue=Ue==="true"||Ue===!0),l.$$.dirty[1]&64&&t(37,Ve=Ve==="true"||Ve===!0),l.$$.dirty[1]&128&&t(38,pe=pe==="true"||pe===!0),l.$$.dirty[0]&2147364965|l.$$.dirty[1]&2147483647|l.$$.dirty[2]&2147483647|l.$$.dirty[3]&33554431)try{if(t(13,Ht=void 0),t(111,ot=[]),t(70,ve=[]),t(113,Ze=[]),t(114,Wt=[]),t(72,st=[]),yl(f),t(67,ee=ci(f)),t(68,rt=Object.keys(ee)),C||t(17,c=rt[0]),!k){t(69,y=rt.filter(function(W){return![c,T,m].includes(W)}));for(let W=0;W<y.length;W++)t(72,st=y[W]),t(71,kt=ee[st].type),kt==="number"&&ve.push(st);t(18,a=ve.length>1?ve:ve[0])}g?t(66,v={x:c,y:a,size:m}):E?t(66,v={x:c}):P?t(66,v={}):t(66,v={x:c,y:a});for(let W in v)v[W]==null&&ot.push(W);if(ot.length===1)throw Error(new Intl.ListFormat().format(ot)+" is required");if(ot.length>1)throw Error(new Intl.ListFormat().format(ot)+" are required");if($e===!0&&a.includes("_pct")&&At===!1)if(typeof a=="object"){for(let W=0;W<a.length;W++)t(18,a[W]=a[W].replace("_pct",""),a);t(112,At=!1)}else t(18,a=a.replace("_pct","")),t(112,At=!1);if(c&&Ze.push(c),a)if(typeof a=="object")for(t(115,Re=0);Re<a.length;t(115,Re++,Re))Ze.push(a[Re]);else Ze.push(a);if(d)if(typeof d=="object")for(t(115,Re=0);Re<d.length;t(115,Re++,Re))Ze.push(d[Re]);else Ze.push(d);if(m&&Ze.push(m),T&&Wt.push(T),h&&Wt.push(h),yl(f,Ze,Wt),$e===!0){if(t(0,f=Nr(f,c,a)),typeof a=="object"){for(let W=0;W<a.length;W++)t(18,a[W]=a[W]+"_pct",a);t(112,At=!1)}else t(18,a=a+"_pct"),t(112,At=!1);t(67,ee=ci(f))}switch(t(73,Fe=ee[c].type),Fe){case"number":t(73,Fe="value");break;case"string":t(73,Fe="category");break;case"date":t(73,Fe="time");break;default:break}if(t(19,U=U==="category"?"category":Fe),L&&U!=="category")throw Error("Horizontal charts do not support a value or time-based x-axis. You can either change your SQL query to output string values or set swapXY=false.");if(L&&d)throw Error("Horizontal charts do not support a secondary y-axis. You can either set swapXY=false or remove the y2 prop from your chart.");if(L&&t(19,U="category"),t(74,gi=Fe==="value"&&U==="category"),t(0,f=I?Fe==="category"?Vt(f,a,!1):Vt(f,c,!0):f),Fe==="time"&&t(0,f=Vt(f,c,!0)),t(116,Gi=ci(f,"array")),t(117,ft=Gi.filter(W=>W.type==="date")),t(117,ft=ft.map(W=>W.id)),ft.length>0)for(let W=0;W<ft.length;W++)t(0,f=_n(f,ft[W]));ie?t(75,Qe=xe(ie,(_=ee[c].format)==null?void 0:_.valueType)):t(75,Qe=ee[c].format),a?Be?typeof a=="object"?t(76,Se=xe(Be,(il=ee[a[0]].format)==null?void 0:il.valueType)):t(76,Se=xe(Be,(ll=ee[a].format)==null?void 0:ll.valueType)):typeof a=="object"?t(76,Se=ee[a[0]].format):t(76,Se=ee[a].format):t(76,Se="str"),d&&(Ye?typeof d=="object"?t(77,Ke=xe(Ye,(nl=ee[d[0]].format)==null?void 0:nl.valueType)):t(77,Ke=xe(Ye,(rl=ee[d].format)==null?void 0:rl.valueType)):typeof d=="object"?t(77,Ke=ee[d[0]].format):t(77,Ke=ee[d].format)),m&&(nt?t(78,Zt=xe(nt,(sl=ee[m].format)==null?void 0:sl.valueType)):t(78,Zt=ee[m].format)),t(79,bi=ee[c].columnUnitSummary),a&&(typeof a=="object"?t(80,jt=ee[a[0]].columnUnitSummary):t(80,jt=ee[a].columnUnitSummary)),d&&(typeof d=="object"?t(81,Jt=ee[d[0]].columnUnitSummary):t(81,Jt=ee[d].columnUnitSummary)),t(20,K=K==="true"?ct(c,Qe):K==="false"?"":K),t(27,ne=ne==="true"?typeof a=="object"?"":ct(a,Se):ne==="false"?"":ne),t(33,Ce=Ce==="true"?typeof d=="object"?"":ct(d,Ke):Ce==="false"?"":Ce);let Lt=typeof a=="object"?a.length:1,ol=T?Gr(f,T):1,at=Lt*ol,Ni=typeof d=="object"?d.length:d?1:0,Pi=at+Ni;if(De!==void 0&&t(39,De=De==="true"||De===!0),t(39,De=De??Pi>1),$e===!0&&J===!0)throw Error("Log axis cannot be used in a 100% stacked chart");if(_t==="stacked"&&Pi>1&&J===!0)throw Error("Log axis cannot be used in a stacked chart");let Ot;if(typeof a=="object"){Ot=ee[a[0]].columnUnitSummary.min;for(let W=0;W<a.length;W++)ee[a[W]].columnUnitSummary.min<Ot&&(Ot=ee[a[W]].columnUnitSummary.min)}else a&&(Ot=ee[a].columnUnitSummary.min);if(J===!0&&Ot<=0&&Ot!==null)throw Error("Log axis cannot display values less than or equal to zero");s.update(W=>({...W,data:f,x:c,y:a,y2:d,series:T,swapXY:L,sort:I,xType:U,xFormat:Qe,yFormat:Se,y2Format:Ke,sizeFormat:Zt,xMismatch:gi,size:m,yMin:He,y2Min:O,columnSummary:ee,xAxisTitle:K,yAxisTitle:ne,y2AxisTitle:Ce,tooltipTitle:h,chartAreaHeight:Ie,chartType:q,yCount:Lt,y2Count:Ni})),t(82,_i=vt(f,c));let fl;if(L?t(83,xt={type:de,logBase:_e,position:"top",axisLabel:{show:we,hideOverlap:!0,showMaxLabel:!0,formatter(W){return ri(W,Se,jt)},margin:4},min:He,max:qe,scale:ke,splitLine:{show:Me},axisLine:{show:me,onZero:!1},axisTick:{show:Z},boundaryGap:!1,z:2}):t(83,xt={type:U,min:Q,max:N,splitLine:{show:x},axisLine:{show:F},axisTick:{show:le},axisLabel:{show:$,hideOverlap:!0,showMaxLabel:U==="category"||U==="value",formatter:U==="time"||U==="category"?!1:function(W){return ri(W,Qe,bi)},margin:6},scale:!0,z:2}),L?t(84,wt={type:U,inverse:"true",splitLine:{show:x},axisLine:{show:F},axisTick:{show:le},axisLabel:{show:$,hideOverlap:!0},scale:!0,min:Q,max:N,z:2}):(t(84,wt={type:de,logBase:_e,splitLine:{show:Me},axisLine:{show:me,onZero:!1},axisTick:{show:Z},axisLabel:{show:we,hideOverlap:!0,margin:4,formatter(W){return ri(W,Se,jt)},color:d?ye==="true"?Le?Le[0]:Ut[0]:ye!=="false"?ye:void 0:void 0},name:ne,nameLocation:"end",nameTextStyle:{align:"left",verticalAlign:"top",padding:[0,5,0,0],color:d?ye==="true"?Le?Le[0]:Ut[0]:ye!=="false"?ye:void 0:void 0},nameGap:6,min:He,max:qe,scale:ke,boundaryGap:["0%","1%"],z:2}),fl={type:"value",show:!1,alignTicks:!0,splitLine:{show:Ue},axisLine:{show:Te,onZero:!1},axisTick:{show:Ee},axisLabel:{show:Ve,hideOverlap:!0,margin:4,formatter(W){return ri(W,Ke,Jt)},color:Xe==="true"?Le?Le[at]:Ut[at]:Xe!=="false"?Xe:void 0},name:Ce,nameLocation:"end",nameTextStyle:{align:"right",verticalAlign:"top",padding:[0,0,0,5],color:Xe==="true"?Le?Le[at]:Ut[at]:Xe!=="false"?Xe:void 0},nameGap:6,min:O,max:he,scale:pe,boundaryGap:["0%","1%"],z:2},t(84,wt=[wt,fl])),Ie){if(t(40,Ie=Number(Ie)),isNaN(Ie))throw Error("chartAreaHeight must be a number");if(Ie<=0)throw Error("chartAreaHeight must be a positive number")}else t(40,Ie=180);t(87,Gt=!!D),t(88,Ct=!!X),t(89,Ci=De*(T!==null||typeof a=="object"&&a.length>1)),t(90,Ti=ne!==""&&L),t(91,Si=K!==""&&!L),t(92,Ai=15),t(93,Li=13),t(94,Oi=6*Ct),t(95,Mi=Gt*Ai+Ct*Li+Oi*Math.max(Gt,Ct)),t(96,Ei=10),t(97,pi=8),t(98,Di=14),t(99,Ii=14),t(100,Tt=15),t(100,Tt=Tt*Ci),t(101,Nt=7),t(101,Nt=Nt*Math.max(Gt,Ct)),t(102,Pt=Mi+Nt),t(103,$t=Pt+Tt+Ii*Ti+Ei),t(104,ei=Si*Di+pi),t(108,Bi=8),t(110,ti=1),L&&(t(109,zi=_i.length),t(110,ti=Math.max(1,zi/Bi))),t(105,Fi=Ie*ti+$t+ei),t(106,qi=Pt+Tt+7),t(14,tl=Fi+"px"),t(12,ji="100%"),t(107,St=L?ne:K),St!==""&&t(107,St=St+" →"),t(85,ki={id:"horiz-axis-title",type:"text",style:{text:St,textAlign:"right",fill:We.grey500},cursor:"auto",right:L?"2%":"3%",top:L?qi:null,bottom:L?null:"2%"}),t(86,wi={title:{text:D,subtext:X,subtextStyle:{width:ji}},tooltip:{trigger:"axis",formatter(W){let Mt,Et,pt,ii;if(Pi>1){Et=W[0].value[L?1:0],Mt=`<span id="tooltip" style='font-weight: 600;'>${Oe(Et,Qe)}</span>`;for(let ut=W.length-1;ut>=0;ut--)W[ut].seriesName!=="stackTotal"&&(pt=W[ut].value[L?0:1],Mt=Mt+`<br> ${W[ut].marker} ${W[ut].seriesName} <span style='float:right; margin-left: 10px;'>${Oe(pt,Zl(W[ut].componentIndex,Lt,Ni)===0?Se:Ke)}</span>`)}else U==="value"?(Et=W[0].value[L?1:0],pt=W[0].value[L?0:1],ii=W[0].seriesName,Mt=`<span id="tooltip" style='font-weight: 600;'>${ct(c,Qe)}: </span><span style='float:right; margin-left: 10px;'>${Oe(Et,Qe)}</span><br/><span style='font-weight: 600;'>${ct(ii,Se)}: </span><span style='float:right; margin-left: 10px;'>${Oe(pt,Se)}</span>`):(Et=W[0].value[L?1:0],pt=W[0].value[L?0:1],ii=W[0].seriesName,Mt=`<span id="tooltip" style='font-weight: 600;'>${Oe(Et,Qe)}</span><br/><span>${ct(ii,Se)}: </span><span style='float:right; margin-left: 10px;'>${Oe(pt,Se)}</span>`);return Mt},confine:!0,axisPointer:{type:"shadow"},extraCssText:"box-shadow: 0 3px 6px rgba(0,0,0,.15); box-shadow: 0 2px 4px rgba(0,0,0,.12); z-index: 1;",order:"valueDesc"},legend:{show:De,type:"scroll",top:Pt,padding:[0,0,0,0],data:[]},grid:{left:"0.5%",right:L?"4%":"3%",bottom:ei,top:$t,containLabel:!0},xAxis:xt,yAxis:wt,series:[],animation:!0,graphic:ki,color:Le}),o.update(()=>wi)}catch(Lt){if(t(13,Ht=Lt.message),console.error("\x1B[31m%s\x1B[0m",`Error in ${q}: ${Lt.message}`),An)throw Ht;s.update(at=>({...at,error:Ht}))}l.$$.dirty[0]&1},Xt(Vl,s),Xt(Xl,o),[f,A,L,u,w,D,q,It,Ft,qt,Bt,zt,ji,Ht,tl,i,o,c,a,U,K,F,le,x,$,I,J,ne,me,Z,Me,we,ke,Ce,Te,Ee,Ue,Ve,pe,De,Ie,d,T,m,h,X,g,E,P,ie,Q,N,de,_e,He,qe,Be,ye,O,he,Ye,Xe,nt,Le,_t,$e,v,ee,rt,y,ve,kt,st,Fe,gi,Qe,Se,Ke,Zt,bi,jt,Jt,_i,xt,wt,ki,wi,Gt,Ct,Ci,Ti,Si,Ai,Li,Oi,Mi,Ei,pi,Di,Ii,Tt,Nt,Pt,$t,ei,Fi,qi,St,Bi,zi,ti,ot,At,Ze,Wt,Re,Gi,ft,r,n]}class Rr extends Ne{constructor(e){super(),Pe(this,e,Xr,Vr,Ge,{data:0,queryID:3,x:17,y:18,y2:41,series:42,size:43,tooltipTitle:44,showAllXAxisLabels:4,printEchartsConfig:1,swapXY:2,title:5,subtitle:45,chartType:6,bubble:46,hist:47,boxplot:48,xType:19,xAxisTitle:20,xBaseline:21,xTickMarks:22,xGridlines:23,xAxisLabels:24,sort:25,xFmt:49,xMin:50,xMax:51,yLog:26,yType:52,yLogBase:53,yAxisTitle:27,yBaseline:28,yTickMarks:29,yGridlines:30,yAxisLabels:31,yMin:54,yMax:55,yScale:32,yFmt:56,yAxisColor:57,y2AxisTitle:33,y2Baseline:34,y2TickMarks:35,y2Gridlines:36,y2AxisLabels:37,y2Min:58,y2Max:59,y2Scale:38,y2Fmt:60,y2AxisColor:61,sizeFmt:62,colorPalette:63,legend:39,echartsOptions:7,seriesOptions:8,seriesColors:9,stackType:64,stacked100:65,chartAreaHeight:40,renderer:10,connectGroup:11},null,[-1,-1,-1,-1])}}function Yr(l){let e;const t=l[6].default,i=hi(t,l,l[7],null);return{c(){i&&i.c()},l(n){i&&i.l(n)},m(n,r){i&&i.m(n,r),e=!0},p(n,r){i&&i.p&&(!e||r&128)&&di(i,t,n,n[7],e?yi(t,n[7],r,null):mi(n[7]),null)},i(n){e||(G(i,n),e=!0)},o(n){H(i,n),e=!1},d(n){i&&i.d(n)}}}function Qr(l){let e,t;const i=[l[4],{data:Je.isQuery(l[10])?Array.from(l[10]):l[10]},{queryID:l[5]}];let n={$$slots:{default:[Yr]},$$scope:{ctx:l}};for(let r=0;r<i.length;r+=1)n=Yt(n,i[r]);return e=new Rr({props:n}),{c(){se(e.$$.fragment)},l(r){oe(e.$$.fragment,r)},m(r,s){fe(e,r,s),t=!0},p(r,s){const o=s&1072?dn(i,[s&16&&mn(r[4]),s&1024&&{data:Je.isQuery(r[10])?Array.from(r[10]):r[10]},s&32&&{queryID:r[5]}]):{};s&128&&(o.$$scope={dirty:s,ctx:r}),e.$set(o)},i(r){t||(G(e.$$.fragment,r),t=!0)},o(r){H(e.$$.fragment,r),t=!1},d(r){ae(e,r)}}}function vr(l){let e,t;return e=new Yl({props:{slot:"empty",emptyMessage:l[2],emptySet:l[1],chartType:l[4].chartType,isInitial:l[3]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&4&&(r.emptyMessage=i[2]),n&2&&(r.emptySet=i[1]),n&16&&(r.chartType=i[4].chartType),n&8&&(r.isInitial=i[3]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Kr(l){let e,t;return e=new Rl({props:{slot:"error",chartType:l[4].chartType,error:l[10].error.message}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&16&&(r.chartType=i[4].chartType),n&1024&&(r.error=i[10].error.message),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Zr(l){let e,t;return e=new Ln({props:{data:l[0],$$slots:{error:[Kr,({loaded:i})=>({10:i}),({loaded:i})=>i?1024:0],empty:[vr],default:[Qr,({loaded:i})=>({10:i}),({loaded:i})=>i?1024:0]},$$scope:{ctx:l}}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,[n]){const r={};n&1&&(r.data=i[0]),n&1182&&(r.$$scope={dirty:n,ctx:i}),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function Jr(l,e,t){let i,{$$slots:n={},$$scope:r}=e,{data:s}=e;const o=Je.isQuery(s)?s.hash:void 0;let f=(s==null?void 0:s.hash)===o,{emptySet:u=void 0}=e,{emptyMessage:c=void 0}=e,a=s==null?void 0:s.id;return l.$$set=d=>{t(9,e=Yt(Yt({},e),Ri(d))),"data"in d&&t(0,s=d.data),"emptySet"in d&&t(1,u=d.emptySet),"emptyMessage"in d&&t(2,c=d.emptyMessage),"$$scope"in d&&t(7,r=d.$$scope)},l.$$.update=()=>{l.$$.dirty&1&&t(3,f=(s==null?void 0:s.hash)===o),t(4,i={...Object.fromEntries(Object.entries(e).filter(([,d])=>d!==void 0))})},e=Ri(e),[s,u,c,f,i,a,n,r]}class xr extends Ne{constructor(e){super(),Pe(this,e,Jr,Zr,Ge,{data:0,emptySet:1,emptyMessage:2})}}function $r(l,e,t,i,n,r,s,o,f,u=void 0,c=void 0,a=void 0){function d(g,E,P,v){let U={name:E,data:g,yAxisIndex:P};return U={...v,...U},U}let T,m,h,w=[],A,k,C,L,D;function X(g,E){const P=[];function v(K){return typeof K>"u"}function U(K,F){v(K)||(Array.isArray(K)?K.forEach(le=>P.push([le,F])):P.push([K,F]))}return U(g,0),U(E,1),P}let q=X(t,a);if(i!=null&&q.length===1)for(L=vt(l,i),T=0;T<L.length;T++){if(k=l.filter(g=>g[i]===L[T]),n?A=k.map(g=>[g[q[0][0]],o?g[e].toString():g[e]]):A=k.map(g=>[o?g[e].toString():g[e],g[q[0][0]]]),u){let g=k.map(E=>E[u]);A.forEach((E,P)=>E.push(g[P]))}if(c){let g=k.map(E=>E[c]);A.forEach((E,P)=>E.push(g[P]))}C=L[T]??"null",D=q[0][1],h=d(A,C,D,r),w.push(h)}if(i!=null&&q.length>1)for(L=vt(l,i),T=0;T<L.length;T++)for(k=l.filter(g=>g[i]===L[T]),m=0;m<q.length;m++){if(n?A=k.map(g=>[g[q[m][0]],o?g[e].toString():g[e]]):A=k.map(g=>[o?g[e].toString():g[e],g[q[m][0]]]),u){let g=k.map(E=>E[u]);A.forEach((E,P)=>E.push(g[P]))}if(c){let g=k.map(E=>E[c]);A.forEach((E,P)=>E.push(g[P]))}C=(L[T]??"null")+" - "+f[q[m][0]].title,D=q[m][1],h=d(A,C,D,r),w.push(h)}if(i==null&&q.length>1)for(T=0;T<q.length;T++){if(n?A=l.map(g=>[g[q[T][0]],o?g[e].toString():g[e]]):A=l.map(g=>[o?g[e].toString():g[e],g[q[T][0]]]),u){let g=l.map(E=>E[u]);A.forEach((E,P)=>E.push(g[P]))}if(c){let g=l.map(E=>E[c]);A.forEach((E,P)=>E.push(g[P]))}C=f[q[T][0]].title,D=q[T][1],h=d(A,C,D,r),w.push(h)}if(i==null&&q.length===1){if(n?A=l.map(g=>[g[q[0][0]],o?g[e].toString():g[e]]):A=l.map(g=>[o?g[e].toString():g[e],g[q[0][0]]]),u){let g=l.map(E=>E[u]);A.forEach((E,P)=>E.push(g[P]))}if(c){let g=l.map(E=>E[c]);A.forEach((E,P)=>E.push(g[P]))}C=f[q[0][0]].title,D=q[0][1],h=d(A,C,D,r),w.push(h)}return w}function es(l){let e=[];for(let t=1;t<l.length;t++)e.push(l[t]-l[t-1]);return e}function Jl(l,e){return(typeof l!="number"||isNaN(l))&&(l=0),(typeof e!="number"||isNaN(e))&&(e=0),l=Math.abs(l),e=Math.abs(e),e<=.01?l:Jl(e,l%e)}function ts(l,e){if(!Array.isArray(l))throw new TypeError("Cannot calculate extent of non-array value.");let t,i;for(const n of l)typeof n=="number"&&(t===void 0?n>=n&&(t=i=n):(t>n&&(t=n),i<n&&(i=n)));return[t,i]}function is(l,e){let[t,i]=ts(l);const n=[];let r=t;for(;r<=i;)n.push(Math.round((r+Number.EPSILON)*1e8)/1e8),r+=e;return n}function ls(l){if(l.length<=1)return;l.sort(function(t,i){return t-i}),l=l.map(function(t){return t*1e8}),l=es(l);let e=l.reduce((t,i)=>Jl(t,i))/1e8;return e=Math.round((e+Number.EPSILON)*1e8)/1e8,e}function Hi(l,e,t,i,n=!1,r=!1){var T;let s=!1;const o=l.map(m=>Object.assign({},m,{[e]:m[e]instanceof Date?(s=!0,m[e].toISOString()):m[e]})).filter(m=>m[e]!==void 0&&m[e]!==null),f=Array.from(o).reduce((m,h)=>(h[e]instanceof Date&&(h[e]=h[e].toISOString(),s=!0),i?(m[h[i]??"null"]||(m[h[i]??"null"]=[]),m[h[i]??"null"].push(h)):(m.default||(m.default=[]),m.default.push(h)),m),{}),u={};let c;const a=((T=o.find(m=>m&&m[e]!==null&&m[e]!==void 0))==null?void 0:T[e])??null;switch(typeof a){case"object":throw a===null?new Error(`Column '${e}' is entirely null. Column must contain at least one non-null value.`):new Error("Unexpected object property, expected string, date, or number");case"number":if(c=vt(o,e),r){const m=ls(c);u[e]=is(c,m)}break;case"string":c=vt(o,e),u[e]=c;break}const d=[];for(const m of Object.values(f)){const h=i?{[i]:null}:{};if(n)if(t instanceof Array)for(let A=0;A<t.length;A++)h[t[A]]=0;else h[t]=0;else if(t instanceof Array)for(let A=0;A<t.length;A++)h[t[A]]=null;else h[t]=null;i&&(u[i]=i);const w=[];Object.keys(u).length===0?w.push(_l([e],h)):w.push(_l(u,h)),d.push(dt(m,...w))}return s?d.flat().map(m=>({...m,[e]:new Date(m[e])})):d.flat()}function Pl(l,e,t){let i=dt(l,Qi(e,[On(t,Ki)]));if(typeof t=="object")for(let n=0;n<i.length;n++){i[n].stackTotal=0;for(let r=0;r<t.length;r++)i[n].stackTotal=i[n].stackTotal+i[n][t[r]]}return i}let ns=60;function rs(l,e,t){let i,n,r,s,o,f,u,c,a,d,T,m,h,w,A,k,C,L=re,D=()=>(L(),L=Hl(i,O=>t(44,C=O)),i);l.$$.on_destroy.push(()=>L());let{y:X=void 0}=e;const q=!!X;let{y2:g=void 0}=e;const E=!!g;let{series:P=void 0}=e;const v=!!P;let{options:U=void 0}=e,{name:K=void 0}=e,{type:F="stacked"}=e,{stackName:le=void 0}=e,{fillColor:x=void 0}=e,{fillOpacity:$=void 0}=e,{outlineColor:I=void 0}=e,{outlineWidth:ie=void 0}=e,{labels:Q=!1}=e,{seriesLabels:N=!0}=e,{labelSize:J=11}=e,{labelPosition:de=void 0}=e,{labelColor:_e=void 0}=e,{labelFmt:ne=void 0}=e,me;ne&&(me=xe(ne));let{yLabelFmt:Z=void 0}=e,Me;Z&&(Me=xe(Z));let{y2LabelFmt:we=void 0}=e,He;we&&(He=xe(we));let{y2SeriesType:qe="bar"}=e,{stackTotalLabel:ke=!0}=e,{showAllLabels:Be=!1}=e,ye,Ce,Te,Ee;const Ue={outside:"top",inside:"inside"},Ve={outside:"right",inside:"inside"};return nn(()=>{U&&n.update(O=>({...O,...U})),k&&n.update(O=>{if(F.includes("stacked")?O.tooltip={...O.tooltip,order:"seriesDesc"}:O.tooltip={...O.tooltip,order:"seriesAsc"},F==="stacked100"&&(a?O.xAxis={...O.xAxis,max:1}:O.yAxis[0]={...O.yAxis[0],max:1}),a)O.yAxis={...O.yAxis,...k.xAxis},O.xAxis={...O.xAxis,...k.yAxis};else if(O.yAxis[0]={...O.yAxis[0],...k.yAxis},O.xAxis={...O.xAxis,...k.xAxis},g&&(O.yAxis[1]={...O.yAxis[1],show:!0},["line","bar","scatter"].includes(qe)))for(let he=0;he<c;he++)O.series[u+he].type=qe,O.series[u+he].stack=void 0;return O})}),l.$$set=O=>{"y"in O&&t(1,X=O.y),"y2"in O&&t(2,g=O.y2),"series"in O&&t(3,P=O.series),"options"in O&&t(10,U=O.options),"name"in O&&t(4,K=O.name),"type"in O&&t(11,F=O.type),"stackName"in O&&t(5,le=O.stackName),"fillColor"in O&&t(12,x=O.fillColor),"fillOpacity"in O&&t(13,$=O.fillOpacity),"outlineColor"in O&&t(14,I=O.outlineColor),"outlineWidth"in O&&t(15,ie=O.outlineWidth),"labels"in O&&t(6,Q=O.labels),"seriesLabels"in O&&t(7,N=O.seriesLabels),"labelSize"in O&&t(16,J=O.labelSize),"labelPosition"in O&&t(8,de=O.labelPosition),"labelColor"in O&&t(17,_e=O.labelColor),"labelFmt"in O&&t(18,ne=O.labelFmt),"yLabelFmt"in O&&t(19,Z=O.yLabelFmt),"y2LabelFmt"in O&&t(20,we=O.y2LabelFmt),"y2SeriesType"in O&&t(21,qe=O.y2SeriesType),"stackTotalLabel"in O&&t(9,ke=O.stackTotalLabel),"showAllLabels"in O&&t(22,Be=O.showAllLabels)},l.$$.update=()=>{l.$$.dirty[0]&64&&t(6,Q=Q==="true"||Q===!0),l.$$.dirty[0]&128&&t(7,N=N==="true"||N===!0),l.$$.dirty[0]&512&&t(9,ke=ke==="true"||ke===!0),l.$$.dirty[1]&8192&&t(41,r=C.data),l.$$.dirty[1]&8192&&t(37,s=C.x),l.$$.dirty[0]&2|l.$$.dirty[1]&8192&&t(1,X=q?X:C.y),l.$$.dirty[0]&4|l.$$.dirty[1]&8192&&t(2,g=E?g:C.y2),l.$$.dirty[1]&8192&&t(35,o=C.yFormat),l.$$.dirty[1]&8192&&t(42,f=C.y2Format),l.$$.dirty[1]&8192&&t(30,u=C.yCount),l.$$.dirty[1]&8192&&t(31,c=C.y2Count),l.$$.dirty[1]&8192&&t(32,a=C.swapXY),l.$$.dirty[1]&8192&&t(34,d=C.xType),l.$$.dirty[1]&8192&&t(38,T=C.xMismatch),l.$$.dirty[1]&8192&&t(39,m=C.columnSummary),l.$$.dirty[1]&8192&&t(43,h=C.sort),l.$$.dirty[0]&8|l.$$.dirty[1]&8192&&t(3,P=v?P:C.series),l.$$.dirty[0]&201328698|l.$$.dirty[1]&5450&&(!P&&typeof X!="object"?(t(4,K=K??ct(X,m[X].title)),a&&d!=="category"&&(t(41,r=Hi(r,s,X,P,!0,d!=="time")),t(34,d="category")),t(5,le="stack1"),t(28,Te=a?"right":"top")):(h===!0&&d==="category"&&(t(26,ye=Pl(r,s,X)),typeof X=="object"?t(26,ye=Vt(ye,"stackTotal",!1)):t(26,ye=Vt(ye,X,!1)),t(27,Ce=ye.map(O=>O[s])),t(41,r=[...r].sort(function(O,he){return Ce.indexOf(O[s])-Ce.indexOf(he[s])}))),a||(d==="value"||d==="category")&&F.includes("stacked")?(t(41,r=Hi(r,s,X,P,!0,d==="value")),t(34,d="category")):d==="time"&&F.includes("stacked")&&t(41,r=Hi(r,s,X,P,!0,!0)),F.includes("stacked")?(t(5,le=le??"stack1"),t(28,Te="inside")):(t(5,le=void 0),t(28,Te=a?"right":"top")))),l.$$.dirty[0]&2050|l.$$.dirty[1]&1088&&F==="stacked"&&t(29,Ee=Pl(r,s,X)),l.$$.dirty[0]&268435712|l.$$.dirty[1]&2&&t(8,de=(a?Ve[de]:Ue[de])??Te),l.$$.dirty[0]&1136914912|l.$$.dirty[1]&2067&&t(40,w={type:"bar",stack:le,label:{show:Q&&N,formatter(O){return O.value[a?0:1]===0?"":Oe(O.value[a?0:1],[Me??me??o,He??me??f][Zl(O.componentIndex,u,c)])},position:de,fontSize:J,color:_e},labelLayout:{hideOverlap:!Be},emphasis:{focus:"series"},barMaxWidth:ns,itemStyle:{color:x,opacity:$,borderColor:I,borderWidth:ie}}),l.$$.dirty[0]&30|l.$$.dirty[1]&1986&&t(36,A=$r(r,s,X,P,a,w,K,T,m,void 0,void 0,g)),l.$$.dirty[0]&545327722|l.$$.dirty[1]&246&&n.update(O=>(O.series.push(...A),O.legend.data.push(...A.map(he=>he.name.toString())),Q===!0&&F==="stacked"&&typeof X=="object"|P!==void 0&&ke===!0&&P!==s&&(O.series.push({type:"bar",stack:le,name:"stackTotal",color:"none",data:Ee.map(he=>[a?0:T?he[s].toString():he[s],a?T?he[s].toString():he[s]:0]),label:{show:!0,position:a?"right":"top",formatter(he){let pe=0;return A.forEach(Ye=>{pe+=Ye.data[he.dataIndex][a?0:1]}),pe===0?"":Oe(pe,me??o)},fontWeight:"bold",fontSize:J,padding:a?[0,0,0,5]:void 0}}),O.legend.selectedMode=!1),O)),l.$$.dirty[1]&8&&(k={xAxis:{boundaryGap:["1%","2%"],type:d}})},D(t(0,i=Xi(Vl))),t(33,n=Xi(Xl)),[i,X,g,P,K,le,Q,N,de,ke,U,F,x,$,I,ie,J,_e,ne,Z,we,qe,Be,me,Me,He,ye,Ce,Te,Ee,u,c,a,n,d,o,A,s,T,m,w,r,f,h,C]}class ss extends Ne{constructor(e){super(),Pe(this,e,rs,null,Ge,{y:1,y2:2,series:3,options:10,name:4,type:11,stackName:5,fillColor:12,fillOpacity:13,outlineColor:14,outlineWidth:15,labels:6,seriesLabels:7,labelSize:16,labelPosition:8,labelColor:17,labelFmt:18,yLabelFmt:19,y2LabelFmt:20,y2SeriesType:21,stackTotalLabel:9,showAllLabels:22},null,[-1,-1])}}function os(l){let e,t,i;e=new ss({props:{type:l[38],fillColor:l[39],fillOpacity:l[40],outlineColor:l[41],outlineWidth:l[42],labels:l[46],labelSize:l[47],labelPosition:l[48],labelColor:l[49],labelFmt:l[50],yLabelFmt:l[51],y2LabelFmt:l[52],stackTotalLabel:l[53],seriesLabels:l[54],showAllLabels:l[55],y2SeriesType:l[10]}});const n=l[68].default,r=hi(n,l,l[69],null);return{c(){se(e.$$.fragment),t=R(),r&&r.c()},l(s){oe(e.$$.fragment,s),t=Y(s),r&&r.l(s)},m(s,o){fe(e,s,o),p(s,t,o),r&&r.m(s,o),i=!0},p(s,o){const f={};o[1]&128&&(f.type=s[38]),o[1]&256&&(f.fillColor=s[39]),o[1]&512&&(f.fillOpacity=s[40]),o[1]&1024&&(f.outlineColor=s[41]),o[1]&2048&&(f.outlineWidth=s[42]),o[1]&32768&&(f.labels=s[46]),o[1]&65536&&(f.labelSize=s[47]),o[1]&131072&&(f.labelPosition=s[48]),o[1]&262144&&(f.labelColor=s[49]),o[1]&524288&&(f.labelFmt=s[50]),o[1]&1048576&&(f.yLabelFmt=s[51]),o[1]&2097152&&(f.y2LabelFmt=s[52]),o[1]&4194304&&(f.stackTotalLabel=s[53]),o[1]&8388608&&(f.seriesLabels=s[54]),o[1]&16777216&&(f.showAllLabels=s[55]),o[0]&1024&&(f.y2SeriesType=s[10]),e.$set(f),r&&r.p&&(!i||o[2]&128)&&di(r,n,s,s[69],i?yi(n,s[69],o,null):mi(s[69]),null)},i(s){i||(G(e.$$.fragment,s),G(r,s),i=!0)},o(s){H(e.$$.fragment,s),H(r,s),i=!1},d(s){s&&b(t),ae(e,s),r&&r.d(s)}}}function fs(l){let e,t;return e=new xr({props:{data:l[2],x:l[3],y:l[4],y2:l[5],xFmt:l[13],yFmt:l[11],y2Fmt:l[12],series:l[6],xType:l[7],yLog:l[8],yLogBase:l[9],legend:l[16],xAxisTitle:l[17],yAxisTitle:l[18],y2AxisTitle:l[19],xGridlines:l[20],yGridlines:l[21],y2Gridlines:l[22],xAxisLabels:l[23],yAxisLabels:l[24],y2AxisLabels:l[25],xBaseline:l[26],yBaseline:l[27],y2Baseline:l[28],xTickMarks:l[29],yTickMarks:l[30],y2TickMarks:l[31],yAxisColor:l[56],y2AxisColor:l[57],yMin:l[32],yMax:l[33],yScale:l[34],y2Min:l[35],y2Max:l[36],y2Scale:l[37],swapXY:l[0],title:l[14],subtitle:l[15],chartType:"Bar Chart",stackType:l[38],sort:l[44],stacked100:l[66],chartAreaHeight:l[43],showAllXAxisLabels:l[1],colorPalette:l[45],echartsOptions:l[58],seriesOptions:l[59],printEchartsConfig:l[60],emptySet:l[61],emptyMessage:l[62],renderer:l[63],connectGroup:l[65],seriesColors:l[64],$$slots:{default:[os]},$$scope:{ctx:l}}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n[0]&4&&(r.data=i[2]),n[0]&8&&(r.x=i[3]),n[0]&16&&(r.y=i[4]),n[0]&32&&(r.y2=i[5]),n[0]&8192&&(r.xFmt=i[13]),n[0]&2048&&(r.yFmt=i[11]),n[0]&4096&&(r.y2Fmt=i[12]),n[0]&64&&(r.series=i[6]),n[0]&128&&(r.xType=i[7]),n[0]&256&&(r.yLog=i[8]),n[0]&512&&(r.yLogBase=i[9]),n[0]&65536&&(r.legend=i[16]),n[0]&131072&&(r.xAxisTitle=i[17]),n[0]&262144&&(r.yAxisTitle=i[18]),n[0]&524288&&(r.y2AxisTitle=i[19]),n[0]&1048576&&(r.xGridlines=i[20]),n[0]&2097152&&(r.yGridlines=i[21]),n[0]&4194304&&(r.y2Gridlines=i[22]),n[0]&8388608&&(r.xAxisLabels=i[23]),n[0]&16777216&&(r.yAxisLabels=i[24]),n[0]&33554432&&(r.y2AxisLabels=i[25]),n[0]&67108864&&(r.xBaseline=i[26]),n[0]&134217728&&(r.yBaseline=i[27]),n[0]&268435456&&(r.y2Baseline=i[28]),n[0]&536870912&&(r.xTickMarks=i[29]),n[0]&1073741824&&(r.yTickMarks=i[30]),n[1]&1&&(r.y2TickMarks=i[31]),n[1]&33554432&&(r.yAxisColor=i[56]),n[1]&67108864&&(r.y2AxisColor=i[57]),n[1]&2&&(r.yMin=i[32]),n[1]&4&&(r.yMax=i[33]),n[1]&8&&(r.yScale=i[34]),n[1]&16&&(r.y2Min=i[35]),n[1]&32&&(r.y2Max=i[36]),n[1]&64&&(r.y2Scale=i[37]),n[0]&1&&(r.swapXY=i[0]),n[0]&16384&&(r.title=i[14]),n[0]&32768&&(r.subtitle=i[15]),n[1]&128&&(r.stackType=i[38]),n[1]&8192&&(r.sort=i[44]),n[1]&4096&&(r.chartAreaHeight=i[43]),n[0]&2&&(r.showAllXAxisLabels=i[1]),n[1]&16384&&(r.colorPalette=i[45]),n[1]&134217728&&(r.echartsOptions=i[58]),n[1]&268435456&&(r.seriesOptions=i[59]),n[1]&536870912&&(r.printEchartsConfig=i[60]),n[1]&1073741824&&(r.emptySet=i[61]),n[2]&1&&(r.emptyMessage=i[62]),n[2]&2&&(r.renderer=i[63]),n[2]&8&&(r.connectGroup=i[65]),n[2]&4&&(r.seriesColors=i[64]),n[0]&1024|n[1]&33525632|n[2]&128&&(r.$$scope={dirty:n,ctx:i}),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function as(l,e,t){let{$$slots:i={},$$scope:n}=e,{data:r=void 0}=e,{x:s=void 0}=e,{y:o=void 0}=e,{y2:f=void 0}=e,{series:u=void 0}=e,{xType:c=void 0}=e,{yLog:a=void 0}=e,{yLogBase:d=void 0}=e,{y2SeriesType:T=void 0}=e,{yFmt:m=void 0}=e,{y2Fmt:h=void 0}=e,{xFmt:w=void 0}=e,{title:A=void 0}=e,{subtitle:k=void 0}=e,{legend:C=void 0}=e,{xAxisTitle:L=void 0}=e,{yAxisTitle:D=f?"true":void 0}=e,{y2AxisTitle:X=f?"true":void 0}=e,{xGridlines:q=void 0}=e,{yGridlines:g=void 0}=e,{y2Gridlines:E=void 0}=e,{xAxisLabels:P=void 0}=e,{yAxisLabels:v=void 0}=e,{y2AxisLabels:U=void 0}=e,{xBaseline:K=void 0}=e,{yBaseline:F=void 0}=e,{y2Baseline:le=void 0}=e,{xTickMarks:x=void 0}=e,{yTickMarks:$=void 0}=e,{y2TickMarks:I=void 0}=e,{yMin:ie=void 0}=e,{yMax:Q=void 0}=e,{yScale:N=void 0}=e,{y2Min:J=void 0}=e,{y2Max:de=void 0}=e,{y2Scale:_e=void 0}=e,{swapXY:ne=!1}=e,me;Yi(()=>{var y,ve,kt;t(67,me=(kt=(ve=(y=r==null?void 0:r[0])==null?void 0:y._evidenceColumnTypes)==null?void 0:ve.find(st=>{var Fe;return((Fe=st.name)==null?void 0:Fe.toLowerCase())===(s==null?void 0:s.toLowerCase())}))==null?void 0:kt.evidenceType)});let{showAllXAxisLabels:Z}=e;const Me=typeof Z<"u";let{type:we="stacked"}=e,He=we==="stacked100",{fillColor:qe=void 0}=e,{fillOpacity:ke=void 0}=e,{outlineColor:Be=void 0}=e,{outlineWidth:ye=void 0}=e,{chartAreaHeight:Ce=void 0}=e,{sort:Te=void 0}=e,{colorPalette:Ee=void 0}=e,{labels:Ue=void 0}=e,{labelSize:Ve=void 0}=e,{labelPosition:O=void 0}=e,{labelColor:he=void 0}=e,{labelFmt:pe=void 0}=e,{yLabelFmt:Ye=void 0}=e,{y2LabelFmt:Xe=void 0}=e,{stackTotalLabel:nt=void 0}=e,{seriesLabels:Le=void 0}=e,{showAllLabels:De=void 0}=e,{yAxisColor:It=void 0}=e,{y2AxisColor:Ft=void 0}=e,{echartsOptions:qt=void 0}=e,{seriesOptions:_t=void 0}=e,{printEchartsConfig:$e=!1}=e,{emptySet:Ie=void 0}=e,{emptyMessage:Bt=void 0}=e,{renderer:zt=void 0}=e,{seriesColors:ee=void 0}=e,{connectGroup:rt=void 0}=e;return l.$$set=y=>{"data"in y&&t(2,r=y.data),"x"in y&&t(3,s=y.x),"y"in y&&t(4,o=y.y),"y2"in y&&t(5,f=y.y2),"series"in y&&t(6,u=y.series),"xType"in y&&t(7,c=y.xType),"yLog"in y&&t(8,a=y.yLog),"yLogBase"in y&&t(9,d=y.yLogBase),"y2SeriesType"in y&&t(10,T=y.y2SeriesType),"yFmt"in y&&t(11,m=y.yFmt),"y2Fmt"in y&&t(12,h=y.y2Fmt),"xFmt"in y&&t(13,w=y.xFmt),"title"in y&&t(14,A=y.title),"subtitle"in y&&t(15,k=y.subtitle),"legend"in y&&t(16,C=y.legend),"xAxisTitle"in y&&t(17,L=y.xAxisTitle),"yAxisTitle"in y&&t(18,D=y.yAxisTitle),"y2AxisTitle"in y&&t(19,X=y.y2AxisTitle),"xGridlines"in y&&t(20,q=y.xGridlines),"yGridlines"in y&&t(21,g=y.yGridlines),"y2Gridlines"in y&&t(22,E=y.y2Gridlines),"xAxisLabels"in y&&t(23,P=y.xAxisLabels),"yAxisLabels"in y&&t(24,v=y.yAxisLabels),"y2AxisLabels"in y&&t(25,U=y.y2AxisLabels),"xBaseline"in y&&t(26,K=y.xBaseline),"yBaseline"in y&&t(27,F=y.yBaseline),"y2Baseline"in y&&t(28,le=y.y2Baseline),"xTickMarks"in y&&t(29,x=y.xTickMarks),"yTickMarks"in y&&t(30,$=y.yTickMarks),"y2TickMarks"in y&&t(31,I=y.y2TickMarks),"yMin"in y&&t(32,ie=y.yMin),"yMax"in y&&t(33,Q=y.yMax),"yScale"in y&&t(34,N=y.yScale),"y2Min"in y&&t(35,J=y.y2Min),"y2Max"in y&&t(36,de=y.y2Max),"y2Scale"in y&&t(37,_e=y.y2Scale),"swapXY"in y&&t(0,ne=y.swapXY),"showAllXAxisLabels"in y&&t(1,Z=y.showAllXAxisLabels),"type"in y&&t(38,we=y.type),"fillColor"in y&&t(39,qe=y.fillColor),"fillOpacity"in y&&t(40,ke=y.fillOpacity),"outlineColor"in y&&t(41,Be=y.outlineColor),"outlineWidth"in y&&t(42,ye=y.outlineWidth),"chartAreaHeight"in y&&t(43,Ce=y.chartAreaHeight),"sort"in y&&t(44,Te=y.sort),"colorPalette"in y&&t(45,Ee=y.colorPalette),"labels"in y&&t(46,Ue=y.labels),"labelSize"in y&&t(47,Ve=y.labelSize),"labelPosition"in y&&t(48,O=y.labelPosition),"labelColor"in y&&t(49,he=y.labelColor),"labelFmt"in y&&t(50,pe=y.labelFmt),"yLabelFmt"in y&&t(51,Ye=y.yLabelFmt),"y2LabelFmt"in y&&t(52,Xe=y.y2LabelFmt),"stackTotalLabel"in y&&t(53,nt=y.stackTotalLabel),"seriesLabels"in y&&t(54,Le=y.seriesLabels),"showAllLabels"in y&&t(55,De=y.showAllLabels),"yAxisColor"in y&&t(56,It=y.yAxisColor),"y2AxisColor"in y&&t(57,Ft=y.y2AxisColor),"echartsOptions"in y&&t(58,qt=y.echartsOptions),"seriesOptions"in y&&t(59,_t=y.seriesOptions),"printEchartsConfig"in y&&t(60,$e=y.printEchartsConfig),"emptySet"in y&&t(61,Ie=y.emptySet),"emptyMessage"in y&&t(62,Bt=y.emptyMessage),"renderer"in y&&t(63,zt=y.renderer),"seriesColors"in y&&t(64,ee=y.seriesColors),"connectGroup"in y&&t(65,rt=y.connectGroup),"$$scope"in y&&t(69,n=y.$$scope)},l.$$.update=()=>{l.$$.dirty[0]&128|l.$$.dirty[2]&32&&(Me||t(1,Z=c==="category"||me==="string")),l.$$.dirty[0]&2&&typeof Z=="string"&&t(1,Z=(Z==null?void 0:Z.toLowerCase())==="true"),l.$$.dirty[0]&1&&(ne==="true"||ne===!0?t(0,ne=!0):t(0,ne=!1))},[ne,Z,r,s,o,f,u,c,a,d,T,m,h,w,A,k,C,L,D,X,q,g,E,P,v,U,K,F,le,x,$,I,ie,Q,N,J,de,_e,we,qe,ke,Be,ye,Ce,Te,Ee,Ue,Ve,O,he,pe,Ye,Xe,nt,Le,De,It,Ft,qt,_t,$e,Ie,Bt,zt,ee,rt,He,me,i,n]}class us extends Ne{constructor(e){super(),Pe(this,e,as,fs,Ge,{data:2,x:3,y:4,y2:5,series:6,xType:7,yLog:8,yLogBase:9,y2SeriesType:10,yFmt:11,y2Fmt:12,xFmt:13,title:14,subtitle:15,legend:16,xAxisTitle:17,yAxisTitle:18,y2AxisTitle:19,xGridlines:20,yGridlines:21,y2Gridlines:22,xAxisLabels:23,yAxisLabels:24,y2AxisLabels:25,xBaseline:26,yBaseline:27,y2Baseline:28,xTickMarks:29,yTickMarks:30,y2TickMarks:31,yMin:32,yMax:33,yScale:34,y2Min:35,y2Max:36,y2Scale:37,swapXY:0,showAllXAxisLabels:1,type:38,fillColor:39,fillOpacity:40,outlineColor:41,outlineWidth:42,chartAreaHeight:43,sort:44,colorPalette:45,labels:46,labelSize:47,labelPosition:48,labelColor:49,labelFmt:50,yLabelFmt:51,y2LabelFmt:52,stackTotalLabel:53,seriesLabels:54,showAllLabels:55,yAxisColor:56,y2AxisColor:57,echartsOptions:58,seriesOptions:59,printEchartsConfig:60,emptySet:61,emptyMessage:62,renderer:63,seriesColors:64,connectGroup:65},null,[-1,-1,-1])}}function cs(l){let e,t=te.title+"",i;return{c(){e=z("h1"),i=ue(t),this.h()},l(n){e=j(n,"H1",{class:!0});var r=V(e);i=ce(r,t),r.forEach(b),this.h()},h(){S(e,"class","title")},m(n,r){p(n,e,r),B(e,i)},p:re,d(n){n&&b(e)}}}function hs(l){return{c(){this.h()},l(e){this.h()},h(){document.title="Evidence"},m:re,p:re,d:re}}function ds(l){let e,t,i,n,r;return document.title=e=te.title,{c(){t=R(),i=z("meta"),n=R(),r=z("meta"),this.h()},l(s){t=Y(s),i=j(s,"META",{property:!0,content:!0}),n=Y(s),r=j(s,"META",{name:!0,content:!0}),this.h()},h(){var s,o;S(i,"property","og:title"),S(i,"content",((s=te.og)==null?void 0:s.title)??te.title),S(r,"name","twitter:title"),S(r,"content",((o=te.og)==null?void 0:o.title)??te.title)},m(s,o){p(s,t,o),p(s,i,o),p(s,n,o),p(s,r,o)},p(s,o){o&0&&e!==(e=te.title)&&(document.title=e)},d(s){s&&(b(t),b(i),b(n),b(r))}}}function ms(l){var r,s;let e,t,i=(te.description||((r=te.og)==null?void 0:r.description))&&ys(),n=((s=te.og)==null?void 0:s.image)&&gs();return{c(){i&&i.c(),e=R(),n&&n.c(),t=be()},l(o){i&&i.l(o),e=Y(o),n&&n.l(o),t=be()},m(o,f){i&&i.m(o,f),p(o,e,f),n&&n.m(o,f),p(o,t,f)},p(o,f){var u,c;(te.description||(u=te.og)!=null&&u.description)&&i.p(o,f),(c=te.og)!=null&&c.image&&n.p(o,f)},d(o){o&&(b(e),b(t)),i&&i.d(o),n&&n.d(o)}}}function ys(l){let e,t,i,n,r;return{c(){e=z("meta"),t=R(),i=z("meta"),n=R(),r=z("meta"),this.h()},l(s){e=j(s,"META",{name:!0,content:!0}),t=Y(s),i=j(s,"META",{property:!0,content:!0}),n=Y(s),r=j(s,"META",{name:!0,content:!0}),this.h()},h(){var s,o,f;S(e,"name","description"),S(e,"content",te.description??((s=te.og)==null?void 0:s.description)),S(i,"property","og:description"),S(i,"content",((o=te.og)==null?void 0:o.description)??te.description),S(r,"name","twitter:description"),S(r,"content",((f=te.og)==null?void 0:f.description)??te.description)},m(s,o){p(s,e,o),p(s,t,o),p(s,i,o),p(s,n,o),p(s,r,o)},p:re,d(s){s&&(b(e),b(t),b(i),b(n),b(r))}}}function gs(l){let e,t,i;return{c(){e=z("meta"),t=R(),i=z("meta"),this.h()},l(n){e=j(n,"META",{property:!0,content:!0}),t=Y(n),i=j(n,"META",{name:!0,content:!0}),this.h()},h(){var n,r;S(e,"property","og:image"),S(e,"content",(n=te.og)==null?void 0:n.image),S(i,"name","twitter:image"),S(i,"content",(r=te.og)==null?void 0:r.image)},m(n,r){p(n,e,r),p(n,t,r),p(n,i,r)},p:re,d(n){n&&(b(e),b(t),b(i))}}}function Wl(l){let e,t;return e=new ar({props:{queryID:"sales",queryResult:l[0]}}),{c(){se(e.$$.fragment)},l(i){oe(e.$$.fragment,i)},m(i,n){fe(e,i,n),t=!0},p(i,n){const r={};n&1&&(r.queryResult=i[0]),e.$set(r)},i(i){t||(G(e.$$.fragment,i),t=!0)},o(i){H(e.$$.fragment,i),t=!1},d(i){ae(e,i)}}}function bs(l){let e,t,i,n;return e=new Mn({props:{data:l[0]}}),i=new us({props:{data:l[0],x:"month",y:"sales"}}),{c(){se(e.$$.fragment),t=R(),se(i.$$.fragment)},l(r){oe(e.$$.fragment,r),t=Y(r),oe(i.$$.fragment,r)},m(r,s){fe(e,r,s),p(r,t,s),fe(i,r,s),n=!0},p(r,s){const o={};s&1&&(o.data=r[0]),e.$set(o);const f={};s&1&&(f.data=r[0]),i.$set(f)},i(r){n||(G(e.$$.fragment,r),G(i.$$.fragment,r),n=!0)},o(r){H(e.$$.fragment,r),H(i.$$.fragment,r),n=!1},d(r){r&&b(t),ae(e,r),ae(i,r)}}}function _s(l){let e,t,i,n,r,s,o,f,u=typeof te<"u"&&te.title&&te.hide_title!==!0&&cs();function c(h,w){return typeof te<"u"&&te.title?ds:hs}let d=c()(l),T=typeof te=="object"&&ms(),m=l[0]&&Wl(l);return o=new Nn({props:{cols:"2",$$slots:{default:[bs]},$$scope:{ctx:l}}}),{c(){u&&u.c(),e=R(),d.c(),t=z("meta"),i=z("meta"),T&&T.c(),n=be(),r=R(),m&&m.c(),s=R(),se(o.$$.fragment),this.h()},l(h){u&&u.l(h),e=Y(h);const w=rn("svelte-1j2izld",document.head);d.l(w),t=j(w,"META",{name:!0,content:!0}),i=j(w,"META",{name:!0,content:!0}),T&&T.l(w),n=be(),w.forEach(b),r=Y(h),m&&m.l(h),s=Y(h),oe(o.$$.fragment,h),this.h()},h(){S(t,"name","twitter:card"),S(t,"content","summary"),S(i,"name","twitter:site"),S(i,"content","@evidence_dev")},m(h,w){u&&u.m(h,w),p(h,e,w),d.m(document.head,null),B(document.head,t),B(document.head,i),T&&T.m(document.head,null),B(document.head,n),p(h,r,w),m&&m.m(h,w),p(h,s,w),fe(o,h,w),f=!0},p(h,[w]){typeof te<"u"&&te.title&&te.hide_title!==!0&&u.p(h,w),d.p(h,w),typeof te=="object"&&T.p(h,w),h[0]?m?(m.p(h,w),w&1&&G(m,1)):(m=Wl(h),m.c(),G(m,1),m.m(s.parentNode,s)):m&&(ze(),H(m,1,1,()=>{m=null}),je());const A={};w&1048577&&(A.$$scope={dirty:w,ctx:h}),o.$set(A)},i(h){f||(G(m),G(o.$$.fragment,h),f=!0)},o(h){H(m),H(o.$$.fragment,h),f=!1},d(h){h&&(b(e),b(r),b(s)),u&&u.d(h),d.d(h),b(t),b(i),T&&T.d(h),b(n),m&&m.d(h),ae(o,h)}}}const te={title:"Welcome to Aumtech"};function ks(l,e,t){let i,n;ht(l,Ul,L=>t(5,i=L)),ht(l,hl,L=>t(13,n=L));let{data:r}=e,{data:s={},customFormattingSettings:o,__db:f,inputs:u}=r;Vi(hl,n="6666cd76f96956469e7be39d750cc7d9",n);let c=vi(u);Xt(kn,c),sn(c.subscribe(L=>u=L)),Xt(wn,{getCustomFormats:()=>o.customFormats||[]});const a=(L,D)=>bn(f.query,L,{query_name:D});yn(a);let d;const T=()=>{d||(d=setTimeout(()=>{dl.add({id:"LoadingToast",title:"",message:"Loading...",status:"info"},0)},3e3))},m=()=>{d?(clearTimeout(d),d=null):dl.dismiss("LoadingToast")};Yi(()=>(Je.addEventListener("inFlightQueryStart",T),Je.addEventListener("inFlightQueryEnd",m),Je.QueriesLoading&&T(),()=>{Je.removeEventListener("inFlightQueryStart",T),Je.removeEventListener("inFlightQueryEnd",m)})),i.params,Yi(()=>!0);let h={initialData:void 0,initialError:void 0},w=ml`select |