vue-chrts 0.0.81 → 0.0.82
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Area/AreaChart.vue.d.ts +32 -0
- package/dist/Area/index.d.ts +1 -0
- package/dist/AreaStacked/AreaStackedChart.vue.d.ts +13 -0
- package/dist/AreaStacked/index.d.ts +1 -0
- package/dist/Bar/BarChart.vue.d.ts +25 -0
- package/dist/Bar/index.d.ts +1 -0
- package/dist/Donut/index.d.ts +1 -0
- package/dist/Line/LineChart.vue.d.ts +23 -0
- package/dist/Line/index.d.ts +2 -0
- package/dist/Line/types.d.ts +4 -0
- package/dist/Tooltip/Tooltip.vue.d.ts +13 -0
- package/dist/index.cjs +468 -1
- package/dist/index.d.ts +9 -3
- package/dist/index.js +9510 -3
- package/package.json +1 -1
- package/dist/Homepage-BTQ4NMLP.cjs +0 -489
- package/dist/Homepage-DIu5Y175.js +0 -12469
- package/dist/data/InvestmentData.d.ts +0 -9
- package/dist/data/RevenueData.d.ts +0 -11
- package/dist/elements/Card.vue.d.ts +0 -17
- package/dist/elements/Logo.vue.d.ts +0 -2
- package/dist/elements/Table.vue.d.ts +0 -2
- package/dist/index-Ba2KLZqf.cjs +0 -31
- package/dist/index-HFl5iMMW.js +0 -2334
- package/dist/index.css +0 -1
- /package/dist/{elements/Button.vue.d.ts → Donut/DonutChart.vue.d.ts} +0 -0
- /package/dist/{App.vue.d.ts → Progress/Progress.vue.d.ts} +0 -0
- /package/dist/{Homepage.vue.d.ts → Status/Status.vue.d.ts} +0 -0
|
@@ -1,489 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("vue"),ir=require("./index-Ba2KLZqf.cjs"),Tc={class:"ring ring-border divide-y divide-border rounded-xl shadow-sm"},Rc={class:"flex items-center justify-between p-4"},$c={class:"flex items-center gap-2"},Mc={class:"font-medium"},Ec={class:"text-sm dark:text-gray-400"},Ac={class:"p-4"},Fc=c.defineComponent({__name:"Status",setup(e){const t=c.ref("example.com"),n=c.ref("99.9% uptime"),i=c.ref([{hour:0,status:"online"},{hour:1,status:"online"},{hour:2,status:"online"},{hour:3,status:"online"},{hour:4,status:"online"},{hour:5,status:"online"},{hour:6,status:"online"},{hour:7,status:"online"},{hour:8,status:"online"},{hour:9,status:"online"},{hour:10,status:"online"},{hour:11,status:"offline"},{hour:12,status:"online"},{hour:13,status:"online"},{hour:14,status:"online"},{hour:15,status:"online"},{hour:16,status:"online"},{hour:17,status:"online"},{hour:18,status:"online"},{hour:19,status:"online"},{hour:20,status:"online"},{hour:21,status:"online"},{hour:22,status:"online"},{hour:23,status:"online"},{hour:0,status:"online"},{hour:1,status:"online"},{hour:2,status:"online"},{hour:3,status:"online"},{hour:4,status:"online"},{hour:5,status:"online"},{hour:6,status:"online"},{hour:7,status:"online"},{hour:8,status:"online"},{hour:9,status:"online"},{hour:10,status:"online"},{hour:11,status:"online"},{hour:12,status:"online"},{hour:13,status:"online"},{hour:14,status:"online"},{hour:15,status:"online"},{hour:16,status:"online"},{hour:17,status:"online"},{hour:18,status:"online"},{hour:19,status:"online"},{hour:20,status:"online"},{hour:21,status:"online"},{hour:22,status:"online"},{hour:23,status:"online"},{hour:0,status:"online"},{hour:1,status:"online"}]);return(r,o)=>(c.openBlock(),c.createElementBlock("div",Tc,[c.createElementVNode("div",Rc,[c.createElementVNode("div",$c,[o[0]||(o[0]=c.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"size-6 text-primary"},[c.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M9 12.75 11.25 15 15 9.75M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"})],-1)),c.createElementVNode("span",Mc,c.toDisplayString(t.value),1)]),c.createElementVNode("span",Ec,c.toDisplayString(n.value),1)]),c.createElementVNode("div",Ac,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(i.value,(s,a)=>(c.openBlock(),c.createElementBlock("div",{key:a,class:c.normalizeClass(["w-2.5 h-8 first:rounded-tl first:rounded-bl last:rounded-tr last:rounded-br ml-[3px] inline-block",s.status==="online"?"bg-primary":"bg-white"])},null,2))),128))])]))}});var Ar="http://www.w3.org/1999/xhtml";const ms={svg:"http://www.w3.org/2000/svg",xhtml:Ar,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Vi(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),ms.hasOwnProperty(t)?{space:ms[t],local:e}:e}function Vc(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Ar&&t.documentElement.namespaceURI===Ar?t.createElement(e):t.createElementNS(n,e)}}function Nc(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function ja(e){var t=Vi(e);return(t.local?Nc:Vc)(t)}function Dc(){}function wo(e){return e==null?Dc:function(){return this.querySelector(e)}}function Pc(e){typeof e!="function"&&(e=wo(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var o=t[r],s=o.length,a=i[r]=new Array(s),l,u,d=0;d<s;++d)(l=o[d])&&(u=e.call(l,l.__data__,d,o))&&("__data__"in l&&(u.__data__=l.__data__),a[d]=u);return new ke(i,this._parents)}function Oc(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function Lc(){return[]}function Za(e){return e==null?Lc:function(){return this.querySelectorAll(e)}}function Ic(e){return function(){return Oc(e.apply(this,arguments))}}function Bc(e){typeof e=="function"?e=Ic(e):e=Za(e);for(var t=this._groups,n=t.length,i=[],r=[],o=0;o<n;++o)for(var s=t[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&(i.push(e.call(l,l.__data__,u,s)),r.push(l));return new ke(i,r)}function Qa(e){return function(){return this.matches(e)}}function Ka(e){return function(t){return t.matches(e)}}var zc=Array.prototype.find;function Hc(e){return function(){return zc.call(this.children,e)}}function Gc(){return this.firstElementChild}function Uc(e){return this.select(e==null?Gc:Hc(typeof e=="function"?e:Ka(e)))}var Wc=Array.prototype.filter;function Yc(){return Array.from(this.children)}function qc(e){return function(){return Wc.call(this.children,e)}}function Xc(e){return this.selectAll(e==null?Yc:qc(typeof e=="function"?e:Ka(e)))}function jc(e){typeof e!="function"&&(e=Qa(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var o=t[r],s=o.length,a=i[r]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new ke(i,this._parents)}function Ja(e){return new Array(e.length)}function Zc(){return new ke(this._enter||this._groups.map(Ja),this._parents)}function ai(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}ai.prototype={constructor:ai,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function Qc(e){return function(){return e}}function Kc(e,t,n,i,r,o){for(var s=0,a,l=t.length,u=o.length;s<u;++s)(a=t[s])?(a.__data__=o[s],i[s]=a):n[s]=new ai(e,o[s]);for(;s<l;++s)(a=t[s])&&(r[s]=a)}function Jc(e,t,n,i,r,o,s){var a,l,u=new Map,d=t.length,f=o.length,h=new Array(d),g;for(a=0;a<d;++a)(l=t[a])&&(h[a]=g=s.call(l,l.__data__,a,t)+"",u.has(g)?r[a]=l:u.set(g,l));for(a=0;a<f;++a)g=s.call(e,o[a],a,o)+"",(l=u.get(g))?(i[a]=l,l.__data__=o[a],u.delete(g)):n[a]=new ai(e,o[a]);for(a=0;a<d;++a)(l=t[a])&&u.get(h[a])===l&&(r[a]=l)}function ed(e){return e.__data__}function td(e,t){if(!arguments.length)return Array.from(this,ed);var n=t?Jc:Kc,i=this._parents,r=this._groups;typeof e!="function"&&(e=Qc(e));for(var o=r.length,s=new Array(o),a=new Array(o),l=new Array(o),u=0;u<o;++u){var d=i[u],f=r[u],h=f.length,g=nd(e.call(d,d&&d.__data__,u,i)),m=g.length,p=a[u]=new Array(m),v=s[u]=new Array(m),_=l[u]=new Array(h);n(d,f,p,v,_,g,t);for(var y=0,x=0,w,S;y<m;++y)if(w=p[y]){for(y>=x&&(x=y+1);!(S=v[x])&&++x<m;);w._next=S||null}}return s=new ke(s,i),s._enter=a,s._exit=l,s}function nd(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function id(){return new ke(this._exit||this._groups.map(Ja),this._parents)}function rd(e,t,n){var i=this.enter(),r=this,o=this.exit();return typeof e=="function"?(i=e(i),i&&(i=i.selection())):i=i.append(e+""),t!=null&&(r=t(r),r&&(r=r.selection())),n==null?o.remove():n(o),i&&r?i.merge(r).order():r}function od(e){for(var t=e.selection?e.selection():e,n=this._groups,i=t._groups,r=n.length,o=i.length,s=Math.min(r,o),a=new Array(r),l=0;l<s;++l)for(var u=n[l],d=i[l],f=u.length,h=a[l]=new Array(f),g,m=0;m<f;++m)(g=u[m]||d[m])&&(h[m]=g);for(;l<r;++l)a[l]=n[l];return new ke(a,this._parents)}function sd(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var i=e[t],r=i.length-1,o=i[r],s;--r>=0;)(s=i[r])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function ad(e){e||(e=ld);function t(f,h){return f&&h?e(f.__data__,h.__data__):!f-!h}for(var n=this._groups,i=n.length,r=new Array(i),o=0;o<i;++o){for(var s=n[o],a=s.length,l=r[o]=new Array(a),u,d=0;d<a;++d)(u=s[d])&&(l[d]=u);l.sort(t)}return new ke(r,this._parents).order()}function ld(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function ud(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function cd(){return Array.from(this)}function dd(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i=e[t],r=0,o=i.length;r<o;++r){var s=i[r];if(s)return s}return null}function fd(){let e=0;for(const t of this)++e;return e}function hd(){return!this.node()}function gd(e){for(var t=this._groups,n=0,i=t.length;n<i;++n)for(var r=t[n],o=0,s=r.length,a;o<s;++o)(a=r[o])&&e.call(a,a.__data__,o,r);return this}function pd(e){return function(){this.removeAttribute(e)}}function md(e){return function(){this.removeAttributeNS(e.space,e.local)}}function vd(e,t){return function(){this.setAttribute(e,t)}}function _d(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function yd(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function xd(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function wd(e,t){var n=Vi(e);if(arguments.length<2){var i=this.node();return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((t==null?n.local?md:pd:typeof t=="function"?n.local?xd:yd:n.local?_d:vd)(n,t))}function el(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function Sd(e){return function(){this.style.removeProperty(e)}}function bd(e,t,n){return function(){this.style.setProperty(e,t,n)}}function Cd(e,t,n){return function(){var i=t.apply(this,arguments);i==null?this.style.removeProperty(e):this.style.setProperty(e,i,n)}}function kd(e,t,n){return arguments.length>1?this.each((t==null?Sd:typeof t=="function"?Cd:bd)(e,t,n??"")):Bt(this.node(),e)}function Bt(e,t){return e.style.getPropertyValue(t)||el(e).getComputedStyle(e,null).getPropertyValue(t)}function Td(e){return function(){delete this[e]}}function Rd(e,t){return function(){this[e]=t}}function $d(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function Md(e,t){return arguments.length>1?this.each((t==null?Td:typeof t=="function"?$d:Rd)(e,t)):this.node()[e]}function tl(e){return e.trim().split(/^|\s+/)}function So(e){return e.classList||new nl(e)}function nl(e){this._node=e,this._names=tl(e.getAttribute("class")||"")}nl.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 il(e,t){for(var n=So(e),i=-1,r=t.length;++i<r;)n.add(t[i])}function rl(e,t){for(var n=So(e),i=-1,r=t.length;++i<r;)n.remove(t[i])}function Ed(e){return function(){il(this,e)}}function Ad(e){return function(){rl(this,e)}}function Fd(e,t){return function(){(t.apply(this,arguments)?il:rl)(this,e)}}function Vd(e,t){var n=tl(e+"");if(arguments.length<2){for(var i=So(this.node()),r=-1,o=n.length;++r<o;)if(!i.contains(n[r]))return!1;return!0}return this.each((typeof t=="function"?Fd:t?Ed:Ad)(n,t))}function Nd(){this.textContent=""}function Dd(e){return function(){this.textContent=e}}function Pd(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function Od(e){return arguments.length?this.each(e==null?Nd:(typeof e=="function"?Pd:Dd)(e)):this.node().textContent}function Ld(){this.innerHTML=""}function Id(e){return function(){this.innerHTML=e}}function Bd(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function zd(e){return arguments.length?this.each(e==null?Ld:(typeof e=="function"?Bd:Id)(e)):this.node().innerHTML}function Hd(){this.nextSibling&&this.parentNode.appendChild(this)}function Gd(){return this.each(Hd)}function Ud(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function Wd(){return this.each(Ud)}function Yd(e){var t=typeof e=="function"?e:ja(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function qd(){return null}function Xd(e,t){var n=typeof e=="function"?e:ja(e),i=t==null?qd:typeof t=="function"?t:wo(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)})}function jd(){var e=this.parentNode;e&&e.removeChild(this)}function Zd(){return this.each(jd)}function Qd(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Kd(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Jd(e){return this.select(e?Kd:Qd)}function ef(e){return arguments.length?this.property("__data__",e):this.node().__data__}function tf(e){return function(t){e.call(this,t,this.__data__)}}function nf(e){return e.trim().split(/^|\s+/).map(function(t){var n="",i=t.indexOf(".");return i>=0&&(n=t.slice(i+1),t=t.slice(0,i)),{type:t,name:n}})}function rf(e){return function(){var t=this.__on;if(t){for(var n=0,i=-1,r=t.length,o;n<r;++n)o=t[n],(!e.type||o.type===e.type)&&o.name===e.name?this.removeEventListener(o.type,o.listener,o.options):t[++i]=o;++i?t.length=i:delete this.__on}}}function of(e,t,n){return function(){var i=this.__on,r,o=tf(t);if(i){for(var s=0,a=i.length;s<a;++s)if((r=i[s]).type===e.type&&r.name===e.name){this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=o,r.options=n),r.value=t;return}}this.addEventListener(e.type,o,n),r={type:e.type,name:e.name,value:t,listener:o,options:n},i?i.push(r):this.__on=[r]}}function sf(e,t,n){var i=nf(e+""),r,o=i.length,s;if(arguments.length<2){var a=this.node().__on;if(a){for(var l=0,u=a.length,d;l<u;++l)for(r=0,d=a[l];r<o;++r)if((s=i[r]).type===d.type&&s.name===d.name)return d.value}return}for(a=t?of:rf,r=0;r<o;++r)this.each(a(i[r],t,n));return this}function ol(e,t,n){var i=el(e),r=i.CustomEvent;typeof r=="function"?r=new r(t,n):(r=i.document.createEvent("Event"),n?(r.initEvent(t,n.bubbles,n.cancelable),r.detail=n.detail):r.initEvent(t,!1,!1)),e.dispatchEvent(r)}function af(e,t){return function(){return ol(this,e,t)}}function lf(e,t){return function(){return ol(this,e,t.apply(this,arguments))}}function uf(e,t){return this.each((typeof t=="function"?lf:af)(e,t))}function*cf(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i=e[t],r=0,o=i.length,s;r<o;++r)(s=i[r])&&(yield s)}var sl=[null];function ke(e,t){this._groups=e,this._parents=t}function Rn(){return new ke([[document.documentElement]],sl)}function df(){return this}ke.prototype=Rn.prototype={constructor:ke,select:Pc,selectAll:Bc,selectChild:Uc,selectChildren:Xc,filter:jc,data:td,enter:Zc,exit:id,join:rd,merge:od,selection:df,order:sd,sort:ad,call:ud,nodes:cd,node:dd,size:fd,empty:hd,each:gd,attr:wd,style:kd,property:Md,classed:Vd,text:Od,html:zd,raise:Gd,lower:Wd,append:Yd,insert:Xd,remove:Zd,clone:Jd,datum:ef,on:sf,dispatch:uf,[Symbol.iterator]:cf};function ce(e){return typeof e=="string"?new ke([[document.querySelector(e)]],[document.documentElement]):new ke([[e]],sl)}function ff(e){let t;for(;t=e.sourceEvent;)e=t;return e}function li(e,t){if(e=ff(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var i=n.createSVGPoint();return i.x=e.clientX,i.y=e.clientY,i=i.matrixTransform(t.getScreenCTM().inverse()),[i.x,i.y]}if(t.getBoundingClientRect){var r=t.getBoundingClientRect();return[e.clientX-r.left-t.clientLeft,e.clientY-r.top-t.clientTop]}}return[e.pageX,e.pageY]}var fn;(function(e){e[e.SVG=0]="SVG",e[e.HTML=1]="HTML"})(fn||(fn={}));var Je;(function(e){e.Fit="fit",e.Extend="extend",e.FitWidth="fit_width"})(Je||(Je={}));function hn(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function hf(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Ni(e){let t,n,i;e.length!==2?(t=hn,n=(a,l)=>hn(e(a),l),i=(a,l)=>e(a)-l):(t=e===hn||e===hf?e:gf,n=e,i=e);function r(a,l,u=0,d=a.length){if(u<d){if(t(l,l)!==0)return d;do{const f=u+d>>>1;n(a[f],l)<0?u=f+1:d=f}while(u<d)}return u}function o(a,l,u=0,d=a.length){if(u<d){if(t(l,l)!==0)return d;do{const f=u+d>>>1;n(a[f],l)<=0?u=f+1:d=f}while(u<d)}return u}function s(a,l,u=0,d=a.length){const f=r(a,l,u,d-1);return f>u&&i(a[f-1],l)>-i(a[f],l)?f-1:f}return{left:r,center:s,right:o}}function gf(){return 0}function al(e){return e===null?NaN:+e}const pf=Ni(hn),Di=pf.right;Ni(al).center;function mf(e,t){let n,i;for(const r of e)r!=null&&(n===void 0?r>=r&&(n=i=r):(n>r&&(n=r),i<r&&(i=r)));return[n,i]}class vs extends Map{constructor(t,n=yf){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:n}}),t!=null)for(const[i,r]of t)this.set(i,r)}get(t){return super.get(_s(this,t))}has(t){return super.has(_s(this,t))}set(t,n){return super.set(vf(this,t),n)}delete(t){return super.delete(_f(this,t))}}function _s({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):n}function vf({_intern:e,_key:t},n){const i=t(n);return e.has(i)?e.get(i):(e.set(i,n),n)}function _f({_intern:e,_key:t},n){const i=t(n);return e.has(i)&&(n=e.get(i),e.delete(i)),n}function yf(e){return e!==null&&typeof e=="object"?e.valueOf():e}const xf=Math.sqrt(50),wf=Math.sqrt(10),Sf=Math.sqrt(2);function ui(e,t,n){const i=(t-e)/Math.max(0,n),r=Math.floor(Math.log10(i)),o=i/Math.pow(10,r),s=o>=xf?10:o>=wf?5:o>=Sf?2:1;let a,l,u;return r<0?(u=Math.pow(10,-r)/s,a=Math.round(e*u),l=Math.round(t*u),a/u<e&&++a,l/u>t&&--l,u=-u):(u=Math.pow(10,r)*s,a=Math.round(e/u),l=Math.round(t/u),a*u<e&&++a,l*u>t&&--l),l<a&&.5<=n&&n<2?ui(e,t,n*2):[a,l,u]}function Fr(e,t,n){if(t=+t,e=+e,n=+n,!(n>0))return[];if(e===t)return[e];const i=t<e,[r,o,s]=i?ui(t,e,n):ui(e,t,n);if(!(o>=r))return[];const a=o-r+1,l=new Array(a);if(i)if(s<0)for(let u=0;u<a;++u)l[u]=(o-u)/-s;else for(let u=0;u<a;++u)l[u]=(o-u)*s;else if(s<0)for(let u=0;u<a;++u)l[u]=(r+u)/-s;else for(let u=0;u<a;++u)l[u]=(r+u)*s;return l}function Vr(e,t,n){return t=+t,e=+e,n=+n,ui(e,t,n)[2]}function Nr(e,t,n){t=+t,e=+e,n=+n;const i=t<e,r=i?Vr(t,e,n):Vr(e,t,n);return(i?-1:1)*(r<0?1/-r:r)}function Dr(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 r of e)(r=t(r,++i,e))!=null&&(n<r||n===void 0&&r>=r)&&(n=r)}return n}function gn(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 r of e)(r=t(r,++i,e))!=null&&(n>r||n===void 0&&r>=r)&&(n=r)}return n}function bf(e,t,n=al){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,r=(i-1)*t,o=Math.floor(r),s=+n(e[o],o,e),a=+n(e[o+1],o+1,e);return s+(a-s)*(r-o)}}function Cf(e,t){let n=0,i=0;if(t===void 0)for(let r of e)r!=null&&(r=+r)>=r&&(++n,i+=r);else{let r=-1;for(let o of e)(o=t(o,++r,e))!=null&&(o=+o)>=o&&(++n,i+=o)}if(n)return i/n}function*kf(e){for(const t of e)yield*t}function Tf(e){return Array.from(kf(e))}function ll(e,t,n){e=+e,t=+t,n=(r=arguments.length)<2?(t=e,e=0,1):r<3?1:+n;for(var i=-1,r=Math.max(0,Math.ceil((t-e)/n))|0,o=new Array(r);++i<r;)o[i]=e+i*n;return o}function Rf(e,t){let n=0;if(t===void 0)for(let i of e)(i=+i)&&(n+=i);else{let i=-1;for(let r of e)(r=+t(r,++i,e))&&(n+=r)}return n}function $f(e,t,n){var i={},r=i.noTrailing,o=r===void 0?!1:r,s=i.noLeading,a=s===void 0?!1:s,l=i.debounceMode,u=l===void 0?void 0:l,d,f=!1,h=0;function g(){d&&clearTimeout(d)}function m(v){var _=v||{},y=_.upcomingOnly,x=y===void 0?!1:y;g(),f=!x}function p(){for(var v=arguments.length,_=new Array(v),y=0;y<v;y++)_[y]=arguments[y];var x=this,w=Date.now()-h;if(f)return;function S(){h=Date.now(),t.apply(x,_)}function b(){d=void 0}!a&&u&&!d&&S(),g(),u===void 0&&w>e?a?(h=Date.now(),o||(d=setTimeout(u?b:S,e))):S():o!==!0&&(d=setTimeout(u?b:S,u===void 0?e-w:e))}return p.cancel=m,p}const be=e=>typeof e=="number",bo=e=>typeof e=="function",et=e=>Array.isArray(e),Mf=e=>e instanceof Object,ci=e=>e.constructor.name!=="Function"&&e.constructor.name!=="Object",ys=e=>Mf(e)&&!et(e)&&!bo(e)&&!ci(e),Ef=e=>[Object,Array].includes((e||{}).constructor)&&!Object.entries(e||{}).length,_n=(e,t,n=[],i=new Set)=>{if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;if(i.has(e))return!0;i.add(e);for(let r=0;r<e.length;r++)if(!_n(e[r],t[r],n,i))return!1;return!0}if(e instanceof Date&&t instanceof Date)return e.getTime()===t.getTime();if(typeof e=="object"&&e!==null&&t!==null){if(typeof t!="object")return!1;if(e===t)return!0;const r=Object.keys(e).filter(s=>!n.includes(s)),o=Object.keys(t).filter(s=>!n.includes(s));if(r.length!==o.length)return!1;if(i.has(e))return!0;i.add(e);for(const s of r)if(!_n(e[s],t[s],n,i))return!1;return!0}return e===t},Pr=e=>e.flat(),di=(e,t=new Map)=>{if(typeof e!="object"||e===null)return e;if(e instanceof Date)return new Date(e.getTime());if(e instanceof Array){const n=[];t.set(e,n);for(const i of e)n.push(t.has(i)?t.get(i):di(i,t));return n}if(ci(e))return e;if(e instanceof Object){const n={};t.set(e,n);const i=e;return Object.keys(e).reduce((r,o)=>(r[o]=t.has(i[o])?t.get(i[o]):di(i[o],t),r),n),n}return e},$t=(e,t,n=new Map)=>{if(!e||!t||e===t)return e;const i=ci(e)?e:di(e);return n.has(t)?n.get(t):(n.set(t,i),Object.keys(t).forEach(r=>{r==="__proto__"||r==="constructor"||(ys(e[r])&&ys(t[r])?i[r]=$t(e[r],t[r],n):ci(t)?i[r]=t:i[r]=di(t[r]))}),i)},fi=(e,t,n)=>$f(t,e);function Co(e,t,n){return bo(t)?t(e,n):t}function zt(e,t,n){return Co(e,t,n)}function X(e,t,n){return Co(e,t,n)}function Kt(e){return e.filter(t=>t&&!be(t))}function He(e,t,n){return Math.min(Math.max(e,t),n)}function Af(e,...t){if(!e)return[void 0,void 0];if(et(t)){let n=0,i=0;return e.forEach((r,o)=>{let s=0,a=0;for(const l of t){const u=X(r,l,o)||0;u>=0?s+=u:a+=u}s>i&&(i=s),a<n&&(n=a)}),[n,i]}}function Ff(e,t,...n){const i=[];let r=0,o=0;for(const s of n){const a=X(e,s,t)||0;a>=0?i.push(r+=a):i.push(o+=a)}return i}function Vf(e,t,n,i){const r=e.map((a,l)=>X(a,t,l)||0),o=n.map((a,l)=>{const u=Cf(e,(d,f)=>X(d,a,f)||0);return u===0&&Array.isArray(i)?i[l]:u<0}),s=n.map(()=>[]);return e.forEach((a,l)=>{let u=r[l],d=r[l];n.forEach((f,h)=>{const g=X(a,f,l)||0;g>=0?s[h].push([u,u+=g]):s[h].push([d,d+=g])})}),s.forEach((a,l)=>{a.isMostlyNegative=o[l]}),s}function ul(e,...t){return e?gn(e,(i,r)=>gn(t,o=>X(i,o,r))):void 0}function cl(e,...t){return e?Dr(e,(i,r)=>Dr(t,o=>X(i,o,r))):void 0}function Yn(e,...t){return[ul(e,...t),cl(e,...t)]}function Nf(e,t,n){if(e.length<=1)return e[0];const i=e.map((s,a)=>X(s,n,a));i.sort((s,a)=>s-a);const r=Ni(s=>s).left,o=r(i,t,1,e.length-1);return t-i[o-1]>i[o]-t?e[o]:e[o-1]}function dl(e,t,n){return e.filter((r,o)=>{const s=X(r,n,o);return s>=t[0]&&s<=t[1]})}var bt=[],Df=function(){return bt.some(function(e){return e.activeTargets.length>0})},Pf=function(){return bt.some(function(e){return e.skippedTargets.length>0})},xs="ResizeObserver loop completed with undelivered notifications.",Of=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:xs}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=xs),window.dispatchEvent(e)},yn;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(yn||(yn={}));var Ct=function(e){return Object.freeze(e)},Lf=function(){function e(t,n){this.inlineSize=t,this.blockSize=n,Ct(this)}return e}(),fl=function(){function e(t,n,i,r){return this.x=t,this.y=n,this.width=i,this.height=r,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,Ct(this)}return e.prototype.toJSON=function(){var t=this,n=t.x,i=t.y,r=t.top,o=t.right,s=t.bottom,a=t.left,l=t.width,u=t.height;return{x:n,y:i,top:r,right:o,bottom:s,left:a,width:l,height:u}},e.fromRect=function(t){return new e(t.x,t.y,t.width,t.height)},e}(),ko=function(e){return e instanceof SVGElement&&"getBBox"in e},hl=function(e){if(ko(e)){var t=e.getBBox(),n=t.width,i=t.height;return!n&&!i}var r=e,o=r.offsetWidth,s=r.offsetHeight;return!(o||s||e.getClientRects().length)},ws=function(e){var t;if(e instanceof Element)return!0;var n=(t=e==null?void 0:e.ownerDocument)===null||t===void 0?void 0:t.defaultView;return!!(n&&e instanceof n.Element)},If=function(e){switch(e.tagName){case"INPUT":if(e.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},pn=typeof window<"u"?window:{},Vn=new WeakMap,Ss=/auto|scroll/,Bf=/^tb|vertical/,zf=/msie|trident/i.test(pn.navigator&&pn.navigator.userAgent),Le=function(e){return parseFloat(e||"0")},Pt=function(e,t,n){return e===void 0&&(e=0),t===void 0&&(t=0),n===void 0&&(n=!1),new Lf((n?t:e)||0,(n?e:t)||0)},bs=Ct({devicePixelContentBoxSize:Pt(),borderBoxSize:Pt(),contentBoxSize:Pt(),contentRect:new fl(0,0,0,0)}),gl=function(e,t){if(t===void 0&&(t=!1),Vn.has(e)&&!t)return Vn.get(e);if(hl(e))return Vn.set(e,bs),bs;var n=getComputedStyle(e),i=ko(e)&&e.ownerSVGElement&&e.getBBox(),r=!zf&&n.boxSizing==="border-box",o=Bf.test(n.writingMode||""),s=!i&&Ss.test(n.overflowY||""),a=!i&&Ss.test(n.overflowX||""),l=i?0:Le(n.paddingTop),u=i?0:Le(n.paddingRight),d=i?0:Le(n.paddingBottom),f=i?0:Le(n.paddingLeft),h=i?0:Le(n.borderTopWidth),g=i?0:Le(n.borderRightWidth),m=i?0:Le(n.borderBottomWidth),p=i?0:Le(n.borderLeftWidth),v=f+u,_=l+d,y=p+g,x=h+m,w=a?e.offsetHeight-x-e.clientHeight:0,S=s?e.offsetWidth-y-e.clientWidth:0,b=r?v+y:0,C=r?_+x:0,V=i?i.width:Le(n.width)-b-S,F=i?i.height:Le(n.height)-C-w,U=V+v+S+y,M=F+_+w+x,I=Ct({devicePixelContentBoxSize:Pt(Math.round(V*devicePixelRatio),Math.round(F*devicePixelRatio),o),borderBoxSize:Pt(U,M,o),contentBoxSize:Pt(V,F,o),contentRect:new fl(f,l,V,F)});return Vn.set(e,I),I},pl=function(e,t,n){var i=gl(e,n),r=i.borderBoxSize,o=i.contentBoxSize,s=i.devicePixelContentBoxSize;switch(t){case yn.DEVICE_PIXEL_CONTENT_BOX:return s;case yn.BORDER_BOX:return r;default:return o}},Hf=function(){function e(t){var n=gl(t);this.target=t,this.contentRect=n.contentRect,this.borderBoxSize=Ct([n.borderBoxSize]),this.contentBoxSize=Ct([n.contentBoxSize]),this.devicePixelContentBoxSize=Ct([n.devicePixelContentBoxSize])}return e}(),ml=function(e){if(hl(e))return 1/0;for(var t=0,n=e.parentNode;n;)t+=1,n=n.parentNode;return t},Gf=function(){var e=1/0,t=[];bt.forEach(function(s){if(s.activeTargets.length!==0){var a=[];s.activeTargets.forEach(function(u){var d=new Hf(u.target),f=ml(u.target);a.push(d),u.lastReportedSize=pl(u.target,u.observedBox),f<e&&(e=f)}),t.push(function(){s.callback.call(s.observer,a,s.observer)}),s.activeTargets.splice(0,s.activeTargets.length)}});for(var n=0,i=t;n<i.length;n++){var r=i[n];r()}return e},Cs=function(e){bt.forEach(function(n){n.activeTargets.splice(0,n.activeTargets.length),n.skippedTargets.splice(0,n.skippedTargets.length),n.observationTargets.forEach(function(r){r.isActive()&&(ml(r.target)>e?n.activeTargets.push(r):n.skippedTargets.push(r))})})},Uf=function(){var e=0;for(Cs(e);Df();)e=Gf(),Cs(e);return Pf()&&Of(),e>0},rr,vl=[],Wf=function(){return vl.splice(0).forEach(function(e){return e()})},Yf=function(e){if(!rr){var t=0,n=document.createTextNode(""),i={characterData:!0};new MutationObserver(function(){return Wf()}).observe(n,i),rr=function(){n.textContent="".concat(t?t--:t++)}}vl.push(e),rr()},qf=function(e){Yf(function(){requestAnimationFrame(e)})},qn=0,Xf=function(){return!!qn},jf=250,Zf={attributes:!0,characterData:!0,childList:!0,subtree:!0},ks=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],Ts=function(e){return e===void 0&&(e=0),Date.now()+e},or=!1,Qf=function(){function e(){var t=this;this.stopped=!0,this.listener=function(){return t.schedule()}}return e.prototype.run=function(t){var n=this;if(t===void 0&&(t=jf),!or){or=!0;var i=Ts(t);qf(function(){var r=!1;try{r=Uf()}finally{if(or=!1,t=i-Ts(),!Xf())return;r?n.run(1e3):t>0?n.run(t):n.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var t=this,n=function(){return t.observer&&t.observer.observe(document.body,Zf)};document.body?n():pn.addEventListener("DOMContentLoaded",n)},e.prototype.start=function(){var t=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),ks.forEach(function(n){return pn.addEventListener(n,t.listener,!0)}))},e.prototype.stop=function(){var t=this;this.stopped||(this.observer&&this.observer.disconnect(),ks.forEach(function(n){return pn.removeEventListener(n,t.listener,!0)}),this.stopped=!0)},e}(),Or=new Qf,Rs=function(e){!qn&&e>0&&Or.start(),qn+=e,!qn&&Or.stop()},Kf=function(e){return!ko(e)&&!If(e)&&getComputedStyle(e).display==="inline"},Jf=function(){function e(t,n){this.target=t,this.observedBox=n||yn.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var t=pl(this.target,this.observedBox,!0);return Kf(this.target)&&(this.lastReportedSize=t),this.lastReportedSize.inlineSize!==t.inlineSize||this.lastReportedSize.blockSize!==t.blockSize},e}(),eh=function(){function e(t,n){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=t,this.callback=n}return e}(),Nn=new WeakMap,$s=function(e,t){for(var n=0;n<e.length;n+=1)if(e[n].target===t)return n;return-1},Dn=function(){function e(){}return e.connect=function(t,n){var i=new eh(t,n);Nn.set(t,i)},e.observe=function(t,n,i){var r=Nn.get(t),o=r.observationTargets.length===0;$s(r.observationTargets,n)<0&&(o&&bt.push(r),r.observationTargets.push(new Jf(n,i&&i.box)),Rs(1),Or.schedule())},e.unobserve=function(t,n){var i=Nn.get(t),r=$s(i.observationTargets,n),o=i.observationTargets.length===1;r>=0&&(o&&bt.splice(bt.indexOf(i),1),i.observationTargets.splice(r,1),Rs(-1))},e.disconnect=function(t){var n=this,i=Nn.get(t);i.observationTargets.slice().forEach(function(r){return n.unobserve(t,r.target)}),i.activeTargets.splice(0,i.activeTargets.length)},e}(),th=function(){function e(t){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof t!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Dn.connect(this,t)}return e.prototype.observe=function(t,n){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!ws(t))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Dn.observe(this,t,n)},e.prototype.unobserve=function(t){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!ws(t))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Dn.unobserve(this,t)},e.prototype.disconnect=function(){Dn.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}();const nh=globalThis.ResizeObserver||th,To={duration:void 0,margin:{top:0,bottom:0,left:0,right:0},padding:{top:0,bottom:0,left:0,right:0},sizing:Je.Fit,width:void 0,height:void 0,svgDefs:void 0,ariaLabel:void 0};class Ht{constructor(t){this._defaultConfig=To,this._isFirstRender=!0,this._renderAnimationFrameId=null,this._container=t;const n=ce(this._container);n.attr("role","figure"),this.svg=n.append("svg").style("display","block").attr("xmlns","http://www.w3.org/2000/svg").attr("height",Ht.DEFAULT_CONTAINER_HEIGHT).attr("aria-hidden",!0),this._svgDefs=this.svg.append("defs"),this._svgDefsExternal=this.svg.append("defs"),this.element=this.svg.node()}updateContainer(t){var n;this.prevConfig=this.config,this.config=$t(this._defaultConfig,t),(t==null?void 0:t.svgDefs)!==((n=this.prevConfig)===null||n===void 0?void 0:n.svgDefs)&&(this._svgDefsExternal.selectAll("*").remove(),this._svgDefsExternal.html(t.svgDefs))}_preRender(){}_render(t){const{config:n}=this;ce(this._container).attr("aria-label",n.ariaLabel),this._isFirstRender=!1}render(t=this.config.duration){const n=this.config.width||this.containerWidth,i=this.config.height||this.containerHeight;this.svg.attr("width",n).attr("height",i),this._resizeObserver||this._setUpResizeObserver(),cancelAnimationFrame(this._renderAnimationFrameId),this._renderAnimationFrameId=requestAnimationFrame(()=>{this._preRender(),this._render(t)})}get containerWidth(){return this.config.width?this.element.clientWidth:this._container.clientWidth||this._container.getBoundingClientRect().width}get containerHeight(){return this.config.height?this.element.clientHeight:this._container.clientHeight||this._container.getBoundingClientRect().height||Ht.DEFAULT_CONTAINER_HEIGHT}get width(){return He(this.containerWidth-this.config.margin.left-this.config.margin.right,0,Number.POSITIVE_INFINITY)}get height(){return He(this.containerHeight-this.config.margin.top-this.config.margin.bottom,0,Number.POSITIVE_INFINITY)}_removeAllChildren(){for(;this.element.firstChild;)this.element.removeChild(this.element.firstChild)}_onResize(){const{config:t}=this;(t.sizing===Je.Fit||t.sizing===Je.FitWidth)&&this.render(0)}_setUpResizeObserver(){if(this._resizeObserver)return;const t=this._container.getBoundingClientRect();this._containerSize={width:t.width,height:t.height},this._resizeObserver=new nh((n,i)=>{cancelAnimationFrame(this._resizeObserverAnimationFrameId),this._resizeObserverAnimationFrameId=requestAnimationFrame(()=>{const r=this._container.getBoundingClientRect(),o={width:r.width,height:r.height};!_n(this._containerSize,o)&&o.width&&o.height&&(this._containerSize=o,this._onResize())})}),this._resizeObserver.observe(this._container)}destroy(){var t;cancelAnimationFrame(this._renderAnimationFrameId),cancelAnimationFrame(this._resizeObserverAnimationFrameId),(t=this._resizeObserver)===null||t===void 0||t.disconnect(),this.svg.remove()}}Ht.DEFAULT_CONTAINER_HEIGHT=300;function ih(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}function rh(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),e.nonce!==void 0&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}var oh=function(){function e(n){var i=this;this._insertTag=function(r){var o;i.tags.length===0?i.insertionPoint?o=i.insertionPoint.nextSibling:i.prepend?o=i.container.firstChild:o=i.before:o=i.tags[i.tags.length-1].nextSibling,i.container.insertBefore(r,o),i.tags.push(r)},this.isSpeedy=n.speedy===void 0?!0:n.speedy,this.tags=[],this.ctr=0,this.nonce=n.nonce,this.key=n.key,this.container=n.container,this.prepend=n.prepend,this.insertionPoint=n.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(i){i.forEach(this._insertTag)},t.insert=function(i){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(rh(this));var r=this.tags[this.tags.length-1];if(this.isSpeedy){var o=ih(r);try{o.insertRule(i,o.cssRules.length)}catch{}}else r.appendChild(document.createTextNode(i));this.ctr++},t.flush=function(){this.tags.forEach(function(i){var r;return(r=i.parentNode)==null?void 0:r.removeChild(i)}),this.tags=[],this.ctr=0},e}(),ae="-ms-",hi="-moz-",H="-webkit-",_l="comm",Ro="rule",$o="decl",sh="@import",yl="@keyframes",ah="@layer",lh=Math.abs,Pi=String.fromCharCode,uh=Object.assign;function ch(e,t){return te(e,0)^45?(((t<<2^te(e,0))<<2^te(e,1))<<2^te(e,2))<<2^te(e,3):0}function xl(e){return e.trim()}function dh(e,t){return(e=t.exec(e))?e[0]:e}function G(e,t,n){return e.replace(t,n)}function Lr(e,t){return e.indexOf(t)}function te(e,t){return e.charCodeAt(t)|0}function xn(e,t,n){return e.slice(t,n)}function ze(e){return e.length}function Mo(e){return e.length}function Pn(e,t){return t.push(e),e}function fh(e,t){return e.map(t).join("")}var Oi=1,Gt=1,wl=0,ye=0,Q=0,jt="";function Li(e,t,n,i,r,o,s){return{value:e,root:t,parent:n,type:i,props:r,children:o,line:Oi,column:Gt,length:s,return:""}}function Jt(e,t){return uh(Li("",null,null,"",null,null,0),e,{length:-e.length},t)}function hh(){return Q}function gh(){return Q=ye>0?te(jt,--ye):0,Gt--,Q===10&&(Gt=1,Oi--),Q}function Ce(){return Q=ye<wl?te(jt,ye++):0,Gt++,Q===10&&(Gt=1,Oi++),Q}function Ge(){return te(jt,ye)}function Xn(){return ye}function $n(e,t){return xn(jt,e,t)}function wn(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Sl(e){return Oi=Gt=1,wl=ze(jt=e),ye=0,[]}function bl(e){return jt="",e}function jn(e){return xl($n(ye-1,Ir(e===91?e+2:e===40?e+1:e)))}function ph(e){for(;(Q=Ge())&&Q<33;)Ce();return wn(e)>2||wn(Q)>3?"":" "}function mh(e,t){for(;--t&&Ce()&&!(Q<48||Q>102||Q>57&&Q<65||Q>70&&Q<97););return $n(e,Xn()+(t<6&&Ge()==32&&Ce()==32))}function Ir(e){for(;Ce();)switch(Q){case e:return ye;case 34:case 39:e!==34&&e!==39&&Ir(Q);break;case 40:e===41&&Ir(e);break;case 92:Ce();break}return ye}function vh(e,t){for(;Ce()&&e+Q!==57;)if(e+Q===84&&Ge()===47)break;return"/*"+$n(t,ye-1)+"*"+Pi(e===47?e:Ce())}function _h(e){for(;!wn(Ge());)Ce();return $n(e,ye)}function yh(e){return bl(Zn("",null,null,null,[""],e=Sl(e),0,[0],e))}function Zn(e,t,n,i,r,o,s,a,l){for(var u=0,d=0,f=s,h=0,g=0,m=0,p=1,v=1,_=1,y=0,x="",w=r,S=o,b=i,C=x;v;)switch(m=y,y=Ce()){case 40:if(m!=108&&te(C,f-1)==58){Lr(C+=G(jn(y),"&","&\f"),"&\f")!=-1&&(_=-1);break}case 34:case 39:case 91:C+=jn(y);break;case 9:case 10:case 13:case 32:C+=ph(m);break;case 92:C+=mh(Xn()-1,7);continue;case 47:switch(Ge()){case 42:case 47:Pn(xh(vh(Ce(),Xn()),t,n),l);break;default:C+="/"}break;case 123*p:a[u++]=ze(C)*_;case 125*p:case 59:case 0:switch(y){case 0:case 125:v=0;case 59+d:_==-1&&(C=G(C,/\f/g,"")),g>0&&ze(C)-f&&Pn(g>32?Es(C+";",i,n,f-1):Es(G(C," ","")+";",i,n,f-2),l);break;case 59:C+=";";default:if(Pn(b=Ms(C,t,n,u,d,r,a,x,w=[],S=[],f),o),y===123)if(d===0)Zn(C,t,b,b,w,o,f,a,S);else switch(h===99&&te(C,3)===110?100:h){case 100:case 108:case 109:case 115:Zn(e,b,b,i&&Pn(Ms(e,b,b,0,0,r,a,x,r,w=[],f),S),r,S,f,a,i?w:S);break;default:Zn(C,b,b,b,[""],S,0,a,S)}}u=d=g=0,p=_=1,x=C="",f=s;break;case 58:f=1+ze(C),g=m;default:if(p<1){if(y==123)--p;else if(y==125&&p++==0&&gh()==125)continue}switch(C+=Pi(y),y*p){case 38:_=d>0?1:(C+="\f",-1);break;case 44:a[u++]=(ze(C)-1)*_,_=1;break;case 64:Ge()===45&&(C+=jn(Ce())),h=Ge(),d=f=ze(x=C+=_h(Xn())),y++;break;case 45:m===45&&ze(C)==2&&(p=0)}}return o}function Ms(e,t,n,i,r,o,s,a,l,u,d){for(var f=r-1,h=r===0?o:[""],g=Mo(h),m=0,p=0,v=0;m<i;++m)for(var _=0,y=xn(e,f+1,f=lh(p=s[m])),x=e;_<g;++_)(x=xl(p>0?h[_]+" "+y:G(y,/&\f/g,h[_])))&&(l[v++]=x);return Li(e,t,n,r===0?Ro:a,l,u,d)}function xh(e,t,n){return Li(e,t,n,_l,Pi(hh()),xn(e,2,-2),0)}function Es(e,t,n,i){return Li(e,t,n,$o,xn(e,0,i),xn(e,i+1,-1),i)}function Ot(e,t){for(var n="",i=Mo(e),r=0;r<i;r++)n+=t(e[r],r,e,t)||"";return n}function wh(e,t,n,i){switch(e.type){case ah:if(e.children.length)break;case sh:case $o:return e.return=e.return||e.value;case _l:return"";case yl:return e.return=e.value+"{"+Ot(e.children,i)+"}";case Ro:e.value=e.props.join(",")}return ze(n=Ot(e.children,i))?e.return=e.value+"{"+n+"}":""}function Sh(e){var t=Mo(e);return function(n,i,r,o){for(var s="",a=0;a<t;a++)s+=e[a](n,i,r,o)||"";return s}}function bh(e){return function(t){t.root||(t=t.return)&&e(t)}}function Ch(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var kh=function(t,n,i){for(var r=0,o=0;r=o,o=Ge(),r===38&&o===12&&(n[i]=1),!wn(o);)Ce();return $n(t,ye)},Th=function(t,n){var i=-1,r=44;do switch(wn(r)){case 0:r===38&&Ge()===12&&(n[i]=1),t[i]+=kh(ye-1,n,i);break;case 2:t[i]+=jn(r);break;case 4:if(r===44){t[++i]=Ge()===58?"&\f":"",n[i]=t[i].length;break}default:t[i]+=Pi(r)}while(r=Ce());return t},Rh=function(t,n){return bl(Th(Sl(t),n))},As=new WeakMap,$h=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var n=t.value,i=t.parent,r=t.column===i.column&&t.line===i.line;i.type!=="rule";)if(i=i.parent,!i)return;if(!(t.props.length===1&&n.charCodeAt(0)!==58&&!As.get(i))&&!r){As.set(t,!0);for(var o=[],s=Rh(n,o),a=i.props,l=0,u=0;l<s.length;l++)for(var d=0;d<a.length;d++,u++)t.props[u]=o[l]?s[l].replace(/&\f/g,a[d]):a[d]+" "+s[l]}}},Mh=function(t){if(t.type==="decl"){var n=t.value;n.charCodeAt(0)===108&&n.charCodeAt(2)===98&&(t.return="",t.value="")}};function Cl(e,t){switch(ch(e,t)){case 5103:return H+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return H+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return H+e+hi+e+ae+e+e;case 6828:case 4268:return H+e+ae+e+e;case 6165:return H+e+ae+"flex-"+e+e;case 5187:return H+e+G(e,/(\w+).+(:[^]+)/,H+"box-$1$2"+ae+"flex-$1$2")+e;case 5443:return H+e+ae+"flex-item-"+G(e,/flex-|-self/,"")+e;case 4675:return H+e+ae+"flex-line-pack"+G(e,/align-content|flex-|-self/,"")+e;case 5548:return H+e+ae+G(e,"shrink","negative")+e;case 5292:return H+e+ae+G(e,"basis","preferred-size")+e;case 6060:return H+"box-"+G(e,"-grow","")+H+e+ae+G(e,"grow","positive")+e;case 4554:return H+G(e,/([^-])(transform)/g,"$1"+H+"$2")+e;case 6187:return G(G(G(e,/(zoom-|grab)/,H+"$1"),/(image-set)/,H+"$1"),e,"")+e;case 5495:case 3959:return G(e,/(image-set\([^]*)/,H+"$1$`$1");case 4968:return G(G(e,/(.+:)(flex-)?(.*)/,H+"box-pack:$3"+ae+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+H+e+e;case 4095:case 3583:case 4068:case 2532:return G(e,/(.+)-inline(.+)/,H+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(ze(e)-1-t>6)switch(te(e,t+1)){case 109:if(te(e,t+4)!==45)break;case 102:return G(e,/(.+:)(.+)-([^]+)/,"$1"+H+"$2-$3$1"+hi+(te(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Lr(e,"stretch")?Cl(G(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(te(e,t+1)!==115)break;case 6444:switch(te(e,ze(e)-3-(~Lr(e,"!important")&&10))){case 107:return G(e,":",":"+H)+e;case 101:return G(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+H+(te(e,14)===45?"inline-":"")+"box$3$1"+H+"$2$3$1"+ae+"$2box$3")+e}break;case 5936:switch(te(e,t+11)){case 114:return H+e+ae+G(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return H+e+ae+G(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return H+e+ae+G(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return H+e+ae+e+e}return e}var Eh=function(t,n,i,r){if(t.length>-1&&!t.return)switch(t.type){case $o:t.return=Cl(t.value,t.length);break;case yl:return Ot([Jt(t,{value:G(t.value,"@","@"+H)})],r);case Ro:if(t.length)return fh(t.props,function(o){switch(dh(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ot([Jt(t,{props:[G(o,/:(read-\w+)/,":"+hi+"$1")]})],r);case"::placeholder":return Ot([Jt(t,{props:[G(o,/:(plac\w+)/,":"+H+"input-$1")]}),Jt(t,{props:[G(o,/:(plac\w+)/,":"+hi+"$1")]}),Jt(t,{props:[G(o,/:(plac\w+)/,ae+"input-$1")]})],r)}return""})}},Ah=[Eh],Fh=function(t){var n=t.key;if(n==="css"){var i=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(i,function(p){var v=p.getAttribute("data-emotion");v.indexOf(" ")!==-1&&(document.head.appendChild(p),p.setAttribute("data-s",""))})}var r=t.stylisPlugins||Ah,o={},s,a=[];s=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+n+' "]'),function(p){for(var v=p.getAttribute("data-emotion").split(" "),_=1;_<v.length;_++)o[v[_]]=!0;a.push(p)});var l,u=[$h,Mh];{var d,f=[wh,bh(function(p){d.insert(p)})],h=Sh(u.concat(r,f)),g=function(v){return Ot(yh(v),h)};l=function(v,_,y,x){d=y,g(v?v+"{"+_.styles+"}":_.styles),x&&(m.inserted[_.name]=!0)}}var m={key:n,sheet:new oh({key:n,container:s,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:o,registered:{},insert:l};return m.sheet.hydrate(a),m};function Vh(e){for(var t=0,n,i=0,r=e.length;r>=4;++i,r-=4)n=e.charCodeAt(i)&255|(e.charCodeAt(++i)&255)<<8|(e.charCodeAt(++i)&255)<<16|(e.charCodeAt(++i)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(r){case 3:t^=(e.charCodeAt(i+2)&255)<<16;case 2:t^=(e.charCodeAt(i+1)&255)<<8;case 1:t^=e.charCodeAt(i)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var Nh={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Dh=/[A-Z]|^ms/g,Ph=/_EMO_([^_]+?)_([^]*?)_EMO_/g,kl=function(t){return t.charCodeAt(1)===45},Fs=function(t){return t!=null&&typeof t!="boolean"},sr=Ch(function(e){return kl(e)?e:e.replace(Dh,"-$&").toLowerCase()}),Vs=function(t,n){switch(t){case"animation":case"animationName":if(typeof n=="string")return n.replace(Ph,function(i,r,o){return dt={name:r,styles:o,next:dt},r})}return Nh[t]!==1&&!kl(t)&&typeof n=="number"&&n!==0?n+"px":n};function gi(e,t,n){if(n==null)return"";var i=n;if(i.__emotion_styles!==void 0)return i;switch(typeof n){case"boolean":return"";case"object":{var r=n;if(r.anim===1)return dt={name:r.name,styles:r.styles,next:dt},r.name;var o=n;if(o.styles!==void 0){var s=o.next;if(s!==void 0)for(;s!==void 0;)dt={name:s.name,styles:s.styles,next:dt},s=s.next;var a=o.styles+";";return a}return Oh(e,t,n)}}var l=n;if(t==null)return l;var u=t[l];return u!==void 0?u:l}function Oh(e,t,n){var i="";if(Array.isArray(n))for(var r=0;r<n.length;r++)i+=gi(e,t,n[r])+";";else for(var o in n){var s=n[o];if(typeof s!="object"){var a=s;t!=null&&t[a]!==void 0?i+=o+"{"+t[a]+"}":Fs(a)&&(i+=sr(o)+":"+Vs(o,a)+";")}else if(Array.isArray(s)&&typeof s[0]=="string"&&(t==null||t[s[0]]===void 0))for(var l=0;l<s.length;l++)Fs(s[l])&&(i+=sr(o)+":"+Vs(o,s[l])+";");else{var u=gi(e,t,s);switch(o){case"animation":case"animationName":{i+=sr(o)+":"+u+";";break}default:i+=o+"{"+u+"}"}}}return i}var Ns=/label:\s*([^\s;{]+)\s*(;|$)/g,dt;function ar(e,t,n){if(e.length===1&&typeof e[0]=="object"&&e[0]!==null&&e[0].styles!==void 0)return e[0];var i=!0,r="";dt=void 0;var o=e[0];if(o==null||o.raw===void 0)i=!1,r+=gi(n,t,o);else{var s=o;r+=s[0]}for(var a=1;a<e.length;a++)if(r+=gi(n,t,e[a]),i){var l=o;r+=l[a]}Ns.lastIndex=0;for(var u="",d;(d=Ns.exec(r))!==null;)u+="-"+d[1];var f=Vh(r)+u;return{name:f,styles:r,next:dt}}function Tl(e,t,n){var i="";return n.split(" ").forEach(function(r){e[r]!==void 0?t.push(e[r]+";"):r&&(i+=r+" ")}),i}var Lh=function(t,n,i){var r=t.key+"-"+n.name;t.registered[r]===void 0&&(t.registered[r]=n.styles)},Ih=function(t,n,i){Lh(t,n);var r=t.key+"-"+n.name;if(t.inserted[n.name]===void 0){var o=n;do t.insert(n===o?"."+r:"",o,t.sheet,!0),o=o.next;while(o!==void 0)}};function Ds(e,t){if(e.inserted[t.name]===void 0)return e.insert("",t,e.sheet,!0)}function Ps(e,t,n){var i=[],r=Tl(e,i,n);return i.length<2?n:r+t(i)}var Bh=function(t){var n=Fh(t);n.sheet.speedy=function(a){this.isSpeedy=a},n.compat=!0;var i=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var f=ar(u,n.registered,void 0);return Ih(n,f),n.key+"-"+f.name},r=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var f=ar(u,n.registered),h="animation-"+f.name;return Ds(n,{name:f.name,styles:"@keyframes "+h+"{"+f.styles+"}"}),h},o=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];var f=ar(u,n.registered);Ds(n,f)},s=function(){for(var l=arguments.length,u=new Array(l),d=0;d<l;d++)u[d]=arguments[d];return Ps(n.registered,i,zh(u))};return{css:i,cx:s,injectGlobal:o,keyframes:r,hydrate:function(l){l.forEach(function(u){n.inserted[u]=!0})},flush:function(){n.registered={},n.inserted={},n.sheet.flush()},sheet:n.sheet,cache:n,getRegisteredStyles:Tl.bind(null,n.registered),merge:Ps.bind(null,n.registered,i)}},zh=function e(t){for(var n="",i=0;i<t.length;i++){var r=t[i];if(r!=null){var o=void 0;switch(typeof r){case"boolean":break;case"object":{if(Array.isArray(r))o=e(r);else{o="";for(var s in r)r[s]&&s&&(o&&(o+=" "),o+=s)}break}default:o=r}o&&(n&&(n+=" "),n+=o)}}return n},Rl=Bh({key:"css"}),ot=Rl.injectGlobal,P=Rl.css;function Hh(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var lr,Os;function Gh(){return Os||(Os=1,lr=function(t,n){n||(n=[0,""]),t=String(t);var i=parseFloat(t,10);return n[0]=i,n[1]=t.match(/[\d.\-\+]*\s*(.*)/)[1]||"",n}),lr}var ur,Ls;function Uh(){if(Ls)return ur;Ls=1;var e=Gh();ur=r;var t=i("in",document.body);function n(o,s){var a=e(getComputedStyle(o).getPropertyValue(s));return a[0]*r(a[1],o)}function i(o,s){var a=document.createElement("div");a.style.height="128"+o,s.appendChild(a);var l=n(a,"height")/128;return s.removeChild(a),l}function r(o,s){if(!o)return null;switch(s=s||document.body,o=(o+""||"px").trim().toLowerCase(),(s===window||s===document)&&(s=document.body),o){case"%":return s.clientHeight/100;case"ch":case"ex":return i(o,s);case"em":return n(s,"font-size");case"rem":return n(document.body,"font-size");case"vw":return window.innerWidth/100;case"vh":return window.innerHeight/100;case"vmin":return Math.min(window.innerWidth,window.innerHeight)/100;case"vmax":return Math.max(window.innerWidth,window.innerHeight)/100;case"in":return t;case"cm":return t/2.54;case"mm":return t/25.4;case"pt":return t/72;case"pc":return t/6;case"px":return 1}var a=e(o);if(!isNaN(a[0])&&a[1]){var l=r(a[1],s);return typeof l=="number"?a[0]*l:null}return null}return ur}Uh();function $l(){const e=()=>Math.floor((1+crypto.getRandomValues(new Uint32Array(1))[0])*65536).toString(16).substring(1);return`${e()+e()}-${e()}-${e()}-${e()}-${e()}${e()}${e()}`}function Wh(e,t){const n=e.substr(4,e.length-5);return getComputedStyle(t).getPropertyValue(n)}function Yh(e,t,n=0){const[i,r,o,s]=[e.x+n,e.y+e.height-2*n,e.x+e.width-2*n,e.y+n],[a,l,u,d]=[t.x+n,t.y+t.height-2*n,t.x+t.width-2*n,t.y+n];return!(r<d||l<s||o<a||u<i)}function Eo(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function Ml(e,t){var n=Object.create(e.prototype);for(var i in t)n[i]=t[i];return n}function Mn(){}var Sn=.7,pi=1/Sn,Lt="\\s*([+-]?\\d+)\\s*",bn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Ue="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",qh=/^#([0-9a-f]{3,8})$/,Xh=new RegExp(`^rgb\\(${Lt},${Lt},${Lt}\\)$`),jh=new RegExp(`^rgb\\(${Ue},${Ue},${Ue}\\)$`),Zh=new RegExp(`^rgba\\(${Lt},${Lt},${Lt},${bn}\\)$`),Qh=new RegExp(`^rgba\\(${Ue},${Ue},${Ue},${bn}\\)$`),Kh=new RegExp(`^hsl\\(${bn},${Ue},${Ue}\\)$`),Jh=new RegExp(`^hsla\\(${bn},${Ue},${Ue},${bn}\\)$`),Is={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Eo(Mn,Mt,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Bs,formatHex:Bs,formatHex8:eg,formatHsl:tg,formatRgb:zs,toString:zs});function Bs(){return this.rgb().formatHex()}function eg(){return this.rgb().formatHex8()}function tg(){return El(this).formatHsl()}function zs(){return this.rgb().formatRgb()}function Mt(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=qh.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?Hs(t):n===3?new me(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?On(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?On(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=Xh.exec(e))?new me(t[1],t[2],t[3],1):(t=jh.exec(e))?new me(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=Zh.exec(e))?On(t[1],t[2],t[3],t[4]):(t=Qh.exec(e))?On(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=Kh.exec(e))?Ws(t[1],t[2]/100,t[3]/100,1):(t=Jh.exec(e))?Ws(t[1],t[2]/100,t[3]/100,t[4]):Is.hasOwnProperty(e)?Hs(Is[e]):e==="transparent"?new me(NaN,NaN,NaN,0):null}function Hs(e){return new me(e>>16&255,e>>8&255,e&255,1)}function On(e,t,n,i){return i<=0&&(e=t=n=NaN),new me(e,t,n,i)}function ng(e){return e instanceof Mn||(e=Mt(e)),e?(e=e.rgb(),new me(e.r,e.g,e.b,e.opacity)):new me}function Br(e,t,n,i){return arguments.length===1?ng(e):new me(e,t,n,i??1)}function me(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}Eo(me,Br,Ml(Mn,{brighter(e){return e=e==null?pi:Math.pow(pi,e),new me(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Sn:Math.pow(Sn,e),new me(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new me(kt(this.r),kt(this.g),kt(this.b),mi(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:Gs,formatHex:Gs,formatHex8:ig,formatRgb:Us,toString:Us}));function Gs(){return`#${wt(this.r)}${wt(this.g)}${wt(this.b)}`}function ig(){return`#${wt(this.r)}${wt(this.g)}${wt(this.b)}${wt((isNaN(this.opacity)?1:this.opacity)*255)}`}function Us(){const e=mi(this.opacity);return`${e===1?"rgb(":"rgba("}${kt(this.r)}, ${kt(this.g)}, ${kt(this.b)}${e===1?")":`, ${e})`}`}function mi(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function kt(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function wt(e){return e=kt(e),(e<16?"0":"")+e.toString(16)}function Ws(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new Fe(e,t,n,i)}function El(e){if(e instanceof Fe)return new Fe(e.h,e.s,e.l,e.opacity);if(e instanceof Mn||(e=Mt(e)),!e)return new Fe;if(e instanceof Fe)return e;e=e.rgb();var t=e.r/255,n=e.g/255,i=e.b/255,r=Math.min(t,n,i),o=Math.max(t,n,i),s=NaN,a=o-r,l=(o+r)/2;return a?(t===o?s=(n-i)/a+(n<i)*6:n===o?s=(i-t)/a+2:s=(t-n)/a+4,a/=l<.5?o+r:2-o-r,s*=60):a=l>0&&l<1?0:s,new Fe(s,a,l,e.opacity)}function Ao(e,t,n,i){return arguments.length===1?El(e):new Fe(e,t,n,i??1)}function Fe(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}Eo(Fe,Ao,Ml(Mn,{brighter(e){return e=e==null?pi:Math.pow(pi,e),new Fe(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Sn:Math.pow(Sn,e),new Fe(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,r=2*n-i;return new me(cr(e>=240?e-240:e+120,r,i),cr(e,r,i),cr(e<120?e+240:e-120,r,i),this.opacity)},clamp(){return new Fe(Ys(this.h),Ln(this.s),Ln(this.l),mi(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=mi(this.opacity);return`${e===1?"hsl(":"hsla("}${Ys(this.h)}, ${Ln(this.s)*100}%, ${Ln(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Ys(e){return e=(e||0)%360,e<0?e+360:e}function Ln(e){return Math.max(0,Math.min(1,e||0))}function cr(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 sn=(globalThis==null?void 0:globalThis.UNOVIS_COLORS)||["#4D8CFD","#FF6B7E","#F4B83E","#A6CC74","#00C19A","#6859BE"],rg=(globalThis==null?void 0:globalThis.UNOVIS_COLORS_DARK)||["#4D8CFD","#FF6B7E","#FFC16D","#A6CC74","#00C19A","#7887E0"],ut=e=>`--vis-${be(e)?`color${e%sn.length}`:e}`;function og(e,t=.4){const n=Ao(e);return n.l=n.l*(1+t),n.formatHex()}function sg(e,t=.4,n=.6){const i=Ao(e);return i.s=i.s*(1-n),i.l=i.l*(1-t),i.formatHex()}const Cn=10,zr=[{id:"stripes-diagonal",svg:'<path d="M-1,1 l2,-2 M0,10 l10,-10 M9,11 l2,-2" stroke="#000"/>'},{id:"dots",svg:'<path d="m0-1.5a1 1 0 010 3m10-3a1 1 0 000 3M5 3.5a1 1 0 010 3 1 1 0 010-3M0 8.5 a1 1 0 010 3m10-3a1 1 0 000 3" fill"#000"/>'},{id:"stripes-vertical",svg:'<path d="M 5,-1 L5,11" stroke="#000"/>'},{id:"crosshatch",svg:'<path d="M0 0L10 10ZM10 0L0 10Z" stroke="#000"/>'},{id:"waves",svg:'<path d="M0 4Q2.5 1 5 4 7.5 7 10 4v2Q7.5 9 5 6 2.5 3 0 6Z" fill="#000"/>'},{id:"circles",svg:'<circle cx="5" cy="5" r="3" stroke="#000" fill="#fff"/>'}],Hr=[{id:"circle",marker:'<circle cx="5" cy="5" r="5"/>',dashArray:[]},{id:"triangle",marker:'<path d="M5,0 L10,9 L0,9Z">',dashArray:[9,1]},{id:"diamond",marker:'<path d="M 0 5 L5 0 L 10 5 L 5 10 L 0 5Z">',dashArray:[2]},{id:"arrow",marker:'<path d="M4 0 0 0 6 5 0 10 4 10 10 5Z">',dashArray:[2,3,8,3]},{id:"square",marker:'<rect x="1" y="1" width="8" height="8"/>',dashArray:[6]},{id:"star",marker:'<path d="m2 9 3-9 3 9L0 3h10Z"/>',dashArray:[1,6]}];function ct(e){return`vis-${`pattern-${e.svg?"fill":"marker"}`}-${e.id}`}const ag=e=>`<mask id="${ct(e)}">
|
|
2
|
-
<pattern id="${e.id}" viewBox="0 0 10 10" width="${Cn}" height="${Cn}" patternUnits="userSpaceOnUse">
|
|
3
|
-
<rect width="100%" height="100%" fill="#fff"/>
|
|
4
|
-
${e.svg}
|
|
5
|
-
</pattern>
|
|
6
|
-
<rect x="-50%" y="-50%" width="200%" height="200%" fill="url(#${e.id})"/>
|
|
7
|
-
</mask>`,lg=(e,t)=>`<marker id="${ct(e)}"
|
|
8
|
-
fill="var(${ut(t)})"
|
|
9
|
-
markerUnits="userSpaceOnUse"
|
|
10
|
-
refX="5"
|
|
11
|
-
refY="5"
|
|
12
|
-
markerWidth="${Cn}"
|
|
13
|
-
markerHeight="${Cn}">
|
|
14
|
-
${e.marker}
|
|
15
|
-
</marker>`;function ug(){const e=zr.map(ag).concat(Hr.map(lg)).join(""),t=document.createElementNS("http://www.w3.org/2000/svg","svg");t.setAttribute("height","100%"),t.setAttribute("width","100%"),t.style.position="fixed",t.style.zIndex="-99999999",t.innerHTML=`<defs>${e}</defs>`,document.body.appendChild(t)}typeof window<"u"&&ug();const Al=(globalThis==null?void 0:globalThis.UNOVIS_FONT_W2H_RATIO_DEFAULT)||.5,Fl=(globalThis==null?void 0:globalThis.UNOVIS_TEXT_SEPARATOR_DEFAULT)||[" ","-",".",","],Vl=(globalThis==null?void 0:globalThis.UNOVIS_TEXT_HYPHEN_CHARACTER_DEFAULT)||"-",qs=(globalThis==null?void 0:globalThis.UNOVIS_TEXT_DEFAULT)||{text:"",fontSize:12,fontFamily:"var(--vis-font-family)",lineHeight:1.25,marginTop:0,marginBottom:0};ot`
|
|
16
|
-
:root {
|
|
17
|
-
label: vis-root-styles;
|
|
18
|
-
--vis-font-family: Inter, Arial, "Helvetica Neue", Helvetica, sans-serif;
|
|
19
|
-
--vis-font-wh-ratio: ${Al};
|
|
20
|
-
--vis-color-main: var(${ut(0)});
|
|
21
|
-
--vis-color-main-light: ${og(sn[0])};
|
|
22
|
-
--vis-color-main-dark: ${sg(sn[0])};
|
|
23
|
-
--vis-color-grey: #2a2a2a;
|
|
24
|
-
${sn.map((e,t)=>`${ut(t)}: ${e};`)}
|
|
25
|
-
${rg.map((e,t)=>`--vis-dark-color${t}: ${e};`)}
|
|
26
|
-
${zr.map((e,t)=>`
|
|
27
|
-
--${ct(e)}: url(#${ct(e)});
|
|
28
|
-
--vis-pattern-fill${t}: var(--${ct(e)});
|
|
29
|
-
`)}
|
|
30
|
-
${Hr.map((e,t)=>{var n;return`
|
|
31
|
-
--${ct(e)}: url(#${ct(e)});
|
|
32
|
-
--vis-pattern-marker${t}: var(--${ct(e)});
|
|
33
|
-
--vis-pattern-dasharray${t}: ${(n=e.dashArray)===null||n===void 0?void 0:n.join(" ")};
|
|
34
|
-
`})}
|
|
35
|
-
|
|
36
|
-
body.theme-dark {
|
|
37
|
-
${sn.map((e,t)=>`${ut(t)}: var(--vis-dark-color${t});`)}
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
body.theme-patterns {
|
|
41
|
-
${zr.map((e,t)=>`path[style*="fill: var(${ut(t)})"] {
|
|
42
|
-
mask: var(--vis-pattern-fill${t});
|
|
43
|
-
}`)}
|
|
44
|
-
${Hr.map((e,t)=>`
|
|
45
|
-
path[stroke="var(${ut(t)})"]:not([style*="fill"]),
|
|
46
|
-
path[style*="stroke: var(${ut(t)})"]:not([style*="fill"]) {
|
|
47
|
-
marker: var(--vis-pattern-marker${t});
|
|
48
|
-
stroke-dasharray: var(--vis-pattern-dasharray${t});
|
|
49
|
-
}
|
|
50
|
-
`)}
|
|
51
|
-
}
|
|
52
|
-
`;function cg(e=window==null?void 0:window.document.body){return e?+Wh("var(--vis-font-wh-ratio)",e):Al}var dg={value:()=>{}};function Nl(){for(var e=0,t=arguments.length,n={},i;e<t;++e){if(!(i=arguments[e]+"")||i in n||/[\s.]/.test(i))throw new Error("illegal type: "+i);n[i]=[]}return new Qn(n)}function Qn(e){this._=e}function fg(e,t){return e.trim().split(/^|\s+/).map(function(n){var i="",r=n.indexOf(".");if(r>=0&&(i=n.slice(r+1),n=n.slice(0,r)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:i}})}Qn.prototype=Nl.prototype={constructor:Qn,on:function(e,t){var n=this._,i=fg(e+"",n),r,o=-1,s=i.length;if(arguments.length<2){for(;++o<s;)if((r=(e=i[o]).type)&&(r=hg(n[r],e.name)))return r;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++o<s;)if(r=(e=i[o]).type)n[r]=Xs(n[r],e.name,t);else if(t==null)for(r in n)n[r]=Xs(n[r],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new Qn(e)},call:function(e,t){if((r=arguments.length-2)>0)for(var n=new Array(r),i=0,r,o;i<r;++i)n[i]=arguments[i+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(o=this._[e],i=0,r=o.length;i<r;++i)o[i].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var i=this._[e],r=0,o=i.length;r<o;++r)i[r].value.apply(t,n)}};function hg(e,t){for(var n=0,i=e.length,r;n<i;++n)if((r=e[n]).name===t)return r.value}function Xs(e,t,n){for(var i=0,r=e.length;i<r;++i)if(e[i].name===t){e[i]=dg,e=e.slice(0,i).concat(e.slice(i+1));break}return n!=null&&e.push({name:t,value:n}),e}var Ut=0,an=0,en=0,Dl=1e3,vi,ln,_i=0,Et=0,Ii=0,kn=typeof performance=="object"&&performance.now?performance:Date,Pl=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Fo(){return Et||(Pl(gg),Et=kn.now()+Ii)}function gg(){Et=0}function yi(){this._call=this._time=this._next=null}yi.prototype=Ol.prototype={constructor:yi,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?Fo():+n)+(t==null?0:+t),!this._next&&ln!==this&&(ln?ln._next=this:vi=this,ln=this),this._call=e,this._time=n,Gr()},stop:function(){this._call&&(this._call=null,this._time=1/0,Gr())}};function Ol(e,t,n){var i=new yi;return i.restart(e,t,n),i}function pg(){Fo(),++Ut;for(var e=vi,t;e;)(t=Et-e._time)>=0&&e._call.call(void 0,t),e=e._next;--Ut}function js(){Et=(_i=kn.now())+Ii,Ut=an=0;try{pg()}finally{Ut=0,vg(),Et=0}}function mg(){var e=kn.now(),t=e-_i;t>Dl&&(Ii-=t,_i=e)}function vg(){for(var e,t=vi,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:vi=n);ln=e,Gr(i)}function Gr(e){if(!Ut){an&&(an=clearTimeout(an));var t=e-Et;t>24?(e<1/0&&(an=setTimeout(js,e-kn.now()-Ii)),en&&(en=clearInterval(en))):(en||(_i=kn.now(),en=setInterval(mg,Dl)),Ut=1,Pl(js))}}function Zs(e,t,n){var i=new yi;return t=t==null?0:+t,i.restart(r=>{i.stop(),e(r+t)},t,n),i}var _g=Nl("start","end","cancel","interrupt"),yg=[],Ll=0,Qs=1,Ur=2,Kn=3,Ks=4,Wr=5,Jn=6;function Bi(e,t,n,i,r,o){var s=e.__transition;if(!s)e.__transition={};else if(n in s)return;xg(e,n,{name:t,index:i,group:r,on:_g,tween:yg,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:Ll})}function Vo(e,t){var n=De(e,t);if(n.state>Ll)throw new Error("too late; already scheduled");return n}function We(e,t){var n=De(e,t);if(n.state>Kn)throw new Error("too late; already running");return n}function De(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function xg(e,t,n){var i=e.__transition,r;i[t]=n,n.timer=Ol(o,0,n.time);function o(u){n.state=Qs,n.timer.restart(s,n.delay,n.time),n.delay<=u&&s(u-n.delay)}function s(u){var d,f,h,g;if(n.state!==Qs)return l();for(d in i)if(g=i[d],g.name===n.name){if(g.state===Kn)return Zs(s);g.state===Ks?(g.state=Jn,g.timer.stop(),g.on.call("interrupt",e,e.__data__,g.index,g.group),delete i[d]):+d<t&&(g.state=Jn,g.timer.stop(),g.on.call("cancel",e,e.__data__,g.index,g.group),delete i[d])}if(Zs(function(){n.state===Kn&&(n.state=Ks,n.timer.restart(a,n.delay,n.time),a(u))}),n.state=Ur,n.on.call("start",e,e.__data__,n.index,n.group),n.state===Ur){for(n.state=Kn,r=new Array(h=n.tween.length),d=0,f=-1;d<h;++d)(g=n.tween[d].value.call(e,e.__data__,n.index,n.group))&&(r[++f]=g);r.length=f+1}}function a(u){for(var d=u<n.duration?n.ease.call(null,u/n.duration):(n.timer.restart(l),n.state=Wr,1),f=-1,h=r.length;++f<h;)r[f].call(e,d);n.state===Wr&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){n.state=Jn,n.timer.stop(),delete i[t];for(var u in i)return;delete e.__transition}}function No(e,t){var n=e.__transition,i,r,o=!0,s;if(n){t=t==null?null:t+"";for(s in n){if((i=n[s]).name!==t){o=!1;continue}r=i.state>Ur&&i.state<Wr,i.state=Jn,i.timer.stop(),i.on.call(r?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete n[s]}o&&delete e.__transition}}function wg(e){return this.each(function(){No(this,e)})}const Do=e=>()=>e;function Sg(e,t){return function(n){return e+n*t}}function bg(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 Cg(e){return(e=+e)==1?Il:function(t,n){return n-t?bg(t,n,e):Do(isNaN(t)?n:t)}}function Il(e,t){var n=t-e;return n?Sg(e,n):Do(isNaN(e)?t:e)}const xi=function e(t){var n=Cg(t);function i(r,o){var s=n((r=Br(r)).r,(o=Br(o)).r),a=n(r.g,o.g),l=n(r.b,o.b),u=Il(r.opacity,o.opacity);return function(d){return r.r=s(d),r.g=a(d),r.b=l(d),r.opacity=u(d),r+""}}return i.gamma=e,i}(1);function kg(e,t){t||(t=[]);var n=e?Math.min(t.length,e.length):0,i=t.slice(),r;return function(o){for(r=0;r<n;++r)i[r]=e[r]*(1-o)+t[r]*o;return i}}function Tg(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Rg(e,t){var n=t?t.length:0,i=e?Math.min(n,e.length):0,r=new Array(i),o=new Array(n),s;for(s=0;s<i;++s)r[s]=At(e[s],t[s]);for(;s<n;++s)o[s]=t[s];return function(a){for(s=0;s<i;++s)o[s]=r[s](a);return o}}function $g(e,t){var n=new Date;return e=+e,t=+t,function(i){return n.setTime(e*(1-i)+t*i),n}}function Ee(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function Mg(e,t){var n={},i={},r;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(r in t)r in e?n[r]=At(e[r],t[r]):i[r]=t[r];return function(o){for(r in n)i[r]=n[r](o);return i}}var Yr=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,dr=new RegExp(Yr.source,"g");function Eg(e){return function(){return e}}function Ag(e){return function(t){return e(t)+""}}function Bl(e,t){var n=Yr.lastIndex=dr.lastIndex=0,i,r,o,s=-1,a=[],l=[];for(e=e+"",t=t+"";(i=Yr.exec(e))&&(r=dr.exec(t));)(o=r.index)>n&&(o=t.slice(n,o),a[s]?a[s]+=o:a[++s]=o),(i=i[0])===(r=r[0])?a[s]?a[s]+=r:a[++s]=r:(a[++s]=null,l.push({i:s,x:Ee(i,r)})),n=dr.lastIndex;return n<t.length&&(o=t.slice(n),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?Ag(l[0].x):Eg(t):(t=l.length,function(u){for(var d=0,f;d<t;++d)a[(f=l[d]).i]=f.x(u);return a.join("")})}function At(e,t){var n=typeof t,i;return t==null||n==="boolean"?Do(t):(n==="number"?Ee:n==="string"?(i=Mt(t))?(t=i,xi):Bl:t instanceof Mt?xi:t instanceof Date?$g:Tg(t)?kg:Array.isArray(t)?Rg:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Mg:Ee)(e,t)}function Po(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var Js=180/Math.PI,qr={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function zl(e,t,n,i,r,o){var s,a,l;return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*i)&&(n-=e*l,i-=t*l),(a=Math.sqrt(n*n+i*i))&&(n/=a,i/=a,l/=a),e*i<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:r,translateY:o,rotate:Math.atan2(t,e)*Js,skewX:Math.atan(l)*Js,scaleX:s,scaleY:a}}var In;function Fg(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?qr:zl(t.a,t.b,t.c,t.d,t.e,t.f)}function Vg(e){return e==null||(In||(In=document.createElementNS("http://www.w3.org/2000/svg","g")),In.setAttribute("transform",e),!(e=In.transform.baseVal.consolidate()))?qr:(e=e.matrix,zl(e.a,e.b,e.c,e.d,e.e,e.f))}function Hl(e,t,n,i){function r(u){return u.length?u.pop()+" ":""}function o(u,d,f,h,g,m){if(u!==f||d!==h){var p=g.push("translate(",null,t,null,n);m.push({i:p-4,x:Ee(u,f)},{i:p-2,x:Ee(d,h)})}else(f||h)&&g.push("translate("+f+t+h+n)}function s(u,d,f,h){u!==d?(u-d>180?d+=360:d-u>180&&(u+=360),h.push({i:f.push(r(f)+"rotate(",null,i)-2,x:Ee(u,d)})):d&&f.push(r(f)+"rotate("+d+i)}function a(u,d,f,h){u!==d?h.push({i:f.push(r(f)+"skewX(",null,i)-2,x:Ee(u,d)}):d&&f.push(r(f)+"skewX("+d+i)}function l(u,d,f,h,g,m){if(u!==f||d!==h){var p=g.push(r(g)+"scale(",null,",",null,")");m.push({i:p-4,x:Ee(u,f)},{i:p-2,x:Ee(d,h)})}else(f!==1||h!==1)&&g.push(r(g)+"scale("+f+","+h+")")}return function(u,d){var f=[],h=[];return u=e(u),d=e(d),o(u.translateX,u.translateY,d.translateX,d.translateY,f,h),s(u.rotate,d.rotate,f,h),a(u.skewX,d.skewX,f,h),l(u.scaleX,u.scaleY,d.scaleX,d.scaleY,f,h),u=d=null,function(g){for(var m=-1,p=h.length,v;++m<p;)f[(v=h[m]).i]=v.x(g);return f.join("")}}}var Ng=Hl(Fg,"px, ","px)","deg)"),Dg=Hl(Vg,", ",")",")");function Pg(e,t){t===void 0&&(t=e,e=At);for(var n=0,i=t.length-1,r=t[0],o=new Array(i<0?0:i);n<i;)o[n]=e(r,r=t[++n]);return function(s){var a=Math.max(0,Math.min(i-1,Math.floor(s*=i)));return o[a](s-a)}}function Og(e,t){var n,i;return function(){var r=We(this,e),o=r.tween;if(o!==n){i=n=o;for(var s=0,a=i.length;s<a;++s)if(i[s].name===t){i=i.slice(),i.splice(s,1);break}}r.tween=i}}function Lg(e,t,n){var i,r;if(typeof n!="function")throw new Error;return function(){var o=We(this,e),s=o.tween;if(s!==i){r=(i=s).slice();for(var a={name:t,value:n},l=0,u=r.length;l<u;++l)if(r[l].name===t){r[l]=a;break}l===u&&r.push(a)}o.tween=r}}function Ig(e,t){var n=this._id;if(e+="",arguments.length<2){for(var i=De(this.node(),n).tween,r=0,o=i.length,s;r<o;++r)if((s=i[r]).name===e)return s.value;return null}return this.each((t==null?Og:Lg)(n,e,t))}function Oo(e,t,n){var i=e._id;return e.each(function(){var r=We(this,i);(r.value||(r.value={}))[t]=n.apply(this,arguments)}),function(r){return De(r,i).value[t]}}function Gl(e,t){var n;return(typeof t=="number"?Ee:t instanceof Mt?xi:(n=Mt(t))?(t=n,xi):Bl)(e,t)}function Bg(e){return function(){this.removeAttribute(e)}}function zg(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Hg(e,t,n){var i,r=n+"",o;return function(){var s=this.getAttribute(e);return s===r?null:s===i?o:o=t(i=s,n)}}function Gg(e,t,n){var i,r=n+"",o;return function(){var s=this.getAttributeNS(e.space,e.local);return s===r?null:s===i?o:o=t(i=s,n)}}function Ug(e,t,n){var i,r,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttribute(e):(s=this.getAttribute(e),l=a+"",s===l?null:s===i&&l===r?o:(r=l,o=t(i=s,a)))}}function Wg(e,t,n){var i,r,o;return function(){var s,a=n(this),l;return a==null?void this.removeAttributeNS(e.space,e.local):(s=this.getAttributeNS(e.space,e.local),l=a+"",s===l?null:s===i&&l===r?o:(r=l,o=t(i=s,a)))}}function Yg(e,t){var n=Vi(e),i=n==="transform"?Dg:Gl;return this.attrTween(e,typeof t=="function"?(n.local?Wg:Ug)(n,i,Oo(this,"attr."+e,t)):t==null?(n.local?zg:Bg)(n):(n.local?Gg:Hg)(n,i,t))}function qg(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function Xg(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function jg(e,t){var n,i;function r(){var o=t.apply(this,arguments);return o!==i&&(n=(i=o)&&Xg(e,o)),n}return r._value=t,r}function Zg(e,t){var n,i;function r(){var o=t.apply(this,arguments);return o!==i&&(n=(i=o)&&qg(e,o)),n}return r._value=t,r}function Qg(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var i=Vi(e);return this.tween(n,(i.local?jg:Zg)(i,t))}function Kg(e,t){return function(){Vo(this,e).delay=+t.apply(this,arguments)}}function Jg(e,t){return t=+t,function(){Vo(this,e).delay=t}}function ep(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?Kg:Jg)(t,e)):De(this.node(),t).delay}function tp(e,t){return function(){We(this,e).duration=+t.apply(this,arguments)}}function np(e,t){return t=+t,function(){We(this,e).duration=t}}function ip(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?tp:np)(t,e)):De(this.node(),t).duration}function rp(e,t){if(typeof t!="function")throw new Error;return function(){We(this,e).ease=t}}function op(e){var t=this._id;return arguments.length?this.each(rp(t,e)):De(this.node(),t).ease}function sp(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;We(this,e).ease=n}}function ap(e){if(typeof e!="function")throw new Error;return this.each(sp(this._id,e))}function lp(e){typeof e!="function"&&(e=Qa(e));for(var t=this._groups,n=t.length,i=new Array(n),r=0;r<n;++r)for(var o=t[r],s=o.length,a=i[r]=[],l,u=0;u<s;++u)(l=o[u])&&e.call(l,l.__data__,u,o)&&a.push(l);return new tt(i,this._parents,this._name,this._id)}function up(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,i=t.length,r=n.length,o=Math.min(i,r),s=new Array(i),a=0;a<o;++a)for(var l=t[a],u=n[a],d=l.length,f=s[a]=new Array(d),h,g=0;g<d;++g)(h=l[g]||u[g])&&(f[g]=h);for(;a<i;++a)s[a]=t[a];return new tt(s,this._parents,this._name,this._id)}function cp(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function dp(e,t,n){var i,r,o=cp(t)?Vo:We;return function(){var s=o(this,e),a=s.on;a!==i&&(r=(i=a).copy()).on(t,n),s.on=r}}function fp(e,t){var n=this._id;return arguments.length<2?De(this.node(),n).on.on(e):this.each(dp(n,e,t))}function hp(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function gp(){return this.on("end.remove",hp(this._id))}function pp(e){var t=this._name,n=this._id;typeof e!="function"&&(e=wo(e));for(var i=this._groups,r=i.length,o=new Array(r),s=0;s<r;++s)for(var a=i[s],l=a.length,u=o[s]=new Array(l),d,f,h=0;h<l;++h)(d=a[h])&&(f=e.call(d,d.__data__,h,a))&&("__data__"in d&&(f.__data__=d.__data__),u[h]=f,Bi(u[h],t,n,h,u,De(d,n)));return new tt(o,this._parents,t,n)}function mp(e){var t=this._name,n=this._id;typeof e!="function"&&(e=Za(e));for(var i=this._groups,r=i.length,o=[],s=[],a=0;a<r;++a)for(var l=i[a],u=l.length,d,f=0;f<u;++f)if(d=l[f]){for(var h=e.call(d,d.__data__,f,l),g,m=De(d,n),p=0,v=h.length;p<v;++p)(g=h[p])&&Bi(g,t,n,p,h,m);o.push(h),s.push(d)}return new tt(o,s,t,n)}var vp=Rn.prototype.constructor;function _p(){return new vp(this._groups,this._parents)}function yp(e,t){var n,i,r;return function(){var o=Bt(this,e),s=(this.style.removeProperty(e),Bt(this,e));return o===s?null:o===n&&s===i?r:r=t(n=o,i=s)}}function Ul(e){return function(){this.style.removeProperty(e)}}function xp(e,t,n){var i,r=n+"",o;return function(){var s=Bt(this,e);return s===r?null:s===i?o:o=t(i=s,n)}}function wp(e,t,n){var i,r,o;return function(){var s=Bt(this,e),a=n(this),l=a+"";return a==null&&(l=a=(this.style.removeProperty(e),Bt(this,e))),s===l?null:s===i&&l===r?o:(r=l,o=t(i=s,a))}}function Sp(e,t){var n,i,r,o="style."+t,s="end."+o,a;return function(){var l=We(this,e),u=l.on,d=l.value[o]==null?a||(a=Ul(t)):void 0;(u!==n||r!==d)&&(i=(n=u).copy()).on(s,r=d),l.on=i}}function bp(e,t,n){var i=(e+="")=="transform"?Ng:Gl;return t==null?this.styleTween(e,yp(e,i)).on("end.style."+e,Ul(e)):typeof t=="function"?this.styleTween(e,wp(e,i,Oo(this,"style."+e,t))).each(Sp(this._id,e)):this.styleTween(e,xp(e,i,t),n).on("end.style."+e,null)}function Cp(e,t,n){return function(i){this.style.setProperty(e,t.call(this,i),n)}}function kp(e,t,n){var i,r;function o(){var s=t.apply(this,arguments);return s!==r&&(i=(r=s)&&Cp(e,s,n)),i}return o._value=t,o}function Tp(e,t,n){var i="style."+(e+="");if(arguments.length<2)return(i=this.tween(i))&&i._value;if(t==null)return this.tween(i,null);if(typeof t!="function")throw new Error;return this.tween(i,kp(e,t,n??""))}function Rp(e){return function(){this.textContent=e}}function $p(e){return function(){var t=e(this);this.textContent=t??""}}function Mp(e){return this.tween("text",typeof e=="function"?$p(Oo(this,"text",e)):Rp(e==null?"":e+""))}function Ep(e){return function(t){this.textContent=e.call(this,t)}}function Ap(e){var t,n;function i(){var r=e.apply(this,arguments);return r!==n&&(t=(n=r)&&Ep(r)),t}return i._value=e,i}function Fp(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,Ap(e))}function Vp(){for(var e=this._name,t=this._id,n=Wl(),i=this._groups,r=i.length,o=0;o<r;++o)for(var s=i[o],a=s.length,l,u=0;u<a;++u)if(l=s[u]){var d=De(l,t);Bi(l,e,n,u,s,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new tt(i,this._parents,e,n)}function Np(){var e,t,n=this,i=n._id,r=n.size();return new Promise(function(o,s){var a={value:s},l={value:function(){--r===0&&o()}};n.each(function(){var u=We(this,i),d=u.on;d!==e&&(t=(e=d).copy(),t._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),u.on=t}),r===0&&o()})}var Dp=0;function tt(e,t,n,i){this._groups=e,this._parents=t,this._name=n,this._id=i}function Wl(){return++Dp}var Xe=Rn.prototype;tt.prototype={constructor:tt,select:pp,selectAll:mp,selectChild:Xe.selectChild,selectChildren:Xe.selectChildren,filter:lp,merge:up,selection:_p,transition:Vp,call:Xe.call,nodes:Xe.nodes,node:Xe.node,size:Xe.size,empty:Xe.empty,each:Xe.each,on:fp,attr:Yg,attrTween:Qg,style:bp,styleTween:Tp,text:Mp,textTween:Fp,remove:gp,tween:Ig,delay:ep,duration:ip,ease:op,easeVarying:ap,end:Np,[Symbol.iterator]:Xe[Symbol.iterator]};const ea=e=>+e;function Pp(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var Op={time:null,delay:0,duration:250,ease:Pp};function Lp(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function Ip(e){var t,n;e instanceof tt?(t=e._id,e=e._name):(t=Wl(),(n=Op).time=Fo(),e=e==null?null:e+"");for(var i=this._groups,r=i.length,o=0;o<r;++o)for(var s=i[o],a=s.length,l,u=0;u<a;++u)(l=s[u])&&Bi(l,e,t,u,s,n||Lp(l,t));return new tt(i,this._parents,e,t)}Rn.prototype.interrupt=wg;Rn.prototype.transition=Ip;function Z(e,t,n){if(e.nodes().forEach(i=>No(i)),t){const i=e.transition().duration(t);return n&&i.ease(n),i}else return e}const Bp=Object.assign(Object.assign({},To),{tooltip:void 0,annotations:void 0});class zp extends Ht{constructor(t,n,i){var r;super(t),this._defaultConfig=Bp,this.config=this._defaultConfig,n&&(this.updateContainer(n,!0),this.component=n.component),i&&this.setData(i,!0),!((r=this.component)===null||r===void 0)&&r.datamodel.data&&this.render()}setData(t,n){var i;const{config:r}=this;this.component&&this.component.setData(t),n||this.render(),(i=r.tooltip)===null||i===void 0||i.hide()}updateContainer(t,n){super.updateContainer(t),this._removeAllChildren(),this.component=t.component,t.sizing&&(this.component.sizing=t.sizing),this.element.appendChild(this.component.element);const i=t.tooltip;i&&(i.hasContainer()||i.setContainer(this._container),i.setComponents([this.component]));const r=t.annotations;r&&this.element.appendChild(r.element),this.element.appendChild(this._svgDefs.node()),this.element.appendChild(this._svgDefsExternal.node()),n||this.render()}updateComponent(t,n){this.component.setConfig(t),n||this.render()}update(t,n,i){t&&this.updateContainer(t,!0),n&&this.updateComponent(n,!0),i&&this.setData(i,!0),this.render()}getFitWidthScale(){const{config:t,component:n}=this,i=n;if(!i.getWidth)return 1;const r=i.getWidth()+t.margin.left+t.margin.right;return this.width/r}_preRender(){var t;super._preRender(),this.component.setSize(this.width,this.height,this.containerWidth,this.containerHeight),(t=this.config.annotations)===null||t===void 0||t.setSize(this.width,this.height,this.containerWidth,this.containerHeight)}_render(t){var n;const{config:i,component:r}=this;super._render(t),r.g.attr("transform",`translate(${i.margin.left},${i.margin.top})`),r.render(t),(n=i.annotations)===null||n===void 0||n.render(t),i.tooltip&&i.tooltip.update()}render(t=this.config.duration){const{config:n,component:i}=this;if(n.sizing===Je.Extend||n.sizing===Je.FitWidth){const r=n.sizing===Je.FitWidth,o=i,s=o.getWidth()+n.margin.left+n.margin.right,a=o.getHeight()+n.margin.top+n.margin.bottom,l=r?this.getFitWidthScale():1,u=this.svg.attr("width"),d=this.svg.attr("height"),f=s*l,h=a*l,g=u||d;Z(this.svg,g?t:0).attr("width",f).attr("height",h).attr("viewBox",`0 0 ${s} ${r?h:a}`).attr("preserveAspectRatio","xMinYMin")}else this.svg.attr("width",this.config.width||this.containerWidth).attr("height",this.config.height||this.containerHeight);this._resizeObserver||this._setUpResizeObserver(),cancelAnimationFrame(this._renderAnimationFrameId),this._renderAnimationFrameId=requestAnimationFrame(()=>{this._preRender(),this._render(t)})}_onResize(){var t;const{config:n}=this;super._onResize(),(t=n.tooltip)===null||t===void 0||t.hide()}destroy(){var t,n;const{component:i,config:r}=this;super.destroy(),i==null||i.destroy(),(t=r.tooltip)===null||t===void 0||t.destroy(),(n=r.annotations)===null||n===void 0||n.destroy()}}class Lo{constructor(t){this.data=t}get data(){return this._data}set data(t){this._data=t}}var W;(function(e){e.X="x",e.Y="y"})(W||(W={}));function Pe(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function Yl(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 ta=Symbol("implicit");function Io(){var e=new vs,t=[],n=[],i=ta;function r(o){let s=e.get(o);if(s===void 0){if(i!==ta)return i;e.set(o,s=t.push(o)-1)}return n[s%n.length]}return r.domain=function(o){if(!arguments.length)return t.slice();t=[],e=new vs;for(const s of o)e.has(s)||e.set(s,t.push(s)-1);return r},r.range=function(o){return arguments.length?(n=Array.from(o),r):n.slice()},r.unknown=function(o){return arguments.length?(i=o,r):i},r.copy=function(){return Io(t,n).unknown(i)},Pe.apply(r,arguments),r}function zi(){var e=Io().unknown(void 0),t=e.domain,n=e.range,i=0,r=1,o,s,a=!1,l=0,u=0,d=.5;delete e.unknown;function f(){var h=t().length,g=r<i,m=g?r:i,p=g?i:r;o=(p-m)/Math.max(1,h-l+u*2),a&&(o=Math.floor(o)),m+=(p-m-o*(h-l))*d,s=o*(1-l),a&&(m=Math.round(m),s=Math.round(s));var v=ll(h).map(function(_){return m+o*_});return n(g?v.reverse():v)}return e.domain=function(h){return arguments.length?(t(h),f()):t()},e.range=function(h){return arguments.length?([i,r]=h,i=+i,r=+r,f()):[i,r]},e.rangeRound=function(h){return[i,r]=h,i=+i,r=+r,a=!0,f()},e.bandwidth=function(){return s},e.step=function(){return o},e.round=function(h){return arguments.length?(a=!!h,f()):a},e.padding=function(h){return arguments.length?(l=Math.min(1,u=+h),f()):l},e.paddingInner=function(h){return arguments.length?(l=Math.min(1,h),f()):l},e.paddingOuter=function(h){return arguments.length?(u=+h,f()):u},e.align=function(h){return arguments.length?(d=Math.max(0,Math.min(1,h)),f()):d},e.copy=function(){return zi(t(),[i,r]).round(a).paddingInner(l).paddingOuter(u).align(d)},Pe.apply(f(),arguments)}function ql(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return ql(t())},e}function Hp(){return ql(zi.apply(null,arguments).paddingInner(1))}function Gp(e){return function(){return e}}function Xr(e){return+e}var na=[0,1];function ve(e){return e}function jr(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:Gp(isNaN(t)?NaN:.5)}function Up(e,t){var n;return e>t&&(n=e,e=t,t=n),function(i){return Math.max(e,Math.min(t,i))}}function Wp(e,t,n){var i=e[0],r=e[1],o=t[0],s=t[1];return r<i?(i=jr(r,i),o=n(s,o)):(i=jr(i,r),o=n(o,s)),function(a){return o(i(a))}}function Yp(e,t,n){var i=Math.min(e.length,t.length)-1,r=new Array(i),o=new Array(i),s=-1;for(e[i]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<i;)r[s]=jr(e[s],e[s+1]),o[s]=n(t[s],t[s+1]);return function(a){var l=Di(e,a,1,i)-1;return o[l](r[l](a))}}function En(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Hi(){var e=na,t=na,n=At,i,r,o,s=ve,a,l,u;function d(){var h=Math.min(e.length,t.length);return s!==ve&&(s=Up(e[0],e[h-1])),a=h>2?Yp:Wp,l=u=null,f}function f(h){return h==null||isNaN(h=+h)?o:(l||(l=a(e.map(i),t,n)))(i(s(h)))}return f.invert=function(h){return s(r((u||(u=a(t,e.map(i),Ee)))(h)))},f.domain=function(h){return arguments.length?(e=Array.from(h,Xr),d()):e.slice()},f.range=function(h){return arguments.length?(t=Array.from(h),d()):t.slice()},f.rangeRound=function(h){return t=Array.from(h),n=Po,d()},f.clamp=function(h){return arguments.length?(s=h?!0:ve,d()):s!==ve},f.interpolate=function(h){return arguments.length?(n=h,d()):n},f.unknown=function(h){return arguments.length?(o=h,f):o},function(h,g){return i=h,r=g,d()}}function Xl(){return Hi()(ve,ve)}function qp(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function wi(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 Wt(e){return e=wi(Math.abs(e)),e?e[1]:NaN}function Xp(e,t){return function(n,i){for(var r=n.length,o=[],s=0,a=e[0],l=0;r>0&&a>0&&(l+a+1>i&&(a=Math.max(1,i-l)),o.push(n.substring(r-=a,r+a)),!((l+=a+1)>i));)a=e[s=(s+1)%e.length];return o.reverse().join(t)}}function jp(e){return function(t){return t.replace(/[0-9]/g,function(n){return e[+n]})}}var Zp=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Tn(e){if(!(t=Zp.exec(e)))throw new Error("invalid format: "+e);var t;return new Bo({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]})}Tn.prototype=Bo.prototype;function Bo(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+""}Bo.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 Qp(e){e:for(var t=e.length,n=1,i=-1,r;n<t;++n)switch(e[n]){case".":i=r=n;break;case"0":i===0&&(i=n),r=n;break;default:if(!+e[n])break e;i>0&&(i=0);break}return i>0?e.slice(0,i)+e.slice(r+1):e}var jl;function Kp(e,t){var n=wi(e,t);if(!n)return e+"";var i=n[0],r=n[1],o=r-(jl=Math.max(-8,Math.min(8,Math.floor(r/3)))*3)+1,s=i.length;return o===s?i:o>s?i+new Array(o-s+1).join("0"):o>0?i.slice(0,o)+"."+i.slice(o):"0."+new Array(1-o).join("0")+wi(e,Math.max(0,t+o-1))[0]}function ia(e,t){var n=wi(e,t);if(!n)return e+"";var i=n[0],r=n[1];return r<0?"0."+new Array(-r).join("0")+i:i.length>r+1?i.slice(0,r+1)+"."+i.slice(r+1):i+new Array(r-i.length+2).join("0")}const ra={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:qp,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)=>ia(e*100,t),r:ia,s:Kp,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function oa(e){return e}var sa=Array.prototype.map,aa=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Jp(e){var t=e.grouping===void 0||e.thousands===void 0?oa:Xp(sa.call(e.grouping,Number),e.thousands+""),n=e.currency===void 0?"":e.currency[0]+"",i=e.currency===void 0?"":e.currency[1]+"",r=e.decimal===void 0?".":e.decimal+"",o=e.numerals===void 0?oa:jp(sa.call(e.numerals,String)),s=e.percent===void 0?"%":e.percent+"",a=e.minus===void 0?"−":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(f){f=Tn(f);var h=f.fill,g=f.align,m=f.sign,p=f.symbol,v=f.zero,_=f.width,y=f.comma,x=f.precision,w=f.trim,S=f.type;S==="n"?(y=!0,S="g"):ra[S]||(x===void 0&&(x=12),w=!0,S="g"),(v||h==="0"&&g==="=")&&(v=!0,h="0",g="=");var b=p==="$"?n:p==="#"&&/[boxX]/.test(S)?"0"+S.toLowerCase():"",C=p==="$"?i:/[%p]/.test(S)?s:"",V=ra[S],F=/[defgprs%]/.test(S);x=x===void 0?6:/[gprs]/.test(S)?Math.max(1,Math.min(21,x)):Math.max(0,Math.min(20,x));function U(M){var I=b,T=C,D,ie,de;if(S==="c")T=V(M)+T,M="";else{M=+M;var re=M<0||1/M<0;if(M=isNaN(M)?l:V(Math.abs(M),x),w&&(M=Qp(M)),re&&+M==0&&m!=="+"&&(re=!1),I=(re?m==="("?m:a:m==="-"||m==="("?"":m)+I,T=(S==="s"?aa[8+jl/3]:"")+T+(re&&m==="("?")":""),F){for(D=-1,ie=M.length;++D<ie;)if(de=M.charCodeAt(D),48>de||de>57){T=(de===46?r+M.slice(D+1):M.slice(D))+T,M=M.slice(0,D);break}}}y&&!v&&(M=t(M,1/0));var fe=I.length+M.length+T.length,J=fe<_?new Array(_-fe+1).join(h):"";switch(y&&v&&(M=t(J+M,J.length?_-T.length:1/0),J=""),g){case"<":M=I+M+T+J;break;case"=":M=I+J+M+T;break;case"^":M=J.slice(0,fe=J.length>>1)+I+M+T+J.slice(fe);break;default:M=J+I+M+T;break}return o(M)}return U.toString=function(){return f+""},U}function d(f,h){var g=u((f=Tn(f),f.type="f",f)),m=Math.max(-8,Math.min(8,Math.floor(Wt(h)/3)))*3,p=Math.pow(10,-m),v=aa[8+m/3];return function(_){return g(p*_)+v}}return{format:u,formatPrefix:d}}var Bn,zo,Zl;em({thousands:",",grouping:[3],currency:["$",""]});function em(e){return Bn=Jp(e),zo=Bn.format,Zl=Bn.formatPrefix,Bn}function tm(e){return Math.max(0,-Wt(Math.abs(e)))}function nm(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Wt(t)/3)))*3-Wt(Math.abs(e)))}function im(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,Wt(t)-Wt(e))+1}function rm(e,t,n,i){var r=Nr(e,t,n),o;switch(i=Tn(i??",f"),i.type){case"s":{var s=Math.max(Math.abs(e),Math.abs(t));return i.precision==null&&!isNaN(o=nm(r,s))&&(i.precision=o),Zl(i,s)}case"":case"e":case"g":case"p":case"r":{i.precision==null&&!isNaN(o=im(r,Math.max(Math.abs(e),Math.abs(t))))&&(i.precision=o-(i.type==="e"));break}case"f":case"%":{i.precision==null&&!isNaN(o=tm(r))&&(i.precision=o-(i.type==="%")*2);break}}return zo(i)}function Ft(e){var t=e.domain;return e.ticks=function(n){var i=t();return Fr(i[0],i[i.length-1],n??10)},e.tickFormat=function(n,i){var r=t();return rm(r[0],r[r.length-1],n??10,i)},e.nice=function(n){n==null&&(n=10);var i=t(),r=0,o=i.length-1,s=i[r],a=i[o],l,u,d=10;for(a<s&&(u=s,s=a,a=u,u=r,r=o,o=u);d-- >0;){if(u=Vr(s,a,n),u===l)return i[r]=s,i[o]=a,t(i);if(u>0)s=Math.floor(s/u)*u,a=Math.ceil(a/u)*u;else if(u<0)s=Math.ceil(s*u)/u,a=Math.floor(a*u)/u;else break;l=u}return e},e}function Ql(){var e=Xl();return e.copy=function(){return En(e,Ql())},Pe.apply(e,arguments),Ft(e)}function Kl(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,Xr),n):e.slice()},n.unknown=function(i){return arguments.length?(t=i,n):t},n.copy=function(){return Kl(e).unknown(t)},e=arguments.length?Array.from(e,Xr):[0,1],Ft(n)}function Jl(e,t){e=e.slice();var n=0,i=e.length-1,r=e[n],o=e[i],s;return o<r&&(s=n,n=i,i=s,s=r,r=o,o=s),e[n]=t.floor(r),e[i]=t.ceil(o),e}function la(e){return Math.log(e)}function ua(e){return Math.exp(e)}function om(e){return-Math.log(-e)}function sm(e){return-Math.exp(-e)}function am(e){return isFinite(e)?+("1e"+e):e<0?0:e}function lm(e){return e===10?am:e===Math.E?Math.exp:t=>Math.pow(e,t)}function um(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 ca(e){return(t,n)=>-e(-t,n)}function cm(e){const t=e(la,ua),n=t.domain;let i=10,r,o;function s(){return r=um(i),o=lm(i),n()[0]<0?(r=ca(r),o=ca(o),e(om,sm)):e(la,ua),t}return t.base=function(a){return arguments.length?(i=+a,s()):i},t.domain=function(a){return arguments.length?(n(a),s()):n()},t.ticks=a=>{const l=n();let u=l[0],d=l[l.length-1];const f=d<u;f&&([u,d]=[d,u]);let h=r(u),g=r(d),m,p;const v=a==null?10:+a;let _=[];if(!(i%1)&&g-h<v){if(h=Math.floor(h),g=Math.ceil(g),u>0){for(;h<=g;++h)for(m=1;m<i;++m)if(p=h<0?m/o(-h):m*o(h),!(p<u)){if(p>d)break;_.push(p)}}else for(;h<=g;++h)for(m=i-1;m>=1;--m)if(p=h>0?m/o(-h):m*o(h),!(p<u)){if(p>d)break;_.push(p)}_.length*2<v&&(_=Fr(u,d,v))}else _=Fr(h,g,Math.min(g-h,v)).map(o);return f?_.reverse():_},t.tickFormat=(a,l)=>{if(a==null&&(a=10),l==null&&(l=i===10?"s":","),typeof l!="function"&&(!(i%1)&&(l=Tn(l)).precision==null&&(l.trim=!0),l=zo(l)),a===1/0)return l;const u=Math.max(1,i*a/t.ticks().length);return d=>{let f=d/o(Math.round(r(d)));return f*i<i-.5&&(f*=i),f<=u?l(d):""}},t.nice=()=>n(Jl(n(),{floor:a=>o(Math.floor(r(a))),ceil:a=>o(Math.ceil(r(a)))})),t}function eu(){const e=cm(Hi()).domain([1,10]);return e.copy=()=>En(e,eu()).base(e.base()),Pe.apply(e,arguments),e}function da(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function fa(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function dm(e){var t=1,n=e(da(t),fa(t));return n.constant=function(i){return arguments.length?e(da(t=+i),fa(t)):t},Ft(n)}function tu(){var e=dm(Hi());return e.copy=function(){return En(e,tu()).constant(e.constant())},Pe.apply(e,arguments)}function ha(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function fm(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function hm(e){return e<0?-e*e:e*e}function gm(e){var t=e(ve,ve),n=1;function i(){return n===1?e(ve,ve):n===.5?e(fm,hm):e(ha(n),ha(1/n))}return t.exponent=function(r){return arguments.length?(n=+r,i()):n},Ft(t)}function Ho(){var e=gm(Hi());return e.copy=function(){return En(e,Ho()).exponent(e.exponent())},Pe.apply(e,arguments),e}function pm(){return Ho.apply(null,arguments).exponent(.5)}function nu(){var e=[],t=[],n=[],i;function r(){var s=0,a=Math.max(1,t.length);for(n=new Array(a-1);++s<a;)n[s-1]=bf(e,s/a);return o}function o(s){return s==null||isNaN(s=+s)?i:t[Di(n,s)]}return o.invertExtent=function(s){var a=t.indexOf(s);return a<0?[NaN,NaN]:[a>0?n[a-1]:e[0],a<n.length?n[a]:e[e.length-1]]},o.domain=function(s){if(!arguments.length)return e.slice();e=[];for(let a of s)a!=null&&!isNaN(a=+a)&&e.push(a);return e.sort(hn),r()},o.range=function(s){return arguments.length?(t=Array.from(s),r()):t.slice()},o.unknown=function(s){return arguments.length?(i=s,o):i},o.quantiles=function(){return n.slice()},o.copy=function(){return nu().domain(e).range(t).unknown(i)},Pe.apply(o,arguments)}function iu(){var e=0,t=1,n=1,i=[.5],r=[0,1],o;function s(l){return l!=null&&l<=l?r[Di(i,l,0,n)]:o}function a(){var l=-1;for(i=new Array(n);++l<n;)i[l]=((l+1)*t-(l-n)*e)/(n+1);return s}return s.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,a()):[e,t]},s.range=function(l){return arguments.length?(n=(r=Array.from(l)).length-1,a()):r.slice()},s.invertExtent=function(l){var u=r.indexOf(l);return u<0?[NaN,NaN]:u<1?[e,i[0]]:u>=n?[i[n-1],t]:[i[u-1],i[u]]},s.unknown=function(l){return arguments.length&&(o=l),s},s.thresholds=function(){return i.slice()},s.copy=function(){return iu().domain([e,t]).range(r).unknown(o)},Pe.apply(Ft(s),arguments)}function ru(){var e=[.5],t=[0,1],n,i=1;function r(o){return o!=null&&o<=o?t[Di(e,o,0,i)]:n}return r.domain=function(o){return arguments.length?(e=Array.from(o),i=Math.min(e.length,t.length-1),r):e.slice()},r.range=function(o){return arguments.length?(t=Array.from(o),i=Math.min(e.length,t.length-1),r):t.slice()},r.invertExtent=function(o){var s=t.indexOf(o);return[e[s-1],e[s]]},r.unknown=function(o){return arguments.length?(n=o,r):n},r.copy=function(){return ru().domain(e).range(t).unknown(n)},Pe.apply(r,arguments)}const fr=new Date,hr=new Date;function K(e,t,n,i){function r(o){return e(o=arguments.length===0?new Date:new Date(+o)),o}return r.floor=o=>(e(o=new Date(+o)),o),r.ceil=o=>(e(o=new Date(o-1)),t(o,1),e(o),o),r.round=o=>{const s=r(o),a=r.ceil(o);return o-s<a-o?s:a},r.offset=(o,s)=>(t(o=new Date(+o),s==null?1:Math.floor(s)),o),r.range=(o,s,a)=>{const l=[];if(o=r.ceil(o),a=a==null?1:Math.floor(a),!(o<s)||!(a>0))return l;let u;do l.push(u=new Date(+o)),t(o,a),e(o);while(u<o&&o<s);return l},r.filter=o=>K(s=>{if(s>=s)for(;e(s),!o(s);)s.setTime(s-1)},(s,a)=>{if(s>=s)if(a<0)for(;++a<=0;)for(;t(s,-1),!o(s););else for(;--a>=0;)for(;t(s,1),!o(s););}),n&&(r.count=(o,s)=>(fr.setTime(+o),hr.setTime(+s),e(fr),e(hr),Math.floor(n(fr,hr))),r.every=o=>(o=Math.floor(o),!isFinite(o)||!(o>0)?null:o>1?r.filter(i?s=>i(s)%o===0:s=>r.count(0,s)%o===0):r)),r}const Si=K(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);Si.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?K(t=>{t.setTime(Math.floor(t/e)*e)},(t,n)=>{t.setTime(+t+n*e)},(t,n)=>(n-t)/e):Si);Si.range;const Qe=1e3,Me=Qe*60,Ke=Me*60,nt=Ke*24,Go=nt*7,ga=nt*30,gr=nt*365,St=K(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*Qe)},(e,t)=>(t-e)/Qe,e=>e.getUTCSeconds());St.range;const Uo=K(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Qe)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getMinutes());Uo.range;const Wo=K(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Me)},(e,t)=>(t-e)/Me,e=>e.getUTCMinutes());Wo.range;const Yo=K(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*Qe-e.getMinutes()*Me)},(e,t)=>{e.setTime(+e+t*Ke)},(e,t)=>(t-e)/Ke,e=>e.getHours());Yo.range;const qo=K(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Ke)},(e,t)=>(t-e)/Ke,e=>e.getUTCHours());qo.range;const An=K(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Me)/nt,e=>e.getDate()-1);An.range;const Gi=K(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/nt,e=>e.getUTCDate()-1);Gi.range;const ou=K(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/nt,e=>Math.floor(e/nt));ou.range;function Vt(e){return K(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())*Me)/Go)}const Ui=Vt(0),bi=Vt(1),mm=Vt(2),vm=Vt(3),Yt=Vt(4),_m=Vt(5),ym=Vt(6);Ui.range;bi.range;mm.range;vm.range;Yt.range;_m.range;ym.range;function Nt(e){return K(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)/Go)}const Wi=Nt(0),Ci=Nt(1),xm=Nt(2),wm=Nt(3),qt=Nt(4),Sm=Nt(5),bm=Nt(6);Wi.range;Ci.range;xm.range;wm.range;qt.range;Sm.range;bm.range;const Xo=K(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());Xo.range;const jo=K(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());jo.range;const it=K(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());it.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:K(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)});it.range;const rt=K(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());rt.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:K(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)});rt.range;function su(e,t,n,i,r,o){const s=[[St,1,Qe],[St,5,5*Qe],[St,15,15*Qe],[St,30,30*Qe],[o,1,Me],[o,5,5*Me],[o,15,15*Me],[o,30,30*Me],[r,1,Ke],[r,3,3*Ke],[r,6,6*Ke],[r,12,12*Ke],[i,1,nt],[i,2,2*nt],[n,1,Go],[t,1,ga],[t,3,3*ga],[e,1,gr]];function a(u,d,f){const h=d<u;h&&([u,d]=[d,u]);const g=f&&typeof f.range=="function"?f:l(u,d,f),m=g?g.range(u,+d+1):[];return h?m.reverse():m}function l(u,d,f){const h=Math.abs(d-u)/f,g=Ni(([,,v])=>v).right(s,h);if(g===s.length)return e.every(Nr(u/gr,d/gr,f));if(g===0)return Si.every(Math.max(Nr(u,d,f),1));const[m,p]=s[h/s[g-1][2]<s[g][2]/h?g-1:g];return m.every(p)}return[a,l]}const[Cm,km]=su(rt,jo,Wi,ou,qo,Wo),[Tm,Rm]=su(it,Xo,Ui,An,Yo,Uo);function pr(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function mr(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function tn(e,t,n){return{y:e,m:t,d:n,H:0,M:0,S:0,L:0}}function $m(e){var t=e.dateTime,n=e.date,i=e.time,r=e.periods,o=e.days,s=e.shortDays,a=e.months,l=e.shortMonths,u=nn(r),d=rn(r),f=nn(o),h=rn(o),g=nn(s),m=rn(s),p=nn(a),v=rn(a),_=nn(l),y=rn(l),x={a:re,A:fe,b:J,B:Oe,c:null,d:xa,e:xa,f:Qm,g:a0,G:u0,H:Xm,I:jm,j:Zm,L:au,m:Km,M:Jm,p:st,q:qe,Q:ba,s:Ca,S:e0,u:t0,U:n0,V:i0,w:r0,W:o0,x:null,X:null,y:s0,Y:l0,Z:c0,"%":Sa},w={a:at,A:_t,b:he,B:lt,c:null,d:wa,e:wa,f:g0,g:C0,G:T0,H:d0,I:f0,j:h0,L:uu,m:p0,M:m0,p:N,q:ue,Q:ba,s:Ca,S:v0,u:_0,U:y0,V:x0,w:w0,W:S0,x:null,X:null,y:b0,Y:k0,Z:R0,"%":Sa},S={a:U,A:M,b:I,B:T,c:D,d:_a,e:_a,f:Um,g:va,G:ma,H:ya,I:ya,j:Bm,L:Gm,m:Im,M:zm,p:F,q:Lm,Q:Ym,s:qm,S:Hm,u:Vm,U:Nm,V:Dm,w:Fm,W:Pm,x:ie,X:de,y:va,Y:ma,Z:Om,"%":Wm};x.x=b(n,x),x.X=b(i,x),x.c=b(t,x),w.x=b(n,w),w.X=b(i,w),w.c=b(t,w);function b(R,O){return function(B){var k=[],ge=-1,q=0,xe=R.length,we,yt,ps;for(B instanceof Date||(B=new Date(+B));++ge<xe;)R.charCodeAt(ge)===37&&(k.push(R.slice(q,ge)),(yt=pa[we=R.charAt(++ge)])!=null?we=R.charAt(++ge):yt=we==="e"?" ":"0",(ps=O[we])&&(we=ps(B,yt)),k.push(we),q=ge+1);return k.push(R.slice(q,ge)),k.join("")}}function C(R,O){return function(B){var k=tn(1900,void 0,1),ge=V(k,R,B+="",0),q,xe;if(ge!=B.length)return null;if("Q"in k)return new Date(k.Q);if("s"in k)return new Date(k.s*1e3+("L"in k?k.L:0));if(O&&!("Z"in k)&&(k.Z=0),"p"in k&&(k.H=k.H%12+k.p*12),k.m===void 0&&(k.m="q"in k?k.q:0),"V"in k){if(k.V<1||k.V>53)return null;"w"in k||(k.w=1),"Z"in k?(q=mr(tn(k.y,0,1)),xe=q.getUTCDay(),q=xe>4||xe===0?Ci.ceil(q):Ci(q),q=Gi.offset(q,(k.V-1)*7),k.y=q.getUTCFullYear(),k.m=q.getUTCMonth(),k.d=q.getUTCDate()+(k.w+6)%7):(q=pr(tn(k.y,0,1)),xe=q.getDay(),q=xe>4||xe===0?bi.ceil(q):bi(q),q=An.offset(q,(k.V-1)*7),k.y=q.getFullYear(),k.m=q.getMonth(),k.d=q.getDate()+(k.w+6)%7)}else("W"in k||"U"in k)&&("w"in k||(k.w="u"in k?k.u%7:"W"in k?1:0),xe="Z"in k?mr(tn(k.y,0,1)).getUTCDay():pr(tn(k.y,0,1)).getDay(),k.m=0,k.d="W"in k?(k.w+6)%7+k.W*7-(xe+5)%7:k.w+k.U*7-(xe+6)%7);return"Z"in k?(k.H+=k.Z/100|0,k.M+=k.Z%100,mr(k)):pr(k)}}function V(R,O,B,k){for(var ge=0,q=O.length,xe=B.length,we,yt;ge<q;){if(k>=xe)return-1;if(we=O.charCodeAt(ge++),we===37){if(we=O.charAt(ge++),yt=S[we in pa?O.charAt(ge++):we],!yt||(k=yt(R,B,k))<0)return-1}else if(we!=B.charCodeAt(k++))return-1}return k}function F(R,O,B){var k=u.exec(O.slice(B));return k?(R.p=d.get(k[0].toLowerCase()),B+k[0].length):-1}function U(R,O,B){var k=g.exec(O.slice(B));return k?(R.w=m.get(k[0].toLowerCase()),B+k[0].length):-1}function M(R,O,B){var k=f.exec(O.slice(B));return k?(R.w=h.get(k[0].toLowerCase()),B+k[0].length):-1}function I(R,O,B){var k=_.exec(O.slice(B));return k?(R.m=y.get(k[0].toLowerCase()),B+k[0].length):-1}function T(R,O,B){var k=p.exec(O.slice(B));return k?(R.m=v.get(k[0].toLowerCase()),B+k[0].length):-1}function D(R,O,B){return V(R,t,O,B)}function ie(R,O,B){return V(R,n,O,B)}function de(R,O,B){return V(R,i,O,B)}function re(R){return s[R.getDay()]}function fe(R){return o[R.getDay()]}function J(R){return l[R.getMonth()]}function Oe(R){return a[R.getMonth()]}function st(R){return r[+(R.getHours()>=12)]}function qe(R){return 1+~~(R.getMonth()/3)}function at(R){return s[R.getUTCDay()]}function _t(R){return o[R.getUTCDay()]}function he(R){return l[R.getUTCMonth()]}function lt(R){return a[R.getUTCMonth()]}function N(R){return r[+(R.getUTCHours()>=12)]}function ue(R){return 1+~~(R.getUTCMonth()/3)}return{format:function(R){var O=b(R+="",x);return O.toString=function(){return R},O},parse:function(R){var O=C(R+="",!1);return O.toString=function(){return R},O},utcFormat:function(R){var O=b(R+="",w);return O.toString=function(){return R},O},utcParse:function(R){var O=C(R+="",!0);return O.toString=function(){return R},O}}}var pa={"-":"",_:" ",0:"0"},ee=/^\s*\d+/,Mm=/^%/,Em=/[\\^$*+?|[\]().{}]/g;function z(e,t,n){var i=e<0?"-":"",r=(i?-e:e)+"",o=r.length;return i+(o<n?new Array(n-o+1).join(t)+r:r)}function Am(e){return e.replace(Em,"\\$&")}function nn(e){return new RegExp("^(?:"+e.map(Am).join("|")+")","i")}function rn(e){return new Map(e.map((t,n)=>[t.toLowerCase(),n]))}function Fm(e,t,n){var i=ee.exec(t.slice(n,n+1));return i?(e.w=+i[0],n+i[0].length):-1}function Vm(e,t,n){var i=ee.exec(t.slice(n,n+1));return i?(e.u=+i[0],n+i[0].length):-1}function Nm(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.U=+i[0],n+i[0].length):-1}function Dm(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.V=+i[0],n+i[0].length):-1}function Pm(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.W=+i[0],n+i[0].length):-1}function ma(e,t,n){var i=ee.exec(t.slice(n,n+4));return i?(e.y=+i[0],n+i[0].length):-1}function va(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.y=+i[0]+(+i[0]>68?1900:2e3),n+i[0].length):-1}function Om(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 Lm(e,t,n){var i=ee.exec(t.slice(n,n+1));return i?(e.q=i[0]*3-3,n+i[0].length):-1}function Im(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.m=i[0]-1,n+i[0].length):-1}function _a(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.d=+i[0],n+i[0].length):-1}function Bm(e,t,n){var i=ee.exec(t.slice(n,n+3));return i?(e.m=0,e.d=+i[0],n+i[0].length):-1}function ya(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.H=+i[0],n+i[0].length):-1}function zm(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.M=+i[0],n+i[0].length):-1}function Hm(e,t,n){var i=ee.exec(t.slice(n,n+2));return i?(e.S=+i[0],n+i[0].length):-1}function Gm(e,t,n){var i=ee.exec(t.slice(n,n+3));return i?(e.L=+i[0],n+i[0].length):-1}function Um(e,t,n){var i=ee.exec(t.slice(n,n+6));return i?(e.L=Math.floor(i[0]/1e3),n+i[0].length):-1}function Wm(e,t,n){var i=Mm.exec(t.slice(n,n+1));return i?n+i[0].length:-1}function Ym(e,t,n){var i=ee.exec(t.slice(n));return i?(e.Q=+i[0],n+i[0].length):-1}function qm(e,t,n){var i=ee.exec(t.slice(n));return i?(e.s=+i[0],n+i[0].length):-1}function xa(e,t){return z(e.getDate(),t,2)}function Xm(e,t){return z(e.getHours(),t,2)}function jm(e,t){return z(e.getHours()%12||12,t,2)}function Zm(e,t){return z(1+An.count(it(e),e),t,3)}function au(e,t){return z(e.getMilliseconds(),t,3)}function Qm(e,t){return au(e,t)+"000"}function Km(e,t){return z(e.getMonth()+1,t,2)}function Jm(e,t){return z(e.getMinutes(),t,2)}function e0(e,t){return z(e.getSeconds(),t,2)}function t0(e){var t=e.getDay();return t===0?7:t}function n0(e,t){return z(Ui.count(it(e)-1,e),t,2)}function lu(e){var t=e.getDay();return t>=4||t===0?Yt(e):Yt.ceil(e)}function i0(e,t){return e=lu(e),z(Yt.count(it(e),e)+(it(e).getDay()===4),t,2)}function r0(e){return e.getDay()}function o0(e,t){return z(bi.count(it(e)-1,e),t,2)}function s0(e,t){return z(e.getFullYear()%100,t,2)}function a0(e,t){return e=lu(e),z(e.getFullYear()%100,t,2)}function l0(e,t){return z(e.getFullYear()%1e4,t,4)}function u0(e,t){var n=e.getDay();return e=n>=4||n===0?Yt(e):Yt.ceil(e),z(e.getFullYear()%1e4,t,4)}function c0(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+z(t/60|0,"0",2)+z(t%60,"0",2)}function wa(e,t){return z(e.getUTCDate(),t,2)}function d0(e,t){return z(e.getUTCHours(),t,2)}function f0(e,t){return z(e.getUTCHours()%12||12,t,2)}function h0(e,t){return z(1+Gi.count(rt(e),e),t,3)}function uu(e,t){return z(e.getUTCMilliseconds(),t,3)}function g0(e,t){return uu(e,t)+"000"}function p0(e,t){return z(e.getUTCMonth()+1,t,2)}function m0(e,t){return z(e.getUTCMinutes(),t,2)}function v0(e,t){return z(e.getUTCSeconds(),t,2)}function _0(e){var t=e.getUTCDay();return t===0?7:t}function y0(e,t){return z(Wi.count(rt(e)-1,e),t,2)}function cu(e){var t=e.getUTCDay();return t>=4||t===0?qt(e):qt.ceil(e)}function x0(e,t){return e=cu(e),z(qt.count(rt(e),e)+(rt(e).getUTCDay()===4),t,2)}function w0(e){return e.getUTCDay()}function S0(e,t){return z(Ci.count(rt(e)-1,e),t,2)}function b0(e,t){return z(e.getUTCFullYear()%100,t,2)}function C0(e,t){return e=cu(e),z(e.getUTCFullYear()%100,t,2)}function k0(e,t){return z(e.getUTCFullYear()%1e4,t,4)}function T0(e,t){var n=e.getUTCDay();return e=n>=4||n===0?qt(e):qt.ceil(e),z(e.getUTCFullYear()%1e4,t,4)}function R0(){return"+0000"}function Sa(){return"%"}function ba(e){return+e}function Ca(e){return Math.floor(+e/1e3)}var Dt,du,fu;$0({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 $0(e){return Dt=$m(e),du=Dt.format,Dt.parse,fu=Dt.utcFormat,Dt.utcParse,Dt}function M0(e){return new Date(e)}function E0(e){return e instanceof Date?+e:+new Date(+e)}function Zo(e,t,n,i,r,o,s,a,l,u){var d=Xl(),f=d.invert,h=d.domain,g=u(".%L"),m=u(":%S"),p=u("%I:%M"),v=u("%I %p"),_=u("%a %d"),y=u("%b %d"),x=u("%B"),w=u("%Y");function S(b){return(l(b)<b?g:a(b)<b?m:s(b)<b?p:o(b)<b?v:i(b)<b?r(b)<b?_:y:n(b)<b?x:w)(b)}return d.invert=function(b){return new Date(f(b))},d.domain=function(b){return arguments.length?h(Array.from(b,E0)):h().map(M0)},d.ticks=function(b){var C=h();return e(C[0],C[C.length-1],b??10)},d.tickFormat=function(b,C){return C==null?S:u(C)},d.nice=function(b){var C=h();return(!b||typeof b.range!="function")&&(b=t(C[0],C[C.length-1],b??10)),b?h(Jl(C,b)):d},d.copy=function(){return En(d,Zo(e,t,n,i,r,o,s,a,l,u))},d}function A0(){return Pe.apply(Zo(Tm,Rm,it,Xo,Ui,An,Yo,Uo,St,du).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function F0(){return Pe.apply(Zo(Cm,km,rt,jo,Wi,Gi,qo,Wo,St,fu).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function V0(){var e=0,t=1,n,i,r,o,s=ve,a=!1,l;function u(f){return f==null||isNaN(f=+f)?l:s(r===0?.5:(f=(o(f)-n)*r,a?Math.max(0,Math.min(1,f)):f))}u.domain=function(f){return arguments.length?([e,t]=f,n=o(e=+e),i=o(t=+t),r=n===i?0:1/(i-n),u):[e,t]},u.clamp=function(f){return arguments.length?(a=!!f,u):a},u.interpolator=function(f){return arguments.length?(s=f,u):s};function d(f){return function(h){var g,m;return arguments.length?([g,m]=h,s=f(g,m),u):[s(0),s(1)]}}return u.range=d(At),u.rangeRound=d(Po),u.unknown=function(f){return arguments.length?(l=f,u):l},function(f){return o=f,n=f(e),i=f(t),r=n===i?0:1/(i-n),u}}function hu(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function gu(){var e=Ft(V0()(ve));return e.copy=function(){return hu(e,gu())},Yl.apply(e,arguments)}function N0(){var e=0,t=.5,n=1,i=1,r,o,s,a,l,u=ve,d,f=!1,h;function g(p){return isNaN(p=+p)?h:(p=.5+((p=+d(p))-o)*(i*p<i*o?a:l),u(f?Math.max(0,Math.min(1,p)):p))}g.domain=function(p){return arguments.length?([e,t,n]=p,r=d(e=+e),o=d(t=+t),s=d(n=+n),a=r===o?0:.5/(o-r),l=o===s?0:.5/(s-o),i=o<r?-1:1,g):[e,t,n]},g.clamp=function(p){return arguments.length?(f=!!p,g):f},g.interpolator=function(p){return arguments.length?(u=p,g):u};function m(p){return function(v){var _,y,x;return arguments.length?([_,y,x]=v,u=Pg(p,[_,y,x]),g):[u(0),u(.5),u(1)]}}return g.range=m(At),g.rangeRound=m(Po),g.unknown=function(p){return arguments.length?(h=p,g):h},function(p){return d=p,r=p(e),o=p(t),s=p(n),a=r===o?0:.5/(o-r),l=o===s?0:.5/(s-o),i=o<r?-1:1,g}}function pu(){var e=Ft(N0()(ve));return e.copy=function(){return hu(e,pu())},Yl.apply(e,arguments)}const ka={scaleLinear:Ql,scalePow:Ho,scaleSqrt:pm,scaleLog:eu,scaleSymlog:tu,scaleIdentity:Kl,scaleTime:A0,scaleUtc:F0,scaleSequential:gu,scaleDiverging:pu,scaleQuantize:iu,scaleQuantile:nu,scaleThreshold:ru,scaleOrdinal:Io,scaleBand:zi,scalePoint:Hp};var j;(function(e){e.X="x",e.Y="y"})(j||(j={}));var Ve;(function(e){e.West="west",e.East="east",e.North="north",e.South="south"})(Ve||(Ve={}));const D0=Object.assign(Object.assign({},To),{components:[],tooltip:void 0,crosshair:void 0,annotations:void 0,xAxis:void 0,yAxis:void 0,autoMargin:!0,xScale:void 0,xDomain:void 0,xDomainMinConstraint:void 0,xDomainMaxConstraint:void 0,xRange:void 0,yScale:void 0,yDomain:void 0,yDomainMinConstraint:void 0,yDomainMaxConstraint:void 0,yRange:void 0,yDirection:Ve.North,preventEmptyDomain:null,scaleByDomain:!1});class P0 extends Ht{constructor(t,n,i){var r,o;super(t),this._defaultConfig=D0,this.datamodel=new Lo,this.config=this._defaultConfig,this._clipPathId=$l(),this._axisMargin={top:0,bottom:0,left:0,right:0},this._firstRender=!0,this._clipPath=this.svg.append("clipPath").attr("id",this._clipPathId),this._clipPath.append("rect");const s="saturate",a=window.location.href.replace(window.location.hash,"");this.svg.attr("class",P`
|
|
53
|
-
--highlight-filter-id: url(${a}#${s}); // defining a css variable
|
|
54
|
-
`),this._svgDefs.append("filter").attr("id",s).attr("filterUnits","objectBoundingBox").html('<feColorMatrix type="saturate" in="SourceGraphic" values="1.35"/>'),n&&this.updateContainer(n,!0),i&&this.setData(i,!0),(this.config.xAxis||this.config.yAxis||!((r=this.components)===null||r===void 0)&&r.some(l=>l.datamodel.data))&&this.render(),(o=document.fonts)===null||o===void 0||o.ready.then(()=>{this._firstRender||this._renderAxes(0)})}get components(){return this.config.components}get width(){const t=this._getMargin();return He(this.containerWidth-t.left-t.right,0,Number.POSITIVE_INFINITY)}get height(){const t=this._getMargin();return He(this.containerHeight-t.top-t.bottom,0,Number.POSITIVE_INFINITY)}setData(t,n){var i,r,o,s;const{components:a,config:l}=this;t&&(this.datamodel.data=t,a.forEach(u=>{u.setData(t)}),(i=l.crosshair)===null||i===void 0||i.setData(t),(r=l.xAxis)===null||r===void 0||r.setData(t),(o=l.yAxis)===null||o===void 0||o.setData(t),(s=l.tooltip)===null||s===void 0||s.hide(),n||this.render())}updateContainer(t,n){super.updateContainer(t),this._removeAllChildren(),this.setData(this.datamodel.data,!0),t.xAxis&&(this.config.xAxis.config.type=W.X,this.element.appendChild(t.xAxis.element)),t.yAxis&&(this.config.yAxis.config.type=W.Y,this.element.appendChild(t.yAxis.element));for(const s of this.components)this.element.appendChild(s.element);const i=t.tooltip;i&&(i.hasContainer()||i.setContainer(this._container),i.setComponents(this.components));const r=t.crosshair;r&&(r.setContainer(this.svg),r.tooltip=i,this.element.appendChild(r.element));const o=t.annotations;o&&this.element.appendChild(o.element),this.element.appendChild(this._clipPath.node()),this.element.appendChild(this._svgDefs.node()),this.element.appendChild(this._svgDefsExternal.node()),n||this.render()}updateComponents(t,n){const{config:i}=this;this.components.forEach((r,o)=>{t[o]&&r.setConfig(t[o])}),this._updateScales(...this.components,i.xAxis,i.yAxis,i.crosshair),n||this.render()}update(t,n,i){i&&(this.datamodel.data=i),t&&this.updateContainer(t,!0),n&&this.updateComponents(n,!0),this.render()}_preRender(){const{config:t}=this;super._preRender(),t.autoMargin&&this._setAutoMargin();const n=Kt([...this.components,t.xAxis,t.yAxis,t.crosshair,t.annotations]);for(const i of n)i.setSize(this.width,this.height,this.containerWidth,this.containerHeight);this._updateScales(...this.components,t.xAxis,t.yAxis,t.crosshair)}_render(t){var n,i,r,o,s;const{config:a}=this;super._render();const l=this._getMargin();for(const f of this.components)f.g.attr("transform",`translate(${l.left},${l.top})`).style("clip-path",f.clippable?`url(#${this._clipPathId})`:null).style("-webkit-clip-path",f.clippable?`url(#${this._clipPathId})`:null),f.render(t);this._renderAxes(this._firstRender?0:t);const u=2;this._clipPath.select("rect").attr("x",-2).attr("y",-2).attr("width",this.width+2*u).attr("height",this.height+2*u),(n=a.tooltip)===null||n===void 0||n.update();const d=a.crosshair;if(d){const f=this.components.filter(p=>!p.stacked).map(p=>p.config.y),h=this.components.filter(p=>p.stacked).map(p=>p.config.y),g=(i=this.components.find(p=>p.config.baseline))===null||i===void 0?void 0:i.config,m=g==null?void 0:g.baseline;d.accessors={x:(r=this.components[0])===null||r===void 0?void 0:r.config.x,y:Pr(f),yStacked:Pr(h),baseline:m},d.g.attr("transform",`translate(${l.left},${l.top})`).style("clip-path",`url(#${this._clipPathId})`).style("-webkit-clip-path",`url(#${this._clipPathId})`),d.hide()}(o=a.annotations)===null||o===void 0||o.g.attr("transform",`translate(${l.left},${l.top})`),(s=a.annotations)===null||s===void 0||s.render(),this._firstRender=!1}_updateScales(...t){const n=Kt(t||this.components);this._setScales(...n),this._updateScalesDomain(...n),this._updateScalesRange(...n)}_setScales(...t){const{config:n}=this;t&&(n.xScale&&t.forEach(i=>i.setScale(j.X,n.xScale)),n.yScale&&t.forEach(i=>i.setScale(j.Y,n.yScale)))}_updateScalesDomain(...t){const{config:n}=this;if(!t)return;const i=t.filter(r=>!r.config.excludeFromDomainCalculation);Object.values(j).forEach(r=>{var o,s,a,l,u,d,f,h;const[g,m]=mf(Tf(i.map(S=>S.getDataExtent(r,n.scaleByDomain)))),p=r===j.Y?n.yDomain:n.xDomain,v=r===j.Y?n.yDomainMinConstraint:n.xDomainMinConstraint,_=r===j.Y?n.yDomainMaxConstraint:n.xDomainMaxConstraint,y=(s=(o=p==null?void 0:p[0])!==null&&o!==void 0?o:g)!==null&&s!==void 0?s:0,x=(l=(a=p==null?void 0:p[1])!==null&&a!==void 0?a:m)!==null&&l!==void 0?l:1,w=[He(y,(u=v==null?void 0:v[0])!==null&&u!==void 0?u:Number.NEGATIVE_INFINITY,(d=v==null?void 0:v[1])!==null&&d!==void 0?d:Number.POSITIVE_INFINITY),He(x,(f=_==null?void 0:_[0])!==null&&f!==void 0?f:Number.NEGATIVE_INFINITY,(h=_==null?void 0:_[1])!==null&&h!==void 0?h:Number.POSITIVE_INFINITY)];if(w[0]===w[1]){const S=i.some(b=>{var C;return((C=b.datamodel.data)===null||C===void 0?void 0:C.length)>0});(n.preventEmptyDomain||n.preventEmptyDomain===null&&(!S||r===j.Y))&&(w[1]=w[0]+1)}t.forEach(S=>S.setScaleDomain(r,w))})}_updateScalesRange(...t){var n,i,r,o,s,a;const{config:l}=this;if(!t)return;const u=l.yDirection===Ve.South,d=[(n=l.padding.left)!==null&&n!==void 0?n:0,this.width-((i=l.padding.right)!==null&&i!==void 0?i:0)],f=[this.height-((r=l.padding.bottom)!==null&&r!==void 0?r:0),(o=l.padding.top)!==null&&o!==void 0?o:0];u&&f.reverse();for(const g of t)g.setSize(this.width,this.height,this.containerWidth,this.containerHeight),g.setScaleRange(j.X,(s=l.xRange)!==null&&s!==void 0?s:d),g.setScaleRange(j.Y,(a=l.yRange)!==null&&a!==void 0?a:f);const h=t.map(g=>g.bleed).reduce((g,m)=>{for(const p of Object.keys(g)){const v=p;g[v]<m[v]&&(g[v]=m[v])}return g},{top:0,bottom:0,left:0,right:0});for(const g of t)g.setScaleRange(j.X,[d[0]+h.left,d[1]-h.right]),g.setScaleRange(j.Y,u?[f[0]+h.top,f[1]-h.bottom]:[f[0]-h.bottom,f[1]+h.top])}_renderAxes(t){const{config:{xAxis:n,yAxis:i}}=this,r=this._getMargin();Kt([n,i]).forEach(s=>{const a=s.getOffset(r);s.g.attr("transform",`translate(${a.left},${a.top})`),s.render(t)})}_setAutoMargin(){const{config:{xAxis:t,yAxis:n}}=this,i=Kt([...this.components,t,n]);this._setScales(...i),this._updateScalesDomain(...i);const r=this._firstRender?2:1;for(let o=0;o<r;o+=1){const s={top:0,bottom:0,left:0,right:0};this._updateScalesRange(...i),Kt([t,n]).forEach(l=>{l.preRender();const u=l.getRequiredMargin();s.top<u.top&&(s.top=u.top),s.bottom<u.bottom&&(s.bottom=u.bottom),s.left<u.left&&(s.left=u.left),s.right<u.right&&(s.right=u.right)}),this._axisMargin=s}}_getMargin(){const{config:{margin:t}}=this;return{top:t.top+this._axisMargin.top,bottom:t.bottom+this._axisMargin.bottom,left:t.left+this._axisMargin.left,right:t.right+this._axisMargin.right}}destroy(){const{components:t,config:{tooltip:n,crosshair:i,annotations:r,xAxis:o,yAxis:s}}=this;super.destroy();for(const a of t)a==null||a.destroy();n==null||n.destroy(),i==null||i.destroy(),r==null||r.destroy(),o==null||o.destroy(),s==null||s.destroy()}}const Qo={duration:600,events:{},attributes:{}};class mu{constructor(t=fn.SVG){var n,i;this.type=fn.SVG,this.datamodel=new Lo,this.sizing=Je.Fit,this.events={},this._defaultConfig=Qo,this._width=400,this._height=200,this._containerWidth=void 0,this._containerHeight=void 0,this._setUpComponentEventsThrottled=fi(this._setUpComponentEvents,500),this._setCustomAttributesThrottled=fi(this._setCustomAttributes,500),t===fn.SVG?this.element=document.createElementNS("http://www.w3.org/2000/svg","g"):this.element=document.createElement("div"),this.uid=$l(),this.g=ce(this.element);const r=(i=(n=this.constructor)===null||n===void 0?void 0:n.selectors)===null||i===void 0?void 0:i.root;r&&this.g.attr("class",r)}setConfig(t){this.prevConfig=this.config,this.config=$t(this._defaultConfig,t)}setData(t){this.datamodel.data=t}setSize(t,n,i,r){isFinite(t)&&(this._width=t),isFinite(n)&&(this._height=n),isFinite(i)&&(this._containerWidth=i),isFinite(r)&&(this._containerHeight=r)}render(t=this.config.duration){this._render(t);const n="animating";t&&(this.g.attr(n,""),this.g.transition(n).duration(t).on("end interrupt",()=>{this.g.attr(n,null)})),this._setUpComponentEventsThrottled(),this._setCustomAttributesThrottled()}get bleed(){return{top:0,bottom:0,left:0,right:0}}_render(t=this.config.duration){}_setCustomAttributes(){const t=this.config.attributes;Object.keys(t).forEach(n=>{Object.keys(t[n]).forEach(i=>{this.g.selectAll(`.${n}`).attr(i,t[n][i])})})}_setUpComponentEvents(){this._bindEvents(this.events),this._bindEvents(this.config.events,".user")}_bindEvents(t=this.events,n=""){Object.keys(t).forEach(i=>{Object.keys(t[i]).forEach(r=>{const o=this.g.selectAll(`.${i}`);o.on(r+n,(s,a)=>{const l=o.nodes(),u=l.indexOf(s.currentTarget),d=t[i][r];return d==null?void 0:d(a,s,u,l)})})})}destroy(){var t;(t=this.g)===null||t===void 0||t.remove(),this.element=void 0}isDestroyed(){return!this.element}}class vu extends Lo{constructor(t){super(t)}get data(){var t;return(t=this._data)!==null&&t!==void 0?t:[]}set data(t){Array.isArray(t)&&(this._data=t)}}const Zt=Object.assign(Object.assign({},Qo),{x:void 0,y:void 0,id:(e,t)=>{var n;return(n=e.id)!==null&&n!==void 0?n:`${t}`},color:e=>e.color,xScale:void 0,yScale:void 0,excludeFromDomainCalculation:!1});class Fn extends mu{constructor(){super(...arguments),this.datamodel=new vu,this.clippable=!0,this.stacked=!1,this._defaultConfig=Zt,this._xScale=ka.scaleLinear(),this._yScale=ka.scaleLinear()}get xScale(){return this.config.xScale||this._xScale}get yScale(){return this.config.yScale||this._yScale}setConfig(t){var n,i;!((n=this.config)===null||n===void 0)&&n.xScale&&(t.xScale=this.config.xScale),!((i=this.config)===null||i===void 0)&&i.yScale&&(t.yScale=this.config.yScale),super.setConfig(t)}setScaleDomain(t,n){var i,r;t===j.X&&((i=this._xScale)===null||i===void 0||i.domain(n)),t===j.Y&&((r=this._yScale)===null||r===void 0||r.domain(n))}setScaleRange(t,n){var i,r;t===j.X&&((i=this._xScale)===null||i===void 0||i.range(n)),t===j.Y&&((r=this._yScale)===null||r===void 0||r.range(n))}setScale(t,n){n&&t===j.X&&(this._xScale=n),n&&t===j.Y&&(this._yScale=n)}getDataExtent(t,n){const{config:i,datamodel:r}=this;switch(t){case j.X:return this.getXDataExtent();case j.Y:return this.getYDataExtent(n);default:return Yn(r.data,i[t])}}getXDataExtent(){const{config:t,datamodel:n}=this;return Yn(n.data,t.x)}getYDataExtent(t){const{config:n,datamodel:i}=this,r=t?dl(i.data,this.xScale.domain(),n.x):i.data,o=et(n.y)?n.y:[n.y];return Yn(r,...o)}}var $;(function(e){e.Top="top",e.Bottom="bottom",e.Left="left",e.Right="right",e.Center="center",e.Auto="auto"})($||($={}));var Ta;(function(e){e.Absolute="absolute",e.Fixed="fixed"})(Ta||(Ta={}));var Ra;(function(e){e.Inside="inside",e.Outside="outside"})(Ra||(Ra={}));var ki;(function(e){e.Horizontal="horizontal",e.Vertical="vertical"})(ki||(ki={}));const O0={components:[],container:void 0,followCursor:!0,allowHover:!0,horizontalPlacement:$.Auto,horizontalShift:0,verticalPlacement:$.Top,verticalShift:0,attributes:{},triggers:{},className:void 0},Yi=P`
|
|
55
|
-
label: tooltip;
|
|
56
|
-
display: inline-block;
|
|
57
|
-
left: 0;
|
|
58
|
-
bottom: 0;
|
|
59
|
-
min-width: max-content;
|
|
60
|
-
position: absolute;
|
|
61
|
-
opacity: 0;
|
|
62
|
-
transition: opacity;
|
|
63
|
-
transition-duration: var(--vis-tooltip-transition-duration);
|
|
64
|
-
z-index: 999999;
|
|
65
|
-
padding: var(--vis-tooltip-padding);
|
|
66
|
-
color: var(--vis-tooltip-text-color);
|
|
67
|
-
border-radius: var(--vis-tooltip-border-radius);
|
|
68
|
-
box-shadow: var(--vis-tooltip-box-shadow);
|
|
69
|
-
border: solid 1px var(--vis-tooltip-border-color);
|
|
70
|
-
background-color: var(--vis-tooltip-background-color);
|
|
71
|
-
backdrop-filter: var(--vis-tooltip-backdrop-filter);
|
|
72
|
-
`,L0=Yi,I0=ot`
|
|
73
|
-
:root {
|
|
74
|
-
--vis-tooltip-background-color: rgba(255, 255, 255, 0.95);
|
|
75
|
-
--vis-tooltip-border-color: #e5e9f7;
|
|
76
|
-
--vis-tooltip-text-color: #000;
|
|
77
|
-
--vis-tooltip-shadow-color: rgba(172, 179, 184, 0.35);
|
|
78
|
-
--vis-tooltip-backdrop-filter: none;
|
|
79
|
-
--vis-tooltip-padding: 10px 15px;
|
|
80
|
-
--vis-tooltip-border-radius: 5px;
|
|
81
|
-
--vis-tooltip-transition-duration: 300ms;
|
|
82
|
-
--vis-tooltip-box-shadow: none;
|
|
83
|
-
|
|
84
|
-
--vis-dark-tooltip-background-color: rgba(30,30,30, 0.95);
|
|
85
|
-
--vis-dark-tooltip-text-color: #e5e9f7;
|
|
86
|
-
--vis-dark-tooltip-border-color: var(--vis-color-grey);
|
|
87
|
-
--vis-dark-tooltip-shadow-color: rgba(0,0,0, 0.95);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
body.theme-dark ${`.${Yi}`} {
|
|
91
|
-
--vis-tooltip-background-color: var(--vis-dark-tooltip-background-color);
|
|
92
|
-
--vis-tooltip-text-color: var(--vis-dark-tooltip-text-color);
|
|
93
|
-
--vis-tooltip-border-color: var(--vis-dark-tooltip-border-color);
|
|
94
|
-
--vis-tooltip-shadow-color: var(--vis-dark-tooltip-shadow-color);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
body.theme-dark {
|
|
98
|
-
--vis-tooltip-background-color: rgba(30,30,30, 0.95);
|
|
99
|
-
--vis-tooltip-text-color: #e5e9f7;
|
|
100
|
-
--vis-tooltip-border-color: var(--vis-color-grey);
|
|
101
|
-
--vis-tooltip-shadow-color: rgba(0,0,0, 0.95);
|
|
102
|
-
}
|
|
103
|
-
`,_u=P`
|
|
104
|
-
bottom: unset;
|
|
105
|
-
position: fixed;
|
|
106
|
-
`,Zr=P`
|
|
107
|
-
opacity: 1;
|
|
108
|
-
`,Qr=P`
|
|
109
|
-
display: none;
|
|
110
|
-
`,yu=P`
|
|
111
|
-
label: non-interactive;
|
|
112
|
-
pointer-events: none;
|
|
113
|
-
user-select: none;
|
|
114
|
-
`,B0=Object.freeze(Object.defineProperty({__proto__:null,hidden:Qr,nonInteractive:yu,positionFixed:_u,root:Yi,show:Zr,tooltip:L0,variables:I0},Symbol.toStringTag,{value:"Module"}));class xu{constructor(t={}){this._defaultConfig=O0,this.config=this._defaultConfig,this._setUpEventsThrottled=fi(this._setUpEvents,500),this._setContainerPositionThrottled=fi(this._setContainerPosition,500),this._isShown=!1,this.element=document.createElement("div"),this.div=ce(this.element).attr("class",Yi),this.setConfig(t),this.components=this.config.components,this._mutationObserver=new MutationObserver(()=>{this._isShown&&(!this.config.followCursor&&this._hoveredElement?this.placeByElement(this._hoveredElement):this._position&&this.place({x:this._position[0],y:this._position[1]}))}),this._mutationObserver.observe(this.div.node(),{childList:!0,subtree:!0})}setConfig(t){var n;this.prevConfig=this.config,this.config=$t(this._defaultConfig,t),this.prevConfig.horizontalPlacement!==this.config.horizontalPlacement&&this.overrideHorizontalPlacement(void 0),this.config.container&&this.config.container!==((n=this.prevConfig)===null||n===void 0?void 0:n.container)&&this.setContainer(this.config.container),this._setUpAttributes()}setContainer(t){var n;(n=this.element.parentNode)===null||n===void 0||n.removeChild(this.element),this._container=t,this._container.appendChild(this.element),this._setContainerPositionThrottled()}getContainer(){return this._container}hasContainer(){return!!this._container&&this._container.isConnected}setComponents(t){this.components=t}update(){this._container&&this._setUpEventsThrottled()}show(t,n){this.render(t),this.place(n)}hide(){this.div.classed(Zr,!1).on("transitionend",()=>{this.div.classed(Qr,!this._isShown)}),this._isShown=!1}display(){this.div.classed(Qr,!1).classed(Zr,!0),this._isShown=!0}place(t){if(this._position=[t.x,t.y],!this.hasContainer()){console.warn("Unovis | Tooltip: Container was not set or is not initialized yet");return}const{config:n}=this,i=this.element.offsetWidth,r=this.element.offsetHeight,o=this._overriddenHorizontalPlacement||(n.horizontalPlacement===$.Auto?$.Center:n.horizontalPlacement),s=n.verticalPlacement===$.Auto?t.y-r<0?$.Bottom:$.Top:n.verticalPlacement,a=5,l=o===$.Left?-i-a-n.horizontalShift:o===$.Center?-i/2:a+n.horizontalShift,u=s===$.Bottom?a+n.verticalShift:s===$.Center?-r/2:-5-n.verticalShift-r,[d,f]=this._constraintPosToContainer(t.x+l,t.y+u,i,r);this._applyPosition(d,f,r)}placeByElement(t){const{config:n}=this;this._hoveredElement=t;const i=5,r=this.element.offsetWidth,o=this.element.offsetHeight,s=this.isContainerBody(),a=s?window.innerWidth:this._container.scrollWidth,l=t.getBoundingClientRect(),u=s?[l.x,l.y]:li({clientX:l.x,clientY:l.y,pageX:l.x,pageY:l.y},this._container),d=this._overriddenHorizontalPlacement||(n.horizontalPlacement===$.Auto?u[0]-r<0?$.Right:u[0]+r>a?$.Left:$.Center:n.horizontalPlacement);let f=0;switch(d){case $.Left:f=-r-i-n.horizontalShift;break;case $.Right:f=l.width+i+n.horizontalShift;break;case $.Center:default:f=(-r+l.width)/2;break}const h=n.verticalPlacement===$.Auto?d!==$.Center?$.Center:u[1]-o<0?$.Bottom:$.Top:n.verticalPlacement;let g=-o;switch(h){case $.Center:g+=(o+l.height)/2;break;case $.Bottom:g+=o+l.height+i+n.verticalShift;break;case $.Top:default:g+=-5-n.verticalShift;break}const[m,p]=this._constraintPosToContainer(u[0]+f,u[1]+g,r,o);this._applyPosition(m,p,o)}isContainerBody(){return this._container===document.body}overrideHorizontalPlacement(t){this._overriddenHorizontalPlacement=t}render(t){var n;const{config:i,prevConfig:r}=this;t instanceof HTMLElement?this.div.select(":first-child").node()!==t&&this.div.html("").append(()=>t):t&&this.div.html(t),this.div.classed((n=i.className)!==null&&n!==void 0?n:"",!!i.className).classed(yu,!i.allowHover||i.followCursor),r!=null&&r.className&&r.className!==i.className&&this.div.classed(r.className,!1),this.display()}_applyPosition(t,n,i){const r=this.isContainerBody(),o=r?window.innerHeight:this._container.scrollHeight;this.div.classed(_u,r).style("top",r?`${n}px`:"unset").style("bottom",r?"unset":`${o-n-i}px`).style("left",`${t}px`)}_constraintPosToContainer(t,n,i,r){const o=this.isContainerBody(),s=o?window.innerHeight:this._container.scrollHeight,a=o?window.innerWidth:this._container.scrollWidth,l=10,u=t>a-i-l,d=t<l,f=u?a-i-l:d?l:t,h=10,g=n>s-r-h,m=n<h,p=g?s-r-h:m?h:n;return[a<i?0:f,s<r?0:p]}_setContainerPosition(){var t;this._container!==document.body&&((t=getComputedStyle(this._container))===null||t===void 0?void 0:t.position)==="static"&&(this._container.style.position="relative")}_setUpEvents(){const{config:t}=this;this.components.forEach(n=>{const i=ce(n.element);i.on("mousemove.tooltip",r=>{const o=r.composedPath&&r.composedPath()||r.path||[r.target];for(const s of Object.keys(t.triggers)){const a=t.triggers[s];if(!a)continue;const l=i.selectAll(`.${s}`).nodes();for(const u of o){if(u===i.node())break;if(u.classList.contains(s)){const d=l.indexOf(u),f=ce(u).datum(),h=a(f,d,l),[g,m]=this.isContainerBody()?[r.clientX,r.clientY]:li(r,this._container);h===null?this.hide():(this.render(h),t.followCursor?this.place({x:g,y:m}):this.placeByElement(u)),r.stopPropagation();return}}}this._isShown&&this.hide()}).on("mouseleave.tooltip",r=>{r.stopPropagation(),this.hide()})}),t.allowHover&&!t.followCursor?this.div.on("mouseenter.tooltip",this.display.bind(this)).on("mouseleave.tooltip",this.hide.bind(this)):this.div.on("mouseenter.tooltip",null).on("mouseleave.tooltip",null)}_setUpAttributes(){const t=this.config.attributes;t&&Object.keys(t).forEach(n=>{this.div.attr(n,t[n])})}destroy(){var t;this._mutationObserver.disconnect(),(t=this.div)===null||t===void 0||t.remove()}}xu.selectors=B0;function L(e){return function(){return e}}const $a=Math.abs,oe=Math.atan2,je=Math.cos,z0=Math.max,vr=Math.min,pe=Math.sin,ne=Math.sqrt,le=1e-12,gt=Math.PI,Ti=gt/2,ht=2*gt;function H0(e){return e>1?0:e<-1?gt:Math.acos(e)}function Ma(e){return e>=1?Ti:e<=-1?-Ti:Math.asin(e)}const Kr=Math.PI,Jr=2*Kr,xt=1e-6,G0=Jr-xt;function wu(e){this._+=e[0];for(let t=1,n=e.length;t<n;++t)this._+=arguments[t]+e[t]}function U0(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return wu;const n=10**t;return function(i){this._+=i[0];for(let r=1,o=i.length;r<o;++r)this._+=Math.round(arguments[r]*n)/n+i[r]}}class W0{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?wu:U0(t)}moveTo(t,n){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,n){this._append`L${this._x1=+t},${this._y1=+n}`}quadraticCurveTo(t,n,i,r){this._append`Q${+t},${+n},${this._x1=+i},${this._y1=+r}`}bezierCurveTo(t,n,i,r,o,s){this._append`C${+t},${+n},${+i},${+r},${this._x1=+o},${this._y1=+s}`}arcTo(t,n,i,r,o){if(t=+t,n=+n,i=+i,r=+r,o=+o,o<0)throw new Error(`negative radius: ${o}`);let s=this._x1,a=this._y1,l=i-t,u=r-n,d=s-t,f=a-n,h=d*d+f*f;if(this._x1===null)this._append`M${this._x1=t},${this._y1=n}`;else if(h>xt)if(!(Math.abs(f*l-u*d)>xt)||!o)this._append`L${this._x1=t},${this._y1=n}`;else{let g=i-s,m=r-a,p=l*l+u*u,v=g*g+m*m,_=Math.sqrt(p),y=Math.sqrt(h),x=o*Math.tan((Kr-Math.acos((p+h-v)/(2*_*y)))/2),w=x/y,S=x/_;Math.abs(w-1)>xt&&this._append`L${t+w*d},${n+w*f}`,this._append`A${o},${o},0,0,${+(f*g>d*m)},${this._x1=t+S*l},${this._y1=n+S*u}`}}arc(t,n,i,r,o,s){if(t=+t,n=+n,i=+i,s=!!s,i<0)throw new Error(`negative radius: ${i}`);let a=i*Math.cos(r),l=i*Math.sin(r),u=t+a,d=n+l,f=1^s,h=s?r-o:o-r;this._x1===null?this._append`M${u},${d}`:(Math.abs(this._x1-u)>xt||Math.abs(this._y1-d)>xt)&&this._append`L${u},${d}`,i&&(h<0&&(h=h%Jr+Jr),h>G0?this._append`A${i},${i},0,1,${f},${t-a},${n-l}A${i},${i},0,1,${f},${this._x1=u},${this._y1=d}`:h>xt&&this._append`A${i},${i},0,${+(h>=Kr)},${f},${this._x1=t+i*Math.cos(o)},${this._y1=n+i*Math.sin(o)}`)}rect(t,n,i,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+n}h${i=+i}v${+r}h${-i}Z`}toString(){return this._}}function qi(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 W0(t)}function Y0(e){return e.innerRadius}function q0(e){return e.outerRadius}function X0(e){return e.startAngle}function j0(e){return e.endAngle}function Z0(e){return e&&e.padAngle}function Q0(e,t,n,i,r,o,s,a){var l=n-e,u=i-t,d=s-r,f=a-o,h=f*l-d*u;if(!(h*h<le))return h=(d*(t-o)-f*(e-r))/h,[e+h*l,t+h*u]}function zn(e,t,n,i,r,o,s){var a=e-n,l=t-i,u=(s?o:-o)/ne(a*a+l*l),d=u*l,f=-u*a,h=e+d,g=t+f,m=n+d,p=i+f,v=(h+m)/2,_=(g+p)/2,y=m-h,x=p-g,w=y*y+x*x,S=r-o,b=h*p-m*g,C=(x<0?-1:1)*ne(z0(0,S*S*w-b*b)),V=(b*x-y*C)/w,F=(-b*y-x*C)/w,U=(b*x+y*C)/w,M=(-b*y+x*C)/w,I=V-v,T=F-_,D=U-v,ie=M-_;return I*I+T*T>D*D+ie*ie&&(V=U,F=M),{cx:V,cy:F,x01:-d,y01:-f,x11:V*(r/S-1),y11:F*(r/S-1)}}function K0(){var e=Y0,t=q0,n=L(0),i=null,r=X0,o=j0,s=Z0,a=null,l=qi(u);function u(){var d,f,h=+e.apply(this,arguments),g=+t.apply(this,arguments),m=r.apply(this,arguments)-Ti,p=o.apply(this,arguments)-Ti,v=$a(p-m),_=p>m;if(a||(a=d=l()),g<h&&(f=g,g=h,h=f),!(g>le))a.moveTo(0,0);else if(v>ht-le)a.moveTo(g*je(m),g*pe(m)),a.arc(0,0,g,m,p,!_),h>le&&(a.moveTo(h*je(p),h*pe(p)),a.arc(0,0,h,p,m,_));else{var y=m,x=p,w=m,S=p,b=v,C=v,V=s.apply(this,arguments)/2,F=V>le&&(i?+i.apply(this,arguments):ne(h*h+g*g)),U=vr($a(g-h)/2,+n.apply(this,arguments)),M=U,I=U,T,D;if(F>le){var ie=Ma(F/h*pe(V)),de=Ma(F/g*pe(V));(b-=ie*2)>le?(ie*=_?1:-1,w+=ie,S-=ie):(b=0,w=S=(m+p)/2),(C-=de*2)>le?(de*=_?1:-1,y+=de,x-=de):(C=0,y=x=(m+p)/2)}var re=g*je(y),fe=g*pe(y),J=h*je(S),Oe=h*pe(S);if(U>le){var st=g*je(x),qe=g*pe(x),at=h*je(w),_t=h*pe(w),he;if(v<gt)if(he=Q0(re,fe,at,_t,st,qe,J,Oe)){var lt=re-he[0],N=fe-he[1],ue=st-he[0],R=qe-he[1],O=1/pe(H0((lt*ue+N*R)/(ne(lt*lt+N*N)*ne(ue*ue+R*R)))/2),B=ne(he[0]*he[0]+he[1]*he[1]);M=vr(U,(h-B)/(O-1)),I=vr(U,(g-B)/(O+1))}else M=I=0}C>le?I>le?(T=zn(at,_t,re,fe,g,I,_),D=zn(st,qe,J,Oe,g,I,_),a.moveTo(T.cx+T.x01,T.cy+T.y01),I<U?a.arc(T.cx,T.cy,I,oe(T.y01,T.x01),oe(D.y01,D.x01),!_):(a.arc(T.cx,T.cy,I,oe(T.y01,T.x01),oe(T.y11,T.x11),!_),a.arc(0,0,g,oe(T.cy+T.y11,T.cx+T.x11),oe(D.cy+D.y11,D.cx+D.x11),!_),a.arc(D.cx,D.cy,I,oe(D.y11,D.x11),oe(D.y01,D.x01),!_))):(a.moveTo(re,fe),a.arc(0,0,g,y,x,!_)):a.moveTo(re,fe),!(h>le)||!(b>le)?a.lineTo(J,Oe):M>le?(T=zn(J,Oe,st,qe,h,-M,_),D=zn(re,fe,at,_t,h,-M,_),a.lineTo(T.cx+T.x01,T.cy+T.y01),M<U?a.arc(T.cx,T.cy,M,oe(T.y01,T.x01),oe(D.y01,D.x01),!_):(a.arc(T.cx,T.cy,M,oe(T.y01,T.x01),oe(T.y11,T.x11),!_),a.arc(0,0,h,oe(T.cy+T.y11,T.cx+T.x11),oe(D.cy+D.y11,D.cx+D.x11),_),a.arc(D.cx,D.cy,M,oe(D.y11,D.x11),oe(D.y01,D.x01),!_))):a.arc(0,0,h,S,w,_)}if(a.closePath(),d)return a=null,d+""||null}return u.centroid=function(){var d=(+e.apply(this,arguments)+ +t.apply(this,arguments))/2,f=(+r.apply(this,arguments)+ +o.apply(this,arguments))/2-gt/2;return[je(f)*d,pe(f)*d]},u.innerRadius=function(d){return arguments.length?(e=typeof d=="function"?d:L(+d),u):e},u.outerRadius=function(d){return arguments.length?(t=typeof d=="function"?d:L(+d),u):t},u.cornerRadius=function(d){return arguments.length?(n=typeof d=="function"?d:L(+d),u):n},u.padRadius=function(d){return arguments.length?(i=d==null?null:typeof d=="function"?d:L(+d),u):i},u.startAngle=function(d){return arguments.length?(r=typeof d=="function"?d:L(+d),u):r},u.endAngle=function(d){return arguments.length?(o=typeof d=="function"?d:L(+d),u):o},u.padAngle=function(d){return arguments.length?(s=typeof d=="function"?d:L(+d),u):s},u.context=function(d){return arguments.length?(a=d??null,u):a},u}function Ko(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function Su(e){this._context=e}Su.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(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;default:this._context.lineTo(e,t);break}}};function Jo(e){return new Su(e)}function bu(e){return e[0]}function Cu(e){return e[1]}function ku(e,t){var n=L(!0),i=null,r=Jo,o=null,s=qi(a);e=typeof e=="function"?e:e===void 0?bu:L(e),t=typeof t=="function"?t:t===void 0?Cu:L(t);function a(l){var u,d=(l=Ko(l)).length,f,h=!1,g;for(i==null&&(o=r(g=s())),u=0;u<=d;++u)!(u<d&&n(f=l[u],u,l))===h&&((h=!h)?o.lineStart():o.lineEnd()),h&&o.point(+e(f,u,l),+t(f,u,l));if(g)return o=null,g+""||null}return a.x=function(l){return arguments.length?(e=typeof l=="function"?l:L(+l),a):e},a.y=function(l){return arguments.length?(t=typeof l=="function"?l:L(+l),a):t},a.defined=function(l){return arguments.length?(n=typeof l=="function"?l:L(!!l),a):n},a.curve=function(l){return arguments.length?(r=l,i!=null&&(o=r(i)),a):r},a.context=function(l){return arguments.length?(l==null?i=o=null:o=r(i=l),a):i},a}function J0(e,t,n){var i=null,r=L(!0),o=null,s=Jo,a=null,l=qi(u);e=typeof e=="function"?e:e===void 0?bu:L(+e),t=typeof t=="function"?t:L(t===void 0?0:+t),n=typeof n=="function"?n:n===void 0?Cu:L(+n);function u(f){var h,g,m,p=(f=Ko(f)).length,v,_=!1,y,x=new Array(p),w=new Array(p);for(o==null&&(a=s(y=l())),h=0;h<=p;++h){if(!(h<p&&r(v=f[h],h,f))===_)if(_=!_)g=h,a.areaStart(),a.lineStart();else{for(a.lineEnd(),a.lineStart(),m=h-1;m>=g;--m)a.point(x[m],w[m]);a.lineEnd(),a.areaEnd()}_&&(x[h]=+e(v,h,f),w[h]=+t(v,h,f),a.point(i?+i(v,h,f):x[h],n?+n(v,h,f):w[h]))}if(y)return a=null,y+""||null}function d(){return ku().defined(r).curve(s).context(o)}return u.x=function(f){return arguments.length?(e=typeof f=="function"?f:L(+f),i=null,u):e},u.x0=function(f){return arguments.length?(e=typeof f=="function"?f:L(+f),u):e},u.x1=function(f){return arguments.length?(i=f==null?null:typeof f=="function"?f:L(+f),u):i},u.y=function(f){return arguments.length?(t=typeof f=="function"?f:L(+f),n=null,u):t},u.y0=function(f){return arguments.length?(t=typeof f=="function"?f:L(+f),u):t},u.y1=function(f){return arguments.length?(n=f==null?null:typeof f=="function"?f:L(+f),u):n},u.lineX0=u.lineY0=function(){return d().x(e).y(t)},u.lineY1=function(){return d().x(e).y(n)},u.lineX1=function(){return d().x(i).y(t)},u.defined=function(f){return arguments.length?(r=typeof f=="function"?f:L(!!f),u):r},u.curve=function(f){return arguments.length?(s=f,o!=null&&(a=s(o)),u):s},u.context=function(f){return arguments.length?(f==null?o=a=null:a=s(o=f),u):o},u}function ev(e,t){return t<e?-1:t>e?1:t>=e?0:NaN}function tv(e){return e}function nv(){var e=tv,t=ev,n=null,i=L(0),r=L(ht),o=L(0);function s(a){var l,u=(a=Ko(a)).length,d,f,h=0,g=new Array(u),m=new Array(u),p=+i.apply(this,arguments),v=Math.min(ht,Math.max(-ht,r.apply(this,arguments)-p)),_,y=Math.min(Math.abs(v)/u,o.apply(this,arguments)),x=y*(v<0?-1:1),w;for(l=0;l<u;++l)(w=m[g[l]=l]=+e(a[l],l,a))>0&&(h+=w);for(t!=null?g.sort(function(S,b){return t(m[S],m[b])}):n!=null&&g.sort(function(S,b){return n(a[S],a[b])}),l=0,f=h?(v-u*x)/h:0;l<u;++l,p=_)d=g[l],w=m[d],_=p+(w>0?w*f:0)+x,m[d]={data:a[d],index:l,value:w,startAngle:p,endAngle:_,padAngle:y};return m}return s.value=function(a){return arguments.length?(e=typeof a=="function"?a:L(+a),s):e},s.sortValues=function(a){return arguments.length?(t=a,n=null,s):t},s.sort=function(a){return arguments.length?(n=a,t=null,s):n},s.startAngle=function(a){return arguments.length?(i=typeof a=="function"?a:L(+a),s):i},s.endAngle=function(a){return arguments.length?(r=typeof a=="function"?a:L(+a),s):r},s.padAngle=function(a){return arguments.length?(o=typeof a=="function"?a:L(+a),s):o},s}const Tu={draw(e,t){const n=ne(t/gt);e.moveTo(n,0),e.arc(0,0,n,0,ht)}},iv={draw(e,t){const n=ne(t/5)/2;e.moveTo(-3*n,-n),e.lineTo(-n,-n),e.lineTo(-n,-3*n),e.lineTo(n,-3*n),e.lineTo(n,-n),e.lineTo(3*n,-n),e.lineTo(3*n,n),e.lineTo(n,n),e.lineTo(n,3*n),e.lineTo(-n,3*n),e.lineTo(-n,n),e.lineTo(-3*n,n),e.closePath()}},Ru=ne(1/3),rv=Ru*2,ov={draw(e,t){const n=ne(t/rv),i=n*Ru;e.moveTo(0,-n),e.lineTo(i,0),e.lineTo(0,n),e.lineTo(-i,0),e.closePath()}},sv={draw(e,t){const n=ne(t),i=-n/2;e.rect(i,i,n,n)}},av=.8908130915292852,$u=pe(gt/10)/pe(7*gt/10),lv=pe(ht/10)*$u,uv=-je(ht/10)*$u,cv={draw(e,t){const n=ne(t*av),i=lv*n,r=uv*n;e.moveTo(0,-n),e.lineTo(i,r);for(let o=1;o<5;++o){const s=ht*o/5,a=je(s),l=pe(s);e.lineTo(l*n,-a*n),e.lineTo(a*i-l*r,l*i+a*r)}e.closePath()}},_r=ne(3),dv={draw(e,t){const n=-ne(t/(_r*3));e.moveTo(0,n*2),e.lineTo(-_r*n,-n),e.lineTo(_r*n,-n),e.closePath()}},Re=-.5,$e=ne(3)/2,eo=1/ne(12),fv=(eo/2+1)*3,hv={draw(e,t){const n=ne(t/fv),i=n/2,r=n*eo,o=i,s=n*eo+n,a=-o,l=s;e.moveTo(i,r),e.lineTo(o,s),e.lineTo(a,l),e.lineTo(Re*i-$e*r,$e*i+Re*r),e.lineTo(Re*o-$e*s,$e*o+Re*s),e.lineTo(Re*a-$e*l,$e*a+Re*l),e.lineTo(Re*i+$e*r,Re*r-$e*i),e.lineTo(Re*o+$e*s,Re*s-$e*o),e.lineTo(Re*a+$e*l,Re*l-$e*a),e.closePath()}};function gv(e,t){let n=null,i=qi(r);e=typeof e=="function"?e:L(e||Tu),t=typeof t=="function"?t:L(t===void 0?64:+t);function r(){let o;if(n||(n=o=i()),e.apply(this,arguments).draw(n,+t.apply(this,arguments)),o)return n=null,o+""||null}return r.type=function(o){return arguments.length?(e=typeof o=="function"?o:L(o),r):e},r.size=function(o){return arguments.length?(t=typeof o=="function"?o:L(+o),r):t},r.context=function(o){return arguments.length?(n=o??null,r):n},r}function pt(){}function Ri(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 Xi(e){this._context=e}Xi.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:Ri(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:Ri(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function pv(e){return new Xi(e)}function Mu(e){this._context=e}Mu.prototype={areaStart:pt,areaEnd:pt,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:Ri(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function mv(e){return new Mu(e)}function Eu(e){this._context=e}Eu.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:Ri(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function vv(e){return new Eu(e)}function Au(e,t){this._basis=new Xi(e),this._beta=t}Au.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],r=t[0],o=e[n]-i,s=t[n]-r,a=-1,l;++a<=n;)l=a/n,this._basis.point(this._beta*e[a]+(1-this._beta)*(i+l*o),this._beta*t[a]+(1-this._beta)*(r+l*s));this._x=this._y=null,this._basis.lineEnd()},point:function(e,t){this._x.push(+e),this._y.push(+t)}};const _v=function e(t){function n(i){return t===1?new Xi(i):new Au(i,t)}return n.beta=function(i){return e(+i)},n}(.85);function $i(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 es(e,t){this._context=e,this._k=(1-t)/6}es.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:$i(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:$i(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 yv=function e(t){function n(i){return new es(i,t)}return n.tension=function(i){return e(+i)},n}(0);function ts(e,t){this._context=e,this._k=(1-t)/6}ts.prototype={areaStart:pt,areaEnd:pt,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:$i(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 xv=function e(t){function n(i){return new ts(i,t)}return n.tension=function(i){return e(+i)},n}(0);function ns(e,t){this._context=e,this._k=(1-t)/6}ns.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:$i(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 wv=function e(t){function n(i){return new ns(i,t)}return n.tension=function(i){return e(+i)},n}(0);function is(e,t,n){var i=e._x1,r=e._y1,o=e._x2,s=e._y2;if(e._l01_a>le){var a=2*e._l01_2a+3*e._l01_a*e._l12_a+e._l12_2a,l=3*e._l01_a*(e._l01_a+e._l12_a);i=(i*a-e._x0*e._l12_2a+e._x2*e._l01_2a)/l,r=(r*a-e._y0*e._l12_2a+e._y2*e._l01_2a)/l}if(e._l23_a>le){var u=2*e._l23_2a+3*e._l23_a*e._l12_a+e._l12_2a,d=3*e._l23_a*(e._l23_a+e._l12_a);o=(o*u+e._x1*e._l23_2a-t*e._l12_2a)/d,s=(s*u+e._y1*e._l23_2a-n*e._l12_2a)/d}e._context.bezierCurveTo(i,r,o,s,e._x2,e._y2)}function Fu(e,t){this._context=e,this._alpha=t}Fu.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:is(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 Sv=function e(t){function n(i){return t?new Fu(i,t):new es(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Vu(e,t){this._context=e,this._alpha=t}Vu.prototype={areaStart:pt,areaEnd:pt,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:is(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 bv=function e(t){function n(i){return t?new Vu(i,t):new ts(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Nu(e,t){this._context=e,this._alpha=t}Nu.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:is(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 Cv=function e(t){function n(i){return t?new Nu(i,t):new ns(i,0)}return n.alpha=function(i){return e(+i)},n}(.5);function Du(e){this._context=e}Du.prototype={areaStart:pt,areaEnd:pt,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 kv(e){return new Du(e)}function Ea(e){return e<0?-1:1}function Aa(e,t,n){var i=e._x1-e._x0,r=t-e._x1,o=(e._y1-e._y0)/(i||r<0&&-0),s=(n-e._y1)/(r||i<0&&-0),a=(o*r+s*i)/(i+r);return(Ea(o)+Ea(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function Fa(e,t){var n=e._x1-e._x0;return n?(3*(e._y1-e._y0)/n-t)/2:t}function yr(e,t,n){var i=e._x0,r=e._y0,o=e._x1,s=e._y1,a=(o-i)/3;e._context.bezierCurveTo(i+a,r+a*t,o-a,s-a*n,o,s)}function Mi(e){this._context=e}Mi.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:yr(this,this._t0,Fa(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,yr(this,Fa(this,n=Aa(this,e,t)),n);break;default:yr(this,this._t0,n=Aa(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=n}}};function Pu(e){this._context=new Ou(e)}(Pu.prototype=Object.create(Mi.prototype)).point=function(e,t){Mi.prototype.point.call(this,t,e)};function Ou(e){this._context=e}Ou.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,r,o){this._context.bezierCurveTo(t,e,i,n,o,r)}};function Tv(e){return new Mi(e)}function Rv(e){return new Pu(e)}function Lu(e){this._context=e}Lu.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=Va(e),r=Va(t),o=0,s=1;s<n;++o,++s)this._context.bezierCurveTo(i[0][o],r[0][o],i[1][o],r[1][o],e[s],t[s]);(this._line||this._line!==0&&n===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function Va(e){var t,n=e.length-1,i,r=new Array(n),o=new Array(n),s=new Array(n);for(r[0]=0,o[0]=2,s[0]=e[0]+2*e[1],t=1;t<n-1;++t)r[t]=1,o[t]=4,s[t]=4*e[t]+2*e[t+1];for(r[n-1]=2,o[n-1]=7,s[n-1]=8*e[n-1]+e[n],t=1;t<n;++t)i=r[t]/o[t-1],o[t]-=i,s[t]-=i*s[t-1];for(r[n-1]=s[n-1]/o[n-1],t=n-2;t>=0;--t)r[t]=(s[t]-r[t+1])/o[t];for(o[n-1]=(e[n]+r[n-1])/2,t=0;t<n-1;++t)o[t]=2*e[t+1]-r[t+1];return[r,o]}function $v(e){return new Lu(e)}function ji(e,t){this._context=e,this._t=t}ji.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=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 Mv(e){return new ji(e,.5)}function Ev(e){return new ji(e,0)}function Av(e){return new ji(e,1)}function Na(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),n.push.apply(n,i)}return n}function Fv(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Na(Object(n),!0).forEach(function(i){Vv(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Na(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function mn(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?mn=function(t){return typeof t}:mn=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},mn(e)}function Vv(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ei(){return Ei=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},Ei.apply(this,arguments)}function Nv(e,t){if(e){if(typeof e=="string")return Da(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 Da(e,t)}}function Da(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Iu(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Nv(e))||t){n&&(e=n);var i=0,r=function(){};return{s:r,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(l){throw l},f:r}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
115
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var o=!0,s=!1,a;return{s:function(){n=n.call(e)},n:function(){var l=n.next();return o=l.done,l},e:function(l){s=!0,a=l},f:function(){try{!o&&n.return!=null&&n.return()}finally{if(s)throw a}}}}function Dv(e,t){var n=[],i=[];function r(o,s){if(o.length===1)n.push(o[0]),i.push(o[0]);else{for(var a=Array(o.length-1),l=0;l<a.length;l++)l===0&&n.push(o[0]),l===a.length-1&&i.push(o[l+1]),a[l]=[(1-s)*o[l][0]+s*o[l+1][0],(1-s)*o[l][1]+s*o[l+1][1]];r(a,s)}}return e.length&&r(e,t),{left:n,right:i.reverse()}}function Pv(e){var t={};return e.length===4&&(t.x2=e[2][0],t.y2=e[2][1]),e.length>=3&&(t.x1=e[1][0],t.y1=e[1][1]),t.x=e[e.length-1][0],t.y=e[e.length-1][1],e.length===4?t.type="C":e.length===3?t.type="Q":t.type="L",t}function Ov(e,t){t=t||2;for(var n=[],i=e,r=1/t,o=0;o<t-1;o++){var s=r/(1-r*o),a=Dv(i,s);n.push(a.left),i=a.right}return n.push(i),n}function Lv(e,t,n){var i=[[e.x,e.y]];return t.x1!=null&&i.push([t.x1,t.y1]),t.x2!=null&&i.push([t.x2,t.y2]),i.push([t.x,t.y]),Ov(i,n).map(Pv)}var Iv=/[MLCSTQAHVZmlcstqahv]|-?[\d.e+-]+/g,It={M:["x","y"],L:["x","y"],H:["x"],V:["y"],C:["x1","y1","x2","y2","x","y"],S:["x2","y2","x","y"],Q:["x1","y1","x","y"],T:["x","y"],A:["rx","ry","xAxisRotation","largeArcFlag","sweepFlag","x","y"],Z:[]};Object.keys(It).forEach(function(e){It[e.toLowerCase()]=It[e]});function to(e,t){for(var n=Array(e),i=0;i<e;i++)n[i]=t;return n}function Bv(e){return"".concat(e.type).concat(It[e.type].map(function(t){return e[t]}).join(","))}function zv(e,t){var n={x1:"x",y1:"y",x2:"x",y2:"y"},i=["xAxisRotation","largeArcFlag","sweepFlag"];if(e.type!==t.type&&t.type.toUpperCase()!=="M"){var r={};Object.keys(t).forEach(function(o){var s=t[o],a=e[o];a===void 0&&(i.includes(o)?a=s:(a===void 0&&n[o]&&(a=e[n[o]]),a===void 0&&(a=0))),r[o]=a}),r.type=t.type,e=r}return e}function Hv(e,t,n){var i=[];if(t.type==="L"||t.type==="Q"||t.type==="C")i=i.concat(Lv(e,t,n));else{var r=Ei({},e);r.type==="M"&&(r.type="L"),i=i.concat(to(n-1).map(function(){return r})),i.push(t)}return i}function Pa(e,t,n){var i=e.length-1,r=t.length-1,o=i/r,s=to(r).reduce(function(l,u,d){var f=Math.floor(o*d);if(n&&f<e.length-1&&n(e[f],e[f+1])){var h=o*d%1<.5;l[f]&&(h?f>0?f-=1:f<e.length-1&&(f+=1):f<e.length-1?f+=1:f>0&&(f-=1))}return l[f]=(l[f]||0)+1,l},[]),a=s.reduce(function(l,u,d){if(d===e.length-1){var f=to(u,Ei({},e[e.length-1]));return f[0].type==="M"&&f.forEach(function(h){h.type="L"}),l.concat(f)}return l.concat(Hv(e[d],e[d+1],u))},[]);return a.unshift(e[0]),a}function Oa(e){for(var t=(e||"").match(Iv)||[],n=[],i,r,o=0;o<t.length;++o)if(i=It[t[o]],i){r={type:t[o]};for(var s=0;s<i.length;++s)r[i[s]]=+t[o+s+1];o+=i.length,n.push(r)}return n}function Gv(e,t,n){var i=e==null?[]:e.slice(),r=t==null?[]:t.slice(),o=mn(n)==="object"?n:{excludeSegment:n,snapEndsToInput:!0},s=o.excludeSegment,a=o.snapEndsToInput;if(!i.length&&!r.length)return function(){return[]};var l=(i.length===0||i[i.length-1].type==="Z")&&(r.length===0||r[r.length-1].type==="Z");i.length>0&&i[i.length-1].type==="Z"&&i.pop(),r.length>0&&r[r.length-1].type==="Z"&&r.pop(),i.length?r.length||r.push(i[0]):i.push(r[0]);var u=Math.abs(r.length-i.length);u!==0&&(r.length>i.length?i=Pa(i,r,s):r.length<i.length&&(r=Pa(r,i,s))),i=i.map(function(f,h){return zv(f,r[h])});var d=i.map(function(f){return Fv({},f)});return l&&(d.push({type:"Z"}),i.push({type:"Z"})),function(h){if(h===1&&a)return t??[];if(h===0)return i;for(var g=0;g<d.length;++g){var m=i[g],p=r[g],v=d[g],_=Iu(It[v.type]),y;try{for(_.s();!(y=_.n()).done;){var x=y.value;v[x]=(1-h)*m[x]+h*p[x],(x==="largeArcFlag"||x==="sweepFlag")&&(v[x]=Math.round(v[x]))}}catch(w){_.e(w)}finally{_.f()}}return d}}function Bu(e,t,n){var i=Oa(e),r=Oa(t),o=mn(n)==="object"?n:{excludeSegment:n,snapEndsToInput:!0},s=o.excludeSegment,a=o.snapEndsToInput;if(!i.length&&!r.length)return function(){return""};var l=Gv(i,r,{excludeSegment:s,snapEndsToInput:a});return function(d){if(d===1&&a)return t??"";var f=l(d),h="",g=Iu(f),m;try{for(g.s();!(m=g.n()).done;){var p=m.value;h+=Bv(p)}}catch(v){g.e(v)}finally{g.f()}return h}}function _e(e,t,n,i){return Array.isArray(t)&&isFinite(n)?t[n%t.length]:zt(e,t,n)||(be(n)?`var(${ut(n)})`:null)}var Y;(function(e){e.Basis="basis",e.BasisClosed="basisClosed",e.BasisOpen="basisOpen",e.Bundle="bundle",e.Cardinal="cardinal",e.CardinalClosed="cardinalClosed",e.CardinalOpen="cardinalOpen",e.CatmullRom="catmullRom",e.CatmullRomClosed="catmullRomClosed",e.CatmullRomOpen="catmullRomOpen",e.Linear="linear",e.LinearClosed="linearClosed",e.MonotoneX="monotoneX",e.MonotoneY="monotoneY",e.Natural="natural",e.Step="step",e.StepAfter="stepAfter",e.StepBefore="stepBefore"})(Y||(Y={}));const no={[Y.Basis]:pv,[Y.BasisClosed]:mv,[Y.BasisOpen]:vv,[Y.Bundle]:_v,[Y.Cardinal]:yv,[Y.CardinalClosed]:xv,[Y.CardinalOpen]:wv,[Y.CatmullRom]:Sv,[Y.CatmullRomClosed]:bv,[Y.CatmullRomOpen]:Cv,[Y.Linear]:Jo,[Y.LinearClosed]:kv,[Y.MonotoneX]:Tv,[Y.MonotoneY]:Rv,[Y.Natural]:$v,[Y.Step]:Mv,[Y.StepAfter]:Av,[Y.StepBefore]:Ev},Uv=Object.assign(Object.assign({},Zt),{curveType:Y.MonotoneX,lineWidth:2,lineDashArray:void 0,fallbackValue:void 0,highlightOnHover:!1,cursor:null,interpolateMissingData:!1}),Wv=ot`
|
|
116
|
-
:root {
|
|
117
|
-
--vis-line-cursor: default;
|
|
118
|
-
--vis-line-stroke-dasharray: none;
|
|
119
|
-
--vis-line-stroke-dashoffset: 0;
|
|
120
|
-
|
|
121
|
-
--vis-line-gapfill-stroke-dasharray: 2 3;
|
|
122
|
-
--vis-line-gapfill-stroke-opacity: 0.8;
|
|
123
|
-
--vis-line-gapfill-stroke-dashoffset: 0;
|
|
124
|
-
}
|
|
125
|
-
`,Yv=P`
|
|
126
|
-
label: line-component;
|
|
127
|
-
`,un=P`
|
|
128
|
-
label: line;
|
|
129
|
-
transition: opacity 200ms;
|
|
130
|
-
cursor: var(--vis-line-cursor);
|
|
131
|
-
`,io=P`
|
|
132
|
-
label: linePath;
|
|
133
|
-
fill: none;
|
|
134
|
-
stroke-dasharray: var(--vis-line-stroke-dasharray);
|
|
135
|
-
stroke-dashoffset: var(--vis-line-stroke-dashoffset);
|
|
136
|
-
`,ro=P`
|
|
137
|
-
label: lineSelectionHelper;
|
|
138
|
-
fill: none;
|
|
139
|
-
stroke: rgba(0, 0, 0, 0);
|
|
140
|
-
stroke-width: 8px;
|
|
141
|
-
`,oo=P`
|
|
142
|
-
opacity: 0.2;
|
|
143
|
-
`,so=P`
|
|
144
|
-
label: interpolated-path;
|
|
145
|
-
fill: none;
|
|
146
|
-
stroke-dasharray: var(--vis-line-gapfill-stroke-dasharray);
|
|
147
|
-
stroke-dashoffset: var(--vis-line-gapfill-stroke-dashoffset);
|
|
148
|
-
stroke-opacity: var(--vis-line-gapfill-stroke-opacity);
|
|
149
|
-
`,qv=Object.freeze(Object.defineProperty({__proto__:null,dim:oo,globalStyles:Wv,interpolatedPath:so,line:un,linePath:io,lineSelectionHelper:ro,root:Yv},Symbol.toStringTag,{value:"Module"}));class Zi extends Fn{constructor(t){super(),this._defaultConfig=Uv,this.config=this._defaultConfig,this.curve=no[Y.MonotoneX],this.events={[Zi.selectors.line]:{mouseover:this._highlight.bind(this),mouseleave:this._resetHighlight.bind(this)}},t&&this.setConfig(t)}get bleed(){const{config:{lineWidth:t}}=this,n=this.yScale.domain(),r=(this.yScale.range()[0]>this.yScale.range()[1]?Ve.North:Ve.South)===Ve.South,o=t>3,s=t>=10;return{top:!s&&(!r&&n[1]===0||r&&n[0]===0)?0:t/2,bottom:!s&&(!r&&n[0]===0||r&&n[1]===0)?0:t/2,left:o?t/2:0,right:o?t/2:0}}_render(t){super._render(t);const{config:n,datamodel:{data:i}}=this,r=be(t)?t:n.duration;this.curve=no[n.curveType],this.lineGen=ku().x(f=>f.x).y(f=>f.y).defined(f=>f.defined).curve(this.curve);const o=et(n.y)?n.y:[n.y],s=i.map((f,h)=>this.xScale(X(f,n.x,h))),a=o.map(f=>{const h=i.map((_,y)=>{const x=X(_,f,y),w=(be(x)||x===null)&&isFinite(x)?x:n.fallbackValue,S=n.interpolateMissingData?(be(x)||x===null)&&isFinite(x):isFinite(w);return{x:s[y],y:this.yScale(w??0),defined:S,value:w}}),g=h.reduce((_,y)=>y.defined||_,!1);let m=!1;const p=h.reduce((_,y,x)=>{!y.defined&&isFinite(n.fallbackValue)&&_.push(Object.assign(Object.assign({},y),{defined:!0})),!y.defined&&!m&&(m=!0);const w=x>0&&!h[x-1].defined||x<h.length-1&&!h[x+1].defined;return y.defined&&w&&(m||_.push(Object.assign(Object.assign({},y),{defined:!1})),_.push(y),m=!1),_},[]),v=g&&h.some(_=>_.value!==null);return{values:h,defined:g,gaps:p,visible:v}}),l=this.g.selectAll(`.${un}`).data(a),u=l.enter().append("g").attr("class",un);u.append("path").attr("class",io).attr("stroke",(f,h)=>_e(i,n.color,h)).attr("stroke-opacity",0).attr("stroke-width",n.lineWidth),u.append("path").attr("class",ro).attr("d",this._emptyPath()),u.append("path").attr("class",so).attr("d",this._emptyPath()).style("opacity",0);const d=u.merge(l);d.style("cursor",(f,h)=>zt(i,n.cursor,h)),d.each((f,h,g)=>{var m;const p=ce(g[h]),v=p.select(`.${io}`),_=p.select(`.${ro}`),y=p.select(`.${so}`),x=f.visible,w=Co(i,n.lineDashArray,h),S=Z(v,r).attr("stroke",_e(i,n.color,h)).attr("stroke-width",n.lineWidth).attr("stroke-opacity",x?1:0).style("stroke-dasharray",(m=w==null?void 0:w.join(" "))!==null&&m!==void 0?m:null),b=f.values.some(V=>!V.defined),C=this.lineGen(f.values);if(r&&!b){const V=v.attr("d")||this._emptyPath(),F=C||this._emptyPath();S.attrTween("d",()=>Bu(V,F))}else f.visible&&S.attr("d",C);_.attr("d",C).attr("visibility",x?null:"hidden"),b&&n.interpolateMissingData?Z(y,r).attr("d",this.lineGen(f.gaps)).attr("stroke",_e(i,n.color,h)).attr("stroke-width",n.lineWidth-1).style("opacity",1):y.transition().duration(r).style("opacity",0)}),Z(l.exit(),r).style("opacity",0).remove()}_emptyPath(){const t=this.xScale.range(),n=this.yScale.range();return`M${t[0]},${n[0]} L${t[1]},${n[0]}`}_highlight(t){const{config:n}=this;n.highlightOnHover&&this.g.selectAll(`.${un}`).classed(oo,i=>i!==t)}_resetHighlight(){const{config:t}=this;t.highlightOnHover&&this.g.selectAll(`.${un}`).classed(oo,!1)}}Zi.selectors=qv;function Xv({x:e,y:t,w:n,h:i,tl:r=!1,tr:o=!1,bl:s=!1,br:a=!1,r:l=0}){let u;u=`M${e+l},${t}h${n-2*l}`;let d=o?l:0,f=o?0:l;return u+=`a${d},${d} 0 0 1 ${d},${d}`,u+=`h${f}v${f}`,u+=`v${i-2*l}`,d=a?l:0,f=a?0:l,u+=`a${d},${d} 0 0 1 ${-d},${d}`,u+=`v${f}h${-f}`,u+=`h${2*l-n}`,d=s?l:0,f=s?0:l,u+=`a${d},${d} 0 0 1 ${-d},${-d}`,u+=`h${-f}v${-f}`,u+=`v${2*l-i}`,d=r?l:0,f=r?0:l,u+=`a${d},${d} 0 0 1 ${d},${-d}`,u+=`v${-f}h${f}`,u+="z",u}const jv=Object.assign(Object.assign({},Zt),{color:void 0,groupMaxWidth:void 0,groupWidth:void 0,dataStep:void 0,groupPadding:.05,barPadding:0,roundedCorners:2,barMinHeight:2,cursor:null,orientation:ki.Vertical}),zu=P`
|
|
150
|
-
label: grouped-bar-component;
|
|
151
|
-
`,Zv=ot`
|
|
152
|
-
:root {
|
|
153
|
-
--vis-grouped-bar-cursor: default;
|
|
154
|
-
--vis-grouped-bar-fill-color: var(--vis-color-main);
|
|
155
|
-
--vis-grouped-bar-stroke-color: none;
|
|
156
|
-
--vis-grouped-bar-stroke-width: 0px;
|
|
157
|
-
--vis-grouped-bar-hover-stroke-width: 1px;
|
|
158
|
-
--vis-grouped-bar-hover-stroke-color: none;
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
/* Dark Theme */
|
|
162
|
-
--vis-dark-grouped-bar-stroke-color: none;
|
|
163
|
-
}
|
|
164
|
-
|
|
165
|
-
body.theme-dark ${`.${zu}`} {
|
|
166
|
-
--vis-grouped-bar-stroke-color: var(--vis-dark-grouped-bar-stroke-color);
|
|
167
|
-
}
|
|
168
|
-
`,ei=P`
|
|
169
|
-
label: bar;
|
|
170
|
-
fill: var(--vis-grouped-bar-fill-color);
|
|
171
|
-
stroke: var(--vis-grouped-bar-stroke-color);
|
|
172
|
-
stroke-width: var(--vis-grouped-bar-stroke-width);
|
|
173
|
-
cursor: var(--vis-grouped-bar-cursor);
|
|
174
|
-
|
|
175
|
-
&:hover {
|
|
176
|
-
stroke-width: var(--vis-grouped-bar-hover-stroke-width);
|
|
177
|
-
stroke: var(--vis-grouped-bar-hover-stroke-color);
|
|
178
|
-
}
|
|
179
|
-
`,ao=P`
|
|
180
|
-
label: barGroup;
|
|
181
|
-
`,Hu=P`
|
|
182
|
-
label: barGroupExit;
|
|
183
|
-
`,Qv=Object.freeze(Object.defineProperty({__proto__:null,bar:ei,barGroup:ao,barGroupExit:Hu,globalStyles:Zv,root:zu},Symbol.toStringTag,{value:"Module"}));class Qi extends Fn{constructor(t){super(),this._defaultConfig=jv,this.config=this._defaultConfig,this.getAccessors=()=>et(this.config.y)?this.config.y:[this.config.y],this.events={},this._barData=[],t&&this.setConfig(t)}get bleed(){if(this._barData=this._getVisibleData(),this._barData.length===0)return{top:0,bottom:0,left:0,right:0};const t=!this.isVertical()&&this.dataScale.range()[0]>this.dataScale.range()[1],n=this.dataScale.domain(),i=this._getGroupWidth()/2,r=this._barData.map((g,m)=>X(g,this.config.x,m)),o=gn(r),s=Dr(r),a=this.dataScale(o),l=this.dataScale(s),u=this.dataScale.invert(a+(t?i:-i)),d=this.dataScale.invert(l+(t?-i:i)),f=u<=n[0]?this.dataScale(n[0])-this.dataScale(u):0,h=d>n[1]?this.dataScale(d)-this.dataScale(n[1]):0;return{top:this.isVertical()?0:t?-h:f,bottom:this.isVertical()?0:t?-f:h,left:this.isVertical()?f:0,right:this.isVertical()?h:0}}get dataScale(){return this.isVertical()?this.xScale:this.yScale}get valueScale(){return this.isVertical()?this.yScale:this.xScale}isVertical(){return this.config.orientation===ki.Vertical}_render(t){const{config:n}=this,i=be(t)?t:n.duration,r=this._getGroupWidth(),o=this.getAccessors(),s=[-r/2,r/2],a=zi().domain(ll(o.length)).range(s).paddingInner(n.barPadding).paddingOuter(n.barPadding),l=this.g.selectAll(`.${ao}`).data(this._barData,(y,x)=>{var w;return`${(w=zt(y,n.id,x))!==null&&w!==void 0?w:x}`}),u=(y,x)=>{const w=this.dataScale(X(y,n.x,x)),S=this.isVertical()?w:0,b=this.isVertical()?0:w;return`translate(${S},${b})`},f=l.enter().append("g").attr("class",ao).attr("transform",u).style("opacity",1).merge(l);Z(f,i).attr("transform",u).style("opacity",1);const h=l.exit().attr("class",Hu);Z(h,i).style("opacity",0).remove(),Z(h.selectAll(`.${ei}`),i).attr("transform",(y,x,w)=>this.isVertical()?`translate(0,${this.yScale(0)}) scale(1,0)`:`translate(${this.xScale(0)},0) scale(0,1)`);const g=a.bandwidth(),m=f.selectAll(`.${ei}`).data(y=>o.map(()=>y)),p=this._getValueAxisDirection(),_=m.enter().append("path").attr("class",ei).attr("d",(y,x)=>{const w=a(x),S=this.valueScale(0),b=g;return this._getBarPath(w,S,b,0,!1,p)}).style("fill",(y,x)=>_e(y,n.color,x)).merge(m);Z(_,i).attr("d",(y,x)=>{const w=a(x),S=g,b=X(y,o[x]),C=b<0;let V=C?this.valueScale(0):this.valueScale(b||0),F=Math.abs(this.valueScale(0)-this.valueScale(b))||0;if(F<n.barMinHeight){const U=p===Ve.North?-1:1;V=this.valueScale(0)+U*n.barMinHeight,F=n.barMinHeight}return this._getBarPath(w,V,S,F,C,p)}).style("fill",(y,x)=>_e(y,n.color,x)).style("cursor",(y,x)=>zt(y,n.cursor,x)),Z(m.exit(),i).remove()}_getValueAxisDirection(){return this.valueScale.range()[0]>this.valueScale.range()[1]?Ve.North:Ve.South}_getVisibleData(){const{config:t,datamodel:{data:n}}=this,i=this._getGroupWidth(),r=n.length<2?0:i/2,o=this.dataScale,s=Math.abs(o.invert(r)-o.invert(0));return n==null?void 0:n.filter((l,u)=>{const d=X(l,t.x,u),f=o.domain(),h=+f[0],g=+f[1];return d>=h-s&&d<=g+s})}_getBarPath(t,n,i,r,o,s){const{config:a}=this,l=a.roundedCorners?be(a.roundedCorners)?+a.roundedCorners:i/2:0,u=He(l,0,Math.min(r,i)/2),d=s===Ve.North,f=this.isVertical()&&o!==d,h=this.isVertical()&&o===d,g=!this.isVertical()&&o,m=!this.isVertical()&&!o;return Xv({x:this.isVertical()?t:n+(d?0:-r),y:this.isVertical()?n+(d?0:-r):t,w:this.isVertical()?i:r,h:this.isVertical()?r:i,tl:f||g,tr:f||m,bl:h||g,br:h||m,r:u})}_getGroupWidth(){const{config:t,datamodel:{data:n}}=this;if(Ef(n))return 0;if(t.groupWidth)return gn([t.groupWidth,t.groupMaxWidth]);const i=this.dataScale.bandwidth,r=this.dataScale.domain?this.dataScale.domain():[];let s=1+(i?r.length:r[1]-r[0])/t.dataStep||!i&&n.filter((u,d)=>{const f=X(u,t.x,d);return f>=r[0]&&f<=r[1]}).length||n.length;!i&&s>=2&&(s+=1);const l=(s<2?1:1-t.groupPadding)*(this.isVertical()?this._width:this._height)/s;return gn([l,t.groupMaxWidth])}getValueScaleExtent(t){const{datamodel:n}=this,i=this.getAccessors(),r=t?this._getVisibleData():n.data,o=ul(r,...i),s=cl(r,...i);return[o>0?0:o,s<0?0:s]}getDataScaleExtent(){const{config:t,datamodel:n}=this;return Yn(n.data,t.x)}getYDataExtent(t){return this.isVertical()?this.getValueScaleExtent(t):this.getDataScaleExtent()}getXDataExtent(){return this.isVertical()?this.getDataScaleExtent():this.getValueScaleExtent(!1)}}Qi.selectors=Qv;function Kv(e){return e}var ti=1,ni=2,lo=3,cn=4,La=1e-6;function Jv(e){return"translate("+e+",0)"}function e_(e){return"translate(0,"+e+")"}function t_(e){return t=>+e(t)}function n_(e,t){return t=Math.max(0,e.bandwidth()-t*2)/2,e.round()&&(t=Math.round(t)),n=>+e(n)+t}function i_(){return!this.__axis}function Ki(e,t){var n=[],i=null,r=null,o=6,s=6,a=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,u=e===ti||e===cn?-1:1,d=e===cn||e===ni?"x":"y",f=e===ti||e===lo?Jv:e_;function h(g){var m=i??(t.ticks?t.ticks.apply(t,n):t.domain()),p=r??(t.tickFormat?t.tickFormat.apply(t,n):Kv),v=Math.max(o,0)+a,_=t.range(),y=+_[0]+l,x=+_[_.length-1]+l,w=(t.bandwidth?n_:t_)(t.copy(),l),S=g.selection?g.selection():g,b=S.selectAll(".domain").data([null]),C=S.selectAll(".tick").data(m,t).order(),V=C.exit(),F=C.enter().append("g").attr("class","tick"),U=C.select("line"),M=C.select("text");b=b.merge(b.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),C=C.merge(F),U=U.merge(F.append("line").attr("stroke","currentColor").attr(d+"2",u*o)),M=M.merge(F.append("text").attr("fill","currentColor").attr(d,u*v).attr("dy",e===ti?"0em":e===lo?"0.71em":"0.32em")),g!==S&&(b=b.transition(g),C=C.transition(g),U=U.transition(g),M=M.transition(g),V=V.transition(g).attr("opacity",La).attr("transform",function(I){return isFinite(I=w(I))?f(I+l):this.getAttribute("transform")}),F.attr("opacity",La).attr("transform",function(I){var T=this.parentNode.__axis;return f((T&&isFinite(T=T(I))?T:w(I))+l)})),V.remove(),b.attr("d",e===cn||e===ni?s?"M"+u*s+","+y+"H"+l+"V"+x+"H"+u*s:"M"+l+","+y+"V"+x:s?"M"+y+","+u*s+"V"+l+"H"+x+"V"+u*s:"M"+y+","+l+"H"+x),C.attr("opacity",1).attr("transform",function(I){return f(w(I)+l)}),U.attr(d+"2",u*o),M.attr(d,u*v).text(p),S.filter(i_).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",e===ni?"start":e===cn?"end":"middle"),S.each(function(){this.__axis=w})}return h.scale=function(g){return arguments.length?(t=g,h):t},h.ticks=function(){return n=Array.from(arguments),h},h.tickArguments=function(g){return arguments.length?(n=g==null?[]:Array.from(g),h):n.slice()},h.tickValues=function(g){return arguments.length?(i=g==null?null:Array.from(g),h):i&&i.slice()},h.tickFormat=function(g){return arguments.length?(r=g,h):r},h.tickSize=function(g){return arguments.length?(o=s=+g,h):o},h.tickSizeInner=function(g){return arguments.length?(o=+g,h):o},h.tickSizeOuter=function(g){return arguments.length?(s=+g,h):s},h.tickPadding=function(g){return arguments.length?(a=+g,h):a},h.offset=function(g){return arguments.length?(l=+g,h):l},h}function Ia(e){return Ki(ti,e)}function Ba(e){return Ki(ni,e)}function za(e){return Ki(lo,e)}function Ha(e){return Ki(cn,e)}var Tt;(function(e){e.Start="start",e.Middle="middle",e.End="end"})(Tt||(Tt={}));var Rt;(function(e){e.Top="top",e.Middle="middle",e.Bottom="bottom"})(Rt||(Rt={}));var Ai;(function(e){e.Wrap="wrap",e.Trim="trim"})(Ai||(Ai={}));var Ae;(function(e){e.Left="left",e.Center="center",e.Right="right"})(Ae||(Ae={}));var ii={exports:{}},r_=ii.exports,Ga;function o_(){return Ga||(Ga=1,function(e){(function(t){if(typeof n!="function"){var n=function(m){return m};n.nonNative=!0}const i=n("plaintext"),r=n("html"),o=n("comment"),s=/<(\w*)>/g,a=/<\/?([^\s\/>]+)/;function l(m,p,v){m=m||"",p=p||[],v=v||"";let _=d(p,v);return f(m,_)}function u(m,p){m=m||[],p=p||"";let v=d(m,p);return function(y){return f(y||"",v)}}l.init_streaming_mode=u;function d(m,p){return m=h(m),{allowable_tags:m,tag_replacement:p,state:i,tag_buffer:"",depth:0,in_quote_char:""}}function f(m,p){if(typeof m!="string")throw new TypeError("'html' parameter must be a string");let v=p.allowable_tags,_=p.tag_replacement,y=p.state,x=p.tag_buffer,w=p.depth,S=p.in_quote_char,b="";for(let C=0,V=m.length;C<V;C++){let F=m[C];if(y===i)switch(F){case"<":y=r,x+=F;break;default:b+=F;break}else if(y===r)switch(F){case"<":if(S)break;w++;break;case">":if(S)break;if(w){w--;break}S="",y=i,x+=">",v.has(g(x))?b+=x:b+=_,x="";break;case'"':case"'":F===S?S="":S=S||F,x+=F;break;case"-":x==="<!-"&&(y=o),x+=F;break;case" ":case`
|
|
184
|
-
`:if(x==="<"){y=i,b+="< ",x="";break}x+=F;break;default:x+=F;break}else if(y===o)switch(F){case">":x.slice(-2)=="--"&&(y=i),x="";break;default:x+=F;break}}return p.state=y,p.tag_buffer=x,p.depth=w,p.in_quote_char=S,b}function h(m){let p=new Set;if(typeof m=="string"){let v;for(;v=s.exec(m);)p.add(v[1])}else!n.nonNative&&typeof m[n.iterator]=="function"?p=new Set(m):typeof m.forEach=="function"&&m.forEach(p.add,p);return p}function g(m){let p=a.exec(m);return p?p[1].toLowerCase():null}e.exports?e.exports=l:t.striptags=l})(r_)}(ii)),ii.exports}var s_=o_();const a_=Hh(s_);function l_(e){switch(e){case Ae.Center:return"middle";case Ae.Right:return"end";case Ae.Left:default:return"start"}}function u_(e){var t;return(t=e.match(/[A-Z]{2,}(?=[A-Z][a-z0-9]*|\b)|[A-Z]?[a-z0-9]*|[A-Z]|[0-9]+/g))===null||t===void 0?void 0:t.filter(Boolean).map(n=>n.toLowerCase()).join("-")}function c_(e){return e.replace(/['"]/g,"'").replace(/\u0000/g,"\\0").replace(/\n/g,"\\n").replace(/\r/g,"\\r").replace(/\v/g,"\\v").replace(/\t/g,"\\t").replace(/\f/g,"\\f")}function d_(e,t=15){return e?e.length>t?`…${e.substr(e.length-t,t)}`:e:""}function f_(e,t=15){if(!e)return"";const n=Math.floor((t-3)/2);return e.length>t?`${e.substr(0,n)}…${e.substr(-n,n)}`:e}function h_(e,t=15){return e?e.length>t?`${e.substr(0,t)}…`:e:""}function g_(e,t=15,n=Tt.Middle){if(!e)return"";let i=h_(e,t);return n===Tt.Start?i=d_(e,t):n===Tt.Middle&&(i=f_(e,t)),i}function Gu(e,t=[" "]){let n=[e];for(let i=0;i<t.length;i++){const r=t[i];n.forEach((o,s)=>{const a=o.split(r),l=a.map((u,d)=>`${u}${d===a.length-1?"":r}`);n[s]=l}),n=Pr(n)}return n}function p_(e,t,n=[" ","-",".",","]){const i=e.text();if(!i)return;const r=et(n)?n:[n],o=Gu(i,r),s=parseFloat(e.attr("x"))||0;e.text("");let a=e.append("tspan").attr("x",s),l=`${o[0]}`;a.text(l),o.forEach((u,d)=>{if(d===0)return;const f=`${l}${u}`;a.text(f),a.node().getComputedTextLength()>t?(a.text(l.trim()),a=e.append("tspan").attr("x",s).attr("dy","1.2em").text(u),l=u):l+=u})}function m_(e,t,n,i,r,o){var s;t===void 0&&(t=50),n===void 0&&(n=Tt.Middle),r===void 0&&(r=+((s=window.getComputedStyle(e.node()))===null||s===void 0?void 0:s.fontSize)||0);const a=e.text(),l=a.length,u=r*l*o,f=Math.ceil(l*t/(1.1*u));return f<l?(e.text(g_(a,f,n)),!0):!1}function ri(e,t,n=cg()){return e.length*t*n||0}function oi(e,t,n){const i="http://www.w3.org/2000/svg",r=document.createElementNS(i,"svg"),o=document.createElementNS(i,"text");o.textContent=e,o.setAttribute("font-size",`${n}`),o.setAttribute("font-family",t),r.appendChild(o),document.body.appendChild(r);const s=o.getComputedTextLength();return document.body.removeChild(r),s}function v_(e,t=void 0,n=!0,i=Fl,r=!1){const o=`${e.text}`;if(!o)return[];const s=Array.isArray(i)?i:[i];return o.split(`
|
|
185
|
-
`).map(l=>{const u=[];if(!t)return[l];const d=Gu(l,s);let f="";for(let h=0;h<d.length;h+=1){(n?ri(f+d[h],e.fontSize,e.fontWidthToHeightRatio):oi(f+d[h],e.fontFamily,e.fontSize))<t||h===0?f+=d[h]:(u.push(f.trim()),f=d[h]);const m=2;if(r)for(;f.trim().length>m&&(n?ri(f,e.fontSize,e.fontWidthToHeightRatio):oi(f,e.fontFamily,e.fontSize))>t;){let v=f.trim().length-m;for(;v>0;){const _=`${f.substring(0,v)}${Vl}`;if((n?ri(_,e.fontSize,e.fontWidthToHeightRatio):oi(_,e.fontFamily,e.fontSize))<=t||v===1){u.push(_.trim()),f=f.substring(v);break}v--}}}return f&&u.push(f.trim()),u}).flat()}function __(e,t=void 0,n=void 0,i=!0,r=Fl,o=!1){const s=Array.isArray(e)?e.map(f=>$t(qs,f)):[$t(qs,e)],a=s.map(f=>v_(f,t,i,r,o)),l=s[0];let u=-l.fontSize*(l.lineHeight-1);const d=[];return s.forEach((f,h)=>{var g;let m=a[h];const p=h>0?d[h-1]:void 0,v=p?p.marginBottom:0,_=f.marginTop,y=Math.max(v,_);u+=y;const x=f.fontSize*f.lineHeight;let w=0;for(let S=0;S<m.length;S+=1){let b=m[S];u+=x;const C=`${b} …`,V=i?ri(C,f.fontSize,f.fontWidthToHeightRatio):oi(C,f.fontFamily,f.fontSize);if(w=Math.max(V,w),n&&u+x>n&&S!==m.length-1){b.charAt(b.length-1)===Vl&&(b=b.substr(0,m[S].length-1)),V<t?m[S]=C:m[S]=`${m[S].substr(0,m[S].length-2)}…`,m=m.slice(0,S+1);break}}d.push(Object.assign(Object.assign({},f),{_lines:m,_estimatedHeight:u-((p==null?void 0:p._estimatedHeight)||0),_maxWidth:Math.max(w,(g=p==null?void 0:p._maxWidth)!==null&&g!==void 0?g:0)}))}),d}function y_(e,t=0,n){return e.map((i,r)=>{const o=r>0?e[r-1]:void 0,s=o?o.marginBottom/o.fontSize:0,a=i.marginTop/i.fontSize,l=Math.max(s,a),u={fontSize:i.fontSize,fontFamily:i.fontFamily,fontWeight:i.fontWeight,fill:i.color,y:r===0&&n};return`<tspan xmlns="http://www.w3.org/2000/svg" ${Object.entries(u).filter(([f,h])=>h).map(([f,h])=>`${u_(f)}="${c_(h.toString())}"`).join(" ")}>${i._lines.map((f,h)=>{let g;return r===0&&h===0?g=.8+l:h===0?g=l+i.lineHeight:g=i.lineHeight,`<tspan x="${t}" dy="${g}em">${f.length?f:" "}</tspan>`}).join("")}</tspan>`})}function x_(e){return Rf(e,t=>t._estimatedHeight)}const w_=["text","tspan","textPath","altGlyph","altGlyphDef","altGlyphItem","glyphRef","textRef","textArea"];function S_(e,t,n,i){var r,o;const s=__(t,n.width,void 0,n.fastMode,n.separator,n.wordBreak),a=(r=n.x)!==null&&r!==void 0?r:+e.getAttribute("x"),l=(o=n.y)!==null&&o!==void 0?o:+e.getAttribute("y"),u=a??0;let d=l??0;if(n.textAlign&&e.setAttribute("text-anchor",l_(n.textAlign)),n.verticalAlign&&n.verticalAlign!==Rt.Top){const f=x_(s),h=n.verticalAlign===Rt.Middle?-f/2:n.verticalAlign===Rt.Bottom?-f:0;d+=h}n.textRotationAngle?e.setAttribute("transform",`rotate(${n.textRotationAngle===0||n.textRotationAngle?n.textRotationAngle:0} ${u} ${d})`):e.removeAttribute("transform");{const f=new DOMParser;e.textContent="",s.forEach(h=>{const g=y_([h],u,d).join(""),m=a_(g,w_),p=f.parseFromString(m,"image/svg+xml").firstChild;e.appendChild(p)})}}const b_=Object.assign(Object.assign({},Zt),{position:void 0,type:void 0,label:void 0,labelFontSize:null,gridLine:!0,tickLine:!0,domainLine:!0,numTicks:void 0,minMaxTicksOnly:!1,minMaxTicksOnlyWhenWidthIsLess:250,tickTextWidth:void 0,tickTextSeparator:void 0,tickTextForceWordBreak:!1,tickTextTrimType:Tt.Middle,tickTextFitMode:Ai.Wrap,tickTextFontSize:null,tickTextAlign:void 0,tickTextColor:null,tickTextAngle:void 0,labelMargin:8,labelColor:null,tickFormat:void 0,tickValues:void 0,fullSize:!0,tickPadding:8,tickTextHideOverlapping:void 0}),Uu=P`
|
|
186
|
-
label: axis-component;
|
|
187
|
-
`,C_=ot`
|
|
188
|
-
:root {
|
|
189
|
-
// Undefined by default to allow proper fallback to var(--vis-font-family)
|
|
190
|
-
/* --vis-axis-font-family: */
|
|
191
|
-
--vis-axis-tick-color: #e8e9ef;
|
|
192
|
-
/* --vis-axis-domain-color: // Undefined by default to allow fallback to var(--vis-axis-tick-color) */
|
|
193
|
-
--vis-axis-grid-color: #e8e9ef;
|
|
194
|
-
--vis-axis-label-color: #6c778c;
|
|
195
|
-
--vis-axis-tick-label-color: #6c778c;
|
|
196
|
-
--vis-axis-tick-label-font-size: 12px;
|
|
197
|
-
--vis-axis-tick-label-cursor: default;
|
|
198
|
-
--vis-axis-tick-label-text-decoration: none;
|
|
199
|
-
--vis-axis-label-font-size: 14px;
|
|
200
|
-
--vis-axis-tick-line-width: 1px;
|
|
201
|
-
--vis-axis-tick-label-hide-transition: opacity 400ms ease-in-out;
|
|
202
|
-
--vis-axis-grid-line-width: 1px;
|
|
203
|
-
/* --vis-axis-domain-line-width: // Undefined by default to allow fallback to var(--vis-axis-grid-line-width) */
|
|
204
|
-
|
|
205
|
-
--vis-dark-axis-tick-color: #6c778c;
|
|
206
|
-
/* --vis-dark-axis-domain-color: // Undefined by default to allow fallback to var(--vis-dark-axis-tick-color) */
|
|
207
|
-
--vis-dark-axis-tick-label-color: #e8e9ef;
|
|
208
|
-
--vis-dark-axis-grid-color: #6c778c;
|
|
209
|
-
--vis-dark-axis-label-color: #fefefe;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
body.theme-dark ${`.${Uu}`} {
|
|
213
|
-
--vis-axis-tick-color: var(--vis-dark-axis-tick-color);
|
|
214
|
-
--vis-axis-domain-color: var(--vis-dark-axis-domain-color);
|
|
215
|
-
--vis-axis-tick-label-color: var(--vis-dark-axis-tick-label-color);
|
|
216
|
-
--vis-axis-grid-color: var(--vis-dark-axis-grid-color);
|
|
217
|
-
--vis-axis-label-color: var(--vis-dark-axis-label-color);
|
|
218
|
-
}
|
|
219
|
-
`,rs=P`
|
|
220
|
-
label: hide-tick-line;
|
|
221
|
-
`,os=P`
|
|
222
|
-
label: hide-domain;
|
|
223
|
-
`,Wu=P`
|
|
224
|
-
label: axis;
|
|
225
|
-
|
|
226
|
-
user-select: none;
|
|
227
|
-
|
|
228
|
-
.domain {
|
|
229
|
-
stroke: var(--vis-axis-domain-color, var(--vis-axis-tick-color));
|
|
230
|
-
stroke-width: var(--vis-axis-domain-line-width, var(--vis-axis-grid-line-width));
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
&${`.${rs}`} {
|
|
234
|
-
.tick > line {
|
|
235
|
-
opacity: 0;
|
|
236
|
-
}
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
&${`.${os}`} {
|
|
240
|
-
.domain {
|
|
241
|
-
opacity: 0;
|
|
242
|
-
}
|
|
243
|
-
}
|
|
244
|
-
`,Yu=P`
|
|
245
|
-
label: grid;
|
|
246
|
-
|
|
247
|
-
.domain {
|
|
248
|
-
opacity: 0;
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
line {
|
|
252
|
-
stroke: var(--vis-axis-grid-color);
|
|
253
|
-
stroke-width: var(--vis-axis-grid-line-width);
|
|
254
|
-
}
|
|
255
|
-
`,qu=P`
|
|
256
|
-
label: tick;
|
|
257
|
-
|
|
258
|
-
stroke: none;
|
|
259
|
-
font-size: var(--vis-axis-tick-label-font-size);
|
|
260
|
-
|
|
261
|
-
line {
|
|
262
|
-
stroke: var(--vis-axis-tick-color);
|
|
263
|
-
stroke-width: var(--vis-axis-tick-line-width);
|
|
264
|
-
}
|
|
265
|
-
|
|
266
|
-
text {
|
|
267
|
-
fill: var(--vis-axis-tick-label-color);
|
|
268
|
-
cursor: var(--vis-axis-tick-label-cursor);
|
|
269
|
-
font-family: var(--vis-axis-font-family, var(--vis-font-family));
|
|
270
|
-
text-decoration: var(--vis-axis-tick-label-text-decoration);
|
|
271
|
-
stroke: none;
|
|
272
|
-
}
|
|
273
|
-
`,uo=P`
|
|
274
|
-
label: label;
|
|
275
|
-
fill: var(--vis-axis-label-color);
|
|
276
|
-
font-size: var(--vis-axis-label-font-size);
|
|
277
|
-
font-family: var(--vis-axis-font-family, var(--vis-font-family));
|
|
278
|
-
text-anchor: middle;
|
|
279
|
-
`,Xu=P`
|
|
280
|
-
label: tick-label;
|
|
281
|
-
`,ju=P`
|
|
282
|
-
label: tick-label-hideable;
|
|
283
|
-
opacity: 0;
|
|
284
|
-
transition: var(--vis-axis-tick-label-hide-transition);
|
|
285
|
-
`,k_=Object.freeze(Object.defineProperty({__proto__:null,axis:Wu,globalStyles:C_,grid:Yu,hideDomain:os,hideTickLine:rs,label:uo,root:Uu,tick:qu,tickLabel:Xu,tickLabelHideable:ju},Symbol.toStringTag,{value:"Module"}));class Zu extends Fn{constructor(t){super(),this._defaultConfig=b_,this.config=this._defaultConfig,this._defaultNumTicks=3,this.events={},t&&this.setConfig(t),this.axisGroup=this.g.append("g"),this.gridGroup=this.g.append("g").attr("class",Yu)}preRender(){const{config:t}=this,n=this.g.append("g").attr("opacity",0);this._renderAxis(n,0),this._axisRawBBox=n.node().getBBox(),t.tickTextAlign&&this._alignTickLabels(),this._renderAxisLabel(n),this._axisSizeBBox=this._getAxisSize(n),this._requiredMargin=this._getRequiredMargin(this._axisSizeBBox),n.remove()}getPosition(){const{config:{type:t,position:n}}=this;return n??(t===W.X?$.Bottom:$.Left)}_getAxisSize(t){return t.node().getBBox()}_getRequiredMargin(t=this._axisSizeBBox){const{config:{type:n,position:i}}=this;switch(n){case W.X:{const o=this._axisSizeBBox.x+this._axisSizeBBox.width,s=this._axisSizeBBox.x<0?Math.abs(this._axisSizeBBox.x):0,a=o-this._width>1?o-this._width:0;switch(i){case $.Top:return{top:t.height,left:s,right:a};case $.Bottom:default:return{bottom:t.height,left:s,right:a}}}case W.Y:{const r=t.height>this._height?(t.height-this._height)/2:0,o=r,s=r;switch(i){case $.Right:return{right:t.width,top:o,bottom:s};case $.Left:default:return{left:t.width,top:o,bottom:s}}}}}getRequiredMargin(){return this._requiredMargin}getOffset(t){const{config:{type:n,position:i}}=this;switch(n){case W.X:switch(i){case $.Top:return{top:t.top,left:t.left};case $.Bottom:default:return{top:t.top+this._height,left:t.left}}case W.Y:switch(i){case $.Right:return{top:t.top,left:t.left+this._width};case $.Left:default:return{top:t.top,left:t.left}}}}_render(t=this.config.duration,n=this.axisGroup){const{config:i}=this;if(this._renderAxis(n,t),this._renderAxisLabel(n),i.gridLine){const r=this._buildGrid().tickFormat(()=>"");r.tickValues(this._getConfiguredTickValues()),this.gridGroup.selectAll("*").interrupt(),Z(this.gridGroup,t).call(r).style("opacity",1)}else Z(this.gridGroup,t).style("opacity",0);i.tickTextAlign&&this._alignTickLabels(),this._resolveTickLabelOverlap(n)}_buildAxis(){const{config:{type:t,position:n,tickPadding:i}}=this,r=this._getNumTicks();switch(t){case W.X:switch(n){case $.Top:return Ia(this.xScale).ticks(r).tickPadding(i);case $.Bottom:default:return za(this.xScale).ticks(r).tickPadding(i)}case W.Y:switch(n){case $.Right:return Ba(this.yScale).ticks(r).tickPadding(i);case $.Left:default:return Ha(this.yScale).ticks(r).tickPadding(i)}}}_buildGrid(){const{config:{type:t,position:n}}=this,i=this._getNumTicks();switch(t){case W.X:switch(n){case $.Top:return Ia(this.xScale).ticks(i*2).tickSize(-this._height).tickSizeOuter(0);case $.Bottom:default:return za(this.xScale).ticks(i*2).tickSize(-this._height).tickSizeOuter(0)}case W.Y:switch(n){case $.Right:return Ba(this.yScale).ticks(i*2).tickSize(-this._width).tickSizeOuter(0);case $.Left:default:return Ha(this.yScale).ticks(i*2).tickSize(-this._width).tickSizeOuter(0)}}}_renderAxis(t=this.axisGroup,n=this.config.duration){const{config:i}=this,r=this._buildAxis(),o=this._getConfiguredTickValues()||r.scale().ticks(this._getNumTicks());r.tickValues(o),t.selectAll("*").interrupt(),Z(t,n).call(r);const s=t.selectAll("g.tick");s.classed(qu,!0).style("font-size",i.tickTextFontSize);const a=t.selectAll("g.tick > text").filter(l=>o.some(u=>_n(l,u))).classed(Xu,!0).classed(ju,!!i.tickTextHideOverlapping).style("fill",i.tickTextColor);if(a.nodes().forEach(l=>No(l)),a.each((l,u,d)=>{var f,h;let g=(h=(f=i.tickFormat)===null||f===void 0?void 0:f.call(i,l,u,o))!==null&&h!==void 0?h:`${l}`;const m=d[u],p=i.tickTextWidth||(i.type===W.X?this._containerWidth/(s.size()+1):this._containerWidth/5),v=getComputedStyle(m),_=Number.parseFloat(v.fontSize),y=v.fontFamily,x={verticalAlign:i.type===W.X?Rt.Top:Rt.Middle,width:p,textRotationAngle:i.tickTextAngle,separator:i.tickTextSeparator,wordBreak:i.tickTextForceWordBreak};if(i.tickTextFitMode===Ai.Trim){const S=ce(m).text(g);m_(S,p,i.tickTextTrimType,!0,_,.58),g=ce(m).text()}S_(m,{text:g,fontFamily:y,fontSize:_},x)}),t.classed(Wu,!0).classed(rs,!i.tickLine).classed(os,!i.domainLine),i.fullSize){const l=this._getFullDomainPath(0);Z(t.select(".domain"),n).attr("d",l)}}_resolveTickLabelOverlap(t=this.axisGroup){const{config:n}=this,i=t.selectAll("g.tick > text");if(!n.tickTextHideOverlapping){i.style("opacity",null);return}cancelAnimationFrame(this._collideTickLabelsAnimFrameId),this._collideTickLabelsAnimFrameId=requestAnimationFrame(()=>{this._collideTickLabels(i)})}_collideTickLabels(t){t.each((i,r,o)=>{const s=o[r];s._visible=!0});const n=3;for(let i=0;i<n;i+=1)t.each((r,o,s)=>{const a=s[o];if(!a._visible)return;const u=a.getBoundingClientRect();for(let d=o+1;d<s.length;d+=1){if(o===d)continue;const f=s[d];if(f._visible){const g=f.getBoundingClientRect();if(Yh(u,g,-5)){f._visible=!1;break}}}});t.each((i,r,o)=>{const s=o[r];ce(s).style("opacity",s._visible?1:0)})}_getNumTicks(){const{config:{type:t,numTicks:n}}=this;if(n)return n;if(t===W.X){const i=this.xScale.range(),r=i[1]-i[0];return Math.floor(r/175)}if(t===W.Y){const i=this.yScale.range(),r=Math.abs(i[0]-i[1]);return Math.pow(r,.85)/25}return this._defaultNumTicks}_getConfiguredTickValues(){const{config:t}=this,n=t.type===W.X?this.xScale:this.yScale,i=n==null?void 0:n.domain();return t.tickValues?t.tickValues.filter(r=>r>=i[0]&&r<=i[1]):t.minMaxTicksOnly||t.type===W.X&&this._width<t.minMaxTicksOnlyWhenWidthIsLess?i:null}_getFullDomainPath(t=0){const{config:{type:n}}=this;switch(n){case W.X:return`M0.5, ${t} V0.5 H${this._width+.5} V${t}`;case W.Y:return`M${-t}, ${this._height+.5} H0.5 V0.5 H${-t}`}}_renderAxisLabel(t=this.axisGroup){var n;const{type:i,label:r,labelMargin:o,labelFontSize:s}=this.config;t.selectAll(`.${uo}`).remove();const a=this.getPosition(),{width:l,height:u}=(n=this._axisRawBBox)!==null&&n!==void 0?n:t.node().getBBox(),d=i===W.X?this._width/2:Math.pow(-1,+(a===$.Left))*l,f=i===W.X?Math.pow(-1,+(a===$.Top))*u:this._height/2,h=i===W.X?0:Math.pow(-1,+(a===$.Left))*o,g=i===W.X?Math.pow(-1,+(a===$.Top))*o:0,m=i===W.Y?-90:0;t.append("text").attr("class",uo).text(r).attr("dy",`${this._getLabelDY()}em`).attr("transform",`translate(${d+h},${f+g}) rotate(${m})`).style("font-size",s).style("fill",this.config.labelColor)}_getLabelDY(){const{type:t,position:n}=this.config;switch(t){case W.X:switch(n){case $.Top:return 0;case $.Bottom:default:return .75}case W.Y:switch(n){case $.Right:return .75;case $.Left:default:return-.25}}}_alignTickLabels(){const{config:{type:t,tickTextAlign:n,tickTextAngle:i,position:r}}=this,o=this.g.selectAll("g.tick > text"),s=this._getTickTextAnchor(n),a=t===W.X?0:this._getYTickTextTranslate(n,r),l=i?`translate(${a},0) rotate(${i})`:`translate(${a},0)`;o.attr("transform",l).attr("text-anchor",s)}_getTickTextAnchor(t){switch(t){case Ae.Left:return"start";case Ae.Right:return"end";case Ae.Center:return"middle";default:return null}}_getYTickTextTranslate(t,n=$.Left){const r=this._axisRawBBox.width-9;switch(t){case Ae.Left:return n===$.Left?r*-1:0;case Ae.Right:return n===$.Left?0:r;case Ae.Center:return n===$.Left?r*-.5:r*.5;default:return 0}}}Zu.selectors=k_;var Be;(function(e){e.Circle="circle",e.Cross="cross",e.Diamond="diamond",e.Square="square",e.Star="star",e.Triangle="triangle",e.Wye="wye"})(Be||(Be={}));const T_={[Be.Circle]:Tu,[Be.Cross]:iv,[Be.Diamond]:ov,[Be.Square]:sv,[Be.Star]:cv,[Be.Triangle]:dv,[Be.Wye]:hv},Se=Object.assign(Object.assign({},Be),{Line:"line"});var Fi;(function(e){e.Horizontal="horizontal",e.Vertical="vertical"})(Fi||(Fi={}));const R_={items:[],labelClassName:"",onLegendItemClick:void 0,labelFontSize:null,labelMaxWidth:null,bulletSize:null,bulletShape:e=>{var t;return(t=e.shape)!==null&&t!==void 0?t:Se.Circle},orientation:Fi.Horizontal,renderIntoProvidedDomNode:!1},xr=Cn*3,$_={[Se.Circle]:Math.PI/4,[Se.Cross]:5/9,[Se.Diamond]:Math.sqrt(3)/6,[Se.Square]:1,[Se.Star]:.3,[Se.Triangle]:Math.sqrt(3)/4,[Se.Wye]:5/11};function M_(e){e.each((t,n,i)=>{ce(i[n]).append("svg").attr("width","100%").attr("height","100%").append("path")})}function E_(e,t,n){e.each((i,r,o)=>{const s=zt(i,t.bulletShape,r),a=_e(i,n,r),l=xr,u=s===Se.Line?xr/2.5:xr,f=ce(o[r]).select("svg").attr("viewBox",`0 0 ${l} ${u}`).select("path").attr("stroke",a),h=i.inactive?"var(--vis-legend-bullet-inactive-opacity)":1;if(s===Se.Line)f.attr("d",`M0,${u/2} L${l/2},${u/2} L${l},${u/2}`).attr("transform",null).style("opacity",h).style("stroke-width","3px").style("fill",null).style("fill-opacity",null).style("marker-start","none").style("marker-end","none");else{const g=gv().type(T_[s]).size(l*u*$_[s]),m=(l-2)/l;let p=u/2;switch(s){case Se.Triangle:p+=u/8;break;case Se.Star:p+=u/16;break;case Se.Wye:p-=u/16;break}f.attr("d",g).attr("transform",`translate(${l/2}, ${Math.round(p)}) scale(${m})`).style("stroke-width","1px").style("opacity",null).style("fill",a).style("fill-opacity",h)}})}const ss=P`
|
|
286
|
-
label: bullet-legend-component;
|
|
287
|
-
`,A_=ot`
|
|
288
|
-
:root {
|
|
289
|
-
// Undefined by default to allow proper fallback to var(--vis-font-family)
|
|
290
|
-
/* --vis-legend-font-family: */
|
|
291
|
-
|
|
292
|
-
--vis-legend-label-color: #6c778c;
|
|
293
|
-
--vis-legend-label-max-width: 300px;
|
|
294
|
-
--vis-legend-label-font-size: 12px;
|
|
295
|
-
--vis-legend-bullet-size: 9px;
|
|
296
|
-
--vis-legend-bullet-inactive-opacity: 0.15;
|
|
297
|
-
--vis-legend-item-spacing: 20px;
|
|
298
|
-
--vis-legend-vertical-item-spacing: 5px;
|
|
299
|
-
--vis-legend-bullet-label-spacing: 8px;
|
|
300
|
-
|
|
301
|
-
--vis-dark-legend-label-color: #eee;
|
|
302
|
-
}
|
|
303
|
-
|
|
304
|
-
body.theme-dark ${`.${ss}`} {
|
|
305
|
-
--vis-legend-label-color: var(--vis-dark-legend-label-color);
|
|
306
|
-
}
|
|
307
|
-
|
|
308
|
-
body.theme-patterns {
|
|
309
|
-
--vis-legend-bullet-size: 14px;
|
|
310
|
-
}
|
|
311
|
-
`,si=P`
|
|
312
|
-
label: legendItem;
|
|
313
|
-
display: inline-flex;
|
|
314
|
-
align-items: center;
|
|
315
|
-
font-family: var(--vis-legend-font-family, var(--vis-font-family));
|
|
316
|
-
margin-right: var(--vis-legend-item-spacing);
|
|
317
|
-
white-space: nowrap;
|
|
318
|
-
cursor: default;
|
|
319
|
-
user-select: none;
|
|
320
|
-
max-width: min-content;
|
|
321
|
-
`,Qu=P`
|
|
322
|
-
label: legendItemVertical;
|
|
323
|
-
display: flex;
|
|
324
|
-
margin-top: var(--vis-legend-vertical-item-spacing);
|
|
325
|
-
`,Ku=P`
|
|
326
|
-
cursor: pointer;
|
|
327
|
-
`,co=P`
|
|
328
|
-
label: legendItemLabel;
|
|
329
|
-
font-size: var(--vis-legend-label-font-size);
|
|
330
|
-
display: inline-block;
|
|
331
|
-
vertical-align: middle;
|
|
332
|
-
color: var(--vis-legend-label-color);
|
|
333
|
-
max-width: var(--vis-legend-label-max-width);
|
|
334
|
-
text-overflow: ellipsis;
|
|
335
|
-
overflow: hidden;
|
|
336
|
-
white-space: nowrap;
|
|
337
|
-
`,fo=P`
|
|
338
|
-
flex: 0 0 auto;
|
|
339
|
-
label: legendItemBullet;
|
|
340
|
-
margin-right: var(--vis-legend-bullet-label-spacing);
|
|
341
|
-
height: var(--vis-legend-bullet-size);
|
|
342
|
-
width: var(--vis-legend-bullet-size);
|
|
343
|
-
|
|
344
|
-
svg {
|
|
345
|
-
display: block;
|
|
346
|
-
}
|
|
347
|
-
`,F_=Object.freeze(Object.defineProperty({__proto__:null,bullet:fo,clickable:Ku,item:si,itemVertical:Qu,label:co,root:ss,variables:A_},Symbol.toStringTag,{value:"Module"}));class Ju{constructor(t,n){this._defaultConfig=R_,this.config=this._defaultConfig,this._colorAccessor=i=>i.color,this._container=t,this.div=n!=null&&n.renderIntoProvidedDomNode?ce(this._container):ce(this._container).append("div"),this.div.classed(ss,!0),this.element=this.div.node(),n&&this.update(n)}update(t){this.prevConfig=this.config,this.config=$t(this._defaultConfig,t),this.render()}render(){const{config:t}=this,n=this.div.selectAll(`.${si}`).data(t.items),i=n.enter().append("div").on("click",this._onItemClick.bind(this)),r=i.merge(n);r.attr("class",o=>{var s;return`${si} ${(s=o.className)!==null&&s!==void 0?s:""}`}).classed(Qu,t.orientation===Fi.Vertical).classed(Ku,o=>!!t.onLegendItemClick&&this._isItemClickable(o)).attr("title",o=>o.name).style("display",o=>o.hidden?"none":null),i.append("span").attr("class",fo).call(M_),r.select(`.${fo}`).style("width",t.bulletSize).style("height",t.bulletSize).style("box-sizing","content-box").call(E_,this.config,this._colorAccessor),i.append("span").attr("class",co).classed(t.labelClassName,!0).style("max-width",t.labelMaxWidth).style("font-size",t.labelFontSize),r.select(`.${co}`).text(o=>o.name),n.exit().remove()}_isItemClickable(t){return t.pointer===void 0?!0:t.pointer}_onItemClick(t,n){const{config:{onLegendItemClick:i}}=this,o=this.div.selectAll(`.${si}`).nodes().indexOf(t.currentTarget);i&&i(n,o)}destroy(){this.element!==this._container&&this.div.remove()}}Ju.selectors=F_;const V_=Object.assign(Object.assign({},Zt),{yStacked:void 0,baseline:null,duration:100,tooltip:void 0,template:(e,t)=>"",hideWhenFarFromPointer:!0,hideWhenFarFromPointerDistance:100,snapToData:!0,getCircles:void 0,color:void 0,strokeColor:void 0,strokeWidth:void 0}),N_=ot`
|
|
348
|
-
:root {
|
|
349
|
-
--vis-crosshair-line-stroke-color: #888;
|
|
350
|
-
--vis-crosshair-line-stroke-width: 1px;
|
|
351
|
-
--vis-crosshair-line-stroke-opacity: 1;
|
|
352
|
-
--vis-crosshair-circle-stroke-color: #fff;
|
|
353
|
-
--vis-crosshair-circle-stroke-width: 1px;
|
|
354
|
-
--vis-crosshair-circle-stroke-opacity: 0.75;
|
|
355
|
-
}
|
|
356
|
-
`,D_=P`
|
|
357
|
-
label: crosshair-component;
|
|
358
|
-
`,ec=P`
|
|
359
|
-
stroke: var(--vis-crosshair-line-stroke-color);
|
|
360
|
-
stroke-width: var(--vis-crosshair-line-stroke-width);
|
|
361
|
-
stroke-opacity: var(--vis-crosshair-line-stroke-opacity);
|
|
362
|
-
pointer-events: none;
|
|
363
|
-
`,tc=P`
|
|
364
|
-
stroke: var(--vis-crosshair-circle-stroke-color);
|
|
365
|
-
stroke-width: var(--vis-crosshair-circle-stroke-width);
|
|
366
|
-
stroke-opacity: var(--vis-crosshair-circle-stroke-opacity);
|
|
367
|
-
pointer-events: none;
|
|
368
|
-
`,P_=Object.freeze(Object.defineProperty({__proto__:null,circle:tc,globalStyles:N_,line:ec,root:D_},Symbol.toStringTag,{value:"Module"}));class nc extends Fn{constructor(t){super(),this.clippable=!0,this._defaultConfig=V_,this.config=this._defaultConfig,this.x=0,this.show=!1,this._animFrameId=null,this._accessors={x:void 0,y:void 0,yStacked:void 0,baseline:void 0},t&&this.setConfig(t),this.g.style("opacity",this.show?1:0),this.line=this.g.append("line").attr("class",ec)}set accessors(t){this._accessors=t}get accessors(){var t;const{config:n}=this,i=!!(n.x||n.y||n.yStacked),r=i?n.x:this._accessors.x,o=i?n.y:this._accessors.y,s=o?et(o)?o:[o]:void 0,a=i?n.yStacked:this._accessors.yStacked,l=(t=n.baseline)!==null&&t!==void 0?t:this._accessors.baseline;return{x:r,y:s,yStacked:a,baseline:l}}setContainer(t){this.container=t,this.container.on("mousemove.crosshair",this._onMouseMove.bind(this)),this.container.on("mouseout.crosshair",this._onMouseOut.bind(this))}_render(t){const{config:n}=this;if(n.snapToData&&!this.datum)return;const i=be(t)?t:n.duration;Z(this.g,i).style("opacity",this.show?1:0),this.line.attr("y1",0).attr("y1",this._height),Z(this.line,i,ea).attr("x1",this.x).attr("x2",this.x);const r=this.getCircleData(),o=this.g.selectAll("circle").data(r,(a,l)=>{var u;return(u=a.id)!==null&&u!==void 0?u:l}),s=o.enter().append("circle").attr("class",tc).attr("r",0).attr("cx",this.x).attr("cy",a=>a.y).style("fill",a=>a.color).style("stroke",a=>a.strokeColor).style("stroke-width",a=>a.strokeWidth);Z(s.merge(o),i,ea).attr("cx",this.x).attr("cy",a=>a.y).attr("r",4).style("opacity",a=>a.opacity).style("fill",a=>a.color).style("stroke",a=>a.strokeColor).style("stroke-width",a=>a.strokeWidth),o.exit().remove()}hide(){this._onMouseOut()}_onMouseMove(t){var n,i;const{config:r,datamodel:o,element:s}=this;!this.accessors.x&&(!((n=o.data)===null||n===void 0)&&n.length)&&console.warn("Unovis | Crosshair: X accessor function has not been configured. Please check if it's present in the configuration object");const[a]=li(t,s),l=this.xScale.range();if(r.snapToData){!this.accessors.y&&!this.accessors.yStacked&&(!((i=o.data)===null||i===void 0)&&i.length)&&console.warn("Unovis | Crosshair: Y accessors have not been configured. Please check if they're present in the configuration object");const u=this.xScale,d=u.invert(a);if(this.datum=Nf(o.data,d,this.accessors.x),this.datumIndex=o.data.indexOf(this.datum),!this.datum)return;this.x=He(Math.round(u(X(this.datum,this.accessors.x,this.datumIndex))),0,this._width),this.show=this.x>=0&&this.x<=this._width&&(!r.hideWhenFarFromPointer||Math.abs(this.x-a)<r.hideWhenFarFromPointerDistance)}else this.x=He(a,l[0],l[1]),this.show=a>=l[0]-2&&a<=l[1]+2;window.cancelAnimationFrame(this._animFrameId),this._animFrameId=window.requestAnimationFrame(()=>{this._render()}),this.show?this._showTooltip(t):this._hideTooltip()}_onMouseOut(){this.show=!1,window.cancelAnimationFrame(this._animFrameId),this._animFrameId=window.requestAnimationFrame(()=>{this._render()}),this._hideTooltip()}_showTooltip(t){var n;const{config:i}=this,r=(n=i.tooltip)!==null&&n!==void 0?n:this.tooltip;if(!r)return;const o=r.getContainer()||this.container.node(),[s,a]=r.isContainerBody()?[t.clientX,t.clientY]:li(t,o),l=i.template(this.datum,this.xScale.invert(this.x));if(r.config.followCursor=!0,!r.config.horizontalPlacement||r.config.horizontalPlacement===$.Auto){const u=r.isContainerBody()?s-this.container.node().getBoundingClientRect().left:s;r.overrideHorizontalPlacement(u>this._containerWidth/2?$.Left:$.Right)}l&&r.show(l,{x:s,y:a})}_hideTooltip(){var t;const{config:n}=this,i=(t=n.tooltip)!==null&&t!==void 0?t:this.tooltip;i==null||i.hide()}getYDataExtent(){return[void 0,void 0]}getCircleData(){var t,n;const{config:i,datamodel:{data:r}}=this;if(bo(i.getCircles))return i.getCircles(this.xScale.invert(this.x),r,this.yScale);if(i.snapToData&&this.datum){const o=(t=this.accessors.y)!==null&&t!==void 0?t:[],s=(n=this.accessors.yStacked)!==null&&n!==void 0?n:[],a=X(this.datum,this.accessors.baseline,this.datumIndex)||0,l=Ff(this.datum,this.datumIndex,...s).map((d,f,h)=>({y:this.yScale(d+a),opacity:be(X(this.datum,s[f]))?1:0,color:_e(this.datum,i.color,f),strokeColor:i.strokeColor?_e(this.datum,i.strokeColor,f):void 0,strokeWidth:i.strokeWidth?X(this.datum,i.strokeWidth,f):void 0})),u=o.map((d,f)=>{const h=X(this.datum,d);return{y:this.yScale(h),opacity:be(h)?1:0,color:_e(this.datum,i.color,l.length+f),strokeColor:i.strokeColor?_e(this.datum,i.strokeColor,f):void 0,strokeWidth:i.strokeWidth?X(this.datum,i.strokeWidth,f):void 0}});return l.concat(u)}return[]}}nc.selectors=P_;const O_=Object.assign(Object.assign({},Zt),{color:void 0,curveType:Y.MonotoneX,baseline:()=>0,opacity:1,cursor:null,minHeight1Px:!1}),ic=P`
|
|
369
|
-
label: area-component;
|
|
370
|
-
`,L_=ot`
|
|
371
|
-
:root {
|
|
372
|
-
--vis-area-cursor: default;
|
|
373
|
-
--vis-area-fill-opacity: 1;
|
|
374
|
-
--vis-area-stroke-color: none;
|
|
375
|
-
--vis-area-stroke-width: 0px;
|
|
376
|
-
--vis-area-stroke-dasharray: none;
|
|
377
|
-
--vis-area-stroke-opacity: 1;
|
|
378
|
-
--vis-area-hover-fill-opacity: none;
|
|
379
|
-
--vis-area-hover-stroke-width: none;
|
|
380
|
-
|
|
381
|
-
/* Dark Theme */
|
|
382
|
-
--vis-dark-area-stroke-color: none;
|
|
383
|
-
}
|
|
384
|
-
|
|
385
|
-
body.theme-dark ${`.${ic}`} {
|
|
386
|
-
--vis-area-stroke-color: var(--vis-dark-area-stroke-color);
|
|
387
|
-
}
|
|
388
|
-
|
|
389
|
-
`,ho=P`
|
|
390
|
-
label: area;
|
|
391
|
-
cursor: var(--vis-area-cursor);
|
|
392
|
-
fill-opacity: var(--vis-area-fill-opacity);
|
|
393
|
-
stroke-width: var(--vis-area-stroke-width);
|
|
394
|
-
stroke-dasharray: var(--vis-area-stroke-dasharray);
|
|
395
|
-
stroke: var(--vis-area-stroke-color);
|
|
396
|
-
stroke-opacity: var(--vis-area-stroke-opacity);
|
|
397
|
-
|
|
398
|
-
&:hover {
|
|
399
|
-
fill-opacity: var(--vis-area-hover-fill-opacity);
|
|
400
|
-
stroke-width: var(--vis-area-hover-stroke-width);
|
|
401
|
-
}
|
|
402
|
-
`,I_=Object.freeze(Object.defineProperty({__proto__:null,area:ho,globalStyles:L_,root:ic},Symbol.toStringTag,{value:"Module"}));class Ji extends Fn{constructor(t){super(),this._defaultConfig=O_,this.config=this._defaultConfig,this.stacked=!0,this.events={[Ji.selectors.area]:{}},t&&this.setConfig(t),this.stacked=Array.isArray(this.config.y)}_render(t){super._render(t);const{config:n,datamodel:{data:i}}=this,r=be(t)?t:n.duration,o=no[n.curveType];this._areaGen=J0().x(p=>p.x).y0(p=>p.y0).y1(p=>{const v=Math.abs(p.y1-p.y0)<1;return p.y1-(v&&n.minHeight1Px?1:0)}).curve(o);const s=et(n.y)?n.y:[n.y],a=i.map((p,v)=>this.xScale(X(p,n.x,v))),l=Vf(i,n.baseline,s,this._prevNegative);this._prevNegative=l.map(p=>!!p.isMostlyNegative);const u=l.map(p=>p.map((v,_)=>({y0:this.yScale(v[0]),y1:this.yScale(v[1]),x:a[_]}))),d=u.length-1,f=u.reverse(),h=this.g.selectAll(`.${ho}`).data(f),g=h.enter().append("path").attr("class",ho).attr("d",p=>this._areaGen(p)||this._emptyPath()).style("opacity",0).style("fill",(p,v)=>_e(i,n.color,d-v)),m=Z(g.merge(h),r).style("opacity",(p,v)=>p.some(y=>y.y0-y.y1!==0)?X(i,n.opacity,d-v):0).style("fill",(p,v)=>_e(i,n.color,d-v)).style("cursor",(p,v)=>zt(i,n.cursor,d-v));r?m.attrTween("d",(v,_,y)=>{const x=ce(y[_]).attr("d"),w=this._areaGen(v)||this._emptyPath();return Bu(x,w)}):m.attr("d",p=>this._areaGen(p)||this._emptyPath()),Z(h.exit(),r).style("opacity",0).remove()}getYDataExtent(t){const{config:n,datamodel:i}=this,r=et(n.y)?n.y:[n.y],o=t?dl(i.data,this.xScale.domain(),n.x):i.data;return Af(o,n.baseline,...r)}_emptyPath(){const t=this.xScale.range(),n=this.yScale.domain(),i=this.yScale((n[0]+n[1])/2),r=i;return this._areaGen([{y0:i,y1:r,x:t[0]},{y0:i,y1:r,x:t[1]}])}}Ji.selectors=I_;const B_=Object.assign(Object.assign({},Qo),{id:(e,t)=>{var n;return(n=e.id)!==null&&n!==void 0?n:t},value:void 0,angleRange:[0,2*Math.PI],padAngle:0,sortFunction:void 0,cornerRadius:0,color:void 0,radius:void 0,arcWidth:20,centralLabel:void 0,centralSubLabel:void 0,centralSubLabelWrap:!0,showEmptySegments:!1,emptySegmentAngle:.5*Math.PI/180,showBackground:!0,backgroundAngleRange:void 0,centralLabelOffsetX:void 0,centralLabelOffsetY:void 0});function z_(e,t){e.style("fill",n=>_e(n.data,t.color,n.index)).style("opacity",0).each((n,i,r)=>{const o=r[i],s=(n.startAngle+n.endAngle)/2,a=(n.endAngle-n.startAngle)/2;o._animState={startAngle:s-a,endAngle:s+a,innerRadius:n.innerRadius,outerRadius:n.outerRadius,padAngle:n.padAngle}})}function H_(e,t,n,i){e.style("transition",`fill ${i}ms`).style("fill",o=>_e(o.data,t.color,o.index));const r=o=>t.showEmptySegments||o.value?1:0;i?Z(e,i).style("opacity",r).attrTween("d",(s,a,l)=>{const u=l[a],d={startAngle:s.startAngle,endAngle:s.endAngle,innerRadius:s.innerRadius,outerRadius:s.outerRadius,padAngle:s.padAngle},f=At(u._animState,d);return h=>(u._animState=f(h),n(u._animState))}):e.attr("d",n).style("opacity",r)}function G_(e,t){Z(e,t).style("opacity",0).remove()}const rc=Array.from({length:4},(e,t)=>{const n=-Math.PI/2+t*Math.PI/2;return[n,n+Math.PI]}),[cx,dx,fx,hx]=rc,oc=P`
|
|
403
|
-
label: donut-component;
|
|
404
|
-
`,U_=ot`
|
|
405
|
-
:root {
|
|
406
|
-
--vis-donut-central-label-font-size: 16px;
|
|
407
|
-
--vis-donut-central-label-text-color: #5b5f6d;
|
|
408
|
-
// Undefined by default to allow proper fallback to var(--vis-font-family)
|
|
409
|
-
/* --vis-donut-central-label-font-family: */
|
|
410
|
-
--vis-donut-central-label-font-weight: 600;
|
|
411
|
-
|
|
412
|
-
--vis-donut-central-sub-label-font-size: 12px;
|
|
413
|
-
--vis-donut-central-sub-label-text-color: #5b5f6d;
|
|
414
|
-
// Undefined by default to allow proper fallback to var(--vis-font-family)
|
|
415
|
-
/* --vis-donut-central-sub-label-font-family: */
|
|
416
|
-
--vis-donut-central-sub-label-font-weight: 500;
|
|
417
|
-
|
|
418
|
-
--vis-donut-background-color: #E7E9F3;
|
|
419
|
-
--vis-donut-segment-stroke-width: 0;
|
|
420
|
-
// The line segment color variable is not defined by default
|
|
421
|
-
// to allow it to fallback to the donut background color
|
|
422
|
-
/* --vis-donut-segment-stroke-color: none; */
|
|
423
|
-
|
|
424
|
-
--vis-dark-donut-central-label-text-color: #C2BECE;
|
|
425
|
-
--vis-dark-donut-central-sub-label-text-color: #C2BECE;
|
|
426
|
-
--vis-dark-donut-background-color: #18160C;
|
|
427
|
-
}
|
|
428
|
-
|
|
429
|
-
body.theme-dark ${`.${oc}`} {
|
|
430
|
-
--vis-donut-central-label-text-color: var(--vis-dark-donut-central-label-text-color);
|
|
431
|
-
--vis-donut-central-sub-label-text-color: var(--vis-dark-donut-central-sub-label-text-color);
|
|
432
|
-
--vis-donut-background-color: var(--vis-dark-donut-background-color);
|
|
433
|
-
}
|
|
434
|
-
`,sc=P`
|
|
435
|
-
label: background;
|
|
436
|
-
fill: var(--vis-donut-background-color);
|
|
437
|
-
`,go=P`
|
|
438
|
-
label: segment;
|
|
439
|
-
stroke-width: var(--vis-donut-segment-stroke-width);
|
|
440
|
-
stroke: var(--vis-donut-segment-stroke-color, var(--vis-donut-background-color));
|
|
441
|
-
`,ac=P`
|
|
442
|
-
label: segment-exit;
|
|
443
|
-
`,lc=P`
|
|
444
|
-
label: central-label;
|
|
445
|
-
text-anchor: middle;
|
|
446
|
-
dominant-baseline: middle;
|
|
447
|
-
font-size: var(--vis-donut-central-label-font-size);
|
|
448
|
-
font-family: var(--vis-donut-central-label-font-family, var(--vis-font-family));
|
|
449
|
-
font-weight: var(--vis-donut-central-label-font-weight);
|
|
450
|
-
fill: var(--vis-donut-central-label-text-color);
|
|
451
|
-
`,uc=P`
|
|
452
|
-
label: central-label;
|
|
453
|
-
text-anchor: middle;
|
|
454
|
-
dominant-baseline: middle;
|
|
455
|
-
font-size: var(--vis-donut-central-sub-label-font-size);
|
|
456
|
-
font-family: var(--vis-donut-central-sub-label-font-family, var(--vis-font-family));
|
|
457
|
-
font-weight: var(--vis-donut-central-sub-label-font-weight);
|
|
458
|
-
fill: var(--vis-donut-central-sub-label-text-color);
|
|
459
|
-
`,W_=Object.freeze(Object.defineProperty({__proto__:null,background:sc,centralLabel:lc,centralSubLabel:uc,root:oc,segment:go,segmentExit:ac,variables:U_},Symbol.toStringTag,{value:"Module"}));class as extends mu{constructor(t){super(),this._defaultConfig=B_,this.config=this._defaultConfig,this.datamodel=new vu,this.arcGen=K0(),this.events={},t&&this.setConfig(t),this.arcBackground=this.g.append("path"),this.arcGroup=this.g.append("g"),this.centralLabel=this.g.append("text").attr("class",lc),this.centralSubLabel=this.g.append("text").attr("class",uc)}get bleed(){return{top:0,bottom:0,left:0,right:0}}_render(t){var n,i,r,o,s,a,l,u,d,f,h,g,m,p;const{config:v,datamodel:_,bleed:y}=this,x=_.data.map((N,ue)=>({index:ue,datum:N})).filter(N=>v.showEmptySegments||X(N.datum,v.value,N.index)),w=be(t)?t:v.duration,[S,b,C,V]=rc.map(N=>v.angleRange&&v.angleRange[0]===N[0]&&v.angleRange[1]===N[1]),F=S||C,U=b||V,M=this._width*(U?2:1),I=this._height*(F?2:1),T=v.radius||Math.min(M-y.left-y.right,I-y.top-y.bottom)/2,D=v.arcWidth===0?0:He(T-v.arcWidth,0,T-1),ie=this._height/2+(S?T/2:C?-T/2:0),de=this._width/2+(V?T/2:b?-T/2:0),re=`translate(${de},${ie})`;this.arcGroup.attr("transform",re),this.arcGen.startAngle(N=>N.startAngle).endAngle(N=>N.endAngle).innerRadius(N=>N.innerRadius).outerRadius(N=>N.outerRadius).padAngle(N=>N.padAngle).cornerRadius(v.cornerRadius);const J=nv().startAngle((i=(n=v.angleRange)===null||n===void 0?void 0:n[0])!==null&&i!==void 0?i:0).endAngle((o=(r=v.angleRange)===null||r===void 0?void 0:r[1])!==null&&o!==void 0?o:2*Math.PI).padAngle(v.padAngle).value(N=>X(N.datum,v.value,N.index)||0).sort((N,ue)=>{var R;return(R=v.sortFunction)===null||R===void 0?void 0:R.call(v,N.datum,ue.datum)})(x).map(N=>{const ue=Object.assign(Object.assign({},N),{data:N.data.datum,index:N.data.index,innerRadius:D,outerRadius:T});return v.showEmptySegments&&N.endAngle-N.startAngle-N.padAngle<=Number.EPSILON&&(ue.endAngle=N.startAngle+Math.max(v.emptySegmentAngle,v.padAngle),ue.padAngle=N.padAngle/2),ue}),Oe=this.arcGroup.selectAll(`.${go}`).data(J,N=>v.id(N.data,N.index)),st=Oe.enter().append("path").attr("class",go).call(z_,v),qe=Oe.merge(st);qe.call(H_,v,this.arcGen,w),qe.sort((N,ue)=>ue.value-N.value),Oe.exit().attr("class",ac).call(G_,w);const at=b?"start":V?"end":"middle";this.centralLabel.attr("dy",v.centralSubLabel?"-0.55em":null).style("text-anchor",at).text((s=v.centralLabel)!==null&&s!==void 0?s:null),this.centralSubLabel.attr("dy",v.centralLabel?"0.55em":null).style("text-anchor",at).text((a=v.centralSubLabel)!==null&&a!==void 0?a:null),v.centralSubLabelWrap&&p_(this.centralSubLabel,D*1.9);const _t=(v.centralLabelOffsetX||0)+de;let he=(v.centralLabelOffsetY||0)+ie;F&&v.centralLabelOffsetX===void 0&&v.centralLabelOffsetY===void 0&&(he=(S?-this.centralSubLabel.node().getBoundingClientRect().height:C?this.centralLabel.node().getBoundingClientRect().height:0)+ie);const lt=`translate(${_t},${he})`;this.centralLabel.attr("transform",lt),this.centralSubLabel.attr("transform",lt),this.arcBackground.attr("class",sc).attr("visibility",v.showBackground?null:"hidden").attr("transform",re),Z(this.arcBackground,w).attr("d",this.arcGen({startAngle:(f=(u=(l=v.backgroundAngleRange)===null||l===void 0?void 0:l[0])!==null&&u!==void 0?u:(d=v.angleRange)===null||d===void 0?void 0:d[0])!==null&&f!==void 0?f:0,endAngle:(p=(g=(h=v.backgroundAngleRange)===null||h===void 0?void 0:h[1])!==null&&g!==void 0?g:(m=v.angleRange)===null||m===void 0?void 0:m[1])!==null&&p!==void 0?p:2*Math.PI,innerRadius:D,outerRadius:T}))}}as.selectors=W_;const Qt=Symbol("componentAccessorKey"),ls=Symbol("tooltipAccessorKey"),cc=Symbol("crosshairAccessorKey"),dc=Symbol("axisAccessorKey"),fc=Symbol("annotationsAccessorKey");function vt(e,t){return _n(e,t)}function Ye(e){const t=c.getCurrentInstance(),n=t.attrs;return c.computed(()=>{const i={},r=(t==null?void 0:t.vnode.props)??{};return Object.keys(r).forEach(o=>{i[c.camelize(o)]=e[c.camelize(o)]}),{...i,...n}})}const us=c.defineComponent({__name:"index",props:{components:{},xScale:{type:[Object,Function]},xDomain:{},xDomainMinConstraint:{},xDomainMaxConstraint:{},xRange:{},yScale:{type:[Object,Function]},yDomain:{},yDomainMinConstraint:{},yDomainMaxConstraint:{},yRange:{},yDirection:{},xAxis:{},yAxis:{},autoMargin:{type:Boolean},tooltip:{},crosshair:{},preventEmptyDomain:{type:[Boolean,null]},scaleByDomain:{type:Boolean},annotations:{},duration:{},margin:{},padding:{},sizing:{},width:{},height:{},svgDefs:{},ariaLabel:{},data:{}},setup(e,{expose:t}){const n=e,{data:i}=c.toRefs(n),r=Ye(n),o=c.ref(),s=c.reactive({components:[],annotations:void 0,crosshair:void 0,tooltip:void 0,xAxis:void 0,yAxis:void 0}),a=c.ref();return c.watch(i,()=>{o.value&&o.value.setData(i.value,!0)}),c.watchEffect(()=>{var l;s.components.map(u=>u.config),(l=o.value)==null||l.updateContainer({...c.toRaw(r.value),...c.toRaw(s)})}),c.onMounted(()=>{a.value&&(o.value=new P0(a.value,{...c.toRaw(s)},i.value))}),c.onUnmounted(()=>{var l;return(l=o.value)==null?void 0:l.destroy()}),c.provide(Qt,{data:i,update:l=>s.components=[...s.components,l],destroy:()=>{var l;return s.components=(l=s.components)==null?void 0:l.filter(u=>!u.isDestroyed())}}),c.provide(dc,{data:i,update:l=>s[`${l.config.type}Axis`]=l,destroy:l=>{s[`${l}Axis`]=void 0}}),c.provide(cc,{data:i,update:l=>s.crosshair=l,destroy:()=>{s.crosshair=void 0}}),c.provide(ls,{data:i,update:l=>s.tooltip=l,destroy:()=>{s.tooltip=void 0}}),c.provide(fc,{data:i,update:l=>s.annotations=l,destroy:()=>{s.annotations=void 0}}),t({component:o}),(l,u)=>(c.openBlock(),c.createElementBlock("div",{"data-vis-xy-container":"",ref_key:"elRef",ref:a,class:"unovis-xy-container"},[c.renderSlot(l.$slots,"default")],512))}}),Y_=c.defineComponent({__name:"index",props:{component:{},tooltip:{},annotations:{},duration:{},margin:{},padding:{},sizing:{},width:{},height:{},svgDefs:{},ariaLabel:{},data:{}},setup(e,{expose:t}){const n=e,{data:i}=c.toRefs(n),r=Ye(n);let o;const s=c.reactive({component:void 0,tooltip:void 0,annotations:void 0}),a=c.ref(),l=()=>{o||a.value&&s.component&&(o=new zp(a.value,{...c.toRaw(s)},i.value))};return c.watchEffect(()=>{var u;l(),(u=s.component)==null||u.config,o==null||o.updateContainer({...c.toRaw(r.value),...c.toRaw(s)})}),c.watch(i,()=>{o?o.setData(i.value,!0):l()}),c.onUnmounted(()=>o==null?void 0:o.destroy()),c.provide(Qt,{data:i,update:u=>s.component=u,destroy:()=>s.component=void 0}),c.provide(ls,{data:i,update:u=>s.tooltip=u,destroy:()=>{s.tooltip=void 0}}),c.provide(fc,{data:i,update:u=>s.annotations=u,destroy:()=>{s.annotations=void 0}}),t({component:o}),(u,d)=>(c.openBlock(),c.createElementBlock("div",{"data-vis-single-container":"",ref_key:"elRef",ref:a,class:"unovis-single-container"},[c.renderSlot(u.$slots,"default")],512))}}),q_={"data-vis-component":""},X_=c.defineComponent({__name:"index",props:{color:{},curveType:{},baseline:{},opacity:{},cursor:{},minHeight1Px:{type:Boolean},x:{},y:{},id:{type:Function},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(e,{expose:t}){const n=c.inject(Qt),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new Ji(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy()}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",q_))}}),j_={"data-vis-axis":""},Xt=c.defineComponent({__name:"index",props:{position:{},type:{},fullSize:{type:Boolean},label:{},labelFontSize:{},labelMargin:{},labelColor:{},gridLine:{type:Boolean},tickLine:{type:Boolean},domainLine:{type:Boolean},minMaxTicksOnly:{type:Boolean},minMaxTicksOnlyWhenWidthIsLess:{},tickFormat:{type:Function},tickValues:{},numTicks:{},tickTextFitMode:{},tickTextWidth:{},tickTextSeparator:{},tickTextForceWordBreak:{type:Boolean},tickTextTrimType:{},tickTextFontSize:{},tickTextAlign:{},tickTextColor:{},tickTextAngle:{},tickTextHideOverlapping:{type:Boolean},tickPadding:{},x:{},y:{},id:{type:Function},color:{},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(e,{expose:t}){const n=c.inject(dc),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new Zu(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy(i.type)}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",j_))}}),Z_={"data-vis-crosshair":""},hc=c.defineComponent({__name:"index",props:{data:{}},setup(e,{expose:t}){const n=c.inject(cc),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new nc(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy()}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",Z_))}}),Q_={"data-vis-component":""};Qi.selectors;const K_=c.defineComponent({__name:"index",props:{color:{},groupWidth:{},groupMaxWidth:{},dataStep:{},groupPadding:{},barPadding:{},roundedCorners:{type:[Number,Boolean]},barMinHeight:{},cursor:{},orientation:{},x:{},y:{},id:{type:Function},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(e,{expose:t}){const n=c.inject(Qt),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new Qi(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy()}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",Q_))}}),J_={"data-vis-component":""},gc=c.defineComponent({__name:"index",props:{color:{},curveType:{},lineWidth:{},lineDashArray:{},fallbackValue:{},highlightOnHover:{type:Boolean},cursor:{},interpolateMissingData:{type:Boolean},x:{},y:{},id:{type:Function},xScale:{type:[Object,Function]},yScale:{type:[Object,Function]},excludeFromDomainCalculation:{type:Boolean},duration:{},events:{},attributes:{},data:{}},setup(e,{expose:t}){const n=c.inject(Qt),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new Zi(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy()}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",J_))}}),ey={"data-vis-component":""},ty=c.defineComponent({__name:"index",props:{id:{type:Function},value:{},angleRange:{},padAngle:{},sortFunction:{type:Function},cornerRadius:{},color:{},radius:{},arcWidth:{},centralLabel:{},centralSubLabel:{},centralSubLabelWrap:{type:Boolean},showEmptySegments:{type:Boolean},emptySegmentAngle:{},showBackground:{type:Boolean},backgroundAngleRange:{},centralLabelOffsetX:{},centralLabelOffsetY:{},duration:{},events:{},attributes:{},data:{}},setup(e,{expose:t}){const n=c.inject(Qt),i=e,r=c.computed(()=>n.data.value??i.data),o=Ye(i),s=c.ref();return c.onMounted(()=>{c.nextTick(()=>{var a;s.value=new as(o.value),(a=s.value)==null||a.setData(r.value),n.update(s.value)})}),c.onUnmounted(()=>{var a;(a=s.value)==null||a.destroy(),n.destroy()}),c.watch(o,(a,l)=>{var u;vt(a,l)||(u=s.value)==null||u.setConfig(o.value)}),c.watch(r,()=>{var a;(a=s.value)==null||a.setData(r.value)}),t({component:s}),(a,l)=>(c.openBlock(),c.createElementBlock("div",ey))}}),ny={"data-vis-tooltip":""},er=c.defineComponent({__name:"index",props:{components:{},container:{},followCursor:{type:Boolean},allowHover:{type:Boolean},horizontalPlacement:{},horizontalShift:{},verticalPlacement:{},verticalShift:{},triggers:{},attributes:{},className:{},data:{}},setup(e,{expose:t}){const n=c.inject(ls),i=Ye(e),r=c.ref();return c.onMounted(()=>{c.nextTick(()=>{r.value=new xu(i.value),n.update(r.value)})}),c.onUnmounted(()=>{var o;(o=r.value)==null||o.destroy(),n.destroy()}),c.watch(i,(o,s)=>{var a;vt(o,s)||(a=r.value)==null||a.setConfig(i.value)}),t({component:r}),(o,s)=>(c.openBlock(),c.createElementBlock("div",ny))}}),tr=c.defineComponent({__name:"index",props:{items:{},labelClassName:{},onLegendItemClick:{type:Function},labelFontSize:{},labelMaxWidth:{},bulletSize:{},bulletShape:{},orientation:{},renderIntoProvidedDomNode:{type:Boolean},data:{}},setup(e,{expose:t}){const n=e;c.computed(()=>n.data);const i=Ye(n),r=c.ref(),o=c.ref();return c.onMounted(()=>{c.nextTick(()=>{o.value&&(r.value=new Ju(o.value,{...i.value,renderIntoProvidedDomNode:!0}))})}),c.onUnmounted(()=>{var s;(s=r.value)==null||s.destroy()}),c.watch(i,(s,a)=>{var l;vt(s,a)||(l=r.value)==null||l.update(i.value)}),t({component:r}),(s,a)=>(c.openBlock(),c.createElementBlock("div",{"data-vis-bullet-legend":"",ref_key:"elRef",ref:o},null,512))}});(function(){try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".unovis-xy-container,.unovis-single-container{display:block;position:relative;width:100%}[data-vis-leaflet-map],[data-vis-leaflet-flow-map]{display:block;position:relative}[data-vis-bullet-legend]{display:block}")),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();const iy={class:"flex items-center justify-center"},ry={key:0,class:"flex items-center justify-center mt-4"},oy=c.defineComponent({__name:"DonutChart",props:{type:{},data:{},height:{},radius:{},hidePagination:{type:Boolean},labels:{}},setup(e){const t=e,n=o=>o,i=t.type==="half",r={[as.selectors.segment]:o=>(console.log(),`<div class='flex items-center'><div class='w-2 h-2 rounded-full mr-2' style='background-color: ${t.labels[o.index].color} ;'></div>
|
|
460
|
-
<div>${o.data}</div>
|
|
461
|
-
</vistooltip>
|
|
462
|
-
</vissinglecontainer>
|
|
463
|
-
</div>`)};return(o,s)=>(c.openBlock(),c.createElementBlock(c.Fragment,null,[c.createElementVNode("div",iy,[c.createVNode(c.unref(Y_),{class:c.normalizeClass(i?"mt-24":""),data:o.data,height:o.height,margin:{}},{default:c.withCtx(()=>[c.createVNode(c.unref(er),{"horizontal-shift":20,"vertical-shift":20,triggers:r}),c.createVNode(c.unref(ty),{value:n,"corner-radius":o.radius,color:t.labels.map(a=>a.color),"angle-range":i?[-1.5707963267948966,1.5707963267948966]:[]},null,8,["corner-radius","color","angle-range"])]),_:1},8,["class","data","height"]),c.renderSlot(o.$slots,"default")]),o.hidePagination?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",ry,[c.createVNode(c.unref(tr),{items:o.labels},null,8,["items"])]))],64))}}),sy={class:"flex flex-col"},ay={class:"flex items-center mr-2 mt-2"},ly={class:"font-semibold capitalize text-white/75"},uy={class:"flex items-center gap-2"},cy={class:"font-normal"},cs=c.defineComponent({__name:"Tooltip",props:{data:{},categories:{}},setup(e){function t(i){var r;return((r=n.categories[i])==null?void 0:r.color)??"#f00"}const n=e;return(i,r)=>(c.openBlock(),c.createElementBlock("div",sy,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(Object.entries(i.data),([o,s])=>{var a;return c.openBlock(),c.createElementBlock(c.Fragment,{key:o},[c.createElementVNode("div",ay,[c.createElementVNode("span",ly,c.toDisplayString(o)+":",1)]),c.createElementVNode("div",uy,[(a=n.categories[o])!=null&&a.color?(c.openBlock(),c.createElementBlock("span",{key:0,style:c.normalizeStyle({backgroundColor:t(o)}),class:"w-2 h-2"},null,4)):c.createCommentVNode("",!0),c.createElementVNode("span",cy,c.toDisplayString(s),1)])],64)}),128))]))}}),dy={class:"flex items center justify-end"},fy=c.defineComponent({__name:"LineChart",props:{data:{},height:{},xLabel:{},yLabel:{},categories:{},xFormatter:{type:Function},yFormatter:{type:Function},curveType:{},yNumTicks:{},xNumTicks:{},paginationPoisition:{}},setup(e){const t=e,n=r=>Object.values(t.categories)[r].color,i=c.computed(()=>r=>{const o=c.createApp(cs,{data:r,categories:t.categories}),s=document.createElement("div");o.mount(s);const a=s.innerHTML;return o.unmount(),a});return(r,o)=>(c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(["space-y-4 flex flex-col",{"flex-col-reverse":t.paginationPoisition==="top"}])},[c.createVNode(c.unref(us),{data:r.data,height:r.height},{default:c.withCtx(()=>[c.createVNode(c.unref(er),{"horizontal-placement":c.unref($).Right,"vertical-placement":c.unref($).Top},null,8,["horizontal-placement","vertical-placement"]),(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(Object.keys(t.categories),(s,a)=>(c.openBlock(),c.createBlock(c.unref(gc),{key:a,x:(l,u)=>u,y:l=>l[s],color:n(a),"curve-type":r.curveType??c.unref(Y).MonotoneX},null,8,["x","y","color","curve-type"]))),128)),c.createVNode(c.unref(Xt),{type:"x","tick-format":r.xFormatter,"num-ticks":r.xNumTicks??4,label:r.xLabel,"label-margin":8,"domain-line":!1,"grid-line":!1},null,8,["tick-format","num-ticks","label"]),c.createVNode(c.unref(Xt),{type:"y","num-ticks":r.yNumTicks??4,"tick-format":r.yFormatter,label:r.yLabel,"domain-line":!1},null,8,["num-ticks","tick-format","label"]),c.createVNode(c.unref(hc),{color:"#666",template:i.value},null,8,["template"])]),_:1},8,["data","height"]),c.createElementVNode("div",dy,[c.createVNode(c.unref(tr),{items:Object.values(r.categories)},null,8,["items"])])],2))}});var pc=(e=>(e.Top="top",e.Bottom="bottom",e))(pc||{});const hy={class:"space-y-2"},gy={class:"space-y-2"},py={class:"text-gray-500 mb-1"},my={class:"text-xl dark:text-white font-bold"},vy={class:"flex items-center justify-between text-sm font-medium dark:text-gray-500 mt-2"},_y={class:"dark:bg-white/5 bg-gray-100 rounded-full h-3"},wr=c.defineComponent({__name:"Progress",props:{label:{},value:{},unit:{},progress:{},total:{},color:{}},setup(e){const t=e,n=c.computed(()=>(t.progress/t.total*100).toFixed(1)),i=c.computed(()=>`${t.progress/t.total*100}%`);return(r,o)=>(c.openBlock(),c.createElementBlock("div",hy,[c.createElementVNode("div",gy,[c.createElementVNode("p",py,c.toDisplayString(r.label),1),c.createElementVNode("h2",my,c.toDisplayString(r.value),1)]),c.createElementVNode("div",vy,[c.createElementVNode("div",null,c.toDisplayString(n.value)+"%",1),c.createElementVNode("div",null,c.toDisplayString(r.progress)+" of "+c.toDisplayString(r.total)+c.toDisplayString(r.unit),1)]),c.createElementVNode("div",_y,[c.createElementVNode("div",{class:"rounded-full h-full",style:c.normalizeStyle({width:i.value,backgroundColor:r.color})},null,4)])]))}}),yy={key:0,class:"flex items center justify-end"},xy=c.defineComponent({__name:"AreaChart",props:{data:{},height:{},xLabel:{},yLabel:{},categories:{},xFormatter:{},yFormatter:{},curveType:{},xNumTicks:{default:e=>e.data.length>24?24/4:e.data.length-1},yNumTicks:{default:e=>e.data.length>24?24/4:e.data.length-1},hideLegend:{type:Boolean},hideTooltip:{type:Boolean},gridLineX:{type:Boolean},domainLineX:{type:Boolean},gridLineY:{type:Boolean},domainLineY:{type:Boolean},paginationPoisition:{}},setup(e){const t=e,n=Object.values(t.categories).map(s=>s.color),i=c.computed(()=>s=>{const a=c.createApp(cs,{data:s,categories:t.categories}),l=document.createElement("div");a.mount(l);const u=l.innerHTML;return a.unmount(),u});function r(s){var a;return{y:l=>Number(l[s]),color:((a=t.categories[s])==null?void 0:a.color)??"#3b82f6"}}const o=n.map((s,a)=>`
|
|
464
|
-
<linearGradient id="gradient${a}-${s}" gradientTransform="rotate(90)">
|
|
465
|
-
<stop offset="0%" stop-color="${s}" stop-opacity="1" />
|
|
466
|
-
<stop offset="100%" stop-color="${s}" stop-opacity="0" />
|
|
467
|
-
</linearGradient>
|
|
468
|
-
`).join("");return(s,a)=>(c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(["flex flex-col space-y-4",{"flex-col-reverse":t.paginationPoisition==="top"}])},[c.createVNode(c.unref(us),{data:s.data,height:s.height,"svg-defs":c.unref(o)},{default:c.withCtx(()=>[s.hideTooltip?c.createCommentVNode("",!0):(c.openBlock(),c.createBlock(c.unref(er),{key:0,"horizontal-placement":c.unref($).Right,"vertical-placement":c.unref($).Top},null,8,["horizontal-placement","vertical-placement"])),(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(Object.keys(t.categories),(l,u)=>(c.openBlock(),c.createElementBlock(c.Fragment,{key:u},[c.createVNode(c.unref(X_),c.mergeProps({x:(d,f)=>f,ref_for:!0},r(l),{color:`url(#gradient${u}-${c.unref(n)[u]})`,opacity:.5,"curve-type":s.curveType??c.unref(Y).MonotoneX}),null,16,["x","color","curve-type"]),c.createVNode(c.unref(gc),{x:(d,f)=>f,y:d=>d[l],color:c.unref(n)[u],"curve-type":s.curveType??c.unref(Y).MonotoneX},null,8,["x","y","color","curve-type"])],64))),128)),c.createVNode(c.unref(Xt),{type:"x","tick-format":s.xFormatter,"num-ticks":s.xNumTicks,label:s.xLabel,"grid-line":s.gridLineX,"domain-line":s.domainLineX,"tick-line":!!s.gridLineX},null,8,["tick-format","num-ticks","label","grid-line","domain-line","tick-line"]),c.createVNode(c.unref(Xt),{type:"y","num-ticks":s.yNumTicks??s.data.length,"tick-format":s.yFormatter,label:s.yLabel,"grid-line":s.gridLineY,"domain-line":s.domainLineY,"tick-line":!!s.gridLineY},null,8,["num-ticks","tick-format","label","grid-line","domain-line","tick-line"]),s.hideTooltip?c.createCommentVNode("",!0):(c.openBlock(),c.createBlock(c.unref(hc),{key:1,color:"#666",template:i.value},null,8,["template"]))]),_:1},8,["data","height","svg-defs"]),s.hideLegend?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",yy,[c.createVNode(c.unref(tr),{items:Object.values(s.categories)},null,8,["items"])]))],2))}}),wy={class:"space-y-2"},Sy={key:0,class:"flex items center justify-end"},by=c.defineComponent({__name:"BarChart",props:{data:{},height:{},xLabel:{},yLabel:{},categories:{},xFormatter:{type:Function},yFormatter:{type:Function},yNumTicks:{},xNumTicks:{},yAxis:{},groupPadding:{},barPadding:{},radius:{},hideLegend:{type:Boolean}},setup(e){const t=e,n=t.yAxis.map(o=>s=>s[o]),i=(o,s)=>Object.values(t.categories)[s].color,r=c.computed(()=>o=>{const s=c.createApp(cs,{data:o,categories:t.categories}),a=document.createElement("div");s.mount(a);const l=a.innerHTML;return s.unmount(),l});return(o,s)=>(c.openBlock(),c.createElementBlock("div",wy,[c.createVNode(c.unref(us),{height:o.height},{default:c.withCtx(()=>[c.createVNode(c.unref(er),{triggers:{[c.unref(Qi).selectors.bar]:r.value}},null,8,["triggers"]),c.createVNode(c.unref(K_),{data:o.data,x:(a,l)=>l,y:c.unref(n),"grid-line":!1,"domain-line":!1,color:i,"rounded-corners":o.radius??0,"group-padding":o.groupPadding??0,"bar-padding":o.barPadding??0},null,8,["data","x","y","rounded-corners","group-padding","bar-padding"]),c.createVNode(c.unref(Xt),{type:"x",label:o.xLabel,"grid-line":!1,"domain-line":!1,"tick-format":o.xFormatter,"num-ticks":o.xNumTicks},null,8,["label","tick-format","num-ticks"]),c.createVNode(c.unref(Xt),{type:"y",label:o.yLabel,"grid-line":!0,"domain-line":!1,"tick-format":o.yFormatter},null,8,["label","tick-format"])]),_:1},8,["height"]),o.hideLegend?c.createCommentVNode("",!0):(c.openBlock(),c.createElementBlock("div",Sy,[c.createVNode(c.unref(tr),{items:Object.values(o.categories)},null,8,["items"])]))]))}}),Cy={class:"rounded-lg ring ring-border divide-y divide-border bg-card"},ky={key:0,class:"p-4 sm:px-6"},Ty={class:"p-4 sm:px-6"},Ry={key:1,class:"p-4 sm:px-6"},Ie=c.defineComponent({__name:"Card",setup(e){const t=c.useSlots();return(n,i)=>(c.openBlock(),c.createElementBlock("div",Cy,[c.unref(t).header?(c.openBlock(),c.createElementBlock("div",ky,[c.renderSlot(n.$slots,"header",{class:"p-4 sm:px-6"})])):c.createCommentVNode("",!0),c.createElementVNode("div",Ty,[c.renderSlot(n.$slots,"default")]),c.unref(t).footer?(c.openBlock(),c.createElementBlock("div",Ry,[c.renderSlot(n.$slots,"footer",{class:"p-4 sm:px-6"})])):c.createCommentVNode("",!0)]))}});/**
|
|
469
|
-
* table-core
|
|
470
|
-
*
|
|
471
|
-
* Copyright (c) TanStack
|
|
472
|
-
*
|
|
473
|
-
* This source code is licensed under the MIT license found in the
|
|
474
|
-
* LICENSE.md file in the root directory of this source tree.
|
|
475
|
-
*
|
|
476
|
-
* @license MIT
|
|
477
|
-
*/function ft(e,t){return typeof e=="function"?e(t):e}function Te(e,t){return n=>{t.setState(i=>({...i,[e]:ft(n,i[e])}))}}function nr(e){return e instanceof Function}function $y(e){return Array.isArray(e)&&e.every(t=>typeof t=="number")}function My(e,t){const n=[],i=r=>{r.forEach(o=>{n.push(o);const s=t(o);s!=null&&s.length&&i(s)})};return i(e),n}function E(e,t,n){let i=[],r;return o=>{let s;n.key&&n.debug&&(s=Date.now());const a=e(o);if(!(a.length!==i.length||a.some((d,f)=>i[f]!==d)))return r;i=a;let u;if(n.key&&n.debug&&(u=Date.now()),r=t(...a),n==null||n.onChange==null||n.onChange(r),n.key&&n.debug&&n!=null&&n.debug()){const d=Math.round((Date.now()-s)*100)/100,f=Math.round((Date.now()-u)*100)/100,h=f/16,g=(m,p)=>{for(m=String(m);m.length<p;)m=" "+m;return m};console.info(`%c⏱ ${g(f,5)} /${g(d,5)} ms`,`
|
|
478
|
-
font-size: .6rem;
|
|
479
|
-
font-weight: bold;
|
|
480
|
-
color: hsl(${Math.max(0,Math.min(120-120*h,120))}deg 100% 31%);`,n==null?void 0:n.key)}return r}}function A(e,t,n,i){return{debug:()=>{var r;return(r=e==null?void 0:e.debugAll)!=null?r:e[t]},key:process.env.NODE_ENV==="development"&&n,onChange:i}}function Ey(e,t,n,i){const r=()=>{var s;return(s=o.getValue())!=null?s:e.options.renderFallbackValue},o={id:`${t.id}_${n.id}`,row:t,column:n,getValue:()=>t.getValue(i),renderValue:r,getContext:E(()=>[e,n,t,o],(s,a,l,u)=>({table:s,column:a,row:l,cell:u,getValue:u.getValue,renderValue:u.renderValue}),A(e.options,"debugCells","cell.getContext"))};return e._features.forEach(s=>{s.createCell==null||s.createCell(o,n,t,e)},{}),o}function Ay(e,t,n,i){var r,o;const a={...e._getDefaultColumnDef(),...t},l=a.accessorKey;let u=(r=(o=a.id)!=null?o:l?typeof String.prototype.replaceAll=="function"?l.replaceAll(".","_"):l.replace(/\./g,"_"):void 0)!=null?r:typeof a.header=="string"?a.header:void 0,d;if(a.accessorFn?d=a.accessorFn:l&&(l.includes(".")?d=h=>{let g=h;for(const p of l.split(".")){var m;g=(m=g)==null?void 0:m[p],process.env.NODE_ENV!=="production"&&g===void 0&&console.warn(`"${p}" in deeply nested key "${l}" returned undefined.`)}return g}:d=h=>h[a.accessorKey]),!u)throw process.env.NODE_ENV!=="production"?new Error(a.accessorFn?"Columns require an id when using an accessorFn":"Columns require an id when using a non-string header"):new Error;let f={id:`${String(u)}`,accessorFn:d,parent:i,depth:n,columnDef:a,columns:[],getFlatColumns:E(()=>[!0],()=>{var h;return[f,...(h=f.columns)==null?void 0:h.flatMap(g=>g.getFlatColumns())]},A(e.options,"debugColumns","column.getFlatColumns")),getLeafColumns:E(()=>[e._getOrderColumnsFn()],h=>{var g;if((g=f.columns)!=null&&g.length){let m=f.columns.flatMap(p=>p.getLeafColumns());return h(m)}return[f]},A(e.options,"debugColumns","column.getLeafColumns"))};for(const h of e._features)h.createColumn==null||h.createColumn(f,e);return f}const se="debugHeaders";function Ua(e,t,n){var i;let o={id:(i=n.id)!=null?i:t.id,column:t,index:n.index,isPlaceholder:!!n.isPlaceholder,placeholderId:n.placeholderId,depth:n.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const s=[],a=l=>{l.subHeaders&&l.subHeaders.length&&l.subHeaders.map(a),s.push(l)};return a(o),s},getContext:()=>({table:e,header:o,column:t})};return e._features.forEach(s=>{s.createHeader==null||s.createHeader(o,e)}),o}const Fy={createTable:e=>{e.getHeaderGroups=E(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,i,r)=>{var o,s;const a=(o=i==null?void 0:i.map(f=>n.find(h=>h.id===f)).filter(Boolean))!=null?o:[],l=(s=r==null?void 0:r.map(f=>n.find(h=>h.id===f)).filter(Boolean))!=null?s:[],u=n.filter(f=>!(i!=null&&i.includes(f.id))&&!(r!=null&&r.includes(f.id)));return Hn(t,[...a,...u,...l],e)},A(e.options,se,"getHeaderGroups")),e.getCenterHeaderGroups=E(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,i,r)=>(n=n.filter(o=>!(i!=null&&i.includes(o.id))&&!(r!=null&&r.includes(o.id))),Hn(t,n,e,"center")),A(e.options,se,"getCenterHeaderGroups")),e.getLeftHeaderGroups=E(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,n,i)=>{var r;const o=(r=i==null?void 0:i.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return Hn(t,o,e,"left")},A(e.options,se,"getLeftHeaderGroups")),e.getRightHeaderGroups=E(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,n,i)=>{var r;const o=(r=i==null?void 0:i.map(s=>n.find(a=>a.id===s)).filter(Boolean))!=null?r:[];return Hn(t,o,e,"right")},A(e.options,se,"getRightHeaderGroups")),e.getFooterGroups=E(()=>[e.getHeaderGroups()],t=>[...t].reverse(),A(e.options,se,"getFooterGroups")),e.getLeftFooterGroups=E(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),A(e.options,se,"getLeftFooterGroups")),e.getCenterFooterGroups=E(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),A(e.options,se,"getCenterFooterGroups")),e.getRightFooterGroups=E(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),A(e.options,se,"getRightFooterGroups")),e.getFlatHeaders=E(()=>[e.getHeaderGroups()],t=>t.map(n=>n.headers).flat(),A(e.options,se,"getFlatHeaders")),e.getLeftFlatHeaders=E(()=>[e.getLeftHeaderGroups()],t=>t.map(n=>n.headers).flat(),A(e.options,se,"getLeftFlatHeaders")),e.getCenterFlatHeaders=E(()=>[e.getCenterHeaderGroups()],t=>t.map(n=>n.headers).flat(),A(e.options,se,"getCenterFlatHeaders")),e.getRightFlatHeaders=E(()=>[e.getRightHeaderGroups()],t=>t.map(n=>n.headers).flat(),A(e.options,se,"getRightFlatHeaders")),e.getCenterLeafHeaders=E(()=>[e.getCenterFlatHeaders()],t=>t.filter(n=>{var i;return!((i=n.subHeaders)!=null&&i.length)}),A(e.options,se,"getCenterLeafHeaders")),e.getLeftLeafHeaders=E(()=>[e.getLeftFlatHeaders()],t=>t.filter(n=>{var i;return!((i=n.subHeaders)!=null&&i.length)}),A(e.options,se,"getLeftLeafHeaders")),e.getRightLeafHeaders=E(()=>[e.getRightFlatHeaders()],t=>t.filter(n=>{var i;return!((i=n.subHeaders)!=null&&i.length)}),A(e.options,se,"getRightLeafHeaders")),e.getLeafHeaders=E(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,n,i)=>{var r,o,s,a,l,u;return[...(r=(o=t[0])==null?void 0:o.headers)!=null?r:[],...(s=(a=n[0])==null?void 0:a.headers)!=null?s:[],...(l=(u=i[0])==null?void 0:u.headers)!=null?l:[]].map(d=>d.getLeafHeaders()).flat()},A(e.options,se,"getLeafHeaders"))}};function Hn(e,t,n,i){var r,o;let s=0;const a=function(h,g){g===void 0&&(g=1),s=Math.max(s,g),h.filter(m=>m.getIsVisible()).forEach(m=>{var p;(p=m.columns)!=null&&p.length&&a(m.columns,g+1)},0)};a(e);let l=[];const u=(h,g)=>{const m={depth:g,id:[i,`${g}`].filter(Boolean).join("_"),headers:[]},p=[];h.forEach(v=>{const _=[...p].reverse()[0],y=v.column.depth===m.depth;let x,w=!1;if(y&&v.column.parent?x=v.column.parent:(x=v.column,w=!0),_&&(_==null?void 0:_.column)===x)_.subHeaders.push(v);else{const S=Ua(n,x,{id:[i,g,x.id,v==null?void 0:v.id].filter(Boolean).join("_"),isPlaceholder:w,placeholderId:w?`${p.filter(b=>b.column===x).length}`:void 0,depth:g,index:p.length});S.subHeaders.push(v),p.push(S)}m.headers.push(v),v.headerGroup=m}),l.push(m),g>0&&u(p,g-1)},d=t.map((h,g)=>Ua(n,h,{depth:s,index:g}));u(d,s-1),l.reverse();const f=h=>h.filter(m=>m.column.getIsVisible()).map(m=>{let p=0,v=0,_=[0];m.subHeaders&&m.subHeaders.length?(_=[],f(m.subHeaders).forEach(x=>{let{colSpan:w,rowSpan:S}=x;p+=w,_.push(S)})):p=1;const y=Math.min(..._);return v=v+y,m.colSpan=p,m.rowSpan=v,{colSpan:p,rowSpan:v}});return f((r=(o=l[0])==null?void 0:o.headers)!=null?r:[]),l}const ds=(e,t,n,i,r,o,s)=>{let a={id:t,index:i,original:n,depth:r,parentId:s,_valuesCache:{},_uniqueValuesCache:{},getValue:l=>{if(a._valuesCache.hasOwnProperty(l))return a._valuesCache[l];const u=e.getColumn(l);if(u!=null&&u.accessorFn)return a._valuesCache[l]=u.accessorFn(a.original,i),a._valuesCache[l]},getUniqueValues:l=>{if(a._uniqueValuesCache.hasOwnProperty(l))return a._uniqueValuesCache[l];const u=e.getColumn(l);if(u!=null&&u.accessorFn)return u.columnDef.getUniqueValues?(a._uniqueValuesCache[l]=u.columnDef.getUniqueValues(a.original,i),a._uniqueValuesCache[l]):(a._uniqueValuesCache[l]=[a.getValue(l)],a._uniqueValuesCache[l])},renderValue:l=>{var u;return(u=a.getValue(l))!=null?u:e.options.renderFallbackValue},subRows:[],getLeafRows:()=>My(a.subRows,l=>l.subRows),getParentRow:()=>a.parentId?e.getRow(a.parentId,!0):void 0,getParentRows:()=>{let l=[],u=a;for(;;){const d=u.getParentRow();if(!d)break;l.push(d),u=d}return l.reverse()},getAllCells:E(()=>[e.getAllLeafColumns()],l=>l.map(u=>Ey(e,a,u,u.id)),A(e.options,"debugRows","getAllCells")),_getAllCellsByColumnId:E(()=>[a.getAllCells()],l=>l.reduce((u,d)=>(u[d.column.id]=d,u),{}),A(e.options,"debugRows","getAllCellsByColumnId"))};for(let l=0;l<e._features.length;l++){const u=e._features[l];u==null||u.createRow==null||u.createRow(a,e)}return a},Vy={createColumn:(e,t)=>{e._getFacetedRowModel=t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),e.getFacetedRowModel=()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),e._getFacetedUniqueValues=t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),e.getFacetedUniqueValues=()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,e._getFacetedMinMaxValues=t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),e.getFacetedMinMaxValues=()=>{if(e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}},mc=(e,t,n)=>{var i,r;const o=n==null||(i=n.toString())==null?void 0:i.toLowerCase();return!!(!((r=e.getValue(t))==null||(r=r.toString())==null||(r=r.toLowerCase())==null)&&r.includes(o))};mc.autoRemove=e=>Ne(e);const vc=(e,t,n)=>{var i;return!!(!((i=e.getValue(t))==null||(i=i.toString())==null)&&i.includes(n))};vc.autoRemove=e=>Ne(e);const _c=(e,t,n)=>{var i;return((i=e.getValue(t))==null||(i=i.toString())==null?void 0:i.toLowerCase())===(n==null?void 0:n.toLowerCase())};_c.autoRemove=e=>Ne(e);const yc=(e,t,n)=>{var i;return(i=e.getValue(t))==null?void 0:i.includes(n)};yc.autoRemove=e=>Ne(e);const xc=(e,t,n)=>!n.some(i=>{var r;return!((r=e.getValue(t))!=null&&r.includes(i))});xc.autoRemove=e=>Ne(e)||!(e!=null&&e.length);const wc=(e,t,n)=>n.some(i=>{var r;return(r=e.getValue(t))==null?void 0:r.includes(i)});wc.autoRemove=e=>Ne(e)||!(e!=null&&e.length);const Sc=(e,t,n)=>e.getValue(t)===n;Sc.autoRemove=e=>Ne(e);const bc=(e,t,n)=>e.getValue(t)==n;bc.autoRemove=e=>Ne(e);const fs=(e,t,n)=>{let[i,r]=n;const o=e.getValue(t);return o>=i&&o<=r};fs.resolveFilterValue=e=>{let[t,n]=e,i=typeof t!="number"?parseFloat(t):t,r=typeof n!="number"?parseFloat(n):n,o=t===null||Number.isNaN(i)?-1/0:i,s=n===null||Number.isNaN(r)?1/0:r;if(o>s){const a=o;o=s,s=a}return[o,s]};fs.autoRemove=e=>Ne(e)||Ne(e[0])&&Ne(e[1]);const Ze={includesString:mc,includesStringSensitive:vc,equalsString:_c,arrIncludes:yc,arrIncludesAll:xc,arrIncludesSome:wc,equals:Sc,weakEquals:bc,inNumberRange:fs};function Ne(e){return e==null||e===""}const Ny={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],...e}),getDefaultOptions:e=>({onColumnFiltersChange:Te("columnFilters",e),filterFromLeafRows:!1,maxLeafRowFilterDepth:100}),createColumn:(e,t)=>{e.getAutoFilterFn=()=>{const n=t.getCoreRowModel().flatRows[0],i=n==null?void 0:n.getValue(e.id);return typeof i=="string"?Ze.includesString:typeof i=="number"?Ze.inNumberRange:typeof i=="boolean"||i!==null&&typeof i=="object"?Ze.equals:Array.isArray(i)?Ze.arrIncludes:Ze.weakEquals},e.getFilterFn=()=>{var n,i;return nr(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(n=(i=t.options.filterFns)==null?void 0:i[e.columnDef.filterFn])!=null?n:Ze[e.columnDef.filterFn]},e.getCanFilter=()=>{var n,i,r;return((n=e.columnDef.enableColumnFilter)!=null?n:!0)&&((i=t.options.enableColumnFilters)!=null?i:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&!!e.accessorFn},e.getIsFiltered=()=>e.getFilterIndex()>-1,e.getFilterValue=()=>{var n;return(n=t.getState().columnFilters)==null||(n=n.find(i=>i.id===e.id))==null?void 0:n.value},e.getFilterIndex=()=>{var n,i;return(n=(i=t.getState().columnFilters)==null?void 0:i.findIndex(r=>r.id===e.id))!=null?n:-1},e.setFilterValue=n=>{t.setColumnFilters(i=>{const r=e.getFilterFn(),o=i==null?void 0:i.find(d=>d.id===e.id),s=ft(n,o?o.value:void 0);if(Wa(r,s,e)){var a;return(a=i==null?void 0:i.filter(d=>d.id!==e.id))!=null?a:[]}const l={id:e.id,value:s};if(o){var u;return(u=i==null?void 0:i.map(d=>d.id===e.id?l:d))!=null?u:[]}return i!=null&&i.length?[...i,l]:[l]})}},createRow:(e,t)=>{e.columnFilters={},e.columnFiltersMeta={}},createTable:e=>{e.setColumnFilters=t=>{const n=e.getAllLeafColumns(),i=r=>{var o;return(o=ft(t,r))==null?void 0:o.filter(s=>{const a=n.find(l=>l.id===s.id);if(a){const l=a.getFilterFn();if(Wa(l,s.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(i)},e.resetColumnFilters=t=>{var n,i;e.setColumnFilters(t?[]:(n=(i=e.initialState)==null?void 0:i.columnFilters)!=null?n:[])},e.getPreFilteredRowModel=()=>e.getCoreRowModel(),e.getFilteredRowModel=()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel())}};function Wa(e,t,n){return(e&&e.autoRemove?e.autoRemove(t,n):!1)||typeof t>"u"||typeof t=="string"&&!t}const Dy=(e,t,n)=>n.reduce((i,r)=>{const o=r.getValue(e);return i+(typeof o=="number"?o:0)},0),Py=(e,t,n)=>{let i;return n.forEach(r=>{const o=r.getValue(e);o!=null&&(i>o||i===void 0&&o>=o)&&(i=o)}),i},Oy=(e,t,n)=>{let i;return n.forEach(r=>{const o=r.getValue(e);o!=null&&(i<o||i===void 0&&o>=o)&&(i=o)}),i},Ly=(e,t,n)=>{let i,r;return n.forEach(o=>{const s=o.getValue(e);s!=null&&(i===void 0?s>=s&&(i=r=s):(i>s&&(i=s),r<s&&(r=s)))}),[i,r]},Iy=(e,t)=>{let n=0,i=0;if(t.forEach(r=>{let o=r.getValue(e);o!=null&&(o=+o)>=o&&(++n,i+=o)}),n)return i/n},By=(e,t)=>{if(!t.length)return;const n=t.map(o=>o.getValue(e));if(!$y(n))return;if(n.length===1)return n[0];const i=Math.floor(n.length/2),r=n.sort((o,s)=>o-s);return n.length%2!==0?r[i]:(r[i-1]+r[i])/2},zy=(e,t)=>Array.from(new Set(t.map(n=>n.getValue(e))).values()),Hy=(e,t)=>new Set(t.map(n=>n.getValue(e))).size,Gy=(e,t)=>t.length,Sr={sum:Dy,min:Py,max:Oy,extent:Ly,mean:Iy,median:By,unique:zy,uniqueCount:Hy,count:Gy},Uy={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,n;return(t=(n=e.getValue())==null||n.toString==null?void 0:n.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:Te("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>{e.toggleGrouping=()=>{t.setGrouping(n=>n!=null&&n.includes(e.id)?n.filter(i=>i!==e.id):[...n??[],e.id])},e.getCanGroup=()=>{var n,i;return((n=e.columnDef.enableGrouping)!=null?n:!0)&&((i=t.options.enableGrouping)!=null?i:!0)&&(!!e.accessorFn||!!e.columnDef.getGroupingValue)},e.getIsGrouped=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.includes(e.id)},e.getGroupedIndex=()=>{var n;return(n=t.getState().grouping)==null?void 0:n.indexOf(e.id)},e.getToggleGroupingHandler=()=>{const n=e.getCanGroup();return()=>{n&&e.toggleGrouping()}},e.getAutoAggregationFn=()=>{const n=t.getCoreRowModel().flatRows[0],i=n==null?void 0:n.getValue(e.id);if(typeof i=="number")return Sr.sum;if(Object.prototype.toString.call(i)==="[object Date]")return Sr.extent},e.getAggregationFn=()=>{var n,i;if(!e)throw new Error;return nr(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(n=(i=t.options.aggregationFns)==null?void 0:i[e.columnDef.aggregationFn])!=null?n:Sr[e.columnDef.aggregationFn]}},createTable:e=>{e.setGrouping=t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),e.resetGrouping=t=>{var n,i;e.setGrouping(t?[]:(n=(i=e.initialState)==null?void 0:i.grouping)!=null?n:[])},e.getPreGroupedRowModel=()=>e.getFilteredRowModel(),e.getGroupedRowModel=()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())},createRow:(e,t)=>{e.getIsGrouped=()=>!!e.groupingColumnId,e.getGroupingValue=n=>{if(e._groupingValuesCache.hasOwnProperty(n))return e._groupingValuesCache[n];const i=t.getColumn(n);return i!=null&&i.columnDef.getGroupingValue?(e._groupingValuesCache[n]=i.columnDef.getGroupingValue(e.original),e._groupingValuesCache[n]):e.getValue(n)},e._groupingValuesCache={}},createCell:(e,t,n,i)=>{e.getIsGrouped=()=>t.getIsGrouped()&&t.id===n.groupingColumnId,e.getIsPlaceholder=()=>!e.getIsGrouped()&&t.getIsGrouped(),e.getIsAggregated=()=>{var r;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((r=n.subRows)!=null&&r.length)}}};function Wy(e,t,n){if(!(t!=null&&t.length)||!n)return e;const i=e.filter(o=>!t.includes(o.id));return n==="remove"?i:[...t.map(o=>e.find(s=>s.id===o)).filter(Boolean),...i]}const Yy={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:Te("columnOrder",e)}),createColumn:(e,t)=>{e.getIndex=E(n=>[vn(t,n)],n=>n.findIndex(i=>i.id===e.id),A(t.options,"debugColumns","getIndex")),e.getIsFirstColumn=n=>{var i;return((i=vn(t,n)[0])==null?void 0:i.id)===e.id},e.getIsLastColumn=n=>{var i;const r=vn(t,n);return((i=r[r.length-1])==null?void 0:i.id)===e.id}},createTable:e=>{e.setColumnOrder=t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),e.resetColumnOrder=t=>{var n;e.setColumnOrder(t?[]:(n=e.initialState.columnOrder)!=null?n:[])},e._getOrderColumnsFn=E(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,n,i)=>r=>{let o=[];if(!(t!=null&&t.length))o=r;else{const s=[...t],a=[...r];for(;a.length&&s.length;){const l=s.shift(),u=a.findIndex(d=>d.id===l);u>-1&&o.push(a.splice(u,1)[0])}o=[...o,...a]}return Wy(o,n,i)},A(e.options,"debugTable","_getOrderColumnsFn"))}},br=()=>({left:[],right:[]}),qy={getInitialState:e=>({columnPinning:br(),...e}),getDefaultOptions:e=>({onColumnPinningChange:Te("columnPinning",e)}),createColumn:(e,t)=>{e.pin=n=>{const i=e.getLeafColumns().map(r=>r.id).filter(Boolean);t.setColumnPinning(r=>{var o,s;if(n==="right"){var a,l;return{left:((a=r==null?void 0:r.left)!=null?a:[]).filter(f=>!(i!=null&&i.includes(f))),right:[...((l=r==null?void 0:r.right)!=null?l:[]).filter(f=>!(i!=null&&i.includes(f))),...i]}}if(n==="left"){var u,d;return{left:[...((u=r==null?void 0:r.left)!=null?u:[]).filter(f=>!(i!=null&&i.includes(f))),...i],right:((d=r==null?void 0:r.right)!=null?d:[]).filter(f=>!(i!=null&&i.includes(f)))}}return{left:((o=r==null?void 0:r.left)!=null?o:[]).filter(f=>!(i!=null&&i.includes(f))),right:((s=r==null?void 0:r.right)!=null?s:[]).filter(f=>!(i!=null&&i.includes(f)))}})},e.getCanPin=()=>e.getLeafColumns().some(i=>{var r,o,s;return((r=i.columnDef.enablePinning)!=null?r:!0)&&((o=(s=t.options.enableColumnPinning)!=null?s:t.options.enablePinning)!=null?o:!0)}),e.getIsPinned=()=>{const n=e.getLeafColumns().map(a=>a.id),{left:i,right:r}=t.getState().columnPinning,o=n.some(a=>i==null?void 0:i.includes(a)),s=n.some(a=>r==null?void 0:r.includes(a));return o?"left":s?"right":!1},e.getPinnedIndex=()=>{var n,i;const r=e.getIsPinned();return r?(n=(i=t.getState().columnPinning)==null||(i=i[r])==null?void 0:i.indexOf(e.id))!=null?n:-1:0}},createRow:(e,t)=>{e.getCenterVisibleCells=E(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(n,i,r)=>{const o=[...i??[],...r??[]];return n.filter(s=>!o.includes(s.column.id))},A(t.options,"debugRows","getCenterVisibleCells")),e.getLeftVisibleCells=E(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left],(n,i)=>(i??[]).map(o=>n.find(s=>s.column.id===o)).filter(Boolean).map(o=>({...o,position:"left"})),A(t.options,"debugRows","getLeftVisibleCells")),e.getRightVisibleCells=E(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(n,i)=>(i??[]).map(o=>n.find(s=>s.column.id===o)).filter(Boolean).map(o=>({...o,position:"right"})),A(t.options,"debugRows","getRightVisibleCells"))},createTable:e=>{e.setColumnPinning=t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),e.resetColumnPinning=t=>{var n,i;return e.setColumnPinning(t?br():(n=(i=e.initialState)==null?void 0:i.columnPinning)!=null?n:br())},e.getIsSomeColumnsPinned=t=>{var n;const i=e.getState().columnPinning;if(!t){var r,o;return!!((r=i.left)!=null&&r.length||(o=i.right)!=null&&o.length)}return!!((n=i[t])!=null&&n.length)},e.getLeftLeafColumns=E(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,n)=>(n??[]).map(i=>t.find(r=>r.id===i)).filter(Boolean),A(e.options,"debugColumns","getLeftLeafColumns")),e.getRightLeafColumns=E(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,n)=>(n??[]).map(i=>t.find(r=>r.id===i)).filter(Boolean),A(e.options,"debugColumns","getRightLeafColumns")),e.getCenterLeafColumns=E(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,n,i)=>{const r=[...n??[],...i??[]];return t.filter(o=>!r.includes(o.id))},A(e.options,"debugColumns","getCenterLeafColumns"))}},Gn={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},Cr=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),Xy={getDefaultColumnDef:()=>Gn,getInitialState:e=>({columnSizing:{},columnSizingInfo:Cr(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",columnResizeDirection:"ltr",onColumnSizingChange:Te("columnSizing",e),onColumnSizingInfoChange:Te("columnSizingInfo",e)}),createColumn:(e,t)=>{e.getSize=()=>{var n,i,r;const o=t.getState().columnSizing[e.id];return Math.min(Math.max((n=e.columnDef.minSize)!=null?n:Gn.minSize,(i=o??e.columnDef.size)!=null?i:Gn.size),(r=e.columnDef.maxSize)!=null?r:Gn.maxSize)},e.getStart=E(n=>[n,vn(t,n),t.getState().columnSizing],(n,i)=>i.slice(0,e.getIndex(n)).reduce((r,o)=>r+o.getSize(),0),A(t.options,"debugColumns","getStart")),e.getAfter=E(n=>[n,vn(t,n),t.getState().columnSizing],(n,i)=>i.slice(e.getIndex(n)+1).reduce((r,o)=>r+o.getSize(),0),A(t.options,"debugColumns","getAfter")),e.resetSize=()=>{t.setColumnSizing(n=>{let{[e.id]:i,...r}=n;return r})},e.getCanResize=()=>{var n,i;return((n=e.columnDef.enableResizing)!=null?n:!0)&&((i=t.options.enableColumnResizing)!=null?i:!0)},e.getIsResizing=()=>t.getState().columnSizingInfo.isResizingColumn===e.id},createHeader:(e,t)=>{e.getSize=()=>{let n=0;const i=r=>{if(r.subHeaders.length)r.subHeaders.forEach(i);else{var o;n+=(o=r.column.getSize())!=null?o:0}};return i(e),n},e.getStart=()=>{if(e.index>0){const n=e.headerGroup.headers[e.index-1];return n.getStart()+n.getSize()}return 0},e.getResizeHandler=n=>{const i=t.getColumn(e.column.id),r=i==null?void 0:i.getCanResize();return o=>{if(!i||!r||(o.persist==null||o.persist(),kr(o)&&o.touches&&o.touches.length>1))return;const s=e.getSize(),a=e?e.getLeafHeaders().map(_=>[_.column.id,_.column.getSize()]):[[i.id,i.getSize()]],l=kr(o)?Math.round(o.touches[0].clientX):o.clientX,u={},d=(_,y)=>{typeof y=="number"&&(t.setColumnSizingInfo(x=>{var w,S;const b=t.options.columnResizeDirection==="rtl"?-1:1,C=(y-((w=x==null?void 0:x.startOffset)!=null?w:0))*b,V=Math.max(C/((S=x==null?void 0:x.startSize)!=null?S:0),-.999999);return x.columnSizingStart.forEach(F=>{let[U,M]=F;u[U]=Math.round(Math.max(M+M*V,0)*100)/100}),{...x,deltaOffset:C,deltaPercentage:V}}),(t.options.columnResizeMode==="onChange"||_==="end")&&t.setColumnSizing(x=>({...x,...u})))},f=_=>d("move",_),h=_=>{d("end",_),t.setColumnSizingInfo(y=>({...y,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},g=n||typeof document<"u"?document:null,m={moveHandler:_=>f(_.clientX),upHandler:_=>{g==null||g.removeEventListener("mousemove",m.moveHandler),g==null||g.removeEventListener("mouseup",m.upHandler),h(_.clientX)}},p={moveHandler:_=>(_.cancelable&&(_.preventDefault(),_.stopPropagation()),f(_.touches[0].clientX),!1),upHandler:_=>{var y;g==null||g.removeEventListener("touchmove",p.moveHandler),g==null||g.removeEventListener("touchend",p.upHandler),_.cancelable&&(_.preventDefault(),_.stopPropagation()),h((y=_.touches[0])==null?void 0:y.clientX)}},v=jy()?{passive:!1}:!1;kr(o)?(g==null||g.addEventListener("touchmove",p.moveHandler,v),g==null||g.addEventListener("touchend",p.upHandler,v)):(g==null||g.addEventListener("mousemove",m.moveHandler,v),g==null||g.addEventListener("mouseup",m.upHandler,v)),t.setColumnSizingInfo(_=>({..._,startOffset:l,startSize:s,deltaOffset:0,deltaPercentage:0,columnSizingStart:a,isResizingColumn:i.id}))}}},createTable:e=>{e.setColumnSizing=t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),e.setColumnSizingInfo=t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),e.resetColumnSizing=t=>{var n;e.setColumnSizing(t?{}:(n=e.initialState.columnSizing)!=null?n:{})},e.resetHeaderSizeInfo=t=>{var n;e.setColumnSizingInfo(t?Cr():(n=e.initialState.columnSizingInfo)!=null?n:Cr())},e.getTotalSize=()=>{var t,n;return(t=(n=e.getHeaderGroups()[0])==null?void 0:n.headers.reduce((i,r)=>i+r.getSize(),0))!=null?t:0},e.getLeftTotalSize=()=>{var t,n;return(t=(n=e.getLeftHeaderGroups()[0])==null?void 0:n.headers.reduce((i,r)=>i+r.getSize(),0))!=null?t:0},e.getCenterTotalSize=()=>{var t,n;return(t=(n=e.getCenterHeaderGroups()[0])==null?void 0:n.headers.reduce((i,r)=>i+r.getSize(),0))!=null?t:0},e.getRightTotalSize=()=>{var t,n;return(t=(n=e.getRightHeaderGroups()[0])==null?void 0:n.headers.reduce((i,r)=>i+r.getSize(),0))!=null?t:0}}};let Un=null;function jy(){if(typeof Un=="boolean")return Un;let e=!1;try{const t={get passive(){return e=!0,!1}},n=()=>{};window.addEventListener("test",n,t),window.removeEventListener("test",n)}catch{e=!1}return Un=e,Un}function kr(e){return e.type==="touchstart"}const Zy={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:Te("columnVisibility",e)}),createColumn:(e,t)=>{e.toggleVisibility=n=>{e.getCanHide()&&t.setColumnVisibility(i=>({...i,[e.id]:n??!e.getIsVisible()}))},e.getIsVisible=()=>{var n,i;const r=e.columns;return(n=r.length?r.some(o=>o.getIsVisible()):(i=t.getState().columnVisibility)==null?void 0:i[e.id])!=null?n:!0},e.getCanHide=()=>{var n,i;return((n=e.columnDef.enableHiding)!=null?n:!0)&&((i=t.options.enableHiding)!=null?i:!0)},e.getToggleVisibilityHandler=()=>n=>{e.toggleVisibility==null||e.toggleVisibility(n.target.checked)}},createRow:(e,t)=>{e._getAllVisibleCells=E(()=>[e.getAllCells(),t.getState().columnVisibility],n=>n.filter(i=>i.column.getIsVisible()),A(t.options,"debugRows","_getAllVisibleCells")),e.getVisibleCells=E(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(n,i,r)=>[...n,...i,...r],A(t.options,"debugRows","getVisibleCells"))},createTable:e=>{const t=(n,i)=>E(()=>[i(),i().filter(r=>r.getIsVisible()).map(r=>r.id).join("_")],r=>r.filter(o=>o.getIsVisible==null?void 0:o.getIsVisible()),A(e.options,"debugColumns",n));e.getVisibleFlatColumns=t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),e.getVisibleLeafColumns=t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),e.getLeftVisibleLeafColumns=t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),e.getRightVisibleLeafColumns=t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),e.getCenterVisibleLeafColumns=t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),e.setColumnVisibility=n=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(n),e.resetColumnVisibility=n=>{var i;e.setColumnVisibility(n?{}:(i=e.initialState.columnVisibility)!=null?i:{})},e.toggleAllColumnsVisible=n=>{var i;n=(i=n)!=null?i:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((r,o)=>({...r,[o.id]:n||!(o.getCanHide!=null&&o.getCanHide())}),{}))},e.getIsAllColumnsVisible=()=>!e.getAllLeafColumns().some(n=>!(n.getIsVisible!=null&&n.getIsVisible())),e.getIsSomeColumnsVisible=()=>e.getAllLeafColumns().some(n=>n.getIsVisible==null?void 0:n.getIsVisible()),e.getToggleAllColumnsVisibilityHandler=()=>n=>{var i;e.toggleAllColumnsVisible((i=n.target)==null?void 0:i.checked)}}};function vn(e,t){return t?t==="center"?e.getCenterVisibleLeafColumns():t==="left"?e.getLeftVisibleLeafColumns():e.getRightVisibleLeafColumns():e.getVisibleLeafColumns()}const Qy={createTable:e=>{e._getGlobalFacetedRowModel=e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),e.getGlobalFacetedRowModel=()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),e._getGlobalFacetedUniqueValues=e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),e.getGlobalFacetedUniqueValues=()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,e._getGlobalFacetedMinMaxValues=e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),e.getGlobalFacetedMinMaxValues=()=>{if(e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}}},Ky={getInitialState:e=>({globalFilter:void 0,...e}),getDefaultOptions:e=>({onGlobalFilterChange:Te("globalFilter",e),globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var n;const i=(n=e.getCoreRowModel().flatRows[0])==null||(n=n._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof i=="string"||typeof i=="number"}}),createColumn:(e,t)=>{e.getCanGlobalFilter=()=>{var n,i,r,o;return((n=e.columnDef.enableGlobalFilter)!=null?n:!0)&&((i=t.options.enableGlobalFilter)!=null?i:!0)&&((r=t.options.enableFilters)!=null?r:!0)&&((o=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?o:!0)&&!!e.accessorFn}},createTable:e=>{e.getGlobalAutoFilterFn=()=>Ze.includesString,e.getGlobalFilterFn=()=>{var t,n;const{globalFilterFn:i}=e.options;return nr(i)?i:i==="auto"?e.getGlobalAutoFilterFn():(t=(n=e.options.filterFns)==null?void 0:n[i])!=null?t:Ze[i]},e.setGlobalFilter=t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},e.resetGlobalFilter=t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)}}},Jy={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:Te("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,n=!1;e._autoResetExpanded=()=>{var i,r;if(!t){e._queue(()=>{t=!0});return}if((i=(r=e.options.autoResetAll)!=null?r:e.options.autoResetExpanded)!=null?i:!e.options.manualExpanding){if(n)return;n=!0,e._queue(()=>{e.resetExpanded(),n=!1})}},e.setExpanded=i=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(i),e.toggleAllRowsExpanded=i=>{i??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},e.resetExpanded=i=>{var r,o;e.setExpanded(i?{}:(r=(o=e.initialState)==null?void 0:o.expanded)!=null?r:{})},e.getCanSomeRowsExpand=()=>e.getPrePaginationRowModel().flatRows.some(i=>i.getCanExpand()),e.getToggleAllRowsExpandedHandler=()=>i=>{i.persist==null||i.persist(),e.toggleAllRowsExpanded()},e.getIsSomeRowsExpanded=()=>{const i=e.getState().expanded;return i===!0||Object.values(i).some(Boolean)},e.getIsAllRowsExpanded=()=>{const i=e.getState().expanded;return typeof i=="boolean"?i===!0:!(!Object.keys(i).length||e.getRowModel().flatRows.some(r=>!r.getIsExpanded()))},e.getExpandedDepth=()=>{let i=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(o=>{const s=o.split(".");i=Math.max(i,s.length)}),i},e.getPreExpandedRowModel=()=>e.getSortedRowModel(),e.getExpandedRowModel=()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())},createRow:(e,t)=>{e.toggleExpanded=n=>{t.setExpanded(i=>{var r;const o=i===!0?!0:!!(i!=null&&i[e.id]);let s={};if(i===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{s[a]=!0}):s=i,n=(r=n)!=null?r:!o,!o&&n)return{...s,[e.id]:!0};if(o&&!n){const{[e.id]:a,...l}=s;return l}return i})},e.getIsExpanded=()=>{var n;const i=t.getState().expanded;return!!((n=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?n:i===!0||i!=null&&i[e.id])},e.getCanExpand=()=>{var n,i,r;return(n=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?n:((i=t.options.enableExpanding)!=null?i:!0)&&!!((r=e.subRows)!=null&&r.length)},e.getIsAllParentsExpanded=()=>{let n=!0,i=e;for(;n&&i.parentId;)i=t.getRow(i.parentId,!0),n=i.getIsExpanded();return n},e.getToggleExpandedHandler=()=>{const n=e.getCanExpand();return()=>{n&&e.toggleExpanded()}}}},po=0,mo=10,Tr=()=>({pageIndex:po,pageSize:mo}),e1={getInitialState:e=>({...e,pagination:{...Tr(),...e==null?void 0:e.pagination}}),getDefaultOptions:e=>({onPaginationChange:Te("pagination",e)}),createTable:e=>{let t=!1,n=!1;e._autoResetPageIndex=()=>{var i,r;if(!t){e._queue(()=>{t=!0});return}if((i=(r=e.options.autoResetAll)!=null?r:e.options.autoResetPageIndex)!=null?i:!e.options.manualPagination){if(n)return;n=!0,e._queue(()=>{e.resetPageIndex(),n=!1})}},e.setPagination=i=>{const r=o=>ft(i,o);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(r)},e.resetPagination=i=>{var r;e.setPagination(i?Tr():(r=e.initialState.pagination)!=null?r:Tr())},e.setPageIndex=i=>{e.setPagination(r=>{let o=ft(i,r.pageIndex);const s=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return o=Math.max(0,Math.min(o,s)),{...r,pageIndex:o}})},e.resetPageIndex=i=>{var r,o;e.setPageIndex(i?po:(r=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageIndex)!=null?r:po)},e.resetPageSize=i=>{var r,o;e.setPageSize(i?mo:(r=(o=e.initialState)==null||(o=o.pagination)==null?void 0:o.pageSize)!=null?r:mo)},e.setPageSize=i=>{e.setPagination(r=>{const o=Math.max(1,ft(i,r.pageSize)),s=r.pageSize*r.pageIndex,a=Math.floor(s/o);return{...r,pageIndex:a,pageSize:o}})},e.setPageCount=i=>e.setPagination(r=>{var o;let s=ft(i,(o=e.options.pageCount)!=null?o:-1);return typeof s=="number"&&(s=Math.max(-1,s)),{...r,pageCount:s}}),e.getPageOptions=E(()=>[e.getPageCount()],i=>{let r=[];return i&&i>0&&(r=[...new Array(i)].fill(null).map((o,s)=>s)),r},A(e.options,"debugTable","getPageOptions")),e.getCanPreviousPage=()=>e.getState().pagination.pageIndex>0,e.getCanNextPage=()=>{const{pageIndex:i}=e.getState().pagination,r=e.getPageCount();return r===-1?!0:r===0?!1:i<r-1},e.previousPage=()=>e.setPageIndex(i=>i-1),e.nextPage=()=>e.setPageIndex(i=>i+1),e.firstPage=()=>e.setPageIndex(0),e.lastPage=()=>e.setPageIndex(e.getPageCount()-1),e.getPrePaginationRowModel=()=>e.getExpandedRowModel(),e.getPaginationRowModel=()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),e.getPageCount=()=>{var i;return(i=e.options.pageCount)!=null?i:Math.ceil(e.getRowCount()/e.getState().pagination.pageSize)},e.getRowCount=()=>{var i;return(i=e.options.rowCount)!=null?i:e.getPrePaginationRowModel().rows.length}}},Rr=()=>({top:[],bottom:[]}),t1={getInitialState:e=>({rowPinning:Rr(),...e}),getDefaultOptions:e=>({onRowPinningChange:Te("rowPinning",e)}),createRow:(e,t)=>{e.pin=(n,i,r)=>{const o=i?e.getLeafRows().map(l=>{let{id:u}=l;return u}):[],s=r?e.getParentRows().map(l=>{let{id:u}=l;return u}):[],a=new Set([...s,e.id,...o]);t.setRowPinning(l=>{var u,d;if(n==="bottom"){var f,h;return{top:((f=l==null?void 0:l.top)!=null?f:[]).filter(p=>!(a!=null&&a.has(p))),bottom:[...((h=l==null?void 0:l.bottom)!=null?h:[]).filter(p=>!(a!=null&&a.has(p))),...Array.from(a)]}}if(n==="top"){var g,m;return{top:[...((g=l==null?void 0:l.top)!=null?g:[]).filter(p=>!(a!=null&&a.has(p))),...Array.from(a)],bottom:((m=l==null?void 0:l.bottom)!=null?m:[]).filter(p=>!(a!=null&&a.has(p)))}}return{top:((u=l==null?void 0:l.top)!=null?u:[]).filter(p=>!(a!=null&&a.has(p))),bottom:((d=l==null?void 0:l.bottom)!=null?d:[]).filter(p=>!(a!=null&&a.has(p)))}})},e.getCanPin=()=>{var n;const{enableRowPinning:i,enablePinning:r}=t.options;return typeof i=="function"?i(e):(n=i??r)!=null?n:!0},e.getIsPinned=()=>{const n=[e.id],{top:i,bottom:r}=t.getState().rowPinning,o=n.some(a=>i==null?void 0:i.includes(a)),s=n.some(a=>r==null?void 0:r.includes(a));return o?"top":s?"bottom":!1},e.getPinnedIndex=()=>{var n,i;const r=e.getIsPinned();if(!r)return-1;const o=(n=r==="top"?t.getTopRows():t.getBottomRows())==null?void 0:n.map(s=>{let{id:a}=s;return a});return(i=o==null?void 0:o.indexOf(e.id))!=null?i:-1}},createTable:e=>{e.setRowPinning=t=>e.options.onRowPinningChange==null?void 0:e.options.onRowPinningChange(t),e.resetRowPinning=t=>{var n,i;return e.setRowPinning(t?Rr():(n=(i=e.initialState)==null?void 0:i.rowPinning)!=null?n:Rr())},e.getIsSomeRowsPinned=t=>{var n;const i=e.getState().rowPinning;if(!t){var r,o;return!!((r=i.top)!=null&&r.length||(o=i.bottom)!=null&&o.length)}return!!((n=i[t])!=null&&n.length)},e._getPinnedRows=(t,n,i)=>{var r;return((r=e.options.keepPinnedRows)==null||r?(n??[]).map(s=>{const a=e.getRow(s,!0);return a.getIsAllParentsExpanded()?a:null}):(n??[]).map(s=>t.find(a=>a.id===s))).filter(Boolean).map(s=>({...s,position:i}))},e.getTopRows=E(()=>[e.getRowModel().rows,e.getState().rowPinning.top],(t,n)=>e._getPinnedRows(t,n,"top"),A(e.options,"debugRows","getTopRows")),e.getBottomRows=E(()=>[e.getRowModel().rows,e.getState().rowPinning.bottom],(t,n)=>e._getPinnedRows(t,n,"bottom"),A(e.options,"debugRows","getBottomRows")),e.getCenterRows=E(()=>[e.getRowModel().rows,e.getState().rowPinning.top,e.getState().rowPinning.bottom],(t,n,i)=>{const r=new Set([...n??[],...i??[]]);return t.filter(o=>!r.has(o.id))},A(e.options,"debugRows","getCenterRows"))}},n1={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:Te("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>{e.setRowSelection=t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),e.resetRowSelection=t=>{var n;return e.setRowSelection(t?{}:(n=e.initialState.rowSelection)!=null?n:{})},e.toggleAllRowsSelected=t=>{e.setRowSelection(n=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const i={...n},r=e.getPreGroupedRowModel().flatRows;return t?r.forEach(o=>{o.getCanSelect()&&(i[o.id]=!0)}):r.forEach(o=>{delete i[o.id]}),i})},e.toggleAllPageRowsSelected=t=>e.setRowSelection(n=>{const i=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),r={...n};return e.getRowModel().rows.forEach(o=>{vo(r,o.id,i,!0,e)}),r}),e.getPreSelectedRowModel=()=>e.getCoreRowModel(),e.getSelectedRowModel=E(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,n)=>Object.keys(t).length?$r(e,n):{rows:[],flatRows:[],rowsById:{}},A(e.options,"debugTable","getSelectedRowModel")),e.getFilteredSelectedRowModel=E(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,n)=>Object.keys(t).length?$r(e,n):{rows:[],flatRows:[],rowsById:{}},A(e.options,"debugTable","getFilteredSelectedRowModel")),e.getGroupedSelectedRowModel=E(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,n)=>Object.keys(t).length?$r(e,n):{rows:[],flatRows:[],rowsById:{}},A(e.options,"debugTable","getGroupedSelectedRowModel")),e.getIsAllRowsSelected=()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:n}=e.getState();let i=!!(t.length&&Object.keys(n).length);return i&&t.some(r=>r.getCanSelect()&&!n[r.id])&&(i=!1),i},e.getIsAllPageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows.filter(r=>r.getCanSelect()),{rowSelection:n}=e.getState();let i=!!t.length;return i&&t.some(r=>!n[r.id])&&(i=!1),i},e.getIsSomeRowsSelected=()=>{var t;const n=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return n>0&&n<e.getFilteredRowModel().flatRows.length},e.getIsSomePageRowsSelected=()=>{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.filter(n=>n.getCanSelect()).some(n=>n.getIsSelected()||n.getIsSomeSelected())},e.getToggleAllRowsSelectedHandler=()=>t=>{e.toggleAllRowsSelected(t.target.checked)},e.getToggleAllPageRowsSelectedHandler=()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}},createRow:(e,t)=>{e.toggleSelected=(n,i)=>{const r=e.getIsSelected();t.setRowSelection(o=>{var s;if(n=typeof n<"u"?n:!r,e.getCanSelect()&&r===n)return o;const a={...o};return vo(a,e.id,n,(s=i==null?void 0:i.selectChildren)!=null?s:!0,t),a})},e.getIsSelected=()=>{const{rowSelection:n}=t.getState();return hs(e,n)},e.getIsSomeSelected=()=>{const{rowSelection:n}=t.getState();return _o(e,n)==="some"},e.getIsAllSubRowsSelected=()=>{const{rowSelection:n}=t.getState();return _o(e,n)==="all"},e.getCanSelect=()=>{var n;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(n=t.options.enableRowSelection)!=null?n:!0},e.getCanSelectSubRows=()=>{var n;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(n=t.options.enableSubRowSelection)!=null?n:!0},e.getCanMultiSelect=()=>{var n;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(n=t.options.enableMultiRowSelection)!=null?n:!0},e.getToggleSelectedHandler=()=>{const n=e.getCanSelect();return i=>{var r;n&&e.toggleSelected((r=i.target)==null?void 0:r.checked)}}}},vo=(e,t,n,i,r)=>{var o;const s=r.getRow(t,!0);n?(s.getCanMultiSelect()||Object.keys(e).forEach(a=>delete e[a]),s.getCanSelect()&&(e[t]=!0)):delete e[t],i&&(o=s.subRows)!=null&&o.length&&s.getCanSelectSubRows()&&s.subRows.forEach(a=>vo(e,a.id,n,i,r))};function $r(e,t){const n=e.getState().rowSelection,i=[],r={},o=function(s,a){return s.map(l=>{var u;const d=hs(l,n);if(d&&(i.push(l),r[l.id]=l),(u=l.subRows)!=null&&u.length&&(l={...l,subRows:o(l.subRows)}),d)return l}).filter(Boolean)};return{rows:o(t.rows),flatRows:i,rowsById:r}}function hs(e,t){var n;return(n=t[e.id])!=null?n:!1}function _o(e,t,n){var i;if(!((i=e.subRows)!=null&&i.length))return!1;let r=!0,o=!1;return e.subRows.forEach(s=>{if(!(o&&!r)&&(s.getCanSelect()&&(hs(s,t)?o=!0:r=!1),s.subRows&&s.subRows.length)){const a=_o(s,t);a==="all"?o=!0:(a==="some"&&(o=!0),r=!1)}}),r?"all":o?"some":!1}const yo=/([0-9]+)/gm,i1=(e,t,n)=>Cc(mt(e.getValue(n)).toLowerCase(),mt(t.getValue(n)).toLowerCase()),r1=(e,t,n)=>Cc(mt(e.getValue(n)),mt(t.getValue(n))),o1=(e,t,n)=>gs(mt(e.getValue(n)).toLowerCase(),mt(t.getValue(n)).toLowerCase()),s1=(e,t,n)=>gs(mt(e.getValue(n)),mt(t.getValue(n))),a1=(e,t,n)=>{const i=e.getValue(n),r=t.getValue(n);return i>r?1:i<r?-1:0},l1=(e,t,n)=>gs(e.getValue(n),t.getValue(n));function gs(e,t){return e===t?0:e>t?1:-1}function mt(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function Cc(e,t){const n=e.split(yo).filter(Boolean),i=t.split(yo).filter(Boolean);for(;n.length&&i.length;){const r=n.shift(),o=i.shift(),s=parseInt(r,10),a=parseInt(o,10),l=[s,a].sort();if(isNaN(l[0])){if(r>o)return 1;if(o>r)return-1;continue}if(isNaN(l[1]))return isNaN(s)?-1:1;if(s>a)return 1;if(a>s)return-1}return n.length-i.length}const on={alphanumeric:i1,alphanumericCaseSensitive:r1,text:o1,textCaseSensitive:s1,datetime:a1,basic:l1},u1={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto",sortUndefined:1}),getDefaultOptions:e=>({onSortingChange:Te("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>{e.getAutoSortingFn=()=>{const n=t.getFilteredRowModel().flatRows.slice(10);let i=!1;for(const r of n){const o=r==null?void 0:r.getValue(e.id);if(Object.prototype.toString.call(o)==="[object Date]")return on.datetime;if(typeof o=="string"&&(i=!0,o.split(yo).length>1))return on.alphanumeric}return i?on.text:on.basic},e.getAutoSortDir=()=>{const n=t.getFilteredRowModel().flatRows[0];return typeof(n==null?void 0:n.getValue(e.id))=="string"?"asc":"desc"},e.getSortingFn=()=>{var n,i;if(!e)throw new Error;return nr(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(n=(i=t.options.sortingFns)==null?void 0:i[e.columnDef.sortingFn])!=null?n:on[e.columnDef.sortingFn]},e.toggleSorting=(n,i)=>{const r=e.getNextSortingOrder(),o=typeof n<"u"&&n!==null;t.setSorting(s=>{const a=s==null?void 0:s.find(g=>g.id===e.id),l=s==null?void 0:s.findIndex(g=>g.id===e.id);let u=[],d,f=o?n:r==="desc";if(s!=null&&s.length&&e.getCanMultiSort()&&i?a?d="toggle":d="add":s!=null&&s.length&&l!==s.length-1?d="replace":a?d="toggle":d="replace",d==="toggle"&&(o||r||(d="remove")),d==="add"){var h;u=[...s,{id:e.id,desc:f}],u.splice(0,u.length-((h=t.options.maxMultiSortColCount)!=null?h:Number.MAX_SAFE_INTEGER))}else d==="toggle"?u=s.map(g=>g.id===e.id?{...g,desc:f}:g):d==="remove"?u=s.filter(g=>g.id!==e.id):u=[{id:e.id,desc:f}];return u})},e.getFirstSortDir=()=>{var n,i;return((n=(i=e.columnDef.sortDescFirst)!=null?i:t.options.sortDescFirst)!=null?n:e.getAutoSortDir()==="desc")?"desc":"asc"},e.getNextSortingOrder=n=>{var i,r;const o=e.getFirstSortDir(),s=e.getIsSorted();return s?s!==o&&((i=t.options.enableSortingRemoval)==null||i)&&(!(n&&(r=t.options.enableMultiRemove)!=null)||r)?!1:s==="desc"?"asc":"desc":o},e.getCanSort=()=>{var n,i;return((n=e.columnDef.enableSorting)!=null?n:!0)&&((i=t.options.enableSorting)!=null?i:!0)&&!!e.accessorFn},e.getCanMultiSort=()=>{var n,i;return(n=(i=e.columnDef.enableMultiSort)!=null?i:t.options.enableMultiSort)!=null?n:!!e.accessorFn},e.getIsSorted=()=>{var n;const i=(n=t.getState().sorting)==null?void 0:n.find(r=>r.id===e.id);return i?i.desc?"desc":"asc":!1},e.getSortIndex=()=>{var n,i;return(n=(i=t.getState().sorting)==null?void 0:i.findIndex(r=>r.id===e.id))!=null?n:-1},e.clearSorting=()=>{t.setSorting(n=>n!=null&&n.length?n.filter(i=>i.id!==e.id):[])},e.getToggleSortingHandler=()=>{const n=e.getCanSort();return i=>{n&&(i.persist==null||i.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(i):!1))}}},createTable:e=>{e.setSorting=t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),e.resetSorting=t=>{var n,i;e.setSorting(t?[]:(n=(i=e.initialState)==null?void 0:i.sorting)!=null?n:[])},e.getPreSortedRowModel=()=>e.getGroupedRowModel(),e.getSortedRowModel=()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())}},c1=[Fy,Zy,Yy,qy,Vy,Ny,Qy,Ky,u1,Uy,Jy,e1,t1,n1,Xy];function d1(e){var t,n;process.env.NODE_ENV!=="production"&&(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");const i=[...c1,...(t=e._features)!=null?t:[]];let r={_features:i};const o=r._features.reduce((h,g)=>Object.assign(h,g.getDefaultOptions==null?void 0:g.getDefaultOptions(r)),{}),s=h=>r.options.mergeOptions?r.options.mergeOptions(o,h):{...o,...h};let l={...{},...(n=e.initialState)!=null?n:{}};r._features.forEach(h=>{var g;l=(g=h.getInitialState==null?void 0:h.getInitialState(l))!=null?g:l});const u=[];let d=!1;const f={_features:i,options:{...o,...e},initialState:l,_queue:h=>{u.push(h),d||(d=!0,Promise.resolve().then(()=>{for(;u.length;)u.shift()();d=!1}).catch(g=>setTimeout(()=>{throw g})))},reset:()=>{r.setState(r.initialState)},setOptions:h=>{const g=ft(h,r.options);r.options=s(g)},getState:()=>r.options.state,setState:h=>{r.options.onStateChange==null||r.options.onStateChange(h)},_getRowId:(h,g,m)=>{var p;return(p=r.options.getRowId==null?void 0:r.options.getRowId(h,g,m))!=null?p:`${m?[m.id,g].join("."):g}`},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:(h,g)=>{let m=(g?r.getPrePaginationRowModel():r.getRowModel()).rowsById[h];if(!m&&(m=r.getCoreRowModel().rowsById[h],!m))throw process.env.NODE_ENV!=="production"?new Error(`getRow could not find row with ID: ${h}`):new Error;return m},_getDefaultColumnDef:E(()=>[r.options.defaultColumn],h=>{var g;return h=(g=h)!=null?g:{},{header:m=>{const p=m.header.column.columnDef;return p.accessorKey?p.accessorKey:p.accessorFn?p.id:null},cell:m=>{var p,v;return(p=(v=m.renderValue())==null||v.toString==null?void 0:v.toString())!=null?p:null},...r._features.reduce((m,p)=>Object.assign(m,p.getDefaultColumnDef==null?void 0:p.getDefaultColumnDef()),{}),...h}},A(e,"debugColumns","_getDefaultColumnDef")),_getColumnDefs:()=>r.options.columns,getAllColumns:E(()=>[r._getColumnDefs()],h=>{const g=function(m,p,v){return v===void 0&&(v=0),m.map(_=>{const y=Ay(r,_,v,p),x=_;return y.columns=x.columns?g(x.columns,y,v+1):[],y})};return g(h)},A(e,"debugColumns","getAllColumns")),getAllFlatColumns:E(()=>[r.getAllColumns()],h=>h.flatMap(g=>g.getFlatColumns()),A(e,"debugColumns","getAllFlatColumns")),_getAllFlatColumnsById:E(()=>[r.getAllFlatColumns()],h=>h.reduce((g,m)=>(g[m.id]=m,g),{}),A(e,"debugColumns","getAllFlatColumnsById")),getAllLeafColumns:E(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(h,g)=>{let m=h.flatMap(p=>p.getLeafColumns());return g(m)},A(e,"debugColumns","getAllLeafColumns")),getColumn:h=>{const g=r._getAllFlatColumnsById()[h];return process.env.NODE_ENV!=="production"&&!g&&console.error(`[Table] Column with id '${h}' does not exist.`),g}};Object.assign(r,f);for(let h=0;h<r._features.length;h++){const g=r._features[h];g==null||g.createTable==null||g.createTable(r)}return r}function f1(){return e=>E(()=>[e.options.data],t=>{const n={rows:[],flatRows:[],rowsById:{}},i=function(r,o,s){o===void 0&&(o=0);const a=[];for(let u=0;u<r.length;u++){const d=ds(e,e._getRowId(r[u],u,s),r[u],u,o,void 0,s==null?void 0:s.id);if(n.flatRows.push(d),n.rowsById[d.id]=d,a.push(d),e.options.getSubRows){var l;d.originalSubRows=e.options.getSubRows(r[u],u),(l=d.originalSubRows)!=null&&l.length&&(d.subRows=i(d.originalSubRows,o+1,d))}}return a};return n.rows=i(t),n},A(e.options,"debugTable","getRowModel",()=>e._autoResetPageIndex()))}function h1(e){const t=[],n=i=>{var r;t.push(i),(r=i.subRows)!=null&&r.length&&i.getIsExpanded()&&i.subRows.forEach(n)};return e.rows.forEach(n),{rows:t,flatRows:e.flatRows,rowsById:e.rowsById}}function g1(e,t,n){return n.options.filterFromLeafRows?p1(e,t,n):m1(e,t,n)}function p1(e,t,n){var i;const r=[],o={},s=(i=n.options.maxLeafRowFilterDepth)!=null?i:100,a=function(l,u){u===void 0&&(u=0);const d=[];for(let h=0;h<l.length;h++){var f;let g=l[h];const m=ds(n,g.id,g.original,g.index,g.depth,void 0,g.parentId);if(m.columnFilters=g.columnFilters,(f=g.subRows)!=null&&f.length&&u<s){if(m.subRows=a(g.subRows,u+1),g=m,t(g)&&!m.subRows.length){d.push(g),o[g.id]=g,r.push(g);continue}if(t(g)||m.subRows.length){d.push(g),o[g.id]=g,r.push(g);continue}}else g=m,t(g)&&(d.push(g),o[g.id]=g,r.push(g))}return d};return{rows:a(e),flatRows:r,rowsById:o}}function m1(e,t,n){var i;const r=[],o={},s=(i=n.options.maxLeafRowFilterDepth)!=null?i:100,a=function(l,u){u===void 0&&(u=0);const d=[];for(let h=0;h<l.length;h++){let g=l[h];if(t(g)){var f;if((f=g.subRows)!=null&&f.length&&u<s){const p=ds(n,g.id,g.original,g.index,g.depth,void 0,g.parentId);p.subRows=a(g.subRows,u+1),g=p}d.push(g),r.push(g),o[g.id]=g}}return d};return{rows:a(e),flatRows:r,rowsById:o}}function v1(){return e=>E(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,n,i)=>{if(!t.rows.length||!(n!=null&&n.length)&&!i){for(let h=0;h<t.flatRows.length;h++)t.flatRows[h].columnFilters={},t.flatRows[h].columnFiltersMeta={};return t}const r=[],o=[];(n??[]).forEach(h=>{var g;const m=e.getColumn(h.id);if(!m)return;const p=m.getFilterFn();if(!p){process.env.NODE_ENV!=="production"&&console.warn(`Could not find a valid 'column.filterFn' for column with the ID: ${m.id}.`);return}r.push({id:h.id,filterFn:p,resolvedValue:(g=p.resolveFilterValue==null?void 0:p.resolveFilterValue(h.value))!=null?g:h.value})});const s=(n??[]).map(h=>h.id),a=e.getGlobalFilterFn(),l=e.getAllLeafColumns().filter(h=>h.getCanGlobalFilter());i&&a&&l.length&&(s.push("__global__"),l.forEach(h=>{var g;o.push({id:h.id,filterFn:a,resolvedValue:(g=a.resolveFilterValue==null?void 0:a.resolveFilterValue(i))!=null?g:i})}));let u,d;for(let h=0;h<t.flatRows.length;h++){const g=t.flatRows[h];if(g.columnFilters={},r.length)for(let m=0;m<r.length;m++){u=r[m];const p=u.id;g.columnFilters[p]=u.filterFn(g,p,u.resolvedValue,v=>{g.columnFiltersMeta[p]=v})}if(o.length){for(let m=0;m<o.length;m++){d=o[m];const p=d.id;if(d.filterFn(g,p,d.resolvedValue,v=>{g.columnFiltersMeta[p]=v})){g.columnFilters.__global__=!0;break}}g.columnFilters.__global__!==!0&&(g.columnFilters.__global__=!1)}}const f=h=>{for(let g=0;g<s.length;g++)if(h.columnFilters[s[g]]===!1)return!1;return!0};return g1(t.rows,f,e)},A(e.options,"debugTable","getFilteredRowModel",()=>e._autoResetPageIndex()))}function _1(e){return t=>E(()=>[t.getState().pagination,t.getPrePaginationRowModel(),t.options.paginateExpandedRows?void 0:t.getState().expanded],(n,i)=>{if(!i.rows.length)return i;const{pageSize:r,pageIndex:o}=n;let{rows:s,flatRows:a,rowsById:l}=i;const u=r*o,d=u+r;s=s.slice(u,d);let f;t.options.paginateExpandedRows?f={rows:s,flatRows:a,rowsById:l}:f=h1({rows:s,flatRows:a,rowsById:l}),f.flatRows=[];const h=g=>{f.flatRows.push(g),g.subRows.length&&g.subRows.forEach(h)};return f.rows.forEach(h),f},A(t.options,"debugTable","getPaginationRowModel"))}function y1(){return e=>E(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,n)=>{if(!n.rows.length||!(t!=null&&t.length))return n;const i=e.getState().sorting,r=[],o=i.filter(l=>{var u;return(u=e.getColumn(l.id))==null?void 0:u.getCanSort()}),s={};o.forEach(l=>{const u=e.getColumn(l.id);u&&(s[l.id]={sortUndefined:u.columnDef.sortUndefined,invertSorting:u.columnDef.invertSorting,sortingFn:u.getSortingFn()})});const a=l=>{const u=l.map(d=>({...d}));return u.sort((d,f)=>{for(let g=0;g<o.length;g+=1){var h;const m=o[g],p=s[m.id],v=p.sortUndefined,_=(h=m==null?void 0:m.desc)!=null?h:!1;let y=0;if(v){const x=d.getValue(m.id),w=f.getValue(m.id),S=x===void 0,b=w===void 0;if(S||b){if(v==="first")return S?-1:1;if(v==="last")return S?1:-1;y=S&&b?0:S?v:-v}}if(y===0&&(y=p.sortingFn(d,f,m.id)),y!==0)return _&&(y*=-1),p.invertSorting&&(y*=-1),y}return d.index-f.index}),u.forEach(d=>{var f;r.push(d),(f=d.subRows)!=null&&f.length&&(d.subRows=a(d.subRows))}),u};return{rows:a(n.rows),flatRows:r,rowsById:n.rowsById}},A(e.options,"debugTable","getSortedRowModel",()=>e._autoResetPageIndex()))}/**
|
|
481
|
-
* vue-table
|
|
482
|
-
*
|
|
483
|
-
* Copyright (c) TanStack
|
|
484
|
-
*
|
|
485
|
-
* This source code is licensed under the MIT license found in the
|
|
486
|
-
* LICENSE.md file in the root directory of this source tree.
|
|
487
|
-
*
|
|
488
|
-
* @license MIT
|
|
489
|
-
*/function Wn(){return!0}const x1=Symbol("merge-proxy"),w1={get(e,t,n){return t===x1?n:e.get(t)},has(e,t){return e.has(t)},set:Wn,deleteProperty:Wn,getOwnPropertyDescriptor(e,t){return{configurable:!0,enumerable:!0,get(){return e.get(t)},set:Wn,deleteProperty:Wn}},ownKeys(e){return e.keys()}};function Mr(e){return"value"in e?e.value:e}function dn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return new Proxy({get(i){for(let r=t.length-1;r>=0;r--){const o=Mr(t[r])[i];if(o!==void 0)return o}},has(i){for(let r=t.length-1;r>=0;r--)if(i in Mr(t[r]))return!0;return!1},keys(){const i=[];for(let r=0;r<t.length;r++)i.push(...Object.keys(Mr(t[r])));return[...Array.from(new Set(i))]}},w1)}const Er=c.defineComponent({props:["render","props"],setup:e=>()=>typeof e.render=="function"||typeof e.render=="object"?c.h(e.render,e.props):e.render});function Ya(e){return dn(e,{data:c.unref(e.data)})}function S1(e){const t=c.isRef(e.data),n=dn({state:{},onStateChange:()=>{},renderFallbackValue:null,mergeOptions(o,s){return t?{...o,...s}:dn(o,s)}},t?Ya(e):e),i=d1(n);if(t){const o=c.shallowRef(e.data);c.watch(o,()=>{i.setState(s=>({...s,data:o.value}))},{immediate:!0})}const r=c.ref(i.initialState);return c.watchEffect(()=>{i.setOptions(o=>{var s;const a=new Proxy({},{get:(l,u)=>r.value[u]});return dn(o,t?Ya(e):e,{state:dn(a,(s=e.state)!=null?s:{}),onStateChange:l=>{l instanceof Function?r.value=l(r.value):r.value=l,e.onStateChange==null||e.onStateChange(l)}})})}),i}const b1={class:"overflow-x-auto w-full"},C1={key:0,class:"mb-2"},k1={class:"flex justify-between items-center"},T1={class:"flex items-center gap-2"},R1=["value"],$1={class:"flex items-center gap-2"},M1=["disabled"],E1=["disabled"],A1={key:1,class:"mb-2"},F1=["onClick"],V1={class:"flex items-center gap-1"},N1={key:1,class:"flex-1"},D1={key:2,class:"w-4"},P1={class:"divide-y divide-border"},O1=["onClick"],L1={key:1},I1=["colspan"],B1={key:2,class:"mt-2"},z1={class:"flex justify-between items-center"},H1={class:"flex items-center gap-2"},G1=["value"],U1={class:"flex items-center gap-2"},W1=["disabled"],Y1=["disabled"],q1=c.defineComponent({__name:"Table",props:{data:{},columns:{},enableSorting:{type:Boolean,default:!0},enableMultiSort:{type:Boolean,default:!1},enablePagination:{type:Boolean,default:!0},enableFiltering:{type:Boolean,default:!1},enableRowSelection:{type:Boolean,default:!1},tableSize:{default:"md"},striped:{type:Boolean,default:!0},hover:{type:Boolean,default:!0},bordered:{type:Boolean,default:!1},paginationPosition:{default:"bottom"},pageSizeOptions:{default:[10,20,50,100]},initialPageSize:{default:10},onRowClick:{},getRowClass:{}},emits:["update:sorting","update:pagination","update:filters","update:selectedRows","row-click"],setup(e,{expose:t,emit:n}){const i=e,r=n,o=c.ref([]),s=c.ref({pageIndex:0,pageSize:i.initialPageSize}),a=c.ref([]),l=c.ref({}),u=c.ref(""),d=S1({get data(){return i.data},get columns(){return i.columns},state:{get sorting(){return o.value},get pagination(){return s.value},get columnFilters(){return a.value},get rowSelection(){return l.value},get globalFilter(){return u.value}},onSortingChange:v=>{o.value=typeof v=="function"?v(o.value):v,r("update:sorting",o.value)},onPaginationChange:v=>{s.value=typeof v=="function"?v(s.value):v,r("update:pagination",s.value)},onColumnFiltersChange:v=>{a.value=typeof v=="function"?v(a.value):v,r("update:filters",a.value)},onRowSelectionChange:v=>{l.value=typeof v=="function"?v(l.value):v,r("update:selectedRows",l.value)},onGlobalFilterChange:v=>{u.value=typeof v=="function"?v(u.value):v},getCoreRowModel:f1(),getSortedRowModel:y1(),getPaginationRowModel:_1(),getFilteredRowModel:v1(),enableMultiSort:i.enableMultiSort,enableSorting:i.enableSorting,enableRowSelection:i.enableRowSelection,enableFilters:i.enableFiltering,manualPagination:!i.enablePagination}),f=v=>{i.onRowClick&&i.onRowClick(v),r("row-click",v)},h=c.computed(()=>{switch(i.tableSize){case"sm":return{table:"text-xs",cell:"px-2 py-1",pagination:"text-xs"};case"lg":return{table:"text-base",cell:"px-6 py-4",pagination:"text-base"};default:return{table:"text-sm",cell:"px-4 py-2",pagination:"text-sm"}}}),g=c.computed(()=>["min-w-full divide-y divide-neutral-600 border-collapse",h.value.table,i.bordered?"border border-gray-200":""]),m=v=>{const _=["transition-colors",i.hover?"dark:hover:bg-neutral-900 hover:bg-neutral-100":"",i.striped&&v.index%2===1?"bg-neutral":"",i.enableRowSelection&&v.getIsSelected()?"bg-blue-50 hover:bg-blue-100":""];return i.getRowClass&&_.push(i.getRowClass(v)),_.join(" ")},p=(v=!1)=>[h.value.cell,v?"font-semibold text-neutral-500 border-b border-border capitalize":" text-neutral-600 dark:text-neutral-400",i.bordered?"border border-border":""].join(" ");return t({tableInstance:d,sorting:o,pagination:s,columnFilters:a,rowSelection:l,globalFilter:u}),(v,_)=>(c.openBlock(),c.createElementBlock("div",b1,[["top","both"].includes(v.paginationPosition)&&v.enablePagination?(c.openBlock(),c.createElementBlock("div",C1,[c.createElementVNode("div",k1,[c.createElementVNode("div",T1,[c.createElementVNode("span",{class:c.normalizeClass(h.value.pagination)},"Rows per page:",2),c.withDirectives(c.createElementVNode("select",{"onUpdate:modelValue":_[0]||(_[0]=y=>s.value.pageSize=y),class:"border border-gray-300 rounded px-2 py-1 outline-none focus:border-blue-500"},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(v.pageSizeOptions,y=>(c.openBlock(),c.createElementBlock("option",{key:y,value:y},c.toDisplayString(y),9,R1))),128))],512),[[c.vModelSelect,s.value.pageSize]])]),c.createElementVNode("div",$1,[c.createElementVNode("button",{onClick:_[1]||(_[1]=(...y)=>c.unref(d).previousPage&&c.unref(d).previousPage(...y)),disabled:!c.unref(d).getCanPreviousPage(),class:"px-3 py-1 border border-gray-300 rounded disabled:opacity-50"},_[7]||(_[7]=[c.createElementVNode("span",{class:"sr-only"},"Previous",-1),c.createElementVNode("span",{class:"inline-block"},"<",-1)]),8,M1),c.createElementVNode("span",{class:c.normalizeClass(h.value.pagination)}," Page "+c.toDisplayString(c.unref(d).getState().pagination.pageIndex+1)+" of "+c.toDisplayString(c.unref(d).getPageCount()),3),c.createElementVNode("button",{onClick:_[2]||(_[2]=(...y)=>c.unref(d).nextPage&&c.unref(d).nextPage(...y)),disabled:!c.unref(d).getCanNextPage(),class:"px-3 py-1 border border-gray-300 rounded disabled:opacity-50"},_[8]||(_[8]=[c.createElementVNode("span",{class:"sr-only"},"Next",-1),c.createElementVNode("span",{class:"inline-block"},">",-1)]),8,E1)])])])):c.createCommentVNode("",!0),v.enableFiltering?(c.openBlock(),c.createElementBlock("div",A1,[c.withDirectives(c.createElementVNode("input",{"onUpdate:modelValue":_[3]||(_[3]=y=>u.value=y),placeholder:"Search all columns...",class:"border border-gray-300 rounded px-3 py-2 w-full max-w-sm"},null,512),[[c.vModelText,u.value]])])):c.createCommentVNode("",!0),c.createElementVNode("table",{class:c.normalizeClass(g.value)},[c.createElementVNode("thead",null,[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(c.unref(d).getHeaderGroups(),y=>(c.openBlock(),c.createElementBlock("tr",{key:y.id},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(y.headers,x=>(c.openBlock(),c.createElementBlock("th",{key:x.id,class:c.normalizeClass([p(!0),x.column.getCanSort()?"cursor-pointer select-none":"","text-left"]),onClick:w=>x.column.getToggleSortingHandler()},[c.createElementVNode("div",V1,[x.isPlaceholder?(c.openBlock(),c.createBlock(c.unref(Er),{key:0,render:x.column.columnDef.header,props:x.getContext()},null,8,["render","props"])):(c.openBlock(),c.createElementBlock("div",N1,[c.createVNode(c.unref(Er),{render:x.column.columnDef.header,props:x.getContext()},null,8,["render","props"])])),x.column.getCanSort()?(c.openBlock(),c.createElementBlock("div",D1,c.toDisplayString({asc:"▲",desc:"▼"}[x.column.getIsSorted()]??"⬍"),1)):c.createCommentVNode("",!0)])],10,F1))),128))]))),128))]),c.createElementVNode("tbody",P1,[c.unref(d).getRowModel().rows.length?(c.openBlock(!0),c.createElementBlock(c.Fragment,{key:0},c.renderList(c.unref(d).getRowModel().rows,y=>(c.openBlock(),c.createElementBlock("tr",{key:y.id,class:c.normalizeClass(m(y)),onClick:x=>f(y)},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(y.getVisibleCells(),x=>(c.openBlock(),c.createElementBlock("td",{key:x.id,class:c.normalizeClass(p())},[c.createVNode(c.unref(Er),{render:x.column.columnDef.cell,props:x.getContext()},null,8,["render","props"])],2))),128))],10,O1))),128)):(c.openBlock(),c.createElementBlock("tr",L1,[c.createElementVNode("td",{colspan:c.unref(d).getAllColumns().length,class:c.normalizeClass([p(),"text-center py-4"])}," No results found ",10,I1)]))])],2),["bottom","both"].includes(v.paginationPosition)&&v.enablePagination?(c.openBlock(),c.createElementBlock("div",B1,[c.createElementVNode("div",z1,[c.createElementVNode("div",H1,[c.createElementVNode("span",{class:c.normalizeClass(h.value.pagination)},"Rows per page:",2),c.withDirectives(c.createElementVNode("select",{"onUpdate:modelValue":_[4]||(_[4]=y=>s.value.pageSize=y),class:"border border-gray-300 rounded px-2 py-1 outline-none focus:border-blue-500"},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(v.pageSizeOptions,y=>(c.openBlock(),c.createElementBlock("option",{key:y,value:y},c.toDisplayString(y),9,G1))),128))],512),[[c.vModelSelect,s.value.pageSize]])]),c.createElementVNode("div",U1,[c.createElementVNode("button",{onClick:_[5]||(_[5]=(...y)=>c.unref(d).previousPage&&c.unref(d).previousPage(...y)),disabled:!c.unref(d).getCanPreviousPage(),class:"px-3 py-1 border border-gray-300 rounded disabled:opacity-50"},_[9]||(_[9]=[c.createElementVNode("span",{class:"sr-only"},"Previous",-1),c.createElementVNode("span",{class:"inline-block"},"<",-1)]),8,W1),c.createElementVNode("span",{class:c.normalizeClass(h.value.pagination)}," Page "+c.toDisplayString(c.unref(d).getState().pagination.pageIndex+1)+" of "+c.toDisplayString(c.unref(d).getPageCount()),3),c.createElementVNode("button",{onClick:_[6]||(_[6]=(...y)=>c.unref(d).nextPage&&c.unref(d).nextPage(...y)),disabled:!c.unref(d).getCanNextPage(),class:"px-3 py-1 border border-gray-300 rounded disabled:opacity-50"},_[10]||(_[10]=[c.createElementVNode("span",{class:"sr-only"},"Next",-1),c.createElementVNode("span",{class:"inline-block"},">",-1)]),8,Y1)])])])):c.createCommentVNode("",!0)]))}}),X1={"ETF Shares Vital":{name:"ETF Shares Vital",color:"#3b82f6"},"Vitainvest Core":{name:"Vitainvest Core",color:"#d946ef"},"iShares Tech Growth":{name:"iShares Tech Growth",color:"#8b5cf6"}},qa=[{date:"Aug 01","ETF Shares Vital":2100.2,"Vitainvest Core":4434.1,"iShares Tech Growth":7943.2},{date:"Aug 02","ETF Shares Vital":2943,"Vitainvest Core":4954.1,"iShares Tech Growth":8954.1},{date:"Aug 03","ETF Shares Vital":4889.5,"Vitainvest Core":6100.2,"iShares Tech Growth":9123.7},{date:"Aug 04","ETF Shares Vital":3909.8,"Vitainvest Core":4909.7,"iShares Tech Growth":7478.4},{date:"Aug 05","ETF Shares Vital":5778.7,"Vitainvest Core":7103.1,"iShares Tech Growth":9504.3},{date:"Aug 06","ETF Shares Vital":5900.9,"Vitainvest Core":7534.3,"iShares Tech Growth":9943.4},{date:"Aug 07","ETF Shares Vital":4129.4,"Vitainvest Core":7412.1,"iShares Tech Growth":10112.2},{date:"Aug 08","ETF Shares Vital":6021.2,"Vitainvest Core":7834.4,"iShares Tech Growth":10290.2},{date:"Aug 09","ETF Shares Vital":6279.8,"Vitainvest Core":8159.1,"iShares Tech Growth":10349.6},{date:"Aug 10","ETF Shares Vital":6224.5,"Vitainvest Core":8260.6,"iShares Tech Growth":10415.4},{date:"Aug 11","ETF Shares Vital":6380.6,"Vitainvest Core":8965.3,"iShares Tech Growth":10636.3},{date:"Aug 12","ETF Shares Vital":6414.4,"Vitainvest Core":7989.3,"iShares Tech Growth":10900.5},{date:"Aug 13","ETF Shares Vital":6540.1,"Vitainvest Core":7839.6,"iShares Tech Growth":11040.4},{date:"Aug 14","ETF Shares Vital":6634.4,"Vitainvest Core":7343.8,"iShares Tech Growth":11390.5},{date:"Aug 15","ETF Shares Vital":7124.6,"Vitainvest Core":6903.7,"iShares Tech Growth":11423.1},{date:"Aug 16","ETF Shares Vital":7934.5,"Vitainvest Core":6273.6,"iShares Tech Growth":12134.4},{date:"Aug 17","ETF Shares Vital":10287.8,"Vitainvest Core":5900.3,"iShares Tech Growth":12034.4},{date:"Aug 18","ETF Shares Vital":10323.2,"Vitainvest Core":5732.1,"iShares Tech Growth":11011.7},{date:"Aug 19","ETF Shares Vital":10511.4,"Vitainvest Core":5523.1,"iShares Tech Growth":11834.8},{date:"Aug 20","ETF Shares Vital":11043.9,"Vitainvest Core":5422.3,"iShares Tech Growth":12387.1},{date:"Aug 21","ETF Shares Vital":6700.7,"Vitainvest Core":5334.2,"iShares Tech Growth":11032.2},{date:"Aug 22","ETF Shares Vital":6900.8,"Vitainvest Core":4943.4,"iShares Tech Growth":10134.2},{date:"Aug 23","ETF Shares Vital":7934.5,"Vitainvest Core":4812.1,"iShares Tech Growth":9921.2},{date:"Aug 24","ETF Shares Vital":9021,"Vitainvest Core":2729.1,"iShares Tech Growth":10549.8},{date:"Aug 25","ETF Shares Vital":9198.2,"Vitainvest Core":2178,"iShares Tech Growth":10968.4},{date:"Aug 26","ETF Shares Vital":9557.1,"Vitainvest Core":2158.3,"iShares Tech Growth":11059.1},{date:"Aug 27","ETF Shares Vital":9959.8,"Vitainvest Core":2100.8,"iShares Tech Growth":11903.6},{date:"Aug 28","ETF Shares Vital":10034.6,"Vitainvest Core":2934.4,"iShares Tech Growth":12143.3},{date:"Aug 29","ETF Shares Vital":10243.8,"Vitainvest Core":3223.4,"iShares Tech Growth":12930.1},{date:"Aug 30","ETF Shares Vital":10078.5,"Vitainvest Core":3779.1,"iShares Tech Growth":13420.5},{date:"Aug 31","ETF Shares Vital":11134.6,"Vitainvest Core":4190.3,"iShares Tech Growth":14443.2},{date:"Sep 01","ETF Shares Vital":12347.2,"Vitainvest Core":4839.1,"iShares Tech Growth":14532.1},{date:"Sep 02","ETF Shares Vital":12593.8,"Vitainvest Core":5153.3,"iShares Tech Growth":14283.5},{date:"Sep 03","ETF Shares Vital":12043.4,"Vitainvest Core":5234.8,"iShares Tech Growth":14078.9},{date:"Sep 04","ETF Shares Vital":12144.9,"Vitainvest Core":5478.4,"iShares Tech Growth":13859.7},{date:"Sep 05","ETF Shares Vital":12489.5,"Vitainvest Core":5741.1,"iShares Tech Growth":13539.2},{date:"Sep 06","ETF Shares Vital":12748.7,"Vitainvest Core":6743.9,"iShares Tech Growth":13643.2},{date:"Sep 07","ETF Shares Vital":12933.2,"Vitainvest Core":7832.8,"iShares Tech Growth":14629.2},{date:"Sep 08","ETF Shares Vital":13028.8,"Vitainvest Core":8943.2,"iShares Tech Growth":13611.2},{date:"Sep 09","ETF Shares Vital":13412.4,"Vitainvest Core":9932.2,"iShares Tech Growth":12515.2},{date:"Sep 10","ETF Shares Vital":13649,"Vitainvest Core":10139.2,"iShares Tech Growth":11143.8},{date:"Sep 11","ETF Shares Vital":13748.5,"Vitainvest Core":10441.2,"iShares Tech Growth":8929.2},{date:"Sep 12","ETF Shares Vital":13148.1,"Vitainvest Core":10933.8,"iShares Tech Growth":8943.2},{date:"Sep 13","ETF Shares Vital":12839.6,"Vitainvest Core":11073.4,"iShares Tech Growth":7938.3},{date:"Sep 14","ETF Shares Vital":12428.2,"Vitainvest Core":11128.3,"iShares Tech Growth":7533.4},{date:"Sep 15","ETF Shares Vital":12012.8,"Vitainvest Core":11412.3,"iShares Tech Growth":7100.4},{date:"Sep 16","ETF Shares Vital":11801.3,"Vitainvest Core":10501.1,"iShares Tech Growth":6532.1},{date:"Sep 17","ETF Shares Vital":10102.9,"Vitainvest Core":8923.3,"iShares Tech Growth":4332.8},{date:"Sep 18","ETF Shares Vital":12132.5,"Vitainvest Core":10212.1,"iShares Tech Growth":7847.4},{date:"Sep 19","ETF Shares Vital":12901.1,"Vitainvest Core":10101.7,"iShares Tech Growth":7223.3},{date:"Sep 20","ETF Shares Vital":13132.6,"Vitainvest Core":12132.3,"iShares Tech Growth":6900.2},{date:"Sep 21","ETF Shares Vital":14132.2,"Vitainvest Core":13212.5,"iShares Tech Growth":5932.2},{date:"Sep 22","ETF Shares Vital":14245.8,"Vitainvest Core":12163.4,"iShares Tech Growth":5577.1},{date:"Sep 23","ETF Shares Vital":14328.3,"Vitainvest Core":10036.1,"iShares Tech Growth":5439.2},{date:"Sep 24","ETF Shares Vital":14949.9,"Vitainvest Core":8985.1,"iShares Tech Growth":4463.1},{date:"Sep 25","ETF Shares Vital":15967.5,"Vitainvest Core":9700.1,"iShares Tech Growth":4123.2},{date:"Sep 26","ETF Shares Vital":17349.3,"Vitainvest Core":10943.4,"iShares Tech Growth":3935.1}],Xa={value:{name:"Value",color:"#05DF72"}},xo=[{date:"16/12/25",value:6e4},{date:"08/12/25",value:4e4},{date:"30/11/25",value:4e4},{date:"22/11/25",value:3e4},{date:"14/11/25",value:65e3},{date:"06/11/25",value:9e4},{date:"29/10/25",value:35e3},{date:"21/10/25",value:25e3},{date:"13/10/25",value:6e4},{date:"05/10/25",value:55e3},{date:"27/09/25",value:11e4},{date:"19/09/25",value:6e4},{date:"11/09/25",value:5e4},{date:"03/09/25",value:8e4},{date:"26/08/25",value:3e4},{date:"18/08/25",value:45e3},{date:"10/08/25",value:55e3},{date:"02/08/25",value:7e4},{date:"25/07/25",value:4e4},{date:"17/07/25",value:6e4},{date:"09/07/25",value:35e3},{date:"01/07/25",value:5e4},{date:"23/06/25",value:65e3},{date:"15/06/25",value:8e4},{date:"07/06/25",value:45e3},{date:"30/05/25",value:75e3},{date:"22/05/25",value:55e3},{date:"14/05/25",value:6e4},{date:"06/05/25",value:4e4},{date:"28/04/25",value:3e4},{date:"20/04/25",value:5e4},{date:"12/04/25",value:7e4},{date:"04/04/25",value:65e3},{date:"27/03/25",value:85e3},{date:"19/03/25",value:55e3},{date:"11/03/25",value:45e3},{date:"03/03/25",value:6e4},{date:"25/02/25",value:35e3},{date:"16/02/25",value:5e4},{date:"08/02/25",value:75e3},{date:"31/01/25",value:65e3},{date:"23/01/25",value:4e4},{date:"15/01/25",value:55e3},{date:"07/01/25",value:8e4},{date:"30/12/24",value:7e4},{date:"22/12/24",value:6e4},{date:"14/12/24",value:45e3},{date:"06/12/24",value:55e3}].reverse(),kc=xo.slice(0,3);console.log(kc,"RevenueDataSmall");const j1={class:"max-w-7xl mx-auto py-4"},Z1={class:"py-24 sm:py-24 relative px-4 lg:px-0"},Q1={class:"flex items-center justify-center mb-4"},K1={class:"flex items-center gap-4 mt-8 justify-center"},J1={class:"grid grid-cols-12 gap-8 mb-8"},ex={class:"col-span-8"},tx={class:"col-span-4"},nx={class:"mt-4 p-0"},ix={class:"grid grid-cols-12 gap-8 mb-8"},rx={class:"col-span-5"},ox={class:"col-span-7"},sx={class:"grid grid-cols-12 gap-4 mb-8"},ax={class:"col-span-4 space-y-4"},lx={class:"col-span-8"},ux=c.defineComponent({__name:"Homepage",setup(e){const t=[{color:"#60A5FA",name:"Blue",value:50},{color:"#CBD5E1",name:"Gray",value:20},{color:"#00DC82",name:"Green",value:30}],n=[{accessorKey:"name",header:"name",cell:({row:i})=>c.h("div",{class:"flex items-center gap-4"},[c.h("span",{style:{width:"0.75rem",height:"0.75rem",backgroundColor:i.original.color,display:"block"}},""),c.h("span",{},`${i.getValue("name")}`)])},{accessorKey:"value",header:"value",cell:({row:i})=>`${i.getValue("value")}`}];return(i,r)=>{const o=c.resolveComponent("RouterLink");return c.openBlock(),c.createElementBlock("div",j1,[c.createElementVNode("header",Z1,[c.createElementVNode("div",Q1,[c.createVNode(ir.Logo)]),r[3]||(r[3]=c.createElementVNode("h1",{class:"text-6xl font-bold tracking-tight text-gray-900 dark:text-white text-center max-w-3xl mx-auto"}," Vue components to build charts and dashboards ",-1)),r[4]||(r[4]=c.createElementVNode("p",{class:"mt-6 text-lg tracking-tight text-gray-600 dark:text-gray-400 text-center max-w-xl mx-auto"}," Powerful & Accessible Vue Components for Dashboards & Charts. Built with Tailwind CSS and Nuxt UI. ",-1)),c.createElementVNode("div",K1,[(c.openBlock(),c.createBlock(o,{key:0,to:"/auth/login"},{default:c.withCtx(()=>[c.createVNode(ir.Button,{color:"primary",icon:"i-heroicons:arrow-right-20-solid",trailing:!0,size:"lg"},{default:c.withCtx(()=>r[0]||(r[0]=[c.createTextVNode(" Sign in ")])),_:1})]),_:1})),c.createVNode(o,{to:"/overview"},{default:c.withCtx(()=>[c.createVNode(ir.Button,{color:"white",icon:"i-heroicons:swatch",size:"lg"},{default:c.withCtx(()=>r[2]||(r[2]=[c.createTextVNode(" Overview ")])),_:1})]),_:1})])]),c.createElementVNode("div",J1,[c.createElementVNode("div",ex,[c.createVNode(Ie,null,{header:c.withCtx(()=>r[5]||(r[5]=[c.createElementVNode("h2",{class:"heading-2"},"Multi line chart",-1),c.createElementVNode("p",{class:"text-gray-500"},"Website visitors per device",-1)])),default:c.withCtx(()=>[c.createVNode(c.unref(fy),{data:c.unref(qa),height:322,"pagination-poisition":c.unref(pc).Bottom,categories:c.unref(X1),"y-num-ticks":8,"x-formatter":s=>`${c.unref(qa)[s].date}`,"curve-type":c.unref(Y).MonotoneX},null,8,["data","pagination-poisition","categories","x-formatter","curve-type"])]),_:1})]),c.createElementVNode("div",tx,[c.createVNode(Ie,null,{header:c.withCtx(()=>r[6]||(r[6]=[c.createElementVNode("h2",{class:"heading-2"},"Donut Chart Example",-1),c.createElementVNode("p",{class:"text-gray-500"},"Color Distribution",-1)])),default:c.withCtx(()=>[c.createVNode(c.unref(oy),{data:t.map(s=>s.value),height:200,labels:t,"hide-pagination":!0,radius:0},{default:c.withCtx(()=>r[7]||(r[7]=[c.createElementVNode("div",{class:"absolute text-center"},[c.createElementVNode("div",{class:"font-semibold dark:text-white"},"Label"),c.createElementVNode("div",{class:"text-gray-500"},"2 seconds ago")],-1)])),_:1},8,["data"]),c.createElementVNode("div",nx,[c.createVNode(q1,{data:t,columns:n,"enable-sorting":!1,"enable-pagination":!1,"enable-filtering":!1,"enable-row-selection":!0,"table-size":"md",striped:!0,hover:!0,bordered:!1,"pagination-position":"bottom","page-size-options":[5,10,20,50],"initial-page-size":10})])]),_:1})])]),c.createElementVNode("div",ix,[c.createElementVNode("div",rx,[c.createVNode(Ie,{class:"h-full"},{default:c.withCtx(()=>[c.createVNode(Ie,null,{footer:c.withCtx(()=>r[8]||(r[8]=[c.createElementVNode("div",{class:"flex justify-end text-sm items-center gap-2"},[c.createElementVNode("span",null,"View more"),c.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",class:"size-4"},[c.createElementVNode("path",{"fill-rule":"evenodd",d:"M16.72 7.72a.75.75 0 0 1 1.06 0l3.75 3.75a.75.75 0 0 1 0 1.06l-3.75 3.75a.75.75 0 1 1-1.06-1.06l2.47-2.47H3a.75.75 0 0 1 0-1.5h16.19l-2.47-2.47a.75.75 0 0 1 0-1.06Z","clip-rule":"evenodd"})])],-1)])),default:c.withCtx(()=>[r[9]||(r[9]=c.createElementVNode("div",{class:"space-y-2 mb-4"},[c.createElementVNode("p",{class:"text-gray-500 mb-1"},"NuxtLabs"),c.createElementVNode("div",{class:"flex items-center justify-between"},[c.createElementVNode("h2",{class:"text-xl dark:text-white font-bold"},"$75.1K"),c.createElementVNode("div",{class:"flex items-center gap-2 text-sm"},[c.createElementVNode("div",null,"+$1.1K"),c.createElementVNode("div",{class:"text-gray-500"},"+9.1%")])])],-1)),c.createVNode(c.unref(xy),{data:c.unref(kc),height:50,categories:c.unref(Xa),"y-axis":["value"],"hide-legend":!0,"hide-tooltip":!0,"y-formatter":()=>"","x-formatter":()=>""},null,8,["data","categories"])]),_:1})]),_:1})]),c.createElementVNode("div",ox,[c.createVNode(Ie,{class:"h-full"},{footer:c.withCtx(()=>r[10]||(r[10]=[c.createElementVNode("h2",{class:"heading-2"},"Advanced visualizations",-1),c.createElementVNode("p",{class:"text-gray-500"}," Tracker, Bar Lists, and many more components to visualize complex use cases gracefully. ",-1)])),default:c.withCtx(()=>[c.createVNode(c.unref(Fc))]),_:1})])]),c.createVNode(Ie,null,{default:c.withCtx(()=>[c.createElementVNode("div",sx,[c.createElementVNode("div",ax,[c.createVNode(Ie,null,{default:c.withCtx(()=>[c.createVNode(c.unref(wr),{color:"#05DF72",label:"Storage used",value:"1.85GB",total:10,progress:1.85,unit:"GB"})]),_:1}),c.createVNode(Ie,null,{default:c.withCtx(()=>[c.createVNode(c.unref(wr),{color:"#05DF72",label:"Weekly active users",value:"250",total:512,progress:250})]),_:1}),c.createVNode(Ie,null,{default:c.withCtx(()=>[c.createVNode(c.unref(wr),{color:"#05DF72",label:"Current costs",value:"$293.5",total:300,progress:293.5})]),_:1})]),c.createElementVNode("div",lx,[c.createVNode(Ie,null,{header:c.withCtx(()=>r[11]||(r[11]=[c.createElementVNode("h2",{class:"heading-2"},"Beautiful Bar Chart",-1),c.createElementVNode("p",{class:"text-gray-500"}," Tracker, Bar Lists, and many more components to visualize complex use cases gracefully. ",-1)])),default:c.withCtx(()=>[c.createVNode(c.unref(by),{data:c.unref(xo),height:306,categories:c.unref(Xa),"y-axis":["value"],"hide-legend":!0,"y-formatter":s=>s,"x-formatter":s=>`${c.unref(xo)[s].date}`,"x-num-ticks":12},null,8,["data","categories","y-formatter","x-formatter"])]),_:1})])])]),_:1})])}}});exports.default=ux;
|